language
stringclasses
1 value
code
stringlengths
6
12.3k
avg_line_length
float64
2.79
91
line_count
float64
1
367
lang_specific_parse
stringlengths
60
1.08M
ast_node_count
int64
2
6.81k
num_errors
int64
0
499
universal_schema
stringlengths
799
825k
__index_level_0__
int64
0
81.2k
c
/* * * This license is set out in https://raw.githubusercontent.com/Broadcom-Network-Switching-Software/OpenBCM/master/Legal/LICENSE file. * * Copyright 2007-2019 Broadcom Inc. All rights reserved. * * Broadcom System Log Management */ #include <sal/core/libc.h> #include <sal/appl/io.h> #include <shared/bsl.h> #include <shared/bslnames.h> #include <appl/diag/bslenable.h> #include <appl/diag/bslcons.h> #include <appl/diag/bsltrace.h> #include <appl/diag/bslfile.h> #include <appl/diag/bslsink.h> #include <appl/diag/bslmgmt.h> /* * Output hook for core BSL configuration */ STATIC int bslmgmt_out_hook(bsl_meta_t *meta, const char *format, va_list args) { int rv = 0; int sink_rv; va_list args_copy; bslsink_sink_t *sink = bslsink_sink_find_by_id(0); if (meta->severity > bslenable_get(meta->layer, meta->source)) { return 0; } while (sink != NULL) { /* Avoid consuming same arg list twice. */ va_copy(args_copy, args); sink_rv = bslsink_out(sink, meta, format, args_copy); va_end(args_copy); if (sink_rv > 0) { rv = sink_rv; } sink = sink->next; } return rv; } /* * Check hook for core BSL configuration */ STATIC int bslmgmt_check_hook(bsl_packed_meta_t meta_pack) { int layer, source, severity; layer = BSL_LAYER_GET(meta_pack); source = BSL_SOURCE_GET(meta_pack); severity = BSL_SEVERITY_GET(meta_pack); return (severity <= bslenable_get(layer, source)); } int bslmgmt_cleanup(void) { return bslsink_cleanup(); } int bslmgmt_init(void) { bsl_config_t bsl_config; bslenable_reset_all(); bsl_config_t_init(&bsl_config); bsl_config.out_hook = bslmgmt_out_hook; bsl_config.check_hook = bslmgmt_check_hook; bsl_init(&bsl_config); /* Initialize output hook */ bslsink_init(); /* Create console sink */ bslcons_init(); #ifndef NO_FILEIO /* Create file sink */ bslfile_init(); #endif #ifdef BSL_TRACE_INCLUDE /* Create trace sink */ bsltrace_init(); /* Turn on debug so that trace sink can catch it */ bslmgmt_set(bslLayerBcm, bslSourceTrace, bslSeverityDebug); bslmgmt_set(bslLayerSoc, bslSourceTrace, bslSeverityDebug); #endif return 0; }
25.33
86
(translation_unit) "/*\n * \n * This license is set out in https://raw.githubusercontent.com/Broadcom-Network-Switching-Software/OpenBCM/master/Legal/LICENSE file.\n * \n * Copyright 2007-2019 Broadcom Inc. All rights reserved.\n *\n * Broadcom System Log Management\n */\n\n#include <sal/core/libc.h> \n#include <sal/appl/io.h> \n#include <shared/bsl.h>\n#include <shared/bslnames.h>\n#include <appl/diag/bslenable.h>\n#include <appl/diag/bslcons.h>\n#include <appl/diag/bsltrace.h>\n#include <appl/diag/bslfile.h>\n#include <appl/diag/bslsink.h>\n#include <appl/diag/bslmgmt.h>\n\n/*\n * Output hook for core BSL configuration\n */\nSTATIC int\nbslmgmt_out_hook(bsl_meta_t *meta, const char *format, va_list args)\n{\n int rv = 0;\n int sink_rv;\n va_list args_copy;\n bslsink_sink_t *sink = bslsink_sink_find_by_id(0);\n\n if (meta->severity > bslenable_get(meta->layer, meta->source)) {\n return 0;\n }\n\n while (sink != NULL) {\n /* Avoid consuming same arg list twice. */\n va_copy(args_copy, args);\n sink_rv = bslsink_out(sink, meta, format, args_copy);\n va_end(args_copy); \n if (sink_rv > 0) {\n rv = sink_rv;\n }\n sink = sink->next;\n }\n return rv;\n}\n\n/*\n * Check hook for core BSL configuration\n */\nSTATIC int\nbslmgmt_check_hook(bsl_packed_meta_t meta_pack)\n{\n int layer, source, severity;\n\n layer = BSL_LAYER_GET(meta_pack);\n source = BSL_SOURCE_GET(meta_pack);\n severity = BSL_SEVERITY_GET(meta_pack);\n\n return (severity <= bslenable_get(layer, source));\n}\n\nint\nbslmgmt_cleanup(void)\n{\n return bslsink_cleanup();\n}\n\nint\nbslmgmt_init(void)\n{\n bsl_config_t bsl_config;\n\n bslenable_reset_all();\n\n bsl_config_t_init(&bsl_config);\n bsl_config.out_hook = bslmgmt_out_hook;\n bsl_config.check_hook = bslmgmt_check_hook;\n bsl_init(&bsl_config);\n\n /* Initialize output hook */\n bslsink_init();\n\n /* Create console sink */\n bslcons_init();\n\n#ifndef NO_FILEIO\n /* Create file sink */\n bslfile_init();\n#endif\n\n#ifdef BSL_TRACE_INCLUDE\n /* Create trace sink */\n bsltrace_init();\n /* Turn on debug so that trace sink can catch it */\n bslmgmt_set(bslLayerBcm, bslSourceTrace, bslSeverityDebug);\n bslmgmt_set(bslLayerSoc, bslSourceTrace, bslSeverityDebug);\n#endif\n\n return 0;\n}\n" (comment) "/*\n * \n * This license is set out in https://raw.githubusercontent.com/Broadcom-Network-Switching-Software/OpenBCM/master/Legal/LICENSE file.\n * \n * Copyright 2007-2019 Broadcom Inc. All rights reserved.\n *\n * Broadcom System Log Management\n */" (preproc_include) "#include <sal/core/libc.h>" (#include) "#include" (system_lib_string) "<sal/core/libc.h>" (preproc_include) "#include <sal/appl/io.h>" (#include) "#include" (system_lib_string) "<sal/appl/io.h>" (preproc_include) "#include <shared/bsl.h>\n" (#include) "#include" (system_lib_string) "<shared/bsl.h>" (preproc_include) "#include <shared/bslnames.h>\n" (#include) "#include" (system_lib_string) "<shared/bslnames.h>" (preproc_include) "#include <appl/diag/bslenable.h>\n" (#include) "#include" (system_lib_string) "<appl/diag/bslenable.h>" (preproc_include) "#include <appl/diag/bslcons.h>\n" (#include) "#include" (system_lib_string) "<appl/diag/bslcons.h>" (preproc_include) "#include <appl/diag/bsltrace.h>\n" (#include) "#include" (system_lib_string) "<appl/diag/bsltrace.h>" (preproc_include) "#include <appl/diag/bslfile.h>\n" (#include) "#include" (system_lib_string) "<appl/diag/bslfile.h>" (preproc_include) "#include <appl/diag/bslsink.h>\n" (#include) "#include" (system_lib_string) "<appl/diag/bslsink.h>" (preproc_include) "#include <appl/diag/bslmgmt.h>\n" (#include) "#include" (system_lib_string) "<appl/diag/bslmgmt.h>" (comment) "/*\n * Output hook for core BSL configuration\n */" (function_definition) "STATIC int\nbslmgmt_out_hook(bsl_meta_t *meta, const char *format, va_list args)\n{\n int rv = 0;\n int sink_rv;\n va_list args_copy;\n bslsink_sink_t *sink = bslsink_sink_find_by_id(0);\n\n if (meta->severity > bslenable_get(meta->layer, meta->source)) {\n return 0;\n }\n\n while (sink != NULL) {\n /* Avoid consuming same arg list twice. */\n va_copy(args_copy, args);\n sink_rv = bslsink_out(sink, meta, format, args_copy);\n va_end(args_copy); \n if (sink_rv > 0) {\n rv = sink_rv;\n }\n sink = sink->next;\n }\n return rv;\n}" (type_identifier) "STATIC" (ERROR) "int" (identifier) "int" (function_declarator) "bslmgmt_out_hook(bsl_meta_t *meta, const char *format, va_list args)" (identifier) "bslmgmt_out_hook" (parameter_list) "(bsl_meta_t *meta, const char *format, va_list args)" (() "(" (parameter_declaration) "bsl_meta_t *meta" (type_identifier) "bsl_meta_t" (pointer_declarator) "*meta" (*) "*" (identifier) "meta" (,) "," (parameter_declaration) "const char *format" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "*format" (*) "*" (identifier) "format" (,) "," (parameter_declaration) "va_list args" (type_identifier) "va_list" (identifier) "args" ()) ")" (compound_statement) "{\n int rv = 0;\n int sink_rv;\n va_list args_copy;\n bslsink_sink_t *sink = bslsink_sink_find_by_id(0);\n\n if (meta->severity > bslenable_get(meta->layer, meta->source)) {\n return 0;\n }\n\n while (sink != NULL) {\n /* Avoid consuming same arg list twice. */\n va_copy(args_copy, args);\n sink_rv = bslsink_out(sink, meta, format, args_copy);\n va_end(args_copy); \n if (sink_rv > 0) {\n rv = sink_rv;\n }\n sink = sink->next;\n }\n return rv;\n}" ({) "{" (declaration) "int rv = 0;" (primitive_type) "int" (init_declarator) "rv = 0" (identifier) "rv" (=) "=" (number_literal) "0" (;) ";" (declaration) "int sink_rv;" (primitive_type) "int" (identifier) "sink_rv" (;) ";" (declaration) "va_list args_copy;" (type_identifier) "va_list" (identifier) "args_copy" (;) ";" (declaration) "bslsink_sink_t *sink = bslsink_sink_find_by_id(0);" (type_identifier) "bslsink_sink_t" (init_declarator) "*sink = bslsink_sink_find_by_id(0)" (pointer_declarator) "*sink" (*) "*" (identifier) "sink" (=) "=" (call_expression) "bslsink_sink_find_by_id(0)" (identifier) "bslsink_sink_find_by_id" (argument_list) "(0)" (() "(" (number_literal) "0" ()) ")" (;) ";" (if_statement) "if (meta->severity > bslenable_get(meta->layer, meta->source)) {\n return 0;\n }" (if) "if" (parenthesized_expression) "(meta->severity > bslenable_get(meta->layer, meta->source))" (() "(" (binary_expression) "meta->severity > bslenable_get(meta->layer, meta->source)" (field_expression) "meta->severity" (identifier) "meta" (->) "->" (field_identifier) "severity" (>) ">" (call_expression) "bslenable_get(meta->layer, meta->source)" (identifier) "bslenable_get" (argument_list) "(meta->layer, meta->source)" (() "(" (field_expression) "meta->layer" (identifier) "meta" (->) "->" (field_identifier) "layer" (,) "," (field_expression) "meta->source" (identifier) "meta" (->) "->" (field_identifier) "source" ()) ")" ()) ")" (compound_statement) "{\n return 0;\n }" ({) "{" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (while_statement) "while (sink != NULL) {\n /* Avoid consuming same arg list twice. */\n va_copy(args_copy, args);\n sink_rv = bslsink_out(sink, meta, format, args_copy);\n va_end(args_copy); \n if (sink_rv > 0) {\n rv = sink_rv;\n }\n sink = sink->next;\n }" (while) "while" (parenthesized_expression) "(sink != NULL)" (() "(" (binary_expression) "sink != NULL" (identifier) "sink" (!=) "!=" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{\n /* Avoid consuming same arg list twice. */\n va_copy(args_copy, args);\n sink_rv = bslsink_out(sink, meta, format, args_copy);\n va_end(args_copy); \n if (sink_rv > 0) {\n rv = sink_rv;\n }\n sink = sink->next;\n }" ({) "{" (comment) "/* Avoid consuming same arg list twice. */" (expression_statement) "va_copy(args_copy, args);" (call_expression) "va_copy(args_copy, args)" (identifier) "va_copy" (argument_list) "(args_copy, args)" (() "(" (identifier) "args_copy" (,) "," (identifier) "args" ()) ")" (;) ";" (expression_statement) "sink_rv = bslsink_out(sink, meta, format, args_copy);" (assignment_expression) "sink_rv = bslsink_out(sink, meta, format, args_copy)" (identifier) "sink_rv" (=) "=" (call_expression) "bslsink_out(sink, meta, format, args_copy)" (identifier) "bslsink_out" (argument_list) "(sink, meta, format, args_copy)" (() "(" (identifier) "sink" (,) "," (identifier) "meta" (,) "," (identifier) "format" (,) "," (identifier) "args_copy" ()) ")" (;) ";" (expression_statement) "va_end(args_copy);" (call_expression) "va_end(args_copy)" (identifier) "va_end" (argument_list) "(args_copy)" (() "(" (identifier) "args_copy" ()) ")" (;) ";" (if_statement) "if (sink_rv > 0) {\n rv = sink_rv;\n }" (if) "if" (parenthesized_expression) "(sink_rv > 0)" (() "(" (binary_expression) "sink_rv > 0" (identifier) "sink_rv" (>) ">" (number_literal) "0" ()) ")" (compound_statement) "{\n rv = sink_rv;\n }" ({) "{" (expression_statement) "rv = sink_rv;" (assignment_expression) "rv = sink_rv" (identifier) "rv" (=) "=" (identifier) "sink_rv" (;) ";" (}) "}" (expression_statement) "sink = sink->next;" (assignment_expression) "sink = sink->next" (identifier) "sink" (=) "=" (field_expression) "sink->next" (identifier) "sink" (->) "->" (field_identifier) "next" (;) ";" (}) "}" (return_statement) "return rv;" (return) "return" (identifier) "rv" (;) ";" (}) "}" (comment) "/*\n * Check hook for core BSL configuration\n */" (function_definition) "STATIC int\nbslmgmt_check_hook(bsl_packed_meta_t meta_pack)\n{\n int layer, source, severity;\n\n layer = BSL_LAYER_GET(meta_pack);\n source = BSL_SOURCE_GET(meta_pack);\n severity = BSL_SEVERITY_GET(meta_pack);\n\n return (severity <= bslenable_get(layer, source));\n}" (type_identifier) "STATIC" (ERROR) "int" (identifier) "int" (function_declarator) "bslmgmt_check_hook(bsl_packed_meta_t meta_pack)" (identifier) "bslmgmt_check_hook" (parameter_list) "(bsl_packed_meta_t meta_pack)" (() "(" (parameter_declaration) "bsl_packed_meta_t meta_pack" (type_identifier) "bsl_packed_meta_t" (identifier) "meta_pack" ()) ")" (compound_statement) "{\n int layer, source, severity;\n\n layer = BSL_LAYER_GET(meta_pack);\n source = BSL_SOURCE_GET(meta_pack);\n severity = BSL_SEVERITY_GET(meta_pack);\n\n return (severity <= bslenable_get(layer, source));\n}" ({) "{" (declaration) "int layer, source, severity;" (primitive_type) "int" (identifier) "layer" (,) "," (identifier) "source" (,) "," (identifier) "severity" (;) ";" (expression_statement) "layer = BSL_LAYER_GET(meta_pack);" (assignment_expression) "layer = BSL_LAYER_GET(meta_pack)" (identifier) "layer" (=) "=" (call_expression) "BSL_LAYER_GET(meta_pack)" (identifier) "BSL_LAYER_GET" (argument_list) "(meta_pack)" (() "(" (identifier) "meta_pack" ()) ")" (;) ";" (expression_statement) "source = BSL_SOURCE_GET(meta_pack);" (assignment_expression) "source = BSL_SOURCE_GET(meta_pack)" (identifier) "source" (=) "=" (call_expression) "BSL_SOURCE_GET(meta_pack)" (identifier) "BSL_SOURCE_GET" (argument_list) "(meta_pack)" (() "(" (identifier) "meta_pack" ()) ")" (;) ";" (expression_statement) "severity = BSL_SEVERITY_GET(meta_pack);" (assignment_expression) "severity = BSL_SEVERITY_GET(meta_pack)" (identifier) "severity" (=) "=" (call_expression) "BSL_SEVERITY_GET(meta_pack)" (identifier) "BSL_SEVERITY_GET" (argument_list) "(meta_pack)" (() "(" (identifier) "meta_pack" ()) ")" (;) ";" (return_statement) "return (severity <= bslenable_get(layer, source));" (return) "return" (parenthesized_expression) "(severity <= bslenable_get(layer, source))" (() "(" (binary_expression) "severity <= bslenable_get(layer, source)" (identifier) "severity" (<=) "<=" (call_expression) "bslenable_get(layer, source)" (identifier) "bslenable_get" (argument_list) "(layer, source)" (() "(" (identifier) "layer" (,) "," (identifier) "source" ()) ")" ()) ")" (;) ";" (}) "}" (function_definition) "int\nbslmgmt_cleanup(void)\n{\n return bslsink_cleanup();\n}" (primitive_type) "int" (function_declarator) "bslmgmt_cleanup(void)" (identifier) "bslmgmt_cleanup" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (compound_statement) "{\n return bslsink_cleanup();\n}" ({) "{" (return_statement) "return bslsink_cleanup();" (return) "return" (call_expression) "bslsink_cleanup()" (identifier) "bslsink_cleanup" (argument_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (function_definition) "int\nbslmgmt_init(void)\n{\n bsl_config_t bsl_config;\n\n bslenable_reset_all();\n\n bsl_config_t_init(&bsl_config);\n bsl_config.out_hook = bslmgmt_out_hook;\n bsl_config.check_hook = bslmgmt_check_hook;\n bsl_init(&bsl_config);\n\n /* Initialize output hook */\n bslsink_init();\n\n /* Create console sink */\n bslcons_init();\n\n#ifndef NO_FILEIO\n /* Create file sink */\n bslfile_init();\n#endif\n\n#ifdef BSL_TRACE_INCLUDE\n /* Create trace sink */\n bsltrace_init();\n /* Turn on debug so that trace sink can catch it */\n bslmgmt_set(bslLayerBcm, bslSourceTrace, bslSeverityDebug);\n bslmgmt_set(bslLayerSoc, bslSourceTrace, bslSeverityDebug);\n#endif\n\n return 0;\n}" (primitive_type) "int" (function_declarator) "bslmgmt_init(void)" (identifier) "bslmgmt_init" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (compound_statement) "{\n bsl_config_t bsl_config;\n\n bslenable_reset_all();\n\n bsl_config_t_init(&bsl_config);\n bsl_config.out_hook = bslmgmt_out_hook;\n bsl_config.check_hook = bslmgmt_check_hook;\n bsl_init(&bsl_config);\n\n /* Initialize output hook */\n bslsink_init();\n\n /* Create console sink */\n bslcons_init();\n\n#ifndef NO_FILEIO\n /* Create file sink */\n bslfile_init();\n#endif\n\n#ifdef BSL_TRACE_INCLUDE\n /* Create trace sink */\n bsltrace_init();\n /* Turn on debug so that trace sink can catch it */\n bslmgmt_set(bslLayerBcm, bslSourceTrace, bslSeverityDebug);\n bslmgmt_set(bslLayerSoc, bslSourceTrace, bslSeverityDebug);\n#endif\n\n return 0;\n}" ({) "{" (declaration) "bsl_config_t bsl_config;" (type_identifier) "bsl_config_t" (identifier) "bsl_config" (;) ";" (expression_statement) "bslenable_reset_all();" (call_expression) "bslenable_reset_all()" (identifier) "bslenable_reset_all" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "bsl_config_t_init(&bsl_config);" (call_expression) "bsl_config_t_init(&bsl_config)" (identifier) "bsl_config_t_init" (argument_list) "(&bsl_config)" (() "(" (pointer_expression) "&bsl_config" (&) "&" (identifier) "bsl_config" ()) ")" (;) ";" (expression_statement) "bsl_config.out_hook = bslmgmt_out_hook;" (assignment_expression) "bsl_config.out_hook = bslmgmt_out_hook" (field_expression) "bsl_config.out_hook" (identifier) "bsl_config" (.) "." (field_identifier) "out_hook" (=) "=" (identifier) "bslmgmt_out_hook" (;) ";" (expression_statement) "bsl_config.check_hook = bslmgmt_check_hook;" (assignment_expression) "bsl_config.check_hook = bslmgmt_check_hook" (field_expression) "bsl_config.check_hook" (identifier) "bsl_config" (.) "." (field_identifier) "check_hook" (=) "=" (identifier) "bslmgmt_check_hook" (;) ";" (expression_statement) "bsl_init(&bsl_config);" (call_expression) "bsl_init(&bsl_config)" (identifier) "bsl_init" (argument_list) "(&bsl_config)" (() "(" (pointer_expression) "&bsl_config" (&) "&" (identifier) "bsl_config" ()) ")" (;) ";" (comment) "/* Initialize output hook */" (expression_statement) "bslsink_init();" (call_expression) "bslsink_init()" (identifier) "bslsink_init" (argument_list) "()" (() "(" ()) ")" (;) ";" (comment) "/* Create console sink */" (expression_statement) "bslcons_init();" (call_expression) "bslcons_init()" (identifier) "bslcons_init" (argument_list) "()" (() "(" ()) ")" (;) ";" (preproc_ifdef) "#ifndef NO_FILEIO\n /* Create file sink */\n bslfile_init();\n#endif" (#ifndef) "#ifndef" (identifier) "NO_FILEIO" (comment) "/* Create file sink */" (expression_statement) "bslfile_init();" (call_expression) "bslfile_init()" (identifier) "bslfile_init" (argument_list) "()" (() "(" ()) ")" (;) ";" (#endif) "#endif" (preproc_ifdef) "#ifdef BSL_TRACE_INCLUDE\n /* Create trace sink */\n bsltrace_init();\n /* Turn on debug so that trace sink can catch it */\n bslmgmt_set(bslLayerBcm, bslSourceTrace, bslSeverityDebug);\n bslmgmt_set(bslLayerSoc, bslSourceTrace, bslSeverityDebug);\n#endif" (#ifdef) "#ifdef" (identifier) "BSL_TRACE_INCLUDE" (comment) "/* Create trace sink */" (expression_statement) "bsltrace_init();" (call_expression) "bsltrace_init()" (identifier) "bsltrace_init" (argument_list) "()" (() "(" ()) ")" (;) ";" (comment) "/* Turn on debug so that trace sink can catch it */" (expression_statement) "bslmgmt_set(bslLayerBcm, bslSourceTrace, bslSeverityDebug);" (call_expression) "bslmgmt_set(bslLayerBcm, bslSourceTrace, bslSeverityDebug)" (identifier) "bslmgmt_set" (argument_list) "(bslLayerBcm, bslSourceTrace, bslSeverityDebug)" (() "(" (identifier) "bslLayerBcm" (,) "," (identifier) "bslSourceTrace" (,) "," (identifier) "bslSeverityDebug" ()) ")" (;) ";" (expression_statement) "bslmgmt_set(bslLayerSoc, bslSourceTrace, bslSeverityDebug);" (call_expression) "bslmgmt_set(bslLayerSoc, bslSourceTrace, bslSeverityDebug)" (identifier) "bslmgmt_set" (argument_list) "(bslLayerSoc, bslSourceTrace, bslSeverityDebug)" (() "(" (identifier) "bslLayerSoc" (,) "," (identifier) "bslSourceTrace" (,) "," (identifier) "bslSeverityDebug" ()) ")" (;) ";" (#endif) "#endif" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}"
427
2
{"language": "c", "success": true, "metadata": {"lines": 86, "avg_line_length": 25.33, "nodes": 261, "errors": 0, "source_hash": "238ab44b052baa9cd1640e12c5f7383d7bc0f208b90227632cbd41eb9e564e83", "categorized_nodes": 204}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <sal/core/libc.h>", "parent": null, "children": [1, 2], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 26}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<sal/core/libc.h>", "parent": 0, "children": [], "start_point": {"row": 9, "column": 9}, "end_point": {"row": 9, "column": 26}}, {"id": 3, "type": "preproc_include", "text": "#include <sal/appl/io.h>", "parent": null, "children": [4, 5], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 24}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<sal/appl/io.h>", "parent": 3, "children": [], "start_point": {"row": 10, "column": 9}, "end_point": {"row": 10, "column": 24}}, {"id": 6, "type": "preproc_include", "text": "#include <shared/bsl.h>\n", "parent": null, "children": [7, 8], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 12, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<shared/bsl.h>", "parent": 6, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 23}}, {"id": 9, "type": "preproc_include", "text": "#include <shared/bslnames.h>\n", "parent": null, "children": [10, 11], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 13, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<shared/bslnames.h>", "parent": 9, "children": [], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 28}}, {"id": 12, "type": "preproc_include", "text": "#include <appl/diag/bslenable.h>\n", "parent": null, "children": [13, 14], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 14, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 8}}, {"id": 14, "type": "system_lib_string", "text": "<appl/diag/bslenable.h>", "parent": 12, "children": [], "start_point": {"row": 13, "column": 9}, "end_point": {"row": 13, "column": 32}}, {"id": 15, "type": "preproc_include", "text": "#include <appl/diag/bslcons.h>\n", "parent": null, "children": [16, 17], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 15, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 8}}, {"id": 17, "type": "system_lib_string", "text": "<appl/diag/bslcons.h>", "parent": 15, "children": [], "start_point": {"row": 14, "column": 9}, "end_point": {"row": 14, "column": 30}}, {"id": 18, "type": "preproc_include", "text": "#include <appl/diag/bsltrace.h>\n", "parent": null, "children": [19, 20], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 8}}, {"id": 20, "type": "system_lib_string", "text": "<appl/diag/bsltrace.h>", "parent": 18, "children": [], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 31}}, {"id": 21, "type": "preproc_include", "text": "#include <appl/diag/bslfile.h>\n", "parent": null, "children": [22, 23], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 17, "column": 0}}, {"id": 22, "type": "#include", "text": "#include", "parent": 21, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 8}}, {"id": 23, "type": "system_lib_string", "text": "<appl/diag/bslfile.h>", "parent": 21, "children": [], "start_point": {"row": 16, "column": 9}, "end_point": {"row": 16, "column": 30}}, {"id": 24, "type": "preproc_include", "text": "#include <appl/diag/bslsink.h>\n", "parent": null, "children": [25, 26], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 18, "column": 0}}, {"id": 25, "type": "#include", "text": "#include", "parent": 24, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 8}}, {"id": 26, "type": "system_lib_string", "text": "<appl/diag/bslsink.h>", "parent": 24, "children": [], "start_point": {"row": 17, "column": 9}, "end_point": {"row": 17, "column": 30}}, {"id": 27, "type": "preproc_include", "text": "#include <appl/diag/bslmgmt.h>\n", "parent": null, "children": [28, 29], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 19, "column": 0}}, {"id": 28, "type": "#include", "text": "#include", "parent": 27, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 8}}, {"id": 29, "type": "system_lib_string", "text": "<appl/diag/bslmgmt.h>", "parent": 27, "children": [], "start_point": {"row": 18, "column": 9}, "end_point": {"row": 18, "column": 30}}, {"id": 30, "type": "function_definition", "text": "STATIC int\nbslmgmt_out_hook(bsl_meta_t *meta, const char *format, va_list args)\n{\n int rv = 0;\n int sink_rv;\n va_list args_copy;\n bslsink_sink_t *sink = bslsink_sink_find_by_id(0);\n\n if (meta->severity > bslenable_get(meta->layer, meta->source)) {\n return 0;\n }\n\n while (sink != NULL) {\n /* Avoid consuming same arg list twice. */\n va_copy(args_copy, args);\n sink_rv = bslsink_out(sink, meta, format, args_copy);\n va_end(args_copy); \n if (sink_rv > 0) {\n rv = sink_rv;\n }\n sink = sink->next;\n }\n return rv;\n}", "parent": null, "children": [31, 32, 34], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 46, "column": 1}}, {"id": 31, "type": "type_identifier", "text": "STATIC", "parent": 30, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 6}}, {"id": 32, "type": "ERROR", "text": "int", "parent": 30, "children": [33], "start_point": {"row": 23, "column": 7}, "end_point": {"row": 23, "column": 10}}, {"id": 33, "type": "identifier", "text": "int", "parent": 32, "children": [], "start_point": {"row": 23, "column": 7}, "end_point": {"row": 23, "column": 10}}, {"id": 34, "type": "function_declarator", "text": "bslmgmt_out_hook(bsl_meta_t *meta, const char *format, va_list args)", "parent": 30, "children": [35, 36], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 68}}, {"id": 35, "type": "identifier", "text": "bslmgmt_out_hook", "parent": 34, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 16}}, {"id": 36, "type": "parameter_list", "text": "(bsl_meta_t *meta, const char *format, va_list args)", "parent": 34, "children": [37, 42, 47], "start_point": {"row": 24, "column": 16}, "end_point": {"row": 24, "column": 68}}, {"id": 37, "type": "parameter_declaration", "text": "bsl_meta_t *meta", "parent": 36, "children": [38, 39], "start_point": {"row": 24, "column": 17}, "end_point": {"row": 24, "column": 33}}, {"id": 38, "type": "type_identifier", "text": "bsl_meta_t", "parent": 37, "children": [], "start_point": {"row": 24, "column": 17}, "end_point": {"row": 24, "column": 27}}, {"id": 39, "type": "pointer_declarator", "text": "*meta", "parent": 37, "children": [40, 41], "start_point": {"row": 24, "column": 28}, "end_point": {"row": 24, "column": 33}}, {"id": 40, "type": "*", "text": "*", "parent": 39, "children": [], "start_point": {"row": 24, "column": 28}, "end_point": {"row": 24, "column": 29}}, {"id": 41, "type": "identifier", "text": "meta", "parent": 39, "children": [], "start_point": {"row": 24, "column": 29}, "end_point": {"row": 24, "column": 33}}, {"id": 42, "type": "parameter_declaration", "text": "const char *format", "parent": 36, "children": [43, 44], "start_point": {"row": 24, "column": 35}, "end_point": {"row": 24, "column": 53}}, {"id": 43, "type": "primitive_type", "text": "char", "parent": 42, "children": [], "start_point": {"row": 24, "column": 41}, "end_point": {"row": 24, "column": 45}}, {"id": 44, "type": "pointer_declarator", "text": "*format", "parent": 42, "children": [45, 46], "start_point": {"row": 24, "column": 46}, "end_point": {"row": 24, "column": 53}}, {"id": 45, "type": "*", "text": "*", "parent": 44, "children": [], "start_point": {"row": 24, "column": 46}, "end_point": {"row": 24, "column": 47}}, {"id": 46, "type": "identifier", "text": "format", "parent": 44, "children": [], "start_point": {"row": 24, "column": 47}, "end_point": {"row": 24, "column": 53}}, {"id": 47, "type": "parameter_declaration", "text": "va_list args", "parent": 36, "children": [48, 49], "start_point": {"row": 24, "column": 55}, "end_point": {"row": 24, "column": 67}}, {"id": 48, "type": "type_identifier", "text": "va_list", "parent": 47, "children": [], "start_point": {"row": 24, "column": 55}, "end_point": {"row": 24, "column": 62}}, {"id": 49, "type": "identifier", "text": "args", "parent": 47, "children": [], "start_point": {"row": 24, "column": 63}, "end_point": {"row": 24, "column": 67}}, {"id": 50, "type": "declaration", "text": "int rv = 0;", "parent": 30, "children": [51, 52], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 26, "column": 15}}, {"id": 51, "type": "primitive_type", "text": "int", "parent": 50, "children": [], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 26, "column": 7}}, {"id": 52, "type": "init_declarator", "text": "rv = 0", "parent": 50, "children": [53, 54, 55], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 14}}, {"id": 53, "type": "identifier", "text": "rv", "parent": 52, "children": [], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 10}}, {"id": 54, "type": "=", "text": "=", "parent": 52, "children": [], "start_point": {"row": 26, "column": 11}, "end_point": {"row": 26, "column": 12}}, {"id": 55, "type": "number_literal", "text": "0", "parent": 52, "children": [], "start_point": {"row": 26, "column": 13}, "end_point": {"row": 26, "column": 14}}, {"id": 56, "type": "declaration", "text": "int sink_rv;", "parent": 30, "children": [57, 58], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 16}}, {"id": 57, "type": "primitive_type", "text": "int", "parent": 56, "children": [], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 7}}, {"id": 58, "type": "identifier", "text": "sink_rv", "parent": 56, "children": [], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 15}}, {"id": 59, "type": "declaration", "text": "va_list args_copy;", "parent": 30, "children": [60, 61], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 28, "column": 22}}, {"id": 60, "type": "type_identifier", "text": "va_list", "parent": 59, "children": [], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 28, "column": 11}}, {"id": 61, "type": "identifier", "text": "args_copy", "parent": 59, "children": [], "start_point": {"row": 28, "column": 12}, "end_point": {"row": 28, "column": 21}}, {"id": 62, "type": "declaration", "text": "bslsink_sink_t *sink = bslsink_sink_find_by_id(0);", "parent": 30, "children": [63, 64], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 54}}, {"id": 63, "type": "type_identifier", "text": "bslsink_sink_t", "parent": 62, "children": [], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 18}}, {"id": 64, "type": "init_declarator", "text": "*sink = bslsink_sink_find_by_id(0)", "parent": 62, "children": [65, 68, 69], "start_point": {"row": 29, "column": 19}, "end_point": {"row": 29, "column": 53}}, {"id": 65, "type": "pointer_declarator", "text": "*sink", "parent": 64, "children": [66, 67], "start_point": {"row": 29, "column": 19}, "end_point": {"row": 29, "column": 24}}, {"id": 66, "type": "*", "text": "*", "parent": 65, "children": [], "start_point": {"row": 29, "column": 19}, "end_point": {"row": 29, "column": 20}}, {"id": 67, "type": "identifier", "text": "sink", "parent": 65, "children": [], "start_point": {"row": 29, "column": 20}, "end_point": {"row": 29, "column": 24}}, {"id": 68, "type": "=", "text": "=", "parent": 64, "children": [], "start_point": {"row": 29, "column": 25}, "end_point": {"row": 29, "column": 26}}, {"id": 69, "type": "call_expression", "text": "bslsink_sink_find_by_id(0)", "parent": 64, "children": [70, 71], "start_point": {"row": 29, "column": 27}, "end_point": {"row": 29, "column": 53}}, {"id": 70, "type": "identifier", "text": "bslsink_sink_find_by_id", "parent": 69, "children": [], "start_point": {"row": 29, "column": 27}, "end_point": {"row": 29, "column": 50}}, {"id": 71, "type": "argument_list", "text": "(0)", "parent": 69, "children": [72], "start_point": {"row": 29, "column": 50}, "end_point": {"row": 29, "column": 53}}, {"id": 72, "type": "number_literal", "text": "0", "parent": 71, "children": [], "start_point": {"row": 29, "column": 51}, "end_point": {"row": 29, "column": 52}}, {"id": 73, "type": "if_statement", "text": "if (meta->severity > bslenable_get(meta->layer, meta->source)) {\n return 0;\n }", "parent": 30, "children": [74], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 33, "column": 5}}, {"id": 74, "type": "parenthesized_expression", "text": "(meta->severity > bslenable_get(meta->layer, meta->source))", "parent": 73, "children": [75], "start_point": {"row": 31, "column": 7}, "end_point": {"row": 31, "column": 66}}, {"id": 75, "type": "binary_expression", "text": "meta->severity > bslenable_get(meta->layer, meta->source)", "parent": 74, "children": [76, 79, 80], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 65}}, {"id": 76, "type": "field_expression", "text": "meta->severity", "parent": 75, "children": [77, 78], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 22}}, {"id": 77, "type": "identifier", "text": "meta", "parent": 76, "children": [], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 12}}, {"id": 78, "type": "field_identifier", "text": "severity", "parent": 76, "children": [], "start_point": {"row": 31, "column": 14}, "end_point": {"row": 31, "column": 22}}, {"id": 79, "type": ">", "text": ">", "parent": 75, "children": [], "start_point": {"row": 31, "column": 23}, "end_point": {"row": 31, "column": 24}}, {"id": 80, "type": "call_expression", "text": "bslenable_get(meta->layer, meta->source)", "parent": 75, "children": [81, 82], "start_point": {"row": 31, "column": 25}, "end_point": {"row": 31, "column": 65}}, {"id": 81, "type": "identifier", "text": "bslenable_get", "parent": 80, "children": [], "start_point": {"row": 31, "column": 25}, "end_point": {"row": 31, "column": 38}}, {"id": 82, "type": "argument_list", "text": "(meta->layer, meta->source)", "parent": 80, "children": [83, 86], "start_point": {"row": 31, "column": 38}, "end_point": {"row": 31, "column": 65}}, {"id": 83, "type": "field_expression", "text": "meta->layer", "parent": 82, "children": [84, 85], "start_point": {"row": 31, "column": 39}, "end_point": {"row": 31, "column": 50}}, {"id": 84, "type": "identifier", "text": "meta", "parent": 83, "children": [], "start_point": {"row": 31, "column": 39}, "end_point": {"row": 31, "column": 43}}, {"id": 85, "type": "field_identifier", "text": "layer", "parent": 83, "children": [], "start_point": {"row": 31, "column": 45}, "end_point": {"row": 31, "column": 50}}, {"id": 86, "type": "field_expression", "text": "meta->source", "parent": 82, "children": [87, 88], "start_point": {"row": 31, "column": 52}, "end_point": {"row": 31, "column": 64}}, {"id": 87, "type": "identifier", "text": "meta", "parent": 86, "children": [], "start_point": {"row": 31, "column": 52}, "end_point": {"row": 31, "column": 56}}, {"id": 88, "type": "field_identifier", "text": "source", "parent": 86, "children": [], "start_point": {"row": 31, "column": 58}, "end_point": {"row": 31, "column": 64}}, {"id": 89, "type": "return_statement", "text": "return 0;", "parent": 73, "children": [90], "start_point": {"row": 32, "column": 8}, "end_point": {"row": 32, "column": 17}}, {"id": 90, "type": "number_literal", "text": "0", "parent": 89, "children": [], "start_point": {"row": 32, "column": 15}, "end_point": {"row": 32, "column": 16}}, {"id": 91, "type": "while_statement", "text": "while (sink != NULL) {\n /* Avoid consuming same arg list twice. */\n va_copy(args_copy, args);\n sink_rv = bslsink_out(sink, meta, format, args_copy);\n va_end(args_copy); \n if (sink_rv > 0) {\n rv = sink_rv;\n }\n sink = sink->next;\n }", "parent": 30, "children": [92], "start_point": {"row": 35, "column": 4}, "end_point": {"row": 44, "column": 5}}, {"id": 92, "type": "parenthesized_expression", "text": "(sink != NULL)", "parent": 91, "children": [93], "start_point": {"row": 35, "column": 10}, "end_point": {"row": 35, "column": 24}}, {"id": 93, "type": "binary_expression", "text": "sink != NULL", "parent": 92, "children": [94, 95, 96], "start_point": {"row": 35, "column": 11}, "end_point": {"row": 35, "column": 23}}, {"id": 94, "type": "identifier", "text": "sink", "parent": 93, "children": [], "start_point": {"row": 35, "column": 11}, "end_point": {"row": 35, "column": 15}}, {"id": 95, "type": "!=", "text": "!=", "parent": 93, "children": [], "start_point": {"row": 35, "column": 16}, "end_point": {"row": 35, "column": 18}}, {"id": 96, "type": "null", "text": "NULL", "parent": 93, "children": [97], "start_point": {"row": 35, "column": 19}, "end_point": {"row": 35, "column": 23}}, {"id": 97, "type": "NULL", "text": "NULL", "parent": 96, "children": [], "start_point": {"row": 35, "column": 19}, "end_point": {"row": 35, "column": 23}}, {"id": 98, "type": "call_expression", "text": "va_copy(args_copy, args)", "parent": 91, "children": [99, 100], "start_point": {"row": 37, "column": 8}, "end_point": {"row": 37, "column": 32}}, {"id": 99, "type": "identifier", "text": "va_copy", "parent": 98, "children": [], "start_point": {"row": 37, "column": 8}, "end_point": {"row": 37, "column": 15}}, {"id": 100, "type": "argument_list", "text": "(args_copy, args)", "parent": 98, "children": [101, 102], "start_point": {"row": 37, "column": 15}, "end_point": {"row": 37, "column": 32}}, {"id": 101, "type": "identifier", "text": "args_copy", "parent": 100, "children": [], "start_point": {"row": 37, "column": 16}, "end_point": {"row": 37, "column": 25}}, {"id": 102, "type": "identifier", "text": "args", "parent": 100, "children": [], "start_point": {"row": 37, "column": 27}, "end_point": {"row": 37, "column": 31}}, {"id": 103, "type": "assignment_expression", "text": "sink_rv = bslsink_out(sink, meta, format, args_copy)", "parent": 91, "children": [104, 105, 106], "start_point": {"row": 38, "column": 8}, "end_point": {"row": 38, "column": 60}}, {"id": 104, "type": "identifier", "text": "sink_rv", "parent": 103, "children": [], "start_point": {"row": 38, "column": 8}, "end_point": {"row": 38, "column": 15}}, {"id": 105, "type": "=", "text": "=", "parent": 103, "children": [], "start_point": {"row": 38, "column": 16}, "end_point": {"row": 38, "column": 17}}, {"id": 106, "type": "call_expression", "text": "bslsink_out(sink, meta, format, args_copy)", "parent": 103, "children": [107, 108], "start_point": {"row": 38, "column": 18}, "end_point": {"row": 38, "column": 60}}, {"id": 107, "type": "identifier", "text": "bslsink_out", "parent": 106, "children": [], "start_point": {"row": 38, "column": 18}, "end_point": {"row": 38, "column": 29}}, {"id": 108, "type": "argument_list", "text": "(sink, meta, format, args_copy)", "parent": 106, "children": [109, 110, 111, 112], "start_point": {"row": 38, "column": 29}, "end_point": {"row": 38, "column": 60}}, {"id": 109, "type": "identifier", "text": "sink", "parent": 108, "children": [], "start_point": {"row": 38, "column": 30}, "end_point": {"row": 38, "column": 34}}, {"id": 110, "type": "identifier", "text": "meta", "parent": 108, "children": [], "start_point": {"row": 38, "column": 36}, "end_point": {"row": 38, "column": 40}}, {"id": 111, "type": "identifier", "text": "format", "parent": 108, "children": [], "start_point": {"row": 38, "column": 42}, "end_point": {"row": 38, "column": 48}}, {"id": 112, "type": "identifier", "text": "args_copy", "parent": 108, "children": [], "start_point": {"row": 38, "column": 50}, "end_point": {"row": 38, "column": 59}}, {"id": 113, "type": "call_expression", "text": "va_end(args_copy)", "parent": 91, "children": [114, 115], "start_point": {"row": 39, "column": 8}, "end_point": {"row": 39, "column": 25}}, {"id": 114, "type": "identifier", "text": "va_end", "parent": 113, "children": [], "start_point": {"row": 39, "column": 8}, "end_point": {"row": 39, "column": 14}}, {"id": 115, "type": "argument_list", "text": "(args_copy)", "parent": 113, "children": [116], "start_point": {"row": 39, "column": 14}, "end_point": {"row": 39, "column": 25}}, {"id": 116, "type": "identifier", "text": "args_copy", "parent": 115, "children": [], "start_point": {"row": 39, "column": 15}, "end_point": {"row": 39, "column": 24}}, {"id": 117, "type": "if_statement", "text": "if (sink_rv > 0) {\n rv = sink_rv;\n }", "parent": 91, "children": [118], "start_point": {"row": 40, "column": 8}, "end_point": {"row": 42, "column": 9}}, {"id": 118, "type": "parenthesized_expression", "text": "(sink_rv > 0)", "parent": 117, "children": [119], "start_point": {"row": 40, "column": 11}, "end_point": {"row": 40, "column": 24}}, {"id": 119, "type": "binary_expression", "text": "sink_rv > 0", "parent": 118, "children": [120, 121, 122], "start_point": {"row": 40, "column": 12}, "end_point": {"row": 40, "column": 23}}, {"id": 120, "type": "identifier", "text": "sink_rv", "parent": 119, "children": [], "start_point": {"row": 40, "column": 12}, "end_point": {"row": 40, "column": 19}}, {"id": 121, "type": ">", "text": ">", "parent": 119, "children": [], "start_point": {"row": 40, "column": 20}, "end_point": {"row": 40, "column": 21}}, {"id": 122, "type": "number_literal", "text": "0", "parent": 119, "children": [], "start_point": {"row": 40, "column": 22}, "end_point": {"row": 40, "column": 23}}, {"id": 123, "type": "assignment_expression", "text": "rv = sink_rv", "parent": 117, "children": [124, 125, 126], "start_point": {"row": 41, "column": 12}, "end_point": {"row": 41, "column": 24}}, {"id": 124, "type": "identifier", "text": "rv", "parent": 123, "children": [], "start_point": {"row": 41, "column": 12}, "end_point": {"row": 41, "column": 14}}, {"id": 125, "type": "=", "text": "=", "parent": 123, "children": [], "start_point": {"row": 41, "column": 15}, "end_point": {"row": 41, "column": 16}}, {"id": 126, "type": "identifier", "text": "sink_rv", "parent": 123, "children": [], "start_point": {"row": 41, "column": 17}, "end_point": {"row": 41, "column": 24}}, {"id": 127, "type": "assignment_expression", "text": "sink = sink->next", "parent": 91, "children": [128, 129, 130], "start_point": {"row": 43, "column": 8}, "end_point": {"row": 43, "column": 25}}, {"id": 128, "type": "identifier", "text": "sink", "parent": 127, "children": [], "start_point": {"row": 43, "column": 8}, "end_point": {"row": 43, "column": 12}}, {"id": 129, "type": "=", "text": "=", "parent": 127, "children": [], "start_point": {"row": 43, "column": 13}, "end_point": {"row": 43, "column": 14}}, {"id": 130, "type": "field_expression", "text": "sink->next", "parent": 127, "children": [131, 132], "start_point": {"row": 43, "column": 15}, "end_point": {"row": 43, "column": 25}}, {"id": 131, "type": "identifier", "text": "sink", "parent": 130, "children": [], "start_point": {"row": 43, "column": 15}, "end_point": {"row": 43, "column": 19}}, {"id": 132, "type": "field_identifier", "text": "next", "parent": 130, "children": [], "start_point": {"row": 43, "column": 21}, "end_point": {"row": 43, "column": 25}}, {"id": 133, "type": "return_statement", "text": "return rv;", "parent": 30, "children": [134], "start_point": {"row": 45, "column": 4}, "end_point": {"row": 45, "column": 14}}, {"id": 134, "type": "identifier", "text": "rv", "parent": 133, "children": [], "start_point": {"row": 45, "column": 11}, "end_point": {"row": 45, "column": 13}}, {"id": 135, "type": "function_definition", "text": "STATIC int\nbslmgmt_check_hook(bsl_packed_meta_t meta_pack)\n{\n int layer, source, severity;\n\n layer = BSL_LAYER_GET(meta_pack);\n source = BSL_SOURCE_GET(meta_pack);\n severity = BSL_SEVERITY_GET(meta_pack);\n\n return (severity <= bslenable_get(layer, source));\n}", "parent": null, "children": [136, 137, 139], "start_point": {"row": 51, "column": 0}, "end_point": {"row": 61, "column": 1}}, {"id": 136, "type": "type_identifier", "text": "STATIC", "parent": 135, "children": [], "start_point": {"row": 51, "column": 0}, "end_point": {"row": 51, "column": 6}}, {"id": 137, "type": "ERROR", "text": "int", "parent": 135, "children": [138], "start_point": {"row": 51, "column": 7}, "end_point": {"row": 51, "column": 10}}, {"id": 138, "type": "identifier", "text": "int", "parent": 137, "children": [], "start_point": {"row": 51, "column": 7}, "end_point": {"row": 51, "column": 10}}, {"id": 139, "type": "function_declarator", "text": "bslmgmt_check_hook(bsl_packed_meta_t meta_pack)", "parent": 135, "children": [140, 141], "start_point": {"row": 52, "column": 0}, "end_point": {"row": 52, "column": 47}}, {"id": 140, "type": "identifier", "text": "bslmgmt_check_hook", "parent": 139, "children": [], "start_point": {"row": 52, "column": 0}, "end_point": {"row": 52, "column": 18}}, {"id": 141, "type": "parameter_list", "text": "(bsl_packed_meta_t meta_pack)", "parent": 139, "children": [142], "start_point": {"row": 52, "column": 18}, "end_point": {"row": 52, "column": 47}}, {"id": 142, "type": "parameter_declaration", "text": "bsl_packed_meta_t meta_pack", "parent": 141, "children": [143, 144], "start_point": {"row": 52, "column": 19}, "end_point": {"row": 52, "column": 46}}, {"id": 143, "type": "type_identifier", "text": "bsl_packed_meta_t", "parent": 142, "children": [], "start_point": {"row": 52, "column": 19}, "end_point": {"row": 52, "column": 36}}, {"id": 144, "type": "identifier", "text": "meta_pack", "parent": 142, "children": [], "start_point": {"row": 52, "column": 37}, "end_point": {"row": 52, "column": 46}}, {"id": 145, "type": "declaration", "text": "int layer, source, severity;", "parent": 135, "children": [146, 147, 148, 149], "start_point": {"row": 54, "column": 4}, "end_point": {"row": 54, "column": 32}}, {"id": 146, "type": "primitive_type", "text": "int", "parent": 145, "children": [], "start_point": {"row": 54, "column": 4}, "end_point": {"row": 54, "column": 7}}, {"id": 147, "type": "identifier", "text": "layer", "parent": 145, "children": [], "start_point": {"row": 54, "column": 8}, "end_point": {"row": 54, "column": 13}}, {"id": 148, "type": "identifier", "text": "source", "parent": 145, "children": [], "start_point": {"row": 54, "column": 15}, "end_point": {"row": 54, "column": 21}}, {"id": 149, "type": "identifier", "text": "severity", "parent": 145, "children": [], "start_point": {"row": 54, "column": 23}, "end_point": {"row": 54, "column": 31}}, {"id": 150, "type": "assignment_expression", "text": "layer = BSL_LAYER_GET(meta_pack)", "parent": 135, "children": [151, 152, 153], "start_point": {"row": 56, "column": 4}, "end_point": {"row": 56, "column": 36}}, {"id": 151, "type": "identifier", "text": "layer", "parent": 150, "children": [], "start_point": {"row": 56, "column": 4}, "end_point": {"row": 56, "column": 9}}, {"id": 152, "type": "=", "text": "=", "parent": 150, "children": [], "start_point": {"row": 56, "column": 10}, "end_point": {"row": 56, "column": 11}}, {"id": 153, "type": "call_expression", "text": "BSL_LAYER_GET(meta_pack)", "parent": 150, "children": [154, 155], "start_point": {"row": 56, "column": 12}, "end_point": {"row": 56, "column": 36}}, {"id": 154, "type": "identifier", "text": "BSL_LAYER_GET", "parent": 153, "children": [], "start_point": {"row": 56, "column": 12}, "end_point": {"row": 56, "column": 25}}, {"id": 155, "type": "argument_list", "text": "(meta_pack)", "parent": 153, "children": [156], "start_point": {"row": 56, "column": 25}, "end_point": {"row": 56, "column": 36}}, {"id": 156, "type": "identifier", "text": "meta_pack", "parent": 155, "children": [], "start_point": {"row": 56, "column": 26}, "end_point": {"row": 56, "column": 35}}, {"id": 157, "type": "assignment_expression", "text": "source = BSL_SOURCE_GET(meta_pack)", "parent": 135, "children": [158, 159, 160], "start_point": {"row": 57, "column": 4}, "end_point": {"row": 57, "column": 38}}, {"id": 158, "type": "identifier", "text": "source", "parent": 157, "children": [], "start_point": {"row": 57, "column": 4}, "end_point": {"row": 57, "column": 10}}, {"id": 159, "type": "=", "text": "=", "parent": 157, "children": [], "start_point": {"row": 57, "column": 11}, "end_point": {"row": 57, "column": 12}}, {"id": 160, "type": "call_expression", "text": "BSL_SOURCE_GET(meta_pack)", "parent": 157, "children": [161, 162], "start_point": {"row": 57, "column": 13}, "end_point": {"row": 57, "column": 38}}, {"id": 161, "type": "identifier", "text": "BSL_SOURCE_GET", "parent": 160, "children": [], "start_point": {"row": 57, "column": 13}, "end_point": {"row": 57, "column": 27}}, {"id": 162, "type": "argument_list", "text": "(meta_pack)", "parent": 160, "children": [163], "start_point": {"row": 57, "column": 27}, "end_point": {"row": 57, "column": 38}}, {"id": 163, "type": "identifier", "text": "meta_pack", "parent": 162, "children": [], "start_point": {"row": 57, "column": 28}, "end_point": {"row": 57, "column": 37}}, {"id": 164, "type": "assignment_expression", "text": "severity = BSL_SEVERITY_GET(meta_pack)", "parent": 135, "children": [165, 166, 167], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 42}}, {"id": 165, "type": "identifier", "text": "severity", "parent": 164, "children": [], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 12}}, {"id": 166, "type": "=", "text": "=", "parent": 164, "children": [], "start_point": {"row": 58, "column": 13}, "end_point": {"row": 58, "column": 14}}, {"id": 167, "type": "call_expression", "text": "BSL_SEVERITY_GET(meta_pack)", "parent": 164, "children": [168, 169], "start_point": {"row": 58, "column": 15}, "end_point": {"row": 58, "column": 42}}, {"id": 168, "type": "identifier", "text": "BSL_SEVERITY_GET", "parent": 167, "children": [], "start_point": {"row": 58, "column": 15}, "end_point": {"row": 58, "column": 31}}, {"id": 169, "type": "argument_list", "text": "(meta_pack)", "parent": 167, "children": [170], "start_point": {"row": 58, "column": 31}, "end_point": {"row": 58, "column": 42}}, {"id": 170, "type": "identifier", "text": "meta_pack", "parent": 169, "children": [], "start_point": {"row": 58, "column": 32}, "end_point": {"row": 58, "column": 41}}, {"id": 171, "type": "return_statement", "text": "return (severity <= bslenable_get(layer, source));", "parent": 135, "children": [172], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 54}}, {"id": 172, "type": "parenthesized_expression", "text": "(severity <= bslenable_get(layer, source))", "parent": 171, "children": [173], "start_point": {"row": 60, "column": 11}, "end_point": {"row": 60, "column": 53}}, {"id": 173, "type": "binary_expression", "text": "severity <= bslenable_get(layer, source)", "parent": 172, "children": [174, 175, 176], "start_point": {"row": 60, "column": 12}, "end_point": {"row": 60, "column": 52}}, {"id": 174, "type": "identifier", "text": "severity", "parent": 173, "children": [], "start_point": {"row": 60, "column": 12}, "end_point": {"row": 60, "column": 20}}, {"id": 175, "type": "<=", "text": "<=", "parent": 173, "children": [], "start_point": {"row": 60, "column": 21}, "end_point": {"row": 60, "column": 23}}, {"id": 176, "type": "call_expression", "text": "bslenable_get(layer, source)", "parent": 173, "children": [177, 178], "start_point": {"row": 60, "column": 24}, "end_point": {"row": 60, "column": 52}}, {"id": 177, "type": "identifier", "text": "bslenable_get", "parent": 176, "children": [], "start_point": {"row": 60, "column": 24}, "end_point": {"row": 60, "column": 37}}, {"id": 178, "type": "argument_list", "text": "(layer, source)", "parent": 176, "children": [179, 180], "start_point": {"row": 60, "column": 37}, "end_point": {"row": 60, "column": 52}}, {"id": 179, "type": "identifier", "text": "layer", "parent": 178, "children": [], "start_point": {"row": 60, "column": 38}, "end_point": {"row": 60, "column": 43}}, {"id": 180, "type": "identifier", "text": "source", "parent": 178, "children": [], "start_point": {"row": 60, "column": 45}, "end_point": {"row": 60, "column": 51}}, {"id": 181, "type": "function_definition", "text": "int\nbslmgmt_cleanup(void)\n{\n return bslsink_cleanup();\n}", "parent": null, "children": [182, 183], "start_point": {"row": 63, "column": 0}, "end_point": {"row": 67, "column": 1}}, {"id": 182, "type": "primitive_type", "text": "int", "parent": 181, "children": [], "start_point": {"row": 63, "column": 0}, "end_point": {"row": 63, "column": 3}}, {"id": 183, "type": "function_declarator", "text": "bslmgmt_cleanup(void)", "parent": 181, "children": [184, 185], "start_point": {"row": 64, "column": 0}, "end_point": {"row": 64, "column": 21}}, {"id": 184, "type": "identifier", "text": "bslmgmt_cleanup", "parent": 183, "children": [], "start_point": {"row": 64, "column": 0}, "end_point": {"row": 64, "column": 15}}, {"id": 185, "type": "parameter_list", "text": "(void)", "parent": 183, "children": [186], "start_point": {"row": 64, "column": 15}, "end_point": {"row": 64, "column": 21}}, {"id": 186, "type": "parameter_declaration", "text": "void", "parent": 185, "children": [187], "start_point": {"row": 64, "column": 16}, "end_point": {"row": 64, "column": 20}}, {"id": 187, "type": "primitive_type", "text": "void", "parent": 186, "children": [], "start_point": {"row": 64, "column": 16}, "end_point": {"row": 64, "column": 20}}, {"id": 188, "type": "return_statement", "text": "return bslsink_cleanup();", "parent": 181, "children": [189], "start_point": {"row": 66, "column": 4}, "end_point": {"row": 66, "column": 29}}, {"id": 189, "type": "call_expression", "text": "bslsink_cleanup()", "parent": 188, "children": [190, 191], "start_point": {"row": 66, "column": 11}, "end_point": {"row": 66, "column": 28}}, {"id": 190, "type": "identifier", "text": "bslsink_cleanup", "parent": 189, "children": [], "start_point": {"row": 66, "column": 11}, "end_point": {"row": 66, "column": 26}}, {"id": 191, "type": "argument_list", "text": "()", "parent": 189, "children": [], "start_point": {"row": 66, "column": 26}, "end_point": {"row": 66, "column": 28}}, {"id": 192, "type": "function_definition", "text": "int\nbslmgmt_init(void)\n{\n bsl_config_t bsl_config;\n\n bslenable_reset_all();\n\n bsl_config_t_init(&bsl_config);\n bsl_config.out_hook = bslmgmt_out_hook;\n bsl_config.check_hook = bslmgmt_check_hook;\n bsl_init(&bsl_config);\n\n /* Initialize output hook */\n bslsink_init();\n\n /* Create console sink */\n bslcons_init();\n\n#ifndef NO_FILEIO\n /* Create file sink */\n bslfile_init();\n#endif\n\n#ifdef BSL_TRACE_INCLUDE\n /* Create trace sink */\n bsltrace_init();\n /* Turn on debug so that trace sink can catch it */\n bslmgmt_set(bslLayerBcm, bslSourceTrace, bslSeverityDebug);\n bslmgmt_set(bslLayerSoc, bslSourceTrace, bslSeverityDebug);\n#endif\n\n return 0;\n}", "parent": null, "children": [193, 194], "start_point": {"row": 69, "column": 0}, "end_point": {"row": 101, "column": 1}}, {"id": 193, "type": "primitive_type", "text": "int", "parent": 192, "children": [], "start_point": {"row": 69, "column": 0}, "end_point": {"row": 69, "column": 3}}, {"id": 194, "type": "function_declarator", "text": "bslmgmt_init(void)", "parent": 192, "children": [195, 196], "start_point": {"row": 70, "column": 0}, "end_point": {"row": 70, "column": 18}}, {"id": 195, "type": "identifier", "text": "bslmgmt_init", "parent": 194, "children": [], "start_point": {"row": 70, "column": 0}, "end_point": {"row": 70, "column": 12}}, {"id": 196, "type": "parameter_list", "text": "(void)", "parent": 194, "children": [197], "start_point": {"row": 70, "column": 12}, "end_point": {"row": 70, "column": 18}}, {"id": 197, "type": "parameter_declaration", "text": "void", "parent": 196, "children": [198], "start_point": {"row": 70, "column": 13}, "end_point": {"row": 70, "column": 17}}, {"id": 198, "type": "primitive_type", "text": "void", "parent": 197, "children": [], "start_point": {"row": 70, "column": 13}, "end_point": {"row": 70, "column": 17}}, {"id": 199, "type": "declaration", "text": "bsl_config_t bsl_config;", "parent": 192, "children": [200, 201], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 28}}, {"id": 200, "type": "type_identifier", "text": "bsl_config_t", "parent": 199, "children": [], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 16}}, {"id": 201, "type": "identifier", "text": "bsl_config", "parent": 199, "children": [], "start_point": {"row": 72, "column": 17}, "end_point": {"row": 72, "column": 27}}, {"id": 202, "type": "call_expression", "text": "bslenable_reset_all()", "parent": 192, "children": [203, 204], "start_point": {"row": 74, "column": 4}, "end_point": {"row": 74, "column": 25}}, {"id": 203, "type": "identifier", "text": "bslenable_reset_all", "parent": 202, "children": [], "start_point": {"row": 74, "column": 4}, "end_point": {"row": 74, "column": 23}}, {"id": 204, "type": "argument_list", "text": "()", "parent": 202, "children": [], "start_point": {"row": 74, "column": 23}, "end_point": {"row": 74, "column": 25}}, {"id": 205, "type": "call_expression", "text": "bsl_config_t_init(&bsl_config)", "parent": 192, "children": [206, 207], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 34}}, {"id": 206, "type": "identifier", "text": "bsl_config_t_init", "parent": 205, "children": [], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 21}}, {"id": 207, "type": "argument_list", "text": "(&bsl_config)", "parent": 205, "children": [208], "start_point": {"row": 76, "column": 21}, "end_point": {"row": 76, "column": 34}}, {"id": 208, "type": "pointer_expression", "text": "&bsl_config", "parent": 207, "children": [209], "start_point": {"row": 76, "column": 22}, "end_point": {"row": 76, "column": 33}}, {"id": 209, "type": "identifier", "text": "bsl_config", "parent": 208, "children": [], "start_point": {"row": 76, "column": 23}, "end_point": {"row": 76, "column": 33}}, {"id": 210, "type": "assignment_expression", "text": "bsl_config.out_hook = bslmgmt_out_hook", "parent": 192, "children": [211, 214, 215], "start_point": {"row": 77, "column": 4}, "end_point": {"row": 77, "column": 42}}, {"id": 211, "type": "field_expression", "text": "bsl_config.out_hook", "parent": 210, "children": [212, 213], "start_point": {"row": 77, "column": 4}, "end_point": {"row": 77, "column": 23}}, {"id": 212, "type": "identifier", "text": "bsl_config", "parent": 211, "children": [], "start_point": {"row": 77, "column": 4}, "end_point": {"row": 77, "column": 14}}, {"id": 213, "type": "field_identifier", "text": "out_hook", "parent": 211, "children": [], "start_point": {"row": 77, "column": 15}, "end_point": {"row": 77, "column": 23}}, {"id": 214, "type": "=", "text": "=", "parent": 210, "children": [], "start_point": {"row": 77, "column": 24}, "end_point": {"row": 77, "column": 25}}, {"id": 215, "type": "identifier", "text": "bslmgmt_out_hook", "parent": 210, "children": [], "start_point": {"row": 77, "column": 26}, "end_point": {"row": 77, "column": 42}}, {"id": 216, "type": "assignment_expression", "text": "bsl_config.check_hook = bslmgmt_check_hook", "parent": 192, "children": [217, 220, 221], "start_point": {"row": 78, "column": 4}, "end_point": {"row": 78, "column": 46}}, {"id": 217, "type": "field_expression", "text": "bsl_config.check_hook", "parent": 216, "children": [218, 219], "start_point": {"row": 78, "column": 4}, "end_point": {"row": 78, "column": 25}}, {"id": 218, "type": "identifier", "text": "bsl_config", "parent": 217, "children": [], "start_point": {"row": 78, "column": 4}, "end_point": {"row": 78, "column": 14}}, {"id": 219, "type": "field_identifier", "text": "check_hook", "parent": 217, "children": [], "start_point": {"row": 78, "column": 15}, "end_point": {"row": 78, "column": 25}}, {"id": 220, "type": "=", "text": "=", "parent": 216, "children": [], "start_point": {"row": 78, "column": 26}, "end_point": {"row": 78, "column": 27}}, {"id": 221, "type": "identifier", "text": "bslmgmt_check_hook", "parent": 216, "children": [], "start_point": {"row": 78, "column": 28}, "end_point": {"row": 78, "column": 46}}, {"id": 222, "type": "call_expression", "text": "bsl_init(&bsl_config)", "parent": 192, "children": [223, 224], "start_point": {"row": 79, "column": 4}, "end_point": {"row": 79, "column": 25}}, {"id": 223, "type": "identifier", "text": "bsl_init", "parent": 222, "children": [], "start_point": {"row": 79, "column": 4}, "end_point": {"row": 79, "column": 12}}, {"id": 224, "type": "argument_list", "text": "(&bsl_config)", "parent": 222, "children": [225], "start_point": {"row": 79, "column": 12}, "end_point": {"row": 79, "column": 25}}, {"id": 225, "type": "pointer_expression", "text": "&bsl_config", "parent": 224, "children": [226], "start_point": {"row": 79, "column": 13}, "end_point": {"row": 79, "column": 24}}, {"id": 226, "type": "identifier", "text": "bsl_config", "parent": 225, "children": [], "start_point": {"row": 79, "column": 14}, "end_point": {"row": 79, "column": 24}}, {"id": 227, "type": "call_expression", "text": "bslsink_init()", "parent": 192, "children": [228, 229], "start_point": {"row": 82, "column": 4}, "end_point": {"row": 82, "column": 18}}, {"id": 228, "type": "identifier", "text": "bslsink_init", "parent": 227, "children": [], "start_point": {"row": 82, "column": 4}, "end_point": {"row": 82, "column": 16}}, {"id": 229, "type": "argument_list", "text": "()", "parent": 227, "children": [], "start_point": {"row": 82, "column": 16}, "end_point": {"row": 82, "column": 18}}, {"id": 230, "type": "call_expression", "text": "bslcons_init()", "parent": 192, "children": [231, 232], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 18}}, {"id": 231, "type": "identifier", "text": "bslcons_init", "parent": 230, "children": [], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 16}}, {"id": 232, "type": "argument_list", "text": "()", "parent": 230, "children": [], "start_point": {"row": 85, "column": 16}, "end_point": {"row": 85, "column": 18}}, {"id": 233, "type": "preproc_ifdef", "text": "#ifndef NO_FILEIO\n /* Create file sink */\n bslfile_init();\n#endif", "parent": 192, "children": [234, 235, 239], "start_point": {"row": 87, "column": 0}, "end_point": {"row": 90, "column": 6}}, {"id": 234, "type": "#ifndef", "text": "#ifndef", "parent": 233, "children": [], "start_point": {"row": 87, "column": 0}, "end_point": {"row": 87, "column": 7}}, {"id": 235, "type": "identifier", "text": "NO_FILEIO", "parent": 233, "children": [], "start_point": {"row": 87, "column": 8}, "end_point": {"row": 87, "column": 17}}, {"id": 236, "type": "call_expression", "text": "bslfile_init()", "parent": 233, "children": [237, 238], "start_point": {"row": 89, "column": 4}, "end_point": {"row": 89, "column": 18}}, {"id": 237, "type": "identifier", "text": "bslfile_init", "parent": 236, "children": [], "start_point": {"row": 89, "column": 4}, "end_point": {"row": 89, "column": 16}}, {"id": 238, "type": "argument_list", "text": "()", "parent": 236, "children": [], "start_point": {"row": 89, "column": 16}, "end_point": {"row": 89, "column": 18}}, {"id": 239, "type": "#endif", "text": "#endif", "parent": 233, "children": [], "start_point": {"row": 90, "column": 0}, "end_point": {"row": 90, "column": 6}}, {"id": 240, "type": "preproc_ifdef", "text": "#ifdef BSL_TRACE_INCLUDE\n /* Create trace sink */\n bsltrace_init();\n /* Turn on debug so that trace sink can catch it */\n bslmgmt_set(bslLayerBcm, bslSourceTrace, bslSeverityDebug);\n bslmgmt_set(bslLayerSoc, bslSourceTrace, bslSeverityDebug);\n#endif", "parent": 192, "children": [241, 242, 258], "start_point": {"row": 92, "column": 0}, "end_point": {"row": 98, "column": 6}}, {"id": 241, "type": "#ifdef", "text": "#ifdef", "parent": 240, "children": [], "start_point": {"row": 92, "column": 0}, "end_point": {"row": 92, "column": 6}}, {"id": 242, "type": "identifier", "text": "BSL_TRACE_INCLUDE", "parent": 240, "children": [], "start_point": {"row": 92, "column": 7}, "end_point": {"row": 92, "column": 24}}, {"id": 243, "type": "call_expression", "text": "bsltrace_init()", "parent": 240, "children": [244, 245], "start_point": {"row": 94, "column": 4}, "end_point": {"row": 94, "column": 19}}, {"id": 244, "type": "identifier", "text": "bsltrace_init", "parent": 243, "children": [], "start_point": {"row": 94, "column": 4}, "end_point": {"row": 94, "column": 17}}, {"id": 245, "type": "argument_list", "text": "()", "parent": 243, "children": [], "start_point": {"row": 94, "column": 17}, "end_point": {"row": 94, "column": 19}}, {"id": 246, "type": "call_expression", "text": "bslmgmt_set(bslLayerBcm, bslSourceTrace, bslSeverityDebug)", "parent": 240, "children": [247, 248], "start_point": {"row": 96, "column": 4}, "end_point": {"row": 96, "column": 62}}, {"id": 247, "type": "identifier", "text": "bslmgmt_set", "parent": 246, "children": [], "start_point": {"row": 96, "column": 4}, "end_point": {"row": 96, "column": 15}}, {"id": 248, "type": "argument_list", "text": "(bslLayerBcm, bslSourceTrace, bslSeverityDebug)", "parent": 246, "children": [249, 250, 251], "start_point": {"row": 96, "column": 15}, "end_point": {"row": 96, "column": 62}}, {"id": 249, "type": "identifier", "text": "bslLayerBcm", "parent": 248, "children": [], "start_point": {"row": 96, "column": 16}, "end_point": {"row": 96, "column": 27}}, {"id": 250, "type": "identifier", "text": "bslSourceTrace", "parent": 248, "children": [], "start_point": {"row": 96, "column": 29}, "end_point": {"row": 96, "column": 43}}, {"id": 251, "type": "identifier", "text": "bslSeverityDebug", "parent": 248, "children": [], "start_point": {"row": 96, "column": 45}, "end_point": {"row": 96, "column": 61}}, {"id": 252, "type": "call_expression", "text": "bslmgmt_set(bslLayerSoc, bslSourceTrace, bslSeverityDebug)", "parent": 240, "children": [253, 254], "start_point": {"row": 97, "column": 4}, "end_point": {"row": 97, "column": 62}}, {"id": 253, "type": "identifier", "text": "bslmgmt_set", "parent": 252, "children": [], "start_point": {"row": 97, "column": 4}, "end_point": {"row": 97, "column": 15}}, {"id": 254, "type": "argument_list", "text": "(bslLayerSoc, bslSourceTrace, bslSeverityDebug)", "parent": 252, "children": [255, 256, 257], "start_point": {"row": 97, "column": 15}, "end_point": {"row": 97, "column": 62}}, {"id": 255, "type": "identifier", "text": "bslLayerSoc", "parent": 254, "children": [], "start_point": {"row": 97, "column": 16}, "end_point": {"row": 97, "column": 27}}, {"id": 256, "type": "identifier", "text": "bslSourceTrace", "parent": 254, "children": [], "start_point": {"row": 97, "column": 29}, "end_point": {"row": 97, "column": 43}}, {"id": 257, "type": "identifier", "text": "bslSeverityDebug", "parent": 254, "children": [], "start_point": {"row": 97, "column": 45}, "end_point": {"row": 97, "column": 61}}, {"id": 258, "type": "#endif", "text": "#endif", "parent": 240, "children": [], "start_point": {"row": 98, "column": 0}, "end_point": {"row": 98, "column": 6}}, {"id": 259, "type": "return_statement", "text": "return 0;", "parent": 192, "children": [260], "start_point": {"row": 100, "column": 4}, "end_point": {"row": 100, "column": 13}}, {"id": 260, "type": "number_literal", "text": "0", "parent": 259, "children": [], "start_point": {"row": 100, "column": 11}, "end_point": {"row": 100, "column": 12}}]}, "node_categories": {"declarations": {"functions": [30, 34, 135, 139, 181, 183, 192, 194], "variables": [37, 42, 47, 50, 56, 59, 62, 142, 145, 186, 197, 199], "classes": [], "imports": [0, 1, 3, 4, 6, 7, 9, 10, 12, 13, 15, 16, 18, 19, 21, 22, 24, 25, 27, 28], "modules": [], "enums": []}, "statements": {"expressions": [69, 74, 75, 76, 80, 83, 86, 92, 93, 98, 106, 113, 118, 119, 130, 153, 160, 167, 172, 173, 176, 189, 202, 205, 208, 211, 217, 222, 225, 227, 230, 236, 243, 246, 252], "assignments": [103, 123, 127, 150, 157, 164, 210, 216], "loops": [91], "conditionals": [31, 33, 35, 38, 41, 46, 48, 49, 53, 58, 60, 61, 63, 67, 70, 73, 77, 78, 81, 84, 85, 87, 88, 94, 99, 101, 102, 104, 107, 109, 110, 111, 112, 114, 116, 117, 120, 124, 126, 128, 131, 132, 134, 136, 138, 140, 143, 144, 147, 148, 149, 151, 154, 156, 158, 161, 163, 165, 168, 170, 174, 177, 179, 180, 184, 190, 195, 200, 201, 203, 206, 209, 212, 213, 215, 218, 219, 221, 223, 226, 228, 231, 233, 234, 235, 237, 239, 240, 241, 242, 244, 247, 249, 250, 251, 253, 255, 256, 257, 258], "returns": [89, 133, 171, 188, 259], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 8, 11, 14, 17, 20, 23, 26, 29, 55, 72, 90, 122, 260], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 30, "universal_type": "function", "name": "bslmgmt_out_hook", "text_snippet": "STATIC int\nbslmgmt_out_hook(bsl_meta_t *meta, const char *format, va_list args)\n{\n int rv = 0;\n "}, {"node_id": 34, "universal_type": "function", "name": "unknown", "text_snippet": "bslmgmt_out_hook(bsl_meta_t *meta, const char *format, va_list args)"}, {"node_id": 135, "universal_type": "function", "name": "bslmgmt_check_hook", "text_snippet": "STATIC int\nbslmgmt_check_hook(bsl_packed_meta_t meta_pack)\n{\n int layer, source, severity;\n\n l"}, {"node_id": 139, "universal_type": "function", "name": "unknown", "text_snippet": "bslmgmt_check_hook(bsl_packed_meta_t meta_pack)"}, {"node_id": 181, "universal_type": "function", "name": "bslmgmt_cleanup", "text_snippet": "int\nbslmgmt_cleanup(void)\n{\n return bslsink_cleanup();\n}"}, {"node_id": 183, "universal_type": "function", "name": "unknown", "text_snippet": "bslmgmt_cleanup(void)"}, {"node_id": 192, "universal_type": "function", "name": "bslmgmt_init", "text_snippet": "int\nbslmgmt_init(void)\n{\n bsl_config_t bsl_config;\n\n bslenable_reset_all();\n\n bsl_config_t_"}, {"node_id": 194, "universal_type": "function", "name": "unknown", "text_snippet": "bslmgmt_init(void)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <sal/core/libc.h>"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <sal/appl/io.h>"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include <shared/bsl.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <shared/bslnames.h>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include <appl/diag/bslenable.h>\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include <appl/diag/bslcons.h>\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include <appl/diag/bsltrace.h>\n"}, {"node_id": 19, "text": "#include"}, {"node_id": 21, "text": "#include <appl/diag/bslfile.h>\n"}, {"node_id": 22, "text": "#include"}, {"node_id": 24, "text": "#include <appl/diag/bslsink.h>\n"}, {"node_id": 25, "text": "#include"}, {"node_id": 27, "text": "#include <appl/diag/bslmgmt.h>\n"}, {"node_id": 28, "text": "#include"}]}, "original_source_code": "/*\n * \n * This license is set out in https://raw.githubusercontent.com/Broadcom-Network-Switching-Software/OpenBCM/master/Legal/LICENSE file.\n * \n * Copyright 2007-2019 Broadcom Inc. All rights reserved.\n *\n * Broadcom System Log Management\n */\n\n#include <sal/core/libc.h> \n#include <sal/appl/io.h> \n#include <shared/bsl.h>\n#include <shared/bslnames.h>\n#include <appl/diag/bslenable.h>\n#include <appl/diag/bslcons.h>\n#include <appl/diag/bsltrace.h>\n#include <appl/diag/bslfile.h>\n#include <appl/diag/bslsink.h>\n#include <appl/diag/bslmgmt.h>\n\n/*\n * Output hook for core BSL configuration\n */\nSTATIC int\nbslmgmt_out_hook(bsl_meta_t *meta, const char *format, va_list args)\n{\n int rv = 0;\n int sink_rv;\n va_list args_copy;\n bslsink_sink_t *sink = bslsink_sink_find_by_id(0);\n\n if (meta->severity > bslenable_get(meta->layer, meta->source)) {\n return 0;\n }\n\n while (sink != NULL) {\n /* Avoid consuming same arg list twice. */\n va_copy(args_copy, args);\n sink_rv = bslsink_out(sink, meta, format, args_copy);\n va_end(args_copy); \n if (sink_rv > 0) {\n rv = sink_rv;\n }\n sink = sink->next;\n }\n return rv;\n}\n\n/*\n * Check hook for core BSL configuration\n */\nSTATIC int\nbslmgmt_check_hook(bsl_packed_meta_t meta_pack)\n{\n int layer, source, severity;\n\n layer = BSL_LAYER_GET(meta_pack);\n source = BSL_SOURCE_GET(meta_pack);\n severity = BSL_SEVERITY_GET(meta_pack);\n\n return (severity <= bslenable_get(layer, source));\n}\n\nint\nbslmgmt_cleanup(void)\n{\n return bslsink_cleanup();\n}\n\nint\nbslmgmt_init(void)\n{\n bsl_config_t bsl_config;\n\n bslenable_reset_all();\n\n bsl_config_t_init(&bsl_config);\n bsl_config.out_hook = bslmgmt_out_hook;\n bsl_config.check_hook = bslmgmt_check_hook;\n bsl_init(&bsl_config);\n\n /* Initialize output hook */\n bslsink_init();\n\n /* Create console sink */\n bslcons_init();\n\n#ifndef NO_FILEIO\n /* Create file sink */\n bslfile_init();\n#endif\n\n#ifdef BSL_TRACE_INCLUDE\n /* Create trace sink */\n bsltrace_init();\n /* Turn on debug so that trace sink can catch it */\n bslmgmt_set(bslLayerBcm, bslSourceTrace, bslSeverityDebug);\n bslmgmt_set(bslLayerSoc, bslSourceTrace, bslSeverityDebug);\n#endif\n\n return 0;\n}\n"}
80,500
c
/* * common.h * */ #ifndef COMMON_H_ #define COMMON_H_ // OpenGL Graphics Includes #define GLEW_STATIC #include <GL/glew.h> //#define GLFW_DLL #include <GLFW/glfw3.h> // NodeJS includes #include <node.h> #include <nan.h> using namespace v8; namespace { #define JS_STR(...) Nan::New<v8::String>(__VA_ARGS__) #define JS_INT(val) v8::Integer::New(v8::Isolate::GetCurrent(), val) #define JS_NUM(val) v8::Number::New(v8::Isolate::GetCurrent(), val) #define JS_BOOL(val) v8::Boolean::New(v8::Isolate::GetCurrent(), val) #define JS_METHOD(name) NAN_METHOD(name) #define JS_RETHROW(tc) v8::Local<v8::Value>::New(tc.Exception()); inline void ThrowError(const char* msg) { return Nan::ThrowError(msg); } inline void ThrowTypeError(const char* msg) { return Nan::ThrowTypeError(msg); } inline void ThrowRangeError(const char* msg) { return Nan::ThrowRangeError(msg); } #define REQ_ARGS(N) \ if (args.Length() < (N)) \ return ThrowTypeError("Expected " #N "arguments"); #define REQ_STR_ARG(I, VAR) \ if (args.Length() <= (I) || !args[I]->IsString()) \ return ThrowTypeError("Argument " #I " must be a string"); \ String::Utf8Value VAR(args[I]->ToString()); #define REQ_EXT_ARG(I, VAR) \ if (args.Length() <= (I) || !args[I]->IsExternal()) \ return ThrowTypeError("Argument " #I " invalid"); \ Local<External> VAR = Local<External>::Cast(args[I]); #define REQ_FUN_ARG(I, VAR) \ if (args.Length() <= (I) || !args[I]->IsFunction()) \ return ThrowTypeError("Argument " #I " must be a function"); \ Local<Function> VAR = Local<Function>::Cast(args[I]); #define REQ_ERROR_THROW(error) if (ret == error) return ThrowError(#error); } #endif /* COMMON_H_ */
43.02
45
(translation_unit) "/*\n * common.h\n *\n */\n\n#ifndef COMMON_H_\n#define COMMON_H_\n\n// OpenGL Graphics Includes\n#define GLEW_STATIC\n#include <GL/glew.h>\n\n//#define GLFW_DLL\n#include <GLFW/glfw3.h>\n\n// NodeJS includes\n#include <node.h>\n#include <nan.h>\n\nusing namespace v8;\n\nnamespace {\n#define JS_STR(...) Nan::New<v8::String>(__VA_ARGS__)\n#define JS_INT(val) v8::Integer::New(v8::Isolate::GetCurrent(), val)\n#define JS_NUM(val) v8::Number::New(v8::Isolate::GetCurrent(), val)\n#define JS_BOOL(val) v8::Boolean::New(v8::Isolate::GetCurrent(), val)\n#define JS_METHOD(name) NAN_METHOD(name)\n#define JS_RETHROW(tc) v8::Local<v8::Value>::New(tc.Exception());\n\ninline void ThrowError(const char* msg) {\n return Nan::ThrowError(msg);\n}\n\ninline void ThrowTypeError(const char* msg) {\n return Nan::ThrowTypeError(msg);\n}\n\ninline void ThrowRangeError(const char* msg) {\n return Nan::ThrowRangeError(msg);\n}\n\n#define REQ_ARGS(N) \\n if (args.Length() < (N)) \\n return ThrowTypeError("Expected " #N "arguments");\n\n#define REQ_STR_ARG(I, VAR) \\n if (args.Length() <= (I) || !args[I]->IsString()) \\n return ThrowTypeError("Argument " #I " must be a string"); \\n String::Utf8Value VAR(args[I]->ToString());\n\n#define REQ_EXT_ARG(I, VAR) \\n if (args.Length() <= (I) || !args[I]->IsExternal()) \\n return ThrowTypeError("Argument " #I " invalid"); \\n Local<External> VAR = Local<External>::Cast(args[I]);\n\n#define REQ_FUN_ARG(I, VAR) \\n if (args.Length() <= (I) || !args[I]->IsFunction()) \\n return ThrowTypeError("Argument " #I " must be a function"); \\n Local<Function> VAR = Local<Function>::Cast(args[I]);\n\n#define REQ_ERROR_THROW(error) if (ret == error) return ThrowError(#error);\n\n}\n#endif /* COMMON_H_ */\n" (comment) "/*\n * common.h\n *\n */" (preproc_ifdef) "#ifndef COMMON_H_\n#define COMMON_H_\n\n// OpenGL Graphics Includes\n#define GLEW_STATIC\n#include <GL/glew.h>\n\n//#define GLFW_DLL\n#include <GLFW/glfw3.h>\n\n// NodeJS includes\n#include <node.h>\n#include <nan.h>\n\nusing namespace v8;\n\nnamespace {\n#define JS_STR(...) Nan::New<v8::String>(__VA_ARGS__)\n#define JS_INT(val) v8::Integer::New(v8::Isolate::GetCurrent(), val)\n#define JS_NUM(val) v8::Number::New(v8::Isolate::GetCurrent(), val)\n#define JS_BOOL(val) v8::Boolean::New(v8::Isolate::GetCurrent(), val)\n#define JS_METHOD(name) NAN_METHOD(name)\n#define JS_RETHROW(tc) v8::Local<v8::Value>::New(tc.Exception());\n\ninline void ThrowError(const char* msg) {\n return Nan::ThrowError(msg);\n}\n\ninline void ThrowTypeError(const char* msg) {\n return Nan::ThrowTypeError(msg);\n}\n\ninline void ThrowRangeError(const char* msg) {\n return Nan::ThrowRangeError(msg);\n}\n\n#define REQ_ARGS(N) \\n if (args.Length() < (N)) \\n return ThrowTypeError("Expected " #N "arguments");\n\n#define REQ_STR_ARG(I, VAR) \\n if (args.Length() <= (I) || !args[I]->IsString()) \\n return ThrowTypeError("Argument " #I " must be a string"); \\n String::Utf8Value VAR(args[I]->ToString());\n\n#define REQ_EXT_ARG(I, VAR) \\n if (args.Length() <= (I) || !args[I]->IsExternal()) \\n return ThrowTypeError("Argument " #I " invalid"); \\n Local<External> VAR = Local<External>::Cast(args[I]);\n\n#define REQ_FUN_ARG(I, VAR) \\n if (args.Length() <= (I) || !args[I]->IsFunction()) \\n return ThrowTypeError("Argument " #I " must be a function"); \\n Local<Function> VAR = Local<Function>::Cast(args[I]);\n\n#define REQ_ERROR_THROW(error) if (ret == error) return ThrowError(#error);\n\n}\n#endif" (#ifndef) "#ifndef" (identifier) "COMMON_H_" (preproc_def) "#define COMMON_H_\n" (#define) "#define" (identifier) "COMMON_H_" (comment) "// OpenGL Graphics Includes" (preproc_def) "#define GLEW_STATIC\n" (#define) "#define" (identifier) "GLEW_STATIC" (preproc_include) "#include <GL/glew.h>\n" (#include) "#include" (system_lib_string) "<GL/glew.h>" (comment) "//#define GLFW_DLL" (preproc_include) "#include <GLFW/glfw3.h>\n" (#include) "#include" (system_lib_string) "<GLFW/glfw3.h>" (comment) "// NodeJS includes" (preproc_include) "#include <node.h>\n" (#include) "#include" (system_lib_string) "<node.h>" (preproc_include) "#include <nan.h>\n" (#include) "#include" (system_lib_string) "<nan.h>" (declaration) "using namespace v8;" (type_identifier) "using" (identifier) "namespace" (ERROR) "v8" (identifier) "v8" (;) ";" (type_identifier) "namespace" (;) "" (compound_statement) "{\n#define JS_STR(...) Nan::New<v8::String>(__VA_ARGS__)\n#define JS_INT(val) v8::Integer::New(v8::Isolate::GetCurrent(), val)\n#define JS_NUM(val) v8::Number::New(v8::Isolate::GetCurrent(), val)\n#define JS_BOOL(val) v8::Boolean::New(v8::Isolate::GetCurrent(), val)\n#define JS_METHOD(name) NAN_METHOD(name)\n#define JS_RETHROW(tc) v8::Local<v8::Value>::New(tc.Exception());\n\ninline void ThrowError(const char* msg) {\n return Nan::ThrowError(msg);\n}\n\ninline void ThrowTypeError(const char* msg) {\n return Nan::ThrowTypeError(msg);\n}\n\ninline void ThrowRangeError(const char* msg) {\n return Nan::ThrowRangeError(msg);\n}\n\n#define REQ_ARGS(N) \\n if (args.Length() < (N)) \\n return ThrowTypeError("Expected " #N "arguments");\n\n#define REQ_STR_ARG(I, VAR) \\n if (args.Length() <= (I) || !args[I]->IsString()) \\n return ThrowTypeError("Argument " #I " must be a string"); \\n String::Utf8Value VAR(args[I]->ToString());\n\n#define REQ_EXT_ARG(I, VAR) \\n if (args.Length() <= (I) || !args[I]->IsExternal()) \\n return ThrowTypeError("Argument " #I " invalid"); \\n Local<External> VAR = Local<External>::Cast(args[I]);\n\n#define REQ_FUN_ARG(I, VAR) \\n if (args.Length() <= (I) || !args[I]->IsFunction()) \\n return ThrowTypeError("Argument " #I " must be a function"); \\n Local<Function> VAR = Local<Function>::Cast(args[I]);\n\n#define REQ_ERROR_THROW(error) if (ret == error) return ThrowError(#error);\n\n}" ({) "{" (preproc_function_def) "#define JS_STR(...) Nan::New<v8::String>(__VA_ARGS__)\n" (#define) "#define" (identifier) "JS_STR" (preproc_params) "(...)" (() "(" (...) "..." ()) ")" (preproc_arg) "Nan::New<v8::String>(__VA_ARGS__)" (preproc_function_def) "#define JS_INT(val) v8::Integer::New(v8::Isolate::GetCurrent(), val)\n" (#define) "#define" (identifier) "JS_INT" (preproc_params) "(val)" (() "(" (identifier) "val" ()) ")" (preproc_arg) "v8::Integer::New(v8::Isolate::GetCurrent(), val)" (preproc_function_def) "#define JS_NUM(val) v8::Number::New(v8::Isolate::GetCurrent(), val)\n" (#define) "#define" (identifier) "JS_NUM" (preproc_params) "(val)" (() "(" (identifier) "val" ()) ")" (preproc_arg) "v8::Number::New(v8::Isolate::GetCurrent(), val)" (preproc_function_def) "#define JS_BOOL(val) v8::Boolean::New(v8::Isolate::GetCurrent(), val)\n" (#define) "#define" (identifier) "JS_BOOL" (preproc_params) "(val)" (() "(" (identifier) "val" ()) ")" (preproc_arg) "v8::Boolean::New(v8::Isolate::GetCurrent(), val)" (preproc_function_def) "#define JS_METHOD(name) NAN_METHOD(name)\n" (#define) "#define" (identifier) "JS_METHOD" (preproc_params) "(name)" (() "(" (identifier) "name" ()) ")" (preproc_arg) "NAN_METHOD(name)" (preproc_function_def) "#define JS_RETHROW(tc) v8::Local<v8::Value>::New(tc.Exception());\n" (#define) "#define" (identifier) "JS_RETHROW" (preproc_params) "(tc)" (() "(" (identifier) "tc" ()) ")" (preproc_arg) "v8::Local<v8::Value>::New(tc.Exception());" (function_definition) "inline void ThrowError(const char* msg) {\n return Nan::ThrowError(msg);\n}" (storage_class_specifier) "inline" (inline) "inline" (primitive_type) "void" (function_declarator) "ThrowError(const char* msg)" (identifier) "ThrowError" (parameter_list) "(const char* msg)" (() "(" (parameter_declaration) "const char* msg" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "* msg" (*) "*" (identifier) "msg" ()) ")" (compound_statement) "{\n return Nan::ThrowError(msg);\n}" ({) "{" (return_statement) "return Nan::ThrowError(msg);" (return) "return" (ERROR) "Nan::" (identifier) "Nan" (:) ":" (:) ":" (call_expression) "ThrowError(msg)" (identifier) "ThrowError" (argument_list) "(msg)" (() "(" (identifier) "msg" ()) ")" (;) ";" (}) "}" (function_definition) "inline void ThrowTypeError(const char* msg) {\n return Nan::ThrowTypeError(msg);\n}" (storage_class_specifier) "inline" (inline) "inline" (primitive_type) "void" (function_declarator) "ThrowTypeError(const char* msg)" (identifier) "ThrowTypeError" (parameter_list) "(const char* msg)" (() "(" (parameter_declaration) "const char* msg" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "* msg" (*) "*" (identifier) "msg" ()) ")" (compound_statement) "{\n return Nan::ThrowTypeError(msg);\n}" ({) "{" (return_statement) "return Nan::ThrowTypeError(msg);" (return) "return" (ERROR) "Nan::" (identifier) "Nan" (:) ":" (:) ":" (call_expression) "ThrowTypeError(msg)" (identifier) "ThrowTypeError" (argument_list) "(msg)" (() "(" (identifier) "msg" ()) ")" (;) ";" (}) "}" (function_definition) "inline void ThrowRangeError(const char* msg) {\n return Nan::ThrowRangeError(msg);\n}" (storage_class_specifier) "inline" (inline) "inline" (primitive_type) "void" (function_declarator) "ThrowRangeError(const char* msg)" (identifier) "ThrowRangeError" (parameter_list) "(const char* msg)" (() "(" (parameter_declaration) "const char* msg" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "* msg" (*) "*" (identifier) "msg" ()) ")" (compound_statement) "{\n return Nan::ThrowRangeError(msg);\n}" ({) "{" (return_statement) "return Nan::ThrowRangeError(msg);" (return) "return" (ERROR) "Nan::" (identifier) "Nan" (:) ":" (:) ":" (call_expression) "ThrowRangeError(msg)" (identifier) "ThrowRangeError" (argument_list) "(msg)" (() "(" (identifier) "msg" ()) ")" (;) ";" (}) "}" (preproc_function_def) "#define REQ_ARGS(N) \\n if (args.Length() < (N)) \\n return ThrowTypeError("Expected " #N "arguments");\n" (#define) "#define" (identifier) "REQ_ARGS" (preproc_params) "(N)" (() "(" (identifier) "N" ()) ")" (preproc_arg) "if (args.Length() < (N)) \\n return ThrowTypeError("Expected " #N "arguments");" (preproc_function_def) "#define REQ_STR_ARG(I, VAR) \\n if (args.Length() <= (I) || !args[I]->IsString()) \\n return ThrowTypeError("Argument " #I " must be a string"); \\n String::Utf8Value VAR(args[I]->ToString());\n" (#define) "#define" (identifier) "REQ_STR_ARG" (preproc_params) "(I, VAR)" (() "(" (identifier) "I" (,) "," (identifier) "VAR" ()) ")" (preproc_arg) "if (args.Length() <= (I) || !args[I]->IsString()) \\n return ThrowTypeError("Argument " #I " must be a string"); \\n String::Utf8Value VAR(args[I]->ToString());" (preproc_function_def) "#define REQ_EXT_ARG(I, VAR) \\n if (args.Length() <= (I) || !args[I]->IsExternal()) \\n return ThrowTypeError("Argument " #I " invalid"); \\n Local<External> VAR = Local<External>::Cast(args[I]);\n" (#define) "#define" (identifier) "REQ_EXT_ARG" (preproc_params) "(I, VAR)" (() "(" (identifier) "I" (,) "," (identifier) "VAR" ()) ")" (preproc_arg) "if (args.Length() <= (I) || !args[I]->IsExternal()) \\n return ThrowTypeError("Argument " #I " invalid"); \\n Local<External> VAR = Local<External>::Cast(args[I]);" (preproc_function_def) "#define REQ_FUN_ARG(I, VAR) \\n if (args.Length() <= (I) || !args[I]->IsFunction()) \\n return ThrowTypeError("Argument " #I " must be a function"); \\n Local<Function> VAR = Local<Function>::Cast(args[I]);\n" (#define) "#define" (identifier) "REQ_FUN_ARG" (preproc_params) "(I, VAR)" (() "(" (identifier) "I" (,) "," (identifier) "VAR" ()) ")" (preproc_arg) "if (args.Length() <= (I) || !args[I]->IsFunction()) \\n return ThrowTypeError("Argument " #I " must be a function"); \\n Local<Function> VAR = Local<Function>::Cast(args[I]);" (preproc_function_def) "#define REQ_ERROR_THROW(error) if (ret == error) return ThrowError(#error);\n" (#define) "#define" (identifier) "REQ_ERROR_THROW" (preproc_params) "(error)" (() "(" (identifier) "error" ()) ")" (preproc_arg) "if (ret == error) return ThrowError(#error);" (}) "}" (#endif) "#endif" (comment) "/* COMMON_H_ */"
229
4
{"language": "c", "success": true, "metadata": {"lines": 45, "avg_line_length": 43.02, "nodes": 153, "errors": 0, "source_hash": "0be8a2fb372848d4cbf014912bfaef396ac7dad8961c01c74faacd7a1fc41b84", "categorized_nodes": 91}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef COMMON_H_\n#define COMMON_H_\n\n// OpenGL Graphics Includes\n#define GLEW_STATIC\n#include <GL/glew.h>\n\n//#define GLFW_DLL\n#include <GLFW/glfw3.h>\n\n// NodeJS includes\n#include <node.h>\n#include <nan.h>\n\nusing namespace v8;\n\nnamespace {\n#define JS_STR(...) Nan::New<v8::String>(__VA_ARGS__)\n#define JS_INT(val) v8::Integer::New(v8::Isolate::GetCurrent(), val)\n#define JS_NUM(val) v8::Number::New(v8::Isolate::GetCurrent(), val)\n#define JS_BOOL(val) v8::Boolean::New(v8::Isolate::GetCurrent(), val)\n#define JS_METHOD(name) NAN_METHOD(name)\n#define JS_RETHROW(tc) v8::Local<v8::Value>::New(tc.Exception());\n\ninline void ThrowError(const char* msg) {\n return Nan::ThrowError(msg);\n}\n\ninline void ThrowTypeError(const char* msg) {\n return Nan::ThrowTypeError(msg);\n}\n\ninline void ThrowRangeError(const char* msg) {\n return Nan::ThrowRangeError(msg);\n}\n\n#define REQ_ARGS(N) \\\n if (args.Length() < (N)) \\\n return ThrowTypeError(\"Expected \" #N \"arguments\");\n\n#define REQ_STR_ARG(I, VAR) \\\n if (args.Length() <= (I) || !args[I]->IsString()) \\\n return ThrowTypeError(\"Argument \" #I \" must be a string\"); \\\n String::Utf8Value VAR(args[I]->ToString());\n\n#define REQ_EXT_ARG(I, VAR) \\\n if (args.Length() <= (I) || !args[I]->IsExternal()) \\\n return ThrowTypeError(\"Argument \" #I \" invalid\"); \\\n Local<External> VAR = Local<External>::Cast(args[I]);\n\n#define REQ_FUN_ARG(I, VAR) \\\n if (args.Length() <= (I) || !args[I]->IsFunction()) \\\n return ThrowTypeError(\"Argument \" #I \" must be a function\"); \\\n Local<Function> VAR = Local<Function>::Cast(args[I]);\n\n#define REQ_ERROR_THROW(error) if (ret == error) return ThrowError(#error);\n\n}\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 15, 18, 21, 26, 152], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 63, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 7}}, {"id": 2, "type": "identifier", "text": "COMMON_H_", "parent": 0, "children": [], "start_point": {"row": 5, "column": 8}, "end_point": {"row": 5, "column": 17}}, {"id": 3, "type": "preproc_def", "text": "#define COMMON_H_\n", "parent": 0, "children": [4, 5], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 7}}, {"id": 5, "type": "identifier", "text": "COMMON_H_", "parent": 3, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 17}}, {"id": 6, "type": "preproc_def", "text": "#define GLEW_STATIC\n", "parent": 0, "children": [7, 8], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 7, "type": "#define", "text": "#define", "parent": 6, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 7}}, {"id": 8, "type": "identifier", "text": "GLEW_STATIC", "parent": 6, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 19}}, {"id": 9, "type": "preproc_include", "text": "#include <GL/glew.h>\n", "parent": 0, "children": [10, 11], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 11, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<GL/glew.h>", "parent": 9, "children": [], "start_point": {"row": 10, "column": 9}, "end_point": {"row": 10, "column": 20}}, {"id": 12, "type": "preproc_include", "text": "#include <GLFW/glfw3.h>\n", "parent": 0, "children": [13, 14], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 14, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 8}}, {"id": 14, "type": "system_lib_string", "text": "<GLFW/glfw3.h>", "parent": 12, "children": [], "start_point": {"row": 13, "column": 9}, "end_point": {"row": 13, "column": 23}}, {"id": 15, "type": "preproc_include", "text": "#include <node.h>\n", "parent": 0, "children": [16, 17], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 17, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 8}}, {"id": 17, "type": "system_lib_string", "text": "<node.h>", "parent": 15, "children": [], "start_point": {"row": 16, "column": 9}, "end_point": {"row": 16, "column": 17}}, {"id": 18, "type": "preproc_include", "text": "#include <nan.h>\n", "parent": 0, "children": [19, 20], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 18, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 8}}, {"id": 20, "type": "system_lib_string", "text": "<nan.h>", "parent": 18, "children": [], "start_point": {"row": 17, "column": 9}, "end_point": {"row": 17, "column": 16}}, {"id": 21, "type": "declaration", "text": "using namespace v8;", "parent": 0, "children": [22, 23, 24], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 19}}, {"id": 22, "type": "type_identifier", "text": "using", "parent": 21, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 5}}, {"id": 23, "type": "identifier", "text": "namespace", "parent": 21, "children": [], "start_point": {"row": 19, "column": 6}, "end_point": {"row": 19, "column": 15}}, {"id": 24, "type": "ERROR", "text": "v8", "parent": 21, "children": [25], "start_point": {"row": 19, "column": 16}, "end_point": {"row": 19, "column": 18}}, {"id": 25, "type": "identifier", "text": "v8", "parent": 24, "children": [], "start_point": {"row": 19, "column": 16}, "end_point": {"row": 19, "column": 18}}, {"id": 26, "type": "type_identifier", "text": "namespace", "parent": 0, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 9}}, {"id": 27, "type": "preproc_function_def", "text": "#define JS_STR(...) Nan::New<v8::String>(__VA_ARGS__)\n", "parent": 0, "children": [28, 29, 30, 31], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 23, "column": 0}}, {"id": 28, "type": "#define", "text": "#define", "parent": 27, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 7}}, {"id": 29, "type": "identifier", "text": "JS_STR", "parent": 27, "children": [], "start_point": {"row": 22, "column": 8}, "end_point": {"row": 22, "column": 14}}, {"id": 30, "type": "preproc_params", "text": "(...)", "parent": 27, "children": [], "start_point": {"row": 22, "column": 14}, "end_point": {"row": 22, "column": 19}}, {"id": 31, "type": "preproc_arg", "text": "Nan::New<v8::String>(__VA_ARGS__)", "parent": 27, "children": [], "start_point": {"row": 22, "column": 20}, "end_point": {"row": 22, "column": 53}}, {"id": 32, "type": "preproc_function_def", "text": "#define JS_INT(val) v8::Integer::New(v8::Isolate::GetCurrent(), val)\n", "parent": 0, "children": [33, 34, 35, 37], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 24, "column": 0}}, {"id": 33, "type": "#define", "text": "#define", "parent": 32, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 7}}, {"id": 34, "type": "identifier", "text": "JS_INT", "parent": 32, "children": [], "start_point": {"row": 23, "column": 8}, "end_point": {"row": 23, "column": 14}}, {"id": 35, "type": "preproc_params", "text": "(val)", "parent": 32, "children": [36], "start_point": {"row": 23, "column": 14}, "end_point": {"row": 23, "column": 19}}, {"id": 36, "type": "identifier", "text": "val", "parent": 35, "children": [], "start_point": {"row": 23, "column": 15}, "end_point": {"row": 23, "column": 18}}, {"id": 37, "type": "preproc_arg", "text": "v8::Integer::New(v8::Isolate::GetCurrent(), val)", "parent": 32, "children": [], "start_point": {"row": 23, "column": 20}, "end_point": {"row": 23, "column": 68}}, {"id": 38, "type": "preproc_function_def", "text": "#define JS_NUM(val) v8::Number::New(v8::Isolate::GetCurrent(), val)\n", "parent": 0, "children": [39, 40, 41, 43], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 25, "column": 0}}, {"id": 39, "type": "#define", "text": "#define", "parent": 38, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 7}}, {"id": 40, "type": "identifier", "text": "JS_NUM", "parent": 38, "children": [], "start_point": {"row": 24, "column": 8}, "end_point": {"row": 24, "column": 14}}, {"id": 41, "type": "preproc_params", "text": "(val)", "parent": 38, "children": [42], "start_point": {"row": 24, "column": 14}, "end_point": {"row": 24, "column": 19}}, {"id": 42, "type": "identifier", "text": "val", "parent": 41, "children": [], "start_point": {"row": 24, "column": 15}, "end_point": {"row": 24, "column": 18}}, {"id": 43, "type": "preproc_arg", "text": "v8::Number::New(v8::Isolate::GetCurrent(), val)", "parent": 38, "children": [], "start_point": {"row": 24, "column": 20}, "end_point": {"row": 24, "column": 67}}, {"id": 44, "type": "preproc_function_def", "text": "#define JS_BOOL(val) v8::Boolean::New(v8::Isolate::GetCurrent(), val)\n", "parent": 0, "children": [45, 46, 47, 49], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 26, "column": 0}}, {"id": 45, "type": "#define", "text": "#define", "parent": 44, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 7}}, {"id": 46, "type": "identifier", "text": "JS_BOOL", "parent": 44, "children": [], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 15}}, {"id": 47, "type": "preproc_params", "text": "(val)", "parent": 44, "children": [48], "start_point": {"row": 25, "column": 15}, "end_point": {"row": 25, "column": 20}}, {"id": 48, "type": "identifier", "text": "val", "parent": 47, "children": [], "start_point": {"row": 25, "column": 16}, "end_point": {"row": 25, "column": 19}}, {"id": 49, "type": "preproc_arg", "text": "v8::Boolean::New(v8::Isolate::GetCurrent(), val)", "parent": 44, "children": [], "start_point": {"row": 25, "column": 21}, "end_point": {"row": 25, "column": 69}}, {"id": 50, "type": "preproc_function_def", "text": "#define JS_METHOD(name) NAN_METHOD(name)\n", "parent": 0, "children": [51, 52, 53, 55], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 27, "column": 0}}, {"id": 51, "type": "#define", "text": "#define", "parent": 50, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 7}}, {"id": 52, "type": "identifier", "text": "JS_METHOD", "parent": 50, "children": [], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 17}}, {"id": 53, "type": "preproc_params", "text": "(name)", "parent": 50, "children": [54], "start_point": {"row": 26, "column": 17}, "end_point": {"row": 26, "column": 23}}, {"id": 54, "type": "identifier", "text": "name", "parent": 53, "children": [], "start_point": {"row": 26, "column": 18}, "end_point": {"row": 26, "column": 22}}, {"id": 55, "type": "preproc_arg", "text": "NAN_METHOD(name)", "parent": 50, "children": [], "start_point": {"row": 26, "column": 24}, "end_point": {"row": 26, "column": 40}}, {"id": 56, "type": "preproc_function_def", "text": "#define JS_RETHROW(tc) v8::Local<v8::Value>::New(tc.Exception());\n", "parent": 0, "children": [57, 58, 59, 61], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 28, "column": 0}}, {"id": 57, "type": "#define", "text": "#define", "parent": 56, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 7}}, {"id": 58, "type": "identifier", "text": "JS_RETHROW", "parent": 56, "children": [], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 18}}, {"id": 59, "type": "preproc_params", "text": "(tc)", "parent": 56, "children": [60], "start_point": {"row": 27, "column": 18}, "end_point": {"row": 27, "column": 22}}, {"id": 60, "type": "identifier", "text": "tc", "parent": 59, "children": [], "start_point": {"row": 27, "column": 19}, "end_point": {"row": 27, "column": 21}}, {"id": 61, "type": "preproc_arg", "text": "v8::Local<v8::Value>::New(tc.Exception());", "parent": 56, "children": [], "start_point": {"row": 27, "column": 23}, "end_point": {"row": 27, "column": 65}}, {"id": 62, "type": "function_definition", "text": "inline void ThrowError(const char* msg) {\n return Nan::ThrowError(msg);\n}", "parent": 0, "children": [63, 65, 66], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 31, "column": 1}}, {"id": 63, "type": "storage_class_specifier", "text": "inline", "parent": 62, "children": [64], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 6}}, {"id": 64, "type": "inline", "text": "inline", "parent": 63, "children": [], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 6}}, {"id": 65, "type": "primitive_type", "text": "void", "parent": 62, "children": [], "start_point": {"row": 29, "column": 7}, "end_point": {"row": 29, "column": 11}}, {"id": 66, "type": "function_declarator", "text": "ThrowError(const char* msg)", "parent": 62, "children": [67, 68], "start_point": {"row": 29, "column": 12}, "end_point": {"row": 29, "column": 39}}, {"id": 67, "type": "identifier", "text": "ThrowError", "parent": 66, "children": [], "start_point": {"row": 29, "column": 12}, "end_point": {"row": 29, "column": 22}}, {"id": 68, "type": "parameter_list", "text": "(const char* msg)", "parent": 66, "children": [69], "start_point": {"row": 29, "column": 22}, "end_point": {"row": 29, "column": 39}}, {"id": 69, "type": "parameter_declaration", "text": "const char* msg", "parent": 68, "children": [70, 71], "start_point": {"row": 29, "column": 23}, "end_point": {"row": 29, "column": 38}}, {"id": 70, "type": "primitive_type", "text": "char", "parent": 69, "children": [], "start_point": {"row": 29, "column": 29}, "end_point": {"row": 29, "column": 33}}, {"id": 71, "type": "pointer_declarator", "text": "* msg", "parent": 69, "children": [72, 73], "start_point": {"row": 29, "column": 33}, "end_point": {"row": 29, "column": 38}}, {"id": 72, "type": "*", "text": "*", "parent": 71, "children": [], "start_point": {"row": 29, "column": 33}, "end_point": {"row": 29, "column": 34}}, {"id": 73, "type": "identifier", "text": "msg", "parent": 71, "children": [], "start_point": {"row": 29, "column": 35}, "end_point": {"row": 29, "column": 38}}, {"id": 74, "type": "return_statement", "text": "return Nan::ThrowError(msg);", "parent": 62, "children": [75, 77], "start_point": {"row": 30, "column": 2}, "end_point": {"row": 30, "column": 30}}, {"id": 75, "type": "ERROR", "text": "Nan::", "parent": 74, "children": [76], "start_point": {"row": 30, "column": 9}, "end_point": {"row": 30, "column": 14}}, {"id": 76, "type": "identifier", "text": "Nan", "parent": 75, "children": [], "start_point": {"row": 30, "column": 9}, "end_point": {"row": 30, "column": 12}}, {"id": 77, "type": "call_expression", "text": "ThrowError(msg)", "parent": 74, "children": [78, 79], "start_point": {"row": 30, "column": 14}, "end_point": {"row": 30, "column": 29}}, {"id": 78, "type": "identifier", "text": "ThrowError", "parent": 77, "children": [], "start_point": {"row": 30, "column": 14}, "end_point": {"row": 30, "column": 24}}, {"id": 79, "type": "argument_list", "text": "(msg)", "parent": 77, "children": [80], "start_point": {"row": 30, "column": 24}, "end_point": {"row": 30, "column": 29}}, {"id": 80, "type": "identifier", "text": "msg", "parent": 79, "children": [], "start_point": {"row": 30, "column": 25}, "end_point": {"row": 30, "column": 28}}, {"id": 81, "type": "function_definition", "text": "inline void ThrowTypeError(const char* msg) {\n return Nan::ThrowTypeError(msg);\n}", "parent": 0, "children": [82, 84, 85], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 35, "column": 1}}, {"id": 82, "type": "storage_class_specifier", "text": "inline", "parent": 81, "children": [83], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 33, "column": 6}}, {"id": 83, "type": "inline", "text": "inline", "parent": 82, "children": [], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 33, "column": 6}}, {"id": 84, "type": "primitive_type", "text": "void", "parent": 81, "children": [], "start_point": {"row": 33, "column": 7}, "end_point": {"row": 33, "column": 11}}, {"id": 85, "type": "function_declarator", "text": "ThrowTypeError(const char* msg)", "parent": 81, "children": [86, 87], "start_point": {"row": 33, "column": 12}, "end_point": {"row": 33, "column": 43}}, {"id": 86, "type": "identifier", "text": "ThrowTypeError", "parent": 85, "children": [], "start_point": {"row": 33, "column": 12}, "end_point": {"row": 33, "column": 26}}, {"id": 87, "type": "parameter_list", "text": "(const char* msg)", "parent": 85, "children": [88], "start_point": {"row": 33, "column": 26}, "end_point": {"row": 33, "column": 43}}, {"id": 88, "type": "parameter_declaration", "text": "const char* msg", "parent": 87, "children": [89, 90], "start_point": {"row": 33, "column": 27}, "end_point": {"row": 33, "column": 42}}, {"id": 89, "type": "primitive_type", "text": "char", "parent": 88, "children": [], "start_point": {"row": 33, "column": 33}, "end_point": {"row": 33, "column": 37}}, {"id": 90, "type": "pointer_declarator", "text": "* msg", "parent": 88, "children": [91, 92], "start_point": {"row": 33, "column": 37}, "end_point": {"row": 33, "column": 42}}, {"id": 91, "type": "*", "text": "*", "parent": 90, "children": [], "start_point": {"row": 33, "column": 37}, "end_point": {"row": 33, "column": 38}}, {"id": 92, "type": "identifier", "text": "msg", "parent": 90, "children": [], "start_point": {"row": 33, "column": 39}, "end_point": {"row": 33, "column": 42}}, {"id": 93, "type": "return_statement", "text": "return Nan::ThrowTypeError(msg);", "parent": 81, "children": [94, 96], "start_point": {"row": 34, "column": 2}, "end_point": {"row": 34, "column": 34}}, {"id": 94, "type": "ERROR", "text": "Nan::", "parent": 93, "children": [95], "start_point": {"row": 34, "column": 9}, "end_point": {"row": 34, "column": 14}}, {"id": 95, "type": "identifier", "text": "Nan", "parent": 94, "children": [], "start_point": {"row": 34, "column": 9}, "end_point": {"row": 34, "column": 12}}, {"id": 96, "type": "call_expression", "text": "ThrowTypeError(msg)", "parent": 93, "children": [97, 98], "start_point": {"row": 34, "column": 14}, "end_point": {"row": 34, "column": 33}}, {"id": 97, "type": "identifier", "text": "ThrowTypeError", "parent": 96, "children": [], "start_point": {"row": 34, "column": 14}, "end_point": {"row": 34, "column": 28}}, {"id": 98, "type": "argument_list", "text": "(msg)", "parent": 96, "children": [99], "start_point": {"row": 34, "column": 28}, "end_point": {"row": 34, "column": 33}}, {"id": 99, "type": "identifier", "text": "msg", "parent": 98, "children": [], "start_point": {"row": 34, "column": 29}, "end_point": {"row": 34, "column": 32}}, {"id": 100, "type": "function_definition", "text": "inline void ThrowRangeError(const char* msg) {\n return Nan::ThrowRangeError(msg);\n}", "parent": 0, "children": [101, 103, 104], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 39, "column": 1}}, {"id": 101, "type": "storage_class_specifier", "text": "inline", "parent": 100, "children": [102], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 37, "column": 6}}, {"id": 102, "type": "inline", "text": "inline", "parent": 101, "children": [], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 37, "column": 6}}, {"id": 103, "type": "primitive_type", "text": "void", "parent": 100, "children": [], "start_point": {"row": 37, "column": 7}, "end_point": {"row": 37, "column": 11}}, {"id": 104, "type": "function_declarator", "text": "ThrowRangeError(const char* msg)", "parent": 100, "children": [105, 106], "start_point": {"row": 37, "column": 12}, "end_point": {"row": 37, "column": 44}}, {"id": 105, "type": "identifier", "text": "ThrowRangeError", "parent": 104, "children": [], "start_point": {"row": 37, "column": 12}, "end_point": {"row": 37, "column": 27}}, {"id": 106, "type": "parameter_list", "text": "(const char* msg)", "parent": 104, "children": [107], "start_point": {"row": 37, "column": 27}, "end_point": {"row": 37, "column": 44}}, {"id": 107, "type": "parameter_declaration", "text": "const char* msg", "parent": 106, "children": [108, 109], "start_point": {"row": 37, "column": 28}, "end_point": {"row": 37, "column": 43}}, {"id": 108, "type": "primitive_type", "text": "char", "parent": 107, "children": [], "start_point": {"row": 37, "column": 34}, "end_point": {"row": 37, "column": 38}}, {"id": 109, "type": "pointer_declarator", "text": "* msg", "parent": 107, "children": [110, 111], "start_point": {"row": 37, "column": 38}, "end_point": {"row": 37, "column": 43}}, {"id": 110, "type": "*", "text": "*", "parent": 109, "children": [], "start_point": {"row": 37, "column": 38}, "end_point": {"row": 37, "column": 39}}, {"id": 111, "type": "identifier", "text": "msg", "parent": 109, "children": [], "start_point": {"row": 37, "column": 40}, "end_point": {"row": 37, "column": 43}}, {"id": 112, "type": "return_statement", "text": "return Nan::ThrowRangeError(msg);", "parent": 100, "children": [113, 115], "start_point": {"row": 38, "column": 2}, "end_point": {"row": 38, "column": 35}}, {"id": 113, "type": "ERROR", "text": "Nan::", "parent": 112, "children": [114], "start_point": {"row": 38, "column": 9}, "end_point": {"row": 38, "column": 14}}, {"id": 114, "type": "identifier", "text": "Nan", "parent": 113, "children": [], "start_point": {"row": 38, "column": 9}, "end_point": {"row": 38, "column": 12}}, {"id": 115, "type": "call_expression", "text": "ThrowRangeError(msg)", "parent": 112, "children": [116, 117], "start_point": {"row": 38, "column": 14}, "end_point": {"row": 38, "column": 34}}, {"id": 116, "type": "identifier", "text": "ThrowRangeError", "parent": 115, "children": [], "start_point": {"row": 38, "column": 14}, "end_point": {"row": 38, "column": 29}}, {"id": 117, "type": "argument_list", "text": "(msg)", "parent": 115, "children": [118], "start_point": {"row": 38, "column": 29}, "end_point": {"row": 38, "column": 34}}, {"id": 118, "type": "identifier", "text": "msg", "parent": 117, "children": [], "start_point": {"row": 38, "column": 30}, "end_point": {"row": 38, "column": 33}}, {"id": 119, "type": "preproc_function_def", "text": "#define REQ_ARGS(N) \\\n if (args.Length() < (N)) \\\n return ThrowTypeError(\"Expected \" #N \"arguments\");\n", "parent": 0, "children": [120, 121, 122, 124], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 44, "column": 0}}, {"id": 120, "type": "#define", "text": "#define", "parent": 119, "children": [], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 41, "column": 7}}, {"id": 121, "type": "identifier", "text": "REQ_ARGS", "parent": 119, "children": [], "start_point": {"row": 41, "column": 8}, "end_point": {"row": 41, "column": 16}}, {"id": 122, "type": "preproc_params", "text": "(N)", "parent": 119, "children": [123], "start_point": {"row": 41, "column": 16}, "end_point": {"row": 41, "column": 19}}, {"id": 123, "type": "identifier", "text": "N", "parent": 122, "children": [], "start_point": {"row": 41, "column": 17}, "end_point": {"row": 41, "column": 18}}, {"id": 124, "type": "preproc_arg", "text": "if (args.Length() < (N)) \\\n return ThrowTypeError(\"Expected \" #N \"arguments\");", "parent": 119, "children": [], "start_point": {"row": 42, "column": 2}, "end_point": {"row": 43, "column": 54}}, {"id": 125, "type": "preproc_function_def", "text": "#define REQ_STR_ARG(I, VAR) \\\n if (args.Length() <= (I) || !args[I]->IsString()) \\\n return ThrowTypeError(\"Argument \" #I \" must be a string\"); \\\n String::Utf8Value VAR(args[I]->ToString());\n", "parent": 0, "children": [126, 127, 128, 131], "start_point": {"row": 45, "column": 0}, "end_point": {"row": 49, "column": 0}}, {"id": 126, "type": "#define", "text": "#define", "parent": 125, "children": [], "start_point": {"row": 45, "column": 0}, "end_point": {"row": 45, "column": 7}}, {"id": 127, "type": "identifier", "text": "REQ_STR_ARG", "parent": 125, "children": [], "start_point": {"row": 45, "column": 8}, "end_point": {"row": 45, "column": 19}}, {"id": 128, "type": "preproc_params", "text": "(I, VAR)", "parent": 125, "children": [129, 130], "start_point": {"row": 45, "column": 19}, "end_point": {"row": 45, "column": 27}}, {"id": 129, "type": "identifier", "text": "I", "parent": 128, "children": [], "start_point": {"row": 45, "column": 20}, "end_point": {"row": 45, "column": 21}}, {"id": 130, "type": "identifier", "text": "VAR", "parent": 128, "children": [], "start_point": {"row": 45, "column": 23}, "end_point": {"row": 45, "column": 26}}, {"id": 131, "type": "preproc_arg", "text": "if (args.Length() <= (I) || !args[I]->IsString()) \\\n return ThrowTypeError(\"Argument \" #I \" must be a string\"); \\\n String::Utf8Value VAR(args[I]->ToString());", "parent": 125, "children": [], "start_point": {"row": 46, "column": 2}, "end_point": {"row": 48, "column": 45}}, {"id": 132, "type": "preproc_function_def", "text": "#define REQ_EXT_ARG(I, VAR) \\\n if (args.Length() <= (I) || !args[I]->IsExternal()) \\\n return ThrowTypeError(\"Argument \" #I \" invalid\"); \\\n Local<External> VAR = Local<External>::Cast(args[I]);\n", "parent": 0, "children": [133, 134, 135, 138], "start_point": {"row": 50, "column": 0}, "end_point": {"row": 54, "column": 0}}, {"id": 133, "type": "#define", "text": "#define", "parent": 132, "children": [], "start_point": {"row": 50, "column": 0}, "end_point": {"row": 50, "column": 7}}, {"id": 134, "type": "identifier", "text": "REQ_EXT_ARG", "parent": 132, "children": [], "start_point": {"row": 50, "column": 8}, "end_point": {"row": 50, "column": 19}}, {"id": 135, "type": "preproc_params", "text": "(I, VAR)", "parent": 132, "children": [136, 137], "start_point": {"row": 50, "column": 19}, "end_point": {"row": 50, "column": 27}}, {"id": 136, "type": "identifier", "text": "I", "parent": 135, "children": [], "start_point": {"row": 50, "column": 20}, "end_point": {"row": 50, "column": 21}}, {"id": 137, "type": "identifier", "text": "VAR", "parent": 135, "children": [], "start_point": {"row": 50, "column": 23}, "end_point": {"row": 50, "column": 26}}, {"id": 138, "type": "preproc_arg", "text": "if (args.Length() <= (I) || !args[I]->IsExternal()) \\\n return ThrowTypeError(\"Argument \" #I \" invalid\"); \\\n Local<External> VAR = Local<External>::Cast(args[I]);", "parent": 132, "children": [], "start_point": {"row": 51, "column": 2}, "end_point": {"row": 53, "column": 55}}, {"id": 139, "type": "preproc_function_def", "text": "#define REQ_FUN_ARG(I, VAR) \\\n if (args.Length() <= (I) || !args[I]->IsFunction()) \\\n return ThrowTypeError(\"Argument \" #I \" must be a function\"); \\\n Local<Function> VAR = Local<Function>::Cast(args[I]);\n", "parent": 0, "children": [140, 141, 142, 145], "start_point": {"row": 55, "column": 0}, "end_point": {"row": 59, "column": 0}}, {"id": 140, "type": "#define", "text": "#define", "parent": 139, "children": [], "start_point": {"row": 55, "column": 0}, "end_point": {"row": 55, "column": 7}}, {"id": 141, "type": "identifier", "text": "REQ_FUN_ARG", "parent": 139, "children": [], "start_point": {"row": 55, "column": 8}, "end_point": {"row": 55, "column": 19}}, {"id": 142, "type": "preproc_params", "text": "(I, VAR)", "parent": 139, "children": [143, 144], "start_point": {"row": 55, "column": 19}, "end_point": {"row": 55, "column": 27}}, {"id": 143, "type": "identifier", "text": "I", "parent": 142, "children": [], "start_point": {"row": 55, "column": 20}, "end_point": {"row": 55, "column": 21}}, {"id": 144, "type": "identifier", "text": "VAR", "parent": 142, "children": [], "start_point": {"row": 55, "column": 23}, "end_point": {"row": 55, "column": 26}}, {"id": 145, "type": "preproc_arg", "text": "if (args.Length() <= (I) || !args[I]->IsFunction()) \\\n return ThrowTypeError(\"Argument \" #I \" must be a function\"); \\\n Local<Function> VAR = Local<Function>::Cast(args[I]);", "parent": 139, "children": [], "start_point": {"row": 56, "column": 2}, "end_point": {"row": 58, "column": 55}}, {"id": 146, "type": "preproc_function_def", "text": "#define REQ_ERROR_THROW(error) if (ret == error) return ThrowError(#error);\n", "parent": 0, "children": [147, 148, 149, 151], "start_point": {"row": 60, "column": 0}, "end_point": {"row": 61, "column": 0}}, {"id": 147, "type": "#define", "text": "#define", "parent": 146, "children": [], "start_point": {"row": 60, "column": 0}, "end_point": {"row": 60, "column": 7}}, {"id": 148, "type": "identifier", "text": "REQ_ERROR_THROW", "parent": 146, "children": [], "start_point": {"row": 60, "column": 8}, "end_point": {"row": 60, "column": 23}}, {"id": 149, "type": "preproc_params", "text": "(error)", "parent": 146, "children": [150], "start_point": {"row": 60, "column": 23}, "end_point": {"row": 60, "column": 30}}, {"id": 150, "type": "identifier", "text": "error", "parent": 149, "children": [], "start_point": {"row": 60, "column": 24}, "end_point": {"row": 60, "column": 29}}, {"id": 151, "type": "preproc_arg", "text": "if (ret == error) return ThrowError(#error);", "parent": 146, "children": [], "start_point": {"row": 60, "column": 31}, "end_point": {"row": 60, "column": 75}}, {"id": 152, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 63, "column": 0}, "end_point": {"row": 63, "column": 6}}]}, "node_categories": {"declarations": {"functions": [27, 32, 38, 44, 50, 56, 62, 66, 81, 85, 100, 104, 119, 125, 132, 139, 146], "variables": [21, 69, 88, 107], "classes": [63, 82, 101], "imports": [9, 10, 12, 13, 15, 16, 18, 19], "modules": [], "enums": []}, "statements": {"expressions": [77, 96, 115], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 8, 22, 23, 25, 26, 29, 34, 36, 40, 42, 46, 48, 52, 54, 58, 60, 67, 73, 76, 78, 80, 86, 92, 95, 97, 99, 105, 111, 114, 116, 118, 121, 123, 127, 129, 130, 134, 136, 137, 141, 143, 144, 148, 150, 152], "returns": [74, 93, 112], "exceptions": []}, "expressions": {"calls": [], "literals": [11, 14, 17, 20], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 27, "universal_type": "function", "name": "unknown", "text_snippet": "#define JS_STR(...) Nan::New<v8::String>(__VA_ARGS__)\n"}, {"node_id": 32, "universal_type": "function", "name": "unknown", "text_snippet": "#define JS_INT(val) v8::Integer::New(v8::Isolate::GetCurrent(), val)\n"}, {"node_id": 38, "universal_type": "function", "name": "unknown", "text_snippet": "#define JS_NUM(val) v8::Number::New(v8::Isolate::GetCurrent(), val)\n"}, {"node_id": 44, "universal_type": "function", "name": "unknown", "text_snippet": "#define JS_BOOL(val) v8::Boolean::New(v8::Isolate::GetCurrent(), val)\n"}, {"node_id": 50, "universal_type": "function", "name": "unknown", "text_snippet": "#define JS_METHOD(name) NAN_METHOD(name)\n"}, {"node_id": 56, "universal_type": "function", "name": "unknown", "text_snippet": "#define JS_RETHROW(tc) v8::Local<v8::Value>::New(tc.Exception());\n"}, {"node_id": 62, "universal_type": "function", "name": "ThrowError", "text_snippet": "inline void ThrowError(const char* msg) {\n return Nan::ThrowError(msg);\n}"}, {"node_id": 66, "universal_type": "function", "name": "unknown", "text_snippet": "ThrowError(const char* msg)"}, {"node_id": 81, "universal_type": "function", "name": "ThrowTypeError", "text_snippet": "inline void ThrowTypeError(const char* msg) {\n return Nan::ThrowTypeError(msg);\n}"}, {"node_id": 85, "universal_type": "function", "name": "unknown", "text_snippet": "ThrowTypeError(const char* msg)"}, {"node_id": 100, "universal_type": "function", "name": "ThrowRangeError", "text_snippet": "inline void ThrowRangeError(const char* msg) {\n return Nan::ThrowRangeError(msg);\n}"}, {"node_id": 104, "universal_type": "function", "name": "unknown", "text_snippet": "ThrowRangeError(const char* msg)"}, {"node_id": 119, "universal_type": "function", "name": "unknown", "text_snippet": "#define REQ_ARGS(N) \\\n if (args.Length() < (N))"}, {"node_id": 125, "universal_type": "function", "name": "unknown", "text_snippet": "#define REQ_STR_ARG(I, VAR) \\\n if (args.Length() <= (I)"}, {"node_id": 132, "universal_type": "function", "name": "unknown", "text_snippet": "#define REQ_EXT_ARG(I, VAR) \\\n if (args.Length() <= (I)"}, {"node_id": 139, "universal_type": "function", "name": "unknown", "text_snippet": "#define REQ_FUN_ARG(I, VAR) \\\n if (args.Length() <= (I)"}, {"node_id": 146, "universal_type": "function", "name": "unknown", "text_snippet": "#define REQ_ERROR_THROW(error) if (ret == error) return ThrowError(#error);\n"}], "class_declarations": [{"node_id": 63, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}, {"node_id": 82, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}, {"node_id": 101, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}], "import_statements": [{"node_id": 9, "text": "#include <GL/glew.h>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include <GLFW/glfw3.h>\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include <node.h>\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include <nan.h>\n"}, {"node_id": 19, "text": "#include"}]}, "original_source_code": "/*\n * common.h\n *\n */\n\n#ifndef COMMON_H_\n#define COMMON_H_\n\n// OpenGL Graphics Includes\n#define GLEW_STATIC\n#include <GL/glew.h>\n\n//#define GLFW_DLL\n#include <GLFW/glfw3.h>\n\n// NodeJS includes\n#include <node.h>\n#include <nan.h>\n\nusing namespace v8;\n\nnamespace {\n#define JS_STR(...) Nan::New<v8::String>(__VA_ARGS__)\n#define JS_INT(val) v8::Integer::New(v8::Isolate::GetCurrent(), val)\n#define JS_NUM(val) v8::Number::New(v8::Isolate::GetCurrent(), val)\n#define JS_BOOL(val) v8::Boolean::New(v8::Isolate::GetCurrent(), val)\n#define JS_METHOD(name) NAN_METHOD(name)\n#define JS_RETHROW(tc) v8::Local<v8::Value>::New(tc.Exception());\n\ninline void ThrowError(const char* msg) {\n return Nan::ThrowError(msg);\n}\n\ninline void ThrowTypeError(const char* msg) {\n return Nan::ThrowTypeError(msg);\n}\n\ninline void ThrowRangeError(const char* msg) {\n return Nan::ThrowRangeError(msg);\n}\n\n#define REQ_ARGS(N) \\\n if (args.Length() < (N)) \\\n return ThrowTypeError(\"Expected \" #N \"arguments\");\n\n#define REQ_STR_ARG(I, VAR) \\\n if (args.Length() <= (I) || !args[I]->IsString()) \\\n return ThrowTypeError(\"Argument \" #I \" must be a string\"); \\\n String::Utf8Value VAR(args[I]->ToString());\n\n#define REQ_EXT_ARG(I, VAR) \\\n if (args.Length() <= (I) || !args[I]->IsExternal()) \\\n return ThrowTypeError(\"Argument \" #I \" invalid\"); \\\n Local<External> VAR = Local<External>::Cast(args[I]);\n\n#define REQ_FUN_ARG(I, VAR) \\\n if (args.Length() <= (I) || !args[I]->IsFunction()) \\\n return ThrowTypeError(\"Argument \" #I \" must be a function\"); \\\n Local<Function> VAR = Local<Function>::Cast(args[I]);\n\n#define REQ_ERROR_THROW(error) if (ret == error) return ThrowError(#error);\n\n}\n#endif /* COMMON_H_ */\n"}
80,501
c
#ifndef PROJECT_HEADER_component399_8_H #define PROJECT_HEADER_component399_8_H int component399_8(); #endif // PROJECT_HEADER_component399_8_H
28
5
(translation_unit) "#ifndef PROJECT_HEADER_component399_8_H\n#define PROJECT_HEADER_component399_8_H\n\n\n\nint component399_8();\n\n#endif // PROJECT_HEADER_component399_8_H" (preproc_ifdef) "#ifndef PROJECT_HEADER_component399_8_H\n#define PROJECT_HEADER_component399_8_H\n\n\n\nint component399_8();\n\n#endif" (#ifndef) "#ifndef" (identifier) "PROJECT_HEADER_component399_8_H" (preproc_def) "#define PROJECT_HEADER_component399_8_H\n" (#define) "#define" (identifier) "PROJECT_HEADER_component399_8_H" (declaration) "int component399_8();" (primitive_type) "int" (function_declarator) "component399_8()" (identifier) "component399_8" (parameter_list) "()" (() "(" ()) ")" (;) ";" (#endif) "#endif" (comment) "// PROJECT_HEADER_component399_8_H"
17
0
{"language": "c", "success": true, "metadata": {"lines": 5, "avg_line_length": 28.0, "nodes": 12, "errors": 0, "source_hash": "e7c28005c32e6f205d1b532b327de1f6fef67d8a3d30536be8b0675d7a119ee9", "categorized_nodes": 8}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef PROJECT_HEADER_component399_8_H\n#define PROJECT_HEADER_component399_8_H\n\n\n\nint component399_8();\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 11], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 7, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "identifier", "text": "PROJECT_HEADER_component399_8_H", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 39}}, {"id": 3, "type": "preproc_def", "text": "#define PROJECT_HEADER_component399_8_H\n", "parent": 0, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 5, "type": "identifier", "text": "PROJECT_HEADER_component399_8_H", "parent": 3, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 39}}, {"id": 6, "type": "declaration", "text": "int component399_8();", "parent": 0, "children": [7, 8], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 21}}, {"id": 7, "type": "primitive_type", "text": "int", "parent": 6, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 3}}, {"id": 8, "type": "function_declarator", "text": "component399_8()", "parent": 6, "children": [9, 10], "start_point": {"row": 5, "column": 4}, "end_point": {"row": 5, "column": 20}}, {"id": 9, "type": "identifier", "text": "component399_8", "parent": 8, "children": [], "start_point": {"row": 5, "column": 4}, "end_point": {"row": 5, "column": 18}}, {"id": 10, "type": "parameter_list", "text": "()", "parent": 8, "children": [], "start_point": {"row": 5, "column": 18}, "end_point": {"row": 5, "column": 20}}, {"id": 11, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 6}}]}, "node_categories": {"declarations": {"functions": [8], "variables": [6], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 9, 11], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 8, "universal_type": "function", "name": "unknown", "text_snippet": "component399_8()"}], "class_declarations": [], "import_statements": []}, "original_source_code": "#ifndef PROJECT_HEADER_component399_8_H\n#define PROJECT_HEADER_component399_8_H\n\n\n\nint component399_8();\n\n#endif // PROJECT_HEADER_component399_8_H"}
80,502
c
/* * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ #import <UIKit/UIKit.h> #import <ABI41_0_0RCTImageManagerProtocol.h> NS_ASSUME_NONNULL_BEGIN @protocol ABI41_0_0RCTImageLoaderWithAttributionProtocol; /** * iOS-specific ImageManager. */ @interface ABI41_0_0RCTSyncImageManager : NSObject <ABI41_0_0RCTImageManagerProtocol> - (instancetype)initWithImageLoader:(id<ABI41_0_0RCTImageLoaderWithAttributionProtocol>)imageLoader; - (ABI41_0_0facebook::ABI41_0_0React::ImageRequest)requestImage:(ABI41_0_0facebook::ABI41_0_0React::ImageSource)imageSource surfaceId:(ABI41_0_0facebook::ABI41_0_0React::SurfaceId)surfaceId; @end NS_ASSUME_NONNULL_END
42.05
19
(translation_unit) "/*\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n#import <UIKit/UIKit.h>\n\n#import <ABI41_0_0RCTImageManagerProtocol.h>\n\nNS_ASSUME_NONNULL_BEGIN\n\n@protocol ABI41_0_0RCTImageLoaderWithAttributionProtocol;\n\n/**\n * iOS-specific ImageManager.\n */\n@interface ABI41_0_0RCTSyncImageManager : NSObject <ABI41_0_0RCTImageManagerProtocol>\n\n- (instancetype)initWithImageLoader:(id<ABI41_0_0RCTImageLoaderWithAttributionProtocol>)imageLoader;\n\n- (ABI41_0_0facebook::ABI41_0_0React::ImageRequest)requestImage:(ABI41_0_0facebook::ABI41_0_0React::ImageSource)imageSource\n surfaceId:(ABI41_0_0facebook::ABI41_0_0React::SurfaceId)surfaceId;\n\n@end\n\nNS_ASSUME_NONNULL_END\n" (comment) "/*\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */" (preproc_call) "#import <UIKit/UIKit.h>\n" (preproc_directive) "#import" (preproc_arg) "<UIKit/UIKit.h>" (preproc_call) "#import <ABI41_0_0RCTImageManagerProtocol.h>\n" (preproc_directive) "#import" (preproc_arg) "<ABI41_0_0RCTImageManagerProtocol.h>" (declaration) "NS_ASSUME_NONNULL_BEGIN\n\n@protocol ABI41_0_0RCTImageLoaderWithAttributionProtocol;" (type_identifier) "NS_ASSUME_NONNULL_BEGIN" (ERROR) "@protocol" (ERROR) "@" (identifier) "protocol" (identifier) "ABI41_0_0RCTImageLoaderWithAttributionProtocol" (;) ";" (comment) "/**\n * iOS-specific ImageManager.\n */" (ERROR) "@interface ABI41_0_0RCTSyncImageManager : NSObject <ABI41_0_0RCTImageManagerProtocol>\n\n- (instancetype)initWithImageLoader:(id<ABI41_0_0RCTImageLoaderWithAttributionProtocol>)imageLoader" (ERROR) "@" (type_identifier) "interface" (ERROR) "ABI41_0_0RCTSyncImageManager : NSObject <" (identifier) "ABI41_0_0RCTSyncImageManager" (:) ":" (identifier) "NSObject" (<) "<" (identifier) "ABI41_0_0RCTImageManagerProtocol" (>) ">" (unary_expression) "- (instancetype)initWithImageLoader" (-) "-" (cast_expression) "(instancetype)initWithImageLoader" (() "(" (type_descriptor) "instancetype" (type_identifier) "instancetype" ()) ")" (identifier) "initWithImageLoader" (:) ":" (() "(" (binary_expression) "id<ABI41_0_0RCTImageLoaderWithAttributionProtocol>)imageLoader" (binary_expression) "id<ABI41_0_0RCTImageLoaderWithAttributionProtocol" (identifier) "id" (<) "<" (identifier) "ABI41_0_0RCTImageLoaderWithAttributionProtocol" (>) ">" (ERROR) ")" ()) ")" (identifier) "imageLoader" (expression_statement) ";" (;) ";" (ERROR) "- (ABI41_0_0facebook::ABI41_0_0React::ImageRequest)requestImage:(" (unary_expression) "- (ABI41_0_0facebook::ABI41_0_0React::ImageRequest)requestImage" (-) "-" (cast_expression) "(ABI41_0_0facebook::ABI41_0_0React::ImageRequest)requestImage" (() "(" (type_descriptor) "ABI41_0_0facebook" (type_identifier) "ABI41_0_0facebook" (ERROR) "::ABI41_0_0React::ImageRequest" (:) ":" (:) ":" (identifier) "ABI41_0_0React" (:) ":" (:) ":" (identifier) "ImageRequest" ()) ")" (identifier) "requestImage" (:) ":" (() "(" (labeled_statement) "ABI41_0_0facebook::ABI41_0_0React::ImageSource)imageSource\n surfaceId:(ABI41_0_0facebook::ABI41_0_0React::SurfaceId)surfaceId;" (statement_identifier) "ABI41_0_0facebook" (:) ":" (ERROR) ":" (:) ":" (labeled_statement) "ABI41_0_0React::ImageSource)imageSource\n surfaceId:(ABI41_0_0facebook::ABI41_0_0React::SurfaceId)surfaceId;" (statement_identifier) "ABI41_0_0React" (ERROR) "::ImageSource)imageSource\n surfaceId" (:) ":" (:) ":" (type_identifier) "ImageSource" (ERROR) ")" ()) ")" (identifier) "imageSource" (identifier) "surfaceId" (:) ":" (expression_statement) "(ABI41_0_0facebook::ABI41_0_0React::SurfaceId)surfaceId;" (cast_expression) "(ABI41_0_0facebook::ABI41_0_0React::SurfaceId)surfaceId" (() "(" (type_descriptor) "ABI41_0_0facebook" (type_identifier) "ABI41_0_0facebook" (ERROR) "::ABI41_0_0React::SurfaceId" (:) ":" (:) ":" (identifier) "ABI41_0_0React" (:) ":" (:) ":" (identifier) "SurfaceId" ()) ")" (identifier) "surfaceId" (;) ";" (ERROR) "@" (ERROR) "@" (declaration) "end\n\nNS_ASSUME_NONNULL_END" (type_identifier) "end" (identifier) "NS_ASSUME_NONNULL_END" (;) ""
102
14
{"language": "c", "success": true, "metadata": {"lines": 19, "avg_line_length": 42.05, "nodes": 63, "errors": 0, "source_hash": "45765631aa0efe30b5c802f9a89cdcd2a555d19542c3b0c0e7fab31fcd0de51d", "categorized_nodes": 37}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#import <UIKit/UIKit.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#import", "parent": 0, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "<UIKit/UIKit.h>", "parent": 0, "children": [], "start_point": {"row": 7, "column": 8}, "end_point": {"row": 7, "column": 23}}, {"id": 3, "type": "preproc_call", "text": "#import <ABI41_0_0RCTImageManagerProtocol.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 4, "type": "preproc_directive", "text": "#import", "parent": 3, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 7}}, {"id": 5, "type": "preproc_arg", "text": "<ABI41_0_0RCTImageManagerProtocol.h>", "parent": 3, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 44}}, {"id": 6, "type": "declaration", "text": "NS_ASSUME_NONNULL_BEGIN\n\n@protocol ABI41_0_0RCTImageLoaderWithAttributionProtocol;", "parent": null, "children": [7, 8, 11], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 13, "column": 57}}, {"id": 7, "type": "type_identifier", "text": "NS_ASSUME_NONNULL_BEGIN", "parent": 6, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 23}}, {"id": 8, "type": "ERROR", "text": "@protocol", "parent": 6, "children": [9, 10], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 9}}, {"id": 9, "type": "ERROR", "text": "@", "parent": 8, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 10, "type": "identifier", "text": "protocol", "parent": 8, "children": [], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 9}}, {"id": 11, "type": "identifier", "text": "ABI41_0_0RCTImageLoaderWithAttributionProtocol", "parent": 6, "children": [], "start_point": {"row": 13, "column": 10}, "end_point": {"row": 13, "column": 56}}, {"id": 12, "type": "ERROR", "text": "@interface ABI41_0_0RCTSyncImageManager : NSObject <ABI41_0_0RCTImageManagerProtocol>\n\n- (instancetype)initWithImageLoader:(id<ABI41_0_0RCTImageLoaderWithAttributionProtocol>)imageLoader", "parent": null, "children": [13, 14, 15, 19, 20, 21, 27], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 20, "column": 99}}, {"id": 13, "type": "ERROR", "text": "@", "parent": 12, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 1}}, {"id": 14, "type": "type_identifier", "text": "interface", "parent": 12, "children": [], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 10}}, {"id": 15, "type": "ERROR", "text": "ABI41_0_0RCTSyncImageManager : NSObject <", "parent": 12, "children": [16, 17, 18], "start_point": {"row": 18, "column": 11}, "end_point": {"row": 18, "column": 52}}, {"id": 16, "type": "identifier", "text": "ABI41_0_0RCTSyncImageManager", "parent": 15, "children": [], "start_point": {"row": 18, "column": 11}, "end_point": {"row": 18, "column": 39}}, {"id": 17, "type": "identifier", "text": "NSObject", "parent": 15, "children": [], "start_point": {"row": 18, "column": 42}, "end_point": {"row": 18, "column": 50}}, {"id": 18, "type": "<", "text": "<", "parent": 15, "children": [], "start_point": {"row": 18, "column": 51}, "end_point": {"row": 18, "column": 52}}, {"id": 19, "type": "identifier", "text": "ABI41_0_0RCTImageManagerProtocol", "parent": 12, "children": [], "start_point": {"row": 18, "column": 52}, "end_point": {"row": 18, "column": 84}}, {"id": 20, "type": ">", "text": ">", "parent": 12, "children": [], "start_point": {"row": 18, "column": 84}, "end_point": {"row": 18, "column": 85}}, {"id": 21, "type": "unary_expression", "text": "- (instancetype)initWithImageLoader", "parent": 12, "children": [22, 23], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 35}}, {"id": 22, "type": "-", "text": "-", "parent": 21, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 1}}, {"id": 23, "type": "cast_expression", "text": "(instancetype)initWithImageLoader", "parent": 21, "children": [24, 26], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 35}}, {"id": 24, "type": "type_descriptor", "text": "instancetype", "parent": 23, "children": [25], "start_point": {"row": 20, "column": 3}, "end_point": {"row": 20, "column": 15}}, {"id": 25, "type": "type_identifier", "text": "instancetype", "parent": 24, "children": [], "start_point": {"row": 20, "column": 3}, "end_point": {"row": 20, "column": 15}}, {"id": 26, "type": "identifier", "text": "initWithImageLoader", "parent": 23, "children": [], "start_point": {"row": 20, "column": 16}, "end_point": {"row": 20, "column": 35}}, {"id": 27, "type": "binary_expression", "text": "id<ABI41_0_0RCTImageLoaderWithAttributionProtocol>)imageLoader", "parent": 12, "children": [28, 32, 33], "start_point": {"row": 20, "column": 37}, "end_point": {"row": 20, "column": 99}}, {"id": 28, "type": "binary_expression", "text": "id<ABI41_0_0RCTImageLoaderWithAttributionProtocol", "parent": 27, "children": [29, 30, 31], "start_point": {"row": 20, "column": 37}, "end_point": {"row": 20, "column": 86}}, {"id": 29, "type": "identifier", "text": "id", "parent": 28, "children": [], "start_point": {"row": 20, "column": 37}, "end_point": {"row": 20, "column": 39}}, {"id": 30, "type": "<", "text": "<", "parent": 28, "children": [], "start_point": {"row": 20, "column": 39}, "end_point": {"row": 20, "column": 40}}, {"id": 31, "type": "identifier", "text": "ABI41_0_0RCTImageLoaderWithAttributionProtocol", "parent": 28, "children": [], "start_point": {"row": 20, "column": 40}, "end_point": {"row": 20, "column": 86}}, {"id": 32, "type": ">", "text": ">", "parent": 27, "children": [], "start_point": {"row": 20, "column": 86}, "end_point": {"row": 20, "column": 87}}, {"id": 33, "type": "identifier", "text": "imageLoader", "parent": 27, "children": [], "start_point": {"row": 20, "column": 88}, "end_point": {"row": 20, "column": 99}}, {"id": 34, "type": "ERROR", "text": "- (ABI41_0_0facebook::ABI41_0_0React::ImageRequest)requestImage:(", "parent": null, "children": [35], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 65}}, {"id": 35, "type": "unary_expression", "text": "- (ABI41_0_0facebook::ABI41_0_0React::ImageRequest)requestImage", "parent": 34, "children": [36, 37], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 63}}, {"id": 36, "type": "-", "text": "-", "parent": 35, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 1}}, {"id": 37, "type": "cast_expression", "text": "(ABI41_0_0facebook::ABI41_0_0React::ImageRequest)requestImage", "parent": 35, "children": [38, 40, 43], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 22, "column": 63}}, {"id": 38, "type": "type_descriptor", "text": "ABI41_0_0facebook", "parent": 37, "children": [39], "start_point": {"row": 22, "column": 3}, "end_point": {"row": 22, "column": 20}}, {"id": 39, "type": "type_identifier", "text": "ABI41_0_0facebook", "parent": 38, "children": [], "start_point": {"row": 22, "column": 3}, "end_point": {"row": 22, "column": 20}}, {"id": 40, "type": "ERROR", "text": "::ABI41_0_0React::ImageRequest", "parent": 37, "children": [41, 42], "start_point": {"row": 22, "column": 20}, "end_point": {"row": 22, "column": 50}}, {"id": 41, "type": "identifier", "text": "ABI41_0_0React", "parent": 40, "children": [], "start_point": {"row": 22, "column": 22}, "end_point": {"row": 22, "column": 36}}, {"id": 42, "type": "identifier", "text": "ImageRequest", "parent": 40, "children": [], "start_point": {"row": 22, "column": 38}, "end_point": {"row": 22, "column": 50}}, {"id": 43, "type": "identifier", "text": "requestImage", "parent": 37, "children": [], "start_point": {"row": 22, "column": 51}, "end_point": {"row": 22, "column": 63}}, {"id": 44, "type": "labeled_statement", "text": "ABI41_0_0facebook::ABI41_0_0React::ImageSource)imageSource\n surfaceId:(ABI41_0_0facebook::ABI41_0_0React::SurfaceId)surfaceId;", "parent": null, "children": [45, 46], "start_point": {"row": 22, "column": 65}, "end_point": {"row": 23, "column": 102}}, {"id": 45, "type": "statement_identifier", "text": "ABI41_0_0facebook", "parent": 44, "children": [], "start_point": {"row": 22, "column": 65}, "end_point": {"row": 22, "column": 82}}, {"id": 46, "type": "labeled_statement", "text": "ABI41_0_0React::ImageSource)imageSource\n surfaceId:(ABI41_0_0facebook::ABI41_0_0React::SurfaceId)surfaceId;", "parent": 44, "children": [47, 48], "start_point": {"row": 22, "column": 84}, "end_point": {"row": 23, "column": 102}}, {"id": 47, "type": "statement_identifier", "text": "ABI41_0_0React", "parent": 46, "children": [], "start_point": {"row": 22, "column": 84}, "end_point": {"row": 22, "column": 98}}, {"id": 48, "type": "ERROR", "text": "::ImageSource)imageSource\n surfaceId", "parent": 46, "children": [49, 50, 51], "start_point": {"row": 22, "column": 98}, "end_point": {"row": 23, "column": 45}}, {"id": 49, "type": "type_identifier", "text": "ImageSource", "parent": 48, "children": [], "start_point": {"row": 22, "column": 100}, "end_point": {"row": 22, "column": 111}}, {"id": 50, "type": "identifier", "text": "imageSource", "parent": 48, "children": [], "start_point": {"row": 22, "column": 112}, "end_point": {"row": 22, "column": 123}}, {"id": 51, "type": "identifier", "text": "surfaceId", "parent": 48, "children": [], "start_point": {"row": 23, "column": 36}, "end_point": {"row": 23, "column": 45}}, {"id": 52, "type": "cast_expression", "text": "(ABI41_0_0facebook::ABI41_0_0React::SurfaceId)surfaceId", "parent": 46, "children": [53, 55, 58], "start_point": {"row": 23, "column": 46}, "end_point": {"row": 23, "column": 101}}, {"id": 53, "type": "type_descriptor", "text": "ABI41_0_0facebook", "parent": 52, "children": [54], "start_point": {"row": 23, "column": 47}, "end_point": {"row": 23, "column": 64}}, {"id": 54, "type": "type_identifier", "text": "ABI41_0_0facebook", "parent": 53, "children": [], "start_point": {"row": 23, "column": 47}, "end_point": {"row": 23, "column": 64}}, {"id": 55, "type": "ERROR", "text": "::ABI41_0_0React::SurfaceId", "parent": 52, "children": [56, 57], "start_point": {"row": 23, "column": 64}, "end_point": {"row": 23, "column": 91}}, {"id": 56, "type": "identifier", "text": "ABI41_0_0React", "parent": 55, "children": [], "start_point": {"row": 23, "column": 66}, "end_point": {"row": 23, "column": 80}}, {"id": 57, "type": "identifier", "text": "SurfaceId", "parent": 55, "children": [], "start_point": {"row": 23, "column": 82}, "end_point": {"row": 23, "column": 91}}, {"id": 58, "type": "identifier", "text": "surfaceId", "parent": 52, "children": [], "start_point": {"row": 23, "column": 92}, "end_point": {"row": 23, "column": 101}}, {"id": 59, "type": "ERROR", "text": "@", "parent": null, "children": [60], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 1}}, {"id": 60, "type": "ERROR", "text": "@", "parent": 59, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 1}}, {"id": 61, "type": "declaration", "text": "end\n\nNS_ASSUME_NONNULL_END", "parent": null, "children": [62], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 27, "column": 21}}, {"id": 62, "type": "identifier", "text": "NS_ASSUME_NONNULL_END", "parent": 61, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 21}}]}, "node_categories": {"declarations": {"functions": [], "variables": [6, 61], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [21, 23, 27, 28, 35, 37, 52], "assignments": [], "loops": [], "conditionals": [7, 10, 11, 14, 16, 17, 19, 25, 26, 29, 31, 33, 39, 41, 42, 43, 45, 47, 49, 50, 51, 54, 56, 57, 58, 62], "returns": [], "exceptions": []}, "expressions": {"calls": [0, 3], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [], "class_declarations": [], "import_statements": []}, "original_source_code": "/*\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n#import <UIKit/UIKit.h>\n\n#import <ABI41_0_0RCTImageManagerProtocol.h>\n\nNS_ASSUME_NONNULL_BEGIN\n\n@protocol ABI41_0_0RCTImageLoaderWithAttributionProtocol;\n\n/**\n * iOS-specific ImageManager.\n */\n@interface ABI41_0_0RCTSyncImageManager : NSObject <ABI41_0_0RCTImageManagerProtocol>\n\n- (instancetype)initWithImageLoader:(id<ABI41_0_0RCTImageLoaderWithAttributionProtocol>)imageLoader;\n\n- (ABI41_0_0facebook::ABI41_0_0React::ImageRequest)requestImage:(ABI41_0_0facebook::ABI41_0_0React::ImageSource)imageSource\n surfaceId:(ABI41_0_0facebook::ABI41_0_0React::SurfaceId)surfaceId;\n\n@end\n\nNS_ASSUME_NONNULL_END\n"}
80,503
c
/** * This header is generated by class-dump-z 0.2b. * * Source: /System/Library/PrivateFrameworks/AccountSettingsUI.framework/AccountSettingsUI */ @protocol AccountSettingsUIAccount <NSObject> + (id)displayedAccountTypeString; + (id)displayedShortAccountTypeString; + (void *)createSyncDataSourceForDataclass:(id)dataclass options:(id)options; - (id)displayName; - (id)uniqueId; - (id)syncStoreIdentifier; - (id)enabledDataclasses; - (BOOL)isEnabledForDataclass:(id)dataclass; - (void)setEnabled:(BOOL)enabled forDataclass:(id)dataclass; - (BOOL)supportsPush; - (BOOL)otherAccountEnabledForDataclass:(id)dataclass; @optional + (Class)detailControllerClass; + (Class)syncControllerClass; - (id)accountInfoUsername; - (id)localizedDetailString; - (void *)createSyncDataSourceForDataclass:(id)dataclass options:(id)options; - (BOOL)supportsPushForDataclass:(id)dataclass; @end
31.63
27
(translation_unit) "/**\n * This header is generated by class-dump-z 0.2b.\n *\n * Source: /System/Library/PrivateFrameworks/AccountSettingsUI.framework/AccountSettingsUI\n */\n\n\n\n\n@protocol AccountSettingsUIAccount <NSObject>\n+ (id)displayedAccountTypeString;\n+ (id)displayedShortAccountTypeString;\n+ (void *)createSyncDataSourceForDataclass:(id)dataclass options:(id)options;\n- (id)displayName;\n- (id)uniqueId;\n- (id)syncStoreIdentifier;\n- (id)enabledDataclasses;\n- (BOOL)isEnabledForDataclass:(id)dataclass;\n- (void)setEnabled:(BOOL)enabled forDataclass:(id)dataclass;\n- (BOOL)supportsPush;\n- (BOOL)otherAccountEnabledForDataclass:(id)dataclass;\n@optional\n+ (Class)detailControllerClass;\n+ (Class)syncControllerClass;\n- (id)accountInfoUsername;\n- (id)localizedDetailString;\n- (void *)createSyncDataSourceForDataclass:(id)dataclass options:(id)options;\n- (BOOL)supportsPushForDataclass:(id)dataclass;\n@end\n\n" (comment) "/**\n * This header is generated by class-dump-z 0.2b.\n *\n * Source: /System/Library/PrivateFrameworks/AccountSettingsUI.framework/AccountSettingsUI\n */" (ERROR) "@protocol AccountSettingsUIAccount <NSObject>" (ERROR) "@" (type_identifier) "protocol" (identifier) "AccountSettingsUIAccount" (<) "<" (identifier) "NSObject" (>) ">" (expression_statement) "+ (id)displayedAccountTypeString;" (unary_expression) "+ (id)displayedAccountTypeString" (+) "+" (cast_expression) "(id)displayedAccountTypeString" (() "(" (type_descriptor) "id" (type_identifier) "id" ()) ")" (identifier) "displayedAccountTypeString" (;) ";" (expression_statement) "+ (id)displayedShortAccountTypeString;" (unary_expression) "+ (id)displayedShortAccountTypeString" (+) "+" (cast_expression) "(id)displayedShortAccountTypeString" (() "(" (type_descriptor) "id" (type_identifier) "id" ()) ")" (identifier) "displayedShortAccountTypeString" (;) ";" (ERROR) "+ (void *)createSyncDataSourceForDataclass:(id)" (unary_expression) "+ (void *)createSyncDataSourceForDataclass" (+) "+" (cast_expression) "(void *)createSyncDataSourceForDataclass" (() "(" (type_descriptor) "void *" (primitive_type) "void" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "createSyncDataSourceForDataclass" (:) ":" (() "(" (identifier) "id" ()) ")" (declaration) "dataclass options:(id)options;" (type_identifier) "dataclass" (identifier) "options" (ERROR) ":(id)options" (:) ":" (() "(" (identifier) "id" ()) ")" (identifier) "options" (;) ";" (expression_statement) "- (id)displayName;" (unary_expression) "- (id)displayName" (-) "-" (cast_expression) "(id)displayName" (() "(" (type_descriptor) "id" (type_identifier) "id" ()) ")" (identifier) "displayName" (;) ";" (expression_statement) "- (id)uniqueId;" (unary_expression) "- (id)uniqueId" (-) "-" (cast_expression) "(id)uniqueId" (() "(" (type_descriptor) "id" (type_identifier) "id" ()) ")" (identifier) "uniqueId" (;) ";" (expression_statement) "- (id)syncStoreIdentifier;" (unary_expression) "- (id)syncStoreIdentifier" (-) "-" (cast_expression) "(id)syncStoreIdentifier" (() "(" (type_descriptor) "id" (type_identifier) "id" ()) ")" (identifier) "syncStoreIdentifier" (;) ";" (expression_statement) "- (id)enabledDataclasses;" (unary_expression) "- (id)enabledDataclasses" (-) "-" (cast_expression) "(id)enabledDataclasses" (() "(" (type_descriptor) "id" (type_identifier) "id" ()) ")" (identifier) "enabledDataclasses" (;) ";" (expression_statement) "- (BOOL)isEnabledForDataclass:(id)dataclass;" (unary_expression) "- (BOOL)isEnabledForDataclass" (-) "-" (cast_expression) "(BOOL)isEnabledForDataclass" (() "(" (type_descriptor) "BOOL" (type_identifier) "BOOL" ()) ")" (identifier) "isEnabledForDataclass" (ERROR) ":(id)dataclass" (:) ":" (() "(" (identifier) "id" ()) ")" (identifier) "dataclass" (;) ";" (ERROR) "- (void)setEnabled:(BOOL)" (unary_expression) "- (void)setEnabled" (-) "-" (cast_expression) "(void)setEnabled" (() "(" (type_descriptor) "void" (primitive_type) "void" ()) ")" (identifier) "setEnabled" (:) ":" (() "(" (identifier) "BOOL" ()) ")" (declaration) "enabled forDataclass:(id)dataclass;" (type_identifier) "enabled" (identifier) "forDataclass" (ERROR) ":(id)dataclass" (:) ":" (() "(" (identifier) "id" ()) ")" (identifier) "dataclass" (;) ";" (expression_statement) "- (BOOL)supportsPush;" (unary_expression) "- (BOOL)supportsPush" (-) "-" (cast_expression) "(BOOL)supportsPush" (() "(" (type_descriptor) "BOOL" (type_identifier) "BOOL" ()) ")" (identifier) "supportsPush" (;) ";" (expression_statement) "- (BOOL)otherAccountEnabledForDataclass:(id)dataclass;" (unary_expression) "- (BOOL)otherAccountEnabledForDataclass" (-) "-" (cast_expression) "(BOOL)otherAccountEnabledForDataclass" (() "(" (type_descriptor) "BOOL" (type_identifier) "BOOL" ()) ")" (identifier) "otherAccountEnabledForDataclass" (ERROR) ":(id)dataclass" (:) ":" (() "(" (identifier) "id" ()) ")" (identifier) "dataclass" (;) ";" (ERROR) "@optional\n+ (Class)detailControllerClass" (ERROR) "@" (binary_expression) "optional\n+ (Class)detailControllerClass" (identifier) "optional" (+) "+" (cast_expression) "(Class)detailControllerClass" (() "(" (type_descriptor) "Class" (type_identifier) "Class" ()) ")" (identifier) "detailControllerClass" (expression_statement) ";" (;) ";" (expression_statement) "+ (Class)syncControllerClass;" (unary_expression) "+ (Class)syncControllerClass" (+) "+" (cast_expression) "(Class)syncControllerClass" (() "(" (type_descriptor) "Class" (type_identifier) "Class" ()) ")" (identifier) "syncControllerClass" (;) ";" (expression_statement) "- (id)accountInfoUsername;" (unary_expression) "- (id)accountInfoUsername" (-) "-" (cast_expression) "(id)accountInfoUsername" (() "(" (type_descriptor) "id" (type_identifier) "id" ()) ")" (identifier) "accountInfoUsername" (;) ";" (expression_statement) "- (id)localizedDetailString;" (unary_expression) "- (id)localizedDetailString" (-) "-" (cast_expression) "(id)localizedDetailString" (() "(" (type_descriptor) "id" (type_identifier) "id" ()) ")" (identifier) "localizedDetailString" (;) ";" (ERROR) "- (void *)createSyncDataSourceForDataclass:(id)" (unary_expression) "- (void *)createSyncDataSourceForDataclass" (-) "-" (cast_expression) "(void *)createSyncDataSourceForDataclass" (() "(" (type_descriptor) "void *" (primitive_type) "void" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "createSyncDataSourceForDataclass" (:) ":" (() "(" (identifier) "id" ()) ")" (declaration) "dataclass options:(id)options;" (type_identifier) "dataclass" (identifier) "options" (ERROR) ":(id)options" (:) ":" (() "(" (identifier) "id" ()) ")" (identifier) "options" (;) ";" (expression_statement) "- (BOOL)supportsPushForDataclass:(id)dataclass;" (unary_expression) "- (BOOL)supportsPushForDataclass" (-) "-" (cast_expression) "(BOOL)supportsPushForDataclass" (() "(" (type_descriptor) "BOOL" (type_identifier) "BOOL" ()) ")" (identifier) "supportsPushForDataclass" (ERROR) ":(id)dataclass" (:) ":" (() "(" (identifier) "id" ()) ")" (identifier) "dataclass" (;) ";" (ERROR) "@" (ERROR) "@" (expression_statement) "end" (identifier) "end" (;) ""
248
15
{"language": "c", "success": true, "metadata": {"lines": 27, "avg_line_length": 31.63, "nodes": 151, "errors": 0, "source_hash": "85933696107bae2770cef141b1cd6c34cecfe10e08faad3d581c45a356052b2a", "categorized_nodes": 93}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "ERROR", "text": "@protocol AccountSettingsUIAccount <NSObject>", "parent": null, "children": [1, 2, 3, 4, 5, 6], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 45}}, {"id": 1, "type": "ERROR", "text": "@", "parent": 0, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 1}}, {"id": 2, "type": "type_identifier", "text": "protocol", "parent": 0, "children": [], "start_point": {"row": 9, "column": 1}, "end_point": {"row": 9, "column": 9}}, {"id": 3, "type": "identifier", "text": "AccountSettingsUIAccount", "parent": 0, "children": [], "start_point": {"row": 9, "column": 10}, "end_point": {"row": 9, "column": 34}}, {"id": 4, "type": "<", "text": "<", "parent": 0, "children": [], "start_point": {"row": 9, "column": 35}, "end_point": {"row": 9, "column": 36}}, {"id": 5, "type": "identifier", "text": "NSObject", "parent": 0, "children": [], "start_point": {"row": 9, "column": 36}, "end_point": {"row": 9, "column": 44}}, {"id": 6, "type": ">", "text": ">", "parent": 0, "children": [], "start_point": {"row": 9, "column": 44}, "end_point": {"row": 9, "column": 45}}, {"id": 7, "type": "unary_expression", "text": "+ (id)displayedAccountTypeString", "parent": null, "children": [8, 9], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 32}}, {"id": 8, "type": "+", "text": "+", "parent": 7, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 1}}, {"id": 9, "type": "cast_expression", "text": "(id)displayedAccountTypeString", "parent": 7, "children": [10, 12], "start_point": {"row": 10, "column": 2}, "end_point": {"row": 10, "column": 32}}, {"id": 10, "type": "type_descriptor", "text": "id", "parent": 9, "children": [11], "start_point": {"row": 10, "column": 3}, "end_point": {"row": 10, "column": 5}}, {"id": 11, "type": "type_identifier", "text": "id", "parent": 10, "children": [], "start_point": {"row": 10, "column": 3}, "end_point": {"row": 10, "column": 5}}, {"id": 12, "type": "identifier", "text": "displayedAccountTypeString", "parent": 9, "children": [], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 32}}, {"id": 13, "type": "unary_expression", "text": "+ (id)displayedShortAccountTypeString", "parent": null, "children": [14, 15], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 37}}, {"id": 14, "type": "+", "text": "+", "parent": 13, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 1}}, {"id": 15, "type": "cast_expression", "text": "(id)displayedShortAccountTypeString", "parent": 13, "children": [16, 18], "start_point": {"row": 11, "column": 2}, "end_point": {"row": 11, "column": 37}}, {"id": 16, "type": "type_descriptor", "text": "id", "parent": 15, "children": [17], "start_point": {"row": 11, "column": 3}, "end_point": {"row": 11, "column": 5}}, {"id": 17, "type": "type_identifier", "text": "id", "parent": 16, "children": [], "start_point": {"row": 11, "column": 3}, "end_point": {"row": 11, "column": 5}}, {"id": 18, "type": "identifier", "text": "displayedShortAccountTypeString", "parent": 15, "children": [], "start_point": {"row": 11, "column": 6}, "end_point": {"row": 11, "column": 37}}, {"id": 19, "type": "ERROR", "text": "+ (void *)createSyncDataSourceForDataclass:(id)", "parent": null, "children": [20, 28], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 47}}, {"id": 20, "type": "unary_expression", "text": "+ (void *)createSyncDataSourceForDataclass", "parent": 19, "children": [21, 22], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 42}}, {"id": 21, "type": "+", "text": "+", "parent": 20, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 1}}, {"id": 22, "type": "cast_expression", "text": "(void *)createSyncDataSourceForDataclass", "parent": 20, "children": [23, 27], "start_point": {"row": 12, "column": 2}, "end_point": {"row": 12, "column": 42}}, {"id": 23, "type": "type_descriptor", "text": "void *", "parent": 22, "children": [24, 25], "start_point": {"row": 12, "column": 3}, "end_point": {"row": 12, "column": 9}}, {"id": 24, "type": "primitive_type", "text": "void", "parent": 23, "children": [], "start_point": {"row": 12, "column": 3}, "end_point": {"row": 12, "column": 7}}, {"id": 25, "type": "abstract_pointer_declarator", "text": "*", "parent": 23, "children": [26], "start_point": {"row": 12, "column": 8}, "end_point": {"row": 12, "column": 9}}, {"id": 26, "type": "*", "text": "*", "parent": 25, "children": [], "start_point": {"row": 12, "column": 8}, "end_point": {"row": 12, "column": 9}}, {"id": 27, "type": "identifier", "text": "createSyncDataSourceForDataclass", "parent": 22, "children": [], "start_point": {"row": 12, "column": 10}, "end_point": {"row": 12, "column": 42}}, {"id": 28, "type": "identifier", "text": "id", "parent": 19, "children": [], "start_point": {"row": 12, "column": 44}, "end_point": {"row": 12, "column": 46}}, {"id": 29, "type": "declaration", "text": "dataclass options:(id)options;", "parent": null, "children": [30, 31, 32], "start_point": {"row": 12, "column": 47}, "end_point": {"row": 12, "column": 77}}, {"id": 30, "type": "type_identifier", "text": "dataclass", "parent": 29, "children": [], "start_point": {"row": 12, "column": 47}, "end_point": {"row": 12, "column": 56}}, {"id": 31, "type": "identifier", "text": "options", "parent": 29, "children": [], "start_point": {"row": 12, "column": 57}, "end_point": {"row": 12, "column": 64}}, {"id": 32, "type": "ERROR", "text": ":(id)options", "parent": 29, "children": [33, 34], "start_point": {"row": 12, "column": 64}, "end_point": {"row": 12, "column": 76}}, {"id": 33, "type": "identifier", "text": "id", "parent": 32, "children": [], "start_point": {"row": 12, "column": 66}, "end_point": {"row": 12, "column": 68}}, {"id": 34, "type": "identifier", "text": "options", "parent": 32, "children": [], "start_point": {"row": 12, "column": 69}, "end_point": {"row": 12, "column": 76}}, {"id": 35, "type": "unary_expression", "text": "- (id)displayName", "parent": null, "children": [36, 37], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 17}}, {"id": 36, "type": "-", "text": "-", "parent": 35, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 37, "type": "cast_expression", "text": "(id)displayName", "parent": 35, "children": [38, 40], "start_point": {"row": 13, "column": 2}, "end_point": {"row": 13, "column": 17}}, {"id": 38, "type": "type_descriptor", "text": "id", "parent": 37, "children": [39], "start_point": {"row": 13, "column": 3}, "end_point": {"row": 13, "column": 5}}, {"id": 39, "type": "type_identifier", "text": "id", "parent": 38, "children": [], "start_point": {"row": 13, "column": 3}, "end_point": {"row": 13, "column": 5}}, {"id": 40, "type": "identifier", "text": "displayName", "parent": 37, "children": [], "start_point": {"row": 13, "column": 6}, "end_point": {"row": 13, "column": 17}}, {"id": 41, "type": "unary_expression", "text": "- (id)uniqueId", "parent": null, "children": [42, 43], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 14}}, {"id": 42, "type": "-", "text": "-", "parent": 41, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 1}}, {"id": 43, "type": "cast_expression", "text": "(id)uniqueId", "parent": 41, "children": [44, 46], "start_point": {"row": 14, "column": 2}, "end_point": {"row": 14, "column": 14}}, {"id": 44, "type": "type_descriptor", "text": "id", "parent": 43, "children": [45], "start_point": {"row": 14, "column": 3}, "end_point": {"row": 14, "column": 5}}, {"id": 45, "type": "type_identifier", "text": "id", "parent": 44, "children": [], "start_point": {"row": 14, "column": 3}, "end_point": {"row": 14, "column": 5}}, {"id": 46, "type": "identifier", "text": "uniqueId", "parent": 43, "children": [], "start_point": {"row": 14, "column": 6}, "end_point": {"row": 14, "column": 14}}, {"id": 47, "type": "unary_expression", "text": "- (id)syncStoreIdentifier", "parent": null, "children": [48, 49], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 25}}, {"id": 48, "type": "-", "text": "-", "parent": 47, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 1}}, {"id": 49, "type": "cast_expression", "text": "(id)syncStoreIdentifier", "parent": 47, "children": [50, 52], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 25}}, {"id": 50, "type": "type_descriptor", "text": "id", "parent": 49, "children": [51], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 5}}, {"id": 51, "type": "type_identifier", "text": "id", "parent": 50, "children": [], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 5}}, {"id": 52, "type": "identifier", "text": "syncStoreIdentifier", "parent": 49, "children": [], "start_point": {"row": 15, "column": 6}, "end_point": {"row": 15, "column": 25}}, {"id": 53, "type": "unary_expression", "text": "- (id)enabledDataclasses", "parent": null, "children": [54, 55], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 24}}, {"id": 54, "type": "-", "text": "-", "parent": 53, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 1}}, {"id": 55, "type": "cast_expression", "text": "(id)enabledDataclasses", "parent": 53, "children": [56, 58], "start_point": {"row": 16, "column": 2}, "end_point": {"row": 16, "column": 24}}, {"id": 56, "type": "type_descriptor", "text": "id", "parent": 55, "children": [57], "start_point": {"row": 16, "column": 3}, "end_point": {"row": 16, "column": 5}}, {"id": 57, "type": "type_identifier", "text": "id", "parent": 56, "children": [], "start_point": {"row": 16, "column": 3}, "end_point": {"row": 16, "column": 5}}, {"id": 58, "type": "identifier", "text": "enabledDataclasses", "parent": 55, "children": [], "start_point": {"row": 16, "column": 6}, "end_point": {"row": 16, "column": 24}}, {"id": 59, "type": "unary_expression", "text": "- (BOOL)isEnabledForDataclass", "parent": null, "children": [60, 61], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 29}}, {"id": 60, "type": "-", "text": "-", "parent": 59, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 61, "type": "cast_expression", "text": "(BOOL)isEnabledForDataclass", "parent": 59, "children": [62, 64], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 17, "column": 29}}, {"id": 62, "type": "type_descriptor", "text": "BOOL", "parent": 61, "children": [63], "start_point": {"row": 17, "column": 3}, "end_point": {"row": 17, "column": 7}}, {"id": 63, "type": "type_identifier", "text": "BOOL", "parent": 62, "children": [], "start_point": {"row": 17, "column": 3}, "end_point": {"row": 17, "column": 7}}, {"id": 64, "type": "identifier", "text": "isEnabledForDataclass", "parent": 61, "children": [], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 17, "column": 29}}, {"id": 65, "type": "ERROR", "text": ":(id)dataclass", "parent": null, "children": [66, 67], "start_point": {"row": 17, "column": 29}, "end_point": {"row": 17, "column": 43}}, {"id": 66, "type": "identifier", "text": "id", "parent": 65, "children": [], "start_point": {"row": 17, "column": 31}, "end_point": {"row": 17, "column": 33}}, {"id": 67, "type": "identifier", "text": "dataclass", "parent": 65, "children": [], "start_point": {"row": 17, "column": 34}, "end_point": {"row": 17, "column": 43}}, {"id": 68, "type": "ERROR", "text": "- (void)setEnabled:(BOOL)", "parent": null, "children": [69, 75], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 25}}, {"id": 69, "type": "unary_expression", "text": "- (void)setEnabled", "parent": 68, "children": [70, 71], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 18}}, {"id": 70, "type": "-", "text": "-", "parent": 69, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 1}}, {"id": 71, "type": "cast_expression", "text": "(void)setEnabled", "parent": 69, "children": [72, 74], "start_point": {"row": 18, "column": 2}, "end_point": {"row": 18, "column": 18}}, {"id": 72, "type": "type_descriptor", "text": "void", "parent": 71, "children": [73], "start_point": {"row": 18, "column": 3}, "end_point": {"row": 18, "column": 7}}, {"id": 73, "type": "primitive_type", "text": "void", "parent": 72, "children": [], "start_point": {"row": 18, "column": 3}, "end_point": {"row": 18, "column": 7}}, {"id": 74, "type": "identifier", "text": "setEnabled", "parent": 71, "children": [], "start_point": {"row": 18, "column": 8}, "end_point": {"row": 18, "column": 18}}, {"id": 75, "type": "identifier", "text": "BOOL", "parent": 68, "children": [], "start_point": {"row": 18, "column": 20}, "end_point": {"row": 18, "column": 24}}, {"id": 76, "type": "declaration", "text": "enabled forDataclass:(id)dataclass;", "parent": null, "children": [77, 78, 79], "start_point": {"row": 18, "column": 25}, "end_point": {"row": 18, "column": 60}}, {"id": 77, "type": "type_identifier", "text": "enabled", "parent": 76, "children": [], "start_point": {"row": 18, "column": 25}, "end_point": {"row": 18, "column": 32}}, {"id": 78, "type": "identifier", "text": "forDataclass", "parent": 76, "children": [], "start_point": {"row": 18, "column": 33}, "end_point": {"row": 18, "column": 45}}, {"id": 79, "type": "ERROR", "text": ":(id)dataclass", "parent": 76, "children": [80, 81], "start_point": {"row": 18, "column": 45}, "end_point": {"row": 18, "column": 59}}, {"id": 80, "type": "identifier", "text": "id", "parent": 79, "children": [], "start_point": {"row": 18, "column": 47}, "end_point": {"row": 18, "column": 49}}, {"id": 81, "type": "identifier", "text": "dataclass", "parent": 79, "children": [], "start_point": {"row": 18, "column": 50}, "end_point": {"row": 18, "column": 59}}, {"id": 82, "type": "unary_expression", "text": "- (BOOL)supportsPush", "parent": null, "children": [83, 84], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 20}}, {"id": 83, "type": "-", "text": "-", "parent": 82, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 1}}, {"id": 84, "type": "cast_expression", "text": "(BOOL)supportsPush", "parent": 82, "children": [85, 87], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 20}}, {"id": 85, "type": "type_descriptor", "text": "BOOL", "parent": 84, "children": [86], "start_point": {"row": 19, "column": 3}, "end_point": {"row": 19, "column": 7}}, {"id": 86, "type": "type_identifier", "text": "BOOL", "parent": 85, "children": [], "start_point": {"row": 19, "column": 3}, "end_point": {"row": 19, "column": 7}}, {"id": 87, "type": "identifier", "text": "supportsPush", "parent": 84, "children": [], "start_point": {"row": 19, "column": 8}, "end_point": {"row": 19, "column": 20}}, {"id": 88, "type": "unary_expression", "text": "- (BOOL)otherAccountEnabledForDataclass", "parent": null, "children": [89, 90], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 39}}, {"id": 89, "type": "-", "text": "-", "parent": 88, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 1}}, {"id": 90, "type": "cast_expression", "text": "(BOOL)otherAccountEnabledForDataclass", "parent": 88, "children": [91, 93], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 39}}, {"id": 91, "type": "type_descriptor", "text": "BOOL", "parent": 90, "children": [92], "start_point": {"row": 20, "column": 3}, "end_point": {"row": 20, "column": 7}}, {"id": 92, "type": "type_identifier", "text": "BOOL", "parent": 91, "children": [], "start_point": {"row": 20, "column": 3}, "end_point": {"row": 20, "column": 7}}, {"id": 93, "type": "identifier", "text": "otherAccountEnabledForDataclass", "parent": 90, "children": [], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 39}}, {"id": 94, "type": "ERROR", "text": ":(id)dataclass", "parent": null, "children": [95, 96], "start_point": {"row": 20, "column": 39}, "end_point": {"row": 20, "column": 53}}, {"id": 95, "type": "identifier", "text": "id", "parent": 94, "children": [], "start_point": {"row": 20, "column": 41}, "end_point": {"row": 20, "column": 43}}, {"id": 96, "type": "identifier", "text": "dataclass", "parent": 94, "children": [], "start_point": {"row": 20, "column": 44}, "end_point": {"row": 20, "column": 53}}, {"id": 97, "type": "ERROR", "text": "@optional\n+ (Class)detailControllerClass", "parent": null, "children": [98, 99], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 22, "column": 30}}, {"id": 98, "type": "ERROR", "text": "@", "parent": 97, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 1}}, {"id": 99, "type": "binary_expression", "text": "optional\n+ (Class)detailControllerClass", "parent": 97, "children": [100, 101, 102], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 22, "column": 30}}, {"id": 100, "type": "identifier", "text": "optional", "parent": 99, "children": [], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 9}}, {"id": 101, "type": "+", "text": "+", "parent": 99, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 1}}, {"id": 102, "type": "cast_expression", "text": "(Class)detailControllerClass", "parent": 99, "children": [103, 105], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 22, "column": 30}}, {"id": 103, "type": "type_descriptor", "text": "Class", "parent": 102, "children": [104], "start_point": {"row": 22, "column": 3}, "end_point": {"row": 22, "column": 8}}, {"id": 104, "type": "type_identifier", "text": "Class", "parent": 103, "children": [], "start_point": {"row": 22, "column": 3}, "end_point": {"row": 22, "column": 8}}, {"id": 105, "type": "identifier", "text": "detailControllerClass", "parent": 102, "children": [], "start_point": {"row": 22, "column": 9}, "end_point": {"row": 22, "column": 30}}, {"id": 106, "type": "unary_expression", "text": "+ (Class)syncControllerClass", "parent": null, "children": [107, 108], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 28}}, {"id": 107, "type": "+", "text": "+", "parent": 106, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 1}}, {"id": 108, "type": "cast_expression", "text": "(Class)syncControllerClass", "parent": 106, "children": [109, 111], "start_point": {"row": 23, "column": 2}, "end_point": {"row": 23, "column": 28}}, {"id": 109, "type": "type_descriptor", "text": "Class", "parent": 108, "children": [110], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 23, "column": 8}}, {"id": 110, "type": "type_identifier", "text": "Class", "parent": 109, "children": [], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 23, "column": 8}}, {"id": 111, "type": "identifier", "text": "syncControllerClass", "parent": 108, "children": [], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 28}}, {"id": 112, "type": "unary_expression", "text": "- (id)accountInfoUsername", "parent": null, "children": [113, 114], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 25}}, {"id": 113, "type": "-", "text": "-", "parent": 112, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 1}}, {"id": 114, "type": "cast_expression", "text": "(id)accountInfoUsername", "parent": 112, "children": [115, 117], "start_point": {"row": 24, "column": 2}, "end_point": {"row": 24, "column": 25}}, {"id": 115, "type": "type_descriptor", "text": "id", "parent": 114, "children": [116], "start_point": {"row": 24, "column": 3}, "end_point": {"row": 24, "column": 5}}, {"id": 116, "type": "type_identifier", "text": "id", "parent": 115, "children": [], "start_point": {"row": 24, "column": 3}, "end_point": {"row": 24, "column": 5}}, {"id": 117, "type": "identifier", "text": "accountInfoUsername", "parent": 114, "children": [], "start_point": {"row": 24, "column": 6}, "end_point": {"row": 24, "column": 25}}, {"id": 118, "type": "unary_expression", "text": "- (id)localizedDetailString", "parent": null, "children": [119, 120], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 27}}, {"id": 119, "type": "-", "text": "-", "parent": 118, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 1}}, {"id": 120, "type": "cast_expression", "text": "(id)localizedDetailString", "parent": 118, "children": [121, 123], "start_point": {"row": 25, "column": 2}, "end_point": {"row": 25, "column": 27}}, {"id": 121, "type": "type_descriptor", "text": "id", "parent": 120, "children": [122], "start_point": {"row": 25, "column": 3}, "end_point": {"row": 25, "column": 5}}, {"id": 122, "type": "type_identifier", "text": "id", "parent": 121, "children": [], "start_point": {"row": 25, "column": 3}, "end_point": {"row": 25, "column": 5}}, {"id": 123, "type": "identifier", "text": "localizedDetailString", "parent": 120, "children": [], "start_point": {"row": 25, "column": 6}, "end_point": {"row": 25, "column": 27}}, {"id": 124, "type": "ERROR", "text": "- (void *)createSyncDataSourceForDataclass:(id)", "parent": null, "children": [125, 133], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 47}}, {"id": 125, "type": "unary_expression", "text": "- (void *)createSyncDataSourceForDataclass", "parent": 124, "children": [126, 127], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 42}}, {"id": 126, "type": "-", "text": "-", "parent": 125, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 1}}, {"id": 127, "type": "cast_expression", "text": "(void *)createSyncDataSourceForDataclass", "parent": 125, "children": [128, 132], "start_point": {"row": 26, "column": 2}, "end_point": {"row": 26, "column": 42}}, {"id": 128, "type": "type_descriptor", "text": "void *", "parent": 127, "children": [129, 130], "start_point": {"row": 26, "column": 3}, "end_point": {"row": 26, "column": 9}}, {"id": 129, "type": "primitive_type", "text": "void", "parent": 128, "children": [], "start_point": {"row": 26, "column": 3}, "end_point": {"row": 26, "column": 7}}, {"id": 130, "type": "abstract_pointer_declarator", "text": "*", "parent": 128, "children": [131], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 9}}, {"id": 131, "type": "*", "text": "*", "parent": 130, "children": [], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 9}}, {"id": 132, "type": "identifier", "text": "createSyncDataSourceForDataclass", "parent": 127, "children": [], "start_point": {"row": 26, "column": 10}, "end_point": {"row": 26, "column": 42}}, {"id": 133, "type": "identifier", "text": "id", "parent": 124, "children": [], "start_point": {"row": 26, "column": 44}, "end_point": {"row": 26, "column": 46}}, {"id": 134, "type": "declaration", "text": "dataclass options:(id)options;", "parent": null, "children": [135, 136, 137], "start_point": {"row": 26, "column": 47}, "end_point": {"row": 26, "column": 77}}, {"id": 135, "type": "type_identifier", "text": "dataclass", "parent": 134, "children": [], "start_point": {"row": 26, "column": 47}, "end_point": {"row": 26, "column": 56}}, {"id": 136, "type": "identifier", "text": "options", "parent": 134, "children": [], "start_point": {"row": 26, "column": 57}, "end_point": {"row": 26, "column": 64}}, {"id": 137, "type": "ERROR", "text": ":(id)options", "parent": 134, "children": [138, 139], "start_point": {"row": 26, "column": 64}, "end_point": {"row": 26, "column": 76}}, {"id": 138, "type": "identifier", "text": "id", "parent": 137, "children": [], "start_point": {"row": 26, "column": 66}, "end_point": {"row": 26, "column": 68}}, {"id": 139, "type": "identifier", "text": "options", "parent": 137, "children": [], "start_point": {"row": 26, "column": 69}, "end_point": {"row": 26, "column": 76}}, {"id": 140, "type": "unary_expression", "text": "- (BOOL)supportsPushForDataclass", "parent": null, "children": [141, 142], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 32}}, {"id": 141, "type": "-", "text": "-", "parent": 140, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 1}}, {"id": 142, "type": "cast_expression", "text": "(BOOL)supportsPushForDataclass", "parent": 140, "children": [143, 145], "start_point": {"row": 27, "column": 2}, "end_point": {"row": 27, "column": 32}}, {"id": 143, "type": "type_descriptor", "text": "BOOL", "parent": 142, "children": [144], "start_point": {"row": 27, "column": 3}, "end_point": {"row": 27, "column": 7}}, {"id": 144, "type": "type_identifier", "text": "BOOL", "parent": 143, "children": [], "start_point": {"row": 27, "column": 3}, "end_point": {"row": 27, "column": 7}}, {"id": 145, "type": "identifier", "text": "supportsPushForDataclass", "parent": 142, "children": [], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 32}}, {"id": 146, "type": "ERROR", "text": ":(id)dataclass", "parent": null, "children": [147, 148], "start_point": {"row": 27, "column": 32}, "end_point": {"row": 27, "column": 46}}, {"id": 147, "type": "identifier", "text": "id", "parent": 146, "children": [], "start_point": {"row": 27, "column": 34}, "end_point": {"row": 27, "column": 36}}, {"id": 148, "type": "identifier", "text": "dataclass", "parent": 146, "children": [], "start_point": {"row": 27, "column": 37}, "end_point": {"row": 27, "column": 46}}, {"id": 149, "type": "ERROR", "text": "@", "parent": null, "children": [150], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 1}}, {"id": 150, "type": "ERROR", "text": "@", "parent": 149, "children": [], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 1}}]}, "node_categories": {"declarations": {"functions": [], "variables": [29, 76, 134], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [7, 9, 13, 15, 20, 22, 35, 37, 41, 43, 47, 49, 53, 55, 59, 61, 69, 71, 82, 84, 88, 90, 99, 102, 106, 108, 112, 114, 118, 120, 125, 127, 140, 142], "assignments": [], "loops": [], "conditionals": [2, 3, 5, 11, 12, 17, 18, 27, 28, 30, 31, 33, 34, 39, 40, 45, 46, 51, 52, 57, 58, 63, 64, 66, 67, 74, 75, 77, 78, 80, 81, 86, 87, 92, 93, 95, 96, 100, 104, 105, 110, 111, 116, 117, 122, 123, 132, 133, 135, 136, 138, 139, 144, 145, 147, 148], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [], "class_declarations": [], "import_statements": []}, "original_source_code": "/**\n * This header is generated by class-dump-z 0.2b.\n *\n * Source: /System/Library/PrivateFrameworks/AccountSettingsUI.framework/AccountSettingsUI\n */\n\n\n\n\n@protocol AccountSettingsUIAccount <NSObject>\n+ (id)displayedAccountTypeString;\n+ (id)displayedShortAccountTypeString;\n+ (void *)createSyncDataSourceForDataclass:(id)dataclass options:(id)options;\n- (id)displayName;\n- (id)uniqueId;\n- (id)syncStoreIdentifier;\n- (id)enabledDataclasses;\n- (BOOL)isEnabledForDataclass:(id)dataclass;\n- (void)setEnabled:(BOOL)enabled forDataclass:(id)dataclass;\n- (BOOL)supportsPush;\n- (BOOL)otherAccountEnabledForDataclass:(id)dataclass;\n@optional\n+ (Class)detailControllerClass;\n+ (Class)syncControllerClass;\n- (id)accountInfoUsername;\n- (id)localizedDetailString;\n- (void *)createSyncDataSourceForDataclass:(id)dataclass options:(id)options;\n- (BOOL)supportsPushForDataclass:(id)dataclass;\n@end\n\n"}
80,504
c
/* addresses.c -- Playing with addresses of variables and their contents: * what is done by C with variables, addresses, and values. */ #include <stdio.h> void moo(int a, int * b); int main(void) { int x; int *y; x=1; y=&x; printf("Address of x = %d, value of x = %d\n", &x, x); printf("Address of y = %d, value of y = %d, value of *y = %d\n", &y, y, *y); moo(9,y); } void moo(int a, int *b){ printf("Address of a = %d, value of a = %d\n", &a, a); printf("Address of b = %d, value of b = %d, value of *b = %d\n", &b, b, *b); } /* Output from running this program on my computer: Address of x = 536869640, value of x = 1 Address of y = 536869632, value of y = 536869640, value of *y = 1 Address of a = 536869608, value of a = 9 Address of b = 536869600, value of b = 536869640, value of *b = 1 */
33.67
24
(translation_unit) "/* addresses.c -- Playing with addresses of variables and their contents:\n * what is done by C with variables, addresses, and values.\n */\n\n#include <stdio.h>\n\nvoid moo(int a, int * b);\n\nint main(void) {\n int x;\n int *y;\n\n x=1;\n y=&x;\n printf("Address of x = %d, value of x = %d\n", &x, x);\n printf("Address of y = %d, value of y = %d, value of *y = %d\n", &y, y, *y);\n moo(9,y);\n}\n\nvoid moo(int a, int *b){\n printf("Address of a = %d, value of a = %d\n", &a, a);\n printf("Address of b = %d, value of b = %d, value of *b = %d\n", &b, b, *b);\n}\n\n/* Output from running this program on my computer:\n\nAddress of x = 536869640, value of x = 1\nAddress of y = 536869632, value of y = 536869640, value of *y = 1\nAddress of a = 536869608, value of a = 9\nAddress of b = 536869600, value of b = 536869640, value of *b = 1\n\n */\n" (comment) "/* addresses.c -- Playing with addresses of variables and their contents:\n * what is done by C with variables, addresses, and values.\n */" (preproc_include) "#include <stdio.h>\n" (#include) "#include" (system_lib_string) "<stdio.h>" (declaration) "void moo(int a, int * b);" (primitive_type) "void" (function_declarator) "moo(int a, int * b)" (identifier) "moo" (parameter_list) "(int a, int * b)" (() "(" (parameter_declaration) "int a" (primitive_type) "int" (identifier) "a" (,) "," (parameter_declaration) "int * b" (primitive_type) "int" (pointer_declarator) "* b" (*) "*" (identifier) "b" ()) ")" (;) ";" (function_definition) "int main(void) {\n int x;\n int *y;\n\n x=1;\n y=&x;\n printf("Address of x = %d, value of x = %d\n", &x, x);\n printf("Address of y = %d, value of y = %d, value of *y = %d\n", &y, y, *y);\n moo(9,y);\n}" (primitive_type) "int" (function_declarator) "main(void)" (identifier) "main" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (compound_statement) "{\n int x;\n int *y;\n\n x=1;\n y=&x;\n printf("Address of x = %d, value of x = %d\n", &x, x);\n printf("Address of y = %d, value of y = %d, value of *y = %d\n", &y, y, *y);\n moo(9,y);\n}" ({) "{" (declaration) "int x;" (primitive_type) "int" (identifier) "x" (;) ";" (declaration) "int *y;" (primitive_type) "int" (pointer_declarator) "*y" (*) "*" (identifier) "y" (;) ";" (expression_statement) "x=1;" (assignment_expression) "x=1" (identifier) "x" (=) "=" (number_literal) "1" (;) ";" (expression_statement) "y=&x;" (assignment_expression) "y=&x" (identifier) "y" (=) "=" (pointer_expression) "&x" (&) "&" (identifier) "x" (;) ";" (expression_statement) "printf("Address of x = %d, value of x = %d\n", &x, x);" (call_expression) "printf("Address of x = %d, value of x = %d\n", &x, x)" (identifier) "printf" (argument_list) "("Address of x = %d, value of x = %d\n", &x, x)" (() "(" (string_literal) ""Address of x = %d, value of x = %d\n"" (") """ (string_content) "Address of x = %d, value of x = %d" (escape_sequence) "\n" (") """ (,) "," (pointer_expression) "&x" (&) "&" (identifier) "x" (,) "," (identifier) "x" ()) ")" (;) ";" (expression_statement) "printf("Address of y = %d, value of y = %d, value of *y = %d\n", &y, y, *y);" (call_expression) "printf("Address of y = %d, value of y = %d, value of *y = %d\n", &y, y, *y)" (identifier) "printf" (argument_list) "("Address of y = %d, value of y = %d, value of *y = %d\n", &y, y, *y)" (() "(" (string_literal) ""Address of y = %d, value of y = %d, value of *y = %d\n"" (") """ (string_content) "Address of y = %d, value of y = %d, value of *y = %d" (escape_sequence) "\n" (") """ (,) "," (pointer_expression) "&y" (&) "&" (identifier) "y" (,) "," (identifier) "y" (,) "," (pointer_expression) "*y" (*) "*" (identifier) "y" ()) ")" (;) ";" (expression_statement) "moo(9,y);" (call_expression) "moo(9,y)" (identifier) "moo" (argument_list) "(9,y)" (() "(" (number_literal) "9" (,) "," (identifier) "y" ()) ")" (;) ";" (}) "}" (function_definition) "void moo(int a, int *b){\n printf("Address of a = %d, value of a = %d\n", &a, a);\n printf("Address of b = %d, value of b = %d, value of *b = %d\n", &b, b, *b);\n}" (primitive_type) "void" (function_declarator) "moo(int a, int *b)" (identifier) "moo" (parameter_list) "(int a, int *b)" (() "(" (parameter_declaration) "int a" (primitive_type) "int" (identifier) "a" (,) "," (parameter_declaration) "int *b" (primitive_type) "int" (pointer_declarator) "*b" (*) "*" (identifier) "b" ()) ")" (compound_statement) "{\n printf("Address of a = %d, value of a = %d\n", &a, a);\n printf("Address of b = %d, value of b = %d, value of *b = %d\n", &b, b, *b);\n}" ({) "{" (expression_statement) "printf("Address of a = %d, value of a = %d\n", &a, a);" (call_expression) "printf("Address of a = %d, value of a = %d\n", &a, a)" (identifier) "printf" (argument_list) "("Address of a = %d, value of a = %d\n", &a, a)" (() "(" (string_literal) ""Address of a = %d, value of a = %d\n"" (") """ (string_content) "Address of a = %d, value of a = %d" (escape_sequence) "\n" (") """ (,) "," (pointer_expression) "&a" (&) "&" (identifier) "a" (,) "," (identifier) "a" ()) ")" (;) ";" (expression_statement) "printf("Address of b = %d, value of b = %d, value of *b = %d\n", &b, b, *b);" (call_expression) "printf("Address of b = %d, value of b = %d, value of *b = %d\n", &b, b, *b)" (identifier) "printf" (argument_list) "("Address of b = %d, value of b = %d, value of *b = %d\n", &b, b, *b)" (() "(" (string_literal) ""Address of b = %d, value of b = %d, value of *b = %d\n"" (") """ (string_content) "Address of b = %d, value of b = %d, value of *b = %d" (escape_sequence) "\n" (") """ (,) "," (pointer_expression) "&b" (&) "&" (identifier) "b" (,) "," (identifier) "b" (,) "," (pointer_expression) "*b" (*) "*" (identifier) "b" ()) ")" (;) ";" (}) "}" (comment) "/* Output from running this program on my computer:\n\nAddress of x = 536869640, value of x = 1\nAddress of y = 536869632, value of y = 536869640, value of *y = 1\nAddress of a = 536869608, value of a = 9\nAddress of b = 536869600, value of b = 536869640, value of *b = 1\n\n */"
168
0
{"language": "c", "success": true, "metadata": {"lines": 24, "avg_line_length": 33.67, "nodes": 96, "errors": 0, "source_hash": "0118727f957be7c5956c431eaceab0146c40cbea3fb075df5cfb0875e7c6d034", "categorized_nodes": 64}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <stdio.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<stdio.h>", "parent": 0, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 18}}, {"id": 3, "type": "declaration", "text": "void moo(int a, int * b);", "parent": null, "children": [4, 5], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 25}}, {"id": 4, "type": "primitive_type", "text": "void", "parent": 3, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 4}}, {"id": 5, "type": "function_declarator", "text": "moo(int a, int * b)", "parent": 3, "children": [6, 7], "start_point": {"row": 6, "column": 5}, "end_point": {"row": 6, "column": 24}}, {"id": 6, "type": "identifier", "text": "moo", "parent": 5, "children": [], "start_point": {"row": 6, "column": 5}, "end_point": {"row": 6, "column": 8}}, {"id": 7, "type": "parameter_list", "text": "(int a, int * b)", "parent": 5, "children": [8, 11], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 24}}, {"id": 8, "type": "parameter_declaration", "text": "int a", "parent": 7, "children": [9, 10], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 14}}, {"id": 9, "type": "primitive_type", "text": "int", "parent": 8, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 12}}, {"id": 10, "type": "identifier", "text": "a", "parent": 8, "children": [], "start_point": {"row": 6, "column": 13}, "end_point": {"row": 6, "column": 14}}, {"id": 11, "type": "parameter_declaration", "text": "int * b", "parent": 7, "children": [12, 13], "start_point": {"row": 6, "column": 16}, "end_point": {"row": 6, "column": 23}}, {"id": 12, "type": "primitive_type", "text": "int", "parent": 11, "children": [], "start_point": {"row": 6, "column": 16}, "end_point": {"row": 6, "column": 19}}, {"id": 13, "type": "pointer_declarator", "text": "* b", "parent": 11, "children": [14, 15], "start_point": {"row": 6, "column": 20}, "end_point": {"row": 6, "column": 23}}, {"id": 14, "type": "*", "text": "*", "parent": 13, "children": [], "start_point": {"row": 6, "column": 20}, "end_point": {"row": 6, "column": 21}}, {"id": 15, "type": "identifier", "text": "b", "parent": 13, "children": [], "start_point": {"row": 6, "column": 22}, "end_point": {"row": 6, "column": 23}}, {"id": 16, "type": "function_definition", "text": "int main(void) {\n int x;\n int *y;\n\n x=1;\n y=&x;\n printf(\"Address of x = %d, value of x = %d\\n\", &x, x);\n printf(\"Address of y = %d, value of y = %d, value of *y = %d\\n\", &y, y, *y);\n moo(9,y);\n}", "parent": null, "children": [17, 18], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 17, "type": "primitive_type", "text": "int", "parent": 16, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 3}}, {"id": 18, "type": "function_declarator", "text": "main(void)", "parent": 16, "children": [19, 20], "start_point": {"row": 8, "column": 4}, "end_point": {"row": 8, "column": 14}}, {"id": 19, "type": "identifier", "text": "main", "parent": 18, "children": [], "start_point": {"row": 8, "column": 4}, "end_point": {"row": 8, "column": 8}}, {"id": 20, "type": "parameter_list", "text": "(void)", "parent": 18, "children": [21], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 14}}, {"id": 21, "type": "parameter_declaration", "text": "void", "parent": 20, "children": [22], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 13}}, {"id": 22, "type": "primitive_type", "text": "void", "parent": 21, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 13}}, {"id": 23, "type": "declaration", "text": "int x;", "parent": 16, "children": [24, 25], "start_point": {"row": 9, "column": 2}, "end_point": {"row": 9, "column": 8}}, {"id": 24, "type": "primitive_type", "text": "int", "parent": 23, "children": [], "start_point": {"row": 9, "column": 2}, "end_point": {"row": 9, "column": 5}}, {"id": 25, "type": "identifier", "text": "x", "parent": 23, "children": [], "start_point": {"row": 9, "column": 6}, "end_point": {"row": 9, "column": 7}}, {"id": 26, "type": "declaration", "text": "int *y;", "parent": 16, "children": [27, 28], "start_point": {"row": 10, "column": 2}, "end_point": {"row": 10, "column": 9}}, {"id": 27, "type": "primitive_type", "text": "int", "parent": 26, "children": [], "start_point": {"row": 10, "column": 2}, "end_point": {"row": 10, "column": 5}}, {"id": 28, "type": "pointer_declarator", "text": "*y", "parent": 26, "children": [29, 30], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 8}}, {"id": 29, "type": "*", "text": "*", "parent": 28, "children": [], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 7}}, {"id": 30, "type": "identifier", "text": "y", "parent": 28, "children": [], "start_point": {"row": 10, "column": 7}, "end_point": {"row": 10, "column": 8}}, {"id": 31, "type": "assignment_expression", "text": "x=1", "parent": 16, "children": [32, 33, 34], "start_point": {"row": 12, "column": 2}, "end_point": {"row": 12, "column": 5}}, {"id": 32, "type": "identifier", "text": "x", "parent": 31, "children": [], "start_point": {"row": 12, "column": 2}, "end_point": {"row": 12, "column": 3}}, {"id": 33, "type": "=", "text": "=", "parent": 31, "children": [], "start_point": {"row": 12, "column": 3}, "end_point": {"row": 12, "column": 4}}, {"id": 34, "type": "number_literal", "text": "1", "parent": 31, "children": [], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 5}}, {"id": 35, "type": "assignment_expression", "text": "y=&x", "parent": 16, "children": [36, 37, 38], "start_point": {"row": 13, "column": 2}, "end_point": {"row": 13, "column": 6}}, {"id": 36, "type": "identifier", "text": "y", "parent": 35, "children": [], "start_point": {"row": 13, "column": 2}, "end_point": {"row": 13, "column": 3}}, {"id": 37, "type": "=", "text": "=", "parent": 35, "children": [], "start_point": {"row": 13, "column": 3}, "end_point": {"row": 13, "column": 4}}, {"id": 38, "type": "pointer_expression", "text": "&x", "parent": 35, "children": [39], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 6}}, {"id": 39, "type": "identifier", "text": "x", "parent": 38, "children": [], "start_point": {"row": 13, "column": 5}, "end_point": {"row": 13, "column": 6}}, {"id": 40, "type": "call_expression", "text": "printf(\"Address of x = %d, value of x = %d\\n\", &x, x)", "parent": 16, "children": [41, 42], "start_point": {"row": 14, "column": 2}, "end_point": {"row": 14, "column": 55}}, {"id": 41, "type": "identifier", "text": "printf", "parent": 40, "children": [], "start_point": {"row": 14, "column": 2}, "end_point": {"row": 14, "column": 8}}, {"id": 42, "type": "argument_list", "text": "(\"Address of x = %d, value of x = %d\\n\", &x, x)", "parent": 40, "children": [43, 45, 47], "start_point": {"row": 14, "column": 8}, "end_point": {"row": 14, "column": 55}}, {"id": 43, "type": "string_literal", "text": "\"Address of x = %d, value of x = %d\\n\"", "parent": 42, "children": [44], "start_point": {"row": 14, "column": 9}, "end_point": {"row": 14, "column": 47}}, {"id": 44, "type": "escape_sequence", "text": "\\n", "parent": 43, "children": [], "start_point": {"row": 14, "column": 44}, "end_point": {"row": 14, "column": 46}}, {"id": 45, "type": "pointer_expression", "text": "&x", "parent": 42, "children": [46], "start_point": {"row": 14, "column": 49}, "end_point": {"row": 14, "column": 51}}, {"id": 46, "type": "identifier", "text": "x", "parent": 45, "children": [], "start_point": {"row": 14, "column": 50}, "end_point": {"row": 14, "column": 51}}, {"id": 47, "type": "identifier", "text": "x", "parent": 42, "children": [], "start_point": {"row": 14, "column": 53}, "end_point": {"row": 14, "column": 54}}, {"id": 48, "type": "call_expression", "text": "printf(\"Address of y = %d, value of y = %d, value of *y = %d\\n\", &y, y, *y)", "parent": 16, "children": [49, 50], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 77}}, {"id": 49, "type": "identifier", "text": "printf", "parent": 48, "children": [], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 8}}, {"id": 50, "type": "argument_list", "text": "(\"Address of y = %d, value of y = %d, value of *y = %d\\n\", &y, y, *y)", "parent": 48, "children": [51, 53, 55, 56], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 77}}, {"id": 51, "type": "string_literal", "text": "\"Address of y = %d, value of y = %d, value of *y = %d\\n\"", "parent": 50, "children": [52], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 65}}, {"id": 52, "type": "escape_sequence", "text": "\\n", "parent": 51, "children": [], "start_point": {"row": 15, "column": 62}, "end_point": {"row": 15, "column": 64}}, {"id": 53, "type": "pointer_expression", "text": "&y", "parent": 50, "children": [54], "start_point": {"row": 15, "column": 67}, "end_point": {"row": 15, "column": 69}}, {"id": 54, "type": "identifier", "text": "y", "parent": 53, "children": [], "start_point": {"row": 15, "column": 68}, "end_point": {"row": 15, "column": 69}}, {"id": 55, "type": "identifier", "text": "y", "parent": 50, "children": [], "start_point": {"row": 15, "column": 71}, "end_point": {"row": 15, "column": 72}}, {"id": 56, "type": "pointer_expression", "text": "*y", "parent": 50, "children": [57, 58], "start_point": {"row": 15, "column": 74}, "end_point": {"row": 15, "column": 76}}, {"id": 57, "type": "*", "text": "*", "parent": 56, "children": [], "start_point": {"row": 15, "column": 74}, "end_point": {"row": 15, "column": 75}}, {"id": 58, "type": "identifier", "text": "y", "parent": 56, "children": [], "start_point": {"row": 15, "column": 75}, "end_point": {"row": 15, "column": 76}}, {"id": 59, "type": "call_expression", "text": "moo(9,y)", "parent": 16, "children": [60, 61], "start_point": {"row": 16, "column": 2}, "end_point": {"row": 16, "column": 10}}, {"id": 60, "type": "identifier", "text": "moo", "parent": 59, "children": [], "start_point": {"row": 16, "column": 2}, "end_point": {"row": 16, "column": 5}}, {"id": 61, "type": "argument_list", "text": "(9,y)", "parent": 59, "children": [62, 63], "start_point": {"row": 16, "column": 5}, "end_point": {"row": 16, "column": 10}}, {"id": 62, "type": "number_literal", "text": "9", "parent": 61, "children": [], "start_point": {"row": 16, "column": 6}, "end_point": {"row": 16, "column": 7}}, {"id": 63, "type": "identifier", "text": "y", "parent": 61, "children": [], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 9}}, {"id": 64, "type": "function_definition", "text": "void moo(int a, int *b){\n printf(\"Address of a = %d, value of a = %d\\n\", &a, a);\n printf(\"Address of b = %d, value of b = %d, value of *b = %d\\n\", &b, b, *b);\n}", "parent": null, "children": [65, 66], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 22, "column": 1}}, {"id": 65, "type": "primitive_type", "text": "void", "parent": 64, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 4}}, {"id": 66, "type": "function_declarator", "text": "moo(int a, int *b)", "parent": 64, "children": [67, 68], "start_point": {"row": 19, "column": 5}, "end_point": {"row": 19, "column": 23}}, {"id": 67, "type": "identifier", "text": "moo", "parent": 66, "children": [], "start_point": {"row": 19, "column": 5}, "end_point": {"row": 19, "column": 8}}, {"id": 68, "type": "parameter_list", "text": "(int a, int *b)", "parent": 66, "children": [69, 72], "start_point": {"row": 19, "column": 8}, "end_point": {"row": 19, "column": 23}}, {"id": 69, "type": "parameter_declaration", "text": "int a", "parent": 68, "children": [70, 71], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 14}}, {"id": 70, "type": "primitive_type", "text": "int", "parent": 69, "children": [], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 12}}, {"id": 71, "type": "identifier", "text": "a", "parent": 69, "children": [], "start_point": {"row": 19, "column": 13}, "end_point": {"row": 19, "column": 14}}, {"id": 72, "type": "parameter_declaration", "text": "int *b", "parent": 68, "children": [73, 74], "start_point": {"row": 19, "column": 16}, "end_point": {"row": 19, "column": 22}}, {"id": 73, "type": "primitive_type", "text": "int", "parent": 72, "children": [], "start_point": {"row": 19, "column": 16}, "end_point": {"row": 19, "column": 19}}, {"id": 74, "type": "pointer_declarator", "text": "*b", "parent": 72, "children": [75, 76], "start_point": {"row": 19, "column": 20}, "end_point": {"row": 19, "column": 22}}, {"id": 75, "type": "*", "text": "*", "parent": 74, "children": [], "start_point": {"row": 19, "column": 20}, "end_point": {"row": 19, "column": 21}}, {"id": 76, "type": "identifier", "text": "b", "parent": 74, "children": [], "start_point": {"row": 19, "column": 21}, "end_point": {"row": 19, "column": 22}}, {"id": 77, "type": "call_expression", "text": "printf(\"Address of a = %d, value of a = %d\\n\", &a, a)", "parent": 64, "children": [78, 79], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 55}}, {"id": 78, "type": "identifier", "text": "printf", "parent": 77, "children": [], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 8}}, {"id": 79, "type": "argument_list", "text": "(\"Address of a = %d, value of a = %d\\n\", &a, a)", "parent": 77, "children": [80, 82, 84], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 55}}, {"id": 80, "type": "string_literal", "text": "\"Address of a = %d, value of a = %d\\n\"", "parent": 79, "children": [81], "start_point": {"row": 20, "column": 9}, "end_point": {"row": 20, "column": 47}}, {"id": 81, "type": "escape_sequence", "text": "\\n", "parent": 80, "children": [], "start_point": {"row": 20, "column": 44}, "end_point": {"row": 20, "column": 46}}, {"id": 82, "type": "pointer_expression", "text": "&a", "parent": 79, "children": [83], "start_point": {"row": 20, "column": 49}, "end_point": {"row": 20, "column": 51}}, {"id": 83, "type": "identifier", "text": "a", "parent": 82, "children": [], "start_point": {"row": 20, "column": 50}, "end_point": {"row": 20, "column": 51}}, {"id": 84, "type": "identifier", "text": "a", "parent": 79, "children": [], "start_point": {"row": 20, "column": 53}, "end_point": {"row": 20, "column": 54}}, {"id": 85, "type": "call_expression", "text": "printf(\"Address of b = %d, value of b = %d, value of *b = %d\\n\", &b, b, *b)", "parent": 64, "children": [86, 87], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 77}}, {"id": 86, "type": "identifier", "text": "printf", "parent": 85, "children": [], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 8}}, {"id": 87, "type": "argument_list", "text": "(\"Address of b = %d, value of b = %d, value of *b = %d\\n\", &b, b, *b)", "parent": 85, "children": [88, 90, 92, 93], "start_point": {"row": 21, "column": 8}, "end_point": {"row": 21, "column": 77}}, {"id": 88, "type": "string_literal", "text": "\"Address of b = %d, value of b = %d, value of *b = %d\\n\"", "parent": 87, "children": [89], "start_point": {"row": 21, "column": 9}, "end_point": {"row": 21, "column": 65}}, {"id": 89, "type": "escape_sequence", "text": "\\n", "parent": 88, "children": [], "start_point": {"row": 21, "column": 62}, "end_point": {"row": 21, "column": 64}}, {"id": 90, "type": "pointer_expression", "text": "&b", "parent": 87, "children": [91], "start_point": {"row": 21, "column": 67}, "end_point": {"row": 21, "column": 69}}, {"id": 91, "type": "identifier", "text": "b", "parent": 90, "children": [], "start_point": {"row": 21, "column": 68}, "end_point": {"row": 21, "column": 69}}, {"id": 92, "type": "identifier", "text": "b", "parent": 87, "children": [], "start_point": {"row": 21, "column": 71}, "end_point": {"row": 21, "column": 72}}, {"id": 93, "type": "pointer_expression", "text": "*b", "parent": 87, "children": [94, 95], "start_point": {"row": 21, "column": 74}, "end_point": {"row": 21, "column": 76}}, {"id": 94, "type": "*", "text": "*", "parent": 93, "children": [], "start_point": {"row": 21, "column": 74}, "end_point": {"row": 21, "column": 75}}, {"id": 95, "type": "identifier", "text": "b", "parent": 93, "children": [], "start_point": {"row": 21, "column": 75}, "end_point": {"row": 21, "column": 76}}]}, "node_categories": {"declarations": {"functions": [5, 16, 18, 64, 66], "variables": [3, 8, 11, 21, 23, 26, 69, 72], "classes": [], "imports": [0, 1], "modules": [], "enums": []}, "statements": {"expressions": [38, 40, 45, 48, 53, 56, 59, 77, 82, 85, 90, 93], "assignments": [31, 35], "loops": [], "conditionals": [6, 10, 15, 19, 25, 30, 32, 36, 39, 41, 46, 47, 49, 54, 55, 58, 60, 63, 67, 71, 76, 78, 83, 84, 86, 91, 92, 95], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 34, 43, 51, 62, 80, 88], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 5, "universal_type": "function", "name": "*", "text_snippet": "moo(int a, int * b)"}, {"node_id": 16, "universal_type": "function", "name": "main", "text_snippet": "int main(void) {\n int x;\n int *y;\n\n x=1;\n y=&x;\n printf(\"Address of x = %d, value of x = %d\\n\","}, {"node_id": 18, "universal_type": "function", "name": "unknown", "text_snippet": "main(void)"}, {"node_id": 64, "universal_type": "function", "name": "moo", "text_snippet": "void moo(int a, int *b){\n printf(\"Address of a = %d, value of a = %d\\n\", &a, a);\n printf(\"Address "}, {"node_id": 66, "universal_type": "function", "name": "*b)", "text_snippet": "moo(int a, int *b)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <stdio.h>\n"}, {"node_id": 1, "text": "#include"}]}, "original_source_code": "/* addresses.c -- Playing with addresses of variables and their contents:\n * what is done by C with variables, addresses, and values.\n */\n\n#include <stdio.h>\n\nvoid moo(int a, int * b);\n\nint main(void) {\n int x;\n int *y;\n\n x=1;\n y=&x;\n printf(\"Address of x = %d, value of x = %d\\n\", &x, x);\n printf(\"Address of y = %d, value of y = %d, value of *y = %d\\n\", &y, y, *y);\n moo(9,y);\n}\n\nvoid moo(int a, int *b){\n printf(\"Address of a = %d, value of a = %d\\n\", &a, a);\n printf(\"Address of b = %d, value of b = %d, value of *b = %d\\n\", &b, b, *b);\n}\n\n/* Output from running this program on my computer:\n\nAddress of x = 536869640, value of x = 1\nAddress of y = 536869632, value of y = 536869640, value of *y = 1\nAddress of a = 536869608, value of a = 9\nAddress of b = 536869600, value of b = 536869640, value of *b = 1\n\n */\n"}
80,505
c
// // Generated by class-dump 3.5 (64 bit). // // class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2013 by <NAME>. // #import "JPFReceivedPacket.h" @interface JPFAck : JPFReceivedPacket { unsigned char _reqCmd; unsigned char _stepCode; unsigned char _statusCode; unsigned long long _timestamp; } @property(readonly, nonatomic) unsigned long long timestamp; // @synthesize timestamp=_timestamp; @property(readonly, nonatomic) unsigned char statusCode; // @synthesize statusCode=_statusCode; @property(readonly, nonatomic) unsigned char stepCode; // @synthesize stepCode=_stepCode; @property(readonly, nonatomic) unsigned char reqCmd; // @synthesize reqCmd=_reqCmd; - (void)handleReceipt; - (id)initWithBuffer:(const char *)arg1 length:(unsigned short)arg2; @end
38.55
20
(translation_unit) "//\n// Generated by class-dump 3.5 (64 bit).\n//\n// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2013 by <NAME>.\n//\n\n#import "JPFReceivedPacket.h"\n\n@interface JPFAck : JPFReceivedPacket\n{\n unsigned char _reqCmd;\n unsigned char _stepCode;\n unsigned char _statusCode;\n unsigned long long _timestamp;\n}\n\n@property(readonly, nonatomic) unsigned long long timestamp; // @synthesize timestamp=_timestamp;\n@property(readonly, nonatomic) unsigned char statusCode; // @synthesize statusCode=_statusCode;\n@property(readonly, nonatomic) unsigned char stepCode; // @synthesize stepCode=_stepCode;\n@property(readonly, nonatomic) unsigned char reqCmd; // @synthesize reqCmd=_reqCmd;\n- (void)handleReceipt;\n- (id)initWithBuffer:(const char *)arg1 length:(unsigned short)arg2;\n\n@end\n\n" (comment) "//" (comment) "// Generated by class-dump 3.5 (64 bit)." (comment) "//" (comment) "// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2013 by <NAME>." (comment) "//" (preproc_call) "#import "JPFReceivedPacket.h"\n" (preproc_directive) "#import" (preproc_arg) ""JPFReceivedPacket.h"" (ERROR) "@" (ERROR) "@" (function_definition) "interface JPFAck : JPFReceivedPacket\n{\n unsigned char _reqCmd;\n unsigned char _stepCode;\n unsigned char _statusCode;\n unsigned long long _timestamp;\n}" (type_identifier) "interface" (ERROR) "JPFAck :" (identifier) "JPFAck" (:) ":" (identifier) "JPFReceivedPacket" (compound_statement) "{\n unsigned char _reqCmd;\n unsigned char _stepCode;\n unsigned char _statusCode;\n unsigned long long _timestamp;\n}" ({) "{" (declaration) "unsigned char _reqCmd;" (sized_type_specifier) "unsigned char" (unsigned) "unsigned" (primitive_type) "char" (identifier) "_reqCmd" (;) ";" (declaration) "unsigned char _stepCode;" (sized_type_specifier) "unsigned char" (unsigned) "unsigned" (primitive_type) "char" (identifier) "_stepCode" (;) ";" (declaration) "unsigned char _statusCode;" (sized_type_specifier) "unsigned char" (unsigned) "unsigned" (primitive_type) "char" (identifier) "_statusCode" (;) ";" (declaration) "unsigned long long _timestamp;" (sized_type_specifier) "unsigned long long" (unsigned) "unsigned" (long) "long" (long) "long" (identifier) "_timestamp" (;) ";" (}) "}" (ERROR) "@property(readonly, nonatomic) unsigned" (ERROR) "@" (call_expression) "property(readonly, nonatomic)" (identifier) "property" (argument_list) "(readonly, nonatomic)" (() "(" (identifier) "readonly" (,) "," (identifier) "nonatomic" ()) ")" (identifier) "unsigned" (declaration) "long long timestamp;" (sized_type_specifier) "long long" (long) "long" (long) "long" (identifier) "timestamp" (;) ";" (comment) "// @synthesize timestamp=_timestamp;" (ERROR) "@property(readonly, nonatomic) unsigned" (ERROR) "@" (call_expression) "property(readonly, nonatomic)" (identifier) "property" (argument_list) "(readonly, nonatomic)" (() "(" (identifier) "readonly" (,) "," (identifier) "nonatomic" ()) ")" (identifier) "unsigned" (declaration) "char statusCode;" (primitive_type) "char" (identifier) "statusCode" (;) ";" (comment) "// @synthesize statusCode=_statusCode;" (ERROR) "@property(readonly, nonatomic) unsigned" (ERROR) "@" (call_expression) "property(readonly, nonatomic)" (identifier) "property" (argument_list) "(readonly, nonatomic)" (() "(" (identifier) "readonly" (,) "," (identifier) "nonatomic" ()) ")" (identifier) "unsigned" (declaration) "char stepCode;" (primitive_type) "char" (identifier) "stepCode" (;) ";" (comment) "// @synthesize stepCode=_stepCode;" (ERROR) "@property(readonly, nonatomic) unsigned" (ERROR) "@" (call_expression) "property(readonly, nonatomic)" (identifier) "property" (argument_list) "(readonly, nonatomic)" (() "(" (identifier) "readonly" (,) "," (identifier) "nonatomic" ()) ")" (identifier) "unsigned" (declaration) "char reqCmd;" (primitive_type) "char" (identifier) "reqCmd" (;) ";" (comment) "// @synthesize reqCmd=_reqCmd;" (expression_statement) "- (void)handleReceipt;" (unary_expression) "- (void)handleReceipt" (-) "-" (cast_expression) "(void)handleReceipt" (() "(" (type_descriptor) "void" (primitive_type) "void" ()) ")" (identifier) "handleReceipt" (;) ";" (ERROR) "- (id)initWithBuffer:(" (unary_expression) "- (id)initWithBuffer" (-) "-" (cast_expression) "(id)initWithBuffer" (() "(" (type_descriptor) "id" (type_identifier) "id" ()) ")" (identifier) "initWithBuffer" (:) ":" (() "(" (declaration) "const char *)arg1" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "*)arg1" (*) "*" (ERROR) ")" ()) ")" (identifier) "arg1" (;) "" (labeled_statement) "length:(unsigned short)arg2;" (statement_identifier) "length" (:) ":" (expression_statement) "(unsigned short)arg2;" (cast_expression) "(unsigned short)arg2" (() "(" (type_descriptor) "unsigned short" (sized_type_specifier) "unsigned short" (unsigned) "unsigned" (short) "short" ()) ")" (identifier) "arg2" (;) ";" (ERROR) "@" (ERROR) "@" (expression_statement) "end" (identifier) "end" (;) ""
160
15
{"language": "c", "success": true, "metadata": {"lines": 20, "avg_line_length": 38.55, "nodes": 105, "errors": 0, "source_hash": "6d67f9574f4c7a6efc4441fe7d8b3c88626a217017e5cc0405e3c0e46715c130", "categorized_nodes": 59}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#import \"JPFReceivedPacket.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#import", "parent": 0, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "\"JPFReceivedPacket.h\"", "parent": 0, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 29}}, {"id": 3, "type": "ERROR", "text": "@", "parent": null, "children": [4], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 1}}, {"id": 4, "type": "ERROR", "text": "@", "parent": 3, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 1}}, {"id": 5, "type": "function_definition", "text": "interface JPFAck : JPFReceivedPacket\n{\n unsigned char _reqCmd;\n unsigned char _stepCode;\n unsigned char _statusCode;\n unsigned long long _timestamp;\n}", "parent": null, "children": [6, 7, 9], "start_point": {"row": 8, "column": 1}, "end_point": {"row": 14, "column": 1}}, {"id": 6, "type": "type_identifier", "text": "interface", "parent": 5, "children": [], "start_point": {"row": 8, "column": 1}, "end_point": {"row": 8, "column": 10}}, {"id": 7, "type": "ERROR", "text": "JPFAck :", "parent": 5, "children": [8], "start_point": {"row": 8, "column": 11}, "end_point": {"row": 8, "column": 19}}, {"id": 8, "type": "identifier", "text": "JPFAck", "parent": 7, "children": [], "start_point": {"row": 8, "column": 11}, "end_point": {"row": 8, "column": 17}}, {"id": 9, "type": "identifier", "text": "JPFReceivedPacket", "parent": 5, "children": [], "start_point": {"row": 8, "column": 20}, "end_point": {"row": 8, "column": 37}}, {"id": 10, "type": "declaration", "text": "unsigned char _reqCmd;", "parent": 5, "children": [11, 14], "start_point": {"row": 10, "column": 4}, "end_point": {"row": 10, "column": 26}}, {"id": 11, "type": "sized_type_specifier", "text": "unsigned char", "parent": 10, "children": [12, 13], "start_point": {"row": 10, "column": 4}, "end_point": {"row": 10, "column": 17}}, {"id": 12, "type": "unsigned", "text": "unsigned", "parent": 11, "children": [], "start_point": {"row": 10, "column": 4}, "end_point": {"row": 10, "column": 12}}, {"id": 13, "type": "primitive_type", "text": "char", "parent": 11, "children": [], "start_point": {"row": 10, "column": 13}, "end_point": {"row": 10, "column": 17}}, {"id": 14, "type": "identifier", "text": "_reqCmd", "parent": 10, "children": [], "start_point": {"row": 10, "column": 18}, "end_point": {"row": 10, "column": 25}}, {"id": 15, "type": "declaration", "text": "unsigned char _stepCode;", "parent": 5, "children": [16, 19], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 28}}, {"id": 16, "type": "sized_type_specifier", "text": "unsigned char", "parent": 15, "children": [17, 18], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 17}}, {"id": 17, "type": "unsigned", "text": "unsigned", "parent": 16, "children": [], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 12}}, {"id": 18, "type": "primitive_type", "text": "char", "parent": 16, "children": [], "start_point": {"row": 11, "column": 13}, "end_point": {"row": 11, "column": 17}}, {"id": 19, "type": "identifier", "text": "_stepCode", "parent": 15, "children": [], "start_point": {"row": 11, "column": 18}, "end_point": {"row": 11, "column": 27}}, {"id": 20, "type": "declaration", "text": "unsigned char _statusCode;", "parent": 5, "children": [21, 24], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 30}}, {"id": 21, "type": "sized_type_specifier", "text": "unsigned char", "parent": 20, "children": [22, 23], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 17}}, {"id": 22, "type": "unsigned", "text": "unsigned", "parent": 21, "children": [], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 12}}, {"id": 23, "type": "primitive_type", "text": "char", "parent": 21, "children": [], "start_point": {"row": 12, "column": 13}, "end_point": {"row": 12, "column": 17}}, {"id": 24, "type": "identifier", "text": "_statusCode", "parent": 20, "children": [], "start_point": {"row": 12, "column": 18}, "end_point": {"row": 12, "column": 29}}, {"id": 25, "type": "declaration", "text": "unsigned long long _timestamp;", "parent": 5, "children": [26, 30], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 34}}, {"id": 26, "type": "sized_type_specifier", "text": "unsigned long long", "parent": 25, "children": [27, 28, 29], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 22}}, {"id": 27, "type": "unsigned", "text": "unsigned", "parent": 26, "children": [], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 12}}, {"id": 28, "type": "long", "text": "long", "parent": 26, "children": [], "start_point": {"row": 13, "column": 13}, "end_point": {"row": 13, "column": 17}}, {"id": 29, "type": "long", "text": "long", "parent": 26, "children": [], "start_point": {"row": 13, "column": 18}, "end_point": {"row": 13, "column": 22}}, {"id": 30, "type": "identifier", "text": "_timestamp", "parent": 25, "children": [], "start_point": {"row": 13, "column": 23}, "end_point": {"row": 13, "column": 33}}, {"id": 31, "type": "ERROR", "text": "@property(readonly, nonatomic) unsigned", "parent": null, "children": [32, 33, 38], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 39}}, {"id": 32, "type": "ERROR", "text": "@", "parent": 31, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 1}}, {"id": 33, "type": "call_expression", "text": "property(readonly, nonatomic)", "parent": 31, "children": [34, 35], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 30}}, {"id": 34, "type": "identifier", "text": "property", "parent": 33, "children": [], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 9}}, {"id": 35, "type": "argument_list", "text": "(readonly, nonatomic)", "parent": 33, "children": [36, 37], "start_point": {"row": 16, "column": 9}, "end_point": {"row": 16, "column": 30}}, {"id": 36, "type": "identifier", "text": "readonly", "parent": 35, "children": [], "start_point": {"row": 16, "column": 10}, "end_point": {"row": 16, "column": 18}}, {"id": 37, "type": "identifier", "text": "nonatomic", "parent": 35, "children": [], "start_point": {"row": 16, "column": 20}, "end_point": {"row": 16, "column": 29}}, {"id": 38, "type": "identifier", "text": "unsigned", "parent": 31, "children": [], "start_point": {"row": 16, "column": 31}, "end_point": {"row": 16, "column": 39}}, {"id": 39, "type": "declaration", "text": "long long timestamp;", "parent": null, "children": [40, 43], "start_point": {"row": 16, "column": 40}, "end_point": {"row": 16, "column": 60}}, {"id": 40, "type": "sized_type_specifier", "text": "long long", "parent": 39, "children": [41, 42], "start_point": {"row": 16, "column": 40}, "end_point": {"row": 16, "column": 49}}, {"id": 41, "type": "long", "text": "long", "parent": 40, "children": [], "start_point": {"row": 16, "column": 40}, "end_point": {"row": 16, "column": 44}}, {"id": 42, "type": "long", "text": "long", "parent": 40, "children": [], "start_point": {"row": 16, "column": 45}, "end_point": {"row": 16, "column": 49}}, {"id": 43, "type": "identifier", "text": "timestamp", "parent": 39, "children": [], "start_point": {"row": 16, "column": 50}, "end_point": {"row": 16, "column": 59}}, {"id": 44, "type": "ERROR", "text": "@property(readonly, nonatomic) unsigned", "parent": null, "children": [45, 46, 51], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 39}}, {"id": 45, "type": "ERROR", "text": "@", "parent": 44, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 46, "type": "call_expression", "text": "property(readonly, nonatomic)", "parent": 44, "children": [47, 48], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 30}}, {"id": 47, "type": "identifier", "text": "property", "parent": 46, "children": [], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 9}}, {"id": 48, "type": "argument_list", "text": "(readonly, nonatomic)", "parent": 46, "children": [49, 50], "start_point": {"row": 17, "column": 9}, "end_point": {"row": 17, "column": 30}}, {"id": 49, "type": "identifier", "text": "readonly", "parent": 48, "children": [], "start_point": {"row": 17, "column": 10}, "end_point": {"row": 17, "column": 18}}, {"id": 50, "type": "identifier", "text": "nonatomic", "parent": 48, "children": [], "start_point": {"row": 17, "column": 20}, "end_point": {"row": 17, "column": 29}}, {"id": 51, "type": "identifier", "text": "unsigned", "parent": 44, "children": [], "start_point": {"row": 17, "column": 31}, "end_point": {"row": 17, "column": 39}}, {"id": 52, "type": "declaration", "text": "char statusCode;", "parent": null, "children": [53, 54], "start_point": {"row": 17, "column": 40}, "end_point": {"row": 17, "column": 56}}, {"id": 53, "type": "primitive_type", "text": "char", "parent": 52, "children": [], "start_point": {"row": 17, "column": 40}, "end_point": {"row": 17, "column": 44}}, {"id": 54, "type": "identifier", "text": "statusCode", "parent": 52, "children": [], "start_point": {"row": 17, "column": 45}, "end_point": {"row": 17, "column": 55}}, {"id": 55, "type": "ERROR", "text": "@property(readonly, nonatomic) unsigned", "parent": null, "children": [56, 57, 62], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 39}}, {"id": 56, "type": "ERROR", "text": "@", "parent": 55, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 1}}, {"id": 57, "type": "call_expression", "text": "property(readonly, nonatomic)", "parent": 55, "children": [58, 59], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 30}}, {"id": 58, "type": "identifier", "text": "property", "parent": 57, "children": [], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 9}}, {"id": 59, "type": "argument_list", "text": "(readonly, nonatomic)", "parent": 57, "children": [60, 61], "start_point": {"row": 18, "column": 9}, "end_point": {"row": 18, "column": 30}}, {"id": 60, "type": "identifier", "text": "readonly", "parent": 59, "children": [], "start_point": {"row": 18, "column": 10}, "end_point": {"row": 18, "column": 18}}, {"id": 61, "type": "identifier", "text": "nonatomic", "parent": 59, "children": [], "start_point": {"row": 18, "column": 20}, "end_point": {"row": 18, "column": 29}}, {"id": 62, "type": "identifier", "text": "unsigned", "parent": 55, "children": [], "start_point": {"row": 18, "column": 31}, "end_point": {"row": 18, "column": 39}}, {"id": 63, "type": "declaration", "text": "char stepCode;", "parent": null, "children": [64, 65], "start_point": {"row": 18, "column": 40}, "end_point": {"row": 18, "column": 54}}, {"id": 64, "type": "primitive_type", "text": "char", "parent": 63, "children": [], "start_point": {"row": 18, "column": 40}, "end_point": {"row": 18, "column": 44}}, {"id": 65, "type": "identifier", "text": "stepCode", "parent": 63, "children": [], "start_point": {"row": 18, "column": 45}, "end_point": {"row": 18, "column": 53}}, {"id": 66, "type": "ERROR", "text": "@property(readonly, nonatomic) unsigned", "parent": null, "children": [67, 68, 73], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 39}}, {"id": 67, "type": "ERROR", "text": "@", "parent": 66, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 1}}, {"id": 68, "type": "call_expression", "text": "property(readonly, nonatomic)", "parent": 66, "children": [69, 70], "start_point": {"row": 19, "column": 1}, "end_point": {"row": 19, "column": 30}}, {"id": 69, "type": "identifier", "text": "property", "parent": 68, "children": [], "start_point": {"row": 19, "column": 1}, "end_point": {"row": 19, "column": 9}}, {"id": 70, "type": "argument_list", "text": "(readonly, nonatomic)", "parent": 68, "children": [71, 72], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 30}}, {"id": 71, "type": "identifier", "text": "readonly", "parent": 70, "children": [], "start_point": {"row": 19, "column": 10}, "end_point": {"row": 19, "column": 18}}, {"id": 72, "type": "identifier", "text": "nonatomic", "parent": 70, "children": [], "start_point": {"row": 19, "column": 20}, "end_point": {"row": 19, "column": 29}}, {"id": 73, "type": "identifier", "text": "unsigned", "parent": 66, "children": [], "start_point": {"row": 19, "column": 31}, "end_point": {"row": 19, "column": 39}}, {"id": 74, "type": "declaration", "text": "char reqCmd;", "parent": null, "children": [75, 76], "start_point": {"row": 19, "column": 40}, "end_point": {"row": 19, "column": 52}}, {"id": 75, "type": "primitive_type", "text": "char", "parent": 74, "children": [], "start_point": {"row": 19, "column": 40}, "end_point": {"row": 19, "column": 44}}, {"id": 76, "type": "identifier", "text": "reqCmd", "parent": 74, "children": [], "start_point": {"row": 19, "column": 45}, "end_point": {"row": 19, "column": 51}}, {"id": 77, "type": "unary_expression", "text": "- (void)handleReceipt", "parent": null, "children": [78, 79], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 21}}, {"id": 78, "type": "-", "text": "-", "parent": 77, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 1}}, {"id": 79, "type": "cast_expression", "text": "(void)handleReceipt", "parent": 77, "children": [80, 82], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 21}}, {"id": 80, "type": "type_descriptor", "text": "void", "parent": 79, "children": [81], "start_point": {"row": 20, "column": 3}, "end_point": {"row": 20, "column": 7}}, {"id": 81, "type": "primitive_type", "text": "void", "parent": 80, "children": [], "start_point": {"row": 20, "column": 3}, "end_point": {"row": 20, "column": 7}}, {"id": 82, "type": "identifier", "text": "handleReceipt", "parent": 79, "children": [], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 21}}, {"id": 83, "type": "ERROR", "text": "- (id)initWithBuffer:(", "parent": null, "children": [84], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 22}}, {"id": 84, "type": "unary_expression", "text": "- (id)initWithBuffer", "parent": 83, "children": [85, 86], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 20}}, {"id": 85, "type": "-", "text": "-", "parent": 84, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 1}}, {"id": 86, "type": "cast_expression", "text": "(id)initWithBuffer", "parent": 84, "children": [87, 89], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 20}}, {"id": 87, "type": "type_descriptor", "text": "id", "parent": 86, "children": [88], "start_point": {"row": 21, "column": 3}, "end_point": {"row": 21, "column": 5}}, {"id": 88, "type": "type_identifier", "text": "id", "parent": 87, "children": [], "start_point": {"row": 21, "column": 3}, "end_point": {"row": 21, "column": 5}}, {"id": 89, "type": "identifier", "text": "initWithBuffer", "parent": 86, "children": [], "start_point": {"row": 21, "column": 6}, "end_point": {"row": 21, "column": 20}}, {"id": 90, "type": "declaration", "text": "const char *)arg1", "parent": null, "children": [91, 92], "start_point": {"row": 21, "column": 22}, "end_point": {"row": 21, "column": 39}}, {"id": 91, "type": "primitive_type", "text": "char", "parent": 90, "children": [], "start_point": {"row": 21, "column": 28}, "end_point": {"row": 21, "column": 32}}, {"id": 92, "type": "pointer_declarator", "text": "*)arg1", "parent": 90, "children": [93, 94], "start_point": {"row": 21, "column": 33}, "end_point": {"row": 21, "column": 39}}, {"id": 93, "type": "*", "text": "*", "parent": 92, "children": [], "start_point": {"row": 21, "column": 33}, "end_point": {"row": 21, "column": 34}}, {"id": 94, "type": "identifier", "text": "arg1", "parent": 92, "children": [], "start_point": {"row": 21, "column": 35}, "end_point": {"row": 21, "column": 39}}, {"id": 95, "type": "labeled_statement", "text": "length:(unsigned short)arg2;", "parent": null, "children": [96], "start_point": {"row": 21, "column": 40}, "end_point": {"row": 21, "column": 68}}, {"id": 96, "type": "statement_identifier", "text": "length", "parent": 95, "children": [], "start_point": {"row": 21, "column": 40}, "end_point": {"row": 21, "column": 46}}, {"id": 97, "type": "cast_expression", "text": "(unsigned short)arg2", "parent": 95, "children": [98, 102], "start_point": {"row": 21, "column": 47}, "end_point": {"row": 21, "column": 67}}, {"id": 98, "type": "type_descriptor", "text": "unsigned short", "parent": 97, "children": [99], "start_point": {"row": 21, "column": 48}, "end_point": {"row": 21, "column": 62}}, {"id": 99, "type": "sized_type_specifier", "text": "unsigned short", "parent": 98, "children": [100, 101], "start_point": {"row": 21, "column": 48}, "end_point": {"row": 21, "column": 62}}, {"id": 100, "type": "unsigned", "text": "unsigned", "parent": 99, "children": [], "start_point": {"row": 21, "column": 48}, "end_point": {"row": 21, "column": 56}}, {"id": 101, "type": "short", "text": "short", "parent": 99, "children": [], "start_point": {"row": 21, "column": 57}, "end_point": {"row": 21, "column": 62}}, {"id": 102, "type": "identifier", "text": "arg2", "parent": 97, "children": [], "start_point": {"row": 21, "column": 63}, "end_point": {"row": 21, "column": 67}}, {"id": 103, "type": "ERROR", "text": "@", "parent": null, "children": [104], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 1}}, {"id": 104, "type": "ERROR", "text": "@", "parent": 103, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 1}}]}, "node_categories": {"declarations": {"functions": [5], "variables": [10, 15, 20, 25, 39, 52, 63, 74, 90], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [33, 46, 57, 68, 77, 79, 84, 86, 97], "assignments": [], "loops": [], "conditionals": [6, 8, 9, 11, 14, 16, 19, 21, 24, 26, 30, 34, 36, 37, 38, 40, 43, 47, 49, 50, 51, 54, 58, 60, 61, 62, 65, 69, 71, 72, 73, 76, 82, 88, 89, 94, 96, 99, 102], "returns": [], "exceptions": []}, "expressions": {"calls": [0], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 5, "universal_type": "function", "name": "JPFAck", "text_snippet": "interface JPFAck : JPFReceivedPacket\n{\n unsigned char _reqCmd;\n unsigned char _stepCode;\n u"}], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// Generated by class-dump 3.5 (64 bit).\n//\n// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2013 by <NAME>.\n//\n\n#import \"JPFReceivedPacket.h\"\n\n@interface JPFAck : JPFReceivedPacket\n{\n unsigned char _reqCmd;\n unsigned char _stepCode;\n unsigned char _statusCode;\n unsigned long long _timestamp;\n}\n\n@property(readonly, nonatomic) unsigned long long timestamp; // @synthesize timestamp=_timestamp;\n@property(readonly, nonatomic) unsigned char statusCode; // @synthesize statusCode=_statusCode;\n@property(readonly, nonatomic) unsigned char stepCode; // @synthesize stepCode=_stepCode;\n@property(readonly, nonatomic) unsigned char reqCmd; // @synthesize reqCmd=_reqCmd;\n- (void)handleReceipt;\n- (id)initWithBuffer:(const char *)arg1 length:(unsigned short)arg2;\n\n@end\n\n"}
80,506
c
#include <stdio.h> #include <stdlib.h> int main() { int tam; int **matriz; printf("Digite o tamanho da matriz: "); scanf("%d", &tam); matriz = (int**) malloc(tam*sizeof(int*)); for(int i = 0; i < tam; i++) matriz[i] = (int*) malloc (tam*sizeof(int)); for(int i = 0; i < tam; i++) { for (int j = 0; j < tam; j++) { if(i == j) matriz[i][j] = 1; else matriz[i][j] = 0; } } for(int i = 0; i < tam; i++) { for (int j = 0; j < tam; j++) { printf("%d ", matriz[i][j]); } printf("\n"); } return 0; }
20.84
31
(translation_unit) "#include <stdio.h>\n#include <stdlib.h>\n\nint main()\n{\n int tam;\n int **matriz;\n\n printf("Digite o tamanho da matriz: ");\n scanf("%d", &tam);\n\n matriz = (int**) malloc(tam*sizeof(int*)); \n for(int i = 0; i < tam; i++)\n matriz[i] = (int*) malloc (tam*sizeof(int));\n\n for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n if(i == j)\n matriz[i][j] = 1;\n else\n matriz[i][j] = 0;\n }\n }\n\n for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n printf("%d ", matriz[i][j]);\n }\n printf("\n");\n }\n\n return 0;\n}" (preproc_include) "#include <stdio.h>\n" (#include) "#include" (system_lib_string) "<stdio.h>" (preproc_include) "#include <stdlib.h>\n" (#include) "#include" (system_lib_string) "<stdlib.h>" (function_definition) "int main()\n{\n int tam;\n int **matriz;\n\n printf("Digite o tamanho da matriz: ");\n scanf("%d", &tam);\n\n matriz = (int**) malloc(tam*sizeof(int*)); \n for(int i = 0; i < tam; i++)\n matriz[i] = (int*) malloc (tam*sizeof(int));\n\n for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n if(i == j)\n matriz[i][j] = 1;\n else\n matriz[i][j] = 0;\n }\n }\n\n for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n printf("%d ", matriz[i][j]);\n }\n printf("\n");\n }\n\n return 0;\n}" (primitive_type) "int" (function_declarator) "main()" (identifier) "main" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n int tam;\n int **matriz;\n\n printf("Digite o tamanho da matriz: ");\n scanf("%d", &tam);\n\n matriz = (int**) malloc(tam*sizeof(int*)); \n for(int i = 0; i < tam; i++)\n matriz[i] = (int*) malloc (tam*sizeof(int));\n\n for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n if(i == j)\n matriz[i][j] = 1;\n else\n matriz[i][j] = 0;\n }\n }\n\n for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n printf("%d ", matriz[i][j]);\n }\n printf("\n");\n }\n\n return 0;\n}" ({) "{" (declaration) "int tam;" (primitive_type) "int" (identifier) "tam" (;) ";" (declaration) "int **matriz;" (primitive_type) "int" (pointer_declarator) "**matriz" (*) "*" (pointer_declarator) "*matriz" (*) "*" (identifier) "matriz" (;) ";" (expression_statement) "printf("Digite o tamanho da matriz: ");" (call_expression) "printf("Digite o tamanho da matriz: ")" (identifier) "printf" (argument_list) "("Digite o tamanho da matriz: ")" (() "(" (string_literal) ""Digite o tamanho da matriz: "" (") """ (string_content) "Digite o tamanho da matriz: " (") """ ()) ")" (;) ";" (expression_statement) "scanf("%d", &tam);" (call_expression) "scanf("%d", &tam)" (identifier) "scanf" (argument_list) "("%d", &tam)" (() "(" (string_literal) ""%d"" (") """ (string_content) "%d" (") """ (,) "," (pointer_expression) "&tam" (&) "&" (identifier) "tam" ()) ")" (;) ";" (expression_statement) "matriz = (int**) malloc(tam*sizeof(int*));" (assignment_expression) "matriz = (int**) malloc(tam*sizeof(int*))" (identifier) "matriz" (=) "=" (cast_expression) "(int**) malloc(tam*sizeof(int*))" (() "(" (type_descriptor) "int**" (primitive_type) "int" (abstract_pointer_declarator) "**" (*) "*" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (call_expression) "malloc(tam*sizeof(int*))" (identifier) "malloc" (argument_list) "(tam*sizeof(int*))" (() "(" (binary_expression) "tam*sizeof(int*)" (identifier) "tam" (*) "*" (sizeof_expression) "sizeof(int*)" (sizeof) "sizeof" (() "(" (type_descriptor) "int*" (primitive_type) "int" (abstract_pointer_declarator) "*" (*) "*" ()) ")" ()) ")" (;) ";" (for_statement) "for(int i = 0; i < tam; i++)\n matriz[i] = (int*) malloc (tam*sizeof(int));" (for) "for" (() "(" (declaration) "int i = 0;" (primitive_type) "int" (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i < tam" (identifier) "i" (<) "<" (identifier) "tam" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (expression_statement) "matriz[i] = (int*) malloc (tam*sizeof(int));" (assignment_expression) "matriz[i] = (int*) malloc (tam*sizeof(int))" (subscript_expression) "matriz[i]" (identifier) "matriz" ([) "[" (identifier) "i" (]) "]" (=) "=" (cast_expression) "(int*) malloc (tam*sizeof(int))" (() "(" (type_descriptor) "int*" (primitive_type) "int" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (call_expression) "malloc (tam*sizeof(int))" (identifier) "malloc" (argument_list) "(tam*sizeof(int))" (() "(" (binary_expression) "tam*sizeof(int)" (identifier) "tam" (*) "*" (sizeof_expression) "sizeof(int)" (sizeof) "sizeof" (() "(" (type_descriptor) "int" (primitive_type) "int" ()) ")" ()) ")" (;) ";" (for_statement) "for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n if(i == j)\n matriz[i][j] = 1;\n else\n matriz[i][j] = 0;\n }\n }" (for) "for" (() "(" (declaration) "int i = 0;" (primitive_type) "int" (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i < tam" (identifier) "i" (<) "<" (identifier) "tam" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (compound_statement) "{\n for (int j = 0; j < tam; j++)\n {\n if(i == j)\n matriz[i][j] = 1;\n else\n matriz[i][j] = 0;\n }\n }" ({) "{" (for_statement) "for (int j = 0; j < tam; j++)\n {\n if(i == j)\n matriz[i][j] = 1;\n else\n matriz[i][j] = 0;\n }" (for) "for" (() "(" (declaration) "int j = 0;" (primitive_type) "int" (init_declarator) "j = 0" (identifier) "j" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "j < tam" (identifier) "j" (<) "<" (identifier) "tam" (;) ";" (update_expression) "j++" (identifier) "j" (++) "++" ()) ")" (compound_statement) "{\n if(i == j)\n matriz[i][j] = 1;\n else\n matriz[i][j] = 0;\n }" ({) "{" (if_statement) "if(i == j)\n matriz[i][j] = 1;\n else\n matriz[i][j] = 0;" (if) "if" (parenthesized_expression) "(i == j)" (() "(" (binary_expression) "i == j" (identifier) "i" (==) "==" (identifier) "j" ()) ")" (expression_statement) "matriz[i][j] = 1;" (assignment_expression) "matriz[i][j] = 1" (subscript_expression) "matriz[i][j]" (subscript_expression) "matriz[i]" (identifier) "matriz" ([) "[" (identifier) "i" (]) "]" ([) "[" (identifier) "j" (]) "]" (=) "=" (number_literal) "1" (;) ";" (else_clause) "else\n matriz[i][j] = 0;" (else) "else" (expression_statement) "matriz[i][j] = 0;" (assignment_expression) "matriz[i][j] = 0" (subscript_expression) "matriz[i][j]" (subscript_expression) "matriz[i]" (identifier) "matriz" ([) "[" (identifier) "i" (]) "]" ([) "[" (identifier) "j" (]) "]" (=) "=" (number_literal) "0" (;) ";" (}) "}" (}) "}" (for_statement) "for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n printf("%d ", matriz[i][j]);\n }\n printf("\n");\n }" (for) "for" (() "(" (declaration) "int i = 0;" (primitive_type) "int" (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i < tam" (identifier) "i" (<) "<" (identifier) "tam" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (compound_statement) "{\n for (int j = 0; j < tam; j++)\n {\n printf("%d ", matriz[i][j]);\n }\n printf("\n");\n }" ({) "{" (for_statement) "for (int j = 0; j < tam; j++)\n {\n printf("%d ", matriz[i][j]);\n }" (for) "for" (() "(" (declaration) "int j = 0;" (primitive_type) "int" (init_declarator) "j = 0" (identifier) "j" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "j < tam" (identifier) "j" (<) "<" (identifier) "tam" (;) ";" (update_expression) "j++" (identifier) "j" (++) "++" ()) ")" (compound_statement) "{\n printf("%d ", matriz[i][j]);\n }" ({) "{" (expression_statement) "printf("%d ", matriz[i][j]);" (call_expression) "printf("%d ", matriz[i][j])" (identifier) "printf" (argument_list) "("%d ", matriz[i][j])" (() "(" (string_literal) ""%d "" (") """ (string_content) "%d " (") """ (,) "," (subscript_expression) "matriz[i][j]" (subscript_expression) "matriz[i]" (identifier) "matriz" ([) "[" (identifier) "i" (]) "]" ([) "[" (identifier) "j" (]) "]" ()) ")" (;) ";" (}) "}" (expression_statement) "printf("\n");" (call_expression) "printf("\n")" (identifier) "printf" (argument_list) "("\n")" (() "(" (string_literal) ""\n"" (") """ (escape_sequence) "\n" (") """ ()) ")" (;) ";" (}) "}" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}"
297
0
{"language": "c", "success": true, "metadata": {"lines": 31, "avg_line_length": 20.84, "nodes": 180, "errors": 0, "source_hash": "f086ec01d76861762fa1f7630142fdef7392e86c63a7d640ca51b15a68567caa", "categorized_nodes": 116}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <stdio.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<stdio.h>", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 18}}, {"id": 3, "type": "preproc_include", "text": "#include <stdlib.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<stdlib.h>", "parent": 3, "children": [], "start_point": {"row": 1, "column": 9}, "end_point": {"row": 1, "column": 19}}, {"id": 6, "type": "function_definition", "text": "int main()\n{\n int tam;\n int **matriz;\n\n printf(\"Digite o tamanho da matriz: \");\n scanf(\"%d\", &tam);\n\n matriz = (int**) malloc(tam*sizeof(int*)); \n for(int i = 0; i < tam; i++)\n matriz[i] = (int*) malloc (tam*sizeof(int));\n\n for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n if(i == j)\n matriz[i][j] = 1;\n else\n matriz[i][j] = 0;\n }\n }\n\n for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n printf(\"%d \", matriz[i][j]);\n }\n printf(\"\\n\");\n }\n\n return 0;\n}", "parent": null, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 36, "column": 1}}, {"id": 7, "type": "primitive_type", "text": "int", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 3}}, {"id": 8, "type": "function_declarator", "text": "main()", "parent": 6, "children": [9, 10], "start_point": {"row": 3, "column": 4}, "end_point": {"row": 3, "column": 10}}, {"id": 9, "type": "identifier", "text": "main", "parent": 8, "children": [], "start_point": {"row": 3, "column": 4}, "end_point": {"row": 3, "column": 8}}, {"id": 10, "type": "parameter_list", "text": "()", "parent": 8, "children": [], "start_point": {"row": 3, "column": 8}, "end_point": {"row": 3, "column": 10}}, {"id": 11, "type": "declaration", "text": "int tam;", "parent": 6, "children": [12, 13], "start_point": {"row": 5, "column": 4}, "end_point": {"row": 5, "column": 12}}, {"id": 12, "type": "primitive_type", "text": "int", "parent": 11, "children": [], "start_point": {"row": 5, "column": 4}, "end_point": {"row": 5, "column": 7}}, {"id": 13, "type": "identifier", "text": "tam", "parent": 11, "children": [], "start_point": {"row": 5, "column": 8}, "end_point": {"row": 5, "column": 11}}, {"id": 14, "type": "declaration", "text": "int **matriz;", "parent": 6, "children": [15, 16], "start_point": {"row": 6, "column": 4}, "end_point": {"row": 6, "column": 17}}, {"id": 15, "type": "primitive_type", "text": "int", "parent": 14, "children": [], "start_point": {"row": 6, "column": 4}, "end_point": {"row": 6, "column": 7}}, {"id": 16, "type": "pointer_declarator", "text": "**matriz", "parent": 14, "children": [17, 18], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 16}}, {"id": 17, "type": "*", "text": "*", "parent": 16, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 9}}, {"id": 18, "type": "pointer_declarator", "text": "*matriz", "parent": 16, "children": [19, 20], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 16}}, {"id": 19, "type": "*", "text": "*", "parent": 18, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 10}}, {"id": 20, "type": "identifier", "text": "matriz", "parent": 18, "children": [], "start_point": {"row": 6, "column": 10}, "end_point": {"row": 6, "column": 16}}, {"id": 21, "type": "call_expression", "text": "printf(\"Digite o tamanho da matriz: \")", "parent": 6, "children": [22, 23], "start_point": {"row": 8, "column": 4}, "end_point": {"row": 8, "column": 42}}, {"id": 22, "type": "identifier", "text": "printf", "parent": 21, "children": [], "start_point": {"row": 8, "column": 4}, "end_point": {"row": 8, "column": 10}}, {"id": 23, "type": "argument_list", "text": "(\"Digite o tamanho da matriz: \")", "parent": 21, "children": [24], "start_point": {"row": 8, "column": 10}, "end_point": {"row": 8, "column": 42}}, {"id": 24, "type": "string_literal", "text": "\"Digite o tamanho da matriz: \"", "parent": 23, "children": [], "start_point": {"row": 8, "column": 11}, "end_point": {"row": 8, "column": 41}}, {"id": 25, "type": "call_expression", "text": "scanf(\"%d\", &tam)", "parent": 6, "children": [26, 27], "start_point": {"row": 9, "column": 4}, "end_point": {"row": 9, "column": 21}}, {"id": 26, "type": "identifier", "text": "scanf", "parent": 25, "children": [], "start_point": {"row": 9, "column": 4}, "end_point": {"row": 9, "column": 9}}, {"id": 27, "type": "argument_list", "text": "(\"%d\", &tam)", "parent": 25, "children": [28, 29], "start_point": {"row": 9, "column": 9}, "end_point": {"row": 9, "column": 21}}, {"id": 28, "type": "string_literal", "text": "\"%d\"", "parent": 27, "children": [], "start_point": {"row": 9, "column": 10}, "end_point": {"row": 9, "column": 14}}, {"id": 29, "type": "pointer_expression", "text": "&tam", "parent": 27, "children": [30], "start_point": {"row": 9, "column": 16}, "end_point": {"row": 9, "column": 20}}, {"id": 30, "type": "identifier", "text": "tam", "parent": 29, "children": [], "start_point": {"row": 9, "column": 17}, "end_point": {"row": 9, "column": 20}}, {"id": 31, "type": "assignment_expression", "text": "matriz = (int**) malloc(tam*sizeof(int*))", "parent": 6, "children": [32, 33, 34], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 45}}, {"id": 32, "type": "identifier", "text": "matriz", "parent": 31, "children": [], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 10}}, {"id": 33, "type": "=", "text": "=", "parent": 31, "children": [], "start_point": {"row": 11, "column": 11}, "end_point": {"row": 11, "column": 12}}, {"id": 34, "type": "cast_expression", "text": "(int**) malloc(tam*sizeof(int*))", "parent": 31, "children": [35, 41], "start_point": {"row": 11, "column": 13}, "end_point": {"row": 11, "column": 45}}, {"id": 35, "type": "type_descriptor", "text": "int**", "parent": 34, "children": [36, 37], "start_point": {"row": 11, "column": 14}, "end_point": {"row": 11, "column": 19}}, {"id": 36, "type": "primitive_type", "text": "int", "parent": 35, "children": [], "start_point": {"row": 11, "column": 14}, "end_point": {"row": 11, "column": 17}}, {"id": 37, "type": "abstract_pointer_declarator", "text": "**", "parent": 35, "children": [38, 39], "start_point": {"row": 11, "column": 17}, "end_point": {"row": 11, "column": 19}}, {"id": 38, "type": "*", "text": "*", "parent": 37, "children": [], "start_point": {"row": 11, "column": 17}, "end_point": {"row": 11, "column": 18}}, {"id": 39, "type": "abstract_pointer_declarator", "text": "*", "parent": 37, "children": [40], "start_point": {"row": 11, "column": 18}, "end_point": {"row": 11, "column": 19}}, {"id": 40, "type": "*", "text": "*", "parent": 39, "children": [], "start_point": {"row": 11, "column": 18}, "end_point": {"row": 11, "column": 19}}, {"id": 41, "type": "call_expression", "text": "malloc(tam*sizeof(int*))", "parent": 34, "children": [42, 43], "start_point": {"row": 11, "column": 21}, "end_point": {"row": 11, "column": 45}}, {"id": 42, "type": "identifier", "text": "malloc", "parent": 41, "children": [], "start_point": {"row": 11, "column": 21}, "end_point": {"row": 11, "column": 27}}, {"id": 43, "type": "argument_list", "text": "(tam*sizeof(int*))", "parent": 41, "children": [44], "start_point": {"row": 11, "column": 27}, "end_point": {"row": 11, "column": 45}}, {"id": 44, "type": "binary_expression", "text": "tam*sizeof(int*)", "parent": 43, "children": [45, 46, 47], "start_point": {"row": 11, "column": 28}, "end_point": {"row": 11, "column": 44}}, {"id": 45, "type": "identifier", "text": "tam", "parent": 44, "children": [], "start_point": {"row": 11, "column": 28}, "end_point": {"row": 11, "column": 31}}, {"id": 46, "type": "*", "text": "*", "parent": 44, "children": [], "start_point": {"row": 11, "column": 31}, "end_point": {"row": 11, "column": 32}}, {"id": 47, "type": "sizeof_expression", "text": "sizeof(int*)", "parent": 44, "children": [48], "start_point": {"row": 11, "column": 32}, "end_point": {"row": 11, "column": 44}}, {"id": 48, "type": "type_descriptor", "text": "int*", "parent": 47, "children": [49, 50], "start_point": {"row": 11, "column": 39}, "end_point": {"row": 11, "column": 43}}, {"id": 49, "type": "primitive_type", "text": "int", "parent": 48, "children": [], "start_point": {"row": 11, "column": 39}, "end_point": {"row": 11, "column": 42}}, {"id": 50, "type": "abstract_pointer_declarator", "text": "*", "parent": 48, "children": [51], "start_point": {"row": 11, "column": 42}, "end_point": {"row": 11, "column": 43}}, {"id": 51, "type": "*", "text": "*", "parent": 50, "children": [], "start_point": {"row": 11, "column": 42}, "end_point": {"row": 11, "column": 43}}, {"id": 52, "type": "for_statement", "text": "for(int i = 0; i < tam; i++)\n matriz[i] = (int*) malloc (tam*sizeof(int));", "parent": 6, "children": [53, 59, 63], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 13, "column": 52}}, {"id": 53, "type": "declaration", "text": "int i = 0;", "parent": 52, "children": [54, 55], "start_point": {"row": 12, "column": 8}, "end_point": {"row": 12, "column": 18}}, {"id": 54, "type": "primitive_type", "text": "int", "parent": 53, "children": [], "start_point": {"row": 12, "column": 8}, "end_point": {"row": 12, "column": 11}}, {"id": 55, "type": "init_declarator", "text": "i = 0", "parent": 53, "children": [56, 57, 58], "start_point": {"row": 12, "column": 12}, "end_point": {"row": 12, "column": 17}}, {"id": 56, "type": "identifier", "text": "i", "parent": 55, "children": [], "start_point": {"row": 12, "column": 12}, "end_point": {"row": 12, "column": 13}}, {"id": 57, "type": "=", "text": "=", "parent": 55, "children": [], "start_point": {"row": 12, "column": 14}, "end_point": {"row": 12, "column": 15}}, {"id": 58, "type": "number_literal", "text": "0", "parent": 55, "children": [], "start_point": {"row": 12, "column": 16}, "end_point": {"row": 12, "column": 17}}, {"id": 59, "type": "binary_expression", "text": "i < tam", "parent": 52, "children": [60, 61, 62], "start_point": {"row": 12, "column": 19}, "end_point": {"row": 12, "column": 26}}, {"id": 60, "type": "identifier", "text": "i", "parent": 59, "children": [], "start_point": {"row": 12, "column": 19}, "end_point": {"row": 12, "column": 20}}, {"id": 61, "type": "<", "text": "<", "parent": 59, "children": [], "start_point": {"row": 12, "column": 21}, "end_point": {"row": 12, "column": 22}}, {"id": 62, "type": "identifier", "text": "tam", "parent": 59, "children": [], "start_point": {"row": 12, "column": 23}, "end_point": {"row": 12, "column": 26}}, {"id": 63, "type": "update_expression", "text": "i++", "parent": 52, "children": [64, 65], "start_point": {"row": 12, "column": 28}, "end_point": {"row": 12, "column": 31}}, {"id": 64, "type": "identifier", "text": "i", "parent": 63, "children": [], "start_point": {"row": 12, "column": 28}, "end_point": {"row": 12, "column": 29}}, {"id": 65, "type": "++", "text": "++", "parent": 63, "children": [], "start_point": {"row": 12, "column": 29}, "end_point": {"row": 12, "column": 31}}, {"id": 66, "type": "assignment_expression", "text": "matriz[i] = (int*) malloc (tam*sizeof(int))", "parent": 52, "children": [67, 70, 71], "start_point": {"row": 13, "column": 8}, "end_point": {"row": 13, "column": 51}}, {"id": 67, "type": "subscript_expression", "text": "matriz[i]", "parent": 66, "children": [68, 69], "start_point": {"row": 13, "column": 8}, "end_point": {"row": 13, "column": 17}}, {"id": 68, "type": "identifier", "text": "matriz", "parent": 67, "children": [], "start_point": {"row": 13, "column": 8}, "end_point": {"row": 13, "column": 14}}, {"id": 69, "type": "identifier", "text": "i", "parent": 67, "children": [], "start_point": {"row": 13, "column": 15}, "end_point": {"row": 13, "column": 16}}, {"id": 70, "type": "=", "text": "=", "parent": 66, "children": [], "start_point": {"row": 13, "column": 18}, "end_point": {"row": 13, "column": 19}}, {"id": 71, "type": "cast_expression", "text": "(int*) malloc (tam*sizeof(int))", "parent": 66, "children": [72, 76], "start_point": {"row": 13, "column": 20}, "end_point": {"row": 13, "column": 51}}, {"id": 72, "type": "type_descriptor", "text": "int*", "parent": 71, "children": [73, 74], "start_point": {"row": 13, "column": 21}, "end_point": {"row": 13, "column": 25}}, {"id": 73, "type": "primitive_type", "text": "int", "parent": 72, "children": [], "start_point": {"row": 13, "column": 21}, "end_point": {"row": 13, "column": 24}}, {"id": 74, "type": "abstract_pointer_declarator", "text": "*", "parent": 72, "children": [75], "start_point": {"row": 13, "column": 24}, "end_point": {"row": 13, "column": 25}}, {"id": 75, "type": "*", "text": "*", "parent": 74, "children": [], "start_point": {"row": 13, "column": 24}, "end_point": {"row": 13, "column": 25}}, {"id": 76, "type": "call_expression", "text": "malloc (tam*sizeof(int))", "parent": 71, "children": [77, 78], "start_point": {"row": 13, "column": 27}, "end_point": {"row": 13, "column": 51}}, {"id": 77, "type": "identifier", "text": "malloc", "parent": 76, "children": [], "start_point": {"row": 13, "column": 27}, "end_point": {"row": 13, "column": 33}}, {"id": 78, "type": "argument_list", "text": "(tam*sizeof(int))", "parent": 76, "children": [79], "start_point": {"row": 13, "column": 34}, "end_point": {"row": 13, "column": 51}}, {"id": 79, "type": "binary_expression", "text": "tam*sizeof(int)", "parent": 78, "children": [80, 81, 82], "start_point": {"row": 13, "column": 35}, "end_point": {"row": 13, "column": 50}}, {"id": 80, "type": "identifier", "text": "tam", "parent": 79, "children": [], "start_point": {"row": 13, "column": 35}, "end_point": {"row": 13, "column": 38}}, {"id": 81, "type": "*", "text": "*", "parent": 79, "children": [], "start_point": {"row": 13, "column": 38}, "end_point": {"row": 13, "column": 39}}, {"id": 82, "type": "sizeof_expression", "text": "sizeof(int)", "parent": 79, "children": [83], "start_point": {"row": 13, "column": 39}, "end_point": {"row": 13, "column": 50}}, {"id": 83, "type": "type_descriptor", "text": "int", "parent": 82, "children": [84], "start_point": {"row": 13, "column": 46}, "end_point": {"row": 13, "column": 49}}, {"id": 84, "type": "primitive_type", "text": "int", "parent": 83, "children": [], "start_point": {"row": 13, "column": 46}, "end_point": {"row": 13, "column": 49}}, {"id": 85, "type": "for_statement", "text": "for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n if(i == j)\n matriz[i][j] = 1;\n else\n matriz[i][j] = 0;\n }\n }", "parent": 6, "children": [86, 92, 96], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 24, "column": 5}}, {"id": 86, "type": "declaration", "text": "int i = 0;", "parent": 85, "children": [87, 88], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 18}}, {"id": 87, "type": "primitive_type", "text": "int", "parent": 86, "children": [], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 11}}, {"id": 88, "type": "init_declarator", "text": "i = 0", "parent": 86, "children": [89, 90, 91], "start_point": {"row": 15, "column": 12}, "end_point": {"row": 15, "column": 17}}, {"id": 89, "type": "identifier", "text": "i", "parent": 88, "children": [], "start_point": {"row": 15, "column": 12}, "end_point": {"row": 15, "column": 13}}, {"id": 90, "type": "=", "text": "=", "parent": 88, "children": [], "start_point": {"row": 15, "column": 14}, "end_point": {"row": 15, "column": 15}}, {"id": 91, "type": "number_literal", "text": "0", "parent": 88, "children": [], "start_point": {"row": 15, "column": 16}, "end_point": {"row": 15, "column": 17}}, {"id": 92, "type": "binary_expression", "text": "i < tam", "parent": 85, "children": [93, 94, 95], "start_point": {"row": 15, "column": 19}, "end_point": {"row": 15, "column": 26}}, {"id": 93, "type": "identifier", "text": "i", "parent": 92, "children": [], "start_point": {"row": 15, "column": 19}, "end_point": {"row": 15, "column": 20}}, {"id": 94, "type": "<", "text": "<", "parent": 92, "children": [], "start_point": {"row": 15, "column": 21}, "end_point": {"row": 15, "column": 22}}, {"id": 95, "type": "identifier", "text": "tam", "parent": 92, "children": [], "start_point": {"row": 15, "column": 23}, "end_point": {"row": 15, "column": 26}}, {"id": 96, "type": "update_expression", "text": "i++", "parent": 85, "children": [97, 98], "start_point": {"row": 15, "column": 28}, "end_point": {"row": 15, "column": 31}}, {"id": 97, "type": "identifier", "text": "i", "parent": 96, "children": [], "start_point": {"row": 15, "column": 28}, "end_point": {"row": 15, "column": 29}}, {"id": 98, "type": "++", "text": "++", "parent": 96, "children": [], "start_point": {"row": 15, "column": 29}, "end_point": {"row": 15, "column": 31}}, {"id": 99, "type": "for_statement", "text": "for (int j = 0; j < tam; j++)\n {\n if(i == j)\n matriz[i][j] = 1;\n else\n matriz[i][j] = 0;\n }", "parent": 85, "children": [100, 106, 110], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 23, "column": 9}}, {"id": 100, "type": "declaration", "text": "int j = 0;", "parent": 99, "children": [101, 102], "start_point": {"row": 17, "column": 13}, "end_point": {"row": 17, "column": 23}}, {"id": 101, "type": "primitive_type", "text": "int", "parent": 100, "children": [], "start_point": {"row": 17, "column": 13}, "end_point": {"row": 17, "column": 16}}, {"id": 102, "type": "init_declarator", "text": "j = 0", "parent": 100, "children": [103, 104, 105], "start_point": {"row": 17, "column": 17}, "end_point": {"row": 17, "column": 22}}, {"id": 103, "type": "identifier", "text": "j", "parent": 102, "children": [], "start_point": {"row": 17, "column": 17}, "end_point": {"row": 17, "column": 18}}, {"id": 104, "type": "=", "text": "=", "parent": 102, "children": [], "start_point": {"row": 17, "column": 19}, "end_point": {"row": 17, "column": 20}}, {"id": 105, "type": "number_literal", "text": "0", "parent": 102, "children": [], "start_point": {"row": 17, "column": 21}, "end_point": {"row": 17, "column": 22}}, {"id": 106, "type": "binary_expression", "text": "j < tam", "parent": 99, "children": [107, 108, 109], "start_point": {"row": 17, "column": 24}, "end_point": {"row": 17, "column": 31}}, {"id": 107, "type": "identifier", "text": "j", "parent": 106, "children": [], "start_point": {"row": 17, "column": 24}, "end_point": {"row": 17, "column": 25}}, {"id": 108, "type": "<", "text": "<", "parent": 106, "children": [], "start_point": {"row": 17, "column": 26}, "end_point": {"row": 17, "column": 27}}, {"id": 109, "type": "identifier", "text": "tam", "parent": 106, "children": [], "start_point": {"row": 17, "column": 28}, "end_point": {"row": 17, "column": 31}}, {"id": 110, "type": "update_expression", "text": "j++", "parent": 99, "children": [111, 112], "start_point": {"row": 17, "column": 33}, "end_point": {"row": 17, "column": 36}}, {"id": 111, "type": "identifier", "text": "j", "parent": 110, "children": [], "start_point": {"row": 17, "column": 33}, "end_point": {"row": 17, "column": 34}}, {"id": 112, "type": "++", "text": "++", "parent": 110, "children": [], "start_point": {"row": 17, "column": 34}, "end_point": {"row": 17, "column": 36}}, {"id": 113, "type": "if_statement", "text": "if(i == j)\n matriz[i][j] = 1;\n else\n matriz[i][j] = 0;", "parent": 99, "children": [114, 127], "start_point": {"row": 19, "column": 12}, "end_point": {"row": 22, "column": 33}}, {"id": 114, "type": "parenthesized_expression", "text": "(i == j)", "parent": 113, "children": [115], "start_point": {"row": 19, "column": 14}, "end_point": {"row": 19, "column": 22}}, {"id": 115, "type": "binary_expression", "text": "i == j", "parent": 114, "children": [116, 117, 118], "start_point": {"row": 19, "column": 15}, "end_point": {"row": 19, "column": 21}}, {"id": 116, "type": "identifier", "text": "i", "parent": 115, "children": [], "start_point": {"row": 19, "column": 15}, "end_point": {"row": 19, "column": 16}}, {"id": 117, "type": "==", "text": "==", "parent": 115, "children": [], "start_point": {"row": 19, "column": 17}, "end_point": {"row": 19, "column": 19}}, {"id": 118, "type": "identifier", "text": "j", "parent": 115, "children": [], "start_point": {"row": 19, "column": 20}, "end_point": {"row": 19, "column": 21}}, {"id": 119, "type": "assignment_expression", "text": "matriz[i][j] = 1", "parent": 113, "children": [120, 125, 126], "start_point": {"row": 20, "column": 16}, "end_point": {"row": 20, "column": 32}}, {"id": 120, "type": "subscript_expression", "text": "matriz[i][j]", "parent": 119, "children": [121, 124], "start_point": {"row": 20, "column": 16}, "end_point": {"row": 20, "column": 28}}, {"id": 121, "type": "subscript_expression", "text": "matriz[i]", "parent": 120, "children": [122, 123], "start_point": {"row": 20, "column": 16}, "end_point": {"row": 20, "column": 25}}, {"id": 122, "type": "identifier", "text": "matriz", "parent": 121, "children": [], "start_point": {"row": 20, "column": 16}, "end_point": {"row": 20, "column": 22}}, {"id": 123, "type": "identifier", "text": "i", "parent": 121, "children": [], "start_point": {"row": 20, "column": 23}, "end_point": {"row": 20, "column": 24}}, {"id": 124, "type": "identifier", "text": "j", "parent": 120, "children": [], "start_point": {"row": 20, "column": 26}, "end_point": {"row": 20, "column": 27}}, {"id": 125, "type": "=", "text": "=", "parent": 119, "children": [], "start_point": {"row": 20, "column": 29}, "end_point": {"row": 20, "column": 30}}, {"id": 126, "type": "number_literal", "text": "1", "parent": 119, "children": [], "start_point": {"row": 20, "column": 31}, "end_point": {"row": 20, "column": 32}}, {"id": 127, "type": "else_clause", "text": "else\n matriz[i][j] = 0;", "parent": 113, "children": [], "start_point": {"row": 21, "column": 12}, "end_point": {"row": 22, "column": 33}}, {"id": 128, "type": "assignment_expression", "text": "matriz[i][j] = 0", "parent": 127, "children": [129, 134, 135], "start_point": {"row": 22, "column": 16}, "end_point": {"row": 22, "column": 32}}, {"id": 129, "type": "subscript_expression", "text": "matriz[i][j]", "parent": 128, "children": [130, 133], "start_point": {"row": 22, "column": 16}, "end_point": {"row": 22, "column": 28}}, {"id": 130, "type": "subscript_expression", "text": "matriz[i]", "parent": 129, "children": [131, 132], "start_point": {"row": 22, "column": 16}, "end_point": {"row": 22, "column": 25}}, {"id": 131, "type": "identifier", "text": "matriz", "parent": 130, "children": [], "start_point": {"row": 22, "column": 16}, "end_point": {"row": 22, "column": 22}}, {"id": 132, "type": "identifier", "text": "i", "parent": 130, "children": [], "start_point": {"row": 22, "column": 23}, "end_point": {"row": 22, "column": 24}}, {"id": 133, "type": "identifier", "text": "j", "parent": 129, "children": [], "start_point": {"row": 22, "column": 26}, "end_point": {"row": 22, "column": 27}}, {"id": 134, "type": "=", "text": "=", "parent": 128, "children": [], "start_point": {"row": 22, "column": 29}, "end_point": {"row": 22, "column": 30}}, {"id": 135, "type": "number_literal", "text": "0", "parent": 128, "children": [], "start_point": {"row": 22, "column": 31}, "end_point": {"row": 22, "column": 32}}, {"id": 136, "type": "for_statement", "text": "for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n printf(\"%d \", matriz[i][j]);\n }\n printf(\"\\n\");\n }", "parent": 6, "children": [137, 143, 147], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 33, "column": 5}}, {"id": 137, "type": "declaration", "text": "int i = 0;", "parent": 136, "children": [138, 139], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 18}}, {"id": 138, "type": "primitive_type", "text": "int", "parent": 137, "children": [], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 11}}, {"id": 139, "type": "init_declarator", "text": "i = 0", "parent": 137, "children": [140, 141, 142], "start_point": {"row": 26, "column": 12}, "end_point": {"row": 26, "column": 17}}, {"id": 140, "type": "identifier", "text": "i", "parent": 139, "children": [], "start_point": {"row": 26, "column": 12}, "end_point": {"row": 26, "column": 13}}, {"id": 141, "type": "=", "text": "=", "parent": 139, "children": [], "start_point": {"row": 26, "column": 14}, "end_point": {"row": 26, "column": 15}}, {"id": 142, "type": "number_literal", "text": "0", "parent": 139, "children": [], "start_point": {"row": 26, "column": 16}, "end_point": {"row": 26, "column": 17}}, {"id": 143, "type": "binary_expression", "text": "i < tam", "parent": 136, "children": [144, 145, 146], "start_point": {"row": 26, "column": 19}, "end_point": {"row": 26, "column": 26}}, {"id": 144, "type": "identifier", "text": "i", "parent": 143, "children": [], "start_point": {"row": 26, "column": 19}, "end_point": {"row": 26, "column": 20}}, {"id": 145, "type": "<", "text": "<", "parent": 143, "children": [], "start_point": {"row": 26, "column": 21}, "end_point": {"row": 26, "column": 22}}, {"id": 146, "type": "identifier", "text": "tam", "parent": 143, "children": [], "start_point": {"row": 26, "column": 23}, "end_point": {"row": 26, "column": 26}}, {"id": 147, "type": "update_expression", "text": "i++", "parent": 136, "children": [148, 149], "start_point": {"row": 26, "column": 28}, "end_point": {"row": 26, "column": 31}}, {"id": 148, "type": "identifier", "text": "i", "parent": 147, "children": [], "start_point": {"row": 26, "column": 28}, "end_point": {"row": 26, "column": 29}}, {"id": 149, "type": "++", "text": "++", "parent": 147, "children": [], "start_point": {"row": 26, "column": 29}, "end_point": {"row": 26, "column": 31}}, {"id": 150, "type": "for_statement", "text": "for (int j = 0; j < tam; j++)\n {\n printf(\"%d \", matriz[i][j]);\n }", "parent": 136, "children": [151, 157, 161], "start_point": {"row": 28, "column": 8}, "end_point": {"row": 31, "column": 9}}, {"id": 151, "type": "declaration", "text": "int j = 0;", "parent": 150, "children": [152, 153], "start_point": {"row": 28, "column": 13}, "end_point": {"row": 28, "column": 23}}, {"id": 152, "type": "primitive_type", "text": "int", "parent": 151, "children": [], "start_point": {"row": 28, "column": 13}, "end_point": {"row": 28, "column": 16}}, {"id": 153, "type": "init_declarator", "text": "j = 0", "parent": 151, "children": [154, 155, 156], "start_point": {"row": 28, "column": 17}, "end_point": {"row": 28, "column": 22}}, {"id": 154, "type": "identifier", "text": "j", "parent": 153, "children": [], "start_point": {"row": 28, "column": 17}, "end_point": {"row": 28, "column": 18}}, {"id": 155, "type": "=", "text": "=", "parent": 153, "children": [], "start_point": {"row": 28, "column": 19}, "end_point": {"row": 28, "column": 20}}, {"id": 156, "type": "number_literal", "text": "0", "parent": 153, "children": [], "start_point": {"row": 28, "column": 21}, "end_point": {"row": 28, "column": 22}}, {"id": 157, "type": "binary_expression", "text": "j < tam", "parent": 150, "children": [158, 159, 160], "start_point": {"row": 28, "column": 24}, "end_point": {"row": 28, "column": 31}}, {"id": 158, "type": "identifier", "text": "j", "parent": 157, "children": [], "start_point": {"row": 28, "column": 24}, "end_point": {"row": 28, "column": 25}}, {"id": 159, "type": "<", "text": "<", "parent": 157, "children": [], "start_point": {"row": 28, "column": 26}, "end_point": {"row": 28, "column": 27}}, {"id": 160, "type": "identifier", "text": "tam", "parent": 157, "children": [], "start_point": {"row": 28, "column": 28}, "end_point": {"row": 28, "column": 31}}, {"id": 161, "type": "update_expression", "text": "j++", "parent": 150, "children": [162, 163], "start_point": {"row": 28, "column": 33}, "end_point": {"row": 28, "column": 36}}, {"id": 162, "type": "identifier", "text": "j", "parent": 161, "children": [], "start_point": {"row": 28, "column": 33}, "end_point": {"row": 28, "column": 34}}, {"id": 163, "type": "++", "text": "++", "parent": 161, "children": [], "start_point": {"row": 28, "column": 34}, "end_point": {"row": 28, "column": 36}}, {"id": 164, "type": "call_expression", "text": "printf(\"%d \", matriz[i][j])", "parent": 150, "children": [165, 166], "start_point": {"row": 30, "column": 12}, "end_point": {"row": 30, "column": 39}}, {"id": 165, "type": "identifier", "text": "printf", "parent": 164, "children": [], "start_point": {"row": 30, "column": 12}, "end_point": {"row": 30, "column": 18}}, {"id": 166, "type": "argument_list", "text": "(\"%d \", matriz[i][j])", "parent": 164, "children": [167, 168], "start_point": {"row": 30, "column": 18}, "end_point": {"row": 30, "column": 39}}, {"id": 167, "type": "string_literal", "text": "\"%d \"", "parent": 166, "children": [], "start_point": {"row": 30, "column": 19}, "end_point": {"row": 30, "column": 24}}, {"id": 168, "type": "subscript_expression", "text": "matriz[i][j]", "parent": 166, "children": [169, 172], "start_point": {"row": 30, "column": 26}, "end_point": {"row": 30, "column": 38}}, {"id": 169, "type": "subscript_expression", "text": "matriz[i]", "parent": 168, "children": [170, 171], "start_point": {"row": 30, "column": 26}, "end_point": {"row": 30, "column": 35}}, {"id": 170, "type": "identifier", "text": "matriz", "parent": 169, "children": [], "start_point": {"row": 30, "column": 26}, "end_point": {"row": 30, "column": 32}}, {"id": 171, "type": "identifier", "text": "i", "parent": 169, "children": [], "start_point": {"row": 30, "column": 33}, "end_point": {"row": 30, "column": 34}}, {"id": 172, "type": "identifier", "text": "j", "parent": 168, "children": [], "start_point": {"row": 30, "column": 36}, "end_point": {"row": 30, "column": 37}}, {"id": 173, "type": "call_expression", "text": "printf(\"\\n\")", "parent": 136, "children": [174, 175], "start_point": {"row": 32, "column": 8}, "end_point": {"row": 32, "column": 20}}, {"id": 174, "type": "identifier", "text": "printf", "parent": 173, "children": [], "start_point": {"row": 32, "column": 8}, "end_point": {"row": 32, "column": 14}}, {"id": 175, "type": "argument_list", "text": "(\"\\n\")", "parent": 173, "children": [176], "start_point": {"row": 32, "column": 14}, "end_point": {"row": 32, "column": 20}}, {"id": 176, "type": "string_literal", "text": "\"\\n\"", "parent": 175, "children": [177], "start_point": {"row": 32, "column": 15}, "end_point": {"row": 32, "column": 19}}, {"id": 177, "type": "escape_sequence", "text": "\\n", "parent": 176, "children": [], "start_point": {"row": 32, "column": 16}, "end_point": {"row": 32, "column": 18}}, {"id": 178, "type": "return_statement", "text": "return 0;", "parent": 6, "children": [179], "start_point": {"row": 35, "column": 4}, "end_point": {"row": 35, "column": 13}}, {"id": 179, "type": "number_literal", "text": "0", "parent": 178, "children": [], "start_point": {"row": 35, "column": 11}, "end_point": {"row": 35, "column": 12}}]}, "node_categories": {"declarations": {"functions": [6, 8], "variables": [11, 14, 53, 86, 100, 137, 151], "classes": [], "imports": [0, 1, 3, 4], "modules": [], "enums": []}, "statements": {"expressions": [21, 25, 29, 34, 41, 44, 47, 59, 63, 67, 71, 76, 79, 82, 92, 96, 106, 110, 114, 115, 120, 121, 129, 130, 143, 147, 157, 161, 164, 168, 169, 173], "assignments": [31, 66, 119, 128], "loops": [52, 85, 99, 136, 150], "conditionals": [9, 13, 20, 22, 26, 30, 32, 42, 45, 56, 60, 62, 64, 68, 69, 77, 80, 89, 93, 95, 97, 103, 107, 109, 111, 113, 116, 118, 122, 123, 124, 131, 132, 133, 140, 144, 146, 148, 154, 158, 160, 162, 165, 170, 171, 172, 174], "returns": [178], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 24, 28, 58, 91, 105, 126, 135, 142, 156, 167, 176, 179], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 6, "universal_type": "function", "name": "main", "text_snippet": "int main()\n{\n int tam;\n int **matriz;\n\n printf(\"Digite o tamanho da matriz: \");\n scanf(\""}, {"node_id": 8, "universal_type": "function", "name": "unknown", "text_snippet": "main()"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <stdio.h>\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <stdlib.h>\n"}, {"node_id": 4, "text": "#include"}]}, "original_source_code": "#include <stdio.h>\n#include <stdlib.h>\n\nint main()\n{\n int tam;\n int **matriz;\n\n printf(\"Digite o tamanho da matriz: \");\n scanf(\"%d\", &tam);\n\n matriz = (int**) malloc(tam*sizeof(int*)); \n for(int i = 0; i < tam; i++)\n matriz[i] = (int*) malloc (tam*sizeof(int));\n\n for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n if(i == j)\n matriz[i][j] = 1;\n else\n matriz[i][j] = 0;\n }\n }\n\n for(int i = 0; i < tam; i++)\n {\n for (int j = 0; j < tam; j++)\n {\n printf(\"%d \", matriz[i][j]);\n }\n printf(\"\\n\");\n }\n\n return 0;\n}"}
80,507
c
#pragma once #include "EntityFunctions.h" #include "Node.h" #include "../vtable/vmthooks.h" #include "TString.h" namespace ProjectNovigrad { namespace TW3 { struct EntitySpawnParams { char v48; // [rsp+A0h] [rbp-60h] char v49; // [rsp+ACh] [rbp-54h] char v50; // [rsp+B8h] [rbp-48h] char v51; // [rsp+C8h] [rbp-38h] Vector position; // [rsp+F0h] [rbp-10h] EulerAngles direction; // [rsp+100h] [rbp+0h] int v54; // [rsp+108h] [rbp+8h] Vector v55; // [rsp+120h] [rbp+20h] int v56; // [rsp+130h] [rbp+30h] char v57; // [rsp+14Ah] [rbp+4Ah] char v58; // [rsp+150h] [rbp+50h] char v59; // [rsp+1A8h] [rbp+A8h] char v60; // [rsp+1B8h] [rbp+B8h] }; class __declspec(dllexport) CEntity { public: TString<wchar_t>* GetUniqueName(TString<wchar_t>* res) { utils::VtableHook hook(this); return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res); } TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res) { utils::VtableHook hook(this); return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res); } void* SetPosition(Vector* vec) { utils::VtableHook hook(this); return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec); } bool Teleport(Vector* vec, EulerAngles* angles) { utils::VtableHook hook(this); return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles); } Vector GetWorldPosition() { return *(Vector*)(this + 160); } }; } }
30.61
54
(translation_unit) "#pragma once\n\n#include "EntityFunctions.h"\n#include "Node.h"\n#include "../vtable/vmthooks.h"\n#include "TString.h"\n\nnamespace ProjectNovigrad\n{\n namespace TW3\n {\n struct EntitySpawnParams {\n char v48; // [rsp+A0h] [rbp-60h]\n char v49; // [rsp+ACh] [rbp-54h]\n char v50; // [rsp+B8h] [rbp-48h]\n char v51; // [rsp+C8h] [rbp-38h]\n Vector position; // [rsp+F0h] [rbp-10h]\n EulerAngles direction; // [rsp+100h] [rbp+0h]\n int v54; // [rsp+108h] [rbp+8h]\n Vector v55; // [rsp+120h] [rbp+20h]\n int v56; // [rsp+130h] [rbp+30h]\n char v57; // [rsp+14Ah] [rbp+4Ah]\n char v58; // [rsp+150h] [rbp+50h]\n char v59; // [rsp+1A8h] [rbp+A8h]\n char v60; // [rsp+1B8h] [rbp+B8h]\n };\n class __declspec(dllexport) CEntity\n {\n public:\n TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);\n }\n\n TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);\n }\n\n void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }\n\n bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }\n\n Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }\n };\n }\n}" (preproc_call) "#pragma once\n" (preproc_directive) "#pragma" (preproc_arg) "once" (preproc_include) "#include "EntityFunctions.h"\n" (#include) "#include" (string_literal) ""EntityFunctions.h"" (") """ (string_content) "EntityFunctions.h" (") """ (preproc_include) "#include "Node.h"\n" (#include) "#include" (string_literal) ""Node.h"" (") """ (string_content) "Node.h" (") """ (preproc_include) "#include "../vtable/vmthooks.h"\n" (#include) "#include" (string_literal) ""../vtable/vmthooks.h"" (") """ (string_content) "../vtable/vmthooks.h" (") """ (preproc_include) "#include "TString.h"\n" (#include) "#include" (string_literal) ""TString.h"" (") """ (string_content) "TString.h" (") """ (function_definition) "namespace ProjectNovigrad\n{\n namespace TW3\n {\n struct EntitySpawnParams {\n char v48; // [rsp+A0h] [rbp-60h]\n char v49; // [rsp+ACh] [rbp-54h]\n char v50; // [rsp+B8h] [rbp-48h]\n char v51; // [rsp+C8h] [rbp-38h]\n Vector position; // [rsp+F0h] [rbp-10h]\n EulerAngles direction; // [rsp+100h] [rbp+0h]\n int v54; // [rsp+108h] [rbp+8h]\n Vector v55; // [rsp+120h] [rbp+20h]\n int v56; // [rsp+130h] [rbp+30h]\n char v57; // [rsp+14Ah] [rbp+4Ah]\n char v58; // [rsp+150h] [rbp+50h]\n char v59; // [rsp+1A8h] [rbp+A8h]\n char v60; // [rsp+1B8h] [rbp+B8h]\n };\n class __declspec(dllexport) CEntity\n {\n public:\n TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);\n }\n\n TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);\n }\n\n void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }\n\n bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }\n\n Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }\n };\n }\n}" (type_identifier) "namespace" (identifier) "ProjectNovigrad" (compound_statement) "{\n namespace TW3\n {\n struct EntitySpawnParams {\n char v48; // [rsp+A0h] [rbp-60h]\n char v49; // [rsp+ACh] [rbp-54h]\n char v50; // [rsp+B8h] [rbp-48h]\n char v51; // [rsp+C8h] [rbp-38h]\n Vector position; // [rsp+F0h] [rbp-10h]\n EulerAngles direction; // [rsp+100h] [rbp+0h]\n int v54; // [rsp+108h] [rbp+8h]\n Vector v55; // [rsp+120h] [rbp+20h]\n int v56; // [rsp+130h] [rbp+30h]\n char v57; // [rsp+14Ah] [rbp+4Ah]\n char v58; // [rsp+150h] [rbp+50h]\n char v59; // [rsp+1A8h] [rbp+A8h]\n char v60; // [rsp+1B8h] [rbp+B8h]\n };\n class __declspec(dllexport) CEntity\n {\n public:\n TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);\n }\n\n TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);\n }\n\n void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }\n\n bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }\n\n Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }\n };\n }\n}" ({) "{" (function_definition) "namespace TW3\n {\n struct EntitySpawnParams {\n char v48; // [rsp+A0h] [rbp-60h]\n char v49; // [rsp+ACh] [rbp-54h]\n char v50; // [rsp+B8h] [rbp-48h]\n char v51; // [rsp+C8h] [rbp-38h]\n Vector position; // [rsp+F0h] [rbp-10h]\n EulerAngles direction; // [rsp+100h] [rbp+0h]\n int v54; // [rsp+108h] [rbp+8h]\n Vector v55; // [rsp+120h] [rbp+20h]\n int v56; // [rsp+130h] [rbp+30h]\n char v57; // [rsp+14Ah] [rbp+4Ah]\n char v58; // [rsp+150h] [rbp+50h]\n char v59; // [rsp+1A8h] [rbp+A8h]\n char v60; // [rsp+1B8h] [rbp+B8h]\n };\n class __declspec(dllexport) CEntity\n {\n public:\n TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);\n }\n\n TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);\n }\n\n void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }\n\n bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }\n\n Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }\n };\n }" (type_identifier) "namespace" (identifier) "TW3" (compound_statement) "{\n struct EntitySpawnParams {\n char v48; // [rsp+A0h] [rbp-60h]\n char v49; // [rsp+ACh] [rbp-54h]\n char v50; // [rsp+B8h] [rbp-48h]\n char v51; // [rsp+C8h] [rbp-38h]\n Vector position; // [rsp+F0h] [rbp-10h]\n EulerAngles direction; // [rsp+100h] [rbp+0h]\n int v54; // [rsp+108h] [rbp+8h]\n Vector v55; // [rsp+120h] [rbp+20h]\n int v56; // [rsp+130h] [rbp+30h]\n char v57; // [rsp+14Ah] [rbp+4Ah]\n char v58; // [rsp+150h] [rbp+50h]\n char v59; // [rsp+1A8h] [rbp+A8h]\n char v60; // [rsp+1B8h] [rbp+B8h]\n };\n class __declspec(dllexport) CEntity\n {\n public:\n TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);\n }\n\n TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);\n }\n\n void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }\n\n bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }\n\n Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }\n };\n }" ({) "{" (struct_specifier) "struct EntitySpawnParams {\n char v48; // [rsp+A0h] [rbp-60h]\n char v49; // [rsp+ACh] [rbp-54h]\n char v50; // [rsp+B8h] [rbp-48h]\n char v51; // [rsp+C8h] [rbp-38h]\n Vector position; // [rsp+F0h] [rbp-10h]\n EulerAngles direction; // [rsp+100h] [rbp+0h]\n int v54; // [rsp+108h] [rbp+8h]\n Vector v55; // [rsp+120h] [rbp+20h]\n int v56; // [rsp+130h] [rbp+30h]\n char v57; // [rsp+14Ah] [rbp+4Ah]\n char v58; // [rsp+150h] [rbp+50h]\n char v59; // [rsp+1A8h] [rbp+A8h]\n char v60; // [rsp+1B8h] [rbp+B8h]\n }" (struct) "struct" (type_identifier) "EntitySpawnParams" (field_declaration_list) "{\n char v48; // [rsp+A0h] [rbp-60h]\n char v49; // [rsp+ACh] [rbp-54h]\n char v50; // [rsp+B8h] [rbp-48h]\n char v51; // [rsp+C8h] [rbp-38h]\n Vector position; // [rsp+F0h] [rbp-10h]\n EulerAngles direction; // [rsp+100h] [rbp+0h]\n int v54; // [rsp+108h] [rbp+8h]\n Vector v55; // [rsp+120h] [rbp+20h]\n int v56; // [rsp+130h] [rbp+30h]\n char v57; // [rsp+14Ah] [rbp+4Ah]\n char v58; // [rsp+150h] [rbp+50h]\n char v59; // [rsp+1A8h] [rbp+A8h]\n char v60; // [rsp+1B8h] [rbp+B8h]\n }" ({) "{" (field_declaration) "char v48;" (primitive_type) "char" (field_identifier) "v48" (;) ";" (comment) "// [rsp+A0h] [rbp-60h]" (field_declaration) "char v49;" (primitive_type) "char" (field_identifier) "v49" (;) ";" (comment) "// [rsp+ACh] [rbp-54h]" (field_declaration) "char v50;" (primitive_type) "char" (field_identifier) "v50" (;) ";" (comment) "// [rsp+B8h] [rbp-48h]" (field_declaration) "char v51;" (primitive_type) "char" (field_identifier) "v51" (;) ";" (comment) "// [rsp+C8h] [rbp-38h]" (field_declaration) "Vector position;" (type_identifier) "Vector" (field_identifier) "position" (;) ";" (comment) "// [rsp+F0h] [rbp-10h]" (field_declaration) "EulerAngles direction;" (type_identifier) "EulerAngles" (field_identifier) "direction" (;) ";" (comment) "// [rsp+100h] [rbp+0h]" (field_declaration) "int v54;" (primitive_type) "int" (field_identifier) "v54" (;) ";" (comment) "// [rsp+108h] [rbp+8h]" (field_declaration) "Vector v55;" (type_identifier) "Vector" (field_identifier) "v55" (;) ";" (comment) "// [rsp+120h] [rbp+20h]" (field_declaration) "int v56;" (primitive_type) "int" (field_identifier) "v56" (;) ";" (comment) "// [rsp+130h] [rbp+30h]" (field_declaration) "char v57;" (primitive_type) "char" (field_identifier) "v57" (;) ";" (comment) "// [rsp+14Ah] [rbp+4Ah]" (field_declaration) "char v58;" (primitive_type) "char" (field_identifier) "v58" (;) ";" (comment) "// [rsp+150h] [rbp+50h]" (field_declaration) "char v59;" (primitive_type) "char" (field_identifier) "v59" (;) ";" (comment) "// [rsp+1A8h] [rbp+A8h]" (field_declaration) "char v60;" (primitive_type) "char" (field_identifier) "v60" (;) ";" (comment) "// [rsp+1B8h] [rbp+B8h]" (}) "}" (;) ";" (function_definition) "class __declspec(dllexport) CEntity\n {\n public:\n TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);\n }\n\n TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);\n }\n\n void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }\n\n bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }\n\n Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }\n }" (type_identifier) "class" (ms_declspec_modifier) "__declspec(dllexport)" (__declspec) "__declspec" (() "(" (identifier) "dllexport" ()) ")" (identifier) "CEntity" (compound_statement) "{\n public:\n TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);\n }\n\n TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);\n }\n\n void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }\n\n bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }\n\n Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }\n }" ({) "{" (labeled_statement) "public:\n TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)" (statement_identifier) "public" (:) ":" (expression_statement) "TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)" (binary_expression) "TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)" (binary_expression) "TString<wchar_t" (identifier) "TString" (<) "<" (identifier) "wchar_t" (>) ">" (pointer_expression) "* GetUniqueName(TString<wchar_t>* res)" (*) "*" (call_expression) "GetUniqueName(TString<wchar_t>* res)" (identifier) "GetUniqueName" (argument_list) "(TString<wchar_t>* res)" (() "(" (binary_expression) "TString<wchar_t>* res" (binary_expression) "TString<wchar_t" (identifier) "TString" (<) "<" (identifier) "wchar_t" (>) ">" (pointer_expression) "* res" (*) "*" (identifier) "res" ()) ")" (;) "" (compound_statement) "{\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);\n }" ({) "{" (labeled_statement) "utils::VtableHook hook(this);" (statement_identifier) "utils" (:) ":" (ERROR) ":" (:) ":" (declaration) "VtableHook hook(this);" (type_identifier) "VtableHook" (function_declarator) "hook(this)" (identifier) "hook" (parameter_list) "(this)" (() "(" (parameter_declaration) "this" (type_identifier) "this" ()) ")" (;) ";" (return_statement) "return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);" (return) "return" (binary_expression) "hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res)" (binary_expression) "hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)" (binary_expression) "hook.GetMethod<TString<wchar_t" (binary_expression) "hook.GetMethod<TString" (field_expression) "hook.GetMethod" (identifier) "hook" (.) "." (field_identifier) "GetMethod" (<) "<" (identifier) "TString" (<) "<" (identifier) "wchar_t" (>) ">" (pointer_expression) "* (__thiscall*)(void*, TString<wchar_t>*)" (*) "*" (cast_expression) "(__thiscall*)(void*, TString<wchar_t>*)" (() "(" (type_descriptor) "__thiscall*" (type_identifier) "__thiscall" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (parenthesized_expression) "(void*, TString<wchar_t>*)" (() "(" (ERROR) "void*," (type_descriptor) "void*" (primitive_type) "void" (abstract_pointer_declarator) "*" (*) "*" (,) "," (binary_expression) "TString<wchar_t>*" (binary_expression) "TString<wchar_t" (identifier) "TString" (<) "<" (identifier) "wchar_t" (>) ">" (pointer_expression) "*" (*) "*" (identifier) "" ()) ")" (>) ">" (call_expression) "(45)(this, res)" (parenthesized_expression) "(45)" (() "(" (number_literal) "45" ()) ")" (argument_list) "(this, res)" (() "(" (identifier) "this" (,) "," (identifier) "res" ()) ")" (;) ";" (}) "}" (expression_statement) "TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)" (binary_expression) "TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)" (binary_expression) "TString<wchar_t" (identifier) "TString" (<) "<" (identifier) "wchar_t" (>) ">" (pointer_expression) "* GetFriendlyName(TString<wchar_t>* res)" (*) "*" (call_expression) "GetFriendlyName(TString<wchar_t>* res)" (identifier) "GetFriendlyName" (argument_list) "(TString<wchar_t>* res)" (() "(" (binary_expression) "TString<wchar_t>* res" (binary_expression) "TString<wchar_t" (identifier) "TString" (<) "<" (identifier) "wchar_t" (>) ">" (pointer_expression) "* res" (*) "*" (identifier) "res" ()) ")" (;) "" (compound_statement) "{\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);\n }" ({) "{" (labeled_statement) "utils::VtableHook hook(this);" (statement_identifier) "utils" (:) ":" (ERROR) ":" (:) ":" (declaration) "VtableHook hook(this);" (type_identifier) "VtableHook" (function_declarator) "hook(this)" (identifier) "hook" (parameter_list) "(this)" (() "(" (parameter_declaration) "this" (type_identifier) "this" ()) ")" (;) ";" (return_statement) "return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);" (return) "return" (binary_expression) "hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res)" (binary_expression) "hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)" (binary_expression) "hook.GetMethod<TString<wchar_t" (binary_expression) "hook.GetMethod<TString" (field_expression) "hook.GetMethod" (identifier) "hook" (.) "." (field_identifier) "GetMethod" (<) "<" (identifier) "TString" (<) "<" (identifier) "wchar_t" (>) ">" (pointer_expression) "* (__thiscall*)(void*, TString<wchar_t>*)" (*) "*" (cast_expression) "(__thiscall*)(void*, TString<wchar_t>*)" (() "(" (type_descriptor) "__thiscall*" (type_identifier) "__thiscall" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (parenthesized_expression) "(void*, TString<wchar_t>*)" (() "(" (ERROR) "void*," (type_descriptor) "void*" (primitive_type) "void" (abstract_pointer_declarator) "*" (*) "*" (,) "," (binary_expression) "TString<wchar_t>*" (binary_expression) "TString<wchar_t" (identifier) "TString" (<) "<" (identifier) "wchar_t" (>) ">" (pointer_expression) "*" (*) "*" (identifier) "" ()) ")" (>) ">" (call_expression) "(27)(this, res)" (parenthesized_expression) "(27)" (() "(" (number_literal) "27" ()) ")" (argument_list) "(this, res)" (() "(" (identifier) "this" (,) "," (identifier) "res" ()) ")" (;) ";" (}) "}" (function_definition) "void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }" (primitive_type) "void" (pointer_declarator) "* SetPosition(Vector* vec)" (*) "*" (function_declarator) "SetPosition(Vector* vec)" (identifier) "SetPosition" (parameter_list) "(Vector* vec)" (() "(" (parameter_declaration) "Vector* vec" (type_identifier) "Vector" (pointer_declarator) "* vec" (*) "*" (identifier) "vec" ()) ")" (compound_statement) "{\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }" ({) "{" (labeled_statement) "utils::VtableHook hook(this);" (statement_identifier) "utils" (:) ":" (ERROR) ":" (:) ":" (declaration) "VtableHook hook(this);" (type_identifier) "VtableHook" (function_declarator) "hook(this)" (identifier) "hook" (parameter_list) "(this)" (() "(" (parameter_declaration) "this" (type_identifier) "this" ()) ")" (;) ";" (return_statement) "return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);" (return) "return" (binary_expression) "hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec)" (binary_expression) "hook.GetMethod<void* (__thiscall*)(void*, void*)" (field_expression) "hook.GetMethod" (identifier) "hook" (.) "." (field_identifier) "GetMethod" (<) "<" (binary_expression) "void* (__thiscall*)(void*, void*)" (identifier) "void" (*) "*" (cast_expression) "(__thiscall*)(void*, void*)" (() "(" (type_descriptor) "__thiscall*" (type_identifier) "__thiscall" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (cast_expression) "(void*, void*)" (() "(" (ERROR) "void*," (type_descriptor) "void*" (primitive_type) "void" (abstract_pointer_declarator) "*" (*) "*" (,) "," (type_descriptor) "void*" (primitive_type) "void" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "" (>) ">" (call_expression) "(63)(this, vec)" (parenthesized_expression) "(63)" (() "(" (number_literal) "63" ()) ")" (argument_list) "(this, vec)" (() "(" (identifier) "this" (,) "," (identifier) "vec" ()) ")" (;) ";" (}) "}" (function_definition) "bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }" (primitive_type) "bool" (function_declarator) "Teleport(Vector* vec, EulerAngles* angles)" (identifier) "Teleport" (parameter_list) "(Vector* vec, EulerAngles* angles)" (() "(" (parameter_declaration) "Vector* vec" (type_identifier) "Vector" (pointer_declarator) "* vec" (*) "*" (identifier) "vec" (,) "," (parameter_declaration) "EulerAngles* angles" (type_identifier) "EulerAngles" (pointer_declarator) "* angles" (*) "*" (identifier) "angles" ()) ")" (compound_statement) "{\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }" ({) "{" (labeled_statement) "utils::VtableHook hook(this);" (statement_identifier) "utils" (:) ":" (ERROR) ":" (:) ":" (declaration) "VtableHook hook(this);" (type_identifier) "VtableHook" (function_declarator) "hook(this)" (identifier) "hook" (parameter_list) "(this)" (() "(" (parameter_declaration) "this" (type_identifier) "this" ()) ")" (;) ";" (return_statement) "return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);" (return) "return" (binary_expression) "hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles)" (binary_expression) "hook.GetMethod<bool(__thiscall*)(void*, void*, void*)" (field_expression) "hook.GetMethod" (identifier) "hook" (.) "." (field_identifier) "GetMethod" (<) "<" (call_expression) "bool(__thiscall*)(void*, void*, void*)" (call_expression) "bool(__thiscall*)" (identifier) "bool" (argument_list) "(__thiscall*)" (() "(" (binary_expression) "__thiscall*" (identifier) "__thiscall" (*) "*" (identifier) "" ()) ")" (argument_list) "(void*, void*, void*)" (() "(" (binary_expression) "void*" (identifier) "void" (*) "*" (identifier) "" (,) "," (identifier) "void" (ERROR) "*" (*) "*" (,) "," (identifier) "void" (ERROR) "*" (*) "*" ()) ")" (>) ">" (call_expression) "(138)(this, vec, angles)" (parenthesized_expression) "(138)" (() "(" (number_literal) "138" ()) ")" (argument_list) "(this, vec, angles)" (() "(" (identifier) "this" (,) "," (identifier) "vec" (,) "," (identifier) "angles" ()) ")" (;) ";" (}) "}" (function_definition) "Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }" (type_identifier) "Vector" (function_declarator) "GetWorldPosition()" (identifier) "GetWorldPosition" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n return *(Vector*)(this + 160);\n }" ({) "{" (return_statement) "return *(Vector*)(this + 160);" (return) "return" (pointer_expression) "*(Vector*)(this + 160)" (*) "*" (cast_expression) "(Vector*)(this + 160)" (() "(" (type_descriptor) "Vector*" (type_identifier) "Vector" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (parenthesized_expression) "(this + 160)" (() "(" (binary_expression) "this + 160" (identifier) "this" (+) "+" (number_literal) "160" ()) ")" (;) ";" (}) "}" (}) "}" (expression_statement) ";" (;) ";" (}) "}" (}) "}"
514
9
{"language": "c", "success": true, "metadata": {"lines": 54, "avg_line_length": 30.61, "nodes": 341, "errors": 0, "source_hash": "78f7ba60e2548e87127ddc8323f22b621368f1212aab340279135e2ca25e3399", "categorized_nodes": 226}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#pragma once\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#pragma", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "once", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 12}}, {"id": 3, "type": "preproc_include", "text": "#include \"EntityFunctions.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 5, "type": "string_literal", "text": "\"EntityFunctions.h\"", "parent": 3, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 28}}, {"id": 6, "type": "preproc_include", "text": "#include \"Node.h\"\n", "parent": null, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"Node.h\"", "parent": 6, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 17}}, {"id": 9, "type": "preproc_include", "text": "#include \"../vtable/vmthooks.h\"\n", "parent": null, "children": [10, 11], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"../vtable/vmthooks.h\"", "parent": 9, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 31}}, {"id": 12, "type": "preproc_include", "text": "#include \"TString.h\"\n", "parent": null, "children": [13, 14], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 14, "type": "string_literal", "text": "\"TString.h\"", "parent": 12, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 20}}, {"id": 15, "type": "function_definition", "text": "namespace ProjectNovigrad\n{\n namespace TW3\n {\n struct EntitySpawnParams {\n char v48; // [rsp+A0h] [rbp-60h]\n char v49; // [rsp+ACh] [rbp-54h]\n char v50; // [rsp+B8h] [rbp-48h]\n char v51; // [rsp+C8h] [rbp-38h]\n Vector position; // [rsp+F0h] [rbp-10h]\n EulerAngles direction; // [rsp+100h] [rbp+0h]\n int v54; // [rsp+108h] [rbp+8h]\n Vector v55; // [rsp+120h] [rbp+20h]\n int v56; // [rsp+130h] [rbp+30h]\n char v57; // [rsp+14Ah] [rbp+4Ah]\n char v58; // [rsp+150h] [rbp+50h]\n char v59; // [rsp+1A8h] [rbp+A8h]\n char v60; // [rsp+1B8h] [rbp+B8h]\n };\n class __declspec(dllexport) CEntity\n {\n public:\n TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);\n }\n\n TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);\n }\n\n void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }\n\n bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }\n\n Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }\n };\n }\n}", "parent": null, "children": [16, 17], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 59, "column": 1}}, {"id": 16, "type": "type_identifier", "text": "namespace", "parent": 15, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 9}}, {"id": 17, "type": "identifier", "text": "ProjectNovigrad", "parent": 15, "children": [], "start_point": {"row": 7, "column": 10}, "end_point": {"row": 7, "column": 25}}, {"id": 18, "type": "function_definition", "text": "namespace TW3\n {\n struct EntitySpawnParams {\n char v48; // [rsp+A0h] [rbp-60h]\n char v49; // [rsp+ACh] [rbp-54h]\n char v50; // [rsp+B8h] [rbp-48h]\n char v51; // [rsp+C8h] [rbp-38h]\n Vector position; // [rsp+F0h] [rbp-10h]\n EulerAngles direction; // [rsp+100h] [rbp+0h]\n int v54; // [rsp+108h] [rbp+8h]\n Vector v55; // [rsp+120h] [rbp+20h]\n int v56; // [rsp+130h] [rbp+30h]\n char v57; // [rsp+14Ah] [rbp+4Ah]\n char v58; // [rsp+150h] [rbp+50h]\n char v59; // [rsp+1A8h] [rbp+A8h]\n char v60; // [rsp+1B8h] [rbp+B8h]\n };\n class __declspec(dllexport) CEntity\n {\n public:\n TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);\n }\n\n TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);\n }\n\n void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }\n\n bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }\n\n Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }\n };\n }", "parent": 15, "children": [19, 20], "start_point": {"row": 9, "column": 2}, "end_point": {"row": 58, "column": 3}}, {"id": 19, "type": "type_identifier", "text": "namespace", "parent": 18, "children": [], "start_point": {"row": 9, "column": 2}, "end_point": {"row": 9, "column": 11}}, {"id": 20, "type": "identifier", "text": "TW3", "parent": 18, "children": [], "start_point": {"row": 9, "column": 12}, "end_point": {"row": 9, "column": 15}}, {"id": 21, "type": "struct_specifier", "text": "struct EntitySpawnParams {\n char v48; // [rsp+A0h] [rbp-60h]\n char v49; // [rsp+ACh] [rbp-54h]\n char v50; // [rsp+B8h] [rbp-48h]\n char v51; // [rsp+C8h] [rbp-38h]\n Vector position; // [rsp+F0h] [rbp-10h]\n EulerAngles direction; // [rsp+100h] [rbp+0h]\n int v54; // [rsp+108h] [rbp+8h]\n Vector v55; // [rsp+120h] [rbp+20h]\n int v56; // [rsp+130h] [rbp+30h]\n char v57; // [rsp+14Ah] [rbp+4Ah]\n char v58; // [rsp+150h] [rbp+50h]\n char v59; // [rsp+1A8h] [rbp+A8h]\n char v60; // [rsp+1B8h] [rbp+B8h]\n }", "parent": 18, "children": [22, 23], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 25, "column": 5}}, {"id": 22, "type": "struct", "text": "struct", "parent": 21, "children": [], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 10}}, {"id": 23, "type": "type_identifier", "text": "EntitySpawnParams", "parent": 21, "children": [], "start_point": {"row": 11, "column": 11}, "end_point": {"row": 11, "column": 28}}, {"id": 24, "type": "field_declaration", "text": "char v48;", "parent": 21, "children": [25, 26], "start_point": {"row": 12, "column": 6}, "end_point": {"row": 12, "column": 15}}, {"id": 25, "type": "primitive_type", "text": "char", "parent": 24, "children": [], "start_point": {"row": 12, "column": 6}, "end_point": {"row": 12, "column": 10}}, {"id": 26, "type": "field_identifier", "text": "v48", "parent": 24, "children": [], "start_point": {"row": 12, "column": 11}, "end_point": {"row": 12, "column": 14}}, {"id": 27, "type": "field_declaration", "text": "char v49;", "parent": 21, "children": [28, 29], "start_point": {"row": 13, "column": 6}, "end_point": {"row": 13, "column": 15}}, {"id": 28, "type": "primitive_type", "text": "char", "parent": 27, "children": [], "start_point": {"row": 13, "column": 6}, "end_point": {"row": 13, "column": 10}}, {"id": 29, "type": "field_identifier", "text": "v49", "parent": 27, "children": [], "start_point": {"row": 13, "column": 11}, "end_point": {"row": 13, "column": 14}}, {"id": 30, "type": "field_declaration", "text": "char v50;", "parent": 21, "children": [31, 32], "start_point": {"row": 14, "column": 6}, "end_point": {"row": 14, "column": 15}}, {"id": 31, "type": "primitive_type", "text": "char", "parent": 30, "children": [], "start_point": {"row": 14, "column": 6}, "end_point": {"row": 14, "column": 10}}, {"id": 32, "type": "field_identifier", "text": "v50", "parent": 30, "children": [], "start_point": {"row": 14, "column": 11}, "end_point": {"row": 14, "column": 14}}, {"id": 33, "type": "field_declaration", "text": "char v51;", "parent": 21, "children": [34, 35], "start_point": {"row": 15, "column": 6}, "end_point": {"row": 15, "column": 15}}, {"id": 34, "type": "primitive_type", "text": "char", "parent": 33, "children": [], "start_point": {"row": 15, "column": 6}, "end_point": {"row": 15, "column": 10}}, {"id": 35, "type": "field_identifier", "text": "v51", "parent": 33, "children": [], "start_point": {"row": 15, "column": 11}, "end_point": {"row": 15, "column": 14}}, {"id": 36, "type": "field_declaration", "text": "Vector position;", "parent": 21, "children": [37, 38], "start_point": {"row": 16, "column": 6}, "end_point": {"row": 16, "column": 22}}, {"id": 37, "type": "type_identifier", "text": "Vector", "parent": 36, "children": [], "start_point": {"row": 16, "column": 6}, "end_point": {"row": 16, "column": 12}}, {"id": 38, "type": "field_identifier", "text": "position", "parent": 36, "children": [], "start_point": {"row": 16, "column": 13}, "end_point": {"row": 16, "column": 21}}, {"id": 39, "type": "field_declaration", "text": "EulerAngles direction;", "parent": 21, "children": [40, 41], "start_point": {"row": 17, "column": 6}, "end_point": {"row": 17, "column": 28}}, {"id": 40, "type": "type_identifier", "text": "EulerAngles", "parent": 39, "children": [], "start_point": {"row": 17, "column": 6}, "end_point": {"row": 17, "column": 17}}, {"id": 41, "type": "field_identifier", "text": "direction", "parent": 39, "children": [], "start_point": {"row": 17, "column": 18}, "end_point": {"row": 17, "column": 27}}, {"id": 42, "type": "field_declaration", "text": "int v54;", "parent": 21, "children": [43, 44], "start_point": {"row": 18, "column": 6}, "end_point": {"row": 18, "column": 14}}, {"id": 43, "type": "primitive_type", "text": "int", "parent": 42, "children": [], "start_point": {"row": 18, "column": 6}, "end_point": {"row": 18, "column": 9}}, {"id": 44, "type": "field_identifier", "text": "v54", "parent": 42, "children": [], "start_point": {"row": 18, "column": 10}, "end_point": {"row": 18, "column": 13}}, {"id": 45, "type": "field_declaration", "text": "Vector v55;", "parent": 21, "children": [46, 47], "start_point": {"row": 19, "column": 6}, "end_point": {"row": 19, "column": 17}}, {"id": 46, "type": "type_identifier", "text": "Vector", "parent": 45, "children": [], "start_point": {"row": 19, "column": 6}, "end_point": {"row": 19, "column": 12}}, {"id": 47, "type": "field_identifier", "text": "v55", "parent": 45, "children": [], "start_point": {"row": 19, "column": 13}, "end_point": {"row": 19, "column": 16}}, {"id": 48, "type": "field_declaration", "text": "int v56;", "parent": 21, "children": [49, 50], "start_point": {"row": 20, "column": 6}, "end_point": {"row": 20, "column": 14}}, {"id": 49, "type": "primitive_type", "text": "int", "parent": 48, "children": [], "start_point": {"row": 20, "column": 6}, "end_point": {"row": 20, "column": 9}}, {"id": 50, "type": "field_identifier", "text": "v56", "parent": 48, "children": [], "start_point": {"row": 20, "column": 10}, "end_point": {"row": 20, "column": 13}}, {"id": 51, "type": "field_declaration", "text": "char v57;", "parent": 21, "children": [52, 53], "start_point": {"row": 21, "column": 6}, "end_point": {"row": 21, "column": 15}}, {"id": 52, "type": "primitive_type", "text": "char", "parent": 51, "children": [], "start_point": {"row": 21, "column": 6}, "end_point": {"row": 21, "column": 10}}, {"id": 53, "type": "field_identifier", "text": "v57", "parent": 51, "children": [], "start_point": {"row": 21, "column": 11}, "end_point": {"row": 21, "column": 14}}, {"id": 54, "type": "field_declaration", "text": "char v58;", "parent": 21, "children": [55, 56], "start_point": {"row": 22, "column": 6}, "end_point": {"row": 22, "column": 15}}, {"id": 55, "type": "primitive_type", "text": "char", "parent": 54, "children": [], "start_point": {"row": 22, "column": 6}, "end_point": {"row": 22, "column": 10}}, {"id": 56, "type": "field_identifier", "text": "v58", "parent": 54, "children": [], "start_point": {"row": 22, "column": 11}, "end_point": {"row": 22, "column": 14}}, {"id": 57, "type": "field_declaration", "text": "char v59;", "parent": 21, "children": [58, 59], "start_point": {"row": 23, "column": 6}, "end_point": {"row": 23, "column": 15}}, {"id": 58, "type": "primitive_type", "text": "char", "parent": 57, "children": [], "start_point": {"row": 23, "column": 6}, "end_point": {"row": 23, "column": 10}}, {"id": 59, "type": "field_identifier", "text": "v59", "parent": 57, "children": [], "start_point": {"row": 23, "column": 11}, "end_point": {"row": 23, "column": 14}}, {"id": 60, "type": "field_declaration", "text": "char v60;", "parent": 21, "children": [61, 62], "start_point": {"row": 24, "column": 6}, "end_point": {"row": 24, "column": 15}}, {"id": 61, "type": "primitive_type", "text": "char", "parent": 60, "children": [], "start_point": {"row": 24, "column": 6}, "end_point": {"row": 24, "column": 10}}, {"id": 62, "type": "field_identifier", "text": "v60", "parent": 60, "children": [], "start_point": {"row": 24, "column": 11}, "end_point": {"row": 24, "column": 14}}, {"id": 63, "type": "function_definition", "text": "class __declspec(dllexport) CEntity\n {\n public:\n TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);\n }\n\n TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);\n }\n\n void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }\n\n bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }\n\n Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }\n }", "parent": 18, "children": [64, 67], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 57, "column": 5}}, {"id": 64, "type": "ms_declspec_modifier", "text": "__declspec(dllexport)", "parent": 63, "children": [65, 66], "start_point": {"row": 26, "column": 10}, "end_point": {"row": 26, "column": 31}}, {"id": 65, "type": "__declspec", "text": "__declspec", "parent": 64, "children": [], "start_point": {"row": 26, "column": 10}, "end_point": {"row": 26, "column": 20}}, {"id": 66, "type": "identifier", "text": "dllexport", "parent": 64, "children": [], "start_point": {"row": 26, "column": 21}, "end_point": {"row": 26, "column": 30}}, {"id": 67, "type": "identifier", "text": "CEntity", "parent": 63, "children": [], "start_point": {"row": 26, "column": 32}, "end_point": {"row": 26, "column": 39}}, {"id": 68, "type": "labeled_statement", "text": "public:\n TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)", "parent": 63, "children": [], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 29, "column": 60}}, {"id": 69, "type": "binary_expression", "text": "TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)", "parent": 68, "children": [70, 74, 75], "start_point": {"row": 29, "column": 6}, "end_point": {"row": 29, "column": 60}}, {"id": 70, "type": "binary_expression", "text": "TString<wchar_t", "parent": 69, "children": [71, 72, 73], "start_point": {"row": 29, "column": 6}, "end_point": {"row": 29, "column": 21}}, {"id": 71, "type": "identifier", "text": "TString", "parent": 70, "children": [], "start_point": {"row": 29, "column": 6}, "end_point": {"row": 29, "column": 13}}, {"id": 72, "type": "<", "text": "<", "parent": 70, "children": [], "start_point": {"row": 29, "column": 13}, "end_point": {"row": 29, "column": 14}}, {"id": 73, "type": "identifier", "text": "wchar_t", "parent": 70, "children": [], "start_point": {"row": 29, "column": 14}, "end_point": {"row": 29, "column": 21}}, {"id": 74, "type": ">", "text": ">", "parent": 69, "children": [], "start_point": {"row": 29, "column": 21}, "end_point": {"row": 29, "column": 22}}, {"id": 75, "type": "pointer_expression", "text": "* GetUniqueName(TString<wchar_t>* res)", "parent": 69, "children": [76, 77], "start_point": {"row": 29, "column": 22}, "end_point": {"row": 29, "column": 60}}, {"id": 76, "type": "*", "text": "*", "parent": 75, "children": [], "start_point": {"row": 29, "column": 22}, "end_point": {"row": 29, "column": 23}}, {"id": 77, "type": "call_expression", "text": "GetUniqueName(TString<wchar_t>* res)", "parent": 75, "children": [78, 79], "start_point": {"row": 29, "column": 24}, "end_point": {"row": 29, "column": 60}}, {"id": 78, "type": "identifier", "text": "GetUniqueName", "parent": 77, "children": [], "start_point": {"row": 29, "column": 24}, "end_point": {"row": 29, "column": 37}}, {"id": 79, "type": "argument_list", "text": "(TString<wchar_t>* res)", "parent": 77, "children": [80], "start_point": {"row": 29, "column": 37}, "end_point": {"row": 29, "column": 60}}, {"id": 80, "type": "binary_expression", "text": "TString<wchar_t>* res", "parent": 79, "children": [81, 85, 86], "start_point": {"row": 29, "column": 38}, "end_point": {"row": 29, "column": 59}}, {"id": 81, "type": "binary_expression", "text": "TString<wchar_t", "parent": 80, "children": [82, 83, 84], "start_point": {"row": 29, "column": 38}, "end_point": {"row": 29, "column": 53}}, {"id": 82, "type": "identifier", "text": "TString", "parent": 81, "children": [], "start_point": {"row": 29, "column": 38}, "end_point": {"row": 29, "column": 45}}, {"id": 83, "type": "<", "text": "<", "parent": 81, "children": [], "start_point": {"row": 29, "column": 45}, "end_point": {"row": 29, "column": 46}}, {"id": 84, "type": "identifier", "text": "wchar_t", "parent": 81, "children": [], "start_point": {"row": 29, "column": 46}, "end_point": {"row": 29, "column": 53}}, {"id": 85, "type": ">", "text": ">", "parent": 80, "children": [], "start_point": {"row": 29, "column": 53}, "end_point": {"row": 29, "column": 54}}, {"id": 86, "type": "pointer_expression", "text": "* res", "parent": 80, "children": [87, 88], "start_point": {"row": 29, "column": 54}, "end_point": {"row": 29, "column": 59}}, {"id": 87, "type": "*", "text": "*", "parent": 86, "children": [], "start_point": {"row": 29, "column": 54}, "end_point": {"row": 29, "column": 55}}, {"id": 88, "type": "identifier", "text": "res", "parent": 86, "children": [], "start_point": {"row": 29, "column": 56}, "end_point": {"row": 29, "column": 59}}, {"id": 89, "type": "labeled_statement", "text": "utils::VtableHook hook(this);", "parent": 63, "children": [90, 91], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 37}}, {"id": 90, "type": "statement_identifier", "text": "utils", "parent": 89, "children": [], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 13}}, {"id": 91, "type": "declaration", "text": "VtableHook hook(this);", "parent": 89, "children": [92, 93], "start_point": {"row": 31, "column": 15}, "end_point": {"row": 31, "column": 37}}, {"id": 92, "type": "type_identifier", "text": "VtableHook", "parent": 91, "children": [], "start_point": {"row": 31, "column": 15}, "end_point": {"row": 31, "column": 25}}, {"id": 93, "type": "function_declarator", "text": "hook(this)", "parent": 91, "children": [94, 95], "start_point": {"row": 31, "column": 26}, "end_point": {"row": 31, "column": 36}}, {"id": 94, "type": "identifier", "text": "hook", "parent": 93, "children": [], "start_point": {"row": 31, "column": 26}, "end_point": {"row": 31, "column": 30}}, {"id": 95, "type": "parameter_list", "text": "(this)", "parent": 93, "children": [96], "start_point": {"row": 31, "column": 30}, "end_point": {"row": 31, "column": 36}}, {"id": 96, "type": "parameter_declaration", "text": "this", "parent": 95, "children": [97], "start_point": {"row": 31, "column": 31}, "end_point": {"row": 31, "column": 35}}, {"id": 97, "type": "type_identifier", "text": "this", "parent": 96, "children": [], "start_point": {"row": 31, "column": 31}, "end_point": {"row": 31, "column": 35}}, {"id": 98, "type": "return_statement", "text": "return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);", "parent": 63, "children": [99], "start_point": {"row": 32, "column": 8}, "end_point": {"row": 32, "column": 104}}, {"id": 99, "type": "binary_expression", "text": "hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res)", "parent": 98, "children": [100, 133, 134], "start_point": {"row": 32, "column": 15}, "end_point": {"row": 32, "column": 103}}, {"id": 100, "type": "binary_expression", "text": "hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)", "parent": 99, "children": [101, 110, 111], "start_point": {"row": 32, "column": 15}, "end_point": {"row": 32, "column": 87}}, {"id": 101, "type": "binary_expression", "text": "hook.GetMethod<TString<wchar_t", "parent": 100, "children": [102, 108, 109], "start_point": {"row": 32, "column": 15}, "end_point": {"row": 32, "column": 45}}, {"id": 102, "type": "binary_expression", "text": "hook.GetMethod<TString", "parent": 101, "children": [103, 106, 107], "start_point": {"row": 32, "column": 15}, "end_point": {"row": 32, "column": 37}}, {"id": 103, "type": "field_expression", "text": "hook.GetMethod", "parent": 102, "children": [104, 105], "start_point": {"row": 32, "column": 15}, "end_point": {"row": 32, "column": 29}}, {"id": 104, "type": "identifier", "text": "hook", "parent": 103, "children": [], "start_point": {"row": 32, "column": 15}, "end_point": {"row": 32, "column": 19}}, {"id": 105, "type": "field_identifier", "text": "GetMethod", "parent": 103, "children": [], "start_point": {"row": 32, "column": 20}, "end_point": {"row": 32, "column": 29}}, {"id": 106, "type": "<", "text": "<", "parent": 102, "children": [], "start_point": {"row": 32, "column": 29}, "end_point": {"row": 32, "column": 30}}, {"id": 107, "type": "identifier", "text": "TString", "parent": 102, "children": [], "start_point": {"row": 32, "column": 30}, "end_point": {"row": 32, "column": 37}}, {"id": 108, "type": "<", "text": "<", "parent": 101, "children": [], "start_point": {"row": 32, "column": 37}, "end_point": {"row": 32, "column": 38}}, {"id": 109, "type": "identifier", "text": "wchar_t", "parent": 101, "children": [], "start_point": {"row": 32, "column": 38}, "end_point": {"row": 32, "column": 45}}, {"id": 110, "type": ">", "text": ">", "parent": 100, "children": [], "start_point": {"row": 32, "column": 45}, "end_point": {"row": 32, "column": 46}}, {"id": 111, "type": "pointer_expression", "text": "* (__thiscall*)(void*, TString<wchar_t>*)", "parent": 100, "children": [112, 113], "start_point": {"row": 32, "column": 46}, "end_point": {"row": 32, "column": 87}}, {"id": 112, "type": "*", "text": "*", "parent": 111, "children": [], "start_point": {"row": 32, "column": 46}, "end_point": {"row": 32, "column": 47}}, {"id": 113, "type": "cast_expression", "text": "(__thiscall*)(void*, TString<wchar_t>*)", "parent": 111, "children": [114, 118], "start_point": {"row": 32, "column": 48}, "end_point": {"row": 32, "column": 87}}, {"id": 114, "type": "type_descriptor", "text": "__thiscall*", "parent": 113, "children": [115, 116], "start_point": {"row": 32, "column": 49}, "end_point": {"row": 32, "column": 60}}, {"id": 115, "type": "type_identifier", "text": "__thiscall", "parent": 114, "children": [], "start_point": {"row": 32, "column": 49}, "end_point": {"row": 32, "column": 59}}, {"id": 116, "type": "abstract_pointer_declarator", "text": "*", "parent": 114, "children": [117], "start_point": {"row": 32, "column": 59}, "end_point": {"row": 32, "column": 60}}, {"id": 117, "type": "*", "text": "*", "parent": 116, "children": [], "start_point": {"row": 32, "column": 59}, "end_point": {"row": 32, "column": 60}}, {"id": 118, "type": "parenthesized_expression", "text": "(void*, TString<wchar_t>*)", "parent": 113, "children": [119, 124], "start_point": {"row": 32, "column": 61}, "end_point": {"row": 32, "column": 87}}, {"id": 119, "type": "ERROR", "text": "void*,", "parent": 118, "children": [120], "start_point": {"row": 32, "column": 62}, "end_point": {"row": 32, "column": 68}}, {"id": 120, "type": "type_descriptor", "text": "void*", "parent": 119, "children": [121, 122], "start_point": {"row": 32, "column": 62}, "end_point": {"row": 32, "column": 67}}, {"id": 121, "type": "primitive_type", "text": "void", "parent": 120, "children": [], "start_point": {"row": 32, "column": 62}, "end_point": {"row": 32, "column": 66}}, {"id": 122, "type": "abstract_pointer_declarator", "text": "*", "parent": 120, "children": [123], "start_point": {"row": 32, "column": 66}, "end_point": {"row": 32, "column": 67}}, {"id": 123, "type": "*", "text": "*", "parent": 122, "children": [], "start_point": {"row": 32, "column": 66}, "end_point": {"row": 32, "column": 67}}, {"id": 124, "type": "binary_expression", "text": "TString<wchar_t>*", "parent": 118, "children": [125, 129, 130], "start_point": {"row": 32, "column": 69}, "end_point": {"row": 32, "column": 86}}, {"id": 125, "type": "binary_expression", "text": "TString<wchar_t", "parent": 124, "children": [126, 127, 128], "start_point": {"row": 32, "column": 69}, "end_point": {"row": 32, "column": 84}}, {"id": 126, "type": "identifier", "text": "TString", "parent": 125, "children": [], "start_point": {"row": 32, "column": 69}, "end_point": {"row": 32, "column": 76}}, {"id": 127, "type": "<", "text": "<", "parent": 125, "children": [], "start_point": {"row": 32, "column": 76}, "end_point": {"row": 32, "column": 77}}, {"id": 128, "type": "identifier", "text": "wchar_t", "parent": 125, "children": [], "start_point": {"row": 32, "column": 77}, "end_point": {"row": 32, "column": 84}}, {"id": 129, "type": ">", "text": ">", "parent": 124, "children": [], "start_point": {"row": 32, "column": 84}, "end_point": {"row": 32, "column": 85}}, {"id": 130, "type": "pointer_expression", "text": "*", "parent": 124, "children": [131, 132], "start_point": {"row": 32, "column": 85}, "end_point": {"row": 32, "column": 86}}, {"id": 131, "type": "*", "text": "*", "parent": 130, "children": [], "start_point": {"row": 32, "column": 85}, "end_point": {"row": 32, "column": 86}}, {"id": 132, "type": "identifier", "text": "", "parent": 130, "children": [], "start_point": {"row": 32, "column": 86}, "end_point": {"row": 32, "column": 86}}, {"id": 133, "type": ">", "text": ">", "parent": 99, "children": [], "start_point": {"row": 32, "column": 87}, "end_point": {"row": 32, "column": 88}}, {"id": 134, "type": "call_expression", "text": "(45)(this, res)", "parent": 99, "children": [135, 137], "start_point": {"row": 32, "column": 88}, "end_point": {"row": 32, "column": 103}}, {"id": 135, "type": "parenthesized_expression", "text": "(45)", "parent": 134, "children": [136], "start_point": {"row": 32, "column": 88}, "end_point": {"row": 32, "column": 92}}, {"id": 136, "type": "number_literal", "text": "45", "parent": 135, "children": [], "start_point": {"row": 32, "column": 89}, "end_point": {"row": 32, "column": 91}}, {"id": 137, "type": "argument_list", "text": "(this, res)", "parent": 134, "children": [138, 139], "start_point": {"row": 32, "column": 92}, "end_point": {"row": 32, "column": 103}}, {"id": 138, "type": "identifier", "text": "this", "parent": 137, "children": [], "start_point": {"row": 32, "column": 93}, "end_point": {"row": 32, "column": 97}}, {"id": 139, "type": "identifier", "text": "res", "parent": 137, "children": [], "start_point": {"row": 32, "column": 99}, "end_point": {"row": 32, "column": 102}}, {"id": 140, "type": "binary_expression", "text": "TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)", "parent": 63, "children": [141, 145, 146], "start_point": {"row": 35, "column": 6}, "end_point": {"row": 35, "column": 62}}, {"id": 141, "type": "binary_expression", "text": "TString<wchar_t", "parent": 140, "children": [142, 143, 144], "start_point": {"row": 35, "column": 6}, "end_point": {"row": 35, "column": 21}}, {"id": 142, "type": "identifier", "text": "TString", "parent": 141, "children": [], "start_point": {"row": 35, "column": 6}, "end_point": {"row": 35, "column": 13}}, {"id": 143, "type": "<", "text": "<", "parent": 141, "children": [], "start_point": {"row": 35, "column": 13}, "end_point": {"row": 35, "column": 14}}, {"id": 144, "type": "identifier", "text": "wchar_t", "parent": 141, "children": [], "start_point": {"row": 35, "column": 14}, "end_point": {"row": 35, "column": 21}}, {"id": 145, "type": ">", "text": ">", "parent": 140, "children": [], "start_point": {"row": 35, "column": 21}, "end_point": {"row": 35, "column": 22}}, {"id": 146, "type": "pointer_expression", "text": "* GetFriendlyName(TString<wchar_t>* res)", "parent": 140, "children": [147, 148], "start_point": {"row": 35, "column": 22}, "end_point": {"row": 35, "column": 62}}, {"id": 147, "type": "*", "text": "*", "parent": 146, "children": [], "start_point": {"row": 35, "column": 22}, "end_point": {"row": 35, "column": 23}}, {"id": 148, "type": "call_expression", "text": "GetFriendlyName(TString<wchar_t>* res)", "parent": 146, "children": [149, 150], "start_point": {"row": 35, "column": 24}, "end_point": {"row": 35, "column": 62}}, {"id": 149, "type": "identifier", "text": "GetFriendlyName", "parent": 148, "children": [], "start_point": {"row": 35, "column": 24}, "end_point": {"row": 35, "column": 39}}, {"id": 150, "type": "argument_list", "text": "(TString<wchar_t>* res)", "parent": 148, "children": [151], "start_point": {"row": 35, "column": 39}, "end_point": {"row": 35, "column": 62}}, {"id": 151, "type": "binary_expression", "text": "TString<wchar_t>* res", "parent": 150, "children": [152, 156, 157], "start_point": {"row": 35, "column": 40}, "end_point": {"row": 35, "column": 61}}, {"id": 152, "type": "binary_expression", "text": "TString<wchar_t", "parent": 151, "children": [153, 154, 155], "start_point": {"row": 35, "column": 40}, "end_point": {"row": 35, "column": 55}}, {"id": 153, "type": "identifier", "text": "TString", "parent": 152, "children": [], "start_point": {"row": 35, "column": 40}, "end_point": {"row": 35, "column": 47}}, {"id": 154, "type": "<", "text": "<", "parent": 152, "children": [], "start_point": {"row": 35, "column": 47}, "end_point": {"row": 35, "column": 48}}, {"id": 155, "type": "identifier", "text": "wchar_t", "parent": 152, "children": [], "start_point": {"row": 35, "column": 48}, "end_point": {"row": 35, "column": 55}}, {"id": 156, "type": ">", "text": ">", "parent": 151, "children": [], "start_point": {"row": 35, "column": 55}, "end_point": {"row": 35, "column": 56}}, {"id": 157, "type": "pointer_expression", "text": "* res", "parent": 151, "children": [158, 159], "start_point": {"row": 35, "column": 56}, "end_point": {"row": 35, "column": 61}}, {"id": 158, "type": "*", "text": "*", "parent": 157, "children": [], "start_point": {"row": 35, "column": 56}, "end_point": {"row": 35, "column": 57}}, {"id": 159, "type": "identifier", "text": "res", "parent": 157, "children": [], "start_point": {"row": 35, "column": 58}, "end_point": {"row": 35, "column": 61}}, {"id": 160, "type": "labeled_statement", "text": "utils::VtableHook hook(this);", "parent": 63, "children": [161, 162], "start_point": {"row": 37, "column": 8}, "end_point": {"row": 37, "column": 37}}, {"id": 161, "type": "statement_identifier", "text": "utils", "parent": 160, "children": [], "start_point": {"row": 37, "column": 8}, "end_point": {"row": 37, "column": 13}}, {"id": 162, "type": "declaration", "text": "VtableHook hook(this);", "parent": 160, "children": [163, 164], "start_point": {"row": 37, "column": 15}, "end_point": {"row": 37, "column": 37}}, {"id": 163, "type": "type_identifier", "text": "VtableHook", "parent": 162, "children": [], "start_point": {"row": 37, "column": 15}, "end_point": {"row": 37, "column": 25}}, {"id": 164, "type": "function_declarator", "text": "hook(this)", "parent": 162, "children": [165, 166], "start_point": {"row": 37, "column": 26}, "end_point": {"row": 37, "column": 36}}, {"id": 165, "type": "identifier", "text": "hook", "parent": 164, "children": [], "start_point": {"row": 37, "column": 26}, "end_point": {"row": 37, "column": 30}}, {"id": 166, "type": "parameter_list", "text": "(this)", "parent": 164, "children": [167], "start_point": {"row": 37, "column": 30}, "end_point": {"row": 37, "column": 36}}, {"id": 167, "type": "parameter_declaration", "text": "this", "parent": 166, "children": [168], "start_point": {"row": 37, "column": 31}, "end_point": {"row": 37, "column": 35}}, {"id": 168, "type": "type_identifier", "text": "this", "parent": 167, "children": [], "start_point": {"row": 37, "column": 31}, "end_point": {"row": 37, "column": 35}}, {"id": 169, "type": "return_statement", "text": "return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);", "parent": 63, "children": [170], "start_point": {"row": 38, "column": 8}, "end_point": {"row": 38, "column": 104}}, {"id": 170, "type": "binary_expression", "text": "hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res)", "parent": 169, "children": [171, 204, 205], "start_point": {"row": 38, "column": 15}, "end_point": {"row": 38, "column": 103}}, {"id": 171, "type": "binary_expression", "text": "hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)", "parent": 170, "children": [172, 181, 182], "start_point": {"row": 38, "column": 15}, "end_point": {"row": 38, "column": 87}}, {"id": 172, "type": "binary_expression", "text": "hook.GetMethod<TString<wchar_t", "parent": 171, "children": [173, 179, 180], "start_point": {"row": 38, "column": 15}, "end_point": {"row": 38, "column": 45}}, {"id": 173, "type": "binary_expression", "text": "hook.GetMethod<TString", "parent": 172, "children": [174, 177, 178], "start_point": {"row": 38, "column": 15}, "end_point": {"row": 38, "column": 37}}, {"id": 174, "type": "field_expression", "text": "hook.GetMethod", "parent": 173, "children": [175, 176], "start_point": {"row": 38, "column": 15}, "end_point": {"row": 38, "column": 29}}, {"id": 175, "type": "identifier", "text": "hook", "parent": 174, "children": [], "start_point": {"row": 38, "column": 15}, "end_point": {"row": 38, "column": 19}}, {"id": 176, "type": "field_identifier", "text": "GetMethod", "parent": 174, "children": [], "start_point": {"row": 38, "column": 20}, "end_point": {"row": 38, "column": 29}}, {"id": 177, "type": "<", "text": "<", "parent": 173, "children": [], "start_point": {"row": 38, "column": 29}, "end_point": {"row": 38, "column": 30}}, {"id": 178, "type": "identifier", "text": "TString", "parent": 173, "children": [], "start_point": {"row": 38, "column": 30}, "end_point": {"row": 38, "column": 37}}, {"id": 179, "type": "<", "text": "<", "parent": 172, "children": [], "start_point": {"row": 38, "column": 37}, "end_point": {"row": 38, "column": 38}}, {"id": 180, "type": "identifier", "text": "wchar_t", "parent": 172, "children": [], "start_point": {"row": 38, "column": 38}, "end_point": {"row": 38, "column": 45}}, {"id": 181, "type": ">", "text": ">", "parent": 171, "children": [], "start_point": {"row": 38, "column": 45}, "end_point": {"row": 38, "column": 46}}, {"id": 182, "type": "pointer_expression", "text": "* (__thiscall*)(void*, TString<wchar_t>*)", "parent": 171, "children": [183, 184], "start_point": {"row": 38, "column": 46}, "end_point": {"row": 38, "column": 87}}, {"id": 183, "type": "*", "text": "*", "parent": 182, "children": [], "start_point": {"row": 38, "column": 46}, "end_point": {"row": 38, "column": 47}}, {"id": 184, "type": "cast_expression", "text": "(__thiscall*)(void*, TString<wchar_t>*)", "parent": 182, "children": [185, 189], "start_point": {"row": 38, "column": 48}, "end_point": {"row": 38, "column": 87}}, {"id": 185, "type": "type_descriptor", "text": "__thiscall*", "parent": 184, "children": [186, 187], "start_point": {"row": 38, "column": 49}, "end_point": {"row": 38, "column": 60}}, {"id": 186, "type": "type_identifier", "text": "__thiscall", "parent": 185, "children": [], "start_point": {"row": 38, "column": 49}, "end_point": {"row": 38, "column": 59}}, {"id": 187, "type": "abstract_pointer_declarator", "text": "*", "parent": 185, "children": [188], "start_point": {"row": 38, "column": 59}, "end_point": {"row": 38, "column": 60}}, {"id": 188, "type": "*", "text": "*", "parent": 187, "children": [], "start_point": {"row": 38, "column": 59}, "end_point": {"row": 38, "column": 60}}, {"id": 189, "type": "parenthesized_expression", "text": "(void*, TString<wchar_t>*)", "parent": 184, "children": [190, 195], "start_point": {"row": 38, "column": 61}, "end_point": {"row": 38, "column": 87}}, {"id": 190, "type": "ERROR", "text": "void*,", "parent": 189, "children": [191], "start_point": {"row": 38, "column": 62}, "end_point": {"row": 38, "column": 68}}, {"id": 191, "type": "type_descriptor", "text": "void*", "parent": 190, "children": [192, 193], "start_point": {"row": 38, "column": 62}, "end_point": {"row": 38, "column": 67}}, {"id": 192, "type": "primitive_type", "text": "void", "parent": 191, "children": [], "start_point": {"row": 38, "column": 62}, "end_point": {"row": 38, "column": 66}}, {"id": 193, "type": "abstract_pointer_declarator", "text": "*", "parent": 191, "children": [194], "start_point": {"row": 38, "column": 66}, "end_point": {"row": 38, "column": 67}}, {"id": 194, "type": "*", "text": "*", "parent": 193, "children": [], "start_point": {"row": 38, "column": 66}, "end_point": {"row": 38, "column": 67}}, {"id": 195, "type": "binary_expression", "text": "TString<wchar_t>*", "parent": 189, "children": [196, 200, 201], "start_point": {"row": 38, "column": 69}, "end_point": {"row": 38, "column": 86}}, {"id": 196, "type": "binary_expression", "text": "TString<wchar_t", "parent": 195, "children": [197, 198, 199], "start_point": {"row": 38, "column": 69}, "end_point": {"row": 38, "column": 84}}, {"id": 197, "type": "identifier", "text": "TString", "parent": 196, "children": [], "start_point": {"row": 38, "column": 69}, "end_point": {"row": 38, "column": 76}}, {"id": 198, "type": "<", "text": "<", "parent": 196, "children": [], "start_point": {"row": 38, "column": 76}, "end_point": {"row": 38, "column": 77}}, {"id": 199, "type": "identifier", "text": "wchar_t", "parent": 196, "children": [], "start_point": {"row": 38, "column": 77}, "end_point": {"row": 38, "column": 84}}, {"id": 200, "type": ">", "text": ">", "parent": 195, "children": [], "start_point": {"row": 38, "column": 84}, "end_point": {"row": 38, "column": 85}}, {"id": 201, "type": "pointer_expression", "text": "*", "parent": 195, "children": [202, 203], "start_point": {"row": 38, "column": 85}, "end_point": {"row": 38, "column": 86}}, {"id": 202, "type": "*", "text": "*", "parent": 201, "children": [], "start_point": {"row": 38, "column": 85}, "end_point": {"row": 38, "column": 86}}, {"id": 203, "type": "identifier", "text": "", "parent": 201, "children": [], "start_point": {"row": 38, "column": 86}, "end_point": {"row": 38, "column": 86}}, {"id": 204, "type": ">", "text": ">", "parent": 170, "children": [], "start_point": {"row": 38, "column": 87}, "end_point": {"row": 38, "column": 88}}, {"id": 205, "type": "call_expression", "text": "(27)(this, res)", "parent": 170, "children": [206, 208], "start_point": {"row": 38, "column": 88}, "end_point": {"row": 38, "column": 103}}, {"id": 206, "type": "parenthesized_expression", "text": "(27)", "parent": 205, "children": [207], "start_point": {"row": 38, "column": 88}, "end_point": {"row": 38, "column": 92}}, {"id": 207, "type": "number_literal", "text": "27", "parent": 206, "children": [], "start_point": {"row": 38, "column": 89}, "end_point": {"row": 38, "column": 91}}, {"id": 208, "type": "argument_list", "text": "(this, res)", "parent": 205, "children": [209, 210], "start_point": {"row": 38, "column": 92}, "end_point": {"row": 38, "column": 103}}, {"id": 209, "type": "identifier", "text": "this", "parent": 208, "children": [], "start_point": {"row": 38, "column": 93}, "end_point": {"row": 38, "column": 97}}, {"id": 210, "type": "identifier", "text": "res", "parent": 208, "children": [], "start_point": {"row": 38, "column": 99}, "end_point": {"row": 38, "column": 102}}, {"id": 211, "type": "function_definition", "text": "void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }", "parent": 63, "children": [212, 213], "start_point": {"row": 41, "column": 6}, "end_point": {"row": 45, "column": 7}}, {"id": 212, "type": "primitive_type", "text": "void", "parent": 211, "children": [], "start_point": {"row": 41, "column": 6}, "end_point": {"row": 41, "column": 10}}, {"id": 213, "type": "pointer_declarator", "text": "* SetPosition(Vector* vec)", "parent": 211, "children": [214, 215], "start_point": {"row": 41, "column": 10}, "end_point": {"row": 41, "column": 36}}, {"id": 214, "type": "*", "text": "*", "parent": 213, "children": [], "start_point": {"row": 41, "column": 10}, "end_point": {"row": 41, "column": 11}}, {"id": 215, "type": "function_declarator", "text": "SetPosition(Vector* vec)", "parent": 213, "children": [216, 217], "start_point": {"row": 41, "column": 12}, "end_point": {"row": 41, "column": 36}}, {"id": 216, "type": "identifier", "text": "SetPosition", "parent": 215, "children": [], "start_point": {"row": 41, "column": 12}, "end_point": {"row": 41, "column": 23}}, {"id": 217, "type": "parameter_list", "text": "(Vector* vec)", "parent": 215, "children": [218], "start_point": {"row": 41, "column": 23}, "end_point": {"row": 41, "column": 36}}, {"id": 218, "type": "parameter_declaration", "text": "Vector* vec", "parent": 217, "children": [219, 220], "start_point": {"row": 41, "column": 24}, "end_point": {"row": 41, "column": 35}}, {"id": 219, "type": "type_identifier", "text": "Vector", "parent": 218, "children": [], "start_point": {"row": 41, "column": 24}, "end_point": {"row": 41, "column": 30}}, {"id": 220, "type": "pointer_declarator", "text": "* vec", "parent": 218, "children": [221, 222], "start_point": {"row": 41, "column": 30}, "end_point": {"row": 41, "column": 35}}, {"id": 221, "type": "*", "text": "*", "parent": 220, "children": [], "start_point": {"row": 41, "column": 30}, "end_point": {"row": 41, "column": 31}}, {"id": 222, "type": "identifier", "text": "vec", "parent": 220, "children": [], "start_point": {"row": 41, "column": 32}, "end_point": {"row": 41, "column": 35}}, {"id": 223, "type": "labeled_statement", "text": "utils::VtableHook hook(this);", "parent": 211, "children": [224, 225], "start_point": {"row": 43, "column": 8}, "end_point": {"row": 43, "column": 37}}, {"id": 224, "type": "statement_identifier", "text": "utils", "parent": 223, "children": [], "start_point": {"row": 43, "column": 8}, "end_point": {"row": 43, "column": 13}}, {"id": 225, "type": "declaration", "text": "VtableHook hook(this);", "parent": 223, "children": [226, 227], "start_point": {"row": 43, "column": 15}, "end_point": {"row": 43, "column": 37}}, {"id": 226, "type": "type_identifier", "text": "VtableHook", "parent": 225, "children": [], "start_point": {"row": 43, "column": 15}, "end_point": {"row": 43, "column": 25}}, {"id": 227, "type": "function_declarator", "text": "hook(this)", "parent": 225, "children": [228, 229], "start_point": {"row": 43, "column": 26}, "end_point": {"row": 43, "column": 36}}, {"id": 228, "type": "identifier", "text": "hook", "parent": 227, "children": [], "start_point": {"row": 43, "column": 26}, "end_point": {"row": 43, "column": 30}}, {"id": 229, "type": "parameter_list", "text": "(this)", "parent": 227, "children": [230], "start_point": {"row": 43, "column": 30}, "end_point": {"row": 43, "column": 36}}, {"id": 230, "type": "parameter_declaration", "text": "this", "parent": 229, "children": [231], "start_point": {"row": 43, "column": 31}, "end_point": {"row": 43, "column": 35}}, {"id": 231, "type": "type_identifier", "text": "this", "parent": 230, "children": [], "start_point": {"row": 43, "column": 31}, "end_point": {"row": 43, "column": 35}}, {"id": 232, "type": "return_statement", "text": "return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);", "parent": 211, "children": [233], "start_point": {"row": 44, "column": 8}, "end_point": {"row": 44, "column": 80}}, {"id": 233, "type": "binary_expression", "text": "hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec)", "parent": 232, "children": [234, 258, 259], "start_point": {"row": 44, "column": 15}, "end_point": {"row": 44, "column": 79}}, {"id": 234, "type": "binary_expression", "text": "hook.GetMethod<void* (__thiscall*)(void*, void*)", "parent": 233, "children": [235, 238, 239], "start_point": {"row": 44, "column": 15}, "end_point": {"row": 44, "column": 63}}, {"id": 235, "type": "field_expression", "text": "hook.GetMethod", "parent": 234, "children": [236, 237], "start_point": {"row": 44, "column": 15}, "end_point": {"row": 44, "column": 29}}, {"id": 236, "type": "identifier", "text": "hook", "parent": 235, "children": [], "start_point": {"row": 44, "column": 15}, "end_point": {"row": 44, "column": 19}}, {"id": 237, "type": "field_identifier", "text": "GetMethod", "parent": 235, "children": [], "start_point": {"row": 44, "column": 20}, "end_point": {"row": 44, "column": 29}}, {"id": 238, "type": "<", "text": "<", "parent": 234, "children": [], "start_point": {"row": 44, "column": 29}, "end_point": {"row": 44, "column": 30}}, {"id": 239, "type": "binary_expression", "text": "void* (__thiscall*)(void*, void*)", "parent": 234, "children": [240, 241, 242], "start_point": {"row": 44, "column": 30}, "end_point": {"row": 44, "column": 63}}, {"id": 240, "type": "identifier", "text": "void", "parent": 239, "children": [], "start_point": {"row": 44, "column": 30}, "end_point": {"row": 44, "column": 34}}, {"id": 241, "type": "*", "text": "*", "parent": 239, "children": [], "start_point": {"row": 44, "column": 34}, "end_point": {"row": 44, "column": 35}}, {"id": 242, "type": "cast_expression", "text": "(__thiscall*)(void*, void*)", "parent": 239, "children": [243, 247], "start_point": {"row": 44, "column": 36}, "end_point": {"row": 44, "column": 63}}, {"id": 243, "type": "type_descriptor", "text": "__thiscall*", "parent": 242, "children": [244, 245], "start_point": {"row": 44, "column": 37}, "end_point": {"row": 44, "column": 48}}, {"id": 244, "type": "type_identifier", "text": "__thiscall", "parent": 243, "children": [], "start_point": {"row": 44, "column": 37}, "end_point": {"row": 44, "column": 47}}, {"id": 245, "type": "abstract_pointer_declarator", "text": "*", "parent": 243, "children": [246], "start_point": {"row": 44, "column": 47}, "end_point": {"row": 44, "column": 48}}, {"id": 246, "type": "*", "text": "*", "parent": 245, "children": [], "start_point": {"row": 44, "column": 47}, "end_point": {"row": 44, "column": 48}}, {"id": 247, "type": "cast_expression", "text": "(void*, void*)", "parent": 242, "children": [248, 253, 257], "start_point": {"row": 44, "column": 49}, "end_point": {"row": 44, "column": 63}}, {"id": 248, "type": "ERROR", "text": "void*,", "parent": 247, "children": [249], "start_point": {"row": 44, "column": 50}, "end_point": {"row": 44, "column": 56}}, {"id": 249, "type": "type_descriptor", "text": "void*", "parent": 248, "children": [250, 251], "start_point": {"row": 44, "column": 50}, "end_point": {"row": 44, "column": 55}}, {"id": 250, "type": "primitive_type", "text": "void", "parent": 249, "children": [], "start_point": {"row": 44, "column": 50}, "end_point": {"row": 44, "column": 54}}, {"id": 251, "type": "abstract_pointer_declarator", "text": "*", "parent": 249, "children": [252], "start_point": {"row": 44, "column": 54}, "end_point": {"row": 44, "column": 55}}, {"id": 252, "type": "*", "text": "*", "parent": 251, "children": [], "start_point": {"row": 44, "column": 54}, "end_point": {"row": 44, "column": 55}}, {"id": 253, "type": "type_descriptor", "text": "void*", "parent": 247, "children": [254, 255], "start_point": {"row": 44, "column": 57}, "end_point": {"row": 44, "column": 62}}, {"id": 254, "type": "primitive_type", "text": "void", "parent": 253, "children": [], "start_point": {"row": 44, "column": 57}, "end_point": {"row": 44, "column": 61}}, {"id": 255, "type": "abstract_pointer_declarator", "text": "*", "parent": 253, "children": [256], "start_point": {"row": 44, "column": 61}, "end_point": {"row": 44, "column": 62}}, {"id": 256, "type": "*", "text": "*", "parent": 255, "children": [], "start_point": {"row": 44, "column": 61}, "end_point": {"row": 44, "column": 62}}, {"id": 257, "type": "identifier", "text": "", "parent": 247, "children": [], "start_point": {"row": 44, "column": 63}, "end_point": {"row": 44, "column": 63}}, {"id": 258, "type": ">", "text": ">", "parent": 233, "children": [], "start_point": {"row": 44, "column": 63}, "end_point": {"row": 44, "column": 64}}, {"id": 259, "type": "call_expression", "text": "(63)(this, vec)", "parent": 233, "children": [260, 262], "start_point": {"row": 44, "column": 64}, "end_point": {"row": 44, "column": 79}}, {"id": 260, "type": "parenthesized_expression", "text": "(63)", "parent": 259, "children": [261], "start_point": {"row": 44, "column": 64}, "end_point": {"row": 44, "column": 68}}, {"id": 261, "type": "number_literal", "text": "63", "parent": 260, "children": [], "start_point": {"row": 44, "column": 65}, "end_point": {"row": 44, "column": 67}}, {"id": 262, "type": "argument_list", "text": "(this, vec)", "parent": 259, "children": [263, 264], "start_point": {"row": 44, "column": 68}, "end_point": {"row": 44, "column": 79}}, {"id": 263, "type": "identifier", "text": "this", "parent": 262, "children": [], "start_point": {"row": 44, "column": 69}, "end_point": {"row": 44, "column": 73}}, {"id": 264, "type": "identifier", "text": "vec", "parent": 262, "children": [], "start_point": {"row": 44, "column": 75}, "end_point": {"row": 44, "column": 78}}, {"id": 265, "type": "function_definition", "text": "bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }", "parent": 63, "children": [266, 267], "start_point": {"row": 47, "column": 6}, "end_point": {"row": 51, "column": 7}}, {"id": 266, "type": "primitive_type", "text": "bool", "parent": 265, "children": [], "start_point": {"row": 47, "column": 6}, "end_point": {"row": 47, "column": 10}}, {"id": 267, "type": "function_declarator", "text": "Teleport(Vector* vec, EulerAngles* angles)", "parent": 265, "children": [268, 269], "start_point": {"row": 47, "column": 11}, "end_point": {"row": 47, "column": 53}}, {"id": 268, "type": "identifier", "text": "Teleport", "parent": 267, "children": [], "start_point": {"row": 47, "column": 11}, "end_point": {"row": 47, "column": 19}}, {"id": 269, "type": "parameter_list", "text": "(Vector* vec, EulerAngles* angles)", "parent": 267, "children": [270, 275], "start_point": {"row": 47, "column": 19}, "end_point": {"row": 47, "column": 53}}, {"id": 270, "type": "parameter_declaration", "text": "Vector* vec", "parent": 269, "children": [271, 272], "start_point": {"row": 47, "column": 20}, "end_point": {"row": 47, "column": 31}}, {"id": 271, "type": "type_identifier", "text": "Vector", "parent": 270, "children": [], "start_point": {"row": 47, "column": 20}, "end_point": {"row": 47, "column": 26}}, {"id": 272, "type": "pointer_declarator", "text": "* vec", "parent": 270, "children": [273, 274], "start_point": {"row": 47, "column": 26}, "end_point": {"row": 47, "column": 31}}, {"id": 273, "type": "*", "text": "*", "parent": 272, "children": [], "start_point": {"row": 47, "column": 26}, "end_point": {"row": 47, "column": 27}}, {"id": 274, "type": "identifier", "text": "vec", "parent": 272, "children": [], "start_point": {"row": 47, "column": 28}, "end_point": {"row": 47, "column": 31}}, {"id": 275, "type": "parameter_declaration", "text": "EulerAngles* angles", "parent": 269, "children": [276, 277], "start_point": {"row": 47, "column": 33}, "end_point": {"row": 47, "column": 52}}, {"id": 276, "type": "type_identifier", "text": "EulerAngles", "parent": 275, "children": [], "start_point": {"row": 47, "column": 33}, "end_point": {"row": 47, "column": 44}}, {"id": 277, "type": "pointer_declarator", "text": "* angles", "parent": 275, "children": [278, 279], "start_point": {"row": 47, "column": 44}, "end_point": {"row": 47, "column": 52}}, {"id": 278, "type": "*", "text": "*", "parent": 277, "children": [], "start_point": {"row": 47, "column": 44}, "end_point": {"row": 47, "column": 45}}, {"id": 279, "type": "identifier", "text": "angles", "parent": 277, "children": [], "start_point": {"row": 47, "column": 46}, "end_point": {"row": 47, "column": 52}}, {"id": 280, "type": "labeled_statement", "text": "utils::VtableHook hook(this);", "parent": 265, "children": [281, 282], "start_point": {"row": 49, "column": 8}, "end_point": {"row": 49, "column": 37}}, {"id": 281, "type": "statement_identifier", "text": "utils", "parent": 280, "children": [], "start_point": {"row": 49, "column": 8}, "end_point": {"row": 49, "column": 13}}, {"id": 282, "type": "declaration", "text": "VtableHook hook(this);", "parent": 280, "children": [283, 284], "start_point": {"row": 49, "column": 15}, "end_point": {"row": 49, "column": 37}}, {"id": 283, "type": "type_identifier", "text": "VtableHook", "parent": 282, "children": [], "start_point": {"row": 49, "column": 15}, "end_point": {"row": 49, "column": 25}}, {"id": 284, "type": "function_declarator", "text": "hook(this)", "parent": 282, "children": [285, 286], "start_point": {"row": 49, "column": 26}, "end_point": {"row": 49, "column": 36}}, {"id": 285, "type": "identifier", "text": "hook", "parent": 284, "children": [], "start_point": {"row": 49, "column": 26}, "end_point": {"row": 49, "column": 30}}, {"id": 286, "type": "parameter_list", "text": "(this)", "parent": 284, "children": [287], "start_point": {"row": 49, "column": 30}, "end_point": {"row": 49, "column": 36}}, {"id": 287, "type": "parameter_declaration", "text": "this", "parent": 286, "children": [288], "start_point": {"row": 49, "column": 31}, "end_point": {"row": 49, "column": 35}}, {"id": 288, "type": "type_identifier", "text": "this", "parent": 287, "children": [], "start_point": {"row": 49, "column": 31}, "end_point": {"row": 49, "column": 35}}, {"id": 289, "type": "return_statement", "text": "return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);", "parent": 265, "children": [290], "start_point": {"row": 50, "column": 8}, "end_point": {"row": 50, "column": 94}}, {"id": 290, "type": "binary_expression", "text": "hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles)", "parent": 289, "children": [291, 315, 316], "start_point": {"row": 50, "column": 15}, "end_point": {"row": 50, "column": 93}}, {"id": 291, "type": "binary_expression", "text": "hook.GetMethod<bool(__thiscall*)(void*, void*, void*)", "parent": 290, "children": [292, 295, 296], "start_point": {"row": 50, "column": 15}, "end_point": {"row": 50, "column": 68}}, {"id": 292, "type": "field_expression", "text": "hook.GetMethod", "parent": 291, "children": [293, 294], "start_point": {"row": 50, "column": 15}, "end_point": {"row": 50, "column": 29}}, {"id": 293, "type": "identifier", "text": "hook", "parent": 292, "children": [], "start_point": {"row": 50, "column": 15}, "end_point": {"row": 50, "column": 19}}, {"id": 294, "type": "field_identifier", "text": "GetMethod", "parent": 292, "children": [], "start_point": {"row": 50, "column": 20}, "end_point": {"row": 50, "column": 29}}, {"id": 295, "type": "<", "text": "<", "parent": 291, "children": [], "start_point": {"row": 50, "column": 29}, "end_point": {"row": 50, "column": 30}}, {"id": 296, "type": "call_expression", "text": "bool(__thiscall*)(void*, void*, void*)", "parent": 291, "children": [297, 304], "start_point": {"row": 50, "column": 30}, "end_point": {"row": 50, "column": 68}}, {"id": 297, "type": "call_expression", "text": "bool(__thiscall*)", "parent": 296, "children": [298, 299], "start_point": {"row": 50, "column": 30}, "end_point": {"row": 50, "column": 47}}, {"id": 298, "type": "identifier", "text": "bool", "parent": 297, "children": [], "start_point": {"row": 50, "column": 30}, "end_point": {"row": 50, "column": 34}}, {"id": 299, "type": "argument_list", "text": "(__thiscall*)", "parent": 297, "children": [300], "start_point": {"row": 50, "column": 34}, "end_point": {"row": 50, "column": 47}}, {"id": 300, "type": "binary_expression", "text": "__thiscall*", "parent": 299, "children": [301, 302, 303], "start_point": {"row": 50, "column": 35}, "end_point": {"row": 50, "column": 46}}, {"id": 301, "type": "identifier", "text": "__thiscall", "parent": 300, "children": [], "start_point": {"row": 50, "column": 35}, "end_point": {"row": 50, "column": 45}}, {"id": 302, "type": "*", "text": "*", "parent": 300, "children": [], "start_point": {"row": 50, "column": 45}, "end_point": {"row": 50, "column": 46}}, {"id": 303, "type": "identifier", "text": "", "parent": 300, "children": [], "start_point": {"row": 50, "column": 46}, "end_point": {"row": 50, "column": 46}}, {"id": 304, "type": "argument_list", "text": "(void*, void*, void*)", "parent": 296, "children": [305, 309, 310, 312, 313], "start_point": {"row": 50, "column": 47}, "end_point": {"row": 50, "column": 68}}, {"id": 305, "type": "binary_expression", "text": "void*", "parent": 304, "children": [306, 307, 308], "start_point": {"row": 50, "column": 48}, "end_point": {"row": 50, "column": 53}}, {"id": 306, "type": "identifier", "text": "void", "parent": 305, "children": [], "start_point": {"row": 50, "column": 48}, "end_point": {"row": 50, "column": 52}}, {"id": 307, "type": "*", "text": "*", "parent": 305, "children": [], "start_point": {"row": 50, "column": 52}, "end_point": {"row": 50, "column": 53}}, {"id": 308, "type": "identifier", "text": "", "parent": 305, "children": [], "start_point": {"row": 50, "column": 53}, "end_point": {"row": 50, "column": 53}}, {"id": 309, "type": "identifier", "text": "void", "parent": 304, "children": [], "start_point": {"row": 50, "column": 55}, "end_point": {"row": 50, "column": 59}}, {"id": 310, "type": "ERROR", "text": "*", "parent": 304, "children": [311], "start_point": {"row": 50, "column": 59}, "end_point": {"row": 50, "column": 60}}, {"id": 311, "type": "*", "text": "*", "parent": 310, "children": [], "start_point": {"row": 50, "column": 59}, "end_point": {"row": 50, "column": 60}}, {"id": 312, "type": "identifier", "text": "void", "parent": 304, "children": [], "start_point": {"row": 50, "column": 62}, "end_point": {"row": 50, "column": 66}}, {"id": 313, "type": "ERROR", "text": "*", "parent": 304, "children": [314], "start_point": {"row": 50, "column": 66}, "end_point": {"row": 50, "column": 67}}, {"id": 314, "type": "*", "text": "*", "parent": 313, "children": [], "start_point": {"row": 50, "column": 66}, "end_point": {"row": 50, "column": 67}}, {"id": 315, "type": ">", "text": ">", "parent": 290, "children": [], "start_point": {"row": 50, "column": 68}, "end_point": {"row": 50, "column": 69}}, {"id": 316, "type": "call_expression", "text": "(138)(this, vec, angles)", "parent": 290, "children": [317, 319], "start_point": {"row": 50, "column": 69}, "end_point": {"row": 50, "column": 93}}, {"id": 317, "type": "parenthesized_expression", "text": "(138)", "parent": 316, "children": [318], "start_point": {"row": 50, "column": 69}, "end_point": {"row": 50, "column": 74}}, {"id": 318, "type": "number_literal", "text": "138", "parent": 317, "children": [], "start_point": {"row": 50, "column": 70}, "end_point": {"row": 50, "column": 73}}, {"id": 319, "type": "argument_list", "text": "(this, vec, angles)", "parent": 316, "children": [320, 321, 322], "start_point": {"row": 50, "column": 74}, "end_point": {"row": 50, "column": 93}}, {"id": 320, "type": "identifier", "text": "this", "parent": 319, "children": [], "start_point": {"row": 50, "column": 75}, "end_point": {"row": 50, "column": 79}}, {"id": 321, "type": "identifier", "text": "vec", "parent": 319, "children": [], "start_point": {"row": 50, "column": 81}, "end_point": {"row": 50, "column": 84}}, {"id": 322, "type": "identifier", "text": "angles", "parent": 319, "children": [], "start_point": {"row": 50, "column": 86}, "end_point": {"row": 50, "column": 92}}, {"id": 323, "type": "function_definition", "text": "Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }", "parent": 63, "children": [324, 325], "start_point": {"row": 53, "column": 6}, "end_point": {"row": 56, "column": 7}}, {"id": 324, "type": "type_identifier", "text": "Vector", "parent": 323, "children": [], "start_point": {"row": 53, "column": 6}, "end_point": {"row": 53, "column": 12}}, {"id": 325, "type": "function_declarator", "text": "GetWorldPosition()", "parent": 323, "children": [326, 327], "start_point": {"row": 53, "column": 13}, "end_point": {"row": 53, "column": 31}}, {"id": 326, "type": "identifier", "text": "GetWorldPosition", "parent": 325, "children": [], "start_point": {"row": 53, "column": 13}, "end_point": {"row": 53, "column": 29}}, {"id": 327, "type": "parameter_list", "text": "()", "parent": 325, "children": [], "start_point": {"row": 53, "column": 29}, "end_point": {"row": 53, "column": 31}}, {"id": 328, "type": "return_statement", "text": "return *(Vector*)(this + 160);", "parent": 323, "children": [329], "start_point": {"row": 55, "column": 8}, "end_point": {"row": 55, "column": 38}}, {"id": 329, "type": "pointer_expression", "text": "*(Vector*)(this + 160)", "parent": 328, "children": [330, 331], "start_point": {"row": 55, "column": 15}, "end_point": {"row": 55, "column": 37}}, {"id": 330, "type": "*", "text": "*", "parent": 329, "children": [], "start_point": {"row": 55, "column": 15}, "end_point": {"row": 55, "column": 16}}, {"id": 331, "type": "cast_expression", "text": "(Vector*)(this + 160)", "parent": 329, "children": [332, 336], "start_point": {"row": 55, "column": 16}, "end_point": {"row": 55, "column": 37}}, {"id": 332, "type": "type_descriptor", "text": "Vector*", "parent": 331, "children": [333, 334], "start_point": {"row": 55, "column": 17}, "end_point": {"row": 55, "column": 24}}, {"id": 333, "type": "type_identifier", "text": "Vector", "parent": 332, "children": [], "start_point": {"row": 55, "column": 17}, "end_point": {"row": 55, "column": 23}}, {"id": 334, "type": "abstract_pointer_declarator", "text": "*", "parent": 332, "children": [335], "start_point": {"row": 55, "column": 23}, "end_point": {"row": 55, "column": 24}}, {"id": 335, "type": "*", "text": "*", "parent": 334, "children": [], "start_point": {"row": 55, "column": 23}, "end_point": {"row": 55, "column": 24}}, {"id": 336, "type": "parenthesized_expression", "text": "(this + 160)", "parent": 331, "children": [337], "start_point": {"row": 55, "column": 25}, "end_point": {"row": 55, "column": 37}}, {"id": 337, "type": "binary_expression", "text": "this + 160", "parent": 336, "children": [338, 339, 340], "start_point": {"row": 55, "column": 26}, "end_point": {"row": 55, "column": 36}}, {"id": 338, "type": "identifier", "text": "this", "parent": 337, "children": [], "start_point": {"row": 55, "column": 26}, "end_point": {"row": 55, "column": 30}}, {"id": 339, "type": "+", "text": "+", "parent": 337, "children": [], "start_point": {"row": 55, "column": 31}, "end_point": {"row": 55, "column": 32}}, {"id": 340, "type": "number_literal", "text": "160", "parent": 337, "children": [], "start_point": {"row": 55, "column": 33}, "end_point": {"row": 55, "column": 36}}]}, "node_categories": {"declarations": {"functions": [15, 18, 63, 93, 164, 211, 215, 227, 265, 267, 284, 323, 325], "variables": [24, 27, 30, 33, 36, 39, 42, 45, 48, 51, 54, 57, 60, 91, 96, 162, 167, 218, 225, 230, 270, 275, 282, 287], "classes": [21, 22], "imports": [3, 4, 6, 7, 9, 10, 12, 13], "modules": [], "enums": []}, "statements": {"expressions": [69, 70, 75, 77, 80, 81, 86, 99, 100, 101, 102, 103, 111, 113, 118, 124, 125, 130, 134, 135, 140, 141, 146, 148, 151, 152, 157, 170, 171, 172, 173, 174, 182, 184, 189, 195, 196, 201, 205, 206, 233, 234, 235, 239, 242, 247, 259, 260, 290, 291, 292, 296, 297, 300, 305, 316, 317, 329, 331, 336, 337], "assignments": [], "loops": [], "conditionals": [16, 17, 19, 20, 23, 26, 29, 32, 35, 37, 38, 40, 41, 44, 46, 47, 50, 53, 56, 59, 62, 64, 66, 67, 71, 73, 78, 82, 84, 88, 90, 92, 94, 97, 104, 105, 107, 109, 115, 126, 128, 132, 138, 139, 142, 144, 149, 153, 155, 159, 161, 163, 165, 168, 175, 176, 178, 180, 186, 197, 199, 203, 209, 210, 216, 219, 222, 224, 226, 228, 231, 236, 237, 240, 244, 257, 263, 264, 268, 271, 274, 276, 279, 281, 283, 285, 288, 293, 294, 298, 301, 303, 306, 308, 309, 312, 320, 321, 322, 324, 326, 333, 338], "returns": [98, 169, 232, 289, 328], "exceptions": []}, "expressions": {"calls": [0], "literals": [5, 8, 11, 14, 136, 207, 261, 318, 340], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 15, "universal_type": "function", "name": "EntitySpawnParams", "text_snippet": "namespace ProjectNovigrad\n{\n namespace TW3\n {\n struct EntitySpawnParams {\n char v48; // [r"}, {"node_id": 18, "universal_type": "function", "name": "EntitySpawnParams", "text_snippet": "namespace TW3\n {\n struct EntitySpawnParams {\n char v48; // [rsp+A0h] [rbp-60h]\n char v"}, {"node_id": 63, "universal_type": "function", "name": "__declspec(dllexport)", "text_snippet": "class __declspec(dllexport) CEntity\n {\n public:\n TString<wchar_t>* GetUniqueName(TString<"}, {"node_id": 93, "universal_type": "function", "name": "unknown", "text_snippet": "hook(this)"}, {"node_id": 164, "universal_type": "function", "name": "unknown", "text_snippet": "hook(this)"}, {"node_id": 211, "universal_type": "function", "name": "unknown", "text_snippet": "void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.Get"}, {"node_id": 215, "universal_type": "function", "name": "unknown", "text_snippet": "SetPosition(Vector* vec)"}, {"node_id": 227, "universal_type": "function", "name": "unknown", "text_snippet": "hook(this)"}, {"node_id": 265, "universal_type": "function", "name": "Teleport", "text_snippet": "bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n "}, {"node_id": 267, "universal_type": "function", "name": "unknown", "text_snippet": "Teleport(Vector* vec, EulerAngles* angles)"}, {"node_id": 284, "universal_type": "function", "name": "unknown", "text_snippet": "hook(this)"}, {"node_id": 323, "universal_type": "function", "name": "unknown", "text_snippet": "Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }"}, {"node_id": 325, "universal_type": "function", "name": "unknown", "text_snippet": "GetWorldPosition()"}], "class_declarations": [{"node_id": 21, "universal_type": "class", "name": "EntitySpawnParams", "text_snippet": "struct EntitySpawnParams {\n char v48; // [rsp+A0h] [rbp-60h]\n char v49; // [rsp+ACh] [rbp-"}, {"node_id": 22, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": [{"node_id": 3, "text": "#include \"EntityFunctions.h\"\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include \"Node.h\"\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include \"../vtable/vmthooks.h\"\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include \"TString.h\"\n"}, {"node_id": 13, "text": "#include"}]}, "original_source_code": "#pragma once\n\n#include \"EntityFunctions.h\"\n#include \"Node.h\"\n#include \"../vtable/vmthooks.h\"\n#include \"TString.h\"\n\nnamespace ProjectNovigrad\n{\n namespace TW3\n {\n struct EntitySpawnParams {\n char v48; // [rsp+A0h] [rbp-60h]\n char v49; // [rsp+ACh] [rbp-54h]\n char v50; // [rsp+B8h] [rbp-48h]\n char v51; // [rsp+C8h] [rbp-38h]\n Vector position; // [rsp+F0h] [rbp-10h]\n EulerAngles direction; // [rsp+100h] [rbp+0h]\n int v54; // [rsp+108h] [rbp+8h]\n Vector v55; // [rsp+120h] [rbp+20h]\n int v56; // [rsp+130h] [rbp+30h]\n char v57; // [rsp+14Ah] [rbp+4Ah]\n char v58; // [rsp+150h] [rbp+50h]\n char v59; // [rsp+1A8h] [rbp+A8h]\n char v60; // [rsp+1B8h] [rbp+B8h]\n };\n class __declspec(dllexport) CEntity\n {\n public:\n TString<wchar_t>* GetUniqueName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(45)(this, res);\n }\n\n TString<wchar_t>* GetFriendlyName(TString<wchar_t>* res)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<TString<wchar_t>* (__thiscall*)(void*, TString<wchar_t>*)>(27)(this, res);\n }\n\n void* SetPosition(Vector* vec)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<void* (__thiscall*)(void*, void*)>(63)(this, vec);\n }\n\n bool Teleport(Vector* vec, EulerAngles* angles)\n {\n utils::VtableHook hook(this);\n return hook.GetMethod<bool(__thiscall*)(void*, void*, void*)>(138)(this, vec, angles);\n }\n\n Vector GetWorldPosition()\n {\n return *(Vector*)(this + 160);\n }\n };\n }\n}"}
80,508
c
#ifndef INDEX_H #define INDEX_H #include "transaction.h" #include "block.h" class CBlock; class COutPoint; /** Position on disk for a particular transaction. */ class CDiskTxPos { public: unsigned int nFile; unsigned int nBlockPos; unsigned int nTxPos; CDiskTxPos() { SetNull(); } CDiskTxPos(unsigned int nFileIn, unsigned int nBlockPosIn, unsigned int nTxPosIn) { nFile = nFileIn; nBlockPos = nBlockPosIn; nTxPos = nTxPosIn; } IMPLEMENT_SERIALIZE( READWRITE(FLATDATA(*this)); ) void SetNull() { nFile = (unsigned int) -1; nBlockPos = 0; nTxPos = 0; } bool IsNull() const { return (nFile == (unsigned int) -1); } friend bool operator==(const CDiskTxPos& a, const CDiskTxPos& b) { return (a.nFile == b.nFile && a.nBlockPos == b.nBlockPos && a.nTxPos == b.nTxPos); } friend bool operator!=(const CDiskTxPos& a, const CDiskTxPos& b) { return !(a == b); } std::string ToString() const { if (IsNull()) return "null"; else return strprintf("(nFile=%u, nBlockPos=%u, nTxPos=%u)", nFile, nBlockPos, nTxPos); } void print() const { printf("%s", ToString().c_str()); } }; /** A txdb record that contains the disk location of a transaction and the * locations of transactions that spend its outputs. vSpent is really only * used as a flag, but having the location is very helpful for debugging. */ class CTxIndex { public: CDiskTxPos pos; std::vector<CDiskTxPos> vSpent; CTxIndex() { SetNull(); } CTxIndex(const CDiskTxPos& posIn, unsigned int nOutputs) { pos = posIn; vSpent.resize(nOutputs); } IMPLEMENT_SERIALIZE ( if (!(nType & SER_GETHASH)) READWRITE(nVersion); READWRITE(pos); READWRITE(vSpent); ) void SetNull() { pos.SetNull(); vSpent.clear(); } bool IsNull() { return pos.IsNull(); } friend bool operator==(const CTxIndex& a, const CTxIndex& b) { return (a.pos == b.pos && a.vSpent == b.vSpent); } friend bool operator!=(const CTxIndex& a, const CTxIndex& b) { return !(a == b); } int GetDepthInMainChain() const; }; /** The block chain is a tree shaped structure starting with the * genesis block at the root, with each block potentially having multiple * candidates to be the next block. pprev and pnext link a path through the * main/longest chain. A blockindex may have multiple pprev pointing back * to it, but pnext will only point forward to the longest branch, or will * be null if the block is not part of the longest chain. */ class CBlockIndex { public: const uint256* phashBlock; CBlockIndex* pprev; CBlockIndex* pnext; unsigned int nFile; unsigned int nBlockPos; uint256 nChainTrust; // ppcoin: trust score of block chain int nHeight; int64 nMint; int64 nMoneySupply; unsigned int nFlags; // ppcoin: block index flags enum { BLOCK_PROOF_OF_STAKE = (1 << 0), // is proof-of-stake block BLOCK_STAKE_ENTROPY = (1 << 1), // entropy bit for stake modifier BLOCK_STAKE_MODIFIER = (1 << 2), // regenerated stake modifier }; uint64 nStakeModifier; // hash modifier for proof-of-stake unsigned int nStakeModifierChecksum; // checksum of index; in-memeory only // proof-of-stake specific fields COutPoint prevoutStake; unsigned int nStakeTime; uint256 hashProofOfStake; // block header int nVersion; uint256 hashMerkleRoot; unsigned int nTime; unsigned int nBits; unsigned int nNonce; CBlockIndex() { phashBlock = NULL; pprev = NULL; pnext = NULL; nFile = 0; nBlockPos = 0; nHeight = 0; nChainTrust = 0; nMint = 0; nMoneySupply = 0; nFlags = 0; nStakeModifier = 0; nStakeModifierChecksum = 0; hashProofOfStake = 0; prevoutStake.SetNull(); nStakeTime = 0; nVersion = 0; hashMerkleRoot = 0; nTime = 0; nBits = 0; nNonce = 0; } CBlockIndex(unsigned int nFileIn, unsigned int nBlockPosIn, CBlock& block); CBlock GetBlockHeader() const; uint256 GetBlockHash() const; int64 GetBlockTime() const; uint256 GetBlockTrust() const; bool IsInMainChain() const; bool CheckIndex() const; enum { nMedianTimeSpan=11 }; int64 GetMedianTimePast() const; int64 GetMedianTime() const; /** * Returns true if there are nRequired or more blocks of minVersion or above * in the last nToCheck blocks, starting at pstart and going backwards. */ bool IsSuperMajority(int minVersion, const CBlockIndex* pstart, unsigned int nRequired, unsigned int nToCheck); bool IsProofOfWork() const; bool IsProofOfStake() const; void SetProofOfStake(); unsigned int GetStakeEntropyBit() const; bool SetStakeEntropyBit(unsigned int nEntropyBit); bool GeneratedStakeModifier() const; void SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier); std::string ToString() const; void print() const; }; /** Used to marshal pointers into hashes for db storage. */ class CDiskBlockIndex : public CBlockIndex { public: uint256 hashPrev; uint256 hashNext; CDiskBlockIndex() { hashPrev = 0; hashNext = 0; } explicit CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex) { hashPrev = (pprev ? pprev->GetBlockHash() : 0); hashNext = (pnext ? pnext->GetBlockHash() : 0); } IMPLEMENT_SERIALIZE ( if (!(nType & SER_GETHASH)) READWRITE(nVersion); READWRITE(hashNext); READWRITE(nFile); READWRITE(nBlockPos); READWRITE(nHeight); READWRITE(nMint); READWRITE(nMoneySupply); READWRITE(nFlags); READWRITE(nStakeModifier); if (IsProofOfStake()) { READWRITE(prevoutStake); READWRITE(nStakeTime); READWRITE(hashProofOfStake); } else if (fRead) { const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull(); const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0; const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0; } // block header READWRITE(this->nVersion); READWRITE(hashPrev); READWRITE(hashMerkleRoot); READWRITE(nTime); READWRITE(nBits); READWRITE(nNonce); ) uint256 GetBlockHash() const { CBlock block; block.nVersion = nVersion; block.hashPrevBlock = hashPrev; block.hashMerkleRoot = hashMerkleRoot; block.nTime = nTime; block.nBits = nBits; block.nNonce = nNonce; return block.GetHash(); } std::string ToString() const { std::string str = "CDiskBlockIndex("; str += CBlockIndex::ToString(); str += strprintf("\n hashBlock=%s, hashPrev=%s, hashNext=%s)", GetBlockHash().ToString().c_str(), hashPrev.ToString().c_str(), hashNext.ToString().c_str()); return str; } void print() const { printf("%s\n", ToString().c_str()); } }; #endif // INDEX_H
28.1
261
(translation_unit) "#ifndef INDEX_H\n#define INDEX_H\n\n#include "transaction.h"\n#include "block.h"\n\nclass CBlock;\nclass COutPoint;\n\n/** Position on disk for a particular transaction. */\nclass CDiskTxPos\n{\npublic:\n unsigned int nFile;\n unsigned int nBlockPos;\n unsigned int nTxPos;\n\n CDiskTxPos()\n {\n SetNull();\n }\n\n CDiskTxPos(unsigned int nFileIn, unsigned int nBlockPosIn, unsigned int nTxPosIn)\n {\n nFile = nFileIn;\n nBlockPos = nBlockPosIn;\n nTxPos = nTxPosIn;\n }\n\n IMPLEMENT_SERIALIZE( READWRITE(FLATDATA(*this)); )\n void SetNull() { nFile = (unsigned int) -1; nBlockPos = 0; nTxPos = 0; }\n bool IsNull() const { return (nFile == (unsigned int) -1); }\n\n friend bool operator==(const CDiskTxPos& a, const CDiskTxPos& b)\n {\n return (a.nFile == b.nFile &&\n a.nBlockPos == b.nBlockPos &&\n a.nTxPos == b.nTxPos);\n }\n\n friend bool operator!=(const CDiskTxPos& a, const CDiskTxPos& b)\n {\n return !(a == b);\n }\n\n\n std::string ToString() const\n {\n if (IsNull())\n return "null";\n else\n return strprintf("(nFile=%u, nBlockPos=%u, nTxPos=%u)", nFile, nBlockPos, nTxPos);\n }\n\n void print() const\n {\n printf("%s", ToString().c_str());\n }\n};\n\n\n\n/** A txdb record that contains the disk location of a transaction and the\n * locations of transactions that spend its outputs. vSpent is really only\n * used as a flag, but having the location is very helpful for debugging.\n */\nclass CTxIndex\n{\npublic:\n CDiskTxPos pos;\n std::vector<CDiskTxPos> vSpent;\n\n CTxIndex()\n {\n SetNull();\n }\n\n CTxIndex(const CDiskTxPos& posIn, unsigned int nOutputs)\n {\n pos = posIn;\n vSpent.resize(nOutputs);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);\n READWRITE(vSpent);\n )\n\n void SetNull()\n {\n pos.SetNull();\n vSpent.clear();\n }\n\n bool IsNull()\n {\n return pos.IsNull();\n }\n\n friend bool operator==(const CTxIndex& a, const CTxIndex& b)\n {\n return (a.pos == b.pos &&\n a.vSpent == b.vSpent);\n }\n\n friend bool operator!=(const CTxIndex& a, const CTxIndex& b)\n {\n return !(a == b);\n }\n int GetDepthInMainChain() const;\n\n};\n\n/** The block chain is a tree shaped structure starting with the\n * genesis block at the root, with each block potentially having multiple\n * candidates to be the next block. pprev and pnext link a path through the\n * main/longest chain. A blockindex may have multiple pprev pointing back\n * to it, but pnext will only point forward to the longest branch, or will\n * be null if the block is not part of the longest chain.\n */\nclass CBlockIndex\n{\npublic:\n const uint256* phashBlock;\n CBlockIndex* pprev;\n CBlockIndex* pnext;\n unsigned int nFile;\n unsigned int nBlockPos;\n uint256 nChainTrust; // ppcoin: trust score of block chain\n int nHeight;\n\n int64 nMint;\n int64 nMoneySupply;\n\n unsigned int nFlags; // ppcoin: block index flags\n enum\n {\n BLOCK_PROOF_OF_STAKE = (1 << 0), // is proof-of-stake block\n BLOCK_STAKE_ENTROPY = (1 << 1), // entropy bit for stake modifier\n BLOCK_STAKE_MODIFIER = (1 << 2), // regenerated stake modifier\n };\n\n uint64 nStakeModifier; // hash modifier for proof-of-stake\n unsigned int nStakeModifierChecksum; // checksum of index; in-memeory only\n\n // proof-of-stake specific fields\n COutPoint prevoutStake;\n unsigned int nStakeTime;\n uint256 hashProofOfStake;\n\n // block header\n int nVersion;\n uint256 hashMerkleRoot;\n unsigned int nTime;\n unsigned int nBits;\n unsigned int nNonce;\n\n CBlockIndex()\n {\n phashBlock = NULL;\n pprev = NULL;\n pnext = NULL;\n nFile = 0;\n nBlockPos = 0;\n nHeight = 0;\n nChainTrust = 0;\n nMint = 0;\n nMoneySupply = 0;\n nFlags = 0;\n nStakeModifier = 0;\n nStakeModifierChecksum = 0;\n hashProofOfStake = 0;\n prevoutStake.SetNull();\n nStakeTime = 0;\n\n nVersion = 0;\n hashMerkleRoot = 0;\n nTime = 0;\n nBits = 0;\n nNonce = 0;\n }\n\n CBlockIndex(unsigned int nFileIn, unsigned int nBlockPosIn, CBlock& block);\n\n CBlock GetBlockHeader() const;\n uint256 GetBlockHash() const;\n int64 GetBlockTime() const;\n uint256 GetBlockTrust() const;\n bool IsInMainChain() const;\n bool CheckIndex() const;\n\n enum { nMedianTimeSpan=11 };\n\n int64 GetMedianTimePast() const;\n\n int64 GetMedianTime() const;\n /**\n * Returns true if there are nRequired or more blocks of minVersion or above\n * in the last nToCheck blocks, starting at pstart and going backwards.\n */\n bool IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck);\n\n\n bool IsProofOfWork() const;\n bool IsProofOfStake() const;\n void SetProofOfStake();\n unsigned int GetStakeEntropyBit() const;\n bool SetStakeEntropyBit(unsigned int nEntropyBit);\n bool GeneratedStakeModifier() const;\n void SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier);\n std::string ToString() const;\n void print() const;\n};\n\n\n\n/** Used to marshal pointers into hashes for db storage. */\nclass CDiskBlockIndex : public CBlockIndex\n{\npublic:\n uint256 hashPrev;\n uint256 hashNext;\n\n CDiskBlockIndex()\n {\n hashPrev = 0;\n hashNext = 0;\n }\n\n explicit CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex)\n {\n hashPrev = (pprev ? pprev->GetBlockHash() : 0);\n hashNext = (pnext ? pnext->GetBlockHash() : 0);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);\n READWRITE(nStakeModifier);\n if (IsProofOfStake())\n {\n READWRITE(prevoutStake);\n READWRITE(nStakeTime);\n READWRITE(hashProofOfStake);\n }\n else if (fRead)\n {\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }\n\n // block header\n READWRITE(this->nVersion);\n READWRITE(hashPrev);\n READWRITE(hashMerkleRoot);\n READWRITE(nTime);\n READWRITE(nBits);\n READWRITE(nNonce);\n )\n\n uint256 GetBlockHash() const\n {\n CBlock block;\n block.nVersion = nVersion;\n block.hashPrevBlock = hashPrev;\n block.hashMerkleRoot = hashMerkleRoot;\n block.nTime = nTime;\n block.nBits = nBits;\n block.nNonce = nNonce;\n return block.GetHash();\n }\n\n\n std::string ToString() const\n {\n std::string str = "CDiskBlockIndex(";\n str += CBlockIndex::ToString();\n str += strprintf("\n hashBlock=%s, hashPrev=%s, hashNext=%s)",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str());\n return str;\n }\n\n void print() const\n {\n printf("%s\n", ToString().c_str());\n }\n};\n\n\n\n#endif // INDEX_H\n" (preproc_ifdef) "#ifndef INDEX_H\n#define INDEX_H\n\n#include "transaction.h"\n#include "block.h"\n\nclass CBlock;\nclass COutPoint;\n\n/** Position on disk for a particular transaction. */\nclass CDiskTxPos\n{\npublic:\n unsigned int nFile;\n unsigned int nBlockPos;\n unsigned int nTxPos;\n\n CDiskTxPos()\n {\n SetNull();\n }\n\n CDiskTxPos(unsigned int nFileIn, unsigned int nBlockPosIn, unsigned int nTxPosIn)\n {\n nFile = nFileIn;\n nBlockPos = nBlockPosIn;\n nTxPos = nTxPosIn;\n }\n\n IMPLEMENT_SERIALIZE( READWRITE(FLATDATA(*this)); )\n void SetNull() { nFile = (unsigned int) -1; nBlockPos = 0; nTxPos = 0; }\n bool IsNull() const { return (nFile == (unsigned int) -1); }\n\n friend bool operator==(const CDiskTxPos& a, const CDiskTxPos& b)\n {\n return (a.nFile == b.nFile &&\n a.nBlockPos == b.nBlockPos &&\n a.nTxPos == b.nTxPos);\n }\n\n friend bool operator!=(const CDiskTxPos& a, const CDiskTxPos& b)\n {\n return !(a == b);\n }\n\n\n std::string ToString() const\n {\n if (IsNull())\n return "null";\n else\n return strprintf("(nFile=%u, nBlockPos=%u, nTxPos=%u)", nFile, nBlockPos, nTxPos);\n }\n\n void print() const\n {\n printf("%s", ToString().c_str());\n }\n};\n\n\n\n/** A txdb record that contains the disk location of a transaction and the\n * locations of transactions that spend its outputs. vSpent is really only\n * used as a flag, but having the location is very helpful for debugging.\n */\nclass CTxIndex\n{\npublic:\n CDiskTxPos pos;\n std::vector<CDiskTxPos> vSpent;\n\n CTxIndex()\n {\n SetNull();\n }\n\n CTxIndex(const CDiskTxPos& posIn, unsigned int nOutputs)\n {\n pos = posIn;\n vSpent.resize(nOutputs);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);\n READWRITE(vSpent);\n )\n\n void SetNull()\n {\n pos.SetNull();\n vSpent.clear();\n }\n\n bool IsNull()\n {\n return pos.IsNull();\n }\n\n friend bool operator==(const CTxIndex& a, const CTxIndex& b)\n {\n return (a.pos == b.pos &&\n a.vSpent == b.vSpent);\n }\n\n friend bool operator!=(const CTxIndex& a, const CTxIndex& b)\n {\n return !(a == b);\n }\n int GetDepthInMainChain() const;\n\n};\n\n/** The block chain is a tree shaped structure starting with the\n * genesis block at the root, with each block potentially having multiple\n * candidates to be the next block. pprev and pnext link a path through the\n * main/longest chain. A blockindex may have multiple pprev pointing back\n * to it, but pnext will only point forward to the longest branch, or will\n * be null if the block is not part of the longest chain.\n */\nclass CBlockIndex\n{\npublic:\n const uint256* phashBlock;\n CBlockIndex* pprev;\n CBlockIndex* pnext;\n unsigned int nFile;\n unsigned int nBlockPos;\n uint256 nChainTrust; // ppcoin: trust score of block chain\n int nHeight;\n\n int64 nMint;\n int64 nMoneySupply;\n\n unsigned int nFlags; // ppcoin: block index flags\n enum\n {\n BLOCK_PROOF_OF_STAKE = (1 << 0), // is proof-of-stake block\n BLOCK_STAKE_ENTROPY = (1 << 1), // entropy bit for stake modifier\n BLOCK_STAKE_MODIFIER = (1 << 2), // regenerated stake modifier\n };\n\n uint64 nStakeModifier; // hash modifier for proof-of-stake\n unsigned int nStakeModifierChecksum; // checksum of index; in-memeory only\n\n // proof-of-stake specific fields\n COutPoint prevoutStake;\n unsigned int nStakeTime;\n uint256 hashProofOfStake;\n\n // block header\n int nVersion;\n uint256 hashMerkleRoot;\n unsigned int nTime;\n unsigned int nBits;\n unsigned int nNonce;\n\n CBlockIndex()\n {\n phashBlock = NULL;\n pprev = NULL;\n pnext = NULL;\n nFile = 0;\n nBlockPos = 0;\n nHeight = 0;\n nChainTrust = 0;\n nMint = 0;\n nMoneySupply = 0;\n nFlags = 0;\n nStakeModifier = 0;\n nStakeModifierChecksum = 0;\n hashProofOfStake = 0;\n prevoutStake.SetNull();\n nStakeTime = 0;\n\n nVersion = 0;\n hashMerkleRoot = 0;\n nTime = 0;\n nBits = 0;\n nNonce = 0;\n }\n\n CBlockIndex(unsigned int nFileIn, unsigned int nBlockPosIn, CBlock& block);\n\n CBlock GetBlockHeader() const;\n uint256 GetBlockHash() const;\n int64 GetBlockTime() const;\n uint256 GetBlockTrust() const;\n bool IsInMainChain() const;\n bool CheckIndex() const;\n\n enum { nMedianTimeSpan=11 };\n\n int64 GetMedianTimePast() const;\n\n int64 GetMedianTime() const;\n /**\n * Returns true if there are nRequired or more blocks of minVersion or above\n * in the last nToCheck blocks, starting at pstart and going backwards.\n */\n bool IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck);\n\n\n bool IsProofOfWork() const;\n bool IsProofOfStake() const;\n void SetProofOfStake();\n unsigned int GetStakeEntropyBit() const;\n bool SetStakeEntropyBit(unsigned int nEntropyBit);\n bool GeneratedStakeModifier() const;\n void SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier);\n std::string ToString() const;\n void print() const;\n};\n\n\n\n/** Used to marshal pointers into hashes for db storage. */\nclass CDiskBlockIndex : public CBlockIndex\n{\npublic:\n uint256 hashPrev;\n uint256 hashNext;\n\n CDiskBlockIndex()\n {\n hashPrev = 0;\n hashNext = 0;\n }\n\n explicit CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex)\n {\n hashPrev = (pprev ? pprev->GetBlockHash() : 0);\n hashNext = (pnext ? pnext->GetBlockHash() : 0);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);\n READWRITE(nStakeModifier);\n if (IsProofOfStake())\n {\n READWRITE(prevoutStake);\n READWRITE(nStakeTime);\n READWRITE(hashProofOfStake);\n }\n else if (fRead)\n {\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }\n\n // block header\n READWRITE(this->nVersion);\n READWRITE(hashPrev);\n READWRITE(hashMerkleRoot);\n READWRITE(nTime);\n READWRITE(nBits);\n READWRITE(nNonce);\n )\n\n uint256 GetBlockHash() const\n {\n CBlock block;\n block.nVersion = nVersion;\n block.hashPrevBlock = hashPrev;\n block.hashMerkleRoot = hashMerkleRoot;\n block.nTime = nTime;\n block.nBits = nBits;\n block.nNonce = nNonce;\n return block.GetHash();\n }\n\n\n std::string ToString() const\n {\n std::string str = "CDiskBlockIndex(";\n str += CBlockIndex::ToString();\n str += strprintf("\n hashBlock=%s, hashPrev=%s, hashNext=%s)",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str());\n return str;\n }\n\n void print() const\n {\n printf("%s\n", ToString().c_str());\n }\n};\n\n\n\n#endif" (#ifndef) "#ifndef" (identifier) "INDEX_H" (preproc_def) "#define INDEX_H\n" (#define) "#define" (identifier) "INDEX_H" (preproc_include) "#include "transaction.h"\n" (#include) "#include" (string_literal) ""transaction.h"" (") """ (string_content) "transaction.h" (") """ (preproc_include) "#include "block.h"\n" (#include) "#include" (string_literal) ""block.h"" (") """ (string_content) "block.h" (") """ (declaration) "class CBlock;" (type_identifier) "class" (identifier) "CBlock" (;) ";" (declaration) "class COutPoint;" (type_identifier) "class" (identifier) "COutPoint" (;) ";" (comment) "/** Position on disk for a particular transaction. */" (function_definition) "class CDiskTxPos\n{\npublic:\n unsigned int nFile;\n unsigned int nBlockPos;\n unsigned int nTxPos;\n\n CDiskTxPos()\n {\n SetNull();\n }\n\n CDiskTxPos(unsigned int nFileIn, unsigned int nBlockPosIn, unsigned int nTxPosIn)\n {\n nFile = nFileIn;\n nBlockPos = nBlockPosIn;\n nTxPos = nTxPosIn;\n }" (type_identifier) "class" (identifier) "CDiskTxPos" (compound_statement) "{\npublic:\n unsigned int nFile;\n unsigned int nBlockPos;\n unsigned int nTxPos;\n\n CDiskTxPos()\n {\n SetNull();\n }\n\n CDiskTxPos(unsigned int nFileIn, unsigned int nBlockPosIn, unsigned int nTxPosIn)\n {\n nFile = nFileIn;\n nBlockPos = nBlockPosIn;\n nTxPos = nTxPosIn;\n }" ({) "{" (labeled_statement) "public:\n unsigned int nFile;" (statement_identifier) "public" (:) ":" (declaration) "unsigned int nFile;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nFile" (;) ";" (declaration) "unsigned int nBlockPos;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nBlockPos" (;) ";" (declaration) "unsigned int nTxPos;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nTxPos" (;) ";" (expression_statement) "CDiskTxPos()" (call_expression) "CDiskTxPos()" (identifier) "CDiskTxPos" (argument_list) "()" (() "(" ()) ")" (;) "" (compound_statement) "{\n SetNull();\n }" ({) "{" (expression_statement) "SetNull();" (call_expression) "SetNull()" (identifier) "SetNull" (argument_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (declaration) "CDiskTxPos(unsigned int nFileIn, unsigned int nBlockPosIn, unsigned int nTxPosIn)\n {\n nFile = nFileIn;" (macro_type_specifier) "CDiskTxPos(unsigned int" (identifier) "CDiskTxPos" (() "(" (type_descriptor) "unsigned int" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" ()) "" (identifier) "nFileIn" (,) "," (ERROR) "unsigned int" (identifier) "unsigned" (identifier) "int" (identifier) "nBlockPosIn" (,) "," (ERROR) "unsigned int nTxPosIn)\n {" (identifier) "unsigned" (identifier) "int" (identifier) "nTxPosIn" ()) ")" ({) "{" (init_declarator) "nFile = nFileIn" (identifier) "nFile" (=) "=" (identifier) "nFileIn" (;) ";" (expression_statement) "nBlockPos = nBlockPosIn;" (assignment_expression) "nBlockPos = nBlockPosIn" (identifier) "nBlockPos" (=) "=" (identifier) "nBlockPosIn" (;) ";" (expression_statement) "nTxPos = nTxPosIn;" (assignment_expression) "nTxPos = nTxPosIn" (identifier) "nTxPos" (=) "=" (identifier) "nTxPosIn" (;) ";" (}) "}" (expression_statement) "IMPLEMENT_SERIALIZE( READWRITE(FLATDATA(*this)); )" (call_expression) "IMPLEMENT_SERIALIZE( READWRITE(FLATDATA(*this)); )" (identifier) "IMPLEMENT_SERIALIZE" (argument_list) "( READWRITE(FLATDATA(*this)); )" (() "(" (call_expression) "READWRITE(FLATDATA(*this))" (identifier) "READWRITE" (argument_list) "(FLATDATA(*this))" (() "(" (call_expression) "FLATDATA(*this)" (identifier) "FLATDATA" (argument_list) "(*this)" (() "(" (pointer_expression) "*this" (*) "*" (identifier) "this" ()) ")" ()) ")" (ERROR) ";" (;) ";" ()) ")" (;) "" (function_definition) "void SetNull() { nFile = (unsigned int) -1; nBlockPos = 0; nTxPos = 0; }" (primitive_type) "void" (function_declarator) "SetNull()" (identifier) "SetNull" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{ nFile = (unsigned int) -1; nBlockPos = 0; nTxPos = 0; }" ({) "{" (expression_statement) "nFile = (unsigned int) -1;" (assignment_expression) "nFile = (unsigned int) -1" (identifier) "nFile" (=) "=" (cast_expression) "(unsigned int) -1" (() "(" (type_descriptor) "unsigned int" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" ()) ")" (number_literal) "-1" (;) ";" (expression_statement) "nBlockPos = 0;" (assignment_expression) "nBlockPos = 0" (identifier) "nBlockPos" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "nTxPos = 0;" (assignment_expression) "nTxPos = 0" (identifier) "nTxPos" (=) "=" (number_literal) "0" (;) ";" (}) "}" (ERROR) "bool IsNull() const" (primitive_type) "bool" (function_declarator) "IsNull()" (identifier) "IsNull" (parameter_list) "()" (() "(" ()) ")" (type_qualifier) "const" (const) "const" (compound_statement) "{ return (nFile == (unsigned int) -1); }" ({) "{" (return_statement) "return (nFile == (unsigned int) -1);" (return) "return" (parenthesized_expression) "(nFile == (unsigned int) -1)" (() "(" (binary_expression) "nFile == (unsigned int) -1" (identifier) "nFile" (==) "==" (cast_expression) "(unsigned int) -1" (() "(" (type_descriptor) "unsigned int" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" ()) ")" (number_literal) "-1" ()) ")" (;) ";" (}) "}" (declaration) "friend bool" (type_identifier) "friend" (identifier) "bool" (;) "" (expression_statement) "operator==(const CDiskTxPos& a, const CDiskTxPos& b)" (binary_expression) "operator==(const CDiskTxPos& a, const CDiskTxPos& b)" (identifier) "operator" (==) "==" (parenthesized_expression) "(const CDiskTxPos& a, const CDiskTxPos& b)" (() "(" (ERROR) "const CDiskTxPos" (type_descriptor) "const CDiskTxPos" (type_qualifier) "const" (const) "const" (type_identifier) "CDiskTxPos" (comma_expression) "& a, const CDiskTxPos& b" (pointer_expression) "& a" (&) "&" (identifier) "a" (,) "," (ERROR) "const" (identifier) "const" (binary_expression) "CDiskTxPos& b" (identifier) "CDiskTxPos" (&) "&" (identifier) "b" ()) ")" (;) "" (compound_statement) "{\n return (a.nFile == b.nFile &&\n a.nBlockPos == b.nBlockPos &&\n a.nTxPos == b.nTxPos);\n }" ({) "{" (return_statement) "return (a.nFile == b.nFile &&\n a.nBlockPos == b.nBlockPos &&\n a.nTxPos == b.nTxPos);" (return) "return" (parenthesized_expression) "(a.nFile == b.nFile &&\n a.nBlockPos == b.nBlockPos &&\n a.nTxPos == b.nTxPos)" (() "(" (binary_expression) "a.nFile == b.nFile &&\n a.nBlockPos == b.nBlockPos &&\n a.nTxPos == b.nTxPos" (binary_expression) "a.nFile == b.nFile &&\n a.nBlockPos == b.nBlockPos" (binary_expression) "a.nFile == b.nFile" (field_expression) "a.nFile" (identifier) "a" (.) "." (field_identifier) "nFile" (==) "==" (field_expression) "b.nFile" (identifier) "b" (.) "." (field_identifier) "nFile" (&&) "&&" (binary_expression) "a.nBlockPos == b.nBlockPos" (field_expression) "a.nBlockPos" (identifier) "a" (.) "." (field_identifier) "nBlockPos" (==) "==" (field_expression) "b.nBlockPos" (identifier) "b" (.) "." (field_identifier) "nBlockPos" (&&) "&&" (binary_expression) "a.nTxPos == b.nTxPos" (field_expression) "a.nTxPos" (identifier) "a" (.) "." (field_identifier) "nTxPos" (==) "==" (field_expression) "b.nTxPos" (identifier) "b" (.) "." (field_identifier) "nTxPos" ()) ")" (;) ";" (}) "}" (declaration) "friend bool" (type_identifier) "friend" (identifier) "bool" (;) "" (expression_statement) "operator!=(const CDiskTxPos& a, const CDiskTxPos& b)" (binary_expression) "operator!=(const CDiskTxPos& a, const CDiskTxPos& b)" (identifier) "operator" (!=) "!=" (parenthesized_expression) "(const CDiskTxPos& a, const CDiskTxPos& b)" (() "(" (ERROR) "const CDiskTxPos" (type_descriptor) "const CDiskTxPos" (type_qualifier) "const" (const) "const" (type_identifier) "CDiskTxPos" (comma_expression) "& a, const CDiskTxPos& b" (pointer_expression) "& a" (&) "&" (identifier) "a" (,) "," (ERROR) "const" (identifier) "const" (binary_expression) "CDiskTxPos& b" (identifier) "CDiskTxPos" (&) "&" (identifier) "b" ()) ")" (;) "" (compound_statement) "{\n return !(a == b);\n }" ({) "{" (return_statement) "return !(a == b);" (return) "return" (unary_expression) "!(a == b)" (!) "!" (parenthesized_expression) "(a == b)" (() "(" (binary_expression) "a == b" (identifier) "a" (==) "==" (identifier) "b" ()) ")" (;) ";" (}) "}" (labeled_statement) "std::string ToString() const\n {\n if (IsNull())\n return "null";\n else\n return strprintf("(nFile=%u, nBlockPos=%u, nTxPos=%u)", nFile, nBlockPos, nTxPos);\n }" (statement_identifier) "std" (:) ":" (ERROR) ":string ToString() const" (:) ":" (type_identifier) "string" (function_declarator) "ToString() const" (identifier) "ToString" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (compound_statement) "{\n if (IsNull())\n return "null";\n else\n return strprintf("(nFile=%u, nBlockPos=%u, nTxPos=%u)", nFile, nBlockPos, nTxPos);\n }" ({) "{" (if_statement) "if (IsNull())\n return "null";\n else\n return strprintf("(nFile=%u, nBlockPos=%u, nTxPos=%u)", nFile, nBlockPos, nTxPos);" (if) "if" (parenthesized_expression) "(IsNull())" (() "(" (call_expression) "IsNull()" (identifier) "IsNull" (argument_list) "()" (() "(" ()) ")" ()) ")" (return_statement) "return "null";" (return) "return" (string_literal) ""null"" (") """ (string_content) "null" (") """ (;) ";" (else_clause) "else\n return strprintf("(nFile=%u, nBlockPos=%u, nTxPos=%u)", nFile, nBlockPos, nTxPos);" (else) "else" (return_statement) "return strprintf("(nFile=%u, nBlockPos=%u, nTxPos=%u)", nFile, nBlockPos, nTxPos);" (return) "return" (call_expression) "strprintf("(nFile=%u, nBlockPos=%u, nTxPos=%u)", nFile, nBlockPos, nTxPos)" (identifier) "strprintf" (argument_list) "("(nFile=%u, nBlockPos=%u, nTxPos=%u)", nFile, nBlockPos, nTxPos)" (() "(" (string_literal) ""(nFile=%u, nBlockPos=%u, nTxPos=%u)"" (") """ (string_content) "(nFile=%u, nBlockPos=%u, nTxPos=%u)" (") """ (,) "," (identifier) "nFile" (,) "," (identifier) "nBlockPos" (,) "," (identifier) "nTxPos" ()) ")" (;) ";" (}) "}" (ERROR) "void print() const" (primitive_type) "void" (function_declarator) "print()" (identifier) "print" (parameter_list) "()" (() "(" ()) ")" (type_qualifier) "const" (const) "const" (compound_statement) "{\n printf("%s", ToString().c_str());\n }" ({) "{" (expression_statement) "printf("%s", ToString().c_str());" (call_expression) "printf("%s", ToString().c_str())" (identifier) "printf" (argument_list) "("%s", ToString().c_str())" (() "(" (string_literal) ""%s"" (") """ (string_content) "%s" (") """ (,) "," (call_expression) "ToString().c_str()" (field_expression) "ToString().c_str" (call_expression) "ToString()" (identifier) "ToString" (argument_list) "()" (() "(" ()) ")" (.) "." (field_identifier) "c_str" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) ";" (}) "}" (ERROR) "}" (}) "}" (expression_statement) ";" (;) ";" (comment) "/** A txdb record that contains the disk location of a transaction and the\n * locations of transactions that spend its outputs. vSpent is really only\n * used as a flag, but having the location is very helpful for debugging.\n */" (function_definition) "class CTxIndex\n{\npublic:\n CDiskTxPos pos;\n std::vector<CDiskTxPos> vSpent;\n\n CTxIndex()\n {\n SetNull();\n }\n\n CTxIndex(const CDiskTxPos& posIn, unsigned int nOutputs)\n {\n pos = posIn;\n vSpent.resize(nOutputs);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);\n READWRITE(vSpent);\n )\n\n void SetNull()\n {\n pos.SetNull();\n vSpent.clear();\n }\n\n bool IsNull()\n {\n return pos.IsNull();\n }\n\n friend bool operator==(const CTxIndex& a, const CTxIndex& b)\n {\n return (a.pos == b.pos &&\n a.vSpent == b.vSpent);\n }\n\n friend bool operator!=(const CTxIndex& a, const CTxIndex& b)\n {\n return !(a == b);\n }\n int GetDepthInMainChain() const;\n\n}" (type_identifier) "class" (identifier) "CTxIndex" (compound_statement) "{\npublic:\n CDiskTxPos pos;\n std::vector<CDiskTxPos> vSpent;\n\n CTxIndex()\n {\n SetNull();\n }\n\n CTxIndex(const CDiskTxPos& posIn, unsigned int nOutputs)\n {\n pos = posIn;\n vSpent.resize(nOutputs);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);\n READWRITE(vSpent);\n )\n\n void SetNull()\n {\n pos.SetNull();\n vSpent.clear();\n }\n\n bool IsNull()\n {\n return pos.IsNull();\n }\n\n friend bool operator==(const CTxIndex& a, const CTxIndex& b)\n {\n return (a.pos == b.pos &&\n a.vSpent == b.vSpent);\n }\n\n friend bool operator!=(const CTxIndex& a, const CTxIndex& b)\n {\n return !(a == b);\n }\n int GetDepthInMainChain() const;\n\n}" ({) "{" (labeled_statement) "public:\n CDiskTxPos pos;" (statement_identifier) "public" (:) ":" (declaration) "CDiskTxPos pos;" (type_identifier) "CDiskTxPos" (identifier) "pos" (;) ";" (labeled_statement) "std::vector<CDiskTxPos> vSpent;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "vector<CDiskTxPos> vSpent;" (binary_expression) "vector<CDiskTxPos> vSpent" (binary_expression) "vector<CDiskTxPos" (identifier) "vector" (<) "<" (identifier) "CDiskTxPos" (>) ">" (identifier) "vSpent" (;) ";" (expression_statement) "CTxIndex()" (call_expression) "CTxIndex()" (identifier) "CTxIndex" (argument_list) "()" (() "(" ()) ")" (;) "" (compound_statement) "{\n SetNull();\n }" ({) "{" (expression_statement) "SetNull();" (call_expression) "SetNull()" (identifier) "SetNull" (argument_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (expression_statement) "CTxIndex(const CDiskTxPos& posIn, unsigned" (comma_expression) "CTxIndex(const CDiskTxPos& posIn, unsigned" (binary_expression) "CTxIndex(const CDiskTxPos& posIn" (identifier) "CTxIndex" (ERROR) "(const CDiskTxPos" (() "(" (type_descriptor) "const CDiskTxPos" (type_qualifier) "const" (const) "const" (type_identifier) "CDiskTxPos" (&) "&" (identifier) "posIn" (,) "," (identifier) "unsigned" (;) "" (function_definition) "int nOutputs)\n {\n pos = posIn;\n vSpent.resize(nOutputs);\n }" (primitive_type) "int" (identifier) "nOutputs" (ERROR) ")" ()) ")" (compound_statement) "{\n pos = posIn;\n vSpent.resize(nOutputs);\n }" ({) "{" (expression_statement) "pos = posIn;" (assignment_expression) "pos = posIn" (identifier) "pos" (=) "=" (identifier) "posIn" (;) ";" (expression_statement) "vSpent.resize(nOutputs);" (call_expression) "vSpent.resize(nOutputs)" (field_expression) "vSpent.resize" (identifier) "vSpent" (.) "." (field_identifier) "resize" (argument_list) "(nOutputs)" (() "(" (identifier) "nOutputs" ()) ")" (;) ";" (}) "}" (expression_statement) "IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);\n READWRITE(vSpent);\n )" (call_expression) "IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);\n READWRITE(vSpent);\n )" (identifier) "IMPLEMENT_SERIALIZE" (argument_list) "(\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);\n READWRITE(vSpent);\n )" (() "(" (ERROR) "if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);" (call_expression) "if (!(nType & SER_GETHASH))" (identifier) "if" (argument_list) "(!(nType & SER_GETHASH))" (() "(" (unary_expression) "!(nType & SER_GETHASH)" (!) "!" (parenthesized_expression) "(nType & SER_GETHASH)" (() "(" (binary_expression) "nType & SER_GETHASH" (identifier) "nType" (&) "&" (identifier) "SER_GETHASH" ()) ")" ()) ")" (call_expression) "READWRITE(nVersion)" (identifier) "READWRITE" (argument_list) "(nVersion)" (() "(" (identifier) "nVersion" ()) ")" (;) ";" (call_expression) "READWRITE(pos)" (identifier) "READWRITE" (argument_list) "(pos)" (() "(" (identifier) "pos" ()) ")" (;) ";" (call_expression) "READWRITE(vSpent)" (identifier) "READWRITE" (argument_list) "(vSpent)" (() "(" (identifier) "vSpent" ()) ")" (ERROR) ";" (;) ";" ()) ")" (;) "" (function_definition) "void SetNull()\n {\n pos.SetNull();\n vSpent.clear();\n }" (primitive_type) "void" (function_declarator) "SetNull()" (identifier) "SetNull" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n pos.SetNull();\n vSpent.clear();\n }" ({) "{" (expression_statement) "pos.SetNull();" (call_expression) "pos.SetNull()" (field_expression) "pos.SetNull" (identifier) "pos" (.) "." (field_identifier) "SetNull" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "vSpent.clear();" (call_expression) "vSpent.clear()" (field_expression) "vSpent.clear" (identifier) "vSpent" (.) "." (field_identifier) "clear" (argument_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (function_definition) "bool IsNull()\n {\n return pos.IsNull();\n }" (primitive_type) "bool" (function_declarator) "IsNull()" (identifier) "IsNull" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n return pos.IsNull();\n }" ({) "{" (return_statement) "return pos.IsNull();" (return) "return" (call_expression) "pos.IsNull()" (field_expression) "pos.IsNull" (identifier) "pos" (.) "." (field_identifier) "IsNull" (argument_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (declaration) "friend bool" (type_identifier) "friend" (identifier) "bool" (;) "" (expression_statement) "operator==(const CTxIndex& a, const CTxIndex& b)" (binary_expression) "operator==(const CTxIndex& a, const CTxIndex& b)" (identifier) "operator" (==) "==" (parenthesized_expression) "(const CTxIndex& a, const CTxIndex& b)" (() "(" (ERROR) "const CTxIndex" (type_descriptor) "const CTxIndex" (type_qualifier) "const" (const) "const" (type_identifier) "CTxIndex" (comma_expression) "& a, const CTxIndex& b" (pointer_expression) "& a" (&) "&" (identifier) "a" (,) "," (ERROR) "const" (identifier) "const" (binary_expression) "CTxIndex& b" (identifier) "CTxIndex" (&) "&" (identifier) "b" ()) ")" (;) "" (compound_statement) "{\n return (a.pos == b.pos &&\n a.vSpent == b.vSpent);\n }" ({) "{" (return_statement) "return (a.pos == b.pos &&\n a.vSpent == b.vSpent);" (return) "return" (parenthesized_expression) "(a.pos == b.pos &&\n a.vSpent == b.vSpent)" (() "(" (binary_expression) "a.pos == b.pos &&\n a.vSpent == b.vSpent" (binary_expression) "a.pos == b.pos" (field_expression) "a.pos" (identifier) "a" (.) "." (field_identifier) "pos" (==) "==" (field_expression) "b.pos" (identifier) "b" (.) "." (field_identifier) "pos" (&&) "&&" (binary_expression) "a.vSpent == b.vSpent" (field_expression) "a.vSpent" (identifier) "a" (.) "." (field_identifier) "vSpent" (==) "==" (field_expression) "b.vSpent" (identifier) "b" (.) "." (field_identifier) "vSpent" ()) ")" (;) ";" (}) "}" (declaration) "friend bool" (type_identifier) "friend" (identifier) "bool" (;) "" (expression_statement) "operator!=(const CTxIndex& a, const CTxIndex& b)" (binary_expression) "operator!=(const CTxIndex& a, const CTxIndex& b)" (identifier) "operator" (!=) "!=" (parenthesized_expression) "(const CTxIndex& a, const CTxIndex& b)" (() "(" (ERROR) "const CTxIndex" (type_descriptor) "const CTxIndex" (type_qualifier) "const" (const) "const" (type_identifier) "CTxIndex" (comma_expression) "& a, const CTxIndex& b" (pointer_expression) "& a" (&) "&" (identifier) "a" (,) "," (ERROR) "const" (identifier) "const" (binary_expression) "CTxIndex& b" (identifier) "CTxIndex" (&) "&" (identifier) "b" ()) ")" (;) "" (compound_statement) "{\n return !(a == b);\n }" ({) "{" (return_statement) "return !(a == b);" (return) "return" (unary_expression) "!(a == b)" (!) "!" (parenthesized_expression) "(a == b)" (() "(" (binary_expression) "a == b" (identifier) "a" (==) "==" (identifier) "b" ()) ")" (;) ";" (}) "}" (ERROR) "int GetDepthInMainChain() const" (primitive_type) "int" (function_declarator) "GetDepthInMainChain()" (identifier) "GetDepthInMainChain" (parameter_list) "()" (() "(" ()) ")" (type_qualifier) "const" (const) "const" (expression_statement) ";" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (comment) "/** The block chain is a tree shaped structure starting with the\n * genesis block at the root, with each block potentially having multiple\n * candidates to be the next block. pprev and pnext link a path through the\n * main/longest chain. A blockindex may have multiple pprev pointing back\n * to it, but pnext will only point forward to the longest branch, or will\n * be null if the block is not part of the longest chain.\n */" (function_definition) "class CBlockIndex\n{\npublic:\n const uint256* phashBlock;\n CBlockIndex* pprev;\n CBlockIndex* pnext;\n unsigned int nFile;\n unsigned int nBlockPos;\n uint256 nChainTrust; // ppcoin: trust score of block chain\n int nHeight;\n\n int64 nMint;\n int64 nMoneySupply;\n\n unsigned int nFlags; // ppcoin: block index flags\n enum\n {\n BLOCK_PROOF_OF_STAKE = (1 << 0), // is proof-of-stake block\n BLOCK_STAKE_ENTROPY = (1 << 1), // entropy bit for stake modifier\n BLOCK_STAKE_MODIFIER = (1 << 2), // regenerated stake modifier\n };\n\n uint64 nStakeModifier; // hash modifier for proof-of-stake\n unsigned int nStakeModifierChecksum; // checksum of index; in-memeory only\n\n // proof-of-stake specific fields\n COutPoint prevoutStake;\n unsigned int nStakeTime;\n uint256 hashProofOfStake;\n\n // block header\n int nVersion;\n uint256 hashMerkleRoot;\n unsigned int nTime;\n unsigned int nBits;\n unsigned int nNonce;\n\n CBlockIndex()\n {\n phashBlock = NULL;\n pprev = NULL;\n pnext = NULL;\n nFile = 0;\n nBlockPos = 0;\n nHeight = 0;\n nChainTrust = 0;\n nMint = 0;\n nMoneySupply = 0;\n nFlags = 0;\n nStakeModifier = 0;\n nStakeModifierChecksum = 0;\n hashProofOfStake = 0;\n prevoutStake.SetNull();\n nStakeTime = 0;\n\n nVersion = 0;\n hashMerkleRoot = 0;\n nTime = 0;\n nBits = 0;\n nNonce = 0;\n }\n\n CBlockIndex(unsigned int nFileIn, unsigned int nBlockPosIn, CBlock& block);\n\n CBlock GetBlockHeader() const;\n uint256 GetBlockHash() const;\n int64 GetBlockTime() const;\n uint256 GetBlockTrust() const;\n bool IsInMainChain() const;\n bool CheckIndex() const;\n\n enum { nMedianTimeSpan=11 };\n\n int64 GetMedianTimePast() const;\n\n int64 GetMedianTime() const;\n /**\n * Returns true if there are nRequired or more blocks of minVersion or above\n * in the last nToCheck blocks, starting at pstart and going backwards.\n */\n bool IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck);\n\n\n bool IsProofOfWork() const;\n bool IsProofOfStake() const;\n void SetProofOfStake();\n unsigned int GetStakeEntropyBit() const;\n bool SetStakeEntropyBit(unsigned int nEntropyBit);\n bool GeneratedStakeModifier() const;\n void SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier);\n std::string ToString() const;\n void print() const;\n};\n\n\n\n/** Used to marshal pointers into hashes for db storage. */\nclass CDiskBlockIndex : public CBlockIndex\n{\npublic:\n uint256 hashPrev;\n uint256 hashNext;\n\n CDiskBlockIndex()\n {\n hashPrev = 0;\n hashNext = 0;\n }\n\n explicit CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex)\n {\n hashPrev = (pprev ? pprev->GetBlockHash() : 0);\n hashNext = (pnext ? pnext->GetBlockHash() : 0);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);\n READWRITE(nStakeModifier);\n if (IsProofOfStake())\n {\n READWRITE(prevoutStake);\n READWRITE(nStakeTime);\n READWRITE(hashProofOfStake);\n }\n else if (fRead)\n {\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }\n\n // block header\n READWRITE(this->nVersion);\n READWRITE(hashPrev);\n READWRITE(hashMerkleRoot);\n READWRITE(nTime);\n READWRITE(nBits);\n READWRITE(nNonce);\n )\n\n uint256 GetBlockHash() const\n {\n CBlock block;\n block.nVersion = nVersion;\n block.hashPrevBlock = hashPrev;\n block.hashMerkleRoot = hashMerkleRoot;\n block.nTime = nTime;\n block.nBits = nBits;\n block.nNonce = nNonce;\n return block.GetHash();\n }\n\n\n std::string ToString() const\n {\n std::string str = "CDiskBlockIndex(";\n str += CBlockIndex::ToString();\n str += strprintf("\n hashBlock=%s, hashPrev=%s, hashNext=%s)",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str());\n return str;\n }\n\n void print() const\n {\n printf("%s\n", ToString().c_str());\n }\n}" (type_identifier) "class" (identifier) "CBlockIndex" (compound_statement) "{\npublic:\n const uint256* phashBlock;\n CBlockIndex* pprev;\n CBlockIndex* pnext;\n unsigned int nFile;\n unsigned int nBlockPos;\n uint256 nChainTrust; // ppcoin: trust score of block chain\n int nHeight;\n\n int64 nMint;\n int64 nMoneySupply;\n\n unsigned int nFlags; // ppcoin: block index flags\n enum\n {\n BLOCK_PROOF_OF_STAKE = (1 << 0), // is proof-of-stake block\n BLOCK_STAKE_ENTROPY = (1 << 1), // entropy bit for stake modifier\n BLOCK_STAKE_MODIFIER = (1 << 2), // regenerated stake modifier\n };\n\n uint64 nStakeModifier; // hash modifier for proof-of-stake\n unsigned int nStakeModifierChecksum; // checksum of index; in-memeory only\n\n // proof-of-stake specific fields\n COutPoint prevoutStake;\n unsigned int nStakeTime;\n uint256 hashProofOfStake;\n\n // block header\n int nVersion;\n uint256 hashMerkleRoot;\n unsigned int nTime;\n unsigned int nBits;\n unsigned int nNonce;\n\n CBlockIndex()\n {\n phashBlock = NULL;\n pprev = NULL;\n pnext = NULL;\n nFile = 0;\n nBlockPos = 0;\n nHeight = 0;\n nChainTrust = 0;\n nMint = 0;\n nMoneySupply = 0;\n nFlags = 0;\n nStakeModifier = 0;\n nStakeModifierChecksum = 0;\n hashProofOfStake = 0;\n prevoutStake.SetNull();\n nStakeTime = 0;\n\n nVersion = 0;\n hashMerkleRoot = 0;\n nTime = 0;\n nBits = 0;\n nNonce = 0;\n }\n\n CBlockIndex(unsigned int nFileIn, unsigned int nBlockPosIn, CBlock& block);\n\n CBlock GetBlockHeader() const;\n uint256 GetBlockHash() const;\n int64 GetBlockTime() const;\n uint256 GetBlockTrust() const;\n bool IsInMainChain() const;\n bool CheckIndex() const;\n\n enum { nMedianTimeSpan=11 };\n\n int64 GetMedianTimePast() const;\n\n int64 GetMedianTime() const;\n /**\n * Returns true if there are nRequired or more blocks of minVersion or above\n * in the last nToCheck blocks, starting at pstart and going backwards.\n */\n bool IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck);\n\n\n bool IsProofOfWork() const;\n bool IsProofOfStake() const;\n void SetProofOfStake();\n unsigned int GetStakeEntropyBit() const;\n bool SetStakeEntropyBit(unsigned int nEntropyBit);\n bool GeneratedStakeModifier() const;\n void SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier);\n std::string ToString() const;\n void print() const;\n};\n\n\n\n/** Used to marshal pointers into hashes for db storage. */\nclass CDiskBlockIndex : public CBlockIndex\n{\npublic:\n uint256 hashPrev;\n uint256 hashNext;\n\n CDiskBlockIndex()\n {\n hashPrev = 0;\n hashNext = 0;\n }\n\n explicit CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex)\n {\n hashPrev = (pprev ? pprev->GetBlockHash() : 0);\n hashNext = (pnext ? pnext->GetBlockHash() : 0);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);\n READWRITE(nStakeModifier);\n if (IsProofOfStake())\n {\n READWRITE(prevoutStake);\n READWRITE(nStakeTime);\n READWRITE(hashProofOfStake);\n }\n else if (fRead)\n {\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }\n\n // block header\n READWRITE(this->nVersion);\n READWRITE(hashPrev);\n READWRITE(hashMerkleRoot);\n READWRITE(nTime);\n READWRITE(nBits);\n READWRITE(nNonce);\n )\n\n uint256 GetBlockHash() const\n {\n CBlock block;\n block.nVersion = nVersion;\n block.hashPrevBlock = hashPrev;\n block.hashMerkleRoot = hashMerkleRoot;\n block.nTime = nTime;\n block.nBits = nBits;\n block.nNonce = nNonce;\n return block.GetHash();\n }\n\n\n std::string ToString() const\n {\n std::string str = "CDiskBlockIndex(";\n str += CBlockIndex::ToString();\n str += strprintf("\n hashBlock=%s, hashPrev=%s, hashNext=%s)",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str());\n return str;\n }\n\n void print() const\n {\n printf("%s\n", ToString().c_str());\n }\n}" ({) "{" (labeled_statement) "public:\n const uint256* phashBlock;" (statement_identifier) "public" (:) ":" (declaration) "const uint256* phashBlock;" (type_qualifier) "const" (const) "const" (type_identifier) "uint256" (pointer_declarator) "* phashBlock" (*) "*" (identifier) "phashBlock" (;) ";" (declaration) "CBlockIndex* pprev;" (type_identifier) "CBlockIndex" (pointer_declarator) "* pprev" (*) "*" (identifier) "pprev" (;) ";" (declaration) "CBlockIndex* pnext;" (type_identifier) "CBlockIndex" (pointer_declarator) "* pnext" (*) "*" (identifier) "pnext" (;) ";" (declaration) "unsigned int nFile;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nFile" (;) ";" (declaration) "unsigned int nBlockPos;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nBlockPos" (;) ";" (declaration) "uint256 nChainTrust;" (type_identifier) "uint256" (identifier) "nChainTrust" (;) ";" (comment) "// ppcoin: trust score of block chain" (declaration) "int nHeight;" (primitive_type) "int" (identifier) "nHeight" (;) ";" (declaration) "int64 nMint;" (type_identifier) "int64" (identifier) "nMint" (;) ";" (declaration) "int64 nMoneySupply;" (type_identifier) "int64" (identifier) "nMoneySupply" (;) ";" (declaration) "unsigned int nFlags;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nFlags" (;) ";" (comment) "// ppcoin: block index flags" (enum_specifier) "enum\n {\n BLOCK_PROOF_OF_STAKE = (1 << 0), // is proof-of-stake block\n BLOCK_STAKE_ENTROPY = (1 << 1), // entropy bit for stake modifier\n BLOCK_STAKE_MODIFIER = (1 << 2), // regenerated stake modifier\n }" (enum) "enum" (enumerator_list) "{\n BLOCK_PROOF_OF_STAKE = (1 << 0), // is proof-of-stake block\n BLOCK_STAKE_ENTROPY = (1 << 1), // entropy bit for stake modifier\n BLOCK_STAKE_MODIFIER = (1 << 2), // regenerated stake modifier\n }" ({) "{" (enumerator) "BLOCK_PROOF_OF_STAKE = (1 << 0)" (identifier) "BLOCK_PROOF_OF_STAKE" (=) "=" (parenthesized_expression) "(1 << 0)" (() "(" (binary_expression) "1 << 0" (number_literal) "1" (<<) "<<" (number_literal) "0" ()) ")" (,) "," (comment) "// is proof-of-stake block" (enumerator) "BLOCK_STAKE_ENTROPY = (1 << 1)" (identifier) "BLOCK_STAKE_ENTROPY" (=) "=" (parenthesized_expression) "(1 << 1)" (() "(" (binary_expression) "1 << 1" (number_literal) "1" (<<) "<<" (number_literal) "1" ()) ")" (,) "," (comment) "// entropy bit for stake modifier" (enumerator) "BLOCK_STAKE_MODIFIER = (1 << 2)" (identifier) "BLOCK_STAKE_MODIFIER" (=) "=" (parenthesized_expression) "(1 << 2)" (() "(" (binary_expression) "1 << 2" (number_literal) "1" (<<) "<<" (number_literal) "2" ()) ")" (,) "," (comment) "// regenerated stake modifier" (}) "}" (;) ";" (declaration) "uint64 nStakeModifier;" (type_identifier) "uint64" (identifier) "nStakeModifier" (;) ";" (comment) "// hash modifier for proof-of-stake" (declaration) "unsigned int nStakeModifierChecksum;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nStakeModifierChecksum" (;) ";" (comment) "// checksum of index; in-memeory only" (comment) "// proof-of-stake specific fields" (declaration) "COutPoint prevoutStake;" (type_identifier) "COutPoint" (identifier) "prevoutStake" (;) ";" (declaration) "unsigned int nStakeTime;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nStakeTime" (;) ";" (declaration) "uint256 hashProofOfStake;" (type_identifier) "uint256" (identifier) "hashProofOfStake" (;) ";" (comment) "// block header" (declaration) "int nVersion;" (primitive_type) "int" (identifier) "nVersion" (;) ";" (declaration) "uint256 hashMerkleRoot;" (type_identifier) "uint256" (identifier) "hashMerkleRoot" (;) ";" (declaration) "unsigned int nTime;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nTime" (;) ";" (declaration) "unsigned int nBits;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nBits" (;) ";" (declaration) "unsigned int nNonce;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nNonce" (;) ";" (expression_statement) "CBlockIndex()" (call_expression) "CBlockIndex()" (identifier) "CBlockIndex" (argument_list) "()" (() "(" ()) ")" (;) "" (compound_statement) "{\n phashBlock = NULL;\n pprev = NULL;\n pnext = NULL;\n nFile = 0;\n nBlockPos = 0;\n nHeight = 0;\n nChainTrust = 0;\n nMint = 0;\n nMoneySupply = 0;\n nFlags = 0;\n nStakeModifier = 0;\n nStakeModifierChecksum = 0;\n hashProofOfStake = 0;\n prevoutStake.SetNull();\n nStakeTime = 0;\n\n nVersion = 0;\n hashMerkleRoot = 0;\n nTime = 0;\n nBits = 0;\n nNonce = 0;\n }" ({) "{" (expression_statement) "phashBlock = NULL;" (assignment_expression) "phashBlock = NULL" (identifier) "phashBlock" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (expression_statement) "pprev = NULL;" (assignment_expression) "pprev = NULL" (identifier) "pprev" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (expression_statement) "pnext = NULL;" (assignment_expression) "pnext = NULL" (identifier) "pnext" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (expression_statement) "nFile = 0;" (assignment_expression) "nFile = 0" (identifier) "nFile" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "nBlockPos = 0;" (assignment_expression) "nBlockPos = 0" (identifier) "nBlockPos" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "nHeight = 0;" (assignment_expression) "nHeight = 0" (identifier) "nHeight" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "nChainTrust = 0;" (assignment_expression) "nChainTrust = 0" (identifier) "nChainTrust" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "nMint = 0;" (assignment_expression) "nMint = 0" (identifier) "nMint" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "nMoneySupply = 0;" (assignment_expression) "nMoneySupply = 0" (identifier) "nMoneySupply" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "nFlags = 0;" (assignment_expression) "nFlags = 0" (identifier) "nFlags" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "nStakeModifier = 0;" (assignment_expression) "nStakeModifier = 0" (identifier) "nStakeModifier" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "nStakeModifierChecksum = 0;" (assignment_expression) "nStakeModifierChecksum = 0" (identifier) "nStakeModifierChecksum" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "hashProofOfStake = 0;" (assignment_expression) "hashProofOfStake = 0" (identifier) "hashProofOfStake" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "prevoutStake.SetNull();" (call_expression) "prevoutStake.SetNull()" (field_expression) "prevoutStake.SetNull" (identifier) "prevoutStake" (.) "." (field_identifier) "SetNull" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "nStakeTime = 0;" (assignment_expression) "nStakeTime = 0" (identifier) "nStakeTime" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "nVersion = 0;" (assignment_expression) "nVersion = 0" (identifier) "nVersion" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "hashMerkleRoot = 0;" (assignment_expression) "hashMerkleRoot = 0" (identifier) "hashMerkleRoot" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "nTime = 0;" (assignment_expression) "nTime = 0" (identifier) "nTime" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "nBits = 0;" (assignment_expression) "nBits = 0" (identifier) "nBits" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "nNonce = 0;" (assignment_expression) "nNonce = 0" (identifier) "nNonce" (=) "=" (number_literal) "0" (;) ";" (}) "}" (declaration) "CBlockIndex(unsigned int nFileIn, unsigned int nBlockPosIn, CBlock& block);" (macro_type_specifier) "CBlockIndex(unsigned int" (identifier) "CBlockIndex" (() "(" (type_descriptor) "unsigned int" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" ()) "" (identifier) "nFileIn" (,) "," (ERROR) "unsigned int" (identifier) "unsigned" (identifier) "int" (identifier) "nBlockPosIn" (,) "," (identifier) "CBlock" (ERROR) "& block)" (&) "&" (identifier) "block" ()) ")" (;) ";" (function_definition) "CBlock GetBlockHeader() const;\n uint256 GetBlockHash() const;\n int64 GetBlockTime() const;\n uint256 GetBlockTrust() const;\n bool IsInMainChain() const;\n bool CheckIndex() const;\n\n enum { nMedianTimeSpan=11 };\n\n int64 GetMedianTimePast() const;\n\n int64 GetMedianTime() const;\n /**\n * Returns true if there are nRequired or more blocks of minVersion or above\n * in the last nToCheck blocks, starting at pstart and going backwards.\n */\n bool IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck);\n\n\n bool IsProofOfWork() const;\n bool IsProofOfStake() const;\n void SetProofOfStake();\n unsigned int GetStakeEntropyBit() const;\n bool SetStakeEntropyBit(unsigned int nEntropyBit);\n bool GeneratedStakeModifier() const;\n void SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier);\n std::string ToString() const;\n void print() const;\n};\n\n\n\n/** Used to marshal pointers into hashes for db storage. */\nclass CDiskBlockIndex : public CBlockIndex\n{\npublic:\n uint256 hashPrev;\n uint256 hashNext;\n\n CDiskBlockIndex()\n {\n hashPrev = 0;\n hashNext = 0;\n }" (type_identifier) "CBlock" (function_declarator) "GetBlockHeader()" (identifier) "GetBlockHeader" (parameter_list) "()" (() "(" ()) ")" (declaration) "const;\n uint256 GetBlockHash() const;\n int64 GetBlockTime() const;\n uint256 GetBlockTrust() const;\n bool IsInMainChain() const;\n bool CheckIndex() const;\n\n enum { nMedianTimeSpan=11 };" (type_qualifier) "const" (const) "const" (ERROR) ";" (;) ";" (type_identifier) "uint256" (ERROR) "GetBlockHash() const;\n int64 GetBlockTime() const;\n uint256 GetBlockTrust() const;\n bool IsInMainChain() const;\n bool CheckIndex() const;\n\n enum {" (function_declarator) "GetBlockHash() const" (identifier) "GetBlockHash" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (identifier) "int64" (function_declarator) "GetBlockTime() const" (identifier) "GetBlockTime" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (identifier) "uint256" (function_declarator) "GetBlockTrust() const" (identifier) "GetBlockTrust" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (primitive_type) "bool" (function_declarator) "IsInMainChain() const" (identifier) "IsInMainChain" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (primitive_type) "bool" (function_declarator) "CheckIndex() const" (identifier) "CheckIndex" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (enum) "enum" ({) "{" (init_declarator) "nMedianTimeSpan=11" (identifier) "nMedianTimeSpan" (=) "=" (number_literal) "11" (ERROR) "}" (}) "}" (;) ";" (ERROR) "int64 GetMedianTimePast() const;\n\n int64 GetMedianTime() const;" (type_identifier) "int64" (ERROR) "GetMedianTimePast() const;\n\n int64" (function_declarator) "GetMedianTimePast() const" (identifier) "GetMedianTimePast" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (identifier) "int64" (function_declarator) "GetMedianTime() const" (identifier) "GetMedianTime" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (comment) "/**\n * Returns true if there are nRequired or more blocks of minVersion or above\n * in the last nToCheck blocks, starting at pstart and going backwards.\n */" (declaration) "bool IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck);" (primitive_type) "bool" (function_declarator) "IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck)" (identifier) "IsSuperMajority" (parameter_list) "(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck)" (() "(" (parameter_declaration) "int minVersion" (primitive_type) "int" (identifier) "minVersion" (,) "," (parameter_declaration) "const CBlockIndex* pstart" (type_qualifier) "const" (const) "const" (type_identifier) "CBlockIndex" (pointer_declarator) "* pstart" (*) "*" (identifier) "pstart" (,) "," (parameter_declaration) "unsigned int nRequired" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nRequired" (,) "," (parameter_declaration) "unsigned int nToCheck" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nToCheck" ()) ")" (;) ";" (ERROR) "bool IsProofOfWork() const;\n bool IsProofOfStake() const;" (primitive_type) "bool" (function_declarator) "IsProofOfWork() const" (identifier) "IsProofOfWork" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (primitive_type) "bool" (function_declarator) "IsProofOfStake() const" (identifier) "IsProofOfStake" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (declaration) "void SetProofOfStake();" (primitive_type) "void" (function_declarator) "SetProofOfStake()" (identifier) "SetProofOfStake" (parameter_list) "()" (() "(" ()) ")" (;) ";" (ERROR) "unsigned int GetStakeEntropyBit() const;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (function_declarator) "GetStakeEntropyBit() const" (identifier) "GetStakeEntropyBit" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (declaration) "bool SetStakeEntropyBit(unsigned int nEntropyBit);" (primitive_type) "bool" (function_declarator) "SetStakeEntropyBit(unsigned int nEntropyBit)" (identifier) "SetStakeEntropyBit" (parameter_list) "(unsigned int nEntropyBit)" (() "(" (parameter_declaration) "unsigned int nEntropyBit" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "nEntropyBit" ()) ")" (;) ";" (ERROR) "bool GeneratedStakeModifier() const;" (primitive_type) "bool" (function_declarator) "GeneratedStakeModifier() const" (identifier) "GeneratedStakeModifier" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (declaration) "void SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier);" (primitive_type) "void" (function_declarator) "SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier)" (identifier) "SetStakeModifier" (parameter_list) "(uint64 nModifier, bool fGeneratedStakeModifier)" (() "(" (parameter_declaration) "uint64 nModifier" (type_identifier) "uint64" (identifier) "nModifier" (,) "," (parameter_declaration) "bool fGeneratedStakeModifier" (primitive_type) "bool" (identifier) "fGeneratedStakeModifier" ()) ")" (;) ";" (declaration) "std::string ToString() const;\n void print() const;\n};\n\n\n\n/** Used to marshal pointers into hashes for db storage. */\nclass CDiskBlockIndex : public CBlockIndex\n{\npublic:\n uint256 hashPrev;" (type_identifier) "std" (ERROR) "::string ToString() const;\n void print() const;\n};" (:) ":" (:) ":" (identifier) "string" (function_declarator) "ToString() const" (identifier) "ToString" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (primitive_type) "void" (function_declarator) "print() const" (identifier) "print" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (}) "}" (;) ";" (comment) "/** Used to marshal pointers into hashes for db storage. */" (ERROR) "class CDiskBlockIndex : public CBlockIndex\n{\npublic:\n uint256" (identifier) "class" (identifier) "CDiskBlockIndex" (:) ":" (identifier) "public" (identifier) "CBlockIndex" ({) "{" (identifier) "public" (:) ":" (identifier) "uint256" (identifier) "hashPrev" (;) ";" (declaration) "uint256 hashNext;" (type_identifier) "uint256" (identifier) "hashNext" (;) ";" (ERROR) "CDiskBlockIndex()" (identifier) "CDiskBlockIndex" (() "(" ()) ")" (compound_statement) "{\n hashPrev = 0;\n hashNext = 0;\n }" ({) "{" (expression_statement) "hashPrev = 0;" (assignment_expression) "hashPrev = 0" (identifier) "hashPrev" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "hashNext = 0;" (assignment_expression) "hashNext = 0" (identifier) "hashNext" (=) "=" (number_literal) "0" (;) ";" (}) "}" (function_definition) "explicit CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex)\n {\n hashPrev = (pprev ? pprev->GetBlockHash() : 0);\n hashNext = (pnext ? pnext->GetBlockHash() : 0);\n }" (type_identifier) "explicit" (function_declarator) "CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex)" (identifier) "CDiskBlockIndex" (parameter_list) "(CBlockIndex* pindex)" (() "(" (parameter_declaration) "CBlockIndex* pindex" (type_identifier) "CBlockIndex" (pointer_declarator) "* pindex" (*) "*" (identifier) "pindex" ()) ")" (ERROR) ":" (:) ":" (call_expression) "CBlockIndex(*pindex)" (identifier) "CBlockIndex" (argument_list) "(*pindex)" (() "(" (ERROR) "*" (*) "*" (identifier) "pindex" ()) ")" (compound_statement) "{\n hashPrev = (pprev ? pprev->GetBlockHash() : 0);\n hashNext = (pnext ? pnext->GetBlockHash() : 0);\n }" ({) "{" (expression_statement) "hashPrev = (pprev ? pprev->GetBlockHash() : 0);" (assignment_expression) "hashPrev = (pprev ? pprev->GetBlockHash() : 0)" (identifier) "hashPrev" (=) "=" (parenthesized_expression) "(pprev ? pprev->GetBlockHash() : 0)" (() "(" (conditional_expression) "pprev ? pprev->GetBlockHash() : 0" (identifier) "pprev" (?) "?" (call_expression) "pprev->GetBlockHash()" (field_expression) "pprev->GetBlockHash" (identifier) "pprev" (->) "->" (field_identifier) "GetBlockHash" (argument_list) "()" (() "(" ()) ")" (:) ":" (number_literal) "0" ()) ")" (;) ";" (expression_statement) "hashNext = (pnext ? pnext->GetBlockHash() : 0);" (assignment_expression) "hashNext = (pnext ? pnext->GetBlockHash() : 0)" (identifier) "hashNext" (=) "=" (parenthesized_expression) "(pnext ? pnext->GetBlockHash() : 0)" (() "(" (conditional_expression) "pnext ? pnext->GetBlockHash() : 0" (identifier) "pnext" (?) "?" (call_expression) "pnext->GetBlockHash()" (field_expression) "pnext->GetBlockHash" (identifier) "pnext" (->) "->" (field_identifier) "GetBlockHash" (argument_list) "()" (() "(" ()) ")" (:) ":" (number_literal) "0" ()) ")" (;) ";" (}) "}" (expression_statement) "IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);\n READWRITE(nStakeModifier);" (call_expression) "IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);\n READWRITE(nStakeModifier)" (identifier) "IMPLEMENT_SERIALIZE" (argument_list) "(\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);\n READWRITE(nStakeModifier)" (() "(" (ERROR) "if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);" (call_expression) "if (!(nType & SER_GETHASH))" (identifier) "if" (argument_list) "(!(nType & SER_GETHASH))" (() "(" (unary_expression) "!(nType & SER_GETHASH)" (!) "!" (parenthesized_expression) "(nType & SER_GETHASH)" (() "(" (binary_expression) "nType & SER_GETHASH" (identifier) "nType" (&) "&" (identifier) "SER_GETHASH" ()) ")" ()) ")" (call_expression) "READWRITE(nVersion)" (identifier) "READWRITE" (argument_list) "(nVersion)" (() "(" (identifier) "nVersion" ()) ")" (;) ";" (call_expression) "READWRITE(hashNext)" (identifier) "READWRITE" (argument_list) "(hashNext)" (() "(" (identifier) "hashNext" ()) ")" (;) ";" (call_expression) "READWRITE(nFile)" (identifier) "READWRITE" (argument_list) "(nFile)" (() "(" (identifier) "nFile" ()) ")" (;) ";" (call_expression) "READWRITE(nBlockPos)" (identifier) "READWRITE" (argument_list) "(nBlockPos)" (() "(" (identifier) "nBlockPos" ()) ")" (;) ";" (call_expression) "READWRITE(nHeight)" (identifier) "READWRITE" (argument_list) "(nHeight)" (() "(" (identifier) "nHeight" ()) ")" (;) ";" (call_expression) "READWRITE(nMint)" (identifier) "READWRITE" (argument_list) "(nMint)" (() "(" (identifier) "nMint" ()) ")" (;) ";" (call_expression) "READWRITE(nMoneySupply)" (identifier) "READWRITE" (argument_list) "(nMoneySupply)" (() "(" (identifier) "nMoneySupply" ()) ")" (;) ";" (call_expression) "READWRITE(nFlags)" (identifier) "READWRITE" (argument_list) "(nFlags)" (() "(" (identifier) "nFlags" ()) ")" (;) ";" (call_expression) "READWRITE(nStakeModifier)" (identifier) "READWRITE" (argument_list) "(nStakeModifier)" (() "(" (identifier) "nStakeModifier" ()) ")" ()) "" (;) ";" (if_statement) "if (IsProofOfStake())\n {\n READWRITE(prevoutStake);\n READWRITE(nStakeTime);\n READWRITE(hashProofOfStake);\n }\n else if (fRead)\n {\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }" (if) "if" (parenthesized_expression) "(IsProofOfStake())" (() "(" (call_expression) "IsProofOfStake()" (identifier) "IsProofOfStake" (argument_list) "()" (() "(" ()) ")" ()) ")" (compound_statement) "{\n READWRITE(prevoutStake);\n READWRITE(nStakeTime);\n READWRITE(hashProofOfStake);\n }" ({) "{" (expression_statement) "READWRITE(prevoutStake);" (call_expression) "READWRITE(prevoutStake)" (identifier) "READWRITE" (argument_list) "(prevoutStake)" (() "(" (identifier) "prevoutStake" ()) ")" (;) ";" (expression_statement) "READWRITE(nStakeTime);" (call_expression) "READWRITE(nStakeTime)" (identifier) "READWRITE" (argument_list) "(nStakeTime)" (() "(" (identifier) "nStakeTime" ()) ")" (;) ";" (expression_statement) "READWRITE(hashProofOfStake);" (call_expression) "READWRITE(hashProofOfStake)" (identifier) "READWRITE" (argument_list) "(hashProofOfStake)" (() "(" (identifier) "hashProofOfStake" ()) ")" (;) ";" (}) "}" (else_clause) "else if (fRead)\n {\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }" (else) "else" (if_statement) "if (fRead)\n {\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }" (if) "if" (parenthesized_expression) "(fRead)" (() "(" (identifier) "fRead" ()) ")" (compound_statement) "{\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }" ({) "{" (expression_statement) "const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();" (binary_expression) "const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull()" (binary_expression) "const_cast<CDiskBlockIndex" (identifier) "const_cast" (<) "<" (identifier) "CDiskBlockIndex" (ERROR) "*" (*) "*" (>) ">" (call_expression) "(this)->prevoutStake.SetNull()" (field_expression) "(this)->prevoutStake.SetNull" (field_expression) "(this)->prevoutStake" (parenthesized_expression) "(this)" (() "(" (identifier) "this" ()) ")" (->) "->" (field_identifier) "prevoutStake" (.) "." (field_identifier) "SetNull" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;" (binary_expression) "const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0" (binary_expression) "const_cast<CDiskBlockIndex" (identifier) "const_cast" (<) "<" (identifier) "CDiskBlockIndex" (ERROR) "*" (*) "*" (>) ">" (assignment_expression) "(this)->nStakeTime = 0" (field_expression) "(this)->nStakeTime" (parenthesized_expression) "(this)" (() "(" (identifier) "this" ()) ")" (->) "->" (field_identifier) "nStakeTime" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;" (binary_expression) "const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0" (binary_expression) "const_cast<CDiskBlockIndex" (identifier) "const_cast" (<) "<" (identifier) "CDiskBlockIndex" (ERROR) "*" (*) "*" (>) ">" (assignment_expression) "(this)->hashProofOfStake = 0" (field_expression) "(this)->hashProofOfStake" (parenthesized_expression) "(this)" (() "(" (identifier) "this" ()) ")" (->) "->" (field_identifier) "hashProofOfStake" (=) "=" (number_literal) "0" (;) ";" (}) "}" (comment) "// block header" (expression_statement) "READWRITE(this->nVersion);" (call_expression) "READWRITE(this->nVersion)" (identifier) "READWRITE" (argument_list) "(this->nVersion)" (() "(" (field_expression) "this->nVersion" (identifier) "this" (->) "->" (field_identifier) "nVersion" ()) ")" (;) ";" (expression_statement) "READWRITE(hashPrev);" (call_expression) "READWRITE(hashPrev)" (identifier) "READWRITE" (argument_list) "(hashPrev)" (() "(" (identifier) "hashPrev" ()) ")" (;) ";" (expression_statement) "READWRITE(hashMerkleRoot);" (call_expression) "READWRITE(hashMerkleRoot)" (identifier) "READWRITE" (argument_list) "(hashMerkleRoot)" (() "(" (identifier) "hashMerkleRoot" ()) ")" (;) ";" (expression_statement) "READWRITE(nTime);" (call_expression) "READWRITE(nTime)" (identifier) "READWRITE" (argument_list) "(nTime)" (() "(" (identifier) "nTime" ()) ")" (;) ";" (expression_statement) "READWRITE(nBits);" (call_expression) "READWRITE(nBits)" (identifier) "READWRITE" (argument_list) "(nBits)" (() "(" (identifier) "nBits" ()) ")" (;) ";" (expression_statement) "READWRITE(nNonce);" (call_expression) "READWRITE(nNonce)" (identifier) "READWRITE" (argument_list) "(nNonce)" (() "(" (identifier) "nNonce" ()) ")" (;) ";" (ERROR) ")\n\n uint256 GetBlockHash() const" ()) ")" (type_identifier) "uint256" (function_declarator) "GetBlockHash()" (identifier) "GetBlockHash" (parameter_list) "()" (() "(" ()) ")" (type_qualifier) "const" (const) "const" (compound_statement) "{\n CBlock block;\n block.nVersion = nVersion;\n block.hashPrevBlock = hashPrev;\n block.hashMerkleRoot = hashMerkleRoot;\n block.nTime = nTime;\n block.nBits = nBits;\n block.nNonce = nNonce;\n return block.GetHash();\n }" ({) "{" (declaration) "CBlock block;" (type_identifier) "CBlock" (identifier) "block" (;) ";" (expression_statement) "block.nVersion = nVersion;" (assignment_expression) "block.nVersion = nVersion" (field_expression) "block.nVersion" (identifier) "block" (.) "." (field_identifier) "nVersion" (=) "=" (identifier) "nVersion" (;) ";" (expression_statement) "block.hashPrevBlock = hashPrev;" (assignment_expression) "block.hashPrevBlock = hashPrev" (field_expression) "block.hashPrevBlock" (identifier) "block" (.) "." (field_identifier) "hashPrevBlock" (=) "=" (identifier) "hashPrev" (;) ";" (expression_statement) "block.hashMerkleRoot = hashMerkleRoot;" (assignment_expression) "block.hashMerkleRoot = hashMerkleRoot" (field_expression) "block.hashMerkleRoot" (identifier) "block" (.) "." (field_identifier) "hashMerkleRoot" (=) "=" (identifier) "hashMerkleRoot" (;) ";" (expression_statement) "block.nTime = nTime;" (assignment_expression) "block.nTime = nTime" (field_expression) "block.nTime" (identifier) "block" (.) "." (field_identifier) "nTime" (=) "=" (identifier) "nTime" (;) ";" (expression_statement) "block.nBits = nBits;" (assignment_expression) "block.nBits = nBits" (field_expression) "block.nBits" (identifier) "block" (.) "." (field_identifier) "nBits" (=) "=" (identifier) "nBits" (;) ";" (expression_statement) "block.nNonce = nNonce;" (assignment_expression) "block.nNonce = nNonce" (field_expression) "block.nNonce" (identifier) "block" (.) "." (field_identifier) "nNonce" (=) "=" (identifier) "nNonce" (;) ";" (return_statement) "return block.GetHash();" (return) "return" (call_expression) "block.GetHash()" (field_expression) "block.GetHash" (identifier) "block" (.) "." (field_identifier) "GetHash" (argument_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (labeled_statement) "std::string ToString() const\n {\n std::string str = "CDiskBlockIndex(";\n str += CBlockIndex::ToString();\n str += strprintf("\n hashBlock=%s, hashPrev=%s, hashNext=%s)",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str());\n return str;\n }" (statement_identifier) "std" (:) ":" (ERROR) ":string ToString() const" (:) ":" (type_identifier) "string" (function_declarator) "ToString() const" (identifier) "ToString" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (compound_statement) "{\n std::string str = "CDiskBlockIndex(";\n str += CBlockIndex::ToString();\n str += strprintf("\n hashBlock=%s, hashPrev=%s, hashNext=%s)",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str());\n return str;\n }" ({) "{" (labeled_statement) "std::string str = "CDiskBlockIndex(";" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (declaration) "string str = "CDiskBlockIndex(";" (type_identifier) "string" (init_declarator) "str = "CDiskBlockIndex("" (identifier) "str" (=) "=" (string_literal) ""CDiskBlockIndex("" (") """ (string_content) "CDiskBlockIndex(" (") """ (;) ";" (ERROR) "str += CBlockIndex::" (assignment_expression) "str += CBlockIndex" (identifier) "str" (+=) "+=" (identifier) "CBlockIndex" (:) ":" (:) ":" (expression_statement) "ToString();" (call_expression) "ToString()" (identifier) "ToString" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "str += strprintf("\n hashBlock=%s, hashPrev=%s, hashNext=%s)",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str());" (assignment_expression) "str += strprintf("\n hashBlock=%s, hashPrev=%s, hashNext=%s)",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str())" (identifier) "str" (+=) "+=" (call_expression) "strprintf("\n hashBlock=%s, hashPrev=%s, hashNext=%s)",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str())" (identifier) "strprintf" (argument_list) "("\n hashBlock=%s, hashPrev=%s, hashNext=%s)",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str())" (() "(" (string_literal) ""\n hashBlock=%s, hashPrev=%s, hashNext=%s)"" (") """ (escape_sequence) "\n" (string_content) " hashBlock=%s, hashPrev=%s, hashNext=%s)" (") """ (,) "," (call_expression) "GetBlockHash().ToString().c_str()" (field_expression) "GetBlockHash().ToString().c_str" (call_expression) "GetBlockHash().ToString()" (field_expression) "GetBlockHash().ToString" (call_expression) "GetBlockHash()" (identifier) "GetBlockHash" (argument_list) "()" (() "(" ()) ")" (.) "." (field_identifier) "ToString" (argument_list) "()" (() "(" ()) ")" (.) "." (field_identifier) "c_str" (argument_list) "()" (() "(" ()) ")" (,) "," (call_expression) "hashPrev.ToString().c_str()" (field_expression) "hashPrev.ToString().c_str" (call_expression) "hashPrev.ToString()" (field_expression) "hashPrev.ToString" (identifier) "hashPrev" (.) "." (field_identifier) "ToString" (argument_list) "()" (() "(" ()) ")" (.) "." (field_identifier) "c_str" (argument_list) "()" (() "(" ()) ")" (,) "," (call_expression) "hashNext.ToString().c_str()" (field_expression) "hashNext.ToString().c_str" (call_expression) "hashNext.ToString()" (field_expression) "hashNext.ToString" (identifier) "hashNext" (.) "." (field_identifier) "ToString" (argument_list) "()" (() "(" ()) ")" (.) "." (field_identifier) "c_str" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) ";" (return_statement) "return str;" (return) "return" (identifier) "str" (;) ";" (}) "}" (ERROR) "void print() const" (primitive_type) "void" (function_declarator) "print()" (identifier) "print" (parameter_list) "()" (() "(" ()) ")" (type_qualifier) "const" (const) "const" (compound_statement) "{\n printf("%s\n", ToString().c_str());\n }" ({) "{" (expression_statement) "printf("%s\n", ToString().c_str());" (call_expression) "printf("%s\n", ToString().c_str())" (identifier) "printf" (argument_list) "("%s\n", ToString().c_str())" (() "(" (string_literal) ""%s\n"" (") """ (string_content) "%s" (escape_sequence) "\n" (") """ (,) "," (call_expression) "ToString().c_str()" (field_expression) "ToString().c_str" (call_expression) "ToString()" (identifier) "ToString" (argument_list) "()" (() "(" ()) ")" (.) "." (field_identifier) "c_str" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) ";" (}) "}" (}) "}" (expression_statement) ";" (;) ";" (#endif) "#endif" (comment) "// INDEX_H"
1,816
45
{"language": "c", "success": true, "metadata": {"lines": 261, "avg_line_length": 28.1, "nodes": 1052, "errors": 0, "source_hash": "d0229e0f44744cf5f858e74484cd42446698eac43594eabeb355d0e1f933f773", "categorized_nodes": 747}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef INDEX_H\n#define INDEX_H\n\n#include \"transaction.h\"\n#include \"block.h\"\n\nclass CBlock;\nclass COutPoint;\n\n/** Position on disk for a particular transaction. */\nclass CDiskTxPos\n{\npublic:\n unsigned int nFile;\n unsigned int nBlockPos;\n unsigned int nTxPos;\n\n CDiskTxPos()\n {\n SetNull();\n }\n\n CDiskTxPos(unsigned int nFileIn, unsigned int nBlockPosIn, unsigned int nTxPosIn)\n {\n nFile = nFileIn;\n nBlockPos = nBlockPosIn;\n nTxPos = nTxPosIn;\n }\n\n IMPLEMENT_SERIALIZE( READWRITE(FLATDATA(*this)); )\n void SetNull() { nFile = (unsigned int) -1; nBlockPos = 0; nTxPos = 0; }\n bool IsNull() const { return (nFile == (unsigned int) -1); }\n\n friend bool operator==(const CDiskTxPos& a, const CDiskTxPos& b)\n {\n return (a.nFile == b.nFile &&\n a.nBlockPos == b.nBlockPos &&\n a.nTxPos == b.nTxPos);\n }\n\n friend bool operator!=(const CDiskTxPos& a, const CDiskTxPos& b)\n {\n return !(a == b);\n }\n\n\n std::string ToString() const\n {\n if (IsNull())\n return \"null\";\n else\n return strprintf(\"(nFile=%u, nBlockPos=%u, nTxPos=%u)\", nFile, nBlockPos, nTxPos);\n }\n\n void print() const\n {\n printf(\"%s\", ToString().c_str());\n }\n};\n\n\n\n/** A txdb record that contains the disk location of a transaction and the\n * locations of transactions that spend its outputs. vSpent is really only\n * used as a flag, but having the location is very helpful for debugging.\n */\nclass CTxIndex\n{\npublic:\n CDiskTxPos pos;\n std::vector<CDiskTxPos> vSpent;\n\n CTxIndex()\n {\n SetNull();\n }\n\n CTxIndex(const CDiskTxPos& posIn, unsigned int nOutputs)\n {\n pos = posIn;\n vSpent.resize(nOutputs);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);\n READWRITE(vSpent);\n )\n\n void SetNull()\n {\n pos.SetNull();\n vSpent.clear();\n }\n\n bool IsNull()\n {\n return pos.IsNull();\n }\n\n friend bool operator==(const CTxIndex& a, const CTxIndex& b)\n {\n return (a.pos == b.pos &&\n a.vSpent == b.vSpent);\n }\n\n friend bool operator!=(const CTxIndex& a, const CTxIndex& b)\n {\n return !(a == b);\n }\n int GetDepthInMainChain() const;\n\n};\n\n/** The block chain is a tree shaped structure starting with the\n * genesis block at the root, with each block potentially having multiple\n * candidates to be the next block. pprev and pnext link a path through the\n * main/longest chain. A blockindex may have multiple pprev pointing back\n * to it, but pnext will only point forward to the longest branch, or will\n * be null if the block is not part of the longest chain.\n */\nclass CBlockIndex\n{\npublic:\n const uint256* phashBlock;\n CBlockIndex* pprev;\n CBlockIndex* pnext;\n unsigned int nFile;\n unsigned int nBlockPos;\n uint256 nChainTrust; // ppcoin: trust score of block chain\n int nHeight;\n\n int64 nMint;\n int64 nMoneySupply;\n\n unsigned int nFlags; // ppcoin: block index flags\n enum\n {\n BLOCK_PROOF_OF_STAKE = (1 << 0), // is proof-of-stake block\n BLOCK_STAKE_ENTROPY = (1 << 1), // entropy bit for stake modifier\n BLOCK_STAKE_MODIFIER = (1 << 2), // regenerated stake modifier\n };\n\n uint64 nStakeModifier; // hash modifier for proof-of-stake\n unsigned int nStakeModifierChecksum; // checksum of index; in-memeory only\n\n // proof-of-stake specific fields\n COutPoint prevoutStake;\n unsigned int nStakeTime;\n uint256 hashProofOfStake;\n\n // block header\n int nVersion;\n uint256 hashMerkleRoot;\n unsigned int nTime;\n unsigned int nBits;\n unsigned int nNonce;\n\n CBlockIndex()\n {\n phashBlock = NULL;\n pprev = NULL;\n pnext = NULL;\n nFile = 0;\n nBlockPos = 0;\n nHeight = 0;\n nChainTrust = 0;\n nMint = 0;\n nMoneySupply = 0;\n nFlags = 0;\n nStakeModifier = 0;\n nStakeModifierChecksum = 0;\n hashProofOfStake = 0;\n prevoutStake.SetNull();\n nStakeTime = 0;\n\n nVersion = 0;\n hashMerkleRoot = 0;\n nTime = 0;\n nBits = 0;\n nNonce = 0;\n }\n\n CBlockIndex(unsigned int nFileIn, unsigned int nBlockPosIn, CBlock& block);\n\n CBlock GetBlockHeader() const;\n uint256 GetBlockHash() const;\n int64 GetBlockTime() const;\n uint256 GetBlockTrust() const;\n bool IsInMainChain() const;\n bool CheckIndex() const;\n\n enum { nMedianTimeSpan=11 };\n\n int64 GetMedianTimePast() const;\n\n int64 GetMedianTime() const;\n /**\n * Returns true if there are nRequired or more blocks of minVersion or above\n * in the last nToCheck blocks, starting at pstart and going backwards.\n */\n bool IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck);\n\n\n bool IsProofOfWork() const;\n bool IsProofOfStake() const;\n void SetProofOfStake();\n unsigned int GetStakeEntropyBit() const;\n bool SetStakeEntropyBit(unsigned int nEntropyBit);\n bool GeneratedStakeModifier() const;\n void SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier);\n std::string ToString() const;\n void print() const;\n};\n\n\n\n/** Used to marshal pointers into hashes for db storage. */\nclass CDiskBlockIndex : public CBlockIndex\n{\npublic:\n uint256 hashPrev;\n uint256 hashNext;\n\n CDiskBlockIndex()\n {\n hashPrev = 0;\n hashNext = 0;\n }\n\n explicit CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex)\n {\n hashPrev = (pprev ? pprev->GetBlockHash() : 0);\n hashNext = (pnext ? pnext->GetBlockHash() : 0);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);\n READWRITE(nStakeModifier);\n if (IsProofOfStake())\n {\n READWRITE(prevoutStake);\n READWRITE(nStakeTime);\n READWRITE(hashProofOfStake);\n }\n else if (fRead)\n {\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }\n\n // block header\n READWRITE(this->nVersion);\n READWRITE(hashPrev);\n READWRITE(hashMerkleRoot);\n READWRITE(nTime);\n READWRITE(nBits);\n READWRITE(nNonce);\n )\n\n uint256 GetBlockHash() const\n {\n CBlock block;\n block.nVersion = nVersion;\n block.hashPrevBlock = hashPrev;\n block.hashMerkleRoot = hashMerkleRoot;\n block.nTime = nTime;\n block.nBits = nBits;\n block.nNonce = nNonce;\n return block.GetHash();\n }\n\n\n std::string ToString() const\n {\n std::string str = \"CDiskBlockIndex(\";\n str += CBlockIndex::ToString();\n str += strprintf(\"\\n hashBlock=%s, hashPrev=%s, hashNext=%s)\",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str());\n return str;\n }\n\n void print() const\n {\n printf(\"%s\\n\", ToString().c_str());\n }\n};\n\n\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 14, 16, 80, 102, 118, 164, 188, 211, 227, 384, 1051], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 306, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "identifier", "text": "INDEX_H", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 15}}, {"id": 3, "type": "preproc_def", "text": "#define INDEX_H\n", "parent": 0, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 5, "type": "identifier", "text": "INDEX_H", "parent": 3, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 15}}, {"id": 6, "type": "preproc_include", "text": "#include \"transaction.h\"\n", "parent": 0, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"transaction.h\"", "parent": 6, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 24}}, {"id": 9, "type": "preproc_include", "text": "#include \"block.h\"\n", "parent": 0, "children": [10, 11], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"block.h\"", "parent": 9, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 18}}, {"id": 12, "type": "declaration", "text": "class CBlock;", "parent": 0, "children": [13], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 13}}, {"id": 13, "type": "identifier", "text": "CBlock", "parent": 12, "children": [], "start_point": {"row": 6, "column": 6}, "end_point": {"row": 6, "column": 12}}, {"id": 14, "type": "declaration", "text": "class COutPoint;", "parent": 0, "children": [15], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 16}}, {"id": 15, "type": "identifier", "text": "COutPoint", "parent": 14, "children": [], "start_point": {"row": 7, "column": 6}, "end_point": {"row": 7, "column": 15}}, {"id": 16, "type": "function_definition", "text": "class CDiskTxPos\n{\npublic:\n unsigned int nFile;\n unsigned int nBlockPos;\n unsigned int nTxPos;\n\n CDiskTxPos()\n {\n SetNull();\n }\n\n CDiskTxPos(unsigned int nFileIn, unsigned int nBlockPosIn, unsigned int nTxPosIn)\n {\n nFile = nFileIn;\n nBlockPos = nBlockPosIn;\n nTxPos = nTxPosIn;\n }", "parent": 0, "children": [17], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 27, "column": 5}}, {"id": 17, "type": "identifier", "text": "CDiskTxPos", "parent": 16, "children": [], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 16}}, {"id": 18, "type": "labeled_statement", "text": "public:\n unsigned int nFile;", "parent": 16, "children": [19], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 13, "column": 23}}, {"id": 19, "type": "declaration", "text": "unsigned int nFile;", "parent": 18, "children": [20, 23], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 23}}, {"id": 20, "type": "sized_type_specifier", "text": "unsigned int", "parent": 19, "children": [21, 22], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 16}}, {"id": 21, "type": "unsigned", "text": "unsigned", "parent": 20, "children": [], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 12}}, {"id": 22, "type": "primitive_type", "text": "int", "parent": 20, "children": [], "start_point": {"row": 13, "column": 13}, "end_point": {"row": 13, "column": 16}}, {"id": 23, "type": "identifier", "text": "nFile", "parent": 19, "children": [], "start_point": {"row": 13, "column": 17}, "end_point": {"row": 13, "column": 22}}, {"id": 24, "type": "declaration", "text": "unsigned int nBlockPos;", "parent": 16, "children": [25, 28], "start_point": {"row": 14, "column": 4}, "end_point": {"row": 14, "column": 27}}, {"id": 25, "type": "sized_type_specifier", "text": "unsigned int", "parent": 24, "children": [26, 27], "start_point": {"row": 14, "column": 4}, "end_point": {"row": 14, "column": 16}}, {"id": 26, "type": "unsigned", "text": "unsigned", "parent": 25, "children": [], "start_point": {"row": 14, "column": 4}, "end_point": {"row": 14, "column": 12}}, {"id": 27, "type": "primitive_type", "text": "int", "parent": 25, "children": [], "start_point": {"row": 14, "column": 13}, "end_point": {"row": 14, "column": 16}}, {"id": 28, "type": "identifier", "text": "nBlockPos", "parent": 24, "children": [], "start_point": {"row": 14, "column": 17}, "end_point": {"row": 14, "column": 26}}, {"id": 29, "type": "declaration", "text": "unsigned int nTxPos;", "parent": 16, "children": [30, 33], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 24}}, {"id": 30, "type": "sized_type_specifier", "text": "unsigned int", "parent": 29, "children": [31, 32], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 16}}, {"id": 31, "type": "unsigned", "text": "unsigned", "parent": 30, "children": [], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 12}}, {"id": 32, "type": "primitive_type", "text": "int", "parent": 30, "children": [], "start_point": {"row": 15, "column": 13}, "end_point": {"row": 15, "column": 16}}, {"id": 33, "type": "identifier", "text": "nTxPos", "parent": 29, "children": [], "start_point": {"row": 15, "column": 17}, "end_point": {"row": 15, "column": 23}}, {"id": 34, "type": "call_expression", "text": "CDiskTxPos()", "parent": 16, "children": [35, 36], "start_point": {"row": 17, "column": 4}, "end_point": {"row": 17, "column": 16}}, {"id": 35, "type": "identifier", "text": "CDiskTxPos", "parent": 34, "children": [], "start_point": {"row": 17, "column": 4}, "end_point": {"row": 17, "column": 14}}, {"id": 36, "type": "argument_list", "text": "()", "parent": 34, "children": [], "start_point": {"row": 17, "column": 14}, "end_point": {"row": 17, "column": 16}}, {"id": 37, "type": "call_expression", "text": "SetNull()", "parent": 16, "children": [38, 39], "start_point": {"row": 19, "column": 8}, "end_point": {"row": 19, "column": 17}}, {"id": 38, "type": "identifier", "text": "SetNull", "parent": 37, "children": [], "start_point": {"row": 19, "column": 8}, "end_point": {"row": 19, "column": 15}}, {"id": 39, "type": "argument_list", "text": "()", "parent": 37, "children": [], "start_point": {"row": 19, "column": 15}, "end_point": {"row": 19, "column": 17}}, {"id": 40, "type": "declaration", "text": "CDiskTxPos(unsigned int nFileIn, unsigned int nBlockPosIn, unsigned int nTxPosIn)\n {\n nFile = nFileIn;", "parent": 16, "children": [41, 47, 48, 51, 52, 56], "start_point": {"row": 22, "column": 4}, "end_point": {"row": 24, "column": 24}}, {"id": 41, "type": "macro_type_specifier", "text": "CDiskTxPos(unsigned int", "parent": 40, "children": [42, 43], "start_point": {"row": 22, "column": 4}, "end_point": {"row": 22, "column": 27}}, {"id": 42, "type": "identifier", "text": "CDiskTxPos", "parent": 41, "children": [], "start_point": {"row": 22, "column": 4}, "end_point": {"row": 22, "column": 14}}, {"id": 43, "type": "type_descriptor", "text": "unsigned int", "parent": 41, "children": [44], "start_point": {"row": 22, "column": 15}, "end_point": {"row": 22, "column": 27}}, {"id": 44, "type": "sized_type_specifier", "text": "unsigned int", "parent": 43, "children": [45, 46], "start_point": {"row": 22, "column": 15}, "end_point": {"row": 22, "column": 27}}, {"id": 45, "type": "unsigned", "text": "unsigned", "parent": 44, "children": [], "start_point": {"row": 22, "column": 15}, "end_point": {"row": 22, "column": 23}}, {"id": 46, "type": "primitive_type", "text": "int", "parent": 44, "children": [], "start_point": {"row": 22, "column": 24}, "end_point": {"row": 22, "column": 27}}, {"id": 47, "type": "identifier", "text": "nFileIn", "parent": 40, "children": [], "start_point": {"row": 22, "column": 28}, "end_point": {"row": 22, "column": 35}}, {"id": 48, "type": "ERROR", "text": "unsigned int", "parent": 40, "children": [49, 50], "start_point": {"row": 22, "column": 37}, "end_point": {"row": 22, "column": 49}}, {"id": 49, "type": "identifier", "text": "unsigned", "parent": 48, "children": [], "start_point": {"row": 22, "column": 37}, "end_point": {"row": 22, "column": 45}}, {"id": 50, "type": "identifier", "text": "int", "parent": 48, "children": [], "start_point": {"row": 22, "column": 46}, "end_point": {"row": 22, "column": 49}}, {"id": 51, "type": "identifier", "text": "nBlockPosIn", "parent": 40, "children": [], "start_point": {"row": 22, "column": 50}, "end_point": {"row": 22, "column": 61}}, {"id": 52, "type": "ERROR", "text": "unsigned int nTxPosIn)\n {", "parent": 40, "children": [53, 54, 55], "start_point": {"row": 22, "column": 63}, "end_point": {"row": 23, "column": 5}}, {"id": 53, "type": "identifier", "text": "unsigned", "parent": 52, "children": [], "start_point": {"row": 22, "column": 63}, "end_point": {"row": 22, "column": 71}}, {"id": 54, "type": "identifier", "text": "int", "parent": 52, "children": [], "start_point": {"row": 22, "column": 72}, "end_point": {"row": 22, "column": 75}}, {"id": 55, "type": "identifier", "text": "nTxPosIn", "parent": 52, "children": [], "start_point": {"row": 22, "column": 76}, "end_point": {"row": 22, "column": 84}}, {"id": 56, "type": "init_declarator", "text": "nFile = nFileIn", "parent": 40, "children": [57, 58, 59], "start_point": {"row": 24, "column": 8}, "end_point": {"row": 24, "column": 23}}, {"id": 57, "type": "identifier", "text": "nFile", "parent": 56, "children": [], "start_point": {"row": 24, "column": 8}, "end_point": {"row": 24, "column": 13}}, {"id": 58, "type": "=", "text": "=", "parent": 56, "children": [], "start_point": {"row": 24, "column": 14}, "end_point": {"row": 24, "column": 15}}, {"id": 59, "type": "identifier", "text": "nFileIn", "parent": 56, "children": [], "start_point": {"row": 24, "column": 16}, "end_point": {"row": 24, "column": 23}}, {"id": 60, "type": "assignment_expression", "text": "nBlockPos = nBlockPosIn", "parent": 16, "children": [61, 62, 63], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 31}}, {"id": 61, "type": "identifier", "text": "nBlockPos", "parent": 60, "children": [], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 17}}, {"id": 62, "type": "=", "text": "=", "parent": 60, "children": [], "start_point": {"row": 25, "column": 18}, "end_point": {"row": 25, "column": 19}}, {"id": 63, "type": "identifier", "text": "nBlockPosIn", "parent": 60, "children": [], "start_point": {"row": 25, "column": 20}, "end_point": {"row": 25, "column": 31}}, {"id": 64, "type": "assignment_expression", "text": "nTxPos = nTxPosIn", "parent": 16, "children": [65, 66, 67], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 25}}, {"id": 65, "type": "identifier", "text": "nTxPos", "parent": 64, "children": [], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 14}}, {"id": 66, "type": "=", "text": "=", "parent": 64, "children": [], "start_point": {"row": 26, "column": 15}, "end_point": {"row": 26, "column": 16}}, {"id": 67, "type": "identifier", "text": "nTxPosIn", "parent": 64, "children": [], "start_point": {"row": 26, "column": 17}, "end_point": {"row": 26, "column": 25}}, {"id": 68, "type": "call_expression", "text": "IMPLEMENT_SERIALIZE( READWRITE(FLATDATA(*this)); )", "parent": 0, "children": [69, 70], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 54}}, {"id": 69, "type": "identifier", "text": "IMPLEMENT_SERIALIZE", "parent": 68, "children": [], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 23}}, {"id": 70, "type": "argument_list", "text": "( READWRITE(FLATDATA(*this)); )", "parent": 68, "children": [71], "start_point": {"row": 29, "column": 23}, "end_point": {"row": 29, "column": 54}}, {"id": 71, "type": "call_expression", "text": "READWRITE(FLATDATA(*this))", "parent": 70, "children": [72, 73], "start_point": {"row": 29, "column": 25}, "end_point": {"row": 29, "column": 51}}, {"id": 72, "type": "identifier", "text": "READWRITE", "parent": 71, "children": [], "start_point": {"row": 29, "column": 25}, "end_point": {"row": 29, "column": 34}}, {"id": 73, "type": "argument_list", "text": "(FLATDATA(*this))", "parent": 71, "children": [74], "start_point": {"row": 29, "column": 34}, "end_point": {"row": 29, "column": 51}}, {"id": 74, "type": "call_expression", "text": "FLATDATA(*this)", "parent": 73, "children": [75, 76], "start_point": {"row": 29, "column": 35}, "end_point": {"row": 29, "column": 50}}, {"id": 75, "type": "identifier", "text": "FLATDATA", "parent": 74, "children": [], "start_point": {"row": 29, "column": 35}, "end_point": {"row": 29, "column": 43}}, {"id": 76, "type": "argument_list", "text": "(*this)", "parent": 74, "children": [77], "start_point": {"row": 29, "column": 43}, "end_point": {"row": 29, "column": 50}}, {"id": 77, "type": "pointer_expression", "text": "*this", "parent": 76, "children": [78, 79], "start_point": {"row": 29, "column": 44}, "end_point": {"row": 29, "column": 49}}, {"id": 78, "type": "*", "text": "*", "parent": 77, "children": [], "start_point": {"row": 29, "column": 44}, "end_point": {"row": 29, "column": 45}}, {"id": 79, "type": "identifier", "text": "this", "parent": 77, "children": [], "start_point": {"row": 29, "column": 45}, "end_point": {"row": 29, "column": 49}}, {"id": 80, "type": "function_definition", "text": "void SetNull() { nFile = (unsigned int) -1; nBlockPos = 0; nTxPos = 0; }", "parent": 0, "children": [81, 82], "start_point": {"row": 30, "column": 4}, "end_point": {"row": 30, "column": 76}}, {"id": 81, "type": "primitive_type", "text": "void", "parent": 80, "children": [], "start_point": {"row": 30, "column": 4}, "end_point": {"row": 30, "column": 8}}, {"id": 82, "type": "function_declarator", "text": "SetNull()", "parent": 80, "children": [83, 84], "start_point": {"row": 30, "column": 9}, "end_point": {"row": 30, "column": 18}}, {"id": 83, "type": "identifier", "text": "SetNull", "parent": 82, "children": [], "start_point": {"row": 30, "column": 9}, "end_point": {"row": 30, "column": 16}}, {"id": 84, "type": "parameter_list", "text": "()", "parent": 82, "children": [], "start_point": {"row": 30, "column": 16}, "end_point": {"row": 30, "column": 18}}, {"id": 85, "type": "assignment_expression", "text": "nFile = (unsigned int) -1", "parent": 80, "children": [86, 87, 88], "start_point": {"row": 30, "column": 21}, "end_point": {"row": 30, "column": 46}}, {"id": 86, "type": "identifier", "text": "nFile", "parent": 85, "children": [], "start_point": {"row": 30, "column": 21}, "end_point": {"row": 30, "column": 26}}, {"id": 87, "type": "=", "text": "=", "parent": 85, "children": [], "start_point": {"row": 30, "column": 27}, "end_point": {"row": 30, "column": 28}}, {"id": 88, "type": "cast_expression", "text": "(unsigned int) -1", "parent": 85, "children": [89, 93], "start_point": {"row": 30, "column": 29}, "end_point": {"row": 30, "column": 46}}, {"id": 89, "type": "type_descriptor", "text": "unsigned int", "parent": 88, "children": [90], "start_point": {"row": 30, "column": 30}, "end_point": {"row": 30, "column": 42}}, {"id": 90, "type": "sized_type_specifier", "text": "unsigned int", "parent": 89, "children": [91, 92], "start_point": {"row": 30, "column": 30}, "end_point": {"row": 30, "column": 42}}, {"id": 91, "type": "unsigned", "text": "unsigned", "parent": 90, "children": [], "start_point": {"row": 30, "column": 30}, "end_point": {"row": 30, "column": 38}}, {"id": 92, "type": "primitive_type", "text": "int", "parent": 90, "children": [], "start_point": {"row": 30, "column": 39}, "end_point": {"row": 30, "column": 42}}, {"id": 93, "type": "number_literal", "text": "-1", "parent": 88, "children": [], "start_point": {"row": 30, "column": 44}, "end_point": {"row": 30, "column": 46}}, {"id": 94, "type": "assignment_expression", "text": "nBlockPos = 0", "parent": 80, "children": [95, 96, 97], "start_point": {"row": 30, "column": 48}, "end_point": {"row": 30, "column": 61}}, {"id": 95, "type": "identifier", "text": "nBlockPos", "parent": 94, "children": [], "start_point": {"row": 30, "column": 48}, "end_point": {"row": 30, "column": 57}}, {"id": 96, "type": "=", "text": "=", "parent": 94, "children": [], "start_point": {"row": 30, "column": 58}, "end_point": {"row": 30, "column": 59}}, {"id": 97, "type": "number_literal", "text": "0", "parent": 94, "children": [], "start_point": {"row": 30, "column": 60}, "end_point": {"row": 30, "column": 61}}, {"id": 98, "type": "assignment_expression", "text": "nTxPos = 0", "parent": 80, "children": [99, 100, 101], "start_point": {"row": 30, "column": 63}, "end_point": {"row": 30, "column": 73}}, {"id": 99, "type": "identifier", "text": "nTxPos", "parent": 98, "children": [], "start_point": {"row": 30, "column": 63}, "end_point": {"row": 30, "column": 69}}, {"id": 100, "type": "=", "text": "=", "parent": 98, "children": [], "start_point": {"row": 30, "column": 70}, "end_point": {"row": 30, "column": 71}}, {"id": 101, "type": "number_literal", "text": "0", "parent": 98, "children": [], "start_point": {"row": 30, "column": 72}, "end_point": {"row": 30, "column": 73}}, {"id": 102, "type": "ERROR", "text": "bool IsNull() const", "parent": 0, "children": [103, 104], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 23}}, {"id": 103, "type": "primitive_type", "text": "bool", "parent": 102, "children": [], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 8}}, {"id": 104, "type": "function_declarator", "text": "IsNull()", "parent": 102, "children": [105, 106], "start_point": {"row": 31, "column": 9}, "end_point": {"row": 31, "column": 17}}, {"id": 105, "type": "identifier", "text": "IsNull", "parent": 104, "children": [], "start_point": {"row": 31, "column": 9}, "end_point": {"row": 31, "column": 15}}, {"id": 106, "type": "parameter_list", "text": "()", "parent": 104, "children": [], "start_point": {"row": 31, "column": 15}, "end_point": {"row": 31, "column": 17}}, {"id": 107, "type": "return_statement", "text": "return (nFile == (unsigned int) -1);", "parent": 0, "children": [108], "start_point": {"row": 31, "column": 26}, "end_point": {"row": 31, "column": 62}}, {"id": 108, "type": "parenthesized_expression", "text": "(nFile == (unsigned int) -1)", "parent": 107, "children": [109], "start_point": {"row": 31, "column": 33}, "end_point": {"row": 31, "column": 61}}, {"id": 109, "type": "binary_expression", "text": "nFile == (unsigned int) -1", "parent": 108, "children": [110, 111, 112], "start_point": {"row": 31, "column": 34}, "end_point": {"row": 31, "column": 60}}, {"id": 110, "type": "identifier", "text": "nFile", "parent": 109, "children": [], "start_point": {"row": 31, "column": 34}, "end_point": {"row": 31, "column": 39}}, {"id": 111, "type": "==", "text": "==", "parent": 109, "children": [], "start_point": {"row": 31, "column": 40}, "end_point": {"row": 31, "column": 42}}, {"id": 112, "type": "cast_expression", "text": "(unsigned int) -1", "parent": 109, "children": [113, 117], "start_point": {"row": 31, "column": 43}, "end_point": {"row": 31, "column": 60}}, {"id": 113, "type": "type_descriptor", "text": "unsigned int", "parent": 112, "children": [114], "start_point": {"row": 31, "column": 44}, "end_point": {"row": 31, "column": 56}}, {"id": 114, "type": "sized_type_specifier", "text": "unsigned int", "parent": 113, "children": [115, 116], "start_point": {"row": 31, "column": 44}, "end_point": {"row": 31, "column": 56}}, {"id": 115, "type": "unsigned", "text": "unsigned", "parent": 114, "children": [], "start_point": {"row": 31, "column": 44}, "end_point": {"row": 31, "column": 52}}, {"id": 116, "type": "primitive_type", "text": "int", "parent": 114, "children": [], "start_point": {"row": 31, "column": 53}, "end_point": {"row": 31, "column": 56}}, {"id": 117, "type": "number_literal", "text": "-1", "parent": 112, "children": [], "start_point": {"row": 31, "column": 58}, "end_point": {"row": 31, "column": 60}}, {"id": 118, "type": "declaration", "text": "friend bool", "parent": 0, "children": [119, 120], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 15}}, {"id": 119, "type": "type_identifier", "text": "friend", "parent": 118, "children": [], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 10}}, {"id": 120, "type": "identifier", "text": "bool", "parent": 118, "children": [], "start_point": {"row": 33, "column": 11}, "end_point": {"row": 33, "column": 15}}, {"id": 121, "type": "binary_expression", "text": "operator==(const CDiskTxPos& a, const CDiskTxPos& b)", "parent": 0, "children": [122, 123, 124], "start_point": {"row": 33, "column": 16}, "end_point": {"row": 33, "column": 68}}, {"id": 122, "type": "identifier", "text": "operator", "parent": 121, "children": [], "start_point": {"row": 33, "column": 16}, "end_point": {"row": 33, "column": 24}}, {"id": 123, "type": "==", "text": "==", "parent": 121, "children": [], "start_point": {"row": 33, "column": 24}, "end_point": {"row": 33, "column": 26}}, {"id": 124, "type": "parenthesized_expression", "text": "(const CDiskTxPos& a, const CDiskTxPos& b)", "parent": 121, "children": [125, 128], "start_point": {"row": 33, "column": 26}, "end_point": {"row": 33, "column": 68}}, {"id": 125, "type": "ERROR", "text": "const CDiskTxPos", "parent": 124, "children": [126], "start_point": {"row": 33, "column": 27}, "end_point": {"row": 33, "column": 43}}, {"id": 126, "type": "type_descriptor", "text": "const CDiskTxPos", "parent": 125, "children": [127], "start_point": {"row": 33, "column": 27}, "end_point": {"row": 33, "column": 43}}, {"id": 127, "type": "type_identifier", "text": "CDiskTxPos", "parent": 126, "children": [], "start_point": {"row": 33, "column": 33}, "end_point": {"row": 33, "column": 43}}, {"id": 128, "type": "comma_expression", "text": "& a, const CDiskTxPos& b", "parent": 124, "children": [129, 131], "start_point": {"row": 33, "column": 43}, "end_point": {"row": 33, "column": 67}}, {"id": 129, "type": "pointer_expression", "text": "& a", "parent": 128, "children": [130], "start_point": {"row": 33, "column": 43}, "end_point": {"row": 33, "column": 46}}, {"id": 130, "type": "identifier", "text": "a", "parent": 129, "children": [], "start_point": {"row": 33, "column": 45}, "end_point": {"row": 33, "column": 46}}, {"id": 131, "type": "binary_expression", "text": "CDiskTxPos& b", "parent": 128, "children": [132, 133], "start_point": {"row": 33, "column": 54}, "end_point": {"row": 33, "column": 67}}, {"id": 132, "type": "identifier", "text": "CDiskTxPos", "parent": 131, "children": [], "start_point": {"row": 33, "column": 54}, "end_point": {"row": 33, "column": 64}}, {"id": 133, "type": "identifier", "text": "b", "parent": 131, "children": [], "start_point": {"row": 33, "column": 66}, "end_point": {"row": 33, "column": 67}}, {"id": 134, "type": "return_statement", "text": "return (a.nFile == b.nFile &&\n a.nBlockPos == b.nBlockPos &&\n a.nTxPos == b.nTxPos);", "parent": 0, "children": [135], "start_point": {"row": 35, "column": 8}, "end_point": {"row": 37, "column": 41}}, {"id": 135, "type": "parenthesized_expression", "text": "(a.nFile == b.nFile &&\n a.nBlockPos == b.nBlockPos &&\n a.nTxPos == b.nTxPos)", "parent": 134, "children": [136], "start_point": {"row": 35, "column": 15}, "end_point": {"row": 37, "column": 40}}, {"id": 136, "type": "binary_expression", "text": "a.nFile == b.nFile &&\n a.nBlockPos == b.nBlockPos &&\n a.nTxPos == b.nTxPos", "parent": 135, "children": [137, 155, 156], "start_point": {"row": 35, "column": 16}, "end_point": {"row": 37, "column": 39}}, {"id": 137, "type": "binary_expression", "text": "a.nFile == b.nFile &&\n a.nBlockPos == b.nBlockPos", "parent": 136, "children": [138, 146, 147], "start_point": {"row": 35, "column": 16}, "end_point": {"row": 36, "column": 42}}, {"id": 138, "type": "binary_expression", "text": "a.nFile == b.nFile", "parent": 137, "children": [139, 142, 143], "start_point": {"row": 35, "column": 16}, "end_point": {"row": 35, "column": 38}}, {"id": 139, "type": "field_expression", "text": "a.nFile", "parent": 138, "children": [140, 141], "start_point": {"row": 35, "column": 16}, "end_point": {"row": 35, "column": 23}}, {"id": 140, "type": "identifier", "text": "a", "parent": 139, "children": [], "start_point": {"row": 35, "column": 16}, "end_point": {"row": 35, "column": 17}}, {"id": 141, "type": "field_identifier", "text": "nFile", "parent": 139, "children": [], "start_point": {"row": 35, "column": 18}, "end_point": {"row": 35, "column": 23}}, {"id": 142, "type": "==", "text": "==", "parent": 138, "children": [], "start_point": {"row": 35, "column": 28}, "end_point": {"row": 35, "column": 30}}, {"id": 143, "type": "field_expression", "text": "b.nFile", "parent": 138, "children": [144, 145], "start_point": {"row": 35, "column": 31}, "end_point": {"row": 35, "column": 38}}, {"id": 144, "type": "identifier", "text": "b", "parent": 143, "children": [], "start_point": {"row": 35, "column": 31}, "end_point": {"row": 35, "column": 32}}, {"id": 145, "type": "field_identifier", "text": "nFile", "parent": 143, "children": [], "start_point": {"row": 35, "column": 33}, "end_point": {"row": 35, "column": 38}}, {"id": 146, "type": "&&", "text": "&&", "parent": 137, "children": [], "start_point": {"row": 35, "column": 39}, "end_point": {"row": 35, "column": 41}}, {"id": 147, "type": "binary_expression", "text": "a.nBlockPos == b.nBlockPos", "parent": 137, "children": [148, 151, 152], "start_point": {"row": 36, "column": 16}, "end_point": {"row": 36, "column": 42}}, {"id": 148, "type": "field_expression", "text": "a.nBlockPos", "parent": 147, "children": [149, 150], "start_point": {"row": 36, "column": 16}, "end_point": {"row": 36, "column": 27}}, {"id": 149, "type": "identifier", "text": "a", "parent": 148, "children": [], "start_point": {"row": 36, "column": 16}, "end_point": {"row": 36, "column": 17}}, {"id": 150, "type": "field_identifier", "text": "nBlockPos", "parent": 148, "children": [], "start_point": {"row": 36, "column": 18}, "end_point": {"row": 36, "column": 27}}, {"id": 151, "type": "==", "text": "==", "parent": 147, "children": [], "start_point": {"row": 36, "column": 28}, "end_point": {"row": 36, "column": 30}}, {"id": 152, "type": "field_expression", "text": "b.nBlockPos", "parent": 147, "children": [153, 154], "start_point": {"row": 36, "column": 31}, "end_point": {"row": 36, "column": 42}}, {"id": 153, "type": "identifier", "text": "b", "parent": 152, "children": [], "start_point": {"row": 36, "column": 31}, "end_point": {"row": 36, "column": 32}}, {"id": 154, "type": "field_identifier", "text": "nBlockPos", "parent": 152, "children": [], "start_point": {"row": 36, "column": 33}, "end_point": {"row": 36, "column": 42}}, {"id": 155, "type": "&&", "text": "&&", "parent": 136, "children": [], "start_point": {"row": 36, "column": 43}, "end_point": {"row": 36, "column": 45}}, {"id": 156, "type": "binary_expression", "text": "a.nTxPos == b.nTxPos", "parent": 136, "children": [157, 160, 161], "start_point": {"row": 37, "column": 16}, "end_point": {"row": 37, "column": 39}}, {"id": 157, "type": "field_expression", "text": "a.nTxPos", "parent": 156, "children": [158, 159], "start_point": {"row": 37, "column": 16}, "end_point": {"row": 37, "column": 24}}, {"id": 158, "type": "identifier", "text": "a", "parent": 157, "children": [], "start_point": {"row": 37, "column": 16}, "end_point": {"row": 37, "column": 17}}, {"id": 159, "type": "field_identifier", "text": "nTxPos", "parent": 157, "children": [], "start_point": {"row": 37, "column": 18}, "end_point": {"row": 37, "column": 24}}, {"id": 160, "type": "==", "text": "==", "parent": 156, "children": [], "start_point": {"row": 37, "column": 28}, "end_point": {"row": 37, "column": 30}}, {"id": 161, "type": "field_expression", "text": "b.nTxPos", "parent": 156, "children": [162, 163], "start_point": {"row": 37, "column": 31}, "end_point": {"row": 37, "column": 39}}, {"id": 162, "type": "identifier", "text": "b", "parent": 161, "children": [], "start_point": {"row": 37, "column": 31}, "end_point": {"row": 37, "column": 32}}, {"id": 163, "type": "field_identifier", "text": "nTxPos", "parent": 161, "children": [], "start_point": {"row": 37, "column": 33}, "end_point": {"row": 37, "column": 39}}, {"id": 164, "type": "declaration", "text": "friend bool", "parent": 0, "children": [165, 166], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 40, "column": 15}}, {"id": 165, "type": "type_identifier", "text": "friend", "parent": 164, "children": [], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 40, "column": 10}}, {"id": 166, "type": "identifier", "text": "bool", "parent": 164, "children": [], "start_point": {"row": 40, "column": 11}, "end_point": {"row": 40, "column": 15}}, {"id": 167, "type": "binary_expression", "text": "operator!=(const CDiskTxPos& a, const CDiskTxPos& b)", "parent": 0, "children": [168, 169, 170], "start_point": {"row": 40, "column": 16}, "end_point": {"row": 40, "column": 68}}, {"id": 168, "type": "identifier", "text": "operator", "parent": 167, "children": [], "start_point": {"row": 40, "column": 16}, "end_point": {"row": 40, "column": 24}}, {"id": 169, "type": "!=", "text": "!=", "parent": 167, "children": [], "start_point": {"row": 40, "column": 24}, "end_point": {"row": 40, "column": 26}}, {"id": 170, "type": "parenthesized_expression", "text": "(const CDiskTxPos& a, const CDiskTxPos& b)", "parent": 167, "children": [171, 174], "start_point": {"row": 40, "column": 26}, "end_point": {"row": 40, "column": 68}}, {"id": 171, "type": "ERROR", "text": "const CDiskTxPos", "parent": 170, "children": [172], "start_point": {"row": 40, "column": 27}, "end_point": {"row": 40, "column": 43}}, {"id": 172, "type": "type_descriptor", "text": "const CDiskTxPos", "parent": 171, "children": [173], "start_point": {"row": 40, "column": 27}, "end_point": {"row": 40, "column": 43}}, {"id": 173, "type": "type_identifier", "text": "CDiskTxPos", "parent": 172, "children": [], "start_point": {"row": 40, "column": 33}, "end_point": {"row": 40, "column": 43}}, {"id": 174, "type": "comma_expression", "text": "& a, const CDiskTxPos& b", "parent": 170, "children": [175, 177], "start_point": {"row": 40, "column": 43}, "end_point": {"row": 40, "column": 67}}, {"id": 175, "type": "pointer_expression", "text": "& a", "parent": 174, "children": [176], "start_point": {"row": 40, "column": 43}, "end_point": {"row": 40, "column": 46}}, {"id": 176, "type": "identifier", "text": "a", "parent": 175, "children": [], "start_point": {"row": 40, "column": 45}, "end_point": {"row": 40, "column": 46}}, {"id": 177, "type": "binary_expression", "text": "CDiskTxPos& b", "parent": 174, "children": [178, 179], "start_point": {"row": 40, "column": 54}, "end_point": {"row": 40, "column": 67}}, {"id": 178, "type": "identifier", "text": "CDiskTxPos", "parent": 177, "children": [], "start_point": {"row": 40, "column": 54}, "end_point": {"row": 40, "column": 64}}, {"id": 179, "type": "identifier", "text": "b", "parent": 177, "children": [], "start_point": {"row": 40, "column": 66}, "end_point": {"row": 40, "column": 67}}, {"id": 180, "type": "return_statement", "text": "return !(a == b);", "parent": 0, "children": [181], "start_point": {"row": 42, "column": 8}, "end_point": {"row": 42, "column": 25}}, {"id": 181, "type": "unary_expression", "text": "!(a == b)", "parent": 180, "children": [182, 183], "start_point": {"row": 42, "column": 15}, "end_point": {"row": 42, "column": 24}}, {"id": 182, "type": "!", "text": "!", "parent": 181, "children": [], "start_point": {"row": 42, "column": 15}, "end_point": {"row": 42, "column": 16}}, {"id": 183, "type": "parenthesized_expression", "text": "(a == b)", "parent": 181, "children": [184], "start_point": {"row": 42, "column": 16}, "end_point": {"row": 42, "column": 24}}, {"id": 184, "type": "binary_expression", "text": "a == b", "parent": 183, "children": [185, 186, 187], "start_point": {"row": 42, "column": 17}, "end_point": {"row": 42, "column": 23}}, {"id": 185, "type": "identifier", "text": "a", "parent": 184, "children": [], "start_point": {"row": 42, "column": 17}, "end_point": {"row": 42, "column": 18}}, {"id": 186, "type": "==", "text": "==", "parent": 184, "children": [], "start_point": {"row": 42, "column": 19}, "end_point": {"row": 42, "column": 21}}, {"id": 187, "type": "identifier", "text": "b", "parent": 184, "children": [], "start_point": {"row": 42, "column": 22}, "end_point": {"row": 42, "column": 23}}, {"id": 188, "type": "labeled_statement", "text": "std::string ToString() const\n {\n if (IsNull())\n return \"null\";\n else\n return strprintf(\"(nFile=%u, nBlockPos=%u, nTxPos=%u)\", nFile, nBlockPos, nTxPos);\n }", "parent": 0, "children": [189, 190], "start_point": {"row": 46, "column": 4}, "end_point": {"row": 52, "column": 5}}, {"id": 189, "type": "statement_identifier", "text": "std", "parent": 188, "children": [], "start_point": {"row": 46, "column": 4}, "end_point": {"row": 46, "column": 7}}, {"id": 190, "type": "ERROR", "text": ":string ToString() const", "parent": 188, "children": [191, 192], "start_point": {"row": 46, "column": 8}, "end_point": {"row": 46, "column": 32}}, {"id": 191, "type": "type_identifier", "text": "string", "parent": 190, "children": [], "start_point": {"row": 46, "column": 9}, "end_point": {"row": 46, "column": 15}}, {"id": 192, "type": "function_declarator", "text": "ToString() const", "parent": 190, "children": [193, 194], "start_point": {"row": 46, "column": 16}, "end_point": {"row": 46, "column": 32}}, {"id": 193, "type": "identifier", "text": "ToString", "parent": 192, "children": [], "start_point": {"row": 46, "column": 16}, "end_point": {"row": 46, "column": 24}}, {"id": 194, "type": "parameter_list", "text": "()", "parent": 192, "children": [], "start_point": {"row": 46, "column": 24}, "end_point": {"row": 46, "column": 26}}, {"id": 195, "type": "if_statement", "text": "if (IsNull())\n return \"null\";\n else\n return strprintf(\"(nFile=%u, nBlockPos=%u, nTxPos=%u)\", nFile, nBlockPos, nTxPos);", "parent": 188, "children": [196, 200, 202], "start_point": {"row": 48, "column": 8}, "end_point": {"row": 51, "column": 94}}, {"id": 196, "type": "parenthesized_expression", "text": "(IsNull())", "parent": 195, "children": [197], "start_point": {"row": 48, "column": 11}, "end_point": {"row": 48, "column": 21}}, {"id": 197, "type": "call_expression", "text": "IsNull()", "parent": 196, "children": [198, 199], "start_point": {"row": 48, "column": 12}, "end_point": {"row": 48, "column": 20}}, {"id": 198, "type": "identifier", "text": "IsNull", "parent": 197, "children": [], "start_point": {"row": 48, "column": 12}, "end_point": {"row": 48, "column": 18}}, {"id": 199, "type": "argument_list", "text": "()", "parent": 197, "children": [], "start_point": {"row": 48, "column": 18}, "end_point": {"row": 48, "column": 20}}, {"id": 200, "type": "return_statement", "text": "return \"null\";", "parent": 195, "children": [201], "start_point": {"row": 49, "column": 12}, "end_point": {"row": 49, "column": 26}}, {"id": 201, "type": "string_literal", "text": "\"null\"", "parent": 200, "children": [], "start_point": {"row": 49, "column": 19}, "end_point": {"row": 49, "column": 25}}, {"id": 202, "type": "else_clause", "text": "else\n return strprintf(\"(nFile=%u, nBlockPos=%u, nTxPos=%u)\", nFile, nBlockPos, nTxPos);", "parent": 195, "children": [203], "start_point": {"row": 50, "column": 8}, "end_point": {"row": 51, "column": 94}}, {"id": 203, "type": "return_statement", "text": "return strprintf(\"(nFile=%u, nBlockPos=%u, nTxPos=%u)\", nFile, nBlockPos, nTxPos);", "parent": 202, "children": [204], "start_point": {"row": 51, "column": 12}, "end_point": {"row": 51, "column": 94}}, {"id": 204, "type": "call_expression", "text": "strprintf(\"(nFile=%u, nBlockPos=%u, nTxPos=%u)\", nFile, nBlockPos, nTxPos)", "parent": 203, "children": [205, 206], "start_point": {"row": 51, "column": 19}, "end_point": {"row": 51, "column": 93}}, {"id": 205, "type": "identifier", "text": "strprintf", "parent": 204, "children": [], "start_point": {"row": 51, "column": 19}, "end_point": {"row": 51, "column": 28}}, {"id": 206, "type": "argument_list", "text": "(\"(nFile=%u, nBlockPos=%u, nTxPos=%u)\", nFile, nBlockPos, nTxPos)", "parent": 204, "children": [207, 208, 209, 210], "start_point": {"row": 51, "column": 28}, "end_point": {"row": 51, "column": 93}}, {"id": 207, "type": "string_literal", "text": "\"(nFile=%u, nBlockPos=%u, nTxPos=%u)\"", "parent": 206, "children": [], "start_point": {"row": 51, "column": 29}, "end_point": {"row": 51, "column": 66}}, {"id": 208, "type": "identifier", "text": "nFile", "parent": 206, "children": [], "start_point": {"row": 51, "column": 68}, "end_point": {"row": 51, "column": 73}}, {"id": 209, "type": "identifier", "text": "nBlockPos", "parent": 206, "children": [], "start_point": {"row": 51, "column": 75}, "end_point": {"row": 51, "column": 84}}, {"id": 210, "type": "identifier", "text": "nTxPos", "parent": 206, "children": [], "start_point": {"row": 51, "column": 86}, "end_point": {"row": 51, "column": 92}}, {"id": 211, "type": "ERROR", "text": "void print() const", "parent": 0, "children": [212, 213], "start_point": {"row": 54, "column": 4}, "end_point": {"row": 54, "column": 22}}, {"id": 212, "type": "primitive_type", "text": "void", "parent": 211, "children": [], "start_point": {"row": 54, "column": 4}, "end_point": {"row": 54, "column": 8}}, {"id": 213, "type": "function_declarator", "text": "print()", "parent": 211, "children": [214, 215], "start_point": {"row": 54, "column": 9}, "end_point": {"row": 54, "column": 16}}, {"id": 214, "type": "identifier", "text": "print", "parent": 213, "children": [], "start_point": {"row": 54, "column": 9}, "end_point": {"row": 54, "column": 14}}, {"id": 215, "type": "parameter_list", "text": "()", "parent": 213, "children": [], "start_point": {"row": 54, "column": 14}, "end_point": {"row": 54, "column": 16}}, {"id": 216, "type": "call_expression", "text": "printf(\"%s\", ToString().c_str())", "parent": 0, "children": [217, 218], "start_point": {"row": 56, "column": 8}, "end_point": {"row": 56, "column": 40}}, {"id": 217, "type": "identifier", "text": "printf", "parent": 216, "children": [], "start_point": {"row": 56, "column": 8}, "end_point": {"row": 56, "column": 14}}, {"id": 218, "type": "argument_list", "text": "(\"%s\", ToString().c_str())", "parent": 216, "children": [219, 220], "start_point": {"row": 56, "column": 14}, "end_point": {"row": 56, "column": 40}}, {"id": 219, "type": "string_literal", "text": "\"%s\"", "parent": 218, "children": [], "start_point": {"row": 56, "column": 15}, "end_point": {"row": 56, "column": 19}}, {"id": 220, "type": "call_expression", "text": "ToString().c_str()", "parent": 218, "children": [221, 226], "start_point": {"row": 56, "column": 21}, "end_point": {"row": 56, "column": 39}}, {"id": 221, "type": "field_expression", "text": "ToString().c_str", "parent": 220, "children": [222, 225], "start_point": {"row": 56, "column": 21}, "end_point": {"row": 56, "column": 37}}, {"id": 222, "type": "call_expression", "text": "ToString()", "parent": 221, "children": [223, 224], "start_point": {"row": 56, "column": 21}, "end_point": {"row": 56, "column": 31}}, {"id": 223, "type": "identifier", "text": "ToString", "parent": 222, "children": [], "start_point": {"row": 56, "column": 21}, "end_point": {"row": 56, "column": 29}}, {"id": 224, "type": "argument_list", "text": "()", "parent": 222, "children": [], "start_point": {"row": 56, "column": 29}, "end_point": {"row": 56, "column": 31}}, {"id": 225, "type": "field_identifier", "text": "c_str", "parent": 221, "children": [], "start_point": {"row": 56, "column": 32}, "end_point": {"row": 56, "column": 37}}, {"id": 226, "type": "argument_list", "text": "()", "parent": 220, "children": [], "start_point": {"row": 56, "column": 37}, "end_point": {"row": 56, "column": 39}}, {"id": 227, "type": "function_definition", "text": "class CTxIndex\n{\npublic:\n CDiskTxPos pos;\n std::vector<CDiskTxPos> vSpent;\n\n CTxIndex()\n {\n SetNull();\n }\n\n CTxIndex(const CDiskTxPos& posIn, unsigned int nOutputs)\n {\n pos = posIn;\n vSpent.resize(nOutputs);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);\n READWRITE(vSpent);\n )\n\n void SetNull()\n {\n pos.SetNull();\n vSpent.clear();\n }\n\n bool IsNull()\n {\n return pos.IsNull();\n }\n\n friend bool operator==(const CTxIndex& a, const CTxIndex& b)\n {\n return (a.pos == b.pos &&\n a.vSpent == b.vSpent);\n }\n\n friend bool operator!=(const CTxIndex& a, const CTxIndex& b)\n {\n return !(a == b);\n }\n int GetDepthInMainChain() const;\n\n}", "parent": 0, "children": [228], "start_point": {"row": 66, "column": 0}, "end_point": {"row": 114, "column": 1}}, {"id": 228, "type": "identifier", "text": "CTxIndex", "parent": 227, "children": [], "start_point": {"row": 66, "column": 6}, "end_point": {"row": 66, "column": 14}}, {"id": 229, "type": "labeled_statement", "text": "public:\n CDiskTxPos pos;", "parent": 227, "children": [230], "start_point": {"row": 68, "column": 0}, "end_point": {"row": 69, "column": 19}}, {"id": 230, "type": "declaration", "text": "CDiskTxPos pos;", "parent": 229, "children": [231, 232], "start_point": {"row": 69, "column": 4}, "end_point": {"row": 69, "column": 19}}, {"id": 231, "type": "type_identifier", "text": "CDiskTxPos", "parent": 230, "children": [], "start_point": {"row": 69, "column": 4}, "end_point": {"row": 69, "column": 14}}, {"id": 232, "type": "identifier", "text": "pos", "parent": 230, "children": [], "start_point": {"row": 69, "column": 15}, "end_point": {"row": 69, "column": 18}}, {"id": 233, "type": "labeled_statement", "text": "std::vector<CDiskTxPos> vSpent;", "parent": 227, "children": [234], "start_point": {"row": 70, "column": 4}, "end_point": {"row": 70, "column": 35}}, {"id": 234, "type": "statement_identifier", "text": "std", "parent": 233, "children": [], "start_point": {"row": 70, "column": 4}, "end_point": {"row": 70, "column": 7}}, {"id": 235, "type": "binary_expression", "text": "vector<CDiskTxPos> vSpent", "parent": 233, "children": [236, 240, 241], "start_point": {"row": 70, "column": 9}, "end_point": {"row": 70, "column": 34}}, {"id": 236, "type": "binary_expression", "text": "vector<CDiskTxPos", "parent": 235, "children": [237, 238, 239], "start_point": {"row": 70, "column": 9}, "end_point": {"row": 70, "column": 26}}, {"id": 237, "type": "identifier", "text": "vector", "parent": 236, "children": [], "start_point": {"row": 70, "column": 9}, "end_point": {"row": 70, "column": 15}}, {"id": 238, "type": "<", "text": "<", "parent": 236, "children": [], "start_point": {"row": 70, "column": 15}, "end_point": {"row": 70, "column": 16}}, {"id": 239, "type": "identifier", "text": "CDiskTxPos", "parent": 236, "children": [], "start_point": {"row": 70, "column": 16}, "end_point": {"row": 70, "column": 26}}, {"id": 240, "type": ">", "text": ">", "parent": 235, "children": [], "start_point": {"row": 70, "column": 26}, "end_point": {"row": 70, "column": 27}}, {"id": 241, "type": "identifier", "text": "vSpent", "parent": 235, "children": [], "start_point": {"row": 70, "column": 28}, "end_point": {"row": 70, "column": 34}}, {"id": 242, "type": "call_expression", "text": "CTxIndex()", "parent": 227, "children": [243, 244], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 14}}, {"id": 243, "type": "identifier", "text": "CTxIndex", "parent": 242, "children": [], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 12}}, {"id": 244, "type": "argument_list", "text": "()", "parent": 242, "children": [], "start_point": {"row": 72, "column": 12}, "end_point": {"row": 72, "column": 14}}, {"id": 245, "type": "call_expression", "text": "SetNull()", "parent": 227, "children": [246, 247], "start_point": {"row": 74, "column": 8}, "end_point": {"row": 74, "column": 17}}, {"id": 246, "type": "identifier", "text": "SetNull", "parent": 245, "children": [], "start_point": {"row": 74, "column": 8}, "end_point": {"row": 74, "column": 15}}, {"id": 247, "type": "argument_list", "text": "()", "parent": 245, "children": [], "start_point": {"row": 74, "column": 15}, "end_point": {"row": 74, "column": 17}}, {"id": 248, "type": "comma_expression", "text": "CTxIndex(const CDiskTxPos& posIn, unsigned", "parent": 227, "children": [249, 255], "start_point": {"row": 77, "column": 4}, "end_point": {"row": 77, "column": 46}}, {"id": 249, "type": "binary_expression", "text": "CTxIndex(const CDiskTxPos& posIn", "parent": 248, "children": [250, 251, 254], "start_point": {"row": 77, "column": 4}, "end_point": {"row": 77, "column": 36}}, {"id": 250, "type": "identifier", "text": "CTxIndex", "parent": 249, "children": [], "start_point": {"row": 77, "column": 4}, "end_point": {"row": 77, "column": 12}}, {"id": 251, "type": "ERROR", "text": "(const CDiskTxPos", "parent": 249, "children": [252], "start_point": {"row": 77, "column": 12}, "end_point": {"row": 77, "column": 29}}, {"id": 252, "type": "type_descriptor", "text": "const CDiskTxPos", "parent": 251, "children": [253], "start_point": {"row": 77, "column": 13}, "end_point": {"row": 77, "column": 29}}, {"id": 253, "type": "type_identifier", "text": "CDiskTxPos", "parent": 252, "children": [], "start_point": {"row": 77, "column": 19}, "end_point": {"row": 77, "column": 29}}, {"id": 254, "type": "identifier", "text": "posIn", "parent": 249, "children": [], "start_point": {"row": 77, "column": 31}, "end_point": {"row": 77, "column": 36}}, {"id": 255, "type": "identifier", "text": "unsigned", "parent": 248, "children": [], "start_point": {"row": 77, "column": 38}, "end_point": {"row": 77, "column": 46}}, {"id": 256, "type": "function_definition", "text": "int nOutputs)\n {\n pos = posIn;\n vSpent.resize(nOutputs);\n }", "parent": 227, "children": [257, 258], "start_point": {"row": 77, "column": 47}, "end_point": {"row": 81, "column": 5}}, {"id": 257, "type": "primitive_type", "text": "int", "parent": 256, "children": [], "start_point": {"row": 77, "column": 47}, "end_point": {"row": 77, "column": 50}}, {"id": 258, "type": "identifier", "text": "nOutputs", "parent": 256, "children": [], "start_point": {"row": 77, "column": 51}, "end_point": {"row": 77, "column": 59}}, {"id": 259, "type": "assignment_expression", "text": "pos = posIn", "parent": 256, "children": [260, 261, 262], "start_point": {"row": 79, "column": 8}, "end_point": {"row": 79, "column": 19}}, {"id": 260, "type": "identifier", "text": "pos", "parent": 259, "children": [], "start_point": {"row": 79, "column": 8}, "end_point": {"row": 79, "column": 11}}, {"id": 261, "type": "=", "text": "=", "parent": 259, "children": [], "start_point": {"row": 79, "column": 12}, "end_point": {"row": 79, "column": 13}}, {"id": 262, "type": "identifier", "text": "posIn", "parent": 259, "children": [], "start_point": {"row": 79, "column": 14}, "end_point": {"row": 79, "column": 19}}, {"id": 263, "type": "call_expression", "text": "vSpent.resize(nOutputs)", "parent": 256, "children": [264, 267], "start_point": {"row": 80, "column": 8}, "end_point": {"row": 80, "column": 31}}, {"id": 264, "type": "field_expression", "text": "vSpent.resize", "parent": 263, "children": [265, 266], "start_point": {"row": 80, "column": 8}, "end_point": {"row": 80, "column": 21}}, {"id": 265, "type": "identifier", "text": "vSpent", "parent": 264, "children": [], "start_point": {"row": 80, "column": 8}, "end_point": {"row": 80, "column": 14}}, {"id": 266, "type": "field_identifier", "text": "resize", "parent": 264, "children": [], "start_point": {"row": 80, "column": 15}, "end_point": {"row": 80, "column": 21}}, {"id": 267, "type": "argument_list", "text": "(nOutputs)", "parent": 263, "children": [268], "start_point": {"row": 80, "column": 21}, "end_point": {"row": 80, "column": 31}}, {"id": 268, "type": "identifier", "text": "nOutputs", "parent": 267, "children": [], "start_point": {"row": 80, "column": 22}, "end_point": {"row": 80, "column": 30}}, {"id": 269, "type": "call_expression", "text": "IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);\n READWRITE(vSpent);\n )", "parent": 227, "children": [270, 271], "start_point": {"row": 83, "column": 4}, "end_point": {"row": 89, "column": 5}}, {"id": 270, "type": "identifier", "text": "IMPLEMENT_SERIALIZE", "parent": 269, "children": [], "start_point": {"row": 83, "column": 4}, "end_point": {"row": 83, "column": 23}}, {"id": 271, "type": "argument_list", "text": "(\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);\n READWRITE(vSpent);\n )", "parent": 269, "children": [272, 289], "start_point": {"row": 84, "column": 4}, "end_point": {"row": 89, "column": 5}}, {"id": 272, "type": "ERROR", "text": "if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);", "parent": 271, "children": [273, 281, 285], "start_point": {"row": 85, "column": 8}, "end_point": {"row": 87, "column": 23}}, {"id": 273, "type": "call_expression", "text": "if (!(nType & SER_GETHASH))", "parent": 272, "children": [274], "start_point": {"row": 85, "column": 8}, "end_point": {"row": 85, "column": 35}}, {"id": 274, "type": "argument_list", "text": "(!(nType & SER_GETHASH))", "parent": 273, "children": [275], "start_point": {"row": 85, "column": 11}, "end_point": {"row": 85, "column": 35}}, {"id": 275, "type": "unary_expression", "text": "!(nType & SER_GETHASH)", "parent": 274, "children": [276, 277], "start_point": {"row": 85, "column": 12}, "end_point": {"row": 85, "column": 34}}, {"id": 276, "type": "!", "text": "!", "parent": 275, "children": [], "start_point": {"row": 85, "column": 12}, "end_point": {"row": 85, "column": 13}}, {"id": 277, "type": "parenthesized_expression", "text": "(nType & SER_GETHASH)", "parent": 275, "children": [278], "start_point": {"row": 85, "column": 13}, "end_point": {"row": 85, "column": 34}}, {"id": 278, "type": "binary_expression", "text": "nType & SER_GETHASH", "parent": 277, "children": [279, 280], "start_point": {"row": 85, "column": 14}, "end_point": {"row": 85, "column": 33}}, {"id": 279, "type": "identifier", "text": "nType", "parent": 278, "children": [], "start_point": {"row": 85, "column": 14}, "end_point": {"row": 85, "column": 19}}, {"id": 280, "type": "identifier", "text": "SER_GETHASH", "parent": 278, "children": [], "start_point": {"row": 85, "column": 22}, "end_point": {"row": 85, "column": 33}}, {"id": 281, "type": "call_expression", "text": "READWRITE(nVersion)", "parent": 272, "children": [282, 283], "start_point": {"row": 86, "column": 12}, "end_point": {"row": 86, "column": 31}}, {"id": 282, "type": "identifier", "text": "READWRITE", "parent": 281, "children": [], "start_point": {"row": 86, "column": 12}, "end_point": {"row": 86, "column": 21}}, {"id": 283, "type": "argument_list", "text": "(nVersion)", "parent": 281, "children": [284], "start_point": {"row": 86, "column": 21}, "end_point": {"row": 86, "column": 31}}, {"id": 284, "type": "identifier", "text": "nVersion", "parent": 283, "children": [], "start_point": {"row": 86, "column": 22}, "end_point": {"row": 86, "column": 30}}, {"id": 285, "type": "call_expression", "text": "READWRITE(pos)", "parent": 272, "children": [286, 287], "start_point": {"row": 87, "column": 8}, "end_point": {"row": 87, "column": 22}}, {"id": 286, "type": "identifier", "text": "READWRITE", "parent": 285, "children": [], "start_point": {"row": 87, "column": 8}, "end_point": {"row": 87, "column": 17}}, {"id": 287, "type": "argument_list", "text": "(pos)", "parent": 285, "children": [288], "start_point": {"row": 87, "column": 17}, "end_point": {"row": 87, "column": 22}}, {"id": 288, "type": "identifier", "text": "pos", "parent": 287, "children": [], "start_point": {"row": 87, "column": 18}, "end_point": {"row": 87, "column": 21}}, {"id": 289, "type": "call_expression", "text": "READWRITE(vSpent)", "parent": 271, "children": [290, 291], "start_point": {"row": 88, "column": 8}, "end_point": {"row": 88, "column": 25}}, {"id": 290, "type": "identifier", "text": "READWRITE", "parent": 289, "children": [], "start_point": {"row": 88, "column": 8}, "end_point": {"row": 88, "column": 17}}, {"id": 291, "type": "argument_list", "text": "(vSpent)", "parent": 289, "children": [292], "start_point": {"row": 88, "column": 17}, "end_point": {"row": 88, "column": 25}}, {"id": 292, "type": "identifier", "text": "vSpent", "parent": 291, "children": [], "start_point": {"row": 88, "column": 18}, "end_point": {"row": 88, "column": 24}}, {"id": 293, "type": "function_definition", "text": "void SetNull()\n {\n pos.SetNull();\n vSpent.clear();\n }", "parent": 227, "children": [294, 295], "start_point": {"row": 91, "column": 4}, "end_point": {"row": 95, "column": 5}}, {"id": 294, "type": "primitive_type", "text": "void", "parent": 293, "children": [], "start_point": {"row": 91, "column": 4}, "end_point": {"row": 91, "column": 8}}, {"id": 295, "type": "function_declarator", "text": "SetNull()", "parent": 293, "children": [296, 297], "start_point": {"row": 91, "column": 9}, "end_point": {"row": 91, "column": 18}}, {"id": 296, "type": "identifier", "text": "SetNull", "parent": 295, "children": [], "start_point": {"row": 91, "column": 9}, "end_point": {"row": 91, "column": 16}}, {"id": 297, "type": "parameter_list", "text": "()", "parent": 295, "children": [], "start_point": {"row": 91, "column": 16}, "end_point": {"row": 91, "column": 18}}, {"id": 298, "type": "call_expression", "text": "pos.SetNull()", "parent": 293, "children": [299, 302], "start_point": {"row": 93, "column": 8}, "end_point": {"row": 93, "column": 21}}, {"id": 299, "type": "field_expression", "text": "pos.SetNull", "parent": 298, "children": [300, 301], "start_point": {"row": 93, "column": 8}, "end_point": {"row": 93, "column": 19}}, {"id": 300, "type": "identifier", "text": "pos", "parent": 299, "children": [], "start_point": {"row": 93, "column": 8}, "end_point": {"row": 93, "column": 11}}, {"id": 301, "type": "field_identifier", "text": "SetNull", "parent": 299, "children": [], "start_point": {"row": 93, "column": 12}, "end_point": {"row": 93, "column": 19}}, {"id": 302, "type": "argument_list", "text": "()", "parent": 298, "children": [], "start_point": {"row": 93, "column": 19}, "end_point": {"row": 93, "column": 21}}, {"id": 303, "type": "call_expression", "text": "vSpent.clear()", "parent": 293, "children": [304, 307], "start_point": {"row": 94, "column": 8}, "end_point": {"row": 94, "column": 22}}, {"id": 304, "type": "field_expression", "text": "vSpent.clear", "parent": 303, "children": [305, 306], "start_point": {"row": 94, "column": 8}, "end_point": {"row": 94, "column": 20}}, {"id": 305, "type": "identifier", "text": "vSpent", "parent": 304, "children": [], "start_point": {"row": 94, "column": 8}, "end_point": {"row": 94, "column": 14}}, {"id": 306, "type": "field_identifier", "text": "clear", "parent": 304, "children": [], "start_point": {"row": 94, "column": 15}, "end_point": {"row": 94, "column": 20}}, {"id": 307, "type": "argument_list", "text": "()", "parent": 303, "children": [], "start_point": {"row": 94, "column": 20}, "end_point": {"row": 94, "column": 22}}, {"id": 308, "type": "function_definition", "text": "bool IsNull()\n {\n return pos.IsNull();\n }", "parent": 227, "children": [309, 310], "start_point": {"row": 97, "column": 4}, "end_point": {"row": 100, "column": 5}}, {"id": 309, "type": "primitive_type", "text": "bool", "parent": 308, "children": [], "start_point": {"row": 97, "column": 4}, "end_point": {"row": 97, "column": 8}}, {"id": 310, "type": "function_declarator", "text": "IsNull()", "parent": 308, "children": [311, 312], "start_point": {"row": 97, "column": 9}, "end_point": {"row": 97, "column": 17}}, {"id": 311, "type": "identifier", "text": "IsNull", "parent": 310, "children": [], "start_point": {"row": 97, "column": 9}, "end_point": {"row": 97, "column": 15}}, {"id": 312, "type": "parameter_list", "text": "()", "parent": 310, "children": [], "start_point": {"row": 97, "column": 15}, "end_point": {"row": 97, "column": 17}}, {"id": 313, "type": "return_statement", "text": "return pos.IsNull();", "parent": 308, "children": [314], "start_point": {"row": 99, "column": 8}, "end_point": {"row": 99, "column": 28}}, {"id": 314, "type": "call_expression", "text": "pos.IsNull()", "parent": 313, "children": [315, 318], "start_point": {"row": 99, "column": 15}, "end_point": {"row": 99, "column": 27}}, {"id": 315, "type": "field_expression", "text": "pos.IsNull", "parent": 314, "children": [316, 317], "start_point": {"row": 99, "column": 15}, "end_point": {"row": 99, "column": 25}}, {"id": 316, "type": "identifier", "text": "pos", "parent": 315, "children": [], "start_point": {"row": 99, "column": 15}, "end_point": {"row": 99, "column": 18}}, {"id": 317, "type": "field_identifier", "text": "IsNull", "parent": 315, "children": [], "start_point": {"row": 99, "column": 19}, "end_point": {"row": 99, "column": 25}}, {"id": 318, "type": "argument_list", "text": "()", "parent": 314, "children": [], "start_point": {"row": 99, "column": 25}, "end_point": {"row": 99, "column": 27}}, {"id": 319, "type": "declaration", "text": "friend bool", "parent": 227, "children": [320, 321], "start_point": {"row": 102, "column": 4}, "end_point": {"row": 102, "column": 15}}, {"id": 320, "type": "type_identifier", "text": "friend", "parent": 319, "children": [], "start_point": {"row": 102, "column": 4}, "end_point": {"row": 102, "column": 10}}, {"id": 321, "type": "identifier", "text": "bool", "parent": 319, "children": [], "start_point": {"row": 102, "column": 11}, "end_point": {"row": 102, "column": 15}}, {"id": 322, "type": "binary_expression", "text": "operator==(const CTxIndex& a, const CTxIndex& b)", "parent": 227, "children": [323, 324, 325], "start_point": {"row": 102, "column": 16}, "end_point": {"row": 102, "column": 64}}, {"id": 323, "type": "identifier", "text": "operator", "parent": 322, "children": [], "start_point": {"row": 102, "column": 16}, "end_point": {"row": 102, "column": 24}}, {"id": 324, "type": "==", "text": "==", "parent": 322, "children": [], "start_point": {"row": 102, "column": 24}, "end_point": {"row": 102, "column": 26}}, {"id": 325, "type": "parenthesized_expression", "text": "(const CTxIndex& a, const CTxIndex& b)", "parent": 322, "children": [326, 329], "start_point": {"row": 102, "column": 26}, "end_point": {"row": 102, "column": 64}}, {"id": 326, "type": "ERROR", "text": "const CTxIndex", "parent": 325, "children": [327], "start_point": {"row": 102, "column": 27}, "end_point": {"row": 102, "column": 41}}, {"id": 327, "type": "type_descriptor", "text": "const CTxIndex", "parent": 326, "children": [328], "start_point": {"row": 102, "column": 27}, "end_point": {"row": 102, "column": 41}}, {"id": 328, "type": "type_identifier", "text": "CTxIndex", "parent": 327, "children": [], "start_point": {"row": 102, "column": 33}, "end_point": {"row": 102, "column": 41}}, {"id": 329, "type": "comma_expression", "text": "& a, const CTxIndex& b", "parent": 325, "children": [330, 332], "start_point": {"row": 102, "column": 41}, "end_point": {"row": 102, "column": 63}}, {"id": 330, "type": "pointer_expression", "text": "& a", "parent": 329, "children": [331], "start_point": {"row": 102, "column": 41}, "end_point": {"row": 102, "column": 44}}, {"id": 331, "type": "identifier", "text": "a", "parent": 330, "children": [], "start_point": {"row": 102, "column": 43}, "end_point": {"row": 102, "column": 44}}, {"id": 332, "type": "binary_expression", "text": "CTxIndex& b", "parent": 329, "children": [333, 334], "start_point": {"row": 102, "column": 52}, "end_point": {"row": 102, "column": 63}}, {"id": 333, "type": "identifier", "text": "CTxIndex", "parent": 332, "children": [], "start_point": {"row": 102, "column": 52}, "end_point": {"row": 102, "column": 60}}, {"id": 334, "type": "identifier", "text": "b", "parent": 332, "children": [], "start_point": {"row": 102, "column": 62}, "end_point": {"row": 102, "column": 63}}, {"id": 335, "type": "return_statement", "text": "return (a.pos == b.pos &&\n a.vSpent == b.vSpent);", "parent": 227, "children": [336], "start_point": {"row": 104, "column": 8}, "end_point": {"row": 105, "column": 38}}, {"id": 336, "type": "parenthesized_expression", "text": "(a.pos == b.pos &&\n a.vSpent == b.vSpent)", "parent": 335, "children": [337], "start_point": {"row": 104, "column": 15}, "end_point": {"row": 105, "column": 37}}, {"id": 337, "type": "binary_expression", "text": "a.pos == b.pos &&\n a.vSpent == b.vSpent", "parent": 336, "children": [338, 346, 347], "start_point": {"row": 104, "column": 16}, "end_point": {"row": 105, "column": 36}}, {"id": 338, "type": "binary_expression", "text": "a.pos == b.pos", "parent": 337, "children": [339, 342, 343], "start_point": {"row": 104, "column": 16}, "end_point": {"row": 104, "column": 33}}, {"id": 339, "type": "field_expression", "text": "a.pos", "parent": 338, "children": [340, 341], "start_point": {"row": 104, "column": 16}, "end_point": {"row": 104, "column": 21}}, {"id": 340, "type": "identifier", "text": "a", "parent": 339, "children": [], "start_point": {"row": 104, "column": 16}, "end_point": {"row": 104, "column": 17}}, {"id": 341, "type": "field_identifier", "text": "pos", "parent": 339, "children": [], "start_point": {"row": 104, "column": 18}, "end_point": {"row": 104, "column": 21}}, {"id": 342, "type": "==", "text": "==", "parent": 338, "children": [], "start_point": {"row": 104, "column": 25}, "end_point": {"row": 104, "column": 27}}, {"id": 343, "type": "field_expression", "text": "b.pos", "parent": 338, "children": [344, 345], "start_point": {"row": 104, "column": 28}, "end_point": {"row": 104, "column": 33}}, {"id": 344, "type": "identifier", "text": "b", "parent": 343, "children": [], "start_point": {"row": 104, "column": 28}, "end_point": {"row": 104, "column": 29}}, {"id": 345, "type": "field_identifier", "text": "pos", "parent": 343, "children": [], "start_point": {"row": 104, "column": 30}, "end_point": {"row": 104, "column": 33}}, {"id": 346, "type": "&&", "text": "&&", "parent": 337, "children": [], "start_point": {"row": 104, "column": 34}, "end_point": {"row": 104, "column": 36}}, {"id": 347, "type": "binary_expression", "text": "a.vSpent == b.vSpent", "parent": 337, "children": [348, 351, 352], "start_point": {"row": 105, "column": 16}, "end_point": {"row": 105, "column": 36}}, {"id": 348, "type": "field_expression", "text": "a.vSpent", "parent": 347, "children": [349, 350], "start_point": {"row": 105, "column": 16}, "end_point": {"row": 105, "column": 24}}, {"id": 349, "type": "identifier", "text": "a", "parent": 348, "children": [], "start_point": {"row": 105, "column": 16}, "end_point": {"row": 105, "column": 17}}, {"id": 350, "type": "field_identifier", "text": "vSpent", "parent": 348, "children": [], "start_point": {"row": 105, "column": 18}, "end_point": {"row": 105, "column": 24}}, {"id": 351, "type": "==", "text": "==", "parent": 347, "children": [], "start_point": {"row": 105, "column": 25}, "end_point": {"row": 105, "column": 27}}, {"id": 352, "type": "field_expression", "text": "b.vSpent", "parent": 347, "children": [353, 354], "start_point": {"row": 105, "column": 28}, "end_point": {"row": 105, "column": 36}}, {"id": 353, "type": "identifier", "text": "b", "parent": 352, "children": [], "start_point": {"row": 105, "column": 28}, "end_point": {"row": 105, "column": 29}}, {"id": 354, "type": "field_identifier", "text": "vSpent", "parent": 352, "children": [], "start_point": {"row": 105, "column": 30}, "end_point": {"row": 105, "column": 36}}, {"id": 355, "type": "declaration", "text": "friend bool", "parent": 227, "children": [356, 357], "start_point": {"row": 108, "column": 4}, "end_point": {"row": 108, "column": 15}}, {"id": 356, "type": "type_identifier", "text": "friend", "parent": 355, "children": [], "start_point": {"row": 108, "column": 4}, "end_point": {"row": 108, "column": 10}}, {"id": 357, "type": "identifier", "text": "bool", "parent": 355, "children": [], "start_point": {"row": 108, "column": 11}, "end_point": {"row": 108, "column": 15}}, {"id": 358, "type": "binary_expression", "text": "operator!=(const CTxIndex& a, const CTxIndex& b)", "parent": 227, "children": [359, 360, 361], "start_point": {"row": 108, "column": 16}, "end_point": {"row": 108, "column": 64}}, {"id": 359, "type": "identifier", "text": "operator", "parent": 358, "children": [], "start_point": {"row": 108, "column": 16}, "end_point": {"row": 108, "column": 24}}, {"id": 360, "type": "!=", "text": "!=", "parent": 358, "children": [], "start_point": {"row": 108, "column": 24}, "end_point": {"row": 108, "column": 26}}, {"id": 361, "type": "parenthesized_expression", "text": "(const CTxIndex& a, const CTxIndex& b)", "parent": 358, "children": [362, 365], "start_point": {"row": 108, "column": 26}, "end_point": {"row": 108, "column": 64}}, {"id": 362, "type": "ERROR", "text": "const CTxIndex", "parent": 361, "children": [363], "start_point": {"row": 108, "column": 27}, "end_point": {"row": 108, "column": 41}}, {"id": 363, "type": "type_descriptor", "text": "const CTxIndex", "parent": 362, "children": [364], "start_point": {"row": 108, "column": 27}, "end_point": {"row": 108, "column": 41}}, {"id": 364, "type": "type_identifier", "text": "CTxIndex", "parent": 363, "children": [], "start_point": {"row": 108, "column": 33}, "end_point": {"row": 108, "column": 41}}, {"id": 365, "type": "comma_expression", "text": "& a, const CTxIndex& b", "parent": 361, "children": [366, 368], "start_point": {"row": 108, "column": 41}, "end_point": {"row": 108, "column": 63}}, {"id": 366, "type": "pointer_expression", "text": "& a", "parent": 365, "children": [367], "start_point": {"row": 108, "column": 41}, "end_point": {"row": 108, "column": 44}}, {"id": 367, "type": "identifier", "text": "a", "parent": 366, "children": [], "start_point": {"row": 108, "column": 43}, "end_point": {"row": 108, "column": 44}}, {"id": 368, "type": "binary_expression", "text": "CTxIndex& b", "parent": 365, "children": [369, 370], "start_point": {"row": 108, "column": 52}, "end_point": {"row": 108, "column": 63}}, {"id": 369, "type": "identifier", "text": "CTxIndex", "parent": 368, "children": [], "start_point": {"row": 108, "column": 52}, "end_point": {"row": 108, "column": 60}}, {"id": 370, "type": "identifier", "text": "b", "parent": 368, "children": [], "start_point": {"row": 108, "column": 62}, "end_point": {"row": 108, "column": 63}}, {"id": 371, "type": "return_statement", "text": "return !(a == b);", "parent": 227, "children": [372], "start_point": {"row": 110, "column": 8}, "end_point": {"row": 110, "column": 25}}, {"id": 372, "type": "unary_expression", "text": "!(a == b)", "parent": 371, "children": [373, 374], "start_point": {"row": 110, "column": 15}, "end_point": {"row": 110, "column": 24}}, {"id": 373, "type": "!", "text": "!", "parent": 372, "children": [], "start_point": {"row": 110, "column": 15}, "end_point": {"row": 110, "column": 16}}, {"id": 374, "type": "parenthesized_expression", "text": "(a == b)", "parent": 372, "children": [375], "start_point": {"row": 110, "column": 16}, "end_point": {"row": 110, "column": 24}}, {"id": 375, "type": "binary_expression", "text": "a == b", "parent": 374, "children": [376, 377, 378], "start_point": {"row": 110, "column": 17}, "end_point": {"row": 110, "column": 23}}, {"id": 376, "type": "identifier", "text": "a", "parent": 375, "children": [], "start_point": {"row": 110, "column": 17}, "end_point": {"row": 110, "column": 18}}, {"id": 377, "type": "==", "text": "==", "parent": 375, "children": [], "start_point": {"row": 110, "column": 19}, "end_point": {"row": 110, "column": 21}}, {"id": 378, "type": "identifier", "text": "b", "parent": 375, "children": [], "start_point": {"row": 110, "column": 22}, "end_point": {"row": 110, "column": 23}}, {"id": 379, "type": "ERROR", "text": "int GetDepthInMainChain() const", "parent": 227, "children": [380, 381], "start_point": {"row": 112, "column": 4}, "end_point": {"row": 112, "column": 35}}, {"id": 380, "type": "primitive_type", "text": "int", "parent": 379, "children": [], "start_point": {"row": 112, "column": 4}, "end_point": {"row": 112, "column": 7}}, {"id": 381, "type": "function_declarator", "text": "GetDepthInMainChain()", "parent": 379, "children": [382, 383], "start_point": {"row": 112, "column": 8}, "end_point": {"row": 112, "column": 29}}, {"id": 382, "type": "identifier", "text": "GetDepthInMainChain", "parent": 381, "children": [], "start_point": {"row": 112, "column": 8}, "end_point": {"row": 112, "column": 27}}, {"id": 383, "type": "parameter_list", "text": "()", "parent": 381, "children": [], "start_point": {"row": 112, "column": 27}, "end_point": {"row": 112, "column": 29}}, {"id": 384, "type": "function_definition", "text": "class CBlockIndex\n{\npublic:\n const uint256* phashBlock;\n CBlockIndex* pprev;\n CBlockIndex* pnext;\n unsigned int nFile;\n unsigned int nBlockPos;\n uint256 nChainTrust; // ppcoin: trust score of block chain\n int nHeight;\n\n int64 nMint;\n int64 nMoneySupply;\n\n unsigned int nFlags; // ppcoin: block index flags\n enum\n {\n BLOCK_PROOF_OF_STAKE = (1 << 0), // is proof-of-stake block\n BLOCK_STAKE_ENTROPY = (1 << 1), // entropy bit for stake modifier\n BLOCK_STAKE_MODIFIER = (1 << 2), // regenerated stake modifier\n };\n\n uint64 nStakeModifier; // hash modifier for proof-of-stake\n unsigned int nStakeModifierChecksum; // checksum of index; in-memeory only\n\n // proof-of-stake specific fields\n COutPoint prevoutStake;\n unsigned int nStakeTime;\n uint256 hashProofOfStake;\n\n // block header\n int nVersion;\n uint256 hashMerkleRoot;\n unsigned int nTime;\n unsigned int nBits;\n unsigned int nNonce;\n\n CBlockIndex()\n {\n phashBlock = NULL;\n pprev = NULL;\n pnext = NULL;\n nFile = 0;\n nBlockPos = 0;\n nHeight = 0;\n nChainTrust = 0;\n nMint = 0;\n nMoneySupply = 0;\n nFlags = 0;\n nStakeModifier = 0;\n nStakeModifierChecksum = 0;\n hashProofOfStake = 0;\n prevoutStake.SetNull();\n nStakeTime = 0;\n\n nVersion = 0;\n hashMerkleRoot = 0;\n nTime = 0;\n nBits = 0;\n nNonce = 0;\n }\n\n CBlockIndex(unsigned int nFileIn, unsigned int nBlockPosIn, CBlock& block);\n\n CBlock GetBlockHeader() const;\n uint256 GetBlockHash() const;\n int64 GetBlockTime() const;\n uint256 GetBlockTrust() const;\n bool IsInMainChain() const;\n bool CheckIndex() const;\n\n enum { nMedianTimeSpan=11 };\n\n int64 GetMedianTimePast() const;\n\n int64 GetMedianTime() const;\n /**\n * Returns true if there are nRequired or more blocks of minVersion or above\n * in the last nToCheck blocks, starting at pstart and going backwards.\n */\n bool IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck);\n\n\n bool IsProofOfWork() const;\n bool IsProofOfStake() const;\n void SetProofOfStake();\n unsigned int GetStakeEntropyBit() const;\n bool SetStakeEntropyBit(unsigned int nEntropyBit);\n bool GeneratedStakeModifier() const;\n void SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier);\n std::string ToString() const;\n void print() const;\n};\n\n\n\n/** Used to marshal pointers into hashes for db storage. */\nclass CDiskBlockIndex : public CBlockIndex\n{\npublic:\n uint256 hashPrev;\n uint256 hashNext;\n\n CDiskBlockIndex()\n {\n hashPrev = 0;\n hashNext = 0;\n }\n\n explicit CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex)\n {\n hashPrev = (pprev ? pprev->GetBlockHash() : 0);\n hashNext = (pnext ? pnext->GetBlockHash() : 0);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);\n READWRITE(nStakeModifier);\n if (IsProofOfStake())\n {\n READWRITE(prevoutStake);\n READWRITE(nStakeTime);\n READWRITE(hashProofOfStake);\n }\n else if (fRead)\n {\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }\n\n // block header\n READWRITE(this->nVersion);\n READWRITE(hashPrev);\n READWRITE(hashMerkleRoot);\n READWRITE(nTime);\n READWRITE(nBits);\n READWRITE(nNonce);\n )\n\n uint256 GetBlockHash() const\n {\n CBlock block;\n block.nVersion = nVersion;\n block.hashPrevBlock = hashPrev;\n block.hashMerkleRoot = hashMerkleRoot;\n block.nTime = nTime;\n block.nBits = nBits;\n block.nNonce = nNonce;\n return block.GetHash();\n }\n\n\n std::string ToString() const\n {\n std::string str = \"CDiskBlockIndex(\";\n str += CBlockIndex::ToString();\n str += strprintf(\"\\n hashBlock=%s, hashPrev=%s, hashNext=%s)\",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str());\n return str;\n }\n\n void print() const\n {\n printf(\"%s\\n\", ToString().c_str());\n }\n}", "parent": 0, "children": [385], "start_point": {"row": 123, "column": 0}, "end_point": {"row": 302, "column": 1}}, {"id": 385, "type": "identifier", "text": "CBlockIndex", "parent": 384, "children": [], "start_point": {"row": 123, "column": 6}, "end_point": {"row": 123, "column": 17}}, {"id": 386, "type": "labeled_statement", "text": "public:\n const uint256* phashBlock;", "parent": 384, "children": [387], "start_point": {"row": 125, "column": 0}, "end_point": {"row": 126, "column": 30}}, {"id": 387, "type": "declaration", "text": "const uint256* phashBlock;", "parent": 386, "children": [388, 389], "start_point": {"row": 126, "column": 4}, "end_point": {"row": 126, "column": 30}}, {"id": 388, "type": "type_identifier", "text": "uint256", "parent": 387, "children": [], "start_point": {"row": 126, "column": 10}, "end_point": {"row": 126, "column": 17}}, {"id": 389, "type": "pointer_declarator", "text": "* phashBlock", "parent": 387, "children": [390, 391], "start_point": {"row": 126, "column": 17}, "end_point": {"row": 126, "column": 29}}, {"id": 390, "type": "*", "text": "*", "parent": 389, "children": [], "start_point": {"row": 126, "column": 17}, "end_point": {"row": 126, "column": 18}}, {"id": 391, "type": "identifier", "text": "phashBlock", "parent": 389, "children": [], "start_point": {"row": 126, "column": 19}, "end_point": {"row": 126, "column": 29}}, {"id": 392, "type": "declaration", "text": "CBlockIndex* pprev;", "parent": 384, "children": [393, 394], "start_point": {"row": 127, "column": 4}, "end_point": {"row": 127, "column": 23}}, {"id": 393, "type": "type_identifier", "text": "CBlockIndex", "parent": 392, "children": [], "start_point": {"row": 127, "column": 4}, "end_point": {"row": 127, "column": 15}}, {"id": 394, "type": "pointer_declarator", "text": "* pprev", "parent": 392, "children": [395, 396], "start_point": {"row": 127, "column": 15}, "end_point": {"row": 127, "column": 22}}, {"id": 395, "type": "*", "text": "*", "parent": 394, "children": [], "start_point": {"row": 127, "column": 15}, "end_point": {"row": 127, "column": 16}}, {"id": 396, "type": "identifier", "text": "pprev", "parent": 394, "children": [], "start_point": {"row": 127, "column": 17}, "end_point": {"row": 127, "column": 22}}, {"id": 397, "type": "declaration", "text": "CBlockIndex* pnext;", "parent": 384, "children": [398, 399], "start_point": {"row": 128, "column": 4}, "end_point": {"row": 128, "column": 23}}, {"id": 398, "type": "type_identifier", "text": "CBlockIndex", "parent": 397, "children": [], "start_point": {"row": 128, "column": 4}, "end_point": {"row": 128, "column": 15}}, {"id": 399, "type": "pointer_declarator", "text": "* pnext", "parent": 397, "children": [400, 401], "start_point": {"row": 128, "column": 15}, "end_point": {"row": 128, "column": 22}}, {"id": 400, "type": "*", "text": "*", "parent": 399, "children": [], "start_point": {"row": 128, "column": 15}, "end_point": {"row": 128, "column": 16}}, {"id": 401, "type": "identifier", "text": "pnext", "parent": 399, "children": [], "start_point": {"row": 128, "column": 17}, "end_point": {"row": 128, "column": 22}}, {"id": 402, "type": "declaration", "text": "unsigned int nFile;", "parent": 384, "children": [403, 406], "start_point": {"row": 129, "column": 4}, "end_point": {"row": 129, "column": 23}}, {"id": 403, "type": "sized_type_specifier", "text": "unsigned int", "parent": 402, "children": [404, 405], "start_point": {"row": 129, "column": 4}, "end_point": {"row": 129, "column": 16}}, {"id": 404, "type": "unsigned", "text": "unsigned", "parent": 403, "children": [], "start_point": {"row": 129, "column": 4}, "end_point": {"row": 129, "column": 12}}, {"id": 405, "type": "primitive_type", "text": "int", "parent": 403, "children": [], "start_point": {"row": 129, "column": 13}, "end_point": {"row": 129, "column": 16}}, {"id": 406, "type": "identifier", "text": "nFile", "parent": 402, "children": [], "start_point": {"row": 129, "column": 17}, "end_point": {"row": 129, "column": 22}}, {"id": 407, "type": "declaration", "text": "unsigned int nBlockPos;", "parent": 384, "children": [408, 411], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 27}}, {"id": 408, "type": "sized_type_specifier", "text": "unsigned int", "parent": 407, "children": [409, 410], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 16}}, {"id": 409, "type": "unsigned", "text": "unsigned", "parent": 408, "children": [], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 12}}, {"id": 410, "type": "primitive_type", "text": "int", "parent": 408, "children": [], "start_point": {"row": 130, "column": 13}, "end_point": {"row": 130, "column": 16}}, {"id": 411, "type": "identifier", "text": "nBlockPos", "parent": 407, "children": [], "start_point": {"row": 130, "column": 17}, "end_point": {"row": 130, "column": 26}}, {"id": 412, "type": "declaration", "text": "uint256 nChainTrust;", "parent": 384, "children": [413, 414], "start_point": {"row": 131, "column": 4}, "end_point": {"row": 131, "column": 24}}, {"id": 413, "type": "type_identifier", "text": "uint256", "parent": 412, "children": [], "start_point": {"row": 131, "column": 4}, "end_point": {"row": 131, "column": 11}}, {"id": 414, "type": "identifier", "text": "nChainTrust", "parent": 412, "children": [], "start_point": {"row": 131, "column": 12}, "end_point": {"row": 131, "column": 23}}, {"id": 415, "type": "declaration", "text": "int nHeight;", "parent": 384, "children": [416, 417], "start_point": {"row": 132, "column": 4}, "end_point": {"row": 132, "column": 16}}, {"id": 416, "type": "primitive_type", "text": "int", "parent": 415, "children": [], "start_point": {"row": 132, "column": 4}, "end_point": {"row": 132, "column": 7}}, {"id": 417, "type": "identifier", "text": "nHeight", "parent": 415, "children": [], "start_point": {"row": 132, "column": 8}, "end_point": {"row": 132, "column": 15}}, {"id": 418, "type": "declaration", "text": "int64 nMint;", "parent": 384, "children": [419, 420], "start_point": {"row": 134, "column": 4}, "end_point": {"row": 134, "column": 16}}, {"id": 419, "type": "type_identifier", "text": "int64", "parent": 418, "children": [], "start_point": {"row": 134, "column": 4}, "end_point": {"row": 134, "column": 9}}, {"id": 420, "type": "identifier", "text": "nMint", "parent": 418, "children": [], "start_point": {"row": 134, "column": 10}, "end_point": {"row": 134, "column": 15}}, {"id": 421, "type": "declaration", "text": "int64 nMoneySupply;", "parent": 384, "children": [422, 423], "start_point": {"row": 135, "column": 4}, "end_point": {"row": 135, "column": 23}}, {"id": 422, "type": "type_identifier", "text": "int64", "parent": 421, "children": [], "start_point": {"row": 135, "column": 4}, "end_point": {"row": 135, "column": 9}}, {"id": 423, "type": "identifier", "text": "nMoneySupply", "parent": 421, "children": [], "start_point": {"row": 135, "column": 10}, "end_point": {"row": 135, "column": 22}}, {"id": 424, "type": "declaration", "text": "unsigned int nFlags;", "parent": 384, "children": [425, 428], "start_point": {"row": 137, "column": 4}, "end_point": {"row": 137, "column": 24}}, {"id": 425, "type": "sized_type_specifier", "text": "unsigned int", "parent": 424, "children": [426, 427], "start_point": {"row": 137, "column": 4}, "end_point": {"row": 137, "column": 16}}, {"id": 426, "type": "unsigned", "text": "unsigned", "parent": 425, "children": [], "start_point": {"row": 137, "column": 4}, "end_point": {"row": 137, "column": 12}}, {"id": 427, "type": "primitive_type", "text": "int", "parent": 425, "children": [], "start_point": {"row": 137, "column": 13}, "end_point": {"row": 137, "column": 16}}, {"id": 428, "type": "identifier", "text": "nFlags", "parent": 424, "children": [], "start_point": {"row": 137, "column": 17}, "end_point": {"row": 137, "column": 23}}, {"id": 429, "type": "enum_specifier", "text": "enum\n {\n BLOCK_PROOF_OF_STAKE = (1 << 0), // is proof-of-stake block\n BLOCK_STAKE_ENTROPY = (1 << 1), // entropy bit for stake modifier\n BLOCK_STAKE_MODIFIER = (1 << 2), // regenerated stake modifier\n }", "parent": 384, "children": [430, 431], "start_point": {"row": 138, "column": 4}, "end_point": {"row": 143, "column": 5}}, {"id": 430, "type": "enum", "text": "enum", "parent": 429, "children": [], "start_point": {"row": 138, "column": 4}, "end_point": {"row": 138, "column": 8}}, {"id": 431, "type": "enumerator_list", "text": "{\n BLOCK_PROOF_OF_STAKE = (1 << 0), // is proof-of-stake block\n BLOCK_STAKE_ENTROPY = (1 << 1), // entropy bit for stake modifier\n BLOCK_STAKE_MODIFIER = (1 << 2), // regenerated stake modifier\n }", "parent": 429, "children": [432, 440, 448], "start_point": {"row": 139, "column": 4}, "end_point": {"row": 143, "column": 5}}, {"id": 432, "type": "enumerator", "text": "BLOCK_PROOF_OF_STAKE = (1 << 0)", "parent": 431, "children": [433, 434, 435], "start_point": {"row": 140, "column": 8}, "end_point": {"row": 140, "column": 39}}, {"id": 433, "type": "identifier", "text": "BLOCK_PROOF_OF_STAKE", "parent": 432, "children": [], "start_point": {"row": 140, "column": 8}, "end_point": {"row": 140, "column": 28}}, {"id": 434, "type": "=", "text": "=", "parent": 432, "children": [], "start_point": {"row": 140, "column": 29}, "end_point": {"row": 140, "column": 30}}, {"id": 435, "type": "parenthesized_expression", "text": "(1 << 0)", "parent": 432, "children": [436], "start_point": {"row": 140, "column": 31}, "end_point": {"row": 140, "column": 39}}, {"id": 436, "type": "binary_expression", "text": "1 << 0", "parent": 435, "children": [437, 438, 439], "start_point": {"row": 140, "column": 32}, "end_point": {"row": 140, "column": 38}}, {"id": 437, "type": "number_literal", "text": "1", "parent": 436, "children": [], "start_point": {"row": 140, "column": 32}, "end_point": {"row": 140, "column": 33}}, {"id": 438, "type": "<<", "text": "<<", "parent": 436, "children": [], "start_point": {"row": 140, "column": 34}, "end_point": {"row": 140, "column": 36}}, {"id": 439, "type": "number_literal", "text": "0", "parent": 436, "children": [], "start_point": {"row": 140, "column": 37}, "end_point": {"row": 140, "column": 38}}, {"id": 440, "type": "enumerator", "text": "BLOCK_STAKE_ENTROPY = (1 << 1)", "parent": 431, "children": [441, 442, 443], "start_point": {"row": 141, "column": 8}, "end_point": {"row": 141, "column": 39}}, {"id": 441, "type": "identifier", "text": "BLOCK_STAKE_ENTROPY", "parent": 440, "children": [], "start_point": {"row": 141, "column": 8}, "end_point": {"row": 141, "column": 27}}, {"id": 442, "type": "=", "text": "=", "parent": 440, "children": [], "start_point": {"row": 141, "column": 29}, "end_point": {"row": 141, "column": 30}}, {"id": 443, "type": "parenthesized_expression", "text": "(1 << 1)", "parent": 440, "children": [444], "start_point": {"row": 141, "column": 31}, "end_point": {"row": 141, "column": 39}}, {"id": 444, "type": "binary_expression", "text": "1 << 1", "parent": 443, "children": [445, 446, 447], "start_point": {"row": 141, "column": 32}, "end_point": {"row": 141, "column": 38}}, {"id": 445, "type": "number_literal", "text": "1", "parent": 444, "children": [], "start_point": {"row": 141, "column": 32}, "end_point": {"row": 141, "column": 33}}, {"id": 446, "type": "<<", "text": "<<", "parent": 444, "children": [], "start_point": {"row": 141, "column": 34}, "end_point": {"row": 141, "column": 36}}, {"id": 447, "type": "number_literal", "text": "1", "parent": 444, "children": [], "start_point": {"row": 141, "column": 37}, "end_point": {"row": 141, "column": 38}}, {"id": 448, "type": "enumerator", "text": "BLOCK_STAKE_MODIFIER = (1 << 2)", "parent": 431, "children": [449, 450, 451], "start_point": {"row": 142, "column": 8}, "end_point": {"row": 142, "column": 39}}, {"id": 449, "type": "identifier", "text": "BLOCK_STAKE_MODIFIER", "parent": 448, "children": [], "start_point": {"row": 142, "column": 8}, "end_point": {"row": 142, "column": 28}}, {"id": 450, "type": "=", "text": "=", "parent": 448, "children": [], "start_point": {"row": 142, "column": 29}, "end_point": {"row": 142, "column": 30}}, {"id": 451, "type": "parenthesized_expression", "text": "(1 << 2)", "parent": 448, "children": [452], "start_point": {"row": 142, "column": 31}, "end_point": {"row": 142, "column": 39}}, {"id": 452, "type": "binary_expression", "text": "1 << 2", "parent": 451, "children": [453, 454, 455], "start_point": {"row": 142, "column": 32}, "end_point": {"row": 142, "column": 38}}, {"id": 453, "type": "number_literal", "text": "1", "parent": 452, "children": [], "start_point": {"row": 142, "column": 32}, "end_point": {"row": 142, "column": 33}}, {"id": 454, "type": "<<", "text": "<<", "parent": 452, "children": [], "start_point": {"row": 142, "column": 34}, "end_point": {"row": 142, "column": 36}}, {"id": 455, "type": "number_literal", "text": "2", "parent": 452, "children": [], "start_point": {"row": 142, "column": 37}, "end_point": {"row": 142, "column": 38}}, {"id": 456, "type": "declaration", "text": "uint64 nStakeModifier;", "parent": 384, "children": [457, 458], "start_point": {"row": 145, "column": 4}, "end_point": {"row": 145, "column": 26}}, {"id": 457, "type": "type_identifier", "text": "uint64", "parent": 456, "children": [], "start_point": {"row": 145, "column": 4}, "end_point": {"row": 145, "column": 10}}, {"id": 458, "type": "identifier", "text": "nStakeModifier", "parent": 456, "children": [], "start_point": {"row": 145, "column": 11}, "end_point": {"row": 145, "column": 25}}, {"id": 459, "type": "declaration", "text": "unsigned int nStakeModifierChecksum;", "parent": 384, "children": [460, 463], "start_point": {"row": 146, "column": 4}, "end_point": {"row": 146, "column": 40}}, {"id": 460, "type": "sized_type_specifier", "text": "unsigned int", "parent": 459, "children": [461, 462], "start_point": {"row": 146, "column": 4}, "end_point": {"row": 146, "column": 16}}, {"id": 461, "type": "unsigned", "text": "unsigned", "parent": 460, "children": [], "start_point": {"row": 146, "column": 4}, "end_point": {"row": 146, "column": 12}}, {"id": 462, "type": "primitive_type", "text": "int", "parent": 460, "children": [], "start_point": {"row": 146, "column": 13}, "end_point": {"row": 146, "column": 16}}, {"id": 463, "type": "identifier", "text": "nStakeModifierChecksum", "parent": 459, "children": [], "start_point": {"row": 146, "column": 17}, "end_point": {"row": 146, "column": 39}}, {"id": 464, "type": "declaration", "text": "COutPoint prevoutStake;", "parent": 384, "children": [465, 466], "start_point": {"row": 149, "column": 4}, "end_point": {"row": 149, "column": 27}}, {"id": 465, "type": "type_identifier", "text": "COutPoint", "parent": 464, "children": [], "start_point": {"row": 149, "column": 4}, "end_point": {"row": 149, "column": 13}}, {"id": 466, "type": "identifier", "text": "prevoutStake", "parent": 464, "children": [], "start_point": {"row": 149, "column": 14}, "end_point": {"row": 149, "column": 26}}, {"id": 467, "type": "declaration", "text": "unsigned int nStakeTime;", "parent": 384, "children": [468, 471], "start_point": {"row": 150, "column": 4}, "end_point": {"row": 150, "column": 28}}, {"id": 468, "type": "sized_type_specifier", "text": "unsigned int", "parent": 467, "children": [469, 470], "start_point": {"row": 150, "column": 4}, "end_point": {"row": 150, "column": 16}}, {"id": 469, "type": "unsigned", "text": "unsigned", "parent": 468, "children": [], "start_point": {"row": 150, "column": 4}, "end_point": {"row": 150, "column": 12}}, {"id": 470, "type": "primitive_type", "text": "int", "parent": 468, "children": [], "start_point": {"row": 150, "column": 13}, "end_point": {"row": 150, "column": 16}}, {"id": 471, "type": "identifier", "text": "nStakeTime", "parent": 467, "children": [], "start_point": {"row": 150, "column": 17}, "end_point": {"row": 150, "column": 27}}, {"id": 472, "type": "declaration", "text": "uint256 hashProofOfStake;", "parent": 384, "children": [473, 474], "start_point": {"row": 151, "column": 4}, "end_point": {"row": 151, "column": 29}}, {"id": 473, "type": "type_identifier", "text": "uint256", "parent": 472, "children": [], "start_point": {"row": 151, "column": 4}, "end_point": {"row": 151, "column": 11}}, {"id": 474, "type": "identifier", "text": "hashProofOfStake", "parent": 472, "children": [], "start_point": {"row": 151, "column": 12}, "end_point": {"row": 151, "column": 28}}, {"id": 475, "type": "declaration", "text": "int nVersion;", "parent": 384, "children": [476, 477], "start_point": {"row": 154, "column": 4}, "end_point": {"row": 154, "column": 17}}, {"id": 476, "type": "primitive_type", "text": "int", "parent": 475, "children": [], "start_point": {"row": 154, "column": 4}, "end_point": {"row": 154, "column": 7}}, {"id": 477, "type": "identifier", "text": "nVersion", "parent": 475, "children": [], "start_point": {"row": 154, "column": 8}, "end_point": {"row": 154, "column": 16}}, {"id": 478, "type": "declaration", "text": "uint256 hashMerkleRoot;", "parent": 384, "children": [479, 480], "start_point": {"row": 155, "column": 4}, "end_point": {"row": 155, "column": 27}}, {"id": 479, "type": "type_identifier", "text": "uint256", "parent": 478, "children": [], "start_point": {"row": 155, "column": 4}, "end_point": {"row": 155, "column": 11}}, {"id": 480, "type": "identifier", "text": "hashMerkleRoot", "parent": 478, "children": [], "start_point": {"row": 155, "column": 12}, "end_point": {"row": 155, "column": 26}}, {"id": 481, "type": "declaration", "text": "unsigned int nTime;", "parent": 384, "children": [482, 485], "start_point": {"row": 156, "column": 4}, "end_point": {"row": 156, "column": 23}}, {"id": 482, "type": "sized_type_specifier", "text": "unsigned int", "parent": 481, "children": [483, 484], "start_point": {"row": 156, "column": 4}, "end_point": {"row": 156, "column": 16}}, {"id": 483, "type": "unsigned", "text": "unsigned", "parent": 482, "children": [], "start_point": {"row": 156, "column": 4}, "end_point": {"row": 156, "column": 12}}, {"id": 484, "type": "primitive_type", "text": "int", "parent": 482, "children": [], "start_point": {"row": 156, "column": 13}, "end_point": {"row": 156, "column": 16}}, {"id": 485, "type": "identifier", "text": "nTime", "parent": 481, "children": [], "start_point": {"row": 156, "column": 17}, "end_point": {"row": 156, "column": 22}}, {"id": 486, "type": "declaration", "text": "unsigned int nBits;", "parent": 384, "children": [487, 490], "start_point": {"row": 157, "column": 4}, "end_point": {"row": 157, "column": 23}}, {"id": 487, "type": "sized_type_specifier", "text": "unsigned int", "parent": 486, "children": [488, 489], "start_point": {"row": 157, "column": 4}, "end_point": {"row": 157, "column": 16}}, {"id": 488, "type": "unsigned", "text": "unsigned", "parent": 487, "children": [], "start_point": {"row": 157, "column": 4}, "end_point": {"row": 157, "column": 12}}, {"id": 489, "type": "primitive_type", "text": "int", "parent": 487, "children": [], "start_point": {"row": 157, "column": 13}, "end_point": {"row": 157, "column": 16}}, {"id": 490, "type": "identifier", "text": "nBits", "parent": 486, "children": [], "start_point": {"row": 157, "column": 17}, "end_point": {"row": 157, "column": 22}}, {"id": 491, "type": "declaration", "text": "unsigned int nNonce;", "parent": 384, "children": [492, 495], "start_point": {"row": 158, "column": 4}, "end_point": {"row": 158, "column": 24}}, {"id": 492, "type": "sized_type_specifier", "text": "unsigned int", "parent": 491, "children": [493, 494], "start_point": {"row": 158, "column": 4}, "end_point": {"row": 158, "column": 16}}, {"id": 493, "type": "unsigned", "text": "unsigned", "parent": 492, "children": [], "start_point": {"row": 158, "column": 4}, "end_point": {"row": 158, "column": 12}}, {"id": 494, "type": "primitive_type", "text": "int", "parent": 492, "children": [], "start_point": {"row": 158, "column": 13}, "end_point": {"row": 158, "column": 16}}, {"id": 495, "type": "identifier", "text": "nNonce", "parent": 491, "children": [], "start_point": {"row": 158, "column": 17}, "end_point": {"row": 158, "column": 23}}, {"id": 496, "type": "call_expression", "text": "CBlockIndex()", "parent": 384, "children": [497, 498], "start_point": {"row": 160, "column": 4}, "end_point": {"row": 160, "column": 17}}, {"id": 497, "type": "identifier", "text": "CBlockIndex", "parent": 496, "children": [], "start_point": {"row": 160, "column": 4}, "end_point": {"row": 160, "column": 15}}, {"id": 498, "type": "argument_list", "text": "()", "parent": 496, "children": [], "start_point": {"row": 160, "column": 15}, "end_point": {"row": 160, "column": 17}}, {"id": 499, "type": "assignment_expression", "text": "phashBlock = NULL", "parent": 384, "children": [500, 501, 502], "start_point": {"row": 162, "column": 8}, "end_point": {"row": 162, "column": 25}}, {"id": 500, "type": "identifier", "text": "phashBlock", "parent": 499, "children": [], "start_point": {"row": 162, "column": 8}, "end_point": {"row": 162, "column": 18}}, {"id": 501, "type": "=", "text": "=", "parent": 499, "children": [], "start_point": {"row": 162, "column": 19}, "end_point": {"row": 162, "column": 20}}, {"id": 502, "type": "null", "text": "NULL", "parent": 499, "children": [503], "start_point": {"row": 162, "column": 21}, "end_point": {"row": 162, "column": 25}}, {"id": 503, "type": "NULL", "text": "NULL", "parent": 502, "children": [], "start_point": {"row": 162, "column": 21}, "end_point": {"row": 162, "column": 25}}, {"id": 504, "type": "assignment_expression", "text": "pprev = NULL", "parent": 384, "children": [505, 506, 507], "start_point": {"row": 163, "column": 8}, "end_point": {"row": 163, "column": 20}}, {"id": 505, "type": "identifier", "text": "pprev", "parent": 504, "children": [], "start_point": {"row": 163, "column": 8}, "end_point": {"row": 163, "column": 13}}, {"id": 506, "type": "=", "text": "=", "parent": 504, "children": [], "start_point": {"row": 163, "column": 14}, "end_point": {"row": 163, "column": 15}}, {"id": 507, "type": "null", "text": "NULL", "parent": 504, "children": [508], "start_point": {"row": 163, "column": 16}, "end_point": {"row": 163, "column": 20}}, {"id": 508, "type": "NULL", "text": "NULL", "parent": 507, "children": [], "start_point": {"row": 163, "column": 16}, "end_point": {"row": 163, "column": 20}}, {"id": 509, "type": "assignment_expression", "text": "pnext = NULL", "parent": 384, "children": [510, 511, 512], "start_point": {"row": 164, "column": 8}, "end_point": {"row": 164, "column": 20}}, {"id": 510, "type": "identifier", "text": "pnext", "parent": 509, "children": [], "start_point": {"row": 164, "column": 8}, "end_point": {"row": 164, "column": 13}}, {"id": 511, "type": "=", "text": "=", "parent": 509, "children": [], "start_point": {"row": 164, "column": 14}, "end_point": {"row": 164, "column": 15}}, {"id": 512, "type": "null", "text": "NULL", "parent": 509, "children": [513], "start_point": {"row": 164, "column": 16}, "end_point": {"row": 164, "column": 20}}, {"id": 513, "type": "NULL", "text": "NULL", "parent": 512, "children": [], "start_point": {"row": 164, "column": 16}, "end_point": {"row": 164, "column": 20}}, {"id": 514, "type": "assignment_expression", "text": "nFile = 0", "parent": 384, "children": [515, 516, 517], "start_point": {"row": 165, "column": 8}, "end_point": {"row": 165, "column": 17}}, {"id": 515, "type": "identifier", "text": "nFile", "parent": 514, "children": [], "start_point": {"row": 165, "column": 8}, "end_point": {"row": 165, "column": 13}}, {"id": 516, "type": "=", "text": "=", "parent": 514, "children": [], "start_point": {"row": 165, "column": 14}, "end_point": {"row": 165, "column": 15}}, {"id": 517, "type": "number_literal", "text": "0", "parent": 514, "children": [], "start_point": {"row": 165, "column": 16}, "end_point": {"row": 165, "column": 17}}, {"id": 518, "type": "assignment_expression", "text": "nBlockPos = 0", "parent": 384, "children": [519, 520, 521], "start_point": {"row": 166, "column": 8}, "end_point": {"row": 166, "column": 21}}, {"id": 519, "type": "identifier", "text": "nBlockPos", "parent": 518, "children": [], "start_point": {"row": 166, "column": 8}, "end_point": {"row": 166, "column": 17}}, {"id": 520, "type": "=", "text": "=", "parent": 518, "children": [], "start_point": {"row": 166, "column": 18}, "end_point": {"row": 166, "column": 19}}, {"id": 521, "type": "number_literal", "text": "0", "parent": 518, "children": [], "start_point": {"row": 166, "column": 20}, "end_point": {"row": 166, "column": 21}}, {"id": 522, "type": "assignment_expression", "text": "nHeight = 0", "parent": 384, "children": [523, 524, 525], "start_point": {"row": 167, "column": 8}, "end_point": {"row": 167, "column": 19}}, {"id": 523, "type": "identifier", "text": "nHeight", "parent": 522, "children": [], "start_point": {"row": 167, "column": 8}, "end_point": {"row": 167, "column": 15}}, {"id": 524, "type": "=", "text": "=", "parent": 522, "children": [], "start_point": {"row": 167, "column": 16}, "end_point": {"row": 167, "column": 17}}, {"id": 525, "type": "number_literal", "text": "0", "parent": 522, "children": [], "start_point": {"row": 167, "column": 18}, "end_point": {"row": 167, "column": 19}}, {"id": 526, "type": "assignment_expression", "text": "nChainTrust = 0", "parent": 384, "children": [527, 528, 529], "start_point": {"row": 168, "column": 8}, "end_point": {"row": 168, "column": 23}}, {"id": 527, "type": "identifier", "text": "nChainTrust", "parent": 526, "children": [], "start_point": {"row": 168, "column": 8}, "end_point": {"row": 168, "column": 19}}, {"id": 528, "type": "=", "text": "=", "parent": 526, "children": [], "start_point": {"row": 168, "column": 20}, "end_point": {"row": 168, "column": 21}}, {"id": 529, "type": "number_literal", "text": "0", "parent": 526, "children": [], "start_point": {"row": 168, "column": 22}, "end_point": {"row": 168, "column": 23}}, {"id": 530, "type": "assignment_expression", "text": "nMint = 0", "parent": 384, "children": [531, 532, 533], "start_point": {"row": 169, "column": 8}, "end_point": {"row": 169, "column": 17}}, {"id": 531, "type": "identifier", "text": "nMint", "parent": 530, "children": [], "start_point": {"row": 169, "column": 8}, "end_point": {"row": 169, "column": 13}}, {"id": 532, "type": "=", "text": "=", "parent": 530, "children": [], "start_point": {"row": 169, "column": 14}, "end_point": {"row": 169, "column": 15}}, {"id": 533, "type": "number_literal", "text": "0", "parent": 530, "children": [], "start_point": {"row": 169, "column": 16}, "end_point": {"row": 169, "column": 17}}, {"id": 534, "type": "assignment_expression", "text": "nMoneySupply = 0", "parent": 384, "children": [535, 536, 537], "start_point": {"row": 170, "column": 8}, "end_point": {"row": 170, "column": 24}}, {"id": 535, "type": "identifier", "text": "nMoneySupply", "parent": 534, "children": [], "start_point": {"row": 170, "column": 8}, "end_point": {"row": 170, "column": 20}}, {"id": 536, "type": "=", "text": "=", "parent": 534, "children": [], "start_point": {"row": 170, "column": 21}, "end_point": {"row": 170, "column": 22}}, {"id": 537, "type": "number_literal", "text": "0", "parent": 534, "children": [], "start_point": {"row": 170, "column": 23}, "end_point": {"row": 170, "column": 24}}, {"id": 538, "type": "assignment_expression", "text": "nFlags = 0", "parent": 384, "children": [539, 540, 541], "start_point": {"row": 171, "column": 8}, "end_point": {"row": 171, "column": 18}}, {"id": 539, "type": "identifier", "text": "nFlags", "parent": 538, "children": [], "start_point": {"row": 171, "column": 8}, "end_point": {"row": 171, "column": 14}}, {"id": 540, "type": "=", "text": "=", "parent": 538, "children": [], "start_point": {"row": 171, "column": 15}, "end_point": {"row": 171, "column": 16}}, {"id": 541, "type": "number_literal", "text": "0", "parent": 538, "children": [], "start_point": {"row": 171, "column": 17}, "end_point": {"row": 171, "column": 18}}, {"id": 542, "type": "assignment_expression", "text": "nStakeModifier = 0", "parent": 384, "children": [543, 544, 545], "start_point": {"row": 172, "column": 8}, "end_point": {"row": 172, "column": 26}}, {"id": 543, "type": "identifier", "text": "nStakeModifier", "parent": 542, "children": [], "start_point": {"row": 172, "column": 8}, "end_point": {"row": 172, "column": 22}}, {"id": 544, "type": "=", "text": "=", "parent": 542, "children": [], "start_point": {"row": 172, "column": 23}, "end_point": {"row": 172, "column": 24}}, {"id": 545, "type": "number_literal", "text": "0", "parent": 542, "children": [], "start_point": {"row": 172, "column": 25}, "end_point": {"row": 172, "column": 26}}, {"id": 546, "type": "assignment_expression", "text": "nStakeModifierChecksum = 0", "parent": 384, "children": [547, 548, 549], "start_point": {"row": 173, "column": 8}, "end_point": {"row": 173, "column": 34}}, {"id": 547, "type": "identifier", "text": "nStakeModifierChecksum", "parent": 546, "children": [], "start_point": {"row": 173, "column": 8}, "end_point": {"row": 173, "column": 30}}, {"id": 548, "type": "=", "text": "=", "parent": 546, "children": [], "start_point": {"row": 173, "column": 31}, "end_point": {"row": 173, "column": 32}}, {"id": 549, "type": "number_literal", "text": "0", "parent": 546, "children": [], "start_point": {"row": 173, "column": 33}, "end_point": {"row": 173, "column": 34}}, {"id": 550, "type": "assignment_expression", "text": "hashProofOfStake = 0", "parent": 384, "children": [551, 552, 553], "start_point": {"row": 174, "column": 8}, "end_point": {"row": 174, "column": 28}}, {"id": 551, "type": "identifier", "text": "hashProofOfStake", "parent": 550, "children": [], "start_point": {"row": 174, "column": 8}, "end_point": {"row": 174, "column": 24}}, {"id": 552, "type": "=", "text": "=", "parent": 550, "children": [], "start_point": {"row": 174, "column": 25}, "end_point": {"row": 174, "column": 26}}, {"id": 553, "type": "number_literal", "text": "0", "parent": 550, "children": [], "start_point": {"row": 174, "column": 27}, "end_point": {"row": 174, "column": 28}}, {"id": 554, "type": "call_expression", "text": "prevoutStake.SetNull()", "parent": 384, "children": [555, 558], "start_point": {"row": 175, "column": 8}, "end_point": {"row": 175, "column": 30}}, {"id": 555, "type": "field_expression", "text": "prevoutStake.SetNull", "parent": 554, "children": [556, 557], "start_point": {"row": 175, "column": 8}, "end_point": {"row": 175, "column": 28}}, {"id": 556, "type": "identifier", "text": "prevoutStake", "parent": 555, "children": [], "start_point": {"row": 175, "column": 8}, "end_point": {"row": 175, "column": 20}}, {"id": 557, "type": "field_identifier", "text": "SetNull", "parent": 555, "children": [], "start_point": {"row": 175, "column": 21}, "end_point": {"row": 175, "column": 28}}, {"id": 558, "type": "argument_list", "text": "()", "parent": 554, "children": [], "start_point": {"row": 175, "column": 28}, "end_point": {"row": 175, "column": 30}}, {"id": 559, "type": "assignment_expression", "text": "nStakeTime = 0", "parent": 384, "children": [560, 561, 562], "start_point": {"row": 176, "column": 8}, "end_point": {"row": 176, "column": 22}}, {"id": 560, "type": "identifier", "text": "nStakeTime", "parent": 559, "children": [], "start_point": {"row": 176, "column": 8}, "end_point": {"row": 176, "column": 18}}, {"id": 561, "type": "=", "text": "=", "parent": 559, "children": [], "start_point": {"row": 176, "column": 19}, "end_point": {"row": 176, "column": 20}}, {"id": 562, "type": "number_literal", "text": "0", "parent": 559, "children": [], "start_point": {"row": 176, "column": 21}, "end_point": {"row": 176, "column": 22}}, {"id": 563, "type": "assignment_expression", "text": "nVersion = 0", "parent": 384, "children": [564, 565, 566], "start_point": {"row": 178, "column": 8}, "end_point": {"row": 178, "column": 26}}, {"id": 564, "type": "identifier", "text": "nVersion", "parent": 563, "children": [], "start_point": {"row": 178, "column": 8}, "end_point": {"row": 178, "column": 16}}, {"id": 565, "type": "=", "text": "=", "parent": 563, "children": [], "start_point": {"row": 178, "column": 23}, "end_point": {"row": 178, "column": 24}}, {"id": 566, "type": "number_literal", "text": "0", "parent": 563, "children": [], "start_point": {"row": 178, "column": 25}, "end_point": {"row": 178, "column": 26}}, {"id": 567, "type": "assignment_expression", "text": "hashMerkleRoot = 0", "parent": 384, "children": [568, 569, 570], "start_point": {"row": 179, "column": 8}, "end_point": {"row": 179, "column": 26}}, {"id": 568, "type": "identifier", "text": "hashMerkleRoot", "parent": 567, "children": [], "start_point": {"row": 179, "column": 8}, "end_point": {"row": 179, "column": 22}}, {"id": 569, "type": "=", "text": "=", "parent": 567, "children": [], "start_point": {"row": 179, "column": 23}, "end_point": {"row": 179, "column": 24}}, {"id": 570, "type": "number_literal", "text": "0", "parent": 567, "children": [], "start_point": {"row": 179, "column": 25}, "end_point": {"row": 179, "column": 26}}, {"id": 571, "type": "assignment_expression", "text": "nTime = 0", "parent": 384, "children": [572, 573, 574], "start_point": {"row": 180, "column": 8}, "end_point": {"row": 180, "column": 26}}, {"id": 572, "type": "identifier", "text": "nTime", "parent": 571, "children": [], "start_point": {"row": 180, "column": 8}, "end_point": {"row": 180, "column": 13}}, {"id": 573, "type": "=", "text": "=", "parent": 571, "children": [], "start_point": {"row": 180, "column": 23}, "end_point": {"row": 180, "column": 24}}, {"id": 574, "type": "number_literal", "text": "0", "parent": 571, "children": [], "start_point": {"row": 180, "column": 25}, "end_point": {"row": 180, "column": 26}}, {"id": 575, "type": "assignment_expression", "text": "nBits = 0", "parent": 384, "children": [576, 577, 578], "start_point": {"row": 181, "column": 8}, "end_point": {"row": 181, "column": 26}}, {"id": 576, "type": "identifier", "text": "nBits", "parent": 575, "children": [], "start_point": {"row": 181, "column": 8}, "end_point": {"row": 181, "column": 13}}, {"id": 577, "type": "=", "text": "=", "parent": 575, "children": [], "start_point": {"row": 181, "column": 23}, "end_point": {"row": 181, "column": 24}}, {"id": 578, "type": "number_literal", "text": "0", "parent": 575, "children": [], "start_point": {"row": 181, "column": 25}, "end_point": {"row": 181, "column": 26}}, {"id": 579, "type": "assignment_expression", "text": "nNonce = 0", "parent": 384, "children": [580, 581, 582], "start_point": {"row": 182, "column": 8}, "end_point": {"row": 182, "column": 26}}, {"id": 580, "type": "identifier", "text": "nNonce", "parent": 579, "children": [], "start_point": {"row": 182, "column": 8}, "end_point": {"row": 182, "column": 14}}, {"id": 581, "type": "=", "text": "=", "parent": 579, "children": [], "start_point": {"row": 182, "column": 23}, "end_point": {"row": 182, "column": 24}}, {"id": 582, "type": "number_literal", "text": "0", "parent": 579, "children": [], "start_point": {"row": 182, "column": 25}, "end_point": {"row": 182, "column": 26}}, {"id": 583, "type": "declaration", "text": "CBlockIndex(unsigned int nFileIn, unsigned int nBlockPosIn, CBlock& block);", "parent": 384, "children": [584, 590, 591, 594, 595, 596], "start_point": {"row": 185, "column": 4}, "end_point": {"row": 185, "column": 79}}, {"id": 584, "type": "macro_type_specifier", "text": "CBlockIndex(unsigned int", "parent": 583, "children": [585, 586], "start_point": {"row": 185, "column": 4}, "end_point": {"row": 185, "column": 28}}, {"id": 585, "type": "identifier", "text": "CBlockIndex", "parent": 584, "children": [], "start_point": {"row": 185, "column": 4}, "end_point": {"row": 185, "column": 15}}, {"id": 586, "type": "type_descriptor", "text": "unsigned int", "parent": 584, "children": [587], "start_point": {"row": 185, "column": 16}, "end_point": {"row": 185, "column": 28}}, {"id": 587, "type": "sized_type_specifier", "text": "unsigned int", "parent": 586, "children": [588, 589], "start_point": {"row": 185, "column": 16}, "end_point": {"row": 185, "column": 28}}, {"id": 588, "type": "unsigned", "text": "unsigned", "parent": 587, "children": [], "start_point": {"row": 185, "column": 16}, "end_point": {"row": 185, "column": 24}}, {"id": 589, "type": "primitive_type", "text": "int", "parent": 587, "children": [], "start_point": {"row": 185, "column": 25}, "end_point": {"row": 185, "column": 28}}, {"id": 590, "type": "identifier", "text": "nFileIn", "parent": 583, "children": [], "start_point": {"row": 185, "column": 29}, "end_point": {"row": 185, "column": 36}}, {"id": 591, "type": "ERROR", "text": "unsigned int", "parent": 583, "children": [592, 593], "start_point": {"row": 185, "column": 38}, "end_point": {"row": 185, "column": 50}}, {"id": 592, "type": "identifier", "text": "unsigned", "parent": 591, "children": [], "start_point": {"row": 185, "column": 38}, "end_point": {"row": 185, "column": 46}}, {"id": 593, "type": "identifier", "text": "int", "parent": 591, "children": [], "start_point": {"row": 185, "column": 47}, "end_point": {"row": 185, "column": 50}}, {"id": 594, "type": "identifier", "text": "nBlockPosIn", "parent": 583, "children": [], "start_point": {"row": 185, "column": 51}, "end_point": {"row": 185, "column": 62}}, {"id": 595, "type": "identifier", "text": "CBlock", "parent": 583, "children": [], "start_point": {"row": 185, "column": 64}, "end_point": {"row": 185, "column": 70}}, {"id": 596, "type": "ERROR", "text": "& block)", "parent": 583, "children": [597], "start_point": {"row": 185, "column": 70}, "end_point": {"row": 185, "column": 78}}, {"id": 597, "type": "identifier", "text": "block", "parent": 596, "children": [], "start_point": {"row": 185, "column": 72}, "end_point": {"row": 185, "column": 77}}, {"id": 598, "type": "function_definition", "text": "CBlock GetBlockHeader() const;\n uint256 GetBlockHash() const;\n int64 GetBlockTime() const;\n uint256 GetBlockTrust() const;\n bool IsInMainChain() const;\n bool CheckIndex() const;\n\n enum { nMedianTimeSpan=11 };\n\n int64 GetMedianTimePast() const;\n\n int64 GetMedianTime() const;\n /**\n * Returns true if there are nRequired or more blocks of minVersion or above\n * in the last nToCheck blocks, starting at pstart and going backwards.\n */\n bool IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck);\n\n\n bool IsProofOfWork() const;\n bool IsProofOfStake() const;\n void SetProofOfStake();\n unsigned int GetStakeEntropyBit() const;\n bool SetStakeEntropyBit(unsigned int nEntropyBit);\n bool GeneratedStakeModifier() const;\n void SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier);\n std::string ToString() const;\n void print() const;\n};\n\n\n\n/** Used to marshal pointers into hashes for db storage. */\nclass CDiskBlockIndex : public CBlockIndex\n{\npublic:\n uint256 hashPrev;\n uint256 hashNext;\n\n CDiskBlockIndex()\n {\n hashPrev = 0;\n hashNext = 0;\n }", "parent": 384, "children": [599, 600, 603, 630, 640, 663, 672, 677, 684, 694, 699, 710, 726, 729], "start_point": {"row": 187, "column": 4}, "end_point": {"row": 231, "column": 5}}, {"id": 599, "type": "type_identifier", "text": "CBlock", "parent": 598, "children": [], "start_point": {"row": 187, "column": 4}, "end_point": {"row": 187, "column": 10}}, {"id": 600, "type": "function_declarator", "text": "GetBlockHeader()", "parent": 598, "children": [601, 602], "start_point": {"row": 187, "column": 11}, "end_point": {"row": 187, "column": 27}}, {"id": 601, "type": "identifier", "text": "GetBlockHeader", "parent": 600, "children": [], "start_point": {"row": 187, "column": 11}, "end_point": {"row": 187, "column": 25}}, {"id": 602, "type": "parameter_list", "text": "()", "parent": 600, "children": [], "start_point": {"row": 187, "column": 25}, "end_point": {"row": 187, "column": 27}}, {"id": 603, "type": "declaration", "text": "const;\n uint256 GetBlockHash() const;\n int64 GetBlockTime() const;\n uint256 GetBlockTrust() const;\n bool IsInMainChain() const;\n bool CheckIndex() const;\n\n enum { nMedianTimeSpan=11 };", "parent": 598, "children": [604, 605, 626], "start_point": {"row": 187, "column": 28}, "end_point": {"row": 194, "column": 32}}, {"id": 604, "type": "type_identifier", "text": "uint256", "parent": 603, "children": [], "start_point": {"row": 188, "column": 4}, "end_point": {"row": 188, "column": 11}}, {"id": 605, "type": "ERROR", "text": "GetBlockHash() const;\n int64 GetBlockTime() const;\n uint256 GetBlockTrust() const;\n bool IsInMainChain() const;\n bool CheckIndex() const;\n\n enum {", "parent": 603, "children": [606, 609, 610, 613, 614, 617, 618, 621, 622, 625], "start_point": {"row": 188, "column": 12}, "end_point": {"row": 194, "column": 10}}, {"id": 606, "type": "function_declarator", "text": "GetBlockHash() const", "parent": 605, "children": [607, 608], "start_point": {"row": 188, "column": 12}, "end_point": {"row": 188, "column": 32}}, {"id": 607, "type": "identifier", "text": "GetBlockHash", "parent": 606, "children": [], "start_point": {"row": 188, "column": 12}, "end_point": {"row": 188, "column": 24}}, {"id": 608, "type": "parameter_list", "text": "()", "parent": 606, "children": [], "start_point": {"row": 188, "column": 24}, "end_point": {"row": 188, "column": 26}}, {"id": 609, "type": "identifier", "text": "int64", "parent": 605, "children": [], "start_point": {"row": 189, "column": 4}, "end_point": {"row": 189, "column": 9}}, {"id": 610, "type": "function_declarator", "text": "GetBlockTime() const", "parent": 605, "children": [611, 612], "start_point": {"row": 189, "column": 10}, "end_point": {"row": 189, "column": 30}}, {"id": 611, "type": "identifier", "text": "GetBlockTime", "parent": 610, "children": [], "start_point": {"row": 189, "column": 10}, "end_point": {"row": 189, "column": 22}}, {"id": 612, "type": "parameter_list", "text": "()", "parent": 610, "children": [], "start_point": {"row": 189, "column": 22}, "end_point": {"row": 189, "column": 24}}, {"id": 613, "type": "identifier", "text": "uint256", "parent": 605, "children": [], "start_point": {"row": 190, "column": 4}, "end_point": {"row": 190, "column": 11}}, {"id": 614, "type": "function_declarator", "text": "GetBlockTrust() const", "parent": 605, "children": [615, 616], "start_point": {"row": 190, "column": 12}, "end_point": {"row": 190, "column": 33}}, {"id": 615, "type": "identifier", "text": "GetBlockTrust", "parent": 614, "children": [], "start_point": {"row": 190, "column": 12}, "end_point": {"row": 190, "column": 25}}, {"id": 616, "type": "parameter_list", "text": "()", "parent": 614, "children": [], "start_point": {"row": 190, "column": 25}, "end_point": {"row": 190, "column": 27}}, {"id": 617, "type": "primitive_type", "text": "bool", "parent": 605, "children": [], "start_point": {"row": 191, "column": 4}, "end_point": {"row": 191, "column": 8}}, {"id": 618, "type": "function_declarator", "text": "IsInMainChain() const", "parent": 605, "children": [619, 620], "start_point": {"row": 191, "column": 9}, "end_point": {"row": 191, "column": 30}}, {"id": 619, "type": "identifier", "text": "IsInMainChain", "parent": 618, "children": [], "start_point": {"row": 191, "column": 9}, "end_point": {"row": 191, "column": 22}}, {"id": 620, "type": "parameter_list", "text": "()", "parent": 618, "children": [], "start_point": {"row": 191, "column": 22}, "end_point": {"row": 191, "column": 24}}, {"id": 621, "type": "primitive_type", "text": "bool", "parent": 605, "children": [], "start_point": {"row": 192, "column": 4}, "end_point": {"row": 192, "column": 8}}, {"id": 622, "type": "function_declarator", "text": "CheckIndex() const", "parent": 605, "children": [623, 624], "start_point": {"row": 192, "column": 9}, "end_point": {"row": 192, "column": 27}}, {"id": 623, "type": "identifier", "text": "CheckIndex", "parent": 622, "children": [], "start_point": {"row": 192, "column": 9}, "end_point": {"row": 192, "column": 19}}, {"id": 624, "type": "parameter_list", "text": "()", "parent": 622, "children": [], "start_point": {"row": 192, "column": 19}, "end_point": {"row": 192, "column": 21}}, {"id": 625, "type": "enum", "text": "enum", "parent": 605, "children": [], "start_point": {"row": 194, "column": 4}, "end_point": {"row": 194, "column": 8}}, {"id": 626, "type": "init_declarator", "text": "nMedianTimeSpan=11", "parent": 603, "children": [627, 628, 629], "start_point": {"row": 194, "column": 11}, "end_point": {"row": 194, "column": 29}}, {"id": 627, "type": "identifier", "text": "nMedianTimeSpan", "parent": 626, "children": [], "start_point": {"row": 194, "column": 11}, "end_point": {"row": 194, "column": 26}}, {"id": 628, "type": "=", "text": "=", "parent": 626, "children": [], "start_point": {"row": 194, "column": 26}, "end_point": {"row": 194, "column": 27}}, {"id": 629, "type": "number_literal", "text": "11", "parent": 626, "children": [], "start_point": {"row": 194, "column": 27}, "end_point": {"row": 194, "column": 29}}, {"id": 630, "type": "ERROR", "text": "int64 GetMedianTimePast() const;\n\n int64 GetMedianTime() const;", "parent": 598, "children": [631, 632, 637], "start_point": {"row": 196, "column": 4}, "end_point": {"row": 198, "column": 32}}, {"id": 631, "type": "type_identifier", "text": "int64", "parent": 630, "children": [], "start_point": {"row": 196, "column": 4}, "end_point": {"row": 196, "column": 9}}, {"id": 632, "type": "ERROR", "text": "GetMedianTimePast() const;\n\n int64", "parent": 630, "children": [633, 636], "start_point": {"row": 196, "column": 10}, "end_point": {"row": 198, "column": 9}}, {"id": 633, "type": "function_declarator", "text": "GetMedianTimePast() const", "parent": 632, "children": [634, 635], "start_point": {"row": 196, "column": 10}, "end_point": {"row": 196, "column": 35}}, {"id": 634, "type": "identifier", "text": "GetMedianTimePast", "parent": 633, "children": [], "start_point": {"row": 196, "column": 10}, "end_point": {"row": 196, "column": 27}}, {"id": 635, "type": "parameter_list", "text": "()", "parent": 633, "children": [], "start_point": {"row": 196, "column": 27}, "end_point": {"row": 196, "column": 29}}, {"id": 636, "type": "identifier", "text": "int64", "parent": 632, "children": [], "start_point": {"row": 198, "column": 4}, "end_point": {"row": 198, "column": 9}}, {"id": 637, "type": "function_declarator", "text": "GetMedianTime() const", "parent": 630, "children": [638, 639], "start_point": {"row": 198, "column": 10}, "end_point": {"row": 198, "column": 31}}, {"id": 638, "type": "identifier", "text": "GetMedianTime", "parent": 637, "children": [], "start_point": {"row": 198, "column": 10}, "end_point": {"row": 198, "column": 23}}, {"id": 639, "type": "parameter_list", "text": "()", "parent": 637, "children": [], "start_point": {"row": 198, "column": 23}, "end_point": {"row": 198, "column": 25}}, {"id": 640, "type": "declaration", "text": "bool IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck);", "parent": 598, "children": [641, 642], "start_point": {"row": 203, "column": 4}, "end_point": {"row": 204, "column": 79}}, {"id": 641, "type": "primitive_type", "text": "bool", "parent": 640, "children": [], "start_point": {"row": 203, "column": 4}, "end_point": {"row": 203, "column": 8}}, {"id": 642, "type": "function_declarator", "text": "IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck)", "parent": 640, "children": [643, 644], "start_point": {"row": 203, "column": 9}, "end_point": {"row": 204, "column": 78}}, {"id": 643, "type": "identifier", "text": "IsSuperMajority", "parent": 642, "children": [], "start_point": {"row": 203, "column": 9}, "end_point": {"row": 203, "column": 24}}, {"id": 644, "type": "parameter_list", "text": "(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck)", "parent": 642, "children": [645, 648, 653, 658], "start_point": {"row": 203, "column": 24}, "end_point": {"row": 204, "column": 78}}, {"id": 645, "type": "parameter_declaration", "text": "int minVersion", "parent": 644, "children": [646, 647], "start_point": {"row": 203, "column": 25}, "end_point": {"row": 203, "column": 39}}, {"id": 646, "type": "primitive_type", "text": "int", "parent": 645, "children": [], "start_point": {"row": 203, "column": 25}, "end_point": {"row": 203, "column": 28}}, {"id": 647, "type": "identifier", "text": "minVersion", "parent": 645, "children": [], "start_point": {"row": 203, "column": 29}, "end_point": {"row": 203, "column": 39}}, {"id": 648, "type": "parameter_declaration", "text": "const CBlockIndex* pstart", "parent": 644, "children": [649, 650], "start_point": {"row": 203, "column": 41}, "end_point": {"row": 203, "column": 66}}, {"id": 649, "type": "type_identifier", "text": "CBlockIndex", "parent": 648, "children": [], "start_point": {"row": 203, "column": 47}, "end_point": {"row": 203, "column": 58}}, {"id": 650, "type": "pointer_declarator", "text": "* pstart", "parent": 648, "children": [651, 652], "start_point": {"row": 203, "column": 58}, "end_point": {"row": 203, "column": 66}}, {"id": 651, "type": "*", "text": "*", "parent": 650, "children": [], "start_point": {"row": 203, "column": 58}, "end_point": {"row": 203, "column": 59}}, {"id": 652, "type": "identifier", "text": "pstart", "parent": 650, "children": [], "start_point": {"row": 203, "column": 60}, "end_point": {"row": 203, "column": 66}}, {"id": 653, "type": "parameter_declaration", "text": "unsigned int nRequired", "parent": 644, "children": [654, 657], "start_point": {"row": 204, "column": 32}, "end_point": {"row": 204, "column": 54}}, {"id": 654, "type": "sized_type_specifier", "text": "unsigned int", "parent": 653, "children": [655, 656], "start_point": {"row": 204, "column": 32}, "end_point": {"row": 204, "column": 44}}, {"id": 655, "type": "unsigned", "text": "unsigned", "parent": 654, "children": [], "start_point": {"row": 204, "column": 32}, "end_point": {"row": 204, "column": 40}}, {"id": 656, "type": "primitive_type", "text": "int", "parent": 654, "children": [], "start_point": {"row": 204, "column": 41}, "end_point": {"row": 204, "column": 44}}, {"id": 657, "type": "identifier", "text": "nRequired", "parent": 653, "children": [], "start_point": {"row": 204, "column": 45}, "end_point": {"row": 204, "column": 54}}, {"id": 658, "type": "parameter_declaration", "text": "unsigned int nToCheck", "parent": 644, "children": [659, 662], "start_point": {"row": 204, "column": 56}, "end_point": {"row": 204, "column": 77}}, {"id": 659, "type": "sized_type_specifier", "text": "unsigned int", "parent": 658, "children": [660, 661], "start_point": {"row": 204, "column": 56}, "end_point": {"row": 204, "column": 68}}, {"id": 660, "type": "unsigned", "text": "unsigned", "parent": 659, "children": [], "start_point": {"row": 204, "column": 56}, "end_point": {"row": 204, "column": 64}}, {"id": 661, "type": "primitive_type", "text": "int", "parent": 659, "children": [], "start_point": {"row": 204, "column": 65}, "end_point": {"row": 204, "column": 68}}, {"id": 662, "type": "identifier", "text": "nToCheck", "parent": 658, "children": [], "start_point": {"row": 204, "column": 69}, "end_point": {"row": 204, "column": 77}}, {"id": 663, "type": "ERROR", "text": "bool IsProofOfWork() const;\n bool IsProofOfStake() const;", "parent": 598, "children": [664, 665, 668, 669], "start_point": {"row": 207, "column": 4}, "end_point": {"row": 208, "column": 32}}, {"id": 664, "type": "primitive_type", "text": "bool", "parent": 663, "children": [], "start_point": {"row": 207, "column": 4}, "end_point": {"row": 207, "column": 8}}, {"id": 665, "type": "function_declarator", "text": "IsProofOfWork() const", "parent": 663, "children": [666, 667], "start_point": {"row": 207, "column": 9}, "end_point": {"row": 207, "column": 30}}, {"id": 666, "type": "identifier", "text": "IsProofOfWork", "parent": 665, "children": [], "start_point": {"row": 207, "column": 9}, "end_point": {"row": 207, "column": 22}}, {"id": 667, "type": "parameter_list", "text": "()", "parent": 665, "children": [], "start_point": {"row": 207, "column": 22}, "end_point": {"row": 207, "column": 24}}, {"id": 668, "type": "primitive_type", "text": "bool", "parent": 663, "children": [], "start_point": {"row": 208, "column": 4}, "end_point": {"row": 208, "column": 8}}, {"id": 669, "type": "function_declarator", "text": "IsProofOfStake() const", "parent": 663, "children": [670, 671], "start_point": {"row": 208, "column": 9}, "end_point": {"row": 208, "column": 31}}, {"id": 670, "type": "identifier", "text": "IsProofOfStake", "parent": 669, "children": [], "start_point": {"row": 208, "column": 9}, "end_point": {"row": 208, "column": 23}}, {"id": 671, "type": "parameter_list", "text": "()", "parent": 669, "children": [], "start_point": {"row": 208, "column": 23}, "end_point": {"row": 208, "column": 25}}, {"id": 672, "type": "declaration", "text": "void SetProofOfStake();", "parent": 598, "children": [673, 674], "start_point": {"row": 209, "column": 4}, "end_point": {"row": 209, "column": 27}}, {"id": 673, "type": "primitive_type", "text": "void", "parent": 672, "children": [], "start_point": {"row": 209, "column": 4}, "end_point": {"row": 209, "column": 8}}, {"id": 674, "type": "function_declarator", "text": "SetProofOfStake()", "parent": 672, "children": [675, 676], "start_point": {"row": 209, "column": 9}, "end_point": {"row": 209, "column": 26}}, {"id": 675, "type": "identifier", "text": "SetProofOfStake", "parent": 674, "children": [], "start_point": {"row": 209, "column": 9}, "end_point": {"row": 209, "column": 24}}, {"id": 676, "type": "parameter_list", "text": "()", "parent": 674, "children": [], "start_point": {"row": 209, "column": 24}, "end_point": {"row": 209, "column": 26}}, {"id": 677, "type": "ERROR", "text": "unsigned int GetStakeEntropyBit() const;", "parent": 598, "children": [678, 681], "start_point": {"row": 210, "column": 4}, "end_point": {"row": 210, "column": 44}}, {"id": 678, "type": "sized_type_specifier", "text": "unsigned int", "parent": 677, "children": [679, 680], "start_point": {"row": 210, "column": 4}, "end_point": {"row": 210, "column": 16}}, {"id": 679, "type": "unsigned", "text": "unsigned", "parent": 678, "children": [], "start_point": {"row": 210, "column": 4}, "end_point": {"row": 210, "column": 12}}, {"id": 680, "type": "primitive_type", "text": "int", "parent": 678, "children": [], "start_point": {"row": 210, "column": 13}, "end_point": {"row": 210, "column": 16}}, {"id": 681, "type": "function_declarator", "text": "GetStakeEntropyBit() const", "parent": 677, "children": [682, 683], "start_point": {"row": 210, "column": 17}, "end_point": {"row": 210, "column": 43}}, {"id": 682, "type": "identifier", "text": "GetStakeEntropyBit", "parent": 681, "children": [], "start_point": {"row": 210, "column": 17}, "end_point": {"row": 210, "column": 35}}, {"id": 683, "type": "parameter_list", "text": "()", "parent": 681, "children": [], "start_point": {"row": 210, "column": 35}, "end_point": {"row": 210, "column": 37}}, {"id": 684, "type": "declaration", "text": "bool SetStakeEntropyBit(unsigned int nEntropyBit);", "parent": 598, "children": [685, 686], "start_point": {"row": 211, "column": 4}, "end_point": {"row": 211, "column": 54}}, {"id": 685, "type": "primitive_type", "text": "bool", "parent": 684, "children": [], "start_point": {"row": 211, "column": 4}, "end_point": {"row": 211, "column": 8}}, {"id": 686, "type": "function_declarator", "text": "SetStakeEntropyBit(unsigned int nEntropyBit)", "parent": 684, "children": [687, 688], "start_point": {"row": 211, "column": 9}, "end_point": {"row": 211, "column": 53}}, {"id": 687, "type": "identifier", "text": "SetStakeEntropyBit", "parent": 686, "children": [], "start_point": {"row": 211, "column": 9}, "end_point": {"row": 211, "column": 27}}, {"id": 688, "type": "parameter_list", "text": "(unsigned int nEntropyBit)", "parent": 686, "children": [689], "start_point": {"row": 211, "column": 27}, "end_point": {"row": 211, "column": 53}}, {"id": 689, "type": "parameter_declaration", "text": "unsigned int nEntropyBit", "parent": 688, "children": [690, 693], "start_point": {"row": 211, "column": 28}, "end_point": {"row": 211, "column": 52}}, {"id": 690, "type": "sized_type_specifier", "text": "unsigned int", "parent": 689, "children": [691, 692], "start_point": {"row": 211, "column": 28}, "end_point": {"row": 211, "column": 40}}, {"id": 691, "type": "unsigned", "text": "unsigned", "parent": 690, "children": [], "start_point": {"row": 211, "column": 28}, "end_point": {"row": 211, "column": 36}}, {"id": 692, "type": "primitive_type", "text": "int", "parent": 690, "children": [], "start_point": {"row": 211, "column": 37}, "end_point": {"row": 211, "column": 40}}, {"id": 693, "type": "identifier", "text": "nEntropyBit", "parent": 689, "children": [], "start_point": {"row": 211, "column": 41}, "end_point": {"row": 211, "column": 52}}, {"id": 694, "type": "ERROR", "text": "bool GeneratedStakeModifier() const;", "parent": 598, "children": [695, 696], "start_point": {"row": 212, "column": 4}, "end_point": {"row": 212, "column": 40}}, {"id": 695, "type": "primitive_type", "text": "bool", "parent": 694, "children": [], "start_point": {"row": 212, "column": 4}, "end_point": {"row": 212, "column": 8}}, {"id": 696, "type": "function_declarator", "text": "GeneratedStakeModifier() const", "parent": 694, "children": [697, 698], "start_point": {"row": 212, "column": 9}, "end_point": {"row": 212, "column": 39}}, {"id": 697, "type": "identifier", "text": "GeneratedStakeModifier", "parent": 696, "children": [], "start_point": {"row": 212, "column": 9}, "end_point": {"row": 212, "column": 31}}, {"id": 698, "type": "parameter_list", "text": "()", "parent": 696, "children": [], "start_point": {"row": 212, "column": 31}, "end_point": {"row": 212, "column": 33}}, {"id": 699, "type": "declaration", "text": "void SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier);", "parent": 598, "children": [700, 701], "start_point": {"row": 213, "column": 4}, "end_point": {"row": 213, "column": 74}}, {"id": 700, "type": "primitive_type", "text": "void", "parent": 699, "children": [], "start_point": {"row": 213, "column": 4}, "end_point": {"row": 213, "column": 8}}, {"id": 701, "type": "function_declarator", "text": "SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier)", "parent": 699, "children": [702, 703], "start_point": {"row": 213, "column": 9}, "end_point": {"row": 213, "column": 73}}, {"id": 702, "type": "identifier", "text": "SetStakeModifier", "parent": 701, "children": [], "start_point": {"row": 213, "column": 9}, "end_point": {"row": 213, "column": 25}}, {"id": 703, "type": "parameter_list", "text": "(uint64 nModifier, bool fGeneratedStakeModifier)", "parent": 701, "children": [704, 707], "start_point": {"row": 213, "column": 25}, "end_point": {"row": 213, "column": 73}}, {"id": 704, "type": "parameter_declaration", "text": "uint64 nModifier", "parent": 703, "children": [705, 706], "start_point": {"row": 213, "column": 26}, "end_point": {"row": 213, "column": 42}}, {"id": 705, "type": "type_identifier", "text": "uint64", "parent": 704, "children": [], "start_point": {"row": 213, "column": 26}, "end_point": {"row": 213, "column": 32}}, {"id": 706, "type": "identifier", "text": "nModifier", "parent": 704, "children": [], "start_point": {"row": 213, "column": 33}, "end_point": {"row": 213, "column": 42}}, {"id": 707, "type": "parameter_declaration", "text": "bool fGeneratedStakeModifier", "parent": 703, "children": [708, 709], "start_point": {"row": 213, "column": 44}, "end_point": {"row": 213, "column": 72}}, {"id": 708, "type": "primitive_type", "text": "bool", "parent": 707, "children": [], "start_point": {"row": 213, "column": 44}, "end_point": {"row": 213, "column": 48}}, {"id": 709, "type": "identifier", "text": "fGeneratedStakeModifier", "parent": 707, "children": [], "start_point": {"row": 213, "column": 49}, "end_point": {"row": 213, "column": 72}}, {"id": 710, "type": "declaration", "text": "std::string ToString() const;\n void print() const;\n};\n\n\n\n/** Used to marshal pointers into hashes for db storage. */\nclass CDiskBlockIndex : public CBlockIndex\n{\npublic:\n uint256 hashPrev;", "parent": 598, "children": [711, 712, 721, 725], "start_point": {"row": 214, "column": 4}, "end_point": {"row": 224, "column": 21}}, {"id": 711, "type": "type_identifier", "text": "std", "parent": 710, "children": [], "start_point": {"row": 214, "column": 4}, "end_point": {"row": 214, "column": 7}}, {"id": 712, "type": "ERROR", "text": "::string ToString() const;\n void print() const;\n};", "parent": 710, "children": [713, 714, 717, 718], "start_point": {"row": 214, "column": 7}, "end_point": {"row": 216, "column": 2}}, {"id": 713, "type": "identifier", "text": "string", "parent": 712, "children": [], "start_point": {"row": 214, "column": 9}, "end_point": {"row": 214, "column": 15}}, {"id": 714, "type": "function_declarator", "text": "ToString() const", "parent": 712, "children": [715, 716], "start_point": {"row": 214, "column": 16}, "end_point": {"row": 214, "column": 32}}, {"id": 715, "type": "identifier", "text": "ToString", "parent": 714, "children": [], "start_point": {"row": 214, "column": 16}, "end_point": {"row": 214, "column": 24}}, {"id": 716, "type": "parameter_list", "text": "()", "parent": 714, "children": [], "start_point": {"row": 214, "column": 24}, "end_point": {"row": 214, "column": 26}}, {"id": 717, "type": "primitive_type", "text": "void", "parent": 712, "children": [], "start_point": {"row": 215, "column": 4}, "end_point": {"row": 215, "column": 8}}, {"id": 718, "type": "function_declarator", "text": "print() const", "parent": 712, "children": [719, 720], "start_point": {"row": 215, "column": 9}, "end_point": {"row": 215, "column": 22}}, {"id": 719, "type": "identifier", "text": "print", "parent": 718, "children": [], "start_point": {"row": 215, "column": 9}, "end_point": {"row": 215, "column": 14}}, {"id": 720, "type": "parameter_list", "text": "()", "parent": 718, "children": [], "start_point": {"row": 215, "column": 14}, "end_point": {"row": 215, "column": 16}}, {"id": 721, "type": "ERROR", "text": "class CDiskBlockIndex : public CBlockIndex\n{\npublic:\n uint256", "parent": 710, "children": [722, 723, 724], "start_point": {"row": 221, "column": 0}, "end_point": {"row": 224, "column": 11}}, {"id": 722, "type": "identifier", "text": "CDiskBlockIndex", "parent": 721, "children": [], "start_point": {"row": 221, "column": 6}, "end_point": {"row": 221, "column": 21}}, {"id": 723, "type": "identifier", "text": "CBlockIndex", "parent": 721, "children": [], "start_point": {"row": 221, "column": 31}, "end_point": {"row": 221, "column": 42}}, {"id": 724, "type": "identifier", "text": "uint256", "parent": 721, "children": [], "start_point": {"row": 224, "column": 4}, "end_point": {"row": 224, "column": 11}}, {"id": 725, "type": "identifier", "text": "hashPrev", "parent": 710, "children": [], "start_point": {"row": 224, "column": 12}, "end_point": {"row": 224, "column": 20}}, {"id": 726, "type": "declaration", "text": "uint256 hashNext;", "parent": 598, "children": [727, 728], "start_point": {"row": 225, "column": 4}, "end_point": {"row": 225, "column": 21}}, {"id": 727, "type": "type_identifier", "text": "uint256", "parent": 726, "children": [], "start_point": {"row": 225, "column": 4}, "end_point": {"row": 225, "column": 11}}, {"id": 728, "type": "identifier", "text": "hashNext", "parent": 726, "children": [], "start_point": {"row": 225, "column": 12}, "end_point": {"row": 225, "column": 20}}, {"id": 729, "type": "ERROR", "text": "CDiskBlockIndex()", "parent": 598, "children": [730], "start_point": {"row": 227, "column": 4}, "end_point": {"row": 227, "column": 21}}, {"id": 730, "type": "identifier", "text": "CDiskBlockIndex", "parent": 729, "children": [], "start_point": {"row": 227, "column": 4}, "end_point": {"row": 227, "column": 19}}, {"id": 731, "type": "assignment_expression", "text": "hashPrev = 0", "parent": 598, "children": [732, 733, 734], "start_point": {"row": 229, "column": 8}, "end_point": {"row": 229, "column": 20}}, {"id": 732, "type": "identifier", "text": "hashPrev", "parent": 731, "children": [], "start_point": {"row": 229, "column": 8}, "end_point": {"row": 229, "column": 16}}, {"id": 733, "type": "=", "text": "=", "parent": 731, "children": [], "start_point": {"row": 229, "column": 17}, "end_point": {"row": 229, "column": 18}}, {"id": 734, "type": "number_literal", "text": "0", "parent": 731, "children": [], "start_point": {"row": 229, "column": 19}, "end_point": {"row": 229, "column": 20}}, {"id": 735, "type": "assignment_expression", "text": "hashNext = 0", "parent": 598, "children": [736, 737, 738], "start_point": {"row": 230, "column": 8}, "end_point": {"row": 230, "column": 20}}, {"id": 736, "type": "identifier", "text": "hashNext", "parent": 735, "children": [], "start_point": {"row": 230, "column": 8}, "end_point": {"row": 230, "column": 16}}, {"id": 737, "type": "=", "text": "=", "parent": 735, "children": [], "start_point": {"row": 230, "column": 17}, "end_point": {"row": 230, "column": 18}}, {"id": 738, "type": "number_literal", "text": "0", "parent": 735, "children": [], "start_point": {"row": 230, "column": 19}, "end_point": {"row": 230, "column": 20}}, {"id": 739, "type": "function_definition", "text": "explicit CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex)\n {\n hashPrev = (pprev ? pprev->GetBlockHash() : 0);\n hashNext = (pnext ? pnext->GetBlockHash() : 0);\n }", "parent": 384, "children": [740, 741], "start_point": {"row": 233, "column": 4}, "end_point": {"row": 237, "column": 5}}, {"id": 740, "type": "type_identifier", "text": "explicit", "parent": 739, "children": [], "start_point": {"row": 233, "column": 4}, "end_point": {"row": 233, "column": 12}}, {"id": 741, "type": "function_declarator", "text": "CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex)", "parent": 739, "children": [742, 743, 749], "start_point": {"row": 233, "column": 13}, "end_point": {"row": 233, "column": 72}}, {"id": 742, "type": "identifier", "text": "CDiskBlockIndex", "parent": 741, "children": [], "start_point": {"row": 233, "column": 13}, "end_point": {"row": 233, "column": 28}}, {"id": 743, "type": "parameter_list", "text": "(CBlockIndex* pindex)", "parent": 741, "children": [744], "start_point": {"row": 233, "column": 28}, "end_point": {"row": 233, "column": 49}}, {"id": 744, "type": "parameter_declaration", "text": "CBlockIndex* pindex", "parent": 743, "children": [745, 746], "start_point": {"row": 233, "column": 29}, "end_point": {"row": 233, "column": 48}}, {"id": 745, "type": "type_identifier", "text": "CBlockIndex", "parent": 744, "children": [], "start_point": {"row": 233, "column": 29}, "end_point": {"row": 233, "column": 40}}, {"id": 746, "type": "pointer_declarator", "text": "* pindex", "parent": 744, "children": [747, 748], "start_point": {"row": 233, "column": 40}, "end_point": {"row": 233, "column": 48}}, {"id": 747, "type": "*", "text": "*", "parent": 746, "children": [], "start_point": {"row": 233, "column": 40}, "end_point": {"row": 233, "column": 41}}, {"id": 748, "type": "identifier", "text": "pindex", "parent": 746, "children": [], "start_point": {"row": 233, "column": 42}, "end_point": {"row": 233, "column": 48}}, {"id": 749, "type": "call_expression", "text": "CBlockIndex(*pindex)", "parent": 741, "children": [750, 751], "start_point": {"row": 233, "column": 52}, "end_point": {"row": 233, "column": 72}}, {"id": 750, "type": "identifier", "text": "CBlockIndex", "parent": 749, "children": [], "start_point": {"row": 233, "column": 52}, "end_point": {"row": 233, "column": 63}}, {"id": 751, "type": "argument_list", "text": "(*pindex)", "parent": 749, "children": [752, 754], "start_point": {"row": 233, "column": 63}, "end_point": {"row": 233, "column": 72}}, {"id": 752, "type": "ERROR", "text": "*", "parent": 751, "children": [753], "start_point": {"row": 233, "column": 64}, "end_point": {"row": 233, "column": 65}}, {"id": 753, "type": "*", "text": "*", "parent": 752, "children": [], "start_point": {"row": 233, "column": 64}, "end_point": {"row": 233, "column": 65}}, {"id": 754, "type": "identifier", "text": "pindex", "parent": 751, "children": [], "start_point": {"row": 233, "column": 65}, "end_point": {"row": 233, "column": 71}}, {"id": 755, "type": "assignment_expression", "text": "hashPrev = (pprev ? pprev->GetBlockHash() : 0)", "parent": 739, "children": [756, 757, 758], "start_point": {"row": 235, "column": 8}, "end_point": {"row": 235, "column": 54}}, {"id": 756, "type": "identifier", "text": "hashPrev", "parent": 755, "children": [], "start_point": {"row": 235, "column": 8}, "end_point": {"row": 235, "column": 16}}, {"id": 757, "type": "=", "text": "=", "parent": 755, "children": [], "start_point": {"row": 235, "column": 17}, "end_point": {"row": 235, "column": 18}}, {"id": 758, "type": "parenthesized_expression", "text": "(pprev ? pprev->GetBlockHash() : 0)", "parent": 755, "children": [759], "start_point": {"row": 235, "column": 19}, "end_point": {"row": 235, "column": 54}}, {"id": 759, "type": "conditional_expression", "text": "pprev ? pprev->GetBlockHash() : 0", "parent": 758, "children": [760, 761, 762, 767], "start_point": {"row": 235, "column": 20}, "end_point": {"row": 235, "column": 53}}, {"id": 760, "type": "identifier", "text": "pprev", "parent": 759, "children": [], "start_point": {"row": 235, "column": 20}, "end_point": {"row": 235, "column": 25}}, {"id": 761, "type": "?", "text": "?", "parent": 759, "children": [], "start_point": {"row": 235, "column": 26}, "end_point": {"row": 235, "column": 27}}, {"id": 762, "type": "call_expression", "text": "pprev->GetBlockHash()", "parent": 759, "children": [763, 766], "start_point": {"row": 235, "column": 28}, "end_point": {"row": 235, "column": 49}}, {"id": 763, "type": "field_expression", "text": "pprev->GetBlockHash", "parent": 762, "children": [764, 765], "start_point": {"row": 235, "column": 28}, "end_point": {"row": 235, "column": 47}}, {"id": 764, "type": "identifier", "text": "pprev", "parent": 763, "children": [], "start_point": {"row": 235, "column": 28}, "end_point": {"row": 235, "column": 33}}, {"id": 765, "type": "field_identifier", "text": "GetBlockHash", "parent": 763, "children": [], "start_point": {"row": 235, "column": 35}, "end_point": {"row": 235, "column": 47}}, {"id": 766, "type": "argument_list", "text": "()", "parent": 762, "children": [], "start_point": {"row": 235, "column": 47}, "end_point": {"row": 235, "column": 49}}, {"id": 767, "type": "number_literal", "text": "0", "parent": 759, "children": [], "start_point": {"row": 235, "column": 52}, "end_point": {"row": 235, "column": 53}}, {"id": 768, "type": "assignment_expression", "text": "hashNext = (pnext ? pnext->GetBlockHash() : 0)", "parent": 739, "children": [769, 770, 771], "start_point": {"row": 236, "column": 8}, "end_point": {"row": 236, "column": 54}}, {"id": 769, "type": "identifier", "text": "hashNext", "parent": 768, "children": [], "start_point": {"row": 236, "column": 8}, "end_point": {"row": 236, "column": 16}}, {"id": 770, "type": "=", "text": "=", "parent": 768, "children": [], "start_point": {"row": 236, "column": 17}, "end_point": {"row": 236, "column": 18}}, {"id": 771, "type": "parenthesized_expression", "text": "(pnext ? pnext->GetBlockHash() : 0)", "parent": 768, "children": [772], "start_point": {"row": 236, "column": 19}, "end_point": {"row": 236, "column": 54}}, {"id": 772, "type": "conditional_expression", "text": "pnext ? pnext->GetBlockHash() : 0", "parent": 771, "children": [773, 774, 775, 780], "start_point": {"row": 236, "column": 20}, "end_point": {"row": 236, "column": 53}}, {"id": 773, "type": "identifier", "text": "pnext", "parent": 772, "children": [], "start_point": {"row": 236, "column": 20}, "end_point": {"row": 236, "column": 25}}, {"id": 774, "type": "?", "text": "?", "parent": 772, "children": [], "start_point": {"row": 236, "column": 26}, "end_point": {"row": 236, "column": 27}}, {"id": 775, "type": "call_expression", "text": "pnext->GetBlockHash()", "parent": 772, "children": [776, 779], "start_point": {"row": 236, "column": 28}, "end_point": {"row": 236, "column": 49}}, {"id": 776, "type": "field_expression", "text": "pnext->GetBlockHash", "parent": 775, "children": [777, 778], "start_point": {"row": 236, "column": 28}, "end_point": {"row": 236, "column": 47}}, {"id": 777, "type": "identifier", "text": "pnext", "parent": 776, "children": [], "start_point": {"row": 236, "column": 28}, "end_point": {"row": 236, "column": 33}}, {"id": 778, "type": "field_identifier", "text": "GetBlockHash", "parent": 776, "children": [], "start_point": {"row": 236, "column": 35}, "end_point": {"row": 236, "column": 47}}, {"id": 779, "type": "argument_list", "text": "()", "parent": 775, "children": [], "start_point": {"row": 236, "column": 47}, "end_point": {"row": 236, "column": 49}}, {"id": 780, "type": "number_literal", "text": "0", "parent": 772, "children": [], "start_point": {"row": 236, "column": 52}, "end_point": {"row": 236, "column": 53}}, {"id": 781, "type": "call_expression", "text": "IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);\n READWRITE(nStakeModifier)", "parent": 384, "children": [782, 783], "start_point": {"row": 239, "column": 4}, "end_point": {"row": 251, "column": 33}}, {"id": 782, "type": "identifier", "text": "IMPLEMENT_SERIALIZE", "parent": 781, "children": [], "start_point": {"row": 239, "column": 4}, "end_point": {"row": 239, "column": 23}}, {"id": 783, "type": "argument_list", "text": "(\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);\n READWRITE(nStakeModifier)", "parent": 781, "children": [784, 825], "start_point": {"row": 240, "column": 4}, "end_point": {"row": 251, "column": 33}}, {"id": 784, "type": "ERROR", "text": "if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);", "parent": 783, "children": [785, 793, 797, 801, 805, 809, 813, 817, 821], "start_point": {"row": 241, "column": 8}, "end_point": {"row": 250, "column": 26}}, {"id": 785, "type": "call_expression", "text": "if (!(nType & SER_GETHASH))", "parent": 784, "children": [786], "start_point": {"row": 241, "column": 8}, "end_point": {"row": 241, "column": 35}}, {"id": 786, "type": "argument_list", "text": "(!(nType & SER_GETHASH))", "parent": 785, "children": [787], "start_point": {"row": 241, "column": 11}, "end_point": {"row": 241, "column": 35}}, {"id": 787, "type": "unary_expression", "text": "!(nType & SER_GETHASH)", "parent": 786, "children": [788, 789], "start_point": {"row": 241, "column": 12}, "end_point": {"row": 241, "column": 34}}, {"id": 788, "type": "!", "text": "!", "parent": 787, "children": [], "start_point": {"row": 241, "column": 12}, "end_point": {"row": 241, "column": 13}}, {"id": 789, "type": "parenthesized_expression", "text": "(nType & SER_GETHASH)", "parent": 787, "children": [790], "start_point": {"row": 241, "column": 13}, "end_point": {"row": 241, "column": 34}}, {"id": 790, "type": "binary_expression", "text": "nType & SER_GETHASH", "parent": 789, "children": [791, 792], "start_point": {"row": 241, "column": 14}, "end_point": {"row": 241, "column": 33}}, {"id": 791, "type": "identifier", "text": "nType", "parent": 790, "children": [], "start_point": {"row": 241, "column": 14}, "end_point": {"row": 241, "column": 19}}, {"id": 792, "type": "identifier", "text": "SER_GETHASH", "parent": 790, "children": [], "start_point": {"row": 241, "column": 22}, "end_point": {"row": 241, "column": 33}}, {"id": 793, "type": "call_expression", "text": "READWRITE(nVersion)", "parent": 784, "children": [794, 795], "start_point": {"row": 242, "column": 12}, "end_point": {"row": 242, "column": 31}}, {"id": 794, "type": "identifier", "text": "READWRITE", "parent": 793, "children": [], "start_point": {"row": 242, "column": 12}, "end_point": {"row": 242, "column": 21}}, {"id": 795, "type": "argument_list", "text": "(nVersion)", "parent": 793, "children": [796], "start_point": {"row": 242, "column": 21}, "end_point": {"row": 242, "column": 31}}, {"id": 796, "type": "identifier", "text": "nVersion", "parent": 795, "children": [], "start_point": {"row": 242, "column": 22}, "end_point": {"row": 242, "column": 30}}, {"id": 797, "type": "call_expression", "text": "READWRITE(hashNext)", "parent": 784, "children": [798, 799], "start_point": {"row": 244, "column": 8}, "end_point": {"row": 244, "column": 27}}, {"id": 798, "type": "identifier", "text": "READWRITE", "parent": 797, "children": [], "start_point": {"row": 244, "column": 8}, "end_point": {"row": 244, "column": 17}}, {"id": 799, "type": "argument_list", "text": "(hashNext)", "parent": 797, "children": [800], "start_point": {"row": 244, "column": 17}, "end_point": {"row": 244, "column": 27}}, {"id": 800, "type": "identifier", "text": "hashNext", "parent": 799, "children": [], "start_point": {"row": 244, "column": 18}, "end_point": {"row": 244, "column": 26}}, {"id": 801, "type": "call_expression", "text": "READWRITE(nFile)", "parent": 784, "children": [802, 803], "start_point": {"row": 245, "column": 8}, "end_point": {"row": 245, "column": 24}}, {"id": 802, "type": "identifier", "text": "READWRITE", "parent": 801, "children": [], "start_point": {"row": 245, "column": 8}, "end_point": {"row": 245, "column": 17}}, {"id": 803, "type": "argument_list", "text": "(nFile)", "parent": 801, "children": [804], "start_point": {"row": 245, "column": 17}, "end_point": {"row": 245, "column": 24}}, {"id": 804, "type": "identifier", "text": "nFile", "parent": 803, "children": [], "start_point": {"row": 245, "column": 18}, "end_point": {"row": 245, "column": 23}}, {"id": 805, "type": "call_expression", "text": "READWRITE(nBlockPos)", "parent": 784, "children": [806, 807], "start_point": {"row": 246, "column": 8}, "end_point": {"row": 246, "column": 28}}, {"id": 806, "type": "identifier", "text": "READWRITE", "parent": 805, "children": [], "start_point": {"row": 246, "column": 8}, "end_point": {"row": 246, "column": 17}}, {"id": 807, "type": "argument_list", "text": "(nBlockPos)", "parent": 805, "children": [808], "start_point": {"row": 246, "column": 17}, "end_point": {"row": 246, "column": 28}}, {"id": 808, "type": "identifier", "text": "nBlockPos", "parent": 807, "children": [], "start_point": {"row": 246, "column": 18}, "end_point": {"row": 246, "column": 27}}, {"id": 809, "type": "call_expression", "text": "READWRITE(nHeight)", "parent": 784, "children": [810, 811], "start_point": {"row": 247, "column": 8}, "end_point": {"row": 247, "column": 26}}, {"id": 810, "type": "identifier", "text": "READWRITE", "parent": 809, "children": [], "start_point": {"row": 247, "column": 8}, "end_point": {"row": 247, "column": 17}}, {"id": 811, "type": "argument_list", "text": "(nHeight)", "parent": 809, "children": [812], "start_point": {"row": 247, "column": 17}, "end_point": {"row": 247, "column": 26}}, {"id": 812, "type": "identifier", "text": "nHeight", "parent": 811, "children": [], "start_point": {"row": 247, "column": 18}, "end_point": {"row": 247, "column": 25}}, {"id": 813, "type": "call_expression", "text": "READWRITE(nMint)", "parent": 784, "children": [814, 815], "start_point": {"row": 248, "column": 8}, "end_point": {"row": 248, "column": 24}}, {"id": 814, "type": "identifier", "text": "READWRITE", "parent": 813, "children": [], "start_point": {"row": 248, "column": 8}, "end_point": {"row": 248, "column": 17}}, {"id": 815, "type": "argument_list", "text": "(nMint)", "parent": 813, "children": [816], "start_point": {"row": 248, "column": 17}, "end_point": {"row": 248, "column": 24}}, {"id": 816, "type": "identifier", "text": "nMint", "parent": 815, "children": [], "start_point": {"row": 248, "column": 18}, "end_point": {"row": 248, "column": 23}}, {"id": 817, "type": "call_expression", "text": "READWRITE(nMoneySupply)", "parent": 784, "children": [818, 819], "start_point": {"row": 249, "column": 8}, "end_point": {"row": 249, "column": 31}}, {"id": 818, "type": "identifier", "text": "READWRITE", "parent": 817, "children": [], "start_point": {"row": 249, "column": 8}, "end_point": {"row": 249, "column": 17}}, {"id": 819, "type": "argument_list", "text": "(nMoneySupply)", "parent": 817, "children": [820], "start_point": {"row": 249, "column": 17}, "end_point": {"row": 249, "column": 31}}, {"id": 820, "type": "identifier", "text": "nMoneySupply", "parent": 819, "children": [], "start_point": {"row": 249, "column": 18}, "end_point": {"row": 249, "column": 30}}, {"id": 821, "type": "call_expression", "text": "READWRITE(nFlags)", "parent": 784, "children": [822, 823], "start_point": {"row": 250, "column": 8}, "end_point": {"row": 250, "column": 25}}, {"id": 822, "type": "identifier", "text": "READWRITE", "parent": 821, "children": [], "start_point": {"row": 250, "column": 8}, "end_point": {"row": 250, "column": 17}}, {"id": 823, "type": "argument_list", "text": "(nFlags)", "parent": 821, "children": [824], "start_point": {"row": 250, "column": 17}, "end_point": {"row": 250, "column": 25}}, {"id": 824, "type": "identifier", "text": "nFlags", "parent": 823, "children": [], "start_point": {"row": 250, "column": 18}, "end_point": {"row": 250, "column": 24}}, {"id": 825, "type": "call_expression", "text": "READWRITE(nStakeModifier)", "parent": 783, "children": [826, 827], "start_point": {"row": 251, "column": 8}, "end_point": {"row": 251, "column": 33}}, {"id": 826, "type": "identifier", "text": "READWRITE", "parent": 825, "children": [], "start_point": {"row": 251, "column": 8}, "end_point": {"row": 251, "column": 17}}, {"id": 827, "type": "argument_list", "text": "(nStakeModifier)", "parent": 825, "children": [828], "start_point": {"row": 251, "column": 17}, "end_point": {"row": 251, "column": 33}}, {"id": 828, "type": "identifier", "text": "nStakeModifier", "parent": 827, "children": [], "start_point": {"row": 251, "column": 18}, "end_point": {"row": 251, "column": 32}}, {"id": 829, "type": "if_statement", "text": "if (IsProofOfStake())\n {\n READWRITE(prevoutStake);\n READWRITE(nStakeTime);\n READWRITE(hashProofOfStake);\n }\n else if (fRead)\n {\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }", "parent": 384, "children": [830, 846], "start_point": {"row": 252, "column": 8}, "end_point": {"row": 263, "column": 9}}, {"id": 830, "type": "parenthesized_expression", "text": "(IsProofOfStake())", "parent": 829, "children": [831], "start_point": {"row": 252, "column": 11}, "end_point": {"row": 252, "column": 29}}, {"id": 831, "type": "call_expression", "text": "IsProofOfStake()", "parent": 830, "children": [832, 833], "start_point": {"row": 252, "column": 12}, "end_point": {"row": 252, "column": 28}}, {"id": 832, "type": "identifier", "text": "IsProofOfStake", "parent": 831, "children": [], "start_point": {"row": 252, "column": 12}, "end_point": {"row": 252, "column": 26}}, {"id": 833, "type": "argument_list", "text": "()", "parent": 831, "children": [], "start_point": {"row": 252, "column": 26}, "end_point": {"row": 252, "column": 28}}, {"id": 834, "type": "call_expression", "text": "READWRITE(prevoutStake)", "parent": 829, "children": [835, 836], "start_point": {"row": 254, "column": 12}, "end_point": {"row": 254, "column": 35}}, {"id": 835, "type": "identifier", "text": "READWRITE", "parent": 834, "children": [], "start_point": {"row": 254, "column": 12}, "end_point": {"row": 254, "column": 21}}, {"id": 836, "type": "argument_list", "text": "(prevoutStake)", "parent": 834, "children": [837], "start_point": {"row": 254, "column": 21}, "end_point": {"row": 254, "column": 35}}, {"id": 837, "type": "identifier", "text": "prevoutStake", "parent": 836, "children": [], "start_point": {"row": 254, "column": 22}, "end_point": {"row": 254, "column": 34}}, {"id": 838, "type": "call_expression", "text": "READWRITE(nStakeTime)", "parent": 829, "children": [839, 840], "start_point": {"row": 255, "column": 12}, "end_point": {"row": 255, "column": 33}}, {"id": 839, "type": "identifier", "text": "READWRITE", "parent": 838, "children": [], "start_point": {"row": 255, "column": 12}, "end_point": {"row": 255, "column": 21}}, {"id": 840, "type": "argument_list", "text": "(nStakeTime)", "parent": 838, "children": [841], "start_point": {"row": 255, "column": 21}, "end_point": {"row": 255, "column": 33}}, {"id": 841, "type": "identifier", "text": "nStakeTime", "parent": 840, "children": [], "start_point": {"row": 255, "column": 22}, "end_point": {"row": 255, "column": 32}}, {"id": 842, "type": "call_expression", "text": "READWRITE(hashProofOfStake)", "parent": 829, "children": [843, 844], "start_point": {"row": 256, "column": 12}, "end_point": {"row": 256, "column": 39}}, {"id": 843, "type": "identifier", "text": "READWRITE", "parent": 842, "children": [], "start_point": {"row": 256, "column": 12}, "end_point": {"row": 256, "column": 21}}, {"id": 844, "type": "argument_list", "text": "(hashProofOfStake)", "parent": 842, "children": [845], "start_point": {"row": 256, "column": 21}, "end_point": {"row": 256, "column": 39}}, {"id": 845, "type": "identifier", "text": "hashProofOfStake", "parent": 844, "children": [], "start_point": {"row": 256, "column": 22}, "end_point": {"row": 256, "column": 38}}, {"id": 846, "type": "else_clause", "text": "else if (fRead)\n {\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }", "parent": 829, "children": [847], "start_point": {"row": 258, "column": 8}, "end_point": {"row": 263, "column": 9}}, {"id": 847, "type": "if_statement", "text": "if (fRead)\n {\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }", "parent": 846, "children": [848], "start_point": {"row": 258, "column": 13}, "end_point": {"row": 263, "column": 9}}, {"id": 848, "type": "parenthesized_expression", "text": "(fRead)", "parent": 847, "children": [849], "start_point": {"row": 258, "column": 16}, "end_point": {"row": 258, "column": 23}}, {"id": 849, "type": "identifier", "text": "fRead", "parent": 848, "children": [], "start_point": {"row": 258, "column": 17}, "end_point": {"row": 258, "column": 22}}, {"id": 850, "type": "binary_expression", "text": "const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull()", "parent": 847, "children": [851, 855, 857, 858], "start_point": {"row": 260, "column": 12}, "end_point": {"row": 260, "column": 70}}, {"id": 851, "type": "binary_expression", "text": "const_cast<CDiskBlockIndex", "parent": 850, "children": [852, 853, 854], "start_point": {"row": 260, "column": 12}, "end_point": {"row": 260, "column": 38}}, {"id": 852, "type": "identifier", "text": "const_cast", "parent": 851, "children": [], "start_point": {"row": 260, "column": 12}, "end_point": {"row": 260, "column": 22}}, {"id": 853, "type": "<", "text": "<", "parent": 851, "children": [], "start_point": {"row": 260, "column": 22}, "end_point": {"row": 260, "column": 23}}, {"id": 854, "type": "identifier", "text": "CDiskBlockIndex", "parent": 851, "children": [], "start_point": {"row": 260, "column": 23}, "end_point": {"row": 260, "column": 38}}, {"id": 855, "type": "ERROR", "text": "*", "parent": 850, "children": [856], "start_point": {"row": 260, "column": 38}, "end_point": {"row": 260, "column": 39}}, {"id": 856, "type": "*", "text": "*", "parent": 855, "children": [], "start_point": {"row": 260, "column": 38}, "end_point": {"row": 260, "column": 39}}, {"id": 857, "type": ">", "text": ">", "parent": 850, "children": [], "start_point": {"row": 260, "column": 39}, "end_point": {"row": 260, "column": 40}}, {"id": 858, "type": "call_expression", "text": "(this)->prevoutStake.SetNull()", "parent": 850, "children": [859, 865], "start_point": {"row": 260, "column": 40}, "end_point": {"row": 260, "column": 70}}, {"id": 859, "type": "field_expression", "text": "(this)->prevoutStake.SetNull", "parent": 858, "children": [860, 864], "start_point": {"row": 260, "column": 40}, "end_point": {"row": 260, "column": 68}}, {"id": 860, "type": "field_expression", "text": "(this)->prevoutStake", "parent": 859, "children": [861, 863], "start_point": {"row": 260, "column": 40}, "end_point": {"row": 260, "column": 60}}, {"id": 861, "type": "parenthesized_expression", "text": "(this)", "parent": 860, "children": [862], "start_point": {"row": 260, "column": 40}, "end_point": {"row": 260, "column": 46}}, {"id": 862, "type": "identifier", "text": "this", "parent": 861, "children": [], "start_point": {"row": 260, "column": 41}, "end_point": {"row": 260, "column": 45}}, {"id": 863, "type": "field_identifier", "text": "prevoutStake", "parent": 860, "children": [], "start_point": {"row": 260, "column": 48}, "end_point": {"row": 260, "column": 60}}, {"id": 864, "type": "field_identifier", "text": "SetNull", "parent": 859, "children": [], "start_point": {"row": 260, "column": 61}, "end_point": {"row": 260, "column": 68}}, {"id": 865, "type": "argument_list", "text": "()", "parent": 858, "children": [], "start_point": {"row": 260, "column": 68}, "end_point": {"row": 260, "column": 70}}, {"id": 866, "type": "binary_expression", "text": "const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0", "parent": 847, "children": [867, 871, 873, 874], "start_point": {"row": 261, "column": 12}, "end_point": {"row": 261, "column": 62}}, {"id": 867, "type": "binary_expression", "text": "const_cast<CDiskBlockIndex", "parent": 866, "children": [868, 869, 870], "start_point": {"row": 261, "column": 12}, "end_point": {"row": 261, "column": 38}}, {"id": 868, "type": "identifier", "text": "const_cast", "parent": 867, "children": [], "start_point": {"row": 261, "column": 12}, "end_point": {"row": 261, "column": 22}}, {"id": 869, "type": "<", "text": "<", "parent": 867, "children": [], "start_point": {"row": 261, "column": 22}, "end_point": {"row": 261, "column": 23}}, {"id": 870, "type": "identifier", "text": "CDiskBlockIndex", "parent": 867, "children": [], "start_point": {"row": 261, "column": 23}, "end_point": {"row": 261, "column": 38}}, {"id": 871, "type": "ERROR", "text": "*", "parent": 866, "children": [872], "start_point": {"row": 261, "column": 38}, "end_point": {"row": 261, "column": 39}}, {"id": 872, "type": "*", "text": "*", "parent": 871, "children": [], "start_point": {"row": 261, "column": 38}, "end_point": {"row": 261, "column": 39}}, {"id": 873, "type": ">", "text": ">", "parent": 866, "children": [], "start_point": {"row": 261, "column": 39}, "end_point": {"row": 261, "column": 40}}, {"id": 874, "type": "assignment_expression", "text": "(this)->nStakeTime = 0", "parent": 866, "children": [875, 879, 880], "start_point": {"row": 261, "column": 40}, "end_point": {"row": 261, "column": 62}}, {"id": 875, "type": "field_expression", "text": "(this)->nStakeTime", "parent": 874, "children": [876, 878], "start_point": {"row": 261, "column": 40}, "end_point": {"row": 261, "column": 58}}, {"id": 876, "type": "parenthesized_expression", "text": "(this)", "parent": 875, "children": [877], "start_point": {"row": 261, "column": 40}, "end_point": {"row": 261, "column": 46}}, {"id": 877, "type": "identifier", "text": "this", "parent": 876, "children": [], "start_point": {"row": 261, "column": 41}, "end_point": {"row": 261, "column": 45}}, {"id": 878, "type": "field_identifier", "text": "nStakeTime", "parent": 875, "children": [], "start_point": {"row": 261, "column": 48}, "end_point": {"row": 261, "column": 58}}, {"id": 879, "type": "=", "text": "=", "parent": 874, "children": [], "start_point": {"row": 261, "column": 59}, "end_point": {"row": 261, "column": 60}}, {"id": 880, "type": "number_literal", "text": "0", "parent": 874, "children": [], "start_point": {"row": 261, "column": 61}, "end_point": {"row": 261, "column": 62}}, {"id": 881, "type": "binary_expression", "text": "const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0", "parent": 847, "children": [882, 886, 888, 889], "start_point": {"row": 262, "column": 12}, "end_point": {"row": 262, "column": 68}}, {"id": 882, "type": "binary_expression", "text": "const_cast<CDiskBlockIndex", "parent": 881, "children": [883, 884, 885], "start_point": {"row": 262, "column": 12}, "end_point": {"row": 262, "column": 38}}, {"id": 883, "type": "identifier", "text": "const_cast", "parent": 882, "children": [], "start_point": {"row": 262, "column": 12}, "end_point": {"row": 262, "column": 22}}, {"id": 884, "type": "<", "text": "<", "parent": 882, "children": [], "start_point": {"row": 262, "column": 22}, "end_point": {"row": 262, "column": 23}}, {"id": 885, "type": "identifier", "text": "CDiskBlockIndex", "parent": 882, "children": [], "start_point": {"row": 262, "column": 23}, "end_point": {"row": 262, "column": 38}}, {"id": 886, "type": "ERROR", "text": "*", "parent": 881, "children": [887], "start_point": {"row": 262, "column": 38}, "end_point": {"row": 262, "column": 39}}, {"id": 887, "type": "*", "text": "*", "parent": 886, "children": [], "start_point": {"row": 262, "column": 38}, "end_point": {"row": 262, "column": 39}}, {"id": 888, "type": ">", "text": ">", "parent": 881, "children": [], "start_point": {"row": 262, "column": 39}, "end_point": {"row": 262, "column": 40}}, {"id": 889, "type": "assignment_expression", "text": "(this)->hashProofOfStake = 0", "parent": 881, "children": [890, 894, 895], "start_point": {"row": 262, "column": 40}, "end_point": {"row": 262, "column": 68}}, {"id": 890, "type": "field_expression", "text": "(this)->hashProofOfStake", "parent": 889, "children": [891, 893], "start_point": {"row": 262, "column": 40}, "end_point": {"row": 262, "column": 64}}, {"id": 891, "type": "parenthesized_expression", "text": "(this)", "parent": 890, "children": [892], "start_point": {"row": 262, "column": 40}, "end_point": {"row": 262, "column": 46}}, {"id": 892, "type": "identifier", "text": "this", "parent": 891, "children": [], "start_point": {"row": 262, "column": 41}, "end_point": {"row": 262, "column": 45}}, {"id": 893, "type": "field_identifier", "text": "hashProofOfStake", "parent": 890, "children": [], "start_point": {"row": 262, "column": 48}, "end_point": {"row": 262, "column": 64}}, {"id": 894, "type": "=", "text": "=", "parent": 889, "children": [], "start_point": {"row": 262, "column": 65}, "end_point": {"row": 262, "column": 66}}, {"id": 895, "type": "number_literal", "text": "0", "parent": 889, "children": [], "start_point": {"row": 262, "column": 67}, "end_point": {"row": 262, "column": 68}}, {"id": 896, "type": "call_expression", "text": "READWRITE(this->nVersion)", "parent": 384, "children": [897, 898], "start_point": {"row": 266, "column": 8}, "end_point": {"row": 266, "column": 33}}, {"id": 897, "type": "identifier", "text": "READWRITE", "parent": 896, "children": [], "start_point": {"row": 266, "column": 8}, "end_point": {"row": 266, "column": 17}}, {"id": 898, "type": "argument_list", "text": "(this->nVersion)", "parent": 896, "children": [899], "start_point": {"row": 266, "column": 17}, "end_point": {"row": 266, "column": 33}}, {"id": 899, "type": "field_expression", "text": "this->nVersion", "parent": 898, "children": [900, 901], "start_point": {"row": 266, "column": 18}, "end_point": {"row": 266, "column": 32}}, {"id": 900, "type": "identifier", "text": "this", "parent": 899, "children": [], "start_point": {"row": 266, "column": 18}, "end_point": {"row": 266, "column": 22}}, {"id": 901, "type": "field_identifier", "text": "nVersion", "parent": 899, "children": [], "start_point": {"row": 266, "column": 24}, "end_point": {"row": 266, "column": 32}}, {"id": 902, "type": "call_expression", "text": "READWRITE(hashPrev)", "parent": 384, "children": [903, 904], "start_point": {"row": 267, "column": 8}, "end_point": {"row": 267, "column": 27}}, {"id": 903, "type": "identifier", "text": "READWRITE", "parent": 902, "children": [], "start_point": {"row": 267, "column": 8}, "end_point": {"row": 267, "column": 17}}, {"id": 904, "type": "argument_list", "text": "(hashPrev)", "parent": 902, "children": [905], "start_point": {"row": 267, "column": 17}, "end_point": {"row": 267, "column": 27}}, {"id": 905, "type": "identifier", "text": "hashPrev", "parent": 904, "children": [], "start_point": {"row": 267, "column": 18}, "end_point": {"row": 267, "column": 26}}, {"id": 906, "type": "call_expression", "text": "READWRITE(hashMerkleRoot)", "parent": 384, "children": [907, 908], "start_point": {"row": 268, "column": 8}, "end_point": {"row": 268, "column": 33}}, {"id": 907, "type": "identifier", "text": "READWRITE", "parent": 906, "children": [], "start_point": {"row": 268, "column": 8}, "end_point": {"row": 268, "column": 17}}, {"id": 908, "type": "argument_list", "text": "(hashMerkleRoot)", "parent": 906, "children": [909], "start_point": {"row": 268, "column": 17}, "end_point": {"row": 268, "column": 33}}, {"id": 909, "type": "identifier", "text": "hashMerkleRoot", "parent": 908, "children": [], "start_point": {"row": 268, "column": 18}, "end_point": {"row": 268, "column": 32}}, {"id": 910, "type": "call_expression", "text": "READWRITE(nTime)", "parent": 384, "children": [911, 912], "start_point": {"row": 269, "column": 8}, "end_point": {"row": 269, "column": 24}}, {"id": 911, "type": "identifier", "text": "READWRITE", "parent": 910, "children": [], "start_point": {"row": 269, "column": 8}, "end_point": {"row": 269, "column": 17}}, {"id": 912, "type": "argument_list", "text": "(nTime)", "parent": 910, "children": [913], "start_point": {"row": 269, "column": 17}, "end_point": {"row": 269, "column": 24}}, {"id": 913, "type": "identifier", "text": "nTime", "parent": 912, "children": [], "start_point": {"row": 269, "column": 18}, "end_point": {"row": 269, "column": 23}}, {"id": 914, "type": "call_expression", "text": "READWRITE(nBits)", "parent": 384, "children": [915, 916], "start_point": {"row": 270, "column": 8}, "end_point": {"row": 270, "column": 24}}, {"id": 915, "type": "identifier", "text": "READWRITE", "parent": 914, "children": [], "start_point": {"row": 270, "column": 8}, "end_point": {"row": 270, "column": 17}}, {"id": 916, "type": "argument_list", "text": "(nBits)", "parent": 914, "children": [917], "start_point": {"row": 270, "column": 17}, "end_point": {"row": 270, "column": 24}}, {"id": 917, "type": "identifier", "text": "nBits", "parent": 916, "children": [], "start_point": {"row": 270, "column": 18}, "end_point": {"row": 270, "column": 23}}, {"id": 918, "type": "call_expression", "text": "READWRITE(nNonce)", "parent": 384, "children": [919, 920], "start_point": {"row": 271, "column": 8}, "end_point": {"row": 271, "column": 25}}, {"id": 919, "type": "identifier", "text": "READWRITE", "parent": 918, "children": [], "start_point": {"row": 271, "column": 8}, "end_point": {"row": 271, "column": 17}}, {"id": 920, "type": "argument_list", "text": "(nNonce)", "parent": 918, "children": [921], "start_point": {"row": 271, "column": 17}, "end_point": {"row": 271, "column": 25}}, {"id": 921, "type": "identifier", "text": "nNonce", "parent": 920, "children": [], "start_point": {"row": 271, "column": 18}, "end_point": {"row": 271, "column": 24}}, {"id": 922, "type": "ERROR", "text": ")\n\n uint256 GetBlockHash() const", "parent": 384, "children": [923, 924], "start_point": {"row": 272, "column": 4}, "end_point": {"row": 274, "column": 32}}, {"id": 923, "type": "type_identifier", "text": "uint256", "parent": 922, "children": [], "start_point": {"row": 274, "column": 4}, "end_point": {"row": 274, "column": 11}}, {"id": 924, "type": "function_declarator", "text": "GetBlockHash()", "parent": 922, "children": [925, 926], "start_point": {"row": 274, "column": 12}, "end_point": {"row": 274, "column": 26}}, {"id": 925, "type": "identifier", "text": "GetBlockHash", "parent": 924, "children": [], "start_point": {"row": 274, "column": 12}, "end_point": {"row": 274, "column": 24}}, {"id": 926, "type": "parameter_list", "text": "()", "parent": 924, "children": [], "start_point": {"row": 274, "column": 24}, "end_point": {"row": 274, "column": 26}}, {"id": 927, "type": "declaration", "text": "CBlock block;", "parent": 384, "children": [928, 929], "start_point": {"row": 276, "column": 8}, "end_point": {"row": 276, "column": 21}}, {"id": 928, "type": "type_identifier", "text": "CBlock", "parent": 927, "children": [], "start_point": {"row": 276, "column": 8}, "end_point": {"row": 276, "column": 14}}, {"id": 929, "type": "identifier", "text": "block", "parent": 927, "children": [], "start_point": {"row": 276, "column": 15}, "end_point": {"row": 276, "column": 20}}, {"id": 930, "type": "assignment_expression", "text": "block.nVersion = nVersion", "parent": 384, "children": [931, 934, 935], "start_point": {"row": 277, "column": 8}, "end_point": {"row": 277, "column": 40}}, {"id": 931, "type": "field_expression", "text": "block.nVersion", "parent": 930, "children": [932, 933], "start_point": {"row": 277, "column": 8}, "end_point": {"row": 277, "column": 22}}, {"id": 932, "type": "identifier", "text": "block", "parent": 931, "children": [], "start_point": {"row": 277, "column": 8}, "end_point": {"row": 277, "column": 13}}, {"id": 933, "type": "field_identifier", "text": "nVersion", "parent": 931, "children": [], "start_point": {"row": 277, "column": 14}, "end_point": {"row": 277, "column": 22}}, {"id": 934, "type": "=", "text": "=", "parent": 930, "children": [], "start_point": {"row": 277, "column": 30}, "end_point": {"row": 277, "column": 31}}, {"id": 935, "type": "identifier", "text": "nVersion", "parent": 930, "children": [], "start_point": {"row": 277, "column": 32}, "end_point": {"row": 277, "column": 40}}, {"id": 936, "type": "assignment_expression", "text": "block.hashPrevBlock = hashPrev", "parent": 384, "children": [937, 940, 941], "start_point": {"row": 278, "column": 8}, "end_point": {"row": 278, "column": 40}}, {"id": 937, "type": "field_expression", "text": "block.hashPrevBlock", "parent": 936, "children": [938, 939], "start_point": {"row": 278, "column": 8}, "end_point": {"row": 278, "column": 27}}, {"id": 938, "type": "identifier", "text": "block", "parent": 937, "children": [], "start_point": {"row": 278, "column": 8}, "end_point": {"row": 278, "column": 13}}, {"id": 939, "type": "field_identifier", "text": "hashPrevBlock", "parent": 937, "children": [], "start_point": {"row": 278, "column": 14}, "end_point": {"row": 278, "column": 27}}, {"id": 940, "type": "=", "text": "=", "parent": 936, "children": [], "start_point": {"row": 278, "column": 30}, "end_point": {"row": 278, "column": 31}}, {"id": 941, "type": "identifier", "text": "hashPrev", "parent": 936, "children": [], "start_point": {"row": 278, "column": 32}, "end_point": {"row": 278, "column": 40}}, {"id": 942, "type": "assignment_expression", "text": "block.hashMerkleRoot = hashMerkleRoot", "parent": 384, "children": [943, 946, 947], "start_point": {"row": 279, "column": 8}, "end_point": {"row": 279, "column": 46}}, {"id": 943, "type": "field_expression", "text": "block.hashMerkleRoot", "parent": 942, "children": [944, 945], "start_point": {"row": 279, "column": 8}, "end_point": {"row": 279, "column": 28}}, {"id": 944, "type": "identifier", "text": "block", "parent": 943, "children": [], "start_point": {"row": 279, "column": 8}, "end_point": {"row": 279, "column": 13}}, {"id": 945, "type": "field_identifier", "text": "hashMerkleRoot", "parent": 943, "children": [], "start_point": {"row": 279, "column": 14}, "end_point": {"row": 279, "column": 28}}, {"id": 946, "type": "=", "text": "=", "parent": 942, "children": [], "start_point": {"row": 279, "column": 30}, "end_point": {"row": 279, "column": 31}}, {"id": 947, "type": "identifier", "text": "hashMerkleRoot", "parent": 942, "children": [], "start_point": {"row": 279, "column": 32}, "end_point": {"row": 279, "column": 46}}, {"id": 948, "type": "assignment_expression", "text": "block.nTime = nTime", "parent": 384, "children": [949, 952, 953], "start_point": {"row": 280, "column": 8}, "end_point": {"row": 280, "column": 37}}, {"id": 949, "type": "field_expression", "text": "block.nTime", "parent": 948, "children": [950, 951], "start_point": {"row": 280, "column": 8}, "end_point": {"row": 280, "column": 19}}, {"id": 950, "type": "identifier", "text": "block", "parent": 949, "children": [], "start_point": {"row": 280, "column": 8}, "end_point": {"row": 280, "column": 13}}, {"id": 951, "type": "field_identifier", "text": "nTime", "parent": 949, "children": [], "start_point": {"row": 280, "column": 14}, "end_point": {"row": 280, "column": 19}}, {"id": 952, "type": "=", "text": "=", "parent": 948, "children": [], "start_point": {"row": 280, "column": 30}, "end_point": {"row": 280, "column": 31}}, {"id": 953, "type": "identifier", "text": "nTime", "parent": 948, "children": [], "start_point": {"row": 280, "column": 32}, "end_point": {"row": 280, "column": 37}}, {"id": 954, "type": "assignment_expression", "text": "block.nBits = nBits", "parent": 384, "children": [955, 958, 959], "start_point": {"row": 281, "column": 8}, "end_point": {"row": 281, "column": 37}}, {"id": 955, "type": "field_expression", "text": "block.nBits", "parent": 954, "children": [956, 957], "start_point": {"row": 281, "column": 8}, "end_point": {"row": 281, "column": 19}}, {"id": 956, "type": "identifier", "text": "block", "parent": 955, "children": [], "start_point": {"row": 281, "column": 8}, "end_point": {"row": 281, "column": 13}}, {"id": 957, "type": "field_identifier", "text": "nBits", "parent": 955, "children": [], "start_point": {"row": 281, "column": 14}, "end_point": {"row": 281, "column": 19}}, {"id": 958, "type": "=", "text": "=", "parent": 954, "children": [], "start_point": {"row": 281, "column": 30}, "end_point": {"row": 281, "column": 31}}, {"id": 959, "type": "identifier", "text": "nBits", "parent": 954, "children": [], "start_point": {"row": 281, "column": 32}, "end_point": {"row": 281, "column": 37}}, {"id": 960, "type": "assignment_expression", "text": "block.nNonce = nNonce", "parent": 384, "children": [961, 964, 965], "start_point": {"row": 282, "column": 8}, "end_point": {"row": 282, "column": 38}}, {"id": 961, "type": "field_expression", "text": "block.nNonce", "parent": 960, "children": [962, 963], "start_point": {"row": 282, "column": 8}, "end_point": {"row": 282, "column": 20}}, {"id": 962, "type": "identifier", "text": "block", "parent": 961, "children": [], "start_point": {"row": 282, "column": 8}, "end_point": {"row": 282, "column": 13}}, {"id": 963, "type": "field_identifier", "text": "nNonce", "parent": 961, "children": [], "start_point": {"row": 282, "column": 14}, "end_point": {"row": 282, "column": 20}}, {"id": 964, "type": "=", "text": "=", "parent": 960, "children": [], "start_point": {"row": 282, "column": 30}, "end_point": {"row": 282, "column": 31}}, {"id": 965, "type": "identifier", "text": "nNonce", "parent": 960, "children": [], "start_point": {"row": 282, "column": 32}, "end_point": {"row": 282, "column": 38}}, {"id": 966, "type": "return_statement", "text": "return block.GetHash();", "parent": 384, "children": [967], "start_point": {"row": 283, "column": 8}, "end_point": {"row": 283, "column": 31}}, {"id": 967, "type": "call_expression", "text": "block.GetHash()", "parent": 966, "children": [968, 971], "start_point": {"row": 283, "column": 15}, "end_point": {"row": 283, "column": 30}}, {"id": 968, "type": "field_expression", "text": "block.GetHash", "parent": 967, "children": [969, 970], "start_point": {"row": 283, "column": 15}, "end_point": {"row": 283, "column": 28}}, {"id": 969, "type": "identifier", "text": "block", "parent": 968, "children": [], "start_point": {"row": 283, "column": 15}, "end_point": {"row": 283, "column": 20}}, {"id": 970, "type": "field_identifier", "text": "GetHash", "parent": 968, "children": [], "start_point": {"row": 283, "column": 21}, "end_point": {"row": 283, "column": 28}}, {"id": 971, "type": "argument_list", "text": "()", "parent": 967, "children": [], "start_point": {"row": 283, "column": 28}, "end_point": {"row": 283, "column": 30}}, {"id": 972, "type": "labeled_statement", "text": "std::string ToString() const\n {\n std::string str = \"CDiskBlockIndex(\";\n str += CBlockIndex::ToString();\n str += strprintf(\"\\n hashBlock=%s, hashPrev=%s, hashNext=%s)\",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str());\n return str;\n }", "parent": 384, "children": [973, 974], "start_point": {"row": 287, "column": 4}, "end_point": {"row": 296, "column": 5}}, {"id": 973, "type": "statement_identifier", "text": "std", "parent": 972, "children": [], "start_point": {"row": 287, "column": 4}, "end_point": {"row": 287, "column": 7}}, {"id": 974, "type": "ERROR", "text": ":string ToString() const", "parent": 972, "children": [975, 976], "start_point": {"row": 287, "column": 8}, "end_point": {"row": 287, "column": 32}}, {"id": 975, "type": "type_identifier", "text": "string", "parent": 974, "children": [], "start_point": {"row": 287, "column": 9}, "end_point": {"row": 287, "column": 15}}, {"id": 976, "type": "function_declarator", "text": "ToString() const", "parent": 974, "children": [977, 978], "start_point": {"row": 287, "column": 16}, "end_point": {"row": 287, "column": 32}}, {"id": 977, "type": "identifier", "text": "ToString", "parent": 976, "children": [], "start_point": {"row": 287, "column": 16}, "end_point": {"row": 287, "column": 24}}, {"id": 978, "type": "parameter_list", "text": "()", "parent": 976, "children": [], "start_point": {"row": 287, "column": 24}, "end_point": {"row": 287, "column": 26}}, {"id": 979, "type": "labeled_statement", "text": "std::string str = \"CDiskBlockIndex(\";", "parent": 972, "children": [980, 981], "start_point": {"row": 289, "column": 8}, "end_point": {"row": 289, "column": 45}}, {"id": 980, "type": "statement_identifier", "text": "std", "parent": 979, "children": [], "start_point": {"row": 289, "column": 8}, "end_point": {"row": 289, "column": 11}}, {"id": 981, "type": "declaration", "text": "string str = \"CDiskBlockIndex(\";", "parent": 979, "children": [982, 983], "start_point": {"row": 289, "column": 13}, "end_point": {"row": 289, "column": 45}}, {"id": 982, "type": "type_identifier", "text": "string", "parent": 981, "children": [], "start_point": {"row": 289, "column": 13}, "end_point": {"row": 289, "column": 19}}, {"id": 983, "type": "init_declarator", "text": "str = \"CDiskBlockIndex(\"", "parent": 981, "children": [984, 985, 986], "start_point": {"row": 289, "column": 20}, "end_point": {"row": 289, "column": 44}}, {"id": 984, "type": "identifier", "text": "str", "parent": 983, "children": [], "start_point": {"row": 289, "column": 20}, "end_point": {"row": 289, "column": 23}}, {"id": 985, "type": "=", "text": "=", "parent": 983, "children": [], "start_point": {"row": 289, "column": 24}, "end_point": {"row": 289, "column": 25}}, {"id": 986, "type": "string_literal", "text": "\"CDiskBlockIndex(\"", "parent": 983, "children": [], "start_point": {"row": 289, "column": 26}, "end_point": {"row": 289, "column": 44}}, {"id": 987, "type": "ERROR", "text": "str += CBlockIndex::", "parent": 972, "children": [988], "start_point": {"row": 290, "column": 8}, "end_point": {"row": 290, "column": 28}}, {"id": 988, "type": "assignment_expression", "text": "str += CBlockIndex", "parent": 987, "children": [989, 990, 991], "start_point": {"row": 290, "column": 8}, "end_point": {"row": 290, "column": 26}}, {"id": 989, "type": "identifier", "text": "str", "parent": 988, "children": [], "start_point": {"row": 290, "column": 8}, "end_point": {"row": 290, "column": 11}}, {"id": 990, "type": "+=", "text": "+=", "parent": 988, "children": [], "start_point": {"row": 290, "column": 12}, "end_point": {"row": 290, "column": 14}}, {"id": 991, "type": "identifier", "text": "CBlockIndex", "parent": 988, "children": [], "start_point": {"row": 290, "column": 15}, "end_point": {"row": 290, "column": 26}}, {"id": 992, "type": "call_expression", "text": "ToString()", "parent": 972, "children": [993, 994], "start_point": {"row": 290, "column": 28}, "end_point": {"row": 290, "column": 38}}, {"id": 993, "type": "identifier", "text": "ToString", "parent": 992, "children": [], "start_point": {"row": 290, "column": 28}, "end_point": {"row": 290, "column": 36}}, {"id": 994, "type": "argument_list", "text": "()", "parent": 992, "children": [], "start_point": {"row": 290, "column": 36}, "end_point": {"row": 290, "column": 38}}, {"id": 995, "type": "assignment_expression", "text": "str += strprintf(\"\\n hashBlock=%s, hashPrev=%s, hashNext=%s)\",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str())", "parent": 972, "children": [996, 997, 998], "start_point": {"row": 291, "column": 8}, "end_point": {"row": 294, "column": 40}}, {"id": 996, "type": "identifier", "text": "str", "parent": 995, "children": [], "start_point": {"row": 291, "column": 8}, "end_point": {"row": 291, "column": 11}}, {"id": 997, "type": "+=", "text": "+=", "parent": 995, "children": [], "start_point": {"row": 291, "column": 12}, "end_point": {"row": 291, "column": 14}}, {"id": 998, "type": "call_expression", "text": "strprintf(\"\\n hashBlock=%s, hashPrev=%s, hashNext=%s)\",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str())", "parent": 995, "children": [999, 1000], "start_point": {"row": 291, "column": 15}, "end_point": {"row": 294, "column": 40}}, {"id": 999, "type": "identifier", "text": "strprintf", "parent": 998, "children": [], "start_point": {"row": 291, "column": 15}, "end_point": {"row": 291, "column": 24}}, {"id": 1000, "type": "argument_list", "text": "(\"\\n hashBlock=%s, hashPrev=%s, hashNext=%s)\",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str())", "parent": 998, "children": [1001, 1003, 1014, 1023], "start_point": {"row": 291, "column": 24}, "end_point": {"row": 294, "column": 40}}, {"id": 1001, "type": "string_literal", "text": "\"\\n hashBlock=%s, hashPrev=%s, hashNext=%s)\"", "parent": 1000, "children": [1002], "start_point": {"row": 291, "column": 25}, "end_point": {"row": 291, "column": 84}}, {"id": 1002, "type": "escape_sequence", "text": "\\n", "parent": 1001, "children": [], "start_point": {"row": 291, "column": 26}, "end_point": {"row": 291, "column": 28}}, {"id": 1003, "type": "call_expression", "text": "GetBlockHash().ToString().c_str()", "parent": 1000, "children": [1004, 1013], "start_point": {"row": 292, "column": 12}, "end_point": {"row": 292, "column": 45}}, {"id": 1004, "type": "field_expression", "text": "GetBlockHash().ToString().c_str", "parent": 1003, "children": [1005, 1012], "start_point": {"row": 292, "column": 12}, "end_point": {"row": 292, "column": 43}}, {"id": 1005, "type": "call_expression", "text": "GetBlockHash().ToString()", "parent": 1004, "children": [1006, 1011], "start_point": {"row": 292, "column": 12}, "end_point": {"row": 292, "column": 37}}, {"id": 1006, "type": "field_expression", "text": "GetBlockHash().ToString", "parent": 1005, "children": [1007, 1010], "start_point": {"row": 292, "column": 12}, "end_point": {"row": 292, "column": 35}}, {"id": 1007, "type": "call_expression", "text": "GetBlockHash()", "parent": 1006, "children": [1008, 1009], "start_point": {"row": 292, "column": 12}, "end_point": {"row": 292, "column": 26}}, {"id": 1008, "type": "identifier", "text": "GetBlockHash", "parent": 1007, "children": [], "start_point": {"row": 292, "column": 12}, "end_point": {"row": 292, "column": 24}}, {"id": 1009, "type": "argument_list", "text": "()", "parent": 1007, "children": [], "start_point": {"row": 292, "column": 24}, "end_point": {"row": 292, "column": 26}}, {"id": 1010, "type": "field_identifier", "text": "ToString", "parent": 1006, "children": [], "start_point": {"row": 292, "column": 27}, "end_point": {"row": 292, "column": 35}}, {"id": 1011, "type": "argument_list", "text": "()", "parent": 1005, "children": [], "start_point": {"row": 292, "column": 35}, "end_point": {"row": 292, "column": 37}}, {"id": 1012, "type": "field_identifier", "text": "c_str", "parent": 1004, "children": [], "start_point": {"row": 292, "column": 38}, "end_point": {"row": 292, "column": 43}}, {"id": 1013, "type": "argument_list", "text": "()", "parent": 1003, "children": [], "start_point": {"row": 292, "column": 43}, "end_point": {"row": 292, "column": 45}}, {"id": 1014, "type": "call_expression", "text": "hashPrev.ToString().c_str()", "parent": 1000, "children": [1015, 1022], "start_point": {"row": 293, "column": 12}, "end_point": {"row": 293, "column": 39}}, {"id": 1015, "type": "field_expression", "text": "hashPrev.ToString().c_str", "parent": 1014, "children": [1016, 1021], "start_point": {"row": 293, "column": 12}, "end_point": {"row": 293, "column": 37}}, {"id": 1016, "type": "call_expression", "text": "hashPrev.ToString()", "parent": 1015, "children": [1017, 1020], "start_point": {"row": 293, "column": 12}, "end_point": {"row": 293, "column": 31}}, {"id": 1017, "type": "field_expression", "text": "hashPrev.ToString", "parent": 1016, "children": [1018, 1019], "start_point": {"row": 293, "column": 12}, "end_point": {"row": 293, "column": 29}}, {"id": 1018, "type": "identifier", "text": "hashPrev", "parent": 1017, "children": [], "start_point": {"row": 293, "column": 12}, "end_point": {"row": 293, "column": 20}}, {"id": 1019, "type": "field_identifier", "text": "ToString", "parent": 1017, "children": [], "start_point": {"row": 293, "column": 21}, "end_point": {"row": 293, "column": 29}}, {"id": 1020, "type": "argument_list", "text": "()", "parent": 1016, "children": [], "start_point": {"row": 293, "column": 29}, "end_point": {"row": 293, "column": 31}}, {"id": 1021, "type": "field_identifier", "text": "c_str", "parent": 1015, "children": [], "start_point": {"row": 293, "column": 32}, "end_point": {"row": 293, "column": 37}}, {"id": 1022, "type": "argument_list", "text": "()", "parent": 1014, "children": [], "start_point": {"row": 293, "column": 37}, "end_point": {"row": 293, "column": 39}}, {"id": 1023, "type": "call_expression", "text": "hashNext.ToString().c_str()", "parent": 1000, "children": [1024, 1031], "start_point": {"row": 294, "column": 12}, "end_point": {"row": 294, "column": 39}}, {"id": 1024, "type": "field_expression", "text": "hashNext.ToString().c_str", "parent": 1023, "children": [1025, 1030], "start_point": {"row": 294, "column": 12}, "end_point": {"row": 294, "column": 37}}, {"id": 1025, "type": "call_expression", "text": "hashNext.ToString()", "parent": 1024, "children": [1026, 1029], "start_point": {"row": 294, "column": 12}, "end_point": {"row": 294, "column": 31}}, {"id": 1026, "type": "field_expression", "text": "hashNext.ToString", "parent": 1025, "children": [1027, 1028], "start_point": {"row": 294, "column": 12}, "end_point": {"row": 294, "column": 29}}, {"id": 1027, "type": "identifier", "text": "hashNext", "parent": 1026, "children": [], "start_point": {"row": 294, "column": 12}, "end_point": {"row": 294, "column": 20}}, {"id": 1028, "type": "field_identifier", "text": "ToString", "parent": 1026, "children": [], "start_point": {"row": 294, "column": 21}, "end_point": {"row": 294, "column": 29}}, {"id": 1029, "type": "argument_list", "text": "()", "parent": 1025, "children": [], "start_point": {"row": 294, "column": 29}, "end_point": {"row": 294, "column": 31}}, {"id": 1030, "type": "field_identifier", "text": "c_str", "parent": 1024, "children": [], "start_point": {"row": 294, "column": 32}, "end_point": {"row": 294, "column": 37}}, {"id": 1031, "type": "argument_list", "text": "()", "parent": 1023, "children": [], "start_point": {"row": 294, "column": 37}, "end_point": {"row": 294, "column": 39}}, {"id": 1032, "type": "return_statement", "text": "return str;", "parent": 972, "children": [1033], "start_point": {"row": 295, "column": 8}, "end_point": {"row": 295, "column": 19}}, {"id": 1033, "type": "identifier", "text": "str", "parent": 1032, "children": [], "start_point": {"row": 295, "column": 15}, "end_point": {"row": 295, "column": 18}}, {"id": 1034, "type": "ERROR", "text": "void print() const", "parent": 384, "children": [1035, 1036], "start_point": {"row": 298, "column": 4}, "end_point": {"row": 298, "column": 22}}, {"id": 1035, "type": "primitive_type", "text": "void", "parent": 1034, "children": [], "start_point": {"row": 298, "column": 4}, "end_point": {"row": 298, "column": 8}}, {"id": 1036, "type": "function_declarator", "text": "print()", "parent": 1034, "children": [1037, 1038], "start_point": {"row": 298, "column": 9}, "end_point": {"row": 298, "column": 16}}, {"id": 1037, "type": "identifier", "text": "print", "parent": 1036, "children": [], "start_point": {"row": 298, "column": 9}, "end_point": {"row": 298, "column": 14}}, {"id": 1038, "type": "parameter_list", "text": "()", "parent": 1036, "children": [], "start_point": {"row": 298, "column": 14}, "end_point": {"row": 298, "column": 16}}, {"id": 1039, "type": "call_expression", "text": "printf(\"%s\\n\", ToString().c_str())", "parent": 384, "children": [1040, 1041], "start_point": {"row": 300, "column": 8}, "end_point": {"row": 300, "column": 42}}, {"id": 1040, "type": "identifier", "text": "printf", "parent": 1039, "children": [], "start_point": {"row": 300, "column": 8}, "end_point": {"row": 300, "column": 14}}, {"id": 1041, "type": "argument_list", "text": "(\"%s\\n\", ToString().c_str())", "parent": 1039, "children": [1042, 1044], "start_point": {"row": 300, "column": 14}, "end_point": {"row": 300, "column": 42}}, {"id": 1042, "type": "string_literal", "text": "\"%s\\n\"", "parent": 1041, "children": [1043], "start_point": {"row": 300, "column": 15}, "end_point": {"row": 300, "column": 21}}, {"id": 1043, "type": "escape_sequence", "text": "\\n", "parent": 1042, "children": [], "start_point": {"row": 300, "column": 18}, "end_point": {"row": 300, "column": 20}}, {"id": 1044, "type": "call_expression", "text": "ToString().c_str()", "parent": 1041, "children": [1045, 1050], "start_point": {"row": 300, "column": 23}, "end_point": {"row": 300, "column": 41}}, {"id": 1045, "type": "field_expression", "text": "ToString().c_str", "parent": 1044, "children": [1046, 1049], "start_point": {"row": 300, "column": 23}, "end_point": {"row": 300, "column": 39}}, {"id": 1046, "type": "call_expression", "text": "ToString()", "parent": 1045, "children": [1047, 1048], "start_point": {"row": 300, "column": 23}, "end_point": {"row": 300, "column": 33}}, {"id": 1047, "type": "identifier", "text": "ToString", "parent": 1046, "children": [], "start_point": {"row": 300, "column": 23}, "end_point": {"row": 300, "column": 31}}, {"id": 1048, "type": "argument_list", "text": "()", "parent": 1046, "children": [], "start_point": {"row": 300, "column": 31}, "end_point": {"row": 300, "column": 33}}, {"id": 1049, "type": "field_identifier", "text": "c_str", "parent": 1045, "children": [], "start_point": {"row": 300, "column": 34}, "end_point": {"row": 300, "column": 39}}, {"id": 1050, "type": "argument_list", "text": "()", "parent": 1044, "children": [], "start_point": {"row": 300, "column": 39}, "end_point": {"row": 300, "column": 41}}, {"id": 1051, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 306, "column": 0}, "end_point": {"row": 306, "column": 6}}]}, "node_categories": {"declarations": {"functions": [16, 80, 82, 104, 192, 213, 227, 256, 293, 295, 308, 310, 381, 384, 598, 600, 606, 610, 614, 618, 622, 633, 637, 642, 665, 669, 674, 681, 686, 696, 701, 714, 718, 739, 741, 924, 976, 1036], "variables": [12, 14, 19, 24, 29, 40, 118, 164, 230, 319, 355, 387, 392, 397, 402, 407, 412, 415, 418, 421, 424, 456, 459, 464, 467, 472, 475, 478, 481, 486, 491, 583, 603, 640, 645, 648, 653, 658, 672, 684, 689, 699, 704, 707, 710, 726, 744, 927, 981], "classes": [], "imports": [6, 7, 9, 10], "modules": [], "enums": [429, 430, 431, 432, 440, 448, 625]}, "statements": {"expressions": [34, 37, 68, 71, 74, 77, 88, 108, 109, 112, 121, 124, 128, 129, 131, 135, 136, 137, 138, 139, 143, 147, 148, 152, 156, 157, 161, 167, 170, 174, 175, 177, 181, 183, 184, 196, 197, 204, 216, 220, 221, 222, 235, 236, 242, 245, 248, 249, 263, 264, 269, 273, 275, 277, 278, 281, 285, 289, 298, 299, 303, 304, 314, 315, 322, 325, 329, 330, 332, 336, 337, 338, 339, 343, 347, 348, 352, 358, 361, 365, 366, 368, 372, 374, 375, 435, 436, 443, 444, 451, 452, 496, 554, 555, 749, 758, 762, 763, 771, 775, 776, 781, 785, 787, 789, 790, 793, 797, 801, 805, 809, 813, 817, 821, 825, 830, 831, 834, 838, 842, 848, 850, 851, 858, 859, 860, 861, 866, 867, 875, 876, 881, 882, 890, 891, 896, 899, 902, 906, 910, 914, 918, 931, 937, 943, 949, 955, 961, 967, 968, 992, 998, 1003, 1004, 1005, 1006, 1007, 1014, 1015, 1016, 1017, 1023, 1024, 1025, 1026, 1039, 1044, 1045, 1046], "assignments": [60, 64, 85, 94, 98, 259, 499, 504, 509, 514, 518, 522, 526, 530, 534, 538, 542, 546, 550, 559, 563, 567, 571, 575, 579, 731, 735, 755, 768, 874, 889, 930, 936, 942, 948, 954, 960, 988, 995], "loops": [], "conditionals": [0, 1, 2, 5, 13, 15, 17, 20, 23, 25, 28, 30, 33, 35, 38, 41, 42, 44, 47, 49, 50, 51, 53, 54, 55, 57, 59, 61, 63, 65, 67, 69, 72, 75, 79, 83, 86, 90, 95, 99, 105, 110, 114, 119, 120, 122, 127, 130, 132, 133, 140, 141, 144, 145, 149, 150, 153, 154, 158, 159, 162, 163, 165, 166, 168, 173, 176, 178, 179, 185, 187, 189, 191, 193, 195, 198, 205, 208, 209, 210, 214, 217, 223, 225, 228, 231, 232, 234, 237, 239, 241, 243, 246, 250, 253, 254, 255, 258, 260, 262, 265, 266, 268, 270, 279, 280, 282, 284, 286, 288, 290, 292, 296, 300, 301, 305, 306, 311, 316, 317, 320, 321, 323, 328, 331, 333, 334, 340, 341, 344, 345, 349, 350, 353, 354, 356, 357, 359, 364, 367, 369, 370, 376, 378, 382, 385, 388, 391, 393, 396, 398, 401, 403, 406, 408, 411, 413, 414, 417, 419, 420, 422, 423, 425, 428, 433, 441, 449, 457, 458, 460, 463, 465, 466, 468, 471, 473, 474, 477, 479, 480, 482, 485, 487, 490, 492, 495, 497, 500, 505, 510, 515, 519, 523, 527, 531, 535, 539, 543, 547, 551, 556, 557, 560, 564, 568, 572, 576, 580, 584, 585, 587, 590, 592, 593, 594, 595, 597, 599, 601, 604, 607, 609, 611, 613, 615, 619, 623, 627, 631, 634, 636, 638, 643, 647, 649, 652, 654, 657, 659, 662, 666, 670, 675, 678, 682, 687, 690, 693, 697, 702, 705, 706, 709, 711, 713, 715, 719, 722, 723, 724, 725, 727, 728, 730, 732, 736, 740, 742, 745, 748, 750, 754, 756, 759, 760, 764, 765, 769, 772, 773, 777, 778, 782, 791, 792, 794, 796, 798, 800, 802, 804, 806, 808, 810, 812, 814, 816, 818, 820, 822, 824, 826, 828, 829, 832, 835, 837, 839, 841, 843, 845, 847, 849, 852, 854, 862, 863, 864, 868, 870, 877, 878, 883, 885, 892, 893, 897, 900, 901, 903, 905, 907, 909, 911, 913, 915, 917, 919, 921, 923, 925, 928, 929, 932, 933, 935, 938, 939, 941, 944, 945, 947, 950, 951, 953, 956, 957, 959, 962, 963, 965, 969, 970, 973, 975, 977, 980, 982, 984, 989, 991, 993, 996, 999, 1008, 1010, 1012, 1018, 1019, 1021, 1027, 1028, 1030, 1033, 1037, 1040, 1047, 1049, 1051], "returns": [107, 134, 180, 200, 203, 313, 335, 371, 966, 1032], "exceptions": []}, "expressions": {"calls": [], "literals": [8, 11, 93, 97, 101, 117, 201, 207, 219, 437, 439, 445, 447, 453, 455, 517, 521, 525, 529, 533, 537, 541, 545, 549, 553, 562, 566, 570, 574, 578, 582, 629, 734, 738, 767, 780, 880, 895, 986, 1001, 1042], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 16, "universal_type": "function", "name": "CDiskTxPos", "text_snippet": "class CDiskTxPos\n{\npublic:\n unsigned int nFile;\n unsigned int nBlockPos;\n unsigned int nTxP"}, {"node_id": 80, "universal_type": "function", "name": "SetNull", "text_snippet": "void SetNull() { nFile = (unsigned int) -1; nBlockPos = 0; nTxPos = 0; }"}, {"node_id": 82, "universal_type": "function", "name": "unknown", "text_snippet": "SetNull()"}, {"node_id": 104, "universal_type": "function", "name": "unknown", "text_snippet": "IsNull()"}, {"node_id": 192, "universal_type": "function", "name": "unknown", "text_snippet": "ToString() const"}, {"node_id": 213, "universal_type": "function", "name": "unknown", "text_snippet": "print()"}, {"node_id": 227, "universal_type": "function", "name": "CTxIndex", "text_snippet": "class CTxIndex\n{\npublic:\n CDiskTxPos pos;\n std::vector<CDiskTxPos> vSpent;\n\n CTxIndex()\n "}, {"node_id": 256, "universal_type": "function", "name": "nOutputs)", "text_snippet": "int nOutputs)\n {\n pos = posIn;\n vSpent.resize(nOutputs);\n }"}, {"node_id": 293, "universal_type": "function", "name": "SetNull", "text_snippet": "void SetNull()\n {\n pos.SetNull();\n vSpent.clear();\n }"}, {"node_id": 295, "universal_type": "function", "name": "unknown", "text_snippet": "SetNull()"}, {"node_id": 308, "universal_type": "function", "name": "IsNull", "text_snippet": "bool IsNull()\n {\n return pos.IsNull();\n }"}, {"node_id": 310, "universal_type": "function", "name": "unknown", "text_snippet": "IsNull()"}, {"node_id": 381, "universal_type": "function", "name": "unknown", "text_snippet": "GetDepthInMainChain()"}, {"node_id": 384, "universal_type": "function", "name": "CBlockIndex", "text_snippet": "class CBlockIndex\n{\npublic:\n const uint256* phashBlock;\n CBlockIndex* pprev;\n CBlockIndex* "}, {"node_id": 598, "universal_type": "function", "name": "IsInMainChain", "text_snippet": "CBlock GetBlockHeader() const;\n uint256 GetBlockHash() const;\n int64 GetBlockTime() const;\n "}, {"node_id": 600, "universal_type": "function", "name": "unknown", "text_snippet": "GetBlockHeader()"}, {"node_id": 606, "universal_type": "function", "name": "unknown", "text_snippet": "GetBlockHash() const"}, {"node_id": 610, "universal_type": "function", "name": "unknown", "text_snippet": "GetBlockTime() const"}, {"node_id": 614, "universal_type": "function", "name": "unknown", "text_snippet": "GetBlockTrust() const"}, {"node_id": 618, "universal_type": "function", "name": "unknown", "text_snippet": "IsInMainChain() const"}, {"node_id": 622, "universal_type": "function", "name": "unknown", "text_snippet": "CheckIndex() const"}, {"node_id": 633, "universal_type": "function", "name": "unknown", "text_snippet": "GetMedianTimePast() const"}, {"node_id": 637, "universal_type": "function", "name": "unknown", "text_snippet": "GetMedianTime() const"}, {"node_id": 642, "universal_type": "function", "name": "nRequired,", "text_snippet": "IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned "}, {"node_id": 665, "universal_type": "function", "name": "unknown", "text_snippet": "IsProofOfWork() const"}, {"node_id": 669, "universal_type": "function", "name": "unknown", "text_snippet": "IsProofOfStake() const"}, {"node_id": 674, "universal_type": "function", "name": "unknown", "text_snippet": "SetProofOfStake()"}, {"node_id": 681, "universal_type": "function", "name": "unknown", "text_snippet": "GetStakeEntropyBit() const"}, {"node_id": 686, "universal_type": "function", "name": "nEntropyBit)", "text_snippet": "SetStakeEntropyBit(unsigned int nEntropyBit)"}, {"node_id": 696, "universal_type": "function", "name": "unknown", "text_snippet": "GeneratedStakeModifier() const"}, {"node_id": 701, "universal_type": "function", "name": "fGeneratedStakeModifier)", "text_snippet": "SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier)"}, {"node_id": 714, "universal_type": "function", "name": "unknown", "text_snippet": "ToString() const"}, {"node_id": 718, "universal_type": "function", "name": "unknown", "text_snippet": "print() const"}, {"node_id": 739, "universal_type": "function", "name": "unknown", "text_snippet": "explicit CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex)\n {\n hashPrev = (pprev"}, {"node_id": 741, "universal_type": "function", "name": "unknown", "text_snippet": "CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex)"}, {"node_id": 924, "universal_type": "function", "name": "unknown", "text_snippet": "GetBlockHash()"}, {"node_id": 976, "universal_type": "function", "name": "unknown", "text_snippet": "ToString() const"}, {"node_id": 1036, "universal_type": "function", "name": "unknown", "text_snippet": "print()"}], "class_declarations": [], "import_statements": [{"node_id": 6, "text": "#include \"transaction.h\"\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include \"block.h\"\n"}, {"node_id": 10, "text": "#include"}]}, "original_source_code": "#ifndef INDEX_H\n#define INDEX_H\n\n#include \"transaction.h\"\n#include \"block.h\"\n\nclass CBlock;\nclass COutPoint;\n\n/** Position on disk for a particular transaction. */\nclass CDiskTxPos\n{\npublic:\n unsigned int nFile;\n unsigned int nBlockPos;\n unsigned int nTxPos;\n\n CDiskTxPos()\n {\n SetNull();\n }\n\n CDiskTxPos(unsigned int nFileIn, unsigned int nBlockPosIn, unsigned int nTxPosIn)\n {\n nFile = nFileIn;\n nBlockPos = nBlockPosIn;\n nTxPos = nTxPosIn;\n }\n\n IMPLEMENT_SERIALIZE( READWRITE(FLATDATA(*this)); )\n void SetNull() { nFile = (unsigned int) -1; nBlockPos = 0; nTxPos = 0; }\n bool IsNull() const { return (nFile == (unsigned int) -1); }\n\n friend bool operator==(const CDiskTxPos& a, const CDiskTxPos& b)\n {\n return (a.nFile == b.nFile &&\n a.nBlockPos == b.nBlockPos &&\n a.nTxPos == b.nTxPos);\n }\n\n friend bool operator!=(const CDiskTxPos& a, const CDiskTxPos& b)\n {\n return !(a == b);\n }\n\n\n std::string ToString() const\n {\n if (IsNull())\n return \"null\";\n else\n return strprintf(\"(nFile=%u, nBlockPos=%u, nTxPos=%u)\", nFile, nBlockPos, nTxPos);\n }\n\n void print() const\n {\n printf(\"%s\", ToString().c_str());\n }\n};\n\n\n\n/** A txdb record that contains the disk location of a transaction and the\n * locations of transactions that spend its outputs. vSpent is really only\n * used as a flag, but having the location is very helpful for debugging.\n */\nclass CTxIndex\n{\npublic:\n CDiskTxPos pos;\n std::vector<CDiskTxPos> vSpent;\n\n CTxIndex()\n {\n SetNull();\n }\n\n CTxIndex(const CDiskTxPos& posIn, unsigned int nOutputs)\n {\n pos = posIn;\n vSpent.resize(nOutputs);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n READWRITE(pos);\n READWRITE(vSpent);\n )\n\n void SetNull()\n {\n pos.SetNull();\n vSpent.clear();\n }\n\n bool IsNull()\n {\n return pos.IsNull();\n }\n\n friend bool operator==(const CTxIndex& a, const CTxIndex& b)\n {\n return (a.pos == b.pos &&\n a.vSpent == b.vSpent);\n }\n\n friend bool operator!=(const CTxIndex& a, const CTxIndex& b)\n {\n return !(a == b);\n }\n int GetDepthInMainChain() const;\n\n};\n\n/** The block chain is a tree shaped structure starting with the\n * genesis block at the root, with each block potentially having multiple\n * candidates to be the next block. pprev and pnext link a path through the\n * main/longest chain. A blockindex may have multiple pprev pointing back\n * to it, but pnext will only point forward to the longest branch, or will\n * be null if the block is not part of the longest chain.\n */\nclass CBlockIndex\n{\npublic:\n const uint256* phashBlock;\n CBlockIndex* pprev;\n CBlockIndex* pnext;\n unsigned int nFile;\n unsigned int nBlockPos;\n uint256 nChainTrust; // ppcoin: trust score of block chain\n int nHeight;\n\n int64 nMint;\n int64 nMoneySupply;\n\n unsigned int nFlags; // ppcoin: block index flags\n enum\n {\n BLOCK_PROOF_OF_STAKE = (1 << 0), // is proof-of-stake block\n BLOCK_STAKE_ENTROPY = (1 << 1), // entropy bit for stake modifier\n BLOCK_STAKE_MODIFIER = (1 << 2), // regenerated stake modifier\n };\n\n uint64 nStakeModifier; // hash modifier for proof-of-stake\n unsigned int nStakeModifierChecksum; // checksum of index; in-memeory only\n\n // proof-of-stake specific fields\n COutPoint prevoutStake;\n unsigned int nStakeTime;\n uint256 hashProofOfStake;\n\n // block header\n int nVersion;\n uint256 hashMerkleRoot;\n unsigned int nTime;\n unsigned int nBits;\n unsigned int nNonce;\n\n CBlockIndex()\n {\n phashBlock = NULL;\n pprev = NULL;\n pnext = NULL;\n nFile = 0;\n nBlockPos = 0;\n nHeight = 0;\n nChainTrust = 0;\n nMint = 0;\n nMoneySupply = 0;\n nFlags = 0;\n nStakeModifier = 0;\n nStakeModifierChecksum = 0;\n hashProofOfStake = 0;\n prevoutStake.SetNull();\n nStakeTime = 0;\n\n nVersion = 0;\n hashMerkleRoot = 0;\n nTime = 0;\n nBits = 0;\n nNonce = 0;\n }\n\n CBlockIndex(unsigned int nFileIn, unsigned int nBlockPosIn, CBlock& block);\n\n CBlock GetBlockHeader() const;\n uint256 GetBlockHash() const;\n int64 GetBlockTime() const;\n uint256 GetBlockTrust() const;\n bool IsInMainChain() const;\n bool CheckIndex() const;\n\n enum { nMedianTimeSpan=11 };\n\n int64 GetMedianTimePast() const;\n\n int64 GetMedianTime() const;\n /**\n * Returns true if there are nRequired or more blocks of minVersion or above\n * in the last nToCheck blocks, starting at pstart and going backwards.\n */\n bool IsSuperMajority(int minVersion, const CBlockIndex* pstart,\n unsigned int nRequired, unsigned int nToCheck);\n\n\n bool IsProofOfWork() const;\n bool IsProofOfStake() const;\n void SetProofOfStake();\n unsigned int GetStakeEntropyBit() const;\n bool SetStakeEntropyBit(unsigned int nEntropyBit);\n bool GeneratedStakeModifier() const;\n void SetStakeModifier(uint64 nModifier, bool fGeneratedStakeModifier);\n std::string ToString() const;\n void print() const;\n};\n\n\n\n/** Used to marshal pointers into hashes for db storage. */\nclass CDiskBlockIndex : public CBlockIndex\n{\npublic:\n uint256 hashPrev;\n uint256 hashNext;\n\n CDiskBlockIndex()\n {\n hashPrev = 0;\n hashNext = 0;\n }\n\n explicit CDiskBlockIndex(CBlockIndex* pindex) : CBlockIndex(*pindex)\n {\n hashPrev = (pprev ? pprev->GetBlockHash() : 0);\n hashNext = (pnext ? pnext->GetBlockHash() : 0);\n }\n\n IMPLEMENT_SERIALIZE\n (\n if (!(nType & SER_GETHASH))\n READWRITE(nVersion);\n\n READWRITE(hashNext);\n READWRITE(nFile);\n READWRITE(nBlockPos);\n READWRITE(nHeight);\n READWRITE(nMint);\n READWRITE(nMoneySupply);\n READWRITE(nFlags);\n READWRITE(nStakeModifier);\n if (IsProofOfStake())\n {\n READWRITE(prevoutStake);\n READWRITE(nStakeTime);\n READWRITE(hashProofOfStake);\n }\n else if (fRead)\n {\n const_cast<CDiskBlockIndex*>(this)->prevoutStake.SetNull();\n const_cast<CDiskBlockIndex*>(this)->nStakeTime = 0;\n const_cast<CDiskBlockIndex*>(this)->hashProofOfStake = 0;\n }\n\n // block header\n READWRITE(this->nVersion);\n READWRITE(hashPrev);\n READWRITE(hashMerkleRoot);\n READWRITE(nTime);\n READWRITE(nBits);\n READWRITE(nNonce);\n )\n\n uint256 GetBlockHash() const\n {\n CBlock block;\n block.nVersion = nVersion;\n block.hashPrevBlock = hashPrev;\n block.hashMerkleRoot = hashMerkleRoot;\n block.nTime = nTime;\n block.nBits = nBits;\n block.nNonce = nNonce;\n return block.GetHash();\n }\n\n\n std::string ToString() const\n {\n std::string str = \"CDiskBlockIndex(\";\n str += CBlockIndex::ToString();\n str += strprintf(\"\\n hashBlock=%s, hashPrev=%s, hashNext=%s)\",\n GetBlockHash().ToString().c_str(),\n hashPrev.ToString().c_str(),\n hashNext.ToString().c_str());\n return str;\n }\n\n void print() const\n {\n printf(\"%s\\n\", ToString().c_str());\n }\n};\n\n\n\n#endif // INDEX_H\n"}
80,509
c
/* GTK - The GIMP Toolkit * Copyright (C) 2007 Red Hat, Inc. * * Authors: * - <NAME> <<EMAIL>> * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. */ /* * Modified by the GTK+ Team and others 2007. See the AUTHORS * file for a list of people on the GTK+ Team. See the ChangeLog * files for a list of changes. These files are distributed with * GTK+ at ftp://ftp.gtk.org/pub/gtk/. */ #include "config.h" #include "gtkvolumebutton.h" #include "gtkadjustment.h" #include "gtkintl.h" #include "gtktooltip.h" /** * SECTION:gtkvolumebutton * @Short_description: A button which pops up a volume control * @Title: GtkVolumeButton * * #GtkVolumeButton is a subclass of #GtkScaleButton that has * been tailored for use as a volume control widget with suitable * icons, tooltips and accessible labels. */ #define EPSILON (1e-10) static const gchar * const icons[] = { "audio-volume-muted", "audio-volume-high", "audio-volume-low", "audio-volume-medium", NULL }; static const gchar * const icons_symbolic[] = { "audio-volume-muted-symbolic", "audio-volume-high-symbolic", "audio-volume-low-symbolic", "audio-volume-medium-symbolic", NULL }; enum { PROP_0, PROP_SYMBOLIC }; static gboolean cb_query_tooltip (GtkWidget *button, gint x, gint y, gboolean keyboard_mode, GtkTooltip *tooltip, gpointer user_data); static void cb_value_changed (GtkVolumeButton *button, gdouble value, gpointer user_data); G_DEFINE_TYPE (GtkVolumeButton, gtk_volume_button, GTK_TYPE_SCALE_BUTTON) static void gtk_volume_button_set_property (GObject *object, guint prop_id, const GValue *value, GParamSpec *pspec) { GtkScaleButton *button = GTK_SCALE_BUTTON (object); switch (prop_id) { case PROP_SYMBOLIC: if (g_value_get_boolean (value)) gtk_scale_button_set_icons (button, (const char **) icons_symbolic); else gtk_scale_button_set_icons (button, (const char **) icons); break; default: G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); break; } } static void gtk_volume_button_get_property (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec) { switch (prop_id) { case PROP_SYMBOLIC: { char **icon_list; g_object_get (object, "icons", &icon_list, NULL); if (icon_list != NULL && icon_list[0] != NULL && g_str_equal (icon_list[0], icons_symbolic[0])) g_value_set_boolean (value, TRUE); else g_value_set_boolean (value, FALSE); g_strfreev (icon_list); break; } default: G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); break; } } static void gtk_volume_button_class_init (GtkVolumeButtonClass *klass) { GObjectClass *gobject_class = G_OBJECT_CLASS (klass); GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass); gobject_class->set_property = gtk_volume_button_set_property; gobject_class->get_property = gtk_volume_button_get_property; /** * GtkVolumeButton:use-symbolic: * * Whether to use symbolic icons as the icons. Note that * if the symbolic icons are not available in your installed * theme, then the normal (potentially colorful) icons will * be used. * * Since: 3.0 */ g_object_class_install_property (gobject_class, PROP_SYMBOLIC, g_param_spec_boolean ("use-symbolic", P_("Use symbolic icons"), P_("Whether to use symbolic icons"), TRUE, G_PARAM_READWRITE|G_PARAM_CONSTRUCT)); /* Bind class to template */ gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/ui/gtkvolumebutton.ui"); gtk_widget_class_bind_template_callback (widget_class, cb_query_tooltip); gtk_widget_class_bind_template_callback (widget_class, cb_value_changed); } static void gtk_volume_button_init (GtkVolumeButton *button) { GtkWidget *widget = GTK_WIDGET (button); gtk_widget_init_template (widget); /* The atk action description is not supported by GtkBuilder */ atk_action_set_description (ATK_ACTION (gtk_widget_get_accessible (GTK_WIDGET (widget))), 1, _("Adjusts the volume")); } /** * gtk_volume_button_new: * * Creates a #GtkVolumeButton, with a range between 0.0 and 1.0, with * a stepping of 0.02. Volume values can be obtained and modified using * the functions from #GtkScaleButton. * * Returns: a new #GtkVolumeButton * * Since: 2.12 */ GtkWidget * gtk_volume_button_new (void) { GObject *button; button = g_object_new (GTK_TYPE_VOLUME_BUTTON, NULL); return GTK_WIDGET (button); } static gboolean cb_query_tooltip (GtkWidget *button, gint x, gint y, gboolean keyboard_mode, GtkTooltip *tooltip, gpointer user_data) { GtkScaleButton *scale_button = GTK_SCALE_BUTTON (button); GtkAdjustment *adjustment; gdouble val; char *str; AtkImage *image; image = ATK_IMAGE (gtk_widget_get_accessible (button)); adjustment = gtk_scale_button_get_adjustment (scale_button); val = gtk_scale_button_get_value (scale_button); if (val < (gtk_adjustment_get_lower (adjustment) + EPSILON)) { str = g_strdup (_("Muted")); } else if (val >= (gtk_adjustment_get_upper (adjustment) - EPSILON)) { str = g_strdup (_("Full Volume")); } else { int percent; percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5); /* Translators: this is the percentage of the current volume, * as used in the tooltip, eg. "49 %". * Translate the "%d" to "%Id" if you want to use localised digits, * or otherwise translate the "%d" to "%d". */ str = g_strdup_printf (C_("volume percentage", "%d %%"), percent); } gtk_tooltip_set_text (tooltip, str); atk_image_set_image_description (image, str); g_free (str); return TRUE; } static void cb_value_changed (GtkVolumeButton *button, gdouble value, gpointer user_data) { gtk_widget_trigger_tooltip_query (GTK_WIDGET (button)); }
32.15
219
(translation_unit) "/* GTK - The GIMP Toolkit\n * Copyright (C) 2007 Red Hat, Inc.\n *\n * Authors:\n * - <NAME> <<EMAIL>>\n *\n * This library is free software; you can redistribute it and/or\n * modify it under the terms of the GNU Lesser General Public\n * License as published by the Free Software Foundation; either\n * version 2 of the License, or (at your option) any later version.\n *\n * This library is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n * Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public\n * License along with this library. If not, see <http://www.gnu.org/licenses/>.\n */\n\n/*\n * Modified by the GTK+ Team and others 2007. See the AUTHORS\n * file for a list of people on the GTK+ Team. See the ChangeLog\n * files for a list of changes. These files are distributed with\n * GTK+ at ftp://ftp.gtk.org/pub/gtk/.\n */\n\n#include "config.h"\n\n#include "gtkvolumebutton.h"\n\n#include "gtkadjustment.h"\n#include "gtkintl.h"\n#include "gtktooltip.h"\n\n\n/**\n * SECTION:gtkvolumebutton\n * @Short_description: A button which pops up a volume control\n * @Title: GtkVolumeButton\n *\n * #GtkVolumeButton is a subclass of #GtkScaleButton that has\n * been tailored for use as a volume control widget with suitable\n * icons, tooltips and accessible labels.\n */\n\n#define EPSILON (1e-10)\n\nstatic const gchar * const icons[] =\n{\n "audio-volume-muted",\n "audio-volume-high",\n "audio-volume-low",\n "audio-volume-medium",\n NULL\n};\n\nstatic const gchar * const icons_symbolic[] =\n{\n "audio-volume-muted-symbolic",\n "audio-volume-high-symbolic",\n "audio-volume-low-symbolic",\n "audio-volume-medium-symbolic",\n NULL\n};\n\nenum\n{\n PROP_0,\n PROP_SYMBOLIC\n};\n\nstatic gboolean cb_query_tooltip (GtkWidget *button,\n gint x,\n gint y,\n gboolean keyboard_mode,\n GtkTooltip *tooltip,\n gpointer user_data);\nstatic void cb_value_changed (GtkVolumeButton *button,\n gdouble value,\n gpointer user_data);\n\nG_DEFINE_TYPE (GtkVolumeButton, gtk_volume_button, GTK_TYPE_SCALE_BUTTON)\n\nstatic void\ngtk_volume_button_set_property (GObject *object,\n guint prop_id,\n const GValue *value,\n GParamSpec *pspec)\n{\n GtkScaleButton *button = GTK_SCALE_BUTTON (object);\n\n switch (prop_id)\n {\n case PROP_SYMBOLIC:\n if (g_value_get_boolean (value))\n gtk_scale_button_set_icons (button, (const char **) icons_symbolic);\n else\n gtk_scale_button_set_icons (button, (const char **) icons);\n break;\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }\n}\n\nstatic void\ngtk_volume_button_get_property (GObject *object,\n guint prop_id,\n GValue *value,\n GParamSpec *pspec)\n{\n switch (prop_id)\n {\n case PROP_SYMBOLIC: {\n char **icon_list;\n\n g_object_get (object, "icons", &icon_list, NULL);\n if (icon_list != NULL &&\n icon_list[0] != NULL &&\n g_str_equal (icon_list[0], icons_symbolic[0]))\n g_value_set_boolean (value, TRUE);\n else\n g_value_set_boolean (value, FALSE);\n g_strfreev (icon_list);\n break;\n }\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }\n}\n\nstatic void\ngtk_volume_button_class_init (GtkVolumeButtonClass *klass)\n{\n GObjectClass *gobject_class = G_OBJECT_CLASS (klass);\n GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);\n\n gobject_class->set_property = gtk_volume_button_set_property;\n gobject_class->get_property = gtk_volume_button_get_property;\n\n /**\n * GtkVolumeButton:use-symbolic:\n *\n * Whether to use symbolic icons as the icons. Note that\n * if the symbolic icons are not available in your installed\n * theme, then the normal (potentially colorful) icons will\n * be used.\n *\n * Since: 3.0\n */\n g_object_class_install_property (gobject_class,\n PROP_SYMBOLIC,\n g_param_spec_boolean ("use-symbolic",\n P_("Use symbolic icons"),\n P_("Whether to use symbolic icons"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT));\n\n /* Bind class to template\n */\n gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/ui/gtkvolumebutton.ui");\n gtk_widget_class_bind_template_callback (widget_class, cb_query_tooltip);\n gtk_widget_class_bind_template_callback (widget_class, cb_value_changed);\n}\n\nstatic void\ngtk_volume_button_init (GtkVolumeButton *button)\n{\n GtkWidget *widget = GTK_WIDGET (button);\n\n gtk_widget_init_template (widget);\n\n /* The atk action description is not supported by GtkBuilder */\n atk_action_set_description (ATK_ACTION (gtk_widget_get_accessible (GTK_WIDGET (widget))),\n 1, _("Adjusts the volume"));\n}\n\n/**\n * gtk_volume_button_new:\n *\n * Creates a #GtkVolumeButton, with a range between 0.0 and 1.0, with\n * a stepping of 0.02. Volume values can be obtained and modified using\n * the functions from #GtkScaleButton.\n *\n * Returns: a new #GtkVolumeButton\n *\n * Since: 2.12\n */\nGtkWidget *\ngtk_volume_button_new (void)\n{\n GObject *button;\n button = g_object_new (GTK_TYPE_VOLUME_BUTTON, NULL);\n return GTK_WIDGET (button);\n}\n\nstatic gboolean\ncb_query_tooltip (GtkWidget *button,\n gint x,\n gint y,\n gboolean keyboard_mode,\n GtkTooltip *tooltip,\n gpointer user_data)\n{\n GtkScaleButton *scale_button = GTK_SCALE_BUTTON (button);\n GtkAdjustment *adjustment;\n gdouble val;\n char *str;\n AtkImage *image;\n\n image = ATK_IMAGE (gtk_widget_get_accessible (button));\n\n adjustment = gtk_scale_button_get_adjustment (scale_button);\n val = gtk_scale_button_get_value (scale_button);\n\n if (val < (gtk_adjustment_get_lower (adjustment) + EPSILON))\n {\n str = g_strdup (_("Muted"));\n }\n else if (val >= (gtk_adjustment_get_upper (adjustment) - EPSILON))\n {\n str = g_strdup (_("Full Volume"));\n }\n else\n {\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. "49 %".\n * Translate the "%d" to "%Id" if you want to use localised digits,\n * or otherwise translate the "%d" to "%d".\n */\n str = g_strdup_printf (C_("volume percentage", "%d %%"), percent);\n }\n\n gtk_tooltip_set_text (tooltip, str);\n atk_image_set_image_description (image, str);\n g_free (str);\n\n return TRUE;\n}\n\nstatic void\ncb_value_changed (GtkVolumeButton *button, gdouble value, gpointer user_data)\n{\n gtk_widget_trigger_tooltip_query (GTK_WIDGET (button));\n}\n" (comment) "/* GTK - The GIMP Toolkit\n * Copyright (C) 2007 Red Hat, Inc.\n *\n * Authors:\n * - <NAME> <<EMAIL>>\n *\n * This library is free software; you can redistribute it and/or\n * modify it under the terms of the GNU Lesser General Public\n * License as published by the Free Software Foundation; either\n * version 2 of the License, or (at your option) any later version.\n *\n * This library is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n * Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public\n * License along with this library. If not, see <http://www.gnu.org/licenses/>.\n */" (comment) "/*\n * Modified by the GTK+ Team and others 2007. See the AUTHORS\n * file for a list of people on the GTK+ Team. See the ChangeLog\n * files for a list of changes. These files are distributed with\n * GTK+ at ftp://ftp.gtk.org/pub/gtk/.\n */" (preproc_include) "#include "config.h"\n" (#include) "#include" (string_literal) ""config.h"" (") """ (string_content) "config.h" (") """ (preproc_include) "#include "gtkvolumebutton.h"\n" (#include) "#include" (string_literal) ""gtkvolumebutton.h"" (") """ (string_content) "gtkvolumebutton.h" (") """ (preproc_include) "#include "gtkadjustment.h"\n" (#include) "#include" (string_literal) ""gtkadjustment.h"" (") """ (string_content) "gtkadjustment.h" (") """ (preproc_include) "#include "gtkintl.h"\n" (#include) "#include" (string_literal) ""gtkintl.h"" (") """ (string_content) "gtkintl.h" (") """ (preproc_include) "#include "gtktooltip.h"\n" (#include) "#include" (string_literal) ""gtktooltip.h"" (") """ (string_content) "gtktooltip.h" (") """ (comment) "/**\n * SECTION:gtkvolumebutton\n * @Short_description: A button which pops up a volume control\n * @Title: GtkVolumeButton\n *\n * #GtkVolumeButton is a subclass of #GtkScaleButton that has\n * been tailored for use as a volume control widget with suitable\n * icons, tooltips and accessible labels.\n */" (preproc_def) "#define EPSILON (1e-10)\n" (#define) "#define" (identifier) "EPSILON" (preproc_arg) "(1e-10)" (declaration) "static const gchar * const icons[] =\n{\n "audio-volume-muted",\n "audio-volume-high",\n "audio-volume-low",\n "audio-volume-medium",\n NULL\n};" (storage_class_specifier) "static" (static) "static" (type_qualifier) "const" (const) "const" (type_identifier) "gchar" (init_declarator) "* const icons[] =\n{\n "audio-volume-muted",\n "audio-volume-high",\n "audio-volume-low",\n "audio-volume-medium",\n NULL\n}" (pointer_declarator) "* const icons[]" (*) "*" (type_qualifier) "const" (const) "const" (array_declarator) "icons[]" (identifier) "icons" ([) "[" (]) "]" (=) "=" (initializer_list) "{\n "audio-volume-muted",\n "audio-volume-high",\n "audio-volume-low",\n "audio-volume-medium",\n NULL\n}" ({) "{" (string_literal) ""audio-volume-muted"" (") """ (string_content) "audio-volume-muted" (") """ (,) "," (string_literal) ""audio-volume-high"" (") """ (string_content) "audio-volume-high" (") """ (,) "," (string_literal) ""audio-volume-low"" (") """ (string_content) "audio-volume-low" (") """ (,) "," (string_literal) ""audio-volume-medium"" (") """ (string_content) "audio-volume-medium" (") """ (,) "," (null) "NULL" (NULL) "NULL" (}) "}" (;) ";" (declaration) "static const gchar * const icons_symbolic[] =\n{\n "audio-volume-muted-symbolic",\n "audio-volume-high-symbolic",\n "audio-volume-low-symbolic",\n "audio-volume-medium-symbolic",\n NULL\n};" (storage_class_specifier) "static" (static) "static" (type_qualifier) "const" (const) "const" (type_identifier) "gchar" (init_declarator) "* const icons_symbolic[] =\n{\n "audio-volume-muted-symbolic",\n "audio-volume-high-symbolic",\n "audio-volume-low-symbolic",\n "audio-volume-medium-symbolic",\n NULL\n}" (pointer_declarator) "* const icons_symbolic[]" (*) "*" (type_qualifier) "const" (const) "const" (array_declarator) "icons_symbolic[]" (identifier) "icons_symbolic" ([) "[" (]) "]" (=) "=" (initializer_list) "{\n "audio-volume-muted-symbolic",\n "audio-volume-high-symbolic",\n "audio-volume-low-symbolic",\n "audio-volume-medium-symbolic",\n NULL\n}" ({) "{" (string_literal) ""audio-volume-muted-symbolic"" (") """ (string_content) "audio-volume-muted-symbolic" (") """ (,) "," (string_literal) ""audio-volume-high-symbolic"" (") """ (string_content) "audio-volume-high-symbolic" (") """ (,) "," (string_literal) ""audio-volume-low-symbolic"" (") """ (string_content) "audio-volume-low-symbolic" (") """ (,) "," (string_literal) ""audio-volume-medium-symbolic"" (") """ (string_content) "audio-volume-medium-symbolic" (") """ (,) "," (null) "NULL" (NULL) "NULL" (}) "}" (;) ";" (enum_specifier) "enum\n{\n PROP_0,\n PROP_SYMBOLIC\n}" (enum) "enum" (enumerator_list) "{\n PROP_0,\n PROP_SYMBOLIC\n}" ({) "{" (enumerator) "PROP_0" (identifier) "PROP_0" (,) "," (enumerator) "PROP_SYMBOLIC" (identifier) "PROP_SYMBOLIC" (}) "}" (;) ";" (declaration) "static gboolean cb_query_tooltip (GtkWidget *button,\n gint x,\n gint y,\n gboolean keyboard_mode,\n GtkTooltip *tooltip,\n gpointer user_data);" (storage_class_specifier) "static" (static) "static" (type_identifier) "gboolean" (function_declarator) "cb_query_tooltip (GtkWidget *button,\n gint x,\n gint y,\n gboolean keyboard_mode,\n GtkTooltip *tooltip,\n gpointer user_data)" (identifier) "cb_query_tooltip" (parameter_list) "(GtkWidget *button,\n gint x,\n gint y,\n gboolean keyboard_mode,\n GtkTooltip *tooltip,\n gpointer user_data)" (() "(" (parameter_declaration) "GtkWidget *button" (type_identifier) "GtkWidget" (pointer_declarator) "*button" (*) "*" (identifier) "button" (,) "," (parameter_declaration) "gint x" (type_identifier) "gint" (identifier) "x" (,) "," (parameter_declaration) "gint y" (type_identifier) "gint" (identifier) "y" (,) "," (parameter_declaration) "gboolean keyboard_mode" (type_identifier) "gboolean" (identifier) "keyboard_mode" (,) "," (parameter_declaration) "GtkTooltip *tooltip" (type_identifier) "GtkTooltip" (pointer_declarator) "*tooltip" (*) "*" (identifier) "tooltip" (,) "," (parameter_declaration) "gpointer user_data" (type_identifier) "gpointer" (identifier) "user_data" ()) ")" (;) ";" (declaration) "static void cb_value_changed (GtkVolumeButton *button,\n gdouble value,\n gpointer user_data);" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "cb_value_changed (GtkVolumeButton *button,\n gdouble value,\n gpointer user_data)" (identifier) "cb_value_changed" (parameter_list) "(GtkVolumeButton *button,\n gdouble value,\n gpointer user_data)" (() "(" (parameter_declaration) "GtkVolumeButton *button" (type_identifier) "GtkVolumeButton" (pointer_declarator) "*button" (*) "*" (identifier) "button" (,) "," (parameter_declaration) "gdouble value" (type_identifier) "gdouble" (identifier) "value" (,) "," (parameter_declaration) "gpointer user_data" (type_identifier) "gpointer" (identifier) "user_data" ()) ")" (;) ";" (expression_statement) "G_DEFINE_TYPE (GtkVolumeButton, gtk_volume_button, GTK_TYPE_SCALE_BUTTON)" (call_expression) "G_DEFINE_TYPE (GtkVolumeButton, gtk_volume_button, GTK_TYPE_SCALE_BUTTON)" (identifier) "G_DEFINE_TYPE" (argument_list) "(GtkVolumeButton, gtk_volume_button, GTK_TYPE_SCALE_BUTTON)" (() "(" (identifier) "GtkVolumeButton" (,) "," (identifier) "gtk_volume_button" (,) "," (identifier) "GTK_TYPE_SCALE_BUTTON" ()) ")" (;) "" (function_definition) "static void\ngtk_volume_button_set_property (GObject *object,\n guint prop_id,\n const GValue *value,\n GParamSpec *pspec)\n{\n GtkScaleButton *button = GTK_SCALE_BUTTON (object);\n\n switch (prop_id)\n {\n case PROP_SYMBOLIC:\n if (g_value_get_boolean (value))\n gtk_scale_button_set_icons (button, (const char **) icons_symbolic);\n else\n gtk_scale_button_set_icons (button, (const char **) icons);\n break;\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "gtk_volume_button_set_property (GObject *object,\n guint prop_id,\n const GValue *value,\n GParamSpec *pspec)" (identifier) "gtk_volume_button_set_property" (parameter_list) "(GObject *object,\n guint prop_id,\n const GValue *value,\n GParamSpec *pspec)" (() "(" (parameter_declaration) "GObject *object" (type_identifier) "GObject" (pointer_declarator) "*object" (*) "*" (identifier) "object" (,) "," (parameter_declaration) "guint prop_id" (type_identifier) "guint" (identifier) "prop_id" (,) "," (parameter_declaration) "const GValue *value" (type_qualifier) "const" (const) "const" (type_identifier) "GValue" (pointer_declarator) "*value" (*) "*" (identifier) "value" (,) "," (parameter_declaration) "GParamSpec *pspec" (type_identifier) "GParamSpec" (pointer_declarator) "*pspec" (*) "*" (identifier) "pspec" ()) ")" (compound_statement) "{\n GtkScaleButton *button = GTK_SCALE_BUTTON (object);\n\n switch (prop_id)\n {\n case PROP_SYMBOLIC:\n if (g_value_get_boolean (value))\n gtk_scale_button_set_icons (button, (const char **) icons_symbolic);\n else\n gtk_scale_button_set_icons (button, (const char **) icons);\n break;\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }\n}" ({) "{" (declaration) "GtkScaleButton *button = GTK_SCALE_BUTTON (object);" (type_identifier) "GtkScaleButton" (init_declarator) "*button = GTK_SCALE_BUTTON (object)" (pointer_declarator) "*button" (*) "*" (identifier) "button" (=) "=" (call_expression) "GTK_SCALE_BUTTON (object)" (identifier) "GTK_SCALE_BUTTON" (argument_list) "(object)" (() "(" (identifier) "object" ()) ")" (;) ";" (switch_statement) "switch (prop_id)\n {\n case PROP_SYMBOLIC:\n if (g_value_get_boolean (value))\n gtk_scale_button_set_icons (button, (const char **) icons_symbolic);\n else\n gtk_scale_button_set_icons (button, (const char **) icons);\n break;\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }" (switch) "switch" (parenthesized_expression) "(prop_id)" (() "(" (identifier) "prop_id" ()) ")" (compound_statement) "{\n case PROP_SYMBOLIC:\n if (g_value_get_boolean (value))\n gtk_scale_button_set_icons (button, (const char **) icons_symbolic);\n else\n gtk_scale_button_set_icons (button, (const char **) icons);\n break;\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }" ({) "{" (case_statement) "case PROP_SYMBOLIC:\n if (g_value_get_boolean (value))\n gtk_scale_button_set_icons (button, (const char **) icons_symbolic);\n else\n gtk_scale_button_set_icons (button, (const char **) icons);\n break;" (case) "case" (identifier) "PROP_SYMBOLIC" (:) ":" (if_statement) "if (g_value_get_boolean (value))\n gtk_scale_button_set_icons (button, (const char **) icons_symbolic);\n else\n gtk_scale_button_set_icons (button, (const char **) icons);" (if) "if" (parenthesized_expression) "(g_value_get_boolean (value))" (() "(" (call_expression) "g_value_get_boolean (value)" (identifier) "g_value_get_boolean" (argument_list) "(value)" (() "(" (identifier) "value" ()) ")" ()) ")" (expression_statement) "gtk_scale_button_set_icons (button, (const char **) icons_symbolic);" (call_expression) "gtk_scale_button_set_icons (button, (const char **) icons_symbolic)" (identifier) "gtk_scale_button_set_icons" (argument_list) "(button, (const char **) icons_symbolic)" (() "(" (identifier) "button" (,) "," (cast_expression) "(const char **) icons_symbolic" (() "(" (type_descriptor) "const char **" (type_qualifier) "const" (const) "const" (primitive_type) "char" (abstract_pointer_declarator) "**" (*) "*" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "icons_symbolic" ()) ")" (;) ";" (else_clause) "else\n gtk_scale_button_set_icons (button, (const char **) icons);" (else) "else" (expression_statement) "gtk_scale_button_set_icons (button, (const char **) icons);" (call_expression) "gtk_scale_button_set_icons (button, (const char **) icons)" (identifier) "gtk_scale_button_set_icons" (argument_list) "(button, (const char **) icons)" (() "(" (identifier) "button" (,) "," (cast_expression) "(const char **) icons" (() "(" (type_descriptor) "const char **" (type_qualifier) "const" (const) "const" (primitive_type) "char" (abstract_pointer_declarator) "**" (*) "*" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "icons" ()) ")" (;) ";" (break_statement) "break;" (break) "break" (;) ";" (case_statement) "default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;" (default) "default" (:) ":" (expression_statement) "G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);" (call_expression) "G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec)" (identifier) "G_OBJECT_WARN_INVALID_PROPERTY_ID" (argument_list) "(object, prop_id, pspec)" (() "(" (identifier) "object" (,) "," (identifier) "prop_id" (,) "," (identifier) "pspec" ()) ")" (;) ";" (break_statement) "break;" (break) "break" (;) ";" (}) "}" (}) "}" (function_definition) "static void\ngtk_volume_button_get_property (GObject *object,\n guint prop_id,\n GValue *value,\n GParamSpec *pspec)\n{\n switch (prop_id)\n {\n case PROP_SYMBOLIC: {\n char **icon_list;\n\n g_object_get (object, "icons", &icon_list, NULL);\n if (icon_list != NULL &&\n icon_list[0] != NULL &&\n g_str_equal (icon_list[0], icons_symbolic[0]))\n g_value_set_boolean (value, TRUE);\n else\n g_value_set_boolean (value, FALSE);\n g_strfreev (icon_list);\n break;\n }\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "gtk_volume_button_get_property (GObject *object,\n guint prop_id,\n GValue *value,\n GParamSpec *pspec)" (identifier) "gtk_volume_button_get_property" (parameter_list) "(GObject *object,\n guint prop_id,\n GValue *value,\n GParamSpec *pspec)" (() "(" (parameter_declaration) "GObject *object" (type_identifier) "GObject" (pointer_declarator) "*object" (*) "*" (identifier) "object" (,) "," (parameter_declaration) "guint prop_id" (type_identifier) "guint" (identifier) "prop_id" (,) "," (parameter_declaration) "GValue *value" (type_identifier) "GValue" (pointer_declarator) "*value" (*) "*" (identifier) "value" (,) "," (parameter_declaration) "GParamSpec *pspec" (type_identifier) "GParamSpec" (pointer_declarator) "*pspec" (*) "*" (identifier) "pspec" ()) ")" (compound_statement) "{\n switch (prop_id)\n {\n case PROP_SYMBOLIC: {\n char **icon_list;\n\n g_object_get (object, "icons", &icon_list, NULL);\n if (icon_list != NULL &&\n icon_list[0] != NULL &&\n g_str_equal (icon_list[0], icons_symbolic[0]))\n g_value_set_boolean (value, TRUE);\n else\n g_value_set_boolean (value, FALSE);\n g_strfreev (icon_list);\n break;\n }\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }\n}" ({) "{" (switch_statement) "switch (prop_id)\n {\n case PROP_SYMBOLIC: {\n char **icon_list;\n\n g_object_get (object, "icons", &icon_list, NULL);\n if (icon_list != NULL &&\n icon_list[0] != NULL &&\n g_str_equal (icon_list[0], icons_symbolic[0]))\n g_value_set_boolean (value, TRUE);\n else\n g_value_set_boolean (value, FALSE);\n g_strfreev (icon_list);\n break;\n }\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }" (switch) "switch" (parenthesized_expression) "(prop_id)" (() "(" (identifier) "prop_id" ()) ")" (compound_statement) "{\n case PROP_SYMBOLIC: {\n char **icon_list;\n\n g_object_get (object, "icons", &icon_list, NULL);\n if (icon_list != NULL &&\n icon_list[0] != NULL &&\n g_str_equal (icon_list[0], icons_symbolic[0]))\n g_value_set_boolean (value, TRUE);\n else\n g_value_set_boolean (value, FALSE);\n g_strfreev (icon_list);\n break;\n }\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }" ({) "{" (case_statement) "case PROP_SYMBOLIC: {\n char **icon_list;\n\n g_object_get (object, "icons", &icon_list, NULL);\n if (icon_list != NULL &&\n icon_list[0] != NULL &&\n g_str_equal (icon_list[0], icons_symbolic[0]))\n g_value_set_boolean (value, TRUE);\n else\n g_value_set_boolean (value, FALSE);\n g_strfreev (icon_list);\n break;\n }" (case) "case" (identifier) "PROP_SYMBOLIC" (:) ":" (compound_statement) "{\n char **icon_list;\n\n g_object_get (object, "icons", &icon_list, NULL);\n if (icon_list != NULL &&\n icon_list[0] != NULL &&\n g_str_equal (icon_list[0], icons_symbolic[0]))\n g_value_set_boolean (value, TRUE);\n else\n g_value_set_boolean (value, FALSE);\n g_strfreev (icon_list);\n break;\n }" ({) "{" (declaration) "char **icon_list;" (primitive_type) "char" (pointer_declarator) "**icon_list" (*) "*" (pointer_declarator) "*icon_list" (*) "*" (identifier) "icon_list" (;) ";" (expression_statement) "g_object_get (object, "icons", &icon_list, NULL);" (call_expression) "g_object_get (object, "icons", &icon_list, NULL)" (identifier) "g_object_get" (argument_list) "(object, "icons", &icon_list, NULL)" (() "(" (identifier) "object" (,) "," (string_literal) ""icons"" (") """ (string_content) "icons" (") """ (,) "," (pointer_expression) "&icon_list" (&) "&" (identifier) "icon_list" (,) "," (null) "NULL" (NULL) "NULL" ()) ")" (;) ";" (if_statement) "if (icon_list != NULL &&\n icon_list[0] != NULL &&\n g_str_equal (icon_list[0], icons_symbolic[0]))\n g_value_set_boolean (value, TRUE);\n else\n g_value_set_boolean (value, FALSE);" (if) "if" (parenthesized_expression) "(icon_list != NULL &&\n icon_list[0] != NULL &&\n g_str_equal (icon_list[0], icons_symbolic[0]))" (() "(" (binary_expression) "icon_list != NULL &&\n icon_list[0] != NULL &&\n g_str_equal (icon_list[0], icons_symbolic[0])" (binary_expression) "icon_list != NULL &&\n icon_list[0] != NULL" (binary_expression) "icon_list != NULL" (identifier) "icon_list" (!=) "!=" (null) "NULL" (NULL) "NULL" (&&) "&&" (binary_expression) "icon_list[0] != NULL" (subscript_expression) "icon_list[0]" (identifier) "icon_list" ([) "[" (number_literal) "0" (]) "]" (!=) "!=" (null) "NULL" (NULL) "NULL" (&&) "&&" (call_expression) "g_str_equal (icon_list[0], icons_symbolic[0])" (identifier) "g_str_equal" (argument_list) "(icon_list[0], icons_symbolic[0])" (() "(" (subscript_expression) "icon_list[0]" (identifier) "icon_list" ([) "[" (number_literal) "0" (]) "]" (,) "," (subscript_expression) "icons_symbolic[0]" (identifier) "icons_symbolic" ([) "[" (number_literal) "0" (]) "]" ()) ")" ()) ")" (expression_statement) "g_value_set_boolean (value, TRUE);" (call_expression) "g_value_set_boolean (value, TRUE)" (identifier) "g_value_set_boolean" (argument_list) "(value, TRUE)" (() "(" (identifier) "value" (,) "," (true) "TRUE" ()) ")" (;) ";" (else_clause) "else\n g_value_set_boolean (value, FALSE);" (else) "else" (expression_statement) "g_value_set_boolean (value, FALSE);" (call_expression) "g_value_set_boolean (value, FALSE)" (identifier) "g_value_set_boolean" (argument_list) "(value, FALSE)" (() "(" (identifier) "value" (,) "," (false) "FALSE" ()) ")" (;) ";" (expression_statement) "g_strfreev (icon_list);" (call_expression) "g_strfreev (icon_list)" (identifier) "g_strfreev" (argument_list) "(icon_list)" (() "(" (identifier) "icon_list" ()) ")" (;) ";" (break_statement) "break;" (break) "break" (;) ";" (}) "}" (case_statement) "default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;" (default) "default" (:) ":" (expression_statement) "G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);" (call_expression) "G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec)" (identifier) "G_OBJECT_WARN_INVALID_PROPERTY_ID" (argument_list) "(object, prop_id, pspec)" (() "(" (identifier) "object" (,) "," (identifier) "prop_id" (,) "," (identifier) "pspec" ()) ")" (;) ";" (break_statement) "break;" (break) "break" (;) ";" (}) "}" (}) "}" (function_definition) "static void\ngtk_volume_button_class_init (GtkVolumeButtonClass *klass)\n{\n GObjectClass *gobject_class = G_OBJECT_CLASS (klass);\n GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);\n\n gobject_class->set_property = gtk_volume_button_set_property;\n gobject_class->get_property = gtk_volume_button_get_property;\n\n /**\n * GtkVolumeButton:use-symbolic:\n *\n * Whether to use symbolic icons as the icons. Note that\n * if the symbolic icons are not available in your installed\n * theme, then the normal (potentially colorful) icons will\n * be used.\n *\n * Since: 3.0\n */\n g_object_class_install_property (gobject_class,\n PROP_SYMBOLIC,\n g_param_spec_boolean ("use-symbolic",\n P_("Use symbolic icons"),\n P_("Whether to use symbolic icons"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT));\n\n /* Bind class to template\n */\n gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/ui/gtkvolumebutton.ui");\n gtk_widget_class_bind_template_callback (widget_class, cb_query_tooltip);\n gtk_widget_class_bind_template_callback (widget_class, cb_value_changed);\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "gtk_volume_button_class_init (GtkVolumeButtonClass *klass)" (identifier) "gtk_volume_button_class_init" (parameter_list) "(GtkVolumeButtonClass *klass)" (() "(" (parameter_declaration) "GtkVolumeButtonClass *klass" (type_identifier) "GtkVolumeButtonClass" (pointer_declarator) "*klass" (*) "*" (identifier) "klass" ()) ")" (compound_statement) "{\n GObjectClass *gobject_class = G_OBJECT_CLASS (klass);\n GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);\n\n gobject_class->set_property = gtk_volume_button_set_property;\n gobject_class->get_property = gtk_volume_button_get_property;\n\n /**\n * GtkVolumeButton:use-symbolic:\n *\n * Whether to use symbolic icons as the icons. Note that\n * if the symbolic icons are not available in your installed\n * theme, then the normal (potentially colorful) icons will\n * be used.\n *\n * Since: 3.0\n */\n g_object_class_install_property (gobject_class,\n PROP_SYMBOLIC,\n g_param_spec_boolean ("use-symbolic",\n P_("Use symbolic icons"),\n P_("Whether to use symbolic icons"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT));\n\n /* Bind class to template\n */\n gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/ui/gtkvolumebutton.ui");\n gtk_widget_class_bind_template_callback (widget_class, cb_query_tooltip);\n gtk_widget_class_bind_template_callback (widget_class, cb_value_changed);\n}" ({) "{" (declaration) "GObjectClass *gobject_class = G_OBJECT_CLASS (klass);" (type_identifier) "GObjectClass" (init_declarator) "*gobject_class = G_OBJECT_CLASS (klass)" (pointer_declarator) "*gobject_class" (*) "*" (identifier) "gobject_class" (=) "=" (call_expression) "G_OBJECT_CLASS (klass)" (identifier) "G_OBJECT_CLASS" (argument_list) "(klass)" (() "(" (identifier) "klass" ()) ")" (;) ";" (declaration) "GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);" (type_identifier) "GtkWidgetClass" (init_declarator) "*widget_class = GTK_WIDGET_CLASS (klass)" (pointer_declarator) "*widget_class" (*) "*" (identifier) "widget_class" (=) "=" (call_expression) "GTK_WIDGET_CLASS (klass)" (identifier) "GTK_WIDGET_CLASS" (argument_list) "(klass)" (() "(" (identifier) "klass" ()) ")" (;) ";" (expression_statement) "gobject_class->set_property = gtk_volume_button_set_property;" (assignment_expression) "gobject_class->set_property = gtk_volume_button_set_property" (field_expression) "gobject_class->set_property" (identifier) "gobject_class" (->) "->" (field_identifier) "set_property" (=) "=" (identifier) "gtk_volume_button_set_property" (;) ";" (expression_statement) "gobject_class->get_property = gtk_volume_button_get_property;" (assignment_expression) "gobject_class->get_property = gtk_volume_button_get_property" (field_expression) "gobject_class->get_property" (identifier) "gobject_class" (->) "->" (field_identifier) "get_property" (=) "=" (identifier) "gtk_volume_button_get_property" (;) ";" (comment) "/**\n * GtkVolumeButton:use-symbolic:\n *\n * Whether to use symbolic icons as the icons. Note that\n * if the symbolic icons are not available in your installed\n * theme, then the normal (potentially colorful) icons will\n * be used.\n *\n * Since: 3.0\n */" (expression_statement) "g_object_class_install_property (gobject_class,\n PROP_SYMBOLIC,\n g_param_spec_boolean ("use-symbolic",\n P_("Use symbolic icons"),\n P_("Whether to use symbolic icons"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT));" (call_expression) "g_object_class_install_property (gobject_class,\n PROP_SYMBOLIC,\n g_param_spec_boolean ("use-symbolic",\n P_("Use symbolic icons"),\n P_("Whether to use symbolic icons"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT))" (identifier) "g_object_class_install_property" (argument_list) "(gobject_class,\n PROP_SYMBOLIC,\n g_param_spec_boolean ("use-symbolic",\n P_("Use symbolic icons"),\n P_("Whether to use symbolic icons"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT))" (() "(" (identifier) "gobject_class" (,) "," (identifier) "PROP_SYMBOLIC" (,) "," (call_expression) "g_param_spec_boolean ("use-symbolic",\n P_("Use symbolic icons"),\n P_("Whether to use symbolic icons"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT)" (identifier) "g_param_spec_boolean" (argument_list) "("use-symbolic",\n P_("Use symbolic icons"),\n P_("Whether to use symbolic icons"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT)" (() "(" (string_literal) ""use-symbolic"" (") """ (string_content) "use-symbolic" (") """ (,) "," (call_expression) "P_("Use symbolic icons")" (identifier) "P_" (argument_list) "("Use symbolic icons")" (() "(" (string_literal) ""Use symbolic icons"" (") """ (string_content) "Use symbolic icons" (") """ ()) ")" (,) "," (call_expression) "P_("Whether to use symbolic icons")" (identifier) "P_" (argument_list) "("Whether to use symbolic icons")" (() "(" (string_literal) ""Whether to use symbolic icons"" (") """ (string_content) "Whether to use symbolic icons" (") """ ()) ")" (,) "," (true) "TRUE" (,) "," (binary_expression) "G_PARAM_READWRITE|G_PARAM_CONSTRUCT" (identifier) "G_PARAM_READWRITE" (|) "|" (identifier) "G_PARAM_CONSTRUCT" ()) ")" ()) ")" (;) ";" (comment) "/* Bind class to template\n */" (expression_statement) "gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/ui/gtkvolumebutton.ui");" (call_expression) "gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/ui/gtkvolumebutton.ui")" (identifier) "gtk_widget_class_set_template_from_resource" (argument_list) "(widget_class, "/org/gtk/libgtk/ui/gtkvolumebutton.ui")" (() "(" (identifier) "widget_class" (,) "," (string_literal) ""/org/gtk/libgtk/ui/gtkvolumebutton.ui"" (") """ (string_content) "/org/gtk/libgtk/ui/gtkvolumebutton.ui" (") """ ()) ")" (;) ";" (expression_statement) "gtk_widget_class_bind_template_callback (widget_class, cb_query_tooltip);" (call_expression) "gtk_widget_class_bind_template_callback (widget_class, cb_query_tooltip)" (identifier) "gtk_widget_class_bind_template_callback" (argument_list) "(widget_class, cb_query_tooltip)" (() "(" (identifier) "widget_class" (,) "," (identifier) "cb_query_tooltip" ()) ")" (;) ";" (expression_statement) "gtk_widget_class_bind_template_callback (widget_class, cb_value_changed);" (call_expression) "gtk_widget_class_bind_template_callback (widget_class, cb_value_changed)" (identifier) "gtk_widget_class_bind_template_callback" (argument_list) "(widget_class, cb_value_changed)" (() "(" (identifier) "widget_class" (,) "," (identifier) "cb_value_changed" ()) ")" (;) ";" (}) "}" (function_definition) "static void\ngtk_volume_button_init (GtkVolumeButton *button)\n{\n GtkWidget *widget = GTK_WIDGET (button);\n\n gtk_widget_init_template (widget);\n\n /* The atk action description is not supported by GtkBuilder */\n atk_action_set_description (ATK_ACTION (gtk_widget_get_accessible (GTK_WIDGET (widget))),\n 1, _("Adjusts the volume"));\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "gtk_volume_button_init (GtkVolumeButton *button)" (identifier) "gtk_volume_button_init" (parameter_list) "(GtkVolumeButton *button)" (() "(" (parameter_declaration) "GtkVolumeButton *button" (type_identifier) "GtkVolumeButton" (pointer_declarator) "*button" (*) "*" (identifier) "button" ()) ")" (compound_statement) "{\n GtkWidget *widget = GTK_WIDGET (button);\n\n gtk_widget_init_template (widget);\n\n /* The atk action description is not supported by GtkBuilder */\n atk_action_set_description (ATK_ACTION (gtk_widget_get_accessible (GTK_WIDGET (widget))),\n 1, _("Adjusts the volume"));\n}" ({) "{" (declaration) "GtkWidget *widget = GTK_WIDGET (button);" (type_identifier) "GtkWidget" (init_declarator) "*widget = GTK_WIDGET (button)" (pointer_declarator) "*widget" (*) "*" (identifier) "widget" (=) "=" (call_expression) "GTK_WIDGET (button)" (identifier) "GTK_WIDGET" (argument_list) "(button)" (() "(" (identifier) "button" ()) ")" (;) ";" (expression_statement) "gtk_widget_init_template (widget);" (call_expression) "gtk_widget_init_template (widget)" (identifier) "gtk_widget_init_template" (argument_list) "(widget)" (() "(" (identifier) "widget" ()) ")" (;) ";" (comment) "/* The atk action description is not supported by GtkBuilder */" (expression_statement) "atk_action_set_description (ATK_ACTION (gtk_widget_get_accessible (GTK_WIDGET (widget))),\n 1, _("Adjusts the volume"));" (call_expression) "atk_action_set_description (ATK_ACTION (gtk_widget_get_accessible (GTK_WIDGET (widget))),\n 1, _("Adjusts the volume"))" (identifier) "atk_action_set_description" (argument_list) "(ATK_ACTION (gtk_widget_get_accessible (GTK_WIDGET (widget))),\n 1, _("Adjusts the volume"))" (() "(" (call_expression) "ATK_ACTION (gtk_widget_get_accessible (GTK_WIDGET (widget)))" (identifier) "ATK_ACTION" (argument_list) "(gtk_widget_get_accessible (GTK_WIDGET (widget)))" (() "(" (call_expression) "gtk_widget_get_accessible (GTK_WIDGET (widget))" (identifier) "gtk_widget_get_accessible" (argument_list) "(GTK_WIDGET (widget))" (() "(" (call_expression) "GTK_WIDGET (widget)" (identifier) "GTK_WIDGET" (argument_list) "(widget)" (() "(" (identifier) "widget" ()) ")" ()) ")" ()) ")" (,) "," (number_literal) "1" (,) "," (call_expression) "_("Adjusts the volume")" (identifier) "_" (argument_list) "("Adjusts the volume")" (() "(" (string_literal) ""Adjusts the volume"" (") """ (string_content) "Adjusts the volume" (") """ ()) ")" ()) ")" (;) ";" (}) "}" (comment) "/**\n * gtk_volume_button_new:\n *\n * Creates a #GtkVolumeButton, with a range between 0.0 and 1.0, with\n * a stepping of 0.02. Volume values can be obtained and modified using\n * the functions from #GtkScaleButton.\n *\n * Returns: a new #GtkVolumeButton\n *\n * Since: 2.12\n */" (function_definition) "GtkWidget *\ngtk_volume_button_new (void)\n{\n GObject *button;\n button = g_object_new (GTK_TYPE_VOLUME_BUTTON, NULL);\n return GTK_WIDGET (button);\n}" (type_identifier) "GtkWidget" (pointer_declarator) "*\ngtk_volume_button_new (void)" (*) "*" (function_declarator) "gtk_volume_button_new (void)" (identifier) "gtk_volume_button_new" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (compound_statement) "{\n GObject *button;\n button = g_object_new (GTK_TYPE_VOLUME_BUTTON, NULL);\n return GTK_WIDGET (button);\n}" ({) "{" (declaration) "GObject *button;" (type_identifier) "GObject" (pointer_declarator) "*button" (*) "*" (identifier) "button" (;) ";" (expression_statement) "button = g_object_new (GTK_TYPE_VOLUME_BUTTON, NULL);" (assignment_expression) "button = g_object_new (GTK_TYPE_VOLUME_BUTTON, NULL)" (identifier) "button" (=) "=" (call_expression) "g_object_new (GTK_TYPE_VOLUME_BUTTON, NULL)" (identifier) "g_object_new" (argument_list) "(GTK_TYPE_VOLUME_BUTTON, NULL)" (() "(" (identifier) "GTK_TYPE_VOLUME_BUTTON" (,) "," (null) "NULL" (NULL) "NULL" ()) ")" (;) ";" (return_statement) "return GTK_WIDGET (button);" (return) "return" (call_expression) "GTK_WIDGET (button)" (identifier) "GTK_WIDGET" (argument_list) "(button)" (() "(" (identifier) "button" ()) ")" (;) ";" (}) "}" (function_definition) "static gboolean\ncb_query_tooltip (GtkWidget *button,\n gint x,\n gint y,\n gboolean keyboard_mode,\n GtkTooltip *tooltip,\n gpointer user_data)\n{\n GtkScaleButton *scale_button = GTK_SCALE_BUTTON (button);\n GtkAdjustment *adjustment;\n gdouble val;\n char *str;\n AtkImage *image;\n\n image = ATK_IMAGE (gtk_widget_get_accessible (button));\n\n adjustment = gtk_scale_button_get_adjustment (scale_button);\n val = gtk_scale_button_get_value (scale_button);\n\n if (val < (gtk_adjustment_get_lower (adjustment) + EPSILON))\n {\n str = g_strdup (_("Muted"));\n }\n else if (val >= (gtk_adjustment_get_upper (adjustment) - EPSILON))\n {\n str = g_strdup (_("Full Volume"));\n }\n else\n {\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. "49 %".\n * Translate the "%d" to "%Id" if you want to use localised digits,\n * or otherwise translate the "%d" to "%d".\n */\n str = g_strdup_printf (C_("volume percentage", "%d %%"), percent);\n }\n\n gtk_tooltip_set_text (tooltip, str);\n atk_image_set_image_description (image, str);\n g_free (str);\n\n return TRUE;\n}" (storage_class_specifier) "static" (static) "static" (type_identifier) "gboolean" (function_declarator) "cb_query_tooltip (GtkWidget *button,\n gint x,\n gint y,\n gboolean keyboard_mode,\n GtkTooltip *tooltip,\n gpointer user_data)" (identifier) "cb_query_tooltip" (parameter_list) "(GtkWidget *button,\n gint x,\n gint y,\n gboolean keyboard_mode,\n GtkTooltip *tooltip,\n gpointer user_data)" (() "(" (parameter_declaration) "GtkWidget *button" (type_identifier) "GtkWidget" (pointer_declarator) "*button" (*) "*" (identifier) "button" (,) "," (parameter_declaration) "gint x" (type_identifier) "gint" (identifier) "x" (,) "," (parameter_declaration) "gint y" (type_identifier) "gint" (identifier) "y" (,) "," (parameter_declaration) "gboolean keyboard_mode" (type_identifier) "gboolean" (identifier) "keyboard_mode" (,) "," (parameter_declaration) "GtkTooltip *tooltip" (type_identifier) "GtkTooltip" (pointer_declarator) "*tooltip" (*) "*" (identifier) "tooltip" (,) "," (parameter_declaration) "gpointer user_data" (type_identifier) "gpointer" (identifier) "user_data" ()) ")" (compound_statement) "{\n GtkScaleButton *scale_button = GTK_SCALE_BUTTON (button);\n GtkAdjustment *adjustment;\n gdouble val;\n char *str;\n AtkImage *image;\n\n image = ATK_IMAGE (gtk_widget_get_accessible (button));\n\n adjustment = gtk_scale_button_get_adjustment (scale_button);\n val = gtk_scale_button_get_value (scale_button);\n\n if (val < (gtk_adjustment_get_lower (adjustment) + EPSILON))\n {\n str = g_strdup (_("Muted"));\n }\n else if (val >= (gtk_adjustment_get_upper (adjustment) - EPSILON))\n {\n str = g_strdup (_("Full Volume"));\n }\n else\n {\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. "49 %".\n * Translate the "%d" to "%Id" if you want to use localised digits,\n * or otherwise translate the "%d" to "%d".\n */\n str = g_strdup_printf (C_("volume percentage", "%d %%"), percent);\n }\n\n gtk_tooltip_set_text (tooltip, str);\n atk_image_set_image_description (image, str);\n g_free (str);\n\n return TRUE;\n}" ({) "{" (declaration) "GtkScaleButton *scale_button = GTK_SCALE_BUTTON (button);" (type_identifier) "GtkScaleButton" (init_declarator) "*scale_button = GTK_SCALE_BUTTON (button)" (pointer_declarator) "*scale_button" (*) "*" (identifier) "scale_button" (=) "=" (call_expression) "GTK_SCALE_BUTTON (button)" (identifier) "GTK_SCALE_BUTTON" (argument_list) "(button)" (() "(" (identifier) "button" ()) ")" (;) ";" (declaration) "GtkAdjustment *adjustment;" (type_identifier) "GtkAdjustment" (pointer_declarator) "*adjustment" (*) "*" (identifier) "adjustment" (;) ";" (declaration) "gdouble val;" (type_identifier) "gdouble" (identifier) "val" (;) ";" (declaration) "char *str;" (primitive_type) "char" (pointer_declarator) "*str" (*) "*" (identifier) "str" (;) ";" (declaration) "AtkImage *image;" (type_identifier) "AtkImage" (pointer_declarator) "*image" (*) "*" (identifier) "image" (;) ";" (expression_statement) "image = ATK_IMAGE (gtk_widget_get_accessible (button));" (assignment_expression) "image = ATK_IMAGE (gtk_widget_get_accessible (button))" (identifier) "image" (=) "=" (call_expression) "ATK_IMAGE (gtk_widget_get_accessible (button))" (identifier) "ATK_IMAGE" (argument_list) "(gtk_widget_get_accessible (button))" (() "(" (call_expression) "gtk_widget_get_accessible (button)" (identifier) "gtk_widget_get_accessible" (argument_list) "(button)" (() "(" (identifier) "button" ()) ")" ()) ")" (;) ";" (expression_statement) "adjustment = gtk_scale_button_get_adjustment (scale_button);" (assignment_expression) "adjustment = gtk_scale_button_get_adjustment (scale_button)" (identifier) "adjustment" (=) "=" (call_expression) "gtk_scale_button_get_adjustment (scale_button)" (identifier) "gtk_scale_button_get_adjustment" (argument_list) "(scale_button)" (() "(" (identifier) "scale_button" ()) ")" (;) ";" (expression_statement) "val = gtk_scale_button_get_value (scale_button);" (assignment_expression) "val = gtk_scale_button_get_value (scale_button)" (identifier) "val" (=) "=" (call_expression) "gtk_scale_button_get_value (scale_button)" (identifier) "gtk_scale_button_get_value" (argument_list) "(scale_button)" (() "(" (identifier) "scale_button" ()) ")" (;) ";" (if_statement) "if (val < (gtk_adjustment_get_lower (adjustment) + EPSILON))\n {\n str = g_strdup (_("Muted"));\n }\n else if (val >= (gtk_adjustment_get_upper (adjustment) - EPSILON))\n {\n str = g_strdup (_("Full Volume"));\n }\n else\n {\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. "49 %".\n * Translate the "%d" to "%Id" if you want to use localised digits,\n * or otherwise translate the "%d" to "%d".\n */\n str = g_strdup_printf (C_("volume percentage", "%d %%"), percent);\n }" (if) "if" (parenthesized_expression) "(val < (gtk_adjustment_get_lower (adjustment) + EPSILON))" (() "(" (binary_expression) "val < (gtk_adjustment_get_lower (adjustment) + EPSILON)" (identifier) "val" (<) "<" (parenthesized_expression) "(gtk_adjustment_get_lower (adjustment) + EPSILON)" (() "(" (binary_expression) "gtk_adjustment_get_lower (adjustment) + EPSILON" (call_expression) "gtk_adjustment_get_lower (adjustment)" (identifier) "gtk_adjustment_get_lower" (argument_list) "(adjustment)" (() "(" (identifier) "adjustment" ()) ")" (+) "+" (identifier) "EPSILON" ()) ")" ()) ")" (compound_statement) "{\n str = g_strdup (_("Muted"));\n }" ({) "{" (expression_statement) "str = g_strdup (_("Muted"));" (assignment_expression) "str = g_strdup (_("Muted"))" (identifier) "str" (=) "=" (call_expression) "g_strdup (_("Muted"))" (identifier) "g_strdup" (argument_list) "(_("Muted"))" (() "(" (call_expression) "_("Muted")" (identifier) "_" (argument_list) "("Muted")" (() "(" (string_literal) ""Muted"" (") """ (string_content) "Muted" (") """ ()) ")" ()) ")" (;) ";" (}) "}" (else_clause) "else if (val >= (gtk_adjustment_get_upper (adjustment) - EPSILON))\n {\n str = g_strdup (_("Full Volume"));\n }\n else\n {\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. "49 %".\n * Translate the "%d" to "%Id" if you want to use localised digits,\n * or otherwise translate the "%d" to "%d".\n */\n str = g_strdup_printf (C_("volume percentage", "%d %%"), percent);\n }" (else) "else" (if_statement) "if (val >= (gtk_adjustment_get_upper (adjustment) - EPSILON))\n {\n str = g_strdup (_("Full Volume"));\n }\n else\n {\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. "49 %".\n * Translate the "%d" to "%Id" if you want to use localised digits,\n * or otherwise translate the "%d" to "%d".\n */\n str = g_strdup_printf (C_("volume percentage", "%d %%"), percent);\n }" (if) "if" (parenthesized_expression) "(val >= (gtk_adjustment_get_upper (adjustment) - EPSILON))" (() "(" (binary_expression) "val >= (gtk_adjustment_get_upper (adjustment) - EPSILON)" (identifier) "val" (>=) ">=" (parenthesized_expression) "(gtk_adjustment_get_upper (adjustment) - EPSILON)" (() "(" (binary_expression) "gtk_adjustment_get_upper (adjustment) - EPSILON" (call_expression) "gtk_adjustment_get_upper (adjustment)" (identifier) "gtk_adjustment_get_upper" (argument_list) "(adjustment)" (() "(" (identifier) "adjustment" ()) ")" (-) "-" (identifier) "EPSILON" ()) ")" ()) ")" (compound_statement) "{\n str = g_strdup (_("Full Volume"));\n }" ({) "{" (expression_statement) "str = g_strdup (_("Full Volume"));" (assignment_expression) "str = g_strdup (_("Full Volume"))" (identifier) "str" (=) "=" (call_expression) "g_strdup (_("Full Volume"))" (identifier) "g_strdup" (argument_list) "(_("Full Volume"))" (() "(" (call_expression) "_("Full Volume")" (identifier) "_" (argument_list) "("Full Volume")" (() "(" (string_literal) ""Full Volume"" (") """ (string_content) "Full Volume" (") """ ()) ")" ()) ")" (;) ";" (}) "}" (else_clause) "else\n {\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. "49 %".\n * Translate the "%d" to "%Id" if you want to use localised digits,\n * or otherwise translate the "%d" to "%d".\n */\n str = g_strdup_printf (C_("volume percentage", "%d %%"), percent);\n }" (else) "else" (compound_statement) "{\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. "49 %".\n * Translate the "%d" to "%Id" if you want to use localised digits,\n * or otherwise translate the "%d" to "%d".\n */\n str = g_strdup_printf (C_("volume percentage", "%d %%"), percent);\n }" ({) "{" (declaration) "int percent;" (primitive_type) "int" (identifier) "percent" (;) ";" (expression_statement) "percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);" (assignment_expression) "percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5)" (identifier) "percent" (=) "=" (cast_expression) "(int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5)" (() "(" (type_descriptor) "int" (primitive_type) "int" ()) ")" (parenthesized_expression) "(100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5)" (() "(" (binary_expression) "100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5" (binary_expression) "100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment))" (binary_expression) "100. * val" (number_literal) "100." (*) "*" (identifier) "val" (/) "/" (parenthesized_expression) "(gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment))" (() "(" (binary_expression) "gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)" (call_expression) "gtk_adjustment_get_upper (adjustment)" (identifier) "gtk_adjustment_get_upper" (argument_list) "(adjustment)" (() "(" (identifier) "adjustment" ()) ")" (-) "-" (call_expression) "gtk_adjustment_get_lower (adjustment)" (identifier) "gtk_adjustment_get_lower" (argument_list) "(adjustment)" (() "(" (identifier) "adjustment" ()) ")" ()) ")" (+) "+" (number_literal) ".5" ()) ")" (;) ";" (comment) "/* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. "49 %".\n * Translate the "%d" to "%Id" if you want to use localised digits,\n * or otherwise translate the "%d" to "%d".\n */" (expression_statement) "str = g_strdup_printf (C_("volume percentage", "%d %%"), percent);" (assignment_expression) "str = g_strdup_printf (C_("volume percentage", "%d %%"), percent)" (identifier) "str" (=) "=" (call_expression) "g_strdup_printf (C_("volume percentage", "%d %%"), percent)" (identifier) "g_strdup_printf" (argument_list) "(C_("volume percentage", "%d %%"), percent)" (() "(" (call_expression) "C_("volume percentage", "%d %%")" (identifier) "C_" (argument_list) "("volume percentage", "%d %%")" (() "(" (string_literal) ""volume percentage"" (") """ (string_content) "volume percentage" (") """ (,) "," (string_literal) ""%d %%"" (") """ (string_content) "%d %%" (") """ ()) ")" (,) "," (identifier) "percent" ()) ")" (;) ";" (}) "}" (expression_statement) "gtk_tooltip_set_text (tooltip, str);" (call_expression) "gtk_tooltip_set_text (tooltip, str)" (identifier) "gtk_tooltip_set_text" (argument_list) "(tooltip, str)" (() "(" (identifier) "tooltip" (,) "," (identifier) "str" ()) ")" (;) ";" (expression_statement) "atk_image_set_image_description (image, str);" (call_expression) "atk_image_set_image_description (image, str)" (identifier) "atk_image_set_image_description" (argument_list) "(image, str)" (() "(" (identifier) "image" (,) "," (identifier) "str" ()) ")" (;) ";" (expression_statement) "g_free (str);" (call_expression) "g_free (str)" (identifier) "g_free" (argument_list) "(str)" (() "(" (identifier) "str" ()) ")" (;) ";" (return_statement) "return TRUE;" (return) "return" (true) "TRUE" (;) ";" (}) "}" (function_definition) "static void\ncb_value_changed (GtkVolumeButton *button, gdouble value, gpointer user_data)\n{\n gtk_widget_trigger_tooltip_query (GTK_WIDGET (button));\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "cb_value_changed (GtkVolumeButton *button, gdouble value, gpointer user_data)" (identifier) "cb_value_changed" (parameter_list) "(GtkVolumeButton *button, gdouble value, gpointer user_data)" (() "(" (parameter_declaration) "GtkVolumeButton *button" (type_identifier) "GtkVolumeButton" (pointer_declarator) "*button" (*) "*" (identifier) "button" (,) "," (parameter_declaration) "gdouble value" (type_identifier) "gdouble" (identifier) "value" (,) "," (parameter_declaration) "gpointer user_data" (type_identifier) "gpointer" (identifier) "user_data" ()) ")" (compound_statement) "{\n gtk_widget_trigger_tooltip_query (GTK_WIDGET (button));\n}" ({) "{" (expression_statement) "gtk_widget_trigger_tooltip_query (GTK_WIDGET (button));" (call_expression) "gtk_widget_trigger_tooltip_query (GTK_WIDGET (button))" (identifier) "gtk_widget_trigger_tooltip_query" (argument_list) "(GTK_WIDGET (button))" (() "(" (call_expression) "GTK_WIDGET (button)" (identifier) "GTK_WIDGET" (argument_list) "(button)" (() "(" (identifier) "button" ()) ")" ()) ")" (;) ";" (}) "}"
1,118
0
{"language": "c", "success": true, "metadata": {"lines": 219, "avg_line_length": 32.15, "nodes": 649, "errors": 0, "source_hash": "7bcb71c965e2a447a2b7f5d5d84ee5b5cd8d1420198ac51da8ca43dc0b517d90", "categorized_nodes": 437}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"config.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 28, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"config.h\"", "parent": 0, "children": [], "start_point": {"row": 27, "column": 9}, "end_point": {"row": 27, "column": 19}}, {"id": 3, "type": "preproc_include", "text": "#include \"gtkvolumebutton.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 30, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 8}}, {"id": 5, "type": "string_literal", "text": "\"gtkvolumebutton.h\"", "parent": 3, "children": [], "start_point": {"row": 29, "column": 9}, "end_point": {"row": 29, "column": 28}}, {"id": 6, "type": "preproc_include", "text": "#include \"gtkadjustment.h\"\n", "parent": null, "children": [7, 8], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 32, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 31, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"gtkadjustment.h\"", "parent": 6, "children": [], "start_point": {"row": 31, "column": 9}, "end_point": {"row": 31, "column": 26}}, {"id": 9, "type": "preproc_include", "text": "#include \"gtkintl.h\"\n", "parent": null, "children": [10, 11], "start_point": {"row": 32, "column": 0}, "end_point": {"row": 33, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 32, "column": 0}, "end_point": {"row": 32, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"gtkintl.h\"", "parent": 9, "children": [], "start_point": {"row": 32, "column": 9}, "end_point": {"row": 32, "column": 20}}, {"id": 12, "type": "preproc_include", "text": "#include \"gtktooltip.h\"\n", "parent": null, "children": [13, 14], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 34, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 33, "column": 8}}, {"id": 14, "type": "string_literal", "text": "\"gtktooltip.h\"", "parent": 12, "children": [], "start_point": {"row": 33, "column": 9}, "end_point": {"row": 33, "column": 23}}, {"id": 15, "type": "preproc_def", "text": "#define EPSILON (1e-10)\n", "parent": null, "children": [16, 17, 18], "start_point": {"row": 46, "column": 0}, "end_point": {"row": 47, "column": 0}}, {"id": 16, "type": "#define", "text": "#define", "parent": 15, "children": [], "start_point": {"row": 46, "column": 0}, "end_point": {"row": 46, "column": 7}}, {"id": 17, "type": "identifier", "text": "EPSILON", "parent": 15, "children": [], "start_point": {"row": 46, "column": 8}, "end_point": {"row": 46, "column": 15}}, {"id": 18, "type": "preproc_arg", "text": "(1e-10)", "parent": 15, "children": [], "start_point": {"row": 46, "column": 16}, "end_point": {"row": 46, "column": 23}}, {"id": 19, "type": "declaration", "text": "static const gchar * const icons[] =\n{\n \"audio-volume-muted\",\n \"audio-volume-high\",\n \"audio-volume-low\",\n \"audio-volume-medium\",\n NULL\n};", "parent": null, "children": [20, 21], "start_point": {"row": 48, "column": 0}, "end_point": {"row": 55, "column": 2}}, {"id": 20, "type": "type_identifier", "text": "gchar", "parent": 19, "children": [], "start_point": {"row": 48, "column": 13}, "end_point": {"row": 48, "column": 18}}, {"id": 21, "type": "init_declarator", "text": "* const icons[] =\n{\n \"audio-volume-muted\",\n \"audio-volume-high\",\n \"audio-volume-low\",\n \"audio-volume-medium\",\n NULL\n}", "parent": 19, "children": [22, 26, 27], "start_point": {"row": 48, "column": 19}, "end_point": {"row": 55, "column": 1}}, {"id": 22, "type": "pointer_declarator", "text": "* const icons[]", "parent": 21, "children": [23, 24], "start_point": {"row": 48, "column": 19}, "end_point": {"row": 48, "column": 34}}, {"id": 23, "type": "*", "text": "*", "parent": 22, "children": [], "start_point": {"row": 48, "column": 19}, "end_point": {"row": 48, "column": 20}}, {"id": 24, "type": "array_declarator", "text": "icons[]", "parent": 22, "children": [25], "start_point": {"row": 48, "column": 27}, "end_point": {"row": 48, "column": 34}}, {"id": 25, "type": "identifier", "text": "icons", "parent": 24, "children": [], "start_point": {"row": 48, "column": 27}, "end_point": {"row": 48, "column": 32}}, {"id": 26, "type": "=", "text": "=", "parent": 21, "children": [], "start_point": {"row": 48, "column": 35}, "end_point": {"row": 48, "column": 36}}, {"id": 27, "type": "initializer_list", "text": "{\n \"audio-volume-muted\",\n \"audio-volume-high\",\n \"audio-volume-low\",\n \"audio-volume-medium\",\n NULL\n}", "parent": 21, "children": [28, 29, 30, 31, 32], "start_point": {"row": 49, "column": 0}, "end_point": {"row": 55, "column": 1}}, {"id": 28, "type": "string_literal", "text": "\"audio-volume-muted\"", "parent": 27, "children": [], "start_point": {"row": 50, "column": 2}, "end_point": {"row": 50, "column": 22}}, {"id": 29, "type": "string_literal", "text": "\"audio-volume-high\"", "parent": 27, "children": [], "start_point": {"row": 51, "column": 2}, "end_point": {"row": 51, "column": 21}}, {"id": 30, "type": "string_literal", "text": "\"audio-volume-low\"", "parent": 27, "children": [], "start_point": {"row": 52, "column": 2}, "end_point": {"row": 52, "column": 20}}, {"id": 31, "type": "string_literal", "text": "\"audio-volume-medium\"", "parent": 27, "children": [], "start_point": {"row": 53, "column": 2}, "end_point": {"row": 53, "column": 23}}, {"id": 32, "type": "null", "text": "NULL", "parent": 27, "children": [33], "start_point": {"row": 54, "column": 2}, "end_point": {"row": 54, "column": 6}}, {"id": 33, "type": "NULL", "text": "NULL", "parent": 32, "children": [], "start_point": {"row": 54, "column": 2}, "end_point": {"row": 54, "column": 6}}, {"id": 34, "type": "declaration", "text": "static const gchar * const icons_symbolic[] =\n{\n \"audio-volume-muted-symbolic\",\n \"audio-volume-high-symbolic\",\n \"audio-volume-low-symbolic\",\n \"audio-volume-medium-symbolic\",\n NULL\n};", "parent": null, "children": [35, 36], "start_point": {"row": 57, "column": 0}, "end_point": {"row": 64, "column": 2}}, {"id": 35, "type": "type_identifier", "text": "gchar", "parent": 34, "children": [], "start_point": {"row": 57, "column": 13}, "end_point": {"row": 57, "column": 18}}, {"id": 36, "type": "init_declarator", "text": "* const icons_symbolic[] =\n{\n \"audio-volume-muted-symbolic\",\n \"audio-volume-high-symbolic\",\n \"audio-volume-low-symbolic\",\n \"audio-volume-medium-symbolic\",\n NULL\n}", "parent": 34, "children": [37, 41, 42], "start_point": {"row": 57, "column": 19}, "end_point": {"row": 64, "column": 1}}, {"id": 37, "type": "pointer_declarator", "text": "* const icons_symbolic[]", "parent": 36, "children": [38, 39], "start_point": {"row": 57, "column": 19}, "end_point": {"row": 57, "column": 43}}, {"id": 38, "type": "*", "text": "*", "parent": 37, "children": [], "start_point": {"row": 57, "column": 19}, "end_point": {"row": 57, "column": 20}}, {"id": 39, "type": "array_declarator", "text": "icons_symbolic[]", "parent": 37, "children": [40], "start_point": {"row": 57, "column": 27}, "end_point": {"row": 57, "column": 43}}, {"id": 40, "type": "identifier", "text": "icons_symbolic", "parent": 39, "children": [], "start_point": {"row": 57, "column": 27}, "end_point": {"row": 57, "column": 41}}, {"id": 41, "type": "=", "text": "=", "parent": 36, "children": [], "start_point": {"row": 57, "column": 44}, "end_point": {"row": 57, "column": 45}}, {"id": 42, "type": "initializer_list", "text": "{\n \"audio-volume-muted-symbolic\",\n \"audio-volume-high-symbolic\",\n \"audio-volume-low-symbolic\",\n \"audio-volume-medium-symbolic\",\n NULL\n}", "parent": 36, "children": [43, 44, 45, 46, 47], "start_point": {"row": 58, "column": 0}, "end_point": {"row": 64, "column": 1}}, {"id": 43, "type": "string_literal", "text": "\"audio-volume-muted-symbolic\"", "parent": 42, "children": [], "start_point": {"row": 59, "column": 2}, "end_point": {"row": 59, "column": 31}}, {"id": 44, "type": "string_literal", "text": "\"audio-volume-high-symbolic\"", "parent": 42, "children": [], "start_point": {"row": 60, "column": 2}, "end_point": {"row": 60, "column": 30}}, {"id": 45, "type": "string_literal", "text": "\"audio-volume-low-symbolic\"", "parent": 42, "children": [], "start_point": {"row": 61, "column": 2}, "end_point": {"row": 61, "column": 29}}, {"id": 46, "type": "string_literal", "text": "\"audio-volume-medium-symbolic\"", "parent": 42, "children": [], "start_point": {"row": 62, "column": 2}, "end_point": {"row": 62, "column": 32}}, {"id": 47, "type": "null", "text": "NULL", "parent": 42, "children": [48], "start_point": {"row": 63, "column": 2}, "end_point": {"row": 63, "column": 6}}, {"id": 48, "type": "NULL", "text": "NULL", "parent": 47, "children": [], "start_point": {"row": 63, "column": 2}, "end_point": {"row": 63, "column": 6}}, {"id": 49, "type": "enum_specifier", "text": "enum\n{\n PROP_0,\n PROP_SYMBOLIC\n}", "parent": null, "children": [50, 51], "start_point": {"row": 66, "column": 0}, "end_point": {"row": 70, "column": 1}}, {"id": 50, "type": "enum", "text": "enum", "parent": 49, "children": [], "start_point": {"row": 66, "column": 0}, "end_point": {"row": 66, "column": 4}}, {"id": 51, "type": "enumerator_list", "text": "{\n PROP_0,\n PROP_SYMBOLIC\n}", "parent": 49, "children": [52, 54], "start_point": {"row": 67, "column": 0}, "end_point": {"row": 70, "column": 1}}, {"id": 52, "type": "enumerator", "text": "PROP_0", "parent": 51, "children": [53], "start_point": {"row": 68, "column": 2}, "end_point": {"row": 68, "column": 8}}, {"id": 53, "type": "identifier", "text": "PROP_0", "parent": 52, "children": [], "start_point": {"row": 68, "column": 2}, "end_point": {"row": 68, "column": 8}}, {"id": 54, "type": "enumerator", "text": "PROP_SYMBOLIC", "parent": 51, "children": [55], "start_point": {"row": 69, "column": 2}, "end_point": {"row": 69, "column": 15}}, {"id": 55, "type": "identifier", "text": "PROP_SYMBOLIC", "parent": 54, "children": [], "start_point": {"row": 69, "column": 2}, "end_point": {"row": 69, "column": 15}}, {"id": 56, "type": "declaration", "text": "static gboolean\tcb_query_tooltip (GtkWidget *button,\n gint x,\n gint y,\n gboolean keyboard_mode,\n GtkTooltip *tooltip,\n gpointer user_data);", "parent": null, "children": [57, 58], "start_point": {"row": 72, "column": 0}, "end_point": {"row": 77, "column": 62}}, {"id": 57, "type": "type_identifier", "text": "gboolean", "parent": 56, "children": [], "start_point": {"row": 72, "column": 7}, "end_point": {"row": 72, "column": 15}}, {"id": 58, "type": "function_declarator", "text": "cb_query_tooltip (GtkWidget *button,\n gint x,\n gint y,\n gboolean keyboard_mode,\n GtkTooltip *tooltip,\n gpointer user_data)", "parent": 56, "children": [59, 60], "start_point": {"row": 72, "column": 16}, "end_point": {"row": 77, "column": 61}}, {"id": 59, "type": "identifier", "text": "cb_query_tooltip", "parent": 58, "children": [], "start_point": {"row": 72, "column": 16}, "end_point": {"row": 72, "column": 32}}, {"id": 60, "type": "parameter_list", "text": "(GtkWidget *button,\n gint x,\n gint y,\n gboolean keyboard_mode,\n GtkTooltip *tooltip,\n gpointer user_data)", "parent": 58, "children": [61, 66, 69, 72, 75, 80], "start_point": {"row": 72, "column": 33}, "end_point": {"row": 77, "column": 61}}, {"id": 61, "type": "parameter_declaration", "text": "GtkWidget *button", "parent": 60, "children": [62, 63], "start_point": {"row": 72, "column": 34}, "end_point": {"row": 72, "column": 57}}, {"id": 62, "type": "type_identifier", "text": "GtkWidget", "parent": 61, "children": [], "start_point": {"row": 72, "column": 34}, "end_point": {"row": 72, "column": 43}}, {"id": 63, "type": "pointer_declarator", "text": "*button", "parent": 61, "children": [64, 65], "start_point": {"row": 72, "column": 50}, "end_point": {"row": 72, "column": 57}}, {"id": 64, "type": "*", "text": "*", "parent": 63, "children": [], "start_point": {"row": 72, "column": 50}, "end_point": {"row": 72, "column": 51}}, {"id": 65, "type": "identifier", "text": "button", "parent": 63, "children": [], "start_point": {"row": 72, "column": 51}, "end_point": {"row": 72, "column": 57}}, {"id": 66, "type": "parameter_declaration", "text": "gint x", "parent": 60, "children": [67, 68], "start_point": {"row": 73, "column": 34}, "end_point": {"row": 73, "column": 52}}, {"id": 67, "type": "type_identifier", "text": "gint", "parent": 66, "children": [], "start_point": {"row": 73, "column": 34}, "end_point": {"row": 73, "column": 38}}, {"id": 68, "type": "identifier", "text": "x", "parent": 66, "children": [], "start_point": {"row": 73, "column": 51}, "end_point": {"row": 73, "column": 52}}, {"id": 69, "type": "parameter_declaration", "text": "gint y", "parent": 60, "children": [70, 71], "start_point": {"row": 74, "column": 34}, "end_point": {"row": 74, "column": 52}}, {"id": 70, "type": "type_identifier", "text": "gint", "parent": 69, "children": [], "start_point": {"row": 74, "column": 34}, "end_point": {"row": 74, "column": 38}}, {"id": 71, "type": "identifier", "text": "y", "parent": 69, "children": [], "start_point": {"row": 74, "column": 51}, "end_point": {"row": 74, "column": 52}}, {"id": 72, "type": "parameter_declaration", "text": "gboolean keyboard_mode", "parent": 60, "children": [73, 74], "start_point": {"row": 75, "column": 34}, "end_point": {"row": 75, "column": 64}}, {"id": 73, "type": "type_identifier", "text": "gboolean", "parent": 72, "children": [], "start_point": {"row": 75, "column": 34}, "end_point": {"row": 75, "column": 42}}, {"id": 74, "type": "identifier", "text": "keyboard_mode", "parent": 72, "children": [], "start_point": {"row": 75, "column": 51}, "end_point": {"row": 75, "column": 64}}, {"id": 75, "type": "parameter_declaration", "text": "GtkTooltip *tooltip", "parent": 60, "children": [76, 77], "start_point": {"row": 76, "column": 34}, "end_point": {"row": 76, "column": 58}}, {"id": 76, "type": "type_identifier", "text": "GtkTooltip", "parent": 75, "children": [], "start_point": {"row": 76, "column": 34}, "end_point": {"row": 76, "column": 44}}, {"id": 77, "type": "pointer_declarator", "text": "*tooltip", "parent": 75, "children": [78, 79], "start_point": {"row": 76, "column": 50}, "end_point": {"row": 76, "column": 58}}, {"id": 78, "type": "*", "text": "*", "parent": 77, "children": [], "start_point": {"row": 76, "column": 50}, "end_point": {"row": 76, "column": 51}}, {"id": 79, "type": "identifier", "text": "tooltip", "parent": 77, "children": [], "start_point": {"row": 76, "column": 51}, "end_point": {"row": 76, "column": 58}}, {"id": 80, "type": "parameter_declaration", "text": "gpointer user_data", "parent": 60, "children": [81, 82], "start_point": {"row": 77, "column": 34}, "end_point": {"row": 77, "column": 60}}, {"id": 81, "type": "type_identifier", "text": "gpointer", "parent": 80, "children": [], "start_point": {"row": 77, "column": 34}, "end_point": {"row": 77, "column": 42}}, {"id": 82, "type": "identifier", "text": "user_data", "parent": 80, "children": [], "start_point": {"row": 77, "column": 51}, "end_point": {"row": 77, "column": 60}}, {"id": 83, "type": "declaration", "text": "static void\tcb_value_changed (GtkVolumeButton *button,\n gdouble value,\n gpointer user_data);", "parent": null, "children": [84, 85], "start_point": {"row": 78, "column": 0}, "end_point": {"row": 80, "column": 62}}, {"id": 84, "type": "primitive_type", "text": "void", "parent": 83, "children": [], "start_point": {"row": 78, "column": 7}, "end_point": {"row": 78, "column": 11}}, {"id": 85, "type": "function_declarator", "text": "cb_value_changed (GtkVolumeButton *button,\n gdouble value,\n gpointer user_data)", "parent": 83, "children": [86, 87], "start_point": {"row": 78, "column": 12}, "end_point": {"row": 80, "column": 61}}, {"id": 86, "type": "identifier", "text": "cb_value_changed", "parent": 85, "children": [], "start_point": {"row": 78, "column": 12}, "end_point": {"row": 78, "column": 28}}, {"id": 87, "type": "parameter_list", "text": "(GtkVolumeButton *button,\n gdouble value,\n gpointer user_data)", "parent": 85, "children": [88, 93, 96], "start_point": {"row": 78, "column": 29}, "end_point": {"row": 80, "column": 61}}, {"id": 88, "type": "parameter_declaration", "text": "GtkVolumeButton *button", "parent": 87, "children": [89, 90], "start_point": {"row": 78, "column": 30}, "end_point": {"row": 78, "column": 53}}, {"id": 89, "type": "type_identifier", "text": "GtkVolumeButton", "parent": 88, "children": [], "start_point": {"row": 78, "column": 30}, "end_point": {"row": 78, "column": 45}}, {"id": 90, "type": "pointer_declarator", "text": "*button", "parent": 88, "children": [91, 92], "start_point": {"row": 78, "column": 46}, "end_point": {"row": 78, "column": 53}}, {"id": 91, "type": "*", "text": "*", "parent": 90, "children": [], "start_point": {"row": 78, "column": 46}, "end_point": {"row": 78, "column": 47}}, {"id": 92, "type": "identifier", "text": "button", "parent": 90, "children": [], "start_point": {"row": 78, "column": 47}, "end_point": {"row": 78, "column": 53}}, {"id": 93, "type": "parameter_declaration", "text": "gdouble value", "parent": 87, "children": [94, 95], "start_point": {"row": 79, "column": 34}, "end_point": {"row": 79, "column": 56}}, {"id": 94, "type": "type_identifier", "text": "gdouble", "parent": 93, "children": [], "start_point": {"row": 79, "column": 34}, "end_point": {"row": 79, "column": 41}}, {"id": 95, "type": "identifier", "text": "value", "parent": 93, "children": [], "start_point": {"row": 79, "column": 51}, "end_point": {"row": 79, "column": 56}}, {"id": 96, "type": "parameter_declaration", "text": "gpointer user_data", "parent": 87, "children": [97, 98], "start_point": {"row": 80, "column": 34}, "end_point": {"row": 80, "column": 60}}, {"id": 97, "type": "type_identifier", "text": "gpointer", "parent": 96, "children": [], "start_point": {"row": 80, "column": 34}, "end_point": {"row": 80, "column": 42}}, {"id": 98, "type": "identifier", "text": "user_data", "parent": 96, "children": [], "start_point": {"row": 80, "column": 51}, "end_point": {"row": 80, "column": 60}}, {"id": 99, "type": "call_expression", "text": "G_DEFINE_TYPE (GtkVolumeButton, gtk_volume_button, GTK_TYPE_SCALE_BUTTON)", "parent": null, "children": [100, 101], "start_point": {"row": 82, "column": 0}, "end_point": {"row": 82, "column": 73}}, {"id": 100, "type": "identifier", "text": "G_DEFINE_TYPE", "parent": 99, "children": [], "start_point": {"row": 82, "column": 0}, "end_point": {"row": 82, "column": 13}}, {"id": 101, "type": "argument_list", "text": "(GtkVolumeButton, gtk_volume_button, GTK_TYPE_SCALE_BUTTON)", "parent": 99, "children": [102, 103, 104], "start_point": {"row": 82, "column": 14}, "end_point": {"row": 82, "column": 73}}, {"id": 102, "type": "identifier", "text": "GtkVolumeButton", "parent": 101, "children": [], "start_point": {"row": 82, "column": 15}, "end_point": {"row": 82, "column": 30}}, {"id": 103, "type": "identifier", "text": "gtk_volume_button", "parent": 101, "children": [], "start_point": {"row": 82, "column": 32}, "end_point": {"row": 82, "column": 49}}, {"id": 104, "type": "identifier", "text": "GTK_TYPE_SCALE_BUTTON", "parent": 101, "children": [], "start_point": {"row": 82, "column": 51}, "end_point": {"row": 82, "column": 72}}, {"id": 105, "type": "function_definition", "text": "static void\ngtk_volume_button_set_property (GObject *object,\n\t\t\t\tguint prop_id,\n\t\t\t\tconst GValue *value,\n\t\t\t\tGParamSpec *pspec)\n{\n GtkScaleButton *button = GTK_SCALE_BUTTON (object);\n\n switch (prop_id)\n {\n case PROP_SYMBOLIC:\n if (g_value_get_boolean (value))\n gtk_scale_button_set_icons (button, (const char **) icons_symbolic);\n else\n\tgtk_scale_button_set_icons (button, (const char **) icons);\n break;\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }\n}", "parent": null, "children": [106, 107], "start_point": {"row": 84, "column": 0}, "end_point": {"row": 104, "column": 1}}, {"id": 106, "type": "primitive_type", "text": "void", "parent": 105, "children": [], "start_point": {"row": 84, "column": 7}, "end_point": {"row": 84, "column": 11}}, {"id": 107, "type": "function_declarator", "text": "gtk_volume_button_set_property (GObject *object,\n\t\t\t\tguint prop_id,\n\t\t\t\tconst GValue *value,\n\t\t\t\tGParamSpec *pspec)", "parent": 105, "children": [108, 109], "start_point": {"row": 85, "column": 0}, "end_point": {"row": 88, "column": 25}}, {"id": 108, "type": "identifier", "text": "gtk_volume_button_set_property", "parent": 107, "children": [], "start_point": {"row": 85, "column": 0}, "end_point": {"row": 85, "column": 30}}, {"id": 109, "type": "parameter_list", "text": "(GObject *object,\n\t\t\t\tguint prop_id,\n\t\t\t\tconst GValue *value,\n\t\t\t\tGParamSpec *pspec)", "parent": 107, "children": [110, 115, 118, 123], "start_point": {"row": 85, "column": 31}, "end_point": {"row": 88, "column": 25}}, {"id": 110, "type": "parameter_declaration", "text": "GObject *object", "parent": 109, "children": [111, 112], "start_point": {"row": 85, "column": 32}, "end_point": {"row": 85, "column": 53}}, {"id": 111, "type": "type_identifier", "text": "GObject", "parent": 110, "children": [], "start_point": {"row": 85, "column": 32}, "end_point": {"row": 85, "column": 39}}, {"id": 112, "type": "pointer_declarator", "text": "*object", "parent": 110, "children": [113, 114], "start_point": {"row": 85, "column": 46}, "end_point": {"row": 85, "column": 53}}, {"id": 113, "type": "*", "text": "*", "parent": 112, "children": [], "start_point": {"row": 85, "column": 46}, "end_point": {"row": 85, "column": 47}}, {"id": 114, "type": "identifier", "text": "object", "parent": 112, "children": [], "start_point": {"row": 85, "column": 47}, "end_point": {"row": 85, "column": 53}}, {"id": 115, "type": "parameter_declaration", "text": "guint prop_id", "parent": 109, "children": [116, 117], "start_point": {"row": 86, "column": 4}, "end_point": {"row": 86, "column": 26}}, {"id": 116, "type": "type_identifier", "text": "guint", "parent": 115, "children": [], "start_point": {"row": 86, "column": 4}, "end_point": {"row": 86, "column": 9}}, {"id": 117, "type": "identifier", "text": "prop_id", "parent": 115, "children": [], "start_point": {"row": 86, "column": 19}, "end_point": {"row": 86, "column": 26}}, {"id": 118, "type": "parameter_declaration", "text": "const GValue *value", "parent": 109, "children": [119, 120], "start_point": {"row": 87, "column": 4}, "end_point": {"row": 87, "column": 24}}, {"id": 119, "type": "type_identifier", "text": "GValue", "parent": 118, "children": [], "start_point": {"row": 87, "column": 10}, "end_point": {"row": 87, "column": 16}}, {"id": 120, "type": "pointer_declarator", "text": "*value", "parent": 118, "children": [121, 122], "start_point": {"row": 87, "column": 18}, "end_point": {"row": 87, "column": 24}}, {"id": 121, "type": "*", "text": "*", "parent": 120, "children": [], "start_point": {"row": 87, "column": 18}, "end_point": {"row": 87, "column": 19}}, {"id": 122, "type": "identifier", "text": "value", "parent": 120, "children": [], "start_point": {"row": 87, "column": 19}, "end_point": {"row": 87, "column": 24}}, {"id": 123, "type": "parameter_declaration", "text": "GParamSpec *pspec", "parent": 109, "children": [124, 125], "start_point": {"row": 88, "column": 4}, "end_point": {"row": 88, "column": 24}}, {"id": 124, "type": "type_identifier", "text": "GParamSpec", "parent": 123, "children": [], "start_point": {"row": 88, "column": 4}, "end_point": {"row": 88, "column": 14}}, {"id": 125, "type": "pointer_declarator", "text": "*pspec", "parent": 123, "children": [126, 127], "start_point": {"row": 88, "column": 18}, "end_point": {"row": 88, "column": 24}}, {"id": 126, "type": "*", "text": "*", "parent": 125, "children": [], "start_point": {"row": 88, "column": 18}, "end_point": {"row": 88, "column": 19}}, {"id": 127, "type": "identifier", "text": "pspec", "parent": 125, "children": [], "start_point": {"row": 88, "column": 19}, "end_point": {"row": 88, "column": 24}}, {"id": 128, "type": "declaration", "text": "GtkScaleButton *button = GTK_SCALE_BUTTON (object);", "parent": 105, "children": [129, 130], "start_point": {"row": 90, "column": 2}, "end_point": {"row": 90, "column": 53}}, {"id": 129, "type": "type_identifier", "text": "GtkScaleButton", "parent": 128, "children": [], "start_point": {"row": 90, "column": 2}, "end_point": {"row": 90, "column": 16}}, {"id": 130, "type": "init_declarator", "text": "*button = GTK_SCALE_BUTTON (object)", "parent": 128, "children": [131, 134, 135], "start_point": {"row": 90, "column": 17}, "end_point": {"row": 90, "column": 52}}, {"id": 131, "type": "pointer_declarator", "text": "*button", "parent": 130, "children": [132, 133], "start_point": {"row": 90, "column": 17}, "end_point": {"row": 90, "column": 24}}, {"id": 132, "type": "*", "text": "*", "parent": 131, "children": [], "start_point": {"row": 90, "column": 17}, "end_point": {"row": 90, "column": 18}}, {"id": 133, "type": "identifier", "text": "button", "parent": 131, "children": [], "start_point": {"row": 90, "column": 18}, "end_point": {"row": 90, "column": 24}}, {"id": 134, "type": "=", "text": "=", "parent": 130, "children": [], "start_point": {"row": 90, "column": 25}, "end_point": {"row": 90, "column": 26}}, {"id": 135, "type": "call_expression", "text": "GTK_SCALE_BUTTON (object)", "parent": 130, "children": [136, 137], "start_point": {"row": 90, "column": 27}, "end_point": {"row": 90, "column": 52}}, {"id": 136, "type": "identifier", "text": "GTK_SCALE_BUTTON", "parent": 135, "children": [], "start_point": {"row": 90, "column": 27}, "end_point": {"row": 90, "column": 43}}, {"id": 137, "type": "argument_list", "text": "(object)", "parent": 135, "children": [138], "start_point": {"row": 90, "column": 44}, "end_point": {"row": 90, "column": 52}}, {"id": 138, "type": "identifier", "text": "object", "parent": 137, "children": [], "start_point": {"row": 90, "column": 45}, "end_point": {"row": 90, "column": 51}}, {"id": 139, "type": "switch_statement", "text": "switch (prop_id)\n {\n case PROP_SYMBOLIC:\n if (g_value_get_boolean (value))\n gtk_scale_button_set_icons (button, (const char **) icons_symbolic);\n else\n\tgtk_scale_button_set_icons (button, (const char **) icons);\n break;\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }", "parent": 105, "children": [140, 141], "start_point": {"row": 92, "column": 2}, "end_point": {"row": 103, "column": 5}}, {"id": 140, "type": "switch", "text": "switch", "parent": 139, "children": [], "start_point": {"row": 92, "column": 2}, "end_point": {"row": 92, "column": 8}}, {"id": 141, "type": "parenthesized_expression", "text": "(prop_id)", "parent": 139, "children": [142], "start_point": {"row": 92, "column": 9}, "end_point": {"row": 92, "column": 18}}, {"id": 142, "type": "identifier", "text": "prop_id", "parent": 141, "children": [], "start_point": {"row": 92, "column": 10}, "end_point": {"row": 92, "column": 17}}, {"id": 143, "type": "case_statement", "text": "case PROP_SYMBOLIC:\n if (g_value_get_boolean (value))\n gtk_scale_button_set_icons (button, (const char **) icons_symbolic);\n else\n\tgtk_scale_button_set_icons (button, (const char **) icons);\n break;", "parent": 139, "children": [144, 145, 146, 177], "start_point": {"row": 94, "column": 4}, "end_point": {"row": 99, "column": 12}}, {"id": 144, "type": "case", "text": "case", "parent": 143, "children": [], "start_point": {"row": 94, "column": 4}, "end_point": {"row": 94, "column": 8}}, {"id": 145, "type": "identifier", "text": "PROP_SYMBOLIC", "parent": 143, "children": [], "start_point": {"row": 94, "column": 9}, "end_point": {"row": 94, "column": 22}}, {"id": 146, "type": "if_statement", "text": "if (g_value_get_boolean (value))\n gtk_scale_button_set_icons (button, (const char **) icons_symbolic);\n else\n\tgtk_scale_button_set_icons (button, (const char **) icons);", "parent": 143, "children": [147, 164], "start_point": {"row": 95, "column": 6}, "end_point": {"row": 98, "column": 60}}, {"id": 147, "type": "parenthesized_expression", "text": "(g_value_get_boolean (value))", "parent": 146, "children": [148], "start_point": {"row": 95, "column": 9}, "end_point": {"row": 95, "column": 38}}, {"id": 148, "type": "call_expression", "text": "g_value_get_boolean (value)", "parent": 147, "children": [149, 150], "start_point": {"row": 95, "column": 10}, "end_point": {"row": 95, "column": 37}}, {"id": 149, "type": "identifier", "text": "g_value_get_boolean", "parent": 148, "children": [], "start_point": {"row": 95, "column": 10}, "end_point": {"row": 95, "column": 29}}, {"id": 150, "type": "argument_list", "text": "(value)", "parent": 148, "children": [151], "start_point": {"row": 95, "column": 30}, "end_point": {"row": 95, "column": 37}}, {"id": 151, "type": "identifier", "text": "value", "parent": 150, "children": [], "start_point": {"row": 95, "column": 31}, "end_point": {"row": 95, "column": 36}}, {"id": 152, "type": "call_expression", "text": "gtk_scale_button_set_icons (button, (const char **) icons_symbolic)", "parent": 146, "children": [153, 154], "start_point": {"row": 96, "column": 8}, "end_point": {"row": 96, "column": 75}}, {"id": 153, "type": "identifier", "text": "gtk_scale_button_set_icons", "parent": 152, "children": [], "start_point": {"row": 96, "column": 8}, "end_point": {"row": 96, "column": 34}}, {"id": 154, "type": "argument_list", "text": "(button, (const char **) icons_symbolic)", "parent": 152, "children": [155, 156], "start_point": {"row": 96, "column": 35}, "end_point": {"row": 96, "column": 75}}, {"id": 155, "type": "identifier", "text": "button", "parent": 154, "children": [], "start_point": {"row": 96, "column": 36}, "end_point": {"row": 96, "column": 42}}, {"id": 156, "type": "cast_expression", "text": "(const char **) icons_symbolic", "parent": 154, "children": [157, 163], "start_point": {"row": 96, "column": 44}, "end_point": {"row": 96, "column": 74}}, {"id": 157, "type": "type_descriptor", "text": "const char **", "parent": 156, "children": [158, 159], "start_point": {"row": 96, "column": 45}, "end_point": {"row": 96, "column": 58}}, {"id": 158, "type": "primitive_type", "text": "char", "parent": 157, "children": [], "start_point": {"row": 96, "column": 51}, "end_point": {"row": 96, "column": 55}}, {"id": 159, "type": "abstract_pointer_declarator", "text": "**", "parent": 157, "children": [160, 161], "start_point": {"row": 96, "column": 56}, "end_point": {"row": 96, "column": 58}}, {"id": 160, "type": "*", "text": "*", "parent": 159, "children": [], "start_point": {"row": 96, "column": 56}, "end_point": {"row": 96, "column": 57}}, {"id": 161, "type": "abstract_pointer_declarator", "text": "*", "parent": 159, "children": [162], "start_point": {"row": 96, "column": 57}, "end_point": {"row": 96, "column": 58}}, {"id": 162, "type": "*", "text": "*", "parent": 161, "children": [], "start_point": {"row": 96, "column": 57}, "end_point": {"row": 96, "column": 58}}, {"id": 163, "type": "identifier", "text": "icons_symbolic", "parent": 156, "children": [], "start_point": {"row": 96, "column": 60}, "end_point": {"row": 96, "column": 74}}, {"id": 164, "type": "else_clause", "text": "else\n\tgtk_scale_button_set_icons (button, (const char **) icons);", "parent": 146, "children": [], "start_point": {"row": 97, "column": 6}, "end_point": {"row": 98, "column": 60}}, {"id": 165, "type": "call_expression", "text": "gtk_scale_button_set_icons (button, (const char **) icons)", "parent": 164, "children": [166, 167], "start_point": {"row": 98, "column": 1}, "end_point": {"row": 98, "column": 59}}, {"id": 166, "type": "identifier", "text": "gtk_scale_button_set_icons", "parent": 165, "children": [], "start_point": {"row": 98, "column": 1}, "end_point": {"row": 98, "column": 27}}, {"id": 167, "type": "argument_list", "text": "(button, (const char **) icons)", "parent": 165, "children": [168, 169], "start_point": {"row": 98, "column": 28}, "end_point": {"row": 98, "column": 59}}, {"id": 168, "type": "identifier", "text": "button", "parent": 167, "children": [], "start_point": {"row": 98, "column": 29}, "end_point": {"row": 98, "column": 35}}, {"id": 169, "type": "cast_expression", "text": "(const char **) icons", "parent": 167, "children": [170, 176], "start_point": {"row": 98, "column": 37}, "end_point": {"row": 98, "column": 58}}, {"id": 170, "type": "type_descriptor", "text": "const char **", "parent": 169, "children": [171, 172], "start_point": {"row": 98, "column": 38}, "end_point": {"row": 98, "column": 51}}, {"id": 171, "type": "primitive_type", "text": "char", "parent": 170, "children": [], "start_point": {"row": 98, "column": 44}, "end_point": {"row": 98, "column": 48}}, {"id": 172, "type": "abstract_pointer_declarator", "text": "**", "parent": 170, "children": [173, 174], "start_point": {"row": 98, "column": 49}, "end_point": {"row": 98, "column": 51}}, {"id": 173, "type": "*", "text": "*", "parent": 172, "children": [], "start_point": {"row": 98, "column": 49}, "end_point": {"row": 98, "column": 50}}, {"id": 174, "type": "abstract_pointer_declarator", "text": "*", "parent": 172, "children": [175], "start_point": {"row": 98, "column": 50}, "end_point": {"row": 98, "column": 51}}, {"id": 175, "type": "*", "text": "*", "parent": 174, "children": [], "start_point": {"row": 98, "column": 50}, "end_point": {"row": 98, "column": 51}}, {"id": 176, "type": "identifier", "text": "icons", "parent": 169, "children": [], "start_point": {"row": 98, "column": 53}, "end_point": {"row": 98, "column": 58}}, {"id": 177, "type": "break_statement", "text": "break;", "parent": 143, "children": [178], "start_point": {"row": 99, "column": 6}, "end_point": {"row": 99, "column": 12}}, {"id": 178, "type": "break", "text": "break", "parent": 177, "children": [], "start_point": {"row": 99, "column": 6}, "end_point": {"row": 99, "column": 11}}, {"id": 179, "type": "case_statement", "text": "default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;", "parent": 139, "children": [180, 187], "start_point": {"row": 100, "column": 4}, "end_point": {"row": 102, "column": 12}}, {"id": 180, "type": "default", "text": "default", "parent": 179, "children": [], "start_point": {"row": 100, "column": 4}, "end_point": {"row": 100, "column": 11}}, {"id": 181, "type": "call_expression", "text": "G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec)", "parent": 179, "children": [182, 183], "start_point": {"row": 101, "column": 6}, "end_point": {"row": 101, "column": 64}}, {"id": 182, "type": "identifier", "text": "G_OBJECT_WARN_INVALID_PROPERTY_ID", "parent": 181, "children": [], "start_point": {"row": 101, "column": 6}, "end_point": {"row": 101, "column": 39}}, {"id": 183, "type": "argument_list", "text": "(object, prop_id, pspec)", "parent": 181, "children": [184, 185, 186], "start_point": {"row": 101, "column": 40}, "end_point": {"row": 101, "column": 64}}, {"id": 184, "type": "identifier", "text": "object", "parent": 183, "children": [], "start_point": {"row": 101, "column": 41}, "end_point": {"row": 101, "column": 47}}, {"id": 185, "type": "identifier", "text": "prop_id", "parent": 183, "children": [], "start_point": {"row": 101, "column": 49}, "end_point": {"row": 101, "column": 56}}, {"id": 186, "type": "identifier", "text": "pspec", "parent": 183, "children": [], "start_point": {"row": 101, "column": 58}, "end_point": {"row": 101, "column": 63}}, {"id": 187, "type": "break_statement", "text": "break;", "parent": 179, "children": [188], "start_point": {"row": 102, "column": 6}, "end_point": {"row": 102, "column": 12}}, {"id": 188, "type": "break", "text": "break", "parent": 187, "children": [], "start_point": {"row": 102, "column": 6}, "end_point": {"row": 102, "column": 11}}, {"id": 189, "type": "function_definition", "text": "static void\ngtk_volume_button_get_property (GObject *object,\n\t\t\t guint prop_id,\n\t\t\t GValue *value,\n\t\t\t GParamSpec *pspec)\n{\n switch (prop_id)\n {\n case PROP_SYMBOLIC: {\n char **icon_list;\n\n g_object_get (object, \"icons\", &icon_list, NULL);\n if (icon_list != NULL &&\n\t icon_list[0] != NULL &&\n \t g_str_equal (icon_list[0], icons_symbolic[0]))\n g_value_set_boolean (value, TRUE);\n else\n g_value_set_boolean (value, FALSE);\n g_strfreev (icon_list);\n break;\n }\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }\n}", "parent": null, "children": [190, 191], "start_point": {"row": 106, "column": 0}, "end_point": {"row": 131, "column": 1}}, {"id": 190, "type": "primitive_type", "text": "void", "parent": 189, "children": [], "start_point": {"row": 106, "column": 7}, "end_point": {"row": 106, "column": 11}}, {"id": 191, "type": "function_declarator", "text": "gtk_volume_button_get_property (GObject *object,\n\t\t\t guint prop_id,\n\t\t\t GValue *value,\n\t\t\t GParamSpec *pspec)", "parent": 189, "children": [192, 193], "start_point": {"row": 107, "column": 0}, "end_point": {"row": 110, "column": 30}}, {"id": 192, "type": "identifier", "text": "gtk_volume_button_get_property", "parent": 191, "children": [], "start_point": {"row": 107, "column": 0}, "end_point": {"row": 107, "column": 30}}, {"id": 193, "type": "parameter_list", "text": "(GObject *object,\n\t\t\t guint prop_id,\n\t\t\t GValue *value,\n\t\t\t GParamSpec *pspec)", "parent": 191, "children": [194, 199, 202, 207], "start_point": {"row": 107, "column": 31}, "end_point": {"row": 110, "column": 30}}, {"id": 194, "type": "parameter_declaration", "text": "GObject *object", "parent": 193, "children": [195, 196], "start_point": {"row": 107, "column": 32}, "end_point": {"row": 107, "column": 51}}, {"id": 195, "type": "type_identifier", "text": "GObject", "parent": 194, "children": [], "start_point": {"row": 107, "column": 32}, "end_point": {"row": 107, "column": 39}}, {"id": 196, "type": "pointer_declarator", "text": "*object", "parent": 194, "children": [197, 198], "start_point": {"row": 107, "column": 44}, "end_point": {"row": 107, "column": 51}}, {"id": 197, "type": "*", "text": "*", "parent": 196, "children": [], "start_point": {"row": 107, "column": 44}, "end_point": {"row": 107, "column": 45}}, {"id": 198, "type": "identifier", "text": "object", "parent": 196, "children": [], "start_point": {"row": 107, "column": 45}, "end_point": {"row": 107, "column": 51}}, {"id": 199, "type": "parameter_declaration", "text": "guint prop_id", "parent": 193, "children": [200, 201], "start_point": {"row": 108, "column": 11}, "end_point": {"row": 108, "column": 31}}, {"id": 200, "type": "type_identifier", "text": "guint", "parent": 199, "children": [], "start_point": {"row": 108, "column": 11}, "end_point": {"row": 108, "column": 16}}, {"id": 201, "type": "identifier", "text": "prop_id", "parent": 199, "children": [], "start_point": {"row": 108, "column": 24}, "end_point": {"row": 108, "column": 31}}, {"id": 202, "type": "parameter_declaration", "text": "GValue *value", "parent": 193, "children": [203, 204], "start_point": {"row": 109, "column": 11}, "end_point": {"row": 109, "column": 29}}, {"id": 203, "type": "type_identifier", "text": "GValue", "parent": 202, "children": [], "start_point": {"row": 109, "column": 11}, "end_point": {"row": 109, "column": 17}}, {"id": 204, "type": "pointer_declarator", "text": "*value", "parent": 202, "children": [205, 206], "start_point": {"row": 109, "column": 23}, "end_point": {"row": 109, "column": 29}}, {"id": 205, "type": "*", "text": "*", "parent": 204, "children": [], "start_point": {"row": 109, "column": 23}, "end_point": {"row": 109, "column": 24}}, {"id": 206, "type": "identifier", "text": "value", "parent": 204, "children": [], "start_point": {"row": 109, "column": 24}, "end_point": {"row": 109, "column": 29}}, {"id": 207, "type": "parameter_declaration", "text": "GParamSpec *pspec", "parent": 193, "children": [208, 209], "start_point": {"row": 110, "column": 11}, "end_point": {"row": 110, "column": 29}}, {"id": 208, "type": "type_identifier", "text": "GParamSpec", "parent": 207, "children": [], "start_point": {"row": 110, "column": 11}, "end_point": {"row": 110, "column": 21}}, {"id": 209, "type": "pointer_declarator", "text": "*pspec", "parent": 207, "children": [210, 211], "start_point": {"row": 110, "column": 23}, "end_point": {"row": 110, "column": 29}}, {"id": 210, "type": "*", "text": "*", "parent": 209, "children": [], "start_point": {"row": 110, "column": 23}, "end_point": {"row": 110, "column": 24}}, {"id": 211, "type": "identifier", "text": "pspec", "parent": 209, "children": [], "start_point": {"row": 110, "column": 24}, "end_point": {"row": 110, "column": 29}}, {"id": 212, "type": "switch_statement", "text": "switch (prop_id)\n {\n case PROP_SYMBOLIC: {\n char **icon_list;\n\n g_object_get (object, \"icons\", &icon_list, NULL);\n if (icon_list != NULL &&\n\t icon_list[0] != NULL &&\n \t g_str_equal (icon_list[0], icons_symbolic[0]))\n g_value_set_boolean (value, TRUE);\n else\n g_value_set_boolean (value, FALSE);\n g_strfreev (icon_list);\n break;\n }\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }", "parent": 189, "children": [213, 214], "start_point": {"row": 112, "column": 2}, "end_point": {"row": 130, "column": 5}}, {"id": 213, "type": "switch", "text": "switch", "parent": 212, "children": [], "start_point": {"row": 112, "column": 2}, "end_point": {"row": 112, "column": 8}}, {"id": 214, "type": "parenthesized_expression", "text": "(prop_id)", "parent": 212, "children": [215], "start_point": {"row": 112, "column": 9}, "end_point": {"row": 112, "column": 18}}, {"id": 215, "type": "identifier", "text": "prop_id", "parent": 214, "children": [], "start_point": {"row": 112, "column": 10}, "end_point": {"row": 112, "column": 17}}, {"id": 216, "type": "case_statement", "text": "case PROP_SYMBOLIC: {\n char **icon_list;\n\n g_object_get (object, \"icons\", &icon_list, NULL);\n if (icon_list != NULL &&\n\t icon_list[0] != NULL &&\n \t g_str_equal (icon_list[0], icons_symbolic[0]))\n g_value_set_boolean (value, TRUE);\n else\n g_value_set_boolean (value, FALSE);\n g_strfreev (icon_list);\n break;\n }", "parent": 212, "children": [217, 218], "start_point": {"row": 114, "column": 4}, "end_point": {"row": 126, "column": 5}}, {"id": 217, "type": "case", "text": "case", "parent": 216, "children": [], "start_point": {"row": 114, "column": 4}, "end_point": {"row": 114, "column": 8}}, {"id": 218, "type": "identifier", "text": "PROP_SYMBOLIC", "parent": 216, "children": [], "start_point": {"row": 114, "column": 9}, "end_point": {"row": 114, "column": 22}}, {"id": 219, "type": "declaration", "text": "char **icon_list;", "parent": 216, "children": [220, 221], "start_point": {"row": 115, "column": 6}, "end_point": {"row": 115, "column": 23}}, {"id": 220, "type": "primitive_type", "text": "char", "parent": 219, "children": [], "start_point": {"row": 115, "column": 6}, "end_point": {"row": 115, "column": 10}}, {"id": 221, "type": "pointer_declarator", "text": "**icon_list", "parent": 219, "children": [222, 223], "start_point": {"row": 115, "column": 11}, "end_point": {"row": 115, "column": 22}}, {"id": 222, "type": "*", "text": "*", "parent": 221, "children": [], "start_point": {"row": 115, "column": 11}, "end_point": {"row": 115, "column": 12}}, {"id": 223, "type": "pointer_declarator", "text": "*icon_list", "parent": 221, "children": [224, 225], "start_point": {"row": 115, "column": 12}, "end_point": {"row": 115, "column": 22}}, {"id": 224, "type": "*", "text": "*", "parent": 223, "children": [], "start_point": {"row": 115, "column": 12}, "end_point": {"row": 115, "column": 13}}, {"id": 225, "type": "identifier", "text": "icon_list", "parent": 223, "children": [], "start_point": {"row": 115, "column": 13}, "end_point": {"row": 115, "column": 22}}, {"id": 226, "type": "call_expression", "text": "g_object_get (object, \"icons\", &icon_list, NULL)", "parent": 216, "children": [227, 228], "start_point": {"row": 117, "column": 6}, "end_point": {"row": 117, "column": 54}}, {"id": 227, "type": "identifier", "text": "g_object_get", "parent": 226, "children": [], "start_point": {"row": 117, "column": 6}, "end_point": {"row": 117, "column": 18}}, {"id": 228, "type": "argument_list", "text": "(object, \"icons\", &icon_list, NULL)", "parent": 226, "children": [229, 230, 231, 233], "start_point": {"row": 117, "column": 19}, "end_point": {"row": 117, "column": 54}}, {"id": 229, "type": "identifier", "text": "object", "parent": 228, "children": [], "start_point": {"row": 117, "column": 20}, "end_point": {"row": 117, "column": 26}}, {"id": 230, "type": "string_literal", "text": "\"icons\"", "parent": 228, "children": [], "start_point": {"row": 117, "column": 28}, "end_point": {"row": 117, "column": 35}}, {"id": 231, "type": "pointer_expression", "text": "&icon_list", "parent": 228, "children": [232], "start_point": {"row": 117, "column": 37}, "end_point": {"row": 117, "column": 47}}, {"id": 232, "type": "identifier", "text": "icon_list", "parent": 231, "children": [], "start_point": {"row": 117, "column": 38}, "end_point": {"row": 117, "column": 47}}, {"id": 233, "type": "null", "text": "NULL", "parent": 228, "children": [234], "start_point": {"row": 117, "column": 49}, "end_point": {"row": 117, "column": 53}}, {"id": 234, "type": "NULL", "text": "NULL", "parent": 233, "children": [], "start_point": {"row": 117, "column": 49}, "end_point": {"row": 117, "column": 53}}, {"id": 235, "type": "if_statement", "text": "if (icon_list != NULL &&\n\t icon_list[0] != NULL &&\n \t g_str_equal (icon_list[0], icons_symbolic[0]))\n g_value_set_boolean (value, TRUE);\n else\n g_value_set_boolean (value, FALSE);", "parent": 216, "children": [236, 267], "start_point": {"row": 118, "column": 6}, "end_point": {"row": 123, "column": 43}}, {"id": 236, "type": "parenthesized_expression", "text": "(icon_list != NULL &&\n\t icon_list[0] != NULL &&\n \t g_str_equal (icon_list[0], icons_symbolic[0]))", "parent": 235, "children": [237], "start_point": {"row": 118, "column": 9}, "end_point": {"row": 120, "column": 55}}, {"id": 237, "type": "binary_expression", "text": "icon_list != NULL &&\n\t icon_list[0] != NULL &&\n \t g_str_equal (icon_list[0], icons_symbolic[0])", "parent": 236, "children": [238, 252, 253], "start_point": {"row": 118, "column": 10}, "end_point": {"row": 120, "column": 54}}, {"id": 238, "type": "binary_expression", "text": "icon_list != NULL &&\n\t icon_list[0] != NULL", "parent": 237, "children": [239, 244, 245], "start_point": {"row": 118, "column": 10}, "end_point": {"row": 119, "column": 23}}, {"id": 239, "type": "binary_expression", "text": "icon_list != NULL", "parent": 238, "children": [240, 241, 242], "start_point": {"row": 118, "column": 10}, "end_point": {"row": 118, "column": 27}}, {"id": 240, "type": "identifier", "text": "icon_list", "parent": 239, "children": [], "start_point": {"row": 118, "column": 10}, "end_point": {"row": 118, "column": 19}}, {"id": 241, "type": "!=", "text": "!=", "parent": 239, "children": [], "start_point": {"row": 118, "column": 20}, "end_point": {"row": 118, "column": 22}}, {"id": 242, "type": "null", "text": "NULL", "parent": 239, "children": [243], "start_point": {"row": 118, "column": 23}, "end_point": {"row": 118, "column": 27}}, {"id": 243, "type": "NULL", "text": "NULL", "parent": 242, "children": [], "start_point": {"row": 118, "column": 23}, "end_point": {"row": 118, "column": 27}}, {"id": 244, "type": "&&", "text": "&&", "parent": 238, "children": [], "start_point": {"row": 118, "column": 28}, "end_point": {"row": 118, "column": 30}}, {"id": 245, "type": "binary_expression", "text": "icon_list[0] != NULL", "parent": 238, "children": [246, 249, 250], "start_point": {"row": 119, "column": 3}, "end_point": {"row": 119, "column": 23}}, {"id": 246, "type": "subscript_expression", "text": "icon_list[0]", "parent": 245, "children": [247, 248], "start_point": {"row": 119, "column": 3}, "end_point": {"row": 119, "column": 15}}, {"id": 247, "type": "identifier", "text": "icon_list", "parent": 246, "children": [], "start_point": {"row": 119, "column": 3}, "end_point": {"row": 119, "column": 12}}, {"id": 248, "type": "number_literal", "text": "0", "parent": 246, "children": [], "start_point": {"row": 119, "column": 13}, "end_point": {"row": 119, "column": 14}}, {"id": 249, "type": "!=", "text": "!=", "parent": 245, "children": [], "start_point": {"row": 119, "column": 16}, "end_point": {"row": 119, "column": 18}}, {"id": 250, "type": "null", "text": "NULL", "parent": 245, "children": [251], "start_point": {"row": 119, "column": 19}, "end_point": {"row": 119, "column": 23}}, {"id": 251, "type": "NULL", "text": "NULL", "parent": 250, "children": [], "start_point": {"row": 119, "column": 19}, "end_point": {"row": 119, "column": 23}}, {"id": 252, "type": "&&", "text": "&&", "parent": 237, "children": [], "start_point": {"row": 119, "column": 24}, "end_point": {"row": 119, "column": 26}}, {"id": 253, "type": "call_expression", "text": "g_str_equal (icon_list[0], icons_symbolic[0])", "parent": 237, "children": [254, 255], "start_point": {"row": 120, "column": 9}, "end_point": {"row": 120, "column": 54}}, {"id": 254, "type": "identifier", "text": "g_str_equal", "parent": 253, "children": [], "start_point": {"row": 120, "column": 9}, "end_point": {"row": 120, "column": 20}}, {"id": 255, "type": "argument_list", "text": "(icon_list[0], icons_symbolic[0])", "parent": 253, "children": [256, 259], "start_point": {"row": 120, "column": 21}, "end_point": {"row": 120, "column": 54}}, {"id": 256, "type": "subscript_expression", "text": "icon_list[0]", "parent": 255, "children": [257, 258], "start_point": {"row": 120, "column": 22}, "end_point": {"row": 120, "column": 34}}, {"id": 257, "type": "identifier", "text": "icon_list", "parent": 256, "children": [], "start_point": {"row": 120, "column": 22}, "end_point": {"row": 120, "column": 31}}, {"id": 258, "type": "number_literal", "text": "0", "parent": 256, "children": [], "start_point": {"row": 120, "column": 32}, "end_point": {"row": 120, "column": 33}}, {"id": 259, "type": "subscript_expression", "text": "icons_symbolic[0]", "parent": 255, "children": [260, 261], "start_point": {"row": 120, "column": 36}, "end_point": {"row": 120, "column": 53}}, {"id": 260, "type": "identifier", "text": "icons_symbolic", "parent": 259, "children": [], "start_point": {"row": 120, "column": 36}, "end_point": {"row": 120, "column": 50}}, {"id": 261, "type": "number_literal", "text": "0", "parent": 259, "children": [], "start_point": {"row": 120, "column": 51}, "end_point": {"row": 120, "column": 52}}, {"id": 262, "type": "call_expression", "text": "g_value_set_boolean (value, TRUE)", "parent": 235, "children": [263, 264], "start_point": {"row": 121, "column": 8}, "end_point": {"row": 121, "column": 41}}, {"id": 263, "type": "identifier", "text": "g_value_set_boolean", "parent": 262, "children": [], "start_point": {"row": 121, "column": 8}, "end_point": {"row": 121, "column": 27}}, {"id": 264, "type": "argument_list", "text": "(value, TRUE)", "parent": 262, "children": [265, 266], "start_point": {"row": 121, "column": 28}, "end_point": {"row": 121, "column": 41}}, {"id": 265, "type": "identifier", "text": "value", "parent": 264, "children": [], "start_point": {"row": 121, "column": 29}, "end_point": {"row": 121, "column": 34}}, {"id": 266, "type": "true", "text": "TRUE", "parent": 264, "children": [], "start_point": {"row": 121, "column": 36}, "end_point": {"row": 121, "column": 40}}, {"id": 267, "type": "else_clause", "text": "else\n g_value_set_boolean (value, FALSE);", "parent": 235, "children": [], "start_point": {"row": 122, "column": 6}, "end_point": {"row": 123, "column": 43}}, {"id": 268, "type": "call_expression", "text": "g_value_set_boolean (value, FALSE)", "parent": 267, "children": [269, 270], "start_point": {"row": 123, "column": 8}, "end_point": {"row": 123, "column": 42}}, {"id": 269, "type": "identifier", "text": "g_value_set_boolean", "parent": 268, "children": [], "start_point": {"row": 123, "column": 8}, "end_point": {"row": 123, "column": 27}}, {"id": 270, "type": "argument_list", "text": "(value, FALSE)", "parent": 268, "children": [271, 272], "start_point": {"row": 123, "column": 28}, "end_point": {"row": 123, "column": 42}}, {"id": 271, "type": "identifier", "text": "value", "parent": 270, "children": [], "start_point": {"row": 123, "column": 29}, "end_point": {"row": 123, "column": 34}}, {"id": 272, "type": "false", "text": "FALSE", "parent": 270, "children": [], "start_point": {"row": 123, "column": 36}, "end_point": {"row": 123, "column": 41}}, {"id": 273, "type": "call_expression", "text": "g_strfreev (icon_list)", "parent": 216, "children": [274, 275], "start_point": {"row": 124, "column": 6}, "end_point": {"row": 124, "column": 28}}, {"id": 274, "type": "identifier", "text": "g_strfreev", "parent": 273, "children": [], "start_point": {"row": 124, "column": 6}, "end_point": {"row": 124, "column": 16}}, {"id": 275, "type": "argument_list", "text": "(icon_list)", "parent": 273, "children": [276], "start_point": {"row": 124, "column": 17}, "end_point": {"row": 124, "column": 28}}, {"id": 276, "type": "identifier", "text": "icon_list", "parent": 275, "children": [], "start_point": {"row": 124, "column": 18}, "end_point": {"row": 124, "column": 27}}, {"id": 277, "type": "break_statement", "text": "break;", "parent": 216, "children": [278], "start_point": {"row": 125, "column": 6}, "end_point": {"row": 125, "column": 12}}, {"id": 278, "type": "break", "text": "break", "parent": 277, "children": [], "start_point": {"row": 125, "column": 6}, "end_point": {"row": 125, "column": 11}}, {"id": 279, "type": "case_statement", "text": "default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;", "parent": 212, "children": [280, 287], "start_point": {"row": 127, "column": 4}, "end_point": {"row": 129, "column": 12}}, {"id": 280, "type": "default", "text": "default", "parent": 279, "children": [], "start_point": {"row": 127, "column": 4}, "end_point": {"row": 127, "column": 11}}, {"id": 281, "type": "call_expression", "text": "G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec)", "parent": 279, "children": [282, 283], "start_point": {"row": 128, "column": 6}, "end_point": {"row": 128, "column": 64}}, {"id": 282, "type": "identifier", "text": "G_OBJECT_WARN_INVALID_PROPERTY_ID", "parent": 281, "children": [], "start_point": {"row": 128, "column": 6}, "end_point": {"row": 128, "column": 39}}, {"id": 283, "type": "argument_list", "text": "(object, prop_id, pspec)", "parent": 281, "children": [284, 285, 286], "start_point": {"row": 128, "column": 40}, "end_point": {"row": 128, "column": 64}}, {"id": 284, "type": "identifier", "text": "object", "parent": 283, "children": [], "start_point": {"row": 128, "column": 41}, "end_point": {"row": 128, "column": 47}}, {"id": 285, "type": "identifier", "text": "prop_id", "parent": 283, "children": [], "start_point": {"row": 128, "column": 49}, "end_point": {"row": 128, "column": 56}}, {"id": 286, "type": "identifier", "text": "pspec", "parent": 283, "children": [], "start_point": {"row": 128, "column": 58}, "end_point": {"row": 128, "column": 63}}, {"id": 287, "type": "break_statement", "text": "break;", "parent": 279, "children": [288], "start_point": {"row": 129, "column": 6}, "end_point": {"row": 129, "column": 12}}, {"id": 288, "type": "break", "text": "break", "parent": 287, "children": [], "start_point": {"row": 129, "column": 6}, "end_point": {"row": 129, "column": 11}}, {"id": 289, "type": "function_definition", "text": "static void\ngtk_volume_button_class_init (GtkVolumeButtonClass *klass)\n{\n GObjectClass *gobject_class = G_OBJECT_CLASS (klass);\n GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);\n\n gobject_class->set_property = gtk_volume_button_set_property;\n gobject_class->get_property = gtk_volume_button_get_property;\n\n /**\n * GtkVolumeButton:use-symbolic:\n *\n * Whether to use symbolic icons as the icons. Note that\n * if the symbolic icons are not available in your installed\n * theme, then the normal (potentially colorful) icons will\n * be used.\n *\n * Since: 3.0\n */\n g_object_class_install_property (gobject_class,\n PROP_SYMBOLIC,\n g_param_spec_boolean (\"use-symbolic\",\n P_(\"Use symbolic icons\"),\n P_(\"Whether to use symbolic icons\"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT));\n\n /* Bind class to template\n */\n gtk_widget_class_set_template_from_resource (widget_class, \"/org/gtk/libgtk/ui/gtkvolumebutton.ui\");\n gtk_widget_class_bind_template_callback (widget_class, cb_query_tooltip);\n gtk_widget_class_bind_template_callback (widget_class, cb_value_changed);\n}", "parent": null, "children": [290, 291], "start_point": {"row": 133, "column": 0}, "end_point": {"row": 165, "column": 1}}, {"id": 290, "type": "primitive_type", "text": "void", "parent": 289, "children": [], "start_point": {"row": 133, "column": 7}, "end_point": {"row": 133, "column": 11}}, {"id": 291, "type": "function_declarator", "text": "gtk_volume_button_class_init (GtkVolumeButtonClass *klass)", "parent": 289, "children": [292, 293], "start_point": {"row": 134, "column": 0}, "end_point": {"row": 134, "column": 58}}, {"id": 292, "type": "identifier", "text": "gtk_volume_button_class_init", "parent": 291, "children": [], "start_point": {"row": 134, "column": 0}, "end_point": {"row": 134, "column": 28}}, {"id": 293, "type": "parameter_list", "text": "(GtkVolumeButtonClass *klass)", "parent": 291, "children": [294], "start_point": {"row": 134, "column": 29}, "end_point": {"row": 134, "column": 58}}, {"id": 294, "type": "parameter_declaration", "text": "GtkVolumeButtonClass *klass", "parent": 293, "children": [295, 296], "start_point": {"row": 134, "column": 30}, "end_point": {"row": 134, "column": 57}}, {"id": 295, "type": "type_identifier", "text": "GtkVolumeButtonClass", "parent": 294, "children": [], "start_point": {"row": 134, "column": 30}, "end_point": {"row": 134, "column": 50}}, {"id": 296, "type": "pointer_declarator", "text": "*klass", "parent": 294, "children": [297, 298], "start_point": {"row": 134, "column": 51}, "end_point": {"row": 134, "column": 57}}, {"id": 297, "type": "*", "text": "*", "parent": 296, "children": [], "start_point": {"row": 134, "column": 51}, "end_point": {"row": 134, "column": 52}}, {"id": 298, "type": "identifier", "text": "klass", "parent": 296, "children": [], "start_point": {"row": 134, "column": 52}, "end_point": {"row": 134, "column": 57}}, {"id": 299, "type": "declaration", "text": "GObjectClass *gobject_class = G_OBJECT_CLASS (klass);", "parent": 289, "children": [300, 301], "start_point": {"row": 136, "column": 2}, "end_point": {"row": 136, "column": 55}}, {"id": 300, "type": "type_identifier", "text": "GObjectClass", "parent": 299, "children": [], "start_point": {"row": 136, "column": 2}, "end_point": {"row": 136, "column": 14}}, {"id": 301, "type": "init_declarator", "text": "*gobject_class = G_OBJECT_CLASS (klass)", "parent": 299, "children": [302, 305, 306], "start_point": {"row": 136, "column": 15}, "end_point": {"row": 136, "column": 54}}, {"id": 302, "type": "pointer_declarator", "text": "*gobject_class", "parent": 301, "children": [303, 304], "start_point": {"row": 136, "column": 15}, "end_point": {"row": 136, "column": 29}}, {"id": 303, "type": "*", "text": "*", "parent": 302, "children": [], "start_point": {"row": 136, "column": 15}, "end_point": {"row": 136, "column": 16}}, {"id": 304, "type": "identifier", "text": "gobject_class", "parent": 302, "children": [], "start_point": {"row": 136, "column": 16}, "end_point": {"row": 136, "column": 29}}, {"id": 305, "type": "=", "text": "=", "parent": 301, "children": [], "start_point": {"row": 136, "column": 30}, "end_point": {"row": 136, "column": 31}}, {"id": 306, "type": "call_expression", "text": "G_OBJECT_CLASS (klass)", "parent": 301, "children": [307, 308], "start_point": {"row": 136, "column": 32}, "end_point": {"row": 136, "column": 54}}, {"id": 307, "type": "identifier", "text": "G_OBJECT_CLASS", "parent": 306, "children": [], "start_point": {"row": 136, "column": 32}, "end_point": {"row": 136, "column": 46}}, {"id": 308, "type": "argument_list", "text": "(klass)", "parent": 306, "children": [309], "start_point": {"row": 136, "column": 47}, "end_point": {"row": 136, "column": 54}}, {"id": 309, "type": "identifier", "text": "klass", "parent": 308, "children": [], "start_point": {"row": 136, "column": 48}, "end_point": {"row": 136, "column": 53}}, {"id": 310, "type": "declaration", "text": "GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);", "parent": 289, "children": [311, 312], "start_point": {"row": 137, "column": 2}, "end_point": {"row": 137, "column": 58}}, {"id": 311, "type": "type_identifier", "text": "GtkWidgetClass", "parent": 310, "children": [], "start_point": {"row": 137, "column": 2}, "end_point": {"row": 137, "column": 16}}, {"id": 312, "type": "init_declarator", "text": "*widget_class = GTK_WIDGET_CLASS (klass)", "parent": 310, "children": [313, 316, 317], "start_point": {"row": 137, "column": 17}, "end_point": {"row": 137, "column": 57}}, {"id": 313, "type": "pointer_declarator", "text": "*widget_class", "parent": 312, "children": [314, 315], "start_point": {"row": 137, "column": 17}, "end_point": {"row": 137, "column": 30}}, {"id": 314, "type": "*", "text": "*", "parent": 313, "children": [], "start_point": {"row": 137, "column": 17}, "end_point": {"row": 137, "column": 18}}, {"id": 315, "type": "identifier", "text": "widget_class", "parent": 313, "children": [], "start_point": {"row": 137, "column": 18}, "end_point": {"row": 137, "column": 30}}, {"id": 316, "type": "=", "text": "=", "parent": 312, "children": [], "start_point": {"row": 137, "column": 31}, "end_point": {"row": 137, "column": 32}}, {"id": 317, "type": "call_expression", "text": "GTK_WIDGET_CLASS (klass)", "parent": 312, "children": [318, 319], "start_point": {"row": 137, "column": 33}, "end_point": {"row": 137, "column": 57}}, {"id": 318, "type": "identifier", "text": "GTK_WIDGET_CLASS", "parent": 317, "children": [], "start_point": {"row": 137, "column": 33}, "end_point": {"row": 137, "column": 49}}, {"id": 319, "type": "argument_list", "text": "(klass)", "parent": 317, "children": [320], "start_point": {"row": 137, "column": 50}, "end_point": {"row": 137, "column": 57}}, {"id": 320, "type": "identifier", "text": "klass", "parent": 319, "children": [], "start_point": {"row": 137, "column": 51}, "end_point": {"row": 137, "column": 56}}, {"id": 321, "type": "assignment_expression", "text": "gobject_class->set_property = gtk_volume_button_set_property", "parent": 289, "children": [322, 325, 326], "start_point": {"row": 139, "column": 2}, "end_point": {"row": 139, "column": 62}}, {"id": 322, "type": "field_expression", "text": "gobject_class->set_property", "parent": 321, "children": [323, 324], "start_point": {"row": 139, "column": 2}, "end_point": {"row": 139, "column": 29}}, {"id": 323, "type": "identifier", "text": "gobject_class", "parent": 322, "children": [], "start_point": {"row": 139, "column": 2}, "end_point": {"row": 139, "column": 15}}, {"id": 324, "type": "field_identifier", "text": "set_property", "parent": 322, "children": [], "start_point": {"row": 139, "column": 17}, "end_point": {"row": 139, "column": 29}}, {"id": 325, "type": "=", "text": "=", "parent": 321, "children": [], "start_point": {"row": 139, "column": 30}, "end_point": {"row": 139, "column": 31}}, {"id": 326, "type": "identifier", "text": "gtk_volume_button_set_property", "parent": 321, "children": [], "start_point": {"row": 139, "column": 32}, "end_point": {"row": 139, "column": 62}}, {"id": 327, "type": "assignment_expression", "text": "gobject_class->get_property = gtk_volume_button_get_property", "parent": 289, "children": [328, 331, 332], "start_point": {"row": 140, "column": 2}, "end_point": {"row": 140, "column": 62}}, {"id": 328, "type": "field_expression", "text": "gobject_class->get_property", "parent": 327, "children": [329, 330], "start_point": {"row": 140, "column": 2}, "end_point": {"row": 140, "column": 29}}, {"id": 329, "type": "identifier", "text": "gobject_class", "parent": 328, "children": [], "start_point": {"row": 140, "column": 2}, "end_point": {"row": 140, "column": 15}}, {"id": 330, "type": "field_identifier", "text": "get_property", "parent": 328, "children": [], "start_point": {"row": 140, "column": 17}, "end_point": {"row": 140, "column": 29}}, {"id": 331, "type": "=", "text": "=", "parent": 327, "children": [], "start_point": {"row": 140, "column": 30}, "end_point": {"row": 140, "column": 31}}, {"id": 332, "type": "identifier", "text": "gtk_volume_button_get_property", "parent": 327, "children": [], "start_point": {"row": 140, "column": 32}, "end_point": {"row": 140, "column": 62}}, {"id": 333, "type": "call_expression", "text": "g_object_class_install_property (gobject_class,\n PROP_SYMBOLIC,\n g_param_spec_boolean (\"use-symbolic\",\n P_(\"Use symbolic icons\"),\n P_(\"Whether to use symbolic icons\"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT))", "parent": 289, "children": [334, 335], "start_point": {"row": 152, "column": 2}, "end_point": {"row": 158, "column": 94}}, {"id": 334, "type": "identifier", "text": "g_object_class_install_property", "parent": 333, "children": [], "start_point": {"row": 152, "column": 2}, "end_point": {"row": 152, "column": 33}}, {"id": 335, "type": "argument_list", "text": "(gobject_class,\n PROP_SYMBOLIC,\n g_param_spec_boolean (\"use-symbolic\",\n P_(\"Use symbolic icons\"),\n P_(\"Whether to use symbolic icons\"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT))", "parent": 333, "children": [336, 337, 338], "start_point": {"row": 152, "column": 34}, "end_point": {"row": 158, "column": 94}}, {"id": 336, "type": "identifier", "text": "gobject_class", "parent": 335, "children": [], "start_point": {"row": 152, "column": 35}, "end_point": {"row": 152, "column": 48}}, {"id": 337, "type": "identifier", "text": "PROP_SYMBOLIC", "parent": 335, "children": [], "start_point": {"row": 153, "column": 35}, "end_point": {"row": 153, "column": 48}}, {"id": 338, "type": "call_expression", "text": "g_param_spec_boolean (\"use-symbolic\",\n P_(\"Use symbolic icons\"),\n P_(\"Whether to use symbolic icons\"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT)", "parent": 335, "children": [339, 340], "start_point": {"row": 154, "column": 35}, "end_point": {"row": 158, "column": 93}}, {"id": 339, "type": "identifier", "text": "g_param_spec_boolean", "parent": 338, "children": [], "start_point": {"row": 154, "column": 35}, "end_point": {"row": 154, "column": 55}}, {"id": 340, "type": "argument_list", "text": "(\"use-symbolic\",\n P_(\"Use symbolic icons\"),\n P_(\"Whether to use symbolic icons\"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT)", "parent": 338, "children": [341, 342, 346, 350, 351], "start_point": {"row": 154, "column": 56}, "end_point": {"row": 158, "column": 93}}, {"id": 341, "type": "string_literal", "text": "\"use-symbolic\"", "parent": 340, "children": [], "start_point": {"row": 154, "column": 57}, "end_point": {"row": 154, "column": 71}}, {"id": 342, "type": "call_expression", "text": "P_(\"Use symbolic icons\")", "parent": 340, "children": [343, 344], "start_point": {"row": 155, "column": 57}, "end_point": {"row": 155, "column": 81}}, {"id": 343, "type": "identifier", "text": "P_", "parent": 342, "children": [], "start_point": {"row": 155, "column": 57}, "end_point": {"row": 155, "column": 59}}, {"id": 344, "type": "argument_list", "text": "(\"Use symbolic icons\")", "parent": 342, "children": [345], "start_point": {"row": 155, "column": 59}, "end_point": {"row": 155, "column": 81}}, {"id": 345, "type": "string_literal", "text": "\"Use symbolic icons\"", "parent": 344, "children": [], "start_point": {"row": 155, "column": 60}, "end_point": {"row": 155, "column": 80}}, {"id": 346, "type": "call_expression", "text": "P_(\"Whether to use symbolic icons\")", "parent": 340, "children": [347, 348], "start_point": {"row": 156, "column": 57}, "end_point": {"row": 156, "column": 92}}, {"id": 347, "type": "identifier", "text": "P_", "parent": 346, "children": [], "start_point": {"row": 156, "column": 57}, "end_point": {"row": 156, "column": 59}}, {"id": 348, "type": "argument_list", "text": "(\"Whether to use symbolic icons\")", "parent": 346, "children": [349], "start_point": {"row": 156, "column": 59}, "end_point": {"row": 156, "column": 92}}, {"id": 349, "type": "string_literal", "text": "\"Whether to use symbolic icons\"", "parent": 348, "children": [], "start_point": {"row": 156, "column": 60}, "end_point": {"row": 156, "column": 91}}, {"id": 350, "type": "true", "text": "TRUE", "parent": 340, "children": [], "start_point": {"row": 157, "column": 57}, "end_point": {"row": 157, "column": 61}}, {"id": 351, "type": "binary_expression", "text": "G_PARAM_READWRITE|G_PARAM_CONSTRUCT", "parent": 340, "children": [352, 353], "start_point": {"row": 158, "column": 57}, "end_point": {"row": 158, "column": 92}}, {"id": 352, "type": "identifier", "text": "G_PARAM_READWRITE", "parent": 351, "children": [], "start_point": {"row": 158, "column": 57}, "end_point": {"row": 158, "column": 74}}, {"id": 353, "type": "identifier", "text": "G_PARAM_CONSTRUCT", "parent": 351, "children": [], "start_point": {"row": 158, "column": 75}, "end_point": {"row": 158, "column": 92}}, {"id": 354, "type": "call_expression", "text": "gtk_widget_class_set_template_from_resource (widget_class, \"/org/gtk/libgtk/ui/gtkvolumebutton.ui\")", "parent": 289, "children": [355, 356], "start_point": {"row": 162, "column": 2}, "end_point": {"row": 162, "column": 101}}, {"id": 355, "type": "identifier", "text": "gtk_widget_class_set_template_from_resource", "parent": 354, "children": [], "start_point": {"row": 162, "column": 2}, "end_point": {"row": 162, "column": 45}}, {"id": 356, "type": "argument_list", "text": "(widget_class, \"/org/gtk/libgtk/ui/gtkvolumebutton.ui\")", "parent": 354, "children": [357, 358], "start_point": {"row": 162, "column": 46}, "end_point": {"row": 162, "column": 101}}, {"id": 357, "type": "identifier", "text": "widget_class", "parent": 356, "children": [], "start_point": {"row": 162, "column": 47}, "end_point": {"row": 162, "column": 59}}, {"id": 358, "type": "string_literal", "text": "\"/org/gtk/libgtk/ui/gtkvolumebutton.ui\"", "parent": 356, "children": [], "start_point": {"row": 162, "column": 61}, "end_point": {"row": 162, "column": 100}}, {"id": 359, "type": "call_expression", "text": "gtk_widget_class_bind_template_callback (widget_class, cb_query_tooltip)", "parent": 289, "children": [360, 361], "start_point": {"row": 163, "column": 2}, "end_point": {"row": 163, "column": 74}}, {"id": 360, "type": "identifier", "text": "gtk_widget_class_bind_template_callback", "parent": 359, "children": [], "start_point": {"row": 163, "column": 2}, "end_point": {"row": 163, "column": 41}}, {"id": 361, "type": "argument_list", "text": "(widget_class, cb_query_tooltip)", "parent": 359, "children": [362, 363], "start_point": {"row": 163, "column": 42}, "end_point": {"row": 163, "column": 74}}, {"id": 362, "type": "identifier", "text": "widget_class", "parent": 361, "children": [], "start_point": {"row": 163, "column": 43}, "end_point": {"row": 163, "column": 55}}, {"id": 363, "type": "identifier", "text": "cb_query_tooltip", "parent": 361, "children": [], "start_point": {"row": 163, "column": 57}, "end_point": {"row": 163, "column": 73}}, {"id": 364, "type": "call_expression", "text": "gtk_widget_class_bind_template_callback (widget_class, cb_value_changed)", "parent": 289, "children": [365, 366], "start_point": {"row": 164, "column": 2}, "end_point": {"row": 164, "column": 74}}, {"id": 365, "type": "identifier", "text": "gtk_widget_class_bind_template_callback", "parent": 364, "children": [], "start_point": {"row": 164, "column": 2}, "end_point": {"row": 164, "column": 41}}, {"id": 366, "type": "argument_list", "text": "(widget_class, cb_value_changed)", "parent": 364, "children": [367, 368], "start_point": {"row": 164, "column": 42}, "end_point": {"row": 164, "column": 74}}, {"id": 367, "type": "identifier", "text": "widget_class", "parent": 366, "children": [], "start_point": {"row": 164, "column": 43}, "end_point": {"row": 164, "column": 55}}, {"id": 368, "type": "identifier", "text": "cb_value_changed", "parent": 366, "children": [], "start_point": {"row": 164, "column": 57}, "end_point": {"row": 164, "column": 73}}, {"id": 369, "type": "function_definition", "text": "static void\ngtk_volume_button_init (GtkVolumeButton *button)\n{\n GtkWidget *widget = GTK_WIDGET (button);\n\n gtk_widget_init_template (widget);\n\n /* The atk action description is not supported by GtkBuilder */\n atk_action_set_description (ATK_ACTION (gtk_widget_get_accessible (GTK_WIDGET (widget))),\n\t\t\t 1, _(\"Adjusts the volume\"));\n}", "parent": null, "children": [370, 371], "start_point": {"row": 167, "column": 0}, "end_point": {"row": 177, "column": 1}}, {"id": 370, "type": "primitive_type", "text": "void", "parent": 369, "children": [], "start_point": {"row": 167, "column": 7}, "end_point": {"row": 167, "column": 11}}, {"id": 371, "type": "function_declarator", "text": "gtk_volume_button_init (GtkVolumeButton *button)", "parent": 369, "children": [372, 373], "start_point": {"row": 168, "column": 0}, "end_point": {"row": 168, "column": 48}}, {"id": 372, "type": "identifier", "text": "gtk_volume_button_init", "parent": 371, "children": [], "start_point": {"row": 168, "column": 0}, "end_point": {"row": 168, "column": 22}}, {"id": 373, "type": "parameter_list", "text": "(GtkVolumeButton *button)", "parent": 371, "children": [374], "start_point": {"row": 168, "column": 23}, "end_point": {"row": 168, "column": 48}}, {"id": 374, "type": "parameter_declaration", "text": "GtkVolumeButton *button", "parent": 373, "children": [375, 376], "start_point": {"row": 168, "column": 24}, "end_point": {"row": 168, "column": 47}}, {"id": 375, "type": "type_identifier", "text": "GtkVolumeButton", "parent": 374, "children": [], "start_point": {"row": 168, "column": 24}, "end_point": {"row": 168, "column": 39}}, {"id": 376, "type": "pointer_declarator", "text": "*button", "parent": 374, "children": [377, 378], "start_point": {"row": 168, "column": 40}, "end_point": {"row": 168, "column": 47}}, {"id": 377, "type": "*", "text": "*", "parent": 376, "children": [], "start_point": {"row": 168, "column": 40}, "end_point": {"row": 168, "column": 41}}, {"id": 378, "type": "identifier", "text": "button", "parent": 376, "children": [], "start_point": {"row": 168, "column": 41}, "end_point": {"row": 168, "column": 47}}, {"id": 379, "type": "declaration", "text": "GtkWidget *widget = GTK_WIDGET (button);", "parent": 369, "children": [380, 381], "start_point": {"row": 170, "column": 2}, "end_point": {"row": 170, "column": 42}}, {"id": 380, "type": "type_identifier", "text": "GtkWidget", "parent": 379, "children": [], "start_point": {"row": 170, "column": 2}, "end_point": {"row": 170, "column": 11}}, {"id": 381, "type": "init_declarator", "text": "*widget = GTK_WIDGET (button)", "parent": 379, "children": [382, 385, 386], "start_point": {"row": 170, "column": 12}, "end_point": {"row": 170, "column": 41}}, {"id": 382, "type": "pointer_declarator", "text": "*widget", "parent": 381, "children": [383, 384], "start_point": {"row": 170, "column": 12}, "end_point": {"row": 170, "column": 19}}, {"id": 383, "type": "*", "text": "*", "parent": 382, "children": [], "start_point": {"row": 170, "column": 12}, "end_point": {"row": 170, "column": 13}}, {"id": 384, "type": "identifier", "text": "widget", "parent": 382, "children": [], "start_point": {"row": 170, "column": 13}, "end_point": {"row": 170, "column": 19}}, {"id": 385, "type": "=", "text": "=", "parent": 381, "children": [], "start_point": {"row": 170, "column": 20}, "end_point": {"row": 170, "column": 21}}, {"id": 386, "type": "call_expression", "text": "GTK_WIDGET (button)", "parent": 381, "children": [387, 388], "start_point": {"row": 170, "column": 22}, "end_point": {"row": 170, "column": 41}}, {"id": 387, "type": "identifier", "text": "GTK_WIDGET", "parent": 386, "children": [], "start_point": {"row": 170, "column": 22}, "end_point": {"row": 170, "column": 32}}, {"id": 388, "type": "argument_list", "text": "(button)", "parent": 386, "children": [389], "start_point": {"row": 170, "column": 33}, "end_point": {"row": 170, "column": 41}}, {"id": 389, "type": "identifier", "text": "button", "parent": 388, "children": [], "start_point": {"row": 170, "column": 34}, "end_point": {"row": 170, "column": 40}}, {"id": 390, "type": "call_expression", "text": "gtk_widget_init_template (widget)", "parent": 369, "children": [391, 392], "start_point": {"row": 172, "column": 2}, "end_point": {"row": 172, "column": 35}}, {"id": 391, "type": "identifier", "text": "gtk_widget_init_template", "parent": 390, "children": [], "start_point": {"row": 172, "column": 2}, "end_point": {"row": 172, "column": 26}}, {"id": 392, "type": "argument_list", "text": "(widget)", "parent": 390, "children": [393], "start_point": {"row": 172, "column": 27}, "end_point": {"row": 172, "column": 35}}, {"id": 393, "type": "identifier", "text": "widget", "parent": 392, "children": [], "start_point": {"row": 172, "column": 28}, "end_point": {"row": 172, "column": 34}}, {"id": 394, "type": "call_expression", "text": "atk_action_set_description (ATK_ACTION (gtk_widget_get_accessible (GTK_WIDGET (widget))),\n\t\t\t 1, _(\"Adjusts the volume\"))", "parent": 369, "children": [395, 396], "start_point": {"row": 175, "column": 2}, "end_point": {"row": 176, "column": 36}}, {"id": 395, "type": "identifier", "text": "atk_action_set_description", "parent": 394, "children": [], "start_point": {"row": 175, "column": 2}, "end_point": {"row": 175, "column": 28}}, {"id": 396, "type": "argument_list", "text": "(ATK_ACTION (gtk_widget_get_accessible (GTK_WIDGET (widget))),\n\t\t\t 1, _(\"Adjusts the volume\"))", "parent": 394, "children": [397, 407, 408], "start_point": {"row": 175, "column": 29}, "end_point": {"row": 176, "column": 36}}, {"id": 397, "type": "call_expression", "text": "ATK_ACTION (gtk_widget_get_accessible (GTK_WIDGET (widget)))", "parent": 396, "children": [398, 399], "start_point": {"row": 175, "column": 30}, "end_point": {"row": 175, "column": 90}}, {"id": 398, "type": "identifier", "text": "ATK_ACTION", "parent": 397, "children": [], "start_point": {"row": 175, "column": 30}, "end_point": {"row": 175, "column": 40}}, {"id": 399, "type": "argument_list", "text": "(gtk_widget_get_accessible (GTK_WIDGET (widget)))", "parent": 397, "children": [400], "start_point": {"row": 175, "column": 41}, "end_point": {"row": 175, "column": 90}}, {"id": 400, "type": "call_expression", "text": "gtk_widget_get_accessible (GTK_WIDGET (widget))", "parent": 399, "children": [401, 402], "start_point": {"row": 175, "column": 42}, "end_point": {"row": 175, "column": 89}}, {"id": 401, "type": "identifier", "text": "gtk_widget_get_accessible", "parent": 400, "children": [], "start_point": {"row": 175, "column": 42}, "end_point": {"row": 175, "column": 67}}, {"id": 402, "type": "argument_list", "text": "(GTK_WIDGET (widget))", "parent": 400, "children": [403], "start_point": {"row": 175, "column": 68}, "end_point": {"row": 175, "column": 89}}, {"id": 403, "type": "call_expression", "text": "GTK_WIDGET (widget)", "parent": 402, "children": [404, 405], "start_point": {"row": 175, "column": 69}, "end_point": {"row": 175, "column": 88}}, {"id": 404, "type": "identifier", "text": "GTK_WIDGET", "parent": 403, "children": [], "start_point": {"row": 175, "column": 69}, "end_point": {"row": 175, "column": 79}}, {"id": 405, "type": "argument_list", "text": "(widget)", "parent": 403, "children": [406], "start_point": {"row": 175, "column": 80}, "end_point": {"row": 175, "column": 88}}, {"id": 406, "type": "identifier", "text": "widget", "parent": 405, "children": [], "start_point": {"row": 175, "column": 81}, "end_point": {"row": 175, "column": 87}}, {"id": 407, "type": "number_literal", "text": "1", "parent": 396, "children": [], "start_point": {"row": 176, "column": 9}, "end_point": {"row": 176, "column": 10}}, {"id": 408, "type": "call_expression", "text": "_(\"Adjusts the volume\")", "parent": 396, "children": [409, 410], "start_point": {"row": 176, "column": 12}, "end_point": {"row": 176, "column": 35}}, {"id": 409, "type": "identifier", "text": "_", "parent": 408, "children": [], "start_point": {"row": 176, "column": 12}, "end_point": {"row": 176, "column": 13}}, {"id": 410, "type": "argument_list", "text": "(\"Adjusts the volume\")", "parent": 408, "children": [411], "start_point": {"row": 176, "column": 13}, "end_point": {"row": 176, "column": 35}}, {"id": 411, "type": "string_literal", "text": "\"Adjusts the volume\"", "parent": 410, "children": [], "start_point": {"row": 176, "column": 14}, "end_point": {"row": 176, "column": 34}}, {"id": 412, "type": "function_definition", "text": "GtkWidget *\ngtk_volume_button_new (void)\n{\n GObject *button;\n button = g_object_new (GTK_TYPE_VOLUME_BUTTON, NULL);\n return GTK_WIDGET (button);\n}", "parent": null, "children": [413, 414], "start_point": {"row": 190, "column": 0}, "end_point": {"row": 196, "column": 1}}, {"id": 413, "type": "type_identifier", "text": "GtkWidget", "parent": 412, "children": [], "start_point": {"row": 190, "column": 0}, "end_point": {"row": 190, "column": 9}}, {"id": 414, "type": "pointer_declarator", "text": "*\ngtk_volume_button_new (void)", "parent": 412, "children": [415, 416], "start_point": {"row": 190, "column": 10}, "end_point": {"row": 191, "column": 28}}, {"id": 415, "type": "*", "text": "*", "parent": 414, "children": [], "start_point": {"row": 190, "column": 10}, "end_point": {"row": 190, "column": 11}}, {"id": 416, "type": "function_declarator", "text": "gtk_volume_button_new (void)", "parent": 414, "children": [417, 418], "start_point": {"row": 191, "column": 0}, "end_point": {"row": 191, "column": 28}}, {"id": 417, "type": "identifier", "text": "gtk_volume_button_new", "parent": 416, "children": [], "start_point": {"row": 191, "column": 0}, "end_point": {"row": 191, "column": 21}}, {"id": 418, "type": "parameter_list", "text": "(void)", "parent": 416, "children": [419], "start_point": {"row": 191, "column": 22}, "end_point": {"row": 191, "column": 28}}, {"id": 419, "type": "parameter_declaration", "text": "void", "parent": 418, "children": [420], "start_point": {"row": 191, "column": 23}, "end_point": {"row": 191, "column": 27}}, {"id": 420, "type": "primitive_type", "text": "void", "parent": 419, "children": [], "start_point": {"row": 191, "column": 23}, "end_point": {"row": 191, "column": 27}}, {"id": 421, "type": "declaration", "text": "GObject *button;", "parent": 412, "children": [422, 423], "start_point": {"row": 193, "column": 2}, "end_point": {"row": 193, "column": 18}}, {"id": 422, "type": "type_identifier", "text": "GObject", "parent": 421, "children": [], "start_point": {"row": 193, "column": 2}, "end_point": {"row": 193, "column": 9}}, {"id": 423, "type": "pointer_declarator", "text": "*button", "parent": 421, "children": [424, 425], "start_point": {"row": 193, "column": 10}, "end_point": {"row": 193, "column": 17}}, {"id": 424, "type": "*", "text": "*", "parent": 423, "children": [], "start_point": {"row": 193, "column": 10}, "end_point": {"row": 193, "column": 11}}, {"id": 425, "type": "identifier", "text": "button", "parent": 423, "children": [], "start_point": {"row": 193, "column": 11}, "end_point": {"row": 193, "column": 17}}, {"id": 426, "type": "assignment_expression", "text": "button = g_object_new (GTK_TYPE_VOLUME_BUTTON, NULL)", "parent": 412, "children": [427, 428, 429], "start_point": {"row": 194, "column": 2}, "end_point": {"row": 194, "column": 54}}, {"id": 427, "type": "identifier", "text": "button", "parent": 426, "children": [], "start_point": {"row": 194, "column": 2}, "end_point": {"row": 194, "column": 8}}, {"id": 428, "type": "=", "text": "=", "parent": 426, "children": [], "start_point": {"row": 194, "column": 9}, "end_point": {"row": 194, "column": 10}}, {"id": 429, "type": "call_expression", "text": "g_object_new (GTK_TYPE_VOLUME_BUTTON, NULL)", "parent": 426, "children": [430, 431], "start_point": {"row": 194, "column": 11}, "end_point": {"row": 194, "column": 54}}, {"id": 430, "type": "identifier", "text": "g_object_new", "parent": 429, "children": [], "start_point": {"row": 194, "column": 11}, "end_point": {"row": 194, "column": 23}}, {"id": 431, "type": "argument_list", "text": "(GTK_TYPE_VOLUME_BUTTON, NULL)", "parent": 429, "children": [432, 433], "start_point": {"row": 194, "column": 24}, "end_point": {"row": 194, "column": 54}}, {"id": 432, "type": "identifier", "text": "GTK_TYPE_VOLUME_BUTTON", "parent": 431, "children": [], "start_point": {"row": 194, "column": 25}, "end_point": {"row": 194, "column": 47}}, {"id": 433, "type": "null", "text": "NULL", "parent": 431, "children": [434], "start_point": {"row": 194, "column": 49}, "end_point": {"row": 194, "column": 53}}, {"id": 434, "type": "NULL", "text": "NULL", "parent": 433, "children": [], "start_point": {"row": 194, "column": 49}, "end_point": {"row": 194, "column": 53}}, {"id": 435, "type": "return_statement", "text": "return GTK_WIDGET (button);", "parent": 412, "children": [436], "start_point": {"row": 195, "column": 2}, "end_point": {"row": 195, "column": 29}}, {"id": 436, "type": "call_expression", "text": "GTK_WIDGET (button)", "parent": 435, "children": [437, 438], "start_point": {"row": 195, "column": 9}, "end_point": {"row": 195, "column": 28}}, {"id": 437, "type": "identifier", "text": "GTK_WIDGET", "parent": 436, "children": [], "start_point": {"row": 195, "column": 9}, "end_point": {"row": 195, "column": 19}}, {"id": 438, "type": "argument_list", "text": "(button)", "parent": 436, "children": [439], "start_point": {"row": 195, "column": 20}, "end_point": {"row": 195, "column": 28}}, {"id": 439, "type": "identifier", "text": "button", "parent": 438, "children": [], "start_point": {"row": 195, "column": 21}, "end_point": {"row": 195, "column": 27}}, {"id": 440, "type": "function_definition", "text": "static gboolean\ncb_query_tooltip (GtkWidget *button,\n\t\t gint x,\n\t\t gint y,\n\t\t gboolean keyboard_mode,\n\t\t GtkTooltip *tooltip,\n\t\t gpointer user_data)\n{\n GtkScaleButton *scale_button = GTK_SCALE_BUTTON (button);\n GtkAdjustment *adjustment;\n gdouble val;\n char *str;\n AtkImage *image;\n\n image = ATK_IMAGE (gtk_widget_get_accessible (button));\n\n adjustment = gtk_scale_button_get_adjustment (scale_button);\n val = gtk_scale_button_get_value (scale_button);\n\n if (val < (gtk_adjustment_get_lower (adjustment) + EPSILON))\n {\n str = g_strdup (_(\"Muted\"));\n }\n else if (val >= (gtk_adjustment_get_upper (adjustment) - EPSILON))\n {\n str = g_strdup (_(\"Full Volume\"));\n }\n else\n {\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. \"49 %\".\n * Translate the \"%d\" to \"%Id\" if you want to use localised digits,\n * or otherwise translate the \"%d\" to \"%d\".\n */\n str = g_strdup_printf (C_(\"volume percentage\", \"%d %%\"), percent);\n }\n\n gtk_tooltip_set_text (tooltip, str);\n atk_image_set_image_description (image, str);\n g_free (str);\n\n return TRUE;\n}", "parent": null, "children": [441, 442], "start_point": {"row": 198, "column": 0}, "end_point": {"row": 244, "column": 1}}, {"id": 441, "type": "type_identifier", "text": "gboolean", "parent": 440, "children": [], "start_point": {"row": 198, "column": 7}, "end_point": {"row": 198, "column": 15}}, {"id": 442, "type": "function_declarator", "text": "cb_query_tooltip (GtkWidget *button,\n\t\t gint x,\n\t\t gint y,\n\t\t gboolean keyboard_mode,\n\t\t GtkTooltip *tooltip,\n\t\t gpointer user_data)", "parent": 440, "children": [443, 444], "start_point": {"row": 199, "column": 0}, "end_point": {"row": 204, "column": 26}}, {"id": 443, "type": "identifier", "text": "cb_query_tooltip", "parent": 442, "children": [], "start_point": {"row": 199, "column": 0}, "end_point": {"row": 199, "column": 16}}, {"id": 444, "type": "parameter_list", "text": "(GtkWidget *button,\n\t\t gint x,\n\t\t gint y,\n\t\t gboolean keyboard_mode,\n\t\t GtkTooltip *tooltip,\n\t\t gpointer user_data)", "parent": 442, "children": [445, 450, 453, 456, 459, 464], "start_point": {"row": 199, "column": 17}, "end_point": {"row": 204, "column": 26}}, {"id": 445, "type": "parameter_declaration", "text": "GtkWidget *button", "parent": 444, "children": [446, 447], "start_point": {"row": 199, "column": 18}, "end_point": {"row": 199, "column": 36}}, {"id": 446, "type": "type_identifier", "text": "GtkWidget", "parent": 445, "children": [], "start_point": {"row": 199, "column": 18}, "end_point": {"row": 199, "column": 27}}, {"id": 447, "type": "pointer_declarator", "text": "*button", "parent": 445, "children": [448, 449], "start_point": {"row": 199, "column": 29}, "end_point": {"row": 199, "column": 36}}, {"id": 448, "type": "*", "text": "*", "parent": 447, "children": [], "start_point": {"row": 199, "column": 29}, "end_point": {"row": 199, "column": 30}}, {"id": 449, "type": "identifier", "text": "button", "parent": 447, "children": [], "start_point": {"row": 199, "column": 30}, "end_point": {"row": 199, "column": 36}}, {"id": 450, "type": "parameter_declaration", "text": "gint x", "parent": 444, "children": [451, 452], "start_point": {"row": 200, "column": 4}, "end_point": {"row": 200, "column": 17}}, {"id": 451, "type": "type_identifier", "text": "gint", "parent": 450, "children": [], "start_point": {"row": 200, "column": 4}, "end_point": {"row": 200, "column": 8}}, {"id": 452, "type": "identifier", "text": "x", "parent": 450, "children": [], "start_point": {"row": 200, "column": 16}, "end_point": {"row": 200, "column": 17}}, {"id": 453, "type": "parameter_declaration", "text": "gint y", "parent": 444, "children": [454, 455], "start_point": {"row": 201, "column": 4}, "end_point": {"row": 201, "column": 17}}, {"id": 454, "type": "type_identifier", "text": "gint", "parent": 453, "children": [], "start_point": {"row": 201, "column": 4}, "end_point": {"row": 201, "column": 8}}, {"id": 455, "type": "identifier", "text": "y", "parent": 453, "children": [], "start_point": {"row": 201, "column": 16}, "end_point": {"row": 201, "column": 17}}, {"id": 456, "type": "parameter_declaration", "text": "gboolean keyboard_mode", "parent": 444, "children": [457, 458], "start_point": {"row": 202, "column": 4}, "end_point": {"row": 202, "column": 29}}, {"id": 457, "type": "type_identifier", "text": "gboolean", "parent": 456, "children": [], "start_point": {"row": 202, "column": 4}, "end_point": {"row": 202, "column": 12}}, {"id": 458, "type": "identifier", "text": "keyboard_mode", "parent": 456, "children": [], "start_point": {"row": 202, "column": 16}, "end_point": {"row": 202, "column": 29}}, {"id": 459, "type": "parameter_declaration", "text": "GtkTooltip *tooltip", "parent": 444, "children": [460, 461], "start_point": {"row": 203, "column": 4}, "end_point": {"row": 203, "column": 23}}, {"id": 460, "type": "type_identifier", "text": "GtkTooltip", "parent": 459, "children": [], "start_point": {"row": 203, "column": 4}, "end_point": {"row": 203, "column": 14}}, {"id": 461, "type": "pointer_declarator", "text": "*tooltip", "parent": 459, "children": [462, 463], "start_point": {"row": 203, "column": 15}, "end_point": {"row": 203, "column": 23}}, {"id": 462, "type": "*", "text": "*", "parent": 461, "children": [], "start_point": {"row": 203, "column": 15}, "end_point": {"row": 203, "column": 16}}, {"id": 463, "type": "identifier", "text": "tooltip", "parent": 461, "children": [], "start_point": {"row": 203, "column": 16}, "end_point": {"row": 203, "column": 23}}, {"id": 464, "type": "parameter_declaration", "text": "gpointer user_data", "parent": 444, "children": [465, 466], "start_point": {"row": 204, "column": 4}, "end_point": {"row": 204, "column": 25}}, {"id": 465, "type": "type_identifier", "text": "gpointer", "parent": 464, "children": [], "start_point": {"row": 204, "column": 4}, "end_point": {"row": 204, "column": 12}}, {"id": 466, "type": "identifier", "text": "user_data", "parent": 464, "children": [], "start_point": {"row": 204, "column": 16}, "end_point": {"row": 204, "column": 25}}, {"id": 467, "type": "declaration", "text": "GtkScaleButton *scale_button = GTK_SCALE_BUTTON (button);", "parent": 440, "children": [468, 469], "start_point": {"row": 206, "column": 2}, "end_point": {"row": 206, "column": 59}}, {"id": 468, "type": "type_identifier", "text": "GtkScaleButton", "parent": 467, "children": [], "start_point": {"row": 206, "column": 2}, "end_point": {"row": 206, "column": 16}}, {"id": 469, "type": "init_declarator", "text": "*scale_button = GTK_SCALE_BUTTON (button)", "parent": 467, "children": [470, 473, 474], "start_point": {"row": 206, "column": 17}, "end_point": {"row": 206, "column": 58}}, {"id": 470, "type": "pointer_declarator", "text": "*scale_button", "parent": 469, "children": [471, 472], "start_point": {"row": 206, "column": 17}, "end_point": {"row": 206, "column": 30}}, {"id": 471, "type": "*", "text": "*", "parent": 470, "children": [], "start_point": {"row": 206, "column": 17}, "end_point": {"row": 206, "column": 18}}, {"id": 472, "type": "identifier", "text": "scale_button", "parent": 470, "children": [], "start_point": {"row": 206, "column": 18}, "end_point": {"row": 206, "column": 30}}, {"id": 473, "type": "=", "text": "=", "parent": 469, "children": [], "start_point": {"row": 206, "column": 31}, "end_point": {"row": 206, "column": 32}}, {"id": 474, "type": "call_expression", "text": "GTK_SCALE_BUTTON (button)", "parent": 469, "children": [475, 476], "start_point": {"row": 206, "column": 33}, "end_point": {"row": 206, "column": 58}}, {"id": 475, "type": "identifier", "text": "GTK_SCALE_BUTTON", "parent": 474, "children": [], "start_point": {"row": 206, "column": 33}, "end_point": {"row": 206, "column": 49}}, {"id": 476, "type": "argument_list", "text": "(button)", "parent": 474, "children": [477], "start_point": {"row": 206, "column": 50}, "end_point": {"row": 206, "column": 58}}, {"id": 477, "type": "identifier", "text": "button", "parent": 476, "children": [], "start_point": {"row": 206, "column": 51}, "end_point": {"row": 206, "column": 57}}, {"id": 478, "type": "declaration", "text": "GtkAdjustment *adjustment;", "parent": 440, "children": [479, 480], "start_point": {"row": 207, "column": 2}, "end_point": {"row": 207, "column": 28}}, {"id": 479, "type": "type_identifier", "text": "GtkAdjustment", "parent": 478, "children": [], "start_point": {"row": 207, "column": 2}, "end_point": {"row": 207, "column": 15}}, {"id": 480, "type": "pointer_declarator", "text": "*adjustment", "parent": 478, "children": [481, 482], "start_point": {"row": 207, "column": 16}, "end_point": {"row": 207, "column": 27}}, {"id": 481, "type": "*", "text": "*", "parent": 480, "children": [], "start_point": {"row": 207, "column": 16}, "end_point": {"row": 207, "column": 17}}, {"id": 482, "type": "identifier", "text": "adjustment", "parent": 480, "children": [], "start_point": {"row": 207, "column": 17}, "end_point": {"row": 207, "column": 27}}, {"id": 483, "type": "declaration", "text": "gdouble val;", "parent": 440, "children": [484, 485], "start_point": {"row": 208, "column": 2}, "end_point": {"row": 208, "column": 14}}, {"id": 484, "type": "type_identifier", "text": "gdouble", "parent": 483, "children": [], "start_point": {"row": 208, "column": 2}, "end_point": {"row": 208, "column": 9}}, {"id": 485, "type": "identifier", "text": "val", "parent": 483, "children": [], "start_point": {"row": 208, "column": 10}, "end_point": {"row": 208, "column": 13}}, {"id": 486, "type": "declaration", "text": "char *str;", "parent": 440, "children": [487, 488], "start_point": {"row": 209, "column": 2}, "end_point": {"row": 209, "column": 12}}, {"id": 487, "type": "primitive_type", "text": "char", "parent": 486, "children": [], "start_point": {"row": 209, "column": 2}, "end_point": {"row": 209, "column": 6}}, {"id": 488, "type": "pointer_declarator", "text": "*str", "parent": 486, "children": [489, 490], "start_point": {"row": 209, "column": 7}, "end_point": {"row": 209, "column": 11}}, {"id": 489, "type": "*", "text": "*", "parent": 488, "children": [], "start_point": {"row": 209, "column": 7}, "end_point": {"row": 209, "column": 8}}, {"id": 490, "type": "identifier", "text": "str", "parent": 488, "children": [], "start_point": {"row": 209, "column": 8}, "end_point": {"row": 209, "column": 11}}, {"id": 491, "type": "declaration", "text": "AtkImage *image;", "parent": 440, "children": [492, 493], "start_point": {"row": 210, "column": 2}, "end_point": {"row": 210, "column": 18}}, {"id": 492, "type": "type_identifier", "text": "AtkImage", "parent": 491, "children": [], "start_point": {"row": 210, "column": 2}, "end_point": {"row": 210, "column": 10}}, {"id": 493, "type": "pointer_declarator", "text": "*image", "parent": 491, "children": [494, 495], "start_point": {"row": 210, "column": 11}, "end_point": {"row": 210, "column": 17}}, {"id": 494, "type": "*", "text": "*", "parent": 493, "children": [], "start_point": {"row": 210, "column": 11}, "end_point": {"row": 210, "column": 12}}, {"id": 495, "type": "identifier", "text": "image", "parent": 493, "children": [], "start_point": {"row": 210, "column": 12}, "end_point": {"row": 210, "column": 17}}, {"id": 496, "type": "assignment_expression", "text": "image = ATK_IMAGE (gtk_widget_get_accessible (button))", "parent": 440, "children": [497, 498, 499], "start_point": {"row": 212, "column": 2}, "end_point": {"row": 212, "column": 56}}, {"id": 497, "type": "identifier", "text": "image", "parent": 496, "children": [], "start_point": {"row": 212, "column": 2}, "end_point": {"row": 212, "column": 7}}, {"id": 498, "type": "=", "text": "=", "parent": 496, "children": [], "start_point": {"row": 212, "column": 8}, "end_point": {"row": 212, "column": 9}}, {"id": 499, "type": "call_expression", "text": "ATK_IMAGE (gtk_widget_get_accessible (button))", "parent": 496, "children": [500, 501], "start_point": {"row": 212, "column": 10}, "end_point": {"row": 212, "column": 56}}, {"id": 500, "type": "identifier", "text": "ATK_IMAGE", "parent": 499, "children": [], "start_point": {"row": 212, "column": 10}, "end_point": {"row": 212, "column": 19}}, {"id": 501, "type": "argument_list", "text": "(gtk_widget_get_accessible (button))", "parent": 499, "children": [502], "start_point": {"row": 212, "column": 20}, "end_point": {"row": 212, "column": 56}}, {"id": 502, "type": "call_expression", "text": "gtk_widget_get_accessible (button)", "parent": 501, "children": [503, 504], "start_point": {"row": 212, "column": 21}, "end_point": {"row": 212, "column": 55}}, {"id": 503, "type": "identifier", "text": "gtk_widget_get_accessible", "parent": 502, "children": [], "start_point": {"row": 212, "column": 21}, "end_point": {"row": 212, "column": 46}}, {"id": 504, "type": "argument_list", "text": "(button)", "parent": 502, "children": [505], "start_point": {"row": 212, "column": 47}, "end_point": {"row": 212, "column": 55}}, {"id": 505, "type": "identifier", "text": "button", "parent": 504, "children": [], "start_point": {"row": 212, "column": 48}, "end_point": {"row": 212, "column": 54}}, {"id": 506, "type": "assignment_expression", "text": "adjustment = gtk_scale_button_get_adjustment (scale_button)", "parent": 440, "children": [507, 508, 509], "start_point": {"row": 214, "column": 2}, "end_point": {"row": 214, "column": 61}}, {"id": 507, "type": "identifier", "text": "adjustment", "parent": 506, "children": [], "start_point": {"row": 214, "column": 2}, "end_point": {"row": 214, "column": 12}}, {"id": 508, "type": "=", "text": "=", "parent": 506, "children": [], "start_point": {"row": 214, "column": 13}, "end_point": {"row": 214, "column": 14}}, {"id": 509, "type": "call_expression", "text": "gtk_scale_button_get_adjustment (scale_button)", "parent": 506, "children": [510, 511], "start_point": {"row": 214, "column": 15}, "end_point": {"row": 214, "column": 61}}, {"id": 510, "type": "identifier", "text": "gtk_scale_button_get_adjustment", "parent": 509, "children": [], "start_point": {"row": 214, "column": 15}, "end_point": {"row": 214, "column": 46}}, {"id": 511, "type": "argument_list", "text": "(scale_button)", "parent": 509, "children": [512], "start_point": {"row": 214, "column": 47}, "end_point": {"row": 214, "column": 61}}, {"id": 512, "type": "identifier", "text": "scale_button", "parent": 511, "children": [], "start_point": {"row": 214, "column": 48}, "end_point": {"row": 214, "column": 60}}, {"id": 513, "type": "assignment_expression", "text": "val = gtk_scale_button_get_value (scale_button)", "parent": 440, "children": [514, 515, 516], "start_point": {"row": 215, "column": 2}, "end_point": {"row": 215, "column": 49}}, {"id": 514, "type": "identifier", "text": "val", "parent": 513, "children": [], "start_point": {"row": 215, "column": 2}, "end_point": {"row": 215, "column": 5}}, {"id": 515, "type": "=", "text": "=", "parent": 513, "children": [], "start_point": {"row": 215, "column": 6}, "end_point": {"row": 215, "column": 7}}, {"id": 516, "type": "call_expression", "text": "gtk_scale_button_get_value (scale_button)", "parent": 513, "children": [517, 518], "start_point": {"row": 215, "column": 8}, "end_point": {"row": 215, "column": 49}}, {"id": 517, "type": "identifier", "text": "gtk_scale_button_get_value", "parent": 516, "children": [], "start_point": {"row": 215, "column": 8}, "end_point": {"row": 215, "column": 34}}, {"id": 518, "type": "argument_list", "text": "(scale_button)", "parent": 516, "children": [519], "start_point": {"row": 215, "column": 35}, "end_point": {"row": 215, "column": 49}}, {"id": 519, "type": "identifier", "text": "scale_button", "parent": 518, "children": [], "start_point": {"row": 215, "column": 36}, "end_point": {"row": 215, "column": 48}}, {"id": 520, "type": "if_statement", "text": "if (val < (gtk_adjustment_get_lower (adjustment) + EPSILON))\n {\n str = g_strdup (_(\"Muted\"));\n }\n else if (val >= (gtk_adjustment_get_upper (adjustment) - EPSILON))\n {\n str = g_strdup (_(\"Full Volume\"));\n }\n else\n {\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. \"49 %\".\n * Translate the \"%d\" to \"%Id\" if you want to use localised digits,\n * or otherwise translate the \"%d\" to \"%d\".\n */\n str = g_strdup_printf (C_(\"volume percentage\", \"%d %%\"), percent);\n }", "parent": 440, "children": [521, 543], "start_point": {"row": 217, "column": 2}, "end_point": {"row": 237, "column": 5}}, {"id": 521, "type": "parenthesized_expression", "text": "(val < (gtk_adjustment_get_lower (adjustment) + EPSILON))", "parent": 520, "children": [522], "start_point": {"row": 217, "column": 5}, "end_point": {"row": 217, "column": 62}}, {"id": 522, "type": "binary_expression", "text": "val < (gtk_adjustment_get_lower (adjustment) + EPSILON)", "parent": 521, "children": [523, 524, 525], "start_point": {"row": 217, "column": 6}, "end_point": {"row": 217, "column": 61}}, {"id": 523, "type": "identifier", "text": "val", "parent": 522, "children": [], "start_point": {"row": 217, "column": 6}, "end_point": {"row": 217, "column": 9}}, {"id": 524, "type": "<", "text": "<", "parent": 522, "children": [], "start_point": {"row": 217, "column": 10}, "end_point": {"row": 217, "column": 11}}, {"id": 525, "type": "parenthesized_expression", "text": "(gtk_adjustment_get_lower (adjustment) + EPSILON)", "parent": 522, "children": [526], "start_point": {"row": 217, "column": 12}, "end_point": {"row": 217, "column": 61}}, {"id": 526, "type": "binary_expression", "text": "gtk_adjustment_get_lower (adjustment) + EPSILON", "parent": 525, "children": [527, 531, 532], "start_point": {"row": 217, "column": 13}, "end_point": {"row": 217, "column": 60}}, {"id": 527, "type": "call_expression", "text": "gtk_adjustment_get_lower (adjustment)", "parent": 526, "children": [528, 529], "start_point": {"row": 217, "column": 13}, "end_point": {"row": 217, "column": 50}}, {"id": 528, "type": "identifier", "text": "gtk_adjustment_get_lower", "parent": 527, "children": [], "start_point": {"row": 217, "column": 13}, "end_point": {"row": 217, "column": 37}}, {"id": 529, "type": "argument_list", "text": "(adjustment)", "parent": 527, "children": [530], "start_point": {"row": 217, "column": 38}, "end_point": {"row": 217, "column": 50}}, {"id": 530, "type": "identifier", "text": "adjustment", "parent": 529, "children": [], "start_point": {"row": 217, "column": 39}, "end_point": {"row": 217, "column": 49}}, {"id": 531, "type": "+", "text": "+", "parent": 526, "children": [], "start_point": {"row": 217, "column": 51}, "end_point": {"row": 217, "column": 52}}, {"id": 532, "type": "identifier", "text": "EPSILON", "parent": 526, "children": [], "start_point": {"row": 217, "column": 53}, "end_point": {"row": 217, "column": 60}}, {"id": 533, "type": "assignment_expression", "text": "str = g_strdup (_(\"Muted\"))", "parent": 520, "children": [534, 535, 536], "start_point": {"row": 219, "column": 6}, "end_point": {"row": 219, "column": 33}}, {"id": 534, "type": "identifier", "text": "str", "parent": 533, "children": [], "start_point": {"row": 219, "column": 6}, "end_point": {"row": 219, "column": 9}}, {"id": 535, "type": "=", "text": "=", "parent": 533, "children": [], "start_point": {"row": 219, "column": 10}, "end_point": {"row": 219, "column": 11}}, {"id": 536, "type": "call_expression", "text": "g_strdup (_(\"Muted\"))", "parent": 533, "children": [537, 538], "start_point": {"row": 219, "column": 12}, "end_point": {"row": 219, "column": 33}}, {"id": 537, "type": "identifier", "text": "g_strdup", "parent": 536, "children": [], "start_point": {"row": 219, "column": 12}, "end_point": {"row": 219, "column": 20}}, {"id": 538, "type": "argument_list", "text": "(_(\"Muted\"))", "parent": 536, "children": [539], "start_point": {"row": 219, "column": 21}, "end_point": {"row": 219, "column": 33}}, {"id": 539, "type": "call_expression", "text": "_(\"Muted\")", "parent": 538, "children": [540, 541], "start_point": {"row": 219, "column": 22}, "end_point": {"row": 219, "column": 32}}, {"id": 540, "type": "identifier", "text": "_", "parent": 539, "children": [], "start_point": {"row": 219, "column": 22}, "end_point": {"row": 219, "column": 23}}, {"id": 541, "type": "argument_list", "text": "(\"Muted\")", "parent": 539, "children": [542], "start_point": {"row": 219, "column": 23}, "end_point": {"row": 219, "column": 32}}, {"id": 542, "type": "string_literal", "text": "\"Muted\"", "parent": 541, "children": [], "start_point": {"row": 219, "column": 24}, "end_point": {"row": 219, "column": 31}}, {"id": 543, "type": "else_clause", "text": "else if (val >= (gtk_adjustment_get_upper (adjustment) - EPSILON))\n {\n str = g_strdup (_(\"Full Volume\"));\n }\n else\n {\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. \"49 %\".\n * Translate the \"%d\" to \"%Id\" if you want to use localised digits,\n * or otherwise translate the \"%d\" to \"%d\".\n */\n str = g_strdup_printf (C_(\"volume percentage\", \"%d %%\"), percent);\n }", "parent": 520, "children": [544], "start_point": {"row": 221, "column": 2}, "end_point": {"row": 237, "column": 5}}, {"id": 544, "type": "if_statement", "text": "if (val >= (gtk_adjustment_get_upper (adjustment) - EPSILON))\n {\n str = g_strdup (_(\"Full Volume\"));\n }\n else\n {\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. \"49 %\".\n * Translate the \"%d\" to \"%Id\" if you want to use localised digits,\n * or otherwise translate the \"%d\" to \"%d\".\n */\n str = g_strdup_printf (C_(\"volume percentage\", \"%d %%\"), percent);\n }", "parent": 543, "children": [545, 567], "start_point": {"row": 221, "column": 7}, "end_point": {"row": 237, "column": 5}}, {"id": 545, "type": "parenthesized_expression", "text": "(val >= (gtk_adjustment_get_upper (adjustment) - EPSILON))", "parent": 544, "children": [546], "start_point": {"row": 221, "column": 10}, "end_point": {"row": 221, "column": 68}}, {"id": 546, "type": "binary_expression", "text": "val >= (gtk_adjustment_get_upper (adjustment) - EPSILON)", "parent": 545, "children": [547, 548, 549], "start_point": {"row": 221, "column": 11}, "end_point": {"row": 221, "column": 67}}, {"id": 547, "type": "identifier", "text": "val", "parent": 546, "children": [], "start_point": {"row": 221, "column": 11}, "end_point": {"row": 221, "column": 14}}, {"id": 548, "type": ">=", "text": ">=", "parent": 546, "children": [], "start_point": {"row": 221, "column": 15}, "end_point": {"row": 221, "column": 17}}, {"id": 549, "type": "parenthesized_expression", "text": "(gtk_adjustment_get_upper (adjustment) - EPSILON)", "parent": 546, "children": [550], "start_point": {"row": 221, "column": 18}, "end_point": {"row": 221, "column": 67}}, {"id": 550, "type": "binary_expression", "text": "gtk_adjustment_get_upper (adjustment) - EPSILON", "parent": 549, "children": [551, 555, 556], "start_point": {"row": 221, "column": 19}, "end_point": {"row": 221, "column": 66}}, {"id": 551, "type": "call_expression", "text": "gtk_adjustment_get_upper (adjustment)", "parent": 550, "children": [552, 553], "start_point": {"row": 221, "column": 19}, "end_point": {"row": 221, "column": 56}}, {"id": 552, "type": "identifier", "text": "gtk_adjustment_get_upper", "parent": 551, "children": [], "start_point": {"row": 221, "column": 19}, "end_point": {"row": 221, "column": 43}}, {"id": 553, "type": "argument_list", "text": "(adjustment)", "parent": 551, "children": [554], "start_point": {"row": 221, "column": 44}, "end_point": {"row": 221, "column": 56}}, {"id": 554, "type": "identifier", "text": "adjustment", "parent": 553, "children": [], "start_point": {"row": 221, "column": 45}, "end_point": {"row": 221, "column": 55}}, {"id": 555, "type": "-", "text": "-", "parent": 550, "children": [], "start_point": {"row": 221, "column": 57}, "end_point": {"row": 221, "column": 58}}, {"id": 556, "type": "identifier", "text": "EPSILON", "parent": 550, "children": [], "start_point": {"row": 221, "column": 59}, "end_point": {"row": 221, "column": 66}}, {"id": 557, "type": "assignment_expression", "text": "str = g_strdup (_(\"Full Volume\"))", "parent": 544, "children": [558, 559, 560], "start_point": {"row": 223, "column": 6}, "end_point": {"row": 223, "column": 39}}, {"id": 558, "type": "identifier", "text": "str", "parent": 557, "children": [], "start_point": {"row": 223, "column": 6}, "end_point": {"row": 223, "column": 9}}, {"id": 559, "type": "=", "text": "=", "parent": 557, "children": [], "start_point": {"row": 223, "column": 10}, "end_point": {"row": 223, "column": 11}}, {"id": 560, "type": "call_expression", "text": "g_strdup (_(\"Full Volume\"))", "parent": 557, "children": [561, 562], "start_point": {"row": 223, "column": 12}, "end_point": {"row": 223, "column": 39}}, {"id": 561, "type": "identifier", "text": "g_strdup", "parent": 560, "children": [], "start_point": {"row": 223, "column": 12}, "end_point": {"row": 223, "column": 20}}, {"id": 562, "type": "argument_list", "text": "(_(\"Full Volume\"))", "parent": 560, "children": [563], "start_point": {"row": 223, "column": 21}, "end_point": {"row": 223, "column": 39}}, {"id": 563, "type": "call_expression", "text": "_(\"Full Volume\")", "parent": 562, "children": [564, 565], "start_point": {"row": 223, "column": 22}, "end_point": {"row": 223, "column": 38}}, {"id": 564, "type": "identifier", "text": "_", "parent": 563, "children": [], "start_point": {"row": 223, "column": 22}, "end_point": {"row": 223, "column": 23}}, {"id": 565, "type": "argument_list", "text": "(\"Full Volume\")", "parent": 563, "children": [566], "start_point": {"row": 223, "column": 23}, "end_point": {"row": 223, "column": 38}}, {"id": 566, "type": "string_literal", "text": "\"Full Volume\"", "parent": 565, "children": [], "start_point": {"row": 223, "column": 24}, "end_point": {"row": 223, "column": 37}}, {"id": 567, "type": "else_clause", "text": "else\n {\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. \"49 %\".\n * Translate the \"%d\" to \"%Id\" if you want to use localised digits,\n * or otherwise translate the \"%d\" to \"%d\".\n */\n str = g_strdup_printf (C_(\"volume percentage\", \"%d %%\"), percent);\n }", "parent": 544, "children": [], "start_point": {"row": 225, "column": 2}, "end_point": {"row": 237, "column": 5}}, {"id": 568, "type": "declaration", "text": "int percent;", "parent": 567, "children": [569, 570], "start_point": {"row": 227, "column": 6}, "end_point": {"row": 227, "column": 18}}, {"id": 569, "type": "primitive_type", "text": "int", "parent": 568, "children": [], "start_point": {"row": 227, "column": 6}, "end_point": {"row": 227, "column": 9}}, {"id": 570, "type": "identifier", "text": "percent", "parent": 568, "children": [], "start_point": {"row": 227, "column": 10}, "end_point": {"row": 227, "column": 17}}, {"id": 571, "type": "assignment_expression", "text": "percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5)", "parent": 567, "children": [572, 573, 574], "start_point": {"row": 229, "column": 6}, "end_point": {"row": 229, "column": 121}}, {"id": 572, "type": "identifier", "text": "percent", "parent": 571, "children": [], "start_point": {"row": 229, "column": 6}, "end_point": {"row": 229, "column": 13}}, {"id": 573, "type": "=", "text": "=", "parent": 571, "children": [], "start_point": {"row": 229, "column": 14}, "end_point": {"row": 229, "column": 15}}, {"id": 574, "type": "cast_expression", "text": "(int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5)", "parent": 571, "children": [575, 577], "start_point": {"row": 229, "column": 16}, "end_point": {"row": 229, "column": 121}}, {"id": 575, "type": "type_descriptor", "text": "int", "parent": 574, "children": [576], "start_point": {"row": 229, "column": 17}, "end_point": {"row": 229, "column": 20}}, {"id": 576, "type": "primitive_type", "text": "int", "parent": 575, "children": [], "start_point": {"row": 229, "column": 17}, "end_point": {"row": 229, "column": 20}}, {"id": 577, "type": "parenthesized_expression", "text": "(100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5)", "parent": 574, "children": [578], "start_point": {"row": 229, "column": 22}, "end_point": {"row": 229, "column": 121}}, {"id": 578, "type": "binary_expression", "text": "100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5", "parent": 577, "children": [579, 596, 597], "start_point": {"row": 229, "column": 23}, "end_point": {"row": 229, "column": 120}}, {"id": 579, "type": "binary_expression", "text": "100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment))", "parent": 578, "children": [580, 584, 585], "start_point": {"row": 229, "column": 23}, "end_point": {"row": 229, "column": 115}}, {"id": 580, "type": "binary_expression", "text": "100. * val", "parent": 579, "children": [581, 582, 583], "start_point": {"row": 229, "column": 23}, "end_point": {"row": 229, "column": 33}}, {"id": 581, "type": "number_literal", "text": "100.", "parent": 580, "children": [], "start_point": {"row": 229, "column": 23}, "end_point": {"row": 229, "column": 27}}, {"id": 582, "type": "*", "text": "*", "parent": 580, "children": [], "start_point": {"row": 229, "column": 28}, "end_point": {"row": 229, "column": 29}}, {"id": 583, "type": "identifier", "text": "val", "parent": 580, "children": [], "start_point": {"row": 229, "column": 30}, "end_point": {"row": 229, "column": 33}}, {"id": 584, "type": "/", "text": "/", "parent": 579, "children": [], "start_point": {"row": 229, "column": 34}, "end_point": {"row": 229, "column": 35}}, {"id": 585, "type": "parenthesized_expression", "text": "(gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment))", "parent": 579, "children": [586], "start_point": {"row": 229, "column": 36}, "end_point": {"row": 229, "column": 115}}, {"id": 586, "type": "binary_expression", "text": "gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)", "parent": 585, "children": [587, 591, 592], "start_point": {"row": 229, "column": 37}, "end_point": {"row": 229, "column": 114}}, {"id": 587, "type": "call_expression", "text": "gtk_adjustment_get_upper (adjustment)", "parent": 586, "children": [588, 589], "start_point": {"row": 229, "column": 37}, "end_point": {"row": 229, "column": 74}}, {"id": 588, "type": "identifier", "text": "gtk_adjustment_get_upper", "parent": 587, "children": [], "start_point": {"row": 229, "column": 37}, "end_point": {"row": 229, "column": 61}}, {"id": 589, "type": "argument_list", "text": "(adjustment)", "parent": 587, "children": [590], "start_point": {"row": 229, "column": 62}, "end_point": {"row": 229, "column": 74}}, {"id": 590, "type": "identifier", "text": "adjustment", "parent": 589, "children": [], "start_point": {"row": 229, "column": 63}, "end_point": {"row": 229, "column": 73}}, {"id": 591, "type": "-", "text": "-", "parent": 586, "children": [], "start_point": {"row": 229, "column": 75}, "end_point": {"row": 229, "column": 76}}, {"id": 592, "type": "call_expression", "text": "gtk_adjustment_get_lower (adjustment)", "parent": 586, "children": [593, 594], "start_point": {"row": 229, "column": 77}, "end_point": {"row": 229, "column": 114}}, {"id": 593, "type": "identifier", "text": "gtk_adjustment_get_lower", "parent": 592, "children": [], "start_point": {"row": 229, "column": 77}, "end_point": {"row": 229, "column": 101}}, {"id": 594, "type": "argument_list", "text": "(adjustment)", "parent": 592, "children": [595], "start_point": {"row": 229, "column": 102}, "end_point": {"row": 229, "column": 114}}, {"id": 595, "type": "identifier", "text": "adjustment", "parent": 594, "children": [], "start_point": {"row": 229, "column": 103}, "end_point": {"row": 229, "column": 113}}, {"id": 596, "type": "+", "text": "+", "parent": 578, "children": [], "start_point": {"row": 229, "column": 116}, "end_point": {"row": 229, "column": 117}}, {"id": 597, "type": "number_literal", "text": ".5", "parent": 578, "children": [], "start_point": {"row": 229, "column": 118}, "end_point": {"row": 229, "column": 120}}, {"id": 598, "type": "assignment_expression", "text": "str = g_strdup_printf (C_(\"volume percentage\", \"%d %%\"), percent)", "parent": 567, "children": [599, 600, 601], "start_point": {"row": 236, "column": 6}, "end_point": {"row": 236, "column": 71}}, {"id": 599, "type": "identifier", "text": "str", "parent": 598, "children": [], "start_point": {"row": 236, "column": 6}, "end_point": {"row": 236, "column": 9}}, {"id": 600, "type": "=", "text": "=", "parent": 598, "children": [], "start_point": {"row": 236, "column": 10}, "end_point": {"row": 236, "column": 11}}, {"id": 601, "type": "call_expression", "text": "g_strdup_printf (C_(\"volume percentage\", \"%d %%\"), percent)", "parent": 598, "children": [602, 603], "start_point": {"row": 236, "column": 12}, "end_point": {"row": 236, "column": 71}}, {"id": 602, "type": "identifier", "text": "g_strdup_printf", "parent": 601, "children": [], "start_point": {"row": 236, "column": 12}, "end_point": {"row": 236, "column": 27}}, {"id": 603, "type": "argument_list", "text": "(C_(\"volume percentage\", \"%d %%\"), percent)", "parent": 601, "children": [604, 609], "start_point": {"row": 236, "column": 28}, "end_point": {"row": 236, "column": 71}}, {"id": 604, "type": "call_expression", "text": "C_(\"volume percentage\", \"%d %%\")", "parent": 603, "children": [605, 606], "start_point": {"row": 236, "column": 29}, "end_point": {"row": 236, "column": 61}}, {"id": 605, "type": "identifier", "text": "C_", "parent": 604, "children": [], "start_point": {"row": 236, "column": 29}, "end_point": {"row": 236, "column": 31}}, {"id": 606, "type": "argument_list", "text": "(\"volume percentage\", \"%d %%\")", "parent": 604, "children": [607, 608], "start_point": {"row": 236, "column": 31}, "end_point": {"row": 236, "column": 61}}, {"id": 607, "type": "string_literal", "text": "\"volume percentage\"", "parent": 606, "children": [], "start_point": {"row": 236, "column": 32}, "end_point": {"row": 236, "column": 51}}, {"id": 608, "type": "string_literal", "text": "\"%d %%\"", "parent": 606, "children": [], "start_point": {"row": 236, "column": 53}, "end_point": {"row": 236, "column": 60}}, {"id": 609, "type": "identifier", "text": "percent", "parent": 603, "children": [], "start_point": {"row": 236, "column": 63}, "end_point": {"row": 236, "column": 70}}, {"id": 610, "type": "call_expression", "text": "gtk_tooltip_set_text (tooltip, str)", "parent": 440, "children": [611, 612], "start_point": {"row": 239, "column": 2}, "end_point": {"row": 239, "column": 37}}, {"id": 611, "type": "identifier", "text": "gtk_tooltip_set_text", "parent": 610, "children": [], "start_point": {"row": 239, "column": 2}, "end_point": {"row": 239, "column": 22}}, {"id": 612, "type": "argument_list", "text": "(tooltip, str)", "parent": 610, "children": [613, 614], "start_point": {"row": 239, "column": 23}, "end_point": {"row": 239, "column": 37}}, {"id": 613, "type": "identifier", "text": "tooltip", "parent": 612, "children": [], "start_point": {"row": 239, "column": 24}, "end_point": {"row": 239, "column": 31}}, {"id": 614, "type": "identifier", "text": "str", "parent": 612, "children": [], "start_point": {"row": 239, "column": 33}, "end_point": {"row": 239, "column": 36}}, {"id": 615, "type": "call_expression", "text": "atk_image_set_image_description (image, str)", "parent": 440, "children": [616, 617], "start_point": {"row": 240, "column": 2}, "end_point": {"row": 240, "column": 46}}, {"id": 616, "type": "identifier", "text": "atk_image_set_image_description", "parent": 615, "children": [], "start_point": {"row": 240, "column": 2}, "end_point": {"row": 240, "column": 33}}, {"id": 617, "type": "argument_list", "text": "(image, str)", "parent": 615, "children": [618, 619], "start_point": {"row": 240, "column": 34}, "end_point": {"row": 240, "column": 46}}, {"id": 618, "type": "identifier", "text": "image", "parent": 617, "children": [], "start_point": {"row": 240, "column": 35}, "end_point": {"row": 240, "column": 40}}, {"id": 619, "type": "identifier", "text": "str", "parent": 617, "children": [], "start_point": {"row": 240, "column": 42}, "end_point": {"row": 240, "column": 45}}, {"id": 620, "type": "call_expression", "text": "g_free (str)", "parent": 440, "children": [621, 622], "start_point": {"row": 241, "column": 2}, "end_point": {"row": 241, "column": 14}}, {"id": 621, "type": "identifier", "text": "g_free", "parent": 620, "children": [], "start_point": {"row": 241, "column": 2}, "end_point": {"row": 241, "column": 8}}, {"id": 622, "type": "argument_list", "text": "(str)", "parent": 620, "children": [623], "start_point": {"row": 241, "column": 9}, "end_point": {"row": 241, "column": 14}}, {"id": 623, "type": "identifier", "text": "str", "parent": 622, "children": [], "start_point": {"row": 241, "column": 10}, "end_point": {"row": 241, "column": 13}}, {"id": 624, "type": "return_statement", "text": "return TRUE;", "parent": 440, "children": [625], "start_point": {"row": 243, "column": 2}, "end_point": {"row": 243, "column": 14}}, {"id": 625, "type": "true", "text": "TRUE", "parent": 624, "children": [], "start_point": {"row": 243, "column": 9}, "end_point": {"row": 243, "column": 13}}, {"id": 626, "type": "function_definition", "text": "static void\ncb_value_changed (GtkVolumeButton *button, gdouble value, gpointer user_data)\n{\n gtk_widget_trigger_tooltip_query (GTK_WIDGET (button));\n}", "parent": null, "children": [627, 628], "start_point": {"row": 246, "column": 0}, "end_point": {"row": 250, "column": 1}}, {"id": 627, "type": "primitive_type", "text": "void", "parent": 626, "children": [], "start_point": {"row": 246, "column": 7}, "end_point": {"row": 246, "column": 11}}, {"id": 628, "type": "function_declarator", "text": "cb_value_changed (GtkVolumeButton *button, gdouble value, gpointer user_data)", "parent": 626, "children": [629, 630], "start_point": {"row": 247, "column": 0}, "end_point": {"row": 247, "column": 77}}, {"id": 629, "type": "identifier", "text": "cb_value_changed", "parent": 628, "children": [], "start_point": {"row": 247, "column": 0}, "end_point": {"row": 247, "column": 16}}, {"id": 630, "type": "parameter_list", "text": "(GtkVolumeButton *button, gdouble value, gpointer user_data)", "parent": 628, "children": [631, 636, 639], "start_point": {"row": 247, "column": 17}, "end_point": {"row": 247, "column": 77}}, {"id": 631, "type": "parameter_declaration", "text": "GtkVolumeButton *button", "parent": 630, "children": [632, 633], "start_point": {"row": 247, "column": 18}, "end_point": {"row": 247, "column": 41}}, {"id": 632, "type": "type_identifier", "text": "GtkVolumeButton", "parent": 631, "children": [], "start_point": {"row": 247, "column": 18}, "end_point": {"row": 247, "column": 33}}, {"id": 633, "type": "pointer_declarator", "text": "*button", "parent": 631, "children": [634, 635], "start_point": {"row": 247, "column": 34}, "end_point": {"row": 247, "column": 41}}, {"id": 634, "type": "*", "text": "*", "parent": 633, "children": [], "start_point": {"row": 247, "column": 34}, "end_point": {"row": 247, "column": 35}}, {"id": 635, "type": "identifier", "text": "button", "parent": 633, "children": [], "start_point": {"row": 247, "column": 35}, "end_point": {"row": 247, "column": 41}}, {"id": 636, "type": "parameter_declaration", "text": "gdouble value", "parent": 630, "children": [637, 638], "start_point": {"row": 247, "column": 43}, "end_point": {"row": 247, "column": 56}}, {"id": 637, "type": "type_identifier", "text": "gdouble", "parent": 636, "children": [], "start_point": {"row": 247, "column": 43}, "end_point": {"row": 247, "column": 50}}, {"id": 638, "type": "identifier", "text": "value", "parent": 636, "children": [], "start_point": {"row": 247, "column": 51}, "end_point": {"row": 247, "column": 56}}, {"id": 639, "type": "parameter_declaration", "text": "gpointer user_data", "parent": 630, "children": [640, 641], "start_point": {"row": 247, "column": 58}, "end_point": {"row": 247, "column": 76}}, {"id": 640, "type": "type_identifier", "text": "gpointer", "parent": 639, "children": [], "start_point": {"row": 247, "column": 58}, "end_point": {"row": 247, "column": 66}}, {"id": 641, "type": "identifier", "text": "user_data", "parent": 639, "children": [], "start_point": {"row": 247, "column": 67}, "end_point": {"row": 247, "column": 76}}, {"id": 642, "type": "call_expression", "text": "gtk_widget_trigger_tooltip_query (GTK_WIDGET (button))", "parent": 626, "children": [643, 644], "start_point": {"row": 249, "column": 2}, "end_point": {"row": 249, "column": 56}}, {"id": 643, "type": "identifier", "text": "gtk_widget_trigger_tooltip_query", "parent": 642, "children": [], "start_point": {"row": 249, "column": 2}, "end_point": {"row": 249, "column": 34}}, {"id": 644, "type": "argument_list", "text": "(GTK_WIDGET (button))", "parent": 642, "children": [645], "start_point": {"row": 249, "column": 35}, "end_point": {"row": 249, "column": 56}}, {"id": 645, "type": "call_expression", "text": "GTK_WIDGET (button)", "parent": 644, "children": [646, 647], "start_point": {"row": 249, "column": 36}, "end_point": {"row": 249, "column": 55}}, {"id": 646, "type": "identifier", "text": "GTK_WIDGET", "parent": 645, "children": [], "start_point": {"row": 249, "column": 36}, "end_point": {"row": 249, "column": 46}}, {"id": 647, "type": "argument_list", "text": "(button)", "parent": 645, "children": [648], "start_point": {"row": 249, "column": 47}, "end_point": {"row": 249, "column": 55}}, {"id": 648, "type": "identifier", "text": "button", "parent": 647, "children": [], "start_point": {"row": 249, "column": 48}, "end_point": {"row": 249, "column": 54}}]}, "node_categories": {"declarations": {"functions": [58, 85, 105, 107, 189, 191, 289, 291, 369, 371, 412, 416, 440, 442, 626, 628], "variables": [19, 34, 56, 61, 66, 69, 72, 75, 80, 83, 88, 93, 96, 110, 115, 118, 123, 128, 194, 199, 202, 207, 219, 294, 299, 310, 374, 379, 419, 421, 445, 450, 453, 456, 459, 464, 467, 478, 483, 486, 491, 568, 631, 636, 639], "classes": [], "imports": [0, 1, 3, 4, 6, 7, 9, 10, 12, 13], "modules": [], "enums": [49, 50, 51, 52, 54]}, "statements": {"expressions": [99, 135, 141, 147, 148, 152, 156, 165, 169, 181, 214, 226, 231, 236, 237, 238, 239, 245, 246, 253, 256, 259, 262, 268, 273, 281, 306, 317, 322, 328, 333, 338, 342, 346, 351, 354, 359, 364, 386, 390, 394, 397, 400, 403, 408, 429, 436, 474, 499, 502, 509, 516, 521, 522, 525, 526, 527, 536, 539, 545, 546, 549, 550, 551, 560, 563, 574, 577, 578, 579, 580, 585, 586, 587, 592, 601, 604, 610, 615, 620, 642, 645], "assignments": [321, 327, 426, 496, 506, 513, 533, 557, 571, 598], "loops": [], "conditionals": [17, 20, 25, 35, 40, 53, 55, 57, 59, 62, 65, 67, 68, 70, 71, 73, 74, 76, 79, 81, 82, 86, 89, 92, 94, 95, 97, 98, 100, 102, 103, 104, 108, 111, 114, 116, 117, 119, 122, 124, 127, 129, 133, 136, 138, 139, 140, 142, 143, 144, 145, 146, 149, 151, 153, 155, 163, 166, 168, 176, 179, 182, 184, 185, 186, 192, 195, 198, 200, 201, 203, 206, 208, 211, 212, 213, 215, 216, 217, 218, 225, 227, 229, 232, 235, 240, 247, 254, 257, 260, 263, 265, 269, 271, 274, 276, 279, 282, 284, 285, 286, 292, 295, 298, 300, 304, 307, 309, 311, 315, 318, 320, 323, 324, 326, 329, 330, 332, 334, 336, 337, 339, 343, 347, 352, 353, 355, 357, 360, 362, 363, 365, 367, 368, 372, 375, 378, 380, 384, 387, 389, 391, 393, 395, 398, 401, 404, 406, 409, 413, 417, 422, 425, 427, 430, 432, 437, 439, 441, 443, 446, 449, 451, 452, 454, 455, 457, 458, 460, 463, 465, 466, 468, 472, 475, 477, 479, 482, 484, 485, 490, 492, 495, 497, 500, 503, 505, 507, 510, 512, 514, 517, 519, 520, 523, 528, 530, 532, 534, 537, 540, 544, 547, 552, 554, 556, 558, 561, 564, 570, 572, 583, 588, 590, 593, 595, 599, 602, 605, 609, 611, 613, 614, 616, 618, 619, 621, 623, 629, 632, 635, 637, 638, 640, 641, 643, 646, 648], "returns": [435, 624], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 8, 11, 14, 28, 29, 30, 31, 43, 44, 45, 46, 230, 248, 258, 261, 341, 345, 349, 358, 407, 411, 542, 566, 581, 597, 607, 608], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 58, "universal_type": "function", "name": "unknown", "text_snippet": "cb_query_tooltip (GtkWidget *button,\n gint x,\n "}, {"node_id": 85, "universal_type": "function", "name": "unknown", "text_snippet": "cb_value_changed (GtkVolumeButton *button,\n gdouble value,"}, {"node_id": 105, "universal_type": "function", "name": "gtk_volume_button_set_property", "text_snippet": "static void\ngtk_volume_button_set_property (GObject *object,\n\t\t\t\tguint prop_id,\n\t\t\t\tc"}, {"node_id": 107, "universal_type": "function", "name": "unknown", "text_snippet": "gtk_volume_button_set_property (GObject *object,\n\t\t\t\tguint prop_id,\n\t\t\t\tconst GValue "}, {"node_id": 189, "universal_type": "function", "name": "gtk_volume_button_get_property", "text_snippet": "static void\ngtk_volume_button_get_property (GObject *object,\n\t\t\t guint prop_id,\n\t\t"}, {"node_id": 191, "universal_type": "function", "name": "unknown", "text_snippet": "gtk_volume_button_get_property (GObject *object,\n\t\t\t guint prop_id,\n\t\t\t GVa"}, {"node_id": 289, "universal_type": "function", "name": "gtk_volume_button_class_init", "text_snippet": "static void\ngtk_volume_button_class_init (GtkVolumeButtonClass *klass)\n{\n GObjectClass *gobject_cla"}, {"node_id": 291, "universal_type": "function", "name": "unknown", "text_snippet": "gtk_volume_button_class_init (GtkVolumeButtonClass *klass)"}, {"node_id": 369, "universal_type": "function", "name": "gtk_volume_button_init", "text_snippet": "static void\ngtk_volume_button_init (GtkVolumeButton *button)\n{\n GtkWidget *widget = GTK_WIDGET (but"}, {"node_id": 371, "universal_type": "function", "name": "unknown", "text_snippet": "gtk_volume_button_init (GtkVolumeButton *button)"}, {"node_id": 412, "universal_type": "function", "name": "unknown", "text_snippet": "GtkWidget *\ngtk_volume_button_new (void)\n{\n GObject *button;\n button = g_object_new (GTK_TYPE_VOLU"}, {"node_id": 416, "universal_type": "function", "name": "unknown", "text_snippet": "gtk_volume_button_new (void)"}, {"node_id": 440, "universal_type": "function", "name": "percent;", "text_snippet": "static gboolean\ncb_query_tooltip (GtkWidget *button,\n\t\t gint x,\n\t\t gint y,\n\t\t gboo"}, {"node_id": 442, "universal_type": "function", "name": "unknown", "text_snippet": "cb_query_tooltip (GtkWidget *button,\n\t\t gint x,\n\t\t gint y,\n\t\t gboolean keyboard"}, {"node_id": 626, "universal_type": "function", "name": "cb_value_changed", "text_snippet": "static void\ncb_value_changed (GtkVolumeButton *button, gdouble value, gpointer user_data)\n{\n gtk_wi"}, {"node_id": 628, "universal_type": "function", "name": "unknown", "text_snippet": "cb_value_changed (GtkVolumeButton *button, gdouble value, gpointer user_data)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include \"config.h\"\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include \"gtkvolumebutton.h\"\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include \"gtkadjustment.h\"\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include \"gtkintl.h\"\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include \"gtktooltip.h\"\n"}, {"node_id": 13, "text": "#include"}]}, "original_source_code": "/* GTK - The GIMP Toolkit\n * Copyright (C) 2007 Red Hat, Inc.\n *\n * Authors:\n * - <NAME> <<EMAIL>>\n *\n * This library is free software; you can redistribute it and/or\n * modify it under the terms of the GNU Lesser General Public\n * License as published by the Free Software Foundation; either\n * version 2 of the License, or (at your option) any later version.\n *\n * This library is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n * Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public\n * License along with this library. If not, see <http://www.gnu.org/licenses/>.\n */\n\n/*\n * Modified by the GTK+ Team and others 2007. See the AUTHORS\n * file for a list of people on the GTK+ Team. See the ChangeLog\n * files for a list of changes. These files are distributed with\n * GTK+ at ftp://ftp.gtk.org/pub/gtk/.\n */\n\n#include \"config.h\"\n\n#include \"gtkvolumebutton.h\"\n\n#include \"gtkadjustment.h\"\n#include \"gtkintl.h\"\n#include \"gtktooltip.h\"\n\n\n/**\n * SECTION:gtkvolumebutton\n * @Short_description: A button which pops up a volume control\n * @Title: GtkVolumeButton\n *\n * #GtkVolumeButton is a subclass of #GtkScaleButton that has\n * been tailored for use as a volume control widget with suitable\n * icons, tooltips and accessible labels.\n */\n\n#define EPSILON (1e-10)\n\nstatic const gchar * const icons[] =\n{\n \"audio-volume-muted\",\n \"audio-volume-high\",\n \"audio-volume-low\",\n \"audio-volume-medium\",\n NULL\n};\n\nstatic const gchar * const icons_symbolic[] =\n{\n \"audio-volume-muted-symbolic\",\n \"audio-volume-high-symbolic\",\n \"audio-volume-low-symbolic\",\n \"audio-volume-medium-symbolic\",\n NULL\n};\n\nenum\n{\n PROP_0,\n PROP_SYMBOLIC\n};\n\nstatic gboolean\tcb_query_tooltip (GtkWidget *button,\n gint x,\n gint y,\n gboolean keyboard_mode,\n GtkTooltip *tooltip,\n gpointer user_data);\nstatic void\tcb_value_changed (GtkVolumeButton *button,\n gdouble value,\n gpointer user_data);\n\nG_DEFINE_TYPE (GtkVolumeButton, gtk_volume_button, GTK_TYPE_SCALE_BUTTON)\n\nstatic void\ngtk_volume_button_set_property (GObject *object,\n\t\t\t\tguint prop_id,\n\t\t\t\tconst GValue *value,\n\t\t\t\tGParamSpec *pspec)\n{\n GtkScaleButton *button = GTK_SCALE_BUTTON (object);\n\n switch (prop_id)\n {\n case PROP_SYMBOLIC:\n if (g_value_get_boolean (value))\n gtk_scale_button_set_icons (button, (const char **) icons_symbolic);\n else\n\tgtk_scale_button_set_icons (button, (const char **) icons);\n break;\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }\n}\n\nstatic void\ngtk_volume_button_get_property (GObject *object,\n\t\t\t guint prop_id,\n\t\t\t GValue *value,\n\t\t\t GParamSpec *pspec)\n{\n switch (prop_id)\n {\n case PROP_SYMBOLIC: {\n char **icon_list;\n\n g_object_get (object, \"icons\", &icon_list, NULL);\n if (icon_list != NULL &&\n\t icon_list[0] != NULL &&\n \t g_str_equal (icon_list[0], icons_symbolic[0]))\n g_value_set_boolean (value, TRUE);\n else\n g_value_set_boolean (value, FALSE);\n g_strfreev (icon_list);\n break;\n }\n default:\n G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);\n break;\n }\n}\n\nstatic void\ngtk_volume_button_class_init (GtkVolumeButtonClass *klass)\n{\n GObjectClass *gobject_class = G_OBJECT_CLASS (klass);\n GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);\n\n gobject_class->set_property = gtk_volume_button_set_property;\n gobject_class->get_property = gtk_volume_button_get_property;\n\n /**\n * GtkVolumeButton:use-symbolic:\n *\n * Whether to use symbolic icons as the icons. Note that\n * if the symbolic icons are not available in your installed\n * theme, then the normal (potentially colorful) icons will\n * be used.\n *\n * Since: 3.0\n */\n g_object_class_install_property (gobject_class,\n PROP_SYMBOLIC,\n g_param_spec_boolean (\"use-symbolic\",\n P_(\"Use symbolic icons\"),\n P_(\"Whether to use symbolic icons\"),\n TRUE,\n G_PARAM_READWRITE|G_PARAM_CONSTRUCT));\n\n /* Bind class to template\n */\n gtk_widget_class_set_template_from_resource (widget_class, \"/org/gtk/libgtk/ui/gtkvolumebutton.ui\");\n gtk_widget_class_bind_template_callback (widget_class, cb_query_tooltip);\n gtk_widget_class_bind_template_callback (widget_class, cb_value_changed);\n}\n\nstatic void\ngtk_volume_button_init (GtkVolumeButton *button)\n{\n GtkWidget *widget = GTK_WIDGET (button);\n\n gtk_widget_init_template (widget);\n\n /* The atk action description is not supported by GtkBuilder */\n atk_action_set_description (ATK_ACTION (gtk_widget_get_accessible (GTK_WIDGET (widget))),\n\t\t\t 1, _(\"Adjusts the volume\"));\n}\n\n/**\n * gtk_volume_button_new:\n *\n * Creates a #GtkVolumeButton, with a range between 0.0 and 1.0, with\n * a stepping of 0.02. Volume values can be obtained and modified using\n * the functions from #GtkScaleButton.\n *\n * Returns: a new #GtkVolumeButton\n *\n * Since: 2.12\n */\nGtkWidget *\ngtk_volume_button_new (void)\n{\n GObject *button;\n button = g_object_new (GTK_TYPE_VOLUME_BUTTON, NULL);\n return GTK_WIDGET (button);\n}\n\nstatic gboolean\ncb_query_tooltip (GtkWidget *button,\n\t\t gint x,\n\t\t gint y,\n\t\t gboolean keyboard_mode,\n\t\t GtkTooltip *tooltip,\n\t\t gpointer user_data)\n{\n GtkScaleButton *scale_button = GTK_SCALE_BUTTON (button);\n GtkAdjustment *adjustment;\n gdouble val;\n char *str;\n AtkImage *image;\n\n image = ATK_IMAGE (gtk_widget_get_accessible (button));\n\n adjustment = gtk_scale_button_get_adjustment (scale_button);\n val = gtk_scale_button_get_value (scale_button);\n\n if (val < (gtk_adjustment_get_lower (adjustment) + EPSILON))\n {\n str = g_strdup (_(\"Muted\"));\n }\n else if (val >= (gtk_adjustment_get_upper (adjustment) - EPSILON))\n {\n str = g_strdup (_(\"Full Volume\"));\n }\n else\n {\n int percent;\n\n percent = (int) (100. * val / (gtk_adjustment_get_upper (adjustment) - gtk_adjustment_get_lower (adjustment)) + .5);\n\n /* Translators: this is the percentage of the current volume,\n * as used in the tooltip, eg. \"49 %\".\n * Translate the \"%d\" to \"%Id\" if you want to use localised digits,\n * or otherwise translate the \"%d\" to \"%d\".\n */\n str = g_strdup_printf (C_(\"volume percentage\", \"%d %%\"), percent);\n }\n\n gtk_tooltip_set_text (tooltip, str);\n atk_image_set_image_description (image, str);\n g_free (str);\n\n return TRUE;\n}\n\nstatic void\ncb_value_changed (GtkVolumeButton *button, gdouble value, gpointer user_data)\n{\n gtk_widget_trigger_tooltip_query (GTK_WIDGET (button));\n}\n"}
80,510
c
#ifndef COLOR_INCLUDED #define COLOR_INCLUDED #include "miru/basic/definitions.h" #include "miru/engine/vector.h" class Color { public: Color(); // Color(uint32_t r, uint32_t g, uint32_t b, uint32_t a); Color(float r, float g, float b, float a); Color clone() { return Color(this->r, this->g, this->b, this->a); } Vector3f toRGB() { return Vector3f(this->r, this->g, this->b); } void SetRGB(Vector3f rgb) { this->r = rgb.x; this->g = rgb.y; this->b = rgb.z; } int ru() const; int gu() const; int bu() const; int au() const; private: float r,g,b,a; }; #endif
19.81
32
(translation_unit) "#ifndef COLOR_INCLUDED\n#define COLOR_INCLUDED\n\n#include "miru/basic/definitions.h"\n#include "miru/engine/vector.h"\n\nclass Color\n{\npublic:\n Color();\n // Color(uint32_t r, uint32_t g, uint32_t b, uint32_t a);\n Color(float r, float g, float b, float a);\n\n Color clone()\n {\n return Color(this->r, this->g, this->b, this->a);\n }\n\n Vector3f toRGB()\n {\n return Vector3f(this->r, this->g, this->b);\n }\n\n void SetRGB(Vector3f rgb)\n {\n this->r = rgb.x;\n this->g = rgb.y;\n this->b = rgb.z;\n }\n\n int ru() const;\n int gu() const;\n int bu() const;\n int au() const;\nprivate:\n float r,g,b,a;\n};\n\n#endif" (preproc_ifdef) "#ifndef COLOR_INCLUDED\n#define COLOR_INCLUDED\n\n#include "miru/basic/definitions.h"\n#include "miru/engine/vector.h"\n\nclass Color\n{\npublic:\n Color();\n // Color(uint32_t r, uint32_t g, uint32_t b, uint32_t a);\n Color(float r, float g, float b, float a);\n\n Color clone()\n {\n return Color(this->r, this->g, this->b, this->a);\n }\n\n Vector3f toRGB()\n {\n return Vector3f(this->r, this->g, this->b);\n }\n\n void SetRGB(Vector3f rgb)\n {\n this->r = rgb.x;\n this->g = rgb.y;\n this->b = rgb.z;\n }\n\n int ru() const;\n int gu() const;\n int bu() const;\n int au() const;\nprivate:\n float r,g,b,a;\n};\n\n#endif" (#ifndef) "#ifndef" (identifier) "COLOR_INCLUDED" (preproc_def) "#define COLOR_INCLUDED\n" (#define) "#define" (identifier) "COLOR_INCLUDED" (preproc_include) "#include "miru/basic/definitions.h"\n" (#include) "#include" (string_literal) ""miru/basic/definitions.h"" (") """ (string_content) "miru/basic/definitions.h" (") """ (preproc_include) "#include "miru/engine/vector.h"\n" (#include) "#include" (string_literal) ""miru/engine/vector.h"" (") """ (string_content) "miru/engine/vector.h" (") """ (function_definition) "class Color\n{\npublic:\n Color();\n // Color(uint32_t r, uint32_t g, uint32_t b, uint32_t a);\n Color(float r, float g, float b, float a);\n\n Color clone()\n {\n return Color(this->r, this->g, this->b, this->a);\n }\n\n Vector3f toRGB()\n {\n return Vector3f(this->r, this->g, this->b);\n }\n\n void SetRGB(Vector3f rgb)\n {\n this->r = rgb.x;\n this->g = rgb.y;\n this->b = rgb.z;\n }\n\n int ru() const;\n int gu() const;\n int bu() const;\n int au() const;\nprivate:\n float r,g,b,a;\n}" (type_identifier) "class" (identifier) "Color" (compound_statement) "{\npublic:\n Color();\n // Color(uint32_t r, uint32_t g, uint32_t b, uint32_t a);\n Color(float r, float g, float b, float a);\n\n Color clone()\n {\n return Color(this->r, this->g, this->b, this->a);\n }\n\n Vector3f toRGB()\n {\n return Vector3f(this->r, this->g, this->b);\n }\n\n void SetRGB(Vector3f rgb)\n {\n this->r = rgb.x;\n this->g = rgb.y;\n this->b = rgb.z;\n }\n\n int ru() const;\n int gu() const;\n int bu() const;\n int au() const;\nprivate:\n float r,g,b,a;\n}" ({) "{" (labeled_statement) "public:\n Color();" (statement_identifier) "public" (:) ":" (expression_statement) "Color();" (call_expression) "Color()" (identifier) "Color" (argument_list) "()" (() "(" ()) ")" (;) ";" (comment) "// Color(uint32_t r, uint32_t g, uint32_t b, uint32_t a);" (declaration) "Color(float r, float g, float b, float a);" (macro_type_specifier) "Color(float" (identifier) "Color" (() "(" (type_descriptor) "float" (primitive_type) "float" ()) "" (identifier) "r" (,) "," (identifier) "float" (ERROR) "g" (identifier) "g" (,) "," (identifier) "float" (ERROR) "b" (identifier) "b" (,) "," (identifier) "float" (ERROR) "a)" (identifier) "a" ()) ")" (;) ";" (function_definition) "Color clone()\n {\n return Color(this->r, this->g, this->b, this->a);\n }" (type_identifier) "Color" (function_declarator) "clone()" (identifier) "clone" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n return Color(this->r, this->g, this->b, this->a);\n }" ({) "{" (return_statement) "return Color(this->r, this->g, this->b, this->a);" (return) "return" (call_expression) "Color(this->r, this->g, this->b, this->a)" (identifier) "Color" (argument_list) "(this->r, this->g, this->b, this->a)" (() "(" (field_expression) "this->r" (identifier) "this" (->) "->" (field_identifier) "r" (,) "," (field_expression) "this->g" (identifier) "this" (->) "->" (field_identifier) "g" (,) "," (field_expression) "this->b" (identifier) "this" (->) "->" (field_identifier) "b" (,) "," (field_expression) "this->a" (identifier) "this" (->) "->" (field_identifier) "a" ()) ")" (;) ";" (}) "}" (function_definition) "Vector3f toRGB()\n {\n return Vector3f(this->r, this->g, this->b);\n }" (type_identifier) "Vector3f" (function_declarator) "toRGB()" (identifier) "toRGB" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n return Vector3f(this->r, this->g, this->b);\n }" ({) "{" (return_statement) "return Vector3f(this->r, this->g, this->b);" (return) "return" (call_expression) "Vector3f(this->r, this->g, this->b)" (identifier) "Vector3f" (argument_list) "(this->r, this->g, this->b)" (() "(" (field_expression) "this->r" (identifier) "this" (->) "->" (field_identifier) "r" (,) "," (field_expression) "this->g" (identifier) "this" (->) "->" (field_identifier) "g" (,) "," (field_expression) "this->b" (identifier) "this" (->) "->" (field_identifier) "b" ()) ")" (;) ";" (}) "}" (function_definition) "void SetRGB(Vector3f rgb)\n {\n this->r = rgb.x;\n this->g = rgb.y;\n this->b = rgb.z;\n }" (primitive_type) "void" (function_declarator) "SetRGB(Vector3f rgb)" (identifier) "SetRGB" (parameter_list) "(Vector3f rgb)" (() "(" (parameter_declaration) "Vector3f rgb" (type_identifier) "Vector3f" (identifier) "rgb" ()) ")" (compound_statement) "{\n this->r = rgb.x;\n this->g = rgb.y;\n this->b = rgb.z;\n }" ({) "{" (expression_statement) "this->r = rgb.x;" (assignment_expression) "this->r = rgb.x" (field_expression) "this->r" (identifier) "this" (->) "->" (field_identifier) "r" (=) "=" (field_expression) "rgb.x" (identifier) "rgb" (.) "." (field_identifier) "x" (;) ";" (expression_statement) "this->g = rgb.y;" (assignment_expression) "this->g = rgb.y" (field_expression) "this->g" (identifier) "this" (->) "->" (field_identifier) "g" (=) "=" (field_expression) "rgb.y" (identifier) "rgb" (.) "." (field_identifier) "y" (;) ";" (expression_statement) "this->b = rgb.z;" (assignment_expression) "this->b = rgb.z" (field_expression) "this->b" (identifier) "this" (->) "->" (field_identifier) "b" (=) "=" (field_expression) "rgb.z" (identifier) "rgb" (.) "." (field_identifier) "z" (;) ";" (}) "}" (ERROR) "int ru() const;\n int gu() const;\n int bu() const;\n int au() const;\nprivate:\n float r,g,b,a;" (primitive_type) "int" (function_declarator) "ru()" (identifier) "ru" (parameter_list) "()" (() "(" ()) ")" (declaration) "const;\n int gu() const;\n int bu() const;\n int au() const;\nprivate:\n float r,g,b,a;" (type_qualifier) "const" (const) "const" (ERROR) ";" (;) ";" (primitive_type) "int" (ERROR) "gu() const;\n int bu() const;\n int au() const;\nprivate:\n float" (function_declarator) "gu() const" (identifier) "gu" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (primitive_type) "int" (function_declarator) "bu() const" (identifier) "bu" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (primitive_type) "int" (function_declarator) "au() const" (identifier) "au" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (identifier) "private" (:) ":" (primitive_type) "float" (identifier) "r" (,) "," (identifier) "g" (,) "," (identifier) "b" (,) "," (identifier) "a" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (#endif) "#endif"
227
6
{"language": "c", "success": true, "metadata": {"lines": 32, "avg_line_length": 19.81, "nodes": 129, "errors": 0, "source_hash": "777ce5a5e15a9dd4f94f3d0f58fa12da8bf3d85d9fb05b4f6c95d5448d5fa1ed", "categorized_nodes": 100}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef COLOR_INCLUDED\n#define COLOR_INCLUDED\n\n#include \"miru/basic/definitions.h\"\n#include \"miru/engine/vector.h\"\n\nclass Color\n{\npublic:\n Color();\n // Color(uint32_t r, uint32_t g, uint32_t b, uint32_t a);\n Color(float r, float g, float b, float a);\n\n Color clone()\n {\n return Color(this->r, this->g, this->b, this->a);\n }\n\n Vector3f toRGB()\n {\n return Vector3f(this->r, this->g, this->b);\n }\n\n void SetRGB(Vector3f rgb)\n {\n this->r = rgb.x;\n this->g = rgb.y;\n this->b = rgb.z;\n }\n\n int ru() const;\n int gu() const;\n int bu() const;\n int au() const;\nprivate:\n float r,g,b,a;\n};\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 128], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 38, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "identifier", "text": "COLOR_INCLUDED", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 22}}, {"id": 3, "type": "preproc_def", "text": "#define COLOR_INCLUDED\n", "parent": 0, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 5, "type": "identifier", "text": "COLOR_INCLUDED", "parent": 3, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 22}}, {"id": 6, "type": "preproc_include", "text": "#include \"miru/basic/definitions.h\"\n", "parent": 0, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"miru/basic/definitions.h\"", "parent": 6, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 35}}, {"id": 9, "type": "preproc_include", "text": "#include \"miru/engine/vector.h\"\n", "parent": 0, "children": [10, 11], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"miru/engine/vector.h\"", "parent": 9, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 31}}, {"id": 12, "type": "function_definition", "text": "class Color\n{\npublic:\n Color();\n // Color(uint32_t r, uint32_t g, uint32_t b, uint32_t a);\n Color(float r, float g, float b, float a);\n\n Color clone()\n {\n return Color(this->r, this->g, this->b, this->a);\n }\n\n Vector3f toRGB()\n {\n return Vector3f(this->r, this->g, this->b);\n }\n\n void SetRGB(Vector3f rgb)\n {\n this->r = rgb.x;\n this->g = rgb.y;\n this->b = rgb.z;\n }\n\n int ru() const;\n int gu() const;\n int bu() const;\n int au() const;\nprivate:\n float r,g,b,a;\n}", "parent": 0, "children": [13], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 36, "column": 1}}, {"id": 13, "type": "identifier", "text": "Color", "parent": 12, "children": [], "start_point": {"row": 6, "column": 6}, "end_point": {"row": 6, "column": 11}}, {"id": 14, "type": "labeled_statement", "text": "public:\n Color();", "parent": 12, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 12}}, {"id": 15, "type": "call_expression", "text": "Color()", "parent": 14, "children": [16, 17], "start_point": {"row": 9, "column": 4}, "end_point": {"row": 9, "column": 11}}, {"id": 16, "type": "identifier", "text": "Color", "parent": 15, "children": [], "start_point": {"row": 9, "column": 4}, "end_point": {"row": 9, "column": 9}}, {"id": 17, "type": "argument_list", "text": "()", "parent": 15, "children": [], "start_point": {"row": 9, "column": 9}, "end_point": {"row": 9, "column": 11}}, {"id": 18, "type": "declaration", "text": "Color(float r, float g, float b, float a);", "parent": 12, "children": [19, 23, 24, 25, 27, 28, 30, 31], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 46}}, {"id": 19, "type": "macro_type_specifier", "text": "Color(float", "parent": 18, "children": [20, 21], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 15}}, {"id": 20, "type": "identifier", "text": "Color", "parent": 19, "children": [], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 9}}, {"id": 21, "type": "type_descriptor", "text": "float", "parent": 19, "children": [22], "start_point": {"row": 11, "column": 10}, "end_point": {"row": 11, "column": 15}}, {"id": 22, "type": "primitive_type", "text": "float", "parent": 21, "children": [], "start_point": {"row": 11, "column": 10}, "end_point": {"row": 11, "column": 15}}, {"id": 23, "type": "identifier", "text": "r", "parent": 18, "children": [], "start_point": {"row": 11, "column": 16}, "end_point": {"row": 11, "column": 17}}, {"id": 24, "type": "identifier", "text": "float", "parent": 18, "children": [], "start_point": {"row": 11, "column": 19}, "end_point": {"row": 11, "column": 24}}, {"id": 25, "type": "ERROR", "text": "g", "parent": 18, "children": [26], "start_point": {"row": 11, "column": 25}, "end_point": {"row": 11, "column": 26}}, {"id": 26, "type": "identifier", "text": "g", "parent": 25, "children": [], "start_point": {"row": 11, "column": 25}, "end_point": {"row": 11, "column": 26}}, {"id": 27, "type": "identifier", "text": "float", "parent": 18, "children": [], "start_point": {"row": 11, "column": 28}, "end_point": {"row": 11, "column": 33}}, {"id": 28, "type": "ERROR", "text": "b", "parent": 18, "children": [29], "start_point": {"row": 11, "column": 34}, "end_point": {"row": 11, "column": 35}}, {"id": 29, "type": "identifier", "text": "b", "parent": 28, "children": [], "start_point": {"row": 11, "column": 34}, "end_point": {"row": 11, "column": 35}}, {"id": 30, "type": "identifier", "text": "float", "parent": 18, "children": [], "start_point": {"row": 11, "column": 37}, "end_point": {"row": 11, "column": 42}}, {"id": 31, "type": "ERROR", "text": "a)", "parent": 18, "children": [32], "start_point": {"row": 11, "column": 43}, "end_point": {"row": 11, "column": 45}}, {"id": 32, "type": "identifier", "text": "a", "parent": 31, "children": [], "start_point": {"row": 11, "column": 43}, "end_point": {"row": 11, "column": 44}}, {"id": 33, "type": "function_definition", "text": "Color clone()\n {\n return Color(this->r, this->g, this->b, this->a);\n }", "parent": 12, "children": [34, 35], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 16, "column": 5}}, {"id": 34, "type": "type_identifier", "text": "Color", "parent": 33, "children": [], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 9}}, {"id": 35, "type": "function_declarator", "text": "clone()", "parent": 33, "children": [36, 37], "start_point": {"row": 13, "column": 10}, "end_point": {"row": 13, "column": 17}}, {"id": 36, "type": "identifier", "text": "clone", "parent": 35, "children": [], "start_point": {"row": 13, "column": 10}, "end_point": {"row": 13, "column": 15}}, {"id": 37, "type": "parameter_list", "text": "()", "parent": 35, "children": [], "start_point": {"row": 13, "column": 15}, "end_point": {"row": 13, "column": 17}}, {"id": 38, "type": "return_statement", "text": "return Color(this->r, this->g, this->b, this->a);", "parent": 33, "children": [39], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 57}}, {"id": 39, "type": "call_expression", "text": "Color(this->r, this->g, this->b, this->a)", "parent": 38, "children": [40, 41], "start_point": {"row": 15, "column": 15}, "end_point": {"row": 15, "column": 56}}, {"id": 40, "type": "identifier", "text": "Color", "parent": 39, "children": [], "start_point": {"row": 15, "column": 15}, "end_point": {"row": 15, "column": 20}}, {"id": 41, "type": "argument_list", "text": "(this->r, this->g, this->b, this->a)", "parent": 39, "children": [42, 45, 48, 51], "start_point": {"row": 15, "column": 20}, "end_point": {"row": 15, "column": 56}}, {"id": 42, "type": "field_expression", "text": "this->r", "parent": 41, "children": [43, 44], "start_point": {"row": 15, "column": 21}, "end_point": {"row": 15, "column": 28}}, {"id": 43, "type": "identifier", "text": "this", "parent": 42, "children": [], "start_point": {"row": 15, "column": 21}, "end_point": {"row": 15, "column": 25}}, {"id": 44, "type": "field_identifier", "text": "r", "parent": 42, "children": [], "start_point": {"row": 15, "column": 27}, "end_point": {"row": 15, "column": 28}}, {"id": 45, "type": "field_expression", "text": "this->g", "parent": 41, "children": [46, 47], "start_point": {"row": 15, "column": 30}, "end_point": {"row": 15, "column": 37}}, {"id": 46, "type": "identifier", "text": "this", "parent": 45, "children": [], "start_point": {"row": 15, "column": 30}, "end_point": {"row": 15, "column": 34}}, {"id": 47, "type": "field_identifier", "text": "g", "parent": 45, "children": [], "start_point": {"row": 15, "column": 36}, "end_point": {"row": 15, "column": 37}}, {"id": 48, "type": "field_expression", "text": "this->b", "parent": 41, "children": [49, 50], "start_point": {"row": 15, "column": 39}, "end_point": {"row": 15, "column": 46}}, {"id": 49, "type": "identifier", "text": "this", "parent": 48, "children": [], "start_point": {"row": 15, "column": 39}, "end_point": {"row": 15, "column": 43}}, {"id": 50, "type": "field_identifier", "text": "b", "parent": 48, "children": [], "start_point": {"row": 15, "column": 45}, "end_point": {"row": 15, "column": 46}}, {"id": 51, "type": "field_expression", "text": "this->a", "parent": 41, "children": [52, 53], "start_point": {"row": 15, "column": 48}, "end_point": {"row": 15, "column": 55}}, {"id": 52, "type": "identifier", "text": "this", "parent": 51, "children": [], "start_point": {"row": 15, "column": 48}, "end_point": {"row": 15, "column": 52}}, {"id": 53, "type": "field_identifier", "text": "a", "parent": 51, "children": [], "start_point": {"row": 15, "column": 54}, "end_point": {"row": 15, "column": 55}}, {"id": 54, "type": "function_definition", "text": "Vector3f toRGB()\n {\n return Vector3f(this->r, this->g, this->b);\n }", "parent": 12, "children": [55, 56], "start_point": {"row": 18, "column": 4}, "end_point": {"row": 21, "column": 5}}, {"id": 55, "type": "type_identifier", "text": "Vector3f", "parent": 54, "children": [], "start_point": {"row": 18, "column": 4}, "end_point": {"row": 18, "column": 12}}, {"id": 56, "type": "function_declarator", "text": "toRGB()", "parent": 54, "children": [57, 58], "start_point": {"row": 18, "column": 13}, "end_point": {"row": 18, "column": 20}}, {"id": 57, "type": "identifier", "text": "toRGB", "parent": 56, "children": [], "start_point": {"row": 18, "column": 13}, "end_point": {"row": 18, "column": 18}}, {"id": 58, "type": "parameter_list", "text": "()", "parent": 56, "children": [], "start_point": {"row": 18, "column": 18}, "end_point": {"row": 18, "column": 20}}, {"id": 59, "type": "return_statement", "text": "return Vector3f(this->r, this->g, this->b);", "parent": 54, "children": [60], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 51}}, {"id": 60, "type": "call_expression", "text": "Vector3f(this->r, this->g, this->b)", "parent": 59, "children": [61, 62], "start_point": {"row": 20, "column": 15}, "end_point": {"row": 20, "column": 50}}, {"id": 61, "type": "identifier", "text": "Vector3f", "parent": 60, "children": [], "start_point": {"row": 20, "column": 15}, "end_point": {"row": 20, "column": 23}}, {"id": 62, "type": "argument_list", "text": "(this->r, this->g, this->b)", "parent": 60, "children": [63, 66, 69], "start_point": {"row": 20, "column": 23}, "end_point": {"row": 20, "column": 50}}, {"id": 63, "type": "field_expression", "text": "this->r", "parent": 62, "children": [64, 65], "start_point": {"row": 20, "column": 24}, "end_point": {"row": 20, "column": 31}}, {"id": 64, "type": "identifier", "text": "this", "parent": 63, "children": [], "start_point": {"row": 20, "column": 24}, "end_point": {"row": 20, "column": 28}}, {"id": 65, "type": "field_identifier", "text": "r", "parent": 63, "children": [], "start_point": {"row": 20, "column": 30}, "end_point": {"row": 20, "column": 31}}, {"id": 66, "type": "field_expression", "text": "this->g", "parent": 62, "children": [67, 68], "start_point": {"row": 20, "column": 33}, "end_point": {"row": 20, "column": 40}}, {"id": 67, "type": "identifier", "text": "this", "parent": 66, "children": [], "start_point": {"row": 20, "column": 33}, "end_point": {"row": 20, "column": 37}}, {"id": 68, "type": "field_identifier", "text": "g", "parent": 66, "children": [], "start_point": {"row": 20, "column": 39}, "end_point": {"row": 20, "column": 40}}, {"id": 69, "type": "field_expression", "text": "this->b", "parent": 62, "children": [70, 71], "start_point": {"row": 20, "column": 42}, "end_point": {"row": 20, "column": 49}}, {"id": 70, "type": "identifier", "text": "this", "parent": 69, "children": [], "start_point": {"row": 20, "column": 42}, "end_point": {"row": 20, "column": 46}}, {"id": 71, "type": "field_identifier", "text": "b", "parent": 69, "children": [], "start_point": {"row": 20, "column": 48}, "end_point": {"row": 20, "column": 49}}, {"id": 72, "type": "function_definition", "text": "void SetRGB(Vector3f rgb)\n {\n this->r = rgb.x;\n this->g = rgb.y;\n this->b = rgb.z;\n }", "parent": 12, "children": [73, 74], "start_point": {"row": 23, "column": 4}, "end_point": {"row": 28, "column": 5}}, {"id": 73, "type": "primitive_type", "text": "void", "parent": 72, "children": [], "start_point": {"row": 23, "column": 4}, "end_point": {"row": 23, "column": 8}}, {"id": 74, "type": "function_declarator", "text": "SetRGB(Vector3f rgb)", "parent": 72, "children": [75, 76], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 29}}, {"id": 75, "type": "identifier", "text": "SetRGB", "parent": 74, "children": [], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 15}}, {"id": 76, "type": "parameter_list", "text": "(Vector3f rgb)", "parent": 74, "children": [77], "start_point": {"row": 23, "column": 15}, "end_point": {"row": 23, "column": 29}}, {"id": 77, "type": "parameter_declaration", "text": "Vector3f rgb", "parent": 76, "children": [78, 79], "start_point": {"row": 23, "column": 16}, "end_point": {"row": 23, "column": 28}}, {"id": 78, "type": "type_identifier", "text": "Vector3f", "parent": 77, "children": [], "start_point": {"row": 23, "column": 16}, "end_point": {"row": 23, "column": 24}}, {"id": 79, "type": "identifier", "text": "rgb", "parent": 77, "children": [], "start_point": {"row": 23, "column": 25}, "end_point": {"row": 23, "column": 28}}, {"id": 80, "type": "assignment_expression", "text": "this->r = rgb.x", "parent": 72, "children": [81, 84, 85], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 23}}, {"id": 81, "type": "field_expression", "text": "this->r", "parent": 80, "children": [82, 83], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 15}}, {"id": 82, "type": "identifier", "text": "this", "parent": 81, "children": [], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 12}}, {"id": 83, "type": "field_identifier", "text": "r", "parent": 81, "children": [], "start_point": {"row": 25, "column": 14}, "end_point": {"row": 25, "column": 15}}, {"id": 84, "type": "=", "text": "=", "parent": 80, "children": [], "start_point": {"row": 25, "column": 16}, "end_point": {"row": 25, "column": 17}}, {"id": 85, "type": "field_expression", "text": "rgb.x", "parent": 80, "children": [86, 87], "start_point": {"row": 25, "column": 18}, "end_point": {"row": 25, "column": 23}}, {"id": 86, "type": "identifier", "text": "rgb", "parent": 85, "children": [], "start_point": {"row": 25, "column": 18}, "end_point": {"row": 25, "column": 21}}, {"id": 87, "type": "field_identifier", "text": "x", "parent": 85, "children": [], "start_point": {"row": 25, "column": 22}, "end_point": {"row": 25, "column": 23}}, {"id": 88, "type": "assignment_expression", "text": "this->g = rgb.y", "parent": 72, "children": [89, 92, 93], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 23}}, {"id": 89, "type": "field_expression", "text": "this->g", "parent": 88, "children": [90, 91], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 15}}, {"id": 90, "type": "identifier", "text": "this", "parent": 89, "children": [], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 12}}, {"id": 91, "type": "field_identifier", "text": "g", "parent": 89, "children": [], "start_point": {"row": 26, "column": 14}, "end_point": {"row": 26, "column": 15}}, {"id": 92, "type": "=", "text": "=", "parent": 88, "children": [], "start_point": {"row": 26, "column": 16}, "end_point": {"row": 26, "column": 17}}, {"id": 93, "type": "field_expression", "text": "rgb.y", "parent": 88, "children": [94, 95], "start_point": {"row": 26, "column": 18}, "end_point": {"row": 26, "column": 23}}, {"id": 94, "type": "identifier", "text": "rgb", "parent": 93, "children": [], "start_point": {"row": 26, "column": 18}, "end_point": {"row": 26, "column": 21}}, {"id": 95, "type": "field_identifier", "text": "y", "parent": 93, "children": [], "start_point": {"row": 26, "column": 22}, "end_point": {"row": 26, "column": 23}}, {"id": 96, "type": "assignment_expression", "text": "this->b = rgb.z", "parent": 72, "children": [97, 100, 101], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 23}}, {"id": 97, "type": "field_expression", "text": "this->b", "parent": 96, "children": [98, 99], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 15}}, {"id": 98, "type": "identifier", "text": "this", "parent": 97, "children": [], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 12}}, {"id": 99, "type": "field_identifier", "text": "b", "parent": 97, "children": [], "start_point": {"row": 27, "column": 14}, "end_point": {"row": 27, "column": 15}}, {"id": 100, "type": "=", "text": "=", "parent": 96, "children": [], "start_point": {"row": 27, "column": 16}, "end_point": {"row": 27, "column": 17}}, {"id": 101, "type": "field_expression", "text": "rgb.z", "parent": 96, "children": [102, 103], "start_point": {"row": 27, "column": 18}, "end_point": {"row": 27, "column": 23}}, {"id": 102, "type": "identifier", "text": "rgb", "parent": 101, "children": [], "start_point": {"row": 27, "column": 18}, "end_point": {"row": 27, "column": 21}}, {"id": 103, "type": "field_identifier", "text": "z", "parent": 101, "children": [], "start_point": {"row": 27, "column": 22}, "end_point": {"row": 27, "column": 23}}, {"id": 104, "type": "ERROR", "text": "int ru() const;\n int gu() const;\n int bu() const;\n int au() const;\nprivate:\n float r,g,b,a;", "parent": 12, "children": [105, 106, 109], "start_point": {"row": 30, "column": 4}, "end_point": {"row": 35, "column": 18}}, {"id": 105, "type": "primitive_type", "text": "int", "parent": 104, "children": [], "start_point": {"row": 30, "column": 4}, "end_point": {"row": 30, "column": 7}}, {"id": 106, "type": "function_declarator", "text": "ru()", "parent": 104, "children": [107, 108], "start_point": {"row": 30, "column": 8}, "end_point": {"row": 30, "column": 12}}, {"id": 107, "type": "identifier", "text": "ru", "parent": 106, "children": [], "start_point": {"row": 30, "column": 8}, "end_point": {"row": 30, "column": 10}}, {"id": 108, "type": "parameter_list", "text": "()", "parent": 106, "children": [], "start_point": {"row": 30, "column": 10}, "end_point": {"row": 30, "column": 12}}, {"id": 109, "type": "declaration", "text": "const;\n int gu() const;\n int bu() const;\n int au() const;\nprivate:\n float r,g,b,a;", "parent": 104, "children": [110, 111, 124, 125, 126, 127], "start_point": {"row": 30, "column": 13}, "end_point": {"row": 35, "column": 18}}, {"id": 110, "type": "primitive_type", "text": "int", "parent": 109, "children": [], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 7}}, {"id": 111, "type": "ERROR", "text": "gu() const;\n int bu() const;\n int au() const;\nprivate:\n float", "parent": 109, "children": [112, 115, 116, 119, 120, 123], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 35, "column": 9}}, {"id": 112, "type": "function_declarator", "text": "gu() const", "parent": 111, "children": [113, 114], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 18}}, {"id": 113, "type": "identifier", "text": "gu", "parent": 112, "children": [], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 10}}, {"id": 114, "type": "parameter_list", "text": "()", "parent": 112, "children": [], "start_point": {"row": 31, "column": 10}, "end_point": {"row": 31, "column": 12}}, {"id": 115, "type": "primitive_type", "text": "int", "parent": 111, "children": [], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 32, "column": 7}}, {"id": 116, "type": "function_declarator", "text": "bu() const", "parent": 111, "children": [117, 118], "start_point": {"row": 32, "column": 8}, "end_point": {"row": 32, "column": 18}}, {"id": 117, "type": "identifier", "text": "bu", "parent": 116, "children": [], "start_point": {"row": 32, "column": 8}, "end_point": {"row": 32, "column": 10}}, {"id": 118, "type": "parameter_list", "text": "()", "parent": 116, "children": [], "start_point": {"row": 32, "column": 10}, "end_point": {"row": 32, "column": 12}}, {"id": 119, "type": "primitive_type", "text": "int", "parent": 111, "children": [], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 7}}, {"id": 120, "type": "function_declarator", "text": "au() const", "parent": 111, "children": [121, 122], "start_point": {"row": 33, "column": 8}, "end_point": {"row": 33, "column": 18}}, {"id": 121, "type": "identifier", "text": "au", "parent": 120, "children": [], "start_point": {"row": 33, "column": 8}, "end_point": {"row": 33, "column": 10}}, {"id": 122, "type": "parameter_list", "text": "()", "parent": 120, "children": [], "start_point": {"row": 33, "column": 10}, "end_point": {"row": 33, "column": 12}}, {"id": 123, "type": "primitive_type", "text": "float", "parent": 111, "children": [], "start_point": {"row": 35, "column": 4}, "end_point": {"row": 35, "column": 9}}, {"id": 124, "type": "identifier", "text": "r", "parent": 109, "children": [], "start_point": {"row": 35, "column": 10}, "end_point": {"row": 35, "column": 11}}, {"id": 125, "type": "identifier", "text": "g", "parent": 109, "children": [], "start_point": {"row": 35, "column": 12}, "end_point": {"row": 35, "column": 13}}, {"id": 126, "type": "identifier", "text": "b", "parent": 109, "children": [], "start_point": {"row": 35, "column": 14}, "end_point": {"row": 35, "column": 15}}, {"id": 127, "type": "identifier", "text": "a", "parent": 109, "children": [], "start_point": {"row": 35, "column": 16}, "end_point": {"row": 35, "column": 17}}, {"id": 128, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 38, "column": 0}, "end_point": {"row": 38, "column": 6}}]}, "node_categories": {"declarations": {"functions": [12, 33, 35, 54, 56, 72, 74, 106, 112, 116, 120], "variables": [18, 77, 109], "classes": [], "imports": [6, 7, 9, 10], "modules": [], "enums": []}, "statements": {"expressions": [15, 39, 42, 45, 48, 51, 60, 63, 66, 69, 81, 85, 89, 93, 97, 101], "assignments": [80, 88, 96], "loops": [], "conditionals": [0, 1, 2, 5, 13, 16, 19, 20, 23, 24, 26, 27, 29, 30, 32, 34, 36, 40, 43, 44, 46, 47, 49, 50, 52, 53, 55, 57, 61, 64, 65, 67, 68, 70, 71, 75, 78, 79, 82, 83, 86, 87, 90, 91, 94, 95, 98, 99, 102, 103, 107, 113, 117, 121, 124, 125, 126, 127, 128], "returns": [38, 59], "exceptions": []}, "expressions": {"calls": [], "literals": [8, 11], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 12, "universal_type": "function", "name": "Color", "text_snippet": "class Color\n{\npublic:\n Color();\n // Color(uint32_t r, uint32_t g, uint32_t b, uint32_t a);\n "}, {"node_id": 33, "universal_type": "function", "name": "unknown", "text_snippet": "Color clone()\n {\n return Color(this->r, this->g, this->b, this->a);\n }"}, {"node_id": 35, "universal_type": "function", "name": "unknown", "text_snippet": "clone()"}, {"node_id": 54, "universal_type": "function", "name": "unknown", "text_snippet": "Vector3f toRGB()\n {\n return Vector3f(this->r, this->g, this->b);\n }"}, {"node_id": 56, "universal_type": "function", "name": "unknown", "text_snippet": "toRGB()"}, {"node_id": 72, "universal_type": "function", "name": "SetRGB", "text_snippet": "void SetRGB(Vector3f rgb)\n {\n this->r = rgb.x;\n this->g = rgb.y;\n this->b = "}, {"node_id": 74, "universal_type": "function", "name": "unknown", "text_snippet": "SetRGB(Vector3f rgb)"}, {"node_id": 106, "universal_type": "function", "name": "unknown", "text_snippet": "ru()"}, {"node_id": 112, "universal_type": "function", "name": "unknown", "text_snippet": "gu() const"}, {"node_id": 116, "universal_type": "function", "name": "unknown", "text_snippet": "bu() const"}, {"node_id": 120, "universal_type": "function", "name": "unknown", "text_snippet": "au() const"}], "class_declarations": [], "import_statements": [{"node_id": 6, "text": "#include \"miru/basic/definitions.h\"\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include \"miru/engine/vector.h\"\n"}, {"node_id": 10, "text": "#include"}]}, "original_source_code": "#ifndef COLOR_INCLUDED\n#define COLOR_INCLUDED\n\n#include \"miru/basic/definitions.h\"\n#include \"miru/engine/vector.h\"\n\nclass Color\n{\npublic:\n Color();\n // Color(uint32_t r, uint32_t g, uint32_t b, uint32_t a);\n Color(float r, float g, float b, float a);\n\n Color clone()\n {\n return Color(this->r, this->g, this->b, this->a);\n }\n\n Vector3f toRGB()\n {\n return Vector3f(this->r, this->g, this->b);\n }\n\n void SetRGB(Vector3f rgb)\n {\n this->r = rgb.x;\n this->g = rgb.y;\n this->b = rgb.z;\n }\n\n int ru() const;\n int gu() const;\n int bu() const;\n int au() const;\nprivate:\n float r,g,b,a;\n};\n\n#endif"}
80,511
c
/* * Copyright (C) 2017 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ #ifndef AAUDIO_SERVICE_ENDPOINT_SHARED_H #define AAUDIO_SERVICE_ENDPOINT_SHARED_H #include <atomic> #include <mutex> #include "AAudioServiceEndpoint.h" #include "client/AudioStreamInternal.h" #include "client/AudioStreamInternalPlay.h" #include "AAudioServiceStreamShared.h" #include "AAudioServiceStreamMMAP.h" #include "AAudioService.h" namespace aaudio { /** * This manages an AudioStreamInternal that is shared by multiple Client streams. */ class AAudioServiceEndpointShared : public AAudioServiceEndpoint { public: explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal); std::string dump() const override; aaudio_result_t open(const aaudio::AAudioStreamRequest &request) override; void close() override; aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream, audio_port_handle_t *clientHandle) override; aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream, audio_port_handle_t clientHandle) override; aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override; aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override; virtual void *callbackLoop() = 0; protected: AudioStreamInternal *getStreamInternal() const { return mStreamInternal.get(); }; aaudio_result_t startSharingThread_l(); aaudio_result_t stopSharingThread(); // An MMAP stream that is shared by multiple clients. android::sp<AudioStreamInternal> mStreamInternal; std::atomic<bool> mCallbackEnabled{false}; std::atomic<int> mRunningStreamCount{0}; }; } #endif //AAUDIO_SERVICE_ENDPOINT_SHARED_H
42.2
55
(translation_unit) "/*\n * Copyright (C) 2017 The Android Open Source Project\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n#ifndef AAUDIO_SERVICE_ENDPOINT_SHARED_H\n#define AAUDIO_SERVICE_ENDPOINT_SHARED_H\n\n#include <atomic>\n#include <mutex>\n\n#include "AAudioServiceEndpoint.h"\n#include "client/AudioStreamInternal.h"\n#include "client/AudioStreamInternalPlay.h"\n#include "AAudioServiceStreamShared.h"\n#include "AAudioServiceStreamMMAP.h"\n#include "AAudioService.h"\n\nnamespace aaudio {\n\n/**\n * This manages an AudioStreamInternal that is shared by multiple Client streams.\n */\nclass AAudioServiceEndpointShared : public AAudioServiceEndpoint {\n\npublic:\n explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);\n\n std::string dump() const override;\n\n aaudio_result_t open(const aaudio::AAudioStreamRequest &request) override;\n\n void close() override;\n\n aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;\n\nprotected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();\n };\n\n aaudio_result_t startSharingThread_l();\n\n aaudio_result_t stopSharingThread();\n\n // An MMAP stream that is shared by multiple clients.\n android::sp<AudioStreamInternal> mStreamInternal;\n\n std::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int> mRunningStreamCount{0};\n};\n\n}\n\n#endif //AAUDIO_SERVICE_ENDPOINT_SHARED_H\n" (comment) "/*\n * Copyright (C) 2017 The Android Open Source Project\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */" (preproc_ifdef) "#ifndef AAUDIO_SERVICE_ENDPOINT_SHARED_H\n#define AAUDIO_SERVICE_ENDPOINT_SHARED_H\n\n#include <atomic>\n#include <mutex>\n\n#include "AAudioServiceEndpoint.h"\n#include "client/AudioStreamInternal.h"\n#include "client/AudioStreamInternalPlay.h"\n#include "AAudioServiceStreamShared.h"\n#include "AAudioServiceStreamMMAP.h"\n#include "AAudioService.h"\n\nnamespace aaudio {\n\n/**\n * This manages an AudioStreamInternal that is shared by multiple Client streams.\n */\nclass AAudioServiceEndpointShared : public AAudioServiceEndpoint {\n\npublic:\n explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);\n\n std::string dump() const override;\n\n aaudio_result_t open(const aaudio::AAudioStreamRequest &request) override;\n\n void close() override;\n\n aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;\n\nprotected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();\n };\n\n aaudio_result_t startSharingThread_l();\n\n aaudio_result_t stopSharingThread();\n\n // An MMAP stream that is shared by multiple clients.\n android::sp<AudioStreamInternal> mStreamInternal;\n\n std::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int> mRunningStreamCount{0};\n};\n\n}\n\n#endif" (#ifndef) "#ifndef" (identifier) "AAUDIO_SERVICE_ENDPOINT_SHARED_H" (preproc_def) "#define AAUDIO_SERVICE_ENDPOINT_SHARED_H\n" (#define) "#define" (identifier) "AAUDIO_SERVICE_ENDPOINT_SHARED_H" (preproc_include) "#include <atomic>\n" (#include) "#include" (system_lib_string) "<atomic>" (preproc_include) "#include <mutex>\n" (#include) "#include" (system_lib_string) "<mutex>" (preproc_include) "#include "AAudioServiceEndpoint.h"\n" (#include) "#include" (string_literal) ""AAudioServiceEndpoint.h"" (") """ (string_content) "AAudioServiceEndpoint.h" (") """ (preproc_include) "#include "client/AudioStreamInternal.h"\n" (#include) "#include" (string_literal) ""client/AudioStreamInternal.h"" (") """ (string_content) "client/AudioStreamInternal.h" (") """ (preproc_include) "#include "client/AudioStreamInternalPlay.h"\n" (#include) "#include" (string_literal) ""client/AudioStreamInternalPlay.h"" (") """ (string_content) "client/AudioStreamInternalPlay.h" (") """ (preproc_include) "#include "AAudioServiceStreamShared.h"\n" (#include) "#include" (string_literal) ""AAudioServiceStreamShared.h"" (") """ (string_content) "AAudioServiceStreamShared.h" (") """ (preproc_include) "#include "AAudioServiceStreamMMAP.h"\n" (#include) "#include" (string_literal) ""AAudioServiceStreamMMAP.h"" (") """ (string_content) "AAudioServiceStreamMMAP.h" (") """ (preproc_include) "#include "AAudioService.h"\n" (#include) "#include" (string_literal) ""AAudioService.h"" (") """ (string_content) "AAudioService.h" (") """ (function_definition) "namespace aaudio {\n\n/**\n * This manages an AudioStreamInternal that is shared by multiple Client streams.\n */\nclass AAudioServiceEndpointShared : public AAudioServiceEndpoint {\n\npublic:\n explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);\n\n std::string dump() const override;\n\n aaudio_result_t open(const aaudio::AAudioStreamRequest &request) override;\n\n void close() override;\n\n aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;\n\nprotected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();\n };\n\n aaudio_result_t startSharingThread_l();\n\n aaudio_result_t stopSharingThread();\n\n // An MMAP stream that is shared by multiple clients.\n android::sp<AudioStreamInternal> mStreamInternal;\n\n std::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int> mRunningStreamCount{0};\n};\n\n}" (type_identifier) "namespace" (identifier) "aaudio" (compound_statement) "{\n\n/**\n * This manages an AudioStreamInternal that is shared by multiple Client streams.\n */\nclass AAudioServiceEndpointShared : public AAudioServiceEndpoint {\n\npublic:\n explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);\n\n std::string dump() const override;\n\n aaudio_result_t open(const aaudio::AAudioStreamRequest &request) override;\n\n void close() override;\n\n aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;\n\nprotected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();\n };\n\n aaudio_result_t startSharingThread_l();\n\n aaudio_result_t stopSharingThread();\n\n // An MMAP stream that is shared by multiple clients.\n android::sp<AudioStreamInternal> mStreamInternal;\n\n std::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int> mRunningStreamCount{0};\n};\n\n}" ({) "{" (comment) "/**\n * This manages an AudioStreamInternal that is shared by multiple Client streams.\n */" (function_definition) "class AAudioServiceEndpointShared : public AAudioServiceEndpoint {\n\npublic:\n explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);\n\n std::string dump() const override;\n\n aaudio_result_t open(const aaudio::AAudioStreamRequest &request) override;\n\n void close() override;\n\n aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;\n\nprotected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();\n };\n\n aaudio_result_t startSharingThread_l();\n\n aaudio_result_t stopSharingThread();\n\n // An MMAP stream that is shared by multiple clients.\n android::sp<AudioStreamInternal> mStreamInternal;\n\n std::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int> mRunningStreamCount{0};\n}" (type_identifier) "class" (identifier) "AAudioServiceEndpointShared" (ERROR) ": public AAudioServiceEndpoint" (:) ":" (identifier) "public" (identifier) "AAudioServiceEndpoint" (compound_statement) "{\n\npublic:\n explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);\n\n std::string dump() const override;\n\n aaudio_result_t open(const aaudio::AAudioStreamRequest &request) override;\n\n void close() override;\n\n aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;\n\nprotected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();\n };\n\n aaudio_result_t startSharingThread_l();\n\n aaudio_result_t stopSharingThread();\n\n // An MMAP stream that is shared by multiple clients.\n android::sp<AudioStreamInternal> mStreamInternal;\n\n std::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int> mRunningStreamCount{0};\n}" ({) "{" (labeled_statement) "public:\n explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);" (statement_identifier) "public" (:) ":" (declaration) "explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);" (type_identifier) "explicit" (function_declarator) "AAudioServiceEndpointShared(AudioStreamInternal *streamInternal)" (identifier) "AAudioServiceEndpointShared" (parameter_list) "(AudioStreamInternal *streamInternal)" (() "(" (parameter_declaration) "AudioStreamInternal *streamInternal" (type_identifier) "AudioStreamInternal" (pointer_declarator) "*streamInternal" (*) "*" (identifier) "streamInternal" ()) ")" (;) ";" (labeled_statement) "std::string dump() const override;" (statement_identifier) "std" (:) ":" (ERROR) ":string dump() const override" (:) ":" (type_identifier) "string" (function_declarator) "dump() const override" (identifier) "dump" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (identifier) "override" (expression_statement) ";" (;) ";" (ERROR) "aaudio_result_t open(const aaudio::AAudioStreamRequest &request) override" (type_identifier) "aaudio_result_t" (function_declarator) "open(const aaudio::AAudioStreamRequest &request) override" (identifier) "open" (parameter_list) "(const aaudio::AAudioStreamRequest &request)" (() "(" (parameter_declaration) "const aaudio::AAudioStreamRequest &request" (type_qualifier) "const" (const) "const" (type_identifier) "aaudio" (ERROR) "::AAudioStreamRequest &" (:) ":" (:) ":" (identifier) "AAudioStreamRequest" (&) "&" (identifier) "request" ()) ")" (identifier) "override" (expression_statement) ";" (;) ";" (ERROR) "void close() override;\n\n aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;\n\nprotected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();\n };\n\n aaudio_result_t startSharingThread_l();\n\n aaudio_result_t stopSharingThread();\n\n // An MMAP stream that is shared by multiple clients.\n android::sp<AudioStreamInternal> mStreamInternal;\n\n std::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int> mRunningStreamCount{0}" (primitive_type) "void" (function_declarator) "close()" (identifier) "close" (parameter_list) "()" (() "(" ()) ")" (declaration) "override;" (type_identifier) "override" (identifier) "" (;) ";" (declaration) "aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;" (type_identifier) "aaudio_result_t" (ERROR) "startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void" (function_declarator) "startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override" (identifier) "startStream" (parameter_list) "(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle)" (() "(" (parameter_declaration) "android::sp<AAudioServiceStreamBase> stream" (type_identifier) "android" (ERROR) "::sp<AAudioServiceStreamBase>" (:) ":" (:) ":" (identifier) "sp" (<) "<" (identifier) "AAudioServiceStreamBase" (>) ">" (identifier) "stream" (,) "," (parameter_declaration) "audio_port_handle_t *clientHandle" (type_identifier) "audio_port_handle_t" (pointer_declarator) "*clientHandle" (*) "*" (identifier) "clientHandle" ()) ")" (identifier) "override" (;) ";" (identifier) "aaudio_result_t" (function_declarator) "stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override" (identifier) "stopStream" (parameter_list) "(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle)" (() "(" (parameter_declaration) "android::sp<AAudioServiceStreamBase> stream" (type_identifier) "android" (ERROR) "::sp<AAudioServiceStreamBase>" (:) ":" (:) ":" (identifier) "sp" (<) "<" (identifier) "AAudioServiceStreamBase" (>) ">" (identifier) "stream" (,) "," (parameter_declaration) "audio_port_handle_t clientHandle" (type_identifier) "audio_port_handle_t" (identifier) "clientHandle" ()) ")" (identifier) "override" (;) ";" (identifier) "aaudio_result_t" (function_declarator) "getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override" (identifier) "getFreeRunningPosition" (parameter_list) "(int64_t *positionFrames, int64_t *timeNanos)" (() "(" (parameter_declaration) "int64_t *positionFrames" (primitive_type) "int64_t" (pointer_declarator) "*positionFrames" (*) "*" (identifier) "positionFrames" (,) "," (parameter_declaration) "int64_t *timeNanos" (primitive_type) "int64_t" (pointer_declarator) "*timeNanos" (*) "*" (identifier) "timeNanos" ()) ")" (identifier) "override" (;) ";" (identifier) "aaudio_result_t" (function_declarator) "getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override" (identifier) "getTimestamp" (parameter_list) "(int64_t *positionFrames, int64_t *timeNanos)" (() "(" (parameter_declaration) "int64_t *positionFrames" (primitive_type) "int64_t" (pointer_declarator) "*positionFrames" (*) "*" (identifier) "positionFrames" (,) "," (parameter_declaration) "int64_t *timeNanos" (primitive_type) "int64_t" (pointer_declarator) "*timeNanos" (*) "*" (identifier) "timeNanos" ()) ")" (identifier) "override" (;) ";" (identifier) "virtual" (identifier) "void" (init_declarator) "*callbackLoop() = 0" (pointer_declarator) "*callbackLoop()" (*) "*" (function_declarator) "callbackLoop()" (identifier) "callbackLoop" (parameter_list) "()" (() "(" ()) ")" (=) "=" (number_literal) "0" (;) ";" (declaration) "protected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();" (type_identifier) "protected" (ERROR) ":\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal." (:) ":" (identifier) "AudioStreamInternal" (pointer_declarator) "*getStreamInternal() const" (*) "*" (function_declarator) "getStreamInternal() const" (identifier) "getStreamInternal" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" ({) "{" (return) "return" (identifier) "mStreamInternal" (.) "." (function_declarator) "get()" (identifier) "get" (parameter_list) "()" (() "(" ()) ")" (;) ";" (ERROR) "};" (}) "}" (;) ";" (declaration) "aaudio_result_t startSharingThread_l();" (type_identifier) "aaudio_result_t" (function_declarator) "startSharingThread_l()" (identifier) "startSharingThread_l" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "aaudio_result_t stopSharingThread();" (type_identifier) "aaudio_result_t" (function_declarator) "stopSharingThread()" (identifier) "stopSharingThread" (parameter_list) "()" (() "(" ()) ")" (;) ";" (comment) "// An MMAP stream that is shared by multiple clients." (declaration) "android::sp<AudioStreamInternal> mStreamInternal;" (type_identifier) "android" (ERROR) "::sp<AudioStreamInternal>" (:) ":" (:) ":" (identifier) "sp" (<) "<" (identifier) "AudioStreamInternal" (>) ">" (identifier) "mStreamInternal" (;) ";" (type_identifier) "std" (ERROR) "::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int>" (:) ":" (:) ":" (identifier) "atomic" (<) "<" (primitive_type) "bool" (>) ">" (identifier) "mCallbackEnabled" ({) "{" (false) "false" (}) "}" (;) ";" (identifier) "std" (:) ":" (:) ":" (identifier) "atomic" (<) "<" (primitive_type) "int" (>) ">" (identifier) "mRunningStreamCount" ({) "{" (number_literal) "0" (}) "}" (expression_statement) ";" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (}) "}" (#endif) "#endif" (comment) "//AAUDIO_SERVICE_ENDPOINT_SHARED_H"
312
12
{"language": "c", "success": true, "metadata": {"lines": 55, "avg_line_length": 42.2, "nodes": 198, "errors": 0, "source_hash": "896a0d9b9d551db1c704302b5e660f0f7f7155f9868347f91b5f19ca83ee3ed8", "categorized_nodes": 133}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef AAUDIO_SERVICE_ENDPOINT_SHARED_H\n#define AAUDIO_SERVICE_ENDPOINT_SHARED_H\n\n#include <atomic>\n#include <mutex>\n\n#include \"AAudioServiceEndpoint.h\"\n#include \"client/AudioStreamInternal.h\"\n#include \"client/AudioStreamInternalPlay.h\"\n#include \"AAudioServiceStreamShared.h\"\n#include \"AAudioServiceStreamMMAP.h\"\n#include \"AAudioService.h\"\n\nnamespace aaudio {\n\n/**\n * This manages an AudioStreamInternal that is shared by multiple Client streams.\n */\nclass AAudioServiceEndpointShared : public AAudioServiceEndpoint {\n\npublic:\n explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);\n\n std::string dump() const override;\n\n aaudio_result_t open(const aaudio::AAudioStreamRequest &request) override;\n\n void close() override;\n\n aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;\n\nprotected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();\n };\n\n aaudio_result_t startSharingThread_l();\n\n aaudio_result_t stopSharingThread();\n\n // An MMAP stream that is shared by multiple clients.\n android::sp<AudioStreamInternal> mStreamInternal;\n\n std::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int> mRunningStreamCount{0};\n};\n\n}\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 15, 18, 21, 24, 27, 30, 197], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 77, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 7}}, {"id": 2, "type": "identifier", "text": "AAUDIO_SERVICE_ENDPOINT_SHARED_H", "parent": 0, "children": [], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 40}}, {"id": 3, "type": "preproc_def", "text": "#define AAUDIO_SERVICE_ENDPOINT_SHARED_H\n", "parent": 0, "children": [4, 5], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 18, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 7}}, {"id": 5, "type": "identifier", "text": "AAUDIO_SERVICE_ENDPOINT_SHARED_H", "parent": 3, "children": [], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 17, "column": 40}}, {"id": 6, "type": "preproc_include", "text": "#include <atomic>\n", "parent": 0, "children": [7, 8], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 20, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<atomic>", "parent": 6, "children": [], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 17}}, {"id": 9, "type": "preproc_include", "text": "#include <mutex>\n", "parent": 0, "children": [10, 11], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 21, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<mutex>", "parent": 9, "children": [], "start_point": {"row": 20, "column": 9}, "end_point": {"row": 20, "column": 16}}, {"id": 12, "type": "preproc_include", "text": "#include \"AAudioServiceEndpoint.h\"\n", "parent": 0, "children": [13, 14], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 23, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 8}}, {"id": 14, "type": "string_literal", "text": "\"AAudioServiceEndpoint.h\"", "parent": 12, "children": [], "start_point": {"row": 22, "column": 9}, "end_point": {"row": 22, "column": 34}}, {"id": 15, "type": "preproc_include", "text": "#include \"client/AudioStreamInternal.h\"\n", "parent": 0, "children": [16, 17], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 24, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 8}}, {"id": 17, "type": "string_literal", "text": "\"client/AudioStreamInternal.h\"", "parent": 15, "children": [], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 39}}, {"id": 18, "type": "preproc_include", "text": "#include \"client/AudioStreamInternalPlay.h\"\n", "parent": 0, "children": [19, 20], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 25, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 8}}, {"id": 20, "type": "string_literal", "text": "\"client/AudioStreamInternalPlay.h\"", "parent": 18, "children": [], "start_point": {"row": 24, "column": 9}, "end_point": {"row": 24, "column": 43}}, {"id": 21, "type": "preproc_include", "text": "#include \"AAudioServiceStreamShared.h\"\n", "parent": 0, "children": [22, 23], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 26, "column": 0}}, {"id": 22, "type": "#include", "text": "#include", "parent": 21, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 8}}, {"id": 23, "type": "string_literal", "text": "\"AAudioServiceStreamShared.h\"", "parent": 21, "children": [], "start_point": {"row": 25, "column": 9}, "end_point": {"row": 25, "column": 38}}, {"id": 24, "type": "preproc_include", "text": "#include \"AAudioServiceStreamMMAP.h\"\n", "parent": 0, "children": [25, 26], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 27, "column": 0}}, {"id": 25, "type": "#include", "text": "#include", "parent": 24, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 8}}, {"id": 26, "type": "string_literal", "text": "\"AAudioServiceStreamMMAP.h\"", "parent": 24, "children": [], "start_point": {"row": 26, "column": 9}, "end_point": {"row": 26, "column": 36}}, {"id": 27, "type": "preproc_include", "text": "#include \"AAudioService.h\"\n", "parent": 0, "children": [28, 29], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 28, "column": 0}}, {"id": 28, "type": "#include", "text": "#include", "parent": 27, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 8}}, {"id": 29, "type": "string_literal", "text": "\"AAudioService.h\"", "parent": 27, "children": [], "start_point": {"row": 27, "column": 9}, "end_point": {"row": 27, "column": 26}}, {"id": 30, "type": "function_definition", "text": "namespace aaudio {\n\n/**\n * This manages an AudioStreamInternal that is shared by multiple Client streams.\n */\nclass AAudioServiceEndpointShared : public AAudioServiceEndpoint {\n\npublic:\n explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);\n\n std::string dump() const override;\n\n aaudio_result_t open(const aaudio::AAudioStreamRequest &request) override;\n\n void close() override;\n\n aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;\n\nprotected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();\n };\n\n aaudio_result_t startSharingThread_l();\n\n aaudio_result_t stopSharingThread();\n\n // An MMAP stream that is shared by multiple clients.\n android::sp<AudioStreamInternal> mStreamInternal;\n\n std::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int> mRunningStreamCount{0};\n};\n\n}", "parent": 0, "children": [31, 32], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 75, "column": 1}}, {"id": 31, "type": "type_identifier", "text": "namespace", "parent": 30, "children": [], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 9}}, {"id": 32, "type": "identifier", "text": "aaudio", "parent": 30, "children": [], "start_point": {"row": 29, "column": 10}, "end_point": {"row": 29, "column": 16}}, {"id": 33, "type": "function_definition", "text": "class AAudioServiceEndpointShared : public AAudioServiceEndpoint {\n\npublic:\n explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);\n\n std::string dump() const override;\n\n aaudio_result_t open(const aaudio::AAudioStreamRequest &request) override;\n\n void close() override;\n\n aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;\n\nprotected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();\n };\n\n aaudio_result_t startSharingThread_l();\n\n aaudio_result_t stopSharingThread();\n\n // An MMAP stream that is shared by multiple clients.\n android::sp<AudioStreamInternal> mStreamInternal;\n\n std::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int> mRunningStreamCount{0};\n}", "parent": 30, "children": [34, 35], "start_point": {"row": 34, "column": 0}, "end_point": {"row": 73, "column": 1}}, {"id": 34, "type": "identifier", "text": "AAudioServiceEndpointShared", "parent": 33, "children": [], "start_point": {"row": 34, "column": 6}, "end_point": {"row": 34, "column": 33}}, {"id": 35, "type": "ERROR", "text": ": public AAudioServiceEndpoint", "parent": 33, "children": [36], "start_point": {"row": 34, "column": 34}, "end_point": {"row": 34, "column": 64}}, {"id": 36, "type": "identifier", "text": "AAudioServiceEndpoint", "parent": 35, "children": [], "start_point": {"row": 34, "column": 43}, "end_point": {"row": 34, "column": 64}}, {"id": 37, "type": "labeled_statement", "text": "public:\n explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);", "parent": 33, "children": [38], "start_point": {"row": 36, "column": 0}, "end_point": {"row": 37, "column": 78}}, {"id": 38, "type": "declaration", "text": "explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);", "parent": 37, "children": [39, 40], "start_point": {"row": 37, "column": 4}, "end_point": {"row": 37, "column": 78}}, {"id": 39, "type": "type_identifier", "text": "explicit", "parent": 38, "children": [], "start_point": {"row": 37, "column": 4}, "end_point": {"row": 37, "column": 12}}, {"id": 40, "type": "function_declarator", "text": "AAudioServiceEndpointShared(AudioStreamInternal *streamInternal)", "parent": 38, "children": [41, 42], "start_point": {"row": 37, "column": 13}, "end_point": {"row": 37, "column": 77}}, {"id": 41, "type": "identifier", "text": "AAudioServiceEndpointShared", "parent": 40, "children": [], "start_point": {"row": 37, "column": 13}, "end_point": {"row": 37, "column": 40}}, {"id": 42, "type": "parameter_list", "text": "(AudioStreamInternal *streamInternal)", "parent": 40, "children": [43], "start_point": {"row": 37, "column": 40}, "end_point": {"row": 37, "column": 77}}, {"id": 43, "type": "parameter_declaration", "text": "AudioStreamInternal *streamInternal", "parent": 42, "children": [44, 45], "start_point": {"row": 37, "column": 41}, "end_point": {"row": 37, "column": 76}}, {"id": 44, "type": "type_identifier", "text": "AudioStreamInternal", "parent": 43, "children": [], "start_point": {"row": 37, "column": 41}, "end_point": {"row": 37, "column": 60}}, {"id": 45, "type": "pointer_declarator", "text": "*streamInternal", "parent": 43, "children": [46, 47], "start_point": {"row": 37, "column": 61}, "end_point": {"row": 37, "column": 76}}, {"id": 46, "type": "*", "text": "*", "parent": 45, "children": [], "start_point": {"row": 37, "column": 61}, "end_point": {"row": 37, "column": 62}}, {"id": 47, "type": "identifier", "text": "streamInternal", "parent": 45, "children": [], "start_point": {"row": 37, "column": 62}, "end_point": {"row": 37, "column": 76}}, {"id": 48, "type": "labeled_statement", "text": "std::string dump() const override;", "parent": 33, "children": [49, 50], "start_point": {"row": 39, "column": 4}, "end_point": {"row": 39, "column": 38}}, {"id": 49, "type": "statement_identifier", "text": "std", "parent": 48, "children": [], "start_point": {"row": 39, "column": 4}, "end_point": {"row": 39, "column": 7}}, {"id": 50, "type": "ERROR", "text": ":string dump() const override", "parent": 48, "children": [51, 52], "start_point": {"row": 39, "column": 8}, "end_point": {"row": 39, "column": 37}}, {"id": 51, "type": "type_identifier", "text": "string", "parent": 50, "children": [], "start_point": {"row": 39, "column": 9}, "end_point": {"row": 39, "column": 15}}, {"id": 52, "type": "function_declarator", "text": "dump() const override", "parent": 50, "children": [53, 54, 55], "start_point": {"row": 39, "column": 16}, "end_point": {"row": 39, "column": 37}}, {"id": 53, "type": "identifier", "text": "dump", "parent": 52, "children": [], "start_point": {"row": 39, "column": 16}, "end_point": {"row": 39, "column": 20}}, {"id": 54, "type": "parameter_list", "text": "()", "parent": 52, "children": [], "start_point": {"row": 39, "column": 20}, "end_point": {"row": 39, "column": 22}}, {"id": 55, "type": "identifier", "text": "override", "parent": 52, "children": [], "start_point": {"row": 39, "column": 29}, "end_point": {"row": 39, "column": 37}}, {"id": 56, "type": "ERROR", "text": "aaudio_result_t open(const aaudio::AAudioStreamRequest &request) override", "parent": 33, "children": [57, 58], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 41, "column": 77}}, {"id": 57, "type": "type_identifier", "text": "aaudio_result_t", "parent": 56, "children": [], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 41, "column": 19}}, {"id": 58, "type": "function_declarator", "text": "open(const aaudio::AAudioStreamRequest &request) override", "parent": 56, "children": [59, 60, 66], "start_point": {"row": 41, "column": 20}, "end_point": {"row": 41, "column": 77}}, {"id": 59, "type": "identifier", "text": "open", "parent": 58, "children": [], "start_point": {"row": 41, "column": 20}, "end_point": {"row": 41, "column": 24}}, {"id": 60, "type": "parameter_list", "text": "(const aaudio::AAudioStreamRequest &request)", "parent": 58, "children": [61], "start_point": {"row": 41, "column": 24}, "end_point": {"row": 41, "column": 68}}, {"id": 61, "type": "parameter_declaration", "text": "const aaudio::AAudioStreamRequest &request", "parent": 60, "children": [62, 63, 65], "start_point": {"row": 41, "column": 25}, "end_point": {"row": 41, "column": 67}}, {"id": 62, "type": "type_identifier", "text": "aaudio", "parent": 61, "children": [], "start_point": {"row": 41, "column": 31}, "end_point": {"row": 41, "column": 37}}, {"id": 63, "type": "ERROR", "text": "::AAudioStreamRequest &", "parent": 61, "children": [64], "start_point": {"row": 41, "column": 37}, "end_point": {"row": 41, "column": 60}}, {"id": 64, "type": "identifier", "text": "AAudioStreamRequest", "parent": 63, "children": [], "start_point": {"row": 41, "column": 39}, "end_point": {"row": 41, "column": 58}}, {"id": 65, "type": "identifier", "text": "request", "parent": 61, "children": [], "start_point": {"row": 41, "column": 60}, "end_point": {"row": 41, "column": 67}}, {"id": 66, "type": "identifier", "text": "override", "parent": 58, "children": [], "start_point": {"row": 41, "column": 69}, "end_point": {"row": 41, "column": 77}}, {"id": 67, "type": "ERROR", "text": "void close() override;\n\n aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;\n\nprotected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();\n };\n\n aaudio_result_t startSharingThread_l();\n\n aaudio_result_t stopSharingThread();\n\n // An MMAP stream that is shared by multiple clients.\n android::sp<AudioStreamInternal> mStreamInternal;\n\n std::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int> mRunningStreamCount{0}", "parent": 33, "children": [68, 69, 72, 75, 151, 163, 164, 169, 174, 182, 183, 195, 196], "start_point": {"row": 43, "column": 4}, "end_point": {"row": 72, "column": 51}}, {"id": 68, "type": "primitive_type", "text": "void", "parent": 67, "children": [], "start_point": {"row": 43, "column": 4}, "end_point": {"row": 43, "column": 8}}, {"id": 69, "type": "function_declarator", "text": "close()", "parent": 67, "children": [70, 71], "start_point": {"row": 43, "column": 9}, "end_point": {"row": 43, "column": 16}}, {"id": 70, "type": "identifier", "text": "close", "parent": 69, "children": [], "start_point": {"row": 43, "column": 9}, "end_point": {"row": 43, "column": 14}}, {"id": 71, "type": "parameter_list", "text": "()", "parent": 69, "children": [], "start_point": {"row": 43, "column": 14}, "end_point": {"row": 43, "column": 16}}, {"id": 72, "type": "declaration", "text": "override;", "parent": 67, "children": [73, 74], "start_point": {"row": 43, "column": 17}, "end_point": {"row": 43, "column": 26}}, {"id": 73, "type": "type_identifier", "text": "override", "parent": 72, "children": [], "start_point": {"row": 43, "column": 17}, "end_point": {"row": 43, "column": 25}}, {"id": 74, "type": "identifier", "text": "", "parent": 72, "children": [], "start_point": {"row": 43, "column": 25}, "end_point": {"row": 43, "column": 25}}, {"id": 75, "type": "declaration", "text": "aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;", "parent": 67, "children": [76, 77, 143], "start_point": {"row": 45, "column": 4}, "end_point": {"row": 55, "column": 39}}, {"id": 76, "type": "type_identifier", "text": "aaudio_result_t", "parent": 75, "children": [], "start_point": {"row": 45, "column": 4}, "end_point": {"row": 45, "column": 19}}, {"id": 77, "type": "ERROR", "text": "startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void", "parent": 75, "children": [78, 95, 96, 111, 112, 126, 127, 141, 142], "start_point": {"row": 45, "column": 20}, "end_point": {"row": 55, "column": 16}}, {"id": 78, "type": "function_declarator", "text": "startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override", "parent": 77, "children": [79, 80, 94], "start_point": {"row": 45, "column": 20}, "end_point": {"row": 46, "column": 75}}, {"id": 79, "type": "identifier", "text": "startStream", "parent": 78, "children": [], "start_point": {"row": 45, "column": 20}, "end_point": {"row": 45, "column": 31}}, {"id": 80, "type": "parameter_list", "text": "(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle)", "parent": 78, "children": [81, 89], "start_point": {"row": 45, "column": 31}, "end_point": {"row": 46, "column": 66}}, {"id": 81, "type": "parameter_declaration", "text": "android::sp<AAudioServiceStreamBase> stream", "parent": 80, "children": [82, 83, 88], "start_point": {"row": 45, "column": 32}, "end_point": {"row": 45, "column": 75}}, {"id": 82, "type": "type_identifier", "text": "android", "parent": 81, "children": [], "start_point": {"row": 45, "column": 32}, "end_point": {"row": 45, "column": 39}}, {"id": 83, "type": "ERROR", "text": "::sp<AAudioServiceStreamBase>", "parent": 81, "children": [84, 85, 86, 87], "start_point": {"row": 45, "column": 39}, "end_point": {"row": 45, "column": 68}}, {"id": 84, "type": "identifier", "text": "sp", "parent": 83, "children": [], "start_point": {"row": 45, "column": 41}, "end_point": {"row": 45, "column": 43}}, {"id": 85, "type": "<", "text": "<", "parent": 83, "children": [], "start_point": {"row": 45, "column": 43}, "end_point": {"row": 45, "column": 44}}, {"id": 86, "type": "identifier", "text": "AAudioServiceStreamBase", "parent": 83, "children": [], "start_point": {"row": 45, "column": 44}, "end_point": {"row": 45, "column": 67}}, {"id": 87, "type": ">", "text": ">", "parent": 83, "children": [], "start_point": {"row": 45, "column": 67}, "end_point": {"row": 45, "column": 68}}, {"id": 88, "type": "identifier", "text": "stream", "parent": 81, "children": [], "start_point": {"row": 45, "column": 69}, "end_point": {"row": 45, "column": 75}}, {"id": 89, "type": "parameter_declaration", "text": "audio_port_handle_t *clientHandle", "parent": 80, "children": [90, 91], "start_point": {"row": 46, "column": 32}, "end_point": {"row": 46, "column": 65}}, {"id": 90, "type": "type_identifier", "text": "audio_port_handle_t", "parent": 89, "children": [], "start_point": {"row": 46, "column": 32}, "end_point": {"row": 46, "column": 51}}, {"id": 91, "type": "pointer_declarator", "text": "*clientHandle", "parent": 89, "children": [92, 93], "start_point": {"row": 46, "column": 52}, "end_point": {"row": 46, "column": 65}}, {"id": 92, "type": "*", "text": "*", "parent": 91, "children": [], "start_point": {"row": 46, "column": 52}, "end_point": {"row": 46, "column": 53}}, {"id": 93, "type": "identifier", "text": "clientHandle", "parent": 91, "children": [], "start_point": {"row": 46, "column": 53}, "end_point": {"row": 46, "column": 65}}, {"id": 94, "type": "identifier", "text": "override", "parent": 78, "children": [], "start_point": {"row": 46, "column": 67}, "end_point": {"row": 46, "column": 75}}, {"id": 95, "type": "identifier", "text": "aaudio_result_t", "parent": 77, "children": [], "start_point": {"row": 48, "column": 4}, "end_point": {"row": 48, "column": 19}}, {"id": 96, "type": "function_declarator", "text": "stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override", "parent": 77, "children": [97, 98, 110], "start_point": {"row": 48, "column": 20}, "end_point": {"row": 49, "column": 73}}, {"id": 97, "type": "identifier", "text": "stopStream", "parent": 96, "children": [], "start_point": {"row": 48, "column": 20}, "end_point": {"row": 48, "column": 30}}, {"id": 98, "type": "parameter_list", "text": "(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle)", "parent": 96, "children": [99, 107], "start_point": {"row": 48, "column": 30}, "end_point": {"row": 49, "column": 64}}, {"id": 99, "type": "parameter_declaration", "text": "android::sp<AAudioServiceStreamBase> stream", "parent": 98, "children": [100, 101, 106], "start_point": {"row": 48, "column": 31}, "end_point": {"row": 48, "column": 74}}, {"id": 100, "type": "type_identifier", "text": "android", "parent": 99, "children": [], "start_point": {"row": 48, "column": 31}, "end_point": {"row": 48, "column": 38}}, {"id": 101, "type": "ERROR", "text": "::sp<AAudioServiceStreamBase>", "parent": 99, "children": [102, 103, 104, 105], "start_point": {"row": 48, "column": 38}, "end_point": {"row": 48, "column": 67}}, {"id": 102, "type": "identifier", "text": "sp", "parent": 101, "children": [], "start_point": {"row": 48, "column": 40}, "end_point": {"row": 48, "column": 42}}, {"id": 103, "type": "<", "text": "<", "parent": 101, "children": [], "start_point": {"row": 48, "column": 42}, "end_point": {"row": 48, "column": 43}}, {"id": 104, "type": "identifier", "text": "AAudioServiceStreamBase", "parent": 101, "children": [], "start_point": {"row": 48, "column": 43}, "end_point": {"row": 48, "column": 66}}, {"id": 105, "type": ">", "text": ">", "parent": 101, "children": [], "start_point": {"row": 48, "column": 66}, "end_point": {"row": 48, "column": 67}}, {"id": 106, "type": "identifier", "text": "stream", "parent": 99, "children": [], "start_point": {"row": 48, "column": 68}, "end_point": {"row": 48, "column": 74}}, {"id": 107, "type": "parameter_declaration", "text": "audio_port_handle_t clientHandle", "parent": 98, "children": [108, 109], "start_point": {"row": 49, "column": 31}, "end_point": {"row": 49, "column": 63}}, {"id": 108, "type": "type_identifier", "text": "audio_port_handle_t", "parent": 107, "children": [], "start_point": {"row": 49, "column": 31}, "end_point": {"row": 49, "column": 50}}, {"id": 109, "type": "identifier", "text": "clientHandle", "parent": 107, "children": [], "start_point": {"row": 49, "column": 51}, "end_point": {"row": 49, "column": 63}}, {"id": 110, "type": "identifier", "text": "override", "parent": 96, "children": [], "start_point": {"row": 49, "column": 65}, "end_point": {"row": 49, "column": 73}}, {"id": 111, "type": "identifier", "text": "aaudio_result_t", "parent": 77, "children": [], "start_point": {"row": 51, "column": 4}, "end_point": {"row": 51, "column": 19}}, {"id": 112, "type": "function_declarator", "text": "getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override", "parent": 77, "children": [113, 114, 125], "start_point": {"row": 51, "column": 20}, "end_point": {"row": 51, "column": 96}}, {"id": 113, "type": "identifier", "text": "getFreeRunningPosition", "parent": 112, "children": [], "start_point": {"row": 51, "column": 20}, "end_point": {"row": 51, "column": 42}}, {"id": 114, "type": "parameter_list", "text": "(int64_t *positionFrames, int64_t *timeNanos)", "parent": 112, "children": [115, 120], "start_point": {"row": 51, "column": 42}, "end_point": {"row": 51, "column": 87}}, {"id": 115, "type": "parameter_declaration", "text": "int64_t *positionFrames", "parent": 114, "children": [116, 117], "start_point": {"row": 51, "column": 43}, "end_point": {"row": 51, "column": 66}}, {"id": 116, "type": "primitive_type", "text": "int64_t", "parent": 115, "children": [], "start_point": {"row": 51, "column": 43}, "end_point": {"row": 51, "column": 50}}, {"id": 117, "type": "pointer_declarator", "text": "*positionFrames", "parent": 115, "children": [118, 119], "start_point": {"row": 51, "column": 51}, "end_point": {"row": 51, "column": 66}}, {"id": 118, "type": "*", "text": "*", "parent": 117, "children": [], "start_point": {"row": 51, "column": 51}, "end_point": {"row": 51, "column": 52}}, {"id": 119, "type": "identifier", "text": "positionFrames", "parent": 117, "children": [], "start_point": {"row": 51, "column": 52}, "end_point": {"row": 51, "column": 66}}, {"id": 120, "type": "parameter_declaration", "text": "int64_t *timeNanos", "parent": 114, "children": [121, 122], "start_point": {"row": 51, "column": 68}, "end_point": {"row": 51, "column": 86}}, {"id": 121, "type": "primitive_type", "text": "int64_t", "parent": 120, "children": [], "start_point": {"row": 51, "column": 68}, "end_point": {"row": 51, "column": 75}}, {"id": 122, "type": "pointer_declarator", "text": "*timeNanos", "parent": 120, "children": [123, 124], "start_point": {"row": 51, "column": 76}, "end_point": {"row": 51, "column": 86}}, {"id": 123, "type": "*", "text": "*", "parent": 122, "children": [], "start_point": {"row": 51, "column": 76}, "end_point": {"row": 51, "column": 77}}, {"id": 124, "type": "identifier", "text": "timeNanos", "parent": 122, "children": [], "start_point": {"row": 51, "column": 77}, "end_point": {"row": 51, "column": 86}}, {"id": 125, "type": "identifier", "text": "override", "parent": 112, "children": [], "start_point": {"row": 51, "column": 88}, "end_point": {"row": 51, "column": 96}}, {"id": 126, "type": "identifier", "text": "aaudio_result_t", "parent": 77, "children": [], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 19}}, {"id": 127, "type": "function_declarator", "text": "getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override", "parent": 77, "children": [128, 129, 140], "start_point": {"row": 53, "column": 20}, "end_point": {"row": 53, "column": 86}}, {"id": 128, "type": "identifier", "text": "getTimestamp", "parent": 127, "children": [], "start_point": {"row": 53, "column": 20}, "end_point": {"row": 53, "column": 32}}, {"id": 129, "type": "parameter_list", "text": "(int64_t *positionFrames, int64_t *timeNanos)", "parent": 127, "children": [130, 135], "start_point": {"row": 53, "column": 32}, "end_point": {"row": 53, "column": 77}}, {"id": 130, "type": "parameter_declaration", "text": "int64_t *positionFrames", "parent": 129, "children": [131, 132], "start_point": {"row": 53, "column": 33}, "end_point": {"row": 53, "column": 56}}, {"id": 131, "type": "primitive_type", "text": "int64_t", "parent": 130, "children": [], "start_point": {"row": 53, "column": 33}, "end_point": {"row": 53, "column": 40}}, {"id": 132, "type": "pointer_declarator", "text": "*positionFrames", "parent": 130, "children": [133, 134], "start_point": {"row": 53, "column": 41}, "end_point": {"row": 53, "column": 56}}, {"id": 133, "type": "*", "text": "*", "parent": 132, "children": [], "start_point": {"row": 53, "column": 41}, "end_point": {"row": 53, "column": 42}}, {"id": 134, "type": "identifier", "text": "positionFrames", "parent": 132, "children": [], "start_point": {"row": 53, "column": 42}, "end_point": {"row": 53, "column": 56}}, {"id": 135, "type": "parameter_declaration", "text": "int64_t *timeNanos", "parent": 129, "children": [136, 137], "start_point": {"row": 53, "column": 58}, "end_point": {"row": 53, "column": 76}}, {"id": 136, "type": "primitive_type", "text": "int64_t", "parent": 135, "children": [], "start_point": {"row": 53, "column": 58}, "end_point": {"row": 53, "column": 65}}, {"id": 137, "type": "pointer_declarator", "text": "*timeNanos", "parent": 135, "children": [138, 139], "start_point": {"row": 53, "column": 66}, "end_point": {"row": 53, "column": 76}}, {"id": 138, "type": "*", "text": "*", "parent": 137, "children": [], "start_point": {"row": 53, "column": 66}, "end_point": {"row": 53, "column": 67}}, {"id": 139, "type": "identifier", "text": "timeNanos", "parent": 137, "children": [], "start_point": {"row": 53, "column": 67}, "end_point": {"row": 53, "column": 76}}, {"id": 140, "type": "identifier", "text": "override", "parent": 127, "children": [], "start_point": {"row": 53, "column": 78}, "end_point": {"row": 53, "column": 86}}, {"id": 141, "type": "identifier", "text": "virtual", "parent": 77, "children": [], "start_point": {"row": 55, "column": 4}, "end_point": {"row": 55, "column": 11}}, {"id": 142, "type": "identifier", "text": "void", "parent": 77, "children": [], "start_point": {"row": 55, "column": 12}, "end_point": {"row": 55, "column": 16}}, {"id": 143, "type": "init_declarator", "text": "*callbackLoop() = 0", "parent": 75, "children": [144, 149, 150], "start_point": {"row": 55, "column": 19}, "end_point": {"row": 55, "column": 38}}, {"id": 144, "type": "pointer_declarator", "text": "*callbackLoop()", "parent": 143, "children": [145, 146], "start_point": {"row": 55, "column": 19}, "end_point": {"row": 55, "column": 34}}, {"id": 145, "type": "*", "text": "*", "parent": 144, "children": [], "start_point": {"row": 55, "column": 19}, "end_point": {"row": 55, "column": 20}}, {"id": 146, "type": "function_declarator", "text": "callbackLoop()", "parent": 144, "children": [147, 148], "start_point": {"row": 55, "column": 20}, "end_point": {"row": 55, "column": 34}}, {"id": 147, "type": "identifier", "text": "callbackLoop", "parent": 146, "children": [], "start_point": {"row": 55, "column": 20}, "end_point": {"row": 55, "column": 32}}, {"id": 148, "type": "parameter_list", "text": "()", "parent": 146, "children": [], "start_point": {"row": 55, "column": 32}, "end_point": {"row": 55, "column": 34}}, {"id": 149, "type": "=", "text": "=", "parent": 143, "children": [], "start_point": {"row": 55, "column": 35}, "end_point": {"row": 55, "column": 36}}, {"id": 150, "type": "number_literal", "text": "0", "parent": 143, "children": [], "start_point": {"row": 55, "column": 37}, "end_point": {"row": 55, "column": 38}}, {"id": 151, "type": "declaration", "text": "protected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();", "parent": 67, "children": [152, 160], "start_point": {"row": 57, "column": 0}, "end_point": {"row": 60, "column": 37}}, {"id": 152, "type": "ERROR", "text": ":\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.", "parent": 151, "children": [153, 154, 159], "start_point": {"row": 57, "column": 9}, "end_point": {"row": 60, "column": 31}}, {"id": 153, "type": "identifier", "text": "AudioStreamInternal", "parent": 152, "children": [], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 23}}, {"id": 154, "type": "pointer_declarator", "text": "*getStreamInternal() const", "parent": 152, "children": [155, 156], "start_point": {"row": 59, "column": 24}, "end_point": {"row": 59, "column": 50}}, {"id": 155, "type": "*", "text": "*", "parent": 154, "children": [], "start_point": {"row": 59, "column": 24}, "end_point": {"row": 59, "column": 25}}, {"id": 156, "type": "function_declarator", "text": "getStreamInternal() const", "parent": 154, "children": [157, 158], "start_point": {"row": 59, "column": 25}, "end_point": {"row": 59, "column": 50}}, {"id": 157, "type": "identifier", "text": "getStreamInternal", "parent": 156, "children": [], "start_point": {"row": 59, "column": 25}, "end_point": {"row": 59, "column": 42}}, {"id": 158, "type": "parameter_list", "text": "()", "parent": 156, "children": [], "start_point": {"row": 59, "column": 42}, "end_point": {"row": 59, "column": 44}}, {"id": 159, "type": "identifier", "text": "mStreamInternal", "parent": 152, "children": [], "start_point": {"row": 60, "column": 15}, "end_point": {"row": 60, "column": 30}}, {"id": 160, "type": "function_declarator", "text": "get()", "parent": 151, "children": [161, 162], "start_point": {"row": 60, "column": 31}, "end_point": {"row": 60, "column": 36}}, {"id": 161, "type": "identifier", "text": "get", "parent": 160, "children": [], "start_point": {"row": 60, "column": 31}, "end_point": {"row": 60, "column": 34}}, {"id": 162, "type": "parameter_list", "text": "()", "parent": 160, "children": [], "start_point": {"row": 60, "column": 34}, "end_point": {"row": 60, "column": 36}}, {"id": 163, "type": "ERROR", "text": "};", "parent": 67, "children": [], "start_point": {"row": 61, "column": 4}, "end_point": {"row": 61, "column": 6}}, {"id": 164, "type": "declaration", "text": "aaudio_result_t startSharingThread_l();", "parent": 67, "children": [165, 166], "start_point": {"row": 63, "column": 4}, "end_point": {"row": 63, "column": 52}}, {"id": 165, "type": "type_identifier", "text": "aaudio_result_t", "parent": 164, "children": [], "start_point": {"row": 63, "column": 4}, "end_point": {"row": 63, "column": 19}}, {"id": 166, "type": "function_declarator", "text": "startSharingThread_l()", "parent": 164, "children": [167, 168], "start_point": {"row": 63, "column": 29}, "end_point": {"row": 63, "column": 51}}, {"id": 167, "type": "identifier", "text": "startSharingThread_l", "parent": 166, "children": [], "start_point": {"row": 63, "column": 29}, "end_point": {"row": 63, "column": 49}}, {"id": 168, "type": "parameter_list", "text": "()", "parent": 166, "children": [], "start_point": {"row": 63, "column": 49}, "end_point": {"row": 63, "column": 51}}, {"id": 169, "type": "declaration", "text": "aaudio_result_t stopSharingThread();", "parent": 67, "children": [170, 171], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 49}}, {"id": 170, "type": "type_identifier", "text": "aaudio_result_t", "parent": 169, "children": [], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 19}}, {"id": 171, "type": "function_declarator", "text": "stopSharingThread()", "parent": 169, "children": [172, 173], "start_point": {"row": 65, "column": 29}, "end_point": {"row": 65, "column": 48}}, {"id": 172, "type": "identifier", "text": "stopSharingThread", "parent": 171, "children": [], "start_point": {"row": 65, "column": 29}, "end_point": {"row": 65, "column": 46}}, {"id": 173, "type": "parameter_list", "text": "()", "parent": 171, "children": [], "start_point": {"row": 65, "column": 46}, "end_point": {"row": 65, "column": 48}}, {"id": 174, "type": "declaration", "text": "android::sp<AudioStreamInternal> mStreamInternal;", "parent": 67, "children": [175, 176, 181], "start_point": {"row": 68, "column": 4}, "end_point": {"row": 68, "column": 53}}, {"id": 175, "type": "type_identifier", "text": "android", "parent": 174, "children": [], "start_point": {"row": 68, "column": 4}, "end_point": {"row": 68, "column": 11}}, {"id": 176, "type": "ERROR", "text": "::sp<AudioStreamInternal>", "parent": 174, "children": [177, 178, 179, 180], "start_point": {"row": 68, "column": 11}, "end_point": {"row": 68, "column": 36}}, {"id": 177, "type": "identifier", "text": "sp", "parent": 176, "children": [], "start_point": {"row": 68, "column": 13}, "end_point": {"row": 68, "column": 15}}, {"id": 178, "type": "<", "text": "<", "parent": 176, "children": [], "start_point": {"row": 68, "column": 15}, "end_point": {"row": 68, "column": 16}}, {"id": 179, "type": "identifier", "text": "AudioStreamInternal", "parent": 176, "children": [], "start_point": {"row": 68, "column": 16}, "end_point": {"row": 68, "column": 35}}, {"id": 180, "type": ">", "text": ">", "parent": 176, "children": [], "start_point": {"row": 68, "column": 35}, "end_point": {"row": 68, "column": 36}}, {"id": 181, "type": "identifier", "text": "mStreamInternal", "parent": 174, "children": [], "start_point": {"row": 68, "column": 37}, "end_point": {"row": 68, "column": 52}}, {"id": 182, "type": "type_identifier", "text": "std", "parent": 67, "children": [], "start_point": {"row": 70, "column": 4}, "end_point": {"row": 70, "column": 7}}, {"id": 183, "type": "ERROR", "text": "::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int>", "parent": 67, "children": [184, 185, 186, 187, 188, 189, 190, 191, 192, 193, 194], "start_point": {"row": 70, "column": 7}, "end_point": {"row": 72, "column": 20}}, {"id": 184, "type": "identifier", "text": "atomic", "parent": 183, "children": [], "start_point": {"row": 70, "column": 9}, "end_point": {"row": 70, "column": 15}}, {"id": 185, "type": "<", "text": "<", "parent": 183, "children": [], "start_point": {"row": 70, "column": 15}, "end_point": {"row": 70, "column": 16}}, {"id": 186, "type": "primitive_type", "text": "bool", "parent": 183, "children": [], "start_point": {"row": 70, "column": 16}, "end_point": {"row": 70, "column": 20}}, {"id": 187, "type": ">", "text": ">", "parent": 183, "children": [], "start_point": {"row": 70, "column": 20}, "end_point": {"row": 70, "column": 21}}, {"id": 188, "type": "identifier", "text": "mCallbackEnabled", "parent": 183, "children": [], "start_point": {"row": 70, "column": 29}, "end_point": {"row": 70, "column": 45}}, {"id": 189, "type": "false", "text": "false", "parent": 183, "children": [], "start_point": {"row": 70, "column": 46}, "end_point": {"row": 70, "column": 51}}, {"id": 190, "type": "identifier", "text": "std", "parent": 183, "children": [], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 7}}, {"id": 191, "type": "identifier", "text": "atomic", "parent": 183, "children": [], "start_point": {"row": 72, "column": 9}, "end_point": {"row": 72, "column": 15}}, {"id": 192, "type": "<", "text": "<", "parent": 183, "children": [], "start_point": {"row": 72, "column": 15}, "end_point": {"row": 72, "column": 16}}, {"id": 193, "type": "primitive_type", "text": "int", "parent": 183, "children": [], "start_point": {"row": 72, "column": 16}, "end_point": {"row": 72, "column": 19}}, {"id": 194, "type": ">", "text": ">", "parent": 183, "children": [], "start_point": {"row": 72, "column": 19}, "end_point": {"row": 72, "column": 20}}, {"id": 195, "type": "identifier", "text": "mRunningStreamCount", "parent": 67, "children": [], "start_point": {"row": 72, "column": 29}, "end_point": {"row": 72, "column": 48}}, {"id": 196, "type": "number_literal", "text": "0", "parent": 67, "children": [], "start_point": {"row": 72, "column": 49}, "end_point": {"row": 72, "column": 50}}, {"id": 197, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 77, "column": 0}, "end_point": {"row": 77, "column": 6}}]}, "node_categories": {"declarations": {"functions": [30, 33, 40, 52, 58, 69, 78, 96, 112, 127, 146, 156, 160, 166, 171], "variables": [38, 43, 61, 72, 75, 81, 89, 99, 107, 115, 120, 130, 135, 151, 164, 169, 174], "classes": [], "imports": [6, 7, 9, 10, 12, 13, 15, 16, 18, 19, 21, 22, 24, 25, 27, 28], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 31, 32, 34, 36, 39, 41, 44, 47, 49, 51, 53, 55, 57, 59, 62, 64, 65, 66, 70, 73, 74, 76, 79, 82, 84, 86, 88, 90, 93, 94, 95, 97, 100, 102, 104, 106, 108, 109, 110, 111, 113, 119, 124, 125, 126, 128, 134, 139, 140, 141, 142, 147, 153, 157, 159, 161, 165, 167, 170, 172, 175, 177, 179, 181, 182, 184, 188, 190, 191, 195, 197], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [8, 11, 14, 17, 20, 23, 26, 29, 150, 196], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 30, "universal_type": "function", "name": "AAudioServiceEndpointShared", "text_snippet": "namespace aaudio {\n\n/**\n * This manages an AudioStreamInternal that is shared by multiple Client str"}, {"node_id": 33, "universal_type": "function", "name": "AAudioServiceEndpointShared", "text_snippet": "class AAudioServiceEndpointShared : public AAudioServiceEndpoint {\n\npublic:\n explicit AAudioServi"}, {"node_id": 40, "universal_type": "function", "name": "unknown", "text_snippet": "AAudioServiceEndpointShared(AudioStreamInternal *streamInternal)"}, {"node_id": 52, "universal_type": "function", "name": "unknown", "text_snippet": "dump() const override"}, {"node_id": 58, "universal_type": "function", "name": "unknown", "text_snippet": "open(const aaudio::AAudioStreamRequest &request) override"}, {"node_id": 69, "universal_type": "function", "name": "unknown", "text_snippet": "close()"}, {"node_id": 78, "universal_type": "function", "name": "unknown", "text_snippet": "startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_"}, {"node_id": 96, "universal_type": "function", "name": "unknown", "text_snippet": "stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_ha"}, {"node_id": 112, "universal_type": "function", "name": "unknown", "text_snippet": "getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override"}, {"node_id": 127, "universal_type": "function", "name": "unknown", "text_snippet": "getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override"}, {"node_id": 146, "universal_type": "function", "name": "unknown", "text_snippet": "callbackLoop()"}, {"node_id": 156, "universal_type": "function", "name": "unknown", "text_snippet": "getStreamInternal() const"}, {"node_id": 160, "universal_type": "function", "name": "unknown", "text_snippet": "get()"}, {"node_id": 166, "universal_type": "function", "name": "unknown", "text_snippet": "startSharingThread_l()"}, {"node_id": 171, "universal_type": "function", "name": "unknown", "text_snippet": "stopSharingThread()"}], "class_declarations": [], "import_statements": [{"node_id": 6, "text": "#include <atomic>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <mutex>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include \"AAudioServiceEndpoint.h\"\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include \"client/AudioStreamInternal.h\"\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include \"client/AudioStreamInternalPlay.h\"\n"}, {"node_id": 19, "text": "#include"}, {"node_id": 21, "text": "#include \"AAudioServiceStreamShared.h\"\n"}, {"node_id": 22, "text": "#include"}, {"node_id": 24, "text": "#include \"AAudioServiceStreamMMAP.h\"\n"}, {"node_id": 25, "text": "#include"}, {"node_id": 27, "text": "#include \"AAudioService.h\"\n"}, {"node_id": 28, "text": "#include"}]}, "original_source_code": "/*\n * Copyright (C) 2017 The Android Open Source Project\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n#ifndef AAUDIO_SERVICE_ENDPOINT_SHARED_H\n#define AAUDIO_SERVICE_ENDPOINT_SHARED_H\n\n#include <atomic>\n#include <mutex>\n\n#include \"AAudioServiceEndpoint.h\"\n#include \"client/AudioStreamInternal.h\"\n#include \"client/AudioStreamInternalPlay.h\"\n#include \"AAudioServiceStreamShared.h\"\n#include \"AAudioServiceStreamMMAP.h\"\n#include \"AAudioService.h\"\n\nnamespace aaudio {\n\n/**\n * This manages an AudioStreamInternal that is shared by multiple Client streams.\n */\nclass AAudioServiceEndpointShared : public AAudioServiceEndpoint {\n\npublic:\n explicit AAudioServiceEndpointShared(AudioStreamInternal *streamInternal);\n\n std::string dump() const override;\n\n aaudio_result_t open(const aaudio::AAudioStreamRequest &request) override;\n\n void close() override;\n\n aaudio_result_t startStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t *clientHandle) override;\n\n aaudio_result_t stopStream(android::sp<AAudioServiceStreamBase> stream,\n audio_port_handle_t clientHandle) override;\n\n aaudio_result_t getFreeRunningPosition(int64_t *positionFrames, int64_t *timeNanos) override;\n\n aaudio_result_t getTimestamp(int64_t *positionFrames, int64_t *timeNanos) override;\n\n virtual void *callbackLoop() = 0;\n\nprotected:\n\n AudioStreamInternal *getStreamInternal() const {\n return mStreamInternal.get();\n };\n\n aaudio_result_t startSharingThread_l();\n\n aaudio_result_t stopSharingThread();\n\n // An MMAP stream that is shared by multiple clients.\n android::sp<AudioStreamInternal> mStreamInternal;\n\n std::atomic<bool> mCallbackEnabled{false};\n\n std::atomic<int> mRunningStreamCount{0};\n};\n\n}\n\n#endif //AAUDIO_SERVICE_ENDPOINT_SHARED_H\n"}
80,512
c
// This file is part of BOINC. // http://boinc.berkeley.edu // Copyright (C) 2008 University of California // // BOINC is free software; you can redistribute it and/or modify it // under the terms of the GNU Lesser General Public License // as published by the Free Software Foundation, // either version 3 of the License, or (at your option) any later version. // // BOINC is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. // See the GNU Lesser General Public License for more details. // // You should have received a copy of the GNU Lesser General Public License // along with BOINC. If not, see <http://www.gnu.org/licenses/>. #ifndef _BOINC_DIAGNOSTICS_WIN_ #define _BOINC_DIAGNOSTICS_WIN_ #include "boinc_win.h" #define NT_SUCCESS(Status) ((NTSTATUS)(Status) >= 0) #define STATUS_INFO_LENGTH_MISMATCH ((NTSTATUS)0xC0000004L) #define SystemProcessAndThreadInformation 5 typedef LONG NTSTATUS; typedef LONG KPRIORITY; typedef struct _CLIENT_ID { DWORD UniqueProcess; DWORD UniqueThread; } CLIENT_ID; typedef struct _UNICODE_STRING { USHORT Length; USHORT MaximumLength; PWSTR Buffer; } UNICODE_STRING; typedef struct _VM_COUNTERS { #ifdef _WIN64 // the following was inferred by painful reverse engineering SIZE_T PeakVirtualSize; // not actually SIZE_T PageFaultCount; SIZE_T PeakWorkingSetSize; SIZE_T WorkingSetSize; SIZE_T QuotaPeakPagedPoolUsage; SIZE_T QuotaPagedPoolUsage; SIZE_T QuotaPeakNonPagedPoolUsage; SIZE_T QuotaNonPagedPoolUsage; SIZE_T PagefileUsage; SIZE_T PeakPagefileUsage; SIZE_T VirtualSize; // not actually #else SIZE_T PeakVirtualSize; SIZE_T VirtualSize; ULONG PageFaultCount; SIZE_T PeakWorkingSetSize; SIZE_T WorkingSetSize; SIZE_T QuotaPeakPagedPoolUsage; SIZE_T QuotaPagedPoolUsage; SIZE_T QuotaPeakNonPagedPoolUsage; SIZE_T QuotaNonPagedPoolUsage; SIZE_T PagefileUsage; SIZE_T PeakPagefileUsage; #endif } VM_COUNTERS; typedef struct _SYSTEM_THREADS { LARGE_INTEGER KernelTime; LARGE_INTEGER UserTime; LARGE_INTEGER CreateTime; ULONG WaitTime; PVOID StartAddress; CLIENT_ID ClientId; KPRIORITY Priority; KPRIORITY BasePriority; ULONG ContextSwitchCount; LONG State; LONG WaitReason; } SYSTEM_THREADS, * PSYSTEM_THREADS; typedef struct _SYSTEM_PROCESSES_NT4 { ULONG NextEntryDelta; ULONG ThreadCount; ULONG Reserved1[6]; LARGE_INTEGER CreateTime; LARGE_INTEGER UserTime; LARGE_INTEGER KernelTime; UNICODE_STRING ProcessName; KPRIORITY BasePriority; ULONG ProcessId; ULONG InheritedFromProcessId; ULONG HandleCount; ULONG Reserved2[2]; VM_COUNTERS VmCounters; SYSTEM_THREADS Threads[1]; } SYSTEM_PROCESSES_NT4, *PSYSTEM_PROCESSES_NT4; typedef struct _SYSTEM_PROCESSES { ULONG NextEntryDelta; ULONG ThreadCount; ULONG Reserved1[6]; LARGE_INTEGER CreateTime; LARGE_INTEGER UserTime; LARGE_INTEGER KernelTime; UNICODE_STRING ProcessName; KPRIORITY BasePriority; #ifdef _WIN64 ULONG pad1; ULONG ProcessId; ULONG pad2; ULONG InheritedFromProcessId; ULONG pad3, pad4, pad5; #else ULONG ProcessId; ULONG InheritedFromProcessId; #endif ULONG HandleCount; ULONG Reserved2[2]; VM_COUNTERS VmCounters; IO_COUNTERS IoCounters; SYSTEM_THREADS Threads[1]; } SYSTEM_PROCESSES, * PSYSTEM_PROCESSES; typedef enum _THREAD_STATE { ThreadStateInitialized, ThreadStateReady, ThreadStateRunning, ThreadStateStandby, ThreadStateTerminated, ThreadStateWaiting, ThreadStateTransition } THREAD_STATE, *PTHREAD_STATE; typedef enum _THREAD_WAIT_REASON { ThreadWaitReasonExecutive, ThreadWaitReasonFreePage, ThreadWaitReasonPageIn, ThreadWaitReasonPoolAllocation, ThreadWaitReasonDelayExecution, ThreadWaitReasonSuspended, ThreadWaitReasonUserRequest, ThreadWaitReasonWrExecutive, ThreadWaitReasonWrFreePage, ThreadWaitReasonWrPageIn, ThreadWaitReasonWrPoolAllocation, ThreadWaitReasonWrDelayExecution, ThreadWaitReasonWrSuspended, ThreadWaitReasonWrUserRequest, ThreadWaitReasonWrEventPairHigh, ThreadWaitReasonWrEventPairLow, ThreadWaitReasonWrLpcReceive, ThreadWaitReasonWrLpcReply, ThreadWaitReasonWrVirtualMemory, ThreadWaitReasonWrPageOut, ThreadWaitReasonMaximumWaitReason } THREAD_WAIT_REASON; // Delay Load Error Handling stuff #ifndef _DELAY_IMP_VER #define FACILITY_VISUALCPP ((LONG)0x6d) #define VcppException(sev,err) ((sev) | (FACILITY_VISUALCPP<<16) | err) typedef DWORD RVA; typedef struct ImgDelayDescr { DWORD grAttrs; // attributes RVA rvaDLLName; // RVA to dll name RVA rvaHmod; // RVA of module handle RVA rvaIAT; // RVA of the IAT RVA rvaINT; // RVA of the INT RVA rvaBoundIAT; // RVA of the optional bound IAT RVA rvaUnloadIAT; // RVA of optional copy of original IAT DWORD dwTimeStamp; // 0 if not bound, // O.W. date/time stamp of DLL bound to (Old BIND) } ImgDelayDescr, *PImgDelayDescr; typedef const ImgDelayDescr *PCImgDelayDescr; typedef struct DelayLoadProc { BOOL fImportByName; union { LPCSTR szProcName; DWORD dwOrdinal; }; } DelayLoadProc; typedef struct DelayLoadInfo { DWORD cb; // size of structure PCImgDelayDescr pidd; // raw form of data (everything is there) FARPROC * ppfn; // points to address of function to load LPCSTR szDll; // name of dll DelayLoadProc dlp; // name or ordinal of procedure HMODULE hmodCur; // the hInstance of the library we have loaded FARPROC pfnCur; // the actual function that will be called DWORD dwLastError;// error received (if an error notification) } DelayLoadInfo, * PDelayLoadInfo; #endif #endif
35.51
184
(translation_unit) "// This file is part of BOINC.\n// http://boinc.berkeley.edu\n// Copyright (C) 2008 University of California\n//\n// BOINC is free software; you can redistribute it and/or modify it\n// under the terms of the GNU Lesser General Public License\n// as published by the Free Software Foundation,\n// either version 3 of the License, or (at your option) any later version.\n//\n// BOINC is distributed in the hope that it will be useful,\n// but WITHOUT ANY WARRANTY; without even the implied warranty of\n// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n// See the GNU Lesser General Public License for more details.\n//\n// You should have received a copy of the GNU Lesser General Public License\n// along with BOINC. If not, see <http://www.gnu.org/licenses/>.\n\n#ifndef _BOINC_DIAGNOSTICS_WIN_\n#define _BOINC_DIAGNOSTICS_WIN_\n\n#include "boinc_win.h"\n\n#define NT_SUCCESS(Status) ((NTSTATUS)(Status) >= 0)\n#define STATUS_INFO_LENGTH_MISMATCH ((NTSTATUS)0xC0000004L)\n#define SystemProcessAndThreadInformation 5\n\ntypedef LONG NTSTATUS;\n\ntypedef LONG KPRIORITY;\n\ntypedef struct _CLIENT_ID {\n DWORD UniqueProcess;\n DWORD UniqueThread;\n} CLIENT_ID;\n\ntypedef struct _UNICODE_STRING {\n USHORT Length;\n USHORT MaximumLength;\n PWSTR Buffer;\n} UNICODE_STRING;\n\ntypedef struct _VM_COUNTERS {\n#ifdef _WIN64\n// the following was inferred by painful reverse engineering\n SIZE_T PeakVirtualSize; // not actually\n SIZE_T PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n SIZE_T VirtualSize; // not actually\n#else\n SIZE_T PeakVirtualSize;\n SIZE_T VirtualSize;\n ULONG PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n#endif\n} VM_COUNTERS;\n\ntypedef struct _SYSTEM_THREADS {\n LARGE_INTEGER KernelTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER CreateTime;\n ULONG WaitTime;\n PVOID StartAddress;\n CLIENT_ID ClientId;\n KPRIORITY Priority;\n KPRIORITY BasePriority;\n ULONG ContextSwitchCount;\n LONG State;\n LONG WaitReason;\n} SYSTEM_THREADS, * PSYSTEM_THREADS;\n\ntypedef struct _SYSTEM_PROCESSES_NT4 {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n SYSTEM_THREADS Threads[1];\n} SYSTEM_PROCESSES_NT4, *PSYSTEM_PROCESSES_NT4;\n\ntypedef struct _SYSTEM_PROCESSES {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n#ifdef _WIN64\n ULONG pad1;\n ULONG ProcessId;\n ULONG pad2;\n ULONG InheritedFromProcessId;\n ULONG pad3, pad4, pad5;\n#else\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n#endif\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n IO_COUNTERS IoCounters;\n SYSTEM_THREADS Threads[1];\n} SYSTEM_PROCESSES, * PSYSTEM_PROCESSES;\n\ntypedef enum _THREAD_STATE {\n ThreadStateInitialized,\n ThreadStateReady,\n ThreadStateRunning,\n ThreadStateStandby,\n ThreadStateTerminated,\n ThreadStateWaiting,\n ThreadStateTransition\n} THREAD_STATE, *PTHREAD_STATE;\n\ntypedef enum _THREAD_WAIT_REASON {\n ThreadWaitReasonExecutive,\n ThreadWaitReasonFreePage,\n ThreadWaitReasonPageIn,\n ThreadWaitReasonPoolAllocation,\n ThreadWaitReasonDelayExecution,\n ThreadWaitReasonSuspended,\n ThreadWaitReasonUserRequest,\n ThreadWaitReasonWrExecutive,\n ThreadWaitReasonWrFreePage,\n ThreadWaitReasonWrPageIn,\n ThreadWaitReasonWrPoolAllocation,\n ThreadWaitReasonWrDelayExecution,\n ThreadWaitReasonWrSuspended,\n ThreadWaitReasonWrUserRequest,\n ThreadWaitReasonWrEventPairHigh,\n ThreadWaitReasonWrEventPairLow,\n ThreadWaitReasonWrLpcReceive,\n ThreadWaitReasonWrLpcReply,\n ThreadWaitReasonWrVirtualMemory,\n ThreadWaitReasonWrPageOut,\n ThreadWaitReasonMaximumWaitReason\n} THREAD_WAIT_REASON;\n\n\n// Delay Load Error Handling stuff\n#ifndef _DELAY_IMP_VER\n\n#define FACILITY_VISUALCPP ((LONG)0x6d)\n#define VcppException(sev,err) ((sev) | (FACILITY_VISUALCPP<<16) | err)\n\ntypedef DWORD RVA;\n\ntypedef struct ImgDelayDescr {\n DWORD grAttrs; // attributes\n RVA rvaDLLName; // RVA to dll name\n RVA rvaHmod; // RVA of module handle\n RVA rvaIAT; // RVA of the IAT\n RVA rvaINT; // RVA of the INT\n RVA rvaBoundIAT; // RVA of the optional bound IAT\n RVA rvaUnloadIAT; // RVA of optional copy of original IAT\n DWORD dwTimeStamp; // 0 if not bound,\n // O.W. date/time stamp of DLL bound to (Old BIND)\n} ImgDelayDescr, *PImgDelayDescr;\n\ntypedef const ImgDelayDescr *PCImgDelayDescr;\n\ntypedef struct DelayLoadProc {\n BOOL fImportByName;\n union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n };\n} DelayLoadProc;\n\ntypedef struct DelayLoadInfo {\n DWORD cb; // size of structure\n PCImgDelayDescr pidd; // raw form of data (everything is there)\n FARPROC * ppfn; // points to address of function to load\n LPCSTR szDll; // name of dll\n DelayLoadProc dlp; // name or ordinal of procedure\n HMODULE hmodCur; // the hInstance of the library we have loaded\n FARPROC pfnCur; // the actual function that will be called\n DWORD dwLastError;// error received (if an error notification)\n} DelayLoadInfo, * PDelayLoadInfo;\n\n#endif\n\n#endif\n" (comment) "// This file is part of BOINC." (comment) "// http://boinc.berkeley.edu" (comment) "// Copyright (C) 2008 University of California" (comment) "//" (comment) "// BOINC is free software; you can redistribute it and/or modify it" (comment) "// under the terms of the GNU Lesser General Public License" (comment) "// as published by the Free Software Foundation," (comment) "// either version 3 of the License, or (at your option) any later version." (comment) "//" (comment) "// BOINC is distributed in the hope that it will be useful," (comment) "// but WITHOUT ANY WARRANTY; without even the implied warranty of" (comment) "// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." (comment) "// See the GNU Lesser General Public License for more details." (comment) "//" (comment) "// You should have received a copy of the GNU Lesser General Public License" (comment) "// along with BOINC. If not, see <http://www.gnu.org/licenses/>." (preproc_ifdef) "#ifndef _BOINC_DIAGNOSTICS_WIN_\n#define _BOINC_DIAGNOSTICS_WIN_\n\n#include "boinc_win.h"\n\n#define NT_SUCCESS(Status) ((NTSTATUS)(Status) >= 0)\n#define STATUS_INFO_LENGTH_MISMATCH ((NTSTATUS)0xC0000004L)\n#define SystemProcessAndThreadInformation 5\n\ntypedef LONG NTSTATUS;\n\ntypedef LONG KPRIORITY;\n\ntypedef struct _CLIENT_ID {\n DWORD UniqueProcess;\n DWORD UniqueThread;\n} CLIENT_ID;\n\ntypedef struct _UNICODE_STRING {\n USHORT Length;\n USHORT MaximumLength;\n PWSTR Buffer;\n} UNICODE_STRING;\n\ntypedef struct _VM_COUNTERS {\n#ifdef _WIN64\n// the following was inferred by painful reverse engineering\n SIZE_T PeakVirtualSize; // not actually\n SIZE_T PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n SIZE_T VirtualSize; // not actually\n#else\n SIZE_T PeakVirtualSize;\n SIZE_T VirtualSize;\n ULONG PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n#endif\n} VM_COUNTERS;\n\ntypedef struct _SYSTEM_THREADS {\n LARGE_INTEGER KernelTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER CreateTime;\n ULONG WaitTime;\n PVOID StartAddress;\n CLIENT_ID ClientId;\n KPRIORITY Priority;\n KPRIORITY BasePriority;\n ULONG ContextSwitchCount;\n LONG State;\n LONG WaitReason;\n} SYSTEM_THREADS, * PSYSTEM_THREADS;\n\ntypedef struct _SYSTEM_PROCESSES_NT4 {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n SYSTEM_THREADS Threads[1];\n} SYSTEM_PROCESSES_NT4, *PSYSTEM_PROCESSES_NT4;\n\ntypedef struct _SYSTEM_PROCESSES {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n#ifdef _WIN64\n ULONG pad1;\n ULONG ProcessId;\n ULONG pad2;\n ULONG InheritedFromProcessId;\n ULONG pad3, pad4, pad5;\n#else\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n#endif\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n IO_COUNTERS IoCounters;\n SYSTEM_THREADS Threads[1];\n} SYSTEM_PROCESSES, * PSYSTEM_PROCESSES;\n\ntypedef enum _THREAD_STATE {\n ThreadStateInitialized,\n ThreadStateReady,\n ThreadStateRunning,\n ThreadStateStandby,\n ThreadStateTerminated,\n ThreadStateWaiting,\n ThreadStateTransition\n} THREAD_STATE, *PTHREAD_STATE;\n\ntypedef enum _THREAD_WAIT_REASON {\n ThreadWaitReasonExecutive,\n ThreadWaitReasonFreePage,\n ThreadWaitReasonPageIn,\n ThreadWaitReasonPoolAllocation,\n ThreadWaitReasonDelayExecution,\n ThreadWaitReasonSuspended,\n ThreadWaitReasonUserRequest,\n ThreadWaitReasonWrExecutive,\n ThreadWaitReasonWrFreePage,\n ThreadWaitReasonWrPageIn,\n ThreadWaitReasonWrPoolAllocation,\n ThreadWaitReasonWrDelayExecution,\n ThreadWaitReasonWrSuspended,\n ThreadWaitReasonWrUserRequest,\n ThreadWaitReasonWrEventPairHigh,\n ThreadWaitReasonWrEventPairLow,\n ThreadWaitReasonWrLpcReceive,\n ThreadWaitReasonWrLpcReply,\n ThreadWaitReasonWrVirtualMemory,\n ThreadWaitReasonWrPageOut,\n ThreadWaitReasonMaximumWaitReason\n} THREAD_WAIT_REASON;\n\n\n// Delay Load Error Handling stuff\n#ifndef _DELAY_IMP_VER\n\n#define FACILITY_VISUALCPP ((LONG)0x6d)\n#define VcppException(sev,err) ((sev) | (FACILITY_VISUALCPP<<16) | err)\n\ntypedef DWORD RVA;\n\ntypedef struct ImgDelayDescr {\n DWORD grAttrs; // attributes\n RVA rvaDLLName; // RVA to dll name\n RVA rvaHmod; // RVA of module handle\n RVA rvaIAT; // RVA of the IAT\n RVA rvaINT; // RVA of the INT\n RVA rvaBoundIAT; // RVA of the optional bound IAT\n RVA rvaUnloadIAT; // RVA of optional copy of original IAT\n DWORD dwTimeStamp; // 0 if not bound,\n // O.W. date/time stamp of DLL bound to (Old BIND)\n} ImgDelayDescr, *PImgDelayDescr;\n\ntypedef const ImgDelayDescr *PCImgDelayDescr;\n\ntypedef struct DelayLoadProc {\n BOOL fImportByName;\n union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n };\n} DelayLoadProc;\n\ntypedef struct DelayLoadInfo {\n DWORD cb; // size of structure\n PCImgDelayDescr pidd; // raw form of data (everything is there)\n FARPROC * ppfn; // points to address of function to load\n LPCSTR szDll; // name of dll\n DelayLoadProc dlp; // name or ordinal of procedure\n HMODULE hmodCur; // the hInstance of the library we have loaded\n FARPROC pfnCur; // the actual function that will be called\n DWORD dwLastError;// error received (if an error notification)\n} DelayLoadInfo, * PDelayLoadInfo;\n\n#endif\n\n#endif" (#ifndef) "#ifndef" (identifier) "_BOINC_DIAGNOSTICS_WIN_" (preproc_def) "#define _BOINC_DIAGNOSTICS_WIN_\n" (#define) "#define" (identifier) "_BOINC_DIAGNOSTICS_WIN_" (preproc_include) "#include "boinc_win.h"\n" (#include) "#include" (string_literal) ""boinc_win.h"" (") """ (string_content) "boinc_win.h" (") """ (preproc_function_def) "#define NT_SUCCESS(Status) ((NTSTATUS)(Status) >= 0)\n" (#define) "#define" (identifier) "NT_SUCCESS" (preproc_params) "(Status)" (() "(" (identifier) "Status" ()) ")" (preproc_arg) "((NTSTATUS)(Status) >= 0)" (preproc_def) "#define STATUS_INFO_LENGTH_MISMATCH ((NTSTATUS)0xC0000004L)\n" (#define) "#define" (identifier) "STATUS_INFO_LENGTH_MISMATCH" (preproc_arg) "((NTSTATUS)0xC0000004L)" (preproc_def) "#define SystemProcessAndThreadInformation 5\n" (#define) "#define" (identifier) "SystemProcessAndThreadInformation" (preproc_arg) "5" (type_definition) "typedef LONG NTSTATUS;" (typedef) "typedef" (type_identifier) "LONG" (type_identifier) "NTSTATUS" (;) ";" (type_definition) "typedef LONG KPRIORITY;" (typedef) "typedef" (type_identifier) "LONG" (type_identifier) "KPRIORITY" (;) ";" (type_definition) "typedef struct _CLIENT_ID {\n DWORD UniqueProcess;\n DWORD UniqueThread;\n} CLIENT_ID;" (typedef) "typedef" (struct_specifier) "struct _CLIENT_ID {\n DWORD UniqueProcess;\n DWORD UniqueThread;\n}" (struct) "struct" (type_identifier) "_CLIENT_ID" (field_declaration_list) "{\n DWORD UniqueProcess;\n DWORD UniqueThread;\n}" ({) "{" (field_declaration) "DWORD UniqueProcess;" (type_identifier) "DWORD" (field_identifier) "UniqueProcess" (;) ";" (field_declaration) "DWORD UniqueThread;" (type_identifier) "DWORD" (field_identifier) "UniqueThread" (;) ";" (}) "}" (type_identifier) "CLIENT_ID" (;) ";" (type_definition) "typedef struct _UNICODE_STRING {\n USHORT Length;\n USHORT MaximumLength;\n PWSTR Buffer;\n} UNICODE_STRING;" (typedef) "typedef" (struct_specifier) "struct _UNICODE_STRING {\n USHORT Length;\n USHORT MaximumLength;\n PWSTR Buffer;\n}" (struct) "struct" (type_identifier) "_UNICODE_STRING" (field_declaration_list) "{\n USHORT Length;\n USHORT MaximumLength;\n PWSTR Buffer;\n}" ({) "{" (field_declaration) "USHORT Length;" (type_identifier) "USHORT" (field_identifier) "Length" (;) ";" (field_declaration) "USHORT MaximumLength;" (type_identifier) "USHORT" (field_identifier) "MaximumLength" (;) ";" (field_declaration) "PWSTR Buffer;" (type_identifier) "PWSTR" (field_identifier) "Buffer" (;) ";" (}) "}" (type_identifier) "UNICODE_STRING" (;) ";" (type_definition) "typedef struct _VM_COUNTERS {\n#ifdef _WIN64\n// the following was inferred by painful reverse engineering\n SIZE_T PeakVirtualSize; // not actually\n SIZE_T PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n SIZE_T VirtualSize; // not actually\n#else\n SIZE_T PeakVirtualSize;\n SIZE_T VirtualSize;\n ULONG PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n#endif\n} VM_COUNTERS;" (typedef) "typedef" (struct_specifier) "struct _VM_COUNTERS {\n#ifdef _WIN64\n// the following was inferred by painful reverse engineering\n SIZE_T PeakVirtualSize; // not actually\n SIZE_T PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n SIZE_T VirtualSize; // not actually\n#else\n SIZE_T PeakVirtualSize;\n SIZE_T VirtualSize;\n ULONG PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n#endif\n}" (struct) "struct" (type_identifier) "_VM_COUNTERS" (field_declaration_list) "{\n#ifdef _WIN64\n// the following was inferred by painful reverse engineering\n SIZE_T PeakVirtualSize; // not actually\n SIZE_T PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n SIZE_T VirtualSize; // not actually\n#else\n SIZE_T PeakVirtualSize;\n SIZE_T VirtualSize;\n ULONG PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n#endif\n}" ({) "{" (preproc_ifdef) "#ifdef _WIN64\n// the following was inferred by painful reverse engineering\n SIZE_T PeakVirtualSize; // not actually\n SIZE_T PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n SIZE_T VirtualSize; // not actually\n#else\n SIZE_T PeakVirtualSize;\n SIZE_T VirtualSize;\n ULONG PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n#endif" (#ifdef) "#ifdef" (identifier) "_WIN64" (comment) "// the following was inferred by painful reverse engineering" (field_declaration) "SIZE_T PeakVirtualSize;" (type_identifier) "SIZE_T" (field_identifier) "PeakVirtualSize" (;) ";" (comment) "// not actually" (field_declaration) "SIZE_T PageFaultCount;" (type_identifier) "SIZE_T" (field_identifier) "PageFaultCount" (;) ";" (field_declaration) "SIZE_T PeakWorkingSetSize;" (type_identifier) "SIZE_T" (field_identifier) "PeakWorkingSetSize" (;) ";" (field_declaration) "SIZE_T WorkingSetSize;" (type_identifier) "SIZE_T" (field_identifier) "WorkingSetSize" (;) ";" (field_declaration) "SIZE_T QuotaPeakPagedPoolUsage;" (type_identifier) "SIZE_T" (field_identifier) "QuotaPeakPagedPoolUsage" (;) ";" (field_declaration) "SIZE_T QuotaPagedPoolUsage;" (type_identifier) "SIZE_T" (field_identifier) "QuotaPagedPoolUsage" (;) ";" (field_declaration) "SIZE_T QuotaPeakNonPagedPoolUsage;" (type_identifier) "SIZE_T" (field_identifier) "QuotaPeakNonPagedPoolUsage" (;) ";" (field_declaration) "SIZE_T QuotaNonPagedPoolUsage;" (type_identifier) "SIZE_T" (field_identifier) "QuotaNonPagedPoolUsage" (;) ";" (field_declaration) "SIZE_T PagefileUsage;" (type_identifier) "SIZE_T" (field_identifier) "PagefileUsage" (;) ";" (field_declaration) "SIZE_T PeakPagefileUsage;" (type_identifier) "SIZE_T" (field_identifier) "PeakPagefileUsage" (;) ";" (field_declaration) "SIZE_T VirtualSize;" (type_identifier) "SIZE_T" (field_identifier) "VirtualSize" (;) ";" (comment) "// not actually" (preproc_else) "#else\n SIZE_T PeakVirtualSize;\n SIZE_T VirtualSize;\n ULONG PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;" (#else) "#else" (field_declaration) "SIZE_T PeakVirtualSize;" (type_identifier) "SIZE_T" (field_identifier) "PeakVirtualSize" (;) ";" (field_declaration) "SIZE_T VirtualSize;" (type_identifier) "SIZE_T" (field_identifier) "VirtualSize" (;) ";" (field_declaration) "ULONG PageFaultCount;" (type_identifier) "ULONG" (field_identifier) "PageFaultCount" (;) ";" (field_declaration) "SIZE_T PeakWorkingSetSize;" (type_identifier) "SIZE_T" (field_identifier) "PeakWorkingSetSize" (;) ";" (field_declaration) "SIZE_T WorkingSetSize;" (type_identifier) "SIZE_T" (field_identifier) "WorkingSetSize" (;) ";" (field_declaration) "SIZE_T QuotaPeakPagedPoolUsage;" (type_identifier) "SIZE_T" (field_identifier) "QuotaPeakPagedPoolUsage" (;) ";" (field_declaration) "SIZE_T QuotaPagedPoolUsage;" (type_identifier) "SIZE_T" (field_identifier) "QuotaPagedPoolUsage" (;) ";" (field_declaration) "SIZE_T QuotaPeakNonPagedPoolUsage;" (type_identifier) "SIZE_T" (field_identifier) "QuotaPeakNonPagedPoolUsage" (;) ";" (field_declaration) "SIZE_T QuotaNonPagedPoolUsage;" (type_identifier) "SIZE_T" (field_identifier) "QuotaNonPagedPoolUsage" (;) ";" (field_declaration) "SIZE_T PagefileUsage;" (type_identifier) "SIZE_T" (field_identifier) "PagefileUsage" (;) ";" (field_declaration) "SIZE_T PeakPagefileUsage;" (type_identifier) "SIZE_T" (field_identifier) "PeakPagefileUsage" (;) ";" (#endif) "#endif" (}) "}" (type_identifier) "VM_COUNTERS" (;) ";" (type_definition) "typedef struct _SYSTEM_THREADS {\n LARGE_INTEGER KernelTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER CreateTime;\n ULONG WaitTime;\n PVOID StartAddress;\n CLIENT_ID ClientId;\n KPRIORITY Priority;\n KPRIORITY BasePriority;\n ULONG ContextSwitchCount;\n LONG State;\n LONG WaitReason;\n} SYSTEM_THREADS, * PSYSTEM_THREADS;" (typedef) "typedef" (struct_specifier) "struct _SYSTEM_THREADS {\n LARGE_INTEGER KernelTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER CreateTime;\n ULONG WaitTime;\n PVOID StartAddress;\n CLIENT_ID ClientId;\n KPRIORITY Priority;\n KPRIORITY BasePriority;\n ULONG ContextSwitchCount;\n LONG State;\n LONG WaitReason;\n}" (struct) "struct" (type_identifier) "_SYSTEM_THREADS" (field_declaration_list) "{\n LARGE_INTEGER KernelTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER CreateTime;\n ULONG WaitTime;\n PVOID StartAddress;\n CLIENT_ID ClientId;\n KPRIORITY Priority;\n KPRIORITY BasePriority;\n ULONG ContextSwitchCount;\n LONG State;\n LONG WaitReason;\n}" ({) "{" (field_declaration) "LARGE_INTEGER KernelTime;" (type_identifier) "LARGE_INTEGER" (field_identifier) "KernelTime" (;) ";" (field_declaration) "LARGE_INTEGER UserTime;" (type_identifier) "LARGE_INTEGER" (field_identifier) "UserTime" (;) ";" (field_declaration) "LARGE_INTEGER CreateTime;" (type_identifier) "LARGE_INTEGER" (field_identifier) "CreateTime" (;) ";" (field_declaration) "ULONG WaitTime;" (type_identifier) "ULONG" (field_identifier) "WaitTime" (;) ";" (field_declaration) "PVOID StartAddress;" (type_identifier) "PVOID" (field_identifier) "StartAddress" (;) ";" (field_declaration) "CLIENT_ID ClientId;" (type_identifier) "CLIENT_ID" (field_identifier) "ClientId" (;) ";" (field_declaration) "KPRIORITY Priority;" (type_identifier) "KPRIORITY" (field_identifier) "Priority" (;) ";" (field_declaration) "KPRIORITY BasePriority;" (type_identifier) "KPRIORITY" (field_identifier) "BasePriority" (;) ";" (field_declaration) "ULONG ContextSwitchCount;" (type_identifier) "ULONG" (field_identifier) "ContextSwitchCount" (;) ";" (field_declaration) "LONG State;" (type_identifier) "LONG" (field_identifier) "State" (;) ";" (field_declaration) "LONG WaitReason;" (type_identifier) "LONG" (field_identifier) "WaitReason" (;) ";" (}) "}" (type_identifier) "SYSTEM_THREADS" (,) "," (pointer_declarator) "* PSYSTEM_THREADS" (*) "*" (type_identifier) "PSYSTEM_THREADS" (;) ";" (type_definition) "typedef struct _SYSTEM_PROCESSES_NT4 {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n SYSTEM_THREADS Threads[1];\n} SYSTEM_PROCESSES_NT4, *PSYSTEM_PROCESSES_NT4;" (typedef) "typedef" (struct_specifier) "struct _SYSTEM_PROCESSES_NT4 {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n SYSTEM_THREADS Threads[1];\n}" (struct) "struct" (type_identifier) "_SYSTEM_PROCESSES_NT4" (field_declaration_list) "{\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n SYSTEM_THREADS Threads[1];\n}" ({) "{" (field_declaration) "ULONG NextEntryDelta;" (type_identifier) "ULONG" (field_identifier) "NextEntryDelta" (;) ";" (field_declaration) "ULONG ThreadCount;" (type_identifier) "ULONG" (field_identifier) "ThreadCount" (;) ";" (field_declaration) "ULONG Reserved1[6];" (type_identifier) "ULONG" (array_declarator) "Reserved1[6]" (field_identifier) "Reserved1" ([) "[" (number_literal) "6" (]) "]" (;) ";" (field_declaration) "LARGE_INTEGER CreateTime;" (type_identifier) "LARGE_INTEGER" (field_identifier) "CreateTime" (;) ";" (field_declaration) "LARGE_INTEGER UserTime;" (type_identifier) "LARGE_INTEGER" (field_identifier) "UserTime" (;) ";" (field_declaration) "LARGE_INTEGER KernelTime;" (type_identifier) "LARGE_INTEGER" (field_identifier) "KernelTime" (;) ";" (field_declaration) "UNICODE_STRING ProcessName;" (type_identifier) "UNICODE_STRING" (field_identifier) "ProcessName" (;) ";" (field_declaration) "KPRIORITY BasePriority;" (type_identifier) "KPRIORITY" (field_identifier) "BasePriority" (;) ";" (field_declaration) "ULONG ProcessId;" (type_identifier) "ULONG" (field_identifier) "ProcessId" (;) ";" (field_declaration) "ULONG InheritedFromProcessId;" (type_identifier) "ULONG" (field_identifier) "InheritedFromProcessId" (;) ";" (field_declaration) "ULONG HandleCount;" (type_identifier) "ULONG" (field_identifier) "HandleCount" (;) ";" (field_declaration) "ULONG Reserved2[2];" (type_identifier) "ULONG" (array_declarator) "Reserved2[2]" (field_identifier) "Reserved2" ([) "[" (number_literal) "2" (]) "]" (;) ";" (field_declaration) "VM_COUNTERS VmCounters;" (type_identifier) "VM_COUNTERS" (field_identifier) "VmCounters" (;) ";" (field_declaration) "SYSTEM_THREADS Threads[1];" (type_identifier) "SYSTEM_THREADS" (array_declarator) "Threads[1]" (field_identifier) "Threads" ([) "[" (number_literal) "1" (]) "]" (;) ";" (}) "}" (type_identifier) "SYSTEM_PROCESSES_NT4" (,) "," (pointer_declarator) "*PSYSTEM_PROCESSES_NT4" (*) "*" (type_identifier) "PSYSTEM_PROCESSES_NT4" (;) ";" (type_definition) "typedef struct _SYSTEM_PROCESSES {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n#ifdef _WIN64\n ULONG pad1;\n ULONG ProcessId;\n ULONG pad2;\n ULONG InheritedFromProcessId;\n ULONG pad3, pad4, pad5;\n#else\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n#endif\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n IO_COUNTERS IoCounters;\n SYSTEM_THREADS Threads[1];\n} SYSTEM_PROCESSES, * PSYSTEM_PROCESSES;" (typedef) "typedef" (struct_specifier) "struct _SYSTEM_PROCESSES {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n#ifdef _WIN64\n ULONG pad1;\n ULONG ProcessId;\n ULONG pad2;\n ULONG InheritedFromProcessId;\n ULONG pad3, pad4, pad5;\n#else\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n#endif\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n IO_COUNTERS IoCounters;\n SYSTEM_THREADS Threads[1];\n}" (struct) "struct" (type_identifier) "_SYSTEM_PROCESSES" (field_declaration_list) "{\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n#ifdef _WIN64\n ULONG pad1;\n ULONG ProcessId;\n ULONG pad2;\n ULONG InheritedFromProcessId;\n ULONG pad3, pad4, pad5;\n#else\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n#endif\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n IO_COUNTERS IoCounters;\n SYSTEM_THREADS Threads[1];\n}" ({) "{" (field_declaration) "ULONG NextEntryDelta;" (type_identifier) "ULONG" (field_identifier) "NextEntryDelta" (;) ";" (field_declaration) "ULONG ThreadCount;" (type_identifier) "ULONG" (field_identifier) "ThreadCount" (;) ";" (field_declaration) "ULONG Reserved1[6];" (type_identifier) "ULONG" (array_declarator) "Reserved1[6]" (field_identifier) "Reserved1" ([) "[" (number_literal) "6" (]) "]" (;) ";" (field_declaration) "LARGE_INTEGER CreateTime;" (type_identifier) "LARGE_INTEGER" (field_identifier) "CreateTime" (;) ";" (field_declaration) "LARGE_INTEGER UserTime;" (type_identifier) "LARGE_INTEGER" (field_identifier) "UserTime" (;) ";" (field_declaration) "LARGE_INTEGER KernelTime;" (type_identifier) "LARGE_INTEGER" (field_identifier) "KernelTime" (;) ";" (field_declaration) "UNICODE_STRING ProcessName;" (type_identifier) "UNICODE_STRING" (field_identifier) "ProcessName" (;) ";" (field_declaration) "KPRIORITY BasePriority;" (type_identifier) "KPRIORITY" (field_identifier) "BasePriority" (;) ";" (preproc_ifdef) "#ifdef _WIN64\n ULONG pad1;\n ULONG ProcessId;\n ULONG pad2;\n ULONG InheritedFromProcessId;\n ULONG pad3, pad4, pad5;\n#else\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n#endif" (#ifdef) "#ifdef" (identifier) "_WIN64" (field_declaration) "ULONG pad1;" (type_identifier) "ULONG" (field_identifier) "pad1" (;) ";" (field_declaration) "ULONG ProcessId;" (type_identifier) "ULONG" (field_identifier) "ProcessId" (;) ";" (field_declaration) "ULONG pad2;" (type_identifier) "ULONG" (field_identifier) "pad2" (;) ";" (field_declaration) "ULONG InheritedFromProcessId;" (type_identifier) "ULONG" (field_identifier) "InheritedFromProcessId" (;) ";" (field_declaration) "ULONG pad3, pad4, pad5;" (type_identifier) "ULONG" (field_identifier) "pad3" (,) "," (field_identifier) "pad4" (,) "," (field_identifier) "pad5" (;) ";" (preproc_else) "#else\n ULONG ProcessId;\n ULONG InheritedFromProcessId;" (#else) "#else" (field_declaration) "ULONG ProcessId;" (type_identifier) "ULONG" (field_identifier) "ProcessId" (;) ";" (field_declaration) "ULONG InheritedFromProcessId;" (type_identifier) "ULONG" (field_identifier) "InheritedFromProcessId" (;) ";" (#endif) "#endif" (field_declaration) "ULONG HandleCount;" (type_identifier) "ULONG" (field_identifier) "HandleCount" (;) ";" (field_declaration) "ULONG Reserved2[2];" (type_identifier) "ULONG" (array_declarator) "Reserved2[2]" (field_identifier) "Reserved2" ([) "[" (number_literal) "2" (]) "]" (;) ";" (field_declaration) "VM_COUNTERS VmCounters;" (type_identifier) "VM_COUNTERS" (field_identifier) "VmCounters" (;) ";" (field_declaration) "IO_COUNTERS IoCounters;" (type_identifier) "IO_COUNTERS" (field_identifier) "IoCounters" (;) ";" (field_declaration) "SYSTEM_THREADS Threads[1];" (type_identifier) "SYSTEM_THREADS" (array_declarator) "Threads[1]" (field_identifier) "Threads" ([) "[" (number_literal) "1" (]) "]" (;) ";" (}) "}" (type_identifier) "SYSTEM_PROCESSES" (,) "," (pointer_declarator) "* PSYSTEM_PROCESSES" (*) "*" (type_identifier) "PSYSTEM_PROCESSES" (;) ";" (type_definition) "typedef enum _THREAD_STATE {\n ThreadStateInitialized,\n ThreadStateReady,\n ThreadStateRunning,\n ThreadStateStandby,\n ThreadStateTerminated,\n ThreadStateWaiting,\n ThreadStateTransition\n} THREAD_STATE, *PTHREAD_STATE;" (typedef) "typedef" (enum_specifier) "enum _THREAD_STATE {\n ThreadStateInitialized,\n ThreadStateReady,\n ThreadStateRunning,\n ThreadStateStandby,\n ThreadStateTerminated,\n ThreadStateWaiting,\n ThreadStateTransition\n}" (enum) "enum" (type_identifier) "_THREAD_STATE" (enumerator_list) "{\n ThreadStateInitialized,\n ThreadStateReady,\n ThreadStateRunning,\n ThreadStateStandby,\n ThreadStateTerminated,\n ThreadStateWaiting,\n ThreadStateTransition\n}" ({) "{" (enumerator) "ThreadStateInitialized" (identifier) "ThreadStateInitialized" (,) "," (enumerator) "ThreadStateReady" (identifier) "ThreadStateReady" (,) "," (enumerator) "ThreadStateRunning" (identifier) "ThreadStateRunning" (,) "," (enumerator) "ThreadStateStandby" (identifier) "ThreadStateStandby" (,) "," (enumerator) "ThreadStateTerminated" (identifier) "ThreadStateTerminated" (,) "," (enumerator) "ThreadStateWaiting" (identifier) "ThreadStateWaiting" (,) "," (enumerator) "ThreadStateTransition" (identifier) "ThreadStateTransition" (}) "}" (type_identifier) "THREAD_STATE" (,) "," (pointer_declarator) "*PTHREAD_STATE" (*) "*" (type_identifier) "PTHREAD_STATE" (;) ";" (type_definition) "typedef enum _THREAD_WAIT_REASON {\n ThreadWaitReasonExecutive,\n ThreadWaitReasonFreePage,\n ThreadWaitReasonPageIn,\n ThreadWaitReasonPoolAllocation,\n ThreadWaitReasonDelayExecution,\n ThreadWaitReasonSuspended,\n ThreadWaitReasonUserRequest,\n ThreadWaitReasonWrExecutive,\n ThreadWaitReasonWrFreePage,\n ThreadWaitReasonWrPageIn,\n ThreadWaitReasonWrPoolAllocation,\n ThreadWaitReasonWrDelayExecution,\n ThreadWaitReasonWrSuspended,\n ThreadWaitReasonWrUserRequest,\n ThreadWaitReasonWrEventPairHigh,\n ThreadWaitReasonWrEventPairLow,\n ThreadWaitReasonWrLpcReceive,\n ThreadWaitReasonWrLpcReply,\n ThreadWaitReasonWrVirtualMemory,\n ThreadWaitReasonWrPageOut,\n ThreadWaitReasonMaximumWaitReason\n} THREAD_WAIT_REASON;" (typedef) "typedef" (enum_specifier) "enum _THREAD_WAIT_REASON {\n ThreadWaitReasonExecutive,\n ThreadWaitReasonFreePage,\n ThreadWaitReasonPageIn,\n ThreadWaitReasonPoolAllocation,\n ThreadWaitReasonDelayExecution,\n ThreadWaitReasonSuspended,\n ThreadWaitReasonUserRequest,\n ThreadWaitReasonWrExecutive,\n ThreadWaitReasonWrFreePage,\n ThreadWaitReasonWrPageIn,\n ThreadWaitReasonWrPoolAllocation,\n ThreadWaitReasonWrDelayExecution,\n ThreadWaitReasonWrSuspended,\n ThreadWaitReasonWrUserRequest,\n ThreadWaitReasonWrEventPairHigh,\n ThreadWaitReasonWrEventPairLow,\n ThreadWaitReasonWrLpcReceive,\n ThreadWaitReasonWrLpcReply,\n ThreadWaitReasonWrVirtualMemory,\n ThreadWaitReasonWrPageOut,\n ThreadWaitReasonMaximumWaitReason\n}" (enum) "enum" (type_identifier) "_THREAD_WAIT_REASON" (enumerator_list) "{\n ThreadWaitReasonExecutive,\n ThreadWaitReasonFreePage,\n ThreadWaitReasonPageIn,\n ThreadWaitReasonPoolAllocation,\n ThreadWaitReasonDelayExecution,\n ThreadWaitReasonSuspended,\n ThreadWaitReasonUserRequest,\n ThreadWaitReasonWrExecutive,\n ThreadWaitReasonWrFreePage,\n ThreadWaitReasonWrPageIn,\n ThreadWaitReasonWrPoolAllocation,\n ThreadWaitReasonWrDelayExecution,\n ThreadWaitReasonWrSuspended,\n ThreadWaitReasonWrUserRequest,\n ThreadWaitReasonWrEventPairHigh,\n ThreadWaitReasonWrEventPairLow,\n ThreadWaitReasonWrLpcReceive,\n ThreadWaitReasonWrLpcReply,\n ThreadWaitReasonWrVirtualMemory,\n ThreadWaitReasonWrPageOut,\n ThreadWaitReasonMaximumWaitReason\n}" ({) "{" (enumerator) "ThreadWaitReasonExecutive" (identifier) "ThreadWaitReasonExecutive" (,) "," (enumerator) "ThreadWaitReasonFreePage" (identifier) "ThreadWaitReasonFreePage" (,) "," (enumerator) "ThreadWaitReasonPageIn" (identifier) "ThreadWaitReasonPageIn" (,) "," (enumerator) "ThreadWaitReasonPoolAllocation" (identifier) "ThreadWaitReasonPoolAllocation" (,) "," (enumerator) "ThreadWaitReasonDelayExecution" (identifier) "ThreadWaitReasonDelayExecution" (,) "," (enumerator) "ThreadWaitReasonSuspended" (identifier) "ThreadWaitReasonSuspended" (,) "," (enumerator) "ThreadWaitReasonUserRequest" (identifier) "ThreadWaitReasonUserRequest" (,) "," (enumerator) "ThreadWaitReasonWrExecutive" (identifier) "ThreadWaitReasonWrExecutive" (,) "," (enumerator) "ThreadWaitReasonWrFreePage" (identifier) "ThreadWaitReasonWrFreePage" (,) "," (enumerator) "ThreadWaitReasonWrPageIn" (identifier) "ThreadWaitReasonWrPageIn" (,) "," (enumerator) "ThreadWaitReasonWrPoolAllocation" (identifier) "ThreadWaitReasonWrPoolAllocation" (,) "," (enumerator) "ThreadWaitReasonWrDelayExecution" (identifier) "ThreadWaitReasonWrDelayExecution" (,) "," (enumerator) "ThreadWaitReasonWrSuspended" (identifier) "ThreadWaitReasonWrSuspended" (,) "," (enumerator) "ThreadWaitReasonWrUserRequest" (identifier) "ThreadWaitReasonWrUserRequest" (,) "," (enumerator) "ThreadWaitReasonWrEventPairHigh" (identifier) "ThreadWaitReasonWrEventPairHigh" (,) "," (enumerator) "ThreadWaitReasonWrEventPairLow" (identifier) "ThreadWaitReasonWrEventPairLow" (,) "," (enumerator) "ThreadWaitReasonWrLpcReceive" (identifier) "ThreadWaitReasonWrLpcReceive" (,) "," (enumerator) "ThreadWaitReasonWrLpcReply" (identifier) "ThreadWaitReasonWrLpcReply" (,) "," (enumerator) "ThreadWaitReasonWrVirtualMemory" (identifier) "ThreadWaitReasonWrVirtualMemory" (,) "," (enumerator) "ThreadWaitReasonWrPageOut" (identifier) "ThreadWaitReasonWrPageOut" (,) "," (enumerator) "ThreadWaitReasonMaximumWaitReason" (identifier) "ThreadWaitReasonMaximumWaitReason" (}) "}" (type_identifier) "THREAD_WAIT_REASON" (;) ";" (comment) "// Delay Load Error Handling stuff" (preproc_ifdef) "#ifndef _DELAY_IMP_VER\n\n#define FACILITY_VISUALCPP ((LONG)0x6d)\n#define VcppException(sev,err) ((sev) | (FACILITY_VISUALCPP<<16) | err)\n\ntypedef DWORD RVA;\n\ntypedef struct ImgDelayDescr {\n DWORD grAttrs; // attributes\n RVA rvaDLLName; // RVA to dll name\n RVA rvaHmod; // RVA of module handle\n RVA rvaIAT; // RVA of the IAT\n RVA rvaINT; // RVA of the INT\n RVA rvaBoundIAT; // RVA of the optional bound IAT\n RVA rvaUnloadIAT; // RVA of optional copy of original IAT\n DWORD dwTimeStamp; // 0 if not bound,\n // O.W. date/time stamp of DLL bound to (Old BIND)\n} ImgDelayDescr, *PImgDelayDescr;\n\ntypedef const ImgDelayDescr *PCImgDelayDescr;\n\ntypedef struct DelayLoadProc {\n BOOL fImportByName;\n union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n };\n} DelayLoadProc;\n\ntypedef struct DelayLoadInfo {\n DWORD cb; // size of structure\n PCImgDelayDescr pidd; // raw form of data (everything is there)\n FARPROC * ppfn; // points to address of function to load\n LPCSTR szDll; // name of dll\n DelayLoadProc dlp; // name or ordinal of procedure\n HMODULE hmodCur; // the hInstance of the library we have loaded\n FARPROC pfnCur; // the actual function that will be called\n DWORD dwLastError;// error received (if an error notification)\n} DelayLoadInfo, * PDelayLoadInfo;\n\n#endif" (#ifndef) "#ifndef" (identifier) "_DELAY_IMP_VER" (preproc_def) "#define FACILITY_VISUALCPP ((LONG)0x6d)\n" (#define) "#define" (identifier) "FACILITY_VISUALCPP" (preproc_arg) "((LONG)0x6d)" (preproc_function_def) "#define VcppException(sev,err) ((sev) | (FACILITY_VISUALCPP<<16) | err)\n" (#define) "#define" (identifier) "VcppException" (preproc_params) "(sev,err)" (() "(" (identifier) "sev" (,) "," (identifier) "err" ()) ")" (preproc_arg) "((sev) | (FACILITY_VISUALCPP<<16) | err)" (type_definition) "typedef DWORD RVA;" (typedef) "typedef" (type_identifier) "DWORD" (type_identifier) "RVA" (;) ";" (type_definition) "typedef struct ImgDelayDescr {\n DWORD grAttrs; // attributes\n RVA rvaDLLName; // RVA to dll name\n RVA rvaHmod; // RVA of module handle\n RVA rvaIAT; // RVA of the IAT\n RVA rvaINT; // RVA of the INT\n RVA rvaBoundIAT; // RVA of the optional bound IAT\n RVA rvaUnloadIAT; // RVA of optional copy of original IAT\n DWORD dwTimeStamp; // 0 if not bound,\n // O.W. date/time stamp of DLL bound to (Old BIND)\n} ImgDelayDescr, *PImgDelayDescr;" (typedef) "typedef" (struct_specifier) "struct ImgDelayDescr {\n DWORD grAttrs; // attributes\n RVA rvaDLLName; // RVA to dll name\n RVA rvaHmod; // RVA of module handle\n RVA rvaIAT; // RVA of the IAT\n RVA rvaINT; // RVA of the INT\n RVA rvaBoundIAT; // RVA of the optional bound IAT\n RVA rvaUnloadIAT; // RVA of optional copy of original IAT\n DWORD dwTimeStamp; // 0 if not bound,\n // O.W. date/time stamp of DLL bound to (Old BIND)\n}" (struct) "struct" (type_identifier) "ImgDelayDescr" (field_declaration_list) "{\n DWORD grAttrs; // attributes\n RVA rvaDLLName; // RVA to dll name\n RVA rvaHmod; // RVA of module handle\n RVA rvaIAT; // RVA of the IAT\n RVA rvaINT; // RVA of the INT\n RVA rvaBoundIAT; // RVA of the optional bound IAT\n RVA rvaUnloadIAT; // RVA of optional copy of original IAT\n DWORD dwTimeStamp; // 0 if not bound,\n // O.W. date/time stamp of DLL bound to (Old BIND)\n}" ({) "{" (field_declaration) "DWORD grAttrs;" (type_identifier) "DWORD" (field_identifier) "grAttrs" (;) ";" (comment) "// attributes" (field_declaration) "RVA rvaDLLName;" (type_identifier) "RVA" (field_identifier) "rvaDLLName" (;) ";" (comment) "// RVA to dll name" (field_declaration) "RVA rvaHmod;" (type_identifier) "RVA" (field_identifier) "rvaHmod" (;) ";" (comment) "// RVA of module handle" (field_declaration) "RVA rvaIAT;" (type_identifier) "RVA" (field_identifier) "rvaIAT" (;) ";" (comment) "// RVA of the IAT" (field_declaration) "RVA rvaINT;" (type_identifier) "RVA" (field_identifier) "rvaINT" (;) ";" (comment) "// RVA of the INT" (field_declaration) "RVA rvaBoundIAT;" (type_identifier) "RVA" (field_identifier) "rvaBoundIAT" (;) ";" (comment) "// RVA of the optional bound IAT" (field_declaration) "RVA rvaUnloadIAT;" (type_identifier) "RVA" (field_identifier) "rvaUnloadIAT" (;) ";" (comment) "// RVA of optional copy of original IAT" (field_declaration) "DWORD dwTimeStamp;" (type_identifier) "DWORD" (field_identifier) "dwTimeStamp" (;) ";" (comment) "// 0 if not bound," (comment) "// O.W. date/time stamp of DLL bound to (Old BIND)" (}) "}" (type_identifier) "ImgDelayDescr" (,) "," (pointer_declarator) "*PImgDelayDescr" (*) "*" (type_identifier) "PImgDelayDescr" (;) ";" (type_definition) "typedef const ImgDelayDescr *PCImgDelayDescr;" (typedef) "typedef" (type_qualifier) "const" (const) "const" (type_identifier) "ImgDelayDescr" (pointer_declarator) "*PCImgDelayDescr" (*) "*" (type_identifier) "PCImgDelayDescr" (;) ";" (type_definition) "typedef struct DelayLoadProc {\n BOOL fImportByName;\n union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n };\n} DelayLoadProc;" (typedef) "typedef" (struct_specifier) "struct DelayLoadProc {\n BOOL fImportByName;\n union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n };\n}" (struct) "struct" (type_identifier) "DelayLoadProc" (field_declaration_list) "{\n BOOL fImportByName;\n union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n };\n}" ({) "{" (field_declaration) "BOOL fImportByName;" (type_identifier) "BOOL" (field_identifier) "fImportByName" (;) ";" (field_declaration) "union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n };" (union_specifier) "union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n }" (union) "union" (field_declaration_list) "{\n LPCSTR szProcName;\n DWORD dwOrdinal;\n }" ({) "{" (field_declaration) "LPCSTR szProcName;" (type_identifier) "LPCSTR" (field_identifier) "szProcName" (;) ";" (field_declaration) "DWORD dwOrdinal;" (type_identifier) "DWORD" (field_identifier) "dwOrdinal" (;) ";" (}) "}" (;) ";" (}) "}" (type_identifier) "DelayLoadProc" (;) ";" (type_definition) "typedef struct DelayLoadInfo {\n DWORD cb; // size of structure\n PCImgDelayDescr pidd; // raw form of data (everything is there)\n FARPROC * ppfn; // points to address of function to load\n LPCSTR szDll; // name of dll\n DelayLoadProc dlp; // name or ordinal of procedure\n HMODULE hmodCur; // the hInstance of the library we have loaded\n FARPROC pfnCur; // the actual function that will be called\n DWORD dwLastError;// error received (if an error notification)\n} DelayLoadInfo, * PDelayLoadInfo;" (typedef) "typedef" (struct_specifier) "struct DelayLoadInfo {\n DWORD cb; // size of structure\n PCImgDelayDescr pidd; // raw form of data (everything is there)\n FARPROC * ppfn; // points to address of function to load\n LPCSTR szDll; // name of dll\n DelayLoadProc dlp; // name or ordinal of procedure\n HMODULE hmodCur; // the hInstance of the library we have loaded\n FARPROC pfnCur; // the actual function that will be called\n DWORD dwLastError;// error received (if an error notification)\n}" (struct) "struct" (type_identifier) "DelayLoadInfo" (field_declaration_list) "{\n DWORD cb; // size of structure\n PCImgDelayDescr pidd; // raw form of data (everything is there)\n FARPROC * ppfn; // points to address of function to load\n LPCSTR szDll; // name of dll\n DelayLoadProc dlp; // name or ordinal of procedure\n HMODULE hmodCur; // the hInstance of the library we have loaded\n FARPROC pfnCur; // the actual function that will be called\n DWORD dwLastError;// error received (if an error notification)\n}" ({) "{" (field_declaration) "DWORD cb;" (type_identifier) "DWORD" (field_identifier) "cb" (;) ";" (comment) "// size of structure" (field_declaration) "PCImgDelayDescr pidd;" (type_identifier) "PCImgDelayDescr" (field_identifier) "pidd" (;) ";" (comment) "// raw form of data (everything is there)" (field_declaration) "FARPROC * ppfn;" (type_identifier) "FARPROC" (pointer_declarator) "* ppfn" (*) "*" (field_identifier) "ppfn" (;) ";" (comment) "// points to address of function to load" (field_declaration) "LPCSTR szDll;" (type_identifier) "LPCSTR" (field_identifier) "szDll" (;) ";" (comment) "// name of dll" (field_declaration) "DelayLoadProc dlp;" (type_identifier) "DelayLoadProc" (field_identifier) "dlp" (;) ";" (comment) "// name or ordinal of procedure" (field_declaration) "HMODULE hmodCur;" (type_identifier) "HMODULE" (field_identifier) "hmodCur" (;) ";" (comment) "// the hInstance of the library we have loaded" (field_declaration) "FARPROC pfnCur;" (type_identifier) "FARPROC" (field_identifier) "pfnCur" (;) ";" (comment) "// the actual function that will be called" (field_declaration) "DWORD dwLastError;" (type_identifier) "DWORD" (field_identifier) "dwLastError" (;) ";" (comment) "// error received (if an error notification)" (}) "}" (type_identifier) "DelayLoadInfo" (,) "," (pointer_declarator) "* PDelayLoadInfo" (*) "*" (type_identifier) "PDelayLoadInfo" (;) ";" (#endif) "#endif" (#endif) "#endif"
738
0
{"language": "c", "success": true, "metadata": {"lines": 184, "avg_line_length": 35.51, "nodes": 503, "errors": 0, "source_hash": "04f21d7e90f48b6a2a777ada9ab5e7e5566a320b66f998c1320e17f8b7eb3016", "categorized_nodes": 445}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef _BOINC_DIAGNOSTICS_WIN_\n#define _BOINC_DIAGNOSTICS_WIN_\n\n#include \"boinc_win.h\"\n\n#define NT_SUCCESS(Status) ((NTSTATUS)(Status) >= 0)\n#define STATUS_INFO_LENGTH_MISMATCH ((NTSTATUS)0xC0000004L)\n#define SystemProcessAndThreadInformation 5\n\ntypedef LONG NTSTATUS;\n\ntypedef LONG KPRIORITY;\n\ntypedef struct _CLIENT_ID {\n DWORD UniqueProcess;\n DWORD UniqueThread;\n} CLIENT_ID;\n\ntypedef struct _UNICODE_STRING {\n USHORT Length;\n USHORT MaximumLength;\n PWSTR Buffer;\n} UNICODE_STRING;\n\ntypedef struct _VM_COUNTERS {\n#ifdef _WIN64\n// the following was inferred by painful reverse engineering\n\tSIZE_T\t\t PeakVirtualSize;\t// not actually\n SIZE_T PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n SIZE_T VirtualSize;\t\t// not actually\n#else\n SIZE_T PeakVirtualSize;\n SIZE_T VirtualSize;\n ULONG PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n#endif\n} VM_COUNTERS;\n\ntypedef struct _SYSTEM_THREADS {\n LARGE_INTEGER KernelTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER CreateTime;\n ULONG WaitTime;\n PVOID StartAddress;\n CLIENT_ID ClientId;\n KPRIORITY Priority;\n KPRIORITY BasePriority;\n ULONG ContextSwitchCount;\n LONG State;\n LONG WaitReason;\n} SYSTEM_THREADS, * PSYSTEM_THREADS;\n\ntypedef struct _SYSTEM_PROCESSES_NT4 {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n SYSTEM_THREADS Threads[1];\n} SYSTEM_PROCESSES_NT4, *PSYSTEM_PROCESSES_NT4;\n\ntypedef struct _SYSTEM_PROCESSES {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n#ifdef _WIN64\n\tULONG pad1;\n ULONG ProcessId;\n\tULONG pad2;\n ULONG InheritedFromProcessId;\n\tULONG pad3, pad4, pad5;\n#else\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n#endif\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n IO_COUNTERS IoCounters;\n SYSTEM_THREADS Threads[1];\n} SYSTEM_PROCESSES, * PSYSTEM_PROCESSES;\n\ntypedef enum _THREAD_STATE {\n ThreadStateInitialized,\n ThreadStateReady,\n ThreadStateRunning,\n ThreadStateStandby,\n ThreadStateTerminated,\n ThreadStateWaiting,\n ThreadStateTransition\n} THREAD_STATE, *PTHREAD_STATE;\n\ntypedef enum _THREAD_WAIT_REASON {\n ThreadWaitReasonExecutive,\n ThreadWaitReasonFreePage,\n ThreadWaitReasonPageIn,\n ThreadWaitReasonPoolAllocation,\n ThreadWaitReasonDelayExecution,\n ThreadWaitReasonSuspended,\n ThreadWaitReasonUserRequest,\n ThreadWaitReasonWrExecutive,\n ThreadWaitReasonWrFreePage,\n ThreadWaitReasonWrPageIn,\n ThreadWaitReasonWrPoolAllocation,\n ThreadWaitReasonWrDelayExecution,\n ThreadWaitReasonWrSuspended,\n ThreadWaitReasonWrUserRequest,\n ThreadWaitReasonWrEventPairHigh,\n ThreadWaitReasonWrEventPairLow,\n ThreadWaitReasonWrLpcReceive,\n ThreadWaitReasonWrLpcReply,\n ThreadWaitReasonWrVirtualMemory,\n ThreadWaitReasonWrPageOut,\n ThreadWaitReasonMaximumWaitReason\n} THREAD_WAIT_REASON;\n\n\n// Delay Load Error Handling stuff\n#ifndef _DELAY_IMP_VER\n\n#define FACILITY_VISUALCPP ((LONG)0x6d)\n#define VcppException(sev,err) ((sev) | (FACILITY_VISUALCPP<<16) | err)\n\ntypedef DWORD RVA;\n\ntypedef struct ImgDelayDescr {\n DWORD grAttrs; // attributes\n RVA rvaDLLName; // RVA to dll name\n RVA rvaHmod; // RVA of module handle\n RVA rvaIAT; // RVA of the IAT\n RVA rvaINT; // RVA of the INT\n RVA rvaBoundIAT; // RVA of the optional bound IAT\n RVA rvaUnloadIAT; // RVA of optional copy of original IAT\n DWORD dwTimeStamp; // 0 if not bound,\n // O.W. date/time stamp of DLL bound to (Old BIND)\n} ImgDelayDescr, *PImgDelayDescr;\n\ntypedef const ImgDelayDescr *PCImgDelayDescr;\n\ntypedef struct DelayLoadProc {\n BOOL fImportByName;\n union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n };\n} DelayLoadProc;\n\ntypedef struct DelayLoadInfo {\n DWORD cb; // size of structure\n PCImgDelayDescr pidd; // raw form of data (everything is there)\n FARPROC * ppfn; // points to address of function to load\n LPCSTR szDll; // name of dll\n DelayLoadProc dlp; // name or ordinal of procedure\n HMODULE hmodCur; // the hInstance of the library we have loaded\n FARPROC pfnCur; // the actual function that will be called\n DWORD dwLastError;// error received (if an error notification)\n} DelayLoadInfo, * PDelayLoadInfo;\n\n#endif\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 15, 19, 23, 27, 31, 43, 58, 136, 178, 235, 318, 342, 391, 502], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 205, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 7}}, {"id": 2, "type": "identifier", "text": "_BOINC_DIAGNOSTICS_WIN_", "parent": 0, "children": [], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 17, "column": 31}}, {"id": 3, "type": "preproc_def", "text": "#define _BOINC_DIAGNOSTICS_WIN_\n", "parent": 0, "children": [4, 5], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 19, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 7}}, {"id": 5, "type": "identifier", "text": "_BOINC_DIAGNOSTICS_WIN_", "parent": 3, "children": [], "start_point": {"row": 18, "column": 8}, "end_point": {"row": 18, "column": 31}}, {"id": 6, "type": "preproc_include", "text": "#include \"boinc_win.h\"\n", "parent": 0, "children": [7, 8], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 21, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"boinc_win.h\"", "parent": 6, "children": [], "start_point": {"row": 20, "column": 9}, "end_point": {"row": 20, "column": 22}}, {"id": 9, "type": "preproc_function_def", "text": "#define NT_SUCCESS(Status) ((NTSTATUS)(Status) >= 0)\n", "parent": 0, "children": [10, 11, 12, 14], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 23, "column": 0}}, {"id": 10, "type": "#define", "text": "#define", "parent": 9, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 7}}, {"id": 11, "type": "identifier", "text": "NT_SUCCESS", "parent": 9, "children": [], "start_point": {"row": 22, "column": 8}, "end_point": {"row": 22, "column": 18}}, {"id": 12, "type": "preproc_params", "text": "(Status)", "parent": 9, "children": [13], "start_point": {"row": 22, "column": 18}, "end_point": {"row": 22, "column": 26}}, {"id": 13, "type": "identifier", "text": "Status", "parent": 12, "children": [], "start_point": {"row": 22, "column": 19}, "end_point": {"row": 22, "column": 25}}, {"id": 14, "type": "preproc_arg", "text": "((NTSTATUS)(Status) >= 0)", "parent": 9, "children": [], "start_point": {"row": 22, "column": 48}, "end_point": {"row": 22, "column": 73}}, {"id": 15, "type": "preproc_def", "text": "#define STATUS_INFO_LENGTH_MISMATCH ((NTSTATUS)0xC0000004L)\n", "parent": 0, "children": [16, 17, 18], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 24, "column": 0}}, {"id": 16, "type": "#define", "text": "#define", "parent": 15, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 7}}, {"id": 17, "type": "identifier", "text": "STATUS_INFO_LENGTH_MISMATCH", "parent": 15, "children": [], "start_point": {"row": 23, "column": 8}, "end_point": {"row": 23, "column": 35}}, {"id": 18, "type": "preproc_arg", "text": "((NTSTATUS)0xC0000004L)", "parent": 15, "children": [], "start_point": {"row": 23, "column": 48}, "end_point": {"row": 23, "column": 71}}, {"id": 19, "type": "preproc_def", "text": "#define SystemProcessAndThreadInformation 5\n", "parent": 0, "children": [20, 21, 22], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 25, "column": 0}}, {"id": 20, "type": "#define", "text": "#define", "parent": 19, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 7}}, {"id": 21, "type": "identifier", "text": "SystemProcessAndThreadInformation", "parent": 19, "children": [], "start_point": {"row": 24, "column": 8}, "end_point": {"row": 24, "column": 41}}, {"id": 22, "type": "preproc_arg", "text": "5", "parent": 19, "children": [], "start_point": {"row": 24, "column": 48}, "end_point": {"row": 24, "column": 49}}, {"id": 23, "type": "type_definition", "text": "typedef LONG NTSTATUS;", "parent": 0, "children": [24, 25, 26], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 28}}, {"id": 24, "type": "typedef", "text": "typedef", "parent": 23, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 7}}, {"id": 25, "type": "type_identifier", "text": "LONG", "parent": 23, "children": [], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 12}}, {"id": 26, "type": "type_identifier", "text": "NTSTATUS", "parent": 23, "children": [], "start_point": {"row": 26, "column": 19}, "end_point": {"row": 26, "column": 27}}, {"id": 27, "type": "type_definition", "text": "typedef LONG KPRIORITY;", "parent": 0, "children": [28, 29, 30], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 29}}, {"id": 28, "type": "typedef", "text": "typedef", "parent": 27, "children": [], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 7}}, {"id": 29, "type": "type_identifier", "text": "LONG", "parent": 27, "children": [], "start_point": {"row": 28, "column": 8}, "end_point": {"row": 28, "column": 12}}, {"id": 30, "type": "type_identifier", "text": "KPRIORITY", "parent": 27, "children": [], "start_point": {"row": 28, "column": 19}, "end_point": {"row": 28, "column": 28}}, {"id": 31, "type": "type_definition", "text": "typedef struct _CLIENT_ID {\n DWORD UniqueProcess;\n DWORD UniqueThread;\n} CLIENT_ID;", "parent": 0, "children": [32, 33, 42], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 33, "column": 12}}, {"id": 32, "type": "typedef", "text": "typedef", "parent": 31, "children": [], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 7}}, {"id": 33, "type": "struct_specifier", "text": "struct _CLIENT_ID {\n DWORD UniqueProcess;\n DWORD UniqueThread;\n}", "parent": 31, "children": [34, 35], "start_point": {"row": 30, "column": 8}, "end_point": {"row": 33, "column": 1}}, {"id": 34, "type": "struct", "text": "struct", "parent": 33, "children": [], "start_point": {"row": 30, "column": 8}, "end_point": {"row": 30, "column": 14}}, {"id": 35, "type": "type_identifier", "text": "_CLIENT_ID", "parent": 33, "children": [], "start_point": {"row": 30, "column": 15}, "end_point": {"row": 30, "column": 25}}, {"id": 36, "type": "field_declaration", "text": "DWORD UniqueProcess;", "parent": 33, "children": [37, 38], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 33}}, {"id": 37, "type": "type_identifier", "text": "DWORD", "parent": 36, "children": [], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 9}}, {"id": 38, "type": "field_identifier", "text": "UniqueProcess", "parent": 36, "children": [], "start_point": {"row": 31, "column": 19}, "end_point": {"row": 31, "column": 32}}, {"id": 39, "type": "field_declaration", "text": "DWORD UniqueThread;", "parent": 33, "children": [40, 41], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 32, "column": 32}}, {"id": 40, "type": "type_identifier", "text": "DWORD", "parent": 39, "children": [], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 32, "column": 9}}, {"id": 41, "type": "field_identifier", "text": "UniqueThread", "parent": 39, "children": [], "start_point": {"row": 32, "column": 19}, "end_point": {"row": 32, "column": 31}}, {"id": 42, "type": "type_identifier", "text": "CLIENT_ID", "parent": 31, "children": [], "start_point": {"row": 33, "column": 2}, "end_point": {"row": 33, "column": 11}}, {"id": 43, "type": "type_definition", "text": "typedef struct _UNICODE_STRING {\n USHORT Length;\n USHORT MaximumLength;\n PWSTR Buffer;\n} UNICODE_STRING;", "parent": 0, "children": [44, 45, 57], "start_point": {"row": 35, "column": 0}, "end_point": {"row": 39, "column": 17}}, {"id": 44, "type": "typedef", "text": "typedef", "parent": 43, "children": [], "start_point": {"row": 35, "column": 0}, "end_point": {"row": 35, "column": 7}}, {"id": 45, "type": "struct_specifier", "text": "struct _UNICODE_STRING {\n USHORT Length;\n USHORT MaximumLength;\n PWSTR Buffer;\n}", "parent": 43, "children": [46, 47], "start_point": {"row": 35, "column": 8}, "end_point": {"row": 39, "column": 1}}, {"id": 46, "type": "struct", "text": "struct", "parent": 45, "children": [], "start_point": {"row": 35, "column": 8}, "end_point": {"row": 35, "column": 14}}, {"id": 47, "type": "type_identifier", "text": "_UNICODE_STRING", "parent": 45, "children": [], "start_point": {"row": 35, "column": 15}, "end_point": {"row": 35, "column": 30}}, {"id": 48, "type": "field_declaration", "text": "USHORT Length;", "parent": 45, "children": [49, 50], "start_point": {"row": 36, "column": 4}, "end_point": {"row": 36, "column": 26}}, {"id": 49, "type": "type_identifier", "text": "USHORT", "parent": 48, "children": [], "start_point": {"row": 36, "column": 4}, "end_point": {"row": 36, "column": 10}}, {"id": 50, "type": "field_identifier", "text": "Length", "parent": 48, "children": [], "start_point": {"row": 36, "column": 19}, "end_point": {"row": 36, "column": 25}}, {"id": 51, "type": "field_declaration", "text": "USHORT MaximumLength;", "parent": 45, "children": [52, 53], "start_point": {"row": 37, "column": 4}, "end_point": {"row": 37, "column": 33}}, {"id": 52, "type": "type_identifier", "text": "USHORT", "parent": 51, "children": [], "start_point": {"row": 37, "column": 4}, "end_point": {"row": 37, "column": 10}}, {"id": 53, "type": "field_identifier", "text": "MaximumLength", "parent": 51, "children": [], "start_point": {"row": 37, "column": 19}, "end_point": {"row": 37, "column": 32}}, {"id": 54, "type": "field_declaration", "text": "PWSTR Buffer;", "parent": 45, "children": [55, 56], "start_point": {"row": 38, "column": 4}, "end_point": {"row": 38, "column": 26}}, {"id": 55, "type": "type_identifier", "text": "PWSTR", "parent": 54, "children": [], "start_point": {"row": 38, "column": 4}, "end_point": {"row": 38, "column": 9}}, {"id": 56, "type": "field_identifier", "text": "Buffer", "parent": 54, "children": [], "start_point": {"row": 38, "column": 19}, "end_point": {"row": 38, "column": 25}}, {"id": 57, "type": "type_identifier", "text": "UNICODE_STRING", "parent": 43, "children": [], "start_point": {"row": 39, "column": 2}, "end_point": {"row": 39, "column": 16}}, {"id": 58, "type": "type_definition", "text": "typedef struct _VM_COUNTERS {\n#ifdef _WIN64\n// the following was inferred by painful reverse engineering\n\tSIZE_T\t\t PeakVirtualSize;\t// not actually\n SIZE_T PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n SIZE_T VirtualSize;\t\t// not actually\n#else\n SIZE_T PeakVirtualSize;\n SIZE_T VirtualSize;\n ULONG PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n#endif\n} VM_COUNTERS;", "parent": 0, "children": [59, 60, 135], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 68, "column": 14}}, {"id": 59, "type": "typedef", "text": "typedef", "parent": 58, "children": [], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 41, "column": 7}}, {"id": 60, "type": "struct_specifier", "text": "struct _VM_COUNTERS {\n#ifdef _WIN64\n// the following was inferred by painful reverse engineering\n\tSIZE_T\t\t PeakVirtualSize;\t// not actually\n SIZE_T PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n SIZE_T VirtualSize;\t\t// not actually\n#else\n SIZE_T PeakVirtualSize;\n SIZE_T VirtualSize;\n ULONG PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n#endif\n}", "parent": 58, "children": [61, 62], "start_point": {"row": 41, "column": 8}, "end_point": {"row": 68, "column": 1}}, {"id": 61, "type": "struct", "text": "struct", "parent": 60, "children": [], "start_point": {"row": 41, "column": 8}, "end_point": {"row": 41, "column": 14}}, {"id": 62, "type": "type_identifier", "text": "_VM_COUNTERS", "parent": 60, "children": [], "start_point": {"row": 41, "column": 15}, "end_point": {"row": 41, "column": 27}}, {"id": 63, "type": "preproc_ifdef", "text": "#ifdef _WIN64\n// the following was inferred by painful reverse engineering\n\tSIZE_T\t\t PeakVirtualSize;\t// not actually\n SIZE_T PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n SIZE_T VirtualSize;\t\t// not actually\n#else\n SIZE_T PeakVirtualSize;\n SIZE_T VirtualSize;\n ULONG PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n#endif", "parent": 60, "children": [64, 65, 66, 69, 72, 75, 78, 81, 84, 87, 90, 93, 96, 99, 134], "start_point": {"row": 42, "column": 0}, "end_point": {"row": 67, "column": 6}}, {"id": 64, "type": "#ifdef", "text": "#ifdef", "parent": 63, "children": [], "start_point": {"row": 42, "column": 0}, "end_point": {"row": 42, "column": 6}}, {"id": 65, "type": "identifier", "text": "_WIN64", "parent": 63, "children": [], "start_point": {"row": 42, "column": 7}, "end_point": {"row": 42, "column": 13}}, {"id": 66, "type": "field_declaration", "text": "SIZE_T\t\t PeakVirtualSize;", "parent": 63, "children": [67, 68], "start_point": {"row": 44, "column": 1}, "end_point": {"row": 44, "column": 28}}, {"id": 67, "type": "type_identifier", "text": "SIZE_T", "parent": 66, "children": [], "start_point": {"row": 44, "column": 1}, "end_point": {"row": 44, "column": 7}}, {"id": 68, "type": "field_identifier", "text": "PeakVirtualSize", "parent": 66, "children": [], "start_point": {"row": 44, "column": 12}, "end_point": {"row": 44, "column": 27}}, {"id": 69, "type": "field_declaration", "text": "SIZE_T PageFaultCount;", "parent": 63, "children": [70, 71], "start_point": {"row": 45, "column": 4}, "end_point": {"row": 45, "column": 34}}, {"id": 70, "type": "type_identifier", "text": "SIZE_T", "parent": 69, "children": [], "start_point": {"row": 45, "column": 4}, "end_point": {"row": 45, "column": 10}}, {"id": 71, "type": "field_identifier", "text": "PageFaultCount", "parent": 69, "children": [], "start_point": {"row": 45, "column": 19}, "end_point": {"row": 45, "column": 33}}, {"id": 72, "type": "field_declaration", "text": "SIZE_T PeakWorkingSetSize;", "parent": 63, "children": [73, 74], "start_point": {"row": 46, "column": 4}, "end_point": {"row": 46, "column": 38}}, {"id": 73, "type": "type_identifier", "text": "SIZE_T", "parent": 72, "children": [], "start_point": {"row": 46, "column": 4}, "end_point": {"row": 46, "column": 10}}, {"id": 74, "type": "field_identifier", "text": "PeakWorkingSetSize", "parent": 72, "children": [], "start_point": {"row": 46, "column": 19}, "end_point": {"row": 46, "column": 37}}, {"id": 75, "type": "field_declaration", "text": "SIZE_T WorkingSetSize;", "parent": 63, "children": [76, 77], "start_point": {"row": 47, "column": 4}, "end_point": {"row": 47, "column": 34}}, {"id": 76, "type": "type_identifier", "text": "SIZE_T", "parent": 75, "children": [], "start_point": {"row": 47, "column": 4}, "end_point": {"row": 47, "column": 10}}, {"id": 77, "type": "field_identifier", "text": "WorkingSetSize", "parent": 75, "children": [], "start_point": {"row": 47, "column": 19}, "end_point": {"row": 47, "column": 33}}, {"id": 78, "type": "field_declaration", "text": "SIZE_T QuotaPeakPagedPoolUsage;", "parent": 63, "children": [79, 80], "start_point": {"row": 48, "column": 4}, "end_point": {"row": 48, "column": 43}}, {"id": 79, "type": "type_identifier", "text": "SIZE_T", "parent": 78, "children": [], "start_point": {"row": 48, "column": 4}, "end_point": {"row": 48, "column": 10}}, {"id": 80, "type": "field_identifier", "text": "QuotaPeakPagedPoolUsage", "parent": 78, "children": [], "start_point": {"row": 48, "column": 19}, "end_point": {"row": 48, "column": 42}}, {"id": 81, "type": "field_declaration", "text": "SIZE_T QuotaPagedPoolUsage;", "parent": 63, "children": [82, 83], "start_point": {"row": 49, "column": 4}, "end_point": {"row": 49, "column": 39}}, {"id": 82, "type": "type_identifier", "text": "SIZE_T", "parent": 81, "children": [], "start_point": {"row": 49, "column": 4}, "end_point": {"row": 49, "column": 10}}, {"id": 83, "type": "field_identifier", "text": "QuotaPagedPoolUsage", "parent": 81, "children": [], "start_point": {"row": 49, "column": 19}, "end_point": {"row": 49, "column": 38}}, {"id": 84, "type": "field_declaration", "text": "SIZE_T QuotaPeakNonPagedPoolUsage;", "parent": 63, "children": [85, 86], "start_point": {"row": 50, "column": 4}, "end_point": {"row": 50, "column": 46}}, {"id": 85, "type": "type_identifier", "text": "SIZE_T", "parent": 84, "children": [], "start_point": {"row": 50, "column": 4}, "end_point": {"row": 50, "column": 10}}, {"id": 86, "type": "field_identifier", "text": "QuotaPeakNonPagedPoolUsage", "parent": 84, "children": [], "start_point": {"row": 50, "column": 19}, "end_point": {"row": 50, "column": 45}}, {"id": 87, "type": "field_declaration", "text": "SIZE_T QuotaNonPagedPoolUsage;", "parent": 63, "children": [88, 89], "start_point": {"row": 51, "column": 4}, "end_point": {"row": 51, "column": 42}}, {"id": 88, "type": "type_identifier", "text": "SIZE_T", "parent": 87, "children": [], "start_point": {"row": 51, "column": 4}, "end_point": {"row": 51, "column": 10}}, {"id": 89, "type": "field_identifier", "text": "QuotaNonPagedPoolUsage", "parent": 87, "children": [], "start_point": {"row": 51, "column": 19}, "end_point": {"row": 51, "column": 41}}, {"id": 90, "type": "field_declaration", "text": "SIZE_T PagefileUsage;", "parent": 63, "children": [91, 92], "start_point": {"row": 52, "column": 4}, "end_point": {"row": 52, "column": 33}}, {"id": 91, "type": "type_identifier", "text": "SIZE_T", "parent": 90, "children": [], "start_point": {"row": 52, "column": 4}, "end_point": {"row": 52, "column": 10}}, {"id": 92, "type": "field_identifier", "text": "PagefileUsage", "parent": 90, "children": [], "start_point": {"row": 52, "column": 19}, "end_point": {"row": 52, "column": 32}}, {"id": 93, "type": "field_declaration", "text": "SIZE_T PeakPagefileUsage;", "parent": 63, "children": [94, 95], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 37}}, {"id": 94, "type": "type_identifier", "text": "SIZE_T", "parent": 93, "children": [], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 10}}, {"id": 95, "type": "field_identifier", "text": "PeakPagefileUsage", "parent": 93, "children": [], "start_point": {"row": 53, "column": 19}, "end_point": {"row": 53, "column": 36}}, {"id": 96, "type": "field_declaration", "text": "SIZE_T VirtualSize;", "parent": 63, "children": [97, 98], "start_point": {"row": 54, "column": 4}, "end_point": {"row": 54, "column": 31}}, {"id": 97, "type": "type_identifier", "text": "SIZE_T", "parent": 96, "children": [], "start_point": {"row": 54, "column": 4}, "end_point": {"row": 54, "column": 10}}, {"id": 98, "type": "field_identifier", "text": "VirtualSize", "parent": 96, "children": [], "start_point": {"row": 54, "column": 19}, "end_point": {"row": 54, "column": 30}}, {"id": 99, "type": "preproc_else", "text": "#else\n SIZE_T PeakVirtualSize;\n SIZE_T VirtualSize;\n ULONG PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;", "parent": 63, "children": [100, 101, 104, 107, 110, 113, 116, 119, 122, 125, 128, 131], "start_point": {"row": 55, "column": 0}, "end_point": {"row": 66, "column": 37}}, {"id": 100, "type": "#else", "text": "#else", "parent": 99, "children": [], "start_point": {"row": 55, "column": 0}, "end_point": {"row": 55, "column": 5}}, {"id": 101, "type": "field_declaration", "text": "SIZE_T PeakVirtualSize;", "parent": 99, "children": [102, 103], "start_point": {"row": 56, "column": 4}, "end_point": {"row": 56, "column": 35}}, {"id": 102, "type": "type_identifier", "text": "SIZE_T", "parent": 101, "children": [], "start_point": {"row": 56, "column": 4}, "end_point": {"row": 56, "column": 10}}, {"id": 103, "type": "field_identifier", "text": "PeakVirtualSize", "parent": 101, "children": [], "start_point": {"row": 56, "column": 19}, "end_point": {"row": 56, "column": 34}}, {"id": 104, "type": "field_declaration", "text": "SIZE_T VirtualSize;", "parent": 99, "children": [105, 106], "start_point": {"row": 57, "column": 4}, "end_point": {"row": 57, "column": 31}}, {"id": 105, "type": "type_identifier", "text": "SIZE_T", "parent": 104, "children": [], "start_point": {"row": 57, "column": 4}, "end_point": {"row": 57, "column": 10}}, {"id": 106, "type": "field_identifier", "text": "VirtualSize", "parent": 104, "children": [], "start_point": {"row": 57, "column": 19}, "end_point": {"row": 57, "column": 30}}, {"id": 107, "type": "field_declaration", "text": "ULONG PageFaultCount;", "parent": 99, "children": [108, 109], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 34}}, {"id": 108, "type": "type_identifier", "text": "ULONG", "parent": 107, "children": [], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 9}}, {"id": 109, "type": "field_identifier", "text": "PageFaultCount", "parent": 107, "children": [], "start_point": {"row": 58, "column": 19}, "end_point": {"row": 58, "column": 33}}, {"id": 110, "type": "field_declaration", "text": "SIZE_T PeakWorkingSetSize;", "parent": 99, "children": [111, 112], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 38}}, {"id": 111, "type": "type_identifier", "text": "SIZE_T", "parent": 110, "children": [], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 10}}, {"id": 112, "type": "field_identifier", "text": "PeakWorkingSetSize", "parent": 110, "children": [], "start_point": {"row": 59, "column": 19}, "end_point": {"row": 59, "column": 37}}, {"id": 113, "type": "field_declaration", "text": "SIZE_T WorkingSetSize;", "parent": 99, "children": [114, 115], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 34}}, {"id": 114, "type": "type_identifier", "text": "SIZE_T", "parent": 113, "children": [], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 10}}, {"id": 115, "type": "field_identifier", "text": "WorkingSetSize", "parent": 113, "children": [], "start_point": {"row": 60, "column": 19}, "end_point": {"row": 60, "column": 33}}, {"id": 116, "type": "field_declaration", "text": "SIZE_T QuotaPeakPagedPoolUsage;", "parent": 99, "children": [117, 118], "start_point": {"row": 61, "column": 4}, "end_point": {"row": 61, "column": 43}}, {"id": 117, "type": "type_identifier", "text": "SIZE_T", "parent": 116, "children": [], "start_point": {"row": 61, "column": 4}, "end_point": {"row": 61, "column": 10}}, {"id": 118, "type": "field_identifier", "text": "QuotaPeakPagedPoolUsage", "parent": 116, "children": [], "start_point": {"row": 61, "column": 19}, "end_point": {"row": 61, "column": 42}}, {"id": 119, "type": "field_declaration", "text": "SIZE_T QuotaPagedPoolUsage;", "parent": 99, "children": [120, 121], "start_point": {"row": 62, "column": 4}, "end_point": {"row": 62, "column": 39}}, {"id": 120, "type": "type_identifier", "text": "SIZE_T", "parent": 119, "children": [], "start_point": {"row": 62, "column": 4}, "end_point": {"row": 62, "column": 10}}, {"id": 121, "type": "field_identifier", "text": "QuotaPagedPoolUsage", "parent": 119, "children": [], "start_point": {"row": 62, "column": 19}, "end_point": {"row": 62, "column": 38}}, {"id": 122, "type": "field_declaration", "text": "SIZE_T QuotaPeakNonPagedPoolUsage;", "parent": 99, "children": [123, 124], "start_point": {"row": 63, "column": 4}, "end_point": {"row": 63, "column": 46}}, {"id": 123, "type": "type_identifier", "text": "SIZE_T", "parent": 122, "children": [], "start_point": {"row": 63, "column": 4}, "end_point": {"row": 63, "column": 10}}, {"id": 124, "type": "field_identifier", "text": "QuotaPeakNonPagedPoolUsage", "parent": 122, "children": [], "start_point": {"row": 63, "column": 19}, "end_point": {"row": 63, "column": 45}}, {"id": 125, "type": "field_declaration", "text": "SIZE_T QuotaNonPagedPoolUsage;", "parent": 99, "children": [126, 127], "start_point": {"row": 64, "column": 4}, "end_point": {"row": 64, "column": 42}}, {"id": 126, "type": "type_identifier", "text": "SIZE_T", "parent": 125, "children": [], "start_point": {"row": 64, "column": 4}, "end_point": {"row": 64, "column": 10}}, {"id": 127, "type": "field_identifier", "text": "QuotaNonPagedPoolUsage", "parent": 125, "children": [], "start_point": {"row": 64, "column": 19}, "end_point": {"row": 64, "column": 41}}, {"id": 128, "type": "field_declaration", "text": "SIZE_T PagefileUsage;", "parent": 99, "children": [129, 130], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 33}}, {"id": 129, "type": "type_identifier", "text": "SIZE_T", "parent": 128, "children": [], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 10}}, {"id": 130, "type": "field_identifier", "text": "PagefileUsage", "parent": 128, "children": [], "start_point": {"row": 65, "column": 19}, "end_point": {"row": 65, "column": 32}}, {"id": 131, "type": "field_declaration", "text": "SIZE_T PeakPagefileUsage;", "parent": 99, "children": [132, 133], "start_point": {"row": 66, "column": 4}, "end_point": {"row": 66, "column": 37}}, {"id": 132, "type": "type_identifier", "text": "SIZE_T", "parent": 131, "children": [], "start_point": {"row": 66, "column": 4}, "end_point": {"row": 66, "column": 10}}, {"id": 133, "type": "field_identifier", "text": "PeakPagefileUsage", "parent": 131, "children": [], "start_point": {"row": 66, "column": 19}, "end_point": {"row": 66, "column": 36}}, {"id": 134, "type": "#endif", "text": "#endif", "parent": 63, "children": [], "start_point": {"row": 67, "column": 0}, "end_point": {"row": 67, "column": 6}}, {"id": 135, "type": "type_identifier", "text": "VM_COUNTERS", "parent": 58, "children": [], "start_point": {"row": 68, "column": 2}, "end_point": {"row": 68, "column": 13}}, {"id": 136, "type": "type_definition", "text": "typedef struct _SYSTEM_THREADS {\n LARGE_INTEGER KernelTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER CreateTime;\n ULONG WaitTime;\n PVOID StartAddress;\n CLIENT_ID ClientId;\n KPRIORITY Priority;\n KPRIORITY BasePriority;\n ULONG ContextSwitchCount;\n LONG State;\n LONG WaitReason;\n} SYSTEM_THREADS, * PSYSTEM_THREADS;", "parent": 0, "children": [137, 138, 174, 175], "start_point": {"row": 70, "column": 0}, "end_point": {"row": 82, "column": 36}}, {"id": 137, "type": "typedef", "text": "typedef", "parent": 136, "children": [], "start_point": {"row": 70, "column": 0}, "end_point": {"row": 70, "column": 7}}, {"id": 138, "type": "struct_specifier", "text": "struct _SYSTEM_THREADS {\n LARGE_INTEGER KernelTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER CreateTime;\n ULONG WaitTime;\n PVOID StartAddress;\n CLIENT_ID ClientId;\n KPRIORITY Priority;\n KPRIORITY BasePriority;\n ULONG ContextSwitchCount;\n LONG State;\n LONG WaitReason;\n}", "parent": 136, "children": [139, 140], "start_point": {"row": 70, "column": 8}, "end_point": {"row": 82, "column": 1}}, {"id": 139, "type": "struct", "text": "struct", "parent": 138, "children": [], "start_point": {"row": 70, "column": 8}, "end_point": {"row": 70, "column": 14}}, {"id": 140, "type": "type_identifier", "text": "_SYSTEM_THREADS", "parent": 138, "children": [], "start_point": {"row": 70, "column": 15}, "end_point": {"row": 70, "column": 30}}, {"id": 141, "type": "field_declaration", "text": "LARGE_INTEGER KernelTime;", "parent": 138, "children": [142, 143], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 30}}, {"id": 142, "type": "type_identifier", "text": "LARGE_INTEGER", "parent": 141, "children": [], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 17}}, {"id": 143, "type": "field_identifier", "text": "KernelTime", "parent": 141, "children": [], "start_point": {"row": 71, "column": 19}, "end_point": {"row": 71, "column": 29}}, {"id": 144, "type": "field_declaration", "text": "LARGE_INTEGER UserTime;", "parent": 138, "children": [145, 146], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 28}}, {"id": 145, "type": "type_identifier", "text": "LARGE_INTEGER", "parent": 144, "children": [], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 17}}, {"id": 146, "type": "field_identifier", "text": "UserTime", "parent": 144, "children": [], "start_point": {"row": 72, "column": 19}, "end_point": {"row": 72, "column": 27}}, {"id": 147, "type": "field_declaration", "text": "LARGE_INTEGER CreateTime;", "parent": 138, "children": [148, 149], "start_point": {"row": 73, "column": 4}, "end_point": {"row": 73, "column": 30}}, {"id": 148, "type": "type_identifier", "text": "LARGE_INTEGER", "parent": 147, "children": [], "start_point": {"row": 73, "column": 4}, "end_point": {"row": 73, "column": 17}}, {"id": 149, "type": "field_identifier", "text": "CreateTime", "parent": 147, "children": [], "start_point": {"row": 73, "column": 19}, "end_point": {"row": 73, "column": 29}}, {"id": 150, "type": "field_declaration", "text": "ULONG WaitTime;", "parent": 138, "children": [151, 152], "start_point": {"row": 74, "column": 4}, "end_point": {"row": 74, "column": 28}}, {"id": 151, "type": "type_identifier", "text": "ULONG", "parent": 150, "children": [], "start_point": {"row": 74, "column": 4}, "end_point": {"row": 74, "column": 9}}, {"id": 152, "type": "field_identifier", "text": "WaitTime", "parent": 150, "children": [], "start_point": {"row": 74, "column": 19}, "end_point": {"row": 74, "column": 27}}, {"id": 153, "type": "field_declaration", "text": "PVOID StartAddress;", "parent": 138, "children": [154, 155], "start_point": {"row": 75, "column": 4}, "end_point": {"row": 75, "column": 32}}, {"id": 154, "type": "type_identifier", "text": "PVOID", "parent": 153, "children": [], "start_point": {"row": 75, "column": 4}, "end_point": {"row": 75, "column": 9}}, {"id": 155, "type": "field_identifier", "text": "StartAddress", "parent": 153, "children": [], "start_point": {"row": 75, "column": 19}, "end_point": {"row": 75, "column": 31}}, {"id": 156, "type": "field_declaration", "text": "CLIENT_ID ClientId;", "parent": 138, "children": [157, 158], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 28}}, {"id": 157, "type": "type_identifier", "text": "CLIENT_ID", "parent": 156, "children": [], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 13}}, {"id": 158, "type": "field_identifier", "text": "ClientId", "parent": 156, "children": [], "start_point": {"row": 76, "column": 19}, "end_point": {"row": 76, "column": 27}}, {"id": 159, "type": "field_declaration", "text": "KPRIORITY Priority;", "parent": 138, "children": [160, 161], "start_point": {"row": 77, "column": 4}, "end_point": {"row": 77, "column": 28}}, {"id": 160, "type": "type_identifier", "text": "KPRIORITY", "parent": 159, "children": [], "start_point": {"row": 77, "column": 4}, "end_point": {"row": 77, "column": 13}}, {"id": 161, "type": "field_identifier", "text": "Priority", "parent": 159, "children": [], "start_point": {"row": 77, "column": 19}, "end_point": {"row": 77, "column": 27}}, {"id": 162, "type": "field_declaration", "text": "KPRIORITY BasePriority;", "parent": 138, "children": [163, 164], "start_point": {"row": 78, "column": 4}, "end_point": {"row": 78, "column": 32}}, {"id": 163, "type": "type_identifier", "text": "KPRIORITY", "parent": 162, "children": [], "start_point": {"row": 78, "column": 4}, "end_point": {"row": 78, "column": 13}}, {"id": 164, "type": "field_identifier", "text": "BasePriority", "parent": 162, "children": [], "start_point": {"row": 78, "column": 19}, "end_point": {"row": 78, "column": 31}}, {"id": 165, "type": "field_declaration", "text": "ULONG ContextSwitchCount;", "parent": 138, "children": [166, 167], "start_point": {"row": 79, "column": 4}, "end_point": {"row": 79, "column": 38}}, {"id": 166, "type": "type_identifier", "text": "ULONG", "parent": 165, "children": [], "start_point": {"row": 79, "column": 4}, "end_point": {"row": 79, "column": 9}}, {"id": 167, "type": "field_identifier", "text": "ContextSwitchCount", "parent": 165, "children": [], "start_point": {"row": 79, "column": 19}, "end_point": {"row": 79, "column": 37}}, {"id": 168, "type": "field_declaration", "text": "LONG State;", "parent": 138, "children": [169, 170], "start_point": {"row": 80, "column": 4}, "end_point": {"row": 80, "column": 25}}, {"id": 169, "type": "type_identifier", "text": "LONG", "parent": 168, "children": [], "start_point": {"row": 80, "column": 4}, "end_point": {"row": 80, "column": 8}}, {"id": 170, "type": "field_identifier", "text": "State", "parent": 168, "children": [], "start_point": {"row": 80, "column": 19}, "end_point": {"row": 80, "column": 24}}, {"id": 171, "type": "field_declaration", "text": "LONG WaitReason;", "parent": 138, "children": [172, 173], "start_point": {"row": 81, "column": 4}, "end_point": {"row": 81, "column": 30}}, {"id": 172, "type": "type_identifier", "text": "LONG", "parent": 171, "children": [], "start_point": {"row": 81, "column": 4}, "end_point": {"row": 81, "column": 8}}, {"id": 173, "type": "field_identifier", "text": "WaitReason", "parent": 171, "children": [], "start_point": {"row": 81, "column": 19}, "end_point": {"row": 81, "column": 29}}, {"id": 174, "type": "type_identifier", "text": "SYSTEM_THREADS", "parent": 136, "children": [], "start_point": {"row": 82, "column": 2}, "end_point": {"row": 82, "column": 16}}, {"id": 175, "type": "pointer_declarator", "text": "* PSYSTEM_THREADS", "parent": 136, "children": [176, 177], "start_point": {"row": 82, "column": 18}, "end_point": {"row": 82, "column": 35}}, {"id": 176, "type": "*", "text": "*", "parent": 175, "children": [], "start_point": {"row": 82, "column": 18}, "end_point": {"row": 82, "column": 19}}, {"id": 177, "type": "type_identifier", "text": "PSYSTEM_THREADS", "parent": 175, "children": [], "start_point": {"row": 82, "column": 20}, "end_point": {"row": 82, "column": 35}}, {"id": 178, "type": "type_definition", "text": "typedef struct _SYSTEM_PROCESSES_NT4 {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n SYSTEM_THREADS Threads[1];\n} SYSTEM_PROCESSES_NT4, *PSYSTEM_PROCESSES_NT4;", "parent": 0, "children": [179, 180, 231, 232], "start_point": {"row": 84, "column": 0}, "end_point": {"row": 99, "column": 47}}, {"id": 179, "type": "typedef", "text": "typedef", "parent": 178, "children": [], "start_point": {"row": 84, "column": 0}, "end_point": {"row": 84, "column": 7}}, {"id": 180, "type": "struct_specifier", "text": "struct _SYSTEM_PROCESSES_NT4 {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n SYSTEM_THREADS Threads[1];\n}", "parent": 178, "children": [181, 182], "start_point": {"row": 84, "column": 8}, "end_point": {"row": 99, "column": 1}}, {"id": 181, "type": "struct", "text": "struct", "parent": 180, "children": [], "start_point": {"row": 84, "column": 8}, "end_point": {"row": 84, "column": 14}}, {"id": 182, "type": "type_identifier", "text": "_SYSTEM_PROCESSES_NT4", "parent": 180, "children": [], "start_point": {"row": 84, "column": 15}, "end_point": {"row": 84, "column": 36}}, {"id": 183, "type": "field_declaration", "text": "ULONG NextEntryDelta;", "parent": 180, "children": [184, 185], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 34}}, {"id": 184, "type": "type_identifier", "text": "ULONG", "parent": 183, "children": [], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 9}}, {"id": 185, "type": "field_identifier", "text": "NextEntryDelta", "parent": 183, "children": [], "start_point": {"row": 85, "column": 19}, "end_point": {"row": 85, "column": 33}}, {"id": 186, "type": "field_declaration", "text": "ULONG ThreadCount;", "parent": 180, "children": [187, 188], "start_point": {"row": 86, "column": 4}, "end_point": {"row": 86, "column": 31}}, {"id": 187, "type": "type_identifier", "text": "ULONG", "parent": 186, "children": [], "start_point": {"row": 86, "column": 4}, "end_point": {"row": 86, "column": 9}}, {"id": 188, "type": "field_identifier", "text": "ThreadCount", "parent": 186, "children": [], "start_point": {"row": 86, "column": 19}, "end_point": {"row": 86, "column": 30}}, {"id": 189, "type": "field_declaration", "text": "ULONG Reserved1[6];", "parent": 180, "children": [190, 191], "start_point": {"row": 87, "column": 4}, "end_point": {"row": 87, "column": 32}}, {"id": 190, "type": "type_identifier", "text": "ULONG", "parent": 189, "children": [], "start_point": {"row": 87, "column": 4}, "end_point": {"row": 87, "column": 9}}, {"id": 191, "type": "array_declarator", "text": "Reserved1[6]", "parent": 189, "children": [192, 193], "start_point": {"row": 87, "column": 19}, "end_point": {"row": 87, "column": 31}}, {"id": 192, "type": "field_identifier", "text": "Reserved1", "parent": 191, "children": [], "start_point": {"row": 87, "column": 19}, "end_point": {"row": 87, "column": 28}}, {"id": 193, "type": "number_literal", "text": "6", "parent": 191, "children": [], "start_point": {"row": 87, "column": 29}, "end_point": {"row": 87, "column": 30}}, {"id": 194, "type": "field_declaration", "text": "LARGE_INTEGER CreateTime;", "parent": 180, "children": [195, 196], "start_point": {"row": 88, "column": 4}, "end_point": {"row": 88, "column": 30}}, {"id": 195, "type": "type_identifier", "text": "LARGE_INTEGER", "parent": 194, "children": [], "start_point": {"row": 88, "column": 4}, "end_point": {"row": 88, "column": 17}}, {"id": 196, "type": "field_identifier", "text": "CreateTime", "parent": 194, "children": [], "start_point": {"row": 88, "column": 19}, "end_point": {"row": 88, "column": 29}}, {"id": 197, "type": "field_declaration", "text": "LARGE_INTEGER UserTime;", "parent": 180, "children": [198, 199], "start_point": {"row": 89, "column": 4}, "end_point": {"row": 89, "column": 28}}, {"id": 198, "type": "type_identifier", "text": "LARGE_INTEGER", "parent": 197, "children": [], "start_point": {"row": 89, "column": 4}, "end_point": {"row": 89, "column": 17}}, {"id": 199, "type": "field_identifier", "text": "UserTime", "parent": 197, "children": [], "start_point": {"row": 89, "column": 19}, "end_point": {"row": 89, "column": 27}}, {"id": 200, "type": "field_declaration", "text": "LARGE_INTEGER KernelTime;", "parent": 180, "children": [201, 202], "start_point": {"row": 90, "column": 4}, "end_point": {"row": 90, "column": 30}}, {"id": 201, "type": "type_identifier", "text": "LARGE_INTEGER", "parent": 200, "children": [], "start_point": {"row": 90, "column": 4}, "end_point": {"row": 90, "column": 17}}, {"id": 202, "type": "field_identifier", "text": "KernelTime", "parent": 200, "children": [], "start_point": {"row": 90, "column": 19}, "end_point": {"row": 90, "column": 29}}, {"id": 203, "type": "field_declaration", "text": "UNICODE_STRING ProcessName;", "parent": 180, "children": [204, 205], "start_point": {"row": 91, "column": 4}, "end_point": {"row": 91, "column": 31}}, {"id": 204, "type": "type_identifier", "text": "UNICODE_STRING", "parent": 203, "children": [], "start_point": {"row": 91, "column": 4}, "end_point": {"row": 91, "column": 18}}, {"id": 205, "type": "field_identifier", "text": "ProcessName", "parent": 203, "children": [], "start_point": {"row": 91, "column": 19}, "end_point": {"row": 91, "column": 30}}, {"id": 206, "type": "field_declaration", "text": "KPRIORITY BasePriority;", "parent": 180, "children": [207, 208], "start_point": {"row": 92, "column": 4}, "end_point": {"row": 92, "column": 32}}, {"id": 207, "type": "type_identifier", "text": "KPRIORITY", "parent": 206, "children": [], "start_point": {"row": 92, "column": 4}, "end_point": {"row": 92, "column": 13}}, {"id": 208, "type": "field_identifier", "text": "BasePriority", "parent": 206, "children": [], "start_point": {"row": 92, "column": 19}, "end_point": {"row": 92, "column": 31}}, {"id": 209, "type": "field_declaration", "text": "ULONG ProcessId;", "parent": 180, "children": [210, 211], "start_point": {"row": 93, "column": 4}, "end_point": {"row": 93, "column": 29}}, {"id": 210, "type": "type_identifier", "text": "ULONG", "parent": 209, "children": [], "start_point": {"row": 93, "column": 4}, "end_point": {"row": 93, "column": 9}}, {"id": 211, "type": "field_identifier", "text": "ProcessId", "parent": 209, "children": [], "start_point": {"row": 93, "column": 19}, "end_point": {"row": 93, "column": 28}}, {"id": 212, "type": "field_declaration", "text": "ULONG InheritedFromProcessId;", "parent": 180, "children": [213, 214], "start_point": {"row": 94, "column": 4}, "end_point": {"row": 94, "column": 42}}, {"id": 213, "type": "type_identifier", "text": "ULONG", "parent": 212, "children": [], "start_point": {"row": 94, "column": 4}, "end_point": {"row": 94, "column": 9}}, {"id": 214, "type": "field_identifier", "text": "InheritedFromProcessId", "parent": 212, "children": [], "start_point": {"row": 94, "column": 19}, "end_point": {"row": 94, "column": 41}}, {"id": 215, "type": "field_declaration", "text": "ULONG HandleCount;", "parent": 180, "children": [216, 217], "start_point": {"row": 95, "column": 4}, "end_point": {"row": 95, "column": 31}}, {"id": 216, "type": "type_identifier", "text": "ULONG", "parent": 215, "children": [], "start_point": {"row": 95, "column": 4}, "end_point": {"row": 95, "column": 9}}, {"id": 217, "type": "field_identifier", "text": "HandleCount", "parent": 215, "children": [], "start_point": {"row": 95, "column": 19}, "end_point": {"row": 95, "column": 30}}, {"id": 218, "type": "field_declaration", "text": "ULONG Reserved2[2];", "parent": 180, "children": [219, 220], "start_point": {"row": 96, "column": 4}, "end_point": {"row": 96, "column": 32}}, {"id": 219, "type": "type_identifier", "text": "ULONG", "parent": 218, "children": [], "start_point": {"row": 96, "column": 4}, "end_point": {"row": 96, "column": 9}}, {"id": 220, "type": "array_declarator", "text": "Reserved2[2]", "parent": 218, "children": [221, 222], "start_point": {"row": 96, "column": 19}, "end_point": {"row": 96, "column": 31}}, {"id": 221, "type": "field_identifier", "text": "Reserved2", "parent": 220, "children": [], "start_point": {"row": 96, "column": 19}, "end_point": {"row": 96, "column": 28}}, {"id": 222, "type": "number_literal", "text": "2", "parent": 220, "children": [], "start_point": {"row": 96, "column": 29}, "end_point": {"row": 96, "column": 30}}, {"id": 223, "type": "field_declaration", "text": "VM_COUNTERS VmCounters;", "parent": 180, "children": [224, 225], "start_point": {"row": 97, "column": 4}, "end_point": {"row": 97, "column": 30}}, {"id": 224, "type": "type_identifier", "text": "VM_COUNTERS", "parent": 223, "children": [], "start_point": {"row": 97, "column": 4}, "end_point": {"row": 97, "column": 15}}, {"id": 225, "type": "field_identifier", "text": "VmCounters", "parent": 223, "children": [], "start_point": {"row": 97, "column": 19}, "end_point": {"row": 97, "column": 29}}, {"id": 226, "type": "field_declaration", "text": "SYSTEM_THREADS Threads[1];", "parent": 180, "children": [227, 228], "start_point": {"row": 98, "column": 4}, "end_point": {"row": 98, "column": 30}}, {"id": 227, "type": "type_identifier", "text": "SYSTEM_THREADS", "parent": 226, "children": [], "start_point": {"row": 98, "column": 4}, "end_point": {"row": 98, "column": 18}}, {"id": 228, "type": "array_declarator", "text": "Threads[1]", "parent": 226, "children": [229, 230], "start_point": {"row": 98, "column": 19}, "end_point": {"row": 98, "column": 29}}, {"id": 229, "type": "field_identifier", "text": "Threads", "parent": 228, "children": [], "start_point": {"row": 98, "column": 19}, "end_point": {"row": 98, "column": 26}}, {"id": 230, "type": "number_literal", "text": "1", "parent": 228, "children": [], "start_point": {"row": 98, "column": 27}, "end_point": {"row": 98, "column": 28}}, {"id": 231, "type": "type_identifier", "text": "SYSTEM_PROCESSES_NT4", "parent": 178, "children": [], "start_point": {"row": 99, "column": 2}, "end_point": {"row": 99, "column": 22}}, {"id": 232, "type": "pointer_declarator", "text": "*PSYSTEM_PROCESSES_NT4", "parent": 178, "children": [233, 234], "start_point": {"row": 99, "column": 24}, "end_point": {"row": 99, "column": 46}}, {"id": 233, "type": "*", "text": "*", "parent": 232, "children": [], "start_point": {"row": 99, "column": 24}, "end_point": {"row": 99, "column": 25}}, {"id": 234, "type": "type_identifier", "text": "PSYSTEM_PROCESSES_NT4", "parent": 232, "children": [], "start_point": {"row": 99, "column": 25}, "end_point": {"row": 99, "column": 46}}, {"id": 235, "type": "type_definition", "text": "typedef struct _SYSTEM_PROCESSES {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n#ifdef _WIN64\n\tULONG pad1;\n ULONG ProcessId;\n\tULONG pad2;\n ULONG InheritedFromProcessId;\n\tULONG pad3, pad4, pad5;\n#else\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n#endif\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n IO_COUNTERS IoCounters;\n SYSTEM_THREADS Threads[1];\n} SYSTEM_PROCESSES, * PSYSTEM_PROCESSES;", "parent": 0, "children": [236, 237, 314, 315], "start_point": {"row": 101, "column": 0}, "end_point": {"row": 125, "column": 40}}, {"id": 236, "type": "typedef", "text": "typedef", "parent": 235, "children": [], "start_point": {"row": 101, "column": 0}, "end_point": {"row": 101, "column": 7}}, {"id": 237, "type": "struct_specifier", "text": "struct _SYSTEM_PROCESSES {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n#ifdef _WIN64\n\tULONG pad1;\n ULONG ProcessId;\n\tULONG pad2;\n ULONG InheritedFromProcessId;\n\tULONG pad3, pad4, pad5;\n#else\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n#endif\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n IO_COUNTERS IoCounters;\n SYSTEM_THREADS Threads[1];\n}", "parent": 235, "children": [238, 239], "start_point": {"row": 101, "column": 8}, "end_point": {"row": 125, "column": 1}}, {"id": 238, "type": "struct", "text": "struct", "parent": 237, "children": [], "start_point": {"row": 101, "column": 8}, "end_point": {"row": 101, "column": 14}}, {"id": 239, "type": "type_identifier", "text": "_SYSTEM_PROCESSES", "parent": 237, "children": [], "start_point": {"row": 101, "column": 15}, "end_point": {"row": 101, "column": 32}}, {"id": 240, "type": "field_declaration", "text": "ULONG NextEntryDelta;", "parent": 237, "children": [241, 242], "start_point": {"row": 102, "column": 4}, "end_point": {"row": 102, "column": 34}}, {"id": 241, "type": "type_identifier", "text": "ULONG", "parent": 240, "children": [], "start_point": {"row": 102, "column": 4}, "end_point": {"row": 102, "column": 9}}, {"id": 242, "type": "field_identifier", "text": "NextEntryDelta", "parent": 240, "children": [], "start_point": {"row": 102, "column": 19}, "end_point": {"row": 102, "column": 33}}, {"id": 243, "type": "field_declaration", "text": "ULONG ThreadCount;", "parent": 237, "children": [244, 245], "start_point": {"row": 103, "column": 4}, "end_point": {"row": 103, "column": 31}}, {"id": 244, "type": "type_identifier", "text": "ULONG", "parent": 243, "children": [], "start_point": {"row": 103, "column": 4}, "end_point": {"row": 103, "column": 9}}, {"id": 245, "type": "field_identifier", "text": "ThreadCount", "parent": 243, "children": [], "start_point": {"row": 103, "column": 19}, "end_point": {"row": 103, "column": 30}}, {"id": 246, "type": "field_declaration", "text": "ULONG Reserved1[6];", "parent": 237, "children": [247, 248], "start_point": {"row": 104, "column": 4}, "end_point": {"row": 104, "column": 32}}, {"id": 247, "type": "type_identifier", "text": "ULONG", "parent": 246, "children": [], "start_point": {"row": 104, "column": 4}, "end_point": {"row": 104, "column": 9}}, {"id": 248, "type": "array_declarator", "text": "Reserved1[6]", "parent": 246, "children": [249, 250], "start_point": {"row": 104, "column": 19}, "end_point": {"row": 104, "column": 31}}, {"id": 249, "type": "field_identifier", "text": "Reserved1", "parent": 248, "children": [], "start_point": {"row": 104, "column": 19}, "end_point": {"row": 104, "column": 28}}, {"id": 250, "type": "number_literal", "text": "6", "parent": 248, "children": [], "start_point": {"row": 104, "column": 29}, "end_point": {"row": 104, "column": 30}}, {"id": 251, "type": "field_declaration", "text": "LARGE_INTEGER CreateTime;", "parent": 237, "children": [252, 253], "start_point": {"row": 105, "column": 4}, "end_point": {"row": 105, "column": 30}}, {"id": 252, "type": "type_identifier", "text": "LARGE_INTEGER", "parent": 251, "children": [], "start_point": {"row": 105, "column": 4}, "end_point": {"row": 105, "column": 17}}, {"id": 253, "type": "field_identifier", "text": "CreateTime", "parent": 251, "children": [], "start_point": {"row": 105, "column": 19}, "end_point": {"row": 105, "column": 29}}, {"id": 254, "type": "field_declaration", "text": "LARGE_INTEGER UserTime;", "parent": 237, "children": [255, 256], "start_point": {"row": 106, "column": 4}, "end_point": {"row": 106, "column": 28}}, {"id": 255, "type": "type_identifier", "text": "LARGE_INTEGER", "parent": 254, "children": [], "start_point": {"row": 106, "column": 4}, "end_point": {"row": 106, "column": 17}}, {"id": 256, "type": "field_identifier", "text": "UserTime", "parent": 254, "children": [], "start_point": {"row": 106, "column": 19}, "end_point": {"row": 106, "column": 27}}, {"id": 257, "type": "field_declaration", "text": "LARGE_INTEGER KernelTime;", "parent": 237, "children": [258, 259], "start_point": {"row": 107, "column": 4}, "end_point": {"row": 107, "column": 30}}, {"id": 258, "type": "type_identifier", "text": "LARGE_INTEGER", "parent": 257, "children": [], "start_point": {"row": 107, "column": 4}, "end_point": {"row": 107, "column": 17}}, {"id": 259, "type": "field_identifier", "text": "KernelTime", "parent": 257, "children": [], "start_point": {"row": 107, "column": 19}, "end_point": {"row": 107, "column": 29}}, {"id": 260, "type": "field_declaration", "text": "UNICODE_STRING ProcessName;", "parent": 237, "children": [261, 262], "start_point": {"row": 108, "column": 4}, "end_point": {"row": 108, "column": 31}}, {"id": 261, "type": "type_identifier", "text": "UNICODE_STRING", "parent": 260, "children": [], "start_point": {"row": 108, "column": 4}, "end_point": {"row": 108, "column": 18}}, {"id": 262, "type": "field_identifier", "text": "ProcessName", "parent": 260, "children": [], "start_point": {"row": 108, "column": 19}, "end_point": {"row": 108, "column": 30}}, {"id": 263, "type": "field_declaration", "text": "KPRIORITY BasePriority;", "parent": 237, "children": [264, 265], "start_point": {"row": 109, "column": 4}, "end_point": {"row": 109, "column": 32}}, {"id": 264, "type": "type_identifier", "text": "KPRIORITY", "parent": 263, "children": [], "start_point": {"row": 109, "column": 4}, "end_point": {"row": 109, "column": 13}}, {"id": 265, "type": "field_identifier", "text": "BasePriority", "parent": 263, "children": [], "start_point": {"row": 109, "column": 19}, "end_point": {"row": 109, "column": 31}}, {"id": 266, "type": "preproc_ifdef", "text": "#ifdef _WIN64\n\tULONG pad1;\n ULONG ProcessId;\n\tULONG pad2;\n ULONG InheritedFromProcessId;\n\tULONG pad3, pad4, pad5;\n#else\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n#endif", "parent": 237, "children": [267, 268, 269, 272, 275, 278, 281, 286, 294], "start_point": {"row": 110, "column": 0}, "end_point": {"row": 119, "column": 6}}, {"id": 267, "type": "#ifdef", "text": "#ifdef", "parent": 266, "children": [], "start_point": {"row": 110, "column": 0}, "end_point": {"row": 110, "column": 6}}, {"id": 268, "type": "identifier", "text": "_WIN64", "parent": 266, "children": [], "start_point": {"row": 110, "column": 7}, "end_point": {"row": 110, "column": 13}}, {"id": 269, "type": "field_declaration", "text": "ULONG pad1;", "parent": 266, "children": [270, 271], "start_point": {"row": 111, "column": 1}, "end_point": {"row": 111, "column": 12}}, {"id": 270, "type": "type_identifier", "text": "ULONG", "parent": 269, "children": [], "start_point": {"row": 111, "column": 1}, "end_point": {"row": 111, "column": 6}}, {"id": 271, "type": "field_identifier", "text": "pad1", "parent": 269, "children": [], "start_point": {"row": 111, "column": 7}, "end_point": {"row": 111, "column": 11}}, {"id": 272, "type": "field_declaration", "text": "ULONG ProcessId;", "parent": 266, "children": [273, 274], "start_point": {"row": 112, "column": 4}, "end_point": {"row": 112, "column": 29}}, {"id": 273, "type": "type_identifier", "text": "ULONG", "parent": 272, "children": [], "start_point": {"row": 112, "column": 4}, "end_point": {"row": 112, "column": 9}}, {"id": 274, "type": "field_identifier", "text": "ProcessId", "parent": 272, "children": [], "start_point": {"row": 112, "column": 19}, "end_point": {"row": 112, "column": 28}}, {"id": 275, "type": "field_declaration", "text": "ULONG pad2;", "parent": 266, "children": [276, 277], "start_point": {"row": 113, "column": 1}, "end_point": {"row": 113, "column": 12}}, {"id": 276, "type": "type_identifier", "text": "ULONG", "parent": 275, "children": [], "start_point": {"row": 113, "column": 1}, "end_point": {"row": 113, "column": 6}}, {"id": 277, "type": "field_identifier", "text": "pad2", "parent": 275, "children": [], "start_point": {"row": 113, "column": 7}, "end_point": {"row": 113, "column": 11}}, {"id": 278, "type": "field_declaration", "text": "ULONG InheritedFromProcessId;", "parent": 266, "children": [279, 280], "start_point": {"row": 114, "column": 4}, "end_point": {"row": 114, "column": 42}}, {"id": 279, "type": "type_identifier", "text": "ULONG", "parent": 278, "children": [], "start_point": {"row": 114, "column": 4}, "end_point": {"row": 114, "column": 9}}, {"id": 280, "type": "field_identifier", "text": "InheritedFromProcessId", "parent": 278, "children": [], "start_point": {"row": 114, "column": 19}, "end_point": {"row": 114, "column": 41}}, {"id": 281, "type": "field_declaration", "text": "ULONG pad3, pad4, pad5;", "parent": 266, "children": [282, 283, 284, 285], "start_point": {"row": 115, "column": 1}, "end_point": {"row": 115, "column": 24}}, {"id": 282, "type": "type_identifier", "text": "ULONG", "parent": 281, "children": [], "start_point": {"row": 115, "column": 1}, "end_point": {"row": 115, "column": 6}}, {"id": 283, "type": "field_identifier", "text": "pad3", "parent": 281, "children": [], "start_point": {"row": 115, "column": 7}, "end_point": {"row": 115, "column": 11}}, {"id": 284, "type": "field_identifier", "text": "pad4", "parent": 281, "children": [], "start_point": {"row": 115, "column": 13}, "end_point": {"row": 115, "column": 17}}, {"id": 285, "type": "field_identifier", "text": "pad5", "parent": 281, "children": [], "start_point": {"row": 115, "column": 19}, "end_point": {"row": 115, "column": 23}}, {"id": 286, "type": "preproc_else", "text": "#else\n ULONG ProcessId;\n ULONG InheritedFromProcessId;", "parent": 266, "children": [287, 288, 291], "start_point": {"row": 116, "column": 0}, "end_point": {"row": 118, "column": 42}}, {"id": 287, "type": "#else", "text": "#else", "parent": 286, "children": [], "start_point": {"row": 116, "column": 0}, "end_point": {"row": 116, "column": 5}}, {"id": 288, "type": "field_declaration", "text": "ULONG ProcessId;", "parent": 286, "children": [289, 290], "start_point": {"row": 117, "column": 4}, "end_point": {"row": 117, "column": 29}}, {"id": 289, "type": "type_identifier", "text": "ULONG", "parent": 288, "children": [], "start_point": {"row": 117, "column": 4}, "end_point": {"row": 117, "column": 9}}, {"id": 290, "type": "field_identifier", "text": "ProcessId", "parent": 288, "children": [], "start_point": {"row": 117, "column": 19}, "end_point": {"row": 117, "column": 28}}, {"id": 291, "type": "field_declaration", "text": "ULONG InheritedFromProcessId;", "parent": 286, "children": [292, 293], "start_point": {"row": 118, "column": 4}, "end_point": {"row": 118, "column": 42}}, {"id": 292, "type": "type_identifier", "text": "ULONG", "parent": 291, "children": [], "start_point": {"row": 118, "column": 4}, "end_point": {"row": 118, "column": 9}}, {"id": 293, "type": "field_identifier", "text": "InheritedFromProcessId", "parent": 291, "children": [], "start_point": {"row": 118, "column": 19}, "end_point": {"row": 118, "column": 41}}, {"id": 294, "type": "#endif", "text": "#endif", "parent": 266, "children": [], "start_point": {"row": 119, "column": 0}, "end_point": {"row": 119, "column": 6}}, {"id": 295, "type": "field_declaration", "text": "ULONG HandleCount;", "parent": 237, "children": [296, 297], "start_point": {"row": 120, "column": 4}, "end_point": {"row": 120, "column": 31}}, {"id": 296, "type": "type_identifier", "text": "ULONG", "parent": 295, "children": [], "start_point": {"row": 120, "column": 4}, "end_point": {"row": 120, "column": 9}}, {"id": 297, "type": "field_identifier", "text": "HandleCount", "parent": 295, "children": [], "start_point": {"row": 120, "column": 19}, "end_point": {"row": 120, "column": 30}}, {"id": 298, "type": "field_declaration", "text": "ULONG Reserved2[2];", "parent": 237, "children": [299, 300], "start_point": {"row": 121, "column": 4}, "end_point": {"row": 121, "column": 32}}, {"id": 299, "type": "type_identifier", "text": "ULONG", "parent": 298, "children": [], "start_point": {"row": 121, "column": 4}, "end_point": {"row": 121, "column": 9}}, {"id": 300, "type": "array_declarator", "text": "Reserved2[2]", "parent": 298, "children": [301, 302], "start_point": {"row": 121, "column": 19}, "end_point": {"row": 121, "column": 31}}, {"id": 301, "type": "field_identifier", "text": "Reserved2", "parent": 300, "children": [], "start_point": {"row": 121, "column": 19}, "end_point": {"row": 121, "column": 28}}, {"id": 302, "type": "number_literal", "text": "2", "parent": 300, "children": [], "start_point": {"row": 121, "column": 29}, "end_point": {"row": 121, "column": 30}}, {"id": 303, "type": "field_declaration", "text": "VM_COUNTERS VmCounters;", "parent": 237, "children": [304, 305], "start_point": {"row": 122, "column": 4}, "end_point": {"row": 122, "column": 30}}, {"id": 304, "type": "type_identifier", "text": "VM_COUNTERS", "parent": 303, "children": [], "start_point": {"row": 122, "column": 4}, "end_point": {"row": 122, "column": 15}}, {"id": 305, "type": "field_identifier", "text": "VmCounters", "parent": 303, "children": [], "start_point": {"row": 122, "column": 19}, "end_point": {"row": 122, "column": 29}}, {"id": 306, "type": "field_declaration", "text": "IO_COUNTERS IoCounters;", "parent": 237, "children": [307, 308], "start_point": {"row": 123, "column": 4}, "end_point": {"row": 123, "column": 30}}, {"id": 307, "type": "type_identifier", "text": "IO_COUNTERS", "parent": 306, "children": [], "start_point": {"row": 123, "column": 4}, "end_point": {"row": 123, "column": 15}}, {"id": 308, "type": "field_identifier", "text": "IoCounters", "parent": 306, "children": [], "start_point": {"row": 123, "column": 19}, "end_point": {"row": 123, "column": 29}}, {"id": 309, "type": "field_declaration", "text": "SYSTEM_THREADS Threads[1];", "parent": 237, "children": [310, 311], "start_point": {"row": 124, "column": 4}, "end_point": {"row": 124, "column": 30}}, {"id": 310, "type": "type_identifier", "text": "SYSTEM_THREADS", "parent": 309, "children": [], "start_point": {"row": 124, "column": 4}, "end_point": {"row": 124, "column": 18}}, {"id": 311, "type": "array_declarator", "text": "Threads[1]", "parent": 309, "children": [312, 313], "start_point": {"row": 124, "column": 19}, "end_point": {"row": 124, "column": 29}}, {"id": 312, "type": "field_identifier", "text": "Threads", "parent": 311, "children": [], "start_point": {"row": 124, "column": 19}, "end_point": {"row": 124, "column": 26}}, {"id": 313, "type": "number_literal", "text": "1", "parent": 311, "children": [], "start_point": {"row": 124, "column": 27}, "end_point": {"row": 124, "column": 28}}, {"id": 314, "type": "type_identifier", "text": "SYSTEM_PROCESSES", "parent": 235, "children": [], "start_point": {"row": 125, "column": 2}, "end_point": {"row": 125, "column": 18}}, {"id": 315, "type": "pointer_declarator", "text": "* PSYSTEM_PROCESSES", "parent": 235, "children": [316, 317], "start_point": {"row": 125, "column": 20}, "end_point": {"row": 125, "column": 39}}, {"id": 316, "type": "*", "text": "*", "parent": 315, "children": [], "start_point": {"row": 125, "column": 20}, "end_point": {"row": 125, "column": 21}}, {"id": 317, "type": "type_identifier", "text": "PSYSTEM_PROCESSES", "parent": 315, "children": [], "start_point": {"row": 125, "column": 22}, "end_point": {"row": 125, "column": 39}}, {"id": 318, "type": "type_definition", "text": "typedef enum _THREAD_STATE {\n ThreadStateInitialized,\n ThreadStateReady,\n ThreadStateRunning,\n ThreadStateStandby,\n ThreadStateTerminated,\n ThreadStateWaiting,\n ThreadStateTransition\n} THREAD_STATE, *PTHREAD_STATE;", "parent": 0, "children": [319, 320, 338, 339], "start_point": {"row": 127, "column": 0}, "end_point": {"row": 135, "column": 31}}, {"id": 319, "type": "typedef", "text": "typedef", "parent": 318, "children": [], "start_point": {"row": 127, "column": 0}, "end_point": {"row": 127, "column": 7}}, {"id": 320, "type": "enum_specifier", "text": "enum _THREAD_STATE {\n ThreadStateInitialized,\n ThreadStateReady,\n ThreadStateRunning,\n ThreadStateStandby,\n ThreadStateTerminated,\n ThreadStateWaiting,\n ThreadStateTransition\n}", "parent": 318, "children": [321, 322, 323], "start_point": {"row": 127, "column": 8}, "end_point": {"row": 135, "column": 1}}, {"id": 321, "type": "enum", "text": "enum", "parent": 320, "children": [], "start_point": {"row": 127, "column": 8}, "end_point": {"row": 127, "column": 12}}, {"id": 322, "type": "type_identifier", "text": "_THREAD_STATE", "parent": 320, "children": [], "start_point": {"row": 127, "column": 13}, "end_point": {"row": 127, "column": 26}}, {"id": 323, "type": "enumerator_list", "text": "{\n ThreadStateInitialized,\n ThreadStateReady,\n ThreadStateRunning,\n ThreadStateStandby,\n ThreadStateTerminated,\n ThreadStateWaiting,\n ThreadStateTransition\n}", "parent": 320, "children": [324, 326, 328, 330, 332, 334, 336], "start_point": {"row": 127, "column": 27}, "end_point": {"row": 135, "column": 1}}, {"id": 324, "type": "enumerator", "text": "ThreadStateInitialized", "parent": 323, "children": [325], "start_point": {"row": 128, "column": 4}, "end_point": {"row": 128, "column": 26}}, {"id": 325, "type": "identifier", "text": "ThreadStateInitialized", "parent": 324, "children": [], "start_point": {"row": 128, "column": 4}, "end_point": {"row": 128, "column": 26}}, {"id": 326, "type": "enumerator", "text": "ThreadStateReady", "parent": 323, "children": [327], "start_point": {"row": 129, "column": 4}, "end_point": {"row": 129, "column": 20}}, {"id": 327, "type": "identifier", "text": "ThreadStateReady", "parent": 326, "children": [], "start_point": {"row": 129, "column": 4}, "end_point": {"row": 129, "column": 20}}, {"id": 328, "type": "enumerator", "text": "ThreadStateRunning", "parent": 323, "children": [329], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 22}}, {"id": 329, "type": "identifier", "text": "ThreadStateRunning", "parent": 328, "children": [], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 22}}, {"id": 330, "type": "enumerator", "text": "ThreadStateStandby", "parent": 323, "children": [331], "start_point": {"row": 131, "column": 4}, "end_point": {"row": 131, "column": 22}}, {"id": 331, "type": "identifier", "text": "ThreadStateStandby", "parent": 330, "children": [], "start_point": {"row": 131, "column": 4}, "end_point": {"row": 131, "column": 22}}, {"id": 332, "type": "enumerator", "text": "ThreadStateTerminated", "parent": 323, "children": [333], "start_point": {"row": 132, "column": 4}, "end_point": {"row": 132, "column": 25}}, {"id": 333, "type": "identifier", "text": "ThreadStateTerminated", "parent": 332, "children": [], "start_point": {"row": 132, "column": 4}, "end_point": {"row": 132, "column": 25}}, {"id": 334, "type": "enumerator", "text": "ThreadStateWaiting", "parent": 323, "children": [335], "start_point": {"row": 133, "column": 4}, "end_point": {"row": 133, "column": 22}}, {"id": 335, "type": "identifier", "text": "ThreadStateWaiting", "parent": 334, "children": [], "start_point": {"row": 133, "column": 4}, "end_point": {"row": 133, "column": 22}}, {"id": 336, "type": "enumerator", "text": "ThreadStateTransition", "parent": 323, "children": [337], "start_point": {"row": 134, "column": 4}, "end_point": {"row": 134, "column": 25}}, {"id": 337, "type": "identifier", "text": "ThreadStateTransition", "parent": 336, "children": [], "start_point": {"row": 134, "column": 4}, "end_point": {"row": 134, "column": 25}}, {"id": 338, "type": "type_identifier", "text": "THREAD_STATE", "parent": 318, "children": [], "start_point": {"row": 135, "column": 2}, "end_point": {"row": 135, "column": 14}}, {"id": 339, "type": "pointer_declarator", "text": "*PTHREAD_STATE", "parent": 318, "children": [340, 341], "start_point": {"row": 135, "column": 16}, "end_point": {"row": 135, "column": 30}}, {"id": 340, "type": "*", "text": "*", "parent": 339, "children": [], "start_point": {"row": 135, "column": 16}, "end_point": {"row": 135, "column": 17}}, {"id": 341, "type": "type_identifier", "text": "PTHREAD_STATE", "parent": 339, "children": [], "start_point": {"row": 135, "column": 17}, "end_point": {"row": 135, "column": 30}}, {"id": 342, "type": "type_definition", "text": "typedef enum _THREAD_WAIT_REASON {\n ThreadWaitReasonExecutive,\n ThreadWaitReasonFreePage,\n ThreadWaitReasonPageIn,\n ThreadWaitReasonPoolAllocation,\n ThreadWaitReasonDelayExecution,\n ThreadWaitReasonSuspended,\n ThreadWaitReasonUserRequest,\n ThreadWaitReasonWrExecutive,\n ThreadWaitReasonWrFreePage,\n ThreadWaitReasonWrPageIn,\n ThreadWaitReasonWrPoolAllocation,\n ThreadWaitReasonWrDelayExecution,\n ThreadWaitReasonWrSuspended,\n ThreadWaitReasonWrUserRequest,\n ThreadWaitReasonWrEventPairHigh,\n ThreadWaitReasonWrEventPairLow,\n ThreadWaitReasonWrLpcReceive,\n ThreadWaitReasonWrLpcReply,\n ThreadWaitReasonWrVirtualMemory,\n ThreadWaitReasonWrPageOut,\n ThreadWaitReasonMaximumWaitReason\n} THREAD_WAIT_REASON;", "parent": 0, "children": [343, 344, 390], "start_point": {"row": 137, "column": 0}, "end_point": {"row": 159, "column": 21}}, {"id": 343, "type": "typedef", "text": "typedef", "parent": 342, "children": [], "start_point": {"row": 137, "column": 0}, "end_point": {"row": 137, "column": 7}}, {"id": 344, "type": "enum_specifier", "text": "enum _THREAD_WAIT_REASON {\n ThreadWaitReasonExecutive,\n ThreadWaitReasonFreePage,\n ThreadWaitReasonPageIn,\n ThreadWaitReasonPoolAllocation,\n ThreadWaitReasonDelayExecution,\n ThreadWaitReasonSuspended,\n ThreadWaitReasonUserRequest,\n ThreadWaitReasonWrExecutive,\n ThreadWaitReasonWrFreePage,\n ThreadWaitReasonWrPageIn,\n ThreadWaitReasonWrPoolAllocation,\n ThreadWaitReasonWrDelayExecution,\n ThreadWaitReasonWrSuspended,\n ThreadWaitReasonWrUserRequest,\n ThreadWaitReasonWrEventPairHigh,\n ThreadWaitReasonWrEventPairLow,\n ThreadWaitReasonWrLpcReceive,\n ThreadWaitReasonWrLpcReply,\n ThreadWaitReasonWrVirtualMemory,\n ThreadWaitReasonWrPageOut,\n ThreadWaitReasonMaximumWaitReason\n}", "parent": 342, "children": [345, 346, 347], "start_point": {"row": 137, "column": 8}, "end_point": {"row": 159, "column": 1}}, {"id": 345, "type": "enum", "text": "enum", "parent": 344, "children": [], "start_point": {"row": 137, "column": 8}, "end_point": {"row": 137, "column": 12}}, {"id": 346, "type": "type_identifier", "text": "_THREAD_WAIT_REASON", "parent": 344, "children": [], "start_point": {"row": 137, "column": 13}, "end_point": {"row": 137, "column": 32}}, {"id": 347, "type": "enumerator_list", "text": "{\n ThreadWaitReasonExecutive,\n ThreadWaitReasonFreePage,\n ThreadWaitReasonPageIn,\n ThreadWaitReasonPoolAllocation,\n ThreadWaitReasonDelayExecution,\n ThreadWaitReasonSuspended,\n ThreadWaitReasonUserRequest,\n ThreadWaitReasonWrExecutive,\n ThreadWaitReasonWrFreePage,\n ThreadWaitReasonWrPageIn,\n ThreadWaitReasonWrPoolAllocation,\n ThreadWaitReasonWrDelayExecution,\n ThreadWaitReasonWrSuspended,\n ThreadWaitReasonWrUserRequest,\n ThreadWaitReasonWrEventPairHigh,\n ThreadWaitReasonWrEventPairLow,\n ThreadWaitReasonWrLpcReceive,\n ThreadWaitReasonWrLpcReply,\n ThreadWaitReasonWrVirtualMemory,\n ThreadWaitReasonWrPageOut,\n ThreadWaitReasonMaximumWaitReason\n}", "parent": 344, "children": [348, 350, 352, 354, 356, 358, 360, 362, 364, 366, 368, 370, 372, 374, 376, 378, 380, 382, 384, 386, 388], "start_point": {"row": 137, "column": 33}, "end_point": {"row": 159, "column": 1}}, {"id": 348, "type": "enumerator", "text": "ThreadWaitReasonExecutive", "parent": 347, "children": [349], "start_point": {"row": 138, "column": 4}, "end_point": {"row": 138, "column": 29}}, {"id": 349, "type": "identifier", "text": "ThreadWaitReasonExecutive", "parent": 348, "children": [], "start_point": {"row": 138, "column": 4}, "end_point": {"row": 138, "column": 29}}, {"id": 350, "type": "enumerator", "text": "ThreadWaitReasonFreePage", "parent": 347, "children": [351], "start_point": {"row": 139, "column": 4}, "end_point": {"row": 139, "column": 28}}, {"id": 351, "type": "identifier", "text": "ThreadWaitReasonFreePage", "parent": 350, "children": [], "start_point": {"row": 139, "column": 4}, "end_point": {"row": 139, "column": 28}}, {"id": 352, "type": "enumerator", "text": "ThreadWaitReasonPageIn", "parent": 347, "children": [353], "start_point": {"row": 140, "column": 4}, "end_point": {"row": 140, "column": 26}}, {"id": 353, "type": "identifier", "text": "ThreadWaitReasonPageIn", "parent": 352, "children": [], "start_point": {"row": 140, "column": 4}, "end_point": {"row": 140, "column": 26}}, {"id": 354, "type": "enumerator", "text": "ThreadWaitReasonPoolAllocation", "parent": 347, "children": [355], "start_point": {"row": 141, "column": 4}, "end_point": {"row": 141, "column": 34}}, {"id": 355, "type": "identifier", "text": "ThreadWaitReasonPoolAllocation", "parent": 354, "children": [], "start_point": {"row": 141, "column": 4}, "end_point": {"row": 141, "column": 34}}, {"id": 356, "type": "enumerator", "text": "ThreadWaitReasonDelayExecution", "parent": 347, "children": [357], "start_point": {"row": 142, "column": 4}, "end_point": {"row": 142, "column": 34}}, {"id": 357, "type": "identifier", "text": "ThreadWaitReasonDelayExecution", "parent": 356, "children": [], "start_point": {"row": 142, "column": 4}, "end_point": {"row": 142, "column": 34}}, {"id": 358, "type": "enumerator", "text": "ThreadWaitReasonSuspended", "parent": 347, "children": [359], "start_point": {"row": 143, "column": 4}, "end_point": {"row": 143, "column": 29}}, {"id": 359, "type": "identifier", "text": "ThreadWaitReasonSuspended", "parent": 358, "children": [], "start_point": {"row": 143, "column": 4}, "end_point": {"row": 143, "column": 29}}, {"id": 360, "type": "enumerator", "text": "ThreadWaitReasonUserRequest", "parent": 347, "children": [361], "start_point": {"row": 144, "column": 4}, "end_point": {"row": 144, "column": 31}}, {"id": 361, "type": "identifier", "text": "ThreadWaitReasonUserRequest", "parent": 360, "children": [], "start_point": {"row": 144, "column": 4}, "end_point": {"row": 144, "column": 31}}, {"id": 362, "type": "enumerator", "text": "ThreadWaitReasonWrExecutive", "parent": 347, "children": [363], "start_point": {"row": 145, "column": 4}, "end_point": {"row": 145, "column": 31}}, {"id": 363, "type": "identifier", "text": "ThreadWaitReasonWrExecutive", "parent": 362, "children": [], "start_point": {"row": 145, "column": 4}, "end_point": {"row": 145, "column": 31}}, {"id": 364, "type": "enumerator", "text": "ThreadWaitReasonWrFreePage", "parent": 347, "children": [365], "start_point": {"row": 146, "column": 4}, "end_point": {"row": 146, "column": 30}}, {"id": 365, "type": "identifier", "text": "ThreadWaitReasonWrFreePage", "parent": 364, "children": [], "start_point": {"row": 146, "column": 4}, "end_point": {"row": 146, "column": 30}}, {"id": 366, "type": "enumerator", "text": "ThreadWaitReasonWrPageIn", "parent": 347, "children": [367], "start_point": {"row": 147, "column": 4}, "end_point": {"row": 147, "column": 28}}, {"id": 367, "type": "identifier", "text": "ThreadWaitReasonWrPageIn", "parent": 366, "children": [], "start_point": {"row": 147, "column": 4}, "end_point": {"row": 147, "column": 28}}, {"id": 368, "type": "enumerator", "text": "ThreadWaitReasonWrPoolAllocation", "parent": 347, "children": [369], "start_point": {"row": 148, "column": 4}, "end_point": {"row": 148, "column": 36}}, {"id": 369, "type": "identifier", "text": "ThreadWaitReasonWrPoolAllocation", "parent": 368, "children": [], "start_point": {"row": 148, "column": 4}, "end_point": {"row": 148, "column": 36}}, {"id": 370, "type": "enumerator", "text": "ThreadWaitReasonWrDelayExecution", "parent": 347, "children": [371], "start_point": {"row": 149, "column": 4}, "end_point": {"row": 149, "column": 36}}, {"id": 371, "type": "identifier", "text": "ThreadWaitReasonWrDelayExecution", "parent": 370, "children": [], "start_point": {"row": 149, "column": 4}, "end_point": {"row": 149, "column": 36}}, {"id": 372, "type": "enumerator", "text": "ThreadWaitReasonWrSuspended", "parent": 347, "children": [373], "start_point": {"row": 150, "column": 4}, "end_point": {"row": 150, "column": 31}}, {"id": 373, "type": "identifier", "text": "ThreadWaitReasonWrSuspended", "parent": 372, "children": [], "start_point": {"row": 150, "column": 4}, "end_point": {"row": 150, "column": 31}}, {"id": 374, "type": "enumerator", "text": "ThreadWaitReasonWrUserRequest", "parent": 347, "children": [375], "start_point": {"row": 151, "column": 4}, "end_point": {"row": 151, "column": 33}}, {"id": 375, "type": "identifier", "text": "ThreadWaitReasonWrUserRequest", "parent": 374, "children": [], "start_point": {"row": 151, "column": 4}, "end_point": {"row": 151, "column": 33}}, {"id": 376, "type": "enumerator", "text": "ThreadWaitReasonWrEventPairHigh", "parent": 347, "children": [377], "start_point": {"row": 152, "column": 4}, "end_point": {"row": 152, "column": 35}}, {"id": 377, "type": "identifier", "text": "ThreadWaitReasonWrEventPairHigh", "parent": 376, "children": [], "start_point": {"row": 152, "column": 4}, "end_point": {"row": 152, "column": 35}}, {"id": 378, "type": "enumerator", "text": "ThreadWaitReasonWrEventPairLow", "parent": 347, "children": [379], "start_point": {"row": 153, "column": 4}, "end_point": {"row": 153, "column": 34}}, {"id": 379, "type": "identifier", "text": "ThreadWaitReasonWrEventPairLow", "parent": 378, "children": [], "start_point": {"row": 153, "column": 4}, "end_point": {"row": 153, "column": 34}}, {"id": 380, "type": "enumerator", "text": "ThreadWaitReasonWrLpcReceive", "parent": 347, "children": [381], "start_point": {"row": 154, "column": 4}, "end_point": {"row": 154, "column": 32}}, {"id": 381, "type": "identifier", "text": "ThreadWaitReasonWrLpcReceive", "parent": 380, "children": [], "start_point": {"row": 154, "column": 4}, "end_point": {"row": 154, "column": 32}}, {"id": 382, "type": "enumerator", "text": "ThreadWaitReasonWrLpcReply", "parent": 347, "children": [383], "start_point": {"row": 155, "column": 4}, "end_point": {"row": 155, "column": 30}}, {"id": 383, "type": "identifier", "text": "ThreadWaitReasonWrLpcReply", "parent": 382, "children": [], "start_point": {"row": 155, "column": 4}, "end_point": {"row": 155, "column": 30}}, {"id": 384, "type": "enumerator", "text": "ThreadWaitReasonWrVirtualMemory", "parent": 347, "children": [385], "start_point": {"row": 156, "column": 4}, "end_point": {"row": 156, "column": 35}}, {"id": 385, "type": "identifier", "text": "ThreadWaitReasonWrVirtualMemory", "parent": 384, "children": [], "start_point": {"row": 156, "column": 4}, "end_point": {"row": 156, "column": 35}}, {"id": 386, "type": "enumerator", "text": "ThreadWaitReasonWrPageOut", "parent": 347, "children": [387], "start_point": {"row": 157, "column": 4}, "end_point": {"row": 157, "column": 29}}, {"id": 387, "type": "identifier", "text": "ThreadWaitReasonWrPageOut", "parent": 386, "children": [], "start_point": {"row": 157, "column": 4}, "end_point": {"row": 157, "column": 29}}, {"id": 388, "type": "enumerator", "text": "ThreadWaitReasonMaximumWaitReason", "parent": 347, "children": [389], "start_point": {"row": 158, "column": 4}, "end_point": {"row": 158, "column": 37}}, {"id": 389, "type": "identifier", "text": "ThreadWaitReasonMaximumWaitReason", "parent": 388, "children": [], "start_point": {"row": 158, "column": 4}, "end_point": {"row": 158, "column": 37}}, {"id": 390, "type": "type_identifier", "text": "THREAD_WAIT_REASON", "parent": 342, "children": [], "start_point": {"row": 159, "column": 2}, "end_point": {"row": 159, "column": 20}}, {"id": 391, "type": "preproc_ifdef", "text": "#ifndef _DELAY_IMP_VER\n\n#define FACILITY_VISUALCPP ((LONG)0x6d)\n#define VcppException(sev,err) ((sev) | (FACILITY_VISUALCPP<<16) | err)\n\ntypedef DWORD RVA;\n\ntypedef struct ImgDelayDescr {\n DWORD grAttrs; // attributes\n RVA rvaDLLName; // RVA to dll name\n RVA rvaHmod; // RVA of module handle\n RVA rvaIAT; // RVA of the IAT\n RVA rvaINT; // RVA of the INT\n RVA rvaBoundIAT; // RVA of the optional bound IAT\n RVA rvaUnloadIAT; // RVA of optional copy of original IAT\n DWORD dwTimeStamp; // 0 if not bound,\n // O.W. date/time stamp of DLL bound to (Old BIND)\n} ImgDelayDescr, *PImgDelayDescr;\n\ntypedef const ImgDelayDescr *PCImgDelayDescr;\n\ntypedef struct DelayLoadProc {\n BOOL fImportByName;\n union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n };\n} DelayLoadProc;\n\ntypedef struct DelayLoadInfo {\n DWORD cb; // size of structure\n PCImgDelayDescr pidd; // raw form of data (everything is there)\n FARPROC * ppfn; // points to address of function to load\n LPCSTR szDll; // name of dll\n DelayLoadProc dlp; // name or ordinal of procedure\n HMODULE hmodCur; // the hInstance of the library we have loaded\n FARPROC pfnCur; // the actual function that will be called\n DWORD dwLastError;// error received (if an error notification)\n} DelayLoadInfo, * PDelayLoadInfo;\n\n#endif", "parent": 0, "children": [392, 393, 394, 398, 405, 409, 442, 448, 466, 501], "start_point": {"row": 163, "column": 0}, "end_point": {"row": 203, "column": 6}}, {"id": 392, "type": "#ifndef", "text": "#ifndef", "parent": 391, "children": [], "start_point": {"row": 163, "column": 0}, "end_point": {"row": 163, "column": 7}}, {"id": 393, "type": "identifier", "text": "_DELAY_IMP_VER", "parent": 391, "children": [], "start_point": {"row": 163, "column": 8}, "end_point": {"row": 163, "column": 22}}, {"id": 394, "type": "preproc_def", "text": "#define FACILITY_VISUALCPP ((LONG)0x6d)\n", "parent": 391, "children": [395, 396, 397], "start_point": {"row": 165, "column": 0}, "end_point": {"row": 166, "column": 0}}, {"id": 395, "type": "#define", "text": "#define", "parent": 394, "children": [], "start_point": {"row": 165, "column": 0}, "end_point": {"row": 165, "column": 7}}, {"id": 396, "type": "identifier", "text": "FACILITY_VISUALCPP", "parent": 394, "children": [], "start_point": {"row": 165, "column": 8}, "end_point": {"row": 165, "column": 26}}, {"id": 397, "type": "preproc_arg", "text": "((LONG)0x6d)", "parent": 394, "children": [], "start_point": {"row": 165, "column": 28}, "end_point": {"row": 165, "column": 40}}, {"id": 398, "type": "preproc_function_def", "text": "#define VcppException(sev,err) ((sev) | (FACILITY_VISUALCPP<<16) | err)\n", "parent": 391, "children": [399, 400, 401, 404], "start_point": {"row": 166, "column": 0}, "end_point": {"row": 167, "column": 0}}, {"id": 399, "type": "#define", "text": "#define", "parent": 398, "children": [], "start_point": {"row": 166, "column": 0}, "end_point": {"row": 166, "column": 7}}, {"id": 400, "type": "identifier", "text": "VcppException", "parent": 398, "children": [], "start_point": {"row": 166, "column": 8}, "end_point": {"row": 166, "column": 21}}, {"id": 401, "type": "preproc_params", "text": "(sev,err)", "parent": 398, "children": [402, 403], "start_point": {"row": 166, "column": 21}, "end_point": {"row": 166, "column": 30}}, {"id": 402, "type": "identifier", "text": "sev", "parent": 401, "children": [], "start_point": {"row": 166, "column": 22}, "end_point": {"row": 166, "column": 25}}, {"id": 403, "type": "identifier", "text": "err", "parent": 401, "children": [], "start_point": {"row": 166, "column": 26}, "end_point": {"row": 166, "column": 29}}, {"id": 404, "type": "preproc_arg", "text": "((sev) | (FACILITY_VISUALCPP<<16) | err)", "parent": 398, "children": [], "start_point": {"row": 166, "column": 32}, "end_point": {"row": 166, "column": 72}}, {"id": 405, "type": "type_definition", "text": "typedef DWORD RVA;", "parent": 391, "children": [406, 407, 408], "start_point": {"row": 168, "column": 0}, "end_point": {"row": 168, "column": 19}}, {"id": 406, "type": "typedef", "text": "typedef", "parent": 405, "children": [], "start_point": {"row": 168, "column": 0}, "end_point": {"row": 168, "column": 7}}, {"id": 407, "type": "type_identifier", "text": "DWORD", "parent": 405, "children": [], "start_point": {"row": 168, "column": 8}, "end_point": {"row": 168, "column": 13}}, {"id": 408, "type": "type_identifier", "text": "RVA", "parent": 405, "children": [], "start_point": {"row": 168, "column": 15}, "end_point": {"row": 168, "column": 18}}, {"id": 409, "type": "type_definition", "text": "typedef struct ImgDelayDescr {\n DWORD grAttrs; // attributes\n RVA rvaDLLName; // RVA to dll name\n RVA rvaHmod; // RVA of module handle\n RVA rvaIAT; // RVA of the IAT\n RVA rvaINT; // RVA of the INT\n RVA rvaBoundIAT; // RVA of the optional bound IAT\n RVA rvaUnloadIAT; // RVA of optional copy of original IAT\n DWORD dwTimeStamp; // 0 if not bound,\n // O.W. date/time stamp of DLL bound to (Old BIND)\n} ImgDelayDescr, *PImgDelayDescr;", "parent": 391, "children": [410, 411, 438, 439], "start_point": {"row": 170, "column": 0}, "end_point": {"row": 180, "column": 33}}, {"id": 410, "type": "typedef", "text": "typedef", "parent": 409, "children": [], "start_point": {"row": 170, "column": 0}, "end_point": {"row": 170, "column": 7}}, {"id": 411, "type": "struct_specifier", "text": "struct ImgDelayDescr {\n DWORD grAttrs; // attributes\n RVA rvaDLLName; // RVA to dll name\n RVA rvaHmod; // RVA of module handle\n RVA rvaIAT; // RVA of the IAT\n RVA rvaINT; // RVA of the INT\n RVA rvaBoundIAT; // RVA of the optional bound IAT\n RVA rvaUnloadIAT; // RVA of optional copy of original IAT\n DWORD dwTimeStamp; // 0 if not bound,\n // O.W. date/time stamp of DLL bound to (Old BIND)\n}", "parent": 409, "children": [412, 413], "start_point": {"row": 170, "column": 8}, "end_point": {"row": 180, "column": 1}}, {"id": 412, "type": "struct", "text": "struct", "parent": 411, "children": [], "start_point": {"row": 170, "column": 8}, "end_point": {"row": 170, "column": 14}}, {"id": 413, "type": "type_identifier", "text": "ImgDelayDescr", "parent": 411, "children": [], "start_point": {"row": 170, "column": 15}, "end_point": {"row": 170, "column": 28}}, {"id": 414, "type": "field_declaration", "text": "DWORD grAttrs;", "parent": 411, "children": [415, 416], "start_point": {"row": 171, "column": 4}, "end_point": {"row": 171, "column": 28}}, {"id": 415, "type": "type_identifier", "text": "DWORD", "parent": 414, "children": [], "start_point": {"row": 171, "column": 4}, "end_point": {"row": 171, "column": 9}}, {"id": 416, "type": "field_identifier", "text": "grAttrs", "parent": 414, "children": [], "start_point": {"row": 171, "column": 20}, "end_point": {"row": 171, "column": 27}}, {"id": 417, "type": "field_declaration", "text": "RVA rvaDLLName;", "parent": 411, "children": [418, 419], "start_point": {"row": 172, "column": 4}, "end_point": {"row": 172, "column": 31}}, {"id": 418, "type": "type_identifier", "text": "RVA", "parent": 417, "children": [], "start_point": {"row": 172, "column": 4}, "end_point": {"row": 172, "column": 7}}, {"id": 419, "type": "field_identifier", "text": "rvaDLLName", "parent": 417, "children": [], "start_point": {"row": 172, "column": 20}, "end_point": {"row": 172, "column": 30}}, {"id": 420, "type": "field_declaration", "text": "RVA rvaHmod;", "parent": 411, "children": [421, 422], "start_point": {"row": 173, "column": 4}, "end_point": {"row": 173, "column": 28}}, {"id": 421, "type": "type_identifier", "text": "RVA", "parent": 420, "children": [], "start_point": {"row": 173, "column": 4}, "end_point": {"row": 173, "column": 7}}, {"id": 422, "type": "field_identifier", "text": "rvaHmod", "parent": 420, "children": [], "start_point": {"row": 173, "column": 20}, "end_point": {"row": 173, "column": 27}}, {"id": 423, "type": "field_declaration", "text": "RVA rvaIAT;", "parent": 411, "children": [424, 425], "start_point": {"row": 174, "column": 4}, "end_point": {"row": 174, "column": 27}}, {"id": 424, "type": "type_identifier", "text": "RVA", "parent": 423, "children": [], "start_point": {"row": 174, "column": 4}, "end_point": {"row": 174, "column": 7}}, {"id": 425, "type": "field_identifier", "text": "rvaIAT", "parent": 423, "children": [], "start_point": {"row": 174, "column": 20}, "end_point": {"row": 174, "column": 26}}, {"id": 426, "type": "field_declaration", "text": "RVA rvaINT;", "parent": 411, "children": [427, 428], "start_point": {"row": 175, "column": 4}, "end_point": {"row": 175, "column": 27}}, {"id": 427, "type": "type_identifier", "text": "RVA", "parent": 426, "children": [], "start_point": {"row": 175, "column": 4}, "end_point": {"row": 175, "column": 7}}, {"id": 428, "type": "field_identifier", "text": "rvaINT", "parent": 426, "children": [], "start_point": {"row": 175, "column": 20}, "end_point": {"row": 175, "column": 26}}, {"id": 429, "type": "field_declaration", "text": "RVA rvaBoundIAT;", "parent": 411, "children": [430, 431], "start_point": {"row": 176, "column": 4}, "end_point": {"row": 176, "column": 32}}, {"id": 430, "type": "type_identifier", "text": "RVA", "parent": 429, "children": [], "start_point": {"row": 176, "column": 4}, "end_point": {"row": 176, "column": 7}}, {"id": 431, "type": "field_identifier", "text": "rvaBoundIAT", "parent": 429, "children": [], "start_point": {"row": 176, "column": 20}, "end_point": {"row": 176, "column": 31}}, {"id": 432, "type": "field_declaration", "text": "RVA rvaUnloadIAT;", "parent": 411, "children": [433, 434], "start_point": {"row": 177, "column": 4}, "end_point": {"row": 177, "column": 33}}, {"id": 433, "type": "type_identifier", "text": "RVA", "parent": 432, "children": [], "start_point": {"row": 177, "column": 4}, "end_point": {"row": 177, "column": 7}}, {"id": 434, "type": "field_identifier", "text": "rvaUnloadIAT", "parent": 432, "children": [], "start_point": {"row": 177, "column": 20}, "end_point": {"row": 177, "column": 32}}, {"id": 435, "type": "field_declaration", "text": "DWORD dwTimeStamp;", "parent": 411, "children": [436, 437], "start_point": {"row": 178, "column": 4}, "end_point": {"row": 178, "column": 32}}, {"id": 436, "type": "type_identifier", "text": "DWORD", "parent": 435, "children": [], "start_point": {"row": 178, "column": 4}, "end_point": {"row": 178, "column": 9}}, {"id": 437, "type": "field_identifier", "text": "dwTimeStamp", "parent": 435, "children": [], "start_point": {"row": 178, "column": 20}, "end_point": {"row": 178, "column": 31}}, {"id": 438, "type": "type_identifier", "text": "ImgDelayDescr", "parent": 409, "children": [], "start_point": {"row": 180, "column": 2}, "end_point": {"row": 180, "column": 15}}, {"id": 439, "type": "pointer_declarator", "text": "*PImgDelayDescr", "parent": 409, "children": [440, 441], "start_point": {"row": 180, "column": 17}, "end_point": {"row": 180, "column": 32}}, {"id": 440, "type": "*", "text": "*", "parent": 439, "children": [], "start_point": {"row": 180, "column": 17}, "end_point": {"row": 180, "column": 18}}, {"id": 441, "type": "type_identifier", "text": "PImgDelayDescr", "parent": 439, "children": [], "start_point": {"row": 180, "column": 18}, "end_point": {"row": 180, "column": 32}}, {"id": 442, "type": "type_definition", "text": "typedef const ImgDelayDescr *PCImgDelayDescr;", "parent": 391, "children": [443, 444, 445], "start_point": {"row": 182, "column": 0}, "end_point": {"row": 182, "column": 45}}, {"id": 443, "type": "typedef", "text": "typedef", "parent": 442, "children": [], "start_point": {"row": 182, "column": 0}, "end_point": {"row": 182, "column": 7}}, {"id": 444, "type": "type_identifier", "text": "ImgDelayDescr", "parent": 442, "children": [], "start_point": {"row": 182, "column": 14}, "end_point": {"row": 182, "column": 27}}, {"id": 445, "type": "pointer_declarator", "text": "*PCImgDelayDescr", "parent": 442, "children": [446, 447], "start_point": {"row": 182, "column": 28}, "end_point": {"row": 182, "column": 44}}, {"id": 446, "type": "*", "text": "*", "parent": 445, "children": [], "start_point": {"row": 182, "column": 28}, "end_point": {"row": 182, "column": 29}}, {"id": 447, "type": "type_identifier", "text": "PCImgDelayDescr", "parent": 445, "children": [], "start_point": {"row": 182, "column": 29}, "end_point": {"row": 182, "column": 44}}, {"id": 448, "type": "type_definition", "text": "typedef struct DelayLoadProc {\n BOOL fImportByName;\n union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n };\n} DelayLoadProc;", "parent": 391, "children": [449, 450, 465], "start_point": {"row": 184, "column": 0}, "end_point": {"row": 190, "column": 16}}, {"id": 449, "type": "typedef", "text": "typedef", "parent": 448, "children": [], "start_point": {"row": 184, "column": 0}, "end_point": {"row": 184, "column": 7}}, {"id": 450, "type": "struct_specifier", "text": "struct DelayLoadProc {\n BOOL fImportByName;\n union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n };\n}", "parent": 448, "children": [451, 452], "start_point": {"row": 184, "column": 8}, "end_point": {"row": 190, "column": 1}}, {"id": 451, "type": "struct", "text": "struct", "parent": 450, "children": [], "start_point": {"row": 184, "column": 8}, "end_point": {"row": 184, "column": 14}}, {"id": 452, "type": "type_identifier", "text": "DelayLoadProc", "parent": 450, "children": [], "start_point": {"row": 184, "column": 15}, "end_point": {"row": 184, "column": 28}}, {"id": 453, "type": "field_declaration", "text": "BOOL fImportByName;", "parent": 450, "children": [454, 455], "start_point": {"row": 185, "column": 4}, "end_point": {"row": 185, "column": 38}}, {"id": 454, "type": "type_identifier", "text": "BOOL", "parent": 453, "children": [], "start_point": {"row": 185, "column": 4}, "end_point": {"row": 185, "column": 8}}, {"id": 455, "type": "field_identifier", "text": "fImportByName", "parent": 453, "children": [], "start_point": {"row": 185, "column": 24}, "end_point": {"row": 185, "column": 37}}, {"id": 456, "type": "field_declaration", "text": "union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n };", "parent": 450, "children": [457], "start_point": {"row": 186, "column": 4}, "end_point": {"row": 189, "column": 10}}, {"id": 457, "type": "union_specifier", "text": "union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n }", "parent": 456, "children": [458], "start_point": {"row": 186, "column": 4}, "end_point": {"row": 189, "column": 9}}, {"id": 458, "type": "union", "text": "union", "parent": 457, "children": [], "start_point": {"row": 186, "column": 4}, "end_point": {"row": 186, "column": 9}}, {"id": 459, "type": "field_declaration", "text": "LPCSTR szProcName;", "parent": 457, "children": [460, 461], "start_point": {"row": 187, "column": 8}, "end_point": {"row": 187, "column": 35}}, {"id": 460, "type": "type_identifier", "text": "LPCSTR", "parent": 459, "children": [], "start_point": {"row": 187, "column": 8}, "end_point": {"row": 187, "column": 14}}, {"id": 461, "type": "field_identifier", "text": "szProcName", "parent": 459, "children": [], "start_point": {"row": 187, "column": 24}, "end_point": {"row": 187, "column": 34}}, {"id": 462, "type": "field_declaration", "text": "DWORD dwOrdinal;", "parent": 457, "children": [463, 464], "start_point": {"row": 188, "column": 8}, "end_point": {"row": 188, "column": 34}}, {"id": 463, "type": "type_identifier", "text": "DWORD", "parent": 462, "children": [], "start_point": {"row": 188, "column": 8}, "end_point": {"row": 188, "column": 13}}, {"id": 464, "type": "field_identifier", "text": "dwOrdinal", "parent": 462, "children": [], "start_point": {"row": 188, "column": 24}, "end_point": {"row": 188, "column": 33}}, {"id": 465, "type": "type_identifier", "text": "DelayLoadProc", "parent": 448, "children": [], "start_point": {"row": 190, "column": 2}, "end_point": {"row": 190, "column": 15}}, {"id": 466, "type": "type_definition", "text": "typedef struct DelayLoadInfo {\n DWORD cb; // size of structure\n PCImgDelayDescr pidd; // raw form of data (everything is there)\n FARPROC * ppfn; // points to address of function to load\n LPCSTR szDll; // name of dll\n DelayLoadProc dlp; // name or ordinal of procedure\n HMODULE hmodCur; // the hInstance of the library we have loaded\n FARPROC pfnCur; // the actual function that will be called\n DWORD dwLastError;// error received (if an error notification)\n} DelayLoadInfo, * PDelayLoadInfo;", "parent": 391, "children": [467, 468, 497, 498], "start_point": {"row": 192, "column": 0}, "end_point": {"row": 201, "column": 34}}, {"id": 467, "type": "typedef", "text": "typedef", "parent": 466, "children": [], "start_point": {"row": 192, "column": 0}, "end_point": {"row": 192, "column": 7}}, {"id": 468, "type": "struct_specifier", "text": "struct DelayLoadInfo {\n DWORD cb; // size of structure\n PCImgDelayDescr pidd; // raw form of data (everything is there)\n FARPROC * ppfn; // points to address of function to load\n LPCSTR szDll; // name of dll\n DelayLoadProc dlp; // name or ordinal of procedure\n HMODULE hmodCur; // the hInstance of the library we have loaded\n FARPROC pfnCur; // the actual function that will be called\n DWORD dwLastError;// error received (if an error notification)\n}", "parent": 466, "children": [469, 470], "start_point": {"row": 192, "column": 8}, "end_point": {"row": 201, "column": 1}}, {"id": 469, "type": "struct", "text": "struct", "parent": 468, "children": [], "start_point": {"row": 192, "column": 8}, "end_point": {"row": 192, "column": 14}}, {"id": 470, "type": "type_identifier", "text": "DelayLoadInfo", "parent": 468, "children": [], "start_point": {"row": 192, "column": 15}, "end_point": {"row": 192, "column": 28}}, {"id": 471, "type": "field_declaration", "text": "DWORD cb;", "parent": 468, "children": [472, 473], "start_point": {"row": 193, "column": 4}, "end_point": {"row": 193, "column": 27}}, {"id": 472, "type": "type_identifier", "text": "DWORD", "parent": 471, "children": [], "start_point": {"row": 193, "column": 4}, "end_point": {"row": 193, "column": 9}}, {"id": 473, "type": "field_identifier", "text": "cb", "parent": 471, "children": [], "start_point": {"row": 193, "column": 24}, "end_point": {"row": 193, "column": 26}}, {"id": 474, "type": "field_declaration", "text": "PCImgDelayDescr pidd;", "parent": 468, "children": [475, 476], "start_point": {"row": 194, "column": 4}, "end_point": {"row": 194, "column": 29}}, {"id": 475, "type": "type_identifier", "text": "PCImgDelayDescr", "parent": 474, "children": [], "start_point": {"row": 194, "column": 4}, "end_point": {"row": 194, "column": 19}}, {"id": 476, "type": "field_identifier", "text": "pidd", "parent": 474, "children": [], "start_point": {"row": 194, "column": 24}, "end_point": {"row": 194, "column": 28}}, {"id": 477, "type": "field_declaration", "text": "FARPROC * ppfn;", "parent": 468, "children": [478, 479], "start_point": {"row": 195, "column": 4}, "end_point": {"row": 195, "column": 29}}, {"id": 478, "type": "type_identifier", "text": "FARPROC", "parent": 477, "children": [], "start_point": {"row": 195, "column": 4}, "end_point": {"row": 195, "column": 11}}, {"id": 479, "type": "pointer_declarator", "text": "* ppfn", "parent": 477, "children": [480, 481], "start_point": {"row": 195, "column": 12}, "end_point": {"row": 195, "column": 28}}, {"id": 480, "type": "*", "text": "*", "parent": 479, "children": [], "start_point": {"row": 195, "column": 12}, "end_point": {"row": 195, "column": 13}}, {"id": 481, "type": "field_identifier", "text": "ppfn", "parent": 479, "children": [], "start_point": {"row": 195, "column": 24}, "end_point": {"row": 195, "column": 28}}, {"id": 482, "type": "field_declaration", "text": "LPCSTR szDll;", "parent": 468, "children": [483, 484], "start_point": {"row": 196, "column": 4}, "end_point": {"row": 196, "column": 30}}, {"id": 483, "type": "type_identifier", "text": "LPCSTR", "parent": 482, "children": [], "start_point": {"row": 196, "column": 4}, "end_point": {"row": 196, "column": 10}}, {"id": 484, "type": "field_identifier", "text": "szDll", "parent": 482, "children": [], "start_point": {"row": 196, "column": 24}, "end_point": {"row": 196, "column": 29}}, {"id": 485, "type": "field_declaration", "text": "DelayLoadProc dlp;", "parent": 468, "children": [486, 487], "start_point": {"row": 197, "column": 4}, "end_point": {"row": 197, "column": 28}}, {"id": 486, "type": "type_identifier", "text": "DelayLoadProc", "parent": 485, "children": [], "start_point": {"row": 197, "column": 4}, "end_point": {"row": 197, "column": 17}}, {"id": 487, "type": "field_identifier", "text": "dlp", "parent": 485, "children": [], "start_point": {"row": 197, "column": 24}, "end_point": {"row": 197, "column": 27}}, {"id": 488, "type": "field_declaration", "text": "HMODULE hmodCur;", "parent": 468, "children": [489, 490], "start_point": {"row": 198, "column": 4}, "end_point": {"row": 198, "column": 32}}, {"id": 489, "type": "type_identifier", "text": "HMODULE", "parent": 488, "children": [], "start_point": {"row": 198, "column": 4}, "end_point": {"row": 198, "column": 11}}, {"id": 490, "type": "field_identifier", "text": "hmodCur", "parent": 488, "children": [], "start_point": {"row": 198, "column": 24}, "end_point": {"row": 198, "column": 31}}, {"id": 491, "type": "field_declaration", "text": "FARPROC pfnCur;", "parent": 468, "children": [492, 493], "start_point": {"row": 199, "column": 4}, "end_point": {"row": 199, "column": 31}}, {"id": 492, "type": "type_identifier", "text": "FARPROC", "parent": 491, "children": [], "start_point": {"row": 199, "column": 4}, "end_point": {"row": 199, "column": 11}}, {"id": 493, "type": "field_identifier", "text": "pfnCur", "parent": 491, "children": [], "start_point": {"row": 199, "column": 24}, "end_point": {"row": 199, "column": 30}}, {"id": 494, "type": "field_declaration", "text": "DWORD dwLastError;", "parent": 468, "children": [495, 496], "start_point": {"row": 200, "column": 4}, "end_point": {"row": 200, "column": 36}}, {"id": 495, "type": "type_identifier", "text": "DWORD", "parent": 494, "children": [], "start_point": {"row": 200, "column": 4}, "end_point": {"row": 200, "column": 9}}, {"id": 496, "type": "field_identifier", "text": "dwLastError", "parent": 494, "children": [], "start_point": {"row": 200, "column": 24}, "end_point": {"row": 200, "column": 35}}, {"id": 497, "type": "type_identifier", "text": "DelayLoadInfo", "parent": 466, "children": [], "start_point": {"row": 201, "column": 2}, "end_point": {"row": 201, "column": 15}}, {"id": 498, "type": "pointer_declarator", "text": "* PDelayLoadInfo", "parent": 466, "children": [499, 500], "start_point": {"row": 201, "column": 17}, "end_point": {"row": 201, "column": 33}}, {"id": 499, "type": "*", "text": "*", "parent": 498, "children": [], "start_point": {"row": 201, "column": 17}, "end_point": {"row": 201, "column": 18}}, {"id": 500, "type": "type_identifier", "text": "PDelayLoadInfo", "parent": 498, "children": [], "start_point": {"row": 201, "column": 19}, "end_point": {"row": 201, "column": 33}}, {"id": 501, "type": "#endif", "text": "#endif", "parent": 391, "children": [], "start_point": {"row": 203, "column": 0}, "end_point": {"row": 203, "column": 6}}, {"id": 502, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 205, "column": 0}, "end_point": {"row": 205, "column": 6}}]}, "node_categories": {"declarations": {"functions": [9, 398], "variables": [23, 27, 31, 36, 39, 43, 48, 51, 54, 58, 66, 69, 72, 75, 78, 81, 84, 87, 90, 93, 96, 101, 104, 107, 110, 113, 116, 119, 122, 125, 128, 131, 136, 141, 144, 147, 150, 153, 156, 159, 162, 165, 168, 171, 178, 183, 186, 189, 194, 197, 200, 203, 206, 209, 212, 215, 218, 223, 226, 235, 240, 243, 246, 251, 254, 257, 260, 263, 269, 272, 275, 278, 281, 288, 291, 295, 298, 303, 306, 309, 318, 342, 405, 409, 414, 417, 420, 423, 426, 429, 432, 435, 442, 448, 453, 456, 459, 462, 466, 471, 474, 477, 482, 485, 488, 491, 494], "classes": [33, 34, 45, 46, 60, 61, 138, 139, 180, 181, 237, 238, 411, 412, 450, 451, 457, 458, 468, 469], "imports": [6, 7], "modules": [], "enums": [320, 321, 323, 324, 326, 328, 330, 332, 334, 336, 344, 345, 347, 348, 350, 352, 354, 356, 358, 360, 362, 364, 366, 368, 370, 372, 374, 376, 378, 380, 382, 384, 386, 388]}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 11, 13, 17, 21, 25, 26, 29, 30, 35, 37, 38, 40, 41, 42, 47, 49, 50, 52, 53, 55, 56, 57, 62, 63, 64, 65, 67, 68, 70, 71, 73, 74, 76, 77, 79, 80, 82, 83, 85, 86, 88, 89, 91, 92, 94, 95, 97, 98, 102, 103, 105, 106, 108, 109, 111, 112, 114, 115, 117, 118, 120, 121, 123, 124, 126, 127, 129, 130, 132, 133, 134, 135, 140, 142, 143, 145, 146, 148, 149, 151, 152, 154, 155, 157, 158, 160, 161, 163, 164, 166, 167, 169, 170, 172, 173, 174, 177, 182, 184, 185, 187, 188, 190, 192, 195, 196, 198, 199, 201, 202, 204, 205, 207, 208, 210, 211, 213, 214, 216, 217, 219, 221, 224, 225, 227, 229, 231, 234, 239, 241, 242, 244, 245, 247, 249, 252, 253, 255, 256, 258, 259, 261, 262, 264, 265, 266, 267, 268, 270, 271, 273, 274, 276, 277, 279, 280, 282, 283, 284, 285, 289, 290, 292, 293, 294, 296, 297, 299, 301, 304, 305, 307, 308, 310, 312, 314, 317, 322, 325, 327, 329, 331, 333, 335, 337, 338, 341, 346, 349, 351, 353, 355, 357, 359, 361, 363, 365, 367, 369, 371, 373, 375, 377, 379, 381, 383, 385, 387, 389, 390, 391, 392, 393, 396, 400, 402, 403, 407, 408, 413, 415, 416, 418, 419, 421, 422, 424, 425, 427, 428, 430, 431, 433, 434, 436, 437, 438, 441, 444, 447, 452, 454, 455, 460, 461, 463, 464, 465, 470, 472, 473, 475, 476, 478, 481, 483, 484, 486, 487, 489, 490, 492, 493, 495, 496, 497, 500, 501, 502], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [8, 193, 222, 230, 250, 302, 313], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 9, "universal_type": "function", "name": "unknown", "text_snippet": "#define NT_SUCCESS(Status) ((NTSTATUS)(Status) >= 0)\n"}, {"node_id": 398, "universal_type": "function", "name": "unknown", "text_snippet": "#define VcppException(sev,err) ((sev) | (FACILITY_VISUALCPP<<16) | err)\n"}], "class_declarations": [{"node_id": 33, "universal_type": "class", "name": "_CLIENT_ID", "text_snippet": "struct _CLIENT_ID {\n DWORD UniqueProcess;\n DWORD UniqueThread;\n}"}, {"node_id": 34, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 45, "universal_type": "class", "name": "_UNICODE_STRING", "text_snippet": "struct _UNICODE_STRING {\n USHORT Length;\n USHORT MaximumLength;\n PWSTR "}, {"node_id": 46, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 60, "universal_type": "class", "name": "_VM_COUNTERS", "text_snippet": "struct _VM_COUNTERS {\n#ifdef _WIN64\n// the following was inferred by painful reverse engineering\n\tSI"}, {"node_id": 61, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 138, "universal_type": "class", "name": "_SYSTEM_THREADS", "text_snippet": "struct _SYSTEM_THREADS {\n LARGE_INTEGER KernelTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEG"}, {"node_id": 139, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 180, "universal_type": "class", "name": "_SYSTEM_PROCESSES_NT4", "text_snippet": "struct _SYSTEM_PROCESSES_NT4 {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n "}, {"node_id": 181, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 237, "universal_type": "class", "name": "_SYSTEM_PROCESSES", "text_snippet": "struct _SYSTEM_PROCESSES {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n UL"}, {"node_id": 238, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 411, "universal_type": "class", "name": "ImgDelayDescr", "text_snippet": "struct ImgDelayDescr {\n DWORD grAttrs; // attributes\n RVA rvaDLLN"}, {"node_id": 412, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 450, "universal_type": "class", "name": "DelayLoadProc", "text_snippet": "struct DelayLoadProc {\n BOOL fImportByName;\n union {\n LPCSTR sz"}, {"node_id": 451, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 457, "universal_type": "class", "name": "{", "text_snippet": "union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n }"}, {"node_id": 458, "universal_type": "class", "name": "unknown", "text_snippet": "union"}, {"node_id": 468, "universal_type": "class", "name": "DelayLoadInfo", "text_snippet": "struct DelayLoadInfo {\n DWORD cb; // size of structure\n PCImgDelayDescr "}, {"node_id": 469, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": [{"node_id": 6, "text": "#include \"boinc_win.h\"\n"}, {"node_id": 7, "text": "#include"}]}, "original_source_code": "// This file is part of BOINC.\n// http://boinc.berkeley.edu\n// Copyright (C) 2008 University of California\n//\n// BOINC is free software; you can redistribute it and/or modify it\n// under the terms of the GNU Lesser General Public License\n// as published by the Free Software Foundation,\n// either version 3 of the License, or (at your option) any later version.\n//\n// BOINC is distributed in the hope that it will be useful,\n// but WITHOUT ANY WARRANTY; without even the implied warranty of\n// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n// See the GNU Lesser General Public License for more details.\n//\n// You should have received a copy of the GNU Lesser General Public License\n// along with BOINC. If not, see <http://www.gnu.org/licenses/>.\n\n#ifndef _BOINC_DIAGNOSTICS_WIN_\n#define _BOINC_DIAGNOSTICS_WIN_\n\n#include \"boinc_win.h\"\n\n#define NT_SUCCESS(Status) ((NTSTATUS)(Status) >= 0)\n#define STATUS_INFO_LENGTH_MISMATCH ((NTSTATUS)0xC0000004L)\n#define SystemProcessAndThreadInformation 5\n\ntypedef LONG NTSTATUS;\n\ntypedef LONG KPRIORITY;\n\ntypedef struct _CLIENT_ID {\n DWORD UniqueProcess;\n DWORD UniqueThread;\n} CLIENT_ID;\n\ntypedef struct _UNICODE_STRING {\n USHORT Length;\n USHORT MaximumLength;\n PWSTR Buffer;\n} UNICODE_STRING;\n\ntypedef struct _VM_COUNTERS {\n#ifdef _WIN64\n// the following was inferred by painful reverse engineering\n\tSIZE_T\t\t PeakVirtualSize;\t// not actually\n SIZE_T PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n SIZE_T VirtualSize;\t\t// not actually\n#else\n SIZE_T PeakVirtualSize;\n SIZE_T VirtualSize;\n ULONG PageFaultCount;\n SIZE_T PeakWorkingSetSize;\n SIZE_T WorkingSetSize;\n SIZE_T QuotaPeakPagedPoolUsage;\n SIZE_T QuotaPagedPoolUsage;\n SIZE_T QuotaPeakNonPagedPoolUsage;\n SIZE_T QuotaNonPagedPoolUsage;\n SIZE_T PagefileUsage;\n SIZE_T PeakPagefileUsage;\n#endif\n} VM_COUNTERS;\n\ntypedef struct _SYSTEM_THREADS {\n LARGE_INTEGER KernelTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER CreateTime;\n ULONG WaitTime;\n PVOID StartAddress;\n CLIENT_ID ClientId;\n KPRIORITY Priority;\n KPRIORITY BasePriority;\n ULONG ContextSwitchCount;\n LONG State;\n LONG WaitReason;\n} SYSTEM_THREADS, * PSYSTEM_THREADS;\n\ntypedef struct _SYSTEM_PROCESSES_NT4 {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n SYSTEM_THREADS Threads[1];\n} SYSTEM_PROCESSES_NT4, *PSYSTEM_PROCESSES_NT4;\n\ntypedef struct _SYSTEM_PROCESSES {\n ULONG NextEntryDelta;\n ULONG ThreadCount;\n ULONG Reserved1[6];\n LARGE_INTEGER CreateTime;\n LARGE_INTEGER UserTime;\n LARGE_INTEGER KernelTime;\n UNICODE_STRING ProcessName;\n KPRIORITY BasePriority;\n#ifdef _WIN64\n\tULONG pad1;\n ULONG ProcessId;\n\tULONG pad2;\n ULONG InheritedFromProcessId;\n\tULONG pad3, pad4, pad5;\n#else\n ULONG ProcessId;\n ULONG InheritedFromProcessId;\n#endif\n ULONG HandleCount;\n ULONG Reserved2[2];\n VM_COUNTERS VmCounters;\n IO_COUNTERS IoCounters;\n SYSTEM_THREADS Threads[1];\n} SYSTEM_PROCESSES, * PSYSTEM_PROCESSES;\n\ntypedef enum _THREAD_STATE {\n ThreadStateInitialized,\n ThreadStateReady,\n ThreadStateRunning,\n ThreadStateStandby,\n ThreadStateTerminated,\n ThreadStateWaiting,\n ThreadStateTransition\n} THREAD_STATE, *PTHREAD_STATE;\n\ntypedef enum _THREAD_WAIT_REASON {\n ThreadWaitReasonExecutive,\n ThreadWaitReasonFreePage,\n ThreadWaitReasonPageIn,\n ThreadWaitReasonPoolAllocation,\n ThreadWaitReasonDelayExecution,\n ThreadWaitReasonSuspended,\n ThreadWaitReasonUserRequest,\n ThreadWaitReasonWrExecutive,\n ThreadWaitReasonWrFreePage,\n ThreadWaitReasonWrPageIn,\n ThreadWaitReasonWrPoolAllocation,\n ThreadWaitReasonWrDelayExecution,\n ThreadWaitReasonWrSuspended,\n ThreadWaitReasonWrUserRequest,\n ThreadWaitReasonWrEventPairHigh,\n ThreadWaitReasonWrEventPairLow,\n ThreadWaitReasonWrLpcReceive,\n ThreadWaitReasonWrLpcReply,\n ThreadWaitReasonWrVirtualMemory,\n ThreadWaitReasonWrPageOut,\n ThreadWaitReasonMaximumWaitReason\n} THREAD_WAIT_REASON;\n\n\n// Delay Load Error Handling stuff\n#ifndef _DELAY_IMP_VER\n\n#define FACILITY_VISUALCPP ((LONG)0x6d)\n#define VcppException(sev,err) ((sev) | (FACILITY_VISUALCPP<<16) | err)\n\ntypedef DWORD RVA;\n\ntypedef struct ImgDelayDescr {\n DWORD grAttrs; // attributes\n RVA rvaDLLName; // RVA to dll name\n RVA rvaHmod; // RVA of module handle\n RVA rvaIAT; // RVA of the IAT\n RVA rvaINT; // RVA of the INT\n RVA rvaBoundIAT; // RVA of the optional bound IAT\n RVA rvaUnloadIAT; // RVA of optional copy of original IAT\n DWORD dwTimeStamp; // 0 if not bound,\n // O.W. date/time stamp of DLL bound to (Old BIND)\n} ImgDelayDescr, *PImgDelayDescr;\n\ntypedef const ImgDelayDescr *PCImgDelayDescr;\n\ntypedef struct DelayLoadProc {\n BOOL fImportByName;\n union {\n LPCSTR szProcName;\n DWORD dwOrdinal;\n };\n} DelayLoadProc;\n\ntypedef struct DelayLoadInfo {\n DWORD cb; // size of structure\n PCImgDelayDescr pidd; // raw form of data (everything is there)\n FARPROC * ppfn; // points to address of function to load\n LPCSTR szDll; // name of dll\n DelayLoadProc dlp; // name or ordinal of procedure\n HMODULE hmodCur; // the hInstance of the library we have loaded\n FARPROC pfnCur; // the actual function that will be called\n DWORD dwLastError;// error received (if an error notification)\n} DelayLoadInfo, * PDelayLoadInfo;\n\n#endif\n\n#endif\n"}
80,513
c
// // class.c // CObjects // // Created by <NAME> on 9/2/13. // Copyright (c) 2013 <NAME>. All rights reserved. // #define _XOPEN_SOURCE 700 #include <stdio.h> #include <stdlib.h> #include <string.h> #include <stdarg.h> #include <coassert.h> #include <errno.h> #include <Object.h> #include <Object.r> #include <new.h> static void * Class_constructor (void * _self, va_list * app) { struct Classs * self = _self; self->class_name = va_arg( *app, const char *); self->super = va_arg( *app, struct Classs *); self->size = va_arg( *app, UInteger); assert(self->super != NULL); const UInteger offset = sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *) + sizeof(UInteger); memcpy((char *)self + offset, (char *)(self->super) + offset, sizeOf((void *)self->super) - offset); { typedef void (*voidf) (); voidf selector = NULL; va_list ap; va_copy(ap, *app); while ( (selector = va_arg(ap, voidf)) ) { voidf method = va_arg(ap, voidf); if ( selector == (voidf) constructor ) * (voidf *) & self->constructor = method; else if ( selector == (voidf) destructor ) * (voidf *) & self->destructor = method; else if ( selector == (voidf) copy ) * (voidf *) & self->copy = method; else if ( selector == (voidf) equals ) * (voidf *) & self->equals = method; else if ( selector == (voidf) hash ) * (voidf *) & self->hash = method; else if ( selector == (voidf) retain ) * (voidf *) & self->retain = method; else if ( selector == (voidf) release ) * (voidf *) & self->release = method; else if ( selector == (voidf) retainCount ) * (voidf *) & self->retainCount = method; else if ( selector == (voidf) copyDescription ) * (voidf *) & self->copyDescription = method; else if ( selector == (voidf) autorelease ) * (voidf *) & self->autorelease = method; } va_end(ap); } return self; } static void * Class_destructor (void * _self) { return NULL; } static void * Class_copy (const void *const _self) { return NULL; } static UInteger Class_hash (const void *const self) { COAssertNoNullOrReturn(self,EINVAL,0); const struct Classs *const class = classOf(self); COAssertNoNullOrReturn(class,EINVAL,0); const struct Classs *const _superclass = superclass(self); COAssertNoNullOrReturn(_superclass,EINVAL,0); COAssertNoNullOrReturn(_superclass->hash,EINVAL,0); UInteger prime = 31; UInteger result = _superclass->hash(self); result = prime * result + (UInteger)strlen(class->class_name); result = prime * result + class->size; return result; } static void * Class_retain (void *const _self) { return NULL; } static void Class_release (void *const _self) { } static void *Class_autorelease (void *const _self) { return NULL; } static const struct Classs object [] = { { {object+1}, "Object", object, sizeof(struct Object), Object_constructor, Object_destructor, Object_copy, Object_equals, Object_hash, Object_copyDescription, Object_retain, Object_release, Object_retainCount, Object_autorelease, }, { {object+1}, "Class", object, sizeof(struct Classs), Class_constructor, Class_destructor, Class_copy, Object_equals, Class_hash, Object_copyDescription, Class_retain, Object_release, Object_retainCount, Class_autorelease, } }; const void *const Object = (const void * const)(object); const void *const Class = (const void * const )(object+1);
25.29
131
(translation_unit) "//\n// class.c\n// CObjects\n//\n// Created by <NAME> on 9/2/13.\n// Copyright (c) 2013 <NAME>. All rights reserved.\n//\n#define _XOPEN_SOURCE 700\n\n#include <stdio.h>\n#include <stdlib.h>\n#include <string.h>\n#include <stdarg.h>\n\n#include <coassert.h>\n#include <errno.h>\n\n#include <Object.h>\n#include <Object.r>\n#include <new.h>\n\n\nstatic void * Class_constructor (void * _self, va_list * app) {\n struct Classs * self = _self;\n \n self->class_name = va_arg( *app, const char *);\n self->super = va_arg( *app, struct Classs *);\n self->size = va_arg( *app, UInteger);\n \n assert(self->super != NULL);\n const UInteger offset = sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *) + sizeof(UInteger);\n memcpy((char *)self + offset, (char *)(self->super) + offset, sizeOf((void *)self->super) - offset);\n {\n typedef void (*voidf) ();\n voidf selector = NULL;\n va_list ap;\n va_copy(ap, *app);\n \n while ( (selector = va_arg(ap, voidf)) ) {\n voidf method = va_arg(ap, voidf);\n \n if ( selector == (voidf) constructor )\n * (voidf *) & self->constructor = method;\n else if ( selector == (voidf) destructor )\n * (voidf *) & self->destructor = method;\n \n else if ( selector == (voidf) copy )\n * (voidf *) & self->copy = method;\n else if ( selector == (voidf) equals )\n * (voidf *) & self->equals = method;\n \n else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;\n }\n va_end(ap);\n }\n \n return self;\n}\n\nstatic void * Class_destructor (void * _self) {\n return NULL;\n}\n\nstatic void * Class_copy (const void *const _self) {\n return NULL;\n}\n\nstatic UInteger Class_hash (const void *const self) {\n COAssertNoNullOrReturn(self,EINVAL,0);\n const struct Classs *const class = classOf(self);\n COAssertNoNullOrReturn(class,EINVAL,0);\n const struct Classs *const _superclass = superclass(self);\n COAssertNoNullOrReturn(_superclass,EINVAL,0);\n COAssertNoNullOrReturn(_superclass->hash,EINVAL,0);\n \n \n UInteger prime = 31;\n UInteger result = _superclass->hash(self);\n result = prime * result + (UInteger)strlen(class->class_name);\n result = prime * result + class->size;\n return result;\n}\nstatic void * Class_retain (void *const _self) {\n return NULL;\n}\n\nstatic void Class_release (void *const _self) {\n}\n\nstatic void *Class_autorelease (void *const _self) {\n return NULL;\n}\n\nstatic const struct Classs object [] = {\n { {object+1},\n "Object",\n object,\n sizeof(struct Object),\n Object_constructor,\n Object_destructor,\n Object_copy,\n Object_equals,\n Object_hash,\n Object_copyDescription,\n Object_retain,\n Object_release,\n Object_retainCount,\n Object_autorelease,\n },\n { {object+1},\n "Class",\n object,\n sizeof(struct Classs),\n Class_constructor,\n Class_destructor,\n Class_copy,\n Object_equals,\n Class_hash,\n Object_copyDescription,\n Class_retain,\n Object_release,\n Object_retainCount,\n Class_autorelease,\n }\n};\n\nconst void *const Object = (const void * const)(object);\nconst void *const Class = (const void * const )(object+1);\n\n\n\n" (comment) "//" (comment) "// class.c" (comment) "// CObjects" (comment) "//" (comment) "// Created by <NAME> on 9/2/13." (comment) "// Copyright (c) 2013 <NAME>. All rights reserved." (comment) "//" (preproc_def) "#define _XOPEN_SOURCE 700\n" (#define) "#define" (identifier) "_XOPEN_SOURCE" (preproc_arg) "700" (preproc_include) "#include <stdio.h>\n" (#include) "#include" (system_lib_string) "<stdio.h>" (preproc_include) "#include <stdlib.h>\n" (#include) "#include" (system_lib_string) "<stdlib.h>" (preproc_include) "#include <string.h>\n" (#include) "#include" (system_lib_string) "<string.h>" (preproc_include) "#include <stdarg.h>\n" (#include) "#include" (system_lib_string) "<stdarg.h>" (preproc_include) "#include <coassert.h>\n" (#include) "#include" (system_lib_string) "<coassert.h>" (preproc_include) "#include <errno.h>\n" (#include) "#include" (system_lib_string) "<errno.h>" (preproc_include) "#include <Object.h>\n" (#include) "#include" (system_lib_string) "<Object.h>" (preproc_include) "#include <Object.r>\n" (#include) "#include" (system_lib_string) "<Object.r>" (preproc_include) "#include <new.h>\n" (#include) "#include" (system_lib_string) "<new.h>" (function_definition) "static void * Class_constructor (void * _self, va_list * app) {\n struct Classs * self = _self;\n \n self->class_name = va_arg( *app, const char *);\n self->super = va_arg( *app, struct Classs *);\n self->size = va_arg( *app, UInteger);\n \n assert(self->super != NULL);\n const UInteger offset = sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *) + sizeof(UInteger);\n memcpy((char *)self + offset, (char *)(self->super) + offset, sizeOf((void *)self->super) - offset);\n {\n typedef void (*voidf) ();\n voidf selector = NULL;\n va_list ap;\n va_copy(ap, *app);\n \n while ( (selector = va_arg(ap, voidf)) ) {\n voidf method = va_arg(ap, voidf);\n \n if ( selector == (voidf) constructor )\n * (voidf *) & self->constructor = method;\n else if ( selector == (voidf) destructor )\n * (voidf *) & self->destructor = method;\n \n else if ( selector == (voidf) copy )\n * (voidf *) & self->copy = method;\n else if ( selector == (voidf) equals )\n * (voidf *) & self->equals = method;\n \n else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;\n }\n va_end(ap);\n }\n \n return self;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (pointer_declarator) "* Class_constructor (void * _self, va_list * app)" (*) "*" (function_declarator) "Class_constructor (void * _self, va_list * app)" (identifier) "Class_constructor" (parameter_list) "(void * _self, va_list * app)" (() "(" (parameter_declaration) "void * _self" (primitive_type) "void" (pointer_declarator) "* _self" (*) "*" (identifier) "_self" (,) "," (parameter_declaration) "va_list * app" (type_identifier) "va_list" (pointer_declarator) "* app" (*) "*" (identifier) "app" ()) ")" (compound_statement) "{\n struct Classs * self = _self;\n \n self->class_name = va_arg( *app, const char *);\n self->super = va_arg( *app, struct Classs *);\n self->size = va_arg( *app, UInteger);\n \n assert(self->super != NULL);\n const UInteger offset = sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *) + sizeof(UInteger);\n memcpy((char *)self + offset, (char *)(self->super) + offset, sizeOf((void *)self->super) - offset);\n {\n typedef void (*voidf) ();\n voidf selector = NULL;\n va_list ap;\n va_copy(ap, *app);\n \n while ( (selector = va_arg(ap, voidf)) ) {\n voidf method = va_arg(ap, voidf);\n \n if ( selector == (voidf) constructor )\n * (voidf *) & self->constructor = method;\n else if ( selector == (voidf) destructor )\n * (voidf *) & self->destructor = method;\n \n else if ( selector == (voidf) copy )\n * (voidf *) & self->copy = method;\n else if ( selector == (voidf) equals )\n * (voidf *) & self->equals = method;\n \n else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;\n }\n va_end(ap);\n }\n \n return self;\n}" ({) "{" (declaration) "struct Classs * self = _self;" (struct_specifier) "struct Classs" (struct) "struct" (type_identifier) "Classs" (init_declarator) "* self = _self" (pointer_declarator) "* self" (*) "*" (identifier) "self" (=) "=" (identifier) "_self" (;) ";" (expression_statement) "self->class_name = va_arg( *app, const char *);" (assignment_expression) "self->class_name = va_arg( *app, const char *)" (field_expression) "self->class_name" (identifier) "self" (->) "->" (field_identifier) "class_name" (=) "=" (call_expression) "va_arg( *app, const char *)" (identifier) "va_arg" (argument_list) "( *app, const char *)" (() "(" (pointer_expression) "*app" (*) "*" (identifier) "app" (,) "," (identifier) "const" (ERROR) "char *" (identifier) "char" (*) "*" ()) ")" (;) ";" (expression_statement) "self->super = va_arg( *app, struct Classs *);" (assignment_expression) "self->super = va_arg( *app, struct Classs *)" (field_expression) "self->super" (identifier) "self" (->) "->" (field_identifier) "super" (=) "=" (call_expression) "va_arg( *app, struct Classs *)" (identifier) "va_arg" (argument_list) "( *app, struct Classs *)" (() "(" (pointer_expression) "*app" (*) "*" (identifier) "app" (,) "," (identifier) "struct" (ERROR) "Classs *" (identifier) "Classs" (*) "*" ()) ")" (;) ";" (expression_statement) "self->size = va_arg( *app, UInteger);" (assignment_expression) "self->size = va_arg( *app, UInteger)" (field_expression) "self->size" (identifier) "self" (->) "->" (field_identifier) "size" (=) "=" (call_expression) "va_arg( *app, UInteger)" (identifier) "va_arg" (argument_list) "( *app, UInteger)" (() "(" (pointer_expression) "*app" (*) "*" (identifier) "app" (,) "," (identifier) "UInteger" ()) ")" (;) ";" (expression_statement) "assert(self->super != NULL);" (call_expression) "assert(self->super != NULL)" (identifier) "assert" (argument_list) "(self->super != NULL)" (() "(" (binary_expression) "self->super != NULL" (field_expression) "self->super" (identifier) "self" (->) "->" (field_identifier) "super" (!=) "!=" (null) "NULL" (NULL) "NULL" ()) ")" (;) ";" (declaration) "const UInteger offset = sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *) + sizeof(UInteger);" (type_qualifier) "const" (const) "const" (type_identifier) "UInteger" (init_declarator) "offset = sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *) + sizeof(UInteger)" (identifier) "offset" (=) "=" (binary_expression) "sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *) + sizeof(UInteger)" (binary_expression) "sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *)" (binary_expression) "sizeof(struct Object) + sizeof(char *)" (sizeof_expression) "sizeof(struct Object)" (sizeof) "sizeof" (() "(" (type_descriptor) "struct Object" (struct_specifier) "struct Object" (struct) "struct" (type_identifier) "Object" ()) ")" (+) "+" (sizeof_expression) "sizeof(char *)" (sizeof) "sizeof" (() "(" (type_descriptor) "char *" (primitive_type) "char" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (+) "+" (sizeof_expression) "sizeof(struct Class *)" (sizeof) "sizeof" (() "(" (type_descriptor) "struct Class *" (struct_specifier) "struct Class" (struct) "struct" (type_identifier) "Class" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (+) "+" (sizeof_expression) "sizeof(UInteger)" (sizeof) "sizeof" (parenthesized_expression) "(UInteger)" (() "(" (identifier) "UInteger" ()) ")" (;) ";" (expression_statement) "memcpy((char *)self + offset, (char *)(self->super) + offset, sizeOf((void *)self->super) - offset);" (call_expression) "memcpy((char *)self + offset, (char *)(self->super) + offset, sizeOf((void *)self->super) - offset)" (identifier) "memcpy" (argument_list) "((char *)self + offset, (char *)(self->super) + offset, sizeOf((void *)self->super) - offset)" (() "(" (binary_expression) "(char *)self + offset" (cast_expression) "(char *)self" (() "(" (type_descriptor) "char *" (primitive_type) "char" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "self" (+) "+" (identifier) "offset" (,) "," (binary_expression) "(char *)(self->super) + offset" (cast_expression) "(char *)(self->super)" (() "(" (type_descriptor) "char *" (primitive_type) "char" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (parenthesized_expression) "(self->super)" (() "(" (field_expression) "self->super" (identifier) "self" (->) "->" (field_identifier) "super" ()) ")" (+) "+" (identifier) "offset" (,) "," (binary_expression) "sizeOf((void *)self->super) - offset" (call_expression) "sizeOf((void *)self->super)" (identifier) "sizeOf" (argument_list) "((void *)self->super)" (() "(" (cast_expression) "(void *)self->super" (() "(" (type_descriptor) "void *" (primitive_type) "void" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (field_expression) "self->super" (identifier) "self" (->) "->" (field_identifier) "super" ()) ")" (-) "-" (identifier) "offset" ()) ")" (;) ";" (compound_statement) "{\n typedef void (*voidf) ();\n voidf selector = NULL;\n va_list ap;\n va_copy(ap, *app);\n \n while ( (selector = va_arg(ap, voidf)) ) {\n voidf method = va_arg(ap, voidf);\n \n if ( selector == (voidf) constructor )\n * (voidf *) & self->constructor = method;\n else if ( selector == (voidf) destructor )\n * (voidf *) & self->destructor = method;\n \n else if ( selector == (voidf) copy )\n * (voidf *) & self->copy = method;\n else if ( selector == (voidf) equals )\n * (voidf *) & self->equals = method;\n \n else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;\n }\n va_end(ap);\n }" ({) "{" (type_definition) "typedef void (*voidf) ();" (typedef) "typedef" (primitive_type) "void" (function_declarator) "(*voidf) ()" (parenthesized_declarator) "(*voidf)" (() "(" (pointer_declarator) "*voidf" (*) "*" (type_identifier) "voidf" ()) ")" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "voidf selector = NULL;" (type_identifier) "voidf" (init_declarator) "selector = NULL" (identifier) "selector" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (declaration) "va_list ap;" (type_identifier) "va_list" (identifier) "ap" (;) ";" (expression_statement) "va_copy(ap, *app);" (call_expression) "va_copy(ap, *app)" (identifier) "va_copy" (argument_list) "(ap, *app)" (() "(" (identifier) "ap" (,) "," (pointer_expression) "*app" (*) "*" (identifier) "app" ()) ")" (;) ";" (while_statement) "while ( (selector = va_arg(ap, voidf)) ) {\n voidf method = va_arg(ap, voidf);\n \n if ( selector == (voidf) constructor )\n * (voidf *) & self->constructor = method;\n else if ( selector == (voidf) destructor )\n * (voidf *) & self->destructor = method;\n \n else if ( selector == (voidf) copy )\n * (voidf *) & self->copy = method;\n else if ( selector == (voidf) equals )\n * (voidf *) & self->equals = method;\n \n else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;\n }" (while) "while" (parenthesized_expression) "( (selector = va_arg(ap, voidf)) )" (() "(" (parenthesized_expression) "(selector = va_arg(ap, voidf))" (() "(" (assignment_expression) "selector = va_arg(ap, voidf)" (identifier) "selector" (=) "=" (call_expression) "va_arg(ap, voidf)" (identifier) "va_arg" (argument_list) "(ap, voidf)" (() "(" (identifier) "ap" (,) "," (identifier) "voidf" ()) ")" ()) ")" ()) ")" (compound_statement) "{\n voidf method = va_arg(ap, voidf);\n \n if ( selector == (voidf) constructor )\n * (voidf *) & self->constructor = method;\n else if ( selector == (voidf) destructor )\n * (voidf *) & self->destructor = method;\n \n else if ( selector == (voidf) copy )\n * (voidf *) & self->copy = method;\n else if ( selector == (voidf) equals )\n * (voidf *) & self->equals = method;\n \n else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;\n }" ({) "{" (declaration) "voidf method = va_arg(ap, voidf);" (type_identifier) "voidf" (init_declarator) "method = va_arg(ap, voidf)" (identifier) "method" (=) "=" (call_expression) "va_arg(ap, voidf)" (identifier) "va_arg" (argument_list) "(ap, voidf)" (() "(" (identifier) "ap" (,) "," (identifier) "voidf" ()) ")" (;) ";" (if_statement) "if ( selector == (voidf) constructor )\n * (voidf *) & self->constructor = method;\n else if ( selector == (voidf) destructor )\n * (voidf *) & self->destructor = method;\n \n else if ( selector == (voidf) copy )\n * (voidf *) & self->copy = method;\n else if ( selector == (voidf) equals )\n * (voidf *) & self->equals = method;\n \n else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (if) "if" (parenthesized_expression) "( selector == (voidf) constructor )" (() "(" (binary_expression) "selector == (voidf) constructor" (identifier) "selector" (==) "==" (cast_expression) "(voidf) constructor" (() "(" (type_descriptor) "voidf" (type_identifier) "voidf" ()) ")" (identifier) "constructor" ()) ")" (expression_statement) "* (voidf *) & self->constructor = method;" (assignment_expression) "* (voidf *) & self->constructor = method" (pointer_expression) "* (voidf *) & self->constructor" (*) "*" (cast_expression) "(voidf *) & self->constructor" (() "(" (type_descriptor) "voidf *" (type_identifier) "voidf" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (pointer_expression) "& self->constructor" (&) "&" (field_expression) "self->constructor" (identifier) "self" (->) "->" (field_identifier) "constructor" (=) "=" (identifier) "method" (;) ";" (else_clause) "else if ( selector == (voidf) destructor )\n * (voidf *) & self->destructor = method;\n \n else if ( selector == (voidf) copy )\n * (voidf *) & self->copy = method;\n else if ( selector == (voidf) equals )\n * (voidf *) & self->equals = method;\n \n else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (else) "else" (if_statement) "if ( selector == (voidf) destructor )\n * (voidf *) & self->destructor = method;\n \n else if ( selector == (voidf) copy )\n * (voidf *) & self->copy = method;\n else if ( selector == (voidf) equals )\n * (voidf *) & self->equals = method;\n \n else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (if) "if" (parenthesized_expression) "( selector == (voidf) destructor )" (() "(" (binary_expression) "selector == (voidf) destructor" (identifier) "selector" (==) "==" (cast_expression) "(voidf) destructor" (() "(" (type_descriptor) "voidf" (type_identifier) "voidf" ()) ")" (identifier) "destructor" ()) ")" (expression_statement) "* (voidf *) & self->destructor = method;" (assignment_expression) "* (voidf *) & self->destructor = method" (pointer_expression) "* (voidf *) & self->destructor" (*) "*" (cast_expression) "(voidf *) & self->destructor" (() "(" (type_descriptor) "voidf *" (type_identifier) "voidf" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (pointer_expression) "& self->destructor" (&) "&" (field_expression) "self->destructor" (identifier) "self" (->) "->" (field_identifier) "destructor" (=) "=" (identifier) "method" (;) ";" (else_clause) "else if ( selector == (voidf) copy )\n * (voidf *) & self->copy = method;\n else if ( selector == (voidf) equals )\n * (voidf *) & self->equals = method;\n \n else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (else) "else" (if_statement) "if ( selector == (voidf) copy )\n * (voidf *) & self->copy = method;\n else if ( selector == (voidf) equals )\n * (voidf *) & self->equals = method;\n \n else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (if) "if" (parenthesized_expression) "( selector == (voidf) copy )" (() "(" (binary_expression) "selector == (voidf) copy" (identifier) "selector" (==) "==" (cast_expression) "(voidf) copy" (() "(" (type_descriptor) "voidf" (type_identifier) "voidf" ()) ")" (identifier) "copy" ()) ")" (expression_statement) "* (voidf *) & self->copy = method;" (assignment_expression) "* (voidf *) & self->copy = method" (pointer_expression) "* (voidf *) & self->copy" (*) "*" (cast_expression) "(voidf *) & self->copy" (() "(" (type_descriptor) "voidf *" (type_identifier) "voidf" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (pointer_expression) "& self->copy" (&) "&" (field_expression) "self->copy" (identifier) "self" (->) "->" (field_identifier) "copy" (=) "=" (identifier) "method" (;) ";" (else_clause) "else if ( selector == (voidf) equals )\n * (voidf *) & self->equals = method;\n \n else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (else) "else" (if_statement) "if ( selector == (voidf) equals )\n * (voidf *) & self->equals = method;\n \n else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (if) "if" (parenthesized_expression) "( selector == (voidf) equals )" (() "(" (binary_expression) "selector == (voidf) equals" (identifier) "selector" (==) "==" (cast_expression) "(voidf) equals" (() "(" (type_descriptor) "voidf" (type_identifier) "voidf" ()) ")" (identifier) "equals" ()) ")" (expression_statement) "* (voidf *) & self->equals = method;" (assignment_expression) "* (voidf *) & self->equals = method" (pointer_expression) "* (voidf *) & self->equals" (*) "*" (cast_expression) "(voidf *) & self->equals" (() "(" (type_descriptor) "voidf *" (type_identifier) "voidf" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (pointer_expression) "& self->equals" (&) "&" (field_expression) "self->equals" (identifier) "self" (->) "->" (field_identifier) "equals" (=) "=" (identifier) "method" (;) ";" (else_clause) "else if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (else) "else" (if_statement) "if ( selector == (voidf) hash )\n * (voidf *) & self->hash = method;\n \n else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (if) "if" (parenthesized_expression) "( selector == (voidf) hash )" (() "(" (binary_expression) "selector == (voidf) hash" (identifier) "selector" (==) "==" (cast_expression) "(voidf) hash" (() "(" (type_descriptor) "voidf" (type_identifier) "voidf" ()) ")" (identifier) "hash" ()) ")" (expression_statement) "* (voidf *) & self->hash = method;" (assignment_expression) "* (voidf *) & self->hash = method" (pointer_expression) "* (voidf *) & self->hash" (*) "*" (cast_expression) "(voidf *) & self->hash" (() "(" (type_descriptor) "voidf *" (type_identifier) "voidf" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (pointer_expression) "& self->hash" (&) "&" (field_expression) "self->hash" (identifier) "self" (->) "->" (field_identifier) "hash" (=) "=" (identifier) "method" (;) ";" (else_clause) "else if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (else) "else" (if_statement) "if ( selector == (voidf) retain )\n * (voidf *) & self->retain = method;\n else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (if) "if" (parenthesized_expression) "( selector == (voidf) retain )" (() "(" (binary_expression) "selector == (voidf) retain" (identifier) "selector" (==) "==" (cast_expression) "(voidf) retain" (() "(" (type_descriptor) "voidf" (type_identifier) "voidf" ()) ")" (identifier) "retain" ()) ")" (expression_statement) "* (voidf *) & self->retain = method;" (assignment_expression) "* (voidf *) & self->retain = method" (pointer_expression) "* (voidf *) & self->retain" (*) "*" (cast_expression) "(voidf *) & self->retain" (() "(" (type_descriptor) "voidf *" (type_identifier) "voidf" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (pointer_expression) "& self->retain" (&) "&" (field_expression) "self->retain" (identifier) "self" (->) "->" (field_identifier) "retain" (=) "=" (identifier) "method" (;) ";" (else_clause) "else if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (else) "else" (if_statement) "if ( selector == (voidf) release )\n * (voidf *) & self->release = method;\n else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (if) "if" (parenthesized_expression) "( selector == (voidf) release )" (() "(" (binary_expression) "selector == (voidf) release" (identifier) "selector" (==) "==" (cast_expression) "(voidf) release" (() "(" (type_descriptor) "voidf" (type_identifier) "voidf" ()) ")" (identifier) "release" ()) ")" (expression_statement) "* (voidf *) & self->release = method;" (assignment_expression) "* (voidf *) & self->release = method" (pointer_expression) "* (voidf *) & self->release" (*) "*" (cast_expression) "(voidf *) & self->release" (() "(" (type_descriptor) "voidf *" (type_identifier) "voidf" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (pointer_expression) "& self->release" (&) "&" (field_expression) "self->release" (identifier) "self" (->) "->" (field_identifier) "release" (=) "=" (identifier) "method" (;) ";" (else_clause) "else if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (else) "else" (if_statement) "if ( selector == (voidf) retainCount )\n * (voidf *) & self->retainCount = method;\n \n else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (if) "if" (parenthesized_expression) "( selector == (voidf) retainCount )" (() "(" (binary_expression) "selector == (voidf) retainCount" (identifier) "selector" (==) "==" (cast_expression) "(voidf) retainCount" (() "(" (type_descriptor) "voidf" (type_identifier) "voidf" ()) ")" (identifier) "retainCount" ()) ")" (expression_statement) "* (voidf *) & self->retainCount = method;" (assignment_expression) "* (voidf *) & self->retainCount = method" (pointer_expression) "* (voidf *) & self->retainCount" (*) "*" (cast_expression) "(voidf *) & self->retainCount" (() "(" (type_descriptor) "voidf *" (type_identifier) "voidf" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (pointer_expression) "& self->retainCount" (&) "&" (field_expression) "self->retainCount" (identifier) "self" (->) "->" (field_identifier) "retainCount" (=) "=" (identifier) "method" (;) ";" (else_clause) "else if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (else) "else" (if_statement) "if ( selector == (voidf) copyDescription )\n * (voidf *) & self->copyDescription = method;\n \n else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (if) "if" (parenthesized_expression) "( selector == (voidf) copyDescription )" (() "(" (binary_expression) "selector == (voidf) copyDescription" (identifier) "selector" (==) "==" (cast_expression) "(voidf) copyDescription" (() "(" (type_descriptor) "voidf" (type_identifier) "voidf" ()) ")" (identifier) "copyDescription" ()) ")" (expression_statement) "* (voidf *) & self->copyDescription = method;" (assignment_expression) "* (voidf *) & self->copyDescription = method" (pointer_expression) "* (voidf *) & self->copyDescription" (*) "*" (cast_expression) "(voidf *) & self->copyDescription" (() "(" (type_descriptor) "voidf *" (type_identifier) "voidf" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (pointer_expression) "& self->copyDescription" (&) "&" (field_expression) "self->copyDescription" (identifier) "self" (->) "->" (field_identifier) "copyDescription" (=) "=" (identifier) "method" (;) ";" (else_clause) "else if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (else) "else" (if_statement) "if ( selector == (voidf) autorelease )\n * (voidf *) & self->autorelease = method;" (if) "if" (parenthesized_expression) "( selector == (voidf) autorelease )" (() "(" (binary_expression) "selector == (voidf) autorelease" (identifier) "selector" (==) "==" (cast_expression) "(voidf) autorelease" (() "(" (type_descriptor) "voidf" (type_identifier) "voidf" ()) ")" (identifier) "autorelease" ()) ")" (expression_statement) "* (voidf *) & self->autorelease = method;" (assignment_expression) "* (voidf *) & self->autorelease = method" (pointer_expression) "* (voidf *) & self->autorelease" (*) "*" (cast_expression) "(voidf *) & self->autorelease" (() "(" (type_descriptor) "voidf *" (type_identifier) "voidf" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (pointer_expression) "& self->autorelease" (&) "&" (field_expression) "self->autorelease" (identifier) "self" (->) "->" (field_identifier) "autorelease" (=) "=" (identifier) "method" (;) ";" (}) "}" (expression_statement) "va_end(ap);" (call_expression) "va_end(ap)" (identifier) "va_end" (argument_list) "(ap)" (() "(" (identifier) "ap" ()) ")" (;) ";" (}) "}" (return_statement) "return self;" (return) "return" (identifier) "self" (;) ";" (}) "}" (function_definition) "static void * Class_destructor (void * _self) {\n return NULL;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (pointer_declarator) "* Class_destructor (void * _self)" (*) "*" (function_declarator) "Class_destructor (void * _self)" (identifier) "Class_destructor" (parameter_list) "(void * _self)" (() "(" (parameter_declaration) "void * _self" (primitive_type) "void" (pointer_declarator) "* _self" (*) "*" (identifier) "_self" ()) ")" (compound_statement) "{\n return NULL;\n}" ({) "{" (return_statement) "return NULL;" (return) "return" (null) "NULL" (NULL) "NULL" (;) ";" (}) "}" (function_definition) "static void * Class_copy (const void *const _self) {\n return NULL;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (pointer_declarator) "* Class_copy (const void *const _self)" (*) "*" (function_declarator) "Class_copy (const void *const _self)" (identifier) "Class_copy" (parameter_list) "(const void *const _self)" (() "(" (parameter_declaration) "const void *const _self" (type_qualifier) "const" (const) "const" (primitive_type) "void" (pointer_declarator) "*const _self" (*) "*" (type_qualifier) "const" (const) "const" (identifier) "_self" ()) ")" (compound_statement) "{\n return NULL;\n}" ({) "{" (return_statement) "return NULL;" (return) "return" (null) "NULL" (NULL) "NULL" (;) ";" (}) "}" (function_definition) "static UInteger Class_hash (const void *const self) {\n COAssertNoNullOrReturn(self,EINVAL,0);\n const struct Classs *const class = classOf(self);\n COAssertNoNullOrReturn(class,EINVAL,0);\n const struct Classs *const _superclass = superclass(self);\n COAssertNoNullOrReturn(_superclass,EINVAL,0);\n COAssertNoNullOrReturn(_superclass->hash,EINVAL,0);\n \n \n UInteger prime = 31;\n UInteger result = _superclass->hash(self);\n result = prime * result + (UInteger)strlen(class->class_name);\n result = prime * result + class->size;\n return result;\n}" (storage_class_specifier) "static" (static) "static" (type_identifier) "UInteger" (function_declarator) "Class_hash (const void *const self)" (identifier) "Class_hash" (parameter_list) "(const void *const self)" (() "(" (parameter_declaration) "const void *const self" (type_qualifier) "const" (const) "const" (primitive_type) "void" (pointer_declarator) "*const self" (*) "*" (type_qualifier) "const" (const) "const" (identifier) "self" ()) ")" (compound_statement) "{\n COAssertNoNullOrReturn(self,EINVAL,0);\n const struct Classs *const class = classOf(self);\n COAssertNoNullOrReturn(class,EINVAL,0);\n const struct Classs *const _superclass = superclass(self);\n COAssertNoNullOrReturn(_superclass,EINVAL,0);\n COAssertNoNullOrReturn(_superclass->hash,EINVAL,0);\n \n \n UInteger prime = 31;\n UInteger result = _superclass->hash(self);\n result = prime * result + (UInteger)strlen(class->class_name);\n result = prime * result + class->size;\n return result;\n}" ({) "{" (expression_statement) "COAssertNoNullOrReturn(self,EINVAL,0);" (call_expression) "COAssertNoNullOrReturn(self,EINVAL,0)" (identifier) "COAssertNoNullOrReturn" (argument_list) "(self,EINVAL,0)" (() "(" (identifier) "self" (,) "," (identifier) "EINVAL" (,) "," (number_literal) "0" ()) ")" (;) ";" (declaration) "const struct Classs *const class = classOf(self);" (type_qualifier) "const" (const) "const" (struct_specifier) "struct Classs" (struct) "struct" (type_identifier) "Classs" (init_declarator) "*const class = classOf(self)" (pointer_declarator) "*const class" (*) "*" (type_qualifier) "const" (const) "const" (identifier) "class" (=) "=" (call_expression) "classOf(self)" (identifier) "classOf" (argument_list) "(self)" (() "(" (identifier) "self" ()) ")" (;) ";" (expression_statement) "COAssertNoNullOrReturn(class,EINVAL,0);" (call_expression) "COAssertNoNullOrReturn(class,EINVAL,0)" (identifier) "COAssertNoNullOrReturn" (argument_list) "(class,EINVAL,0)" (() "(" (identifier) "class" (,) "," (identifier) "EINVAL" (,) "," (number_literal) "0" ()) ")" (;) ";" (declaration) "const struct Classs *const _superclass = superclass(self);" (type_qualifier) "const" (const) "const" (struct_specifier) "struct Classs" (struct) "struct" (type_identifier) "Classs" (init_declarator) "*const _superclass = superclass(self)" (pointer_declarator) "*const _superclass" (*) "*" (type_qualifier) "const" (const) "const" (identifier) "_superclass" (=) "=" (call_expression) "superclass(self)" (identifier) "superclass" (argument_list) "(self)" (() "(" (identifier) "self" ()) ")" (;) ";" (expression_statement) "COAssertNoNullOrReturn(_superclass,EINVAL,0);" (call_expression) "COAssertNoNullOrReturn(_superclass,EINVAL,0)" (identifier) "COAssertNoNullOrReturn" (argument_list) "(_superclass,EINVAL,0)" (() "(" (identifier) "_superclass" (,) "," (identifier) "EINVAL" (,) "," (number_literal) "0" ()) ")" (;) ";" (expression_statement) "COAssertNoNullOrReturn(_superclass->hash,EINVAL,0);" (call_expression) "COAssertNoNullOrReturn(_superclass->hash,EINVAL,0)" (identifier) "COAssertNoNullOrReturn" (argument_list) "(_superclass->hash,EINVAL,0)" (() "(" (field_expression) "_superclass->hash" (identifier) "_superclass" (->) "->" (field_identifier) "hash" (,) "," (identifier) "EINVAL" (,) "," (number_literal) "0" ()) ")" (;) ";" (declaration) "UInteger prime = 31;" (type_identifier) "UInteger" (init_declarator) "prime = 31" (identifier) "prime" (=) "=" (number_literal) "31" (;) ";" (declaration) "UInteger result = _superclass->hash(self);" (type_identifier) "UInteger" (init_declarator) "result = _superclass->hash(self)" (identifier) "result" (=) "=" (call_expression) "_superclass->hash(self)" (field_expression) "_superclass->hash" (identifier) "_superclass" (->) "->" (field_identifier) "hash" (argument_list) "(self)" (() "(" (identifier) "self" ()) ")" (;) ";" (expression_statement) "result = prime * result + (UInteger)strlen(class->class_name);" (assignment_expression) "result = prime * result + (UInteger)strlen(class->class_name)" (identifier) "result" (=) "=" (binary_expression) "prime * result + (UInteger)strlen(class->class_name)" (binary_expression) "prime * result" (identifier) "prime" (*) "*" (identifier) "result" (+) "+" (cast_expression) "(UInteger)strlen(class->class_name)" (() "(" (type_descriptor) "UInteger" (type_identifier) "UInteger" ()) ")" (call_expression) "strlen(class->class_name)" (identifier) "strlen" (argument_list) "(class->class_name)" (() "(" (field_expression) "class->class_name" (identifier) "class" (->) "->" (field_identifier) "class_name" ()) ")" (;) ";" (expression_statement) "result = prime * result + class->size;" (assignment_expression) "result = prime * result + class->size" (identifier) "result" (=) "=" (binary_expression) "prime * result + class->size" (binary_expression) "prime * result" (identifier) "prime" (*) "*" (identifier) "result" (+) "+" (field_expression) "class->size" (identifier) "class" (->) "->" (field_identifier) "size" (;) ";" (return_statement) "return result;" (return) "return" (identifier) "result" (;) ";" (}) "}" (function_definition) "static void * Class_retain (void *const _self) {\n return NULL;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (pointer_declarator) "* Class_retain (void *const _self)" (*) "*" (function_declarator) "Class_retain (void *const _self)" (identifier) "Class_retain" (parameter_list) "(void *const _self)" (() "(" (parameter_declaration) "void *const _self" (primitive_type) "void" (pointer_declarator) "*const _self" (*) "*" (type_qualifier) "const" (const) "const" (identifier) "_self" ()) ")" (compound_statement) "{\n return NULL;\n}" ({) "{" (return_statement) "return NULL;" (return) "return" (null) "NULL" (NULL) "NULL" (;) ";" (}) "}" (function_definition) "static void Class_release (void *const _self) {\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "Class_release (void *const _self)" (identifier) "Class_release" (parameter_list) "(void *const _self)" (() "(" (parameter_declaration) "void *const _self" (primitive_type) "void" (pointer_declarator) "*const _self" (*) "*" (type_qualifier) "const" (const) "const" (identifier) "_self" ()) ")" (compound_statement) "{\n}" ({) "{" (}) "}" (function_definition) "static void *Class_autorelease (void *const _self) {\n return NULL;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (pointer_declarator) "*Class_autorelease (void *const _self)" (*) "*" (function_declarator) "Class_autorelease (void *const _self)" (identifier) "Class_autorelease" (parameter_list) "(void *const _self)" (() "(" (parameter_declaration) "void *const _self" (primitive_type) "void" (pointer_declarator) "*const _self" (*) "*" (type_qualifier) "const" (const) "const" (identifier) "_self" ()) ")" (compound_statement) "{\n return NULL;\n}" ({) "{" (return_statement) "return NULL;" (return) "return" (null) "NULL" (NULL) "NULL" (;) ";" (}) "}" (declaration) "static const struct Classs object [] = {\n { {object+1},\n "Object",\n object,\n sizeof(struct Object),\n Object_constructor,\n Object_destructor,\n Object_copy,\n Object_equals,\n Object_hash,\n Object_copyDescription,\n Object_retain,\n Object_release,\n Object_retainCount,\n Object_autorelease,\n },\n { {object+1},\n "Class",\n object,\n sizeof(struct Classs),\n Class_constructor,\n Class_destructor,\n Class_copy,\n Object_equals,\n Class_hash,\n Object_copyDescription,\n Class_retain,\n Object_release,\n Object_retainCount,\n Class_autorelease,\n }\n};" (storage_class_specifier) "static" (static) "static" (type_qualifier) "const" (const) "const" (struct_specifier) "struct Classs" (struct) "struct" (type_identifier) "Classs" (init_declarator) "object [] = {\n { {object+1},\n "Object",\n object,\n sizeof(struct Object),\n Object_constructor,\n Object_destructor,\n Object_copy,\n Object_equals,\n Object_hash,\n Object_copyDescription,\n Object_retain,\n Object_release,\n Object_retainCount,\n Object_autorelease,\n },\n { {object+1},\n "Class",\n object,\n sizeof(struct Classs),\n Class_constructor,\n Class_destructor,\n Class_copy,\n Object_equals,\n Class_hash,\n Object_copyDescription,\n Class_retain,\n Object_release,\n Object_retainCount,\n Class_autorelease,\n }\n}" (array_declarator) "object []" (identifier) "object" ([) "[" (]) "]" (=) "=" (initializer_list) "{\n { {object+1},\n "Object",\n object,\n sizeof(struct Object),\n Object_constructor,\n Object_destructor,\n Object_copy,\n Object_equals,\n Object_hash,\n Object_copyDescription,\n Object_retain,\n Object_release,\n Object_retainCount,\n Object_autorelease,\n },\n { {object+1},\n "Class",\n object,\n sizeof(struct Classs),\n Class_constructor,\n Class_destructor,\n Class_copy,\n Object_equals,\n Class_hash,\n Object_copyDescription,\n Class_retain,\n Object_release,\n Object_retainCount,\n Class_autorelease,\n }\n}" ({) "{" (initializer_list) "{ {object+1},\n "Object",\n object,\n sizeof(struct Object),\n Object_constructor,\n Object_destructor,\n Object_copy,\n Object_equals,\n Object_hash,\n Object_copyDescription,\n Object_retain,\n Object_release,\n Object_retainCount,\n Object_autorelease,\n }" ({) "{" (initializer_list) "{object+1}" ({) "{" (binary_expression) "object+1" (identifier) "object" (+) "+" (number_literal) "1" (}) "}" (,) "," (string_literal) ""Object"" (") """ (string_content) "Object" (") """ (,) "," (identifier) "object" (,) "," (sizeof_expression) "sizeof(struct Object)" (sizeof) "sizeof" (() "(" (type_descriptor) "struct Object" (struct_specifier) "struct Object" (struct) "struct" (type_identifier) "Object" ()) ")" (,) "," (identifier) "Object_constructor" (,) "," (identifier) "Object_destructor" (,) "," (identifier) "Object_copy" (,) "," (identifier) "Object_equals" (,) "," (identifier) "Object_hash" (,) "," (identifier) "Object_copyDescription" (,) "," (identifier) "Object_retain" (,) "," (identifier) "Object_release" (,) "," (identifier) "Object_retainCount" (,) "," (identifier) "Object_autorelease" (,) "," (}) "}" (,) "," (initializer_list) "{ {object+1},\n "Class",\n object,\n sizeof(struct Classs),\n Class_constructor,\n Class_destructor,\n Class_copy,\n Object_equals,\n Class_hash,\n Object_copyDescription,\n Class_retain,\n Object_release,\n Object_retainCount,\n Class_autorelease,\n }" ({) "{" (initializer_list) "{object+1}" ({) "{" (binary_expression) "object+1" (identifier) "object" (+) "+" (number_literal) "1" (}) "}" (,) "," (string_literal) ""Class"" (") """ (string_content) "Class" (") """ (,) "," (identifier) "object" (,) "," (sizeof_expression) "sizeof(struct Classs)" (sizeof) "sizeof" (() "(" (type_descriptor) "struct Classs" (struct_specifier) "struct Classs" (struct) "struct" (type_identifier) "Classs" ()) ")" (,) "," (identifier) "Class_constructor" (,) "," (identifier) "Class_destructor" (,) "," (identifier) "Class_copy" (,) "," (identifier) "Object_equals" (,) "," (identifier) "Class_hash" (,) "," (identifier) "Object_copyDescription" (,) "," (identifier) "Class_retain" (,) "," (identifier) "Object_release" (,) "," (identifier) "Object_retainCount" (,) "," (identifier) "Class_autorelease" (,) "," (}) "}" (}) "}" (;) ";" (declaration) "const void *const Object = (const void * const)(object);" (type_qualifier) "const" (const) "const" (primitive_type) "void" (init_declarator) "*const Object = (const void * const)(object)" (pointer_declarator) "*const Object" (*) "*" (type_qualifier) "const" (const) "const" (identifier) "Object" (=) "=" (cast_expression) "(const void * const)(object)" (() "(" (type_descriptor) "const void * const" (type_qualifier) "const" (const) "const" (primitive_type) "void" (abstract_pointer_declarator) "* const" (*) "*" (type_qualifier) "const" (const) "const" ()) ")" (parenthesized_expression) "(object)" (() "(" (identifier) "object" ()) ")" (;) ";" (declaration) "const void *const Class = (const void * const )(object+1);" (type_qualifier) "const" (const) "const" (primitive_type) "void" (init_declarator) "*const Class = (const void * const )(object+1)" (pointer_declarator) "*const Class" (*) "*" (type_qualifier) "const" (const) "const" (identifier) "Class" (=) "=" (cast_expression) "(const void * const )(object+1)" (() "(" (type_descriptor) "const void * const" (type_qualifier) "const" (const) "const" (primitive_type) "void" (abstract_pointer_declarator) "* const" (*) "*" (type_qualifier) "const" (const) "const" ()) ")" (parenthesized_expression) "(object+1)" (() "(" (binary_expression) "object+1" (identifier) "object" (+) "+" (number_literal) "1" ()) ")" (;) ";"
1,170
2
{"language": "c", "success": true, "metadata": {"lines": 131, "avg_line_length": 25.29, "nodes": 733, "errors": 0, "source_hash": "671da0e1e925d4b66598efa48aa3b71592f15d27a4bef031cc29c053455254ed", "categorized_nodes": 470}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_def", "text": "#define _XOPEN_SOURCE 700\n", "parent": null, "children": [1, 2, 3], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 1, "type": "#define", "text": "#define", "parent": 0, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 7}}, {"id": 2, "type": "identifier", "text": "_XOPEN_SOURCE", "parent": 0, "children": [], "start_point": {"row": 7, "column": 8}, "end_point": {"row": 7, "column": 21}}, {"id": 3, "type": "preproc_arg", "text": "700", "parent": 0, "children": [], "start_point": {"row": 7, "column": 22}, "end_point": {"row": 7, "column": 25}}, {"id": 4, "type": "preproc_include", "text": "#include <stdio.h>\n", "parent": null, "children": [5, 6], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 5, "type": "#include", "text": "#include", "parent": 4, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 8}}, {"id": 6, "type": "system_lib_string", "text": "<stdio.h>", "parent": 4, "children": [], "start_point": {"row": 9, "column": 9}, "end_point": {"row": 9, "column": 18}}, {"id": 7, "type": "preproc_include", "text": "#include <stdlib.h>\n", "parent": null, "children": [8, 9], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 11, "column": 0}}, {"id": 8, "type": "#include", "text": "#include", "parent": 7, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 8}}, {"id": 9, "type": "system_lib_string", "text": "<stdlib.h>", "parent": 7, "children": [], "start_point": {"row": 10, "column": 9}, "end_point": {"row": 10, "column": 19}}, {"id": 10, "type": "preproc_include", "text": "#include <string.h>\n", "parent": null, "children": [11, 12], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 12, "column": 0}}, {"id": 11, "type": "#include", "text": "#include", "parent": 10, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 8}}, {"id": 12, "type": "system_lib_string", "text": "<string.h>", "parent": 10, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 19}}, {"id": 13, "type": "preproc_include", "text": "#include <stdarg.h>\n", "parent": null, "children": [14, 15], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 13, "column": 0}}, {"id": 14, "type": "#include", "text": "#include", "parent": 13, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 8}}, {"id": 15, "type": "system_lib_string", "text": "<stdarg.h>", "parent": 13, "children": [], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 19}}, {"id": 16, "type": "preproc_include", "text": "#include <coassert.h>\n", "parent": null, "children": [17, 18], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 15, "column": 0}}, {"id": 17, "type": "#include", "text": "#include", "parent": 16, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 8}}, {"id": 18, "type": "system_lib_string", "text": "<coassert.h>", "parent": 16, "children": [], "start_point": {"row": 14, "column": 9}, "end_point": {"row": 14, "column": 21}}, {"id": 19, "type": "preproc_include", "text": "#include <errno.h>\n", "parent": null, "children": [20, 21], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 20, "type": "#include", "text": "#include", "parent": 19, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 8}}, {"id": 21, "type": "system_lib_string", "text": "<errno.h>", "parent": 19, "children": [], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 18}}, {"id": 22, "type": "preproc_include", "text": "#include <Object.h>\n", "parent": null, "children": [23, 24], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 18, "column": 0}}, {"id": 23, "type": "#include", "text": "#include", "parent": 22, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 8}}, {"id": 24, "type": "system_lib_string", "text": "<Object.h>", "parent": 22, "children": [], "start_point": {"row": 17, "column": 9}, "end_point": {"row": 17, "column": 19}}, {"id": 25, "type": "preproc_include", "text": "#include <Object.r>\n", "parent": null, "children": [26, 27], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 19, "column": 0}}, {"id": 26, "type": "#include", "text": "#include", "parent": 25, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 8}}, {"id": 27, "type": "system_lib_string", "text": "<Object.r>", "parent": 25, "children": [], "start_point": {"row": 18, "column": 9}, "end_point": {"row": 18, "column": 19}}, {"id": 28, "type": "preproc_include", "text": "#include <new.h>\n", "parent": null, "children": [29, 30], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 20, "column": 0}}, {"id": 29, "type": "#include", "text": "#include", "parent": 28, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 8}}, {"id": 30, "type": "system_lib_string", "text": "<new.h>", "parent": 28, "children": [], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 16}}, {"id": 31, "type": "function_definition", "text": "static void * Class_constructor (void * _self, va_list * app) {\n\tstruct Classs * self = _self;\n\t\n\tself->class_name = va_arg( *app, const char *);\n\tself->super = va_arg( *app, struct Classs *);\n\tself->size = va_arg( *app, UInteger);\n\t\n\tassert(self->super != NULL);\n\tconst UInteger offset\t = sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *) + sizeof(UInteger);\n\tmemcpy((char *)self + offset, (char *)(self->super) + offset, sizeOf((void *)self->super) - offset);\n\t{\n\t\ttypedef void (*voidf) ();\n\t\tvoidf selector = NULL;\n\t\tva_list ap;\n\t\tva_copy(ap, *app);\n\t\t\n\t\twhile ( (selector = va_arg(ap, voidf)) ) {\n\t\t\tvoidf method = va_arg(ap, voidf);\n\t\t\t\n\t\t\tif ( selector == (voidf) constructor )\n\t\t\t\t* (voidf *) & self->constructor = method;\n\t\t\telse if ( selector == (voidf) destructor )\n\t\t\t\t* (voidf *) & self->destructor = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copy )\n\t\t\t\t* (voidf *) & self->copy = method;\n\t\t\telse if ( selector == (voidf) equals )\n\t\t\t\t* (voidf *) & self->equals = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) hash )\n\t\t\t\t* (voidf *) & self->hash = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;\n\t\t}\n\t\tva_end(ap);\n\t}\n\t\n\treturn self;\n}", "parent": null, "children": [32, 33], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 71, "column": 1}}, {"id": 32, "type": "primitive_type", "text": "void", "parent": 31, "children": [], "start_point": {"row": 22, "column": 7}, "end_point": {"row": 22, "column": 11}}, {"id": 33, "type": "pointer_declarator", "text": "* Class_constructor (void * _self, va_list * app)", "parent": 31, "children": [34, 35], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 61}}, {"id": 34, "type": "*", "text": "*", "parent": 33, "children": [], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 13}}, {"id": 35, "type": "function_declarator", "text": "Class_constructor (void * _self, va_list * app)", "parent": 33, "children": [36, 37], "start_point": {"row": 22, "column": 14}, "end_point": {"row": 22, "column": 61}}, {"id": 36, "type": "identifier", "text": "Class_constructor", "parent": 35, "children": [], "start_point": {"row": 22, "column": 14}, "end_point": {"row": 22, "column": 31}}, {"id": 37, "type": "parameter_list", "text": "(void * _self, va_list * app)", "parent": 35, "children": [38, 43], "start_point": {"row": 22, "column": 32}, "end_point": {"row": 22, "column": 61}}, {"id": 38, "type": "parameter_declaration", "text": "void * _self", "parent": 37, "children": [39, 40], "start_point": {"row": 22, "column": 33}, "end_point": {"row": 22, "column": 45}}, {"id": 39, "type": "primitive_type", "text": "void", "parent": 38, "children": [], "start_point": {"row": 22, "column": 33}, "end_point": {"row": 22, "column": 37}}, {"id": 40, "type": "pointer_declarator", "text": "* _self", "parent": 38, "children": [41, 42], "start_point": {"row": 22, "column": 38}, "end_point": {"row": 22, "column": 45}}, {"id": 41, "type": "*", "text": "*", "parent": 40, "children": [], "start_point": {"row": 22, "column": 38}, "end_point": {"row": 22, "column": 39}}, {"id": 42, "type": "identifier", "text": "_self", "parent": 40, "children": [], "start_point": {"row": 22, "column": 40}, "end_point": {"row": 22, "column": 45}}, {"id": 43, "type": "parameter_declaration", "text": "va_list * app", "parent": 37, "children": [44, 45], "start_point": {"row": 22, "column": 47}, "end_point": {"row": 22, "column": 60}}, {"id": 44, "type": "type_identifier", "text": "va_list", "parent": 43, "children": [], "start_point": {"row": 22, "column": 47}, "end_point": {"row": 22, "column": 54}}, {"id": 45, "type": "pointer_declarator", "text": "* app", "parent": 43, "children": [46, 47], "start_point": {"row": 22, "column": 55}, "end_point": {"row": 22, "column": 60}}, {"id": 46, "type": "*", "text": "*", "parent": 45, "children": [], "start_point": {"row": 22, "column": 55}, "end_point": {"row": 22, "column": 56}}, {"id": 47, "type": "identifier", "text": "app", "parent": 45, "children": [], "start_point": {"row": 22, "column": 57}, "end_point": {"row": 22, "column": 60}}, {"id": 48, "type": "declaration", "text": "struct Classs * self = _self;", "parent": 31, "children": [49, 52], "start_point": {"row": 23, "column": 1}, "end_point": {"row": 23, "column": 30}}, {"id": 49, "type": "struct_specifier", "text": "struct Classs", "parent": 48, "children": [50, 51], "start_point": {"row": 23, "column": 1}, "end_point": {"row": 23, "column": 14}}, {"id": 50, "type": "struct", "text": "struct", "parent": 49, "children": [], "start_point": {"row": 23, "column": 1}, "end_point": {"row": 23, "column": 7}}, {"id": 51, "type": "type_identifier", "text": "Classs", "parent": 49, "children": [], "start_point": {"row": 23, "column": 8}, "end_point": {"row": 23, "column": 14}}, {"id": 52, "type": "init_declarator", "text": "* self = _self", "parent": 48, "children": [53, 56, 57], "start_point": {"row": 23, "column": 15}, "end_point": {"row": 23, "column": 29}}, {"id": 53, "type": "pointer_declarator", "text": "* self", "parent": 52, "children": [54, 55], "start_point": {"row": 23, "column": 15}, "end_point": {"row": 23, "column": 21}}, {"id": 54, "type": "*", "text": "*", "parent": 53, "children": [], "start_point": {"row": 23, "column": 15}, "end_point": {"row": 23, "column": 16}}, {"id": 55, "type": "identifier", "text": "self", "parent": 53, "children": [], "start_point": {"row": 23, "column": 17}, "end_point": {"row": 23, "column": 21}}, {"id": 56, "type": "=", "text": "=", "parent": 52, "children": [], "start_point": {"row": 23, "column": 22}, "end_point": {"row": 23, "column": 23}}, {"id": 57, "type": "identifier", "text": "_self", "parent": 52, "children": [], "start_point": {"row": 23, "column": 24}, "end_point": {"row": 23, "column": 29}}, {"id": 58, "type": "assignment_expression", "text": "self->class_name = va_arg( *app, const char *)", "parent": 31, "children": [59, 62, 63], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 25, "column": 47}}, {"id": 59, "type": "field_expression", "text": "self->class_name", "parent": 58, "children": [60, 61], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 25, "column": 17}}, {"id": 60, "type": "identifier", "text": "self", "parent": 59, "children": [], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 25, "column": 5}}, {"id": 61, "type": "field_identifier", "text": "class_name", "parent": 59, "children": [], "start_point": {"row": 25, "column": 7}, "end_point": {"row": 25, "column": 17}}, {"id": 62, "type": "=", "text": "=", "parent": 58, "children": [], "start_point": {"row": 25, "column": 18}, "end_point": {"row": 25, "column": 19}}, {"id": 63, "type": "call_expression", "text": "va_arg( *app, const char *)", "parent": 58, "children": [64, 65], "start_point": {"row": 25, "column": 20}, "end_point": {"row": 25, "column": 47}}, {"id": 64, "type": "identifier", "text": "va_arg", "parent": 63, "children": [], "start_point": {"row": 25, "column": 20}, "end_point": {"row": 25, "column": 26}}, {"id": 65, "type": "argument_list", "text": "( *app, const char *)", "parent": 63, "children": [66, 69], "start_point": {"row": 25, "column": 26}, "end_point": {"row": 25, "column": 47}}, {"id": 66, "type": "pointer_expression", "text": "*app", "parent": 65, "children": [67, 68], "start_point": {"row": 25, "column": 28}, "end_point": {"row": 25, "column": 32}}, {"id": 67, "type": "*", "text": "*", "parent": 66, "children": [], "start_point": {"row": 25, "column": 28}, "end_point": {"row": 25, "column": 29}}, {"id": 68, "type": "identifier", "text": "app", "parent": 66, "children": [], "start_point": {"row": 25, "column": 29}, "end_point": {"row": 25, "column": 32}}, {"id": 69, "type": "ERROR", "text": "char *", "parent": 65, "children": [70, 71], "start_point": {"row": 25, "column": 40}, "end_point": {"row": 25, "column": 46}}, {"id": 70, "type": "identifier", "text": "char", "parent": 69, "children": [], "start_point": {"row": 25, "column": 40}, "end_point": {"row": 25, "column": 44}}, {"id": 71, "type": "*", "text": "*", "parent": 69, "children": [], "start_point": {"row": 25, "column": 45}, "end_point": {"row": 25, "column": 46}}, {"id": 72, "type": "assignment_expression", "text": "self->super = va_arg( *app, struct Classs *)", "parent": 31, "children": [73, 76, 77], "start_point": {"row": 26, "column": 1}, "end_point": {"row": 26, "column": 45}}, {"id": 73, "type": "field_expression", "text": "self->super", "parent": 72, "children": [74, 75], "start_point": {"row": 26, "column": 1}, "end_point": {"row": 26, "column": 12}}, {"id": 74, "type": "identifier", "text": "self", "parent": 73, "children": [], "start_point": {"row": 26, "column": 1}, "end_point": {"row": 26, "column": 5}}, {"id": 75, "type": "field_identifier", "text": "super", "parent": 73, "children": [], "start_point": {"row": 26, "column": 7}, "end_point": {"row": 26, "column": 12}}, {"id": 76, "type": "=", "text": "=", "parent": 72, "children": [], "start_point": {"row": 26, "column": 13}, "end_point": {"row": 26, "column": 14}}, {"id": 77, "type": "call_expression", "text": "va_arg( *app, struct Classs *)", "parent": 72, "children": [78, 79], "start_point": {"row": 26, "column": 15}, "end_point": {"row": 26, "column": 45}}, {"id": 78, "type": "identifier", "text": "va_arg", "parent": 77, "children": [], "start_point": {"row": 26, "column": 15}, "end_point": {"row": 26, "column": 21}}, {"id": 79, "type": "argument_list", "text": "( *app, struct Classs *)", "parent": 77, "children": [80, 83, 84], "start_point": {"row": 26, "column": 21}, "end_point": {"row": 26, "column": 45}}, {"id": 80, "type": "pointer_expression", "text": "*app", "parent": 79, "children": [81, 82], "start_point": {"row": 26, "column": 23}, "end_point": {"row": 26, "column": 27}}, {"id": 81, "type": "*", "text": "*", "parent": 80, "children": [], "start_point": {"row": 26, "column": 23}, "end_point": {"row": 26, "column": 24}}, {"id": 82, "type": "identifier", "text": "app", "parent": 80, "children": [], "start_point": {"row": 26, "column": 24}, "end_point": {"row": 26, "column": 27}}, {"id": 83, "type": "identifier", "text": "struct", "parent": 79, "children": [], "start_point": {"row": 26, "column": 29}, "end_point": {"row": 26, "column": 35}}, {"id": 84, "type": "ERROR", "text": "Classs *", "parent": 79, "children": [85, 86], "start_point": {"row": 26, "column": 36}, "end_point": {"row": 26, "column": 44}}, {"id": 85, "type": "identifier", "text": "Classs", "parent": 84, "children": [], "start_point": {"row": 26, "column": 36}, "end_point": {"row": 26, "column": 42}}, {"id": 86, "type": "*", "text": "*", "parent": 84, "children": [], "start_point": {"row": 26, "column": 43}, "end_point": {"row": 26, "column": 44}}, {"id": 87, "type": "assignment_expression", "text": "self->size = va_arg( *app, UInteger)", "parent": 31, "children": [88, 91, 92], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 37}}, {"id": 88, "type": "field_expression", "text": "self->size", "parent": 87, "children": [89, 90], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 11}}, {"id": 89, "type": "identifier", "text": "self", "parent": 88, "children": [], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 5}}, {"id": 90, "type": "field_identifier", "text": "size", "parent": 88, "children": [], "start_point": {"row": 27, "column": 7}, "end_point": {"row": 27, "column": 11}}, {"id": 91, "type": "=", "text": "=", "parent": 87, "children": [], "start_point": {"row": 27, "column": 12}, "end_point": {"row": 27, "column": 13}}, {"id": 92, "type": "call_expression", "text": "va_arg( *app, UInteger)", "parent": 87, "children": [93, 94], "start_point": {"row": 27, "column": 14}, "end_point": {"row": 27, "column": 37}}, {"id": 93, "type": "identifier", "text": "va_arg", "parent": 92, "children": [], "start_point": {"row": 27, "column": 14}, "end_point": {"row": 27, "column": 20}}, {"id": 94, "type": "argument_list", "text": "( *app, UInteger)", "parent": 92, "children": [95, 98], "start_point": {"row": 27, "column": 20}, "end_point": {"row": 27, "column": 37}}, {"id": 95, "type": "pointer_expression", "text": "*app", "parent": 94, "children": [96, 97], "start_point": {"row": 27, "column": 22}, "end_point": {"row": 27, "column": 26}}, {"id": 96, "type": "*", "text": "*", "parent": 95, "children": [], "start_point": {"row": 27, "column": 22}, "end_point": {"row": 27, "column": 23}}, {"id": 97, "type": "identifier", "text": "app", "parent": 95, "children": [], "start_point": {"row": 27, "column": 23}, "end_point": {"row": 27, "column": 26}}, {"id": 98, "type": "identifier", "text": "UInteger", "parent": 94, "children": [], "start_point": {"row": 27, "column": 28}, "end_point": {"row": 27, "column": 36}}, {"id": 99, "type": "call_expression", "text": "assert(self->super != NULL)", "parent": 31, "children": [100, 101], "start_point": {"row": 29, "column": 1}, "end_point": {"row": 29, "column": 28}}, {"id": 100, "type": "identifier", "text": "assert", "parent": 99, "children": [], "start_point": {"row": 29, "column": 1}, "end_point": {"row": 29, "column": 7}}, {"id": 101, "type": "argument_list", "text": "(self->super != NULL)", "parent": 99, "children": [102], "start_point": {"row": 29, "column": 7}, "end_point": {"row": 29, "column": 28}}, {"id": 102, "type": "binary_expression", "text": "self->super != NULL", "parent": 101, "children": [103, 106, 107], "start_point": {"row": 29, "column": 8}, "end_point": {"row": 29, "column": 27}}, {"id": 103, "type": "field_expression", "text": "self->super", "parent": 102, "children": [104, 105], "start_point": {"row": 29, "column": 8}, "end_point": {"row": 29, "column": 19}}, {"id": 104, "type": "identifier", "text": "self", "parent": 103, "children": [], "start_point": {"row": 29, "column": 8}, "end_point": {"row": 29, "column": 12}}, {"id": 105, "type": "field_identifier", "text": "super", "parent": 103, "children": [], "start_point": {"row": 29, "column": 14}, "end_point": {"row": 29, "column": 19}}, {"id": 106, "type": "!=", "text": "!=", "parent": 102, "children": [], "start_point": {"row": 29, "column": 20}, "end_point": {"row": 29, "column": 22}}, {"id": 107, "type": "null", "text": "NULL", "parent": 102, "children": [108], "start_point": {"row": 29, "column": 23}, "end_point": {"row": 29, "column": 27}}, {"id": 108, "type": "NULL", "text": "NULL", "parent": 107, "children": [], "start_point": {"row": 29, "column": 23}, "end_point": {"row": 29, "column": 27}}, {"id": 109, "type": "declaration", "text": "const UInteger offset\t = sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *) + sizeof(UInteger);", "parent": 31, "children": [110, 111], "start_point": {"row": 30, "column": 1}, "end_point": {"row": 30, "column": 109}}, {"id": 110, "type": "type_identifier", "text": "UInteger", "parent": 109, "children": [], "start_point": {"row": 30, "column": 7}, "end_point": {"row": 30, "column": 15}}, {"id": 111, "type": "init_declarator", "text": "offset\t = sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *) + sizeof(UInteger)", "parent": 109, "children": [112, 113, 114], "start_point": {"row": 30, "column": 16}, "end_point": {"row": 30, "column": 108}}, {"id": 112, "type": "identifier", "text": "offset", "parent": 111, "children": [], "start_point": {"row": 30, "column": 16}, "end_point": {"row": 30, "column": 22}}, {"id": 113, "type": "=", "text": "=", "parent": 111, "children": [], "start_point": {"row": 30, "column": 24}, "end_point": {"row": 30, "column": 25}}, {"id": 114, "type": "binary_expression", "text": "sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *) + sizeof(UInteger)", "parent": 111, "children": [115, 136, 137], "start_point": {"row": 30, "column": 26}, "end_point": {"row": 30, "column": 108}}, {"id": 115, "type": "binary_expression", "text": "sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *)", "parent": 114, "children": [116, 128, 129], "start_point": {"row": 30, "column": 26}, "end_point": {"row": 30, "column": 89}}, {"id": 116, "type": "binary_expression", "text": "sizeof(struct Object) + sizeof(char *)", "parent": 115, "children": [117, 122, 123], "start_point": {"row": 30, "column": 26}, "end_point": {"row": 30, "column": 64}}, {"id": 117, "type": "sizeof_expression", "text": "sizeof(struct Object)", "parent": 116, "children": [118], "start_point": {"row": 30, "column": 26}, "end_point": {"row": 30, "column": 47}}, {"id": 118, "type": "type_descriptor", "text": "struct Object", "parent": 117, "children": [119], "start_point": {"row": 30, "column": 33}, "end_point": {"row": 30, "column": 46}}, {"id": 119, "type": "struct_specifier", "text": "struct Object", "parent": 118, "children": [120, 121], "start_point": {"row": 30, "column": 33}, "end_point": {"row": 30, "column": 46}}, {"id": 120, "type": "struct", "text": "struct", "parent": 119, "children": [], "start_point": {"row": 30, "column": 33}, "end_point": {"row": 30, "column": 39}}, {"id": 121, "type": "type_identifier", "text": "Object", "parent": 119, "children": [], "start_point": {"row": 30, "column": 40}, "end_point": {"row": 30, "column": 46}}, {"id": 122, "type": "+", "text": "+", "parent": 116, "children": [], "start_point": {"row": 30, "column": 48}, "end_point": {"row": 30, "column": 49}}, {"id": 123, "type": "sizeof_expression", "text": "sizeof(char *)", "parent": 116, "children": [124], "start_point": {"row": 30, "column": 50}, "end_point": {"row": 30, "column": 64}}, {"id": 124, "type": "type_descriptor", "text": "char *", "parent": 123, "children": [125, 126], "start_point": {"row": 30, "column": 57}, "end_point": {"row": 30, "column": 63}}, {"id": 125, "type": "primitive_type", "text": "char", "parent": 124, "children": [], "start_point": {"row": 30, "column": 57}, "end_point": {"row": 30, "column": 61}}, {"id": 126, "type": "abstract_pointer_declarator", "text": "*", "parent": 124, "children": [127], "start_point": {"row": 30, "column": 62}, "end_point": {"row": 30, "column": 63}}, {"id": 127, "type": "*", "text": "*", "parent": 126, "children": [], "start_point": {"row": 30, "column": 62}, "end_point": {"row": 30, "column": 63}}, {"id": 128, "type": "+", "text": "+", "parent": 115, "children": [], "start_point": {"row": 30, "column": 65}, "end_point": {"row": 30, "column": 66}}, {"id": 129, "type": "sizeof_expression", "text": "sizeof(struct Class *)", "parent": 115, "children": [130], "start_point": {"row": 30, "column": 67}, "end_point": {"row": 30, "column": 89}}, {"id": 130, "type": "type_descriptor", "text": "struct Class *", "parent": 129, "children": [131, 134], "start_point": {"row": 30, "column": 74}, "end_point": {"row": 30, "column": 88}}, {"id": 131, "type": "struct_specifier", "text": "struct Class", "parent": 130, "children": [132, 133], "start_point": {"row": 30, "column": 74}, "end_point": {"row": 30, "column": 86}}, {"id": 132, "type": "struct", "text": "struct", "parent": 131, "children": [], "start_point": {"row": 30, "column": 74}, "end_point": {"row": 30, "column": 80}}, {"id": 133, "type": "type_identifier", "text": "Class", "parent": 131, "children": [], "start_point": {"row": 30, "column": 81}, "end_point": {"row": 30, "column": 86}}, {"id": 134, "type": "abstract_pointer_declarator", "text": "*", "parent": 130, "children": [135], "start_point": {"row": 30, "column": 87}, "end_point": {"row": 30, "column": 88}}, {"id": 135, "type": "*", "text": "*", "parent": 134, "children": [], "start_point": {"row": 30, "column": 87}, "end_point": {"row": 30, "column": 88}}, {"id": 136, "type": "+", "text": "+", "parent": 114, "children": [], "start_point": {"row": 30, "column": 90}, "end_point": {"row": 30, "column": 91}}, {"id": 137, "type": "sizeof_expression", "text": "sizeof(UInteger)", "parent": 114, "children": [138], "start_point": {"row": 30, "column": 92}, "end_point": {"row": 30, "column": 108}}, {"id": 138, "type": "parenthesized_expression", "text": "(UInteger)", "parent": 137, "children": [139], "start_point": {"row": 30, "column": 98}, "end_point": {"row": 30, "column": 108}}, {"id": 139, "type": "identifier", "text": "UInteger", "parent": 138, "children": [], "start_point": {"row": 30, "column": 99}, "end_point": {"row": 30, "column": 107}}, {"id": 140, "type": "call_expression", "text": "memcpy((char *)self + offset, (char *)(self->super) + offset, sizeOf((void *)self->super) - offset)", "parent": 31, "children": [141, 142], "start_point": {"row": 31, "column": 1}, "end_point": {"row": 31, "column": 101}}, {"id": 141, "type": "identifier", "text": "memcpy", "parent": 140, "children": [], "start_point": {"row": 31, "column": 1}, "end_point": {"row": 31, "column": 7}}, {"id": 142, "type": "argument_list", "text": "((char *)self + offset, (char *)(self->super) + offset, sizeOf((void *)self->super) - offset)", "parent": 140, "children": [143, 152, 164], "start_point": {"row": 31, "column": 7}, "end_point": {"row": 31, "column": 101}}, {"id": 143, "type": "binary_expression", "text": "(char *)self + offset", "parent": 142, "children": [144, 150, 151], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 30}}, {"id": 144, "type": "cast_expression", "text": "(char *)self", "parent": 143, "children": [145, 149], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 20}}, {"id": 145, "type": "type_descriptor", "text": "char *", "parent": 144, "children": [146, 147], "start_point": {"row": 31, "column": 9}, "end_point": {"row": 31, "column": 15}}, {"id": 146, "type": "primitive_type", "text": "char", "parent": 145, "children": [], "start_point": {"row": 31, "column": 9}, "end_point": {"row": 31, "column": 13}}, {"id": 147, "type": "abstract_pointer_declarator", "text": "*", "parent": 145, "children": [148], "start_point": {"row": 31, "column": 14}, "end_point": {"row": 31, "column": 15}}, {"id": 148, "type": "*", "text": "*", "parent": 147, "children": [], "start_point": {"row": 31, "column": 14}, "end_point": {"row": 31, "column": 15}}, {"id": 149, "type": "identifier", "text": "self", "parent": 144, "children": [], "start_point": {"row": 31, "column": 16}, "end_point": {"row": 31, "column": 20}}, {"id": 150, "type": "+", "text": "+", "parent": 143, "children": [], "start_point": {"row": 31, "column": 22}, "end_point": {"row": 31, "column": 23}}, {"id": 151, "type": "identifier", "text": "offset", "parent": 143, "children": [], "start_point": {"row": 31, "column": 24}, "end_point": {"row": 31, "column": 30}}, {"id": 152, "type": "binary_expression", "text": "(char *)(self->super) + offset", "parent": 142, "children": [153, 162, 163], "start_point": {"row": 31, "column": 32}, "end_point": {"row": 31, "column": 62}}, {"id": 153, "type": "cast_expression", "text": "(char *)(self->super)", "parent": 152, "children": [154, 158], "start_point": {"row": 31, "column": 32}, "end_point": {"row": 31, "column": 53}}, {"id": 154, "type": "type_descriptor", "text": "char *", "parent": 153, "children": [155, 156], "start_point": {"row": 31, "column": 33}, "end_point": {"row": 31, "column": 39}}, {"id": 155, "type": "primitive_type", "text": "char", "parent": 154, "children": [], "start_point": {"row": 31, "column": 33}, "end_point": {"row": 31, "column": 37}}, {"id": 156, "type": "abstract_pointer_declarator", "text": "*", "parent": 154, "children": [157], "start_point": {"row": 31, "column": 38}, "end_point": {"row": 31, "column": 39}}, {"id": 157, "type": "*", "text": "*", "parent": 156, "children": [], "start_point": {"row": 31, "column": 38}, "end_point": {"row": 31, "column": 39}}, {"id": 158, "type": "parenthesized_expression", "text": "(self->super)", "parent": 153, "children": [159], "start_point": {"row": 31, "column": 40}, "end_point": {"row": 31, "column": 53}}, {"id": 159, "type": "field_expression", "text": "self->super", "parent": 158, "children": [160, 161], "start_point": {"row": 31, "column": 41}, "end_point": {"row": 31, "column": 52}}, {"id": 160, "type": "identifier", "text": "self", "parent": 159, "children": [], "start_point": {"row": 31, "column": 41}, "end_point": {"row": 31, "column": 45}}, {"id": 161, "type": "field_identifier", "text": "super", "parent": 159, "children": [], "start_point": {"row": 31, "column": 47}, "end_point": {"row": 31, "column": 52}}, {"id": 162, "type": "+", "text": "+", "parent": 152, "children": [], "start_point": {"row": 31, "column": 54}, "end_point": {"row": 31, "column": 55}}, {"id": 163, "type": "identifier", "text": "offset", "parent": 152, "children": [], "start_point": {"row": 31, "column": 56}, "end_point": {"row": 31, "column": 62}}, {"id": 164, "type": "binary_expression", "text": "sizeOf((void *)self->super) - offset", "parent": 142, "children": [165, 176, 177], "start_point": {"row": 31, "column": 64}, "end_point": {"row": 31, "column": 100}}, {"id": 165, "type": "call_expression", "text": "sizeOf((void *)self->super)", "parent": 164, "children": [166, 167], "start_point": {"row": 31, "column": 64}, "end_point": {"row": 31, "column": 91}}, {"id": 166, "type": "identifier", "text": "sizeOf", "parent": 165, "children": [], "start_point": {"row": 31, "column": 64}, "end_point": {"row": 31, "column": 70}}, {"id": 167, "type": "argument_list", "text": "((void *)self->super)", "parent": 165, "children": [168], "start_point": {"row": 31, "column": 70}, "end_point": {"row": 31, "column": 91}}, {"id": 168, "type": "cast_expression", "text": "(void *)self->super", "parent": 167, "children": [169, 173], "start_point": {"row": 31, "column": 71}, "end_point": {"row": 31, "column": 90}}, {"id": 169, "type": "type_descriptor", "text": "void *", "parent": 168, "children": [170, 171], "start_point": {"row": 31, "column": 72}, "end_point": {"row": 31, "column": 78}}, {"id": 170, "type": "primitive_type", "text": "void", "parent": 169, "children": [], "start_point": {"row": 31, "column": 72}, "end_point": {"row": 31, "column": 76}}, {"id": 171, "type": "abstract_pointer_declarator", "text": "*", "parent": 169, "children": [172], "start_point": {"row": 31, "column": 77}, "end_point": {"row": 31, "column": 78}}, {"id": 172, "type": "*", "text": "*", "parent": 171, "children": [], "start_point": {"row": 31, "column": 77}, "end_point": {"row": 31, "column": 78}}, {"id": 173, "type": "field_expression", "text": "self->super", "parent": 168, "children": [174, 175], "start_point": {"row": 31, "column": 79}, "end_point": {"row": 31, "column": 90}}, {"id": 174, "type": "identifier", "text": "self", "parent": 173, "children": [], "start_point": {"row": 31, "column": 79}, "end_point": {"row": 31, "column": 83}}, {"id": 175, "type": "field_identifier", "text": "super", "parent": 173, "children": [], "start_point": {"row": 31, "column": 85}, "end_point": {"row": 31, "column": 90}}, {"id": 176, "type": "-", "text": "-", "parent": 164, "children": [], "start_point": {"row": 31, "column": 92}, "end_point": {"row": 31, "column": 93}}, {"id": 177, "type": "identifier", "text": "offset", "parent": 164, "children": [], "start_point": {"row": 31, "column": 94}, "end_point": {"row": 31, "column": 100}}, {"id": 178, "type": "type_definition", "text": "typedef void (*voidf) ();", "parent": 31, "children": [179, 180, 181], "start_point": {"row": 33, "column": 2}, "end_point": {"row": 33, "column": 27}}, {"id": 179, "type": "typedef", "text": "typedef", "parent": 178, "children": [], "start_point": {"row": 33, "column": 2}, "end_point": {"row": 33, "column": 9}}, {"id": 180, "type": "primitive_type", "text": "void", "parent": 178, "children": [], "start_point": {"row": 33, "column": 10}, "end_point": {"row": 33, "column": 14}}, {"id": 181, "type": "function_declarator", "text": "(*voidf) ()", "parent": 178, "children": [182, 186], "start_point": {"row": 33, "column": 15}, "end_point": {"row": 33, "column": 26}}, {"id": 182, "type": "parenthesized_declarator", "text": "(*voidf)", "parent": 181, "children": [183], "start_point": {"row": 33, "column": 15}, "end_point": {"row": 33, "column": 23}}, {"id": 183, "type": "pointer_declarator", "text": "*voidf", "parent": 182, "children": [184, 185], "start_point": {"row": 33, "column": 16}, "end_point": {"row": 33, "column": 22}}, {"id": 184, "type": "*", "text": "*", "parent": 183, "children": [], "start_point": {"row": 33, "column": 16}, "end_point": {"row": 33, "column": 17}}, {"id": 185, "type": "type_identifier", "text": "voidf", "parent": 183, "children": [], "start_point": {"row": 33, "column": 17}, "end_point": {"row": 33, "column": 22}}, {"id": 186, "type": "parameter_list", "text": "()", "parent": 181, "children": [], "start_point": {"row": 33, "column": 24}, "end_point": {"row": 33, "column": 26}}, {"id": 187, "type": "declaration", "text": "voidf selector = NULL;", "parent": 31, "children": [188, 189], "start_point": {"row": 34, "column": 2}, "end_point": {"row": 34, "column": 24}}, {"id": 188, "type": "type_identifier", "text": "voidf", "parent": 187, "children": [], "start_point": {"row": 34, "column": 2}, "end_point": {"row": 34, "column": 7}}, {"id": 189, "type": "init_declarator", "text": "selector = NULL", "parent": 187, "children": [190, 191, 192], "start_point": {"row": 34, "column": 8}, "end_point": {"row": 34, "column": 23}}, {"id": 190, "type": "identifier", "text": "selector", "parent": 189, "children": [], "start_point": {"row": 34, "column": 8}, "end_point": {"row": 34, "column": 16}}, {"id": 191, "type": "=", "text": "=", "parent": 189, "children": [], "start_point": {"row": 34, "column": 17}, "end_point": {"row": 34, "column": 18}}, {"id": 192, "type": "null", "text": "NULL", "parent": 189, "children": [193], "start_point": {"row": 34, "column": 19}, "end_point": {"row": 34, "column": 23}}, {"id": 193, "type": "NULL", "text": "NULL", "parent": 192, "children": [], "start_point": {"row": 34, "column": 19}, "end_point": {"row": 34, "column": 23}}, {"id": 194, "type": "declaration", "text": "va_list ap;", "parent": 31, "children": [195, 196], "start_point": {"row": 35, "column": 2}, "end_point": {"row": 35, "column": 13}}, {"id": 195, "type": "type_identifier", "text": "va_list", "parent": 194, "children": [], "start_point": {"row": 35, "column": 2}, "end_point": {"row": 35, "column": 9}}, {"id": 196, "type": "identifier", "text": "ap", "parent": 194, "children": [], "start_point": {"row": 35, "column": 10}, "end_point": {"row": 35, "column": 12}}, {"id": 197, "type": "call_expression", "text": "va_copy(ap, *app)", "parent": 31, "children": [198, 199], "start_point": {"row": 36, "column": 2}, "end_point": {"row": 36, "column": 19}}, {"id": 198, "type": "identifier", "text": "va_copy", "parent": 197, "children": [], "start_point": {"row": 36, "column": 2}, "end_point": {"row": 36, "column": 9}}, {"id": 199, "type": "argument_list", "text": "(ap, *app)", "parent": 197, "children": [200, 201], "start_point": {"row": 36, "column": 9}, "end_point": {"row": 36, "column": 19}}, {"id": 200, "type": "identifier", "text": "ap", "parent": 199, "children": [], "start_point": {"row": 36, "column": 10}, "end_point": {"row": 36, "column": 12}}, {"id": 201, "type": "pointer_expression", "text": "*app", "parent": 199, "children": [202, 203], "start_point": {"row": 36, "column": 14}, "end_point": {"row": 36, "column": 18}}, {"id": 202, "type": "*", "text": "*", "parent": 201, "children": [], "start_point": {"row": 36, "column": 14}, "end_point": {"row": 36, "column": 15}}, {"id": 203, "type": "identifier", "text": "app", "parent": 201, "children": [], "start_point": {"row": 36, "column": 15}, "end_point": {"row": 36, "column": 18}}, {"id": 204, "type": "while_statement", "text": "while ( (selector = va_arg(ap, voidf)) ) {\n\t\t\tvoidf method = va_arg(ap, voidf);\n\t\t\t\n\t\t\tif ( selector == (voidf) constructor )\n\t\t\t\t* (voidf *) & self->constructor = method;\n\t\t\telse if ( selector == (voidf) destructor )\n\t\t\t\t* (voidf *) & self->destructor = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copy )\n\t\t\t\t* (voidf *) & self->copy = method;\n\t\t\telse if ( selector == (voidf) equals )\n\t\t\t\t* (voidf *) & self->equals = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) hash )\n\t\t\t\t* (voidf *) & self->hash = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;\n\t\t}", "parent": 31, "children": [205], "start_point": {"row": 38, "column": 2}, "end_point": {"row": 66, "column": 3}}, {"id": 205, "type": "parenthesized_expression", "text": "( (selector = va_arg(ap, voidf)) )", "parent": 204, "children": [206], "start_point": {"row": 38, "column": 8}, "end_point": {"row": 38, "column": 42}}, {"id": 206, "type": "parenthesized_expression", "text": "(selector = va_arg(ap, voidf))", "parent": 205, "children": [207], "start_point": {"row": 38, "column": 10}, "end_point": {"row": 38, "column": 40}}, {"id": 207, "type": "assignment_expression", "text": "selector = va_arg(ap, voidf)", "parent": 206, "children": [208, 209, 210], "start_point": {"row": 38, "column": 11}, "end_point": {"row": 38, "column": 39}}, {"id": 208, "type": "identifier", "text": "selector", "parent": 207, "children": [], "start_point": {"row": 38, "column": 11}, "end_point": {"row": 38, "column": 19}}, {"id": 209, "type": "=", "text": "=", "parent": 207, "children": [], "start_point": {"row": 38, "column": 20}, "end_point": {"row": 38, "column": 21}}, {"id": 210, "type": "call_expression", "text": "va_arg(ap, voidf)", "parent": 207, "children": [211, 212], "start_point": {"row": 38, "column": 22}, "end_point": {"row": 38, "column": 39}}, {"id": 211, "type": "identifier", "text": "va_arg", "parent": 210, "children": [], "start_point": {"row": 38, "column": 22}, "end_point": {"row": 38, "column": 28}}, {"id": 212, "type": "argument_list", "text": "(ap, voidf)", "parent": 210, "children": [213, 214], "start_point": {"row": 38, "column": 28}, "end_point": {"row": 38, "column": 39}}, {"id": 213, "type": "identifier", "text": "ap", "parent": 212, "children": [], "start_point": {"row": 38, "column": 29}, "end_point": {"row": 38, "column": 31}}, {"id": 214, "type": "identifier", "text": "voidf", "parent": 212, "children": [], "start_point": {"row": 38, "column": 33}, "end_point": {"row": 38, "column": 38}}, {"id": 215, "type": "declaration", "text": "voidf method = va_arg(ap, voidf);", "parent": 204, "children": [216, 217], "start_point": {"row": 39, "column": 3}, "end_point": {"row": 39, "column": 36}}, {"id": 216, "type": "type_identifier", "text": "voidf", "parent": 215, "children": [], "start_point": {"row": 39, "column": 3}, "end_point": {"row": 39, "column": 8}}, {"id": 217, "type": "init_declarator", "text": "method = va_arg(ap, voidf)", "parent": 215, "children": [218, 219, 220], "start_point": {"row": 39, "column": 9}, "end_point": {"row": 39, "column": 35}}, {"id": 218, "type": "identifier", "text": "method", "parent": 217, "children": [], "start_point": {"row": 39, "column": 9}, "end_point": {"row": 39, "column": 15}}, {"id": 219, "type": "=", "text": "=", "parent": 217, "children": [], "start_point": {"row": 39, "column": 16}, "end_point": {"row": 39, "column": 17}}, {"id": 220, "type": "call_expression", "text": "va_arg(ap, voidf)", "parent": 217, "children": [221, 222], "start_point": {"row": 39, "column": 18}, "end_point": {"row": 39, "column": 35}}, {"id": 221, "type": "identifier", "text": "va_arg", "parent": 220, "children": [], "start_point": {"row": 39, "column": 18}, "end_point": {"row": 39, "column": 24}}, {"id": 222, "type": "argument_list", "text": "(ap, voidf)", "parent": 220, "children": [223, 224], "start_point": {"row": 39, "column": 24}, "end_point": {"row": 39, "column": 35}}, {"id": 223, "type": "identifier", "text": "ap", "parent": 222, "children": [], "start_point": {"row": 39, "column": 25}, "end_point": {"row": 39, "column": 27}}, {"id": 224, "type": "identifier", "text": "voidf", "parent": 222, "children": [], "start_point": {"row": 39, "column": 29}, "end_point": {"row": 39, "column": 34}}, {"id": 225, "type": "if_statement", "text": "if ( selector == (voidf) constructor )\n\t\t\t\t* (voidf *) & self->constructor = method;\n\t\t\telse if ( selector == (voidf) destructor )\n\t\t\t\t* (voidf *) & self->destructor = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copy )\n\t\t\t\t* (voidf *) & self->copy = method;\n\t\t\telse if ( selector == (voidf) equals )\n\t\t\t\t* (voidf *) & self->equals = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) hash )\n\t\t\t\t* (voidf *) & self->hash = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 204, "children": [226, 248], "start_point": {"row": 41, "column": 3}, "end_point": {"row": 65, "column": 45}}, {"id": 226, "type": "parenthesized_expression", "text": "( selector == (voidf) constructor )", "parent": 225, "children": [227], "start_point": {"row": 41, "column": 6}, "end_point": {"row": 41, "column": 41}}, {"id": 227, "type": "binary_expression", "text": "selector == (voidf) constructor", "parent": 226, "children": [228, 229, 230], "start_point": {"row": 41, "column": 8}, "end_point": {"row": 41, "column": 39}}, {"id": 228, "type": "identifier", "text": "selector", "parent": 227, "children": [], "start_point": {"row": 41, "column": 8}, "end_point": {"row": 41, "column": 16}}, {"id": 229, "type": "==", "text": "==", "parent": 227, "children": [], "start_point": {"row": 41, "column": 17}, "end_point": {"row": 41, "column": 19}}, {"id": 230, "type": "cast_expression", "text": "(voidf) constructor", "parent": 227, "children": [231, 233], "start_point": {"row": 41, "column": 20}, "end_point": {"row": 41, "column": 39}}, {"id": 231, "type": "type_descriptor", "text": "voidf", "parent": 230, "children": [232], "start_point": {"row": 41, "column": 21}, "end_point": {"row": 41, "column": 26}}, {"id": 232, "type": "type_identifier", "text": "voidf", "parent": 231, "children": [], "start_point": {"row": 41, "column": 21}, "end_point": {"row": 41, "column": 26}}, {"id": 233, "type": "identifier", "text": "constructor", "parent": 230, "children": [], "start_point": {"row": 41, "column": 28}, "end_point": {"row": 41, "column": 39}}, {"id": 234, "type": "assignment_expression", "text": "* (voidf *) & self->constructor = method", "parent": 225, "children": [235, 246, 247], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 44}}, {"id": 235, "type": "pointer_expression", "text": "* (voidf *) & self->constructor", "parent": 234, "children": [236, 237], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 35}}, {"id": 236, "type": "*", "text": "*", "parent": 235, "children": [], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 5}}, {"id": 237, "type": "cast_expression", "text": "(voidf *) & self->constructor", "parent": 235, "children": [238, 242], "start_point": {"row": 42, "column": 6}, "end_point": {"row": 42, "column": 35}}, {"id": 238, "type": "type_descriptor", "text": "voidf *", "parent": 237, "children": [239, 240], "start_point": {"row": 42, "column": 7}, "end_point": {"row": 42, "column": 14}}, {"id": 239, "type": "type_identifier", "text": "voidf", "parent": 238, "children": [], "start_point": {"row": 42, "column": 7}, "end_point": {"row": 42, "column": 12}}, {"id": 240, "type": "abstract_pointer_declarator", "text": "*", "parent": 238, "children": [241], "start_point": {"row": 42, "column": 13}, "end_point": {"row": 42, "column": 14}}, {"id": 241, "type": "*", "text": "*", "parent": 240, "children": [], "start_point": {"row": 42, "column": 13}, "end_point": {"row": 42, "column": 14}}, {"id": 242, "type": "pointer_expression", "text": "& self->constructor", "parent": 237, "children": [243], "start_point": {"row": 42, "column": 16}, "end_point": {"row": 42, "column": 35}}, {"id": 243, "type": "field_expression", "text": "self->constructor", "parent": 242, "children": [244, 245], "start_point": {"row": 42, "column": 18}, "end_point": {"row": 42, "column": 35}}, {"id": 244, "type": "identifier", "text": "self", "parent": 243, "children": [], "start_point": {"row": 42, "column": 18}, "end_point": {"row": 42, "column": 22}}, {"id": 245, "type": "field_identifier", "text": "constructor", "parent": 243, "children": [], "start_point": {"row": 42, "column": 24}, "end_point": {"row": 42, "column": 35}}, {"id": 246, "type": "=", "text": "=", "parent": 234, "children": [], "start_point": {"row": 42, "column": 36}, "end_point": {"row": 42, "column": 37}}, {"id": 247, "type": "identifier", "text": "method", "parent": 234, "children": [], "start_point": {"row": 42, "column": 38}, "end_point": {"row": 42, "column": 44}}, {"id": 248, "type": "else_clause", "text": "else if ( selector == (voidf) destructor )\n\t\t\t\t* (voidf *) & self->destructor = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copy )\n\t\t\t\t* (voidf *) & self->copy = method;\n\t\t\telse if ( selector == (voidf) equals )\n\t\t\t\t* (voidf *) & self->equals = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) hash )\n\t\t\t\t* (voidf *) & self->hash = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 225, "children": [249], "start_point": {"row": 43, "column": 3}, "end_point": {"row": 65, "column": 45}}, {"id": 249, "type": "if_statement", "text": "if ( selector == (voidf) destructor )\n\t\t\t\t* (voidf *) & self->destructor = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copy )\n\t\t\t\t* (voidf *) & self->copy = method;\n\t\t\telse if ( selector == (voidf) equals )\n\t\t\t\t* (voidf *) & self->equals = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) hash )\n\t\t\t\t* (voidf *) & self->hash = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 248, "children": [250, 272], "start_point": {"row": 43, "column": 8}, "end_point": {"row": 65, "column": 45}}, {"id": 250, "type": "parenthesized_expression", "text": "( selector == (voidf) destructor )", "parent": 249, "children": [251], "start_point": {"row": 43, "column": 11}, "end_point": {"row": 43, "column": 45}}, {"id": 251, "type": "binary_expression", "text": "selector == (voidf) destructor", "parent": 250, "children": [252, 253, 254], "start_point": {"row": 43, "column": 13}, "end_point": {"row": 43, "column": 43}}, {"id": 252, "type": "identifier", "text": "selector", "parent": 251, "children": [], "start_point": {"row": 43, "column": 13}, "end_point": {"row": 43, "column": 21}}, {"id": 253, "type": "==", "text": "==", "parent": 251, "children": [], "start_point": {"row": 43, "column": 22}, "end_point": {"row": 43, "column": 24}}, {"id": 254, "type": "cast_expression", "text": "(voidf) destructor", "parent": 251, "children": [255, 257], "start_point": {"row": 43, "column": 25}, "end_point": {"row": 43, "column": 43}}, {"id": 255, "type": "type_descriptor", "text": "voidf", "parent": 254, "children": [256], "start_point": {"row": 43, "column": 26}, "end_point": {"row": 43, "column": 31}}, {"id": 256, "type": "type_identifier", "text": "voidf", "parent": 255, "children": [], "start_point": {"row": 43, "column": 26}, "end_point": {"row": 43, "column": 31}}, {"id": 257, "type": "identifier", "text": "destructor", "parent": 254, "children": [], "start_point": {"row": 43, "column": 33}, "end_point": {"row": 43, "column": 43}}, {"id": 258, "type": "assignment_expression", "text": "* (voidf *) & self->destructor = method", "parent": 249, "children": [259, 270, 271], "start_point": {"row": 44, "column": 4}, "end_point": {"row": 44, "column": 43}}, {"id": 259, "type": "pointer_expression", "text": "* (voidf *) & self->destructor", "parent": 258, "children": [260, 261], "start_point": {"row": 44, "column": 4}, "end_point": {"row": 44, "column": 34}}, {"id": 260, "type": "*", "text": "*", "parent": 259, "children": [], "start_point": {"row": 44, "column": 4}, "end_point": {"row": 44, "column": 5}}, {"id": 261, "type": "cast_expression", "text": "(voidf *) & self->destructor", "parent": 259, "children": [262, 266], "start_point": {"row": 44, "column": 6}, "end_point": {"row": 44, "column": 34}}, {"id": 262, "type": "type_descriptor", "text": "voidf *", "parent": 261, "children": [263, 264], "start_point": {"row": 44, "column": 7}, "end_point": {"row": 44, "column": 14}}, {"id": 263, "type": "type_identifier", "text": "voidf", "parent": 262, "children": [], "start_point": {"row": 44, "column": 7}, "end_point": {"row": 44, "column": 12}}, {"id": 264, "type": "abstract_pointer_declarator", "text": "*", "parent": 262, "children": [265], "start_point": {"row": 44, "column": 13}, "end_point": {"row": 44, "column": 14}}, {"id": 265, "type": "*", "text": "*", "parent": 264, "children": [], "start_point": {"row": 44, "column": 13}, "end_point": {"row": 44, "column": 14}}, {"id": 266, "type": "pointer_expression", "text": "& self->destructor", "parent": 261, "children": [267], "start_point": {"row": 44, "column": 16}, "end_point": {"row": 44, "column": 34}}, {"id": 267, "type": "field_expression", "text": "self->destructor", "parent": 266, "children": [268, 269], "start_point": {"row": 44, "column": 18}, "end_point": {"row": 44, "column": 34}}, {"id": 268, "type": "identifier", "text": "self", "parent": 267, "children": [], "start_point": {"row": 44, "column": 18}, "end_point": {"row": 44, "column": 22}}, {"id": 269, "type": "field_identifier", "text": "destructor", "parent": 267, "children": [], "start_point": {"row": 44, "column": 24}, "end_point": {"row": 44, "column": 34}}, {"id": 270, "type": "=", "text": "=", "parent": 258, "children": [], "start_point": {"row": 44, "column": 35}, "end_point": {"row": 44, "column": 36}}, {"id": 271, "type": "identifier", "text": "method", "parent": 258, "children": [], "start_point": {"row": 44, "column": 37}, "end_point": {"row": 44, "column": 43}}, {"id": 272, "type": "else_clause", "text": "else if ( selector == (voidf) copy )\n\t\t\t\t* (voidf *) & self->copy = method;\n\t\t\telse if ( selector == (voidf) equals )\n\t\t\t\t* (voidf *) & self->equals = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) hash )\n\t\t\t\t* (voidf *) & self->hash = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 249, "children": [273], "start_point": {"row": 46, "column": 3}, "end_point": {"row": 65, "column": 45}}, {"id": 273, "type": "if_statement", "text": "if ( selector == (voidf) copy )\n\t\t\t\t* (voidf *) & self->copy = method;\n\t\t\telse if ( selector == (voidf) equals )\n\t\t\t\t* (voidf *) & self->equals = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) hash )\n\t\t\t\t* (voidf *) & self->hash = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 272, "children": [274, 296], "start_point": {"row": 46, "column": 8}, "end_point": {"row": 65, "column": 45}}, {"id": 274, "type": "parenthesized_expression", "text": "( selector == (voidf) copy )", "parent": 273, "children": [275], "start_point": {"row": 46, "column": 11}, "end_point": {"row": 46, "column": 39}}, {"id": 275, "type": "binary_expression", "text": "selector == (voidf) copy", "parent": 274, "children": [276, 277, 278], "start_point": {"row": 46, "column": 13}, "end_point": {"row": 46, "column": 37}}, {"id": 276, "type": "identifier", "text": "selector", "parent": 275, "children": [], "start_point": {"row": 46, "column": 13}, "end_point": {"row": 46, "column": 21}}, {"id": 277, "type": "==", "text": "==", "parent": 275, "children": [], "start_point": {"row": 46, "column": 22}, "end_point": {"row": 46, "column": 24}}, {"id": 278, "type": "cast_expression", "text": "(voidf) copy", "parent": 275, "children": [279, 281], "start_point": {"row": 46, "column": 25}, "end_point": {"row": 46, "column": 37}}, {"id": 279, "type": "type_descriptor", "text": "voidf", "parent": 278, "children": [280], "start_point": {"row": 46, "column": 26}, "end_point": {"row": 46, "column": 31}}, {"id": 280, "type": "type_identifier", "text": "voidf", "parent": 279, "children": [], "start_point": {"row": 46, "column": 26}, "end_point": {"row": 46, "column": 31}}, {"id": 281, "type": "identifier", "text": "copy", "parent": 278, "children": [], "start_point": {"row": 46, "column": 33}, "end_point": {"row": 46, "column": 37}}, {"id": 282, "type": "assignment_expression", "text": "* (voidf *) & self->copy = method", "parent": 273, "children": [283, 294, 295], "start_point": {"row": 47, "column": 4}, "end_point": {"row": 47, "column": 37}}, {"id": 283, "type": "pointer_expression", "text": "* (voidf *) & self->copy", "parent": 282, "children": [284, 285], "start_point": {"row": 47, "column": 4}, "end_point": {"row": 47, "column": 28}}, {"id": 284, "type": "*", "text": "*", "parent": 283, "children": [], "start_point": {"row": 47, "column": 4}, "end_point": {"row": 47, "column": 5}}, {"id": 285, "type": "cast_expression", "text": "(voidf *) & self->copy", "parent": 283, "children": [286, 290], "start_point": {"row": 47, "column": 6}, "end_point": {"row": 47, "column": 28}}, {"id": 286, "type": "type_descriptor", "text": "voidf *", "parent": 285, "children": [287, 288], "start_point": {"row": 47, "column": 7}, "end_point": {"row": 47, "column": 14}}, {"id": 287, "type": "type_identifier", "text": "voidf", "parent": 286, "children": [], "start_point": {"row": 47, "column": 7}, "end_point": {"row": 47, "column": 12}}, {"id": 288, "type": "abstract_pointer_declarator", "text": "*", "parent": 286, "children": [289], "start_point": {"row": 47, "column": 13}, "end_point": {"row": 47, "column": 14}}, {"id": 289, "type": "*", "text": "*", "parent": 288, "children": [], "start_point": {"row": 47, "column": 13}, "end_point": {"row": 47, "column": 14}}, {"id": 290, "type": "pointer_expression", "text": "& self->copy", "parent": 285, "children": [291], "start_point": {"row": 47, "column": 16}, "end_point": {"row": 47, "column": 28}}, {"id": 291, "type": "field_expression", "text": "self->copy", "parent": 290, "children": [292, 293], "start_point": {"row": 47, "column": 18}, "end_point": {"row": 47, "column": 28}}, {"id": 292, "type": "identifier", "text": "self", "parent": 291, "children": [], "start_point": {"row": 47, "column": 18}, "end_point": {"row": 47, "column": 22}}, {"id": 293, "type": "field_identifier", "text": "copy", "parent": 291, "children": [], "start_point": {"row": 47, "column": 24}, "end_point": {"row": 47, "column": 28}}, {"id": 294, "type": "=", "text": "=", "parent": 282, "children": [], "start_point": {"row": 47, "column": 29}, "end_point": {"row": 47, "column": 30}}, {"id": 295, "type": "identifier", "text": "method", "parent": 282, "children": [], "start_point": {"row": 47, "column": 31}, "end_point": {"row": 47, "column": 37}}, {"id": 296, "type": "else_clause", "text": "else if ( selector == (voidf) equals )\n\t\t\t\t* (voidf *) & self->equals = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) hash )\n\t\t\t\t* (voidf *) & self->hash = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 273, "children": [297], "start_point": {"row": 48, "column": 3}, "end_point": {"row": 65, "column": 45}}, {"id": 297, "type": "if_statement", "text": "if ( selector == (voidf) equals )\n\t\t\t\t* (voidf *) & self->equals = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) hash )\n\t\t\t\t* (voidf *) & self->hash = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 296, "children": [298, 320], "start_point": {"row": 48, "column": 8}, "end_point": {"row": 65, "column": 45}}, {"id": 298, "type": "parenthesized_expression", "text": "( selector == (voidf) equals )", "parent": 297, "children": [299], "start_point": {"row": 48, "column": 11}, "end_point": {"row": 48, "column": 41}}, {"id": 299, "type": "binary_expression", "text": "selector == (voidf) equals", "parent": 298, "children": [300, 301, 302], "start_point": {"row": 48, "column": 13}, "end_point": {"row": 48, "column": 39}}, {"id": 300, "type": "identifier", "text": "selector", "parent": 299, "children": [], "start_point": {"row": 48, "column": 13}, "end_point": {"row": 48, "column": 21}}, {"id": 301, "type": "==", "text": "==", "parent": 299, "children": [], "start_point": {"row": 48, "column": 22}, "end_point": {"row": 48, "column": 24}}, {"id": 302, "type": "cast_expression", "text": "(voidf) equals", "parent": 299, "children": [303, 305], "start_point": {"row": 48, "column": 25}, "end_point": {"row": 48, "column": 39}}, {"id": 303, "type": "type_descriptor", "text": "voidf", "parent": 302, "children": [304], "start_point": {"row": 48, "column": 26}, "end_point": {"row": 48, "column": 31}}, {"id": 304, "type": "type_identifier", "text": "voidf", "parent": 303, "children": [], "start_point": {"row": 48, "column": 26}, "end_point": {"row": 48, "column": 31}}, {"id": 305, "type": "identifier", "text": "equals", "parent": 302, "children": [], "start_point": {"row": 48, "column": 33}, "end_point": {"row": 48, "column": 39}}, {"id": 306, "type": "assignment_expression", "text": "* (voidf *) & self->equals = method", "parent": 297, "children": [307, 318, 319], "start_point": {"row": 49, "column": 4}, "end_point": {"row": 49, "column": 39}}, {"id": 307, "type": "pointer_expression", "text": "* (voidf *) & self->equals", "parent": 306, "children": [308, 309], "start_point": {"row": 49, "column": 4}, "end_point": {"row": 49, "column": 30}}, {"id": 308, "type": "*", "text": "*", "parent": 307, "children": [], "start_point": {"row": 49, "column": 4}, "end_point": {"row": 49, "column": 5}}, {"id": 309, "type": "cast_expression", "text": "(voidf *) & self->equals", "parent": 307, "children": [310, 314], "start_point": {"row": 49, "column": 6}, "end_point": {"row": 49, "column": 30}}, {"id": 310, "type": "type_descriptor", "text": "voidf *", "parent": 309, "children": [311, 312], "start_point": {"row": 49, "column": 7}, "end_point": {"row": 49, "column": 14}}, {"id": 311, "type": "type_identifier", "text": "voidf", "parent": 310, "children": [], "start_point": {"row": 49, "column": 7}, "end_point": {"row": 49, "column": 12}}, {"id": 312, "type": "abstract_pointer_declarator", "text": "*", "parent": 310, "children": [313], "start_point": {"row": 49, "column": 13}, "end_point": {"row": 49, "column": 14}}, {"id": 313, "type": "*", "text": "*", "parent": 312, "children": [], "start_point": {"row": 49, "column": 13}, "end_point": {"row": 49, "column": 14}}, {"id": 314, "type": "pointer_expression", "text": "& self->equals", "parent": 309, "children": [315], "start_point": {"row": 49, "column": 16}, "end_point": {"row": 49, "column": 30}}, {"id": 315, "type": "field_expression", "text": "self->equals", "parent": 314, "children": [316, 317], "start_point": {"row": 49, "column": 18}, "end_point": {"row": 49, "column": 30}}, {"id": 316, "type": "identifier", "text": "self", "parent": 315, "children": [], "start_point": {"row": 49, "column": 18}, "end_point": {"row": 49, "column": 22}}, {"id": 317, "type": "field_identifier", "text": "equals", "parent": 315, "children": [], "start_point": {"row": 49, "column": 24}, "end_point": {"row": 49, "column": 30}}, {"id": 318, "type": "=", "text": "=", "parent": 306, "children": [], "start_point": {"row": 49, "column": 31}, "end_point": {"row": 49, "column": 32}}, {"id": 319, "type": "identifier", "text": "method", "parent": 306, "children": [], "start_point": {"row": 49, "column": 33}, "end_point": {"row": 49, "column": 39}}, {"id": 320, "type": "else_clause", "text": "else if ( selector == (voidf) hash )\n\t\t\t\t* (voidf *) & self->hash = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 297, "children": [321], "start_point": {"row": 51, "column": 3}, "end_point": {"row": 65, "column": 45}}, {"id": 321, "type": "if_statement", "text": "if ( selector == (voidf) hash )\n\t\t\t\t* (voidf *) & self->hash = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 320, "children": [322, 344], "start_point": {"row": 51, "column": 8}, "end_point": {"row": 65, "column": 45}}, {"id": 322, "type": "parenthesized_expression", "text": "( selector == (voidf) hash )", "parent": 321, "children": [323], "start_point": {"row": 51, "column": 11}, "end_point": {"row": 51, "column": 39}}, {"id": 323, "type": "binary_expression", "text": "selector == (voidf) hash", "parent": 322, "children": [324, 325, 326], "start_point": {"row": 51, "column": 13}, "end_point": {"row": 51, "column": 37}}, {"id": 324, "type": "identifier", "text": "selector", "parent": 323, "children": [], "start_point": {"row": 51, "column": 13}, "end_point": {"row": 51, "column": 21}}, {"id": 325, "type": "==", "text": "==", "parent": 323, "children": [], "start_point": {"row": 51, "column": 22}, "end_point": {"row": 51, "column": 24}}, {"id": 326, "type": "cast_expression", "text": "(voidf) hash", "parent": 323, "children": [327, 329], "start_point": {"row": 51, "column": 25}, "end_point": {"row": 51, "column": 37}}, {"id": 327, "type": "type_descriptor", "text": "voidf", "parent": 326, "children": [328], "start_point": {"row": 51, "column": 26}, "end_point": {"row": 51, "column": 31}}, {"id": 328, "type": "type_identifier", "text": "voidf", "parent": 327, "children": [], "start_point": {"row": 51, "column": 26}, "end_point": {"row": 51, "column": 31}}, {"id": 329, "type": "identifier", "text": "hash", "parent": 326, "children": [], "start_point": {"row": 51, "column": 33}, "end_point": {"row": 51, "column": 37}}, {"id": 330, "type": "assignment_expression", "text": "* (voidf *) & self->hash = method", "parent": 321, "children": [331, 342, 343], "start_point": {"row": 52, "column": 4}, "end_point": {"row": 52, "column": 37}}, {"id": 331, "type": "pointer_expression", "text": "* (voidf *) & self->hash", "parent": 330, "children": [332, 333], "start_point": {"row": 52, "column": 4}, "end_point": {"row": 52, "column": 28}}, {"id": 332, "type": "*", "text": "*", "parent": 331, "children": [], "start_point": {"row": 52, "column": 4}, "end_point": {"row": 52, "column": 5}}, {"id": 333, "type": "cast_expression", "text": "(voidf *) & self->hash", "parent": 331, "children": [334, 338], "start_point": {"row": 52, "column": 6}, "end_point": {"row": 52, "column": 28}}, {"id": 334, "type": "type_descriptor", "text": "voidf *", "parent": 333, "children": [335, 336], "start_point": {"row": 52, "column": 7}, "end_point": {"row": 52, "column": 14}}, {"id": 335, "type": "type_identifier", "text": "voidf", "parent": 334, "children": [], "start_point": {"row": 52, "column": 7}, "end_point": {"row": 52, "column": 12}}, {"id": 336, "type": "abstract_pointer_declarator", "text": "*", "parent": 334, "children": [337], "start_point": {"row": 52, "column": 13}, "end_point": {"row": 52, "column": 14}}, {"id": 337, "type": "*", "text": "*", "parent": 336, "children": [], "start_point": {"row": 52, "column": 13}, "end_point": {"row": 52, "column": 14}}, {"id": 338, "type": "pointer_expression", "text": "& self->hash", "parent": 333, "children": [339], "start_point": {"row": 52, "column": 16}, "end_point": {"row": 52, "column": 28}}, {"id": 339, "type": "field_expression", "text": "self->hash", "parent": 338, "children": [340, 341], "start_point": {"row": 52, "column": 18}, "end_point": {"row": 52, "column": 28}}, {"id": 340, "type": "identifier", "text": "self", "parent": 339, "children": [], "start_point": {"row": 52, "column": 18}, "end_point": {"row": 52, "column": 22}}, {"id": 341, "type": "field_identifier", "text": "hash", "parent": 339, "children": [], "start_point": {"row": 52, "column": 24}, "end_point": {"row": 52, "column": 28}}, {"id": 342, "type": "=", "text": "=", "parent": 330, "children": [], "start_point": {"row": 52, "column": 29}, "end_point": {"row": 52, "column": 30}}, {"id": 343, "type": "identifier", "text": "method", "parent": 330, "children": [], "start_point": {"row": 52, "column": 31}, "end_point": {"row": 52, "column": 37}}, {"id": 344, "type": "else_clause", "text": "else if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 321, "children": [345], "start_point": {"row": 54, "column": 3}, "end_point": {"row": 65, "column": 45}}, {"id": 345, "type": "if_statement", "text": "if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 344, "children": [346, 368], "start_point": {"row": 54, "column": 8}, "end_point": {"row": 65, "column": 45}}, {"id": 346, "type": "parenthesized_expression", "text": "( selector == (voidf) retain )", "parent": 345, "children": [347], "start_point": {"row": 54, "column": 11}, "end_point": {"row": 54, "column": 41}}, {"id": 347, "type": "binary_expression", "text": "selector == (voidf) retain", "parent": 346, "children": [348, 349, 350], "start_point": {"row": 54, "column": 13}, "end_point": {"row": 54, "column": 39}}, {"id": 348, "type": "identifier", "text": "selector", "parent": 347, "children": [], "start_point": {"row": 54, "column": 13}, "end_point": {"row": 54, "column": 21}}, {"id": 349, "type": "==", "text": "==", "parent": 347, "children": [], "start_point": {"row": 54, "column": 22}, "end_point": {"row": 54, "column": 24}}, {"id": 350, "type": "cast_expression", "text": "(voidf) retain", "parent": 347, "children": [351, 353], "start_point": {"row": 54, "column": 25}, "end_point": {"row": 54, "column": 39}}, {"id": 351, "type": "type_descriptor", "text": "voidf", "parent": 350, "children": [352], "start_point": {"row": 54, "column": 26}, "end_point": {"row": 54, "column": 31}}, {"id": 352, "type": "type_identifier", "text": "voidf", "parent": 351, "children": [], "start_point": {"row": 54, "column": 26}, "end_point": {"row": 54, "column": 31}}, {"id": 353, "type": "identifier", "text": "retain", "parent": 350, "children": [], "start_point": {"row": 54, "column": 33}, "end_point": {"row": 54, "column": 39}}, {"id": 354, "type": "assignment_expression", "text": "* (voidf *) & self->retain = method", "parent": 345, "children": [355, 366, 367], "start_point": {"row": 55, "column": 4}, "end_point": {"row": 55, "column": 39}}, {"id": 355, "type": "pointer_expression", "text": "* (voidf *) & self->retain", "parent": 354, "children": [356, 357], "start_point": {"row": 55, "column": 4}, "end_point": {"row": 55, "column": 30}}, {"id": 356, "type": "*", "text": "*", "parent": 355, "children": [], "start_point": {"row": 55, "column": 4}, "end_point": {"row": 55, "column": 5}}, {"id": 357, "type": "cast_expression", "text": "(voidf *) & self->retain", "parent": 355, "children": [358, 362], "start_point": {"row": 55, "column": 6}, "end_point": {"row": 55, "column": 30}}, {"id": 358, "type": "type_descriptor", "text": "voidf *", "parent": 357, "children": [359, 360], "start_point": {"row": 55, "column": 7}, "end_point": {"row": 55, "column": 14}}, {"id": 359, "type": "type_identifier", "text": "voidf", "parent": 358, "children": [], "start_point": {"row": 55, "column": 7}, "end_point": {"row": 55, "column": 12}}, {"id": 360, "type": "abstract_pointer_declarator", "text": "*", "parent": 358, "children": [361], "start_point": {"row": 55, "column": 13}, "end_point": {"row": 55, "column": 14}}, {"id": 361, "type": "*", "text": "*", "parent": 360, "children": [], "start_point": {"row": 55, "column": 13}, "end_point": {"row": 55, "column": 14}}, {"id": 362, "type": "pointer_expression", "text": "& self->retain", "parent": 357, "children": [363], "start_point": {"row": 55, "column": 16}, "end_point": {"row": 55, "column": 30}}, {"id": 363, "type": "field_expression", "text": "self->retain", "parent": 362, "children": [364, 365], "start_point": {"row": 55, "column": 18}, "end_point": {"row": 55, "column": 30}}, {"id": 364, "type": "identifier", "text": "self", "parent": 363, "children": [], "start_point": {"row": 55, "column": 18}, "end_point": {"row": 55, "column": 22}}, {"id": 365, "type": "field_identifier", "text": "retain", "parent": 363, "children": [], "start_point": {"row": 55, "column": 24}, "end_point": {"row": 55, "column": 30}}, {"id": 366, "type": "=", "text": "=", "parent": 354, "children": [], "start_point": {"row": 55, "column": 31}, "end_point": {"row": 55, "column": 32}}, {"id": 367, "type": "identifier", "text": "method", "parent": 354, "children": [], "start_point": {"row": 55, "column": 33}, "end_point": {"row": 55, "column": 39}}, {"id": 368, "type": "else_clause", "text": "else if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 345, "children": [369], "start_point": {"row": 56, "column": 3}, "end_point": {"row": 65, "column": 45}}, {"id": 369, "type": "if_statement", "text": "if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 368, "children": [370, 392], "start_point": {"row": 56, "column": 8}, "end_point": {"row": 65, "column": 45}}, {"id": 370, "type": "parenthesized_expression", "text": "( selector == (voidf) release )", "parent": 369, "children": [371], "start_point": {"row": 56, "column": 11}, "end_point": {"row": 56, "column": 42}}, {"id": 371, "type": "binary_expression", "text": "selector == (voidf) release", "parent": 370, "children": [372, 373, 374], "start_point": {"row": 56, "column": 13}, "end_point": {"row": 56, "column": 40}}, {"id": 372, "type": "identifier", "text": "selector", "parent": 371, "children": [], "start_point": {"row": 56, "column": 13}, "end_point": {"row": 56, "column": 21}}, {"id": 373, "type": "==", "text": "==", "parent": 371, "children": [], "start_point": {"row": 56, "column": 22}, "end_point": {"row": 56, "column": 24}}, {"id": 374, "type": "cast_expression", "text": "(voidf) release", "parent": 371, "children": [375, 377], "start_point": {"row": 56, "column": 25}, "end_point": {"row": 56, "column": 40}}, {"id": 375, "type": "type_descriptor", "text": "voidf", "parent": 374, "children": [376], "start_point": {"row": 56, "column": 26}, "end_point": {"row": 56, "column": 31}}, {"id": 376, "type": "type_identifier", "text": "voidf", "parent": 375, "children": [], "start_point": {"row": 56, "column": 26}, "end_point": {"row": 56, "column": 31}}, {"id": 377, "type": "identifier", "text": "release", "parent": 374, "children": [], "start_point": {"row": 56, "column": 33}, "end_point": {"row": 56, "column": 40}}, {"id": 378, "type": "assignment_expression", "text": "* (voidf *) & self->release = method", "parent": 369, "children": [379, 390, 391], "start_point": {"row": 57, "column": 4}, "end_point": {"row": 57, "column": 40}}, {"id": 379, "type": "pointer_expression", "text": "* (voidf *) & self->release", "parent": 378, "children": [380, 381], "start_point": {"row": 57, "column": 4}, "end_point": {"row": 57, "column": 31}}, {"id": 380, "type": "*", "text": "*", "parent": 379, "children": [], "start_point": {"row": 57, "column": 4}, "end_point": {"row": 57, "column": 5}}, {"id": 381, "type": "cast_expression", "text": "(voidf *) & self->release", "parent": 379, "children": [382, 386], "start_point": {"row": 57, "column": 6}, "end_point": {"row": 57, "column": 31}}, {"id": 382, "type": "type_descriptor", "text": "voidf *", "parent": 381, "children": [383, 384], "start_point": {"row": 57, "column": 7}, "end_point": {"row": 57, "column": 14}}, {"id": 383, "type": "type_identifier", "text": "voidf", "parent": 382, "children": [], "start_point": {"row": 57, "column": 7}, "end_point": {"row": 57, "column": 12}}, {"id": 384, "type": "abstract_pointer_declarator", "text": "*", "parent": 382, "children": [385], "start_point": {"row": 57, "column": 13}, "end_point": {"row": 57, "column": 14}}, {"id": 385, "type": "*", "text": "*", "parent": 384, "children": [], "start_point": {"row": 57, "column": 13}, "end_point": {"row": 57, "column": 14}}, {"id": 386, "type": "pointer_expression", "text": "& self->release", "parent": 381, "children": [387], "start_point": {"row": 57, "column": 16}, "end_point": {"row": 57, "column": 31}}, {"id": 387, "type": "field_expression", "text": "self->release", "parent": 386, "children": [388, 389], "start_point": {"row": 57, "column": 18}, "end_point": {"row": 57, "column": 31}}, {"id": 388, "type": "identifier", "text": "self", "parent": 387, "children": [], "start_point": {"row": 57, "column": 18}, "end_point": {"row": 57, "column": 22}}, {"id": 389, "type": "field_identifier", "text": "release", "parent": 387, "children": [], "start_point": {"row": 57, "column": 24}, "end_point": {"row": 57, "column": 31}}, {"id": 390, "type": "=", "text": "=", "parent": 378, "children": [], "start_point": {"row": 57, "column": 32}, "end_point": {"row": 57, "column": 33}}, {"id": 391, "type": "identifier", "text": "method", "parent": 378, "children": [], "start_point": {"row": 57, "column": 34}, "end_point": {"row": 57, "column": 40}}, {"id": 392, "type": "else_clause", "text": "else if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 369, "children": [393], "start_point": {"row": 58, "column": 3}, "end_point": {"row": 65, "column": 45}}, {"id": 393, "type": "if_statement", "text": "if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 392, "children": [394, 416], "start_point": {"row": 58, "column": 8}, "end_point": {"row": 65, "column": 45}}, {"id": 394, "type": "parenthesized_expression", "text": "( selector == (voidf) retainCount )", "parent": 393, "children": [395], "start_point": {"row": 58, "column": 11}, "end_point": {"row": 58, "column": 46}}, {"id": 395, "type": "binary_expression", "text": "selector == (voidf) retainCount", "parent": 394, "children": [396, 397, 398], "start_point": {"row": 58, "column": 13}, "end_point": {"row": 58, "column": 44}}, {"id": 396, "type": "identifier", "text": "selector", "parent": 395, "children": [], "start_point": {"row": 58, "column": 13}, "end_point": {"row": 58, "column": 21}}, {"id": 397, "type": "==", "text": "==", "parent": 395, "children": [], "start_point": {"row": 58, "column": 22}, "end_point": {"row": 58, "column": 24}}, {"id": 398, "type": "cast_expression", "text": "(voidf) retainCount", "parent": 395, "children": [399, 401], "start_point": {"row": 58, "column": 25}, "end_point": {"row": 58, "column": 44}}, {"id": 399, "type": "type_descriptor", "text": "voidf", "parent": 398, "children": [400], "start_point": {"row": 58, "column": 26}, "end_point": {"row": 58, "column": 31}}, {"id": 400, "type": "type_identifier", "text": "voidf", "parent": 399, "children": [], "start_point": {"row": 58, "column": 26}, "end_point": {"row": 58, "column": 31}}, {"id": 401, "type": "identifier", "text": "retainCount", "parent": 398, "children": [], "start_point": {"row": 58, "column": 33}, "end_point": {"row": 58, "column": 44}}, {"id": 402, "type": "assignment_expression", "text": "* (voidf *) & self->retainCount = method", "parent": 393, "children": [403, 414, 415], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 44}}, {"id": 403, "type": "pointer_expression", "text": "* (voidf *) & self->retainCount", "parent": 402, "children": [404, 405], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 35}}, {"id": 404, "type": "*", "text": "*", "parent": 403, "children": [], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 5}}, {"id": 405, "type": "cast_expression", "text": "(voidf *) & self->retainCount", "parent": 403, "children": [406, 410], "start_point": {"row": 59, "column": 6}, "end_point": {"row": 59, "column": 35}}, {"id": 406, "type": "type_descriptor", "text": "voidf *", "parent": 405, "children": [407, 408], "start_point": {"row": 59, "column": 7}, "end_point": {"row": 59, "column": 14}}, {"id": 407, "type": "type_identifier", "text": "voidf", "parent": 406, "children": [], "start_point": {"row": 59, "column": 7}, "end_point": {"row": 59, "column": 12}}, {"id": 408, "type": "abstract_pointer_declarator", "text": "*", "parent": 406, "children": [409], "start_point": {"row": 59, "column": 13}, "end_point": {"row": 59, "column": 14}}, {"id": 409, "type": "*", "text": "*", "parent": 408, "children": [], "start_point": {"row": 59, "column": 13}, "end_point": {"row": 59, "column": 14}}, {"id": 410, "type": "pointer_expression", "text": "& self->retainCount", "parent": 405, "children": [411], "start_point": {"row": 59, "column": 16}, "end_point": {"row": 59, "column": 35}}, {"id": 411, "type": "field_expression", "text": "self->retainCount", "parent": 410, "children": [412, 413], "start_point": {"row": 59, "column": 18}, "end_point": {"row": 59, "column": 35}}, {"id": 412, "type": "identifier", "text": "self", "parent": 411, "children": [], "start_point": {"row": 59, "column": 18}, "end_point": {"row": 59, "column": 22}}, {"id": 413, "type": "field_identifier", "text": "retainCount", "parent": 411, "children": [], "start_point": {"row": 59, "column": 24}, "end_point": {"row": 59, "column": 35}}, {"id": 414, "type": "=", "text": "=", "parent": 402, "children": [], "start_point": {"row": 59, "column": 36}, "end_point": {"row": 59, "column": 37}}, {"id": 415, "type": "identifier", "text": "method", "parent": 402, "children": [], "start_point": {"row": 59, "column": 38}, "end_point": {"row": 59, "column": 44}}, {"id": 416, "type": "else_clause", "text": "else if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 393, "children": [417], "start_point": {"row": 61, "column": 3}, "end_point": {"row": 65, "column": 45}}, {"id": 417, "type": "if_statement", "text": "if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 416, "children": [418, 440], "start_point": {"row": 61, "column": 8}, "end_point": {"row": 65, "column": 45}}, {"id": 418, "type": "parenthesized_expression", "text": "( selector == (voidf) copyDescription )", "parent": 417, "children": [419], "start_point": {"row": 61, "column": 11}, "end_point": {"row": 61, "column": 50}}, {"id": 419, "type": "binary_expression", "text": "selector == (voidf) copyDescription", "parent": 418, "children": [420, 421, 422], "start_point": {"row": 61, "column": 13}, "end_point": {"row": 61, "column": 48}}, {"id": 420, "type": "identifier", "text": "selector", "parent": 419, "children": [], "start_point": {"row": 61, "column": 13}, "end_point": {"row": 61, "column": 21}}, {"id": 421, "type": "==", "text": "==", "parent": 419, "children": [], "start_point": {"row": 61, "column": 22}, "end_point": {"row": 61, "column": 24}}, {"id": 422, "type": "cast_expression", "text": "(voidf) copyDescription", "parent": 419, "children": [423, 425], "start_point": {"row": 61, "column": 25}, "end_point": {"row": 61, "column": 48}}, {"id": 423, "type": "type_descriptor", "text": "voidf", "parent": 422, "children": [424], "start_point": {"row": 61, "column": 26}, "end_point": {"row": 61, "column": 31}}, {"id": 424, "type": "type_identifier", "text": "voidf", "parent": 423, "children": [], "start_point": {"row": 61, "column": 26}, "end_point": {"row": 61, "column": 31}}, {"id": 425, "type": "identifier", "text": "copyDescription", "parent": 422, "children": [], "start_point": {"row": 61, "column": 33}, "end_point": {"row": 61, "column": 48}}, {"id": 426, "type": "assignment_expression", "text": "* (voidf *) & self->copyDescription = method", "parent": 417, "children": [427, 438, 439], "start_point": {"row": 62, "column": 4}, "end_point": {"row": 62, "column": 48}}, {"id": 427, "type": "pointer_expression", "text": "* (voidf *) & self->copyDescription", "parent": 426, "children": [428, 429], "start_point": {"row": 62, "column": 4}, "end_point": {"row": 62, "column": 39}}, {"id": 428, "type": "*", "text": "*", "parent": 427, "children": [], "start_point": {"row": 62, "column": 4}, "end_point": {"row": 62, "column": 5}}, {"id": 429, "type": "cast_expression", "text": "(voidf *) & self->copyDescription", "parent": 427, "children": [430, 434], "start_point": {"row": 62, "column": 6}, "end_point": {"row": 62, "column": 39}}, {"id": 430, "type": "type_descriptor", "text": "voidf *", "parent": 429, "children": [431, 432], "start_point": {"row": 62, "column": 7}, "end_point": {"row": 62, "column": 14}}, {"id": 431, "type": "type_identifier", "text": "voidf", "parent": 430, "children": [], "start_point": {"row": 62, "column": 7}, "end_point": {"row": 62, "column": 12}}, {"id": 432, "type": "abstract_pointer_declarator", "text": "*", "parent": 430, "children": [433], "start_point": {"row": 62, "column": 13}, "end_point": {"row": 62, "column": 14}}, {"id": 433, "type": "*", "text": "*", "parent": 432, "children": [], "start_point": {"row": 62, "column": 13}, "end_point": {"row": 62, "column": 14}}, {"id": 434, "type": "pointer_expression", "text": "& self->copyDescription", "parent": 429, "children": [435], "start_point": {"row": 62, "column": 16}, "end_point": {"row": 62, "column": 39}}, {"id": 435, "type": "field_expression", "text": "self->copyDescription", "parent": 434, "children": [436, 437], "start_point": {"row": 62, "column": 18}, "end_point": {"row": 62, "column": 39}}, {"id": 436, "type": "identifier", "text": "self", "parent": 435, "children": [], "start_point": {"row": 62, "column": 18}, "end_point": {"row": 62, "column": 22}}, {"id": 437, "type": "field_identifier", "text": "copyDescription", "parent": 435, "children": [], "start_point": {"row": 62, "column": 24}, "end_point": {"row": 62, "column": 39}}, {"id": 438, "type": "=", "text": "=", "parent": 426, "children": [], "start_point": {"row": 62, "column": 40}, "end_point": {"row": 62, "column": 41}}, {"id": 439, "type": "identifier", "text": "method", "parent": 426, "children": [], "start_point": {"row": 62, "column": 42}, "end_point": {"row": 62, "column": 48}}, {"id": 440, "type": "else_clause", "text": "else if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 417, "children": [441], "start_point": {"row": 64, "column": 3}, "end_point": {"row": 65, "column": 45}}, {"id": 441, "type": "if_statement", "text": "if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;", "parent": 440, "children": [442], "start_point": {"row": 64, "column": 8}, "end_point": {"row": 65, "column": 45}}, {"id": 442, "type": "parenthesized_expression", "text": "( selector == (voidf) autorelease )", "parent": 441, "children": [443], "start_point": {"row": 64, "column": 11}, "end_point": {"row": 64, "column": 46}}, {"id": 443, "type": "binary_expression", "text": "selector == (voidf) autorelease", "parent": 442, "children": [444, 445, 446], "start_point": {"row": 64, "column": 13}, "end_point": {"row": 64, "column": 44}}, {"id": 444, "type": "identifier", "text": "selector", "parent": 443, "children": [], "start_point": {"row": 64, "column": 13}, "end_point": {"row": 64, "column": 21}}, {"id": 445, "type": "==", "text": "==", "parent": 443, "children": [], "start_point": {"row": 64, "column": 22}, "end_point": {"row": 64, "column": 24}}, {"id": 446, "type": "cast_expression", "text": "(voidf) autorelease", "parent": 443, "children": [447, 449], "start_point": {"row": 64, "column": 25}, "end_point": {"row": 64, "column": 44}}, {"id": 447, "type": "type_descriptor", "text": "voidf", "parent": 446, "children": [448], "start_point": {"row": 64, "column": 26}, "end_point": {"row": 64, "column": 31}}, {"id": 448, "type": "type_identifier", "text": "voidf", "parent": 447, "children": [], "start_point": {"row": 64, "column": 26}, "end_point": {"row": 64, "column": 31}}, {"id": 449, "type": "identifier", "text": "autorelease", "parent": 446, "children": [], "start_point": {"row": 64, "column": 33}, "end_point": {"row": 64, "column": 44}}, {"id": 450, "type": "assignment_expression", "text": "* (voidf *) & self->autorelease = method", "parent": 441, "children": [451, 462, 463], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 44}}, {"id": 451, "type": "pointer_expression", "text": "* (voidf *) & self->autorelease", "parent": 450, "children": [452, 453], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 35}}, {"id": 452, "type": "*", "text": "*", "parent": 451, "children": [], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 5}}, {"id": 453, "type": "cast_expression", "text": "(voidf *) & self->autorelease", "parent": 451, "children": [454, 458], "start_point": {"row": 65, "column": 6}, "end_point": {"row": 65, "column": 35}}, {"id": 454, "type": "type_descriptor", "text": "voidf *", "parent": 453, "children": [455, 456], "start_point": {"row": 65, "column": 7}, "end_point": {"row": 65, "column": 14}}, {"id": 455, "type": "type_identifier", "text": "voidf", "parent": 454, "children": [], "start_point": {"row": 65, "column": 7}, "end_point": {"row": 65, "column": 12}}, {"id": 456, "type": "abstract_pointer_declarator", "text": "*", "parent": 454, "children": [457], "start_point": {"row": 65, "column": 13}, "end_point": {"row": 65, "column": 14}}, {"id": 457, "type": "*", "text": "*", "parent": 456, "children": [], "start_point": {"row": 65, "column": 13}, "end_point": {"row": 65, "column": 14}}, {"id": 458, "type": "pointer_expression", "text": "& self->autorelease", "parent": 453, "children": [459], "start_point": {"row": 65, "column": 16}, "end_point": {"row": 65, "column": 35}}, {"id": 459, "type": "field_expression", "text": "self->autorelease", "parent": 458, "children": [460, 461], "start_point": {"row": 65, "column": 18}, "end_point": {"row": 65, "column": 35}}, {"id": 460, "type": "identifier", "text": "self", "parent": 459, "children": [], "start_point": {"row": 65, "column": 18}, "end_point": {"row": 65, "column": 22}}, {"id": 461, "type": "field_identifier", "text": "autorelease", "parent": 459, "children": [], "start_point": {"row": 65, "column": 24}, "end_point": {"row": 65, "column": 35}}, {"id": 462, "type": "=", "text": "=", "parent": 450, "children": [], "start_point": {"row": 65, "column": 36}, "end_point": {"row": 65, "column": 37}}, {"id": 463, "type": "identifier", "text": "method", "parent": 450, "children": [], "start_point": {"row": 65, "column": 38}, "end_point": {"row": 65, "column": 44}}, {"id": 464, "type": "call_expression", "text": "va_end(ap)", "parent": 31, "children": [465, 466], "start_point": {"row": 67, "column": 2}, "end_point": {"row": 67, "column": 12}}, {"id": 465, "type": "identifier", "text": "va_end", "parent": 464, "children": [], "start_point": {"row": 67, "column": 2}, "end_point": {"row": 67, "column": 8}}, {"id": 466, "type": "argument_list", "text": "(ap)", "parent": 464, "children": [467], "start_point": {"row": 67, "column": 8}, "end_point": {"row": 67, "column": 12}}, {"id": 467, "type": "identifier", "text": "ap", "parent": 466, "children": [], "start_point": {"row": 67, "column": 9}, "end_point": {"row": 67, "column": 11}}, {"id": 468, "type": "return_statement", "text": "return self;", "parent": 31, "children": [469], "start_point": {"row": 70, "column": 1}, "end_point": {"row": 70, "column": 13}}, {"id": 469, "type": "identifier", "text": "self", "parent": 468, "children": [], "start_point": {"row": 70, "column": 8}, "end_point": {"row": 70, "column": 12}}, {"id": 470, "type": "function_definition", "text": "static void * Class_destructor (void * _self) {\n\treturn NULL;\n}", "parent": null, "children": [471, 472], "start_point": {"row": 73, "column": 0}, "end_point": {"row": 75, "column": 1}}, {"id": 471, "type": "primitive_type", "text": "void", "parent": 470, "children": [], "start_point": {"row": 73, "column": 7}, "end_point": {"row": 73, "column": 11}}, {"id": 472, "type": "pointer_declarator", "text": "* Class_destructor (void * _self)", "parent": 470, "children": [473, 474], "start_point": {"row": 73, "column": 12}, "end_point": {"row": 73, "column": 45}}, {"id": 473, "type": "*", "text": "*", "parent": 472, "children": [], "start_point": {"row": 73, "column": 12}, "end_point": {"row": 73, "column": 13}}, {"id": 474, "type": "function_declarator", "text": "Class_destructor (void * _self)", "parent": 472, "children": [475, 476], "start_point": {"row": 73, "column": 14}, "end_point": {"row": 73, "column": 45}}, {"id": 475, "type": "identifier", "text": "Class_destructor", "parent": 474, "children": [], "start_point": {"row": 73, "column": 14}, "end_point": {"row": 73, "column": 30}}, {"id": 476, "type": "parameter_list", "text": "(void * _self)", "parent": 474, "children": [477], "start_point": {"row": 73, "column": 31}, "end_point": {"row": 73, "column": 45}}, {"id": 477, "type": "parameter_declaration", "text": "void * _self", "parent": 476, "children": [478, 479], "start_point": {"row": 73, "column": 32}, "end_point": {"row": 73, "column": 44}}, {"id": 478, "type": "primitive_type", "text": "void", "parent": 477, "children": [], "start_point": {"row": 73, "column": 32}, "end_point": {"row": 73, "column": 36}}, {"id": 479, "type": "pointer_declarator", "text": "* _self", "parent": 477, "children": [480, 481], "start_point": {"row": 73, "column": 37}, "end_point": {"row": 73, "column": 44}}, {"id": 480, "type": "*", "text": "*", "parent": 479, "children": [], "start_point": {"row": 73, "column": 37}, "end_point": {"row": 73, "column": 38}}, {"id": 481, "type": "identifier", "text": "_self", "parent": 479, "children": [], "start_point": {"row": 73, "column": 39}, "end_point": {"row": 73, "column": 44}}, {"id": 482, "type": "return_statement", "text": "return NULL;", "parent": 470, "children": [483], "start_point": {"row": 74, "column": 1}, "end_point": {"row": 74, "column": 13}}, {"id": 483, "type": "null", "text": "NULL", "parent": 482, "children": [484], "start_point": {"row": 74, "column": 8}, "end_point": {"row": 74, "column": 12}}, {"id": 484, "type": "NULL", "text": "NULL", "parent": 483, "children": [], "start_point": {"row": 74, "column": 8}, "end_point": {"row": 74, "column": 12}}, {"id": 485, "type": "function_definition", "text": "static void * Class_copy (const void *const _self) {\n\treturn NULL;\n}", "parent": null, "children": [486, 487], "start_point": {"row": 77, "column": 0}, "end_point": {"row": 79, "column": 1}}, {"id": 486, "type": "primitive_type", "text": "void", "parent": 485, "children": [], "start_point": {"row": 77, "column": 7}, "end_point": {"row": 77, "column": 11}}, {"id": 487, "type": "pointer_declarator", "text": "* Class_copy (const void *const _self)", "parent": 485, "children": [488, 489], "start_point": {"row": 77, "column": 12}, "end_point": {"row": 77, "column": 50}}, {"id": 488, "type": "*", "text": "*", "parent": 487, "children": [], "start_point": {"row": 77, "column": 12}, "end_point": {"row": 77, "column": 13}}, {"id": 489, "type": "function_declarator", "text": "Class_copy (const void *const _self)", "parent": 487, "children": [490, 491], "start_point": {"row": 77, "column": 14}, "end_point": {"row": 77, "column": 50}}, {"id": 490, "type": "identifier", "text": "Class_copy", "parent": 489, "children": [], "start_point": {"row": 77, "column": 14}, "end_point": {"row": 77, "column": 24}}, {"id": 491, "type": "parameter_list", "text": "(const void *const _self)", "parent": 489, "children": [492], "start_point": {"row": 77, "column": 25}, "end_point": {"row": 77, "column": 50}}, {"id": 492, "type": "parameter_declaration", "text": "const void *const _self", "parent": 491, "children": [493, 494], "start_point": {"row": 77, "column": 26}, "end_point": {"row": 77, "column": 49}}, {"id": 493, "type": "primitive_type", "text": "void", "parent": 492, "children": [], "start_point": {"row": 77, "column": 32}, "end_point": {"row": 77, "column": 36}}, {"id": 494, "type": "pointer_declarator", "text": "*const _self", "parent": 492, "children": [495, 496], "start_point": {"row": 77, "column": 37}, "end_point": {"row": 77, "column": 49}}, {"id": 495, "type": "*", "text": "*", "parent": 494, "children": [], "start_point": {"row": 77, "column": 37}, "end_point": {"row": 77, "column": 38}}, {"id": 496, "type": "identifier", "text": "_self", "parent": 494, "children": [], "start_point": {"row": 77, "column": 44}, "end_point": {"row": 77, "column": 49}}, {"id": 497, "type": "return_statement", "text": "return NULL;", "parent": 485, "children": [498], "start_point": {"row": 78, "column": 1}, "end_point": {"row": 78, "column": 13}}, {"id": 498, "type": "null", "text": "NULL", "parent": 497, "children": [499], "start_point": {"row": 78, "column": 8}, "end_point": {"row": 78, "column": 12}}, {"id": 499, "type": "NULL", "text": "NULL", "parent": 498, "children": [], "start_point": {"row": 78, "column": 8}, "end_point": {"row": 78, "column": 12}}, {"id": 500, "type": "function_definition", "text": "static UInteger Class_hash (const void *const self) {\n\tCOAssertNoNullOrReturn(self,EINVAL,0);\n\tconst struct Classs *const class = classOf(self);\n\tCOAssertNoNullOrReturn(class,EINVAL,0);\n\tconst struct Classs *const _superclass = superclass(self);\n\tCOAssertNoNullOrReturn(_superclass,EINVAL,0);\n\tCOAssertNoNullOrReturn(_superclass->hash,EINVAL,0);\n\t\n\t\n\tUInteger prime = 31;\n\tUInteger result = _superclass->hash(self);\n\tresult = prime * result + (UInteger)strlen(class->class_name);\n\tresult = prime * result + class->size;\n\treturn result;\n}", "parent": null, "children": [501, 502], "start_point": {"row": 81, "column": 0}, "end_point": {"row": 95, "column": 1}}, {"id": 501, "type": "type_identifier", "text": "UInteger", "parent": 500, "children": [], "start_point": {"row": 81, "column": 7}, "end_point": {"row": 81, "column": 15}}, {"id": 502, "type": "function_declarator", "text": "Class_hash (const void *const self)", "parent": 500, "children": [503, 504], "start_point": {"row": 81, "column": 16}, "end_point": {"row": 81, "column": 51}}, {"id": 503, "type": "identifier", "text": "Class_hash", "parent": 502, "children": [], "start_point": {"row": 81, "column": 16}, "end_point": {"row": 81, "column": 26}}, {"id": 504, "type": "parameter_list", "text": "(const void *const self)", "parent": 502, "children": [505], "start_point": {"row": 81, "column": 27}, "end_point": {"row": 81, "column": 51}}, {"id": 505, "type": "parameter_declaration", "text": "const void *const self", "parent": 504, "children": [506, 507], "start_point": {"row": 81, "column": 28}, "end_point": {"row": 81, "column": 50}}, {"id": 506, "type": "primitive_type", "text": "void", "parent": 505, "children": [], "start_point": {"row": 81, "column": 34}, "end_point": {"row": 81, "column": 38}}, {"id": 507, "type": "pointer_declarator", "text": "*const self", "parent": 505, "children": [508, 509], "start_point": {"row": 81, "column": 39}, "end_point": {"row": 81, "column": 50}}, {"id": 508, "type": "*", "text": "*", "parent": 507, "children": [], "start_point": {"row": 81, "column": 39}, "end_point": {"row": 81, "column": 40}}, {"id": 509, "type": "identifier", "text": "self", "parent": 507, "children": [], "start_point": {"row": 81, "column": 46}, "end_point": {"row": 81, "column": 50}}, {"id": 510, "type": "call_expression", "text": "COAssertNoNullOrReturn(self,EINVAL,0)", "parent": 500, "children": [511, 512], "start_point": {"row": 82, "column": 1}, "end_point": {"row": 82, "column": 38}}, {"id": 511, "type": "identifier", "text": "COAssertNoNullOrReturn", "parent": 510, "children": [], "start_point": {"row": 82, "column": 1}, "end_point": {"row": 82, "column": 23}}, {"id": 512, "type": "argument_list", "text": "(self,EINVAL,0)", "parent": 510, "children": [513, 514, 515], "start_point": {"row": 82, "column": 23}, "end_point": {"row": 82, "column": 38}}, {"id": 513, "type": "identifier", "text": "self", "parent": 512, "children": [], "start_point": {"row": 82, "column": 24}, "end_point": {"row": 82, "column": 28}}, {"id": 514, "type": "identifier", "text": "EINVAL", "parent": 512, "children": [], "start_point": {"row": 82, "column": 29}, "end_point": {"row": 82, "column": 35}}, {"id": 515, "type": "number_literal", "text": "0", "parent": 512, "children": [], "start_point": {"row": 82, "column": 36}, "end_point": {"row": 82, "column": 37}}, {"id": 516, "type": "declaration", "text": "const struct Classs *const class = classOf(self);", "parent": 500, "children": [517, 520], "start_point": {"row": 83, "column": 1}, "end_point": {"row": 83, "column": 50}}, {"id": 517, "type": "struct_specifier", "text": "struct Classs", "parent": 516, "children": [518, 519], "start_point": {"row": 83, "column": 7}, "end_point": {"row": 83, "column": 20}}, {"id": 518, "type": "struct", "text": "struct", "parent": 517, "children": [], "start_point": {"row": 83, "column": 7}, "end_point": {"row": 83, "column": 13}}, {"id": 519, "type": "type_identifier", "text": "Classs", "parent": 517, "children": [], "start_point": {"row": 83, "column": 14}, "end_point": {"row": 83, "column": 20}}, {"id": 520, "type": "init_declarator", "text": "*const class = classOf(self)", "parent": 516, "children": [521, 523, 524], "start_point": {"row": 83, "column": 21}, "end_point": {"row": 83, "column": 49}}, {"id": 521, "type": "pointer_declarator", "text": "*const class", "parent": 520, "children": [522], "start_point": {"row": 83, "column": 21}, "end_point": {"row": 83, "column": 33}}, {"id": 522, "type": "*", "text": "*", "parent": 521, "children": [], "start_point": {"row": 83, "column": 21}, "end_point": {"row": 83, "column": 22}}, {"id": 523, "type": "=", "text": "=", "parent": 520, "children": [], "start_point": {"row": 83, "column": 34}, "end_point": {"row": 83, "column": 35}}, {"id": 524, "type": "call_expression", "text": "classOf(self)", "parent": 520, "children": [525, 526], "start_point": {"row": 83, "column": 36}, "end_point": {"row": 83, "column": 49}}, {"id": 525, "type": "identifier", "text": "classOf", "parent": 524, "children": [], "start_point": {"row": 83, "column": 36}, "end_point": {"row": 83, "column": 43}}, {"id": 526, "type": "argument_list", "text": "(self)", "parent": 524, "children": [527], "start_point": {"row": 83, "column": 43}, "end_point": {"row": 83, "column": 49}}, {"id": 527, "type": "identifier", "text": "self", "parent": 526, "children": [], "start_point": {"row": 83, "column": 44}, "end_point": {"row": 83, "column": 48}}, {"id": 528, "type": "call_expression", "text": "COAssertNoNullOrReturn(class,EINVAL,0)", "parent": 500, "children": [529, 530], "start_point": {"row": 84, "column": 1}, "end_point": {"row": 84, "column": 39}}, {"id": 529, "type": "identifier", "text": "COAssertNoNullOrReturn", "parent": 528, "children": [], "start_point": {"row": 84, "column": 1}, "end_point": {"row": 84, "column": 23}}, {"id": 530, "type": "argument_list", "text": "(class,EINVAL,0)", "parent": 528, "children": [531, 532], "start_point": {"row": 84, "column": 23}, "end_point": {"row": 84, "column": 39}}, {"id": 531, "type": "identifier", "text": "EINVAL", "parent": 530, "children": [], "start_point": {"row": 84, "column": 30}, "end_point": {"row": 84, "column": 36}}, {"id": 532, "type": "number_literal", "text": "0", "parent": 530, "children": [], "start_point": {"row": 84, "column": 37}, "end_point": {"row": 84, "column": 38}}, {"id": 533, "type": "declaration", "text": "const struct Classs *const _superclass = superclass(self);", "parent": 500, "children": [534, 537], "start_point": {"row": 85, "column": 1}, "end_point": {"row": 85, "column": 59}}, {"id": 534, "type": "struct_specifier", "text": "struct Classs", "parent": 533, "children": [535, 536], "start_point": {"row": 85, "column": 7}, "end_point": {"row": 85, "column": 20}}, {"id": 535, "type": "struct", "text": "struct", "parent": 534, "children": [], "start_point": {"row": 85, "column": 7}, "end_point": {"row": 85, "column": 13}}, {"id": 536, "type": "type_identifier", "text": "Classs", "parent": 534, "children": [], "start_point": {"row": 85, "column": 14}, "end_point": {"row": 85, "column": 20}}, {"id": 537, "type": "init_declarator", "text": "*const _superclass = superclass(self)", "parent": 533, "children": [538, 541, 542], "start_point": {"row": 85, "column": 21}, "end_point": {"row": 85, "column": 58}}, {"id": 538, "type": "pointer_declarator", "text": "*const _superclass", "parent": 537, "children": [539, 540], "start_point": {"row": 85, "column": 21}, "end_point": {"row": 85, "column": 39}}, {"id": 539, "type": "*", "text": "*", "parent": 538, "children": [], "start_point": {"row": 85, "column": 21}, "end_point": {"row": 85, "column": 22}}, {"id": 540, "type": "identifier", "text": "_superclass", "parent": 538, "children": [], "start_point": {"row": 85, "column": 28}, "end_point": {"row": 85, "column": 39}}, {"id": 541, "type": "=", "text": "=", "parent": 537, "children": [], "start_point": {"row": 85, "column": 40}, "end_point": {"row": 85, "column": 41}}, {"id": 542, "type": "call_expression", "text": "superclass(self)", "parent": 537, "children": [543, 544], "start_point": {"row": 85, "column": 42}, "end_point": {"row": 85, "column": 58}}, {"id": 543, "type": "identifier", "text": "superclass", "parent": 542, "children": [], "start_point": {"row": 85, "column": 42}, "end_point": {"row": 85, "column": 52}}, {"id": 544, "type": "argument_list", "text": "(self)", "parent": 542, "children": [545], "start_point": {"row": 85, "column": 52}, "end_point": {"row": 85, "column": 58}}, {"id": 545, "type": "identifier", "text": "self", "parent": 544, "children": [], "start_point": {"row": 85, "column": 53}, "end_point": {"row": 85, "column": 57}}, {"id": 546, "type": "call_expression", "text": "COAssertNoNullOrReturn(_superclass,EINVAL,0)", "parent": 500, "children": [547, 548], "start_point": {"row": 86, "column": 1}, "end_point": {"row": 86, "column": 45}}, {"id": 547, "type": "identifier", "text": "COAssertNoNullOrReturn", "parent": 546, "children": [], "start_point": {"row": 86, "column": 1}, "end_point": {"row": 86, "column": 23}}, {"id": 548, "type": "argument_list", "text": "(_superclass,EINVAL,0)", "parent": 546, "children": [549, 550, 551], "start_point": {"row": 86, "column": 23}, "end_point": {"row": 86, "column": 45}}, {"id": 549, "type": "identifier", "text": "_superclass", "parent": 548, "children": [], "start_point": {"row": 86, "column": 24}, "end_point": {"row": 86, "column": 35}}, {"id": 550, "type": "identifier", "text": "EINVAL", "parent": 548, "children": [], "start_point": {"row": 86, "column": 36}, "end_point": {"row": 86, "column": 42}}, {"id": 551, "type": "number_literal", "text": "0", "parent": 548, "children": [], "start_point": {"row": 86, "column": 43}, "end_point": {"row": 86, "column": 44}}, {"id": 552, "type": "call_expression", "text": "COAssertNoNullOrReturn(_superclass->hash,EINVAL,0)", "parent": 500, "children": [553, 554], "start_point": {"row": 87, "column": 1}, "end_point": {"row": 87, "column": 51}}, {"id": 553, "type": "identifier", "text": "COAssertNoNullOrReturn", "parent": 552, "children": [], "start_point": {"row": 87, "column": 1}, "end_point": {"row": 87, "column": 23}}, {"id": 554, "type": "argument_list", "text": "(_superclass->hash,EINVAL,0)", "parent": 552, "children": [555, 558, 559], "start_point": {"row": 87, "column": 23}, "end_point": {"row": 87, "column": 51}}, {"id": 555, "type": "field_expression", "text": "_superclass->hash", "parent": 554, "children": [556, 557], "start_point": {"row": 87, "column": 24}, "end_point": {"row": 87, "column": 41}}, {"id": 556, "type": "identifier", "text": "_superclass", "parent": 555, "children": [], "start_point": {"row": 87, "column": 24}, "end_point": {"row": 87, "column": 35}}, {"id": 557, "type": "field_identifier", "text": "hash", "parent": 555, "children": [], "start_point": {"row": 87, "column": 37}, "end_point": {"row": 87, "column": 41}}, {"id": 558, "type": "identifier", "text": "EINVAL", "parent": 554, "children": [], "start_point": {"row": 87, "column": 42}, "end_point": {"row": 87, "column": 48}}, {"id": 559, "type": "number_literal", "text": "0", "parent": 554, "children": [], "start_point": {"row": 87, "column": 49}, "end_point": {"row": 87, "column": 50}}, {"id": 560, "type": "declaration", "text": "UInteger prime = 31;", "parent": 500, "children": [561, 562], "start_point": {"row": 90, "column": 1}, "end_point": {"row": 90, "column": 21}}, {"id": 561, "type": "type_identifier", "text": "UInteger", "parent": 560, "children": [], "start_point": {"row": 90, "column": 1}, "end_point": {"row": 90, "column": 9}}, {"id": 562, "type": "init_declarator", "text": "prime = 31", "parent": 560, "children": [563, 564, 565], "start_point": {"row": 90, "column": 10}, "end_point": {"row": 90, "column": 20}}, {"id": 563, "type": "identifier", "text": "prime", "parent": 562, "children": [], "start_point": {"row": 90, "column": 10}, "end_point": {"row": 90, "column": 15}}, {"id": 564, "type": "=", "text": "=", "parent": 562, "children": [], "start_point": {"row": 90, "column": 16}, "end_point": {"row": 90, "column": 17}}, {"id": 565, "type": "number_literal", "text": "31", "parent": 562, "children": [], "start_point": {"row": 90, "column": 18}, "end_point": {"row": 90, "column": 20}}, {"id": 566, "type": "declaration", "text": "UInteger result = _superclass->hash(self);", "parent": 500, "children": [567, 568], "start_point": {"row": 91, "column": 1}, "end_point": {"row": 91, "column": 43}}, {"id": 567, "type": "type_identifier", "text": "UInteger", "parent": 566, "children": [], "start_point": {"row": 91, "column": 1}, "end_point": {"row": 91, "column": 9}}, {"id": 568, "type": "init_declarator", "text": "result = _superclass->hash(self)", "parent": 566, "children": [569, 570, 571], "start_point": {"row": 91, "column": 10}, "end_point": {"row": 91, "column": 42}}, {"id": 569, "type": "identifier", "text": "result", "parent": 568, "children": [], "start_point": {"row": 91, "column": 10}, "end_point": {"row": 91, "column": 16}}, {"id": 570, "type": "=", "text": "=", "parent": 568, "children": [], "start_point": {"row": 91, "column": 17}, "end_point": {"row": 91, "column": 18}}, {"id": 571, "type": "call_expression", "text": "_superclass->hash(self)", "parent": 568, "children": [572, 575], "start_point": {"row": 91, "column": 19}, "end_point": {"row": 91, "column": 42}}, {"id": 572, "type": "field_expression", "text": "_superclass->hash", "parent": 571, "children": [573, 574], "start_point": {"row": 91, "column": 19}, "end_point": {"row": 91, "column": 36}}, {"id": 573, "type": "identifier", "text": "_superclass", "parent": 572, "children": [], "start_point": {"row": 91, "column": 19}, "end_point": {"row": 91, "column": 30}}, {"id": 574, "type": "field_identifier", "text": "hash", "parent": 572, "children": [], "start_point": {"row": 91, "column": 32}, "end_point": {"row": 91, "column": 36}}, {"id": 575, "type": "argument_list", "text": "(self)", "parent": 571, "children": [576], "start_point": {"row": 91, "column": 36}, "end_point": {"row": 91, "column": 42}}, {"id": 576, "type": "identifier", "text": "self", "parent": 575, "children": [], "start_point": {"row": 91, "column": 37}, "end_point": {"row": 91, "column": 41}}, {"id": 577, "type": "assignment_expression", "text": "result = prime * result + (UInteger)strlen(class->class_name)", "parent": 500, "children": [578, 579, 580], "start_point": {"row": 92, "column": 1}, "end_point": {"row": 92, "column": 63}}, {"id": 578, "type": "identifier", "text": "result", "parent": 577, "children": [], "start_point": {"row": 92, "column": 1}, "end_point": {"row": 92, "column": 7}}, {"id": 579, "type": "=", "text": "=", "parent": 577, "children": [], "start_point": {"row": 92, "column": 8}, "end_point": {"row": 92, "column": 9}}, {"id": 580, "type": "binary_expression", "text": "prime * result + (UInteger)strlen(class->class_name)", "parent": 577, "children": [581, 585, 586], "start_point": {"row": 92, "column": 10}, "end_point": {"row": 92, "column": 63}}, {"id": 581, "type": "binary_expression", "text": "prime * result", "parent": 580, "children": [582, 583, 584], "start_point": {"row": 92, "column": 10}, "end_point": {"row": 92, "column": 24}}, {"id": 582, "type": "identifier", "text": "prime", "parent": 581, "children": [], "start_point": {"row": 92, "column": 10}, "end_point": {"row": 92, "column": 15}}, {"id": 583, "type": "*", "text": "*", "parent": 581, "children": [], "start_point": {"row": 92, "column": 16}, "end_point": {"row": 92, "column": 17}}, {"id": 584, "type": "identifier", "text": "result", "parent": 581, "children": [], "start_point": {"row": 92, "column": 18}, "end_point": {"row": 92, "column": 24}}, {"id": 585, "type": "+", "text": "+", "parent": 580, "children": [], "start_point": {"row": 92, "column": 26}, "end_point": {"row": 92, "column": 27}}, {"id": 586, "type": "cast_expression", "text": "(UInteger)strlen(class->class_name)", "parent": 580, "children": [587, 589], "start_point": {"row": 92, "column": 28}, "end_point": {"row": 92, "column": 63}}, {"id": 587, "type": "type_descriptor", "text": "UInteger", "parent": 586, "children": [588], "start_point": {"row": 92, "column": 29}, "end_point": {"row": 92, "column": 37}}, {"id": 588, "type": "type_identifier", "text": "UInteger", "parent": 587, "children": [], "start_point": {"row": 92, "column": 29}, "end_point": {"row": 92, "column": 37}}, {"id": 589, "type": "call_expression", "text": "strlen(class->class_name)", "parent": 586, "children": [590, 591], "start_point": {"row": 92, "column": 38}, "end_point": {"row": 92, "column": 63}}, {"id": 590, "type": "identifier", "text": "strlen", "parent": 589, "children": [], "start_point": {"row": 92, "column": 38}, "end_point": {"row": 92, "column": 44}}, {"id": 591, "type": "argument_list", "text": "(class->class_name)", "parent": 589, "children": [592], "start_point": {"row": 92, "column": 44}, "end_point": {"row": 92, "column": 63}}, {"id": 592, "type": "field_expression", "text": "class->class_name", "parent": 591, "children": [593], "start_point": {"row": 92, "column": 45}, "end_point": {"row": 92, "column": 62}}, {"id": 593, "type": "field_identifier", "text": "class_name", "parent": 592, "children": [], "start_point": {"row": 92, "column": 52}, "end_point": {"row": 92, "column": 62}}, {"id": 594, "type": "assignment_expression", "text": "result = prime * result + class->size", "parent": 500, "children": [595, 596, 597], "start_point": {"row": 93, "column": 1}, "end_point": {"row": 93, "column": 38}}, {"id": 595, "type": "identifier", "text": "result", "parent": 594, "children": [], "start_point": {"row": 93, "column": 1}, "end_point": {"row": 93, "column": 7}}, {"id": 596, "type": "=", "text": "=", "parent": 594, "children": [], "start_point": {"row": 93, "column": 8}, "end_point": {"row": 93, "column": 9}}, {"id": 597, "type": "binary_expression", "text": "prime * result + class->size", "parent": 594, "children": [598, 602, 603], "start_point": {"row": 93, "column": 10}, "end_point": {"row": 93, "column": 38}}, {"id": 598, "type": "binary_expression", "text": "prime * result", "parent": 597, "children": [599, 600, 601], "start_point": {"row": 93, "column": 10}, "end_point": {"row": 93, "column": 24}}, {"id": 599, "type": "identifier", "text": "prime", "parent": 598, "children": [], "start_point": {"row": 93, "column": 10}, "end_point": {"row": 93, "column": 15}}, {"id": 600, "type": "*", "text": "*", "parent": 598, "children": [], "start_point": {"row": 93, "column": 16}, "end_point": {"row": 93, "column": 17}}, {"id": 601, "type": "identifier", "text": "result", "parent": 598, "children": [], "start_point": {"row": 93, "column": 18}, "end_point": {"row": 93, "column": 24}}, {"id": 602, "type": "+", "text": "+", "parent": 597, "children": [], "start_point": {"row": 93, "column": 25}, "end_point": {"row": 93, "column": 26}}, {"id": 603, "type": "field_expression", "text": "class->size", "parent": 597, "children": [604], "start_point": {"row": 93, "column": 27}, "end_point": {"row": 93, "column": 38}}, {"id": 604, "type": "field_identifier", "text": "size", "parent": 603, "children": [], "start_point": {"row": 93, "column": 34}, "end_point": {"row": 93, "column": 38}}, {"id": 605, "type": "return_statement", "text": "return result;", "parent": 500, "children": [606], "start_point": {"row": 94, "column": 1}, "end_point": {"row": 94, "column": 15}}, {"id": 606, "type": "identifier", "text": "result", "parent": 605, "children": [], "start_point": {"row": 94, "column": 8}, "end_point": {"row": 94, "column": 14}}, {"id": 607, "type": "function_definition", "text": "static void * Class_retain (void *const _self) {\n\treturn NULL;\n}", "parent": null, "children": [608, 609], "start_point": {"row": 96, "column": 0}, "end_point": {"row": 98, "column": 1}}, {"id": 608, "type": "primitive_type", "text": "void", "parent": 607, "children": [], "start_point": {"row": 96, "column": 7}, "end_point": {"row": 96, "column": 11}}, {"id": 609, "type": "pointer_declarator", "text": "* Class_retain (void *const _self)", "parent": 607, "children": [610, 611], "start_point": {"row": 96, "column": 12}, "end_point": {"row": 96, "column": 46}}, {"id": 610, "type": "*", "text": "*", "parent": 609, "children": [], "start_point": {"row": 96, "column": 12}, "end_point": {"row": 96, "column": 13}}, {"id": 611, "type": "function_declarator", "text": "Class_retain (void *const _self)", "parent": 609, "children": [612, 613], "start_point": {"row": 96, "column": 14}, "end_point": {"row": 96, "column": 46}}, {"id": 612, "type": "identifier", "text": "Class_retain", "parent": 611, "children": [], "start_point": {"row": 96, "column": 14}, "end_point": {"row": 96, "column": 26}}, {"id": 613, "type": "parameter_list", "text": "(void *const _self)", "parent": 611, "children": [614], "start_point": {"row": 96, "column": 27}, "end_point": {"row": 96, "column": 46}}, {"id": 614, "type": "parameter_declaration", "text": "void *const _self", "parent": 613, "children": [615, 616], "start_point": {"row": 96, "column": 28}, "end_point": {"row": 96, "column": 45}}, {"id": 615, "type": "primitive_type", "text": "void", "parent": 614, "children": [], "start_point": {"row": 96, "column": 28}, "end_point": {"row": 96, "column": 32}}, {"id": 616, "type": "pointer_declarator", "text": "*const _self", "parent": 614, "children": [617, 618], "start_point": {"row": 96, "column": 33}, "end_point": {"row": 96, "column": 45}}, {"id": 617, "type": "*", "text": "*", "parent": 616, "children": [], "start_point": {"row": 96, "column": 33}, "end_point": {"row": 96, "column": 34}}, {"id": 618, "type": "identifier", "text": "_self", "parent": 616, "children": [], "start_point": {"row": 96, "column": 40}, "end_point": {"row": 96, "column": 45}}, {"id": 619, "type": "return_statement", "text": "return NULL;", "parent": 607, "children": [620], "start_point": {"row": 97, "column": 1}, "end_point": {"row": 97, "column": 13}}, {"id": 620, "type": "null", "text": "NULL", "parent": 619, "children": [621], "start_point": {"row": 97, "column": 8}, "end_point": {"row": 97, "column": 12}}, {"id": 621, "type": "NULL", "text": "NULL", "parent": 620, "children": [], "start_point": {"row": 97, "column": 8}, "end_point": {"row": 97, "column": 12}}, {"id": 622, "type": "function_definition", "text": "static void Class_release (void *const _self) {\n}", "parent": null, "children": [623, 624], "start_point": {"row": 100, "column": 0}, "end_point": {"row": 101, "column": 1}}, {"id": 623, "type": "primitive_type", "text": "void", "parent": 622, "children": [], "start_point": {"row": 100, "column": 7}, "end_point": {"row": 100, "column": 11}}, {"id": 624, "type": "function_declarator", "text": "Class_release (void *const _self)", "parent": 622, "children": [625, 626], "start_point": {"row": 100, "column": 12}, "end_point": {"row": 100, "column": 45}}, {"id": 625, "type": "identifier", "text": "Class_release", "parent": 624, "children": [], "start_point": {"row": 100, "column": 12}, "end_point": {"row": 100, "column": 25}}, {"id": 626, "type": "parameter_list", "text": "(void *const _self)", "parent": 624, "children": [627], "start_point": {"row": 100, "column": 26}, "end_point": {"row": 100, "column": 45}}, {"id": 627, "type": "parameter_declaration", "text": "void *const _self", "parent": 626, "children": [628, 629], "start_point": {"row": 100, "column": 27}, "end_point": {"row": 100, "column": 44}}, {"id": 628, "type": "primitive_type", "text": "void", "parent": 627, "children": [], "start_point": {"row": 100, "column": 27}, "end_point": {"row": 100, "column": 31}}, {"id": 629, "type": "pointer_declarator", "text": "*const _self", "parent": 627, "children": [630, 631], "start_point": {"row": 100, "column": 32}, "end_point": {"row": 100, "column": 44}}, {"id": 630, "type": "*", "text": "*", "parent": 629, "children": [], "start_point": {"row": 100, "column": 32}, "end_point": {"row": 100, "column": 33}}, {"id": 631, "type": "identifier", "text": "_self", "parent": 629, "children": [], "start_point": {"row": 100, "column": 39}, "end_point": {"row": 100, "column": 44}}, {"id": 632, "type": "function_definition", "text": "static void *Class_autorelease (void *const _self) {\n\treturn NULL;\n}", "parent": null, "children": [633, 634], "start_point": {"row": 103, "column": 0}, "end_point": {"row": 105, "column": 1}}, {"id": 633, "type": "primitive_type", "text": "void", "parent": 632, "children": [], "start_point": {"row": 103, "column": 7}, "end_point": {"row": 103, "column": 11}}, {"id": 634, "type": "pointer_declarator", "text": "*Class_autorelease (void *const _self)", "parent": 632, "children": [635, 636], "start_point": {"row": 103, "column": 12}, "end_point": {"row": 103, "column": 50}}, {"id": 635, "type": "*", "text": "*", "parent": 634, "children": [], "start_point": {"row": 103, "column": 12}, "end_point": {"row": 103, "column": 13}}, {"id": 636, "type": "function_declarator", "text": "Class_autorelease (void *const _self)", "parent": 634, "children": [637, 638], "start_point": {"row": 103, "column": 13}, "end_point": {"row": 103, "column": 50}}, {"id": 637, "type": "identifier", "text": "Class_autorelease", "parent": 636, "children": [], "start_point": {"row": 103, "column": 13}, "end_point": {"row": 103, "column": 30}}, {"id": 638, "type": "parameter_list", "text": "(void *const _self)", "parent": 636, "children": [639], "start_point": {"row": 103, "column": 31}, "end_point": {"row": 103, "column": 50}}, {"id": 639, "type": "parameter_declaration", "text": "void *const _self", "parent": 638, "children": [640, 641], "start_point": {"row": 103, "column": 32}, "end_point": {"row": 103, "column": 49}}, {"id": 640, "type": "primitive_type", "text": "void", "parent": 639, "children": [], "start_point": {"row": 103, "column": 32}, "end_point": {"row": 103, "column": 36}}, {"id": 641, "type": "pointer_declarator", "text": "*const _self", "parent": 639, "children": [642, 643], "start_point": {"row": 103, "column": 37}, "end_point": {"row": 103, "column": 49}}, {"id": 642, "type": "*", "text": "*", "parent": 641, "children": [], "start_point": {"row": 103, "column": 37}, "end_point": {"row": 103, "column": 38}}, {"id": 643, "type": "identifier", "text": "_self", "parent": 641, "children": [], "start_point": {"row": 103, "column": 44}, "end_point": {"row": 103, "column": 49}}, {"id": 644, "type": "return_statement", "text": "return NULL;", "parent": 632, "children": [645], "start_point": {"row": 104, "column": 1}, "end_point": {"row": 104, "column": 13}}, {"id": 645, "type": "null", "text": "NULL", "parent": 644, "children": [646], "start_point": {"row": 104, "column": 8}, "end_point": {"row": 104, "column": 12}}, {"id": 646, "type": "NULL", "text": "NULL", "parent": 645, "children": [], "start_point": {"row": 104, "column": 8}, "end_point": {"row": 104, "column": 12}}, {"id": 647, "type": "declaration", "text": "static const struct Classs object [] = {\n\t{\t{object+1},\n\t\t\"Object\",\n\t\tobject,\n\t\tsizeof(struct Object),\n\t\tObject_constructor,\n\t\tObject_destructor,\n\t\tObject_copy,\n\t\tObject_equals,\n\t\tObject_hash,\n\t\tObject_copyDescription,\n\t\tObject_retain,\n\t\tObject_release,\n\t\tObject_retainCount,\n\t\tObject_autorelease,\n\t},\n\t{\t{object+1},\n\t\t\"Class\",\n\t\tobject,\n\t\tsizeof(struct Classs),\n\t\tClass_constructor,\n\t\tClass_destructor,\n\t\tClass_copy,\n\t\tObject_equals,\n\t\tClass_hash,\n\t\tObject_copyDescription,\n\t\tClass_retain,\n\t\tObject_release,\n\t\tObject_retainCount,\n\t\tClass_autorelease,\n\t}\n};", "parent": null, "children": [648, 651], "start_point": {"row": 107, "column": 0}, "end_point": {"row": 138, "column": 2}}, {"id": 648, "type": "struct_specifier", "text": "struct Classs", "parent": 647, "children": [649, 650], "start_point": {"row": 107, "column": 13}, "end_point": {"row": 107, "column": 26}}, {"id": 649, "type": "struct", "text": "struct", "parent": 648, "children": [], "start_point": {"row": 107, "column": 13}, "end_point": {"row": 107, "column": 19}}, {"id": 650, "type": "type_identifier", "text": "Classs", "parent": 648, "children": [], "start_point": {"row": 107, "column": 20}, "end_point": {"row": 107, "column": 26}}, {"id": 651, "type": "init_declarator", "text": "object [] = {\n\t{\t{object+1},\n\t\t\"Object\",\n\t\tobject,\n\t\tsizeof(struct Object),\n\t\tObject_constructor,\n\t\tObject_destructor,\n\t\tObject_copy,\n\t\tObject_equals,\n\t\tObject_hash,\n\t\tObject_copyDescription,\n\t\tObject_retain,\n\t\tObject_release,\n\t\tObject_retainCount,\n\t\tObject_autorelease,\n\t},\n\t{\t{object+1},\n\t\t\"Class\",\n\t\tobject,\n\t\tsizeof(struct Classs),\n\t\tClass_constructor,\n\t\tClass_destructor,\n\t\tClass_copy,\n\t\tObject_equals,\n\t\tClass_hash,\n\t\tObject_copyDescription,\n\t\tClass_retain,\n\t\tObject_release,\n\t\tObject_retainCount,\n\t\tClass_autorelease,\n\t}\n}", "parent": 647, "children": [652, 654, 655], "start_point": {"row": 107, "column": 27}, "end_point": {"row": 138, "column": 1}}, {"id": 652, "type": "array_declarator", "text": "object []", "parent": 651, "children": [653], "start_point": {"row": 107, "column": 27}, "end_point": {"row": 107, "column": 36}}, {"id": 653, "type": "identifier", "text": "object", "parent": 652, "children": [], "start_point": {"row": 107, "column": 27}, "end_point": {"row": 107, "column": 33}}, {"id": 654, "type": "=", "text": "=", "parent": 651, "children": [], "start_point": {"row": 107, "column": 37}, "end_point": {"row": 107, "column": 38}}, {"id": 655, "type": "initializer_list", "text": "{\n\t{\t{object+1},\n\t\t\"Object\",\n\t\tobject,\n\t\tsizeof(struct Object),\n\t\tObject_constructor,\n\t\tObject_destructor,\n\t\tObject_copy,\n\t\tObject_equals,\n\t\tObject_hash,\n\t\tObject_copyDescription,\n\t\tObject_retain,\n\t\tObject_release,\n\t\tObject_retainCount,\n\t\tObject_autorelease,\n\t},\n\t{\t{object+1},\n\t\t\"Class\",\n\t\tobject,\n\t\tsizeof(struct Classs),\n\t\tClass_constructor,\n\t\tClass_destructor,\n\t\tClass_copy,\n\t\tObject_equals,\n\t\tClass_hash,\n\t\tObject_copyDescription,\n\t\tClass_retain,\n\t\tObject_release,\n\t\tObject_retainCount,\n\t\tClass_autorelease,\n\t}\n}", "parent": 651, "children": [656, 679], "start_point": {"row": 107, "column": 39}, "end_point": {"row": 138, "column": 1}}, {"id": 656, "type": "initializer_list", "text": "{\t{object+1},\n\t\t\"Object\",\n\t\tobject,\n\t\tsizeof(struct Object),\n\t\tObject_constructor,\n\t\tObject_destructor,\n\t\tObject_copy,\n\t\tObject_equals,\n\t\tObject_hash,\n\t\tObject_copyDescription,\n\t\tObject_retain,\n\t\tObject_release,\n\t\tObject_retainCount,\n\t\tObject_autorelease,\n\t}", "parent": 655, "children": [657, 662, 663, 664, 669, 670, 671, 672, 673, 674, 675, 676, 677, 678], "start_point": {"row": 108, "column": 1}, "end_point": {"row": 122, "column": 2}}, {"id": 657, "type": "initializer_list", "text": "{object+1}", "parent": 656, "children": [658], "start_point": {"row": 108, "column": 3}, "end_point": {"row": 108, "column": 13}}, {"id": 658, "type": "binary_expression", "text": "object+1", "parent": 657, "children": [659, 660, 661], "start_point": {"row": 108, "column": 4}, "end_point": {"row": 108, "column": 12}}, {"id": 659, "type": "identifier", "text": "object", "parent": 658, "children": [], "start_point": {"row": 108, "column": 4}, "end_point": {"row": 108, "column": 10}}, {"id": 660, "type": "+", "text": "+", "parent": 658, "children": [], "start_point": {"row": 108, "column": 10}, "end_point": {"row": 108, "column": 11}}, {"id": 661, "type": "number_literal", "text": "1", "parent": 658, "children": [], "start_point": {"row": 108, "column": 11}, "end_point": {"row": 108, "column": 12}}, {"id": 662, "type": "string_literal", "text": "\"Object\"", "parent": 656, "children": [], "start_point": {"row": 109, "column": 2}, "end_point": {"row": 109, "column": 10}}, {"id": 663, "type": "identifier", "text": "object", "parent": 656, "children": [], "start_point": {"row": 110, "column": 2}, "end_point": {"row": 110, "column": 8}}, {"id": 664, "type": "sizeof_expression", "text": "sizeof(struct Object)", "parent": 656, "children": [665], "start_point": {"row": 111, "column": 2}, "end_point": {"row": 111, "column": 23}}, {"id": 665, "type": "type_descriptor", "text": "struct Object", "parent": 664, "children": [666], "start_point": {"row": 111, "column": 9}, "end_point": {"row": 111, "column": 22}}, {"id": 666, "type": "struct_specifier", "text": "struct Object", "parent": 665, "children": [667, 668], "start_point": {"row": 111, "column": 9}, "end_point": {"row": 111, "column": 22}}, {"id": 667, "type": "struct", "text": "struct", "parent": 666, "children": [], "start_point": {"row": 111, "column": 9}, "end_point": {"row": 111, "column": 15}}, {"id": 668, "type": "type_identifier", "text": "Object", "parent": 666, "children": [], "start_point": {"row": 111, "column": 16}, "end_point": {"row": 111, "column": 22}}, {"id": 669, "type": "identifier", "text": "Object_constructor", "parent": 656, "children": [], "start_point": {"row": 112, "column": 2}, "end_point": {"row": 112, "column": 20}}, {"id": 670, "type": "identifier", "text": "Object_destructor", "parent": 656, "children": [], "start_point": {"row": 113, "column": 2}, "end_point": {"row": 113, "column": 19}}, {"id": 671, "type": "identifier", "text": "Object_copy", "parent": 656, "children": [], "start_point": {"row": 114, "column": 2}, "end_point": {"row": 114, "column": 13}}, {"id": 672, "type": "identifier", "text": "Object_equals", "parent": 656, "children": [], "start_point": {"row": 115, "column": 2}, "end_point": {"row": 115, "column": 15}}, {"id": 673, "type": "identifier", "text": "Object_hash", "parent": 656, "children": [], "start_point": {"row": 116, "column": 2}, "end_point": {"row": 116, "column": 13}}, {"id": 674, "type": "identifier", "text": "Object_copyDescription", "parent": 656, "children": [], "start_point": {"row": 117, "column": 2}, "end_point": {"row": 117, "column": 24}}, {"id": 675, "type": "identifier", "text": "Object_retain", "parent": 656, "children": [], "start_point": {"row": 118, "column": 2}, "end_point": {"row": 118, "column": 15}}, {"id": 676, "type": "identifier", "text": "Object_release", "parent": 656, "children": [], "start_point": {"row": 119, "column": 2}, "end_point": {"row": 119, "column": 16}}, {"id": 677, "type": "identifier", "text": "Object_retainCount", "parent": 656, "children": [], "start_point": {"row": 120, "column": 2}, "end_point": {"row": 120, "column": 20}}, {"id": 678, "type": "identifier", "text": "Object_autorelease", "parent": 656, "children": [], "start_point": {"row": 121, "column": 2}, "end_point": {"row": 121, "column": 20}}, {"id": 679, "type": "initializer_list", "text": "{\t{object+1},\n\t\t\"Class\",\n\t\tobject,\n\t\tsizeof(struct Classs),\n\t\tClass_constructor,\n\t\tClass_destructor,\n\t\tClass_copy,\n\t\tObject_equals,\n\t\tClass_hash,\n\t\tObject_copyDescription,\n\t\tClass_retain,\n\t\tObject_release,\n\t\tObject_retainCount,\n\t\tClass_autorelease,\n\t}", "parent": 655, "children": [680, 685, 686, 687, 692, 693, 694, 695, 696, 697, 698, 699, 700, 701], "start_point": {"row": 123, "column": 1}, "end_point": {"row": 137, "column": 2}}, {"id": 680, "type": "initializer_list", "text": "{object+1}", "parent": 679, "children": [681], "start_point": {"row": 123, "column": 3}, "end_point": {"row": 123, "column": 13}}, {"id": 681, "type": "binary_expression", "text": "object+1", "parent": 680, "children": [682, 683, 684], "start_point": {"row": 123, "column": 4}, "end_point": {"row": 123, "column": 12}}, {"id": 682, "type": "identifier", "text": "object", "parent": 681, "children": [], "start_point": {"row": 123, "column": 4}, "end_point": {"row": 123, "column": 10}}, {"id": 683, "type": "+", "text": "+", "parent": 681, "children": [], "start_point": {"row": 123, "column": 10}, "end_point": {"row": 123, "column": 11}}, {"id": 684, "type": "number_literal", "text": "1", "parent": 681, "children": [], "start_point": {"row": 123, "column": 11}, "end_point": {"row": 123, "column": 12}}, {"id": 685, "type": "string_literal", "text": "\"Class\"", "parent": 679, "children": [], "start_point": {"row": 124, "column": 2}, "end_point": {"row": 124, "column": 9}}, {"id": 686, "type": "identifier", "text": "object", "parent": 679, "children": [], "start_point": {"row": 125, "column": 2}, "end_point": {"row": 125, "column": 8}}, {"id": 687, "type": "sizeof_expression", "text": "sizeof(struct Classs)", "parent": 679, "children": [688], "start_point": {"row": 126, "column": 2}, "end_point": {"row": 126, "column": 23}}, {"id": 688, "type": "type_descriptor", "text": "struct Classs", "parent": 687, "children": [689], "start_point": {"row": 126, "column": 9}, "end_point": {"row": 126, "column": 22}}, {"id": 689, "type": "struct_specifier", "text": "struct Classs", "parent": 688, "children": [690, 691], "start_point": {"row": 126, "column": 9}, "end_point": {"row": 126, "column": 22}}, {"id": 690, "type": "struct", "text": "struct", "parent": 689, "children": [], "start_point": {"row": 126, "column": 9}, "end_point": {"row": 126, "column": 15}}, {"id": 691, "type": "type_identifier", "text": "Classs", "parent": 689, "children": [], "start_point": {"row": 126, "column": 16}, "end_point": {"row": 126, "column": 22}}, {"id": 692, "type": "identifier", "text": "Class_constructor", "parent": 679, "children": [], "start_point": {"row": 127, "column": 2}, "end_point": {"row": 127, "column": 19}}, {"id": 693, "type": "identifier", "text": "Class_destructor", "parent": 679, "children": [], "start_point": {"row": 128, "column": 2}, "end_point": {"row": 128, "column": 18}}, {"id": 694, "type": "identifier", "text": "Class_copy", "parent": 679, "children": [], "start_point": {"row": 129, "column": 2}, "end_point": {"row": 129, "column": 12}}, {"id": 695, "type": "identifier", "text": "Object_equals", "parent": 679, "children": [], "start_point": {"row": 130, "column": 2}, "end_point": {"row": 130, "column": 15}}, {"id": 696, "type": "identifier", "text": "Class_hash", "parent": 679, "children": [], "start_point": {"row": 131, "column": 2}, "end_point": {"row": 131, "column": 12}}, {"id": 697, "type": "identifier", "text": "Object_copyDescription", "parent": 679, "children": [], "start_point": {"row": 132, "column": 2}, "end_point": {"row": 132, "column": 24}}, {"id": 698, "type": "identifier", "text": "Class_retain", "parent": 679, "children": [], "start_point": {"row": 133, "column": 2}, "end_point": {"row": 133, "column": 14}}, {"id": 699, "type": "identifier", "text": "Object_release", "parent": 679, "children": [], "start_point": {"row": 134, "column": 2}, "end_point": {"row": 134, "column": 16}}, {"id": 700, "type": "identifier", "text": "Object_retainCount", "parent": 679, "children": [], "start_point": {"row": 135, "column": 2}, "end_point": {"row": 135, "column": 20}}, {"id": 701, "type": "identifier", "text": "Class_autorelease", "parent": 679, "children": [], "start_point": {"row": 136, "column": 2}, "end_point": {"row": 136, "column": 19}}, {"id": 702, "type": "declaration", "text": "const void *const Object = (const void * const)(object);", "parent": null, "children": [703, 704], "start_point": {"row": 140, "column": 0}, "end_point": {"row": 140, "column": 56}}, {"id": 703, "type": "primitive_type", "text": "void", "parent": 702, "children": [], "start_point": {"row": 140, "column": 6}, "end_point": {"row": 140, "column": 10}}, {"id": 704, "type": "init_declarator", "text": "*const Object = (const void * const)(object)", "parent": 702, "children": [705, 708, 709], "start_point": {"row": 140, "column": 11}, "end_point": {"row": 140, "column": 55}}, {"id": 705, "type": "pointer_declarator", "text": "*const Object", "parent": 704, "children": [706, 707], "start_point": {"row": 140, "column": 11}, "end_point": {"row": 140, "column": 24}}, {"id": 706, "type": "*", "text": "*", "parent": 705, "children": [], "start_point": {"row": 140, "column": 11}, "end_point": {"row": 140, "column": 12}}, {"id": 707, "type": "identifier", "text": "Object", "parent": 705, "children": [], "start_point": {"row": 140, "column": 18}, "end_point": {"row": 140, "column": 24}}, {"id": 708, "type": "=", "text": "=", "parent": 704, "children": [], "start_point": {"row": 140, "column": 25}, "end_point": {"row": 140, "column": 26}}, {"id": 709, "type": "cast_expression", "text": "(const void * const)(object)", "parent": 704, "children": [710, 714], "start_point": {"row": 140, "column": 27}, "end_point": {"row": 140, "column": 55}}, {"id": 710, "type": "type_descriptor", "text": "const void * const", "parent": 709, "children": [711, 712], "start_point": {"row": 140, "column": 28}, "end_point": {"row": 140, "column": 46}}, {"id": 711, "type": "primitive_type", "text": "void", "parent": 710, "children": [], "start_point": {"row": 140, "column": 34}, "end_point": {"row": 140, "column": 38}}, {"id": 712, "type": "abstract_pointer_declarator", "text": "* const", "parent": 710, "children": [713], "start_point": {"row": 140, "column": 39}, "end_point": {"row": 140, "column": 46}}, {"id": 713, "type": "*", "text": "*", "parent": 712, "children": [], "start_point": {"row": 140, "column": 39}, "end_point": {"row": 140, "column": 40}}, {"id": 714, "type": "parenthesized_expression", "text": "(object)", "parent": 709, "children": [715], "start_point": {"row": 140, "column": 47}, "end_point": {"row": 140, "column": 55}}, {"id": 715, "type": "identifier", "text": "object", "parent": 714, "children": [], "start_point": {"row": 140, "column": 48}, "end_point": {"row": 140, "column": 54}}, {"id": 716, "type": "declaration", "text": "const void *const Class = (const void * const )(object+1);", "parent": null, "children": [717, 718], "start_point": {"row": 141, "column": 0}, "end_point": {"row": 141, "column": 58}}, {"id": 717, "type": "primitive_type", "text": "void", "parent": 716, "children": [], "start_point": {"row": 141, "column": 6}, "end_point": {"row": 141, "column": 10}}, {"id": 718, "type": "init_declarator", "text": "*const Class = (const void * const )(object+1)", "parent": 716, "children": [719, 722, 723], "start_point": {"row": 141, "column": 11}, "end_point": {"row": 141, "column": 57}}, {"id": 719, "type": "pointer_declarator", "text": "*const Class", "parent": 718, "children": [720, 721], "start_point": {"row": 141, "column": 11}, "end_point": {"row": 141, "column": 23}}, {"id": 720, "type": "*", "text": "*", "parent": 719, "children": [], "start_point": {"row": 141, "column": 11}, "end_point": {"row": 141, "column": 12}}, {"id": 721, "type": "identifier", "text": "Class", "parent": 719, "children": [], "start_point": {"row": 141, "column": 18}, "end_point": {"row": 141, "column": 23}}, {"id": 722, "type": "=", "text": "=", "parent": 718, "children": [], "start_point": {"row": 141, "column": 24}, "end_point": {"row": 141, "column": 25}}, {"id": 723, "type": "cast_expression", "text": "(const void * const )(object+1)", "parent": 718, "children": [724, 728], "start_point": {"row": 141, "column": 26}, "end_point": {"row": 141, "column": 57}}, {"id": 724, "type": "type_descriptor", "text": "const void * const", "parent": 723, "children": [725, 726], "start_point": {"row": 141, "column": 27}, "end_point": {"row": 141, "column": 45}}, {"id": 725, "type": "primitive_type", "text": "void", "parent": 724, "children": [], "start_point": {"row": 141, "column": 33}, "end_point": {"row": 141, "column": 37}}, {"id": 726, "type": "abstract_pointer_declarator", "text": "* const", "parent": 724, "children": [727], "start_point": {"row": 141, "column": 38}, "end_point": {"row": 141, "column": 45}}, {"id": 727, "type": "*", "text": "*", "parent": 726, "children": [], "start_point": {"row": 141, "column": 38}, "end_point": {"row": 141, "column": 39}}, {"id": 728, "type": "parenthesized_expression", "text": "(object+1)", "parent": 723, "children": [729], "start_point": {"row": 141, "column": 47}, "end_point": {"row": 141, "column": 57}}, {"id": 729, "type": "binary_expression", "text": "object+1", "parent": 728, "children": [730, 731, 732], "start_point": {"row": 141, "column": 48}, "end_point": {"row": 141, "column": 56}}, {"id": 730, "type": "identifier", "text": "object", "parent": 729, "children": [], "start_point": {"row": 141, "column": 48}, "end_point": {"row": 141, "column": 54}}, {"id": 731, "type": "+", "text": "+", "parent": 729, "children": [], "start_point": {"row": 141, "column": 54}, "end_point": {"row": 141, "column": 55}}, {"id": 732, "type": "number_literal", "text": "1", "parent": 729, "children": [], "start_point": {"row": 141, "column": 55}, "end_point": {"row": 141, "column": 56}}]}, "node_categories": {"declarations": {"functions": [31, 35, 181, 470, 474, 485, 489, 500, 502, 607, 611, 622, 624, 632, 636], "variables": [38, 43, 48, 109, 178, 187, 194, 215, 477, 492, 505, 516, 533, 560, 566, 614, 627, 639, 647, 702, 716], "classes": [49, 50, 119, 120, 131, 132, 517, 518, 534, 535, 648, 649, 666, 667, 689, 690], "imports": [4, 5, 7, 8, 10, 11, 13, 14, 16, 17, 19, 20, 22, 23, 25, 26, 28, 29], "modules": [], "enums": []}, "statements": {"expressions": [59, 63, 66, 73, 77, 80, 88, 92, 95, 99, 102, 103, 114, 115, 116, 117, 123, 129, 137, 138, 140, 143, 144, 152, 153, 158, 159, 164, 165, 168, 173, 197, 201, 205, 206, 210, 220, 226, 227, 230, 235, 237, 242, 243, 250, 251, 254, 259, 261, 266, 267, 274, 275, 278, 283, 285, 290, 291, 298, 299, 302, 307, 309, 314, 315, 322, 323, 326, 331, 333, 338, 339, 346, 347, 350, 355, 357, 362, 363, 370, 371, 374, 379, 381, 386, 387, 394, 395, 398, 403, 405, 410, 411, 418, 419, 422, 427, 429, 434, 435, 442, 443, 446, 451, 453, 458, 459, 464, 510, 524, 528, 542, 546, 552, 555, 571, 572, 580, 581, 586, 589, 592, 597, 598, 603, 658, 664, 681, 687, 709, 714, 723, 728, 729], "assignments": [58, 72, 87, 207, 234, 258, 282, 306, 330, 354, 378, 402, 426, 450, 577, 594], "loops": [204], "conditionals": [2, 36, 42, 44, 47, 51, 55, 57, 60, 61, 64, 68, 70, 74, 75, 78, 82, 83, 85, 89, 90, 93, 97, 98, 100, 104, 105, 110, 112, 121, 133, 139, 141, 149, 151, 160, 161, 163, 166, 174, 175, 177, 185, 188, 190, 195, 196, 198, 200, 203, 208, 211, 213, 214, 216, 218, 221, 223, 224, 225, 228, 232, 233, 239, 244, 245, 247, 249, 252, 256, 257, 263, 268, 269, 271, 273, 276, 280, 281, 287, 292, 293, 295, 297, 300, 304, 305, 311, 316, 317, 319, 321, 324, 328, 329, 335, 340, 341, 343, 345, 348, 352, 353, 359, 364, 365, 367, 369, 372, 376, 377, 383, 388, 389, 391, 393, 396, 400, 401, 407, 412, 413, 415, 417, 420, 424, 425, 431, 436, 437, 439, 441, 444, 448, 449, 455, 460, 461, 463, 465, 467, 469, 475, 481, 490, 496, 501, 503, 509, 511, 513, 514, 519, 525, 527, 529, 531, 536, 540, 543, 545, 547, 549, 550, 553, 556, 557, 558, 561, 563, 567, 569, 573, 574, 576, 578, 582, 584, 588, 590, 593, 595, 599, 601, 604, 606, 612, 618, 625, 631, 637, 643, 650, 653, 659, 663, 668, 669, 670, 671, 672, 673, 674, 675, 676, 677, 678, 682, 686, 691, 692, 693, 694, 695, 696, 697, 698, 699, 700, 701, 707, 715, 721, 730], "returns": [468, 482, 497, 605, 619, 644], "exceptions": []}, "expressions": {"calls": [], "literals": [6, 9, 12, 15, 18, 21, 24, 27, 30, 515, 532, 551, 559, 565, 661, 662, 684, 685, 732], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 31, "universal_type": "function", "name": "*", "text_snippet": "static void * Class_constructor (void * _self, va_list * app) {\n\tstruct Classs * self = _self;\n\t\n\tse"}, {"node_id": 35, "universal_type": "function", "name": "unknown", "text_snippet": "Class_constructor (void * _self, va_list * app)"}, {"node_id": 181, "universal_type": "function", "name": "unknown", "text_snippet": "(*voidf) ()"}, {"node_id": 470, "universal_type": "function", "name": "*", "text_snippet": "static void * Class_destructor (void * _self) {\n\treturn NULL;\n}"}, {"node_id": 474, "universal_type": "function", "name": "unknown", "text_snippet": "Class_destructor (void * _self)"}, {"node_id": 485, "universal_type": "function", "name": "*", "text_snippet": "static void * Class_copy (const void *const _self) {\n\treturn NULL;\n}"}, {"node_id": 489, "universal_type": "function", "name": "*const", "text_snippet": "Class_copy (const void *const _self)"}, {"node_id": 500, "universal_type": "function", "name": "*const", "text_snippet": "static UInteger Class_hash (const void *const self) {\n\tCOAssertNoNullOrReturn(self,EINVAL,0);\n\tconst"}, {"node_id": 502, "universal_type": "function", "name": "*const", "text_snippet": "Class_hash (const void *const self)"}, {"node_id": 607, "universal_type": "function", "name": "*", "text_snippet": "static void * Class_retain (void *const _self) {\n\treturn NULL;\n}"}, {"node_id": 611, "universal_type": "function", "name": "unknown", "text_snippet": "Class_retain (void *const _self)"}, {"node_id": 622, "universal_type": "function", "name": "Class_release", "text_snippet": "static void Class_release (void *const _self) {\n}"}, {"node_id": 624, "universal_type": "function", "name": "unknown", "text_snippet": "Class_release (void *const _self)"}, {"node_id": 632, "universal_type": "function", "name": "*Class_autorelease", "text_snippet": "static void *Class_autorelease (void *const _self) {\n\treturn NULL;\n}"}, {"node_id": 636, "universal_type": "function", "name": "unknown", "text_snippet": "Class_autorelease (void *const _self)"}], "class_declarations": [{"node_id": 49, "universal_type": "class", "name": "Classs", "text_snippet": "struct Classs"}, {"node_id": 50, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 119, "universal_type": "class", "name": "Object", "text_snippet": "struct Object"}, {"node_id": 120, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 131, "universal_type": "class", "name": "Class", "text_snippet": "struct Class"}, {"node_id": 132, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 517, "universal_type": "class", "name": "Classs", "text_snippet": "struct Classs"}, {"node_id": 518, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 534, "universal_type": "class", "name": "Classs", "text_snippet": "struct Classs"}, {"node_id": 535, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 648, "universal_type": "class", "name": "Classs", "text_snippet": "struct Classs"}, {"node_id": 649, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 666, "universal_type": "class", "name": "Object", "text_snippet": "struct Object"}, {"node_id": 667, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 689, "universal_type": "class", "name": "Classs", "text_snippet": "struct Classs"}, {"node_id": 690, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": [{"node_id": 4, "text": "#include <stdio.h>\n"}, {"node_id": 5, "text": "#include"}, {"node_id": 7, "text": "#include <stdlib.h>\n"}, {"node_id": 8, "text": "#include"}, {"node_id": 10, "text": "#include <string.h>\n"}, {"node_id": 11, "text": "#include"}, {"node_id": 13, "text": "#include <stdarg.h>\n"}, {"node_id": 14, "text": "#include"}, {"node_id": 16, "text": "#include <coassert.h>\n"}, {"node_id": 17, "text": "#include"}, {"node_id": 19, "text": "#include <errno.h>\n"}, {"node_id": 20, "text": "#include"}, {"node_id": 22, "text": "#include <Object.h>\n"}, {"node_id": 23, "text": "#include"}, {"node_id": 25, "text": "#include <Object.r>\n"}, {"node_id": 26, "text": "#include"}, {"node_id": 28, "text": "#include <new.h>\n"}, {"node_id": 29, "text": "#include"}]}, "original_source_code": "//\n// class.c\n// CObjects\n//\n// Created by <NAME> on 9/2/13.\n// Copyright (c) 2013 <NAME>. All rights reserved.\n//\n#define _XOPEN_SOURCE 700\n\n#include <stdio.h>\n#include <stdlib.h>\n#include <string.h>\n#include <stdarg.h>\n\n#include <coassert.h>\n#include <errno.h>\n\n#include <Object.h>\n#include <Object.r>\n#include <new.h>\n\n\nstatic void * Class_constructor (void * _self, va_list * app) {\n\tstruct Classs * self = _self;\n\t\n\tself->class_name = va_arg( *app, const char *);\n\tself->super = va_arg( *app, struct Classs *);\n\tself->size = va_arg( *app, UInteger);\n\t\n\tassert(self->super != NULL);\n\tconst UInteger offset\t = sizeof(struct Object) + sizeof(char *) + sizeof(struct Class *) + sizeof(UInteger);\n\tmemcpy((char *)self + offset, (char *)(self->super) + offset, sizeOf((void *)self->super) - offset);\n\t{\n\t\ttypedef void (*voidf) ();\n\t\tvoidf selector = NULL;\n\t\tva_list ap;\n\t\tva_copy(ap, *app);\n\t\t\n\t\twhile ( (selector = va_arg(ap, voidf)) ) {\n\t\t\tvoidf method = va_arg(ap, voidf);\n\t\t\t\n\t\t\tif ( selector == (voidf) constructor )\n\t\t\t\t* (voidf *) & self->constructor = method;\n\t\t\telse if ( selector == (voidf) destructor )\n\t\t\t\t* (voidf *) & self->destructor = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copy )\n\t\t\t\t* (voidf *) & self->copy = method;\n\t\t\telse if ( selector == (voidf) equals )\n\t\t\t\t* (voidf *) & self->equals = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) hash )\n\t\t\t\t* (voidf *) & self->hash = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) retain )\n\t\t\t\t* (voidf *) & self->retain = method;\n\t\t\telse if ( selector == (voidf) release )\n\t\t\t\t* (voidf *) & self->release = method;\n\t\t\telse if ( selector == (voidf) retainCount )\n\t\t\t\t* (voidf *) & self->retainCount = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) copyDescription )\n\t\t\t\t* (voidf *) & self->copyDescription = method;\n\t\t\t\n\t\t\telse if ( selector == (voidf) autorelease )\n\t\t\t\t* (voidf *) & self->autorelease = method;\n\t\t}\n\t\tva_end(ap);\n\t}\n\t\n\treturn self;\n}\n\nstatic void * Class_destructor (void * _self) {\n\treturn NULL;\n}\n\nstatic void * Class_copy (const void *const _self) {\n\treturn NULL;\n}\n\nstatic UInteger Class_hash (const void *const self) {\n\tCOAssertNoNullOrReturn(self,EINVAL,0);\n\tconst struct Classs *const class = classOf(self);\n\tCOAssertNoNullOrReturn(class,EINVAL,0);\n\tconst struct Classs *const _superclass = superclass(self);\n\tCOAssertNoNullOrReturn(_superclass,EINVAL,0);\n\tCOAssertNoNullOrReturn(_superclass->hash,EINVAL,0);\n\t\n\t\n\tUInteger prime = 31;\n\tUInteger result = _superclass->hash(self);\n\tresult = prime * result + (UInteger)strlen(class->class_name);\n\tresult = prime * result + class->size;\n\treturn result;\n}\nstatic void * Class_retain (void *const _self) {\n\treturn NULL;\n}\n\nstatic void Class_release (void *const _self) {\n}\n\nstatic void *Class_autorelease (void *const _self) {\n\treturn NULL;\n}\n\nstatic const struct Classs object [] = {\n\t{\t{object+1},\n\t\t\"Object\",\n\t\tobject,\n\t\tsizeof(struct Object),\n\t\tObject_constructor,\n\t\tObject_destructor,\n\t\tObject_copy,\n\t\tObject_equals,\n\t\tObject_hash,\n\t\tObject_copyDescription,\n\t\tObject_retain,\n\t\tObject_release,\n\t\tObject_retainCount,\n\t\tObject_autorelease,\n\t},\n\t{\t{object+1},\n\t\t\"Class\",\n\t\tobject,\n\t\tsizeof(struct Classs),\n\t\tClass_constructor,\n\t\tClass_destructor,\n\t\tClass_copy,\n\t\tObject_equals,\n\t\tClass_hash,\n\t\tObject_copyDescription,\n\t\tClass_retain,\n\t\tObject_release,\n\t\tObject_retainCount,\n\t\tClass_autorelease,\n\t}\n};\n\nconst void *const Object = (const void * const)(object);\nconst void *const Class = (const void * const )(object+1);\n\n\n\n"}
80,514
c
#ifndef __NATASHA_MUSEUM_H__ #define __NATASHA_MUSEUM_H__ #include <assert.h> #include <vector> #include "../include/game3x5.h" #include "../include/gamelogic.h" #include "basegame.h" #include "freegame.h" #include "game_museum.h" namespace natasha { // countRTP_museum - count rtp void countRTP_museum(); // Museum class Museum : public GameLogic { public: Museum() {} virtual ~Museum() {} public: virtual ::natashapb::CODE init(const char* cfgpath); // getMainGameMod - get current main game module virtual GameMod* getMainGameMod(UserInfo* pUser, bool isComeInGame); #ifdef NATASHA_COUNTRTP public: virtual void onInitRTP() { addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols); addRTPModuleBonus(::natashapb::BASE_GAME, "wildbomb", 6); addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols); addRTPModuleBonus(::natashapb::FREE_GAME, "wildbomb", 6); } virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module, const ::natashapb::SpinResult& spinret, const ::natashapb::GameResultInfo& gri, const ::natashapb::UserGameModInfo* pUser) { if (gri.typegameresult() == ::natashapb::SPECIAL) { auto turnnums = pUser->cascadinginfo().turnnums(); if (turnnums > 6) { turnnums = 6; } m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin()); } else { m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(), gri.realwin() * spinret.awardmul()); } } #endif // NATASHA_COUNTRTP #ifdef NATASHA_RUNINCPP public: void initConfig(); #endif // NATASHA_RUNINCPP protected: NormalReels3X5 m_reels; Paytables3X5 m_paytables; BetList m_lstBet; ::natashapb::MuseumConfig m_cfg; }; // namespace natasha } // namespace natasha #endif // __NATASHA_MUSEUM_H__
33.07
57
(translation_unit) "#ifndef __NATASHA_MUSEUM_H__\n#define __NATASHA_MUSEUM_H__\n\n#include <assert.h>\n#include <vector>\n#include "../include/game3x5.h"\n#include "../include/gamelogic.h"\n#include "basegame.h"\n#include "freegame.h"\n#include "game_museum.h"\n\nnamespace natasha {\n\n// countRTP_museum - count rtp\nvoid countRTP_museum();\n\n// Museum\nclass Museum : public GameLogic {\n public:\n Museum() {}\n virtual ~Museum() {}\n\n public:\n virtual ::natashapb::CODE init(const char* cfgpath);\n\n // getMainGameMod - get current main game module\n virtual GameMod* getMainGameMod(UserInfo* pUser, bool isComeInGame);\n#ifdef NATASHA_COUNTRTP\n public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::BASE_GAME, "wildbomb", 6);\n addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::FREE_GAME, "wildbomb", 6);\n }\n\n virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }\n#endif // NATASHA_COUNTRTP\n\n#ifdef NATASHA_RUNINCPP\n public:\n void initConfig();\n#endif // NATASHA_RUNINCPP\n\n protected:\n NormalReels3X5 m_reels;\n Paytables3X5 m_paytables;\n BetList m_lstBet;\n ::natashapb::MuseumConfig m_cfg;\n}; // namespace natasha\n\n} // namespace natasha\n\n#endif // __NATASHA_MUSEUM_H__" (preproc_ifdef) "#ifndef __NATASHA_MUSEUM_H__\n#define __NATASHA_MUSEUM_H__\n\n#include <assert.h>\n#include <vector>\n#include "../include/game3x5.h"\n#include "../include/gamelogic.h"\n#include "basegame.h"\n#include "freegame.h"\n#include "game_museum.h"\n\nnamespace natasha {\n\n// countRTP_museum - count rtp\nvoid countRTP_museum();\n\n// Museum\nclass Museum : public GameLogic {\n public:\n Museum() {}\n virtual ~Museum() {}\n\n public:\n virtual ::natashapb::CODE init(const char* cfgpath);\n\n // getMainGameMod - get current main game module\n virtual GameMod* getMainGameMod(UserInfo* pUser, bool isComeInGame);\n#ifdef NATASHA_COUNTRTP\n public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::BASE_GAME, "wildbomb", 6);\n addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::FREE_GAME, "wildbomb", 6);\n }\n\n virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }\n#endif // NATASHA_COUNTRTP\n\n#ifdef NATASHA_RUNINCPP\n public:\n void initConfig();\n#endif // NATASHA_RUNINCPP\n\n protected:\n NormalReels3X5 m_reels;\n Paytables3X5 m_paytables;\n BetList m_lstBet;\n ::natashapb::MuseumConfig m_cfg;\n}; // namespace natasha\n\n} // namespace natasha\n\n#endif" (#ifndef) "#ifndef" (identifier) "__NATASHA_MUSEUM_H__" (preproc_def) "#define __NATASHA_MUSEUM_H__\n" (#define) "#define" (identifier) "__NATASHA_MUSEUM_H__" (preproc_include) "#include <assert.h>\n" (#include) "#include" (system_lib_string) "<assert.h>" (preproc_include) "#include <vector>\n" (#include) "#include" (system_lib_string) "<vector>" (preproc_include) "#include "../include/game3x5.h"\n" (#include) "#include" (string_literal) ""../include/game3x5.h"" (") """ (string_content) "../include/game3x5.h" (") """ (preproc_include) "#include "../include/gamelogic.h"\n" (#include) "#include" (string_literal) ""../include/gamelogic.h"" (") """ (string_content) "../include/gamelogic.h" (") """ (preproc_include) "#include "basegame.h"\n" (#include) "#include" (string_literal) ""basegame.h"" (") """ (string_content) "basegame.h" (") """ (preproc_include) "#include "freegame.h"\n" (#include) "#include" (string_literal) ""freegame.h"" (") """ (string_content) "freegame.h" (") """ (preproc_include) "#include "game_museum.h"\n" (#include) "#include" (string_literal) ""game_museum.h"" (") """ (string_content) "game_museum.h" (") """ (function_definition) "namespace natasha {\n\n// countRTP_museum - count rtp\nvoid countRTP_museum();\n\n// Museum\nclass Museum : public GameLogic {\n public:\n Museum() {}\n virtual ~Museum() {}\n\n public:\n virtual ::natashapb::CODE init(const char* cfgpath);\n\n // getMainGameMod - get current main game module\n virtual GameMod* getMainGameMod(UserInfo* pUser, bool isComeInGame);\n#ifdef NATASHA_COUNTRTP\n public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::BASE_GAME, "wildbomb", 6);\n addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::FREE_GAME, "wildbomb", 6);\n }\n\n virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }\n#endif // NATASHA_COUNTRTP\n\n#ifdef NATASHA_RUNINCPP\n public:\n void initConfig();\n#endif // NATASHA_RUNINCPP\n\n protected:\n NormalReels3X5 m_reels;\n Paytables3X5 m_paytables;\n BetList m_lstBet;\n ::natashapb::MuseumConfig m_cfg;\n}; // namespace natasha\n\n}" (type_identifier) "namespace" (identifier) "natasha" (compound_statement) "{\n\n// countRTP_museum - count rtp\nvoid countRTP_museum();\n\n// Museum\nclass Museum : public GameLogic {\n public:\n Museum() {}\n virtual ~Museum() {}\n\n public:\n virtual ::natashapb::CODE init(const char* cfgpath);\n\n // getMainGameMod - get current main game module\n virtual GameMod* getMainGameMod(UserInfo* pUser, bool isComeInGame);\n#ifdef NATASHA_COUNTRTP\n public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::BASE_GAME, "wildbomb", 6);\n addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::FREE_GAME, "wildbomb", 6);\n }\n\n virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }\n#endif // NATASHA_COUNTRTP\n\n#ifdef NATASHA_RUNINCPP\n public:\n void initConfig();\n#endif // NATASHA_RUNINCPP\n\n protected:\n NormalReels3X5 m_reels;\n Paytables3X5 m_paytables;\n BetList m_lstBet;\n ::natashapb::MuseumConfig m_cfg;\n}; // namespace natasha\n\n}" ({) "{" (comment) "// countRTP_museum - count rtp" (declaration) "void countRTP_museum();" (primitive_type) "void" (function_declarator) "countRTP_museum()" (identifier) "countRTP_museum" (parameter_list) "()" (() "(" ()) ")" (;) ";" (comment) "// Museum" (function_definition) "class Museum : public GameLogic {\n public:\n Museum() {}\n virtual ~Museum() {}\n\n public:\n virtual ::natashapb::CODE init(const char* cfgpath);\n\n // getMainGameMod - get current main game module\n virtual GameMod* getMainGameMod(UserInfo* pUser, bool isComeInGame);\n#ifdef NATASHA_COUNTRTP\n public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::BASE_GAME, "wildbomb", 6);\n addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::FREE_GAME, "wildbomb", 6);\n }\n\n virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }\n#endif // NATASHA_COUNTRTP\n\n#ifdef NATASHA_RUNINCPP\n public:\n void initConfig();\n#endif // NATASHA_RUNINCPP\n\n protected:\n NormalReels3X5 m_reels;\n Paytables3X5 m_paytables;\n BetList m_lstBet;\n ::natashapb::MuseumConfig m_cfg;\n}" (type_identifier) "class" (ERROR) "Museum : public" (identifier) "Museum" (:) ":" (identifier) "public" (identifier) "GameLogic" (compound_statement) "{\n public:\n Museum() {}\n virtual ~Museum() {}\n\n public:\n virtual ::natashapb::CODE init(const char* cfgpath);\n\n // getMainGameMod - get current main game module\n virtual GameMod* getMainGameMod(UserInfo* pUser, bool isComeInGame);\n#ifdef NATASHA_COUNTRTP\n public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::BASE_GAME, "wildbomb", 6);\n addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::FREE_GAME, "wildbomb", 6);\n }\n\n virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }\n#endif // NATASHA_COUNTRTP\n\n#ifdef NATASHA_RUNINCPP\n public:\n void initConfig();\n#endif // NATASHA_RUNINCPP\n\n protected:\n NormalReels3X5 m_reels;\n Paytables3X5 m_paytables;\n BetList m_lstBet;\n ::natashapb::MuseumConfig m_cfg;\n}" ({) "{" (labeled_statement) "public:\n Museum() {}" (statement_identifier) "public" (:) ":" (ERROR) "Museum()" (call_expression) "Museum()" (identifier) "Museum" (argument_list) "()" (() "(" ()) ")" (compound_statement) "{}" ({) "{" (}) "}" (function_definition) "virtual ~Museum() {}" (type_identifier) "virtual" (ERROR) "~" (~) "~" (function_declarator) "Museum()" (identifier) "Museum" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{}" ({) "{" (}) "}" (labeled_statement) "public:\n virtual ::natashapb::CODE init(const char* cfgpath);" (statement_identifier) "public" (:) ":" (labeled_statement) "virtual ::natashapb::CODE init(const char* cfgpath);" (statement_identifier) "virtual" (:) ":" (ERROR) ":" (:) ":" (labeled_statement) "natashapb::CODE init(const char* cfgpath);" (statement_identifier) "natashapb" (:) ":" (ERROR) ":" (:) ":" (declaration) "CODE init(const char* cfgpath);" (type_identifier) "CODE" (function_declarator) "init(const char* cfgpath)" (identifier) "init" (parameter_list) "(const char* cfgpath)" (() "(" (parameter_declaration) "const char* cfgpath" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "* cfgpath" (*) "*" (identifier) "cfgpath" ()) ")" (;) ";" (comment) "// getMainGameMod - get current main game module" (declaration) "virtual GameMod* getMainGameMod(UserInfo* pUser, bool isComeInGame);" (type_identifier) "virtual" (ERROR) "GameMod" (identifier) "GameMod" (pointer_declarator) "* getMainGameMod(UserInfo* pUser, bool isComeInGame)" (*) "*" (function_declarator) "getMainGameMod(UserInfo* pUser, bool isComeInGame)" (identifier) "getMainGameMod" (parameter_list) "(UserInfo* pUser, bool isComeInGame)" (() "(" (parameter_declaration) "UserInfo* pUser" (type_identifier) "UserInfo" (pointer_declarator) "* pUser" (*) "*" (identifier) "pUser" (,) "," (parameter_declaration) "bool isComeInGame" (primitive_type) "bool" (identifier) "isComeInGame" ()) ")" (;) ";" (preproc_ifdef) "#ifdef NATASHA_COUNTRTP\n public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::BASE_GAME, "wildbomb", 6);\n addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::FREE_GAME, "wildbomb", 6);\n }\n\n virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }\n#endif" (#ifdef) "#ifdef" (identifier) "NATASHA_COUNTRTP" (labeled_statement) "public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);" (statement_identifier) "public" (:) ":" (declaration) "virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);" (type_identifier) "virtual" (ERROR) "void onInitRTP() {" (identifier) "void" (function_declarator) "onInitRTP()" (identifier) "onInitRTP" (parameter_list) "()" (() "(" ()) ")" ({) "{" (function_declarator) "addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols)" (identifier) "addRTPModule" (parameter_list) "(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols)" (() "(" (ERROR) "::" (:) ":" (:) ":" (parameter_declaration) "natashapb::BASE_GAME" (type_identifier) "natashapb" (ERROR) "::" (:) ":" (:) ":" (identifier) "BASE_GAME" (,) "," (parameter_declaration) "MeseumMaxPayoutNums" (type_identifier) "MeseumMaxPayoutNums" (,) "," (parameter_declaration) "MeseumMaxSymbols" (type_identifier) "MeseumMaxSymbols" ()) ")" (;) ";" (labeled_statement) "addRTPModuleBonus(::natashapb::BASE_GAME, "wildbomb", 6);" (statement_identifier) "addRTPModuleBonus" (ERROR) "(:" (() "(" (:) ":" (:) ":" (labeled_statement) "natashapb::BASE_GAME, "wildbomb", 6);" (statement_identifier) "natashapb" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "BASE_GAME, "wildbomb", 6);" (comma_expression) "BASE_GAME, "wildbomb", 6" (identifier) "BASE_GAME" (,) "," (comma_expression) ""wildbomb", 6" (string_literal) ""wildbomb"" (") """ (string_content) "wildbomb" (") """ (,) "," (number_literal) "6" (ERROR) ")" ()) ")" (;) ";" (labeled_statement) "addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);" (statement_identifier) "addRTPModule" (ERROR) "(:" (() "(" (:) ":" (:) ":" (labeled_statement) "natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);" (statement_identifier) "natashapb" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);" (comma_expression) "FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols" (identifier) "FREE_GAME" (,) "," (comma_expression) "MeseumMaxPayoutNums, MeseumMaxSymbols" (identifier) "MeseumMaxPayoutNums" (,) "," (identifier) "MeseumMaxSymbols" (ERROR) ")" ()) ")" (;) ";" (labeled_statement) "addRTPModuleBonus(::natashapb::FREE_GAME, "wildbomb", 6);" (statement_identifier) "addRTPModuleBonus" (ERROR) "(:" (() "(" (:) ":" (:) ":" (labeled_statement) "natashapb::FREE_GAME, "wildbomb", 6);" (statement_identifier) "natashapb" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "FREE_GAME, "wildbomb", 6);" (comma_expression) "FREE_GAME, "wildbomb", 6" (identifier) "FREE_GAME" (,) "," (comma_expression) ""wildbomb", 6" (string_literal) ""wildbomb"" (") """ (string_content) "wildbomb" (") """ (,) "," (number_literal) "6" (ERROR) ")" ()) ")" (;) ";" (ERROR) "}" (}) "}" (function_definition) "virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }" (type_identifier) "virtual" (ERROR) "void" (identifier) "void" (function_declarator) "onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser)" (identifier) "onRTPAddPayoutGRI" (parameter_list) "(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser)" (() "(" (ERROR) "::" (:) ":" (:) ":" (parameter_declaration) "natashapb::GAMEMODTYPE module" (type_identifier) "natashapb" (ERROR) "::GAMEMODTYPE" (:) ":" (:) ":" (identifier) "GAMEMODTYPE" (identifier) "module" (,) "," (parameter_declaration) "const ::natashapb::SpinResult& spinret" (type_qualifier) "const" (const) "const" (ERROR) "::" (:) ":" (:) ":" (type_identifier) "natashapb" (ERROR) "::SpinResult&" (:) ":" (:) ":" (identifier) "SpinResult" (&) "&" (identifier) "spinret" (,) "," (parameter_declaration) "const ::natashapb::GameResultInfo& gri" (type_qualifier) "const" (const) "const" (ERROR) "::" (:) ":" (:) ":" (type_identifier) "natashapb" (ERROR) "::GameResultInfo&" (:) ":" (:) ":" (identifier) "GameResultInfo" (&) "&" (identifier) "gri" (,) "," (parameter_declaration) "const ::natashapb::UserGameModInfo* pUser" (type_qualifier) "const" (const) "const" (ERROR) "::" (:) ":" (:) ":" (type_identifier) "natashapb" (ERROR) "::UserGameModInfo" (:) ":" (:) ":" (identifier) "UserGameModInfo" (pointer_declarator) "* pUser" (*) "*" (identifier) "pUser" ()) ")" (compound_statement) "{\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }" ({) "{" (if_statement) "if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }" (if) "if" (parenthesized_expression) "(gri.typegameresult() == ::natashapb::SPECIAL)" (() "(" (binary_expression) "gri.typegameresult() == ::natashapb" (call_expression) "gri.typegameresult()" (field_expression) "gri.typegameresult" (identifier) "gri" (.) "." (field_identifier) "typegameresult" (argument_list) "()" (() "(" ()) ")" (==) "==" (ERROR) "::" (:) ":" (:) ":" (identifier) "natashapb" (ERROR) "::SPECIAL" (:) ":" (:) ":" (identifier) "SPECIAL" ()) ")" (compound_statement) "{\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin());\n }" ({) "{" (declaration) "auto turnnums = pUser->cascadinginfo().turnnums();" (storage_class_specifier) "auto" (auto) "auto" (type_identifier) "turnnums" (init_declarator) " = pUser->cascadinginfo().turnnums()" (identifier) "" (=) "=" (call_expression) "pUser->cascadinginfo().turnnums()" (field_expression) "pUser->cascadinginfo().turnnums" (call_expression) "pUser->cascadinginfo()" (field_expression) "pUser->cascadinginfo" (identifier) "pUser" (->) "->" (field_identifier) "cascadinginfo" (argument_list) "()" (() "(" ()) ")" (.) "." (field_identifier) "turnnums" (argument_list) "()" (() "(" ()) ")" (;) ";" (if_statement) "if (turnnums > 6) {\n turnnums = 6;\n }" (if) "if" (parenthesized_expression) "(turnnums > 6)" (() "(" (binary_expression) "turnnums > 6" (identifier) "turnnums" (>) ">" (number_literal) "6" ()) ")" (compound_statement) "{\n turnnums = 6;\n }" ({) "{" (expression_statement) "turnnums = 6;" (assignment_expression) "turnnums = 6" (identifier) "turnnums" (=) "=" (number_literal) "6" (;) ";" (}) "}" (expression_statement) "m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin());" (call_expression) "m_rtp.addBonusPayout(module, "wildbomb", turnnums - 1, gri.realwin())" (field_expression) "m_rtp.addBonusPayout" (identifier) "m_rtp" (.) "." (field_identifier) "addBonusPayout" (argument_list) "(module, "wildbomb", turnnums - 1, gri.realwin())" (() "(" (identifier) "module" (,) "," (string_literal) ""wildbomb"" (") """ (string_content) "wildbomb" (") """ (,) "," (binary_expression) "turnnums - 1" (identifier) "turnnums" (-) "-" (number_literal) "1" (,) "," (call_expression) "gri.realwin()" (field_expression) "gri.realwin" (identifier) "gri" (.) "." (field_identifier) "realwin" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) ";" (}) "}" (else_clause) "else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }" (else) "else" (compound_statement) "{\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }" ({) "{" (expression_statement) "m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());" (call_expression) "m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul())" (field_expression) "m_rtp.addSymbolPayout" (identifier) "m_rtp" (.) "." (field_identifier) "addSymbolPayout" (argument_list) "(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul())" (() "(" (identifier) "module" (,) "," (call_expression) "gri.symbol()" (field_expression) "gri.symbol" (identifier) "gri" (.) "." (field_identifier) "symbol" (argument_list) "()" (() "(" ()) ")" (,) "," (call_expression) "gri.lstsymbol_size()" (field_expression) "gri.lstsymbol_size" (identifier) "gri" (.) "." (field_identifier) "lstsymbol_size" (argument_list) "()" (() "(" ()) ")" (,) "," (binary_expression) "gri.realwin() * spinret.awardmul()" (call_expression) "gri.realwin()" (field_expression) "gri.realwin" (identifier) "gri" (.) "." (field_identifier) "realwin" (argument_list) "()" (() "(" ()) ")" (*) "*" (call_expression) "spinret.awardmul()" (field_expression) "spinret.awardmul" (identifier) "spinret" (.) "." (field_identifier) "awardmul" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) ";" (}) "}" (}) "}" (#endif) "#endif" (comment) "// NATASHA_COUNTRTP" (preproc_ifdef) "#ifdef NATASHA_RUNINCPP\n public:\n void initConfig();\n#endif" (#ifdef) "#ifdef" (identifier) "NATASHA_RUNINCPP" (labeled_statement) "public:\n void initConfig();" (statement_identifier) "public" (:) ":" (declaration) "void initConfig();" (primitive_type) "void" (function_declarator) "initConfig()" (identifier) "initConfig" (parameter_list) "()" (() "(" ()) ")" (;) ";" (#endif) "#endif" (comment) "// NATASHA_RUNINCPP" (labeled_statement) "protected:\n NormalReels3X5 m_reels;" (statement_identifier) "protected" (:) ":" (declaration) "NormalReels3X5 m_reels;" (type_identifier) "NormalReels3X5" (identifier) "m_reels" (;) ";" (declaration) "Paytables3X5 m_paytables;" (type_identifier) "Paytables3X5" (identifier) "m_paytables" (;) ";" (declaration) "BetList m_lstBet;" (type_identifier) "BetList" (identifier) "m_lstBet" (;) ";" (ERROR) "::" (:) ":" (:) ":" (labeled_statement) "natashapb::MuseumConfig m_cfg;" (statement_identifier) "natashapb" (:) ":" (ERROR) ":" (:) ":" (declaration) "MuseumConfig m_cfg;" (type_identifier) "MuseumConfig" (identifier) "m_cfg" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (comment) "// namespace natasha" (}) "}" (comment) "// namespace natasha" (#endif) "#endif" (comment) "// __NATASHA_MUSEUM_H__"
520
32
{"language": "c", "success": true, "metadata": {"lines": 57, "avg_line_length": 33.07, "nodes": 273, "errors": 0, "source_hash": "7e628b2b9f1ce3e73d6b6b9c7469902e236b1e2e7eb4b887593dd0bb99c464cc", "categorized_nodes": 202}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef __NATASHA_MUSEUM_H__\n#define __NATASHA_MUSEUM_H__\n\n#include <assert.h>\n#include <vector>\n#include \"../include/game3x5.h\"\n#include \"../include/gamelogic.h\"\n#include \"basegame.h\"\n#include \"freegame.h\"\n#include \"game_museum.h\"\n\nnamespace natasha {\n\n// countRTP_museum - count rtp\nvoid countRTP_museum();\n\n// Museum\nclass Museum : public GameLogic {\n public:\n Museum() {}\n virtual ~Museum() {}\n\n public:\n virtual ::natashapb::CODE init(const char* cfgpath);\n\n // getMainGameMod - get current main game module\n virtual GameMod* getMainGameMod(UserInfo* pUser, bool isComeInGame);\n#ifdef NATASHA_COUNTRTP\n public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::BASE_GAME, \"wildbomb\", 6);\n addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::FREE_GAME, \"wildbomb\", 6);\n }\n\n virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, \"wildbomb\", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }\n#endif // NATASHA_COUNTRTP\n\n#ifdef NATASHA_RUNINCPP\n public:\n void initConfig();\n#endif // NATASHA_RUNINCPP\n\n protected:\n NormalReels3X5 m_reels;\n Paytables3X5 m_paytables;\n BetList m_lstBet;\n ::natashapb::MuseumConfig m_cfg;\n}; // namespace natasha\n\n} // namespace natasha\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 15, 18, 21, 24, 27, 272], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 68, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "identifier", "text": "__NATASHA_MUSEUM_H__", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 28}}, {"id": 3, "type": "preproc_def", "text": "#define __NATASHA_MUSEUM_H__\n", "parent": 0, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 5, "type": "identifier", "text": "__NATASHA_MUSEUM_H__", "parent": 3, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 28}}, {"id": 6, "type": "preproc_include", "text": "#include <assert.h>\n", "parent": 0, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<assert.h>", "parent": 6, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 19}}, {"id": 9, "type": "preproc_include", "text": "#include <vector>\n", "parent": 0, "children": [10, 11], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<vector>", "parent": 9, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 17}}, {"id": 12, "type": "preproc_include", "text": "#include \"../include/game3x5.h\"\n", "parent": 0, "children": [13, 14], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 14, "type": "string_literal", "text": "\"../include/game3x5.h\"", "parent": 12, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 31}}, {"id": 15, "type": "preproc_include", "text": "#include \"../include/gamelogic.h\"\n", "parent": 0, "children": [16, 17], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 8}}, {"id": 17, "type": "string_literal", "text": "\"../include/gamelogic.h\"", "parent": 15, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 33}}, {"id": 18, "type": "preproc_include", "text": "#include \"basegame.h\"\n", "parent": 0, "children": [19, 20], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 8}}, {"id": 20, "type": "string_literal", "text": "\"basegame.h\"", "parent": 18, "children": [], "start_point": {"row": 7, "column": 9}, "end_point": {"row": 7, "column": 21}}, {"id": 21, "type": "preproc_include", "text": "#include \"freegame.h\"\n", "parent": 0, "children": [22, 23], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 22, "type": "#include", "text": "#include", "parent": 21, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 8}}, {"id": 23, "type": "string_literal", "text": "\"freegame.h\"", "parent": 21, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 21}}, {"id": 24, "type": "preproc_include", "text": "#include \"game_museum.h\"\n", "parent": 0, "children": [25, 26], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 25, "type": "#include", "text": "#include", "parent": 24, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 8}}, {"id": 26, "type": "string_literal", "text": "\"game_museum.h\"", "parent": 24, "children": [], "start_point": {"row": 9, "column": 9}, "end_point": {"row": 9, "column": 24}}, {"id": 27, "type": "function_definition", "text": "namespace natasha {\n\n// countRTP_museum - count rtp\nvoid countRTP_museum();\n\n// Museum\nclass Museum : public GameLogic {\n public:\n Museum() {}\n virtual ~Museum() {}\n\n public:\n virtual ::natashapb::CODE init(const char* cfgpath);\n\n // getMainGameMod - get current main game module\n virtual GameMod* getMainGameMod(UserInfo* pUser, bool isComeInGame);\n#ifdef NATASHA_COUNTRTP\n public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::BASE_GAME, \"wildbomb\", 6);\n addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::FREE_GAME, \"wildbomb\", 6);\n }\n\n virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, \"wildbomb\", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }\n#endif // NATASHA_COUNTRTP\n\n#ifdef NATASHA_RUNINCPP\n public:\n void initConfig();\n#endif // NATASHA_RUNINCPP\n\n protected:\n NormalReels3X5 m_reels;\n Paytables3X5 m_paytables;\n BetList m_lstBet;\n ::natashapb::MuseumConfig m_cfg;\n}; // namespace natasha\n\n}", "parent": 0, "children": [28, 29], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 66, "column": 1}}, {"id": 28, "type": "type_identifier", "text": "namespace", "parent": 27, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 9}}, {"id": 29, "type": "identifier", "text": "natasha", "parent": 27, "children": [], "start_point": {"row": 11, "column": 10}, "end_point": {"row": 11, "column": 17}}, {"id": 30, "type": "declaration", "text": "void countRTP_museum();", "parent": 27, "children": [31, 32], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 23}}, {"id": 31, "type": "primitive_type", "text": "void", "parent": 30, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 4}}, {"id": 32, "type": "function_declarator", "text": "countRTP_museum()", "parent": 30, "children": [33, 34], "start_point": {"row": 14, "column": 5}, "end_point": {"row": 14, "column": 22}}, {"id": 33, "type": "identifier", "text": "countRTP_museum", "parent": 32, "children": [], "start_point": {"row": 14, "column": 5}, "end_point": {"row": 14, "column": 20}}, {"id": 34, "type": "parameter_list", "text": "()", "parent": 32, "children": [], "start_point": {"row": 14, "column": 20}, "end_point": {"row": 14, "column": 22}}, {"id": 35, "type": "function_definition", "text": "class Museum : public GameLogic {\n public:\n Museum() {}\n virtual ~Museum() {}\n\n public:\n virtual ::natashapb::CODE init(const char* cfgpath);\n\n // getMainGameMod - get current main game module\n virtual GameMod* getMainGameMod(UserInfo* pUser, bool isComeInGame);\n#ifdef NATASHA_COUNTRTP\n public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::BASE_GAME, \"wildbomb\", 6);\n addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::FREE_GAME, \"wildbomb\", 6);\n }\n\n virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, \"wildbomb\", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }\n#endif // NATASHA_COUNTRTP\n\n#ifdef NATASHA_RUNINCPP\n public:\n void initConfig();\n#endif // NATASHA_RUNINCPP\n\n protected:\n NormalReels3X5 m_reels;\n Paytables3X5 m_paytables;\n BetList m_lstBet;\n ::natashapb::MuseumConfig m_cfg;\n}", "parent": 27, "children": [36, 38], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 64, "column": 1}}, {"id": 36, "type": "ERROR", "text": "Museum : public", "parent": 35, "children": [37], "start_point": {"row": 17, "column": 6}, "end_point": {"row": 17, "column": 21}}, {"id": 37, "type": "identifier", "text": "Museum", "parent": 36, "children": [], "start_point": {"row": 17, "column": 6}, "end_point": {"row": 17, "column": 12}}, {"id": 38, "type": "identifier", "text": "GameLogic", "parent": 35, "children": [], "start_point": {"row": 17, "column": 22}, "end_point": {"row": 17, "column": 31}}, {"id": 39, "type": "labeled_statement", "text": "public:\n Museum() {}", "parent": 35, "children": [40], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 19, "column": 13}}, {"id": 40, "type": "ERROR", "text": "Museum()", "parent": 39, "children": [41], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 10}}, {"id": 41, "type": "call_expression", "text": "Museum()", "parent": 40, "children": [42, 43], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 10}}, {"id": 42, "type": "identifier", "text": "Museum", "parent": 41, "children": [], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 8}}, {"id": 43, "type": "argument_list", "text": "()", "parent": 41, "children": [], "start_point": {"row": 19, "column": 8}, "end_point": {"row": 19, "column": 10}}, {"id": 44, "type": "function_definition", "text": "virtual ~Museum() {}", "parent": 35, "children": [45, 46, 48], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 22}}, {"id": 45, "type": "type_identifier", "text": "virtual", "parent": 44, "children": [], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 9}}, {"id": 46, "type": "ERROR", "text": "~", "parent": 44, "children": [47], "start_point": {"row": 20, "column": 10}, "end_point": {"row": 20, "column": 11}}, {"id": 47, "type": "~", "text": "~", "parent": 46, "children": [], "start_point": {"row": 20, "column": 10}, "end_point": {"row": 20, "column": 11}}, {"id": 48, "type": "function_declarator", "text": "Museum()", "parent": 44, "children": [49, 50], "start_point": {"row": 20, "column": 11}, "end_point": {"row": 20, "column": 19}}, {"id": 49, "type": "identifier", "text": "Museum", "parent": 48, "children": [], "start_point": {"row": 20, "column": 11}, "end_point": {"row": 20, "column": 17}}, {"id": 50, "type": "parameter_list", "text": "()", "parent": 48, "children": [], "start_point": {"row": 20, "column": 17}, "end_point": {"row": 20, "column": 19}}, {"id": 51, "type": "labeled_statement", "text": "public:\n virtual ::natashapb::CODE init(const char* cfgpath);", "parent": 35, "children": [52], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 23, "column": 54}}, {"id": 52, "type": "labeled_statement", "text": "virtual ::natashapb::CODE init(const char* cfgpath);", "parent": 51, "children": [53, 54], "start_point": {"row": 23, "column": 2}, "end_point": {"row": 23, "column": 54}}, {"id": 53, "type": "statement_identifier", "text": "virtual", "parent": 52, "children": [], "start_point": {"row": 23, "column": 2}, "end_point": {"row": 23, "column": 9}}, {"id": 54, "type": "labeled_statement", "text": "natashapb::CODE init(const char* cfgpath);", "parent": 52, "children": [55, 56], "start_point": {"row": 23, "column": 12}, "end_point": {"row": 23, "column": 54}}, {"id": 55, "type": "statement_identifier", "text": "natashapb", "parent": 54, "children": [], "start_point": {"row": 23, "column": 12}, "end_point": {"row": 23, "column": 21}}, {"id": 56, "type": "declaration", "text": "CODE init(const char* cfgpath);", "parent": 54, "children": [57, 58], "start_point": {"row": 23, "column": 23}, "end_point": {"row": 23, "column": 54}}, {"id": 57, "type": "type_identifier", "text": "CODE", "parent": 56, "children": [], "start_point": {"row": 23, "column": 23}, "end_point": {"row": 23, "column": 27}}, {"id": 58, "type": "function_declarator", "text": "init(const char* cfgpath)", "parent": 56, "children": [59, 60], "start_point": {"row": 23, "column": 28}, "end_point": {"row": 23, "column": 53}}, {"id": 59, "type": "identifier", "text": "init", "parent": 58, "children": [], "start_point": {"row": 23, "column": 28}, "end_point": {"row": 23, "column": 32}}, {"id": 60, "type": "parameter_list", "text": "(const char* cfgpath)", "parent": 58, "children": [61], "start_point": {"row": 23, "column": 32}, "end_point": {"row": 23, "column": 53}}, {"id": 61, "type": "parameter_declaration", "text": "const char* cfgpath", "parent": 60, "children": [62, 63], "start_point": {"row": 23, "column": 33}, "end_point": {"row": 23, "column": 52}}, {"id": 62, "type": "primitive_type", "text": "char", "parent": 61, "children": [], "start_point": {"row": 23, "column": 39}, "end_point": {"row": 23, "column": 43}}, {"id": 63, "type": "pointer_declarator", "text": "* cfgpath", "parent": 61, "children": [64, 65], "start_point": {"row": 23, "column": 43}, "end_point": {"row": 23, "column": 52}}, {"id": 64, "type": "*", "text": "*", "parent": 63, "children": [], "start_point": {"row": 23, "column": 43}, "end_point": {"row": 23, "column": 44}}, {"id": 65, "type": "identifier", "text": "cfgpath", "parent": 63, "children": [], "start_point": {"row": 23, "column": 45}, "end_point": {"row": 23, "column": 52}}, {"id": 66, "type": "declaration", "text": "virtual GameMod* getMainGameMod(UserInfo* pUser, bool isComeInGame);", "parent": 35, "children": [67, 68, 70], "start_point": {"row": 26, "column": 2}, "end_point": {"row": 26, "column": 70}}, {"id": 67, "type": "type_identifier", "text": "virtual", "parent": 66, "children": [], "start_point": {"row": 26, "column": 2}, "end_point": {"row": 26, "column": 9}}, {"id": 68, "type": "ERROR", "text": "GameMod", "parent": 66, "children": [69], "start_point": {"row": 26, "column": 10}, "end_point": {"row": 26, "column": 17}}, {"id": 69, "type": "identifier", "text": "GameMod", "parent": 68, "children": [], "start_point": {"row": 26, "column": 10}, "end_point": {"row": 26, "column": 17}}, {"id": 70, "type": "pointer_declarator", "text": "* getMainGameMod(UserInfo* pUser, bool isComeInGame)", "parent": 66, "children": [71, 72], "start_point": {"row": 26, "column": 17}, "end_point": {"row": 26, "column": 69}}, {"id": 71, "type": "*", "text": "*", "parent": 70, "children": [], "start_point": {"row": 26, "column": 17}, "end_point": {"row": 26, "column": 18}}, {"id": 72, "type": "function_declarator", "text": "getMainGameMod(UserInfo* pUser, bool isComeInGame)", "parent": 70, "children": [73, 74], "start_point": {"row": 26, "column": 19}, "end_point": {"row": 26, "column": 69}}, {"id": 73, "type": "identifier", "text": "getMainGameMod", "parent": 72, "children": [], "start_point": {"row": 26, "column": 19}, "end_point": {"row": 26, "column": 33}}, {"id": 74, "type": "parameter_list", "text": "(UserInfo* pUser, bool isComeInGame)", "parent": 72, "children": [75, 80], "start_point": {"row": 26, "column": 33}, "end_point": {"row": 26, "column": 69}}, {"id": 75, "type": "parameter_declaration", "text": "UserInfo* pUser", "parent": 74, "children": [76, 77], "start_point": {"row": 26, "column": 34}, "end_point": {"row": 26, "column": 49}}, {"id": 76, "type": "type_identifier", "text": "UserInfo", "parent": 75, "children": [], "start_point": {"row": 26, "column": 34}, "end_point": {"row": 26, "column": 42}}, {"id": 77, "type": "pointer_declarator", "text": "* pUser", "parent": 75, "children": [78, 79], "start_point": {"row": 26, "column": 42}, "end_point": {"row": 26, "column": 49}}, {"id": 78, "type": "*", "text": "*", "parent": 77, "children": [], "start_point": {"row": 26, "column": 42}, "end_point": {"row": 26, "column": 43}}, {"id": 79, "type": "identifier", "text": "pUser", "parent": 77, "children": [], "start_point": {"row": 26, "column": 44}, "end_point": {"row": 26, "column": 49}}, {"id": 80, "type": "parameter_declaration", "text": "bool isComeInGame", "parent": 74, "children": [81, 82], "start_point": {"row": 26, "column": 51}, "end_point": {"row": 26, "column": 68}}, {"id": 81, "type": "primitive_type", "text": "bool", "parent": 80, "children": [], "start_point": {"row": 26, "column": 51}, "end_point": {"row": 26, "column": 55}}, {"id": 82, "type": "identifier", "text": "isComeInGame", "parent": 80, "children": [], "start_point": {"row": 26, "column": 56}, "end_point": {"row": 26, "column": 68}}, {"id": 83, "type": "preproc_ifdef", "text": "#ifdef NATASHA_COUNTRTP\n public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::BASE_GAME, \"wildbomb\", 6);\n addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::FREE_GAME, \"wildbomb\", 6);\n }\n\n virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, \"wildbomb\", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }\n#endif", "parent": 35, "children": [84, 85, 86, 104, 114, 124, 134, 246], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 52, "column": 6}}, {"id": 84, "type": "#ifdef", "text": "#ifdef", "parent": 83, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 6}}, {"id": 85, "type": "identifier", "text": "NATASHA_COUNTRTP", "parent": 83, "children": [], "start_point": {"row": 27, "column": 7}, "end_point": {"row": 27, "column": 23}}, {"id": 86, "type": "labeled_statement", "text": "public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);", "parent": 83, "children": [87], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 30, "column": 80}}, {"id": 87, "type": "declaration", "text": "virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);", "parent": 86, "children": [88, 89, 94], "start_point": {"row": 29, "column": 2}, "end_point": {"row": 30, "column": 80}}, {"id": 88, "type": "type_identifier", "text": "virtual", "parent": 87, "children": [], "start_point": {"row": 29, "column": 2}, "end_point": {"row": 29, "column": 9}}, {"id": 89, "type": "ERROR", "text": "void onInitRTP() {", "parent": 87, "children": [90, 91], "start_point": {"row": 29, "column": 10}, "end_point": {"row": 29, "column": 28}}, {"id": 90, "type": "identifier", "text": "void", "parent": 89, "children": [], "start_point": {"row": 29, "column": 10}, "end_point": {"row": 29, "column": 14}}, {"id": 91, "type": "function_declarator", "text": "onInitRTP()", "parent": 89, "children": [92, 93], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 26}}, {"id": 92, "type": "identifier", "text": "onInitRTP", "parent": 91, "children": [], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 24}}, {"id": 93, "type": "parameter_list", "text": "()", "parent": 91, "children": [], "start_point": {"row": 29, "column": 24}, "end_point": {"row": 29, "column": 26}}, {"id": 94, "type": "function_declarator", "text": "addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols)", "parent": 87, "children": [95, 96], "start_point": {"row": 30, "column": 4}, "end_point": {"row": 30, "column": 79}}, {"id": 95, "type": "identifier", "text": "addRTPModule", "parent": 94, "children": [], "start_point": {"row": 30, "column": 4}, "end_point": {"row": 30, "column": 16}}, {"id": 96, "type": "parameter_list", "text": "(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols)", "parent": 94, "children": [97, 100, 102], "start_point": {"row": 30, "column": 16}, "end_point": {"row": 30, "column": 79}}, {"id": 97, "type": "parameter_declaration", "text": "natashapb::BASE_GAME", "parent": 96, "children": [98, 99], "start_point": {"row": 30, "column": 19}, "end_point": {"row": 30, "column": 39}}, {"id": 98, "type": "type_identifier", "text": "natashapb", "parent": 97, "children": [], "start_point": {"row": 30, "column": 19}, "end_point": {"row": 30, "column": 28}}, {"id": 99, "type": "identifier", "text": "BASE_GAME", "parent": 97, "children": [], "start_point": {"row": 30, "column": 30}, "end_point": {"row": 30, "column": 39}}, {"id": 100, "type": "parameter_declaration", "text": "MeseumMaxPayoutNums", "parent": 96, "children": [101], "start_point": {"row": 30, "column": 41}, "end_point": {"row": 30, "column": 60}}, {"id": 101, "type": "type_identifier", "text": "MeseumMaxPayoutNums", "parent": 100, "children": [], "start_point": {"row": 30, "column": 41}, "end_point": {"row": 30, "column": 60}}, {"id": 102, "type": "parameter_declaration", "text": "MeseumMaxSymbols", "parent": 96, "children": [103], "start_point": {"row": 30, "column": 62}, "end_point": {"row": 30, "column": 78}}, {"id": 103, "type": "type_identifier", "text": "MeseumMaxSymbols", "parent": 102, "children": [], "start_point": {"row": 30, "column": 62}, "end_point": {"row": 30, "column": 78}}, {"id": 104, "type": "labeled_statement", "text": "addRTPModuleBonus(::natashapb::BASE_GAME, \"wildbomb\", 6);", "parent": 83, "children": [105, 106, 107], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 61}}, {"id": 105, "type": "statement_identifier", "text": "addRTPModuleBonus", "parent": 104, "children": [], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 21}}, {"id": 106, "type": "ERROR", "text": "(:", "parent": 104, "children": [], "start_point": {"row": 31, "column": 21}, "end_point": {"row": 31, "column": 23}}, {"id": 107, "type": "labeled_statement", "text": "natashapb::BASE_GAME, \"wildbomb\", 6);", "parent": 104, "children": [108], "start_point": {"row": 31, "column": 24}, "end_point": {"row": 31, "column": 61}}, {"id": 108, "type": "statement_identifier", "text": "natashapb", "parent": 107, "children": [], "start_point": {"row": 31, "column": 24}, "end_point": {"row": 31, "column": 33}}, {"id": 109, "type": "comma_expression", "text": "BASE_GAME, \"wildbomb\", 6", "parent": 107, "children": [110, 111], "start_point": {"row": 31, "column": 35}, "end_point": {"row": 31, "column": 59}}, {"id": 110, "type": "identifier", "text": "BASE_GAME", "parent": 109, "children": [], "start_point": {"row": 31, "column": 35}, "end_point": {"row": 31, "column": 44}}, {"id": 111, "type": "comma_expression", "text": "\"wildbomb\", 6", "parent": 109, "children": [112, 113], "start_point": {"row": 31, "column": 46}, "end_point": {"row": 31, "column": 59}}, {"id": 112, "type": "string_literal", "text": "\"wildbomb\"", "parent": 111, "children": [], "start_point": {"row": 31, "column": 46}, "end_point": {"row": 31, "column": 56}}, {"id": 113, "type": "number_literal", "text": "6", "parent": 111, "children": [], "start_point": {"row": 31, "column": 58}, "end_point": {"row": 31, "column": 59}}, {"id": 114, "type": "labeled_statement", "text": "addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);", "parent": 83, "children": [115, 116, 117], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 32, "column": 80}}, {"id": 115, "type": "statement_identifier", "text": "addRTPModule", "parent": 114, "children": [], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 32, "column": 16}}, {"id": 116, "type": "ERROR", "text": "(:", "parent": 114, "children": [], "start_point": {"row": 32, "column": 16}, "end_point": {"row": 32, "column": 18}}, {"id": 117, "type": "labeled_statement", "text": "natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);", "parent": 114, "children": [118], "start_point": {"row": 32, "column": 19}, "end_point": {"row": 32, "column": 80}}, {"id": 118, "type": "statement_identifier", "text": "natashapb", "parent": 117, "children": [], "start_point": {"row": 32, "column": 19}, "end_point": {"row": 32, "column": 28}}, {"id": 119, "type": "comma_expression", "text": "FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols", "parent": 117, "children": [120, 121], "start_point": {"row": 32, "column": 30}, "end_point": {"row": 32, "column": 78}}, {"id": 120, "type": "identifier", "text": "FREE_GAME", "parent": 119, "children": [], "start_point": {"row": 32, "column": 30}, "end_point": {"row": 32, "column": 39}}, {"id": 121, "type": "comma_expression", "text": "MeseumMaxPayoutNums, MeseumMaxSymbols", "parent": 119, "children": [122, 123], "start_point": {"row": 32, "column": 41}, "end_point": {"row": 32, "column": 78}}, {"id": 122, "type": "identifier", "text": "MeseumMaxPayoutNums", "parent": 121, "children": [], "start_point": {"row": 32, "column": 41}, "end_point": {"row": 32, "column": 60}}, {"id": 123, "type": "identifier", "text": "MeseumMaxSymbols", "parent": 121, "children": [], "start_point": {"row": 32, "column": 62}, "end_point": {"row": 32, "column": 78}}, {"id": 124, "type": "labeled_statement", "text": "addRTPModuleBonus(::natashapb::FREE_GAME, \"wildbomb\", 6);", "parent": 83, "children": [125, 126, 127], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 61}}, {"id": 125, "type": "statement_identifier", "text": "addRTPModuleBonus", "parent": 124, "children": [], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 21}}, {"id": 126, "type": "ERROR", "text": "(:", "parent": 124, "children": [], "start_point": {"row": 33, "column": 21}, "end_point": {"row": 33, "column": 23}}, {"id": 127, "type": "labeled_statement", "text": "natashapb::FREE_GAME, \"wildbomb\", 6);", "parent": 124, "children": [128], "start_point": {"row": 33, "column": 24}, "end_point": {"row": 33, "column": 61}}, {"id": 128, "type": "statement_identifier", "text": "natashapb", "parent": 127, "children": [], "start_point": {"row": 33, "column": 24}, "end_point": {"row": 33, "column": 33}}, {"id": 129, "type": "comma_expression", "text": "FREE_GAME, \"wildbomb\", 6", "parent": 127, "children": [130, 131], "start_point": {"row": 33, "column": 35}, "end_point": {"row": 33, "column": 59}}, {"id": 130, "type": "identifier", "text": "FREE_GAME", "parent": 129, "children": [], "start_point": {"row": 33, "column": 35}, "end_point": {"row": 33, "column": 44}}, {"id": 131, "type": "comma_expression", "text": "\"wildbomb\", 6", "parent": 129, "children": [132, 133], "start_point": {"row": 33, "column": 46}, "end_point": {"row": 33, "column": 59}}, {"id": 132, "type": "string_literal", "text": "\"wildbomb\"", "parent": 131, "children": [], "start_point": {"row": 33, "column": 46}, "end_point": {"row": 33, "column": 56}}, {"id": 133, "type": "number_literal", "text": "6", "parent": 131, "children": [], "start_point": {"row": 33, "column": 58}, "end_point": {"row": 33, "column": 59}}, {"id": 134, "type": "function_definition", "text": "virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, \"wildbomb\", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }", "parent": 83, "children": [135, 136, 138], "start_point": {"row": 36, "column": 2}, "end_point": {"row": 51, "column": 3}}, {"id": 135, "type": "type_identifier", "text": "virtual", "parent": 134, "children": [], "start_point": {"row": 36, "column": 2}, "end_point": {"row": 36, "column": 9}}, {"id": 136, "type": "ERROR", "text": "void", "parent": 134, "children": [137], "start_point": {"row": 36, "column": 10}, "end_point": {"row": 36, "column": 14}}, {"id": 137, "type": "identifier", "text": "void", "parent": 136, "children": [], "start_point": {"row": 36, "column": 10}, "end_point": {"row": 36, "column": 14}}, {"id": 138, "type": "function_declarator", "text": "onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser)", "parent": 134, "children": [139, 140], "start_point": {"row": 36, "column": 15}, "end_point": {"row": 39, "column": 75}}, {"id": 139, "type": "identifier", "text": "onRTPAddPayoutGRI", "parent": 138, "children": [], "start_point": {"row": 36, "column": 15}, "end_point": {"row": 36, "column": 32}}, {"id": 140, "type": "parameter_list", "text": "(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser)", "parent": 138, "children": [141, 146, 151, 156], "start_point": {"row": 36, "column": 32}, "end_point": {"row": 39, "column": 75}}, {"id": 141, "type": "parameter_declaration", "text": "natashapb::GAMEMODTYPE module", "parent": 140, "children": [142, 143, 145], "start_point": {"row": 36, "column": 35}, "end_point": {"row": 36, "column": 64}}, {"id": 142, "type": "type_identifier", "text": "natashapb", "parent": 141, "children": [], "start_point": {"row": 36, "column": 35}, "end_point": {"row": 36, "column": 44}}, {"id": 143, "type": "ERROR", "text": "::GAMEMODTYPE", "parent": 141, "children": [144], "start_point": {"row": 36, "column": 44}, "end_point": {"row": 36, "column": 57}}, {"id": 144, "type": "identifier", "text": "GAMEMODTYPE", "parent": 143, "children": [], "start_point": {"row": 36, "column": 46}, "end_point": {"row": 36, "column": 57}}, {"id": 145, "type": "identifier", "text": "module", "parent": 141, "children": [], "start_point": {"row": 36, "column": 58}, "end_point": {"row": 36, "column": 64}}, {"id": 146, "type": "parameter_declaration", "text": "const ::natashapb::SpinResult& spinret", "parent": 140, "children": [147, 148, 150], "start_point": {"row": 37, "column": 33}, "end_point": {"row": 37, "column": 71}}, {"id": 147, "type": "type_identifier", "text": "natashapb", "parent": 146, "children": [], "start_point": {"row": 37, "column": 41}, "end_point": {"row": 37, "column": 50}}, {"id": 148, "type": "ERROR", "text": "::SpinResult&", "parent": 146, "children": [149], "start_point": {"row": 37, "column": 50}, "end_point": {"row": 37, "column": 63}}, {"id": 149, "type": "identifier", "text": "SpinResult", "parent": 148, "children": [], "start_point": {"row": 37, "column": 52}, "end_point": {"row": 37, "column": 62}}, {"id": 150, "type": "identifier", "text": "spinret", "parent": 146, "children": [], "start_point": {"row": 37, "column": 64}, "end_point": {"row": 37, "column": 71}}, {"id": 151, "type": "parameter_declaration", "text": "const ::natashapb::GameResultInfo& gri", "parent": 140, "children": [152, 153, 155], "start_point": {"row": 38, "column": 33}, "end_point": {"row": 38, "column": 71}}, {"id": 152, "type": "type_identifier", "text": "natashapb", "parent": 151, "children": [], "start_point": {"row": 38, "column": 41}, "end_point": {"row": 38, "column": 50}}, {"id": 153, "type": "ERROR", "text": "::GameResultInfo&", "parent": 151, "children": [154], "start_point": {"row": 38, "column": 50}, "end_point": {"row": 38, "column": 67}}, {"id": 154, "type": "identifier", "text": "GameResultInfo", "parent": 153, "children": [], "start_point": {"row": 38, "column": 52}, "end_point": {"row": 38, "column": 66}}, {"id": 155, "type": "identifier", "text": "gri", "parent": 151, "children": [], "start_point": {"row": 38, "column": 68}, "end_point": {"row": 38, "column": 71}}, {"id": 156, "type": "parameter_declaration", "text": "const ::natashapb::UserGameModInfo* pUser", "parent": 140, "children": [157, 158, 160], "start_point": {"row": 39, "column": 33}, "end_point": {"row": 39, "column": 74}}, {"id": 157, "type": "type_identifier", "text": "natashapb", "parent": 156, "children": [], "start_point": {"row": 39, "column": 41}, "end_point": {"row": 39, "column": 50}}, {"id": 158, "type": "ERROR", "text": "::UserGameModInfo", "parent": 156, "children": [159], "start_point": {"row": 39, "column": 50}, "end_point": {"row": 39, "column": 67}}, {"id": 159, "type": "identifier", "text": "UserGameModInfo", "parent": 158, "children": [], "start_point": {"row": 39, "column": 52}, "end_point": {"row": 39, "column": 67}}, {"id": 160, "type": "pointer_declarator", "text": "* pUser", "parent": 156, "children": [161, 162], "start_point": {"row": 39, "column": 67}, "end_point": {"row": 39, "column": 74}}, {"id": 161, "type": "*", "text": "*", "parent": 160, "children": [], "start_point": {"row": 39, "column": 67}, "end_point": {"row": 39, "column": 68}}, {"id": 162, "type": "identifier", "text": "pUser", "parent": 160, "children": [], "start_point": {"row": 39, "column": 69}, "end_point": {"row": 39, "column": 74}}, {"id": 163, "type": "if_statement", "text": "if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, \"wildbomb\", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }", "parent": 134, "children": [164, 217], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 50, "column": 5}}, {"id": 164, "type": "parenthesized_expression", "text": "(gri.typegameresult() == ::natashapb::SPECIAL)", "parent": 163, "children": [165, 173], "start_point": {"row": 40, "column": 7}, "end_point": {"row": 40, "column": 53}}, {"id": 165, "type": "binary_expression", "text": "gri.typegameresult() == ::natashapb", "parent": 164, "children": [166, 171, 172], "start_point": {"row": 40, "column": 8}, "end_point": {"row": 40, "column": 43}}, {"id": 166, "type": "call_expression", "text": "gri.typegameresult()", "parent": 165, "children": [167, 170], "start_point": {"row": 40, "column": 8}, "end_point": {"row": 40, "column": 28}}, {"id": 167, "type": "field_expression", "text": "gri.typegameresult", "parent": 166, "children": [168, 169], "start_point": {"row": 40, "column": 8}, "end_point": {"row": 40, "column": 26}}, {"id": 168, "type": "identifier", "text": "gri", "parent": 167, "children": [], "start_point": {"row": 40, "column": 8}, "end_point": {"row": 40, "column": 11}}, {"id": 169, "type": "field_identifier", "text": "typegameresult", "parent": 167, "children": [], "start_point": {"row": 40, "column": 12}, "end_point": {"row": 40, "column": 26}}, {"id": 170, "type": "argument_list", "text": "()", "parent": 166, "children": [], "start_point": {"row": 40, "column": 26}, "end_point": {"row": 40, "column": 28}}, {"id": 171, "type": "==", "text": "==", "parent": 165, "children": [], "start_point": {"row": 40, "column": 29}, "end_point": {"row": 40, "column": 31}}, {"id": 172, "type": "identifier", "text": "natashapb", "parent": 165, "children": [], "start_point": {"row": 40, "column": 34}, "end_point": {"row": 40, "column": 43}}, {"id": 173, "type": "ERROR", "text": "::SPECIAL", "parent": 164, "children": [174], "start_point": {"row": 40, "column": 43}, "end_point": {"row": 40, "column": 52}}, {"id": 174, "type": "identifier", "text": "SPECIAL", "parent": 173, "children": [], "start_point": {"row": 40, "column": 45}, "end_point": {"row": 40, "column": 52}}, {"id": 175, "type": "declaration", "text": "auto turnnums = pUser->cascadinginfo().turnnums();", "parent": 163, "children": [176, 178, 179], "start_point": {"row": 41, "column": 6}, "end_point": {"row": 41, "column": 56}}, {"id": 176, "type": "storage_class_specifier", "text": "auto", "parent": 175, "children": [177], "start_point": {"row": 41, "column": 6}, "end_point": {"row": 41, "column": 10}}, {"id": 177, "type": "auto", "text": "auto", "parent": 176, "children": [], "start_point": {"row": 41, "column": 6}, "end_point": {"row": 41, "column": 10}}, {"id": 178, "type": "type_identifier", "text": "turnnums", "parent": 175, "children": [], "start_point": {"row": 41, "column": 11}, "end_point": {"row": 41, "column": 19}}, {"id": 179, "type": "init_declarator", "text": " = pUser->cascadinginfo().turnnums()", "parent": 175, "children": [180, 181, 182], "start_point": {"row": 41, "column": 19}, "end_point": {"row": 41, "column": 55}}, {"id": 180, "type": "identifier", "text": "", "parent": 179, "children": [], "start_point": {"row": 41, "column": 19}, "end_point": {"row": 41, "column": 19}}, {"id": 181, "type": "=", "text": "=", "parent": 179, "children": [], "start_point": {"row": 41, "column": 20}, "end_point": {"row": 41, "column": 21}}, {"id": 182, "type": "call_expression", "text": "pUser->cascadinginfo().turnnums()", "parent": 179, "children": [183, 190], "start_point": {"row": 41, "column": 22}, "end_point": {"row": 41, "column": 55}}, {"id": 183, "type": "field_expression", "text": "pUser->cascadinginfo().turnnums", "parent": 182, "children": [184, 189], "start_point": {"row": 41, "column": 22}, "end_point": {"row": 41, "column": 53}}, {"id": 184, "type": "call_expression", "text": "pUser->cascadinginfo()", "parent": 183, "children": [185, 188], "start_point": {"row": 41, "column": 22}, "end_point": {"row": 41, "column": 44}}, {"id": 185, "type": "field_expression", "text": "pUser->cascadinginfo", "parent": 184, "children": [186, 187], "start_point": {"row": 41, "column": 22}, "end_point": {"row": 41, "column": 42}}, {"id": 186, "type": "identifier", "text": "pUser", "parent": 185, "children": [], "start_point": {"row": 41, "column": 22}, "end_point": {"row": 41, "column": 27}}, {"id": 187, "type": "field_identifier", "text": "cascadinginfo", "parent": 185, "children": [], "start_point": {"row": 41, "column": 29}, "end_point": {"row": 41, "column": 42}}, {"id": 188, "type": "argument_list", "text": "()", "parent": 184, "children": [], "start_point": {"row": 41, "column": 42}, "end_point": {"row": 41, "column": 44}}, {"id": 189, "type": "field_identifier", "text": "turnnums", "parent": 183, "children": [], "start_point": {"row": 41, "column": 45}, "end_point": {"row": 41, "column": 53}}, {"id": 190, "type": "argument_list", "text": "()", "parent": 182, "children": [], "start_point": {"row": 41, "column": 53}, "end_point": {"row": 41, "column": 55}}, {"id": 191, "type": "if_statement", "text": "if (turnnums > 6) {\n turnnums = 6;\n }", "parent": 163, "children": [192], "start_point": {"row": 42, "column": 6}, "end_point": {"row": 44, "column": 7}}, {"id": 192, "type": "parenthesized_expression", "text": "(turnnums > 6)", "parent": 191, "children": [193], "start_point": {"row": 42, "column": 9}, "end_point": {"row": 42, "column": 23}}, {"id": 193, "type": "binary_expression", "text": "turnnums > 6", "parent": 192, "children": [194, 195, 196], "start_point": {"row": 42, "column": 10}, "end_point": {"row": 42, "column": 22}}, {"id": 194, "type": "identifier", "text": "turnnums", "parent": 193, "children": [], "start_point": {"row": 42, "column": 10}, "end_point": {"row": 42, "column": 18}}, {"id": 195, "type": ">", "text": ">", "parent": 193, "children": [], "start_point": {"row": 42, "column": 19}, "end_point": {"row": 42, "column": 20}}, {"id": 196, "type": "number_literal", "text": "6", "parent": 193, "children": [], "start_point": {"row": 42, "column": 21}, "end_point": {"row": 42, "column": 22}}, {"id": 197, "type": "assignment_expression", "text": "turnnums = 6", "parent": 191, "children": [198, 199, 200], "start_point": {"row": 43, "column": 8}, "end_point": {"row": 43, "column": 20}}, {"id": 198, "type": "identifier", "text": "turnnums", "parent": 197, "children": [], "start_point": {"row": 43, "column": 8}, "end_point": {"row": 43, "column": 16}}, {"id": 199, "type": "=", "text": "=", "parent": 197, "children": [], "start_point": {"row": 43, "column": 17}, "end_point": {"row": 43, "column": 18}}, {"id": 200, "type": "number_literal", "text": "6", "parent": 197, "children": [], "start_point": {"row": 43, "column": 19}, "end_point": {"row": 43, "column": 20}}, {"id": 201, "type": "call_expression", "text": "m_rtp.addBonusPayout(module, \"wildbomb\", turnnums - 1, gri.realwin())", "parent": 163, "children": [202, 205], "start_point": {"row": 46, "column": 6}, "end_point": {"row": 46, "column": 75}}, {"id": 202, "type": "field_expression", "text": "m_rtp.addBonusPayout", "parent": 201, "children": [203, 204], "start_point": {"row": 46, "column": 6}, "end_point": {"row": 46, "column": 26}}, {"id": 203, "type": "identifier", "text": "m_rtp", "parent": 202, "children": [], "start_point": {"row": 46, "column": 6}, "end_point": {"row": 46, "column": 11}}, {"id": 204, "type": "field_identifier", "text": "addBonusPayout", "parent": 202, "children": [], "start_point": {"row": 46, "column": 12}, "end_point": {"row": 46, "column": 26}}, {"id": 205, "type": "argument_list", "text": "(module, \"wildbomb\", turnnums - 1, gri.realwin())", "parent": 201, "children": [206, 207, 208, 212], "start_point": {"row": 46, "column": 26}, "end_point": {"row": 46, "column": 75}}, {"id": 206, "type": "identifier", "text": "module", "parent": 205, "children": [], "start_point": {"row": 46, "column": 27}, "end_point": {"row": 46, "column": 33}}, {"id": 207, "type": "string_literal", "text": "\"wildbomb\"", "parent": 205, "children": [], "start_point": {"row": 46, "column": 35}, "end_point": {"row": 46, "column": 45}}, {"id": 208, "type": "binary_expression", "text": "turnnums - 1", "parent": 205, "children": [209, 210, 211], "start_point": {"row": 46, "column": 47}, "end_point": {"row": 46, "column": 59}}, {"id": 209, "type": "identifier", "text": "turnnums", "parent": 208, "children": [], "start_point": {"row": 46, "column": 47}, "end_point": {"row": 46, "column": 55}}, {"id": 210, "type": "-", "text": "-", "parent": 208, "children": [], "start_point": {"row": 46, "column": 56}, "end_point": {"row": 46, "column": 57}}, {"id": 211, "type": "number_literal", "text": "1", "parent": 208, "children": [], "start_point": {"row": 46, "column": 58}, "end_point": {"row": 46, "column": 59}}, {"id": 212, "type": "call_expression", "text": "gri.realwin()", "parent": 205, "children": [213, 216], "start_point": {"row": 46, "column": 61}, "end_point": {"row": 46, "column": 74}}, {"id": 213, "type": "field_expression", "text": "gri.realwin", "parent": 212, "children": [214, 215], "start_point": {"row": 46, "column": 61}, "end_point": {"row": 46, "column": 72}}, {"id": 214, "type": "identifier", "text": "gri", "parent": 213, "children": [], "start_point": {"row": 46, "column": 61}, "end_point": {"row": 46, "column": 64}}, {"id": 215, "type": "field_identifier", "text": "realwin", "parent": 213, "children": [], "start_point": {"row": 46, "column": 65}, "end_point": {"row": 46, "column": 72}}, {"id": 216, "type": "argument_list", "text": "()", "parent": 212, "children": [], "start_point": {"row": 46, "column": 72}, "end_point": {"row": 46, "column": 74}}, {"id": 217, "type": "else_clause", "text": "else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }", "parent": 163, "children": [], "start_point": {"row": 47, "column": 6}, "end_point": {"row": 50, "column": 5}}, {"id": 218, "type": "call_expression", "text": "m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul())", "parent": 217, "children": [219, 222], "start_point": {"row": 48, "column": 6}, "end_point": {"row": 49, "column": 63}}, {"id": 219, "type": "field_expression", "text": "m_rtp.addSymbolPayout", "parent": 218, "children": [220, 221], "start_point": {"row": 48, "column": 6}, "end_point": {"row": 48, "column": 27}}, {"id": 220, "type": "identifier", "text": "m_rtp", "parent": 219, "children": [], "start_point": {"row": 48, "column": 6}, "end_point": {"row": 48, "column": 11}}, {"id": 221, "type": "field_identifier", "text": "addSymbolPayout", "parent": 219, "children": [], "start_point": {"row": 48, "column": 12}, "end_point": {"row": 48, "column": 27}}, {"id": 222, "type": "argument_list", "text": "(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul())", "parent": 218, "children": [223, 224, 229, 234], "start_point": {"row": 48, "column": 27}, "end_point": {"row": 49, "column": 63}}, {"id": 223, "type": "identifier", "text": "module", "parent": 222, "children": [], "start_point": {"row": 48, "column": 28}, "end_point": {"row": 48, "column": 34}}, {"id": 224, "type": "call_expression", "text": "gri.symbol()", "parent": 222, "children": [225, 228], "start_point": {"row": 48, "column": 36}, "end_point": {"row": 48, "column": 48}}, {"id": 225, "type": "field_expression", "text": "gri.symbol", "parent": 224, "children": [226, 227], "start_point": {"row": 48, "column": 36}, "end_point": {"row": 48, "column": 46}}, {"id": 226, "type": "identifier", "text": "gri", "parent": 225, "children": [], "start_point": {"row": 48, "column": 36}, "end_point": {"row": 48, "column": 39}}, {"id": 227, "type": "field_identifier", "text": "symbol", "parent": 225, "children": [], "start_point": {"row": 48, "column": 40}, "end_point": {"row": 48, "column": 46}}, {"id": 228, "type": "argument_list", "text": "()", "parent": 224, "children": [], "start_point": {"row": 48, "column": 46}, "end_point": {"row": 48, "column": 48}}, {"id": 229, "type": "call_expression", "text": "gri.lstsymbol_size()", "parent": 222, "children": [230, 233], "start_point": {"row": 48, "column": 50}, "end_point": {"row": 48, "column": 70}}, {"id": 230, "type": "field_expression", "text": "gri.lstsymbol_size", "parent": 229, "children": [231, 232], "start_point": {"row": 48, "column": 50}, "end_point": {"row": 48, "column": 68}}, {"id": 231, "type": "identifier", "text": "gri", "parent": 230, "children": [], "start_point": {"row": 48, "column": 50}, "end_point": {"row": 48, "column": 53}}, {"id": 232, "type": "field_identifier", "text": "lstsymbol_size", "parent": 230, "children": [], "start_point": {"row": 48, "column": 54}, "end_point": {"row": 48, "column": 68}}, {"id": 233, "type": "argument_list", "text": "()", "parent": 229, "children": [], "start_point": {"row": 48, "column": 68}, "end_point": {"row": 48, "column": 70}}, {"id": 234, "type": "binary_expression", "text": "gri.realwin() * spinret.awardmul()", "parent": 222, "children": [235, 240, 241], "start_point": {"row": 49, "column": 28}, "end_point": {"row": 49, "column": 62}}, {"id": 235, "type": "call_expression", "text": "gri.realwin()", "parent": 234, "children": [236, 239], "start_point": {"row": 49, "column": 28}, "end_point": {"row": 49, "column": 41}}, {"id": 236, "type": "field_expression", "text": "gri.realwin", "parent": 235, "children": [237, 238], "start_point": {"row": 49, "column": 28}, "end_point": {"row": 49, "column": 39}}, {"id": 237, "type": "identifier", "text": "gri", "parent": 236, "children": [], "start_point": {"row": 49, "column": 28}, "end_point": {"row": 49, "column": 31}}, {"id": 238, "type": "field_identifier", "text": "realwin", "parent": 236, "children": [], "start_point": {"row": 49, "column": 32}, "end_point": {"row": 49, "column": 39}}, {"id": 239, "type": "argument_list", "text": "()", "parent": 235, "children": [], "start_point": {"row": 49, "column": 39}, "end_point": {"row": 49, "column": 41}}, {"id": 240, "type": "*", "text": "*", "parent": 234, "children": [], "start_point": {"row": 49, "column": 42}, "end_point": {"row": 49, "column": 43}}, {"id": 241, "type": "call_expression", "text": "spinret.awardmul()", "parent": 234, "children": [242, 245], "start_point": {"row": 49, "column": 44}, "end_point": {"row": 49, "column": 62}}, {"id": 242, "type": "field_expression", "text": "spinret.awardmul", "parent": 241, "children": [243, 244], "start_point": {"row": 49, "column": 44}, "end_point": {"row": 49, "column": 60}}, {"id": 243, "type": "identifier", "text": "spinret", "parent": 242, "children": [], "start_point": {"row": 49, "column": 44}, "end_point": {"row": 49, "column": 51}}, {"id": 244, "type": "field_identifier", "text": "awardmul", "parent": 242, "children": [], "start_point": {"row": 49, "column": 52}, "end_point": {"row": 49, "column": 60}}, {"id": 245, "type": "argument_list", "text": "()", "parent": 241, "children": [], "start_point": {"row": 49, "column": 60}, "end_point": {"row": 49, "column": 62}}, {"id": 246, "type": "#endif", "text": "#endif", "parent": 83, "children": [], "start_point": {"row": 52, "column": 0}, "end_point": {"row": 52, "column": 6}}, {"id": 247, "type": "preproc_ifdef", "text": "#ifdef NATASHA_RUNINCPP\n public:\n void initConfig();\n#endif", "parent": 35, "children": [248, 249, 250, 256], "start_point": {"row": 54, "column": 0}, "end_point": {"row": 57, "column": 6}}, {"id": 248, "type": "#ifdef", "text": "#ifdef", "parent": 247, "children": [], "start_point": {"row": 54, "column": 0}, "end_point": {"row": 54, "column": 6}}, {"id": 249, "type": "identifier", "text": "NATASHA_RUNINCPP", "parent": 247, "children": [], "start_point": {"row": 54, "column": 7}, "end_point": {"row": 54, "column": 23}}, {"id": 250, "type": "labeled_statement", "text": "public:\n void initConfig();", "parent": 247, "children": [251], "start_point": {"row": 55, "column": 1}, "end_point": {"row": 56, "column": 20}}, {"id": 251, "type": "declaration", "text": "void initConfig();", "parent": 250, "children": [252, 253], "start_point": {"row": 56, "column": 2}, "end_point": {"row": 56, "column": 20}}, {"id": 252, "type": "primitive_type", "text": "void", "parent": 251, "children": [], "start_point": {"row": 56, "column": 2}, "end_point": {"row": 56, "column": 6}}, {"id": 253, "type": "function_declarator", "text": "initConfig()", "parent": 251, "children": [254, 255], "start_point": {"row": 56, "column": 7}, "end_point": {"row": 56, "column": 19}}, {"id": 254, "type": "identifier", "text": "initConfig", "parent": 253, "children": [], "start_point": {"row": 56, "column": 7}, "end_point": {"row": 56, "column": 17}}, {"id": 255, "type": "parameter_list", "text": "()", "parent": 253, "children": [], "start_point": {"row": 56, "column": 17}, "end_point": {"row": 56, "column": 19}}, {"id": 256, "type": "#endif", "text": "#endif", "parent": 247, "children": [], "start_point": {"row": 57, "column": 0}, "end_point": {"row": 57, "column": 6}}, {"id": 257, "type": "labeled_statement", "text": "protected:\n NormalReels3X5 m_reels;", "parent": 35, "children": [258], "start_point": {"row": 59, "column": 1}, "end_point": {"row": 60, "column": 25}}, {"id": 258, "type": "declaration", "text": "NormalReels3X5 m_reels;", "parent": 257, "children": [259, 260], "start_point": {"row": 60, "column": 2}, "end_point": {"row": 60, "column": 25}}, {"id": 259, "type": "type_identifier", "text": "NormalReels3X5", "parent": 258, "children": [], "start_point": {"row": 60, "column": 2}, "end_point": {"row": 60, "column": 16}}, {"id": 260, "type": "identifier", "text": "m_reels", "parent": 258, "children": [], "start_point": {"row": 60, "column": 17}, "end_point": {"row": 60, "column": 24}}, {"id": 261, "type": "declaration", "text": "Paytables3X5 m_paytables;", "parent": 35, "children": [262, 263], "start_point": {"row": 61, "column": 2}, "end_point": {"row": 61, "column": 27}}, {"id": 262, "type": "type_identifier", "text": "Paytables3X5", "parent": 261, "children": [], "start_point": {"row": 61, "column": 2}, "end_point": {"row": 61, "column": 14}}, {"id": 263, "type": "identifier", "text": "m_paytables", "parent": 261, "children": [], "start_point": {"row": 61, "column": 15}, "end_point": {"row": 61, "column": 26}}, {"id": 264, "type": "declaration", "text": "BetList m_lstBet;", "parent": 35, "children": [265, 266], "start_point": {"row": 62, "column": 2}, "end_point": {"row": 62, "column": 19}}, {"id": 265, "type": "type_identifier", "text": "BetList", "parent": 264, "children": [], "start_point": {"row": 62, "column": 2}, "end_point": {"row": 62, "column": 9}}, {"id": 266, "type": "identifier", "text": "m_lstBet", "parent": 264, "children": [], "start_point": {"row": 62, "column": 10}, "end_point": {"row": 62, "column": 18}}, {"id": 267, "type": "labeled_statement", "text": "natashapb::MuseumConfig m_cfg;", "parent": 35, "children": [268, 269], "start_point": {"row": 63, "column": 4}, "end_point": {"row": 63, "column": 34}}, {"id": 268, "type": "statement_identifier", "text": "natashapb", "parent": 267, "children": [], "start_point": {"row": 63, "column": 4}, "end_point": {"row": 63, "column": 13}}, {"id": 269, "type": "declaration", "text": "MuseumConfig m_cfg;", "parent": 267, "children": [270, 271], "start_point": {"row": 63, "column": 15}, "end_point": {"row": 63, "column": 34}}, {"id": 270, "type": "type_identifier", "text": "MuseumConfig", "parent": 269, "children": [], "start_point": {"row": 63, "column": 15}, "end_point": {"row": 63, "column": 27}}, {"id": 271, "type": "identifier", "text": "m_cfg", "parent": 269, "children": [], "start_point": {"row": 63, "column": 28}, "end_point": {"row": 63, "column": 33}}, {"id": 272, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 68, "column": 0}, "end_point": {"row": 68, "column": 6}}]}, "node_categories": {"declarations": {"functions": [27, 32, 35, 44, 48, 58, 72, 91, 94, 134, 138, 253], "variables": [30, 56, 61, 66, 75, 80, 87, 97, 100, 102, 141, 146, 151, 156, 175, 251, 258, 261, 264, 269], "classes": [176], "imports": [6, 7, 9, 10, 12, 13, 15, 16, 18, 19, 21, 22, 24, 25], "modules": [], "enums": []}, "statements": {"expressions": [41, 109, 111, 119, 121, 129, 131, 164, 165, 166, 167, 182, 183, 184, 185, 192, 193, 201, 202, 208, 212, 213, 218, 219, 224, 225, 229, 230, 234, 235, 236, 241, 242], "assignments": [197], "loops": [], "conditionals": [0, 1, 2, 5, 28, 29, 33, 37, 38, 42, 45, 49, 53, 55, 57, 59, 65, 67, 69, 73, 76, 79, 82, 83, 84, 85, 88, 90, 92, 95, 98, 99, 101, 103, 105, 108, 110, 115, 118, 120, 122, 123, 125, 128, 130, 135, 137, 139, 142, 144, 145, 147, 149, 150, 152, 154, 155, 157, 159, 162, 163, 168, 169, 172, 174, 178, 180, 186, 187, 189, 191, 194, 198, 203, 204, 206, 209, 214, 215, 220, 221, 223, 226, 227, 231, 232, 237, 238, 243, 244, 246, 247, 248, 249, 254, 256, 259, 260, 262, 263, 265, 266, 268, 270, 271, 272], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [8, 11, 14, 17, 20, 23, 26, 112, 113, 132, 133, 196, 200, 207, 211], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 27, "universal_type": "function", "name": "countRTP_museum", "text_snippet": "namespace natasha {\n\n// countRTP_museum - count rtp\nvoid countRTP_museum();\n\n// Museum\nclass Museum "}, {"node_id": 32, "universal_type": "function", "name": "unknown", "text_snippet": "countRTP_museum()"}, {"node_id": 35, "universal_type": "function", "name": "Museum", "text_snippet": "class Museum : public GameLogic {\n public:\n Museum() {}\n virtual ~Museum() {}\n\n public:\n virtual "}, {"node_id": 44, "universal_type": "function", "name": "unknown", "text_snippet": "virtual ~Museum() {}"}, {"node_id": 48, "universal_type": "function", "name": "unknown", "text_snippet": "Museum()"}, {"node_id": 58, "universal_type": "function", "name": "unknown", "text_snippet": "init(const char* cfgpath)"}, {"node_id": 72, "universal_type": "function", "name": "isComeInGame)", "text_snippet": "getMainGameMod(UserInfo* pUser, bool isComeInGame)"}, {"node_id": 91, "universal_type": "function", "name": "unknown", "text_snippet": "onInitRTP()"}, {"node_id": 94, "universal_type": "function", "name": "unknown", "text_snippet": "addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols)"}, {"node_id": 134, "universal_type": "function", "name": "onRTPAddPayoutGRI", "text_snippet": "virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n con"}, {"node_id": 138, "universal_type": "function", "name": "unknown", "text_snippet": "onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashap"}, {"node_id": 253, "universal_type": "function", "name": "unknown", "text_snippet": "initConfig()"}], "class_declarations": [{"node_id": 176, "universal_type": "class", "name": "unknown", "text_snippet": "auto"}], "import_statements": [{"node_id": 6, "text": "#include <assert.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <vector>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include \"../include/game3x5.h\"\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include \"../include/gamelogic.h\"\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include \"basegame.h\"\n"}, {"node_id": 19, "text": "#include"}, {"node_id": 21, "text": "#include \"freegame.h\"\n"}, {"node_id": 22, "text": "#include"}, {"node_id": 24, "text": "#include \"game_museum.h\"\n"}, {"node_id": 25, "text": "#include"}]}, "original_source_code": "#ifndef __NATASHA_MUSEUM_H__\n#define __NATASHA_MUSEUM_H__\n\n#include <assert.h>\n#include <vector>\n#include \"../include/game3x5.h\"\n#include \"../include/gamelogic.h\"\n#include \"basegame.h\"\n#include \"freegame.h\"\n#include \"game_museum.h\"\n\nnamespace natasha {\n\n// countRTP_museum - count rtp\nvoid countRTP_museum();\n\n// Museum\nclass Museum : public GameLogic {\n public:\n Museum() {}\n virtual ~Museum() {}\n\n public:\n virtual ::natashapb::CODE init(const char* cfgpath);\n\n // getMainGameMod - get current main game module\n virtual GameMod* getMainGameMod(UserInfo* pUser, bool isComeInGame);\n#ifdef NATASHA_COUNTRTP\n public:\n virtual void onInitRTP() {\n addRTPModule(::natashapb::BASE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::BASE_GAME, \"wildbomb\", 6);\n addRTPModule(::natashapb::FREE_GAME, MeseumMaxPayoutNums, MeseumMaxSymbols);\n addRTPModuleBonus(::natashapb::FREE_GAME, \"wildbomb\", 6);\n }\n\n virtual void onRTPAddPayoutGRI(::natashapb::GAMEMODTYPE module,\n const ::natashapb::SpinResult& spinret,\n const ::natashapb::GameResultInfo& gri,\n const ::natashapb::UserGameModInfo* pUser) {\n if (gri.typegameresult() == ::natashapb::SPECIAL) {\n auto turnnums = pUser->cascadinginfo().turnnums();\n if (turnnums > 6) {\n turnnums = 6;\n }\n\n m_rtp.addBonusPayout(module, \"wildbomb\", turnnums - 1, gri.realwin());\n } else {\n m_rtp.addSymbolPayout(module, gri.symbol(), gri.lstsymbol_size(),\n gri.realwin() * spinret.awardmul());\n }\n }\n#endif // NATASHA_COUNTRTP\n\n#ifdef NATASHA_RUNINCPP\n public:\n void initConfig();\n#endif // NATASHA_RUNINCPP\n\n protected:\n NormalReels3X5 m_reels;\n Paytables3X5 m_paytables;\n BetList m_lstBet;\n ::natashapb::MuseumConfig m_cfg;\n}; // namespace natasha\n\n} // namespace natasha\n\n#endif // __NATASHA_MUSEUM_H__"}
80,515
c
/** ****************************************************************************** * @file : init_stwin_sensors.c * @brief : Sensors functions for stwin board ****************************************************************************** * @attention * * <h2><center>&copy; Copyright (c) 2021 enzopicas. * All rights reserved.</center></h2> * * This software component is licensed by ST under BSD 3-Clause license, * the "License"; You may not use this file except in compliance with the * License. You may obtain a copy of the License at: * opensource.org/licenses/BSD-3-Clause * ****************************************************************************** */ #include "init_stwin_sensors.h" /*---------- GLOBAL ----------*/ int init_sensors(UART_HandleTypeDef *UART_bus, I2C_HandleTypeDef *stts751_bus, I2C_HandleTypeDef *lps22hh_bus, I2C_HandleTypeDef *hts221_bus, SPI_HandleTypeDef *ism330_bus) { uint16_t uart_buf_len; uint8_t uart_buf[500] = ""; /*-------- START --------*/ uart_buf_len = sprintf(uart_buf, "---- Demarrage de l'UART ----\r\n"); HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100); /*-------- STTS751 --------*/ if (init_stts751(stts751_bus) == 0) { uart_buf_len = sprintf(uart_buf, "---- Init STTS751 OK\r\n"); HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100); } else { uart_buf_len = sprintf(uart_buf, "---- Init STTS751 Failure\r\n"); HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100); return -1; } /*-------- LPS22HH --------*/ if (init_lps22hh(lps22hh_bus) == 0) { uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH OK\r\n"); HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100); } else { uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH Failure\r\n"); HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100); return -2; } /*-------- HTS221 --------*/ if (init_hts221(hts221_bus) == 0) { uart_buf_len = sprintf(uart_buf, "---- Init HTS221 OK\r\n"); HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100); } else { uart_buf_len = sprintf(uart_buf, "---- Init HTS221 Failure\r\n"); HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100); return -3; } /*-------- ISM330 --------*/ /* if (init_ism330(ism330_bus) == 0) { uart_buf_len = sprintf(uart_buf, "---- Init ISM330 OK\r\n"); HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100); } else { uart_buf_len = sprintf(uart_buf, "---- Init ISM330 Failure\r\n"); HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100); return -4; } */ return 0; } /*---------- STTS 751 ----------*/ int init_stts751(I2C_HandleTypeDef *stts751_bus) { stts751_id_t stts751_whoamI; stts751_dev_ctx.write_reg = platform_write_stts751; stts751_dev_ctx.read_reg = platform_read_stts751; stts751_dev_ctx.handle = stts751_bus; stts751_device_id_get(&stts751_dev_ctx, &stts751_whoamI); if ( (stts751_whoamI.product_id != STTS751_ID_0xxxx) || (stts751_whoamI.manufacturer_id != STTS751_ID_MAN) || (stts751_whoamI.revision_id != STTS751_REV) ) { return -1; } /* Enable interrupt on high(=49.5 degC)/low(=-4.5 degC) temperature. */ float temperature_high_limit = 49.5f; stts751_high_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_high_limit)); float temperature_low_limit = -4.5f; stts751_low_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_low_limit)); stts751_pin_event_route_set(&stts751_dev_ctx, PROPERTY_ENABLE); /* Set Output Data Rate */ stts751_temp_data_rate_set(&stts751_dev_ctx, STTS751_TEMP_ODR_8Hz); /* Set Resolution */ stts751_resolution_set(&stts751_dev_ctx, STTS751_12bit); return 0; } int32_t platform_write_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len) { HAL_I2C_Mem_Write(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000); return 0; } int32_t platform_read_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len) { HAL_I2C_Mem_Read(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000); return 0; } /*---------- LPS22HH ----------*/ int init_lps22hh(I2C_HandleTypeDef *lps22hh_bus) { uint8_t lps22hh_whoamI; uint8_t lps22hh_rst; lps22hh_dev_ctx.write_reg = platform_write_lps22hh; lps22hh_dev_ctx.read_reg = platform_read_lps22hh; lps22hh_dev_ctx.handle = lps22hh_bus; lps22hh_device_id_get(&lps22hh_dev_ctx, &lps22hh_whoamI); if (lps22hh_whoamI != LPS22HH_ID) { return -1; } lps22hh_reset_set(&lps22hh_dev_ctx, PROPERTY_ENABLE); do { lps22hh_reset_get(&lps22hh_dev_ctx, &lps22hh_rst); } while (lps22hh_rst); /* Enable Block Data Update */ lps22hh_block_data_update_set(&lps22hh_dev_ctx, PROPERTY_ENABLE); /* Set Output Data Rate */ lps22hh_data_rate_set(&lps22hh_dev_ctx, LPS22HH_10_Hz_LOW_NOISE); return 0; } int32_t platform_write_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len) { HAL_I2C_Mem_Write(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000); return 0; } int32_t platform_read_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len) { HAL_I2C_Mem_Read(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000); } /*---------- HTS221 ----------*/ int init_hts221(I2C_HandleTypeDef *hts221_bus) { uint8_t hts221_whoamI; hts221_dev_ctx.write_reg = platform_write_hts221; hts221_dev_ctx.read_reg = platform_read_hts221; hts221_dev_ctx.handle = hts221_bus; hts221_whoamI = 0; hts221_device_id_get(&hts221_dev_ctx, &hts221_whoamI); if (hts221_whoamI != HTS221_ID) { return -1; } hts221_hum_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.x0); hts221_hum_rh_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.y0); hts221_hum_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.x1); hts221_hum_rh_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.y1); /* Read temperature calibration coefficient */ hts221_temp_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.x0); hts221_temp_deg_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.y0); hts221_temp_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.x1); hts221_temp_deg_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.y1); /* Enable Block Data Update */ hts221_block_data_update_set(&hts221_dev_ctx, PROPERTY_ENABLE); /* Set Output Data Rate */ hts221_data_rate_set(&hts221_dev_ctx, HTS221_ODR_7Hz); /* Device power on */ hts221_power_on_set(&hts221_dev_ctx, PROPERTY_ENABLE); return 0; } float linear_interpolation(lin_t *lin, int16_t x) { return ((lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) - (lin->x0 * lin->y1))) / (lin->x1 - lin->x0); } int32_t platform_write_hts221(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len) { reg |= 0x80; HAL_I2C_Mem_Write(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000); return 0; } int32_t platform_read_hts221(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len) { reg |= 0x80; HAL_I2C_Mem_Read(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000); return 0; } /*---------- ISM330 ----------*/ /* int init_ism330(SPI_HandleTypeDef *ism330_bus) { ism330_dev_ctx.write_reg = platform_write; ism330_dev_ctx.read_reg = platform_read; ism330_dev_ctx.handle = &ism330_bus; ism330dhcx_device_id_get(&ism330_dev_ctx, &ism330_whoamI); if (ism330_whoamI != ISM330DHCX_ID) { return -1; } ism330dhcx_reset_set(&ism330_dev_ctx, PROPERTY_ENABLE); do { ism330dhcx_reset_get(&ism330_dev_ctx, &ism330_rst); } while (ism330_rst); //* Enable Block Data Update * ism330dhcx_block_data_update_set(&ism330_dev_ctx, PROPERTY_ENABLE); //* Set Output Data Rate ism330dhcx_xl_data_rate_set(&ism330_dev_ctx, ISM330DHCX_XL_ODR_12Hz5); ism330dhcx_gy_data_rate_set(&ism330_dev_ctx, ISM330DHCX_GY_ODR_12Hz5); //* Set full scale * ism330dhcx_xl_full_scale_set(&ism330_dev_ctx, ISM330DHCX_2g); ism330dhcx_gy_full_scale_set(&ism330_dev_ctx, ISM330DHCX_2000dps); //* Configure filtering chain(No aux interface) * ism330dhcx_xl_hp_path_on_out_set(&ism330_dev_ctx, ISM330DHCX_LP_ODR_DIV_100); ism330dhcx_xl_filter_lp2_set(&ism330_dev_ctx, PROPERTY_ENABLE); return 0; } */
35.14
228
(translation_unit) "/**\n ******************************************************************************\n * @file : init_stwin_sensors.c\n * @brief : Sensors functions for stwin board\n ******************************************************************************\n * @attention\n *\n * <h2><center>&copy; Copyright (c) 2021 enzopicas.\n * All rights reserved.</center></h2>\n *\n * This software component is licensed by ST under BSD 3-Clause license,\n * the "License"; You may not use this file except in compliance with the\n * License. You may obtain a copy of the License at:\n * opensource.org/licenses/BSD-3-Clause\n *\n ******************************************************************************\n */\n\n#include "init_stwin_sensors.h"\n\n/*---------- GLOBAL ----------*/\nint init_sensors(UART_HandleTypeDef *UART_bus, I2C_HandleTypeDef *stts751_bus, I2C_HandleTypeDef *lps22hh_bus,\n I2C_HandleTypeDef *hts221_bus, SPI_HandleTypeDef *ism330_bus)\n{\n uint16_t uart_buf_len;\n uint8_t uart_buf[500] = "";\n\n /*-------- START --------*/\n uart_buf_len = sprintf(uart_buf, "---- Demarrage de l'UART ----\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\n /*-------- STTS751 --------*/\n if (init_stts751(stts751_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init STTS751 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init STTS751 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -1;\n }\n\n /*-------- LPS22HH --------*/\n if (init_lps22hh(lps22hh_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -2;\n }\n\n /*-------- HTS221 --------*/\n\n if (init_hts221(hts221_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init HTS221 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init HTS221 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -3;\n }\n\n\n /*-------- ISM330 --------*/\n /*\n if (init_ism330(ism330_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init ISM330 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init ISM330 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -4;\n }\n */\n\n return 0;\n}\n\n/*---------- STTS 751 ----------*/\nint init_stts751(I2C_HandleTypeDef *stts751_bus)\n{\n stts751_id_t stts751_whoamI;\n\n stts751_dev_ctx.write_reg = platform_write_stts751;\n stts751_dev_ctx.read_reg = platform_read_stts751;\n stts751_dev_ctx.handle = stts751_bus;\n\n stts751_device_id_get(&stts751_dev_ctx, &stts751_whoamI);\n if ( (stts751_whoamI.product_id != STTS751_ID_0xxxx) ||\n (stts751_whoamI.manufacturer_id != STTS751_ID_MAN) ||\n (stts751_whoamI.revision_id != STTS751_REV) )\n {\n return -1;\n }\n\n /* Enable interrupt on high(=49.5 degC)/low(=-4.5 degC) temperature. */\n float temperature_high_limit = 49.5f;\n stts751_high_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_high_limit));\n\n float temperature_low_limit = -4.5f;\n stts751_low_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_low_limit));\n\n stts751_pin_event_route_set(&stts751_dev_ctx, PROPERTY_ENABLE);\n\n /* Set Output Data Rate */\n stts751_temp_data_rate_set(&stts751_dev_ctx, STTS751_TEMP_ODR_8Hz);\n\n /* Set Resolution */\n stts751_resolution_set(&stts751_dev_ctx, STTS751_12bit);\n\n return 0;\n}\n\nint32_t platform_write_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n HAL_I2C_Mem_Write(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}\n\nint32_t platform_read_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n HAL_I2C_Mem_Read(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}\n\n/*---------- LPS22HH ----------*/\nint init_lps22hh(I2C_HandleTypeDef *lps22hh_bus)\n{\n uint8_t lps22hh_whoamI;\n uint8_t lps22hh_rst;\n\n lps22hh_dev_ctx.write_reg = platform_write_lps22hh;\n lps22hh_dev_ctx.read_reg = platform_read_lps22hh;\n lps22hh_dev_ctx.handle = lps22hh_bus;\n\n lps22hh_device_id_get(&lps22hh_dev_ctx, &lps22hh_whoamI);\n if (lps22hh_whoamI != LPS22HH_ID)\n {\n return -1;\n }\n\n lps22hh_reset_set(&lps22hh_dev_ctx, PROPERTY_ENABLE);\n do {\n lps22hh_reset_get(&lps22hh_dev_ctx, &lps22hh_rst);\n } while (lps22hh_rst);\n\n /* Enable Block Data Update */\n lps22hh_block_data_update_set(&lps22hh_dev_ctx, PROPERTY_ENABLE);\n /* Set Output Data Rate */\n lps22hh_data_rate_set(&lps22hh_dev_ctx, LPS22HH_10_Hz_LOW_NOISE);\n\n return 0;\n}\n\nint32_t platform_write_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n HAL_I2C_Mem_Write(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}\n\nint32_t platform_read_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n HAL_I2C_Mem_Read(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n}\n\n/*---------- HTS221 ----------*/\nint init_hts221(I2C_HandleTypeDef *hts221_bus)\n{\n uint8_t hts221_whoamI;\n\n hts221_dev_ctx.write_reg = platform_write_hts221;\n hts221_dev_ctx.read_reg = platform_read_hts221;\n hts221_dev_ctx.handle = hts221_bus;\n\n hts221_whoamI = 0;\n hts221_device_id_get(&hts221_dev_ctx, &hts221_whoamI);\n if (hts221_whoamI != HTS221_ID)\n {\n return -1;\n }\n\n hts221_hum_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.x0);\n hts221_hum_rh_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.y0);\n hts221_hum_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.x1);\n hts221_hum_rh_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.y1);\n /* Read temperature calibration coefficient */\n hts221_temp_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.x0);\n hts221_temp_deg_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.y0);\n hts221_temp_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.x1);\n hts221_temp_deg_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.y1);\n /* Enable Block Data Update */\n hts221_block_data_update_set(&hts221_dev_ctx, PROPERTY_ENABLE);\n /* Set Output Data Rate */\n hts221_data_rate_set(&hts221_dev_ctx, HTS221_ODR_7Hz);\n /* Device power on */\n hts221_power_on_set(&hts221_dev_ctx, PROPERTY_ENABLE);\n\n return 0;\n}\n\nfloat linear_interpolation(lin_t *lin, int16_t x)\n{\n return ((lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) -\n (lin->x0 * lin->y1))) / (lin->x1 - lin->x0);\n}\n\nint32_t platform_write_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)\n{\n reg |= 0x80;\n HAL_I2C_Mem_Write(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}\n\nint32_t platform_read_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)\n{\n reg |= 0x80;\n HAL_I2C_Mem_Read(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}\n\n/*---------- ISM330 ----------*/\n/*\nint init_ism330(SPI_HandleTypeDef *ism330_bus)\n{\n ism330_dev_ctx.write_reg = platform_write;\n ism330_dev_ctx.read_reg = platform_read;\n ism330_dev_ctx.handle = &ism330_bus;\n\n ism330dhcx_device_id_get(&ism330_dev_ctx, &ism330_whoamI);\n if (ism330_whoamI != ISM330DHCX_ID)\n {\n return -1;\n }\n\n ism330dhcx_reset_set(&ism330_dev_ctx, PROPERTY_ENABLE);\n do\n {\n ism330dhcx_reset_get(&ism330_dev_ctx, &ism330_rst);\n } while (ism330_rst);\n\n //* Enable Block Data Update *\n ism330dhcx_block_data_update_set(&ism330_dev_ctx, PROPERTY_ENABLE);\n //* Set Output Data Rate\n ism330dhcx_xl_data_rate_set(&ism330_dev_ctx, ISM330DHCX_XL_ODR_12Hz5);\n ism330dhcx_gy_data_rate_set(&ism330_dev_ctx, ISM330DHCX_GY_ODR_12Hz5);\n //* Set full scale *\n ism330dhcx_xl_full_scale_set(&ism330_dev_ctx, ISM330DHCX_2g);\n ism330dhcx_gy_full_scale_set(&ism330_dev_ctx, ISM330DHCX_2000dps);\n //* Configure filtering chain(No aux interface) *\n ism330dhcx_xl_hp_path_on_out_set(&ism330_dev_ctx, ISM330DHCX_LP_ODR_DIV_100);\n ism330dhcx_xl_filter_lp2_set(&ism330_dev_ctx, PROPERTY_ENABLE);\n\n return 0;\n}\n*/\n" (comment) "/**\n ******************************************************************************\n * @file : init_stwin_sensors.c\n * @brief : Sensors functions for stwin board\n ******************************************************************************\n * @attention\n *\n * <h2><center>&copy; Copyright (c) 2021 enzopicas.\n * All rights reserved.</center></h2>\n *\n * This software component is licensed by ST under BSD 3-Clause license,\n * the "License"; You may not use this file except in compliance with the\n * License. You may obtain a copy of the License at:\n * opensource.org/licenses/BSD-3-Clause\n *\n ******************************************************************************\n */" (preproc_include) "#include "init_stwin_sensors.h"\n" (#include) "#include" (string_literal) ""init_stwin_sensors.h"" (") """ (string_content) "init_stwin_sensors.h" (") """ (comment) "/*---------- GLOBAL ----------*/" (function_definition) "int init_sensors(UART_HandleTypeDef *UART_bus, I2C_HandleTypeDef *stts751_bus, I2C_HandleTypeDef *lps22hh_bus,\n I2C_HandleTypeDef *hts221_bus, SPI_HandleTypeDef *ism330_bus)\n{\n uint16_t uart_buf_len;\n uint8_t uart_buf[500] = "";\n\n /*-------- START --------*/\n uart_buf_len = sprintf(uart_buf, "---- Demarrage de l'UART ----\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\n /*-------- STTS751 --------*/\n if (init_stts751(stts751_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init STTS751 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init STTS751 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -1;\n }\n\n /*-------- LPS22HH --------*/\n if (init_lps22hh(lps22hh_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -2;\n }\n\n /*-------- HTS221 --------*/\n\n if (init_hts221(hts221_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init HTS221 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init HTS221 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -3;\n }\n\n\n /*-------- ISM330 --------*/\n /*\n if (init_ism330(ism330_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init ISM330 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init ISM330 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -4;\n }\n */\n\n return 0;\n}" (primitive_type) "int" (function_declarator) "init_sensors(UART_HandleTypeDef *UART_bus, I2C_HandleTypeDef *stts751_bus, I2C_HandleTypeDef *lps22hh_bus,\n I2C_HandleTypeDef *hts221_bus, SPI_HandleTypeDef *ism330_bus)" (identifier) "init_sensors" (parameter_list) "(UART_HandleTypeDef *UART_bus, I2C_HandleTypeDef *stts751_bus, I2C_HandleTypeDef *lps22hh_bus,\n I2C_HandleTypeDef *hts221_bus, SPI_HandleTypeDef *ism330_bus)" (() "(" (parameter_declaration) "UART_HandleTypeDef *UART_bus" (type_identifier) "UART_HandleTypeDef" (pointer_declarator) "*UART_bus" (*) "*" (identifier) "UART_bus" (,) "," (parameter_declaration) "I2C_HandleTypeDef *stts751_bus" (type_identifier) "I2C_HandleTypeDef" (pointer_declarator) "*stts751_bus" (*) "*" (identifier) "stts751_bus" (,) "," (parameter_declaration) "I2C_HandleTypeDef *lps22hh_bus" (type_identifier) "I2C_HandleTypeDef" (pointer_declarator) "*lps22hh_bus" (*) "*" (identifier) "lps22hh_bus" (,) "," (parameter_declaration) "I2C_HandleTypeDef *hts221_bus" (type_identifier) "I2C_HandleTypeDef" (pointer_declarator) "*hts221_bus" (*) "*" (identifier) "hts221_bus" (,) "," (parameter_declaration) "SPI_HandleTypeDef *ism330_bus" (type_identifier) "SPI_HandleTypeDef" (pointer_declarator) "*ism330_bus" (*) "*" (identifier) "ism330_bus" ()) ")" (compound_statement) "{\n uint16_t uart_buf_len;\n uint8_t uart_buf[500] = "";\n\n /*-------- START --------*/\n uart_buf_len = sprintf(uart_buf, "---- Demarrage de l'UART ----\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\n /*-------- STTS751 --------*/\n if (init_stts751(stts751_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init STTS751 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init STTS751 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -1;\n }\n\n /*-------- LPS22HH --------*/\n if (init_lps22hh(lps22hh_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -2;\n }\n\n /*-------- HTS221 --------*/\n\n if (init_hts221(hts221_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init HTS221 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init HTS221 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -3;\n }\n\n\n /*-------- ISM330 --------*/\n /*\n if (init_ism330(ism330_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init ISM330 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init ISM330 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -4;\n }\n */\n\n return 0;\n}" ({) "{" (declaration) "uint16_t uart_buf_len;" (primitive_type) "uint16_t" (identifier) "uart_buf_len" (;) ";" (declaration) "uint8_t uart_buf[500] = "";" (primitive_type) "uint8_t" (init_declarator) "uart_buf[500] = """ (array_declarator) "uart_buf[500]" (identifier) "uart_buf" ([) "[" (number_literal) "500" (]) "]" (=) "=" (string_literal) """" (") """ (") """ (;) ";" (comment) "/*-------- START --------*/" (expression_statement) "uart_buf_len = sprintf(uart_buf, "---- Demarrage de l'UART ----\r\n");" (assignment_expression) "uart_buf_len = sprintf(uart_buf, "---- Demarrage de l'UART ----\r\n")" (identifier) "uart_buf_len" (=) "=" (call_expression) "sprintf(uart_buf, "---- Demarrage de l'UART ----\r\n")" (identifier) "sprintf" (argument_list) "(uart_buf, "---- Demarrage de l'UART ----\r\n")" (() "(" (identifier) "uart_buf" (,) "," (string_literal) ""---- Demarrage de l'UART ----\r\n"" (") """ (string_content) "---- Demarrage de l'UART ----" (escape_sequence) "\r" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (expression_statement) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);" (call_expression) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)" (identifier) "HAL_UART_Transmit" (argument_list) "(UART_bus, uart_buf, uart_buf_len, 100)" (() "(" (identifier) "UART_bus" (,) "," (identifier) "uart_buf" (,) "," (identifier) "uart_buf_len" (,) "," (number_literal) "100" ()) ")" (;) ";" (comment) "/*-------- STTS751 --------*/" (if_statement) "if (init_stts751(stts751_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init STTS751 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init STTS751 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -1;\n }" (if) "if" (parenthesized_expression) "(init_stts751(stts751_bus) == 0)" (() "(" (binary_expression) "init_stts751(stts751_bus) == 0" (call_expression) "init_stts751(stts751_bus)" (identifier) "init_stts751" (argument_list) "(stts751_bus)" (() "(" (identifier) "stts751_bus" ()) ")" (==) "==" (number_literal) "0" ()) ")" (compound_statement) "{\n uart_buf_len = sprintf(uart_buf, "---- Init STTS751 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }" ({) "{" (expression_statement) "uart_buf_len = sprintf(uart_buf, "---- Init STTS751 OK\r\n");" (assignment_expression) "uart_buf_len = sprintf(uart_buf, "---- Init STTS751 OK\r\n")" (identifier) "uart_buf_len" (=) "=" (call_expression) "sprintf(uart_buf, "---- Init STTS751 OK\r\n")" (identifier) "sprintf" (argument_list) "(uart_buf, "---- Init STTS751 OK\r\n")" (() "(" (identifier) "uart_buf" (,) "," (string_literal) ""---- Init STTS751 OK\r\n"" (") """ (string_content) "---- Init STTS751 OK" (escape_sequence) "\r" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (expression_statement) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);" (call_expression) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)" (identifier) "HAL_UART_Transmit" (argument_list) "(UART_bus, uart_buf, uart_buf_len, 100)" (() "(" (identifier) "UART_bus" (,) "," (identifier) "uart_buf" (,) "," (identifier) "uart_buf_len" (,) "," (number_literal) "100" ()) ")" (;) ";" (}) "}" (else_clause) "else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init STTS751 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -1;\n }" (else) "else" (compound_statement) "{\n uart_buf_len = sprintf(uart_buf, "---- Init STTS751 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -1;\n }" ({) "{" (expression_statement) "uart_buf_len = sprintf(uart_buf, "---- Init STTS751 Failure\r\n");" (assignment_expression) "uart_buf_len = sprintf(uart_buf, "---- Init STTS751 Failure\r\n")" (identifier) "uart_buf_len" (=) "=" (call_expression) "sprintf(uart_buf, "---- Init STTS751 Failure\r\n")" (identifier) "sprintf" (argument_list) "(uart_buf, "---- Init STTS751 Failure\r\n")" (() "(" (identifier) "uart_buf" (,) "," (string_literal) ""---- Init STTS751 Failure\r\n"" (") """ (string_content) "---- Init STTS751 Failure" (escape_sequence) "\r" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (expression_statement) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);" (call_expression) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)" (identifier) "HAL_UART_Transmit" (argument_list) "(UART_bus, uart_buf, uart_buf_len, 100)" (() "(" (identifier) "UART_bus" (,) "," (identifier) "uart_buf" (,) "," (identifier) "uart_buf_len" (,) "," (number_literal) "100" ()) ")" (;) ";" (return_statement) "return -1;" (return) "return" (number_literal) "-1" (;) ";" (}) "}" (comment) "/*-------- LPS22HH --------*/" (if_statement) "if (init_lps22hh(lps22hh_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -2;\n }" (if) "if" (parenthesized_expression) "(init_lps22hh(lps22hh_bus) == 0)" (() "(" (binary_expression) "init_lps22hh(lps22hh_bus) == 0" (call_expression) "init_lps22hh(lps22hh_bus)" (identifier) "init_lps22hh" (argument_list) "(lps22hh_bus)" (() "(" (identifier) "lps22hh_bus" ()) ")" (==) "==" (number_literal) "0" ()) ")" (compound_statement) "{\n uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }" ({) "{" (expression_statement) "uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH OK\r\n");" (assignment_expression) "uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH OK\r\n")" (identifier) "uart_buf_len" (=) "=" (call_expression) "sprintf(uart_buf, "---- Init LPS22HH OK\r\n")" (identifier) "sprintf" (argument_list) "(uart_buf, "---- Init LPS22HH OK\r\n")" (() "(" (identifier) "uart_buf" (,) "," (string_literal) ""---- Init LPS22HH OK\r\n"" (") """ (string_content) "---- Init LPS22HH OK" (escape_sequence) "\r" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (expression_statement) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);" (call_expression) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)" (identifier) "HAL_UART_Transmit" (argument_list) "(UART_bus, uart_buf, uart_buf_len, 100)" (() "(" (identifier) "UART_bus" (,) "," (identifier) "uart_buf" (,) "," (identifier) "uart_buf_len" (,) "," (number_literal) "100" ()) ")" (;) ";" (}) "}" (else_clause) "else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -2;\n }" (else) "else" (compound_statement) "{\n uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -2;\n }" ({) "{" (expression_statement) "uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH Failure\r\n");" (assignment_expression) "uart_buf_len = sprintf(uart_buf, "---- Init LPS22HH Failure\r\n")" (identifier) "uart_buf_len" (=) "=" (call_expression) "sprintf(uart_buf, "---- Init LPS22HH Failure\r\n")" (identifier) "sprintf" (argument_list) "(uart_buf, "---- Init LPS22HH Failure\r\n")" (() "(" (identifier) "uart_buf" (,) "," (string_literal) ""---- Init LPS22HH Failure\r\n"" (") """ (string_content) "---- Init LPS22HH Failure" (escape_sequence) "\r" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (expression_statement) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);" (call_expression) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)" (identifier) "HAL_UART_Transmit" (argument_list) "(UART_bus, uart_buf, uart_buf_len, 100)" (() "(" (identifier) "UART_bus" (,) "," (identifier) "uart_buf" (,) "," (identifier) "uart_buf_len" (,) "," (number_literal) "100" ()) ")" (;) ";" (return_statement) "return -2;" (return) "return" (number_literal) "-2" (;) ";" (}) "}" (comment) "/*-------- HTS221 --------*/" (if_statement) "if (init_hts221(hts221_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init HTS221 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init HTS221 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -3;\n }" (if) "if" (parenthesized_expression) "(init_hts221(hts221_bus) == 0)" (() "(" (binary_expression) "init_hts221(hts221_bus) == 0" (call_expression) "init_hts221(hts221_bus)" (identifier) "init_hts221" (argument_list) "(hts221_bus)" (() "(" (identifier) "hts221_bus" ()) ")" (==) "==" (number_literal) "0" ()) ")" (compound_statement) "{\n uart_buf_len = sprintf(uart_buf, "---- Init HTS221 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }" ({) "{" (expression_statement) "uart_buf_len = sprintf(uart_buf, "---- Init HTS221 OK\r\n");" (assignment_expression) "uart_buf_len = sprintf(uart_buf, "---- Init HTS221 OK\r\n")" (identifier) "uart_buf_len" (=) "=" (call_expression) "sprintf(uart_buf, "---- Init HTS221 OK\r\n")" (identifier) "sprintf" (argument_list) "(uart_buf, "---- Init HTS221 OK\r\n")" (() "(" (identifier) "uart_buf" (,) "," (string_literal) ""---- Init HTS221 OK\r\n"" (") """ (string_content) "---- Init HTS221 OK" (escape_sequence) "\r" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (expression_statement) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);" (call_expression) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)" (identifier) "HAL_UART_Transmit" (argument_list) "(UART_bus, uart_buf, uart_buf_len, 100)" (() "(" (identifier) "UART_bus" (,) "," (identifier) "uart_buf" (,) "," (identifier) "uart_buf_len" (,) "," (number_literal) "100" ()) ")" (;) ";" (}) "}" (else_clause) "else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init HTS221 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -3;\n }" (else) "else" (compound_statement) "{\n uart_buf_len = sprintf(uart_buf, "---- Init HTS221 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -3;\n }" ({) "{" (expression_statement) "uart_buf_len = sprintf(uart_buf, "---- Init HTS221 Failure\r\n");" (assignment_expression) "uart_buf_len = sprintf(uart_buf, "---- Init HTS221 Failure\r\n")" (identifier) "uart_buf_len" (=) "=" (call_expression) "sprintf(uart_buf, "---- Init HTS221 Failure\r\n")" (identifier) "sprintf" (argument_list) "(uart_buf, "---- Init HTS221 Failure\r\n")" (() "(" (identifier) "uart_buf" (,) "," (string_literal) ""---- Init HTS221 Failure\r\n"" (") """ (string_content) "---- Init HTS221 Failure" (escape_sequence) "\r" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (expression_statement) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);" (call_expression) "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)" (identifier) "HAL_UART_Transmit" (argument_list) "(UART_bus, uart_buf, uart_buf_len, 100)" (() "(" (identifier) "UART_bus" (,) "," (identifier) "uart_buf" (,) "," (identifier) "uart_buf_len" (,) "," (number_literal) "100" ()) ")" (;) ";" (return_statement) "return -3;" (return) "return" (number_literal) "-3" (;) ";" (}) "}" (comment) "/*-------- ISM330 --------*/" (comment) "/*\n if (init_ism330(ism330_bus) == 0)\n {\n uart_buf_len = sprintf(uart_buf, "---- Init ISM330 OK\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n }\n else\n {\n uart_buf_len = sprintf(uart_buf, "---- Init ISM330 Failure\r\n");\n HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n return -4;\n }\n */" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (comment) "/*---------- STTS 751 ----------*/" (function_definition) "int init_stts751(I2C_HandleTypeDef *stts751_bus)\n{\n stts751_id_t stts751_whoamI;\n\n stts751_dev_ctx.write_reg = platform_write_stts751;\n stts751_dev_ctx.read_reg = platform_read_stts751;\n stts751_dev_ctx.handle = stts751_bus;\n\n stts751_device_id_get(&stts751_dev_ctx, &stts751_whoamI);\n if ( (stts751_whoamI.product_id != STTS751_ID_0xxxx) ||\n (stts751_whoamI.manufacturer_id != STTS751_ID_MAN) ||\n (stts751_whoamI.revision_id != STTS751_REV) )\n {\n return -1;\n }\n\n /* Enable interrupt on high(=49.5 degC)/low(=-4.5 degC) temperature. */\n float temperature_high_limit = 49.5f;\n stts751_high_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_high_limit));\n\n float temperature_low_limit = -4.5f;\n stts751_low_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_low_limit));\n\n stts751_pin_event_route_set(&stts751_dev_ctx, PROPERTY_ENABLE);\n\n /* Set Output Data Rate */\n stts751_temp_data_rate_set(&stts751_dev_ctx, STTS751_TEMP_ODR_8Hz);\n\n /* Set Resolution */\n stts751_resolution_set(&stts751_dev_ctx, STTS751_12bit);\n\n return 0;\n}" (primitive_type) "int" (function_declarator) "init_stts751(I2C_HandleTypeDef *stts751_bus)" (identifier) "init_stts751" (parameter_list) "(I2C_HandleTypeDef *stts751_bus)" (() "(" (parameter_declaration) "I2C_HandleTypeDef *stts751_bus" (type_identifier) "I2C_HandleTypeDef" (pointer_declarator) "*stts751_bus" (*) "*" (identifier) "stts751_bus" ()) ")" (compound_statement) "{\n stts751_id_t stts751_whoamI;\n\n stts751_dev_ctx.write_reg = platform_write_stts751;\n stts751_dev_ctx.read_reg = platform_read_stts751;\n stts751_dev_ctx.handle = stts751_bus;\n\n stts751_device_id_get(&stts751_dev_ctx, &stts751_whoamI);\n if ( (stts751_whoamI.product_id != STTS751_ID_0xxxx) ||\n (stts751_whoamI.manufacturer_id != STTS751_ID_MAN) ||\n (stts751_whoamI.revision_id != STTS751_REV) )\n {\n return -1;\n }\n\n /* Enable interrupt on high(=49.5 degC)/low(=-4.5 degC) temperature. */\n float temperature_high_limit = 49.5f;\n stts751_high_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_high_limit));\n\n float temperature_low_limit = -4.5f;\n stts751_low_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_low_limit));\n\n stts751_pin_event_route_set(&stts751_dev_ctx, PROPERTY_ENABLE);\n\n /* Set Output Data Rate */\n stts751_temp_data_rate_set(&stts751_dev_ctx, STTS751_TEMP_ODR_8Hz);\n\n /* Set Resolution */\n stts751_resolution_set(&stts751_dev_ctx, STTS751_12bit);\n\n return 0;\n}" ({) "{" (declaration) "stts751_id_t stts751_whoamI;" (type_identifier) "stts751_id_t" (identifier) "stts751_whoamI" (;) ";" (expression_statement) "stts751_dev_ctx.write_reg = platform_write_stts751;" (assignment_expression) "stts751_dev_ctx.write_reg = platform_write_stts751" (field_expression) "stts751_dev_ctx.write_reg" (identifier) "stts751_dev_ctx" (.) "." (field_identifier) "write_reg" (=) "=" (identifier) "platform_write_stts751" (;) ";" (expression_statement) "stts751_dev_ctx.read_reg = platform_read_stts751;" (assignment_expression) "stts751_dev_ctx.read_reg = platform_read_stts751" (field_expression) "stts751_dev_ctx.read_reg" (identifier) "stts751_dev_ctx" (.) "." (field_identifier) "read_reg" (=) "=" (identifier) "platform_read_stts751" (;) ";" (expression_statement) "stts751_dev_ctx.handle = stts751_bus;" (assignment_expression) "stts751_dev_ctx.handle = stts751_bus" (field_expression) "stts751_dev_ctx.handle" (identifier) "stts751_dev_ctx" (.) "." (field_identifier) "handle" (=) "=" (identifier) "stts751_bus" (;) ";" (expression_statement) "stts751_device_id_get(&stts751_dev_ctx, &stts751_whoamI);" (call_expression) "stts751_device_id_get(&stts751_dev_ctx, &stts751_whoamI)" (identifier) "stts751_device_id_get" (argument_list) "(&stts751_dev_ctx, &stts751_whoamI)" (() "(" (pointer_expression) "&stts751_dev_ctx" (&) "&" (identifier) "stts751_dev_ctx" (,) "," (pointer_expression) "&stts751_whoamI" (&) "&" (identifier) "stts751_whoamI" ()) ")" (;) ";" (if_statement) "if ( (stts751_whoamI.product_id != STTS751_ID_0xxxx) ||\n (stts751_whoamI.manufacturer_id != STTS751_ID_MAN) ||\n (stts751_whoamI.revision_id != STTS751_REV) )\n {\n return -1;\n }" (if) "if" (parenthesized_expression) "( (stts751_whoamI.product_id != STTS751_ID_0xxxx) ||\n (stts751_whoamI.manufacturer_id != STTS751_ID_MAN) ||\n (stts751_whoamI.revision_id != STTS751_REV) )" (() "(" (binary_expression) "(stts751_whoamI.product_id != STTS751_ID_0xxxx) ||\n (stts751_whoamI.manufacturer_id != STTS751_ID_MAN) ||\n (stts751_whoamI.revision_id != STTS751_REV)" (binary_expression) "(stts751_whoamI.product_id != STTS751_ID_0xxxx) ||\n (stts751_whoamI.manufacturer_id != STTS751_ID_MAN)" (parenthesized_expression) "(stts751_whoamI.product_id != STTS751_ID_0xxxx)" (() "(" (binary_expression) "stts751_whoamI.product_id != STTS751_ID_0xxxx" (field_expression) "stts751_whoamI.product_id" (identifier) "stts751_whoamI" (.) "." (field_identifier) "product_id" (!=) "!=" (identifier) "STTS751_ID_0xxxx" ()) ")" (||) "||" (parenthesized_expression) "(stts751_whoamI.manufacturer_id != STTS751_ID_MAN)" (() "(" (binary_expression) "stts751_whoamI.manufacturer_id != STTS751_ID_MAN" (field_expression) "stts751_whoamI.manufacturer_id" (identifier) "stts751_whoamI" (.) "." (field_identifier) "manufacturer_id" (!=) "!=" (identifier) "STTS751_ID_MAN" ()) ")" (||) "||" (parenthesized_expression) "(stts751_whoamI.revision_id != STTS751_REV)" (() "(" (binary_expression) "stts751_whoamI.revision_id != STTS751_REV" (field_expression) "stts751_whoamI.revision_id" (identifier) "stts751_whoamI" (.) "." (field_identifier) "revision_id" (!=) "!=" (identifier) "STTS751_REV" ()) ")" ()) ")" (compound_statement) "{\n return -1;\n }" ({) "{" (return_statement) "return -1;" (return) "return" (number_literal) "-1" (;) ";" (}) "}" (comment) "/* Enable interrupt on high(=49.5 degC)/low(=-4.5 degC) temperature. */" (declaration) "float temperature_high_limit = 49.5f;" (primitive_type) "float" (init_declarator) "temperature_high_limit = 49.5f" (identifier) "temperature_high_limit" (=) "=" (number_literal) "49.5f" (;) ";" (expression_statement) "stts751_high_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_high_limit));" (call_expression) "stts751_high_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_high_limit))" (identifier) "stts751_high_temperature_threshold_set" (argument_list) "(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_high_limit))" (() "(" (pointer_expression) "&stts751_dev_ctx" (&) "&" (identifier) "stts751_dev_ctx" (,) "," (call_expression) "stts751_from_celsius_to_lsb(temperature_high_limit)" (identifier) "stts751_from_celsius_to_lsb" (argument_list) "(temperature_high_limit)" (() "(" (identifier) "temperature_high_limit" ()) ")" ()) ")" (;) ";" (declaration) "float temperature_low_limit = -4.5f;" (primitive_type) "float" (init_declarator) "temperature_low_limit = -4.5f" (identifier) "temperature_low_limit" (=) "=" (number_literal) "-4.5f" (;) ";" (expression_statement) "stts751_low_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_low_limit));" (call_expression) "stts751_low_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_low_limit))" (identifier) "stts751_low_temperature_threshold_set" (argument_list) "(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_low_limit))" (() "(" (pointer_expression) "&stts751_dev_ctx" (&) "&" (identifier) "stts751_dev_ctx" (,) "," (call_expression) "stts751_from_celsius_to_lsb(temperature_low_limit)" (identifier) "stts751_from_celsius_to_lsb" (argument_list) "(temperature_low_limit)" (() "(" (identifier) "temperature_low_limit" ()) ")" ()) ")" (;) ";" (expression_statement) "stts751_pin_event_route_set(&stts751_dev_ctx, PROPERTY_ENABLE);" (call_expression) "stts751_pin_event_route_set(&stts751_dev_ctx, PROPERTY_ENABLE)" (identifier) "stts751_pin_event_route_set" (argument_list) "(&stts751_dev_ctx, PROPERTY_ENABLE)" (() "(" (pointer_expression) "&stts751_dev_ctx" (&) "&" (identifier) "stts751_dev_ctx" (,) "," (identifier) "PROPERTY_ENABLE" ()) ")" (;) ";" (comment) "/* Set Output Data Rate */" (expression_statement) "stts751_temp_data_rate_set(&stts751_dev_ctx, STTS751_TEMP_ODR_8Hz);" (call_expression) "stts751_temp_data_rate_set(&stts751_dev_ctx, STTS751_TEMP_ODR_8Hz)" (identifier) "stts751_temp_data_rate_set" (argument_list) "(&stts751_dev_ctx, STTS751_TEMP_ODR_8Hz)" (() "(" (pointer_expression) "&stts751_dev_ctx" (&) "&" (identifier) "stts751_dev_ctx" (,) "," (identifier) "STTS751_TEMP_ODR_8Hz" ()) ")" (;) ";" (comment) "/* Set Resolution */" (expression_statement) "stts751_resolution_set(&stts751_dev_ctx, STTS751_12bit);" (call_expression) "stts751_resolution_set(&stts751_dev_ctx, STTS751_12bit)" (identifier) "stts751_resolution_set" (argument_list) "(&stts751_dev_ctx, STTS751_12bit)" (() "(" (pointer_expression) "&stts751_dev_ctx" (&) "&" (identifier) "stts751_dev_ctx" (,) "," (identifier) "STTS751_12bit" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (function_definition) "int32_t platform_write_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n HAL_I2C_Mem_Write(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}" (primitive_type) "int32_t" (function_declarator) "platform_write_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)" (identifier) "platform_write_stts751" (parameter_list) "(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)" (() "(" (parameter_declaration) "void *handle" (primitive_type) "void" (pointer_declarator) "*handle" (*) "*" (identifier) "handle" (,) "," (parameter_declaration) "uint8_t reg" (primitive_type) "uint8_t" (identifier) "reg" (,) "," (parameter_declaration) "uint8_t *bufp" (primitive_type) "uint8_t" (pointer_declarator) "*bufp" (*) "*" (identifier) "bufp" (,) "," (parameter_declaration) "uint16_t len" (primitive_type) "uint16_t" (identifier) "len" ()) ")" (compound_statement) "{\n HAL_I2C_Mem_Write(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}" ({) "{" (expression_statement) "HAL_I2C_Mem_Write(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);" (call_expression) "HAL_I2C_Mem_Write(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)" (identifier) "HAL_I2C_Mem_Write" (argument_list) "(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)" (() "(" (identifier) "handle" (,) "," (identifier) "STTS751_0xxxx_ADD_7K5" (,) "," (identifier) "reg" (,) "," (identifier) "I2C_MEMADD_SIZE_8BIT" (,) "," (identifier) "bufp" (,) "," (identifier) "len" (,) "," (number_literal) "1000" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (function_definition) "int32_t platform_read_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n HAL_I2C_Mem_Read(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}" (primitive_type) "int32_t" (function_declarator) "platform_read_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)" (identifier) "platform_read_stts751" (parameter_list) "(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)" (() "(" (parameter_declaration) "void *handle" (primitive_type) "void" (pointer_declarator) "*handle" (*) "*" (identifier) "handle" (,) "," (parameter_declaration) "uint8_t reg" (primitive_type) "uint8_t" (identifier) "reg" (,) "," (parameter_declaration) "uint8_t *bufp" (primitive_type) "uint8_t" (pointer_declarator) "*bufp" (*) "*" (identifier) "bufp" (,) "," (parameter_declaration) "uint16_t len" (primitive_type) "uint16_t" (identifier) "len" ()) ")" (compound_statement) "{\n HAL_I2C_Mem_Read(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}" ({) "{" (expression_statement) "HAL_I2C_Mem_Read(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);" (call_expression) "HAL_I2C_Mem_Read(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)" (identifier) "HAL_I2C_Mem_Read" (argument_list) "(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)" (() "(" (identifier) "handle" (,) "," (identifier) "STTS751_0xxxx_ADD_7K5" (,) "," (identifier) "reg" (,) "," (identifier) "I2C_MEMADD_SIZE_8BIT" (,) "," (identifier) "bufp" (,) "," (identifier) "len" (,) "," (number_literal) "1000" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (comment) "/*---------- LPS22HH ----------*/" (function_definition) "int init_lps22hh(I2C_HandleTypeDef *lps22hh_bus)\n{\n uint8_t lps22hh_whoamI;\n uint8_t lps22hh_rst;\n\n lps22hh_dev_ctx.write_reg = platform_write_lps22hh;\n lps22hh_dev_ctx.read_reg = platform_read_lps22hh;\n lps22hh_dev_ctx.handle = lps22hh_bus;\n\n lps22hh_device_id_get(&lps22hh_dev_ctx, &lps22hh_whoamI);\n if (lps22hh_whoamI != LPS22HH_ID)\n {\n return -1;\n }\n\n lps22hh_reset_set(&lps22hh_dev_ctx, PROPERTY_ENABLE);\n do {\n lps22hh_reset_get(&lps22hh_dev_ctx, &lps22hh_rst);\n } while (lps22hh_rst);\n\n /* Enable Block Data Update */\n lps22hh_block_data_update_set(&lps22hh_dev_ctx, PROPERTY_ENABLE);\n /* Set Output Data Rate */\n lps22hh_data_rate_set(&lps22hh_dev_ctx, LPS22HH_10_Hz_LOW_NOISE);\n\n return 0;\n}" (primitive_type) "int" (function_declarator) "init_lps22hh(I2C_HandleTypeDef *lps22hh_bus)" (identifier) "init_lps22hh" (parameter_list) "(I2C_HandleTypeDef *lps22hh_bus)" (() "(" (parameter_declaration) "I2C_HandleTypeDef *lps22hh_bus" (type_identifier) "I2C_HandleTypeDef" (pointer_declarator) "*lps22hh_bus" (*) "*" (identifier) "lps22hh_bus" ()) ")" (compound_statement) "{\n uint8_t lps22hh_whoamI;\n uint8_t lps22hh_rst;\n\n lps22hh_dev_ctx.write_reg = platform_write_lps22hh;\n lps22hh_dev_ctx.read_reg = platform_read_lps22hh;\n lps22hh_dev_ctx.handle = lps22hh_bus;\n\n lps22hh_device_id_get(&lps22hh_dev_ctx, &lps22hh_whoamI);\n if (lps22hh_whoamI != LPS22HH_ID)\n {\n return -1;\n }\n\n lps22hh_reset_set(&lps22hh_dev_ctx, PROPERTY_ENABLE);\n do {\n lps22hh_reset_get(&lps22hh_dev_ctx, &lps22hh_rst);\n } while (lps22hh_rst);\n\n /* Enable Block Data Update */\n lps22hh_block_data_update_set(&lps22hh_dev_ctx, PROPERTY_ENABLE);\n /* Set Output Data Rate */\n lps22hh_data_rate_set(&lps22hh_dev_ctx, LPS22HH_10_Hz_LOW_NOISE);\n\n return 0;\n}" ({) "{" (declaration) "uint8_t lps22hh_whoamI;" (primitive_type) "uint8_t" (identifier) "lps22hh_whoamI" (;) ";" (declaration) "uint8_t lps22hh_rst;" (primitive_type) "uint8_t" (identifier) "lps22hh_rst" (;) ";" (expression_statement) "lps22hh_dev_ctx.write_reg = platform_write_lps22hh;" (assignment_expression) "lps22hh_dev_ctx.write_reg = platform_write_lps22hh" (field_expression) "lps22hh_dev_ctx.write_reg" (identifier) "lps22hh_dev_ctx" (.) "." (field_identifier) "write_reg" (=) "=" (identifier) "platform_write_lps22hh" (;) ";" (expression_statement) "lps22hh_dev_ctx.read_reg = platform_read_lps22hh;" (assignment_expression) "lps22hh_dev_ctx.read_reg = platform_read_lps22hh" (field_expression) "lps22hh_dev_ctx.read_reg" (identifier) "lps22hh_dev_ctx" (.) "." (field_identifier) "read_reg" (=) "=" (identifier) "platform_read_lps22hh" (;) ";" (expression_statement) "lps22hh_dev_ctx.handle = lps22hh_bus;" (assignment_expression) "lps22hh_dev_ctx.handle = lps22hh_bus" (field_expression) "lps22hh_dev_ctx.handle" (identifier) "lps22hh_dev_ctx" (.) "." (field_identifier) "handle" (=) "=" (identifier) "lps22hh_bus" (;) ";" (expression_statement) "lps22hh_device_id_get(&lps22hh_dev_ctx, &lps22hh_whoamI);" (call_expression) "lps22hh_device_id_get(&lps22hh_dev_ctx, &lps22hh_whoamI)" (identifier) "lps22hh_device_id_get" (argument_list) "(&lps22hh_dev_ctx, &lps22hh_whoamI)" (() "(" (pointer_expression) "&lps22hh_dev_ctx" (&) "&" (identifier) "lps22hh_dev_ctx" (,) "," (pointer_expression) "&lps22hh_whoamI" (&) "&" (identifier) "lps22hh_whoamI" ()) ")" (;) ";" (if_statement) "if (lps22hh_whoamI != LPS22HH_ID)\n {\n return -1;\n }" (if) "if" (parenthesized_expression) "(lps22hh_whoamI != LPS22HH_ID)" (() "(" (binary_expression) "lps22hh_whoamI != LPS22HH_ID" (identifier) "lps22hh_whoamI" (!=) "!=" (identifier) "LPS22HH_ID" ()) ")" (compound_statement) "{\n return -1;\n }" ({) "{" (return_statement) "return -1;" (return) "return" (number_literal) "-1" (;) ";" (}) "}" (expression_statement) "lps22hh_reset_set(&lps22hh_dev_ctx, PROPERTY_ENABLE);" (call_expression) "lps22hh_reset_set(&lps22hh_dev_ctx, PROPERTY_ENABLE)" (identifier) "lps22hh_reset_set" (argument_list) "(&lps22hh_dev_ctx, PROPERTY_ENABLE)" (() "(" (pointer_expression) "&lps22hh_dev_ctx" (&) "&" (identifier) "lps22hh_dev_ctx" (,) "," (identifier) "PROPERTY_ENABLE" ()) ")" (;) ";" (do_statement) "do {\n lps22hh_reset_get(&lps22hh_dev_ctx, &lps22hh_rst);\n } while (lps22hh_rst);" (do) "do" (compound_statement) "{\n lps22hh_reset_get(&lps22hh_dev_ctx, &lps22hh_rst);\n }" ({) "{" (expression_statement) "lps22hh_reset_get(&lps22hh_dev_ctx, &lps22hh_rst);" (call_expression) "lps22hh_reset_get(&lps22hh_dev_ctx, &lps22hh_rst)" (identifier) "lps22hh_reset_get" (argument_list) "(&lps22hh_dev_ctx, &lps22hh_rst)" (() "(" (pointer_expression) "&lps22hh_dev_ctx" (&) "&" (identifier) "lps22hh_dev_ctx" (,) "," (pointer_expression) "&lps22hh_rst" (&) "&" (identifier) "lps22hh_rst" ()) ")" (;) ";" (}) "}" (while) "while" (parenthesized_expression) "(lps22hh_rst)" (() "(" (identifier) "lps22hh_rst" ()) ")" (;) ";" (comment) "/* Enable Block Data Update */" (expression_statement) "lps22hh_block_data_update_set(&lps22hh_dev_ctx, PROPERTY_ENABLE);" (call_expression) "lps22hh_block_data_update_set(&lps22hh_dev_ctx, PROPERTY_ENABLE)" (identifier) "lps22hh_block_data_update_set" (argument_list) "(&lps22hh_dev_ctx, PROPERTY_ENABLE)" (() "(" (pointer_expression) "&lps22hh_dev_ctx" (&) "&" (identifier) "lps22hh_dev_ctx" (,) "," (identifier) "PROPERTY_ENABLE" ()) ")" (;) ";" (comment) "/* Set Output Data Rate */" (expression_statement) "lps22hh_data_rate_set(&lps22hh_dev_ctx, LPS22HH_10_Hz_LOW_NOISE);" (call_expression) "lps22hh_data_rate_set(&lps22hh_dev_ctx, LPS22HH_10_Hz_LOW_NOISE)" (identifier) "lps22hh_data_rate_set" (argument_list) "(&lps22hh_dev_ctx, LPS22HH_10_Hz_LOW_NOISE)" (() "(" (pointer_expression) "&lps22hh_dev_ctx" (&) "&" (identifier) "lps22hh_dev_ctx" (,) "," (identifier) "LPS22HH_10_Hz_LOW_NOISE" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (function_definition) "int32_t platform_write_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n HAL_I2C_Mem_Write(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}" (primitive_type) "int32_t" (function_declarator) "platform_write_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)" (identifier) "platform_write_lps22hh" (parameter_list) "(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)" (() "(" (parameter_declaration) "void *handle" (primitive_type) "void" (pointer_declarator) "*handle" (*) "*" (identifier) "handle" (,) "," (parameter_declaration) "uint8_t reg" (primitive_type) "uint8_t" (identifier) "reg" (,) "," (parameter_declaration) "uint8_t *bufp" (primitive_type) "uint8_t" (pointer_declarator) "*bufp" (*) "*" (identifier) "bufp" (,) "," (parameter_declaration) "uint16_t len" (primitive_type) "uint16_t" (identifier) "len" ()) ")" (compound_statement) "{\n HAL_I2C_Mem_Write(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}" ({) "{" (expression_statement) "HAL_I2C_Mem_Write(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);" (call_expression) "HAL_I2C_Mem_Write(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)" (identifier) "HAL_I2C_Mem_Write" (argument_list) "(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)" (() "(" (identifier) "handle" (,) "," (identifier) "LPS22HH_I2C_ADD_H" (,) "," (identifier) "reg" (,) "," (identifier) "I2C_MEMADD_SIZE_8BIT" (,) "," (identifier) "bufp" (,) "," (identifier) "len" (,) "," (number_literal) "1000" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (function_definition) "int32_t platform_read_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n HAL_I2C_Mem_Read(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n}" (primitive_type) "int32_t" (function_declarator) "platform_read_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)" (identifier) "platform_read_lps22hh" (parameter_list) "(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)" (() "(" (parameter_declaration) "void *handle" (primitive_type) "void" (pointer_declarator) "*handle" (*) "*" (identifier) "handle" (,) "," (parameter_declaration) "uint8_t reg" (primitive_type) "uint8_t" (identifier) "reg" (,) "," (parameter_declaration) "uint8_t *bufp" (primitive_type) "uint8_t" (pointer_declarator) "*bufp" (*) "*" (identifier) "bufp" (,) "," (parameter_declaration) "uint16_t len" (primitive_type) "uint16_t" (identifier) "len" ()) ")" (compound_statement) "{\n HAL_I2C_Mem_Read(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n}" ({) "{" (expression_statement) "HAL_I2C_Mem_Read(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);" (call_expression) "HAL_I2C_Mem_Read(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)" (identifier) "HAL_I2C_Mem_Read" (argument_list) "(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)" (() "(" (identifier) "handle" (,) "," (identifier) "LPS22HH_I2C_ADD_H" (,) "," (identifier) "reg" (,) "," (identifier) "I2C_MEMADD_SIZE_8BIT" (,) "," (identifier) "bufp" (,) "," (identifier) "len" (,) "," (number_literal) "1000" ()) ")" (;) ";" (}) "}" (comment) "/*---------- HTS221 ----------*/" (function_definition) "int init_hts221(I2C_HandleTypeDef *hts221_bus)\n{\n uint8_t hts221_whoamI;\n\n hts221_dev_ctx.write_reg = platform_write_hts221;\n hts221_dev_ctx.read_reg = platform_read_hts221;\n hts221_dev_ctx.handle = hts221_bus;\n\n hts221_whoamI = 0;\n hts221_device_id_get(&hts221_dev_ctx, &hts221_whoamI);\n if (hts221_whoamI != HTS221_ID)\n {\n return -1;\n }\n\n hts221_hum_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.x0);\n hts221_hum_rh_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.y0);\n hts221_hum_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.x1);\n hts221_hum_rh_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.y1);\n /* Read temperature calibration coefficient */\n hts221_temp_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.x0);\n hts221_temp_deg_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.y0);\n hts221_temp_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.x1);\n hts221_temp_deg_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.y1);\n /* Enable Block Data Update */\n hts221_block_data_update_set(&hts221_dev_ctx, PROPERTY_ENABLE);\n /* Set Output Data Rate */\n hts221_data_rate_set(&hts221_dev_ctx, HTS221_ODR_7Hz);\n /* Device power on */\n hts221_power_on_set(&hts221_dev_ctx, PROPERTY_ENABLE);\n\n return 0;\n}" (primitive_type) "int" (function_declarator) "init_hts221(I2C_HandleTypeDef *hts221_bus)" (identifier) "init_hts221" (parameter_list) "(I2C_HandleTypeDef *hts221_bus)" (() "(" (parameter_declaration) "I2C_HandleTypeDef *hts221_bus" (type_identifier) "I2C_HandleTypeDef" (pointer_declarator) "*hts221_bus" (*) "*" (identifier) "hts221_bus" ()) ")" (compound_statement) "{\n uint8_t hts221_whoamI;\n\n hts221_dev_ctx.write_reg = platform_write_hts221;\n hts221_dev_ctx.read_reg = platform_read_hts221;\n hts221_dev_ctx.handle = hts221_bus;\n\n hts221_whoamI = 0;\n hts221_device_id_get(&hts221_dev_ctx, &hts221_whoamI);\n if (hts221_whoamI != HTS221_ID)\n {\n return -1;\n }\n\n hts221_hum_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.x0);\n hts221_hum_rh_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.y0);\n hts221_hum_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.x1);\n hts221_hum_rh_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.y1);\n /* Read temperature calibration coefficient */\n hts221_temp_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.x0);\n hts221_temp_deg_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.y0);\n hts221_temp_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.x1);\n hts221_temp_deg_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.y1);\n /* Enable Block Data Update */\n hts221_block_data_update_set(&hts221_dev_ctx, PROPERTY_ENABLE);\n /* Set Output Data Rate */\n hts221_data_rate_set(&hts221_dev_ctx, HTS221_ODR_7Hz);\n /* Device power on */\n hts221_power_on_set(&hts221_dev_ctx, PROPERTY_ENABLE);\n\n return 0;\n}" ({) "{" (declaration) "uint8_t hts221_whoamI;" (primitive_type) "uint8_t" (identifier) "hts221_whoamI" (;) ";" (expression_statement) "hts221_dev_ctx.write_reg = platform_write_hts221;" (assignment_expression) "hts221_dev_ctx.write_reg = platform_write_hts221" (field_expression) "hts221_dev_ctx.write_reg" (identifier) "hts221_dev_ctx" (.) "." (field_identifier) "write_reg" (=) "=" (identifier) "platform_write_hts221" (;) ";" (expression_statement) "hts221_dev_ctx.read_reg = platform_read_hts221;" (assignment_expression) "hts221_dev_ctx.read_reg = platform_read_hts221" (field_expression) "hts221_dev_ctx.read_reg" (identifier) "hts221_dev_ctx" (.) "." (field_identifier) "read_reg" (=) "=" (identifier) "platform_read_hts221" (;) ";" (expression_statement) "hts221_dev_ctx.handle = hts221_bus;" (assignment_expression) "hts221_dev_ctx.handle = hts221_bus" (field_expression) "hts221_dev_ctx.handle" (identifier) "hts221_dev_ctx" (.) "." (field_identifier) "handle" (=) "=" (identifier) "hts221_bus" (;) ";" (expression_statement) "hts221_whoamI = 0;" (assignment_expression) "hts221_whoamI = 0" (identifier) "hts221_whoamI" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "hts221_device_id_get(&hts221_dev_ctx, &hts221_whoamI);" (call_expression) "hts221_device_id_get(&hts221_dev_ctx, &hts221_whoamI)" (identifier) "hts221_device_id_get" (argument_list) "(&hts221_dev_ctx, &hts221_whoamI)" (() "(" (pointer_expression) "&hts221_dev_ctx" (&) "&" (identifier) "hts221_dev_ctx" (,) "," (pointer_expression) "&hts221_whoamI" (&) "&" (identifier) "hts221_whoamI" ()) ")" (;) ";" (if_statement) "if (hts221_whoamI != HTS221_ID)\n {\n return -1;\n }" (if) "if" (parenthesized_expression) "(hts221_whoamI != HTS221_ID)" (() "(" (binary_expression) "hts221_whoamI != HTS221_ID" (identifier) "hts221_whoamI" (!=) "!=" (identifier) "HTS221_ID" ()) ")" (compound_statement) "{\n return -1;\n }" ({) "{" (return_statement) "return -1;" (return) "return" (number_literal) "-1" (;) ";" (}) "}" (expression_statement) "hts221_hum_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.x0);" (call_expression) "hts221_hum_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.x0)" (identifier) "hts221_hum_adc_point_0_get" (argument_list) "(&hts221_dev_ctx, &hts221_lin_hum.x0)" (() "(" (pointer_expression) "&hts221_dev_ctx" (&) "&" (identifier) "hts221_dev_ctx" (,) "," (pointer_expression) "&hts221_lin_hum.x0" (&) "&" (field_expression) "hts221_lin_hum.x0" (identifier) "hts221_lin_hum" (.) "." (field_identifier) "x0" ()) ")" (;) ";" (expression_statement) "hts221_hum_rh_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.y0);" (call_expression) "hts221_hum_rh_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.y0)" (identifier) "hts221_hum_rh_point_0_get" (argument_list) "(&hts221_dev_ctx, &hts221_lin_hum.y0)" (() "(" (pointer_expression) "&hts221_dev_ctx" (&) "&" (identifier) "hts221_dev_ctx" (,) "," (pointer_expression) "&hts221_lin_hum.y0" (&) "&" (field_expression) "hts221_lin_hum.y0" (identifier) "hts221_lin_hum" (.) "." (field_identifier) "y0" ()) ")" (;) ";" (expression_statement) "hts221_hum_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.x1);" (call_expression) "hts221_hum_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.x1)" (identifier) "hts221_hum_adc_point_1_get" (argument_list) "(&hts221_dev_ctx, &hts221_lin_hum.x1)" (() "(" (pointer_expression) "&hts221_dev_ctx" (&) "&" (identifier) "hts221_dev_ctx" (,) "," (pointer_expression) "&hts221_lin_hum.x1" (&) "&" (field_expression) "hts221_lin_hum.x1" (identifier) "hts221_lin_hum" (.) "." (field_identifier) "x1" ()) ")" (;) ";" (expression_statement) "hts221_hum_rh_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.y1);" (call_expression) "hts221_hum_rh_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.y1)" (identifier) "hts221_hum_rh_point_1_get" (argument_list) "(&hts221_dev_ctx, &hts221_lin_hum.y1)" (() "(" (pointer_expression) "&hts221_dev_ctx" (&) "&" (identifier) "hts221_dev_ctx" (,) "," (pointer_expression) "&hts221_lin_hum.y1" (&) "&" (field_expression) "hts221_lin_hum.y1" (identifier) "hts221_lin_hum" (.) "." (field_identifier) "y1" ()) ")" (;) ";" (comment) "/* Read temperature calibration coefficient */" (expression_statement) "hts221_temp_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.x0);" (call_expression) "hts221_temp_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.x0)" (identifier) "hts221_temp_adc_point_0_get" (argument_list) "(&hts221_dev_ctx, &hts221_lin_temp.x0)" (() "(" (pointer_expression) "&hts221_dev_ctx" (&) "&" (identifier) "hts221_dev_ctx" (,) "," (pointer_expression) "&hts221_lin_temp.x0" (&) "&" (field_expression) "hts221_lin_temp.x0" (identifier) "hts221_lin_temp" (.) "." (field_identifier) "x0" ()) ")" (;) ";" (expression_statement) "hts221_temp_deg_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.y0);" (call_expression) "hts221_temp_deg_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.y0)" (identifier) "hts221_temp_deg_point_0_get" (argument_list) "(&hts221_dev_ctx, &hts221_lin_temp.y0)" (() "(" (pointer_expression) "&hts221_dev_ctx" (&) "&" (identifier) "hts221_dev_ctx" (,) "," (pointer_expression) "&hts221_lin_temp.y0" (&) "&" (field_expression) "hts221_lin_temp.y0" (identifier) "hts221_lin_temp" (.) "." (field_identifier) "y0" ()) ")" (;) ";" (expression_statement) "hts221_temp_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.x1);" (call_expression) "hts221_temp_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.x1)" (identifier) "hts221_temp_adc_point_1_get" (argument_list) "(&hts221_dev_ctx, &hts221_lin_temp.x1)" (() "(" (pointer_expression) "&hts221_dev_ctx" (&) "&" (identifier) "hts221_dev_ctx" (,) "," (pointer_expression) "&hts221_lin_temp.x1" (&) "&" (field_expression) "hts221_lin_temp.x1" (identifier) "hts221_lin_temp" (.) "." (field_identifier) "x1" ()) ")" (;) ";" (expression_statement) "hts221_temp_deg_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.y1);" (call_expression) "hts221_temp_deg_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.y1)" (identifier) "hts221_temp_deg_point_1_get" (argument_list) "(&hts221_dev_ctx, &hts221_lin_temp.y1)" (() "(" (pointer_expression) "&hts221_dev_ctx" (&) "&" (identifier) "hts221_dev_ctx" (,) "," (pointer_expression) "&hts221_lin_temp.y1" (&) "&" (field_expression) "hts221_lin_temp.y1" (identifier) "hts221_lin_temp" (.) "." (field_identifier) "y1" ()) ")" (;) ";" (comment) "/* Enable Block Data Update */" (expression_statement) "hts221_block_data_update_set(&hts221_dev_ctx, PROPERTY_ENABLE);" (call_expression) "hts221_block_data_update_set(&hts221_dev_ctx, PROPERTY_ENABLE)" (identifier) "hts221_block_data_update_set" (argument_list) "(&hts221_dev_ctx, PROPERTY_ENABLE)" (() "(" (pointer_expression) "&hts221_dev_ctx" (&) "&" (identifier) "hts221_dev_ctx" (,) "," (identifier) "PROPERTY_ENABLE" ()) ")" (;) ";" (comment) "/* Set Output Data Rate */" (expression_statement) "hts221_data_rate_set(&hts221_dev_ctx, HTS221_ODR_7Hz);" (call_expression) "hts221_data_rate_set(&hts221_dev_ctx, HTS221_ODR_7Hz)" (identifier) "hts221_data_rate_set" (argument_list) "(&hts221_dev_ctx, HTS221_ODR_7Hz)" (() "(" (pointer_expression) "&hts221_dev_ctx" (&) "&" (identifier) "hts221_dev_ctx" (,) "," (identifier) "HTS221_ODR_7Hz" ()) ")" (;) ";" (comment) "/* Device power on */" (expression_statement) "hts221_power_on_set(&hts221_dev_ctx, PROPERTY_ENABLE);" (call_expression) "hts221_power_on_set(&hts221_dev_ctx, PROPERTY_ENABLE)" (identifier) "hts221_power_on_set" (argument_list) "(&hts221_dev_ctx, PROPERTY_ENABLE)" (() "(" (pointer_expression) "&hts221_dev_ctx" (&) "&" (identifier) "hts221_dev_ctx" (,) "," (identifier) "PROPERTY_ENABLE" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (function_definition) "float linear_interpolation(lin_t *lin, int16_t x)\n{\n return ((lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) -\n (lin->x0 * lin->y1))) / (lin->x1 - lin->x0);\n}" (primitive_type) "float" (function_declarator) "linear_interpolation(lin_t *lin, int16_t x)" (identifier) "linear_interpolation" (parameter_list) "(lin_t *lin, int16_t x)" (() "(" (parameter_declaration) "lin_t *lin" (type_identifier) "lin_t" (pointer_declarator) "*lin" (*) "*" (identifier) "lin" (,) "," (parameter_declaration) "int16_t x" (primitive_type) "int16_t" (identifier) "x" ()) ")" (compound_statement) "{\n return ((lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) -\n (lin->x0 * lin->y1))) / (lin->x1 - lin->x0);\n}" ({) "{" (return_statement) "return ((lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) -\n (lin->x0 * lin->y1))) / (lin->x1 - lin->x0);" (return) "return" (binary_expression) "((lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) -\n (lin->x0 * lin->y1))) / (lin->x1 - lin->x0)" (parenthesized_expression) "((lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) -\n (lin->x0 * lin->y1)))" (() "(" (binary_expression) "(lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) -\n (lin->x0 * lin->y1))" (binary_expression) "(lin->y1 - lin->y0) * x" (parenthesized_expression) "(lin->y1 - lin->y0)" (() "(" (binary_expression) "lin->y1 - lin->y0" (field_expression) "lin->y1" (identifier) "lin" (->) "->" (field_identifier) "y1" (-) "-" (field_expression) "lin->y0" (identifier) "lin" (->) "->" (field_identifier) "y0" ()) ")" (*) "*" (identifier) "x" (+) "+" (parenthesized_expression) "((lin->x1 * lin->y0) -\n (lin->x0 * lin->y1))" (() "(" (binary_expression) "(lin->x1 * lin->y0) -\n (lin->x0 * lin->y1)" (parenthesized_expression) "(lin->x1 * lin->y0)" (() "(" (binary_expression) "lin->x1 * lin->y0" (field_expression) "lin->x1" (identifier) "lin" (->) "->" (field_identifier) "x1" (*) "*" (field_expression) "lin->y0" (identifier) "lin" (->) "->" (field_identifier) "y0" ()) ")" (-) "-" (parenthesized_expression) "(lin->x0 * lin->y1)" (() "(" (binary_expression) "lin->x0 * lin->y1" (field_expression) "lin->x0" (identifier) "lin" (->) "->" (field_identifier) "x0" (*) "*" (field_expression) "lin->y1" (identifier) "lin" (->) "->" (field_identifier) "y1" ()) ")" ()) ")" ()) ")" (/) "/" (parenthesized_expression) "(lin->x1 - lin->x0)" (() "(" (binary_expression) "lin->x1 - lin->x0" (field_expression) "lin->x1" (identifier) "lin" (->) "->" (field_identifier) "x1" (-) "-" (field_expression) "lin->x0" (identifier) "lin" (->) "->" (field_identifier) "x0" ()) ")" (;) ";" (}) "}" (function_definition) "int32_t platform_write_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)\n{\n reg |= 0x80;\n HAL_I2C_Mem_Write(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}" (primitive_type) "int32_t" (function_declarator) "platform_write_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)" (identifier) "platform_write_hts221" (parameter_list) "(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)" (() "(" (parameter_declaration) "void *handle" (primitive_type) "void" (pointer_declarator) "*handle" (*) "*" (identifier) "handle" (,) "," (parameter_declaration) "uint8_t reg" (primitive_type) "uint8_t" (identifier) "reg" (,) "," (parameter_declaration) "uint8_t *bufp" (primitive_type) "uint8_t" (pointer_declarator) "*bufp" (*) "*" (identifier) "bufp" (,) "," (parameter_declaration) "uint16_t len" (primitive_type) "uint16_t" (identifier) "len" ()) ")" (compound_statement) "{\n reg |= 0x80;\n HAL_I2C_Mem_Write(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}" ({) "{" (expression_statement) "reg |= 0x80;" (assignment_expression) "reg |= 0x80" (identifier) "reg" (|=) "|=" (number_literal) "0x80" (;) ";" (expression_statement) "HAL_I2C_Mem_Write(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);" (call_expression) "HAL_I2C_Mem_Write(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)" (identifier) "HAL_I2C_Mem_Write" (argument_list) "(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)" (() "(" (identifier) "handle" (,) "," (identifier) "HTS221_I2C_ADDRESS" (,) "," (identifier) "reg" (,) "," (identifier) "I2C_MEMADD_SIZE_8BIT" (,) "," (identifier) "bufp" (,) "," (identifier) "len" (,) "," (number_literal) "1000" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (function_definition) "int32_t platform_read_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)\n{\n reg |= 0x80;\n HAL_I2C_Mem_Read(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}" (primitive_type) "int32_t" (function_declarator) "platform_read_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)" (identifier) "platform_read_hts221" (parameter_list) "(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)" (() "(" (parameter_declaration) "void *handle" (primitive_type) "void" (pointer_declarator) "*handle" (*) "*" (identifier) "handle" (,) "," (parameter_declaration) "uint8_t reg" (primitive_type) "uint8_t" (identifier) "reg" (,) "," (parameter_declaration) "uint8_t *bufp" (primitive_type) "uint8_t" (pointer_declarator) "*bufp" (*) "*" (identifier) "bufp" (,) "," (parameter_declaration) "uint16_t len" (primitive_type) "uint16_t" (identifier) "len" ()) ")" (compound_statement) "{\n reg |= 0x80;\n HAL_I2C_Mem_Read(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}" ({) "{" (expression_statement) "reg |= 0x80;" (assignment_expression) "reg |= 0x80" (identifier) "reg" (|=) "|=" (number_literal) "0x80" (;) ";" (expression_statement) "HAL_I2C_Mem_Read(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);" (call_expression) "HAL_I2C_Mem_Read(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)" (identifier) "HAL_I2C_Mem_Read" (argument_list) "(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)" (() "(" (identifier) "handle" (,) "," (identifier) "HTS221_I2C_ADDRESS" (,) "," (identifier) "reg" (,) "," (identifier) "I2C_MEMADD_SIZE_8BIT" (,) "," (identifier) "bufp" (,) "," (identifier) "len" (,) "," (number_literal) "1000" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (comment) "/*---------- ISM330 ----------*/" (comment) "/*\nint init_ism330(SPI_HandleTypeDef *ism330_bus)\n{\n ism330_dev_ctx.write_reg = platform_write;\n ism330_dev_ctx.read_reg = platform_read;\n ism330_dev_ctx.handle = &ism330_bus;\n\n ism330dhcx_device_id_get(&ism330_dev_ctx, &ism330_whoamI);\n if (ism330_whoamI != ISM330DHCX_ID)\n {\n return -1;\n }\n\n ism330dhcx_reset_set(&ism330_dev_ctx, PROPERTY_ENABLE);\n do\n {\n ism330dhcx_reset_get(&ism330_dev_ctx, &ism330_rst);\n } while (ism330_rst);\n\n //* Enable Block Data Update *\n ism330dhcx_block_data_update_set(&ism330_dev_ctx, PROPERTY_ENABLE);\n //* Set Output Data Rate\n ism330dhcx_xl_data_rate_set(&ism330_dev_ctx, ISM330DHCX_XL_ODR_12Hz5);\n ism330dhcx_gy_data_rate_set(&ism330_dev_ctx, ISM330DHCX_GY_ODR_12Hz5);\n //* Set full scale *\n ism330dhcx_xl_full_scale_set(&ism330_dev_ctx, ISM330DHCX_2g);\n ism330dhcx_gy_full_scale_set(&ism330_dev_ctx, ISM330DHCX_2000dps);\n //* Configure filtering chain(No aux interface) *\n ism330dhcx_xl_hp_path_on_out_set(&ism330_dev_ctx, ISM330DHCX_LP_ODR_DIV_100);\n ism330dhcx_xl_filter_lp2_set(&ism330_dev_ctx, PROPERTY_ENABLE);\n\n return 0;\n}\n*/"
1,403
0
{"language": "c", "success": true, "metadata": {"lines": 228, "avg_line_length": 35.14, "nodes": 804, "errors": 0, "source_hash": "cb1b342ade75caafe3246c10975ce643d91bc144e2214099a250a21e27feb2b6", "categorized_nodes": 598}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"init_stwin_sensors.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 19, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"init_stwin_sensors.h\"", "parent": 0, "children": [], "start_point": {"row": 18, "column": 9}, "end_point": {"row": 18, "column": 31}}, {"id": 3, "type": "function_definition", "text": "int init_sensors(UART_HandleTypeDef *UART_bus, I2C_HandleTypeDef *stts751_bus, I2C_HandleTypeDef *lps22hh_bus,\n\t\tI2C_HandleTypeDef *hts221_bus, SPI_HandleTypeDef *ism330_bus)\n{\n\tuint16_t uart_buf_len;\n\tuint8_t uart_buf[500] = \"\";\n\n\t/*-------- START --------*/\n\tuart_buf_len = sprintf(uart_buf, \"---- Demarrage de l'UART ----\\r\\n\");\n\tHAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\n\t/*-------- STTS751 --------*/\n\tif (init_stts751(stts751_bus) == 0)\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init STTS751 OK\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t}\n\telse\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init STTS751 Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -1;\n\t}\n\n\t/*-------- LPS22HH --------*/\n\tif (init_lps22hh(lps22hh_bus) == 0)\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init LPS22HH OK\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t}\n\telse\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init LPS22HH Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -2;\n\t}\n\n\t/*-------- HTS221 --------*/\n\n\tif (init_hts221(hts221_bus) == 0)\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init HTS221 OK\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t}\n\telse\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init HTS221 Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -3;\n\t}\n\n\n\t/*-------- ISM330 --------*/\n\t/*\n\tif (init_ism330(ism330_bus) == 0)\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init ISM330 OK\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t}\n\telse\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init ISM330 Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -4;\n\t}\n\t*/\n\n\treturn 0;\n}", "parent": null, "children": [4, 5], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 88, "column": 1}}, {"id": 4, "type": "primitive_type", "text": "int", "parent": 3, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 3}}, {"id": 5, "type": "function_declarator", "text": "init_sensors(UART_HandleTypeDef *UART_bus, I2C_HandleTypeDef *stts751_bus, I2C_HandleTypeDef *lps22hh_bus,\n\t\tI2C_HandleTypeDef *hts221_bus, SPI_HandleTypeDef *ism330_bus)", "parent": 3, "children": [6, 7], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 22, "column": 63}}, {"id": 6, "type": "identifier", "text": "init_sensors", "parent": 5, "children": [], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 21, "column": 16}}, {"id": 7, "type": "parameter_list", "text": "(UART_HandleTypeDef *UART_bus, I2C_HandleTypeDef *stts751_bus, I2C_HandleTypeDef *lps22hh_bus,\n\t\tI2C_HandleTypeDef *hts221_bus, SPI_HandleTypeDef *ism330_bus)", "parent": 5, "children": [8, 13, 18, 23, 28], "start_point": {"row": 21, "column": 16}, "end_point": {"row": 22, "column": 63}}, {"id": 8, "type": "parameter_declaration", "text": "UART_HandleTypeDef *UART_bus", "parent": 7, "children": [9, 10], "start_point": {"row": 21, "column": 17}, "end_point": {"row": 21, "column": 45}}, {"id": 9, "type": "type_identifier", "text": "UART_HandleTypeDef", "parent": 8, "children": [], "start_point": {"row": 21, "column": 17}, "end_point": {"row": 21, "column": 35}}, {"id": 10, "type": "pointer_declarator", "text": "*UART_bus", "parent": 8, "children": [11, 12], "start_point": {"row": 21, "column": 36}, "end_point": {"row": 21, "column": 45}}, {"id": 11, "type": "*", "text": "*", "parent": 10, "children": [], "start_point": {"row": 21, "column": 36}, "end_point": {"row": 21, "column": 37}}, {"id": 12, "type": "identifier", "text": "UART_bus", "parent": 10, "children": [], "start_point": {"row": 21, "column": 37}, "end_point": {"row": 21, "column": 45}}, {"id": 13, "type": "parameter_declaration", "text": "I2C_HandleTypeDef *stts751_bus", "parent": 7, "children": [14, 15], "start_point": {"row": 21, "column": 47}, "end_point": {"row": 21, "column": 77}}, {"id": 14, "type": "type_identifier", "text": "I2C_HandleTypeDef", "parent": 13, "children": [], "start_point": {"row": 21, "column": 47}, "end_point": {"row": 21, "column": 64}}, {"id": 15, "type": "pointer_declarator", "text": "*stts751_bus", "parent": 13, "children": [16, 17], "start_point": {"row": 21, "column": 65}, "end_point": {"row": 21, "column": 77}}, {"id": 16, "type": "*", "text": "*", "parent": 15, "children": [], "start_point": {"row": 21, "column": 65}, "end_point": {"row": 21, "column": 66}}, {"id": 17, "type": "identifier", "text": "stts751_bus", "parent": 15, "children": [], "start_point": {"row": 21, "column": 66}, "end_point": {"row": 21, "column": 77}}, {"id": 18, "type": "parameter_declaration", "text": "I2C_HandleTypeDef *lps22hh_bus", "parent": 7, "children": [19, 20], "start_point": {"row": 21, "column": 79}, "end_point": {"row": 21, "column": 109}}, {"id": 19, "type": "type_identifier", "text": "I2C_HandleTypeDef", "parent": 18, "children": [], "start_point": {"row": 21, "column": 79}, "end_point": {"row": 21, "column": 96}}, {"id": 20, "type": "pointer_declarator", "text": "*lps22hh_bus", "parent": 18, "children": [21, 22], "start_point": {"row": 21, "column": 97}, "end_point": {"row": 21, "column": 109}}, {"id": 21, "type": "*", "text": "*", "parent": 20, "children": [], "start_point": {"row": 21, "column": 97}, "end_point": {"row": 21, "column": 98}}, {"id": 22, "type": "identifier", "text": "lps22hh_bus", "parent": 20, "children": [], "start_point": {"row": 21, "column": 98}, "end_point": {"row": 21, "column": 109}}, {"id": 23, "type": "parameter_declaration", "text": "I2C_HandleTypeDef *hts221_bus", "parent": 7, "children": [24, 25], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 22, "column": 31}}, {"id": 24, "type": "type_identifier", "text": "I2C_HandleTypeDef", "parent": 23, "children": [], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 22, "column": 19}}, {"id": 25, "type": "pointer_declarator", "text": "*hts221_bus", "parent": 23, "children": [26, 27], "start_point": {"row": 22, "column": 20}, "end_point": {"row": 22, "column": 31}}, {"id": 26, "type": "*", "text": "*", "parent": 25, "children": [], "start_point": {"row": 22, "column": 20}, "end_point": {"row": 22, "column": 21}}, {"id": 27, "type": "identifier", "text": "hts221_bus", "parent": 25, "children": [], "start_point": {"row": 22, "column": 21}, "end_point": {"row": 22, "column": 31}}, {"id": 28, "type": "parameter_declaration", "text": "SPI_HandleTypeDef *ism330_bus", "parent": 7, "children": [29, 30], "start_point": {"row": 22, "column": 33}, "end_point": {"row": 22, "column": 62}}, {"id": 29, "type": "type_identifier", "text": "SPI_HandleTypeDef", "parent": 28, "children": [], "start_point": {"row": 22, "column": 33}, "end_point": {"row": 22, "column": 50}}, {"id": 30, "type": "pointer_declarator", "text": "*ism330_bus", "parent": 28, "children": [31, 32], "start_point": {"row": 22, "column": 51}, "end_point": {"row": 22, "column": 62}}, {"id": 31, "type": "*", "text": "*", "parent": 30, "children": [], "start_point": {"row": 22, "column": 51}, "end_point": {"row": 22, "column": 52}}, {"id": 32, "type": "identifier", "text": "ism330_bus", "parent": 30, "children": [], "start_point": {"row": 22, "column": 52}, "end_point": {"row": 22, "column": 62}}, {"id": 33, "type": "declaration", "text": "uint16_t uart_buf_len;", "parent": 3, "children": [34, 35], "start_point": {"row": 24, "column": 1}, "end_point": {"row": 24, "column": 23}}, {"id": 34, "type": "primitive_type", "text": "uint16_t", "parent": 33, "children": [], "start_point": {"row": 24, "column": 1}, "end_point": {"row": 24, "column": 9}}, {"id": 35, "type": "identifier", "text": "uart_buf_len", "parent": 33, "children": [], "start_point": {"row": 24, "column": 10}, "end_point": {"row": 24, "column": 22}}, {"id": 36, "type": "declaration", "text": "uint8_t uart_buf[500] = \"\";", "parent": 3, "children": [37, 38], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 25, "column": 28}}, {"id": 37, "type": "primitive_type", "text": "uint8_t", "parent": 36, "children": [], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 25, "column": 8}}, {"id": 38, "type": "init_declarator", "text": "uart_buf[500] = \"\"", "parent": 36, "children": [39, 42, 43], "start_point": {"row": 25, "column": 9}, "end_point": {"row": 25, "column": 27}}, {"id": 39, "type": "array_declarator", "text": "uart_buf[500]", "parent": 38, "children": [40, 41], "start_point": {"row": 25, "column": 9}, "end_point": {"row": 25, "column": 22}}, {"id": 40, "type": "identifier", "text": "uart_buf", "parent": 39, "children": [], "start_point": {"row": 25, "column": 9}, "end_point": {"row": 25, "column": 17}}, {"id": 41, "type": "number_literal", "text": "500", "parent": 39, "children": [], "start_point": {"row": 25, "column": 18}, "end_point": {"row": 25, "column": 21}}, {"id": 42, "type": "=", "text": "=", "parent": 38, "children": [], "start_point": {"row": 25, "column": 23}, "end_point": {"row": 25, "column": 24}}, {"id": 43, "type": "string_literal", "text": "\"\"", "parent": 38, "children": [], "start_point": {"row": 25, "column": 25}, "end_point": {"row": 25, "column": 27}}, {"id": 44, "type": "assignment_expression", "text": "uart_buf_len = sprintf(uart_buf, \"---- Demarrage de l'UART ----\\r\\n\")", "parent": 3, "children": [45, 46, 47], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 28, "column": 70}}, {"id": 45, "type": "identifier", "text": "uart_buf_len", "parent": 44, "children": [], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 28, "column": 13}}, {"id": 46, "type": "=", "text": "=", "parent": 44, "children": [], "start_point": {"row": 28, "column": 14}, "end_point": {"row": 28, "column": 15}}, {"id": 47, "type": "call_expression", "text": "sprintf(uart_buf, \"---- Demarrage de l'UART ----\\r\\n\")", "parent": 44, "children": [48, 49], "start_point": {"row": 28, "column": 16}, "end_point": {"row": 28, "column": 70}}, {"id": 48, "type": "identifier", "text": "sprintf", "parent": 47, "children": [], "start_point": {"row": 28, "column": 16}, "end_point": {"row": 28, "column": 23}}, {"id": 49, "type": "argument_list", "text": "(uart_buf, \"---- Demarrage de l'UART ----\\r\\n\")", "parent": 47, "children": [50, 51], "start_point": {"row": 28, "column": 23}, "end_point": {"row": 28, "column": 70}}, {"id": 50, "type": "identifier", "text": "uart_buf", "parent": 49, "children": [], "start_point": {"row": 28, "column": 24}, "end_point": {"row": 28, "column": 32}}, {"id": 51, "type": "string_literal", "text": "\"---- Demarrage de l'UART ----\\r\\n\"", "parent": 49, "children": [52, 53], "start_point": {"row": 28, "column": 34}, "end_point": {"row": 28, "column": 69}}, {"id": 52, "type": "escape_sequence", "text": "\\r", "parent": 51, "children": [], "start_point": {"row": 28, "column": 64}, "end_point": {"row": 28, "column": 66}}, {"id": 53, "type": "escape_sequence", "text": "\\n", "parent": 51, "children": [], "start_point": {"row": 28, "column": 66}, "end_point": {"row": 28, "column": 68}}, {"id": 54, "type": "call_expression", "text": "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 3, "children": [55, 56], "start_point": {"row": 29, "column": 1}, "end_point": {"row": 29, "column": 57}}, {"id": 55, "type": "identifier", "text": "HAL_UART_Transmit", "parent": 54, "children": [], "start_point": {"row": 29, "column": 1}, "end_point": {"row": 29, "column": 18}}, {"id": 56, "type": "argument_list", "text": "(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 54, "children": [57, 58, 59, 60], "start_point": {"row": 29, "column": 18}, "end_point": {"row": 29, "column": 57}}, {"id": 57, "type": "identifier", "text": "UART_bus", "parent": 56, "children": [], "start_point": {"row": 29, "column": 19}, "end_point": {"row": 29, "column": 27}}, {"id": 58, "type": "identifier", "text": "uart_buf", "parent": 56, "children": [], "start_point": {"row": 29, "column": 29}, "end_point": {"row": 29, "column": 37}}, {"id": 59, "type": "identifier", "text": "uart_buf_len", "parent": 56, "children": [], "start_point": {"row": 29, "column": 39}, "end_point": {"row": 29, "column": 51}}, {"id": 60, "type": "number_literal", "text": "100", "parent": 56, "children": [], "start_point": {"row": 29, "column": 53}, "end_point": {"row": 29, "column": 56}}, {"id": 61, "type": "if_statement", "text": "if (init_stts751(stts751_bus) == 0)\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init STTS751 OK\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t}\n\telse\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init STTS751 Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -1;\n\t}", "parent": 3, "children": [62, 87], "start_point": {"row": 32, "column": 1}, "end_point": {"row": 42, "column": 2}}, {"id": 62, "type": "parenthesized_expression", "text": "(init_stts751(stts751_bus) == 0)", "parent": 61, "children": [63], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 32, "column": 36}}, {"id": 63, "type": "binary_expression", "text": "init_stts751(stts751_bus) == 0", "parent": 62, "children": [64, 68, 69], "start_point": {"row": 32, "column": 5}, "end_point": {"row": 32, "column": 35}}, {"id": 64, "type": "call_expression", "text": "init_stts751(stts751_bus)", "parent": 63, "children": [65, 66], "start_point": {"row": 32, "column": 5}, "end_point": {"row": 32, "column": 30}}, {"id": 65, "type": "identifier", "text": "init_stts751", "parent": 64, "children": [], "start_point": {"row": 32, "column": 5}, "end_point": {"row": 32, "column": 17}}, {"id": 66, "type": "argument_list", "text": "(stts751_bus)", "parent": 64, "children": [67], "start_point": {"row": 32, "column": 17}, "end_point": {"row": 32, "column": 30}}, {"id": 67, "type": "identifier", "text": "stts751_bus", "parent": 66, "children": [], "start_point": {"row": 32, "column": 18}, "end_point": {"row": 32, "column": 29}}, {"id": 68, "type": "==", "text": "==", "parent": 63, "children": [], "start_point": {"row": 32, "column": 31}, "end_point": {"row": 32, "column": 33}}, {"id": 69, "type": "number_literal", "text": "0", "parent": 63, "children": [], "start_point": {"row": 32, "column": 34}, "end_point": {"row": 32, "column": 35}}, {"id": 70, "type": "assignment_expression", "text": "uart_buf_len = sprintf(uart_buf, \"---- Init STTS751 OK\\r\\n\")", "parent": 61, "children": [71, 72, 73], "start_point": {"row": 34, "column": 3}, "end_point": {"row": 34, "column": 63}}, {"id": 71, "type": "identifier", "text": "uart_buf_len", "parent": 70, "children": [], "start_point": {"row": 34, "column": 3}, "end_point": {"row": 34, "column": 15}}, {"id": 72, "type": "=", "text": "=", "parent": 70, "children": [], "start_point": {"row": 34, "column": 16}, "end_point": {"row": 34, "column": 17}}, {"id": 73, "type": "call_expression", "text": "sprintf(uart_buf, \"---- Init STTS751 OK\\r\\n\")", "parent": 70, "children": [74, 75], "start_point": {"row": 34, "column": 18}, "end_point": {"row": 34, "column": 63}}, {"id": 74, "type": "identifier", "text": "sprintf", "parent": 73, "children": [], "start_point": {"row": 34, "column": 18}, "end_point": {"row": 34, "column": 25}}, {"id": 75, "type": "argument_list", "text": "(uart_buf, \"---- Init STTS751 OK\\r\\n\")", "parent": 73, "children": [76, 77], "start_point": {"row": 34, "column": 25}, "end_point": {"row": 34, "column": 63}}, {"id": 76, "type": "identifier", "text": "uart_buf", "parent": 75, "children": [], "start_point": {"row": 34, "column": 26}, "end_point": {"row": 34, "column": 34}}, {"id": 77, "type": "string_literal", "text": "\"---- Init STTS751 OK\\r\\n\"", "parent": 75, "children": [78, 79], "start_point": {"row": 34, "column": 36}, "end_point": {"row": 34, "column": 62}}, {"id": 78, "type": "escape_sequence", "text": "\\r", "parent": 77, "children": [], "start_point": {"row": 34, "column": 57}, "end_point": {"row": 34, "column": 59}}, {"id": 79, "type": "escape_sequence", "text": "\\n", "parent": 77, "children": [], "start_point": {"row": 34, "column": 59}, "end_point": {"row": 34, "column": 61}}, {"id": 80, "type": "call_expression", "text": "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 61, "children": [81, 82], "start_point": {"row": 35, "column": 3}, "end_point": {"row": 35, "column": 59}}, {"id": 81, "type": "identifier", "text": "HAL_UART_Transmit", "parent": 80, "children": [], "start_point": {"row": 35, "column": 3}, "end_point": {"row": 35, "column": 20}}, {"id": 82, "type": "argument_list", "text": "(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 80, "children": [83, 84, 85, 86], "start_point": {"row": 35, "column": 20}, "end_point": {"row": 35, "column": 59}}, {"id": 83, "type": "identifier", "text": "UART_bus", "parent": 82, "children": [], "start_point": {"row": 35, "column": 21}, "end_point": {"row": 35, "column": 29}}, {"id": 84, "type": "identifier", "text": "uart_buf", "parent": 82, "children": [], "start_point": {"row": 35, "column": 31}, "end_point": {"row": 35, "column": 39}}, {"id": 85, "type": "identifier", "text": "uart_buf_len", "parent": 82, "children": [], "start_point": {"row": 35, "column": 41}, "end_point": {"row": 35, "column": 53}}, {"id": 86, "type": "number_literal", "text": "100", "parent": 82, "children": [], "start_point": {"row": 35, "column": 55}, "end_point": {"row": 35, "column": 58}}, {"id": 87, "type": "else_clause", "text": "else\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init STTS751 Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -1;\n\t}", "parent": 61, "children": [], "start_point": {"row": 37, "column": 1}, "end_point": {"row": 42, "column": 2}}, {"id": 88, "type": "assignment_expression", "text": "uart_buf_len = sprintf(uart_buf, \"---- Init STTS751 Failure\\r\\n\")", "parent": 87, "children": [89, 90, 91], "start_point": {"row": 39, "column": 3}, "end_point": {"row": 39, "column": 68}}, {"id": 89, "type": "identifier", "text": "uart_buf_len", "parent": 88, "children": [], "start_point": {"row": 39, "column": 3}, "end_point": {"row": 39, "column": 15}}, {"id": 90, "type": "=", "text": "=", "parent": 88, "children": [], "start_point": {"row": 39, "column": 16}, "end_point": {"row": 39, "column": 17}}, {"id": 91, "type": "call_expression", "text": "sprintf(uart_buf, \"---- Init STTS751 Failure\\r\\n\")", "parent": 88, "children": [92, 93], "start_point": {"row": 39, "column": 18}, "end_point": {"row": 39, "column": 68}}, {"id": 92, "type": "identifier", "text": "sprintf", "parent": 91, "children": [], "start_point": {"row": 39, "column": 18}, "end_point": {"row": 39, "column": 25}}, {"id": 93, "type": "argument_list", "text": "(uart_buf, \"---- Init STTS751 Failure\\r\\n\")", "parent": 91, "children": [94, 95], "start_point": {"row": 39, "column": 25}, "end_point": {"row": 39, "column": 68}}, {"id": 94, "type": "identifier", "text": "uart_buf", "parent": 93, "children": [], "start_point": {"row": 39, "column": 26}, "end_point": {"row": 39, "column": 34}}, {"id": 95, "type": "string_literal", "text": "\"---- Init STTS751 Failure\\r\\n\"", "parent": 93, "children": [96, 97], "start_point": {"row": 39, "column": 36}, "end_point": {"row": 39, "column": 67}}, {"id": 96, "type": "escape_sequence", "text": "\\r", "parent": 95, "children": [], "start_point": {"row": 39, "column": 62}, "end_point": {"row": 39, "column": 64}}, {"id": 97, "type": "escape_sequence", "text": "\\n", "parent": 95, "children": [], "start_point": {"row": 39, "column": 64}, "end_point": {"row": 39, "column": 66}}, {"id": 98, "type": "call_expression", "text": "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 87, "children": [99, 100], "start_point": {"row": 40, "column": 3}, "end_point": {"row": 40, "column": 59}}, {"id": 99, "type": "identifier", "text": "HAL_UART_Transmit", "parent": 98, "children": [], "start_point": {"row": 40, "column": 3}, "end_point": {"row": 40, "column": 20}}, {"id": 100, "type": "argument_list", "text": "(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 98, "children": [101, 102, 103, 104], "start_point": {"row": 40, "column": 20}, "end_point": {"row": 40, "column": 59}}, {"id": 101, "type": "identifier", "text": "UART_bus", "parent": 100, "children": [], "start_point": {"row": 40, "column": 21}, "end_point": {"row": 40, "column": 29}}, {"id": 102, "type": "identifier", "text": "uart_buf", "parent": 100, "children": [], "start_point": {"row": 40, "column": 31}, "end_point": {"row": 40, "column": 39}}, {"id": 103, "type": "identifier", "text": "uart_buf_len", "parent": 100, "children": [], "start_point": {"row": 40, "column": 41}, "end_point": {"row": 40, "column": 53}}, {"id": 104, "type": "number_literal", "text": "100", "parent": 100, "children": [], "start_point": {"row": 40, "column": 55}, "end_point": {"row": 40, "column": 58}}, {"id": 105, "type": "return_statement", "text": "return -1;", "parent": 87, "children": [106], "start_point": {"row": 41, "column": 3}, "end_point": {"row": 41, "column": 13}}, {"id": 106, "type": "number_literal", "text": "-1", "parent": 105, "children": [], "start_point": {"row": 41, "column": 10}, "end_point": {"row": 41, "column": 12}}, {"id": 107, "type": "if_statement", "text": "if (init_lps22hh(lps22hh_bus) == 0)\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init LPS22HH OK\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t}\n\telse\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init LPS22HH Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -2;\n\t}", "parent": 3, "children": [108, 133], "start_point": {"row": 45, "column": 1}, "end_point": {"row": 55, "column": 2}}, {"id": 108, "type": "parenthesized_expression", "text": "(init_lps22hh(lps22hh_bus) == 0)", "parent": 107, "children": [109], "start_point": {"row": 45, "column": 4}, "end_point": {"row": 45, "column": 36}}, {"id": 109, "type": "binary_expression", "text": "init_lps22hh(lps22hh_bus) == 0", "parent": 108, "children": [110, 114, 115], "start_point": {"row": 45, "column": 5}, "end_point": {"row": 45, "column": 35}}, {"id": 110, "type": "call_expression", "text": "init_lps22hh(lps22hh_bus)", "parent": 109, "children": [111, 112], "start_point": {"row": 45, "column": 5}, "end_point": {"row": 45, "column": 30}}, {"id": 111, "type": "identifier", "text": "init_lps22hh", "parent": 110, "children": [], "start_point": {"row": 45, "column": 5}, "end_point": {"row": 45, "column": 17}}, {"id": 112, "type": "argument_list", "text": "(lps22hh_bus)", "parent": 110, "children": [113], "start_point": {"row": 45, "column": 17}, "end_point": {"row": 45, "column": 30}}, {"id": 113, "type": "identifier", "text": "lps22hh_bus", "parent": 112, "children": [], "start_point": {"row": 45, "column": 18}, "end_point": {"row": 45, "column": 29}}, {"id": 114, "type": "==", "text": "==", "parent": 109, "children": [], "start_point": {"row": 45, "column": 31}, "end_point": {"row": 45, "column": 33}}, {"id": 115, "type": "number_literal", "text": "0", "parent": 109, "children": [], "start_point": {"row": 45, "column": 34}, "end_point": {"row": 45, "column": 35}}, {"id": 116, "type": "assignment_expression", "text": "uart_buf_len = sprintf(uart_buf, \"---- Init LPS22HH OK\\r\\n\")", "parent": 107, "children": [117, 118, 119], "start_point": {"row": 47, "column": 3}, "end_point": {"row": 47, "column": 63}}, {"id": 117, "type": "identifier", "text": "uart_buf_len", "parent": 116, "children": [], "start_point": {"row": 47, "column": 3}, "end_point": {"row": 47, "column": 15}}, {"id": 118, "type": "=", "text": "=", "parent": 116, "children": [], "start_point": {"row": 47, "column": 16}, "end_point": {"row": 47, "column": 17}}, {"id": 119, "type": "call_expression", "text": "sprintf(uart_buf, \"---- Init LPS22HH OK\\r\\n\")", "parent": 116, "children": [120, 121], "start_point": {"row": 47, "column": 18}, "end_point": {"row": 47, "column": 63}}, {"id": 120, "type": "identifier", "text": "sprintf", "parent": 119, "children": [], "start_point": {"row": 47, "column": 18}, "end_point": {"row": 47, "column": 25}}, {"id": 121, "type": "argument_list", "text": "(uart_buf, \"---- Init LPS22HH OK\\r\\n\")", "parent": 119, "children": [122, 123], "start_point": {"row": 47, "column": 25}, "end_point": {"row": 47, "column": 63}}, {"id": 122, "type": "identifier", "text": "uart_buf", "parent": 121, "children": [], "start_point": {"row": 47, "column": 26}, "end_point": {"row": 47, "column": 34}}, {"id": 123, "type": "string_literal", "text": "\"---- Init LPS22HH OK\\r\\n\"", "parent": 121, "children": [124, 125], "start_point": {"row": 47, "column": 36}, "end_point": {"row": 47, "column": 62}}, {"id": 124, "type": "escape_sequence", "text": "\\r", "parent": 123, "children": [], "start_point": {"row": 47, "column": 57}, "end_point": {"row": 47, "column": 59}}, {"id": 125, "type": "escape_sequence", "text": "\\n", "parent": 123, "children": [], "start_point": {"row": 47, "column": 59}, "end_point": {"row": 47, "column": 61}}, {"id": 126, "type": "call_expression", "text": "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 107, "children": [127, 128], "start_point": {"row": 48, "column": 3}, "end_point": {"row": 48, "column": 59}}, {"id": 127, "type": "identifier", "text": "HAL_UART_Transmit", "parent": 126, "children": [], "start_point": {"row": 48, "column": 3}, "end_point": {"row": 48, "column": 20}}, {"id": 128, "type": "argument_list", "text": "(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 126, "children": [129, 130, 131, 132], "start_point": {"row": 48, "column": 20}, "end_point": {"row": 48, "column": 59}}, {"id": 129, "type": "identifier", "text": "UART_bus", "parent": 128, "children": [], "start_point": {"row": 48, "column": 21}, "end_point": {"row": 48, "column": 29}}, {"id": 130, "type": "identifier", "text": "uart_buf", "parent": 128, "children": [], "start_point": {"row": 48, "column": 31}, "end_point": {"row": 48, "column": 39}}, {"id": 131, "type": "identifier", "text": "uart_buf_len", "parent": 128, "children": [], "start_point": {"row": 48, "column": 41}, "end_point": {"row": 48, "column": 53}}, {"id": 132, "type": "number_literal", "text": "100", "parent": 128, "children": [], "start_point": {"row": 48, "column": 55}, "end_point": {"row": 48, "column": 58}}, {"id": 133, "type": "else_clause", "text": "else\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init LPS22HH Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -2;\n\t}", "parent": 107, "children": [], "start_point": {"row": 50, "column": 1}, "end_point": {"row": 55, "column": 2}}, {"id": 134, "type": "assignment_expression", "text": "uart_buf_len = sprintf(uart_buf, \"---- Init LPS22HH Failure\\r\\n\")", "parent": 133, "children": [135, 136, 137], "start_point": {"row": 52, "column": 3}, "end_point": {"row": 52, "column": 68}}, {"id": 135, "type": "identifier", "text": "uart_buf_len", "parent": 134, "children": [], "start_point": {"row": 52, "column": 3}, "end_point": {"row": 52, "column": 15}}, {"id": 136, "type": "=", "text": "=", "parent": 134, "children": [], "start_point": {"row": 52, "column": 16}, "end_point": {"row": 52, "column": 17}}, {"id": 137, "type": "call_expression", "text": "sprintf(uart_buf, \"---- Init LPS22HH Failure\\r\\n\")", "parent": 134, "children": [138, 139], "start_point": {"row": 52, "column": 18}, "end_point": {"row": 52, "column": 68}}, {"id": 138, "type": "identifier", "text": "sprintf", "parent": 137, "children": [], "start_point": {"row": 52, "column": 18}, "end_point": {"row": 52, "column": 25}}, {"id": 139, "type": "argument_list", "text": "(uart_buf, \"---- Init LPS22HH Failure\\r\\n\")", "parent": 137, "children": [140, 141], "start_point": {"row": 52, "column": 25}, "end_point": {"row": 52, "column": 68}}, {"id": 140, "type": "identifier", "text": "uart_buf", "parent": 139, "children": [], "start_point": {"row": 52, "column": 26}, "end_point": {"row": 52, "column": 34}}, {"id": 141, "type": "string_literal", "text": "\"---- Init LPS22HH Failure\\r\\n\"", "parent": 139, "children": [142, 143], "start_point": {"row": 52, "column": 36}, "end_point": {"row": 52, "column": 67}}, {"id": 142, "type": "escape_sequence", "text": "\\r", "parent": 141, "children": [], "start_point": {"row": 52, "column": 62}, "end_point": {"row": 52, "column": 64}}, {"id": 143, "type": "escape_sequence", "text": "\\n", "parent": 141, "children": [], "start_point": {"row": 52, "column": 64}, "end_point": {"row": 52, "column": 66}}, {"id": 144, "type": "call_expression", "text": "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 133, "children": [145, 146], "start_point": {"row": 53, "column": 3}, "end_point": {"row": 53, "column": 59}}, {"id": 145, "type": "identifier", "text": "HAL_UART_Transmit", "parent": 144, "children": [], "start_point": {"row": 53, "column": 3}, "end_point": {"row": 53, "column": 20}}, {"id": 146, "type": "argument_list", "text": "(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 144, "children": [147, 148, 149, 150], "start_point": {"row": 53, "column": 20}, "end_point": {"row": 53, "column": 59}}, {"id": 147, "type": "identifier", "text": "UART_bus", "parent": 146, "children": [], "start_point": {"row": 53, "column": 21}, "end_point": {"row": 53, "column": 29}}, {"id": 148, "type": "identifier", "text": "uart_buf", "parent": 146, "children": [], "start_point": {"row": 53, "column": 31}, "end_point": {"row": 53, "column": 39}}, {"id": 149, "type": "identifier", "text": "uart_buf_len", "parent": 146, "children": [], "start_point": {"row": 53, "column": 41}, "end_point": {"row": 53, "column": 53}}, {"id": 150, "type": "number_literal", "text": "100", "parent": 146, "children": [], "start_point": {"row": 53, "column": 55}, "end_point": {"row": 53, "column": 58}}, {"id": 151, "type": "return_statement", "text": "return -2;", "parent": 133, "children": [152], "start_point": {"row": 54, "column": 3}, "end_point": {"row": 54, "column": 13}}, {"id": 152, "type": "number_literal", "text": "-2", "parent": 151, "children": [], "start_point": {"row": 54, "column": 10}, "end_point": {"row": 54, "column": 12}}, {"id": 153, "type": "if_statement", "text": "if (init_hts221(hts221_bus) == 0)\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init HTS221 OK\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t}\n\telse\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init HTS221 Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -3;\n\t}", "parent": 3, "children": [154, 179], "start_point": {"row": 59, "column": 1}, "end_point": {"row": 69, "column": 2}}, {"id": 154, "type": "parenthesized_expression", "text": "(init_hts221(hts221_bus) == 0)", "parent": 153, "children": [155], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 34}}, {"id": 155, "type": "binary_expression", "text": "init_hts221(hts221_bus) == 0", "parent": 154, "children": [156, 160, 161], "start_point": {"row": 59, "column": 5}, "end_point": {"row": 59, "column": 33}}, {"id": 156, "type": "call_expression", "text": "init_hts221(hts221_bus)", "parent": 155, "children": [157, 158], "start_point": {"row": 59, "column": 5}, "end_point": {"row": 59, "column": 28}}, {"id": 157, "type": "identifier", "text": "init_hts221", "parent": 156, "children": [], "start_point": {"row": 59, "column": 5}, "end_point": {"row": 59, "column": 16}}, {"id": 158, "type": "argument_list", "text": "(hts221_bus)", "parent": 156, "children": [159], "start_point": {"row": 59, "column": 16}, "end_point": {"row": 59, "column": 28}}, {"id": 159, "type": "identifier", "text": "hts221_bus", "parent": 158, "children": [], "start_point": {"row": 59, "column": 17}, "end_point": {"row": 59, "column": 27}}, {"id": 160, "type": "==", "text": "==", "parent": 155, "children": [], "start_point": {"row": 59, "column": 29}, "end_point": {"row": 59, "column": 31}}, {"id": 161, "type": "number_literal", "text": "0", "parent": 155, "children": [], "start_point": {"row": 59, "column": 32}, "end_point": {"row": 59, "column": 33}}, {"id": 162, "type": "assignment_expression", "text": "uart_buf_len = sprintf(uart_buf, \"---- Init HTS221 OK\\r\\n\")", "parent": 153, "children": [163, 164, 165], "start_point": {"row": 61, "column": 3}, "end_point": {"row": 61, "column": 62}}, {"id": 163, "type": "identifier", "text": "uart_buf_len", "parent": 162, "children": [], "start_point": {"row": 61, "column": 3}, "end_point": {"row": 61, "column": 15}}, {"id": 164, "type": "=", "text": "=", "parent": 162, "children": [], "start_point": {"row": 61, "column": 16}, "end_point": {"row": 61, "column": 17}}, {"id": 165, "type": "call_expression", "text": "sprintf(uart_buf, \"---- Init HTS221 OK\\r\\n\")", "parent": 162, "children": [166, 167], "start_point": {"row": 61, "column": 18}, "end_point": {"row": 61, "column": 62}}, {"id": 166, "type": "identifier", "text": "sprintf", "parent": 165, "children": [], "start_point": {"row": 61, "column": 18}, "end_point": {"row": 61, "column": 25}}, {"id": 167, "type": "argument_list", "text": "(uart_buf, \"---- Init HTS221 OK\\r\\n\")", "parent": 165, "children": [168, 169], "start_point": {"row": 61, "column": 25}, "end_point": {"row": 61, "column": 62}}, {"id": 168, "type": "identifier", "text": "uart_buf", "parent": 167, "children": [], "start_point": {"row": 61, "column": 26}, "end_point": {"row": 61, "column": 34}}, {"id": 169, "type": "string_literal", "text": "\"---- Init HTS221 OK\\r\\n\"", "parent": 167, "children": [170, 171], "start_point": {"row": 61, "column": 36}, "end_point": {"row": 61, "column": 61}}, {"id": 170, "type": "escape_sequence", "text": "\\r", "parent": 169, "children": [], "start_point": {"row": 61, "column": 56}, "end_point": {"row": 61, "column": 58}}, {"id": 171, "type": "escape_sequence", "text": "\\n", "parent": 169, "children": [], "start_point": {"row": 61, "column": 58}, "end_point": {"row": 61, "column": 60}}, {"id": 172, "type": "call_expression", "text": "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 153, "children": [173, 174], "start_point": {"row": 62, "column": 3}, "end_point": {"row": 62, "column": 59}}, {"id": 173, "type": "identifier", "text": "HAL_UART_Transmit", "parent": 172, "children": [], "start_point": {"row": 62, "column": 3}, "end_point": {"row": 62, "column": 20}}, {"id": 174, "type": "argument_list", "text": "(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 172, "children": [175, 176, 177, 178], "start_point": {"row": 62, "column": 20}, "end_point": {"row": 62, "column": 59}}, {"id": 175, "type": "identifier", "text": "UART_bus", "parent": 174, "children": [], "start_point": {"row": 62, "column": 21}, "end_point": {"row": 62, "column": 29}}, {"id": 176, "type": "identifier", "text": "uart_buf", "parent": 174, "children": [], "start_point": {"row": 62, "column": 31}, "end_point": {"row": 62, "column": 39}}, {"id": 177, "type": "identifier", "text": "uart_buf_len", "parent": 174, "children": [], "start_point": {"row": 62, "column": 41}, "end_point": {"row": 62, "column": 53}}, {"id": 178, "type": "number_literal", "text": "100", "parent": 174, "children": [], "start_point": {"row": 62, "column": 55}, "end_point": {"row": 62, "column": 58}}, {"id": 179, "type": "else_clause", "text": "else\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init HTS221 Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -3;\n\t}", "parent": 153, "children": [], "start_point": {"row": 64, "column": 1}, "end_point": {"row": 69, "column": 2}}, {"id": 180, "type": "assignment_expression", "text": "uart_buf_len = sprintf(uart_buf, \"---- Init HTS221 Failure\\r\\n\")", "parent": 179, "children": [181, 182, 183], "start_point": {"row": 66, "column": 3}, "end_point": {"row": 66, "column": 67}}, {"id": 181, "type": "identifier", "text": "uart_buf_len", "parent": 180, "children": [], "start_point": {"row": 66, "column": 3}, "end_point": {"row": 66, "column": 15}}, {"id": 182, "type": "=", "text": "=", "parent": 180, "children": [], "start_point": {"row": 66, "column": 16}, "end_point": {"row": 66, "column": 17}}, {"id": 183, "type": "call_expression", "text": "sprintf(uart_buf, \"---- Init HTS221 Failure\\r\\n\")", "parent": 180, "children": [184, 185], "start_point": {"row": 66, "column": 18}, "end_point": {"row": 66, "column": 67}}, {"id": 184, "type": "identifier", "text": "sprintf", "parent": 183, "children": [], "start_point": {"row": 66, "column": 18}, "end_point": {"row": 66, "column": 25}}, {"id": 185, "type": "argument_list", "text": "(uart_buf, \"---- Init HTS221 Failure\\r\\n\")", "parent": 183, "children": [186, 187], "start_point": {"row": 66, "column": 25}, "end_point": {"row": 66, "column": 67}}, {"id": 186, "type": "identifier", "text": "uart_buf", "parent": 185, "children": [], "start_point": {"row": 66, "column": 26}, "end_point": {"row": 66, "column": 34}}, {"id": 187, "type": "string_literal", "text": "\"---- Init HTS221 Failure\\r\\n\"", "parent": 185, "children": [188, 189], "start_point": {"row": 66, "column": 36}, "end_point": {"row": 66, "column": 66}}, {"id": 188, "type": "escape_sequence", "text": "\\r", "parent": 187, "children": [], "start_point": {"row": 66, "column": 61}, "end_point": {"row": 66, "column": 63}}, {"id": 189, "type": "escape_sequence", "text": "\\n", "parent": 187, "children": [], "start_point": {"row": 66, "column": 63}, "end_point": {"row": 66, "column": 65}}, {"id": 190, "type": "call_expression", "text": "HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 179, "children": [191, 192], "start_point": {"row": 67, "column": 3}, "end_point": {"row": 67, "column": 59}}, {"id": 191, "type": "identifier", "text": "HAL_UART_Transmit", "parent": 190, "children": [], "start_point": {"row": 67, "column": 3}, "end_point": {"row": 67, "column": 20}}, {"id": 192, "type": "argument_list", "text": "(UART_bus, uart_buf, uart_buf_len, 100)", "parent": 190, "children": [193, 194, 195, 196], "start_point": {"row": 67, "column": 20}, "end_point": {"row": 67, "column": 59}}, {"id": 193, "type": "identifier", "text": "UART_bus", "parent": 192, "children": [], "start_point": {"row": 67, "column": 21}, "end_point": {"row": 67, "column": 29}}, {"id": 194, "type": "identifier", "text": "uart_buf", "parent": 192, "children": [], "start_point": {"row": 67, "column": 31}, "end_point": {"row": 67, "column": 39}}, {"id": 195, "type": "identifier", "text": "uart_buf_len", "parent": 192, "children": [], "start_point": {"row": 67, "column": 41}, "end_point": {"row": 67, "column": 53}}, {"id": 196, "type": "number_literal", "text": "100", "parent": 192, "children": [], "start_point": {"row": 67, "column": 55}, "end_point": {"row": 67, "column": 58}}, {"id": 197, "type": "return_statement", "text": "return -3;", "parent": 179, "children": [198], "start_point": {"row": 68, "column": 3}, "end_point": {"row": 68, "column": 13}}, {"id": 198, "type": "number_literal", "text": "-3", "parent": 197, "children": [], "start_point": {"row": 68, "column": 10}, "end_point": {"row": 68, "column": 12}}, {"id": 199, "type": "return_statement", "text": "return 0;", "parent": 3, "children": [200], "start_point": {"row": 87, "column": 1}, "end_point": {"row": 87, "column": 10}}, {"id": 200, "type": "number_literal", "text": "0", "parent": 199, "children": [], "start_point": {"row": 87, "column": 8}, "end_point": {"row": 87, "column": 9}}, {"id": 201, "type": "function_definition", "text": "int init_stts751(I2C_HandleTypeDef *stts751_bus)\n{\n\tstts751_id_t stts751_whoamI;\n\n\tstts751_dev_ctx.write_reg = platform_write_stts751;\n\tstts751_dev_ctx.read_reg = platform_read_stts751;\n\tstts751_dev_ctx.handle = stts751_bus;\n\n\tstts751_device_id_get(&stts751_dev_ctx, &stts751_whoamI);\n\tif ( (stts751_whoamI.product_id != STTS751_ID_0xxxx) ||\n\t (stts751_whoamI.manufacturer_id != STTS751_ID_MAN) ||\n\t (stts751_whoamI.revision_id != STTS751_REV) )\n\t{\n\t return -1;\n\t}\n\n\t/* Enable interrupt on high(=49.5 degC)/low(=-4.5 degC) temperature. */\n\tfloat temperature_high_limit = 49.5f;\n\tstts751_high_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_high_limit));\n\n\tfloat temperature_low_limit = -4.5f;\n\tstts751_low_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_low_limit));\n\n\tstts751_pin_event_route_set(&stts751_dev_ctx, PROPERTY_ENABLE);\n\n\t/* Set Output Data Rate */\n\tstts751_temp_data_rate_set(&stts751_dev_ctx, STTS751_TEMP_ODR_8Hz);\n\n\t/* Set Resolution */\n\tstts751_resolution_set(&stts751_dev_ctx, STTS751_12bit);\n\n\treturn 0;\n}", "parent": null, "children": [202, 203], "start_point": {"row": 91, "column": 0}, "end_point": {"row": 123, "column": 1}}, {"id": 202, "type": "primitive_type", "text": "int", "parent": 201, "children": [], "start_point": {"row": 91, "column": 0}, "end_point": {"row": 91, "column": 3}}, {"id": 203, "type": "function_declarator", "text": "init_stts751(I2C_HandleTypeDef *stts751_bus)", "parent": 201, "children": [204, 205], "start_point": {"row": 91, "column": 4}, "end_point": {"row": 91, "column": 48}}, {"id": 204, "type": "identifier", "text": "init_stts751", "parent": 203, "children": [], "start_point": {"row": 91, "column": 4}, "end_point": {"row": 91, "column": 16}}, {"id": 205, "type": "parameter_list", "text": "(I2C_HandleTypeDef *stts751_bus)", "parent": 203, "children": [206], "start_point": {"row": 91, "column": 16}, "end_point": {"row": 91, "column": 48}}, {"id": 206, "type": "parameter_declaration", "text": "I2C_HandleTypeDef *stts751_bus", "parent": 205, "children": [207, 208], "start_point": {"row": 91, "column": 17}, "end_point": {"row": 91, "column": 47}}, {"id": 207, "type": "type_identifier", "text": "I2C_HandleTypeDef", "parent": 206, "children": [], "start_point": {"row": 91, "column": 17}, "end_point": {"row": 91, "column": 34}}, {"id": 208, "type": "pointer_declarator", "text": "*stts751_bus", "parent": 206, "children": [209, 210], "start_point": {"row": 91, "column": 35}, "end_point": {"row": 91, "column": 47}}, {"id": 209, "type": "*", "text": "*", "parent": 208, "children": [], "start_point": {"row": 91, "column": 35}, "end_point": {"row": 91, "column": 36}}, {"id": 210, "type": "identifier", "text": "stts751_bus", "parent": 208, "children": [], "start_point": {"row": 91, "column": 36}, "end_point": {"row": 91, "column": 47}}, {"id": 211, "type": "declaration", "text": "stts751_id_t stts751_whoamI;", "parent": 201, "children": [212, 213], "start_point": {"row": 93, "column": 1}, "end_point": {"row": 93, "column": 29}}, {"id": 212, "type": "type_identifier", "text": "stts751_id_t", "parent": 211, "children": [], "start_point": {"row": 93, "column": 1}, "end_point": {"row": 93, "column": 13}}, {"id": 213, "type": "identifier", "text": "stts751_whoamI", "parent": 211, "children": [], "start_point": {"row": 93, "column": 14}, "end_point": {"row": 93, "column": 28}}, {"id": 214, "type": "assignment_expression", "text": "stts751_dev_ctx.write_reg = platform_write_stts751", "parent": 201, "children": [215, 218, 219], "start_point": {"row": 95, "column": 1}, "end_point": {"row": 95, "column": 51}}, {"id": 215, "type": "field_expression", "text": "stts751_dev_ctx.write_reg", "parent": 214, "children": [216, 217], "start_point": {"row": 95, "column": 1}, "end_point": {"row": 95, "column": 26}}, {"id": 216, "type": "identifier", "text": "stts751_dev_ctx", "parent": 215, "children": [], "start_point": {"row": 95, "column": 1}, "end_point": {"row": 95, "column": 16}}, {"id": 217, "type": "field_identifier", "text": "write_reg", "parent": 215, "children": [], "start_point": {"row": 95, "column": 17}, "end_point": {"row": 95, "column": 26}}, {"id": 218, "type": "=", "text": "=", "parent": 214, "children": [], "start_point": {"row": 95, "column": 27}, "end_point": {"row": 95, "column": 28}}, {"id": 219, "type": "identifier", "text": "platform_write_stts751", "parent": 214, "children": [], "start_point": {"row": 95, "column": 29}, "end_point": {"row": 95, "column": 51}}, {"id": 220, "type": "assignment_expression", "text": "stts751_dev_ctx.read_reg = platform_read_stts751", "parent": 201, "children": [221, 224, 225], "start_point": {"row": 96, "column": 1}, "end_point": {"row": 96, "column": 49}}, {"id": 221, "type": "field_expression", "text": "stts751_dev_ctx.read_reg", "parent": 220, "children": [222, 223], "start_point": {"row": 96, "column": 1}, "end_point": {"row": 96, "column": 25}}, {"id": 222, "type": "identifier", "text": "stts751_dev_ctx", "parent": 221, "children": [], "start_point": {"row": 96, "column": 1}, "end_point": {"row": 96, "column": 16}}, {"id": 223, "type": "field_identifier", "text": "read_reg", "parent": 221, "children": [], "start_point": {"row": 96, "column": 17}, "end_point": {"row": 96, "column": 25}}, {"id": 224, "type": "=", "text": "=", "parent": 220, "children": [], "start_point": {"row": 96, "column": 26}, "end_point": {"row": 96, "column": 27}}, {"id": 225, "type": "identifier", "text": "platform_read_stts751", "parent": 220, "children": [], "start_point": {"row": 96, "column": 28}, "end_point": {"row": 96, "column": 49}}, {"id": 226, "type": "assignment_expression", "text": "stts751_dev_ctx.handle = stts751_bus", "parent": 201, "children": [227, 230, 231], "start_point": {"row": 97, "column": 1}, "end_point": {"row": 97, "column": 37}}, {"id": 227, "type": "field_expression", "text": "stts751_dev_ctx.handle", "parent": 226, "children": [228, 229], "start_point": {"row": 97, "column": 1}, "end_point": {"row": 97, "column": 23}}, {"id": 228, "type": "identifier", "text": "stts751_dev_ctx", "parent": 227, "children": [], "start_point": {"row": 97, "column": 1}, "end_point": {"row": 97, "column": 16}}, {"id": 229, "type": "field_identifier", "text": "handle", "parent": 227, "children": [], "start_point": {"row": 97, "column": 17}, "end_point": {"row": 97, "column": 23}}, {"id": 230, "type": "=", "text": "=", "parent": 226, "children": [], "start_point": {"row": 97, "column": 24}, "end_point": {"row": 97, "column": 25}}, {"id": 231, "type": "identifier", "text": "stts751_bus", "parent": 226, "children": [], "start_point": {"row": 97, "column": 26}, "end_point": {"row": 97, "column": 37}}, {"id": 232, "type": "call_expression", "text": "stts751_device_id_get(&stts751_dev_ctx, &stts751_whoamI)", "parent": 201, "children": [233, 234], "start_point": {"row": 99, "column": 1}, "end_point": {"row": 99, "column": 57}}, {"id": 233, "type": "identifier", "text": "stts751_device_id_get", "parent": 232, "children": [], "start_point": {"row": 99, "column": 1}, "end_point": {"row": 99, "column": 22}}, {"id": 234, "type": "argument_list", "text": "(&stts751_dev_ctx, &stts751_whoamI)", "parent": 232, "children": [235, 237], "start_point": {"row": 99, "column": 22}, "end_point": {"row": 99, "column": 57}}, {"id": 235, "type": "pointer_expression", "text": "&stts751_dev_ctx", "parent": 234, "children": [236], "start_point": {"row": 99, "column": 23}, "end_point": {"row": 99, "column": 39}}, {"id": 236, "type": "identifier", "text": "stts751_dev_ctx", "parent": 235, "children": [], "start_point": {"row": 99, "column": 24}, "end_point": {"row": 99, "column": 39}}, {"id": 237, "type": "pointer_expression", "text": "&stts751_whoamI", "parent": 234, "children": [238], "start_point": {"row": 99, "column": 41}, "end_point": {"row": 99, "column": 56}}, {"id": 238, "type": "identifier", "text": "stts751_whoamI", "parent": 237, "children": [], "start_point": {"row": 99, "column": 42}, "end_point": {"row": 99, "column": 56}}, {"id": 239, "type": "if_statement", "text": "if ( (stts751_whoamI.product_id != STTS751_ID_0xxxx) ||\n\t (stts751_whoamI.manufacturer_id != STTS751_ID_MAN) ||\n\t (stts751_whoamI.revision_id != STTS751_REV) )\n\t{\n\t return -1;\n\t}", "parent": 201, "children": [240], "start_point": {"row": 100, "column": 1}, "end_point": {"row": 105, "column": 2}}, {"id": 240, "type": "parenthesized_expression", "text": "( (stts751_whoamI.product_id != STTS751_ID_0xxxx) ||\n\t (stts751_whoamI.manufacturer_id != STTS751_ID_MAN) ||\n\t (stts751_whoamI.revision_id != STTS751_REV) )", "parent": 239, "children": [241], "start_point": {"row": 100, "column": 4}, "end_point": {"row": 102, "column": 51}}, {"id": 241, "type": "binary_expression", "text": "(stts751_whoamI.product_id != STTS751_ID_0xxxx) ||\n\t (stts751_whoamI.manufacturer_id != STTS751_ID_MAN) ||\n\t (stts751_whoamI.revision_id != STTS751_REV)", "parent": 240, "children": [242, 258, 259], "start_point": {"row": 100, "column": 6}, "end_point": {"row": 102, "column": 49}}, {"id": 242, "type": "binary_expression", "text": "(stts751_whoamI.product_id != STTS751_ID_0xxxx) ||\n\t (stts751_whoamI.manufacturer_id != STTS751_ID_MAN)", "parent": 241, "children": [243, 250, 251], "start_point": {"row": 100, "column": 6}, "end_point": {"row": 101, "column": 56}}, {"id": 243, "type": "parenthesized_expression", "text": "(stts751_whoamI.product_id != STTS751_ID_0xxxx)", "parent": 242, "children": [244], "start_point": {"row": 100, "column": 6}, "end_point": {"row": 100, "column": 53}}, {"id": 244, "type": "binary_expression", "text": "stts751_whoamI.product_id != STTS751_ID_0xxxx", "parent": 243, "children": [245, 248, 249], "start_point": {"row": 100, "column": 7}, "end_point": {"row": 100, "column": 52}}, {"id": 245, "type": "field_expression", "text": "stts751_whoamI.product_id", "parent": 244, "children": [246, 247], "start_point": {"row": 100, "column": 7}, "end_point": {"row": 100, "column": 32}}, {"id": 246, "type": "identifier", "text": "stts751_whoamI", "parent": 245, "children": [], "start_point": {"row": 100, "column": 7}, "end_point": {"row": 100, "column": 21}}, {"id": 247, "type": "field_identifier", "text": "product_id", "parent": 245, "children": [], "start_point": {"row": 100, "column": 22}, "end_point": {"row": 100, "column": 32}}, {"id": 248, "type": "!=", "text": "!=", "parent": 244, "children": [], "start_point": {"row": 100, "column": 33}, "end_point": {"row": 100, "column": 35}}, {"id": 249, "type": "identifier", "text": "STTS751_ID_0xxxx", "parent": 244, "children": [], "start_point": {"row": 100, "column": 36}, "end_point": {"row": 100, "column": 52}}, {"id": 250, "type": "||", "text": "||", "parent": 242, "children": [], "start_point": {"row": 100, "column": 54}, "end_point": {"row": 100, "column": 56}}, {"id": 251, "type": "parenthesized_expression", "text": "(stts751_whoamI.manufacturer_id != STTS751_ID_MAN)", "parent": 242, "children": [252], "start_point": {"row": 101, "column": 6}, "end_point": {"row": 101, "column": 56}}, {"id": 252, "type": "binary_expression", "text": "stts751_whoamI.manufacturer_id != STTS751_ID_MAN", "parent": 251, "children": [253, 256, 257], "start_point": {"row": 101, "column": 7}, "end_point": {"row": 101, "column": 55}}, {"id": 253, "type": "field_expression", "text": "stts751_whoamI.manufacturer_id", "parent": 252, "children": [254, 255], "start_point": {"row": 101, "column": 7}, "end_point": {"row": 101, "column": 37}}, {"id": 254, "type": "identifier", "text": "stts751_whoamI", "parent": 253, "children": [], "start_point": {"row": 101, "column": 7}, "end_point": {"row": 101, "column": 21}}, {"id": 255, "type": "field_identifier", "text": "manufacturer_id", "parent": 253, "children": [], "start_point": {"row": 101, "column": 22}, "end_point": {"row": 101, "column": 37}}, {"id": 256, "type": "!=", "text": "!=", "parent": 252, "children": [], "start_point": {"row": 101, "column": 38}, "end_point": {"row": 101, "column": 40}}, {"id": 257, "type": "identifier", "text": "STTS751_ID_MAN", "parent": 252, "children": [], "start_point": {"row": 101, "column": 41}, "end_point": {"row": 101, "column": 55}}, {"id": 258, "type": "||", "text": "||", "parent": 241, "children": [], "start_point": {"row": 101, "column": 57}, "end_point": {"row": 101, "column": 59}}, {"id": 259, "type": "parenthesized_expression", "text": "(stts751_whoamI.revision_id != STTS751_REV)", "parent": 241, "children": [260], "start_point": {"row": 102, "column": 6}, "end_point": {"row": 102, "column": 49}}, {"id": 260, "type": "binary_expression", "text": "stts751_whoamI.revision_id != STTS751_REV", "parent": 259, "children": [261, 264, 265], "start_point": {"row": 102, "column": 7}, "end_point": {"row": 102, "column": 48}}, {"id": 261, "type": "field_expression", "text": "stts751_whoamI.revision_id", "parent": 260, "children": [262, 263], "start_point": {"row": 102, "column": 7}, "end_point": {"row": 102, "column": 33}}, {"id": 262, "type": "identifier", "text": "stts751_whoamI", "parent": 261, "children": [], "start_point": {"row": 102, "column": 7}, "end_point": {"row": 102, "column": 21}}, {"id": 263, "type": "field_identifier", "text": "revision_id", "parent": 261, "children": [], "start_point": {"row": 102, "column": 22}, "end_point": {"row": 102, "column": 33}}, {"id": 264, "type": "!=", "text": "!=", "parent": 260, "children": [], "start_point": {"row": 102, "column": 34}, "end_point": {"row": 102, "column": 36}}, {"id": 265, "type": "identifier", "text": "STTS751_REV", "parent": 260, "children": [], "start_point": {"row": 102, "column": 37}, "end_point": {"row": 102, "column": 48}}, {"id": 266, "type": "return_statement", "text": "return -1;", "parent": 239, "children": [267], "start_point": {"row": 104, "column": 4}, "end_point": {"row": 104, "column": 14}}, {"id": 267, "type": "number_literal", "text": "-1", "parent": 266, "children": [], "start_point": {"row": 104, "column": 11}, "end_point": {"row": 104, "column": 13}}, {"id": 268, "type": "declaration", "text": "float temperature_high_limit = 49.5f;", "parent": 201, "children": [269, 270], "start_point": {"row": 108, "column": 1}, "end_point": {"row": 108, "column": 38}}, {"id": 269, "type": "primitive_type", "text": "float", "parent": 268, "children": [], "start_point": {"row": 108, "column": 1}, "end_point": {"row": 108, "column": 6}}, {"id": 270, "type": "init_declarator", "text": "temperature_high_limit = 49.5f", "parent": 268, "children": [271, 272, 273], "start_point": {"row": 108, "column": 7}, "end_point": {"row": 108, "column": 37}}, {"id": 271, "type": "identifier", "text": "temperature_high_limit", "parent": 270, "children": [], "start_point": {"row": 108, "column": 7}, "end_point": {"row": 108, "column": 29}}, {"id": 272, "type": "=", "text": "=", "parent": 270, "children": [], "start_point": {"row": 108, "column": 30}, "end_point": {"row": 108, "column": 31}}, {"id": 273, "type": "number_literal", "text": "49.5f", "parent": 270, "children": [], "start_point": {"row": 108, "column": 32}, "end_point": {"row": 108, "column": 37}}, {"id": 274, "type": "call_expression", "text": "stts751_high_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_high_limit))", "parent": 201, "children": [275, 276], "start_point": {"row": 109, "column": 1}, "end_point": {"row": 109, "column": 110}}, {"id": 275, "type": "identifier", "text": "stts751_high_temperature_threshold_set", "parent": 274, "children": [], "start_point": {"row": 109, "column": 1}, "end_point": {"row": 109, "column": 39}}, {"id": 276, "type": "argument_list", "text": "(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_high_limit))", "parent": 274, "children": [277, 279], "start_point": {"row": 109, "column": 39}, "end_point": {"row": 109, "column": 110}}, {"id": 277, "type": "pointer_expression", "text": "&stts751_dev_ctx", "parent": 276, "children": [278], "start_point": {"row": 109, "column": 40}, "end_point": {"row": 109, "column": 56}}, {"id": 278, "type": "identifier", "text": "stts751_dev_ctx", "parent": 277, "children": [], "start_point": {"row": 109, "column": 41}, "end_point": {"row": 109, "column": 56}}, {"id": 279, "type": "call_expression", "text": "stts751_from_celsius_to_lsb(temperature_high_limit)", "parent": 276, "children": [280, 281], "start_point": {"row": 109, "column": 58}, "end_point": {"row": 109, "column": 109}}, {"id": 280, "type": "identifier", "text": "stts751_from_celsius_to_lsb", "parent": 279, "children": [], "start_point": {"row": 109, "column": 58}, "end_point": {"row": 109, "column": 85}}, {"id": 281, "type": "argument_list", "text": "(temperature_high_limit)", "parent": 279, "children": [282], "start_point": {"row": 109, "column": 85}, "end_point": {"row": 109, "column": 109}}, {"id": 282, "type": "identifier", "text": "temperature_high_limit", "parent": 281, "children": [], "start_point": {"row": 109, "column": 86}, "end_point": {"row": 109, "column": 108}}, {"id": 283, "type": "declaration", "text": "float temperature_low_limit = -4.5f;", "parent": 201, "children": [284, 285], "start_point": {"row": 111, "column": 1}, "end_point": {"row": 111, "column": 37}}, {"id": 284, "type": "primitive_type", "text": "float", "parent": 283, "children": [], "start_point": {"row": 111, "column": 1}, "end_point": {"row": 111, "column": 6}}, {"id": 285, "type": "init_declarator", "text": "temperature_low_limit = -4.5f", "parent": 283, "children": [286, 287, 288], "start_point": {"row": 111, "column": 7}, "end_point": {"row": 111, "column": 36}}, {"id": 286, "type": "identifier", "text": "temperature_low_limit", "parent": 285, "children": [], "start_point": {"row": 111, "column": 7}, "end_point": {"row": 111, "column": 28}}, {"id": 287, "type": "=", "text": "=", "parent": 285, "children": [], "start_point": {"row": 111, "column": 29}, "end_point": {"row": 111, "column": 30}}, {"id": 288, "type": "number_literal", "text": "-4.5f", "parent": 285, "children": [], "start_point": {"row": 111, "column": 31}, "end_point": {"row": 111, "column": 36}}, {"id": 289, "type": "call_expression", "text": "stts751_low_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_low_limit))", "parent": 201, "children": [290, 291], "start_point": {"row": 112, "column": 1}, "end_point": {"row": 112, "column": 108}}, {"id": 290, "type": "identifier", "text": "stts751_low_temperature_threshold_set", "parent": 289, "children": [], "start_point": {"row": 112, "column": 1}, "end_point": {"row": 112, "column": 38}}, {"id": 291, "type": "argument_list", "text": "(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_low_limit))", "parent": 289, "children": [292, 294], "start_point": {"row": 112, "column": 38}, "end_point": {"row": 112, "column": 108}}, {"id": 292, "type": "pointer_expression", "text": "&stts751_dev_ctx", "parent": 291, "children": [293], "start_point": {"row": 112, "column": 39}, "end_point": {"row": 112, "column": 55}}, {"id": 293, "type": "identifier", "text": "stts751_dev_ctx", "parent": 292, "children": [], "start_point": {"row": 112, "column": 40}, "end_point": {"row": 112, "column": 55}}, {"id": 294, "type": "call_expression", "text": "stts751_from_celsius_to_lsb(temperature_low_limit)", "parent": 291, "children": [295, 296], "start_point": {"row": 112, "column": 57}, "end_point": {"row": 112, "column": 107}}, {"id": 295, "type": "identifier", "text": "stts751_from_celsius_to_lsb", "parent": 294, "children": [], "start_point": {"row": 112, "column": 57}, "end_point": {"row": 112, "column": 84}}, {"id": 296, "type": "argument_list", "text": "(temperature_low_limit)", "parent": 294, "children": [297], "start_point": {"row": 112, "column": 84}, "end_point": {"row": 112, "column": 107}}, {"id": 297, "type": "identifier", "text": "temperature_low_limit", "parent": 296, "children": [], "start_point": {"row": 112, "column": 85}, "end_point": {"row": 112, "column": 106}}, {"id": 298, "type": "call_expression", "text": "stts751_pin_event_route_set(&stts751_dev_ctx, PROPERTY_ENABLE)", "parent": 201, "children": [299, 300], "start_point": {"row": 114, "column": 1}, "end_point": {"row": 114, "column": 64}}, {"id": 299, "type": "identifier", "text": "stts751_pin_event_route_set", "parent": 298, "children": [], "start_point": {"row": 114, "column": 1}, "end_point": {"row": 114, "column": 28}}, {"id": 300, "type": "argument_list", "text": "(&stts751_dev_ctx, PROPERTY_ENABLE)", "parent": 298, "children": [301, 303], "start_point": {"row": 114, "column": 28}, "end_point": {"row": 114, "column": 64}}, {"id": 301, "type": "pointer_expression", "text": "&stts751_dev_ctx", "parent": 300, "children": [302], "start_point": {"row": 114, "column": 29}, "end_point": {"row": 114, "column": 45}}, {"id": 302, "type": "identifier", "text": "stts751_dev_ctx", "parent": 301, "children": [], "start_point": {"row": 114, "column": 30}, "end_point": {"row": 114, "column": 45}}, {"id": 303, "type": "identifier", "text": "PROPERTY_ENABLE", "parent": 300, "children": [], "start_point": {"row": 114, "column": 48}, "end_point": {"row": 114, "column": 63}}, {"id": 304, "type": "call_expression", "text": "stts751_temp_data_rate_set(&stts751_dev_ctx, STTS751_TEMP_ODR_8Hz)", "parent": 201, "children": [305, 306], "start_point": {"row": 117, "column": 1}, "end_point": {"row": 117, "column": 67}}, {"id": 305, "type": "identifier", "text": "stts751_temp_data_rate_set", "parent": 304, "children": [], "start_point": {"row": 117, "column": 1}, "end_point": {"row": 117, "column": 27}}, {"id": 306, "type": "argument_list", "text": "(&stts751_dev_ctx, STTS751_TEMP_ODR_8Hz)", "parent": 304, "children": [307, 309], "start_point": {"row": 117, "column": 27}, "end_point": {"row": 117, "column": 67}}, {"id": 307, "type": "pointer_expression", "text": "&stts751_dev_ctx", "parent": 306, "children": [308], "start_point": {"row": 117, "column": 28}, "end_point": {"row": 117, "column": 44}}, {"id": 308, "type": "identifier", "text": "stts751_dev_ctx", "parent": 307, "children": [], "start_point": {"row": 117, "column": 29}, "end_point": {"row": 117, "column": 44}}, {"id": 309, "type": "identifier", "text": "STTS751_TEMP_ODR_8Hz", "parent": 306, "children": [], "start_point": {"row": 117, "column": 46}, "end_point": {"row": 117, "column": 66}}, {"id": 310, "type": "call_expression", "text": "stts751_resolution_set(&stts751_dev_ctx, STTS751_12bit)", "parent": 201, "children": [311, 312], "start_point": {"row": 120, "column": 1}, "end_point": {"row": 120, "column": 56}}, {"id": 311, "type": "identifier", "text": "stts751_resolution_set", "parent": 310, "children": [], "start_point": {"row": 120, "column": 1}, "end_point": {"row": 120, "column": 23}}, {"id": 312, "type": "argument_list", "text": "(&stts751_dev_ctx, STTS751_12bit)", "parent": 310, "children": [313, 315], "start_point": {"row": 120, "column": 23}, "end_point": {"row": 120, "column": 56}}, {"id": 313, "type": "pointer_expression", "text": "&stts751_dev_ctx", "parent": 312, "children": [314], "start_point": {"row": 120, "column": 24}, "end_point": {"row": 120, "column": 40}}, {"id": 314, "type": "identifier", "text": "stts751_dev_ctx", "parent": 313, "children": [], "start_point": {"row": 120, "column": 25}, "end_point": {"row": 120, "column": 40}}, {"id": 315, "type": "identifier", "text": "STTS751_12bit", "parent": 312, "children": [], "start_point": {"row": 120, "column": 42}, "end_point": {"row": 120, "column": 55}}, {"id": 316, "type": "return_statement", "text": "return 0;", "parent": 201, "children": [317], "start_point": {"row": 122, "column": 1}, "end_point": {"row": 122, "column": 10}}, {"id": 317, "type": "number_literal", "text": "0", "parent": 316, "children": [], "start_point": {"row": 122, "column": 8}, "end_point": {"row": 122, "column": 9}}, {"id": 318, "type": "function_definition", "text": "int32_t platform_write_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n\tHAL_I2C_Mem_Write(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n\treturn 0;\n}", "parent": null, "children": [319, 320], "start_point": {"row": 125, "column": 0}, "end_point": {"row": 129, "column": 1}}, {"id": 319, "type": "primitive_type", "text": "int32_t", "parent": 318, "children": [], "start_point": {"row": 125, "column": 0}, "end_point": {"row": 125, "column": 7}}, {"id": 320, "type": "function_declarator", "text": "platform_write_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)", "parent": 318, "children": [321, 322], "start_point": {"row": 125, "column": 8}, "end_point": {"row": 125, "column": 86}}, {"id": 321, "type": "identifier", "text": "platform_write_stts751", "parent": 320, "children": [], "start_point": {"row": 125, "column": 8}, "end_point": {"row": 125, "column": 30}}, {"id": 322, "type": "parameter_list", "text": "(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)", "parent": 320, "children": [323, 328, 331, 336], "start_point": {"row": 125, "column": 30}, "end_point": {"row": 125, "column": 86}}, {"id": 323, "type": "parameter_declaration", "text": "void *handle", "parent": 322, "children": [324, 325], "start_point": {"row": 125, "column": 31}, "end_point": {"row": 125, "column": 43}}, {"id": 324, "type": "primitive_type", "text": "void", "parent": 323, "children": [], "start_point": {"row": 125, "column": 31}, "end_point": {"row": 125, "column": 35}}, {"id": 325, "type": "pointer_declarator", "text": "*handle", "parent": 323, "children": [326, 327], "start_point": {"row": 125, "column": 36}, "end_point": {"row": 125, "column": 43}}, {"id": 326, "type": "*", "text": "*", "parent": 325, "children": [], "start_point": {"row": 125, "column": 36}, "end_point": {"row": 125, "column": 37}}, {"id": 327, "type": "identifier", "text": "handle", "parent": 325, "children": [], "start_point": {"row": 125, "column": 37}, "end_point": {"row": 125, "column": 43}}, {"id": 328, "type": "parameter_declaration", "text": "uint8_t reg", "parent": 322, "children": [329, 330], "start_point": {"row": 125, "column": 45}, "end_point": {"row": 125, "column": 56}}, {"id": 329, "type": "primitive_type", "text": "uint8_t", "parent": 328, "children": [], "start_point": {"row": 125, "column": 45}, "end_point": {"row": 125, "column": 52}}, {"id": 330, "type": "identifier", "text": "reg", "parent": 328, "children": [], "start_point": {"row": 125, "column": 53}, "end_point": {"row": 125, "column": 56}}, {"id": 331, "type": "parameter_declaration", "text": "uint8_t *bufp", "parent": 322, "children": [332, 333], "start_point": {"row": 125, "column": 58}, "end_point": {"row": 125, "column": 71}}, {"id": 332, "type": "primitive_type", "text": "uint8_t", "parent": 331, "children": [], "start_point": {"row": 125, "column": 58}, "end_point": {"row": 125, "column": 65}}, {"id": 333, "type": "pointer_declarator", "text": "*bufp", "parent": 331, "children": [334, 335], "start_point": {"row": 125, "column": 66}, "end_point": {"row": 125, "column": 71}}, {"id": 334, "type": "*", "text": "*", "parent": 333, "children": [], "start_point": {"row": 125, "column": 66}, "end_point": {"row": 125, "column": 67}}, {"id": 335, "type": "identifier", "text": "bufp", "parent": 333, "children": [], "start_point": {"row": 125, "column": 67}, "end_point": {"row": 125, "column": 71}}, {"id": 336, "type": "parameter_declaration", "text": "uint16_t len", "parent": 322, "children": [337, 338], "start_point": {"row": 125, "column": 73}, "end_point": {"row": 125, "column": 85}}, {"id": 337, "type": "primitive_type", "text": "uint16_t", "parent": 336, "children": [], "start_point": {"row": 125, "column": 73}, "end_point": {"row": 125, "column": 81}}, {"id": 338, "type": "identifier", "text": "len", "parent": 336, "children": [], "start_point": {"row": 125, "column": 82}, "end_point": {"row": 125, "column": 85}}, {"id": 339, "type": "call_expression", "text": "HAL_I2C_Mem_Write(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)", "parent": 318, "children": [340, 341], "start_point": {"row": 127, "column": 1}, "end_point": {"row": 127, "column": 93}}, {"id": 340, "type": "identifier", "text": "HAL_I2C_Mem_Write", "parent": 339, "children": [], "start_point": {"row": 127, "column": 1}, "end_point": {"row": 127, "column": 18}}, {"id": 341, "type": "argument_list", "text": "(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)", "parent": 339, "children": [342, 343, 344, 345, 346, 347, 348], "start_point": {"row": 127, "column": 18}, "end_point": {"row": 127, "column": 93}}, {"id": 342, "type": "identifier", "text": "handle", "parent": 341, "children": [], "start_point": {"row": 127, "column": 19}, "end_point": {"row": 127, "column": 25}}, {"id": 343, "type": "identifier", "text": "STTS751_0xxxx_ADD_7K5", "parent": 341, "children": [], "start_point": {"row": 127, "column": 27}, "end_point": {"row": 127, "column": 48}}, {"id": 344, "type": "identifier", "text": "reg", "parent": 341, "children": [], "start_point": {"row": 127, "column": 50}, "end_point": {"row": 127, "column": 53}}, {"id": 345, "type": "identifier", "text": "I2C_MEMADD_SIZE_8BIT", "parent": 341, "children": [], "start_point": {"row": 127, "column": 55}, "end_point": {"row": 127, "column": 75}}, {"id": 346, "type": "identifier", "text": "bufp", "parent": 341, "children": [], "start_point": {"row": 127, "column": 77}, "end_point": {"row": 127, "column": 81}}, {"id": 347, "type": "identifier", "text": "len", "parent": 341, "children": [], "start_point": {"row": 127, "column": 83}, "end_point": {"row": 127, "column": 86}}, {"id": 348, "type": "number_literal", "text": "1000", "parent": 341, "children": [], "start_point": {"row": 127, "column": 88}, "end_point": {"row": 127, "column": 92}}, {"id": 349, "type": "return_statement", "text": "return 0;", "parent": 318, "children": [350], "start_point": {"row": 128, "column": 1}, "end_point": {"row": 128, "column": 10}}, {"id": 350, "type": "number_literal", "text": "0", "parent": 349, "children": [], "start_point": {"row": 128, "column": 8}, "end_point": {"row": 128, "column": 9}}, {"id": 351, "type": "function_definition", "text": "int32_t platform_read_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n\tHAL_I2C_Mem_Read(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n\treturn 0;\n}", "parent": null, "children": [352, 353], "start_point": {"row": 131, "column": 0}, "end_point": {"row": 135, "column": 1}}, {"id": 352, "type": "primitive_type", "text": "int32_t", "parent": 351, "children": [], "start_point": {"row": 131, "column": 0}, "end_point": {"row": 131, "column": 7}}, {"id": 353, "type": "function_declarator", "text": "platform_read_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)", "parent": 351, "children": [354, 355], "start_point": {"row": 131, "column": 8}, "end_point": {"row": 131, "column": 85}}, {"id": 354, "type": "identifier", "text": "platform_read_stts751", "parent": 353, "children": [], "start_point": {"row": 131, "column": 8}, "end_point": {"row": 131, "column": 29}}, {"id": 355, "type": "parameter_list", "text": "(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)", "parent": 353, "children": [356, 361, 364, 369], "start_point": {"row": 131, "column": 29}, "end_point": {"row": 131, "column": 85}}, {"id": 356, "type": "parameter_declaration", "text": "void *handle", "parent": 355, "children": [357, 358], "start_point": {"row": 131, "column": 30}, "end_point": {"row": 131, "column": 42}}, {"id": 357, "type": "primitive_type", "text": "void", "parent": 356, "children": [], "start_point": {"row": 131, "column": 30}, "end_point": {"row": 131, "column": 34}}, {"id": 358, "type": "pointer_declarator", "text": "*handle", "parent": 356, "children": [359, 360], "start_point": {"row": 131, "column": 35}, "end_point": {"row": 131, "column": 42}}, {"id": 359, "type": "*", "text": "*", "parent": 358, "children": [], "start_point": {"row": 131, "column": 35}, "end_point": {"row": 131, "column": 36}}, {"id": 360, "type": "identifier", "text": "handle", "parent": 358, "children": [], "start_point": {"row": 131, "column": 36}, "end_point": {"row": 131, "column": 42}}, {"id": 361, "type": "parameter_declaration", "text": "uint8_t reg", "parent": 355, "children": [362, 363], "start_point": {"row": 131, "column": 44}, "end_point": {"row": 131, "column": 55}}, {"id": 362, "type": "primitive_type", "text": "uint8_t", "parent": 361, "children": [], "start_point": {"row": 131, "column": 44}, "end_point": {"row": 131, "column": 51}}, {"id": 363, "type": "identifier", "text": "reg", "parent": 361, "children": [], "start_point": {"row": 131, "column": 52}, "end_point": {"row": 131, "column": 55}}, {"id": 364, "type": "parameter_declaration", "text": "uint8_t *bufp", "parent": 355, "children": [365, 366], "start_point": {"row": 131, "column": 57}, "end_point": {"row": 131, "column": 70}}, {"id": 365, "type": "primitive_type", "text": "uint8_t", "parent": 364, "children": [], "start_point": {"row": 131, "column": 57}, "end_point": {"row": 131, "column": 64}}, {"id": 366, "type": "pointer_declarator", "text": "*bufp", "parent": 364, "children": [367, 368], "start_point": {"row": 131, "column": 65}, "end_point": {"row": 131, "column": 70}}, {"id": 367, "type": "*", "text": "*", "parent": 366, "children": [], "start_point": {"row": 131, "column": 65}, "end_point": {"row": 131, "column": 66}}, {"id": 368, "type": "identifier", "text": "bufp", "parent": 366, "children": [], "start_point": {"row": 131, "column": 66}, "end_point": {"row": 131, "column": 70}}, {"id": 369, "type": "parameter_declaration", "text": "uint16_t len", "parent": 355, "children": [370, 371], "start_point": {"row": 131, "column": 72}, "end_point": {"row": 131, "column": 84}}, {"id": 370, "type": "primitive_type", "text": "uint16_t", "parent": 369, "children": [], "start_point": {"row": 131, "column": 72}, "end_point": {"row": 131, "column": 80}}, {"id": 371, "type": "identifier", "text": "len", "parent": 369, "children": [], "start_point": {"row": 131, "column": 81}, "end_point": {"row": 131, "column": 84}}, {"id": 372, "type": "call_expression", "text": "HAL_I2C_Mem_Read(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)", "parent": 351, "children": [373, 374], "start_point": {"row": 133, "column": 1}, "end_point": {"row": 133, "column": 92}}, {"id": 373, "type": "identifier", "text": "HAL_I2C_Mem_Read", "parent": 372, "children": [], "start_point": {"row": 133, "column": 1}, "end_point": {"row": 133, "column": 17}}, {"id": 374, "type": "argument_list", "text": "(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)", "parent": 372, "children": [375, 376, 377, 378, 379, 380, 381], "start_point": {"row": 133, "column": 17}, "end_point": {"row": 133, "column": 92}}, {"id": 375, "type": "identifier", "text": "handle", "parent": 374, "children": [], "start_point": {"row": 133, "column": 18}, "end_point": {"row": 133, "column": 24}}, {"id": 376, "type": "identifier", "text": "STTS751_0xxxx_ADD_7K5", "parent": 374, "children": [], "start_point": {"row": 133, "column": 26}, "end_point": {"row": 133, "column": 47}}, {"id": 377, "type": "identifier", "text": "reg", "parent": 374, "children": [], "start_point": {"row": 133, "column": 49}, "end_point": {"row": 133, "column": 52}}, {"id": 378, "type": "identifier", "text": "I2C_MEMADD_SIZE_8BIT", "parent": 374, "children": [], "start_point": {"row": 133, "column": 54}, "end_point": {"row": 133, "column": 74}}, {"id": 379, "type": "identifier", "text": "bufp", "parent": 374, "children": [], "start_point": {"row": 133, "column": 76}, "end_point": {"row": 133, "column": 80}}, {"id": 380, "type": "identifier", "text": "len", "parent": 374, "children": [], "start_point": {"row": 133, "column": 82}, "end_point": {"row": 133, "column": 85}}, {"id": 381, "type": "number_literal", "text": "1000", "parent": 374, "children": [], "start_point": {"row": 133, "column": 87}, "end_point": {"row": 133, "column": 91}}, {"id": 382, "type": "return_statement", "text": "return 0;", "parent": 351, "children": [383], "start_point": {"row": 134, "column": 1}, "end_point": {"row": 134, "column": 10}}, {"id": 383, "type": "number_literal", "text": "0", "parent": 382, "children": [], "start_point": {"row": 134, "column": 8}, "end_point": {"row": 134, "column": 9}}, {"id": 384, "type": "function_definition", "text": "int init_lps22hh(I2C_HandleTypeDef *lps22hh_bus)\n{\n\tuint8_t lps22hh_whoamI;\n\tuint8_t lps22hh_rst;\n\n\tlps22hh_dev_ctx.write_reg = platform_write_lps22hh;\n\tlps22hh_dev_ctx.read_reg = platform_read_lps22hh;\n\tlps22hh_dev_ctx.handle = lps22hh_bus;\n\n\tlps22hh_device_id_get(&lps22hh_dev_ctx, &lps22hh_whoamI);\n\tif (lps22hh_whoamI != LPS22HH_ID)\n\t{\n\t\treturn -1;\n\t}\n\n\tlps22hh_reset_set(&lps22hh_dev_ctx, PROPERTY_ENABLE);\n\tdo {\n\t lps22hh_reset_get(&lps22hh_dev_ctx, &lps22hh_rst);\n\t} while (lps22hh_rst);\n\n\t/* Enable Block Data Update */\n\tlps22hh_block_data_update_set(&lps22hh_dev_ctx, PROPERTY_ENABLE);\n\t/* Set Output Data Rate */\n\tlps22hh_data_rate_set(&lps22hh_dev_ctx, LPS22HH_10_Hz_LOW_NOISE);\n\n\treturn 0;\n}", "parent": null, "children": [385, 386], "start_point": {"row": 138, "column": 0}, "end_point": {"row": 164, "column": 1}}, {"id": 385, "type": "primitive_type", "text": "int", "parent": 384, "children": [], "start_point": {"row": 138, "column": 0}, "end_point": {"row": 138, "column": 3}}, {"id": 386, "type": "function_declarator", "text": "init_lps22hh(I2C_HandleTypeDef *lps22hh_bus)", "parent": 384, "children": [387, 388], "start_point": {"row": 138, "column": 4}, "end_point": {"row": 138, "column": 48}}, {"id": 387, "type": "identifier", "text": "init_lps22hh", "parent": 386, "children": [], "start_point": {"row": 138, "column": 4}, "end_point": {"row": 138, "column": 16}}, {"id": 388, "type": "parameter_list", "text": "(I2C_HandleTypeDef *lps22hh_bus)", "parent": 386, "children": [389], "start_point": {"row": 138, "column": 16}, "end_point": {"row": 138, "column": 48}}, {"id": 389, "type": "parameter_declaration", "text": "I2C_HandleTypeDef *lps22hh_bus", "parent": 388, "children": [390, 391], "start_point": {"row": 138, "column": 17}, "end_point": {"row": 138, "column": 47}}, {"id": 390, "type": "type_identifier", "text": "I2C_HandleTypeDef", "parent": 389, "children": [], "start_point": {"row": 138, "column": 17}, "end_point": {"row": 138, "column": 34}}, {"id": 391, "type": "pointer_declarator", "text": "*lps22hh_bus", "parent": 389, "children": [392, 393], "start_point": {"row": 138, "column": 35}, "end_point": {"row": 138, "column": 47}}, {"id": 392, "type": "*", "text": "*", "parent": 391, "children": [], "start_point": {"row": 138, "column": 35}, "end_point": {"row": 138, "column": 36}}, {"id": 393, "type": "identifier", "text": "lps22hh_bus", "parent": 391, "children": [], "start_point": {"row": 138, "column": 36}, "end_point": {"row": 138, "column": 47}}, {"id": 394, "type": "declaration", "text": "uint8_t lps22hh_whoamI;", "parent": 384, "children": [395, 396], "start_point": {"row": 140, "column": 1}, "end_point": {"row": 140, "column": 24}}, {"id": 395, "type": "primitive_type", "text": "uint8_t", "parent": 394, "children": [], "start_point": {"row": 140, "column": 1}, "end_point": {"row": 140, "column": 8}}, {"id": 396, "type": "identifier", "text": "lps22hh_whoamI", "parent": 394, "children": [], "start_point": {"row": 140, "column": 9}, "end_point": {"row": 140, "column": 23}}, {"id": 397, "type": "declaration", "text": "uint8_t lps22hh_rst;", "parent": 384, "children": [398, 399], "start_point": {"row": 141, "column": 1}, "end_point": {"row": 141, "column": 21}}, {"id": 398, "type": "primitive_type", "text": "uint8_t", "parent": 397, "children": [], "start_point": {"row": 141, "column": 1}, "end_point": {"row": 141, "column": 8}}, {"id": 399, "type": "identifier", "text": "lps22hh_rst", "parent": 397, "children": [], "start_point": {"row": 141, "column": 9}, "end_point": {"row": 141, "column": 20}}, {"id": 400, "type": "assignment_expression", "text": "lps22hh_dev_ctx.write_reg = platform_write_lps22hh", "parent": 384, "children": [401, 404, 405], "start_point": {"row": 143, "column": 1}, "end_point": {"row": 143, "column": 51}}, {"id": 401, "type": "field_expression", "text": "lps22hh_dev_ctx.write_reg", "parent": 400, "children": [402, 403], "start_point": {"row": 143, "column": 1}, "end_point": {"row": 143, "column": 26}}, {"id": 402, "type": "identifier", "text": "lps22hh_dev_ctx", "parent": 401, "children": [], "start_point": {"row": 143, "column": 1}, "end_point": {"row": 143, "column": 16}}, {"id": 403, "type": "field_identifier", "text": "write_reg", "parent": 401, "children": [], "start_point": {"row": 143, "column": 17}, "end_point": {"row": 143, "column": 26}}, {"id": 404, "type": "=", "text": "=", "parent": 400, "children": [], "start_point": {"row": 143, "column": 27}, "end_point": {"row": 143, "column": 28}}, {"id": 405, "type": "identifier", "text": "platform_write_lps22hh", "parent": 400, "children": [], "start_point": {"row": 143, "column": 29}, "end_point": {"row": 143, "column": 51}}, {"id": 406, "type": "assignment_expression", "text": "lps22hh_dev_ctx.read_reg = platform_read_lps22hh", "parent": 384, "children": [407, 410, 411], "start_point": {"row": 144, "column": 1}, "end_point": {"row": 144, "column": 49}}, {"id": 407, "type": "field_expression", "text": "lps22hh_dev_ctx.read_reg", "parent": 406, "children": [408, 409], "start_point": {"row": 144, "column": 1}, "end_point": {"row": 144, "column": 25}}, {"id": 408, "type": "identifier", "text": "lps22hh_dev_ctx", "parent": 407, "children": [], "start_point": {"row": 144, "column": 1}, "end_point": {"row": 144, "column": 16}}, {"id": 409, "type": "field_identifier", "text": "read_reg", "parent": 407, "children": [], "start_point": {"row": 144, "column": 17}, "end_point": {"row": 144, "column": 25}}, {"id": 410, "type": "=", "text": "=", "parent": 406, "children": [], "start_point": {"row": 144, "column": 26}, "end_point": {"row": 144, "column": 27}}, {"id": 411, "type": "identifier", "text": "platform_read_lps22hh", "parent": 406, "children": [], "start_point": {"row": 144, "column": 28}, "end_point": {"row": 144, "column": 49}}, {"id": 412, "type": "assignment_expression", "text": "lps22hh_dev_ctx.handle = lps22hh_bus", "parent": 384, "children": [413, 416, 417], "start_point": {"row": 145, "column": 1}, "end_point": {"row": 145, "column": 37}}, {"id": 413, "type": "field_expression", "text": "lps22hh_dev_ctx.handle", "parent": 412, "children": [414, 415], "start_point": {"row": 145, "column": 1}, "end_point": {"row": 145, "column": 23}}, {"id": 414, "type": "identifier", "text": "lps22hh_dev_ctx", "parent": 413, "children": [], "start_point": {"row": 145, "column": 1}, "end_point": {"row": 145, "column": 16}}, {"id": 415, "type": "field_identifier", "text": "handle", "parent": 413, "children": [], "start_point": {"row": 145, "column": 17}, "end_point": {"row": 145, "column": 23}}, {"id": 416, "type": "=", "text": "=", "parent": 412, "children": [], "start_point": {"row": 145, "column": 24}, "end_point": {"row": 145, "column": 25}}, {"id": 417, "type": "identifier", "text": "lps22hh_bus", "parent": 412, "children": [], "start_point": {"row": 145, "column": 26}, "end_point": {"row": 145, "column": 37}}, {"id": 418, "type": "call_expression", "text": "lps22hh_device_id_get(&lps22hh_dev_ctx, &lps22hh_whoamI)", "parent": 384, "children": [419, 420], "start_point": {"row": 147, "column": 1}, "end_point": {"row": 147, "column": 57}}, {"id": 419, "type": "identifier", "text": "lps22hh_device_id_get", "parent": 418, "children": [], "start_point": {"row": 147, "column": 1}, "end_point": {"row": 147, "column": 22}}, {"id": 420, "type": "argument_list", "text": "(&lps22hh_dev_ctx, &lps22hh_whoamI)", "parent": 418, "children": [421, 423], "start_point": {"row": 147, "column": 22}, "end_point": {"row": 147, "column": 57}}, {"id": 421, "type": "pointer_expression", "text": "&lps22hh_dev_ctx", "parent": 420, "children": [422], "start_point": {"row": 147, "column": 23}, "end_point": {"row": 147, "column": 39}}, {"id": 422, "type": "identifier", "text": "lps22hh_dev_ctx", "parent": 421, "children": [], "start_point": {"row": 147, "column": 24}, "end_point": {"row": 147, "column": 39}}, {"id": 423, "type": "pointer_expression", "text": "&lps22hh_whoamI", "parent": 420, "children": [424], "start_point": {"row": 147, "column": 41}, "end_point": {"row": 147, "column": 56}}, {"id": 424, "type": "identifier", "text": "lps22hh_whoamI", "parent": 423, "children": [], "start_point": {"row": 147, "column": 42}, "end_point": {"row": 147, "column": 56}}, {"id": 425, "type": "if_statement", "text": "if (lps22hh_whoamI != LPS22HH_ID)\n\t{\n\t\treturn -1;\n\t}", "parent": 384, "children": [426], "start_point": {"row": 148, "column": 1}, "end_point": {"row": 151, "column": 2}}, {"id": 426, "type": "parenthesized_expression", "text": "(lps22hh_whoamI != LPS22HH_ID)", "parent": 425, "children": [427], "start_point": {"row": 148, "column": 4}, "end_point": {"row": 148, "column": 34}}, {"id": 427, "type": "binary_expression", "text": "lps22hh_whoamI != LPS22HH_ID", "parent": 426, "children": [428, 429, 430], "start_point": {"row": 148, "column": 5}, "end_point": {"row": 148, "column": 33}}, {"id": 428, "type": "identifier", "text": "lps22hh_whoamI", "parent": 427, "children": [], "start_point": {"row": 148, "column": 5}, "end_point": {"row": 148, "column": 19}}, {"id": 429, "type": "!=", "text": "!=", "parent": 427, "children": [], "start_point": {"row": 148, "column": 20}, "end_point": {"row": 148, "column": 22}}, {"id": 430, "type": "identifier", "text": "LPS22HH_ID", "parent": 427, "children": [], "start_point": {"row": 148, "column": 23}, "end_point": {"row": 148, "column": 33}}, {"id": 431, "type": "return_statement", "text": "return -1;", "parent": 425, "children": [432], "start_point": {"row": 150, "column": 2}, "end_point": {"row": 150, "column": 12}}, {"id": 432, "type": "number_literal", "text": "-1", "parent": 431, "children": [], "start_point": {"row": 150, "column": 9}, "end_point": {"row": 150, "column": 11}}, {"id": 433, "type": "call_expression", "text": "lps22hh_reset_set(&lps22hh_dev_ctx, PROPERTY_ENABLE)", "parent": 384, "children": [434, 435], "start_point": {"row": 153, "column": 1}, "end_point": {"row": 153, "column": 53}}, {"id": 434, "type": "identifier", "text": "lps22hh_reset_set", "parent": 433, "children": [], "start_point": {"row": 153, "column": 1}, "end_point": {"row": 153, "column": 18}}, {"id": 435, "type": "argument_list", "text": "(&lps22hh_dev_ctx, PROPERTY_ENABLE)", "parent": 433, "children": [436, 438], "start_point": {"row": 153, "column": 18}, "end_point": {"row": 153, "column": 53}}, {"id": 436, "type": "pointer_expression", "text": "&lps22hh_dev_ctx", "parent": 435, "children": [437], "start_point": {"row": 153, "column": 19}, "end_point": {"row": 153, "column": 35}}, {"id": 437, "type": "identifier", "text": "lps22hh_dev_ctx", "parent": 436, "children": [], "start_point": {"row": 153, "column": 20}, "end_point": {"row": 153, "column": 35}}, {"id": 438, "type": "identifier", "text": "PROPERTY_ENABLE", "parent": 435, "children": [], "start_point": {"row": 153, "column": 37}, "end_point": {"row": 153, "column": 52}}, {"id": 439, "type": "do_statement", "text": "do {\n\t lps22hh_reset_get(&lps22hh_dev_ctx, &lps22hh_rst);\n\t} while (lps22hh_rst);", "parent": 384, "children": [447], "start_point": {"row": 154, "column": 1}, "end_point": {"row": 156, "column": 23}}, {"id": 440, "type": "call_expression", "text": "lps22hh_reset_get(&lps22hh_dev_ctx, &lps22hh_rst)", "parent": 439, "children": [441, 442], "start_point": {"row": 155, "column": 3}, "end_point": {"row": 155, "column": 52}}, {"id": 441, "type": "identifier", "text": "lps22hh_reset_get", "parent": 440, "children": [], "start_point": {"row": 155, "column": 3}, "end_point": {"row": 155, "column": 20}}, {"id": 442, "type": "argument_list", "text": "(&lps22hh_dev_ctx, &lps22hh_rst)", "parent": 440, "children": [443, 445], "start_point": {"row": 155, "column": 20}, "end_point": {"row": 155, "column": 52}}, {"id": 443, "type": "pointer_expression", "text": "&lps22hh_dev_ctx", "parent": 442, "children": [444], "start_point": {"row": 155, "column": 21}, "end_point": {"row": 155, "column": 37}}, {"id": 444, "type": "identifier", "text": "lps22hh_dev_ctx", "parent": 443, "children": [], "start_point": {"row": 155, "column": 22}, "end_point": {"row": 155, "column": 37}}, {"id": 445, "type": "pointer_expression", "text": "&lps22hh_rst", "parent": 442, "children": [446], "start_point": {"row": 155, "column": 39}, "end_point": {"row": 155, "column": 51}}, {"id": 446, "type": "identifier", "text": "lps22hh_rst", "parent": 445, "children": [], "start_point": {"row": 155, "column": 40}, "end_point": {"row": 155, "column": 51}}, {"id": 447, "type": "parenthesized_expression", "text": "(lps22hh_rst)", "parent": 439, "children": [448], "start_point": {"row": 156, "column": 9}, "end_point": {"row": 156, "column": 22}}, {"id": 448, "type": "identifier", "text": "lps22hh_rst", "parent": 447, "children": [], "start_point": {"row": 156, "column": 10}, "end_point": {"row": 156, "column": 21}}, {"id": 449, "type": "call_expression", "text": "lps22hh_block_data_update_set(&lps22hh_dev_ctx, PROPERTY_ENABLE)", "parent": 384, "children": [450, 451], "start_point": {"row": 159, "column": 1}, "end_point": {"row": 159, "column": 65}}, {"id": 450, "type": "identifier", "text": "lps22hh_block_data_update_set", "parent": 449, "children": [], "start_point": {"row": 159, "column": 1}, "end_point": {"row": 159, "column": 30}}, {"id": 451, "type": "argument_list", "text": "(&lps22hh_dev_ctx, PROPERTY_ENABLE)", "parent": 449, "children": [452, 454], "start_point": {"row": 159, "column": 30}, "end_point": {"row": 159, "column": 65}}, {"id": 452, "type": "pointer_expression", "text": "&lps22hh_dev_ctx", "parent": 451, "children": [453], "start_point": {"row": 159, "column": 31}, "end_point": {"row": 159, "column": 47}}, {"id": 453, "type": "identifier", "text": "lps22hh_dev_ctx", "parent": 452, "children": [], "start_point": {"row": 159, "column": 32}, "end_point": {"row": 159, "column": 47}}, {"id": 454, "type": "identifier", "text": "PROPERTY_ENABLE", "parent": 451, "children": [], "start_point": {"row": 159, "column": 49}, "end_point": {"row": 159, "column": 64}}, {"id": 455, "type": "call_expression", "text": "lps22hh_data_rate_set(&lps22hh_dev_ctx, LPS22HH_10_Hz_LOW_NOISE)", "parent": 384, "children": [456, 457], "start_point": {"row": 161, "column": 1}, "end_point": {"row": 161, "column": 65}}, {"id": 456, "type": "identifier", "text": "lps22hh_data_rate_set", "parent": 455, "children": [], "start_point": {"row": 161, "column": 1}, "end_point": {"row": 161, "column": 22}}, {"id": 457, "type": "argument_list", "text": "(&lps22hh_dev_ctx, LPS22HH_10_Hz_LOW_NOISE)", "parent": 455, "children": [458, 460], "start_point": {"row": 161, "column": 22}, "end_point": {"row": 161, "column": 65}}, {"id": 458, "type": "pointer_expression", "text": "&lps22hh_dev_ctx", "parent": 457, "children": [459], "start_point": {"row": 161, "column": 23}, "end_point": {"row": 161, "column": 39}}, {"id": 459, "type": "identifier", "text": "lps22hh_dev_ctx", "parent": 458, "children": [], "start_point": {"row": 161, "column": 24}, "end_point": {"row": 161, "column": 39}}, {"id": 460, "type": "identifier", "text": "LPS22HH_10_Hz_LOW_NOISE", "parent": 457, "children": [], "start_point": {"row": 161, "column": 41}, "end_point": {"row": 161, "column": 64}}, {"id": 461, "type": "return_statement", "text": "return 0;", "parent": 384, "children": [462], "start_point": {"row": 163, "column": 1}, "end_point": {"row": 163, "column": 10}}, {"id": 462, "type": "number_literal", "text": "0", "parent": 461, "children": [], "start_point": {"row": 163, "column": 8}, "end_point": {"row": 163, "column": 9}}, {"id": 463, "type": "function_definition", "text": "int32_t platform_write_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n\tHAL_I2C_Mem_Write(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n\treturn 0;\n}", "parent": null, "children": [464, 465], "start_point": {"row": 166, "column": 0}, "end_point": {"row": 170, "column": 1}}, {"id": 464, "type": "primitive_type", "text": "int32_t", "parent": 463, "children": [], "start_point": {"row": 166, "column": 0}, "end_point": {"row": 166, "column": 7}}, {"id": 465, "type": "function_declarator", "text": "platform_write_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)", "parent": 463, "children": [466, 467], "start_point": {"row": 166, "column": 8}, "end_point": {"row": 166, "column": 86}}, {"id": 466, "type": "identifier", "text": "platform_write_lps22hh", "parent": 465, "children": [], "start_point": {"row": 166, "column": 8}, "end_point": {"row": 166, "column": 30}}, {"id": 467, "type": "parameter_list", "text": "(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)", "parent": 465, "children": [468, 473, 476, 481], "start_point": {"row": 166, "column": 30}, "end_point": {"row": 166, "column": 86}}, {"id": 468, "type": "parameter_declaration", "text": "void *handle", "parent": 467, "children": [469, 470], "start_point": {"row": 166, "column": 31}, "end_point": {"row": 166, "column": 43}}, {"id": 469, "type": "primitive_type", "text": "void", "parent": 468, "children": [], "start_point": {"row": 166, "column": 31}, "end_point": {"row": 166, "column": 35}}, {"id": 470, "type": "pointer_declarator", "text": "*handle", "parent": 468, "children": [471, 472], "start_point": {"row": 166, "column": 36}, "end_point": {"row": 166, "column": 43}}, {"id": 471, "type": "*", "text": "*", "parent": 470, "children": [], "start_point": {"row": 166, "column": 36}, "end_point": {"row": 166, "column": 37}}, {"id": 472, "type": "identifier", "text": "handle", "parent": 470, "children": [], "start_point": {"row": 166, "column": 37}, "end_point": {"row": 166, "column": 43}}, {"id": 473, "type": "parameter_declaration", "text": "uint8_t reg", "parent": 467, "children": [474, 475], "start_point": {"row": 166, "column": 45}, "end_point": {"row": 166, "column": 56}}, {"id": 474, "type": "primitive_type", "text": "uint8_t", "parent": 473, "children": [], "start_point": {"row": 166, "column": 45}, "end_point": {"row": 166, "column": 52}}, {"id": 475, "type": "identifier", "text": "reg", "parent": 473, "children": [], "start_point": {"row": 166, "column": 53}, "end_point": {"row": 166, "column": 56}}, {"id": 476, "type": "parameter_declaration", "text": "uint8_t *bufp", "parent": 467, "children": [477, 478], "start_point": {"row": 166, "column": 58}, "end_point": {"row": 166, "column": 71}}, {"id": 477, "type": "primitive_type", "text": "uint8_t", "parent": 476, "children": [], "start_point": {"row": 166, "column": 58}, "end_point": {"row": 166, "column": 65}}, {"id": 478, "type": "pointer_declarator", "text": "*bufp", "parent": 476, "children": [479, 480], "start_point": {"row": 166, "column": 66}, "end_point": {"row": 166, "column": 71}}, {"id": 479, "type": "*", "text": "*", "parent": 478, "children": [], "start_point": {"row": 166, "column": 66}, "end_point": {"row": 166, "column": 67}}, {"id": 480, "type": "identifier", "text": "bufp", "parent": 478, "children": [], "start_point": {"row": 166, "column": 67}, "end_point": {"row": 166, "column": 71}}, {"id": 481, "type": "parameter_declaration", "text": "uint16_t len", "parent": 467, "children": [482, 483], "start_point": {"row": 166, "column": 73}, "end_point": {"row": 166, "column": 85}}, {"id": 482, "type": "primitive_type", "text": "uint16_t", "parent": 481, "children": [], "start_point": {"row": 166, "column": 73}, "end_point": {"row": 166, "column": 81}}, {"id": 483, "type": "identifier", "text": "len", "parent": 481, "children": [], "start_point": {"row": 166, "column": 82}, "end_point": {"row": 166, "column": 85}}, {"id": 484, "type": "call_expression", "text": "HAL_I2C_Mem_Write(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)", "parent": 463, "children": [485, 486], "start_point": {"row": 168, "column": 1}, "end_point": {"row": 168, "column": 89}}, {"id": 485, "type": "identifier", "text": "HAL_I2C_Mem_Write", "parent": 484, "children": [], "start_point": {"row": 168, "column": 1}, "end_point": {"row": 168, "column": 18}}, {"id": 486, "type": "argument_list", "text": "(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)", "parent": 484, "children": [487, 488, 489, 490, 491, 492, 493], "start_point": {"row": 168, "column": 18}, "end_point": {"row": 168, "column": 89}}, {"id": 487, "type": "identifier", "text": "handle", "parent": 486, "children": [], "start_point": {"row": 168, "column": 19}, "end_point": {"row": 168, "column": 25}}, {"id": 488, "type": "identifier", "text": "LPS22HH_I2C_ADD_H", "parent": 486, "children": [], "start_point": {"row": 168, "column": 27}, "end_point": {"row": 168, "column": 44}}, {"id": 489, "type": "identifier", "text": "reg", "parent": 486, "children": [], "start_point": {"row": 168, "column": 46}, "end_point": {"row": 168, "column": 49}}, {"id": 490, "type": "identifier", "text": "I2C_MEMADD_SIZE_8BIT", "parent": 486, "children": [], "start_point": {"row": 168, "column": 51}, "end_point": {"row": 168, "column": 71}}, {"id": 491, "type": "identifier", "text": "bufp", "parent": 486, "children": [], "start_point": {"row": 168, "column": 73}, "end_point": {"row": 168, "column": 77}}, {"id": 492, "type": "identifier", "text": "len", "parent": 486, "children": [], "start_point": {"row": 168, "column": 79}, "end_point": {"row": 168, "column": 82}}, {"id": 493, "type": "number_literal", "text": "1000", "parent": 486, "children": [], "start_point": {"row": 168, "column": 84}, "end_point": {"row": 168, "column": 88}}, {"id": 494, "type": "return_statement", "text": "return 0;", "parent": 463, "children": [495], "start_point": {"row": 169, "column": 1}, "end_point": {"row": 169, "column": 10}}, {"id": 495, "type": "number_literal", "text": "0", "parent": 494, "children": [], "start_point": {"row": 169, "column": 8}, "end_point": {"row": 169, "column": 9}}, {"id": 496, "type": "function_definition", "text": "int32_t platform_read_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n\tHAL_I2C_Mem_Read(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n}", "parent": null, "children": [497, 498], "start_point": {"row": 172, "column": 0}, "end_point": {"row": 175, "column": 1}}, {"id": 497, "type": "primitive_type", "text": "int32_t", "parent": 496, "children": [], "start_point": {"row": 172, "column": 0}, "end_point": {"row": 172, "column": 7}}, {"id": 498, "type": "function_declarator", "text": "platform_read_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)", "parent": 496, "children": [499, 500], "start_point": {"row": 172, "column": 8}, "end_point": {"row": 172, "column": 85}}, {"id": 499, "type": "identifier", "text": "platform_read_lps22hh", "parent": 498, "children": [], "start_point": {"row": 172, "column": 8}, "end_point": {"row": 172, "column": 29}}, {"id": 500, "type": "parameter_list", "text": "(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)", "parent": 498, "children": [501, 506, 509, 514], "start_point": {"row": 172, "column": 29}, "end_point": {"row": 172, "column": 85}}, {"id": 501, "type": "parameter_declaration", "text": "void *handle", "parent": 500, "children": [502, 503], "start_point": {"row": 172, "column": 30}, "end_point": {"row": 172, "column": 42}}, {"id": 502, "type": "primitive_type", "text": "void", "parent": 501, "children": [], "start_point": {"row": 172, "column": 30}, "end_point": {"row": 172, "column": 34}}, {"id": 503, "type": "pointer_declarator", "text": "*handle", "parent": 501, "children": [504, 505], "start_point": {"row": 172, "column": 35}, "end_point": {"row": 172, "column": 42}}, {"id": 504, "type": "*", "text": "*", "parent": 503, "children": [], "start_point": {"row": 172, "column": 35}, "end_point": {"row": 172, "column": 36}}, {"id": 505, "type": "identifier", "text": "handle", "parent": 503, "children": [], "start_point": {"row": 172, "column": 36}, "end_point": {"row": 172, "column": 42}}, {"id": 506, "type": "parameter_declaration", "text": "uint8_t reg", "parent": 500, "children": [507, 508], "start_point": {"row": 172, "column": 44}, "end_point": {"row": 172, "column": 55}}, {"id": 507, "type": "primitive_type", "text": "uint8_t", "parent": 506, "children": [], "start_point": {"row": 172, "column": 44}, "end_point": {"row": 172, "column": 51}}, {"id": 508, "type": "identifier", "text": "reg", "parent": 506, "children": [], "start_point": {"row": 172, "column": 52}, "end_point": {"row": 172, "column": 55}}, {"id": 509, "type": "parameter_declaration", "text": "uint8_t *bufp", "parent": 500, "children": [510, 511], "start_point": {"row": 172, "column": 57}, "end_point": {"row": 172, "column": 70}}, {"id": 510, "type": "primitive_type", "text": "uint8_t", "parent": 509, "children": [], "start_point": {"row": 172, "column": 57}, "end_point": {"row": 172, "column": 64}}, {"id": 511, "type": "pointer_declarator", "text": "*bufp", "parent": 509, "children": [512, 513], "start_point": {"row": 172, "column": 65}, "end_point": {"row": 172, "column": 70}}, {"id": 512, "type": "*", "text": "*", "parent": 511, "children": [], "start_point": {"row": 172, "column": 65}, "end_point": {"row": 172, "column": 66}}, {"id": 513, "type": "identifier", "text": "bufp", "parent": 511, "children": [], "start_point": {"row": 172, "column": 66}, "end_point": {"row": 172, "column": 70}}, {"id": 514, "type": "parameter_declaration", "text": "uint16_t len", "parent": 500, "children": [515, 516], "start_point": {"row": 172, "column": 72}, "end_point": {"row": 172, "column": 84}}, {"id": 515, "type": "primitive_type", "text": "uint16_t", "parent": 514, "children": [], "start_point": {"row": 172, "column": 72}, "end_point": {"row": 172, "column": 80}}, {"id": 516, "type": "identifier", "text": "len", "parent": 514, "children": [], "start_point": {"row": 172, "column": 81}, "end_point": {"row": 172, "column": 84}}, {"id": 517, "type": "call_expression", "text": "HAL_I2C_Mem_Read(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)", "parent": 496, "children": [518, 519], "start_point": {"row": 174, "column": 1}, "end_point": {"row": 174, "column": 88}}, {"id": 518, "type": "identifier", "text": "HAL_I2C_Mem_Read", "parent": 517, "children": [], "start_point": {"row": 174, "column": 1}, "end_point": {"row": 174, "column": 17}}, {"id": 519, "type": "argument_list", "text": "(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)", "parent": 517, "children": [520, 521, 522, 523, 524, 525, 526], "start_point": {"row": 174, "column": 17}, "end_point": {"row": 174, "column": 88}}, {"id": 520, "type": "identifier", "text": "handle", "parent": 519, "children": [], "start_point": {"row": 174, "column": 18}, "end_point": {"row": 174, "column": 24}}, {"id": 521, "type": "identifier", "text": "LPS22HH_I2C_ADD_H", "parent": 519, "children": [], "start_point": {"row": 174, "column": 26}, "end_point": {"row": 174, "column": 43}}, {"id": 522, "type": "identifier", "text": "reg", "parent": 519, "children": [], "start_point": {"row": 174, "column": 45}, "end_point": {"row": 174, "column": 48}}, {"id": 523, "type": "identifier", "text": "I2C_MEMADD_SIZE_8BIT", "parent": 519, "children": [], "start_point": {"row": 174, "column": 50}, "end_point": {"row": 174, "column": 70}}, {"id": 524, "type": "identifier", "text": "bufp", "parent": 519, "children": [], "start_point": {"row": 174, "column": 72}, "end_point": {"row": 174, "column": 76}}, {"id": 525, "type": "identifier", "text": "len", "parent": 519, "children": [], "start_point": {"row": 174, "column": 78}, "end_point": {"row": 174, "column": 81}}, {"id": 526, "type": "number_literal", "text": "1000", "parent": 519, "children": [], "start_point": {"row": 174, "column": 83}, "end_point": {"row": 174, "column": 87}}, {"id": 527, "type": "function_definition", "text": "int init_hts221(I2C_HandleTypeDef *hts221_bus)\n{\n\tuint8_t hts221_whoamI;\n\n\thts221_dev_ctx.write_reg = platform_write_hts221;\n\thts221_dev_ctx.read_reg = platform_read_hts221;\n\thts221_dev_ctx.handle = hts221_bus;\n\n\thts221_whoamI = 0;\n\thts221_device_id_get(&hts221_dev_ctx, &hts221_whoamI);\n\tif (hts221_whoamI != HTS221_ID)\n\t{\n\t\treturn -1;\n\t}\n\n\thts221_hum_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.x0);\n\thts221_hum_rh_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.y0);\n\thts221_hum_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.x1);\n\thts221_hum_rh_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.y1);\n\t/* Read temperature calibration coefficient */\n\thts221_temp_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.x0);\n\thts221_temp_deg_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.y0);\n\thts221_temp_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.x1);\n\thts221_temp_deg_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.y1);\n\t/* Enable Block Data Update */\n\thts221_block_data_update_set(&hts221_dev_ctx, PROPERTY_ENABLE);\n\t/* Set Output Data Rate */\n\thts221_data_rate_set(&hts221_dev_ctx, HTS221_ODR_7Hz);\n\t/* Device power on */\n\thts221_power_on_set(&hts221_dev_ctx, PROPERTY_ENABLE);\n\n\treturn 0;\n}", "parent": null, "children": [528, 529], "start_point": {"row": 178, "column": 0}, "end_point": {"row": 210, "column": 1}}, {"id": 528, "type": "primitive_type", "text": "int", "parent": 527, "children": [], "start_point": {"row": 178, "column": 0}, "end_point": {"row": 178, "column": 3}}, {"id": 529, "type": "function_declarator", "text": "init_hts221(I2C_HandleTypeDef *hts221_bus)", "parent": 527, "children": [530, 531], "start_point": {"row": 178, "column": 4}, "end_point": {"row": 178, "column": 46}}, {"id": 530, "type": "identifier", "text": "init_hts221", "parent": 529, "children": [], "start_point": {"row": 178, "column": 4}, "end_point": {"row": 178, "column": 15}}, {"id": 531, "type": "parameter_list", "text": "(I2C_HandleTypeDef *hts221_bus)", "parent": 529, "children": [532], "start_point": {"row": 178, "column": 15}, "end_point": {"row": 178, "column": 46}}, {"id": 532, "type": "parameter_declaration", "text": "I2C_HandleTypeDef *hts221_bus", "parent": 531, "children": [533, 534], "start_point": {"row": 178, "column": 16}, "end_point": {"row": 178, "column": 45}}, {"id": 533, "type": "type_identifier", "text": "I2C_HandleTypeDef", "parent": 532, "children": [], "start_point": {"row": 178, "column": 16}, "end_point": {"row": 178, "column": 33}}, {"id": 534, "type": "pointer_declarator", "text": "*hts221_bus", "parent": 532, "children": [535, 536], "start_point": {"row": 178, "column": 34}, "end_point": {"row": 178, "column": 45}}, {"id": 535, "type": "*", "text": "*", "parent": 534, "children": [], "start_point": {"row": 178, "column": 34}, "end_point": {"row": 178, "column": 35}}, {"id": 536, "type": "identifier", "text": "hts221_bus", "parent": 534, "children": [], "start_point": {"row": 178, "column": 35}, "end_point": {"row": 178, "column": 45}}, {"id": 537, "type": "declaration", "text": "uint8_t hts221_whoamI;", "parent": 527, "children": [538, 539], "start_point": {"row": 180, "column": 1}, "end_point": {"row": 180, "column": 23}}, {"id": 538, "type": "primitive_type", "text": "uint8_t", "parent": 537, "children": [], "start_point": {"row": 180, "column": 1}, "end_point": {"row": 180, "column": 8}}, {"id": 539, "type": "identifier", "text": "hts221_whoamI", "parent": 537, "children": [], "start_point": {"row": 180, "column": 9}, "end_point": {"row": 180, "column": 22}}, {"id": 540, "type": "assignment_expression", "text": "hts221_dev_ctx.write_reg = platform_write_hts221", "parent": 527, "children": [541, 544, 545], "start_point": {"row": 182, "column": 1}, "end_point": {"row": 182, "column": 49}}, {"id": 541, "type": "field_expression", "text": "hts221_dev_ctx.write_reg", "parent": 540, "children": [542, 543], "start_point": {"row": 182, "column": 1}, "end_point": {"row": 182, "column": 25}}, {"id": 542, "type": "identifier", "text": "hts221_dev_ctx", "parent": 541, "children": [], "start_point": {"row": 182, "column": 1}, "end_point": {"row": 182, "column": 15}}, {"id": 543, "type": "field_identifier", "text": "write_reg", "parent": 541, "children": [], "start_point": {"row": 182, "column": 16}, "end_point": {"row": 182, "column": 25}}, {"id": 544, "type": "=", "text": "=", "parent": 540, "children": [], "start_point": {"row": 182, "column": 26}, "end_point": {"row": 182, "column": 27}}, {"id": 545, "type": "identifier", "text": "platform_write_hts221", "parent": 540, "children": [], "start_point": {"row": 182, "column": 28}, "end_point": {"row": 182, "column": 49}}, {"id": 546, "type": "assignment_expression", "text": "hts221_dev_ctx.read_reg = platform_read_hts221", "parent": 527, "children": [547, 550, 551], "start_point": {"row": 183, "column": 1}, "end_point": {"row": 183, "column": 47}}, {"id": 547, "type": "field_expression", "text": "hts221_dev_ctx.read_reg", "parent": 546, "children": [548, 549], "start_point": {"row": 183, "column": 1}, "end_point": {"row": 183, "column": 24}}, {"id": 548, "type": "identifier", "text": "hts221_dev_ctx", "parent": 547, "children": [], "start_point": {"row": 183, "column": 1}, "end_point": {"row": 183, "column": 15}}, {"id": 549, "type": "field_identifier", "text": "read_reg", "parent": 547, "children": [], "start_point": {"row": 183, "column": 16}, "end_point": {"row": 183, "column": 24}}, {"id": 550, "type": "=", "text": "=", "parent": 546, "children": [], "start_point": {"row": 183, "column": 25}, "end_point": {"row": 183, "column": 26}}, {"id": 551, "type": "identifier", "text": "platform_read_hts221", "parent": 546, "children": [], "start_point": {"row": 183, "column": 27}, "end_point": {"row": 183, "column": 47}}, {"id": 552, "type": "assignment_expression", "text": "hts221_dev_ctx.handle = hts221_bus", "parent": 527, "children": [553, 556, 557], "start_point": {"row": 184, "column": 1}, "end_point": {"row": 184, "column": 35}}, {"id": 553, "type": "field_expression", "text": "hts221_dev_ctx.handle", "parent": 552, "children": [554, 555], "start_point": {"row": 184, "column": 1}, "end_point": {"row": 184, "column": 22}}, {"id": 554, "type": "identifier", "text": "hts221_dev_ctx", "parent": 553, "children": [], "start_point": {"row": 184, "column": 1}, "end_point": {"row": 184, "column": 15}}, {"id": 555, "type": "field_identifier", "text": "handle", "parent": 553, "children": [], "start_point": {"row": 184, "column": 16}, "end_point": {"row": 184, "column": 22}}, {"id": 556, "type": "=", "text": "=", "parent": 552, "children": [], "start_point": {"row": 184, "column": 23}, "end_point": {"row": 184, "column": 24}}, {"id": 557, "type": "identifier", "text": "hts221_bus", "parent": 552, "children": [], "start_point": {"row": 184, "column": 25}, "end_point": {"row": 184, "column": 35}}, {"id": 558, "type": "assignment_expression", "text": "hts221_whoamI = 0", "parent": 527, "children": [559, 560, 561], "start_point": {"row": 186, "column": 1}, "end_point": {"row": 186, "column": 18}}, {"id": 559, "type": "identifier", "text": "hts221_whoamI", "parent": 558, "children": [], "start_point": {"row": 186, "column": 1}, "end_point": {"row": 186, "column": 14}}, {"id": 560, "type": "=", "text": "=", "parent": 558, "children": [], "start_point": {"row": 186, "column": 15}, "end_point": {"row": 186, "column": 16}}, {"id": 561, "type": "number_literal", "text": "0", "parent": 558, "children": [], "start_point": {"row": 186, "column": 17}, "end_point": {"row": 186, "column": 18}}, {"id": 562, "type": "call_expression", "text": "hts221_device_id_get(&hts221_dev_ctx, &hts221_whoamI)", "parent": 527, "children": [563, 564], "start_point": {"row": 187, "column": 1}, "end_point": {"row": 187, "column": 54}}, {"id": 563, "type": "identifier", "text": "hts221_device_id_get", "parent": 562, "children": [], "start_point": {"row": 187, "column": 1}, "end_point": {"row": 187, "column": 21}}, {"id": 564, "type": "argument_list", "text": "(&hts221_dev_ctx, &hts221_whoamI)", "parent": 562, "children": [565, 567], "start_point": {"row": 187, "column": 21}, "end_point": {"row": 187, "column": 54}}, {"id": 565, "type": "pointer_expression", "text": "&hts221_dev_ctx", "parent": 564, "children": [566], "start_point": {"row": 187, "column": 22}, "end_point": {"row": 187, "column": 37}}, {"id": 566, "type": "identifier", "text": "hts221_dev_ctx", "parent": 565, "children": [], "start_point": {"row": 187, "column": 23}, "end_point": {"row": 187, "column": 37}}, {"id": 567, "type": "pointer_expression", "text": "&hts221_whoamI", "parent": 564, "children": [568], "start_point": {"row": 187, "column": 39}, "end_point": {"row": 187, "column": 53}}, {"id": 568, "type": "identifier", "text": "hts221_whoamI", "parent": 567, "children": [], "start_point": {"row": 187, "column": 40}, "end_point": {"row": 187, "column": 53}}, {"id": 569, "type": "if_statement", "text": "if (hts221_whoamI != HTS221_ID)\n\t{\n\t\treturn -1;\n\t}", "parent": 527, "children": [570], "start_point": {"row": 188, "column": 1}, "end_point": {"row": 191, "column": 2}}, {"id": 570, "type": "parenthesized_expression", "text": "(hts221_whoamI != HTS221_ID)", "parent": 569, "children": [571], "start_point": {"row": 188, "column": 4}, "end_point": {"row": 188, "column": 32}}, {"id": 571, "type": "binary_expression", "text": "hts221_whoamI != HTS221_ID", "parent": 570, "children": [572, 573, 574], "start_point": {"row": 188, "column": 5}, "end_point": {"row": 188, "column": 31}}, {"id": 572, "type": "identifier", "text": "hts221_whoamI", "parent": 571, "children": [], "start_point": {"row": 188, "column": 5}, "end_point": {"row": 188, "column": 18}}, {"id": 573, "type": "!=", "text": "!=", "parent": 571, "children": [], "start_point": {"row": 188, "column": 19}, "end_point": {"row": 188, "column": 21}}, {"id": 574, "type": "identifier", "text": "HTS221_ID", "parent": 571, "children": [], "start_point": {"row": 188, "column": 22}, "end_point": {"row": 188, "column": 31}}, {"id": 575, "type": "return_statement", "text": "return -1;", "parent": 569, "children": [576], "start_point": {"row": 190, "column": 2}, "end_point": {"row": 190, "column": 12}}, {"id": 576, "type": "number_literal", "text": "-1", "parent": 575, "children": [], "start_point": {"row": 190, "column": 9}, "end_point": {"row": 190, "column": 11}}, {"id": 577, "type": "call_expression", "text": "hts221_hum_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.x0)", "parent": 527, "children": [578, 579], "start_point": {"row": 193, "column": 1}, "end_point": {"row": 193, "column": 64}}, {"id": 578, "type": "identifier", "text": "hts221_hum_adc_point_0_get", "parent": 577, "children": [], "start_point": {"row": 193, "column": 1}, "end_point": {"row": 193, "column": 27}}, {"id": 579, "type": "argument_list", "text": "(&hts221_dev_ctx, &hts221_lin_hum.x0)", "parent": 577, "children": [580, 582], "start_point": {"row": 193, "column": 27}, "end_point": {"row": 193, "column": 64}}, {"id": 580, "type": "pointer_expression", "text": "&hts221_dev_ctx", "parent": 579, "children": [581], "start_point": {"row": 193, "column": 28}, "end_point": {"row": 193, "column": 43}}, {"id": 581, "type": "identifier", "text": "hts221_dev_ctx", "parent": 580, "children": [], "start_point": {"row": 193, "column": 29}, "end_point": {"row": 193, "column": 43}}, {"id": 582, "type": "pointer_expression", "text": "&hts221_lin_hum.x0", "parent": 579, "children": [583], "start_point": {"row": 193, "column": 45}, "end_point": {"row": 193, "column": 63}}, {"id": 583, "type": "field_expression", "text": "hts221_lin_hum.x0", "parent": 582, "children": [584, 585], "start_point": {"row": 193, "column": 46}, "end_point": {"row": 193, "column": 63}}, {"id": 584, "type": "identifier", "text": "hts221_lin_hum", "parent": 583, "children": [], "start_point": {"row": 193, "column": 46}, "end_point": {"row": 193, "column": 60}}, {"id": 585, "type": "field_identifier", "text": "x0", "parent": 583, "children": [], "start_point": {"row": 193, "column": 61}, "end_point": {"row": 193, "column": 63}}, {"id": 586, "type": "call_expression", "text": "hts221_hum_rh_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.y0)", "parent": 527, "children": [587, 588], "start_point": {"row": 194, "column": 1}, "end_point": {"row": 194, "column": 63}}, {"id": 587, "type": "identifier", "text": "hts221_hum_rh_point_0_get", "parent": 586, "children": [], "start_point": {"row": 194, "column": 1}, "end_point": {"row": 194, "column": 26}}, {"id": 588, "type": "argument_list", "text": "(&hts221_dev_ctx, &hts221_lin_hum.y0)", "parent": 586, "children": [589, 591], "start_point": {"row": 194, "column": 26}, "end_point": {"row": 194, "column": 63}}, {"id": 589, "type": "pointer_expression", "text": "&hts221_dev_ctx", "parent": 588, "children": [590], "start_point": {"row": 194, "column": 27}, "end_point": {"row": 194, "column": 42}}, {"id": 590, "type": "identifier", "text": "hts221_dev_ctx", "parent": 589, "children": [], "start_point": {"row": 194, "column": 28}, "end_point": {"row": 194, "column": 42}}, {"id": 591, "type": "pointer_expression", "text": "&hts221_lin_hum.y0", "parent": 588, "children": [592], "start_point": {"row": 194, "column": 44}, "end_point": {"row": 194, "column": 62}}, {"id": 592, "type": "field_expression", "text": "hts221_lin_hum.y0", "parent": 591, "children": [593, 594], "start_point": {"row": 194, "column": 45}, "end_point": {"row": 194, "column": 62}}, {"id": 593, "type": "identifier", "text": "hts221_lin_hum", "parent": 592, "children": [], "start_point": {"row": 194, "column": 45}, "end_point": {"row": 194, "column": 59}}, {"id": 594, "type": "field_identifier", "text": "y0", "parent": 592, "children": [], "start_point": {"row": 194, "column": 60}, "end_point": {"row": 194, "column": 62}}, {"id": 595, "type": "call_expression", "text": "hts221_hum_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.x1)", "parent": 527, "children": [596, 597], "start_point": {"row": 195, "column": 1}, "end_point": {"row": 195, "column": 64}}, {"id": 596, "type": "identifier", "text": "hts221_hum_adc_point_1_get", "parent": 595, "children": [], "start_point": {"row": 195, "column": 1}, "end_point": {"row": 195, "column": 27}}, {"id": 597, "type": "argument_list", "text": "(&hts221_dev_ctx, &hts221_lin_hum.x1)", "parent": 595, "children": [598, 600], "start_point": {"row": 195, "column": 27}, "end_point": {"row": 195, "column": 64}}, {"id": 598, "type": "pointer_expression", "text": "&hts221_dev_ctx", "parent": 597, "children": [599], "start_point": {"row": 195, "column": 28}, "end_point": {"row": 195, "column": 43}}, {"id": 599, "type": "identifier", "text": "hts221_dev_ctx", "parent": 598, "children": [], "start_point": {"row": 195, "column": 29}, "end_point": {"row": 195, "column": 43}}, {"id": 600, "type": "pointer_expression", "text": "&hts221_lin_hum.x1", "parent": 597, "children": [601], "start_point": {"row": 195, "column": 45}, "end_point": {"row": 195, "column": 63}}, {"id": 601, "type": "field_expression", "text": "hts221_lin_hum.x1", "parent": 600, "children": [602, 603], "start_point": {"row": 195, "column": 46}, "end_point": {"row": 195, "column": 63}}, {"id": 602, "type": "identifier", "text": "hts221_lin_hum", "parent": 601, "children": [], "start_point": {"row": 195, "column": 46}, "end_point": {"row": 195, "column": 60}}, {"id": 603, "type": "field_identifier", "text": "x1", "parent": 601, "children": [], "start_point": {"row": 195, "column": 61}, "end_point": {"row": 195, "column": 63}}, {"id": 604, "type": "call_expression", "text": "hts221_hum_rh_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.y1)", "parent": 527, "children": [605, 606], "start_point": {"row": 196, "column": 1}, "end_point": {"row": 196, "column": 63}}, {"id": 605, "type": "identifier", "text": "hts221_hum_rh_point_1_get", "parent": 604, "children": [], "start_point": {"row": 196, "column": 1}, "end_point": {"row": 196, "column": 26}}, {"id": 606, "type": "argument_list", "text": "(&hts221_dev_ctx, &hts221_lin_hum.y1)", "parent": 604, "children": [607, 609], "start_point": {"row": 196, "column": 26}, "end_point": {"row": 196, "column": 63}}, {"id": 607, "type": "pointer_expression", "text": "&hts221_dev_ctx", "parent": 606, "children": [608], "start_point": {"row": 196, "column": 27}, "end_point": {"row": 196, "column": 42}}, {"id": 608, "type": "identifier", "text": "hts221_dev_ctx", "parent": 607, "children": [], "start_point": {"row": 196, "column": 28}, "end_point": {"row": 196, "column": 42}}, {"id": 609, "type": "pointer_expression", "text": "&hts221_lin_hum.y1", "parent": 606, "children": [610], "start_point": {"row": 196, "column": 44}, "end_point": {"row": 196, "column": 62}}, {"id": 610, "type": "field_expression", "text": "hts221_lin_hum.y1", "parent": 609, "children": [611, 612], "start_point": {"row": 196, "column": 45}, "end_point": {"row": 196, "column": 62}}, {"id": 611, "type": "identifier", "text": "hts221_lin_hum", "parent": 610, "children": [], "start_point": {"row": 196, "column": 45}, "end_point": {"row": 196, "column": 59}}, {"id": 612, "type": "field_identifier", "text": "y1", "parent": 610, "children": [], "start_point": {"row": 196, "column": 60}, "end_point": {"row": 196, "column": 62}}, {"id": 613, "type": "call_expression", "text": "hts221_temp_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.x0)", "parent": 527, "children": [614, 615], "start_point": {"row": 198, "column": 1}, "end_point": {"row": 198, "column": 66}}, {"id": 614, "type": "identifier", "text": "hts221_temp_adc_point_0_get", "parent": 613, "children": [], "start_point": {"row": 198, "column": 1}, "end_point": {"row": 198, "column": 28}}, {"id": 615, "type": "argument_list", "text": "(&hts221_dev_ctx, &hts221_lin_temp.x0)", "parent": 613, "children": [616, 618], "start_point": {"row": 198, "column": 28}, "end_point": {"row": 198, "column": 66}}, {"id": 616, "type": "pointer_expression", "text": "&hts221_dev_ctx", "parent": 615, "children": [617], "start_point": {"row": 198, "column": 29}, "end_point": {"row": 198, "column": 44}}, {"id": 617, "type": "identifier", "text": "hts221_dev_ctx", "parent": 616, "children": [], "start_point": {"row": 198, "column": 30}, "end_point": {"row": 198, "column": 44}}, {"id": 618, "type": "pointer_expression", "text": "&hts221_lin_temp.x0", "parent": 615, "children": [619], "start_point": {"row": 198, "column": 46}, "end_point": {"row": 198, "column": 65}}, {"id": 619, "type": "field_expression", "text": "hts221_lin_temp.x0", "parent": 618, "children": [620, 621], "start_point": {"row": 198, "column": 47}, "end_point": {"row": 198, "column": 65}}, {"id": 620, "type": "identifier", "text": "hts221_lin_temp", "parent": 619, "children": [], "start_point": {"row": 198, "column": 47}, "end_point": {"row": 198, "column": 62}}, {"id": 621, "type": "field_identifier", "text": "x0", "parent": 619, "children": [], "start_point": {"row": 198, "column": 63}, "end_point": {"row": 198, "column": 65}}, {"id": 622, "type": "call_expression", "text": "hts221_temp_deg_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.y0)", "parent": 527, "children": [623, 624], "start_point": {"row": 199, "column": 1}, "end_point": {"row": 199, "column": 66}}, {"id": 623, "type": "identifier", "text": "hts221_temp_deg_point_0_get", "parent": 622, "children": [], "start_point": {"row": 199, "column": 1}, "end_point": {"row": 199, "column": 28}}, {"id": 624, "type": "argument_list", "text": "(&hts221_dev_ctx, &hts221_lin_temp.y0)", "parent": 622, "children": [625, 627], "start_point": {"row": 199, "column": 28}, "end_point": {"row": 199, "column": 66}}, {"id": 625, "type": "pointer_expression", "text": "&hts221_dev_ctx", "parent": 624, "children": [626], "start_point": {"row": 199, "column": 29}, "end_point": {"row": 199, "column": 44}}, {"id": 626, "type": "identifier", "text": "hts221_dev_ctx", "parent": 625, "children": [], "start_point": {"row": 199, "column": 30}, "end_point": {"row": 199, "column": 44}}, {"id": 627, "type": "pointer_expression", "text": "&hts221_lin_temp.y0", "parent": 624, "children": [628], "start_point": {"row": 199, "column": 46}, "end_point": {"row": 199, "column": 65}}, {"id": 628, "type": "field_expression", "text": "hts221_lin_temp.y0", "parent": 627, "children": [629, 630], "start_point": {"row": 199, "column": 47}, "end_point": {"row": 199, "column": 65}}, {"id": 629, "type": "identifier", "text": "hts221_lin_temp", "parent": 628, "children": [], "start_point": {"row": 199, "column": 47}, "end_point": {"row": 199, "column": 62}}, {"id": 630, "type": "field_identifier", "text": "y0", "parent": 628, "children": [], "start_point": {"row": 199, "column": 63}, "end_point": {"row": 199, "column": 65}}, {"id": 631, "type": "call_expression", "text": "hts221_temp_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.x1)", "parent": 527, "children": [632, 633], "start_point": {"row": 200, "column": 1}, "end_point": {"row": 200, "column": 66}}, {"id": 632, "type": "identifier", "text": "hts221_temp_adc_point_1_get", "parent": 631, "children": [], "start_point": {"row": 200, "column": 1}, "end_point": {"row": 200, "column": 28}}, {"id": 633, "type": "argument_list", "text": "(&hts221_dev_ctx, &hts221_lin_temp.x1)", "parent": 631, "children": [634, 636], "start_point": {"row": 200, "column": 28}, "end_point": {"row": 200, "column": 66}}, {"id": 634, "type": "pointer_expression", "text": "&hts221_dev_ctx", "parent": 633, "children": [635], "start_point": {"row": 200, "column": 29}, "end_point": {"row": 200, "column": 44}}, {"id": 635, "type": "identifier", "text": "hts221_dev_ctx", "parent": 634, "children": [], "start_point": {"row": 200, "column": 30}, "end_point": {"row": 200, "column": 44}}, {"id": 636, "type": "pointer_expression", "text": "&hts221_lin_temp.x1", "parent": 633, "children": [637], "start_point": {"row": 200, "column": 46}, "end_point": {"row": 200, "column": 65}}, {"id": 637, "type": "field_expression", "text": "hts221_lin_temp.x1", "parent": 636, "children": [638, 639], "start_point": {"row": 200, "column": 47}, "end_point": {"row": 200, "column": 65}}, {"id": 638, "type": "identifier", "text": "hts221_lin_temp", "parent": 637, "children": [], "start_point": {"row": 200, "column": 47}, "end_point": {"row": 200, "column": 62}}, {"id": 639, "type": "field_identifier", "text": "x1", "parent": 637, "children": [], "start_point": {"row": 200, "column": 63}, "end_point": {"row": 200, "column": 65}}, {"id": 640, "type": "call_expression", "text": "hts221_temp_deg_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.y1)", "parent": 527, "children": [641, 642], "start_point": {"row": 201, "column": 1}, "end_point": {"row": 201, "column": 66}}, {"id": 641, "type": "identifier", "text": "hts221_temp_deg_point_1_get", "parent": 640, "children": [], "start_point": {"row": 201, "column": 1}, "end_point": {"row": 201, "column": 28}}, {"id": 642, "type": "argument_list", "text": "(&hts221_dev_ctx, &hts221_lin_temp.y1)", "parent": 640, "children": [643, 645], "start_point": {"row": 201, "column": 28}, "end_point": {"row": 201, "column": 66}}, {"id": 643, "type": "pointer_expression", "text": "&hts221_dev_ctx", "parent": 642, "children": [644], "start_point": {"row": 201, "column": 29}, "end_point": {"row": 201, "column": 44}}, {"id": 644, "type": "identifier", "text": "hts221_dev_ctx", "parent": 643, "children": [], "start_point": {"row": 201, "column": 30}, "end_point": {"row": 201, "column": 44}}, {"id": 645, "type": "pointer_expression", "text": "&hts221_lin_temp.y1", "parent": 642, "children": [646], "start_point": {"row": 201, "column": 46}, "end_point": {"row": 201, "column": 65}}, {"id": 646, "type": "field_expression", "text": "hts221_lin_temp.y1", "parent": 645, "children": [647, 648], "start_point": {"row": 201, "column": 47}, "end_point": {"row": 201, "column": 65}}, {"id": 647, "type": "identifier", "text": "hts221_lin_temp", "parent": 646, "children": [], "start_point": {"row": 201, "column": 47}, "end_point": {"row": 201, "column": 62}}, {"id": 648, "type": "field_identifier", "text": "y1", "parent": 646, "children": [], "start_point": {"row": 201, "column": 63}, "end_point": {"row": 201, "column": 65}}, {"id": 649, "type": "call_expression", "text": "hts221_block_data_update_set(&hts221_dev_ctx, PROPERTY_ENABLE)", "parent": 527, "children": [650, 651], "start_point": {"row": 203, "column": 1}, "end_point": {"row": 203, "column": 63}}, {"id": 650, "type": "identifier", "text": "hts221_block_data_update_set", "parent": 649, "children": [], "start_point": {"row": 203, "column": 1}, "end_point": {"row": 203, "column": 29}}, {"id": 651, "type": "argument_list", "text": "(&hts221_dev_ctx, PROPERTY_ENABLE)", "parent": 649, "children": [652, 654], "start_point": {"row": 203, "column": 29}, "end_point": {"row": 203, "column": 63}}, {"id": 652, "type": "pointer_expression", "text": "&hts221_dev_ctx", "parent": 651, "children": [653], "start_point": {"row": 203, "column": 30}, "end_point": {"row": 203, "column": 45}}, {"id": 653, "type": "identifier", "text": "hts221_dev_ctx", "parent": 652, "children": [], "start_point": {"row": 203, "column": 31}, "end_point": {"row": 203, "column": 45}}, {"id": 654, "type": "identifier", "text": "PROPERTY_ENABLE", "parent": 651, "children": [], "start_point": {"row": 203, "column": 47}, "end_point": {"row": 203, "column": 62}}, {"id": 655, "type": "call_expression", "text": "hts221_data_rate_set(&hts221_dev_ctx, HTS221_ODR_7Hz)", "parent": 527, "children": [656, 657], "start_point": {"row": 205, "column": 1}, "end_point": {"row": 205, "column": 54}}, {"id": 656, "type": "identifier", "text": "hts221_data_rate_set", "parent": 655, "children": [], "start_point": {"row": 205, "column": 1}, "end_point": {"row": 205, "column": 21}}, {"id": 657, "type": "argument_list", "text": "(&hts221_dev_ctx, HTS221_ODR_7Hz)", "parent": 655, "children": [658, 660], "start_point": {"row": 205, "column": 21}, "end_point": {"row": 205, "column": 54}}, {"id": 658, "type": "pointer_expression", "text": "&hts221_dev_ctx", "parent": 657, "children": [659], "start_point": {"row": 205, "column": 22}, "end_point": {"row": 205, "column": 37}}, {"id": 659, "type": "identifier", "text": "hts221_dev_ctx", "parent": 658, "children": [], "start_point": {"row": 205, "column": 23}, "end_point": {"row": 205, "column": 37}}, {"id": 660, "type": "identifier", "text": "HTS221_ODR_7Hz", "parent": 657, "children": [], "start_point": {"row": 205, "column": 39}, "end_point": {"row": 205, "column": 53}}, {"id": 661, "type": "call_expression", "text": "hts221_power_on_set(&hts221_dev_ctx, PROPERTY_ENABLE)", "parent": 527, "children": [662, 663], "start_point": {"row": 207, "column": 1}, "end_point": {"row": 207, "column": 54}}, {"id": 662, "type": "identifier", "text": "hts221_power_on_set", "parent": 661, "children": [], "start_point": {"row": 207, "column": 1}, "end_point": {"row": 207, "column": 20}}, {"id": 663, "type": "argument_list", "text": "(&hts221_dev_ctx, PROPERTY_ENABLE)", "parent": 661, "children": [664, 666], "start_point": {"row": 207, "column": 20}, "end_point": {"row": 207, "column": 54}}, {"id": 664, "type": "pointer_expression", "text": "&hts221_dev_ctx", "parent": 663, "children": [665], "start_point": {"row": 207, "column": 21}, "end_point": {"row": 207, "column": 36}}, {"id": 665, "type": "identifier", "text": "hts221_dev_ctx", "parent": 664, "children": [], "start_point": {"row": 207, "column": 22}, "end_point": {"row": 207, "column": 36}}, {"id": 666, "type": "identifier", "text": "PROPERTY_ENABLE", "parent": 663, "children": [], "start_point": {"row": 207, "column": 38}, "end_point": {"row": 207, "column": 53}}, {"id": 667, "type": "return_statement", "text": "return 0;", "parent": 527, "children": [668], "start_point": {"row": 209, "column": 1}, "end_point": {"row": 209, "column": 10}}, {"id": 668, "type": "number_literal", "text": "0", "parent": 667, "children": [], "start_point": {"row": 209, "column": 8}, "end_point": {"row": 209, "column": 9}}, {"id": 669, "type": "function_definition", "text": "float linear_interpolation(lin_t *lin, int16_t x)\n{\n\treturn ((lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) -\n\t (lin->x0 * lin->y1))) / (lin->x1 - lin->x0);\n}", "parent": null, "children": [670, 671], "start_point": {"row": 212, "column": 0}, "end_point": {"row": 216, "column": 1}}, {"id": 670, "type": "primitive_type", "text": "float", "parent": 669, "children": [], "start_point": {"row": 212, "column": 0}, "end_point": {"row": 212, "column": 5}}, {"id": 671, "type": "function_declarator", "text": "linear_interpolation(lin_t *lin, int16_t x)", "parent": 669, "children": [672, 673], "start_point": {"row": 212, "column": 6}, "end_point": {"row": 212, "column": 49}}, {"id": 672, "type": "identifier", "text": "linear_interpolation", "parent": 671, "children": [], "start_point": {"row": 212, "column": 6}, "end_point": {"row": 212, "column": 26}}, {"id": 673, "type": "parameter_list", "text": "(lin_t *lin, int16_t x)", "parent": 671, "children": [674, 679], "start_point": {"row": 212, "column": 26}, "end_point": {"row": 212, "column": 49}}, {"id": 674, "type": "parameter_declaration", "text": "lin_t *lin", "parent": 673, "children": [675, 676], "start_point": {"row": 212, "column": 27}, "end_point": {"row": 212, "column": 37}}, {"id": 675, "type": "type_identifier", "text": "lin_t", "parent": 674, "children": [], "start_point": {"row": 212, "column": 27}, "end_point": {"row": 212, "column": 32}}, {"id": 676, "type": "pointer_declarator", "text": "*lin", "parent": 674, "children": [677, 678], "start_point": {"row": 212, "column": 33}, "end_point": {"row": 212, "column": 37}}, {"id": 677, "type": "*", "text": "*", "parent": 676, "children": [], "start_point": {"row": 212, "column": 33}, "end_point": {"row": 212, "column": 34}}, {"id": 678, "type": "identifier", "text": "lin", "parent": 676, "children": [], "start_point": {"row": 212, "column": 34}, "end_point": {"row": 212, "column": 37}}, {"id": 679, "type": "parameter_declaration", "text": "int16_t x", "parent": 673, "children": [680, 681], "start_point": {"row": 212, "column": 39}, "end_point": {"row": 212, "column": 48}}, {"id": 680, "type": "primitive_type", "text": "int16_t", "parent": 679, "children": [], "start_point": {"row": 212, "column": 39}, "end_point": {"row": 212, "column": 46}}, {"id": 681, "type": "identifier", "text": "x", "parent": 679, "children": [], "start_point": {"row": 212, "column": 47}, "end_point": {"row": 212, "column": 48}}, {"id": 682, "type": "return_statement", "text": "return ((lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) -\n\t (lin->x0 * lin->y1))) / (lin->x1 - lin->x0);", "parent": 669, "children": [683], "start_point": {"row": 214, "column": 1}, "end_point": {"row": 215, "column": 56}}, {"id": 683, "type": "binary_expression", "text": "((lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) -\n\t (lin->x0 * lin->y1))) / (lin->x1 - lin->x0)", "parent": 682, "children": [684, 720, 721], "start_point": {"row": 214, "column": 8}, "end_point": {"row": 215, "column": 55}}, {"id": 684, "type": "parenthesized_expression", "text": "((lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) -\n\t (lin->x0 * lin->y1)))", "parent": 683, "children": [685], "start_point": {"row": 214, "column": 8}, "end_point": {"row": 215, "column": 33}}, {"id": 685, "type": "binary_expression", "text": "(lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) -\n\t (lin->x0 * lin->y1))", "parent": 684, "children": [686, 698, 699], "start_point": {"row": 214, "column": 9}, "end_point": {"row": 215, "column": 32}}, {"id": 686, "type": "binary_expression", "text": "(lin->y1 - lin->y0) * x", "parent": 685, "children": [687, 696, 697], "start_point": {"row": 214, "column": 9}, "end_point": {"row": 214, "column": 32}}, {"id": 687, "type": "parenthesized_expression", "text": "(lin->y1 - lin->y0)", "parent": 686, "children": [688], "start_point": {"row": 214, "column": 9}, "end_point": {"row": 214, "column": 28}}, {"id": 688, "type": "binary_expression", "text": "lin->y1 - lin->y0", "parent": 687, "children": [689, 692, 693], "start_point": {"row": 214, "column": 10}, "end_point": {"row": 214, "column": 27}}, {"id": 689, "type": "field_expression", "text": "lin->y1", "parent": 688, "children": [690, 691], "start_point": {"row": 214, "column": 10}, "end_point": {"row": 214, "column": 17}}, {"id": 690, "type": "identifier", "text": "lin", "parent": 689, "children": [], "start_point": {"row": 214, "column": 10}, "end_point": {"row": 214, "column": 13}}, {"id": 691, "type": "field_identifier", "text": "y1", "parent": 689, "children": [], "start_point": {"row": 214, "column": 15}, "end_point": {"row": 214, "column": 17}}, {"id": 692, "type": "-", "text": "-", "parent": 688, "children": [], "start_point": {"row": 214, "column": 18}, "end_point": {"row": 214, "column": 19}}, {"id": 693, "type": "field_expression", "text": "lin->y0", "parent": 688, "children": [694, 695], "start_point": {"row": 214, "column": 20}, "end_point": {"row": 214, "column": 27}}, {"id": 694, "type": "identifier", "text": "lin", "parent": 693, "children": [], "start_point": {"row": 214, "column": 20}, "end_point": {"row": 214, "column": 23}}, {"id": 695, "type": "field_identifier", "text": "y0", "parent": 693, "children": [], "start_point": {"row": 214, "column": 25}, "end_point": {"row": 214, "column": 27}}, {"id": 696, "type": "*", "text": "*", "parent": 686, "children": [], "start_point": {"row": 214, "column": 29}, "end_point": {"row": 214, "column": 30}}, {"id": 697, "type": "identifier", "text": "x", "parent": 686, "children": [], "start_point": {"row": 214, "column": 31}, "end_point": {"row": 214, "column": 32}}, {"id": 698, "type": "+", "text": "+", "parent": 685, "children": [], "start_point": {"row": 214, "column": 33}, "end_point": {"row": 214, "column": 34}}, {"id": 699, "type": "parenthesized_expression", "text": "((lin->x1 * lin->y0) -\n\t (lin->x0 * lin->y1))", "parent": 685, "children": [700], "start_point": {"row": 214, "column": 35}, "end_point": {"row": 215, "column": 32}}, {"id": 700, "type": "binary_expression", "text": "(lin->x1 * lin->y0) -\n\t (lin->x0 * lin->y1)", "parent": 699, "children": [701, 710, 711], "start_point": {"row": 214, "column": 36}, "end_point": {"row": 215, "column": 31}}, {"id": 701, "type": "parenthesized_expression", "text": "(lin->x1 * lin->y0)", "parent": 700, "children": [702], "start_point": {"row": 214, "column": 36}, "end_point": {"row": 214, "column": 55}}, {"id": 702, "type": "binary_expression", "text": "lin->x1 * lin->y0", "parent": 701, "children": [703, 706, 707], "start_point": {"row": 214, "column": 37}, "end_point": {"row": 214, "column": 54}}, {"id": 703, "type": "field_expression", "text": "lin->x1", "parent": 702, "children": [704, 705], "start_point": {"row": 214, "column": 37}, "end_point": {"row": 214, "column": 44}}, {"id": 704, "type": "identifier", "text": "lin", "parent": 703, "children": [], "start_point": {"row": 214, "column": 37}, "end_point": {"row": 214, "column": 40}}, {"id": 705, "type": "field_identifier", "text": "x1", "parent": 703, "children": [], "start_point": {"row": 214, "column": 42}, "end_point": {"row": 214, "column": 44}}, {"id": 706, "type": "*", "text": "*", "parent": 702, "children": [], "start_point": {"row": 214, "column": 45}, "end_point": {"row": 214, "column": 46}}, {"id": 707, "type": "field_expression", "text": "lin->y0", "parent": 702, "children": [708, 709], "start_point": {"row": 214, "column": 47}, "end_point": {"row": 214, "column": 54}}, {"id": 708, "type": "identifier", "text": "lin", "parent": 707, "children": [], "start_point": {"row": 214, "column": 47}, "end_point": {"row": 214, "column": 50}}, {"id": 709, "type": "field_identifier", "text": "y0", "parent": 707, "children": [], "start_point": {"row": 214, "column": 52}, "end_point": {"row": 214, "column": 54}}, {"id": 710, "type": "-", "text": "-", "parent": 700, "children": [], "start_point": {"row": 214, "column": 56}, "end_point": {"row": 214, "column": 57}}, {"id": 711, "type": "parenthesized_expression", "text": "(lin->x0 * lin->y1)", "parent": 700, "children": [712], "start_point": {"row": 215, "column": 12}, "end_point": {"row": 215, "column": 31}}, {"id": 712, "type": "binary_expression", "text": "lin->x0 * lin->y1", "parent": 711, "children": [713, 716, 717], "start_point": {"row": 215, "column": 13}, "end_point": {"row": 215, "column": 30}}, {"id": 713, "type": "field_expression", "text": "lin->x0", "parent": 712, "children": [714, 715], "start_point": {"row": 215, "column": 13}, "end_point": {"row": 215, "column": 20}}, {"id": 714, "type": "identifier", "text": "lin", "parent": 713, "children": [], "start_point": {"row": 215, "column": 13}, "end_point": {"row": 215, "column": 16}}, {"id": 715, "type": "field_identifier", "text": "x0", "parent": 713, "children": [], "start_point": {"row": 215, "column": 18}, "end_point": {"row": 215, "column": 20}}, {"id": 716, "type": "*", "text": "*", "parent": 712, "children": [], "start_point": {"row": 215, "column": 21}, "end_point": {"row": 215, "column": 22}}, {"id": 717, "type": "field_expression", "text": "lin->y1", "parent": 712, "children": [718, 719], "start_point": {"row": 215, "column": 23}, "end_point": {"row": 215, "column": 30}}, {"id": 718, "type": "identifier", "text": "lin", "parent": 717, "children": [], "start_point": {"row": 215, "column": 23}, "end_point": {"row": 215, "column": 26}}, {"id": 719, "type": "field_identifier", "text": "y1", "parent": 717, "children": [], "start_point": {"row": 215, "column": 28}, "end_point": {"row": 215, "column": 30}}, {"id": 720, "type": "/", "text": "/", "parent": 683, "children": [], "start_point": {"row": 215, "column": 34}, "end_point": {"row": 215, "column": 35}}, {"id": 721, "type": "parenthesized_expression", "text": "(lin->x1 - lin->x0)", "parent": 683, "children": [722], "start_point": {"row": 215, "column": 36}, "end_point": {"row": 215, "column": 55}}, {"id": 722, "type": "binary_expression", "text": "lin->x1 - lin->x0", "parent": 721, "children": [723, 726, 727], "start_point": {"row": 215, "column": 37}, "end_point": {"row": 215, "column": 54}}, {"id": 723, "type": "field_expression", "text": "lin->x1", "parent": 722, "children": [724, 725], "start_point": {"row": 215, "column": 37}, "end_point": {"row": 215, "column": 44}}, {"id": 724, "type": "identifier", "text": "lin", "parent": 723, "children": [], "start_point": {"row": 215, "column": 37}, "end_point": {"row": 215, "column": 40}}, {"id": 725, "type": "field_identifier", "text": "x1", "parent": 723, "children": [], "start_point": {"row": 215, "column": 42}, "end_point": {"row": 215, "column": 44}}, {"id": 726, "type": "-", "text": "-", "parent": 722, "children": [], "start_point": {"row": 215, "column": 45}, "end_point": {"row": 215, "column": 46}}, {"id": 727, "type": "field_expression", "text": "lin->x0", "parent": 722, "children": [728, 729], "start_point": {"row": 215, "column": 47}, "end_point": {"row": 215, "column": 54}}, {"id": 728, "type": "identifier", "text": "lin", "parent": 727, "children": [], "start_point": {"row": 215, "column": 47}, "end_point": {"row": 215, "column": 50}}, {"id": 729, "type": "field_identifier", "text": "x0", "parent": 727, "children": [], "start_point": {"row": 215, "column": 52}, "end_point": {"row": 215, "column": 54}}, {"id": 730, "type": "function_definition", "text": "int32_t platform_write_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)\n{\n reg |= 0x80;\n HAL_I2C_Mem_Write(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}", "parent": null, "children": [731, 732], "start_point": {"row": 218, "column": 0}, "end_point": {"row": 224, "column": 1}}, {"id": 731, "type": "primitive_type", "text": "int32_t", "parent": 730, "children": [], "start_point": {"row": 218, "column": 0}, "end_point": {"row": 218, "column": 7}}, {"id": 732, "type": "function_declarator", "text": "platform_write_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)", "parent": 730, "children": [733, 734], "start_point": {"row": 218, "column": 8}, "end_point": {"row": 219, "column": 43}}, {"id": 733, "type": "identifier", "text": "platform_write_hts221", "parent": 732, "children": [], "start_point": {"row": 218, "column": 8}, "end_point": {"row": 218, "column": 29}}, {"id": 734, "type": "parameter_list", "text": "(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)", "parent": 732, "children": [735, 740, 743, 748], "start_point": {"row": 218, "column": 29}, "end_point": {"row": 219, "column": 43}}, {"id": 735, "type": "parameter_declaration", "text": "void *handle", "parent": 734, "children": [736, 737], "start_point": {"row": 218, "column": 30}, "end_point": {"row": 218, "column": 42}}, {"id": 736, "type": "primitive_type", "text": "void", "parent": 735, "children": [], "start_point": {"row": 218, "column": 30}, "end_point": {"row": 218, "column": 34}}, {"id": 737, "type": "pointer_declarator", "text": "*handle", "parent": 735, "children": [738, 739], "start_point": {"row": 218, "column": 35}, "end_point": {"row": 218, "column": 42}}, {"id": 738, "type": "*", "text": "*", "parent": 737, "children": [], "start_point": {"row": 218, "column": 35}, "end_point": {"row": 218, "column": 36}}, {"id": 739, "type": "identifier", "text": "handle", "parent": 737, "children": [], "start_point": {"row": 218, "column": 36}, "end_point": {"row": 218, "column": 42}}, {"id": 740, "type": "parameter_declaration", "text": "uint8_t reg", "parent": 734, "children": [741, 742], "start_point": {"row": 218, "column": 44}, "end_point": {"row": 218, "column": 55}}, {"id": 741, "type": "primitive_type", "text": "uint8_t", "parent": 740, "children": [], "start_point": {"row": 218, "column": 44}, "end_point": {"row": 218, "column": 51}}, {"id": 742, "type": "identifier", "text": "reg", "parent": 740, "children": [], "start_point": {"row": 218, "column": 52}, "end_point": {"row": 218, "column": 55}}, {"id": 743, "type": "parameter_declaration", "text": "uint8_t *bufp", "parent": 734, "children": [744, 745], "start_point": {"row": 218, "column": 57}, "end_point": {"row": 218, "column": 70}}, {"id": 744, "type": "primitive_type", "text": "uint8_t", "parent": 743, "children": [], "start_point": {"row": 218, "column": 57}, "end_point": {"row": 218, "column": 64}}, {"id": 745, "type": "pointer_declarator", "text": "*bufp", "parent": 743, "children": [746, 747], "start_point": {"row": 218, "column": 65}, "end_point": {"row": 218, "column": 70}}, {"id": 746, "type": "*", "text": "*", "parent": 745, "children": [], "start_point": {"row": 218, "column": 65}, "end_point": {"row": 218, "column": 66}}, {"id": 747, "type": "identifier", "text": "bufp", "parent": 745, "children": [], "start_point": {"row": 218, "column": 66}, "end_point": {"row": 218, "column": 70}}, {"id": 748, "type": "parameter_declaration", "text": "uint16_t len", "parent": 734, "children": [749, 750], "start_point": {"row": 219, "column": 30}, "end_point": {"row": 219, "column": 42}}, {"id": 749, "type": "primitive_type", "text": "uint16_t", "parent": 748, "children": [], "start_point": {"row": 219, "column": 30}, "end_point": {"row": 219, "column": 38}}, {"id": 750, "type": "identifier", "text": "len", "parent": 748, "children": [], "start_point": {"row": 219, "column": 39}, "end_point": {"row": 219, "column": 42}}, {"id": 751, "type": "assignment_expression", "text": "reg |= 0x80", "parent": 730, "children": [752, 753, 754], "start_point": {"row": 221, "column": 2}, "end_point": {"row": 221, "column": 13}}, {"id": 752, "type": "identifier", "text": "reg", "parent": 751, "children": [], "start_point": {"row": 221, "column": 2}, "end_point": {"row": 221, "column": 5}}, {"id": 753, "type": "|=", "text": "|=", "parent": 751, "children": [], "start_point": {"row": 221, "column": 6}, "end_point": {"row": 221, "column": 8}}, {"id": 754, "type": "number_literal", "text": "0x80", "parent": 751, "children": [], "start_point": {"row": 221, "column": 9}, "end_point": {"row": 221, "column": 13}}, {"id": 755, "type": "call_expression", "text": "HAL_I2C_Mem_Write(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)", "parent": 730, "children": [756, 757], "start_point": {"row": 222, "column": 2}, "end_point": {"row": 222, "column": 91}}, {"id": 756, "type": "identifier", "text": "HAL_I2C_Mem_Write", "parent": 755, "children": [], "start_point": {"row": 222, "column": 2}, "end_point": {"row": 222, "column": 19}}, {"id": 757, "type": "argument_list", "text": "(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)", "parent": 755, "children": [758, 759, 760, 761, 762, 763, 764], "start_point": {"row": 222, "column": 19}, "end_point": {"row": 222, "column": 91}}, {"id": 758, "type": "identifier", "text": "handle", "parent": 757, "children": [], "start_point": {"row": 222, "column": 20}, "end_point": {"row": 222, "column": 26}}, {"id": 759, "type": "identifier", "text": "HTS221_I2C_ADDRESS", "parent": 757, "children": [], "start_point": {"row": 222, "column": 28}, "end_point": {"row": 222, "column": 46}}, {"id": 760, "type": "identifier", "text": "reg", "parent": 757, "children": [], "start_point": {"row": 222, "column": 48}, "end_point": {"row": 222, "column": 51}}, {"id": 761, "type": "identifier", "text": "I2C_MEMADD_SIZE_8BIT", "parent": 757, "children": [], "start_point": {"row": 222, "column": 53}, "end_point": {"row": 222, "column": 73}}, {"id": 762, "type": "identifier", "text": "bufp", "parent": 757, "children": [], "start_point": {"row": 222, "column": 75}, "end_point": {"row": 222, "column": 79}}, {"id": 763, "type": "identifier", "text": "len", "parent": 757, "children": [], "start_point": {"row": 222, "column": 81}, "end_point": {"row": 222, "column": 84}}, {"id": 764, "type": "number_literal", "text": "1000", "parent": 757, "children": [], "start_point": {"row": 222, "column": 86}, "end_point": {"row": 222, "column": 90}}, {"id": 765, "type": "return_statement", "text": "return 0;", "parent": 730, "children": [766], "start_point": {"row": 223, "column": 2}, "end_point": {"row": 223, "column": 11}}, {"id": 766, "type": "number_literal", "text": "0", "parent": 765, "children": [], "start_point": {"row": 223, "column": 9}, "end_point": {"row": 223, "column": 10}}, {"id": 767, "type": "function_definition", "text": "int32_t platform_read_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)\n{\n reg |= 0x80;\n HAL_I2C_Mem_Read(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}", "parent": null, "children": [768, 769], "start_point": {"row": 226, "column": 0}, "end_point": {"row": 232, "column": 1}}, {"id": 768, "type": "primitive_type", "text": "int32_t", "parent": 767, "children": [], "start_point": {"row": 226, "column": 0}, "end_point": {"row": 226, "column": 7}}, {"id": 769, "type": "function_declarator", "text": "platform_read_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)", "parent": 767, "children": [770, 771], "start_point": {"row": 226, "column": 8}, "end_point": {"row": 227, "column": 42}}, {"id": 770, "type": "identifier", "text": "platform_read_hts221", "parent": 769, "children": [], "start_point": {"row": 226, "column": 8}, "end_point": {"row": 226, "column": 28}}, {"id": 771, "type": "parameter_list", "text": "(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)", "parent": 769, "children": [772, 777, 780, 785], "start_point": {"row": 226, "column": 28}, "end_point": {"row": 227, "column": 42}}, {"id": 772, "type": "parameter_declaration", "text": "void *handle", "parent": 771, "children": [773, 774], "start_point": {"row": 226, "column": 29}, "end_point": {"row": 226, "column": 41}}, {"id": 773, "type": "primitive_type", "text": "void", "parent": 772, "children": [], "start_point": {"row": 226, "column": 29}, "end_point": {"row": 226, "column": 33}}, {"id": 774, "type": "pointer_declarator", "text": "*handle", "parent": 772, "children": [775, 776], "start_point": {"row": 226, "column": 34}, "end_point": {"row": 226, "column": 41}}, {"id": 775, "type": "*", "text": "*", "parent": 774, "children": [], "start_point": {"row": 226, "column": 34}, "end_point": {"row": 226, "column": 35}}, {"id": 776, "type": "identifier", "text": "handle", "parent": 774, "children": [], "start_point": {"row": 226, "column": 35}, "end_point": {"row": 226, "column": 41}}, {"id": 777, "type": "parameter_declaration", "text": "uint8_t reg", "parent": 771, "children": [778, 779], "start_point": {"row": 226, "column": 43}, "end_point": {"row": 226, "column": 54}}, {"id": 778, "type": "primitive_type", "text": "uint8_t", "parent": 777, "children": [], "start_point": {"row": 226, "column": 43}, "end_point": {"row": 226, "column": 50}}, {"id": 779, "type": "identifier", "text": "reg", "parent": 777, "children": [], "start_point": {"row": 226, "column": 51}, "end_point": {"row": 226, "column": 54}}, {"id": 780, "type": "parameter_declaration", "text": "uint8_t *bufp", "parent": 771, "children": [781, 782], "start_point": {"row": 226, "column": 56}, "end_point": {"row": 226, "column": 69}}, {"id": 781, "type": "primitive_type", "text": "uint8_t", "parent": 780, "children": [], "start_point": {"row": 226, "column": 56}, "end_point": {"row": 226, "column": 63}}, {"id": 782, "type": "pointer_declarator", "text": "*bufp", "parent": 780, "children": [783, 784], "start_point": {"row": 226, "column": 64}, "end_point": {"row": 226, "column": 69}}, {"id": 783, "type": "*", "text": "*", "parent": 782, "children": [], "start_point": {"row": 226, "column": 64}, "end_point": {"row": 226, "column": 65}}, {"id": 784, "type": "identifier", "text": "bufp", "parent": 782, "children": [], "start_point": {"row": 226, "column": 65}, "end_point": {"row": 226, "column": 69}}, {"id": 785, "type": "parameter_declaration", "text": "uint16_t len", "parent": 771, "children": [786, 787], "start_point": {"row": 227, "column": 29}, "end_point": {"row": 227, "column": 41}}, {"id": 786, "type": "primitive_type", "text": "uint16_t", "parent": 785, "children": [], "start_point": {"row": 227, "column": 29}, "end_point": {"row": 227, "column": 37}}, {"id": 787, "type": "identifier", "text": "len", "parent": 785, "children": [], "start_point": {"row": 227, "column": 38}, "end_point": {"row": 227, "column": 41}}, {"id": 788, "type": "assignment_expression", "text": "reg |= 0x80", "parent": 767, "children": [789, 790, 791], "start_point": {"row": 229, "column": 2}, "end_point": {"row": 229, "column": 13}}, {"id": 789, "type": "identifier", "text": "reg", "parent": 788, "children": [], "start_point": {"row": 229, "column": 2}, "end_point": {"row": 229, "column": 5}}, {"id": 790, "type": "|=", "text": "|=", "parent": 788, "children": [], "start_point": {"row": 229, "column": 6}, "end_point": {"row": 229, "column": 8}}, {"id": 791, "type": "number_literal", "text": "0x80", "parent": 788, "children": [], "start_point": {"row": 229, "column": 9}, "end_point": {"row": 229, "column": 13}}, {"id": 792, "type": "call_expression", "text": "HAL_I2C_Mem_Read(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)", "parent": 767, "children": [793, 794], "start_point": {"row": 230, "column": 2}, "end_point": {"row": 230, "column": 90}}, {"id": 793, "type": "identifier", "text": "HAL_I2C_Mem_Read", "parent": 792, "children": [], "start_point": {"row": 230, "column": 2}, "end_point": {"row": 230, "column": 18}}, {"id": 794, "type": "argument_list", "text": "(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000)", "parent": 792, "children": [795, 796, 797, 798, 799, 800, 801], "start_point": {"row": 230, "column": 18}, "end_point": {"row": 230, "column": 90}}, {"id": 795, "type": "identifier", "text": "handle", "parent": 794, "children": [], "start_point": {"row": 230, "column": 19}, "end_point": {"row": 230, "column": 25}}, {"id": 796, "type": "identifier", "text": "HTS221_I2C_ADDRESS", "parent": 794, "children": [], "start_point": {"row": 230, "column": 27}, "end_point": {"row": 230, "column": 45}}, {"id": 797, "type": "identifier", "text": "reg", "parent": 794, "children": [], "start_point": {"row": 230, "column": 47}, "end_point": {"row": 230, "column": 50}}, {"id": 798, "type": "identifier", "text": "I2C_MEMADD_SIZE_8BIT", "parent": 794, "children": [], "start_point": {"row": 230, "column": 52}, "end_point": {"row": 230, "column": 72}}, {"id": 799, "type": "identifier", "text": "bufp", "parent": 794, "children": [], "start_point": {"row": 230, "column": 74}, "end_point": {"row": 230, "column": 78}}, {"id": 800, "type": "identifier", "text": "len", "parent": 794, "children": [], "start_point": {"row": 230, "column": 80}, "end_point": {"row": 230, "column": 83}}, {"id": 801, "type": "number_literal", "text": "1000", "parent": 794, "children": [], "start_point": {"row": 230, "column": 85}, "end_point": {"row": 230, "column": 89}}, {"id": 802, "type": "return_statement", "text": "return 0;", "parent": 767, "children": [803], "start_point": {"row": 231, "column": 2}, "end_point": {"row": 231, "column": 11}}, {"id": 803, "type": "number_literal", "text": "0", "parent": 802, "children": [], "start_point": {"row": 231, "column": 9}, "end_point": {"row": 231, "column": 10}}]}, "node_categories": {"declarations": {"functions": [3, 5, 201, 203, 318, 320, 351, 353, 384, 386, 463, 465, 496, 498, 527, 529, 669, 671, 730, 732, 767, 769], "variables": [8, 13, 18, 23, 28, 33, 36, 206, 211, 268, 283, 323, 328, 331, 336, 356, 361, 364, 369, 389, 394, 397, 468, 473, 476, 481, 501, 506, 509, 514, 532, 537, 674, 679, 735, 740, 743, 748, 772, 777, 780, 785], "classes": [], "imports": [0, 1], "modules": [], "enums": []}, "statements": {"expressions": [47, 54, 62, 63, 64, 73, 80, 91, 98, 108, 109, 110, 119, 126, 137, 144, 154, 155, 156, 165, 172, 183, 190, 215, 221, 227, 232, 235, 237, 240, 241, 242, 243, 244, 245, 251, 252, 253, 259, 260, 261, 274, 277, 279, 289, 292, 294, 298, 301, 304, 307, 310, 313, 339, 372, 401, 407, 413, 418, 421, 423, 426, 427, 433, 436, 440, 443, 445, 447, 449, 452, 455, 458, 484, 517, 541, 547, 553, 562, 565, 567, 570, 571, 577, 580, 582, 583, 586, 589, 591, 592, 595, 598, 600, 601, 604, 607, 609, 610, 613, 616, 618, 619, 622, 625, 627, 628, 631, 634, 636, 637, 640, 643, 645, 646, 649, 652, 655, 658, 661, 664, 683, 684, 685, 686, 687, 688, 689, 693, 699, 700, 701, 702, 703, 707, 711, 712, 713, 717, 721, 722, 723, 727, 755, 792], "assignments": [44, 70, 88, 116, 134, 162, 180, 214, 220, 226, 400, 406, 412, 540, 546, 552, 558, 751, 788], "loops": [], "conditionals": [6, 9, 12, 14, 17, 19, 22, 24, 27, 29, 32, 35, 40, 45, 48, 50, 55, 57, 58, 59, 61, 65, 67, 71, 74, 76, 81, 83, 84, 85, 89, 92, 94, 99, 101, 102, 103, 107, 111, 113, 117, 120, 122, 127, 129, 130, 131, 135, 138, 140, 145, 147, 148, 149, 153, 157, 159, 163, 166, 168, 173, 175, 176, 177, 181, 184, 186, 191, 193, 194, 195, 204, 207, 210, 212, 213, 216, 217, 219, 222, 223, 225, 228, 229, 231, 233, 236, 238, 239, 246, 247, 249, 254, 255, 257, 262, 263, 265, 271, 275, 278, 280, 282, 286, 290, 293, 295, 297, 299, 302, 303, 305, 308, 309, 311, 314, 315, 321, 327, 330, 335, 338, 340, 342, 343, 344, 345, 346, 347, 354, 360, 363, 368, 371, 373, 375, 376, 377, 378, 379, 380, 387, 390, 393, 396, 399, 402, 403, 405, 408, 409, 411, 414, 415, 417, 419, 422, 424, 425, 428, 430, 434, 437, 438, 441, 444, 446, 448, 450, 453, 454, 456, 459, 460, 466, 472, 475, 480, 483, 485, 487, 488, 489, 490, 491, 492, 499, 505, 508, 513, 516, 518, 520, 521, 522, 523, 524, 525, 530, 533, 536, 539, 542, 543, 545, 548, 549, 551, 554, 555, 557, 559, 563, 566, 568, 569, 572, 574, 578, 581, 584, 585, 587, 590, 593, 594, 596, 599, 602, 603, 605, 608, 611, 612, 614, 617, 620, 621, 623, 626, 629, 630, 632, 635, 638, 639, 641, 644, 647, 648, 650, 653, 654, 656, 659, 660, 662, 665, 666, 672, 675, 678, 681, 690, 691, 694, 695, 697, 704, 705, 708, 709, 714, 715, 718, 719, 724, 725, 728, 729, 733, 739, 742, 747, 750, 752, 756, 758, 759, 760, 761, 762, 763, 770, 776, 779, 784, 787, 789, 793, 795, 796, 797, 798, 799, 800], "returns": [105, 151, 197, 199, 266, 316, 349, 382, 431, 461, 494, 575, 667, 682, 765, 802], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 41, 43, 51, 60, 69, 77, 86, 95, 104, 106, 115, 123, 132, 141, 150, 152, 161, 169, 178, 187, 196, 198, 200, 267, 273, 288, 317, 348, 350, 381, 383, 432, 462, 493, 495, 526, 561, 576, 668, 754, 764, 766, 791, 801, 803], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 3, "universal_type": "function", "name": "init_sensors", "text_snippet": "int init_sensors(UART_HandleTypeDef *UART_bus, I2C_HandleTypeDef *stts751_bus, I2C_HandleTypeDef *lp"}, {"node_id": 5, "universal_type": "function", "name": "unknown", "text_snippet": "init_sensors(UART_HandleTypeDef *UART_bus, I2C_HandleTypeDef *stts751_bus, I2C_HandleTypeDef *lps22h"}, {"node_id": 201, "universal_type": "function", "name": "init_stts751", "text_snippet": "int init_stts751(I2C_HandleTypeDef *stts751_bus)\n{\n\tstts751_id_t stts751_whoamI;\n\n\tstts751_dev_ctx.w"}, {"node_id": 203, "universal_type": "function", "name": "unknown", "text_snippet": "init_stts751(I2C_HandleTypeDef *stts751_bus)"}, {"node_id": 318, "universal_type": "function", "name": "unknown", "text_snippet": "int32_t platform_write_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n\tHAL_I2C_Me"}, {"node_id": 320, "universal_type": "function", "name": "unknown", "text_snippet": "platform_write_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)"}, {"node_id": 351, "universal_type": "function", "name": "unknown", "text_snippet": "int32_t platform_read_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n\tHAL_I2C_Mem"}, {"node_id": 353, "universal_type": "function", "name": "unknown", "text_snippet": "platform_read_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)"}, {"node_id": 384, "universal_type": "function", "name": "init_lps22hh", "text_snippet": "int init_lps22hh(I2C_HandleTypeDef *lps22hh_bus)\n{\n\tuint8_t lps22hh_whoamI;\n\tuint8_t lps22hh_rst;\n\n\t"}, {"node_id": 386, "universal_type": "function", "name": "unknown", "text_snippet": "init_lps22hh(I2C_HandleTypeDef *lps22hh_bus)"}, {"node_id": 463, "universal_type": "function", "name": "unknown", "text_snippet": "int32_t platform_write_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n\tHAL_I2C_Me"}, {"node_id": 465, "universal_type": "function", "name": "unknown", "text_snippet": "platform_write_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)"}, {"node_id": 496, "universal_type": "function", "name": "unknown", "text_snippet": "int32_t platform_read_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n\tHAL_I2C_Mem"}, {"node_id": 498, "universal_type": "function", "name": "unknown", "text_snippet": "platform_read_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)"}, {"node_id": 527, "universal_type": "function", "name": "init_hts221", "text_snippet": "int init_hts221(I2C_HandleTypeDef *hts221_bus)\n{\n\tuint8_t hts221_whoamI;\n\n\thts221_dev_ctx.write_reg "}, {"node_id": 529, "universal_type": "function", "name": "unknown", "text_snippet": "init_hts221(I2C_HandleTypeDef *hts221_bus)"}, {"node_id": 669, "universal_type": "function", "name": "unknown", "text_snippet": "float linear_interpolation(lin_t *lin, int16_t x)\n{\n\treturn ((lin->y1 - lin->y0) * x + ((lin->x1 * l"}, {"node_id": 671, "universal_type": "function", "name": "unknown", "text_snippet": "linear_interpolation(lin_t *lin, int16_t x)"}, {"node_id": 730, "universal_type": "function", "name": "unknown", "text_snippet": "int32_t platform_write_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n "}, {"node_id": 732, "universal_type": "function", "name": "unknown", "text_snippet": "platform_write_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16"}, {"node_id": 767, "universal_type": "function", "name": "unknown", "text_snippet": "int32_t platform_read_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n "}, {"node_id": 769, "universal_type": "function", "name": "unknown", "text_snippet": "platform_read_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include \"init_stwin_sensors.h\"\n"}, {"node_id": 1, "text": "#include"}]}, "original_source_code": "/**\n ******************************************************************************\n * @file : init_stwin_sensors.c\n * @brief : Sensors functions for stwin board\n ******************************************************************************\n * @attention\n *\n * <h2><center>&copy; Copyright (c) 2021 enzopicas.\n * All rights reserved.</center></h2>\n *\n * This software component is licensed by ST under BSD 3-Clause license,\n * the \"License\"; You may not use this file except in compliance with the\n * License. You may obtain a copy of the License at:\n * opensource.org/licenses/BSD-3-Clause\n *\n ******************************************************************************\n */\n\n#include \"init_stwin_sensors.h\"\n\n/*---------- GLOBAL ----------*/\nint init_sensors(UART_HandleTypeDef *UART_bus, I2C_HandleTypeDef *stts751_bus, I2C_HandleTypeDef *lps22hh_bus,\n\t\tI2C_HandleTypeDef *hts221_bus, SPI_HandleTypeDef *ism330_bus)\n{\n\tuint16_t uart_buf_len;\n\tuint8_t uart_buf[500] = \"\";\n\n\t/*-------- START --------*/\n\tuart_buf_len = sprintf(uart_buf, \"---- Demarrage de l'UART ----\\r\\n\");\n\tHAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\n\t/*-------- STTS751 --------*/\n\tif (init_stts751(stts751_bus) == 0)\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init STTS751 OK\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t}\n\telse\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init STTS751 Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -1;\n\t}\n\n\t/*-------- LPS22HH --------*/\n\tif (init_lps22hh(lps22hh_bus) == 0)\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init LPS22HH OK\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t}\n\telse\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init LPS22HH Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -2;\n\t}\n\n\t/*-------- HTS221 --------*/\n\n\tif (init_hts221(hts221_bus) == 0)\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init HTS221 OK\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t}\n\telse\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init HTS221 Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -3;\n\t}\n\n\n\t/*-------- ISM330 --------*/\n\t/*\n\tif (init_ism330(ism330_bus) == 0)\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init ISM330 OK\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t}\n\telse\n\t{\n\t uart_buf_len = sprintf(uart_buf, \"---- Init ISM330 Failure\\r\\n\");\n\t HAL_UART_Transmit(UART_bus, uart_buf, uart_buf_len, 100);\n\t return -4;\n\t}\n\t*/\n\n\treturn 0;\n}\n\n/*---------- STTS 751 ----------*/\nint init_stts751(I2C_HandleTypeDef *stts751_bus)\n{\n\tstts751_id_t stts751_whoamI;\n\n\tstts751_dev_ctx.write_reg = platform_write_stts751;\n\tstts751_dev_ctx.read_reg = platform_read_stts751;\n\tstts751_dev_ctx.handle = stts751_bus;\n\n\tstts751_device_id_get(&stts751_dev_ctx, &stts751_whoamI);\n\tif ( (stts751_whoamI.product_id != STTS751_ID_0xxxx) ||\n\t (stts751_whoamI.manufacturer_id != STTS751_ID_MAN) ||\n\t (stts751_whoamI.revision_id != STTS751_REV) )\n\t{\n\t return -1;\n\t}\n\n\t/* Enable interrupt on high(=49.5 degC)/low(=-4.5 degC) temperature. */\n\tfloat temperature_high_limit = 49.5f;\n\tstts751_high_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_high_limit));\n\n\tfloat temperature_low_limit = -4.5f;\n\tstts751_low_temperature_threshold_set(&stts751_dev_ctx, stts751_from_celsius_to_lsb(temperature_low_limit));\n\n\tstts751_pin_event_route_set(&stts751_dev_ctx, PROPERTY_ENABLE);\n\n\t/* Set Output Data Rate */\n\tstts751_temp_data_rate_set(&stts751_dev_ctx, STTS751_TEMP_ODR_8Hz);\n\n\t/* Set Resolution */\n\tstts751_resolution_set(&stts751_dev_ctx, STTS751_12bit);\n\n\treturn 0;\n}\n\nint32_t platform_write_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n\tHAL_I2C_Mem_Write(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n\treturn 0;\n}\n\nint32_t platform_read_stts751(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n\tHAL_I2C_Mem_Read(handle, STTS751_0xxxx_ADD_7K5, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n\treturn 0;\n}\n\n/*---------- LPS22HH ----------*/\nint init_lps22hh(I2C_HandleTypeDef *lps22hh_bus)\n{\n\tuint8_t lps22hh_whoamI;\n\tuint8_t lps22hh_rst;\n\n\tlps22hh_dev_ctx.write_reg = platform_write_lps22hh;\n\tlps22hh_dev_ctx.read_reg = platform_read_lps22hh;\n\tlps22hh_dev_ctx.handle = lps22hh_bus;\n\n\tlps22hh_device_id_get(&lps22hh_dev_ctx, &lps22hh_whoamI);\n\tif (lps22hh_whoamI != LPS22HH_ID)\n\t{\n\t\treturn -1;\n\t}\n\n\tlps22hh_reset_set(&lps22hh_dev_ctx, PROPERTY_ENABLE);\n\tdo {\n\t lps22hh_reset_get(&lps22hh_dev_ctx, &lps22hh_rst);\n\t} while (lps22hh_rst);\n\n\t/* Enable Block Data Update */\n\tlps22hh_block_data_update_set(&lps22hh_dev_ctx, PROPERTY_ENABLE);\n\t/* Set Output Data Rate */\n\tlps22hh_data_rate_set(&lps22hh_dev_ctx, LPS22HH_10_Hz_LOW_NOISE);\n\n\treturn 0;\n}\n\nint32_t platform_write_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n\tHAL_I2C_Mem_Write(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n\treturn 0;\n}\n\nint32_t platform_read_lps22hh(void *handle, uint8_t reg, uint8_t *bufp, uint16_t len)\n{\n\tHAL_I2C_Mem_Read(handle, LPS22HH_I2C_ADD_H, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n}\n\n/*---------- HTS221 ----------*/\nint init_hts221(I2C_HandleTypeDef *hts221_bus)\n{\n\tuint8_t hts221_whoamI;\n\n\thts221_dev_ctx.write_reg = platform_write_hts221;\n\thts221_dev_ctx.read_reg = platform_read_hts221;\n\thts221_dev_ctx.handle = hts221_bus;\n\n\thts221_whoamI = 0;\n\thts221_device_id_get(&hts221_dev_ctx, &hts221_whoamI);\n\tif (hts221_whoamI != HTS221_ID)\n\t{\n\t\treturn -1;\n\t}\n\n\thts221_hum_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.x0);\n\thts221_hum_rh_point_0_get(&hts221_dev_ctx, &hts221_lin_hum.y0);\n\thts221_hum_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.x1);\n\thts221_hum_rh_point_1_get(&hts221_dev_ctx, &hts221_lin_hum.y1);\n\t/* Read temperature calibration coefficient */\n\thts221_temp_adc_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.x0);\n\thts221_temp_deg_point_0_get(&hts221_dev_ctx, &hts221_lin_temp.y0);\n\thts221_temp_adc_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.x1);\n\thts221_temp_deg_point_1_get(&hts221_dev_ctx, &hts221_lin_temp.y1);\n\t/* Enable Block Data Update */\n\thts221_block_data_update_set(&hts221_dev_ctx, PROPERTY_ENABLE);\n\t/* Set Output Data Rate */\n\thts221_data_rate_set(&hts221_dev_ctx, HTS221_ODR_7Hz);\n\t/* Device power on */\n\thts221_power_on_set(&hts221_dev_ctx, PROPERTY_ENABLE);\n\n\treturn 0;\n}\n\nfloat linear_interpolation(lin_t *lin, int16_t x)\n{\n\treturn ((lin->y1 - lin->y0) * x + ((lin->x1 * lin->y0) -\n\t (lin->x0 * lin->y1))) / (lin->x1 - lin->x0);\n}\n\nint32_t platform_write_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)\n{\n reg |= 0x80;\n HAL_I2C_Mem_Write(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}\n\nint32_t platform_read_hts221(void *handle, uint8_t reg, uint8_t *bufp,\n uint16_t len)\n{\n reg |= 0x80;\n HAL_I2C_Mem_Read(handle, HTS221_I2C_ADDRESS, reg, I2C_MEMADD_SIZE_8BIT, bufp, len, 1000);\n return 0;\n}\n\n/*---------- ISM330 ----------*/\n/*\nint init_ism330(SPI_HandleTypeDef *ism330_bus)\n{\n\tism330_dev_ctx.write_reg = platform_write;\n\tism330_dev_ctx.read_reg = platform_read;\n\tism330_dev_ctx.handle = &ism330_bus;\n\n\tism330dhcx_device_id_get(&ism330_dev_ctx, &ism330_whoamI);\n\tif (ism330_whoamI != ISM330DHCX_ID)\n\t{\n\t\treturn -1;\n\t}\n\n\tism330dhcx_reset_set(&ism330_dev_ctx, PROPERTY_ENABLE);\n\tdo\n\t{\n\t\tism330dhcx_reset_get(&ism330_dev_ctx, &ism330_rst);\n\t} while (ism330_rst);\n\n\t//* Enable Block Data Update *\n\tism330dhcx_block_data_update_set(&ism330_dev_ctx, PROPERTY_ENABLE);\n\t//* Set Output Data Rate\n\tism330dhcx_xl_data_rate_set(&ism330_dev_ctx, ISM330DHCX_XL_ODR_12Hz5);\n\tism330dhcx_gy_data_rate_set(&ism330_dev_ctx, ISM330DHCX_GY_ODR_12Hz5);\n\t//* Set full scale *\n\tism330dhcx_xl_full_scale_set(&ism330_dev_ctx, ISM330DHCX_2g);\n\tism330dhcx_gy_full_scale_set(&ism330_dev_ctx, ISM330DHCX_2000dps);\n\t//* Configure filtering chain(No aux interface) *\n\tism330dhcx_xl_hp_path_on_out_set(&ism330_dev_ctx, ISM330DHCX_LP_ODR_DIV_100);\n\tism330dhcx_xl_filter_lp2_set(&ism330_dev_ctx, PROPERTY_ENABLE);\n\n\treturn 0;\n}\n*/\n"}
80,516
c
#include <stdio.h> int cont; int main(void){ for(cont = 1; cont > 5; cont++){ // cont =6 ; 6 <= 5-> true printf("\n\t %i --> Te amo <3", cont); //5 -- Te amo <3 } printf("\n\n La variable cont vale: %i", cont); // 6 return 0; }
22.8
10
(translation_unit) "#include <stdio.h>\n\nint cont;\n\nint main(void){ \n\n for(cont = 1; cont > 5; cont++){ // cont =6 ; 6 <= 5-> true\n printf("\n\t %i --> Te amo <3", cont); //5 -- Te amo <3\n }\n \n printf("\n\n La variable cont vale: %i", cont); // 6\n\n return 0;\n}\n" (preproc_include) "#include <stdio.h>\n" (#include) "#include" (system_lib_string) "<stdio.h>" (declaration) "int cont;" (primitive_type) "int" (identifier) "cont" (;) ";" (function_definition) "int main(void){ \n\n for(cont = 1; cont > 5; cont++){ // cont =6 ; 6 <= 5-> true\n printf("\n\t %i --> Te amo <3", cont); //5 -- Te amo <3\n }\n \n printf("\n\n La variable cont vale: %i", cont); // 6\n\n return 0;\n}" (primitive_type) "int" (function_declarator) "main(void)" (identifier) "main" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (compound_statement) "{ \n\n for(cont = 1; cont > 5; cont++){ // cont =6 ; 6 <= 5-> true\n printf("\n\t %i --> Te amo <3", cont); //5 -- Te amo <3\n }\n \n printf("\n\n La variable cont vale: %i", cont); // 6\n\n return 0;\n}" ({) "{" (for_statement) "for(cont = 1; cont > 5; cont++){ // cont =6 ; 6 <= 5-> true\n printf("\n\t %i --> Te amo <3", cont); //5 -- Te amo <3\n }" (for) "for" (() "(" (assignment_expression) "cont = 1" (identifier) "cont" (=) "=" (number_literal) "1" (;) ";" (binary_expression) "cont > 5" (identifier) "cont" (>) ">" (number_literal) "5" (;) ";" (update_expression) "cont++" (identifier) "cont" (++) "++" ()) ")" (compound_statement) "{ // cont =6 ; 6 <= 5-> true\n printf("\n\t %i --> Te amo <3", cont); //5 -- Te amo <3\n }" ({) "{" (comment) "// cont =6 ; 6 <= 5-> true" (expression_statement) "printf("\n\t %i --> Te amo <3", cont);" (call_expression) "printf("\n\t %i --> Te amo <3", cont)" (identifier) "printf" (argument_list) "("\n\t %i --> Te amo <3", cont)" (() "(" (string_literal) ""\n\t %i --> Te amo <3"" (") """ (escape_sequence) "\n" (escape_sequence) "\t" (string_content) " %i --> Te amo <3" (") """ (,) "," (identifier) "cont" ()) ")" (;) ";" (comment) "//5 -- Te amo <3" (}) "}" (expression_statement) "printf("\n\n La variable cont vale: %i", cont);" (call_expression) "printf("\n\n La variable cont vale: %i", cont)" (identifier) "printf" (argument_list) "("\n\n La variable cont vale: %i", cont)" (() "(" (string_literal) ""\n\n La variable cont vale: %i"" (") """ (escape_sequence) "\n" (escape_sequence) "\n" (string_content) " La variable cont vale: %i" (") """ (,) "," (identifier) "cont" ()) ")" (;) ";" (comment) "// 6" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}"
77
0
{"language": "c", "success": true, "metadata": {"lines": 10, "avg_line_length": 22.8, "nodes": 41, "errors": 0, "source_hash": "19314e28985ae15e4763ee91ffdcdf13666bfcfdabc1d33af3130cb7f954a226", "categorized_nodes": 28}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <stdio.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<stdio.h>", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 18}}, {"id": 3, "type": "declaration", "text": "int cont;", "parent": null, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 9}}, {"id": 4, "type": "primitive_type", "text": "int", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 3}}, {"id": 5, "type": "identifier", "text": "cont", "parent": 3, "children": [], "start_point": {"row": 2, "column": 4}, "end_point": {"row": 2, "column": 8}}, {"id": 6, "type": "function_definition", "text": "int main(void){ \n\n\tfor(cont = 1; cont > 5; cont++){ // cont =6 ; 6 <= 5-> true\n\t\tprintf(\"\\n\\t %i --> Te amo <3\", cont); //5 -- Te amo <3\n\t}\n\t\n\tprintf(\"\\n\\n La variable cont vale: %i\", cont); // 6\n\n\treturn 0;\n}", "parent": null, "children": [7, 8], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 7, "type": "primitive_type", "text": "int", "parent": 6, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 3}}, {"id": 8, "type": "function_declarator", "text": "main(void)", "parent": 6, "children": [9, 10], "start_point": {"row": 4, "column": 4}, "end_point": {"row": 4, "column": 14}}, {"id": 9, "type": "identifier", "text": "main", "parent": 8, "children": [], "start_point": {"row": 4, "column": 4}, "end_point": {"row": 4, "column": 8}}, {"id": 10, "type": "parameter_list", "text": "(void)", "parent": 8, "children": [11], "start_point": {"row": 4, "column": 8}, "end_point": {"row": 4, "column": 14}}, {"id": 11, "type": "parameter_declaration", "text": "void", "parent": 10, "children": [12], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 13}}, {"id": 12, "type": "primitive_type", "text": "void", "parent": 11, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 13}}, {"id": 13, "type": "for_statement", "text": "for(cont = 1; cont > 5; cont++){ // cont =6 ; 6 <= 5-> true\n\t\tprintf(\"\\n\\t %i --> Te amo <3\", cont); //5 -- Te amo <3\n\t}", "parent": 6, "children": [14, 18, 22], "start_point": {"row": 6, "column": 1}, "end_point": {"row": 8, "column": 2}}, {"id": 14, "type": "assignment_expression", "text": "cont = 1", "parent": 13, "children": [15, 16, 17], "start_point": {"row": 6, "column": 5}, "end_point": {"row": 6, "column": 13}}, {"id": 15, "type": "identifier", "text": "cont", "parent": 14, "children": [], "start_point": {"row": 6, "column": 5}, "end_point": {"row": 6, "column": 9}}, {"id": 16, "type": "=", "text": "=", "parent": 14, "children": [], "start_point": {"row": 6, "column": 10}, "end_point": {"row": 6, "column": 11}}, {"id": 17, "type": "number_literal", "text": "1", "parent": 14, "children": [], "start_point": {"row": 6, "column": 12}, "end_point": {"row": 6, "column": 13}}, {"id": 18, "type": "binary_expression", "text": "cont > 5", "parent": 13, "children": [19, 20, 21], "start_point": {"row": 6, "column": 15}, "end_point": {"row": 6, "column": 23}}, {"id": 19, "type": "identifier", "text": "cont", "parent": 18, "children": [], "start_point": {"row": 6, "column": 15}, "end_point": {"row": 6, "column": 19}}, {"id": 20, "type": ">", "text": ">", "parent": 18, "children": [], "start_point": {"row": 6, "column": 20}, "end_point": {"row": 6, "column": 21}}, {"id": 21, "type": "number_literal", "text": "5", "parent": 18, "children": [], "start_point": {"row": 6, "column": 22}, "end_point": {"row": 6, "column": 23}}, {"id": 22, "type": "update_expression", "text": "cont++", "parent": 13, "children": [23, 24], "start_point": {"row": 6, "column": 25}, "end_point": {"row": 6, "column": 31}}, {"id": 23, "type": "identifier", "text": "cont", "parent": 22, "children": [], "start_point": {"row": 6, "column": 25}, "end_point": {"row": 6, "column": 29}}, {"id": 24, "type": "++", "text": "++", "parent": 22, "children": [], "start_point": {"row": 6, "column": 29}, "end_point": {"row": 6, "column": 31}}, {"id": 25, "type": "call_expression", "text": "printf(\"\\n\\t %i --> Te amo <3\", cont)", "parent": 13, "children": [26, 27], "start_point": {"row": 7, "column": 2}, "end_point": {"row": 7, "column": 39}}, {"id": 26, "type": "identifier", "text": "printf", "parent": 25, "children": [], "start_point": {"row": 7, "column": 2}, "end_point": {"row": 7, "column": 8}}, {"id": 27, "type": "argument_list", "text": "(\"\\n\\t %i --> Te amo <3\", cont)", "parent": 25, "children": [28, 31], "start_point": {"row": 7, "column": 8}, "end_point": {"row": 7, "column": 39}}, {"id": 28, "type": "string_literal", "text": "\"\\n\\t %i --> Te amo <3\"", "parent": 27, "children": [29, 30], "start_point": {"row": 7, "column": 9}, "end_point": {"row": 7, "column": 32}}, {"id": 29, "type": "escape_sequence", "text": "\\n", "parent": 28, "children": [], "start_point": {"row": 7, "column": 10}, "end_point": {"row": 7, "column": 12}}, {"id": 30, "type": "escape_sequence", "text": "\\t", "parent": 28, "children": [], "start_point": {"row": 7, "column": 12}, "end_point": {"row": 7, "column": 14}}, {"id": 31, "type": "identifier", "text": "cont", "parent": 27, "children": [], "start_point": {"row": 7, "column": 34}, "end_point": {"row": 7, "column": 38}}, {"id": 32, "type": "call_expression", "text": "printf(\"\\n\\n La variable cont vale: %i\", cont)", "parent": 6, "children": [33, 34], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 47}}, {"id": 33, "type": "identifier", "text": "printf", "parent": 32, "children": [], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 7}}, {"id": 34, "type": "argument_list", "text": "(\"\\n\\n La variable cont vale: %i\", cont)", "parent": 32, "children": [35, 38], "start_point": {"row": 10, "column": 7}, "end_point": {"row": 10, "column": 47}}, {"id": 35, "type": "string_literal", "text": "\"\\n\\n La variable cont vale: %i\"", "parent": 34, "children": [36, 37], "start_point": {"row": 10, "column": 8}, "end_point": {"row": 10, "column": 40}}, {"id": 36, "type": "escape_sequence", "text": "\\n", "parent": 35, "children": [], "start_point": {"row": 10, "column": 9}, "end_point": {"row": 10, "column": 11}}, {"id": 37, "type": "escape_sequence", "text": "\\n", "parent": 35, "children": [], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 10, "column": 13}}, {"id": 38, "type": "identifier", "text": "cont", "parent": 34, "children": [], "start_point": {"row": 10, "column": 42}, "end_point": {"row": 10, "column": 46}}, {"id": 39, "type": "return_statement", "text": "return 0;", "parent": 6, "children": [40], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 10}}, {"id": 40, "type": "number_literal", "text": "0", "parent": 39, "children": [], "start_point": {"row": 12, "column": 8}, "end_point": {"row": 12, "column": 9}}]}, "node_categories": {"declarations": {"functions": [6, 8], "variables": [3, 11], "classes": [], "imports": [0, 1], "modules": [], "enums": []}, "statements": {"expressions": [18, 22, 25, 32], "assignments": [14], "loops": [13], "conditionals": [5, 9, 15, 19, 23, 26, 31, 33, 38], "returns": [39], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 17, 21, 28, 35, 40], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 6, "universal_type": "function", "name": "main", "text_snippet": "int main(void){ \n\n\tfor(cont = 1; cont > 5; cont++){ // cont =6 ; 6 <= 5-> true\n\t\tprintf(\"\\n\\t %i -->"}, {"node_id": 8, "universal_type": "function", "name": "unknown", "text_snippet": "main(void)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <stdio.h>\n"}, {"node_id": 1, "text": "#include"}]}, "original_source_code": "#include <stdio.h>\n\nint cont;\n\nint main(void){ \n\n\tfor(cont = 1; cont > 5; cont++){ // cont =6 ; 6 <= 5-> true\n\t\tprintf(\"\\n\\t %i --> Te amo <3\", cont); //5 -- Te amo <3\n\t}\n\t\n\tprintf(\"\\n\\n La variable cont vale: %i\", cont); // 6\n\n\treturn 0;\n}\n"}
80,517
c
// // CDFAnswer.h // // // Created by <NAME> on 27/1/16. // // #import <Foundation/Foundation.h> #import <CoreData/CoreData.h> NS_ASSUME_NONNULL_BEGIN @interface CDFAnswer : NSManagedObject // Insert code here to declare functionality of your managed object subclass @end NS_ASSUME_NONNULL_END #import "CDFAnswer+CoreDataProperties.h"
21.6
15
(translation_unit) "//\n// CDFAnswer.h\n// \n//\n// Created by <NAME> on 27/1/16.\n//\n//\n\n#import <Foundation/Foundation.h>\n#import <CoreData/CoreData.h>\n\nNS_ASSUME_NONNULL_BEGIN\n\n@interface CDFAnswer : NSManagedObject\n\n// Insert code here to declare functionality of your managed object subclass\n\n@end\n\nNS_ASSUME_NONNULL_END\n\n#import "CDFAnswer+CoreDataProperties.h"\n" (comment) "//" (comment) "// CDFAnswer.h" (comment) "// " (comment) "//" (comment) "// Created by <NAME> on 27/1/16." (comment) "//" (comment) "//" (preproc_call) "#import <Foundation/Foundation.h>\n" (preproc_directive) "#import" (preproc_arg) "<Foundation/Foundation.h>" (preproc_call) "#import <CoreData/CoreData.h>\n" (preproc_directive) "#import" (preproc_arg) "<CoreData/CoreData.h>" (declaration) "NS_ASSUME_NONNULL_BEGIN\n\n@interface" (type_identifier) "NS_ASSUME_NONNULL_BEGIN" (ERROR) "@" (ERROR) "@" (identifier) "interface" (;) "" (ERROR) "CDFAnswer : NSManagedObject\n\n// Insert code here to declare functionality of your managed object subclass\n\n@end\n\nNS_ASSUME_NONNULL_END" (identifier) "CDFAnswer" (:) ":" (type_identifier) "NSManagedObject" (comment) "// Insert code here to declare functionality of your managed object subclass" (ERROR) "@" (ERROR) "@" (identifier) "end" (identifier) "NS_ASSUME_NONNULL_END" (preproc_call) "#import "CDFAnswer+CoreDataProperties.h"\n" (preproc_directive) "#import" (preproc_arg) ""CDFAnswer+CoreDataProperties.h""
32
5
{"language": "c", "success": true, "metadata": {"lines": 15, "avg_line_length": 21.6, "nodes": 20, "errors": 0, "source_hash": "f18eb2f4eaeac00153da6f1c03d6b6845222fe63c5e3f1a55a7095eb57a3cac5", "categorized_nodes": 9}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#import <Foundation/Foundation.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#import", "parent": 0, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "<Foundation/Foundation.h>", "parent": 0, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 33}}, {"id": 3, "type": "preproc_call", "text": "#import <CoreData/CoreData.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 4, "type": "preproc_directive", "text": "#import", "parent": 3, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 7}}, {"id": 5, "type": "preproc_arg", "text": "<CoreData/CoreData.h>", "parent": 3, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 29}}, {"id": 6, "type": "declaration", "text": "NS_ASSUME_NONNULL_BEGIN\n\n@interface", "parent": null, "children": [7, 8, 10], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 13, "column": 10}}, {"id": 7, "type": "type_identifier", "text": "NS_ASSUME_NONNULL_BEGIN", "parent": 6, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 23}}, {"id": 8, "type": "ERROR", "text": "@", "parent": 6, "children": [9], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 9, "type": "ERROR", "text": "@", "parent": 8, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 10, "type": "identifier", "text": "interface", "parent": 6, "children": [], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 10}}, {"id": 11, "type": "ERROR", "text": "CDFAnswer : NSManagedObject\n\n// Insert code here to declare functionality of your managed object subclass\n\n@end\n\nNS_ASSUME_NONNULL_END", "parent": null, "children": [12, 13, 14, 16], "start_point": {"row": 13, "column": 11}, "end_point": {"row": 19, "column": 21}}, {"id": 12, "type": "identifier", "text": "CDFAnswer", "parent": 11, "children": [], "start_point": {"row": 13, "column": 11}, "end_point": {"row": 13, "column": 20}}, {"id": 13, "type": "type_identifier", "text": "NSManagedObject", "parent": 11, "children": [], "start_point": {"row": 13, "column": 23}, "end_point": {"row": 13, "column": 38}}, {"id": 14, "type": "ERROR", "text": "@", "parent": 11, "children": [15], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 15, "type": "ERROR", "text": "@", "parent": 14, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 16, "type": "identifier", "text": "NS_ASSUME_NONNULL_END", "parent": 11, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 21}}, {"id": 17, "type": "preproc_call", "text": "#import \"CDFAnswer+CoreDataProperties.h\"\n", "parent": null, "children": [18, 19], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 22, "column": 0}}, {"id": 18, "type": "preproc_directive", "text": "#import", "parent": 17, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 7}}, {"id": 19, "type": "preproc_arg", "text": "\"CDFAnswer+CoreDataProperties.h\"", "parent": 17, "children": [], "start_point": {"row": 21, "column": 8}, "end_point": {"row": 21, "column": 40}}]}, "node_categories": {"declarations": {"functions": [], "variables": [6], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [7, 10, 12, 13, 16], "returns": [], "exceptions": []}, "expressions": {"calls": [0, 3, 17], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// CDFAnswer.h\n// \n//\n// Created by <NAME> on 27/1/16.\n//\n//\n\n#import <Foundation/Foundation.h>\n#import <CoreData/CoreData.h>\n\nNS_ASSUME_NONNULL_BEGIN\n\n@interface CDFAnswer : NSManagedObject\n\n// Insert code here to declare functionality of your managed object subclass\n\n@end\n\nNS_ASSUME_NONNULL_END\n\n#import \"CDFAnswer+CoreDataProperties.h\"\n"}
80,518
c
#pragma once #if PARAM==0 #define SIZE 4 #elif PARAM==1 #define SIZE 30 #elif PARAM==2 #define SIZE 50 #elif PARAM==3 #define SIZE 70 #elif PARAM==4 #define SIZE 90 #elif PARAM==5 #define SIZE 110 #else #error unknown PARAM #endif #define MAT(m, r, c) (m)[(r)*SIZE+(c)] struct Input { int a[SIZE*SIZE]; int b[SIZE*SIZE]; }; struct Output { int r[SIZE*SIZE]; }; void outsource(struct Input *input, struct Output *output);
14.33
30
(translation_unit) "#pragma once \n \n#if PARAM==0 \n#define SIZE 4 \n#elif PARAM==1 \n#define SIZE 30 \n#elif PARAM==2 \n#define SIZE 50 \n#elif PARAM==3 \n#define SIZE 70 \n#elif PARAM==4 \n#define SIZE 90 \n#elif PARAM==5 \n#define SIZE 110 \n#else \n#error unknown PARAM \n#endif \n \n#define MAT(m, r, c) (m)[(r)*SIZE+(c)] \n \nstruct Input { \n int a[SIZE*SIZE]; \n int b[SIZE*SIZE]; \n}; \n \nstruct Output { \n int r[SIZE*SIZE]; \n}; \n \nvoid outsource(struct Input *input, struct Output *output); \n" (preproc_call) "#pragma once \n" (preproc_directive) "#pragma" (preproc_arg) "once " (preproc_if) "#if PARAM==0 \n#define SIZE 4 \n#elif PARAM==1 \n#define SIZE 30 \n#elif PARAM==2 \n#define SIZE 50 \n#elif PARAM==3 \n#define SIZE 70 \n#elif PARAM==4 \n#define SIZE 90 \n#elif PARAM==5 \n#define SIZE 110 \n#else \n#error unknown PARAM \n#endif" (#if) "#if" (binary_expression) "PARAM==0" (identifier) "PARAM" (==) "==" (number_literal) "0" ( ) "\n" (preproc_def) "#define SIZE 4 \n" (#define) "#define" (identifier) "SIZE" (preproc_arg) "4 " (preproc_elif) "#elif PARAM==1 \n#define SIZE 30 \n#elif PARAM==2 \n#define SIZE 50 \n#elif PARAM==3 \n#define SIZE 70 \n#elif PARAM==4 \n#define SIZE 90 \n#elif PARAM==5 \n#define SIZE 110 \n#else \n#error unknown PARAM \n" (#elif) "#elif" (binary_expression) "PARAM==1" (identifier) "PARAM" (==) "==" (number_literal) "1" ( ) "\n" (preproc_def) "#define SIZE 30 \n" (#define) "#define" (identifier) "SIZE" (preproc_arg) "30 " (preproc_elif) "#elif PARAM==2 \n#define SIZE 50 \n#elif PARAM==3 \n#define SIZE 70 \n#elif PARAM==4 \n#define SIZE 90 \n#elif PARAM==5 \n#define SIZE 110 \n#else \n#error unknown PARAM \n" (#elif) "#elif" (binary_expression) "PARAM==2" (identifier) "PARAM" (==) "==" (number_literal) "2" ( ) "\n" (preproc_def) "#define SIZE 50 \n" (#define) "#define" (identifier) "SIZE" (preproc_arg) "50 " (preproc_elif) "#elif PARAM==3 \n#define SIZE 70 \n#elif PARAM==4 \n#define SIZE 90 \n#elif PARAM==5 \n#define SIZE 110 \n#else \n#error unknown PARAM \n" (#elif) "#elif" (binary_expression) "PARAM==3" (identifier) "PARAM" (==) "==" (number_literal) "3" ( ) "\n" (preproc_def) "#define SIZE 70 \n" (#define) "#define" (identifier) "SIZE" (preproc_arg) "70 " (preproc_elif) "#elif PARAM==4 \n#define SIZE 90 \n#elif PARAM==5 \n#define SIZE 110 \n#else \n#error unknown PARAM \n" (#elif) "#elif" (binary_expression) "PARAM==4" (identifier) "PARAM" (==) "==" (number_literal) "4" ( ) "\n" (preproc_def) "#define SIZE 90 \n" (#define) "#define" (identifier) "SIZE" (preproc_arg) "90 " (preproc_elif) "#elif PARAM==5 \n#define SIZE 110 \n#else \n#error unknown PARAM \n" (#elif) "#elif" (binary_expression) "PARAM==5" (identifier) "PARAM" (==) "==" (number_literal) "5" ( ) "\n" (preproc_def) "#define SIZE 110 \n" (#define) "#define" (identifier) "SIZE" (preproc_arg) "110 " (preproc_else) "#else \n#error unknown PARAM \n" (#else) "#else" (preproc_call) "#error unknown PARAM \n" (preproc_directive) "#error" (preproc_arg) "unknown PARAM " (#endif) "#endif" (preproc_function_def) "#define MAT(m, r, c) (m)[(r)*SIZE+(c)] \n" (#define) "#define" (identifier) "MAT" (preproc_params) "(m, r, c)" (() "(" (identifier) "m" (,) "," (identifier) "r" (,) "," (identifier) "c" ()) ")" (preproc_arg) "(m)[(r)*SIZE+(c)] " (struct_specifier) "struct Input { \n int a[SIZE*SIZE]; \n int b[SIZE*SIZE]; \n}" (struct) "struct" (type_identifier) "Input" (field_declaration_list) "{ \n int a[SIZE*SIZE]; \n int b[SIZE*SIZE]; \n}" ({) "{" (field_declaration) "int a[SIZE*SIZE];" (primitive_type) "int" (array_declarator) "a[SIZE*SIZE]" (field_identifier) "a" ([) "[" (binary_expression) "SIZE*SIZE" (identifier) "SIZE" (*) "*" (identifier) "SIZE" (]) "]" (;) ";" (field_declaration) "int b[SIZE*SIZE];" (primitive_type) "int" (array_declarator) "b[SIZE*SIZE]" (field_identifier) "b" ([) "[" (binary_expression) "SIZE*SIZE" (identifier) "SIZE" (*) "*" (identifier) "SIZE" (]) "]" (;) ";" (}) "}" (;) ";" (struct_specifier) "struct Output { \n int r[SIZE*SIZE]; \n}" (struct) "struct" (type_identifier) "Output" (field_declaration_list) "{ \n int r[SIZE*SIZE]; \n}" ({) "{" (field_declaration) "int r[SIZE*SIZE];" (primitive_type) "int" (array_declarator) "r[SIZE*SIZE]" (field_identifier) "r" ([) "[" (binary_expression) "SIZE*SIZE" (identifier) "SIZE" (*) "*" (identifier) "SIZE" (]) "]" (;) ";" (}) "}" (;) ";" (declaration) "void outsource(struct Input *input, struct Output *output);" (primitive_type) "void" (function_declarator) "outsource(struct Input *input, struct Output *output)" (identifier) "outsource" (parameter_list) "(struct Input *input, struct Output *output)" (() "(" (parameter_declaration) "struct Input *input" (struct_specifier) "struct Input" (struct) "struct" (type_identifier) "Input" (pointer_declarator) "*input" (*) "*" (identifier) "input" (,) "," (parameter_declaration) "struct Output *output" (struct_specifier) "struct Output" (struct) "struct" (type_identifier) "Output" (pointer_declarator) "*output" (*) "*" (identifier) "output" ()) ")" (;) ";"
158
0
{"language": "c", "success": true, "metadata": {"lines": 30, "avg_line_length": 14.33, "nodes": 132, "errors": 0, "source_hash": "8b4cd0f9d28b256123c78ac1305851e0d368bcc99c0d56f4ff19b7e17cef02a4", "categorized_nodes": 78}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#pragma once\r\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#pragma", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "once\r", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 13}}, {"id": 3, "type": "preproc_if", "text": "#if PARAM==0\r\n#define SIZE\t4\r\n#elif PARAM==1\r\n#define SIZE\t30\r\n#elif PARAM==2\r\n#define SIZE\t50\r\n#elif PARAM==3\r\n#define SIZE\t70\r\n#elif PARAM==4\r\n#define SIZE 90\t\r\n#elif PARAM==5\r\n#define SIZE\t110\r\n#else\r\n#error unknown PARAM\r\n#endif", "parent": null, "children": [4, 5, 9, 10, 14, 74], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 16, "column": 6}}, {"id": 4, "type": "#if", "text": "#if", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 3}}, {"id": 5, "type": "binary_expression", "text": "PARAM==0", "parent": 3, "children": [6, 7, 8], "start_point": {"row": 2, "column": 4}, "end_point": {"row": 2, "column": 12}}, {"id": 6, "type": "identifier", "text": "PARAM", "parent": 5, "children": [], "start_point": {"row": 2, "column": 4}, "end_point": {"row": 2, "column": 9}}, {"id": 7, "type": "==", "text": "==", "parent": 5, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 11}}, {"id": 8, "type": "number_literal", "text": "0", "parent": 5, "children": [], "start_point": {"row": 2, "column": 11}, "end_point": {"row": 2, "column": 12}}, {"id": 9, "type": "\n", "text": "\n", "parent": 3, "children": [], "start_point": {"row": 2, "column": 13}, "end_point": {"row": 3, "column": 0}}, {"id": 10, "type": "preproc_def", "text": "#define SIZE\t4\r\n", "parent": 3, "children": [11, 12, 13], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 11, "type": "#define", "text": "#define", "parent": 10, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 7}}, {"id": 12, "type": "identifier", "text": "SIZE", "parent": 10, "children": [], "start_point": {"row": 3, "column": 8}, "end_point": {"row": 3, "column": 12}}, {"id": 13, "type": "preproc_arg", "text": "4\r", "parent": 10, "children": [], "start_point": {"row": 3, "column": 13}, "end_point": {"row": 3, "column": 15}}, {"id": 14, "type": "preproc_elif", "text": "#elif PARAM==1\r\n#define SIZE\t30\r\n#elif PARAM==2\r\n#define SIZE\t50\r\n#elif PARAM==3\r\n#define SIZE\t70\r\n#elif PARAM==4\r\n#define SIZE 90\t\r\n#elif PARAM==5\r\n#define SIZE\t110\r\n#else\r\n#error unknown PARAM\r\n", "parent": 3, "children": [15, 16, 20, 21, 25], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 15, "type": "#elif", "text": "#elif", "parent": 14, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 5}}, {"id": 16, "type": "binary_expression", "text": "PARAM==1", "parent": 14, "children": [17, 18, 19], "start_point": {"row": 4, "column": 6}, "end_point": {"row": 4, "column": 14}}, {"id": 17, "type": "identifier", "text": "PARAM", "parent": 16, "children": [], "start_point": {"row": 4, "column": 6}, "end_point": {"row": 4, "column": 11}}, {"id": 18, "type": "==", "text": "==", "parent": 16, "children": [], "start_point": {"row": 4, "column": 11}, "end_point": {"row": 4, "column": 13}}, {"id": 19, "type": "number_literal", "text": "1", "parent": 16, "children": [], "start_point": {"row": 4, "column": 13}, "end_point": {"row": 4, "column": 14}}, {"id": 20, "type": "\n", "text": "\n", "parent": 14, "children": [], "start_point": {"row": 4, "column": 15}, "end_point": {"row": 5, "column": 0}}, {"id": 21, "type": "preproc_def", "text": "#define SIZE\t30\r\n", "parent": 14, "children": [22, 23, 24], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 22, "type": "#define", "text": "#define", "parent": 21, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 7}}, {"id": 23, "type": "identifier", "text": "SIZE", "parent": 21, "children": [], "start_point": {"row": 5, "column": 8}, "end_point": {"row": 5, "column": 12}}, {"id": 24, "type": "preproc_arg", "text": "30\r", "parent": 21, "children": [], "start_point": {"row": 5, "column": 13}, "end_point": {"row": 5, "column": 16}}, {"id": 25, "type": "preproc_elif", "text": "#elif PARAM==2\r\n#define SIZE\t50\r\n#elif PARAM==3\r\n#define SIZE\t70\r\n#elif PARAM==4\r\n#define SIZE 90\t\r\n#elif PARAM==5\r\n#define SIZE\t110\r\n#else\r\n#error unknown PARAM\r\n", "parent": 14, "children": [26, 27, 31, 32, 36], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 26, "type": "#elif", "text": "#elif", "parent": 25, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 5}}, {"id": 27, "type": "binary_expression", "text": "PARAM==2", "parent": 25, "children": [28, 29, 30], "start_point": {"row": 6, "column": 6}, "end_point": {"row": 6, "column": 14}}, {"id": 28, "type": "identifier", "text": "PARAM", "parent": 27, "children": [], "start_point": {"row": 6, "column": 6}, "end_point": {"row": 6, "column": 11}}, {"id": 29, "type": "==", "text": "==", "parent": 27, "children": [], "start_point": {"row": 6, "column": 11}, "end_point": {"row": 6, "column": 13}}, {"id": 30, "type": "number_literal", "text": "2", "parent": 27, "children": [], "start_point": {"row": 6, "column": 13}, "end_point": {"row": 6, "column": 14}}, {"id": 31, "type": "\n", "text": "\n", "parent": 25, "children": [], "start_point": {"row": 6, "column": 15}, "end_point": {"row": 7, "column": 0}}, {"id": 32, "type": "preproc_def", "text": "#define SIZE\t50\r\n", "parent": 25, "children": [33, 34, 35], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 33, "type": "#define", "text": "#define", "parent": 32, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 7}}, {"id": 34, "type": "identifier", "text": "SIZE", "parent": 32, "children": [], "start_point": {"row": 7, "column": 8}, "end_point": {"row": 7, "column": 12}}, {"id": 35, "type": "preproc_arg", "text": "50\r", "parent": 32, "children": [], "start_point": {"row": 7, "column": 13}, "end_point": {"row": 7, "column": 16}}, {"id": 36, "type": "preproc_elif", "text": "#elif PARAM==3\r\n#define SIZE\t70\r\n#elif PARAM==4\r\n#define SIZE 90\t\r\n#elif PARAM==5\r\n#define SIZE\t110\r\n#else\r\n#error unknown PARAM\r\n", "parent": 25, "children": [37, 38, 42, 43, 47], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 37, "type": "#elif", "text": "#elif", "parent": 36, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 5}}, {"id": 38, "type": "binary_expression", "text": "PARAM==3", "parent": 36, "children": [39, 40, 41], "start_point": {"row": 8, "column": 6}, "end_point": {"row": 8, "column": 14}}, {"id": 39, "type": "identifier", "text": "PARAM", "parent": 38, "children": [], "start_point": {"row": 8, "column": 6}, "end_point": {"row": 8, "column": 11}}, {"id": 40, "type": "==", "text": "==", "parent": 38, "children": [], "start_point": {"row": 8, "column": 11}, "end_point": {"row": 8, "column": 13}}, {"id": 41, "type": "number_literal", "text": "3", "parent": 38, "children": [], "start_point": {"row": 8, "column": 13}, "end_point": {"row": 8, "column": 14}}, {"id": 42, "type": "\n", "text": "\n", "parent": 36, "children": [], "start_point": {"row": 8, "column": 15}, "end_point": {"row": 9, "column": 0}}, {"id": 43, "type": "preproc_def", "text": "#define SIZE\t70\r\n", "parent": 36, "children": [44, 45, 46], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 44, "type": "#define", "text": "#define", "parent": 43, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 7}}, {"id": 45, "type": "identifier", "text": "SIZE", "parent": 43, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 12}}, {"id": 46, "type": "preproc_arg", "text": "70\r", "parent": 43, "children": [], "start_point": {"row": 9, "column": 13}, "end_point": {"row": 9, "column": 16}}, {"id": 47, "type": "preproc_elif", "text": "#elif PARAM==4\r\n#define SIZE 90\t\r\n#elif PARAM==5\r\n#define SIZE\t110\r\n#else\r\n#error unknown PARAM\r\n", "parent": 36, "children": [48, 49, 53, 54, 58], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 48, "type": "#elif", "text": "#elif", "parent": 47, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 5}}, {"id": 49, "type": "binary_expression", "text": "PARAM==4", "parent": 47, "children": [50, 51, 52], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 14}}, {"id": 50, "type": "identifier", "text": "PARAM", "parent": 49, "children": [], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 11}}, {"id": 51, "type": "==", "text": "==", "parent": 49, "children": [], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 10, "column": 13}}, {"id": 52, "type": "number_literal", "text": "4", "parent": 49, "children": [], "start_point": {"row": 10, "column": 13}, "end_point": {"row": 10, "column": 14}}, {"id": 53, "type": "\n", "text": "\n", "parent": 47, "children": [], "start_point": {"row": 10, "column": 15}, "end_point": {"row": 11, "column": 0}}, {"id": 54, "type": "preproc_def", "text": "#define SIZE 90\t\r\n", "parent": 47, "children": [55, 56, 57], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 12, "column": 0}}, {"id": 55, "type": "#define", "text": "#define", "parent": 54, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 7}}, {"id": 56, "type": "identifier", "text": "SIZE", "parent": 54, "children": [], "start_point": {"row": 11, "column": 8}, "end_point": {"row": 11, "column": 12}}, {"id": 57, "type": "preproc_arg", "text": "90\t\r", "parent": 54, "children": [], "start_point": {"row": 11, "column": 14}, "end_point": {"row": 11, "column": 18}}, {"id": 58, "type": "preproc_elif", "text": "#elif PARAM==5\r\n#define SIZE\t110\r\n#else\r\n#error unknown PARAM\r\n", "parent": 47, "children": [59, 60, 64, 65, 69], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 59, "type": "#elif", "text": "#elif", "parent": 58, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 5}}, {"id": 60, "type": "binary_expression", "text": "PARAM==5", "parent": 58, "children": [61, 62, 63], "start_point": {"row": 12, "column": 6}, "end_point": {"row": 12, "column": 14}}, {"id": 61, "type": "identifier", "text": "PARAM", "parent": 60, "children": [], "start_point": {"row": 12, "column": 6}, "end_point": {"row": 12, "column": 11}}, {"id": 62, "type": "==", "text": "==", "parent": 60, "children": [], "start_point": {"row": 12, "column": 11}, "end_point": {"row": 12, "column": 13}}, {"id": 63, "type": "number_literal", "text": "5", "parent": 60, "children": [], "start_point": {"row": 12, "column": 13}, "end_point": {"row": 12, "column": 14}}, {"id": 64, "type": "\n", "text": "\n", "parent": 58, "children": [], "start_point": {"row": 12, "column": 15}, "end_point": {"row": 13, "column": 0}}, {"id": 65, "type": "preproc_def", "text": "#define SIZE\t110\r\n", "parent": 58, "children": [66, 67, 68], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 14, "column": 0}}, {"id": 66, "type": "#define", "text": "#define", "parent": 65, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 7}}, {"id": 67, "type": "identifier", "text": "SIZE", "parent": 65, "children": [], "start_point": {"row": 13, "column": 8}, "end_point": {"row": 13, "column": 12}}, {"id": 68, "type": "preproc_arg", "text": "110\r", "parent": 65, "children": [], "start_point": {"row": 13, "column": 13}, "end_point": {"row": 13, "column": 17}}, {"id": 69, "type": "preproc_else", "text": "#else\r\n#error unknown PARAM\r\n", "parent": 58, "children": [70, 71], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 70, "type": "#else", "text": "#else", "parent": 69, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 5}}, {"id": 71, "type": "preproc_call", "text": "#error unknown PARAM\r\n", "parent": 69, "children": [72, 73], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 72, "type": "preproc_directive", "text": "#error", "parent": 71, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 6}}, {"id": 73, "type": "preproc_arg", "text": "unknown PARAM\r", "parent": 71, "children": [], "start_point": {"row": 15, "column": 7}, "end_point": {"row": 15, "column": 21}}, {"id": 74, "type": "#endif", "text": "#endif", "parent": 3, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 6}}, {"id": 75, "type": "preproc_function_def", "text": "#define MAT(m, r, c)\t(m)[(r)*SIZE+(c)]\r\n", "parent": null, "children": [76, 77, 78, 82], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 19, "column": 0}}, {"id": 76, "type": "#define", "text": "#define", "parent": 75, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 7}}, {"id": 77, "type": "identifier", "text": "MAT", "parent": 75, "children": [], "start_point": {"row": 18, "column": 8}, "end_point": {"row": 18, "column": 11}}, {"id": 78, "type": "preproc_params", "text": "(m, r, c)", "parent": 75, "children": [79, 80, 81], "start_point": {"row": 18, "column": 11}, "end_point": {"row": 18, "column": 20}}, {"id": 79, "type": "identifier", "text": "m", "parent": 78, "children": [], "start_point": {"row": 18, "column": 12}, "end_point": {"row": 18, "column": 13}}, {"id": 80, "type": "identifier", "text": "r", "parent": 78, "children": [], "start_point": {"row": 18, "column": 15}, "end_point": {"row": 18, "column": 16}}, {"id": 81, "type": "identifier", "text": "c", "parent": 78, "children": [], "start_point": {"row": 18, "column": 18}, "end_point": {"row": 18, "column": 19}}, {"id": 82, "type": "preproc_arg", "text": "(m)[(r)*SIZE+(c)]\r", "parent": 75, "children": [], "start_point": {"row": 18, "column": 21}, "end_point": {"row": 18, "column": 39}}, {"id": 83, "type": "struct_specifier", "text": "struct Input {\r\n\tint a[SIZE*SIZE];\r\n\tint b[SIZE*SIZE];\r\n}", "parent": null, "children": [84, 85], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 23, "column": 1}}, {"id": 84, "type": "struct", "text": "struct", "parent": 83, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 6}}, {"id": 85, "type": "type_identifier", "text": "Input", "parent": 83, "children": [], "start_point": {"row": 20, "column": 7}, "end_point": {"row": 20, "column": 12}}, {"id": 86, "type": "field_declaration", "text": "int a[SIZE*SIZE];", "parent": 83, "children": [87, 88], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 18}}, {"id": 87, "type": "primitive_type", "text": "int", "parent": 86, "children": [], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 4}}, {"id": 88, "type": "array_declarator", "text": "a[SIZE*SIZE]", "parent": 86, "children": [89, 90], "start_point": {"row": 21, "column": 5}, "end_point": {"row": 21, "column": 17}}, {"id": 89, "type": "field_identifier", "text": "a", "parent": 88, "children": [], "start_point": {"row": 21, "column": 5}, "end_point": {"row": 21, "column": 6}}, {"id": 90, "type": "binary_expression", "text": "SIZE*SIZE", "parent": 88, "children": [91, 92, 93], "start_point": {"row": 21, "column": 7}, "end_point": {"row": 21, "column": 16}}, {"id": 91, "type": "identifier", "text": "SIZE", "parent": 90, "children": [], "start_point": {"row": 21, "column": 7}, "end_point": {"row": 21, "column": 11}}, {"id": 92, "type": "*", "text": "*", "parent": 90, "children": [], "start_point": {"row": 21, "column": 11}, "end_point": {"row": 21, "column": 12}}, {"id": 93, "type": "identifier", "text": "SIZE", "parent": 90, "children": [], "start_point": {"row": 21, "column": 12}, "end_point": {"row": 21, "column": 16}}, {"id": 94, "type": "field_declaration", "text": "int b[SIZE*SIZE];", "parent": 83, "children": [95, 96], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 18}}, {"id": 95, "type": "primitive_type", "text": "int", "parent": 94, "children": [], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 4}}, {"id": 96, "type": "array_declarator", "text": "b[SIZE*SIZE]", "parent": 94, "children": [97, 98], "start_point": {"row": 22, "column": 5}, "end_point": {"row": 22, "column": 17}}, {"id": 97, "type": "field_identifier", "text": "b", "parent": 96, "children": [], "start_point": {"row": 22, "column": 5}, "end_point": {"row": 22, "column": 6}}, {"id": 98, "type": "binary_expression", "text": "SIZE*SIZE", "parent": 96, "children": [99, 100, 101], "start_point": {"row": 22, "column": 7}, "end_point": {"row": 22, "column": 16}}, {"id": 99, "type": "identifier", "text": "SIZE", "parent": 98, "children": [], "start_point": {"row": 22, "column": 7}, "end_point": {"row": 22, "column": 11}}, {"id": 100, "type": "*", "text": "*", "parent": 98, "children": [], "start_point": {"row": 22, "column": 11}, "end_point": {"row": 22, "column": 12}}, {"id": 101, "type": "identifier", "text": "SIZE", "parent": 98, "children": [], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 16}}, {"id": 102, "type": "struct_specifier", "text": "struct Output {\r\n\tint r[SIZE*SIZE];\r\n}", "parent": null, "children": [103, 104], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 27, "column": 1}}, {"id": 103, "type": "struct", "text": "struct", "parent": 102, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 6}}, {"id": 104, "type": "type_identifier", "text": "Output", "parent": 102, "children": [], "start_point": {"row": 25, "column": 7}, "end_point": {"row": 25, "column": 13}}, {"id": 105, "type": "field_declaration", "text": "int r[SIZE*SIZE];", "parent": 102, "children": [106, 107], "start_point": {"row": 26, "column": 1}, "end_point": {"row": 26, "column": 18}}, {"id": 106, "type": "primitive_type", "text": "int", "parent": 105, "children": [], "start_point": {"row": 26, "column": 1}, "end_point": {"row": 26, "column": 4}}, {"id": 107, "type": "array_declarator", "text": "r[SIZE*SIZE]", "parent": 105, "children": [108, 109], "start_point": {"row": 26, "column": 5}, "end_point": {"row": 26, "column": 17}}, {"id": 108, "type": "field_identifier", "text": "r", "parent": 107, "children": [], "start_point": {"row": 26, "column": 5}, "end_point": {"row": 26, "column": 6}}, {"id": 109, "type": "binary_expression", "text": "SIZE*SIZE", "parent": 107, "children": [110, 111, 112], "start_point": {"row": 26, "column": 7}, "end_point": {"row": 26, "column": 16}}, {"id": 110, "type": "identifier", "text": "SIZE", "parent": 109, "children": [], "start_point": {"row": 26, "column": 7}, "end_point": {"row": 26, "column": 11}}, {"id": 111, "type": "*", "text": "*", "parent": 109, "children": [], "start_point": {"row": 26, "column": 11}, "end_point": {"row": 26, "column": 12}}, {"id": 112, "type": "identifier", "text": "SIZE", "parent": 109, "children": [], "start_point": {"row": 26, "column": 12}, "end_point": {"row": 26, "column": 16}}, {"id": 113, "type": "declaration", "text": "void outsource(struct Input *input, struct Output *output);", "parent": null, "children": [114, 115], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 59}}, {"id": 114, "type": "primitive_type", "text": "void", "parent": 113, "children": [], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 4}}, {"id": 115, "type": "function_declarator", "text": "outsource(struct Input *input, struct Output *output)", "parent": 113, "children": [116, 117], "start_point": {"row": 29, "column": 5}, "end_point": {"row": 29, "column": 58}}, {"id": 116, "type": "identifier", "text": "outsource", "parent": 115, "children": [], "start_point": {"row": 29, "column": 5}, "end_point": {"row": 29, "column": 14}}, {"id": 117, "type": "parameter_list", "text": "(struct Input *input, struct Output *output)", "parent": 115, "children": [118, 125], "start_point": {"row": 29, "column": 14}, "end_point": {"row": 29, "column": 58}}, {"id": 118, "type": "parameter_declaration", "text": "struct Input *input", "parent": 117, "children": [119, 122], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 34}}, {"id": 119, "type": "struct_specifier", "text": "struct Input", "parent": 118, "children": [120, 121], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 27}}, {"id": 120, "type": "struct", "text": "struct", "parent": 119, "children": [], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 21}}, {"id": 121, "type": "type_identifier", "text": "Input", "parent": 119, "children": [], "start_point": {"row": 29, "column": 22}, "end_point": {"row": 29, "column": 27}}, {"id": 122, "type": "pointer_declarator", "text": "*input", "parent": 118, "children": [123, 124], "start_point": {"row": 29, "column": 28}, "end_point": {"row": 29, "column": 34}}, {"id": 123, "type": "*", "text": "*", "parent": 122, "children": [], "start_point": {"row": 29, "column": 28}, "end_point": {"row": 29, "column": 29}}, {"id": 124, "type": "identifier", "text": "input", "parent": 122, "children": [], "start_point": {"row": 29, "column": 29}, "end_point": {"row": 29, "column": 34}}, {"id": 125, "type": "parameter_declaration", "text": "struct Output *output", "parent": 117, "children": [126, 129], "start_point": {"row": 29, "column": 36}, "end_point": {"row": 29, "column": 57}}, {"id": 126, "type": "struct_specifier", "text": "struct Output", "parent": 125, "children": [127, 128], "start_point": {"row": 29, "column": 36}, "end_point": {"row": 29, "column": 49}}, {"id": 127, "type": "struct", "text": "struct", "parent": 126, "children": [], "start_point": {"row": 29, "column": 36}, "end_point": {"row": 29, "column": 42}}, {"id": 128, "type": "type_identifier", "text": "Output", "parent": 126, "children": [], "start_point": {"row": 29, "column": 43}, "end_point": {"row": 29, "column": 49}}, {"id": 129, "type": "pointer_declarator", "text": "*output", "parent": 125, "children": [130, 131], "start_point": {"row": 29, "column": 50}, "end_point": {"row": 29, "column": 57}}, {"id": 130, "type": "*", "text": "*", "parent": 129, "children": [], "start_point": {"row": 29, "column": 50}, "end_point": {"row": 29, "column": 51}}, {"id": 131, "type": "identifier", "text": "output", "parent": 129, "children": [], "start_point": {"row": 29, "column": 51}, "end_point": {"row": 29, "column": 57}}]}, "node_categories": {"declarations": {"functions": [75, 115], "variables": [86, 94, 105, 113, 118, 125], "classes": [83, 84, 102, 103, 119, 120, 126, 127], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [5, 16, 27, 38, 49, 60, 90, 98, 109], "assignments": [], "loops": [], "conditionals": [3, 4, 6, 12, 14, 15, 17, 23, 25, 26, 28, 34, 36, 37, 39, 45, 47, 48, 50, 56, 58, 59, 61, 67, 74, 77, 79, 80, 81, 85, 89, 91, 93, 97, 99, 101, 104, 108, 110, 112, 116, 121, 124, 128, 131], "returns": [], "exceptions": []}, "expressions": {"calls": [0, 71], "literals": [8, 19, 30, 41, 52, 63], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 75, "universal_type": "function", "name": "unknown", "text_snippet": "#define MAT(m, r, c)\t(m)[(r)*SIZE+(c)]\r\n"}, {"node_id": 115, "universal_type": "function", "name": "Output", "text_snippet": "outsource(struct Input *input, struct Output *output)"}], "class_declarations": [{"node_id": 83, "universal_type": "class", "name": "Input", "text_snippet": "struct Input {\r\n\tint a[SIZE*SIZE];\r\n\tint b[SIZE*SIZE];\r\n}"}, {"node_id": 84, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 102, "universal_type": "class", "name": "Output", "text_snippet": "struct Output {\r\n\tint r[SIZE*SIZE];\r\n}"}, {"node_id": 103, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 119, "universal_type": "class", "name": "Input", "text_snippet": "struct Input"}, {"node_id": 120, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 126, "universal_type": "class", "name": "Output", "text_snippet": "struct Output"}, {"node_id": 127, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": []}, "original_source_code": "#pragma once\r\n\r\n#if PARAM==0\r\n#define SIZE\t4\r\n#elif PARAM==1\r\n#define SIZE\t30\r\n#elif PARAM==2\r\n#define SIZE\t50\r\n#elif PARAM==3\r\n#define SIZE\t70\r\n#elif PARAM==4\r\n#define SIZE 90\t\r\n#elif PARAM==5\r\n#define SIZE\t110\r\n#else\r\n#error unknown PARAM\r\n#endif\r\n\r\n#define MAT(m, r, c)\t(m)[(r)*SIZE+(c)]\r\n\r\nstruct Input {\r\n\tint a[SIZE*SIZE];\r\n\tint b[SIZE*SIZE];\r\n};\r\n\r\nstruct Output {\r\n\tint r[SIZE*SIZE];\r\n};\r\n\r\nvoid outsource(struct Input *input, struct Output *output);\r\n"}
80,519
c
// // MMarvel.h // Marvel Comics // // Created by <NAME> on 07/04/2018. // Copyright © 2018 <NAME>. All rights reserved. // #import <Foundation/Foundation.h> #import "JSON2Model.h" typedef NS_ENUM(NSInteger, MType) { MTypeComic, MTypeStory, MTypeEvent, MTypeSeries, MTypeCount }; @interface MMarvel : NSObject <JSON2Model> @property (nonatomic,assign) NSInteger mid; //available (int, optional): The number of total available events in this list. Will always be greater than or equal to the "returned" value., @property (nonatomic,assign) NSInteger available; //returned (int, optional): The number of events returned in this collection (up to 20)., @property (nonatomic,assign) NSInteger returned; //collectionURI (string, optional): The path to the full list of events in this collection., @property (nonatomic,copy) NSString *collectionURI; @property (nonatomic,copy) NSString *title; @property (nonatomic,copy) NSString *desc; + (NSString *)marvelTypeString:(MType)mtype; @end
32.53
30
(translation_unit) "//\n// MMarvel.h\n// Marvel Comics\n//\n// Created by <NAME> on 07/04/2018.\n// Copyright © 2018 <NAME>. All rights reserved.\n//\n#import <Foundation/Foundation.h>\n#import "JSON2Model.h"\n\ntypedef NS_ENUM(NSInteger, MType)\n{\n MTypeComic,\n MTypeStory,\n MTypeEvent,\n MTypeSeries,\n MTypeCount\n};\n\n@interface MMarvel : NSObject <JSON2Model>\n@property (nonatomic,assign) NSInteger mid;\n//available (int, optional): The number of total available events in this list. Will always be greater than or equal to the "returned" value.,\n@property (nonatomic,assign) NSInteger available;\n//returned (int, optional): The number of events returned in this collection (up to 20).,\n@property (nonatomic,assign) NSInteger returned;\n//collectionURI (string, optional): The path to the full list of events in this collection.,\n@property (nonatomic,copy) NSString *collectionURI;\n@property (nonatomic,copy) NSString *title;\n@property (nonatomic,copy) NSString *desc;\n\n+ (NSString *)marvelTypeString:(MType)mtype;\n\n\n@end\n" (comment) "//" (comment) "// MMarvel.h" (comment) "// Marvel Comics" (comment) "//" (comment) "// Created by <NAME> on 07/04/2018." (comment) "// Copyright © 2018 <NAME>. All rights reserved.\n" (comment) "/\n" (preproc_call) "import <Foundation/Foundation.h>\n#" (preproc_directive) "import " (preproc_arg) "Foundation/Foundation.h>\n" (preproc_call) "import "JSON2Model.h"\n\n" (preproc_directive) "import " (preproc_arg) "JSON2Model.h"\n" (type_definition) "ypedef NS_ENUM(NSInteger, MType)\n{\n MTypeComic,\n MTypeStory,\n MTypeEvent,\n MTypeSeries,\n MTypeCount\n};\n" (typedef) "ypedef " (macro_type_specifier) "S_ENUM(NSInteger, MType)\n" (identifier) "S_ENUM(" (() "N" (type_descriptor) "SInteger," (type_identifier) "SInteger," (ERROR) " MType)" (,) " " (identifier) "Type)" ()) "\n" (ERROR) "\n" ({) "\n" (type_identifier) "TypeComic," (,) "\n" (type_identifier) "TypeStory," (,) "\n" (type_identifier) "TypeEvent," (,) "\n" (type_identifier) "TypeSeries," (,) "\n" (type_identifier) "TypeCount\n" (ERROR) ";" (}) ";" (;) "\n" (ERROR) "interface MMarvel : NSObject <JSON2Model>\n@property (nonatomic,assign) NSInteger mid;\n//available (int, optional): The number of total available events in this list. Will always be greater than or equal to the "returned" value.,\n@property (nonatomic,assign) NSInteger available;\n//returned (int, optional): The number of events returned in this collection (up to 20).,\n@property (nonatomic,assign) NSInteger returned;\n//collectionURI (string, optional): The path to the full list of events in this collection.,\n@property (nonatomic,copy) NSString *collectionURI;\n@property (nonatomic,copy) NSString *title;\n@property (nonatomic,copy) NSString *desc;\n\n+ (NSString *)marvelTypeString:(MType)mtype;\n\n\n@end\n" (ERROR) "i" (type_identifier) "nterface " (ERROR) "Marvel : NSObject <JSON2Model>\n@p" (identifier) "Marvel " (:) " " (identifier) "SObject " (<) "J" (identifier) "SON2Model>" (>) "\n" (ERROR) "p" (function_declarator) "roperty (nonatomic,assign) " (identifier) "roperty " (parameter_list) "nonatomic,assign) " (() "n" (identifier) "onatomic," (,) "a" (identifier) "ssign)" ()) " " (declaration) "SInteger mid;\n" (type_identifier) "SInteger " (identifier) "id;" (;) "\n" (comment) "/available (int, optional): The number of total available events in this list. Will always be greater than or equal to the "returned" value.,\n" (ERROR) "p" (ERROR) "p" (declaration) "roperty (nonatomic,assign) NSInteger available;\n" (macro_type_specifier) "roperty (nonatomic,assign) " (identifier) "roperty " (() "n" (type_descriptor) "onatomic," (type_identifier) "onatomic," (ERROR) "assign)" (,) "a" (identifier) "ssign)" ()) " " (ERROR) "SInteger " (identifier) "SInteger " (identifier) "vailable;" (;) "\n" (comment) "/returned (int, optional): The number of events returned in this collection (up to 20).,\n" (ERROR) "p" (ERROR) "p" (declaration) "roperty (nonatomic,assign) NSInteger returned;\n" (macro_type_specifier) "roperty (nonatomic,assign) " (identifier) "roperty " (() "n" (type_descriptor) "onatomic," (type_identifier) "onatomic," (ERROR) "assign)" (,) "a" (identifier) "ssign)" ()) " " (identifier) "SInteger " (ERROR) "eturned;" (identifier) "eturned;" (;) "\n" (comment) "/collectionURI (string, optional): The path to the full list of events in this collection.,\n" (ERROR) "p" (ERROR) "p" (declaration) "roperty (nonatomic,copy) NSString *collectionURI;\n" (macro_type_specifier) "roperty (nonatomic,copy) " (identifier) "roperty " (() "n" (type_descriptor) "onatomic," (type_identifier) "onatomic," (ERROR) "copy)" (,) "c" (identifier) "opy)" ()) " " (ERROR) "SString " (identifier) "SString " (pointer_declarator) "collectionURI;" (*) "c" (identifier) "ollectionURI;" (;) "\n" (ERROR) "p" (ERROR) "p" (declaration) "roperty (nonatomic,copy) NSString *title;\n" (macro_type_specifier) "roperty (nonatomic,copy) " (identifier) "roperty " (() "n" (type_descriptor) "onatomic," (type_identifier) "onatomic," (ERROR) "copy)" (,) "c" (identifier) "opy)" ()) " " (ERROR) "SString " (identifier) "SString " (pointer_declarator) "title;" (*) "t" (identifier) "itle;" (;) "\n" (ERROR) "p" (ERROR) "p" (declaration) "roperty (nonatomic,copy) NSString *desc;\n" (macro_type_specifier) "roperty (nonatomic,copy) " (identifier) "roperty " (() "n" (type_descriptor) "onatomic," (type_identifier) "onatomic," (ERROR) "copy)" (,) "c" (identifier) "opy)" ()) " " (ERROR) "SString " (identifier) "SString " (pointer_declarator) "desc;" (*) "d" (identifier) "esc;" (;) "\n" (ERROR) " (N" (+) " " (() "N" (declaration) "SString *)marvelTypeString:(MType)mtype;\n" (type_identifier) "SString " (pointer_declarator) ")marvelTypeString:(MType)" (*) ")" (ERROR) "marvelTypeString:(M" ()) "m" (identifier) "arvelTypeString:" (:) "(" (() "M" (identifier) "Type)" (ERROR) "mtype;" ()) "m" (identifier) "type;" (;) "\n" (ERROR) "e" (ERROR) "e" (identifier) "nd\n"
171
32
{"language": "c", "success": true, "metadata": {"lines": 30, "avg_line_length": 32.53, "nodes": 115, "errors": 0, "source_hash": "d7f5adc66e77c38d7053825e7e71eb4a9b1cb62187b28392e8210f5d0b2369bc", "categorized_nodes": 64}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "import <Foundation/Foundation.h>\n#", "parent": null, "children": [1], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 1, "type": "preproc_arg", "text": "Foundation/Foundation.h>\n", "parent": 0, "children": [], "start_point": {"row": 7, "column": 8}, "end_point": {"row": 7, "column": 33}}, {"id": 2, "type": "preproc_call", "text": "import \"JSON2Model.h\"\n\n", "parent": null, "children": [3], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 3, "type": "preproc_arg", "text": "JSON2Model.h\"\n", "parent": 2, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 22}}, {"id": 4, "type": "type_definition", "text": "ypedef NS_ENUM(NSInteger, MType)\n{\n MTypeComic,\n MTypeStory,\n MTypeEvent,\n MTypeSeries,\n MTypeCount\n};\n", "parent": null, "children": [5, 6, 12, 13, 14, 15, 16, 17], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 17, "column": 2}}, {"id": 5, "type": "typedef", "text": "ypedef ", "parent": 4, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 7}}, {"id": 6, "type": "macro_type_specifier", "text": "S_ENUM(NSInteger, MType)\n", "parent": 4, "children": [7, 8, 10], "start_point": {"row": 10, "column": 8}, "end_point": {"row": 10, "column": 33}}, {"id": 7, "type": "identifier", "text": "S_ENUM(", "parent": 6, "children": [], "start_point": {"row": 10, "column": 8}, "end_point": {"row": 10, "column": 15}}, {"id": 8, "type": "type_descriptor", "text": "SInteger,", "parent": 6, "children": [9], "start_point": {"row": 10, "column": 16}, "end_point": {"row": 10, "column": 25}}, {"id": 9, "type": "type_identifier", "text": "SInteger,", "parent": 8, "children": [], "start_point": {"row": 10, "column": 16}, "end_point": {"row": 10, "column": 25}}, {"id": 10, "type": "ERROR", "text": " MType)", "parent": 6, "children": [11], "start_point": {"row": 10, "column": 25}, "end_point": {"row": 10, "column": 32}}, {"id": 11, "type": "identifier", "text": "Type)", "parent": 10, "children": [], "start_point": {"row": 10, "column": 27}, "end_point": {"row": 10, "column": 32}}, {"id": 12, "type": "ERROR", "text": "\n", "parent": 4, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 1}}, {"id": 13, "type": "type_identifier", "text": "TypeComic,", "parent": 4, "children": [], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 14}}, {"id": 14, "type": "type_identifier", "text": "TypeStory,", "parent": 4, "children": [], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 14}}, {"id": 15, "type": "type_identifier", "text": "TypeEvent,", "parent": 4, "children": [], "start_point": {"row": 14, "column": 4}, "end_point": {"row": 14, "column": 14}}, {"id": 16, "type": "type_identifier", "text": "TypeSeries,", "parent": 4, "children": [], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 15}}, {"id": 17, "type": "type_identifier", "text": "TypeCount\n", "parent": 4, "children": [], "start_point": {"row": 16, "column": 4}, "end_point": {"row": 16, "column": 14}}, {"id": 18, "type": "ERROR", "text": "interface MMarvel : NSObject <JSON2Model>\n@property (nonatomic,assign) NSInteger mid;\n//available (int, optional): The number of total available events in this list. Will always be greater than or equal to the \"returned\" value.,\n@property (nonatomic,assign) NSInteger available;\n//returned (int, optional): The number of events returned in this collection (up to 20).,\n@property (nonatomic,assign) NSInteger returned;\n//collectionURI (string, optional): The path to the full list of events in this collection.,\n@property (nonatomic,copy) NSString *collectionURI;\n@property (nonatomic,copy) NSString *title;\n@property (nonatomic,copy) NSString *desc;\n\n+ (NSString *)marvelTypeString:(MType)mtype;\n\n\n@end\n", "parent": null, "children": [19, 20, 21, 28, 33, 36, 38, 48, 50, 60, 62, 74, 76, 88, 90, 102, 104, 112, 114], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 33, "column": 4}}, {"id": 19, "type": "ERROR", "text": "i", "parent": 18, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 1}}, {"id": 20, "type": "type_identifier", "text": "nterface ", "parent": 18, "children": [], "start_point": {"row": 19, "column": 1}, "end_point": {"row": 19, "column": 10}}, {"id": 21, "type": "ERROR", "text": "Marvel : NSObject <JSON2Model>\n@p", "parent": 18, "children": [22, 23, 24, 25, 26, 27], "start_point": {"row": 19, "column": 11}, "end_point": {"row": 20, "column": 1}}, {"id": 22, "type": "identifier", "text": "Marvel ", "parent": 21, "children": [], "start_point": {"row": 19, "column": 11}, "end_point": {"row": 19, "column": 18}}, {"id": 23, "type": "identifier", "text": "SObject ", "parent": 21, "children": [], "start_point": {"row": 19, "column": 21}, "end_point": {"row": 19, "column": 29}}, {"id": 24, "type": "<", "text": "J", "parent": 21, "children": [], "start_point": {"row": 19, "column": 30}, "end_point": {"row": 19, "column": 31}}, {"id": 25, "type": "identifier", "text": "SON2Model>", "parent": 21, "children": [], "start_point": {"row": 19, "column": 31}, "end_point": {"row": 19, "column": 41}}, {"id": 26, "type": ">", "text": "\n", "parent": 21, "children": [], "start_point": {"row": 19, "column": 41}, "end_point": {"row": 19, "column": 42}}, {"id": 27, "type": "ERROR", "text": "p", "parent": 21, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 1}}, {"id": 28, "type": "function_declarator", "text": "roperty (nonatomic,assign) ", "parent": 18, "children": [29, 30], "start_point": {"row": 20, "column": 1}, "end_point": {"row": 20, "column": 28}}, {"id": 29, "type": "identifier", "text": "roperty ", "parent": 28, "children": [], "start_point": {"row": 20, "column": 1}, "end_point": {"row": 20, "column": 9}}, {"id": 30, "type": "parameter_list", "text": "nonatomic,assign) ", "parent": 28, "children": [31, 32], "start_point": {"row": 20, "column": 10}, "end_point": {"row": 20, "column": 28}}, {"id": 31, "type": "identifier", "text": "onatomic,", "parent": 30, "children": [], "start_point": {"row": 20, "column": 11}, "end_point": {"row": 20, "column": 20}}, {"id": 32, "type": "identifier", "text": "ssign)", "parent": 30, "children": [], "start_point": {"row": 20, "column": 21}, "end_point": {"row": 20, "column": 27}}, {"id": 33, "type": "declaration", "text": "SInteger mid;\n", "parent": 18, "children": [34, 35], "start_point": {"row": 20, "column": 29}, "end_point": {"row": 20, "column": 43}}, {"id": 34, "type": "type_identifier", "text": "SInteger ", "parent": 33, "children": [], "start_point": {"row": 20, "column": 29}, "end_point": {"row": 20, "column": 38}}, {"id": 35, "type": "identifier", "text": "id;", "parent": 33, "children": [], "start_point": {"row": 20, "column": 39}, "end_point": {"row": 20, "column": 42}}, {"id": 36, "type": "ERROR", "text": "p", "parent": 18, "children": [37], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 1}}, {"id": 37, "type": "ERROR", "text": "p", "parent": 36, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 1}}, {"id": 38, "type": "declaration", "text": "roperty (nonatomic,assign) NSInteger available;\n", "parent": 18, "children": [39, 45, 47], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 49}}, {"id": 39, "type": "macro_type_specifier", "text": "roperty (nonatomic,assign) ", "parent": 38, "children": [40, 41, 43], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 28}}, {"id": 40, "type": "identifier", "text": "roperty ", "parent": 39, "children": [], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 9}}, {"id": 41, "type": "type_descriptor", "text": "onatomic,", "parent": 39, "children": [42], "start_point": {"row": 22, "column": 11}, "end_point": {"row": 22, "column": 20}}, {"id": 42, "type": "type_identifier", "text": "onatomic,", "parent": 41, "children": [], "start_point": {"row": 22, "column": 11}, "end_point": {"row": 22, "column": 20}}, {"id": 43, "type": "ERROR", "text": "assign)", "parent": 39, "children": [44], "start_point": {"row": 22, "column": 20}, "end_point": {"row": 22, "column": 27}}, {"id": 44, "type": "identifier", "text": "ssign)", "parent": 43, "children": [], "start_point": {"row": 22, "column": 21}, "end_point": {"row": 22, "column": 27}}, {"id": 45, "type": "ERROR", "text": "SInteger ", "parent": 38, "children": [46], "start_point": {"row": 22, "column": 29}, "end_point": {"row": 22, "column": 38}}, {"id": 46, "type": "identifier", "text": "SInteger ", "parent": 45, "children": [], "start_point": {"row": 22, "column": 29}, "end_point": {"row": 22, "column": 38}}, {"id": 47, "type": "identifier", "text": "vailable;", "parent": 38, "children": [], "start_point": {"row": 22, "column": 39}, "end_point": {"row": 22, "column": 48}}, {"id": 48, "type": "ERROR", "text": "p", "parent": 18, "children": [49], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 1}}, {"id": 49, "type": "ERROR", "text": "p", "parent": 48, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 1}}, {"id": 50, "type": "declaration", "text": "roperty (nonatomic,assign) NSInteger returned;\n", "parent": 18, "children": [51, 57, 58], "start_point": {"row": 24, "column": 1}, "end_point": {"row": 24, "column": 48}}, {"id": 51, "type": "macro_type_specifier", "text": "roperty (nonatomic,assign) ", "parent": 50, "children": [52, 53, 55], "start_point": {"row": 24, "column": 1}, "end_point": {"row": 24, "column": 28}}, {"id": 52, "type": "identifier", "text": "roperty ", "parent": 51, "children": [], "start_point": {"row": 24, "column": 1}, "end_point": {"row": 24, "column": 9}}, {"id": 53, "type": "type_descriptor", "text": "onatomic,", "parent": 51, "children": [54], "start_point": {"row": 24, "column": 11}, "end_point": {"row": 24, "column": 20}}, {"id": 54, "type": "type_identifier", "text": "onatomic,", "parent": 53, "children": [], "start_point": {"row": 24, "column": 11}, "end_point": {"row": 24, "column": 20}}, {"id": 55, "type": "ERROR", "text": "assign)", "parent": 51, "children": [56], "start_point": {"row": 24, "column": 20}, "end_point": {"row": 24, "column": 27}}, {"id": 56, "type": "identifier", "text": "ssign)", "parent": 55, "children": [], "start_point": {"row": 24, "column": 21}, "end_point": {"row": 24, "column": 27}}, {"id": 57, "type": "identifier", "text": "SInteger ", "parent": 50, "children": [], "start_point": {"row": 24, "column": 29}, "end_point": {"row": 24, "column": 38}}, {"id": 58, "type": "ERROR", "text": "eturned;", "parent": 50, "children": [59], "start_point": {"row": 24, "column": 39}, "end_point": {"row": 24, "column": 47}}, {"id": 59, "type": "identifier", "text": "eturned;", "parent": 58, "children": [], "start_point": {"row": 24, "column": 39}, "end_point": {"row": 24, "column": 47}}, {"id": 60, "type": "ERROR", "text": "p", "parent": 18, "children": [61], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 1}}, {"id": 61, "type": "ERROR", "text": "p", "parent": 60, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 1}}, {"id": 62, "type": "declaration", "text": "roperty (nonatomic,copy) NSString *collectionURI;\n", "parent": 18, "children": [63, 69, 71], "start_point": {"row": 26, "column": 1}, "end_point": {"row": 26, "column": 51}}, {"id": 63, "type": "macro_type_specifier", "text": "roperty (nonatomic,copy) ", "parent": 62, "children": [64, 65, 67], "start_point": {"row": 26, "column": 1}, "end_point": {"row": 26, "column": 26}}, {"id": 64, "type": "identifier", "text": "roperty ", "parent": 63, "children": [], "start_point": {"row": 26, "column": 1}, "end_point": {"row": 26, "column": 9}}, {"id": 65, "type": "type_descriptor", "text": "onatomic,", "parent": 63, "children": [66], "start_point": {"row": 26, "column": 11}, "end_point": {"row": 26, "column": 20}}, {"id": 66, "type": "type_identifier", "text": "onatomic,", "parent": 65, "children": [], "start_point": {"row": 26, "column": 11}, "end_point": {"row": 26, "column": 20}}, {"id": 67, "type": "ERROR", "text": "copy)", "parent": 63, "children": [68], "start_point": {"row": 26, "column": 20}, "end_point": {"row": 26, "column": 25}}, {"id": 68, "type": "identifier", "text": "opy)", "parent": 67, "children": [], "start_point": {"row": 26, "column": 21}, "end_point": {"row": 26, "column": 25}}, {"id": 69, "type": "ERROR", "text": "SString ", "parent": 62, "children": [70], "start_point": {"row": 26, "column": 27}, "end_point": {"row": 26, "column": 35}}, {"id": 70, "type": "identifier", "text": "SString ", "parent": 69, "children": [], "start_point": {"row": 26, "column": 27}, "end_point": {"row": 26, "column": 35}}, {"id": 71, "type": "pointer_declarator", "text": "collectionURI;", "parent": 62, "children": [72, 73], "start_point": {"row": 26, "column": 36}, "end_point": {"row": 26, "column": 50}}, {"id": 72, "type": "*", "text": "c", "parent": 71, "children": [], "start_point": {"row": 26, "column": 36}, "end_point": {"row": 26, "column": 37}}, {"id": 73, "type": "identifier", "text": "ollectionURI;", "parent": 71, "children": [], "start_point": {"row": 26, "column": 37}, "end_point": {"row": 26, "column": 50}}, {"id": 74, "type": "ERROR", "text": "p", "parent": 18, "children": [75], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 1}}, {"id": 75, "type": "ERROR", "text": "p", "parent": 74, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 1}}, {"id": 76, "type": "declaration", "text": "roperty (nonatomic,copy) NSString *title;\n", "parent": 18, "children": [77, 83, 85], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 43}}, {"id": 77, "type": "macro_type_specifier", "text": "roperty (nonatomic,copy) ", "parent": 76, "children": [78, 79, 81], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 26}}, {"id": 78, "type": "identifier", "text": "roperty ", "parent": 77, "children": [], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 9}}, {"id": 79, "type": "type_descriptor", "text": "onatomic,", "parent": 77, "children": [80], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 20}}, {"id": 80, "type": "type_identifier", "text": "onatomic,", "parent": 79, "children": [], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 20}}, {"id": 81, "type": "ERROR", "text": "copy)", "parent": 77, "children": [82], "start_point": {"row": 27, "column": 20}, "end_point": {"row": 27, "column": 25}}, {"id": 82, "type": "identifier", "text": "opy)", "parent": 81, "children": [], "start_point": {"row": 27, "column": 21}, "end_point": {"row": 27, "column": 25}}, {"id": 83, "type": "ERROR", "text": "SString ", "parent": 76, "children": [84], "start_point": {"row": 27, "column": 27}, "end_point": {"row": 27, "column": 35}}, {"id": 84, "type": "identifier", "text": "SString ", "parent": 83, "children": [], "start_point": {"row": 27, "column": 27}, "end_point": {"row": 27, "column": 35}}, {"id": 85, "type": "pointer_declarator", "text": "title;", "parent": 76, "children": [86, 87], "start_point": {"row": 27, "column": 36}, "end_point": {"row": 27, "column": 42}}, {"id": 86, "type": "*", "text": "t", "parent": 85, "children": [], "start_point": {"row": 27, "column": 36}, "end_point": {"row": 27, "column": 37}}, {"id": 87, "type": "identifier", "text": "itle;", "parent": 85, "children": [], "start_point": {"row": 27, "column": 37}, "end_point": {"row": 27, "column": 42}}, {"id": 88, "type": "ERROR", "text": "p", "parent": 18, "children": [89], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 1}}, {"id": 89, "type": "ERROR", "text": "p", "parent": 88, "children": [], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 1}}, {"id": 90, "type": "declaration", "text": "roperty (nonatomic,copy) NSString *desc;\n", "parent": 18, "children": [91, 97, 99], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 28, "column": 42}}, {"id": 91, "type": "macro_type_specifier", "text": "roperty (nonatomic,copy) ", "parent": 90, "children": [92, 93, 95], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 28, "column": 26}}, {"id": 92, "type": "identifier", "text": "roperty ", "parent": 91, "children": [], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 28, "column": 9}}, {"id": 93, "type": "type_descriptor", "text": "onatomic,", "parent": 91, "children": [94], "start_point": {"row": 28, "column": 11}, "end_point": {"row": 28, "column": 20}}, {"id": 94, "type": "type_identifier", "text": "onatomic,", "parent": 93, "children": [], "start_point": {"row": 28, "column": 11}, "end_point": {"row": 28, "column": 20}}, {"id": 95, "type": "ERROR", "text": "copy)", "parent": 91, "children": [96], "start_point": {"row": 28, "column": 20}, "end_point": {"row": 28, "column": 25}}, {"id": 96, "type": "identifier", "text": "opy)", "parent": 95, "children": [], "start_point": {"row": 28, "column": 21}, "end_point": {"row": 28, "column": 25}}, {"id": 97, "type": "ERROR", "text": "SString ", "parent": 90, "children": [98], "start_point": {"row": 28, "column": 27}, "end_point": {"row": 28, "column": 35}}, {"id": 98, "type": "identifier", "text": "SString ", "parent": 97, "children": [], "start_point": {"row": 28, "column": 27}, "end_point": {"row": 28, "column": 35}}, {"id": 99, "type": "pointer_declarator", "text": "desc;", "parent": 90, "children": [100, 101], "start_point": {"row": 28, "column": 36}, "end_point": {"row": 28, "column": 41}}, {"id": 100, "type": "*", "text": "d", "parent": 99, "children": [], "start_point": {"row": 28, "column": 36}, "end_point": {"row": 28, "column": 37}}, {"id": 101, "type": "identifier", "text": "esc;", "parent": 99, "children": [], "start_point": {"row": 28, "column": 37}, "end_point": {"row": 28, "column": 41}}, {"id": 102, "type": "ERROR", "text": " (N", "parent": 18, "children": [103], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 3}}, {"id": 103, "type": "+", "text": " ", "parent": 102, "children": [], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 1}}, {"id": 104, "type": "declaration", "text": "SString *)marvelTypeString:(MType)mtype;\n", "parent": 18, "children": [105, 106, 110], "start_point": {"row": 30, "column": 3}, "end_point": {"row": 30, "column": 44}}, {"id": 105, "type": "type_identifier", "text": "SString ", "parent": 104, "children": [], "start_point": {"row": 30, "column": 3}, "end_point": {"row": 30, "column": 11}}, {"id": 106, "type": "pointer_declarator", "text": ")marvelTypeString:(MType)", "parent": 104, "children": [107, 109], "start_point": {"row": 30, "column": 12}, "end_point": {"row": 30, "column": 37}}, {"id": 107, "type": "ERROR", "text": "marvelTypeString:(M", "parent": 106, "children": [108], "start_point": {"row": 30, "column": 13}, "end_point": {"row": 30, "column": 32}}, {"id": 108, "type": "identifier", "text": "arvelTypeString:", "parent": 107, "children": [], "start_point": {"row": 30, "column": 14}, "end_point": {"row": 30, "column": 30}}, {"id": 109, "type": "identifier", "text": "Type)", "parent": 106, "children": [], "start_point": {"row": 30, "column": 32}, "end_point": {"row": 30, "column": 37}}, {"id": 110, "type": "ERROR", "text": "mtype;", "parent": 104, "children": [111], "start_point": {"row": 30, "column": 37}, "end_point": {"row": 30, "column": 43}}, {"id": 111, "type": "identifier", "text": "type;", "parent": 110, "children": [], "start_point": {"row": 30, "column": 38}, "end_point": {"row": 30, "column": 43}}, {"id": 112, "type": "ERROR", "text": "e", "parent": 18, "children": [113], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 33, "column": 1}}, {"id": 113, "type": "ERROR", "text": "e", "parent": 112, "children": [], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 33, "column": 1}}, {"id": 114, "type": "identifier", "text": "nd\n", "parent": 18, "children": [], "start_point": {"row": 33, "column": 1}, "end_point": {"row": 33, "column": 4}}]}, "node_categories": {"declarations": {"functions": [28], "variables": [4, 33, 38, 50, 62, 76, 90, 104], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [6, 7, 9, 11, 13, 14, 15, 16, 17, 20, 22, 23, 25, 29, 31, 32, 34, 35, 39, 40, 42, 44, 46, 47, 51, 52, 54, 56, 57, 59, 63, 64, 66, 68, 70, 73, 77, 78, 80, 82, 84, 87, 91, 92, 94, 96, 98, 101, 105, 108, 109, 111, 114], "returns": [], "exceptions": []}, "expressions": {"calls": [0, 2], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 28, "universal_type": "function", "name": "unknown", "text_snippet": "roperty (nonatomic,assign) "}], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// MMarvel.h\n// Marvel Comics\n//\n// Created by <NAME> on 07/04/2018.\n// Copyright \u00a9 2018 <NAME>. All rights reserved.\n//\n#import <Foundation/Foundation.h>\n#import \"JSON2Model.h\"\n\ntypedef NS_ENUM(NSInteger, MType)\n{\n MTypeComic,\n MTypeStory,\n MTypeEvent,\n MTypeSeries,\n MTypeCount\n};\n\n@interface MMarvel : NSObject <JSON2Model>\n@property (nonatomic,assign) NSInteger mid;\n//available (int, optional): The number of total available events in this list. Will always be greater than or equal to the \"returned\" value.,\n@property (nonatomic,assign) NSInteger available;\n//returned (int, optional): The number of events returned in this collection (up to 20).,\n@property (nonatomic,assign) NSInteger returned;\n//collectionURI (string, optional): The path to the full list of events in this collection.,\n@property (nonatomic,copy) NSString *collectionURI;\n@property (nonatomic,copy) NSString *title;\n@property (nonatomic,copy) NSString *desc;\n\n+ (NSString *)marvelTypeString:(MType)mtype;\n\n\n@end\n"}
80,520
c
/** * Written in 2014 by <NAME> (<EMAIL>) * * To the extent possible under law, the author has dedicated all copyright * and related and neighboring rights to this software to the public domain * worldwide. This software is distributed without any warranty. * * See <http://creativecommons.org/publicdomain/zero/1.0/>. * * This is a fast, top-quality generator. If 1024 bits of state are too much, try a xoroshiro128+ generator. Note that the three lowest bits of this generator are LSFRs, and thus they are slightly less random than the other bits. We suggest to use a sign test to extract a random Boolean value. The state must be seeded so that it is not everywhere zero. If you have a 64-bit seed, we suggest to seed a splitmix64 generator and use its output to fill s. */ #pragma once // --------------------------------------------------------- #include <stdint.h> #include <string.h> #include <fcntl.h> #include <stdio.h> #include <stdlib.h> #include <sys/stat.h> #include <sys/types.h> #include <unistd.h> // --------------------------------------------------------- namespace utils { // --------------------------------------------------------- typedef struct { uint64_t s[16]; int p; } xorshift_prng_ctx_t; // --------------------------------------------------------- void get_random_bytes_from_dev_urandom(uint8_t* data, size_t num_bytes) { int gathered_bytes = open("/dev/urandom", O_RDONLY); size_t len = 0; while (len < num_bytes) { ssize_t num_gathered_bytes = read( gathered_bytes, data + len, num_bytes - len ); if (num_gathered_bytes < 0) { puts("Error, unable to read stream"); close(gathered_bytes); exit(EXIT_FAILURE); } else { len += num_gathered_bytes; } } close(gathered_bytes); } // --------------------------------------------------------- void xorshift1024_init(xorshift_prng_ctx_t* ctx) { const size_t num_bytes = 16 * sizeof(uint64_t); get_random_bytes_from_dev_urandom((uint8_t*)(ctx->s), num_bytes); ctx->p = 0; } // --------------------------------------------------------- uint64_t xorshift1024_next(xorshift_prng_ctx_t* ctx) { const uint64_t s0 = ctx->s[ctx->p]; uint64_t s1 = ctx->s[ctx->p = (ctx->p + 1) & 15]; s1 ^= s1 << 31; // a ctx->s[ctx->p] = s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30); // b,c return ctx->s[ctx->p] * UINT64_C(1181783497276652981); } // --------------------------------------------------------- void get_random_bytes(xorshift_prng_ctx_t *ctx, uint8_t* data, const size_t num_bytes) { const size_t wordsize = sizeof(uint64_t); const size_t num_words = num_bytes / wordsize; for (size_t i = 0; i < num_words; ++i) { const uint64_t word = xorshift1024_next(ctx); memcpy(data + i * wordsize, &word, wordsize); } const size_t num_bytes_remaining = num_bytes - num_words * wordsize; if (num_bytes_remaining > 0) { const uint64_t word = xorshift1024_next(ctx); memcpy(data + num_words * wordsize, &word, num_bytes_remaining); } } // --------------------------------------------------------- void get_random_bytes(uint8_t* data, const size_t num_bytes) { xorshift_prng_ctx_t ctx; xorshift1024_init(&ctx); get_random_bytes(&ctx, data, num_bytes); } } // namespace utils
36.31
93
(translation_unit) "/**\n * Written in 2014 by <NAME> (<EMAIL>)\n *\n * To the extent possible under law, the author has dedicated all copyright\n * and related and neighboring rights to this software to the public domain\n * worldwide. This software is distributed without any warranty.\n * \n * See <http://creativecommons.org/publicdomain/zero/1.0/>. \n * \n * This is a fast, top-quality generator. If 1024 bits of state are too\n much, try a xoroshiro128+ generator.\n\n Note that the three lowest bits of this generator are LSFRs, and thus\n they are slightly less random than the other bits. We suggest to use a\n sign test to extract a random Boolean value.\n\n The state must be seeded so that it is not everywhere zero. If you have\n a 64-bit seed, we suggest to seed a splitmix64 generator and use its\n output to fill s.\n */\n\n#pragma once\n\n// ---------------------------------------------------------\n\n#include <stdint.h>\n#include <string.h>\n\n#include <fcntl.h>\n#include <stdio.h>\n#include <stdlib.h>\n#include <sys/stat.h>\n#include <sys/types.h>\n#include <unistd.h>\n\n// ---------------------------------------------------------\n\nnamespace utils {\n// ---------------------------------------------------------\n\ntypedef struct {\n uint64_t s[16]; \n int p;\n} xorshift_prng_ctx_t;\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes_from_dev_urandom(uint8_t* data, size_t num_bytes) {\n int gathered_bytes = open("/dev/urandom", O_RDONLY);\n size_t len = 0;\n\n while (len < num_bytes) {\n ssize_t num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n );\n\n if (num_gathered_bytes < 0) {\n puts("Error, unable to read stream");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n } else {\n len += num_gathered_bytes;\n }\n }\n\n close(gathered_bytes);\n}\n\n// ---------------------------------------------------------\n\nvoid xorshift1024_init(xorshift_prng_ctx_t* ctx) {\n const size_t num_bytes = 16 * sizeof(uint64_t);\n get_random_bytes_from_dev_urandom((uint8_t*)(ctx->s), num_bytes);\n ctx->p = 0;\n}\n\n// ---------------------------------------------------------\n\nuint64_t xorshift1024_next(xorshift_prng_ctx_t* ctx) {\n const uint64_t s0 = ctx->s[ctx->p];\n uint64_t s1 = ctx->s[ctx->p = (ctx->p + 1) & 15];\n s1 ^= s1 << 31; // a\n ctx->s[ctx->p] = s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30); // b,c\n return ctx->s[ctx->p] * UINT64_C(1181783497276652981);\n}\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes(xorshift_prng_ctx_t *ctx,\n uint8_t* data,\n const size_t num_bytes) {\n const size_t wordsize = sizeof(uint64_t);\n const size_t num_words = num_bytes / wordsize;\n\n for (size_t i = 0; i < num_words; ++i) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + i * wordsize, &word, wordsize);\n }\n\n const size_t num_bytes_remaining = num_bytes - num_words * wordsize;\n\n if (num_bytes_remaining > 0) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + num_words * wordsize, &word, num_bytes_remaining);\n }\n}\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes(uint8_t* data,\n const size_t num_bytes) {\n xorshift_prng_ctx_t ctx;\n xorshift1024_init(&ctx);\n get_random_bytes(&ctx, data, num_bytes);\n}\n\n} // namespace utils\n" (comment) "/**\n * Written in 2014 by <NAME> (<EMAIL>)\n *\n * To the extent possible under law, the author has dedicated all copyright\n * and related and neighboring rights to this software to the public domain\n * worldwide. This software is distributed without any warranty.\n * \n * See <http://creativecommons.org/publicdomain/zero/1.0/>. \n * \n * This is a fast, top-quality generator. If 1024 bits of state are too\n much, try a xoroshiro128+ generator.\n\n Note that the three lowest bits of this generator are LSFRs, and thus\n they are slightly less random than the other bits. We suggest to use a\n sign test to extract a random Boolean value.\n\n The state must be seeded so that it is not everywhere zero. If you have\n a 64-bit seed, we suggest to seed a splitmix64 generator and use its\n output to fill s.\n */" (preproc_call) "#pragma once\n" (preproc_directive) "#pragma" (preproc_arg) "once" (comment) "// ---------------------------------------------------------" (preproc_include) "#include <stdint.h>\n" (#include) "#include" (system_lib_string) "<stdint.h>" (preproc_include) "#include <string.h>\n" (#include) "#include" (system_lib_string) "<string.h>" (preproc_include) "#include <fcntl.h>\n" (#include) "#include" (system_lib_string) "<fcntl.h>" (preproc_include) "#include <stdio.h>\n" (#include) "#include" (system_lib_string) "<stdio.h>" (preproc_include) "#include <stdlib.h>\n" (#include) "#include" (system_lib_string) "<stdlib.h>" (preproc_include) "#include <sys/stat.h>\n" (#include) "#include" (system_lib_string) "<sys/stat.h>" (preproc_include) "#include <sys/types.h>\n" (#include) "#include" (system_lib_string) "<sys/types.h>" (preproc_include) "#include <unistd.h>\n" (#include) "#include" (system_lib_string) "<unistd.h>" (comment) "// ---------------------------------------------------------" (function_definition) "namespace utils {\n// ---------------------------------------------------------\n\ntypedef struct {\n uint64_t s[16]; \n int p;\n} xorshift_prng_ctx_t;\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes_from_dev_urandom(uint8_t* data, size_t num_bytes) {\n int gathered_bytes = open("/dev/urandom", O_RDONLY);\n size_t len = 0;\n\n while (len < num_bytes) {\n ssize_t num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n );\n\n if (num_gathered_bytes < 0) {\n puts("Error, unable to read stream");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n } else {\n len += num_gathered_bytes;\n }\n }\n\n close(gathered_bytes);\n}\n\n// ---------------------------------------------------------\n\nvoid xorshift1024_init(xorshift_prng_ctx_t* ctx) {\n const size_t num_bytes = 16 * sizeof(uint64_t);\n get_random_bytes_from_dev_urandom((uint8_t*)(ctx->s), num_bytes);\n ctx->p = 0;\n}\n\n// ---------------------------------------------------------\n\nuint64_t xorshift1024_next(xorshift_prng_ctx_t* ctx) {\n const uint64_t s0 = ctx->s[ctx->p];\n uint64_t s1 = ctx->s[ctx->p = (ctx->p + 1) & 15];\n s1 ^= s1 << 31; // a\n ctx->s[ctx->p] = s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30); // b,c\n return ctx->s[ctx->p] * UINT64_C(1181783497276652981);\n}\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes(xorshift_prng_ctx_t *ctx,\n uint8_t* data,\n const size_t num_bytes) {\n const size_t wordsize = sizeof(uint64_t);\n const size_t num_words = num_bytes / wordsize;\n\n for (size_t i = 0; i < num_words; ++i) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + i * wordsize, &word, wordsize);\n }\n\n const size_t num_bytes_remaining = num_bytes - num_words * wordsize;\n\n if (num_bytes_remaining > 0) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + num_words * wordsize, &word, num_bytes_remaining);\n }\n}\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes(uint8_t* data,\n const size_t num_bytes) {\n xorshift_prng_ctx_t ctx;\n xorshift1024_init(&ctx);\n get_random_bytes(&ctx, data, num_bytes);\n}\n\n}" (type_identifier) "namespace" (identifier) "utils" (compound_statement) "{\n// ---------------------------------------------------------\n\ntypedef struct {\n uint64_t s[16]; \n int p;\n} xorshift_prng_ctx_t;\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes_from_dev_urandom(uint8_t* data, size_t num_bytes) {\n int gathered_bytes = open("/dev/urandom", O_RDONLY);\n size_t len = 0;\n\n while (len < num_bytes) {\n ssize_t num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n );\n\n if (num_gathered_bytes < 0) {\n puts("Error, unable to read stream");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n } else {\n len += num_gathered_bytes;\n }\n }\n\n close(gathered_bytes);\n}\n\n// ---------------------------------------------------------\n\nvoid xorshift1024_init(xorshift_prng_ctx_t* ctx) {\n const size_t num_bytes = 16 * sizeof(uint64_t);\n get_random_bytes_from_dev_urandom((uint8_t*)(ctx->s), num_bytes);\n ctx->p = 0;\n}\n\n// ---------------------------------------------------------\n\nuint64_t xorshift1024_next(xorshift_prng_ctx_t* ctx) {\n const uint64_t s0 = ctx->s[ctx->p];\n uint64_t s1 = ctx->s[ctx->p = (ctx->p + 1) & 15];\n s1 ^= s1 << 31; // a\n ctx->s[ctx->p] = s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30); // b,c\n return ctx->s[ctx->p] * UINT64_C(1181783497276652981);\n}\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes(xorshift_prng_ctx_t *ctx,\n uint8_t* data,\n const size_t num_bytes) {\n const size_t wordsize = sizeof(uint64_t);\n const size_t num_words = num_bytes / wordsize;\n\n for (size_t i = 0; i < num_words; ++i) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + i * wordsize, &word, wordsize);\n }\n\n const size_t num_bytes_remaining = num_bytes - num_words * wordsize;\n\n if (num_bytes_remaining > 0) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + num_words * wordsize, &word, num_bytes_remaining);\n }\n}\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes(uint8_t* data,\n const size_t num_bytes) {\n xorshift_prng_ctx_t ctx;\n xorshift1024_init(&ctx);\n get_random_bytes(&ctx, data, num_bytes);\n}\n\n}" ({) "{" (comment) "// ---------------------------------------------------------" (type_definition) "typedef struct {\n uint64_t s[16]; \n int p;\n} xorshift_prng_ctx_t;" (typedef) "typedef" (struct_specifier) "struct {\n uint64_t s[16]; \n int p;\n}" (struct) "struct" (field_declaration_list) "{\n uint64_t s[16]; \n int p;\n}" ({) "{" (field_declaration) "uint64_t s[16];" (primitive_type) "uint64_t" (array_declarator) "s[16]" (field_identifier) "s" ([) "[" (number_literal) "16" (]) "]" (;) ";" (field_declaration) "int p;" (primitive_type) "int" (field_identifier) "p" (;) ";" (}) "}" (type_identifier) "xorshift_prng_ctx_t" (;) ";" (comment) "// ---------------------------------------------------------" (function_definition) "void get_random_bytes_from_dev_urandom(uint8_t* data, size_t num_bytes) {\n int gathered_bytes = open("/dev/urandom", O_RDONLY);\n size_t len = 0;\n\n while (len < num_bytes) {\n ssize_t num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n );\n\n if (num_gathered_bytes < 0) {\n puts("Error, unable to read stream");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n } else {\n len += num_gathered_bytes;\n }\n }\n\n close(gathered_bytes);\n}" (primitive_type) "void" (function_declarator) "get_random_bytes_from_dev_urandom(uint8_t* data, size_t num_bytes)" (identifier) "get_random_bytes_from_dev_urandom" (parameter_list) "(uint8_t* data, size_t num_bytes)" (() "(" (parameter_declaration) "uint8_t* data" (primitive_type) "uint8_t" (pointer_declarator) "* data" (*) "*" (identifier) "data" (,) "," (parameter_declaration) "size_t num_bytes" (primitive_type) "size_t" (identifier) "num_bytes" ()) ")" (compound_statement) "{\n int gathered_bytes = open("/dev/urandom", O_RDONLY);\n size_t len = 0;\n\n while (len < num_bytes) {\n ssize_t num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n );\n\n if (num_gathered_bytes < 0) {\n puts("Error, unable to read stream");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n } else {\n len += num_gathered_bytes;\n }\n }\n\n close(gathered_bytes);\n}" ({) "{" (declaration) "int gathered_bytes = open("/dev/urandom", O_RDONLY);" (primitive_type) "int" (init_declarator) "gathered_bytes = open("/dev/urandom", O_RDONLY)" (identifier) "gathered_bytes" (=) "=" (call_expression) "open("/dev/urandom", O_RDONLY)" (identifier) "open" (argument_list) "("/dev/urandom", O_RDONLY)" (() "(" (string_literal) ""/dev/urandom"" (") """ (string_content) "/dev/urandom" (") """ (,) "," (identifier) "O_RDONLY" ()) ")" (;) ";" (declaration) "size_t len = 0;" (primitive_type) "size_t" (init_declarator) "len = 0" (identifier) "len" (=) "=" (number_literal) "0" (;) ";" (while_statement) "while (len < num_bytes) {\n ssize_t num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n );\n\n if (num_gathered_bytes < 0) {\n puts("Error, unable to read stream");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n } else {\n len += num_gathered_bytes;\n }\n }" (while) "while" (parenthesized_expression) "(len < num_bytes)" (() "(" (binary_expression) "len < num_bytes" (identifier) "len" (<) "<" (identifier) "num_bytes" ()) ")" (compound_statement) "{\n ssize_t num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n );\n\n if (num_gathered_bytes < 0) {\n puts("Error, unable to read stream");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n } else {\n len += num_gathered_bytes;\n }\n }" ({) "{" (declaration) "ssize_t num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n );" (primitive_type) "ssize_t" (init_declarator) "num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n )" (identifier) "num_gathered_bytes" (=) "=" (call_expression) "read(\n gathered_bytes, \n data + len, \n num_bytes - len\n )" (identifier) "read" (argument_list) "(\n gathered_bytes, \n data + len, \n num_bytes - len\n )" (() "(" (identifier) "gathered_bytes" (,) "," (binary_expression) "data + len" (identifier) "data" (+) "+" (identifier) "len" (,) "," (binary_expression) "num_bytes - len" (identifier) "num_bytes" (-) "-" (identifier) "len" ()) ")" (;) ";" (if_statement) "if (num_gathered_bytes < 0) {\n puts("Error, unable to read stream");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n } else {\n len += num_gathered_bytes;\n }" (if) "if" (parenthesized_expression) "(num_gathered_bytes < 0)" (() "(" (binary_expression) "num_gathered_bytes < 0" (identifier) "num_gathered_bytes" (<) "<" (number_literal) "0" ()) ")" (compound_statement) "{\n puts("Error, unable to read stream");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n }" ({) "{" (expression_statement) "puts("Error, unable to read stream");" (call_expression) "puts("Error, unable to read stream")" (identifier) "puts" (argument_list) "("Error, unable to read stream")" (() "(" (string_literal) ""Error, unable to read stream"" (") """ (string_content) "Error, unable to read stream" (") """ ()) ")" (;) ";" (expression_statement) "close(gathered_bytes);" (call_expression) "close(gathered_bytes)" (identifier) "close" (argument_list) "(gathered_bytes)" (() "(" (identifier) "gathered_bytes" ()) ")" (;) ";" (expression_statement) "exit(EXIT_FAILURE);" (call_expression) "exit(EXIT_FAILURE)" (identifier) "exit" (argument_list) "(EXIT_FAILURE)" (() "(" (identifier) "EXIT_FAILURE" ()) ")" (;) ";" (}) "}" (else_clause) "else {\n len += num_gathered_bytes;\n }" (else) "else" (compound_statement) "{\n len += num_gathered_bytes;\n }" ({) "{" (expression_statement) "len += num_gathered_bytes;" (assignment_expression) "len += num_gathered_bytes" (identifier) "len" (+=) "+=" (identifier) "num_gathered_bytes" (;) ";" (}) "}" (}) "}" (expression_statement) "close(gathered_bytes);" (call_expression) "close(gathered_bytes)" (identifier) "close" (argument_list) "(gathered_bytes)" (() "(" (identifier) "gathered_bytes" ()) ")" (;) ";" (}) "}" (comment) "// ---------------------------------------------------------" (function_definition) "void xorshift1024_init(xorshift_prng_ctx_t* ctx) {\n const size_t num_bytes = 16 * sizeof(uint64_t);\n get_random_bytes_from_dev_urandom((uint8_t*)(ctx->s), num_bytes);\n ctx->p = 0;\n}" (primitive_type) "void" (function_declarator) "xorshift1024_init(xorshift_prng_ctx_t* ctx)" (identifier) "xorshift1024_init" (parameter_list) "(xorshift_prng_ctx_t* ctx)" (() "(" (parameter_declaration) "xorshift_prng_ctx_t* ctx" (type_identifier) "xorshift_prng_ctx_t" (pointer_declarator) "* ctx" (*) "*" (identifier) "ctx" ()) ")" (compound_statement) "{\n const size_t num_bytes = 16 * sizeof(uint64_t);\n get_random_bytes_from_dev_urandom((uint8_t*)(ctx->s), num_bytes);\n ctx->p = 0;\n}" ({) "{" (declaration) "const size_t num_bytes = 16 * sizeof(uint64_t);" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (init_declarator) "num_bytes = 16 * sizeof(uint64_t)" (identifier) "num_bytes" (=) "=" (binary_expression) "16 * sizeof(uint64_t)" (number_literal) "16" (*) "*" (sizeof_expression) "sizeof(uint64_t)" (sizeof) "sizeof" (() "(" (type_descriptor) "uint64_t" (primitive_type) "uint64_t" ()) ")" (;) ";" (expression_statement) "get_random_bytes_from_dev_urandom((uint8_t*)(ctx->s), num_bytes);" (call_expression) "get_random_bytes_from_dev_urandom((uint8_t*)(ctx->s), num_bytes)" (identifier) "get_random_bytes_from_dev_urandom" (argument_list) "((uint8_t*)(ctx->s), num_bytes)" (() "(" (cast_expression) "(uint8_t*)(ctx->s)" (() "(" (type_descriptor) "uint8_t*" (primitive_type) "uint8_t" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (parenthesized_expression) "(ctx->s)" (() "(" (field_expression) "ctx->s" (identifier) "ctx" (->) "->" (field_identifier) "s" ()) ")" (,) "," (identifier) "num_bytes" ()) ")" (;) ";" (expression_statement) "ctx->p = 0;" (assignment_expression) "ctx->p = 0" (field_expression) "ctx->p" (identifier) "ctx" (->) "->" (field_identifier) "p" (=) "=" (number_literal) "0" (;) ";" (}) "}" (comment) "// ---------------------------------------------------------" (function_definition) "uint64_t xorshift1024_next(xorshift_prng_ctx_t* ctx) {\n const uint64_t s0 = ctx->s[ctx->p];\n uint64_t s1 = ctx->s[ctx->p = (ctx->p + 1) & 15];\n s1 ^= s1 << 31; // a\n ctx->s[ctx->p] = s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30); // b,c\n return ctx->s[ctx->p] * UINT64_C(1181783497276652981);\n}" (primitive_type) "uint64_t" (function_declarator) "xorshift1024_next(xorshift_prng_ctx_t* ctx)" (identifier) "xorshift1024_next" (parameter_list) "(xorshift_prng_ctx_t* ctx)" (() "(" (parameter_declaration) "xorshift_prng_ctx_t* ctx" (type_identifier) "xorshift_prng_ctx_t" (pointer_declarator) "* ctx" (*) "*" (identifier) "ctx" ()) ")" (compound_statement) "{\n const uint64_t s0 = ctx->s[ctx->p];\n uint64_t s1 = ctx->s[ctx->p = (ctx->p + 1) & 15];\n s1 ^= s1 << 31; // a\n ctx->s[ctx->p] = s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30); // b,c\n return ctx->s[ctx->p] * UINT64_C(1181783497276652981);\n}" ({) "{" (declaration) "const uint64_t s0 = ctx->s[ctx->p];" (type_qualifier) "const" (const) "const" (primitive_type) "uint64_t" (init_declarator) "s0 = ctx->s[ctx->p]" (identifier) "s0" (=) "=" (subscript_expression) "ctx->s[ctx->p]" (field_expression) "ctx->s" (identifier) "ctx" (->) "->" (field_identifier) "s" ([) "[" (field_expression) "ctx->p" (identifier) "ctx" (->) "->" (field_identifier) "p" (]) "]" (;) ";" (declaration) "uint64_t s1 = ctx->s[ctx->p = (ctx->p + 1) & 15];" (primitive_type) "uint64_t" (init_declarator) "s1 = ctx->s[ctx->p = (ctx->p + 1) & 15]" (identifier) "s1" (=) "=" (subscript_expression) "ctx->s[ctx->p = (ctx->p + 1) & 15]" (field_expression) "ctx->s" (identifier) "ctx" (->) "->" (field_identifier) "s" ([) "[" (assignment_expression) "ctx->p = (ctx->p + 1) & 15" (field_expression) "ctx->p" (identifier) "ctx" (->) "->" (field_identifier) "p" (=) "=" (binary_expression) "(ctx->p + 1) & 15" (parenthesized_expression) "(ctx->p + 1)" (() "(" (binary_expression) "ctx->p + 1" (field_expression) "ctx->p" (identifier) "ctx" (->) "->" (field_identifier) "p" (+) "+" (number_literal) "1" ()) ")" (&) "&" (number_literal) "15" (]) "]" (;) ";" (expression_statement) "s1 ^= s1 << 31;" (assignment_expression) "s1 ^= s1 << 31" (identifier) "s1" (^=) "^=" (binary_expression) "s1 << 31" (identifier) "s1" (<<) "<<" (number_literal) "31" (;) ";" (comment) "// a" (expression_statement) "ctx->s[ctx->p] = s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30);" (assignment_expression) "ctx->s[ctx->p] = s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30)" (subscript_expression) "ctx->s[ctx->p]" (field_expression) "ctx->s" (identifier) "ctx" (->) "->" (field_identifier) "s" ([) "[" (field_expression) "ctx->p" (identifier) "ctx" (->) "->" (field_identifier) "p" (]) "]" (=) "=" (binary_expression) "s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30)" (binary_expression) "s1 ^ s0 ^ (s1 >> 11)" (binary_expression) "s1 ^ s0" (identifier) "s1" (^) "^" (identifier) "s0" (^) "^" (parenthesized_expression) "(s1 >> 11)" (() "(" (binary_expression) "s1 >> 11" (identifier) "s1" (>>) ">>" (number_literal) "11" ()) ")" (^) "^" (parenthesized_expression) "(s0 >> 30)" (() "(" (binary_expression) "s0 >> 30" (identifier) "s0" (>>) ">>" (number_literal) "30" ()) ")" (;) ";" (comment) "// b,c" (return_statement) "return ctx->s[ctx->p] * UINT64_C(1181783497276652981);" (return) "return" (binary_expression) "ctx->s[ctx->p] * UINT64_C(1181783497276652981)" (subscript_expression) "ctx->s[ctx->p]" (field_expression) "ctx->s" (identifier) "ctx" (->) "->" (field_identifier) "s" ([) "[" (field_expression) "ctx->p" (identifier) "ctx" (->) "->" (field_identifier) "p" (]) "]" (*) "*" (call_expression) "UINT64_C(1181783497276652981)" (identifier) "UINT64_C" (argument_list) "(1181783497276652981)" (() "(" (number_literal) "1181783497276652981" ()) ")" (;) ";" (}) "}" (comment) "// ---------------------------------------------------------" (function_definition) "void get_random_bytes(xorshift_prng_ctx_t *ctx,\n uint8_t* data,\n const size_t num_bytes) {\n const size_t wordsize = sizeof(uint64_t);\n const size_t num_words = num_bytes / wordsize;\n\n for (size_t i = 0; i < num_words; ++i) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + i * wordsize, &word, wordsize);\n }\n\n const size_t num_bytes_remaining = num_bytes - num_words * wordsize;\n\n if (num_bytes_remaining > 0) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + num_words * wordsize, &word, num_bytes_remaining);\n }\n}" (primitive_type) "void" (function_declarator) "get_random_bytes(xorshift_prng_ctx_t *ctx,\n uint8_t* data,\n const size_t num_bytes)" (identifier) "get_random_bytes" (parameter_list) "(xorshift_prng_ctx_t *ctx,\n uint8_t* data,\n const size_t num_bytes)" (() "(" (parameter_declaration) "xorshift_prng_ctx_t *ctx" (type_identifier) "xorshift_prng_ctx_t" (pointer_declarator) "*ctx" (*) "*" (identifier) "ctx" (,) "," (parameter_declaration) "uint8_t* data" (primitive_type) "uint8_t" (pointer_declarator) "* data" (*) "*" (identifier) "data" (,) "," (parameter_declaration) "const size_t num_bytes" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (identifier) "num_bytes" ()) ")" (compound_statement) "{\n const size_t wordsize = sizeof(uint64_t);\n const size_t num_words = num_bytes / wordsize;\n\n for (size_t i = 0; i < num_words; ++i) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + i * wordsize, &word, wordsize);\n }\n\n const size_t num_bytes_remaining = num_bytes - num_words * wordsize;\n\n if (num_bytes_remaining > 0) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + num_words * wordsize, &word, num_bytes_remaining);\n }\n}" ({) "{" (declaration) "const size_t wordsize = sizeof(uint64_t);" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (init_declarator) "wordsize = sizeof(uint64_t)" (identifier) "wordsize" (=) "=" (sizeof_expression) "sizeof(uint64_t)" (sizeof) "sizeof" (() "(" (type_descriptor) "uint64_t" (primitive_type) "uint64_t" ()) ")" (;) ";" (declaration) "const size_t num_words = num_bytes / wordsize;" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (init_declarator) "num_words = num_bytes / wordsize" (identifier) "num_words" (=) "=" (binary_expression) "num_bytes / wordsize" (identifier) "num_bytes" (/) "/" (identifier) "wordsize" (;) ";" (for_statement) "for (size_t i = 0; i < num_words; ++i) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + i * wordsize, &word, wordsize);\n }" (for) "for" (() "(" (declaration) "size_t i = 0;" (primitive_type) "size_t" (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i < num_words" (identifier) "i" (<) "<" (identifier) "num_words" (;) ";" (update_expression) "++i" (++) "++" (identifier) "i" ()) ")" (compound_statement) "{\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + i * wordsize, &word, wordsize);\n }" ({) "{" (declaration) "const uint64_t word = xorshift1024_next(ctx);" (type_qualifier) "const" (const) "const" (primitive_type) "uint64_t" (init_declarator) "word = xorshift1024_next(ctx)" (identifier) "word" (=) "=" (call_expression) "xorshift1024_next(ctx)" (identifier) "xorshift1024_next" (argument_list) "(ctx)" (() "(" (identifier) "ctx" ()) ")" (;) ";" (expression_statement) "memcpy(data + i * wordsize, &word, wordsize);" (call_expression) "memcpy(data + i * wordsize, &word, wordsize)" (identifier) "memcpy" (argument_list) "(data + i * wordsize, &word, wordsize)" (() "(" (binary_expression) "data + i * wordsize" (identifier) "data" (+) "+" (binary_expression) "i * wordsize" (identifier) "i" (*) "*" (identifier) "wordsize" (,) "," (pointer_expression) "&word" (&) "&" (identifier) "word" (,) "," (identifier) "wordsize" ()) ")" (;) ";" (}) "}" (declaration) "const size_t num_bytes_remaining = num_bytes - num_words * wordsize;" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (init_declarator) "num_bytes_remaining = num_bytes - num_words * wordsize" (identifier) "num_bytes_remaining" (=) "=" (binary_expression) "num_bytes - num_words * wordsize" (identifier) "num_bytes" (-) "-" (binary_expression) "num_words * wordsize" (identifier) "num_words" (*) "*" (identifier) "wordsize" (;) ";" (if_statement) "if (num_bytes_remaining > 0) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + num_words * wordsize, &word, num_bytes_remaining);\n }" (if) "if" (parenthesized_expression) "(num_bytes_remaining > 0)" (() "(" (binary_expression) "num_bytes_remaining > 0" (identifier) "num_bytes_remaining" (>) ">" (number_literal) "0" ()) ")" (compound_statement) "{\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + num_words * wordsize, &word, num_bytes_remaining);\n }" ({) "{" (declaration) "const uint64_t word = xorshift1024_next(ctx);" (type_qualifier) "const" (const) "const" (primitive_type) "uint64_t" (init_declarator) "word = xorshift1024_next(ctx)" (identifier) "word" (=) "=" (call_expression) "xorshift1024_next(ctx)" (identifier) "xorshift1024_next" (argument_list) "(ctx)" (() "(" (identifier) "ctx" ()) ")" (;) ";" (expression_statement) "memcpy(data + num_words * wordsize, &word, num_bytes_remaining);" (call_expression) "memcpy(data + num_words * wordsize, &word, num_bytes_remaining)" (identifier) "memcpy" (argument_list) "(data + num_words * wordsize, &word, num_bytes_remaining)" (() "(" (binary_expression) "data + num_words * wordsize" (identifier) "data" (+) "+" (binary_expression) "num_words * wordsize" (identifier) "num_words" (*) "*" (identifier) "wordsize" (,) "," (pointer_expression) "&word" (&) "&" (identifier) "word" (,) "," (identifier) "num_bytes_remaining" ()) ")" (;) ";" (}) "}" (}) "}" (comment) "// ---------------------------------------------------------" (function_definition) "void get_random_bytes(uint8_t* data,\n const size_t num_bytes) {\n xorshift_prng_ctx_t ctx;\n xorshift1024_init(&ctx);\n get_random_bytes(&ctx, data, num_bytes);\n}" (primitive_type) "void" (function_declarator) "get_random_bytes(uint8_t* data,\n const size_t num_bytes)" (identifier) "get_random_bytes" (parameter_list) "(uint8_t* data,\n const size_t num_bytes)" (() "(" (parameter_declaration) "uint8_t* data" (primitive_type) "uint8_t" (pointer_declarator) "* data" (*) "*" (identifier) "data" (,) "," (parameter_declaration) "const size_t num_bytes" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (identifier) "num_bytes" ()) ")" (compound_statement) "{\n xorshift_prng_ctx_t ctx;\n xorshift1024_init(&ctx);\n get_random_bytes(&ctx, data, num_bytes);\n}" ({) "{" (declaration) "xorshift_prng_ctx_t ctx;" (type_identifier) "xorshift_prng_ctx_t" (identifier) "ctx" (;) ";" (expression_statement) "xorshift1024_init(&ctx);" (call_expression) "xorshift1024_init(&ctx)" (identifier) "xorshift1024_init" (argument_list) "(&ctx)" (() "(" (pointer_expression) "&ctx" (&) "&" (identifier) "ctx" ()) ")" (;) ";" (expression_statement) "get_random_bytes(&ctx, data, num_bytes);" (call_expression) "get_random_bytes(&ctx, data, num_bytes)" (identifier) "get_random_bytes" (argument_list) "(&ctx, data, num_bytes)" (() "(" (pointer_expression) "&ctx" (&) "&" (identifier) "ctx" (,) "," (identifier) "data" (,) "," (identifier) "num_bytes" ()) ")" (;) ";" (}) "}" (}) "}" (comment) "// namespace utils"
619
0
{"language": "c", "success": true, "metadata": {"lines": 93, "avg_line_length": 36.31, "nodes": 394, "errors": 0, "source_hash": "5771b519acfefea46c8f59616c53b6c842eca719a3243b6016ad63f68ddec19f", "categorized_nodes": 273}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#pragma once\n", "parent": null, "children": [1, 2], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 22, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#pragma", "parent": 0, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "once", "parent": 0, "children": [], "start_point": {"row": 21, "column": 8}, "end_point": {"row": 21, "column": 12}}, {"id": 3, "type": "preproc_include", "text": "#include <stdint.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 26, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<stdint.h>", "parent": 3, "children": [], "start_point": {"row": 25, "column": 9}, "end_point": {"row": 25, "column": 19}}, {"id": 6, "type": "preproc_include", "text": "#include <string.h>\n", "parent": null, "children": [7, 8], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 27, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<string.h>", "parent": 6, "children": [], "start_point": {"row": 26, "column": 9}, "end_point": {"row": 26, "column": 19}}, {"id": 9, "type": "preproc_include", "text": "#include <fcntl.h>\n", "parent": null, "children": [10, 11], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 29, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<fcntl.h>", "parent": 9, "children": [], "start_point": {"row": 28, "column": 9}, "end_point": {"row": 28, "column": 18}}, {"id": 12, "type": "preproc_include", "text": "#include <stdio.h>\n", "parent": null, "children": [13, 14], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 30, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 8}}, {"id": 14, "type": "system_lib_string", "text": "<stdio.h>", "parent": 12, "children": [], "start_point": {"row": 29, "column": 9}, "end_point": {"row": 29, "column": 18}}, {"id": 15, "type": "preproc_include", "text": "#include <stdlib.h>\n", "parent": null, "children": [16, 17], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 31, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 8}}, {"id": 17, "type": "system_lib_string", "text": "<stdlib.h>", "parent": 15, "children": [], "start_point": {"row": 30, "column": 9}, "end_point": {"row": 30, "column": 19}}, {"id": 18, "type": "preproc_include", "text": "#include <sys/stat.h>\n", "parent": null, "children": [19, 20], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 32, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 31, "column": 8}}, {"id": 20, "type": "system_lib_string", "text": "<sys/stat.h>", "parent": 18, "children": [], "start_point": {"row": 31, "column": 9}, "end_point": {"row": 31, "column": 21}}, {"id": 21, "type": "preproc_include", "text": "#include <sys/types.h>\n", "parent": null, "children": [22, 23], "start_point": {"row": 32, "column": 0}, "end_point": {"row": 33, "column": 0}}, {"id": 22, "type": "#include", "text": "#include", "parent": 21, "children": [], "start_point": {"row": 32, "column": 0}, "end_point": {"row": 32, "column": 8}}, {"id": 23, "type": "system_lib_string", "text": "<sys/types.h>", "parent": 21, "children": [], "start_point": {"row": 32, "column": 9}, "end_point": {"row": 32, "column": 22}}, {"id": 24, "type": "preproc_include", "text": "#include <unistd.h>\n", "parent": null, "children": [25, 26], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 34, "column": 0}}, {"id": 25, "type": "#include", "text": "#include", "parent": 24, "children": [], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 33, "column": 8}}, {"id": 26, "type": "system_lib_string", "text": "<unistd.h>", "parent": 24, "children": [], "start_point": {"row": 33, "column": 9}, "end_point": {"row": 33, "column": 19}}, {"id": 27, "type": "function_definition", "text": "namespace utils {\n// ---------------------------------------------------------\n\ntypedef struct {\n uint64_t s[16]; \n int p;\n} xorshift_prng_ctx_t;\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes_from_dev_urandom(uint8_t* data, size_t num_bytes) {\n int gathered_bytes = open(\"/dev/urandom\", O_RDONLY);\n size_t len = 0;\n\n while (len < num_bytes) {\n ssize_t num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n );\n\n if (num_gathered_bytes < 0) {\n puts(\"Error, unable to read stream\");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n } else {\n len += num_gathered_bytes;\n }\n }\n\n close(gathered_bytes);\n}\n\n// ---------------------------------------------------------\n\nvoid xorshift1024_init(xorshift_prng_ctx_t* ctx) {\n const size_t num_bytes = 16 * sizeof(uint64_t);\n get_random_bytes_from_dev_urandom((uint8_t*)(ctx->s), num_bytes);\n ctx->p = 0;\n}\n\n// ---------------------------------------------------------\n\nuint64_t xorshift1024_next(xorshift_prng_ctx_t* ctx) {\n const uint64_t s0 = ctx->s[ctx->p];\n uint64_t s1 = ctx->s[ctx->p = (ctx->p + 1) & 15];\n s1 ^= s1 << 31; // a\n ctx->s[ctx->p] = s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30); // b,c\n return ctx->s[ctx->p] * UINT64_C(1181783497276652981);\n}\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes(xorshift_prng_ctx_t *ctx,\n uint8_t* data,\n const size_t num_bytes) {\n const size_t wordsize = sizeof(uint64_t);\n const size_t num_words = num_bytes / wordsize;\n\n for (size_t i = 0; i < num_words; ++i) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + i * wordsize, &word, wordsize);\n }\n\n const size_t num_bytes_remaining = num_bytes - num_words * wordsize;\n\n if (num_bytes_remaining > 0) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + num_words * wordsize, &word, num_bytes_remaining);\n }\n}\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes(uint8_t* data,\n const size_t num_bytes) {\n xorshift_prng_ctx_t ctx;\n xorshift1024_init(&ctx);\n get_random_bytes(&ctx, data, num_bytes);\n}\n\n}", "parent": null, "children": [28, 29], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 118, "column": 1}}, {"id": 28, "type": "type_identifier", "text": "namespace", "parent": 27, "children": [], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 37, "column": 9}}, {"id": 29, "type": "identifier", "text": "utils", "parent": 27, "children": [], "start_point": {"row": 37, "column": 10}, "end_point": {"row": 37, "column": 15}}, {"id": 30, "type": "type_definition", "text": "typedef struct {\n uint64_t s[16]; \n int p;\n} xorshift_prng_ctx_t;", "parent": 27, "children": [31, 32, 42], "start_point": {"row": 40, "column": 0}, "end_point": {"row": 43, "column": 22}}, {"id": 31, "type": "typedef", "text": "typedef", "parent": 30, "children": [], "start_point": {"row": 40, "column": 0}, "end_point": {"row": 40, "column": 7}}, {"id": 32, "type": "struct_specifier", "text": "struct {\n uint64_t s[16]; \n int p;\n}", "parent": 30, "children": [33], "start_point": {"row": 40, "column": 8}, "end_point": {"row": 43, "column": 1}}, {"id": 33, "type": "struct", "text": "struct", "parent": 32, "children": [], "start_point": {"row": 40, "column": 8}, "end_point": {"row": 40, "column": 14}}, {"id": 34, "type": "field_declaration", "text": "uint64_t s[16];", "parent": 32, "children": [35, 36], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 41, "column": 19}}, {"id": 35, "type": "primitive_type", "text": "uint64_t", "parent": 34, "children": [], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 41, "column": 12}}, {"id": 36, "type": "array_declarator", "text": "s[16]", "parent": 34, "children": [37, 38], "start_point": {"row": 41, "column": 13}, "end_point": {"row": 41, "column": 18}}, {"id": 37, "type": "field_identifier", "text": "s", "parent": 36, "children": [], "start_point": {"row": 41, "column": 13}, "end_point": {"row": 41, "column": 14}}, {"id": 38, "type": "number_literal", "text": "16", "parent": 36, "children": [], "start_point": {"row": 41, "column": 15}, "end_point": {"row": 41, "column": 17}}, {"id": 39, "type": "field_declaration", "text": "int p;", "parent": 32, "children": [40, 41], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 10}}, {"id": 40, "type": "primitive_type", "text": "int", "parent": 39, "children": [], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 7}}, {"id": 41, "type": "field_identifier", "text": "p", "parent": 39, "children": [], "start_point": {"row": 42, "column": 8}, "end_point": {"row": 42, "column": 9}}, {"id": 42, "type": "type_identifier", "text": "xorshift_prng_ctx_t", "parent": 30, "children": [], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 43, "column": 21}}, {"id": 43, "type": "function_definition", "text": "void get_random_bytes_from_dev_urandom(uint8_t* data, size_t num_bytes) {\n int gathered_bytes = open(\"/dev/urandom\", O_RDONLY);\n size_t len = 0;\n\n while (len < num_bytes) {\n ssize_t num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n );\n\n if (num_gathered_bytes < 0) {\n puts(\"Error, unable to read stream\");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n } else {\n len += num_gathered_bytes;\n }\n }\n\n close(gathered_bytes);\n}", "parent": 27, "children": [44, 45], "start_point": {"row": 47, "column": 0}, "end_point": {"row": 68, "column": 1}}, {"id": 44, "type": "primitive_type", "text": "void", "parent": 43, "children": [], "start_point": {"row": 47, "column": 0}, "end_point": {"row": 47, "column": 4}}, {"id": 45, "type": "function_declarator", "text": "get_random_bytes_from_dev_urandom(uint8_t* data, size_t num_bytes)", "parent": 43, "children": [46, 47], "start_point": {"row": 47, "column": 5}, "end_point": {"row": 47, "column": 71}}, {"id": 46, "type": "identifier", "text": "get_random_bytes_from_dev_urandom", "parent": 45, "children": [], "start_point": {"row": 47, "column": 5}, "end_point": {"row": 47, "column": 38}}, {"id": 47, "type": "parameter_list", "text": "(uint8_t* data, size_t num_bytes)", "parent": 45, "children": [48, 53], "start_point": {"row": 47, "column": 38}, "end_point": {"row": 47, "column": 71}}, {"id": 48, "type": "parameter_declaration", "text": "uint8_t* data", "parent": 47, "children": [49, 50], "start_point": {"row": 47, "column": 39}, "end_point": {"row": 47, "column": 52}}, {"id": 49, "type": "primitive_type", "text": "uint8_t", "parent": 48, "children": [], "start_point": {"row": 47, "column": 39}, "end_point": {"row": 47, "column": 46}}, {"id": 50, "type": "pointer_declarator", "text": "* data", "parent": 48, "children": [51, 52], "start_point": {"row": 47, "column": 46}, "end_point": {"row": 47, "column": 52}}, {"id": 51, "type": "*", "text": "*", "parent": 50, "children": [], "start_point": {"row": 47, "column": 46}, "end_point": {"row": 47, "column": 47}}, {"id": 52, "type": "identifier", "text": "data", "parent": 50, "children": [], "start_point": {"row": 47, "column": 48}, "end_point": {"row": 47, "column": 52}}, {"id": 53, "type": "parameter_declaration", "text": "size_t num_bytes", "parent": 47, "children": [54, 55], "start_point": {"row": 47, "column": 54}, "end_point": {"row": 47, "column": 70}}, {"id": 54, "type": "primitive_type", "text": "size_t", "parent": 53, "children": [], "start_point": {"row": 47, "column": 54}, "end_point": {"row": 47, "column": 60}}, {"id": 55, "type": "identifier", "text": "num_bytes", "parent": 53, "children": [], "start_point": {"row": 47, "column": 61}, "end_point": {"row": 47, "column": 70}}, {"id": 56, "type": "declaration", "text": "int gathered_bytes = open(\"/dev/urandom\", O_RDONLY);", "parent": 43, "children": [57, 58], "start_point": {"row": 48, "column": 4}, "end_point": {"row": 48, "column": 56}}, {"id": 57, "type": "primitive_type", "text": "int", "parent": 56, "children": [], "start_point": {"row": 48, "column": 4}, "end_point": {"row": 48, "column": 7}}, {"id": 58, "type": "init_declarator", "text": "gathered_bytes = open(\"/dev/urandom\", O_RDONLY)", "parent": 56, "children": [59, 60, 61], "start_point": {"row": 48, "column": 8}, "end_point": {"row": 48, "column": 55}}, {"id": 59, "type": "identifier", "text": "gathered_bytes", "parent": 58, "children": [], "start_point": {"row": 48, "column": 8}, "end_point": {"row": 48, "column": 22}}, {"id": 60, "type": "=", "text": "=", "parent": 58, "children": [], "start_point": {"row": 48, "column": 23}, "end_point": {"row": 48, "column": 24}}, {"id": 61, "type": "call_expression", "text": "open(\"/dev/urandom\", O_RDONLY)", "parent": 58, "children": [62, 63], "start_point": {"row": 48, "column": 25}, "end_point": {"row": 48, "column": 55}}, {"id": 62, "type": "identifier", "text": "open", "parent": 61, "children": [], "start_point": {"row": 48, "column": 25}, "end_point": {"row": 48, "column": 29}}, {"id": 63, "type": "argument_list", "text": "(\"/dev/urandom\", O_RDONLY)", "parent": 61, "children": [64, 65], "start_point": {"row": 48, "column": 29}, "end_point": {"row": 48, "column": 55}}, {"id": 64, "type": "string_literal", "text": "\"/dev/urandom\"", "parent": 63, "children": [], "start_point": {"row": 48, "column": 30}, "end_point": {"row": 48, "column": 44}}, {"id": 65, "type": "identifier", "text": "O_RDONLY", "parent": 63, "children": [], "start_point": {"row": 48, "column": 46}, "end_point": {"row": 48, "column": 54}}, {"id": 66, "type": "declaration", "text": "size_t len = 0;", "parent": 43, "children": [67, 68], "start_point": {"row": 49, "column": 4}, "end_point": {"row": 49, "column": 19}}, {"id": 67, "type": "primitive_type", "text": "size_t", "parent": 66, "children": [], "start_point": {"row": 49, "column": 4}, "end_point": {"row": 49, "column": 10}}, {"id": 68, "type": "init_declarator", "text": "len = 0", "parent": 66, "children": [69, 70, 71], "start_point": {"row": 49, "column": 11}, "end_point": {"row": 49, "column": 18}}, {"id": 69, "type": "identifier", "text": "len", "parent": 68, "children": [], "start_point": {"row": 49, "column": 11}, "end_point": {"row": 49, "column": 14}}, {"id": 70, "type": "=", "text": "=", "parent": 68, "children": [], "start_point": {"row": 49, "column": 15}, "end_point": {"row": 49, "column": 16}}, {"id": 71, "type": "number_literal", "text": "0", "parent": 68, "children": [], "start_point": {"row": 49, "column": 17}, "end_point": {"row": 49, "column": 18}}, {"id": 72, "type": "while_statement", "text": "while (len < num_bytes) {\n ssize_t num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n );\n\n if (num_gathered_bytes < 0) {\n puts(\"Error, unable to read stream\");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n } else {\n len += num_gathered_bytes;\n }\n }", "parent": 43, "children": [73], "start_point": {"row": 51, "column": 4}, "end_point": {"row": 65, "column": 5}}, {"id": 73, "type": "parenthesized_expression", "text": "(len < num_bytes)", "parent": 72, "children": [74], "start_point": {"row": 51, "column": 10}, "end_point": {"row": 51, "column": 27}}, {"id": 74, "type": "binary_expression", "text": "len < num_bytes", "parent": 73, "children": [75, 76, 77], "start_point": {"row": 51, "column": 11}, "end_point": {"row": 51, "column": 26}}, {"id": 75, "type": "identifier", "text": "len", "parent": 74, "children": [], "start_point": {"row": 51, "column": 11}, "end_point": {"row": 51, "column": 14}}, {"id": 76, "type": "<", "text": "<", "parent": 74, "children": [], "start_point": {"row": 51, "column": 15}, "end_point": {"row": 51, "column": 16}}, {"id": 77, "type": "identifier", "text": "num_bytes", "parent": 74, "children": [], "start_point": {"row": 51, "column": 17}, "end_point": {"row": 51, "column": 26}}, {"id": 78, "type": "declaration", "text": "ssize_t num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n );", "parent": 72, "children": [79, 80], "start_point": {"row": 52, "column": 8}, "end_point": {"row": 56, "column": 10}}, {"id": 79, "type": "primitive_type", "text": "ssize_t", "parent": 78, "children": [], "start_point": {"row": 52, "column": 8}, "end_point": {"row": 52, "column": 15}}, {"id": 80, "type": "init_declarator", "text": "num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n )", "parent": 78, "children": [81, 82, 83], "start_point": {"row": 52, "column": 16}, "end_point": {"row": 56, "column": 9}}, {"id": 81, "type": "identifier", "text": "num_gathered_bytes", "parent": 80, "children": [], "start_point": {"row": 52, "column": 16}, "end_point": {"row": 52, "column": 34}}, {"id": 82, "type": "=", "text": "=", "parent": 80, "children": [], "start_point": {"row": 52, "column": 35}, "end_point": {"row": 52, "column": 36}}, {"id": 83, "type": "call_expression", "text": "read(\n gathered_bytes, \n data + len, \n num_bytes - len\n )", "parent": 80, "children": [84, 85], "start_point": {"row": 52, "column": 37}, "end_point": {"row": 56, "column": 9}}, {"id": 84, "type": "identifier", "text": "read", "parent": 83, "children": [], "start_point": {"row": 52, "column": 37}, "end_point": {"row": 52, "column": 41}}, {"id": 85, "type": "argument_list", "text": "(\n gathered_bytes, \n data + len, \n num_bytes - len\n )", "parent": 83, "children": [86, 87, 91], "start_point": {"row": 52, "column": 41}, "end_point": {"row": 56, "column": 9}}, {"id": 86, "type": "identifier", "text": "gathered_bytes", "parent": 85, "children": [], "start_point": {"row": 53, "column": 12}, "end_point": {"row": 53, "column": 26}}, {"id": 87, "type": "binary_expression", "text": "data + len", "parent": 85, "children": [88, 89, 90], "start_point": {"row": 54, "column": 12}, "end_point": {"row": 54, "column": 22}}, {"id": 88, "type": "identifier", "text": "data", "parent": 87, "children": [], "start_point": {"row": 54, "column": 12}, "end_point": {"row": 54, "column": 16}}, {"id": 89, "type": "+", "text": "+", "parent": 87, "children": [], "start_point": {"row": 54, "column": 17}, "end_point": {"row": 54, "column": 18}}, {"id": 90, "type": "identifier", "text": "len", "parent": 87, "children": [], "start_point": {"row": 54, "column": 19}, "end_point": {"row": 54, "column": 22}}, {"id": 91, "type": "binary_expression", "text": "num_bytes - len", "parent": 85, "children": [92, 93, 94], "start_point": {"row": 55, "column": 12}, "end_point": {"row": 55, "column": 27}}, {"id": 92, "type": "identifier", "text": "num_bytes", "parent": 91, "children": [], "start_point": {"row": 55, "column": 12}, "end_point": {"row": 55, "column": 21}}, {"id": 93, "type": "-", "text": "-", "parent": 91, "children": [], "start_point": {"row": 55, "column": 22}, "end_point": {"row": 55, "column": 23}}, {"id": 94, "type": "identifier", "text": "len", "parent": 91, "children": [], "start_point": {"row": 55, "column": 24}, "end_point": {"row": 55, "column": 27}}, {"id": 95, "type": "if_statement", "text": "if (num_gathered_bytes < 0) {\n puts(\"Error, unable to read stream\");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n } else {\n len += num_gathered_bytes;\n }", "parent": 72, "children": [96, 113], "start_point": {"row": 58, "column": 8}, "end_point": {"row": 64, "column": 9}}, {"id": 96, "type": "parenthesized_expression", "text": "(num_gathered_bytes < 0)", "parent": 95, "children": [97], "start_point": {"row": 58, "column": 11}, "end_point": {"row": 58, "column": 35}}, {"id": 97, "type": "binary_expression", "text": "num_gathered_bytes < 0", "parent": 96, "children": [98, 99, 100], "start_point": {"row": 58, "column": 12}, "end_point": {"row": 58, "column": 34}}, {"id": 98, "type": "identifier", "text": "num_gathered_bytes", "parent": 97, "children": [], "start_point": {"row": 58, "column": 12}, "end_point": {"row": 58, "column": 30}}, {"id": 99, "type": "<", "text": "<", "parent": 97, "children": [], "start_point": {"row": 58, "column": 31}, "end_point": {"row": 58, "column": 32}}, {"id": 100, "type": "number_literal", "text": "0", "parent": 97, "children": [], "start_point": {"row": 58, "column": 33}, "end_point": {"row": 58, "column": 34}}, {"id": 101, "type": "call_expression", "text": "puts(\"Error, unable to read stream\")", "parent": 95, "children": [102, 103], "start_point": {"row": 59, "column": 12}, "end_point": {"row": 59, "column": 48}}, {"id": 102, "type": "identifier", "text": "puts", "parent": 101, "children": [], "start_point": {"row": 59, "column": 12}, "end_point": {"row": 59, "column": 16}}, {"id": 103, "type": "argument_list", "text": "(\"Error, unable to read stream\")", "parent": 101, "children": [104], "start_point": {"row": 59, "column": 16}, "end_point": {"row": 59, "column": 48}}, {"id": 104, "type": "string_literal", "text": "\"Error, unable to read stream\"", "parent": 103, "children": [], "start_point": {"row": 59, "column": 17}, "end_point": {"row": 59, "column": 47}}, {"id": 105, "type": "call_expression", "text": "close(gathered_bytes)", "parent": 95, "children": [106, 107], "start_point": {"row": 60, "column": 12}, "end_point": {"row": 60, "column": 33}}, {"id": 106, "type": "identifier", "text": "close", "parent": 105, "children": [], "start_point": {"row": 60, "column": 12}, "end_point": {"row": 60, "column": 17}}, {"id": 107, "type": "argument_list", "text": "(gathered_bytes)", "parent": 105, "children": [108], "start_point": {"row": 60, "column": 17}, "end_point": {"row": 60, "column": 33}}, {"id": 108, "type": "identifier", "text": "gathered_bytes", "parent": 107, "children": [], "start_point": {"row": 60, "column": 18}, "end_point": {"row": 60, "column": 32}}, {"id": 109, "type": "call_expression", "text": "exit(EXIT_FAILURE)", "parent": 95, "children": [110, 111], "start_point": {"row": 61, "column": 12}, "end_point": {"row": 61, "column": 30}}, {"id": 110, "type": "identifier", "text": "exit", "parent": 109, "children": [], "start_point": {"row": 61, "column": 12}, "end_point": {"row": 61, "column": 16}}, {"id": 111, "type": "argument_list", "text": "(EXIT_FAILURE)", "parent": 109, "children": [112], "start_point": {"row": 61, "column": 16}, "end_point": {"row": 61, "column": 30}}, {"id": 112, "type": "identifier", "text": "EXIT_FAILURE", "parent": 111, "children": [], "start_point": {"row": 61, "column": 17}, "end_point": {"row": 61, "column": 29}}, {"id": 113, "type": "else_clause", "text": "else {\n len += num_gathered_bytes;\n }", "parent": 95, "children": [], "start_point": {"row": 62, "column": 10}, "end_point": {"row": 64, "column": 9}}, {"id": 114, "type": "assignment_expression", "text": "len += num_gathered_bytes", "parent": 113, "children": [115, 116, 117], "start_point": {"row": 63, "column": 12}, "end_point": {"row": 63, "column": 37}}, {"id": 115, "type": "identifier", "text": "len", "parent": 114, "children": [], "start_point": {"row": 63, "column": 12}, "end_point": {"row": 63, "column": 15}}, {"id": 116, "type": "+=", "text": "+=", "parent": 114, "children": [], "start_point": {"row": 63, "column": 16}, "end_point": {"row": 63, "column": 18}}, {"id": 117, "type": "identifier", "text": "num_gathered_bytes", "parent": 114, "children": [], "start_point": {"row": 63, "column": 19}, "end_point": {"row": 63, "column": 37}}, {"id": 118, "type": "call_expression", "text": "close(gathered_bytes)", "parent": 43, "children": [119, 120], "start_point": {"row": 67, "column": 4}, "end_point": {"row": 67, "column": 25}}, {"id": 119, "type": "identifier", "text": "close", "parent": 118, "children": [], "start_point": {"row": 67, "column": 4}, "end_point": {"row": 67, "column": 9}}, {"id": 120, "type": "argument_list", "text": "(gathered_bytes)", "parent": 118, "children": [121], "start_point": {"row": 67, "column": 9}, "end_point": {"row": 67, "column": 25}}, {"id": 121, "type": "identifier", "text": "gathered_bytes", "parent": 120, "children": [], "start_point": {"row": 67, "column": 10}, "end_point": {"row": 67, "column": 24}}, {"id": 122, "type": "function_definition", "text": "void xorshift1024_init(xorshift_prng_ctx_t* ctx) {\n const size_t num_bytes = 16 * sizeof(uint64_t);\n get_random_bytes_from_dev_urandom((uint8_t*)(ctx->s), num_bytes);\n ctx->p = 0;\n}", "parent": 27, "children": [123, 124], "start_point": {"row": 72, "column": 0}, "end_point": {"row": 76, "column": 1}}, {"id": 123, "type": "primitive_type", "text": "void", "parent": 122, "children": [], "start_point": {"row": 72, "column": 0}, "end_point": {"row": 72, "column": 4}}, {"id": 124, "type": "function_declarator", "text": "xorshift1024_init(xorshift_prng_ctx_t* ctx)", "parent": 122, "children": [125, 126], "start_point": {"row": 72, "column": 5}, "end_point": {"row": 72, "column": 48}}, {"id": 125, "type": "identifier", "text": "xorshift1024_init", "parent": 124, "children": [], "start_point": {"row": 72, "column": 5}, "end_point": {"row": 72, "column": 22}}, {"id": 126, "type": "parameter_list", "text": "(xorshift_prng_ctx_t* ctx)", "parent": 124, "children": [127], "start_point": {"row": 72, "column": 22}, "end_point": {"row": 72, "column": 48}}, {"id": 127, "type": "parameter_declaration", "text": "xorshift_prng_ctx_t* ctx", "parent": 126, "children": [128, 129], "start_point": {"row": 72, "column": 23}, "end_point": {"row": 72, "column": 47}}, {"id": 128, "type": "type_identifier", "text": "xorshift_prng_ctx_t", "parent": 127, "children": [], "start_point": {"row": 72, "column": 23}, "end_point": {"row": 72, "column": 42}}, {"id": 129, "type": "pointer_declarator", "text": "* ctx", "parent": 127, "children": [130, 131], "start_point": {"row": 72, "column": 42}, "end_point": {"row": 72, "column": 47}}, {"id": 130, "type": "*", "text": "*", "parent": 129, "children": [], "start_point": {"row": 72, "column": 42}, "end_point": {"row": 72, "column": 43}}, {"id": 131, "type": "identifier", "text": "ctx", "parent": 129, "children": [], "start_point": {"row": 72, "column": 44}, "end_point": {"row": 72, "column": 47}}, {"id": 132, "type": "declaration", "text": "const size_t num_bytes = 16 * sizeof(uint64_t);", "parent": 122, "children": [133, 134], "start_point": {"row": 73, "column": 4}, "end_point": {"row": 73, "column": 51}}, {"id": 133, "type": "primitive_type", "text": "size_t", "parent": 132, "children": [], "start_point": {"row": 73, "column": 10}, "end_point": {"row": 73, "column": 16}}, {"id": 134, "type": "init_declarator", "text": "num_bytes = 16 * sizeof(uint64_t)", "parent": 132, "children": [135, 136, 137], "start_point": {"row": 73, "column": 17}, "end_point": {"row": 73, "column": 50}}, {"id": 135, "type": "identifier", "text": "num_bytes", "parent": 134, "children": [], "start_point": {"row": 73, "column": 17}, "end_point": {"row": 73, "column": 26}}, {"id": 136, "type": "=", "text": "=", "parent": 134, "children": [], "start_point": {"row": 73, "column": 27}, "end_point": {"row": 73, "column": 28}}, {"id": 137, "type": "binary_expression", "text": "16 * sizeof(uint64_t)", "parent": 134, "children": [138, 139, 140], "start_point": {"row": 73, "column": 29}, "end_point": {"row": 73, "column": 50}}, {"id": 138, "type": "number_literal", "text": "16", "parent": 137, "children": [], "start_point": {"row": 73, "column": 29}, "end_point": {"row": 73, "column": 31}}, {"id": 139, "type": "*", "text": "*", "parent": 137, "children": [], "start_point": {"row": 73, "column": 32}, "end_point": {"row": 73, "column": 33}}, {"id": 140, "type": "sizeof_expression", "text": "sizeof(uint64_t)", "parent": 137, "children": [141], "start_point": {"row": 73, "column": 34}, "end_point": {"row": 73, "column": 50}}, {"id": 141, "type": "type_descriptor", "text": "uint64_t", "parent": 140, "children": [142], "start_point": {"row": 73, "column": 41}, "end_point": {"row": 73, "column": 49}}, {"id": 142, "type": "primitive_type", "text": "uint64_t", "parent": 141, "children": [], "start_point": {"row": 73, "column": 41}, "end_point": {"row": 73, "column": 49}}, {"id": 143, "type": "call_expression", "text": "get_random_bytes_from_dev_urandom((uint8_t*)(ctx->s), num_bytes)", "parent": 122, "children": [144, 145], "start_point": {"row": 74, "column": 4}, "end_point": {"row": 74, "column": 68}}, {"id": 144, "type": "identifier", "text": "get_random_bytes_from_dev_urandom", "parent": 143, "children": [], "start_point": {"row": 74, "column": 4}, "end_point": {"row": 74, "column": 37}}, {"id": 145, "type": "argument_list", "text": "((uint8_t*)(ctx->s), num_bytes)", "parent": 143, "children": [146, 155], "start_point": {"row": 74, "column": 37}, "end_point": {"row": 74, "column": 68}}, {"id": 146, "type": "cast_expression", "text": "(uint8_t*)(ctx->s)", "parent": 145, "children": [147, 151], "start_point": {"row": 74, "column": 38}, "end_point": {"row": 74, "column": 56}}, {"id": 147, "type": "type_descriptor", "text": "uint8_t*", "parent": 146, "children": [148, 149], "start_point": {"row": 74, "column": 39}, "end_point": {"row": 74, "column": 47}}, {"id": 148, "type": "primitive_type", "text": "uint8_t", "parent": 147, "children": [], "start_point": {"row": 74, "column": 39}, "end_point": {"row": 74, "column": 46}}, {"id": 149, "type": "abstract_pointer_declarator", "text": "*", "parent": 147, "children": [150], "start_point": {"row": 74, "column": 46}, "end_point": {"row": 74, "column": 47}}, {"id": 150, "type": "*", "text": "*", "parent": 149, "children": [], "start_point": {"row": 74, "column": 46}, "end_point": {"row": 74, "column": 47}}, {"id": 151, "type": "parenthesized_expression", "text": "(ctx->s)", "parent": 146, "children": [152], "start_point": {"row": 74, "column": 48}, "end_point": {"row": 74, "column": 56}}, {"id": 152, "type": "field_expression", "text": "ctx->s", "parent": 151, "children": [153, 154], "start_point": {"row": 74, "column": 49}, "end_point": {"row": 74, "column": 55}}, {"id": 153, "type": "identifier", "text": "ctx", "parent": 152, "children": [], "start_point": {"row": 74, "column": 49}, "end_point": {"row": 74, "column": 52}}, {"id": 154, "type": "field_identifier", "text": "s", "parent": 152, "children": [], "start_point": {"row": 74, "column": 54}, "end_point": {"row": 74, "column": 55}}, {"id": 155, "type": "identifier", "text": "num_bytes", "parent": 145, "children": [], "start_point": {"row": 74, "column": 58}, "end_point": {"row": 74, "column": 67}}, {"id": 156, "type": "assignment_expression", "text": "ctx->p = 0", "parent": 122, "children": [157, 160, 161], "start_point": {"row": 75, "column": 4}, "end_point": {"row": 75, "column": 14}}, {"id": 157, "type": "field_expression", "text": "ctx->p", "parent": 156, "children": [158, 159], "start_point": {"row": 75, "column": 4}, "end_point": {"row": 75, "column": 10}}, {"id": 158, "type": "identifier", "text": "ctx", "parent": 157, "children": [], "start_point": {"row": 75, "column": 4}, "end_point": {"row": 75, "column": 7}}, {"id": 159, "type": "field_identifier", "text": "p", "parent": 157, "children": [], "start_point": {"row": 75, "column": 9}, "end_point": {"row": 75, "column": 10}}, {"id": 160, "type": "=", "text": "=", "parent": 156, "children": [], "start_point": {"row": 75, "column": 11}, "end_point": {"row": 75, "column": 12}}, {"id": 161, "type": "number_literal", "text": "0", "parent": 156, "children": [], "start_point": {"row": 75, "column": 13}, "end_point": {"row": 75, "column": 14}}, {"id": 162, "type": "function_definition", "text": "uint64_t xorshift1024_next(xorshift_prng_ctx_t* ctx) {\n const uint64_t s0 = ctx->s[ctx->p];\n uint64_t s1 = ctx->s[ctx->p = (ctx->p + 1) & 15];\n s1 ^= s1 << 31; // a\n ctx->s[ctx->p] = s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30); // b,c\n return ctx->s[ctx->p] * UINT64_C(1181783497276652981);\n}", "parent": 27, "children": [163, 164], "start_point": {"row": 80, "column": 0}, "end_point": {"row": 86, "column": 1}}, {"id": 163, "type": "primitive_type", "text": "uint64_t", "parent": 162, "children": [], "start_point": {"row": 80, "column": 0}, "end_point": {"row": 80, "column": 8}}, {"id": 164, "type": "function_declarator", "text": "xorshift1024_next(xorshift_prng_ctx_t* ctx)", "parent": 162, "children": [165, 166], "start_point": {"row": 80, "column": 9}, "end_point": {"row": 80, "column": 52}}, {"id": 165, "type": "identifier", "text": "xorshift1024_next", "parent": 164, "children": [], "start_point": {"row": 80, "column": 9}, "end_point": {"row": 80, "column": 26}}, {"id": 166, "type": "parameter_list", "text": "(xorshift_prng_ctx_t* ctx)", "parent": 164, "children": [167], "start_point": {"row": 80, "column": 26}, "end_point": {"row": 80, "column": 52}}, {"id": 167, "type": "parameter_declaration", "text": "xorshift_prng_ctx_t* ctx", "parent": 166, "children": [168, 169], "start_point": {"row": 80, "column": 27}, "end_point": {"row": 80, "column": 51}}, {"id": 168, "type": "type_identifier", "text": "xorshift_prng_ctx_t", "parent": 167, "children": [], "start_point": {"row": 80, "column": 27}, "end_point": {"row": 80, "column": 46}}, {"id": 169, "type": "pointer_declarator", "text": "* ctx", "parent": 167, "children": [170, 171], "start_point": {"row": 80, "column": 46}, "end_point": {"row": 80, "column": 51}}, {"id": 170, "type": "*", "text": "*", "parent": 169, "children": [], "start_point": {"row": 80, "column": 46}, "end_point": {"row": 80, "column": 47}}, {"id": 171, "type": "identifier", "text": "ctx", "parent": 169, "children": [], "start_point": {"row": 80, "column": 48}, "end_point": {"row": 80, "column": 51}}, {"id": 172, "type": "declaration", "text": "const uint64_t s0 = ctx->s[ctx->p];", "parent": 162, "children": [173, 174], "start_point": {"row": 81, "column": 4}, "end_point": {"row": 81, "column": 39}}, {"id": 173, "type": "primitive_type", "text": "uint64_t", "parent": 172, "children": [], "start_point": {"row": 81, "column": 10}, "end_point": {"row": 81, "column": 18}}, {"id": 174, "type": "init_declarator", "text": "s0 = ctx->s[ctx->p]", "parent": 172, "children": [175, 176, 177], "start_point": {"row": 81, "column": 19}, "end_point": {"row": 81, "column": 38}}, {"id": 175, "type": "identifier", "text": "s0", "parent": 174, "children": [], "start_point": {"row": 81, "column": 19}, "end_point": {"row": 81, "column": 21}}, {"id": 176, "type": "=", "text": "=", "parent": 174, "children": [], "start_point": {"row": 81, "column": 22}, "end_point": {"row": 81, "column": 23}}, {"id": 177, "type": "subscript_expression", "text": "ctx->s[ctx->p]", "parent": 174, "children": [178, 181], "start_point": {"row": 81, "column": 24}, "end_point": {"row": 81, "column": 38}}, {"id": 178, "type": "field_expression", "text": "ctx->s", "parent": 177, "children": [179, 180], "start_point": {"row": 81, "column": 24}, "end_point": {"row": 81, "column": 30}}, {"id": 179, "type": "identifier", "text": "ctx", "parent": 178, "children": [], "start_point": {"row": 81, "column": 24}, "end_point": {"row": 81, "column": 27}}, {"id": 180, "type": "field_identifier", "text": "s", "parent": 178, "children": [], "start_point": {"row": 81, "column": 29}, "end_point": {"row": 81, "column": 30}}, {"id": 181, "type": "field_expression", "text": "ctx->p", "parent": 177, "children": [182, 183], "start_point": {"row": 81, "column": 31}, "end_point": {"row": 81, "column": 37}}, {"id": 182, "type": "identifier", "text": "ctx", "parent": 181, "children": [], "start_point": {"row": 81, "column": 31}, "end_point": {"row": 81, "column": 34}}, {"id": 183, "type": "field_identifier", "text": "p", "parent": 181, "children": [], "start_point": {"row": 81, "column": 36}, "end_point": {"row": 81, "column": 37}}, {"id": 184, "type": "declaration", "text": "uint64_t s1 = ctx->s[ctx->p = (ctx->p + 1) & 15];", "parent": 162, "children": [185, 186], "start_point": {"row": 82, "column": 4}, "end_point": {"row": 82, "column": 53}}, {"id": 185, "type": "primitive_type", "text": "uint64_t", "parent": 184, "children": [], "start_point": {"row": 82, "column": 4}, "end_point": {"row": 82, "column": 12}}, {"id": 186, "type": "init_declarator", "text": "s1 = ctx->s[ctx->p = (ctx->p + 1) & 15]", "parent": 184, "children": [187, 188, 189], "start_point": {"row": 82, "column": 13}, "end_point": {"row": 82, "column": 52}}, {"id": 187, "type": "identifier", "text": "s1", "parent": 186, "children": [], "start_point": {"row": 82, "column": 13}, "end_point": {"row": 82, "column": 15}}, {"id": 188, "type": "=", "text": "=", "parent": 186, "children": [], "start_point": {"row": 82, "column": 16}, "end_point": {"row": 82, "column": 17}}, {"id": 189, "type": "subscript_expression", "text": "ctx->s[ctx->p = (ctx->p + 1) & 15]", "parent": 186, "children": [190, 193], "start_point": {"row": 82, "column": 18}, "end_point": {"row": 82, "column": 52}}, {"id": 190, "type": "field_expression", "text": "ctx->s", "parent": 189, "children": [191, 192], "start_point": {"row": 82, "column": 18}, "end_point": {"row": 82, "column": 24}}, {"id": 191, "type": "identifier", "text": "ctx", "parent": 190, "children": [], "start_point": {"row": 82, "column": 18}, "end_point": {"row": 82, "column": 21}}, {"id": 192, "type": "field_identifier", "text": "s", "parent": 190, "children": [], "start_point": {"row": 82, "column": 23}, "end_point": {"row": 82, "column": 24}}, {"id": 193, "type": "assignment_expression", "text": "ctx->p = (ctx->p + 1) & 15", "parent": 189, "children": [194, 197, 198], "start_point": {"row": 82, "column": 25}, "end_point": {"row": 82, "column": 51}}, {"id": 194, "type": "field_expression", "text": "ctx->p", "parent": 193, "children": [195, 196], "start_point": {"row": 82, "column": 25}, "end_point": {"row": 82, "column": 31}}, {"id": 195, "type": "identifier", "text": "ctx", "parent": 194, "children": [], "start_point": {"row": 82, "column": 25}, "end_point": {"row": 82, "column": 28}}, {"id": 196, "type": "field_identifier", "text": "p", "parent": 194, "children": [], "start_point": {"row": 82, "column": 30}, "end_point": {"row": 82, "column": 31}}, {"id": 197, "type": "=", "text": "=", "parent": 193, "children": [], "start_point": {"row": 82, "column": 32}, "end_point": {"row": 82, "column": 33}}, {"id": 198, "type": "binary_expression", "text": "(ctx->p + 1) & 15", "parent": 193, "children": [199, 206], "start_point": {"row": 82, "column": 34}, "end_point": {"row": 82, "column": 51}}, {"id": 199, "type": "parenthesized_expression", "text": "(ctx->p + 1)", "parent": 198, "children": [200], "start_point": {"row": 82, "column": 34}, "end_point": {"row": 82, "column": 46}}, {"id": 200, "type": "binary_expression", "text": "ctx->p + 1", "parent": 199, "children": [201, 204, 205], "start_point": {"row": 82, "column": 35}, "end_point": {"row": 82, "column": 45}}, {"id": 201, "type": "field_expression", "text": "ctx->p", "parent": 200, "children": [202, 203], "start_point": {"row": 82, "column": 35}, "end_point": {"row": 82, "column": 41}}, {"id": 202, "type": "identifier", "text": "ctx", "parent": 201, "children": [], "start_point": {"row": 82, "column": 35}, "end_point": {"row": 82, "column": 38}}, {"id": 203, "type": "field_identifier", "text": "p", "parent": 201, "children": [], "start_point": {"row": 82, "column": 40}, "end_point": {"row": 82, "column": 41}}, {"id": 204, "type": "+", "text": "+", "parent": 200, "children": [], "start_point": {"row": 82, "column": 42}, "end_point": {"row": 82, "column": 43}}, {"id": 205, "type": "number_literal", "text": "1", "parent": 200, "children": [], "start_point": {"row": 82, "column": 44}, "end_point": {"row": 82, "column": 45}}, {"id": 206, "type": "number_literal", "text": "15", "parent": 198, "children": [], "start_point": {"row": 82, "column": 49}, "end_point": {"row": 82, "column": 51}}, {"id": 207, "type": "assignment_expression", "text": "s1 ^= s1 << 31", "parent": 162, "children": [208, 209, 210], "start_point": {"row": 83, "column": 4}, "end_point": {"row": 83, "column": 18}}, {"id": 208, "type": "identifier", "text": "s1", "parent": 207, "children": [], "start_point": {"row": 83, "column": 4}, "end_point": {"row": 83, "column": 6}}, {"id": 209, "type": "^=", "text": "^=", "parent": 207, "children": [], "start_point": {"row": 83, "column": 7}, "end_point": {"row": 83, "column": 9}}, {"id": 210, "type": "binary_expression", "text": "s1 << 31", "parent": 207, "children": [211, 212, 213], "start_point": {"row": 83, "column": 10}, "end_point": {"row": 83, "column": 18}}, {"id": 211, "type": "identifier", "text": "s1", "parent": 210, "children": [], "start_point": {"row": 83, "column": 10}, "end_point": {"row": 83, "column": 12}}, {"id": 212, "type": "<<", "text": "<<", "parent": 210, "children": [], "start_point": {"row": 83, "column": 13}, "end_point": {"row": 83, "column": 15}}, {"id": 213, "type": "number_literal", "text": "31", "parent": 210, "children": [], "start_point": {"row": 83, "column": 16}, "end_point": {"row": 83, "column": 18}}, {"id": 214, "type": "assignment_expression", "text": "ctx->s[ctx->p] = s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30)", "parent": 162, "children": [215, 222, 223], "start_point": {"row": 84, "column": 4}, "end_point": {"row": 84, "column": 54}}, {"id": 215, "type": "subscript_expression", "text": "ctx->s[ctx->p]", "parent": 214, "children": [216, 219], "start_point": {"row": 84, "column": 4}, "end_point": {"row": 84, "column": 18}}, {"id": 216, "type": "field_expression", "text": "ctx->s", "parent": 215, "children": [217, 218], "start_point": {"row": 84, "column": 4}, "end_point": {"row": 84, "column": 10}}, {"id": 217, "type": "identifier", "text": "ctx", "parent": 216, "children": [], "start_point": {"row": 84, "column": 4}, "end_point": {"row": 84, "column": 7}}, {"id": 218, "type": "field_identifier", "text": "s", "parent": 216, "children": [], "start_point": {"row": 84, "column": 9}, "end_point": {"row": 84, "column": 10}}, {"id": 219, "type": "field_expression", "text": "ctx->p", "parent": 215, "children": [220, 221], "start_point": {"row": 84, "column": 11}, "end_point": {"row": 84, "column": 17}}, {"id": 220, "type": "identifier", "text": "ctx", "parent": 219, "children": [], "start_point": {"row": 84, "column": 11}, "end_point": {"row": 84, "column": 14}}, {"id": 221, "type": "field_identifier", "text": "p", "parent": 219, "children": [], "start_point": {"row": 84, "column": 16}, "end_point": {"row": 84, "column": 17}}, {"id": 222, "type": "=", "text": "=", "parent": 214, "children": [], "start_point": {"row": 84, "column": 19}, "end_point": {"row": 84, "column": 20}}, {"id": 223, "type": "binary_expression", "text": "s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30)", "parent": 214, "children": [224, 235, 236], "start_point": {"row": 84, "column": 21}, "end_point": {"row": 84, "column": 54}}, {"id": 224, "type": "binary_expression", "text": "s1 ^ s0 ^ (s1 >> 11)", "parent": 223, "children": [225, 229, 230], "start_point": {"row": 84, "column": 21}, "end_point": {"row": 84, "column": 41}}, {"id": 225, "type": "binary_expression", "text": "s1 ^ s0", "parent": 224, "children": [226, 227, 228], "start_point": {"row": 84, "column": 21}, "end_point": {"row": 84, "column": 28}}, {"id": 226, "type": "identifier", "text": "s1", "parent": 225, "children": [], "start_point": {"row": 84, "column": 21}, "end_point": {"row": 84, "column": 23}}, {"id": 227, "type": "^", "text": "^", "parent": 225, "children": [], "start_point": {"row": 84, "column": 24}, "end_point": {"row": 84, "column": 25}}, {"id": 228, "type": "identifier", "text": "s0", "parent": 225, "children": [], "start_point": {"row": 84, "column": 26}, "end_point": {"row": 84, "column": 28}}, {"id": 229, "type": "^", "text": "^", "parent": 224, "children": [], "start_point": {"row": 84, "column": 29}, "end_point": {"row": 84, "column": 30}}, {"id": 230, "type": "parenthesized_expression", "text": "(s1 >> 11)", "parent": 224, "children": [231], "start_point": {"row": 84, "column": 31}, "end_point": {"row": 84, "column": 41}}, {"id": 231, "type": "binary_expression", "text": "s1 >> 11", "parent": 230, "children": [232, 233, 234], "start_point": {"row": 84, "column": 32}, "end_point": {"row": 84, "column": 40}}, {"id": 232, "type": "identifier", "text": "s1", "parent": 231, "children": [], "start_point": {"row": 84, "column": 32}, "end_point": {"row": 84, "column": 34}}, {"id": 233, "type": ">>", "text": ">>", "parent": 231, "children": [], "start_point": {"row": 84, "column": 35}, "end_point": {"row": 84, "column": 37}}, {"id": 234, "type": "number_literal", "text": "11", "parent": 231, "children": [], "start_point": {"row": 84, "column": 38}, "end_point": {"row": 84, "column": 40}}, {"id": 235, "type": "^", "text": "^", "parent": 223, "children": [], "start_point": {"row": 84, "column": 42}, "end_point": {"row": 84, "column": 43}}, {"id": 236, "type": "parenthesized_expression", "text": "(s0 >> 30)", "parent": 223, "children": [237], "start_point": {"row": 84, "column": 44}, "end_point": {"row": 84, "column": 54}}, {"id": 237, "type": "binary_expression", "text": "s0 >> 30", "parent": 236, "children": [238, 239, 240], "start_point": {"row": 84, "column": 45}, "end_point": {"row": 84, "column": 53}}, {"id": 238, "type": "identifier", "text": "s0", "parent": 237, "children": [], "start_point": {"row": 84, "column": 45}, "end_point": {"row": 84, "column": 47}}, {"id": 239, "type": ">>", "text": ">>", "parent": 237, "children": [], "start_point": {"row": 84, "column": 48}, "end_point": {"row": 84, "column": 50}}, {"id": 240, "type": "number_literal", "text": "30", "parent": 237, "children": [], "start_point": {"row": 84, "column": 51}, "end_point": {"row": 84, "column": 53}}, {"id": 241, "type": "return_statement", "text": "return ctx->s[ctx->p] * UINT64_C(1181783497276652981);", "parent": 162, "children": [242], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 58}}, {"id": 242, "type": "binary_expression", "text": "ctx->s[ctx->p] * UINT64_C(1181783497276652981)", "parent": 241, "children": [243, 250, 251], "start_point": {"row": 85, "column": 11}, "end_point": {"row": 85, "column": 57}}, {"id": 243, "type": "subscript_expression", "text": "ctx->s[ctx->p]", "parent": 242, "children": [244, 247], "start_point": {"row": 85, "column": 11}, "end_point": {"row": 85, "column": 25}}, {"id": 244, "type": "field_expression", "text": "ctx->s", "parent": 243, "children": [245, 246], "start_point": {"row": 85, "column": 11}, "end_point": {"row": 85, "column": 17}}, {"id": 245, "type": "identifier", "text": "ctx", "parent": 244, "children": [], "start_point": {"row": 85, "column": 11}, "end_point": {"row": 85, "column": 14}}, {"id": 246, "type": "field_identifier", "text": "s", "parent": 244, "children": [], "start_point": {"row": 85, "column": 16}, "end_point": {"row": 85, "column": 17}}, {"id": 247, "type": "field_expression", "text": "ctx->p", "parent": 243, "children": [248, 249], "start_point": {"row": 85, "column": 18}, "end_point": {"row": 85, "column": 24}}, {"id": 248, "type": "identifier", "text": "ctx", "parent": 247, "children": [], "start_point": {"row": 85, "column": 18}, "end_point": {"row": 85, "column": 21}}, {"id": 249, "type": "field_identifier", "text": "p", "parent": 247, "children": [], "start_point": {"row": 85, "column": 23}, "end_point": {"row": 85, "column": 24}}, {"id": 250, "type": "*", "text": "*", "parent": 242, "children": [], "start_point": {"row": 85, "column": 26}, "end_point": {"row": 85, "column": 27}}, {"id": 251, "type": "call_expression", "text": "UINT64_C(1181783497276652981)", "parent": 242, "children": [252, 253], "start_point": {"row": 85, "column": 28}, "end_point": {"row": 85, "column": 57}}, {"id": 252, "type": "identifier", "text": "UINT64_C", "parent": 251, "children": [], "start_point": {"row": 85, "column": 28}, "end_point": {"row": 85, "column": 36}}, {"id": 253, "type": "argument_list", "text": "(1181783497276652981)", "parent": 251, "children": [254], "start_point": {"row": 85, "column": 36}, "end_point": {"row": 85, "column": 57}}, {"id": 254, "type": "number_literal", "text": "1181783497276652981", "parent": 253, "children": [], "start_point": {"row": 85, "column": 37}, "end_point": {"row": 85, "column": 56}}, {"id": 255, "type": "function_definition", "text": "void get_random_bytes(xorshift_prng_ctx_t *ctx,\n uint8_t* data,\n const size_t num_bytes) {\n const size_t wordsize = sizeof(uint64_t);\n const size_t num_words = num_bytes / wordsize;\n\n for (size_t i = 0; i < num_words; ++i) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + i * wordsize, &word, wordsize);\n }\n\n const size_t num_bytes_remaining = num_bytes - num_words * wordsize;\n\n if (num_bytes_remaining > 0) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + num_words * wordsize, &word, num_bytes_remaining);\n }\n}", "parent": 27, "children": [256, 257], "start_point": {"row": 90, "column": 0}, "end_point": {"row": 107, "column": 1}}, {"id": 256, "type": "primitive_type", "text": "void", "parent": 255, "children": [], "start_point": {"row": 90, "column": 0}, "end_point": {"row": 90, "column": 4}}, {"id": 257, "type": "function_declarator", "text": "get_random_bytes(xorshift_prng_ctx_t *ctx,\n uint8_t* data,\n const size_t num_bytes)", "parent": 255, "children": [258, 259], "start_point": {"row": 90, "column": 5}, "end_point": {"row": 92, "column": 45}}, {"id": 258, "type": "identifier", "text": "get_random_bytes", "parent": 257, "children": [], "start_point": {"row": 90, "column": 5}, "end_point": {"row": 90, "column": 21}}, {"id": 259, "type": "parameter_list", "text": "(xorshift_prng_ctx_t *ctx,\n uint8_t* data,\n const size_t num_bytes)", "parent": 257, "children": [260, 265, 270], "start_point": {"row": 90, "column": 21}, "end_point": {"row": 92, "column": 45}}, {"id": 260, "type": "parameter_declaration", "text": "xorshift_prng_ctx_t *ctx", "parent": 259, "children": [261, 262], "start_point": {"row": 90, "column": 22}, "end_point": {"row": 90, "column": 46}}, {"id": 261, "type": "type_identifier", "text": "xorshift_prng_ctx_t", "parent": 260, "children": [], "start_point": {"row": 90, "column": 22}, "end_point": {"row": 90, "column": 41}}, {"id": 262, "type": "pointer_declarator", "text": "*ctx", "parent": 260, "children": [263, 264], "start_point": {"row": 90, "column": 42}, "end_point": {"row": 90, "column": 46}}, {"id": 263, "type": "*", "text": "*", "parent": 262, "children": [], "start_point": {"row": 90, "column": 42}, "end_point": {"row": 90, "column": 43}}, {"id": 264, "type": "identifier", "text": "ctx", "parent": 262, "children": [], "start_point": {"row": 90, "column": 43}, "end_point": {"row": 90, "column": 46}}, {"id": 265, "type": "parameter_declaration", "text": "uint8_t* data", "parent": 259, "children": [266, 267], "start_point": {"row": 91, "column": 22}, "end_point": {"row": 91, "column": 35}}, {"id": 266, "type": "primitive_type", "text": "uint8_t", "parent": 265, "children": [], "start_point": {"row": 91, "column": 22}, "end_point": {"row": 91, "column": 29}}, {"id": 267, "type": "pointer_declarator", "text": "* data", "parent": 265, "children": [268, 269], "start_point": {"row": 91, "column": 29}, "end_point": {"row": 91, "column": 35}}, {"id": 268, "type": "*", "text": "*", "parent": 267, "children": [], "start_point": {"row": 91, "column": 29}, "end_point": {"row": 91, "column": 30}}, {"id": 269, "type": "identifier", "text": "data", "parent": 267, "children": [], "start_point": {"row": 91, "column": 31}, "end_point": {"row": 91, "column": 35}}, {"id": 270, "type": "parameter_declaration", "text": "const size_t num_bytes", "parent": 259, "children": [271, 272], "start_point": {"row": 92, "column": 22}, "end_point": {"row": 92, "column": 44}}, {"id": 271, "type": "primitive_type", "text": "size_t", "parent": 270, "children": [], "start_point": {"row": 92, "column": 28}, "end_point": {"row": 92, "column": 34}}, {"id": 272, "type": "identifier", "text": "num_bytes", "parent": 270, "children": [], "start_point": {"row": 92, "column": 35}, "end_point": {"row": 92, "column": 44}}, {"id": 273, "type": "declaration", "text": "const size_t wordsize = sizeof(uint64_t);", "parent": 255, "children": [274, 275], "start_point": {"row": 93, "column": 4}, "end_point": {"row": 93, "column": 45}}, {"id": 274, "type": "primitive_type", "text": "size_t", "parent": 273, "children": [], "start_point": {"row": 93, "column": 10}, "end_point": {"row": 93, "column": 16}}, {"id": 275, "type": "init_declarator", "text": "wordsize = sizeof(uint64_t)", "parent": 273, "children": [276, 277, 278], "start_point": {"row": 93, "column": 17}, "end_point": {"row": 93, "column": 44}}, {"id": 276, "type": "identifier", "text": "wordsize", "parent": 275, "children": [], "start_point": {"row": 93, "column": 17}, "end_point": {"row": 93, "column": 25}}, {"id": 277, "type": "=", "text": "=", "parent": 275, "children": [], "start_point": {"row": 93, "column": 26}, "end_point": {"row": 93, "column": 27}}, {"id": 278, "type": "sizeof_expression", "text": "sizeof(uint64_t)", "parent": 275, "children": [279], "start_point": {"row": 93, "column": 28}, "end_point": {"row": 93, "column": 44}}, {"id": 279, "type": "type_descriptor", "text": "uint64_t", "parent": 278, "children": [280], "start_point": {"row": 93, "column": 35}, "end_point": {"row": 93, "column": 43}}, {"id": 280, "type": "primitive_type", "text": "uint64_t", "parent": 279, "children": [], "start_point": {"row": 93, "column": 35}, "end_point": {"row": 93, "column": 43}}, {"id": 281, "type": "declaration", "text": "const size_t num_words = num_bytes / wordsize;", "parent": 255, "children": [282, 283], "start_point": {"row": 94, "column": 4}, "end_point": {"row": 94, "column": 50}}, {"id": 282, "type": "primitive_type", "text": "size_t", "parent": 281, "children": [], "start_point": {"row": 94, "column": 10}, "end_point": {"row": 94, "column": 16}}, {"id": 283, "type": "init_declarator", "text": "num_words = num_bytes / wordsize", "parent": 281, "children": [284, 285, 286], "start_point": {"row": 94, "column": 17}, "end_point": {"row": 94, "column": 49}}, {"id": 284, "type": "identifier", "text": "num_words", "parent": 283, "children": [], "start_point": {"row": 94, "column": 17}, "end_point": {"row": 94, "column": 26}}, {"id": 285, "type": "=", "text": "=", "parent": 283, "children": [], "start_point": {"row": 94, "column": 27}, "end_point": {"row": 94, "column": 28}}, {"id": 286, "type": "binary_expression", "text": "num_bytes / wordsize", "parent": 283, "children": [287, 288, 289], "start_point": {"row": 94, "column": 29}, "end_point": {"row": 94, "column": 49}}, {"id": 287, "type": "identifier", "text": "num_bytes", "parent": 286, "children": [], "start_point": {"row": 94, "column": 29}, "end_point": {"row": 94, "column": 38}}, {"id": 288, "type": "/", "text": "/", "parent": 286, "children": [], "start_point": {"row": 94, "column": 39}, "end_point": {"row": 94, "column": 40}}, {"id": 289, "type": "identifier", "text": "wordsize", "parent": 286, "children": [], "start_point": {"row": 94, "column": 41}, "end_point": {"row": 94, "column": 49}}, {"id": 290, "type": "for_statement", "text": "for (size_t i = 0; i < num_words; ++i) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + i * wordsize, &word, wordsize);\n }", "parent": 255, "children": [291, 297, 301], "start_point": {"row": 96, "column": 4}, "end_point": {"row": 99, "column": 5}}, {"id": 291, "type": "declaration", "text": "size_t i = 0;", "parent": 290, "children": [292, 293], "start_point": {"row": 96, "column": 9}, "end_point": {"row": 96, "column": 22}}, {"id": 292, "type": "primitive_type", "text": "size_t", "parent": 291, "children": [], "start_point": {"row": 96, "column": 9}, "end_point": {"row": 96, "column": 15}}, {"id": 293, "type": "init_declarator", "text": "i = 0", "parent": 291, "children": [294, 295, 296], "start_point": {"row": 96, "column": 16}, "end_point": {"row": 96, "column": 21}}, {"id": 294, "type": "identifier", "text": "i", "parent": 293, "children": [], "start_point": {"row": 96, "column": 16}, "end_point": {"row": 96, "column": 17}}, {"id": 295, "type": "=", "text": "=", "parent": 293, "children": [], "start_point": {"row": 96, "column": 18}, "end_point": {"row": 96, "column": 19}}, {"id": 296, "type": "number_literal", "text": "0", "parent": 293, "children": [], "start_point": {"row": 96, "column": 20}, "end_point": {"row": 96, "column": 21}}, {"id": 297, "type": "binary_expression", "text": "i < num_words", "parent": 290, "children": [298, 299, 300], "start_point": {"row": 96, "column": 23}, "end_point": {"row": 96, "column": 36}}, {"id": 298, "type": "identifier", "text": "i", "parent": 297, "children": [], "start_point": {"row": 96, "column": 23}, "end_point": {"row": 96, "column": 24}}, {"id": 299, "type": "<", "text": "<", "parent": 297, "children": [], "start_point": {"row": 96, "column": 25}, "end_point": {"row": 96, "column": 26}}, {"id": 300, "type": "identifier", "text": "num_words", "parent": 297, "children": [], "start_point": {"row": 96, "column": 27}, "end_point": {"row": 96, "column": 36}}, {"id": 301, "type": "update_expression", "text": "++i", "parent": 290, "children": [302, 303], "start_point": {"row": 96, "column": 38}, "end_point": {"row": 96, "column": 41}}, {"id": 302, "type": "++", "text": "++", "parent": 301, "children": [], "start_point": {"row": 96, "column": 38}, "end_point": {"row": 96, "column": 40}}, {"id": 303, "type": "identifier", "text": "i", "parent": 301, "children": [], "start_point": {"row": 96, "column": 40}, "end_point": {"row": 96, "column": 41}}, {"id": 304, "type": "declaration", "text": "const uint64_t word = xorshift1024_next(ctx);", "parent": 290, "children": [305, 306], "start_point": {"row": 97, "column": 8}, "end_point": {"row": 97, "column": 53}}, {"id": 305, "type": "primitive_type", "text": "uint64_t", "parent": 304, "children": [], "start_point": {"row": 97, "column": 14}, "end_point": {"row": 97, "column": 22}}, {"id": 306, "type": "init_declarator", "text": "word = xorshift1024_next(ctx)", "parent": 304, "children": [307, 308, 309], "start_point": {"row": 97, "column": 23}, "end_point": {"row": 97, "column": 52}}, {"id": 307, "type": "identifier", "text": "word", "parent": 306, "children": [], "start_point": {"row": 97, "column": 23}, "end_point": {"row": 97, "column": 27}}, {"id": 308, "type": "=", "text": "=", "parent": 306, "children": [], "start_point": {"row": 97, "column": 28}, "end_point": {"row": 97, "column": 29}}, {"id": 309, "type": "call_expression", "text": "xorshift1024_next(ctx)", "parent": 306, "children": [310, 311], "start_point": {"row": 97, "column": 30}, "end_point": {"row": 97, "column": 52}}, {"id": 310, "type": "identifier", "text": "xorshift1024_next", "parent": 309, "children": [], "start_point": {"row": 97, "column": 30}, "end_point": {"row": 97, "column": 47}}, {"id": 311, "type": "argument_list", "text": "(ctx)", "parent": 309, "children": [312], "start_point": {"row": 97, "column": 47}, "end_point": {"row": 97, "column": 52}}, {"id": 312, "type": "identifier", "text": "ctx", "parent": 311, "children": [], "start_point": {"row": 97, "column": 48}, "end_point": {"row": 97, "column": 51}}, {"id": 313, "type": "call_expression", "text": "memcpy(data + i * wordsize, &word, wordsize)", "parent": 290, "children": [314, 315], "start_point": {"row": 98, "column": 8}, "end_point": {"row": 98, "column": 52}}, {"id": 314, "type": "identifier", "text": "memcpy", "parent": 313, "children": [], "start_point": {"row": 98, "column": 8}, "end_point": {"row": 98, "column": 14}}, {"id": 315, "type": "argument_list", "text": "(data + i * wordsize, &word, wordsize)", "parent": 313, "children": [316, 323, 325], "start_point": {"row": 98, "column": 14}, "end_point": {"row": 98, "column": 52}}, {"id": 316, "type": "binary_expression", "text": "data + i * wordsize", "parent": 315, "children": [317, 318, 319], "start_point": {"row": 98, "column": 15}, "end_point": {"row": 98, "column": 34}}, {"id": 317, "type": "identifier", "text": "data", "parent": 316, "children": [], "start_point": {"row": 98, "column": 15}, "end_point": {"row": 98, "column": 19}}, {"id": 318, "type": "+", "text": "+", "parent": 316, "children": [], "start_point": {"row": 98, "column": 20}, "end_point": {"row": 98, "column": 21}}, {"id": 319, "type": "binary_expression", "text": "i * wordsize", "parent": 316, "children": [320, 321, 322], "start_point": {"row": 98, "column": 22}, "end_point": {"row": 98, "column": 34}}, {"id": 320, "type": "identifier", "text": "i", "parent": 319, "children": [], "start_point": {"row": 98, "column": 22}, "end_point": {"row": 98, "column": 23}}, {"id": 321, "type": "*", "text": "*", "parent": 319, "children": [], "start_point": {"row": 98, "column": 24}, "end_point": {"row": 98, "column": 25}}, {"id": 322, "type": "identifier", "text": "wordsize", "parent": 319, "children": [], "start_point": {"row": 98, "column": 26}, "end_point": {"row": 98, "column": 34}}, {"id": 323, "type": "pointer_expression", "text": "&word", "parent": 315, "children": [324], "start_point": {"row": 98, "column": 36}, "end_point": {"row": 98, "column": 41}}, {"id": 324, "type": "identifier", "text": "word", "parent": 323, "children": [], "start_point": {"row": 98, "column": 37}, "end_point": {"row": 98, "column": 41}}, {"id": 325, "type": "identifier", "text": "wordsize", "parent": 315, "children": [], "start_point": {"row": 98, "column": 43}, "end_point": {"row": 98, "column": 51}}, {"id": 326, "type": "declaration", "text": "const size_t num_bytes_remaining = num_bytes - num_words * wordsize;", "parent": 255, "children": [327, 328], "start_point": {"row": 101, "column": 4}, "end_point": {"row": 101, "column": 72}}, {"id": 327, "type": "primitive_type", "text": "size_t", "parent": 326, "children": [], "start_point": {"row": 101, "column": 10}, "end_point": {"row": 101, "column": 16}}, {"id": 328, "type": "init_declarator", "text": "num_bytes_remaining = num_bytes - num_words * wordsize", "parent": 326, "children": [329, 330, 331], "start_point": {"row": 101, "column": 17}, "end_point": {"row": 101, "column": 71}}, {"id": 329, "type": "identifier", "text": "num_bytes_remaining", "parent": 328, "children": [], "start_point": {"row": 101, "column": 17}, "end_point": {"row": 101, "column": 36}}, {"id": 330, "type": "=", "text": "=", "parent": 328, "children": [], "start_point": {"row": 101, "column": 37}, "end_point": {"row": 101, "column": 38}}, {"id": 331, "type": "binary_expression", "text": "num_bytes - num_words * wordsize", "parent": 328, "children": [332, 333, 334], "start_point": {"row": 101, "column": 39}, "end_point": {"row": 101, "column": 71}}, {"id": 332, "type": "identifier", "text": "num_bytes", "parent": 331, "children": [], "start_point": {"row": 101, "column": 39}, "end_point": {"row": 101, "column": 48}}, {"id": 333, "type": "-", "text": "-", "parent": 331, "children": [], "start_point": {"row": 101, "column": 49}, "end_point": {"row": 101, "column": 50}}, {"id": 334, "type": "binary_expression", "text": "num_words * wordsize", "parent": 331, "children": [335, 336, 337], "start_point": {"row": 101, "column": 51}, "end_point": {"row": 101, "column": 71}}, {"id": 335, "type": "identifier", "text": "num_words", "parent": 334, "children": [], "start_point": {"row": 101, "column": 51}, "end_point": {"row": 101, "column": 60}}, {"id": 336, "type": "*", "text": "*", "parent": 334, "children": [], "start_point": {"row": 101, "column": 61}, "end_point": {"row": 101, "column": 62}}, {"id": 337, "type": "identifier", "text": "wordsize", "parent": 334, "children": [], "start_point": {"row": 101, "column": 63}, "end_point": {"row": 101, "column": 71}}, {"id": 338, "type": "if_statement", "text": "if (num_bytes_remaining > 0) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + num_words * wordsize, &word, num_bytes_remaining);\n }", "parent": 255, "children": [339], "start_point": {"row": 103, "column": 4}, "end_point": {"row": 106, "column": 5}}, {"id": 339, "type": "parenthesized_expression", "text": "(num_bytes_remaining > 0)", "parent": 338, "children": [340], "start_point": {"row": 103, "column": 7}, "end_point": {"row": 103, "column": 32}}, {"id": 340, "type": "binary_expression", "text": "num_bytes_remaining > 0", "parent": 339, "children": [341, 342, 343], "start_point": {"row": 103, "column": 8}, "end_point": {"row": 103, "column": 31}}, {"id": 341, "type": "identifier", "text": "num_bytes_remaining", "parent": 340, "children": [], "start_point": {"row": 103, "column": 8}, "end_point": {"row": 103, "column": 27}}, {"id": 342, "type": ">", "text": ">", "parent": 340, "children": [], "start_point": {"row": 103, "column": 28}, "end_point": {"row": 103, "column": 29}}, {"id": 343, "type": "number_literal", "text": "0", "parent": 340, "children": [], "start_point": {"row": 103, "column": 30}, "end_point": {"row": 103, "column": 31}}, {"id": 344, "type": "declaration", "text": "const uint64_t word = xorshift1024_next(ctx);", "parent": 338, "children": [345, 346], "start_point": {"row": 104, "column": 8}, "end_point": {"row": 104, "column": 53}}, {"id": 345, "type": "primitive_type", "text": "uint64_t", "parent": 344, "children": [], "start_point": {"row": 104, "column": 14}, "end_point": {"row": 104, "column": 22}}, {"id": 346, "type": "init_declarator", "text": "word = xorshift1024_next(ctx)", "parent": 344, "children": [347, 348, 349], "start_point": {"row": 104, "column": 23}, "end_point": {"row": 104, "column": 52}}, {"id": 347, "type": "identifier", "text": "word", "parent": 346, "children": [], "start_point": {"row": 104, "column": 23}, "end_point": {"row": 104, "column": 27}}, {"id": 348, "type": "=", "text": "=", "parent": 346, "children": [], "start_point": {"row": 104, "column": 28}, "end_point": {"row": 104, "column": 29}}, {"id": 349, "type": "call_expression", "text": "xorshift1024_next(ctx)", "parent": 346, "children": [350, 351], "start_point": {"row": 104, "column": 30}, "end_point": {"row": 104, "column": 52}}, {"id": 350, "type": "identifier", "text": "xorshift1024_next", "parent": 349, "children": [], "start_point": {"row": 104, "column": 30}, "end_point": {"row": 104, "column": 47}}, {"id": 351, "type": "argument_list", "text": "(ctx)", "parent": 349, "children": [352], "start_point": {"row": 104, "column": 47}, "end_point": {"row": 104, "column": 52}}, {"id": 352, "type": "identifier", "text": "ctx", "parent": 351, "children": [], "start_point": {"row": 104, "column": 48}, "end_point": {"row": 104, "column": 51}}, {"id": 353, "type": "call_expression", "text": "memcpy(data + num_words * wordsize, &word, num_bytes_remaining)", "parent": 338, "children": [354, 355], "start_point": {"row": 105, "column": 8}, "end_point": {"row": 105, "column": 71}}, {"id": 354, "type": "identifier", "text": "memcpy", "parent": 353, "children": [], "start_point": {"row": 105, "column": 8}, "end_point": {"row": 105, "column": 14}}, {"id": 355, "type": "argument_list", "text": "(data + num_words * wordsize, &word, num_bytes_remaining)", "parent": 353, "children": [356, 363, 365], "start_point": {"row": 105, "column": 14}, "end_point": {"row": 105, "column": 71}}, {"id": 356, "type": "binary_expression", "text": "data + num_words * wordsize", "parent": 355, "children": [357, 358, 359], "start_point": {"row": 105, "column": 15}, "end_point": {"row": 105, "column": 42}}, {"id": 357, "type": "identifier", "text": "data", "parent": 356, "children": [], "start_point": {"row": 105, "column": 15}, "end_point": {"row": 105, "column": 19}}, {"id": 358, "type": "+", "text": "+", "parent": 356, "children": [], "start_point": {"row": 105, "column": 20}, "end_point": {"row": 105, "column": 21}}, {"id": 359, "type": "binary_expression", "text": "num_words * wordsize", "parent": 356, "children": [360, 361, 362], "start_point": {"row": 105, "column": 22}, "end_point": {"row": 105, "column": 42}}, {"id": 360, "type": "identifier", "text": "num_words", "parent": 359, "children": [], "start_point": {"row": 105, "column": 22}, "end_point": {"row": 105, "column": 31}}, {"id": 361, "type": "*", "text": "*", "parent": 359, "children": [], "start_point": {"row": 105, "column": 32}, "end_point": {"row": 105, "column": 33}}, {"id": 362, "type": "identifier", "text": "wordsize", "parent": 359, "children": [], "start_point": {"row": 105, "column": 34}, "end_point": {"row": 105, "column": 42}}, {"id": 363, "type": "pointer_expression", "text": "&word", "parent": 355, "children": [364], "start_point": {"row": 105, "column": 44}, "end_point": {"row": 105, "column": 49}}, {"id": 364, "type": "identifier", "text": "word", "parent": 363, "children": [], "start_point": {"row": 105, "column": 45}, "end_point": {"row": 105, "column": 49}}, {"id": 365, "type": "identifier", "text": "num_bytes_remaining", "parent": 355, "children": [], "start_point": {"row": 105, "column": 51}, "end_point": {"row": 105, "column": 70}}, {"id": 366, "type": "function_definition", "text": "void get_random_bytes(uint8_t* data,\n const size_t num_bytes) {\n xorshift_prng_ctx_t ctx;\n xorshift1024_init(&ctx);\n get_random_bytes(&ctx, data, num_bytes);\n}", "parent": 27, "children": [367, 368], "start_point": {"row": 111, "column": 0}, "end_point": {"row": 116, "column": 1}}, {"id": 367, "type": "primitive_type", "text": "void", "parent": 366, "children": [], "start_point": {"row": 111, "column": 0}, "end_point": {"row": 111, "column": 4}}, {"id": 368, "type": "function_declarator", "text": "get_random_bytes(uint8_t* data,\n const size_t num_bytes)", "parent": 366, "children": [369, 370], "start_point": {"row": 111, "column": 5}, "end_point": {"row": 112, "column": 45}}, {"id": 369, "type": "identifier", "text": "get_random_bytes", "parent": 368, "children": [], "start_point": {"row": 111, "column": 5}, "end_point": {"row": 111, "column": 21}}, {"id": 370, "type": "parameter_list", "text": "(uint8_t* data,\n const size_t num_bytes)", "parent": 368, "children": [371, 376], "start_point": {"row": 111, "column": 21}, "end_point": {"row": 112, "column": 45}}, {"id": 371, "type": "parameter_declaration", "text": "uint8_t* data", "parent": 370, "children": [372, 373], "start_point": {"row": 111, "column": 22}, "end_point": {"row": 111, "column": 35}}, {"id": 372, "type": "primitive_type", "text": "uint8_t", "parent": 371, "children": [], "start_point": {"row": 111, "column": 22}, "end_point": {"row": 111, "column": 29}}, {"id": 373, "type": "pointer_declarator", "text": "* data", "parent": 371, "children": [374, 375], "start_point": {"row": 111, "column": 29}, "end_point": {"row": 111, "column": 35}}, {"id": 374, "type": "*", "text": "*", "parent": 373, "children": [], "start_point": {"row": 111, "column": 29}, "end_point": {"row": 111, "column": 30}}, {"id": 375, "type": "identifier", "text": "data", "parent": 373, "children": [], "start_point": {"row": 111, "column": 31}, "end_point": {"row": 111, "column": 35}}, {"id": 376, "type": "parameter_declaration", "text": "const size_t num_bytes", "parent": 370, "children": [377, 378], "start_point": {"row": 112, "column": 22}, "end_point": {"row": 112, "column": 44}}, {"id": 377, "type": "primitive_type", "text": "size_t", "parent": 376, "children": [], "start_point": {"row": 112, "column": 28}, "end_point": {"row": 112, "column": 34}}, {"id": 378, "type": "identifier", "text": "num_bytes", "parent": 376, "children": [], "start_point": {"row": 112, "column": 35}, "end_point": {"row": 112, "column": 44}}, {"id": 379, "type": "declaration", "text": "xorshift_prng_ctx_t ctx;", "parent": 366, "children": [380, 381], "start_point": {"row": 113, "column": 4}, "end_point": {"row": 113, "column": 28}}, {"id": 380, "type": "type_identifier", "text": "xorshift_prng_ctx_t", "parent": 379, "children": [], "start_point": {"row": 113, "column": 4}, "end_point": {"row": 113, "column": 23}}, {"id": 381, "type": "identifier", "text": "ctx", "parent": 379, "children": [], "start_point": {"row": 113, "column": 24}, "end_point": {"row": 113, "column": 27}}, {"id": 382, "type": "call_expression", "text": "xorshift1024_init(&ctx)", "parent": 366, "children": [383, 384], "start_point": {"row": 114, "column": 4}, "end_point": {"row": 114, "column": 27}}, {"id": 383, "type": "identifier", "text": "xorshift1024_init", "parent": 382, "children": [], "start_point": {"row": 114, "column": 4}, "end_point": {"row": 114, "column": 21}}, {"id": 384, "type": "argument_list", "text": "(&ctx)", "parent": 382, "children": [385], "start_point": {"row": 114, "column": 21}, "end_point": {"row": 114, "column": 27}}, {"id": 385, "type": "pointer_expression", "text": "&ctx", "parent": 384, "children": [386], "start_point": {"row": 114, "column": 22}, "end_point": {"row": 114, "column": 26}}, {"id": 386, "type": "identifier", "text": "ctx", "parent": 385, "children": [], "start_point": {"row": 114, "column": 23}, "end_point": {"row": 114, "column": 26}}, {"id": 387, "type": "call_expression", "text": "get_random_bytes(&ctx, data, num_bytes)", "parent": 366, "children": [388, 389], "start_point": {"row": 115, "column": 4}, "end_point": {"row": 115, "column": 43}}, {"id": 388, "type": "identifier", "text": "get_random_bytes", "parent": 387, "children": [], "start_point": {"row": 115, "column": 4}, "end_point": {"row": 115, "column": 20}}, {"id": 389, "type": "argument_list", "text": "(&ctx, data, num_bytes)", "parent": 387, "children": [390, 392, 393], "start_point": {"row": 115, "column": 20}, "end_point": {"row": 115, "column": 43}}, {"id": 390, "type": "pointer_expression", "text": "&ctx", "parent": 389, "children": [391], "start_point": {"row": 115, "column": 21}, "end_point": {"row": 115, "column": 25}}, {"id": 391, "type": "identifier", "text": "ctx", "parent": 390, "children": [], "start_point": {"row": 115, "column": 22}, "end_point": {"row": 115, "column": 25}}, {"id": 392, "type": "identifier", "text": "data", "parent": 389, "children": [], "start_point": {"row": 115, "column": 27}, "end_point": {"row": 115, "column": 31}}, {"id": 393, "type": "identifier", "text": "num_bytes", "parent": 389, "children": [], "start_point": {"row": 115, "column": 33}, "end_point": {"row": 115, "column": 42}}]}, "node_categories": {"declarations": {"functions": [27, 43, 45, 122, 124, 162, 164, 255, 257, 366, 368], "variables": [30, 34, 39, 48, 53, 56, 66, 78, 127, 132, 167, 172, 184, 260, 265, 270, 273, 281, 291, 304, 326, 344, 371, 376, 379], "classes": [32, 33], "imports": [3, 4, 6, 7, 9, 10, 12, 13, 15, 16, 18, 19, 21, 22, 24, 25], "modules": [], "enums": []}, "statements": {"expressions": [61, 73, 74, 83, 87, 91, 96, 97, 101, 105, 109, 118, 137, 140, 143, 146, 151, 152, 157, 177, 178, 181, 189, 190, 194, 198, 199, 200, 201, 210, 215, 216, 219, 223, 224, 225, 230, 231, 236, 237, 242, 243, 244, 247, 251, 278, 286, 297, 301, 309, 313, 316, 319, 323, 331, 334, 339, 340, 349, 353, 356, 359, 363, 382, 385, 387, 390], "assignments": [114, 156, 193, 207, 214], "loops": [72, 290], "conditionals": [28, 29, 37, 41, 42, 46, 52, 55, 59, 62, 65, 69, 75, 77, 81, 84, 86, 88, 90, 92, 94, 95, 98, 102, 106, 108, 110, 112, 115, 117, 119, 121, 125, 128, 131, 135, 144, 153, 154, 155, 158, 159, 165, 168, 171, 175, 179, 180, 182, 183, 187, 191, 192, 195, 196, 202, 203, 208, 211, 217, 218, 220, 221, 226, 228, 232, 238, 245, 246, 248, 249, 252, 258, 261, 264, 269, 272, 276, 284, 287, 289, 294, 298, 300, 303, 307, 310, 312, 314, 317, 320, 322, 324, 325, 329, 332, 335, 337, 338, 341, 347, 350, 352, 354, 357, 360, 362, 364, 365, 369, 375, 378, 380, 381, 383, 386, 388, 391, 392, 393], "returns": [241], "exceptions": []}, "expressions": {"calls": [0], "literals": [5, 8, 11, 14, 17, 20, 23, 26, 38, 64, 71, 100, 104, 138, 161, 205, 206, 213, 234, 240, 254, 296, 343], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 27, "universal_type": "function", "name": "{", "text_snippet": "namespace utils {\n// ---------------------------------------------------------\n\ntypedef struct {\n "}, {"node_id": 43, "universal_type": "function", "name": "get_random_bytes_from_dev_urandom", "text_snippet": "void get_random_bytes_from_dev_urandom(uint8_t* data, size_t num_bytes) {\n int gathered_bytes = o"}, {"node_id": 45, "universal_type": "function", "name": "unknown", "text_snippet": "get_random_bytes_from_dev_urandom(uint8_t* data, size_t num_bytes)"}, {"node_id": 122, "universal_type": "function", "name": "xorshift1024_init", "text_snippet": "void xorshift1024_init(xorshift_prng_ctx_t* ctx) {\n const size_t num_bytes = 16 * sizeof(uint64_t"}, {"node_id": 124, "universal_type": "function", "name": "unknown", "text_snippet": "xorshift1024_init(xorshift_prng_ctx_t* ctx)"}, {"node_id": 162, "universal_type": "function", "name": "unknown", "text_snippet": "uint64_t xorshift1024_next(xorshift_prng_ctx_t* ctx) {\n const uint64_t s0 = ctx->s[ctx->p];\n u"}, {"node_id": 164, "universal_type": "function", "name": "unknown", "text_snippet": "xorshift1024_next(xorshift_prng_ctx_t* ctx)"}, {"node_id": 255, "universal_type": "function", "name": "get_random_bytes", "text_snippet": "void get_random_bytes(xorshift_prng_ctx_t *ctx,\n uint8_t* data,\n "}, {"node_id": 257, "universal_type": "function", "name": "unknown", "text_snippet": "get_random_bytes(xorshift_prng_ctx_t *ctx,\n uint8_t* data,\n "}, {"node_id": 366, "universal_type": "function", "name": "get_random_bytes", "text_snippet": "void get_random_bytes(uint8_t* data,\n const size_t num_bytes) {\n xorshift_pr"}, {"node_id": 368, "universal_type": "function", "name": "unknown", "text_snippet": "get_random_bytes(uint8_t* data,\n const size_t num_bytes)"}], "class_declarations": [{"node_id": 32, "universal_type": "class", "name": "{", "text_snippet": "struct {\n uint64_t s[16]; \n int p;\n}"}, {"node_id": 33, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": [{"node_id": 3, "text": "#include <stdint.h>\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include <string.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <fcntl.h>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include <stdio.h>\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include <stdlib.h>\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include <sys/stat.h>\n"}, {"node_id": 19, "text": "#include"}, {"node_id": 21, "text": "#include <sys/types.h>\n"}, {"node_id": 22, "text": "#include"}, {"node_id": 24, "text": "#include <unistd.h>\n"}, {"node_id": 25, "text": "#include"}]}, "original_source_code": "/**\n * Written in 2014 by <NAME> (<EMAIL>)\n *\n * To the extent possible under law, the author has dedicated all copyright\n * and related and neighboring rights to this software to the public domain\n * worldwide. This software is distributed without any warranty.\n * \n * See <http://creativecommons.org/publicdomain/zero/1.0/>. \n * \n * This is a fast, top-quality generator. If 1024 bits of state are too\n much, try a xoroshiro128+ generator.\n\n Note that the three lowest bits of this generator are LSFRs, and thus\n they are slightly less random than the other bits. We suggest to use a\n sign test to extract a random Boolean value.\n\n The state must be seeded so that it is not everywhere zero. If you have\n a 64-bit seed, we suggest to seed a splitmix64 generator and use its\n output to fill s.\n */\n\n#pragma once\n\n// ---------------------------------------------------------\n\n#include <stdint.h>\n#include <string.h>\n\n#include <fcntl.h>\n#include <stdio.h>\n#include <stdlib.h>\n#include <sys/stat.h>\n#include <sys/types.h>\n#include <unistd.h>\n\n// ---------------------------------------------------------\n\nnamespace utils {\n// ---------------------------------------------------------\n\ntypedef struct {\n uint64_t s[16]; \n int p;\n} xorshift_prng_ctx_t;\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes_from_dev_urandom(uint8_t* data, size_t num_bytes) {\n int gathered_bytes = open(\"/dev/urandom\", O_RDONLY);\n size_t len = 0;\n\n while (len < num_bytes) {\n ssize_t num_gathered_bytes = read(\n gathered_bytes, \n data + len, \n num_bytes - len\n );\n\n if (num_gathered_bytes < 0) {\n puts(\"Error, unable to read stream\");\n close(gathered_bytes);\n exit(EXIT_FAILURE);\n } else {\n len += num_gathered_bytes;\n }\n }\n\n close(gathered_bytes);\n}\n\n// ---------------------------------------------------------\n\nvoid xorshift1024_init(xorshift_prng_ctx_t* ctx) {\n const size_t num_bytes = 16 * sizeof(uint64_t);\n get_random_bytes_from_dev_urandom((uint8_t*)(ctx->s), num_bytes);\n ctx->p = 0;\n}\n\n// ---------------------------------------------------------\n\nuint64_t xorshift1024_next(xorshift_prng_ctx_t* ctx) {\n const uint64_t s0 = ctx->s[ctx->p];\n uint64_t s1 = ctx->s[ctx->p = (ctx->p + 1) & 15];\n s1 ^= s1 << 31; // a\n ctx->s[ctx->p] = s1 ^ s0 ^ (s1 >> 11) ^ (s0 >> 30); // b,c\n return ctx->s[ctx->p] * UINT64_C(1181783497276652981);\n}\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes(xorshift_prng_ctx_t *ctx,\n uint8_t* data,\n const size_t num_bytes) {\n const size_t wordsize = sizeof(uint64_t);\n const size_t num_words = num_bytes / wordsize;\n\n for (size_t i = 0; i < num_words; ++i) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + i * wordsize, &word, wordsize);\n }\n\n const size_t num_bytes_remaining = num_bytes - num_words * wordsize;\n\n if (num_bytes_remaining > 0) {\n const uint64_t word = xorshift1024_next(ctx);\n memcpy(data + num_words * wordsize, &word, num_bytes_remaining);\n }\n}\n\n// ---------------------------------------------------------\n\nvoid get_random_bytes(uint8_t* data,\n const size_t num_bytes) {\n xorshift_prng_ctx_t ctx;\n xorshift1024_init(&ctx);\n get_random_bytes(&ctx, data, num_bytes);\n}\n\n} // namespace utils\n"}
80,521
c
// // CMSHuShenGangTongCapitalFlowViewModel.h // CMSPaaS // // Created by sway on 2021/2/26. // #import <Foundation/Foundation.h> #import "CMSQuotesCellViewModel.h" #import "CMSHuShenGangTongCapitalFlowView.h" NS_ASSUME_NONNULL_BEGIN @interface CMSHuShenGangTongCapitalFlowViewModel : CMSQuotesCellViewModel @property (nonatomic, strong) NSArray <CMSHuShenGangTongCapitalFlowItem*> *capitalFlows; //数据更新日期 @property (nonatomic, strong) NSString *subTitle; //获取沪深港通数据 - (void)getHuShenGangTongCapitalFlowsData; @end NS_ASSUME_NONNULL_END
29.06
18
(translation_unit) "//\n// CMSHuShenGangTongCapitalFlowViewModel.h\n// CMSPaaS\n//\n// Created by sway on 2021/2/26.\n//\n\n#import <Foundation/Foundation.h>\n#import "CMSQuotesCellViewModel.h"\n#import "CMSHuShenGangTongCapitalFlowView.h"\nNS_ASSUME_NONNULL_BEGIN\n\n@interface CMSHuShenGangTongCapitalFlowViewModel : CMSQuotesCellViewModel\n@property (nonatomic, strong) NSArray <CMSHuShenGangTongCapitalFlowItem*> *capitalFlows;\n//数据更新日期\n@property (nonatomic, strong) NSString *subTitle;\n//获取沪深港通数据\n- (void)getHuShenGangTongCapitalFlowsData;\n\n@end\n\nNS_ASSUME_NONNULL_END\n" (comment) "//" (comment) "// CMSHuShenGangTongCapitalFlowViewModel.h" (comment) "// CMSPaaS" (comment) "//" (comment) "// Created by sway on 2021/2/26." (comment) "//" (preproc_call) "#import <Foundation/Foundation.h>\n" (preproc_directive) "#import" (preproc_arg) "<Foundation/Foundation.h>" (preproc_call) "#import "CMSQuotesCellViewModel.h"\n" (preproc_directive) "#import" (preproc_arg) ""CMSQuotesCellViewModel.h"" (preproc_call) "#import "CMSHuShenGangTongCapitalFlowView.h"\n" (preproc_directive) "#import" (preproc_arg) ""CMSHuShenGangTongCapitalFlowView.h"" (declaration) "NS_ASSUME_NONNULL_BEGIN\n\n@interface" (type_identifier) "NS_ASSUME_NONNULL_BEGIN" (ERROR) "@" (ERROR) "@" (identifier) "interface" (;) "" (ERROR) "CMSHuShenGangTongCapitalFlowViewModel : CMSQuotesCellViewModel\n@property (nonatomic, strong) NSArray <CMSHuShenGangTongCapitalFlowItem*> *capitalFlows;\n//数据更新日期\n@property (no" (binary_expression) "CMSHuShenGangTongCapitalFlowViewModel : CMSQuotesCellViewModel\n@property (nonatomic, strong) NSArray <CMSHuShenGangTongCapitalFlowItem*> *capitalFlows" (binary_expression) "CMSHuShenGangTongCapitalFlowViewModel : CMSQuotesCellViewModel\n@property (nonatomic, strong) NSArray <CMSHuShenGangTongCapitalFlowItem" (identifier) "CMSHuShenGangTongCapitalFlowViewModel" (ERROR) ": CMSQuotesCellViewModel\n@property (nonatomic, strong) NSArray" (:) ":" (type_identifier) "CMSQuotesCellViewModel" (ERROR) "@" (ERROR) "@" (function_declarator) "property (nonatomic, strong) NSArray" (identifier) "property" (parameter_list) "(nonatomic, strong)" (() "(" (parameter_declaration) "nonatomic" (type_identifier) "nonatomic" (,) "," (parameter_declaration) "strong" (type_identifier) "strong" ()) ")" (identifier) "NSArray" (<) "<" (identifier) "CMSHuShenGangTongCapitalFlowItem" (ERROR) "*" (*) "*" (>) ">" (pointer_expression) "*capitalFlows" (*) "*" (identifier) "capitalFlows" (;) ";" (comment) "//数据更新日期\n@property (" (ERROR) "o" (expression_statement) "natomic, strong) NSString *" (call_expression) "natomic, strong) NSString *" (identifier) "natomic," (argument_list) "strong) NSString *" (() "s" (identifier) "trong) NS" (,) "S" (identifier) "ring " ()) "*" (;) "" (declaration) "ubTitle;\n//获取沪深港通数据\n" (type_identifier) "ubTitle;" (pointer_declarator) "/获取沪深港通数据" (*) "/" (identifier) "获取沪深港通数据" (;) "\n" (comment) " (void)getHuShenGangTongCa" (expression_statement) "italFlowsData;\n\n@end\n\nNS_ASSUME_NONNULL_EN" (unary_expression) "italFlowsData;\n\n@end\n\nNS_ASSUME_NONNULL_E" (-) "i" (cast_expression) "alFlowsData;\n\n@end\n\nNS_ASSUME_NONNULL_E" (() "a" (type_descriptor) "lFlo" (primitive_type) "lFlo" ()) "w" (identifier) "sData;\n\n@end\n\nNS_ASSUME_NONNULL_E" (;) "N" (ERROR) "" (ERROR) "" (declaration) "" (type_identifier) "" (identifier) "" (;) ""
86
10
{"language": "c", "success": true, "metadata": {"lines": 18, "avg_line_length": 29.06, "nodes": 60, "errors": 0, "source_hash": "10baa4a2efe5edebc5fdade86ba51cb3b9d7199d1bd69d0b60c792711e16ad91", "categorized_nodes": 33}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#import <Foundation/Foundation.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#import", "parent": 0, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "<Foundation/Foundation.h>", "parent": 0, "children": [], "start_point": {"row": 7, "column": 8}, "end_point": {"row": 7, "column": 33}}, {"id": 3, "type": "preproc_call", "text": "#import \"CMSQuotesCellViewModel.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 4, "type": "preproc_directive", "text": "#import", "parent": 3, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 7}}, {"id": 5, "type": "preproc_arg", "text": "\"CMSQuotesCellViewModel.h\"", "parent": 3, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 34}}, {"id": 6, "type": "preproc_call", "text": "#import \"CMSHuShenGangTongCapitalFlowView.h\"\n", "parent": null, "children": [7, 8], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 7, "type": "preproc_directive", "text": "#import", "parent": 6, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 7}}, {"id": 8, "type": "preproc_arg", "text": "\"CMSHuShenGangTongCapitalFlowView.h\"", "parent": 6, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 44}}, {"id": 9, "type": "declaration", "text": "NS_ASSUME_NONNULL_BEGIN\n\n@interface", "parent": null, "children": [10, 11, 13], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 12, "column": 10}}, {"id": 10, "type": "type_identifier", "text": "NS_ASSUME_NONNULL_BEGIN", "parent": 9, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 23}}, {"id": 11, "type": "ERROR", "text": "@", "parent": 9, "children": [12], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 1}}, {"id": 12, "type": "ERROR", "text": "@", "parent": 11, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 1}}, {"id": 13, "type": "identifier", "text": "interface", "parent": 9, "children": [], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 10}}, {"id": 14, "type": "ERROR", "text": "CMSHuShenGangTongCapitalFlowViewModel : CMSQuotesCellViewModel\n@property (nonatomic, strong) NSArray <CMSHuShenGangTongCapitalFlowItem*> *capitalFlows;\n//\u6570\u636e\u66f4\u65b0\u65e5\u671f\n@property (no", "parent": null, "children": [15, 38], "start_point": {"row": 12, "column": 11}, "end_point": {"row": 15, "column": 1}}, {"id": 15, "type": "binary_expression", "text": "CMSHuShenGangTongCapitalFlowViewModel : CMSQuotesCellViewModel\n@property (nonatomic, strong) NSArray <CMSHuShenGangTongCapitalFlowItem*> *capitalFlows", "parent": 14, "children": [16, 32, 34, 35], "start_point": {"row": 12, "column": 11}, "end_point": {"row": 13, "column": 87}}, {"id": 16, "type": "binary_expression", "text": "CMSHuShenGangTongCapitalFlowViewModel : CMSQuotesCellViewModel\n@property (nonatomic, strong) NSArray <CMSHuShenGangTongCapitalFlowItem", "parent": 15, "children": [17, 18, 30, 31], "start_point": {"row": 12, "column": 11}, "end_point": {"row": 13, "column": 71}}, {"id": 17, "type": "identifier", "text": "CMSHuShenGangTongCapitalFlowViewModel", "parent": 16, "children": [], "start_point": {"row": 12, "column": 11}, "end_point": {"row": 12, "column": 48}}, {"id": 18, "type": "ERROR", "text": ": CMSQuotesCellViewModel\n@property (nonatomic, strong) NSArray", "parent": 16, "children": [19, 20, 22], "start_point": {"row": 12, "column": 49}, "end_point": {"row": 13, "column": 37}}, {"id": 19, "type": "type_identifier", "text": "CMSQuotesCellViewModel", "parent": 18, "children": [], "start_point": {"row": 12, "column": 51}, "end_point": {"row": 12, "column": 73}}, {"id": 20, "type": "ERROR", "text": "@", "parent": 18, "children": [21], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 21, "type": "ERROR", "text": "@", "parent": 20, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 22, "type": "function_declarator", "text": "property (nonatomic, strong) NSArray", "parent": 18, "children": [23, 24, 29], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 37}}, {"id": 23, "type": "identifier", "text": "property", "parent": 22, "children": [], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 9}}, {"id": 24, "type": "parameter_list", "text": "(nonatomic, strong)", "parent": 22, "children": [25, 27], "start_point": {"row": 13, "column": 10}, "end_point": {"row": 13, "column": 29}}, {"id": 25, "type": "parameter_declaration", "text": "nonatomic", "parent": 24, "children": [26], "start_point": {"row": 13, "column": 11}, "end_point": {"row": 13, "column": 20}}, {"id": 26, "type": "type_identifier", "text": "nonatomic", "parent": 25, "children": [], "start_point": {"row": 13, "column": 11}, "end_point": {"row": 13, "column": 20}}, {"id": 27, "type": "parameter_declaration", "text": "strong", "parent": 24, "children": [28], "start_point": {"row": 13, "column": 22}, "end_point": {"row": 13, "column": 28}}, {"id": 28, "type": "type_identifier", "text": "strong", "parent": 27, "children": [], "start_point": {"row": 13, "column": 22}, "end_point": {"row": 13, "column": 28}}, {"id": 29, "type": "identifier", "text": "NSArray", "parent": 22, "children": [], "start_point": {"row": 13, "column": 30}, "end_point": {"row": 13, "column": 37}}, {"id": 30, "type": "<", "text": "<", "parent": 16, "children": [], "start_point": {"row": 13, "column": 38}, "end_point": {"row": 13, "column": 39}}, {"id": 31, "type": "identifier", "text": "CMSHuShenGangTongCapitalFlowItem", "parent": 16, "children": [], "start_point": {"row": 13, "column": 39}, "end_point": {"row": 13, "column": 71}}, {"id": 32, "type": "ERROR", "text": "*", "parent": 15, "children": [33], "start_point": {"row": 13, "column": 71}, "end_point": {"row": 13, "column": 72}}, {"id": 33, "type": "*", "text": "*", "parent": 32, "children": [], "start_point": {"row": 13, "column": 71}, "end_point": {"row": 13, "column": 72}}, {"id": 34, "type": ">", "text": ">", "parent": 15, "children": [], "start_point": {"row": 13, "column": 72}, "end_point": {"row": 13, "column": 73}}, {"id": 35, "type": "pointer_expression", "text": "*capitalFlows", "parent": 15, "children": [36, 37], "start_point": {"row": 13, "column": 74}, "end_point": {"row": 13, "column": 87}}, {"id": 36, "type": "*", "text": "*", "parent": 35, "children": [], "start_point": {"row": 13, "column": 74}, "end_point": {"row": 13, "column": 75}}, {"id": 37, "type": "identifier", "text": "capitalFlows", "parent": 35, "children": [], "start_point": {"row": 13, "column": 75}, "end_point": {"row": 13, "column": 87}}, {"id": 38, "type": "ERROR", "text": "o", "parent": 14, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 1}}, {"id": 39, "type": "call_expression", "text": "natomic, strong) NSString *", "parent": null, "children": [40, 41], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 29}}, {"id": 40, "type": "identifier", "text": "natomic,", "parent": 39, "children": [], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 9}}, {"id": 41, "type": "argument_list", "text": "strong) NSString *", "parent": 39, "children": [42, 43], "start_point": {"row": 15, "column": 10}, "end_point": {"row": 15, "column": 29}}, {"id": 42, "type": "identifier", "text": "trong) NS", "parent": 41, "children": [], "start_point": {"row": 15, "column": 11}, "end_point": {"row": 15, "column": 20}}, {"id": 43, "type": "identifier", "text": "ring ", "parent": 41, "children": [], "start_point": {"row": 15, "column": 22}, "end_point": {"row": 15, "column": 28}}, {"id": 44, "type": "declaration", "text": "ubTitle;\n//\u83b7\u53d6\u6caa\u6df1\u6e2f\u901a\u6570\u636e\n", "parent": null, "children": [45, 46], "start_point": {"row": 15, "column": 30}, "end_point": {"row": 15, "column": 50}}, {"id": 45, "type": "type_identifier", "text": "ubTitle;", "parent": 44, "children": [], "start_point": {"row": 15, "column": 30}, "end_point": {"row": 15, "column": 38}}, {"id": 46, "type": "pointer_declarator", "text": "/\u83b7\u53d6\u6caa\u6df1\u6e2f\u901a\u6570\u636e", "parent": 44, "children": [47, 48], "start_point": {"row": 15, "column": 40}, "end_point": {"row": 15, "column": 49}}, {"id": 47, "type": "*", "text": "/", "parent": 46, "children": [], "start_point": {"row": 15, "column": 40}, "end_point": {"row": 15, "column": 41}}, {"id": 48, "type": "identifier", "text": "\u83b7\u53d6\u6caa\u6df1\u6e2f\u901a\u6570\u636e", "parent": 46, "children": [], "start_point": {"row": 15, "column": 41}, "end_point": {"row": 15, "column": 49}}, {"id": 49, "type": "unary_expression", "text": "italFlowsData;\n\n@end\n\nNS_ASSUME_NONNULL_E", "parent": null, "children": [50, 51], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 41}}, {"id": 50, "type": "-", "text": "i", "parent": 49, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 51, "type": "cast_expression", "text": "alFlowsData;\n\n@end\n\nNS_ASSUME_NONNULL_E", "parent": 49, "children": [52, 54], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 17, "column": 41}}, {"id": 52, "type": "type_descriptor", "text": "lFlo", "parent": 51, "children": [53], "start_point": {"row": 17, "column": 3}, "end_point": {"row": 17, "column": 7}}, {"id": 53, "type": "primitive_type", "text": "lFlo", "parent": 52, "children": [], "start_point": {"row": 17, "column": 3}, "end_point": {"row": 17, "column": 7}}, {"id": 54, "type": "identifier", "text": "sData;\n\n@end\n\nNS_ASSUME_NONNULL_E", "parent": 51, "children": [], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 17, "column": 41}}, {"id": 55, "type": "ERROR", "text": "", "parent": null, "children": [56], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 1}}, {"id": 56, "type": "ERROR", "text": "", "parent": 55, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 1}}, {"id": 57, "type": "declaration", "text": "", "parent": null, "children": [58, 59], "start_point": {"row": 19, "column": 1}, "end_point": {"row": 21, "column": 21}}, {"id": 58, "type": "type_identifier", "text": "", "parent": 57, "children": [], "start_point": {"row": 19, "column": 1}, "end_point": {"row": 19, "column": 4}}, {"id": 59, "type": "identifier", "text": "", "parent": 57, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 21}}]}, "node_categories": {"declarations": {"functions": [22], "variables": [9, 25, 27, 44, 57], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [15, 16, 35, 39, 49, 51], "assignments": [], "loops": [], "conditionals": [10, 13, 17, 19, 23, 26, 28, 29, 31, 37, 40, 42, 43, 45, 48, 54, 58, 59], "returns": [], "exceptions": []}, "expressions": {"calls": [0, 3, 6], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 22, "universal_type": "function", "name": "unknown", "text_snippet": "property (nonatomic, strong) NSArray"}], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// CMSHuShenGangTongCapitalFlowViewModel.h\n// CMSPaaS\n//\n// Created by sway on 2021/2/26.\n//\n\n#import <Foundation/Foundation.h>\n#import \"CMSQuotesCellViewModel.h\"\n#import \"CMSHuShenGangTongCapitalFlowView.h\"\nNS_ASSUME_NONNULL_BEGIN\n\n@interface CMSHuShenGangTongCapitalFlowViewModel : CMSQuotesCellViewModel\n@property (nonatomic, strong) NSArray <CMSHuShenGangTongCapitalFlowItem*> *capitalFlows;\n//\u6570\u636e\u66f4\u65b0\u65e5\u671f\n@property (nonatomic, strong) NSString *subTitle;\n//\u83b7\u53d6\u6caa\u6df1\u6e2f\u901a\u6570\u636e\n- (void)getHuShenGangTongCapitalFlowsData;\n\n@end\n\nNS_ASSUME_NONNULL_END\n"}
80,522
c
// // DZLClassSingleton.h // DZLObjcAdditions // // Created by <NAME> on 23/05/2014. // Copyright (c) 2014 <NAME>. All rights reserved. // @interface NSObject () @property (nonatomic, strong) NSString *dzl_class_singleton; @end #define class_singleton(class, methodName) \ dynamic dzl_class_singleton; \ + (class *)methodName { \ static class *methodName; \ static dispatch_once_t onceToken; \ dispatch_once(&onceToken, ^{ \ methodName = [class new]; \ }); \ return methodName; \ } #define class_singleton_setup(class, methodName, setupCode) \ dynamic dzl_class_singleton; \ + (class *)methodName { \ static class *methodName; \ static dispatch_once_t onceToken; \ dispatch_once(&onceToken, ^{ \ methodName = [class new]; \ ({setupCode;});\ }); \ return methodName; \ }
31.04
24
(translation_unit) "//\n// DZLClassSingleton.h\n// DZLObjcAdditions\n//\n// Created by <NAME> on 23/05/2014.\n// Copyright (c) 2014 <NAME>. All rights reserved.\n//\n\n\n@interface NSObject ()\n@property (nonatomic, strong) NSString *dzl_class_singleton;\n@end\n\n#define class_singleton(class, methodName) \\ndynamic dzl_class_singleton; \\n+ (class *)methodName { \\nstatic class *methodName; \\nstatic dispatch_once_t onceToken; \\ndispatch_once(&onceToken, ^{ \\nmethodName = [class new]; \\n}); \\nreturn methodName; \\n}\n\n\n#define class_singleton_setup(class, methodName, setupCode) \\ndynamic dzl_class_singleton; \\n+ (class *)methodName { \\nstatic class *methodName; \\nstatic dispatch_once_t onceToken; \\ndispatch_once(&onceToken, ^{ \\nmethodName = [class new]; \\n({setupCode;});\\n}); \\nreturn methodName; \\n}\n" (comment) "//" (comment) "// DZLClassSingleton.h" (comment) "// DZLObjcAdditions" (comment) "//" (comment) "// Created by <NAME> on 23/05/2014." (comment) "// Copyright (c) 2014 <NAME>. All rights reserved." (comment) "//" (ERROR) "@interface NSObject ()\n@property (nonatomic, strong) NSString *dzl_class_singleton;\n@end" (ERROR) "@" (type_identifier) "interface" (function_declarator) "NSObject ()" (identifier) "NSObject" (parameter_list) "()" (() "(" ()) ")" (ERROR) "@" (ERROR) "@" (declaration) "property (nonatomic, strong) NSString *dzl_class_singleton;" (macro_type_specifier) "property (nonatomic, strong)" (identifier) "property" (() "(" (type_descriptor) "nonatomic" (type_identifier) "nonatomic" (ERROR) ", strong" (,) "," (identifier) "strong" ()) ")" (ERROR) "NSString" (identifier) "NSString" (pointer_declarator) "*dzl_class_singleton" (*) "*" (identifier) "dzl_class_singleton" (;) ";" (ERROR) "@" (ERROR) "@" (identifier) "end" (preproc_function_def) "#define class_singleton(class, methodName) \\ndynamic dzl_class_singleton; \\n+ (class *)methodName { \\nstatic class *methodName; \\nstatic dispatch_once_t onceToken; \\ndispatch_once(&onceToken, ^{ \\nmethodName = [class new]; \\n}); \\nreturn methodName; \\n}\n" (#define) "#define" (identifier) "class_singleton" (preproc_params) "(class, methodName)" (() "(" (identifier) "class" (,) "," (identifier) "methodName" ()) ")" (preproc_arg) "dynamic dzl_class_singleton; \\n+ (class *)methodName { \\nstatic class *methodName; \\nstatic dispatch_once_t onceToken; \\ndispatch_once(&onceToken, ^{ \\nmethodName = [class new]; \\n}); \\nreturn methodName; \\n}" (preproc_function_def) "#define class_singleton_setup(class, methodName, setupCode) \\ndynamic dzl_class_singleton; \\n+ (class *)methodName { \\nstatic class *methodName; \\nstatic dispatch_once_t onceToken; \\ndispatch_once(&onceToken, ^{ \\nmethodName = [class new]; \\n({setupCode;});\\n}); \\nreturn methodName; \\n}\n" (#define) "#define" (identifier) "class_singleton_setup" (preproc_params) "(class, methodName, setupCode)" (() "(" (identifier) "class" (,) "," (identifier) "methodName" (,) "," (identifier) "setupCode" ()) ")" (preproc_arg) "dynamic dzl_class_singleton; \\n+ (class *)methodName { \\nstatic class *methodName; \\nstatic dispatch_once_t onceToken; \\ndispatch_once(&onceToken, ^{ \\nmethodName = [class new]; \\n({setupCode;});\\n}); \\nreturn methodName; \\n}"
59
8
{"language": "c", "success": true, "metadata": {"lines": 24, "avg_line_length": 31.04, "nodes": 35, "errors": 0, "source_hash": "f6d5f10ec1a689c4725644bc5b9bccf562bc9b7b84990258072b1213275d96c9", "categorized_nodes": 17}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "ERROR", "text": "@interface NSObject ()\n@property (nonatomic, strong) NSString *dzl_class_singleton;\n@end", "parent": null, "children": [1, 2, 3, 6, 8, 20], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 11, "column": 4}}, {"id": 1, "type": "ERROR", "text": "@", "parent": 0, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 1}}, {"id": 2, "type": "type_identifier", "text": "interface", "parent": 0, "children": [], "start_point": {"row": 9, "column": 1}, "end_point": {"row": 9, "column": 10}}, {"id": 3, "type": "function_declarator", "text": "NSObject ()", "parent": 0, "children": [4, 5], "start_point": {"row": 9, "column": 11}, "end_point": {"row": 9, "column": 22}}, {"id": 4, "type": "identifier", "text": "NSObject", "parent": 3, "children": [], "start_point": {"row": 9, "column": 11}, "end_point": {"row": 9, "column": 19}}, {"id": 5, "type": "parameter_list", "text": "()", "parent": 3, "children": [], "start_point": {"row": 9, "column": 20}, "end_point": {"row": 9, "column": 22}}, {"id": 6, "type": "ERROR", "text": "@", "parent": 0, "children": [7], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 1}}, {"id": 7, "type": "ERROR", "text": "@", "parent": 6, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 1}}, {"id": 8, "type": "declaration", "text": "property (nonatomic, strong) NSString *dzl_class_singleton;", "parent": 0, "children": [9, 15, 17], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 60}}, {"id": 9, "type": "macro_type_specifier", "text": "property (nonatomic, strong)", "parent": 8, "children": [10, 11, 13], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 29}}, {"id": 10, "type": "identifier", "text": "property", "parent": 9, "children": [], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 9}}, {"id": 11, "type": "type_descriptor", "text": "nonatomic", "parent": 9, "children": [12], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 10, "column": 20}}, {"id": 12, "type": "type_identifier", "text": "nonatomic", "parent": 11, "children": [], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 10, "column": 20}}, {"id": 13, "type": "ERROR", "text": ", strong", "parent": 9, "children": [14], "start_point": {"row": 10, "column": 20}, "end_point": {"row": 10, "column": 28}}, {"id": 14, "type": "identifier", "text": "strong", "parent": 13, "children": [], "start_point": {"row": 10, "column": 22}, "end_point": {"row": 10, "column": 28}}, {"id": 15, "type": "ERROR", "text": "NSString", "parent": 8, "children": [16], "start_point": {"row": 10, "column": 30}, "end_point": {"row": 10, "column": 38}}, {"id": 16, "type": "identifier", "text": "NSString", "parent": 15, "children": [], "start_point": {"row": 10, "column": 30}, "end_point": {"row": 10, "column": 38}}, {"id": 17, "type": "pointer_declarator", "text": "*dzl_class_singleton", "parent": 8, "children": [18, 19], "start_point": {"row": 10, "column": 39}, "end_point": {"row": 10, "column": 59}}, {"id": 18, "type": "*", "text": "*", "parent": 17, "children": [], "start_point": {"row": 10, "column": 39}, "end_point": {"row": 10, "column": 40}}, {"id": 19, "type": "identifier", "text": "dzl_class_singleton", "parent": 17, "children": [], "start_point": {"row": 10, "column": 40}, "end_point": {"row": 10, "column": 59}}, {"id": 20, "type": "ERROR", "text": "@", "parent": 0, "children": [21], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 1}}, {"id": 21, "type": "ERROR", "text": "@", "parent": 20, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 1}}, {"id": 22, "type": "preproc_function_def", "text": "#define class_singleton(class, methodName) \\\ndynamic dzl_class_singleton; \\\n+ (class *)methodName { \\\nstatic class *methodName; \\\nstatic dispatch_once_t onceToken; \\\ndispatch_once(&onceToken, ^{ \\\nmethodName = [class new]; \\\n}); \\\nreturn methodName; \\\n}\n", "parent": null, "children": [23, 24, 25, 27], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 23, "column": 0}}, {"id": 23, "type": "#define", "text": "#define", "parent": 22, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 7}}, {"id": 24, "type": "identifier", "text": "class_singleton", "parent": 22, "children": [], "start_point": {"row": 13, "column": 8}, "end_point": {"row": 13, "column": 23}}, {"id": 25, "type": "preproc_params", "text": "(class, methodName)", "parent": 22, "children": [26], "start_point": {"row": 13, "column": 23}, "end_point": {"row": 13, "column": 42}}, {"id": 26, "type": "identifier", "text": "methodName", "parent": 25, "children": [], "start_point": {"row": 13, "column": 31}, "end_point": {"row": 13, "column": 41}}, {"id": 27, "type": "preproc_arg", "text": "dynamic dzl_class_singleton; \\\n+ (class *)methodName { \\\nstatic class *methodName; \\\nstatic dispatch_once_t onceToken; \\\ndispatch_once(&onceToken, ^{ \\\nmethodName = [class new]; \\\n}); \\\nreturn methodName; \\\n}", "parent": 22, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 22, "column": 1}}, {"id": 28, "type": "preproc_function_def", "text": "#define class_singleton_setup(class, methodName, setupCode) \\\ndynamic dzl_class_singleton; \\\n+ (class *)methodName { \\\nstatic class *methodName; \\\nstatic dispatch_once_t onceToken; \\\ndispatch_once(&onceToken, ^{ \\\nmethodName = [class new]; \\\n({setupCode;});\\\n}); \\\nreturn methodName; \\\n}\n", "parent": null, "children": [29, 30, 31, 34], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 36, "column": 0}}, {"id": 29, "type": "#define", "text": "#define", "parent": 28, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 7}}, {"id": 30, "type": "identifier", "text": "class_singleton_setup", "parent": 28, "children": [], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 29}}, {"id": 31, "type": "preproc_params", "text": "(class, methodName, setupCode)", "parent": 28, "children": [32, 33], "start_point": {"row": 25, "column": 29}, "end_point": {"row": 25, "column": 59}}, {"id": 32, "type": "identifier", "text": "methodName", "parent": 31, "children": [], "start_point": {"row": 25, "column": 37}, "end_point": {"row": 25, "column": 47}}, {"id": 33, "type": "identifier", "text": "setupCode", "parent": 31, "children": [], "start_point": {"row": 25, "column": 49}, "end_point": {"row": 25, "column": 58}}, {"id": 34, "type": "preproc_arg", "text": "dynamic dzl_class_singleton; \\\n+ (class *)methodName { \\\nstatic class *methodName; \\\nstatic dispatch_once_t onceToken; \\\ndispatch_once(&onceToken, ^{ \\\nmethodName = [class new]; \\\n({setupCode;});\\\n}); \\\nreturn methodName; \\\n}", "parent": 28, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 35, "column": 1}}]}, "node_categories": {"declarations": {"functions": [3, 22, 28], "variables": [8], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [2, 4, 9, 10, 12, 14, 16, 19, 24, 26, 30, 32, 33], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 3, "universal_type": "function", "name": "unknown", "text_snippet": "NSObject ()"}, {"node_id": 22, "universal_type": "function", "name": "*methodName;", "text_snippet": "#define class_singleton(class, methodName) \\\ndynamic dzl_class_singleton; \\\n+ (class *)methodName { "}, {"node_id": 28, "universal_type": "function", "name": "*methodName;", "text_snippet": "#define class_singleton_setup(class, methodName, setupCode) \\\ndynamic dzl_class_singleton; \\\n+ (clas"}], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// DZLClassSingleton.h\n// DZLObjcAdditions\n//\n// Created by <NAME> on 23/05/2014.\n// Copyright (c) 2014 <NAME>. All rights reserved.\n//\n\n\n@interface NSObject ()\n@property (nonatomic, strong) NSString *dzl_class_singleton;\n@end\n\n#define class_singleton(class, methodName) \\\ndynamic dzl_class_singleton; \\\n+ (class *)methodName { \\\nstatic class *methodName; \\\nstatic dispatch_once_t onceToken; \\\ndispatch_once(&onceToken, ^{ \\\nmethodName = [class new]; \\\n}); \\\nreturn methodName; \\\n}\n\n\n#define class_singleton_setup(class, methodName, setupCode) \\\ndynamic dzl_class_singleton; \\\n+ (class *)methodName { \\\nstatic class *methodName; \\\nstatic dispatch_once_t onceToken; \\\ndispatch_once(&onceToken, ^{ \\\nmethodName = [class new]; \\\n({setupCode;});\\\n}); \\\nreturn methodName; \\\n}\n"}
80,523
c
/* * Copyright (C) 2018-2020 Alibaba Group Holding Limited */ #ifndef __DEMUX_CLS_H__ #define __DEMUX_CLS_H__ #include "avutil/av_config.h" #include "avutil/av_typedef.h" #include "avutil/avpacket.h" #include "stream/stream_cls.h" #include "avformat/avparser_cls.h" __BEGIN_DECLS__ typedef struct demux_cls demux_cls_t; typedef struct avprobe_data { #define AVPROBE_SCORE_GUESS (50) #define AVPROBE_SCORE_EXTENSION (60) #define AVPROBE_SCORE_MIME (75) #define AVPROBE_SCORE_NAME (80) #define AVPROBE_SCORE_AGAIN (85) ///< next frame(not need sync) probe ok #define AVPROBE_SCORE_MAX (100) uint8_t *buf; int32_t buf_size; const char *filename; char avformat[16]; } avprobe_data_t; struct demux_ops { #define MAX_EXTENTSIONS (5) const char *name; uint8_t type; const char *extensions[MAX_EXTENTSIONS]; int (*read_probe) (const avprobe_data_t *pd); int (*open) (demux_cls_t *o); int (*read_packet) (demux_cls_t *o, avpacket_t *pkt); int (*seek) (demux_cls_t *o, uint64_t timestamp); int (*control) (demux_cls_t *o, int cmd, void *arg, size_t *arg_size); int (*close) (demux_cls_t *o); }; struct demux_cls { stream_cls_t *s; sh_audio_t ash; aos_mutex_t lock; avpacket_t fpkt; ///< reserved, the first packet for mp3, etc size_t id3v2size; ///< TODO: uint64_t bps; size_t time_scale; ///< only for audio uint64_t duration; ///< only for audio, ms track_info_t *tracks; ///< TODO: need call tracks_info_freep when unused avparser_t *psr; slist_t list_free; ///< free avpacket_list for psr slist_t list_ready; ///< ready avpacket_list for psr void *priv; const struct demux_ops *ops; }; __END_DECLS__ #endif /* __DEMUX_CLS_H__ */
40.8
54
(translation_unit) "/*\n * Copyright (C) 2018-2020 Alibaba Group Holding Limited\n */\n\n#ifndef __DEMUX_CLS_H__\n#define __DEMUX_CLS_H__\n\n#include "avutil/av_config.h"\n#include "avutil/av_typedef.h"\n#include "avutil/avpacket.h"\n#include "stream/stream_cls.h"\n#include "avformat/avparser_cls.h"\n\n__BEGIN_DECLS__\n\ntypedef struct demux_cls demux_cls_t;\n\ntypedef struct avprobe_data {\n#define AVPROBE_SCORE_GUESS (50)\n#define AVPROBE_SCORE_EXTENSION (60)\n#define AVPROBE_SCORE_MIME (75)\n#define AVPROBE_SCORE_NAME (80)\n#define AVPROBE_SCORE_AGAIN (85) ///< next frame(not need sync) probe ok\n#define AVPROBE_SCORE_MAX (100)\n uint8_t *buf;\n int32_t buf_size;\n const char *filename;\n char avformat[16];\n} avprobe_data_t;\n\nstruct demux_ops {\n#define MAX_EXTENTSIONS (5)\n const char *name;\n uint8_t type;\n const char *extensions[MAX_EXTENTSIONS];\n\n int (*read_probe) (const avprobe_data_t *pd);\n\n int (*open) (demux_cls_t *o);\n int (*read_packet) (demux_cls_t *o, avpacket_t *pkt);\n int (*seek) (demux_cls_t *o, uint64_t timestamp);\n int (*control) (demux_cls_t *o, int cmd, void *arg, size_t *arg_size);\n int (*close) (demux_cls_t *o);\n};\n\nstruct demux_cls {\n stream_cls_t *s;\n sh_audio_t ash;\n aos_mutex_t lock;\n avpacket_t fpkt; ///< reserved, the first packet for mp3, etc\n size_t id3v2size; ///< TODO:\n uint64_t bps;\n size_t time_scale; ///< only for audio\n uint64_t duration; ///< only for audio, ms\n track_info_t *tracks; ///< TODO: need call tracks_info_freep when unused\n\n avparser_t *psr;\n slist_t list_free; ///< free avpacket_list for psr\n slist_t list_ready; ///< ready avpacket_list for psr\n\n void *priv;\n const struct demux_ops *ops;\n};\n\n__END_DECLS__\n\n#endif /* __DEMUX_CLS_H__ */\n\n" (comment) "/*\n * Copyright (C) 2018-2020 Alibaba Group Holding Limited\n */" (preproc_ifdef) "#ifndef __DEMUX_CLS_H__\n#define __DEMUX_CLS_H__\n\n#include "avutil/av_config.h"\n#include "avutil/av_typedef.h"\n#include "avutil/avpacket.h"\n#include "stream/stream_cls.h"\n#include "avformat/avparser_cls.h"\n\n__BEGIN_DECLS__\n\ntypedef struct demux_cls demux_cls_t;\n\ntypedef struct avprobe_data {\n#define AVPROBE_SCORE_GUESS (50)\n#define AVPROBE_SCORE_EXTENSION (60)\n#define AVPROBE_SCORE_MIME (75)\n#define AVPROBE_SCORE_NAME (80)\n#define AVPROBE_SCORE_AGAIN (85) ///< next frame(not need sync) probe ok\n#define AVPROBE_SCORE_MAX (100)\n uint8_t *buf;\n int32_t buf_size;\n const char *filename;\n char avformat[16];\n} avprobe_data_t;\n\nstruct demux_ops {\n#define MAX_EXTENTSIONS (5)\n const char *name;\n uint8_t type;\n const char *extensions[MAX_EXTENTSIONS];\n\n int (*read_probe) (const avprobe_data_t *pd);\n\n int (*open) (demux_cls_t *o);\n int (*read_packet) (demux_cls_t *o, avpacket_t *pkt);\n int (*seek) (demux_cls_t *o, uint64_t timestamp);\n int (*control) (demux_cls_t *o, int cmd, void *arg, size_t *arg_size);\n int (*close) (demux_cls_t *o);\n};\n\nstruct demux_cls {\n stream_cls_t *s;\n sh_audio_t ash;\n aos_mutex_t lock;\n avpacket_t fpkt; ///< reserved, the first packet for mp3, etc\n size_t id3v2size; ///< TODO:\n uint64_t bps;\n size_t time_scale; ///< only for audio\n uint64_t duration; ///< only for audio, ms\n track_info_t *tracks; ///< TODO: need call tracks_info_freep when unused\n\n avparser_t *psr;\n slist_t list_free; ///< free avpacket_list for psr\n slist_t list_ready; ///< ready avpacket_list for psr\n\n void *priv;\n const struct demux_ops *ops;\n};\n\n__END_DECLS__\n\n#endif" (#ifndef) "#ifndef" (identifier) "__DEMUX_CLS_H__" (preproc_def) "#define __DEMUX_CLS_H__\n" (#define) "#define" (identifier) "__DEMUX_CLS_H__" (preproc_include) "#include "avutil/av_config.h"\n" (#include) "#include" (string_literal) ""avutil/av_config.h"" (") """ (string_content) "avutil/av_config.h" (") """ (preproc_include) "#include "avutil/av_typedef.h"\n" (#include) "#include" (string_literal) ""avutil/av_typedef.h"" (") """ (string_content) "avutil/av_typedef.h" (") """ (preproc_include) "#include "avutil/avpacket.h"\n" (#include) "#include" (string_literal) ""avutil/avpacket.h"" (") """ (string_content) "avutil/avpacket.h" (") """ (preproc_include) "#include "stream/stream_cls.h"\n" (#include) "#include" (string_literal) ""stream/stream_cls.h"" (") """ (string_content) "stream/stream_cls.h" (") """ (preproc_include) "#include "avformat/avparser_cls.h"\n" (#include) "#include" (string_literal) ""avformat/avparser_cls.h"" (") """ (string_content) "avformat/avparser_cls.h" (") """ (declaration) "__BEGIN_DECLS__\n\ntypedef" (type_identifier) "__BEGIN_DECLS__" (identifier) "typedef" (;) "" (declaration) "struct demux_cls demux_cls_t;" (struct_specifier) "struct demux_cls" (struct) "struct" (type_identifier) "demux_cls" (identifier) "demux_cls_t" (;) ";" (type_definition) "typedef struct avprobe_data {\n#define AVPROBE_SCORE_GUESS (50)\n#define AVPROBE_SCORE_EXTENSION (60)\n#define AVPROBE_SCORE_MIME (75)\n#define AVPROBE_SCORE_NAME (80)\n#define AVPROBE_SCORE_AGAIN (85) ///< next frame(not need sync) probe ok\n#define AVPROBE_SCORE_MAX (100)\n uint8_t *buf;\n int32_t buf_size;\n const char *filename;\n char avformat[16];\n} avprobe_data_t;" (typedef) "typedef" (struct_specifier) "struct avprobe_data {\n#define AVPROBE_SCORE_GUESS (50)\n#define AVPROBE_SCORE_EXTENSION (60)\n#define AVPROBE_SCORE_MIME (75)\n#define AVPROBE_SCORE_NAME (80)\n#define AVPROBE_SCORE_AGAIN (85) ///< next frame(not need sync) probe ok\n#define AVPROBE_SCORE_MAX (100)\n uint8_t *buf;\n int32_t buf_size;\n const char *filename;\n char avformat[16];\n}" (struct) "struct" (type_identifier) "avprobe_data" (field_declaration_list) "{\n#define AVPROBE_SCORE_GUESS (50)\n#define AVPROBE_SCORE_EXTENSION (60)\n#define AVPROBE_SCORE_MIME (75)\n#define AVPROBE_SCORE_NAME (80)\n#define AVPROBE_SCORE_AGAIN (85) ///< next frame(not need sync) probe ok\n#define AVPROBE_SCORE_MAX (100)\n uint8_t *buf;\n int32_t buf_size;\n const char *filename;\n char avformat[16];\n}" ({) "{" (preproc_def) "#define AVPROBE_SCORE_GUESS (50)\n" (#define) "#define" (identifier) "AVPROBE_SCORE_GUESS" (preproc_arg) "(50)" (preproc_def) "#define AVPROBE_SCORE_EXTENSION (60)\n" (#define) "#define" (identifier) "AVPROBE_SCORE_EXTENSION" (preproc_arg) "(60)" (preproc_def) "#define AVPROBE_SCORE_MIME (75)\n" (#define) "#define" (identifier) "AVPROBE_SCORE_MIME" (preproc_arg) "(75)" (preproc_def) "#define AVPROBE_SCORE_NAME (80)\n" (#define) "#define" (identifier) "AVPROBE_SCORE_NAME" (preproc_arg) "(80)" (preproc_def) "#define AVPROBE_SCORE_AGAIN (85) ///< next frame(not need sync) probe ok\n" (#define) "#define" (identifier) "AVPROBE_SCORE_AGAIN" (preproc_arg) "(85) ///< next frame(not need sync) probe ok" (preproc_def) "#define AVPROBE_SCORE_MAX (100)\n" (#define) "#define" (identifier) "AVPROBE_SCORE_MAX" (preproc_arg) "(100)" (field_declaration) "uint8_t *buf;" (primitive_type) "uint8_t" (pointer_declarator) "*buf" (*) "*" (field_identifier) "buf" (;) ";" (field_declaration) "int32_t buf_size;" (primitive_type) "int32_t" (field_identifier) "buf_size" (;) ";" (field_declaration) "const char *filename;" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "*filename" (*) "*" (field_identifier) "filename" (;) ";" (field_declaration) "char avformat[16];" (primitive_type) "char" (array_declarator) "avformat[16]" (field_identifier) "avformat" ([) "[" (number_literal) "16" (]) "]" (;) ";" (}) "}" (type_identifier) "avprobe_data_t" (;) ";" (struct_specifier) "struct demux_ops {\n#define MAX_EXTENTSIONS (5)\n const char *name;\n uint8_t type;\n const char *extensions[MAX_EXTENTSIONS];\n\n int (*read_probe) (const avprobe_data_t *pd);\n\n int (*open) (demux_cls_t *o);\n int (*read_packet) (demux_cls_t *o, avpacket_t *pkt);\n int (*seek) (demux_cls_t *o, uint64_t timestamp);\n int (*control) (demux_cls_t *o, int cmd, void *arg, size_t *arg_size);\n int (*close) (demux_cls_t *o);\n}" (struct) "struct" (type_identifier) "demux_ops" (field_declaration_list) "{\n#define MAX_EXTENTSIONS (5)\n const char *name;\n uint8_t type;\n const char *extensions[MAX_EXTENTSIONS];\n\n int (*read_probe) (const avprobe_data_t *pd);\n\n int (*open) (demux_cls_t *o);\n int (*read_packet) (demux_cls_t *o, avpacket_t *pkt);\n int (*seek) (demux_cls_t *o, uint64_t timestamp);\n int (*control) (demux_cls_t *o, int cmd, void *arg, size_t *arg_size);\n int (*close) (demux_cls_t *o);\n}" ({) "{" (preproc_def) "#define MAX_EXTENTSIONS (5)\n" (#define) "#define" (identifier) "MAX_EXTENTSIONS" (preproc_arg) "(5)" (field_declaration) "const char *name;" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "*name" (*) "*" (field_identifier) "name" (;) ";" (field_declaration) "uint8_t type;" (primitive_type) "uint8_t" (field_identifier) "type" (;) ";" (field_declaration) "const char *extensions[MAX_EXTENTSIONS];" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "*extensions[MAX_EXTENTSIONS]" (*) "*" (array_declarator) "extensions[MAX_EXTENTSIONS]" (field_identifier) "extensions" ([) "[" (identifier) "MAX_EXTENTSIONS" (]) "]" (;) ";" (field_declaration) "int (*read_probe) (const avprobe_data_t *pd);" (primitive_type) "int" (function_declarator) "(*read_probe) (const avprobe_data_t *pd)" (parenthesized_declarator) "(*read_probe)" (() "(" (pointer_declarator) "*read_probe" (*) "*" (field_identifier) "read_probe" ()) ")" (parameter_list) "(const avprobe_data_t *pd)" (() "(" (parameter_declaration) "const avprobe_data_t *pd" (type_qualifier) "const" (const) "const" (type_identifier) "avprobe_data_t" (pointer_declarator) "*pd" (*) "*" (identifier) "pd" ()) ")" (;) ";" (field_declaration) "int (*open) (demux_cls_t *o);" (primitive_type) "int" (function_declarator) "(*open) (demux_cls_t *o)" (parenthesized_declarator) "(*open)" (() "(" (pointer_declarator) "*open" (*) "*" (field_identifier) "open" ()) ")" (parameter_list) "(demux_cls_t *o)" (() "(" (parameter_declaration) "demux_cls_t *o" (type_identifier) "demux_cls_t" (pointer_declarator) "*o" (*) "*" (identifier) "o" ()) ")" (;) ";" (field_declaration) "int (*read_packet) (demux_cls_t *o, avpacket_t *pkt);" (primitive_type) "int" (function_declarator) "(*read_packet) (demux_cls_t *o, avpacket_t *pkt)" (parenthesized_declarator) "(*read_packet)" (() "(" (pointer_declarator) "*read_packet" (*) "*" (field_identifier) "read_packet" ()) ")" (parameter_list) "(demux_cls_t *o, avpacket_t *pkt)" (() "(" (parameter_declaration) "demux_cls_t *o" (type_identifier) "demux_cls_t" (pointer_declarator) "*o" (*) "*" (identifier) "o" (,) "," (parameter_declaration) "avpacket_t *pkt" (type_identifier) "avpacket_t" (pointer_declarator) "*pkt" (*) "*" (identifier) "pkt" ()) ")" (;) ";" (field_declaration) "int (*seek) (demux_cls_t *o, uint64_t timestamp);" (primitive_type) "int" (function_declarator) "(*seek) (demux_cls_t *o, uint64_t timestamp)" (parenthesized_declarator) "(*seek)" (() "(" (pointer_declarator) "*seek" (*) "*" (field_identifier) "seek" ()) ")" (parameter_list) "(demux_cls_t *o, uint64_t timestamp)" (() "(" (parameter_declaration) "demux_cls_t *o" (type_identifier) "demux_cls_t" (pointer_declarator) "*o" (*) "*" (identifier) "o" (,) "," (parameter_declaration) "uint64_t timestamp" (primitive_type) "uint64_t" (identifier) "timestamp" ()) ")" (;) ";" (field_declaration) "int (*control) (demux_cls_t *o, int cmd, void *arg, size_t *arg_size);" (primitive_type) "int" (function_declarator) "(*control) (demux_cls_t *o, int cmd, void *arg, size_t *arg_size)" (parenthesized_declarator) "(*control)" (() "(" (pointer_declarator) "*control" (*) "*" (field_identifier) "control" ()) ")" (parameter_list) "(demux_cls_t *o, int cmd, void *arg, size_t *arg_size)" (() "(" (parameter_declaration) "demux_cls_t *o" (type_identifier) "demux_cls_t" (pointer_declarator) "*o" (*) "*" (identifier) "o" (,) "," (parameter_declaration) "int cmd" (primitive_type) "int" (identifier) "cmd" (,) "," (parameter_declaration) "void *arg" (primitive_type) "void" (pointer_declarator) "*arg" (*) "*" (identifier) "arg" (,) "," (parameter_declaration) "size_t *arg_size" (primitive_type) "size_t" (pointer_declarator) "*arg_size" (*) "*" (identifier) "arg_size" ()) ")" (;) ";" (field_declaration) "int (*close) (demux_cls_t *o);" (primitive_type) "int" (function_declarator) "(*close) (demux_cls_t *o)" (parenthesized_declarator) "(*close)" (() "(" (pointer_declarator) "*close" (*) "*" (field_identifier) "close" ()) ")" (parameter_list) "(demux_cls_t *o)" (() "(" (parameter_declaration) "demux_cls_t *o" (type_identifier) "demux_cls_t" (pointer_declarator) "*o" (*) "*" (identifier) "o" ()) ")" (;) ";" (}) "}" (;) ";" (struct_specifier) "struct demux_cls {\n stream_cls_t *s;\n sh_audio_t ash;\n aos_mutex_t lock;\n avpacket_t fpkt; ///< reserved, the first packet for mp3, etc\n size_t id3v2size; ///< TODO:\n uint64_t bps;\n size_t time_scale; ///< only for audio\n uint64_t duration; ///< only for audio, ms\n track_info_t *tracks; ///< TODO: need call tracks_info_freep when unused\n\n avparser_t *psr;\n slist_t list_free; ///< free avpacket_list for psr\n slist_t list_ready; ///< ready avpacket_list for psr\n\n void *priv;\n const struct demux_ops *ops;\n}" (struct) "struct" (type_identifier) "demux_cls" (field_declaration_list) "{\n stream_cls_t *s;\n sh_audio_t ash;\n aos_mutex_t lock;\n avpacket_t fpkt; ///< reserved, the first packet for mp3, etc\n size_t id3v2size; ///< TODO:\n uint64_t bps;\n size_t time_scale; ///< only for audio\n uint64_t duration; ///< only for audio, ms\n track_info_t *tracks; ///< TODO: need call tracks_info_freep when unused\n\n avparser_t *psr;\n slist_t list_free; ///< free avpacket_list for psr\n slist_t list_ready; ///< ready avpacket_list for psr\n\n void *priv;\n const struct demux_ops *ops;\n}" ({) "{" (field_declaration) "stream_cls_t *s;" (type_identifier) "stream_cls_t" (pointer_declarator) "*s" (*) "*" (field_identifier) "s" (;) ";" (field_declaration) "sh_audio_t ash;" (type_identifier) "sh_audio_t" (field_identifier) "ash" (;) ";" (field_declaration) "aos_mutex_t lock;" (type_identifier) "aos_mutex_t" (field_identifier) "lock" (;) ";" (field_declaration) "avpacket_t fpkt;" (type_identifier) "avpacket_t" (field_identifier) "fpkt" (;) ";" (comment) "///< reserved, the first packet for mp3, etc" (field_declaration) "size_t id3v2size;" (primitive_type) "size_t" (field_identifier) "id3v2size" (;) ";" (comment) "///< TODO:" (field_declaration) "uint64_t bps;" (primitive_type) "uint64_t" (field_identifier) "bps" (;) ";" (field_declaration) "size_t time_scale;" (primitive_type) "size_t" (field_identifier) "time_scale" (;) ";" (comment) "///< only for audio" (field_declaration) "uint64_t duration;" (primitive_type) "uint64_t" (field_identifier) "duration" (;) ";" (comment) "///< only for audio, ms" (field_declaration) "track_info_t *tracks;" (type_identifier) "track_info_t" (pointer_declarator) "*tracks" (*) "*" (field_identifier) "tracks" (;) ";" (comment) "///< TODO: need call tracks_info_freep when unused" (field_declaration) "avparser_t *psr;" (type_identifier) "avparser_t" (pointer_declarator) "*psr" (*) "*" (field_identifier) "psr" (;) ";" (field_declaration) "slist_t list_free;" (type_identifier) "slist_t" (field_identifier) "list_free" (;) ";" (comment) "///< free avpacket_list for psr" (field_declaration) "slist_t list_ready;" (type_identifier) "slist_t" (field_identifier) "list_ready" (;) ";" (comment) "///< ready avpacket_list for psr" (field_declaration) "void *priv;" (primitive_type) "void" (pointer_declarator) "*priv" (*) "*" (field_identifier) "priv" (;) ";" (field_declaration) "const struct demux_ops *ops;" (type_qualifier) "const" (const) "const" (struct_specifier) "struct demux_ops" (struct) "struct" (type_identifier) "demux_ops" (pointer_declarator) "*ops" (*) "*" (field_identifier) "ops" (;) ";" (}) "}" (;) ";" (type_identifier) "__END_DECLS__" (;) "" (#endif) "#endif" (comment) "/* __DEMUX_CLS_H__ */"
367
0
{"language": "c", "success": true, "metadata": {"lines": 54, "avg_line_length": 40.8, "nodes": 257, "errors": 0, "source_hash": "ab0f95e593b9064b6ac6fa6bea58c289ef1482ced44a1a18c238277d8f69d5d5", "categorized_nodes": 149}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef __DEMUX_CLS_H__\n#define __DEMUX_CLS_H__\n\n#include \"avutil/av_config.h\"\n#include \"avutil/av_typedef.h\"\n#include \"avutil/avpacket.h\"\n#include \"stream/stream_cls.h\"\n#include \"avformat/avparser_cls.h\"\n\n__BEGIN_DECLS__\n\ntypedef struct demux_cls demux_cls_t;\n\ntypedef struct avprobe_data {\n#define AVPROBE_SCORE_GUESS (50)\n#define AVPROBE_SCORE_EXTENSION (60)\n#define AVPROBE_SCORE_MIME (75)\n#define AVPROBE_SCORE_NAME (80)\n#define AVPROBE_SCORE_AGAIN (85) ///< next frame(not need sync) probe ok\n#define AVPROBE_SCORE_MAX (100)\n uint8_t *buf;\n int32_t buf_size;\n const char *filename;\n char avformat[16];\n} avprobe_data_t;\n\nstruct demux_ops {\n#define MAX_EXTENTSIONS (5)\n const char *name;\n uint8_t type;\n const char *extensions[MAX_EXTENTSIONS];\n\n int (*read_probe) (const avprobe_data_t *pd);\n\n int (*open) (demux_cls_t *o);\n int (*read_packet) (demux_cls_t *o, avpacket_t *pkt);\n int (*seek) (demux_cls_t *o, uint64_t timestamp);\n int (*control) (demux_cls_t *o, int cmd, void *arg, size_t *arg_size);\n int (*close) (demux_cls_t *o);\n};\n\nstruct demux_cls {\n stream_cls_t *s;\n sh_audio_t ash;\n aos_mutex_t lock;\n avpacket_t fpkt; ///< reserved, the first packet for mp3, etc\n size_t id3v2size; ///< TODO:\n uint64_t bps;\n size_t time_scale; ///< only for audio\n uint64_t duration; ///< only for audio, ms\n track_info_t *tracks; ///< TODO: need call tracks_info_freep when unused\n\n avparser_t *psr;\n slist_t list_free; ///< free avpacket_list for psr\n slist_t list_ready; ///< ready avpacket_list for psr\n\n void *priv;\n const struct demux_ops *ops;\n};\n\n__END_DECLS__\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 15, 18, 21, 24, 29, 77, 198, 255, 256], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 66, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 7}}, {"id": 2, "type": "identifier", "text": "__DEMUX_CLS_H__", "parent": 0, "children": [], "start_point": {"row": 4, "column": 8}, "end_point": {"row": 4, "column": 23}}, {"id": 3, "type": "preproc_def", "text": "#define __DEMUX_CLS_H__\n", "parent": 0, "children": [4, 5], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 7}}, {"id": 5, "type": "identifier", "text": "__DEMUX_CLS_H__", "parent": 3, "children": [], "start_point": {"row": 5, "column": 8}, "end_point": {"row": 5, "column": 23}}, {"id": 6, "type": "preproc_include", "text": "#include \"avutil/av_config.h\"\n", "parent": 0, "children": [7, 8], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"avutil/av_config.h\"", "parent": 6, "children": [], "start_point": {"row": 7, "column": 9}, "end_point": {"row": 7, "column": 29}}, {"id": 9, "type": "preproc_include", "text": "#include \"avutil/av_typedef.h\"\n", "parent": 0, "children": [10, 11], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"avutil/av_typedef.h\"", "parent": 9, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 30}}, {"id": 12, "type": "preproc_include", "text": "#include \"avutil/avpacket.h\"\n", "parent": 0, "children": [13, 14], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 8}}, {"id": 14, "type": "string_literal", "text": "\"avutil/avpacket.h\"", "parent": 12, "children": [], "start_point": {"row": 9, "column": 9}, "end_point": {"row": 9, "column": 28}}, {"id": 15, "type": "preproc_include", "text": "#include \"stream/stream_cls.h\"\n", "parent": 0, "children": [16, 17], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 11, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 8}}, {"id": 17, "type": "string_literal", "text": "\"stream/stream_cls.h\"", "parent": 15, "children": [], "start_point": {"row": 10, "column": 9}, "end_point": {"row": 10, "column": 30}}, {"id": 18, "type": "preproc_include", "text": "#include \"avformat/avparser_cls.h\"\n", "parent": 0, "children": [19, 20], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 12, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 8}}, {"id": 20, "type": "string_literal", "text": "\"avformat/avparser_cls.h\"", "parent": 18, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 34}}, {"id": 21, "type": "declaration", "text": "__BEGIN_DECLS__\n\ntypedef", "parent": 0, "children": [22, 23], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 15, "column": 7}}, {"id": 22, "type": "type_identifier", "text": "__BEGIN_DECLS__", "parent": 21, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 15}}, {"id": 23, "type": "identifier", "text": "typedef", "parent": 21, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 7}}, {"id": 24, "type": "declaration", "text": "struct demux_cls demux_cls_t;", "parent": 0, "children": [25, 28], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 37}}, {"id": 25, "type": "struct_specifier", "text": "struct demux_cls", "parent": 24, "children": [26, 27], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 24}}, {"id": 26, "type": "struct", "text": "struct", "parent": 25, "children": [], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 14}}, {"id": 27, "type": "type_identifier", "text": "demux_cls", "parent": 25, "children": [], "start_point": {"row": 15, "column": 15}, "end_point": {"row": 15, "column": 24}}, {"id": 28, "type": "identifier", "text": "demux_cls_t", "parent": 24, "children": [], "start_point": {"row": 15, "column": 25}, "end_point": {"row": 15, "column": 36}}, {"id": 29, "type": "type_definition", "text": "typedef struct avprobe_data {\n#define AVPROBE_SCORE_GUESS (50)\n#define AVPROBE_SCORE_EXTENSION (60)\n#define AVPROBE_SCORE_MIME (75)\n#define AVPROBE_SCORE_NAME (80)\n#define AVPROBE_SCORE_AGAIN (85) ///< next frame(not need sync) probe ok\n#define AVPROBE_SCORE_MAX (100)\n uint8_t *buf;\n int32_t buf_size;\n const char *filename;\n char avformat[16];\n} avprobe_data_t;", "parent": 0, "children": [30, 31, 76], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 28, "column": 17}}, {"id": 30, "type": "typedef", "text": "typedef", "parent": 29, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 7}}, {"id": 31, "type": "struct_specifier", "text": "struct avprobe_data {\n#define AVPROBE_SCORE_GUESS (50)\n#define AVPROBE_SCORE_EXTENSION (60)\n#define AVPROBE_SCORE_MIME (75)\n#define AVPROBE_SCORE_NAME (80)\n#define AVPROBE_SCORE_AGAIN (85) ///< next frame(not need sync) probe ok\n#define AVPROBE_SCORE_MAX (100)\n uint8_t *buf;\n int32_t buf_size;\n const char *filename;\n char avformat[16];\n}", "parent": 29, "children": [32, 33], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 28, "column": 1}}, {"id": 32, "type": "struct", "text": "struct", "parent": 31, "children": [], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 17, "column": 14}}, {"id": 33, "type": "type_identifier", "text": "avprobe_data", "parent": 31, "children": [], "start_point": {"row": 17, "column": 15}, "end_point": {"row": 17, "column": 27}}, {"id": 34, "type": "preproc_def", "text": "#define AVPROBE_SCORE_GUESS (50)\n", "parent": 31, "children": [35, 36, 37], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 19, "column": 0}}, {"id": 35, "type": "#define", "text": "#define", "parent": 34, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 7}}, {"id": 36, "type": "identifier", "text": "AVPROBE_SCORE_GUESS", "parent": 34, "children": [], "start_point": {"row": 18, "column": 8}, "end_point": {"row": 18, "column": 27}}, {"id": 37, "type": "preproc_arg", "text": "(50)", "parent": 34, "children": [], "start_point": {"row": 18, "column": 32}, "end_point": {"row": 18, "column": 36}}, {"id": 38, "type": "preproc_def", "text": "#define AVPROBE_SCORE_EXTENSION (60)\n", "parent": 31, "children": [39, 40, 41], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 20, "column": 0}}, {"id": 39, "type": "#define", "text": "#define", "parent": 38, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 7}}, {"id": 40, "type": "identifier", "text": "AVPROBE_SCORE_EXTENSION", "parent": 38, "children": [], "start_point": {"row": 19, "column": 8}, "end_point": {"row": 19, "column": 31}}, {"id": 41, "type": "preproc_arg", "text": "(60)", "parent": 38, "children": [], "start_point": {"row": 19, "column": 32}, "end_point": {"row": 19, "column": 36}}, {"id": 42, "type": "preproc_def", "text": "#define AVPROBE_SCORE_MIME (75)\n", "parent": 31, "children": [43, 44, 45], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 21, "column": 0}}, {"id": 43, "type": "#define", "text": "#define", "parent": 42, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 7}}, {"id": 44, "type": "identifier", "text": "AVPROBE_SCORE_MIME", "parent": 42, "children": [], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 26}}, {"id": 45, "type": "preproc_arg", "text": "(75)", "parent": 42, "children": [], "start_point": {"row": 20, "column": 32}, "end_point": {"row": 20, "column": 36}}, {"id": 46, "type": "preproc_def", "text": "#define AVPROBE_SCORE_NAME (80)\n", "parent": 31, "children": [47, 48, 49], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 22, "column": 0}}, {"id": 47, "type": "#define", "text": "#define", "parent": 46, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 7}}, {"id": 48, "type": "identifier", "text": "AVPROBE_SCORE_NAME", "parent": 46, "children": [], "start_point": {"row": 21, "column": 8}, "end_point": {"row": 21, "column": 26}}, {"id": 49, "type": "preproc_arg", "text": "(80)", "parent": 46, "children": [], "start_point": {"row": 21, "column": 32}, "end_point": {"row": 21, "column": 36}}, {"id": 50, "type": "preproc_def", "text": "#define AVPROBE_SCORE_AGAIN (85) ///< next frame(not need sync) probe ok\n", "parent": 31, "children": [51, 52, 53], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 23, "column": 0}}, {"id": 51, "type": "#define", "text": "#define", "parent": 50, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 7}}, {"id": 52, "type": "identifier", "text": "AVPROBE_SCORE_AGAIN", "parent": 50, "children": [], "start_point": {"row": 22, "column": 8}, "end_point": {"row": 22, "column": 27}}, {"id": 53, "type": "preproc_arg", "text": "(85) ///< next frame(not need sync) probe ok", "parent": 50, "children": [], "start_point": {"row": 22, "column": 32}, "end_point": {"row": 22, "column": 84}}, {"id": 54, "type": "preproc_def", "text": "#define AVPROBE_SCORE_MAX (100)\n", "parent": 31, "children": [55, 56, 57], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 24, "column": 0}}, {"id": 55, "type": "#define", "text": "#define", "parent": 54, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 7}}, {"id": 56, "type": "identifier", "text": "AVPROBE_SCORE_MAX", "parent": 54, "children": [], "start_point": {"row": 23, "column": 8}, "end_point": {"row": 23, "column": 25}}, {"id": 57, "type": "preproc_arg", "text": "(100)", "parent": 54, "children": [], "start_point": {"row": 23, "column": 32}, "end_point": {"row": 23, "column": 37}}, {"id": 58, "type": "field_declaration", "text": "uint8_t *buf;", "parent": 31, "children": [59, 60], "start_point": {"row": 24, "column": 4}, "end_point": {"row": 24, "column": 37}}, {"id": 59, "type": "primitive_type", "text": "uint8_t", "parent": 58, "children": [], "start_point": {"row": 24, "column": 4}, "end_point": {"row": 24, "column": 11}}, {"id": 60, "type": "pointer_declarator", "text": "*buf", "parent": 58, "children": [61, 62], "start_point": {"row": 24, "column": 32}, "end_point": {"row": 24, "column": 36}}, {"id": 61, "type": "*", "text": "*", "parent": 60, "children": [], "start_point": {"row": 24, "column": 32}, "end_point": {"row": 24, "column": 33}}, {"id": 62, "type": "field_identifier", "text": "buf", "parent": 60, "children": [], "start_point": {"row": 24, "column": 33}, "end_point": {"row": 24, "column": 36}}, {"id": 63, "type": "field_declaration", "text": "int32_t buf_size;", "parent": 31, "children": [64, 65], "start_point": {"row": 25, "column": 4}, "end_point": {"row": 25, "column": 41}}, {"id": 64, "type": "primitive_type", "text": "int32_t", "parent": 63, "children": [], "start_point": {"row": 25, "column": 4}, "end_point": {"row": 25, "column": 11}}, {"id": 65, "type": "field_identifier", "text": "buf_size", "parent": 63, "children": [], "start_point": {"row": 25, "column": 32}, "end_point": {"row": 25, "column": 40}}, {"id": 66, "type": "field_declaration", "text": "const char *filename;", "parent": 31, "children": [67, 68], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 26, "column": 42}}, {"id": 67, "type": "primitive_type", "text": "char", "parent": 66, "children": [], "start_point": {"row": 26, "column": 10}, "end_point": {"row": 26, "column": 14}}, {"id": 68, "type": "pointer_declarator", "text": "*filename", "parent": 66, "children": [69, 70], "start_point": {"row": 26, "column": 32}, "end_point": {"row": 26, "column": 41}}, {"id": 69, "type": "*", "text": "*", "parent": 68, "children": [], "start_point": {"row": 26, "column": 32}, "end_point": {"row": 26, "column": 33}}, {"id": 70, "type": "field_identifier", "text": "filename", "parent": 68, "children": [], "start_point": {"row": 26, "column": 33}, "end_point": {"row": 26, "column": 41}}, {"id": 71, "type": "field_declaration", "text": "char avformat[16];", "parent": 31, "children": [72, 73], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 45}}, {"id": 72, "type": "primitive_type", "text": "char", "parent": 71, "children": [], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 8}}, {"id": 73, "type": "array_declarator", "text": "avformat[16]", "parent": 71, "children": [74, 75], "start_point": {"row": 27, "column": 32}, "end_point": {"row": 27, "column": 44}}, {"id": 74, "type": "field_identifier", "text": "avformat", "parent": 73, "children": [], "start_point": {"row": 27, "column": 32}, "end_point": {"row": 27, "column": 40}}, {"id": 75, "type": "number_literal", "text": "16", "parent": 73, "children": [], "start_point": {"row": 27, "column": 41}, "end_point": {"row": 27, "column": 43}}, {"id": 76, "type": "type_identifier", "text": "avprobe_data_t", "parent": 29, "children": [], "start_point": {"row": 28, "column": 2}, "end_point": {"row": 28, "column": 16}}, {"id": 77, "type": "struct_specifier", "text": "struct demux_ops {\n#define MAX_EXTENTSIONS (5)\n const char *name;\n uint8_t type;\n const char *extensions[MAX_EXTENTSIONS];\n\n int (*read_probe) (const avprobe_data_t *pd);\n\n int (*open) (demux_cls_t *o);\n int (*read_packet) (demux_cls_t *o, avpacket_t *pkt);\n int (*seek) (demux_cls_t *o, uint64_t timestamp);\n int (*control) (demux_cls_t *o, int cmd, void *arg, size_t *arg_size);\n int (*close) (demux_cls_t *o);\n}", "parent": 0, "children": [78, 79], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 43, "column": 1}}, {"id": 78, "type": "struct", "text": "struct", "parent": 77, "children": [], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 6}}, {"id": 79, "type": "type_identifier", "text": "demux_ops", "parent": 77, "children": [], "start_point": {"row": 30, "column": 7}, "end_point": {"row": 30, "column": 16}}, {"id": 80, "type": "preproc_def", "text": "#define MAX_EXTENTSIONS (5)\n", "parent": 77, "children": [81, 82, 83], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 32, "column": 0}}, {"id": 81, "type": "#define", "text": "#define", "parent": 80, "children": [], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 31, "column": 7}}, {"id": 82, "type": "identifier", "text": "MAX_EXTENTSIONS", "parent": 80, "children": [], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 23}}, {"id": 83, "type": "preproc_arg", "text": "(5)", "parent": 80, "children": [], "start_point": {"row": 31, "column": 24}, "end_point": {"row": 31, "column": 27}}, {"id": 84, "type": "field_declaration", "text": "const char *name;", "parent": 77, "children": [85, 86], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 32, "column": 38}}, {"id": 85, "type": "primitive_type", "text": "char", "parent": 84, "children": [], "start_point": {"row": 32, "column": 10}, "end_point": {"row": 32, "column": 14}}, {"id": 86, "type": "pointer_declarator", "text": "*name", "parent": 84, "children": [87, 88], "start_point": {"row": 32, "column": 32}, "end_point": {"row": 32, "column": 37}}, {"id": 87, "type": "*", "text": "*", "parent": 86, "children": [], "start_point": {"row": 32, "column": 32}, "end_point": {"row": 32, "column": 33}}, {"id": 88, "type": "field_identifier", "text": "name", "parent": 86, "children": [], "start_point": {"row": 32, "column": 33}, "end_point": {"row": 32, "column": 37}}, {"id": 89, "type": "field_declaration", "text": "uint8_t type;", "parent": 77, "children": [90, 91], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 37}}, {"id": 90, "type": "primitive_type", "text": "uint8_t", "parent": 89, "children": [], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 11}}, {"id": 91, "type": "field_identifier", "text": "type", "parent": 89, "children": [], "start_point": {"row": 33, "column": 32}, "end_point": {"row": 33, "column": 36}}, {"id": 92, "type": "field_declaration", "text": "const char *extensions[MAX_EXTENTSIONS];", "parent": 77, "children": [93, 94], "start_point": {"row": 34, "column": 4}, "end_point": {"row": 34, "column": 61}}, {"id": 93, "type": "primitive_type", "text": "char", "parent": 92, "children": [], "start_point": {"row": 34, "column": 10}, "end_point": {"row": 34, "column": 14}}, {"id": 94, "type": "pointer_declarator", "text": "*extensions[MAX_EXTENTSIONS]", "parent": 92, "children": [95, 96], "start_point": {"row": 34, "column": 32}, "end_point": {"row": 34, "column": 60}}, {"id": 95, "type": "*", "text": "*", "parent": 94, "children": [], "start_point": {"row": 34, "column": 32}, "end_point": {"row": 34, "column": 33}}, {"id": 96, "type": "array_declarator", "text": "extensions[MAX_EXTENTSIONS]", "parent": 94, "children": [97, 98], "start_point": {"row": 34, "column": 33}, "end_point": {"row": 34, "column": 60}}, {"id": 97, "type": "field_identifier", "text": "extensions", "parent": 96, "children": [], "start_point": {"row": 34, "column": 33}, "end_point": {"row": 34, "column": 43}}, {"id": 98, "type": "identifier", "text": "MAX_EXTENTSIONS", "parent": 96, "children": [], "start_point": {"row": 34, "column": 44}, "end_point": {"row": 34, "column": 59}}, {"id": 99, "type": "field_declaration", "text": "int (*read_probe) (const avprobe_data_t *pd);", "parent": 77, "children": [100, 101], "start_point": {"row": 36, "column": 4}, "end_point": {"row": 36, "column": 59}}, {"id": 100, "type": "primitive_type", "text": "int", "parent": 99, "children": [], "start_point": {"row": 36, "column": 4}, "end_point": {"row": 36, "column": 7}}, {"id": 101, "type": "function_declarator", "text": "(*read_probe) (const avprobe_data_t *pd)", "parent": 99, "children": [102, 106], "start_point": {"row": 36, "column": 13}, "end_point": {"row": 36, "column": 58}}, {"id": 102, "type": "parenthesized_declarator", "text": "(*read_probe)", "parent": 101, "children": [103], "start_point": {"row": 36, "column": 13}, "end_point": {"row": 36, "column": 26}}, {"id": 103, "type": "pointer_declarator", "text": "*read_probe", "parent": 102, "children": [104, 105], "start_point": {"row": 36, "column": 14}, "end_point": {"row": 36, "column": 25}}, {"id": 104, "type": "*", "text": "*", "parent": 103, "children": [], "start_point": {"row": 36, "column": 14}, "end_point": {"row": 36, "column": 15}}, {"id": 105, "type": "field_identifier", "text": "read_probe", "parent": 103, "children": [], "start_point": {"row": 36, "column": 15}, "end_point": {"row": 36, "column": 25}}, {"id": 106, "type": "parameter_list", "text": "(const avprobe_data_t *pd)", "parent": 101, "children": [107], "start_point": {"row": 36, "column": 32}, "end_point": {"row": 36, "column": 58}}, {"id": 107, "type": "parameter_declaration", "text": "const avprobe_data_t *pd", "parent": 106, "children": [108, 109], "start_point": {"row": 36, "column": 33}, "end_point": {"row": 36, "column": 57}}, {"id": 108, "type": "type_identifier", "text": "avprobe_data_t", "parent": 107, "children": [], "start_point": {"row": 36, "column": 39}, "end_point": {"row": 36, "column": 53}}, {"id": 109, "type": "pointer_declarator", "text": "*pd", "parent": 107, "children": [110, 111], "start_point": {"row": 36, "column": 54}, "end_point": {"row": 36, "column": 57}}, {"id": 110, "type": "*", "text": "*", "parent": 109, "children": [], "start_point": {"row": 36, "column": 54}, "end_point": {"row": 36, "column": 55}}, {"id": 111, "type": "identifier", "text": "pd", "parent": 109, "children": [], "start_point": {"row": 36, "column": 55}, "end_point": {"row": 36, "column": 57}}, {"id": 112, "type": "field_declaration", "text": "int (*open) (demux_cls_t *o);", "parent": 77, "children": [113, 114], "start_point": {"row": 38, "column": 4}, "end_point": {"row": 38, "column": 49}}, {"id": 113, "type": "primitive_type", "text": "int", "parent": 112, "children": [], "start_point": {"row": 38, "column": 4}, "end_point": {"row": 38, "column": 7}}, {"id": 114, "type": "function_declarator", "text": "(*open) (demux_cls_t *o)", "parent": 112, "children": [115, 119], "start_point": {"row": 38, "column": 13}, "end_point": {"row": 38, "column": 48}}, {"id": 115, "type": "parenthesized_declarator", "text": "(*open)", "parent": 114, "children": [116], "start_point": {"row": 38, "column": 13}, "end_point": {"row": 38, "column": 20}}, {"id": 116, "type": "pointer_declarator", "text": "*open", "parent": 115, "children": [117, 118], "start_point": {"row": 38, "column": 14}, "end_point": {"row": 38, "column": 19}}, {"id": 117, "type": "*", "text": "*", "parent": 116, "children": [], "start_point": {"row": 38, "column": 14}, "end_point": {"row": 38, "column": 15}}, {"id": 118, "type": "field_identifier", "text": "open", "parent": 116, "children": [], "start_point": {"row": 38, "column": 15}, "end_point": {"row": 38, "column": 19}}, {"id": 119, "type": "parameter_list", "text": "(demux_cls_t *o)", "parent": 114, "children": [120], "start_point": {"row": 38, "column": 32}, "end_point": {"row": 38, "column": 48}}, {"id": 120, "type": "parameter_declaration", "text": "demux_cls_t *o", "parent": 119, "children": [121, 122], "start_point": {"row": 38, "column": 33}, "end_point": {"row": 38, "column": 47}}, {"id": 121, "type": "type_identifier", "text": "demux_cls_t", "parent": 120, "children": [], "start_point": {"row": 38, "column": 33}, "end_point": {"row": 38, "column": 44}}, {"id": 122, "type": "pointer_declarator", "text": "*o", "parent": 120, "children": [123, 124], "start_point": {"row": 38, "column": 45}, "end_point": {"row": 38, "column": 47}}, {"id": 123, "type": "*", "text": "*", "parent": 122, "children": [], "start_point": {"row": 38, "column": 45}, "end_point": {"row": 38, "column": 46}}, {"id": 124, "type": "identifier", "text": "o", "parent": 122, "children": [], "start_point": {"row": 38, "column": 46}, "end_point": {"row": 38, "column": 47}}, {"id": 125, "type": "field_declaration", "text": "int (*read_packet) (demux_cls_t *o, avpacket_t *pkt);", "parent": 77, "children": [126, 127], "start_point": {"row": 39, "column": 4}, "end_point": {"row": 39, "column": 66}}, {"id": 126, "type": "primitive_type", "text": "int", "parent": 125, "children": [], "start_point": {"row": 39, "column": 4}, "end_point": {"row": 39, "column": 7}}, {"id": 127, "type": "function_declarator", "text": "(*read_packet) (demux_cls_t *o, avpacket_t *pkt)", "parent": 125, "children": [128, 132], "start_point": {"row": 39, "column": 13}, "end_point": {"row": 39, "column": 65}}, {"id": 128, "type": "parenthesized_declarator", "text": "(*read_packet)", "parent": 127, "children": [129], "start_point": {"row": 39, "column": 13}, "end_point": {"row": 39, "column": 27}}, {"id": 129, "type": "pointer_declarator", "text": "*read_packet", "parent": 128, "children": [130, 131], "start_point": {"row": 39, "column": 14}, "end_point": {"row": 39, "column": 26}}, {"id": 130, "type": "*", "text": "*", "parent": 129, "children": [], "start_point": {"row": 39, "column": 14}, "end_point": {"row": 39, "column": 15}}, {"id": 131, "type": "field_identifier", "text": "read_packet", "parent": 129, "children": [], "start_point": {"row": 39, "column": 15}, "end_point": {"row": 39, "column": 26}}, {"id": 132, "type": "parameter_list", "text": "(demux_cls_t *o, avpacket_t *pkt)", "parent": 127, "children": [133, 138], "start_point": {"row": 39, "column": 32}, "end_point": {"row": 39, "column": 65}}, {"id": 133, "type": "parameter_declaration", "text": "demux_cls_t *o", "parent": 132, "children": [134, 135], "start_point": {"row": 39, "column": 33}, "end_point": {"row": 39, "column": 47}}, {"id": 134, "type": "type_identifier", "text": "demux_cls_t", "parent": 133, "children": [], "start_point": {"row": 39, "column": 33}, "end_point": {"row": 39, "column": 44}}, {"id": 135, "type": "pointer_declarator", "text": "*o", "parent": 133, "children": [136, 137], "start_point": {"row": 39, "column": 45}, "end_point": {"row": 39, "column": 47}}, {"id": 136, "type": "*", "text": "*", "parent": 135, "children": [], "start_point": {"row": 39, "column": 45}, "end_point": {"row": 39, "column": 46}}, {"id": 137, "type": "identifier", "text": "o", "parent": 135, "children": [], "start_point": {"row": 39, "column": 46}, "end_point": {"row": 39, "column": 47}}, {"id": 138, "type": "parameter_declaration", "text": "avpacket_t *pkt", "parent": 132, "children": [139, 140], "start_point": {"row": 39, "column": 49}, "end_point": {"row": 39, "column": 64}}, {"id": 139, "type": "type_identifier", "text": "avpacket_t", "parent": 138, "children": [], "start_point": {"row": 39, "column": 49}, "end_point": {"row": 39, "column": 59}}, {"id": 140, "type": "pointer_declarator", "text": "*pkt", "parent": 138, "children": [141, 142], "start_point": {"row": 39, "column": 60}, "end_point": {"row": 39, "column": 64}}, {"id": 141, "type": "*", "text": "*", "parent": 140, "children": [], "start_point": {"row": 39, "column": 60}, "end_point": {"row": 39, "column": 61}}, {"id": 142, "type": "identifier", "text": "pkt", "parent": 140, "children": [], "start_point": {"row": 39, "column": 61}, "end_point": {"row": 39, "column": 64}}, {"id": 143, "type": "field_declaration", "text": "int (*seek) (demux_cls_t *o, uint64_t timestamp);", "parent": 77, "children": [144, 145], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 40, "column": 69}}, {"id": 144, "type": "primitive_type", "text": "int", "parent": 143, "children": [], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 40, "column": 7}}, {"id": 145, "type": "function_declarator", "text": "(*seek) (demux_cls_t *o, uint64_t timestamp)", "parent": 143, "children": [146, 150], "start_point": {"row": 40, "column": 13}, "end_point": {"row": 40, "column": 68}}, {"id": 146, "type": "parenthesized_declarator", "text": "(*seek)", "parent": 145, "children": [147], "start_point": {"row": 40, "column": 13}, "end_point": {"row": 40, "column": 20}}, {"id": 147, "type": "pointer_declarator", "text": "*seek", "parent": 146, "children": [148, 149], "start_point": {"row": 40, "column": 14}, "end_point": {"row": 40, "column": 19}}, {"id": 148, "type": "*", "text": "*", "parent": 147, "children": [], "start_point": {"row": 40, "column": 14}, "end_point": {"row": 40, "column": 15}}, {"id": 149, "type": "field_identifier", "text": "seek", "parent": 147, "children": [], "start_point": {"row": 40, "column": 15}, "end_point": {"row": 40, "column": 19}}, {"id": 150, "type": "parameter_list", "text": "(demux_cls_t *o, uint64_t timestamp)", "parent": 145, "children": [151, 156], "start_point": {"row": 40, "column": 32}, "end_point": {"row": 40, "column": 68}}, {"id": 151, "type": "parameter_declaration", "text": "demux_cls_t *o", "parent": 150, "children": [152, 153], "start_point": {"row": 40, "column": 33}, "end_point": {"row": 40, "column": 47}}, {"id": 152, "type": "type_identifier", "text": "demux_cls_t", "parent": 151, "children": [], "start_point": {"row": 40, "column": 33}, "end_point": {"row": 40, "column": 44}}, {"id": 153, "type": "pointer_declarator", "text": "*o", "parent": 151, "children": [154, 155], "start_point": {"row": 40, "column": 45}, "end_point": {"row": 40, "column": 47}}, {"id": 154, "type": "*", "text": "*", "parent": 153, "children": [], "start_point": {"row": 40, "column": 45}, "end_point": {"row": 40, "column": 46}}, {"id": 155, "type": "identifier", "text": "o", "parent": 153, "children": [], "start_point": {"row": 40, "column": 46}, "end_point": {"row": 40, "column": 47}}, {"id": 156, "type": "parameter_declaration", "text": "uint64_t timestamp", "parent": 150, "children": [157, 158], "start_point": {"row": 40, "column": 49}, "end_point": {"row": 40, "column": 67}}, {"id": 157, "type": "primitive_type", "text": "uint64_t", "parent": 156, "children": [], "start_point": {"row": 40, "column": 49}, "end_point": {"row": 40, "column": 57}}, {"id": 158, "type": "identifier", "text": "timestamp", "parent": 156, "children": [], "start_point": {"row": 40, "column": 58}, "end_point": {"row": 40, "column": 67}}, {"id": 159, "type": "field_declaration", "text": "int (*control) (demux_cls_t *o, int cmd, void *arg, size_t *arg_size);", "parent": 77, "children": [160, 161], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 41, "column": 87}}, {"id": 160, "type": "primitive_type", "text": "int", "parent": 159, "children": [], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 41, "column": 7}}, {"id": 161, "type": "function_declarator", "text": "(*control) (demux_cls_t *o, int cmd, void *arg, size_t *arg_size)", "parent": 159, "children": [162, 166], "start_point": {"row": 41, "column": 13}, "end_point": {"row": 41, "column": 86}}, {"id": 162, "type": "parenthesized_declarator", "text": "(*control)", "parent": 161, "children": [163], "start_point": {"row": 41, "column": 13}, "end_point": {"row": 41, "column": 23}}, {"id": 163, "type": "pointer_declarator", "text": "*control", "parent": 162, "children": [164, 165], "start_point": {"row": 41, "column": 14}, "end_point": {"row": 41, "column": 22}}, {"id": 164, "type": "*", "text": "*", "parent": 163, "children": [], "start_point": {"row": 41, "column": 14}, "end_point": {"row": 41, "column": 15}}, {"id": 165, "type": "field_identifier", "text": "control", "parent": 163, "children": [], "start_point": {"row": 41, "column": 15}, "end_point": {"row": 41, "column": 22}}, {"id": 166, "type": "parameter_list", "text": "(demux_cls_t *o, int cmd, void *arg, size_t *arg_size)", "parent": 161, "children": [167, 172, 175, 180], "start_point": {"row": 41, "column": 32}, "end_point": {"row": 41, "column": 86}}, {"id": 167, "type": "parameter_declaration", "text": "demux_cls_t *o", "parent": 166, "children": [168, 169], "start_point": {"row": 41, "column": 33}, "end_point": {"row": 41, "column": 47}}, {"id": 168, "type": "type_identifier", "text": "demux_cls_t", "parent": 167, "children": [], "start_point": {"row": 41, "column": 33}, "end_point": {"row": 41, "column": 44}}, {"id": 169, "type": "pointer_declarator", "text": "*o", "parent": 167, "children": [170, 171], "start_point": {"row": 41, "column": 45}, "end_point": {"row": 41, "column": 47}}, {"id": 170, "type": "*", "text": "*", "parent": 169, "children": [], "start_point": {"row": 41, "column": 45}, "end_point": {"row": 41, "column": 46}}, {"id": 171, "type": "identifier", "text": "o", "parent": 169, "children": [], "start_point": {"row": 41, "column": 46}, "end_point": {"row": 41, "column": 47}}, {"id": 172, "type": "parameter_declaration", "text": "int cmd", "parent": 166, "children": [173, 174], "start_point": {"row": 41, "column": 49}, "end_point": {"row": 41, "column": 56}}, {"id": 173, "type": "primitive_type", "text": "int", "parent": 172, "children": [], "start_point": {"row": 41, "column": 49}, "end_point": {"row": 41, "column": 52}}, {"id": 174, "type": "identifier", "text": "cmd", "parent": 172, "children": [], "start_point": {"row": 41, "column": 53}, "end_point": {"row": 41, "column": 56}}, {"id": 175, "type": "parameter_declaration", "text": "void *arg", "parent": 166, "children": [176, 177], "start_point": {"row": 41, "column": 58}, "end_point": {"row": 41, "column": 67}}, {"id": 176, "type": "primitive_type", "text": "void", "parent": 175, "children": [], "start_point": {"row": 41, "column": 58}, "end_point": {"row": 41, "column": 62}}, {"id": 177, "type": "pointer_declarator", "text": "*arg", "parent": 175, "children": [178, 179], "start_point": {"row": 41, "column": 63}, "end_point": {"row": 41, "column": 67}}, {"id": 178, "type": "*", "text": "*", "parent": 177, "children": [], "start_point": {"row": 41, "column": 63}, "end_point": {"row": 41, "column": 64}}, {"id": 179, "type": "identifier", "text": "arg", "parent": 177, "children": [], "start_point": {"row": 41, "column": 64}, "end_point": {"row": 41, "column": 67}}, {"id": 180, "type": "parameter_declaration", "text": "size_t *arg_size", "parent": 166, "children": [181, 182], "start_point": {"row": 41, "column": 69}, "end_point": {"row": 41, "column": 85}}, {"id": 181, "type": "primitive_type", "text": "size_t", "parent": 180, "children": [], "start_point": {"row": 41, "column": 69}, "end_point": {"row": 41, "column": 75}}, {"id": 182, "type": "pointer_declarator", "text": "*arg_size", "parent": 180, "children": [183, 184], "start_point": {"row": 41, "column": 76}, "end_point": {"row": 41, "column": 85}}, {"id": 183, "type": "*", "text": "*", "parent": 182, "children": [], "start_point": {"row": 41, "column": 76}, "end_point": {"row": 41, "column": 77}}, {"id": 184, "type": "identifier", "text": "arg_size", "parent": 182, "children": [], "start_point": {"row": 41, "column": 77}, "end_point": {"row": 41, "column": 85}}, {"id": 185, "type": "field_declaration", "text": "int (*close) (demux_cls_t *o);", "parent": 77, "children": [186, 187], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 49}}, {"id": 186, "type": "primitive_type", "text": "int", "parent": 185, "children": [], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 7}}, {"id": 187, "type": "function_declarator", "text": "(*close) (demux_cls_t *o)", "parent": 185, "children": [188, 192], "start_point": {"row": 42, "column": 13}, "end_point": {"row": 42, "column": 48}}, {"id": 188, "type": "parenthesized_declarator", "text": "(*close)", "parent": 187, "children": [189], "start_point": {"row": 42, "column": 13}, "end_point": {"row": 42, "column": 21}}, {"id": 189, "type": "pointer_declarator", "text": "*close", "parent": 188, "children": [190, 191], "start_point": {"row": 42, "column": 14}, "end_point": {"row": 42, "column": 20}}, {"id": 190, "type": "*", "text": "*", "parent": 189, "children": [], "start_point": {"row": 42, "column": 14}, "end_point": {"row": 42, "column": 15}}, {"id": 191, "type": "field_identifier", "text": "close", "parent": 189, "children": [], "start_point": {"row": 42, "column": 15}, "end_point": {"row": 42, "column": 20}}, {"id": 192, "type": "parameter_list", "text": "(demux_cls_t *o)", "parent": 187, "children": [193], "start_point": {"row": 42, "column": 32}, "end_point": {"row": 42, "column": 48}}, {"id": 193, "type": "parameter_declaration", "text": "demux_cls_t *o", "parent": 192, "children": [194, 195], "start_point": {"row": 42, "column": 33}, "end_point": {"row": 42, "column": 47}}, {"id": 194, "type": "type_identifier", "text": "demux_cls_t", "parent": 193, "children": [], "start_point": {"row": 42, "column": 33}, "end_point": {"row": 42, "column": 44}}, {"id": 195, "type": "pointer_declarator", "text": "*o", "parent": 193, "children": [196, 197], "start_point": {"row": 42, "column": 45}, "end_point": {"row": 42, "column": 47}}, {"id": 196, "type": "*", "text": "*", "parent": 195, "children": [], "start_point": {"row": 42, "column": 45}, "end_point": {"row": 42, "column": 46}}, {"id": 197, "type": "identifier", "text": "o", "parent": 195, "children": [], "start_point": {"row": 42, "column": 46}, "end_point": {"row": 42, "column": 47}}, {"id": 198, "type": "struct_specifier", "text": "struct demux_cls {\n stream_cls_t *s;\n sh_audio_t ash;\n aos_mutex_t lock;\n avpacket_t fpkt; ///< reserved, the first packet for mp3, etc\n size_t id3v2size; ///< TODO:\n uint64_t bps;\n size_t time_scale; ///< only for audio\n uint64_t duration; ///< only for audio, ms\n track_info_t *tracks; ///< TODO: need call tracks_info_freep when unused\n\n avparser_t *psr;\n slist_t list_free; ///< free avpacket_list for psr\n slist_t list_ready; ///< ready avpacket_list for psr\n\n void *priv;\n const struct demux_ops *ops;\n}", "parent": 0, "children": [199, 200], "start_point": {"row": 45, "column": 0}, "end_point": {"row": 62, "column": 1}}, {"id": 199, "type": "struct", "text": "struct", "parent": 198, "children": [], "start_point": {"row": 45, "column": 0}, "end_point": {"row": 45, "column": 6}}, {"id": 200, "type": "type_identifier", "text": "demux_cls", "parent": 198, "children": [], "start_point": {"row": 45, "column": 7}, "end_point": {"row": 45, "column": 16}}, {"id": 201, "type": "field_declaration", "text": "stream_cls_t *s;", "parent": 198, "children": [202, 203], "start_point": {"row": 46, "column": 4}, "end_point": {"row": 46, "column": 35}}, {"id": 202, "type": "type_identifier", "text": "stream_cls_t", "parent": 201, "children": [], "start_point": {"row": 46, "column": 4}, "end_point": {"row": 46, "column": 16}}, {"id": 203, "type": "pointer_declarator", "text": "*s", "parent": 201, "children": [204, 205], "start_point": {"row": 46, "column": 32}, "end_point": {"row": 46, "column": 34}}, {"id": 204, "type": "*", "text": "*", "parent": 203, "children": [], "start_point": {"row": 46, "column": 32}, "end_point": {"row": 46, "column": 33}}, {"id": 205, "type": "field_identifier", "text": "s", "parent": 203, "children": [], "start_point": {"row": 46, "column": 33}, "end_point": {"row": 46, "column": 34}}, {"id": 206, "type": "field_declaration", "text": "sh_audio_t ash;", "parent": 198, "children": [207, 208], "start_point": {"row": 47, "column": 4}, "end_point": {"row": 47, "column": 36}}, {"id": 207, "type": "type_identifier", "text": "sh_audio_t", "parent": 206, "children": [], "start_point": {"row": 47, "column": 4}, "end_point": {"row": 47, "column": 14}}, {"id": 208, "type": "field_identifier", "text": "ash", "parent": 206, "children": [], "start_point": {"row": 47, "column": 32}, "end_point": {"row": 47, "column": 35}}, {"id": 209, "type": "field_declaration", "text": "aos_mutex_t lock;", "parent": 198, "children": [210, 211], "start_point": {"row": 48, "column": 4}, "end_point": {"row": 48, "column": 37}}, {"id": 210, "type": "type_identifier", "text": "aos_mutex_t", "parent": 209, "children": [], "start_point": {"row": 48, "column": 4}, "end_point": {"row": 48, "column": 15}}, {"id": 211, "type": "field_identifier", "text": "lock", "parent": 209, "children": [], "start_point": {"row": 48, "column": 32}, "end_point": {"row": 48, "column": 36}}, {"id": 212, "type": "field_declaration", "text": "avpacket_t fpkt;", "parent": 198, "children": [213, 214], "start_point": {"row": 49, "column": 4}, "end_point": {"row": 49, "column": 37}}, {"id": 213, "type": "type_identifier", "text": "avpacket_t", "parent": 212, "children": [], "start_point": {"row": 49, "column": 4}, "end_point": {"row": 49, "column": 14}}, {"id": 214, "type": "field_identifier", "text": "fpkt", "parent": 212, "children": [], "start_point": {"row": 49, "column": 32}, "end_point": {"row": 49, "column": 36}}, {"id": 215, "type": "field_declaration", "text": "size_t id3v2size;", "parent": 198, "children": [216, 217], "start_point": {"row": 50, "column": 4}, "end_point": {"row": 50, "column": 42}}, {"id": 216, "type": "primitive_type", "text": "size_t", "parent": 215, "children": [], "start_point": {"row": 50, "column": 4}, "end_point": {"row": 50, "column": 10}}, {"id": 217, "type": "field_identifier", "text": "id3v2size", "parent": 215, "children": [], "start_point": {"row": 50, "column": 32}, "end_point": {"row": 50, "column": 41}}, {"id": 218, "type": "field_declaration", "text": "uint64_t bps;", "parent": 198, "children": [219, 220], "start_point": {"row": 51, "column": 4}, "end_point": {"row": 51, "column": 36}}, {"id": 219, "type": "primitive_type", "text": "uint64_t", "parent": 218, "children": [], "start_point": {"row": 51, "column": 4}, "end_point": {"row": 51, "column": 12}}, {"id": 220, "type": "field_identifier", "text": "bps", "parent": 218, "children": [], "start_point": {"row": 51, "column": 32}, "end_point": {"row": 51, "column": 35}}, {"id": 221, "type": "field_declaration", "text": "size_t time_scale;", "parent": 198, "children": [222, 223], "start_point": {"row": 52, "column": 4}, "end_point": {"row": 52, "column": 43}}, {"id": 222, "type": "primitive_type", "text": "size_t", "parent": 221, "children": [], "start_point": {"row": 52, "column": 4}, "end_point": {"row": 52, "column": 10}}, {"id": 223, "type": "field_identifier", "text": "time_scale", "parent": 221, "children": [], "start_point": {"row": 52, "column": 32}, "end_point": {"row": 52, "column": 42}}, {"id": 224, "type": "field_declaration", "text": "uint64_t duration;", "parent": 198, "children": [225, 226], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 41}}, {"id": 225, "type": "primitive_type", "text": "uint64_t", "parent": 224, "children": [], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 12}}, {"id": 226, "type": "field_identifier", "text": "duration", "parent": 224, "children": [], "start_point": {"row": 53, "column": 32}, "end_point": {"row": 53, "column": 40}}, {"id": 227, "type": "field_declaration", "text": "track_info_t *tracks;", "parent": 198, "children": [228, 229], "start_point": {"row": 54, "column": 4}, "end_point": {"row": 54, "column": 40}}, {"id": 228, "type": "type_identifier", "text": "track_info_t", "parent": 227, "children": [], "start_point": {"row": 54, "column": 4}, "end_point": {"row": 54, "column": 16}}, {"id": 229, "type": "pointer_declarator", "text": "*tracks", "parent": 227, "children": [230, 231], "start_point": {"row": 54, "column": 32}, "end_point": {"row": 54, "column": 39}}, {"id": 230, "type": "*", "text": "*", "parent": 229, "children": [], "start_point": {"row": 54, "column": 32}, "end_point": {"row": 54, "column": 33}}, {"id": 231, "type": "field_identifier", "text": "tracks", "parent": 229, "children": [], "start_point": {"row": 54, "column": 33}, "end_point": {"row": 54, "column": 39}}, {"id": 232, "type": "field_declaration", "text": "avparser_t *psr;", "parent": 198, "children": [233, 234], "start_point": {"row": 56, "column": 4}, "end_point": {"row": 56, "column": 37}}, {"id": 233, "type": "type_identifier", "text": "avparser_t", "parent": 232, "children": [], "start_point": {"row": 56, "column": 4}, "end_point": {"row": 56, "column": 14}}, {"id": 234, "type": "pointer_declarator", "text": "*psr", "parent": 232, "children": [235, 236], "start_point": {"row": 56, "column": 32}, "end_point": {"row": 56, "column": 36}}, {"id": 235, "type": "*", "text": "*", "parent": 234, "children": [], "start_point": {"row": 56, "column": 32}, "end_point": {"row": 56, "column": 33}}, {"id": 236, "type": "field_identifier", "text": "psr", "parent": 234, "children": [], "start_point": {"row": 56, "column": 33}, "end_point": {"row": 56, "column": 36}}, {"id": 237, "type": "field_declaration", "text": "slist_t list_free;", "parent": 198, "children": [238, 239], "start_point": {"row": 57, "column": 4}, "end_point": {"row": 57, "column": 42}}, {"id": 238, "type": "type_identifier", "text": "slist_t", "parent": 237, "children": [], "start_point": {"row": 57, "column": 4}, "end_point": {"row": 57, "column": 11}}, {"id": 239, "type": "field_identifier", "text": "list_free", "parent": 237, "children": [], "start_point": {"row": 57, "column": 32}, "end_point": {"row": 57, "column": 41}}, {"id": 240, "type": "field_declaration", "text": "slist_t list_ready;", "parent": 198, "children": [241, 242], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 43}}, {"id": 241, "type": "type_identifier", "text": "slist_t", "parent": 240, "children": [], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 11}}, {"id": 242, "type": "field_identifier", "text": "list_ready", "parent": 240, "children": [], "start_point": {"row": 58, "column": 32}, "end_point": {"row": 58, "column": 42}}, {"id": 243, "type": "field_declaration", "text": "void *priv;", "parent": 198, "children": [244, 245], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 38}}, {"id": 244, "type": "primitive_type", "text": "void", "parent": 243, "children": [], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 8}}, {"id": 245, "type": "pointer_declarator", "text": "*priv", "parent": 243, "children": [246, 247], "start_point": {"row": 60, "column": 32}, "end_point": {"row": 60, "column": 37}}, {"id": 246, "type": "*", "text": "*", "parent": 245, "children": [], "start_point": {"row": 60, "column": 32}, "end_point": {"row": 60, "column": 33}}, {"id": 247, "type": "field_identifier", "text": "priv", "parent": 245, "children": [], "start_point": {"row": 60, "column": 33}, "end_point": {"row": 60, "column": 37}}, {"id": 248, "type": "field_declaration", "text": "const struct demux_ops *ops;", "parent": 198, "children": [249, 252], "start_point": {"row": 61, "column": 4}, "end_point": {"row": 61, "column": 37}}, {"id": 249, "type": "struct_specifier", "text": "struct demux_ops", "parent": 248, "children": [250, 251], "start_point": {"row": 61, "column": 10}, "end_point": {"row": 61, "column": 26}}, {"id": 250, "type": "struct", "text": "struct", "parent": 249, "children": [], "start_point": {"row": 61, "column": 10}, "end_point": {"row": 61, "column": 16}}, {"id": 251, "type": "type_identifier", "text": "demux_ops", "parent": 249, "children": [], "start_point": {"row": 61, "column": 17}, "end_point": {"row": 61, "column": 26}}, {"id": 252, "type": "pointer_declarator", "text": "*ops", "parent": 248, "children": [253, 254], "start_point": {"row": 61, "column": 32}, "end_point": {"row": 61, "column": 36}}, {"id": 253, "type": "*", "text": "*", "parent": 252, "children": [], "start_point": {"row": 61, "column": 32}, "end_point": {"row": 61, "column": 33}}, {"id": 254, "type": "field_identifier", "text": "ops", "parent": 252, "children": [], "start_point": {"row": 61, "column": 33}, "end_point": {"row": 61, "column": 36}}, {"id": 255, "type": "type_identifier", "text": "__END_DECLS__", "parent": 0, "children": [], "start_point": {"row": 64, "column": 0}, "end_point": {"row": 64, "column": 13}}, {"id": 256, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 66, "column": 0}, "end_point": {"row": 66, "column": 6}}]}, "node_categories": {"declarations": {"functions": [101, 114, 127, 145, 161, 187], "variables": [21, 24, 29, 58, 63, 66, 71, 84, 89, 92, 99, 107, 112, 120, 125, 133, 138, 143, 151, 156, 159, 167, 172, 175, 180, 185, 193, 201, 206, 209, 212, 215, 218, 221, 224, 227, 232, 237, 240, 243, 248], "classes": [25, 26, 31, 32, 77, 78, 198, 199, 249, 250], "imports": [6, 7, 9, 10, 12, 13, 15, 16, 18, 19], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 22, 23, 27, 28, 33, 36, 40, 44, 48, 52, 56, 62, 65, 70, 74, 76, 79, 82, 88, 91, 97, 98, 105, 108, 111, 118, 121, 124, 131, 134, 137, 139, 142, 149, 152, 155, 158, 165, 168, 171, 174, 179, 184, 191, 194, 197, 200, 202, 205, 207, 208, 210, 211, 213, 214, 217, 220, 223, 226, 228, 231, 233, 236, 238, 239, 241, 242, 247, 251, 254, 255, 256], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [8, 11, 14, 17, 20, 75], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 101, "universal_type": "function", "name": "unknown", "text_snippet": "(*read_probe) (const avprobe_data_t *pd)"}, {"node_id": 114, "universal_type": "function", "name": "unknown", "text_snippet": "(*open) (demux_cls_t *o)"}, {"node_id": 127, "universal_type": "function", "name": "unknown", "text_snippet": "(*read_packet) (demux_cls_t *o, avpacket_t *pkt)"}, {"node_id": 145, "universal_type": "function", "name": "unknown", "text_snippet": "(*seek) (demux_cls_t *o, uint64_t timestamp)"}, {"node_id": 161, "universal_type": "function", "name": "cmd,", "text_snippet": "(*control) (demux_cls_t *o, int cmd, void *arg, size_t *arg_size)"}, {"node_id": 187, "universal_type": "function", "name": "unknown", "text_snippet": "(*close) (demux_cls_t *o)"}], "class_declarations": [{"node_id": 25, "universal_type": "class", "name": "demux_cls", "text_snippet": "struct demux_cls"}, {"node_id": 26, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 31, "universal_type": "class", "name": "avprobe_data", "text_snippet": "struct avprobe_data {\n#define AVPROBE_SCORE_GUESS (50)\n#define AVPROBE_SCORE_EXTENSION (60)\n#def"}, {"node_id": 32, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 77, "universal_type": "class", "name": "demux_ops", "text_snippet": "struct demux_ops {\n#define MAX_EXTENTSIONS (5)\n const char *name;\n uint8_t "}, {"node_id": 78, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 198, "universal_type": "class", "name": "demux_cls", "text_snippet": "struct demux_cls {\n stream_cls_t *s;\n sh_audio_t ash;\n aos_"}, {"node_id": 199, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 249, "universal_type": "class", "name": "demux_ops", "text_snippet": "struct demux_ops"}, {"node_id": 250, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": [{"node_id": 6, "text": "#include \"avutil/av_config.h\"\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include \"avutil/av_typedef.h\"\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include \"avutil/avpacket.h\"\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include \"stream/stream_cls.h\"\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include \"avformat/avparser_cls.h\"\n"}, {"node_id": 19, "text": "#include"}]}, "original_source_code": "/*\n * Copyright (C) 2018-2020 Alibaba Group Holding Limited\n */\n\n#ifndef __DEMUX_CLS_H__\n#define __DEMUX_CLS_H__\n\n#include \"avutil/av_config.h\"\n#include \"avutil/av_typedef.h\"\n#include \"avutil/avpacket.h\"\n#include \"stream/stream_cls.h\"\n#include \"avformat/avparser_cls.h\"\n\n__BEGIN_DECLS__\n\ntypedef struct demux_cls demux_cls_t;\n\ntypedef struct avprobe_data {\n#define AVPROBE_SCORE_GUESS (50)\n#define AVPROBE_SCORE_EXTENSION (60)\n#define AVPROBE_SCORE_MIME (75)\n#define AVPROBE_SCORE_NAME (80)\n#define AVPROBE_SCORE_AGAIN (85) ///< next frame(not need sync) probe ok\n#define AVPROBE_SCORE_MAX (100)\n uint8_t *buf;\n int32_t buf_size;\n const char *filename;\n char avformat[16];\n} avprobe_data_t;\n\nstruct demux_ops {\n#define MAX_EXTENTSIONS (5)\n const char *name;\n uint8_t type;\n const char *extensions[MAX_EXTENTSIONS];\n\n int (*read_probe) (const avprobe_data_t *pd);\n\n int (*open) (demux_cls_t *o);\n int (*read_packet) (demux_cls_t *o, avpacket_t *pkt);\n int (*seek) (demux_cls_t *o, uint64_t timestamp);\n int (*control) (demux_cls_t *o, int cmd, void *arg, size_t *arg_size);\n int (*close) (demux_cls_t *o);\n};\n\nstruct demux_cls {\n stream_cls_t *s;\n sh_audio_t ash;\n aos_mutex_t lock;\n avpacket_t fpkt; ///< reserved, the first packet for mp3, etc\n size_t id3v2size; ///< TODO:\n uint64_t bps;\n size_t time_scale; ///< only for audio\n uint64_t duration; ///< only for audio, ms\n track_info_t *tracks; ///< TODO: need call tracks_info_freep when unused\n\n avparser_t *psr;\n slist_t list_free; ///< free avpacket_list for psr\n slist_t list_ready; ///< ready avpacket_list for psr\n\n void *priv;\n const struct demux_ops *ops;\n};\n\n__END_DECLS__\n\n#endif /* __DEMUX_CLS_H__ */\n\n"}
80,524
c
/* * LCD_I2C_Driver.h */ #ifndef INC_LCD_I2C_DRIVER_H_ #define INC_LCD_I2C_DRIVER_H_ #include "stm32f4xx_hal.h" #define CMD_LCD_CLEAR 0b00000001 #define CMD_LCD_CONTROL_ON 0b00001111 // Display on, cursor on and blinking #define CMD_LCD_CONTROL_OFF 0b00001000 // Display of, cursor off and blinking #define CMD_LCD_SET_4BIT_2LINE 0b00101000 #define CMD_LCD_SET_8BIT_2LINE 0b00111000 #define CMD_LCD_RETURN_HOME 0b00000010 #define CMD_LCD_SET_SECOND_LINE 0b11000000 #define CMD_LCD_ENTRY_MODE_INC 0b00000110 #define CMD_LCD_ENTRY_MODE_SHIFT 0b00000111 #define CMD_LCD_SHIFT_CURSOR_LEFT 0b00010000 #define CMD_LCD_SHIFT_CURSOR_RIGHT 0b00010100 #define BG_BIT_POSITION 3 /* * Handle struct für LCD */ typedef struct { I2C_HandleTypeDef *i2c_handle; uint16_t Slave_address; uint8_t bg; // Background switch }LCD_Handle_t; // Sendet das Kommando in cmd angegebene Kommando an das Display (instruction Mode) // und führt es aus. void lcd_command(LCD_Handle_t* lcd_config, uint8_t cmd); // Inistialiserung des Displays void lcd_init(LCD_Handle_t* lcd_config); void printLetter(LCD_Handle_t* lcd_config, uint8_t letter); void printText(LCD_Handle_t* lcd_config, char *Text, uint32_t delayvalue); #endif /* INC_LCD_I2C_DRIVER_H_ */
27.06
47
(translation_unit) "/* \n * LCD_I2C_Driver.h \n */ \n \n#ifndef INC_LCD_I2C_DRIVER_H_ \n#define INC_LCD_I2C_DRIVER_H_ \n \n#include "stm32f4xx_hal.h" \n \n#define CMD_LCD_CLEAR 0b00000001 \n#define CMD_LCD_CONTROL_ON 0b00001111 // Display on, cursor on and blinking \n#define CMD_LCD_CONTROL_OFF 0b00001000 // Display of, cursor off and blinking \n#define CMD_LCD_SET_4BIT_2LINE 0b00101000 \n#define CMD_LCD_SET_8BIT_2LINE 0b00111000 \n#define CMD_LCD_RETURN_HOME 0b00000010 \n#define CMD_LCD_SET_SECOND_LINE 0b11000000 \n#define CMD_LCD_ENTRY_MODE_INC 0b00000110 \n#define CMD_LCD_ENTRY_MODE_SHIFT 0b00000111 \n#define CMD_LCD_SHIFT_CURSOR_LEFT 0b00010000 \n#define CMD_LCD_SHIFT_CURSOR_RIGHT 0b00010100 \n \n#define BG_BIT_POSITION 3 \n \n/* \n * Handle struct für LCD \n */ \ntypedef struct \n{ \n I2C_HandleTypeDef *i2c_handle; \n uint16_t Slave_address; \n uint8_t bg; // Background switch \n}LCD_Handle_t; \n \n \n// Sendet das Kommando in cmd angegebene Kommando an das Display (instruction Mode) \n// und führt es aus. \nvoid lcd_command(LCD_Handle_t* lcd_config, uint8_t cmd); \n \n// Inistialiserung des Displays \nvoid lcd_init(LCD_Handle_t* lcd_config); \n \nvoid printLetter(LCD_Handle_t* lcd_config, uint8_t letter); \n \nvoid printText(LCD_Handle_t* lcd_config, char *Text, uint32_t delayvalue); \n \n \n#endif /* INC_LCD_I2C_DRIVER_H_ */ \n \n \n \n" (comment) "/* \n * LCD_I2C_Driver.h \n */" (preproc_ifdef) "#ifndef INC_LCD_I2C_DRIVER_H_ \n#define INC_LCD_I2C_DRIVER_H_ \n \n#include "stm32f4xx_hal.h" \n \n#define CMD_LCD_CLEAR 0b00000001 \n#define CMD_LCD_CONTROL_ON 0b00001111 // Display on, cursor on and blinking \n#define CMD_LCD_CONTROL_OFF 0b00001000 // Display of, cursor off and blinking \n#define CMD_LCD_SET_4BIT_2LINE 0b00101000 \n#define CMD_LCD_SET_8BIT_2LINE 0b00111000 \n#define CMD_LCD_RETURN_HOME 0b00000010 \n#define CMD_LCD_SET_SECOND_LINE 0b11000000 \n#define CMD_LCD_ENTRY_MODE_INC 0b00000110 \n#define CMD_LCD_ENTRY_MODE_SHIFT 0b00000111 \n#define CMD_LCD_SHIFT_CURSOR_LEFT 0b00010000 \n#define CMD_LCD_SHIFT_CURSOR_RIGHT 0b00010100 \n \n#define BG_BIT_POSITION 3 \n \n/* \n * Handle struct für LCD \n */ \ntypedef struct \n{ \n I2C_HandleTypeDef *i2c_handle; \n uint16_t Slave_address; \n uint8_t bg; // Background switch \n}LCD_Handle_t; \n \n \n// Sendet das Kommando in cmd angegebene Kommando an das Display (instruction Mode) \n// und führt es aus. \nvoid lcd_command(LCD_Handle_t* lcd_config, uint8_t cmd); \n \n// Inistialiserung des Displays \nvoid lcd_init(LCD_Handle_t* lcd_config); \n \nvoid printLetter(LCD_Handle_t* lcd_config, uint8_t letter); \n \nvoid printText(LCD_Handle_t* lcd_config, char *Text, uint32_t delayvalue); \n \n \n#endif /" (#ifndef) "#ifndef" (identifier) "INC_LCD_I2C_DRIVER_H_" (preproc_def) "#define INC_LCD_I2C_DRIVER_H_ \n" (#define) "#define" (identifier) "INC_LCD_I2C_DRIVER_H_" (preproc_include) "#include "stm32f4xx_hal.h" \n" (#include) "#include" (string_literal) ""stm32f4xx_hal.h"" (") """ (string_content) "stm32f4xx_hal.h" (") """ (preproc_def) "#define CMD_LCD_CLEAR 0b00000001 \n" (#define) "#define" (identifier) "CMD_LCD_CLEAR" (preproc_arg) "0b00000001 " (preproc_def) "#define CMD_LCD_CONTROL_ON 0b00001111 // Display on, cursor on and blinking \n" (#define) "#define" (identifier) "CMD_LCD_CONTROL_ON" (preproc_arg) "0b00001111 // Display on, cursor on and blinking " (preproc_def) "#define CMD_LCD_CONTROL_OFF 0b00001000 // Display of, cursor off and blinking \n" (#define) "#define" (identifier) "CMD_LCD_CONTROL_OFF" (preproc_arg) "0b00001000 // Display of, cursor off and blinking " (preproc_def) "#define CMD_LCD_SET_4BIT_2LINE 0b00101000 \n" (#define) "#define" (identifier) "CMD_LCD_SET_4BIT_2LINE" (preproc_arg) "0b00101000 " (preproc_def) "#define CMD_LCD_SET_8BIT_2LINE 0b00111000 \n" (#define) "#define" (identifier) "CMD_LCD_SET_8BIT_2LINE" (preproc_arg) "0b00111000 " (preproc_def) "#define CMD_LCD_RETURN_HOME 0b00000010 \n" (#define) "#define" (identifier) "CMD_LCD_RETURN_HOME" (preproc_arg) "0b00000010 " (preproc_def) "#define CMD_LCD_SET_SECOND_LINE 0b11000000 \n" (#define) "#define" (identifier) "CMD_LCD_SET_SECOND_LINE" (preproc_arg) "0b11000000 " (preproc_def) "#define CMD_LCD_ENTRY_MODE_INC 0b00000110 \n" (#define) "#define" (identifier) "CMD_LCD_ENTRY_MODE_INC" (preproc_arg) "0b00000110 " (preproc_def) "#define CMD_LCD_ENTRY_MODE_SHIFT 0b00000111 \n" (#define) "#define" (identifier) "CMD_LCD_ENTRY_MODE_SHIFT" (preproc_arg) "0b00000111 " (preproc_def) "#define CMD_LCD_SHIFT_CURSOR_LEFT 0b00010000 \n" (#define) "#define" (identifier) "CMD_LCD_SHIFT_CURSOR_LEFT" (preproc_arg) "0b00010000 " (preproc_def) "#define CMD_LCD_SHIFT_CURSOR_RIGHT 0b00010100 \n" (#define) "#define" (identifier) "CMD_LCD_SHIFT_CURSOR_RIGHT" (preproc_arg) "0b00010100 " (preproc_def) "#define BG_BIT_POSITION 3 \n" (#define) "#define" (identifier) "BG_BIT_POSITION" (preproc_arg) "3 " (comment) "/* \n * Handle struct für LCD \n */ " (type_definition) "ypedef struct \n{ \n I2C_HandleTypeDef *i2c_handle; \n uint16_t Slave_address; \n uint8_t bg; // Background switch \n}LCD_Handle_t; " (typedef) "ypedef " (struct_specifier) "truct \n{ \n I2C_HandleTypeDef *i2c_handle; \n uint16_t Slave_address; \n uint8_t bg; // Background switch \n}L" (struct) "truct " (field_declaration_list) " \n I2C_HandleTypeDef *i2c_handle; \n uint16_t Slave_address; \n uint8_t bg; // Background switch \n}L" ({) " " (field_declaration) "2C_HandleTypeDef *i2c_handle; " (type_identifier) "2C_HandleTypeDef " (pointer_declarator) "i2c_handle;" (*) "i" (field_identifier) "2c_handle;" (;) " " (field_declaration) "int16_t Slave_address; " (primitive_type) "int16_t " (field_identifier) "lave_address;" (;) " " (field_declaration) "int8_t bg; " (primitive_type) "int8_t " (field_identifier) "g;" (;) " " (comment) "/ Background switch \n" (}) "L" (type_identifier) "CD_Handle_t;" (;) " " (comment) "/ Sendet das Kommando in cmd angegebene Kommando an das Display (instruction Mode) \n" (comment) "/ und führt es aus. \nv" (declaration) "id lcd_command(LCD_Handle_t* lcd_config, uint8_t cmd); \n" (primitive_type) "id l" (function_declarator) "d_command(LCD_Handle_t* lcd_config, uint8_t cmd); " (identifier) "d_command(L" (parameter_list) "CD_Handle_t* lcd_config, uint8_t cmd); " (() "C" (parameter_declaration) "D_Handle_t* lcd_config, " (type_identifier) "D_Handle_t* " (pointer_declarator) "lcd_config, " (*) "l" (identifier) "d_config, " (,) "u" (parameter_declaration) "nt8_t cmd);" (primitive_type) "nt8_t c" (identifier) "d);" ()) " " (;) "\n" (comment) " Inistialiserung des Displays \nv" (declaration) "id lcd_init(LCD_Handle_t* lcd_config); \n" (primitive_type) "id l" (function_declarator) "d_init(LCD_Handle_t* lcd_config); " (identifier) "d_init(L" (parameter_list) "CD_Handle_t* lcd_config); " (() "C" (parameter_declaration) "D_Handle_t* lcd_config);" (type_identifier) "D_Handle_t* " (pointer_declarator) "lcd_config);" (*) "l" (identifier) "d_config);" ()) " " (;) "\n" (declaration) "id printLetter(LCD_Handle_t* lcd_config, uint8_t letter); \n" (primitive_type) "id p" (function_declarator) "intLetter(LCD_Handle_t* lcd_config, uint8_t letter); " (identifier) "intLetter(L" (parameter_list) "CD_Handle_t* lcd_config, uint8_t letter); " (() "C" (parameter_declaration) "D_Handle_t* lcd_config, " (type_identifier) "D_Handle_t* " (pointer_declarator) "lcd_config, " (*) "l" (identifier) "d_config, " (,) "u" (parameter_declaration) "nt8_t letter);" (primitive_type) "nt8_t l" (identifier) "tter);" ()) " " (;) "\n" (declaration) "id printText(LCD_Handle_t* lcd_config, char *Text, uint32_t delayvalue); \n" (primitive_type) "id p" (function_declarator) "intText(LCD_Handle_t* lcd_config, char *Text, uint32_t delayvalue); " (identifier) "intText(L" (parameter_list) "CD_Handle_t* lcd_config, char *Text, uint32_t delayvalue); " (() "C" (parameter_declaration) "D_Handle_t* lcd_config, " (type_identifier) "D_Handle_t* " (pointer_declarator) "lcd_config, " (*) "l" (identifier) "d_config, " (,) "c" (parameter_declaration) "ar *Text, " (primitive_type) "ar *" (pointer_declarator) "ext, " (*) "e" (identifier) "xt, " (,) "u" (parameter_declaration) "nt32_t delayvalue);" (primitive_type) "nt32_t d" (identifier) "layvalue);" ()) " " (;) "\n" (#endif) "ndif /" (comment) " INC_LCD_I2C_DRIVER_H_ */ \n"
162
0
{"language": "c", "success": true, "metadata": {"lines": 47, "avg_line_length": 27.06, "nodes": 128, "errors": 0, "source_hash": "61077068103a1c148eeffd080bde92809d091cc88408e63671449c505852bb49", "categorized_nodes": 63}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef INC_LCD_I2C_DRIVER_H_\r\n#define INC_LCD_I2C_DRIVER_H_\r\n\r\n#include \"stm32f4xx_hal.h\"\r\n\r\n#define CMD_LCD_CLEAR\t\t\t\t\t0b00000001\r\n#define CMD_LCD_CONTROL_ON \t\t\t\t0b00001111\t// Display on, cursor on and blinking\r\n#define CMD_LCD_CONTROL_OFF \t\t\t0b00001000\t// Display of, cursor off and blinking\r\n#define CMD_LCD_SET_4BIT_2LINE \t\t\t0b00101000\r\n#define CMD_LCD_SET_8BIT_2LINE \t\t\t0b00111000\r\n#define CMD_LCD_RETURN_HOME\t\t\t\t0b00000010\r\n#define CMD_LCD_SET_SECOND_LINE\t\t\t0b11000000\r\n#define CMD_LCD_ENTRY_MODE_INC\t\t\t0b00000110\r\n#define CMD_LCD_ENTRY_MODE_SHIFT\t\t0b00000111\r\n#define CMD_LCD_SHIFT_CURSOR_LEFT\t\t0b00010000\r\n#define CMD_LCD_SHIFT_CURSOR_RIGHT\t\t0b00010100\r\n\r\n#define BG_BIT_POSITION\t\t\t\t\t3\r\n\r\n/*\r\n * Handle struct f\u00fcr LCD\r\n */\r\ntypedef struct\r\n{\r\n\tI2C_HandleTypeDef *i2c_handle;\r\n\tuint16_t Slave_address;\r\n\tuint8_t bg; // Background switch\r\n}LCD_Handle_t;\r\n\r\n\r\n// Sendet das Kommando in cmd angegebene Kommando an das Display (instruction Mode)\r\n// und f\u00fchrt es aus.\r\nvoid lcd_command(LCD_Handle_t* lcd_config, uint8_t cmd);\r\n\r\n// Inistialiserung des Displays\r\nvoid lcd_init(LCD_Handle_t* lcd_config);\r\n\r\nvoid printLetter(LCD_Handle_t* lcd_config, uint8_t letter);\r\n\r\nvoid printText(LCD_Handle_t* lcd_config, char *Text, uint32_t delayvalue);\r\n\r\n\r\n#endif /", "parent": null, "children": [1, 2, 3, 6, 9, 13, 17, 21, 25, 29, 33, 37, 41, 45, 49, 53, 57, 73, 86, 96, 109, 127], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 46, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 7}}, {"id": 2, "type": "identifier", "text": "INC_LCD_I2C_DRIVER_H_", "parent": 0, "children": [], "start_point": {"row": 4, "column": 8}, "end_point": {"row": 4, "column": 29}}, {"id": 3, "type": "preproc_def", "text": "#define INC_LCD_I2C_DRIVER_H_\r\n", "parent": 0, "children": [4, 5], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 7}}, {"id": 5, "type": "identifier", "text": "INC_LCD_I2C_DRIVER_H_", "parent": 3, "children": [], "start_point": {"row": 5, "column": 8}, "end_point": {"row": 5, "column": 29}}, {"id": 6, "type": "preproc_include", "text": "#include \"stm32f4xx_hal.h\"\r\n", "parent": 0, "children": [7, 8], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"stm32f4xx_hal.h\"", "parent": 6, "children": [], "start_point": {"row": 7, "column": 9}, "end_point": {"row": 7, "column": 26}}, {"id": 9, "type": "preproc_def", "text": "#define CMD_LCD_CLEAR\t\t\t\t\t0b00000001\r\n", "parent": 0, "children": [10, 11, 12], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 10, "type": "#define", "text": "#define", "parent": 9, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 7}}, {"id": 11, "type": "identifier", "text": "CMD_LCD_CLEAR", "parent": 9, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 21}}, {"id": 12, "type": "preproc_arg", "text": "0b00000001\r", "parent": 9, "children": [], "start_point": {"row": 9, "column": 26}, "end_point": {"row": 9, "column": 37}}, {"id": 13, "type": "preproc_def", "text": "#define CMD_LCD_CONTROL_ON \t\t\t\t0b00001111\t// Display on, cursor on and blinking\r\n", "parent": 0, "children": [14, 15, 16], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 11, "column": 0}}, {"id": 14, "type": "#define", "text": "#define", "parent": 13, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 7}}, {"id": 15, "type": "identifier", "text": "CMD_LCD_CONTROL_ON", "parent": 13, "children": [], "start_point": {"row": 10, "column": 8}, "end_point": {"row": 10, "column": 26}}, {"id": 16, "type": "preproc_arg", "text": "0b00001111\t// Display on, cursor on and blinking\r", "parent": 13, "children": [], "start_point": {"row": 10, "column": 31}, "end_point": {"row": 10, "column": 80}}, {"id": 17, "type": "preproc_def", "text": "#define CMD_LCD_CONTROL_OFF \t\t\t0b00001000\t// Display of, cursor off and blinking\r\n", "parent": 0, "children": [18, 19, 20], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 12, "column": 0}}, {"id": 18, "type": "#define", "text": "#define", "parent": 17, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 7}}, {"id": 19, "type": "identifier", "text": "CMD_LCD_CONTROL_OFF", "parent": 17, "children": [], "start_point": {"row": 11, "column": 8}, "end_point": {"row": 11, "column": 27}}, {"id": 20, "type": "preproc_arg", "text": "0b00001000\t// Display of, cursor off and blinking\r", "parent": 17, "children": [], "start_point": {"row": 11, "column": 31}, "end_point": {"row": 11, "column": 81}}, {"id": 21, "type": "preproc_def", "text": "#define CMD_LCD_SET_4BIT_2LINE \t\t\t0b00101000\r\n", "parent": 0, "children": [22, 23, 24], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 13, "column": 0}}, {"id": 22, "type": "#define", "text": "#define", "parent": 21, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 7}}, {"id": 23, "type": "identifier", "text": "CMD_LCD_SET_4BIT_2LINE", "parent": 21, "children": [], "start_point": {"row": 12, "column": 8}, "end_point": {"row": 12, "column": 30}}, {"id": 24, "type": "preproc_arg", "text": "0b00101000\r", "parent": 21, "children": [], "start_point": {"row": 12, "column": 34}, "end_point": {"row": 12, "column": 45}}, {"id": 25, "type": "preproc_def", "text": "#define CMD_LCD_SET_8BIT_2LINE \t\t\t0b00111000\r\n", "parent": 0, "children": [26, 27, 28], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 14, "column": 0}}, {"id": 26, "type": "#define", "text": "#define", "parent": 25, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 7}}, {"id": 27, "type": "identifier", "text": "CMD_LCD_SET_8BIT_2LINE", "parent": 25, "children": [], "start_point": {"row": 13, "column": 8}, "end_point": {"row": 13, "column": 30}}, {"id": 28, "type": "preproc_arg", "text": "0b00111000\r", "parent": 25, "children": [], "start_point": {"row": 13, "column": 34}, "end_point": {"row": 13, "column": 45}}, {"id": 29, "type": "preproc_def", "text": "#define CMD_LCD_RETURN_HOME\t\t\t\t0b00000010\r\n", "parent": 0, "children": [30, 31, 32], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 15, "column": 0}}, {"id": 30, "type": "#define", "text": "#define", "parent": 29, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 7}}, {"id": 31, "type": "identifier", "text": "CMD_LCD_RETURN_HOME", "parent": 29, "children": [], "start_point": {"row": 14, "column": 8}, "end_point": {"row": 14, "column": 27}}, {"id": 32, "type": "preproc_arg", "text": "0b00000010\r", "parent": 29, "children": [], "start_point": {"row": 14, "column": 31}, "end_point": {"row": 14, "column": 42}}, {"id": 33, "type": "preproc_def", "text": "#define CMD_LCD_SET_SECOND_LINE\t\t\t0b11000000\r\n", "parent": 0, "children": [34, 35, 36], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 34, "type": "#define", "text": "#define", "parent": 33, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 7}}, {"id": 35, "type": "identifier", "text": "CMD_LCD_SET_SECOND_LINE", "parent": 33, "children": [], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 31}}, {"id": 36, "type": "preproc_arg", "text": "0b11000000\r", "parent": 33, "children": [], "start_point": {"row": 15, "column": 34}, "end_point": {"row": 15, "column": 45}}, {"id": 37, "type": "preproc_def", "text": "#define CMD_LCD_ENTRY_MODE_INC\t\t\t0b00000110\r\n", "parent": 0, "children": [38, 39, 40], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 17, "column": 0}}, {"id": 38, "type": "#define", "text": "#define", "parent": 37, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 7}}, {"id": 39, "type": "identifier", "text": "CMD_LCD_ENTRY_MODE_INC", "parent": 37, "children": [], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 30}}, {"id": 40, "type": "preproc_arg", "text": "0b00000110\r", "parent": 37, "children": [], "start_point": {"row": 16, "column": 33}, "end_point": {"row": 16, "column": 44}}, {"id": 41, "type": "preproc_def", "text": "#define CMD_LCD_ENTRY_MODE_SHIFT\t\t0b00000111\r\n", "parent": 0, "children": [42, 43, 44], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 18, "column": 0}}, {"id": 42, "type": "#define", "text": "#define", "parent": 41, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 7}}, {"id": 43, "type": "identifier", "text": "CMD_LCD_ENTRY_MODE_SHIFT", "parent": 41, "children": [], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 17, "column": 32}}, {"id": 44, "type": "preproc_arg", "text": "0b00000111\r", "parent": 41, "children": [], "start_point": {"row": 17, "column": 34}, "end_point": {"row": 17, "column": 45}}, {"id": 45, "type": "preproc_def", "text": "#define CMD_LCD_SHIFT_CURSOR_LEFT\t\t0b00010000\r\n", "parent": 0, "children": [46, 47, 48], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 19, "column": 0}}, {"id": 46, "type": "#define", "text": "#define", "parent": 45, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 7}}, {"id": 47, "type": "identifier", "text": "CMD_LCD_SHIFT_CURSOR_LEFT", "parent": 45, "children": [], "start_point": {"row": 18, "column": 8}, "end_point": {"row": 18, "column": 33}}, {"id": 48, "type": "preproc_arg", "text": "0b00010000\r", "parent": 45, "children": [], "start_point": {"row": 18, "column": 35}, "end_point": {"row": 18, "column": 46}}, {"id": 49, "type": "preproc_def", "text": "#define CMD_LCD_SHIFT_CURSOR_RIGHT\t\t0b00010100\r\n", "parent": 0, "children": [50, 51, 52], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 20, "column": 0}}, {"id": 50, "type": "#define", "text": "#define", "parent": 49, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 7}}, {"id": 51, "type": "identifier", "text": "CMD_LCD_SHIFT_CURSOR_RIGHT", "parent": 49, "children": [], "start_point": {"row": 19, "column": 8}, "end_point": {"row": 19, "column": 34}}, {"id": 52, "type": "preproc_arg", "text": "0b00010100\r", "parent": 49, "children": [], "start_point": {"row": 19, "column": 36}, "end_point": {"row": 19, "column": 47}}, {"id": 53, "type": "preproc_def", "text": "#define BG_BIT_POSITION\t\t\t\t\t3\r\n", "parent": 0, "children": [54, 55, 56], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 22, "column": 0}}, {"id": 54, "type": "#define", "text": "#define", "parent": 53, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 7}}, {"id": 55, "type": "identifier", "text": "BG_BIT_POSITION", "parent": 53, "children": [], "start_point": {"row": 21, "column": 8}, "end_point": {"row": 21, "column": 23}}, {"id": 56, "type": "preproc_arg", "text": "3\r", "parent": 53, "children": [], "start_point": {"row": 21, "column": 28}, "end_point": {"row": 21, "column": 30}}, {"id": 57, "type": "type_definition", "text": "ypedef struct\r\n{\r\n\tI2C_HandleTypeDef *i2c_handle;\r\n\tuint16_t Slave_address;\r\n\tuint8_t bg; // Background switch\r\n}LCD_Handle_t;\r", "parent": 0, "children": [58, 59, 72], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 31, "column": 14}}, {"id": 58, "type": "typedef", "text": "ypedef ", "parent": 57, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 7}}, {"id": 59, "type": "struct_specifier", "text": "truct\r\n{\r\n\tI2C_HandleTypeDef *i2c_handle;\r\n\tuint16_t Slave_address;\r\n\tuint8_t bg; // Background switch\r\n}L", "parent": 57, "children": [60], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 31, "column": 1}}, {"id": 60, "type": "struct", "text": "truct\r", "parent": 59, "children": [], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 14}}, {"id": 61, "type": "field_declaration", "text": "2C_HandleTypeDef *i2c_handle;\r", "parent": 59, "children": [62, 63], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 28, "column": 31}}, {"id": 62, "type": "type_identifier", "text": "2C_HandleTypeDef ", "parent": 61, "children": [], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 28, "column": 18}}, {"id": 63, "type": "pointer_declarator", "text": "i2c_handle;", "parent": 61, "children": [64, 65], "start_point": {"row": 28, "column": 19}, "end_point": {"row": 28, "column": 30}}, {"id": 64, "type": "*", "text": "i", "parent": 63, "children": [], "start_point": {"row": 28, "column": 19}, "end_point": {"row": 28, "column": 20}}, {"id": 65, "type": "field_identifier", "text": "2c_handle;", "parent": 63, "children": [], "start_point": {"row": 28, "column": 20}, "end_point": {"row": 28, "column": 30}}, {"id": 66, "type": "field_declaration", "text": "int16_t Slave_address;\r", "parent": 59, "children": [67, 68], "start_point": {"row": 29, "column": 1}, "end_point": {"row": 29, "column": 24}}, {"id": 67, "type": "primitive_type", "text": "int16_t ", "parent": 66, "children": [], "start_point": {"row": 29, "column": 1}, "end_point": {"row": 29, "column": 9}}, {"id": 68, "type": "field_identifier", "text": "lave_address;", "parent": 66, "children": [], "start_point": {"row": 29, "column": 10}, "end_point": {"row": 29, "column": 23}}, {"id": 69, "type": "field_declaration", "text": "int8_t bg; ", "parent": 59, "children": [70, 71], "start_point": {"row": 30, "column": 1}, "end_point": {"row": 30, "column": 12}}, {"id": 70, "type": "primitive_type", "text": "int8_t ", "parent": 69, "children": [], "start_point": {"row": 30, "column": 1}, "end_point": {"row": 30, "column": 8}}, {"id": 71, "type": "field_identifier", "text": "g;", "parent": 69, "children": [], "start_point": {"row": 30, "column": 9}, "end_point": {"row": 30, "column": 11}}, {"id": 72, "type": "type_identifier", "text": "CD_Handle_t;", "parent": 57, "children": [], "start_point": {"row": 31, "column": 1}, "end_point": {"row": 31, "column": 13}}, {"id": 73, "type": "declaration", "text": "id lcd_command(LCD_Handle_t* lcd_config, uint8_t cmd);\r\n", "parent": 0, "children": [74, 75], "start_point": {"row": 36, "column": 0}, "end_point": {"row": 36, "column": 56}}, {"id": 74, "type": "primitive_type", "text": "id l", "parent": 73, "children": [], "start_point": {"row": 36, "column": 0}, "end_point": {"row": 36, "column": 4}}, {"id": 75, "type": "function_declarator", "text": "d_command(LCD_Handle_t* lcd_config, uint8_t cmd);\r", "parent": 73, "children": [76, 77], "start_point": {"row": 36, "column": 5}, "end_point": {"row": 36, "column": 55}}, {"id": 76, "type": "identifier", "text": "d_command(L", "parent": 75, "children": [], "start_point": {"row": 36, "column": 5}, "end_point": {"row": 36, "column": 16}}, {"id": 77, "type": "parameter_list", "text": "CD_Handle_t* lcd_config, uint8_t cmd);\r", "parent": 75, "children": [78, 83], "start_point": {"row": 36, "column": 16}, "end_point": {"row": 36, "column": 55}}, {"id": 78, "type": "parameter_declaration", "text": "D_Handle_t* lcd_config, ", "parent": 77, "children": [79, 80], "start_point": {"row": 36, "column": 17}, "end_point": {"row": 36, "column": 41}}, {"id": 79, "type": "type_identifier", "text": "D_Handle_t* ", "parent": 78, "children": [], "start_point": {"row": 36, "column": 17}, "end_point": {"row": 36, "column": 29}}, {"id": 80, "type": "pointer_declarator", "text": "lcd_config, ", "parent": 78, "children": [81, 82], "start_point": {"row": 36, "column": 29}, "end_point": {"row": 36, "column": 41}}, {"id": 81, "type": "*", "text": "l", "parent": 80, "children": [], "start_point": {"row": 36, "column": 29}, "end_point": {"row": 36, "column": 30}}, {"id": 82, "type": "identifier", "text": "d_config, ", "parent": 80, "children": [], "start_point": {"row": 36, "column": 31}, "end_point": {"row": 36, "column": 41}}, {"id": 83, "type": "parameter_declaration", "text": "nt8_t cmd);", "parent": 77, "children": [84, 85], "start_point": {"row": 36, "column": 43}, "end_point": {"row": 36, "column": 54}}, {"id": 84, "type": "primitive_type", "text": "nt8_t c", "parent": 83, "children": [], "start_point": {"row": 36, "column": 43}, "end_point": {"row": 36, "column": 50}}, {"id": 85, "type": "identifier", "text": "d);", "parent": 83, "children": [], "start_point": {"row": 36, "column": 51}, "end_point": {"row": 36, "column": 54}}, {"id": 86, "type": "declaration", "text": "id lcd_init(LCD_Handle_t* lcd_config);\r\n", "parent": 0, "children": [87, 88], "start_point": {"row": 39, "column": 0}, "end_point": {"row": 39, "column": 40}}, {"id": 87, "type": "primitive_type", "text": "id l", "parent": 86, "children": [], "start_point": {"row": 39, "column": 0}, "end_point": {"row": 39, "column": 4}}, {"id": 88, "type": "function_declarator", "text": "d_init(LCD_Handle_t* lcd_config);\r", "parent": 86, "children": [89, 90], "start_point": {"row": 39, "column": 5}, "end_point": {"row": 39, "column": 39}}, {"id": 89, "type": "identifier", "text": "d_init(L", "parent": 88, "children": [], "start_point": {"row": 39, "column": 5}, "end_point": {"row": 39, "column": 13}}, {"id": 90, "type": "parameter_list", "text": "CD_Handle_t* lcd_config);\r", "parent": 88, "children": [91], "start_point": {"row": 39, "column": 13}, "end_point": {"row": 39, "column": 39}}, {"id": 91, "type": "parameter_declaration", "text": "D_Handle_t* lcd_config);", "parent": 90, "children": [92, 93], "start_point": {"row": 39, "column": 14}, "end_point": {"row": 39, "column": 38}}, {"id": 92, "type": "type_identifier", "text": "D_Handle_t* ", "parent": 91, "children": [], "start_point": {"row": 39, "column": 14}, "end_point": {"row": 39, "column": 26}}, {"id": 93, "type": "pointer_declarator", "text": "lcd_config);", "parent": 91, "children": [94, 95], "start_point": {"row": 39, "column": 26}, "end_point": {"row": 39, "column": 38}}, {"id": 94, "type": "*", "text": "l", "parent": 93, "children": [], "start_point": {"row": 39, "column": 26}, "end_point": {"row": 39, "column": 27}}, {"id": 95, "type": "identifier", "text": "d_config);", "parent": 93, "children": [], "start_point": {"row": 39, "column": 28}, "end_point": {"row": 39, "column": 38}}, {"id": 96, "type": "declaration", "text": "id printLetter(LCD_Handle_t* lcd_config, uint8_t letter);\r\n", "parent": 0, "children": [97, 98], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 41, "column": 59}}, {"id": 97, "type": "primitive_type", "text": "id p", "parent": 96, "children": [], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 41, "column": 4}}, {"id": 98, "type": "function_declarator", "text": "intLetter(LCD_Handle_t* lcd_config, uint8_t letter);\r", "parent": 96, "children": [99, 100], "start_point": {"row": 41, "column": 5}, "end_point": {"row": 41, "column": 58}}, {"id": 99, "type": "identifier", "text": "intLetter(L", "parent": 98, "children": [], "start_point": {"row": 41, "column": 5}, "end_point": {"row": 41, "column": 16}}, {"id": 100, "type": "parameter_list", "text": "CD_Handle_t* lcd_config, uint8_t letter);\r", "parent": 98, "children": [101, 106], "start_point": {"row": 41, "column": 16}, "end_point": {"row": 41, "column": 58}}, {"id": 101, "type": "parameter_declaration", "text": "D_Handle_t* lcd_config, ", "parent": 100, "children": [102, 103], "start_point": {"row": 41, "column": 17}, "end_point": {"row": 41, "column": 41}}, {"id": 102, "type": "type_identifier", "text": "D_Handle_t* ", "parent": 101, "children": [], "start_point": {"row": 41, "column": 17}, "end_point": {"row": 41, "column": 29}}, {"id": 103, "type": "pointer_declarator", "text": "lcd_config, ", "parent": 101, "children": [104, 105], "start_point": {"row": 41, "column": 29}, "end_point": {"row": 41, "column": 41}}, {"id": 104, "type": "*", "text": "l", "parent": 103, "children": [], "start_point": {"row": 41, "column": 29}, "end_point": {"row": 41, "column": 30}}, {"id": 105, "type": "identifier", "text": "d_config, ", "parent": 103, "children": [], "start_point": {"row": 41, "column": 31}, "end_point": {"row": 41, "column": 41}}, {"id": 106, "type": "parameter_declaration", "text": "nt8_t letter);", "parent": 100, "children": [107, 108], "start_point": {"row": 41, "column": 43}, "end_point": {"row": 41, "column": 57}}, {"id": 107, "type": "primitive_type", "text": "nt8_t l", "parent": 106, "children": [], "start_point": {"row": 41, "column": 43}, "end_point": {"row": 41, "column": 50}}, {"id": 108, "type": "identifier", "text": "tter);", "parent": 106, "children": [], "start_point": {"row": 41, "column": 51}, "end_point": {"row": 41, "column": 57}}, {"id": 109, "type": "declaration", "text": "id printText(LCD_Handle_t* lcd_config, char *Text, uint32_t delayvalue);\r\n", "parent": 0, "children": [110, 111], "start_point": {"row": 43, "column": 0}, "end_point": {"row": 43, "column": 74}}, {"id": 110, "type": "primitive_type", "text": "id p", "parent": 109, "children": [], "start_point": {"row": 43, "column": 0}, "end_point": {"row": 43, "column": 4}}, {"id": 111, "type": "function_declarator", "text": "intText(LCD_Handle_t* lcd_config, char *Text, uint32_t delayvalue);\r", "parent": 109, "children": [112, 113], "start_point": {"row": 43, "column": 5}, "end_point": {"row": 43, "column": 73}}, {"id": 112, "type": "identifier", "text": "intText(L", "parent": 111, "children": [], "start_point": {"row": 43, "column": 5}, "end_point": {"row": 43, "column": 14}}, {"id": 113, "type": "parameter_list", "text": "CD_Handle_t* lcd_config, char *Text, uint32_t delayvalue);\r", "parent": 111, "children": [114, 119, 124], "start_point": {"row": 43, "column": 14}, "end_point": {"row": 43, "column": 73}}, {"id": 114, "type": "parameter_declaration", "text": "D_Handle_t* lcd_config, ", "parent": 113, "children": [115, 116], "start_point": {"row": 43, "column": 15}, "end_point": {"row": 43, "column": 39}}, {"id": 115, "type": "type_identifier", "text": "D_Handle_t* ", "parent": 114, "children": [], "start_point": {"row": 43, "column": 15}, "end_point": {"row": 43, "column": 27}}, {"id": 116, "type": "pointer_declarator", "text": "lcd_config, ", "parent": 114, "children": [117, 118], "start_point": {"row": 43, "column": 27}, "end_point": {"row": 43, "column": 39}}, {"id": 117, "type": "*", "text": "l", "parent": 116, "children": [], "start_point": {"row": 43, "column": 27}, "end_point": {"row": 43, "column": 28}}, {"id": 118, "type": "identifier", "text": "d_config, ", "parent": 116, "children": [], "start_point": {"row": 43, "column": 29}, "end_point": {"row": 43, "column": 39}}, {"id": 119, "type": "parameter_declaration", "text": "ar *Text, ", "parent": 113, "children": [120, 121], "start_point": {"row": 43, "column": 41}, "end_point": {"row": 43, "column": 51}}, {"id": 120, "type": "primitive_type", "text": "ar *", "parent": 119, "children": [], "start_point": {"row": 43, "column": 41}, "end_point": {"row": 43, "column": 45}}, {"id": 121, "type": "pointer_declarator", "text": "ext, ", "parent": 119, "children": [122, 123], "start_point": {"row": 43, "column": 46}, "end_point": {"row": 43, "column": 51}}, {"id": 122, "type": "*", "text": "e", "parent": 121, "children": [], "start_point": {"row": 43, "column": 46}, "end_point": {"row": 43, "column": 47}}, {"id": 123, "type": "identifier", "text": "xt, ", "parent": 121, "children": [], "start_point": {"row": 43, "column": 47}, "end_point": {"row": 43, "column": 51}}, {"id": 124, "type": "parameter_declaration", "text": "nt32_t delayvalue);", "parent": 113, "children": [125, 126], "start_point": {"row": 43, "column": 53}, "end_point": {"row": 43, "column": 72}}, {"id": 125, "type": "primitive_type", "text": "nt32_t d", "parent": 124, "children": [], "start_point": {"row": 43, "column": 53}, "end_point": {"row": 43, "column": 61}}, {"id": 126, "type": "identifier", "text": "layvalue);", "parent": 124, "children": [], "start_point": {"row": 43, "column": 62}, "end_point": {"row": 43, "column": 72}}, {"id": 127, "type": "#endif", "text": "ndif /", "parent": 0, "children": [], "start_point": {"row": 46, "column": 0}, "end_point": {"row": 46, "column": 6}}]}, "node_categories": {"declarations": {"functions": [75, 88, 98, 111], "variables": [57, 61, 66, 69, 73, 78, 83, 86, 91, 96, 101, 106, 109, 114, 119, 124], "classes": [59, 60], "imports": [6, 7], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 11, 15, 19, 23, 27, 31, 35, 39, 43, 47, 51, 55, 62, 65, 68, 71, 72, 76, 79, 82, 85, 89, 92, 95, 99, 102, 105, 108, 112, 115, 118, 123, 126, 127], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [8], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 75, "universal_type": "function", "name": "unknown", "text_snippet": "d_command(LCD_Handle_t* lcd_config, uint8_t cmd);\r"}, {"node_id": 88, "universal_type": "function", "name": "unknown", "text_snippet": "d_init(LCD_Handle_t* lcd_config);\r"}, {"node_id": 98, "universal_type": "function", "name": "unknown", "text_snippet": "intLetter(LCD_Handle_t* lcd_config, uint8_t letter);\r"}, {"node_id": 111, "universal_type": "function", "name": "unknown", "text_snippet": "intText(LCD_Handle_t* lcd_config, char *Text, uint32_t delayvalue);\r"}], "class_declarations": [{"node_id": 59, "universal_type": "class", "name": "unknown", "text_snippet": "truct\r\n{\r\n\tI2C_HandleTypeDef *i2c_handle;\r\n\tuint16_t Slave_address;\r\n\tuint8_t bg; // Background swit"}, {"node_id": 60, "universal_type": "class", "name": "unknown", "text_snippet": "truct\r"}], "import_statements": [{"node_id": 6, "text": "#include \"stm32f4xx_hal.h\"\r\n"}, {"node_id": 7, "text": "#include"}]}, "original_source_code": "/*\r\n * LCD_I2C_Driver.h\r\n */\r\n\r\n#ifndef INC_LCD_I2C_DRIVER_H_\r\n#define INC_LCD_I2C_DRIVER_H_\r\n\r\n#include \"stm32f4xx_hal.h\"\r\n\r\n#define CMD_LCD_CLEAR\t\t\t\t\t0b00000001\r\n#define CMD_LCD_CONTROL_ON \t\t\t\t0b00001111\t// Display on, cursor on and blinking\r\n#define CMD_LCD_CONTROL_OFF \t\t\t0b00001000\t// Display of, cursor off and blinking\r\n#define CMD_LCD_SET_4BIT_2LINE \t\t\t0b00101000\r\n#define CMD_LCD_SET_8BIT_2LINE \t\t\t0b00111000\r\n#define CMD_LCD_RETURN_HOME\t\t\t\t0b00000010\r\n#define CMD_LCD_SET_SECOND_LINE\t\t\t0b11000000\r\n#define CMD_LCD_ENTRY_MODE_INC\t\t\t0b00000110\r\n#define CMD_LCD_ENTRY_MODE_SHIFT\t\t0b00000111\r\n#define CMD_LCD_SHIFT_CURSOR_LEFT\t\t0b00010000\r\n#define CMD_LCD_SHIFT_CURSOR_RIGHT\t\t0b00010100\r\n\r\n#define BG_BIT_POSITION\t\t\t\t\t3\r\n\r\n/*\r\n * Handle struct f\u00fcr LCD\r\n */\r\ntypedef struct\r\n{\r\n\tI2C_HandleTypeDef *i2c_handle;\r\n\tuint16_t Slave_address;\r\n\tuint8_t bg; // Background switch\r\n}LCD_Handle_t;\r\n\r\n\r\n// Sendet das Kommando in cmd angegebene Kommando an das Display (instruction Mode)\r\n// und f\u00fchrt es aus.\r\nvoid lcd_command(LCD_Handle_t* lcd_config, uint8_t cmd);\r\n\r\n// Inistialiserung des Displays\r\nvoid lcd_init(LCD_Handle_t* lcd_config);\r\n\r\nvoid printLetter(LCD_Handle_t* lcd_config, uint8_t letter);\r\n\r\nvoid printText(LCD_Handle_t* lcd_config, char *Text, uint32_t delayvalue);\r\n\r\n\r\n#endif /* INC_LCD_I2C_DRIVER_H_ */\r\n\r\n\r\n\r\n"}
80,525
c
#ifndef __SHMOBILE_CLK_DIV6_H__ #define __SHMOBILE_CLK_DIV6_H__ struct clk *cpg_div6_register(const char *name, unsigned int num_parents, const char **parent_names, void __iomem *reg); #endif
39.2
5
(translation_unit) "#ifndef __SHMOBILE_CLK_DIV6_H__\n#define __SHMOBILE_CLK_DIV6_H__\n\nstruct clk *cpg_div6_register(const char *name, unsigned int num_parents,\n const char **parent_names, void __iomem *reg);\n\n#endif\n" (preproc_ifdef) "#ifndef __SHMOBILE_CLK_DIV6_H__\n#define __SHMOBILE_CLK_DIV6_H__\n\nstruct clk *cpg_div6_register(const char *name, unsigned int num_parents,\n const char **parent_names, void __iomem *reg);\n\n#endif" (#ifndef) "#ifndef" (identifier) "__SHMOBILE_CLK_DIV6_H__" (preproc_def) "#define __SHMOBILE_CLK_DIV6_H__\n" (#define) "#define" (identifier) "__SHMOBILE_CLK_DIV6_H__" (declaration) "struct clk *cpg_div6_register(const char *name, unsigned int num_parents,\n const char **parent_names, void __iomem *reg);" (struct_specifier) "struct clk" (struct) "struct" (type_identifier) "clk" (pointer_declarator) "*cpg_div6_register(const char *name, unsigned int num_parents,\n const char **parent_names, void __iomem *reg)" (*) "*" (function_declarator) "cpg_div6_register(const char *name, unsigned int num_parents,\n const char **parent_names, void __iomem *reg)" (identifier) "cpg_div6_register" (parameter_list) "(const char *name, unsigned int num_parents,\n const char **parent_names, void __iomem *reg)" (() "(" (parameter_declaration) "const char *name" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "*name" (*) "*" (identifier) "name" (,) "," (parameter_declaration) "unsigned int num_parents" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "num_parents" (,) "," (parameter_declaration) "const char **parent_names" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "**parent_names" (*) "*" (pointer_declarator) "*parent_names" (*) "*" (identifier) "parent_names" (,) "," (parameter_declaration) "void __iomem *reg" (primitive_type) "void" (ERROR) "__iomem" (identifier) "__iomem" (pointer_declarator) "*reg" (*) "*" (identifier) "reg" ()) ")" (;) ";" (#endif) "#endif"
51
1
{"language": "c", "success": true, "metadata": {"lines": 5, "avg_line_length": 39.2, "nodes": 40, "errors": 0, "source_hash": "55944f9accc9e70951f79629a67716366091f6551e384b647711286a7b947e3b", "categorized_nodes": 21}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef __SHMOBILE_CLK_DIV6_H__\n#define __SHMOBILE_CLK_DIV6_H__\n\nstruct clk *cpg_div6_register(const char *name, unsigned int num_parents,\n\t\t\t const char **parent_names, void __iomem *reg);\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 39], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 6, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "identifier", "text": "__SHMOBILE_CLK_DIV6_H__", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 31}}, {"id": 3, "type": "preproc_def", "text": "#define __SHMOBILE_CLK_DIV6_H__\n", "parent": 0, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 5, "type": "identifier", "text": "__SHMOBILE_CLK_DIV6_H__", "parent": 3, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 31}}, {"id": 6, "type": "declaration", "text": "struct clk *cpg_div6_register(const char *name, unsigned int num_parents,\n\t\t\t const char **parent_names, void __iomem *reg);", "parent": 0, "children": [7, 10], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 55}}, {"id": 7, "type": "struct_specifier", "text": "struct clk", "parent": 6, "children": [8, 9], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 10}}, {"id": 8, "type": "struct", "text": "struct", "parent": 7, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 6}}, {"id": 9, "type": "type_identifier", "text": "clk", "parent": 7, "children": [], "start_point": {"row": 3, "column": 7}, "end_point": {"row": 3, "column": 10}}, {"id": 10, "type": "pointer_declarator", "text": "*cpg_div6_register(const char *name, unsigned int num_parents,\n\t\t\t const char **parent_names, void __iomem *reg)", "parent": 6, "children": [11, 12], "start_point": {"row": 3, "column": 11}, "end_point": {"row": 4, "column": 54}}, {"id": 11, "type": "*", "text": "*", "parent": 10, "children": [], "start_point": {"row": 3, "column": 11}, "end_point": {"row": 3, "column": 12}}, {"id": 12, "type": "function_declarator", "text": "cpg_div6_register(const char *name, unsigned int num_parents,\n\t\t\t const char **parent_names, void __iomem *reg)", "parent": 10, "children": [13, 14], "start_point": {"row": 3, "column": 12}, "end_point": {"row": 4, "column": 54}}, {"id": 13, "type": "identifier", "text": "cpg_div6_register", "parent": 12, "children": [], "start_point": {"row": 3, "column": 12}, "end_point": {"row": 3, "column": 29}}, {"id": 14, "type": "parameter_list", "text": "(const char *name, unsigned int num_parents,\n\t\t\t const char **parent_names, void __iomem *reg)", "parent": 12, "children": [15, 20, 25, 32], "start_point": {"row": 3, "column": 29}, "end_point": {"row": 4, "column": 54}}, {"id": 15, "type": "parameter_declaration", "text": "const char *name", "parent": 14, "children": [16, 17], "start_point": {"row": 3, "column": 30}, "end_point": {"row": 3, "column": 46}}, {"id": 16, "type": "primitive_type", "text": "char", "parent": 15, "children": [], "start_point": {"row": 3, "column": 36}, "end_point": {"row": 3, "column": 40}}, {"id": 17, "type": "pointer_declarator", "text": "*name", "parent": 15, "children": [18, 19], "start_point": {"row": 3, "column": 41}, "end_point": {"row": 3, "column": 46}}, {"id": 18, "type": "*", "text": "*", "parent": 17, "children": [], "start_point": {"row": 3, "column": 41}, "end_point": {"row": 3, "column": 42}}, {"id": 19, "type": "identifier", "text": "name", "parent": 17, "children": [], "start_point": {"row": 3, "column": 42}, "end_point": {"row": 3, "column": 46}}, {"id": 20, "type": "parameter_declaration", "text": "unsigned int num_parents", "parent": 14, "children": [21, 24], "start_point": {"row": 3, "column": 48}, "end_point": {"row": 3, "column": 72}}, {"id": 21, "type": "sized_type_specifier", "text": "unsigned int", "parent": 20, "children": [22, 23], "start_point": {"row": 3, "column": 48}, "end_point": {"row": 3, "column": 60}}, {"id": 22, "type": "unsigned", "text": "unsigned", "parent": 21, "children": [], "start_point": {"row": 3, "column": 48}, "end_point": {"row": 3, "column": 56}}, {"id": 23, "type": "primitive_type", "text": "int", "parent": 21, "children": [], "start_point": {"row": 3, "column": 57}, "end_point": {"row": 3, "column": 60}}, {"id": 24, "type": "identifier", "text": "num_parents", "parent": 20, "children": [], "start_point": {"row": 3, "column": 61}, "end_point": {"row": 3, "column": 72}}, {"id": 25, "type": "parameter_declaration", "text": "const char **parent_names", "parent": 14, "children": [26, 27], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 34}}, {"id": 26, "type": "primitive_type", "text": "char", "parent": 25, "children": [], "start_point": {"row": 4, "column": 15}, "end_point": {"row": 4, "column": 19}}, {"id": 27, "type": "pointer_declarator", "text": "**parent_names", "parent": 25, "children": [28, 29], "start_point": {"row": 4, "column": 20}, "end_point": {"row": 4, "column": 34}}, {"id": 28, "type": "*", "text": "*", "parent": 27, "children": [], "start_point": {"row": 4, "column": 20}, "end_point": {"row": 4, "column": 21}}, {"id": 29, "type": "pointer_declarator", "text": "*parent_names", "parent": 27, "children": [30, 31], "start_point": {"row": 4, "column": 21}, "end_point": {"row": 4, "column": 34}}, {"id": 30, "type": "*", "text": "*", "parent": 29, "children": [], "start_point": {"row": 4, "column": 21}, "end_point": {"row": 4, "column": 22}}, {"id": 31, "type": "identifier", "text": "parent_names", "parent": 29, "children": [], "start_point": {"row": 4, "column": 22}, "end_point": {"row": 4, "column": 34}}, {"id": 32, "type": "parameter_declaration", "text": "void __iomem *reg", "parent": 14, "children": [33, 34, 36], "start_point": {"row": 4, "column": 36}, "end_point": {"row": 4, "column": 53}}, {"id": 33, "type": "primitive_type", "text": "void", "parent": 32, "children": [], "start_point": {"row": 4, "column": 36}, "end_point": {"row": 4, "column": 40}}, {"id": 34, "type": "ERROR", "text": "__iomem", "parent": 32, "children": [35], "start_point": {"row": 4, "column": 41}, "end_point": {"row": 4, "column": 48}}, {"id": 35, "type": "identifier", "text": "__iomem", "parent": 34, "children": [], "start_point": {"row": 4, "column": 41}, "end_point": {"row": 4, "column": 48}}, {"id": 36, "type": "pointer_declarator", "text": "*reg", "parent": 32, "children": [37, 38], "start_point": {"row": 4, "column": 49}, "end_point": {"row": 4, "column": 53}}, {"id": 37, "type": "*", "text": "*", "parent": 36, "children": [], "start_point": {"row": 4, "column": 49}, "end_point": {"row": 4, "column": 50}}, {"id": 38, "type": "identifier", "text": "reg", "parent": 36, "children": [], "start_point": {"row": 4, "column": 50}, "end_point": {"row": 4, "column": 53}}, {"id": 39, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 6}}]}, "node_categories": {"declarations": {"functions": [12], "variables": [6, 15, 20, 25, 32], "classes": [7, 8], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 9, 13, 19, 21, 24, 31, 35, 38, 39], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 12, "universal_type": "function", "name": "num_parents,", "text_snippet": "cpg_div6_register(const char *name, unsigned int num_parents,\n\t\t\t const char **parent_names, vo"}], "class_declarations": [{"node_id": 7, "universal_type": "class", "name": "clk", "text_snippet": "struct clk"}, {"node_id": 8, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": []}, "original_source_code": "#ifndef __SHMOBILE_CLK_DIV6_H__\n#define __SHMOBILE_CLK_DIV6_H__\n\nstruct clk *cpg_div6_register(const char *name, unsigned int num_parents,\n\t\t\t const char **parent_names, void __iomem *reg);\n\n#endif\n"}
80,526
c
/* Generated by re2c */ // re2c $INPUT -o $OUTPUT -i --case-inverted { YYCTYPE yych; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; switch (yych) { case 'A': case 'a': goto yy3; case 'b': goto yy5; default: goto yy2; } yy2: yy3: ++YYCURSOR; {return 'a';} yy5: ++YYCURSOR; {return 'b';} } } casing-flags_i_case_inverted.re:5:2: warning: control flow is undefined for strings that match '[\x0-\x40\x42-\x60\x63-\xFF]', use default rule '*' [-Wundefined-control-flow]
21.05
22
(translation_unit) "/* Generated by re2c */\n// re2c $INPUT -o $OUTPUT -i --case-inverted\n\n{\n YYCTYPE yych;\n if (YYLIMIT <= YYCURSOR) YYFILL(1);\n yych = *YYCURSOR;\n switch (yych) {\n case 'A':\n case 'a': goto yy3;\n case 'b': goto yy5;\n default: goto yy2;\n }\nyy2:\nyy3:\n ++YYCURSOR;\n {return 'a';}\nyy5:\n ++YYCURSOR;\n {return 'b';}\n}\n\n}\ncasing-flags_i_case_inverted.re:5:2: warning: control flow is undefined for strings that match '[\x0-\x40\x42-\x60\x63-\xFF]', use default rule '*' [-Wundefined-control-flow]\n" (comment) "/* Generated by re2c */" (comment) "// re2c $INPUT -o $OUTPUT -i --case-inverted" (compound_statement) "{\n YYCTYPE yych;\n if (YYLIMIT <= YYCURSOR) YYFILL(1);\n yych = *YYCURSOR;\n switch (yych) {\n case 'A':\n case 'a': goto yy3;\n case 'b': goto yy5;\n default: goto yy2;\n }\nyy2:\nyy3:\n ++YYCURSOR;\n {return 'a';}\nyy5:\n ++YYCURSOR;\n {return 'b';}\n}" ({) "{" (declaration) "YYCTYPE yych;" (type_identifier) "YYCTYPE" (identifier) "yych" (;) ";" (if_statement) "if (YYLIMIT <= YYCURSOR) YYFILL(1);" (if) "if" (parenthesized_expression) "(YYLIMIT <= YYCURSOR)" (() "(" (binary_expression) "YYLIMIT <= YYCURSOR" (identifier) "YYLIMIT" (<=) "<=" (identifier) "YYCURSOR" ()) ")" (expression_statement) "YYFILL(1);" (call_expression) "YYFILL(1)" (identifier) "YYFILL" (argument_list) "(1)" (() "(" (number_literal) "1" ()) ")" (;) ";" (expression_statement) "yych = *YYCURSOR;" (assignment_expression) "yych = *YYCURSOR" (identifier) "yych" (=) "=" (pointer_expression) "*YYCURSOR" (*) "*" (identifier) "YYCURSOR" (;) ";" (switch_statement) "switch (yych) {\n case 'A':\n case 'a': goto yy3;\n case 'b': goto yy5;\n default: goto yy2;\n }" (switch) "switch" (parenthesized_expression) "(yych)" (() "(" (identifier) "yych" ()) ")" (compound_statement) "{\n case 'A':\n case 'a': goto yy3;\n case 'b': goto yy5;\n default: goto yy2;\n }" ({) "{" (case_statement) "case 'A':" (case) "case" (char_literal) "'A'" (') "'" (character) "A" (') "'" (:) ":" (case_statement) "case 'a': goto yy3;" (case) "case" (char_literal) "'a'" (') "'" (character) "a" (') "'" (:) ":" (goto_statement) "goto yy3;" (goto) "goto" (statement_identifier) "yy3" (;) ";" (case_statement) "case 'b': goto yy5;" (case) "case" (char_literal) "'b'" (') "'" (character) "b" (') "'" (:) ":" (goto_statement) "goto yy5;" (goto) "goto" (statement_identifier) "yy5" (;) ";" (case_statement) "default: goto yy2;" (default) "default" (:) ":" (goto_statement) "goto yy2;" (goto) "goto" (statement_identifier) "yy2" (;) ";" (}) "}" (labeled_statement) "yy2:\nyy3:\n ++YYCURSOR;" (statement_identifier) "yy2" (:) ":" (labeled_statement) "yy3:\n ++YYCURSOR;" (statement_identifier) "yy3" (:) ":" (expression_statement) "++YYCURSOR;" (update_expression) "++YYCURSOR" (++) "++" (identifier) "YYCURSOR" (;) ";" (compound_statement) "{return 'a';}" ({) "{" (return_statement) "return 'a';" (return) "return" (char_literal) "'a'" (') "'" (character) "a" (') "'" (;) ";" (}) "}" (labeled_statement) "yy5:\n ++YYCURSOR;" (statement_identifier) "yy5" (:) ":" (expression_statement) "++YYCURSOR;" (update_expression) "++YYCURSOR" (++) "++" (identifier) "YYCURSOR" (;) ";" (compound_statement) "{return 'b';}" ({) "{" (return_statement) "return 'b';" (return) "return" (char_literal) "'b'" (') "'" (character) "b" (') "'" (;) ";" (}) "}" (}) "}" (ERROR) "}\ncasing-flags_i_case_inverted.re:5:2:" (}) "}" (binary_expression) "casing-flags_i_case_inverted.re" (identifier) "casing" (-) "-" (field_expression) "flags_i_case_inverted.re" (identifier) "flags_i_case_inverted" (.) "." (field_identifier) "re" (:) ":" (number_literal) "5" (:) ":" (number_literal) "2" (:) ":" (labeled_statement) "warning: control flow" (statement_identifier) "warning" (:) ":" (declaration) "control flow" (type_identifier) "control" (identifier) "flow" (;) "" (ERROR) "is undefined for strings that match '[\x0-\x40\x42-\x60\x63-\xFF]', use default rule" (type_identifier) "is" (identifier) "undefined" (identifier) "for" (identifier) "strings" (identifier) "that" (identifier) "match" (char_literal) "'[\x0-\x40\x42-\x60\x63-\xFF]'" (') "'" (character) "[" (escape_sequence) "\x0" (character) "-" (escape_sequence) "\x40" (escape_sequence) "\x42" (character) "-" (escape_sequence) "\x60" (escape_sequence) "\x63" (character) "-" (escape_sequence) "\xFF" (character) "]" (') "'" (,) "," (type_identifier) "use" (identifier) "default" (identifier) "rule" (expression_statement) "'*' [-Wundefined-control-flow]" (subscript_expression) "'*' [-Wundefined-control-flow]" (char_literal) "'*'" (') "'" (character) "*" (') "'" ([) "[" (binary_expression) "-Wundefined-control-flow" (binary_expression) "-Wundefined-control" (unary_expression) "-Wundefined" (-) "-" (identifier) "Wundefined" (-) "-" (identifier) "control" (-) "-" (identifier) "flow" (]) "]" (;) ""
183
2
{"language": "c", "success": true, "metadata": {"lines": 22, "avg_line_length": 21.05, "nodes": 123, "errors": 0, "source_hash": "435f125b4511db8fec219ad4667a3e09e74d277728262f3d712b4396fc848b3f", "categorized_nodes": 71}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "declaration", "text": "YYCTYPE yych;", "parent": null, "children": [1, 2], "start_point": {"row": 4, "column": 1}, "end_point": {"row": 4, "column": 14}}, {"id": 1, "type": "type_identifier", "text": "YYCTYPE", "parent": 0, "children": [], "start_point": {"row": 4, "column": 1}, "end_point": {"row": 4, "column": 8}}, {"id": 2, "type": "identifier", "text": "yych", "parent": 0, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 13}}, {"id": 3, "type": "if_statement", "text": "if (YYLIMIT <= YYCURSOR) YYFILL(1);", "parent": null, "children": [4], "start_point": {"row": 5, "column": 1}, "end_point": {"row": 5, "column": 36}}, {"id": 4, "type": "parenthesized_expression", "text": "(YYLIMIT <= YYCURSOR)", "parent": 3, "children": [5], "start_point": {"row": 5, "column": 4}, "end_point": {"row": 5, "column": 25}}, {"id": 5, "type": "binary_expression", "text": "YYLIMIT <= YYCURSOR", "parent": 4, "children": [6, 7, 8], "start_point": {"row": 5, "column": 5}, "end_point": {"row": 5, "column": 24}}, {"id": 6, "type": "identifier", "text": "YYLIMIT", "parent": 5, "children": [], "start_point": {"row": 5, "column": 5}, "end_point": {"row": 5, "column": 12}}, {"id": 7, "type": "<=", "text": "<=", "parent": 5, "children": [], "start_point": {"row": 5, "column": 13}, "end_point": {"row": 5, "column": 15}}, {"id": 8, "type": "identifier", "text": "YYCURSOR", "parent": 5, "children": [], "start_point": {"row": 5, "column": 16}, "end_point": {"row": 5, "column": 24}}, {"id": 9, "type": "call_expression", "text": "YYFILL(1)", "parent": 3, "children": [10, 11], "start_point": {"row": 5, "column": 26}, "end_point": {"row": 5, "column": 35}}, {"id": 10, "type": "identifier", "text": "YYFILL", "parent": 9, "children": [], "start_point": {"row": 5, "column": 26}, "end_point": {"row": 5, "column": 32}}, {"id": 11, "type": "argument_list", "text": "(1)", "parent": 9, "children": [12], "start_point": {"row": 5, "column": 32}, "end_point": {"row": 5, "column": 35}}, {"id": 12, "type": "number_literal", "text": "1", "parent": 11, "children": [], "start_point": {"row": 5, "column": 33}, "end_point": {"row": 5, "column": 34}}, {"id": 13, "type": "assignment_expression", "text": "yych = *YYCURSOR", "parent": null, "children": [14, 15, 16], "start_point": {"row": 6, "column": 1}, "end_point": {"row": 6, "column": 17}}, {"id": 14, "type": "identifier", "text": "yych", "parent": 13, "children": [], "start_point": {"row": 6, "column": 1}, "end_point": {"row": 6, "column": 5}}, {"id": 15, "type": "=", "text": "=", "parent": 13, "children": [], "start_point": {"row": 6, "column": 6}, "end_point": {"row": 6, "column": 7}}, {"id": 16, "type": "pointer_expression", "text": "*YYCURSOR", "parent": 13, "children": [17, 18], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 17}}, {"id": 17, "type": "*", "text": "*", "parent": 16, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 9}}, {"id": 18, "type": "identifier", "text": "YYCURSOR", "parent": 16, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 17}}, {"id": 19, "type": "switch_statement", "text": "switch (yych) {\n\tcase 'A':\n\tcase 'a':\tgoto yy3;\n\tcase 'b':\tgoto yy5;\n\tdefault:\tgoto yy2;\n\t}", "parent": null, "children": [20, 21], "start_point": {"row": 7, "column": 1}, "end_point": {"row": 12, "column": 2}}, {"id": 20, "type": "switch", "text": "switch", "parent": 19, "children": [], "start_point": {"row": 7, "column": 1}, "end_point": {"row": 7, "column": 7}}, {"id": 21, "type": "parenthesized_expression", "text": "(yych)", "parent": 19, "children": [22], "start_point": {"row": 7, "column": 8}, "end_point": {"row": 7, "column": 14}}, {"id": 22, "type": "identifier", "text": "yych", "parent": 21, "children": [], "start_point": {"row": 7, "column": 9}, "end_point": {"row": 7, "column": 13}}, {"id": 23, "type": "case_statement", "text": "case 'A':", "parent": 19, "children": [24, 25], "start_point": {"row": 8, "column": 1}, "end_point": {"row": 8, "column": 10}}, {"id": 24, "type": "case", "text": "case", "parent": 23, "children": [], "start_point": {"row": 8, "column": 1}, "end_point": {"row": 8, "column": 5}}, {"id": 25, "type": "char_literal", "text": "'A'", "parent": 23, "children": [26, 27, 28], "start_point": {"row": 8, "column": 6}, "end_point": {"row": 8, "column": 9}}, {"id": 26, "type": "'", "text": "'", "parent": 25, "children": [], "start_point": {"row": 8, "column": 6}, "end_point": {"row": 8, "column": 7}}, {"id": 27, "type": "character", "text": "A", "parent": 25, "children": [], "start_point": {"row": 8, "column": 7}, "end_point": {"row": 8, "column": 8}}, {"id": 28, "type": "'", "text": "'", "parent": 25, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 9}}, {"id": 29, "type": "case_statement", "text": "case 'a':\tgoto yy3;", "parent": 19, "children": [30, 31, 35], "start_point": {"row": 9, "column": 1}, "end_point": {"row": 9, "column": 20}}, {"id": 30, "type": "case", "text": "case", "parent": 29, "children": [], "start_point": {"row": 9, "column": 1}, "end_point": {"row": 9, "column": 5}}, {"id": 31, "type": "char_literal", "text": "'a'", "parent": 29, "children": [32, 33, 34], "start_point": {"row": 9, "column": 6}, "end_point": {"row": 9, "column": 9}}, {"id": 32, "type": "'", "text": "'", "parent": 31, "children": [], "start_point": {"row": 9, "column": 6}, "end_point": {"row": 9, "column": 7}}, {"id": 33, "type": "character", "text": "a", "parent": 31, "children": [], "start_point": {"row": 9, "column": 7}, "end_point": {"row": 9, "column": 8}}, {"id": 34, "type": "'", "text": "'", "parent": 31, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 9}}, {"id": 35, "type": "goto_statement", "text": "goto yy3;", "parent": 29, "children": [36, 37], "start_point": {"row": 9, "column": 11}, "end_point": {"row": 9, "column": 20}}, {"id": 36, "type": "goto", "text": "goto", "parent": 35, "children": [], "start_point": {"row": 9, "column": 11}, "end_point": {"row": 9, "column": 15}}, {"id": 37, "type": "statement_identifier", "text": "yy3", "parent": 35, "children": [], "start_point": {"row": 9, "column": 16}, "end_point": {"row": 9, "column": 19}}, {"id": 38, "type": "case_statement", "text": "case 'b':\tgoto yy5;", "parent": 19, "children": [39, 40, 44], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 20}}, {"id": 39, "type": "case", "text": "case", "parent": 38, "children": [], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 5}}, {"id": 40, "type": "char_literal", "text": "'b'", "parent": 38, "children": [41, 42, 43], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 9}}, {"id": 41, "type": "'", "text": "'", "parent": 40, "children": [], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 7}}, {"id": 42, "type": "character", "text": "b", "parent": 40, "children": [], "start_point": {"row": 10, "column": 7}, "end_point": {"row": 10, "column": 8}}, {"id": 43, "type": "'", "text": "'", "parent": 40, "children": [], "start_point": {"row": 10, "column": 8}, "end_point": {"row": 10, "column": 9}}, {"id": 44, "type": "goto_statement", "text": "goto yy5;", "parent": 38, "children": [45, 46], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 10, "column": 20}}, {"id": 45, "type": "goto", "text": "goto", "parent": 44, "children": [], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 10, "column": 15}}, {"id": 46, "type": "statement_identifier", "text": "yy5", "parent": 44, "children": [], "start_point": {"row": 10, "column": 16}, "end_point": {"row": 10, "column": 19}}, {"id": 47, "type": "case_statement", "text": "default:\tgoto yy2;", "parent": 19, "children": [48, 49], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 11, "column": 19}}, {"id": 48, "type": "default", "text": "default", "parent": 47, "children": [], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 11, "column": 8}}, {"id": 49, "type": "goto_statement", "text": "goto yy2;", "parent": 47, "children": [50, 51], "start_point": {"row": 11, "column": 10}, "end_point": {"row": 11, "column": 19}}, {"id": 50, "type": "goto", "text": "goto", "parent": 49, "children": [], "start_point": {"row": 11, "column": 10}, "end_point": {"row": 11, "column": 14}}, {"id": 51, "type": "statement_identifier", "text": "yy2", "parent": 49, "children": [], "start_point": {"row": 11, "column": 15}, "end_point": {"row": 11, "column": 18}}, {"id": 52, "type": "labeled_statement", "text": "yy2:\nyy3:\n\t++YYCURSOR;", "parent": null, "children": [53, 54], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 15, "column": 12}}, {"id": 53, "type": "statement_identifier", "text": "yy2", "parent": 52, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 3}}, {"id": 54, "type": "labeled_statement", "text": "yy3:\n\t++YYCURSOR;", "parent": 52, "children": [55], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 15, "column": 12}}, {"id": 55, "type": "statement_identifier", "text": "yy3", "parent": 54, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 3}}, {"id": 56, "type": "update_expression", "text": "++YYCURSOR", "parent": 54, "children": [57, 58], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 11}}, {"id": 57, "type": "++", "text": "++", "parent": 56, "children": [], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 3}}, {"id": 58, "type": "identifier", "text": "YYCURSOR", "parent": 56, "children": [], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 11}}, {"id": 59, "type": "return_statement", "text": "return 'a';", "parent": null, "children": [60], "start_point": {"row": 16, "column": 2}, "end_point": {"row": 16, "column": 13}}, {"id": 60, "type": "char_literal", "text": "'a'", "parent": 59, "children": [61, 62, 63], "start_point": {"row": 16, "column": 9}, "end_point": {"row": 16, "column": 12}}, {"id": 61, "type": "'", "text": "'", "parent": 60, "children": [], "start_point": {"row": 16, "column": 9}, "end_point": {"row": 16, "column": 10}}, {"id": 62, "type": "character", "text": "a", "parent": 60, "children": [], "start_point": {"row": 16, "column": 10}, "end_point": {"row": 16, "column": 11}}, {"id": 63, "type": "'", "text": "'", "parent": 60, "children": [], "start_point": {"row": 16, "column": 11}, "end_point": {"row": 16, "column": 12}}, {"id": 64, "type": "labeled_statement", "text": "yy5:\n\t++YYCURSOR;", "parent": null, "children": [65], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 18, "column": 12}}, {"id": 65, "type": "statement_identifier", "text": "yy5", "parent": 64, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 3}}, {"id": 66, "type": "update_expression", "text": "++YYCURSOR", "parent": 64, "children": [67, 68], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 11}}, {"id": 67, "type": "++", "text": "++", "parent": 66, "children": [], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 3}}, {"id": 68, "type": "identifier", "text": "YYCURSOR", "parent": 66, "children": [], "start_point": {"row": 18, "column": 3}, "end_point": {"row": 18, "column": 11}}, {"id": 69, "type": "return_statement", "text": "return 'b';", "parent": null, "children": [70], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 13}}, {"id": 70, "type": "char_literal", "text": "'b'", "parent": 69, "children": [71, 72, 73], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 12}}, {"id": 71, "type": "'", "text": "'", "parent": 70, "children": [], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 10}}, {"id": 72, "type": "character", "text": "b", "parent": 70, "children": [], "start_point": {"row": 19, "column": 10}, "end_point": {"row": 19, "column": 11}}, {"id": 73, "type": "'", "text": "'", "parent": 70, "children": [], "start_point": {"row": 19, "column": 11}, "end_point": {"row": 19, "column": 12}}, {"id": 74, "type": "ERROR", "text": "}\ncasing-flags_i_case_inverted.re:5:2:", "parent": null, "children": [75, 81, 82], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 23, "column": 36}}, {"id": 75, "type": "binary_expression", "text": "casing-flags_i_case_inverted.re", "parent": 74, "children": [76, 77, 78], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 31}}, {"id": 76, "type": "identifier", "text": "casing", "parent": 75, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 6}}, {"id": 77, "type": "-", "text": "-", "parent": 75, "children": [], "start_point": {"row": 23, "column": 6}, "end_point": {"row": 23, "column": 7}}, {"id": 78, "type": "field_expression", "text": "flags_i_case_inverted.re", "parent": 75, "children": [79, 80], "start_point": {"row": 23, "column": 7}, "end_point": {"row": 23, "column": 31}}, {"id": 79, "type": "identifier", "text": "flags_i_case_inverted", "parent": 78, "children": [], "start_point": {"row": 23, "column": 7}, "end_point": {"row": 23, "column": 28}}, {"id": 80, "type": "field_identifier", "text": "re", "parent": 78, "children": [], "start_point": {"row": 23, "column": 29}, "end_point": {"row": 23, "column": 31}}, {"id": 81, "type": "number_literal", "text": "5", "parent": 74, "children": [], "start_point": {"row": 23, "column": 32}, "end_point": {"row": 23, "column": 33}}, {"id": 82, "type": "number_literal", "text": "2", "parent": 74, "children": [], "start_point": {"row": 23, "column": 34}, "end_point": {"row": 23, "column": 35}}, {"id": 83, "type": "labeled_statement", "text": "warning: control flow", "parent": null, "children": [84, 85], "start_point": {"row": 23, "column": 37}, "end_point": {"row": 23, "column": 58}}, {"id": 84, "type": "statement_identifier", "text": "warning", "parent": 83, "children": [], "start_point": {"row": 23, "column": 37}, "end_point": {"row": 23, "column": 44}}, {"id": 85, "type": "declaration", "text": "control flow", "parent": 83, "children": [86, 87], "start_point": {"row": 23, "column": 46}, "end_point": {"row": 23, "column": 58}}, {"id": 86, "type": "type_identifier", "text": "control", "parent": 85, "children": [], "start_point": {"row": 23, "column": 46}, "end_point": {"row": 23, "column": 53}}, {"id": 87, "type": "identifier", "text": "flow", "parent": 85, "children": [], "start_point": {"row": 23, "column": 54}, "end_point": {"row": 23, "column": 58}}, {"id": 88, "type": "ERROR", "text": "is undefined for strings that match '[\\x0-\\x40\\x42-\\x60\\x63-\\xFF]', use default rule", "parent": null, "children": [89, 90, 91, 92, 93, 94, 106, 107, 108], "start_point": {"row": 23, "column": 59}, "end_point": {"row": 23, "column": 143}}, {"id": 89, "type": "type_identifier", "text": "is", "parent": 88, "children": [], "start_point": {"row": 23, "column": 59}, "end_point": {"row": 23, "column": 61}}, {"id": 90, "type": "identifier", "text": "undefined", "parent": 88, "children": [], "start_point": {"row": 23, "column": 62}, "end_point": {"row": 23, "column": 71}}, {"id": 91, "type": "identifier", "text": "strings", "parent": 88, "children": [], "start_point": {"row": 23, "column": 76}, "end_point": {"row": 23, "column": 83}}, {"id": 92, "type": "identifier", "text": "that", "parent": 88, "children": [], "start_point": {"row": 23, "column": 84}, "end_point": {"row": 23, "column": 88}}, {"id": 93, "type": "identifier", "text": "match", "parent": 88, "children": [], "start_point": {"row": 23, "column": 89}, "end_point": {"row": 23, "column": 94}}, {"id": 94, "type": "char_literal", "text": "'[\\x0-\\x40\\x42-\\x60\\x63-\\xFF]'", "parent": 88, "children": [95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105], "start_point": {"row": 23, "column": 95}, "end_point": {"row": 23, "column": 125}}, {"id": 95, "type": "'", "text": "'", "parent": 94, "children": [], "start_point": {"row": 23, "column": 95}, "end_point": {"row": 23, "column": 96}}, {"id": 96, "type": "escape_sequence", "text": "\\x0", "parent": 94, "children": [], "start_point": {"row": 23, "column": 97}, "end_point": {"row": 23, "column": 100}}, {"id": 97, "type": "character", "text": "-", "parent": 94, "children": [], "start_point": {"row": 23, "column": 100}, "end_point": {"row": 23, "column": 101}}, {"id": 98, "type": "escape_sequence", "text": "\\x40", "parent": 94, "children": [], "start_point": {"row": 23, "column": 101}, "end_point": {"row": 23, "column": 105}}, {"id": 99, "type": "escape_sequence", "text": "\\x42", "parent": 94, "children": [], "start_point": {"row": 23, "column": 105}, "end_point": {"row": 23, "column": 109}}, {"id": 100, "type": "character", "text": "-", "parent": 94, "children": [], "start_point": {"row": 23, "column": 109}, "end_point": {"row": 23, "column": 110}}, {"id": 101, "type": "escape_sequence", "text": "\\x60", "parent": 94, "children": [], "start_point": {"row": 23, "column": 110}, "end_point": {"row": 23, "column": 114}}, {"id": 102, "type": "escape_sequence", "text": "\\x63", "parent": 94, "children": [], "start_point": {"row": 23, "column": 114}, "end_point": {"row": 23, "column": 118}}, {"id": 103, "type": "character", "text": "-", "parent": 94, "children": [], "start_point": {"row": 23, "column": 118}, "end_point": {"row": 23, "column": 119}}, {"id": 104, "type": "escape_sequence", "text": "\\xFF", "parent": 94, "children": [], "start_point": {"row": 23, "column": 119}, "end_point": {"row": 23, "column": 123}}, {"id": 105, "type": "'", "text": "'", "parent": 94, "children": [], "start_point": {"row": 23, "column": 124}, "end_point": {"row": 23, "column": 125}}, {"id": 106, "type": "type_identifier", "text": "use", "parent": 88, "children": [], "start_point": {"row": 23, "column": 127}, "end_point": {"row": 23, "column": 130}}, {"id": 107, "type": "identifier", "text": "default", "parent": 88, "children": [], "start_point": {"row": 23, "column": 131}, "end_point": {"row": 23, "column": 138}}, {"id": 108, "type": "identifier", "text": "rule", "parent": 88, "children": [], "start_point": {"row": 23, "column": 139}, "end_point": {"row": 23, "column": 143}}, {"id": 109, "type": "subscript_expression", "text": "'*' [-Wundefined-control-flow]", "parent": null, "children": [110, 114], "start_point": {"row": 23, "column": 144}, "end_point": {"row": 23, "column": 174}}, {"id": 110, "type": "char_literal", "text": "'*'", "parent": 109, "children": [111, 112, 113], "start_point": {"row": 23, "column": 144}, "end_point": {"row": 23, "column": 147}}, {"id": 111, "type": "'", "text": "'", "parent": 110, "children": [], "start_point": {"row": 23, "column": 144}, "end_point": {"row": 23, "column": 145}}, {"id": 112, "type": "character", "text": "*", "parent": 110, "children": [], "start_point": {"row": 23, "column": 145}, "end_point": {"row": 23, "column": 146}}, {"id": 113, "type": "'", "text": "'", "parent": 110, "children": [], "start_point": {"row": 23, "column": 146}, "end_point": {"row": 23, "column": 147}}, {"id": 114, "type": "binary_expression", "text": "-Wundefined-control-flow", "parent": 109, "children": [115, 121, 122], "start_point": {"row": 23, "column": 149}, "end_point": {"row": 23, "column": 173}}, {"id": 115, "type": "binary_expression", "text": "-Wundefined-control", "parent": 114, "children": [116, 119, 120], "start_point": {"row": 23, "column": 149}, "end_point": {"row": 23, "column": 168}}, {"id": 116, "type": "unary_expression", "text": "-Wundefined", "parent": 115, "children": [117, 118], "start_point": {"row": 23, "column": 149}, "end_point": {"row": 23, "column": 160}}, {"id": 117, "type": "-", "text": "-", "parent": 116, "children": [], "start_point": {"row": 23, "column": 149}, "end_point": {"row": 23, "column": 150}}, {"id": 118, "type": "identifier", "text": "Wundefined", "parent": 116, "children": [], "start_point": {"row": 23, "column": 150}, "end_point": {"row": 23, "column": 160}}, {"id": 119, "type": "-", "text": "-", "parent": 115, "children": [], "start_point": {"row": 23, "column": 160}, "end_point": {"row": 23, "column": 161}}, {"id": 120, "type": "identifier", "text": "control", "parent": 115, "children": [], "start_point": {"row": 23, "column": 161}, "end_point": {"row": 23, "column": 168}}, {"id": 121, "type": "-", "text": "-", "parent": 114, "children": [], "start_point": {"row": 23, "column": 168}, "end_point": {"row": 23, "column": 169}}, {"id": 122, "type": "identifier", "text": "flow", "parent": 114, "children": [], "start_point": {"row": 23, "column": 169}, "end_point": {"row": 23, "column": 173}}]}, "node_categories": {"declarations": {"functions": [], "variables": [0, 85], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [4, 5, 9, 16, 21, 56, 66, 75, 78, 109, 114, 115, 116], "assignments": [13], "loops": [], "conditionals": [1, 2, 3, 6, 8, 10, 14, 18, 19, 20, 22, 23, 24, 29, 30, 37, 38, 39, 46, 47, 51, 53, 55, 58, 65, 68, 76, 79, 80, 84, 86, 87, 89, 90, 91, 92, 93, 106, 107, 108, 118, 120, 122], "returns": [59, 69], "exceptions": []}, "expressions": {"calls": [], "literals": [12, 25, 31, 40, 60, 70, 81, 82, 94, 110], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [], "class_declarations": [], "import_statements": []}, "original_source_code": "/* Generated by re2c */\n// re2c $INPUT -o $OUTPUT -i --case-inverted\n\n{\n\tYYCTYPE yych;\n\tif (YYLIMIT <= YYCURSOR) YYFILL(1);\n\tyych = *YYCURSOR;\n\tswitch (yych) {\n\tcase 'A':\n\tcase 'a':\tgoto yy3;\n\tcase 'b':\tgoto yy5;\n\tdefault:\tgoto yy2;\n\t}\nyy2:\nyy3:\n\t++YYCURSOR;\n\t{return 'a';}\nyy5:\n\t++YYCURSOR;\n\t{return 'b';}\n}\n\n}\ncasing-flags_i_case_inverted.re:5:2: warning: control flow is undefined for strings that match '[\\x0-\\x40\\x42-\\x60\\x63-\\xFF]', use default rule '*' [-Wundefined-control-flow]\n"}
80,527
c
/*** * * include/rtmac/tdma/tdma.h * * RTmac - real-time networking media access control subsystem * Copyright (C) 2002 <NAME> <<EMAIL>>, * 2003-2005 <NAME> <<EMAIL>> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * */ #ifndef __TDMA_H_ #define __TDMA_H_ #include <rtdm/driver.h> #include <rtnet_rtpc.h> #include <rtmac/rtmac_disc.h> #define RTMAC_TYPE_TDMA 0x0001 #define TDMA_MAGIC 0x3A0D4D0A #define TDMA_FLAG_CALIBRATED 1 #define TDMA_FLAG_RECEIVED_SYNC 2 #define TDMA_FLAG_MASTER 3 /* also set for backup masters */ #define TDMA_FLAG_BACKUP_MASTER 4 #define TDMA_FLAG_ATTACHED 5 #define TDMA_FLAG_BACKUP_ACTIVE 6 #define DEFAULT_SLOT 0 #define DEFAULT_NRT_SLOT 1 /* job IDs */ #define WAIT_ON_SYNC -1 #define XMIT_SYNC -2 #define BACKUP_SYNC -3 #define XMIT_REQ_CAL -4 #define XMIT_RPL_CAL -5 struct tdma_priv; struct tdma_job { struct list_head entry; int id; unsigned int ref_count; }; #define SLOT_JOB(job) ((struct tdma_slot *)(job)) struct tdma_slot { struct tdma_job head; u64 offset; unsigned int period; unsigned int phasing; unsigned int mtu; unsigned int size; struct rtskb_prio_queue *queue; struct rtskb_prio_queue local_queue; }; #define REQUEST_CAL_JOB(job) ((struct tdma_request_cal *)(job)) struct tdma_request_cal { struct tdma_job head; struct tdma_priv *tdma; u64 offset; unsigned int period; unsigned int phasing; unsigned int cal_rounds; u64 *cal_results; u64 *result_buffer; }; #define REPLY_CAL_JOB(job) ((struct tdma_reply_cal *)(job)) struct tdma_reply_cal { struct tdma_job head; u32 reply_cycle; u64 reply_offset; struct rtskb *reply_rtskb; }; struct tdma_priv { unsigned int magic; struct rtnet_device *rtdev; char device_name[32]; struct rtdm_driver api_driver; struct rtdm_device api_device; #ifdef ALIGN_RTOS_TASK __u8 __align[(ALIGN_RTOS_TASK - ((sizeof(unsigned int) + sizeof(struct rtnet_device *) + sizeof(struct rtdm_device) ) & (ALIGN_RTOS_TASK-1)) ) & (ALIGN_RTOS_TASK-1)]; #endif rtdm_task_t worker_task; rtdm_event_t worker_wakeup; rtdm_event_t xmit_event; rtdm_event_t sync_event; unsigned long flags; unsigned int cal_rounds; u32 current_cycle; u64 current_cycle_start; u64 master_packet_delay_ns; nanosecs_rel_t clock_offset; struct tdma_job sync_job; struct tdma_job *first_job; struct tdma_job *current_job; volatile unsigned int job_list_revision; unsigned int max_slot_id; struct tdma_slot **slot_table; struct rt_proc_call *calibration_call; unsigned char master_hw_addr[MAX_ADDR_LEN]; rtdm_lock_t lock; #ifdef CONFIG_XENO_DRIVERS_NET_TDMA_MASTER struct rtskb_pool cal_rtskb_pool; u64 cycle_period; u64 backup_sync_inc; #endif #ifdef CONFIG_XENO_OPT_VFILE struct list_head list_entry; #endif }; extern struct rtmac_disc tdma_disc; #define print_jobs() do { \ struct tdma_job *entry; \ rtdm_printk("%s:%d - ", __FUNCTION__, __LINE__); \ list_for_each_entry(entry, &tdma->first_job->entry, entry) \ rtdm_printk("%d ", entry->id); \ rtdm_printk("\n"); \ } while (0) #endif /* __TDMA_H_ */
36.46
134
(translation_unit) "/***\n *\n * include/rtmac/tdma/tdma.h\n *\n * RTmac - real-time networking media access control subsystem\n * Copyright (C) 2002 <NAME> <<EMAIL>>,\n * 2003-2005 <NAME> <<EMAIL>>\n *\n * This program is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.\n *\n */\n\n#ifndef __TDMA_H_\n#define __TDMA_H_\n\n#include <rtdm/driver.h>\n\n#include <rtnet_rtpc.h>\n#include <rtmac/rtmac_disc.h>\n\n\n#define RTMAC_TYPE_TDMA 0x0001\n\n#define TDMA_MAGIC 0x3A0D4D0A\n\n#define TDMA_FLAG_CALIBRATED 1\n#define TDMA_FLAG_RECEIVED_SYNC 2\n#define TDMA_FLAG_MASTER 3 /* also set for backup masters */\n#define TDMA_FLAG_BACKUP_MASTER 4\n#define TDMA_FLAG_ATTACHED 5\n#define TDMA_FLAG_BACKUP_ACTIVE 6\n\n#define DEFAULT_SLOT 0\n#define DEFAULT_NRT_SLOT 1\n\n/* job IDs */\n#define WAIT_ON_SYNC -1\n#define XMIT_SYNC -2\n#define BACKUP_SYNC -3\n#define XMIT_REQ_CAL -4\n#define XMIT_RPL_CAL -5\n\n\nstruct tdma_priv;\n\n\nstruct tdma_job {\n struct list_head entry;\n int id;\n unsigned int ref_count;\n};\n\n\n#define SLOT_JOB(job) ((struct tdma_slot *)(job))\n\nstruct tdma_slot {\n struct tdma_job head;\n\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int mtu;\n unsigned int size;\n struct rtskb_prio_queue *queue;\n struct rtskb_prio_queue local_queue;\n};\n\n\n#define REQUEST_CAL_JOB(job) ((struct tdma_request_cal *)(job))\n\nstruct tdma_request_cal {\n struct tdma_job head;\n\n struct tdma_priv *tdma;\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int cal_rounds;\n u64 *cal_results;\n u64 *result_buffer;\n};\n\n\n#define REPLY_CAL_JOB(job) ((struct tdma_reply_cal *)(job))\n\nstruct tdma_reply_cal {\n struct tdma_job head;\n\n u32 reply_cycle;\n u64 reply_offset;\n struct rtskb *reply_rtskb;\n};\n\nstruct tdma_priv {\n unsigned int magic;\n struct rtnet_device *rtdev;\n char device_name[32];\n struct rtdm_driver api_driver;\n struct rtdm_device api_device;\n\n#ifdef ALIGN_RTOS_TASK\n __u8 __align[(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)];\n#endif\n rtdm_task_t worker_task;\n rtdm_event_t worker_wakeup;\n rtdm_event_t xmit_event;\n rtdm_event_t sync_event;\n\n unsigned long flags;\n unsigned int cal_rounds;\n u32 current_cycle;\n u64 current_cycle_start;\n u64 master_packet_delay_ns;\n nanosecs_rel_t clock_offset;\n\n struct tdma_job sync_job;\n struct tdma_job *first_job;\n struct tdma_job *current_job;\n volatile unsigned int job_list_revision;\n\n unsigned int max_slot_id;\n struct tdma_slot **slot_table;\n\n struct rt_proc_call *calibration_call;\n unsigned char master_hw_addr[MAX_ADDR_LEN];\n\n rtdm_lock_t lock;\n\n#ifdef CONFIG_XENO_DRIVERS_NET_TDMA_MASTER\n struct rtskb_pool cal_rtskb_pool;\n u64 cycle_period;\n u64 backup_sync_inc;\n#endif\n\n#ifdef CONFIG_XENO_OPT_VFILE\n struct list_head list_entry;\n#endif\n};\n\n\nextern struct rtmac_disc tdma_disc;\n\n#define print_jobs() do { \\n struct tdma_job *entry; \\n rtdm_printk("%s:%d - ", __FUNCTION__, __LINE__); \\n list_for_each_entry(entry, &tdma->first_job->entry, entry) \\n rtdm_printk("%d ", entry->id); \\n rtdm_printk("\n"); \\n} while (0)\n\n#endif /* __TDMA_H_ */\n" (comment) "/***\n *\n * include/rtmac/tdma/tdma.h\n *\n * RTmac - real-time networking media access control subsystem\n * Copyright (C) 2002 <NAME> <<EMAIL>>,\n * 2003-2005 <NAME> <<EMAIL>>\n *\n * This program is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.\n *\n */" (preproc_ifdef) "#ifndef __TDMA_H_\n#define __TDMA_H_\n\n#include <rtdm/driver.h>\n\n#include <rtnet_rtpc.h>\n#include <rtmac/rtmac_disc.h>\n\n\n#define RTMAC_TYPE_TDMA 0x0001\n\n#define TDMA_MAGIC 0x3A0D4D0A\n\n#define TDMA_FLAG_CALIBRATED 1\n#define TDMA_FLAG_RECEIVED_SYNC 2\n#define TDMA_FLAG_MASTER 3 /* also set for backup masters */\n#define TDMA_FLAG_BACKUP_MASTER 4\n#define TDMA_FLAG_ATTACHED 5\n#define TDMA_FLAG_BACKUP_ACTIVE 6\n\n#define DEFAULT_SLOT 0\n#define DEFAULT_NRT_SLOT 1\n\n/* job IDs */\n#define WAIT_ON_SYNC -1\n#define XMIT_SYNC -2\n#define BACKUP_SYNC -3\n#define XMIT_REQ_CAL -4\n#define XMIT_RPL_CAL -5\n\n\nstruct tdma_priv;\n\n\nstruct tdma_job {\n struct list_head entry;\n int id;\n unsigned int ref_count;\n};\n\n\n#define SLOT_JOB(job) ((struct tdma_slot *)(job))\n\nstruct tdma_slot {\n struct tdma_job head;\n\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int mtu;\n unsigned int size;\n struct rtskb_prio_queue *queue;\n struct rtskb_prio_queue local_queue;\n};\n\n\n#define REQUEST_CAL_JOB(job) ((struct tdma_request_cal *)(job))\n\nstruct tdma_request_cal {\n struct tdma_job head;\n\n struct tdma_priv *tdma;\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int cal_rounds;\n u64 *cal_results;\n u64 *result_buffer;\n};\n\n\n#define REPLY_CAL_JOB(job) ((struct tdma_reply_cal *)(job))\n\nstruct tdma_reply_cal {\n struct tdma_job head;\n\n u32 reply_cycle;\n u64 reply_offset;\n struct rtskb *reply_rtskb;\n};\n\nstruct tdma_priv {\n unsigned int magic;\n struct rtnet_device *rtdev;\n char device_name[32];\n struct rtdm_driver api_driver;\n struct rtdm_device api_device;\n\n#ifdef ALIGN_RTOS_TASK\n __u8 __align[(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)];\n#endif\n rtdm_task_t worker_task;\n rtdm_event_t worker_wakeup;\n rtdm_event_t xmit_event;\n rtdm_event_t sync_event;\n\n unsigned long flags;\n unsigned int cal_rounds;\n u32 current_cycle;\n u64 current_cycle_start;\n u64 master_packet_delay_ns;\n nanosecs_rel_t clock_offset;\n\n struct tdma_job sync_job;\n struct tdma_job *first_job;\n struct tdma_job *current_job;\n volatile unsigned int job_list_revision;\n\n unsigned int max_slot_id;\n struct tdma_slot **slot_table;\n\n struct rt_proc_call *calibration_call;\n unsigned char master_hw_addr[MAX_ADDR_LEN];\n\n rtdm_lock_t lock;\n\n#ifdef CONFIG_XENO_DRIVERS_NET_TDMA_MASTER\n struct rtskb_pool cal_rtskb_pool;\n u64 cycle_period;\n u64 backup_sync_inc;\n#endif\n\n#ifdef CONFIG_XENO_OPT_VFILE\n struct list_head list_entry;\n#endif\n};\n\n\nextern struct rtmac_disc tdma_disc;\n\n#define print_jobs() do { \\n struct tdma_job *entry; \\n rtdm_printk("%s:%d - ", __FUNCTION__, __LINE__); \\n list_for_each_entry(entry, &tdma->first_job->entry, entry) \\n rtdm_printk("%d ", entry->id); \\n rtdm_printk("\n"); \\n} while (0)\n\n#endif" (#ifndef) "#ifndef" (identifier) "__TDMA_H_" (preproc_def) "#define __TDMA_H_\n" (#define) "#define" (identifier) "__TDMA_H_" (preproc_include) "#include <rtdm/driver.h>\n" (#include) "#include" (system_lib_string) "<rtdm/driver.h>" (preproc_include) "#include <rtnet_rtpc.h>\n" (#include) "#include" (system_lib_string) "<rtnet_rtpc.h>" (preproc_include) "#include <rtmac/rtmac_disc.h>\n" (#include) "#include" (system_lib_string) "<rtmac/rtmac_disc.h>" (preproc_def) "#define RTMAC_TYPE_TDMA 0x0001\n" (#define) "#define" (identifier) "RTMAC_TYPE_TDMA" (preproc_arg) "0x0001" (preproc_def) "#define TDMA_MAGIC 0x3A0D4D0A\n" (#define) "#define" (identifier) "TDMA_MAGIC" (preproc_arg) "0x3A0D4D0A" (preproc_def) "#define TDMA_FLAG_CALIBRATED 1\n" (#define) "#define" (identifier) "TDMA_FLAG_CALIBRATED" (preproc_arg) "1" (preproc_def) "#define TDMA_FLAG_RECEIVED_SYNC 2\n" (#define) "#define" (identifier) "TDMA_FLAG_RECEIVED_SYNC" (preproc_arg) "2" (preproc_def) "#define TDMA_FLAG_MASTER 3 /* also set for backup masters */\n" (#define) "#define" (identifier) "TDMA_FLAG_MASTER" (preproc_arg) "3 " (comment) "/* also set for backup masters */" (preproc_def) "#define TDMA_FLAG_BACKUP_MASTER 4\n" (#define) "#define" (identifier) "TDMA_FLAG_BACKUP_MASTER" (preproc_arg) "4" (preproc_def) "#define TDMA_FLAG_ATTACHED 5\n" (#define) "#define" (identifier) "TDMA_FLAG_ATTACHED" (preproc_arg) "5" (preproc_def) "#define TDMA_FLAG_BACKUP_ACTIVE 6\n" (#define) "#define" (identifier) "TDMA_FLAG_BACKUP_ACTIVE" (preproc_arg) "6" (preproc_def) "#define DEFAULT_SLOT 0\n" (#define) "#define" (identifier) "DEFAULT_SLOT" (preproc_arg) "0" (preproc_def) "#define DEFAULT_NRT_SLOT 1\n" (#define) "#define" (identifier) "DEFAULT_NRT_SLOT" (preproc_arg) "1" (comment) "/* job IDs */" (preproc_def) "#define WAIT_ON_SYNC -1\n" (#define) "#define" (identifier) "WAIT_ON_SYNC" (preproc_arg) "-1" (preproc_def) "#define XMIT_SYNC -2\n" (#define) "#define" (identifier) "XMIT_SYNC" (preproc_arg) "-2" (preproc_def) "#define BACKUP_SYNC -3\n" (#define) "#define" (identifier) "BACKUP_SYNC" (preproc_arg) "-3" (preproc_def) "#define XMIT_REQ_CAL -4\n" (#define) "#define" (identifier) "XMIT_REQ_CAL" (preproc_arg) "-4" (preproc_def) "#define XMIT_RPL_CAL -5\n" (#define) "#define" (identifier) "XMIT_RPL_CAL" (preproc_arg) "-5" (struct_specifier) "struct tdma_priv" (struct) "struct" (type_identifier) "tdma_priv" (;) ";" (struct_specifier) "struct tdma_job {\n struct list_head entry;\n int id;\n unsigned int ref_count;\n}" (struct) "struct" (type_identifier) "tdma_job" (field_declaration_list) "{\n struct list_head entry;\n int id;\n unsigned int ref_count;\n}" ({) "{" (field_declaration) "struct list_head entry;" (struct_specifier) "struct list_head" (struct) "struct" (type_identifier) "list_head" (field_identifier) "entry" (;) ";" (field_declaration) "int id;" (primitive_type) "int" (field_identifier) "id" (;) ";" (field_declaration) "unsigned int ref_count;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "ref_count" (;) ";" (}) "}" (;) ";" (preproc_function_def) "#define SLOT_JOB(job) ((struct tdma_slot *)(job))\n" (#define) "#define" (identifier) "SLOT_JOB" (preproc_params) "(job)" (() "(" (identifier) "job" ()) ")" (preproc_arg) "((struct tdma_slot *)(job))" (struct_specifier) "struct tdma_slot {\n struct tdma_job head;\n\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int mtu;\n unsigned int size;\n struct rtskb_prio_queue *queue;\n struct rtskb_prio_queue local_queue;\n}" (struct) "struct" (type_identifier) "tdma_slot" (field_declaration_list) "{\n struct tdma_job head;\n\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int mtu;\n unsigned int size;\n struct rtskb_prio_queue *queue;\n struct rtskb_prio_queue local_queue;\n}" ({) "{" (field_declaration) "struct tdma_job head;" (struct_specifier) "struct tdma_job" (struct) "struct" (type_identifier) "tdma_job" (field_identifier) "head" (;) ";" (field_declaration) "u64 offset;" (type_identifier) "u64" (field_identifier) "offset" (;) ";" (field_declaration) "unsigned int period;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "period" (;) ";" (field_declaration) "unsigned int phasing;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "phasing" (;) ";" (field_declaration) "unsigned int mtu;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "mtu" (;) ";" (field_declaration) "unsigned int size;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "size" (;) ";" (field_declaration) "struct rtskb_prio_queue *queue;" (struct_specifier) "struct rtskb_prio_queue" (struct) "struct" (type_identifier) "rtskb_prio_queue" (pointer_declarator) "*queue" (*) "*" (field_identifier) "queue" (;) ";" (field_declaration) "struct rtskb_prio_queue local_queue;" (struct_specifier) "struct rtskb_prio_queue" (struct) "struct" (type_identifier) "rtskb_prio_queue" (field_identifier) "local_queue" (;) ";" (}) "}" (;) ";" (preproc_function_def) "#define REQUEST_CAL_JOB(job) ((struct tdma_request_cal *)(job))\n" (#define) "#define" (identifier) "REQUEST_CAL_JOB" (preproc_params) "(job)" (() "(" (identifier) "job" ()) ")" (preproc_arg) "((struct tdma_request_cal *)(job))" (struct_specifier) "struct tdma_request_cal {\n struct tdma_job head;\n\n struct tdma_priv *tdma;\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int cal_rounds;\n u64 *cal_results;\n u64 *result_buffer;\n}" (struct) "struct" (type_identifier) "tdma_request_cal" (field_declaration_list) "{\n struct tdma_job head;\n\n struct tdma_priv *tdma;\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int cal_rounds;\n u64 *cal_results;\n u64 *result_buffer;\n}" ({) "{" (field_declaration) "struct tdma_job head;" (struct_specifier) "struct tdma_job" (struct) "struct" (type_identifier) "tdma_job" (field_identifier) "head" (;) ";" (field_declaration) "struct tdma_priv *tdma;" (struct_specifier) "struct tdma_priv" (struct) "struct" (type_identifier) "tdma_priv" (pointer_declarator) "*tdma" (*) "*" (field_identifier) "tdma" (;) ";" (field_declaration) "u64 offset;" (type_identifier) "u64" (field_identifier) "offset" (;) ";" (field_declaration) "unsigned int period;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "period" (;) ";" (field_declaration) "unsigned int phasing;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "phasing" (;) ";" (field_declaration) "unsigned int cal_rounds;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "cal_rounds" (;) ";" (field_declaration) "u64 *cal_results;" (type_identifier) "u64" (pointer_declarator) "*cal_results" (*) "*" (field_identifier) "cal_results" (;) ";" (field_declaration) "u64 *result_buffer;" (type_identifier) "u64" (pointer_declarator) "*result_buffer" (*) "*" (field_identifier) "result_buffer" (;) ";" (}) "}" (;) ";" (preproc_function_def) "#define REPLY_CAL_JOB(job) ((struct tdma_reply_cal *)(job))\n" (#define) "#define" (identifier) "REPLY_CAL_JOB" (preproc_params) "(job)" (() "(" (identifier) "job" ()) ")" (preproc_arg) "((struct tdma_reply_cal *)(job))" (struct_specifier) "struct tdma_reply_cal {\n struct tdma_job head;\n\n u32 reply_cycle;\n u64 reply_offset;\n struct rtskb *reply_rtskb;\n}" (struct) "struct" (type_identifier) "tdma_reply_cal" (field_declaration_list) "{\n struct tdma_job head;\n\n u32 reply_cycle;\n u64 reply_offset;\n struct rtskb *reply_rtskb;\n}" ({) "{" (field_declaration) "struct tdma_job head;" (struct_specifier) "struct tdma_job" (struct) "struct" (type_identifier) "tdma_job" (field_identifier) "head" (;) ";" (field_declaration) "u32 reply_cycle;" (type_identifier) "u32" (field_identifier) "reply_cycle" (;) ";" (field_declaration) "u64 reply_offset;" (type_identifier) "u64" (field_identifier) "reply_offset" (;) ";" (field_declaration) "struct rtskb *reply_rtskb;" (struct_specifier) "struct rtskb" (struct) "struct" (type_identifier) "rtskb" (pointer_declarator) "*reply_rtskb" (*) "*" (field_identifier) "reply_rtskb" (;) ";" (}) "}" (;) ";" (struct_specifier) "struct tdma_priv {\n unsigned int magic;\n struct rtnet_device *rtdev;\n char device_name[32];\n struct rtdm_driver api_driver;\n struct rtdm_device api_device;\n\n#ifdef ALIGN_RTOS_TASK\n __u8 __align[(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)];\n#endif\n rtdm_task_t worker_task;\n rtdm_event_t worker_wakeup;\n rtdm_event_t xmit_event;\n rtdm_event_t sync_event;\n\n unsigned long flags;\n unsigned int cal_rounds;\n u32 current_cycle;\n u64 current_cycle_start;\n u64 master_packet_delay_ns;\n nanosecs_rel_t clock_offset;\n\n struct tdma_job sync_job;\n struct tdma_job *first_job;\n struct tdma_job *current_job;\n volatile unsigned int job_list_revision;\n\n unsigned int max_slot_id;\n struct tdma_slot **slot_table;\n\n struct rt_proc_call *calibration_call;\n unsigned char master_hw_addr[MAX_ADDR_LEN];\n\n rtdm_lock_t lock;\n\n#ifdef CONFIG_XENO_DRIVERS_NET_TDMA_MASTER\n struct rtskb_pool cal_rtskb_pool;\n u64 cycle_period;\n u64 backup_sync_inc;\n#endif\n\n#ifdef CONFIG_XENO_OPT_VFILE\n struct list_head list_entry;\n#endif\n}" (struct) "struct" (type_identifier) "tdma_priv" (field_declaration_list) "{\n unsigned int magic;\n struct rtnet_device *rtdev;\n char device_name[32];\n struct rtdm_driver api_driver;\n struct rtdm_device api_device;\n\n#ifdef ALIGN_RTOS_TASK\n __u8 __align[(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)];\n#endif\n rtdm_task_t worker_task;\n rtdm_event_t worker_wakeup;\n rtdm_event_t xmit_event;\n rtdm_event_t sync_event;\n\n unsigned long flags;\n unsigned int cal_rounds;\n u32 current_cycle;\n u64 current_cycle_start;\n u64 master_packet_delay_ns;\n nanosecs_rel_t clock_offset;\n\n struct tdma_job sync_job;\n struct tdma_job *first_job;\n struct tdma_job *current_job;\n volatile unsigned int job_list_revision;\n\n unsigned int max_slot_id;\n struct tdma_slot **slot_table;\n\n struct rt_proc_call *calibration_call;\n unsigned char master_hw_addr[MAX_ADDR_LEN];\n\n rtdm_lock_t lock;\n\n#ifdef CONFIG_XENO_DRIVERS_NET_TDMA_MASTER\n struct rtskb_pool cal_rtskb_pool;\n u64 cycle_period;\n u64 backup_sync_inc;\n#endif\n\n#ifdef CONFIG_XENO_OPT_VFILE\n struct list_head list_entry;\n#endif\n}" ({) "{" (field_declaration) "unsigned int magic;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "magic" (;) ";" (field_declaration) "struct rtnet_device *rtdev;" (struct_specifier) "struct rtnet_device" (struct) "struct" (type_identifier) "rtnet_device" (pointer_declarator) "*rtdev" (*) "*" (field_identifier) "rtdev" (;) ";" (field_declaration) "char device_name[32];" (primitive_type) "char" (array_declarator) "device_name[32]" (field_identifier) "device_name" ([) "[" (number_literal) "32" (]) "]" (;) ";" (field_declaration) "struct rtdm_driver api_driver;" (struct_specifier) "struct rtdm_driver" (struct) "struct" (type_identifier) "rtdm_driver" (field_identifier) "api_driver" (;) ";" (field_declaration) "struct rtdm_device api_device;" (struct_specifier) "struct rtdm_device" (struct) "struct" (type_identifier) "rtdm_device" (field_identifier) "api_device" (;) ";" (preproc_ifdef) "#ifdef ALIGN_RTOS_TASK\n __u8 __align[(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)];\n#endif" (#ifdef) "#ifdef" (identifier) "ALIGN_RTOS_TASK" (field_declaration) "__u8 __align[(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)];" (type_identifier) "__u8" (array_declarator) "__align[(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)]" (field_identifier) "__align" ([) "[" (binary_expression) "(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)" (parenthesized_expression) "(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n )" (() "(" (binary_expression) "ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))" (identifier) "ALIGN_RTOS_TASK" (-) "-" (parenthesized_expression) "((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))" (() "(" (binary_expression) "(sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1)" (parenthesized_expression) "(sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n )" (() "(" (binary_expression) "sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)" (binary_expression) "sizeof(unsigned int) +\n sizeof(struct rtnet_device *)" (sizeof_expression) "sizeof(unsigned int)" (sizeof) "sizeof" (() "(" (type_descriptor) "unsigned int" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" ()) ")" (+) "+" (sizeof_expression) "sizeof(struct rtnet_device *)" (sizeof) "sizeof" (() "(" (type_descriptor) "struct rtnet_device *" (struct_specifier) "struct rtnet_device" (struct) "struct" (type_identifier) "rtnet_device" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (+) "+" (sizeof_expression) "sizeof(struct rtdm_device)" (sizeof) "sizeof" (() "(" (type_descriptor) "struct rtdm_device" (struct_specifier) "struct rtdm_device" (struct) "struct" (type_identifier) "rtdm_device" ()) ")" ()) ")" (&) "&" (parenthesized_expression) "(ALIGN_RTOS_TASK-1)" (() "(" (binary_expression) "ALIGN_RTOS_TASK-1" (identifier) "ALIGN_RTOS_TASK" (-) "-" (number_literal) "1" ()) ")" ()) ")" ()) ")" (&) "&" (parenthesized_expression) "(ALIGN_RTOS_TASK-1)" (() "(" (binary_expression) "ALIGN_RTOS_TASK-1" (identifier) "ALIGN_RTOS_TASK" (-) "-" (number_literal) "1" ()) ")" (]) "]" (;) ";" (#endif) "#endif" (field_declaration) "rtdm_task_t worker_task;" (type_identifier) "rtdm_task_t" (field_identifier) "worker_task" (;) ";" (field_declaration) "rtdm_event_t worker_wakeup;" (type_identifier) "rtdm_event_t" (field_identifier) "worker_wakeup" (;) ";" (field_declaration) "rtdm_event_t xmit_event;" (type_identifier) "rtdm_event_t" (field_identifier) "xmit_event" (;) ";" (field_declaration) "rtdm_event_t sync_event;" (type_identifier) "rtdm_event_t" (field_identifier) "sync_event" (;) ";" (field_declaration) "unsigned long flags;" (sized_type_specifier) "unsigned long" (unsigned) "unsigned" (long) "long" (field_identifier) "flags" (;) ";" (field_declaration) "unsigned int cal_rounds;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "cal_rounds" (;) ";" (field_declaration) "u32 current_cycle;" (type_identifier) "u32" (field_identifier) "current_cycle" (;) ";" (field_declaration) "u64 current_cycle_start;" (type_identifier) "u64" (field_identifier) "current_cycle_start" (;) ";" (field_declaration) "u64 master_packet_delay_ns;" (type_identifier) "u64" (field_identifier) "master_packet_delay_ns" (;) ";" (field_declaration) "nanosecs_rel_t clock_offset;" (type_identifier) "nanosecs_rel_t" (field_identifier) "clock_offset" (;) ";" (field_declaration) "struct tdma_job sync_job;" (struct_specifier) "struct tdma_job" (struct) "struct" (type_identifier) "tdma_job" (field_identifier) "sync_job" (;) ";" (field_declaration) "struct tdma_job *first_job;" (struct_specifier) "struct tdma_job" (struct) "struct" (type_identifier) "tdma_job" (pointer_declarator) "*first_job" (*) "*" (field_identifier) "first_job" (;) ";" (field_declaration) "struct tdma_job *current_job;" (struct_specifier) "struct tdma_job" (struct) "struct" (type_identifier) "tdma_job" (pointer_declarator) "*current_job" (*) "*" (field_identifier) "current_job" (;) ";" (field_declaration) "volatile unsigned int job_list_revision;" (type_qualifier) "volatile" (volatile) "volatile" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "job_list_revision" (;) ";" (field_declaration) "unsigned int max_slot_id;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "max_slot_id" (;) ";" (field_declaration) "struct tdma_slot **slot_table;" (struct_specifier) "struct tdma_slot" (struct) "struct" (type_identifier) "tdma_slot" (pointer_declarator) "**slot_table" (*) "*" (pointer_declarator) "*slot_table" (*) "*" (field_identifier) "slot_table" (;) ";" (field_declaration) "struct rt_proc_call *calibration_call;" (struct_specifier) "struct rt_proc_call" (struct) "struct" (type_identifier) "rt_proc_call" (pointer_declarator) "*calibration_call" (*) "*" (field_identifier) "calibration_call" (;) ";" (field_declaration) "unsigned char master_hw_addr[MAX_ADDR_LEN];" (sized_type_specifier) "unsigned char" (unsigned) "unsigned" (primitive_type) "char" (array_declarator) "master_hw_addr[MAX_ADDR_LEN]" (field_identifier) "master_hw_addr" ([) "[" (identifier) "MAX_ADDR_LEN" (]) "]" (;) ";" (field_declaration) "rtdm_lock_t lock;" (type_identifier) "rtdm_lock_t" (field_identifier) "lock" (;) ";" (preproc_ifdef) "#ifdef CONFIG_XENO_DRIVERS_NET_TDMA_MASTER\n struct rtskb_pool cal_rtskb_pool;\n u64 cycle_period;\n u64 backup_sync_inc;\n#endif" (#ifdef) "#ifdef" (identifier) "CONFIG_XENO_DRIVERS_NET_TDMA_MASTER" (field_declaration) "struct rtskb_pool cal_rtskb_pool;" (struct_specifier) "struct rtskb_pool" (struct) "struct" (type_identifier) "rtskb_pool" (field_identifier) "cal_rtskb_pool" (;) ";" (field_declaration) "u64 cycle_period;" (type_identifier) "u64" (field_identifier) "cycle_period" (;) ";" (field_declaration) "u64 backup_sync_inc;" (type_identifier) "u64" (field_identifier) "backup_sync_inc" (;) ";" (#endif) "#endif" (preproc_ifdef) "#ifdef CONFIG_XENO_OPT_VFILE\n struct list_head list_entry;\n#endif" (#ifdef) "#ifdef" (identifier) "CONFIG_XENO_OPT_VFILE" (field_declaration) "struct list_head list_entry;" (struct_specifier) "struct list_head" (struct) "struct" (type_identifier) "list_head" (field_identifier) "list_entry" (;) ";" (#endif) "#endif" (}) "}" (;) ";" (declaration) "extern struct rtmac_disc tdma_disc;" (storage_class_specifier) "extern" (extern) "extern" (struct_specifier) "struct rtmac_disc" (struct) "struct" (type_identifier) "rtmac_disc" (identifier) "tdma_disc" (;) ";" (preproc_function_def) "#define print_jobs() do { \\n struct tdma_job *entry; \\n rtdm_printk("%s:%d - ", __FUNCTION__, __LINE__); \\n list_for_each_entry(entry, &tdma->first_job->entry, entry) \\n rtdm_printk("%d ", entry->id); \\n rtdm_printk("\n"); \\n} while (0)\n" (#define) "#define" (identifier) "print_jobs" (preproc_params) "()" (() "(" ()) ")" (preproc_arg) "do { \\n struct tdma_job *entry; \\n rtdm_printk("%s:%d - ", __FUNCTION__, __LINE__); \\n list_for_each_entry(entry, &tdma->first_job->entry, entry) \\n rtdm_printk("%d ", entry->id); \\n rtdm_printk("\n"); \\n} while (0)" (#endif) "#endif" (comment) "/* __TDMA_H_ */"
538
0
{"language": "c", "success": true, "metadata": {"lines": 134, "avg_line_length": 36.46, "nodes": 424, "errors": 0, "source_hash": "876cee01a39ca633c9c0d4f92c68432c868ef412bbe2ffebd8d11d39f025c700", "categorized_nodes": 296}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef __TDMA_H_\n#define __TDMA_H_\n\n#include <rtdm/driver.h>\n\n#include <rtnet_rtpc.h>\n#include <rtmac/rtmac_disc.h>\n\n\n#define RTMAC_TYPE_TDMA 0x0001\n\n#define TDMA_MAGIC 0x3A0D4D0A\n\n#define TDMA_FLAG_CALIBRATED 1\n#define TDMA_FLAG_RECEIVED_SYNC 2\n#define TDMA_FLAG_MASTER 3 /* also set for backup masters */\n#define TDMA_FLAG_BACKUP_MASTER 4\n#define TDMA_FLAG_ATTACHED 5\n#define TDMA_FLAG_BACKUP_ACTIVE 6\n\n#define DEFAULT_SLOT 0\n#define DEFAULT_NRT_SLOT 1\n\n/* job IDs */\n#define WAIT_ON_SYNC -1\n#define XMIT_SYNC -2\n#define BACKUP_SYNC -3\n#define XMIT_REQ_CAL -4\n#define XMIT_RPL_CAL -5\n\n\nstruct tdma_priv;\n\n\nstruct tdma_job {\n struct list_head entry;\n int id;\n unsigned int ref_count;\n};\n\n\n#define SLOT_JOB(job) ((struct tdma_slot *)(job))\n\nstruct tdma_slot {\n struct tdma_job head;\n\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int mtu;\n unsigned int size;\n struct rtskb_prio_queue *queue;\n struct rtskb_prio_queue local_queue;\n};\n\n\n#define REQUEST_CAL_JOB(job) ((struct tdma_request_cal *)(job))\n\nstruct tdma_request_cal {\n struct tdma_job head;\n\n struct tdma_priv *tdma;\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int cal_rounds;\n u64 *cal_results;\n u64 *result_buffer;\n};\n\n\n#define REPLY_CAL_JOB(job) ((struct tdma_reply_cal *)(job))\n\nstruct tdma_reply_cal {\n struct tdma_job head;\n\n u32 reply_cycle;\n u64 reply_offset;\n struct rtskb *reply_rtskb;\n};\n\nstruct tdma_priv {\n unsigned int magic;\n struct rtnet_device *rtdev;\n char device_name[32];\n struct rtdm_driver api_driver;\n struct rtdm_device api_device;\n\n#ifdef ALIGN_RTOS_TASK\n __u8 __align[(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)];\n#endif\n rtdm_task_t worker_task;\n rtdm_event_t worker_wakeup;\n rtdm_event_t xmit_event;\n rtdm_event_t sync_event;\n\n unsigned long flags;\n unsigned int cal_rounds;\n u32 current_cycle;\n u64 current_cycle_start;\n u64 master_packet_delay_ns;\n nanosecs_rel_t clock_offset;\n\n struct tdma_job sync_job;\n struct tdma_job *first_job;\n struct tdma_job *current_job;\n volatile unsigned int job_list_revision;\n\n unsigned int max_slot_id;\n struct tdma_slot **slot_table;\n\n struct rt_proc_call *calibration_call;\n unsigned char master_hw_addr[MAX_ADDR_LEN];\n\n rtdm_lock_t lock;\n\n#ifdef CONFIG_XENO_DRIVERS_NET_TDMA_MASTER\n struct rtskb_pool cal_rtskb_pool;\n u64 cycle_period;\n u64 backup_sync_inc;\n#endif\n\n#ifdef CONFIG_XENO_OPT_VFILE\n struct list_head list_entry;\n#endif\n};\n\n\nextern struct rtmac_disc tdma_disc;\n\n#define print_jobs() do { \\\n struct tdma_job *entry; \\\n rtdm_printk(\"%s:%d - \", __FUNCTION__, __LINE__); \\\n list_for_each_entry(entry, &tdma->first_job->entry, entry) \\\n rtdm_printk(\"%d \", entry->id); \\\n rtdm_printk(\"\\n\"); \\\n} while (0)\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 15, 19, 23, 27, 31, 35, 39, 43, 47, 51, 55, 59, 63, 67, 71, 75, 78, 94, 100, 143, 149, 192, 198, 219, 411, 418, 423], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 167, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 7}}, {"id": 2, "type": "identifier", "text": "__TDMA_H_", "parent": 0, "children": [], "start_point": {"row": 24, "column": 8}, "end_point": {"row": 24, "column": 17}}, {"id": 3, "type": "preproc_def", "text": "#define __TDMA_H_\n", "parent": 0, "children": [4, 5], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 26, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 7}}, {"id": 5, "type": "identifier", "text": "__TDMA_H_", "parent": 3, "children": [], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 17}}, {"id": 6, "type": "preproc_include", "text": "#include <rtdm/driver.h>\n", "parent": 0, "children": [7, 8], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 28, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<rtdm/driver.h>", "parent": 6, "children": [], "start_point": {"row": 27, "column": 9}, "end_point": {"row": 27, "column": 24}}, {"id": 9, "type": "preproc_include", "text": "#include <rtnet_rtpc.h>\n", "parent": 0, "children": [10, 11], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 30, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<rtnet_rtpc.h>", "parent": 9, "children": [], "start_point": {"row": 29, "column": 9}, "end_point": {"row": 29, "column": 23}}, {"id": 12, "type": "preproc_include", "text": "#include <rtmac/rtmac_disc.h>\n", "parent": 0, "children": [13, 14], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 31, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 8}}, {"id": 14, "type": "system_lib_string", "text": "<rtmac/rtmac_disc.h>", "parent": 12, "children": [], "start_point": {"row": 30, "column": 9}, "end_point": {"row": 30, "column": 29}}, {"id": 15, "type": "preproc_def", "text": "#define RTMAC_TYPE_TDMA 0x0001\n", "parent": 0, "children": [16, 17, 18], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 34, "column": 0}}, {"id": 16, "type": "#define", "text": "#define", "parent": 15, "children": [], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 33, "column": 7}}, {"id": 17, "type": "identifier", "text": "RTMAC_TYPE_TDMA", "parent": 15, "children": [], "start_point": {"row": 33, "column": 8}, "end_point": {"row": 33, "column": 23}}, {"id": 18, "type": "preproc_arg", "text": "0x0001", "parent": 15, "children": [], "start_point": {"row": 33, "column": 32}, "end_point": {"row": 33, "column": 38}}, {"id": 19, "type": "preproc_def", "text": "#define TDMA_MAGIC 0x3A0D4D0A\n", "parent": 0, "children": [20, 21, 22], "start_point": {"row": 35, "column": 0}, "end_point": {"row": 36, "column": 0}}, {"id": 20, "type": "#define", "text": "#define", "parent": 19, "children": [], "start_point": {"row": 35, "column": 0}, "end_point": {"row": 35, "column": 7}}, {"id": 21, "type": "identifier", "text": "TDMA_MAGIC", "parent": 19, "children": [], "start_point": {"row": 35, "column": 8}, "end_point": {"row": 35, "column": 18}}, {"id": 22, "type": "preproc_arg", "text": "0x3A0D4D0A", "parent": 19, "children": [], "start_point": {"row": 35, "column": 32}, "end_point": {"row": 35, "column": 42}}, {"id": 23, "type": "preproc_def", "text": "#define TDMA_FLAG_CALIBRATED 1\n", "parent": 0, "children": [24, 25, 26], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 38, "column": 0}}, {"id": 24, "type": "#define", "text": "#define", "parent": 23, "children": [], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 37, "column": 7}}, {"id": 25, "type": "identifier", "text": "TDMA_FLAG_CALIBRATED", "parent": 23, "children": [], "start_point": {"row": 37, "column": 8}, "end_point": {"row": 37, "column": 28}}, {"id": 26, "type": "preproc_arg", "text": "1", "parent": 23, "children": [], "start_point": {"row": 37, "column": 32}, "end_point": {"row": 37, "column": 33}}, {"id": 27, "type": "preproc_def", "text": "#define TDMA_FLAG_RECEIVED_SYNC 2\n", "parent": 0, "children": [28, 29, 30], "start_point": {"row": 38, "column": 0}, "end_point": {"row": 39, "column": 0}}, {"id": 28, "type": "#define", "text": "#define", "parent": 27, "children": [], "start_point": {"row": 38, "column": 0}, "end_point": {"row": 38, "column": 7}}, {"id": 29, "type": "identifier", "text": "TDMA_FLAG_RECEIVED_SYNC", "parent": 27, "children": [], "start_point": {"row": 38, "column": 8}, "end_point": {"row": 38, "column": 31}}, {"id": 30, "type": "preproc_arg", "text": "2", "parent": 27, "children": [], "start_point": {"row": 38, "column": 32}, "end_point": {"row": 38, "column": 33}}, {"id": 31, "type": "preproc_def", "text": "#define TDMA_FLAG_MASTER 3 /* also set for backup masters */\n", "parent": 0, "children": [32, 33, 34], "start_point": {"row": 39, "column": 0}, "end_point": {"row": 40, "column": 0}}, {"id": 32, "type": "#define", "text": "#define", "parent": 31, "children": [], "start_point": {"row": 39, "column": 0}, "end_point": {"row": 39, "column": 7}}, {"id": 33, "type": "identifier", "text": "TDMA_FLAG_MASTER", "parent": 31, "children": [], "start_point": {"row": 39, "column": 8}, "end_point": {"row": 39, "column": 24}}, {"id": 34, "type": "preproc_arg", "text": "3 ", "parent": 31, "children": [], "start_point": {"row": 39, "column": 32}, "end_point": {"row": 39, "column": 36}}, {"id": 35, "type": "preproc_def", "text": "#define TDMA_FLAG_BACKUP_MASTER 4\n", "parent": 0, "children": [36, 37, 38], "start_point": {"row": 40, "column": 0}, "end_point": {"row": 41, "column": 0}}, {"id": 36, "type": "#define", "text": "#define", "parent": 35, "children": [], "start_point": {"row": 40, "column": 0}, "end_point": {"row": 40, "column": 7}}, {"id": 37, "type": "identifier", "text": "TDMA_FLAG_BACKUP_MASTER", "parent": 35, "children": [], "start_point": {"row": 40, "column": 8}, "end_point": {"row": 40, "column": 31}}, {"id": 38, "type": "preproc_arg", "text": "4", "parent": 35, "children": [], "start_point": {"row": 40, "column": 32}, "end_point": {"row": 40, "column": 33}}, {"id": 39, "type": "preproc_def", "text": "#define TDMA_FLAG_ATTACHED 5\n", "parent": 0, "children": [40, 41, 42], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 42, "column": 0}}, {"id": 40, "type": "#define", "text": "#define", "parent": 39, "children": [], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 41, "column": 7}}, {"id": 41, "type": "identifier", "text": "TDMA_FLAG_ATTACHED", "parent": 39, "children": [], "start_point": {"row": 41, "column": 8}, "end_point": {"row": 41, "column": 26}}, {"id": 42, "type": "preproc_arg", "text": "5", "parent": 39, "children": [], "start_point": {"row": 41, "column": 32}, "end_point": {"row": 41, "column": 33}}, {"id": 43, "type": "preproc_def", "text": "#define TDMA_FLAG_BACKUP_ACTIVE 6\n", "parent": 0, "children": [44, 45, 46], "start_point": {"row": 42, "column": 0}, "end_point": {"row": 43, "column": 0}}, {"id": 44, "type": "#define", "text": "#define", "parent": 43, "children": [], "start_point": {"row": 42, "column": 0}, "end_point": {"row": 42, "column": 7}}, {"id": 45, "type": "identifier", "text": "TDMA_FLAG_BACKUP_ACTIVE", "parent": 43, "children": [], "start_point": {"row": 42, "column": 8}, "end_point": {"row": 42, "column": 31}}, {"id": 46, "type": "preproc_arg", "text": "6", "parent": 43, "children": [], "start_point": {"row": 42, "column": 32}, "end_point": {"row": 42, "column": 33}}, {"id": 47, "type": "preproc_def", "text": "#define DEFAULT_SLOT 0\n", "parent": 0, "children": [48, 49, 50], "start_point": {"row": 44, "column": 0}, "end_point": {"row": 45, "column": 0}}, {"id": 48, "type": "#define", "text": "#define", "parent": 47, "children": [], "start_point": {"row": 44, "column": 0}, "end_point": {"row": 44, "column": 7}}, {"id": 49, "type": "identifier", "text": "DEFAULT_SLOT", "parent": 47, "children": [], "start_point": {"row": 44, "column": 8}, "end_point": {"row": 44, "column": 20}}, {"id": 50, "type": "preproc_arg", "text": "0", "parent": 47, "children": [], "start_point": {"row": 44, "column": 32}, "end_point": {"row": 44, "column": 33}}, {"id": 51, "type": "preproc_def", "text": "#define DEFAULT_NRT_SLOT 1\n", "parent": 0, "children": [52, 53, 54], "start_point": {"row": 45, "column": 0}, "end_point": {"row": 46, "column": 0}}, {"id": 52, "type": "#define", "text": "#define", "parent": 51, "children": [], "start_point": {"row": 45, "column": 0}, "end_point": {"row": 45, "column": 7}}, {"id": 53, "type": "identifier", "text": "DEFAULT_NRT_SLOT", "parent": 51, "children": [], "start_point": {"row": 45, "column": 8}, "end_point": {"row": 45, "column": 24}}, {"id": 54, "type": "preproc_arg", "text": "1", "parent": 51, "children": [], "start_point": {"row": 45, "column": 32}, "end_point": {"row": 45, "column": 33}}, {"id": 55, "type": "preproc_def", "text": "#define WAIT_ON_SYNC -1\n", "parent": 0, "children": [56, 57, 58], "start_point": {"row": 48, "column": 0}, "end_point": {"row": 49, "column": 0}}, {"id": 56, "type": "#define", "text": "#define", "parent": 55, "children": [], "start_point": {"row": 48, "column": 0}, "end_point": {"row": 48, "column": 7}}, {"id": 57, "type": "identifier", "text": "WAIT_ON_SYNC", "parent": 55, "children": [], "start_point": {"row": 48, "column": 8}, "end_point": {"row": 48, "column": 20}}, {"id": 58, "type": "preproc_arg", "text": "-1", "parent": 55, "children": [], "start_point": {"row": 48, "column": 32}, "end_point": {"row": 48, "column": 34}}, {"id": 59, "type": "preproc_def", "text": "#define XMIT_SYNC -2\n", "parent": 0, "children": [60, 61, 62], "start_point": {"row": 49, "column": 0}, "end_point": {"row": 50, "column": 0}}, {"id": 60, "type": "#define", "text": "#define", "parent": 59, "children": [], "start_point": {"row": 49, "column": 0}, "end_point": {"row": 49, "column": 7}}, {"id": 61, "type": "identifier", "text": "XMIT_SYNC", "parent": 59, "children": [], "start_point": {"row": 49, "column": 8}, "end_point": {"row": 49, "column": 17}}, {"id": 62, "type": "preproc_arg", "text": "-2", "parent": 59, "children": [], "start_point": {"row": 49, "column": 32}, "end_point": {"row": 49, "column": 34}}, {"id": 63, "type": "preproc_def", "text": "#define BACKUP_SYNC -3\n", "parent": 0, "children": [64, 65, 66], "start_point": {"row": 50, "column": 0}, "end_point": {"row": 51, "column": 0}}, {"id": 64, "type": "#define", "text": "#define", "parent": 63, "children": [], "start_point": {"row": 50, "column": 0}, "end_point": {"row": 50, "column": 7}}, {"id": 65, "type": "identifier", "text": "BACKUP_SYNC", "parent": 63, "children": [], "start_point": {"row": 50, "column": 8}, "end_point": {"row": 50, "column": 19}}, {"id": 66, "type": "preproc_arg", "text": "-3", "parent": 63, "children": [], "start_point": {"row": 50, "column": 32}, "end_point": {"row": 50, "column": 34}}, {"id": 67, "type": "preproc_def", "text": "#define XMIT_REQ_CAL -4\n", "parent": 0, "children": [68, 69, 70], "start_point": {"row": 51, "column": 0}, "end_point": {"row": 52, "column": 0}}, {"id": 68, "type": "#define", "text": "#define", "parent": 67, "children": [], "start_point": {"row": 51, "column": 0}, "end_point": {"row": 51, "column": 7}}, {"id": 69, "type": "identifier", "text": "XMIT_REQ_CAL", "parent": 67, "children": [], "start_point": {"row": 51, "column": 8}, "end_point": {"row": 51, "column": 20}}, {"id": 70, "type": "preproc_arg", "text": "-4", "parent": 67, "children": [], "start_point": {"row": 51, "column": 32}, "end_point": {"row": 51, "column": 34}}, {"id": 71, "type": "preproc_def", "text": "#define XMIT_RPL_CAL -5\n", "parent": 0, "children": [72, 73, 74], "start_point": {"row": 52, "column": 0}, "end_point": {"row": 53, "column": 0}}, {"id": 72, "type": "#define", "text": "#define", "parent": 71, "children": [], "start_point": {"row": 52, "column": 0}, "end_point": {"row": 52, "column": 7}}, {"id": 73, "type": "identifier", "text": "XMIT_RPL_CAL", "parent": 71, "children": [], "start_point": {"row": 52, "column": 8}, "end_point": {"row": 52, "column": 20}}, {"id": 74, "type": "preproc_arg", "text": "-5", "parent": 71, "children": [], "start_point": {"row": 52, "column": 32}, "end_point": {"row": 52, "column": 34}}, {"id": 75, "type": "struct_specifier", "text": "struct tdma_priv", "parent": 0, "children": [76, 77], "start_point": {"row": 55, "column": 0}, "end_point": {"row": 55, "column": 16}}, {"id": 76, "type": "struct", "text": "struct", "parent": 75, "children": [], "start_point": {"row": 55, "column": 0}, "end_point": {"row": 55, "column": 6}}, {"id": 77, "type": "type_identifier", "text": "tdma_priv", "parent": 75, "children": [], "start_point": {"row": 55, "column": 7}, "end_point": {"row": 55, "column": 16}}, {"id": 78, "type": "struct_specifier", "text": "struct tdma_job {\n struct list_head entry;\n int id;\n unsigned int ref_count;\n}", "parent": 0, "children": [79, 80], "start_point": {"row": 58, "column": 0}, "end_point": {"row": 62, "column": 1}}, {"id": 79, "type": "struct", "text": "struct", "parent": 78, "children": [], "start_point": {"row": 58, "column": 0}, "end_point": {"row": 58, "column": 6}}, {"id": 80, "type": "type_identifier", "text": "tdma_job", "parent": 78, "children": [], "start_point": {"row": 58, "column": 7}, "end_point": {"row": 58, "column": 15}}, {"id": 81, "type": "field_declaration", "text": "struct list_head entry;", "parent": 78, "children": [82, 85], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 38}}, {"id": 82, "type": "struct_specifier", "text": "struct list_head", "parent": 81, "children": [83, 84], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 20}}, {"id": 83, "type": "struct", "text": "struct", "parent": 82, "children": [], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 10}}, {"id": 84, "type": "type_identifier", "text": "list_head", "parent": 82, "children": [], "start_point": {"row": 59, "column": 11}, "end_point": {"row": 59, "column": 20}}, {"id": 85, "type": "field_identifier", "text": "entry", "parent": 81, "children": [], "start_point": {"row": 59, "column": 32}, "end_point": {"row": 59, "column": 37}}, {"id": 86, "type": "field_declaration", "text": "int id;", "parent": 78, "children": [87, 88], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 35}}, {"id": 87, "type": "primitive_type", "text": "int", "parent": 86, "children": [], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 7}}, {"id": 88, "type": "field_identifier", "text": "id", "parent": 86, "children": [], "start_point": {"row": 60, "column": 32}, "end_point": {"row": 60, "column": 34}}, {"id": 89, "type": "field_declaration", "text": "unsigned int ref_count;", "parent": 78, "children": [90, 93], "start_point": {"row": 61, "column": 4}, "end_point": {"row": 61, "column": 42}}, {"id": 90, "type": "sized_type_specifier", "text": "unsigned int", "parent": 89, "children": [91, 92], "start_point": {"row": 61, "column": 4}, "end_point": {"row": 61, "column": 16}}, {"id": 91, "type": "unsigned", "text": "unsigned", "parent": 90, "children": [], "start_point": {"row": 61, "column": 4}, "end_point": {"row": 61, "column": 12}}, {"id": 92, "type": "primitive_type", "text": "int", "parent": 90, "children": [], "start_point": {"row": 61, "column": 13}, "end_point": {"row": 61, "column": 16}}, {"id": 93, "type": "field_identifier", "text": "ref_count", "parent": 89, "children": [], "start_point": {"row": 61, "column": 32}, "end_point": {"row": 61, "column": 41}}, {"id": 94, "type": "preproc_function_def", "text": "#define SLOT_JOB(job) ((struct tdma_slot *)(job))\n", "parent": 0, "children": [95, 96, 97, 99], "start_point": {"row": 65, "column": 0}, "end_point": {"row": 66, "column": 0}}, {"id": 95, "type": "#define", "text": "#define", "parent": 94, "children": [], "start_point": {"row": 65, "column": 0}, "end_point": {"row": 65, "column": 7}}, {"id": 96, "type": "identifier", "text": "SLOT_JOB", "parent": 94, "children": [], "start_point": {"row": 65, "column": 8}, "end_point": {"row": 65, "column": 16}}, {"id": 97, "type": "preproc_params", "text": "(job)", "parent": 94, "children": [98], "start_point": {"row": 65, "column": 16}, "end_point": {"row": 65, "column": 21}}, {"id": 98, "type": "identifier", "text": "job", "parent": 97, "children": [], "start_point": {"row": 65, "column": 17}, "end_point": {"row": 65, "column": 20}}, {"id": 99, "type": "preproc_arg", "text": "((struct tdma_slot *)(job))", "parent": 94, "children": [], "start_point": {"row": 65, "column": 32}, "end_point": {"row": 65, "column": 59}}, {"id": 100, "type": "struct_specifier", "text": "struct tdma_slot {\n struct tdma_job head;\n\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int mtu;\n unsigned int size;\n struct rtskb_prio_queue *queue;\n struct rtskb_prio_queue local_queue;\n}", "parent": 0, "children": [101, 102], "start_point": {"row": 67, "column": 0}, "end_point": {"row": 77, "column": 1}}, {"id": 101, "type": "struct", "text": "struct", "parent": 100, "children": [], "start_point": {"row": 67, "column": 0}, "end_point": {"row": 67, "column": 6}}, {"id": 102, "type": "type_identifier", "text": "tdma_slot", "parent": 100, "children": [], "start_point": {"row": 67, "column": 7}, "end_point": {"row": 67, "column": 16}}, {"id": 103, "type": "field_declaration", "text": "struct tdma_job head;", "parent": 100, "children": [104, 107], "start_point": {"row": 68, "column": 4}, "end_point": {"row": 68, "column": 37}}, {"id": 104, "type": "struct_specifier", "text": "struct tdma_job", "parent": 103, "children": [105, 106], "start_point": {"row": 68, "column": 4}, "end_point": {"row": 68, "column": 19}}, {"id": 105, "type": "struct", "text": "struct", "parent": 104, "children": [], "start_point": {"row": 68, "column": 4}, "end_point": {"row": 68, "column": 10}}, {"id": 106, "type": "type_identifier", "text": "tdma_job", "parent": 104, "children": [], "start_point": {"row": 68, "column": 11}, "end_point": {"row": 68, "column": 19}}, {"id": 107, "type": "field_identifier", "text": "head", "parent": 103, "children": [], "start_point": {"row": 68, "column": 32}, "end_point": {"row": 68, "column": 36}}, {"id": 108, "type": "field_declaration", "text": "u64 offset;", "parent": 100, "children": [109, 110], "start_point": {"row": 70, "column": 4}, "end_point": {"row": 70, "column": 39}}, {"id": 109, "type": "type_identifier", "text": "u64", "parent": 108, "children": [], "start_point": {"row": 70, "column": 4}, "end_point": {"row": 70, "column": 7}}, {"id": 110, "type": "field_identifier", "text": "offset", "parent": 108, "children": [], "start_point": {"row": 70, "column": 32}, "end_point": {"row": 70, "column": 38}}, {"id": 111, "type": "field_declaration", "text": "unsigned int period;", "parent": 100, "children": [112, 115], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 39}}, {"id": 112, "type": "sized_type_specifier", "text": "unsigned int", "parent": 111, "children": [113, 114], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 16}}, {"id": 113, "type": "unsigned", "text": "unsigned", "parent": 112, "children": [], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 12}}, {"id": 114, "type": "primitive_type", "text": "int", "parent": 112, "children": [], "start_point": {"row": 71, "column": 13}, "end_point": {"row": 71, "column": 16}}, {"id": 115, "type": "field_identifier", "text": "period", "parent": 111, "children": [], "start_point": {"row": 71, "column": 32}, "end_point": {"row": 71, "column": 38}}, {"id": 116, "type": "field_declaration", "text": "unsigned int phasing;", "parent": 100, "children": [117, 120], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 40}}, {"id": 117, "type": "sized_type_specifier", "text": "unsigned int", "parent": 116, "children": [118, 119], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 16}}, {"id": 118, "type": "unsigned", "text": "unsigned", "parent": 117, "children": [], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 12}}, {"id": 119, "type": "primitive_type", "text": "int", "parent": 117, "children": [], "start_point": {"row": 72, "column": 13}, "end_point": {"row": 72, "column": 16}}, {"id": 120, "type": "field_identifier", "text": "phasing", "parent": 116, "children": [], "start_point": {"row": 72, "column": 32}, "end_point": {"row": 72, "column": 39}}, {"id": 121, "type": "field_declaration", "text": "unsigned int mtu;", "parent": 100, "children": [122, 125], "start_point": {"row": 73, "column": 4}, "end_point": {"row": 73, "column": 36}}, {"id": 122, "type": "sized_type_specifier", "text": "unsigned int", "parent": 121, "children": [123, 124], "start_point": {"row": 73, "column": 4}, "end_point": {"row": 73, "column": 16}}, {"id": 123, "type": "unsigned", "text": "unsigned", "parent": 122, "children": [], "start_point": {"row": 73, "column": 4}, "end_point": {"row": 73, "column": 12}}, {"id": 124, "type": "primitive_type", "text": "int", "parent": 122, "children": [], "start_point": {"row": 73, "column": 13}, "end_point": {"row": 73, "column": 16}}, {"id": 125, "type": "field_identifier", "text": "mtu", "parent": 121, "children": [], "start_point": {"row": 73, "column": 32}, "end_point": {"row": 73, "column": 35}}, {"id": 126, "type": "field_declaration", "text": "unsigned int size;", "parent": 100, "children": [127, 130], "start_point": {"row": 74, "column": 4}, "end_point": {"row": 74, "column": 37}}, {"id": 127, "type": "sized_type_specifier", "text": "unsigned int", "parent": 126, "children": [128, 129], "start_point": {"row": 74, "column": 4}, "end_point": {"row": 74, "column": 16}}, {"id": 128, "type": "unsigned", "text": "unsigned", "parent": 127, "children": [], "start_point": {"row": 74, "column": 4}, "end_point": {"row": 74, "column": 12}}, {"id": 129, "type": "primitive_type", "text": "int", "parent": 127, "children": [], "start_point": {"row": 74, "column": 13}, "end_point": {"row": 74, "column": 16}}, {"id": 130, "type": "field_identifier", "text": "size", "parent": 126, "children": [], "start_point": {"row": 74, "column": 32}, "end_point": {"row": 74, "column": 36}}, {"id": 131, "type": "field_declaration", "text": "struct rtskb_prio_queue *queue;", "parent": 100, "children": [132, 135], "start_point": {"row": 75, "column": 4}, "end_point": {"row": 75, "column": 39}}, {"id": 132, "type": "struct_specifier", "text": "struct rtskb_prio_queue", "parent": 131, "children": [133, 134], "start_point": {"row": 75, "column": 4}, "end_point": {"row": 75, "column": 27}}, {"id": 133, "type": "struct", "text": "struct", "parent": 132, "children": [], "start_point": {"row": 75, "column": 4}, "end_point": {"row": 75, "column": 10}}, {"id": 134, "type": "type_identifier", "text": "rtskb_prio_queue", "parent": 132, "children": [], "start_point": {"row": 75, "column": 11}, "end_point": {"row": 75, "column": 27}}, {"id": 135, "type": "pointer_declarator", "text": "*queue", "parent": 131, "children": [136, 137], "start_point": {"row": 75, "column": 32}, "end_point": {"row": 75, "column": 38}}, {"id": 136, "type": "*", "text": "*", "parent": 135, "children": [], "start_point": {"row": 75, "column": 32}, "end_point": {"row": 75, "column": 33}}, {"id": 137, "type": "field_identifier", "text": "queue", "parent": 135, "children": [], "start_point": {"row": 75, "column": 33}, "end_point": {"row": 75, "column": 38}}, {"id": 138, "type": "field_declaration", "text": "struct rtskb_prio_queue local_queue;", "parent": 100, "children": [139, 142], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 44}}, {"id": 139, "type": "struct_specifier", "text": "struct rtskb_prio_queue", "parent": 138, "children": [140, 141], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 27}}, {"id": 140, "type": "struct", "text": "struct", "parent": 139, "children": [], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 10}}, {"id": 141, "type": "type_identifier", "text": "rtskb_prio_queue", "parent": 139, "children": [], "start_point": {"row": 76, "column": 11}, "end_point": {"row": 76, "column": 27}}, {"id": 142, "type": "field_identifier", "text": "local_queue", "parent": 138, "children": [], "start_point": {"row": 76, "column": 32}, "end_point": {"row": 76, "column": 43}}, {"id": 143, "type": "preproc_function_def", "text": "#define REQUEST_CAL_JOB(job) ((struct tdma_request_cal *)(job))\n", "parent": 0, "children": [144, 145, 146, 148], "start_point": {"row": 80, "column": 0}, "end_point": {"row": 81, "column": 0}}, {"id": 144, "type": "#define", "text": "#define", "parent": 143, "children": [], "start_point": {"row": 80, "column": 0}, "end_point": {"row": 80, "column": 7}}, {"id": 145, "type": "identifier", "text": "REQUEST_CAL_JOB", "parent": 143, "children": [], "start_point": {"row": 80, "column": 8}, "end_point": {"row": 80, "column": 23}}, {"id": 146, "type": "preproc_params", "text": "(job)", "parent": 143, "children": [147], "start_point": {"row": 80, "column": 23}, "end_point": {"row": 80, "column": 28}}, {"id": 147, "type": "identifier", "text": "job", "parent": 146, "children": [], "start_point": {"row": 80, "column": 24}, "end_point": {"row": 80, "column": 27}}, {"id": 148, "type": "preproc_arg", "text": "((struct tdma_request_cal *)(job))", "parent": 143, "children": [], "start_point": {"row": 80, "column": 32}, "end_point": {"row": 80, "column": 66}}, {"id": 149, "type": "struct_specifier", "text": "struct tdma_request_cal {\n struct tdma_job head;\n\n struct tdma_priv *tdma;\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int cal_rounds;\n u64 *cal_results;\n u64 *result_buffer;\n}", "parent": 0, "children": [150, 151], "start_point": {"row": 82, "column": 0}, "end_point": {"row": 92, "column": 1}}, {"id": 150, "type": "struct", "text": "struct", "parent": 149, "children": [], "start_point": {"row": 82, "column": 0}, "end_point": {"row": 82, "column": 6}}, {"id": 151, "type": "type_identifier", "text": "tdma_request_cal", "parent": 149, "children": [], "start_point": {"row": 82, "column": 7}, "end_point": {"row": 82, "column": 23}}, {"id": 152, "type": "field_declaration", "text": "struct tdma_job head;", "parent": 149, "children": [153, 156], "start_point": {"row": 83, "column": 4}, "end_point": {"row": 83, "column": 37}}, {"id": 153, "type": "struct_specifier", "text": "struct tdma_job", "parent": 152, "children": [154, 155], "start_point": {"row": 83, "column": 4}, "end_point": {"row": 83, "column": 19}}, {"id": 154, "type": "struct", "text": "struct", "parent": 153, "children": [], "start_point": {"row": 83, "column": 4}, "end_point": {"row": 83, "column": 10}}, {"id": 155, "type": "type_identifier", "text": "tdma_job", "parent": 153, "children": [], "start_point": {"row": 83, "column": 11}, "end_point": {"row": 83, "column": 19}}, {"id": 156, "type": "field_identifier", "text": "head", "parent": 152, "children": [], "start_point": {"row": 83, "column": 32}, "end_point": {"row": 83, "column": 36}}, {"id": 157, "type": "field_declaration", "text": "struct tdma_priv *tdma;", "parent": 149, "children": [158, 161], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 38}}, {"id": 158, "type": "struct_specifier", "text": "struct tdma_priv", "parent": 157, "children": [159, 160], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 20}}, {"id": 159, "type": "struct", "text": "struct", "parent": 158, "children": [], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 10}}, {"id": 160, "type": "type_identifier", "text": "tdma_priv", "parent": 158, "children": [], "start_point": {"row": 85, "column": 11}, "end_point": {"row": 85, "column": 20}}, {"id": 161, "type": "pointer_declarator", "text": "*tdma", "parent": 157, "children": [162, 163], "start_point": {"row": 85, "column": 32}, "end_point": {"row": 85, "column": 37}}, {"id": 162, "type": "*", "text": "*", "parent": 161, "children": [], "start_point": {"row": 85, "column": 32}, "end_point": {"row": 85, "column": 33}}, {"id": 163, "type": "field_identifier", "text": "tdma", "parent": 161, "children": [], "start_point": {"row": 85, "column": 33}, "end_point": {"row": 85, "column": 37}}, {"id": 164, "type": "field_declaration", "text": "u64 offset;", "parent": 149, "children": [165, 166], "start_point": {"row": 86, "column": 4}, "end_point": {"row": 86, "column": 39}}, {"id": 165, "type": "type_identifier", "text": "u64", "parent": 164, "children": [], "start_point": {"row": 86, "column": 4}, "end_point": {"row": 86, "column": 7}}, {"id": 166, "type": "field_identifier", "text": "offset", "parent": 164, "children": [], "start_point": {"row": 86, "column": 32}, "end_point": {"row": 86, "column": 38}}, {"id": 167, "type": "field_declaration", "text": "unsigned int period;", "parent": 149, "children": [168, 171], "start_point": {"row": 87, "column": 4}, "end_point": {"row": 87, "column": 39}}, {"id": 168, "type": "sized_type_specifier", "text": "unsigned int", "parent": 167, "children": [169, 170], "start_point": {"row": 87, "column": 4}, "end_point": {"row": 87, "column": 16}}, {"id": 169, "type": "unsigned", "text": "unsigned", "parent": 168, "children": [], "start_point": {"row": 87, "column": 4}, "end_point": {"row": 87, "column": 12}}, {"id": 170, "type": "primitive_type", "text": "int", "parent": 168, "children": [], "start_point": {"row": 87, "column": 13}, "end_point": {"row": 87, "column": 16}}, {"id": 171, "type": "field_identifier", "text": "period", "parent": 167, "children": [], "start_point": {"row": 87, "column": 32}, "end_point": {"row": 87, "column": 38}}, {"id": 172, "type": "field_declaration", "text": "unsigned int phasing;", "parent": 149, "children": [173, 176], "start_point": {"row": 88, "column": 4}, "end_point": {"row": 88, "column": 40}}, {"id": 173, "type": "sized_type_specifier", "text": "unsigned int", "parent": 172, "children": [174, 175], "start_point": {"row": 88, "column": 4}, "end_point": {"row": 88, "column": 16}}, {"id": 174, "type": "unsigned", "text": "unsigned", "parent": 173, "children": [], "start_point": {"row": 88, "column": 4}, "end_point": {"row": 88, "column": 12}}, {"id": 175, "type": "primitive_type", "text": "int", "parent": 173, "children": [], "start_point": {"row": 88, "column": 13}, "end_point": {"row": 88, "column": 16}}, {"id": 176, "type": "field_identifier", "text": "phasing", "parent": 172, "children": [], "start_point": {"row": 88, "column": 32}, "end_point": {"row": 88, "column": 39}}, {"id": 177, "type": "field_declaration", "text": "unsigned int cal_rounds;", "parent": 149, "children": [178, 181], "start_point": {"row": 89, "column": 4}, "end_point": {"row": 89, "column": 43}}, {"id": 178, "type": "sized_type_specifier", "text": "unsigned int", "parent": 177, "children": [179, 180], "start_point": {"row": 89, "column": 4}, "end_point": {"row": 89, "column": 16}}, {"id": 179, "type": "unsigned", "text": "unsigned", "parent": 178, "children": [], "start_point": {"row": 89, "column": 4}, "end_point": {"row": 89, "column": 12}}, {"id": 180, "type": "primitive_type", "text": "int", "parent": 178, "children": [], "start_point": {"row": 89, "column": 13}, "end_point": {"row": 89, "column": 16}}, {"id": 181, "type": "field_identifier", "text": "cal_rounds", "parent": 177, "children": [], "start_point": {"row": 89, "column": 32}, "end_point": {"row": 89, "column": 42}}, {"id": 182, "type": "field_declaration", "text": "u64 *cal_results;", "parent": 149, "children": [183, 184], "start_point": {"row": 90, "column": 4}, "end_point": {"row": 90, "column": 45}}, {"id": 183, "type": "type_identifier", "text": "u64", "parent": 182, "children": [], "start_point": {"row": 90, "column": 4}, "end_point": {"row": 90, "column": 7}}, {"id": 184, "type": "pointer_declarator", "text": "*cal_results", "parent": 182, "children": [185, 186], "start_point": {"row": 90, "column": 32}, "end_point": {"row": 90, "column": 44}}, {"id": 185, "type": "*", "text": "*", "parent": 184, "children": [], "start_point": {"row": 90, "column": 32}, "end_point": {"row": 90, "column": 33}}, {"id": 186, "type": "field_identifier", "text": "cal_results", "parent": 184, "children": [], "start_point": {"row": 90, "column": 33}, "end_point": {"row": 90, "column": 44}}, {"id": 187, "type": "field_declaration", "text": "u64 *result_buffer;", "parent": 149, "children": [188, 189], "start_point": {"row": 91, "column": 4}, "end_point": {"row": 91, "column": 47}}, {"id": 188, "type": "type_identifier", "text": "u64", "parent": 187, "children": [], "start_point": {"row": 91, "column": 4}, "end_point": {"row": 91, "column": 7}}, {"id": 189, "type": "pointer_declarator", "text": "*result_buffer", "parent": 187, "children": [190, 191], "start_point": {"row": 91, "column": 32}, "end_point": {"row": 91, "column": 46}}, {"id": 190, "type": "*", "text": "*", "parent": 189, "children": [], "start_point": {"row": 91, "column": 32}, "end_point": {"row": 91, "column": 33}}, {"id": 191, "type": "field_identifier", "text": "result_buffer", "parent": 189, "children": [], "start_point": {"row": 91, "column": 33}, "end_point": {"row": 91, "column": 46}}, {"id": 192, "type": "preproc_function_def", "text": "#define REPLY_CAL_JOB(job) ((struct tdma_reply_cal *)(job))\n", "parent": 0, "children": [193, 194, 195, 197], "start_point": {"row": 95, "column": 0}, "end_point": {"row": 96, "column": 0}}, {"id": 193, "type": "#define", "text": "#define", "parent": 192, "children": [], "start_point": {"row": 95, "column": 0}, "end_point": {"row": 95, "column": 7}}, {"id": 194, "type": "identifier", "text": "REPLY_CAL_JOB", "parent": 192, "children": [], "start_point": {"row": 95, "column": 8}, "end_point": {"row": 95, "column": 21}}, {"id": 195, "type": "preproc_params", "text": "(job)", "parent": 192, "children": [196], "start_point": {"row": 95, "column": 21}, "end_point": {"row": 95, "column": 26}}, {"id": 196, "type": "identifier", "text": "job", "parent": 195, "children": [], "start_point": {"row": 95, "column": 22}, "end_point": {"row": 95, "column": 25}}, {"id": 197, "type": "preproc_arg", "text": "((struct tdma_reply_cal *)(job))", "parent": 192, "children": [], "start_point": {"row": 95, "column": 32}, "end_point": {"row": 95, "column": 64}}, {"id": 198, "type": "struct_specifier", "text": "struct tdma_reply_cal {\n struct tdma_job head;\n\n u32 reply_cycle;\n u64 reply_offset;\n struct rtskb *reply_rtskb;\n}", "parent": 0, "children": [199, 200], "start_point": {"row": 97, "column": 0}, "end_point": {"row": 103, "column": 1}}, {"id": 199, "type": "struct", "text": "struct", "parent": 198, "children": [], "start_point": {"row": 97, "column": 0}, "end_point": {"row": 97, "column": 6}}, {"id": 200, "type": "type_identifier", "text": "tdma_reply_cal", "parent": 198, "children": [], "start_point": {"row": 97, "column": 7}, "end_point": {"row": 97, "column": 21}}, {"id": 201, "type": "field_declaration", "text": "struct tdma_job head;", "parent": 198, "children": [202, 205], "start_point": {"row": 98, "column": 4}, "end_point": {"row": 98, "column": 37}}, {"id": 202, "type": "struct_specifier", "text": "struct tdma_job", "parent": 201, "children": [203, 204], "start_point": {"row": 98, "column": 4}, "end_point": {"row": 98, "column": 19}}, {"id": 203, "type": "struct", "text": "struct", "parent": 202, "children": [], "start_point": {"row": 98, "column": 4}, "end_point": {"row": 98, "column": 10}}, {"id": 204, "type": "type_identifier", "text": "tdma_job", "parent": 202, "children": [], "start_point": {"row": 98, "column": 11}, "end_point": {"row": 98, "column": 19}}, {"id": 205, "type": "field_identifier", "text": "head", "parent": 201, "children": [], "start_point": {"row": 98, "column": 32}, "end_point": {"row": 98, "column": 36}}, {"id": 206, "type": "field_declaration", "text": "u32 reply_cycle;", "parent": 198, "children": [207, 208], "start_point": {"row": 100, "column": 4}, "end_point": {"row": 100, "column": 44}}, {"id": 207, "type": "type_identifier", "text": "u32", "parent": 206, "children": [], "start_point": {"row": 100, "column": 4}, "end_point": {"row": 100, "column": 7}}, {"id": 208, "type": "field_identifier", "text": "reply_cycle", "parent": 206, "children": [], "start_point": {"row": 100, "column": 32}, "end_point": {"row": 100, "column": 43}}, {"id": 209, "type": "field_declaration", "text": "u64 reply_offset;", "parent": 198, "children": [210, 211], "start_point": {"row": 101, "column": 4}, "end_point": {"row": 101, "column": 45}}, {"id": 210, "type": "type_identifier", "text": "u64", "parent": 209, "children": [], "start_point": {"row": 101, "column": 4}, "end_point": {"row": 101, "column": 7}}, {"id": 211, "type": "field_identifier", "text": "reply_offset", "parent": 209, "children": [], "start_point": {"row": 101, "column": 32}, "end_point": {"row": 101, "column": 44}}, {"id": 212, "type": "field_declaration", "text": "struct rtskb *reply_rtskb;", "parent": 198, "children": [213, 216], "start_point": {"row": 102, "column": 4}, "end_point": {"row": 102, "column": 45}}, {"id": 213, "type": "struct_specifier", "text": "struct rtskb", "parent": 212, "children": [214, 215], "start_point": {"row": 102, "column": 4}, "end_point": {"row": 102, "column": 16}}, {"id": 214, "type": "struct", "text": "struct", "parent": 213, "children": [], "start_point": {"row": 102, "column": 4}, "end_point": {"row": 102, "column": 10}}, {"id": 215, "type": "type_identifier", "text": "rtskb", "parent": 213, "children": [], "start_point": {"row": 102, "column": 11}, "end_point": {"row": 102, "column": 16}}, {"id": 216, "type": "pointer_declarator", "text": "*reply_rtskb", "parent": 212, "children": [217, 218], "start_point": {"row": 102, "column": 32}, "end_point": {"row": 102, "column": 44}}, {"id": 217, "type": "*", "text": "*", "parent": 216, "children": [], "start_point": {"row": 102, "column": 32}, "end_point": {"row": 102, "column": 33}}, {"id": 218, "type": "field_identifier", "text": "reply_rtskb", "parent": 216, "children": [], "start_point": {"row": 102, "column": 33}, "end_point": {"row": 102, "column": 44}}, {"id": 219, "type": "struct_specifier", "text": "struct tdma_priv {\n unsigned int magic;\n struct rtnet_device *rtdev;\n char device_name[32];\n struct rtdm_driver api_driver;\n struct rtdm_device api_device;\n\n#ifdef ALIGN_RTOS_TASK\n __u8 __align[(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)];\n#endif\n rtdm_task_t worker_task;\n rtdm_event_t worker_wakeup;\n rtdm_event_t xmit_event;\n rtdm_event_t sync_event;\n\n unsigned long flags;\n unsigned int cal_rounds;\n u32 current_cycle;\n u64 current_cycle_start;\n u64 master_packet_delay_ns;\n nanosecs_rel_t clock_offset;\n\n struct tdma_job sync_job;\n struct tdma_job *first_job;\n struct tdma_job *current_job;\n volatile unsigned int job_list_revision;\n\n unsigned int max_slot_id;\n struct tdma_slot **slot_table;\n\n struct rt_proc_call *calibration_call;\n unsigned char master_hw_addr[MAX_ADDR_LEN];\n\n rtdm_lock_t lock;\n\n#ifdef CONFIG_XENO_DRIVERS_NET_TDMA_MASTER\n struct rtskb_pool cal_rtskb_pool;\n u64 cycle_period;\n u64 backup_sync_inc;\n#endif\n\n#ifdef CONFIG_XENO_OPT_VFILE\n struct list_head list_entry;\n#endif\n}", "parent": 0, "children": [220, 221], "start_point": {"row": 105, "column": 0}, "end_point": {"row": 154, "column": 1}}, {"id": 220, "type": "struct", "text": "struct", "parent": 219, "children": [], "start_point": {"row": 105, "column": 0}, "end_point": {"row": 105, "column": 6}}, {"id": 221, "type": "type_identifier", "text": "tdma_priv", "parent": 219, "children": [], "start_point": {"row": 105, "column": 7}, "end_point": {"row": 105, "column": 16}}, {"id": 222, "type": "field_declaration", "text": "unsigned int magic;", "parent": 219, "children": [223, 226], "start_point": {"row": 106, "column": 4}, "end_point": {"row": 106, "column": 38}}, {"id": 223, "type": "sized_type_specifier", "text": "unsigned int", "parent": 222, "children": [224, 225], "start_point": {"row": 106, "column": 4}, "end_point": {"row": 106, "column": 16}}, {"id": 224, "type": "unsigned", "text": "unsigned", "parent": 223, "children": [], "start_point": {"row": 106, "column": 4}, "end_point": {"row": 106, "column": 12}}, {"id": 225, "type": "primitive_type", "text": "int", "parent": 223, "children": [], "start_point": {"row": 106, "column": 13}, "end_point": {"row": 106, "column": 16}}, {"id": 226, "type": "field_identifier", "text": "magic", "parent": 222, "children": [], "start_point": {"row": 106, "column": 32}, "end_point": {"row": 106, "column": 37}}, {"id": 227, "type": "field_declaration", "text": "struct rtnet_device *rtdev;", "parent": 219, "children": [228, 231], "start_point": {"row": 107, "column": 4}, "end_point": {"row": 107, "column": 39}}, {"id": 228, "type": "struct_specifier", "text": "struct rtnet_device", "parent": 227, "children": [229, 230], "start_point": {"row": 107, "column": 4}, "end_point": {"row": 107, "column": 23}}, {"id": 229, "type": "struct", "text": "struct", "parent": 228, "children": [], "start_point": {"row": 107, "column": 4}, "end_point": {"row": 107, "column": 10}}, {"id": 230, "type": "type_identifier", "text": "rtnet_device", "parent": 228, "children": [], "start_point": {"row": 107, "column": 11}, "end_point": {"row": 107, "column": 23}}, {"id": 231, "type": "pointer_declarator", "text": "*rtdev", "parent": 227, "children": [232, 233], "start_point": {"row": 107, "column": 32}, "end_point": {"row": 107, "column": 38}}, {"id": 232, "type": "*", "text": "*", "parent": 231, "children": [], "start_point": {"row": 107, "column": 32}, "end_point": {"row": 107, "column": 33}}, {"id": 233, "type": "field_identifier", "text": "rtdev", "parent": 231, "children": [], "start_point": {"row": 107, "column": 33}, "end_point": {"row": 107, "column": 38}}, {"id": 234, "type": "field_declaration", "text": "char device_name[32];", "parent": 219, "children": [235, 236], "start_point": {"row": 108, "column": 4}, "end_point": {"row": 108, "column": 48}}, {"id": 235, "type": "primitive_type", "text": "char", "parent": 234, "children": [], "start_point": {"row": 108, "column": 4}, "end_point": {"row": 108, "column": 8}}, {"id": 236, "type": "array_declarator", "text": "device_name[32]", "parent": 234, "children": [237, 238], "start_point": {"row": 108, "column": 32}, "end_point": {"row": 108, "column": 47}}, {"id": 237, "type": "field_identifier", "text": "device_name", "parent": 236, "children": [], "start_point": {"row": 108, "column": 32}, "end_point": {"row": 108, "column": 43}}, {"id": 238, "type": "number_literal", "text": "32", "parent": 236, "children": [], "start_point": {"row": 108, "column": 44}, "end_point": {"row": 108, "column": 46}}, {"id": 239, "type": "field_declaration", "text": "struct rtdm_driver api_driver;", "parent": 219, "children": [240, 243], "start_point": {"row": 109, "column": 4}, "end_point": {"row": 109, "column": 43}}, {"id": 240, "type": "struct_specifier", "text": "struct rtdm_driver", "parent": 239, "children": [241, 242], "start_point": {"row": 109, "column": 4}, "end_point": {"row": 109, "column": 22}}, {"id": 241, "type": "struct", "text": "struct", "parent": 240, "children": [], "start_point": {"row": 109, "column": 4}, "end_point": {"row": 109, "column": 10}}, {"id": 242, "type": "type_identifier", "text": "rtdm_driver", "parent": 240, "children": [], "start_point": {"row": 109, "column": 11}, "end_point": {"row": 109, "column": 22}}, {"id": 243, "type": "field_identifier", "text": "api_driver", "parent": 239, "children": [], "start_point": {"row": 109, "column": 32}, "end_point": {"row": 109, "column": 42}}, {"id": 244, "type": "field_declaration", "text": "struct rtdm_device api_device;", "parent": 219, "children": [245, 248], "start_point": {"row": 110, "column": 4}, "end_point": {"row": 110, "column": 43}}, {"id": 245, "type": "struct_specifier", "text": "struct rtdm_device", "parent": 244, "children": [246, 247], "start_point": {"row": 110, "column": 4}, "end_point": {"row": 110, "column": 22}}, {"id": 246, "type": "struct", "text": "struct", "parent": 245, "children": [], "start_point": {"row": 110, "column": 4}, "end_point": {"row": 110, "column": 10}}, {"id": 247, "type": "type_identifier", "text": "rtdm_device", "parent": 245, "children": [], "start_point": {"row": 110, "column": 11}, "end_point": {"row": 110, "column": 22}}, {"id": 248, "type": "field_identifier", "text": "api_device", "parent": 244, "children": [], "start_point": {"row": 110, "column": 32}, "end_point": {"row": 110, "column": 42}}, {"id": 249, "type": "preproc_ifdef", "text": "#ifdef ALIGN_RTOS_TASK\n __u8 __align[(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)];\n#endif", "parent": 219, "children": [250, 251, 252, 295], "start_point": {"row": 112, "column": 0}, "end_point": {"row": 119, "column": 6}}, {"id": 250, "type": "#ifdef", "text": "#ifdef", "parent": 249, "children": [], "start_point": {"row": 112, "column": 0}, "end_point": {"row": 112, "column": 6}}, {"id": 251, "type": "identifier", "text": "ALIGN_RTOS_TASK", "parent": 249, "children": [], "start_point": {"row": 112, "column": 7}, "end_point": {"row": 112, "column": 22}}, {"id": 252, "type": "field_declaration", "text": "__u8 __align[(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)];", "parent": 249, "children": [253, 254], "start_point": {"row": 113, "column": 4}, "end_point": {"row": 118, "column": 66}}, {"id": 253, "type": "type_identifier", "text": "__u8", "parent": 252, "children": [], "start_point": {"row": 113, "column": 4}, "end_point": {"row": 113, "column": 8}}, {"id": 254, "type": "array_declarator", "text": "__align[(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)]", "parent": 252, "children": [255, 256], "start_point": {"row": 113, "column": 32}, "end_point": {"row": 118, "column": 65}}, {"id": 255, "type": "field_identifier", "text": "__align", "parent": 254, "children": [], "start_point": {"row": 113, "column": 32}, "end_point": {"row": 113, "column": 39}}, {"id": 256, "type": "binary_expression", "text": "(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)", "parent": 254, "children": [257, 290], "start_point": {"row": 113, "column": 40}, "end_point": {"row": 118, "column": 64}}, {"id": 257, "type": "parenthesized_expression", "text": "(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n )", "parent": 256, "children": [258], "start_point": {"row": 113, "column": 40}, "end_point": {"row": 118, "column": 42}}, {"id": 258, "type": "binary_expression", "text": "ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))", "parent": 257, "children": [259, 260, 261], "start_point": {"row": 113, "column": 41}, "end_point": {"row": 117, "column": 66}}, {"id": 259, "type": "identifier", "text": "ALIGN_RTOS_TASK", "parent": 258, "children": [], "start_point": {"row": 113, "column": 41}, "end_point": {"row": 113, "column": 56}}, {"id": 260, "type": "-", "text": "-", "parent": 258, "children": [], "start_point": {"row": 113, "column": 57}, "end_point": {"row": 113, "column": 58}}, {"id": 261, "type": "parenthesized_expression", "text": "((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))", "parent": 258, "children": [262], "start_point": {"row": 114, "column": 41}, "end_point": {"row": 117, "column": 66}}, {"id": 262, "type": "binary_expression", "text": "(sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1)", "parent": 261, "children": [263, 285], "start_point": {"row": 114, "column": 42}, "end_point": {"row": 117, "column": 65}}, {"id": 263, "type": "parenthesized_expression", "text": "(sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n )", "parent": 262, "children": [264], "start_point": {"row": 114, "column": 42}, "end_point": {"row": 117, "column": 43}}, {"id": 264, "type": "binary_expression", "text": "sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)", "parent": 263, "children": [265, 279, 280], "start_point": {"row": 114, "column": 43}, "end_point": {"row": 116, "column": 69}}, {"id": 265, "type": "binary_expression", "text": "sizeof(unsigned int) +\n sizeof(struct rtnet_device *)", "parent": 264, "children": [266, 271, 272], "start_point": {"row": 114, "column": 43}, "end_point": {"row": 115, "column": 72}}, {"id": 266, "type": "sizeof_expression", "text": "sizeof(unsigned int)", "parent": 265, "children": [267], "start_point": {"row": 114, "column": 43}, "end_point": {"row": 114, "column": 63}}, {"id": 267, "type": "type_descriptor", "text": "unsigned int", "parent": 266, "children": [268], "start_point": {"row": 114, "column": 50}, "end_point": {"row": 114, "column": 62}}, {"id": 268, "type": "sized_type_specifier", "text": "unsigned int", "parent": 267, "children": [269, 270], "start_point": {"row": 114, "column": 50}, "end_point": {"row": 114, "column": 62}}, {"id": 269, "type": "unsigned", "text": "unsigned", "parent": 268, "children": [], "start_point": {"row": 114, "column": 50}, "end_point": {"row": 114, "column": 58}}, {"id": 270, "type": "primitive_type", "text": "int", "parent": 268, "children": [], "start_point": {"row": 114, "column": 59}, "end_point": {"row": 114, "column": 62}}, {"id": 271, "type": "+", "text": "+", "parent": 265, "children": [], "start_point": {"row": 114, "column": 64}, "end_point": {"row": 114, "column": 65}}, {"id": 272, "type": "sizeof_expression", "text": "sizeof(struct rtnet_device *)", "parent": 265, "children": [273], "start_point": {"row": 115, "column": 43}, "end_point": {"row": 115, "column": 72}}, {"id": 273, "type": "type_descriptor", "text": "struct rtnet_device *", "parent": 272, "children": [274, 277], "start_point": {"row": 115, "column": 50}, "end_point": {"row": 115, "column": 71}}, {"id": 274, "type": "struct_specifier", "text": "struct rtnet_device", "parent": 273, "children": [275, 276], "start_point": {"row": 115, "column": 50}, "end_point": {"row": 115, "column": 69}}, {"id": 275, "type": "struct", "text": "struct", "parent": 274, "children": [], "start_point": {"row": 115, "column": 50}, "end_point": {"row": 115, "column": 56}}, {"id": 276, "type": "type_identifier", "text": "rtnet_device", "parent": 274, "children": [], "start_point": {"row": 115, "column": 57}, "end_point": {"row": 115, "column": 69}}, {"id": 277, "type": "abstract_pointer_declarator", "text": "*", "parent": 273, "children": [278], "start_point": {"row": 115, "column": 70}, "end_point": {"row": 115, "column": 71}}, {"id": 278, "type": "*", "text": "*", "parent": 277, "children": [], "start_point": {"row": 115, "column": 70}, "end_point": {"row": 115, "column": 71}}, {"id": 279, "type": "+", "text": "+", "parent": 264, "children": [], "start_point": {"row": 115, "column": 73}, "end_point": {"row": 115, "column": 74}}, {"id": 280, "type": "sizeof_expression", "text": "sizeof(struct rtdm_device)", "parent": 264, "children": [281], "start_point": {"row": 116, "column": 43}, "end_point": {"row": 116, "column": 69}}, {"id": 281, "type": "type_descriptor", "text": "struct rtdm_device", "parent": 280, "children": [282], "start_point": {"row": 116, "column": 50}, "end_point": {"row": 116, "column": 68}}, {"id": 282, "type": "struct_specifier", "text": "struct rtdm_device", "parent": 281, "children": [283, 284], "start_point": {"row": 116, "column": 50}, "end_point": {"row": 116, "column": 68}}, {"id": 283, "type": "struct", "text": "struct", "parent": 282, "children": [], "start_point": {"row": 116, "column": 50}, "end_point": {"row": 116, "column": 56}}, {"id": 284, "type": "type_identifier", "text": "rtdm_device", "parent": 282, "children": [], "start_point": {"row": 116, "column": 57}, "end_point": {"row": 116, "column": 68}}, {"id": 285, "type": "parenthesized_expression", "text": "(ALIGN_RTOS_TASK-1)", "parent": 262, "children": [286], "start_point": {"row": 117, "column": 46}, "end_point": {"row": 117, "column": 65}}, {"id": 286, "type": "binary_expression", "text": "ALIGN_RTOS_TASK-1", "parent": 285, "children": [287, 288, 289], "start_point": {"row": 117, "column": 47}, "end_point": {"row": 117, "column": 64}}, {"id": 287, "type": "identifier", "text": "ALIGN_RTOS_TASK", "parent": 286, "children": [], "start_point": {"row": 117, "column": 47}, "end_point": {"row": 117, "column": 62}}, {"id": 288, "type": "-", "text": "-", "parent": 286, "children": [], "start_point": {"row": 117, "column": 62}, "end_point": {"row": 117, "column": 63}}, {"id": 289, "type": "number_literal", "text": "1", "parent": 286, "children": [], "start_point": {"row": 117, "column": 63}, "end_point": {"row": 117, "column": 64}}, {"id": 290, "type": "parenthesized_expression", "text": "(ALIGN_RTOS_TASK-1)", "parent": 256, "children": [291], "start_point": {"row": 118, "column": 45}, "end_point": {"row": 118, "column": 64}}, {"id": 291, "type": "binary_expression", "text": "ALIGN_RTOS_TASK-1", "parent": 290, "children": [292, 293, 294], "start_point": {"row": 118, "column": 46}, "end_point": {"row": 118, "column": 63}}, {"id": 292, "type": "identifier", "text": "ALIGN_RTOS_TASK", "parent": 291, "children": [], "start_point": {"row": 118, "column": 46}, "end_point": {"row": 118, "column": 61}}, {"id": 293, "type": "-", "text": "-", "parent": 291, "children": [], "start_point": {"row": 118, "column": 61}, "end_point": {"row": 118, "column": 62}}, {"id": 294, "type": "number_literal", "text": "1", "parent": 291, "children": [], "start_point": {"row": 118, "column": 62}, "end_point": {"row": 118, "column": 63}}, {"id": 295, "type": "#endif", "text": "#endif", "parent": 249, "children": [], "start_point": {"row": 119, "column": 0}, "end_point": {"row": 119, "column": 6}}, {"id": 296, "type": "field_declaration", "text": "rtdm_task_t worker_task;", "parent": 219, "children": [297, 298], "start_point": {"row": 120, "column": 4}, "end_point": {"row": 120, "column": 44}}, {"id": 297, "type": "type_identifier", "text": "rtdm_task_t", "parent": 296, "children": [], "start_point": {"row": 120, "column": 4}, "end_point": {"row": 120, "column": 15}}, {"id": 298, "type": "field_identifier", "text": "worker_task", "parent": 296, "children": [], "start_point": {"row": 120, "column": 32}, "end_point": {"row": 120, "column": 43}}, {"id": 299, "type": "field_declaration", "text": "rtdm_event_t worker_wakeup;", "parent": 219, "children": [300, 301], "start_point": {"row": 121, "column": 4}, "end_point": {"row": 121, "column": 46}}, {"id": 300, "type": "type_identifier", "text": "rtdm_event_t", "parent": 299, "children": [], "start_point": {"row": 121, "column": 4}, "end_point": {"row": 121, "column": 16}}, {"id": 301, "type": "field_identifier", "text": "worker_wakeup", "parent": 299, "children": [], "start_point": {"row": 121, "column": 32}, "end_point": {"row": 121, "column": 45}}, {"id": 302, "type": "field_declaration", "text": "rtdm_event_t xmit_event;", "parent": 219, "children": [303, 304], "start_point": {"row": 122, "column": 4}, "end_point": {"row": 122, "column": 43}}, {"id": 303, "type": "type_identifier", "text": "rtdm_event_t", "parent": 302, "children": [], "start_point": {"row": 122, "column": 4}, "end_point": {"row": 122, "column": 16}}, {"id": 304, "type": "field_identifier", "text": "xmit_event", "parent": 302, "children": [], "start_point": {"row": 122, "column": 32}, "end_point": {"row": 122, "column": 42}}, {"id": 305, "type": "field_declaration", "text": "rtdm_event_t sync_event;", "parent": 219, "children": [306, 307], "start_point": {"row": 123, "column": 4}, "end_point": {"row": 123, "column": 43}}, {"id": 306, "type": "type_identifier", "text": "rtdm_event_t", "parent": 305, "children": [], "start_point": {"row": 123, "column": 4}, "end_point": {"row": 123, "column": 16}}, {"id": 307, "type": "field_identifier", "text": "sync_event", "parent": 305, "children": [], "start_point": {"row": 123, "column": 32}, "end_point": {"row": 123, "column": 42}}, {"id": 308, "type": "field_declaration", "text": "unsigned long flags;", "parent": 219, "children": [309, 312], "start_point": {"row": 125, "column": 4}, "end_point": {"row": 125, "column": 38}}, {"id": 309, "type": "sized_type_specifier", "text": "unsigned long", "parent": 308, "children": [310, 311], "start_point": {"row": 125, "column": 4}, "end_point": {"row": 125, "column": 17}}, {"id": 310, "type": "unsigned", "text": "unsigned", "parent": 309, "children": [], "start_point": {"row": 125, "column": 4}, "end_point": {"row": 125, "column": 12}}, {"id": 311, "type": "long", "text": "long", "parent": 309, "children": [], "start_point": {"row": 125, "column": 13}, "end_point": {"row": 125, "column": 17}}, {"id": 312, "type": "field_identifier", "text": "flags", "parent": 308, "children": [], "start_point": {"row": 125, "column": 32}, "end_point": {"row": 125, "column": 37}}, {"id": 313, "type": "field_declaration", "text": "unsigned int cal_rounds;", "parent": 219, "children": [314, 317], "start_point": {"row": 126, "column": 4}, "end_point": {"row": 126, "column": 43}}, {"id": 314, "type": "sized_type_specifier", "text": "unsigned int", "parent": 313, "children": [315, 316], "start_point": {"row": 126, "column": 4}, "end_point": {"row": 126, "column": 16}}, {"id": 315, "type": "unsigned", "text": "unsigned", "parent": 314, "children": [], "start_point": {"row": 126, "column": 4}, "end_point": {"row": 126, "column": 12}}, {"id": 316, "type": "primitive_type", "text": "int", "parent": 314, "children": [], "start_point": {"row": 126, "column": 13}, "end_point": {"row": 126, "column": 16}}, {"id": 317, "type": "field_identifier", "text": "cal_rounds", "parent": 313, "children": [], "start_point": {"row": 126, "column": 32}, "end_point": {"row": 126, "column": 42}}, {"id": 318, "type": "field_declaration", "text": "u32 current_cycle;", "parent": 219, "children": [319, 320], "start_point": {"row": 127, "column": 4}, "end_point": {"row": 127, "column": 46}}, {"id": 319, "type": "type_identifier", "text": "u32", "parent": 318, "children": [], "start_point": {"row": 127, "column": 4}, "end_point": {"row": 127, "column": 7}}, {"id": 320, "type": "field_identifier", "text": "current_cycle", "parent": 318, "children": [], "start_point": {"row": 127, "column": 32}, "end_point": {"row": 127, "column": 45}}, {"id": 321, "type": "field_declaration", "text": "u64 current_cycle_start;", "parent": 219, "children": [322, 323], "start_point": {"row": 128, "column": 4}, "end_point": {"row": 128, "column": 52}}, {"id": 322, "type": "type_identifier", "text": "u64", "parent": 321, "children": [], "start_point": {"row": 128, "column": 4}, "end_point": {"row": 128, "column": 7}}, {"id": 323, "type": "field_identifier", "text": "current_cycle_start", "parent": 321, "children": [], "start_point": {"row": 128, "column": 32}, "end_point": {"row": 128, "column": 51}}, {"id": 324, "type": "field_declaration", "text": "u64 master_packet_delay_ns;", "parent": 219, "children": [325, 326], "start_point": {"row": 129, "column": 4}, "end_point": {"row": 129, "column": 55}}, {"id": 325, "type": "type_identifier", "text": "u64", "parent": 324, "children": [], "start_point": {"row": 129, "column": 4}, "end_point": {"row": 129, "column": 7}}, {"id": 326, "type": "field_identifier", "text": "master_packet_delay_ns", "parent": 324, "children": [], "start_point": {"row": 129, "column": 32}, "end_point": {"row": 129, "column": 54}}, {"id": 327, "type": "field_declaration", "text": "nanosecs_rel_t clock_offset;", "parent": 219, "children": [328, 329], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 45}}, {"id": 328, "type": "type_identifier", "text": "nanosecs_rel_t", "parent": 327, "children": [], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 18}}, {"id": 329, "type": "field_identifier", "text": "clock_offset", "parent": 327, "children": [], "start_point": {"row": 130, "column": 32}, "end_point": {"row": 130, "column": 44}}, {"id": 330, "type": "field_declaration", "text": "struct tdma_job sync_job;", "parent": 219, "children": [331, 334], "start_point": {"row": 132, "column": 4}, "end_point": {"row": 132, "column": 41}}, {"id": 331, "type": "struct_specifier", "text": "struct tdma_job", "parent": 330, "children": [332, 333], "start_point": {"row": 132, "column": 4}, "end_point": {"row": 132, "column": 19}}, {"id": 332, "type": "struct", "text": "struct", "parent": 331, "children": [], "start_point": {"row": 132, "column": 4}, "end_point": {"row": 132, "column": 10}}, {"id": 333, "type": "type_identifier", "text": "tdma_job", "parent": 331, "children": [], "start_point": {"row": 132, "column": 11}, "end_point": {"row": 132, "column": 19}}, {"id": 334, "type": "field_identifier", "text": "sync_job", "parent": 330, "children": [], "start_point": {"row": 132, "column": 32}, "end_point": {"row": 132, "column": 40}}, {"id": 335, "type": "field_declaration", "text": "struct tdma_job *first_job;", "parent": 219, "children": [336, 339], "start_point": {"row": 133, "column": 4}, "end_point": {"row": 133, "column": 43}}, {"id": 336, "type": "struct_specifier", "text": "struct tdma_job", "parent": 335, "children": [337, 338], "start_point": {"row": 133, "column": 4}, "end_point": {"row": 133, "column": 19}}, {"id": 337, "type": "struct", "text": "struct", "parent": 336, "children": [], "start_point": {"row": 133, "column": 4}, "end_point": {"row": 133, "column": 10}}, {"id": 338, "type": "type_identifier", "text": "tdma_job", "parent": 336, "children": [], "start_point": {"row": 133, "column": 11}, "end_point": {"row": 133, "column": 19}}, {"id": 339, "type": "pointer_declarator", "text": "*first_job", "parent": 335, "children": [340, 341], "start_point": {"row": 133, "column": 32}, "end_point": {"row": 133, "column": 42}}, {"id": 340, "type": "*", "text": "*", "parent": 339, "children": [], "start_point": {"row": 133, "column": 32}, "end_point": {"row": 133, "column": 33}}, {"id": 341, "type": "field_identifier", "text": "first_job", "parent": 339, "children": [], "start_point": {"row": 133, "column": 33}, "end_point": {"row": 133, "column": 42}}, {"id": 342, "type": "field_declaration", "text": "struct tdma_job *current_job;", "parent": 219, "children": [343, 346], "start_point": {"row": 134, "column": 4}, "end_point": {"row": 134, "column": 45}}, {"id": 343, "type": "struct_specifier", "text": "struct tdma_job", "parent": 342, "children": [344, 345], "start_point": {"row": 134, "column": 4}, "end_point": {"row": 134, "column": 19}}, {"id": 344, "type": "struct", "text": "struct", "parent": 343, "children": [], "start_point": {"row": 134, "column": 4}, "end_point": {"row": 134, "column": 10}}, {"id": 345, "type": "type_identifier", "text": "tdma_job", "parent": 343, "children": [], "start_point": {"row": 134, "column": 11}, "end_point": {"row": 134, "column": 19}}, {"id": 346, "type": "pointer_declarator", "text": "*current_job", "parent": 342, "children": [347, 348], "start_point": {"row": 134, "column": 32}, "end_point": {"row": 134, "column": 44}}, {"id": 347, "type": "*", "text": "*", "parent": 346, "children": [], "start_point": {"row": 134, "column": 32}, "end_point": {"row": 134, "column": 33}}, {"id": 348, "type": "field_identifier", "text": "current_job", "parent": 346, "children": [], "start_point": {"row": 134, "column": 33}, "end_point": {"row": 134, "column": 44}}, {"id": 349, "type": "field_declaration", "text": "volatile unsigned int job_list_revision;", "parent": 219, "children": [350, 352, 355], "start_point": {"row": 135, "column": 4}, "end_point": {"row": 135, "column": 50}}, {"id": 350, "type": "type_qualifier", "text": "volatile", "parent": 349, "children": [351], "start_point": {"row": 135, "column": 4}, "end_point": {"row": 135, "column": 12}}, {"id": 351, "type": "volatile", "text": "volatile", "parent": 350, "children": [], "start_point": {"row": 135, "column": 4}, "end_point": {"row": 135, "column": 12}}, {"id": 352, "type": "sized_type_specifier", "text": "unsigned int", "parent": 349, "children": [353, 354], "start_point": {"row": 135, "column": 13}, "end_point": {"row": 135, "column": 25}}, {"id": 353, "type": "unsigned", "text": "unsigned", "parent": 352, "children": [], "start_point": {"row": 135, "column": 13}, "end_point": {"row": 135, "column": 21}}, {"id": 354, "type": "primitive_type", "text": "int", "parent": 352, "children": [], "start_point": {"row": 135, "column": 22}, "end_point": {"row": 135, "column": 25}}, {"id": 355, "type": "field_identifier", "text": "job_list_revision", "parent": 349, "children": [], "start_point": {"row": 135, "column": 32}, "end_point": {"row": 135, "column": 49}}, {"id": 356, "type": "field_declaration", "text": "unsigned int max_slot_id;", "parent": 219, "children": [357, 360], "start_point": {"row": 137, "column": 4}, "end_point": {"row": 137, "column": 44}}, {"id": 357, "type": "sized_type_specifier", "text": "unsigned int", "parent": 356, "children": [358, 359], "start_point": {"row": 137, "column": 4}, "end_point": {"row": 137, "column": 16}}, {"id": 358, "type": "unsigned", "text": "unsigned", "parent": 357, "children": [], "start_point": {"row": 137, "column": 4}, "end_point": {"row": 137, "column": 12}}, {"id": 359, "type": "primitive_type", "text": "int", "parent": 357, "children": [], "start_point": {"row": 137, "column": 13}, "end_point": {"row": 137, "column": 16}}, {"id": 360, "type": "field_identifier", "text": "max_slot_id", "parent": 356, "children": [], "start_point": {"row": 137, "column": 32}, "end_point": {"row": 137, "column": 43}}, {"id": 361, "type": "field_declaration", "text": "struct tdma_slot **slot_table;", "parent": 219, "children": [362, 365], "start_point": {"row": 138, "column": 4}, "end_point": {"row": 138, "column": 45}}, {"id": 362, "type": "struct_specifier", "text": "struct tdma_slot", "parent": 361, "children": [363, 364], "start_point": {"row": 138, "column": 4}, "end_point": {"row": 138, "column": 20}}, {"id": 363, "type": "struct", "text": "struct", "parent": 362, "children": [], "start_point": {"row": 138, "column": 4}, "end_point": {"row": 138, "column": 10}}, {"id": 364, "type": "type_identifier", "text": "tdma_slot", "parent": 362, "children": [], "start_point": {"row": 138, "column": 11}, "end_point": {"row": 138, "column": 20}}, {"id": 365, "type": "pointer_declarator", "text": "**slot_table", "parent": 361, "children": [366, 367], "start_point": {"row": 138, "column": 32}, "end_point": {"row": 138, "column": 44}}, {"id": 366, "type": "*", "text": "*", "parent": 365, "children": [], "start_point": {"row": 138, "column": 32}, "end_point": {"row": 138, "column": 33}}, {"id": 367, "type": "pointer_declarator", "text": "*slot_table", "parent": 365, "children": [368, 369], "start_point": {"row": 138, "column": 33}, "end_point": {"row": 138, "column": 44}}, {"id": 368, "type": "*", "text": "*", "parent": 367, "children": [], "start_point": {"row": 138, "column": 33}, "end_point": {"row": 138, "column": 34}}, {"id": 369, "type": "field_identifier", "text": "slot_table", "parent": 367, "children": [], "start_point": {"row": 138, "column": 34}, "end_point": {"row": 138, "column": 44}}, {"id": 370, "type": "field_declaration", "text": "struct rt_proc_call *calibration_call;", "parent": 219, "children": [371, 374], "start_point": {"row": 140, "column": 4}, "end_point": {"row": 140, "column": 50}}, {"id": 371, "type": "struct_specifier", "text": "struct rt_proc_call", "parent": 370, "children": [372, 373], "start_point": {"row": 140, "column": 4}, "end_point": {"row": 140, "column": 23}}, {"id": 372, "type": "struct", "text": "struct", "parent": 371, "children": [], "start_point": {"row": 140, "column": 4}, "end_point": {"row": 140, "column": 10}}, {"id": 373, "type": "type_identifier", "text": "rt_proc_call", "parent": 371, "children": [], "start_point": {"row": 140, "column": 11}, "end_point": {"row": 140, "column": 23}}, {"id": 374, "type": "pointer_declarator", "text": "*calibration_call", "parent": 370, "children": [375, 376], "start_point": {"row": 140, "column": 32}, "end_point": {"row": 140, "column": 49}}, {"id": 375, "type": "*", "text": "*", "parent": 374, "children": [], "start_point": {"row": 140, "column": 32}, "end_point": {"row": 140, "column": 33}}, {"id": 376, "type": "field_identifier", "text": "calibration_call", "parent": 374, "children": [], "start_point": {"row": 140, "column": 33}, "end_point": {"row": 140, "column": 49}}, {"id": 377, "type": "field_declaration", "text": "unsigned char master_hw_addr[MAX_ADDR_LEN];", "parent": 219, "children": [378, 381], "start_point": {"row": 141, "column": 4}, "end_point": {"row": 141, "column": 61}}, {"id": 378, "type": "sized_type_specifier", "text": "unsigned char", "parent": 377, "children": [379, 380], "start_point": {"row": 141, "column": 4}, "end_point": {"row": 141, "column": 17}}, {"id": 379, "type": "unsigned", "text": "unsigned", "parent": 378, "children": [], "start_point": {"row": 141, "column": 4}, "end_point": {"row": 141, "column": 12}}, {"id": 380, "type": "primitive_type", "text": "char", "parent": 378, "children": [], "start_point": {"row": 141, "column": 13}, "end_point": {"row": 141, "column": 17}}, {"id": 381, "type": "array_declarator", "text": "master_hw_addr[MAX_ADDR_LEN]", "parent": 377, "children": [382, 383], "start_point": {"row": 141, "column": 32}, "end_point": {"row": 141, "column": 60}}, {"id": 382, "type": "field_identifier", "text": "master_hw_addr", "parent": 381, "children": [], "start_point": {"row": 141, "column": 32}, "end_point": {"row": 141, "column": 46}}, {"id": 383, "type": "identifier", "text": "MAX_ADDR_LEN", "parent": 381, "children": [], "start_point": {"row": 141, "column": 47}, "end_point": {"row": 141, "column": 59}}, {"id": 384, "type": "field_declaration", "text": "rtdm_lock_t lock;", "parent": 219, "children": [385, 386], "start_point": {"row": 143, "column": 4}, "end_point": {"row": 143, "column": 37}}, {"id": 385, "type": "type_identifier", "text": "rtdm_lock_t", "parent": 384, "children": [], "start_point": {"row": 143, "column": 4}, "end_point": {"row": 143, "column": 15}}, {"id": 386, "type": "field_identifier", "text": "lock", "parent": 384, "children": [], "start_point": {"row": 143, "column": 32}, "end_point": {"row": 143, "column": 36}}, {"id": 387, "type": "preproc_ifdef", "text": "#ifdef CONFIG_XENO_DRIVERS_NET_TDMA_MASTER\n struct rtskb_pool cal_rtskb_pool;\n u64 cycle_period;\n u64 backup_sync_inc;\n#endif", "parent": 219, "children": [388, 389, 390, 395, 398, 401], "start_point": {"row": 145, "column": 0}, "end_point": {"row": 149, "column": 6}}, {"id": 388, "type": "#ifdef", "text": "#ifdef", "parent": 387, "children": [], "start_point": {"row": 145, "column": 0}, "end_point": {"row": 145, "column": 6}}, {"id": 389, "type": "identifier", "text": "CONFIG_XENO_DRIVERS_NET_TDMA_MASTER", "parent": 387, "children": [], "start_point": {"row": 145, "column": 7}, "end_point": {"row": 145, "column": 42}}, {"id": 390, "type": "field_declaration", "text": "struct rtskb_pool cal_rtskb_pool;", "parent": 387, "children": [391, 394], "start_point": {"row": 146, "column": 4}, "end_point": {"row": 146, "column": 47}}, {"id": 391, "type": "struct_specifier", "text": "struct rtskb_pool", "parent": 390, "children": [392, 393], "start_point": {"row": 146, "column": 4}, "end_point": {"row": 146, "column": 21}}, {"id": 392, "type": "struct", "text": "struct", "parent": 391, "children": [], "start_point": {"row": 146, "column": 4}, "end_point": {"row": 146, "column": 10}}, {"id": 393, "type": "type_identifier", "text": "rtskb_pool", "parent": 391, "children": [], "start_point": {"row": 146, "column": 11}, "end_point": {"row": 146, "column": 21}}, {"id": 394, "type": "field_identifier", "text": "cal_rtskb_pool", "parent": 390, "children": [], "start_point": {"row": 146, "column": 32}, "end_point": {"row": 146, "column": 46}}, {"id": 395, "type": "field_declaration", "text": "u64 cycle_period;", "parent": 387, "children": [396, 397], "start_point": {"row": 147, "column": 4}, "end_point": {"row": 147, "column": 45}}, {"id": 396, "type": "type_identifier", "text": "u64", "parent": 395, "children": [], "start_point": {"row": 147, "column": 4}, "end_point": {"row": 147, "column": 7}}, {"id": 397, "type": "field_identifier", "text": "cycle_period", "parent": 395, "children": [], "start_point": {"row": 147, "column": 32}, "end_point": {"row": 147, "column": 44}}, {"id": 398, "type": "field_declaration", "text": "u64 backup_sync_inc;", "parent": 387, "children": [399, 400], "start_point": {"row": 148, "column": 4}, "end_point": {"row": 148, "column": 48}}, {"id": 399, "type": "type_identifier", "text": "u64", "parent": 398, "children": [], "start_point": {"row": 148, "column": 4}, "end_point": {"row": 148, "column": 7}}, {"id": 400, "type": "field_identifier", "text": "backup_sync_inc", "parent": 398, "children": [], "start_point": {"row": 148, "column": 32}, "end_point": {"row": 148, "column": 47}}, {"id": 401, "type": "#endif", "text": "#endif", "parent": 387, "children": [], "start_point": {"row": 149, "column": 0}, "end_point": {"row": 149, "column": 6}}, {"id": 402, "type": "preproc_ifdef", "text": "#ifdef CONFIG_XENO_OPT_VFILE\n struct list_head list_entry;\n#endif", "parent": 219, "children": [403, 404, 405, 410], "start_point": {"row": 151, "column": 0}, "end_point": {"row": 153, "column": 6}}, {"id": 403, "type": "#ifdef", "text": "#ifdef", "parent": 402, "children": [], "start_point": {"row": 151, "column": 0}, "end_point": {"row": 151, "column": 6}}, {"id": 404, "type": "identifier", "text": "CONFIG_XENO_OPT_VFILE", "parent": 402, "children": [], "start_point": {"row": 151, "column": 7}, "end_point": {"row": 151, "column": 28}}, {"id": 405, "type": "field_declaration", "text": "struct list_head list_entry;", "parent": 402, "children": [406, 409], "start_point": {"row": 152, "column": 4}, "end_point": {"row": 152, "column": 43}}, {"id": 406, "type": "struct_specifier", "text": "struct list_head", "parent": 405, "children": [407, 408], "start_point": {"row": 152, "column": 4}, "end_point": {"row": 152, "column": 20}}, {"id": 407, "type": "struct", "text": "struct", "parent": 406, "children": [], "start_point": {"row": 152, "column": 4}, "end_point": {"row": 152, "column": 10}}, {"id": 408, "type": "type_identifier", "text": "list_head", "parent": 406, "children": [], "start_point": {"row": 152, "column": 11}, "end_point": {"row": 152, "column": 20}}, {"id": 409, "type": "field_identifier", "text": "list_entry", "parent": 405, "children": [], "start_point": {"row": 152, "column": 32}, "end_point": {"row": 152, "column": 42}}, {"id": 410, "type": "#endif", "text": "#endif", "parent": 402, "children": [], "start_point": {"row": 153, "column": 0}, "end_point": {"row": 153, "column": 6}}, {"id": 411, "type": "declaration", "text": "extern struct rtmac_disc tdma_disc;", "parent": 0, "children": [412, 414, 417], "start_point": {"row": 157, "column": 0}, "end_point": {"row": 157, "column": 42}}, {"id": 412, "type": "storage_class_specifier", "text": "extern", "parent": 411, "children": [413], "start_point": {"row": 157, "column": 0}, "end_point": {"row": 157, "column": 6}}, {"id": 413, "type": "extern", "text": "extern", "parent": 412, "children": [], "start_point": {"row": 157, "column": 0}, "end_point": {"row": 157, "column": 6}}, {"id": 414, "type": "struct_specifier", "text": "struct rtmac_disc", "parent": 411, "children": [415, 416], "start_point": {"row": 157, "column": 7}, "end_point": {"row": 157, "column": 24}}, {"id": 415, "type": "struct", "text": "struct", "parent": 414, "children": [], "start_point": {"row": 157, "column": 7}, "end_point": {"row": 157, "column": 13}}, {"id": 416, "type": "type_identifier", "text": "rtmac_disc", "parent": 414, "children": [], "start_point": {"row": 157, "column": 14}, "end_point": {"row": 157, "column": 24}}, {"id": 417, "type": "identifier", "text": "tdma_disc", "parent": 411, "children": [], "start_point": {"row": 157, "column": 32}, "end_point": {"row": 157, "column": 41}}, {"id": 418, "type": "preproc_function_def", "text": "#define print_jobs() do { \\\n struct tdma_job *entry; \\\n rtdm_printk(\"%s:%d - \", __FUNCTION__, __LINE__); \\\n list_for_each_entry(entry, &tdma->first_job->entry, entry) \\\n rtdm_printk(\"%d \", entry->id); \\\n rtdm_printk(\"\\n\"); \\\n} while (0)\n", "parent": 0, "children": [419, 420, 421, 422], "start_point": {"row": 159, "column": 0}, "end_point": {"row": 166, "column": 0}}, {"id": 419, "type": "#define", "text": "#define", "parent": 418, "children": [], "start_point": {"row": 159, "column": 0}, "end_point": {"row": 159, "column": 7}}, {"id": 420, "type": "identifier", "text": "print_jobs", "parent": 418, "children": [], "start_point": {"row": 159, "column": 8}, "end_point": {"row": 159, "column": 18}}, {"id": 421, "type": "preproc_params", "text": "()", "parent": 418, "children": [], "start_point": {"row": 159, "column": 18}, "end_point": {"row": 159, "column": 20}}, {"id": 422, "type": "preproc_arg", "text": "do { \\\n struct tdma_job *entry; \\\n rtdm_printk(\"%s:%d - \", __FUNCTION__, __LINE__); \\\n list_for_each_entry(entry, &tdma->first_job->entry, entry) \\\n rtdm_printk(\"%d \", entry->id); \\\n rtdm_printk(\"\\n\"); \\\n} while (0)", "parent": 418, "children": [], "start_point": {"row": 159, "column": 32}, "end_point": {"row": 165, "column": 11}}, {"id": 423, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 167, "column": 0}, "end_point": {"row": 167, "column": 6}}]}, "node_categories": {"declarations": {"functions": [94, 143, 192, 418], "variables": [81, 86, 89, 103, 108, 111, 116, 121, 126, 131, 138, 152, 157, 164, 167, 172, 177, 182, 187, 201, 206, 209, 212, 222, 227, 234, 239, 244, 252, 296, 299, 302, 305, 308, 313, 318, 321, 324, 327, 330, 335, 342, 349, 356, 361, 370, 377, 384, 390, 395, 398, 405, 411], "classes": [75, 76, 78, 79, 82, 83, 100, 101, 104, 105, 132, 133, 139, 140, 149, 150, 153, 154, 158, 159, 198, 199, 202, 203, 213, 214, 219, 220, 228, 229, 240, 241, 245, 246, 274, 275, 282, 283, 331, 332, 336, 337, 343, 344, 362, 363, 371, 372, 391, 392, 406, 407, 412, 414, 415], "imports": [6, 7, 9, 10, 12, 13], "modules": [], "enums": []}, "statements": {"expressions": [256, 257, 258, 261, 262, 263, 264, 265, 266, 272, 280, 285, 286, 290, 291], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 17, 21, 25, 29, 33, 37, 41, 45, 49, 53, 57, 61, 65, 69, 73, 77, 80, 84, 85, 88, 90, 93, 96, 98, 102, 106, 107, 109, 110, 112, 115, 117, 120, 122, 125, 127, 130, 134, 137, 141, 142, 145, 147, 151, 155, 156, 160, 163, 165, 166, 168, 171, 173, 176, 178, 181, 183, 186, 188, 191, 194, 196, 200, 204, 205, 207, 208, 210, 211, 215, 218, 221, 223, 226, 230, 233, 237, 242, 243, 247, 248, 249, 250, 251, 253, 255, 259, 268, 276, 284, 287, 292, 295, 297, 298, 300, 301, 303, 304, 306, 307, 309, 312, 314, 317, 319, 320, 322, 323, 325, 326, 328, 329, 333, 334, 338, 341, 345, 348, 350, 352, 355, 357, 360, 364, 369, 373, 376, 378, 382, 383, 385, 386, 387, 388, 389, 393, 394, 396, 397, 399, 400, 401, 402, 403, 404, 408, 409, 410, 416, 417, 420, 423], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [8, 11, 14, 238, 289, 294], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 94, "universal_type": "function", "name": "unknown", "text_snippet": "#define SLOT_JOB(job) ((struct tdma_slot *)(job))\n"}, {"node_id": 143, "universal_type": "function", "name": "unknown", "text_snippet": "#define REQUEST_CAL_JOB(job) ((struct tdma_request_cal *)(job))\n"}, {"node_id": 192, "universal_type": "function", "name": "unknown", "text_snippet": "#define REPLY_CAL_JOB(job) ((struct tdma_reply_cal *)(job))\n"}, {"node_id": 418, "universal_type": "function", "name": "tdma_job", "text_snippet": "#define print_jobs() do { \\\n struct tdma_job *entry; \\\n rtdm_printk(\"%s:%d - \", __F"}], "class_declarations": [{"node_id": 75, "universal_type": "class", "name": "tdma_priv", "text_snippet": "struct tdma_priv"}, {"node_id": 76, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 78, "universal_type": "class", "name": "tdma_job", "text_snippet": "struct tdma_job {\n struct list_head entry;\n int id;\n uns"}, {"node_id": 79, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 82, "universal_type": "class", "name": "list_head", "text_snippet": "struct list_head"}, {"node_id": 83, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 100, "universal_type": "class", "name": "tdma_slot", "text_snippet": "struct tdma_slot {\n struct tdma_job head;\n\n u64 offset;\n "}, {"node_id": 101, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 104, "universal_type": "class", "name": "tdma_job", "text_snippet": "struct tdma_job"}, {"node_id": 105, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 132, "universal_type": "class", "name": "rtskb_prio_queue", "text_snippet": "struct rtskb_prio_queue"}, {"node_id": 133, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 139, "universal_type": "class", "name": "rtskb_prio_queue", "text_snippet": "struct rtskb_prio_queue"}, {"node_id": 140, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 149, "universal_type": "class", "name": "tdma_request_cal", "text_snippet": "struct tdma_request_cal {\n struct tdma_job head;\n\n struct tdma_priv *td"}, {"node_id": 150, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 153, "universal_type": "class", "name": "tdma_job", "text_snippet": "struct tdma_job"}, {"node_id": 154, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 158, "universal_type": "class", "name": "tdma_priv", "text_snippet": "struct tdma_priv"}, {"node_id": 159, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 198, "universal_type": "class", "name": "tdma_reply_cal", "text_snippet": "struct tdma_reply_cal {\n struct tdma_job head;\n\n u32 reply"}, {"node_id": 199, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 202, "universal_type": "class", "name": "tdma_job", "text_snippet": "struct tdma_job"}, {"node_id": 203, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 213, "universal_type": "class", "name": "rtskb", "text_snippet": "struct rtskb"}, {"node_id": 214, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 219, "universal_type": "class", "name": "tdma_priv", "text_snippet": "struct tdma_priv {\n unsigned int magic;\n struct rtnet_device *rtdev;\n "}, {"node_id": 220, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 228, "universal_type": "class", "name": "rtnet_device", "text_snippet": "struct rtnet_device"}, {"node_id": 229, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 240, "universal_type": "class", "name": "rtdm_driver", "text_snippet": "struct rtdm_driver"}, {"node_id": 241, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 245, "universal_type": "class", "name": "rtdm_device", "text_snippet": "struct rtdm_device"}, {"node_id": 246, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 274, "universal_type": "class", "name": "rtnet_device", "text_snippet": "struct rtnet_device"}, {"node_id": 275, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 282, "universal_type": "class", "name": "rtdm_device", "text_snippet": "struct rtdm_device"}, {"node_id": 283, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 331, "universal_type": "class", "name": "tdma_job", "text_snippet": "struct tdma_job"}, {"node_id": 332, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 336, "universal_type": "class", "name": "tdma_job", "text_snippet": "struct tdma_job"}, {"node_id": 337, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 343, "universal_type": "class", "name": "tdma_job", "text_snippet": "struct tdma_job"}, {"node_id": 344, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 362, "universal_type": "class", "name": "tdma_slot", "text_snippet": "struct tdma_slot"}, {"node_id": 363, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 371, "universal_type": "class", "name": "rt_proc_call", "text_snippet": "struct rt_proc_call"}, {"node_id": 372, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 391, "universal_type": "class", "name": "rtskb_pool", "text_snippet": "struct rtskb_pool"}, {"node_id": 392, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 406, "universal_type": "class", "name": "list_head", "text_snippet": "struct list_head"}, {"node_id": 407, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 412, "universal_type": "class", "name": "unknown", "text_snippet": "extern"}, {"node_id": 414, "universal_type": "class", "name": "rtmac_disc", "text_snippet": "struct rtmac_disc"}, {"node_id": 415, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": [{"node_id": 6, "text": "#include <rtdm/driver.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <rtnet_rtpc.h>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include <rtmac/rtmac_disc.h>\n"}, {"node_id": 13, "text": "#include"}]}, "original_source_code": "/***\n *\n * include/rtmac/tdma/tdma.h\n *\n * RTmac - real-time networking media access control subsystem\n * Copyright (C) 2002 <NAME> <<EMAIL>>,\n * 2003-2005 <NAME> <<EMAIL>>\n *\n * This program is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.\n *\n */\n\n#ifndef __TDMA_H_\n#define __TDMA_H_\n\n#include <rtdm/driver.h>\n\n#include <rtnet_rtpc.h>\n#include <rtmac/rtmac_disc.h>\n\n\n#define RTMAC_TYPE_TDMA 0x0001\n\n#define TDMA_MAGIC 0x3A0D4D0A\n\n#define TDMA_FLAG_CALIBRATED 1\n#define TDMA_FLAG_RECEIVED_SYNC 2\n#define TDMA_FLAG_MASTER 3 /* also set for backup masters */\n#define TDMA_FLAG_BACKUP_MASTER 4\n#define TDMA_FLAG_ATTACHED 5\n#define TDMA_FLAG_BACKUP_ACTIVE 6\n\n#define DEFAULT_SLOT 0\n#define DEFAULT_NRT_SLOT 1\n\n/* job IDs */\n#define WAIT_ON_SYNC -1\n#define XMIT_SYNC -2\n#define BACKUP_SYNC -3\n#define XMIT_REQ_CAL -4\n#define XMIT_RPL_CAL -5\n\n\nstruct tdma_priv;\n\n\nstruct tdma_job {\n struct list_head entry;\n int id;\n unsigned int ref_count;\n};\n\n\n#define SLOT_JOB(job) ((struct tdma_slot *)(job))\n\nstruct tdma_slot {\n struct tdma_job head;\n\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int mtu;\n unsigned int size;\n struct rtskb_prio_queue *queue;\n struct rtskb_prio_queue local_queue;\n};\n\n\n#define REQUEST_CAL_JOB(job) ((struct tdma_request_cal *)(job))\n\nstruct tdma_request_cal {\n struct tdma_job head;\n\n struct tdma_priv *tdma;\n u64 offset;\n unsigned int period;\n unsigned int phasing;\n unsigned int cal_rounds;\n u64 *cal_results;\n u64 *result_buffer;\n};\n\n\n#define REPLY_CAL_JOB(job) ((struct tdma_reply_cal *)(job))\n\nstruct tdma_reply_cal {\n struct tdma_job head;\n\n u32 reply_cycle;\n u64 reply_offset;\n struct rtskb *reply_rtskb;\n};\n\nstruct tdma_priv {\n unsigned int magic;\n struct rtnet_device *rtdev;\n char device_name[32];\n struct rtdm_driver api_driver;\n struct rtdm_device api_device;\n\n#ifdef ALIGN_RTOS_TASK\n __u8 __align[(ALIGN_RTOS_TASK -\n ((sizeof(unsigned int) +\n sizeof(struct rtnet_device *) +\n sizeof(struct rtdm_device)\n ) & (ALIGN_RTOS_TASK-1))\n ) & (ALIGN_RTOS_TASK-1)];\n#endif\n rtdm_task_t worker_task;\n rtdm_event_t worker_wakeup;\n rtdm_event_t xmit_event;\n rtdm_event_t sync_event;\n\n unsigned long flags;\n unsigned int cal_rounds;\n u32 current_cycle;\n u64 current_cycle_start;\n u64 master_packet_delay_ns;\n nanosecs_rel_t clock_offset;\n\n struct tdma_job sync_job;\n struct tdma_job *first_job;\n struct tdma_job *current_job;\n volatile unsigned int job_list_revision;\n\n unsigned int max_slot_id;\n struct tdma_slot **slot_table;\n\n struct rt_proc_call *calibration_call;\n unsigned char master_hw_addr[MAX_ADDR_LEN];\n\n rtdm_lock_t lock;\n\n#ifdef CONFIG_XENO_DRIVERS_NET_TDMA_MASTER\n struct rtskb_pool cal_rtskb_pool;\n u64 cycle_period;\n u64 backup_sync_inc;\n#endif\n\n#ifdef CONFIG_XENO_OPT_VFILE\n struct list_head list_entry;\n#endif\n};\n\n\nextern struct rtmac_disc tdma_disc;\n\n#define print_jobs() do { \\\n struct tdma_job *entry; \\\n rtdm_printk(\"%s:%d - \", __FUNCTION__, __LINE__); \\\n list_for_each_entry(entry, &tdma->first_job->entry, entry) \\\n rtdm_printk(\"%d \", entry->id); \\\n rtdm_printk(\"\\n\"); \\\n} while (0)\n\n#endif /* __TDMA_H_ */\n"}
80,528
c
#include <string.h> #include <dlfcn.h> int main() { void *h; /* Try loading anything, we don't care if it works */ h = dlopen("__nothing_rdkafka.so", RTLD_NOW | RTLD_LOCAL); if (h) dlclose(h); return 0; }
25.1
10
(translation_unit) "#include <string.h>\n#include <dlfcn.h>\n\nint main() {\n void *h;\n /* Try loading anything, we don't care if it works */\n h = dlopen("__nothing_rdkafka.so", RTLD_NOW | RTLD_LOCAL);\n if (h)\n dlclose(h);\n return 0;\n}\n" (preproc_include) "#include <string.h>\n" (#include) "#include" (system_lib_string) "<string.h>" (preproc_include) "#include <dlfcn.h>\n" (#include) "#include" (system_lib_string) "<dlfcn.h>" (function_definition) "int main() {\n void *h;\n /* Try loading anything, we don't care if it works */\n h = dlopen("__nothing_rdkafka.so", RTLD_NOW | RTLD_LOCAL);\n if (h)\n dlclose(h);\n return 0;\n}" (primitive_type) "int" (function_declarator) "main()" (identifier) "main" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n void *h;\n /* Try loading anything, we don't care if it works */\n h = dlopen("__nothing_rdkafka.so", RTLD_NOW | RTLD_LOCAL);\n if (h)\n dlclose(h);\n return 0;\n}" ({) "{" (declaration) "void *h;" (primitive_type) "void" (pointer_declarator) "*h" (*) "*" (identifier) "h" (;) ";" (comment) "/* Try loading anything, we don't care if it works */" (expression_statement) "h = dlopen("__nothing_rdkafka.so", RTLD_NOW | RTLD_LOCAL);" (assignment_expression) "h = dlopen("__nothing_rdkafka.so", RTLD_NOW | RTLD_LOCAL)" (identifier) "h" (=) "=" (call_expression) "dlopen("__nothing_rdkafka.so", RTLD_NOW | RTLD_LOCAL)" (identifier) "dlopen" (argument_list) "("__nothing_rdkafka.so", RTLD_NOW | RTLD_LOCAL)" (() "(" (string_literal) ""__nothing_rdkafka.so"" (") """ (string_content) "__nothing_rdkafka.so" (") """ (,) "," (binary_expression) "RTLD_NOW | RTLD_LOCAL" (identifier) "RTLD_NOW" (|) "|" (identifier) "RTLD_LOCAL" ()) ")" (;) ";" (if_statement) "if (h)\n dlclose(h);" (if) "if" (parenthesized_expression) "(h)" (() "(" (identifier) "h" ()) ")" (expression_statement) "dlclose(h);" (call_expression) "dlclose(h)" (identifier) "dlclose" (argument_list) "(h)" (() "(" (identifier) "h" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}"
61
0
{"language": "c", "success": true, "metadata": {"lines": 10, "avg_line_length": 25.1, "nodes": 35, "errors": 0, "source_hash": "a41aae9ba1e2c838af227e0d69b4cb109d6ba786cf4410b6801126cc89e5059c", "categorized_nodes": 27}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <string.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<string.h>", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 19}}, {"id": 3, "type": "preproc_include", "text": "#include <dlfcn.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<dlfcn.h>", "parent": 3, "children": [], "start_point": {"row": 1, "column": 9}, "end_point": {"row": 1, "column": 18}}, {"id": 6, "type": "function_definition", "text": "int main() {\n void *h;\n /* Try loading anything, we don't care if it works */\n h = dlopen(\"__nothing_rdkafka.so\", RTLD_NOW | RTLD_LOCAL);\n if (h)\n dlclose(h);\n return 0;\n}", "parent": null, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 10, "column": 1}}, {"id": 7, "type": "primitive_type", "text": "int", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 3}}, {"id": 8, "type": "function_declarator", "text": "main()", "parent": 6, "children": [9, 10], "start_point": {"row": 3, "column": 4}, "end_point": {"row": 3, "column": 10}}, {"id": 9, "type": "identifier", "text": "main", "parent": 8, "children": [], "start_point": {"row": 3, "column": 4}, "end_point": {"row": 3, "column": 8}}, {"id": 10, "type": "parameter_list", "text": "()", "parent": 8, "children": [], "start_point": {"row": 3, "column": 8}, "end_point": {"row": 3, "column": 10}}, {"id": 11, "type": "declaration", "text": "void *h;", "parent": 6, "children": [12, 13], "start_point": {"row": 4, "column": 8}, "end_point": {"row": 4, "column": 16}}, {"id": 12, "type": "primitive_type", "text": "void", "parent": 11, "children": [], "start_point": {"row": 4, "column": 8}, "end_point": {"row": 4, "column": 12}}, {"id": 13, "type": "pointer_declarator", "text": "*h", "parent": 11, "children": [14, 15], "start_point": {"row": 4, "column": 13}, "end_point": {"row": 4, "column": 15}}, {"id": 14, "type": "*", "text": "*", "parent": 13, "children": [], "start_point": {"row": 4, "column": 13}, "end_point": {"row": 4, "column": 14}}, {"id": 15, "type": "identifier", "text": "h", "parent": 13, "children": [], "start_point": {"row": 4, "column": 14}, "end_point": {"row": 4, "column": 15}}, {"id": 16, "type": "assignment_expression", "text": "h = dlopen(\"__nothing_rdkafka.so\", RTLD_NOW | RTLD_LOCAL)", "parent": 6, "children": [17, 18, 19], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 65}}, {"id": 17, "type": "identifier", "text": "h", "parent": 16, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 9}}, {"id": 18, "type": "=", "text": "=", "parent": 16, "children": [], "start_point": {"row": 6, "column": 10}, "end_point": {"row": 6, "column": 11}}, {"id": 19, "type": "call_expression", "text": "dlopen(\"__nothing_rdkafka.so\", RTLD_NOW | RTLD_LOCAL)", "parent": 16, "children": [20, 21], "start_point": {"row": 6, "column": 12}, "end_point": {"row": 6, "column": 65}}, {"id": 20, "type": "identifier", "text": "dlopen", "parent": 19, "children": [], "start_point": {"row": 6, "column": 12}, "end_point": {"row": 6, "column": 18}}, {"id": 21, "type": "argument_list", "text": "(\"__nothing_rdkafka.so\", RTLD_NOW | RTLD_LOCAL)", "parent": 19, "children": [22, 23], "start_point": {"row": 6, "column": 18}, "end_point": {"row": 6, "column": 65}}, {"id": 22, "type": "string_literal", "text": "\"__nothing_rdkafka.so\"", "parent": 21, "children": [], "start_point": {"row": 6, "column": 19}, "end_point": {"row": 6, "column": 41}}, {"id": 23, "type": "binary_expression", "text": "RTLD_NOW | RTLD_LOCAL", "parent": 21, "children": [24, 25], "start_point": {"row": 6, "column": 43}, "end_point": {"row": 6, "column": 64}}, {"id": 24, "type": "identifier", "text": "RTLD_NOW", "parent": 23, "children": [], "start_point": {"row": 6, "column": 43}, "end_point": {"row": 6, "column": 51}}, {"id": 25, "type": "identifier", "text": "RTLD_LOCAL", "parent": 23, "children": [], "start_point": {"row": 6, "column": 54}, "end_point": {"row": 6, "column": 64}}, {"id": 26, "type": "if_statement", "text": "if (h)\n dlclose(h);", "parent": 6, "children": [27], "start_point": {"row": 7, "column": 8}, "end_point": {"row": 8, "column": 27}}, {"id": 27, "type": "parenthesized_expression", "text": "(h)", "parent": 26, "children": [28], "start_point": {"row": 7, "column": 11}, "end_point": {"row": 7, "column": 14}}, {"id": 28, "type": "identifier", "text": "h", "parent": 27, "children": [], "start_point": {"row": 7, "column": 12}, "end_point": {"row": 7, "column": 13}}, {"id": 29, "type": "call_expression", "text": "dlclose(h)", "parent": 26, "children": [30, 31], "start_point": {"row": 8, "column": 16}, "end_point": {"row": 8, "column": 26}}, {"id": 30, "type": "identifier", "text": "dlclose", "parent": 29, "children": [], "start_point": {"row": 8, "column": 16}, "end_point": {"row": 8, "column": 23}}, {"id": 31, "type": "argument_list", "text": "(h)", "parent": 29, "children": [32], "start_point": {"row": 8, "column": 23}, "end_point": {"row": 8, "column": 26}}, {"id": 32, "type": "identifier", "text": "h", "parent": 31, "children": [], "start_point": {"row": 8, "column": 24}, "end_point": {"row": 8, "column": 25}}, {"id": 33, "type": "return_statement", "text": "return 0;", "parent": 6, "children": [34], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 17}}, {"id": 34, "type": "number_literal", "text": "0", "parent": 33, "children": [], "start_point": {"row": 9, "column": 15}, "end_point": {"row": 9, "column": 16}}]}, "node_categories": {"declarations": {"functions": [6, 8], "variables": [11], "classes": [], "imports": [0, 1, 3, 4], "modules": [], "enums": []}, "statements": {"expressions": [19, 23, 27, 29], "assignments": [16], "loops": [], "conditionals": [9, 15, 17, 20, 24, 25, 26, 28, 30, 32], "returns": [33], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 22, 34], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 6, "universal_type": "function", "name": "main", "text_snippet": "int main() {\n void *h;\n /* Try loading anything, we don't care if it works */\n "}, {"node_id": 8, "universal_type": "function", "name": "unknown", "text_snippet": "main()"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <string.h>\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <dlfcn.h>\n"}, {"node_id": 4, "text": "#include"}]}, "original_source_code": "#include <string.h>\n#include <dlfcn.h>\n\nint main() {\n void *h;\n /* Try loading anything, we don't care if it works */\n h = dlopen(\"__nothing_rdkafka.so\", RTLD_NOW | RTLD_LOCAL);\n if (h)\n dlclose(h);\n return 0;\n}\n"}
80,529
c
#ifndef _LIBC_STRING_STRCHR_H_ #define _LIBC_STRING_STRCHR_H_ extern char *strchr(const char *str, int c); #endif
27.5
4
(translation_unit) "#ifndef _LIBC_STRING_STRCHR_H_\n#define _LIBC_STRING_STRCHR_H_\n\nextern char *strchr(const char *str, int c);\n\n#endif" (preproc_ifdef) "#ifndef _LIBC_STRING_STRCHR_H_\n#define _LIBC_STRING_STRCHR_H_\n\nextern char *strchr(const char *str, int c);\n\n#endif" (#ifndef) "#ifndef" (identifier) "_LIBC_STRING_STRCHR_H_" (preproc_def) "#define _LIBC_STRING_STRCHR_H_\n" (#define) "#define" (identifier) "_LIBC_STRING_STRCHR_H_" (declaration) "extern char *strchr(const char *str, int c);" (storage_class_specifier) "extern" (extern) "extern" (primitive_type) "char" (pointer_declarator) "*strchr(const char *str, int c)" (*) "*" (function_declarator) "strchr(const char *str, int c)" (identifier) "strchr" (parameter_list) "(const char *str, int c)" (() "(" (parameter_declaration) "const char *str" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "*str" (*) "*" (identifier) "str" (,) "," (parameter_declaration) "int c" (primitive_type) "int" (identifier) "c" ()) ")" (;) ";" (#endif) "#endif"
31
0
{"language": "c", "success": true, "metadata": {"lines": 4, "avg_line_length": 27.5, "nodes": 24, "errors": 0, "source_hash": "eb028497428a10eb34883998fb26f96bb604bb9ceced74336ca991dde79086be", "categorized_nodes": 13}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef _LIBC_STRING_STRCHR_H_\n#define _LIBC_STRING_STRCHR_H_\n\nextern char *strchr(const char *str, int c);\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 23], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 5, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "identifier", "text": "_LIBC_STRING_STRCHR_H_", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 30}}, {"id": 3, "type": "preproc_def", "text": "#define _LIBC_STRING_STRCHR_H_\n", "parent": 0, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 5, "type": "identifier", "text": "_LIBC_STRING_STRCHR_H_", "parent": 3, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 30}}, {"id": 6, "type": "declaration", "text": "extern char *strchr(const char *str, int c);", "parent": 0, "children": [7, 9, 10], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 44}}, {"id": 7, "type": "storage_class_specifier", "text": "extern", "parent": 6, "children": [8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 6}}, {"id": 8, "type": "extern", "text": "extern", "parent": 7, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 6}}, {"id": 9, "type": "primitive_type", "text": "char", "parent": 6, "children": [], "start_point": {"row": 3, "column": 7}, "end_point": {"row": 3, "column": 11}}, {"id": 10, "type": "pointer_declarator", "text": "*strchr(const char *str, int c)", "parent": 6, "children": [11, 12], "start_point": {"row": 3, "column": 12}, "end_point": {"row": 3, "column": 43}}, {"id": 11, "type": "*", "text": "*", "parent": 10, "children": [], "start_point": {"row": 3, "column": 12}, "end_point": {"row": 3, "column": 13}}, {"id": 12, "type": "function_declarator", "text": "strchr(const char *str, int c)", "parent": 10, "children": [13, 14], "start_point": {"row": 3, "column": 13}, "end_point": {"row": 3, "column": 43}}, {"id": 13, "type": "identifier", "text": "strchr", "parent": 12, "children": [], "start_point": {"row": 3, "column": 13}, "end_point": {"row": 3, "column": 19}}, {"id": 14, "type": "parameter_list", "text": "(const char *str, int c)", "parent": 12, "children": [15, 20], "start_point": {"row": 3, "column": 19}, "end_point": {"row": 3, "column": 43}}, {"id": 15, "type": "parameter_declaration", "text": "const char *str", "parent": 14, "children": [16, 17], "start_point": {"row": 3, "column": 20}, "end_point": {"row": 3, "column": 35}}, {"id": 16, "type": "primitive_type", "text": "char", "parent": 15, "children": [], "start_point": {"row": 3, "column": 26}, "end_point": {"row": 3, "column": 30}}, {"id": 17, "type": "pointer_declarator", "text": "*str", "parent": 15, "children": [18, 19], "start_point": {"row": 3, "column": 31}, "end_point": {"row": 3, "column": 35}}, {"id": 18, "type": "*", "text": "*", "parent": 17, "children": [], "start_point": {"row": 3, "column": 31}, "end_point": {"row": 3, "column": 32}}, {"id": 19, "type": "identifier", "text": "str", "parent": 17, "children": [], "start_point": {"row": 3, "column": 32}, "end_point": {"row": 3, "column": 35}}, {"id": 20, "type": "parameter_declaration", "text": "int c", "parent": 14, "children": [21, 22], "start_point": {"row": 3, "column": 37}, "end_point": {"row": 3, "column": 42}}, {"id": 21, "type": "primitive_type", "text": "int", "parent": 20, "children": [], "start_point": {"row": 3, "column": 37}, "end_point": {"row": 3, "column": 40}}, {"id": 22, "type": "identifier", "text": "c", "parent": 20, "children": [], "start_point": {"row": 3, "column": 41}, "end_point": {"row": 3, "column": 42}}, {"id": 23, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 6}}]}, "node_categories": {"declarations": {"functions": [12], "variables": [6, 15, 20], "classes": [7], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 13, 19, 22, 23], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 12, "universal_type": "function", "name": "c)", "text_snippet": "strchr(const char *str, int c)"}], "class_declarations": [{"node_id": 7, "universal_type": "class", "name": "unknown", "text_snippet": "extern"}], "import_statements": []}, "original_source_code": "#ifndef _LIBC_STRING_STRCHR_H_\n#define _LIBC_STRING_STRCHR_H_\n\nextern char *strchr(const char *str, int c);\n\n#endif"}
80,530
c
#include "Absyn.h" int interpret(Exp p);
19.5
2
(translation_unit) "#include "Absyn.h"\n\nint interpret(Exp p);\n" (preproc_include) "#include "Absyn.h"\n" (#include) "#include" (string_literal) ""Absyn.h"" (") """ (string_content) "Absyn.h" (") """ (declaration) "int interpret(Exp p);" (primitive_type) "int" (function_declarator) "interpret(Exp p)" (identifier) "interpret" (parameter_list) "(Exp p)" (() "(" (parameter_declaration) "Exp p" (type_identifier) "Exp" (identifier) "p" ()) ")" (;) ";"
18
0
{"language": "c", "success": true, "metadata": {"lines": 2, "avg_line_length": 19.5, "nodes": 11, "errors": 0, "source_hash": "4990828da83245413df5d5c0f9a40117c6d729ab0745ec453dd282ece82f1c6f", "categorized_nodes": 9}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"Absyn.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"Absyn.h\"", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 18}}, {"id": 3, "type": "declaration", "text": "int interpret(Exp p);", "parent": null, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 21}}, {"id": 4, "type": "primitive_type", "text": "int", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 3}}, {"id": 5, "type": "function_declarator", "text": "interpret(Exp p)", "parent": 3, "children": [6, 7], "start_point": {"row": 2, "column": 4}, "end_point": {"row": 2, "column": 20}}, {"id": 6, "type": "identifier", "text": "interpret", "parent": 5, "children": [], "start_point": {"row": 2, "column": 4}, "end_point": {"row": 2, "column": 13}}, {"id": 7, "type": "parameter_list", "text": "(Exp p)", "parent": 5, "children": [8], "start_point": {"row": 2, "column": 13}, "end_point": {"row": 2, "column": 20}}, {"id": 8, "type": "parameter_declaration", "text": "Exp p", "parent": 7, "children": [9, 10], "start_point": {"row": 2, "column": 14}, "end_point": {"row": 2, "column": 19}}, {"id": 9, "type": "type_identifier", "text": "Exp", "parent": 8, "children": [], "start_point": {"row": 2, "column": 14}, "end_point": {"row": 2, "column": 17}}, {"id": 10, "type": "identifier", "text": "p", "parent": 8, "children": [], "start_point": {"row": 2, "column": 18}, "end_point": {"row": 2, "column": 19}}]}, "node_categories": {"declarations": {"functions": [5], "variables": [3, 8], "classes": [], "imports": [0, 1], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [6, 9, 10], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [2], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 5, "universal_type": "function", "name": "unknown", "text_snippet": "interpret(Exp p)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include \"Absyn.h\"\n"}, {"node_id": 1, "text": "#include"}]}, "original_source_code": "#include \"Absyn.h\"\n\nint interpret(Exp p);\n"}
80,531
c
/** * \file * * \brief SAM TIMER Driver for SAMB11 * * Copyright (c) 2015-2018 Microchip Technology Inc. and its subsidiaries. * * \asf_license_start * * \page License * * Subject to your compliance with these terms, you may use Microchip * software and any derivatives exclusively with Microchip products. * It is your responsibility to comply with third party license terms applicable * to your use of third party software (including open source software) that * may accompany Microchip software. * * THIS SOFTWARE IS SUPPLIED BY MICROCHIP "AS IS". NO WARRANTIES, * WHETHER EXPRESS, IMPLIED OR STATUTORY, APPLY TO THIS SOFTWARE, * INCLUDING ANY IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY, * AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT WILL MICROCHIP BE * LIABLE FOR ANY INDIRECT, SPECIAL, PUNITIVE, INCIDENTAL OR CONSEQUENTIAL * LOSS, DAMAGE, COST OR EXPENSE OF ANY KIND WHATSOEVER RELATED TO THE * SOFTWARE, HOWEVER CAUSED, EVEN IF MICROCHIP HAS BEEN ADVISED OF THE * POSSIBILITY OR THE DAMAGES ARE FORESEEABLE. TO THE FULLEST EXTENT * ALLOWED BY LAW, MICROCHIP'S TOTAL LIABILITY ON ALL CLAIMS IN ANY WAY * RELATED TO THIS SOFTWARE WILL NOT EXCEED THE AMOUNT OF FEES, IF ANY, * THAT YOU HAVE PAID DIRECTLY TO MICROCHIP FOR THIS SOFTWARE. * * \asf_license_stop * */ /* * Support and FAQ: visit <a href="https://www.microchip.com/support/">Microchip Support</a> */ #ifndef TIMER_H_INCLUDED #define TIMER_H_INCLUDED /** * \defgroup asfdoc_samb_timer_group SAM TIMER * * This driver for Atmel&reg; | SMART SAM devices provides an interface for the * configuration and management of the device's basic Timer functionality. * * The following peripherals are used by this module: * - TIMER * * The following devices can use this module: * - Atmel | SMART SAM B11 * * The outline of this documentation is as follows: * - \ref asfdoc_samb_timer_prerequisites * - \ref asfdoc_samb_timer_module_overview * - \ref asfdoc_samb_timer_special_considerations * - \ref asfdoc_samb_timer_extra_info * - \ref asfdoc_samb_timer_examples * - \ref asfdoc_samb_timer_api_overview * * * \section asfdoc_samb_timer_prerequisites Prerequisites * * There are no prerequisites for this module. * * * \section asfdoc_samb_timer_module_overview Module Overview * This driver proiveds a basic timer for count, is a 32-bit * down-counter with the following features: * * - You can generate an interrupt request signal, TIMERINT, * when the counter reaches 0. * - The interrupt request is held until it is cleared by writing to the INTCLEAR Register. * * - You can use the zero to one transition of the external input signal, EXTIN, as a timer enable. * * - If the APB timer count reaches 0 and, at the same time, the software clears a previous * interrupt status, the interrupt status is set to 1. * * - The external clock, EXTIN, must be slower than half of the peripheral clock because it is * sampled by a double flip-flop and then goes through edge-detection logic when the * external inputs act as a clock. * * - A separate clock pin, PCLKG, for the APB register read or write logic that permits the * clock to peripheral register logic to stop when there is no APB activity. * * \section asfdoc_samb_timer_special_considerations Special Considerations * * There are no prerequisites for this module. * * \section asfdoc_samb_timer_extra_info Extra Information * * For extra information, see \ref asfdoc_samb_timer_extra. This includes: * - \ref asfdoc_samb_timer_extra_acronyms * - \ref asfdoc_samb_timer_extra_dependencies * - \ref asfdoc_samb_timer_extra_errata * - \ref asfdoc_samb_timer_extra_history * * * \section asfdoc_samb_timer_examples Examples * * For a list of examples related to this driver, see * \ref asfdoc_samb_timer_exqsg. * * * \section asfdoc_samb_timer_api_overview API Overview * @{ */ #include <compiler.h> #include <system_sam_b.h> #ifdef __cplusplus extern "C" { #endif /** Type definition for a TIMER module callback function. */ typedef void (*timer_callback_t)(void); /** * \brief TIMER configuration structure. * * Configuration struct for a TIMER instance. This structure should be * initialized by the \ref timer_get_config_defaults function before being * modified by the user application. */ struct timer_config { /** Reload value */ uint32_t reload_value; /** Enable timer interrupt */ bool interrupt_enable; }; /** * \name Configuration and Initialization * @{ */ void timer_get_config_defaults(struct timer_config *config); void timer_init(const struct timer_config *config); /** @} */ /** * \name Get and set value * @{ */ uint32_t timer_get_value(void); void timer_set_value(uint32_t value); /** @} */ /** * \name Get and Clear status * @{ */ uint32_t timer_get_interrupt_status(void); void timer_clear_interrupt_status(void); /** @} */ /** * \name Enable and disable module * @{ */ void timer_enable(void); void timer_disable(void); /** @} */ /** * \name Callback * @{ */ void timer_register_callback(timer_callback_t fun); void timer_unregister_callback(void); /** @} */ /** @}*/ #ifdef __cplusplus } #endif /** * \page asfdoc_samb_timer_extra Extra Information for TIMER Driver * * \section asfdoc_samb_timer_extra_acronyms Acronyms * Below is a table listing the acronyms used in this module, along with their * intended meanings. * <table> * <tr> * <th>Acronym</th> * <th>Description</th> * </tr> * <tr> * <td>TIMER</td> * <td>Timer</td> * </tr> * </table> * * \section asfdoc_samb_timer_extra_dependencies Dependencies * There are no dependencies related to this driver. * * * \section asfdoc_samb_timer_extra_errata Errata * There are no errata related to this driver. * * * \section asfdoc_samb_timer_extra_history Module History * An overview of the module history is presented in the table below, with * details on the enhancements and fixes made to the module since its first * release. The current version of this corresponds to the newest version in * the table. * * <table> * <tr> * <th>Changelog</th> * </tr> * <tr> * <td>Initial Release</td> * </tr> * </table> */ /** * \page asfdoc_samb_timer_exqsg Examples for TIMER Driver * * This is a list of the available Quick Start guides (QSGs) and example * applications for \ref asfdoc_samb_timer_group. QSGs are simple examples with * step-by-step instructions to configure and use this driver in a selection of * use cases. Note that QSGs can be compiled as a standalone application or be * added to the user application. * * - \subpage asfdoc_samb_timer_basic_use_case * * \page asfdoc_samb_timer_document_revision_history Document Revision History * * <table> * <tr> * <th>Doc. Rev.</td> * <th>Date</td> * <th>Comments</td> * </tr> * <tr> * <td>A</td> * <td>09/2015</td> * <td>Initial release</td> * </tr> * </table> */ #endif
29.06
232
(translation_unit) "/**\n * \file\n *\n * \brief SAM TIMER Driver for SAMB11\n *\n * Copyright (c) 2015-2018 Microchip Technology Inc. and its subsidiaries.\n *\n * \asf_license_start\n *\n * \page License\n *\n * Subject to your compliance with these terms, you may use Microchip\n * software and any derivatives exclusively with Microchip products.\n * It is your responsibility to comply with third party license terms applicable\n * to your use of third party software (including open source software) that\n * may accompany Microchip software.\n *\n * THIS SOFTWARE IS SUPPLIED BY MICROCHIP "AS IS". NO WARRANTIES,\n * WHETHER EXPRESS, IMPLIED OR STATUTORY, APPLY TO THIS SOFTWARE,\n * INCLUDING ANY IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY,\n * AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT WILL MICROCHIP BE\n * LIABLE FOR ANY INDIRECT, SPECIAL, PUNITIVE, INCIDENTAL OR CONSEQUENTIAL\n * LOSS, DAMAGE, COST OR EXPENSE OF ANY KIND WHATSOEVER RELATED TO THE\n * SOFTWARE, HOWEVER CAUSED, EVEN IF MICROCHIP HAS BEEN ADVISED OF THE\n * POSSIBILITY OR THE DAMAGES ARE FORESEEABLE. TO THE FULLEST EXTENT\n * ALLOWED BY LAW, MICROCHIP'S TOTAL LIABILITY ON ALL CLAIMS IN ANY WAY\n * RELATED TO THIS SOFTWARE WILL NOT EXCEED THE AMOUNT OF FEES, IF ANY,\n * THAT YOU HAVE PAID DIRECTLY TO MICROCHIP FOR THIS SOFTWARE.\n *\n * \asf_license_stop\n *\n */\n/*\n * Support and FAQ: visit <a href="https://www.microchip.com/support/">Microchip Support</a>\n */\n#ifndef TIMER_H_INCLUDED\n#define TIMER_H_INCLUDED\n\n/**\n * \defgroup asfdoc_samb_timer_group SAM TIMER\n *\n * This driver for Atmel&reg; | SMART SAM devices provides an interface for the\n * configuration and management of the device's basic Timer functionality.\n *\n * The following peripherals are used by this module:\n * - TIMER\n *\n * The following devices can use this module:\n * - Atmel | SMART SAM B11\n *\n * The outline of this documentation is as follows:\n * - \ref asfdoc_samb_timer_prerequisites\n * - \ref asfdoc_samb_timer_module_overview\n * - \ref asfdoc_samb_timer_special_considerations\n * - \ref asfdoc_samb_timer_extra_info\n * - \ref asfdoc_samb_timer_examples\n * - \ref asfdoc_samb_timer_api_overview\n *\n *\n * \section asfdoc_samb_timer_prerequisites Prerequisites\n *\n * There are no prerequisites for this module.\n *\n *\n * \section asfdoc_samb_timer_module_overview Module Overview\n * This driver proiveds a basic timer for count, is a 32-bit\n * down-counter with the following features:\n *\n * - You can generate an interrupt request signal, TIMERINT,\n * when the counter reaches 0.\n \n * - The interrupt request is held until it is cleared by writing to the INTCLEAR Register.\n *\n * - You can use the zero to one transition of the external input signal, EXTIN, as a timer enable.\n *\n * - If the APB timer count reaches 0 and, at the same time, the software clears a previous\n * interrupt status, the interrupt status is set to 1.\n *\n * - The external clock, EXTIN, must be slower than half of the peripheral clock because it is\n * sampled by a double flip-flop and then goes through edge-detection logic when the\n * external inputs act as a clock. \n *\n * - A separate clock pin, PCLKG, for the APB register read or write logic that permits the\n * clock to peripheral register logic to stop when there is no APB activity.\n *\n * \section asfdoc_samb_timer_special_considerations Special Considerations\n *\n * There are no prerequisites for this module.\n *\n * \section asfdoc_samb_timer_extra_info Extra Information\n *\n * For extra information, see \ref asfdoc_samb_timer_extra. This includes:\n * - \ref asfdoc_samb_timer_extra_acronyms\n * - \ref asfdoc_samb_timer_extra_dependencies\n * - \ref asfdoc_samb_timer_extra_errata\n * - \ref asfdoc_samb_timer_extra_history\n *\n *\n * \section asfdoc_samb_timer_examples Examples\n *\n * For a list of examples related to this driver, see\n * \ref asfdoc_samb_timer_exqsg.\n *\n *\n * \section asfdoc_samb_timer_api_overview API Overview\n * @{\n */\n\n#include <compiler.h>\n#include <system_sam_b.h>\n\n#ifdef __cplusplus\nextern "C" {\n#endif\n\n/** Type definition for a TIMER module callback function. */\ntypedef void (*timer_callback_t)(void);\n\n/**\n * \brief TIMER configuration structure.\n *\n * Configuration struct for a TIMER instance. This structure should be\n * initialized by the \ref timer_get_config_defaults function before being\n * modified by the user application.\n */\nstruct timer_config {\n /** Reload value */\n uint32_t reload_value;\n /** Enable timer interrupt */\n bool interrupt_enable;\n};\n\n/**\n * \name Configuration and Initialization\n * @{\n */\nvoid timer_get_config_defaults(struct timer_config *config);\nvoid timer_init(const struct timer_config *config);\n/** @} */\n\n/**\n * \name Get and set value\n * @{\n */\nuint32_t timer_get_value(void);\nvoid timer_set_value(uint32_t value);\n/** @} */\n\n/**\n * \name Get and Clear status\n * @{\n */\nuint32_t timer_get_interrupt_status(void);\nvoid timer_clear_interrupt_status(void);\n/** @} */\n\n/**\n * \name Enable and disable module\n * @{\n */\nvoid timer_enable(void);\nvoid timer_disable(void);\n/** @} */\n\n/**\n * \name Callback\n * @{\n */\nvoid timer_register_callback(timer_callback_t fun);\nvoid timer_unregister_callback(void);\n/** @} */\n\n/** @}*/\n\n#ifdef __cplusplus\n}\n#endif\n\n/**\n * \page asfdoc_samb_timer_extra Extra Information for TIMER Driver\n *\n * \section asfdoc_samb_timer_extra_acronyms Acronyms\n * Below is a table listing the acronyms used in this module, along with their\n * intended meanings.\n * <table>\n * <tr>\n * <th>Acronym</th>\n * <th>Description</th>\n * </tr>\n * <tr>\n * <td>TIMER</td>\n * <td>Timer</td>\n * </tr>\n * </table>\n *\n * \section asfdoc_samb_timer_extra_dependencies Dependencies\n * There are no dependencies related to this driver.\n *\n *\n * \section asfdoc_samb_timer_extra_errata Errata\n * There are no errata related to this driver.\n *\n *\n * \section asfdoc_samb_timer_extra_history Module History\n * An overview of the module history is presented in the table below, with\n * details on the enhancements and fixes made to the module since its first\n * release. The current version of this corresponds to the newest version in\n * the table.\n *\n * <table>\n * <tr>\n * <th>Changelog</th>\n * </tr>\n * <tr>\n * <td>Initial Release</td>\n * </tr>\n * </table>\n */\n\n/**\n * \page asfdoc_samb_timer_exqsg Examples for TIMER Driver\n *\n * This is a list of the available Quick Start guides (QSGs) and example\n * applications for \ref asfdoc_samb_timer_group. QSGs are simple examples with\n * step-by-step instructions to configure and use this driver in a selection of\n * use cases. Note that QSGs can be compiled as a standalone application or be\n * added to the user application.\n *\n * - \subpage asfdoc_samb_timer_basic_use_case\n *\n * \page asfdoc_samb_timer_document_revision_history Document Revision History\n *\n * <table>\n * <tr>\n * <th>Doc. Rev.</td>\n * <th>Date</td>\n * <th>Comments</td>\n * </tr>\n * <tr>\n * <td>A</td>\n * <td>09/2015</td>\n * <td>Initial release</td>\n * </tr>\n * </table>\n */\n\n#endif" (comment) "/**\n * \file\n *\n * \brief SAM TIMER Driver for SAMB11\n *\n * Copyright (c) 2015-2018 Microchip Technology Inc. and its subsidiaries.\n *\n * \asf_license_start\n *\n * \page License\n *\n * Subject to your compliance with these terms, you may use Microchip\n * software and any derivatives exclusively with Microchip products.\n * It is your responsibility to comply with third party license terms applicable\n * to your use of third party software (including open source software) that\n * may accompany Microchip software.\n *\n * THIS SOFTWARE IS SUPPLIED BY MICROCHIP "AS IS". NO WARRANTIES,\n * WHETHER EXPRESS, IMPLIED OR STATUTORY, APPLY TO THIS SOFTWARE,\n * INCLUDING ANY IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY,\n * AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT WILL MICROCHIP BE\n * LIABLE FOR ANY INDIRECT, SPECIAL, PUNITIVE, INCIDENTAL OR CONSEQUENTIAL\n * LOSS, DAMAGE, COST OR EXPENSE OF ANY KIND WHATSOEVER RELATED TO THE\n * SOFTWARE, HOWEVER CAUSED, EVEN IF MICROCHIP HAS BEEN ADVISED OF THE\n * POSSIBILITY OR THE DAMAGES ARE FORESEEABLE. TO THE FULLEST EXTENT\n * ALLOWED BY LAW, MICROCHIP'S TOTAL LIABILITY ON ALL CLAIMS IN ANY WAY\n * RELATED TO THIS SOFTWARE WILL NOT EXCEED THE AMOUNT OF FEES, IF ANY,\n * THAT YOU HAVE PAID DIRECTLY TO MICROCHIP FOR THIS SOFTWARE.\n *\n * \asf_license_stop\n *\n */" (comment) "/*\n * Support and FAQ: visit <a href="https://www.microchip.com/support/">Microchip Support</a>\n */" (preproc_ifdef) "#ifndef TIMER_H_INCLUDED\n#define TIMER_H_INCLUDED\n\n/**\n * \defgroup asfdoc_samb_timer_group SAM TIMER\n *\n * This driver for Atmel&reg; | SMART SAM devices provides an interface for the\n * configuration and management of the device's basic Timer functionality.\n *\n * The following peripherals are used by this module:\n * - TIMER\n *\n * The following devices can use this module:\n * - Atmel | SMART SAM B11\n *\n * The outline of this documentation is as follows:\n * - \ref asfdoc_samb_timer_prerequisites\n * - \ref asfdoc_samb_timer_module_overview\n * - \ref asfdoc_samb_timer_special_considerations\n * - \ref asfdoc_samb_timer_extra_info\n * - \ref asfdoc_samb_timer_examples\n * - \ref asfdoc_samb_timer_api_overview\n *\n *\n * \section asfdoc_samb_timer_prerequisites Prerequisites\n *\n * There are no prerequisites for this module.\n *\n *\n * \section asfdoc_samb_timer_module_overview Module Overview\n * This driver proiveds a basic timer for count, is a 32-bit\n * down-counter with the following features:\n *\n * - You can generate an interrupt request signal, TIMERINT,\n * when the counter reaches 0.\n \n * - The interrupt request is held until it is cleared by writing to the INTCLEAR Register.\n *\n * - You can use the zero to one transition of the external input signal, EXTIN, as a timer enable.\n *\n * - If the APB timer count reaches 0 and, at the same time, the software clears a previous\n * interrupt status, the interrupt status is set to 1.\n *\n * - The external clock, EXTIN, must be slower than half of the peripheral clock because it is\n * sampled by a double flip-flop and then goes through edge-detection logic when the\n * external inputs act as a clock. \n *\n * - A separate clock pin, PCLKG, for the APB register read or write logic that permits the\n * clock to peripheral register logic to stop when there is no APB activity.\n *\n * \section asfdoc_samb_timer_special_considerations Special Considerations\n *\n * There are no prerequisites for this module.\n *\n * \section asfdoc_samb_timer_extra_info Extra Information\n *\n * For extra information, see \ref asfdoc_samb_timer_extra. This includes:\n * - \ref asfdoc_samb_timer_extra_acronyms\n * - \ref asfdoc_samb_timer_extra_dependencies\n * - \ref asfdoc_samb_timer_extra_errata\n * - \ref asfdoc_samb_timer_extra_history\n *\n *\n * \section asfdoc_samb_timer_examples Examples\n *\n * For a list of examples related to this driver, see\n * \ref asfdoc_samb_timer_exqsg.\n *\n *\n * \section asfdoc_samb_timer_api_overview API Overview\n * @{\n */\n\n#include <compiler.h>\n#include <system_sam_b.h>\n\n#ifdef __cplusplus\nextern "C" {\n#endif\n\n/** Type definition for a TIMER module callback function. */\ntypedef void (*timer_callback_t)(void);\n\n/**\n * \brief TIMER configuration structure.\n *\n * Configuration struct for a TIMER instance. This structure should be\n * initialized by the \ref timer_get_config_defaults function before being\n * modified by the user application.\n */\nstruct timer_config {\n /** Reload value */\n uint32_t reload_value;\n /** Enable timer interrupt */\n bool interrupt_enable;\n};\n\n/**\n * \name Configuration and Initialization\n * @{\n */\nvoid timer_get_config_defaults(struct timer_config *config);\nvoid timer_init(const struct timer_config *config);\n/** @} */\n\n/**\n * \name Get and set value\n * @{\n */\nuint32_t timer_get_value(void);\nvoid timer_set_value(uint32_t value);\n/** @} */\n\n/**\n * \name Get and Clear status\n * @{\n */\nuint32_t timer_get_interrupt_status(void);\nvoid timer_clear_interrupt_status(void);\n/** @} */\n\n/**\n * \name Enable and disable module\n * @{\n */\nvoid timer_enable(void);\nvoid timer_disable(void);\n/** @} */\n\n/**\n * \name Callback\n * @{\n */\nvoid timer_register_callback(timer_callback_t fun);\nvoid timer_unregister_callback(void);\n/** @} */\n\n/** @}*/\n\n#ifdef __cplusplus\n}\n#endif\n\n/**\n * \page asfdoc_samb_timer_extra Extra Information for TIMER Driver\n *\n * \section asfdoc_samb_timer_extra_acronyms Acronyms\n * Below is a table listing the acronyms used in this module, along with their\n * intended meanings.\n * <table>\n * <tr>\n * <th>Acronym</th>\n * <th>Description</th>\n * </tr>\n * <tr>\n * <td>TIMER</td>\n * <td>Timer</td>\n * </tr>\n * </table>\n *\n * \section asfdoc_samb_timer_extra_dependencies Dependencies\n * There are no dependencies related to this driver.\n *\n *\n * \section asfdoc_samb_timer_extra_errata Errata\n * There are no errata related to this driver.\n *\n *\n * \section asfdoc_samb_timer_extra_history Module History\n * An overview of the module history is presented in the table below, with\n * details on the enhancements and fixes made to the module since its first\n * release. The current version of this corresponds to the newest version in\n * the table.\n *\n * <table>\n * <tr>\n * <th>Changelog</th>\n * </tr>\n * <tr>\n * <td>Initial Release</td>\n * </tr>\n * </table>\n */\n\n/**\n * \page asfdoc_samb_timer_exqsg Examples for TIMER Driver\n *\n * This is a list of the available Quick Start guides (QSGs) and example\n * applications for \ref asfdoc_samb_timer_group. QSGs are simple examples with\n * step-by-step instructions to configure and use this driver in a selection of\n * use cases. Note that QSGs can be compiled as a standalone application or be\n * added to the user application.\n *\n * - \subpage asfdoc_samb_timer_basic_use_case\n *\n * \page asfdoc_samb_timer_document_revision_history Document Revision History\n *\n * <table>\n * <tr>\n * <th>Doc. Rev.</td>\n * <th>Date</td>\n * <th>Comments</td>\n * </tr>\n * <tr>\n * <td>A</td>\n * <td>09/2015</td>\n * <td>Initial release</td>\n * </tr>\n * </table>\n */\n\n#endif" (#ifndef) "#ifndef" (identifier) "TIMER_H_INCLUDED" (preproc_def) "#define TIMER_H_INCLUDED\n" (#define) "#define" (identifier) "TIMER_H_INCLUDED" (comment) "/**\n * \defgroup asfdoc_samb_timer_group SAM TIMER\n *\n * This driver for Atmel&reg; | SMART SAM devices provides an interface for the\n * configuration and management of the device's basic Timer functionality.\n *\n * The following peripherals are used by this module:\n * - TIMER\n *\n * The following devices can use this module:\n * - Atmel | SMART SAM B11\n *\n * The outline of this documentation is as follows:\n * - \ref asfdoc_samb_timer_prerequisites\n * - \ref asfdoc_samb_timer_module_overview\n * - \ref asfdoc_samb_timer_special_considerations\n * - \ref asfdoc_samb_timer_extra_info\n * - \ref asfdoc_samb_timer_examples\n * - \ref asfdoc_samb_timer_api_overview\n *\n *\n * \section asfdoc_samb_timer_prerequisites Prerequisites\n *\n * There are no prerequisites for this module.\n *\n *\n * \section asfdoc_samb_timer_module_overview Module Overview\n * This driver proiveds a basic timer for count, is a 32-bit\n * down-counter with the following features:\n *\n * - You can generate an interrupt request signal, TIMERINT,\n * when the counter reaches 0.\n \n * - The interrupt request is held until it is cleared by writing to the INTCLEAR Register.\n *\n * - You can use the zero to one transition of the external input signal, EXTIN, as a timer enable.\n *\n * - If the APB timer count reaches 0 and, at the same time, the software clears a previous\n * interrupt status, the interrupt status is set to 1.\n *\n * - The external clock, EXTIN, must be slower than half of the peripheral clock because it is\n * sampled by a double flip-flop and then goes through edge-detection logic when the\n * external inputs act as a clock. \n *\n * - A separate clock pin, PCLKG, for the APB register read or write logic that permits the\n * clock to peripheral register logic to stop when there is no APB activity.\n *\n * \section asfdoc_samb_timer_special_considerations Special Considerations\n *\n * There are no prerequisites for this module.\n *\n * \section asfdoc_samb_timer_extra_info Extra Information\n *\n * For extra information, see \ref asfdoc_samb_timer_extra. This includes:\n * - \ref asfdoc_samb_timer_extra_acronyms\n * - \ref asfdoc_samb_timer_extra_dependencies\n * - \ref asfdoc_samb_timer_extra_errata\n * - \ref asfdoc_samb_timer_extra_history\n *\n *\n * \section asfdoc_samb_timer_examples Examples\n *\n * For a list of examples related to this driver, see\n * \ref asfdoc_samb_timer_exqsg.\n *\n *\n * \section asfdoc_samb_timer_api_overview API Overview\n * @{\n */" (preproc_include) "#include <compiler.h>\n" (#include) "#include" (system_lib_string) "<compiler.h>" (preproc_include) "#include <system_sam_b.h>\n" (#include) "#include" (system_lib_string) "<system_sam_b.h>" (preproc_ifdef) "#ifdef __cplusplus\nextern "C" {\n#endif\n\n/** Type definition for a TIMER module callback function. */\ntypedef void (*timer_callback_t)(void);\n\n/**\n * \brief TIMER configuration structure.\n *\n * Configuration struct for a TIMER instance. This structure should be\n * initialized by the \ref timer_get_config_defaults function before being\n * modified by the user application.\n */\nstruct timer_config {\n /** Reload value */\n uint32_t reload_value;\n /** Enable timer interrupt */\n bool interrupt_enable;\n};\n\n/**\n * \name Configuration and Initialization\n * @{\n */\nvoid timer_get_config_defaults(struct timer_config *config);\nvoid timer_init(const struct timer_config *config);\n/** @} */\n\n/**\n * \name Get and set value\n * @{\n */\nuint32_t timer_get_value(void);\nvoid timer_set_value(uint32_t value);\n/** @} */\n\n/**\n * \name Get and Clear status\n * @{\n */\nuint32_t timer_get_interrupt_status(void);\nvoid timer_clear_interrupt_status(void);\n/** @} */\n\n/**\n * \name Enable and disable module\n * @{\n */\nvoid timer_enable(void);\nvoid timer_disable(void);\n/** @} */\n\n/**\n * \name Callback\n * @{\n */\nvoid timer_register_callback(timer_callback_t fun);\nvoid timer_unregister_callback(void);\n/** @} */\n\n/** @}*/\n\n#ifdef __cplusplus\n}\n#endif" (#ifdef) "#ifdef" (identifier) "__cplusplus" (linkage_specification) "extern "C" {\n#endif\n\n/** Type definition for a TIMER module callback function. */\ntypedef void (*timer_callback_t)(void);\n\n/**\n * \brief TIMER configuration structure.\n *\n * Configuration struct for a TIMER instance. This structure should be\n * initialized by the \ref timer_get_config_defaults function before being\n * modified by the user application.\n */\nstruct timer_config {\n /** Reload value */\n uint32_t reload_value;\n /** Enable timer interrupt */\n bool interrupt_enable;\n};\n\n/**\n * \name Configuration and Initialization\n * @{\n */\nvoid timer_get_config_defaults(struct timer_config *config);\nvoid timer_init(const struct timer_config *config);\n/** @} */\n\n/**\n * \name Get and set value\n * @{\n */\nuint32_t timer_get_value(void);\nvoid timer_set_value(uint32_t value);\n/** @} */\n\n/**\n * \name Get and Clear status\n * @{\n */\nuint32_t timer_get_interrupt_status(void);\nvoid timer_clear_interrupt_status(void);\n/** @} */\n\n/**\n * \name Enable and disable module\n * @{\n */\nvoid timer_enable(void);\nvoid timer_disable(void);\n/** @} */\n\n/**\n * \name Callback\n * @{\n */\nvoid timer_register_callback(timer_callback_t fun);\nvoid timer_unregister_callback(void);\n/** @} */\n\n/** @}*/\n\n#ifdef __cplusplus\n}" (extern) "extern" (string_literal) ""C"" (") """ (string_content) "C" (") """ (declaration_list) "{\n#endif\n\n/** Type definition for a TIMER module callback function. */\ntypedef void (*timer_callback_t)(void);\n\n/**\n * \brief TIMER configuration structure.\n *\n * Configuration struct for a TIMER instance. This structure should be\n * initialized by the \ref timer_get_config_defaults function before being\n * modified by the user application.\n */\nstruct timer_config {\n /** Reload value */\n uint32_t reload_value;\n /** Enable timer interrupt */\n bool interrupt_enable;\n};\n\n/**\n * \name Configuration and Initialization\n * @{\n */\nvoid timer_get_config_defaults(struct timer_config *config);\nvoid timer_init(const struct timer_config *config);\n/** @} */\n\n/**\n * \name Get and set value\n * @{\n */\nuint32_t timer_get_value(void);\nvoid timer_set_value(uint32_t value);\n/** @} */\n\n/**\n * \name Get and Clear status\n * @{\n */\nuint32_t timer_get_interrupt_status(void);\nvoid timer_clear_interrupt_status(void);\n/** @} */\n\n/**\n * \name Enable and disable module\n * @{\n */\nvoid timer_enable(void);\nvoid timer_disable(void);\n/** @} */\n\n/**\n * \name Callback\n * @{\n */\nvoid timer_register_callback(timer_callback_t fun);\nvoid timer_unregister_callback(void);\n/** @} */\n\n/** @}*/\n\n#ifdef __cplusplus\n}" ({) "{" (preproc_call) "#endif\n" (preproc_directive) "#endif" (comment) "/** Type definition for a TIMER module callback function. */" (type_definition) "typedef void (*timer_callback_t)(void);" (typedef) "typedef" (primitive_type) "void" (function_declarator) "(*timer_callback_t)(void)" (parenthesized_declarator) "(*timer_callback_t)" (() "(" (pointer_declarator) "*timer_callback_t" (*) "*" (type_identifier) "timer_callback_t" ()) ")" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (;) ";" (comment) "/**\n * \brief TIMER configuration structure.\n *\n * Configuration struct for a TIMER instance. This structure should be\n * initialized by the \ref timer_get_config_defaults function before being\n * modified by the user application.\n */" (struct_specifier) "struct timer_config {\n /** Reload value */\n uint32_t reload_value;\n /** Enable timer interrupt */\n bool interrupt_enable;\n}" (struct) "struct" (type_identifier) "timer_config" (field_declaration_list) "{\n /** Reload value */\n uint32_t reload_value;\n /** Enable timer interrupt */\n bool interrupt_enable;\n}" ({) "{" (comment) "/** Reload value */" (field_declaration) "uint32_t reload_value;" (primitive_type) "uint32_t" (field_identifier) "reload_value" (;) ";" (comment) "/** Enable timer interrupt */" (field_declaration) "bool interrupt_enable;" (primitive_type) "bool" (field_identifier) "interrupt_enable" (;) ";" (}) "}" (;) ";" (comment) "/**\n * \name Configuration and Initialization\n * @{\n */" (declaration) "void timer_get_config_defaults(struct timer_config *config);" (primitive_type) "void" (function_declarator) "timer_get_config_defaults(struct timer_config *config)" (identifier) "timer_get_config_defaults" (parameter_list) "(struct timer_config *config)" (() "(" (parameter_declaration) "struct timer_config *config" (struct_specifier) "struct timer_config" (struct) "struct" (type_identifier) "timer_config" (pointer_declarator) "*config" (*) "*" (identifier) "config" ()) ")" (;) ";" (declaration) "void timer_init(const struct timer_config *config);" (primitive_type) "void" (function_declarator) "timer_init(const struct timer_config *config)" (identifier) "timer_init" (parameter_list) "(const struct timer_config *config)" (() "(" (parameter_declaration) "const struct timer_config *config" (type_qualifier) "const" (const) "const" (struct_specifier) "struct timer_config" (struct) "struct" (type_identifier) "timer_config" (pointer_declarator) "*config" (*) "*" (identifier) "config" ()) ")" (;) ";" (comment) "/** @} */" (comment) "/**\n * \name Get and set value\n * @{\n */" (declaration) "uint32_t timer_get_value(void);" (primitive_type) "uint32_t" (function_declarator) "timer_get_value(void)" (identifier) "timer_get_value" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (;) ";" (declaration) "void timer_set_value(uint32_t value);" (primitive_type) "void" (function_declarator) "timer_set_value(uint32_t value)" (identifier) "timer_set_value" (parameter_list) "(uint32_t value)" (() "(" (parameter_declaration) "uint32_t value" (primitive_type) "uint32_t" (identifier) "value" ()) ")" (;) ";" (comment) "/** @} */" (comment) "/**\n * \name Get and Clear status\n * @{\n */" (declaration) "uint32_t timer_get_interrupt_status(void);" (primitive_type) "uint32_t" (function_declarator) "timer_get_interrupt_status(void)" (identifier) "timer_get_interrupt_status" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (;) ";" (declaration) "void timer_clear_interrupt_status(void);" (primitive_type) "void" (function_declarator) "timer_clear_interrupt_status(void)" (identifier) "timer_clear_interrupt_status" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (;) ";" (comment) "/** @} */" (comment) "/**\n * \name Enable and disable module\n * @{\n */" (declaration) "void timer_enable(void);" (primitive_type) "void" (function_declarator) "timer_enable(void)" (identifier) "timer_enable" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (;) ";" (declaration) "void timer_disable(void);" (primitive_type) "void" (function_declarator) "timer_disable(void)" (identifier) "timer_disable" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (;) ";" (comment) "/** @} */" (comment) "/**\n * \name Callback\n * @{\n */" (declaration) "void timer_register_callback(timer_callback_t fun);" (primitive_type) "void" (function_declarator) "timer_register_callback(timer_callback_t fun)" (identifier) "timer_register_callback" (parameter_list) "(timer_callback_t fun)" (() "(" (parameter_declaration) "timer_callback_t fun" (type_identifier) "timer_callback_t" (identifier) "fun" ()) ")" (;) ";" (declaration) "void timer_unregister_callback(void);" (primitive_type) "void" (function_declarator) "timer_unregister_callback(void)" (identifier) "timer_unregister_callback" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (;) ";" (comment) "/** @} */" (comment) "/** @}*/" (preproc_ifdef) "#ifdef __cplusplus" (#ifdef) "#ifdef" (identifier) "__cplusplus" (#endif) "" (}) "}" (#endif) "#endif" (comment) "/**\n * \page asfdoc_samb_timer_extra Extra Information for TIMER Driver\n *\n * \section asfdoc_samb_timer_extra_acronyms Acronyms\n * Below is a table listing the acronyms used in this module, along with their\n * intended meanings.\n * <table>\n * <tr>\n * <th>Acronym</th>\n * <th>Description</th>\n * </tr>\n * <tr>\n * <td>TIMER</td>\n * <td>Timer</td>\n * </tr>\n * </table>\n *\n * \section asfdoc_samb_timer_extra_dependencies Dependencies\n * There are no dependencies related to this driver.\n *\n *\n * \section asfdoc_samb_timer_extra_errata Errata\n * There are no errata related to this driver.\n *\n *\n * \section asfdoc_samb_timer_extra_history Module History\n * An overview of the module history is presented in the table below, with\n * details on the enhancements and fixes made to the module since its first\n * release. The current version of this corresponds to the newest version in\n * the table.\n *\n * <table>\n * <tr>\n * <th>Changelog</th>\n * </tr>\n * <tr>\n * <td>Initial Release</td>\n * </tr>\n * </table>\n */" (comment) "/**\n * \page asfdoc_samb_timer_exqsg Examples for TIMER Driver\n *\n * This is a list of the available Quick Start guides (QSGs) and example\n * applications for \ref asfdoc_samb_timer_group. QSGs are simple examples with\n * step-by-step instructions to configure and use this driver in a selection of\n * use cases. Note that QSGs can be compiled as a standalone application or be\n * added to the user application.\n *\n * - \subpage asfdoc_samb_timer_basic_use_case\n *\n * \page asfdoc_samb_timer_document_revision_history Document Revision History\n *\n * <table>\n * <tr>\n * <th>Doc. Rev.</td>\n * <th>Date</td>\n * <th>Comments</td>\n * </tr>\n * <tr>\n * <td>A</td>\n * <td>09/2015</td>\n * <td>Initial release</td>\n * </tr>\n * </table>\n */" (#endif) "#endif"
198
0
{"language": "c", "success": true, "metadata": {"lines": 232, "avg_line_length": 29.06, "nodes": 128, "errors": 0, "source_hash": "fa43bab077c6df284c216f3689a607fdb45e70156cf977dcb9d76f55629001da", "categorized_nodes": 84}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef TIMER_H_INCLUDED\n#define TIMER_H_INCLUDED\n\n/**\n * \\defgroup asfdoc_samb_timer_group SAM TIMER\n *\n * This driver for Atmel&reg; | SMART SAM devices provides an interface for the\n * configuration and management of the device's basic Timer functionality.\n *\n * The following peripherals are used by this module:\n * - TIMER\n *\n * The following devices can use this module:\n * - Atmel | SMART SAM B11\n *\n * The outline of this documentation is as follows:\n * - \\ref asfdoc_samb_timer_prerequisites\n * - \\ref asfdoc_samb_timer_module_overview\n * - \\ref asfdoc_samb_timer_special_considerations\n * - \\ref asfdoc_samb_timer_extra_info\n * - \\ref asfdoc_samb_timer_examples\n * - \\ref asfdoc_samb_timer_api_overview\n *\n *\n * \\section asfdoc_samb_timer_prerequisites Prerequisites\n *\n * There are no prerequisites for this module.\n *\n *\n * \\section asfdoc_samb_timer_module_overview Module Overview\n * This driver proiveds a basic timer for count, is a 32-bit\n * down-counter with the following features:\n *\n * - You can generate an interrupt request signal, TIMERINT,\n * when the counter reaches 0.\n \n * - The interrupt request is held until it is cleared by writing to the INTCLEAR Register.\n *\n * - You can use the zero to one transition of the external input signal, EXTIN, as a timer enable.\n *\n * - If the APB timer count reaches 0 and, at the same time, the software clears a previous\n * interrupt status, the interrupt status is set to 1.\n *\n * - The external clock, EXTIN, must be slower than half of the peripheral clock because it is\n * sampled by a double flip-flop and then goes through edge-detection logic when the\n * external inputs act as a clock. \n *\n * - A separate clock pin, PCLKG, for the APB register read or write logic that permits the\n * clock to peripheral register logic to stop when there is no APB activity.\n *\n * \\section asfdoc_samb_timer_special_considerations Special Considerations\n *\n * There are no prerequisites for this module.\n *\n * \\section asfdoc_samb_timer_extra_info Extra Information\n *\n * For extra information, see \\ref asfdoc_samb_timer_extra. This includes:\n * - \\ref asfdoc_samb_timer_extra_acronyms\n * - \\ref asfdoc_samb_timer_extra_dependencies\n * - \\ref asfdoc_samb_timer_extra_errata\n * - \\ref asfdoc_samb_timer_extra_history\n *\n *\n * \\section asfdoc_samb_timer_examples Examples\n *\n * For a list of examples related to this driver, see\n * \\ref asfdoc_samb_timer_exqsg.\n *\n *\n * \\section asfdoc_samb_timer_api_overview API Overview\n * @{\n */\n\n#include <compiler.h>\n#include <system_sam_b.h>\n\n#ifdef __cplusplus\nextern \"C\" {\n#endif\n\n/** Type definition for a TIMER module callback function. */\ntypedef void (*timer_callback_t)(void);\n\n/**\n * \\brief TIMER configuration structure.\n *\n * Configuration struct for a TIMER instance. This structure should be\n * initialized by the \\ref timer_get_config_defaults function before being\n * modified by the user application.\n */\nstruct timer_config {\n\t/** Reload value */\n\tuint32_t reload_value;\n\t/** Enable timer interrupt */\n\tbool interrupt_enable;\n};\n\n/**\n * \\name Configuration and Initialization\n * @{\n */\nvoid timer_get_config_defaults(struct timer_config *config);\nvoid timer_init(const struct timer_config *config);\n/** @} */\n\n/**\n * \\name Get and set value\n * @{\n */\nuint32_t timer_get_value(void);\nvoid timer_set_value(uint32_t value);\n/** @} */\n\n/**\n * \\name Get and Clear status\n * @{\n */\nuint32_t timer_get_interrupt_status(void);\nvoid timer_clear_interrupt_status(void);\n/** @} */\n\n/**\n * \\name Enable and disable module\n * @{\n */\nvoid timer_enable(void);\nvoid timer_disable(void);\n/** @} */\n\n/**\n * \\name Callback\n * @{\n */\nvoid timer_register_callback(timer_callback_t fun);\nvoid timer_unregister_callback(void);\n/** @} */\n\n/** @}*/\n\n#ifdef __cplusplus\n}\n#endif\n\n/**\n * \\page asfdoc_samb_timer_extra Extra Information for TIMER Driver\n *\n * \\section asfdoc_samb_timer_extra_acronyms Acronyms\n * Below is a table listing the acronyms used in this module, along with their\n * intended meanings.\n * <table>\n *\t<tr>\n *\t\t<th>Acronym</th>\n *\t\t<th>Description</th>\n *\t</tr>\n *\t<tr>\n *\t\t<td>TIMER</td>\n *\t\t<td>Timer</td>\n *\t</tr>\n * </table>\n *\n * \\section asfdoc_samb_timer_extra_dependencies Dependencies\n * There are no dependencies related to this driver.\n *\n *\n * \\section asfdoc_samb_timer_extra_errata Errata\n * There are no errata related to this driver.\n *\n *\n * \\section asfdoc_samb_timer_extra_history Module History\n * An overview of the module history is presented in the table below, with\n * details on the enhancements and fixes made to the module since its first\n * release. The current version of this corresponds to the newest version in\n * the table.\n *\n * <table>\n * <tr>\n * <th>Changelog</th>\n * </tr>\n * <tr>\n * <td>Initial Release</td>\n * </tr>\n * </table>\n */\n\n/**\n * \\page asfdoc_samb_timer_exqsg Examples for TIMER Driver\n *\n * This is a list of the available Quick Start guides (QSGs) and example\n * applications for \\ref asfdoc_samb_timer_group. QSGs are simple examples with\n * step-by-step instructions to configure and use this driver in a selection of\n * use cases. Note that QSGs can be compiled as a standalone application or be\n * added to the user application.\n *\n * - \\subpage asfdoc_samb_timer_basic_use_case\n *\n * \\page asfdoc_samb_timer_document_revision_history Document Revision History\n *\n * <table>\n * <tr>\n * <th>Doc. Rev.</td>\n * <th>Date</td>\n * <th>Comments</td>\n * </tr>\n * <tr>\n * <td>A</td>\n * <td>09/2015</td>\n * <td>Initial release</td>\n * </tr>\n * </table>\n */\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 127], "start_point": {"row": 35, "column": 0}, "end_point": {"row": 246, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 35, "column": 0}, "end_point": {"row": 35, "column": 7}}, {"id": 2, "type": "identifier", "text": "TIMER_H_INCLUDED", "parent": 0, "children": [], "start_point": {"row": 35, "column": 8}, "end_point": {"row": 35, "column": 24}}, {"id": 3, "type": "preproc_def", "text": "#define TIMER_H_INCLUDED\n", "parent": 0, "children": [4, 5], "start_point": {"row": 36, "column": 0}, "end_point": {"row": 37, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 36, "column": 0}, "end_point": {"row": 36, "column": 7}}, {"id": 5, "type": "identifier", "text": "TIMER_H_INCLUDED", "parent": 3, "children": [], "start_point": {"row": 36, "column": 8}, "end_point": {"row": 36, "column": 24}}, {"id": 6, "type": "preproc_include", "text": "#include <compiler.h>\n", "parent": 0, "children": [7, 8], "start_point": {"row": 108, "column": 0}, "end_point": {"row": 109, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 108, "column": 0}, "end_point": {"row": 108, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<compiler.h>", "parent": 6, "children": [], "start_point": {"row": 108, "column": 9}, "end_point": {"row": 108, "column": 21}}, {"id": 9, "type": "preproc_include", "text": "#include <system_sam_b.h>\n", "parent": 0, "children": [10, 11], "start_point": {"row": 109, "column": 0}, "end_point": {"row": 110, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 109, "column": 0}, "end_point": {"row": 109, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<system_sam_b.h>", "parent": 9, "children": [], "start_point": {"row": 109, "column": 9}, "end_point": {"row": 109, "column": 25}}, {"id": 12, "type": "preproc_ifdef", "text": "#ifdef __cplusplus\nextern \"C\" {\n#endif\n\n/** Type definition for a TIMER module callback function. */\ntypedef void (*timer_callback_t)(void);\n\n/**\n * \\brief TIMER configuration structure.\n *\n * Configuration struct for a TIMER instance. This structure should be\n * initialized by the \\ref timer_get_config_defaults function before being\n * modified by the user application.\n */\nstruct timer_config {\n\t/** Reload value */\n\tuint32_t reload_value;\n\t/** Enable timer interrupt */\n\tbool interrupt_enable;\n};\n\n/**\n * \\name Configuration and Initialization\n * @{\n */\nvoid timer_get_config_defaults(struct timer_config *config);\nvoid timer_init(const struct timer_config *config);\n/** @} */\n\n/**\n * \\name Get and set value\n * @{\n */\nuint32_t timer_get_value(void);\nvoid timer_set_value(uint32_t value);\n/** @} */\n\n/**\n * \\name Get and Clear status\n * @{\n */\nuint32_t timer_get_interrupt_status(void);\nvoid timer_clear_interrupt_status(void);\n/** @} */\n\n/**\n * \\name Enable and disable module\n * @{\n */\nvoid timer_enable(void);\nvoid timer_disable(void);\n/** @} */\n\n/**\n * \\name Callback\n * @{\n */\nvoid timer_register_callback(timer_callback_t fun);\nvoid timer_unregister_callback(void);\n/** @} */\n\n/** @}*/\n\n#ifdef __cplusplus\n}\n#endif", "parent": 0, "children": [13, 14, 15, 126], "start_point": {"row": 111, "column": 0}, "end_point": {"row": 176, "column": 6}}, {"id": 13, "type": "#ifdef", "text": "#ifdef", "parent": 12, "children": [], "start_point": {"row": 111, "column": 0}, "end_point": {"row": 111, "column": 6}}, {"id": 14, "type": "identifier", "text": "__cplusplus", "parent": 12, "children": [], "start_point": {"row": 111, "column": 7}, "end_point": {"row": 111, "column": 18}}, {"id": 15, "type": "linkage_specification", "text": "extern \"C\" {\n#endif\n\n/** Type definition for a TIMER module callback function. */\ntypedef void (*timer_callback_t)(void);\n\n/**\n * \\brief TIMER configuration structure.\n *\n * Configuration struct for a TIMER instance. This structure should be\n * initialized by the \\ref timer_get_config_defaults function before being\n * modified by the user application.\n */\nstruct timer_config {\n\t/** Reload value */\n\tuint32_t reload_value;\n\t/** Enable timer interrupt */\n\tbool interrupt_enable;\n};\n\n/**\n * \\name Configuration and Initialization\n * @{\n */\nvoid timer_get_config_defaults(struct timer_config *config);\nvoid timer_init(const struct timer_config *config);\n/** @} */\n\n/**\n * \\name Get and set value\n * @{\n */\nuint32_t timer_get_value(void);\nvoid timer_set_value(uint32_t value);\n/** @} */\n\n/**\n * \\name Get and Clear status\n * @{\n */\nuint32_t timer_get_interrupt_status(void);\nvoid timer_clear_interrupt_status(void);\n/** @} */\n\n/**\n * \\name Enable and disable module\n * @{\n */\nvoid timer_enable(void);\nvoid timer_disable(void);\n/** @} */\n\n/**\n * \\name Callback\n * @{\n */\nvoid timer_register_callback(timer_callback_t fun);\nvoid timer_unregister_callback(void);\n/** @} */\n\n/** @}*/\n\n#ifdef __cplusplus\n}", "parent": 12, "children": [16, 17], "start_point": {"row": 112, "column": 0}, "end_point": {"row": 175, "column": 1}}, {"id": 16, "type": "extern", "text": "extern", "parent": 15, "children": [], "start_point": {"row": 112, "column": 0}, "end_point": {"row": 112, "column": 6}}, {"id": 17, "type": "string_literal", "text": "\"C\"", "parent": 15, "children": [], "start_point": {"row": 112, "column": 7}, "end_point": {"row": 112, "column": 10}}, {"id": 18, "type": "preproc_call", "text": "#endif\n", "parent": 15, "children": [19], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 114, "column": 0}}, {"id": 19, "type": "preproc_directive", "text": "#endif", "parent": 18, "children": [], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 113, "column": 6}}, {"id": 20, "type": "type_definition", "text": "typedef void (*timer_callback_t)(void);", "parent": 15, "children": [21, 22, 23], "start_point": {"row": 116, "column": 0}, "end_point": {"row": 116, "column": 39}}, {"id": 21, "type": "typedef", "text": "typedef", "parent": 20, "children": [], "start_point": {"row": 116, "column": 0}, "end_point": {"row": 116, "column": 7}}, {"id": 22, "type": "primitive_type", "text": "void", "parent": 20, "children": [], "start_point": {"row": 116, "column": 8}, "end_point": {"row": 116, "column": 12}}, {"id": 23, "type": "function_declarator", "text": "(*timer_callback_t)(void)", "parent": 20, "children": [24, 28], "start_point": {"row": 116, "column": 13}, "end_point": {"row": 116, "column": 38}}, {"id": 24, "type": "parenthesized_declarator", "text": "(*timer_callback_t)", "parent": 23, "children": [25], "start_point": {"row": 116, "column": 13}, "end_point": {"row": 116, "column": 32}}, {"id": 25, "type": "pointer_declarator", "text": "*timer_callback_t", "parent": 24, "children": [26, 27], "start_point": {"row": 116, "column": 14}, "end_point": {"row": 116, "column": 31}}, {"id": 26, "type": "*", "text": "*", "parent": 25, "children": [], "start_point": {"row": 116, "column": 14}, "end_point": {"row": 116, "column": 15}}, {"id": 27, "type": "type_identifier", "text": "timer_callback_t", "parent": 25, "children": [], "start_point": {"row": 116, "column": 15}, "end_point": {"row": 116, "column": 31}}, {"id": 28, "type": "parameter_list", "text": "(void)", "parent": 23, "children": [29], "start_point": {"row": 116, "column": 32}, "end_point": {"row": 116, "column": 38}}, {"id": 29, "type": "parameter_declaration", "text": "void", "parent": 28, "children": [30], "start_point": {"row": 116, "column": 33}, "end_point": {"row": 116, "column": 37}}, {"id": 30, "type": "primitive_type", "text": "void", "parent": 29, "children": [], "start_point": {"row": 116, "column": 33}, "end_point": {"row": 116, "column": 37}}, {"id": 31, "type": "struct_specifier", "text": "struct timer_config {\n\t/** Reload value */\n\tuint32_t reload_value;\n\t/** Enable timer interrupt */\n\tbool interrupt_enable;\n}", "parent": 15, "children": [32, 33], "start_point": {"row": 125, "column": 0}, "end_point": {"row": 130, "column": 1}}, {"id": 32, "type": "struct", "text": "struct", "parent": 31, "children": [], "start_point": {"row": 125, "column": 0}, "end_point": {"row": 125, "column": 6}}, {"id": 33, "type": "type_identifier", "text": "timer_config", "parent": 31, "children": [], "start_point": {"row": 125, "column": 7}, "end_point": {"row": 125, "column": 19}}, {"id": 34, "type": "field_declaration", "text": "uint32_t reload_value;", "parent": 31, "children": [35, 36], "start_point": {"row": 127, "column": 1}, "end_point": {"row": 127, "column": 23}}, {"id": 35, "type": "primitive_type", "text": "uint32_t", "parent": 34, "children": [], "start_point": {"row": 127, "column": 1}, "end_point": {"row": 127, "column": 9}}, {"id": 36, "type": "field_identifier", "text": "reload_value", "parent": 34, "children": [], "start_point": {"row": 127, "column": 10}, "end_point": {"row": 127, "column": 22}}, {"id": 37, "type": "field_declaration", "text": "bool interrupt_enable;", "parent": 31, "children": [38, 39], "start_point": {"row": 129, "column": 1}, "end_point": {"row": 129, "column": 23}}, {"id": 38, "type": "primitive_type", "text": "bool", "parent": 37, "children": [], "start_point": {"row": 129, "column": 1}, "end_point": {"row": 129, "column": 5}}, {"id": 39, "type": "field_identifier", "text": "interrupt_enable", "parent": 37, "children": [], "start_point": {"row": 129, "column": 6}, "end_point": {"row": 129, "column": 22}}, {"id": 40, "type": "declaration", "text": "void timer_get_config_defaults(struct timer_config *config);", "parent": 15, "children": [41, 42], "start_point": {"row": 136, "column": 0}, "end_point": {"row": 136, "column": 60}}, {"id": 41, "type": "primitive_type", "text": "void", "parent": 40, "children": [], "start_point": {"row": 136, "column": 0}, "end_point": {"row": 136, "column": 4}}, {"id": 42, "type": "function_declarator", "text": "timer_get_config_defaults(struct timer_config *config)", "parent": 40, "children": [43, 44], "start_point": {"row": 136, "column": 5}, "end_point": {"row": 136, "column": 59}}, {"id": 43, "type": "identifier", "text": "timer_get_config_defaults", "parent": 42, "children": [], "start_point": {"row": 136, "column": 5}, "end_point": {"row": 136, "column": 30}}, {"id": 44, "type": "parameter_list", "text": "(struct timer_config *config)", "parent": 42, "children": [45], "start_point": {"row": 136, "column": 30}, "end_point": {"row": 136, "column": 59}}, {"id": 45, "type": "parameter_declaration", "text": "struct timer_config *config", "parent": 44, "children": [46, 49], "start_point": {"row": 136, "column": 31}, "end_point": {"row": 136, "column": 58}}, {"id": 46, "type": "struct_specifier", "text": "struct timer_config", "parent": 45, "children": [47, 48], "start_point": {"row": 136, "column": 31}, "end_point": {"row": 136, "column": 50}}, {"id": 47, "type": "struct", "text": "struct", "parent": 46, "children": [], "start_point": {"row": 136, "column": 31}, "end_point": {"row": 136, "column": 37}}, {"id": 48, "type": "type_identifier", "text": "timer_config", "parent": 46, "children": [], "start_point": {"row": 136, "column": 38}, "end_point": {"row": 136, "column": 50}}, {"id": 49, "type": "pointer_declarator", "text": "*config", "parent": 45, "children": [50, 51], "start_point": {"row": 136, "column": 51}, "end_point": {"row": 136, "column": 58}}, {"id": 50, "type": "*", "text": "*", "parent": 49, "children": [], "start_point": {"row": 136, "column": 51}, "end_point": {"row": 136, "column": 52}}, {"id": 51, "type": "identifier", "text": "config", "parent": 49, "children": [], "start_point": {"row": 136, "column": 52}, "end_point": {"row": 136, "column": 58}}, {"id": 52, "type": "declaration", "text": "void timer_init(const struct timer_config *config);", "parent": 15, "children": [53, 54], "start_point": {"row": 137, "column": 0}, "end_point": {"row": 137, "column": 51}}, {"id": 53, "type": "primitive_type", "text": "void", "parent": 52, "children": [], "start_point": {"row": 137, "column": 0}, "end_point": {"row": 137, "column": 4}}, {"id": 54, "type": "function_declarator", "text": "timer_init(const struct timer_config *config)", "parent": 52, "children": [55, 56], "start_point": {"row": 137, "column": 5}, "end_point": {"row": 137, "column": 50}}, {"id": 55, "type": "identifier", "text": "timer_init", "parent": 54, "children": [], "start_point": {"row": 137, "column": 5}, "end_point": {"row": 137, "column": 15}}, {"id": 56, "type": "parameter_list", "text": "(const struct timer_config *config)", "parent": 54, "children": [57], "start_point": {"row": 137, "column": 15}, "end_point": {"row": 137, "column": 50}}, {"id": 57, "type": "parameter_declaration", "text": "const struct timer_config *config", "parent": 56, "children": [58, 61], "start_point": {"row": 137, "column": 16}, "end_point": {"row": 137, "column": 49}}, {"id": 58, "type": "struct_specifier", "text": "struct timer_config", "parent": 57, "children": [59, 60], "start_point": {"row": 137, "column": 22}, "end_point": {"row": 137, "column": 41}}, {"id": 59, "type": "struct", "text": "struct", "parent": 58, "children": [], "start_point": {"row": 137, "column": 22}, "end_point": {"row": 137, "column": 28}}, {"id": 60, "type": "type_identifier", "text": "timer_config", "parent": 58, "children": [], "start_point": {"row": 137, "column": 29}, "end_point": {"row": 137, "column": 41}}, {"id": 61, "type": "pointer_declarator", "text": "*config", "parent": 57, "children": [62, 63], "start_point": {"row": 137, "column": 42}, "end_point": {"row": 137, "column": 49}}, {"id": 62, "type": "*", "text": "*", "parent": 61, "children": [], "start_point": {"row": 137, "column": 42}, "end_point": {"row": 137, "column": 43}}, {"id": 63, "type": "identifier", "text": "config", "parent": 61, "children": [], "start_point": {"row": 137, "column": 43}, "end_point": {"row": 137, "column": 49}}, {"id": 64, "type": "declaration", "text": "uint32_t timer_get_value(void);", "parent": 15, "children": [65, 66], "start_point": {"row": 144, "column": 0}, "end_point": {"row": 144, "column": 31}}, {"id": 65, "type": "primitive_type", "text": "uint32_t", "parent": 64, "children": [], "start_point": {"row": 144, "column": 0}, "end_point": {"row": 144, "column": 8}}, {"id": 66, "type": "function_declarator", "text": "timer_get_value(void)", "parent": 64, "children": [67, 68], "start_point": {"row": 144, "column": 9}, "end_point": {"row": 144, "column": 30}}, {"id": 67, "type": "identifier", "text": "timer_get_value", "parent": 66, "children": [], "start_point": {"row": 144, "column": 9}, "end_point": {"row": 144, "column": 24}}, {"id": 68, "type": "parameter_list", "text": "(void)", "parent": 66, "children": [69], "start_point": {"row": 144, "column": 24}, "end_point": {"row": 144, "column": 30}}, {"id": 69, "type": "parameter_declaration", "text": "void", "parent": 68, "children": [70], "start_point": {"row": 144, "column": 25}, "end_point": {"row": 144, "column": 29}}, {"id": 70, "type": "primitive_type", "text": "void", "parent": 69, "children": [], "start_point": {"row": 144, "column": 25}, "end_point": {"row": 144, "column": 29}}, {"id": 71, "type": "declaration", "text": "void timer_set_value(uint32_t value);", "parent": 15, "children": [72, 73], "start_point": {"row": 145, "column": 0}, "end_point": {"row": 145, "column": 37}}, {"id": 72, "type": "primitive_type", "text": "void", "parent": 71, "children": [], "start_point": {"row": 145, "column": 0}, "end_point": {"row": 145, "column": 4}}, {"id": 73, "type": "function_declarator", "text": "timer_set_value(uint32_t value)", "parent": 71, "children": [74, 75], "start_point": {"row": 145, "column": 5}, "end_point": {"row": 145, "column": 36}}, {"id": 74, "type": "identifier", "text": "timer_set_value", "parent": 73, "children": [], "start_point": {"row": 145, "column": 5}, "end_point": {"row": 145, "column": 20}}, {"id": 75, "type": "parameter_list", "text": "(uint32_t value)", "parent": 73, "children": [76], "start_point": {"row": 145, "column": 20}, "end_point": {"row": 145, "column": 36}}, {"id": 76, "type": "parameter_declaration", "text": "uint32_t value", "parent": 75, "children": [77, 78], "start_point": {"row": 145, "column": 21}, "end_point": {"row": 145, "column": 35}}, {"id": 77, "type": "primitive_type", "text": "uint32_t", "parent": 76, "children": [], "start_point": {"row": 145, "column": 21}, "end_point": {"row": 145, "column": 29}}, {"id": 78, "type": "identifier", "text": "value", "parent": 76, "children": [], "start_point": {"row": 145, "column": 30}, "end_point": {"row": 145, "column": 35}}, {"id": 79, "type": "declaration", "text": "uint32_t timer_get_interrupt_status(void);", "parent": 15, "children": [80, 81], "start_point": {"row": 152, "column": 0}, "end_point": {"row": 152, "column": 42}}, {"id": 80, "type": "primitive_type", "text": "uint32_t", "parent": 79, "children": [], "start_point": {"row": 152, "column": 0}, "end_point": {"row": 152, "column": 8}}, {"id": 81, "type": "function_declarator", "text": "timer_get_interrupt_status(void)", "parent": 79, "children": [82, 83], "start_point": {"row": 152, "column": 9}, "end_point": {"row": 152, "column": 41}}, {"id": 82, "type": "identifier", "text": "timer_get_interrupt_status", "parent": 81, "children": [], "start_point": {"row": 152, "column": 9}, "end_point": {"row": 152, "column": 35}}, {"id": 83, "type": "parameter_list", "text": "(void)", "parent": 81, "children": [84], "start_point": {"row": 152, "column": 35}, "end_point": {"row": 152, "column": 41}}, {"id": 84, "type": "parameter_declaration", "text": "void", "parent": 83, "children": [85], "start_point": {"row": 152, "column": 36}, "end_point": {"row": 152, "column": 40}}, {"id": 85, "type": "primitive_type", "text": "void", "parent": 84, "children": [], "start_point": {"row": 152, "column": 36}, "end_point": {"row": 152, "column": 40}}, {"id": 86, "type": "declaration", "text": "void timer_clear_interrupt_status(void);", "parent": 15, "children": [87, 88], "start_point": {"row": 153, "column": 0}, "end_point": {"row": 153, "column": 40}}, {"id": 87, "type": "primitive_type", "text": "void", "parent": 86, "children": [], "start_point": {"row": 153, "column": 0}, "end_point": {"row": 153, "column": 4}}, {"id": 88, "type": "function_declarator", "text": "timer_clear_interrupt_status(void)", "parent": 86, "children": [89, 90], "start_point": {"row": 153, "column": 5}, "end_point": {"row": 153, "column": 39}}, {"id": 89, "type": "identifier", "text": "timer_clear_interrupt_status", "parent": 88, "children": [], "start_point": {"row": 153, "column": 5}, "end_point": {"row": 153, "column": 33}}, {"id": 90, "type": "parameter_list", "text": "(void)", "parent": 88, "children": [91], "start_point": {"row": 153, "column": 33}, "end_point": {"row": 153, "column": 39}}, {"id": 91, "type": "parameter_declaration", "text": "void", "parent": 90, "children": [92], "start_point": {"row": 153, "column": 34}, "end_point": {"row": 153, "column": 38}}, {"id": 92, "type": "primitive_type", "text": "void", "parent": 91, "children": [], "start_point": {"row": 153, "column": 34}, "end_point": {"row": 153, "column": 38}}, {"id": 93, "type": "declaration", "text": "void timer_enable(void);", "parent": 15, "children": [94, 95], "start_point": {"row": 160, "column": 0}, "end_point": {"row": 160, "column": 24}}, {"id": 94, "type": "primitive_type", "text": "void", "parent": 93, "children": [], "start_point": {"row": 160, "column": 0}, "end_point": {"row": 160, "column": 4}}, {"id": 95, "type": "function_declarator", "text": "timer_enable(void)", "parent": 93, "children": [96, 97], "start_point": {"row": 160, "column": 5}, "end_point": {"row": 160, "column": 23}}, {"id": 96, "type": "identifier", "text": "timer_enable", "parent": 95, "children": [], "start_point": {"row": 160, "column": 5}, "end_point": {"row": 160, "column": 17}}, {"id": 97, "type": "parameter_list", "text": "(void)", "parent": 95, "children": [98], "start_point": {"row": 160, "column": 17}, "end_point": {"row": 160, "column": 23}}, {"id": 98, "type": "parameter_declaration", "text": "void", "parent": 97, "children": [99], "start_point": {"row": 160, "column": 18}, "end_point": {"row": 160, "column": 22}}, {"id": 99, "type": "primitive_type", "text": "void", "parent": 98, "children": [], "start_point": {"row": 160, "column": 18}, "end_point": {"row": 160, "column": 22}}, {"id": 100, "type": "declaration", "text": "void timer_disable(void);", "parent": 15, "children": [101, 102], "start_point": {"row": 161, "column": 0}, "end_point": {"row": 161, "column": 25}}, {"id": 101, "type": "primitive_type", "text": "void", "parent": 100, "children": [], "start_point": {"row": 161, "column": 0}, "end_point": {"row": 161, "column": 4}}, {"id": 102, "type": "function_declarator", "text": "timer_disable(void)", "parent": 100, "children": [103, 104], "start_point": {"row": 161, "column": 5}, "end_point": {"row": 161, "column": 24}}, {"id": 103, "type": "identifier", "text": "timer_disable", "parent": 102, "children": [], "start_point": {"row": 161, "column": 5}, "end_point": {"row": 161, "column": 18}}, {"id": 104, "type": "parameter_list", "text": "(void)", "parent": 102, "children": [105], "start_point": {"row": 161, "column": 18}, "end_point": {"row": 161, "column": 24}}, {"id": 105, "type": "parameter_declaration", "text": "void", "parent": 104, "children": [106], "start_point": {"row": 161, "column": 19}, "end_point": {"row": 161, "column": 23}}, {"id": 106, "type": "primitive_type", "text": "void", "parent": 105, "children": [], "start_point": {"row": 161, "column": 19}, "end_point": {"row": 161, "column": 23}}, {"id": 107, "type": "declaration", "text": "void timer_register_callback(timer_callback_t fun);", "parent": 15, "children": [108, 109], "start_point": {"row": 168, "column": 0}, "end_point": {"row": 168, "column": 51}}, {"id": 108, "type": "primitive_type", "text": "void", "parent": 107, "children": [], "start_point": {"row": 168, "column": 0}, "end_point": {"row": 168, "column": 4}}, {"id": 109, "type": "function_declarator", "text": "timer_register_callback(timer_callback_t fun)", "parent": 107, "children": [110, 111], "start_point": {"row": 168, "column": 5}, "end_point": {"row": 168, "column": 50}}, {"id": 110, "type": "identifier", "text": "timer_register_callback", "parent": 109, "children": [], "start_point": {"row": 168, "column": 5}, "end_point": {"row": 168, "column": 28}}, {"id": 111, "type": "parameter_list", "text": "(timer_callback_t fun)", "parent": 109, "children": [112], "start_point": {"row": 168, "column": 28}, "end_point": {"row": 168, "column": 50}}, {"id": 112, "type": "parameter_declaration", "text": "timer_callback_t fun", "parent": 111, "children": [113, 114], "start_point": {"row": 168, "column": 29}, "end_point": {"row": 168, "column": 49}}, {"id": 113, "type": "type_identifier", "text": "timer_callback_t", "parent": 112, "children": [], "start_point": {"row": 168, "column": 29}, "end_point": {"row": 168, "column": 45}}, {"id": 114, "type": "identifier", "text": "fun", "parent": 112, "children": [], "start_point": {"row": 168, "column": 46}, "end_point": {"row": 168, "column": 49}}, {"id": 115, "type": "declaration", "text": "void timer_unregister_callback(void);", "parent": 15, "children": [116, 117], "start_point": {"row": 169, "column": 0}, "end_point": {"row": 169, "column": 37}}, {"id": 116, "type": "primitive_type", "text": "void", "parent": 115, "children": [], "start_point": {"row": 169, "column": 0}, "end_point": {"row": 169, "column": 4}}, {"id": 117, "type": "function_declarator", "text": "timer_unregister_callback(void)", "parent": 115, "children": [118, 119], "start_point": {"row": 169, "column": 5}, "end_point": {"row": 169, "column": 36}}, {"id": 118, "type": "identifier", "text": "timer_unregister_callback", "parent": 117, "children": [], "start_point": {"row": 169, "column": 5}, "end_point": {"row": 169, "column": 30}}, {"id": 119, "type": "parameter_list", "text": "(void)", "parent": 117, "children": [120], "start_point": {"row": 169, "column": 30}, "end_point": {"row": 169, "column": 36}}, {"id": 120, "type": "parameter_declaration", "text": "void", "parent": 119, "children": [121], "start_point": {"row": 169, "column": 31}, "end_point": {"row": 169, "column": 35}}, {"id": 121, "type": "primitive_type", "text": "void", "parent": 120, "children": [], "start_point": {"row": 169, "column": 31}, "end_point": {"row": 169, "column": 35}}, {"id": 122, "type": "preproc_ifdef", "text": "#ifdef __cplusplus", "parent": 15, "children": [123, 124, 125], "start_point": {"row": 174, "column": 0}, "end_point": {"row": 174, "column": 18}}, {"id": 123, "type": "#ifdef", "text": "#ifdef", "parent": 122, "children": [], "start_point": {"row": 174, "column": 0}, "end_point": {"row": 174, "column": 6}}, {"id": 124, "type": "identifier", "text": "__cplusplus", "parent": 122, "children": [], "start_point": {"row": 174, "column": 7}, "end_point": {"row": 174, "column": 18}}, {"id": 125, "type": "#endif", "text": "", "parent": 122, "children": [], "start_point": {"row": 174, "column": 18}, "end_point": {"row": 174, "column": 18}}, {"id": 126, "type": "#endif", "text": "#endif", "parent": 12, "children": [], "start_point": {"row": 176, "column": 0}, "end_point": {"row": 176, "column": 6}}, {"id": 127, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 246, "column": 0}, "end_point": {"row": 246, "column": 6}}]}, "node_categories": {"declarations": {"functions": [23, 42, 54, 66, 73, 81, 88, 95, 102, 109, 117], "variables": [20, 29, 34, 37, 40, 45, 52, 57, 64, 69, 71, 76, 79, 84, 86, 91, 93, 98, 100, 105, 107, 112, 115, 120], "classes": [31, 32, 46, 47, 58, 59], "imports": [6, 7, 9, 10], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 12, 13, 14, 15, 27, 33, 36, 39, 43, 48, 51, 55, 60, 63, 67, 74, 78, 82, 89, 96, 103, 110, 113, 114, 118, 122, 123, 124, 125, 126, 127], "returns": [], "exceptions": []}, "expressions": {"calls": [18], "literals": [8, 11, 17], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 23, "universal_type": "function", "name": "unknown", "text_snippet": "(*timer_callback_t)(void)"}, {"node_id": 42, "universal_type": "function", "name": "unknown", "text_snippet": "timer_get_config_defaults(struct timer_config *config)"}, {"node_id": 54, "universal_type": "function", "name": "timer_config", "text_snippet": "timer_init(const struct timer_config *config)"}, {"node_id": 66, "universal_type": "function", "name": "unknown", "text_snippet": "timer_get_value(void)"}, {"node_id": 73, "universal_type": "function", "name": "unknown", "text_snippet": "timer_set_value(uint32_t value)"}, {"node_id": 81, "universal_type": "function", "name": "unknown", "text_snippet": "timer_get_interrupt_status(void)"}, {"node_id": 88, "universal_type": "function", "name": "unknown", "text_snippet": "timer_clear_interrupt_status(void)"}, {"node_id": 95, "universal_type": "function", "name": "unknown", "text_snippet": "timer_enable(void)"}, {"node_id": 102, "universal_type": "function", "name": "unknown", "text_snippet": "timer_disable(void)"}, {"node_id": 109, "universal_type": "function", "name": "unknown", "text_snippet": "timer_register_callback(timer_callback_t fun)"}, {"node_id": 117, "universal_type": "function", "name": "unknown", "text_snippet": "timer_unregister_callback(void)"}], "class_declarations": [{"node_id": 31, "universal_type": "class", "name": "timer_config", "text_snippet": "struct timer_config {\n\t/** Reload value */\n\tuint32_t reload_value;\n\t/** Enable timer interrupt */\n\tb"}, {"node_id": 32, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 46, "universal_type": "class", "name": "timer_config", "text_snippet": "struct timer_config"}, {"node_id": 47, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 58, "universal_type": "class", "name": "timer_config", "text_snippet": "struct timer_config"}, {"node_id": 59, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": [{"node_id": 6, "text": "#include <compiler.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <system_sam_b.h>\n"}, {"node_id": 10, "text": "#include"}]}, "original_source_code": "/**\n * \\file\n *\n * \\brief SAM TIMER Driver for SAMB11\n *\n * Copyright (c) 2015-2018 Microchip Technology Inc. and its subsidiaries.\n *\n * \\asf_license_start\n *\n * \\page License\n *\n * Subject to your compliance with these terms, you may use Microchip\n * software and any derivatives exclusively with Microchip products.\n * It is your responsibility to comply with third party license terms applicable\n * to your use of third party software (including open source software) that\n * may accompany Microchip software.\n *\n * THIS SOFTWARE IS SUPPLIED BY MICROCHIP \"AS IS\". NO WARRANTIES,\n * WHETHER EXPRESS, IMPLIED OR STATUTORY, APPLY TO THIS SOFTWARE,\n * INCLUDING ANY IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY,\n * AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT WILL MICROCHIP BE\n * LIABLE FOR ANY INDIRECT, SPECIAL, PUNITIVE, INCIDENTAL OR CONSEQUENTIAL\n * LOSS, DAMAGE, COST OR EXPENSE OF ANY KIND WHATSOEVER RELATED TO THE\n * SOFTWARE, HOWEVER CAUSED, EVEN IF MICROCHIP HAS BEEN ADVISED OF THE\n * POSSIBILITY OR THE DAMAGES ARE FORESEEABLE. TO THE FULLEST EXTENT\n * ALLOWED BY LAW, MICROCHIP'S TOTAL LIABILITY ON ALL CLAIMS IN ANY WAY\n * RELATED TO THIS SOFTWARE WILL NOT EXCEED THE AMOUNT OF FEES, IF ANY,\n * THAT YOU HAVE PAID DIRECTLY TO MICROCHIP FOR THIS SOFTWARE.\n *\n * \\asf_license_stop\n *\n */\n/*\n * Support and FAQ: visit <a href=\"https://www.microchip.com/support/\">Microchip Support</a>\n */\n#ifndef TIMER_H_INCLUDED\n#define TIMER_H_INCLUDED\n\n/**\n * \\defgroup asfdoc_samb_timer_group SAM TIMER\n *\n * This driver for Atmel&reg; | SMART SAM devices provides an interface for the\n * configuration and management of the device's basic Timer functionality.\n *\n * The following peripherals are used by this module:\n * - TIMER\n *\n * The following devices can use this module:\n * - Atmel | SMART SAM B11\n *\n * The outline of this documentation is as follows:\n * - \\ref asfdoc_samb_timer_prerequisites\n * - \\ref asfdoc_samb_timer_module_overview\n * - \\ref asfdoc_samb_timer_special_considerations\n * - \\ref asfdoc_samb_timer_extra_info\n * - \\ref asfdoc_samb_timer_examples\n * - \\ref asfdoc_samb_timer_api_overview\n *\n *\n * \\section asfdoc_samb_timer_prerequisites Prerequisites\n *\n * There are no prerequisites for this module.\n *\n *\n * \\section asfdoc_samb_timer_module_overview Module Overview\n * This driver proiveds a basic timer for count, is a 32-bit\n * down-counter with the following features:\n *\n * - You can generate an interrupt request signal, TIMERINT,\n * when the counter reaches 0.\n \n * - The interrupt request is held until it is cleared by writing to the INTCLEAR Register.\n *\n * - You can use the zero to one transition of the external input signal, EXTIN, as a timer enable.\n *\n * - If the APB timer count reaches 0 and, at the same time, the software clears a previous\n * interrupt status, the interrupt status is set to 1.\n *\n * - The external clock, EXTIN, must be slower than half of the peripheral clock because it is\n * sampled by a double flip-flop and then goes through edge-detection logic when the\n * external inputs act as a clock. \n *\n * - A separate clock pin, PCLKG, for the APB register read or write logic that permits the\n * clock to peripheral register logic to stop when there is no APB activity.\n *\n * \\section asfdoc_samb_timer_special_considerations Special Considerations\n *\n * There are no prerequisites for this module.\n *\n * \\section asfdoc_samb_timer_extra_info Extra Information\n *\n * For extra information, see \\ref asfdoc_samb_timer_extra. This includes:\n * - \\ref asfdoc_samb_timer_extra_acronyms\n * - \\ref asfdoc_samb_timer_extra_dependencies\n * - \\ref asfdoc_samb_timer_extra_errata\n * - \\ref asfdoc_samb_timer_extra_history\n *\n *\n * \\section asfdoc_samb_timer_examples Examples\n *\n * For a list of examples related to this driver, see\n * \\ref asfdoc_samb_timer_exqsg.\n *\n *\n * \\section asfdoc_samb_timer_api_overview API Overview\n * @{\n */\n\n#include <compiler.h>\n#include <system_sam_b.h>\n\n#ifdef __cplusplus\nextern \"C\" {\n#endif\n\n/** Type definition for a TIMER module callback function. */\ntypedef void (*timer_callback_t)(void);\n\n/**\n * \\brief TIMER configuration structure.\n *\n * Configuration struct for a TIMER instance. This structure should be\n * initialized by the \\ref timer_get_config_defaults function before being\n * modified by the user application.\n */\nstruct timer_config {\n\t/** Reload value */\n\tuint32_t reload_value;\n\t/** Enable timer interrupt */\n\tbool interrupt_enable;\n};\n\n/**\n * \\name Configuration and Initialization\n * @{\n */\nvoid timer_get_config_defaults(struct timer_config *config);\nvoid timer_init(const struct timer_config *config);\n/** @} */\n\n/**\n * \\name Get and set value\n * @{\n */\nuint32_t timer_get_value(void);\nvoid timer_set_value(uint32_t value);\n/** @} */\n\n/**\n * \\name Get and Clear status\n * @{\n */\nuint32_t timer_get_interrupt_status(void);\nvoid timer_clear_interrupt_status(void);\n/** @} */\n\n/**\n * \\name Enable and disable module\n * @{\n */\nvoid timer_enable(void);\nvoid timer_disable(void);\n/** @} */\n\n/**\n * \\name Callback\n * @{\n */\nvoid timer_register_callback(timer_callback_t fun);\nvoid timer_unregister_callback(void);\n/** @} */\n\n/** @}*/\n\n#ifdef __cplusplus\n}\n#endif\n\n/**\n * \\page asfdoc_samb_timer_extra Extra Information for TIMER Driver\n *\n * \\section asfdoc_samb_timer_extra_acronyms Acronyms\n * Below is a table listing the acronyms used in this module, along with their\n * intended meanings.\n * <table>\n *\t<tr>\n *\t\t<th>Acronym</th>\n *\t\t<th>Description</th>\n *\t</tr>\n *\t<tr>\n *\t\t<td>TIMER</td>\n *\t\t<td>Timer</td>\n *\t</tr>\n * </table>\n *\n * \\section asfdoc_samb_timer_extra_dependencies Dependencies\n * There are no dependencies related to this driver.\n *\n *\n * \\section asfdoc_samb_timer_extra_errata Errata\n * There are no errata related to this driver.\n *\n *\n * \\section asfdoc_samb_timer_extra_history Module History\n * An overview of the module history is presented in the table below, with\n * details on the enhancements and fixes made to the module since its first\n * release. The current version of this corresponds to the newest version in\n * the table.\n *\n * <table>\n * <tr>\n * <th>Changelog</th>\n * </tr>\n * <tr>\n * <td>Initial Release</td>\n * </tr>\n * </table>\n */\n\n/**\n * \\page asfdoc_samb_timer_exqsg Examples for TIMER Driver\n *\n * This is a list of the available Quick Start guides (QSGs) and example\n * applications for \\ref asfdoc_samb_timer_group. QSGs are simple examples with\n * step-by-step instructions to configure and use this driver in a selection of\n * use cases. Note that QSGs can be compiled as a standalone application or be\n * added to the user application.\n *\n * - \\subpage asfdoc_samb_timer_basic_use_case\n *\n * \\page asfdoc_samb_timer_document_revision_history Document Revision History\n *\n * <table>\n * <tr>\n * <th>Doc. Rev.</td>\n * <th>Date</td>\n * <th>Comments</td>\n * </tr>\n * <tr>\n * <td>A</td>\n * <td>09/2015</td>\n * <td>Initial release</td>\n * </tr>\n * </table>\n */\n\n#endif"}
80,532
c
/** * Copyright 2021 Huawei Technologies Co., Ltd * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ #ifndef MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_ #define MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_ #include <functional> #include <queue> #include <mutex> #include <vector> #include <thread> #include <condition_variable> #include "utils/log_adapter.h" #include "ps/constants.h" namespace mindspore { namespace ps { namespace core { /* This class can submit tasks in multiple threads * example: * void TestTaskExecutor() { * std::cout << "Execute in one thread"; * } * * TaskExecutor executor(10); // 10 threads * executor.Submit(TestTaskExecutor, this); // Submit task */ class TaskExecutor { public: explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum, size_t submit_timeout = kSubmitTimeOutInMs); ~TaskExecutor(); // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent // tasks unitl timeout. template <typename Fun, typename... Args> bool Submit(Fun &&function, Args &&... args) { auto callee = std::bind(function, args...); std::function<void()> task = [callee]() -> void { callee(); }; size_t index = 0; for (size_t i = 0; i < submit_timeout_; i++) { std::unique_lock<std::mutex> lock(mtx_); if (task_num_ >= max_task_num_) { lock.unlock(); std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs)); index++; } else { break; } } if (index >= submit_timeout_) { MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms."; return false; } std::unique_lock<std::mutex> lock(mtx_); task_num_++; task_queue_.push(task); return true; } private: bool running_; // The number of tasks actually running size_t thread_num_; // The number of idle threads that can execute tasks size_t idle_thread_num_; // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds. size_t submit_timeout_; // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or // timeout. size_t max_task_num_; // The number of currently submitted to the task queue size_t task_num_; std::thread notify_thread_; std::mutex mtx_; std::condition_variable cv_; std::vector<std::thread> working_threads_; std::queue<std::function<void()>> task_queue_; }; } // namespace core } // namespace ps } // namespace mindspore #endif // MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_
35.02
92
(translation_unit) "/**\n * Copyright 2021 Huawei Technologies Co., Ltd\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n#ifndef MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_\n#define MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_\n\n#include <functional>\n#include <queue>\n#include <mutex>\n#include <vector>\n#include <thread>\n#include <condition_variable>\n\n#include "utils/log_adapter.h"\n#include "ps/constants.h"\n\nnamespace mindspore {\nnamespace ps {\nnamespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << "Execute in one thread";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */\nclass TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n};\n} // namespace core\n} // namespace ps\n} // namespace mindspore\n#endif // MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_\n" (comment) "/**\n * Copyright 2021 Huawei Technologies Co., Ltd\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */" (preproc_ifdef) "#ifndef MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_\n#define MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_\n\n#include <functional>\n#include <queue>\n#include <mutex>\n#include <vector>\n#include <thread>\n#include <condition_variable>\n\n#include "utils/log_adapter.h"\n#include "ps/constants.h"\n\nnamespace mindspore {\nnamespace ps {\nnamespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << "Execute in one thread";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */\nclass TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n};\n} // namespace core\n} // namespace ps\n} // namespace mindspore\n#endif" (#ifndef) "#ifndef" (identifier) "MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_" (preproc_def) "#define MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_\n" (#define) "#define" (identifier) "MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_" (preproc_include) "#include <functional>\n" (#include) "#include" (system_lib_string) "<functional>" (preproc_include) "#include <queue>\n" (#include) "#include" (system_lib_string) "<queue>" (preproc_include) "#include <mutex>\n" (#include) "#include" (system_lib_string) "<mutex>" (preproc_include) "#include <vector>\n" (#include) "#include" (system_lib_string) "<vector>" (preproc_include) "#include <thread>\n" (#include) "#include" (system_lib_string) "<thread>" (preproc_include) "#include <condition_variable>\n" (#include) "#include" (system_lib_string) "<condition_variable>" (preproc_include) "#include "utils/log_adapter.h"\n" (#include) "#include" (string_literal) ""utils/log_adapter.h"" (") """ (string_content) "utils/log_adapter.h" (") """ (preproc_include) "#include "ps/constants.h"\n" (#include) "#include" (string_literal) ""ps/constants.h"" (") """ (string_content) "ps/constants.h" (") """ (function_definition) "namespace mindspore {\nnamespace ps {\nnamespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << "Execute in one thread";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */\nclass TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n};\n} // namespace core\n} // namespace ps\n}" (type_identifier) "namespace" (identifier) "mindspore" (compound_statement) "{\nnamespace ps {\nnamespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << "Execute in one thread";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */\nclass TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n};\n} // namespace core\n} // namespace ps\n}" ({) "{" (function_definition) "namespace ps {\nnamespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << "Execute in one thread";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */\nclass TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n};\n} // namespace core\n}" (type_identifier) "namespace" (identifier) "ps" (compound_statement) "{\nnamespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << "Execute in one thread";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */\nclass TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n};\n} // namespace core\n}" ({) "{" (function_definition) "namespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << "Execute in one thread";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */\nclass TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n};\n}" (type_identifier) "namespace" (identifier) "core" (compound_statement) "{\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << "Execute in one thread";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */\nclass TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n};\n}" ({) "{" (comment) "/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << "Execute in one thread";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */" (function_definition) "class TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n}" (type_identifier) "class" (identifier) "TaskExecutor" (compound_statement) "{\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n}" ({) "{" (labeled_statement) "public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);" (statement_identifier) "public" (:) ":" (declaration) "explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);" (type_identifier) "explicit" (function_declarator) "TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs)" (identifier) "TaskExecutor" (parameter_list) "(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs)" (() "(" (parameter_declaration) "size_t thread_num" (primitive_type) "size_t" (identifier) "thread_num" (,) "," (parameter_declaration) "size_t max_task_num = kMaxTaskNum" (primitive_type) "size_t" (ERROR) "max_task_num =" (identifier) "max_task_num" (=) "=" (identifier) "kMaxTaskNum" (,) "," (parameter_declaration) "size_t submit_timeout = kSubmitTimeOutInMs" (primitive_type) "size_t" (ERROR) "submit_timeout =" (identifier) "submit_timeout" (=) "=" (identifier) "kSubmitTimeOutInMs" ()) ")" (;) ";" (expression_statement) "~TaskExecutor();" (unary_expression) "~TaskExecutor()" (~) "~" (call_expression) "TaskExecutor()" (identifier) "TaskExecutor" (argument_list) "()" (() "(" ()) ")" (;) ";" (comment) "// If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent" (comment) "// tasks unitl timeout." (expression_statement) "template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args)" (comma_expression) "template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args)" (binary_expression) "template <typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "Fun" (identifier) "Fun" (,) "," (binary_expression) "typename... Args>\n bool Submit(Fun &&function, Args &&... args)" (identifier) "typename" (ERROR) "... Args" (...) "..." (identifier) "Args" (>) ">" (ERROR) "bool" (identifier) "bool" (call_expression) "Submit(Fun &&function, Args &&... args)" (identifier) "Submit" (argument_list) "(Fun &&function, Args &&... args)" (() "(" (binary_expression) "Fun &&function" (identifier) "Fun" (&&) "&&" (identifier) "function" (,) "," (binary_expression) "Args &&... args" (identifier) "Args" (&&) "&&" (ERROR) "..." (.) "." (.) "." (.) "." (identifier) "args" ()) ")" (;) "" (compound_statement) "{\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }" ({) "{" (declaration) "auto callee = std::bind(function, args...);" (storage_class_specifier) "auto" (auto) "auto" (type_identifier) "callee" (ERROR) "= std::" (=) "=" (identifier) "std" (:) ":" (:) ":" (function_declarator) "bind(function, args...)" (identifier) "bind" (parameter_list) "(function, args...)" (() "(" (ERROR) "function, args" (identifier) "function" (,) "," (identifier) "args" (variadic_parameter) "..." (...) "..." ()) ")" (;) ";" (labeled_statement) "std::function<void()> task = [callee]() -> void { callee(); }" (statement_identifier) "std" (:) ":" (ERROR) ":function<void()> task = [callee]() -> void" (:) ":" (binary_expression) "function<void()> task = [callee]() -> void" (binary_expression) "function<void()" (identifier) "function" (<) "<" (call_expression) "void()" (identifier) "void" (argument_list) "()" (() "(" ()) ")" (>) ">" (field_expression) "task = [callee]() -> void" (call_expression) "task = [callee]()" (subscript_expression) "task = [callee]" (identifier) "task" (ERROR) "=" (=) "=" ([) "[" (identifier) "callee" (]) "]" (argument_list) "()" (() "(" ()) ")" (->) "->" (field_identifier) "void" (compound_statement) "{ callee(); }" ({) "{" (expression_statement) "callee();" (call_expression) "callee()" (identifier) "callee" (argument_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (declaration) "size_t index = 0;" (primitive_type) "size_t" (init_declarator) "index = 0" (identifier) "index" (=) "=" (number_literal) "0" (;) ";" (for_statement) "for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }" (for) "for" (() "(" (declaration) "size_t i = 0;" (primitive_type) "size_t" (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i < submit_timeout_" (identifier) "i" (<) "<" (identifier) "submit_timeout_" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (compound_statement) "{\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }" ({) "{" (labeled_statement) "std::unique_lock<std::mutex> lock(mtx_);" (statement_identifier) "std" (ERROR) "::unique_lock<std:" (:) ":" (:) ":" (binary_expression) "unique_lock<std" (identifier) "unique_lock" (<) "<" (identifier) "std" (:) ":" (:) ":" (expression_statement) "mutex> lock(mtx_);" (binary_expression) "mutex> lock(mtx_)" (identifier) "mutex" (>) ">" (call_expression) "lock(mtx_)" (identifier) "lock" (argument_list) "(mtx_)" (() "(" (identifier) "mtx_" ()) ")" (;) ";" (if_statement) "if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }" (if) "if" (parenthesized_expression) "(task_num_ >= max_task_num_)" (() "(" (binary_expression) "task_num_ >= max_task_num_" (identifier) "task_num_" (>=) ">=" (identifier) "max_task_num_" ()) ")" (compound_statement) "{\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n }" ({) "{" (expression_statement) "lock.unlock();" (call_expression) "lock.unlock()" (field_expression) "lock.unlock" (identifier) "lock" (.) "." (field_identifier) "unlock" (argument_list) "()" (() "(" ()) ")" (;) ";" (labeled_statement) "std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (labeled_statement) "this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));" (statement_identifier) "this_thread" (:) ":" (ERROR) ":" (:) ":" (labeled_statement) "sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));" (statement_identifier) "sleep_for" (ERROR) "(std:" (() "(" (type_descriptor) "std" (type_identifier) "std" (:) ":" (:) ":" (labeled_statement) "chrono::milliseconds(kSubmitTaskIntervalInMs));" (statement_identifier) "chrono" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "milliseconds(kSubmitTaskIntervalInMs));" (call_expression) "milliseconds(kSubmitTaskIntervalInMs)" (identifier) "milliseconds" (argument_list) "(kSubmitTaskIntervalInMs)" (() "(" (identifier) "kSubmitTaskIntervalInMs" ()) ")" (ERROR) ")" ()) ")" (;) ";" (expression_statement) "index++;" (update_expression) "index++" (identifier) "index" (++) "++" (;) ";" (}) "}" (else_clause) "else {\n break;\n }" (else) "else" (compound_statement) "{\n break;\n }" ({) "{" (break_statement) "break;" (break) "break" (;) ";" (}) "}" (}) "}" (if_statement) "if (index >= submit_timeout_) {\n MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";\n return false;\n }" (if) "if" (parenthesized_expression) "(index >= submit_timeout_)" (() "(" (binary_expression) "index >= submit_timeout_" (identifier) "index" (>=) ">=" (identifier) "submit_timeout_" ()) ")" (compound_statement) "{\n MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";\n return false;\n }" ({) "{" (expression_statement) "MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms.";" (binary_expression) "MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_ << " ms."" (binary_expression) "MS_LOG(WARNING) << "Submit task failed after " << submit_timeout_" (binary_expression) "MS_LOG(WARNING) << "Submit task failed after "" (call_expression) "MS_LOG(WARNING)" (identifier) "MS_LOG" (argument_list) "(WARNING)" (() "(" (identifier) "WARNING" ()) ")" (<<) "<<" (string_literal) ""Submit task failed after "" (") """ (string_content) "Submit task failed after " (") """ (<<) "<<" (identifier) "submit_timeout_" (<<) "<<" (string_literal) "" ms."" (") """ (string_content) " ms." (") """ (;) ";" (return_statement) "return false;" (return) "return" (false) "false" (;) ";" (}) "}" (labeled_statement) "std::unique_lock<std::mutex> lock(mtx_);" (statement_identifier) "std" (ERROR) "::unique_lock<std:" (:) ":" (:) ":" (binary_expression) "unique_lock<std" (identifier) "unique_lock" (<) "<" (identifier) "std" (:) ":" (:) ":" (expression_statement) "mutex> lock(mtx_);" (binary_expression) "mutex> lock(mtx_)" (identifier) "mutex" (>) ">" (call_expression) "lock(mtx_)" (identifier) "lock" (argument_list) "(mtx_)" (() "(" (identifier) "mtx_" ()) ")" (;) ";" (expression_statement) "task_num_++;" (update_expression) "task_num_++" (identifier) "task_num_" (++) "++" (;) ";" (expression_statement) "task_queue_.push(task);" (call_expression) "task_queue_.push(task)" (field_expression) "task_queue_.push" (identifier) "task_queue_" (.) "." (field_identifier) "push" (argument_list) "(task)" (() "(" (identifier) "task" ()) ")" (;) ";" (return_statement) "return true;" (return) "return" (true) "true" (;) ";" (}) "}" (labeled_statement) "private:\n bool running_;" (statement_identifier) "private" (:) ":" (declaration) "bool running_;" (primitive_type) "bool" (identifier) "running_" (;) ";" (comment) "// The number of tasks actually running" (declaration) "size_t thread_num_;" (primitive_type) "size_t" (identifier) "thread_num_" (;) ";" (comment) "// The number of idle threads that can execute tasks" (declaration) "size_t idle_thread_num_;" (primitive_type) "size_t" (identifier) "idle_thread_num_" (;) ";" (comment) "// The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds." (declaration) "size_t submit_timeout_;" (primitive_type) "size_t" (identifier) "submit_timeout_" (;) ";" (comment) "// The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this" (comment) "// max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or" (comment) "// timeout." (declaration) "size_t max_task_num_;" (primitive_type) "size_t" (identifier) "max_task_num_" (;) ";" (comment) "// The number of currently submitted to the task queue" (declaration) "size_t task_num_;" (primitive_type) "size_t" (identifier) "task_num_" (;) ";" (labeled_statement) "std::thread notify_thread_;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (declaration) "thread notify_thread_;" (type_identifier) "thread" (identifier) "notify_thread_" (;) ";" (labeled_statement) "std::mutex mtx_;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (declaration) "mutex mtx_;" (type_identifier) "mutex" (identifier) "mtx_" (;) ";" (labeled_statement) "std::condition_variable cv_;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (declaration) "condition_variable cv_;" (type_identifier) "condition_variable" (identifier) "cv_" (;) ";" (labeled_statement) "std::vector<std::thread> working_threads_;" (statement_identifier) "std" (ERROR) "::vector<std:" (:) ":" (:) ":" (binary_expression) "vector<std" (identifier) "vector" (<) "<" (identifier) "std" (:) ":" (:) ":" (expression_statement) "thread> working_threads_;" (binary_expression) "thread> working_threads_" (identifier) "thread" (>) ">" (identifier) "working_threads_" (;) ";" (labeled_statement) "std::queue<std::function<void()>> task_queue_;" (statement_identifier) "std" (ERROR) "::queue<std:" (:) ":" (:) ":" (binary_expression) "queue<std" (identifier) "queue" (<) "<" (identifier) "std" (:) ":" (:) ":" (expression_statement) "function<void()>> task_queue_;" (binary_expression) "function<void()>> task_queue_" (identifier) "function" (<) "<" (binary_expression) "void()>> task_queue_" (call_expression) "void()" (identifier) "void" (argument_list) "()" (() "(" ()) ")" (>>) ">>" (identifier) "task_queue_" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (}) "}" (comment) "// namespace core" (}) "}" (comment) "// namespace ps" (}) "}" (comment) "// namespace mindspore" (#endif) "#endif" (comment) "// MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_"
512
22
{"language": "c", "success": true, "metadata": {"lines": 92, "avg_line_length": 35.02, "nodes": 298, "errors": 0, "source_hash": "3cef6c3c540e51729c4e790217d8e1195ce14fd77895e28374e34047ca065aa3", "categorized_nodes": 203}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_\n#define MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_\n\n#include <functional>\n#include <queue>\n#include <mutex>\n#include <vector>\n#include <thread>\n#include <condition_variable>\n\n#include \"utils/log_adapter.h\"\n#include \"ps/constants.h\"\n\nnamespace mindspore {\nnamespace ps {\nnamespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << \"Execute in one thread\";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */\nclass TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << \"Submit task failed after \" << submit_timeout_ << \" ms.\";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n};\n} // namespace core\n} // namespace ps\n} // namespace mindspore\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 15, 18, 21, 24, 27, 30, 297], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 102, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 7}}, {"id": 2, "type": "identifier", "text": "MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_", "parent": 0, "children": [], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 61}}, {"id": 3, "type": "preproc_def", "text": "#define MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_\n", "parent": 0, "children": [4, 5], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 18, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 7}}, {"id": 5, "type": "identifier", "text": "MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_", "parent": 3, "children": [], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 17, "column": 61}}, {"id": 6, "type": "preproc_include", "text": "#include <functional>\n", "parent": 0, "children": [7, 8], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 20, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<functional>", "parent": 6, "children": [], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 21}}, {"id": 9, "type": "preproc_include", "text": "#include <queue>\n", "parent": 0, "children": [10, 11], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 21, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<queue>", "parent": 9, "children": [], "start_point": {"row": 20, "column": 9}, "end_point": {"row": 20, "column": 16}}, {"id": 12, "type": "preproc_include", "text": "#include <mutex>\n", "parent": 0, "children": [13, 14], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 22, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 8}}, {"id": 14, "type": "system_lib_string", "text": "<mutex>", "parent": 12, "children": [], "start_point": {"row": 21, "column": 9}, "end_point": {"row": 21, "column": 16}}, {"id": 15, "type": "preproc_include", "text": "#include <vector>\n", "parent": 0, "children": [16, 17], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 23, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 8}}, {"id": 17, "type": "system_lib_string", "text": "<vector>", "parent": 15, "children": [], "start_point": {"row": 22, "column": 9}, "end_point": {"row": 22, "column": 17}}, {"id": 18, "type": "preproc_include", "text": "#include <thread>\n", "parent": 0, "children": [19, 20], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 24, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 8}}, {"id": 20, "type": "system_lib_string", "text": "<thread>", "parent": 18, "children": [], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 17}}, {"id": 21, "type": "preproc_include", "text": "#include <condition_variable>\n", "parent": 0, "children": [22, 23], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 25, "column": 0}}, {"id": 22, "type": "#include", "text": "#include", "parent": 21, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 8}}, {"id": 23, "type": "system_lib_string", "text": "<condition_variable>", "parent": 21, "children": [], "start_point": {"row": 24, "column": 9}, "end_point": {"row": 24, "column": 29}}, {"id": 24, "type": "preproc_include", "text": "#include \"utils/log_adapter.h\"\n", "parent": 0, "children": [25, 26], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 27, "column": 0}}, {"id": 25, "type": "#include", "text": "#include", "parent": 24, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 8}}, {"id": 26, "type": "string_literal", "text": "\"utils/log_adapter.h\"", "parent": 24, "children": [], "start_point": {"row": 26, "column": 9}, "end_point": {"row": 26, "column": 30}}, {"id": 27, "type": "preproc_include", "text": "#include \"ps/constants.h\"\n", "parent": 0, "children": [28, 29], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 28, "column": 0}}, {"id": 28, "type": "#include", "text": "#include", "parent": 27, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 8}}, {"id": 29, "type": "string_literal", "text": "\"ps/constants.h\"", "parent": 27, "children": [], "start_point": {"row": 27, "column": 9}, "end_point": {"row": 27, "column": 25}}, {"id": 30, "type": "function_definition", "text": "namespace mindspore {\nnamespace ps {\nnamespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << \"Execute in one thread\";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */\nclass TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << \"Submit task failed after \" << submit_timeout_ << \" ms.\";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n};\n} // namespace core\n} // namespace ps\n}", "parent": 0, "children": [31, 32], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 101, "column": 1}}, {"id": 31, "type": "type_identifier", "text": "namespace", "parent": 30, "children": [], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 9}}, {"id": 32, "type": "identifier", "text": "mindspore", "parent": 30, "children": [], "start_point": {"row": 29, "column": 10}, "end_point": {"row": 29, "column": 19}}, {"id": 33, "type": "function_definition", "text": "namespace ps {\nnamespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << \"Execute in one thread\";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */\nclass TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << \"Submit task failed after \" << submit_timeout_ << \" ms.\";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n};\n} // namespace core\n}", "parent": 30, "children": [34, 35], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 100, "column": 1}}, {"id": 34, "type": "type_identifier", "text": "namespace", "parent": 33, "children": [], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 9}}, {"id": 35, "type": "identifier", "text": "ps", "parent": 33, "children": [], "start_point": {"row": 30, "column": 10}, "end_point": {"row": 30, "column": 12}}, {"id": 36, "type": "function_definition", "text": "namespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << \"Execute in one thread\";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */\nclass TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << \"Submit task failed after \" << submit_timeout_ << \" ms.\";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n};\n}", "parent": 33, "children": [37, 38], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 99, "column": 1}}, {"id": 37, "type": "type_identifier", "text": "namespace", "parent": 36, "children": [], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 31, "column": 9}}, {"id": 38, "type": "identifier", "text": "core", "parent": 36, "children": [], "start_point": {"row": 31, "column": 10}, "end_point": {"row": 31, "column": 14}}, {"id": 39, "type": "function_definition", "text": "class TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << \"Submit task failed after \" << submit_timeout_ << \" ms.\";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n}", "parent": 36, "children": [40], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 98, "column": 1}}, {"id": 40, "type": "identifier", "text": "TaskExecutor", "parent": 39, "children": [], "start_point": {"row": 41, "column": 6}, "end_point": {"row": 41, "column": 18}}, {"id": 41, "type": "labeled_statement", "text": "public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);", "parent": 39, "children": [42], "start_point": {"row": 42, "column": 1}, "end_point": {"row": 44, "column": 68}}, {"id": 42, "type": "declaration", "text": "explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);", "parent": 41, "children": [43, 44], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 44, "column": 68}}, {"id": 43, "type": "type_identifier", "text": "explicit", "parent": 42, "children": [], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 43, "column": 10}}, {"id": 44, "type": "function_declarator", "text": "TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs)", "parent": 42, "children": [45, 46], "start_point": {"row": 43, "column": 11}, "end_point": {"row": 44, "column": 67}}, {"id": 45, "type": "identifier", "text": "TaskExecutor", "parent": 44, "children": [], "start_point": {"row": 43, "column": 11}, "end_point": {"row": 43, "column": 23}}, {"id": 46, "type": "parameter_list", "text": "(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs)", "parent": 44, "children": [47, 50, 56], "start_point": {"row": 43, "column": 23}, "end_point": {"row": 44, "column": 67}}, {"id": 47, "type": "parameter_declaration", "text": "size_t thread_num", "parent": 46, "children": [48, 49], "start_point": {"row": 43, "column": 24}, "end_point": {"row": 43, "column": 41}}, {"id": 48, "type": "primitive_type", "text": "size_t", "parent": 47, "children": [], "start_point": {"row": 43, "column": 24}, "end_point": {"row": 43, "column": 30}}, {"id": 49, "type": "identifier", "text": "thread_num", "parent": 47, "children": [], "start_point": {"row": 43, "column": 31}, "end_point": {"row": 43, "column": 41}}, {"id": 50, "type": "parameter_declaration", "text": "size_t max_task_num = kMaxTaskNum", "parent": 46, "children": [51, 52, 55], "start_point": {"row": 43, "column": 43}, "end_point": {"row": 43, "column": 76}}, {"id": 51, "type": "primitive_type", "text": "size_t", "parent": 50, "children": [], "start_point": {"row": 43, "column": 43}, "end_point": {"row": 43, "column": 49}}, {"id": 52, "type": "ERROR", "text": "max_task_num =", "parent": 50, "children": [53, 54], "start_point": {"row": 43, "column": 50}, "end_point": {"row": 43, "column": 64}}, {"id": 53, "type": "identifier", "text": "max_task_num", "parent": 52, "children": [], "start_point": {"row": 43, "column": 50}, "end_point": {"row": 43, "column": 62}}, {"id": 54, "type": "=", "text": "=", "parent": 52, "children": [], "start_point": {"row": 43, "column": 63}, "end_point": {"row": 43, "column": 64}}, {"id": 55, "type": "identifier", "text": "kMaxTaskNum", "parent": 50, "children": [], "start_point": {"row": 43, "column": 65}, "end_point": {"row": 43, "column": 76}}, {"id": 56, "type": "parameter_declaration", "text": "size_t submit_timeout = kSubmitTimeOutInMs", "parent": 46, "children": [57, 58, 61], "start_point": {"row": 44, "column": 24}, "end_point": {"row": 44, "column": 66}}, {"id": 57, "type": "primitive_type", "text": "size_t", "parent": 56, "children": [], "start_point": {"row": 44, "column": 24}, "end_point": {"row": 44, "column": 30}}, {"id": 58, "type": "ERROR", "text": "submit_timeout =", "parent": 56, "children": [59, 60], "start_point": {"row": 44, "column": 31}, "end_point": {"row": 44, "column": 47}}, {"id": 59, "type": "identifier", "text": "submit_timeout", "parent": 58, "children": [], "start_point": {"row": 44, "column": 31}, "end_point": {"row": 44, "column": 45}}, {"id": 60, "type": "=", "text": "=", "parent": 58, "children": [], "start_point": {"row": 44, "column": 46}, "end_point": {"row": 44, "column": 47}}, {"id": 61, "type": "identifier", "text": "kSubmitTimeOutInMs", "parent": 56, "children": [], "start_point": {"row": 44, "column": 48}, "end_point": {"row": 44, "column": 66}}, {"id": 62, "type": "unary_expression", "text": "~TaskExecutor()", "parent": 39, "children": [63, 64], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 17}}, {"id": 63, "type": "~", "text": "~", "parent": 62, "children": [], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 3}}, {"id": 64, "type": "call_expression", "text": "TaskExecutor()", "parent": 62, "children": [65, 66], "start_point": {"row": 45, "column": 3}, "end_point": {"row": 45, "column": 17}}, {"id": 65, "type": "identifier", "text": "TaskExecutor", "parent": 64, "children": [], "start_point": {"row": 45, "column": 3}, "end_point": {"row": 45, "column": 15}}, {"id": 66, "type": "argument_list", "text": "()", "parent": 64, "children": [], "start_point": {"row": 45, "column": 15}, "end_point": {"row": 45, "column": 17}}, {"id": 67, "type": "comma_expression", "text": "template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args)", "parent": 39, "children": [68, 72, 74], "start_point": {"row": 49, "column": 2}, "end_point": {"row": 50, "column": 46}}, {"id": 68, "type": "binary_expression", "text": "template <typename", "parent": 67, "children": [69, 70, 71], "start_point": {"row": 49, "column": 2}, "end_point": {"row": 49, "column": 20}}, {"id": 69, "type": "identifier", "text": "template", "parent": 68, "children": [], "start_point": {"row": 49, "column": 2}, "end_point": {"row": 49, "column": 10}}, {"id": 70, "type": "<", "text": "<", "parent": 68, "children": [], "start_point": {"row": 49, "column": 11}, "end_point": {"row": 49, "column": 12}}, {"id": 71, "type": "identifier", "text": "typename", "parent": 68, "children": [], "start_point": {"row": 49, "column": 12}, "end_point": {"row": 49, "column": 20}}, {"id": 72, "type": "ERROR", "text": "Fun", "parent": 67, "children": [73], "start_point": {"row": 49, "column": 21}, "end_point": {"row": 49, "column": 24}}, {"id": 73, "type": "identifier", "text": "Fun", "parent": 72, "children": [], "start_point": {"row": 49, "column": 21}, "end_point": {"row": 49, "column": 24}}, {"id": 74, "type": "binary_expression", "text": "typename... Args>\n bool Submit(Fun &&function, Args &&... args)", "parent": 67, "children": [75, 76, 78, 79, 81], "start_point": {"row": 49, "column": 26}, "end_point": {"row": 50, "column": 46}}, {"id": 75, "type": "identifier", "text": "typename", "parent": 74, "children": [], "start_point": {"row": 49, "column": 26}, "end_point": {"row": 49, "column": 34}}, {"id": 76, "type": "ERROR", "text": "... Args", "parent": 74, "children": [77], "start_point": {"row": 49, "column": 34}, "end_point": {"row": 49, "column": 42}}, {"id": 77, "type": "identifier", "text": "Args", "parent": 76, "children": [], "start_point": {"row": 49, "column": 38}, "end_point": {"row": 49, "column": 42}}, {"id": 78, "type": ">", "text": ">", "parent": 74, "children": [], "start_point": {"row": 49, "column": 42}, "end_point": {"row": 49, "column": 43}}, {"id": 79, "type": "ERROR", "text": "bool", "parent": 74, "children": [80], "start_point": {"row": 50, "column": 2}, "end_point": {"row": 50, "column": 6}}, {"id": 80, "type": "identifier", "text": "bool", "parent": 79, "children": [], "start_point": {"row": 50, "column": 2}, "end_point": {"row": 50, "column": 6}}, {"id": 81, "type": "call_expression", "text": "Submit(Fun &&function, Args &&... args)", "parent": 74, "children": [82, 83], "start_point": {"row": 50, "column": 7}, "end_point": {"row": 50, "column": 46}}, {"id": 82, "type": "identifier", "text": "Submit", "parent": 81, "children": [], "start_point": {"row": 50, "column": 7}, "end_point": {"row": 50, "column": 13}}, {"id": 83, "type": "argument_list", "text": "(Fun &&function, Args &&... args)", "parent": 81, "children": [84, 87], "start_point": {"row": 50, "column": 13}, "end_point": {"row": 50, "column": 46}}, {"id": 84, "type": "binary_expression", "text": "Fun &&function", "parent": 83, "children": [85, 86], "start_point": {"row": 50, "column": 14}, "end_point": {"row": 50, "column": 28}}, {"id": 85, "type": "identifier", "text": "Fun", "parent": 84, "children": [], "start_point": {"row": 50, "column": 14}, "end_point": {"row": 50, "column": 17}}, {"id": 86, "type": "&&", "text": "&&", "parent": 84, "children": [], "start_point": {"row": 50, "column": 18}, "end_point": {"row": 50, "column": 20}}, {"id": 87, "type": "binary_expression", "text": "Args &&... args", "parent": 83, "children": [88, 89, 90], "start_point": {"row": 50, "column": 30}, "end_point": {"row": 50, "column": 45}}, {"id": 88, "type": "identifier", "text": "Args", "parent": 87, "children": [], "start_point": {"row": 50, "column": 30}, "end_point": {"row": 50, "column": 34}}, {"id": 89, "type": "&&", "text": "&&", "parent": 87, "children": [], "start_point": {"row": 50, "column": 35}, "end_point": {"row": 50, "column": 37}}, {"id": 90, "type": "identifier", "text": "args", "parent": 87, "children": [], "start_point": {"row": 50, "column": 41}, "end_point": {"row": 50, "column": 45}}, {"id": 91, "type": "declaration", "text": "auto callee = std::bind(function, args...);", "parent": 39, "children": [92, 94, 95, 98], "start_point": {"row": 51, "column": 4}, "end_point": {"row": 51, "column": 47}}, {"id": 92, "type": "storage_class_specifier", "text": "auto", "parent": 91, "children": [93], "start_point": {"row": 51, "column": 4}, "end_point": {"row": 51, "column": 8}}, {"id": 93, "type": "auto", "text": "auto", "parent": 92, "children": [], "start_point": {"row": 51, "column": 4}, "end_point": {"row": 51, "column": 8}}, {"id": 94, "type": "type_identifier", "text": "callee", "parent": 91, "children": [], "start_point": {"row": 51, "column": 9}, "end_point": {"row": 51, "column": 15}}, {"id": 95, "type": "ERROR", "text": "= std::", "parent": 91, "children": [96, 97], "start_point": {"row": 51, "column": 16}, "end_point": {"row": 51, "column": 23}}, {"id": 96, "type": "=", "text": "=", "parent": 95, "children": [], "start_point": {"row": 51, "column": 16}, "end_point": {"row": 51, "column": 17}}, {"id": 97, "type": "identifier", "text": "std", "parent": 95, "children": [], "start_point": {"row": 51, "column": 18}, "end_point": {"row": 51, "column": 21}}, {"id": 98, "type": "function_declarator", "text": "bind(function, args...)", "parent": 91, "children": [99, 100], "start_point": {"row": 51, "column": 23}, "end_point": {"row": 51, "column": 46}}, {"id": 99, "type": "identifier", "text": "bind", "parent": 98, "children": [], "start_point": {"row": 51, "column": 23}, "end_point": {"row": 51, "column": 27}}, {"id": 100, "type": "parameter_list", "text": "(function, args...)", "parent": 98, "children": [101], "start_point": {"row": 51, "column": 27}, "end_point": {"row": 51, "column": 46}}, {"id": 101, "type": "ERROR", "text": "function, args", "parent": 100, "children": [102], "start_point": {"row": 51, "column": 28}, "end_point": {"row": 51, "column": 42}}, {"id": 102, "type": "identifier", "text": "args", "parent": 101, "children": [], "start_point": {"row": 51, "column": 38}, "end_point": {"row": 51, "column": 42}}, {"id": 103, "type": "labeled_statement", "text": "std::function<void()> task = [callee]() -> void { callee(); }", "parent": 39, "children": [104, 105], "start_point": {"row": 52, "column": 4}, "end_point": {"row": 52, "column": 65}}, {"id": 104, "type": "statement_identifier", "text": "std", "parent": 103, "children": [], "start_point": {"row": 52, "column": 4}, "end_point": {"row": 52, "column": 7}}, {"id": 105, "type": "ERROR", "text": ":function<void()> task = [callee]() -> void", "parent": 103, "children": [106], "start_point": {"row": 52, "column": 8}, "end_point": {"row": 52, "column": 51}}, {"id": 106, "type": "binary_expression", "text": "function<void()> task = [callee]() -> void", "parent": 105, "children": [107, 112, 113], "start_point": {"row": 52, "column": 9}, "end_point": {"row": 52, "column": 51}}, {"id": 107, "type": "binary_expression", "text": "function<void()", "parent": 106, "children": [108, 109], "start_point": {"row": 52, "column": 9}, "end_point": {"row": 52, "column": 24}}, {"id": 108, "type": "<", "text": "<", "parent": 107, "children": [], "start_point": {"row": 52, "column": 17}, "end_point": {"row": 52, "column": 18}}, {"id": 109, "type": "call_expression", "text": "void()", "parent": 107, "children": [110, 111], "start_point": {"row": 52, "column": 18}, "end_point": {"row": 52, "column": 24}}, {"id": 110, "type": "identifier", "text": "void", "parent": 109, "children": [], "start_point": {"row": 52, "column": 18}, "end_point": {"row": 52, "column": 22}}, {"id": 111, "type": "argument_list", "text": "()", "parent": 109, "children": [], "start_point": {"row": 52, "column": 22}, "end_point": {"row": 52, "column": 24}}, {"id": 112, "type": ">", "text": ">", "parent": 106, "children": [], "start_point": {"row": 52, "column": 24}, "end_point": {"row": 52, "column": 25}}, {"id": 113, "type": "field_expression", "text": "task = [callee]() -> void", "parent": 106, "children": [114, 121], "start_point": {"row": 52, "column": 26}, "end_point": {"row": 52, "column": 51}}, {"id": 114, "type": "call_expression", "text": "task = [callee]()", "parent": 113, "children": [115, 120], "start_point": {"row": 52, "column": 26}, "end_point": {"row": 52, "column": 43}}, {"id": 115, "type": "subscript_expression", "text": "task = [callee]", "parent": 114, "children": [116, 117, 119], "start_point": {"row": 52, "column": 26}, "end_point": {"row": 52, "column": 41}}, {"id": 116, "type": "identifier", "text": "task", "parent": 115, "children": [], "start_point": {"row": 52, "column": 26}, "end_point": {"row": 52, "column": 30}}, {"id": 117, "type": "ERROR", "text": "=", "parent": 115, "children": [118], "start_point": {"row": 52, "column": 31}, "end_point": {"row": 52, "column": 32}}, {"id": 118, "type": "=", "text": "=", "parent": 117, "children": [], "start_point": {"row": 52, "column": 31}, "end_point": {"row": 52, "column": 32}}, {"id": 119, "type": "identifier", "text": "callee", "parent": 115, "children": [], "start_point": {"row": 52, "column": 34}, "end_point": {"row": 52, "column": 40}}, {"id": 120, "type": "argument_list", "text": "()", "parent": 114, "children": [], "start_point": {"row": 52, "column": 41}, "end_point": {"row": 52, "column": 43}}, {"id": 121, "type": "field_identifier", "text": "void", "parent": 113, "children": [], "start_point": {"row": 52, "column": 47}, "end_point": {"row": 52, "column": 51}}, {"id": 122, "type": "call_expression", "text": "callee()", "parent": 103, "children": [123, 124], "start_point": {"row": 52, "column": 54}, "end_point": {"row": 52, "column": 62}}, {"id": 123, "type": "identifier", "text": "callee", "parent": 122, "children": [], "start_point": {"row": 52, "column": 54}, "end_point": {"row": 52, "column": 60}}, {"id": 124, "type": "argument_list", "text": "()", "parent": 122, "children": [], "start_point": {"row": 52, "column": 60}, "end_point": {"row": 52, "column": 62}}, {"id": 125, "type": "declaration", "text": "size_t index = 0;", "parent": 39, "children": [126, 127], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 21}}, {"id": 126, "type": "primitive_type", "text": "size_t", "parent": 125, "children": [], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 10}}, {"id": 127, "type": "init_declarator", "text": "index = 0", "parent": 125, "children": [128, 129, 130], "start_point": {"row": 53, "column": 11}, "end_point": {"row": 53, "column": 20}}, {"id": 128, "type": "identifier", "text": "index", "parent": 127, "children": [], "start_point": {"row": 53, "column": 11}, "end_point": {"row": 53, "column": 16}}, {"id": 129, "type": "=", "text": "=", "parent": 127, "children": [], "start_point": {"row": 53, "column": 17}, "end_point": {"row": 53, "column": 18}}, {"id": 130, "type": "number_literal", "text": "0", "parent": 127, "children": [], "start_point": {"row": 53, "column": 19}, "end_point": {"row": 53, "column": 20}}, {"id": 131, "type": "for_statement", "text": "for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }", "parent": 39, "children": [132, 138, 142], "start_point": {"row": 54, "column": 4}, "end_point": {"row": 63, "column": 5}}, {"id": 132, "type": "declaration", "text": "size_t i = 0;", "parent": 131, "children": [133, 134], "start_point": {"row": 54, "column": 9}, "end_point": {"row": 54, "column": 22}}, {"id": 133, "type": "primitive_type", "text": "size_t", "parent": 132, "children": [], "start_point": {"row": 54, "column": 9}, "end_point": {"row": 54, "column": 15}}, {"id": 134, "type": "init_declarator", "text": "i = 0", "parent": 132, "children": [135, 136, 137], "start_point": {"row": 54, "column": 16}, "end_point": {"row": 54, "column": 21}}, {"id": 135, "type": "identifier", "text": "i", "parent": 134, "children": [], "start_point": {"row": 54, "column": 16}, "end_point": {"row": 54, "column": 17}}, {"id": 136, "type": "=", "text": "=", "parent": 134, "children": [], "start_point": {"row": 54, "column": 18}, "end_point": {"row": 54, "column": 19}}, {"id": 137, "type": "number_literal", "text": "0", "parent": 134, "children": [], "start_point": {"row": 54, "column": 20}, "end_point": {"row": 54, "column": 21}}, {"id": 138, "type": "binary_expression", "text": "i < submit_timeout_", "parent": 131, "children": [139, 140, 141], "start_point": {"row": 54, "column": 23}, "end_point": {"row": 54, "column": 42}}, {"id": 139, "type": "identifier", "text": "i", "parent": 138, "children": [], "start_point": {"row": 54, "column": 23}, "end_point": {"row": 54, "column": 24}}, {"id": 140, "type": "<", "text": "<", "parent": 138, "children": [], "start_point": {"row": 54, "column": 25}, "end_point": {"row": 54, "column": 26}}, {"id": 141, "type": "identifier", "text": "submit_timeout_", "parent": 138, "children": [], "start_point": {"row": 54, "column": 27}, "end_point": {"row": 54, "column": 42}}, {"id": 142, "type": "update_expression", "text": "i++", "parent": 131, "children": [143, 144], "start_point": {"row": 54, "column": 44}, "end_point": {"row": 54, "column": 47}}, {"id": 143, "type": "identifier", "text": "i", "parent": 142, "children": [], "start_point": {"row": 54, "column": 44}, "end_point": {"row": 54, "column": 45}}, {"id": 144, "type": "++", "text": "++", "parent": 142, "children": [], "start_point": {"row": 54, "column": 45}, "end_point": {"row": 54, "column": 47}}, {"id": 145, "type": "labeled_statement", "text": "std::unique_lock<std::mutex> lock(mtx_);", "parent": 131, "children": [146, 147], "start_point": {"row": 55, "column": 6}, "end_point": {"row": 55, "column": 46}}, {"id": 146, "type": "statement_identifier", "text": "std", "parent": 145, "children": [], "start_point": {"row": 55, "column": 6}, "end_point": {"row": 55, "column": 9}}, {"id": 147, "type": "ERROR", "text": "::unique_lock<std:", "parent": 145, "children": [148], "start_point": {"row": 55, "column": 9}, "end_point": {"row": 55, "column": 27}}, {"id": 148, "type": "binary_expression", "text": "unique_lock<std", "parent": 147, "children": [149, 150, 151], "start_point": {"row": 55, "column": 11}, "end_point": {"row": 55, "column": 26}}, {"id": 149, "type": "identifier", "text": "unique_lock", "parent": 148, "children": [], "start_point": {"row": 55, "column": 11}, "end_point": {"row": 55, "column": 22}}, {"id": 150, "type": "<", "text": "<", "parent": 148, "children": [], "start_point": {"row": 55, "column": 22}, "end_point": {"row": 55, "column": 23}}, {"id": 151, "type": "identifier", "text": "std", "parent": 148, "children": [], "start_point": {"row": 55, "column": 23}, "end_point": {"row": 55, "column": 26}}, {"id": 152, "type": "binary_expression", "text": "mutex> lock(mtx_)", "parent": 145, "children": [153, 154, 155], "start_point": {"row": 55, "column": 28}, "end_point": {"row": 55, "column": 45}}, {"id": 153, "type": "identifier", "text": "mutex", "parent": 152, "children": [], "start_point": {"row": 55, "column": 28}, "end_point": {"row": 55, "column": 33}}, {"id": 154, "type": ">", "text": ">", "parent": 152, "children": [], "start_point": {"row": 55, "column": 33}, "end_point": {"row": 55, "column": 34}}, {"id": 155, "type": "call_expression", "text": "lock(mtx_)", "parent": 152, "children": [156, 157], "start_point": {"row": 55, "column": 35}, "end_point": {"row": 55, "column": 45}}, {"id": 156, "type": "identifier", "text": "lock", "parent": 155, "children": [], "start_point": {"row": 55, "column": 35}, "end_point": {"row": 55, "column": 39}}, {"id": 157, "type": "argument_list", "text": "(mtx_)", "parent": 155, "children": [158], "start_point": {"row": 55, "column": 39}, "end_point": {"row": 55, "column": 45}}, {"id": 158, "type": "identifier", "text": "mtx_", "parent": 157, "children": [], "start_point": {"row": 55, "column": 40}, "end_point": {"row": 55, "column": 44}}, {"id": 159, "type": "if_statement", "text": "if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }", "parent": 131, "children": [160, 188], "start_point": {"row": 56, "column": 6}, "end_point": {"row": 62, "column": 7}}, {"id": 160, "type": "parenthesized_expression", "text": "(task_num_ >= max_task_num_)", "parent": 159, "children": [161], "start_point": {"row": 56, "column": 9}, "end_point": {"row": 56, "column": 37}}, {"id": 161, "type": "binary_expression", "text": "task_num_ >= max_task_num_", "parent": 160, "children": [162, 163, 164], "start_point": {"row": 56, "column": 10}, "end_point": {"row": 56, "column": 36}}, {"id": 162, "type": "identifier", "text": "task_num_", "parent": 161, "children": [], "start_point": {"row": 56, "column": 10}, "end_point": {"row": 56, "column": 19}}, {"id": 163, "type": ">=", "text": ">=", "parent": 161, "children": [], "start_point": {"row": 56, "column": 20}, "end_point": {"row": 56, "column": 22}}, {"id": 164, "type": "identifier", "text": "max_task_num_", "parent": 161, "children": [], "start_point": {"row": 56, "column": 23}, "end_point": {"row": 56, "column": 36}}, {"id": 165, "type": "call_expression", "text": "lock.unlock()", "parent": 159, "children": [166, 169], "start_point": {"row": 57, "column": 8}, "end_point": {"row": 57, "column": 21}}, {"id": 166, "type": "field_expression", "text": "lock.unlock", "parent": 165, "children": [167, 168], "start_point": {"row": 57, "column": 8}, "end_point": {"row": 57, "column": 19}}, {"id": 167, "type": "identifier", "text": "lock", "parent": 166, "children": [], "start_point": {"row": 57, "column": 8}, "end_point": {"row": 57, "column": 12}}, {"id": 168, "type": "field_identifier", "text": "unlock", "parent": 166, "children": [], "start_point": {"row": 57, "column": 13}, "end_point": {"row": 57, "column": 19}}, {"id": 169, "type": "argument_list", "text": "()", "parent": 165, "children": [], "start_point": {"row": 57, "column": 19}, "end_point": {"row": 57, "column": 21}}, {"id": 170, "type": "labeled_statement", "text": "std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));", "parent": 159, "children": [171, 172], "start_point": {"row": 58, "column": 8}, "end_point": {"row": 58, "column": 88}}, {"id": 171, "type": "statement_identifier", "text": "std", "parent": 170, "children": [], "start_point": {"row": 58, "column": 8}, "end_point": {"row": 58, "column": 11}}, {"id": 172, "type": "labeled_statement", "text": "this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));", "parent": 170, "children": [173, 174], "start_point": {"row": 58, "column": 13}, "end_point": {"row": 58, "column": 88}}, {"id": 173, "type": "statement_identifier", "text": "this_thread", "parent": 172, "children": [], "start_point": {"row": 58, "column": 13}, "end_point": {"row": 58, "column": 24}}, {"id": 174, "type": "labeled_statement", "text": "sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));", "parent": 172, "children": [175, 176, 179], "start_point": {"row": 58, "column": 26}, "end_point": {"row": 58, "column": 88}}, {"id": 175, "type": "statement_identifier", "text": "sleep_for", "parent": 174, "children": [], "start_point": {"row": 58, "column": 26}, "end_point": {"row": 58, "column": 35}}, {"id": 176, "type": "ERROR", "text": "(std:", "parent": 174, "children": [177], "start_point": {"row": 58, "column": 35}, "end_point": {"row": 58, "column": 40}}, {"id": 177, "type": "type_descriptor", "text": "std", "parent": 176, "children": [178], "start_point": {"row": 58, "column": 36}, "end_point": {"row": 58, "column": 39}}, {"id": 178, "type": "type_identifier", "text": "std", "parent": 177, "children": [], "start_point": {"row": 58, "column": 36}, "end_point": {"row": 58, "column": 39}}, {"id": 179, "type": "labeled_statement", "text": "chrono::milliseconds(kSubmitTaskIntervalInMs));", "parent": 174, "children": [180], "start_point": {"row": 58, "column": 41}, "end_point": {"row": 58, "column": 88}}, {"id": 180, "type": "statement_identifier", "text": "chrono", "parent": 179, "children": [], "start_point": {"row": 58, "column": 41}, "end_point": {"row": 58, "column": 47}}, {"id": 181, "type": "call_expression", "text": "milliseconds(kSubmitTaskIntervalInMs)", "parent": 179, "children": [182, 183], "start_point": {"row": 58, "column": 49}, "end_point": {"row": 58, "column": 86}}, {"id": 182, "type": "identifier", "text": "milliseconds", "parent": 181, "children": [], "start_point": {"row": 58, "column": 49}, "end_point": {"row": 58, "column": 61}}, {"id": 183, "type": "argument_list", "text": "(kSubmitTaskIntervalInMs)", "parent": 181, "children": [184], "start_point": {"row": 58, "column": 61}, "end_point": {"row": 58, "column": 86}}, {"id": 184, "type": "identifier", "text": "kSubmitTaskIntervalInMs", "parent": 183, "children": [], "start_point": {"row": 58, "column": 62}, "end_point": {"row": 58, "column": 85}}, {"id": 185, "type": "update_expression", "text": "index++", "parent": 159, "children": [186, 187], "start_point": {"row": 59, "column": 8}, "end_point": {"row": 59, "column": 15}}, {"id": 186, "type": "identifier", "text": "index", "parent": 185, "children": [], "start_point": {"row": 59, "column": 8}, "end_point": {"row": 59, "column": 13}}, {"id": 187, "type": "++", "text": "++", "parent": 185, "children": [], "start_point": {"row": 59, "column": 13}, "end_point": {"row": 59, "column": 15}}, {"id": 188, "type": "else_clause", "text": "else {\n break;\n }", "parent": 159, "children": [], "start_point": {"row": 60, "column": 8}, "end_point": {"row": 62, "column": 7}}, {"id": 189, "type": "break_statement", "text": "break;", "parent": 188, "children": [190], "start_point": {"row": 61, "column": 8}, "end_point": {"row": 61, "column": 14}}, {"id": 190, "type": "break", "text": "break", "parent": 189, "children": [], "start_point": {"row": 61, "column": 8}, "end_point": {"row": 61, "column": 13}}, {"id": 191, "type": "if_statement", "text": "if (index >= submit_timeout_) {\n MS_LOG(WARNING) << \"Submit task failed after \" << submit_timeout_ << \" ms.\";\n return false;\n }", "parent": 39, "children": [192], "start_point": {"row": 64, "column": 4}, "end_point": {"row": 67, "column": 5}}, {"id": 192, "type": "parenthesized_expression", "text": "(index >= submit_timeout_)", "parent": 191, "children": [193], "start_point": {"row": 64, "column": 7}, "end_point": {"row": 64, "column": 33}}, {"id": 193, "type": "binary_expression", "text": "index >= submit_timeout_", "parent": 192, "children": [194, 195, 196], "start_point": {"row": 64, "column": 8}, "end_point": {"row": 64, "column": 32}}, {"id": 194, "type": "identifier", "text": "index", "parent": 193, "children": [], "start_point": {"row": 64, "column": 8}, "end_point": {"row": 64, "column": 13}}, {"id": 195, "type": ">=", "text": ">=", "parent": 193, "children": [], "start_point": {"row": 64, "column": 14}, "end_point": {"row": 64, "column": 16}}, {"id": 196, "type": "identifier", "text": "submit_timeout_", "parent": 193, "children": [], "start_point": {"row": 64, "column": 17}, "end_point": {"row": 64, "column": 32}}, {"id": 197, "type": "binary_expression", "text": "MS_LOG(WARNING) << \"Submit task failed after \" << submit_timeout_ << \" ms.\"", "parent": 191, "children": [198, 208, 209], "start_point": {"row": 65, "column": 6}, "end_point": {"row": 65, "column": 81}}, {"id": 198, "type": "binary_expression", "text": "MS_LOG(WARNING) << \"Submit task failed after \" << submit_timeout_", "parent": 197, "children": [199, 206, 207], "start_point": {"row": 65, "column": 6}, "end_point": {"row": 65, "column": 71}}, {"id": 199, "type": "binary_expression", "text": "MS_LOG(WARNING) << \"Submit task failed after \"", "parent": 198, "children": [200, 204, 205], "start_point": {"row": 65, "column": 6}, "end_point": {"row": 65, "column": 52}}, {"id": 200, "type": "call_expression", "text": "MS_LOG(WARNING)", "parent": 199, "children": [201, 202], "start_point": {"row": 65, "column": 6}, "end_point": {"row": 65, "column": 21}}, {"id": 201, "type": "identifier", "text": "MS_LOG", "parent": 200, "children": [], "start_point": {"row": 65, "column": 6}, "end_point": {"row": 65, "column": 12}}, {"id": 202, "type": "argument_list", "text": "(WARNING)", "parent": 200, "children": [203], "start_point": {"row": 65, "column": 12}, "end_point": {"row": 65, "column": 21}}, {"id": 203, "type": "identifier", "text": "WARNING", "parent": 202, "children": [], "start_point": {"row": 65, "column": 13}, "end_point": {"row": 65, "column": 20}}, {"id": 204, "type": "<<", "text": "<<", "parent": 199, "children": [], "start_point": {"row": 65, "column": 22}, "end_point": {"row": 65, "column": 24}}, {"id": 205, "type": "string_literal", "text": "\"Submit task failed after \"", "parent": 199, "children": [], "start_point": {"row": 65, "column": 25}, "end_point": {"row": 65, "column": 52}}, {"id": 206, "type": "<<", "text": "<<", "parent": 198, "children": [], "start_point": {"row": 65, "column": 53}, "end_point": {"row": 65, "column": 55}}, {"id": 207, "type": "identifier", "text": "submit_timeout_", "parent": 198, "children": [], "start_point": {"row": 65, "column": 56}, "end_point": {"row": 65, "column": 71}}, {"id": 208, "type": "<<", "text": "<<", "parent": 197, "children": [], "start_point": {"row": 65, "column": 72}, "end_point": {"row": 65, "column": 74}}, {"id": 209, "type": "string_literal", "text": "\" ms.\"", "parent": 197, "children": [], "start_point": {"row": 65, "column": 75}, "end_point": {"row": 65, "column": 81}}, {"id": 210, "type": "return_statement", "text": "return false;", "parent": 191, "children": [211], "start_point": {"row": 66, "column": 6}, "end_point": {"row": 66, "column": 19}}, {"id": 211, "type": "false", "text": "false", "parent": 210, "children": [], "start_point": {"row": 66, "column": 13}, "end_point": {"row": 66, "column": 18}}, {"id": 212, "type": "labeled_statement", "text": "std::unique_lock<std::mutex> lock(mtx_);", "parent": 39, "children": [213, 214], "start_point": {"row": 68, "column": 4}, "end_point": {"row": 68, "column": 44}}, {"id": 213, "type": "statement_identifier", "text": "std", "parent": 212, "children": [], "start_point": {"row": 68, "column": 4}, "end_point": {"row": 68, "column": 7}}, {"id": 214, "type": "ERROR", "text": "::unique_lock<std:", "parent": 212, "children": [215], "start_point": {"row": 68, "column": 7}, "end_point": {"row": 68, "column": 25}}, {"id": 215, "type": "binary_expression", "text": "unique_lock<std", "parent": 214, "children": [216, 217, 218], "start_point": {"row": 68, "column": 9}, "end_point": {"row": 68, "column": 24}}, {"id": 216, "type": "identifier", "text": "unique_lock", "parent": 215, "children": [], "start_point": {"row": 68, "column": 9}, "end_point": {"row": 68, "column": 20}}, {"id": 217, "type": "<", "text": "<", "parent": 215, "children": [], "start_point": {"row": 68, "column": 20}, "end_point": {"row": 68, "column": 21}}, {"id": 218, "type": "identifier", "text": "std", "parent": 215, "children": [], "start_point": {"row": 68, "column": 21}, "end_point": {"row": 68, "column": 24}}, {"id": 219, "type": "binary_expression", "text": "mutex> lock(mtx_)", "parent": 212, "children": [220, 221, 222], "start_point": {"row": 68, "column": 26}, "end_point": {"row": 68, "column": 43}}, {"id": 220, "type": "identifier", "text": "mutex", "parent": 219, "children": [], "start_point": {"row": 68, "column": 26}, "end_point": {"row": 68, "column": 31}}, {"id": 221, "type": ">", "text": ">", "parent": 219, "children": [], "start_point": {"row": 68, "column": 31}, "end_point": {"row": 68, "column": 32}}, {"id": 222, "type": "call_expression", "text": "lock(mtx_)", "parent": 219, "children": [223, 224], "start_point": {"row": 68, "column": 33}, "end_point": {"row": 68, "column": 43}}, {"id": 223, "type": "identifier", "text": "lock", "parent": 222, "children": [], "start_point": {"row": 68, "column": 33}, "end_point": {"row": 68, "column": 37}}, {"id": 224, "type": "argument_list", "text": "(mtx_)", "parent": 222, "children": [225], "start_point": {"row": 68, "column": 37}, "end_point": {"row": 68, "column": 43}}, {"id": 225, "type": "identifier", "text": "mtx_", "parent": 224, "children": [], "start_point": {"row": 68, "column": 38}, "end_point": {"row": 68, "column": 42}}, {"id": 226, "type": "update_expression", "text": "task_num_++", "parent": 39, "children": [227, 228], "start_point": {"row": 69, "column": 4}, "end_point": {"row": 69, "column": 15}}, {"id": 227, "type": "identifier", "text": "task_num_", "parent": 226, "children": [], "start_point": {"row": 69, "column": 4}, "end_point": {"row": 69, "column": 13}}, {"id": 228, "type": "++", "text": "++", "parent": 226, "children": [], "start_point": {"row": 69, "column": 13}, "end_point": {"row": 69, "column": 15}}, {"id": 229, "type": "call_expression", "text": "task_queue_.push(task)", "parent": 39, "children": [230, 233], "start_point": {"row": 70, "column": 4}, "end_point": {"row": 70, "column": 26}}, {"id": 230, "type": "field_expression", "text": "task_queue_.push", "parent": 229, "children": [231, 232], "start_point": {"row": 70, "column": 4}, "end_point": {"row": 70, "column": 20}}, {"id": 231, "type": "identifier", "text": "task_queue_", "parent": 230, "children": [], "start_point": {"row": 70, "column": 4}, "end_point": {"row": 70, "column": 15}}, {"id": 232, "type": "field_identifier", "text": "push", "parent": 230, "children": [], "start_point": {"row": 70, "column": 16}, "end_point": {"row": 70, "column": 20}}, {"id": 233, "type": "argument_list", "text": "(task)", "parent": 229, "children": [234], "start_point": {"row": 70, "column": 20}, "end_point": {"row": 70, "column": 26}}, {"id": 234, "type": "identifier", "text": "task", "parent": 233, "children": [], "start_point": {"row": 70, "column": 21}, "end_point": {"row": 70, "column": 25}}, {"id": 235, "type": "return_statement", "text": "return true;", "parent": 39, "children": [236], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 16}}, {"id": 236, "type": "true", "text": "true", "parent": 235, "children": [], "start_point": {"row": 71, "column": 11}, "end_point": {"row": 71, "column": 15}}, {"id": 237, "type": "labeled_statement", "text": "private:\n bool running_;", "parent": 39, "children": [238], "start_point": {"row": 74, "column": 1}, "end_point": {"row": 75, "column": 16}}, {"id": 238, "type": "declaration", "text": "bool running_;", "parent": 237, "children": [239, 240], "start_point": {"row": 75, "column": 2}, "end_point": {"row": 75, "column": 16}}, {"id": 239, "type": "primitive_type", "text": "bool", "parent": 238, "children": [], "start_point": {"row": 75, "column": 2}, "end_point": {"row": 75, "column": 6}}, {"id": 240, "type": "identifier", "text": "running_", "parent": 238, "children": [], "start_point": {"row": 75, "column": 7}, "end_point": {"row": 75, "column": 15}}, {"id": 241, "type": "declaration", "text": "size_t thread_num_;", "parent": 39, "children": [242, 243], "start_point": {"row": 78, "column": 2}, "end_point": {"row": 78, "column": 21}}, {"id": 242, "type": "primitive_type", "text": "size_t", "parent": 241, "children": [], "start_point": {"row": 78, "column": 2}, "end_point": {"row": 78, "column": 8}}, {"id": 243, "type": "identifier", "text": "thread_num_", "parent": 241, "children": [], "start_point": {"row": 78, "column": 9}, "end_point": {"row": 78, "column": 20}}, {"id": 244, "type": "declaration", "text": "size_t idle_thread_num_;", "parent": 39, "children": [245, 246], "start_point": {"row": 80, "column": 2}, "end_point": {"row": 80, "column": 26}}, {"id": 245, "type": "primitive_type", "text": "size_t", "parent": 244, "children": [], "start_point": {"row": 80, "column": 2}, "end_point": {"row": 80, "column": 8}}, {"id": 246, "type": "identifier", "text": "idle_thread_num_", "parent": 244, "children": [], "start_point": {"row": 80, "column": 9}, "end_point": {"row": 80, "column": 25}}, {"id": 247, "type": "declaration", "text": "size_t submit_timeout_;", "parent": 39, "children": [248, 249], "start_point": {"row": 83, "column": 2}, "end_point": {"row": 83, "column": 25}}, {"id": 248, "type": "primitive_type", "text": "size_t", "parent": 247, "children": [], "start_point": {"row": 83, "column": 2}, "end_point": {"row": 83, "column": 8}}, {"id": 249, "type": "identifier", "text": "submit_timeout_", "parent": 247, "children": [], "start_point": {"row": 83, "column": 9}, "end_point": {"row": 83, "column": 24}}, {"id": 250, "type": "declaration", "text": "size_t max_task_num_;", "parent": 39, "children": [251, 252], "start_point": {"row": 88, "column": 2}, "end_point": {"row": 88, "column": 23}}, {"id": 251, "type": "primitive_type", "text": "size_t", "parent": 250, "children": [], "start_point": {"row": 88, "column": 2}, "end_point": {"row": 88, "column": 8}}, {"id": 252, "type": "identifier", "text": "max_task_num_", "parent": 250, "children": [], "start_point": {"row": 88, "column": 9}, "end_point": {"row": 88, "column": 22}}, {"id": 253, "type": "declaration", "text": "size_t task_num_;", "parent": 39, "children": [254, 255], "start_point": {"row": 90, "column": 2}, "end_point": {"row": 90, "column": 19}}, {"id": 254, "type": "primitive_type", "text": "size_t", "parent": 253, "children": [], "start_point": {"row": 90, "column": 2}, "end_point": {"row": 90, "column": 8}}, {"id": 255, "type": "identifier", "text": "task_num_", "parent": 253, "children": [], "start_point": {"row": 90, "column": 9}, "end_point": {"row": 90, "column": 18}}, {"id": 256, "type": "labeled_statement", "text": "std::thread notify_thread_;", "parent": 39, "children": [257, 258], "start_point": {"row": 92, "column": 2}, "end_point": {"row": 92, "column": 29}}, {"id": 257, "type": "statement_identifier", "text": "std", "parent": 256, "children": [], "start_point": {"row": 92, "column": 2}, "end_point": {"row": 92, "column": 5}}, {"id": 258, "type": "declaration", "text": "thread notify_thread_;", "parent": 256, "children": [259, 260], "start_point": {"row": 92, "column": 7}, "end_point": {"row": 92, "column": 29}}, {"id": 259, "type": "type_identifier", "text": "thread", "parent": 258, "children": [], "start_point": {"row": 92, "column": 7}, "end_point": {"row": 92, "column": 13}}, {"id": 260, "type": "identifier", "text": "notify_thread_", "parent": 258, "children": [], "start_point": {"row": 92, "column": 14}, "end_point": {"row": 92, "column": 28}}, {"id": 261, "type": "labeled_statement", "text": "std::mutex mtx_;", "parent": 39, "children": [262, 263], "start_point": {"row": 93, "column": 2}, "end_point": {"row": 93, "column": 18}}, {"id": 262, "type": "statement_identifier", "text": "std", "parent": 261, "children": [], "start_point": {"row": 93, "column": 2}, "end_point": {"row": 93, "column": 5}}, {"id": 263, "type": "declaration", "text": "mutex mtx_;", "parent": 261, "children": [264, 265], "start_point": {"row": 93, "column": 7}, "end_point": {"row": 93, "column": 18}}, {"id": 264, "type": "type_identifier", "text": "mutex", "parent": 263, "children": [], "start_point": {"row": 93, "column": 7}, "end_point": {"row": 93, "column": 12}}, {"id": 265, "type": "identifier", "text": "mtx_", "parent": 263, "children": [], "start_point": {"row": 93, "column": 13}, "end_point": {"row": 93, "column": 17}}, {"id": 266, "type": "labeled_statement", "text": "std::condition_variable cv_;", "parent": 39, "children": [267, 268], "start_point": {"row": 94, "column": 2}, "end_point": {"row": 94, "column": 30}}, {"id": 267, "type": "statement_identifier", "text": "std", "parent": 266, "children": [], "start_point": {"row": 94, "column": 2}, "end_point": {"row": 94, "column": 5}}, {"id": 268, "type": "declaration", "text": "condition_variable cv_;", "parent": 266, "children": [269, 270], "start_point": {"row": 94, "column": 7}, "end_point": {"row": 94, "column": 30}}, {"id": 269, "type": "type_identifier", "text": "condition_variable", "parent": 268, "children": [], "start_point": {"row": 94, "column": 7}, "end_point": {"row": 94, "column": 25}}, {"id": 270, "type": "identifier", "text": "cv_", "parent": 268, "children": [], "start_point": {"row": 94, "column": 26}, "end_point": {"row": 94, "column": 29}}, {"id": 271, "type": "labeled_statement", "text": "std::vector<std::thread> working_threads_;", "parent": 39, "children": [272, 273], "start_point": {"row": 96, "column": 2}, "end_point": {"row": 96, "column": 44}}, {"id": 272, "type": "statement_identifier", "text": "std", "parent": 271, "children": [], "start_point": {"row": 96, "column": 2}, "end_point": {"row": 96, "column": 5}}, {"id": 273, "type": "ERROR", "text": "::vector<std:", "parent": 271, "children": [274], "start_point": {"row": 96, "column": 5}, "end_point": {"row": 96, "column": 18}}, {"id": 274, "type": "binary_expression", "text": "vector<std", "parent": 273, "children": [275, 276, 277], "start_point": {"row": 96, "column": 7}, "end_point": {"row": 96, "column": 17}}, {"id": 275, "type": "identifier", "text": "vector", "parent": 274, "children": [], "start_point": {"row": 96, "column": 7}, "end_point": {"row": 96, "column": 13}}, {"id": 276, "type": "<", "text": "<", "parent": 274, "children": [], "start_point": {"row": 96, "column": 13}, "end_point": {"row": 96, "column": 14}}, {"id": 277, "type": "identifier", "text": "std", "parent": 274, "children": [], "start_point": {"row": 96, "column": 14}, "end_point": {"row": 96, "column": 17}}, {"id": 278, "type": "binary_expression", "text": "thread> working_threads_", "parent": 271, "children": [279, 280, 281], "start_point": {"row": 96, "column": 19}, "end_point": {"row": 96, "column": 43}}, {"id": 279, "type": "identifier", "text": "thread", "parent": 278, "children": [], "start_point": {"row": 96, "column": 19}, "end_point": {"row": 96, "column": 25}}, {"id": 280, "type": ">", "text": ">", "parent": 278, "children": [], "start_point": {"row": 96, "column": 25}, "end_point": {"row": 96, "column": 26}}, {"id": 281, "type": "identifier", "text": "working_threads_", "parent": 278, "children": [], "start_point": {"row": 96, "column": 27}, "end_point": {"row": 96, "column": 43}}, {"id": 282, "type": "labeled_statement", "text": "std::queue<std::function<void()>> task_queue_;", "parent": 39, "children": [283, 284], "start_point": {"row": 97, "column": 2}, "end_point": {"row": 97, "column": 48}}, {"id": 283, "type": "statement_identifier", "text": "std", "parent": 282, "children": [], "start_point": {"row": 97, "column": 2}, "end_point": {"row": 97, "column": 5}}, {"id": 284, "type": "ERROR", "text": "::queue<std:", "parent": 282, "children": [285], "start_point": {"row": 97, "column": 5}, "end_point": {"row": 97, "column": 17}}, {"id": 285, "type": "binary_expression", "text": "queue<std", "parent": 284, "children": [286, 287, 288], "start_point": {"row": 97, "column": 7}, "end_point": {"row": 97, "column": 16}}, {"id": 286, "type": "identifier", "text": "queue", "parent": 285, "children": [], "start_point": {"row": 97, "column": 7}, "end_point": {"row": 97, "column": 12}}, {"id": 287, "type": "<", "text": "<", "parent": 285, "children": [], "start_point": {"row": 97, "column": 12}, "end_point": {"row": 97, "column": 13}}, {"id": 288, "type": "identifier", "text": "std", "parent": 285, "children": [], "start_point": {"row": 97, "column": 13}, "end_point": {"row": 97, "column": 16}}, {"id": 289, "type": "binary_expression", "text": "function<void()>> task_queue_", "parent": 282, "children": [290, 291], "start_point": {"row": 97, "column": 18}, "end_point": {"row": 97, "column": 47}}, {"id": 290, "type": "<", "text": "<", "parent": 289, "children": [], "start_point": {"row": 97, "column": 26}, "end_point": {"row": 97, "column": 27}}, {"id": 291, "type": "binary_expression", "text": "void()>> task_queue_", "parent": 289, "children": [292, 295, 296], "start_point": {"row": 97, "column": 27}, "end_point": {"row": 97, "column": 47}}, {"id": 292, "type": "call_expression", "text": "void()", "parent": 291, "children": [293, 294], "start_point": {"row": 97, "column": 27}, "end_point": {"row": 97, "column": 33}}, {"id": 293, "type": "identifier", "text": "void", "parent": 292, "children": [], "start_point": {"row": 97, "column": 27}, "end_point": {"row": 97, "column": 31}}, {"id": 294, "type": "argument_list", "text": "()", "parent": 292, "children": [], "start_point": {"row": 97, "column": 31}, "end_point": {"row": 97, "column": 33}}, {"id": 295, "type": ">>", "text": ">>", "parent": 291, "children": [], "start_point": {"row": 97, "column": 33}, "end_point": {"row": 97, "column": 35}}, {"id": 296, "type": "identifier", "text": "task_queue_", "parent": 291, "children": [], "start_point": {"row": 97, "column": 36}, "end_point": {"row": 97, "column": 47}}, {"id": 297, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 102, "column": 0}, "end_point": {"row": 102, "column": 6}}]}, "node_categories": {"declarations": {"functions": [30, 33, 36, 39, 44, 98], "variables": [42, 47, 50, 56, 91, 125, 132, 238, 241, 244, 247, 250, 253, 258, 263, 268], "classes": [92], "imports": [6, 7, 9, 10, 12, 13, 15, 16, 18, 19, 21, 22, 24, 25, 27, 28], "modules": [], "enums": []}, "statements": {"expressions": [62, 64, 67, 68, 74, 81, 84, 87, 106, 107, 109, 113, 114, 115, 122, 138, 142, 148, 152, 155, 160, 161, 165, 166, 181, 185, 192, 193, 197, 198, 199, 200, 215, 219, 222, 226, 229, 230, 274, 278, 285, 289, 291, 292], "assignments": [], "loops": [131], "conditionals": [0, 1, 2, 5, 31, 32, 34, 35, 37, 38, 40, 43, 45, 49, 53, 55, 59, 61, 65, 69, 71, 73, 75, 77, 80, 82, 85, 88, 90, 94, 97, 99, 102, 104, 110, 116, 119, 121, 123, 128, 135, 139, 141, 143, 146, 149, 151, 153, 156, 158, 159, 162, 164, 167, 168, 171, 173, 175, 178, 180, 182, 184, 186, 191, 194, 196, 201, 203, 207, 213, 216, 218, 220, 223, 225, 227, 231, 232, 234, 240, 243, 246, 249, 252, 255, 257, 259, 260, 262, 264, 265, 267, 269, 270, 272, 275, 277, 279, 281, 283, 286, 288, 293, 296, 297], "returns": [210, 235], "exceptions": []}, "expressions": {"calls": [], "literals": [8, 11, 14, 17, 20, 23, 26, 29, 130, 137, 205, 209], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 30, "universal_type": "function", "name": "can", "text_snippet": "namespace mindspore {\nnamespace ps {\nnamespace core {\n/* This class can submit tasks in multiple thr"}, {"node_id": 33, "universal_type": "function", "name": "can", "text_snippet": "namespace ps {\nnamespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * vo"}, {"node_id": 36, "universal_type": "function", "name": "can", "text_snippet": "namespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExec"}, {"node_id": 39, "universal_type": "function", "name": "TaskExecutor", "text_snippet": "class TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxT"}, {"node_id": 44, "universal_type": "function", "name": "unknown", "text_snippet": "TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t su"}, {"node_id": 98, "universal_type": "function", "name": "unknown", "text_snippet": "bind(function, args...)"}], "class_declarations": [{"node_id": 92, "universal_type": "class", "name": "unknown", "text_snippet": "auto"}], "import_statements": [{"node_id": 6, "text": "#include <functional>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <queue>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include <mutex>\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include <vector>\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include <thread>\n"}, {"node_id": 19, "text": "#include"}, {"node_id": 21, "text": "#include <condition_variable>\n"}, {"node_id": 22, "text": "#include"}, {"node_id": 24, "text": "#include \"utils/log_adapter.h\"\n"}, {"node_id": 25, "text": "#include"}, {"node_id": 27, "text": "#include \"ps/constants.h\"\n"}, {"node_id": 28, "text": "#include"}]}, "original_source_code": "/**\n * Copyright 2021 Huawei Technologies Co., Ltd\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n#ifndef MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_\n#define MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_\n\n#include <functional>\n#include <queue>\n#include <mutex>\n#include <vector>\n#include <thread>\n#include <condition_variable>\n\n#include \"utils/log_adapter.h\"\n#include \"ps/constants.h\"\n\nnamespace mindspore {\nnamespace ps {\nnamespace core {\n/* This class can submit tasks in multiple threads\n * example:\n * void TestTaskExecutor() {\n * std::cout << \"Execute in one thread\";\n * }\n *\n * TaskExecutor executor(10); // 10 threads\n * executor.Submit(TestTaskExecutor, this); // Submit task\n */\nclass TaskExecutor {\n public:\n explicit TaskExecutor(size_t thread_num, size_t max_task_num = kMaxTaskNum,\n size_t submit_timeout = kSubmitTimeOutInMs);\n ~TaskExecutor();\n\n // If the number of submitted tasks is greater than the size of the queue, it will block the submission of subsequent\n // tasks unitl timeout.\n template <typename Fun, typename... Args>\n bool Submit(Fun &&function, Args &&... args) {\n auto callee = std::bind(function, args...);\n std::function<void()> task = [callee]() -> void { callee(); };\n size_t index = 0;\n for (size_t i = 0; i < submit_timeout_; i++) {\n std::unique_lock<std::mutex> lock(mtx_);\n if (task_num_ >= max_task_num_) {\n lock.unlock();\n std::this_thread::sleep_for(std::chrono::milliseconds(kSubmitTaskIntervalInMs));\n index++;\n } else {\n break;\n }\n }\n if (index >= submit_timeout_) {\n MS_LOG(WARNING) << \"Submit task failed after \" << submit_timeout_ << \" ms.\";\n return false;\n }\n std::unique_lock<std::mutex> lock(mtx_);\n task_num_++;\n task_queue_.push(task);\n return true;\n }\n\n private:\n bool running_;\n\n // The number of tasks actually running\n size_t thread_num_;\n // The number of idle threads that can execute tasks\n size_t idle_thread_num_;\n\n // The timeout period of the task submission, in milliseconds. default timeout is 3000 milliseconds.\n size_t submit_timeout_;\n\n // The maximum number of tasks that can be submitted to the task queue, If the number of submitted tasks exceeds this\n // max_task_num_, the Submit function will block.Until the current number of tasks is less than max task num,or\n // timeout.\n size_t max_task_num_;\n // The number of currently submitted to the task queue\n size_t task_num_;\n\n std::thread notify_thread_;\n std::mutex mtx_;\n std::condition_variable cv_;\n\n std::vector<std::thread> working_threads_;\n std::queue<std::function<void()>> task_queue_;\n};\n} // namespace core\n} // namespace ps\n} // namespace mindspore\n#endif // MINDSPORE_CCSRC_PS_CORE_COMMUNICATOR_TASK_EXECUTOR_H_\n"}
80,533
c
struct bintree *delete_it(char ch1,struct bintree *ptr) { if (ptr == NULL) return ptr; if (ch1 < ptr->ch) ptr->lch = delete_it(ch1,ptr->lch); else if (ch1 > ptr->ch) ptr->rch = delete_it(ch1,ptr->rch); else { if (ptr->lch == NULL) { struct bintree *temp = ptr->rch; free(ptr); return temp; } else if (ptr->rch == NULL) { struct bintree *temp = ptr->lch; free(ptr); return temp; } struct bintree* temp = find_min(ptr->rch); ptr->ch = temp->ch; ptr->rch = delete_it(temp->ch,ptr->rch); } return ptr; }
19.26
27
(translation_unit) "struct bintree *delete_it(char ch1,struct bintree *ptr)\n{\n if (ptr == NULL) return ptr;\n if (ch1 < ptr->ch)\n ptr->lch = delete_it(ch1,ptr->lch);\n else if (ch1 > ptr->ch)\n ptr->rch = delete_it(ch1,ptr->rch);\n else\n {\n if (ptr->lch == NULL)\n {\n struct bintree *temp = ptr->rch;\n free(ptr);\n return temp;\n }\n else if (ptr->rch == NULL)\n {\n struct bintree *temp = ptr->lch;\n free(ptr);\n return temp;\n }\n struct bintree* temp = find_min(ptr->rch);\n ptr->ch = temp->ch;\n ptr->rch = delete_it(temp->ch,ptr->rch);\n }\n return ptr;\n}\n" (function_definition) "struct bintree *delete_it(char ch1,struct bintree *ptr)\n{\n if (ptr == NULL) return ptr;\n if (ch1 < ptr->ch)\n ptr->lch = delete_it(ch1,ptr->lch);\n else if (ch1 > ptr->ch)\n ptr->rch = delete_it(ch1,ptr->rch);\n else\n {\n if (ptr->lch == NULL)\n {\n struct bintree *temp = ptr->rch;\n free(ptr);\n return temp;\n }\n else if (ptr->rch == NULL)\n {\n struct bintree *temp = ptr->lch;\n free(ptr);\n return temp;\n }\n struct bintree* temp = find_min(ptr->rch);\n ptr->ch = temp->ch;\n ptr->rch = delete_it(temp->ch,ptr->rch);\n }\n return ptr;\n}" (struct_specifier) "struct bintree" (struct) "struct" (type_identifier) "bintree" (pointer_declarator) "*delete_it(char ch1,struct bintree *ptr)" (*) "*" (function_declarator) "delete_it(char ch1,struct bintree *ptr)" (identifier) "delete_it" (parameter_list) "(char ch1,struct bintree *ptr)" (() "(" (parameter_declaration) "char ch1" (primitive_type) "char" (identifier) "ch1" (,) "," (parameter_declaration) "struct bintree *ptr" (struct_specifier) "struct bintree" (struct) "struct" (type_identifier) "bintree" (pointer_declarator) "*ptr" (*) "*" (identifier) "ptr" ()) ")" (compound_statement) "{\n if (ptr == NULL) return ptr;\n if (ch1 < ptr->ch)\n ptr->lch = delete_it(ch1,ptr->lch);\n else if (ch1 > ptr->ch)\n ptr->rch = delete_it(ch1,ptr->rch);\n else\n {\n if (ptr->lch == NULL)\n {\n struct bintree *temp = ptr->rch;\n free(ptr);\n return temp;\n }\n else if (ptr->rch == NULL)\n {\n struct bintree *temp = ptr->lch;\n free(ptr);\n return temp;\n }\n struct bintree* temp = find_min(ptr->rch);\n ptr->ch = temp->ch;\n ptr->rch = delete_it(temp->ch,ptr->rch);\n }\n return ptr;\n}" ({) "{" (if_statement) "if (ptr == NULL) return ptr;" (if) "if" (parenthesized_expression) "(ptr == NULL)" (() "(" (binary_expression) "ptr == NULL" (identifier) "ptr" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (return_statement) "return ptr;" (return) "return" (identifier) "ptr" (;) ";" (if_statement) "if (ch1 < ptr->ch)\n ptr->lch = delete_it(ch1,ptr->lch);\n else if (ch1 > ptr->ch)\n ptr->rch = delete_it(ch1,ptr->rch);\n else\n {\n if (ptr->lch == NULL)\n {\n struct bintree *temp = ptr->rch;\n free(ptr);\n return temp;\n }\n else if (ptr->rch == NULL)\n {\n struct bintree *temp = ptr->lch;\n free(ptr);\n return temp;\n }\n struct bintree* temp = find_min(ptr->rch);\n ptr->ch = temp->ch;\n ptr->rch = delete_it(temp->ch,ptr->rch);\n }" (if) "if" (parenthesized_expression) "(ch1 < ptr->ch)" (() "(" (binary_expression) "ch1 < ptr->ch" (identifier) "ch1" (<) "<" (field_expression) "ptr->ch" (identifier) "ptr" (->) "->" (field_identifier) "ch" ()) ")" (expression_statement) "ptr->lch = delete_it(ch1,ptr->lch);" (assignment_expression) "ptr->lch = delete_it(ch1,ptr->lch)" (field_expression) "ptr->lch" (identifier) "ptr" (->) "->" (field_identifier) "lch" (=) "=" (call_expression) "delete_it(ch1,ptr->lch)" (identifier) "delete_it" (argument_list) "(ch1,ptr->lch)" (() "(" (identifier) "ch1" (,) "," (field_expression) "ptr->lch" (identifier) "ptr" (->) "->" (field_identifier) "lch" ()) ")" (;) ";" (else_clause) "else if (ch1 > ptr->ch)\n ptr->rch = delete_it(ch1,ptr->rch);\n else\n {\n if (ptr->lch == NULL)\n {\n struct bintree *temp = ptr->rch;\n free(ptr);\n return temp;\n }\n else if (ptr->rch == NULL)\n {\n struct bintree *temp = ptr->lch;\n free(ptr);\n return temp;\n }\n struct bintree* temp = find_min(ptr->rch);\n ptr->ch = temp->ch;\n ptr->rch = delete_it(temp->ch,ptr->rch);\n }" (else) "else" (if_statement) "if (ch1 > ptr->ch)\n ptr->rch = delete_it(ch1,ptr->rch);\n else\n {\n if (ptr->lch == NULL)\n {\n struct bintree *temp = ptr->rch;\n free(ptr);\n return temp;\n }\n else if (ptr->rch == NULL)\n {\n struct bintree *temp = ptr->lch;\n free(ptr);\n return temp;\n }\n struct bintree* temp = find_min(ptr->rch);\n ptr->ch = temp->ch;\n ptr->rch = delete_it(temp->ch,ptr->rch);\n }" (if) "if" (parenthesized_expression) "(ch1 > ptr->ch)" (() "(" (binary_expression) "ch1 > ptr->ch" (identifier) "ch1" (>) ">" (field_expression) "ptr->ch" (identifier) "ptr" (->) "->" (field_identifier) "ch" ()) ")" (expression_statement) "ptr->rch = delete_it(ch1,ptr->rch);" (assignment_expression) "ptr->rch = delete_it(ch1,ptr->rch)" (field_expression) "ptr->rch" (identifier) "ptr" (->) "->" (field_identifier) "rch" (=) "=" (call_expression) "delete_it(ch1,ptr->rch)" (identifier) "delete_it" (argument_list) "(ch1,ptr->rch)" (() "(" (identifier) "ch1" (,) "," (field_expression) "ptr->rch" (identifier) "ptr" (->) "->" (field_identifier) "rch" ()) ")" (;) ";" (else_clause) "else\n {\n if (ptr->lch == NULL)\n {\n struct bintree *temp = ptr->rch;\n free(ptr);\n return temp;\n }\n else if (ptr->rch == NULL)\n {\n struct bintree *temp = ptr->lch;\n free(ptr);\n return temp;\n }\n struct bintree* temp = find_min(ptr->rch);\n ptr->ch = temp->ch;\n ptr->rch = delete_it(temp->ch,ptr->rch);\n }" (else) "else" (compound_statement) "{\n if (ptr->lch == NULL)\n {\n struct bintree *temp = ptr->rch;\n free(ptr);\n return temp;\n }\n else if (ptr->rch == NULL)\n {\n struct bintree *temp = ptr->lch;\n free(ptr);\n return temp;\n }\n struct bintree* temp = find_min(ptr->rch);\n ptr->ch = temp->ch;\n ptr->rch = delete_it(temp->ch,ptr->rch);\n }" ({) "{" (if_statement) "if (ptr->lch == NULL)\n {\n struct bintree *temp = ptr->rch;\n free(ptr);\n return temp;\n }\n else if (ptr->rch == NULL)\n {\n struct bintree *temp = ptr->lch;\n free(ptr);\n return temp;\n }" (if) "if" (parenthesized_expression) "(ptr->lch == NULL)" (() "(" (binary_expression) "ptr->lch == NULL" (field_expression) "ptr->lch" (identifier) "ptr" (->) "->" (field_identifier) "lch" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{\n struct bintree *temp = ptr->rch;\n free(ptr);\n return temp;\n }" ({) "{" (declaration) "struct bintree *temp = ptr->rch;" (struct_specifier) "struct bintree" (struct) "struct" (type_identifier) "bintree" (init_declarator) "*temp = ptr->rch" (pointer_declarator) "*temp" (*) "*" (identifier) "temp" (=) "=" (field_expression) "ptr->rch" (identifier) "ptr" (->) "->" (field_identifier) "rch" (;) ";" (expression_statement) "free(ptr);" (call_expression) "free(ptr)" (identifier) "free" (argument_list) "(ptr)" (() "(" (identifier) "ptr" ()) ")" (;) ";" (return_statement) "return temp;" (return) "return" (identifier) "temp" (;) ";" (}) "}" (else_clause) "else if (ptr->rch == NULL)\n {\n struct bintree *temp = ptr->lch;\n free(ptr);\n return temp;\n }" (else) "else" (if_statement) "if (ptr->rch == NULL)\n {\n struct bintree *temp = ptr->lch;\n free(ptr);\n return temp;\n }" (if) "if" (parenthesized_expression) "(ptr->rch == NULL)" (() "(" (binary_expression) "ptr->rch == NULL" (field_expression) "ptr->rch" (identifier) "ptr" (->) "->" (field_identifier) "rch" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{\n struct bintree *temp = ptr->lch;\n free(ptr);\n return temp;\n }" ({) "{" (declaration) "struct bintree *temp = ptr->lch;" (struct_specifier) "struct bintree" (struct) "struct" (type_identifier) "bintree" (init_declarator) "*temp = ptr->lch" (pointer_declarator) "*temp" (*) "*" (identifier) "temp" (=) "=" (field_expression) "ptr->lch" (identifier) "ptr" (->) "->" (field_identifier) "lch" (;) ";" (expression_statement) "free(ptr);" (call_expression) "free(ptr)" (identifier) "free" (argument_list) "(ptr)" (() "(" (identifier) "ptr" ()) ")" (;) ";" (return_statement) "return temp;" (return) "return" (identifier) "temp" (;) ";" (}) "}" (declaration) "struct bintree* temp = find_min(ptr->rch);" (struct_specifier) "struct bintree" (struct) "struct" (type_identifier) "bintree" (init_declarator) "* temp = find_min(ptr->rch)" (pointer_declarator) "* temp" (*) "*" (identifier) "temp" (=) "=" (call_expression) "find_min(ptr->rch)" (identifier) "find_min" (argument_list) "(ptr->rch)" (() "(" (field_expression) "ptr->rch" (identifier) "ptr" (->) "->" (field_identifier) "rch" ()) ")" (;) ";" (expression_statement) "ptr->ch = temp->ch;" (assignment_expression) "ptr->ch = temp->ch" (field_expression) "ptr->ch" (identifier) "ptr" (->) "->" (field_identifier) "ch" (=) "=" (field_expression) "temp->ch" (identifier) "temp" (->) "->" (field_identifier) "ch" (;) ";" (expression_statement) "ptr->rch = delete_it(temp->ch,ptr->rch);" (assignment_expression) "ptr->rch = delete_it(temp->ch,ptr->rch)" (field_expression) "ptr->rch" (identifier) "ptr" (->) "->" (field_identifier) "rch" (=) "=" (call_expression) "delete_it(temp->ch,ptr->rch)" (identifier) "delete_it" (argument_list) "(temp->ch,ptr->rch)" (() "(" (field_expression) "temp->ch" (identifier) "temp" (->) "->" (field_identifier) "ch" (,) "," (field_expression) "ptr->rch" (identifier) "ptr" (->) "->" (field_identifier) "rch" ()) ")" (;) ";" (}) "}" (return_statement) "return ptr;" (return) "return" (identifier) "ptr" (;) ";" (}) "}"
252
0
{"language": "c", "success": true, "metadata": {"lines": 27, "avg_line_length": 19.26, "nodes": 164, "errors": 0, "source_hash": "4fea11bb85328d2202b4e2e6f993a8bd11d81d53d8e4e018cf94c04f291f1ed6", "categorized_nodes": 122}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "function_definition", "text": "struct bintree *delete_it(char ch1,struct bintree *ptr)\n{\n\tif (ptr == NULL) return ptr;\n\tif (ch1 < ptr->ch)\n\t\tptr->lch = delete_it(ch1,ptr->lch);\n\telse if (ch1 > ptr->ch)\n\t\tptr->rch = delete_it(ch1,ptr->rch);\n\telse\n\t{\n\t\tif (ptr->lch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->rch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}\n\t\telse if (ptr->rch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->lch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}\n\t\tstruct bintree* temp = find_min(ptr->rch);\n\t\tptr->ch = temp->ch;\n\t\tptr->rch = delete_it(temp->ch,ptr->rch);\n\t}\n\treturn ptr;\n}", "parent": null, "children": [1, 4], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 26, "column": 1}}, {"id": 1, "type": "struct_specifier", "text": "struct bintree", "parent": 0, "children": [2, 3], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 14}}, {"id": 2, "type": "struct", "text": "struct", "parent": 1, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 6}}, {"id": 3, "type": "type_identifier", "text": "bintree", "parent": 1, "children": [], "start_point": {"row": 0, "column": 7}, "end_point": {"row": 0, "column": 14}}, {"id": 4, "type": "pointer_declarator", "text": "*delete_it(char ch1,struct bintree *ptr)", "parent": 0, "children": [5, 6], "start_point": {"row": 0, "column": 15}, "end_point": {"row": 0, "column": 55}}, {"id": 5, "type": "*", "text": "*", "parent": 4, "children": [], "start_point": {"row": 0, "column": 15}, "end_point": {"row": 0, "column": 16}}, {"id": 6, "type": "function_declarator", "text": "delete_it(char ch1,struct bintree *ptr)", "parent": 4, "children": [7, 8], "start_point": {"row": 0, "column": 16}, "end_point": {"row": 0, "column": 55}}, {"id": 7, "type": "identifier", "text": "delete_it", "parent": 6, "children": [], "start_point": {"row": 0, "column": 16}, "end_point": {"row": 0, "column": 25}}, {"id": 8, "type": "parameter_list", "text": "(char ch1,struct bintree *ptr)", "parent": 6, "children": [9, 12], "start_point": {"row": 0, "column": 25}, "end_point": {"row": 0, "column": 55}}, {"id": 9, "type": "parameter_declaration", "text": "char ch1", "parent": 8, "children": [10, 11], "start_point": {"row": 0, "column": 26}, "end_point": {"row": 0, "column": 34}}, {"id": 10, "type": "primitive_type", "text": "char", "parent": 9, "children": [], "start_point": {"row": 0, "column": 26}, "end_point": {"row": 0, "column": 30}}, {"id": 11, "type": "identifier", "text": "ch1", "parent": 9, "children": [], "start_point": {"row": 0, "column": 31}, "end_point": {"row": 0, "column": 34}}, {"id": 12, "type": "parameter_declaration", "text": "struct bintree *ptr", "parent": 8, "children": [13, 16], "start_point": {"row": 0, "column": 35}, "end_point": {"row": 0, "column": 54}}, {"id": 13, "type": "struct_specifier", "text": "struct bintree", "parent": 12, "children": [14, 15], "start_point": {"row": 0, "column": 35}, "end_point": {"row": 0, "column": 49}}, {"id": 14, "type": "struct", "text": "struct", "parent": 13, "children": [], "start_point": {"row": 0, "column": 35}, "end_point": {"row": 0, "column": 41}}, {"id": 15, "type": "type_identifier", "text": "bintree", "parent": 13, "children": [], "start_point": {"row": 0, "column": 42}, "end_point": {"row": 0, "column": 49}}, {"id": 16, "type": "pointer_declarator", "text": "*ptr", "parent": 12, "children": [17, 18], "start_point": {"row": 0, "column": 50}, "end_point": {"row": 0, "column": 54}}, {"id": 17, "type": "*", "text": "*", "parent": 16, "children": [], "start_point": {"row": 0, "column": 50}, "end_point": {"row": 0, "column": 51}}, {"id": 18, "type": "identifier", "text": "ptr", "parent": 16, "children": [], "start_point": {"row": 0, "column": 51}, "end_point": {"row": 0, "column": 54}}, {"id": 19, "type": "if_statement", "text": "if (ptr == NULL) return ptr;", "parent": 0, "children": [20, 26], "start_point": {"row": 2, "column": 1}, "end_point": {"row": 2, "column": 29}}, {"id": 20, "type": "parenthesized_expression", "text": "(ptr == NULL)", "parent": 19, "children": [21], "start_point": {"row": 2, "column": 4}, "end_point": {"row": 2, "column": 17}}, {"id": 21, "type": "binary_expression", "text": "ptr == NULL", "parent": 20, "children": [22, 23, 24], "start_point": {"row": 2, "column": 5}, "end_point": {"row": 2, "column": 16}}, {"id": 22, "type": "identifier", "text": "ptr", "parent": 21, "children": [], "start_point": {"row": 2, "column": 5}, "end_point": {"row": 2, "column": 8}}, {"id": 23, "type": "==", "text": "==", "parent": 21, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 11}}, {"id": 24, "type": "null", "text": "NULL", "parent": 21, "children": [25], "start_point": {"row": 2, "column": 12}, "end_point": {"row": 2, "column": 16}}, {"id": 25, "type": "NULL", "text": "NULL", "parent": 24, "children": [], "start_point": {"row": 2, "column": 12}, "end_point": {"row": 2, "column": 16}}, {"id": 26, "type": "return_statement", "text": "return ptr;", "parent": 19, "children": [27], "start_point": {"row": 2, "column": 18}, "end_point": {"row": 2, "column": 29}}, {"id": 27, "type": "identifier", "text": "ptr", "parent": 26, "children": [], "start_point": {"row": 2, "column": 25}, "end_point": {"row": 2, "column": 28}}, {"id": 28, "type": "if_statement", "text": "if (ch1 < ptr->ch)\n\t\tptr->lch = delete_it(ch1,ptr->lch);\n\telse if (ch1 > ptr->ch)\n\t\tptr->rch = delete_it(ch1,ptr->rch);\n\telse\n\t{\n\t\tif (ptr->lch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->rch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}\n\t\telse if (ptr->rch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->lch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}\n\t\tstruct bintree* temp = find_min(ptr->rch);\n\t\tptr->ch = temp->ch;\n\t\tptr->rch = delete_it(temp->ch,ptr->rch);\n\t}", "parent": 0, "children": [29, 48], "start_point": {"row": 3, "column": 1}, "end_point": {"row": 24, "column": 2}}, {"id": 29, "type": "parenthesized_expression", "text": "(ch1 < ptr->ch)", "parent": 28, "children": [30], "start_point": {"row": 3, "column": 4}, "end_point": {"row": 3, "column": 19}}, {"id": 30, "type": "binary_expression", "text": "ch1 < ptr->ch", "parent": 29, "children": [31, 32, 33], "start_point": {"row": 3, "column": 5}, "end_point": {"row": 3, "column": 18}}, {"id": 31, "type": "identifier", "text": "ch1", "parent": 30, "children": [], "start_point": {"row": 3, "column": 5}, "end_point": {"row": 3, "column": 8}}, {"id": 32, "type": "<", "text": "<", "parent": 30, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 10}}, {"id": 33, "type": "field_expression", "text": "ptr->ch", "parent": 30, "children": [34, 35], "start_point": {"row": 3, "column": 11}, "end_point": {"row": 3, "column": 18}}, {"id": 34, "type": "identifier", "text": "ptr", "parent": 33, "children": [], "start_point": {"row": 3, "column": 11}, "end_point": {"row": 3, "column": 14}}, {"id": 35, "type": "field_identifier", "text": "ch", "parent": 33, "children": [], "start_point": {"row": 3, "column": 16}, "end_point": {"row": 3, "column": 18}}, {"id": 36, "type": "assignment_expression", "text": "ptr->lch = delete_it(ch1,ptr->lch)", "parent": 28, "children": [37, 40, 41], "start_point": {"row": 4, "column": 2}, "end_point": {"row": 4, "column": 36}}, {"id": 37, "type": "field_expression", "text": "ptr->lch", "parent": 36, "children": [38, 39], "start_point": {"row": 4, "column": 2}, "end_point": {"row": 4, "column": 10}}, {"id": 38, "type": "identifier", "text": "ptr", "parent": 37, "children": [], "start_point": {"row": 4, "column": 2}, "end_point": {"row": 4, "column": 5}}, {"id": 39, "type": "field_identifier", "text": "lch", "parent": 37, "children": [], "start_point": {"row": 4, "column": 7}, "end_point": {"row": 4, "column": 10}}, {"id": 40, "type": "=", "text": "=", "parent": 36, "children": [], "start_point": {"row": 4, "column": 11}, "end_point": {"row": 4, "column": 12}}, {"id": 41, "type": "call_expression", "text": "delete_it(ch1,ptr->lch)", "parent": 36, "children": [42, 43], "start_point": {"row": 4, "column": 13}, "end_point": {"row": 4, "column": 36}}, {"id": 42, "type": "identifier", "text": "delete_it", "parent": 41, "children": [], "start_point": {"row": 4, "column": 13}, "end_point": {"row": 4, "column": 22}}, {"id": 43, "type": "argument_list", "text": "(ch1,ptr->lch)", "parent": 41, "children": [44, 45], "start_point": {"row": 4, "column": 22}, "end_point": {"row": 4, "column": 36}}, {"id": 44, "type": "identifier", "text": "ch1", "parent": 43, "children": [], "start_point": {"row": 4, "column": 23}, "end_point": {"row": 4, "column": 26}}, {"id": 45, "type": "field_expression", "text": "ptr->lch", "parent": 43, "children": [46, 47], "start_point": {"row": 4, "column": 27}, "end_point": {"row": 4, "column": 35}}, {"id": 46, "type": "identifier", "text": "ptr", "parent": 45, "children": [], "start_point": {"row": 4, "column": 27}, "end_point": {"row": 4, "column": 30}}, {"id": 47, "type": "field_identifier", "text": "lch", "parent": 45, "children": [], "start_point": {"row": 4, "column": 32}, "end_point": {"row": 4, "column": 35}}, {"id": 48, "type": "else_clause", "text": "else if (ch1 > ptr->ch)\n\t\tptr->rch = delete_it(ch1,ptr->rch);\n\telse\n\t{\n\t\tif (ptr->lch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->rch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}\n\t\telse if (ptr->rch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->lch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}\n\t\tstruct bintree* temp = find_min(ptr->rch);\n\t\tptr->ch = temp->ch;\n\t\tptr->rch = delete_it(temp->ch,ptr->rch);\n\t}", "parent": 28, "children": [49], "start_point": {"row": 5, "column": 1}, "end_point": {"row": 24, "column": 2}}, {"id": 49, "type": "if_statement", "text": "if (ch1 > ptr->ch)\n\t\tptr->rch = delete_it(ch1,ptr->rch);\n\telse\n\t{\n\t\tif (ptr->lch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->rch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}\n\t\telse if (ptr->rch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->lch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}\n\t\tstruct bintree* temp = find_min(ptr->rch);\n\t\tptr->ch = temp->ch;\n\t\tptr->rch = delete_it(temp->ch,ptr->rch);\n\t}", "parent": 48, "children": [50, 69], "start_point": {"row": 5, "column": 6}, "end_point": {"row": 24, "column": 2}}, {"id": 50, "type": "parenthesized_expression", "text": "(ch1 > ptr->ch)", "parent": 49, "children": [51], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 24}}, {"id": 51, "type": "binary_expression", "text": "ch1 > ptr->ch", "parent": 50, "children": [52, 53, 54], "start_point": {"row": 5, "column": 10}, "end_point": {"row": 5, "column": 23}}, {"id": 52, "type": "identifier", "text": "ch1", "parent": 51, "children": [], "start_point": {"row": 5, "column": 10}, "end_point": {"row": 5, "column": 13}}, {"id": 53, "type": ">", "text": ">", "parent": 51, "children": [], "start_point": {"row": 5, "column": 14}, "end_point": {"row": 5, "column": 15}}, {"id": 54, "type": "field_expression", "text": "ptr->ch", "parent": 51, "children": [55, 56], "start_point": {"row": 5, "column": 16}, "end_point": {"row": 5, "column": 23}}, {"id": 55, "type": "identifier", "text": "ptr", "parent": 54, "children": [], "start_point": {"row": 5, "column": 16}, "end_point": {"row": 5, "column": 19}}, {"id": 56, "type": "field_identifier", "text": "ch", "parent": 54, "children": [], "start_point": {"row": 5, "column": 21}, "end_point": {"row": 5, "column": 23}}, {"id": 57, "type": "assignment_expression", "text": "ptr->rch = delete_it(ch1,ptr->rch)", "parent": 49, "children": [58, 61, 62], "start_point": {"row": 6, "column": 2}, "end_point": {"row": 6, "column": 36}}, {"id": 58, "type": "field_expression", "text": "ptr->rch", "parent": 57, "children": [59, 60], "start_point": {"row": 6, "column": 2}, "end_point": {"row": 6, "column": 10}}, {"id": 59, "type": "identifier", "text": "ptr", "parent": 58, "children": [], "start_point": {"row": 6, "column": 2}, "end_point": {"row": 6, "column": 5}}, {"id": 60, "type": "field_identifier", "text": "rch", "parent": 58, "children": [], "start_point": {"row": 6, "column": 7}, "end_point": {"row": 6, "column": 10}}, {"id": 61, "type": "=", "text": "=", "parent": 57, "children": [], "start_point": {"row": 6, "column": 11}, "end_point": {"row": 6, "column": 12}}, {"id": 62, "type": "call_expression", "text": "delete_it(ch1,ptr->rch)", "parent": 57, "children": [63, 64], "start_point": {"row": 6, "column": 13}, "end_point": {"row": 6, "column": 36}}, {"id": 63, "type": "identifier", "text": "delete_it", "parent": 62, "children": [], "start_point": {"row": 6, "column": 13}, "end_point": {"row": 6, "column": 22}}, {"id": 64, "type": "argument_list", "text": "(ch1,ptr->rch)", "parent": 62, "children": [65, 66], "start_point": {"row": 6, "column": 22}, "end_point": {"row": 6, "column": 36}}, {"id": 65, "type": "identifier", "text": "ch1", "parent": 64, "children": [], "start_point": {"row": 6, "column": 23}, "end_point": {"row": 6, "column": 26}}, {"id": 66, "type": "field_expression", "text": "ptr->rch", "parent": 64, "children": [67, 68], "start_point": {"row": 6, "column": 27}, "end_point": {"row": 6, "column": 35}}, {"id": 67, "type": "identifier", "text": "ptr", "parent": 66, "children": [], "start_point": {"row": 6, "column": 27}, "end_point": {"row": 6, "column": 30}}, {"id": 68, "type": "field_identifier", "text": "rch", "parent": 66, "children": [], "start_point": {"row": 6, "column": 32}, "end_point": {"row": 6, "column": 35}}, {"id": 69, "type": "else_clause", "text": "else\n\t{\n\t\tif (ptr->lch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->rch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}\n\t\telse if (ptr->rch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->lch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}\n\t\tstruct bintree* temp = find_min(ptr->rch);\n\t\tptr->ch = temp->ch;\n\t\tptr->rch = delete_it(temp->ch,ptr->rch);\n\t}", "parent": 49, "children": [], "start_point": {"row": 7, "column": 1}, "end_point": {"row": 24, "column": 2}}, {"id": 70, "type": "if_statement", "text": "if (ptr->lch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->rch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}\n\t\telse if (ptr->rch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->lch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}", "parent": 69, "children": [71, 97], "start_point": {"row": 9, "column": 2}, "end_point": {"row": 20, "column": 3}}, {"id": 71, "type": "parenthesized_expression", "text": "(ptr->lch == NULL)", "parent": 70, "children": [72], "start_point": {"row": 9, "column": 5}, "end_point": {"row": 9, "column": 23}}, {"id": 72, "type": "binary_expression", "text": "ptr->lch == NULL", "parent": 71, "children": [73, 76, 77], "start_point": {"row": 9, "column": 6}, "end_point": {"row": 9, "column": 22}}, {"id": 73, "type": "field_expression", "text": "ptr->lch", "parent": 72, "children": [74, 75], "start_point": {"row": 9, "column": 6}, "end_point": {"row": 9, "column": 14}}, {"id": 74, "type": "identifier", "text": "ptr", "parent": 73, "children": [], "start_point": {"row": 9, "column": 6}, "end_point": {"row": 9, "column": 9}}, {"id": 75, "type": "field_identifier", "text": "lch", "parent": 73, "children": [], "start_point": {"row": 9, "column": 11}, "end_point": {"row": 9, "column": 14}}, {"id": 76, "type": "==", "text": "==", "parent": 72, "children": [], "start_point": {"row": 9, "column": 15}, "end_point": {"row": 9, "column": 17}}, {"id": 77, "type": "null", "text": "NULL", "parent": 72, "children": [78], "start_point": {"row": 9, "column": 18}, "end_point": {"row": 9, "column": 22}}, {"id": 78, "type": "NULL", "text": "NULL", "parent": 77, "children": [], "start_point": {"row": 9, "column": 18}, "end_point": {"row": 9, "column": 22}}, {"id": 79, "type": "declaration", "text": "struct bintree *temp = ptr->rch;", "parent": 70, "children": [80, 83], "start_point": {"row": 11, "column": 3}, "end_point": {"row": 11, "column": 35}}, {"id": 80, "type": "struct_specifier", "text": "struct bintree", "parent": 79, "children": [81, 82], "start_point": {"row": 11, "column": 3}, "end_point": {"row": 11, "column": 17}}, {"id": 81, "type": "struct", "text": "struct", "parent": 80, "children": [], "start_point": {"row": 11, "column": 3}, "end_point": {"row": 11, "column": 9}}, {"id": 82, "type": "type_identifier", "text": "bintree", "parent": 80, "children": [], "start_point": {"row": 11, "column": 10}, "end_point": {"row": 11, "column": 17}}, {"id": 83, "type": "init_declarator", "text": "*temp = ptr->rch", "parent": 79, "children": [84, 87, 88], "start_point": {"row": 11, "column": 18}, "end_point": {"row": 11, "column": 34}}, {"id": 84, "type": "pointer_declarator", "text": "*temp", "parent": 83, "children": [85, 86], "start_point": {"row": 11, "column": 18}, "end_point": {"row": 11, "column": 23}}, {"id": 85, "type": "*", "text": "*", "parent": 84, "children": [], "start_point": {"row": 11, "column": 18}, "end_point": {"row": 11, "column": 19}}, {"id": 86, "type": "identifier", "text": "temp", "parent": 84, "children": [], "start_point": {"row": 11, "column": 19}, "end_point": {"row": 11, "column": 23}}, {"id": 87, "type": "=", "text": "=", "parent": 83, "children": [], "start_point": {"row": 11, "column": 24}, "end_point": {"row": 11, "column": 25}}, {"id": 88, "type": "field_expression", "text": "ptr->rch", "parent": 83, "children": [89, 90], "start_point": {"row": 11, "column": 26}, "end_point": {"row": 11, "column": 34}}, {"id": 89, "type": "identifier", "text": "ptr", "parent": 88, "children": [], "start_point": {"row": 11, "column": 26}, "end_point": {"row": 11, "column": 29}}, {"id": 90, "type": "field_identifier", "text": "rch", "parent": 88, "children": [], "start_point": {"row": 11, "column": 31}, "end_point": {"row": 11, "column": 34}}, {"id": 91, "type": "call_expression", "text": "free(ptr)", "parent": 70, "children": [92, 93], "start_point": {"row": 12, "column": 3}, "end_point": {"row": 12, "column": 12}}, {"id": 92, "type": "identifier", "text": "free", "parent": 91, "children": [], "start_point": {"row": 12, "column": 3}, "end_point": {"row": 12, "column": 7}}, {"id": 93, "type": "argument_list", "text": "(ptr)", "parent": 91, "children": [94], "start_point": {"row": 12, "column": 7}, "end_point": {"row": 12, "column": 12}}, {"id": 94, "type": "identifier", "text": "ptr", "parent": 93, "children": [], "start_point": {"row": 12, "column": 8}, "end_point": {"row": 12, "column": 11}}, {"id": 95, "type": "return_statement", "text": "return temp;", "parent": 70, "children": [96], "start_point": {"row": 13, "column": 3}, "end_point": {"row": 13, "column": 15}}, {"id": 96, "type": "identifier", "text": "temp", "parent": 95, "children": [], "start_point": {"row": 13, "column": 10}, "end_point": {"row": 13, "column": 14}}, {"id": 97, "type": "else_clause", "text": "else if (ptr->rch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->lch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}", "parent": 70, "children": [98], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 20, "column": 3}}, {"id": 98, "type": "if_statement", "text": "if (ptr->rch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->lch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}", "parent": 97, "children": [99], "start_point": {"row": 15, "column": 7}, "end_point": {"row": 20, "column": 3}}, {"id": 99, "type": "parenthesized_expression", "text": "(ptr->rch == NULL)", "parent": 98, "children": [100], "start_point": {"row": 15, "column": 10}, "end_point": {"row": 15, "column": 28}}, {"id": 100, "type": "binary_expression", "text": "ptr->rch == NULL", "parent": 99, "children": [101, 104, 105], "start_point": {"row": 15, "column": 11}, "end_point": {"row": 15, "column": 27}}, {"id": 101, "type": "field_expression", "text": "ptr->rch", "parent": 100, "children": [102, 103], "start_point": {"row": 15, "column": 11}, "end_point": {"row": 15, "column": 19}}, {"id": 102, "type": "identifier", "text": "ptr", "parent": 101, "children": [], "start_point": {"row": 15, "column": 11}, "end_point": {"row": 15, "column": 14}}, {"id": 103, "type": "field_identifier", "text": "rch", "parent": 101, "children": [], "start_point": {"row": 15, "column": 16}, "end_point": {"row": 15, "column": 19}}, {"id": 104, "type": "==", "text": "==", "parent": 100, "children": [], "start_point": {"row": 15, "column": 20}, "end_point": {"row": 15, "column": 22}}, {"id": 105, "type": "null", "text": "NULL", "parent": 100, "children": [106], "start_point": {"row": 15, "column": 23}, "end_point": {"row": 15, "column": 27}}, {"id": 106, "type": "NULL", "text": "NULL", "parent": 105, "children": [], "start_point": {"row": 15, "column": 23}, "end_point": {"row": 15, "column": 27}}, {"id": 107, "type": "declaration", "text": "struct bintree *temp = ptr->lch;", "parent": 98, "children": [108, 111], "start_point": {"row": 17, "column": 3}, "end_point": {"row": 17, "column": 35}}, {"id": 108, "type": "struct_specifier", "text": "struct bintree", "parent": 107, "children": [109, 110], "start_point": {"row": 17, "column": 3}, "end_point": {"row": 17, "column": 17}}, {"id": 109, "type": "struct", "text": "struct", "parent": 108, "children": [], "start_point": {"row": 17, "column": 3}, "end_point": {"row": 17, "column": 9}}, {"id": 110, "type": "type_identifier", "text": "bintree", "parent": 108, "children": [], "start_point": {"row": 17, "column": 10}, "end_point": {"row": 17, "column": 17}}, {"id": 111, "type": "init_declarator", "text": "*temp = ptr->lch", "parent": 107, "children": [112, 115, 116], "start_point": {"row": 17, "column": 18}, "end_point": {"row": 17, "column": 34}}, {"id": 112, "type": "pointer_declarator", "text": "*temp", "parent": 111, "children": [113, 114], "start_point": {"row": 17, "column": 18}, "end_point": {"row": 17, "column": 23}}, {"id": 113, "type": "*", "text": "*", "parent": 112, "children": [], "start_point": {"row": 17, "column": 18}, "end_point": {"row": 17, "column": 19}}, {"id": 114, "type": "identifier", "text": "temp", "parent": 112, "children": [], "start_point": {"row": 17, "column": 19}, "end_point": {"row": 17, "column": 23}}, {"id": 115, "type": "=", "text": "=", "parent": 111, "children": [], "start_point": {"row": 17, "column": 24}, "end_point": {"row": 17, "column": 25}}, {"id": 116, "type": "field_expression", "text": "ptr->lch", "parent": 111, "children": [117, 118], "start_point": {"row": 17, "column": 26}, "end_point": {"row": 17, "column": 34}}, {"id": 117, "type": "identifier", "text": "ptr", "parent": 116, "children": [], "start_point": {"row": 17, "column": 26}, "end_point": {"row": 17, "column": 29}}, {"id": 118, "type": "field_identifier", "text": "lch", "parent": 116, "children": [], "start_point": {"row": 17, "column": 31}, "end_point": {"row": 17, "column": 34}}, {"id": 119, "type": "call_expression", "text": "free(ptr)", "parent": 98, "children": [120, 121], "start_point": {"row": 18, "column": 3}, "end_point": {"row": 18, "column": 12}}, {"id": 120, "type": "identifier", "text": "free", "parent": 119, "children": [], "start_point": {"row": 18, "column": 3}, "end_point": {"row": 18, "column": 7}}, {"id": 121, "type": "argument_list", "text": "(ptr)", "parent": 119, "children": [122], "start_point": {"row": 18, "column": 7}, "end_point": {"row": 18, "column": 12}}, {"id": 122, "type": "identifier", "text": "ptr", "parent": 121, "children": [], "start_point": {"row": 18, "column": 8}, "end_point": {"row": 18, "column": 11}}, {"id": 123, "type": "return_statement", "text": "return temp;", "parent": 98, "children": [124], "start_point": {"row": 19, "column": 3}, "end_point": {"row": 19, "column": 15}}, {"id": 124, "type": "identifier", "text": "temp", "parent": 123, "children": [], "start_point": {"row": 19, "column": 10}, "end_point": {"row": 19, "column": 14}}, {"id": 125, "type": "declaration", "text": "struct bintree* temp = find_min(ptr->rch);", "parent": 69, "children": [126, 129], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 44}}, {"id": 126, "type": "struct_specifier", "text": "struct bintree", "parent": 125, "children": [127, 128], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 16}}, {"id": 127, "type": "struct", "text": "struct", "parent": 126, "children": [], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 8}}, {"id": 128, "type": "type_identifier", "text": "bintree", "parent": 126, "children": [], "start_point": {"row": 21, "column": 9}, "end_point": {"row": 21, "column": 16}}, {"id": 129, "type": "init_declarator", "text": "* temp = find_min(ptr->rch)", "parent": 125, "children": [130, 133, 134], "start_point": {"row": 21, "column": 16}, "end_point": {"row": 21, "column": 43}}, {"id": 130, "type": "pointer_declarator", "text": "* temp", "parent": 129, "children": [131, 132], "start_point": {"row": 21, "column": 16}, "end_point": {"row": 21, "column": 22}}, {"id": 131, "type": "*", "text": "*", "parent": 130, "children": [], "start_point": {"row": 21, "column": 16}, "end_point": {"row": 21, "column": 17}}, {"id": 132, "type": "identifier", "text": "temp", "parent": 130, "children": [], "start_point": {"row": 21, "column": 18}, "end_point": {"row": 21, "column": 22}}, {"id": 133, "type": "=", "text": "=", "parent": 129, "children": [], "start_point": {"row": 21, "column": 23}, "end_point": {"row": 21, "column": 24}}, {"id": 134, "type": "call_expression", "text": "find_min(ptr->rch)", "parent": 129, "children": [135, 136], "start_point": {"row": 21, "column": 25}, "end_point": {"row": 21, "column": 43}}, {"id": 135, "type": "identifier", "text": "find_min", "parent": 134, "children": [], "start_point": {"row": 21, "column": 25}, "end_point": {"row": 21, "column": 33}}, {"id": 136, "type": "argument_list", "text": "(ptr->rch)", "parent": 134, "children": [137], "start_point": {"row": 21, "column": 33}, "end_point": {"row": 21, "column": 43}}, {"id": 137, "type": "field_expression", "text": "ptr->rch", "parent": 136, "children": [138, 139], "start_point": {"row": 21, "column": 34}, "end_point": {"row": 21, "column": 42}}, {"id": 138, "type": "identifier", "text": "ptr", "parent": 137, "children": [], "start_point": {"row": 21, "column": 34}, "end_point": {"row": 21, "column": 37}}, {"id": 139, "type": "field_identifier", "text": "rch", "parent": 137, "children": [], "start_point": {"row": 21, "column": 39}, "end_point": {"row": 21, "column": 42}}, {"id": 140, "type": "assignment_expression", "text": "ptr->ch = temp->ch", "parent": 69, "children": [141, 144, 145], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 22, "column": 20}}, {"id": 141, "type": "field_expression", "text": "ptr->ch", "parent": 140, "children": [142, 143], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 22, "column": 9}}, {"id": 142, "type": "identifier", "text": "ptr", "parent": 141, "children": [], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 22, "column": 5}}, {"id": 143, "type": "field_identifier", "text": "ch", "parent": 141, "children": [], "start_point": {"row": 22, "column": 7}, "end_point": {"row": 22, "column": 9}}, {"id": 144, "type": "=", "text": "=", "parent": 140, "children": [], "start_point": {"row": 22, "column": 10}, "end_point": {"row": 22, "column": 11}}, {"id": 145, "type": "field_expression", "text": "temp->ch", "parent": 140, "children": [146, 147], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 20}}, {"id": 146, "type": "identifier", "text": "temp", "parent": 145, "children": [], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 16}}, {"id": 147, "type": "field_identifier", "text": "ch", "parent": 145, "children": [], "start_point": {"row": 22, "column": 18}, "end_point": {"row": 22, "column": 20}}, {"id": 148, "type": "assignment_expression", "text": "ptr->rch = delete_it(temp->ch,ptr->rch)", "parent": 69, "children": [149, 152, 153], "start_point": {"row": 23, "column": 2}, "end_point": {"row": 23, "column": 41}}, {"id": 149, "type": "field_expression", "text": "ptr->rch", "parent": 148, "children": [150, 151], "start_point": {"row": 23, "column": 2}, "end_point": {"row": 23, "column": 10}}, {"id": 150, "type": "identifier", "text": "ptr", "parent": 149, "children": [], "start_point": {"row": 23, "column": 2}, "end_point": {"row": 23, "column": 5}}, {"id": 151, "type": "field_identifier", "text": "rch", "parent": 149, "children": [], "start_point": {"row": 23, "column": 7}, "end_point": {"row": 23, "column": 10}}, {"id": 152, "type": "=", "text": "=", "parent": 148, "children": [], "start_point": {"row": 23, "column": 11}, "end_point": {"row": 23, "column": 12}}, {"id": 153, "type": "call_expression", "text": "delete_it(temp->ch,ptr->rch)", "parent": 148, "children": [154, 155], "start_point": {"row": 23, "column": 13}, "end_point": {"row": 23, "column": 41}}, {"id": 154, "type": "identifier", "text": "delete_it", "parent": 153, "children": [], "start_point": {"row": 23, "column": 13}, "end_point": {"row": 23, "column": 22}}, {"id": 155, "type": "argument_list", "text": "(temp->ch,ptr->rch)", "parent": 153, "children": [156, 159], "start_point": {"row": 23, "column": 22}, "end_point": {"row": 23, "column": 41}}, {"id": 156, "type": "field_expression", "text": "temp->ch", "parent": 155, "children": [157, 158], "start_point": {"row": 23, "column": 23}, "end_point": {"row": 23, "column": 31}}, {"id": 157, "type": "identifier", "text": "temp", "parent": 156, "children": [], "start_point": {"row": 23, "column": 23}, "end_point": {"row": 23, "column": 27}}, {"id": 158, "type": "field_identifier", "text": "ch", "parent": 156, "children": [], "start_point": {"row": 23, "column": 29}, "end_point": {"row": 23, "column": 31}}, {"id": 159, "type": "field_expression", "text": "ptr->rch", "parent": 155, "children": [160, 161], "start_point": {"row": 23, "column": 32}, "end_point": {"row": 23, "column": 40}}, {"id": 160, "type": "identifier", "text": "ptr", "parent": 159, "children": [], "start_point": {"row": 23, "column": 32}, "end_point": {"row": 23, "column": 35}}, {"id": 161, "type": "field_identifier", "text": "rch", "parent": 159, "children": [], "start_point": {"row": 23, "column": 37}, "end_point": {"row": 23, "column": 40}}, {"id": 162, "type": "return_statement", "text": "return ptr;", "parent": 0, "children": [163], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 25, "column": 12}}, {"id": 163, "type": "identifier", "text": "ptr", "parent": 162, "children": [], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 11}}]}, "node_categories": {"declarations": {"functions": [0, 6], "variables": [9, 12, 79, 107, 125], "classes": [1, 2, 13, 14, 80, 81, 108, 109, 126, 127], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [20, 21, 29, 30, 33, 37, 41, 45, 50, 51, 54, 58, 62, 66, 71, 72, 73, 88, 91, 99, 100, 101, 116, 119, 134, 137, 141, 145, 149, 153, 156, 159], "assignments": [36, 57, 140, 148], "loops": [], "conditionals": [3, 7, 11, 15, 18, 19, 22, 27, 28, 31, 34, 35, 38, 39, 42, 44, 46, 47, 49, 52, 55, 56, 59, 60, 63, 65, 67, 68, 70, 74, 75, 82, 86, 89, 90, 92, 94, 96, 98, 102, 103, 110, 114, 117, 118, 120, 122, 124, 128, 132, 135, 138, 139, 142, 143, 146, 147, 150, 151, 154, 157, 158, 160, 161, 163], "returns": [26, 95, 123, 162], "exceptions": []}, "expressions": {"calls": [], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 0, "universal_type": "function", "name": "bintree", "text_snippet": "struct bintree *delete_it(char ch1,struct bintree *ptr)\n{\n\tif (ptr == NULL) return ptr;\n\tif (ch1 < p"}, {"node_id": 6, "universal_type": "function", "name": "unknown", "text_snippet": "delete_it(char ch1,struct bintree *ptr)"}], "class_declarations": [{"node_id": 1, "universal_type": "class", "name": "bintree", "text_snippet": "struct bintree"}, {"node_id": 2, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 13, "universal_type": "class", "name": "bintree", "text_snippet": "struct bintree"}, {"node_id": 14, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 80, "universal_type": "class", "name": "bintree", "text_snippet": "struct bintree"}, {"node_id": 81, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 108, "universal_type": "class", "name": "bintree", "text_snippet": "struct bintree"}, {"node_id": 109, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 126, "universal_type": "class", "name": "bintree", "text_snippet": "struct bintree"}, {"node_id": 127, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": []}, "original_source_code": "struct bintree *delete_it(char ch1,struct bintree *ptr)\n{\n\tif (ptr == NULL) return ptr;\n\tif (ch1 < ptr->ch)\n\t\tptr->lch = delete_it(ch1,ptr->lch);\n\telse if (ch1 > ptr->ch)\n\t\tptr->rch = delete_it(ch1,ptr->rch);\n\telse\n\t{\n\t\tif (ptr->lch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->rch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}\n\t\telse if (ptr->rch == NULL)\n\t\t{\n\t\t\tstruct bintree *temp = ptr->lch;\n\t\t\tfree(ptr);\n\t\t\treturn temp;\n\t\t}\n\t\tstruct bintree* temp = find_min(ptr->rch);\n\t\tptr->ch = temp->ch;\n\t\tptr->rch = delete_it(temp->ch,ptr->rch);\n\t}\n\treturn ptr;\n}\n"}
80,534
c
#include "Malloc.h" #include <stdio.h> #include <stdlib.h> #include <assert.h> #include <sys/unistd.h> #include <unistd.h> #include <sys/types.h> #include <stdbool.h> #include <errno.h> #include <stdatomic.h> #ifndef HEAP_SIZE #define HEAP_SIZE 33554432u #endif #define ALIGN4(x) (((((x) - 1) >> 2) << 2) + 4) #define foreach(ptr, List) for(ptr = *List; ptr != NULL; ptr = ptr->next) #define getHeader(ptr) (((Block)ptr)-1); #define BlockSize(ptr) (ptr->Info.Field.size) #define isFreeBlock(ptr) (ptr->Info.Field.free) typedef struct Block { struct Block* next; union { unsigned int BlockInfo; struct { unsigned size:31; unsigned free:1; }Field; }Info; unsigned int id; }*Block; struct { void* baseHeap; Block LastBlockReleased; void* CurrentPointerHeap; Block* ListBlocks; }Gerency; static unsigned int memoryUsage; static unsigned int numberBlocks; static unsigned int numberFreeBlocks; static unsigned int numberFragmentation; static unsigned int totalAllocatedMemory; static const unsigned int MAX_FRAGMENTATION_BLOCK = 10U; enum AllocationAlgorithm AAlgorithm = FIRST_FIT; static void __attribute__((constructor))InitMalloc(void) { void* response; puts("\n\n"); Gerency.baseHeap = sbrk(0); response = sbrk(ALIGN4(HEAP_SIZE)); totalAllocatedMemory += ALIGN4(HEAP_SIZE); assert(!(response == (void*)-1)); Gerency.ListBlocks = sbrk(0); response = sbrk(sizeof(Block)); totalAllocatedMemory += sizeof(Block); assert(!(response == (void*)-1)); *(Gerency.ListBlocks) = NULL; Gerency.LastBlockReleased = NULL; numberBlocks = 0; Gerency.CurrentPointerHeap = Gerency.baseHeap; } void* myMalloc(unsigned int size) { Block newBlock; Block scroll; Block previousScroll; Block enjoyBlock; Block tempBlock; Block* headerList; int spaceFree = 0; int spaceEvaluation = 0; size = ALIGN4(size); if((Gerency.CurrentPointerHeap) - (Gerency.baseHeap) == HEAP_SIZE) return NULL; if(((Gerency.CurrentPointerHeap) + size) >= (void*)HEAP_SIZE) { return NULL; } if((*(Gerency.ListBlocks)) == NULL) { newBlock = Gerency.CurrentPointerHeap; newBlock->next = NULL; newBlock->Info.Field.free = 0; newBlock->Info.Field.size = size; newBlock->id = numberBlocks; *(Gerency.ListBlocks) = newBlock; numberBlocks += 1; Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size)); memoryUsage += ((sizeof(struct Block) + size)); } else { if((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK)) { enjoyBlock = Gerency.LastBlockReleased; enjoyBlock->Info.Field.free = 0; Gerency.LastBlockReleased = NULL; numberFragmentation += BlockSize(enjoyBlock) - size; numberFreeBlocks -= 1; return (enjoyBlock + 1); } else { switch(AAlgorithm) { case FIRST_FIT: try_first_fit: foreach(enjoyBlock,(Gerency.ListBlocks)) { if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock))) { enjoyBlock->Info.Field.free = 0; numberFreeBlocks -= 1; numberFragmentation += BlockSize(enjoyBlock) - size; return (enjoyBlock + 1); } } break; case BEST_FIT: spaceFree = BlockSize((*(Gerency.ListBlocks))) - size; tempBlock = *(Gerency.ListBlocks); foreach(enjoyBlock, Gerency.ListBlocks) { spaceEvaluation = BlockSize(enjoyBlock) - size; if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock)))) { spaceFree = spaceEvaluation; tempBlock = enjoyBlock; } } if(spaceFree < 0) { break; } else if(isFreeBlock(tempBlock)) { tempBlock->Info.Field.free = 0; numberFragmentation += BlockSize(tempBlock) - size; return (tempBlock + 1); } break; case WORST_FIT: spaceFree = BlockSize((*(Gerency.ListBlocks))) - size; tempBlock = *(Gerency.ListBlocks); foreach(enjoyBlock, (Gerency.ListBlocks)) { spaceEvaluation = BlockSize(enjoyBlock) - size; if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock)))) { spaceFree = spaceEvaluation; tempBlock = enjoyBlock; } } if(isFreeBlock(tempBlock)) { tempBlock->Info.Field.free = 0; return (tempBlock + 1); } break; default: goto try_first_fit; } scroll = *(Gerency.ListBlocks); while((scroll != NULL) && (BlockSize(scroll) < size)) { previousScroll = scroll; scroll = scroll->next; } newBlock = Gerency.CurrentPointerHeap; newBlock->Info.Field.free = 0; newBlock->Info.Field.size = size; newBlock->id = numberBlocks; numberBlocks += 1; if(scroll == *(Gerency.ListBlocks) ) { newBlock->next = *(Gerency.ListBlocks); *(Gerency.ListBlocks) = newBlock; } else { newBlock->next = previousScroll->next; previousScroll->next = newBlock; } Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size)); memoryUsage += ((sizeof(struct Block) + size)); } } return (newBlock + 1); } void* myCalloc(unsigned int length, unsigned int size) { } int myMallocFree(void* ptr) { Block releaseBlock; releaseBlock = getHeader(ptr); releaseBlock->Info.Field.free = 1; if(Gerency.LastBlockReleased == NULL) { Gerency.LastBlockReleased = releaseBlock; } numberFreeBlocks += 1; } void __attribute__((destructor))Exit(void) { Block p; printf("Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes\n\n", HEAP_SIZE, totalAllocatedMemory); printf("Memory Usage: %u Bytes \n\n",memoryUsage); printf("Internal Fragmentation: %u Bytes \n\n", numberFragmentation); foreach(p, (Gerency.ListBlocks)) { printf("Block ID: %u ", p->id); printf("Size: %u ", BlockSize(p)); printf("Free: %s\n", isFreeBlock(p)?"True":"False"); puts(" "); } }
24.42
231
(translation_unit) "#include "Malloc.h"\n#include <stdio.h>\n#include <stdlib.h>\n#include <assert.h>\n#include <sys/unistd.h>\n#include <unistd.h>\n#include <sys/types.h>\n#include <stdbool.h>\n#include <errno.h>\n#include <stdatomic.h>\n\n#ifndef HEAP_SIZE \n #define HEAP_SIZE 33554432u\n#endif\n\n#define ALIGN4(x) (((((x) - 1) >> 2) << 2) + 4)\n\n#define foreach(ptr, List) for(ptr = *List; ptr != NULL; ptr = ptr->next)\n\n#define getHeader(ptr) (((Block)ptr)-1);\n\n#define BlockSize(ptr) (ptr->Info.Field.size)\n#define isFreeBlock(ptr) (ptr->Info.Field.free)\n\n\ntypedef struct Block\n{\n struct Block* next;\n\n union\n {\n unsigned int BlockInfo;\n struct \n {\n unsigned size:31;\n unsigned free:1;\n }Field;\n }Info;\n unsigned int id;\n}*Block;\n\nstruct \n{\n void* baseHeap;\n Block LastBlockReleased;\n void* CurrentPointerHeap;\n Block* ListBlocks;\n}Gerency;\n\n\nstatic unsigned int memoryUsage;\nstatic unsigned int numberBlocks;\nstatic unsigned int numberFreeBlocks;\nstatic unsigned int numberFragmentation;\nstatic unsigned int totalAllocatedMemory;\nstatic const unsigned int MAX_FRAGMENTATION_BLOCK = 10U;\nenum AllocationAlgorithm AAlgorithm = FIRST_FIT;\n\n\n\nstatic void __attribute__((constructor))InitMalloc(void)\n{\n void* response;\n\n puts("\n\n");\n\n Gerency.baseHeap = sbrk(0);\n response = sbrk(ALIGN4(HEAP_SIZE));\n\n totalAllocatedMemory += ALIGN4(HEAP_SIZE);\n\n assert(!(response == (void*)-1));\n\n Gerency.ListBlocks = sbrk(0);\n response = sbrk(sizeof(Block));\n \n totalAllocatedMemory += sizeof(Block);\n\n\n assert(!(response == (void*)-1));\n\n *(Gerency.ListBlocks) = NULL;\n Gerency.LastBlockReleased = NULL;\n numberBlocks = 0;\n Gerency.CurrentPointerHeap = Gerency.baseHeap;\n}\n\n\nvoid* myMalloc(unsigned int size)\n{\n Block newBlock;\n Block scroll;\n Block previousScroll;\n Block enjoyBlock;\n Block tempBlock;\n Block* headerList;\n int spaceFree = 0;\n int spaceEvaluation = 0;\n\n size = ALIGN4(size);\n\n if((Gerency.CurrentPointerHeap) - (Gerency.baseHeap) == HEAP_SIZE)\n return NULL;\n\n if(((Gerency.CurrentPointerHeap) + size) >= (void*)HEAP_SIZE)\n {\n return NULL;\n }\n\n if((*(Gerency.ListBlocks)) == NULL)\n {\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->next = NULL;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n *(Gerency.ListBlocks) = newBlock;\n \n numberBlocks += 1;\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n } \n else\n {\n if((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))\n {\n enjoyBlock = Gerency.LastBlockReleased;\n enjoyBlock->Info.Field.free = 0;\n Gerency.LastBlockReleased = NULL;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n numberFreeBlocks -= 1;\n return (enjoyBlock + 1);\n }\n else\n {\n switch(AAlgorithm)\n {\n case FIRST_FIT:\n try_first_fit:\n\n\n foreach(enjoyBlock,(Gerency.ListBlocks))\n {\n if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }\n }\n\n break;\n\n case BEST_FIT:\n\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, Gerency.ListBlocks)\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n if(spaceFree < 0)\n {\n break;\n }\n else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }\n\n break;\n\n\n case WORST_FIT:\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, (Gerency.ListBlocks))\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n\n if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n\n if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }\n\n break;\n\n default:\n goto try_first_fit;\n\n }\n\n scroll = *(Gerency.ListBlocks);\n\n while((scroll != NULL) && (BlockSize(scroll) < size))\n {\n previousScroll = scroll;\n scroll = scroll->next;\n }\n\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n numberBlocks += 1;\n\n if(scroll == *(Gerency.ListBlocks) )\n {\n newBlock->next = *(Gerency.ListBlocks);\n *(Gerency.ListBlocks) = newBlock;\n }\n \n else\n {\n newBlock->next = previousScroll->next;\n previousScroll->next = newBlock;\n }\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n }\n }\n\n return (newBlock + 1);\n}\n\nvoid* myCalloc(unsigned int length, unsigned int size)\n{\n\n}\n\nint myMallocFree(void* ptr)\n{\n Block releaseBlock;\n\n releaseBlock = getHeader(ptr);\n releaseBlock->Info.Field.free = 1;\n\n if(Gerency.LastBlockReleased == NULL)\n {\n Gerency.LastBlockReleased = releaseBlock;\n }\n numberFreeBlocks += 1;\n}\n\nvoid __attribute__((destructor))Exit(void)\n{\n Block p;\n\n printf("Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes\n\n", HEAP_SIZE, totalAllocatedMemory);\n printf("Memory Usage: %u Bytes \n\n",memoryUsage);\n printf("Internal Fragmentation: %u Bytes \n\n", numberFragmentation);\n \n foreach(p, (Gerency.ListBlocks))\n {\n printf("Block ID: %u ", p->id);\n printf("Size: %u ", BlockSize(p));\n printf("Free: %s\n", isFreeBlock(p)?"True":"False");\n puts(" ");\n }\n}" (preproc_include) "#include "Malloc.h"\n" (#include) "#include" (string_literal) ""Malloc.h"" (") """ (string_content) "Malloc.h" (") """ (preproc_include) "#include <stdio.h>\n" (#include) "#include" (system_lib_string) "<stdio.h>" (preproc_include) "#include <stdlib.h>\n" (#include) "#include" (system_lib_string) "<stdlib.h>" (preproc_include) "#include <assert.h>\n" (#include) "#include" (system_lib_string) "<assert.h>" (preproc_include) "#include <sys/unistd.h>\n" (#include) "#include" (system_lib_string) "<sys/unistd.h>" (preproc_include) "#include <unistd.h>\n" (#include) "#include" (system_lib_string) "<unistd.h>" (preproc_include) "#include <sys/types.h>\n" (#include) "#include" (system_lib_string) "<sys/types.h>" (preproc_include) "#include <stdbool.h>\n" (#include) "#include" (system_lib_string) "<stdbool.h>" (preproc_include) "#include <errno.h>\n" (#include) "#include" (system_lib_string) "<errno.h>" (preproc_include) "#include <stdatomic.h>\n" (#include) "#include" (system_lib_string) "<stdatomic.h>" (preproc_ifdef) "#ifndef HEAP_SIZE \n #define HEAP_SIZE 33554432u\n#endif" (#ifndef) "#ifndef" (identifier) "HEAP_SIZE" (preproc_def) "#define HEAP_SIZE 33554432u\n" (#define) "#define" (identifier) "HEAP_SIZE" (preproc_arg) "33554432u" (#endif) "#endif" (preproc_function_def) "#define ALIGN4(x) (((((x) - 1) >> 2) << 2) + 4)\n" (#define) "#define" (identifier) "ALIGN4" (preproc_params) "(x)" (() "(" (identifier) "x" ()) ")" (preproc_arg) "(((((x) - 1) >> 2) << 2) + 4)" (preproc_function_def) "#define foreach(ptr, List) for(ptr = *List; ptr != NULL; ptr = ptr->next)\n" (#define) "#define" (identifier) "foreach" (preproc_params) "(ptr, List)" (() "(" (identifier) "ptr" (,) "," (identifier) "List" ()) ")" (preproc_arg) "for(ptr = *List; ptr != NULL; ptr = ptr->next)" (preproc_function_def) "#define getHeader(ptr) (((Block)ptr)-1);\n" (#define) "#define" (identifier) "getHeader" (preproc_params) "(ptr)" (() "(" (identifier) "ptr" ()) ")" (preproc_arg) "(((Block)ptr)-1);" (preproc_function_def) "#define BlockSize(ptr) (ptr->Info.Field.size)\n" (#define) "#define" (identifier) "BlockSize" (preproc_params) "(ptr)" (() "(" (identifier) "ptr" ()) ")" (preproc_arg) "(ptr->Info.Field.size)" (preproc_function_def) "#define isFreeBlock(ptr) (ptr->Info.Field.free)\n" (#define) "#define" (identifier) "isFreeBlock" (preproc_params) "(ptr)" (() "(" (identifier) "ptr" ()) ")" (preproc_arg) "(ptr->Info.Field.free)" (type_definition) "typedef struct Block\n{\n struct Block* next;\n\n union\n {\n unsigned int BlockInfo;\n struct \n {\n unsigned size:31;\n unsigned free:1;\n }Field;\n }Info;\n unsigned int id;\n}*Block;" (typedef) "typedef" (struct_specifier) "struct Block\n{\n struct Block* next;\n\n union\n {\n unsigned int BlockInfo;\n struct \n {\n unsigned size:31;\n unsigned free:1;\n }Field;\n }Info;\n unsigned int id;\n}" (struct) "struct" (type_identifier) "Block" (field_declaration_list) "{\n struct Block* next;\n\n union\n {\n unsigned int BlockInfo;\n struct \n {\n unsigned size:31;\n unsigned free:1;\n }Field;\n }Info;\n unsigned int id;\n}" ({) "{" (field_declaration) "struct Block* next;" (struct_specifier) "struct Block" (struct) "struct" (type_identifier) "Block" (pointer_declarator) "* next" (*) "*" (field_identifier) "next" (;) ";" (field_declaration) "union\n {\n unsigned int BlockInfo;\n struct \n {\n unsigned size:31;\n unsigned free:1;\n }Field;\n }Info;" (union_specifier) "union\n {\n unsigned int BlockInfo;\n struct \n {\n unsigned size:31;\n unsigned free:1;\n }Field;\n }" (union) "union" (field_declaration_list) "{\n unsigned int BlockInfo;\n struct \n {\n unsigned size:31;\n unsigned free:1;\n }Field;\n }" ({) "{" (field_declaration) "unsigned int BlockInfo;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "BlockInfo" (;) ";" (field_declaration) "struct \n {\n unsigned size:31;\n unsigned free:1;\n }Field;" (struct_specifier) "struct \n {\n unsigned size:31;\n unsigned free:1;\n }" (struct) "struct" (field_declaration_list) "{\n unsigned size:31;\n unsigned free:1;\n }" ({) "{" (field_declaration) "unsigned size:31;" (sized_type_specifier) "unsigned" (unsigned) "unsigned" (field_identifier) "size" (bitfield_clause) ":31" (:) ":" (number_literal) "31" (;) ";" (field_declaration) "unsigned free:1;" (sized_type_specifier) "unsigned" (unsigned) "unsigned" (field_identifier) "free" (bitfield_clause) ":1" (:) ":" (number_literal) "1" (;) ";" (}) "}" (field_identifier) "Field" (;) ";" (}) "}" (field_identifier) "Info" (;) ";" (field_declaration) "unsigned int id;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (field_identifier) "id" (;) ";" (}) "}" (pointer_declarator) "*Block" (*) "*" (type_identifier) "Block" (;) ";" (declaration) "struct \n{\n void* baseHeap;\n Block LastBlockReleased;\n void* CurrentPointerHeap;\n Block* ListBlocks;\n}Gerency;" (struct_specifier) "struct \n{\n void* baseHeap;\n Block LastBlockReleased;\n void* CurrentPointerHeap;\n Block* ListBlocks;\n}" (struct) "struct" (field_declaration_list) "{\n void* baseHeap;\n Block LastBlockReleased;\n void* CurrentPointerHeap;\n Block* ListBlocks;\n}" ({) "{" (field_declaration) "void* baseHeap;" (primitive_type) "void" (pointer_declarator) "* baseHeap" (*) "*" (field_identifier) "baseHeap" (;) ";" (field_declaration) "Block LastBlockReleased;" (type_identifier) "Block" (field_identifier) "LastBlockReleased" (;) ";" (field_declaration) "void* CurrentPointerHeap;" (primitive_type) "void" (pointer_declarator) "* CurrentPointerHeap" (*) "*" (field_identifier) "CurrentPointerHeap" (;) ";" (field_declaration) "Block* ListBlocks;" (type_identifier) "Block" (pointer_declarator) "* ListBlocks" (*) "*" (field_identifier) "ListBlocks" (;) ";" (}) "}" (identifier) "Gerency" (;) ";" (declaration) "static unsigned int memoryUsage;" (storage_class_specifier) "static" (static) "static" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "memoryUsage" (;) ";" (declaration) "static unsigned int numberBlocks;" (storage_class_specifier) "static" (static) "static" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "numberBlocks" (;) ";" (declaration) "static unsigned int numberFreeBlocks;" (storage_class_specifier) "static" (static) "static" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "numberFreeBlocks" (;) ";" (declaration) "static unsigned int numberFragmentation;" (storage_class_specifier) "static" (static) "static" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "numberFragmentation" (;) ";" (declaration) "static unsigned int totalAllocatedMemory;" (storage_class_specifier) "static" (static) "static" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "totalAllocatedMemory" (;) ";" (declaration) "static const unsigned int MAX_FRAGMENTATION_BLOCK = 10U;" (storage_class_specifier) "static" (static) "static" (type_qualifier) "const" (const) "const" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (init_declarator) "MAX_FRAGMENTATION_BLOCK = 10U" (identifier) "MAX_FRAGMENTATION_BLOCK" (=) "=" (number_literal) "10U" (;) ";" (declaration) "enum AllocationAlgorithm AAlgorithm = FIRST_FIT;" (enum_specifier) "enum AllocationAlgorithm" (enum) "enum" (type_identifier) "AllocationAlgorithm" (init_declarator) "AAlgorithm = FIRST_FIT" (identifier) "AAlgorithm" (=) "=" (identifier) "FIRST_FIT" (;) ";" (function_definition) "static void __attribute__((constructor))InitMalloc(void)\n{\n void* response;\n\n puts("\n\n");\n\n Gerency.baseHeap = sbrk(0);\n response = sbrk(ALIGN4(HEAP_SIZE));\n\n totalAllocatedMemory += ALIGN4(HEAP_SIZE);\n\n assert(!(response == (void*)-1));\n\n Gerency.ListBlocks = sbrk(0);\n response = sbrk(sizeof(Block));\n \n totalAllocatedMemory += sizeof(Block);\n\n\n assert(!(response == (void*)-1));\n\n *(Gerency.ListBlocks) = NULL;\n Gerency.LastBlockReleased = NULL;\n numberBlocks = 0;\n Gerency.CurrentPointerHeap = Gerency.baseHeap;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (attribute_specifier) "__attribute__((constructor))" (__attribute__) "__attribute__" (() "(" (argument_list) "(constructor)" (() "(" (identifier) "constructor" ()) ")" ()) ")" (function_declarator) "InitMalloc(void)" (identifier) "InitMalloc" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (compound_statement) "{\n void* response;\n\n puts("\n\n");\n\n Gerency.baseHeap = sbrk(0);\n response = sbrk(ALIGN4(HEAP_SIZE));\n\n totalAllocatedMemory += ALIGN4(HEAP_SIZE);\n\n assert(!(response == (void*)-1));\n\n Gerency.ListBlocks = sbrk(0);\n response = sbrk(sizeof(Block));\n \n totalAllocatedMemory += sizeof(Block);\n\n\n assert(!(response == (void*)-1));\n\n *(Gerency.ListBlocks) = NULL;\n Gerency.LastBlockReleased = NULL;\n numberBlocks = 0;\n Gerency.CurrentPointerHeap = Gerency.baseHeap;\n}" ({) "{" (declaration) "void* response;" (primitive_type) "void" (pointer_declarator) "* response" (*) "*" (identifier) "response" (;) ";" (expression_statement) "puts("\n\n");" (call_expression) "puts("\n\n")" (identifier) "puts" (argument_list) "("\n\n")" (() "(" (string_literal) ""\n\n"" (") """ (escape_sequence) "\n" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (expression_statement) "Gerency.baseHeap = sbrk(0);" (assignment_expression) "Gerency.baseHeap = sbrk(0)" (field_expression) "Gerency.baseHeap" (identifier) "Gerency" (.) "." (field_identifier) "baseHeap" (=) "=" (call_expression) "sbrk(0)" (identifier) "sbrk" (argument_list) "(0)" (() "(" (number_literal) "0" ()) ")" (;) ";" (expression_statement) "response = sbrk(ALIGN4(HEAP_SIZE));" (assignment_expression) "response = sbrk(ALIGN4(HEAP_SIZE))" (identifier) "response" (=) "=" (call_expression) "sbrk(ALIGN4(HEAP_SIZE))" (identifier) "sbrk" (argument_list) "(ALIGN4(HEAP_SIZE))" (() "(" (call_expression) "ALIGN4(HEAP_SIZE)" (identifier) "ALIGN4" (argument_list) "(HEAP_SIZE)" (() "(" (identifier) "HEAP_SIZE" ()) ")" ()) ")" (;) ";" (expression_statement) "totalAllocatedMemory += ALIGN4(HEAP_SIZE);" (assignment_expression) "totalAllocatedMemory += ALIGN4(HEAP_SIZE)" (identifier) "totalAllocatedMemory" (+=) "+=" (call_expression) "ALIGN4(HEAP_SIZE)" (identifier) "ALIGN4" (argument_list) "(HEAP_SIZE)" (() "(" (identifier) "HEAP_SIZE" ()) ")" (;) ";" (expression_statement) "assert(!(response == (void*)-1));" (call_expression) "assert(!(response == (void*)-1))" (identifier) "assert" (argument_list) "(!(response == (void*)-1))" (() "(" (unary_expression) "!(response == (void*)-1)" (!) "!" (parenthesized_expression) "(response == (void*)-1)" (() "(" (binary_expression) "response == (void*)-1" (identifier) "response" (==) "==" (cast_expression) "(void*)-1" (() "(" (type_descriptor) "void*" (primitive_type) "void" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (number_literal) "-1" ()) ")" ()) ")" (;) ";" (expression_statement) "Gerency.ListBlocks = sbrk(0);" (assignment_expression) "Gerency.ListBlocks = sbrk(0)" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" (=) "=" (call_expression) "sbrk(0)" (identifier) "sbrk" (argument_list) "(0)" (() "(" (number_literal) "0" ()) ")" (;) ";" (expression_statement) "response = sbrk(sizeof(Block));" (assignment_expression) "response = sbrk(sizeof(Block))" (identifier) "response" (=) "=" (call_expression) "sbrk(sizeof(Block))" (identifier) "sbrk" (argument_list) "(sizeof(Block))" (() "(" (sizeof_expression) "sizeof(Block)" (sizeof) "sizeof" (parenthesized_expression) "(Block)" (() "(" (identifier) "Block" ()) ")" ()) ")" (;) ";" (expression_statement) "totalAllocatedMemory += sizeof(Block);" (assignment_expression) "totalAllocatedMemory += sizeof(Block)" (identifier) "totalAllocatedMemory" (+=) "+=" (sizeof_expression) "sizeof(Block)" (sizeof) "sizeof" (parenthesized_expression) "(Block)" (() "(" (identifier) "Block" ()) ")" (;) ";" (expression_statement) "assert(!(response == (void*)-1));" (call_expression) "assert(!(response == (void*)-1))" (identifier) "assert" (argument_list) "(!(response == (void*)-1))" (() "(" (unary_expression) "!(response == (void*)-1)" (!) "!" (parenthesized_expression) "(response == (void*)-1)" (() "(" (binary_expression) "response == (void*)-1" (identifier) "response" (==) "==" (cast_expression) "(void*)-1" (() "(" (type_descriptor) "void*" (primitive_type) "void" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (number_literal) "-1" ()) ")" ()) ")" (;) ";" (expression_statement) "*(Gerency.ListBlocks) = NULL;" (assignment_expression) "*(Gerency.ListBlocks) = NULL" (pointer_expression) "*(Gerency.ListBlocks)" (*) "*" (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (expression_statement) "Gerency.LastBlockReleased = NULL;" (assignment_expression) "Gerency.LastBlockReleased = NULL" (field_expression) "Gerency.LastBlockReleased" (identifier) "Gerency" (.) "." (field_identifier) "LastBlockReleased" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (expression_statement) "numberBlocks = 0;" (assignment_expression) "numberBlocks = 0" (identifier) "numberBlocks" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "Gerency.CurrentPointerHeap = Gerency.baseHeap;" (assignment_expression) "Gerency.CurrentPointerHeap = Gerency.baseHeap" (field_expression) "Gerency.CurrentPointerHeap" (identifier) "Gerency" (.) "." (field_identifier) "CurrentPointerHeap" (=) "=" (field_expression) "Gerency.baseHeap" (identifier) "Gerency" (.) "." (field_identifier) "baseHeap" (;) ";" (}) "}" (function_definition) "void* myMalloc(unsigned int size)\n{\n Block newBlock;\n Block scroll;\n Block previousScroll;\n Block enjoyBlock;\n Block tempBlock;\n Block* headerList;\n int spaceFree = 0;\n int spaceEvaluation = 0;\n\n size = ALIGN4(size);\n\n if((Gerency.CurrentPointerHeap) - (Gerency.baseHeap) == HEAP_SIZE)\n return NULL;\n\n if(((Gerency.CurrentPointerHeap) + size) >= (void*)HEAP_SIZE)\n {\n return NULL;\n }\n\n if((*(Gerency.ListBlocks)) == NULL)\n {\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->next = NULL;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n *(Gerency.ListBlocks) = newBlock;\n \n numberBlocks += 1;\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n } \n else\n {\n if((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))\n {\n enjoyBlock = Gerency.LastBlockReleased;\n enjoyBlock->Info.Field.free = 0;\n Gerency.LastBlockReleased = NULL;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n numberFreeBlocks -= 1;\n return (enjoyBlock + 1);\n }\n else\n {\n switch(AAlgorithm)\n {\n case FIRST_FIT:\n try_first_fit:\n\n\n foreach(enjoyBlock,(Gerency.ListBlocks))\n {\n if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }\n }\n\n break;\n\n case BEST_FIT:\n\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, Gerency.ListBlocks)\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n if(spaceFree < 0)\n {\n break;\n }\n else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }\n\n break;\n\n\n case WORST_FIT:\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, (Gerency.ListBlocks))\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n\n if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n\n if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }\n\n break;\n\n default:\n goto try_first_fit;\n\n }\n\n scroll = *(Gerency.ListBlocks);\n\n while((scroll != NULL) && (BlockSize(scroll) < size))\n {\n previousScroll = scroll;\n scroll = scroll->next;\n }\n\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n numberBlocks += 1;\n\n if(scroll == *(Gerency.ListBlocks) )\n {\n newBlock->next = *(Gerency.ListBlocks);\n *(Gerency.ListBlocks) = newBlock;\n }\n \n else\n {\n newBlock->next = previousScroll->next;\n previousScroll->next = newBlock;\n }\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n }\n }\n\n return (newBlock + 1);\n}" (primitive_type) "void" (pointer_declarator) "* myMalloc(unsigned int size)" (*) "*" (function_declarator) "myMalloc(unsigned int size)" (identifier) "myMalloc" (parameter_list) "(unsigned int size)" (() "(" (parameter_declaration) "unsigned int size" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "size" ()) ")" (compound_statement) "{\n Block newBlock;\n Block scroll;\n Block previousScroll;\n Block enjoyBlock;\n Block tempBlock;\n Block* headerList;\n int spaceFree = 0;\n int spaceEvaluation = 0;\n\n size = ALIGN4(size);\n\n if((Gerency.CurrentPointerHeap) - (Gerency.baseHeap) == HEAP_SIZE)\n return NULL;\n\n if(((Gerency.CurrentPointerHeap) + size) >= (void*)HEAP_SIZE)\n {\n return NULL;\n }\n\n if((*(Gerency.ListBlocks)) == NULL)\n {\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->next = NULL;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n *(Gerency.ListBlocks) = newBlock;\n \n numberBlocks += 1;\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n } \n else\n {\n if((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))\n {\n enjoyBlock = Gerency.LastBlockReleased;\n enjoyBlock->Info.Field.free = 0;\n Gerency.LastBlockReleased = NULL;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n numberFreeBlocks -= 1;\n return (enjoyBlock + 1);\n }\n else\n {\n switch(AAlgorithm)\n {\n case FIRST_FIT:\n try_first_fit:\n\n\n foreach(enjoyBlock,(Gerency.ListBlocks))\n {\n if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }\n }\n\n break;\n\n case BEST_FIT:\n\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, Gerency.ListBlocks)\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n if(spaceFree < 0)\n {\n break;\n }\n else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }\n\n break;\n\n\n case WORST_FIT:\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, (Gerency.ListBlocks))\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n\n if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n\n if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }\n\n break;\n\n default:\n goto try_first_fit;\n\n }\n\n scroll = *(Gerency.ListBlocks);\n\n while((scroll != NULL) && (BlockSize(scroll) < size))\n {\n previousScroll = scroll;\n scroll = scroll->next;\n }\n\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n numberBlocks += 1;\n\n if(scroll == *(Gerency.ListBlocks) )\n {\n newBlock->next = *(Gerency.ListBlocks);\n *(Gerency.ListBlocks) = newBlock;\n }\n \n else\n {\n newBlock->next = previousScroll->next;\n previousScroll->next = newBlock;\n }\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n }\n }\n\n return (newBlock + 1);\n}" ({) "{" (declaration) "Block newBlock;" (type_identifier) "Block" (identifier) "newBlock" (;) ";" (declaration) "Block scroll;" (type_identifier) "Block" (identifier) "scroll" (;) ";" (declaration) "Block previousScroll;" (type_identifier) "Block" (identifier) "previousScroll" (;) ";" (declaration) "Block enjoyBlock;" (type_identifier) "Block" (identifier) "enjoyBlock" (;) ";" (declaration) "Block tempBlock;" (type_identifier) "Block" (identifier) "tempBlock" (;) ";" (declaration) "Block* headerList;" (type_identifier) "Block" (pointer_declarator) "* headerList" (*) "*" (identifier) "headerList" (;) ";" (declaration) "int spaceFree = 0;" (primitive_type) "int" (init_declarator) "spaceFree = 0" (identifier) "spaceFree" (=) "=" (number_literal) "0" (;) ";" (declaration) "int spaceEvaluation = 0;" (primitive_type) "int" (init_declarator) "spaceEvaluation = 0" (identifier) "spaceEvaluation" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "size = ALIGN4(size);" (assignment_expression) "size = ALIGN4(size)" (identifier) "size" (=) "=" (call_expression) "ALIGN4(size)" (identifier) "ALIGN4" (argument_list) "(size)" (() "(" (identifier) "size" ()) ")" (;) ";" (if_statement) "if((Gerency.CurrentPointerHeap) - (Gerency.baseHeap) == HEAP_SIZE)\n return NULL;" (if) "if" (parenthesized_expression) "((Gerency.CurrentPointerHeap) - (Gerency.baseHeap) == HEAP_SIZE)" (() "(" (binary_expression) "(Gerency.CurrentPointerHeap) - (Gerency.baseHeap) == HEAP_SIZE" (binary_expression) "(Gerency.CurrentPointerHeap) - (Gerency.baseHeap)" (parenthesized_expression) "(Gerency.CurrentPointerHeap)" (() "(" (field_expression) "Gerency.CurrentPointerHeap" (identifier) "Gerency" (.) "." (field_identifier) "CurrentPointerHeap" ()) ")" (-) "-" (parenthesized_expression) "(Gerency.baseHeap)" (() "(" (field_expression) "Gerency.baseHeap" (identifier) "Gerency" (.) "." (field_identifier) "baseHeap" ()) ")" (==) "==" (identifier) "HEAP_SIZE" ()) ")" (return_statement) "return NULL;" (return) "return" (null) "NULL" (NULL) "NULL" (;) ";" (if_statement) "if(((Gerency.CurrentPointerHeap) + size) >= (void*)HEAP_SIZE)\n {\n return NULL;\n }" (if) "if" (parenthesized_expression) "(((Gerency.CurrentPointerHeap) + size) >= (void*)HEAP_SIZE)" (() "(" (binary_expression) "((Gerency.CurrentPointerHeap) + size) >= (void*)HEAP_SIZE" (parenthesized_expression) "((Gerency.CurrentPointerHeap) + size)" (() "(" (binary_expression) "(Gerency.CurrentPointerHeap) + size" (parenthesized_expression) "(Gerency.CurrentPointerHeap)" (() "(" (field_expression) "Gerency.CurrentPointerHeap" (identifier) "Gerency" (.) "." (field_identifier) "CurrentPointerHeap" ()) ")" (+) "+" (identifier) "size" ()) ")" (>=) ">=" (cast_expression) "(void*)HEAP_SIZE" (() "(" (type_descriptor) "void*" (primitive_type) "void" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "HEAP_SIZE" ()) ")" (compound_statement) "{\n return NULL;\n }" ({) "{" (return_statement) "return NULL;" (return) "return" (null) "NULL" (NULL) "NULL" (;) ";" (}) "}" (if_statement) "if((*(Gerency.ListBlocks)) == NULL)\n {\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->next = NULL;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n *(Gerency.ListBlocks) = newBlock;\n \n numberBlocks += 1;\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n } \n else\n {\n if((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))\n {\n enjoyBlock = Gerency.LastBlockReleased;\n enjoyBlock->Info.Field.free = 0;\n Gerency.LastBlockReleased = NULL;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n numberFreeBlocks -= 1;\n return (enjoyBlock + 1);\n }\n else\n {\n switch(AAlgorithm)\n {\n case FIRST_FIT:\n try_first_fit:\n\n\n foreach(enjoyBlock,(Gerency.ListBlocks))\n {\n if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }\n }\n\n break;\n\n case BEST_FIT:\n\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, Gerency.ListBlocks)\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n if(spaceFree < 0)\n {\n break;\n }\n else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }\n\n break;\n\n\n case WORST_FIT:\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, (Gerency.ListBlocks))\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n\n if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n\n if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }\n\n break;\n\n default:\n goto try_first_fit;\n\n }\n\n scroll = *(Gerency.ListBlocks);\n\n while((scroll != NULL) && (BlockSize(scroll) < size))\n {\n previousScroll = scroll;\n scroll = scroll->next;\n }\n\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n numberBlocks += 1;\n\n if(scroll == *(Gerency.ListBlocks) )\n {\n newBlock->next = *(Gerency.ListBlocks);\n *(Gerency.ListBlocks) = newBlock;\n }\n \n else\n {\n newBlock->next = previousScroll->next;\n previousScroll->next = newBlock;\n }\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n }\n }" (if) "if" (parenthesized_expression) "((*(Gerency.ListBlocks)) == NULL)" (() "(" (binary_expression) "(*(Gerency.ListBlocks)) == NULL" (parenthesized_expression) "(*(Gerency.ListBlocks))" (() "(" (pointer_expression) "*(Gerency.ListBlocks)" (*) "*" (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" ()) ")" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->next = NULL;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n *(Gerency.ListBlocks) = newBlock;\n \n numberBlocks += 1;\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n }" ({) "{" (expression_statement) "newBlock = Gerency.CurrentPointerHeap;" (assignment_expression) "newBlock = Gerency.CurrentPointerHeap" (identifier) "newBlock" (=) "=" (field_expression) "Gerency.CurrentPointerHeap" (identifier) "Gerency" (.) "." (field_identifier) "CurrentPointerHeap" (;) ";" (expression_statement) "newBlock->next = NULL;" (assignment_expression) "newBlock->next = NULL" (field_expression) "newBlock->next" (identifier) "newBlock" (->) "->" (field_identifier) "next" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (expression_statement) "newBlock->Info.Field.free = 0;" (assignment_expression) "newBlock->Info.Field.free = 0" (field_expression) "newBlock->Info.Field.free" (field_expression) "newBlock->Info.Field" (field_expression) "newBlock->Info" (identifier) "newBlock" (->) "->" (field_identifier) "Info" (.) "." (field_identifier) "Field" (.) "." (field_identifier) "free" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "newBlock->Info.Field.size = size;" (assignment_expression) "newBlock->Info.Field.size = size" (field_expression) "newBlock->Info.Field.size" (field_expression) "newBlock->Info.Field" (field_expression) "newBlock->Info" (identifier) "newBlock" (->) "->" (field_identifier) "Info" (.) "." (field_identifier) "Field" (.) "." (field_identifier) "size" (=) "=" (identifier) "size" (;) ";" (expression_statement) "newBlock->id = numberBlocks;" (assignment_expression) "newBlock->id = numberBlocks" (field_expression) "newBlock->id" (identifier) "newBlock" (->) "->" (field_identifier) "id" (=) "=" (identifier) "numberBlocks" (;) ";" (expression_statement) "*(Gerency.ListBlocks) = newBlock;" (assignment_expression) "*(Gerency.ListBlocks) = newBlock" (pointer_expression) "*(Gerency.ListBlocks)" (*) "*" (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" (=) "=" (identifier) "newBlock" (;) ";" (expression_statement) "numberBlocks += 1;" (assignment_expression) "numberBlocks += 1" (identifier) "numberBlocks" (+=) "+=" (number_literal) "1" (;) ";" (expression_statement) "Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));" (assignment_expression) "Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size))" (field_expression) "Gerency.CurrentPointerHeap" (identifier) "Gerency" (.) "." (field_identifier) "CurrentPointerHeap" (+=) "+=" (parenthesized_expression) "((sizeof(struct Block) + size))" (() "(" (parenthesized_expression) "(sizeof(struct Block) + size)" (() "(" (binary_expression) "sizeof(struct Block) + size" (sizeof_expression) "sizeof(struct Block)" (sizeof) "sizeof" (() "(" (type_descriptor) "struct Block" (struct_specifier) "struct Block" (struct) "struct" (type_identifier) "Block" ()) ")" (+) "+" (identifier) "size" ()) ")" ()) ")" (;) ";" (expression_statement) "memoryUsage += ((sizeof(struct Block) + size));" (assignment_expression) "memoryUsage += ((sizeof(struct Block) + size))" (identifier) "memoryUsage" (+=) "+=" (parenthesized_expression) "((sizeof(struct Block) + size))" (() "(" (parenthesized_expression) "(sizeof(struct Block) + size)" (() "(" (binary_expression) "sizeof(struct Block) + size" (sizeof_expression) "sizeof(struct Block)" (sizeof) "sizeof" (() "(" (type_descriptor) "struct Block" (struct_specifier) "struct Block" (struct) "struct" (type_identifier) "Block" ()) ")" (+) "+" (identifier) "size" ()) ")" ()) ")" (;) ";" (}) "}" (else_clause) "else\n {\n if((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))\n {\n enjoyBlock = Gerency.LastBlockReleased;\n enjoyBlock->Info.Field.free = 0;\n Gerency.LastBlockReleased = NULL;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n numberFreeBlocks -= 1;\n return (enjoyBlock + 1);\n }\n else\n {\n switch(AAlgorithm)\n {\n case FIRST_FIT:\n try_first_fit:\n\n\n foreach(enjoyBlock,(Gerency.ListBlocks))\n {\n if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }\n }\n\n break;\n\n case BEST_FIT:\n\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, Gerency.ListBlocks)\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n if(spaceFree < 0)\n {\n break;\n }\n else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }\n\n break;\n\n\n case WORST_FIT:\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, (Gerency.ListBlocks))\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n\n if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n\n if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }\n\n break;\n\n default:\n goto try_first_fit;\n\n }\n\n scroll = *(Gerency.ListBlocks);\n\n while((scroll != NULL) && (BlockSize(scroll) < size))\n {\n previousScroll = scroll;\n scroll = scroll->next;\n }\n\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n numberBlocks += 1;\n\n if(scroll == *(Gerency.ListBlocks) )\n {\n newBlock->next = *(Gerency.ListBlocks);\n *(Gerency.ListBlocks) = newBlock;\n }\n \n else\n {\n newBlock->next = previousScroll->next;\n previousScroll->next = newBlock;\n }\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n }\n }" (else) "else" (compound_statement) "{\n if((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))\n {\n enjoyBlock = Gerency.LastBlockReleased;\n enjoyBlock->Info.Field.free = 0;\n Gerency.LastBlockReleased = NULL;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n numberFreeBlocks -= 1;\n return (enjoyBlock + 1);\n }\n else\n {\n switch(AAlgorithm)\n {\n case FIRST_FIT:\n try_first_fit:\n\n\n foreach(enjoyBlock,(Gerency.ListBlocks))\n {\n if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }\n }\n\n break;\n\n case BEST_FIT:\n\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, Gerency.ListBlocks)\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n if(spaceFree < 0)\n {\n break;\n }\n else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }\n\n break;\n\n\n case WORST_FIT:\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, (Gerency.ListBlocks))\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n\n if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n\n if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }\n\n break;\n\n default:\n goto try_first_fit;\n\n }\n\n scroll = *(Gerency.ListBlocks);\n\n while((scroll != NULL) && (BlockSize(scroll) < size))\n {\n previousScroll = scroll;\n scroll = scroll->next;\n }\n\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n numberBlocks += 1;\n\n if(scroll == *(Gerency.ListBlocks) )\n {\n newBlock->next = *(Gerency.ListBlocks);\n *(Gerency.ListBlocks) = newBlock;\n }\n \n else\n {\n newBlock->next = previousScroll->next;\n previousScroll->next = newBlock;\n }\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n }\n }" ({) "{" (if_statement) "if((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))\n {\n enjoyBlock = Gerency.LastBlockReleased;\n enjoyBlock->Info.Field.free = 0;\n Gerency.LastBlockReleased = NULL;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n numberFreeBlocks -= 1;\n return (enjoyBlock + 1);\n }\n else\n {\n switch(AAlgorithm)\n {\n case FIRST_FIT:\n try_first_fit:\n\n\n foreach(enjoyBlock,(Gerency.ListBlocks))\n {\n if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }\n }\n\n break;\n\n case BEST_FIT:\n\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, Gerency.ListBlocks)\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n if(spaceFree < 0)\n {\n break;\n }\n else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }\n\n break;\n\n\n case WORST_FIT:\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, (Gerency.ListBlocks))\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n\n if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n\n if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }\n\n break;\n\n default:\n goto try_first_fit;\n\n }\n\n scroll = *(Gerency.ListBlocks);\n\n while((scroll != NULL) && (BlockSize(scroll) < size))\n {\n previousScroll = scroll;\n scroll = scroll->next;\n }\n\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n numberBlocks += 1;\n\n if(scroll == *(Gerency.ListBlocks) )\n {\n newBlock->next = *(Gerency.ListBlocks);\n *(Gerency.ListBlocks) = newBlock;\n }\n \n else\n {\n newBlock->next = previousScroll->next;\n previousScroll->next = newBlock;\n }\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n }" (if) "if" (parenthesized_expression) "((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))" (() "(" (binary_expression) "(Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK)" (parenthesized_expression) "(Gerency.LastBlockReleased != NULL)" (() "(" (binary_expression) "Gerency.LastBlockReleased != NULL" (field_expression) "Gerency.LastBlockReleased" (identifier) "Gerency" (.) "." (field_identifier) "LastBlockReleased" (!=) "!=" (null) "NULL" (NULL) "NULL" ()) ")" (&&) "&&" (parenthesized_expression) "((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK)" (() "(" (binary_expression) "(BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK" (parenthesized_expression) "(BlockSize((Gerency.LastBlockReleased)) - size)" (() "(" (binary_expression) "BlockSize((Gerency.LastBlockReleased)) - size" (call_expression) "BlockSize((Gerency.LastBlockReleased))" (identifier) "BlockSize" (argument_list) "((Gerency.LastBlockReleased))" (() "(" (parenthesized_expression) "(Gerency.LastBlockReleased)" (() "(" (field_expression) "Gerency.LastBlockReleased" (identifier) "Gerency" (.) "." (field_identifier) "LastBlockReleased" ()) ")" ()) ")" (-) "-" (identifier) "size" ()) ")" (<=) "<=" (identifier) "MAX_FRAGMENTATION_BLOCK" ()) ")" ()) ")" (compound_statement) "{\n enjoyBlock = Gerency.LastBlockReleased;\n enjoyBlock->Info.Field.free = 0;\n Gerency.LastBlockReleased = NULL;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n numberFreeBlocks -= 1;\n return (enjoyBlock + 1);\n }" ({) "{" (expression_statement) "enjoyBlock = Gerency.LastBlockReleased;" (assignment_expression) "enjoyBlock = Gerency.LastBlockReleased" (identifier) "enjoyBlock" (=) "=" (field_expression) "Gerency.LastBlockReleased" (identifier) "Gerency" (.) "." (field_identifier) "LastBlockReleased" (;) ";" (expression_statement) "enjoyBlock->Info.Field.free = 0;" (assignment_expression) "enjoyBlock->Info.Field.free = 0" (field_expression) "enjoyBlock->Info.Field.free" (field_expression) "enjoyBlock->Info.Field" (field_expression) "enjoyBlock->Info" (identifier) "enjoyBlock" (->) "->" (field_identifier) "Info" (.) "." (field_identifier) "Field" (.) "." (field_identifier) "free" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "Gerency.LastBlockReleased = NULL;" (assignment_expression) "Gerency.LastBlockReleased = NULL" (field_expression) "Gerency.LastBlockReleased" (identifier) "Gerency" (.) "." (field_identifier) "LastBlockReleased" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (expression_statement) "numberFragmentation += BlockSize(enjoyBlock) - size;" (assignment_expression) "numberFragmentation += BlockSize(enjoyBlock) - size" (identifier) "numberFragmentation" (+=) "+=" (binary_expression) "BlockSize(enjoyBlock) - size" (call_expression) "BlockSize(enjoyBlock)" (identifier) "BlockSize" (argument_list) "(enjoyBlock)" (() "(" (identifier) "enjoyBlock" ()) ")" (-) "-" (identifier) "size" (;) ";" (expression_statement) "numberFreeBlocks -= 1;" (assignment_expression) "numberFreeBlocks -= 1" (identifier) "numberFreeBlocks" (-=) "-=" (number_literal) "1" (;) ";" (return_statement) "return (enjoyBlock + 1);" (return) "return" (parenthesized_expression) "(enjoyBlock + 1)" (() "(" (binary_expression) "enjoyBlock + 1" (identifier) "enjoyBlock" (+) "+" (number_literal) "1" ()) ")" (;) ";" (}) "}" (else_clause) "else\n {\n switch(AAlgorithm)\n {\n case FIRST_FIT:\n try_first_fit:\n\n\n foreach(enjoyBlock,(Gerency.ListBlocks))\n {\n if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }\n }\n\n break;\n\n case BEST_FIT:\n\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, Gerency.ListBlocks)\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n if(spaceFree < 0)\n {\n break;\n }\n else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }\n\n break;\n\n\n case WORST_FIT:\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, (Gerency.ListBlocks))\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n\n if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n\n if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }\n\n break;\n\n default:\n goto try_first_fit;\n\n }\n\n scroll = *(Gerency.ListBlocks);\n\n while((scroll != NULL) && (BlockSize(scroll) < size))\n {\n previousScroll = scroll;\n scroll = scroll->next;\n }\n\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n numberBlocks += 1;\n\n if(scroll == *(Gerency.ListBlocks) )\n {\n newBlock->next = *(Gerency.ListBlocks);\n *(Gerency.ListBlocks) = newBlock;\n }\n \n else\n {\n newBlock->next = previousScroll->next;\n previousScroll->next = newBlock;\n }\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n }" (else) "else" (compound_statement) "{\n switch(AAlgorithm)\n {\n case FIRST_FIT:\n try_first_fit:\n\n\n foreach(enjoyBlock,(Gerency.ListBlocks))\n {\n if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }\n }\n\n break;\n\n case BEST_FIT:\n\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, Gerency.ListBlocks)\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n if(spaceFree < 0)\n {\n break;\n }\n else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }\n\n break;\n\n\n case WORST_FIT:\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, (Gerency.ListBlocks))\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n\n if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n\n if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }\n\n break;\n\n default:\n goto try_first_fit;\n\n }\n\n scroll = *(Gerency.ListBlocks);\n\n while((scroll != NULL) && (BlockSize(scroll) < size))\n {\n previousScroll = scroll;\n scroll = scroll->next;\n }\n\n newBlock = Gerency.CurrentPointerHeap;\n newBlock->Info.Field.free = 0;\n newBlock->Info.Field.size = size;\n newBlock->id = numberBlocks;\n numberBlocks += 1;\n\n if(scroll == *(Gerency.ListBlocks) )\n {\n newBlock->next = *(Gerency.ListBlocks);\n *(Gerency.ListBlocks) = newBlock;\n }\n \n else\n {\n newBlock->next = previousScroll->next;\n previousScroll->next = newBlock;\n }\n\n Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n memoryUsage += ((sizeof(struct Block) + size));\n }" ({) "{" (switch_statement) "switch(AAlgorithm)\n {\n case FIRST_FIT:\n try_first_fit:\n\n\n foreach(enjoyBlock,(Gerency.ListBlocks))\n {\n if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }\n }\n\n break;\n\n case BEST_FIT:\n\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, Gerency.ListBlocks)\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n if(spaceFree < 0)\n {\n break;\n }\n else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }\n\n break;\n\n\n case WORST_FIT:\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, (Gerency.ListBlocks))\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n\n if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n\n if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }\n\n break;\n\n default:\n goto try_first_fit;\n\n }" (switch) "switch" (parenthesized_expression) "(AAlgorithm)" (() "(" (identifier) "AAlgorithm" ()) ")" (compound_statement) "{\n case FIRST_FIT:\n try_first_fit:\n\n\n foreach(enjoyBlock,(Gerency.ListBlocks))\n {\n if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }\n }\n\n break;\n\n case BEST_FIT:\n\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, Gerency.ListBlocks)\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n if(spaceFree < 0)\n {\n break;\n }\n else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }\n\n break;\n\n\n case WORST_FIT:\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, (Gerency.ListBlocks))\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n\n if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n\n if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }\n\n break;\n\n default:\n goto try_first_fit;\n\n }" ({) "{" (case_statement) "case FIRST_FIT:\n try_first_fit:\n\n\n foreach(enjoyBlock,(Gerency.ListBlocks))\n {\n if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }\n }\n\n break;" (case) "case" (identifier) "FIRST_FIT" (:) ":" (labeled_statement) "try_first_fit:\n\n\n foreach(enjoyBlock,(Gerency.ListBlocks))" (statement_identifier) "try_first_fit" (:) ":" (expression_statement) "foreach(enjoyBlock,(Gerency.ListBlocks))" (call_expression) "foreach(enjoyBlock,(Gerency.ListBlocks))" (identifier) "foreach" (argument_list) "(enjoyBlock,(Gerency.ListBlocks))" (() "(" (identifier) "enjoyBlock" (,) "," (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" ()) ")" (;) "" (compound_statement) "{\n if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }\n }" ({) "{" (if_statement) "if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n {\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }" (if) "if" (parenthesized_expression) "((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))" (() "(" (binary_expression) "(BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock))" (parenthesized_expression) "(BlockSize(enjoyBlock) >= size)" (() "(" (binary_expression) "BlockSize(enjoyBlock) >= size" (call_expression) "BlockSize(enjoyBlock)" (identifier) "BlockSize" (argument_list) "(enjoyBlock)" (() "(" (identifier) "enjoyBlock" ()) ")" (>=) ">=" (identifier) "size" ()) ")" (&&) "&&" (parenthesized_expression) "(isFreeBlock(enjoyBlock))" (() "(" (call_expression) "isFreeBlock(enjoyBlock)" (identifier) "isFreeBlock" (argument_list) "(enjoyBlock)" (() "(" (identifier) "enjoyBlock" ()) ")" ()) ")" ()) ")" (compound_statement) "{\n enjoyBlock->Info.Field.free = 0;\n numberFreeBlocks -= 1;\n numberFragmentation += BlockSize(enjoyBlock) - size;\n return (enjoyBlock + 1);\n }" ({) "{" (expression_statement) "enjoyBlock->Info.Field.free = 0;" (assignment_expression) "enjoyBlock->Info.Field.free = 0" (field_expression) "enjoyBlock->Info.Field.free" (field_expression) "enjoyBlock->Info.Field" (field_expression) "enjoyBlock->Info" (identifier) "enjoyBlock" (->) "->" (field_identifier) "Info" (.) "." (field_identifier) "Field" (.) "." (field_identifier) "free" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "numberFreeBlocks -= 1;" (assignment_expression) "numberFreeBlocks -= 1" (identifier) "numberFreeBlocks" (-=) "-=" (number_literal) "1" (;) ";" (expression_statement) "numberFragmentation += BlockSize(enjoyBlock) - size;" (assignment_expression) "numberFragmentation += BlockSize(enjoyBlock) - size" (identifier) "numberFragmentation" (+=) "+=" (binary_expression) "BlockSize(enjoyBlock) - size" (call_expression) "BlockSize(enjoyBlock)" (identifier) "BlockSize" (argument_list) "(enjoyBlock)" (() "(" (identifier) "enjoyBlock" ()) ")" (-) "-" (identifier) "size" (;) ";" (return_statement) "return (enjoyBlock + 1);" (return) "return" (parenthesized_expression) "(enjoyBlock + 1)" (() "(" (binary_expression) "enjoyBlock + 1" (identifier) "enjoyBlock" (+) "+" (number_literal) "1" ()) ")" (;) ";" (}) "}" (}) "}" (break_statement) "break;" (break) "break" (;) ";" (case_statement) "case BEST_FIT:\n\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, Gerency.ListBlocks)\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n if(spaceFree < 0)\n {\n break;\n }\n else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }\n\n break;" (case) "case" (identifier) "BEST_FIT" (:) ":" (expression_statement) "spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;" (assignment_expression) "spaceFree = BlockSize((*(Gerency.ListBlocks))) - size" (identifier) "spaceFree" (=) "=" (binary_expression) "BlockSize((*(Gerency.ListBlocks))) - size" (call_expression) "BlockSize((*(Gerency.ListBlocks)))" (identifier) "BlockSize" (argument_list) "((*(Gerency.ListBlocks)))" (() "(" (parenthesized_expression) "(*(Gerency.ListBlocks))" (() "(" (pointer_expression) "*(Gerency.ListBlocks)" (*) "*" (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" ()) ")" ()) ")" (-) "-" (identifier) "size" (;) ";" (expression_statement) "tempBlock = *(Gerency.ListBlocks);" (assignment_expression) "tempBlock = *(Gerency.ListBlocks)" (identifier) "tempBlock" (=) "=" (pointer_expression) "*(Gerency.ListBlocks)" (*) "*" (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" (;) ";" (expression_statement) "foreach(enjoyBlock, Gerency.ListBlocks)" (call_expression) "foreach(enjoyBlock, Gerency.ListBlocks)" (identifier) "foreach" (argument_list) "(enjoyBlock, Gerency.ListBlocks)" (() "(" (identifier) "enjoyBlock" (,) "," (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" (;) "" (compound_statement) "{ \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }" ({) "{" (expression_statement) "spaceEvaluation = BlockSize(enjoyBlock) - size;" (assignment_expression) "spaceEvaluation = BlockSize(enjoyBlock) - size" (identifier) "spaceEvaluation" (=) "=" (binary_expression) "BlockSize(enjoyBlock) - size" (call_expression) "BlockSize(enjoyBlock)" (identifier) "BlockSize" (argument_list) "(enjoyBlock)" (() "(" (identifier) "enjoyBlock" ()) ")" (-) "-" (identifier) "size" (;) ";" (if_statement) "if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }" (if) "if" (parenthesized_expression) "((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))" (() "(" (binary_expression) "(spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock)))" (parenthesized_expression) "(spaceFree < 0)" (() "(" (binary_expression) "spaceFree < 0" (identifier) "spaceFree" (<) "<" (number_literal) "0" ()) ")" (||) "||" (parenthesized_expression) "((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock)))" (() "(" (binary_expression) "(spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))" (parenthesized_expression) "(spaceEvaluation <= spaceFree)" (() "(" (binary_expression) "spaceEvaluation <= spaceFree" (identifier) "spaceEvaluation" (<=) "<=" (identifier) "spaceFree" ()) ")" (&&) "&&" (parenthesized_expression) "(isFreeBlock(enjoyBlock))" (() "(" (call_expression) "isFreeBlock(enjoyBlock)" (identifier) "isFreeBlock" (argument_list) "(enjoyBlock)" (() "(" (identifier) "enjoyBlock" ()) ")" ()) ")" ()) ")" ()) ")" (compound_statement) "{\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }" ({) "{" (expression_statement) "spaceFree = spaceEvaluation;" (assignment_expression) "spaceFree = spaceEvaluation" (identifier) "spaceFree" (=) "=" (identifier) "spaceEvaluation" (;) ";" (expression_statement) "tempBlock = enjoyBlock;" (assignment_expression) "tempBlock = enjoyBlock" (identifier) "tempBlock" (=) "=" (identifier) "enjoyBlock" (;) ";" (}) "}" (}) "}" (if_statement) "if(spaceFree < 0)\n {\n break;\n }\n else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }" (if) "if" (parenthesized_expression) "(spaceFree < 0)" (() "(" (binary_expression) "spaceFree < 0" (identifier) "spaceFree" (<) "<" (number_literal) "0" ()) ")" (compound_statement) "{\n break;\n }" ({) "{" (break_statement) "break;" (break) "break" (;) ";" (}) "}" (else_clause) "else if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }" (else) "else" (if_statement) "if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }" (if) "if" (parenthesized_expression) "(isFreeBlock(tempBlock))" (() "(" (call_expression) "isFreeBlock(tempBlock)" (identifier) "isFreeBlock" (argument_list) "(tempBlock)" (() "(" (identifier) "tempBlock" ()) ")" ()) ")" (compound_statement) "{\n tempBlock->Info.Field.free = 0;\n numberFragmentation += BlockSize(tempBlock) - size;\n return (tempBlock + 1);\n }" ({) "{" (expression_statement) "tempBlock->Info.Field.free = 0;" (assignment_expression) "tempBlock->Info.Field.free = 0" (field_expression) "tempBlock->Info.Field.free" (field_expression) "tempBlock->Info.Field" (field_expression) "tempBlock->Info" (identifier) "tempBlock" (->) "->" (field_identifier) "Info" (.) "." (field_identifier) "Field" (.) "." (field_identifier) "free" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "numberFragmentation += BlockSize(tempBlock) - size;" (assignment_expression) "numberFragmentation += BlockSize(tempBlock) - size" (identifier) "numberFragmentation" (+=) "+=" (binary_expression) "BlockSize(tempBlock) - size" (call_expression) "BlockSize(tempBlock)" (identifier) "BlockSize" (argument_list) "(tempBlock)" (() "(" (identifier) "tempBlock" ()) ")" (-) "-" (identifier) "size" (;) ";" (return_statement) "return (tempBlock + 1);" (return) "return" (parenthesized_expression) "(tempBlock + 1)" (() "(" (binary_expression) "tempBlock + 1" (identifier) "tempBlock" (+) "+" (number_literal) "1" ()) ")" (;) ";" (}) "}" (break_statement) "break;" (break) "break" (;) ";" (case_statement) "case WORST_FIT:\n\n spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n tempBlock = *(Gerency.ListBlocks);\n\n foreach(enjoyBlock, (Gerency.ListBlocks))\n { \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n\n if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }\n\n if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }\n\n break;" (case) "case" (identifier) "WORST_FIT" (:) ":" (expression_statement) "spaceFree = BlockSize((*(Gerency.ListBlocks))) - size;" (assignment_expression) "spaceFree = BlockSize((*(Gerency.ListBlocks))) - size" (identifier) "spaceFree" (=) "=" (binary_expression) "BlockSize((*(Gerency.ListBlocks))) - size" (call_expression) "BlockSize((*(Gerency.ListBlocks)))" (identifier) "BlockSize" (argument_list) "((*(Gerency.ListBlocks)))" (() "(" (parenthesized_expression) "(*(Gerency.ListBlocks))" (() "(" (pointer_expression) "*(Gerency.ListBlocks)" (*) "*" (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" ()) ")" ()) ")" (-) "-" (identifier) "size" (;) ";" (expression_statement) "tempBlock = *(Gerency.ListBlocks);" (assignment_expression) "tempBlock = *(Gerency.ListBlocks)" (identifier) "tempBlock" (=) "=" (pointer_expression) "*(Gerency.ListBlocks)" (*) "*" (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" (;) ";" (expression_statement) "foreach(enjoyBlock, (Gerency.ListBlocks))" (call_expression) "foreach(enjoyBlock, (Gerency.ListBlocks))" (identifier) "foreach" (argument_list) "(enjoyBlock, (Gerency.ListBlocks))" (() "(" (identifier) "enjoyBlock" (,) "," (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" ()) ")" (;) "" (compound_statement) "{ \n spaceEvaluation = BlockSize(enjoyBlock) - size;\n\n if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }\n }" ({) "{" (expression_statement) "spaceEvaluation = BlockSize(enjoyBlock) - size;" (assignment_expression) "spaceEvaluation = BlockSize(enjoyBlock) - size" (identifier) "spaceEvaluation" (=) "=" (binary_expression) "BlockSize(enjoyBlock) - size" (call_expression) "BlockSize(enjoyBlock)" (identifier) "BlockSize" (argument_list) "(enjoyBlock)" (() "(" (identifier) "enjoyBlock" ()) ")" (-) "-" (identifier) "size" (;) ";" (if_statement) "if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n {\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }" (if) "if" (parenthesized_expression) "((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))" (() "(" (binary_expression) "(spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock)))" (parenthesized_expression) "(spaceFree < 0)" (() "(" (binary_expression) "spaceFree < 0" (identifier) "spaceFree" (<) "<" (number_literal) "0" ()) ")" (||) "||" (parenthesized_expression) "((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock)))" (() "(" (binary_expression) "(spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))" (parenthesized_expression) "(spaceEvaluation > spaceFree)" (() "(" (binary_expression) "spaceEvaluation > spaceFree" (identifier) "spaceEvaluation" (>) ">" (identifier) "spaceFree" ()) ")" (&&) "&&" (parenthesized_expression) "(isFreeBlock(enjoyBlock))" (() "(" (call_expression) "isFreeBlock(enjoyBlock)" (identifier) "isFreeBlock" (argument_list) "(enjoyBlock)" (() "(" (identifier) "enjoyBlock" ()) ")" ()) ")" ()) ")" ()) ")" (compound_statement) "{\n spaceFree = spaceEvaluation;\n tempBlock = enjoyBlock;\n }" ({) "{" (expression_statement) "spaceFree = spaceEvaluation;" (assignment_expression) "spaceFree = spaceEvaluation" (identifier) "spaceFree" (=) "=" (identifier) "spaceEvaluation" (;) ";" (expression_statement) "tempBlock = enjoyBlock;" (assignment_expression) "tempBlock = enjoyBlock" (identifier) "tempBlock" (=) "=" (identifier) "enjoyBlock" (;) ";" (}) "}" (}) "}" (if_statement) "if(isFreeBlock(tempBlock))\n {\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }" (if) "if" (parenthesized_expression) "(isFreeBlock(tempBlock))" (() "(" (call_expression) "isFreeBlock(tempBlock)" (identifier) "isFreeBlock" (argument_list) "(tempBlock)" (() "(" (identifier) "tempBlock" ()) ")" ()) ")" (compound_statement) "{\n tempBlock->Info.Field.free = 0;\n return (tempBlock + 1);\n }" ({) "{" (expression_statement) "tempBlock->Info.Field.free = 0;" (assignment_expression) "tempBlock->Info.Field.free = 0" (field_expression) "tempBlock->Info.Field.free" (field_expression) "tempBlock->Info.Field" (field_expression) "tempBlock->Info" (identifier) "tempBlock" (->) "->" (field_identifier) "Info" (.) "." (field_identifier) "Field" (.) "." (field_identifier) "free" (=) "=" (number_literal) "0" (;) ";" (return_statement) "return (tempBlock + 1);" (return) "return" (parenthesized_expression) "(tempBlock + 1)" (() "(" (binary_expression) "tempBlock + 1" (identifier) "tempBlock" (+) "+" (number_literal) "1" ()) ")" (;) ";" (}) "}" (break_statement) "break;" (break) "break" (;) ";" (case_statement) "default:\n goto try_first_fit;" (default) "default" (:) ":" (goto_statement) "goto try_first_fit;" (goto) "goto" (statement_identifier) "try_first_fit" (;) ";" (}) "}" (expression_statement) "scroll = *(Gerency.ListBlocks);" (assignment_expression) "scroll = *(Gerency.ListBlocks)" (identifier) "scroll" (=) "=" (pointer_expression) "*(Gerency.ListBlocks)" (*) "*" (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" (;) ";" (while_statement) "while((scroll != NULL) && (BlockSize(scroll) < size))\n {\n previousScroll = scroll;\n scroll = scroll->next;\n }" (while) "while" (parenthesized_expression) "((scroll != NULL) && (BlockSize(scroll) < size))" (() "(" (binary_expression) "(scroll != NULL) && (BlockSize(scroll) < size)" (parenthesized_expression) "(scroll != NULL)" (() "(" (binary_expression) "scroll != NULL" (identifier) "scroll" (!=) "!=" (null) "NULL" (NULL) "NULL" ()) ")" (&&) "&&" (parenthesized_expression) "(BlockSize(scroll) < size)" (() "(" (binary_expression) "BlockSize(scroll) < size" (call_expression) "BlockSize(scroll)" (identifier) "BlockSize" (argument_list) "(scroll)" (() "(" (identifier) "scroll" ()) ")" (<) "<" (identifier) "size" ()) ")" ()) ")" (compound_statement) "{\n previousScroll = scroll;\n scroll = scroll->next;\n }" ({) "{" (expression_statement) "previousScroll = scroll;" (assignment_expression) "previousScroll = scroll" (identifier) "previousScroll" (=) "=" (identifier) "scroll" (;) ";" (expression_statement) "scroll = scroll->next;" (assignment_expression) "scroll = scroll->next" (identifier) "scroll" (=) "=" (field_expression) "scroll->next" (identifier) "scroll" (->) "->" (field_identifier) "next" (;) ";" (}) "}" (expression_statement) "newBlock = Gerency.CurrentPointerHeap;" (assignment_expression) "newBlock = Gerency.CurrentPointerHeap" (identifier) "newBlock" (=) "=" (field_expression) "Gerency.CurrentPointerHeap" (identifier) "Gerency" (.) "." (field_identifier) "CurrentPointerHeap" (;) ";" (expression_statement) "newBlock->Info.Field.free = 0;" (assignment_expression) "newBlock->Info.Field.free = 0" (field_expression) "newBlock->Info.Field.free" (field_expression) "newBlock->Info.Field" (field_expression) "newBlock->Info" (identifier) "newBlock" (->) "->" (field_identifier) "Info" (.) "." (field_identifier) "Field" (.) "." (field_identifier) "free" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "newBlock->Info.Field.size = size;" (assignment_expression) "newBlock->Info.Field.size = size" (field_expression) "newBlock->Info.Field.size" (field_expression) "newBlock->Info.Field" (field_expression) "newBlock->Info" (identifier) "newBlock" (->) "->" (field_identifier) "Info" (.) "." (field_identifier) "Field" (.) "." (field_identifier) "size" (=) "=" (identifier) "size" (;) ";" (expression_statement) "newBlock->id = numberBlocks;" (assignment_expression) "newBlock->id = numberBlocks" (field_expression) "newBlock->id" (identifier) "newBlock" (->) "->" (field_identifier) "id" (=) "=" (identifier) "numberBlocks" (;) ";" (expression_statement) "numberBlocks += 1;" (assignment_expression) "numberBlocks += 1" (identifier) "numberBlocks" (+=) "+=" (number_literal) "1" (;) ";" (if_statement) "if(scroll == *(Gerency.ListBlocks) )\n {\n newBlock->next = *(Gerency.ListBlocks);\n *(Gerency.ListBlocks) = newBlock;\n }\n \n else\n {\n newBlock->next = previousScroll->next;\n previousScroll->next = newBlock;\n }" (if) "if" (parenthesized_expression) "(scroll == *(Gerency.ListBlocks) )" (() "(" (binary_expression) "scroll == *(Gerency.ListBlocks)" (identifier) "scroll" (==) "==" (pointer_expression) "*(Gerency.ListBlocks)" (*) "*" (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" ()) ")" (compound_statement) "{\n newBlock->next = *(Gerency.ListBlocks);\n *(Gerency.ListBlocks) = newBlock;\n }" ({) "{" (expression_statement) "newBlock->next = *(Gerency.ListBlocks);" (assignment_expression) "newBlock->next = *(Gerency.ListBlocks)" (field_expression) "newBlock->next" (identifier) "newBlock" (->) "->" (field_identifier) "next" (=) "=" (pointer_expression) "*(Gerency.ListBlocks)" (*) "*" (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" (;) ";" (expression_statement) "*(Gerency.ListBlocks) = newBlock;" (assignment_expression) "*(Gerency.ListBlocks) = newBlock" (pointer_expression) "*(Gerency.ListBlocks)" (*) "*" (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" (=) "=" (identifier) "newBlock" (;) ";" (}) "}" (else_clause) "else\n {\n newBlock->next = previousScroll->next;\n previousScroll->next = newBlock;\n }" (else) "else" (compound_statement) "{\n newBlock->next = previousScroll->next;\n previousScroll->next = newBlock;\n }" ({) "{" (expression_statement) "newBlock->next = previousScroll->next;" (assignment_expression) "newBlock->next = previousScroll->next" (field_expression) "newBlock->next" (identifier) "newBlock" (->) "->" (field_identifier) "next" (=) "=" (field_expression) "previousScroll->next" (identifier) "previousScroll" (->) "->" (field_identifier) "next" (;) ";" (expression_statement) "previousScroll->next = newBlock;" (assignment_expression) "previousScroll->next = newBlock" (field_expression) "previousScroll->next" (identifier) "previousScroll" (->) "->" (field_identifier) "next" (=) "=" (identifier) "newBlock" (;) ";" (}) "}" (expression_statement) "Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size));" (assignment_expression) "Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size))" (field_expression) "Gerency.CurrentPointerHeap" (identifier) "Gerency" (.) "." (field_identifier) "CurrentPointerHeap" (+=) "+=" (parenthesized_expression) "((sizeof(struct Block) + size))" (() "(" (parenthesized_expression) "(sizeof(struct Block) + size)" (() "(" (binary_expression) "sizeof(struct Block) + size" (sizeof_expression) "sizeof(struct Block)" (sizeof) "sizeof" (() "(" (type_descriptor) "struct Block" (struct_specifier) "struct Block" (struct) "struct" (type_identifier) "Block" ()) ")" (+) "+" (identifier) "size" ()) ")" ()) ")" (;) ";" (expression_statement) "memoryUsage += ((sizeof(struct Block) + size));" (assignment_expression) "memoryUsage += ((sizeof(struct Block) + size))" (identifier) "memoryUsage" (+=) "+=" (parenthesized_expression) "((sizeof(struct Block) + size))" (() "(" (parenthesized_expression) "(sizeof(struct Block) + size)" (() "(" (binary_expression) "sizeof(struct Block) + size" (sizeof_expression) "sizeof(struct Block)" (sizeof) "sizeof" (() "(" (type_descriptor) "struct Block" (struct_specifier) "struct Block" (struct) "struct" (type_identifier) "Block" ()) ")" (+) "+" (identifier) "size" ()) ")" ()) ")" (;) ";" (}) "}" (}) "}" (return_statement) "return (newBlock + 1);" (return) "return" (parenthesized_expression) "(newBlock + 1)" (() "(" (binary_expression) "newBlock + 1" (identifier) "newBlock" (+) "+" (number_literal) "1" ()) ")" (;) ";" (}) "}" (function_definition) "void* myCalloc(unsigned int length, unsigned int size)\n{\n\n}" (primitive_type) "void" (pointer_declarator) "* myCalloc(unsigned int length, unsigned int size)" (*) "*" (function_declarator) "myCalloc(unsigned int length, unsigned int size)" (identifier) "myCalloc" (parameter_list) "(unsigned int length, unsigned int size)" (() "(" (parameter_declaration) "unsigned int length" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "length" (,) "," (parameter_declaration) "unsigned int size" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "size" ()) ")" (compound_statement) "{\n\n}" ({) "{" (}) "}" (function_definition) "int myMallocFree(void* ptr)\n{\n Block releaseBlock;\n\n releaseBlock = getHeader(ptr);\n releaseBlock->Info.Field.free = 1;\n\n if(Gerency.LastBlockReleased == NULL)\n {\n Gerency.LastBlockReleased = releaseBlock;\n }\n numberFreeBlocks += 1;\n}" (primitive_type) "int" (function_declarator) "myMallocFree(void* ptr)" (identifier) "myMallocFree" (parameter_list) "(void* ptr)" (() "(" (parameter_declaration) "void* ptr" (primitive_type) "void" (pointer_declarator) "* ptr" (*) "*" (identifier) "ptr" ()) ")" (compound_statement) "{\n Block releaseBlock;\n\n releaseBlock = getHeader(ptr);\n releaseBlock->Info.Field.free = 1;\n\n if(Gerency.LastBlockReleased == NULL)\n {\n Gerency.LastBlockReleased = releaseBlock;\n }\n numberFreeBlocks += 1;\n}" ({) "{" (declaration) "Block releaseBlock;" (type_identifier) "Block" (identifier) "releaseBlock" (;) ";" (expression_statement) "releaseBlock = getHeader(ptr);" (assignment_expression) "releaseBlock = getHeader(ptr)" (identifier) "releaseBlock" (=) "=" (call_expression) "getHeader(ptr)" (identifier) "getHeader" (argument_list) "(ptr)" (() "(" (identifier) "ptr" ()) ")" (;) ";" (expression_statement) "releaseBlock->Info.Field.free = 1;" (assignment_expression) "releaseBlock->Info.Field.free = 1" (field_expression) "releaseBlock->Info.Field.free" (field_expression) "releaseBlock->Info.Field" (field_expression) "releaseBlock->Info" (identifier) "releaseBlock" (->) "->" (field_identifier) "Info" (.) "." (field_identifier) "Field" (.) "." (field_identifier) "free" (=) "=" (number_literal) "1" (;) ";" (if_statement) "if(Gerency.LastBlockReleased == NULL)\n {\n Gerency.LastBlockReleased = releaseBlock;\n }" (if) "if" (parenthesized_expression) "(Gerency.LastBlockReleased == NULL)" (() "(" (binary_expression) "Gerency.LastBlockReleased == NULL" (field_expression) "Gerency.LastBlockReleased" (identifier) "Gerency" (.) "." (field_identifier) "LastBlockReleased" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{\n Gerency.LastBlockReleased = releaseBlock;\n }" ({) "{" (expression_statement) "Gerency.LastBlockReleased = releaseBlock;" (assignment_expression) "Gerency.LastBlockReleased = releaseBlock" (field_expression) "Gerency.LastBlockReleased" (identifier) "Gerency" (.) "." (field_identifier) "LastBlockReleased" (=) "=" (identifier) "releaseBlock" (;) ";" (}) "}" (expression_statement) "numberFreeBlocks += 1;" (assignment_expression) "numberFreeBlocks += 1" (identifier) "numberFreeBlocks" (+=) "+=" (number_literal) "1" (;) ";" (}) "}" (function_definition) "void __attribute__((destructor))Exit(void)\n{\n Block p;\n\n printf("Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes\n\n", HEAP_SIZE, totalAllocatedMemory);\n printf("Memory Usage: %u Bytes \n\n",memoryUsage);\n printf("Internal Fragmentation: %u Bytes \n\n", numberFragmentation);\n \n foreach(p, (Gerency.ListBlocks))\n {\n printf("Block ID: %u ", p->id);\n printf("Size: %u ", BlockSize(p));\n printf("Free: %s\n", isFreeBlock(p)?"True":"False");\n puts(" ");\n }\n}" (primitive_type) "void" (attribute_specifier) "__attribute__((destructor))" (__attribute__) "__attribute__" (() "(" (argument_list) "(destructor)" (() "(" (identifier) "destructor" ()) ")" ()) ")" (function_declarator) "Exit(void)" (identifier) "Exit" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (compound_statement) "{\n Block p;\n\n printf("Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes\n\n", HEAP_SIZE, totalAllocatedMemory);\n printf("Memory Usage: %u Bytes \n\n",memoryUsage);\n printf("Internal Fragmentation: %u Bytes \n\n", numberFragmentation);\n \n foreach(p, (Gerency.ListBlocks))\n {\n printf("Block ID: %u ", p->id);\n printf("Size: %u ", BlockSize(p));\n printf("Free: %s\n", isFreeBlock(p)?"True":"False");\n puts(" ");\n }\n}" ({) "{" (declaration) "Block p;" (type_identifier) "Block" (identifier) "p" (;) ";" (expression_statement) "printf("Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes\n\n", HEAP_SIZE, totalAllocatedMemory);" (call_expression) "printf("Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes\n\n", HEAP_SIZE, totalAllocatedMemory)" (identifier) "printf" (argument_list) "("Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes\n\n", HEAP_SIZE, totalAllocatedMemory)" (() "(" (string_literal) ""Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes\n\n"" (") """ (string_content) "Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes" (escape_sequence) "\n" (escape_sequence) "\n" (") """ (,) "," (identifier) "HEAP_SIZE" (,) "," (identifier) "totalAllocatedMemory" ()) ")" (;) ";" (expression_statement) "printf("Memory Usage: %u Bytes \n\n",memoryUsage);" (call_expression) "printf("Memory Usage: %u Bytes \n\n",memoryUsage)" (identifier) "printf" (argument_list) "("Memory Usage: %u Bytes \n\n",memoryUsage)" (() "(" (string_literal) ""Memory Usage: %u Bytes \n\n"" (") """ (string_content) "Memory Usage: %u Bytes " (escape_sequence) "\n" (escape_sequence) "\n" (") """ (,) "," (identifier) "memoryUsage" ()) ")" (;) ";" (expression_statement) "printf("Internal Fragmentation: %u Bytes \n\n", numberFragmentation);" (call_expression) "printf("Internal Fragmentation: %u Bytes \n\n", numberFragmentation)" (identifier) "printf" (argument_list) "("Internal Fragmentation: %u Bytes \n\n", numberFragmentation)" (() "(" (string_literal) ""Internal Fragmentation: %u Bytes \n\n"" (") """ (string_content) "Internal Fragmentation: %u Bytes " (escape_sequence) "\n" (escape_sequence) "\n" (") """ (,) "," (identifier) "numberFragmentation" ()) ")" (;) ";" (expression_statement) "foreach(p, (Gerency.ListBlocks))" (call_expression) "foreach(p, (Gerency.ListBlocks))" (identifier) "foreach" (argument_list) "(p, (Gerency.ListBlocks))" (() "(" (identifier) "p" (,) "," (parenthesized_expression) "(Gerency.ListBlocks)" (() "(" (field_expression) "Gerency.ListBlocks" (identifier) "Gerency" (.) "." (field_identifier) "ListBlocks" ()) ")" ()) ")" (;) "" (compound_statement) "{\n printf("Block ID: %u ", p->id);\n printf("Size: %u ", BlockSize(p));\n printf("Free: %s\n", isFreeBlock(p)?"True":"False");\n puts(" ");\n }" ({) "{" (expression_statement) "printf("Block ID: %u ", p->id);" (call_expression) "printf("Block ID: %u ", p->id)" (identifier) "printf" (argument_list) "("Block ID: %u ", p->id)" (() "(" (string_literal) ""Block ID: %u "" (") """ (string_content) "Block ID: %u " (") """ (,) "," (field_expression) "p->id" (identifier) "p" (->) "->" (field_identifier) "id" ()) ")" (;) ";" (expression_statement) "printf("Size: %u ", BlockSize(p));" (call_expression) "printf("Size: %u ", BlockSize(p))" (identifier) "printf" (argument_list) "("Size: %u ", BlockSize(p))" (() "(" (string_literal) ""Size: %u "" (") """ (string_content) "Size: %u " (") """ (,) "," (call_expression) "BlockSize(p)" (identifier) "BlockSize" (argument_list) "(p)" (() "(" (identifier) "p" ()) ")" ()) ")" (;) ";" (expression_statement) "printf("Free: %s\n", isFreeBlock(p)?"True":"False");" (call_expression) "printf("Free: %s\n", isFreeBlock(p)?"True":"False")" (identifier) "printf" (argument_list) "("Free: %s\n", isFreeBlock(p)?"True":"False")" (() "(" (string_literal) ""Free: %s\n"" (") """ (string_content) "Free: %s" (escape_sequence) "\n" (") """ (,) "," (conditional_expression) "isFreeBlock(p)?"True":"False"" (call_expression) "isFreeBlock(p)" (identifier) "isFreeBlock" (argument_list) "(p)" (() "(" (identifier) "p" ()) ")" (?) "?" (string_literal) ""True"" (") """ (string_content) "True" (") """ (:) ":" (string_literal) ""False"" (") """ (string_content) "False" (") """ ()) ")" (;) ";" (expression_statement) "puts(" ");" (call_expression) "puts(" ")" (identifier) "puts" (argument_list) "(" ")" (() "(" (string_literal) "" "" (") """ (string_content) " " (") """ ()) ")" (;) ";" (}) "}" (}) "}"
1,848
0
{"language": "c", "success": true, "metadata": {"lines": 231, "avg_line_length": 24.42, "nodes": 1147, "errors": 0, "source_hash": "4f24a837e679817b19a4c3341afa196508d6b643615d0d3e7786dd1b2c4de624", "categorized_nodes": 838}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"Malloc.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"Malloc.h\"", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 19}}, {"id": 3, "type": "preproc_include", "text": "#include <stdio.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<stdio.h>", "parent": 3, "children": [], "start_point": {"row": 1, "column": 9}, "end_point": {"row": 1, "column": 18}}, {"id": 6, "type": "preproc_include", "text": "#include <stdlib.h>\n", "parent": null, "children": [7, 8], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<stdlib.h>", "parent": 6, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 19}}, {"id": 9, "type": "preproc_include", "text": "#include <assert.h>\n", "parent": null, "children": [10, 11], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<assert.h>", "parent": 9, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 19}}, {"id": 12, "type": "preproc_include", "text": "#include <sys/unistd.h>\n", "parent": null, "children": [13, 14], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 14, "type": "system_lib_string", "text": "<sys/unistd.h>", "parent": 12, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 23}}, {"id": 15, "type": "preproc_include", "text": "#include <unistd.h>\n", "parent": null, "children": [16, 17], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 17, "type": "system_lib_string", "text": "<unistd.h>", "parent": 15, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 19}}, {"id": 18, "type": "preproc_include", "text": "#include <sys/types.h>\n", "parent": null, "children": [19, 20], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 8}}, {"id": 20, "type": "system_lib_string", "text": "<sys/types.h>", "parent": 18, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 22}}, {"id": 21, "type": "preproc_include", "text": "#include <stdbool.h>\n", "parent": null, "children": [22, 23], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 22, "type": "#include", "text": "#include", "parent": 21, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 8}}, {"id": 23, "type": "system_lib_string", "text": "<stdbool.h>", "parent": 21, "children": [], "start_point": {"row": 7, "column": 9}, "end_point": {"row": 7, "column": 20}}, {"id": 24, "type": "preproc_include", "text": "#include <errno.h>\n", "parent": null, "children": [25, 26], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 25, "type": "#include", "text": "#include", "parent": 24, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 8}}, {"id": 26, "type": "system_lib_string", "text": "<errno.h>", "parent": 24, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 18}}, {"id": 27, "type": "preproc_include", "text": "#include <stdatomic.h>\n", "parent": null, "children": [28, 29], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 28, "type": "#include", "text": "#include", "parent": 27, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 8}}, {"id": 29, "type": "system_lib_string", "text": "<stdatomic.h>", "parent": 27, "children": [], "start_point": {"row": 9, "column": 9}, "end_point": {"row": 9, "column": 22}}, {"id": 30, "type": "preproc_ifdef", "text": "#ifndef HEAP_SIZE \n\t#define HEAP_SIZE 33554432u\n#endif", "parent": null, "children": [31, 32, 33, 37], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 13, "column": 6}}, {"id": 31, "type": "#ifndef", "text": "#ifndef", "parent": 30, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 7}}, {"id": 32, "type": "identifier", "text": "HEAP_SIZE", "parent": 30, "children": [], "start_point": {"row": 11, "column": 8}, "end_point": {"row": 11, "column": 17}}, {"id": 33, "type": "preproc_def", "text": "#define HEAP_SIZE 33554432u\n", "parent": 30, "children": [34, 35, 36], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 13, "column": 0}}, {"id": 34, "type": "#define", "text": "#define", "parent": 33, "children": [], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 8}}, {"id": 35, "type": "identifier", "text": "HEAP_SIZE", "parent": 33, "children": [], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 18}}, {"id": 36, "type": "preproc_arg", "text": "33554432u", "parent": 33, "children": [], "start_point": {"row": 12, "column": 19}, "end_point": {"row": 12, "column": 28}}, {"id": 37, "type": "#endif", "text": "#endif", "parent": 30, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 6}}, {"id": 38, "type": "preproc_function_def", "text": "#define ALIGN4(x) (((((x) - 1) >> 2) << 2) + 4)\n", "parent": null, "children": [39, 40, 41, 43], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 39, "type": "#define", "text": "#define", "parent": 38, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 7}}, {"id": 40, "type": "identifier", "text": "ALIGN4", "parent": 38, "children": [], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 14}}, {"id": 41, "type": "preproc_params", "text": "(x)", "parent": 38, "children": [42], "start_point": {"row": 15, "column": 14}, "end_point": {"row": 15, "column": 17}}, {"id": 42, "type": "identifier", "text": "x", "parent": 41, "children": [], "start_point": {"row": 15, "column": 15}, "end_point": {"row": 15, "column": 16}}, {"id": 43, "type": "preproc_arg", "text": "(((((x) - 1) >> 2) << 2) + 4)", "parent": 38, "children": [], "start_point": {"row": 15, "column": 18}, "end_point": {"row": 15, "column": 47}}, {"id": 44, "type": "preproc_function_def", "text": "#define foreach(ptr, List) for(ptr = *List; ptr != NULL; ptr = ptr->next)\n", "parent": null, "children": [45, 46, 47, 50], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 18, "column": 0}}, {"id": 45, "type": "#define", "text": "#define", "parent": 44, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 7}}, {"id": 46, "type": "identifier", "text": "foreach", "parent": 44, "children": [], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 17, "column": 15}}, {"id": 47, "type": "preproc_params", "text": "(ptr, List)", "parent": 44, "children": [48, 49], "start_point": {"row": 17, "column": 15}, "end_point": {"row": 17, "column": 26}}, {"id": 48, "type": "identifier", "text": "ptr", "parent": 47, "children": [], "start_point": {"row": 17, "column": 16}, "end_point": {"row": 17, "column": 19}}, {"id": 49, "type": "identifier", "text": "List", "parent": 47, "children": [], "start_point": {"row": 17, "column": 21}, "end_point": {"row": 17, "column": 25}}, {"id": 50, "type": "preproc_arg", "text": "for(ptr = *List; ptr != NULL; ptr = ptr->next)", "parent": 44, "children": [], "start_point": {"row": 17, "column": 27}, "end_point": {"row": 17, "column": 73}}, {"id": 51, "type": "preproc_function_def", "text": "#define getHeader(ptr) (((Block)ptr)-1);\n", "parent": null, "children": [52, 53, 54, 56], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 20, "column": 0}}, {"id": 52, "type": "#define", "text": "#define", "parent": 51, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 7}}, {"id": 53, "type": "identifier", "text": "getHeader", "parent": 51, "children": [], "start_point": {"row": 19, "column": 8}, "end_point": {"row": 19, "column": 17}}, {"id": 54, "type": "preproc_params", "text": "(ptr)", "parent": 51, "children": [55], "start_point": {"row": 19, "column": 17}, "end_point": {"row": 19, "column": 22}}, {"id": 55, "type": "identifier", "text": "ptr", "parent": 54, "children": [], "start_point": {"row": 19, "column": 18}, "end_point": {"row": 19, "column": 21}}, {"id": 56, "type": "preproc_arg", "text": "(((Block)ptr)-1);", "parent": 51, "children": [], "start_point": {"row": 19, "column": 23}, "end_point": {"row": 19, "column": 40}}, {"id": 57, "type": "preproc_function_def", "text": "#define BlockSize(ptr) (ptr->Info.Field.size)\n", "parent": null, "children": [58, 59, 60, 62], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 22, "column": 0}}, {"id": 58, "type": "#define", "text": "#define", "parent": 57, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 7}}, {"id": 59, "type": "identifier", "text": "BlockSize", "parent": 57, "children": [], "start_point": {"row": 21, "column": 8}, "end_point": {"row": 21, "column": 17}}, {"id": 60, "type": "preproc_params", "text": "(ptr)", "parent": 57, "children": [61], "start_point": {"row": 21, "column": 17}, "end_point": {"row": 21, "column": 22}}, {"id": 61, "type": "identifier", "text": "ptr", "parent": 60, "children": [], "start_point": {"row": 21, "column": 18}, "end_point": {"row": 21, "column": 21}}, {"id": 62, "type": "preproc_arg", "text": "(ptr->Info.Field.size)", "parent": 57, "children": [], "start_point": {"row": 21, "column": 25}, "end_point": {"row": 21, "column": 47}}, {"id": 63, "type": "preproc_function_def", "text": "#define isFreeBlock(ptr) (ptr->Info.Field.free)\n", "parent": null, "children": [64, 65, 66, 68], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 23, "column": 0}}, {"id": 64, "type": "#define", "text": "#define", "parent": 63, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 7}}, {"id": 65, "type": "identifier", "text": "isFreeBlock", "parent": 63, "children": [], "start_point": {"row": 22, "column": 8}, "end_point": {"row": 22, "column": 19}}, {"id": 66, "type": "preproc_params", "text": "(ptr)", "parent": 63, "children": [67], "start_point": {"row": 22, "column": 19}, "end_point": {"row": 22, "column": 24}}, {"id": 67, "type": "identifier", "text": "ptr", "parent": 66, "children": [], "start_point": {"row": 22, "column": 20}, "end_point": {"row": 22, "column": 23}}, {"id": 68, "type": "preproc_arg", "text": "(ptr->Info.Field.free)", "parent": 63, "children": [], "start_point": {"row": 22, "column": 25}, "end_point": {"row": 22, "column": 47}}, {"id": 69, "type": "type_definition", "text": "typedef struct Block\n{\n\tstruct Block* next;\n\n\tunion\n\t{\n\t\tunsigned int BlockInfo;\n\t\tstruct \n\t\t{\n\t\t\tunsigned size:31;\n\t\t\tunsigned free:1;\n\t\t}Field;\n\t}Info;\n\tunsigned int id;\n}*Block;", "parent": null, "children": [70, 71, 111], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 39, "column": 8}}, {"id": 70, "type": "typedef", "text": "typedef", "parent": 69, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 7}}, {"id": 71, "type": "struct_specifier", "text": "struct Block\n{\n\tstruct Block* next;\n\n\tunion\n\t{\n\t\tunsigned int BlockInfo;\n\t\tstruct \n\t\t{\n\t\t\tunsigned size:31;\n\t\t\tunsigned free:1;\n\t\t}Field;\n\t}Info;\n\tunsigned int id;\n}", "parent": 69, "children": [72, 73], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 39, "column": 1}}, {"id": 72, "type": "struct", "text": "struct", "parent": 71, "children": [], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 14}}, {"id": 73, "type": "type_identifier", "text": "Block", "parent": 71, "children": [], "start_point": {"row": 25, "column": 15}, "end_point": {"row": 25, "column": 20}}, {"id": 74, "type": "field_declaration", "text": "struct Block* next;", "parent": 71, "children": [75, 78], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 20}}, {"id": 75, "type": "struct_specifier", "text": "struct Block", "parent": 74, "children": [76, 77], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 13}}, {"id": 76, "type": "struct", "text": "struct", "parent": 75, "children": [], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 7}}, {"id": 77, "type": "type_identifier", "text": "Block", "parent": 75, "children": [], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 13}}, {"id": 78, "type": "pointer_declarator", "text": "* next", "parent": 74, "children": [79, 80], "start_point": {"row": 27, "column": 13}, "end_point": {"row": 27, "column": 19}}, {"id": 79, "type": "*", "text": "*", "parent": 78, "children": [], "start_point": {"row": 27, "column": 13}, "end_point": {"row": 27, "column": 14}}, {"id": 80, "type": "field_identifier", "text": "next", "parent": 78, "children": [], "start_point": {"row": 27, "column": 15}, "end_point": {"row": 27, "column": 19}}, {"id": 81, "type": "field_declaration", "text": "union\n\t{\n\t\tunsigned int BlockInfo;\n\t\tstruct \n\t\t{\n\t\t\tunsigned size:31;\n\t\t\tunsigned free:1;\n\t\t}Field;\n\t}Info;", "parent": 71, "children": [82, 105], "start_point": {"row": 29, "column": 1}, "end_point": {"row": 37, "column": 7}}, {"id": 82, "type": "union_specifier", "text": "union\n\t{\n\t\tunsigned int BlockInfo;\n\t\tstruct \n\t\t{\n\t\t\tunsigned size:31;\n\t\t\tunsigned free:1;\n\t\t}Field;\n\t}", "parent": 81, "children": [83], "start_point": {"row": 29, "column": 1}, "end_point": {"row": 37, "column": 2}}, {"id": 83, "type": "union", "text": "union", "parent": 82, "children": [], "start_point": {"row": 29, "column": 1}, "end_point": {"row": 29, "column": 6}}, {"id": 84, "type": "field_declaration", "text": "unsigned int BlockInfo;", "parent": 82, "children": [85, 88], "start_point": {"row": 31, "column": 2}, "end_point": {"row": 31, "column": 25}}, {"id": 85, "type": "sized_type_specifier", "text": "unsigned int", "parent": 84, "children": [86, 87], "start_point": {"row": 31, "column": 2}, "end_point": {"row": 31, "column": 14}}, {"id": 86, "type": "unsigned", "text": "unsigned", "parent": 85, "children": [], "start_point": {"row": 31, "column": 2}, "end_point": {"row": 31, "column": 10}}, {"id": 87, "type": "primitive_type", "text": "int", "parent": 85, "children": [], "start_point": {"row": 31, "column": 11}, "end_point": {"row": 31, "column": 14}}, {"id": 88, "type": "field_identifier", "text": "BlockInfo", "parent": 84, "children": [], "start_point": {"row": 31, "column": 15}, "end_point": {"row": 31, "column": 24}}, {"id": 89, "type": "field_declaration", "text": "struct \n\t\t{\n\t\t\tunsigned size:31;\n\t\t\tunsigned free:1;\n\t\t}Field;", "parent": 82, "children": [90, 104], "start_point": {"row": 32, "column": 2}, "end_point": {"row": 36, "column": 9}}, {"id": 90, "type": "struct_specifier", "text": "struct \n\t\t{\n\t\t\tunsigned size:31;\n\t\t\tunsigned free:1;\n\t\t}", "parent": 89, "children": [91], "start_point": {"row": 32, "column": 2}, "end_point": {"row": 36, "column": 3}}, {"id": 91, "type": "struct", "text": "struct", "parent": 90, "children": [], "start_point": {"row": 32, "column": 2}, "end_point": {"row": 32, "column": 8}}, {"id": 92, "type": "field_declaration", "text": "unsigned size:31;", "parent": 90, "children": [93, 95, 96], "start_point": {"row": 34, "column": 3}, "end_point": {"row": 34, "column": 20}}, {"id": 93, "type": "sized_type_specifier", "text": "unsigned", "parent": 92, "children": [94], "start_point": {"row": 34, "column": 3}, "end_point": {"row": 34, "column": 11}}, {"id": 94, "type": "unsigned", "text": "unsigned", "parent": 93, "children": [], "start_point": {"row": 34, "column": 3}, "end_point": {"row": 34, "column": 11}}, {"id": 95, "type": "field_identifier", "text": "size", "parent": 92, "children": [], "start_point": {"row": 34, "column": 12}, "end_point": {"row": 34, "column": 16}}, {"id": 96, "type": "bitfield_clause", "text": ":31", "parent": 92, "children": [97], "start_point": {"row": 34, "column": 16}, "end_point": {"row": 34, "column": 19}}, {"id": 97, "type": "number_literal", "text": "31", "parent": 96, "children": [], "start_point": {"row": 34, "column": 17}, "end_point": {"row": 34, "column": 19}}, {"id": 98, "type": "field_declaration", "text": "unsigned free:1;", "parent": 90, "children": [99, 101, 102], "start_point": {"row": 35, "column": 3}, "end_point": {"row": 35, "column": 19}}, {"id": 99, "type": "sized_type_specifier", "text": "unsigned", "parent": 98, "children": [100], "start_point": {"row": 35, "column": 3}, "end_point": {"row": 35, "column": 11}}, {"id": 100, "type": "unsigned", "text": "unsigned", "parent": 99, "children": [], "start_point": {"row": 35, "column": 3}, "end_point": {"row": 35, "column": 11}}, {"id": 101, "type": "field_identifier", "text": "free", "parent": 98, "children": [], "start_point": {"row": 35, "column": 12}, "end_point": {"row": 35, "column": 16}}, {"id": 102, "type": "bitfield_clause", "text": ":1", "parent": 98, "children": [103], "start_point": {"row": 35, "column": 16}, "end_point": {"row": 35, "column": 18}}, {"id": 103, "type": "number_literal", "text": "1", "parent": 102, "children": [], "start_point": {"row": 35, "column": 17}, "end_point": {"row": 35, "column": 18}}, {"id": 104, "type": "field_identifier", "text": "Field", "parent": 89, "children": [], "start_point": {"row": 36, "column": 3}, "end_point": {"row": 36, "column": 8}}, {"id": 105, "type": "field_identifier", "text": "Info", "parent": 81, "children": [], "start_point": {"row": 37, "column": 2}, "end_point": {"row": 37, "column": 6}}, {"id": 106, "type": "field_declaration", "text": "unsigned int id;", "parent": 71, "children": [107, 110], "start_point": {"row": 38, "column": 1}, "end_point": {"row": 38, "column": 17}}, {"id": 107, "type": "sized_type_specifier", "text": "unsigned int", "parent": 106, "children": [108, 109], "start_point": {"row": 38, "column": 1}, "end_point": {"row": 38, "column": 13}}, {"id": 108, "type": "unsigned", "text": "unsigned", "parent": 107, "children": [], "start_point": {"row": 38, "column": 1}, "end_point": {"row": 38, "column": 9}}, {"id": 109, "type": "primitive_type", "text": "int", "parent": 107, "children": [], "start_point": {"row": 38, "column": 10}, "end_point": {"row": 38, "column": 13}}, {"id": 110, "type": "field_identifier", "text": "id", "parent": 106, "children": [], "start_point": {"row": 38, "column": 14}, "end_point": {"row": 38, "column": 16}}, {"id": 111, "type": "pointer_declarator", "text": "*Block", "parent": 69, "children": [112, 113], "start_point": {"row": 39, "column": 1}, "end_point": {"row": 39, "column": 7}}, {"id": 112, "type": "*", "text": "*", "parent": 111, "children": [], "start_point": {"row": 39, "column": 1}, "end_point": {"row": 39, "column": 2}}, {"id": 113, "type": "type_identifier", "text": "Block", "parent": 111, "children": [], "start_point": {"row": 39, "column": 2}, "end_point": {"row": 39, "column": 7}}, {"id": 114, "type": "declaration", "text": "struct \n{\n\tvoid* baseHeap;\n\tBlock LastBlockReleased;\n\tvoid* CurrentPointerHeap;\n\tBlock* ListBlocks;\n}Gerency;", "parent": null, "children": [115, 135], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 47, "column": 9}}, {"id": 115, "type": "struct_specifier", "text": "struct \n{\n\tvoid* baseHeap;\n\tBlock LastBlockReleased;\n\tvoid* CurrentPointerHeap;\n\tBlock* ListBlocks;\n}", "parent": 114, "children": [116], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 47, "column": 1}}, {"id": 116, "type": "struct", "text": "struct", "parent": 115, "children": [], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 41, "column": 6}}, {"id": 117, "type": "field_declaration", "text": "void* baseHeap;", "parent": 115, "children": [118, 119], "start_point": {"row": 43, "column": 1}, "end_point": {"row": 43, "column": 16}}, {"id": 118, "type": "primitive_type", "text": "void", "parent": 117, "children": [], "start_point": {"row": 43, "column": 1}, "end_point": {"row": 43, "column": 5}}, {"id": 119, "type": "pointer_declarator", "text": "* baseHeap", "parent": 117, "children": [120, 121], "start_point": {"row": 43, "column": 5}, "end_point": {"row": 43, "column": 15}}, {"id": 120, "type": "*", "text": "*", "parent": 119, "children": [], "start_point": {"row": 43, "column": 5}, "end_point": {"row": 43, "column": 6}}, {"id": 121, "type": "field_identifier", "text": "baseHeap", "parent": 119, "children": [], "start_point": {"row": 43, "column": 7}, "end_point": {"row": 43, "column": 15}}, {"id": 122, "type": "field_declaration", "text": "Block LastBlockReleased;", "parent": 115, "children": [123, 124], "start_point": {"row": 44, "column": 1}, "end_point": {"row": 44, "column": 25}}, {"id": 123, "type": "type_identifier", "text": "Block", "parent": 122, "children": [], "start_point": {"row": 44, "column": 1}, "end_point": {"row": 44, "column": 6}}, {"id": 124, "type": "field_identifier", "text": "LastBlockReleased", "parent": 122, "children": [], "start_point": {"row": 44, "column": 7}, "end_point": {"row": 44, "column": 24}}, {"id": 125, "type": "field_declaration", "text": "void* CurrentPointerHeap;", "parent": 115, "children": [126, 127], "start_point": {"row": 45, "column": 1}, "end_point": {"row": 45, "column": 26}}, {"id": 126, "type": "primitive_type", "text": "void", "parent": 125, "children": [], "start_point": {"row": 45, "column": 1}, "end_point": {"row": 45, "column": 5}}, {"id": 127, "type": "pointer_declarator", "text": "* CurrentPointerHeap", "parent": 125, "children": [128, 129], "start_point": {"row": 45, "column": 5}, "end_point": {"row": 45, "column": 25}}, {"id": 128, "type": "*", "text": "*", "parent": 127, "children": [], "start_point": {"row": 45, "column": 5}, "end_point": {"row": 45, "column": 6}}, {"id": 129, "type": "field_identifier", "text": "CurrentPointerHeap", "parent": 127, "children": [], "start_point": {"row": 45, "column": 7}, "end_point": {"row": 45, "column": 25}}, {"id": 130, "type": "field_declaration", "text": "Block* ListBlocks;", "parent": 115, "children": [131, 132], "start_point": {"row": 46, "column": 1}, "end_point": {"row": 46, "column": 19}}, {"id": 131, "type": "type_identifier", "text": "Block", "parent": 130, "children": [], "start_point": {"row": 46, "column": 1}, "end_point": {"row": 46, "column": 6}}, {"id": 132, "type": "pointer_declarator", "text": "* ListBlocks", "parent": 130, "children": [133, 134], "start_point": {"row": 46, "column": 6}, "end_point": {"row": 46, "column": 18}}, {"id": 133, "type": "*", "text": "*", "parent": 132, "children": [], "start_point": {"row": 46, "column": 6}, "end_point": {"row": 46, "column": 7}}, {"id": 134, "type": "field_identifier", "text": "ListBlocks", "parent": 132, "children": [], "start_point": {"row": 46, "column": 8}, "end_point": {"row": 46, "column": 18}}, {"id": 135, "type": "identifier", "text": "Gerency", "parent": 114, "children": [], "start_point": {"row": 47, "column": 1}, "end_point": {"row": 47, "column": 8}}, {"id": 136, "type": "declaration", "text": "static unsigned int memoryUsage;", "parent": null, "children": [137, 140], "start_point": {"row": 50, "column": 0}, "end_point": {"row": 50, "column": 32}}, {"id": 137, "type": "sized_type_specifier", "text": "unsigned int", "parent": 136, "children": [138, 139], "start_point": {"row": 50, "column": 7}, "end_point": {"row": 50, "column": 19}}, {"id": 138, "type": "unsigned", "text": "unsigned", "parent": 137, "children": [], "start_point": {"row": 50, "column": 7}, "end_point": {"row": 50, "column": 15}}, {"id": 139, "type": "primitive_type", "text": "int", "parent": 137, "children": [], "start_point": {"row": 50, "column": 16}, "end_point": {"row": 50, "column": 19}}, {"id": 140, "type": "identifier", "text": "memoryUsage", "parent": 136, "children": [], "start_point": {"row": 50, "column": 20}, "end_point": {"row": 50, "column": 31}}, {"id": 141, "type": "declaration", "text": "static unsigned int numberBlocks;", "parent": null, "children": [142, 145], "start_point": {"row": 51, "column": 0}, "end_point": {"row": 51, "column": 33}}, {"id": 142, "type": "sized_type_specifier", "text": "unsigned int", "parent": 141, "children": [143, 144], "start_point": {"row": 51, "column": 7}, "end_point": {"row": 51, "column": 19}}, {"id": 143, "type": "unsigned", "text": "unsigned", "parent": 142, "children": [], "start_point": {"row": 51, "column": 7}, "end_point": {"row": 51, "column": 15}}, {"id": 144, "type": "primitive_type", "text": "int", "parent": 142, "children": [], "start_point": {"row": 51, "column": 16}, "end_point": {"row": 51, "column": 19}}, {"id": 145, "type": "identifier", "text": "numberBlocks", "parent": 141, "children": [], "start_point": {"row": 51, "column": 20}, "end_point": {"row": 51, "column": 32}}, {"id": 146, "type": "declaration", "text": "static unsigned int numberFreeBlocks;", "parent": null, "children": [147, 150], "start_point": {"row": 52, "column": 0}, "end_point": {"row": 52, "column": 37}}, {"id": 147, "type": "sized_type_specifier", "text": "unsigned int", "parent": 146, "children": [148, 149], "start_point": {"row": 52, "column": 7}, "end_point": {"row": 52, "column": 19}}, {"id": 148, "type": "unsigned", "text": "unsigned", "parent": 147, "children": [], "start_point": {"row": 52, "column": 7}, "end_point": {"row": 52, "column": 15}}, {"id": 149, "type": "primitive_type", "text": "int", "parent": 147, "children": [], "start_point": {"row": 52, "column": 16}, "end_point": {"row": 52, "column": 19}}, {"id": 150, "type": "identifier", "text": "numberFreeBlocks", "parent": 146, "children": [], "start_point": {"row": 52, "column": 20}, "end_point": {"row": 52, "column": 36}}, {"id": 151, "type": "declaration", "text": "static unsigned int numberFragmentation;", "parent": null, "children": [152, 155], "start_point": {"row": 53, "column": 0}, "end_point": {"row": 53, "column": 40}}, {"id": 152, "type": "sized_type_specifier", "text": "unsigned int", "parent": 151, "children": [153, 154], "start_point": {"row": 53, "column": 7}, "end_point": {"row": 53, "column": 19}}, {"id": 153, "type": "unsigned", "text": "unsigned", "parent": 152, "children": [], "start_point": {"row": 53, "column": 7}, "end_point": {"row": 53, "column": 15}}, {"id": 154, "type": "primitive_type", "text": "int", "parent": 152, "children": [], "start_point": {"row": 53, "column": 16}, "end_point": {"row": 53, "column": 19}}, {"id": 155, "type": "identifier", "text": "numberFragmentation", "parent": 151, "children": [], "start_point": {"row": 53, "column": 20}, "end_point": {"row": 53, "column": 39}}, {"id": 156, "type": "declaration", "text": "static unsigned int totalAllocatedMemory;", "parent": null, "children": [157, 160], "start_point": {"row": 54, "column": 0}, "end_point": {"row": 54, "column": 41}}, {"id": 157, "type": "sized_type_specifier", "text": "unsigned int", "parent": 156, "children": [158, 159], "start_point": {"row": 54, "column": 7}, "end_point": {"row": 54, "column": 19}}, {"id": 158, "type": "unsigned", "text": "unsigned", "parent": 157, "children": [], "start_point": {"row": 54, "column": 7}, "end_point": {"row": 54, "column": 15}}, {"id": 159, "type": "primitive_type", "text": "int", "parent": 157, "children": [], "start_point": {"row": 54, "column": 16}, "end_point": {"row": 54, "column": 19}}, {"id": 160, "type": "identifier", "text": "totalAllocatedMemory", "parent": 156, "children": [], "start_point": {"row": 54, "column": 20}, "end_point": {"row": 54, "column": 40}}, {"id": 161, "type": "declaration", "text": "static const unsigned int MAX_FRAGMENTATION_BLOCK = 10U;", "parent": null, "children": [162, 165], "start_point": {"row": 55, "column": 0}, "end_point": {"row": 55, "column": 56}}, {"id": 162, "type": "sized_type_specifier", "text": "unsigned int", "parent": 161, "children": [163, 164], "start_point": {"row": 55, "column": 13}, "end_point": {"row": 55, "column": 25}}, {"id": 163, "type": "unsigned", "text": "unsigned", "parent": 162, "children": [], "start_point": {"row": 55, "column": 13}, "end_point": {"row": 55, "column": 21}}, {"id": 164, "type": "primitive_type", "text": "int", "parent": 162, "children": [], "start_point": {"row": 55, "column": 22}, "end_point": {"row": 55, "column": 25}}, {"id": 165, "type": "init_declarator", "text": "MAX_FRAGMENTATION_BLOCK = 10U", "parent": 161, "children": [166, 167, 168], "start_point": {"row": 55, "column": 26}, "end_point": {"row": 55, "column": 55}}, {"id": 166, "type": "identifier", "text": "MAX_FRAGMENTATION_BLOCK", "parent": 165, "children": [], "start_point": {"row": 55, "column": 26}, "end_point": {"row": 55, "column": 49}}, {"id": 167, "type": "=", "text": "=", "parent": 165, "children": [], "start_point": {"row": 55, "column": 50}, "end_point": {"row": 55, "column": 51}}, {"id": 168, "type": "number_literal", "text": "10U", "parent": 165, "children": [], "start_point": {"row": 55, "column": 52}, "end_point": {"row": 55, "column": 55}}, {"id": 169, "type": "declaration", "text": "enum AllocationAlgorithm AAlgorithm = FIRST_FIT;", "parent": null, "children": [170, 173], "start_point": {"row": 56, "column": 0}, "end_point": {"row": 56, "column": 48}}, {"id": 170, "type": "enum_specifier", "text": "enum AllocationAlgorithm", "parent": 169, "children": [171, 172], "start_point": {"row": 56, "column": 0}, "end_point": {"row": 56, "column": 24}}, {"id": 171, "type": "enum", "text": "enum", "parent": 170, "children": [], "start_point": {"row": 56, "column": 0}, "end_point": {"row": 56, "column": 4}}, {"id": 172, "type": "type_identifier", "text": "AllocationAlgorithm", "parent": 170, "children": [], "start_point": {"row": 56, "column": 5}, "end_point": {"row": 56, "column": 24}}, {"id": 173, "type": "init_declarator", "text": "AAlgorithm = FIRST_FIT", "parent": 169, "children": [174, 175, 176], "start_point": {"row": 56, "column": 25}, "end_point": {"row": 56, "column": 47}}, {"id": 174, "type": "identifier", "text": "AAlgorithm", "parent": 173, "children": [], "start_point": {"row": 56, "column": 25}, "end_point": {"row": 56, "column": 35}}, {"id": 175, "type": "=", "text": "=", "parent": 173, "children": [], "start_point": {"row": 56, "column": 36}, "end_point": {"row": 56, "column": 37}}, {"id": 176, "type": "identifier", "text": "FIRST_FIT", "parent": 173, "children": [], "start_point": {"row": 56, "column": 38}, "end_point": {"row": 56, "column": 47}}, {"id": 177, "type": "function_definition", "text": "static void __attribute__((constructor))InitMalloc(void)\n{\n\tvoid* response;\n\n\tputs(\"\\n\\n\");\n\n\tGerency.baseHeap = sbrk(0);\n\tresponse = sbrk(ALIGN4(HEAP_SIZE));\n\n\ttotalAllocatedMemory += ALIGN4(HEAP_SIZE);\n\n\tassert(!(response == (void*)-1));\n\n\tGerency.ListBlocks = sbrk(0);\n\tresponse = sbrk(sizeof(Block));\n \n totalAllocatedMemory += sizeof(Block);\n\n\n\tassert(!(response == (void*)-1));\n\n\t*(Gerency.ListBlocks) = NULL;\n\tGerency.LastBlockReleased = NULL;\n\tnumberBlocks = 0;\n\tGerency.CurrentPointerHeap = Gerency.baseHeap;\n}", "parent": null, "children": [178, 179, 183], "start_point": {"row": 60, "column": 0}, "end_point": {"row": 85, "column": 1}}, {"id": 178, "type": "primitive_type", "text": "void", "parent": 177, "children": [], "start_point": {"row": 60, "column": 7}, "end_point": {"row": 60, "column": 11}}, {"id": 179, "type": "attribute_specifier", "text": "__attribute__((constructor))", "parent": 177, "children": [180, 181], "start_point": {"row": 60, "column": 12}, "end_point": {"row": 60, "column": 40}}, {"id": 180, "type": "__attribute__", "text": "__attribute__", "parent": 179, "children": [], "start_point": {"row": 60, "column": 12}, "end_point": {"row": 60, "column": 25}}, {"id": 181, "type": "argument_list", "text": "(constructor)", "parent": 179, "children": [182], "start_point": {"row": 60, "column": 26}, "end_point": {"row": 60, "column": 39}}, {"id": 182, "type": "identifier", "text": "constructor", "parent": 181, "children": [], "start_point": {"row": 60, "column": 27}, "end_point": {"row": 60, "column": 38}}, {"id": 183, "type": "function_declarator", "text": "InitMalloc(void)", "parent": 177, "children": [184, 185], "start_point": {"row": 60, "column": 40}, "end_point": {"row": 60, "column": 56}}, {"id": 184, "type": "identifier", "text": "InitMalloc", "parent": 183, "children": [], "start_point": {"row": 60, "column": 40}, "end_point": {"row": 60, "column": 50}}, {"id": 185, "type": "parameter_list", "text": "(void)", "parent": 183, "children": [186], "start_point": {"row": 60, "column": 50}, "end_point": {"row": 60, "column": 56}}, {"id": 186, "type": "parameter_declaration", "text": "void", "parent": 185, "children": [187], "start_point": {"row": 60, "column": 51}, "end_point": {"row": 60, "column": 55}}, {"id": 187, "type": "primitive_type", "text": "void", "parent": 186, "children": [], "start_point": {"row": 60, "column": 51}, "end_point": {"row": 60, "column": 55}}, {"id": 188, "type": "declaration", "text": "void* response;", "parent": 177, "children": [189, 190], "start_point": {"row": 62, "column": 1}, "end_point": {"row": 62, "column": 16}}, {"id": 189, "type": "primitive_type", "text": "void", "parent": 188, "children": [], "start_point": {"row": 62, "column": 1}, "end_point": {"row": 62, "column": 5}}, {"id": 190, "type": "pointer_declarator", "text": "* response", "parent": 188, "children": [191, 192], "start_point": {"row": 62, "column": 5}, "end_point": {"row": 62, "column": 15}}, {"id": 191, "type": "*", "text": "*", "parent": 190, "children": [], "start_point": {"row": 62, "column": 5}, "end_point": {"row": 62, "column": 6}}, {"id": 192, "type": "identifier", "text": "response", "parent": 190, "children": [], "start_point": {"row": 62, "column": 7}, "end_point": {"row": 62, "column": 15}}, {"id": 193, "type": "call_expression", "text": "puts(\"\\n\\n\")", "parent": 177, "children": [194, 195], "start_point": {"row": 64, "column": 1}, "end_point": {"row": 64, "column": 13}}, {"id": 194, "type": "identifier", "text": "puts", "parent": 193, "children": [], "start_point": {"row": 64, "column": 1}, "end_point": {"row": 64, "column": 5}}, {"id": 195, "type": "argument_list", "text": "(\"\\n\\n\")", "parent": 193, "children": [196], "start_point": {"row": 64, "column": 5}, "end_point": {"row": 64, "column": 13}}, {"id": 196, "type": "string_literal", "text": "\"\\n\\n\"", "parent": 195, "children": [197, 198], "start_point": {"row": 64, "column": 6}, "end_point": {"row": 64, "column": 12}}, {"id": 197, "type": "escape_sequence", "text": "\\n", "parent": 196, "children": [], "start_point": {"row": 64, "column": 7}, "end_point": {"row": 64, "column": 9}}, {"id": 198, "type": "escape_sequence", "text": "\\n", "parent": 196, "children": [], "start_point": {"row": 64, "column": 9}, "end_point": {"row": 64, "column": 11}}, {"id": 199, "type": "assignment_expression", "text": "Gerency.baseHeap = sbrk(0)", "parent": 177, "children": [200, 203, 204], "start_point": {"row": 66, "column": 1}, "end_point": {"row": 66, "column": 27}}, {"id": 200, "type": "field_expression", "text": "Gerency.baseHeap", "parent": 199, "children": [201, 202], "start_point": {"row": 66, "column": 1}, "end_point": {"row": 66, "column": 17}}, {"id": 201, "type": "identifier", "text": "Gerency", "parent": 200, "children": [], "start_point": {"row": 66, "column": 1}, "end_point": {"row": 66, "column": 8}}, {"id": 202, "type": "field_identifier", "text": "baseHeap", "parent": 200, "children": [], "start_point": {"row": 66, "column": 9}, "end_point": {"row": 66, "column": 17}}, {"id": 203, "type": "=", "text": "=", "parent": 199, "children": [], "start_point": {"row": 66, "column": 18}, "end_point": {"row": 66, "column": 19}}, {"id": 204, "type": "call_expression", "text": "sbrk(0)", "parent": 199, "children": [205, 206], "start_point": {"row": 66, "column": 20}, "end_point": {"row": 66, "column": 27}}, {"id": 205, "type": "identifier", "text": "sbrk", "parent": 204, "children": [], "start_point": {"row": 66, "column": 20}, "end_point": {"row": 66, "column": 24}}, {"id": 206, "type": "argument_list", "text": "(0)", "parent": 204, "children": [207], "start_point": {"row": 66, "column": 24}, "end_point": {"row": 66, "column": 27}}, {"id": 207, "type": "number_literal", "text": "0", "parent": 206, "children": [], "start_point": {"row": 66, "column": 25}, "end_point": {"row": 66, "column": 26}}, {"id": 208, "type": "assignment_expression", "text": "response = sbrk(ALIGN4(HEAP_SIZE))", "parent": 177, "children": [209, 210, 211], "start_point": {"row": 67, "column": 1}, "end_point": {"row": 67, "column": 35}}, {"id": 209, "type": "identifier", "text": "response", "parent": 208, "children": [], "start_point": {"row": 67, "column": 1}, "end_point": {"row": 67, "column": 9}}, {"id": 210, "type": "=", "text": "=", "parent": 208, "children": [], "start_point": {"row": 67, "column": 10}, "end_point": {"row": 67, "column": 11}}, {"id": 211, "type": "call_expression", "text": "sbrk(ALIGN4(HEAP_SIZE))", "parent": 208, "children": [212, 213], "start_point": {"row": 67, "column": 12}, "end_point": {"row": 67, "column": 35}}, {"id": 212, "type": "identifier", "text": "sbrk", "parent": 211, "children": [], "start_point": {"row": 67, "column": 12}, "end_point": {"row": 67, "column": 16}}, {"id": 213, "type": "argument_list", "text": "(ALIGN4(HEAP_SIZE))", "parent": 211, "children": [214], "start_point": {"row": 67, "column": 16}, "end_point": {"row": 67, "column": 35}}, {"id": 214, "type": "call_expression", "text": "ALIGN4(HEAP_SIZE)", "parent": 213, "children": [215, 216], "start_point": {"row": 67, "column": 17}, "end_point": {"row": 67, "column": 34}}, {"id": 215, "type": "identifier", "text": "ALIGN4", "parent": 214, "children": [], "start_point": {"row": 67, "column": 17}, "end_point": {"row": 67, "column": 23}}, {"id": 216, "type": "argument_list", "text": "(HEAP_SIZE)", "parent": 214, "children": [217], "start_point": {"row": 67, "column": 23}, "end_point": {"row": 67, "column": 34}}, {"id": 217, "type": "identifier", "text": "HEAP_SIZE", "parent": 216, "children": [], "start_point": {"row": 67, "column": 24}, "end_point": {"row": 67, "column": 33}}, {"id": 218, "type": "assignment_expression", "text": "totalAllocatedMemory += ALIGN4(HEAP_SIZE)", "parent": 177, "children": [219, 220, 221], "start_point": {"row": 69, "column": 1}, "end_point": {"row": 69, "column": 42}}, {"id": 219, "type": "identifier", "text": "totalAllocatedMemory", "parent": 218, "children": [], "start_point": {"row": 69, "column": 1}, "end_point": {"row": 69, "column": 21}}, {"id": 220, "type": "+=", "text": "+=", "parent": 218, "children": [], "start_point": {"row": 69, "column": 22}, "end_point": {"row": 69, "column": 24}}, {"id": 221, "type": "call_expression", "text": "ALIGN4(HEAP_SIZE)", "parent": 218, "children": [222, 223], "start_point": {"row": 69, "column": 25}, "end_point": {"row": 69, "column": 42}}, {"id": 222, "type": "identifier", "text": "ALIGN4", "parent": 221, "children": [], "start_point": {"row": 69, "column": 25}, "end_point": {"row": 69, "column": 31}}, {"id": 223, "type": "argument_list", "text": "(HEAP_SIZE)", "parent": 221, "children": [224], "start_point": {"row": 69, "column": 31}, "end_point": {"row": 69, "column": 42}}, {"id": 224, "type": "identifier", "text": "HEAP_SIZE", "parent": 223, "children": [], "start_point": {"row": 69, "column": 32}, "end_point": {"row": 69, "column": 41}}, {"id": 225, "type": "call_expression", "text": "assert(!(response == (void*)-1))", "parent": 177, "children": [226, 227], "start_point": {"row": 71, "column": 1}, "end_point": {"row": 71, "column": 33}}, {"id": 226, "type": "identifier", "text": "assert", "parent": 225, "children": [], "start_point": {"row": 71, "column": 1}, "end_point": {"row": 71, "column": 7}}, {"id": 227, "type": "argument_list", "text": "(!(response == (void*)-1))", "parent": 225, "children": [228], "start_point": {"row": 71, "column": 7}, "end_point": {"row": 71, "column": 33}}, {"id": 228, "type": "unary_expression", "text": "!(response == (void*)-1)", "parent": 227, "children": [229, 230], "start_point": {"row": 71, "column": 8}, "end_point": {"row": 71, "column": 32}}, {"id": 229, "type": "!", "text": "!", "parent": 228, "children": [], "start_point": {"row": 71, "column": 8}, "end_point": {"row": 71, "column": 9}}, {"id": 230, "type": "parenthesized_expression", "text": "(response == (void*)-1)", "parent": 228, "children": [231], "start_point": {"row": 71, "column": 9}, "end_point": {"row": 71, "column": 32}}, {"id": 231, "type": "binary_expression", "text": "response == (void*)-1", "parent": 230, "children": [232, 233, 234], "start_point": {"row": 71, "column": 10}, "end_point": {"row": 71, "column": 31}}, {"id": 232, "type": "identifier", "text": "response", "parent": 231, "children": [], "start_point": {"row": 71, "column": 10}, "end_point": {"row": 71, "column": 18}}, {"id": 233, "type": "==", "text": "==", "parent": 231, "children": [], "start_point": {"row": 71, "column": 19}, "end_point": {"row": 71, "column": 21}}, {"id": 234, "type": "cast_expression", "text": "(void*)-1", "parent": 231, "children": [235, 239], "start_point": {"row": 71, "column": 22}, "end_point": {"row": 71, "column": 31}}, {"id": 235, "type": "type_descriptor", "text": "void*", "parent": 234, "children": [236, 237], "start_point": {"row": 71, "column": 23}, "end_point": {"row": 71, "column": 28}}, {"id": 236, "type": "primitive_type", "text": "void", "parent": 235, "children": [], "start_point": {"row": 71, "column": 23}, "end_point": {"row": 71, "column": 27}}, {"id": 237, "type": "abstract_pointer_declarator", "text": "*", "parent": 235, "children": [238], "start_point": {"row": 71, "column": 27}, "end_point": {"row": 71, "column": 28}}, {"id": 238, "type": "*", "text": "*", "parent": 237, "children": [], "start_point": {"row": 71, "column": 27}, "end_point": {"row": 71, "column": 28}}, {"id": 239, "type": "number_literal", "text": "-1", "parent": 234, "children": [], "start_point": {"row": 71, "column": 29}, "end_point": {"row": 71, "column": 31}}, {"id": 240, "type": "assignment_expression", "text": "Gerency.ListBlocks = sbrk(0)", "parent": 177, "children": [241, 244, 245], "start_point": {"row": 73, "column": 1}, "end_point": {"row": 73, "column": 29}}, {"id": 241, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 240, "children": [242, 243], "start_point": {"row": 73, "column": 1}, "end_point": {"row": 73, "column": 19}}, {"id": 242, "type": "identifier", "text": "Gerency", "parent": 241, "children": [], "start_point": {"row": 73, "column": 1}, "end_point": {"row": 73, "column": 8}}, {"id": 243, "type": "field_identifier", "text": "ListBlocks", "parent": 241, "children": [], "start_point": {"row": 73, "column": 9}, "end_point": {"row": 73, "column": 19}}, {"id": 244, "type": "=", "text": "=", "parent": 240, "children": [], "start_point": {"row": 73, "column": 20}, "end_point": {"row": 73, "column": 21}}, {"id": 245, "type": "call_expression", "text": "sbrk(0)", "parent": 240, "children": [246, 247], "start_point": {"row": 73, "column": 22}, "end_point": {"row": 73, "column": 29}}, {"id": 246, "type": "identifier", "text": "sbrk", "parent": 245, "children": [], "start_point": {"row": 73, "column": 22}, "end_point": {"row": 73, "column": 26}}, {"id": 247, "type": "argument_list", "text": "(0)", "parent": 245, "children": [248], "start_point": {"row": 73, "column": 26}, "end_point": {"row": 73, "column": 29}}, {"id": 248, "type": "number_literal", "text": "0", "parent": 247, "children": [], "start_point": {"row": 73, "column": 27}, "end_point": {"row": 73, "column": 28}}, {"id": 249, "type": "assignment_expression", "text": "response = sbrk(sizeof(Block))", "parent": 177, "children": [250, 251, 252], "start_point": {"row": 74, "column": 1}, "end_point": {"row": 74, "column": 31}}, {"id": 250, "type": "identifier", "text": "response", "parent": 249, "children": [], "start_point": {"row": 74, "column": 1}, "end_point": {"row": 74, "column": 9}}, {"id": 251, "type": "=", "text": "=", "parent": 249, "children": [], "start_point": {"row": 74, "column": 10}, "end_point": {"row": 74, "column": 11}}, {"id": 252, "type": "call_expression", "text": "sbrk(sizeof(Block))", "parent": 249, "children": [253, 254], "start_point": {"row": 74, "column": 12}, "end_point": {"row": 74, "column": 31}}, {"id": 253, "type": "identifier", "text": "sbrk", "parent": 252, "children": [], "start_point": {"row": 74, "column": 12}, "end_point": {"row": 74, "column": 16}}, {"id": 254, "type": "argument_list", "text": "(sizeof(Block))", "parent": 252, "children": [255], "start_point": {"row": 74, "column": 16}, "end_point": {"row": 74, "column": 31}}, {"id": 255, "type": "sizeof_expression", "text": "sizeof(Block)", "parent": 254, "children": [256], "start_point": {"row": 74, "column": 17}, "end_point": {"row": 74, "column": 30}}, {"id": 256, "type": "parenthesized_expression", "text": "(Block)", "parent": 255, "children": [257], "start_point": {"row": 74, "column": 23}, "end_point": {"row": 74, "column": 30}}, {"id": 257, "type": "identifier", "text": "Block", "parent": 256, "children": [], "start_point": {"row": 74, "column": 24}, "end_point": {"row": 74, "column": 29}}, {"id": 258, "type": "assignment_expression", "text": "totalAllocatedMemory += sizeof(Block)", "parent": 177, "children": [259, 260, 261], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 41}}, {"id": 259, "type": "identifier", "text": "totalAllocatedMemory", "parent": 258, "children": [], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 24}}, {"id": 260, "type": "+=", "text": "+=", "parent": 258, "children": [], "start_point": {"row": 76, "column": 25}, "end_point": {"row": 76, "column": 27}}, {"id": 261, "type": "sizeof_expression", "text": "sizeof(Block)", "parent": 258, "children": [262], "start_point": {"row": 76, "column": 28}, "end_point": {"row": 76, "column": 41}}, {"id": 262, "type": "parenthesized_expression", "text": "(Block)", "parent": 261, "children": [263], "start_point": {"row": 76, "column": 34}, "end_point": {"row": 76, "column": 41}}, {"id": 263, "type": "identifier", "text": "Block", "parent": 262, "children": [], "start_point": {"row": 76, "column": 35}, "end_point": {"row": 76, "column": 40}}, {"id": 264, "type": "call_expression", "text": "assert(!(response == (void*)-1))", "parent": 177, "children": [265, 266], "start_point": {"row": 79, "column": 1}, "end_point": {"row": 79, "column": 33}}, {"id": 265, "type": "identifier", "text": "assert", "parent": 264, "children": [], "start_point": {"row": 79, "column": 1}, "end_point": {"row": 79, "column": 7}}, {"id": 266, "type": "argument_list", "text": "(!(response == (void*)-1))", "parent": 264, "children": [267], "start_point": {"row": 79, "column": 7}, "end_point": {"row": 79, "column": 33}}, {"id": 267, "type": "unary_expression", "text": "!(response == (void*)-1)", "parent": 266, "children": [268, 269], "start_point": {"row": 79, "column": 8}, "end_point": {"row": 79, "column": 32}}, {"id": 268, "type": "!", "text": "!", "parent": 267, "children": [], "start_point": {"row": 79, "column": 8}, "end_point": {"row": 79, "column": 9}}, {"id": 269, "type": "parenthesized_expression", "text": "(response == (void*)-1)", "parent": 267, "children": [270], "start_point": {"row": 79, "column": 9}, "end_point": {"row": 79, "column": 32}}, {"id": 270, "type": "binary_expression", "text": "response == (void*)-1", "parent": 269, "children": [271, 272, 273], "start_point": {"row": 79, "column": 10}, "end_point": {"row": 79, "column": 31}}, {"id": 271, "type": "identifier", "text": "response", "parent": 270, "children": [], "start_point": {"row": 79, "column": 10}, "end_point": {"row": 79, "column": 18}}, {"id": 272, "type": "==", "text": "==", "parent": 270, "children": [], "start_point": {"row": 79, "column": 19}, "end_point": {"row": 79, "column": 21}}, {"id": 273, "type": "cast_expression", "text": "(void*)-1", "parent": 270, "children": [274, 278], "start_point": {"row": 79, "column": 22}, "end_point": {"row": 79, "column": 31}}, {"id": 274, "type": "type_descriptor", "text": "void*", "parent": 273, "children": [275, 276], "start_point": {"row": 79, "column": 23}, "end_point": {"row": 79, "column": 28}}, {"id": 275, "type": "primitive_type", "text": "void", "parent": 274, "children": [], "start_point": {"row": 79, "column": 23}, "end_point": {"row": 79, "column": 27}}, {"id": 276, "type": "abstract_pointer_declarator", "text": "*", "parent": 274, "children": [277], "start_point": {"row": 79, "column": 27}, "end_point": {"row": 79, "column": 28}}, {"id": 277, "type": "*", "text": "*", "parent": 276, "children": [], "start_point": {"row": 79, "column": 27}, "end_point": {"row": 79, "column": 28}}, {"id": 278, "type": "number_literal", "text": "-1", "parent": 273, "children": [], "start_point": {"row": 79, "column": 29}, "end_point": {"row": 79, "column": 31}}, {"id": 279, "type": "assignment_expression", "text": "*(Gerency.ListBlocks) = NULL", "parent": 177, "children": [280, 286, 287], "start_point": {"row": 81, "column": 1}, "end_point": {"row": 81, "column": 29}}, {"id": 280, "type": "pointer_expression", "text": "*(Gerency.ListBlocks)", "parent": 279, "children": [281, 282], "start_point": {"row": 81, "column": 1}, "end_point": {"row": 81, "column": 22}}, {"id": 281, "type": "*", "text": "*", "parent": 280, "children": [], "start_point": {"row": 81, "column": 1}, "end_point": {"row": 81, "column": 2}}, {"id": 282, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 280, "children": [283], "start_point": {"row": 81, "column": 2}, "end_point": {"row": 81, "column": 22}}, {"id": 283, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 282, "children": [284, 285], "start_point": {"row": 81, "column": 3}, "end_point": {"row": 81, "column": 21}}, {"id": 284, "type": "identifier", "text": "Gerency", "parent": 283, "children": [], "start_point": {"row": 81, "column": 3}, "end_point": {"row": 81, "column": 10}}, {"id": 285, "type": "field_identifier", "text": "ListBlocks", "parent": 283, "children": [], "start_point": {"row": 81, "column": 11}, "end_point": {"row": 81, "column": 21}}, {"id": 286, "type": "=", "text": "=", "parent": 279, "children": [], "start_point": {"row": 81, "column": 23}, "end_point": {"row": 81, "column": 24}}, {"id": 287, "type": "null", "text": "NULL", "parent": 279, "children": [288], "start_point": {"row": 81, "column": 25}, "end_point": {"row": 81, "column": 29}}, {"id": 288, "type": "NULL", "text": "NULL", "parent": 287, "children": [], "start_point": {"row": 81, "column": 25}, "end_point": {"row": 81, "column": 29}}, {"id": 289, "type": "assignment_expression", "text": "Gerency.LastBlockReleased = NULL", "parent": 177, "children": [290, 293, 294], "start_point": {"row": 82, "column": 1}, "end_point": {"row": 82, "column": 33}}, {"id": 290, "type": "field_expression", "text": "Gerency.LastBlockReleased", "parent": 289, "children": [291, 292], "start_point": {"row": 82, "column": 1}, "end_point": {"row": 82, "column": 26}}, {"id": 291, "type": "identifier", "text": "Gerency", "parent": 290, "children": [], "start_point": {"row": 82, "column": 1}, "end_point": {"row": 82, "column": 8}}, {"id": 292, "type": "field_identifier", "text": "LastBlockReleased", "parent": 290, "children": [], "start_point": {"row": 82, "column": 9}, "end_point": {"row": 82, "column": 26}}, {"id": 293, "type": "=", "text": "=", "parent": 289, "children": [], "start_point": {"row": 82, "column": 27}, "end_point": {"row": 82, "column": 28}}, {"id": 294, "type": "null", "text": "NULL", "parent": 289, "children": [295], "start_point": {"row": 82, "column": 29}, "end_point": {"row": 82, "column": 33}}, {"id": 295, "type": "NULL", "text": "NULL", "parent": 294, "children": [], "start_point": {"row": 82, "column": 29}, "end_point": {"row": 82, "column": 33}}, {"id": 296, "type": "assignment_expression", "text": "numberBlocks = 0", "parent": 177, "children": [297, 298, 299], "start_point": {"row": 83, "column": 1}, "end_point": {"row": 83, "column": 17}}, {"id": 297, "type": "identifier", "text": "numberBlocks", "parent": 296, "children": [], "start_point": {"row": 83, "column": 1}, "end_point": {"row": 83, "column": 13}}, {"id": 298, "type": "=", "text": "=", "parent": 296, "children": [], "start_point": {"row": 83, "column": 14}, "end_point": {"row": 83, "column": 15}}, {"id": 299, "type": "number_literal", "text": "0", "parent": 296, "children": [], "start_point": {"row": 83, "column": 16}, "end_point": {"row": 83, "column": 17}}, {"id": 300, "type": "assignment_expression", "text": "Gerency.CurrentPointerHeap = Gerency.baseHeap", "parent": 177, "children": [301, 304, 305], "start_point": {"row": 84, "column": 1}, "end_point": {"row": 84, "column": 46}}, {"id": 301, "type": "field_expression", "text": "Gerency.CurrentPointerHeap", "parent": 300, "children": [302, 303], "start_point": {"row": 84, "column": 1}, "end_point": {"row": 84, "column": 27}}, {"id": 302, "type": "identifier", "text": "Gerency", "parent": 301, "children": [], "start_point": {"row": 84, "column": 1}, "end_point": {"row": 84, "column": 8}}, {"id": 303, "type": "field_identifier", "text": "CurrentPointerHeap", "parent": 301, "children": [], "start_point": {"row": 84, "column": 9}, "end_point": {"row": 84, "column": 27}}, {"id": 304, "type": "=", "text": "=", "parent": 300, "children": [], "start_point": {"row": 84, "column": 28}, "end_point": {"row": 84, "column": 29}}, {"id": 305, "type": "field_expression", "text": "Gerency.baseHeap", "parent": 300, "children": [306, 307], "start_point": {"row": 84, "column": 30}, "end_point": {"row": 84, "column": 46}}, {"id": 306, "type": "identifier", "text": "Gerency", "parent": 305, "children": [], "start_point": {"row": 84, "column": 30}, "end_point": {"row": 84, "column": 37}}, {"id": 307, "type": "field_identifier", "text": "baseHeap", "parent": 305, "children": [], "start_point": {"row": 84, "column": 38}, "end_point": {"row": 84, "column": 46}}, {"id": 308, "type": "function_definition", "text": "void* myMalloc(unsigned int size)\n{\n\tBlock newBlock;\n\tBlock scroll;\n\tBlock previousScroll;\n\tBlock enjoyBlock;\n\tBlock tempBlock;\n\tBlock* headerList;\n\tint spaceFree = 0;\n\tint spaceEvaluation = 0;\n\n\tsize = ALIGN4(size);\n\n\tif((Gerency.CurrentPointerHeap) - (Gerency.baseHeap) == HEAP_SIZE)\n\t\treturn NULL;\n\n\tif(((Gerency.CurrentPointerHeap) + size) >= (void*)HEAP_SIZE)\n\t{\n\t\treturn NULL;\n\t}\n\n\tif((*(Gerency.ListBlocks)) == NULL)\n\t{\n\t\tnewBlock = Gerency.CurrentPointerHeap;\n\t\tnewBlock->next = NULL;\n\t\tnewBlock->Info.Field.free = 0;\n\t\tnewBlock->Info.Field.size = size;\n\t\tnewBlock->id = numberBlocks;\n\t\t*(Gerency.ListBlocks) = newBlock;\n\t\t\n\t\tnumberBlocks += 1;\n\n\t\tGerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n\t\tmemoryUsage += ((sizeof(struct Block) + size));\n\t} \n\telse\n\t{\n\t\tif((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))\n\t\t{\n\t\t\tenjoyBlock = Gerency.LastBlockReleased;\n\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\tGerency.LastBlockReleased = NULL;\n\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\tnumberFreeBlocks -= 1;\n\t\t\treturn (enjoyBlock + 1);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tswitch(AAlgorithm)\n\t\t\t{\n\t\t\t\tcase FIRST_FIT:\n\t\t\t\ttry_first_fit:\n\n\n\t\t\t\t\tforeach(enjoyBlock,(Gerency.ListBlocks))\n\t\t\t\t\t{\n\t\t\t\t\t\tif((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\t\t\t\t\tnumberFreeBlocks -= 1;\n\t\t\t\t\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\t\t\t\t\treturn (enjoyBlock + 1);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tcase BEST_FIT:\n\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, Gerency.ListBlocks)\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(spaceFree < 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\telse if(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\tnumberFragmentation += BlockSize(tempBlock) - size;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\n\t\t\t\tcase WORST_FIT:\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, (Gerency.ListBlocks))\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tdefault:\n\t\t\t\t\tgoto try_first_fit;\n\n\t\t\t}\n\n\t\t\tscroll = *(Gerency.ListBlocks);\n\n\t\t\twhile((scroll != NULL) && (BlockSize(scroll) < size))\n\t\t\t{\n\t\t\t\tpreviousScroll = scroll;\n\t\t\t\tscroll = scroll->next;\n\t\t\t}\n\n\t\t\tnewBlock = Gerency.CurrentPointerHeap;\n\t\t\tnewBlock->Info.Field.free = 0;\n\t\t\tnewBlock->Info.Field.size = size;\n\t\t\tnewBlock->id = numberBlocks;\n\t\t\tnumberBlocks += 1;\n\n\t\t\tif(scroll == *(Gerency.ListBlocks) )\n\t\t\t{\n\t\t\t\tnewBlock->next = *(Gerency.ListBlocks);\n\t\t\t\t*(Gerency.ListBlocks) = newBlock;\n\t\t\t}\n\t\t\t\n\t\t\telse\n\t\t\t{\n\t\t\t\tnewBlock->next = previousScroll->next;\n\t\t\t\tpreviousScroll->next = newBlock;\n\t\t\t}\n\n\t\t\tGerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n\t\t\tmemoryUsage += ((sizeof(struct Block) + size));\n\t\t}\n\t}\n\n\treturn (newBlock + 1);\n}", "parent": null, "children": [309, 310], "start_point": {"row": 88, "column": 0}, "end_point": {"row": 245, "column": 1}}, {"id": 309, "type": "primitive_type", "text": "void", "parent": 308, "children": [], "start_point": {"row": 88, "column": 0}, "end_point": {"row": 88, "column": 4}}, {"id": 310, "type": "pointer_declarator", "text": "* myMalloc(unsigned int size)", "parent": 308, "children": [311, 312], "start_point": {"row": 88, "column": 4}, "end_point": {"row": 88, "column": 33}}, {"id": 311, "type": "*", "text": "*", "parent": 310, "children": [], "start_point": {"row": 88, "column": 4}, "end_point": {"row": 88, "column": 5}}, {"id": 312, "type": "function_declarator", "text": "myMalloc(unsigned int size)", "parent": 310, "children": [313, 314], "start_point": {"row": 88, "column": 6}, "end_point": {"row": 88, "column": 33}}, {"id": 313, "type": "identifier", "text": "myMalloc", "parent": 312, "children": [], "start_point": {"row": 88, "column": 6}, "end_point": {"row": 88, "column": 14}}, {"id": 314, "type": "parameter_list", "text": "(unsigned int size)", "parent": 312, "children": [315], "start_point": {"row": 88, "column": 14}, "end_point": {"row": 88, "column": 33}}, {"id": 315, "type": "parameter_declaration", "text": "unsigned int size", "parent": 314, "children": [316, 319], "start_point": {"row": 88, "column": 15}, "end_point": {"row": 88, "column": 32}}, {"id": 316, "type": "sized_type_specifier", "text": "unsigned int", "parent": 315, "children": [317, 318], "start_point": {"row": 88, "column": 15}, "end_point": {"row": 88, "column": 27}}, {"id": 317, "type": "unsigned", "text": "unsigned", "parent": 316, "children": [], "start_point": {"row": 88, "column": 15}, "end_point": {"row": 88, "column": 23}}, {"id": 318, "type": "primitive_type", "text": "int", "parent": 316, "children": [], "start_point": {"row": 88, "column": 24}, "end_point": {"row": 88, "column": 27}}, {"id": 319, "type": "identifier", "text": "size", "parent": 315, "children": [], "start_point": {"row": 88, "column": 28}, "end_point": {"row": 88, "column": 32}}, {"id": 320, "type": "declaration", "text": "Block newBlock;", "parent": 308, "children": [321, 322], "start_point": {"row": 90, "column": 1}, "end_point": {"row": 90, "column": 16}}, {"id": 321, "type": "type_identifier", "text": "Block", "parent": 320, "children": [], "start_point": {"row": 90, "column": 1}, "end_point": {"row": 90, "column": 6}}, {"id": 322, "type": "identifier", "text": "newBlock", "parent": 320, "children": [], "start_point": {"row": 90, "column": 7}, "end_point": {"row": 90, "column": 15}}, {"id": 323, "type": "declaration", "text": "Block scroll;", "parent": 308, "children": [324, 325], "start_point": {"row": 91, "column": 1}, "end_point": {"row": 91, "column": 14}}, {"id": 324, "type": "type_identifier", "text": "Block", "parent": 323, "children": [], "start_point": {"row": 91, "column": 1}, "end_point": {"row": 91, "column": 6}}, {"id": 325, "type": "identifier", "text": "scroll", "parent": 323, "children": [], "start_point": {"row": 91, "column": 7}, "end_point": {"row": 91, "column": 13}}, {"id": 326, "type": "declaration", "text": "Block previousScroll;", "parent": 308, "children": [327, 328], "start_point": {"row": 92, "column": 1}, "end_point": {"row": 92, "column": 22}}, {"id": 327, "type": "type_identifier", "text": "Block", "parent": 326, "children": [], "start_point": {"row": 92, "column": 1}, "end_point": {"row": 92, "column": 6}}, {"id": 328, "type": "identifier", "text": "previousScroll", "parent": 326, "children": [], "start_point": {"row": 92, "column": 7}, "end_point": {"row": 92, "column": 21}}, {"id": 329, "type": "declaration", "text": "Block enjoyBlock;", "parent": 308, "children": [330, 331], "start_point": {"row": 93, "column": 1}, "end_point": {"row": 93, "column": 18}}, {"id": 330, "type": "type_identifier", "text": "Block", "parent": 329, "children": [], "start_point": {"row": 93, "column": 1}, "end_point": {"row": 93, "column": 6}}, {"id": 331, "type": "identifier", "text": "enjoyBlock", "parent": 329, "children": [], "start_point": {"row": 93, "column": 7}, "end_point": {"row": 93, "column": 17}}, {"id": 332, "type": "declaration", "text": "Block tempBlock;", "parent": 308, "children": [333, 334], "start_point": {"row": 94, "column": 1}, "end_point": {"row": 94, "column": 17}}, {"id": 333, "type": "type_identifier", "text": "Block", "parent": 332, "children": [], "start_point": {"row": 94, "column": 1}, "end_point": {"row": 94, "column": 6}}, {"id": 334, "type": "identifier", "text": "tempBlock", "parent": 332, "children": [], "start_point": {"row": 94, "column": 7}, "end_point": {"row": 94, "column": 16}}, {"id": 335, "type": "declaration", "text": "Block* headerList;", "parent": 308, "children": [336, 337], "start_point": {"row": 95, "column": 1}, "end_point": {"row": 95, "column": 19}}, {"id": 336, "type": "type_identifier", "text": "Block", "parent": 335, "children": [], "start_point": {"row": 95, "column": 1}, "end_point": {"row": 95, "column": 6}}, {"id": 337, "type": "pointer_declarator", "text": "* headerList", "parent": 335, "children": [338, 339], "start_point": {"row": 95, "column": 6}, "end_point": {"row": 95, "column": 18}}, {"id": 338, "type": "*", "text": "*", "parent": 337, "children": [], "start_point": {"row": 95, "column": 6}, "end_point": {"row": 95, "column": 7}}, {"id": 339, "type": "identifier", "text": "headerList", "parent": 337, "children": [], "start_point": {"row": 95, "column": 8}, "end_point": {"row": 95, "column": 18}}, {"id": 340, "type": "declaration", "text": "int spaceFree = 0;", "parent": 308, "children": [341, 342], "start_point": {"row": 96, "column": 1}, "end_point": {"row": 96, "column": 19}}, {"id": 341, "type": "primitive_type", "text": "int", "parent": 340, "children": [], "start_point": {"row": 96, "column": 1}, "end_point": {"row": 96, "column": 4}}, {"id": 342, "type": "init_declarator", "text": "spaceFree = 0", "parent": 340, "children": [343, 344, 345], "start_point": {"row": 96, "column": 5}, "end_point": {"row": 96, "column": 18}}, {"id": 343, "type": "identifier", "text": "spaceFree", "parent": 342, "children": [], "start_point": {"row": 96, "column": 5}, "end_point": {"row": 96, "column": 14}}, {"id": 344, "type": "=", "text": "=", "parent": 342, "children": [], "start_point": {"row": 96, "column": 15}, "end_point": {"row": 96, "column": 16}}, {"id": 345, "type": "number_literal", "text": "0", "parent": 342, "children": [], "start_point": {"row": 96, "column": 17}, "end_point": {"row": 96, "column": 18}}, {"id": 346, "type": "declaration", "text": "int spaceEvaluation = 0;", "parent": 308, "children": [347, 348], "start_point": {"row": 97, "column": 1}, "end_point": {"row": 97, "column": 25}}, {"id": 347, "type": "primitive_type", "text": "int", "parent": 346, "children": [], "start_point": {"row": 97, "column": 1}, "end_point": {"row": 97, "column": 4}}, {"id": 348, "type": "init_declarator", "text": "spaceEvaluation = 0", "parent": 346, "children": [349, 350, 351], "start_point": {"row": 97, "column": 5}, "end_point": {"row": 97, "column": 24}}, {"id": 349, "type": "identifier", "text": "spaceEvaluation", "parent": 348, "children": [], "start_point": {"row": 97, "column": 5}, "end_point": {"row": 97, "column": 20}}, {"id": 350, "type": "=", "text": "=", "parent": 348, "children": [], "start_point": {"row": 97, "column": 21}, "end_point": {"row": 97, "column": 22}}, {"id": 351, "type": "number_literal", "text": "0", "parent": 348, "children": [], "start_point": {"row": 97, "column": 23}, "end_point": {"row": 97, "column": 24}}, {"id": 352, "type": "assignment_expression", "text": "size = ALIGN4(size)", "parent": 308, "children": [353, 354, 355], "start_point": {"row": 99, "column": 1}, "end_point": {"row": 99, "column": 20}}, {"id": 353, "type": "identifier", "text": "size", "parent": 352, "children": [], "start_point": {"row": 99, "column": 1}, "end_point": {"row": 99, "column": 5}}, {"id": 354, "type": "=", "text": "=", "parent": 352, "children": [], "start_point": {"row": 99, "column": 6}, "end_point": {"row": 99, "column": 7}}, {"id": 355, "type": "call_expression", "text": "ALIGN4(size)", "parent": 352, "children": [356, 357], "start_point": {"row": 99, "column": 8}, "end_point": {"row": 99, "column": 20}}, {"id": 356, "type": "identifier", "text": "ALIGN4", "parent": 355, "children": [], "start_point": {"row": 99, "column": 8}, "end_point": {"row": 99, "column": 14}}, {"id": 357, "type": "argument_list", "text": "(size)", "parent": 355, "children": [358], "start_point": {"row": 99, "column": 14}, "end_point": {"row": 99, "column": 20}}, {"id": 358, "type": "identifier", "text": "size", "parent": 357, "children": [], "start_point": {"row": 99, "column": 15}, "end_point": {"row": 99, "column": 19}}, {"id": 359, "type": "if_statement", "text": "if((Gerency.CurrentPointerHeap) - (Gerency.baseHeap) == HEAP_SIZE)\n\t\treturn NULL;", "parent": 308, "children": [360, 374], "start_point": {"row": 101, "column": 1}, "end_point": {"row": 102, "column": 14}}, {"id": 360, "type": "parenthesized_expression", "text": "((Gerency.CurrentPointerHeap) - (Gerency.baseHeap) == HEAP_SIZE)", "parent": 359, "children": [361], "start_point": {"row": 101, "column": 3}, "end_point": {"row": 101, "column": 67}}, {"id": 361, "type": "binary_expression", "text": "(Gerency.CurrentPointerHeap) - (Gerency.baseHeap) == HEAP_SIZE", "parent": 360, "children": [362, 372, 373], "start_point": {"row": 101, "column": 4}, "end_point": {"row": 101, "column": 66}}, {"id": 362, "type": "binary_expression", "text": "(Gerency.CurrentPointerHeap) - (Gerency.baseHeap)", "parent": 361, "children": [363, 367, 368], "start_point": {"row": 101, "column": 4}, "end_point": {"row": 101, "column": 53}}, {"id": 363, "type": "parenthesized_expression", "text": "(Gerency.CurrentPointerHeap)", "parent": 362, "children": [364], "start_point": {"row": 101, "column": 4}, "end_point": {"row": 101, "column": 32}}, {"id": 364, "type": "field_expression", "text": "Gerency.CurrentPointerHeap", "parent": 363, "children": [365, 366], "start_point": {"row": 101, "column": 5}, "end_point": {"row": 101, "column": 31}}, {"id": 365, "type": "identifier", "text": "Gerency", "parent": 364, "children": [], "start_point": {"row": 101, "column": 5}, "end_point": {"row": 101, "column": 12}}, {"id": 366, "type": "field_identifier", "text": "CurrentPointerHeap", "parent": 364, "children": [], "start_point": {"row": 101, "column": 13}, "end_point": {"row": 101, "column": 31}}, {"id": 367, "type": "-", "text": "-", "parent": 362, "children": [], "start_point": {"row": 101, "column": 33}, "end_point": {"row": 101, "column": 34}}, {"id": 368, "type": "parenthesized_expression", "text": "(Gerency.baseHeap)", "parent": 362, "children": [369], "start_point": {"row": 101, "column": 35}, "end_point": {"row": 101, "column": 53}}, {"id": 369, "type": "field_expression", "text": "Gerency.baseHeap", "parent": 368, "children": [370, 371], "start_point": {"row": 101, "column": 36}, "end_point": {"row": 101, "column": 52}}, {"id": 370, "type": "identifier", "text": "Gerency", "parent": 369, "children": [], "start_point": {"row": 101, "column": 36}, "end_point": {"row": 101, "column": 43}}, {"id": 371, "type": "field_identifier", "text": "baseHeap", "parent": 369, "children": [], "start_point": {"row": 101, "column": 44}, "end_point": {"row": 101, "column": 52}}, {"id": 372, "type": "==", "text": "==", "parent": 361, "children": [], "start_point": {"row": 101, "column": 54}, "end_point": {"row": 101, "column": 56}}, {"id": 373, "type": "identifier", "text": "HEAP_SIZE", "parent": 361, "children": [], "start_point": {"row": 101, "column": 57}, "end_point": {"row": 101, "column": 66}}, {"id": 374, "type": "return_statement", "text": "return NULL;", "parent": 359, "children": [375], "start_point": {"row": 102, "column": 2}, "end_point": {"row": 102, "column": 14}}, {"id": 375, "type": "null", "text": "NULL", "parent": 374, "children": [376], "start_point": {"row": 102, "column": 9}, "end_point": {"row": 102, "column": 13}}, {"id": 376, "type": "NULL", "text": "NULL", "parent": 375, "children": [], "start_point": {"row": 102, "column": 9}, "end_point": {"row": 102, "column": 13}}, {"id": 377, "type": "if_statement", "text": "if(((Gerency.CurrentPointerHeap) + size) >= (void*)HEAP_SIZE)\n\t{\n\t\treturn NULL;\n\t}", "parent": 308, "children": [378], "start_point": {"row": 104, "column": 1}, "end_point": {"row": 107, "column": 2}}, {"id": 378, "type": "parenthesized_expression", "text": "(((Gerency.CurrentPointerHeap) + size) >= (void*)HEAP_SIZE)", "parent": 377, "children": [379], "start_point": {"row": 104, "column": 3}, "end_point": {"row": 104, "column": 62}}, {"id": 379, "type": "binary_expression", "text": "((Gerency.CurrentPointerHeap) + size) >= (void*)HEAP_SIZE", "parent": 378, "children": [380, 388, 389], "start_point": {"row": 104, "column": 4}, "end_point": {"row": 104, "column": 61}}, {"id": 380, "type": "parenthesized_expression", "text": "((Gerency.CurrentPointerHeap) + size)", "parent": 379, "children": [381], "start_point": {"row": 104, "column": 4}, "end_point": {"row": 104, "column": 41}}, {"id": 381, "type": "binary_expression", "text": "(Gerency.CurrentPointerHeap) + size", "parent": 380, "children": [382, 386, 387], "start_point": {"row": 104, "column": 5}, "end_point": {"row": 104, "column": 40}}, {"id": 382, "type": "parenthesized_expression", "text": "(Gerency.CurrentPointerHeap)", "parent": 381, "children": [383], "start_point": {"row": 104, "column": 5}, "end_point": {"row": 104, "column": 33}}, {"id": 383, "type": "field_expression", "text": "Gerency.CurrentPointerHeap", "parent": 382, "children": [384, 385], "start_point": {"row": 104, "column": 6}, "end_point": {"row": 104, "column": 32}}, {"id": 384, "type": "identifier", "text": "Gerency", "parent": 383, "children": [], "start_point": {"row": 104, "column": 6}, "end_point": {"row": 104, "column": 13}}, {"id": 385, "type": "field_identifier", "text": "CurrentPointerHeap", "parent": 383, "children": [], "start_point": {"row": 104, "column": 14}, "end_point": {"row": 104, "column": 32}}, {"id": 386, "type": "+", "text": "+", "parent": 381, "children": [], "start_point": {"row": 104, "column": 34}, "end_point": {"row": 104, "column": 35}}, {"id": 387, "type": "identifier", "text": "size", "parent": 381, "children": [], "start_point": {"row": 104, "column": 36}, "end_point": {"row": 104, "column": 40}}, {"id": 388, "type": ">=", "text": ">=", "parent": 379, "children": [], "start_point": {"row": 104, "column": 42}, "end_point": {"row": 104, "column": 44}}, {"id": 389, "type": "cast_expression", "text": "(void*)HEAP_SIZE", "parent": 379, "children": [390, 394], "start_point": {"row": 104, "column": 45}, "end_point": {"row": 104, "column": 61}}, {"id": 390, "type": "type_descriptor", "text": "void*", "parent": 389, "children": [391, 392], "start_point": {"row": 104, "column": 46}, "end_point": {"row": 104, "column": 51}}, {"id": 391, "type": "primitive_type", "text": "void", "parent": 390, "children": [], "start_point": {"row": 104, "column": 46}, "end_point": {"row": 104, "column": 50}}, {"id": 392, "type": "abstract_pointer_declarator", "text": "*", "parent": 390, "children": [393], "start_point": {"row": 104, "column": 50}, "end_point": {"row": 104, "column": 51}}, {"id": 393, "type": "*", "text": "*", "parent": 392, "children": [], "start_point": {"row": 104, "column": 50}, "end_point": {"row": 104, "column": 51}}, {"id": 394, "type": "identifier", "text": "HEAP_SIZE", "parent": 389, "children": [], "start_point": {"row": 104, "column": 52}, "end_point": {"row": 104, "column": 61}}, {"id": 395, "type": "return_statement", "text": "return NULL;", "parent": 377, "children": [396], "start_point": {"row": 106, "column": 2}, "end_point": {"row": 106, "column": 14}}, {"id": 396, "type": "null", "text": "NULL", "parent": 395, "children": [397], "start_point": {"row": 106, "column": 9}, "end_point": {"row": 106, "column": 13}}, {"id": 397, "type": "NULL", "text": "NULL", "parent": 396, "children": [], "start_point": {"row": 106, "column": 9}, "end_point": {"row": 106, "column": 13}}, {"id": 398, "type": "if_statement", "text": "if((*(Gerency.ListBlocks)) == NULL)\n\t{\n\t\tnewBlock = Gerency.CurrentPointerHeap;\n\t\tnewBlock->next = NULL;\n\t\tnewBlock->Info.Field.free = 0;\n\t\tnewBlock->Info.Field.size = size;\n\t\tnewBlock->id = numberBlocks;\n\t\t*(Gerency.ListBlocks) = newBlock;\n\t\t\n\t\tnumberBlocks += 1;\n\n\t\tGerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n\t\tmemoryUsage += ((sizeof(struct Block) + size));\n\t} \n\telse\n\t{\n\t\tif((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))\n\t\t{\n\t\t\tenjoyBlock = Gerency.LastBlockReleased;\n\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\tGerency.LastBlockReleased = NULL;\n\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\tnumberFreeBlocks -= 1;\n\t\t\treturn (enjoyBlock + 1);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tswitch(AAlgorithm)\n\t\t\t{\n\t\t\t\tcase FIRST_FIT:\n\t\t\t\ttry_first_fit:\n\n\n\t\t\t\t\tforeach(enjoyBlock,(Gerency.ListBlocks))\n\t\t\t\t\t{\n\t\t\t\t\t\tif((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\t\t\t\t\tnumberFreeBlocks -= 1;\n\t\t\t\t\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\t\t\t\t\treturn (enjoyBlock + 1);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tcase BEST_FIT:\n\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, Gerency.ListBlocks)\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(spaceFree < 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\telse if(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\tnumberFragmentation += BlockSize(tempBlock) - size;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\n\t\t\t\tcase WORST_FIT:\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, (Gerency.ListBlocks))\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tdefault:\n\t\t\t\t\tgoto try_first_fit;\n\n\t\t\t}\n\n\t\t\tscroll = *(Gerency.ListBlocks);\n\n\t\t\twhile((scroll != NULL) && (BlockSize(scroll) < size))\n\t\t\t{\n\t\t\t\tpreviousScroll = scroll;\n\t\t\t\tscroll = scroll->next;\n\t\t\t}\n\n\t\t\tnewBlock = Gerency.CurrentPointerHeap;\n\t\t\tnewBlock->Info.Field.free = 0;\n\t\t\tnewBlock->Info.Field.size = size;\n\t\t\tnewBlock->id = numberBlocks;\n\t\t\tnumberBlocks += 1;\n\n\t\t\tif(scroll == *(Gerency.ListBlocks) )\n\t\t\t{\n\t\t\t\tnewBlock->next = *(Gerency.ListBlocks);\n\t\t\t\t*(Gerency.ListBlocks) = newBlock;\n\t\t\t}\n\t\t\t\n\t\t\telse\n\t\t\t{\n\t\t\t\tnewBlock->next = previousScroll->next;\n\t\t\t\tpreviousScroll->next = newBlock;\n\t\t\t}\n\n\t\t\tGerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n\t\t\tmemoryUsage += ((sizeof(struct Block) + size));\n\t\t}\n\t}", "parent": 308, "children": [399, 491], "start_point": {"row": 109, "column": 1}, "end_point": {"row": 242, "column": 2}}, {"id": 399, "type": "parenthesized_expression", "text": "((*(Gerency.ListBlocks)) == NULL)", "parent": 398, "children": [400], "start_point": {"row": 109, "column": 3}, "end_point": {"row": 109, "column": 36}}, {"id": 400, "type": "binary_expression", "text": "(*(Gerency.ListBlocks)) == NULL", "parent": 399, "children": [401, 408, 409], "start_point": {"row": 109, "column": 4}, "end_point": {"row": 109, "column": 35}}, {"id": 401, "type": "parenthesized_expression", "text": "(*(Gerency.ListBlocks))", "parent": 400, "children": [402], "start_point": {"row": 109, "column": 4}, "end_point": {"row": 109, "column": 27}}, {"id": 402, "type": "pointer_expression", "text": "*(Gerency.ListBlocks)", "parent": 401, "children": [403, 404], "start_point": {"row": 109, "column": 5}, "end_point": {"row": 109, "column": 26}}, {"id": 403, "type": "*", "text": "*", "parent": 402, "children": [], "start_point": {"row": 109, "column": 5}, "end_point": {"row": 109, "column": 6}}, {"id": 404, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 402, "children": [405], "start_point": {"row": 109, "column": 6}, "end_point": {"row": 109, "column": 26}}, {"id": 405, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 404, "children": [406, 407], "start_point": {"row": 109, "column": 7}, "end_point": {"row": 109, "column": 25}}, {"id": 406, "type": "identifier", "text": "Gerency", "parent": 405, "children": [], "start_point": {"row": 109, "column": 7}, "end_point": {"row": 109, "column": 14}}, {"id": 407, "type": "field_identifier", "text": "ListBlocks", "parent": 405, "children": [], "start_point": {"row": 109, "column": 15}, "end_point": {"row": 109, "column": 25}}, {"id": 408, "type": "==", "text": "==", "parent": 400, "children": [], "start_point": {"row": 109, "column": 28}, "end_point": {"row": 109, "column": 30}}, {"id": 409, "type": "null", "text": "NULL", "parent": 400, "children": [410], "start_point": {"row": 109, "column": 31}, "end_point": {"row": 109, "column": 35}}, {"id": 410, "type": "NULL", "text": "NULL", "parent": 409, "children": [], "start_point": {"row": 109, "column": 31}, "end_point": {"row": 109, "column": 35}}, {"id": 411, "type": "assignment_expression", "text": "newBlock = Gerency.CurrentPointerHeap", "parent": 398, "children": [412, 413, 414], "start_point": {"row": 111, "column": 2}, "end_point": {"row": 111, "column": 39}}, {"id": 412, "type": "identifier", "text": "newBlock", "parent": 411, "children": [], "start_point": {"row": 111, "column": 2}, "end_point": {"row": 111, "column": 10}}, {"id": 413, "type": "=", "text": "=", "parent": 411, "children": [], "start_point": {"row": 111, "column": 11}, "end_point": {"row": 111, "column": 12}}, {"id": 414, "type": "field_expression", "text": "Gerency.CurrentPointerHeap", "parent": 411, "children": [415, 416], "start_point": {"row": 111, "column": 13}, "end_point": {"row": 111, "column": 39}}, {"id": 415, "type": "identifier", "text": "Gerency", "parent": 414, "children": [], "start_point": {"row": 111, "column": 13}, "end_point": {"row": 111, "column": 20}}, {"id": 416, "type": "field_identifier", "text": "CurrentPointerHeap", "parent": 414, "children": [], "start_point": {"row": 111, "column": 21}, "end_point": {"row": 111, "column": 39}}, {"id": 417, "type": "assignment_expression", "text": "newBlock->next = NULL", "parent": 398, "children": [418, 421, 422], "start_point": {"row": 112, "column": 2}, "end_point": {"row": 112, "column": 23}}, {"id": 418, "type": "field_expression", "text": "newBlock->next", "parent": 417, "children": [419, 420], "start_point": {"row": 112, "column": 2}, "end_point": {"row": 112, "column": 16}}, {"id": 419, "type": "identifier", "text": "newBlock", "parent": 418, "children": [], "start_point": {"row": 112, "column": 2}, "end_point": {"row": 112, "column": 10}}, {"id": 420, "type": "field_identifier", "text": "next", "parent": 418, "children": [], "start_point": {"row": 112, "column": 12}, "end_point": {"row": 112, "column": 16}}, {"id": 421, "type": "=", "text": "=", "parent": 417, "children": [], "start_point": {"row": 112, "column": 17}, "end_point": {"row": 112, "column": 18}}, {"id": 422, "type": "null", "text": "NULL", "parent": 417, "children": [423], "start_point": {"row": 112, "column": 19}, "end_point": {"row": 112, "column": 23}}, {"id": 423, "type": "NULL", "text": "NULL", "parent": 422, "children": [], "start_point": {"row": 112, "column": 19}, "end_point": {"row": 112, "column": 23}}, {"id": 424, "type": "assignment_expression", "text": "newBlock->Info.Field.free = 0", "parent": 398, "children": [425, 432, 433], "start_point": {"row": 113, "column": 2}, "end_point": {"row": 113, "column": 31}}, {"id": 425, "type": "field_expression", "text": "newBlock->Info.Field.free", "parent": 424, "children": [426, 431], "start_point": {"row": 113, "column": 2}, "end_point": {"row": 113, "column": 27}}, {"id": 426, "type": "field_expression", "text": "newBlock->Info.Field", "parent": 425, "children": [427, 430], "start_point": {"row": 113, "column": 2}, "end_point": {"row": 113, "column": 22}}, {"id": 427, "type": "field_expression", "text": "newBlock->Info", "parent": 426, "children": [428, 429], "start_point": {"row": 113, "column": 2}, "end_point": {"row": 113, "column": 16}}, {"id": 428, "type": "identifier", "text": "newBlock", "parent": 427, "children": [], "start_point": {"row": 113, "column": 2}, "end_point": {"row": 113, "column": 10}}, {"id": 429, "type": "field_identifier", "text": "Info", "parent": 427, "children": [], "start_point": {"row": 113, "column": 12}, "end_point": {"row": 113, "column": 16}}, {"id": 430, "type": "field_identifier", "text": "Field", "parent": 426, "children": [], "start_point": {"row": 113, "column": 17}, "end_point": {"row": 113, "column": 22}}, {"id": 431, "type": "field_identifier", "text": "free", "parent": 425, "children": [], "start_point": {"row": 113, "column": 23}, "end_point": {"row": 113, "column": 27}}, {"id": 432, "type": "=", "text": "=", "parent": 424, "children": [], "start_point": {"row": 113, "column": 28}, "end_point": {"row": 113, "column": 29}}, {"id": 433, "type": "number_literal", "text": "0", "parent": 424, "children": [], "start_point": {"row": 113, "column": 30}, "end_point": {"row": 113, "column": 31}}, {"id": 434, "type": "assignment_expression", "text": "newBlock->Info.Field.size = size", "parent": 398, "children": [435, 442, 443], "start_point": {"row": 114, "column": 2}, "end_point": {"row": 114, "column": 34}}, {"id": 435, "type": "field_expression", "text": "newBlock->Info.Field.size", "parent": 434, "children": [436, 441], "start_point": {"row": 114, "column": 2}, "end_point": {"row": 114, "column": 27}}, {"id": 436, "type": "field_expression", "text": "newBlock->Info.Field", "parent": 435, "children": [437, 440], "start_point": {"row": 114, "column": 2}, "end_point": {"row": 114, "column": 22}}, {"id": 437, "type": "field_expression", "text": "newBlock->Info", "parent": 436, "children": [438, 439], "start_point": {"row": 114, "column": 2}, "end_point": {"row": 114, "column": 16}}, {"id": 438, "type": "identifier", "text": "newBlock", "parent": 437, "children": [], "start_point": {"row": 114, "column": 2}, "end_point": {"row": 114, "column": 10}}, {"id": 439, "type": "field_identifier", "text": "Info", "parent": 437, "children": [], "start_point": {"row": 114, "column": 12}, "end_point": {"row": 114, "column": 16}}, {"id": 440, "type": "field_identifier", "text": "Field", "parent": 436, "children": [], "start_point": {"row": 114, "column": 17}, "end_point": {"row": 114, "column": 22}}, {"id": 441, "type": "field_identifier", "text": "size", "parent": 435, "children": [], "start_point": {"row": 114, "column": 23}, "end_point": {"row": 114, "column": 27}}, {"id": 442, "type": "=", "text": "=", "parent": 434, "children": [], "start_point": {"row": 114, "column": 28}, "end_point": {"row": 114, "column": 29}}, {"id": 443, "type": "identifier", "text": "size", "parent": 434, "children": [], "start_point": {"row": 114, "column": 30}, "end_point": {"row": 114, "column": 34}}, {"id": 444, "type": "assignment_expression", "text": "newBlock->id = numberBlocks", "parent": 398, "children": [445, 448, 449], "start_point": {"row": 115, "column": 2}, "end_point": {"row": 115, "column": 29}}, {"id": 445, "type": "field_expression", "text": "newBlock->id", "parent": 444, "children": [446, 447], "start_point": {"row": 115, "column": 2}, "end_point": {"row": 115, "column": 14}}, {"id": 446, "type": "identifier", "text": "newBlock", "parent": 445, "children": [], "start_point": {"row": 115, "column": 2}, "end_point": {"row": 115, "column": 10}}, {"id": 447, "type": "field_identifier", "text": "id", "parent": 445, "children": [], "start_point": {"row": 115, "column": 12}, "end_point": {"row": 115, "column": 14}}, {"id": 448, "type": "=", "text": "=", "parent": 444, "children": [], "start_point": {"row": 115, "column": 15}, "end_point": {"row": 115, "column": 16}}, {"id": 449, "type": "identifier", "text": "numberBlocks", "parent": 444, "children": [], "start_point": {"row": 115, "column": 17}, "end_point": {"row": 115, "column": 29}}, {"id": 450, "type": "assignment_expression", "text": "*(Gerency.ListBlocks) = newBlock", "parent": 398, "children": [451, 457, 458], "start_point": {"row": 116, "column": 2}, "end_point": {"row": 116, "column": 34}}, {"id": 451, "type": "pointer_expression", "text": "*(Gerency.ListBlocks)", "parent": 450, "children": [452, 453], "start_point": {"row": 116, "column": 2}, "end_point": {"row": 116, "column": 23}}, {"id": 452, "type": "*", "text": "*", "parent": 451, "children": [], "start_point": {"row": 116, "column": 2}, "end_point": {"row": 116, "column": 3}}, {"id": 453, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 451, "children": [454], "start_point": {"row": 116, "column": 3}, "end_point": {"row": 116, "column": 23}}, {"id": 454, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 453, "children": [455, 456], "start_point": {"row": 116, "column": 4}, "end_point": {"row": 116, "column": 22}}, {"id": 455, "type": "identifier", "text": "Gerency", "parent": 454, "children": [], "start_point": {"row": 116, "column": 4}, "end_point": {"row": 116, "column": 11}}, {"id": 456, "type": "field_identifier", "text": "ListBlocks", "parent": 454, "children": [], "start_point": {"row": 116, "column": 12}, "end_point": {"row": 116, "column": 22}}, {"id": 457, "type": "=", "text": "=", "parent": 450, "children": [], "start_point": {"row": 116, "column": 24}, "end_point": {"row": 116, "column": 25}}, {"id": 458, "type": "identifier", "text": "newBlock", "parent": 450, "children": [], "start_point": {"row": 116, "column": 26}, "end_point": {"row": 116, "column": 34}}, {"id": 459, "type": "assignment_expression", "text": "numberBlocks += 1", "parent": 398, "children": [460, 461, 462], "start_point": {"row": 118, "column": 2}, "end_point": {"row": 118, "column": 19}}, {"id": 460, "type": "identifier", "text": "numberBlocks", "parent": 459, "children": [], "start_point": {"row": 118, "column": 2}, "end_point": {"row": 118, "column": 14}}, {"id": 461, "type": "+=", "text": "+=", "parent": 459, "children": [], "start_point": {"row": 118, "column": 15}, "end_point": {"row": 118, "column": 17}}, {"id": 462, "type": "number_literal", "text": "1", "parent": 459, "children": [], "start_point": {"row": 118, "column": 18}, "end_point": {"row": 118, "column": 19}}, {"id": 463, "type": "assignment_expression", "text": "Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size))", "parent": 398, "children": [464, 467, 468], "start_point": {"row": 120, "column": 2}, "end_point": {"row": 120, "column": 63}}, {"id": 464, "type": "field_expression", "text": "Gerency.CurrentPointerHeap", "parent": 463, "children": [465, 466], "start_point": {"row": 120, "column": 2}, "end_point": {"row": 120, "column": 28}}, {"id": 465, "type": "identifier", "text": "Gerency", "parent": 464, "children": [], "start_point": {"row": 120, "column": 2}, "end_point": {"row": 120, "column": 9}}, {"id": 466, "type": "field_identifier", "text": "CurrentPointerHeap", "parent": 464, "children": [], "start_point": {"row": 120, "column": 10}, "end_point": {"row": 120, "column": 28}}, {"id": 467, "type": "+=", "text": "+=", "parent": 463, "children": [], "start_point": {"row": 120, "column": 29}, "end_point": {"row": 120, "column": 31}}, {"id": 468, "type": "parenthesized_expression", "text": "((sizeof(struct Block) + size))", "parent": 463, "children": [469], "start_point": {"row": 120, "column": 32}, "end_point": {"row": 120, "column": 63}}, {"id": 469, "type": "parenthesized_expression", "text": "(sizeof(struct Block) + size)", "parent": 468, "children": [470], "start_point": {"row": 120, "column": 33}, "end_point": {"row": 120, "column": 62}}, {"id": 470, "type": "binary_expression", "text": "sizeof(struct Block) + size", "parent": 469, "children": [471, 476, 477], "start_point": {"row": 120, "column": 34}, "end_point": {"row": 120, "column": 61}}, {"id": 471, "type": "sizeof_expression", "text": "sizeof(struct Block)", "parent": 470, "children": [472], "start_point": {"row": 120, "column": 34}, "end_point": {"row": 120, "column": 54}}, {"id": 472, "type": "type_descriptor", "text": "struct Block", "parent": 471, "children": [473], "start_point": {"row": 120, "column": 41}, "end_point": {"row": 120, "column": 53}}, {"id": 473, "type": "struct_specifier", "text": "struct Block", "parent": 472, "children": [474, 475], "start_point": {"row": 120, "column": 41}, "end_point": {"row": 120, "column": 53}}, {"id": 474, "type": "struct", "text": "struct", "parent": 473, "children": [], "start_point": {"row": 120, "column": 41}, "end_point": {"row": 120, "column": 47}}, {"id": 475, "type": "type_identifier", "text": "Block", "parent": 473, "children": [], "start_point": {"row": 120, "column": 48}, "end_point": {"row": 120, "column": 53}}, {"id": 476, "type": "+", "text": "+", "parent": 470, "children": [], "start_point": {"row": 120, "column": 55}, "end_point": {"row": 120, "column": 56}}, {"id": 477, "type": "identifier", "text": "size", "parent": 470, "children": [], "start_point": {"row": 120, "column": 57}, "end_point": {"row": 120, "column": 61}}, {"id": 478, "type": "assignment_expression", "text": "memoryUsage += ((sizeof(struct Block) + size))", "parent": 398, "children": [479, 480, 481], "start_point": {"row": 121, "column": 2}, "end_point": {"row": 121, "column": 48}}, {"id": 479, "type": "identifier", "text": "memoryUsage", "parent": 478, "children": [], "start_point": {"row": 121, "column": 2}, "end_point": {"row": 121, "column": 13}}, {"id": 480, "type": "+=", "text": "+=", "parent": 478, "children": [], "start_point": {"row": 121, "column": 14}, "end_point": {"row": 121, "column": 16}}, {"id": 481, "type": "parenthesized_expression", "text": "((sizeof(struct Block) + size))", "parent": 478, "children": [482], "start_point": {"row": 121, "column": 17}, "end_point": {"row": 121, "column": 48}}, {"id": 482, "type": "parenthesized_expression", "text": "(sizeof(struct Block) + size)", "parent": 481, "children": [483], "start_point": {"row": 121, "column": 18}, "end_point": {"row": 121, "column": 47}}, {"id": 483, "type": "binary_expression", "text": "sizeof(struct Block) + size", "parent": 482, "children": [484, 489, 490], "start_point": {"row": 121, "column": 19}, "end_point": {"row": 121, "column": 46}}, {"id": 484, "type": "sizeof_expression", "text": "sizeof(struct Block)", "parent": 483, "children": [485], "start_point": {"row": 121, "column": 19}, "end_point": {"row": 121, "column": 39}}, {"id": 485, "type": "type_descriptor", "text": "struct Block", "parent": 484, "children": [486], "start_point": {"row": 121, "column": 26}, "end_point": {"row": 121, "column": 38}}, {"id": 486, "type": "struct_specifier", "text": "struct Block", "parent": 485, "children": [487, 488], "start_point": {"row": 121, "column": 26}, "end_point": {"row": 121, "column": 38}}, {"id": 487, "type": "struct", "text": "struct", "parent": 486, "children": [], "start_point": {"row": 121, "column": 26}, "end_point": {"row": 121, "column": 32}}, {"id": 488, "type": "type_identifier", "text": "Block", "parent": 486, "children": [], "start_point": {"row": 121, "column": 33}, "end_point": {"row": 121, "column": 38}}, {"id": 489, "type": "+", "text": "+", "parent": 483, "children": [], "start_point": {"row": 121, "column": 40}, "end_point": {"row": 121, "column": 41}}, {"id": 490, "type": "identifier", "text": "size", "parent": 483, "children": [], "start_point": {"row": 121, "column": 42}, "end_point": {"row": 121, "column": 46}}, {"id": 491, "type": "else_clause", "text": "else\n\t{\n\t\tif((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))\n\t\t{\n\t\t\tenjoyBlock = Gerency.LastBlockReleased;\n\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\tGerency.LastBlockReleased = NULL;\n\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\tnumberFreeBlocks -= 1;\n\t\t\treturn (enjoyBlock + 1);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tswitch(AAlgorithm)\n\t\t\t{\n\t\t\t\tcase FIRST_FIT:\n\t\t\t\ttry_first_fit:\n\n\n\t\t\t\t\tforeach(enjoyBlock,(Gerency.ListBlocks))\n\t\t\t\t\t{\n\t\t\t\t\t\tif((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\t\t\t\t\tnumberFreeBlocks -= 1;\n\t\t\t\t\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\t\t\t\t\treturn (enjoyBlock + 1);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tcase BEST_FIT:\n\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, Gerency.ListBlocks)\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(spaceFree < 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\telse if(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\tnumberFragmentation += BlockSize(tempBlock) - size;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\n\t\t\t\tcase WORST_FIT:\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, (Gerency.ListBlocks))\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tdefault:\n\t\t\t\t\tgoto try_first_fit;\n\n\t\t\t}\n\n\t\t\tscroll = *(Gerency.ListBlocks);\n\n\t\t\twhile((scroll != NULL) && (BlockSize(scroll) < size))\n\t\t\t{\n\t\t\t\tpreviousScroll = scroll;\n\t\t\t\tscroll = scroll->next;\n\t\t\t}\n\n\t\t\tnewBlock = Gerency.CurrentPointerHeap;\n\t\t\tnewBlock->Info.Field.free = 0;\n\t\t\tnewBlock->Info.Field.size = size;\n\t\t\tnewBlock->id = numberBlocks;\n\t\t\tnumberBlocks += 1;\n\n\t\t\tif(scroll == *(Gerency.ListBlocks) )\n\t\t\t{\n\t\t\t\tnewBlock->next = *(Gerency.ListBlocks);\n\t\t\t\t*(Gerency.ListBlocks) = newBlock;\n\t\t\t}\n\t\t\t\n\t\t\telse\n\t\t\t{\n\t\t\t\tnewBlock->next = previousScroll->next;\n\t\t\t\tpreviousScroll->next = newBlock;\n\t\t\t}\n\n\t\t\tGerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n\t\t\tmemoryUsage += ((sizeof(struct Block) + size));\n\t\t}\n\t}", "parent": 398, "children": [], "start_point": {"row": 123, "column": 1}, "end_point": {"row": 242, "column": 2}}, {"id": 492, "type": "if_statement", "text": "if((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))\n\t\t{\n\t\t\tenjoyBlock = Gerency.LastBlockReleased;\n\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\tGerency.LastBlockReleased = NULL;\n\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\tnumberFreeBlocks -= 1;\n\t\t\treturn (enjoyBlock + 1);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tswitch(AAlgorithm)\n\t\t\t{\n\t\t\t\tcase FIRST_FIT:\n\t\t\t\ttry_first_fit:\n\n\n\t\t\t\t\tforeach(enjoyBlock,(Gerency.ListBlocks))\n\t\t\t\t\t{\n\t\t\t\t\t\tif((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\t\t\t\t\tnumberFreeBlocks -= 1;\n\t\t\t\t\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\t\t\t\t\treturn (enjoyBlock + 1);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tcase BEST_FIT:\n\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, Gerency.ListBlocks)\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(spaceFree < 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\telse if(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\tnumberFragmentation += BlockSize(tempBlock) - size;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\n\t\t\t\tcase WORST_FIT:\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, (Gerency.ListBlocks))\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tdefault:\n\t\t\t\t\tgoto try_first_fit;\n\n\t\t\t}\n\n\t\t\tscroll = *(Gerency.ListBlocks);\n\n\t\t\twhile((scroll != NULL) && (BlockSize(scroll) < size))\n\t\t\t{\n\t\t\t\tpreviousScroll = scroll;\n\t\t\t\tscroll = scroll->next;\n\t\t\t}\n\n\t\t\tnewBlock = Gerency.CurrentPointerHeap;\n\t\t\tnewBlock->Info.Field.free = 0;\n\t\t\tnewBlock->Info.Field.size = size;\n\t\t\tnewBlock->id = numberBlocks;\n\t\t\tnumberBlocks += 1;\n\n\t\t\tif(scroll == *(Gerency.ListBlocks) )\n\t\t\t{\n\t\t\t\tnewBlock->next = *(Gerency.ListBlocks);\n\t\t\t\t*(Gerency.ListBlocks) = newBlock;\n\t\t\t}\n\t\t\t\n\t\t\telse\n\t\t\t{\n\t\t\t\tnewBlock->next = previousScroll->next;\n\t\t\t\tpreviousScroll->next = newBlock;\n\t\t\t}\n\n\t\t\tGerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n\t\t\tmemoryUsage += ((sizeof(struct Block) + size));\n\t\t}", "parent": 491, "children": [493, 562], "start_point": {"row": 125, "column": 2}, "end_point": {"row": 241, "column": 3}}, {"id": 493, "type": "parenthesized_expression", "text": "((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))", "parent": 492, "children": [494], "start_point": {"row": 125, "column": 4}, "end_point": {"row": 125, "column": 121}}, {"id": 494, "type": "binary_expression", "text": "(Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK)", "parent": 493, "children": [495, 503, 504], "start_point": {"row": 125, "column": 5}, "end_point": {"row": 125, "column": 120}}, {"id": 495, "type": "parenthesized_expression", "text": "(Gerency.LastBlockReleased != NULL)", "parent": 494, "children": [496], "start_point": {"row": 125, "column": 5}, "end_point": {"row": 125, "column": 40}}, {"id": 496, "type": "binary_expression", "text": "Gerency.LastBlockReleased != NULL", "parent": 495, "children": [497, 500, 501], "start_point": {"row": 125, "column": 6}, "end_point": {"row": 125, "column": 39}}, {"id": 497, "type": "field_expression", "text": "Gerency.LastBlockReleased", "parent": 496, "children": [498, 499], "start_point": {"row": 125, "column": 6}, "end_point": {"row": 125, "column": 31}}, {"id": 498, "type": "identifier", "text": "Gerency", "parent": 497, "children": [], "start_point": {"row": 125, "column": 6}, "end_point": {"row": 125, "column": 13}}, {"id": 499, "type": "field_identifier", "text": "LastBlockReleased", "parent": 497, "children": [], "start_point": {"row": 125, "column": 14}, "end_point": {"row": 125, "column": 31}}, {"id": 500, "type": "!=", "text": "!=", "parent": 496, "children": [], "start_point": {"row": 125, "column": 32}, "end_point": {"row": 125, "column": 34}}, {"id": 501, "type": "null", "text": "NULL", "parent": 496, "children": [502], "start_point": {"row": 125, "column": 35}, "end_point": {"row": 125, "column": 39}}, {"id": 502, "type": "NULL", "text": "NULL", "parent": 501, "children": [], "start_point": {"row": 125, "column": 35}, "end_point": {"row": 125, "column": 39}}, {"id": 503, "type": "&&", "text": "&&", "parent": 494, "children": [], "start_point": {"row": 125, "column": 41}, "end_point": {"row": 125, "column": 43}}, {"id": 504, "type": "parenthesized_expression", "text": "((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK)", "parent": 494, "children": [505], "start_point": {"row": 125, "column": 44}, "end_point": {"row": 125, "column": 120}}, {"id": 505, "type": "binary_expression", "text": "(BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK", "parent": 504, "children": [506, 517, 518], "start_point": {"row": 125, "column": 45}, "end_point": {"row": 125, "column": 119}}, {"id": 506, "type": "parenthesized_expression", "text": "(BlockSize((Gerency.LastBlockReleased)) - size)", "parent": 505, "children": [507], "start_point": {"row": 125, "column": 45}, "end_point": {"row": 125, "column": 92}}, {"id": 507, "type": "binary_expression", "text": "BlockSize((Gerency.LastBlockReleased)) - size", "parent": 506, "children": [508, 515, 516], "start_point": {"row": 125, "column": 46}, "end_point": {"row": 125, "column": 91}}, {"id": 508, "type": "call_expression", "text": "BlockSize((Gerency.LastBlockReleased))", "parent": 507, "children": [509, 510], "start_point": {"row": 125, "column": 46}, "end_point": {"row": 125, "column": 84}}, {"id": 509, "type": "identifier", "text": "BlockSize", "parent": 508, "children": [], "start_point": {"row": 125, "column": 46}, "end_point": {"row": 125, "column": 55}}, {"id": 510, "type": "argument_list", "text": "((Gerency.LastBlockReleased))", "parent": 508, "children": [511], "start_point": {"row": 125, "column": 55}, "end_point": {"row": 125, "column": 84}}, {"id": 511, "type": "parenthesized_expression", "text": "(Gerency.LastBlockReleased)", "parent": 510, "children": [512], "start_point": {"row": 125, "column": 56}, "end_point": {"row": 125, "column": 83}}, {"id": 512, "type": "field_expression", "text": "Gerency.LastBlockReleased", "parent": 511, "children": [513, 514], "start_point": {"row": 125, "column": 57}, "end_point": {"row": 125, "column": 82}}, {"id": 513, "type": "identifier", "text": "Gerency", "parent": 512, "children": [], "start_point": {"row": 125, "column": 57}, "end_point": {"row": 125, "column": 64}}, {"id": 514, "type": "field_identifier", "text": "LastBlockReleased", "parent": 512, "children": [], "start_point": {"row": 125, "column": 65}, "end_point": {"row": 125, "column": 82}}, {"id": 515, "type": "-", "text": "-", "parent": 507, "children": [], "start_point": {"row": 125, "column": 85}, "end_point": {"row": 125, "column": 86}}, {"id": 516, "type": "identifier", "text": "size", "parent": 507, "children": [], "start_point": {"row": 125, "column": 87}, "end_point": {"row": 125, "column": 91}}, {"id": 517, "type": "<=", "text": "<=", "parent": 505, "children": [], "start_point": {"row": 125, "column": 93}, "end_point": {"row": 125, "column": 95}}, {"id": 518, "type": "identifier", "text": "MAX_FRAGMENTATION_BLOCK", "parent": 505, "children": [], "start_point": {"row": 125, "column": 96}, "end_point": {"row": 125, "column": 119}}, {"id": 519, "type": "assignment_expression", "text": "enjoyBlock = Gerency.LastBlockReleased", "parent": 492, "children": [520, 521, 522], "start_point": {"row": 127, "column": 3}, "end_point": {"row": 127, "column": 41}}, {"id": 520, "type": "identifier", "text": "enjoyBlock", "parent": 519, "children": [], "start_point": {"row": 127, "column": 3}, "end_point": {"row": 127, "column": 13}}, {"id": 521, "type": "=", "text": "=", "parent": 519, "children": [], "start_point": {"row": 127, "column": 14}, "end_point": {"row": 127, "column": 15}}, {"id": 522, "type": "field_expression", "text": "Gerency.LastBlockReleased", "parent": 519, "children": [523, 524], "start_point": {"row": 127, "column": 16}, "end_point": {"row": 127, "column": 41}}, {"id": 523, "type": "identifier", "text": "Gerency", "parent": 522, "children": [], "start_point": {"row": 127, "column": 16}, "end_point": {"row": 127, "column": 23}}, {"id": 524, "type": "field_identifier", "text": "LastBlockReleased", "parent": 522, "children": [], "start_point": {"row": 127, "column": 24}, "end_point": {"row": 127, "column": 41}}, {"id": 525, "type": "assignment_expression", "text": "enjoyBlock->Info.Field.free = 0", "parent": 492, "children": [526, 533, 534], "start_point": {"row": 128, "column": 3}, "end_point": {"row": 128, "column": 34}}, {"id": 526, "type": "field_expression", "text": "enjoyBlock->Info.Field.free", "parent": 525, "children": [527, 532], "start_point": {"row": 128, "column": 3}, "end_point": {"row": 128, "column": 30}}, {"id": 527, "type": "field_expression", "text": "enjoyBlock->Info.Field", "parent": 526, "children": [528, 531], "start_point": {"row": 128, "column": 3}, "end_point": {"row": 128, "column": 25}}, {"id": 528, "type": "field_expression", "text": "enjoyBlock->Info", "parent": 527, "children": [529, 530], "start_point": {"row": 128, "column": 3}, "end_point": {"row": 128, "column": 19}}, {"id": 529, "type": "identifier", "text": "enjoyBlock", "parent": 528, "children": [], "start_point": {"row": 128, "column": 3}, "end_point": {"row": 128, "column": 13}}, {"id": 530, "type": "field_identifier", "text": "Info", "parent": 528, "children": [], "start_point": {"row": 128, "column": 15}, "end_point": {"row": 128, "column": 19}}, {"id": 531, "type": "field_identifier", "text": "Field", "parent": 527, "children": [], "start_point": {"row": 128, "column": 20}, "end_point": {"row": 128, "column": 25}}, {"id": 532, "type": "field_identifier", "text": "free", "parent": 526, "children": [], "start_point": {"row": 128, "column": 26}, "end_point": {"row": 128, "column": 30}}, {"id": 533, "type": "=", "text": "=", "parent": 525, "children": [], "start_point": {"row": 128, "column": 31}, "end_point": {"row": 128, "column": 32}}, {"id": 534, "type": "number_literal", "text": "0", "parent": 525, "children": [], "start_point": {"row": 128, "column": 33}, "end_point": {"row": 128, "column": 34}}, {"id": 535, "type": "assignment_expression", "text": "Gerency.LastBlockReleased = NULL", "parent": 492, "children": [536, 539, 540], "start_point": {"row": 129, "column": 3}, "end_point": {"row": 129, "column": 35}}, {"id": 536, "type": "field_expression", "text": "Gerency.LastBlockReleased", "parent": 535, "children": [537, 538], "start_point": {"row": 129, "column": 3}, "end_point": {"row": 129, "column": 28}}, {"id": 537, "type": "identifier", "text": "Gerency", "parent": 536, "children": [], "start_point": {"row": 129, "column": 3}, "end_point": {"row": 129, "column": 10}}, {"id": 538, "type": "field_identifier", "text": "LastBlockReleased", "parent": 536, "children": [], "start_point": {"row": 129, "column": 11}, "end_point": {"row": 129, "column": 28}}, {"id": 539, "type": "=", "text": "=", "parent": 535, "children": [], "start_point": {"row": 129, "column": 29}, "end_point": {"row": 129, "column": 30}}, {"id": 540, "type": "null", "text": "NULL", "parent": 535, "children": [541], "start_point": {"row": 129, "column": 31}, "end_point": {"row": 129, "column": 35}}, {"id": 541, "type": "NULL", "text": "NULL", "parent": 540, "children": [], "start_point": {"row": 129, "column": 31}, "end_point": {"row": 129, "column": 35}}, {"id": 542, "type": "assignment_expression", "text": "numberFragmentation += BlockSize(enjoyBlock) - size", "parent": 492, "children": [543, 544, 545], "start_point": {"row": 130, "column": 3}, "end_point": {"row": 130, "column": 54}}, {"id": 543, "type": "identifier", "text": "numberFragmentation", "parent": 542, "children": [], "start_point": {"row": 130, "column": 3}, "end_point": {"row": 130, "column": 22}}, {"id": 544, "type": "+=", "text": "+=", "parent": 542, "children": [], "start_point": {"row": 130, "column": 23}, "end_point": {"row": 130, "column": 25}}, {"id": 545, "type": "binary_expression", "text": "BlockSize(enjoyBlock) - size", "parent": 542, "children": [546, 550, 551], "start_point": {"row": 130, "column": 26}, "end_point": {"row": 130, "column": 54}}, {"id": 546, "type": "call_expression", "text": "BlockSize(enjoyBlock)", "parent": 545, "children": [547, 548], "start_point": {"row": 130, "column": 26}, "end_point": {"row": 130, "column": 47}}, {"id": 547, "type": "identifier", "text": "BlockSize", "parent": 546, "children": [], "start_point": {"row": 130, "column": 26}, "end_point": {"row": 130, "column": 35}}, {"id": 548, "type": "argument_list", "text": "(enjoyBlock)", "parent": 546, "children": [549], "start_point": {"row": 130, "column": 35}, "end_point": {"row": 130, "column": 47}}, {"id": 549, "type": "identifier", "text": "enjoyBlock", "parent": 548, "children": [], "start_point": {"row": 130, "column": 36}, "end_point": {"row": 130, "column": 46}}, {"id": 550, "type": "-", "text": "-", "parent": 545, "children": [], "start_point": {"row": 130, "column": 48}, "end_point": {"row": 130, "column": 49}}, {"id": 551, "type": "identifier", "text": "size", "parent": 545, "children": [], "start_point": {"row": 130, "column": 50}, "end_point": {"row": 130, "column": 54}}, {"id": 552, "type": "assignment_expression", "text": "numberFreeBlocks -= 1", "parent": 492, "children": [553, 554, 555], "start_point": {"row": 131, "column": 3}, "end_point": {"row": 131, "column": 24}}, {"id": 553, "type": "identifier", "text": "numberFreeBlocks", "parent": 552, "children": [], "start_point": {"row": 131, "column": 3}, "end_point": {"row": 131, "column": 19}}, {"id": 554, "type": "-=", "text": "-=", "parent": 552, "children": [], "start_point": {"row": 131, "column": 20}, "end_point": {"row": 131, "column": 22}}, {"id": 555, "type": "number_literal", "text": "1", "parent": 552, "children": [], "start_point": {"row": 131, "column": 23}, "end_point": {"row": 131, "column": 24}}, {"id": 556, "type": "return_statement", "text": "return (enjoyBlock + 1);", "parent": 492, "children": [557], "start_point": {"row": 132, "column": 3}, "end_point": {"row": 132, "column": 27}}, {"id": 557, "type": "parenthesized_expression", "text": "(enjoyBlock + 1)", "parent": 556, "children": [558], "start_point": {"row": 132, "column": 10}, "end_point": {"row": 132, "column": 26}}, {"id": 558, "type": "binary_expression", "text": "enjoyBlock + 1", "parent": 557, "children": [559, 560, 561], "start_point": {"row": 132, "column": 11}, "end_point": {"row": 132, "column": 25}}, {"id": 559, "type": "identifier", "text": "enjoyBlock", "parent": 558, "children": [], "start_point": {"row": 132, "column": 11}, "end_point": {"row": 132, "column": 21}}, {"id": 560, "type": "+", "text": "+", "parent": 558, "children": [], "start_point": {"row": 132, "column": 22}, "end_point": {"row": 132, "column": 23}}, {"id": 561, "type": "number_literal", "text": "1", "parent": 558, "children": [], "start_point": {"row": 132, "column": 24}, "end_point": {"row": 132, "column": 25}}, {"id": 562, "type": "else_clause", "text": "else\n\t\t{\n\t\t\tswitch(AAlgorithm)\n\t\t\t{\n\t\t\t\tcase FIRST_FIT:\n\t\t\t\ttry_first_fit:\n\n\n\t\t\t\t\tforeach(enjoyBlock,(Gerency.ListBlocks))\n\t\t\t\t\t{\n\t\t\t\t\t\tif((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\t\t\t\t\tnumberFreeBlocks -= 1;\n\t\t\t\t\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\t\t\t\t\treturn (enjoyBlock + 1);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tcase BEST_FIT:\n\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, Gerency.ListBlocks)\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(spaceFree < 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\telse if(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\tnumberFragmentation += BlockSize(tempBlock) - size;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\n\t\t\t\tcase WORST_FIT:\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, (Gerency.ListBlocks))\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tdefault:\n\t\t\t\t\tgoto try_first_fit;\n\n\t\t\t}\n\n\t\t\tscroll = *(Gerency.ListBlocks);\n\n\t\t\twhile((scroll != NULL) && (BlockSize(scroll) < size))\n\t\t\t{\n\t\t\t\tpreviousScroll = scroll;\n\t\t\t\tscroll = scroll->next;\n\t\t\t}\n\n\t\t\tnewBlock = Gerency.CurrentPointerHeap;\n\t\t\tnewBlock->Info.Field.free = 0;\n\t\t\tnewBlock->Info.Field.size = size;\n\t\t\tnewBlock->id = numberBlocks;\n\t\t\tnumberBlocks += 1;\n\n\t\t\tif(scroll == *(Gerency.ListBlocks) )\n\t\t\t{\n\t\t\t\tnewBlock->next = *(Gerency.ListBlocks);\n\t\t\t\t*(Gerency.ListBlocks) = newBlock;\n\t\t\t}\n\t\t\t\n\t\t\telse\n\t\t\t{\n\t\t\t\tnewBlock->next = previousScroll->next;\n\t\t\t\tpreviousScroll->next = newBlock;\n\t\t\t}\n\n\t\t\tGerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n\t\t\tmemoryUsage += ((sizeof(struct Block) + size));\n\t\t}", "parent": 492, "children": [], "start_point": {"row": 134, "column": 2}, "end_point": {"row": 241, "column": 3}}, {"id": 563, "type": "switch_statement", "text": "switch(AAlgorithm)\n\t\t\t{\n\t\t\t\tcase FIRST_FIT:\n\t\t\t\ttry_first_fit:\n\n\n\t\t\t\t\tforeach(enjoyBlock,(Gerency.ListBlocks))\n\t\t\t\t\t{\n\t\t\t\t\t\tif((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\t\t\t\t\tnumberFreeBlocks -= 1;\n\t\t\t\t\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\t\t\t\t\treturn (enjoyBlock + 1);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tcase BEST_FIT:\n\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, Gerency.ListBlocks)\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(spaceFree < 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\telse if(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\tnumberFragmentation += BlockSize(tempBlock) - size;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\n\t\t\t\tcase WORST_FIT:\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, (Gerency.ListBlocks))\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tdefault:\n\t\t\t\t\tgoto try_first_fit;\n\n\t\t\t}", "parent": 562, "children": [564, 565], "start_point": {"row": 136, "column": 3}, "end_point": {"row": 211, "column": 4}}, {"id": 564, "type": "switch", "text": "switch", "parent": 563, "children": [], "start_point": {"row": 136, "column": 3}, "end_point": {"row": 136, "column": 9}}, {"id": 565, "type": "parenthesized_expression", "text": "(AAlgorithm)", "parent": 563, "children": [566], "start_point": {"row": 136, "column": 9}, "end_point": {"row": 136, "column": 21}}, {"id": 566, "type": "identifier", "text": "AAlgorithm", "parent": 565, "children": [], "start_point": {"row": 136, "column": 10}, "end_point": {"row": 136, "column": 20}}, {"id": 567, "type": "case_statement", "text": "case FIRST_FIT:\n\t\t\t\ttry_first_fit:\n\n\n\t\t\t\t\tforeach(enjoyBlock,(Gerency.ListBlocks))\n\t\t\t\t\t{\n\t\t\t\t\t\tif((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\t\t\t\t\tnumberFreeBlocks -= 1;\n\t\t\t\t\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\t\t\t\t\treturn (enjoyBlock + 1);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\tbreak;", "parent": 563, "children": [568, 569, 570, 627], "start_point": {"row": 138, "column": 4}, "end_point": {"row": 153, "column": 10}}, {"id": 568, "type": "case", "text": "case", "parent": 567, "children": [], "start_point": {"row": 138, "column": 4}, "end_point": {"row": 138, "column": 8}}, {"id": 569, "type": "identifier", "text": "FIRST_FIT", "parent": 567, "children": [], "start_point": {"row": 138, "column": 9}, "end_point": {"row": 138, "column": 18}}, {"id": 570, "type": "labeled_statement", "text": "try_first_fit:\n\n\n\t\t\t\t\tforeach(enjoyBlock,(Gerency.ListBlocks))", "parent": 567, "children": [571], "start_point": {"row": 139, "column": 4}, "end_point": {"row": 142, "column": 45}}, {"id": 571, "type": "statement_identifier", "text": "try_first_fit", "parent": 570, "children": [], "start_point": {"row": 139, "column": 4}, "end_point": {"row": 139, "column": 17}}, {"id": 572, "type": "call_expression", "text": "foreach(enjoyBlock,(Gerency.ListBlocks))", "parent": 570, "children": [573, 574], "start_point": {"row": 142, "column": 5}, "end_point": {"row": 142, "column": 45}}, {"id": 573, "type": "identifier", "text": "foreach", "parent": 572, "children": [], "start_point": {"row": 142, "column": 5}, "end_point": {"row": 142, "column": 12}}, {"id": 574, "type": "argument_list", "text": "(enjoyBlock,(Gerency.ListBlocks))", "parent": 572, "children": [575, 576], "start_point": {"row": 142, "column": 12}, "end_point": {"row": 142, "column": 45}}, {"id": 575, "type": "identifier", "text": "enjoyBlock", "parent": 574, "children": [], "start_point": {"row": 142, "column": 13}, "end_point": {"row": 142, "column": 23}}, {"id": 576, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 574, "children": [577], "start_point": {"row": 142, "column": 24}, "end_point": {"row": 142, "column": 44}}, {"id": 577, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 576, "children": [578, 579], "start_point": {"row": 142, "column": 25}, "end_point": {"row": 142, "column": 43}}, {"id": 578, "type": "identifier", "text": "Gerency", "parent": 577, "children": [], "start_point": {"row": 142, "column": 25}, "end_point": {"row": 142, "column": 32}}, {"id": 579, "type": "field_identifier", "text": "ListBlocks", "parent": 577, "children": [], "start_point": {"row": 142, "column": 33}, "end_point": {"row": 142, "column": 43}}, {"id": 580, "type": "if_statement", "text": "if((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\t\t\t\t\tnumberFreeBlocks -= 1;\n\t\t\t\t\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\t\t\t\t\treturn (enjoyBlock + 1);\n\t\t\t\t\t\t}", "parent": 567, "children": [581], "start_point": {"row": 144, "column": 6}, "end_point": {"row": 150, "column": 7}}, {"id": 581, "type": "parenthesized_expression", "text": "((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))", "parent": 580, "children": [582], "start_point": {"row": 144, "column": 8}, "end_point": {"row": 144, "column": 70}}, {"id": 582, "type": "binary_expression", "text": "(BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock))", "parent": 581, "children": [583, 591, 592], "start_point": {"row": 144, "column": 9}, "end_point": {"row": 144, "column": 69}}, {"id": 583, "type": "parenthesized_expression", "text": "(BlockSize(enjoyBlock) >= size)", "parent": 582, "children": [584], "start_point": {"row": 144, "column": 9}, "end_point": {"row": 144, "column": 40}}, {"id": 584, "type": "binary_expression", "text": "BlockSize(enjoyBlock) >= size", "parent": 583, "children": [585, 589, 590], "start_point": {"row": 144, "column": 10}, "end_point": {"row": 144, "column": 39}}, {"id": 585, "type": "call_expression", "text": "BlockSize(enjoyBlock)", "parent": 584, "children": [586, 587], "start_point": {"row": 144, "column": 10}, "end_point": {"row": 144, "column": 31}}, {"id": 586, "type": "identifier", "text": "BlockSize", "parent": 585, "children": [], "start_point": {"row": 144, "column": 10}, "end_point": {"row": 144, "column": 19}}, {"id": 587, "type": "argument_list", "text": "(enjoyBlock)", "parent": 585, "children": [588], "start_point": {"row": 144, "column": 19}, "end_point": {"row": 144, "column": 31}}, {"id": 588, "type": "identifier", "text": "enjoyBlock", "parent": 587, "children": [], "start_point": {"row": 144, "column": 20}, "end_point": {"row": 144, "column": 30}}, {"id": 589, "type": ">=", "text": ">=", "parent": 584, "children": [], "start_point": {"row": 144, "column": 32}, "end_point": {"row": 144, "column": 34}}, {"id": 590, "type": "identifier", "text": "size", "parent": 584, "children": [], "start_point": {"row": 144, "column": 35}, "end_point": {"row": 144, "column": 39}}, {"id": 591, "type": "&&", "text": "&&", "parent": 582, "children": [], "start_point": {"row": 144, "column": 41}, "end_point": {"row": 144, "column": 43}}, {"id": 592, "type": "parenthesized_expression", "text": "(isFreeBlock(enjoyBlock))", "parent": 582, "children": [593], "start_point": {"row": 144, "column": 44}, "end_point": {"row": 144, "column": 69}}, {"id": 593, "type": "call_expression", "text": "isFreeBlock(enjoyBlock)", "parent": 592, "children": [594, 595], "start_point": {"row": 144, "column": 45}, "end_point": {"row": 144, "column": 68}}, {"id": 594, "type": "identifier", "text": "isFreeBlock", "parent": 593, "children": [], "start_point": {"row": 144, "column": 45}, "end_point": {"row": 144, "column": 56}}, {"id": 595, "type": "argument_list", "text": "(enjoyBlock)", "parent": 593, "children": [596], "start_point": {"row": 144, "column": 56}, "end_point": {"row": 144, "column": 68}}, {"id": 596, "type": "identifier", "text": "enjoyBlock", "parent": 595, "children": [], "start_point": {"row": 144, "column": 57}, "end_point": {"row": 144, "column": 67}}, {"id": 597, "type": "assignment_expression", "text": "enjoyBlock->Info.Field.free = 0", "parent": 580, "children": [598, 605, 606], "start_point": {"row": 146, "column": 7}, "end_point": {"row": 146, "column": 38}}, {"id": 598, "type": "field_expression", "text": "enjoyBlock->Info.Field.free", "parent": 597, "children": [599, 604], "start_point": {"row": 146, "column": 7}, "end_point": {"row": 146, "column": 34}}, {"id": 599, "type": "field_expression", "text": "enjoyBlock->Info.Field", "parent": 598, "children": [600, 603], "start_point": {"row": 146, "column": 7}, "end_point": {"row": 146, "column": 29}}, {"id": 600, "type": "field_expression", "text": "enjoyBlock->Info", "parent": 599, "children": [601, 602], "start_point": {"row": 146, "column": 7}, "end_point": {"row": 146, "column": 23}}, {"id": 601, "type": "identifier", "text": "enjoyBlock", "parent": 600, "children": [], "start_point": {"row": 146, "column": 7}, "end_point": {"row": 146, "column": 17}}, {"id": 602, "type": "field_identifier", "text": "Info", "parent": 600, "children": [], "start_point": {"row": 146, "column": 19}, "end_point": {"row": 146, "column": 23}}, {"id": 603, "type": "field_identifier", "text": "Field", "parent": 599, "children": [], "start_point": {"row": 146, "column": 24}, "end_point": {"row": 146, "column": 29}}, {"id": 604, "type": "field_identifier", "text": "free", "parent": 598, "children": [], "start_point": {"row": 146, "column": 30}, "end_point": {"row": 146, "column": 34}}, {"id": 605, "type": "=", "text": "=", "parent": 597, "children": [], "start_point": {"row": 146, "column": 35}, "end_point": {"row": 146, "column": 36}}, {"id": 606, "type": "number_literal", "text": "0", "parent": 597, "children": [], "start_point": {"row": 146, "column": 37}, "end_point": {"row": 146, "column": 38}}, {"id": 607, "type": "assignment_expression", "text": "numberFreeBlocks -= 1", "parent": 580, "children": [608, 609, 610], "start_point": {"row": 147, "column": 7}, "end_point": {"row": 147, "column": 28}}, {"id": 608, "type": "identifier", "text": "numberFreeBlocks", "parent": 607, "children": [], "start_point": {"row": 147, "column": 7}, "end_point": {"row": 147, "column": 23}}, {"id": 609, "type": "-=", "text": "-=", "parent": 607, "children": [], "start_point": {"row": 147, "column": 24}, "end_point": {"row": 147, "column": 26}}, {"id": 610, "type": "number_literal", "text": "1", "parent": 607, "children": [], "start_point": {"row": 147, "column": 27}, "end_point": {"row": 147, "column": 28}}, {"id": 611, "type": "assignment_expression", "text": "numberFragmentation += BlockSize(enjoyBlock) - size", "parent": 580, "children": [612, 613, 614], "start_point": {"row": 148, "column": 7}, "end_point": {"row": 148, "column": 58}}, {"id": 612, "type": "identifier", "text": "numberFragmentation", "parent": 611, "children": [], "start_point": {"row": 148, "column": 7}, "end_point": {"row": 148, "column": 26}}, {"id": 613, "type": "+=", "text": "+=", "parent": 611, "children": [], "start_point": {"row": 148, "column": 27}, "end_point": {"row": 148, "column": 29}}, {"id": 614, "type": "binary_expression", "text": "BlockSize(enjoyBlock) - size", "parent": 611, "children": [615, 619, 620], "start_point": {"row": 148, "column": 30}, "end_point": {"row": 148, "column": 58}}, {"id": 615, "type": "call_expression", "text": "BlockSize(enjoyBlock)", "parent": 614, "children": [616, 617], "start_point": {"row": 148, "column": 30}, "end_point": {"row": 148, "column": 51}}, {"id": 616, "type": "identifier", "text": "BlockSize", "parent": 615, "children": [], "start_point": {"row": 148, "column": 30}, "end_point": {"row": 148, "column": 39}}, {"id": 617, "type": "argument_list", "text": "(enjoyBlock)", "parent": 615, "children": [618], "start_point": {"row": 148, "column": 39}, "end_point": {"row": 148, "column": 51}}, {"id": 618, "type": "identifier", "text": "enjoyBlock", "parent": 617, "children": [], "start_point": {"row": 148, "column": 40}, "end_point": {"row": 148, "column": 50}}, {"id": 619, "type": "-", "text": "-", "parent": 614, "children": [], "start_point": {"row": 148, "column": 52}, "end_point": {"row": 148, "column": 53}}, {"id": 620, "type": "identifier", "text": "size", "parent": 614, "children": [], "start_point": {"row": 148, "column": 54}, "end_point": {"row": 148, "column": 58}}, {"id": 621, "type": "return_statement", "text": "return (enjoyBlock + 1);", "parent": 580, "children": [622], "start_point": {"row": 149, "column": 7}, "end_point": {"row": 149, "column": 31}}, {"id": 622, "type": "parenthesized_expression", "text": "(enjoyBlock + 1)", "parent": 621, "children": [623], "start_point": {"row": 149, "column": 14}, "end_point": {"row": 149, "column": 30}}, {"id": 623, "type": "binary_expression", "text": "enjoyBlock + 1", "parent": 622, "children": [624, 625, 626], "start_point": {"row": 149, "column": 15}, "end_point": {"row": 149, "column": 29}}, {"id": 624, "type": "identifier", "text": "enjoyBlock", "parent": 623, "children": [], "start_point": {"row": 149, "column": 15}, "end_point": {"row": 149, "column": 25}}, {"id": 625, "type": "+", "text": "+", "parent": 623, "children": [], "start_point": {"row": 149, "column": 26}, "end_point": {"row": 149, "column": 27}}, {"id": 626, "type": "number_literal", "text": "1", "parent": 623, "children": [], "start_point": {"row": 149, "column": 28}, "end_point": {"row": 149, "column": 29}}, {"id": 627, "type": "break_statement", "text": "break;", "parent": 567, "children": [628], "start_point": {"row": 153, "column": 4}, "end_point": {"row": 153, "column": 10}}, {"id": 628, "type": "break", "text": "break", "parent": 627, "children": [], "start_point": {"row": 153, "column": 4}, "end_point": {"row": 153, "column": 9}}, {"id": 629, "type": "case_statement", "text": "case BEST_FIT:\n\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, Gerency.ListBlocks)\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(spaceFree < 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\telse if(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\tnumberFragmentation += BlockSize(tempBlock) - size;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;", "parent": 563, "children": [630, 631, 704, 745], "start_point": {"row": 155, "column": 4}, "end_point": {"row": 181, "column": 10}}, {"id": 630, "type": "case", "text": "case", "parent": 629, "children": [], "start_point": {"row": 155, "column": 4}, "end_point": {"row": 155, "column": 8}}, {"id": 631, "type": "identifier", "text": "BEST_FIT", "parent": 629, "children": [], "start_point": {"row": 155, "column": 9}, "end_point": {"row": 155, "column": 17}}, {"id": 632, "type": "assignment_expression", "text": "spaceFree = BlockSize((*(Gerency.ListBlocks))) - size", "parent": 629, "children": [633, 634, 635], "start_point": {"row": 158, "column": 5}, "end_point": {"row": 158, "column": 58}}, {"id": 633, "type": "identifier", "text": "spaceFree", "parent": 632, "children": [], "start_point": {"row": 158, "column": 5}, "end_point": {"row": 158, "column": 14}}, {"id": 634, "type": "=", "text": "=", "parent": 632, "children": [], "start_point": {"row": 158, "column": 15}, "end_point": {"row": 158, "column": 16}}, {"id": 635, "type": "binary_expression", "text": "BlockSize((*(Gerency.ListBlocks))) - size", "parent": 632, "children": [636, 646, 647], "start_point": {"row": 158, "column": 17}, "end_point": {"row": 158, "column": 58}}, {"id": 636, "type": "call_expression", "text": "BlockSize((*(Gerency.ListBlocks)))", "parent": 635, "children": [637, 638], "start_point": {"row": 158, "column": 17}, "end_point": {"row": 158, "column": 51}}, {"id": 637, "type": "identifier", "text": "BlockSize", "parent": 636, "children": [], "start_point": {"row": 158, "column": 17}, "end_point": {"row": 158, "column": 26}}, {"id": 638, "type": "argument_list", "text": "((*(Gerency.ListBlocks)))", "parent": 636, "children": [639], "start_point": {"row": 158, "column": 26}, "end_point": {"row": 158, "column": 51}}, {"id": 639, "type": "parenthesized_expression", "text": "(*(Gerency.ListBlocks))", "parent": 638, "children": [640], "start_point": {"row": 158, "column": 27}, "end_point": {"row": 158, "column": 50}}, {"id": 640, "type": "pointer_expression", "text": "*(Gerency.ListBlocks)", "parent": 639, "children": [641, 642], "start_point": {"row": 158, "column": 28}, "end_point": {"row": 158, "column": 49}}, {"id": 641, "type": "*", "text": "*", "parent": 640, "children": [], "start_point": {"row": 158, "column": 28}, "end_point": {"row": 158, "column": 29}}, {"id": 642, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 640, "children": [643], "start_point": {"row": 158, "column": 29}, "end_point": {"row": 158, "column": 49}}, {"id": 643, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 642, "children": [644, 645], "start_point": {"row": 158, "column": 30}, "end_point": {"row": 158, "column": 48}}, {"id": 644, "type": "identifier", "text": "Gerency", "parent": 643, "children": [], "start_point": {"row": 158, "column": 30}, "end_point": {"row": 158, "column": 37}}, {"id": 645, "type": "field_identifier", "text": "ListBlocks", "parent": 643, "children": [], "start_point": {"row": 158, "column": 38}, "end_point": {"row": 158, "column": 48}}, {"id": 646, "type": "-", "text": "-", "parent": 635, "children": [], "start_point": {"row": 158, "column": 52}, "end_point": {"row": 158, "column": 53}}, {"id": 647, "type": "identifier", "text": "size", "parent": 635, "children": [], "start_point": {"row": 158, "column": 54}, "end_point": {"row": 158, "column": 58}}, {"id": 648, "type": "assignment_expression", "text": "tempBlock = *(Gerency.ListBlocks)", "parent": 629, "children": [649, 650, 651], "start_point": {"row": 159, "column": 5}, "end_point": {"row": 159, "column": 38}}, {"id": 649, "type": "identifier", "text": "tempBlock", "parent": 648, "children": [], "start_point": {"row": 159, "column": 5}, "end_point": {"row": 159, "column": 14}}, {"id": 650, "type": "=", "text": "=", "parent": 648, "children": [], "start_point": {"row": 159, "column": 15}, "end_point": {"row": 159, "column": 16}}, {"id": 651, "type": "pointer_expression", "text": "*(Gerency.ListBlocks)", "parent": 648, "children": [652, 653], "start_point": {"row": 159, "column": 17}, "end_point": {"row": 159, "column": 38}}, {"id": 652, "type": "*", "text": "*", "parent": 651, "children": [], "start_point": {"row": 159, "column": 17}, "end_point": {"row": 159, "column": 18}}, {"id": 653, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 651, "children": [654], "start_point": {"row": 159, "column": 18}, "end_point": {"row": 159, "column": 38}}, {"id": 654, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 653, "children": [655, 656], "start_point": {"row": 159, "column": 19}, "end_point": {"row": 159, "column": 37}}, {"id": 655, "type": "identifier", "text": "Gerency", "parent": 654, "children": [], "start_point": {"row": 159, "column": 19}, "end_point": {"row": 159, "column": 26}}, {"id": 656, "type": "field_identifier", "text": "ListBlocks", "parent": 654, "children": [], "start_point": {"row": 159, "column": 27}, "end_point": {"row": 159, "column": 37}}, {"id": 657, "type": "call_expression", "text": "foreach(enjoyBlock, Gerency.ListBlocks)", "parent": 629, "children": [658, 659], "start_point": {"row": 161, "column": 5}, "end_point": {"row": 161, "column": 44}}, {"id": 658, "type": "identifier", "text": "foreach", "parent": 657, "children": [], "start_point": {"row": 161, "column": 5}, "end_point": {"row": 161, "column": 12}}, {"id": 659, "type": "argument_list", "text": "(enjoyBlock, Gerency.ListBlocks)", "parent": 657, "children": [660, 661], "start_point": {"row": 161, "column": 12}, "end_point": {"row": 161, "column": 44}}, {"id": 660, "type": "identifier", "text": "enjoyBlock", "parent": 659, "children": [], "start_point": {"row": 161, "column": 13}, "end_point": {"row": 161, "column": 23}}, {"id": 661, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 659, "children": [662, 663], "start_point": {"row": 161, "column": 25}, "end_point": {"row": 161, "column": 43}}, {"id": 662, "type": "identifier", "text": "Gerency", "parent": 661, "children": [], "start_point": {"row": 161, "column": 25}, "end_point": {"row": 161, "column": 32}}, {"id": 663, "type": "field_identifier", "text": "ListBlocks", "parent": 661, "children": [], "start_point": {"row": 161, "column": 33}, "end_point": {"row": 161, "column": 43}}, {"id": 664, "type": "assignment_expression", "text": "spaceEvaluation = BlockSize(enjoyBlock) - size", "parent": 629, "children": [665, 666, 667], "start_point": {"row": 163, "column": 6}, "end_point": {"row": 163, "column": 53}}, {"id": 665, "type": "identifier", "text": "spaceEvaluation", "parent": 664, "children": [], "start_point": {"row": 163, "column": 6}, "end_point": {"row": 163, "column": 21}}, {"id": 666, "type": "=", "text": "=", "parent": 664, "children": [], "start_point": {"row": 163, "column": 23}, "end_point": {"row": 163, "column": 24}}, {"id": 667, "type": "binary_expression", "text": "BlockSize(enjoyBlock) - size", "parent": 664, "children": [668, 672, 673], "start_point": {"row": 163, "column": 25}, "end_point": {"row": 163, "column": 53}}, {"id": 668, "type": "call_expression", "text": "BlockSize(enjoyBlock)", "parent": 667, "children": [669, 670], "start_point": {"row": 163, "column": 25}, "end_point": {"row": 163, "column": 46}}, {"id": 669, "type": "identifier", "text": "BlockSize", "parent": 668, "children": [], "start_point": {"row": 163, "column": 25}, "end_point": {"row": 163, "column": 34}}, {"id": 670, "type": "argument_list", "text": "(enjoyBlock)", "parent": 668, "children": [671], "start_point": {"row": 163, "column": 34}, "end_point": {"row": 163, "column": 46}}, {"id": 671, "type": "identifier", "text": "enjoyBlock", "parent": 670, "children": [], "start_point": {"row": 163, "column": 35}, "end_point": {"row": 163, "column": 45}}, {"id": 672, "type": "-", "text": "-", "parent": 667, "children": [], "start_point": {"row": 163, "column": 47}, "end_point": {"row": 163, "column": 48}}, {"id": 673, "type": "identifier", "text": "size", "parent": 667, "children": [], "start_point": {"row": 163, "column": 49}, "end_point": {"row": 163, "column": 53}}, {"id": 674, "type": "if_statement", "text": "if((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}", "parent": 629, "children": [675], "start_point": {"row": 164, "column": 7}, "end_point": {"row": 168, "column": 7}}, {"id": 675, "type": "parenthesized_expression", "text": "((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))", "parent": 674, "children": [676], "start_point": {"row": 164, "column": 9}, "end_point": {"row": 164, "column": 91}}, {"id": 676, "type": "binary_expression", "text": "(spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock)))", "parent": 675, "children": [677, 682, 683], "start_point": {"row": 164, "column": 10}, "end_point": {"row": 164, "column": 90}}, {"id": 677, "type": "parenthesized_expression", "text": "(spaceFree < 0)", "parent": 676, "children": [678], "start_point": {"row": 164, "column": 10}, "end_point": {"row": 164, "column": 25}}, {"id": 678, "type": "binary_expression", "text": "spaceFree < 0", "parent": 677, "children": [679, 680, 681], "start_point": {"row": 164, "column": 11}, "end_point": {"row": 164, "column": 24}}, {"id": 679, "type": "identifier", "text": "spaceFree", "parent": 678, "children": [], "start_point": {"row": 164, "column": 11}, "end_point": {"row": 164, "column": 20}}, {"id": 680, "type": "<", "text": "<", "parent": 678, "children": [], "start_point": {"row": 164, "column": 21}, "end_point": {"row": 164, "column": 22}}, {"id": 681, "type": "number_literal", "text": "0", "parent": 678, "children": [], "start_point": {"row": 164, "column": 23}, "end_point": {"row": 164, "column": 24}}, {"id": 682, "type": "||", "text": "||", "parent": 676, "children": [], "start_point": {"row": 164, "column": 26}, "end_point": {"row": 164, "column": 28}}, {"id": 683, "type": "parenthesized_expression", "text": "((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock)))", "parent": 676, "children": [684], "start_point": {"row": 164, "column": 29}, "end_point": {"row": 164, "column": 90}}, {"id": 684, "type": "binary_expression", "text": "(spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))", "parent": 683, "children": [685, 690, 691], "start_point": {"row": 164, "column": 30}, "end_point": {"row": 164, "column": 89}}, {"id": 685, "type": "parenthesized_expression", "text": "(spaceEvaluation <= spaceFree)", "parent": 684, "children": [686], "start_point": {"row": 164, "column": 30}, "end_point": {"row": 164, "column": 60}}, {"id": 686, "type": "binary_expression", "text": "spaceEvaluation <= spaceFree", "parent": 685, "children": [687, 688, 689], "start_point": {"row": 164, "column": 31}, "end_point": {"row": 164, "column": 59}}, {"id": 687, "type": "identifier", "text": "spaceEvaluation", "parent": 686, "children": [], "start_point": {"row": 164, "column": 31}, "end_point": {"row": 164, "column": 46}}, {"id": 688, "type": "<=", "text": "<=", "parent": 686, "children": [], "start_point": {"row": 164, "column": 47}, "end_point": {"row": 164, "column": 49}}, {"id": 689, "type": "identifier", "text": "spaceFree", "parent": 686, "children": [], "start_point": {"row": 164, "column": 50}, "end_point": {"row": 164, "column": 59}}, {"id": 690, "type": "&&", "text": "&&", "parent": 684, "children": [], "start_point": {"row": 164, "column": 61}, "end_point": {"row": 164, "column": 63}}, {"id": 691, "type": "parenthesized_expression", "text": "(isFreeBlock(enjoyBlock))", "parent": 684, "children": [692], "start_point": {"row": 164, "column": 64}, "end_point": {"row": 164, "column": 89}}, {"id": 692, "type": "call_expression", "text": "isFreeBlock(enjoyBlock)", "parent": 691, "children": [693, 694], "start_point": {"row": 164, "column": 65}, "end_point": {"row": 164, "column": 88}}, {"id": 693, "type": "identifier", "text": "isFreeBlock", "parent": 692, "children": [], "start_point": {"row": 164, "column": 65}, "end_point": {"row": 164, "column": 76}}, {"id": 694, "type": "argument_list", "text": "(enjoyBlock)", "parent": 692, "children": [695], "start_point": {"row": 164, "column": 76}, "end_point": {"row": 164, "column": 88}}, {"id": 695, "type": "identifier", "text": "enjoyBlock", "parent": 694, "children": [], "start_point": {"row": 164, "column": 77}, "end_point": {"row": 164, "column": 87}}, {"id": 696, "type": "assignment_expression", "text": "spaceFree = spaceEvaluation", "parent": 674, "children": [697, 698, 699], "start_point": {"row": 166, "column": 7}, "end_point": {"row": 166, "column": 34}}, {"id": 697, "type": "identifier", "text": "spaceFree", "parent": 696, "children": [], "start_point": {"row": 166, "column": 7}, "end_point": {"row": 166, "column": 16}}, {"id": 698, "type": "=", "text": "=", "parent": 696, "children": [], "start_point": {"row": 166, "column": 17}, "end_point": {"row": 166, "column": 18}}, {"id": 699, "type": "identifier", "text": "spaceEvaluation", "parent": 696, "children": [], "start_point": {"row": 166, "column": 19}, "end_point": {"row": 166, "column": 34}}, {"id": 700, "type": "assignment_expression", "text": "tempBlock = enjoyBlock", "parent": 674, "children": [701, 702, 703], "start_point": {"row": 167, "column": 7}, "end_point": {"row": 167, "column": 29}}, {"id": 701, "type": "identifier", "text": "tempBlock", "parent": 700, "children": [], "start_point": {"row": 167, "column": 7}, "end_point": {"row": 167, "column": 16}}, {"id": 702, "type": "=", "text": "=", "parent": 700, "children": [], "start_point": {"row": 167, "column": 17}, "end_point": {"row": 167, "column": 18}}, {"id": 703, "type": "identifier", "text": "enjoyBlock", "parent": 700, "children": [], "start_point": {"row": 167, "column": 19}, "end_point": {"row": 167, "column": 29}}, {"id": 704, "type": "if_statement", "text": "if(spaceFree < 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\telse if(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\tnumberFragmentation += BlockSize(tempBlock) - size;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}", "parent": 629, "children": [705, 712], "start_point": {"row": 170, "column": 5}, "end_point": {"row": 179, "column": 6}}, {"id": 705, "type": "parenthesized_expression", "text": "(spaceFree < 0)", "parent": 704, "children": [706], "start_point": {"row": 170, "column": 7}, "end_point": {"row": 170, "column": 22}}, {"id": 706, "type": "binary_expression", "text": "spaceFree < 0", "parent": 705, "children": [707, 708, 709], "start_point": {"row": 170, "column": 8}, "end_point": {"row": 170, "column": 21}}, {"id": 707, "type": "identifier", "text": "spaceFree", "parent": 706, "children": [], "start_point": {"row": 170, "column": 8}, "end_point": {"row": 170, "column": 17}}, {"id": 708, "type": "<", "text": "<", "parent": 706, "children": [], "start_point": {"row": 170, "column": 18}, "end_point": {"row": 170, "column": 19}}, {"id": 709, "type": "number_literal", "text": "0", "parent": 706, "children": [], "start_point": {"row": 170, "column": 20}, "end_point": {"row": 170, "column": 21}}, {"id": 710, "type": "break_statement", "text": "break;", "parent": 704, "children": [711], "start_point": {"row": 172, "column": 6}, "end_point": {"row": 172, "column": 12}}, {"id": 711, "type": "break", "text": "break", "parent": 710, "children": [], "start_point": {"row": 172, "column": 6}, "end_point": {"row": 172, "column": 11}}, {"id": 712, "type": "else_clause", "text": "else if(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\tnumberFragmentation += BlockSize(tempBlock) - size;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}", "parent": 704, "children": [713], "start_point": {"row": 174, "column": 5}, "end_point": {"row": 179, "column": 6}}, {"id": 713, "type": "if_statement", "text": "if(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\tnumberFragmentation += BlockSize(tempBlock) - size;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}", "parent": 712, "children": [714], "start_point": {"row": 174, "column": 10}, "end_point": {"row": 179, "column": 6}}, {"id": 714, "type": "parenthesized_expression", "text": "(isFreeBlock(tempBlock))", "parent": 713, "children": [715], "start_point": {"row": 174, "column": 12}, "end_point": {"row": 174, "column": 36}}, {"id": 715, "type": "call_expression", "text": "isFreeBlock(tempBlock)", "parent": 714, "children": [716, 717], "start_point": {"row": 174, "column": 13}, "end_point": {"row": 174, "column": 35}}, {"id": 716, "type": "identifier", "text": "isFreeBlock", "parent": 715, "children": [], "start_point": {"row": 174, "column": 13}, "end_point": {"row": 174, "column": 24}}, {"id": 717, "type": "argument_list", "text": "(tempBlock)", "parent": 715, "children": [718], "start_point": {"row": 174, "column": 24}, "end_point": {"row": 174, "column": 35}}, {"id": 718, "type": "identifier", "text": "tempBlock", "parent": 717, "children": [], "start_point": {"row": 174, "column": 25}, "end_point": {"row": 174, "column": 34}}, {"id": 719, "type": "assignment_expression", "text": "tempBlock->Info.Field.free = 0", "parent": 713, "children": [720, 727, 728], "start_point": {"row": 176, "column": 6}, "end_point": {"row": 176, "column": 36}}, {"id": 720, "type": "field_expression", "text": "tempBlock->Info.Field.free", "parent": 719, "children": [721, 726], "start_point": {"row": 176, "column": 6}, "end_point": {"row": 176, "column": 32}}, {"id": 721, "type": "field_expression", "text": "tempBlock->Info.Field", "parent": 720, "children": [722, 725], "start_point": {"row": 176, "column": 6}, "end_point": {"row": 176, "column": 27}}, {"id": 722, "type": "field_expression", "text": "tempBlock->Info", "parent": 721, "children": [723, 724], "start_point": {"row": 176, "column": 6}, "end_point": {"row": 176, "column": 21}}, {"id": 723, "type": "identifier", "text": "tempBlock", "parent": 722, "children": [], "start_point": {"row": 176, "column": 6}, "end_point": {"row": 176, "column": 15}}, {"id": 724, "type": "field_identifier", "text": "Info", "parent": 722, "children": [], "start_point": {"row": 176, "column": 17}, "end_point": {"row": 176, "column": 21}}, {"id": 725, "type": "field_identifier", "text": "Field", "parent": 721, "children": [], "start_point": {"row": 176, "column": 22}, "end_point": {"row": 176, "column": 27}}, {"id": 726, "type": "field_identifier", "text": "free", "parent": 720, "children": [], "start_point": {"row": 176, "column": 28}, "end_point": {"row": 176, "column": 32}}, {"id": 727, "type": "=", "text": "=", "parent": 719, "children": [], "start_point": {"row": 176, "column": 33}, "end_point": {"row": 176, "column": 34}}, {"id": 728, "type": "number_literal", "text": "0", "parent": 719, "children": [], "start_point": {"row": 176, "column": 35}, "end_point": {"row": 176, "column": 36}}, {"id": 729, "type": "assignment_expression", "text": "numberFragmentation += BlockSize(tempBlock) - size", "parent": 713, "children": [730, 731, 732], "start_point": {"row": 177, "column": 6}, "end_point": {"row": 177, "column": 56}}, {"id": 730, "type": "identifier", "text": "numberFragmentation", "parent": 729, "children": [], "start_point": {"row": 177, "column": 6}, "end_point": {"row": 177, "column": 25}}, {"id": 731, "type": "+=", "text": "+=", "parent": 729, "children": [], "start_point": {"row": 177, "column": 26}, "end_point": {"row": 177, "column": 28}}, {"id": 732, "type": "binary_expression", "text": "BlockSize(tempBlock) - size", "parent": 729, "children": [733, 737, 738], "start_point": {"row": 177, "column": 29}, "end_point": {"row": 177, "column": 56}}, {"id": 733, "type": "call_expression", "text": "BlockSize(tempBlock)", "parent": 732, "children": [734, 735], "start_point": {"row": 177, "column": 29}, "end_point": {"row": 177, "column": 49}}, {"id": 734, "type": "identifier", "text": "BlockSize", "parent": 733, "children": [], "start_point": {"row": 177, "column": 29}, "end_point": {"row": 177, "column": 38}}, {"id": 735, "type": "argument_list", "text": "(tempBlock)", "parent": 733, "children": [736], "start_point": {"row": 177, "column": 38}, "end_point": {"row": 177, "column": 49}}, {"id": 736, "type": "identifier", "text": "tempBlock", "parent": 735, "children": [], "start_point": {"row": 177, "column": 39}, "end_point": {"row": 177, "column": 48}}, {"id": 737, "type": "-", "text": "-", "parent": 732, "children": [], "start_point": {"row": 177, "column": 50}, "end_point": {"row": 177, "column": 51}}, {"id": 738, "type": "identifier", "text": "size", "parent": 732, "children": [], "start_point": {"row": 177, "column": 52}, "end_point": {"row": 177, "column": 56}}, {"id": 739, "type": "return_statement", "text": "return (tempBlock + 1);", "parent": 713, "children": [740], "start_point": {"row": 178, "column": 6}, "end_point": {"row": 178, "column": 29}}, {"id": 740, "type": "parenthesized_expression", "text": "(tempBlock + 1)", "parent": 739, "children": [741], "start_point": {"row": 178, "column": 13}, "end_point": {"row": 178, "column": 28}}, {"id": 741, "type": "binary_expression", "text": "tempBlock + 1", "parent": 740, "children": [742, 743, 744], "start_point": {"row": 178, "column": 14}, "end_point": {"row": 178, "column": 27}}, {"id": 742, "type": "identifier", "text": "tempBlock", "parent": 741, "children": [], "start_point": {"row": 178, "column": 14}, "end_point": {"row": 178, "column": 23}}, {"id": 743, "type": "+", "text": "+", "parent": 741, "children": [], "start_point": {"row": 178, "column": 24}, "end_point": {"row": 178, "column": 25}}, {"id": 744, "type": "number_literal", "text": "1", "parent": 741, "children": [], "start_point": {"row": 178, "column": 26}, "end_point": {"row": 178, "column": 27}}, {"id": 745, "type": "break_statement", "text": "break;", "parent": 629, "children": [746], "start_point": {"row": 181, "column": 4}, "end_point": {"row": 181, "column": 10}}, {"id": 746, "type": "break", "text": "break", "parent": 745, "children": [], "start_point": {"row": 181, "column": 4}, "end_point": {"row": 181, "column": 9}}, {"id": 747, "type": "case_statement", "text": "case WORST_FIT:\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, (Gerency.ListBlocks))\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;", "parent": 563, "children": [748, 749, 823, 845], "start_point": {"row": 184, "column": 4}, "end_point": {"row": 206, "column": 10}}, {"id": 748, "type": "case", "text": "case", "parent": 747, "children": [], "start_point": {"row": 184, "column": 4}, "end_point": {"row": 184, "column": 8}}, {"id": 749, "type": "identifier", "text": "WORST_FIT", "parent": 747, "children": [], "start_point": {"row": 184, "column": 9}, "end_point": {"row": 184, "column": 18}}, {"id": 750, "type": "assignment_expression", "text": "spaceFree = BlockSize((*(Gerency.ListBlocks))) - size", "parent": 747, "children": [751, 752, 753], "start_point": {"row": 186, "column": 5}, "end_point": {"row": 186, "column": 58}}, {"id": 751, "type": "identifier", "text": "spaceFree", "parent": 750, "children": [], "start_point": {"row": 186, "column": 5}, "end_point": {"row": 186, "column": 14}}, {"id": 752, "type": "=", "text": "=", "parent": 750, "children": [], "start_point": {"row": 186, "column": 15}, "end_point": {"row": 186, "column": 16}}, {"id": 753, "type": "binary_expression", "text": "BlockSize((*(Gerency.ListBlocks))) - size", "parent": 750, "children": [754, 764, 765], "start_point": {"row": 186, "column": 17}, "end_point": {"row": 186, "column": 58}}, {"id": 754, "type": "call_expression", "text": "BlockSize((*(Gerency.ListBlocks)))", "parent": 753, "children": [755, 756], "start_point": {"row": 186, "column": 17}, "end_point": {"row": 186, "column": 51}}, {"id": 755, "type": "identifier", "text": "BlockSize", "parent": 754, "children": [], "start_point": {"row": 186, "column": 17}, "end_point": {"row": 186, "column": 26}}, {"id": 756, "type": "argument_list", "text": "((*(Gerency.ListBlocks)))", "parent": 754, "children": [757], "start_point": {"row": 186, "column": 26}, "end_point": {"row": 186, "column": 51}}, {"id": 757, "type": "parenthesized_expression", "text": "(*(Gerency.ListBlocks))", "parent": 756, "children": [758], "start_point": {"row": 186, "column": 27}, "end_point": {"row": 186, "column": 50}}, {"id": 758, "type": "pointer_expression", "text": "*(Gerency.ListBlocks)", "parent": 757, "children": [759, 760], "start_point": {"row": 186, "column": 28}, "end_point": {"row": 186, "column": 49}}, {"id": 759, "type": "*", "text": "*", "parent": 758, "children": [], "start_point": {"row": 186, "column": 28}, "end_point": {"row": 186, "column": 29}}, {"id": 760, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 758, "children": [761], "start_point": {"row": 186, "column": 29}, "end_point": {"row": 186, "column": 49}}, {"id": 761, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 760, "children": [762, 763], "start_point": {"row": 186, "column": 30}, "end_point": {"row": 186, "column": 48}}, {"id": 762, "type": "identifier", "text": "Gerency", "parent": 761, "children": [], "start_point": {"row": 186, "column": 30}, "end_point": {"row": 186, "column": 37}}, {"id": 763, "type": "field_identifier", "text": "ListBlocks", "parent": 761, "children": [], "start_point": {"row": 186, "column": 38}, "end_point": {"row": 186, "column": 48}}, {"id": 764, "type": "-", "text": "-", "parent": 753, "children": [], "start_point": {"row": 186, "column": 52}, "end_point": {"row": 186, "column": 53}}, {"id": 765, "type": "identifier", "text": "size", "parent": 753, "children": [], "start_point": {"row": 186, "column": 54}, "end_point": {"row": 186, "column": 58}}, {"id": 766, "type": "assignment_expression", "text": "tempBlock = *(Gerency.ListBlocks)", "parent": 747, "children": [767, 768, 769], "start_point": {"row": 187, "column": 5}, "end_point": {"row": 187, "column": 38}}, {"id": 767, "type": "identifier", "text": "tempBlock", "parent": 766, "children": [], "start_point": {"row": 187, "column": 5}, "end_point": {"row": 187, "column": 14}}, {"id": 768, "type": "=", "text": "=", "parent": 766, "children": [], "start_point": {"row": 187, "column": 15}, "end_point": {"row": 187, "column": 16}}, {"id": 769, "type": "pointer_expression", "text": "*(Gerency.ListBlocks)", "parent": 766, "children": [770, 771], "start_point": {"row": 187, "column": 17}, "end_point": {"row": 187, "column": 38}}, {"id": 770, "type": "*", "text": "*", "parent": 769, "children": [], "start_point": {"row": 187, "column": 17}, "end_point": {"row": 187, "column": 18}}, {"id": 771, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 769, "children": [772], "start_point": {"row": 187, "column": 18}, "end_point": {"row": 187, "column": 38}}, {"id": 772, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 771, "children": [773, 774], "start_point": {"row": 187, "column": 19}, "end_point": {"row": 187, "column": 37}}, {"id": 773, "type": "identifier", "text": "Gerency", "parent": 772, "children": [], "start_point": {"row": 187, "column": 19}, "end_point": {"row": 187, "column": 26}}, {"id": 774, "type": "field_identifier", "text": "ListBlocks", "parent": 772, "children": [], "start_point": {"row": 187, "column": 27}, "end_point": {"row": 187, "column": 37}}, {"id": 775, "type": "call_expression", "text": "foreach(enjoyBlock, (Gerency.ListBlocks))", "parent": 747, "children": [776, 777], "start_point": {"row": 189, "column": 5}, "end_point": {"row": 189, "column": 46}}, {"id": 776, "type": "identifier", "text": "foreach", "parent": 775, "children": [], "start_point": {"row": 189, "column": 5}, "end_point": {"row": 189, "column": 12}}, {"id": 777, "type": "argument_list", "text": "(enjoyBlock, (Gerency.ListBlocks))", "parent": 775, "children": [778, 779], "start_point": {"row": 189, "column": 12}, "end_point": {"row": 189, "column": 46}}, {"id": 778, "type": "identifier", "text": "enjoyBlock", "parent": 777, "children": [], "start_point": {"row": 189, "column": 13}, "end_point": {"row": 189, "column": 23}}, {"id": 779, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 777, "children": [780], "start_point": {"row": 189, "column": 25}, "end_point": {"row": 189, "column": 45}}, {"id": 780, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 779, "children": [781, 782], "start_point": {"row": 189, "column": 26}, "end_point": {"row": 189, "column": 44}}, {"id": 781, "type": "identifier", "text": "Gerency", "parent": 780, "children": [], "start_point": {"row": 189, "column": 26}, "end_point": {"row": 189, "column": 33}}, {"id": 782, "type": "field_identifier", "text": "ListBlocks", "parent": 780, "children": [], "start_point": {"row": 189, "column": 34}, "end_point": {"row": 189, "column": 44}}, {"id": 783, "type": "assignment_expression", "text": "spaceEvaluation = BlockSize(enjoyBlock) - size", "parent": 747, "children": [784, 785, 786], "start_point": {"row": 191, "column": 6}, "end_point": {"row": 191, "column": 53}}, {"id": 784, "type": "identifier", "text": "spaceEvaluation", "parent": 783, "children": [], "start_point": {"row": 191, "column": 6}, "end_point": {"row": 191, "column": 21}}, {"id": 785, "type": "=", "text": "=", "parent": 783, "children": [], "start_point": {"row": 191, "column": 23}, "end_point": {"row": 191, "column": 24}}, {"id": 786, "type": "binary_expression", "text": "BlockSize(enjoyBlock) - size", "parent": 783, "children": [787, 791, 792], "start_point": {"row": 191, "column": 25}, "end_point": {"row": 191, "column": 53}}, {"id": 787, "type": "call_expression", "text": "BlockSize(enjoyBlock)", "parent": 786, "children": [788, 789], "start_point": {"row": 191, "column": 25}, "end_point": {"row": 191, "column": 46}}, {"id": 788, "type": "identifier", "text": "BlockSize", "parent": 787, "children": [], "start_point": {"row": 191, "column": 25}, "end_point": {"row": 191, "column": 34}}, {"id": 789, "type": "argument_list", "text": "(enjoyBlock)", "parent": 787, "children": [790], "start_point": {"row": 191, "column": 34}, "end_point": {"row": 191, "column": 46}}, {"id": 790, "type": "identifier", "text": "enjoyBlock", "parent": 789, "children": [], "start_point": {"row": 191, "column": 35}, "end_point": {"row": 191, "column": 45}}, {"id": 791, "type": "-", "text": "-", "parent": 786, "children": [], "start_point": {"row": 191, "column": 47}, "end_point": {"row": 191, "column": 48}}, {"id": 792, "type": "identifier", "text": "size", "parent": 786, "children": [], "start_point": {"row": 191, "column": 49}, "end_point": {"row": 191, "column": 53}}, {"id": 793, "type": "if_statement", "text": "if((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}", "parent": 747, "children": [794], "start_point": {"row": 193, "column": 7}, "end_point": {"row": 197, "column": 7}}, {"id": 794, "type": "parenthesized_expression", "text": "((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))", "parent": 793, "children": [795], "start_point": {"row": 193, "column": 9}, "end_point": {"row": 193, "column": 90}}, {"id": 795, "type": "binary_expression", "text": "(spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock)))", "parent": 794, "children": [796, 801, 802], "start_point": {"row": 193, "column": 10}, "end_point": {"row": 193, "column": 89}}, {"id": 796, "type": "parenthesized_expression", "text": "(spaceFree < 0)", "parent": 795, "children": [797], "start_point": {"row": 193, "column": 10}, "end_point": {"row": 193, "column": 25}}, {"id": 797, "type": "binary_expression", "text": "spaceFree < 0", "parent": 796, "children": [798, 799, 800], "start_point": {"row": 193, "column": 11}, "end_point": {"row": 193, "column": 24}}, {"id": 798, "type": "identifier", "text": "spaceFree", "parent": 797, "children": [], "start_point": {"row": 193, "column": 11}, "end_point": {"row": 193, "column": 20}}, {"id": 799, "type": "<", "text": "<", "parent": 797, "children": [], "start_point": {"row": 193, "column": 21}, "end_point": {"row": 193, "column": 22}}, {"id": 800, "type": "number_literal", "text": "0", "parent": 797, "children": [], "start_point": {"row": 193, "column": 23}, "end_point": {"row": 193, "column": 24}}, {"id": 801, "type": "||", "text": "||", "parent": 795, "children": [], "start_point": {"row": 193, "column": 26}, "end_point": {"row": 193, "column": 28}}, {"id": 802, "type": "parenthesized_expression", "text": "((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock)))", "parent": 795, "children": [803], "start_point": {"row": 193, "column": 29}, "end_point": {"row": 193, "column": 89}}, {"id": 803, "type": "binary_expression", "text": "(spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))", "parent": 802, "children": [804, 809, 810], "start_point": {"row": 193, "column": 30}, "end_point": {"row": 193, "column": 88}}, {"id": 804, "type": "parenthesized_expression", "text": "(spaceEvaluation > spaceFree)", "parent": 803, "children": [805], "start_point": {"row": 193, "column": 30}, "end_point": {"row": 193, "column": 59}}, {"id": 805, "type": "binary_expression", "text": "spaceEvaluation > spaceFree", "parent": 804, "children": [806, 807, 808], "start_point": {"row": 193, "column": 31}, "end_point": {"row": 193, "column": 58}}, {"id": 806, "type": "identifier", "text": "spaceEvaluation", "parent": 805, "children": [], "start_point": {"row": 193, "column": 31}, "end_point": {"row": 193, "column": 46}}, {"id": 807, "type": ">", "text": ">", "parent": 805, "children": [], "start_point": {"row": 193, "column": 47}, "end_point": {"row": 193, "column": 48}}, {"id": 808, "type": "identifier", "text": "spaceFree", "parent": 805, "children": [], "start_point": {"row": 193, "column": 49}, "end_point": {"row": 193, "column": 58}}, {"id": 809, "type": "&&", "text": "&&", "parent": 803, "children": [], "start_point": {"row": 193, "column": 60}, "end_point": {"row": 193, "column": 62}}, {"id": 810, "type": "parenthesized_expression", "text": "(isFreeBlock(enjoyBlock))", "parent": 803, "children": [811], "start_point": {"row": 193, "column": 63}, "end_point": {"row": 193, "column": 88}}, {"id": 811, "type": "call_expression", "text": "isFreeBlock(enjoyBlock)", "parent": 810, "children": [812, 813], "start_point": {"row": 193, "column": 64}, "end_point": {"row": 193, "column": 87}}, {"id": 812, "type": "identifier", "text": "isFreeBlock", "parent": 811, "children": [], "start_point": {"row": 193, "column": 64}, "end_point": {"row": 193, "column": 75}}, {"id": 813, "type": "argument_list", "text": "(enjoyBlock)", "parent": 811, "children": [814], "start_point": {"row": 193, "column": 75}, "end_point": {"row": 193, "column": 87}}, {"id": 814, "type": "identifier", "text": "enjoyBlock", "parent": 813, "children": [], "start_point": {"row": 193, "column": 76}, "end_point": {"row": 193, "column": 86}}, {"id": 815, "type": "assignment_expression", "text": "spaceFree = spaceEvaluation", "parent": 793, "children": [816, 817, 818], "start_point": {"row": 195, "column": 7}, "end_point": {"row": 195, "column": 34}}, {"id": 816, "type": "identifier", "text": "spaceFree", "parent": 815, "children": [], "start_point": {"row": 195, "column": 7}, "end_point": {"row": 195, "column": 16}}, {"id": 817, "type": "=", "text": "=", "parent": 815, "children": [], "start_point": {"row": 195, "column": 17}, "end_point": {"row": 195, "column": 18}}, {"id": 818, "type": "identifier", "text": "spaceEvaluation", "parent": 815, "children": [], "start_point": {"row": 195, "column": 19}, "end_point": {"row": 195, "column": 34}}, {"id": 819, "type": "assignment_expression", "text": "tempBlock = enjoyBlock", "parent": 793, "children": [820, 821, 822], "start_point": {"row": 196, "column": 7}, "end_point": {"row": 196, "column": 29}}, {"id": 820, "type": "identifier", "text": "tempBlock", "parent": 819, "children": [], "start_point": {"row": 196, "column": 7}, "end_point": {"row": 196, "column": 16}}, {"id": 821, "type": "=", "text": "=", "parent": 819, "children": [], "start_point": {"row": 196, "column": 17}, "end_point": {"row": 196, "column": 18}}, {"id": 822, "type": "identifier", "text": "enjoyBlock", "parent": 819, "children": [], "start_point": {"row": 196, "column": 19}, "end_point": {"row": 196, "column": 29}}, {"id": 823, "type": "if_statement", "text": "if(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}", "parent": 747, "children": [824], "start_point": {"row": 200, "column": 5}, "end_point": {"row": 204, "column": 6}}, {"id": 824, "type": "parenthesized_expression", "text": "(isFreeBlock(tempBlock))", "parent": 823, "children": [825], "start_point": {"row": 200, "column": 7}, "end_point": {"row": 200, "column": 31}}, {"id": 825, "type": "call_expression", "text": "isFreeBlock(tempBlock)", "parent": 824, "children": [826, 827], "start_point": {"row": 200, "column": 8}, "end_point": {"row": 200, "column": 30}}, {"id": 826, "type": "identifier", "text": "isFreeBlock", "parent": 825, "children": [], "start_point": {"row": 200, "column": 8}, "end_point": {"row": 200, "column": 19}}, {"id": 827, "type": "argument_list", "text": "(tempBlock)", "parent": 825, "children": [828], "start_point": {"row": 200, "column": 19}, "end_point": {"row": 200, "column": 30}}, {"id": 828, "type": "identifier", "text": "tempBlock", "parent": 827, "children": [], "start_point": {"row": 200, "column": 20}, "end_point": {"row": 200, "column": 29}}, {"id": 829, "type": "assignment_expression", "text": "tempBlock->Info.Field.free = 0", "parent": 823, "children": [830, 837, 838], "start_point": {"row": 202, "column": 6}, "end_point": {"row": 202, "column": 36}}, {"id": 830, "type": "field_expression", "text": "tempBlock->Info.Field.free", "parent": 829, "children": [831, 836], "start_point": {"row": 202, "column": 6}, "end_point": {"row": 202, "column": 32}}, {"id": 831, "type": "field_expression", "text": "tempBlock->Info.Field", "parent": 830, "children": [832, 835], "start_point": {"row": 202, "column": 6}, "end_point": {"row": 202, "column": 27}}, {"id": 832, "type": "field_expression", "text": "tempBlock->Info", "parent": 831, "children": [833, 834], "start_point": {"row": 202, "column": 6}, "end_point": {"row": 202, "column": 21}}, {"id": 833, "type": "identifier", "text": "tempBlock", "parent": 832, "children": [], "start_point": {"row": 202, "column": 6}, "end_point": {"row": 202, "column": 15}}, {"id": 834, "type": "field_identifier", "text": "Info", "parent": 832, "children": [], "start_point": {"row": 202, "column": 17}, "end_point": {"row": 202, "column": 21}}, {"id": 835, "type": "field_identifier", "text": "Field", "parent": 831, "children": [], "start_point": {"row": 202, "column": 22}, "end_point": {"row": 202, "column": 27}}, {"id": 836, "type": "field_identifier", "text": "free", "parent": 830, "children": [], "start_point": {"row": 202, "column": 28}, "end_point": {"row": 202, "column": 32}}, {"id": 837, "type": "=", "text": "=", "parent": 829, "children": [], "start_point": {"row": 202, "column": 33}, "end_point": {"row": 202, "column": 34}}, {"id": 838, "type": "number_literal", "text": "0", "parent": 829, "children": [], "start_point": {"row": 202, "column": 35}, "end_point": {"row": 202, "column": 36}}, {"id": 839, "type": "return_statement", "text": "return (tempBlock + 1);", "parent": 823, "children": [840], "start_point": {"row": 203, "column": 6}, "end_point": {"row": 203, "column": 29}}, {"id": 840, "type": "parenthesized_expression", "text": "(tempBlock + 1)", "parent": 839, "children": [841], "start_point": {"row": 203, "column": 13}, "end_point": {"row": 203, "column": 28}}, {"id": 841, "type": "binary_expression", "text": "tempBlock + 1", "parent": 840, "children": [842, 843, 844], "start_point": {"row": 203, "column": 14}, "end_point": {"row": 203, "column": 27}}, {"id": 842, "type": "identifier", "text": "tempBlock", "parent": 841, "children": [], "start_point": {"row": 203, "column": 14}, "end_point": {"row": 203, "column": 23}}, {"id": 843, "type": "+", "text": "+", "parent": 841, "children": [], "start_point": {"row": 203, "column": 24}, "end_point": {"row": 203, "column": 25}}, {"id": 844, "type": "number_literal", "text": "1", "parent": 841, "children": [], "start_point": {"row": 203, "column": 26}, "end_point": {"row": 203, "column": 27}}, {"id": 845, "type": "break_statement", "text": "break;", "parent": 747, "children": [846], "start_point": {"row": 206, "column": 4}, "end_point": {"row": 206, "column": 10}}, {"id": 846, "type": "break", "text": "break", "parent": 845, "children": [], "start_point": {"row": 206, "column": 4}, "end_point": {"row": 206, "column": 9}}, {"id": 847, "type": "case_statement", "text": "default:\n\t\t\t\t\tgoto try_first_fit;", "parent": 563, "children": [848, 849], "start_point": {"row": 208, "column": 4}, "end_point": {"row": 209, "column": 24}}, {"id": 848, "type": "default", "text": "default", "parent": 847, "children": [], "start_point": {"row": 208, "column": 4}, "end_point": {"row": 208, "column": 11}}, {"id": 849, "type": "goto_statement", "text": "goto try_first_fit;", "parent": 847, "children": [850, 851], "start_point": {"row": 209, "column": 5}, "end_point": {"row": 209, "column": 24}}, {"id": 850, "type": "goto", "text": "goto", "parent": 849, "children": [], "start_point": {"row": 209, "column": 5}, "end_point": {"row": 209, "column": 9}}, {"id": 851, "type": "statement_identifier", "text": "try_first_fit", "parent": 849, "children": [], "start_point": {"row": 209, "column": 10}, "end_point": {"row": 209, "column": 23}}, {"id": 852, "type": "assignment_expression", "text": "scroll = *(Gerency.ListBlocks)", "parent": 562, "children": [853, 854, 855], "start_point": {"row": 213, "column": 3}, "end_point": {"row": 213, "column": 33}}, {"id": 853, "type": "identifier", "text": "scroll", "parent": 852, "children": [], "start_point": {"row": 213, "column": 3}, "end_point": {"row": 213, "column": 9}}, {"id": 854, "type": "=", "text": "=", "parent": 852, "children": [], "start_point": {"row": 213, "column": 10}, "end_point": {"row": 213, "column": 11}}, {"id": 855, "type": "pointer_expression", "text": "*(Gerency.ListBlocks)", "parent": 852, "children": [856, 857], "start_point": {"row": 213, "column": 12}, "end_point": {"row": 213, "column": 33}}, {"id": 856, "type": "*", "text": "*", "parent": 855, "children": [], "start_point": {"row": 213, "column": 12}, "end_point": {"row": 213, "column": 13}}, {"id": 857, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 855, "children": [858], "start_point": {"row": 213, "column": 13}, "end_point": {"row": 213, "column": 33}}, {"id": 858, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 857, "children": [859, 860], "start_point": {"row": 213, "column": 14}, "end_point": {"row": 213, "column": 32}}, {"id": 859, "type": "identifier", "text": "Gerency", "parent": 858, "children": [], "start_point": {"row": 213, "column": 14}, "end_point": {"row": 213, "column": 21}}, {"id": 860, "type": "field_identifier", "text": "ListBlocks", "parent": 858, "children": [], "start_point": {"row": 213, "column": 22}, "end_point": {"row": 213, "column": 32}}, {"id": 861, "type": "while_statement", "text": "while((scroll != NULL) && (BlockSize(scroll) < size))\n\t\t\t{\n\t\t\t\tpreviousScroll = scroll;\n\t\t\t\tscroll = scroll->next;\n\t\t\t}", "parent": 562, "children": [862], "start_point": {"row": 215, "column": 3}, "end_point": {"row": 219, "column": 4}}, {"id": 862, "type": "parenthesized_expression", "text": "((scroll != NULL) && (BlockSize(scroll) < size))", "parent": 861, "children": [863], "start_point": {"row": 215, "column": 8}, "end_point": {"row": 215, "column": 56}}, {"id": 863, "type": "binary_expression", "text": "(scroll != NULL) && (BlockSize(scroll) < size)", "parent": 862, "children": [864, 870, 871], "start_point": {"row": 215, "column": 9}, "end_point": {"row": 215, "column": 55}}, {"id": 864, "type": "parenthesized_expression", "text": "(scroll != NULL)", "parent": 863, "children": [865], "start_point": {"row": 215, "column": 9}, "end_point": {"row": 215, "column": 25}}, {"id": 865, "type": "binary_expression", "text": "scroll != NULL", "parent": 864, "children": [866, 867, 868], "start_point": {"row": 215, "column": 10}, "end_point": {"row": 215, "column": 24}}, {"id": 866, "type": "identifier", "text": "scroll", "parent": 865, "children": [], "start_point": {"row": 215, "column": 10}, "end_point": {"row": 215, "column": 16}}, {"id": 867, "type": "!=", "text": "!=", "parent": 865, "children": [], "start_point": {"row": 215, "column": 17}, "end_point": {"row": 215, "column": 19}}, {"id": 868, "type": "null", "text": "NULL", "parent": 865, "children": [869], "start_point": {"row": 215, "column": 20}, "end_point": {"row": 215, "column": 24}}, {"id": 869, "type": "NULL", "text": "NULL", "parent": 868, "children": [], "start_point": {"row": 215, "column": 20}, "end_point": {"row": 215, "column": 24}}, {"id": 870, "type": "&&", "text": "&&", "parent": 863, "children": [], "start_point": {"row": 215, "column": 26}, "end_point": {"row": 215, "column": 28}}, {"id": 871, "type": "parenthesized_expression", "text": "(BlockSize(scroll) < size)", "parent": 863, "children": [872], "start_point": {"row": 215, "column": 29}, "end_point": {"row": 215, "column": 55}}, {"id": 872, "type": "binary_expression", "text": "BlockSize(scroll) < size", "parent": 871, "children": [873, 877, 878], "start_point": {"row": 215, "column": 30}, "end_point": {"row": 215, "column": 54}}, {"id": 873, "type": "call_expression", "text": "BlockSize(scroll)", "parent": 872, "children": [874, 875], "start_point": {"row": 215, "column": 30}, "end_point": {"row": 215, "column": 47}}, {"id": 874, "type": "identifier", "text": "BlockSize", "parent": 873, "children": [], "start_point": {"row": 215, "column": 30}, "end_point": {"row": 215, "column": 39}}, {"id": 875, "type": "argument_list", "text": "(scroll)", "parent": 873, "children": [876], "start_point": {"row": 215, "column": 39}, "end_point": {"row": 215, "column": 47}}, {"id": 876, "type": "identifier", "text": "scroll", "parent": 875, "children": [], "start_point": {"row": 215, "column": 40}, "end_point": {"row": 215, "column": 46}}, {"id": 877, "type": "<", "text": "<", "parent": 872, "children": [], "start_point": {"row": 215, "column": 48}, "end_point": {"row": 215, "column": 49}}, {"id": 878, "type": "identifier", "text": "size", "parent": 872, "children": [], "start_point": {"row": 215, "column": 50}, "end_point": {"row": 215, "column": 54}}, {"id": 879, "type": "assignment_expression", "text": "previousScroll = scroll", "parent": 861, "children": [880, 881, 882], "start_point": {"row": 217, "column": 4}, "end_point": {"row": 217, "column": 27}}, {"id": 880, "type": "identifier", "text": "previousScroll", "parent": 879, "children": [], "start_point": {"row": 217, "column": 4}, "end_point": {"row": 217, "column": 18}}, {"id": 881, "type": "=", "text": "=", "parent": 879, "children": [], "start_point": {"row": 217, "column": 19}, "end_point": {"row": 217, "column": 20}}, {"id": 882, "type": "identifier", "text": "scroll", "parent": 879, "children": [], "start_point": {"row": 217, "column": 21}, "end_point": {"row": 217, "column": 27}}, {"id": 883, "type": "assignment_expression", "text": "scroll = scroll->next", "parent": 861, "children": [884, 885, 886], "start_point": {"row": 218, "column": 4}, "end_point": {"row": 218, "column": 25}}, {"id": 884, "type": "identifier", "text": "scroll", "parent": 883, "children": [], "start_point": {"row": 218, "column": 4}, "end_point": {"row": 218, "column": 10}}, {"id": 885, "type": "=", "text": "=", "parent": 883, "children": [], "start_point": {"row": 218, "column": 11}, "end_point": {"row": 218, "column": 12}}, {"id": 886, "type": "field_expression", "text": "scroll->next", "parent": 883, "children": [887, 888], "start_point": {"row": 218, "column": 13}, "end_point": {"row": 218, "column": 25}}, {"id": 887, "type": "identifier", "text": "scroll", "parent": 886, "children": [], "start_point": {"row": 218, "column": 13}, "end_point": {"row": 218, "column": 19}}, {"id": 888, "type": "field_identifier", "text": "next", "parent": 886, "children": [], "start_point": {"row": 218, "column": 21}, "end_point": {"row": 218, "column": 25}}, {"id": 889, "type": "assignment_expression", "text": "newBlock = Gerency.CurrentPointerHeap", "parent": 562, "children": [890, 891, 892], "start_point": {"row": 221, "column": 3}, "end_point": {"row": 221, "column": 40}}, {"id": 890, "type": "identifier", "text": "newBlock", "parent": 889, "children": [], "start_point": {"row": 221, "column": 3}, "end_point": {"row": 221, "column": 11}}, {"id": 891, "type": "=", "text": "=", "parent": 889, "children": [], "start_point": {"row": 221, "column": 12}, "end_point": {"row": 221, "column": 13}}, {"id": 892, "type": "field_expression", "text": "Gerency.CurrentPointerHeap", "parent": 889, "children": [893, 894], "start_point": {"row": 221, "column": 14}, "end_point": {"row": 221, "column": 40}}, {"id": 893, "type": "identifier", "text": "Gerency", "parent": 892, "children": [], "start_point": {"row": 221, "column": 14}, "end_point": {"row": 221, "column": 21}}, {"id": 894, "type": "field_identifier", "text": "CurrentPointerHeap", "parent": 892, "children": [], "start_point": {"row": 221, "column": 22}, "end_point": {"row": 221, "column": 40}}, {"id": 895, "type": "assignment_expression", "text": "newBlock->Info.Field.free = 0", "parent": 562, "children": [896, 903, 904], "start_point": {"row": 222, "column": 3}, "end_point": {"row": 222, "column": 32}}, {"id": 896, "type": "field_expression", "text": "newBlock->Info.Field.free", "parent": 895, "children": [897, 902], "start_point": {"row": 222, "column": 3}, "end_point": {"row": 222, "column": 28}}, {"id": 897, "type": "field_expression", "text": "newBlock->Info.Field", "parent": 896, "children": [898, 901], "start_point": {"row": 222, "column": 3}, "end_point": {"row": 222, "column": 23}}, {"id": 898, "type": "field_expression", "text": "newBlock->Info", "parent": 897, "children": [899, 900], "start_point": {"row": 222, "column": 3}, "end_point": {"row": 222, "column": 17}}, {"id": 899, "type": "identifier", "text": "newBlock", "parent": 898, "children": [], "start_point": {"row": 222, "column": 3}, "end_point": {"row": 222, "column": 11}}, {"id": 900, "type": "field_identifier", "text": "Info", "parent": 898, "children": [], "start_point": {"row": 222, "column": 13}, "end_point": {"row": 222, "column": 17}}, {"id": 901, "type": "field_identifier", "text": "Field", "parent": 897, "children": [], "start_point": {"row": 222, "column": 18}, "end_point": {"row": 222, "column": 23}}, {"id": 902, "type": "field_identifier", "text": "free", "parent": 896, "children": [], "start_point": {"row": 222, "column": 24}, "end_point": {"row": 222, "column": 28}}, {"id": 903, "type": "=", "text": "=", "parent": 895, "children": [], "start_point": {"row": 222, "column": 29}, "end_point": {"row": 222, "column": 30}}, {"id": 904, "type": "number_literal", "text": "0", "parent": 895, "children": [], "start_point": {"row": 222, "column": 31}, "end_point": {"row": 222, "column": 32}}, {"id": 905, "type": "assignment_expression", "text": "newBlock->Info.Field.size = size", "parent": 562, "children": [906, 913, 914], "start_point": {"row": 223, "column": 3}, "end_point": {"row": 223, "column": 35}}, {"id": 906, "type": "field_expression", "text": "newBlock->Info.Field.size", "parent": 905, "children": [907, 912], "start_point": {"row": 223, "column": 3}, "end_point": {"row": 223, "column": 28}}, {"id": 907, "type": "field_expression", "text": "newBlock->Info.Field", "parent": 906, "children": [908, 911], "start_point": {"row": 223, "column": 3}, "end_point": {"row": 223, "column": 23}}, {"id": 908, "type": "field_expression", "text": "newBlock->Info", "parent": 907, "children": [909, 910], "start_point": {"row": 223, "column": 3}, "end_point": {"row": 223, "column": 17}}, {"id": 909, "type": "identifier", "text": "newBlock", "parent": 908, "children": [], "start_point": {"row": 223, "column": 3}, "end_point": {"row": 223, "column": 11}}, {"id": 910, "type": "field_identifier", "text": "Info", "parent": 908, "children": [], "start_point": {"row": 223, "column": 13}, "end_point": {"row": 223, "column": 17}}, {"id": 911, "type": "field_identifier", "text": "Field", "parent": 907, "children": [], "start_point": {"row": 223, "column": 18}, "end_point": {"row": 223, "column": 23}}, {"id": 912, "type": "field_identifier", "text": "size", "parent": 906, "children": [], "start_point": {"row": 223, "column": 24}, "end_point": {"row": 223, "column": 28}}, {"id": 913, "type": "=", "text": "=", "parent": 905, "children": [], "start_point": {"row": 223, "column": 29}, "end_point": {"row": 223, "column": 30}}, {"id": 914, "type": "identifier", "text": "size", "parent": 905, "children": [], "start_point": {"row": 223, "column": 31}, "end_point": {"row": 223, "column": 35}}, {"id": 915, "type": "assignment_expression", "text": "newBlock->id = numberBlocks", "parent": 562, "children": [916, 919, 920], "start_point": {"row": 224, "column": 3}, "end_point": {"row": 224, "column": 30}}, {"id": 916, "type": "field_expression", "text": "newBlock->id", "parent": 915, "children": [917, 918], "start_point": {"row": 224, "column": 3}, "end_point": {"row": 224, "column": 15}}, {"id": 917, "type": "identifier", "text": "newBlock", "parent": 916, "children": [], "start_point": {"row": 224, "column": 3}, "end_point": {"row": 224, "column": 11}}, {"id": 918, "type": "field_identifier", "text": "id", "parent": 916, "children": [], "start_point": {"row": 224, "column": 13}, "end_point": {"row": 224, "column": 15}}, {"id": 919, "type": "=", "text": "=", "parent": 915, "children": [], "start_point": {"row": 224, "column": 16}, "end_point": {"row": 224, "column": 17}}, {"id": 920, "type": "identifier", "text": "numberBlocks", "parent": 915, "children": [], "start_point": {"row": 224, "column": 18}, "end_point": {"row": 224, "column": 30}}, {"id": 921, "type": "assignment_expression", "text": "numberBlocks += 1", "parent": 562, "children": [922, 923, 924], "start_point": {"row": 225, "column": 3}, "end_point": {"row": 225, "column": 20}}, {"id": 922, "type": "identifier", "text": "numberBlocks", "parent": 921, "children": [], "start_point": {"row": 225, "column": 3}, "end_point": {"row": 225, "column": 15}}, {"id": 923, "type": "+=", "text": "+=", "parent": 921, "children": [], "start_point": {"row": 225, "column": 16}, "end_point": {"row": 225, "column": 18}}, {"id": 924, "type": "number_literal", "text": "1", "parent": 921, "children": [], "start_point": {"row": 225, "column": 19}, "end_point": {"row": 225, "column": 20}}, {"id": 925, "type": "if_statement", "text": "if(scroll == *(Gerency.ListBlocks) )\n\t\t\t{\n\t\t\t\tnewBlock->next = *(Gerency.ListBlocks);\n\t\t\t\t*(Gerency.ListBlocks) = newBlock;\n\t\t\t}\n\t\t\t\n\t\t\telse\n\t\t\t{\n\t\t\t\tnewBlock->next = previousScroll->next;\n\t\t\t\tpreviousScroll->next = newBlock;\n\t\t\t}", "parent": 562, "children": [926, 956], "start_point": {"row": 227, "column": 3}, "end_point": {"row": 237, "column": 4}}, {"id": 926, "type": "parenthesized_expression", "text": "(scroll == *(Gerency.ListBlocks) )", "parent": 925, "children": [927], "start_point": {"row": 227, "column": 5}, "end_point": {"row": 227, "column": 39}}, {"id": 927, "type": "binary_expression", "text": "scroll == *(Gerency.ListBlocks)", "parent": 926, "children": [928, 929, 930], "start_point": {"row": 227, "column": 6}, "end_point": {"row": 227, "column": 37}}, {"id": 928, "type": "identifier", "text": "scroll", "parent": 927, "children": [], "start_point": {"row": 227, "column": 6}, "end_point": {"row": 227, "column": 12}}, {"id": 929, "type": "==", "text": "==", "parent": 927, "children": [], "start_point": {"row": 227, "column": 13}, "end_point": {"row": 227, "column": 15}}, {"id": 930, "type": "pointer_expression", "text": "*(Gerency.ListBlocks)", "parent": 927, "children": [931, 932], "start_point": {"row": 227, "column": 16}, "end_point": {"row": 227, "column": 37}}, {"id": 931, "type": "*", "text": "*", "parent": 930, "children": [], "start_point": {"row": 227, "column": 16}, "end_point": {"row": 227, "column": 17}}, {"id": 932, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 930, "children": [933], "start_point": {"row": 227, "column": 17}, "end_point": {"row": 227, "column": 37}}, {"id": 933, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 932, "children": [934, 935], "start_point": {"row": 227, "column": 18}, "end_point": {"row": 227, "column": 36}}, {"id": 934, "type": "identifier", "text": "Gerency", "parent": 933, "children": [], "start_point": {"row": 227, "column": 18}, "end_point": {"row": 227, "column": 25}}, {"id": 935, "type": "field_identifier", "text": "ListBlocks", "parent": 933, "children": [], "start_point": {"row": 227, "column": 26}, "end_point": {"row": 227, "column": 36}}, {"id": 936, "type": "assignment_expression", "text": "newBlock->next = *(Gerency.ListBlocks)", "parent": 925, "children": [937, 940, 941], "start_point": {"row": 229, "column": 4}, "end_point": {"row": 229, "column": 42}}, {"id": 937, "type": "field_expression", "text": "newBlock->next", "parent": 936, "children": [938, 939], "start_point": {"row": 229, "column": 4}, "end_point": {"row": 229, "column": 18}}, {"id": 938, "type": "identifier", "text": "newBlock", "parent": 937, "children": [], "start_point": {"row": 229, "column": 4}, "end_point": {"row": 229, "column": 12}}, {"id": 939, "type": "field_identifier", "text": "next", "parent": 937, "children": [], "start_point": {"row": 229, "column": 14}, "end_point": {"row": 229, "column": 18}}, {"id": 940, "type": "=", "text": "=", "parent": 936, "children": [], "start_point": {"row": 229, "column": 19}, "end_point": {"row": 229, "column": 20}}, {"id": 941, "type": "pointer_expression", "text": "*(Gerency.ListBlocks)", "parent": 936, "children": [942, 943], "start_point": {"row": 229, "column": 21}, "end_point": {"row": 229, "column": 42}}, {"id": 942, "type": "*", "text": "*", "parent": 941, "children": [], "start_point": {"row": 229, "column": 21}, "end_point": {"row": 229, "column": 22}}, {"id": 943, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 941, "children": [944], "start_point": {"row": 229, "column": 22}, "end_point": {"row": 229, "column": 42}}, {"id": 944, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 943, "children": [945, 946], "start_point": {"row": 229, "column": 23}, "end_point": {"row": 229, "column": 41}}, {"id": 945, "type": "identifier", "text": "Gerency", "parent": 944, "children": [], "start_point": {"row": 229, "column": 23}, "end_point": {"row": 229, "column": 30}}, {"id": 946, "type": "field_identifier", "text": "ListBlocks", "parent": 944, "children": [], "start_point": {"row": 229, "column": 31}, "end_point": {"row": 229, "column": 41}}, {"id": 947, "type": "assignment_expression", "text": "*(Gerency.ListBlocks) = newBlock", "parent": 925, "children": [948, 954, 955], "start_point": {"row": 230, "column": 4}, "end_point": {"row": 230, "column": 36}}, {"id": 948, "type": "pointer_expression", "text": "*(Gerency.ListBlocks)", "parent": 947, "children": [949, 950], "start_point": {"row": 230, "column": 4}, "end_point": {"row": 230, "column": 25}}, {"id": 949, "type": "*", "text": "*", "parent": 948, "children": [], "start_point": {"row": 230, "column": 4}, "end_point": {"row": 230, "column": 5}}, {"id": 950, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 948, "children": [951], "start_point": {"row": 230, "column": 5}, "end_point": {"row": 230, "column": 25}}, {"id": 951, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 950, "children": [952, 953], "start_point": {"row": 230, "column": 6}, "end_point": {"row": 230, "column": 24}}, {"id": 952, "type": "identifier", "text": "Gerency", "parent": 951, "children": [], "start_point": {"row": 230, "column": 6}, "end_point": {"row": 230, "column": 13}}, {"id": 953, "type": "field_identifier", "text": "ListBlocks", "parent": 951, "children": [], "start_point": {"row": 230, "column": 14}, "end_point": {"row": 230, "column": 24}}, {"id": 954, "type": "=", "text": "=", "parent": 947, "children": [], "start_point": {"row": 230, "column": 26}, "end_point": {"row": 230, "column": 27}}, {"id": 955, "type": "identifier", "text": "newBlock", "parent": 947, "children": [], "start_point": {"row": 230, "column": 28}, "end_point": {"row": 230, "column": 36}}, {"id": 956, "type": "else_clause", "text": "else\n\t\t\t{\n\t\t\t\tnewBlock->next = previousScroll->next;\n\t\t\t\tpreviousScroll->next = newBlock;\n\t\t\t}", "parent": 925, "children": [], "start_point": {"row": 233, "column": 3}, "end_point": {"row": 237, "column": 4}}, {"id": 957, "type": "assignment_expression", "text": "newBlock->next = previousScroll->next", "parent": 956, "children": [958, 961, 962], "start_point": {"row": 235, "column": 4}, "end_point": {"row": 235, "column": 41}}, {"id": 958, "type": "field_expression", "text": "newBlock->next", "parent": 957, "children": [959, 960], "start_point": {"row": 235, "column": 4}, "end_point": {"row": 235, "column": 18}}, {"id": 959, "type": "identifier", "text": "newBlock", "parent": 958, "children": [], "start_point": {"row": 235, "column": 4}, "end_point": {"row": 235, "column": 12}}, {"id": 960, "type": "field_identifier", "text": "next", "parent": 958, "children": [], "start_point": {"row": 235, "column": 14}, "end_point": {"row": 235, "column": 18}}, {"id": 961, "type": "=", "text": "=", "parent": 957, "children": [], "start_point": {"row": 235, "column": 19}, "end_point": {"row": 235, "column": 20}}, {"id": 962, "type": "field_expression", "text": "previousScroll->next", "parent": 957, "children": [963, 964], "start_point": {"row": 235, "column": 21}, "end_point": {"row": 235, "column": 41}}, {"id": 963, "type": "identifier", "text": "previousScroll", "parent": 962, "children": [], "start_point": {"row": 235, "column": 21}, "end_point": {"row": 235, "column": 35}}, {"id": 964, "type": "field_identifier", "text": "next", "parent": 962, "children": [], "start_point": {"row": 235, "column": 37}, "end_point": {"row": 235, "column": 41}}, {"id": 965, "type": "assignment_expression", "text": "previousScroll->next = newBlock", "parent": 956, "children": [966, 969, 970], "start_point": {"row": 236, "column": 4}, "end_point": {"row": 236, "column": 35}}, {"id": 966, "type": "field_expression", "text": "previousScroll->next", "parent": 965, "children": [967, 968], "start_point": {"row": 236, "column": 4}, "end_point": {"row": 236, "column": 24}}, {"id": 967, "type": "identifier", "text": "previousScroll", "parent": 966, "children": [], "start_point": {"row": 236, "column": 4}, "end_point": {"row": 236, "column": 18}}, {"id": 968, "type": "field_identifier", "text": "next", "parent": 966, "children": [], "start_point": {"row": 236, "column": 20}, "end_point": {"row": 236, "column": 24}}, {"id": 969, "type": "=", "text": "=", "parent": 965, "children": [], "start_point": {"row": 236, "column": 25}, "end_point": {"row": 236, "column": 26}}, {"id": 970, "type": "identifier", "text": "newBlock", "parent": 965, "children": [], "start_point": {"row": 236, "column": 27}, "end_point": {"row": 236, "column": 35}}, {"id": 971, "type": "assignment_expression", "text": "Gerency.CurrentPointerHeap += ((sizeof(struct Block) + size))", "parent": 562, "children": [972, 975, 976], "start_point": {"row": 239, "column": 3}, "end_point": {"row": 239, "column": 64}}, {"id": 972, "type": "field_expression", "text": "Gerency.CurrentPointerHeap", "parent": 971, "children": [973, 974], "start_point": {"row": 239, "column": 3}, "end_point": {"row": 239, "column": 29}}, {"id": 973, "type": "identifier", "text": "Gerency", "parent": 972, "children": [], "start_point": {"row": 239, "column": 3}, "end_point": {"row": 239, "column": 10}}, {"id": 974, "type": "field_identifier", "text": "CurrentPointerHeap", "parent": 972, "children": [], "start_point": {"row": 239, "column": 11}, "end_point": {"row": 239, "column": 29}}, {"id": 975, "type": "+=", "text": "+=", "parent": 971, "children": [], "start_point": {"row": 239, "column": 30}, "end_point": {"row": 239, "column": 32}}, {"id": 976, "type": "parenthesized_expression", "text": "((sizeof(struct Block) + size))", "parent": 971, "children": [977], "start_point": {"row": 239, "column": 33}, "end_point": {"row": 239, "column": 64}}, {"id": 977, "type": "parenthesized_expression", "text": "(sizeof(struct Block) + size)", "parent": 976, "children": [978], "start_point": {"row": 239, "column": 34}, "end_point": {"row": 239, "column": 63}}, {"id": 978, "type": "binary_expression", "text": "sizeof(struct Block) + size", "parent": 977, "children": [979, 984, 985], "start_point": {"row": 239, "column": 35}, "end_point": {"row": 239, "column": 62}}, {"id": 979, "type": "sizeof_expression", "text": "sizeof(struct Block)", "parent": 978, "children": [980], "start_point": {"row": 239, "column": 35}, "end_point": {"row": 239, "column": 55}}, {"id": 980, "type": "type_descriptor", "text": "struct Block", "parent": 979, "children": [981], "start_point": {"row": 239, "column": 42}, "end_point": {"row": 239, "column": 54}}, {"id": 981, "type": "struct_specifier", "text": "struct Block", "parent": 980, "children": [982, 983], "start_point": {"row": 239, "column": 42}, "end_point": {"row": 239, "column": 54}}, {"id": 982, "type": "struct", "text": "struct", "parent": 981, "children": [], "start_point": {"row": 239, "column": 42}, "end_point": {"row": 239, "column": 48}}, {"id": 983, "type": "type_identifier", "text": "Block", "parent": 981, "children": [], "start_point": {"row": 239, "column": 49}, "end_point": {"row": 239, "column": 54}}, {"id": 984, "type": "+", "text": "+", "parent": 978, "children": [], "start_point": {"row": 239, "column": 56}, "end_point": {"row": 239, "column": 57}}, {"id": 985, "type": "identifier", "text": "size", "parent": 978, "children": [], "start_point": {"row": 239, "column": 58}, "end_point": {"row": 239, "column": 62}}, {"id": 986, "type": "assignment_expression", "text": "memoryUsage += ((sizeof(struct Block) + size))", "parent": 562, "children": [987, 988, 989], "start_point": {"row": 240, "column": 3}, "end_point": {"row": 240, "column": 49}}, {"id": 987, "type": "identifier", "text": "memoryUsage", "parent": 986, "children": [], "start_point": {"row": 240, "column": 3}, "end_point": {"row": 240, "column": 14}}, {"id": 988, "type": "+=", "text": "+=", "parent": 986, "children": [], "start_point": {"row": 240, "column": 15}, "end_point": {"row": 240, "column": 17}}, {"id": 989, "type": "parenthesized_expression", "text": "((sizeof(struct Block) + size))", "parent": 986, "children": [990], "start_point": {"row": 240, "column": 18}, "end_point": {"row": 240, "column": 49}}, {"id": 990, "type": "parenthesized_expression", "text": "(sizeof(struct Block) + size)", "parent": 989, "children": [991], "start_point": {"row": 240, "column": 19}, "end_point": {"row": 240, "column": 48}}, {"id": 991, "type": "binary_expression", "text": "sizeof(struct Block) + size", "parent": 990, "children": [992, 997, 998], "start_point": {"row": 240, "column": 20}, "end_point": {"row": 240, "column": 47}}, {"id": 992, "type": "sizeof_expression", "text": "sizeof(struct Block)", "parent": 991, "children": [993], "start_point": {"row": 240, "column": 20}, "end_point": {"row": 240, "column": 40}}, {"id": 993, "type": "type_descriptor", "text": "struct Block", "parent": 992, "children": [994], "start_point": {"row": 240, "column": 27}, "end_point": {"row": 240, "column": 39}}, {"id": 994, "type": "struct_specifier", "text": "struct Block", "parent": 993, "children": [995, 996], "start_point": {"row": 240, "column": 27}, "end_point": {"row": 240, "column": 39}}, {"id": 995, "type": "struct", "text": "struct", "parent": 994, "children": [], "start_point": {"row": 240, "column": 27}, "end_point": {"row": 240, "column": 33}}, {"id": 996, "type": "type_identifier", "text": "Block", "parent": 994, "children": [], "start_point": {"row": 240, "column": 34}, "end_point": {"row": 240, "column": 39}}, {"id": 997, "type": "+", "text": "+", "parent": 991, "children": [], "start_point": {"row": 240, "column": 41}, "end_point": {"row": 240, "column": 42}}, {"id": 998, "type": "identifier", "text": "size", "parent": 991, "children": [], "start_point": {"row": 240, "column": 43}, "end_point": {"row": 240, "column": 47}}, {"id": 999, "type": "return_statement", "text": "return (newBlock + 1);", "parent": 308, "children": [1000], "start_point": {"row": 244, "column": 1}, "end_point": {"row": 244, "column": 23}}, {"id": 1000, "type": "parenthesized_expression", "text": "(newBlock + 1)", "parent": 999, "children": [1001], "start_point": {"row": 244, "column": 8}, "end_point": {"row": 244, "column": 22}}, {"id": 1001, "type": "binary_expression", "text": "newBlock + 1", "parent": 1000, "children": [1002, 1003, 1004], "start_point": {"row": 244, "column": 9}, "end_point": {"row": 244, "column": 21}}, {"id": 1002, "type": "identifier", "text": "newBlock", "parent": 1001, "children": [], "start_point": {"row": 244, "column": 9}, "end_point": {"row": 244, "column": 17}}, {"id": 1003, "type": "+", "text": "+", "parent": 1001, "children": [], "start_point": {"row": 244, "column": 18}, "end_point": {"row": 244, "column": 19}}, {"id": 1004, "type": "number_literal", "text": "1", "parent": 1001, "children": [], "start_point": {"row": 244, "column": 20}, "end_point": {"row": 244, "column": 21}}, {"id": 1005, "type": "function_definition", "text": "void* myCalloc(unsigned int length, unsigned int size)\n{\n\n}", "parent": null, "children": [1006, 1007], "start_point": {"row": 247, "column": 0}, "end_point": {"row": 250, "column": 1}}, {"id": 1006, "type": "primitive_type", "text": "void", "parent": 1005, "children": [], "start_point": {"row": 247, "column": 0}, "end_point": {"row": 247, "column": 4}}, {"id": 1007, "type": "pointer_declarator", "text": "* myCalloc(unsigned int length, unsigned int size)", "parent": 1005, "children": [1008, 1009], "start_point": {"row": 247, "column": 4}, "end_point": {"row": 247, "column": 54}}, {"id": 1008, "type": "*", "text": "*", "parent": 1007, "children": [], "start_point": {"row": 247, "column": 4}, "end_point": {"row": 247, "column": 5}}, {"id": 1009, "type": "function_declarator", "text": "myCalloc(unsigned int length, unsigned int size)", "parent": 1007, "children": [1010, 1011], "start_point": {"row": 247, "column": 6}, "end_point": {"row": 247, "column": 54}}, {"id": 1010, "type": "identifier", "text": "myCalloc", "parent": 1009, "children": [], "start_point": {"row": 247, "column": 6}, "end_point": {"row": 247, "column": 14}}, {"id": 1011, "type": "parameter_list", "text": "(unsigned int length, unsigned int size)", "parent": 1009, "children": [1012, 1017], "start_point": {"row": 247, "column": 14}, "end_point": {"row": 247, "column": 54}}, {"id": 1012, "type": "parameter_declaration", "text": "unsigned int length", "parent": 1011, "children": [1013, 1016], "start_point": {"row": 247, "column": 15}, "end_point": {"row": 247, "column": 34}}, {"id": 1013, "type": "sized_type_specifier", "text": "unsigned int", "parent": 1012, "children": [1014, 1015], "start_point": {"row": 247, "column": 15}, "end_point": {"row": 247, "column": 27}}, {"id": 1014, "type": "unsigned", "text": "unsigned", "parent": 1013, "children": [], "start_point": {"row": 247, "column": 15}, "end_point": {"row": 247, "column": 23}}, {"id": 1015, "type": "primitive_type", "text": "int", "parent": 1013, "children": [], "start_point": {"row": 247, "column": 24}, "end_point": {"row": 247, "column": 27}}, {"id": 1016, "type": "identifier", "text": "length", "parent": 1012, "children": [], "start_point": {"row": 247, "column": 28}, "end_point": {"row": 247, "column": 34}}, {"id": 1017, "type": "parameter_declaration", "text": "unsigned int size", "parent": 1011, "children": [1018, 1021], "start_point": {"row": 247, "column": 36}, "end_point": {"row": 247, "column": 53}}, {"id": 1018, "type": "sized_type_specifier", "text": "unsigned int", "parent": 1017, "children": [1019, 1020], "start_point": {"row": 247, "column": 36}, "end_point": {"row": 247, "column": 48}}, {"id": 1019, "type": "unsigned", "text": "unsigned", "parent": 1018, "children": [], "start_point": {"row": 247, "column": 36}, "end_point": {"row": 247, "column": 44}}, {"id": 1020, "type": "primitive_type", "text": "int", "parent": 1018, "children": [], "start_point": {"row": 247, "column": 45}, "end_point": {"row": 247, "column": 48}}, {"id": 1021, "type": "identifier", "text": "size", "parent": 1017, "children": [], "start_point": {"row": 247, "column": 49}, "end_point": {"row": 247, "column": 53}}, {"id": 1022, "type": "function_definition", "text": "int myMallocFree(void* ptr)\n{\n\tBlock releaseBlock;\n\n\treleaseBlock = getHeader(ptr);\n\treleaseBlock->Info.Field.free = 1;\n\n\tif(Gerency.LastBlockReleased == NULL)\n\t{\n\t\tGerency.LastBlockReleased = releaseBlock;\n\t}\n\tnumberFreeBlocks += 1;\n}", "parent": null, "children": [1023, 1024], "start_point": {"row": 252, "column": 0}, "end_point": {"row": 264, "column": 1}}, {"id": 1023, "type": "primitive_type", "text": "int", "parent": 1022, "children": [], "start_point": {"row": 252, "column": 0}, "end_point": {"row": 252, "column": 3}}, {"id": 1024, "type": "function_declarator", "text": "myMallocFree(void* ptr)", "parent": 1022, "children": [1025, 1026], "start_point": {"row": 252, "column": 4}, "end_point": {"row": 252, "column": 27}}, {"id": 1025, "type": "identifier", "text": "myMallocFree", "parent": 1024, "children": [], "start_point": {"row": 252, "column": 4}, "end_point": {"row": 252, "column": 16}}, {"id": 1026, "type": "parameter_list", "text": "(void* ptr)", "parent": 1024, "children": [1027], "start_point": {"row": 252, "column": 16}, "end_point": {"row": 252, "column": 27}}, {"id": 1027, "type": "parameter_declaration", "text": "void* ptr", "parent": 1026, "children": [1028, 1029], "start_point": {"row": 252, "column": 17}, "end_point": {"row": 252, "column": 26}}, {"id": 1028, "type": "primitive_type", "text": "void", "parent": 1027, "children": [], "start_point": {"row": 252, "column": 17}, "end_point": {"row": 252, "column": 21}}, {"id": 1029, "type": "pointer_declarator", "text": "* ptr", "parent": 1027, "children": [1030, 1031], "start_point": {"row": 252, "column": 21}, "end_point": {"row": 252, "column": 26}}, {"id": 1030, "type": "*", "text": "*", "parent": 1029, "children": [], "start_point": {"row": 252, "column": 21}, "end_point": {"row": 252, "column": 22}}, {"id": 1031, "type": "identifier", "text": "ptr", "parent": 1029, "children": [], "start_point": {"row": 252, "column": 23}, "end_point": {"row": 252, "column": 26}}, {"id": 1032, "type": "declaration", "text": "Block releaseBlock;", "parent": 1022, "children": [1033, 1034], "start_point": {"row": 254, "column": 1}, "end_point": {"row": 254, "column": 20}}, {"id": 1033, "type": "type_identifier", "text": "Block", "parent": 1032, "children": [], "start_point": {"row": 254, "column": 1}, "end_point": {"row": 254, "column": 6}}, {"id": 1034, "type": "identifier", "text": "releaseBlock", "parent": 1032, "children": [], "start_point": {"row": 254, "column": 7}, "end_point": {"row": 254, "column": 19}}, {"id": 1035, "type": "assignment_expression", "text": "releaseBlock = getHeader(ptr)", "parent": 1022, "children": [1036, 1037, 1038], "start_point": {"row": 256, "column": 1}, "end_point": {"row": 256, "column": 30}}, {"id": 1036, "type": "identifier", "text": "releaseBlock", "parent": 1035, "children": [], "start_point": {"row": 256, "column": 1}, "end_point": {"row": 256, "column": 13}}, {"id": 1037, "type": "=", "text": "=", "parent": 1035, "children": [], "start_point": {"row": 256, "column": 14}, "end_point": {"row": 256, "column": 15}}, {"id": 1038, "type": "call_expression", "text": "getHeader(ptr)", "parent": 1035, "children": [1039, 1040], "start_point": {"row": 256, "column": 16}, "end_point": {"row": 256, "column": 30}}, {"id": 1039, "type": "identifier", "text": "getHeader", "parent": 1038, "children": [], "start_point": {"row": 256, "column": 16}, "end_point": {"row": 256, "column": 25}}, {"id": 1040, "type": "argument_list", "text": "(ptr)", "parent": 1038, "children": [1041], "start_point": {"row": 256, "column": 25}, "end_point": {"row": 256, "column": 30}}, {"id": 1041, "type": "identifier", "text": "ptr", "parent": 1040, "children": [], "start_point": {"row": 256, "column": 26}, "end_point": {"row": 256, "column": 29}}, {"id": 1042, "type": "assignment_expression", "text": "releaseBlock->Info.Field.free = 1", "parent": 1022, "children": [1043, 1050, 1051], "start_point": {"row": 257, "column": 1}, "end_point": {"row": 257, "column": 34}}, {"id": 1043, "type": "field_expression", "text": "releaseBlock->Info.Field.free", "parent": 1042, "children": [1044, 1049], "start_point": {"row": 257, "column": 1}, "end_point": {"row": 257, "column": 30}}, {"id": 1044, "type": "field_expression", "text": "releaseBlock->Info.Field", "parent": 1043, "children": [1045, 1048], "start_point": {"row": 257, "column": 1}, "end_point": {"row": 257, "column": 25}}, {"id": 1045, "type": "field_expression", "text": "releaseBlock->Info", "parent": 1044, "children": [1046, 1047], "start_point": {"row": 257, "column": 1}, "end_point": {"row": 257, "column": 19}}, {"id": 1046, "type": "identifier", "text": "releaseBlock", "parent": 1045, "children": [], "start_point": {"row": 257, "column": 1}, "end_point": {"row": 257, "column": 13}}, {"id": 1047, "type": "field_identifier", "text": "Info", "parent": 1045, "children": [], "start_point": {"row": 257, "column": 15}, "end_point": {"row": 257, "column": 19}}, {"id": 1048, "type": "field_identifier", "text": "Field", "parent": 1044, "children": [], "start_point": {"row": 257, "column": 20}, "end_point": {"row": 257, "column": 25}}, {"id": 1049, "type": "field_identifier", "text": "free", "parent": 1043, "children": [], "start_point": {"row": 257, "column": 26}, "end_point": {"row": 257, "column": 30}}, {"id": 1050, "type": "=", "text": "=", "parent": 1042, "children": [], "start_point": {"row": 257, "column": 31}, "end_point": {"row": 257, "column": 32}}, {"id": 1051, "type": "number_literal", "text": "1", "parent": 1042, "children": [], "start_point": {"row": 257, "column": 33}, "end_point": {"row": 257, "column": 34}}, {"id": 1052, "type": "if_statement", "text": "if(Gerency.LastBlockReleased == NULL)\n\t{\n\t\tGerency.LastBlockReleased = releaseBlock;\n\t}", "parent": 1022, "children": [1053], "start_point": {"row": 259, "column": 1}, "end_point": {"row": 262, "column": 2}}, {"id": 1053, "type": "parenthesized_expression", "text": "(Gerency.LastBlockReleased == NULL)", "parent": 1052, "children": [1054], "start_point": {"row": 259, "column": 3}, "end_point": {"row": 259, "column": 38}}, {"id": 1054, "type": "binary_expression", "text": "Gerency.LastBlockReleased == NULL", "parent": 1053, "children": [1055, 1058, 1059], "start_point": {"row": 259, "column": 4}, "end_point": {"row": 259, "column": 37}}, {"id": 1055, "type": "field_expression", "text": "Gerency.LastBlockReleased", "parent": 1054, "children": [1056, 1057], "start_point": {"row": 259, "column": 4}, "end_point": {"row": 259, "column": 29}}, {"id": 1056, "type": "identifier", "text": "Gerency", "parent": 1055, "children": [], "start_point": {"row": 259, "column": 4}, "end_point": {"row": 259, "column": 11}}, {"id": 1057, "type": "field_identifier", "text": "LastBlockReleased", "parent": 1055, "children": [], "start_point": {"row": 259, "column": 12}, "end_point": {"row": 259, "column": 29}}, {"id": 1058, "type": "==", "text": "==", "parent": 1054, "children": [], "start_point": {"row": 259, "column": 30}, "end_point": {"row": 259, "column": 32}}, {"id": 1059, "type": "null", "text": "NULL", "parent": 1054, "children": [1060], "start_point": {"row": 259, "column": 33}, "end_point": {"row": 259, "column": 37}}, {"id": 1060, "type": "NULL", "text": "NULL", "parent": 1059, "children": [], "start_point": {"row": 259, "column": 33}, "end_point": {"row": 259, "column": 37}}, {"id": 1061, "type": "assignment_expression", "text": "Gerency.LastBlockReleased = releaseBlock", "parent": 1052, "children": [1062, 1065, 1066], "start_point": {"row": 261, "column": 2}, "end_point": {"row": 261, "column": 42}}, {"id": 1062, "type": "field_expression", "text": "Gerency.LastBlockReleased", "parent": 1061, "children": [1063, 1064], "start_point": {"row": 261, "column": 2}, "end_point": {"row": 261, "column": 27}}, {"id": 1063, "type": "identifier", "text": "Gerency", "parent": 1062, "children": [], "start_point": {"row": 261, "column": 2}, "end_point": {"row": 261, "column": 9}}, {"id": 1064, "type": "field_identifier", "text": "LastBlockReleased", "parent": 1062, "children": [], "start_point": {"row": 261, "column": 10}, "end_point": {"row": 261, "column": 27}}, {"id": 1065, "type": "=", "text": "=", "parent": 1061, "children": [], "start_point": {"row": 261, "column": 28}, "end_point": {"row": 261, "column": 29}}, {"id": 1066, "type": "identifier", "text": "releaseBlock", "parent": 1061, "children": [], "start_point": {"row": 261, "column": 30}, "end_point": {"row": 261, "column": 42}}, {"id": 1067, "type": "assignment_expression", "text": "numberFreeBlocks += 1", "parent": 1022, "children": [1068, 1069, 1070], "start_point": {"row": 263, "column": 1}, "end_point": {"row": 263, "column": 22}}, {"id": 1068, "type": "identifier", "text": "numberFreeBlocks", "parent": 1067, "children": [], "start_point": {"row": 263, "column": 1}, "end_point": {"row": 263, "column": 17}}, {"id": 1069, "type": "+=", "text": "+=", "parent": 1067, "children": [], "start_point": {"row": 263, "column": 18}, "end_point": {"row": 263, "column": 20}}, {"id": 1070, "type": "number_literal", "text": "1", "parent": 1067, "children": [], "start_point": {"row": 263, "column": 21}, "end_point": {"row": 263, "column": 22}}, {"id": 1071, "type": "function_definition", "text": "void __attribute__((destructor))Exit(void)\n{\n\tBlock p;\n\n\tprintf(\"Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes\\n\\n\", HEAP_SIZE, totalAllocatedMemory);\n\tprintf(\"Memory Usage: %u Bytes \\n\\n\",memoryUsage);\n\tprintf(\"Internal Fragmentation: %u Bytes \\n\\n\", numberFragmentation);\n\t\n\tforeach(p, (Gerency.ListBlocks))\n\t{\n\t\tprintf(\"Block ID: %u \", p->id);\n\t\tprintf(\"Size: %u \", BlockSize(p));\n\t\tprintf(\"Free: %s\\n\", isFreeBlock(p)?\"True\":\"False\");\n\t\tputs(\" \");\n\t}\n}", "parent": null, "children": [1072, 1073, 1077], "start_point": {"row": 266, "column": 0}, "end_point": {"row": 281, "column": 1}}, {"id": 1072, "type": "primitive_type", "text": "void", "parent": 1071, "children": [], "start_point": {"row": 266, "column": 0}, "end_point": {"row": 266, "column": 4}}, {"id": 1073, "type": "attribute_specifier", "text": "__attribute__((destructor))", "parent": 1071, "children": [1074, 1075], "start_point": {"row": 266, "column": 5}, "end_point": {"row": 266, "column": 32}}, {"id": 1074, "type": "__attribute__", "text": "__attribute__", "parent": 1073, "children": [], "start_point": {"row": 266, "column": 5}, "end_point": {"row": 266, "column": 18}}, {"id": 1075, "type": "argument_list", "text": "(destructor)", "parent": 1073, "children": [1076], "start_point": {"row": 266, "column": 19}, "end_point": {"row": 266, "column": 31}}, {"id": 1076, "type": "identifier", "text": "destructor", "parent": 1075, "children": [], "start_point": {"row": 266, "column": 20}, "end_point": {"row": 266, "column": 30}}, {"id": 1077, "type": "function_declarator", "text": "Exit(void)", "parent": 1071, "children": [1078, 1079], "start_point": {"row": 266, "column": 32}, "end_point": {"row": 266, "column": 42}}, {"id": 1078, "type": "identifier", "text": "Exit", "parent": 1077, "children": [], "start_point": {"row": 266, "column": 32}, "end_point": {"row": 266, "column": 36}}, {"id": 1079, "type": "parameter_list", "text": "(void)", "parent": 1077, "children": [1080], "start_point": {"row": 266, "column": 36}, "end_point": {"row": 266, "column": 42}}, {"id": 1080, "type": "parameter_declaration", "text": "void", "parent": 1079, "children": [1081], "start_point": {"row": 266, "column": 37}, "end_point": {"row": 266, "column": 41}}, {"id": 1081, "type": "primitive_type", "text": "void", "parent": 1080, "children": [], "start_point": {"row": 266, "column": 37}, "end_point": {"row": 266, "column": 41}}, {"id": 1082, "type": "declaration", "text": "Block p;", "parent": 1071, "children": [1083, 1084], "start_point": {"row": 268, "column": 1}, "end_point": {"row": 268, "column": 9}}, {"id": 1083, "type": "type_identifier", "text": "Block", "parent": 1082, "children": [], "start_point": {"row": 268, "column": 1}, "end_point": {"row": 268, "column": 6}}, {"id": 1084, "type": "identifier", "text": "p", "parent": 1082, "children": [], "start_point": {"row": 268, "column": 7}, "end_point": {"row": 268, "column": 8}}, {"id": 1085, "type": "call_expression", "text": "printf(\"Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes\\n\\n\", HEAP_SIZE, totalAllocatedMemory)", "parent": 1071, "children": [1086, 1087], "start_point": {"row": 270, "column": 1}, "end_point": {"row": 270, "column": 117}}, {"id": 1086, "type": "identifier", "text": "printf", "parent": 1085, "children": [], "start_point": {"row": 270, "column": 1}, "end_point": {"row": 270, "column": 7}}, {"id": 1087, "type": "argument_list", "text": "(\"Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes\\n\\n\", HEAP_SIZE, totalAllocatedMemory)", "parent": 1085, "children": [1088, 1091, 1092], "start_point": {"row": 270, "column": 7}, "end_point": {"row": 270, "column": 117}}, {"id": 1088, "type": "string_literal", "text": "\"Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes\\n\\n\"", "parent": 1087, "children": [1089, 1090], "start_point": {"row": 270, "column": 8}, "end_point": {"row": 270, "column": 83}}, {"id": 1089, "type": "escape_sequence", "text": "\\n", "parent": 1088, "children": [], "start_point": {"row": 270, "column": 78}, "end_point": {"row": 270, "column": 80}}, {"id": 1090, "type": "escape_sequence", "text": "\\n", "parent": 1088, "children": [], "start_point": {"row": 270, "column": 80}, "end_point": {"row": 270, "column": 82}}, {"id": 1091, "type": "identifier", "text": "HEAP_SIZE", "parent": 1087, "children": [], "start_point": {"row": 270, "column": 85}, "end_point": {"row": 270, "column": 94}}, {"id": 1092, "type": "identifier", "text": "totalAllocatedMemory", "parent": 1087, "children": [], "start_point": {"row": 270, "column": 96}, "end_point": {"row": 270, "column": 116}}, {"id": 1093, "type": "call_expression", "text": "printf(\"Memory Usage: %u Bytes \\n\\n\",memoryUsage)", "parent": 1071, "children": [1094, 1095], "start_point": {"row": 271, "column": 1}, "end_point": {"row": 271, "column": 50}}, {"id": 1094, "type": "identifier", "text": "printf", "parent": 1093, "children": [], "start_point": {"row": 271, "column": 1}, "end_point": {"row": 271, "column": 7}}, {"id": 1095, "type": "argument_list", "text": "(\"Memory Usage: %u Bytes \\n\\n\",memoryUsage)", "parent": 1093, "children": [1096, 1099], "start_point": {"row": 271, "column": 7}, "end_point": {"row": 271, "column": 50}}, {"id": 1096, "type": "string_literal", "text": "\"Memory Usage: %u Bytes \\n\\n\"", "parent": 1095, "children": [1097, 1098], "start_point": {"row": 271, "column": 8}, "end_point": {"row": 271, "column": 37}}, {"id": 1097, "type": "escape_sequence", "text": "\\n", "parent": 1096, "children": [], "start_point": {"row": 271, "column": 32}, "end_point": {"row": 271, "column": 34}}, {"id": 1098, "type": "escape_sequence", "text": "\\n", "parent": 1096, "children": [], "start_point": {"row": 271, "column": 34}, "end_point": {"row": 271, "column": 36}}, {"id": 1099, "type": "identifier", "text": "memoryUsage", "parent": 1095, "children": [], "start_point": {"row": 271, "column": 38}, "end_point": {"row": 271, "column": 49}}, {"id": 1100, "type": "call_expression", "text": "printf(\"Internal Fragmentation: %u Bytes \\n\\n\", numberFragmentation)", "parent": 1071, "children": [1101, 1102], "start_point": {"row": 272, "column": 1}, "end_point": {"row": 272, "column": 69}}, {"id": 1101, "type": "identifier", "text": "printf", "parent": 1100, "children": [], "start_point": {"row": 272, "column": 1}, "end_point": {"row": 272, "column": 7}}, {"id": 1102, "type": "argument_list", "text": "(\"Internal Fragmentation: %u Bytes \\n\\n\", numberFragmentation)", "parent": 1100, "children": [1103, 1106], "start_point": {"row": 272, "column": 7}, "end_point": {"row": 272, "column": 69}}, {"id": 1103, "type": "string_literal", "text": "\"Internal Fragmentation: %u Bytes \\n\\n\"", "parent": 1102, "children": [1104, 1105], "start_point": {"row": 272, "column": 8}, "end_point": {"row": 272, "column": 47}}, {"id": 1104, "type": "escape_sequence", "text": "\\n", "parent": 1103, "children": [], "start_point": {"row": 272, "column": 42}, "end_point": {"row": 272, "column": 44}}, {"id": 1105, "type": "escape_sequence", "text": "\\n", "parent": 1103, "children": [], "start_point": {"row": 272, "column": 44}, "end_point": {"row": 272, "column": 46}}, {"id": 1106, "type": "identifier", "text": "numberFragmentation", "parent": 1102, "children": [], "start_point": {"row": 272, "column": 49}, "end_point": {"row": 272, "column": 68}}, {"id": 1107, "type": "call_expression", "text": "foreach(p, (Gerency.ListBlocks))", "parent": 1071, "children": [1108, 1109], "start_point": {"row": 274, "column": 1}, "end_point": {"row": 274, "column": 33}}, {"id": 1108, "type": "identifier", "text": "foreach", "parent": 1107, "children": [], "start_point": {"row": 274, "column": 1}, "end_point": {"row": 274, "column": 8}}, {"id": 1109, "type": "argument_list", "text": "(p, (Gerency.ListBlocks))", "parent": 1107, "children": [1110, 1111], "start_point": {"row": 274, "column": 8}, "end_point": {"row": 274, "column": 33}}, {"id": 1110, "type": "identifier", "text": "p", "parent": 1109, "children": [], "start_point": {"row": 274, "column": 9}, "end_point": {"row": 274, "column": 10}}, {"id": 1111, "type": "parenthesized_expression", "text": "(Gerency.ListBlocks)", "parent": 1109, "children": [1112], "start_point": {"row": 274, "column": 12}, "end_point": {"row": 274, "column": 32}}, {"id": 1112, "type": "field_expression", "text": "Gerency.ListBlocks", "parent": 1111, "children": [1113, 1114], "start_point": {"row": 274, "column": 13}, "end_point": {"row": 274, "column": 31}}, {"id": 1113, "type": "identifier", "text": "Gerency", "parent": 1112, "children": [], "start_point": {"row": 274, "column": 13}, "end_point": {"row": 274, "column": 20}}, {"id": 1114, "type": "field_identifier", "text": "ListBlocks", "parent": 1112, "children": [], "start_point": {"row": 274, "column": 21}, "end_point": {"row": 274, "column": 31}}, {"id": 1115, "type": "call_expression", "text": "printf(\"Block ID: %u \", p->id)", "parent": 1071, "children": [1116, 1117], "start_point": {"row": 276, "column": 2}, "end_point": {"row": 276, "column": 32}}, {"id": 1116, "type": "identifier", "text": "printf", "parent": 1115, "children": [], "start_point": {"row": 276, "column": 2}, "end_point": {"row": 276, "column": 8}}, {"id": 1117, "type": "argument_list", "text": "(\"Block ID: %u \", p->id)", "parent": 1115, "children": [1118, 1119], "start_point": {"row": 276, "column": 8}, "end_point": {"row": 276, "column": 32}}, {"id": 1118, "type": "string_literal", "text": "\"Block ID: %u \"", "parent": 1117, "children": [], "start_point": {"row": 276, "column": 9}, "end_point": {"row": 276, "column": 24}}, {"id": 1119, "type": "field_expression", "text": "p->id", "parent": 1117, "children": [1120, 1121], "start_point": {"row": 276, "column": 26}, "end_point": {"row": 276, "column": 31}}, {"id": 1120, "type": "identifier", "text": "p", "parent": 1119, "children": [], "start_point": {"row": 276, "column": 26}, "end_point": {"row": 276, "column": 27}}, {"id": 1121, "type": "field_identifier", "text": "id", "parent": 1119, "children": [], "start_point": {"row": 276, "column": 29}, "end_point": {"row": 276, "column": 31}}, {"id": 1122, "type": "call_expression", "text": "printf(\"Size: %u \", BlockSize(p))", "parent": 1071, "children": [1123, 1124], "start_point": {"row": 277, "column": 2}, "end_point": {"row": 277, "column": 35}}, {"id": 1123, "type": "identifier", "text": "printf", "parent": 1122, "children": [], "start_point": {"row": 277, "column": 2}, "end_point": {"row": 277, "column": 8}}, {"id": 1124, "type": "argument_list", "text": "(\"Size: %u \", BlockSize(p))", "parent": 1122, "children": [1125, 1126], "start_point": {"row": 277, "column": 8}, "end_point": {"row": 277, "column": 35}}, {"id": 1125, "type": "string_literal", "text": "\"Size: %u \"", "parent": 1124, "children": [], "start_point": {"row": 277, "column": 9}, "end_point": {"row": 277, "column": 20}}, {"id": 1126, "type": "call_expression", "text": "BlockSize(p)", "parent": 1124, "children": [1127, 1128], "start_point": {"row": 277, "column": 22}, "end_point": {"row": 277, "column": 34}}, {"id": 1127, "type": "identifier", "text": "BlockSize", "parent": 1126, "children": [], "start_point": {"row": 277, "column": 22}, "end_point": {"row": 277, "column": 31}}, {"id": 1128, "type": "argument_list", "text": "(p)", "parent": 1126, "children": [1129], "start_point": {"row": 277, "column": 31}, "end_point": {"row": 277, "column": 34}}, {"id": 1129, "type": "identifier", "text": "p", "parent": 1128, "children": [], "start_point": {"row": 277, "column": 32}, "end_point": {"row": 277, "column": 33}}, {"id": 1130, "type": "call_expression", "text": "printf(\"Free: %s\\n\", isFreeBlock(p)?\"True\":\"False\")", "parent": 1071, "children": [1131, 1132], "start_point": {"row": 278, "column": 2}, "end_point": {"row": 278, "column": 53}}, {"id": 1131, "type": "identifier", "text": "printf", "parent": 1130, "children": [], "start_point": {"row": 278, "column": 2}, "end_point": {"row": 278, "column": 8}}, {"id": 1132, "type": "argument_list", "text": "(\"Free: %s\\n\", isFreeBlock(p)?\"True\":\"False\")", "parent": 1130, "children": [1133, 1135], "start_point": {"row": 278, "column": 8}, "end_point": {"row": 278, "column": 53}}, {"id": 1133, "type": "string_literal", "text": "\"Free: %s\\n\"", "parent": 1132, "children": [1134], "start_point": {"row": 278, "column": 9}, "end_point": {"row": 278, "column": 21}}, {"id": 1134, "type": "escape_sequence", "text": "\\n", "parent": 1133, "children": [], "start_point": {"row": 278, "column": 18}, "end_point": {"row": 278, "column": 20}}, {"id": 1135, "type": "conditional_expression", "text": "isFreeBlock(p)?\"True\":\"False\"", "parent": 1132, "children": [1136, 1140, 1141, 1142], "start_point": {"row": 278, "column": 23}, "end_point": {"row": 278, "column": 52}}, {"id": 1136, "type": "call_expression", "text": "isFreeBlock(p)", "parent": 1135, "children": [1137, 1138], "start_point": {"row": 278, "column": 23}, "end_point": {"row": 278, "column": 37}}, {"id": 1137, "type": "identifier", "text": "isFreeBlock", "parent": 1136, "children": [], "start_point": {"row": 278, "column": 23}, "end_point": {"row": 278, "column": 34}}, {"id": 1138, "type": "argument_list", "text": "(p)", "parent": 1136, "children": [1139], "start_point": {"row": 278, "column": 34}, "end_point": {"row": 278, "column": 37}}, {"id": 1139, "type": "identifier", "text": "p", "parent": 1138, "children": [], "start_point": {"row": 278, "column": 35}, "end_point": {"row": 278, "column": 36}}, {"id": 1140, "type": "?", "text": "?", "parent": 1135, "children": [], "start_point": {"row": 278, "column": 37}, "end_point": {"row": 278, "column": 38}}, {"id": 1141, "type": "string_literal", "text": "\"True\"", "parent": 1135, "children": [], "start_point": {"row": 278, "column": 38}, "end_point": {"row": 278, "column": 44}}, {"id": 1142, "type": "string_literal", "text": "\"False\"", "parent": 1135, "children": [], "start_point": {"row": 278, "column": 45}, "end_point": {"row": 278, "column": 52}}, {"id": 1143, "type": "call_expression", "text": "puts(\" \")", "parent": 1071, "children": [1144, 1145], "start_point": {"row": 279, "column": 2}, "end_point": {"row": 279, "column": 11}}, {"id": 1144, "type": "identifier", "text": "puts", "parent": 1143, "children": [], "start_point": {"row": 279, "column": 2}, "end_point": {"row": 279, "column": 6}}, {"id": 1145, "type": "argument_list", "text": "(\" \")", "parent": 1143, "children": [1146], "start_point": {"row": 279, "column": 6}, "end_point": {"row": 279, "column": 11}}, {"id": 1146, "type": "string_literal", "text": "\" \"", "parent": 1145, "children": [], "start_point": {"row": 279, "column": 7}, "end_point": {"row": 279, "column": 10}}]}, "node_categories": {"declarations": {"functions": [38, 44, 51, 57, 63, 177, 183, 308, 312, 1005, 1009, 1022, 1024, 1071, 1077], "variables": [69, 74, 81, 84, 89, 92, 98, 106, 114, 117, 122, 125, 130, 136, 141, 146, 151, 156, 161, 169, 186, 188, 315, 320, 323, 326, 329, 332, 335, 340, 346, 1012, 1017, 1027, 1032, 1080, 1082], "classes": [71, 72, 75, 76, 82, 83, 90, 91, 115, 116, 473, 474, 486, 487, 981, 982, 994, 995], "imports": [0, 1, 3, 4, 6, 7, 9, 10, 12, 13, 15, 16, 18, 19, 21, 22, 24, 25, 27, 28], "modules": [], "enums": [170, 171]}, "statements": {"expressions": [193, 200, 204, 211, 214, 221, 225, 228, 230, 231, 234, 241, 245, 252, 255, 256, 261, 262, 264, 267, 269, 270, 273, 280, 282, 283, 290, 301, 305, 355, 360, 361, 362, 363, 364, 368, 369, 378, 379, 380, 381, 382, 383, 389, 399, 400, 401, 402, 404, 405, 414, 418, 425, 426, 427, 435, 436, 437, 445, 451, 453, 454, 464, 468, 469, 470, 471, 481, 482, 483, 484, 493, 494, 495, 496, 497, 504, 505, 506, 507, 508, 511, 512, 522, 526, 527, 528, 536, 545, 546, 557, 558, 565, 572, 576, 577, 581, 582, 583, 584, 585, 592, 593, 598, 599, 600, 614, 615, 622, 623, 635, 636, 639, 640, 642, 643, 651, 653, 654, 657, 661, 667, 668, 675, 676, 677, 678, 683, 684, 685, 686, 691, 692, 705, 706, 714, 715, 720, 721, 722, 732, 733, 740, 741, 753, 754, 757, 758, 760, 761, 769, 771, 772, 775, 779, 780, 786, 787, 794, 795, 796, 797, 802, 803, 804, 805, 810, 811, 824, 825, 830, 831, 832, 840, 841, 855, 857, 858, 862, 863, 864, 865, 871, 872, 873, 886, 892, 896, 897, 898, 906, 907, 908, 916, 926, 927, 930, 932, 933, 937, 941, 943, 944, 948, 950, 951, 958, 962, 966, 972, 976, 977, 978, 979, 989, 990, 991, 992, 1000, 1001, 1038, 1043, 1044, 1045, 1053, 1054, 1055, 1062, 1085, 1093, 1100, 1107, 1111, 1112, 1115, 1119, 1122, 1126, 1130, 1136, 1143], "assignments": [199, 208, 218, 240, 249, 258, 279, 289, 296, 300, 352, 411, 417, 424, 434, 444, 450, 459, 463, 478, 519, 525, 535, 542, 552, 597, 607, 611, 632, 648, 664, 696, 700, 719, 729, 750, 766, 783, 815, 819, 829, 852, 879, 883, 889, 895, 905, 915, 921, 936, 947, 957, 965, 971, 986, 1035, 1042, 1061, 1067], "loops": [861], "conditionals": [30, 31, 32, 35, 37, 40, 42, 46, 48, 49, 53, 55, 59, 61, 65, 67, 73, 77, 80, 85, 88, 93, 95, 99, 101, 104, 105, 107, 110, 113, 121, 123, 124, 129, 131, 134, 135, 137, 140, 142, 145, 147, 150, 152, 155, 157, 160, 162, 166, 172, 174, 176, 179, 182, 184, 192, 194, 201, 202, 205, 209, 212, 215, 217, 219, 222, 224, 226, 232, 242, 243, 246, 250, 253, 257, 259, 263, 265, 271, 284, 285, 291, 292, 297, 302, 303, 306, 307, 313, 316, 319, 321, 322, 324, 325, 327, 328, 330, 331, 333, 334, 336, 339, 343, 349, 353, 356, 358, 359, 365, 366, 370, 371, 373, 377, 384, 385, 387, 394, 398, 406, 407, 412, 415, 416, 419, 420, 428, 429, 430, 431, 438, 439, 440, 441, 443, 446, 447, 449, 455, 456, 458, 460, 465, 466, 475, 477, 479, 488, 490, 492, 498, 499, 509, 513, 514, 516, 518, 520, 523, 524, 529, 530, 531, 532, 537, 538, 543, 547, 549, 551, 553, 559, 563, 564, 566, 567, 568, 569, 571, 573, 575, 578, 579, 580, 586, 588, 590, 594, 596, 601, 602, 603, 604, 608, 612, 616, 618, 620, 624, 629, 630, 631, 633, 637, 644, 645, 647, 649, 655, 656, 658, 660, 662, 663, 665, 669, 671, 673, 674, 679, 687, 689, 693, 695, 697, 699, 701, 703, 704, 707, 713, 716, 718, 723, 724, 725, 726, 730, 734, 736, 738, 742, 747, 748, 749, 751, 755, 762, 763, 765, 767, 773, 774, 776, 778, 781, 782, 784, 788, 790, 792, 793, 798, 806, 808, 812, 814, 816, 818, 820, 822, 823, 826, 828, 833, 834, 835, 836, 842, 847, 851, 853, 859, 860, 866, 874, 876, 878, 880, 882, 884, 887, 888, 890, 893, 894, 899, 900, 901, 902, 909, 910, 911, 912, 914, 917, 918, 920, 922, 925, 928, 934, 935, 938, 939, 945, 946, 952, 953, 955, 959, 960, 963, 964, 967, 968, 970, 973, 974, 983, 985, 987, 996, 998, 1002, 1010, 1013, 1016, 1018, 1021, 1025, 1031, 1033, 1034, 1036, 1039, 1041, 1046, 1047, 1048, 1049, 1052, 1056, 1057, 1063, 1064, 1066, 1068, 1073, 1076, 1078, 1083, 1084, 1086, 1091, 1092, 1094, 1099, 1101, 1106, 1108, 1110, 1113, 1114, 1116, 1120, 1121, 1123, 1127, 1129, 1131, 1135, 1137, 1139, 1144], "returns": [374, 395, 556, 621, 739, 839, 999], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 8, 11, 14, 17, 20, 23, 26, 29, 97, 103, 168, 196, 207, 239, 248, 278, 299, 345, 351, 433, 462, 534, 555, 561, 606, 610, 626, 681, 709, 728, 744, 800, 838, 844, 904, 924, 1004, 1051, 1070, 1088, 1096, 1103, 1118, 1125, 1133, 1141, 1142, 1146], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": [96, 102]}}, "cross_language_map": {"function_declarations": [{"node_id": 38, "universal_type": "function", "name": "unknown", "text_snippet": "#define ALIGN4(x) (((((x) - 1) >> 2) << 2) + 4)\n"}, {"node_id": 44, "universal_type": "function", "name": "unknown", "text_snippet": "#define foreach(ptr, List) for(ptr = *List; ptr != NULL; ptr = ptr->next)\n"}, {"node_id": 51, "universal_type": "function", "name": "unknown", "text_snippet": "#define getHeader(ptr) (((Block)ptr)-1);\n"}, {"node_id": 57, "universal_type": "function", "name": "unknown", "text_snippet": "#define BlockSize(ptr) (ptr->Info.Field.size)\n"}, {"node_id": 63, "universal_type": "function", "name": "unknown", "text_snippet": "#define isFreeBlock(ptr) (ptr->Info.Field.free)\n"}, {"node_id": 177, "universal_type": "function", "name": "__attribute__", "text_snippet": "static void __attribute__((constructor))InitMalloc(void)\n{\n\tvoid* response;\n\n\tputs(\"\\n\\n\");\n\n\tGerenc"}, {"node_id": 183, "universal_type": "function", "name": "unknown", "text_snippet": "InitMalloc(void)"}, {"node_id": 308, "universal_type": "function", "name": "size)", "text_snippet": "void* myMalloc(unsigned int size)\n{\n\tBlock newBlock;\n\tBlock scroll;\n\tBlock previousScroll;\n\tBlock en"}, {"node_id": 312, "universal_type": "function", "name": "size)", "text_snippet": "myMalloc(unsigned int size)"}, {"node_id": 1005, "universal_type": "function", "name": "length,", "text_snippet": "void* myCalloc(unsigned int length, unsigned int size)\n{\n\n}"}, {"node_id": 1009, "universal_type": "function", "name": "length,", "text_snippet": "myCalloc(unsigned int length, unsigned int size)"}, {"node_id": 1022, "universal_type": "function", "name": "myMallocFree", "text_snippet": "int myMallocFree(void* ptr)\n{\n\tBlock releaseBlock;\n\n\treleaseBlock = getHeader(ptr);\n\treleaseBlock->I"}, {"node_id": 1024, "universal_type": "function", "name": "unknown", "text_snippet": "myMallocFree(void* ptr)"}, {"node_id": 1071, "universal_type": "function", "name": "__attribute__", "text_snippet": "void __attribute__((destructor))Exit(void)\n{\n\tBlock p;\n\n\tprintf(\"Allocated memory for heap: %u Bytes"}, {"node_id": 1077, "universal_type": "function", "name": "unknown", "text_snippet": "Exit(void)"}], "class_declarations": [{"node_id": 71, "universal_type": "class", "name": "Block", "text_snippet": "struct Block\n{\n\tstruct Block* next;\n\n\tunion\n\t{\n\t\tunsigned int BlockInfo;\n\t\tstruct \n\t\t{\n\t\t\tunsigned s"}, {"node_id": 72, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 75, "universal_type": "class", "name": "Block", "text_snippet": "struct Block"}, {"node_id": 76, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 82, "universal_type": "class", "name": "{", "text_snippet": "union\n\t{\n\t\tunsigned int BlockInfo;\n\t\tstruct \n\t\t{\n\t\t\tunsigned size:31;\n\t\t\tunsigned free:1;\n\t\t}Field;\n"}, {"node_id": 83, "universal_type": "class", "name": "unknown", "text_snippet": "union"}, {"node_id": 90, "universal_type": "class", "name": "{", "text_snippet": "struct \n\t\t{\n\t\t\tunsigned size:31;\n\t\t\tunsigned free:1;\n\t\t}"}, {"node_id": 91, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 115, "universal_type": "class", "name": "{", "text_snippet": "struct \n{\n\tvoid* baseHeap;\n\tBlock LastBlockReleased;\n\tvoid* CurrentPointerHeap;\n\tBlock* ListBlocks;\n"}, {"node_id": 116, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 473, "universal_type": "class", "name": "Block", "text_snippet": "struct Block"}, {"node_id": 474, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 486, "universal_type": "class", "name": "Block", "text_snippet": "struct Block"}, {"node_id": 487, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 981, "universal_type": "class", "name": "Block", "text_snippet": "struct Block"}, {"node_id": 982, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 994, "universal_type": "class", "name": "Block", "text_snippet": "struct Block"}, {"node_id": 995, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": [{"node_id": 0, "text": "#include \"Malloc.h\"\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <stdio.h>\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include <stdlib.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <assert.h>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include <sys/unistd.h>\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include <unistd.h>\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include <sys/types.h>\n"}, {"node_id": 19, "text": "#include"}, {"node_id": 21, "text": "#include <stdbool.h>\n"}, {"node_id": 22, "text": "#include"}, {"node_id": 24, "text": "#include <errno.h>\n"}, {"node_id": 25, "text": "#include"}, {"node_id": 27, "text": "#include <stdatomic.h>\n"}, {"node_id": 28, "text": "#include"}]}, "original_source_code": "#include \"Malloc.h\"\n#include <stdio.h>\n#include <stdlib.h>\n#include <assert.h>\n#include <sys/unistd.h>\n#include <unistd.h>\n#include <sys/types.h>\n#include <stdbool.h>\n#include <errno.h>\n#include <stdatomic.h>\n\n#ifndef HEAP_SIZE \n\t#define HEAP_SIZE 33554432u\n#endif\n\n#define ALIGN4(x) (((((x) - 1) >> 2) << 2) + 4)\n\n#define foreach(ptr, List) for(ptr = *List; ptr != NULL; ptr = ptr->next)\n\n#define getHeader(ptr) (((Block)ptr)-1);\n\n#define BlockSize(ptr) (ptr->Info.Field.size)\n#define isFreeBlock(ptr) (ptr->Info.Field.free)\n\n\ntypedef struct Block\n{\n\tstruct Block* next;\n\n\tunion\n\t{\n\t\tunsigned int BlockInfo;\n\t\tstruct \n\t\t{\n\t\t\tunsigned size:31;\n\t\t\tunsigned free:1;\n\t\t}Field;\n\t}Info;\n\tunsigned int id;\n}*Block;\n\nstruct \n{\n\tvoid* baseHeap;\n\tBlock LastBlockReleased;\n\tvoid* CurrentPointerHeap;\n\tBlock* ListBlocks;\n}Gerency;\n\n\nstatic unsigned int memoryUsage;\nstatic unsigned int numberBlocks;\nstatic unsigned int numberFreeBlocks;\nstatic unsigned int numberFragmentation;\nstatic unsigned int totalAllocatedMemory;\nstatic const unsigned int MAX_FRAGMENTATION_BLOCK = 10U;\nenum AllocationAlgorithm AAlgorithm = FIRST_FIT;\n\n\n\nstatic void __attribute__((constructor))InitMalloc(void)\n{\n\tvoid* response;\n\n\tputs(\"\\n\\n\");\n\n\tGerency.baseHeap = sbrk(0);\n\tresponse = sbrk(ALIGN4(HEAP_SIZE));\n\n\ttotalAllocatedMemory += ALIGN4(HEAP_SIZE);\n\n\tassert(!(response == (void*)-1));\n\n\tGerency.ListBlocks = sbrk(0);\n\tresponse = sbrk(sizeof(Block));\n \n totalAllocatedMemory += sizeof(Block);\n\n\n\tassert(!(response == (void*)-1));\n\n\t*(Gerency.ListBlocks) = NULL;\n\tGerency.LastBlockReleased = NULL;\n\tnumberBlocks = 0;\n\tGerency.CurrentPointerHeap = Gerency.baseHeap;\n}\n\n\nvoid* myMalloc(unsigned int size)\n{\n\tBlock newBlock;\n\tBlock scroll;\n\tBlock previousScroll;\n\tBlock enjoyBlock;\n\tBlock tempBlock;\n\tBlock* headerList;\n\tint spaceFree = 0;\n\tint spaceEvaluation = 0;\n\n\tsize = ALIGN4(size);\n\n\tif((Gerency.CurrentPointerHeap) - (Gerency.baseHeap) == HEAP_SIZE)\n\t\treturn NULL;\n\n\tif(((Gerency.CurrentPointerHeap) + size) >= (void*)HEAP_SIZE)\n\t{\n\t\treturn NULL;\n\t}\n\n\tif((*(Gerency.ListBlocks)) == NULL)\n\t{\n\t\tnewBlock = Gerency.CurrentPointerHeap;\n\t\tnewBlock->next = NULL;\n\t\tnewBlock->Info.Field.free = 0;\n\t\tnewBlock->Info.Field.size = size;\n\t\tnewBlock->id = numberBlocks;\n\t\t*(Gerency.ListBlocks) = newBlock;\n\t\t\n\t\tnumberBlocks += 1;\n\n\t\tGerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n\t\tmemoryUsage += ((sizeof(struct Block) + size));\n\t} \n\telse\n\t{\n\t\tif((Gerency.LastBlockReleased != NULL) && ((BlockSize((Gerency.LastBlockReleased)) - size) <= MAX_FRAGMENTATION_BLOCK))\n\t\t{\n\t\t\tenjoyBlock = Gerency.LastBlockReleased;\n\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\tGerency.LastBlockReleased = NULL;\n\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\tnumberFreeBlocks -= 1;\n\t\t\treturn (enjoyBlock + 1);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tswitch(AAlgorithm)\n\t\t\t{\n\t\t\t\tcase FIRST_FIT:\n\t\t\t\ttry_first_fit:\n\n\n\t\t\t\t\tforeach(enjoyBlock,(Gerency.ListBlocks))\n\t\t\t\t\t{\n\t\t\t\t\t\tif((BlockSize(enjoyBlock) >= size) && (isFreeBlock(enjoyBlock)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tenjoyBlock->Info.Field.free = 0;\n\t\t\t\t\t\t\tnumberFreeBlocks -= 1;\n\t\t\t\t\t\t\tnumberFragmentation += BlockSize(enjoyBlock) - size;\n\t\t\t\t\t\t\treturn (enjoyBlock + 1);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tcase BEST_FIT:\n\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, Gerency.ListBlocks)\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation <= spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(spaceFree < 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\telse if(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\tnumberFragmentation += BlockSize(tempBlock) - size;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\n\t\t\t\tcase WORST_FIT:\n\n\t\t\t\t\tspaceFree = BlockSize((*(Gerency.ListBlocks))) - size;\n\t\t\t\t\ttempBlock = *(Gerency.ListBlocks);\n\n\t\t\t\t\tforeach(enjoyBlock, (Gerency.ListBlocks))\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tspaceEvaluation = BlockSize(enjoyBlock) - size;\n\n\t\t\t\t\t \tif((spaceFree < 0) || ((spaceEvaluation > spaceFree) && (isFreeBlock(enjoyBlock))))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tspaceFree = spaceEvaluation;\n\t\t\t\t\t\t\ttempBlock = enjoyBlock;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif(isFreeBlock(tempBlock))\n\t\t\t\t\t{\n\t\t\t\t\t\ttempBlock->Info.Field.free = 0;\n\t\t\t\t\t\treturn (tempBlock + 1);\n\t\t\t\t\t}\n\n\t\t\t\tbreak;\n\n\t\t\t\tdefault:\n\t\t\t\t\tgoto try_first_fit;\n\n\t\t\t}\n\n\t\t\tscroll = *(Gerency.ListBlocks);\n\n\t\t\twhile((scroll != NULL) && (BlockSize(scroll) < size))\n\t\t\t{\n\t\t\t\tpreviousScroll = scroll;\n\t\t\t\tscroll = scroll->next;\n\t\t\t}\n\n\t\t\tnewBlock = Gerency.CurrentPointerHeap;\n\t\t\tnewBlock->Info.Field.free = 0;\n\t\t\tnewBlock->Info.Field.size = size;\n\t\t\tnewBlock->id = numberBlocks;\n\t\t\tnumberBlocks += 1;\n\n\t\t\tif(scroll == *(Gerency.ListBlocks) )\n\t\t\t{\n\t\t\t\tnewBlock->next = *(Gerency.ListBlocks);\n\t\t\t\t*(Gerency.ListBlocks) = newBlock;\n\t\t\t}\n\t\t\t\n\t\t\telse\n\t\t\t{\n\t\t\t\tnewBlock->next = previousScroll->next;\n\t\t\t\tpreviousScroll->next = newBlock;\n\t\t\t}\n\n\t\t\tGerency.CurrentPointerHeap += ((sizeof(struct Block) + size));\n\t\t\tmemoryUsage += ((sizeof(struct Block) + size));\n\t\t}\n\t}\n\n\treturn (newBlock + 1);\n}\n\nvoid* myCalloc(unsigned int length, unsigned int size)\n{\n\n}\n\nint myMallocFree(void* ptr)\n{\n\tBlock releaseBlock;\n\n\treleaseBlock = getHeader(ptr);\n\treleaseBlock->Info.Field.free = 1;\n\n\tif(Gerency.LastBlockReleased == NULL)\n\t{\n\t\tGerency.LastBlockReleased = releaseBlock;\n\t}\n\tnumberFreeBlocks += 1;\n}\n\nvoid __attribute__((destructor))Exit(void)\n{\n\tBlock p;\n\n\tprintf(\"Allocated memory for heap: %u Bytes , Total Allocated Memory %u Bytes\\n\\n\", HEAP_SIZE, totalAllocatedMemory);\n\tprintf(\"Memory Usage: %u Bytes \\n\\n\",memoryUsage);\n\tprintf(\"Internal Fragmentation: %u Bytes \\n\\n\", numberFragmentation);\n\t\n\tforeach(p, (Gerency.ListBlocks))\n\t{\n\t\tprintf(\"Block ID: %u \", p->id);\n\t\tprintf(\"Size: %u \", BlockSize(p));\n\t\tprintf(\"Free: %s\\n\", isFreeBlock(p)?\"True\":\"False\");\n\t\tputs(\" \");\n\t}\n}"}
80,535
c
// // AppDelegate.h // DocumentInteraction // // Created by <NAME> on 7/27/15. // Copyright (c) 2015 <NAME>. All rights reserved. // @import UIKit; @interface AppDelegate: UIResponder <UIApplicationDelegate> @property (strong, nonatomic) UIWindow *window; @end
23.09
11
(translation_unit) "//\n// AppDelegate.h\n// DocumentInteraction\n//\n// Created by <NAME> on 7/27/15.\n// Copyright (c) 2015 <NAME>. All rights reserved.\n//\n\n@import UIKit;\n\n@interface AppDelegate: UIResponder <UIApplicationDelegate>\n\n@property (strong, nonatomic) UIWindow *window;\n\n@end\n\n" (comment) "//" (comment) "// AppDelegate.h" (comment) "// DocumentInteraction" (comment) "//" (comment) "// Created by <NAME> on 7/27/15." (comment) "// Copyright (c) 2015 <NAME>. All rights reserved." (comment) "//" (ERROR) "@" (ERROR) "@" (declaration) "import UIKit;" (type_identifier) "import" (identifier) "UIKit" (;) ";" (ERROR) "@interface AppDelegate: UIResponder <UIApplicationDelegate>\n\n@property (strong, nonatomic) UIWindow *window;\n\n@end" (ERROR) "@" (type_identifier) "interface" (ERROR) "AppDelegate: UIResponder <UIApplicationDelegate>\n\n@" (identifier) "AppDelegate" (:) ":" (identifier) "UIResponder" (<) "<" (identifier) "UIApplicationDelegate" (>) ">" (ERROR) "@" (function_declarator) "property (strong, nonatomic)" (identifier) "property" (parameter_list) "(strong, nonatomic)" (() "(" (identifier) "strong" (,) "," (identifier) "nonatomic" ()) ")" (declaration) "UIWindow *window;" (type_identifier) "UIWindow" (pointer_declarator) "*window" (*) "*" (identifier) "window" (;) ";" (ERROR) "@" (ERROR) "@" (identifier) "end"
42
8
{"language": "c", "success": true, "metadata": {"lines": 11, "avg_line_length": 23.09, "nodes": 26, "errors": 0, "source_hash": "7d062df8c46a66415e7059d00d499b39f3849fe097e36849dd17d3715eb6553e", "categorized_nodes": 13}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "ERROR", "text": "@", "parent": null, "children": [1], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 1}}, {"id": 1, "type": "ERROR", "text": "@", "parent": 0, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 1}}, {"id": 2, "type": "declaration", "text": "import UIKit;", "parent": null, "children": [3], "start_point": {"row": 8, "column": 1}, "end_point": {"row": 8, "column": 14}}, {"id": 3, "type": "identifier", "text": "UIKit", "parent": 2, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 13}}, {"id": 4, "type": "ERROR", "text": "@interface AppDelegate: UIResponder <UIApplicationDelegate>\n\n@property (strong, nonatomic) UIWindow *window;\n\n@end", "parent": null, "children": [5, 6, 7, 14, 19, 24], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 14, "column": 4}}, {"id": 5, "type": "ERROR", "text": "@", "parent": 4, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 1}}, {"id": 6, "type": "type_identifier", "text": "interface", "parent": 4, "children": [], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 10}}, {"id": 7, "type": "ERROR", "text": "AppDelegate: UIResponder <UIApplicationDelegate>\n\n@", "parent": 4, "children": [8, 9, 10, 11, 12, 13], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 12, "column": 1}}, {"id": 8, "type": "identifier", "text": "AppDelegate", "parent": 7, "children": [], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 10, "column": 22}}, {"id": 9, "type": "identifier", "text": "UIResponder", "parent": 7, "children": [], "start_point": {"row": 10, "column": 24}, "end_point": {"row": 10, "column": 35}}, {"id": 10, "type": "<", "text": "<", "parent": 7, "children": [], "start_point": {"row": 10, "column": 36}, "end_point": {"row": 10, "column": 37}}, {"id": 11, "type": "identifier", "text": "UIApplicationDelegate", "parent": 7, "children": [], "start_point": {"row": 10, "column": 37}, "end_point": {"row": 10, "column": 58}}, {"id": 12, "type": ">", "text": ">", "parent": 7, "children": [], "start_point": {"row": 10, "column": 58}, "end_point": {"row": 10, "column": 59}}, {"id": 13, "type": "ERROR", "text": "@", "parent": 7, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 1}}, {"id": 14, "type": "function_declarator", "text": "property (strong, nonatomic)", "parent": 4, "children": [15, 16], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 29}}, {"id": 15, "type": "identifier", "text": "property", "parent": 14, "children": [], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 9}}, {"id": 16, "type": "parameter_list", "text": "(strong, nonatomic)", "parent": 14, "children": [17, 18], "start_point": {"row": 12, "column": 10}, "end_point": {"row": 12, "column": 29}}, {"id": 17, "type": "identifier", "text": "strong", "parent": 16, "children": [], "start_point": {"row": 12, "column": 11}, "end_point": {"row": 12, "column": 17}}, {"id": 18, "type": "identifier", "text": "nonatomic", "parent": 16, "children": [], "start_point": {"row": 12, "column": 19}, "end_point": {"row": 12, "column": 28}}, {"id": 19, "type": "declaration", "text": "UIWindow *window;", "parent": 4, "children": [20, 21], "start_point": {"row": 12, "column": 30}, "end_point": {"row": 12, "column": 47}}, {"id": 20, "type": "type_identifier", "text": "UIWindow", "parent": 19, "children": [], "start_point": {"row": 12, "column": 30}, "end_point": {"row": 12, "column": 38}}, {"id": 21, "type": "pointer_declarator", "text": "*window", "parent": 19, "children": [22, 23], "start_point": {"row": 12, "column": 39}, "end_point": {"row": 12, "column": 46}}, {"id": 22, "type": "*", "text": "*", "parent": 21, "children": [], "start_point": {"row": 12, "column": 39}, "end_point": {"row": 12, "column": 40}}, {"id": 23, "type": "identifier", "text": "window", "parent": 21, "children": [], "start_point": {"row": 12, "column": 40}, "end_point": {"row": 12, "column": 46}}, {"id": 24, "type": "ERROR", "text": "@", "parent": 4, "children": [25], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 1}}, {"id": 25, "type": "ERROR", "text": "@", "parent": 24, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 1}}]}, "node_categories": {"declarations": {"functions": [14], "variables": [2, 19], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [3, 6, 8, 9, 11, 15, 17, 18, 20, 23], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 14, "universal_type": "function", "name": "unknown", "text_snippet": "property (strong, nonatomic)"}], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// AppDelegate.h\n// DocumentInteraction\n//\n// Created by <NAME> on 7/27/15.\n// Copyright (c) 2015 <NAME>. All rights reserved.\n//\n\n@import UIKit;\n\n@interface AppDelegate: UIResponder <UIApplicationDelegate>\n\n@property (strong, nonatomic) UIWindow *window;\n\n@end\n\n"}
80,536
c
// // FFAppDelegate.h // TSCategoryKit // // Created by myGitHubLxd on 03/18/2019. // Copyright (c) 2019 myGitHubLxd. All rights reserved. // @import UIKit; @interface FFAppDelegate : UIResponder <UIApplicationDelegate> @property (strong, nonatomic) UIWindow *window; @end
24.18
11
(translation_unit) "//\n// FFAppDelegate.h\n// TSCategoryKit\n//\n// Created by myGitHubLxd on 03/18/2019.\n// Copyright (c) 2019 myGitHubLxd. All rights reserved.\n//\n\n@import UIKit;\n\n@interface FFAppDelegate : UIResponder <UIApplicationDelegate>\n\n@property (strong, nonatomic) UIWindow *window;\n\n@end\n" (comment) "//" (comment) "// FFAppDelegate.h" (comment) "// TSCategoryKit" (comment) "//" (comment) "// Created by myGitHubLxd on 03/18/2019." (comment) "// Copyright (c) 2019 myGitHubLxd. All rights reserved." (comment) "//" (ERROR) "@" (ERROR) "@" (declaration) "import UIKit;" (type_identifier) "import" (identifier) "UIKit" (;) ";" (ERROR) "@interface FFAppDelegate : UIResponder <UIApplicationDelegate>\n\n@property (strong, nonatomic) UIWindow *window;\n\n@end" (ERROR) "@" (type_identifier) "interface" (ERROR) "FFAppDelegate : UIResponder <UIApplicationDelegate>\n\n@" (identifier) "FFAppDelegate" (:) ":" (identifier) "UIResponder" (<) "<" (identifier) "UIApplicationDelegate" (>) ">" (ERROR) "@" (function_declarator) "property (strong, nonatomic)" (identifier) "property" (parameter_list) "(strong, nonatomic)" (() "(" (identifier) "strong" (,) "," (identifier) "nonatomic" ()) ")" (declaration) "UIWindow *window;" (type_identifier) "UIWindow" (pointer_declarator) "*window" (*) "*" (identifier) "window" (;) ";" (ERROR) "@" (ERROR) "@" (identifier) "end"
42
8
{"language": "c", "success": true, "metadata": {"lines": 11, "avg_line_length": 24.18, "nodes": 26, "errors": 0, "source_hash": "eb0989da25b724f101f35a1bad3fa676a486f5a287f0d947c3a16301d9dab1a9", "categorized_nodes": 13}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "ERROR", "text": "@", "parent": null, "children": [1], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 1}}, {"id": 1, "type": "ERROR", "text": "@", "parent": 0, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 1}}, {"id": 2, "type": "declaration", "text": "import UIKit;", "parent": null, "children": [3], "start_point": {"row": 8, "column": 1}, "end_point": {"row": 8, "column": 14}}, {"id": 3, "type": "identifier", "text": "UIKit", "parent": 2, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 13}}, {"id": 4, "type": "ERROR", "text": "@interface FFAppDelegate : UIResponder <UIApplicationDelegate>\n\n@property (strong, nonatomic) UIWindow *window;\n\n@end", "parent": null, "children": [5, 6, 7, 14, 19, 24], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 14, "column": 4}}, {"id": 5, "type": "ERROR", "text": "@", "parent": 4, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 1}}, {"id": 6, "type": "type_identifier", "text": "interface", "parent": 4, "children": [], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 10}}, {"id": 7, "type": "ERROR", "text": "FFAppDelegate : UIResponder <UIApplicationDelegate>\n\n@", "parent": 4, "children": [8, 9, 10, 11, 12, 13], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 12, "column": 1}}, {"id": 8, "type": "identifier", "text": "FFAppDelegate", "parent": 7, "children": [], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 10, "column": 24}}, {"id": 9, "type": "identifier", "text": "UIResponder", "parent": 7, "children": [], "start_point": {"row": 10, "column": 27}, "end_point": {"row": 10, "column": 38}}, {"id": 10, "type": "<", "text": "<", "parent": 7, "children": [], "start_point": {"row": 10, "column": 39}, "end_point": {"row": 10, "column": 40}}, {"id": 11, "type": "identifier", "text": "UIApplicationDelegate", "parent": 7, "children": [], "start_point": {"row": 10, "column": 40}, "end_point": {"row": 10, "column": 61}}, {"id": 12, "type": ">", "text": ">", "parent": 7, "children": [], "start_point": {"row": 10, "column": 61}, "end_point": {"row": 10, "column": 62}}, {"id": 13, "type": "ERROR", "text": "@", "parent": 7, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 1}}, {"id": 14, "type": "function_declarator", "text": "property (strong, nonatomic)", "parent": 4, "children": [15, 16], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 29}}, {"id": 15, "type": "identifier", "text": "property", "parent": 14, "children": [], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 9}}, {"id": 16, "type": "parameter_list", "text": "(strong, nonatomic)", "parent": 14, "children": [17, 18], "start_point": {"row": 12, "column": 10}, "end_point": {"row": 12, "column": 29}}, {"id": 17, "type": "identifier", "text": "strong", "parent": 16, "children": [], "start_point": {"row": 12, "column": 11}, "end_point": {"row": 12, "column": 17}}, {"id": 18, "type": "identifier", "text": "nonatomic", "parent": 16, "children": [], "start_point": {"row": 12, "column": 19}, "end_point": {"row": 12, "column": 28}}, {"id": 19, "type": "declaration", "text": "UIWindow *window;", "parent": 4, "children": [20, 21], "start_point": {"row": 12, "column": 30}, "end_point": {"row": 12, "column": 47}}, {"id": 20, "type": "type_identifier", "text": "UIWindow", "parent": 19, "children": [], "start_point": {"row": 12, "column": 30}, "end_point": {"row": 12, "column": 38}}, {"id": 21, "type": "pointer_declarator", "text": "*window", "parent": 19, "children": [22, 23], "start_point": {"row": 12, "column": 39}, "end_point": {"row": 12, "column": 46}}, {"id": 22, "type": "*", "text": "*", "parent": 21, "children": [], "start_point": {"row": 12, "column": 39}, "end_point": {"row": 12, "column": 40}}, {"id": 23, "type": "identifier", "text": "window", "parent": 21, "children": [], "start_point": {"row": 12, "column": 40}, "end_point": {"row": 12, "column": 46}}, {"id": 24, "type": "ERROR", "text": "@", "parent": 4, "children": [25], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 1}}, {"id": 25, "type": "ERROR", "text": "@", "parent": 24, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 1}}]}, "node_categories": {"declarations": {"functions": [14], "variables": [2, 19], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [3, 6, 8, 9, 11, 15, 17, 18, 20, 23], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 14, "universal_type": "function", "name": "unknown", "text_snippet": "property (strong, nonatomic)"}], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// FFAppDelegate.h\n// TSCategoryKit\n//\n// Created by myGitHubLxd on 03/18/2019.\n// Copyright (c) 2019 myGitHubLxd. All rights reserved.\n//\n\n@import UIKit;\n\n@interface FFAppDelegate : UIResponder <UIApplicationDelegate>\n\n@property (strong, nonatomic) UIWindow *window;\n\n@end\n"}
80,537
c
/* -*- C -*- */ /* * Copyright (c) 2017-2020 Seagate Technology LLC and/or its Affiliates * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * * For any questions about this software or licensing, * please email <EMAIL> or <EMAIL>. * */ #define M0_TRACE_SUBSYSTEM M0_TRACE_SUBSYS_FDMI #include "lib/trace.h" #include "lib/memory.h" #include "ut/ut.h" #include "fdmi/fdmi.h" #include "fdmi/service.h" /* m0_reqh_fdmi_service */ #include "fdmi/source_dock_internal.h" #include "fdmi/ut/sd_common.h" static struct m0_semaphore g_sem; static char g_fdmi_data[] = "hello, FDMI"; static struct m0_fdmi_src_rec g_src_rec; /*********** FilterC stub ***********/ static struct m0_conf_fdmi_filter g_conf_filter; static char *g_var_str; static int filterc_apply_flt_start(struct m0_filterc_ctx *ctx, struct m0_reqh *reqh); static void filterc_apply_flt_stop(struct m0_filterc_ctx *ctx); static int filterc_apply_flt_open(struct m0_filterc_ctx *ctx, enum m0_fdmi_rec_type_id rec_type_id, struct m0_filterc_iter *iter); static int filterc_apply_flt_get_next(struct m0_filterc_iter *iter, struct m0_conf_fdmi_filter **out); static void filterc_apply_flt_close(struct m0_filterc_iter *iter); const struct m0_filterc_ops filterc_apply_flt_ops = { .fco_start = filterc_apply_flt_start, .fco_stop = filterc_apply_flt_stop, .fco_open = filterc_apply_flt_open, .fco_get_next = filterc_apply_flt_get_next, .fco_close = filterc_apply_flt_close }; static int filterc_apply_flt_start(struct m0_filterc_ctx *ctx, struct m0_reqh *reqh) { return 0; } static void filterc_apply_flt_stop(struct m0_filterc_ctx *ctx) { } static int filterc_apply_flt_open(struct m0_filterc_ctx *ctx, enum m0_fdmi_rec_type_id rec_type_id, struct m0_filterc_iter *iter) { return 0; } static int filterc_apply_flt_get_next(struct m0_filterc_iter *iter, struct m0_conf_fdmi_filter **out) { int rc; static bool first_filter = true; struct m0_fdmi_filter *flt = &g_conf_filter.ff_filter; struct m0_fdmi_flt_node *root; struct m0_buf var = M0_BUF_INITS(g_var_str); if (first_filter) { root = m0_fdmi_flt_op_node_create( M0_FFO_OR, m0_fdmi_flt_bool_node_create(false), m0_fdmi_flt_var_node_create(&var)); m0_fdmi_filter_init(flt); m0_fdmi_filter_root_set(flt, root); *out = &g_conf_filter; rc = 1; first_filter = false; } else { *out = NULL; rc = 0; } return rc; } static void filterc_apply_flt_close(struct m0_filterc_iter *iter) { m0_fdmi_filter_fini(&g_conf_filter.ff_filter); } /*********** Source definition ***********/ static int test_fs_node_eval( struct m0_fdmi_src_rec *src_rec, struct m0_fdmi_flt_var_node *value_desc, struct m0_fdmi_flt_operand *value) { M0_UT_ASSERT(src_rec == &g_src_rec); M0_UT_ASSERT(src_rec->fsr_data == &g_fdmi_data); M0_UT_ASSERT(value_desc->ffvn_data.b_nob == strlen(g_var_str)); M0_UT_ASSERT(value_desc->ffvn_data.b_addr == g_var_str); m0_fdmi_flt_bool_opnd_fill(value, false); return 0; } static int test_fs_encode(struct m0_fdmi_src_rec *src_rec, struct m0_buf *buf) { M0_UT_ASSERT(false); return 0; } static void test_fs_get(struct m0_fdmi_src_rec *src_rec) { M0_UT_ASSERT(false); } static void test_fs_put(struct m0_fdmi_src_rec *src_rec) { M0_UT_ASSERT(src_rec != NULL); M0_UT_ASSERT(src_rec == &g_src_rec); } static void test_fs_end(struct m0_fdmi_src_rec *src_rec) { M0_UT_ASSERT(src_rec != NULL); M0_UT_ASSERT(src_rec == &g_src_rec); /* Calling of this function is a sign for fdmi_sd_post_record UT * that FDMI finished record processing */ m0_semaphore_up(&g_sem); } static struct m0_fdmi_src *src_alloc() { struct m0_fdmi_src *src; int rc; rc = m0_fdmi_source_alloc(M0_FDMI_REC_TYPE_TEST, &src); M0_UT_ASSERT(rc == 0); src->fs_node_eval = test_fs_node_eval; src->fs_get = test_fs_get; src->fs_put = test_fs_put; src->fs_end = test_fs_end; src->fs_encode = test_fs_encode; return src; } static void fdmi_sd_apply_filter_internal(const struct m0_filterc_ops *ops) { struct m0_fdmi_src *src = src_alloc(); int rc; M0_ENTRY(); g_var_str = strdup("test"); M0_SET0(&g_conf_filter); fdmi_serv_start_ut(ops); m0_semaphore_init(&g_sem, 0); rc = m0_fdmi_source_register(src); M0_UT_ASSERT(rc == 0); g_src_rec = (struct m0_fdmi_src_rec) { .fsr_src = src, .fsr_data = g_fdmi_data, }; M0_FDMI_SOURCE_POST_RECORD(&g_src_rec); /* Wait until record is processed and released */ m0_semaphore_down(&g_sem); m0_fdmi_source_deregister(src); m0_fdmi_source_free(src); m0_semaphore_fini(&g_sem); fdmi_serv_stop_ut(); M0_LEAVE(); } void fdmi_sd_apply_filter(void) { M0_ENTRY(); fdmi_sd_apply_filter_internal(&filterc_apply_flt_ops); M0_LEAVE(); } #undef M0_TRACE_SUBSYSTEM /* * Local variables: * c-indentation-style: "K&R" * c-basic-offset: 8 * tab-width: 8 * fill-column: 80 * scroll-step: 1 * End: */ /* * vim: tabstop=8 shiftwidth=8 noexpandtab textwidth=80 nowrap */
29.49
186
(translation_unit) "/* -*- C -*- */\n/*\n * Copyright (c) 2017-2020 Seagate Technology LLC and/or its Affiliates\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n * For any questions about this software or licensing,\n * please email <EMAIL> or <EMAIL>.\n *\n */\n\n\n#define M0_TRACE_SUBSYSTEM M0_TRACE_SUBSYS_FDMI\n#include "lib/trace.h"\n\n#include "lib/memory.h"\n#include "ut/ut.h"\n#include "fdmi/fdmi.h"\n#include "fdmi/service.h" /* m0_reqh_fdmi_service */\n#include "fdmi/source_dock_internal.h"\n\n#include "fdmi/ut/sd_common.h"\n\nstatic struct m0_semaphore g_sem;\nstatic char g_fdmi_data[] = "hello, FDMI";\nstatic struct m0_fdmi_src_rec g_src_rec;\n\n/*********** FilterC stub ***********/\n\nstatic struct m0_conf_fdmi_filter g_conf_filter;\nstatic char *g_var_str;\n\nstatic int filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n struct m0_reqh *reqh);\n\nstatic void filterc_apply_flt_stop(struct m0_filterc_ctx *ctx);\n\nstatic int filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n enum m0_fdmi_rec_type_id rec_type_id,\n struct m0_filterc_iter *iter);\n\nstatic int filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n struct m0_conf_fdmi_filter **out);\n\nstatic void filterc_apply_flt_close(struct m0_filterc_iter *iter);\n\nconst struct m0_filterc_ops filterc_apply_flt_ops = {\n .fco_start = filterc_apply_flt_start,\n .fco_stop = filterc_apply_flt_stop,\n .fco_open = filterc_apply_flt_open,\n .fco_get_next = filterc_apply_flt_get_next,\n .fco_close = filterc_apply_flt_close\n};\n\nstatic int filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n struct m0_reqh *reqh)\n{\n return 0;\n}\n\nstatic void filterc_apply_flt_stop(struct m0_filterc_ctx *ctx)\n{\n}\n\nstatic int filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n enum m0_fdmi_rec_type_id rec_type_id,\n struct m0_filterc_iter *iter)\n{\n return 0;\n}\n\nstatic int filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n struct m0_conf_fdmi_filter **out)\n{\n int rc;\n static bool first_filter = true;\n struct m0_fdmi_filter *flt = &g_conf_filter.ff_filter;\n struct m0_fdmi_flt_node *root;\n struct m0_buf var = M0_BUF_INITS(g_var_str);\n\n if (first_filter) {\n root = m0_fdmi_flt_op_node_create(\n M0_FFO_OR,\n m0_fdmi_flt_bool_node_create(false),\n m0_fdmi_flt_var_node_create(&var));\n\n m0_fdmi_filter_init(flt);\n\n m0_fdmi_filter_root_set(flt, root);\n\n *out = &g_conf_filter;\n rc = 1;\n first_filter = false;\n } else {\n *out = NULL;\n rc = 0;\n }\n return rc;\n}\n\nstatic void filterc_apply_flt_close(struct m0_filterc_iter *iter)\n{\n m0_fdmi_filter_fini(&g_conf_filter.ff_filter);\n}\n\n/*********** Source definition ***********/\nstatic int test_fs_node_eval(\n struct m0_fdmi_src_rec *src_rec,\n struct m0_fdmi_flt_var_node *value_desc,\n struct m0_fdmi_flt_operand *value)\n{\n M0_UT_ASSERT(src_rec == &g_src_rec);\n M0_UT_ASSERT(src_rec->fsr_data == &g_fdmi_data);\n M0_UT_ASSERT(value_desc->ffvn_data.b_nob == strlen(g_var_str));\n M0_UT_ASSERT(value_desc->ffvn_data.b_addr == g_var_str);\n\n m0_fdmi_flt_bool_opnd_fill(value, false);\n return 0;\n}\n\nstatic int test_fs_encode(struct m0_fdmi_src_rec *src_rec,\n struct m0_buf *buf)\n{\n M0_UT_ASSERT(false);\n return 0;\n}\n\n\nstatic void test_fs_get(struct m0_fdmi_src_rec *src_rec)\n{\n M0_UT_ASSERT(false);\n}\n\nstatic void test_fs_put(struct m0_fdmi_src_rec *src_rec)\n{\n M0_UT_ASSERT(src_rec != NULL);\n M0_UT_ASSERT(src_rec == &g_src_rec);\n}\n\nstatic void test_fs_end(struct m0_fdmi_src_rec *src_rec)\n{\n M0_UT_ASSERT(src_rec != NULL);\n M0_UT_ASSERT(src_rec == &g_src_rec);\n /* Calling of this function is a sign for fdmi_sd_post_record UT\n * that FDMI finished record processing */\n m0_semaphore_up(&g_sem);\n}\n\nstatic struct m0_fdmi_src *src_alloc()\n{\n struct m0_fdmi_src *src;\n int rc;\n\n rc = m0_fdmi_source_alloc(M0_FDMI_REC_TYPE_TEST, &src);\n M0_UT_ASSERT(rc == 0);\n\n src->fs_node_eval = test_fs_node_eval;\n src->fs_get = test_fs_get;\n src->fs_put = test_fs_put;\n src->fs_end = test_fs_end;\n src->fs_encode = test_fs_encode;\n return src;\n}\n\nstatic void fdmi_sd_apply_filter_internal(const struct m0_filterc_ops *ops)\n{\n struct m0_fdmi_src *src = src_alloc();\n int rc;\n\n M0_ENTRY();\n\n g_var_str = strdup("test");\n M0_SET0(&g_conf_filter);\n\n fdmi_serv_start_ut(ops);\n m0_semaphore_init(&g_sem, 0);\n rc = m0_fdmi_source_register(src);\n M0_UT_ASSERT(rc == 0);\n g_src_rec = (struct m0_fdmi_src_rec) {\n .fsr_src = src,\n .fsr_data = g_fdmi_data,\n };\n M0_FDMI_SOURCE_POST_RECORD(&g_src_rec);\n /* Wait until record is processed and released */\n m0_semaphore_down(&g_sem);\n m0_fdmi_source_deregister(src);\n m0_fdmi_source_free(src);\n m0_semaphore_fini(&g_sem);\n fdmi_serv_stop_ut();\n M0_LEAVE();\n}\n\nvoid fdmi_sd_apply_filter(void)\n{\n M0_ENTRY();\n fdmi_sd_apply_filter_internal(&filterc_apply_flt_ops);\n M0_LEAVE();\n}\n\n#undef M0_TRACE_SUBSYSTEM\n\n/*\n * Local variables:\n * c-indentation-style: "K&R"\n * c-basic-offset: 8\n * tab-width: 8\n * fill-column: 80\n * scroll-step: 1\n * End:\n */\n/*\n * vim: tabstop=8 shiftwidth=8 noexpandtab textwidth=80 nowrap\n */\n" (comment) "/* -*- C -*- */" (comment) "/*\n * Copyright (c) 2017-2020 Seagate Technology LLC and/or its Affiliates\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n * For any questions about this software or licensing,\n * please email <EMAIL> or <EMAIL>.\n *\n */" (preproc_def) "#define M0_TRACE_SUBSYSTEM M0_TRACE_SUBSYS_FDMI\n" (#define) "#define" (identifier) "M0_TRACE_SUBSYSTEM" (preproc_arg) "M0_TRACE_SUBSYS_FDMI" (preproc_include) "#include "lib/trace.h"\n" (#include) "#include" (string_literal) ""lib/trace.h"" (") """ (string_content) "lib/trace.h" (") """ (preproc_include) "#include "lib/memory.h"\n" (#include) "#include" (string_literal) ""lib/memory.h"" (") """ (string_content) "lib/memory.h" (") """ (preproc_include) "#include "ut/ut.h"\n" (#include) "#include" (string_literal) ""ut/ut.h"" (") """ (string_content) "ut/ut.h" (") """ (preproc_include) "#include "fdmi/fdmi.h"\n" (#include) "#include" (string_literal) ""fdmi/fdmi.h"" (") """ (string_content) "fdmi/fdmi.h" (") """ (preproc_include) "#include "fdmi/service.h" /* m0_reqh_fdmi_service */\n" (#include) "#include" (string_literal) ""fdmi/service.h"" (") """ (string_content) "fdmi/service.h" (") """ (comment) "/* m0_reqh_fdmi_service */" (preproc_include) "#include "fdmi/source_dock_internal.h"\n" (#include) "#include" (string_literal) ""fdmi/source_dock_internal.h"" (") """ (string_content) "fdmi/source_dock_internal.h" (") """ (preproc_include) "#include "fdmi/ut/sd_common.h"\n" (#include) "#include" (string_literal) ""fdmi/ut/sd_common.h"" (") """ (string_content) "fdmi/ut/sd_common.h" (") """ (declaration) "static struct m0_semaphore g_sem;" (storage_class_specifier) "static" (static) "static" (struct_specifier) "struct m0_semaphore" (struct) "struct" (type_identifier) "m0_semaphore" (identifier) "g_sem" (;) ";" (declaration) "static char g_fdmi_data[] = "hello, FDMI";" (storage_class_specifier) "static" (static) "static" (primitive_type) "char" (init_declarator) "g_fdmi_data[] = "hello, FDMI"" (array_declarator) "g_fdmi_data[]" (identifier) "g_fdmi_data" ([) "[" (]) "]" (=) "=" (string_literal) ""hello, FDMI"" (") """ (string_content) "hello, FDMI" (") """ (;) ";" (declaration) "static struct m0_fdmi_src_rec g_src_rec;" (storage_class_specifier) "static" (static) "static" (struct_specifier) "struct m0_fdmi_src_rec" (struct) "struct" (type_identifier) "m0_fdmi_src_rec" (identifier) "g_src_rec" (;) ";" (comment) "/*********** FilterC stub ***********/" (declaration) "static struct m0_conf_fdmi_filter g_conf_filter;" (storage_class_specifier) "static" (static) "static" (struct_specifier) "struct m0_conf_fdmi_filter" (struct) "struct" (type_identifier) "m0_conf_fdmi_filter" (identifier) "g_conf_filter" (;) ";" (declaration) "static char *g_var_str;" (storage_class_specifier) "static" (static) "static" (primitive_type) "char" (pointer_declarator) "*g_var_str" (*) "*" (identifier) "g_var_str" (;) ";" (declaration) "static int filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n struct m0_reqh *reqh);" (storage_class_specifier) "static" (static) "static" (primitive_type) "int" (function_declarator) "filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n struct m0_reqh *reqh)" (identifier) "filterc_apply_flt_start" (parameter_list) "(struct m0_filterc_ctx *ctx,\n struct m0_reqh *reqh)" (() "(" (parameter_declaration) "struct m0_filterc_ctx *ctx" (struct_specifier) "struct m0_filterc_ctx" (struct) "struct" (type_identifier) "m0_filterc_ctx" (pointer_declarator) "*ctx" (*) "*" (identifier) "ctx" (,) "," (parameter_declaration) "struct m0_reqh *reqh" (struct_specifier) "struct m0_reqh" (struct) "struct" (type_identifier) "m0_reqh" (pointer_declarator) "*reqh" (*) "*" (identifier) "reqh" ()) ")" (;) ";" (declaration) "static void filterc_apply_flt_stop(struct m0_filterc_ctx *ctx);" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "filterc_apply_flt_stop(struct m0_filterc_ctx *ctx)" (identifier) "filterc_apply_flt_stop" (parameter_list) "(struct m0_filterc_ctx *ctx)" (() "(" (parameter_declaration) "struct m0_filterc_ctx *ctx" (struct_specifier) "struct m0_filterc_ctx" (struct) "struct" (type_identifier) "m0_filterc_ctx" (pointer_declarator) "*ctx" (*) "*" (identifier) "ctx" ()) ")" (;) ";" (declaration) "static int filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n enum m0_fdmi_rec_type_id rec_type_id,\n struct m0_filterc_iter *iter);" (storage_class_specifier) "static" (static) "static" (primitive_type) "int" (function_declarator) "filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n enum m0_fdmi_rec_type_id rec_type_id,\n struct m0_filterc_iter *iter)" (identifier) "filterc_apply_flt_open" (parameter_list) "(struct m0_filterc_ctx *ctx,\n enum m0_fdmi_rec_type_id rec_type_id,\n struct m0_filterc_iter *iter)" (() "(" (parameter_declaration) "struct m0_filterc_ctx *ctx" (struct_specifier) "struct m0_filterc_ctx" (struct) "struct" (type_identifier) "m0_filterc_ctx" (pointer_declarator) "*ctx" (*) "*" (identifier) "ctx" (,) "," (parameter_declaration) "enum m0_fdmi_rec_type_id rec_type_id" (enum_specifier) "enum m0_fdmi_rec_type_id" (enum) "enum" (type_identifier) "m0_fdmi_rec_type_id" (identifier) "rec_type_id" (,) "," (parameter_declaration) "struct m0_filterc_iter *iter" (struct_specifier) "struct m0_filterc_iter" (struct) "struct" (type_identifier) "m0_filterc_iter" (pointer_declarator) "*iter" (*) "*" (identifier) "iter" ()) ")" (;) ";" (declaration) "static int filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n struct m0_conf_fdmi_filter **out);" (storage_class_specifier) "static" (static) "static" (primitive_type) "int" (function_declarator) "filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n struct m0_conf_fdmi_filter **out)" (identifier) "filterc_apply_flt_get_next" (parameter_list) "(struct m0_filterc_iter *iter,\n struct m0_conf_fdmi_filter **out)" (() "(" (parameter_declaration) "struct m0_filterc_iter *iter" (struct_specifier) "struct m0_filterc_iter" (struct) "struct" (type_identifier) "m0_filterc_iter" (pointer_declarator) "*iter" (*) "*" (identifier) "iter" (,) "," (parameter_declaration) "struct m0_conf_fdmi_filter **out" (struct_specifier) "struct m0_conf_fdmi_filter" (struct) "struct" (type_identifier) "m0_conf_fdmi_filter" (pointer_declarator) "**out" (*) "*" (pointer_declarator) "*out" (*) "*" (identifier) "out" ()) ")" (;) ";" (declaration) "static void filterc_apply_flt_close(struct m0_filterc_iter *iter);" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "filterc_apply_flt_close(struct m0_filterc_iter *iter)" (identifier) "filterc_apply_flt_close" (parameter_list) "(struct m0_filterc_iter *iter)" (() "(" (parameter_declaration) "struct m0_filterc_iter *iter" (struct_specifier) "struct m0_filterc_iter" (struct) "struct" (type_identifier) "m0_filterc_iter" (pointer_declarator) "*iter" (*) "*" (identifier) "iter" ()) ")" (;) ";" (declaration) "const struct m0_filterc_ops filterc_apply_flt_ops = {\n .fco_start = filterc_apply_flt_start,\n .fco_stop = filterc_apply_flt_stop,\n .fco_open = filterc_apply_flt_open,\n .fco_get_next = filterc_apply_flt_get_next,\n .fco_close = filterc_apply_flt_close\n};" (type_qualifier) "const" (const) "const" (struct_specifier) "struct m0_filterc_ops" (struct) "struct" (type_identifier) "m0_filterc_ops" (init_declarator) "filterc_apply_flt_ops = {\n .fco_start = filterc_apply_flt_start,\n .fco_stop = filterc_apply_flt_stop,\n .fco_open = filterc_apply_flt_open,\n .fco_get_next = filterc_apply_flt_get_next,\n .fco_close = filterc_apply_flt_close\n}" (identifier) "filterc_apply_flt_ops" (=) "=" (initializer_list) "{\n .fco_start = filterc_apply_flt_start,\n .fco_stop = filterc_apply_flt_stop,\n .fco_open = filterc_apply_flt_open,\n .fco_get_next = filterc_apply_flt_get_next,\n .fco_close = filterc_apply_flt_close\n}" ({) "{" (initializer_pair) ".fco_start = filterc_apply_flt_start" (field_designator) ".fco_start" (.) "." (field_identifier) "fco_start" (=) "=" (identifier) "filterc_apply_flt_start" (,) "," (initializer_pair) ".fco_stop = filterc_apply_flt_stop" (field_designator) ".fco_stop" (.) "." (field_identifier) "fco_stop" (=) "=" (identifier) "filterc_apply_flt_stop" (,) "," (initializer_pair) ".fco_open = filterc_apply_flt_open" (field_designator) ".fco_open" (.) "." (field_identifier) "fco_open" (=) "=" (identifier) "filterc_apply_flt_open" (,) "," (initializer_pair) ".fco_get_next = filterc_apply_flt_get_next" (field_designator) ".fco_get_next" (.) "." (field_identifier) "fco_get_next" (=) "=" (identifier) "filterc_apply_flt_get_next" (,) "," (initializer_pair) ".fco_close = filterc_apply_flt_close" (field_designator) ".fco_close" (.) "." (field_identifier) "fco_close" (=) "=" (identifier) "filterc_apply_flt_close" (}) "}" (;) ";" (function_definition) "static int filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n struct m0_reqh *reqh)\n{\n return 0;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "int" (function_declarator) "filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n struct m0_reqh *reqh)" (identifier) "filterc_apply_flt_start" (parameter_list) "(struct m0_filterc_ctx *ctx,\n struct m0_reqh *reqh)" (() "(" (parameter_declaration) "struct m0_filterc_ctx *ctx" (struct_specifier) "struct m0_filterc_ctx" (struct) "struct" (type_identifier) "m0_filterc_ctx" (pointer_declarator) "*ctx" (*) "*" (identifier) "ctx" (,) "," (parameter_declaration) "struct m0_reqh *reqh" (struct_specifier) "struct m0_reqh" (struct) "struct" (type_identifier) "m0_reqh" (pointer_declarator) "*reqh" (*) "*" (identifier) "reqh" ()) ")" (compound_statement) "{\n return 0;\n}" ({) "{" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (function_definition) "static void filterc_apply_flt_stop(struct m0_filterc_ctx *ctx)\n{\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "filterc_apply_flt_stop(struct m0_filterc_ctx *ctx)" (identifier) "filterc_apply_flt_stop" (parameter_list) "(struct m0_filterc_ctx *ctx)" (() "(" (parameter_declaration) "struct m0_filterc_ctx *ctx" (struct_specifier) "struct m0_filterc_ctx" (struct) "struct" (type_identifier) "m0_filterc_ctx" (pointer_declarator) "*ctx" (*) "*" (identifier) "ctx" ()) ")" (compound_statement) "{\n}" ({) "{" (}) "}" (function_definition) "static int filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n enum m0_fdmi_rec_type_id rec_type_id,\n struct m0_filterc_iter *iter)\n{\n return 0;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "int" (function_declarator) "filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n enum m0_fdmi_rec_type_id rec_type_id,\n struct m0_filterc_iter *iter)" (identifier) "filterc_apply_flt_open" (parameter_list) "(struct m0_filterc_ctx *ctx,\n enum m0_fdmi_rec_type_id rec_type_id,\n struct m0_filterc_iter *iter)" (() "(" (parameter_declaration) "struct m0_filterc_ctx *ctx" (struct_specifier) "struct m0_filterc_ctx" (struct) "struct" (type_identifier) "m0_filterc_ctx" (pointer_declarator) "*ctx" (*) "*" (identifier) "ctx" (,) "," (parameter_declaration) "enum m0_fdmi_rec_type_id rec_type_id" (enum_specifier) "enum m0_fdmi_rec_type_id" (enum) "enum" (type_identifier) "m0_fdmi_rec_type_id" (identifier) "rec_type_id" (,) "," (parameter_declaration) "struct m0_filterc_iter *iter" (struct_specifier) "struct m0_filterc_iter" (struct) "struct" (type_identifier) "m0_filterc_iter" (pointer_declarator) "*iter" (*) "*" (identifier) "iter" ()) ")" (compound_statement) "{\n return 0;\n}" ({) "{" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (function_definition) "static int filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n struct m0_conf_fdmi_filter **out)\n{\n int rc;\n static bool first_filter = true;\n struct m0_fdmi_filter *flt = &g_conf_filter.ff_filter;\n struct m0_fdmi_flt_node *root;\n struct m0_buf var = M0_BUF_INITS(g_var_str);\n\n if (first_filter) {\n root = m0_fdmi_flt_op_node_create(\n M0_FFO_OR,\n m0_fdmi_flt_bool_node_create(false),\n m0_fdmi_flt_var_node_create(&var));\n\n m0_fdmi_filter_init(flt);\n\n m0_fdmi_filter_root_set(flt, root);\n\n *out = &g_conf_filter;\n rc = 1;\n first_filter = false;\n } else {\n *out = NULL;\n rc = 0;\n }\n return rc;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "int" (function_declarator) "filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n struct m0_conf_fdmi_filter **out)" (identifier) "filterc_apply_flt_get_next" (parameter_list) "(struct m0_filterc_iter *iter,\n struct m0_conf_fdmi_filter **out)" (() "(" (parameter_declaration) "struct m0_filterc_iter *iter" (struct_specifier) "struct m0_filterc_iter" (struct) "struct" (type_identifier) "m0_filterc_iter" (pointer_declarator) "*iter" (*) "*" (identifier) "iter" (,) "," (parameter_declaration) "struct m0_conf_fdmi_filter **out" (struct_specifier) "struct m0_conf_fdmi_filter" (struct) "struct" (type_identifier) "m0_conf_fdmi_filter" (pointer_declarator) "**out" (*) "*" (pointer_declarator) "*out" (*) "*" (identifier) "out" ()) ")" (compound_statement) "{\n int rc;\n static bool first_filter = true;\n struct m0_fdmi_filter *flt = &g_conf_filter.ff_filter;\n struct m0_fdmi_flt_node *root;\n struct m0_buf var = M0_BUF_INITS(g_var_str);\n\n if (first_filter) {\n root = m0_fdmi_flt_op_node_create(\n M0_FFO_OR,\n m0_fdmi_flt_bool_node_create(false),\n m0_fdmi_flt_var_node_create(&var));\n\n m0_fdmi_filter_init(flt);\n\n m0_fdmi_filter_root_set(flt, root);\n\n *out = &g_conf_filter;\n rc = 1;\n first_filter = false;\n } else {\n *out = NULL;\n rc = 0;\n }\n return rc;\n}" ({) "{" (declaration) "int rc;" (primitive_type) "int" (identifier) "rc" (;) ";" (declaration) "static bool first_filter = true;" (storage_class_specifier) "static" (static) "static" (primitive_type) "bool" (init_declarator) "first_filter = true" (identifier) "first_filter" (=) "=" (true) "true" (;) ";" (declaration) "struct m0_fdmi_filter *flt = &g_conf_filter.ff_filter;" (struct_specifier) "struct m0_fdmi_filter" (struct) "struct" (type_identifier) "m0_fdmi_filter" (init_declarator) "*flt = &g_conf_filter.ff_filter" (pointer_declarator) "*flt" (*) "*" (identifier) "flt" (=) "=" (pointer_expression) "&g_conf_filter.ff_filter" (&) "&" (field_expression) "g_conf_filter.ff_filter" (identifier) "g_conf_filter" (.) "." (field_identifier) "ff_filter" (;) ";" (declaration) "struct m0_fdmi_flt_node *root;" (struct_specifier) "struct m0_fdmi_flt_node" (struct) "struct" (type_identifier) "m0_fdmi_flt_node" (pointer_declarator) "*root" (*) "*" (identifier) "root" (;) ";" (declaration) "struct m0_buf var = M0_BUF_INITS(g_var_str);" (struct_specifier) "struct m0_buf" (struct) "struct" (type_identifier) "m0_buf" (init_declarator) "var = M0_BUF_INITS(g_var_str)" (identifier) "var" (=) "=" (call_expression) "M0_BUF_INITS(g_var_str)" (identifier) "M0_BUF_INITS" (argument_list) "(g_var_str)" (() "(" (identifier) "g_var_str" ()) ")" (;) ";" (if_statement) "if (first_filter) {\n root = m0_fdmi_flt_op_node_create(\n M0_FFO_OR,\n m0_fdmi_flt_bool_node_create(false),\n m0_fdmi_flt_var_node_create(&var));\n\n m0_fdmi_filter_init(flt);\n\n m0_fdmi_filter_root_set(flt, root);\n\n *out = &g_conf_filter;\n rc = 1;\n first_filter = false;\n } else {\n *out = NULL;\n rc = 0;\n }" (if) "if" (parenthesized_expression) "(first_filter)" (() "(" (identifier) "first_filter" ()) ")" (compound_statement) "{\n root = m0_fdmi_flt_op_node_create(\n M0_FFO_OR,\n m0_fdmi_flt_bool_node_create(false),\n m0_fdmi_flt_var_node_create(&var));\n\n m0_fdmi_filter_init(flt);\n\n m0_fdmi_filter_root_set(flt, root);\n\n *out = &g_conf_filter;\n rc = 1;\n first_filter = false;\n }" ({) "{" (expression_statement) "root = m0_fdmi_flt_op_node_create(\n M0_FFO_OR,\n m0_fdmi_flt_bool_node_create(false),\n m0_fdmi_flt_var_node_create(&var));" (assignment_expression) "root = m0_fdmi_flt_op_node_create(\n M0_FFO_OR,\n m0_fdmi_flt_bool_node_create(false),\n m0_fdmi_flt_var_node_create(&var))" (identifier) "root" (=) "=" (call_expression) "m0_fdmi_flt_op_node_create(\n M0_FFO_OR,\n m0_fdmi_flt_bool_node_create(false),\n m0_fdmi_flt_var_node_create(&var))" (identifier) "m0_fdmi_flt_op_node_create" (argument_list) "(\n M0_FFO_OR,\n m0_fdmi_flt_bool_node_create(false),\n m0_fdmi_flt_var_node_create(&var))" (() "(" (identifier) "M0_FFO_OR" (,) "," (call_expression) "m0_fdmi_flt_bool_node_create(false)" (identifier) "m0_fdmi_flt_bool_node_create" (argument_list) "(false)" (() "(" (false) "false" ()) ")" (,) "," (call_expression) "m0_fdmi_flt_var_node_create(&var)" (identifier) "m0_fdmi_flt_var_node_create" (argument_list) "(&var)" (() "(" (pointer_expression) "&var" (&) "&" (identifier) "var" ()) ")" ()) ")" (;) ";" (expression_statement) "m0_fdmi_filter_init(flt);" (call_expression) "m0_fdmi_filter_init(flt)" (identifier) "m0_fdmi_filter_init" (argument_list) "(flt)" (() "(" (identifier) "flt" ()) ")" (;) ";" (expression_statement) "m0_fdmi_filter_root_set(flt, root);" (call_expression) "m0_fdmi_filter_root_set(flt, root)" (identifier) "m0_fdmi_filter_root_set" (argument_list) "(flt, root)" (() "(" (identifier) "flt" (,) "," (identifier) "root" ()) ")" (;) ";" (expression_statement) "*out = &g_conf_filter;" (assignment_expression) "*out = &g_conf_filter" (pointer_expression) "*out" (*) "*" (identifier) "out" (=) "=" (pointer_expression) "&g_conf_filter" (&) "&" (identifier) "g_conf_filter" (;) ";" (expression_statement) "rc = 1;" (assignment_expression) "rc = 1" (identifier) "rc" (=) "=" (number_literal) "1" (;) ";" (expression_statement) "first_filter = false;" (assignment_expression) "first_filter = false" (identifier) "first_filter" (=) "=" (false) "false" (;) ";" (}) "}" (else_clause) "else {\n *out = NULL;\n rc = 0;\n }" (else) "else" (compound_statement) "{\n *out = NULL;\n rc = 0;\n }" ({) "{" (expression_statement) "*out = NULL;" (assignment_expression) "*out = NULL" (pointer_expression) "*out" (*) "*" (identifier) "out" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (expression_statement) "rc = 0;" (assignment_expression) "rc = 0" (identifier) "rc" (=) "=" (number_literal) "0" (;) ";" (}) "}" (return_statement) "return rc;" (return) "return" (identifier) "rc" (;) ";" (}) "}" (function_definition) "static void filterc_apply_flt_close(struct m0_filterc_iter *iter)\n{\n m0_fdmi_filter_fini(&g_conf_filter.ff_filter);\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "filterc_apply_flt_close(struct m0_filterc_iter *iter)" (identifier) "filterc_apply_flt_close" (parameter_list) "(struct m0_filterc_iter *iter)" (() "(" (parameter_declaration) "struct m0_filterc_iter *iter" (struct_specifier) "struct m0_filterc_iter" (struct) "struct" (type_identifier) "m0_filterc_iter" (pointer_declarator) "*iter" (*) "*" (identifier) "iter" ()) ")" (compound_statement) "{\n m0_fdmi_filter_fini(&g_conf_filter.ff_filter);\n}" ({) "{" (expression_statement) "m0_fdmi_filter_fini(&g_conf_filter.ff_filter);" (call_expression) "m0_fdmi_filter_fini(&g_conf_filter.ff_filter)" (identifier) "m0_fdmi_filter_fini" (argument_list) "(&g_conf_filter.ff_filter)" (() "(" (pointer_expression) "&g_conf_filter.ff_filter" (&) "&" (field_expression) "g_conf_filter.ff_filter" (identifier) "g_conf_filter" (.) "." (field_identifier) "ff_filter" ()) ")" (;) ";" (}) "}" (comment) "/*********** Source definition ***********/" (function_definition) "static int test_fs_node_eval(\n struct m0_fdmi_src_rec *src_rec,\n struct m0_fdmi_flt_var_node *value_desc,\n struct m0_fdmi_flt_operand *value)\n{\n M0_UT_ASSERT(src_rec == &g_src_rec);\n M0_UT_ASSERT(src_rec->fsr_data == &g_fdmi_data);\n M0_UT_ASSERT(value_desc->ffvn_data.b_nob == strlen(g_var_str));\n M0_UT_ASSERT(value_desc->ffvn_data.b_addr == g_var_str);\n\n m0_fdmi_flt_bool_opnd_fill(value, false);\n return 0;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "int" (function_declarator) "test_fs_node_eval(\n struct m0_fdmi_src_rec *src_rec,\n struct m0_fdmi_flt_var_node *value_desc,\n struct m0_fdmi_flt_operand *value)" (identifier) "test_fs_node_eval" (parameter_list) "(\n struct m0_fdmi_src_rec *src_rec,\n struct m0_fdmi_flt_var_node *value_desc,\n struct m0_fdmi_flt_operand *value)" (() "(" (parameter_declaration) "struct m0_fdmi_src_rec *src_rec" (struct_specifier) "struct m0_fdmi_src_rec" (struct) "struct" (type_identifier) "m0_fdmi_src_rec" (pointer_declarator) "*src_rec" (*) "*" (identifier) "src_rec" (,) "," (parameter_declaration) "struct m0_fdmi_flt_var_node *value_desc" (struct_specifier) "struct m0_fdmi_flt_var_node" (struct) "struct" (type_identifier) "m0_fdmi_flt_var_node" (pointer_declarator) "*value_desc" (*) "*" (identifier) "value_desc" (,) "," (parameter_declaration) "struct m0_fdmi_flt_operand *value" (struct_specifier) "struct m0_fdmi_flt_operand" (struct) "struct" (type_identifier) "m0_fdmi_flt_operand" (pointer_declarator) "*value" (*) "*" (identifier) "value" ()) ")" (compound_statement) "{\n M0_UT_ASSERT(src_rec == &g_src_rec);\n M0_UT_ASSERT(src_rec->fsr_data == &g_fdmi_data);\n M0_UT_ASSERT(value_desc->ffvn_data.b_nob == strlen(g_var_str));\n M0_UT_ASSERT(value_desc->ffvn_data.b_addr == g_var_str);\n\n m0_fdmi_flt_bool_opnd_fill(value, false);\n return 0;\n}" ({) "{" (expression_statement) "M0_UT_ASSERT(src_rec == &g_src_rec);" (call_expression) "M0_UT_ASSERT(src_rec == &g_src_rec)" (identifier) "M0_UT_ASSERT" (argument_list) "(src_rec == &g_src_rec)" (() "(" (binary_expression) "src_rec == &g_src_rec" (identifier) "src_rec" (==) "==" (pointer_expression) "&g_src_rec" (&) "&" (identifier) "g_src_rec" ()) ")" (;) ";" (expression_statement) "M0_UT_ASSERT(src_rec->fsr_data == &g_fdmi_data);" (call_expression) "M0_UT_ASSERT(src_rec->fsr_data == &g_fdmi_data)" (identifier) "M0_UT_ASSERT" (argument_list) "(src_rec->fsr_data == &g_fdmi_data)" (() "(" (binary_expression) "src_rec->fsr_data == &g_fdmi_data" (field_expression) "src_rec->fsr_data" (identifier) "src_rec" (->) "->" (field_identifier) "fsr_data" (==) "==" (pointer_expression) "&g_fdmi_data" (&) "&" (identifier) "g_fdmi_data" ()) ")" (;) ";" (expression_statement) "M0_UT_ASSERT(value_desc->ffvn_data.b_nob == strlen(g_var_str));" (call_expression) "M0_UT_ASSERT(value_desc->ffvn_data.b_nob == strlen(g_var_str))" (identifier) "M0_UT_ASSERT" (argument_list) "(value_desc->ffvn_data.b_nob == strlen(g_var_str))" (() "(" (binary_expression) "value_desc->ffvn_data.b_nob == strlen(g_var_str)" (field_expression) "value_desc->ffvn_data.b_nob" (field_expression) "value_desc->ffvn_data" (identifier) "value_desc" (->) "->" (field_identifier) "ffvn_data" (.) "." (field_identifier) "b_nob" (==) "==" (call_expression) "strlen(g_var_str)" (identifier) "strlen" (argument_list) "(g_var_str)" (() "(" (identifier) "g_var_str" ()) ")" ()) ")" (;) ";" (expression_statement) "M0_UT_ASSERT(value_desc->ffvn_data.b_addr == g_var_str);" (call_expression) "M0_UT_ASSERT(value_desc->ffvn_data.b_addr == g_var_str)" (identifier) "M0_UT_ASSERT" (argument_list) "(value_desc->ffvn_data.b_addr == g_var_str)" (() "(" (binary_expression) "value_desc->ffvn_data.b_addr == g_var_str" (field_expression) "value_desc->ffvn_data.b_addr" (field_expression) "value_desc->ffvn_data" (identifier) "value_desc" (->) "->" (field_identifier) "ffvn_data" (.) "." (field_identifier) "b_addr" (==) "==" (identifier) "g_var_str" ()) ")" (;) ";" (expression_statement) "m0_fdmi_flt_bool_opnd_fill(value, false);" (call_expression) "m0_fdmi_flt_bool_opnd_fill(value, false)" (identifier) "m0_fdmi_flt_bool_opnd_fill" (argument_list) "(value, false)" (() "(" (identifier) "value" (,) "," (false) "false" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (function_definition) "static int test_fs_encode(struct m0_fdmi_src_rec *src_rec,\n struct m0_buf *buf)\n{\n M0_UT_ASSERT(false);\n return 0;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "int" (function_declarator) "test_fs_encode(struct m0_fdmi_src_rec *src_rec,\n struct m0_buf *buf)" (identifier) "test_fs_encode" (parameter_list) "(struct m0_fdmi_src_rec *src_rec,\n struct m0_buf *buf)" (() "(" (parameter_declaration) "struct m0_fdmi_src_rec *src_rec" (struct_specifier) "struct m0_fdmi_src_rec" (struct) "struct" (type_identifier) "m0_fdmi_src_rec" (pointer_declarator) "*src_rec" (*) "*" (identifier) "src_rec" (,) "," (parameter_declaration) "struct m0_buf *buf" (struct_specifier) "struct m0_buf" (struct) "struct" (type_identifier) "m0_buf" (pointer_declarator) "*buf" (*) "*" (identifier) "buf" ()) ")" (compound_statement) "{\n M0_UT_ASSERT(false);\n return 0;\n}" ({) "{" (expression_statement) "M0_UT_ASSERT(false);" (call_expression) "M0_UT_ASSERT(false)" (identifier) "M0_UT_ASSERT" (argument_list) "(false)" (() "(" (false) "false" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (function_definition) "static void test_fs_get(struct m0_fdmi_src_rec *src_rec)\n{\n M0_UT_ASSERT(false);\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "test_fs_get(struct m0_fdmi_src_rec *src_rec)" (identifier) "test_fs_get" (parameter_list) "(struct m0_fdmi_src_rec *src_rec)" (() "(" (parameter_declaration) "struct m0_fdmi_src_rec *src_rec" (struct_specifier) "struct m0_fdmi_src_rec" (struct) "struct" (type_identifier) "m0_fdmi_src_rec" (pointer_declarator) "*src_rec" (*) "*" (identifier) "src_rec" ()) ")" (compound_statement) "{\n M0_UT_ASSERT(false);\n}" ({) "{" (expression_statement) "M0_UT_ASSERT(false);" (call_expression) "M0_UT_ASSERT(false)" (identifier) "M0_UT_ASSERT" (argument_list) "(false)" (() "(" (false) "false" ()) ")" (;) ";" (}) "}" (function_definition) "static void test_fs_put(struct m0_fdmi_src_rec *src_rec)\n{\n M0_UT_ASSERT(src_rec != NULL);\n M0_UT_ASSERT(src_rec == &g_src_rec);\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "test_fs_put(struct m0_fdmi_src_rec *src_rec)" (identifier) "test_fs_put" (parameter_list) "(struct m0_fdmi_src_rec *src_rec)" (() "(" (parameter_declaration) "struct m0_fdmi_src_rec *src_rec" (struct_specifier) "struct m0_fdmi_src_rec" (struct) "struct" (type_identifier) "m0_fdmi_src_rec" (pointer_declarator) "*src_rec" (*) "*" (identifier) "src_rec" ()) ")" (compound_statement) "{\n M0_UT_ASSERT(src_rec != NULL);\n M0_UT_ASSERT(src_rec == &g_src_rec);\n}" ({) "{" (expression_statement) "M0_UT_ASSERT(src_rec != NULL);" (call_expression) "M0_UT_ASSERT(src_rec != NULL)" (identifier) "M0_UT_ASSERT" (argument_list) "(src_rec != NULL)" (() "(" (binary_expression) "src_rec != NULL" (identifier) "src_rec" (!=) "!=" (null) "NULL" (NULL) "NULL" ()) ")" (;) ";" (expression_statement) "M0_UT_ASSERT(src_rec == &g_src_rec);" (call_expression) "M0_UT_ASSERT(src_rec == &g_src_rec)" (identifier) "M0_UT_ASSERT" (argument_list) "(src_rec == &g_src_rec)" (() "(" (binary_expression) "src_rec == &g_src_rec" (identifier) "src_rec" (==) "==" (pointer_expression) "&g_src_rec" (&) "&" (identifier) "g_src_rec" ()) ")" (;) ";" (}) "}" (function_definition) "static void test_fs_end(struct m0_fdmi_src_rec *src_rec)\n{\n M0_UT_ASSERT(src_rec != NULL);\n M0_UT_ASSERT(src_rec == &g_src_rec);\n /* Calling of this function is a sign for fdmi_sd_post_record UT\n * that FDMI finished record processing */\n m0_semaphore_up(&g_sem);\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "test_fs_end(struct m0_fdmi_src_rec *src_rec)" (identifier) "test_fs_end" (parameter_list) "(struct m0_fdmi_src_rec *src_rec)" (() "(" (parameter_declaration) "struct m0_fdmi_src_rec *src_rec" (struct_specifier) "struct m0_fdmi_src_rec" (struct) "struct" (type_identifier) "m0_fdmi_src_rec" (pointer_declarator) "*src_rec" (*) "*" (identifier) "src_rec" ()) ")" (compound_statement) "{\n M0_UT_ASSERT(src_rec != NULL);\n M0_UT_ASSERT(src_rec == &g_src_rec);\n /* Calling of this function is a sign for fdmi_sd_post_record UT\n * that FDMI finished record processing */\n m0_semaphore_up(&g_sem);\n}" ({) "{" (expression_statement) "M0_UT_ASSERT(src_rec != NULL);" (call_expression) "M0_UT_ASSERT(src_rec != NULL)" (identifier) "M0_UT_ASSERT" (argument_list) "(src_rec != NULL)" (() "(" (binary_expression) "src_rec != NULL" (identifier) "src_rec" (!=) "!=" (null) "NULL" (NULL) "NULL" ()) ")" (;) ";" (expression_statement) "M0_UT_ASSERT(src_rec == &g_src_rec);" (call_expression) "M0_UT_ASSERT(src_rec == &g_src_rec)" (identifier) "M0_UT_ASSERT" (argument_list) "(src_rec == &g_src_rec)" (() "(" (binary_expression) "src_rec == &g_src_rec" (identifier) "src_rec" (==) "==" (pointer_expression) "&g_src_rec" (&) "&" (identifier) "g_src_rec" ()) ")" (;) ";" (comment) "/* Calling of this function is a sign for fdmi_sd_post_record UT\n * that FDMI finished record processing */" (expression_statement) "m0_semaphore_up(&g_sem);" (call_expression) "m0_semaphore_up(&g_sem)" (identifier) "m0_semaphore_up" (argument_list) "(&g_sem)" (() "(" (pointer_expression) "&g_sem" (&) "&" (identifier) "g_sem" ()) ")" (;) ";" (}) "}" (function_definition) "static struct m0_fdmi_src *src_alloc()\n{\n struct m0_fdmi_src *src;\n int rc;\n\n rc = m0_fdmi_source_alloc(M0_FDMI_REC_TYPE_TEST, &src);\n M0_UT_ASSERT(rc == 0);\n\n src->fs_node_eval = test_fs_node_eval;\n src->fs_get = test_fs_get;\n src->fs_put = test_fs_put;\n src->fs_end = test_fs_end;\n src->fs_encode = test_fs_encode;\n return src;\n}" (storage_class_specifier) "static" (static) "static" (struct_specifier) "struct m0_fdmi_src" (struct) "struct" (type_identifier) "m0_fdmi_src" (pointer_declarator) "*src_alloc()" (*) "*" (function_declarator) "src_alloc()" (identifier) "src_alloc" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n struct m0_fdmi_src *src;\n int rc;\n\n rc = m0_fdmi_source_alloc(M0_FDMI_REC_TYPE_TEST, &src);\n M0_UT_ASSERT(rc == 0);\n\n src->fs_node_eval = test_fs_node_eval;\n src->fs_get = test_fs_get;\n src->fs_put = test_fs_put;\n src->fs_end = test_fs_end;\n src->fs_encode = test_fs_encode;\n return src;\n}" ({) "{" (declaration) "struct m0_fdmi_src *src;" (struct_specifier) "struct m0_fdmi_src" (struct) "struct" (type_identifier) "m0_fdmi_src" (pointer_declarator) "*src" (*) "*" (identifier) "src" (;) ";" (declaration) "int rc;" (primitive_type) "int" (identifier) "rc" (;) ";" (expression_statement) "rc = m0_fdmi_source_alloc(M0_FDMI_REC_TYPE_TEST, &src);" (assignment_expression) "rc = m0_fdmi_source_alloc(M0_FDMI_REC_TYPE_TEST, &src)" (identifier) "rc" (=) "=" (call_expression) "m0_fdmi_source_alloc(M0_FDMI_REC_TYPE_TEST, &src)" (identifier) "m0_fdmi_source_alloc" (argument_list) "(M0_FDMI_REC_TYPE_TEST, &src)" (() "(" (identifier) "M0_FDMI_REC_TYPE_TEST" (,) "," (pointer_expression) "&src" (&) "&" (identifier) "src" ()) ")" (;) ";" (expression_statement) "M0_UT_ASSERT(rc == 0);" (call_expression) "M0_UT_ASSERT(rc == 0)" (identifier) "M0_UT_ASSERT" (argument_list) "(rc == 0)" (() "(" (binary_expression) "rc == 0" (identifier) "rc" (==) "==" (number_literal) "0" ()) ")" (;) ";" (expression_statement) "src->fs_node_eval = test_fs_node_eval;" (assignment_expression) "src->fs_node_eval = test_fs_node_eval" (field_expression) "src->fs_node_eval" (identifier) "src" (->) "->" (field_identifier) "fs_node_eval" (=) "=" (identifier) "test_fs_node_eval" (;) ";" (expression_statement) "src->fs_get = test_fs_get;" (assignment_expression) "src->fs_get = test_fs_get" (field_expression) "src->fs_get" (identifier) "src" (->) "->" (field_identifier) "fs_get" (=) "=" (identifier) "test_fs_get" (;) ";" (expression_statement) "src->fs_put = test_fs_put;" (assignment_expression) "src->fs_put = test_fs_put" (field_expression) "src->fs_put" (identifier) "src" (->) "->" (field_identifier) "fs_put" (=) "=" (identifier) "test_fs_put" (;) ";" (expression_statement) "src->fs_end = test_fs_end;" (assignment_expression) "src->fs_end = test_fs_end" (field_expression) "src->fs_end" (identifier) "src" (->) "->" (field_identifier) "fs_end" (=) "=" (identifier) "test_fs_end" (;) ";" (expression_statement) "src->fs_encode = test_fs_encode;" (assignment_expression) "src->fs_encode = test_fs_encode" (field_expression) "src->fs_encode" (identifier) "src" (->) "->" (field_identifier) "fs_encode" (=) "=" (identifier) "test_fs_encode" (;) ";" (return_statement) "return src;" (return) "return" (identifier) "src" (;) ";" (}) "}" (function_definition) "static void fdmi_sd_apply_filter_internal(const struct m0_filterc_ops *ops)\n{\n struct m0_fdmi_src *src = src_alloc();\n int rc;\n\n M0_ENTRY();\n\n g_var_str = strdup("test");\n M0_SET0(&g_conf_filter);\n\n fdmi_serv_start_ut(ops);\n m0_semaphore_init(&g_sem, 0);\n rc = m0_fdmi_source_register(src);\n M0_UT_ASSERT(rc == 0);\n g_src_rec = (struct m0_fdmi_src_rec) {\n .fsr_src = src,\n .fsr_data = g_fdmi_data,\n };\n M0_FDMI_SOURCE_POST_RECORD(&g_src_rec);\n /* Wait until record is processed and released */\n m0_semaphore_down(&g_sem);\n m0_fdmi_source_deregister(src);\n m0_fdmi_source_free(src);\n m0_semaphore_fini(&g_sem);\n fdmi_serv_stop_ut();\n M0_LEAVE();\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "fdmi_sd_apply_filter_internal(const struct m0_filterc_ops *ops)" (identifier) "fdmi_sd_apply_filter_internal" (parameter_list) "(const struct m0_filterc_ops *ops)" (() "(" (parameter_declaration) "const struct m0_filterc_ops *ops" (type_qualifier) "const" (const) "const" (struct_specifier) "struct m0_filterc_ops" (struct) "struct" (type_identifier) "m0_filterc_ops" (pointer_declarator) "*ops" (*) "*" (identifier) "ops" ()) ")" (compound_statement) "{\n struct m0_fdmi_src *src = src_alloc();\n int rc;\n\n M0_ENTRY();\n\n g_var_str = strdup("test");\n M0_SET0(&g_conf_filter);\n\n fdmi_serv_start_ut(ops);\n m0_semaphore_init(&g_sem, 0);\n rc = m0_fdmi_source_register(src);\n M0_UT_ASSERT(rc == 0);\n g_src_rec = (struct m0_fdmi_src_rec) {\n .fsr_src = src,\n .fsr_data = g_fdmi_data,\n };\n M0_FDMI_SOURCE_POST_RECORD(&g_src_rec);\n /* Wait until record is processed and released */\n m0_semaphore_down(&g_sem);\n m0_fdmi_source_deregister(src);\n m0_fdmi_source_free(src);\n m0_semaphore_fini(&g_sem);\n fdmi_serv_stop_ut();\n M0_LEAVE();\n}" ({) "{" (declaration) "struct m0_fdmi_src *src = src_alloc();" (struct_specifier) "struct m0_fdmi_src" (struct) "struct" (type_identifier) "m0_fdmi_src" (init_declarator) "*src = src_alloc()" (pointer_declarator) "*src" (*) "*" (identifier) "src" (=) "=" (call_expression) "src_alloc()" (identifier) "src_alloc" (argument_list) "()" (() "(" ()) ")" (;) ";" (declaration) "int rc;" (primitive_type) "int" (identifier) "rc" (;) ";" (expression_statement) "M0_ENTRY();" (call_expression) "M0_ENTRY()" (identifier) "M0_ENTRY" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "g_var_str = strdup("test");" (assignment_expression) "g_var_str = strdup("test")" (identifier) "g_var_str" (=) "=" (call_expression) "strdup("test")" (identifier) "strdup" (argument_list) "("test")" (() "(" (string_literal) ""test"" (") """ (string_content) "test" (") """ ()) ")" (;) ";" (expression_statement) "M0_SET0(&g_conf_filter);" (call_expression) "M0_SET0(&g_conf_filter)" (identifier) "M0_SET0" (argument_list) "(&g_conf_filter)" (() "(" (pointer_expression) "&g_conf_filter" (&) "&" (identifier) "g_conf_filter" ()) ")" (;) ";" (expression_statement) "fdmi_serv_start_ut(ops);" (call_expression) "fdmi_serv_start_ut(ops)" (identifier) "fdmi_serv_start_ut" (argument_list) "(ops)" (() "(" (identifier) "ops" ()) ")" (;) ";" (expression_statement) "m0_semaphore_init(&g_sem, 0);" (call_expression) "m0_semaphore_init(&g_sem, 0)" (identifier) "m0_semaphore_init" (argument_list) "(&g_sem, 0)" (() "(" (pointer_expression) "&g_sem" (&) "&" (identifier) "g_sem" (,) "," (number_literal) "0" ()) ")" (;) ";" (expression_statement) "rc = m0_fdmi_source_register(src);" (assignment_expression) "rc = m0_fdmi_source_register(src)" (identifier) "rc" (=) "=" (call_expression) "m0_fdmi_source_register(src)" (identifier) "m0_fdmi_source_register" (argument_list) "(src)" (() "(" (identifier) "src" ()) ")" (;) ";" (expression_statement) "M0_UT_ASSERT(rc == 0);" (call_expression) "M0_UT_ASSERT(rc == 0)" (identifier) "M0_UT_ASSERT" (argument_list) "(rc == 0)" (() "(" (binary_expression) "rc == 0" (identifier) "rc" (==) "==" (number_literal) "0" ()) ")" (;) ";" (expression_statement) "g_src_rec = (struct m0_fdmi_src_rec) {\n .fsr_src = src,\n .fsr_data = g_fdmi_data,\n };" (assignment_expression) "g_src_rec = (struct m0_fdmi_src_rec) {\n .fsr_src = src,\n .fsr_data = g_fdmi_data,\n }" (identifier) "g_src_rec" (=) "=" (compound_literal_expression) "(struct m0_fdmi_src_rec) {\n .fsr_src = src,\n .fsr_data = g_fdmi_data,\n }" (() "(" (type_descriptor) "struct m0_fdmi_src_rec" (struct_specifier) "struct m0_fdmi_src_rec" (struct) "struct" (type_identifier) "m0_fdmi_src_rec" ()) ")" (initializer_list) "{\n .fsr_src = src,\n .fsr_data = g_fdmi_data,\n }" ({) "{" (initializer_pair) ".fsr_src = src" (field_designator) ".fsr_src" (.) "." (field_identifier) "fsr_src" (=) "=" (identifier) "src" (,) "," (initializer_pair) ".fsr_data = g_fdmi_data" (field_designator) ".fsr_data" (.) "." (field_identifier) "fsr_data" (=) "=" (identifier) "g_fdmi_data" (,) "," (}) "}" (;) ";" (expression_statement) "M0_FDMI_SOURCE_POST_RECORD(&g_src_rec);" (call_expression) "M0_FDMI_SOURCE_POST_RECORD(&g_src_rec)" (identifier) "M0_FDMI_SOURCE_POST_RECORD" (argument_list) "(&g_src_rec)" (() "(" (pointer_expression) "&g_src_rec" (&) "&" (identifier) "g_src_rec" ()) ")" (;) ";" (comment) "/* Wait until record is processed and released */" (expression_statement) "m0_semaphore_down(&g_sem);" (call_expression) "m0_semaphore_down(&g_sem)" (identifier) "m0_semaphore_down" (argument_list) "(&g_sem)" (() "(" (pointer_expression) "&g_sem" (&) "&" (identifier) "g_sem" ()) ")" (;) ";" (expression_statement) "m0_fdmi_source_deregister(src);" (call_expression) "m0_fdmi_source_deregister(src)" (identifier) "m0_fdmi_source_deregister" (argument_list) "(src)" (() "(" (identifier) "src" ()) ")" (;) ";" (expression_statement) "m0_fdmi_source_free(src);" (call_expression) "m0_fdmi_source_free(src)" (identifier) "m0_fdmi_source_free" (argument_list) "(src)" (() "(" (identifier) "src" ()) ")" (;) ";" (expression_statement) "m0_semaphore_fini(&g_sem);" (call_expression) "m0_semaphore_fini(&g_sem)" (identifier) "m0_semaphore_fini" (argument_list) "(&g_sem)" (() "(" (pointer_expression) "&g_sem" (&) "&" (identifier) "g_sem" ()) ")" (;) ";" (expression_statement) "fdmi_serv_stop_ut();" (call_expression) "fdmi_serv_stop_ut()" (identifier) "fdmi_serv_stop_ut" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "M0_LEAVE();" (call_expression) "M0_LEAVE()" (identifier) "M0_LEAVE" (argument_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (function_definition) "void fdmi_sd_apply_filter(void)\n{\n M0_ENTRY();\n fdmi_sd_apply_filter_internal(&filterc_apply_flt_ops);\n M0_LEAVE();\n}" (primitive_type) "void" (function_declarator) "fdmi_sd_apply_filter(void)" (identifier) "fdmi_sd_apply_filter" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (compound_statement) "{\n M0_ENTRY();\n fdmi_sd_apply_filter_internal(&filterc_apply_flt_ops);\n M0_LEAVE();\n}" ({) "{" (expression_statement) "M0_ENTRY();" (call_expression) "M0_ENTRY()" (identifier) "M0_ENTRY" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "fdmi_sd_apply_filter_internal(&filterc_apply_flt_ops);" (call_expression) "fdmi_sd_apply_filter_internal(&filterc_apply_flt_ops)" (identifier) "fdmi_sd_apply_filter_internal" (argument_list) "(&filterc_apply_flt_ops)" (() "(" (pointer_expression) "&filterc_apply_flt_ops" (&) "&" (identifier) "filterc_apply_flt_ops" ()) ")" (;) ";" (expression_statement) "M0_LEAVE();" (call_expression) "M0_LEAVE()" (identifier) "M0_LEAVE" (argument_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (preproc_call) "#undef M0_TRACE_SUBSYSTEM\n" (preproc_directive) "#undef" (preproc_arg) "M0_TRACE_SUBSYSTEM" (comment) "/*\n * Local variables:\n * c-indentation-style: "K&R"\n * c-basic-offset: 8\n * tab-width: 8\n * fill-column: 80\n * scroll-step: 1\n * End:\n */" (comment) "/*\n * vim: tabstop=8 shiftwidth=8 noexpandtab textwidth=80 nowrap\n */"
1,191
0
{"language": "c", "success": true, "metadata": {"lines": 186, "avg_line_length": 29.49, "nodes": 747, "errors": 0, "source_hash": "d80e142287d0eef16ae0545144af3e01ad3c352f173239e5a70b530fc6a44413", "categorized_nodes": 524}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_def", "text": "#define M0_TRACE_SUBSYSTEM M0_TRACE_SUBSYS_FDMI\n", "parent": null, "children": [1, 2, 3], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 23, "column": 0}}, {"id": 1, "type": "#define", "text": "#define", "parent": 0, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 7}}, {"id": 2, "type": "identifier", "text": "M0_TRACE_SUBSYSTEM", "parent": 0, "children": [], "start_point": {"row": 22, "column": 8}, "end_point": {"row": 22, "column": 26}}, {"id": 3, "type": "preproc_arg", "text": "M0_TRACE_SUBSYS_FDMI", "parent": 0, "children": [], "start_point": {"row": 22, "column": 27}, "end_point": {"row": 22, "column": 47}}, {"id": 4, "type": "preproc_include", "text": "#include \"lib/trace.h\"\n", "parent": null, "children": [5, 6], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 24, "column": 0}}, {"id": 5, "type": "#include", "text": "#include", "parent": 4, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 8}}, {"id": 6, "type": "string_literal", "text": "\"lib/trace.h\"", "parent": 4, "children": [], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 22}}, {"id": 7, "type": "preproc_include", "text": "#include \"lib/memory.h\"\n", "parent": null, "children": [8, 9], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 26, "column": 0}}, {"id": 8, "type": "#include", "text": "#include", "parent": 7, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 8}}, {"id": 9, "type": "string_literal", "text": "\"lib/memory.h\"", "parent": 7, "children": [], "start_point": {"row": 25, "column": 9}, "end_point": {"row": 25, "column": 23}}, {"id": 10, "type": "preproc_include", "text": "#include \"ut/ut.h\"\n", "parent": null, "children": [11, 12], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 27, "column": 0}}, {"id": 11, "type": "#include", "text": "#include", "parent": 10, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 8}}, {"id": 12, "type": "string_literal", "text": "\"ut/ut.h\"", "parent": 10, "children": [], "start_point": {"row": 26, "column": 9}, "end_point": {"row": 26, "column": 18}}, {"id": 13, "type": "preproc_include", "text": "#include \"fdmi/fdmi.h\"\n", "parent": null, "children": [14, 15], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 28, "column": 0}}, {"id": 14, "type": "#include", "text": "#include", "parent": 13, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 8}}, {"id": 15, "type": "string_literal", "text": "\"fdmi/fdmi.h\"", "parent": 13, "children": [], "start_point": {"row": 27, "column": 9}, "end_point": {"row": 27, "column": 22}}, {"id": 16, "type": "preproc_include", "text": "#include \"fdmi/service.h\" /* m0_reqh_fdmi_service */\n", "parent": null, "children": [17, 18], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 29, "column": 0}}, {"id": 17, "type": "#include", "text": "#include", "parent": 16, "children": [], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 8}}, {"id": 18, "type": "string_literal", "text": "\"fdmi/service.h\"", "parent": 16, "children": [], "start_point": {"row": 28, "column": 9}, "end_point": {"row": 28, "column": 25}}, {"id": 19, "type": "preproc_include", "text": "#include \"fdmi/source_dock_internal.h\"\n", "parent": null, "children": [20, 21], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 30, "column": 0}}, {"id": 20, "type": "#include", "text": "#include", "parent": 19, "children": [], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 8}}, {"id": 21, "type": "string_literal", "text": "\"fdmi/source_dock_internal.h\"", "parent": 19, "children": [], "start_point": {"row": 29, "column": 9}, "end_point": {"row": 29, "column": 38}}, {"id": 22, "type": "preproc_include", "text": "#include \"fdmi/ut/sd_common.h\"\n", "parent": null, "children": [23, 24], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 32, "column": 0}}, {"id": 23, "type": "#include", "text": "#include", "parent": 22, "children": [], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 31, "column": 8}}, {"id": 24, "type": "string_literal", "text": "\"fdmi/ut/sd_common.h\"", "parent": 22, "children": [], "start_point": {"row": 31, "column": 9}, "end_point": {"row": 31, "column": 30}}, {"id": 25, "type": "declaration", "text": "static struct m0_semaphore g_sem;", "parent": null, "children": [26, 29], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 33, "column": 36}}, {"id": 26, "type": "struct_specifier", "text": "struct m0_semaphore", "parent": 25, "children": [27, 28], "start_point": {"row": 33, "column": 7}, "end_point": {"row": 33, "column": 26}}, {"id": 27, "type": "struct", "text": "struct", "parent": 26, "children": [], "start_point": {"row": 33, "column": 7}, "end_point": {"row": 33, "column": 13}}, {"id": 28, "type": "type_identifier", "text": "m0_semaphore", "parent": 26, "children": [], "start_point": {"row": 33, "column": 14}, "end_point": {"row": 33, "column": 26}}, {"id": 29, "type": "identifier", "text": "g_sem", "parent": 25, "children": [], "start_point": {"row": 33, "column": 30}, "end_point": {"row": 33, "column": 35}}, {"id": 30, "type": "declaration", "text": "static char g_fdmi_data[] = \"hello, FDMI\";", "parent": null, "children": [31, 32], "start_point": {"row": 34, "column": 0}, "end_point": {"row": 34, "column": 60}}, {"id": 31, "type": "primitive_type", "text": "char", "parent": 30, "children": [], "start_point": {"row": 34, "column": 7}, "end_point": {"row": 34, "column": 11}}, {"id": 32, "type": "init_declarator", "text": "g_fdmi_data[] = \"hello, FDMI\"", "parent": 30, "children": [33, 35, 36], "start_point": {"row": 34, "column": 30}, "end_point": {"row": 34, "column": 59}}, {"id": 33, "type": "array_declarator", "text": "g_fdmi_data[]", "parent": 32, "children": [34], "start_point": {"row": 34, "column": 30}, "end_point": {"row": 34, "column": 43}}, {"id": 34, "type": "identifier", "text": "g_fdmi_data", "parent": 33, "children": [], "start_point": {"row": 34, "column": 30}, "end_point": {"row": 34, "column": 41}}, {"id": 35, "type": "=", "text": "=", "parent": 32, "children": [], "start_point": {"row": 34, "column": 44}, "end_point": {"row": 34, "column": 45}}, {"id": 36, "type": "string_literal", "text": "\"hello, FDMI\"", "parent": 32, "children": [], "start_point": {"row": 34, "column": 46}, "end_point": {"row": 34, "column": 59}}, {"id": 37, "type": "declaration", "text": "static struct m0_fdmi_src_rec g_src_rec;", "parent": null, "children": [38, 41], "start_point": {"row": 35, "column": 0}, "end_point": {"row": 35, "column": 40}}, {"id": 38, "type": "struct_specifier", "text": "struct m0_fdmi_src_rec", "parent": 37, "children": [39, 40], "start_point": {"row": 35, "column": 7}, "end_point": {"row": 35, "column": 29}}, {"id": 39, "type": "struct", "text": "struct", "parent": 38, "children": [], "start_point": {"row": 35, "column": 7}, "end_point": {"row": 35, "column": 13}}, {"id": 40, "type": "type_identifier", "text": "m0_fdmi_src_rec", "parent": 38, "children": [], "start_point": {"row": 35, "column": 14}, "end_point": {"row": 35, "column": 29}}, {"id": 41, "type": "identifier", "text": "g_src_rec", "parent": 37, "children": [], "start_point": {"row": 35, "column": 30}, "end_point": {"row": 35, "column": 39}}, {"id": 42, "type": "declaration", "text": "static struct m0_conf_fdmi_filter g_conf_filter;", "parent": null, "children": [43, 46], "start_point": {"row": 39, "column": 0}, "end_point": {"row": 39, "column": 48}}, {"id": 43, "type": "struct_specifier", "text": "struct m0_conf_fdmi_filter", "parent": 42, "children": [44, 45], "start_point": {"row": 39, "column": 7}, "end_point": {"row": 39, "column": 33}}, {"id": 44, "type": "struct", "text": "struct", "parent": 43, "children": [], "start_point": {"row": 39, "column": 7}, "end_point": {"row": 39, "column": 13}}, {"id": 45, "type": "type_identifier", "text": "m0_conf_fdmi_filter", "parent": 43, "children": [], "start_point": {"row": 39, "column": 14}, "end_point": {"row": 39, "column": 33}}, {"id": 46, "type": "identifier", "text": "g_conf_filter", "parent": 42, "children": [], "start_point": {"row": 39, "column": 34}, "end_point": {"row": 39, "column": 47}}, {"id": 47, "type": "declaration", "text": "static char *g_var_str;", "parent": null, "children": [48, 49], "start_point": {"row": 40, "column": 0}, "end_point": {"row": 40, "column": 23}}, {"id": 48, "type": "primitive_type", "text": "char", "parent": 47, "children": [], "start_point": {"row": 40, "column": 7}, "end_point": {"row": 40, "column": 11}}, {"id": 49, "type": "pointer_declarator", "text": "*g_var_str", "parent": 47, "children": [50, 51], "start_point": {"row": 40, "column": 12}, "end_point": {"row": 40, "column": 22}}, {"id": 50, "type": "*", "text": "*", "parent": 49, "children": [], "start_point": {"row": 40, "column": 12}, "end_point": {"row": 40, "column": 13}}, {"id": 51, "type": "identifier", "text": "g_var_str", "parent": 49, "children": [], "start_point": {"row": 40, "column": 13}, "end_point": {"row": 40, "column": 22}}, {"id": 52, "type": "declaration", "text": "static int filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n\t\t\t\t struct m0_reqh *reqh);", "parent": null, "children": [53, 54], "start_point": {"row": 42, "column": 0}, "end_point": {"row": 43, "column": 36}}, {"id": 53, "type": "primitive_type", "text": "int", "parent": 52, "children": [], "start_point": {"row": 42, "column": 7}, "end_point": {"row": 42, "column": 10}}, {"id": 54, "type": "function_declarator", "text": "filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n\t\t\t\t struct m0_reqh *reqh)", "parent": 52, "children": [55, 56], "start_point": {"row": 42, "column": 11}, "end_point": {"row": 43, "column": 35}}, {"id": 55, "type": "identifier", "text": "filterc_apply_flt_start", "parent": 54, "children": [], "start_point": {"row": 42, "column": 11}, "end_point": {"row": 42, "column": 34}}, {"id": 56, "type": "parameter_list", "text": "(struct m0_filterc_ctx *ctx,\n\t\t\t\t struct m0_reqh *reqh)", "parent": 54, "children": [57, 64], "start_point": {"row": 42, "column": 34}, "end_point": {"row": 43, "column": 35}}, {"id": 57, "type": "parameter_declaration", "text": "struct m0_filterc_ctx *ctx", "parent": 56, "children": [58, 61], "start_point": {"row": 42, "column": 35}, "end_point": {"row": 42, "column": 61}}, {"id": 58, "type": "struct_specifier", "text": "struct m0_filterc_ctx", "parent": 57, "children": [59, 60], "start_point": {"row": 42, "column": 35}, "end_point": {"row": 42, "column": 56}}, {"id": 59, "type": "struct", "text": "struct", "parent": 58, "children": [], "start_point": {"row": 42, "column": 35}, "end_point": {"row": 42, "column": 41}}, {"id": 60, "type": "type_identifier", "text": "m0_filterc_ctx", "parent": 58, "children": [], "start_point": {"row": 42, "column": 42}, "end_point": {"row": 42, "column": 56}}, {"id": 61, "type": "pointer_declarator", "text": "*ctx", "parent": 57, "children": [62, 63], "start_point": {"row": 42, "column": 57}, "end_point": {"row": 42, "column": 61}}, {"id": 62, "type": "*", "text": "*", "parent": 61, "children": [], "start_point": {"row": 42, "column": 57}, "end_point": {"row": 42, "column": 58}}, {"id": 63, "type": "identifier", "text": "ctx", "parent": 61, "children": [], "start_point": {"row": 42, "column": 58}, "end_point": {"row": 42, "column": 61}}, {"id": 64, "type": "parameter_declaration", "text": "struct m0_reqh *reqh", "parent": 56, "children": [65, 68], "start_point": {"row": 43, "column": 7}, "end_point": {"row": 43, "column": 34}}, {"id": 65, "type": "struct_specifier", "text": "struct m0_reqh", "parent": 64, "children": [66, 67], "start_point": {"row": 43, "column": 7}, "end_point": {"row": 43, "column": 21}}, {"id": 66, "type": "struct", "text": "struct", "parent": 65, "children": [], "start_point": {"row": 43, "column": 7}, "end_point": {"row": 43, "column": 13}}, {"id": 67, "type": "type_identifier", "text": "m0_reqh", "parent": 65, "children": [], "start_point": {"row": 43, "column": 14}, "end_point": {"row": 43, "column": 21}}, {"id": 68, "type": "pointer_declarator", "text": "*reqh", "parent": 64, "children": [69, 70], "start_point": {"row": 43, "column": 29}, "end_point": {"row": 43, "column": 34}}, {"id": 69, "type": "*", "text": "*", "parent": 68, "children": [], "start_point": {"row": 43, "column": 29}, "end_point": {"row": 43, "column": 30}}, {"id": 70, "type": "identifier", "text": "reqh", "parent": 68, "children": [], "start_point": {"row": 43, "column": 30}, "end_point": {"row": 43, "column": 34}}, {"id": 71, "type": "declaration", "text": "static void filterc_apply_flt_stop(struct m0_filterc_ctx *ctx);", "parent": null, "children": [72, 73], "start_point": {"row": 45, "column": 0}, "end_point": {"row": 45, "column": 63}}, {"id": 72, "type": "primitive_type", "text": "void", "parent": 71, "children": [], "start_point": {"row": 45, "column": 7}, "end_point": {"row": 45, "column": 11}}, {"id": 73, "type": "function_declarator", "text": "filterc_apply_flt_stop(struct m0_filterc_ctx *ctx)", "parent": 71, "children": [74, 75], "start_point": {"row": 45, "column": 12}, "end_point": {"row": 45, "column": 62}}, {"id": 74, "type": "identifier", "text": "filterc_apply_flt_stop", "parent": 73, "children": [], "start_point": {"row": 45, "column": 12}, "end_point": {"row": 45, "column": 34}}, {"id": 75, "type": "parameter_list", "text": "(struct m0_filterc_ctx *ctx)", "parent": 73, "children": [76], "start_point": {"row": 45, "column": 34}, "end_point": {"row": 45, "column": 62}}, {"id": 76, "type": "parameter_declaration", "text": "struct m0_filterc_ctx *ctx", "parent": 75, "children": [77, 80], "start_point": {"row": 45, "column": 35}, "end_point": {"row": 45, "column": 61}}, {"id": 77, "type": "struct_specifier", "text": "struct m0_filterc_ctx", "parent": 76, "children": [78, 79], "start_point": {"row": 45, "column": 35}, "end_point": {"row": 45, "column": 56}}, {"id": 78, "type": "struct", "text": "struct", "parent": 77, "children": [], "start_point": {"row": 45, "column": 35}, "end_point": {"row": 45, "column": 41}}, {"id": 79, "type": "type_identifier", "text": "m0_filterc_ctx", "parent": 77, "children": [], "start_point": {"row": 45, "column": 42}, "end_point": {"row": 45, "column": 56}}, {"id": 80, "type": "pointer_declarator", "text": "*ctx", "parent": 76, "children": [81, 82], "start_point": {"row": 45, "column": 57}, "end_point": {"row": 45, "column": 61}}, {"id": 81, "type": "*", "text": "*", "parent": 80, "children": [], "start_point": {"row": 45, "column": 57}, "end_point": {"row": 45, "column": 58}}, {"id": 82, "type": "identifier", "text": "ctx", "parent": 80, "children": [], "start_point": {"row": 45, "column": 58}, "end_point": {"row": 45, "column": 61}}, {"id": 83, "type": "declaration", "text": "static int filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n\t\t\t\t enum m0_fdmi_rec_type_id rec_type_id,\n\t\t\t\t struct m0_filterc_iter *iter);", "parent": null, "children": [84, 85], "start_point": {"row": 47, "column": 0}, "end_point": {"row": 49, "column": 37}}, {"id": 84, "type": "primitive_type", "text": "int", "parent": 83, "children": [], "start_point": {"row": 47, "column": 7}, "end_point": {"row": 47, "column": 10}}, {"id": 85, "type": "function_declarator", "text": "filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n\t\t\t\t enum m0_fdmi_rec_type_id rec_type_id,\n\t\t\t\t struct m0_filterc_iter *iter)", "parent": 83, "children": [86, 87], "start_point": {"row": 47, "column": 11}, "end_point": {"row": 49, "column": 36}}, {"id": 86, "type": "identifier", "text": "filterc_apply_flt_open", "parent": 85, "children": [], "start_point": {"row": 47, "column": 11}, "end_point": {"row": 47, "column": 33}}, {"id": 87, "type": "parameter_list", "text": "(struct m0_filterc_ctx *ctx,\n\t\t\t\t enum m0_fdmi_rec_type_id rec_type_id,\n\t\t\t\t struct m0_filterc_iter *iter)", "parent": 85, "children": [88, 95, 100], "start_point": {"row": 47, "column": 33}, "end_point": {"row": 49, "column": 36}}, {"id": 88, "type": "parameter_declaration", "text": "struct m0_filterc_ctx *ctx", "parent": 87, "children": [89, 92], "start_point": {"row": 47, "column": 34}, "end_point": {"row": 47, "column": 62}}, {"id": 89, "type": "struct_specifier", "text": "struct m0_filterc_ctx", "parent": 88, "children": [90, 91], "start_point": {"row": 47, "column": 34}, "end_point": {"row": 47, "column": 55}}, {"id": 90, "type": "struct", "text": "struct", "parent": 89, "children": [], "start_point": {"row": 47, "column": 34}, "end_point": {"row": 47, "column": 40}}, {"id": 91, "type": "type_identifier", "text": "m0_filterc_ctx", "parent": 89, "children": [], "start_point": {"row": 47, "column": 41}, "end_point": {"row": 47, "column": 55}}, {"id": 92, "type": "pointer_declarator", "text": "*ctx", "parent": 88, "children": [93, 94], "start_point": {"row": 47, "column": 58}, "end_point": {"row": 47, "column": 62}}, {"id": 93, "type": "*", "text": "*", "parent": 92, "children": [], "start_point": {"row": 47, "column": 58}, "end_point": {"row": 47, "column": 59}}, {"id": 94, "type": "identifier", "text": "ctx", "parent": 92, "children": [], "start_point": {"row": 47, "column": 59}, "end_point": {"row": 47, "column": 62}}, {"id": 95, "type": "parameter_declaration", "text": "enum m0_fdmi_rec_type_id rec_type_id", "parent": 87, "children": [96, 99], "start_point": {"row": 48, "column": 6}, "end_point": {"row": 48, "column": 42}}, {"id": 96, "type": "enum_specifier", "text": "enum m0_fdmi_rec_type_id", "parent": 95, "children": [97, 98], "start_point": {"row": 48, "column": 6}, "end_point": {"row": 48, "column": 30}}, {"id": 97, "type": "enum", "text": "enum", "parent": 96, "children": [], "start_point": {"row": 48, "column": 6}, "end_point": {"row": 48, "column": 10}}, {"id": 98, "type": "type_identifier", "text": "m0_fdmi_rec_type_id", "parent": 96, "children": [], "start_point": {"row": 48, "column": 11}, "end_point": {"row": 48, "column": 30}}, {"id": 99, "type": "identifier", "text": "rec_type_id", "parent": 95, "children": [], "start_point": {"row": 48, "column": 31}, "end_point": {"row": 48, "column": 42}}, {"id": 100, "type": "parameter_declaration", "text": "struct m0_filterc_iter *iter", "parent": 87, "children": [101, 104], "start_point": {"row": 49, "column": 6}, "end_point": {"row": 49, "column": 35}}, {"id": 101, "type": "struct_specifier", "text": "struct m0_filterc_iter", "parent": 100, "children": [102, 103], "start_point": {"row": 49, "column": 6}, "end_point": {"row": 49, "column": 28}}, {"id": 102, "type": "struct", "text": "struct", "parent": 101, "children": [], "start_point": {"row": 49, "column": 6}, "end_point": {"row": 49, "column": 12}}, {"id": 103, "type": "type_identifier", "text": "m0_filterc_iter", "parent": 101, "children": [], "start_point": {"row": 49, "column": 13}, "end_point": {"row": 49, "column": 28}}, {"id": 104, "type": "pointer_declarator", "text": "*iter", "parent": 100, "children": [105, 106], "start_point": {"row": 49, "column": 30}, "end_point": {"row": 49, "column": 35}}, {"id": 105, "type": "*", "text": "*", "parent": 104, "children": [], "start_point": {"row": 49, "column": 30}, "end_point": {"row": 49, "column": 31}}, {"id": 106, "type": "identifier", "text": "iter", "parent": 104, "children": [], "start_point": {"row": 49, "column": 31}, "end_point": {"row": 49, "column": 35}}, {"id": 107, "type": "declaration", "text": "static int filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n\t\t\t\t struct m0_conf_fdmi_filter **out);", "parent": null, "children": [108, 109], "start_point": {"row": 51, "column": 0}, "end_point": {"row": 52, "column": 44}}, {"id": 108, "type": "primitive_type", "text": "int", "parent": 107, "children": [], "start_point": {"row": 51, "column": 7}, "end_point": {"row": 51, "column": 10}}, {"id": 109, "type": "function_declarator", "text": "filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n\t\t\t\t struct m0_conf_fdmi_filter **out)", "parent": 107, "children": [110, 111], "start_point": {"row": 51, "column": 11}, "end_point": {"row": 52, "column": 43}}, {"id": 110, "type": "identifier", "text": "filterc_apply_flt_get_next", "parent": 109, "children": [], "start_point": {"row": 51, "column": 11}, "end_point": {"row": 51, "column": 37}}, {"id": 111, "type": "parameter_list", "text": "(struct m0_filterc_iter *iter,\n\t\t\t\t struct m0_conf_fdmi_filter **out)", "parent": 109, "children": [112, 119], "start_point": {"row": 51, "column": 37}, "end_point": {"row": 52, "column": 43}}, {"id": 112, "type": "parameter_declaration", "text": "struct m0_filterc_iter *iter", "parent": 111, "children": [113, 116], "start_point": {"row": 51, "column": 38}, "end_point": {"row": 51, "column": 70}}, {"id": 113, "type": "struct_specifier", "text": "struct m0_filterc_iter", "parent": 112, "children": [114, 115], "start_point": {"row": 51, "column": 38}, "end_point": {"row": 51, "column": 60}}, {"id": 114, "type": "struct", "text": "struct", "parent": 113, "children": [], "start_point": {"row": 51, "column": 38}, "end_point": {"row": 51, "column": 44}}, {"id": 115, "type": "type_identifier", "text": "m0_filterc_iter", "parent": 113, "children": [], "start_point": {"row": 51, "column": 45}, "end_point": {"row": 51, "column": 60}}, {"id": 116, "type": "pointer_declarator", "text": "*iter", "parent": 112, "children": [117, 118], "start_point": {"row": 51, "column": 65}, "end_point": {"row": 51, "column": 70}}, {"id": 117, "type": "*", "text": "*", "parent": 116, "children": [], "start_point": {"row": 51, "column": 65}, "end_point": {"row": 51, "column": 66}}, {"id": 118, "type": "identifier", "text": "iter", "parent": 116, "children": [], "start_point": {"row": 51, "column": 66}, "end_point": {"row": 51, "column": 70}}, {"id": 119, "type": "parameter_declaration", "text": "struct m0_conf_fdmi_filter **out", "parent": 111, "children": [120, 123], "start_point": {"row": 52, "column": 10}, "end_point": {"row": 52, "column": 42}}, {"id": 120, "type": "struct_specifier", "text": "struct m0_conf_fdmi_filter", "parent": 119, "children": [121, 122], "start_point": {"row": 52, "column": 10}, "end_point": {"row": 52, "column": 36}}, {"id": 121, "type": "struct", "text": "struct", "parent": 120, "children": [], "start_point": {"row": 52, "column": 10}, "end_point": {"row": 52, "column": 16}}, {"id": 122, "type": "type_identifier", "text": "m0_conf_fdmi_filter", "parent": 120, "children": [], "start_point": {"row": 52, "column": 17}, "end_point": {"row": 52, "column": 36}}, {"id": 123, "type": "pointer_declarator", "text": "**out", "parent": 119, "children": [124, 125], "start_point": {"row": 52, "column": 37}, "end_point": {"row": 52, "column": 42}}, {"id": 124, "type": "*", "text": "*", "parent": 123, "children": [], "start_point": {"row": 52, "column": 37}, "end_point": {"row": 52, "column": 38}}, {"id": 125, "type": "pointer_declarator", "text": "*out", "parent": 123, "children": [126, 127], "start_point": {"row": 52, "column": 38}, "end_point": {"row": 52, "column": 42}}, {"id": 126, "type": "*", "text": "*", "parent": 125, "children": [], "start_point": {"row": 52, "column": 38}, "end_point": {"row": 52, "column": 39}}, {"id": 127, "type": "identifier", "text": "out", "parent": 125, "children": [], "start_point": {"row": 52, "column": 39}, "end_point": {"row": 52, "column": 42}}, {"id": 128, "type": "declaration", "text": "static void filterc_apply_flt_close(struct m0_filterc_iter *iter);", "parent": null, "children": [129, 130], "start_point": {"row": 54, "column": 0}, "end_point": {"row": 54, "column": 66}}, {"id": 129, "type": "primitive_type", "text": "void", "parent": 128, "children": [], "start_point": {"row": 54, "column": 7}, "end_point": {"row": 54, "column": 11}}, {"id": 130, "type": "function_declarator", "text": "filterc_apply_flt_close(struct m0_filterc_iter *iter)", "parent": 128, "children": [131, 132], "start_point": {"row": 54, "column": 12}, "end_point": {"row": 54, "column": 65}}, {"id": 131, "type": "identifier", "text": "filterc_apply_flt_close", "parent": 130, "children": [], "start_point": {"row": 54, "column": 12}, "end_point": {"row": 54, "column": 35}}, {"id": 132, "type": "parameter_list", "text": "(struct m0_filterc_iter *iter)", "parent": 130, "children": [133], "start_point": {"row": 54, "column": 35}, "end_point": {"row": 54, "column": 65}}, {"id": 133, "type": "parameter_declaration", "text": "struct m0_filterc_iter *iter", "parent": 132, "children": [134, 137], "start_point": {"row": 54, "column": 36}, "end_point": {"row": 54, "column": 64}}, {"id": 134, "type": "struct_specifier", "text": "struct m0_filterc_iter", "parent": 133, "children": [135, 136], "start_point": {"row": 54, "column": 36}, "end_point": {"row": 54, "column": 58}}, {"id": 135, "type": "struct", "text": "struct", "parent": 134, "children": [], "start_point": {"row": 54, "column": 36}, "end_point": {"row": 54, "column": 42}}, {"id": 136, "type": "type_identifier", "text": "m0_filterc_iter", "parent": 134, "children": [], "start_point": {"row": 54, "column": 43}, "end_point": {"row": 54, "column": 58}}, {"id": 137, "type": "pointer_declarator", "text": "*iter", "parent": 133, "children": [138, 139], "start_point": {"row": 54, "column": 59}, "end_point": {"row": 54, "column": 64}}, {"id": 138, "type": "*", "text": "*", "parent": 137, "children": [], "start_point": {"row": 54, "column": 59}, "end_point": {"row": 54, "column": 60}}, {"id": 139, "type": "identifier", "text": "iter", "parent": 137, "children": [], "start_point": {"row": 54, "column": 60}, "end_point": {"row": 54, "column": 64}}, {"id": 140, "type": "declaration", "text": "const struct m0_filterc_ops filterc_apply_flt_ops = {\n\t.fco_start = filterc_apply_flt_start,\n\t.fco_stop = filterc_apply_flt_stop,\n\t.fco_open = filterc_apply_flt_open,\n\t.fco_get_next = filterc_apply_flt_get_next,\n\t.fco_close = filterc_apply_flt_close\n};", "parent": null, "children": [141, 144], "start_point": {"row": 56, "column": 0}, "end_point": {"row": 62, "column": 2}}, {"id": 141, "type": "struct_specifier", "text": "struct m0_filterc_ops", "parent": 140, "children": [142, 143], "start_point": {"row": 56, "column": 6}, "end_point": {"row": 56, "column": 27}}, {"id": 142, "type": "struct", "text": "struct", "parent": 141, "children": [], "start_point": {"row": 56, "column": 6}, "end_point": {"row": 56, "column": 12}}, {"id": 143, "type": "type_identifier", "text": "m0_filterc_ops", "parent": 141, "children": [], "start_point": {"row": 56, "column": 13}, "end_point": {"row": 56, "column": 27}}, {"id": 144, "type": "init_declarator", "text": "filterc_apply_flt_ops = {\n\t.fco_start = filterc_apply_flt_start,\n\t.fco_stop = filterc_apply_flt_stop,\n\t.fco_open = filterc_apply_flt_open,\n\t.fco_get_next = filterc_apply_flt_get_next,\n\t.fco_close = filterc_apply_flt_close\n}", "parent": 140, "children": [145, 146, 147], "start_point": {"row": 56, "column": 28}, "end_point": {"row": 62, "column": 1}}, {"id": 145, "type": "identifier", "text": "filterc_apply_flt_ops", "parent": 144, "children": [], "start_point": {"row": 56, "column": 28}, "end_point": {"row": 56, "column": 49}}, {"id": 146, "type": "=", "text": "=", "parent": 144, "children": [], "start_point": {"row": 56, "column": 50}, "end_point": {"row": 56, "column": 51}}, {"id": 147, "type": "initializer_list", "text": "{\n\t.fco_start = filterc_apply_flt_start,\n\t.fco_stop = filterc_apply_flt_stop,\n\t.fco_open = filterc_apply_flt_open,\n\t.fco_get_next = filterc_apply_flt_get_next,\n\t.fco_close = filterc_apply_flt_close\n}", "parent": 144, "children": [148, 153, 158, 163, 168], "start_point": {"row": 56, "column": 52}, "end_point": {"row": 62, "column": 1}}, {"id": 148, "type": "initializer_pair", "text": ".fco_start = filterc_apply_flt_start", "parent": 147, "children": [149, 151, 152], "start_point": {"row": 57, "column": 1}, "end_point": {"row": 57, "column": 41}}, {"id": 149, "type": "field_designator", "text": ".fco_start", "parent": 148, "children": [150], "start_point": {"row": 57, "column": 1}, "end_point": {"row": 57, "column": 11}}, {"id": 150, "type": "field_identifier", "text": "fco_start", "parent": 149, "children": [], "start_point": {"row": 57, "column": 2}, "end_point": {"row": 57, "column": 11}}, {"id": 151, "type": "=", "text": "=", "parent": 148, "children": [], "start_point": {"row": 57, "column": 16}, "end_point": {"row": 57, "column": 17}}, {"id": 152, "type": "identifier", "text": "filterc_apply_flt_start", "parent": 148, "children": [], "start_point": {"row": 57, "column": 18}, "end_point": {"row": 57, "column": 41}}, {"id": 153, "type": "initializer_pair", "text": ".fco_stop = filterc_apply_flt_stop", "parent": 147, "children": [154, 156, 157], "start_point": {"row": 58, "column": 1}, "end_point": {"row": 58, "column": 40}}, {"id": 154, "type": "field_designator", "text": ".fco_stop", "parent": 153, "children": [155], "start_point": {"row": 58, "column": 1}, "end_point": {"row": 58, "column": 10}}, {"id": 155, "type": "field_identifier", "text": "fco_stop", "parent": 154, "children": [], "start_point": {"row": 58, "column": 2}, "end_point": {"row": 58, "column": 10}}, {"id": 156, "type": "=", "text": "=", "parent": 153, "children": [], "start_point": {"row": 58, "column": 16}, "end_point": {"row": 58, "column": 17}}, {"id": 157, "type": "identifier", "text": "filterc_apply_flt_stop", "parent": 153, "children": [], "start_point": {"row": 58, "column": 18}, "end_point": {"row": 58, "column": 40}}, {"id": 158, "type": "initializer_pair", "text": ".fco_open = filterc_apply_flt_open", "parent": 147, "children": [159, 161, 162], "start_point": {"row": 59, "column": 1}, "end_point": {"row": 59, "column": 40}}, {"id": 159, "type": "field_designator", "text": ".fco_open", "parent": 158, "children": [160], "start_point": {"row": 59, "column": 1}, "end_point": {"row": 59, "column": 10}}, {"id": 160, "type": "field_identifier", "text": "fco_open", "parent": 159, "children": [], "start_point": {"row": 59, "column": 2}, "end_point": {"row": 59, "column": 10}}, {"id": 161, "type": "=", "text": "=", "parent": 158, "children": [], "start_point": {"row": 59, "column": 16}, "end_point": {"row": 59, "column": 17}}, {"id": 162, "type": "identifier", "text": "filterc_apply_flt_open", "parent": 158, "children": [], "start_point": {"row": 59, "column": 18}, "end_point": {"row": 59, "column": 40}}, {"id": 163, "type": "initializer_pair", "text": ".fco_get_next = filterc_apply_flt_get_next", "parent": 147, "children": [164, 166, 167], "start_point": {"row": 60, "column": 1}, "end_point": {"row": 60, "column": 44}}, {"id": 164, "type": "field_designator", "text": ".fco_get_next", "parent": 163, "children": [165], "start_point": {"row": 60, "column": 1}, "end_point": {"row": 60, "column": 14}}, {"id": 165, "type": "field_identifier", "text": "fco_get_next", "parent": 164, "children": [], "start_point": {"row": 60, "column": 2}, "end_point": {"row": 60, "column": 14}}, {"id": 166, "type": "=", "text": "=", "parent": 163, "children": [], "start_point": {"row": 60, "column": 16}, "end_point": {"row": 60, "column": 17}}, {"id": 167, "type": "identifier", "text": "filterc_apply_flt_get_next", "parent": 163, "children": [], "start_point": {"row": 60, "column": 18}, "end_point": {"row": 60, "column": 44}}, {"id": 168, "type": "initializer_pair", "text": ".fco_close = filterc_apply_flt_close", "parent": 147, "children": [169, 171, 172], "start_point": {"row": 61, "column": 1}, "end_point": {"row": 61, "column": 41}}, {"id": 169, "type": "field_designator", "text": ".fco_close", "parent": 168, "children": [170], "start_point": {"row": 61, "column": 1}, "end_point": {"row": 61, "column": 11}}, {"id": 170, "type": "field_identifier", "text": "fco_close", "parent": 169, "children": [], "start_point": {"row": 61, "column": 2}, "end_point": {"row": 61, "column": 11}}, {"id": 171, "type": "=", "text": "=", "parent": 168, "children": [], "start_point": {"row": 61, "column": 16}, "end_point": {"row": 61, "column": 17}}, {"id": 172, "type": "identifier", "text": "filterc_apply_flt_close", "parent": 168, "children": [], "start_point": {"row": 61, "column": 18}, "end_point": {"row": 61, "column": 41}}, {"id": 173, "type": "function_definition", "text": "static int filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n\t\t\t\t struct m0_reqh *reqh)\n{\n\treturn 0;\n}", "parent": null, "children": [174, 175], "start_point": {"row": 64, "column": 0}, "end_point": {"row": 68, "column": 1}}, {"id": 174, "type": "primitive_type", "text": "int", "parent": 173, "children": [], "start_point": {"row": 64, "column": 7}, "end_point": {"row": 64, "column": 10}}, {"id": 175, "type": "function_declarator", "text": "filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n\t\t\t\t struct m0_reqh *reqh)", "parent": 173, "children": [176, 177], "start_point": {"row": 64, "column": 11}, "end_point": {"row": 65, "column": 35}}, {"id": 176, "type": "identifier", "text": "filterc_apply_flt_start", "parent": 175, "children": [], "start_point": {"row": 64, "column": 11}, "end_point": {"row": 64, "column": 34}}, {"id": 177, "type": "parameter_list", "text": "(struct m0_filterc_ctx *ctx,\n\t\t\t\t struct m0_reqh *reqh)", "parent": 175, "children": [178, 185], "start_point": {"row": 64, "column": 34}, "end_point": {"row": 65, "column": 35}}, {"id": 178, "type": "parameter_declaration", "text": "struct m0_filterc_ctx *ctx", "parent": 177, "children": [179, 182], "start_point": {"row": 64, "column": 35}, "end_point": {"row": 64, "column": 61}}, {"id": 179, "type": "struct_specifier", "text": "struct m0_filterc_ctx", "parent": 178, "children": [180, 181], "start_point": {"row": 64, "column": 35}, "end_point": {"row": 64, "column": 56}}, {"id": 180, "type": "struct", "text": "struct", "parent": 179, "children": [], "start_point": {"row": 64, "column": 35}, "end_point": {"row": 64, "column": 41}}, {"id": 181, "type": "type_identifier", "text": "m0_filterc_ctx", "parent": 179, "children": [], "start_point": {"row": 64, "column": 42}, "end_point": {"row": 64, "column": 56}}, {"id": 182, "type": "pointer_declarator", "text": "*ctx", "parent": 178, "children": [183, 184], "start_point": {"row": 64, "column": 57}, "end_point": {"row": 64, "column": 61}}, {"id": 183, "type": "*", "text": "*", "parent": 182, "children": [], "start_point": {"row": 64, "column": 57}, "end_point": {"row": 64, "column": 58}}, {"id": 184, "type": "identifier", "text": "ctx", "parent": 182, "children": [], "start_point": {"row": 64, "column": 58}, "end_point": {"row": 64, "column": 61}}, {"id": 185, "type": "parameter_declaration", "text": "struct m0_reqh *reqh", "parent": 177, "children": [186, 189], "start_point": {"row": 65, "column": 7}, "end_point": {"row": 65, "column": 34}}, {"id": 186, "type": "struct_specifier", "text": "struct m0_reqh", "parent": 185, "children": [187, 188], "start_point": {"row": 65, "column": 7}, "end_point": {"row": 65, "column": 21}}, {"id": 187, "type": "struct", "text": "struct", "parent": 186, "children": [], "start_point": {"row": 65, "column": 7}, "end_point": {"row": 65, "column": 13}}, {"id": 188, "type": "type_identifier", "text": "m0_reqh", "parent": 186, "children": [], "start_point": {"row": 65, "column": 14}, "end_point": {"row": 65, "column": 21}}, {"id": 189, "type": "pointer_declarator", "text": "*reqh", "parent": 185, "children": [190, 191], "start_point": {"row": 65, "column": 29}, "end_point": {"row": 65, "column": 34}}, {"id": 190, "type": "*", "text": "*", "parent": 189, "children": [], "start_point": {"row": 65, "column": 29}, "end_point": {"row": 65, "column": 30}}, {"id": 191, "type": "identifier", "text": "reqh", "parent": 189, "children": [], "start_point": {"row": 65, "column": 30}, "end_point": {"row": 65, "column": 34}}, {"id": 192, "type": "return_statement", "text": "return 0;", "parent": 173, "children": [193], "start_point": {"row": 67, "column": 1}, "end_point": {"row": 67, "column": 10}}, {"id": 193, "type": "number_literal", "text": "0", "parent": 192, "children": [], "start_point": {"row": 67, "column": 8}, "end_point": {"row": 67, "column": 9}}, {"id": 194, "type": "function_definition", "text": "static void filterc_apply_flt_stop(struct m0_filterc_ctx *ctx)\n{\n}", "parent": null, "children": [195, 196], "start_point": {"row": 70, "column": 0}, "end_point": {"row": 72, "column": 1}}, {"id": 195, "type": "primitive_type", "text": "void", "parent": 194, "children": [], "start_point": {"row": 70, "column": 7}, "end_point": {"row": 70, "column": 11}}, {"id": 196, "type": "function_declarator", "text": "filterc_apply_flt_stop(struct m0_filterc_ctx *ctx)", "parent": 194, "children": [197, 198], "start_point": {"row": 70, "column": 12}, "end_point": {"row": 70, "column": 62}}, {"id": 197, "type": "identifier", "text": "filterc_apply_flt_stop", "parent": 196, "children": [], "start_point": {"row": 70, "column": 12}, "end_point": {"row": 70, "column": 34}}, {"id": 198, "type": "parameter_list", "text": "(struct m0_filterc_ctx *ctx)", "parent": 196, "children": [199], "start_point": {"row": 70, "column": 34}, "end_point": {"row": 70, "column": 62}}, {"id": 199, "type": "parameter_declaration", "text": "struct m0_filterc_ctx *ctx", "parent": 198, "children": [200, 203], "start_point": {"row": 70, "column": 35}, "end_point": {"row": 70, "column": 61}}, {"id": 200, "type": "struct_specifier", "text": "struct m0_filterc_ctx", "parent": 199, "children": [201, 202], "start_point": {"row": 70, "column": 35}, "end_point": {"row": 70, "column": 56}}, {"id": 201, "type": "struct", "text": "struct", "parent": 200, "children": [], "start_point": {"row": 70, "column": 35}, "end_point": {"row": 70, "column": 41}}, {"id": 202, "type": "type_identifier", "text": "m0_filterc_ctx", "parent": 200, "children": [], "start_point": {"row": 70, "column": 42}, "end_point": {"row": 70, "column": 56}}, {"id": 203, "type": "pointer_declarator", "text": "*ctx", "parent": 199, "children": [204, 205], "start_point": {"row": 70, "column": 57}, "end_point": {"row": 70, "column": 61}}, {"id": 204, "type": "*", "text": "*", "parent": 203, "children": [], "start_point": {"row": 70, "column": 57}, "end_point": {"row": 70, "column": 58}}, {"id": 205, "type": "identifier", "text": "ctx", "parent": 203, "children": [], "start_point": {"row": 70, "column": 58}, "end_point": {"row": 70, "column": 61}}, {"id": 206, "type": "function_definition", "text": "static int filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n\t\t\t\t enum m0_fdmi_rec_type_id rec_type_id,\n\t\t\t\t struct m0_filterc_iter *iter)\n{\n\treturn 0;\n}", "parent": null, "children": [207, 208], "start_point": {"row": 74, "column": 0}, "end_point": {"row": 79, "column": 1}}, {"id": 207, "type": "primitive_type", "text": "int", "parent": 206, "children": [], "start_point": {"row": 74, "column": 7}, "end_point": {"row": 74, "column": 10}}, {"id": 208, "type": "function_declarator", "text": "filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n\t\t\t\t enum m0_fdmi_rec_type_id rec_type_id,\n\t\t\t\t struct m0_filterc_iter *iter)", "parent": 206, "children": [209, 210], "start_point": {"row": 74, "column": 11}, "end_point": {"row": 76, "column": 36}}, {"id": 209, "type": "identifier", "text": "filterc_apply_flt_open", "parent": 208, "children": [], "start_point": {"row": 74, "column": 11}, "end_point": {"row": 74, "column": 33}}, {"id": 210, "type": "parameter_list", "text": "(struct m0_filterc_ctx *ctx,\n\t\t\t\t enum m0_fdmi_rec_type_id rec_type_id,\n\t\t\t\t struct m0_filterc_iter *iter)", "parent": 208, "children": [211, 218, 223], "start_point": {"row": 74, "column": 33}, "end_point": {"row": 76, "column": 36}}, {"id": 211, "type": "parameter_declaration", "text": "struct m0_filterc_ctx *ctx", "parent": 210, "children": [212, 215], "start_point": {"row": 74, "column": 34}, "end_point": {"row": 74, "column": 62}}, {"id": 212, "type": "struct_specifier", "text": "struct m0_filterc_ctx", "parent": 211, "children": [213, 214], "start_point": {"row": 74, "column": 34}, "end_point": {"row": 74, "column": 55}}, {"id": 213, "type": "struct", "text": "struct", "parent": 212, "children": [], "start_point": {"row": 74, "column": 34}, "end_point": {"row": 74, "column": 40}}, {"id": 214, "type": "type_identifier", "text": "m0_filterc_ctx", "parent": 212, "children": [], "start_point": {"row": 74, "column": 41}, "end_point": {"row": 74, "column": 55}}, {"id": 215, "type": "pointer_declarator", "text": "*ctx", "parent": 211, "children": [216, 217], "start_point": {"row": 74, "column": 58}, "end_point": {"row": 74, "column": 62}}, {"id": 216, "type": "*", "text": "*", "parent": 215, "children": [], "start_point": {"row": 74, "column": 58}, "end_point": {"row": 74, "column": 59}}, {"id": 217, "type": "identifier", "text": "ctx", "parent": 215, "children": [], "start_point": {"row": 74, "column": 59}, "end_point": {"row": 74, "column": 62}}, {"id": 218, "type": "parameter_declaration", "text": "enum m0_fdmi_rec_type_id rec_type_id", "parent": 210, "children": [219, 222], "start_point": {"row": 75, "column": 6}, "end_point": {"row": 75, "column": 42}}, {"id": 219, "type": "enum_specifier", "text": "enum m0_fdmi_rec_type_id", "parent": 218, "children": [220, 221], "start_point": {"row": 75, "column": 6}, "end_point": {"row": 75, "column": 30}}, {"id": 220, "type": "enum", "text": "enum", "parent": 219, "children": [], "start_point": {"row": 75, "column": 6}, "end_point": {"row": 75, "column": 10}}, {"id": 221, "type": "type_identifier", "text": "m0_fdmi_rec_type_id", "parent": 219, "children": [], "start_point": {"row": 75, "column": 11}, "end_point": {"row": 75, "column": 30}}, {"id": 222, "type": "identifier", "text": "rec_type_id", "parent": 218, "children": [], "start_point": {"row": 75, "column": 31}, "end_point": {"row": 75, "column": 42}}, {"id": 223, "type": "parameter_declaration", "text": "struct m0_filterc_iter *iter", "parent": 210, "children": [224, 227], "start_point": {"row": 76, "column": 6}, "end_point": {"row": 76, "column": 35}}, {"id": 224, "type": "struct_specifier", "text": "struct m0_filterc_iter", "parent": 223, "children": [225, 226], "start_point": {"row": 76, "column": 6}, "end_point": {"row": 76, "column": 28}}, {"id": 225, "type": "struct", "text": "struct", "parent": 224, "children": [], "start_point": {"row": 76, "column": 6}, "end_point": {"row": 76, "column": 12}}, {"id": 226, "type": "type_identifier", "text": "m0_filterc_iter", "parent": 224, "children": [], "start_point": {"row": 76, "column": 13}, "end_point": {"row": 76, "column": 28}}, {"id": 227, "type": "pointer_declarator", "text": "*iter", "parent": 223, "children": [228, 229], "start_point": {"row": 76, "column": 30}, "end_point": {"row": 76, "column": 35}}, {"id": 228, "type": "*", "text": "*", "parent": 227, "children": [], "start_point": {"row": 76, "column": 30}, "end_point": {"row": 76, "column": 31}}, {"id": 229, "type": "identifier", "text": "iter", "parent": 227, "children": [], "start_point": {"row": 76, "column": 31}, "end_point": {"row": 76, "column": 35}}, {"id": 230, "type": "return_statement", "text": "return 0;", "parent": 206, "children": [231], "start_point": {"row": 78, "column": 1}, "end_point": {"row": 78, "column": 10}}, {"id": 231, "type": "number_literal", "text": "0", "parent": 230, "children": [], "start_point": {"row": 78, "column": 8}, "end_point": {"row": 78, "column": 9}}, {"id": 232, "type": "function_definition", "text": "static int filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n\t\t\t\t struct m0_conf_fdmi_filter **out)\n{\n\tint rc;\n\tstatic bool first_filter = true;\n\tstruct m0_fdmi_filter *flt = &g_conf_filter.ff_filter;\n\tstruct m0_fdmi_flt_node *root;\n\tstruct m0_buf var = M0_BUF_INITS(g_var_str);\n\n\tif (first_filter) {\n\t\troot = m0_fdmi_flt_op_node_create(\n\t\t M0_FFO_OR,\n\t\t\t m0_fdmi_flt_bool_node_create(false),\n\t\t\t m0_fdmi_flt_var_node_create(&var));\n\n\t\tm0_fdmi_filter_init(flt);\n\n\t\tm0_fdmi_filter_root_set(flt, root);\n\n\t\t*out = &g_conf_filter;\n\t\trc = 1;\n\t\tfirst_filter = false;\n\t} else {\n\t\t*out = NULL;\n\t\trc = 0;\n\t}\n\treturn rc;\n}", "parent": null, "children": [233, 234], "start_point": {"row": 81, "column": 0}, "end_point": {"row": 108, "column": 1}}, {"id": 233, "type": "primitive_type", "text": "int", "parent": 232, "children": [], "start_point": {"row": 81, "column": 7}, "end_point": {"row": 81, "column": 10}}, {"id": 234, "type": "function_declarator", "text": "filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n\t\t\t\t struct m0_conf_fdmi_filter **out)", "parent": 232, "children": [235, 236], "start_point": {"row": 81, "column": 11}, "end_point": {"row": 82, "column": 43}}, {"id": 235, "type": "identifier", "text": "filterc_apply_flt_get_next", "parent": 234, "children": [], "start_point": {"row": 81, "column": 11}, "end_point": {"row": 81, "column": 37}}, {"id": 236, "type": "parameter_list", "text": "(struct m0_filterc_iter *iter,\n\t\t\t\t struct m0_conf_fdmi_filter **out)", "parent": 234, "children": [237, 244], "start_point": {"row": 81, "column": 37}, "end_point": {"row": 82, "column": 43}}, {"id": 237, "type": "parameter_declaration", "text": "struct m0_filterc_iter *iter", "parent": 236, "children": [238, 241], "start_point": {"row": 81, "column": 38}, "end_point": {"row": 81, "column": 70}}, {"id": 238, "type": "struct_specifier", "text": "struct m0_filterc_iter", "parent": 237, "children": [239, 240], "start_point": {"row": 81, "column": 38}, "end_point": {"row": 81, "column": 60}}, {"id": 239, "type": "struct", "text": "struct", "parent": 238, "children": [], "start_point": {"row": 81, "column": 38}, "end_point": {"row": 81, "column": 44}}, {"id": 240, "type": "type_identifier", "text": "m0_filterc_iter", "parent": 238, "children": [], "start_point": {"row": 81, "column": 45}, "end_point": {"row": 81, "column": 60}}, {"id": 241, "type": "pointer_declarator", "text": "*iter", "parent": 237, "children": [242, 243], "start_point": {"row": 81, "column": 65}, "end_point": {"row": 81, "column": 70}}, {"id": 242, "type": "*", "text": "*", "parent": 241, "children": [], "start_point": {"row": 81, "column": 65}, "end_point": {"row": 81, "column": 66}}, {"id": 243, "type": "identifier", "text": "iter", "parent": 241, "children": [], "start_point": {"row": 81, "column": 66}, "end_point": {"row": 81, "column": 70}}, {"id": 244, "type": "parameter_declaration", "text": "struct m0_conf_fdmi_filter **out", "parent": 236, "children": [245, 248], "start_point": {"row": 82, "column": 10}, "end_point": {"row": 82, "column": 42}}, {"id": 245, "type": "struct_specifier", "text": "struct m0_conf_fdmi_filter", "parent": 244, "children": [246, 247], "start_point": {"row": 82, "column": 10}, "end_point": {"row": 82, "column": 36}}, {"id": 246, "type": "struct", "text": "struct", "parent": 245, "children": [], "start_point": {"row": 82, "column": 10}, "end_point": {"row": 82, "column": 16}}, {"id": 247, "type": "type_identifier", "text": "m0_conf_fdmi_filter", "parent": 245, "children": [], "start_point": {"row": 82, "column": 17}, "end_point": {"row": 82, "column": 36}}, {"id": 248, "type": "pointer_declarator", "text": "**out", "parent": 244, "children": [249, 250], "start_point": {"row": 82, "column": 37}, "end_point": {"row": 82, "column": 42}}, {"id": 249, "type": "*", "text": "*", "parent": 248, "children": [], "start_point": {"row": 82, "column": 37}, "end_point": {"row": 82, "column": 38}}, {"id": 250, "type": "pointer_declarator", "text": "*out", "parent": 248, "children": [251, 252], "start_point": {"row": 82, "column": 38}, "end_point": {"row": 82, "column": 42}}, {"id": 251, "type": "*", "text": "*", "parent": 250, "children": [], "start_point": {"row": 82, "column": 38}, "end_point": {"row": 82, "column": 39}}, {"id": 252, "type": "identifier", "text": "out", "parent": 250, "children": [], "start_point": {"row": 82, "column": 39}, "end_point": {"row": 82, "column": 42}}, {"id": 253, "type": "declaration", "text": "int rc;", "parent": 232, "children": [254, 255], "start_point": {"row": 84, "column": 1}, "end_point": {"row": 84, "column": 28}}, {"id": 254, "type": "primitive_type", "text": "int", "parent": 253, "children": [], "start_point": {"row": 84, "column": 1}, "end_point": {"row": 84, "column": 4}}, {"id": 255, "type": "identifier", "text": "rc", "parent": 253, "children": [], "start_point": {"row": 84, "column": 25}, "end_point": {"row": 84, "column": 27}}, {"id": 256, "type": "declaration", "text": "static bool first_filter = true;", "parent": 232, "children": [257, 258], "start_point": {"row": 85, "column": 1}, "end_point": {"row": 85, "column": 45}}, {"id": 257, "type": "primitive_type", "text": "bool", "parent": 256, "children": [], "start_point": {"row": 85, "column": 8}, "end_point": {"row": 85, "column": 12}}, {"id": 258, "type": "init_declarator", "text": "first_filter = true", "parent": 256, "children": [259, 260, 261], "start_point": {"row": 85, "column": 25}, "end_point": {"row": 85, "column": 44}}, {"id": 259, "type": "identifier", "text": "first_filter", "parent": 258, "children": [], "start_point": {"row": 85, "column": 25}, "end_point": {"row": 85, "column": 37}}, {"id": 260, "type": "=", "text": "=", "parent": 258, "children": [], "start_point": {"row": 85, "column": 38}, "end_point": {"row": 85, "column": 39}}, {"id": 261, "type": "true", "text": "true", "parent": 258, "children": [], "start_point": {"row": 85, "column": 40}, "end_point": {"row": 85, "column": 44}}, {"id": 262, "type": "declaration", "text": "struct m0_fdmi_filter *flt = &g_conf_filter.ff_filter;", "parent": 232, "children": [263, 266], "start_point": {"row": 86, "column": 1}, "end_point": {"row": 86, "column": 57}}, {"id": 263, "type": "struct_specifier", "text": "struct m0_fdmi_filter", "parent": 262, "children": [264, 265], "start_point": {"row": 86, "column": 1}, "end_point": {"row": 86, "column": 22}}, {"id": 264, "type": "struct", "text": "struct", "parent": 263, "children": [], "start_point": {"row": 86, "column": 1}, "end_point": {"row": 86, "column": 7}}, {"id": 265, "type": "type_identifier", "text": "m0_fdmi_filter", "parent": 263, "children": [], "start_point": {"row": 86, "column": 8}, "end_point": {"row": 86, "column": 22}}, {"id": 266, "type": "init_declarator", "text": "*flt = &g_conf_filter.ff_filter", "parent": 262, "children": [267, 270, 271], "start_point": {"row": 86, "column": 25}, "end_point": {"row": 86, "column": 56}}, {"id": 267, "type": "pointer_declarator", "text": "*flt", "parent": 266, "children": [268, 269], "start_point": {"row": 86, "column": 25}, "end_point": {"row": 86, "column": 29}}, {"id": 268, "type": "*", "text": "*", "parent": 267, "children": [], "start_point": {"row": 86, "column": 25}, "end_point": {"row": 86, "column": 26}}, {"id": 269, "type": "identifier", "text": "flt", "parent": 267, "children": [], "start_point": {"row": 86, "column": 26}, "end_point": {"row": 86, "column": 29}}, {"id": 270, "type": "=", "text": "=", "parent": 266, "children": [], "start_point": {"row": 86, "column": 30}, "end_point": {"row": 86, "column": 31}}, {"id": 271, "type": "pointer_expression", "text": "&g_conf_filter.ff_filter", "parent": 266, "children": [272], "start_point": {"row": 86, "column": 32}, "end_point": {"row": 86, "column": 56}}, {"id": 272, "type": "field_expression", "text": "g_conf_filter.ff_filter", "parent": 271, "children": [273, 274], "start_point": {"row": 86, "column": 33}, "end_point": {"row": 86, "column": 56}}, {"id": 273, "type": "identifier", "text": "g_conf_filter", "parent": 272, "children": [], "start_point": {"row": 86, "column": 33}, "end_point": {"row": 86, "column": 46}}, {"id": 274, "type": "field_identifier", "text": "ff_filter", "parent": 272, "children": [], "start_point": {"row": 86, "column": 47}, "end_point": {"row": 86, "column": 56}}, {"id": 275, "type": "declaration", "text": "struct m0_fdmi_flt_node *root;", "parent": 232, "children": [276, 279], "start_point": {"row": 87, "column": 1}, "end_point": {"row": 87, "column": 31}}, {"id": 276, "type": "struct_specifier", "text": "struct m0_fdmi_flt_node", "parent": 275, "children": [277, 278], "start_point": {"row": 87, "column": 1}, "end_point": {"row": 87, "column": 24}}, {"id": 277, "type": "struct", "text": "struct", "parent": 276, "children": [], "start_point": {"row": 87, "column": 1}, "end_point": {"row": 87, "column": 7}}, {"id": 278, "type": "type_identifier", "text": "m0_fdmi_flt_node", "parent": 276, "children": [], "start_point": {"row": 87, "column": 8}, "end_point": {"row": 87, "column": 24}}, {"id": 279, "type": "pointer_declarator", "text": "*root", "parent": 275, "children": [280, 281], "start_point": {"row": 87, "column": 25}, "end_point": {"row": 87, "column": 30}}, {"id": 280, "type": "*", "text": "*", "parent": 279, "children": [], "start_point": {"row": 87, "column": 25}, "end_point": {"row": 87, "column": 26}}, {"id": 281, "type": "identifier", "text": "root", "parent": 279, "children": [], "start_point": {"row": 87, "column": 26}, "end_point": {"row": 87, "column": 30}}, {"id": 282, "type": "declaration", "text": "struct m0_buf var = M0_BUF_INITS(g_var_str);", "parent": 232, "children": [283, 286], "start_point": {"row": 88, "column": 1}, "end_point": {"row": 88, "column": 55}}, {"id": 283, "type": "struct_specifier", "text": "struct m0_buf", "parent": 282, "children": [284, 285], "start_point": {"row": 88, "column": 1}, "end_point": {"row": 88, "column": 14}}, {"id": 284, "type": "struct", "text": "struct", "parent": 283, "children": [], "start_point": {"row": 88, "column": 1}, "end_point": {"row": 88, "column": 7}}, {"id": 285, "type": "type_identifier", "text": "m0_buf", "parent": 283, "children": [], "start_point": {"row": 88, "column": 8}, "end_point": {"row": 88, "column": 14}}, {"id": 286, "type": "init_declarator", "text": "var = M0_BUF_INITS(g_var_str)", "parent": 282, "children": [287, 288], "start_point": {"row": 88, "column": 25}, "end_point": {"row": 88, "column": 54}}, {"id": 287, "type": "=", "text": "=", "parent": 286, "children": [], "start_point": {"row": 88, "column": 29}, "end_point": {"row": 88, "column": 30}}, {"id": 288, "type": "call_expression", "text": "M0_BUF_INITS(g_var_str)", "parent": 286, "children": [289, 290], "start_point": {"row": 88, "column": 31}, "end_point": {"row": 88, "column": 54}}, {"id": 289, "type": "identifier", "text": "M0_BUF_INITS", "parent": 288, "children": [], "start_point": {"row": 88, "column": 31}, "end_point": {"row": 88, "column": 43}}, {"id": 290, "type": "argument_list", "text": "(g_var_str)", "parent": 288, "children": [291], "start_point": {"row": 88, "column": 43}, "end_point": {"row": 88, "column": 54}}, {"id": 291, "type": "identifier", "text": "g_var_str", "parent": 290, "children": [], "start_point": {"row": 88, "column": 44}, "end_point": {"row": 88, "column": 53}}, {"id": 292, "type": "if_statement", "text": "if (first_filter) {\n\t\troot = m0_fdmi_flt_op_node_create(\n\t\t M0_FFO_OR,\n\t\t\t m0_fdmi_flt_bool_node_create(false),\n\t\t\t m0_fdmi_flt_var_node_create(&var));\n\n\t\tm0_fdmi_filter_init(flt);\n\n\t\tm0_fdmi_filter_root_set(flt, root);\n\n\t\t*out = &g_conf_filter;\n\t\trc = 1;\n\t\tfirst_filter = false;\n\t} else {\n\t\t*out = NULL;\n\t\trc = 0;\n\t}", "parent": 232, "children": [293, 334], "start_point": {"row": 90, "column": 1}, "end_point": {"row": 106, "column": 2}}, {"id": 293, "type": "parenthesized_expression", "text": "(first_filter)", "parent": 292, "children": [294], "start_point": {"row": 90, "column": 4}, "end_point": {"row": 90, "column": 18}}, {"id": 294, "type": "identifier", "text": "first_filter", "parent": 293, "children": [], "start_point": {"row": 90, "column": 5}, "end_point": {"row": 90, "column": 17}}, {"id": 295, "type": "assignment_expression", "text": "root = m0_fdmi_flt_op_node_create(\n\t\t M0_FFO_OR,\n\t\t\t m0_fdmi_flt_bool_node_create(false),\n\t\t\t m0_fdmi_flt_var_node_create(&var))", "parent": 292, "children": [296, 297, 298], "start_point": {"row": 91, "column": 2}, "end_point": {"row": 94, "column": 38}}, {"id": 296, "type": "identifier", "text": "root", "parent": 295, "children": [], "start_point": {"row": 91, "column": 2}, "end_point": {"row": 91, "column": 6}}, {"id": 297, "type": "=", "text": "=", "parent": 295, "children": [], "start_point": {"row": 91, "column": 7}, "end_point": {"row": 91, "column": 8}}, {"id": 298, "type": "call_expression", "text": "m0_fdmi_flt_op_node_create(\n\t\t M0_FFO_OR,\n\t\t\t m0_fdmi_flt_bool_node_create(false),\n\t\t\t m0_fdmi_flt_var_node_create(&var))", "parent": 295, "children": [299, 300], "start_point": {"row": 91, "column": 9}, "end_point": {"row": 94, "column": 38}}, {"id": 299, "type": "identifier", "text": "m0_fdmi_flt_op_node_create", "parent": 298, "children": [], "start_point": {"row": 91, "column": 9}, "end_point": {"row": 91, "column": 35}}, {"id": 300, "type": "argument_list", "text": "(\n\t\t M0_FFO_OR,\n\t\t\t m0_fdmi_flt_bool_node_create(false),\n\t\t\t m0_fdmi_flt_var_node_create(&var))", "parent": 298, "children": [301, 302, 306], "start_point": {"row": 91, "column": 35}, "end_point": {"row": 94, "column": 38}}, {"id": 301, "type": "identifier", "text": "M0_FFO_OR", "parent": 300, "children": [], "start_point": {"row": 92, "column": 11}, "end_point": {"row": 92, "column": 20}}, {"id": 302, "type": "call_expression", "text": "m0_fdmi_flt_bool_node_create(false)", "parent": 300, "children": [303, 304], "start_point": {"row": 93, "column": 4}, "end_point": {"row": 93, "column": 39}}, {"id": 303, "type": "identifier", "text": "m0_fdmi_flt_bool_node_create", "parent": 302, "children": [], "start_point": {"row": 93, "column": 4}, "end_point": {"row": 93, "column": 32}}, {"id": 304, "type": "argument_list", "text": "(false)", "parent": 302, "children": [305], "start_point": {"row": 93, "column": 32}, "end_point": {"row": 93, "column": 39}}, {"id": 305, "type": "false", "text": "false", "parent": 304, "children": [], "start_point": {"row": 93, "column": 33}, "end_point": {"row": 93, "column": 38}}, {"id": 306, "type": "call_expression", "text": "m0_fdmi_flt_var_node_create(&var)", "parent": 300, "children": [307, 308], "start_point": {"row": 94, "column": 4}, "end_point": {"row": 94, "column": 37}}, {"id": 307, "type": "identifier", "text": "m0_fdmi_flt_var_node_create", "parent": 306, "children": [], "start_point": {"row": 94, "column": 4}, "end_point": {"row": 94, "column": 31}}, {"id": 308, "type": "argument_list", "text": "(&var)", "parent": 306, "children": [309], "start_point": {"row": 94, "column": 31}, "end_point": {"row": 94, "column": 37}}, {"id": 309, "type": "pointer_expression", "text": "&var", "parent": 308, "children": [], "start_point": {"row": 94, "column": 32}, "end_point": {"row": 94, "column": 36}}, {"id": 310, "type": "call_expression", "text": "m0_fdmi_filter_init(flt)", "parent": 292, "children": [311, 312], "start_point": {"row": 96, "column": 2}, "end_point": {"row": 96, "column": 26}}, {"id": 311, "type": "identifier", "text": "m0_fdmi_filter_init", "parent": 310, "children": [], "start_point": {"row": 96, "column": 2}, "end_point": {"row": 96, "column": 21}}, {"id": 312, "type": "argument_list", "text": "(flt)", "parent": 310, "children": [313], "start_point": {"row": 96, "column": 21}, "end_point": {"row": 96, "column": 26}}, {"id": 313, "type": "identifier", "text": "flt", "parent": 312, "children": [], "start_point": {"row": 96, "column": 22}, "end_point": {"row": 96, "column": 25}}, {"id": 314, "type": "call_expression", "text": "m0_fdmi_filter_root_set(flt, root)", "parent": 292, "children": [315, 316], "start_point": {"row": 98, "column": 2}, "end_point": {"row": 98, "column": 36}}, {"id": 315, "type": "identifier", "text": "m0_fdmi_filter_root_set", "parent": 314, "children": [], "start_point": {"row": 98, "column": 2}, "end_point": {"row": 98, "column": 25}}, {"id": 316, "type": "argument_list", "text": "(flt, root)", "parent": 314, "children": [317, 318], "start_point": {"row": 98, "column": 25}, "end_point": {"row": 98, "column": 36}}, {"id": 317, "type": "identifier", "text": "flt", "parent": 316, "children": [], "start_point": {"row": 98, "column": 26}, "end_point": {"row": 98, "column": 29}}, {"id": 318, "type": "identifier", "text": "root", "parent": 316, "children": [], "start_point": {"row": 98, "column": 31}, "end_point": {"row": 98, "column": 35}}, {"id": 319, "type": "assignment_expression", "text": "*out = &g_conf_filter", "parent": 292, "children": [320, 323, 324], "start_point": {"row": 100, "column": 2}, "end_point": {"row": 100, "column": 23}}, {"id": 320, "type": "pointer_expression", "text": "*out", "parent": 319, "children": [321, 322], "start_point": {"row": 100, "column": 2}, "end_point": {"row": 100, "column": 6}}, {"id": 321, "type": "*", "text": "*", "parent": 320, "children": [], "start_point": {"row": 100, "column": 2}, "end_point": {"row": 100, "column": 3}}, {"id": 322, "type": "identifier", "text": "out", "parent": 320, "children": [], "start_point": {"row": 100, "column": 3}, "end_point": {"row": 100, "column": 6}}, {"id": 323, "type": "=", "text": "=", "parent": 319, "children": [], "start_point": {"row": 100, "column": 7}, "end_point": {"row": 100, "column": 8}}, {"id": 324, "type": "pointer_expression", "text": "&g_conf_filter", "parent": 319, "children": [325], "start_point": {"row": 100, "column": 9}, "end_point": {"row": 100, "column": 23}}, {"id": 325, "type": "identifier", "text": "g_conf_filter", "parent": 324, "children": [], "start_point": {"row": 100, "column": 10}, "end_point": {"row": 100, "column": 23}}, {"id": 326, "type": "assignment_expression", "text": "rc = 1", "parent": 292, "children": [327, 328, 329], "start_point": {"row": 101, "column": 2}, "end_point": {"row": 101, "column": 8}}, {"id": 327, "type": "identifier", "text": "rc", "parent": 326, "children": [], "start_point": {"row": 101, "column": 2}, "end_point": {"row": 101, "column": 4}}, {"id": 328, "type": "=", "text": "=", "parent": 326, "children": [], "start_point": {"row": 101, "column": 5}, "end_point": {"row": 101, "column": 6}}, {"id": 329, "type": "number_literal", "text": "1", "parent": 326, "children": [], "start_point": {"row": 101, "column": 7}, "end_point": {"row": 101, "column": 8}}, {"id": 330, "type": "assignment_expression", "text": "first_filter = false", "parent": 292, "children": [331, 332, 333], "start_point": {"row": 102, "column": 2}, "end_point": {"row": 102, "column": 22}}, {"id": 331, "type": "identifier", "text": "first_filter", "parent": 330, "children": [], "start_point": {"row": 102, "column": 2}, "end_point": {"row": 102, "column": 14}}, {"id": 332, "type": "=", "text": "=", "parent": 330, "children": [], "start_point": {"row": 102, "column": 15}, "end_point": {"row": 102, "column": 16}}, {"id": 333, "type": "false", "text": "false", "parent": 330, "children": [], "start_point": {"row": 102, "column": 17}, "end_point": {"row": 102, "column": 22}}, {"id": 334, "type": "else_clause", "text": "else {\n\t\t*out = NULL;\n\t\trc = 0;\n\t}", "parent": 292, "children": [], "start_point": {"row": 103, "column": 3}, "end_point": {"row": 106, "column": 2}}, {"id": 335, "type": "assignment_expression", "text": "*out = NULL", "parent": 334, "children": [336, 339, 340], "start_point": {"row": 104, "column": 2}, "end_point": {"row": 104, "column": 13}}, {"id": 336, "type": "pointer_expression", "text": "*out", "parent": 335, "children": [337, 338], "start_point": {"row": 104, "column": 2}, "end_point": {"row": 104, "column": 6}}, {"id": 337, "type": "*", "text": "*", "parent": 336, "children": [], "start_point": {"row": 104, "column": 2}, "end_point": {"row": 104, "column": 3}}, {"id": 338, "type": "identifier", "text": "out", "parent": 336, "children": [], "start_point": {"row": 104, "column": 3}, "end_point": {"row": 104, "column": 6}}, {"id": 339, "type": "=", "text": "=", "parent": 335, "children": [], "start_point": {"row": 104, "column": 7}, "end_point": {"row": 104, "column": 8}}, {"id": 340, "type": "null", "text": "NULL", "parent": 335, "children": [341], "start_point": {"row": 104, "column": 9}, "end_point": {"row": 104, "column": 13}}, {"id": 341, "type": "NULL", "text": "NULL", "parent": 340, "children": [], "start_point": {"row": 104, "column": 9}, "end_point": {"row": 104, "column": 13}}, {"id": 342, "type": "assignment_expression", "text": "rc = 0", "parent": 334, "children": [343, 344, 345], "start_point": {"row": 105, "column": 2}, "end_point": {"row": 105, "column": 8}}, {"id": 343, "type": "identifier", "text": "rc", "parent": 342, "children": [], "start_point": {"row": 105, "column": 2}, "end_point": {"row": 105, "column": 4}}, {"id": 344, "type": "=", "text": "=", "parent": 342, "children": [], "start_point": {"row": 105, "column": 5}, "end_point": {"row": 105, "column": 6}}, {"id": 345, "type": "number_literal", "text": "0", "parent": 342, "children": [], "start_point": {"row": 105, "column": 7}, "end_point": {"row": 105, "column": 8}}, {"id": 346, "type": "return_statement", "text": "return rc;", "parent": 232, "children": [347], "start_point": {"row": 107, "column": 1}, "end_point": {"row": 107, "column": 11}}, {"id": 347, "type": "identifier", "text": "rc", "parent": 346, "children": [], "start_point": {"row": 107, "column": 8}, "end_point": {"row": 107, "column": 10}}, {"id": 348, "type": "function_definition", "text": "static void filterc_apply_flt_close(struct m0_filterc_iter *iter)\n{\n\tm0_fdmi_filter_fini(&g_conf_filter.ff_filter);\n}", "parent": null, "children": [349, 350], "start_point": {"row": 110, "column": 0}, "end_point": {"row": 113, "column": 1}}, {"id": 349, "type": "primitive_type", "text": "void", "parent": 348, "children": [], "start_point": {"row": 110, "column": 7}, "end_point": {"row": 110, "column": 11}}, {"id": 350, "type": "function_declarator", "text": "filterc_apply_flt_close(struct m0_filterc_iter *iter)", "parent": 348, "children": [351, 352], "start_point": {"row": 110, "column": 12}, "end_point": {"row": 110, "column": 65}}, {"id": 351, "type": "identifier", "text": "filterc_apply_flt_close", "parent": 350, "children": [], "start_point": {"row": 110, "column": 12}, "end_point": {"row": 110, "column": 35}}, {"id": 352, "type": "parameter_list", "text": "(struct m0_filterc_iter *iter)", "parent": 350, "children": [353], "start_point": {"row": 110, "column": 35}, "end_point": {"row": 110, "column": 65}}, {"id": 353, "type": "parameter_declaration", "text": "struct m0_filterc_iter *iter", "parent": 352, "children": [354, 357], "start_point": {"row": 110, "column": 36}, "end_point": {"row": 110, "column": 64}}, {"id": 354, "type": "struct_specifier", "text": "struct m0_filterc_iter", "parent": 353, "children": [355, 356], "start_point": {"row": 110, "column": 36}, "end_point": {"row": 110, "column": 58}}, {"id": 355, "type": "struct", "text": "struct", "parent": 354, "children": [], "start_point": {"row": 110, "column": 36}, "end_point": {"row": 110, "column": 42}}, {"id": 356, "type": "type_identifier", "text": "m0_filterc_iter", "parent": 354, "children": [], "start_point": {"row": 110, "column": 43}, "end_point": {"row": 110, "column": 58}}, {"id": 357, "type": "pointer_declarator", "text": "*iter", "parent": 353, "children": [358, 359], "start_point": {"row": 110, "column": 59}, "end_point": {"row": 110, "column": 64}}, {"id": 358, "type": "*", "text": "*", "parent": 357, "children": [], "start_point": {"row": 110, "column": 59}, "end_point": {"row": 110, "column": 60}}, {"id": 359, "type": "identifier", "text": "iter", "parent": 357, "children": [], "start_point": {"row": 110, "column": 60}, "end_point": {"row": 110, "column": 64}}, {"id": 360, "type": "call_expression", "text": "m0_fdmi_filter_fini(&g_conf_filter.ff_filter)", "parent": 348, "children": [361, 362], "start_point": {"row": 112, "column": 1}, "end_point": {"row": 112, "column": 46}}, {"id": 361, "type": "identifier", "text": "m0_fdmi_filter_fini", "parent": 360, "children": [], "start_point": {"row": 112, "column": 1}, "end_point": {"row": 112, "column": 20}}, {"id": 362, "type": "argument_list", "text": "(&g_conf_filter.ff_filter)", "parent": 360, "children": [363], "start_point": {"row": 112, "column": 20}, "end_point": {"row": 112, "column": 46}}, {"id": 363, "type": "pointer_expression", "text": "&g_conf_filter.ff_filter", "parent": 362, "children": [364], "start_point": {"row": 112, "column": 21}, "end_point": {"row": 112, "column": 45}}, {"id": 364, "type": "field_expression", "text": "g_conf_filter.ff_filter", "parent": 363, "children": [365, 366], "start_point": {"row": 112, "column": 22}, "end_point": {"row": 112, "column": 45}}, {"id": 365, "type": "identifier", "text": "g_conf_filter", "parent": 364, "children": [], "start_point": {"row": 112, "column": 22}, "end_point": {"row": 112, "column": 35}}, {"id": 366, "type": "field_identifier", "text": "ff_filter", "parent": 364, "children": [], "start_point": {"row": 112, "column": 36}, "end_point": {"row": 112, "column": 45}}, {"id": 367, "type": "function_definition", "text": "static int test_fs_node_eval(\n\t\tstruct m0_fdmi_src_rec *src_rec,\n\t\tstruct m0_fdmi_flt_var_node *value_desc,\n\t\tstruct m0_fdmi_flt_operand *value)\n{\n\tM0_UT_ASSERT(src_rec == &g_src_rec);\n\tM0_UT_ASSERT(src_rec->fsr_data == &g_fdmi_data);\n\tM0_UT_ASSERT(value_desc->ffvn_data.b_nob == strlen(g_var_str));\n\tM0_UT_ASSERT(value_desc->ffvn_data.b_addr == g_var_str);\n\n\tm0_fdmi_flt_bool_opnd_fill(value, false);\n\treturn 0;\n}", "parent": null, "children": [368, 369], "start_point": {"row": 116, "column": 0}, "end_point": {"row": 128, "column": 1}}, {"id": 368, "type": "primitive_type", "text": "int", "parent": 367, "children": [], "start_point": {"row": 116, "column": 7}, "end_point": {"row": 116, "column": 10}}, {"id": 369, "type": "function_declarator", "text": "test_fs_node_eval(\n\t\tstruct m0_fdmi_src_rec *src_rec,\n\t\tstruct m0_fdmi_flt_var_node *value_desc,\n\t\tstruct m0_fdmi_flt_operand *value)", "parent": 367, "children": [370, 371], "start_point": {"row": 116, "column": 11}, "end_point": {"row": 119, "column": 36}}, {"id": 370, "type": "identifier", "text": "test_fs_node_eval", "parent": 369, "children": [], "start_point": {"row": 116, "column": 11}, "end_point": {"row": 116, "column": 28}}, {"id": 371, "type": "parameter_list", "text": "(\n\t\tstruct m0_fdmi_src_rec *src_rec,\n\t\tstruct m0_fdmi_flt_var_node *value_desc,\n\t\tstruct m0_fdmi_flt_operand *value)", "parent": 369, "children": [372, 379, 386], "start_point": {"row": 116, "column": 28}, "end_point": {"row": 119, "column": 36}}, {"id": 372, "type": "parameter_declaration", "text": "struct m0_fdmi_src_rec *src_rec", "parent": 371, "children": [373, 376], "start_point": {"row": 117, "column": 2}, "end_point": {"row": 117, "column": 33}}, {"id": 373, "type": "struct_specifier", "text": "struct m0_fdmi_src_rec", "parent": 372, "children": [374, 375], "start_point": {"row": 117, "column": 2}, "end_point": {"row": 117, "column": 24}}, {"id": 374, "type": "struct", "text": "struct", "parent": 373, "children": [], "start_point": {"row": 117, "column": 2}, "end_point": {"row": 117, "column": 8}}, {"id": 375, "type": "type_identifier", "text": "m0_fdmi_src_rec", "parent": 373, "children": [], "start_point": {"row": 117, "column": 9}, "end_point": {"row": 117, "column": 24}}, {"id": 376, "type": "pointer_declarator", "text": "*src_rec", "parent": 372, "children": [377, 378], "start_point": {"row": 117, "column": 25}, "end_point": {"row": 117, "column": 33}}, {"id": 377, "type": "*", "text": "*", "parent": 376, "children": [], "start_point": {"row": 117, "column": 25}, "end_point": {"row": 117, "column": 26}}, {"id": 378, "type": "identifier", "text": "src_rec", "parent": 376, "children": [], "start_point": {"row": 117, "column": 26}, "end_point": {"row": 117, "column": 33}}, {"id": 379, "type": "parameter_declaration", "text": "struct m0_fdmi_flt_var_node *value_desc", "parent": 371, "children": [380, 383], "start_point": {"row": 118, "column": 2}, "end_point": {"row": 118, "column": 41}}, {"id": 380, "type": "struct_specifier", "text": "struct m0_fdmi_flt_var_node", "parent": 379, "children": [381, 382], "start_point": {"row": 118, "column": 2}, "end_point": {"row": 118, "column": 29}}, {"id": 381, "type": "struct", "text": "struct", "parent": 380, "children": [], "start_point": {"row": 118, "column": 2}, "end_point": {"row": 118, "column": 8}}, {"id": 382, "type": "type_identifier", "text": "m0_fdmi_flt_var_node", "parent": 380, "children": [], "start_point": {"row": 118, "column": 9}, "end_point": {"row": 118, "column": 29}}, {"id": 383, "type": "pointer_declarator", "text": "*value_desc", "parent": 379, "children": [384, 385], "start_point": {"row": 118, "column": 30}, "end_point": {"row": 118, "column": 41}}, {"id": 384, "type": "*", "text": "*", "parent": 383, "children": [], "start_point": {"row": 118, "column": 30}, "end_point": {"row": 118, "column": 31}}, {"id": 385, "type": "identifier", "text": "value_desc", "parent": 383, "children": [], "start_point": {"row": 118, "column": 31}, "end_point": {"row": 118, "column": 41}}, {"id": 386, "type": "parameter_declaration", "text": "struct m0_fdmi_flt_operand *value", "parent": 371, "children": [387, 390], "start_point": {"row": 119, "column": 2}, "end_point": {"row": 119, "column": 35}}, {"id": 387, "type": "struct_specifier", "text": "struct m0_fdmi_flt_operand", "parent": 386, "children": [388, 389], "start_point": {"row": 119, "column": 2}, "end_point": {"row": 119, "column": 28}}, {"id": 388, "type": "struct", "text": "struct", "parent": 387, "children": [], "start_point": {"row": 119, "column": 2}, "end_point": {"row": 119, "column": 8}}, {"id": 389, "type": "type_identifier", "text": "m0_fdmi_flt_operand", "parent": 387, "children": [], "start_point": {"row": 119, "column": 9}, "end_point": {"row": 119, "column": 28}}, {"id": 390, "type": "pointer_declarator", "text": "*value", "parent": 386, "children": [391, 392], "start_point": {"row": 119, "column": 29}, "end_point": {"row": 119, "column": 35}}, {"id": 391, "type": "*", "text": "*", "parent": 390, "children": [], "start_point": {"row": 119, "column": 29}, "end_point": {"row": 119, "column": 30}}, {"id": 392, "type": "identifier", "text": "value", "parent": 390, "children": [], "start_point": {"row": 119, "column": 30}, "end_point": {"row": 119, "column": 35}}, {"id": 393, "type": "call_expression", "text": "M0_UT_ASSERT(src_rec == &g_src_rec)", "parent": 367, "children": [394, 395], "start_point": {"row": 121, "column": 1}, "end_point": {"row": 121, "column": 36}}, {"id": 394, "type": "identifier", "text": "M0_UT_ASSERT", "parent": 393, "children": [], "start_point": {"row": 121, "column": 1}, "end_point": {"row": 121, "column": 13}}, {"id": 395, "type": "argument_list", "text": "(src_rec == &g_src_rec)", "parent": 393, "children": [396], "start_point": {"row": 121, "column": 13}, "end_point": {"row": 121, "column": 36}}, {"id": 396, "type": "binary_expression", "text": "src_rec == &g_src_rec", "parent": 395, "children": [397, 398, 399], "start_point": {"row": 121, "column": 14}, "end_point": {"row": 121, "column": 35}}, {"id": 397, "type": "identifier", "text": "src_rec", "parent": 396, "children": [], "start_point": {"row": 121, "column": 14}, "end_point": {"row": 121, "column": 21}}, {"id": 398, "type": "==", "text": "==", "parent": 396, "children": [], "start_point": {"row": 121, "column": 22}, "end_point": {"row": 121, "column": 24}}, {"id": 399, "type": "pointer_expression", "text": "&g_src_rec", "parent": 396, "children": [400], "start_point": {"row": 121, "column": 25}, "end_point": {"row": 121, "column": 35}}, {"id": 400, "type": "identifier", "text": "g_src_rec", "parent": 399, "children": [], "start_point": {"row": 121, "column": 26}, "end_point": {"row": 121, "column": 35}}, {"id": 401, "type": "call_expression", "text": "M0_UT_ASSERT(src_rec->fsr_data == &g_fdmi_data)", "parent": 367, "children": [402, 403], "start_point": {"row": 122, "column": 1}, "end_point": {"row": 122, "column": 48}}, {"id": 402, "type": "identifier", "text": "M0_UT_ASSERT", "parent": 401, "children": [], "start_point": {"row": 122, "column": 1}, "end_point": {"row": 122, "column": 13}}, {"id": 403, "type": "argument_list", "text": "(src_rec->fsr_data == &g_fdmi_data)", "parent": 401, "children": [404], "start_point": {"row": 122, "column": 13}, "end_point": {"row": 122, "column": 48}}, {"id": 404, "type": "binary_expression", "text": "src_rec->fsr_data == &g_fdmi_data", "parent": 403, "children": [405, 408, 409], "start_point": {"row": 122, "column": 14}, "end_point": {"row": 122, "column": 47}}, {"id": 405, "type": "field_expression", "text": "src_rec->fsr_data", "parent": 404, "children": [406, 407], "start_point": {"row": 122, "column": 14}, "end_point": {"row": 122, "column": 31}}, {"id": 406, "type": "identifier", "text": "src_rec", "parent": 405, "children": [], "start_point": {"row": 122, "column": 14}, "end_point": {"row": 122, "column": 21}}, {"id": 407, "type": "field_identifier", "text": "fsr_data", "parent": 405, "children": [], "start_point": {"row": 122, "column": 23}, "end_point": {"row": 122, "column": 31}}, {"id": 408, "type": "==", "text": "==", "parent": 404, "children": [], "start_point": {"row": 122, "column": 32}, "end_point": {"row": 122, "column": 34}}, {"id": 409, "type": "pointer_expression", "text": "&g_fdmi_data", "parent": 404, "children": [410], "start_point": {"row": 122, "column": 35}, "end_point": {"row": 122, "column": 47}}, {"id": 410, "type": "identifier", "text": "g_fdmi_data", "parent": 409, "children": [], "start_point": {"row": 122, "column": 36}, "end_point": {"row": 122, "column": 47}}, {"id": 411, "type": "call_expression", "text": "M0_UT_ASSERT(value_desc->ffvn_data.b_nob == strlen(g_var_str))", "parent": 367, "children": [412, 413], "start_point": {"row": 123, "column": 1}, "end_point": {"row": 123, "column": 63}}, {"id": 412, "type": "identifier", "text": "M0_UT_ASSERT", "parent": 411, "children": [], "start_point": {"row": 123, "column": 1}, "end_point": {"row": 123, "column": 13}}, {"id": 413, "type": "argument_list", "text": "(value_desc->ffvn_data.b_nob == strlen(g_var_str))", "parent": 411, "children": [414], "start_point": {"row": 123, "column": 13}, "end_point": {"row": 123, "column": 63}}, {"id": 414, "type": "binary_expression", "text": "value_desc->ffvn_data.b_nob == strlen(g_var_str)", "parent": 413, "children": [415, 420, 421], "start_point": {"row": 123, "column": 14}, "end_point": {"row": 123, "column": 62}}, {"id": 415, "type": "field_expression", "text": "value_desc->ffvn_data.b_nob", "parent": 414, "children": [416, 419], "start_point": {"row": 123, "column": 14}, "end_point": {"row": 123, "column": 41}}, {"id": 416, "type": "field_expression", "text": "value_desc->ffvn_data", "parent": 415, "children": [417, 418], "start_point": {"row": 123, "column": 14}, "end_point": {"row": 123, "column": 35}}, {"id": 417, "type": "identifier", "text": "value_desc", "parent": 416, "children": [], "start_point": {"row": 123, "column": 14}, "end_point": {"row": 123, "column": 24}}, {"id": 418, "type": "field_identifier", "text": "ffvn_data", "parent": 416, "children": [], "start_point": {"row": 123, "column": 26}, "end_point": {"row": 123, "column": 35}}, {"id": 419, "type": "field_identifier", "text": "b_nob", "parent": 415, "children": [], "start_point": {"row": 123, "column": 36}, "end_point": {"row": 123, "column": 41}}, {"id": 420, "type": "==", "text": "==", "parent": 414, "children": [], "start_point": {"row": 123, "column": 42}, "end_point": {"row": 123, "column": 44}}, {"id": 421, "type": "call_expression", "text": "strlen(g_var_str)", "parent": 414, "children": [422, 423], "start_point": {"row": 123, "column": 45}, "end_point": {"row": 123, "column": 62}}, {"id": 422, "type": "identifier", "text": "strlen", "parent": 421, "children": [], "start_point": {"row": 123, "column": 45}, "end_point": {"row": 123, "column": 51}}, {"id": 423, "type": "argument_list", "text": "(g_var_str)", "parent": 421, "children": [424], "start_point": {"row": 123, "column": 51}, "end_point": {"row": 123, "column": 62}}, {"id": 424, "type": "identifier", "text": "g_var_str", "parent": 423, "children": [], "start_point": {"row": 123, "column": 52}, "end_point": {"row": 123, "column": 61}}, {"id": 425, "type": "call_expression", "text": "M0_UT_ASSERT(value_desc->ffvn_data.b_addr == g_var_str)", "parent": 367, "children": [426, 427], "start_point": {"row": 124, "column": 1}, "end_point": {"row": 124, "column": 56}}, {"id": 426, "type": "identifier", "text": "M0_UT_ASSERT", "parent": 425, "children": [], "start_point": {"row": 124, "column": 1}, "end_point": {"row": 124, "column": 13}}, {"id": 427, "type": "argument_list", "text": "(value_desc->ffvn_data.b_addr == g_var_str)", "parent": 425, "children": [428], "start_point": {"row": 124, "column": 13}, "end_point": {"row": 124, "column": 56}}, {"id": 428, "type": "binary_expression", "text": "value_desc->ffvn_data.b_addr == g_var_str", "parent": 427, "children": [429, 434, 435], "start_point": {"row": 124, "column": 14}, "end_point": {"row": 124, "column": 55}}, {"id": 429, "type": "field_expression", "text": "value_desc->ffvn_data.b_addr", "parent": 428, "children": [430, 433], "start_point": {"row": 124, "column": 14}, "end_point": {"row": 124, "column": 42}}, {"id": 430, "type": "field_expression", "text": "value_desc->ffvn_data", "parent": 429, "children": [431, 432], "start_point": {"row": 124, "column": 14}, "end_point": {"row": 124, "column": 35}}, {"id": 431, "type": "identifier", "text": "value_desc", "parent": 430, "children": [], "start_point": {"row": 124, "column": 14}, "end_point": {"row": 124, "column": 24}}, {"id": 432, "type": "field_identifier", "text": "ffvn_data", "parent": 430, "children": [], "start_point": {"row": 124, "column": 26}, "end_point": {"row": 124, "column": 35}}, {"id": 433, "type": "field_identifier", "text": "b_addr", "parent": 429, "children": [], "start_point": {"row": 124, "column": 36}, "end_point": {"row": 124, "column": 42}}, {"id": 434, "type": "==", "text": "==", "parent": 428, "children": [], "start_point": {"row": 124, "column": 43}, "end_point": {"row": 124, "column": 45}}, {"id": 435, "type": "identifier", "text": "g_var_str", "parent": 428, "children": [], "start_point": {"row": 124, "column": 46}, "end_point": {"row": 124, "column": 55}}, {"id": 436, "type": "call_expression", "text": "m0_fdmi_flt_bool_opnd_fill(value, false)", "parent": 367, "children": [437, 438], "start_point": {"row": 126, "column": 1}, "end_point": {"row": 126, "column": 41}}, {"id": 437, "type": "identifier", "text": "m0_fdmi_flt_bool_opnd_fill", "parent": 436, "children": [], "start_point": {"row": 126, "column": 1}, "end_point": {"row": 126, "column": 27}}, {"id": 438, "type": "argument_list", "text": "(value, false)", "parent": 436, "children": [439, 440], "start_point": {"row": 126, "column": 27}, "end_point": {"row": 126, "column": 41}}, {"id": 439, "type": "identifier", "text": "value", "parent": 438, "children": [], "start_point": {"row": 126, "column": 28}, "end_point": {"row": 126, "column": 33}}, {"id": 440, "type": "false", "text": "false", "parent": 438, "children": [], "start_point": {"row": 126, "column": 35}, "end_point": {"row": 126, "column": 40}}, {"id": 441, "type": "return_statement", "text": "return 0;", "parent": 367, "children": [442], "start_point": {"row": 127, "column": 1}, "end_point": {"row": 127, "column": 10}}, {"id": 442, "type": "number_literal", "text": "0", "parent": 441, "children": [], "start_point": {"row": 127, "column": 8}, "end_point": {"row": 127, "column": 9}}, {"id": 443, "type": "function_definition", "text": "static int test_fs_encode(struct m0_fdmi_src_rec *src_rec,\n\t\t\t struct m0_buf *buf)\n{\n\tM0_UT_ASSERT(false);\n\treturn 0;\n}", "parent": null, "children": [444, 445], "start_point": {"row": 130, "column": 0}, "end_point": {"row": 135, "column": 1}}, {"id": 444, "type": "primitive_type", "text": "int", "parent": 443, "children": [], "start_point": {"row": 130, "column": 7}, "end_point": {"row": 130, "column": 10}}, {"id": 445, "type": "function_declarator", "text": "test_fs_encode(struct m0_fdmi_src_rec *src_rec,\n\t\t\t struct m0_buf *buf)", "parent": 443, "children": [446, 447], "start_point": {"row": 130, "column": 11}, "end_point": {"row": 131, "column": 33}}, {"id": 446, "type": "identifier", "text": "test_fs_encode", "parent": 445, "children": [], "start_point": {"row": 130, "column": 11}, "end_point": {"row": 130, "column": 25}}, {"id": 447, "type": "parameter_list", "text": "(struct m0_fdmi_src_rec *src_rec,\n\t\t\t struct m0_buf *buf)", "parent": 445, "children": [448, 455], "start_point": {"row": 130, "column": 25}, "end_point": {"row": 131, "column": 33}}, {"id": 448, "type": "parameter_declaration", "text": "struct m0_fdmi_src_rec *src_rec", "parent": 447, "children": [449, 452], "start_point": {"row": 130, "column": 26}, "end_point": {"row": 130, "column": 57}}, {"id": 449, "type": "struct_specifier", "text": "struct m0_fdmi_src_rec", "parent": 448, "children": [450, 451], "start_point": {"row": 130, "column": 26}, "end_point": {"row": 130, "column": 48}}, {"id": 450, "type": "struct", "text": "struct", "parent": 449, "children": [], "start_point": {"row": 130, "column": 26}, "end_point": {"row": 130, "column": 32}}, {"id": 451, "type": "type_identifier", "text": "m0_fdmi_src_rec", "parent": 449, "children": [], "start_point": {"row": 130, "column": 33}, "end_point": {"row": 130, "column": 48}}, {"id": 452, "type": "pointer_declarator", "text": "*src_rec", "parent": 448, "children": [453, 454], "start_point": {"row": 130, "column": 49}, "end_point": {"row": 130, "column": 57}}, {"id": 453, "type": "*", "text": "*", "parent": 452, "children": [], "start_point": {"row": 130, "column": 49}, "end_point": {"row": 130, "column": 50}}, {"id": 454, "type": "identifier", "text": "src_rec", "parent": 452, "children": [], "start_point": {"row": 130, "column": 50}, "end_point": {"row": 130, "column": 57}}, {"id": 455, "type": "parameter_declaration", "text": "struct m0_buf *buf", "parent": 447, "children": [456, 459], "start_point": {"row": 131, "column": 5}, "end_point": {"row": 131, "column": 32}}, {"id": 456, "type": "struct_specifier", "text": "struct m0_buf", "parent": 455, "children": [457, 458], "start_point": {"row": 131, "column": 5}, "end_point": {"row": 131, "column": 18}}, {"id": 457, "type": "struct", "text": "struct", "parent": 456, "children": [], "start_point": {"row": 131, "column": 5}, "end_point": {"row": 131, "column": 11}}, {"id": 458, "type": "type_identifier", "text": "m0_buf", "parent": 456, "children": [], "start_point": {"row": 131, "column": 12}, "end_point": {"row": 131, "column": 18}}, {"id": 459, "type": "pointer_declarator", "text": "*buf", "parent": 455, "children": [460, 461], "start_point": {"row": 131, "column": 28}, "end_point": {"row": 131, "column": 32}}, {"id": 460, "type": "*", "text": "*", "parent": 459, "children": [], "start_point": {"row": 131, "column": 28}, "end_point": {"row": 131, "column": 29}}, {"id": 461, "type": "identifier", "text": "buf", "parent": 459, "children": [], "start_point": {"row": 131, "column": 29}, "end_point": {"row": 131, "column": 32}}, {"id": 462, "type": "call_expression", "text": "M0_UT_ASSERT(false)", "parent": 443, "children": [463, 464], "start_point": {"row": 133, "column": 1}, "end_point": {"row": 133, "column": 20}}, {"id": 463, "type": "identifier", "text": "M0_UT_ASSERT", "parent": 462, "children": [], "start_point": {"row": 133, "column": 1}, "end_point": {"row": 133, "column": 13}}, {"id": 464, "type": "argument_list", "text": "(false)", "parent": 462, "children": [465], "start_point": {"row": 133, "column": 13}, "end_point": {"row": 133, "column": 20}}, {"id": 465, "type": "false", "text": "false", "parent": 464, "children": [], "start_point": {"row": 133, "column": 14}, "end_point": {"row": 133, "column": 19}}, {"id": 466, "type": "return_statement", "text": "return 0;", "parent": 443, "children": [467], "start_point": {"row": 134, "column": 1}, "end_point": {"row": 134, "column": 10}}, {"id": 467, "type": "number_literal", "text": "0", "parent": 466, "children": [], "start_point": {"row": 134, "column": 8}, "end_point": {"row": 134, "column": 9}}, {"id": 468, "type": "function_definition", "text": "static void test_fs_get(struct m0_fdmi_src_rec *src_rec)\n{\n\tM0_UT_ASSERT(false);\n}", "parent": null, "children": [469, 470], "start_point": {"row": 138, "column": 0}, "end_point": {"row": 141, "column": 1}}, {"id": 469, "type": "primitive_type", "text": "void", "parent": 468, "children": [], "start_point": {"row": 138, "column": 7}, "end_point": {"row": 138, "column": 11}}, {"id": 470, "type": "function_declarator", "text": "test_fs_get(struct m0_fdmi_src_rec *src_rec)", "parent": 468, "children": [471, 472], "start_point": {"row": 138, "column": 12}, "end_point": {"row": 138, "column": 56}}, {"id": 471, "type": "identifier", "text": "test_fs_get", "parent": 470, "children": [], "start_point": {"row": 138, "column": 12}, "end_point": {"row": 138, "column": 23}}, {"id": 472, "type": "parameter_list", "text": "(struct m0_fdmi_src_rec *src_rec)", "parent": 470, "children": [473], "start_point": {"row": 138, "column": 23}, "end_point": {"row": 138, "column": 56}}, {"id": 473, "type": "parameter_declaration", "text": "struct m0_fdmi_src_rec *src_rec", "parent": 472, "children": [474, 477], "start_point": {"row": 138, "column": 24}, "end_point": {"row": 138, "column": 55}}, {"id": 474, "type": "struct_specifier", "text": "struct m0_fdmi_src_rec", "parent": 473, "children": [475, 476], "start_point": {"row": 138, "column": 24}, "end_point": {"row": 138, "column": 46}}, {"id": 475, "type": "struct", "text": "struct", "parent": 474, "children": [], "start_point": {"row": 138, "column": 24}, "end_point": {"row": 138, "column": 30}}, {"id": 476, "type": "type_identifier", "text": "m0_fdmi_src_rec", "parent": 474, "children": [], "start_point": {"row": 138, "column": 31}, "end_point": {"row": 138, "column": 46}}, {"id": 477, "type": "pointer_declarator", "text": "*src_rec", "parent": 473, "children": [478, 479], "start_point": {"row": 138, "column": 47}, "end_point": {"row": 138, "column": 55}}, {"id": 478, "type": "*", "text": "*", "parent": 477, "children": [], "start_point": {"row": 138, "column": 47}, "end_point": {"row": 138, "column": 48}}, {"id": 479, "type": "identifier", "text": "src_rec", "parent": 477, "children": [], "start_point": {"row": 138, "column": 48}, "end_point": {"row": 138, "column": 55}}, {"id": 480, "type": "call_expression", "text": "M0_UT_ASSERT(false)", "parent": 468, "children": [481, 482], "start_point": {"row": 140, "column": 1}, "end_point": {"row": 140, "column": 20}}, {"id": 481, "type": "identifier", "text": "M0_UT_ASSERT", "parent": 480, "children": [], "start_point": {"row": 140, "column": 1}, "end_point": {"row": 140, "column": 13}}, {"id": 482, "type": "argument_list", "text": "(false)", "parent": 480, "children": [483], "start_point": {"row": 140, "column": 13}, "end_point": {"row": 140, "column": 20}}, {"id": 483, "type": "false", "text": "false", "parent": 482, "children": [], "start_point": {"row": 140, "column": 14}, "end_point": {"row": 140, "column": 19}}, {"id": 484, "type": "function_definition", "text": "static void test_fs_put(struct m0_fdmi_src_rec *src_rec)\n{\n\tM0_UT_ASSERT(src_rec != NULL);\n\tM0_UT_ASSERT(src_rec == &g_src_rec);\n}", "parent": null, "children": [485, 486], "start_point": {"row": 143, "column": 0}, "end_point": {"row": 147, "column": 1}}, {"id": 485, "type": "primitive_type", "text": "void", "parent": 484, "children": [], "start_point": {"row": 143, "column": 7}, "end_point": {"row": 143, "column": 11}}, {"id": 486, "type": "function_declarator", "text": "test_fs_put(struct m0_fdmi_src_rec *src_rec)", "parent": 484, "children": [487, 488], "start_point": {"row": 143, "column": 12}, "end_point": {"row": 143, "column": 56}}, {"id": 487, "type": "identifier", "text": "test_fs_put", "parent": 486, "children": [], "start_point": {"row": 143, "column": 12}, "end_point": {"row": 143, "column": 23}}, {"id": 488, "type": "parameter_list", "text": "(struct m0_fdmi_src_rec *src_rec)", "parent": 486, "children": [489], "start_point": {"row": 143, "column": 23}, "end_point": {"row": 143, "column": 56}}, {"id": 489, "type": "parameter_declaration", "text": "struct m0_fdmi_src_rec *src_rec", "parent": 488, "children": [490, 493], "start_point": {"row": 143, "column": 24}, "end_point": {"row": 143, "column": 55}}, {"id": 490, "type": "struct_specifier", "text": "struct m0_fdmi_src_rec", "parent": 489, "children": [491, 492], "start_point": {"row": 143, "column": 24}, "end_point": {"row": 143, "column": 46}}, {"id": 491, "type": "struct", "text": "struct", "parent": 490, "children": [], "start_point": {"row": 143, "column": 24}, "end_point": {"row": 143, "column": 30}}, {"id": 492, "type": "type_identifier", "text": "m0_fdmi_src_rec", "parent": 490, "children": [], "start_point": {"row": 143, "column": 31}, "end_point": {"row": 143, "column": 46}}, {"id": 493, "type": "pointer_declarator", "text": "*src_rec", "parent": 489, "children": [494, 495], "start_point": {"row": 143, "column": 47}, "end_point": {"row": 143, "column": 55}}, {"id": 494, "type": "*", "text": "*", "parent": 493, "children": [], "start_point": {"row": 143, "column": 47}, "end_point": {"row": 143, "column": 48}}, {"id": 495, "type": "identifier", "text": "src_rec", "parent": 493, "children": [], "start_point": {"row": 143, "column": 48}, "end_point": {"row": 143, "column": 55}}, {"id": 496, "type": "call_expression", "text": "M0_UT_ASSERT(src_rec != NULL)", "parent": 484, "children": [497, 498], "start_point": {"row": 145, "column": 1}, "end_point": {"row": 145, "column": 30}}, {"id": 497, "type": "identifier", "text": "M0_UT_ASSERT", "parent": 496, "children": [], "start_point": {"row": 145, "column": 1}, "end_point": {"row": 145, "column": 13}}, {"id": 498, "type": "argument_list", "text": "(src_rec != NULL)", "parent": 496, "children": [499], "start_point": {"row": 145, "column": 13}, "end_point": {"row": 145, "column": 30}}, {"id": 499, "type": "binary_expression", "text": "src_rec != NULL", "parent": 498, "children": [500, 501, 502], "start_point": {"row": 145, "column": 14}, "end_point": {"row": 145, "column": 29}}, {"id": 500, "type": "identifier", "text": "src_rec", "parent": 499, "children": [], "start_point": {"row": 145, "column": 14}, "end_point": {"row": 145, "column": 21}}, {"id": 501, "type": "!=", "text": "!=", "parent": 499, "children": [], "start_point": {"row": 145, "column": 22}, "end_point": {"row": 145, "column": 24}}, {"id": 502, "type": "null", "text": "NULL", "parent": 499, "children": [503], "start_point": {"row": 145, "column": 25}, "end_point": {"row": 145, "column": 29}}, {"id": 503, "type": "NULL", "text": "NULL", "parent": 502, "children": [], "start_point": {"row": 145, "column": 25}, "end_point": {"row": 145, "column": 29}}, {"id": 504, "type": "call_expression", "text": "M0_UT_ASSERT(src_rec == &g_src_rec)", "parent": 484, "children": [505, 506], "start_point": {"row": 146, "column": 1}, "end_point": {"row": 146, "column": 36}}, {"id": 505, "type": "identifier", "text": "M0_UT_ASSERT", "parent": 504, "children": [], "start_point": {"row": 146, "column": 1}, "end_point": {"row": 146, "column": 13}}, {"id": 506, "type": "argument_list", "text": "(src_rec == &g_src_rec)", "parent": 504, "children": [507], "start_point": {"row": 146, "column": 13}, "end_point": {"row": 146, "column": 36}}, {"id": 507, "type": "binary_expression", "text": "src_rec == &g_src_rec", "parent": 506, "children": [508, 509, 510], "start_point": {"row": 146, "column": 14}, "end_point": {"row": 146, "column": 35}}, {"id": 508, "type": "identifier", "text": "src_rec", "parent": 507, "children": [], "start_point": {"row": 146, "column": 14}, "end_point": {"row": 146, "column": 21}}, {"id": 509, "type": "==", "text": "==", "parent": 507, "children": [], "start_point": {"row": 146, "column": 22}, "end_point": {"row": 146, "column": 24}}, {"id": 510, "type": "pointer_expression", "text": "&g_src_rec", "parent": 507, "children": [511], "start_point": {"row": 146, "column": 25}, "end_point": {"row": 146, "column": 35}}, {"id": 511, "type": "identifier", "text": "g_src_rec", "parent": 510, "children": [], "start_point": {"row": 146, "column": 26}, "end_point": {"row": 146, "column": 35}}, {"id": 512, "type": "function_definition", "text": "static void test_fs_end(struct m0_fdmi_src_rec *src_rec)\n{\n\tM0_UT_ASSERT(src_rec != NULL);\n\tM0_UT_ASSERT(src_rec == &g_src_rec);\n\t/* Calling of this function is a sign for fdmi_sd_post_record UT\n\t * that FDMI finished record processing */\n\tm0_semaphore_up(&g_sem);\n}", "parent": null, "children": [513, 514], "start_point": {"row": 149, "column": 0}, "end_point": {"row": 156, "column": 1}}, {"id": 513, "type": "primitive_type", "text": "void", "parent": 512, "children": [], "start_point": {"row": 149, "column": 7}, "end_point": {"row": 149, "column": 11}}, {"id": 514, "type": "function_declarator", "text": "test_fs_end(struct m0_fdmi_src_rec *src_rec)", "parent": 512, "children": [515, 516], "start_point": {"row": 149, "column": 12}, "end_point": {"row": 149, "column": 56}}, {"id": 515, "type": "identifier", "text": "test_fs_end", "parent": 514, "children": [], "start_point": {"row": 149, "column": 12}, "end_point": {"row": 149, "column": 23}}, {"id": 516, "type": "parameter_list", "text": "(struct m0_fdmi_src_rec *src_rec)", "parent": 514, "children": [517], "start_point": {"row": 149, "column": 23}, "end_point": {"row": 149, "column": 56}}, {"id": 517, "type": "parameter_declaration", "text": "struct m0_fdmi_src_rec *src_rec", "parent": 516, "children": [518, 521], "start_point": {"row": 149, "column": 24}, "end_point": {"row": 149, "column": 55}}, {"id": 518, "type": "struct_specifier", "text": "struct m0_fdmi_src_rec", "parent": 517, "children": [519, 520], "start_point": {"row": 149, "column": 24}, "end_point": {"row": 149, "column": 46}}, {"id": 519, "type": "struct", "text": "struct", "parent": 518, "children": [], "start_point": {"row": 149, "column": 24}, "end_point": {"row": 149, "column": 30}}, {"id": 520, "type": "type_identifier", "text": "m0_fdmi_src_rec", "parent": 518, "children": [], "start_point": {"row": 149, "column": 31}, "end_point": {"row": 149, "column": 46}}, {"id": 521, "type": "pointer_declarator", "text": "*src_rec", "parent": 517, "children": [522, 523], "start_point": {"row": 149, "column": 47}, "end_point": {"row": 149, "column": 55}}, {"id": 522, "type": "*", "text": "*", "parent": 521, "children": [], "start_point": {"row": 149, "column": 47}, "end_point": {"row": 149, "column": 48}}, {"id": 523, "type": "identifier", "text": "src_rec", "parent": 521, "children": [], "start_point": {"row": 149, "column": 48}, "end_point": {"row": 149, "column": 55}}, {"id": 524, "type": "call_expression", "text": "M0_UT_ASSERT(src_rec != NULL)", "parent": 512, "children": [525, 526], "start_point": {"row": 151, "column": 1}, "end_point": {"row": 151, "column": 30}}, {"id": 525, "type": "identifier", "text": "M0_UT_ASSERT", "parent": 524, "children": [], "start_point": {"row": 151, "column": 1}, "end_point": {"row": 151, "column": 13}}, {"id": 526, "type": "argument_list", "text": "(src_rec != NULL)", "parent": 524, "children": [527], "start_point": {"row": 151, "column": 13}, "end_point": {"row": 151, "column": 30}}, {"id": 527, "type": "binary_expression", "text": "src_rec != NULL", "parent": 526, "children": [528, 529, 530], "start_point": {"row": 151, "column": 14}, "end_point": {"row": 151, "column": 29}}, {"id": 528, "type": "identifier", "text": "src_rec", "parent": 527, "children": [], "start_point": {"row": 151, "column": 14}, "end_point": {"row": 151, "column": 21}}, {"id": 529, "type": "!=", "text": "!=", "parent": 527, "children": [], "start_point": {"row": 151, "column": 22}, "end_point": {"row": 151, "column": 24}}, {"id": 530, "type": "null", "text": "NULL", "parent": 527, "children": [531], "start_point": {"row": 151, "column": 25}, "end_point": {"row": 151, "column": 29}}, {"id": 531, "type": "NULL", "text": "NULL", "parent": 530, "children": [], "start_point": {"row": 151, "column": 25}, "end_point": {"row": 151, "column": 29}}, {"id": 532, "type": "call_expression", "text": "M0_UT_ASSERT(src_rec == &g_src_rec)", "parent": 512, "children": [533, 534], "start_point": {"row": 152, "column": 1}, "end_point": {"row": 152, "column": 36}}, {"id": 533, "type": "identifier", "text": "M0_UT_ASSERT", "parent": 532, "children": [], "start_point": {"row": 152, "column": 1}, "end_point": {"row": 152, "column": 13}}, {"id": 534, "type": "argument_list", "text": "(src_rec == &g_src_rec)", "parent": 532, "children": [535], "start_point": {"row": 152, "column": 13}, "end_point": {"row": 152, "column": 36}}, {"id": 535, "type": "binary_expression", "text": "src_rec == &g_src_rec", "parent": 534, "children": [536, 537, 538], "start_point": {"row": 152, "column": 14}, "end_point": {"row": 152, "column": 35}}, {"id": 536, "type": "identifier", "text": "src_rec", "parent": 535, "children": [], "start_point": {"row": 152, "column": 14}, "end_point": {"row": 152, "column": 21}}, {"id": 537, "type": "==", "text": "==", "parent": 535, "children": [], "start_point": {"row": 152, "column": 22}, "end_point": {"row": 152, "column": 24}}, {"id": 538, "type": "pointer_expression", "text": "&g_src_rec", "parent": 535, "children": [539], "start_point": {"row": 152, "column": 25}, "end_point": {"row": 152, "column": 35}}, {"id": 539, "type": "identifier", "text": "g_src_rec", "parent": 538, "children": [], "start_point": {"row": 152, "column": 26}, "end_point": {"row": 152, "column": 35}}, {"id": 540, "type": "call_expression", "text": "m0_semaphore_up(&g_sem)", "parent": 512, "children": [541, 542], "start_point": {"row": 155, "column": 1}, "end_point": {"row": 155, "column": 24}}, {"id": 541, "type": "identifier", "text": "m0_semaphore_up", "parent": 540, "children": [], "start_point": {"row": 155, "column": 1}, "end_point": {"row": 155, "column": 16}}, {"id": 542, "type": "argument_list", "text": "(&g_sem)", "parent": 540, "children": [543], "start_point": {"row": 155, "column": 16}, "end_point": {"row": 155, "column": 24}}, {"id": 543, "type": "pointer_expression", "text": "&g_sem", "parent": 542, "children": [544], "start_point": {"row": 155, "column": 17}, "end_point": {"row": 155, "column": 23}}, {"id": 544, "type": "identifier", "text": "g_sem", "parent": 543, "children": [], "start_point": {"row": 155, "column": 18}, "end_point": {"row": 155, "column": 23}}, {"id": 545, "type": "function_definition", "text": "static struct m0_fdmi_src *src_alloc()\n{\n\tstruct m0_fdmi_src *src;\n\tint rc;\n\n\trc = m0_fdmi_source_alloc(M0_FDMI_REC_TYPE_TEST, &src);\n\tM0_UT_ASSERT(rc == 0);\n\n\tsrc->fs_node_eval = test_fs_node_eval;\n\tsrc->fs_get = test_fs_get;\n\tsrc->fs_put = test_fs_put;\n\tsrc->fs_end = test_fs_end;\n\tsrc->fs_encode = test_fs_encode;\n\treturn src;\n}", "parent": null, "children": [546, 549], "start_point": {"row": 158, "column": 0}, "end_point": {"row": 172, "column": 1}}, {"id": 546, "type": "struct_specifier", "text": "struct m0_fdmi_src", "parent": 545, "children": [547, 548], "start_point": {"row": 158, "column": 7}, "end_point": {"row": 158, "column": 25}}, {"id": 547, "type": "struct", "text": "struct", "parent": 546, "children": [], "start_point": {"row": 158, "column": 7}, "end_point": {"row": 158, "column": 13}}, {"id": 548, "type": "type_identifier", "text": "m0_fdmi_src", "parent": 546, "children": [], "start_point": {"row": 158, "column": 14}, "end_point": {"row": 158, "column": 25}}, {"id": 549, "type": "pointer_declarator", "text": "*src_alloc()", "parent": 545, "children": [550, 551], "start_point": {"row": 158, "column": 26}, "end_point": {"row": 158, "column": 38}}, {"id": 550, "type": "*", "text": "*", "parent": 549, "children": [], "start_point": {"row": 158, "column": 26}, "end_point": {"row": 158, "column": 27}}, {"id": 551, "type": "function_declarator", "text": "src_alloc()", "parent": 549, "children": [552, 553], "start_point": {"row": 158, "column": 27}, "end_point": {"row": 158, "column": 38}}, {"id": 552, "type": "identifier", "text": "src_alloc", "parent": 551, "children": [], "start_point": {"row": 158, "column": 27}, "end_point": {"row": 158, "column": 36}}, {"id": 553, "type": "parameter_list", "text": "()", "parent": 551, "children": [], "start_point": {"row": 158, "column": 36}, "end_point": {"row": 158, "column": 38}}, {"id": 554, "type": "declaration", "text": "struct m0_fdmi_src *src;", "parent": 545, "children": [555, 558], "start_point": {"row": 160, "column": 1}, "end_point": {"row": 160, "column": 25}}, {"id": 555, "type": "struct_specifier", "text": "struct m0_fdmi_src", "parent": 554, "children": [556, 557], "start_point": {"row": 160, "column": 1}, "end_point": {"row": 160, "column": 19}}, {"id": 556, "type": "struct", "text": "struct", "parent": 555, "children": [], "start_point": {"row": 160, "column": 1}, "end_point": {"row": 160, "column": 7}}, {"id": 557, "type": "type_identifier", "text": "m0_fdmi_src", "parent": 555, "children": [], "start_point": {"row": 160, "column": 8}, "end_point": {"row": 160, "column": 19}}, {"id": 558, "type": "pointer_declarator", "text": "*src", "parent": 554, "children": [559, 560], "start_point": {"row": 160, "column": 20}, "end_point": {"row": 160, "column": 24}}, {"id": 559, "type": "*", "text": "*", "parent": 558, "children": [], "start_point": {"row": 160, "column": 20}, "end_point": {"row": 160, "column": 21}}, {"id": 560, "type": "identifier", "text": "src", "parent": 558, "children": [], "start_point": {"row": 160, "column": 21}, "end_point": {"row": 160, "column": 24}}, {"id": 561, "type": "declaration", "text": "int rc;", "parent": 545, "children": [562, 563], "start_point": {"row": 161, "column": 1}, "end_point": {"row": 161, "column": 24}}, {"id": 562, "type": "primitive_type", "text": "int", "parent": 561, "children": [], "start_point": {"row": 161, "column": 1}, "end_point": {"row": 161, "column": 4}}, {"id": 563, "type": "identifier", "text": "rc", "parent": 561, "children": [], "start_point": {"row": 161, "column": 21}, "end_point": {"row": 161, "column": 23}}, {"id": 564, "type": "assignment_expression", "text": "rc = m0_fdmi_source_alloc(M0_FDMI_REC_TYPE_TEST, &src)", "parent": 545, "children": [565, 566, 567], "start_point": {"row": 163, "column": 1}, "end_point": {"row": 163, "column": 55}}, {"id": 565, "type": "identifier", "text": "rc", "parent": 564, "children": [], "start_point": {"row": 163, "column": 1}, "end_point": {"row": 163, "column": 3}}, {"id": 566, "type": "=", "text": "=", "parent": 564, "children": [], "start_point": {"row": 163, "column": 4}, "end_point": {"row": 163, "column": 5}}, {"id": 567, "type": "call_expression", "text": "m0_fdmi_source_alloc(M0_FDMI_REC_TYPE_TEST, &src)", "parent": 564, "children": [568, 569], "start_point": {"row": 163, "column": 6}, "end_point": {"row": 163, "column": 55}}, {"id": 568, "type": "identifier", "text": "m0_fdmi_source_alloc", "parent": 567, "children": [], "start_point": {"row": 163, "column": 6}, "end_point": {"row": 163, "column": 26}}, {"id": 569, "type": "argument_list", "text": "(M0_FDMI_REC_TYPE_TEST, &src)", "parent": 567, "children": [570, 571], "start_point": {"row": 163, "column": 26}, "end_point": {"row": 163, "column": 55}}, {"id": 570, "type": "identifier", "text": "M0_FDMI_REC_TYPE_TEST", "parent": 569, "children": [], "start_point": {"row": 163, "column": 27}, "end_point": {"row": 163, "column": 48}}, {"id": 571, "type": "pointer_expression", "text": "&src", "parent": 569, "children": [572], "start_point": {"row": 163, "column": 50}, "end_point": {"row": 163, "column": 54}}, {"id": 572, "type": "identifier", "text": "src", "parent": 571, "children": [], "start_point": {"row": 163, "column": 51}, "end_point": {"row": 163, "column": 54}}, {"id": 573, "type": "call_expression", "text": "M0_UT_ASSERT(rc == 0)", "parent": 545, "children": [574, 575], "start_point": {"row": 164, "column": 1}, "end_point": {"row": 164, "column": 22}}, {"id": 574, "type": "identifier", "text": "M0_UT_ASSERT", "parent": 573, "children": [], "start_point": {"row": 164, "column": 1}, "end_point": {"row": 164, "column": 13}}, {"id": 575, "type": "argument_list", "text": "(rc == 0)", "parent": 573, "children": [576], "start_point": {"row": 164, "column": 13}, "end_point": {"row": 164, "column": 22}}, {"id": 576, "type": "binary_expression", "text": "rc == 0", "parent": 575, "children": [577, 578, 579], "start_point": {"row": 164, "column": 14}, "end_point": {"row": 164, "column": 21}}, {"id": 577, "type": "identifier", "text": "rc", "parent": 576, "children": [], "start_point": {"row": 164, "column": 14}, "end_point": {"row": 164, "column": 16}}, {"id": 578, "type": "==", "text": "==", "parent": 576, "children": [], "start_point": {"row": 164, "column": 17}, "end_point": {"row": 164, "column": 19}}, {"id": 579, "type": "number_literal", "text": "0", "parent": 576, "children": [], "start_point": {"row": 164, "column": 20}, "end_point": {"row": 164, "column": 21}}, {"id": 580, "type": "assignment_expression", "text": "src->fs_node_eval = test_fs_node_eval", "parent": 545, "children": [581, 584, 585], "start_point": {"row": 166, "column": 1}, "end_point": {"row": 166, "column": 39}}, {"id": 581, "type": "field_expression", "text": "src->fs_node_eval", "parent": 580, "children": [582, 583], "start_point": {"row": 166, "column": 1}, "end_point": {"row": 166, "column": 18}}, {"id": 582, "type": "identifier", "text": "src", "parent": 581, "children": [], "start_point": {"row": 166, "column": 1}, "end_point": {"row": 166, "column": 4}}, {"id": 583, "type": "field_identifier", "text": "fs_node_eval", "parent": 581, "children": [], "start_point": {"row": 166, "column": 6}, "end_point": {"row": 166, "column": 18}}, {"id": 584, "type": "=", "text": "=", "parent": 580, "children": [], "start_point": {"row": 166, "column": 20}, "end_point": {"row": 166, "column": 21}}, {"id": 585, "type": "identifier", "text": "test_fs_node_eval", "parent": 580, "children": [], "start_point": {"row": 166, "column": 22}, "end_point": {"row": 166, "column": 39}}, {"id": 586, "type": "assignment_expression", "text": "src->fs_get = test_fs_get", "parent": 545, "children": [587, 590, 591], "start_point": {"row": 167, "column": 1}, "end_point": {"row": 167, "column": 33}}, {"id": 587, "type": "field_expression", "text": "src->fs_get", "parent": 586, "children": [588, 589], "start_point": {"row": 167, "column": 1}, "end_point": {"row": 167, "column": 12}}, {"id": 588, "type": "identifier", "text": "src", "parent": 587, "children": [], "start_point": {"row": 167, "column": 1}, "end_point": {"row": 167, "column": 4}}, {"id": 589, "type": "field_identifier", "text": "fs_get", "parent": 587, "children": [], "start_point": {"row": 167, "column": 6}, "end_point": {"row": 167, "column": 12}}, {"id": 590, "type": "=", "text": "=", "parent": 586, "children": [], "start_point": {"row": 167, "column": 20}, "end_point": {"row": 167, "column": 21}}, {"id": 591, "type": "identifier", "text": "test_fs_get", "parent": 586, "children": [], "start_point": {"row": 167, "column": 22}, "end_point": {"row": 167, "column": 33}}, {"id": 592, "type": "assignment_expression", "text": "src->fs_put = test_fs_put", "parent": 545, "children": [593, 596, 597], "start_point": {"row": 168, "column": 1}, "end_point": {"row": 168, "column": 33}}, {"id": 593, "type": "field_expression", "text": "src->fs_put", "parent": 592, "children": [594, 595], "start_point": {"row": 168, "column": 1}, "end_point": {"row": 168, "column": 12}}, {"id": 594, "type": "identifier", "text": "src", "parent": 593, "children": [], "start_point": {"row": 168, "column": 1}, "end_point": {"row": 168, "column": 4}}, {"id": 595, "type": "field_identifier", "text": "fs_put", "parent": 593, "children": [], "start_point": {"row": 168, "column": 6}, "end_point": {"row": 168, "column": 12}}, {"id": 596, "type": "=", "text": "=", "parent": 592, "children": [], "start_point": {"row": 168, "column": 20}, "end_point": {"row": 168, "column": 21}}, {"id": 597, "type": "identifier", "text": "test_fs_put", "parent": 592, "children": [], "start_point": {"row": 168, "column": 22}, "end_point": {"row": 168, "column": 33}}, {"id": 598, "type": "assignment_expression", "text": "src->fs_end = test_fs_end", "parent": 545, "children": [599, 602, 603], "start_point": {"row": 169, "column": 1}, "end_point": {"row": 169, "column": 33}}, {"id": 599, "type": "field_expression", "text": "src->fs_end", "parent": 598, "children": [600, 601], "start_point": {"row": 169, "column": 1}, "end_point": {"row": 169, "column": 12}}, {"id": 600, "type": "identifier", "text": "src", "parent": 599, "children": [], "start_point": {"row": 169, "column": 1}, "end_point": {"row": 169, "column": 4}}, {"id": 601, "type": "field_identifier", "text": "fs_end", "parent": 599, "children": [], "start_point": {"row": 169, "column": 6}, "end_point": {"row": 169, "column": 12}}, {"id": 602, "type": "=", "text": "=", "parent": 598, "children": [], "start_point": {"row": 169, "column": 20}, "end_point": {"row": 169, "column": 21}}, {"id": 603, "type": "identifier", "text": "test_fs_end", "parent": 598, "children": [], "start_point": {"row": 169, "column": 22}, "end_point": {"row": 169, "column": 33}}, {"id": 604, "type": "assignment_expression", "text": "src->fs_encode = test_fs_encode", "parent": 545, "children": [605, 608, 609], "start_point": {"row": 170, "column": 1}, "end_point": {"row": 170, "column": 36}}, {"id": 605, "type": "field_expression", "text": "src->fs_encode", "parent": 604, "children": [606, 607], "start_point": {"row": 170, "column": 1}, "end_point": {"row": 170, "column": 15}}, {"id": 606, "type": "identifier", "text": "src", "parent": 605, "children": [], "start_point": {"row": 170, "column": 1}, "end_point": {"row": 170, "column": 4}}, {"id": 607, "type": "field_identifier", "text": "fs_encode", "parent": 605, "children": [], "start_point": {"row": 170, "column": 6}, "end_point": {"row": 170, "column": 15}}, {"id": 608, "type": "=", "text": "=", "parent": 604, "children": [], "start_point": {"row": 170, "column": 20}, "end_point": {"row": 170, "column": 21}}, {"id": 609, "type": "identifier", "text": "test_fs_encode", "parent": 604, "children": [], "start_point": {"row": 170, "column": 22}, "end_point": {"row": 170, "column": 36}}, {"id": 610, "type": "return_statement", "text": "return src;", "parent": 545, "children": [611], "start_point": {"row": 171, "column": 1}, "end_point": {"row": 171, "column": 12}}, {"id": 611, "type": "identifier", "text": "src", "parent": 610, "children": [], "start_point": {"row": 171, "column": 8}, "end_point": {"row": 171, "column": 11}}, {"id": 612, "type": "function_definition", "text": "static void fdmi_sd_apply_filter_internal(const struct m0_filterc_ops *ops)\n{\n\tstruct m0_fdmi_src *src = src_alloc();\n\tint rc;\n\n\tM0_ENTRY();\n\n\tg_var_str = strdup(\"test\");\n\tM0_SET0(&g_conf_filter);\n\n\tfdmi_serv_start_ut(ops);\n\tm0_semaphore_init(&g_sem, 0);\n\trc = m0_fdmi_source_register(src);\n\tM0_UT_ASSERT(rc == 0);\n\tg_src_rec = (struct m0_fdmi_src_rec) {\n\t\t.fsr_src = src,\n\t\t.fsr_data = g_fdmi_data,\n\t};\n\tM0_FDMI_SOURCE_POST_RECORD(&g_src_rec);\n\t/* Wait until record is processed and released */\n\tm0_semaphore_down(&g_sem);\n\tm0_fdmi_source_deregister(src);\n\tm0_fdmi_source_free(src);\n\tm0_semaphore_fini(&g_sem);\n\tfdmi_serv_stop_ut();\n\tM0_LEAVE();\n}", "parent": null, "children": [613, 614], "start_point": {"row": 174, "column": 0}, "end_point": {"row": 200, "column": 1}}, {"id": 613, "type": "primitive_type", "text": "void", "parent": 612, "children": [], "start_point": {"row": 174, "column": 7}, "end_point": {"row": 174, "column": 11}}, {"id": 614, "type": "function_declarator", "text": "fdmi_sd_apply_filter_internal(const struct m0_filterc_ops *ops)", "parent": 612, "children": [615, 616], "start_point": {"row": 174, "column": 12}, "end_point": {"row": 174, "column": 75}}, {"id": 615, "type": "identifier", "text": "fdmi_sd_apply_filter_internal", "parent": 614, "children": [], "start_point": {"row": 174, "column": 12}, "end_point": {"row": 174, "column": 41}}, {"id": 616, "type": "parameter_list", "text": "(const struct m0_filterc_ops *ops)", "parent": 614, "children": [617], "start_point": {"row": 174, "column": 41}, "end_point": {"row": 174, "column": 75}}, {"id": 617, "type": "parameter_declaration", "text": "const struct m0_filterc_ops *ops", "parent": 616, "children": [618, 621], "start_point": {"row": 174, "column": 42}, "end_point": {"row": 174, "column": 74}}, {"id": 618, "type": "struct_specifier", "text": "struct m0_filterc_ops", "parent": 617, "children": [619, 620], "start_point": {"row": 174, "column": 48}, "end_point": {"row": 174, "column": 69}}, {"id": 619, "type": "struct", "text": "struct", "parent": 618, "children": [], "start_point": {"row": 174, "column": 48}, "end_point": {"row": 174, "column": 54}}, {"id": 620, "type": "type_identifier", "text": "m0_filterc_ops", "parent": 618, "children": [], "start_point": {"row": 174, "column": 55}, "end_point": {"row": 174, "column": 69}}, {"id": 621, "type": "pointer_declarator", "text": "*ops", "parent": 617, "children": [622, 623], "start_point": {"row": 174, "column": 70}, "end_point": {"row": 174, "column": 74}}, {"id": 622, "type": "*", "text": "*", "parent": 621, "children": [], "start_point": {"row": 174, "column": 70}, "end_point": {"row": 174, "column": 71}}, {"id": 623, "type": "identifier", "text": "ops", "parent": 621, "children": [], "start_point": {"row": 174, "column": 71}, "end_point": {"row": 174, "column": 74}}, {"id": 624, "type": "declaration", "text": "struct m0_fdmi_src *src = src_alloc();", "parent": 612, "children": [625, 628], "start_point": {"row": 176, "column": 1}, "end_point": {"row": 176, "column": 51}}, {"id": 625, "type": "struct_specifier", "text": "struct m0_fdmi_src", "parent": 624, "children": [626, 627], "start_point": {"row": 176, "column": 1}, "end_point": {"row": 176, "column": 19}}, {"id": 626, "type": "struct", "text": "struct", "parent": 625, "children": [], "start_point": {"row": 176, "column": 1}, "end_point": {"row": 176, "column": 7}}, {"id": 627, "type": "type_identifier", "text": "m0_fdmi_src", "parent": 625, "children": [], "start_point": {"row": 176, "column": 8}, "end_point": {"row": 176, "column": 19}}, {"id": 628, "type": "init_declarator", "text": "*src = src_alloc()", "parent": 624, "children": [629, 632, 633], "start_point": {"row": 176, "column": 32}, "end_point": {"row": 176, "column": 50}}, {"id": 629, "type": "pointer_declarator", "text": "*src", "parent": 628, "children": [630, 631], "start_point": {"row": 176, "column": 32}, "end_point": {"row": 176, "column": 36}}, {"id": 630, "type": "*", "text": "*", "parent": 629, "children": [], "start_point": {"row": 176, "column": 32}, "end_point": {"row": 176, "column": 33}}, {"id": 631, "type": "identifier", "text": "src", "parent": 629, "children": [], "start_point": {"row": 176, "column": 33}, "end_point": {"row": 176, "column": 36}}, {"id": 632, "type": "=", "text": "=", "parent": 628, "children": [], "start_point": {"row": 176, "column": 37}, "end_point": {"row": 176, "column": 38}}, {"id": 633, "type": "call_expression", "text": "src_alloc()", "parent": 628, "children": [634, 635], "start_point": {"row": 176, "column": 39}, "end_point": {"row": 176, "column": 50}}, {"id": 634, "type": "identifier", "text": "src_alloc", "parent": 633, "children": [], "start_point": {"row": 176, "column": 39}, "end_point": {"row": 176, "column": 48}}, {"id": 635, "type": "argument_list", "text": "()", "parent": 633, "children": [], "start_point": {"row": 176, "column": 48}, "end_point": {"row": 176, "column": 50}}, {"id": 636, "type": "declaration", "text": "int rc;", "parent": 612, "children": [637, 638], "start_point": {"row": 177, "column": 1}, "end_point": {"row": 177, "column": 36}}, {"id": 637, "type": "primitive_type", "text": "int", "parent": 636, "children": [], "start_point": {"row": 177, "column": 1}, "end_point": {"row": 177, "column": 4}}, {"id": 638, "type": "identifier", "text": "rc", "parent": 636, "children": [], "start_point": {"row": 177, "column": 33}, "end_point": {"row": 177, "column": 35}}, {"id": 639, "type": "call_expression", "text": "M0_ENTRY()", "parent": 612, "children": [640, 641], "start_point": {"row": 179, "column": 1}, "end_point": {"row": 179, "column": 11}}, {"id": 640, "type": "identifier", "text": "M0_ENTRY", "parent": 639, "children": [], "start_point": {"row": 179, "column": 1}, "end_point": {"row": 179, "column": 9}}, {"id": 641, "type": "argument_list", "text": "()", "parent": 639, "children": [], "start_point": {"row": 179, "column": 9}, "end_point": {"row": 179, "column": 11}}, {"id": 642, "type": "assignment_expression", "text": "g_var_str = strdup(\"test\")", "parent": 612, "children": [643, 644, 645], "start_point": {"row": 181, "column": 1}, "end_point": {"row": 181, "column": 27}}, {"id": 643, "type": "identifier", "text": "g_var_str", "parent": 642, "children": [], "start_point": {"row": 181, "column": 1}, "end_point": {"row": 181, "column": 10}}, {"id": 644, "type": "=", "text": "=", "parent": 642, "children": [], "start_point": {"row": 181, "column": 11}, "end_point": {"row": 181, "column": 12}}, {"id": 645, "type": "call_expression", "text": "strdup(\"test\")", "parent": 642, "children": [646, 647], "start_point": {"row": 181, "column": 13}, "end_point": {"row": 181, "column": 27}}, {"id": 646, "type": "identifier", "text": "strdup", "parent": 645, "children": [], "start_point": {"row": 181, "column": 13}, "end_point": {"row": 181, "column": 19}}, {"id": 647, "type": "argument_list", "text": "(\"test\")", "parent": 645, "children": [648], "start_point": {"row": 181, "column": 19}, "end_point": {"row": 181, "column": 27}}, {"id": 648, "type": "string_literal", "text": "\"test\"", "parent": 647, "children": [], "start_point": {"row": 181, "column": 20}, "end_point": {"row": 181, "column": 26}}, {"id": 649, "type": "call_expression", "text": "M0_SET0(&g_conf_filter)", "parent": 612, "children": [650, 651], "start_point": {"row": 182, "column": 1}, "end_point": {"row": 182, "column": 24}}, {"id": 650, "type": "identifier", "text": "M0_SET0", "parent": 649, "children": [], "start_point": {"row": 182, "column": 1}, "end_point": {"row": 182, "column": 8}}, {"id": 651, "type": "argument_list", "text": "(&g_conf_filter)", "parent": 649, "children": [652], "start_point": {"row": 182, "column": 8}, "end_point": {"row": 182, "column": 24}}, {"id": 652, "type": "pointer_expression", "text": "&g_conf_filter", "parent": 651, "children": [653], "start_point": {"row": 182, "column": 9}, "end_point": {"row": 182, "column": 23}}, {"id": 653, "type": "identifier", "text": "g_conf_filter", "parent": 652, "children": [], "start_point": {"row": 182, "column": 10}, "end_point": {"row": 182, "column": 23}}, {"id": 654, "type": "call_expression", "text": "fdmi_serv_start_ut(ops)", "parent": 612, "children": [655, 656], "start_point": {"row": 184, "column": 1}, "end_point": {"row": 184, "column": 24}}, {"id": 655, "type": "identifier", "text": "fdmi_serv_start_ut", "parent": 654, "children": [], "start_point": {"row": 184, "column": 1}, "end_point": {"row": 184, "column": 19}}, {"id": 656, "type": "argument_list", "text": "(ops)", "parent": 654, "children": [657], "start_point": {"row": 184, "column": 19}, "end_point": {"row": 184, "column": 24}}, {"id": 657, "type": "identifier", "text": "ops", "parent": 656, "children": [], "start_point": {"row": 184, "column": 20}, "end_point": {"row": 184, "column": 23}}, {"id": 658, "type": "call_expression", "text": "m0_semaphore_init(&g_sem, 0)", "parent": 612, "children": [659, 660], "start_point": {"row": 185, "column": 1}, "end_point": {"row": 185, "column": 29}}, {"id": 659, "type": "identifier", "text": "m0_semaphore_init", "parent": 658, "children": [], "start_point": {"row": 185, "column": 1}, "end_point": {"row": 185, "column": 18}}, {"id": 660, "type": "argument_list", "text": "(&g_sem, 0)", "parent": 658, "children": [661, 663], "start_point": {"row": 185, "column": 18}, "end_point": {"row": 185, "column": 29}}, {"id": 661, "type": "pointer_expression", "text": "&g_sem", "parent": 660, "children": [662], "start_point": {"row": 185, "column": 19}, "end_point": {"row": 185, "column": 25}}, {"id": 662, "type": "identifier", "text": "g_sem", "parent": 661, "children": [], "start_point": {"row": 185, "column": 20}, "end_point": {"row": 185, "column": 25}}, {"id": 663, "type": "number_literal", "text": "0", "parent": 660, "children": [], "start_point": {"row": 185, "column": 27}, "end_point": {"row": 185, "column": 28}}, {"id": 664, "type": "assignment_expression", "text": "rc = m0_fdmi_source_register(src)", "parent": 612, "children": [665, 666, 667], "start_point": {"row": 186, "column": 1}, "end_point": {"row": 186, "column": 34}}, {"id": 665, "type": "identifier", "text": "rc", "parent": 664, "children": [], "start_point": {"row": 186, "column": 1}, "end_point": {"row": 186, "column": 3}}, {"id": 666, "type": "=", "text": "=", "parent": 664, "children": [], "start_point": {"row": 186, "column": 4}, "end_point": {"row": 186, "column": 5}}, {"id": 667, "type": "call_expression", "text": "m0_fdmi_source_register(src)", "parent": 664, "children": [668, 669], "start_point": {"row": 186, "column": 6}, "end_point": {"row": 186, "column": 34}}, {"id": 668, "type": "identifier", "text": "m0_fdmi_source_register", "parent": 667, "children": [], "start_point": {"row": 186, "column": 6}, "end_point": {"row": 186, "column": 29}}, {"id": 669, "type": "argument_list", "text": "(src)", "parent": 667, "children": [670], "start_point": {"row": 186, "column": 29}, "end_point": {"row": 186, "column": 34}}, {"id": 670, "type": "identifier", "text": "src", "parent": 669, "children": [], "start_point": {"row": 186, "column": 30}, "end_point": {"row": 186, "column": 33}}, {"id": 671, "type": "call_expression", "text": "M0_UT_ASSERT(rc == 0)", "parent": 612, "children": [672, 673], "start_point": {"row": 187, "column": 1}, "end_point": {"row": 187, "column": 22}}, {"id": 672, "type": "identifier", "text": "M0_UT_ASSERT", "parent": 671, "children": [], "start_point": {"row": 187, "column": 1}, "end_point": {"row": 187, "column": 13}}, {"id": 673, "type": "argument_list", "text": "(rc == 0)", "parent": 671, "children": [674], "start_point": {"row": 187, "column": 13}, "end_point": {"row": 187, "column": 22}}, {"id": 674, "type": "binary_expression", "text": "rc == 0", "parent": 673, "children": [675, 676, 677], "start_point": {"row": 187, "column": 14}, "end_point": {"row": 187, "column": 21}}, {"id": 675, "type": "identifier", "text": "rc", "parent": 674, "children": [], "start_point": {"row": 187, "column": 14}, "end_point": {"row": 187, "column": 16}}, {"id": 676, "type": "==", "text": "==", "parent": 674, "children": [], "start_point": {"row": 187, "column": 17}, "end_point": {"row": 187, "column": 19}}, {"id": 677, "type": "number_literal", "text": "0", "parent": 674, "children": [], "start_point": {"row": 187, "column": 20}, "end_point": {"row": 187, "column": 21}}, {"id": 678, "type": "assignment_expression", "text": "g_src_rec = (struct m0_fdmi_src_rec) {\n\t\t.fsr_src = src,\n\t\t.fsr_data = g_fdmi_data,\n\t}", "parent": 612, "children": [679, 680, 681], "start_point": {"row": 188, "column": 1}, "end_point": {"row": 191, "column": 2}}, {"id": 679, "type": "identifier", "text": "g_src_rec", "parent": 678, "children": [], "start_point": {"row": 188, "column": 1}, "end_point": {"row": 188, "column": 10}}, {"id": 680, "type": "=", "text": "=", "parent": 678, "children": [], "start_point": {"row": 188, "column": 11}, "end_point": {"row": 188, "column": 12}}, {"id": 681, "type": "compound_literal_expression", "text": "(struct m0_fdmi_src_rec) {\n\t\t.fsr_src = src,\n\t\t.fsr_data = g_fdmi_data,\n\t}", "parent": 678, "children": [682, 686], "start_point": {"row": 188, "column": 13}, "end_point": {"row": 191, "column": 2}}, {"id": 682, "type": "type_descriptor", "text": "struct m0_fdmi_src_rec", "parent": 681, "children": [683], "start_point": {"row": 188, "column": 14}, "end_point": {"row": 188, "column": 36}}, {"id": 683, "type": "struct_specifier", "text": "struct m0_fdmi_src_rec", "parent": 682, "children": [684, 685], "start_point": {"row": 188, "column": 14}, "end_point": {"row": 188, "column": 36}}, {"id": 684, "type": "struct", "text": "struct", "parent": 683, "children": [], "start_point": {"row": 188, "column": 14}, "end_point": {"row": 188, "column": 20}}, {"id": 685, "type": "type_identifier", "text": "m0_fdmi_src_rec", "parent": 683, "children": [], "start_point": {"row": 188, "column": 21}, "end_point": {"row": 188, "column": 36}}, {"id": 686, "type": "initializer_list", "text": "{\n\t\t.fsr_src = src,\n\t\t.fsr_data = g_fdmi_data,\n\t}", "parent": 681, "children": [687, 692], "start_point": {"row": 188, "column": 38}, "end_point": {"row": 191, "column": 2}}, {"id": 687, "type": "initializer_pair", "text": ".fsr_src = src", "parent": 686, "children": [688, 690, 691], "start_point": {"row": 189, "column": 2}, "end_point": {"row": 189, "column": 19}}, {"id": 688, "type": "field_designator", "text": ".fsr_src", "parent": 687, "children": [689], "start_point": {"row": 189, "column": 2}, "end_point": {"row": 189, "column": 10}}, {"id": 689, "type": "field_identifier", "text": "fsr_src", "parent": 688, "children": [], "start_point": {"row": 189, "column": 3}, "end_point": {"row": 189, "column": 10}}, {"id": 690, "type": "=", "text": "=", "parent": 687, "children": [], "start_point": {"row": 189, "column": 14}, "end_point": {"row": 189, "column": 15}}, {"id": 691, "type": "identifier", "text": "src", "parent": 687, "children": [], "start_point": {"row": 189, "column": 16}, "end_point": {"row": 189, "column": 19}}, {"id": 692, "type": "initializer_pair", "text": ".fsr_data = g_fdmi_data", "parent": 686, "children": [693, 695, 696], "start_point": {"row": 190, "column": 2}, "end_point": {"row": 190, "column": 27}}, {"id": 693, "type": "field_designator", "text": ".fsr_data", "parent": 692, "children": [694], "start_point": {"row": 190, "column": 2}, "end_point": {"row": 190, "column": 11}}, {"id": 694, "type": "field_identifier", "text": "fsr_data", "parent": 693, "children": [], "start_point": {"row": 190, "column": 3}, "end_point": {"row": 190, "column": 11}}, {"id": 695, "type": "=", "text": "=", "parent": 692, "children": [], "start_point": {"row": 190, "column": 14}, "end_point": {"row": 190, "column": 15}}, {"id": 696, "type": "identifier", "text": "g_fdmi_data", "parent": 692, "children": [], "start_point": {"row": 190, "column": 16}, "end_point": {"row": 190, "column": 27}}, {"id": 697, "type": "call_expression", "text": "M0_FDMI_SOURCE_POST_RECORD(&g_src_rec)", "parent": 612, "children": [698, 699], "start_point": {"row": 192, "column": 1}, "end_point": {"row": 192, "column": 39}}, {"id": 698, "type": "identifier", "text": "M0_FDMI_SOURCE_POST_RECORD", "parent": 697, "children": [], "start_point": {"row": 192, "column": 1}, "end_point": {"row": 192, "column": 27}}, {"id": 699, "type": "argument_list", "text": "(&g_src_rec)", "parent": 697, "children": [700], "start_point": {"row": 192, "column": 27}, "end_point": {"row": 192, "column": 39}}, {"id": 700, "type": "pointer_expression", "text": "&g_src_rec", "parent": 699, "children": [701], "start_point": {"row": 192, "column": 28}, "end_point": {"row": 192, "column": 38}}, {"id": 701, "type": "identifier", "text": "g_src_rec", "parent": 700, "children": [], "start_point": {"row": 192, "column": 29}, "end_point": {"row": 192, "column": 38}}, {"id": 702, "type": "call_expression", "text": "m0_semaphore_down(&g_sem)", "parent": 612, "children": [703, 704], "start_point": {"row": 194, "column": 1}, "end_point": {"row": 194, "column": 26}}, {"id": 703, "type": "identifier", "text": "m0_semaphore_down", "parent": 702, "children": [], "start_point": {"row": 194, "column": 1}, "end_point": {"row": 194, "column": 18}}, {"id": 704, "type": "argument_list", "text": "(&g_sem)", "parent": 702, "children": [705], "start_point": {"row": 194, "column": 18}, "end_point": {"row": 194, "column": 26}}, {"id": 705, "type": "pointer_expression", "text": "&g_sem", "parent": 704, "children": [706], "start_point": {"row": 194, "column": 19}, "end_point": {"row": 194, "column": 25}}, {"id": 706, "type": "identifier", "text": "g_sem", "parent": 705, "children": [], "start_point": {"row": 194, "column": 20}, "end_point": {"row": 194, "column": 25}}, {"id": 707, "type": "call_expression", "text": "m0_fdmi_source_deregister(src)", "parent": 612, "children": [708, 709], "start_point": {"row": 195, "column": 1}, "end_point": {"row": 195, "column": 31}}, {"id": 708, "type": "identifier", "text": "m0_fdmi_source_deregister", "parent": 707, "children": [], "start_point": {"row": 195, "column": 1}, "end_point": {"row": 195, "column": 26}}, {"id": 709, "type": "argument_list", "text": "(src)", "parent": 707, "children": [710], "start_point": {"row": 195, "column": 26}, "end_point": {"row": 195, "column": 31}}, {"id": 710, "type": "identifier", "text": "src", "parent": 709, "children": [], "start_point": {"row": 195, "column": 27}, "end_point": {"row": 195, "column": 30}}, {"id": 711, "type": "call_expression", "text": "m0_fdmi_source_free(src)", "parent": 612, "children": [712, 713], "start_point": {"row": 196, "column": 1}, "end_point": {"row": 196, "column": 25}}, {"id": 712, "type": "identifier", "text": "m0_fdmi_source_free", "parent": 711, "children": [], "start_point": {"row": 196, "column": 1}, "end_point": {"row": 196, "column": 20}}, {"id": 713, "type": "argument_list", "text": "(src)", "parent": 711, "children": [714], "start_point": {"row": 196, "column": 20}, "end_point": {"row": 196, "column": 25}}, {"id": 714, "type": "identifier", "text": "src", "parent": 713, "children": [], "start_point": {"row": 196, "column": 21}, "end_point": {"row": 196, "column": 24}}, {"id": 715, "type": "call_expression", "text": "m0_semaphore_fini(&g_sem)", "parent": 612, "children": [716, 717], "start_point": {"row": 197, "column": 1}, "end_point": {"row": 197, "column": 26}}, {"id": 716, "type": "identifier", "text": "m0_semaphore_fini", "parent": 715, "children": [], "start_point": {"row": 197, "column": 1}, "end_point": {"row": 197, "column": 18}}, {"id": 717, "type": "argument_list", "text": "(&g_sem)", "parent": 715, "children": [718], "start_point": {"row": 197, "column": 18}, "end_point": {"row": 197, "column": 26}}, {"id": 718, "type": "pointer_expression", "text": "&g_sem", "parent": 717, "children": [719], "start_point": {"row": 197, "column": 19}, "end_point": {"row": 197, "column": 25}}, {"id": 719, "type": "identifier", "text": "g_sem", "parent": 718, "children": [], "start_point": {"row": 197, "column": 20}, "end_point": {"row": 197, "column": 25}}, {"id": 720, "type": "call_expression", "text": "fdmi_serv_stop_ut()", "parent": 612, "children": [721, 722], "start_point": {"row": 198, "column": 1}, "end_point": {"row": 198, "column": 20}}, {"id": 721, "type": "identifier", "text": "fdmi_serv_stop_ut", "parent": 720, "children": [], "start_point": {"row": 198, "column": 1}, "end_point": {"row": 198, "column": 18}}, {"id": 722, "type": "argument_list", "text": "()", "parent": 720, "children": [], "start_point": {"row": 198, "column": 18}, "end_point": {"row": 198, "column": 20}}, {"id": 723, "type": "call_expression", "text": "M0_LEAVE()", "parent": 612, "children": [724, 725], "start_point": {"row": 199, "column": 1}, "end_point": {"row": 199, "column": 11}}, {"id": 724, "type": "identifier", "text": "M0_LEAVE", "parent": 723, "children": [], "start_point": {"row": 199, "column": 1}, "end_point": {"row": 199, "column": 9}}, {"id": 725, "type": "argument_list", "text": "()", "parent": 723, "children": [], "start_point": {"row": 199, "column": 9}, "end_point": {"row": 199, "column": 11}}, {"id": 726, "type": "function_definition", "text": "void fdmi_sd_apply_filter(void)\n{\n\tM0_ENTRY();\n\tfdmi_sd_apply_filter_internal(&filterc_apply_flt_ops);\n\tM0_LEAVE();\n}", "parent": null, "children": [727, 728], "start_point": {"row": 202, "column": 0}, "end_point": {"row": 207, "column": 1}}, {"id": 727, "type": "primitive_type", "text": "void", "parent": 726, "children": [], "start_point": {"row": 202, "column": 0}, "end_point": {"row": 202, "column": 4}}, {"id": 728, "type": "function_declarator", "text": "fdmi_sd_apply_filter(void)", "parent": 726, "children": [729, 730], "start_point": {"row": 202, "column": 5}, "end_point": {"row": 202, "column": 31}}, {"id": 729, "type": "identifier", "text": "fdmi_sd_apply_filter", "parent": 728, "children": [], "start_point": {"row": 202, "column": 5}, "end_point": {"row": 202, "column": 25}}, {"id": 730, "type": "parameter_list", "text": "(void)", "parent": 728, "children": [731], "start_point": {"row": 202, "column": 25}, "end_point": {"row": 202, "column": 31}}, {"id": 731, "type": "parameter_declaration", "text": "void", "parent": 730, "children": [732], "start_point": {"row": 202, "column": 26}, "end_point": {"row": 202, "column": 30}}, {"id": 732, "type": "primitive_type", "text": "void", "parent": 731, "children": [], "start_point": {"row": 202, "column": 26}, "end_point": {"row": 202, "column": 30}}, {"id": 733, "type": "call_expression", "text": "M0_ENTRY()", "parent": 726, "children": [734, 735], "start_point": {"row": 204, "column": 1}, "end_point": {"row": 204, "column": 11}}, {"id": 734, "type": "identifier", "text": "M0_ENTRY", "parent": 733, "children": [], "start_point": {"row": 204, "column": 1}, "end_point": {"row": 204, "column": 9}}, {"id": 735, "type": "argument_list", "text": "()", "parent": 733, "children": [], "start_point": {"row": 204, "column": 9}, "end_point": {"row": 204, "column": 11}}, {"id": 736, "type": "call_expression", "text": "fdmi_sd_apply_filter_internal(&filterc_apply_flt_ops)", "parent": 726, "children": [737, 738], "start_point": {"row": 205, "column": 1}, "end_point": {"row": 205, "column": 54}}, {"id": 737, "type": "identifier", "text": "fdmi_sd_apply_filter_internal", "parent": 736, "children": [], "start_point": {"row": 205, "column": 1}, "end_point": {"row": 205, "column": 30}}, {"id": 738, "type": "argument_list", "text": "(&filterc_apply_flt_ops)", "parent": 736, "children": [739], "start_point": {"row": 205, "column": 30}, "end_point": {"row": 205, "column": 54}}, {"id": 739, "type": "pointer_expression", "text": "&filterc_apply_flt_ops", "parent": 738, "children": [740], "start_point": {"row": 205, "column": 31}, "end_point": {"row": 205, "column": 53}}, {"id": 740, "type": "identifier", "text": "filterc_apply_flt_ops", "parent": 739, "children": [], "start_point": {"row": 205, "column": 32}, "end_point": {"row": 205, "column": 53}}, {"id": 741, "type": "call_expression", "text": "M0_LEAVE()", "parent": 726, "children": [742, 743], "start_point": {"row": 206, "column": 1}, "end_point": {"row": 206, "column": 11}}, {"id": 742, "type": "identifier", "text": "M0_LEAVE", "parent": 741, "children": [], "start_point": {"row": 206, "column": 1}, "end_point": {"row": 206, "column": 9}}, {"id": 743, "type": "argument_list", "text": "()", "parent": 741, "children": [], "start_point": {"row": 206, "column": 9}, "end_point": {"row": 206, "column": 11}}, {"id": 744, "type": "preproc_call", "text": "#undef M0_TRACE_SUBSYSTEM\n", "parent": null, "children": [745, 746], "start_point": {"row": 209, "column": 0}, "end_point": {"row": 210, "column": 0}}, {"id": 745, "type": "preproc_directive", "text": "#undef", "parent": 744, "children": [], "start_point": {"row": 209, "column": 0}, "end_point": {"row": 209, "column": 6}}, {"id": 746, "type": "preproc_arg", "text": "M0_TRACE_SUBSYSTEM", "parent": 744, "children": [], "start_point": {"row": 209, "column": 7}, "end_point": {"row": 209, "column": 25}}]}, "node_categories": {"declarations": {"functions": [54, 73, 85, 109, 130, 173, 175, 194, 196, 206, 208, 232, 234, 348, 350, 367, 369, 443, 445, 468, 470, 484, 486, 512, 514, 545, 551, 612, 614, 726, 728], "variables": [25, 30, 37, 42, 47, 52, 57, 64, 71, 76, 83, 88, 95, 100, 107, 112, 119, 128, 133, 140, 178, 185, 199, 211, 218, 223, 237, 244, 253, 256, 262, 275, 282, 353, 372, 379, 386, 448, 455, 473, 489, 517, 554, 561, 617, 624, 636, 731], "classes": [26, 27, 38, 39, 43, 44, 58, 59, 65, 66, 77, 78, 89, 90, 101, 102, 113, 114, 120, 121, 134, 135, 141, 142, 179, 180, 186, 187, 200, 201, 212, 213, 224, 225, 238, 239, 245, 246, 263, 264, 276, 277, 283, 284, 354, 355, 373, 374, 380, 381, 387, 388, 449, 450, 456, 457, 474, 475, 490, 491, 518, 519, 546, 547, 555, 556, 618, 619, 625, 626, 683, 684], "imports": [4, 5, 7, 8, 10, 11, 13, 14, 16, 17, 19, 20, 22, 23], "modules": [], "enums": [96, 97, 219, 220]}, "statements": {"expressions": [271, 272, 288, 293, 298, 302, 306, 309, 310, 314, 320, 324, 336, 360, 363, 364, 393, 396, 399, 401, 404, 405, 409, 411, 414, 415, 416, 421, 425, 428, 429, 430, 436, 462, 480, 496, 499, 504, 507, 510, 524, 527, 532, 535, 538, 540, 543, 567, 571, 573, 576, 581, 587, 593, 599, 605, 633, 639, 645, 649, 652, 654, 658, 661, 667, 671, 674, 681, 697, 700, 702, 705, 707, 711, 715, 718, 720, 723, 733, 736, 739, 741], "assignments": [295, 319, 326, 330, 335, 342, 564, 580, 586, 592, 598, 604, 642, 664, 678], "loops": [], "conditionals": [2, 28, 29, 34, 40, 41, 45, 46, 51, 55, 60, 63, 67, 70, 74, 79, 82, 86, 91, 94, 98, 99, 103, 106, 110, 115, 118, 122, 127, 131, 136, 139, 143, 145, 150, 152, 155, 157, 160, 162, 165, 167, 170, 172, 176, 181, 184, 188, 191, 197, 202, 205, 209, 214, 217, 221, 222, 226, 229, 235, 240, 243, 247, 252, 255, 259, 265, 269, 273, 274, 278, 281, 285, 289, 291, 292, 294, 296, 299, 301, 303, 307, 311, 313, 315, 317, 318, 322, 325, 327, 331, 338, 343, 347, 351, 356, 359, 361, 365, 366, 370, 375, 378, 382, 385, 389, 392, 394, 397, 400, 402, 406, 407, 410, 412, 417, 418, 419, 422, 424, 426, 431, 432, 433, 435, 437, 439, 446, 451, 454, 458, 461, 463, 471, 476, 479, 481, 487, 492, 495, 497, 500, 505, 508, 511, 515, 520, 523, 525, 528, 533, 536, 539, 541, 544, 548, 552, 557, 560, 563, 565, 568, 570, 572, 574, 577, 582, 583, 585, 588, 589, 591, 594, 595, 597, 600, 601, 603, 606, 607, 609, 611, 615, 620, 623, 627, 631, 634, 638, 640, 643, 646, 650, 653, 655, 657, 659, 662, 665, 668, 670, 672, 675, 679, 685, 689, 691, 694, 696, 698, 701, 703, 706, 708, 710, 712, 714, 716, 719, 721, 724, 729, 734, 737, 740, 742], "returns": [192, 230, 346, 441, 466, 610], "exceptions": []}, "expressions": {"calls": [744], "literals": [6, 9, 12, 15, 18, 21, 24, 36, 193, 231, 329, 345, 442, 467, 579, 648, 663, 677], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": [149, 154, 159, 164, 169, 688, 693]}}, "cross_language_map": {"function_declarations": [{"node_id": 54, "universal_type": "function", "name": "m0_reqh", "text_snippet": "filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n\t\t\t\t struct m0_reqh *reqh)"}, {"node_id": 73, "universal_type": "function", "name": "unknown", "text_snippet": "filterc_apply_flt_stop(struct m0_filterc_ctx *ctx)"}, {"node_id": 85, "universal_type": "function", "name": "m0_filterc_iter", "text_snippet": "filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n\t\t\t\t enum m0_fdmi_rec_type_id rec_type_id,\n\t\t\t"}, {"node_id": 109, "universal_type": "function", "name": "m0_conf_fdmi_filter", "text_snippet": "filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n\t\t\t\t struct m0_conf_fdmi_filter **"}, {"node_id": 130, "universal_type": "function", "name": "unknown", "text_snippet": "filterc_apply_flt_close(struct m0_filterc_iter *iter)"}, {"node_id": 173, "universal_type": "function", "name": "filterc_apply_flt_start", "text_snippet": "static int filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n\t\t\t\t struct m0_reqh *reqh)\n{"}, {"node_id": 175, "universal_type": "function", "name": "m0_reqh", "text_snippet": "filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n\t\t\t\t struct m0_reqh *reqh)"}, {"node_id": 194, "universal_type": "function", "name": "filterc_apply_flt_stop", "text_snippet": "static void filterc_apply_flt_stop(struct m0_filterc_ctx *ctx)\n{\n}"}, {"node_id": 196, "universal_type": "function", "name": "unknown", "text_snippet": "filterc_apply_flt_stop(struct m0_filterc_ctx *ctx)"}, {"node_id": 206, "universal_type": "function", "name": "filterc_apply_flt_open", "text_snippet": "static int filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n\t\t\t\t enum m0_fdmi_rec_type_id rec_t"}, {"node_id": 208, "universal_type": "function", "name": "m0_filterc_iter", "text_snippet": "filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n\t\t\t\t enum m0_fdmi_rec_type_id rec_type_id,\n\t\t\t"}, {"node_id": 232, "universal_type": "function", "name": "filterc_apply_flt_get_next", "text_snippet": "static int filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n\t\t\t\t struct m0_conf_fdm"}, {"node_id": 234, "universal_type": "function", "name": "m0_conf_fdmi_filter", "text_snippet": "filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n\t\t\t\t struct m0_conf_fdmi_filter **"}, {"node_id": 348, "universal_type": "function", "name": "filterc_apply_flt_close", "text_snippet": "static void filterc_apply_flt_close(struct m0_filterc_iter *iter)\n{\n\tm0_fdmi_filter_fini(&g_conf_fil"}, {"node_id": 350, "universal_type": "function", "name": "unknown", "text_snippet": "filterc_apply_flt_close(struct m0_filterc_iter *iter)"}, {"node_id": 367, "universal_type": "function", "name": "test_fs_node_eval", "text_snippet": "static int test_fs_node_eval(\n\t\tstruct m0_fdmi_src_rec *src_rec,\n\t\tstruct m0_fdmi_flt_var_node *valu"}, {"node_id": 369, "universal_type": "function", "name": "m0_fdmi_src_rec", "text_snippet": "test_fs_node_eval(\n\t\tstruct m0_fdmi_src_rec *src_rec,\n\t\tstruct m0_fdmi_flt_var_node *value_desc,\n\t\ts"}, {"node_id": 443, "universal_type": "function", "name": "test_fs_encode", "text_snippet": "static int test_fs_encode(struct m0_fdmi_src_rec *src_rec,\n\t\t\t struct m0_buf *buf)\n{\n\tM0_U"}, {"node_id": 445, "universal_type": "function", "name": "m0_buf", "text_snippet": "test_fs_encode(struct m0_fdmi_src_rec *src_rec,\n\t\t\t struct m0_buf *buf)"}, {"node_id": 468, "universal_type": "function", "name": "test_fs_get", "text_snippet": "static void test_fs_get(struct m0_fdmi_src_rec *src_rec)\n{\n\tM0_UT_ASSERT(false);\n}"}, {"node_id": 470, "universal_type": "function", "name": "unknown", "text_snippet": "test_fs_get(struct m0_fdmi_src_rec *src_rec)"}, {"node_id": 484, "universal_type": "function", "name": "test_fs_put", "text_snippet": "static void test_fs_put(struct m0_fdmi_src_rec *src_rec)\n{\n\tM0_UT_ASSERT(src_rec != NULL);\n\tM0_UT_AS"}, {"node_id": 486, "universal_type": "function", "name": "unknown", "text_snippet": "test_fs_put(struct m0_fdmi_src_rec *src_rec)"}, {"node_id": 512, "universal_type": "function", "name": "test_fs_end", "text_snippet": "static void test_fs_end(struct m0_fdmi_src_rec *src_rec)\n{\n\tM0_UT_ASSERT(src_rec != NULL);\n\tM0_UT_AS"}, {"node_id": 514, "universal_type": "function", "name": "unknown", "text_snippet": "test_fs_end(struct m0_fdmi_src_rec *src_rec)"}, {"node_id": 545, "universal_type": "function", "name": "m0_fdmi_src", "text_snippet": "static struct m0_fdmi_src *src_alloc()\n{\n\tstruct m0_fdmi_src *src;\n\tint rc;\n\n\trc = m"}, {"node_id": 551, "universal_type": "function", "name": "unknown", "text_snippet": "src_alloc()"}, {"node_id": 612, "universal_type": "function", "name": "fdmi_sd_apply_filter_internal", "text_snippet": "static void fdmi_sd_apply_filter_internal(const struct m0_filterc_ops *ops)\n{\n\tstruct m0_fdmi_src "}, {"node_id": 614, "universal_type": "function", "name": "m0_filterc_ops", "text_snippet": "fdmi_sd_apply_filter_internal(const struct m0_filterc_ops *ops)"}, {"node_id": 726, "universal_type": "function", "name": "fdmi_sd_apply_filter", "text_snippet": "void fdmi_sd_apply_filter(void)\n{\n\tM0_ENTRY();\n\tfdmi_sd_apply_filter_internal(&filterc_apply_flt_ops"}, {"node_id": 728, "universal_type": "function", "name": "unknown", "text_snippet": "fdmi_sd_apply_filter(void)"}], "class_declarations": [{"node_id": 26, "universal_type": "class", "name": "m0_semaphore", "text_snippet": "struct m0_semaphore"}, {"node_id": 27, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 38, "universal_type": "class", "name": "m0_fdmi_src_rec", "text_snippet": "struct m0_fdmi_src_rec"}, {"node_id": 39, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 43, "universal_type": "class", "name": "m0_conf_fdmi_filter", "text_snippet": "struct m0_conf_fdmi_filter"}, {"node_id": 44, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 58, "universal_type": "class", "name": "m0_filterc_ctx", "text_snippet": "struct m0_filterc_ctx"}, {"node_id": 59, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 65, "universal_type": "class", "name": "m0_reqh", "text_snippet": "struct m0_reqh"}, {"node_id": 66, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 77, "universal_type": "class", "name": "m0_filterc_ctx", "text_snippet": "struct m0_filterc_ctx"}, {"node_id": 78, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 89, "universal_type": "class", "name": "m0_filterc_ctx", "text_snippet": "struct m0_filterc_ctx"}, {"node_id": 90, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 101, "universal_type": "class", "name": "m0_filterc_iter", "text_snippet": "struct m0_filterc_iter"}, {"node_id": 102, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 113, "universal_type": "class", "name": "m0_filterc_iter", "text_snippet": "struct m0_filterc_iter"}, {"node_id": 114, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 120, "universal_type": "class", "name": "m0_conf_fdmi_filter", "text_snippet": "struct m0_conf_fdmi_filter"}, {"node_id": 121, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 134, "universal_type": "class", "name": "m0_filterc_iter", "text_snippet": "struct m0_filterc_iter"}, {"node_id": 135, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 141, "universal_type": "class", "name": "m0_filterc_ops", "text_snippet": "struct m0_filterc_ops"}, {"node_id": 142, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 179, "universal_type": "class", "name": "m0_filterc_ctx", "text_snippet": "struct m0_filterc_ctx"}, {"node_id": 180, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 186, "universal_type": "class", "name": "m0_reqh", "text_snippet": "struct m0_reqh"}, {"node_id": 187, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 200, "universal_type": "class", "name": "m0_filterc_ctx", "text_snippet": "struct m0_filterc_ctx"}, {"node_id": 201, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 212, "universal_type": "class", "name": "m0_filterc_ctx", "text_snippet": "struct m0_filterc_ctx"}, {"node_id": 213, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 224, "universal_type": "class", "name": "m0_filterc_iter", "text_snippet": "struct m0_filterc_iter"}, {"node_id": 225, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 238, "universal_type": "class", "name": "m0_filterc_iter", "text_snippet": "struct m0_filterc_iter"}, {"node_id": 239, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 245, "universal_type": "class", "name": "m0_conf_fdmi_filter", "text_snippet": "struct m0_conf_fdmi_filter"}, {"node_id": 246, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 263, "universal_type": "class", "name": "m0_fdmi_filter", "text_snippet": "struct m0_fdmi_filter"}, {"node_id": 264, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 276, "universal_type": "class", "name": "m0_fdmi_flt_node", "text_snippet": "struct m0_fdmi_flt_node"}, {"node_id": 277, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 283, "universal_type": "class", "name": "m0_buf", "text_snippet": "struct m0_buf"}, {"node_id": 284, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 354, "universal_type": "class", "name": "m0_filterc_iter", "text_snippet": "struct m0_filterc_iter"}, {"node_id": 355, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 373, "universal_type": "class", "name": "m0_fdmi_src_rec", "text_snippet": "struct m0_fdmi_src_rec"}, {"node_id": 374, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 380, "universal_type": "class", "name": "m0_fdmi_flt_var_node", "text_snippet": "struct m0_fdmi_flt_var_node"}, {"node_id": 381, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 387, "universal_type": "class", "name": "m0_fdmi_flt_operand", "text_snippet": "struct m0_fdmi_flt_operand"}, {"node_id": 388, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 449, "universal_type": "class", "name": "m0_fdmi_src_rec", "text_snippet": "struct m0_fdmi_src_rec"}, {"node_id": 450, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 456, "universal_type": "class", "name": "m0_buf", "text_snippet": "struct m0_buf"}, {"node_id": 457, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 474, "universal_type": "class", "name": "m0_fdmi_src_rec", "text_snippet": "struct m0_fdmi_src_rec"}, {"node_id": 475, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 490, "universal_type": "class", "name": "m0_fdmi_src_rec", "text_snippet": "struct m0_fdmi_src_rec"}, {"node_id": 491, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 518, "universal_type": "class", "name": "m0_fdmi_src_rec", "text_snippet": "struct m0_fdmi_src_rec"}, {"node_id": 519, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 546, "universal_type": "class", "name": "m0_fdmi_src", "text_snippet": "struct m0_fdmi_src"}, {"node_id": 547, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 555, "universal_type": "class", "name": "m0_fdmi_src", "text_snippet": "struct m0_fdmi_src"}, {"node_id": 556, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 618, "universal_type": "class", "name": "m0_filterc_ops", "text_snippet": "struct m0_filterc_ops"}, {"node_id": 619, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 625, "universal_type": "class", "name": "m0_fdmi_src", "text_snippet": "struct m0_fdmi_src"}, {"node_id": 626, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 683, "universal_type": "class", "name": "m0_fdmi_src_rec", "text_snippet": "struct m0_fdmi_src_rec"}, {"node_id": 684, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": [{"node_id": 4, "text": "#include \"lib/trace.h\"\n"}, {"node_id": 5, "text": "#include"}, {"node_id": 7, "text": "#include \"lib/memory.h\"\n"}, {"node_id": 8, "text": "#include"}, {"node_id": 10, "text": "#include \"ut/ut.h\"\n"}, {"node_id": 11, "text": "#include"}, {"node_id": 13, "text": "#include \"fdmi/fdmi.h\"\n"}, {"node_id": 14, "text": "#include"}, {"node_id": 16, "text": "#include \"fdmi/service.h\" /* m0_reqh_fdmi_service */\n"}, {"node_id": 17, "text": "#include"}, {"node_id": 19, "text": "#include \"fdmi/source_dock_internal.h\"\n"}, {"node_id": 20, "text": "#include"}, {"node_id": 22, "text": "#include \"fdmi/ut/sd_common.h\"\n"}, {"node_id": 23, "text": "#include"}]}, "original_source_code": "/* -*- C -*- */\n/*\n * Copyright (c) 2017-2020 Seagate Technology LLC and/or its Affiliates\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n * For any questions about this software or licensing,\n * please email <EMAIL> or <EMAIL>.\n *\n */\n\n\n#define M0_TRACE_SUBSYSTEM M0_TRACE_SUBSYS_FDMI\n#include \"lib/trace.h\"\n\n#include \"lib/memory.h\"\n#include \"ut/ut.h\"\n#include \"fdmi/fdmi.h\"\n#include \"fdmi/service.h\" /* m0_reqh_fdmi_service */\n#include \"fdmi/source_dock_internal.h\"\n\n#include \"fdmi/ut/sd_common.h\"\n\nstatic struct m0_semaphore g_sem;\nstatic char g_fdmi_data[] = \"hello, FDMI\";\nstatic struct m0_fdmi_src_rec g_src_rec;\n\n/*********** FilterC stub ***********/\n\nstatic struct m0_conf_fdmi_filter g_conf_filter;\nstatic char *g_var_str;\n\nstatic int filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n\t\t\t\t struct m0_reqh *reqh);\n\nstatic void filterc_apply_flt_stop(struct m0_filterc_ctx *ctx);\n\nstatic int filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n\t\t\t\t enum m0_fdmi_rec_type_id rec_type_id,\n\t\t\t\t struct m0_filterc_iter *iter);\n\nstatic int filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n\t\t\t\t struct m0_conf_fdmi_filter **out);\n\nstatic void filterc_apply_flt_close(struct m0_filterc_iter *iter);\n\nconst struct m0_filterc_ops filterc_apply_flt_ops = {\n\t.fco_start = filterc_apply_flt_start,\n\t.fco_stop = filterc_apply_flt_stop,\n\t.fco_open = filterc_apply_flt_open,\n\t.fco_get_next = filterc_apply_flt_get_next,\n\t.fco_close = filterc_apply_flt_close\n};\n\nstatic int filterc_apply_flt_start(struct m0_filterc_ctx *ctx,\n\t\t\t\t struct m0_reqh *reqh)\n{\n\treturn 0;\n}\n\nstatic void filterc_apply_flt_stop(struct m0_filterc_ctx *ctx)\n{\n}\n\nstatic int filterc_apply_flt_open(struct m0_filterc_ctx *ctx,\n\t\t\t\t enum m0_fdmi_rec_type_id rec_type_id,\n\t\t\t\t struct m0_filterc_iter *iter)\n{\n\treturn 0;\n}\n\nstatic int filterc_apply_flt_get_next(struct m0_filterc_iter *iter,\n\t\t\t\t struct m0_conf_fdmi_filter **out)\n{\n\tint rc;\n\tstatic bool first_filter = true;\n\tstruct m0_fdmi_filter *flt = &g_conf_filter.ff_filter;\n\tstruct m0_fdmi_flt_node *root;\n\tstruct m0_buf var = M0_BUF_INITS(g_var_str);\n\n\tif (first_filter) {\n\t\troot = m0_fdmi_flt_op_node_create(\n\t\t M0_FFO_OR,\n\t\t\t m0_fdmi_flt_bool_node_create(false),\n\t\t\t m0_fdmi_flt_var_node_create(&var));\n\n\t\tm0_fdmi_filter_init(flt);\n\n\t\tm0_fdmi_filter_root_set(flt, root);\n\n\t\t*out = &g_conf_filter;\n\t\trc = 1;\n\t\tfirst_filter = false;\n\t} else {\n\t\t*out = NULL;\n\t\trc = 0;\n\t}\n\treturn rc;\n}\n\nstatic void filterc_apply_flt_close(struct m0_filterc_iter *iter)\n{\n\tm0_fdmi_filter_fini(&g_conf_filter.ff_filter);\n}\n\n/*********** Source definition ***********/\nstatic int test_fs_node_eval(\n\t\tstruct m0_fdmi_src_rec *src_rec,\n\t\tstruct m0_fdmi_flt_var_node *value_desc,\n\t\tstruct m0_fdmi_flt_operand *value)\n{\n\tM0_UT_ASSERT(src_rec == &g_src_rec);\n\tM0_UT_ASSERT(src_rec->fsr_data == &g_fdmi_data);\n\tM0_UT_ASSERT(value_desc->ffvn_data.b_nob == strlen(g_var_str));\n\tM0_UT_ASSERT(value_desc->ffvn_data.b_addr == g_var_str);\n\n\tm0_fdmi_flt_bool_opnd_fill(value, false);\n\treturn 0;\n}\n\nstatic int test_fs_encode(struct m0_fdmi_src_rec *src_rec,\n\t\t\t struct m0_buf *buf)\n{\n\tM0_UT_ASSERT(false);\n\treturn 0;\n}\n\n\nstatic void test_fs_get(struct m0_fdmi_src_rec *src_rec)\n{\n\tM0_UT_ASSERT(false);\n}\n\nstatic void test_fs_put(struct m0_fdmi_src_rec *src_rec)\n{\n\tM0_UT_ASSERT(src_rec != NULL);\n\tM0_UT_ASSERT(src_rec == &g_src_rec);\n}\n\nstatic void test_fs_end(struct m0_fdmi_src_rec *src_rec)\n{\n\tM0_UT_ASSERT(src_rec != NULL);\n\tM0_UT_ASSERT(src_rec == &g_src_rec);\n\t/* Calling of this function is a sign for fdmi_sd_post_record UT\n\t * that FDMI finished record processing */\n\tm0_semaphore_up(&g_sem);\n}\n\nstatic struct m0_fdmi_src *src_alloc()\n{\n\tstruct m0_fdmi_src *src;\n\tint rc;\n\n\trc = m0_fdmi_source_alloc(M0_FDMI_REC_TYPE_TEST, &src);\n\tM0_UT_ASSERT(rc == 0);\n\n\tsrc->fs_node_eval = test_fs_node_eval;\n\tsrc->fs_get = test_fs_get;\n\tsrc->fs_put = test_fs_put;\n\tsrc->fs_end = test_fs_end;\n\tsrc->fs_encode = test_fs_encode;\n\treturn src;\n}\n\nstatic void fdmi_sd_apply_filter_internal(const struct m0_filterc_ops *ops)\n{\n\tstruct m0_fdmi_src *src = src_alloc();\n\tint rc;\n\n\tM0_ENTRY();\n\n\tg_var_str = strdup(\"test\");\n\tM0_SET0(&g_conf_filter);\n\n\tfdmi_serv_start_ut(ops);\n\tm0_semaphore_init(&g_sem, 0);\n\trc = m0_fdmi_source_register(src);\n\tM0_UT_ASSERT(rc == 0);\n\tg_src_rec = (struct m0_fdmi_src_rec) {\n\t\t.fsr_src = src,\n\t\t.fsr_data = g_fdmi_data,\n\t};\n\tM0_FDMI_SOURCE_POST_RECORD(&g_src_rec);\n\t/* Wait until record is processed and released */\n\tm0_semaphore_down(&g_sem);\n\tm0_fdmi_source_deregister(src);\n\tm0_fdmi_source_free(src);\n\tm0_semaphore_fini(&g_sem);\n\tfdmi_serv_stop_ut();\n\tM0_LEAVE();\n}\n\nvoid fdmi_sd_apply_filter(void)\n{\n\tM0_ENTRY();\n\tfdmi_sd_apply_filter_internal(&filterc_apply_flt_ops);\n\tM0_LEAVE();\n}\n\n#undef M0_TRACE_SUBSYSTEM\n\n/*\n * Local variables:\n * c-indentation-style: \"K&R\"\n * c-basic-offset: 8\n * tab-width: 8\n * fill-column: 80\n * scroll-step: 1\n * End:\n */\n/*\n * vim: tabstop=8 shiftwidth=8 noexpandtab textwidth=80 nowrap\n */\n"}
80,538
c
/* * Copyright (C) 2020 <NAME> * * This program is free software. You can use and redistribute it * under the terms and conditions of the MIT License (see LICENCE). */ #pragma once #ifndef _AGSIMVEC2_H #define _AGSIMVEC2_H #include "plugin/agsplugin.h" #include "imgui/imgui.h" struct AgsImVec2 : ImVec2 { public : int id; AgsImVec2(float _x, float _y) : ImVec2(_x,_y){ id = -1; } AgsImVec2(float _x, float _y, int _id) : ImVec2(_x,_y){ id = _id; } float Length() ; float SquaredLength(); AgsImVec2* Scale(float scale) ; AgsImVec2 *Add(AgsImVec2 *agsImVec2); AgsImVec2 *Sub(AgsImVec2 *agsImVec2); }; //------------------------------------------------------------------------------ // AGS interface instances class AgsImVec2Interface : public IAGSScriptManagedObject { public: static const char* name; AgsImVec2Interface() {}; virtual int Dispose(const char* address, bool force); virtual const char* GetType() { return (name); } virtual int Serialize(const char* address, char* buffer, int bufsize); }; //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - class AgsImVec2Reader : public IAGSManagedObjectReader { public: AgsImVec2Reader() {} virtual void Unserialize(int key, const char* serializedData, int dataSize); }; //------------------------------------------------------------------------------ extern AgsImVec2Interface AgsImVec2_Interface; extern AgsImVec2Reader AgsImVec2_Reader; //------------------------------------------------------------------------------ #endif /* _AGSIMVEC2_H */ //............
31.08
52
(translation_unit) "/*\n * Copyright (C) 2020 <NAME>\n *\n * This program is free software. You can use and redistribute it\n * under the terms and conditions of the MIT License (see LICENCE).\n */\n\n#pragma once\n\n#ifndef _AGSIMVEC2_H\n#define _AGSIMVEC2_H\n\n#include "plugin/agsplugin.h"\n#include "imgui/imgui.h"\n\nstruct AgsImVec2 : ImVec2 {\n public :\n int id;\n AgsImVec2(float _x, float _y)\n : ImVec2(_x,_y){\n id = -1;\n }\n\n AgsImVec2(float _x, float _y, int _id)\n : ImVec2(_x,_y){\n id = _id;\n }\n float Length() ;\n float SquaredLength();\n AgsImVec2* Scale(float scale) ;\n\n AgsImVec2 *Add(AgsImVec2 *agsImVec2);\n\n AgsImVec2 *Sub(AgsImVec2 *agsImVec2);\n};\n\n//------------------------------------------------------------------------------\n// AGS interface instances\n\nclass AgsImVec2Interface : public IAGSScriptManagedObject\n{\npublic:\n static const char* name;\n\n AgsImVec2Interface() {};\n\n virtual int Dispose(const char* address, bool force);\n virtual const char* GetType() { return (name); }\n virtual int Serialize(const char* address, char* buffer, int bufsize);\n\n};\n\n//- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \n\nclass AgsImVec2Reader : public IAGSManagedObjectReader\n{\npublic:\n\n AgsImVec2Reader() {}\n\n virtual void Unserialize(int key, const char* serializedData, int dataSize);\n\n};\n\n//------------------------------------------------------------------------------\n\nextern AgsImVec2Interface AgsImVec2_Interface;\nextern AgsImVec2Reader AgsImVec2_Reader;\n\n//------------------------------------------------------------------------------\n\n#endif /* _AGSIMVEC2_H */\n\n//............\n" (comment) "/*\n * Copyright (C) 2020 <NAME>\n *\n * This program is free software. You can use and redistribute it\n * under the terms and conditions of the MIT License (see LICENCE).\n */" (preproc_call) "#pragma once\n" (preproc_directive) "#pragma" (preproc_arg) "once" (preproc_ifdef) "#ifndef _AGSIMVEC2_H\n#define _AGSIMVEC2_H\n\n#include "plugin/agsplugin.h"\n#include "imgui/imgui.h"\n\nstruct AgsImVec2 : ImVec2 {\n public :\n int id;\n AgsImVec2(float _x, float _y)\n : ImVec2(_x,_y){\n id = -1;\n }\n\n AgsImVec2(float _x, float _y, int _id)\n : ImVec2(_x,_y){\n id = _id;\n }\n float Length() ;\n float SquaredLength();\n AgsImVec2* Scale(float scale) ;\n\n AgsImVec2 *Add(AgsImVec2 *agsImVec2);\n\n AgsImVec2 *Sub(AgsImVec2 *agsImVec2);\n};\n\n//------------------------------------------------------------------------------\n// AGS interface instances\n\nclass AgsImVec2Interface : public IAGSScriptManagedObject\n{\npublic:\n static const char* name;\n\n AgsImVec2Interface() {};\n\n virtual int Dispose(const char* address, bool force);\n virtual const char* GetType() { return (name); }\n virtual int Serialize(const char* address, char* buffer, int bufsize);\n\n};\n\n//- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \n\nclass AgsImVec2Reader : public IAGSManagedObjectReader\n{\npublic:\n\n AgsImVec2Reader() {}\n\n virtual void Unserialize(int key, const char* serializedData, int dataSize);\n\n};\n\n//------------------------------------------------------------------------------\n\nextern AgsImVec2Interface AgsImVec2_Interface;\nextern AgsImVec2Reader AgsImVec2_Reader;\n\n//------------------------------------------------------------------------------\n\n#endif" (#ifndef) "#ifndef" (identifier) "_AGSIMVEC2_H" (preproc_def) "#define _AGSIMVEC2_H\n" (#define) "#define" (identifier) "_AGSIMVEC2_H" (preproc_include) "#include "plugin/agsplugin.h"\n" (#include) "#include" (string_literal) ""plugin/agsplugin.h"" (") """ (string_content) "plugin/agsplugin.h" (") """ (preproc_include) "#include "imgui/imgui.h"\n" (#include) "#include" (string_literal) ""imgui/imgui.h"" (") """ (string_content) "imgui/imgui.h" (") """ (function_definition) "struct AgsImVec2 : ImVec2 {\n public :\n int id;\n AgsImVec2(float _x, float _y)\n : ImVec2(_x,_y){\n id = -1;\n }" (struct_specifier) "struct AgsImVec2" (struct) "struct" (type_identifier) "AgsImVec2" (ERROR) ":" (:) ":" (identifier) "ImVec2" (compound_statement) "{\n public :\n int id;\n AgsImVec2(float _x, float _y)\n : ImVec2(_x,_y){\n id = -1;\n }" ({) "{" (labeled_statement) "public :\n int id;" (statement_identifier) "public" (:) ":" (declaration) "int id;" (primitive_type) "int" (identifier) "id" (;) ";" (declaration) "AgsImVec2(float _x, float _y)\n : ImVec2(_x,_y){\n id = -1;" (macro_type_specifier) "AgsImVec2(float" (identifier) "AgsImVec2" (() "(" (type_descriptor) "float" (primitive_type) "float" ()) "" (identifier) "_x" (,) "," (ERROR) "float _y)\n : ImVec2(_x,_y){" (identifier) "float" (identifier) "_y" ()) ")" (:) ":" (function_declarator) "ImVec2(_x,_y)" (identifier) "ImVec2" (parameter_list) "(_x,_y)" (() "(" (parameter_declaration) "_x" (type_identifier) "_x" (,) "," (parameter_declaration) "_y" (type_identifier) "_y" ()) ")" ({) "{" (init_declarator) "id = -1" (identifier) "id" (=) "=" (number_literal) "-1" (;) ";" (}) "}" (declaration) "AgsImVec2(float _x, float _y, int _id)\n : ImVec2(_x,_y){\n id = _id;" (macro_type_specifier) "AgsImVec2(float" (identifier) "AgsImVec2" (() "(" (type_descriptor) "float" (primitive_type) "float" ()) "" (identifier) "_x" (,) "," (identifier) "float" (ERROR) "_y" (identifier) "_y" (,) "," (ERROR) "int _id)\n : ImVec2(_x,_y){" (identifier) "int" (identifier) "_id" ()) ")" (:) ":" (function_declarator) "ImVec2(_x,_y)" (identifier) "ImVec2" (parameter_list) "(_x,_y)" (() "(" (parameter_declaration) "_x" (type_identifier) "_x" (,) "," (parameter_declaration) "_y" (type_identifier) "_y" ()) ")" ({) "{" (init_declarator) "id = _id" (identifier) "id" (=) "=" (identifier) "_id" (;) ";" (ERROR) "}" (}) "}" (declaration) "float Length() ;" (primitive_type) "float" (function_declarator) "Length()" (identifier) "Length" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "float SquaredLength();" (primitive_type) "float" (function_declarator) "SquaredLength()" (identifier) "SquaredLength" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "AgsImVec2* Scale(float scale) ;" (type_identifier) "AgsImVec2" (pointer_declarator) "* Scale(float scale)" (*) "*" (function_declarator) "Scale(float scale)" (identifier) "Scale" (parameter_list) "(float scale)" (() "(" (parameter_declaration) "float scale" (primitive_type) "float" (identifier) "scale" ()) ")" (;) ";" (declaration) "AgsImVec2 *Add(AgsImVec2 *agsImVec2);" (type_identifier) "AgsImVec2" (pointer_declarator) "*Add(AgsImVec2 *agsImVec2)" (*) "*" (function_declarator) "Add(AgsImVec2 *agsImVec2)" (identifier) "Add" (parameter_list) "(AgsImVec2 *agsImVec2)" (() "(" (parameter_declaration) "AgsImVec2 *agsImVec2" (type_identifier) "AgsImVec2" (pointer_declarator) "*agsImVec2" (*) "*" (identifier) "agsImVec2" ()) ")" (;) ";" (declaration) "AgsImVec2 *Sub(AgsImVec2 *agsImVec2);" (type_identifier) "AgsImVec2" (pointer_declarator) "*Sub(AgsImVec2 *agsImVec2)" (*) "*" (function_declarator) "Sub(AgsImVec2 *agsImVec2)" (identifier) "Sub" (parameter_list) "(AgsImVec2 *agsImVec2)" (() "(" (parameter_declaration) "AgsImVec2 *agsImVec2" (type_identifier) "AgsImVec2" (pointer_declarator) "*agsImVec2" (*) "*" (identifier) "agsImVec2" ()) ")" (;) ";" (ERROR) "}" (}) "}" (expression_statement) ";" (;) ";" (comment) "//------------------------------------------------------------------------------" (comment) "// AGS interface instances" (function_definition) "class AgsImVec2Interface : public IAGSScriptManagedObject\n{\npublic:\n static const char* name;\n\n AgsImVec2Interface() {};\n\n virtual int Dispose(const char* address, bool force);\n virtual const char* GetType() { return (name); }\n virtual int Serialize(const char* address, char* buffer, int bufsize);\n\n}" (type_identifier) "class" (ERROR) "AgsImVec2Interface : public" (identifier) "AgsImVec2Interface" (:) ":" (identifier) "public" (identifier) "IAGSScriptManagedObject" (compound_statement) "{\npublic:\n static const char* name;\n\n AgsImVec2Interface() {};\n\n virtual int Dispose(const char* address, bool force);\n virtual const char* GetType() { return (name); }\n virtual int Serialize(const char* address, char* buffer, int bufsize);\n\n}" ({) "{" (labeled_statement) "public:\n static const char* name;" (statement_identifier) "public" (:) ":" (declaration) "static const char* name;" (storage_class_specifier) "static" (static) "static" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "* name" (*) "*" (identifier) "name" (;) ";" (expression_statement) "AgsImVec2Interface()" (call_expression) "AgsImVec2Interface()" (identifier) "AgsImVec2Interface" (argument_list) "()" (() "(" ()) ")" (;) "" (compound_statement) "{}" ({) "{" (}) "}" (expression_statement) ";" (;) ";" (declaration) "virtual int Dispose(const char* address, bool force);" (type_identifier) "virtual" (ERROR) "int" (identifier) "int" (function_declarator) "Dispose(const char* address, bool force)" (identifier) "Dispose" (parameter_list) "(const char* address, bool force)" (() "(" (parameter_declaration) "const char* address" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "* address" (*) "*" (identifier) "address" (,) "," (parameter_declaration) "bool force" (primitive_type) "bool" (identifier) "force" ()) ")" (;) ";" (function_definition) "virtual const char* GetType() { return (name); }" (type_identifier) "virtual" (type_qualifier) "const" (const) "const" (ERROR) "char" (identifier) "char" (pointer_declarator) "* GetType()" (*) "*" (function_declarator) "GetType()" (identifier) "GetType" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{ return (name); }" ({) "{" (return_statement) "return (name);" (return) "return" (parenthesized_expression) "(name)" (() "(" (identifier) "name" ()) ")" (;) ";" (}) "}" (declaration) "virtual int Serialize(const char* address, char* buffer, int bufsize);" (type_identifier) "virtual" (ERROR) "int" (identifier) "int" (function_declarator) "Serialize(const char* address, char* buffer, int bufsize)" (identifier) "Serialize" (parameter_list) "(const char* address, char* buffer, int bufsize)" (() "(" (parameter_declaration) "const char* address" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "* address" (*) "*" (identifier) "address" (,) "," (parameter_declaration) "char* buffer" (primitive_type) "char" (pointer_declarator) "* buffer" (*) "*" (identifier) "buffer" (,) "," (parameter_declaration) "int bufsize" (primitive_type) "int" (identifier) "bufsize" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (comment) "//- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - " (function_definition) "class AgsImVec2Reader : public IAGSManagedObjectReader\n{\npublic:\n\n AgsImVec2Reader() {}\n\n virtual void Unserialize(int key, const char* serializedData, int dataSize);\n\n}" (type_identifier) "class" (ERROR) "AgsImVec2Reader : public" (identifier) "AgsImVec2Reader" (:) ":" (identifier) "public" (identifier) "IAGSManagedObjectReader" (compound_statement) "{\npublic:\n\n AgsImVec2Reader() {}\n\n virtual void Unserialize(int key, const char* serializedData, int dataSize);\n\n}" ({) "{" (labeled_statement) "public:\n\n AgsImVec2Reader()" (statement_identifier) "public" (:) ":" (expression_statement) "AgsImVec2Reader()" (call_expression) "AgsImVec2Reader()" (identifier) "AgsImVec2Reader" (argument_list) "()" (() "(" ()) ")" (;) "" (compound_statement) "{}" ({) "{" (}) "}" (declaration) "virtual void Unserialize(int key, const char* serializedData, int dataSize);" (type_identifier) "virtual" (ERROR) "void" (identifier) "void" (function_declarator) "Unserialize(int key, const char* serializedData, int dataSize)" (identifier) "Unserialize" (parameter_list) "(int key, const char* serializedData, int dataSize)" (() "(" (parameter_declaration) "int key" (primitive_type) "int" (identifier) "key" (,) "," (parameter_declaration) "const char* serializedData" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "* serializedData" (*) "*" (identifier) "serializedData" (,) "," (parameter_declaration) "int dataSize" (primitive_type) "int" (identifier) "dataSize" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (comment) "//------------------------------------------------------------------------------" (declaration) "extern AgsImVec2Interface AgsImVec2_Interface;" (storage_class_specifier) "extern" (extern) "extern" (type_identifier) "AgsImVec2Interface" (identifier) "AgsImVec2_Interface" (;) ";" (declaration) "extern AgsImVec2Reader AgsImVec2_Reader;" (storage_class_specifier) "extern" (extern) "extern" (type_identifier) "AgsImVec2Reader" (identifier) "AgsImVec2_Reader" (;) ";" (comment) "//------------------------------------------------------------------------------" (#endif) "#endif" (comment) "/* _AGSIMVEC2_H */" (comment) "//............"
347
12
{"language": "c", "success": true, "metadata": {"lines": 52, "avg_line_length": 31.08, "nodes": 208, "errors": 0, "source_hash": "0cea5babc2b6196354f923c7c5e0400da4c788b957e07823aaaa598b53df671f", "categorized_nodes": 134}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#pragma once\n", "parent": null, "children": [1, 2], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#pragma", "parent": 0, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "once", "parent": 0, "children": [], "start_point": {"row": 7, "column": 8}, "end_point": {"row": 7, "column": 12}}, {"id": 3, "type": "preproc_ifdef", "text": "#ifndef _AGSIMVEC2_H\n#define _AGSIMVEC2_H\n\n#include \"plugin/agsplugin.h\"\n#include \"imgui/imgui.h\"\n\nstruct AgsImVec2 : ImVec2 {\n public :\n int id;\n AgsImVec2(float _x, float _y)\n : ImVec2(_x,_y){\n id = -1;\n }\n\n AgsImVec2(float _x, float _y, int _id)\n : ImVec2(_x,_y){\n id = _id;\n }\n float Length() ;\n float SquaredLength();\n AgsImVec2* Scale(float scale) ;\n\n AgsImVec2 *Add(AgsImVec2 *agsImVec2);\n\n AgsImVec2 *Sub(AgsImVec2 *agsImVec2);\n};\n\n//------------------------------------------------------------------------------\n// AGS interface instances\n\nclass AgsImVec2Interface : public IAGSScriptManagedObject\n{\npublic:\n static const char* name;\n\n AgsImVec2Interface() {};\n\n virtual int Dispose(const char* address, bool force);\n virtual const char* GetType() { return (name); }\n virtual int Serialize(const char* address, char* buffer, int bufsize);\n\n};\n\n//- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \n\nclass AgsImVec2Reader : public IAGSManagedObjectReader\n{\npublic:\n\n AgsImVec2Reader() {}\n\n virtual void Unserialize(int key, const char* serializedData, int dataSize);\n\n};\n\n//------------------------------------------------------------------------------\n\nextern AgsImVec2Interface AgsImVec2_Interface;\nextern AgsImVec2Reader AgsImVec2_Reader;\n\n//------------------------------------------------------------------------------\n\n#endif", "parent": null, "children": [4, 5, 6, 9, 12, 15, 44, 67, 72, 77, 87, 99, 111, 171, 197, 202, 207], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 71, "column": 6}}, {"id": 4, "type": "#ifndef", "text": "#ifndef", "parent": 3, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 7}}, {"id": 5, "type": "identifier", "text": "_AGSIMVEC2_H", "parent": 3, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 20}}, {"id": 6, "type": "preproc_def", "text": "#define _AGSIMVEC2_H\n", "parent": 3, "children": [7, 8], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 11, "column": 0}}, {"id": 7, "type": "#define", "text": "#define", "parent": 6, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 7}}, {"id": 8, "type": "identifier", "text": "_AGSIMVEC2_H", "parent": 6, "children": [], "start_point": {"row": 10, "column": 8}, "end_point": {"row": 10, "column": 20}}, {"id": 9, "type": "preproc_include", "text": "#include \"plugin/agsplugin.h\"\n", "parent": 3, "children": [10, 11], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 13, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"plugin/agsplugin.h\"", "parent": 9, "children": [], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 29}}, {"id": 12, "type": "preproc_include", "text": "#include \"imgui/imgui.h\"\n", "parent": 3, "children": [13, 14], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 14, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 8}}, {"id": 14, "type": "string_literal", "text": "\"imgui/imgui.h\"", "parent": 12, "children": [], "start_point": {"row": 13, "column": 9}, "end_point": {"row": 13, "column": 24}}, {"id": 15, "type": "function_definition", "text": "struct AgsImVec2 : ImVec2 {\n public :\n int id;\n AgsImVec2(float _x, float _y)\n : ImVec2(_x,_y){\n id = -1;\n }", "parent": 3, "children": [16, 19], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 21, "column": 5}}, {"id": 16, "type": "struct_specifier", "text": "struct AgsImVec2", "parent": 15, "children": [17, 18], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 16}}, {"id": 17, "type": "struct", "text": "struct", "parent": 16, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 6}}, {"id": 18, "type": "type_identifier", "text": "AgsImVec2", "parent": 16, "children": [], "start_point": {"row": 15, "column": 7}, "end_point": {"row": 15, "column": 16}}, {"id": 19, "type": "identifier", "text": "ImVec2", "parent": 15, "children": [], "start_point": {"row": 15, "column": 19}, "end_point": {"row": 15, "column": 25}}, {"id": 20, "type": "labeled_statement", "text": "public :\n int id;", "parent": 15, "children": [21], "start_point": {"row": 16, "column": 4}, "end_point": {"row": 17, "column": 11}}, {"id": 21, "type": "declaration", "text": "int id;", "parent": 20, "children": [22, 23], "start_point": {"row": 17, "column": 4}, "end_point": {"row": 17, "column": 11}}, {"id": 22, "type": "primitive_type", "text": "int", "parent": 21, "children": [], "start_point": {"row": 17, "column": 4}, "end_point": {"row": 17, "column": 7}}, {"id": 23, "type": "identifier", "text": "id", "parent": 21, "children": [], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 17, "column": 10}}, {"id": 24, "type": "declaration", "text": "AgsImVec2(float _x, float _y)\n : ImVec2(_x,_y){\n id = -1;", "parent": 15, "children": [25, 29, 30, 40], "start_point": {"row": 18, "column": 8}, "end_point": {"row": 20, "column": 16}}, {"id": 25, "type": "macro_type_specifier", "text": "AgsImVec2(float", "parent": 24, "children": [26, 27], "start_point": {"row": 18, "column": 8}, "end_point": {"row": 18, "column": 23}}, {"id": 26, "type": "identifier", "text": "AgsImVec2", "parent": 25, "children": [], "start_point": {"row": 18, "column": 8}, "end_point": {"row": 18, "column": 17}}, {"id": 27, "type": "type_descriptor", "text": "float", "parent": 25, "children": [28], "start_point": {"row": 18, "column": 18}, "end_point": {"row": 18, "column": 23}}, {"id": 28, "type": "primitive_type", "text": "float", "parent": 27, "children": [], "start_point": {"row": 18, "column": 18}, "end_point": {"row": 18, "column": 23}}, {"id": 29, "type": "identifier", "text": "_x", "parent": 24, "children": [], "start_point": {"row": 18, "column": 24}, "end_point": {"row": 18, "column": 26}}, {"id": 30, "type": "ERROR", "text": "float _y)\n : ImVec2(_x,_y){", "parent": 24, "children": [31, 32, 33], "start_point": {"row": 18, "column": 28}, "end_point": {"row": 19, "column": 28}}, {"id": 31, "type": "identifier", "text": "float", "parent": 30, "children": [], "start_point": {"row": 18, "column": 28}, "end_point": {"row": 18, "column": 33}}, {"id": 32, "type": "identifier", "text": "_y", "parent": 30, "children": [], "start_point": {"row": 18, "column": 34}, "end_point": {"row": 18, "column": 36}}, {"id": 33, "type": "function_declarator", "text": "ImVec2(_x,_y)", "parent": 30, "children": [34, 35], "start_point": {"row": 19, "column": 14}, "end_point": {"row": 19, "column": 27}}, {"id": 34, "type": "identifier", "text": "ImVec2", "parent": 33, "children": [], "start_point": {"row": 19, "column": 14}, "end_point": {"row": 19, "column": 20}}, {"id": 35, "type": "parameter_list", "text": "(_x,_y)", "parent": 33, "children": [36, 38], "start_point": {"row": 19, "column": 20}, "end_point": {"row": 19, "column": 27}}, {"id": 36, "type": "parameter_declaration", "text": "_x", "parent": 35, "children": [37], "start_point": {"row": 19, "column": 21}, "end_point": {"row": 19, "column": 23}}, {"id": 37, "type": "type_identifier", "text": "_x", "parent": 36, "children": [], "start_point": {"row": 19, "column": 21}, "end_point": {"row": 19, "column": 23}}, {"id": 38, "type": "parameter_declaration", "text": "_y", "parent": 35, "children": [39], "start_point": {"row": 19, "column": 24}, "end_point": {"row": 19, "column": 26}}, {"id": 39, "type": "type_identifier", "text": "_y", "parent": 38, "children": [], "start_point": {"row": 19, "column": 24}, "end_point": {"row": 19, "column": 26}}, {"id": 40, "type": "init_declarator", "text": "id = -1", "parent": 24, "children": [41, 42, 43], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 15}}, {"id": 41, "type": "identifier", "text": "id", "parent": 40, "children": [], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 10}}, {"id": 42, "type": "=", "text": "=", "parent": 40, "children": [], "start_point": {"row": 20, "column": 11}, "end_point": {"row": 20, "column": 12}}, {"id": 43, "type": "number_literal", "text": "-1", "parent": 40, "children": [], "start_point": {"row": 20, "column": 13}, "end_point": {"row": 20, "column": 15}}, {"id": 44, "type": "declaration", "text": "AgsImVec2(float _x, float _y, int _id)\n : ImVec2(_x,_y){\n id = _id;", "parent": 3, "children": [45, 49, 50, 51, 53, 63], "start_point": {"row": 23, "column": 8}, "end_point": {"row": 25, "column": 17}}, {"id": 45, "type": "macro_type_specifier", "text": "AgsImVec2(float", "parent": 44, "children": [46, 47], "start_point": {"row": 23, "column": 8}, "end_point": {"row": 23, "column": 23}}, {"id": 46, "type": "identifier", "text": "AgsImVec2", "parent": 45, "children": [], "start_point": {"row": 23, "column": 8}, "end_point": {"row": 23, "column": 17}}, {"id": 47, "type": "type_descriptor", "text": "float", "parent": 45, "children": [48], "start_point": {"row": 23, "column": 18}, "end_point": {"row": 23, "column": 23}}, {"id": 48, "type": "primitive_type", "text": "float", "parent": 47, "children": [], "start_point": {"row": 23, "column": 18}, "end_point": {"row": 23, "column": 23}}, {"id": 49, "type": "identifier", "text": "_x", "parent": 44, "children": [], "start_point": {"row": 23, "column": 24}, "end_point": {"row": 23, "column": 26}}, {"id": 50, "type": "identifier", "text": "float", "parent": 44, "children": [], "start_point": {"row": 23, "column": 28}, "end_point": {"row": 23, "column": 33}}, {"id": 51, "type": "ERROR", "text": "_y", "parent": 44, "children": [52], "start_point": {"row": 23, "column": 34}, "end_point": {"row": 23, "column": 36}}, {"id": 52, "type": "identifier", "text": "_y", "parent": 51, "children": [], "start_point": {"row": 23, "column": 34}, "end_point": {"row": 23, "column": 36}}, {"id": 53, "type": "ERROR", "text": "int _id)\n : ImVec2(_x,_y){", "parent": 44, "children": [54, 55, 56], "start_point": {"row": 23, "column": 38}, "end_point": {"row": 24, "column": 28}}, {"id": 54, "type": "identifier", "text": "int", "parent": 53, "children": [], "start_point": {"row": 23, "column": 38}, "end_point": {"row": 23, "column": 41}}, {"id": 55, "type": "identifier", "text": "_id", "parent": 53, "children": [], "start_point": {"row": 23, "column": 42}, "end_point": {"row": 23, "column": 45}}, {"id": 56, "type": "function_declarator", "text": "ImVec2(_x,_y)", "parent": 53, "children": [57, 58], "start_point": {"row": 24, "column": 14}, "end_point": {"row": 24, "column": 27}}, {"id": 57, "type": "identifier", "text": "ImVec2", "parent": 56, "children": [], "start_point": {"row": 24, "column": 14}, "end_point": {"row": 24, "column": 20}}, {"id": 58, "type": "parameter_list", "text": "(_x,_y)", "parent": 56, "children": [59, 61], "start_point": {"row": 24, "column": 20}, "end_point": {"row": 24, "column": 27}}, {"id": 59, "type": "parameter_declaration", "text": "_x", "parent": 58, "children": [60], "start_point": {"row": 24, "column": 21}, "end_point": {"row": 24, "column": 23}}, {"id": 60, "type": "type_identifier", "text": "_x", "parent": 59, "children": [], "start_point": {"row": 24, "column": 21}, "end_point": {"row": 24, "column": 23}}, {"id": 61, "type": "parameter_declaration", "text": "_y", "parent": 58, "children": [62], "start_point": {"row": 24, "column": 24}, "end_point": {"row": 24, "column": 26}}, {"id": 62, "type": "type_identifier", "text": "_y", "parent": 61, "children": [], "start_point": {"row": 24, "column": 24}, "end_point": {"row": 24, "column": 26}}, {"id": 63, "type": "init_declarator", "text": "id = _id", "parent": 44, "children": [64, 65, 66], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 16}}, {"id": 64, "type": "identifier", "text": "id", "parent": 63, "children": [], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 10}}, {"id": 65, "type": "=", "text": "=", "parent": 63, "children": [], "start_point": {"row": 25, "column": 11}, "end_point": {"row": 25, "column": 12}}, {"id": 66, "type": "identifier", "text": "_id", "parent": 63, "children": [], "start_point": {"row": 25, "column": 13}, "end_point": {"row": 25, "column": 16}}, {"id": 67, "type": "declaration", "text": "float Length() ;", "parent": 3, "children": [68, 69], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 20}}, {"id": 68, "type": "primitive_type", "text": "float", "parent": 67, "children": [], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 9}}, {"id": 69, "type": "function_declarator", "text": "Length()", "parent": 67, "children": [70, 71], "start_point": {"row": 27, "column": 10}, "end_point": {"row": 27, "column": 18}}, {"id": 70, "type": "identifier", "text": "Length", "parent": 69, "children": [], "start_point": {"row": 27, "column": 10}, "end_point": {"row": 27, "column": 16}}, {"id": 71, "type": "parameter_list", "text": "()", "parent": 69, "children": [], "start_point": {"row": 27, "column": 16}, "end_point": {"row": 27, "column": 18}}, {"id": 72, "type": "declaration", "text": "float SquaredLength();", "parent": 3, "children": [73, 74], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 28, "column": 26}}, {"id": 73, "type": "primitive_type", "text": "float", "parent": 72, "children": [], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 28, "column": 9}}, {"id": 74, "type": "function_declarator", "text": "SquaredLength()", "parent": 72, "children": [75, 76], "start_point": {"row": 28, "column": 10}, "end_point": {"row": 28, "column": 25}}, {"id": 75, "type": "identifier", "text": "SquaredLength", "parent": 74, "children": [], "start_point": {"row": 28, "column": 10}, "end_point": {"row": 28, "column": 23}}, {"id": 76, "type": "parameter_list", "text": "()", "parent": 74, "children": [], "start_point": {"row": 28, "column": 23}, "end_point": {"row": 28, "column": 25}}, {"id": 77, "type": "declaration", "text": "AgsImVec2* Scale(float scale) ;", "parent": 3, "children": [78, 79], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 35}}, {"id": 78, "type": "type_identifier", "text": "AgsImVec2", "parent": 77, "children": [], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 13}}, {"id": 79, "type": "pointer_declarator", "text": "* Scale(float scale)", "parent": 77, "children": [80, 81], "start_point": {"row": 29, "column": 13}, "end_point": {"row": 29, "column": 33}}, {"id": 80, "type": "*", "text": "*", "parent": 79, "children": [], "start_point": {"row": 29, "column": 13}, "end_point": {"row": 29, "column": 14}}, {"id": 81, "type": "function_declarator", "text": "Scale(float scale)", "parent": 79, "children": [82, 83], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 33}}, {"id": 82, "type": "identifier", "text": "Scale", "parent": 81, "children": [], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 20}}, {"id": 83, "type": "parameter_list", "text": "(float scale)", "parent": 81, "children": [84], "start_point": {"row": 29, "column": 20}, "end_point": {"row": 29, "column": 33}}, {"id": 84, "type": "parameter_declaration", "text": "float scale", "parent": 83, "children": [85, 86], "start_point": {"row": 29, "column": 21}, "end_point": {"row": 29, "column": 32}}, {"id": 85, "type": "primitive_type", "text": "float", "parent": 84, "children": [], "start_point": {"row": 29, "column": 21}, "end_point": {"row": 29, "column": 26}}, {"id": 86, "type": "identifier", "text": "scale", "parent": 84, "children": [], "start_point": {"row": 29, "column": 27}, "end_point": {"row": 29, "column": 32}}, {"id": 87, "type": "declaration", "text": "AgsImVec2 *Add(AgsImVec2 *agsImVec2);", "parent": 3, "children": [88, 89], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 41}}, {"id": 88, "type": "type_identifier", "text": "AgsImVec2", "parent": 87, "children": [], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 13}}, {"id": 89, "type": "pointer_declarator", "text": "*Add(AgsImVec2 *agsImVec2)", "parent": 87, "children": [90, 91], "start_point": {"row": 31, "column": 14}, "end_point": {"row": 31, "column": 40}}, {"id": 90, "type": "*", "text": "*", "parent": 89, "children": [], "start_point": {"row": 31, "column": 14}, "end_point": {"row": 31, "column": 15}}, {"id": 91, "type": "function_declarator", "text": "Add(AgsImVec2 *agsImVec2)", "parent": 89, "children": [92, 93], "start_point": {"row": 31, "column": 15}, "end_point": {"row": 31, "column": 40}}, {"id": 92, "type": "identifier", "text": "Add", "parent": 91, "children": [], "start_point": {"row": 31, "column": 15}, "end_point": {"row": 31, "column": 18}}, {"id": 93, "type": "parameter_list", "text": "(AgsImVec2 *agsImVec2)", "parent": 91, "children": [94], "start_point": {"row": 31, "column": 18}, "end_point": {"row": 31, "column": 40}}, {"id": 94, "type": "parameter_declaration", "text": "AgsImVec2 *agsImVec2", "parent": 93, "children": [95, 96], "start_point": {"row": 31, "column": 19}, "end_point": {"row": 31, "column": 39}}, {"id": 95, "type": "type_identifier", "text": "AgsImVec2", "parent": 94, "children": [], "start_point": {"row": 31, "column": 19}, "end_point": {"row": 31, "column": 28}}, {"id": 96, "type": "pointer_declarator", "text": "*agsImVec2", "parent": 94, "children": [97, 98], "start_point": {"row": 31, "column": 29}, "end_point": {"row": 31, "column": 39}}, {"id": 97, "type": "*", "text": "*", "parent": 96, "children": [], "start_point": {"row": 31, "column": 29}, "end_point": {"row": 31, "column": 30}}, {"id": 98, "type": "identifier", "text": "agsImVec2", "parent": 96, "children": [], "start_point": {"row": 31, "column": 30}, "end_point": {"row": 31, "column": 39}}, {"id": 99, "type": "declaration", "text": "AgsImVec2 *Sub(AgsImVec2 *agsImVec2);", "parent": 3, "children": [100, 101], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 41}}, {"id": 100, "type": "type_identifier", "text": "AgsImVec2", "parent": 99, "children": [], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 13}}, {"id": 101, "type": "pointer_declarator", "text": "*Sub(AgsImVec2 *agsImVec2)", "parent": 99, "children": [102, 103], "start_point": {"row": 33, "column": 14}, "end_point": {"row": 33, "column": 40}}, {"id": 102, "type": "*", "text": "*", "parent": 101, "children": [], "start_point": {"row": 33, "column": 14}, "end_point": {"row": 33, "column": 15}}, {"id": 103, "type": "function_declarator", "text": "Sub(AgsImVec2 *agsImVec2)", "parent": 101, "children": [104, 105], "start_point": {"row": 33, "column": 15}, "end_point": {"row": 33, "column": 40}}, {"id": 104, "type": "identifier", "text": "Sub", "parent": 103, "children": [], "start_point": {"row": 33, "column": 15}, "end_point": {"row": 33, "column": 18}}, {"id": 105, "type": "parameter_list", "text": "(AgsImVec2 *agsImVec2)", "parent": 103, "children": [106], "start_point": {"row": 33, "column": 18}, "end_point": {"row": 33, "column": 40}}, {"id": 106, "type": "parameter_declaration", "text": "AgsImVec2 *agsImVec2", "parent": 105, "children": [107, 108], "start_point": {"row": 33, "column": 19}, "end_point": {"row": 33, "column": 39}}, {"id": 107, "type": "type_identifier", "text": "AgsImVec2", "parent": 106, "children": [], "start_point": {"row": 33, "column": 19}, "end_point": {"row": 33, "column": 28}}, {"id": 108, "type": "pointer_declarator", "text": "*agsImVec2", "parent": 106, "children": [109, 110], "start_point": {"row": 33, "column": 29}, "end_point": {"row": 33, "column": 39}}, {"id": 109, "type": "*", "text": "*", "parent": 108, "children": [], "start_point": {"row": 33, "column": 29}, "end_point": {"row": 33, "column": 30}}, {"id": 110, "type": "identifier", "text": "agsImVec2", "parent": 108, "children": [], "start_point": {"row": 33, "column": 30}, "end_point": {"row": 33, "column": 39}}, {"id": 111, "type": "function_definition", "text": "class AgsImVec2Interface : public IAGSScriptManagedObject\n{\npublic:\n static const char* name;\n\n AgsImVec2Interface() {};\n\n virtual int Dispose(const char* address, bool force);\n virtual const char* GetType() { return (name); }\n virtual int Serialize(const char* address, char* buffer, int bufsize);\n\n}", "parent": 3, "children": [112, 114], "start_point": {"row": 39, "column": 0}, "end_point": {"row": 50, "column": 1}}, {"id": 112, "type": "ERROR", "text": "AgsImVec2Interface : public", "parent": 111, "children": [113], "start_point": {"row": 39, "column": 6}, "end_point": {"row": 39, "column": 33}}, {"id": 113, "type": "identifier", "text": "AgsImVec2Interface", "parent": 112, "children": [], "start_point": {"row": 39, "column": 6}, "end_point": {"row": 39, "column": 24}}, {"id": 114, "type": "identifier", "text": "IAGSScriptManagedObject", "parent": 111, "children": [], "start_point": {"row": 39, "column": 34}, "end_point": {"row": 39, "column": 57}}, {"id": 115, "type": "labeled_statement", "text": "public:\n static const char* name;", "parent": 111, "children": [116], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 42, "column": 28}}, {"id": 116, "type": "declaration", "text": "static const char* name;", "parent": 115, "children": [117, 118], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 28}}, {"id": 117, "type": "primitive_type", "text": "char", "parent": 116, "children": [], "start_point": {"row": 42, "column": 17}, "end_point": {"row": 42, "column": 21}}, {"id": 118, "type": "pointer_declarator", "text": "* name", "parent": 116, "children": [119, 120], "start_point": {"row": 42, "column": 21}, "end_point": {"row": 42, "column": 27}}, {"id": 119, "type": "*", "text": "*", "parent": 118, "children": [], "start_point": {"row": 42, "column": 21}, "end_point": {"row": 42, "column": 22}}, {"id": 120, "type": "identifier", "text": "name", "parent": 118, "children": [], "start_point": {"row": 42, "column": 23}, "end_point": {"row": 42, "column": 27}}, {"id": 121, "type": "call_expression", "text": "AgsImVec2Interface()", "parent": 111, "children": [122, 123], "start_point": {"row": 44, "column": 4}, "end_point": {"row": 44, "column": 24}}, {"id": 122, "type": "identifier", "text": "AgsImVec2Interface", "parent": 121, "children": [], "start_point": {"row": 44, "column": 4}, "end_point": {"row": 44, "column": 22}}, {"id": 123, "type": "argument_list", "text": "()", "parent": 121, "children": [], "start_point": {"row": 44, "column": 22}, "end_point": {"row": 44, "column": 24}}, {"id": 124, "type": "declaration", "text": "virtual int Dispose(const char* address, bool force);", "parent": 111, "children": [125, 126, 128], "start_point": {"row": 46, "column": 4}, "end_point": {"row": 46, "column": 57}}, {"id": 125, "type": "type_identifier", "text": "virtual", "parent": 124, "children": [], "start_point": {"row": 46, "column": 4}, "end_point": {"row": 46, "column": 11}}, {"id": 126, "type": "ERROR", "text": "int", "parent": 124, "children": [127], "start_point": {"row": 46, "column": 12}, "end_point": {"row": 46, "column": 15}}, {"id": 127, "type": "identifier", "text": "int", "parent": 126, "children": [], "start_point": {"row": 46, "column": 12}, "end_point": {"row": 46, "column": 15}}, {"id": 128, "type": "function_declarator", "text": "Dispose(const char* address, bool force)", "parent": 124, "children": [129, 130], "start_point": {"row": 46, "column": 16}, "end_point": {"row": 46, "column": 56}}, {"id": 129, "type": "identifier", "text": "Dispose", "parent": 128, "children": [], "start_point": {"row": 46, "column": 16}, "end_point": {"row": 46, "column": 23}}, {"id": 130, "type": "parameter_list", "text": "(const char* address, bool force)", "parent": 128, "children": [131, 136], "start_point": {"row": 46, "column": 23}, "end_point": {"row": 46, "column": 56}}, {"id": 131, "type": "parameter_declaration", "text": "const char* address", "parent": 130, "children": [132, 133], "start_point": {"row": 46, "column": 24}, "end_point": {"row": 46, "column": 43}}, {"id": 132, "type": "primitive_type", "text": "char", "parent": 131, "children": [], "start_point": {"row": 46, "column": 30}, "end_point": {"row": 46, "column": 34}}, {"id": 133, "type": "pointer_declarator", "text": "* address", "parent": 131, "children": [134, 135], "start_point": {"row": 46, "column": 34}, "end_point": {"row": 46, "column": 43}}, {"id": 134, "type": "*", "text": "*", "parent": 133, "children": [], "start_point": {"row": 46, "column": 34}, "end_point": {"row": 46, "column": 35}}, {"id": 135, "type": "identifier", "text": "address", "parent": 133, "children": [], "start_point": {"row": 46, "column": 36}, "end_point": {"row": 46, "column": 43}}, {"id": 136, "type": "parameter_declaration", "text": "bool force", "parent": 130, "children": [137, 138], "start_point": {"row": 46, "column": 45}, "end_point": {"row": 46, "column": 55}}, {"id": 137, "type": "primitive_type", "text": "bool", "parent": 136, "children": [], "start_point": {"row": 46, "column": 45}, "end_point": {"row": 46, "column": 49}}, {"id": 138, "type": "identifier", "text": "force", "parent": 136, "children": [], "start_point": {"row": 46, "column": 50}, "end_point": {"row": 46, "column": 55}}, {"id": 139, "type": "function_definition", "text": "virtual const char* GetType() { return (name); }", "parent": 111, "children": [140, 141, 143], "start_point": {"row": 47, "column": 4}, "end_point": {"row": 47, "column": 52}}, {"id": 140, "type": "type_identifier", "text": "virtual", "parent": 139, "children": [], "start_point": {"row": 47, "column": 4}, "end_point": {"row": 47, "column": 11}}, {"id": 141, "type": "ERROR", "text": "char", "parent": 139, "children": [142], "start_point": {"row": 47, "column": 18}, "end_point": {"row": 47, "column": 22}}, {"id": 142, "type": "identifier", "text": "char", "parent": 141, "children": [], "start_point": {"row": 47, "column": 18}, "end_point": {"row": 47, "column": 22}}, {"id": 143, "type": "pointer_declarator", "text": "* GetType()", "parent": 139, "children": [144, 145], "start_point": {"row": 47, "column": 22}, "end_point": {"row": 47, "column": 33}}, {"id": 144, "type": "*", "text": "*", "parent": 143, "children": [], "start_point": {"row": 47, "column": 22}, "end_point": {"row": 47, "column": 23}}, {"id": 145, "type": "function_declarator", "text": "GetType()", "parent": 143, "children": [146, 147], "start_point": {"row": 47, "column": 24}, "end_point": {"row": 47, "column": 33}}, {"id": 146, "type": "identifier", "text": "GetType", "parent": 145, "children": [], "start_point": {"row": 47, "column": 24}, "end_point": {"row": 47, "column": 31}}, {"id": 147, "type": "parameter_list", "text": "()", "parent": 145, "children": [], "start_point": {"row": 47, "column": 31}, "end_point": {"row": 47, "column": 33}}, {"id": 148, "type": "return_statement", "text": "return (name);", "parent": 139, "children": [149], "start_point": {"row": 47, "column": 36}, "end_point": {"row": 47, "column": 50}}, {"id": 149, "type": "parenthesized_expression", "text": "(name)", "parent": 148, "children": [150], "start_point": {"row": 47, "column": 43}, "end_point": {"row": 47, "column": 49}}, {"id": 150, "type": "identifier", "text": "name", "parent": 149, "children": [], "start_point": {"row": 47, "column": 44}, "end_point": {"row": 47, "column": 48}}, {"id": 151, "type": "declaration", "text": "virtual int Serialize(const char* address, char* buffer, int bufsize);", "parent": 111, "children": [152, 153, 155], "start_point": {"row": 48, "column": 4}, "end_point": {"row": 48, "column": 74}}, {"id": 152, "type": "type_identifier", "text": "virtual", "parent": 151, "children": [], "start_point": {"row": 48, "column": 4}, "end_point": {"row": 48, "column": 11}}, {"id": 153, "type": "ERROR", "text": "int", "parent": 151, "children": [154], "start_point": {"row": 48, "column": 12}, "end_point": {"row": 48, "column": 15}}, {"id": 154, "type": "identifier", "text": "int", "parent": 153, "children": [], "start_point": {"row": 48, "column": 12}, "end_point": {"row": 48, "column": 15}}, {"id": 155, "type": "function_declarator", "text": "Serialize(const char* address, char* buffer, int bufsize)", "parent": 151, "children": [156, 157], "start_point": {"row": 48, "column": 16}, "end_point": {"row": 48, "column": 73}}, {"id": 156, "type": "identifier", "text": "Serialize", "parent": 155, "children": [], "start_point": {"row": 48, "column": 16}, "end_point": {"row": 48, "column": 25}}, {"id": 157, "type": "parameter_list", "text": "(const char* address, char* buffer, int bufsize)", "parent": 155, "children": [158, 163, 168], "start_point": {"row": 48, "column": 25}, "end_point": {"row": 48, "column": 73}}, {"id": 158, "type": "parameter_declaration", "text": "const char* address", "parent": 157, "children": [159, 160], "start_point": {"row": 48, "column": 26}, "end_point": {"row": 48, "column": 45}}, {"id": 159, "type": "primitive_type", "text": "char", "parent": 158, "children": [], "start_point": {"row": 48, "column": 32}, "end_point": {"row": 48, "column": 36}}, {"id": 160, "type": "pointer_declarator", "text": "* address", "parent": 158, "children": [161, 162], "start_point": {"row": 48, "column": 36}, "end_point": {"row": 48, "column": 45}}, {"id": 161, "type": "*", "text": "*", "parent": 160, "children": [], "start_point": {"row": 48, "column": 36}, "end_point": {"row": 48, "column": 37}}, {"id": 162, "type": "identifier", "text": "address", "parent": 160, "children": [], "start_point": {"row": 48, "column": 38}, "end_point": {"row": 48, "column": 45}}, {"id": 163, "type": "parameter_declaration", "text": "char* buffer", "parent": 157, "children": [164, 165], "start_point": {"row": 48, "column": 47}, "end_point": {"row": 48, "column": 59}}, {"id": 164, "type": "primitive_type", "text": "char", "parent": 163, "children": [], "start_point": {"row": 48, "column": 47}, "end_point": {"row": 48, "column": 51}}, {"id": 165, "type": "pointer_declarator", "text": "* buffer", "parent": 163, "children": [166, 167], "start_point": {"row": 48, "column": 51}, "end_point": {"row": 48, "column": 59}}, {"id": 166, "type": "*", "text": "*", "parent": 165, "children": [], "start_point": {"row": 48, "column": 51}, "end_point": {"row": 48, "column": 52}}, {"id": 167, "type": "identifier", "text": "buffer", "parent": 165, "children": [], "start_point": {"row": 48, "column": 53}, "end_point": {"row": 48, "column": 59}}, {"id": 168, "type": "parameter_declaration", "text": "int bufsize", "parent": 157, "children": [169, 170], "start_point": {"row": 48, "column": 61}, "end_point": {"row": 48, "column": 72}}, {"id": 169, "type": "primitive_type", "text": "int", "parent": 168, "children": [], "start_point": {"row": 48, "column": 61}, "end_point": {"row": 48, "column": 64}}, {"id": 170, "type": "identifier", "text": "bufsize", "parent": 168, "children": [], "start_point": {"row": 48, "column": 65}, "end_point": {"row": 48, "column": 72}}, {"id": 171, "type": "function_definition", "text": "class AgsImVec2Reader : public IAGSManagedObjectReader\n{\npublic:\n\n AgsImVec2Reader() {}\n\n virtual void Unserialize(int key, const char* serializedData, int dataSize);\n\n}", "parent": 3, "children": [172, 174], "start_point": {"row": 54, "column": 0}, "end_point": {"row": 62, "column": 1}}, {"id": 172, "type": "ERROR", "text": "AgsImVec2Reader : public", "parent": 171, "children": [173], "start_point": {"row": 54, "column": 6}, "end_point": {"row": 54, "column": 30}}, {"id": 173, "type": "identifier", "text": "AgsImVec2Reader", "parent": 172, "children": [], "start_point": {"row": 54, "column": 6}, "end_point": {"row": 54, "column": 21}}, {"id": 174, "type": "identifier", "text": "IAGSManagedObjectReader", "parent": 171, "children": [], "start_point": {"row": 54, "column": 31}, "end_point": {"row": 54, "column": 54}}, {"id": 175, "type": "labeled_statement", "text": "public:\n\n AgsImVec2Reader()", "parent": 171, "children": [], "start_point": {"row": 56, "column": 0}, "end_point": {"row": 58, "column": 21}}, {"id": 176, "type": "call_expression", "text": "AgsImVec2Reader()", "parent": 175, "children": [177, 178], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 21}}, {"id": 177, "type": "identifier", "text": "AgsImVec2Reader", "parent": 176, "children": [], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 19}}, {"id": 178, "type": "argument_list", "text": "()", "parent": 176, "children": [], "start_point": {"row": 58, "column": 19}, "end_point": {"row": 58, "column": 21}}, {"id": 179, "type": "declaration", "text": "virtual void Unserialize(int key, const char* serializedData, int dataSize);", "parent": 171, "children": [180, 181, 183], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 80}}, {"id": 180, "type": "type_identifier", "text": "virtual", "parent": 179, "children": [], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 11}}, {"id": 181, "type": "ERROR", "text": "void", "parent": 179, "children": [182], "start_point": {"row": 60, "column": 12}, "end_point": {"row": 60, "column": 16}}, {"id": 182, "type": "identifier", "text": "void", "parent": 181, "children": [], "start_point": {"row": 60, "column": 12}, "end_point": {"row": 60, "column": 16}}, {"id": 183, "type": "function_declarator", "text": "Unserialize(int key, const char* serializedData, int dataSize)", "parent": 179, "children": [184, 185], "start_point": {"row": 60, "column": 17}, "end_point": {"row": 60, "column": 79}}, {"id": 184, "type": "identifier", "text": "Unserialize", "parent": 183, "children": [], "start_point": {"row": 60, "column": 17}, "end_point": {"row": 60, "column": 28}}, {"id": 185, "type": "parameter_list", "text": "(int key, const char* serializedData, int dataSize)", "parent": 183, "children": [186, 189, 194], "start_point": {"row": 60, "column": 28}, "end_point": {"row": 60, "column": 79}}, {"id": 186, "type": "parameter_declaration", "text": "int key", "parent": 185, "children": [187, 188], "start_point": {"row": 60, "column": 29}, "end_point": {"row": 60, "column": 36}}, {"id": 187, "type": "primitive_type", "text": "int", "parent": 186, "children": [], "start_point": {"row": 60, "column": 29}, "end_point": {"row": 60, "column": 32}}, {"id": 188, "type": "identifier", "text": "key", "parent": 186, "children": [], "start_point": {"row": 60, "column": 33}, "end_point": {"row": 60, "column": 36}}, {"id": 189, "type": "parameter_declaration", "text": "const char* serializedData", "parent": 185, "children": [190, 191], "start_point": {"row": 60, "column": 38}, "end_point": {"row": 60, "column": 64}}, {"id": 190, "type": "primitive_type", "text": "char", "parent": 189, "children": [], "start_point": {"row": 60, "column": 44}, "end_point": {"row": 60, "column": 48}}, {"id": 191, "type": "pointer_declarator", "text": "* serializedData", "parent": 189, "children": [192, 193], "start_point": {"row": 60, "column": 48}, "end_point": {"row": 60, "column": 64}}, {"id": 192, "type": "*", "text": "*", "parent": 191, "children": [], "start_point": {"row": 60, "column": 48}, "end_point": {"row": 60, "column": 49}}, {"id": 193, "type": "identifier", "text": "serializedData", "parent": 191, "children": [], "start_point": {"row": 60, "column": 50}, "end_point": {"row": 60, "column": 64}}, {"id": 194, "type": "parameter_declaration", "text": "int dataSize", "parent": 185, "children": [195, 196], "start_point": {"row": 60, "column": 66}, "end_point": {"row": 60, "column": 78}}, {"id": 195, "type": "primitive_type", "text": "int", "parent": 194, "children": [], "start_point": {"row": 60, "column": 66}, "end_point": {"row": 60, "column": 69}}, {"id": 196, "type": "identifier", "text": "dataSize", "parent": 194, "children": [], "start_point": {"row": 60, "column": 70}, "end_point": {"row": 60, "column": 78}}, {"id": 197, "type": "declaration", "text": "extern AgsImVec2Interface AgsImVec2_Interface;", "parent": 3, "children": [198, 200, 201], "start_point": {"row": 66, "column": 0}, "end_point": {"row": 66, "column": 46}}, {"id": 198, "type": "storage_class_specifier", "text": "extern", "parent": 197, "children": [199], "start_point": {"row": 66, "column": 0}, "end_point": {"row": 66, "column": 6}}, {"id": 199, "type": "extern", "text": "extern", "parent": 198, "children": [], "start_point": {"row": 66, "column": 0}, "end_point": {"row": 66, "column": 6}}, {"id": 200, "type": "type_identifier", "text": "AgsImVec2Interface", "parent": 197, "children": [], "start_point": {"row": 66, "column": 7}, "end_point": {"row": 66, "column": 25}}, {"id": 201, "type": "identifier", "text": "AgsImVec2_Interface", "parent": 197, "children": [], "start_point": {"row": 66, "column": 26}, "end_point": {"row": 66, "column": 45}}, {"id": 202, "type": "declaration", "text": "extern AgsImVec2Reader AgsImVec2_Reader;", "parent": 3, "children": [203, 205, 206], "start_point": {"row": 67, "column": 0}, "end_point": {"row": 67, "column": 40}}, {"id": 203, "type": "storage_class_specifier", "text": "extern", "parent": 202, "children": [204], "start_point": {"row": 67, "column": 0}, "end_point": {"row": 67, "column": 6}}, {"id": 204, "type": "extern", "text": "extern", "parent": 203, "children": [], "start_point": {"row": 67, "column": 0}, "end_point": {"row": 67, "column": 6}}, {"id": 205, "type": "type_identifier", "text": "AgsImVec2Reader", "parent": 202, "children": [], "start_point": {"row": 67, "column": 7}, "end_point": {"row": 67, "column": 22}}, {"id": 206, "type": "identifier", "text": "AgsImVec2_Reader", "parent": 202, "children": [], "start_point": {"row": 67, "column": 23}, "end_point": {"row": 67, "column": 39}}, {"id": 207, "type": "#endif", "text": "#endif", "parent": 3, "children": [], "start_point": {"row": 71, "column": 0}, "end_point": {"row": 71, "column": 6}}]}, "node_categories": {"declarations": {"functions": [15, 33, 56, 69, 74, 81, 91, 103, 111, 128, 139, 145, 155, 171, 183], "variables": [21, 24, 36, 38, 44, 59, 61, 67, 72, 77, 84, 87, 94, 99, 106, 116, 124, 131, 136, 151, 158, 163, 168, 179, 186, 189, 194, 197, 202], "classes": [16, 17, 198, 203], "imports": [9, 10, 12, 13], "modules": [], "enums": []}, "statements": {"expressions": [121, 149, 176], "assignments": [], "loops": [], "conditionals": [3, 4, 5, 8, 18, 19, 23, 25, 26, 29, 31, 32, 34, 37, 39, 41, 45, 46, 49, 50, 52, 54, 55, 57, 60, 62, 64, 66, 70, 75, 78, 82, 86, 88, 92, 95, 98, 100, 104, 107, 110, 113, 114, 120, 122, 125, 127, 129, 135, 138, 140, 142, 146, 150, 152, 154, 156, 162, 167, 170, 173, 174, 177, 180, 182, 184, 188, 193, 196, 200, 201, 205, 206, 207], "returns": [148], "exceptions": []}, "expressions": {"calls": [0], "literals": [11, 14, 43], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 15, "universal_type": "function", "name": "AgsImVec2", "text_snippet": "struct AgsImVec2 : ImVec2 {\n public :\n int id;\n AgsImVec2(float _x, float _y)\n "}, {"node_id": 33, "universal_type": "function", "name": "unknown", "text_snippet": "ImVec2(_x,_y)"}, {"node_id": 56, "universal_type": "function", "name": "unknown", "text_snippet": "ImVec2(_x,_y)"}, {"node_id": 69, "universal_type": "function", "name": "unknown", "text_snippet": "Length()"}, {"node_id": 74, "universal_type": "function", "name": "unknown", "text_snippet": "SquaredLength()"}, {"node_id": 81, "universal_type": "function", "name": "unknown", "text_snippet": "Scale(float scale)"}, {"node_id": 91, "universal_type": "function", "name": "unknown", "text_snippet": "Add(AgsImVec2 *agsImVec2)"}, {"node_id": 103, "universal_type": "function", "name": "unknown", "text_snippet": "Sub(AgsImVec2 *agsImVec2)"}, {"node_id": 111, "universal_type": "function", "name": "AgsImVec2Interface", "text_snippet": "class AgsImVec2Interface : public IAGSScriptManagedObject\n{\npublic:\n static const char* name;\n\n "}, {"node_id": 128, "universal_type": "function", "name": "force)", "text_snippet": "Dispose(const char* address, bool force)"}, {"node_id": 139, "universal_type": "function", "name": "unknown", "text_snippet": "virtual const char* GetType() { return (name); }"}, {"node_id": 145, "universal_type": "function", "name": "unknown", "text_snippet": "GetType()"}, {"node_id": 155, "universal_type": "function", "name": "bufsize)", "text_snippet": "Serialize(const char* address, char* buffer, int bufsize)"}, {"node_id": 171, "universal_type": "function", "name": "AgsImVec2Reader", "text_snippet": "class AgsImVec2Reader : public IAGSManagedObjectReader\n{\npublic:\n\n AgsImVec2Reader() {}\n\n virt"}, {"node_id": 183, "universal_type": "function", "name": "dataSize)", "text_snippet": "Unserialize(int key, const char* serializedData, int dataSize)"}], "class_declarations": [{"node_id": 16, "universal_type": "class", "name": "AgsImVec2", "text_snippet": "struct AgsImVec2"}, {"node_id": 17, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 198, "universal_type": "class", "name": "unknown", "text_snippet": "extern"}, {"node_id": 203, "universal_type": "class", "name": "unknown", "text_snippet": "extern"}], "import_statements": [{"node_id": 9, "text": "#include \"plugin/agsplugin.h\"\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include \"imgui/imgui.h\"\n"}, {"node_id": 13, "text": "#include"}]}, "original_source_code": "/*\n * Copyright (C) 2020 <NAME>\n *\n * This program is free software. You can use and redistribute it\n * under the terms and conditions of the MIT License (see LICENCE).\n */\n\n#pragma once\n\n#ifndef _AGSIMVEC2_H\n#define _AGSIMVEC2_H\n\n#include \"plugin/agsplugin.h\"\n#include \"imgui/imgui.h\"\n\nstruct AgsImVec2 : ImVec2 {\n public :\n int id;\n AgsImVec2(float _x, float _y)\n : ImVec2(_x,_y){\n id = -1;\n }\n\n AgsImVec2(float _x, float _y, int _id)\n : ImVec2(_x,_y){\n id = _id;\n }\n float Length() ;\n float SquaredLength();\n AgsImVec2* Scale(float scale) ;\n\n AgsImVec2 *Add(AgsImVec2 *agsImVec2);\n\n AgsImVec2 *Sub(AgsImVec2 *agsImVec2);\n};\n\n//------------------------------------------------------------------------------\n// AGS interface instances\n\nclass AgsImVec2Interface : public IAGSScriptManagedObject\n{\npublic:\n static const char* name;\n\n AgsImVec2Interface() {};\n\n virtual int Dispose(const char* address, bool force);\n virtual const char* GetType() { return (name); }\n virtual int Serialize(const char* address, char* buffer, int bufsize);\n\n};\n\n//- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \n\nclass AgsImVec2Reader : public IAGSManagedObjectReader\n{\npublic:\n\n AgsImVec2Reader() {}\n\n virtual void Unserialize(int key, const char* serializedData, int dataSize);\n\n};\n\n//------------------------------------------------------------------------------\n\nextern AgsImVec2Interface AgsImVec2_Interface;\nextern AgsImVec2Reader AgsImVec2_Reader;\n\n//------------------------------------------------------------------------------\n\n#endif /* _AGSIMVEC2_H */\n\n//............\n"}
80,539
c
/* * (C) 2003-2006 Gabest * (C) 2006-2018 see Authors.txt * * This file is part of MPC-BE. * * MPC-BE is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 3 of the License, or * (at your option) any later version. * * MPC-BE is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>. * */ #pragma once #include "OggFile.h" #include "../BaseSplitter/BaseSplitter.h" #define OggSplitterName L"MPC Ogg Splitter" #define OggSourceName L"MPC Ogg Source" class COggSplitterFilter; class COggSplitterOutputPin : public CBaseSplitterOutputPin { protected: std::map<CStringW, CStringW> m_pComments; CPacketQueue m_queue; std::vector<BYTE> m_lastPacketData; DWORD m_lastseqnum; REFERENCE_TIME m_rtLast; bool m_bSetKeyFrame; void ResetState(DWORD seqnum = DWORD_MAX); COggSplitterFilter* m_pFilter = nullptr; public: COggSplitterOutputPin(LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); void AddComment(BYTE* p, int len); CStringW GetComment(CStringW key); void HandlePacket(DWORD TrackNumber, BYTE* pData, int len); HRESULT UnpackPage(OggPage& page); virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len) PURE; virtual REFERENCE_TIME GetRefTime(__int64 granule_position) PURE; CAutoPtr<CPacket> GetPacket(); HRESULT DeliverEndFlush(); HRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate); }; class COggVorbisOutputPin : public COggSplitterOutputPin { std::list<CAutoPtr<CPacket>> m_initpackets; DWORD m_audio_sample_rate; DWORD m_blocksize[2], m_lastblocksize; std::vector<bool> m_blockflags; virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len); virtual REFERENCE_TIME GetRefTime(__int64 granule_position); HRESULT DeliverPacket(CAutoPtr<CPacket> p); HRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate); public: COggVorbisOutputPin(OggVorbisIdHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); HRESULT UnpackInitPage(OggPage& page); bool IsInitialized() { return m_initpackets.size() >= 3; } }; class COggFlacOutputPin : public COggSplitterOutputPin { int m_nSamplesPerSec; int m_nChannels; WORD m_wBitsPerSample; int m_nAvgBytesPerSec; virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len); virtual REFERENCE_TIME GetRefTime(__int64 granule_position); public: COggFlacOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); }; class COggDirectShowOutputPin : public COggSplitterOutputPin { virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len); virtual REFERENCE_TIME GetRefTime(__int64 granule_position); public: COggDirectShowOutputPin(AM_MEDIA_TYPE* pmt, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); }; class COggStreamOutputPin : public COggSplitterOutputPin { __int64 m_time_unit, m_samples_per_unit; DWORD m_default_len; virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len); virtual REFERENCE_TIME GetRefTime(__int64 granule_position); public: COggStreamOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); }; class COggVideoOutputPin : public COggStreamOutputPin { public: COggVideoOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); }; class COggAudioOutputPin : public COggStreamOutputPin { public: COggAudioOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); }; class COggTextOutputPin : public COggStreamOutputPin { public: COggTextOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); }; class COggKateOutputPin : public COggStreamOutputPin { public: COggKateOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); }; class COggTheoraOutputPin : public COggSplitterOutputPin { std::list<CAutoPtr<CPacket>> m_initpackets; LONG m_KfgShift; LONG m_KfgMask; UINT m_nVersion; REFERENCE_TIME m_rtAvgTimePerFrame; virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len); virtual REFERENCE_TIME GetRefTime(__int64 granule_position); public: COggTheoraOutputPin(OggPage& page, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); HRESULT UnpackInitPage(OggPage& page); bool IsInitialized() { return m_initpackets.size() >= 3; } }; class COggDiracOutputPin : public COggSplitterOutputPin { REFERENCE_TIME m_rtAvgTimePerFrame; bool m_bOldDirac; bool m_IsInitialized; virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len); virtual REFERENCE_TIME GetRefTime(__int64 granule_position); public: COggDiracOutputPin(BYTE* p, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); HRESULT UnpackInitPage(OggPage& page); bool IsInitialized() { return m_IsInitialized; } HRESULT InitDirac(BYTE* p, int nCount); }; class COggOpusOutputPin : public COggSplitterOutputPin { int m_SampleRate; WORD m_Preskip; virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len); virtual REFERENCE_TIME GetRefTime(__int64 granule_position); public: COggOpusOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); }; class COggSpeexOutputPin : public COggSplitterOutputPin { int m_SampleRate; virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len); virtual REFERENCE_TIME GetRefTime(__int64 granule_position); public: COggSpeexOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); }; class COggVP8OutputPin : public COggSplitterOutputPin { REFERENCE_TIME m_rtAvgTimePerFrame; virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len); virtual REFERENCE_TIME GetRefTime(__int64 granule_position); public: COggVP8OutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr); }; class __declspec(uuid("9FF48807-E133-40AA-826F-9B2959E5232D")) COggSplitterFilter : public CBaseSplitterFilter { protected: CAutoPtr<COggFile> m_pFile; HRESULT CreateOutputs(IAsyncReader* pAsyncReader); bool DemuxInit(); void DemuxSeek(REFERENCE_TIME rt); bool DemuxLoop(); DWORD m_bitstream_serial_number_start = 0; DWORD m_bitstream_serial_number_last = 0; DWORD m_bitstream_serial_number_Video = DWORD_MAX; public: REFERENCE_TIME m_rtOffset = 0; COggSplitterFilter(LPUNKNOWN pUnk, HRESULT* phr); virtual ~COggSplitterFilter(); // CBaseFilter STDMETHODIMP_(HRESULT) QueryFilterInfo(FILTER_INFO* pInfo); }; class __declspec(uuid("6D3688CE-3E9D-42F4-92CA-8A11119D25CD")) COggSourceFilter : public COggSplitterFilter { public: COggSourceFilter(LPUNKNOWN pUnk, HRESULT* phr); };
36.88
194
(translation_unit) "/*\n * (C) 2003-2006 Gabest\n * (C) 2006-2018 see Authors.txt\n *\n * This file is part of MPC-BE.\n *\n * MPC-BE is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 3 of the License, or\n * (at your option) any later version.\n *\n * MPC-BE is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\n#pragma once\n\n#include "OggFile.h"\n#include "../BaseSplitter/BaseSplitter.h"\n\n#define OggSplitterName L"MPC Ogg Splitter"\n#define OggSourceName L"MPC Ogg Source"\n\nclass COggSplitterFilter;\n\nclass COggSplitterOutputPin : public CBaseSplitterOutputPin\n{\nprotected:\n std::map<CStringW, CStringW> m_pComments;\n\n CPacketQueue m_queue;\n std::vector<BYTE> m_lastPacketData;\n DWORD m_lastseqnum;\n REFERENCE_TIME m_rtLast;\n bool m_bSetKeyFrame;\n\n void ResetState(DWORD seqnum = DWORD_MAX);\n\n COggSplitterFilter* m_pFilter = nullptr;\n\npublic:\n COggSplitterOutputPin(LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n void AddComment(BYTE* p, int len);\n CStringW GetComment(CStringW key);\n\n void HandlePacket(DWORD TrackNumber, BYTE* pData, int len);\n HRESULT UnpackPage(OggPage& page);\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len) PURE;\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position) PURE;\n CAutoPtr<CPacket> GetPacket();\n\n HRESULT DeliverEndFlush();\n HRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);\n};\n\nclass COggVorbisOutputPin : public COggSplitterOutputPin\n{\n std::list<CAutoPtr<CPacket>> m_initpackets;\n\n DWORD m_audio_sample_rate;\n DWORD m_blocksize[2], m_lastblocksize;\n std::vector<bool> m_blockflags;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\n HRESULT DeliverPacket(CAutoPtr<CPacket> p);\n HRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);\n\npublic:\n COggVorbisOutputPin(OggVorbisIdHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n HRESULT UnpackInitPage(OggPage& page);\n bool IsInitialized() {\n return m_initpackets.size() >= 3;\n }\n};\n\nclass COggFlacOutputPin : public COggSplitterOutputPin\n{\n int m_nSamplesPerSec;\n int m_nChannels;\n WORD m_wBitsPerSample;\n int m_nAvgBytesPerSec;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggFlacOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggDirectShowOutputPin : public COggSplitterOutputPin\n{\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggDirectShowOutputPin(AM_MEDIA_TYPE* pmt, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggStreamOutputPin : public COggSplitterOutputPin\n{\n __int64 m_time_unit, m_samples_per_unit;\n DWORD m_default_len;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggStreamOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggVideoOutputPin : public COggStreamOutputPin\n{\npublic:\n COggVideoOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggAudioOutputPin : public COggStreamOutputPin\n{\npublic:\n COggAudioOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggTextOutputPin : public COggStreamOutputPin\n{\npublic:\n COggTextOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggKateOutputPin : public COggStreamOutputPin\n{\npublic:\n COggKateOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggTheoraOutputPin : public COggSplitterOutputPin\n{\n std::list<CAutoPtr<CPacket>> m_initpackets;\n LONG m_KfgShift;\n LONG m_KfgMask;\n UINT m_nVersion;\n REFERENCE_TIME m_rtAvgTimePerFrame;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggTheoraOutputPin(OggPage& page, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n HRESULT UnpackInitPage(OggPage& page);\n bool IsInitialized() {\n return m_initpackets.size() >= 3;\n }\n};\n\nclass COggDiracOutputPin : public COggSplitterOutputPin\n{\n REFERENCE_TIME m_rtAvgTimePerFrame;\n bool m_bOldDirac;\n bool m_IsInitialized;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggDiracOutputPin(BYTE* p, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n HRESULT UnpackInitPage(OggPage& page);\n bool IsInitialized() {\n return m_IsInitialized;\n }\n HRESULT InitDirac(BYTE* p, int nCount);\n};\n\nclass COggOpusOutputPin : public COggSplitterOutputPin\n{\n int m_SampleRate;\n WORD m_Preskip;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggOpusOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggSpeexOutputPin : public COggSplitterOutputPin\n{\n int m_SampleRate;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggSpeexOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggVP8OutputPin : public COggSplitterOutputPin\n{\n REFERENCE_TIME m_rtAvgTimePerFrame;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggVP8OutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass __declspec(uuid("9FF48807-E133-40AA-826F-9B2959E5232D"))\n COggSplitterFilter : public CBaseSplitterFilter\n{\nprotected:\n CAutoPtr<COggFile> m_pFile;\n HRESULT CreateOutputs(IAsyncReader* pAsyncReader);\n\n bool DemuxInit();\n void DemuxSeek(REFERENCE_TIME rt);\n bool DemuxLoop();\n\n DWORD m_bitstream_serial_number_start = 0;\n DWORD m_bitstream_serial_number_last = 0;\n DWORD m_bitstream_serial_number_Video = DWORD_MAX;\n\npublic:\n REFERENCE_TIME m_rtOffset = 0;\n\n COggSplitterFilter(LPUNKNOWN pUnk, HRESULT* phr);\n virtual ~COggSplitterFilter();\n\n // CBaseFilter\n\n STDMETHODIMP_(HRESULT) QueryFilterInfo(FILTER_INFO* pInfo);\n};\n\nclass __declspec(uuid("6D3688CE-3E9D-42F4-92CA-8A11119D25CD"))\n COggSourceFilter : public COggSplitterFilter\n{\npublic:\n COggSourceFilter(LPUNKNOWN pUnk, HRESULT* phr);\n};\n" (comment) "/*\n * (C) 2003-2006 Gabest\n * (C) 2006-2018 see Authors.txt\n *\n * This file is part of MPC-BE.\n *\n * MPC-BE is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 3 of the License, or\n * (at your option) any later version.\n *\n * MPC-BE is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */" (preproc_call) "#pragma once\n" (preproc_directive) "#pragma" (preproc_arg) "once" (preproc_include) "#include "OggFile.h"\n" (#include) "#include" (string_literal) ""OggFile.h"" (") """ (string_content) "OggFile.h" (") """ (preproc_include) "#include "../BaseSplitter/BaseSplitter.h"\n" (#include) "#include" (string_literal) ""../BaseSplitter/BaseSplitter.h"" (") """ (string_content) "../BaseSplitter/BaseSplitter.h" (") """ (preproc_def) "#define OggSplitterName L"MPC Ogg Splitter"\n" (#define) "#define" (identifier) "OggSplitterName" (preproc_arg) "L"MPC Ogg Splitter"" (preproc_def) "#define OggSourceName L"MPC Ogg Source"\n" (#define) "#define" (identifier) "OggSourceName" (preproc_arg) "L"MPC Ogg Source"" (declaration) "class COggSplitterFilter;" (type_identifier) "class" (identifier) "COggSplitterFilter" (;) ";" (function_definition) "class COggSplitterOutputPin : public CBaseSplitterOutputPin\n{\nprotected:\n std::map<CStringW, CStringW> m_pComments;\n\n CPacketQueue m_queue;\n std::vector<BYTE> m_lastPacketData;\n DWORD m_lastseqnum;\n REFERENCE_TIME m_rtLast;\n bool m_bSetKeyFrame;\n\n void ResetState(DWORD seqnum = DWORD_MAX);\n\n COggSplitterFilter* m_pFilter = nullptr;\n\npublic:\n COggSplitterOutputPin(LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n void AddComment(BYTE* p, int len);\n CStringW GetComment(CStringW key);\n\n void HandlePacket(DWORD TrackNumber, BYTE* pData, int len);\n HRESULT UnpackPage(OggPage& page);\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len) PURE;\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position) PURE;\n CAutoPtr<CPacket> GetPacket();\n\n HRESULT DeliverEndFlush();\n HRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);\n}" (type_identifier) "class" (ERROR) "COggSplitterOutputPin : public" (identifier) "COggSplitterOutputPin" (:) ":" (identifier) "public" (identifier) "CBaseSplitterOutputPin" (compound_statement) "{\nprotected:\n std::map<CStringW, CStringW> m_pComments;\n\n CPacketQueue m_queue;\n std::vector<BYTE> m_lastPacketData;\n DWORD m_lastseqnum;\n REFERENCE_TIME m_rtLast;\n bool m_bSetKeyFrame;\n\n void ResetState(DWORD seqnum = DWORD_MAX);\n\n COggSplitterFilter* m_pFilter = nullptr;\n\npublic:\n COggSplitterOutputPin(LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n void AddComment(BYTE* p, int len);\n CStringW GetComment(CStringW key);\n\n void HandlePacket(DWORD TrackNumber, BYTE* pData, int len);\n HRESULT UnpackPage(OggPage& page);\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len) PURE;\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position) PURE;\n CAutoPtr<CPacket> GetPacket();\n\n HRESULT DeliverEndFlush();\n HRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);\n}" ({) "{" (labeled_statement) "protected:\n std::map<CStringW, CStringW> m_pComments;" (statement_identifier) "protected" (:) ":" (labeled_statement) "std::map<CStringW, CStringW> m_pComments;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "map<CStringW, CStringW> m_pComments;" (comma_expression) "map<CStringW, CStringW> m_pComments" (binary_expression) "map<CStringW" (identifier) "map" (<) "<" (identifier) "CStringW" (,) "," (binary_expression) "CStringW> m_pComments" (identifier) "CStringW" (>) ">" (identifier) "m_pComments" (;) ";" (declaration) "CPacketQueue m_queue;" (type_identifier) "CPacketQueue" (identifier) "m_queue" (;) ";" (labeled_statement) "std::vector<BYTE> m_lastPacketData;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "vector<BYTE> m_lastPacketData;" (binary_expression) "vector<BYTE> m_lastPacketData" (binary_expression) "vector<BYTE" (identifier) "vector" (<) "<" (identifier) "BYTE" (>) ">" (identifier) "m_lastPacketData" (;) ";" (declaration) "DWORD m_lastseqnum;" (type_identifier) "DWORD" (identifier) "m_lastseqnum" (;) ";" (declaration) "REFERENCE_TIME m_rtLast;" (type_identifier) "REFERENCE_TIME" (identifier) "m_rtLast" (;) ";" (declaration) "bool m_bSetKeyFrame;" (primitive_type) "bool" (identifier) "m_bSetKeyFrame" (;) ";" (declaration) "void ResetState(DWORD seqnum = DWORD_MAX);" (primitive_type) "void" (function_declarator) "ResetState(DWORD seqnum = DWORD_MAX)" (identifier) "ResetState" (parameter_list) "(DWORD seqnum = DWORD_MAX)" (() "(" (parameter_declaration) "DWORD seqnum = DWORD_MAX" (type_identifier) "DWORD" (ERROR) "seqnum =" (identifier) "seqnum" (=) "=" (identifier) "DWORD_MAX" ()) ")" (;) ";" (declaration) "COggSplitterFilter* m_pFilter = nullptr;" (type_identifier) "COggSplitterFilter" (init_declarator) "* m_pFilter = nullptr" (pointer_declarator) "* m_pFilter" (*) "*" (identifier) "m_pFilter" (=) "=" (null) "nullptr" (nullptr) "nullptr" (;) ";" (labeled_statement) "public:\n COggSplitterOutputPin(LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (declaration) "COggSplitterOutputPin(LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (macro_type_specifier) "COggSplitterOutputPin(LPCWSTR" (identifier) "COggSplitterOutputPin" (() "(" (type_descriptor) "LPCWSTR" (type_identifier) "LPCWSTR" ()) "" (identifier) "pName" (,) "," (ERROR) "CBaseFilter" (identifier) "CBaseFilter" (pointer_declarator) "* pFilter" (*) "*" (identifier) "pFilter" (,) "," (ERROR) "CCritSec" (identifier) "CCritSec" (pointer_declarator) "* pLock" (*) "*" (identifier) "pLock" (,) "," (ERROR) "HRESULT" (identifier) "HRESULT" (pointer_declarator) "* phr" (*) "*" (identifier) "phr" (ERROR) ")" ()) ")" (;) ";" (declaration) "void AddComment(BYTE* p, int len);" (primitive_type) "void" (function_declarator) "AddComment(BYTE* p, int len)" (identifier) "AddComment" (parameter_list) "(BYTE* p, int len)" (() "(" (parameter_declaration) "BYTE* p" (type_identifier) "BYTE" (pointer_declarator) "* p" (*) "*" (identifier) "p" (,) "," (parameter_declaration) "int len" (primitive_type) "int" (identifier) "len" ()) ")" (;) ";" (declaration) "CStringW GetComment(CStringW key);" (type_identifier) "CStringW" (function_declarator) "GetComment(CStringW key)" (identifier) "GetComment" (parameter_list) "(CStringW key)" (() "(" (parameter_declaration) "CStringW key" (type_identifier) "CStringW" (identifier) "key" ()) ")" (;) ";" (declaration) "void HandlePacket(DWORD TrackNumber, BYTE* pData, int len);" (primitive_type) "void" (function_declarator) "HandlePacket(DWORD TrackNumber, BYTE* pData, int len)" (identifier) "HandlePacket" (parameter_list) "(DWORD TrackNumber, BYTE* pData, int len)" (() "(" (parameter_declaration) "DWORD TrackNumber" (type_identifier) "DWORD" (identifier) "TrackNumber" (,) "," (parameter_declaration) "BYTE* pData" (type_identifier) "BYTE" (pointer_declarator) "* pData" (*) "*" (identifier) "pData" (,) "," (parameter_declaration) "int len" (primitive_type) "int" (identifier) "len" ()) ")" (;) ";" (declaration) "HRESULT UnpackPage(OggPage& page);" (type_identifier) "HRESULT" (function_declarator) "UnpackPage(OggPage& page)" (identifier) "UnpackPage" (parameter_list) "(OggPage& page)" (() "(" (parameter_declaration) "OggPage& page" (type_identifier) "OggPage" (ERROR) "&" (&) "&" (identifier) "page" ()) ")" (;) ";" (declaration) "virtual HRESULT" (type_identifier) "virtual" (identifier) "HRESULT" (;) "" (expression_statement) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len) PURE;" (call_expression) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (identifier) "UnpackPacket" (argument_list) "(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (() "(" (binary_expression) "CAutoPtr<CPacket>& p" (binary_expression) "CAutoPtr<CPacket" (identifier) "CAutoPtr" (<) "<" (identifier) "CPacket" (>) ">" (pointer_expression) "& p" (&) "&" (identifier) "p" (,) "," (binary_expression) "BYTE* pData" (identifier) "BYTE" (*) "*" (identifier) "pData" (,) "," (identifier) "int" (ERROR) "len" (identifier) "len" ()) ")" (ERROR) "PURE" (identifier) "PURE" (;) ";" (ERROR) "virtual REFERENCE_TIME GetRefTime(__int64 granule_position) PURE" (type_identifier) "virtual" (ERROR) "REFERENCE_TIME" (identifier) "REFERENCE_TIME" (function_declarator) "GetRefTime(__int64 granule_position) PURE" (identifier) "GetRefTime" (parameter_list) "(__int64 granule_position)" (() "(" (parameter_declaration) "__int64 granule_position" (type_identifier) "__int64" (identifier) "granule_position" ()) ")" (identifier) "PURE" (expression_statement) ";" (;) ";" (expression_statement) "CAutoPtr<CPacket> GetPacket();" (binary_expression) "CAutoPtr<CPacket> GetPacket()" (binary_expression) "CAutoPtr<CPacket" (identifier) "CAutoPtr" (<) "<" (identifier) "CPacket" (>) ">" (call_expression) "GetPacket()" (identifier) "GetPacket" (argument_list) "()" (() "(" ()) ")" (;) ";" (declaration) "HRESULT DeliverEndFlush();" (type_identifier) "HRESULT" (function_declarator) "DeliverEndFlush()" (identifier) "DeliverEndFlush" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "HRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);" (type_identifier) "HRESULT" (function_declarator) "DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate)" (identifier) "DeliverNewSegment" (parameter_list) "(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate)" (() "(" (parameter_declaration) "REFERENCE_TIME tStart" (type_identifier) "REFERENCE_TIME" (identifier) "tStart" (,) "," (parameter_declaration) "REFERENCE_TIME tStop" (type_identifier) "REFERENCE_TIME" (identifier) "tStop" (,) "," (parameter_declaration) "double dRate" (primitive_type) "double" (identifier) "dRate" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (function_definition) "class COggVorbisOutputPin : public COggSplitterOutputPin\n{\n std::list<CAutoPtr<CPacket>> m_initpackets;\n\n DWORD m_audio_sample_rate;\n DWORD m_blocksize[2], m_lastblocksize;\n std::vector<bool> m_blockflags;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\n HRESULT DeliverPacket(CAutoPtr<CPacket> p);\n HRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);\n\npublic:\n COggVorbisOutputPin(OggVorbisIdHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n HRESULT UnpackInitPage(OggPage& page);\n bool IsInitialized() {\n return m_initpackets.size() >= 3;\n }\n}" (type_identifier) "class" (ERROR) "COggVorbisOutputPin : public" (identifier) "COggVorbisOutputPin" (:) ":" (identifier) "public" (identifier) "COggSplitterOutputPin" (compound_statement) "{\n std::list<CAutoPtr<CPacket>> m_initpackets;\n\n DWORD m_audio_sample_rate;\n DWORD m_blocksize[2], m_lastblocksize;\n std::vector<bool> m_blockflags;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\n HRESULT DeliverPacket(CAutoPtr<CPacket> p);\n HRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);\n\npublic:\n COggVorbisOutputPin(OggVorbisIdHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n HRESULT UnpackInitPage(OggPage& page);\n bool IsInitialized() {\n return m_initpackets.size() >= 3;\n }\n}" ({) "{" (labeled_statement) "std::list<CAutoPtr<CPacket>> m_initpackets;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "list<CAutoPtr<CPacket>> m_initpackets;" (binary_expression) "list<CAutoPtr<CPacket>> m_initpackets" (binary_expression) "list<CAutoPtr" (identifier) "list" (<) "<" (identifier) "CAutoPtr" (<) "<" (binary_expression) "CPacket>> m_initpackets" (identifier) "CPacket" (>>) ">>" (identifier) "m_initpackets" (;) ";" (declaration) "DWORD m_audio_sample_rate;" (type_identifier) "DWORD" (identifier) "m_audio_sample_rate" (;) ";" (declaration) "DWORD m_blocksize[2], m_lastblocksize;" (type_identifier) "DWORD" (array_declarator) "m_blocksize[2]" (identifier) "m_blocksize" ([) "[" (number_literal) "2" (]) "]" (,) "," (identifier) "m_lastblocksize" (;) ";" (labeled_statement) "std::vector<bool> m_blockflags;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "vector<bool> m_blockflags;" (binary_expression) "vector<bool> m_blockflags" (binary_expression) "vector<bool" (identifier) "vector" (<) "<" (identifier) "bool" (>) ">" (identifier) "m_blockflags" (;) ";" (declaration) "virtual HRESULT" (type_identifier) "virtual" (identifier) "HRESULT" (;) "" (expression_statement) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);" (call_expression) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (identifier) "UnpackPacket" (argument_list) "(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (() "(" (binary_expression) "CAutoPtr<CPacket>& p" (binary_expression) "CAutoPtr<CPacket" (identifier) "CAutoPtr" (<) "<" (identifier) "CPacket" (>) ">" (pointer_expression) "& p" (&) "&" (identifier) "p" (,) "," (binary_expression) "BYTE* pData" (identifier) "BYTE" (*) "*" (identifier) "pData" (,) "," (identifier) "int" (ERROR) "len" (identifier) "len" ()) ")" (;) ";" (declaration) "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);" (type_identifier) "virtual" (ERROR) "REFERENCE_TIME" (identifier) "REFERENCE_TIME" (function_declarator) "GetRefTime(__int64 granule_position)" (identifier) "GetRefTime" (parameter_list) "(__int64 granule_position)" (() "(" (parameter_declaration) "__int64 granule_position" (type_identifier) "__int64" (identifier) "granule_position" ()) ")" (;) ";" (declaration) "HRESULT DeliverPacket(CAutoPtr<CPacket> p);" (type_identifier) "HRESULT" (function_declarator) "DeliverPacket(CAutoPtr<CPacket> p)" (identifier) "DeliverPacket" (parameter_list) "(CAutoPtr<CPacket> p)" (() "(" (parameter_declaration) "CAutoPtr<CPacket> p" (type_identifier) "CAutoPtr" (ERROR) "<CPacket>" (<) "<" (identifier) "CPacket" (>) ">" (identifier) "p" ()) ")" (;) ";" (declaration) "HRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);" (type_identifier) "HRESULT" (function_declarator) "DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate)" (identifier) "DeliverNewSegment" (parameter_list) "(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate)" (() "(" (parameter_declaration) "REFERENCE_TIME tStart" (type_identifier) "REFERENCE_TIME" (identifier) "tStart" (,) "," (parameter_declaration) "REFERENCE_TIME tStop" (type_identifier) "REFERENCE_TIME" (identifier) "tStop" (,) "," (parameter_declaration) "double dRate" (primitive_type) "double" (identifier) "dRate" ()) ")" (;) ";" (labeled_statement) "public:\n COggVorbisOutputPin(OggVorbisIdHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (expression_statement) "COggVorbisOutputPin(OggVorbisIdHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (call_expression) "COggVorbisOutputPin(OggVorbisIdHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (identifier) "COggVorbisOutputPin" (argument_list) "(OggVorbisIdHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (() "(" (binary_expression) "OggVorbisIdHeader* h" (identifier) "OggVorbisIdHeader" (*) "*" (identifier) "h" (,) "," (identifier) "LPCWSTR" (ERROR) "pName" (identifier) "pName" (,) "," (binary_expression) "CBaseFilter* pFilter" (identifier) "CBaseFilter" (*) "*" (identifier) "pFilter" (,) "," (binary_expression) "CCritSec* pLock" (identifier) "CCritSec" (*) "*" (identifier) "pLock" (,) "," (binary_expression) "HRESULT* phr" (identifier) "HRESULT" (*) "*" (identifier) "phr" ()) ")" (;) ";" (declaration) "HRESULT UnpackInitPage(OggPage& page);" (type_identifier) "HRESULT" (function_declarator) "UnpackInitPage(OggPage& page)" (identifier) "UnpackInitPage" (parameter_list) "(OggPage& page)" (() "(" (parameter_declaration) "OggPage& page" (type_identifier) "OggPage" (ERROR) "&" (&) "&" (identifier) "page" ()) ")" (;) ";" (function_definition) "bool IsInitialized() {\n return m_initpackets.size() >= 3;\n }" (primitive_type) "bool" (function_declarator) "IsInitialized()" (identifier) "IsInitialized" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n return m_initpackets.size() >= 3;\n }" ({) "{" (return_statement) "return m_initpackets.size() >= 3;" (return) "return" (binary_expression) "m_initpackets.size() >= 3" (call_expression) "m_initpackets.size()" (field_expression) "m_initpackets.size" (identifier) "m_initpackets" (.) "." (field_identifier) "size" (argument_list) "()" (() "(" ()) ")" (>=) ">=" (number_literal) "3" (;) ";" (}) "}" (}) "}" (expression_statement) ";" (;) ";" (function_definition) "class COggFlacOutputPin : public COggSplitterOutputPin\n{\n int m_nSamplesPerSec;\n int m_nChannels;\n WORD m_wBitsPerSample;\n int m_nAvgBytesPerSec;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggFlacOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" (type_identifier) "class" (ERROR) "COggFlacOutputPin : public" (identifier) "COggFlacOutputPin" (:) ":" (identifier) "public" (identifier) "COggSplitterOutputPin" (compound_statement) "{\n int m_nSamplesPerSec;\n int m_nChannels;\n WORD m_wBitsPerSample;\n int m_nAvgBytesPerSec;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggFlacOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" ({) "{" (declaration) "int m_nSamplesPerSec;" (primitive_type) "int" (identifier) "m_nSamplesPerSec" (;) ";" (declaration) "int m_nChannels;" (primitive_type) "int" (identifier) "m_nChannels" (;) ";" (declaration) "WORD m_wBitsPerSample;" (type_identifier) "WORD" (identifier) "m_wBitsPerSample" (;) ";" (declaration) "int m_nAvgBytesPerSec;" (primitive_type) "int" (identifier) "m_nAvgBytesPerSec" (;) ";" (declaration) "virtual HRESULT" (type_identifier) "virtual" (identifier) "HRESULT" (;) "" (expression_statement) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);" (call_expression) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (identifier) "UnpackPacket" (argument_list) "(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (() "(" (binary_expression) "CAutoPtr<CPacket>& p" (binary_expression) "CAutoPtr<CPacket" (identifier) "CAutoPtr" (<) "<" (identifier) "CPacket" (>) ">" (pointer_expression) "& p" (&) "&" (identifier) "p" (,) "," (binary_expression) "BYTE* pData" (identifier) "BYTE" (*) "*" (identifier) "pData" (,) "," (identifier) "int" (ERROR) "len" (identifier) "len" ()) ")" (;) ";" (declaration) "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);" (type_identifier) "virtual" (ERROR) "REFERENCE_TIME" (identifier) "REFERENCE_TIME" (function_declarator) "GetRefTime(__int64 granule_position)" (identifier) "GetRefTime" (parameter_list) "(__int64 granule_position)" (() "(" (parameter_declaration) "__int64 granule_position" (type_identifier) "__int64" (identifier) "granule_position" ()) ")" (;) ";" (labeled_statement) "public:\n COggFlacOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (expression_statement) "COggFlacOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (call_expression) "COggFlacOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (identifier) "COggFlacOutputPin" (argument_list) "(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (() "(" (binary_expression) "BYTE* h" (identifier) "BYTE" (*) "*" (identifier) "h" (,) "," (ERROR) "int" (identifier) "int" (identifier) "nCount" (,) "," (identifier) "LPCWSTR" (ERROR) "pName" (identifier) "pName" (,) "," (binary_expression) "CBaseFilter* pFilter" (identifier) "CBaseFilter" (*) "*" (identifier) "pFilter" (,) "," (binary_expression) "CCritSec* pLock" (identifier) "CCritSec" (*) "*" (identifier) "pLock" (,) "," (binary_expression) "HRESULT* phr" (identifier) "HRESULT" (*) "*" (identifier) "phr" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (function_definition) "class COggDirectShowOutputPin : public COggSplitterOutputPin\n{\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggDirectShowOutputPin(AM_MEDIA_TYPE* pmt, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" (type_identifier) "class" (identifier) "COggDirectShowOutputPin" (ERROR) ": public COggSplitterOutputPin" (:) ":" (identifier) "public" (identifier) "COggSplitterOutputPin" (compound_statement) "{\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggDirectShowOutputPin(AM_MEDIA_TYPE* pmt, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" ({) "{" (declaration) "virtual HRESULT" (type_identifier) "virtual" (identifier) "HRESULT" (;) "" (expression_statement) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);" (call_expression) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (identifier) "UnpackPacket" (argument_list) "(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (() "(" (binary_expression) "CAutoPtr<CPacket>& p" (binary_expression) "CAutoPtr<CPacket" (identifier) "CAutoPtr" (<) "<" (identifier) "CPacket" (>) ">" (pointer_expression) "& p" (&) "&" (identifier) "p" (,) "," (binary_expression) "BYTE* pData" (identifier) "BYTE" (*) "*" (identifier) "pData" (,) "," (identifier) "int" (ERROR) "len" (identifier) "len" ()) ")" (;) ";" (declaration) "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);" (type_identifier) "virtual" (ERROR) "REFERENCE_TIME" (identifier) "REFERENCE_TIME" (function_declarator) "GetRefTime(__int64 granule_position)" (identifier) "GetRefTime" (parameter_list) "(__int64 granule_position)" (() "(" (parameter_declaration) "__int64 granule_position" (type_identifier) "__int64" (identifier) "granule_position" ()) ")" (;) ";" (labeled_statement) "public:\n COggDirectShowOutputPin(AM_MEDIA_TYPE* pmt, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (expression_statement) "COggDirectShowOutputPin(AM_MEDIA_TYPE* pmt, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (call_expression) "COggDirectShowOutputPin(AM_MEDIA_TYPE* pmt, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (identifier) "COggDirectShowOutputPin" (argument_list) "(AM_MEDIA_TYPE* pmt, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (() "(" (binary_expression) "AM_MEDIA_TYPE* pmt" (identifier) "AM_MEDIA_TYPE" (*) "*" (identifier) "pmt" (,) "," (identifier) "LPCWSTR" (ERROR) "pName" (identifier) "pName" (,) "," (binary_expression) "CBaseFilter* pFilter" (identifier) "CBaseFilter" (*) "*" (identifier) "pFilter" (,) "," (binary_expression) "CCritSec* pLock" (identifier) "CCritSec" (*) "*" (identifier) "pLock" (,) "," (binary_expression) "HRESULT* phr" (identifier) "HRESULT" (*) "*" (identifier) "phr" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (function_definition) "class COggStreamOutputPin : public COggSplitterOutputPin\n{\n __int64 m_time_unit, m_samples_per_unit;\n DWORD m_default_len;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggStreamOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" (type_identifier) "class" (ERROR) "COggStreamOutputPin : public" (identifier) "COggStreamOutputPin" (:) ":" (identifier) "public" (identifier) "COggSplitterOutputPin" (compound_statement) "{\n __int64 m_time_unit, m_samples_per_unit;\n DWORD m_default_len;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggStreamOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" ({) "{" (declaration) "__int64 m_time_unit, m_samples_per_unit;" (type_identifier) "__int64" (identifier) "m_time_unit" (,) "," (identifier) "m_samples_per_unit" (;) ";" (declaration) "DWORD m_default_len;" (type_identifier) "DWORD" (identifier) "m_default_len" (;) ";" (declaration) "virtual HRESULT" (type_identifier) "virtual" (identifier) "HRESULT" (;) "" (expression_statement) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);" (call_expression) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (identifier) "UnpackPacket" (argument_list) "(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (() "(" (binary_expression) "CAutoPtr<CPacket>& p" (binary_expression) "CAutoPtr<CPacket" (identifier) "CAutoPtr" (<) "<" (identifier) "CPacket" (>) ">" (pointer_expression) "& p" (&) "&" (identifier) "p" (,) "," (binary_expression) "BYTE* pData" (identifier) "BYTE" (*) "*" (identifier) "pData" (,) "," (identifier) "int" (ERROR) "len" (identifier) "len" ()) ")" (;) ";" (declaration) "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);" (type_identifier) "virtual" (ERROR) "REFERENCE_TIME" (identifier) "REFERENCE_TIME" (function_declarator) "GetRefTime(__int64 granule_position)" (identifier) "GetRefTime" (parameter_list) "(__int64 granule_position)" (() "(" (parameter_declaration) "__int64 granule_position" (type_identifier) "__int64" (identifier) "granule_position" ()) ")" (;) ";" (labeled_statement) "public:\n COggStreamOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (expression_statement) "COggStreamOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (call_expression) "COggStreamOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (identifier) "COggStreamOutputPin" (argument_list) "(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (() "(" (binary_expression) "OggStreamHeader* h" (identifier) "OggStreamHeader" (*) "*" (identifier) "h" (,) "," (identifier) "LPCWSTR" (ERROR) "pName" (identifier) "pName" (,) "," (binary_expression) "CBaseFilter* pFilter" (identifier) "CBaseFilter" (*) "*" (identifier) "pFilter" (,) "," (binary_expression) "CCritSec* pLock" (identifier) "CCritSec" (*) "*" (identifier) "pLock" (,) "," (binary_expression) "HRESULT* phr" (identifier) "HRESULT" (*) "*" (identifier) "phr" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (function_definition) "class COggVideoOutputPin : public COggStreamOutputPin\n{\npublic:\n COggVideoOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" (type_identifier) "class" (ERROR) "COggVideoOutputPin : public" (identifier) "COggVideoOutputPin" (:) ":" (identifier) "public" (identifier) "COggStreamOutputPin" (compound_statement) "{\npublic:\n COggVideoOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" ({) "{" (labeled_statement) "public:\n COggVideoOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (expression_statement) "COggVideoOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (call_expression) "COggVideoOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (identifier) "COggVideoOutputPin" (argument_list) "(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (() "(" (binary_expression) "OggStreamHeader* h" (identifier) "OggStreamHeader" (*) "*" (identifier) "h" (,) "," (identifier) "LPCWSTR" (ERROR) "pName" (identifier) "pName" (,) "," (binary_expression) "CBaseFilter* pFilter" (identifier) "CBaseFilter" (*) "*" (identifier) "pFilter" (,) "," (binary_expression) "CCritSec* pLock" (identifier) "CCritSec" (*) "*" (identifier) "pLock" (,) "," (binary_expression) "HRESULT* phr" (identifier) "HRESULT" (*) "*" (identifier) "phr" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (function_definition) "class COggAudioOutputPin : public COggStreamOutputPin\n{\npublic:\n COggAudioOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" (type_identifier) "class" (ERROR) "COggAudioOutputPin : public" (identifier) "COggAudioOutputPin" (:) ":" (identifier) "public" (identifier) "COggStreamOutputPin" (compound_statement) "{\npublic:\n COggAudioOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" ({) "{" (labeled_statement) "public:\n COggAudioOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (expression_statement) "COggAudioOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (call_expression) "COggAudioOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (identifier) "COggAudioOutputPin" (argument_list) "(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (() "(" (binary_expression) "OggStreamHeader* h" (identifier) "OggStreamHeader" (*) "*" (identifier) "h" (,) "," (identifier) "LPCWSTR" (ERROR) "pName" (identifier) "pName" (,) "," (binary_expression) "CBaseFilter* pFilter" (identifier) "CBaseFilter" (*) "*" (identifier) "pFilter" (,) "," (binary_expression) "CCritSec* pLock" (identifier) "CCritSec" (*) "*" (identifier) "pLock" (,) "," (binary_expression) "HRESULT* phr" (identifier) "HRESULT" (*) "*" (identifier) "phr" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (function_definition) "class COggTextOutputPin : public COggStreamOutputPin\n{\npublic:\n COggTextOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" (type_identifier) "class" (ERROR) "COggTextOutputPin : public" (identifier) "COggTextOutputPin" (:) ":" (identifier) "public" (identifier) "COggStreamOutputPin" (compound_statement) "{\npublic:\n COggTextOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" ({) "{" (labeled_statement) "public:\n COggTextOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (expression_statement) "COggTextOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (call_expression) "COggTextOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (identifier) "COggTextOutputPin" (argument_list) "(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (() "(" (binary_expression) "OggStreamHeader* h" (identifier) "OggStreamHeader" (*) "*" (identifier) "h" (,) "," (identifier) "LPCWSTR" (ERROR) "pName" (identifier) "pName" (,) "," (binary_expression) "CBaseFilter* pFilter" (identifier) "CBaseFilter" (*) "*" (identifier) "pFilter" (,) "," (binary_expression) "CCritSec* pLock" (identifier) "CCritSec" (*) "*" (identifier) "pLock" (,) "," (binary_expression) "HRESULT* phr" (identifier) "HRESULT" (*) "*" (identifier) "phr" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (function_definition) "class COggKateOutputPin : public COggStreamOutputPin\n{\npublic:\n COggKateOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" (type_identifier) "class" (ERROR) "COggKateOutputPin : public" (identifier) "COggKateOutputPin" (:) ":" (identifier) "public" (identifier) "COggStreamOutputPin" (compound_statement) "{\npublic:\n COggKateOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" ({) "{" (labeled_statement) "public:\n COggKateOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (expression_statement) "COggKateOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (call_expression) "COggKateOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (identifier) "COggKateOutputPin" (argument_list) "(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (() "(" (binary_expression) "OggStreamHeader* h" (identifier) "OggStreamHeader" (*) "*" (identifier) "h" (,) "," (identifier) "LPCWSTR" (ERROR) "pName" (identifier) "pName" (,) "," (binary_expression) "CBaseFilter* pFilter" (identifier) "CBaseFilter" (*) "*" (identifier) "pFilter" (,) "," (binary_expression) "CCritSec* pLock" (identifier) "CCritSec" (*) "*" (identifier) "pLock" (,) "," (binary_expression) "HRESULT* phr" (identifier) "HRESULT" (*) "*" (identifier) "phr" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (function_definition) "class COggTheoraOutputPin : public COggSplitterOutputPin\n{\n std::list<CAutoPtr<CPacket>> m_initpackets;\n LONG m_KfgShift;\n LONG m_KfgMask;\n UINT m_nVersion;\n REFERENCE_TIME m_rtAvgTimePerFrame;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggTheoraOutputPin(OggPage& page, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n HRESULT UnpackInitPage(OggPage& page);\n bool IsInitialized() {\n return m_initpackets.size() >= 3;\n }\n}" (type_identifier) "class" (ERROR) "COggTheoraOutputPin : public" (identifier) "COggTheoraOutputPin" (:) ":" (identifier) "public" (identifier) "COggSplitterOutputPin" (compound_statement) "{\n std::list<CAutoPtr<CPacket>> m_initpackets;\n LONG m_KfgShift;\n LONG m_KfgMask;\n UINT m_nVersion;\n REFERENCE_TIME m_rtAvgTimePerFrame;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggTheoraOutputPin(OggPage& page, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n HRESULT UnpackInitPage(OggPage& page);\n bool IsInitialized() {\n return m_initpackets.size() >= 3;\n }\n}" ({) "{" (labeled_statement) "std::list<CAutoPtr<CPacket>> m_initpackets;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "list<CAutoPtr<CPacket>> m_initpackets;" (binary_expression) "list<CAutoPtr<CPacket>> m_initpackets" (binary_expression) "list<CAutoPtr" (identifier) "list" (<) "<" (identifier) "CAutoPtr" (<) "<" (binary_expression) "CPacket>> m_initpackets" (identifier) "CPacket" (>>) ">>" (identifier) "m_initpackets" (;) ";" (declaration) "LONG m_KfgShift;" (type_identifier) "LONG" (identifier) "m_KfgShift" (;) ";" (declaration) "LONG m_KfgMask;" (type_identifier) "LONG" (identifier) "m_KfgMask" (;) ";" (declaration) "UINT m_nVersion;" (type_identifier) "UINT" (identifier) "m_nVersion" (;) ";" (declaration) "REFERENCE_TIME m_rtAvgTimePerFrame;" (type_identifier) "REFERENCE_TIME" (identifier) "m_rtAvgTimePerFrame" (;) ";" (declaration) "virtual HRESULT" (type_identifier) "virtual" (identifier) "HRESULT" (;) "" (expression_statement) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);" (call_expression) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (identifier) "UnpackPacket" (argument_list) "(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (() "(" (binary_expression) "CAutoPtr<CPacket>& p" (binary_expression) "CAutoPtr<CPacket" (identifier) "CAutoPtr" (<) "<" (identifier) "CPacket" (>) ">" (pointer_expression) "& p" (&) "&" (identifier) "p" (,) "," (binary_expression) "BYTE* pData" (identifier) "BYTE" (*) "*" (identifier) "pData" (,) "," (identifier) "int" (ERROR) "len" (identifier) "len" ()) ")" (;) ";" (declaration) "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);" (type_identifier) "virtual" (ERROR) "REFERENCE_TIME" (identifier) "REFERENCE_TIME" (function_declarator) "GetRefTime(__int64 granule_position)" (identifier) "GetRefTime" (parameter_list) "(__int64 granule_position)" (() "(" (parameter_declaration) "__int64 granule_position" (type_identifier) "__int64" (identifier) "granule_position" ()) ")" (;) ";" (labeled_statement) "public:\n COggTheoraOutputPin(OggPage& page, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (expression_statement) "COggTheoraOutputPin(OggPage& page, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (call_expression) "COggTheoraOutputPin(OggPage& page, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (identifier) "COggTheoraOutputPin" (argument_list) "(OggPage& page, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (() "(" (binary_expression) "OggPage& page" (identifier) "OggPage" (&) "&" (identifier) "page" (,) "," (identifier) "LPCWSTR" (ERROR) "pName" (identifier) "pName" (,) "," (binary_expression) "CBaseFilter* pFilter" (identifier) "CBaseFilter" (*) "*" (identifier) "pFilter" (,) "," (binary_expression) "CCritSec* pLock" (identifier) "CCritSec" (*) "*" (identifier) "pLock" (,) "," (binary_expression) "HRESULT* phr" (identifier) "HRESULT" (*) "*" (identifier) "phr" ()) ")" (;) ";" (declaration) "HRESULT UnpackInitPage(OggPage& page);" (type_identifier) "HRESULT" (function_declarator) "UnpackInitPage(OggPage& page)" (identifier) "UnpackInitPage" (parameter_list) "(OggPage& page)" (() "(" (parameter_declaration) "OggPage& page" (type_identifier) "OggPage" (ERROR) "&" (&) "&" (identifier) "page" ()) ")" (;) ";" (function_definition) "bool IsInitialized() {\n return m_initpackets.size() >= 3;\n }" (primitive_type) "bool" (function_declarator) "IsInitialized()" (identifier) "IsInitialized" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n return m_initpackets.size() >= 3;\n }" ({) "{" (return_statement) "return m_initpackets.size() >= 3;" (return) "return" (binary_expression) "m_initpackets.size() >= 3" (call_expression) "m_initpackets.size()" (field_expression) "m_initpackets.size" (identifier) "m_initpackets" (.) "." (field_identifier) "size" (argument_list) "()" (() "(" ()) ")" (>=) ">=" (number_literal) "3" (;) ";" (}) "}" (}) "}" (expression_statement) ";" (;) ";" (function_definition) "class COggDiracOutputPin : public COggSplitterOutputPin\n{\n REFERENCE_TIME m_rtAvgTimePerFrame;\n bool m_bOldDirac;\n bool m_IsInitialized;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggDiracOutputPin(BYTE* p, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n HRESULT UnpackInitPage(OggPage& page);\n bool IsInitialized() {\n return m_IsInitialized;\n }\n HRESULT InitDirac(BYTE* p, int nCount);\n}" (type_identifier) "class" (ERROR) "COggDiracOutputPin : public" (identifier) "COggDiracOutputPin" (:) ":" (identifier) "public" (identifier) "COggSplitterOutputPin" (compound_statement) "{\n REFERENCE_TIME m_rtAvgTimePerFrame;\n bool m_bOldDirac;\n bool m_IsInitialized;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggDiracOutputPin(BYTE* p, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n HRESULT UnpackInitPage(OggPage& page);\n bool IsInitialized() {\n return m_IsInitialized;\n }\n HRESULT InitDirac(BYTE* p, int nCount);\n}" ({) "{" (declaration) "REFERENCE_TIME m_rtAvgTimePerFrame;" (type_identifier) "REFERENCE_TIME" (identifier) "m_rtAvgTimePerFrame" (;) ";" (declaration) "bool m_bOldDirac;" (primitive_type) "bool" (identifier) "m_bOldDirac" (;) ";" (declaration) "bool m_IsInitialized;" (primitive_type) "bool" (identifier) "m_IsInitialized" (;) ";" (declaration) "virtual HRESULT" (type_identifier) "virtual" (identifier) "HRESULT" (;) "" (expression_statement) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);" (call_expression) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (identifier) "UnpackPacket" (argument_list) "(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (() "(" (binary_expression) "CAutoPtr<CPacket>& p" (binary_expression) "CAutoPtr<CPacket" (identifier) "CAutoPtr" (<) "<" (identifier) "CPacket" (>) ">" (pointer_expression) "& p" (&) "&" (identifier) "p" (,) "," (binary_expression) "BYTE* pData" (identifier) "BYTE" (*) "*" (identifier) "pData" (,) "," (identifier) "int" (ERROR) "len" (identifier) "len" ()) ")" (;) ";" (declaration) "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);" (type_identifier) "virtual" (ERROR) "REFERENCE_TIME" (identifier) "REFERENCE_TIME" (function_declarator) "GetRefTime(__int64 granule_position)" (identifier) "GetRefTime" (parameter_list) "(__int64 granule_position)" (() "(" (parameter_declaration) "__int64 granule_position" (type_identifier) "__int64" (identifier) "granule_position" ()) ")" (;) ";" (labeled_statement) "public:\n COggDiracOutputPin(BYTE* p, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (expression_statement) "COggDiracOutputPin(BYTE* p, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (call_expression) "COggDiracOutputPin(BYTE* p, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (identifier) "COggDiracOutputPin" (argument_list) "(BYTE* p, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (() "(" (binary_expression) "BYTE* p" (identifier) "BYTE" (*) "*" (identifier) "p" (,) "," (ERROR) "int" (identifier) "int" (identifier) "nCount" (,) "," (identifier) "LPCWSTR" (ERROR) "pName" (identifier) "pName" (,) "," (binary_expression) "CBaseFilter* pFilter" (identifier) "CBaseFilter" (*) "*" (identifier) "pFilter" (,) "," (binary_expression) "CCritSec* pLock" (identifier) "CCritSec" (*) "*" (identifier) "pLock" (,) "," (binary_expression) "HRESULT* phr" (identifier) "HRESULT" (*) "*" (identifier) "phr" ()) ")" (;) ";" (declaration) "HRESULT UnpackInitPage(OggPage& page);" (type_identifier) "HRESULT" (function_declarator) "UnpackInitPage(OggPage& page)" (identifier) "UnpackInitPage" (parameter_list) "(OggPage& page)" (() "(" (parameter_declaration) "OggPage& page" (type_identifier) "OggPage" (ERROR) "&" (&) "&" (identifier) "page" ()) ")" (;) ";" (function_definition) "bool IsInitialized() {\n return m_IsInitialized;\n }" (primitive_type) "bool" (function_declarator) "IsInitialized()" (identifier) "IsInitialized" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n return m_IsInitialized;\n }" ({) "{" (return_statement) "return m_IsInitialized;" (return) "return" (identifier) "m_IsInitialized" (;) ";" (}) "}" (declaration) "HRESULT InitDirac(BYTE* p, int nCount);" (type_identifier) "HRESULT" (function_declarator) "InitDirac(BYTE* p, int nCount)" (identifier) "InitDirac" (parameter_list) "(BYTE* p, int nCount)" (() "(" (parameter_declaration) "BYTE* p" (type_identifier) "BYTE" (pointer_declarator) "* p" (*) "*" (identifier) "p" (,) "," (parameter_declaration) "int nCount" (primitive_type) "int" (identifier) "nCount" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (function_definition) "class COggOpusOutputPin : public COggSplitterOutputPin\n{\n int m_SampleRate;\n WORD m_Preskip;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggOpusOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" (type_identifier) "class" (ERROR) "COggOpusOutputPin : public" (identifier) "COggOpusOutputPin" (:) ":" (identifier) "public" (identifier) "COggSplitterOutputPin" (compound_statement) "{\n int m_SampleRate;\n WORD m_Preskip;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggOpusOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" ({) "{" (declaration) "int m_SampleRate;" (primitive_type) "int" (identifier) "m_SampleRate" (;) ";" (declaration) "WORD m_Preskip;" (type_identifier) "WORD" (identifier) "m_Preskip" (;) ";" (declaration) "virtual HRESULT" (type_identifier) "virtual" (identifier) "HRESULT" (;) "" (expression_statement) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);" (call_expression) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (identifier) "UnpackPacket" (argument_list) "(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (() "(" (binary_expression) "CAutoPtr<CPacket>& p" (binary_expression) "CAutoPtr<CPacket" (identifier) "CAutoPtr" (<) "<" (identifier) "CPacket" (>) ">" (pointer_expression) "& p" (&) "&" (identifier) "p" (,) "," (binary_expression) "BYTE* pData" (identifier) "BYTE" (*) "*" (identifier) "pData" (,) "," (identifier) "int" (ERROR) "len" (identifier) "len" ()) ")" (;) ";" (declaration) "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);" (type_identifier) "virtual" (ERROR) "REFERENCE_TIME" (identifier) "REFERENCE_TIME" (function_declarator) "GetRefTime(__int64 granule_position)" (identifier) "GetRefTime" (parameter_list) "(__int64 granule_position)" (() "(" (parameter_declaration) "__int64 granule_position" (type_identifier) "__int64" (identifier) "granule_position" ()) ")" (;) ";" (labeled_statement) "public:\n COggOpusOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (expression_statement) "COggOpusOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (call_expression) "COggOpusOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (identifier) "COggOpusOutputPin" (argument_list) "(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (() "(" (binary_expression) "BYTE* h" (identifier) "BYTE" (*) "*" (identifier) "h" (,) "," (ERROR) "int" (identifier) "int" (identifier) "nCount" (,) "," (identifier) "LPCWSTR" (ERROR) "pName" (identifier) "pName" (,) "," (binary_expression) "CBaseFilter* pFilter" (identifier) "CBaseFilter" (*) "*" (identifier) "pFilter" (,) "," (binary_expression) "CCritSec* pLock" (identifier) "CCritSec" (*) "*" (identifier) "pLock" (,) "," (binary_expression) "HRESULT* phr" (identifier) "HRESULT" (*) "*" (identifier) "phr" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (function_definition) "class COggSpeexOutputPin : public COggSplitterOutputPin\n{\n int m_SampleRate;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggSpeexOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" (type_identifier) "class" (ERROR) "COggSpeexOutputPin : public" (identifier) "COggSpeexOutputPin" (:) ":" (identifier) "public" (identifier) "COggSplitterOutputPin" (compound_statement) "{\n int m_SampleRate;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggSpeexOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" ({) "{" (declaration) "int m_SampleRate;" (primitive_type) "int" (identifier) "m_SampleRate" (;) ";" (declaration) "virtual HRESULT" (type_identifier) "virtual" (identifier) "HRESULT" (;) "" (expression_statement) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);" (call_expression) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (identifier) "UnpackPacket" (argument_list) "(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (() "(" (binary_expression) "CAutoPtr<CPacket>& p" (binary_expression) "CAutoPtr<CPacket" (identifier) "CAutoPtr" (<) "<" (identifier) "CPacket" (>) ">" (pointer_expression) "& p" (&) "&" (identifier) "p" (,) "," (binary_expression) "BYTE* pData" (identifier) "BYTE" (*) "*" (identifier) "pData" (,) "," (identifier) "int" (ERROR) "len" (identifier) "len" ()) ")" (;) ";" (declaration) "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);" (type_identifier) "virtual" (ERROR) "REFERENCE_TIME" (identifier) "REFERENCE_TIME" (function_declarator) "GetRefTime(__int64 granule_position)" (identifier) "GetRefTime" (parameter_list) "(__int64 granule_position)" (() "(" (parameter_declaration) "__int64 granule_position" (type_identifier) "__int64" (identifier) "granule_position" ()) ")" (;) ";" (labeled_statement) "public:\n COggSpeexOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (expression_statement) "COggSpeexOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (call_expression) "COggSpeexOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (identifier) "COggSpeexOutputPin" (argument_list) "(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (() "(" (binary_expression) "BYTE* h" (identifier) "BYTE" (*) "*" (identifier) "h" (,) "," (ERROR) "int" (identifier) "int" (identifier) "nCount" (,) "," (identifier) "LPCWSTR" (ERROR) "pName" (identifier) "pName" (,) "," (binary_expression) "CBaseFilter* pFilter" (identifier) "CBaseFilter" (*) "*" (identifier) "pFilter" (,) "," (binary_expression) "CCritSec* pLock" (identifier) "CCritSec" (*) "*" (identifier) "pLock" (,) "," (binary_expression) "HRESULT* phr" (identifier) "HRESULT" (*) "*" (identifier) "phr" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (function_definition) "class COggVP8OutputPin : public COggSplitterOutputPin\n{\n REFERENCE_TIME m_rtAvgTimePerFrame;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggVP8OutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" (type_identifier) "class" (ERROR) "COggVP8OutputPin : public" (identifier) "COggVP8OutputPin" (:) ":" (identifier) "public" (identifier) "COggSplitterOutputPin" (compound_statement) "{\n REFERENCE_TIME m_rtAvgTimePerFrame;\n\n virtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n virtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n COggVP8OutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}" ({) "{" (declaration) "REFERENCE_TIME m_rtAvgTimePerFrame;" (type_identifier) "REFERENCE_TIME" (identifier) "m_rtAvgTimePerFrame" (;) ";" (declaration) "virtual HRESULT" (type_identifier) "virtual" (identifier) "HRESULT" (;) "" (expression_statement) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);" (call_expression) "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (identifier) "UnpackPacket" (argument_list) "(CAutoPtr<CPacket>& p, BYTE* pData, int len)" (() "(" (binary_expression) "CAutoPtr<CPacket>& p" (binary_expression) "CAutoPtr<CPacket" (identifier) "CAutoPtr" (<) "<" (identifier) "CPacket" (>) ">" (pointer_expression) "& p" (&) "&" (identifier) "p" (,) "," (binary_expression) "BYTE* pData" (identifier) "BYTE" (*) "*" (identifier) "pData" (,) "," (identifier) "int" (ERROR) "len" (identifier) "len" ()) ")" (;) ";" (declaration) "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);" (type_identifier) "virtual" (ERROR) "REFERENCE_TIME" (identifier) "REFERENCE_TIME" (function_declarator) "GetRefTime(__int64 granule_position)" (identifier) "GetRefTime" (parameter_list) "(__int64 granule_position)" (() "(" (parameter_declaration) "__int64 granule_position" (type_identifier) "__int64" (identifier) "granule_position" ()) ")" (;) ";" (labeled_statement) "public:\n COggVP8OutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (statement_identifier) "public" (:) ":" (expression_statement) "COggVP8OutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);" (call_expression) "COggVP8OutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (identifier) "COggVP8OutputPin" (argument_list) "(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)" (() "(" (binary_expression) "BYTE* h" (identifier) "BYTE" (*) "*" (identifier) "h" (,) "," (ERROR) "int" (identifier) "int" (identifier) "nCount" (,) "," (identifier) "LPCWSTR" (ERROR) "pName" (identifier) "pName" (,) "," (binary_expression) "CBaseFilter* pFilter" (identifier) "CBaseFilter" (*) "*" (identifier) "pFilter" (,) "," (binary_expression) "CCritSec* pLock" (identifier) "CCritSec" (*) "*" (identifier) "pLock" (,) "," (binary_expression) "HRESULT* phr" (identifier) "HRESULT" (*) "*" (identifier) "phr" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (ERROR) "class __declspec(uuid("9FF48807-E133-40AA-826F-9B2959E5232D"))" (type_identifier) "class" (__declspec) "__declspec" (() "(" (identifier) "uuid" (() "(" (string_literal) ""9FF48807-E133-40AA-826F-9B2959E5232D"" (") """ (string_content) "9FF48807-E133-40AA-826F-9B2959E5232D" (") """ ()) ")" ()) ")" (labeled_statement) "COggSplitterFilter : public CBaseSplitterFilter\n{\nprotected:\n CAutoPtr<COggFile> m_pFile;\n HRESULT CreateOutputs(IAsyncReader* pAsyncReader);\n\n bool DemuxInit();\n void DemuxSeek(REFERENCE_TIME rt);\n bool DemuxLoop();\n\n DWORD m_bitstream_serial_number_start = 0;\n DWORD m_bitstream_serial_number_last = 0;\n DWORD m_bitstream_serial_number_Video = DWORD_MAX;\n\npublic:\n REFERENCE_TIME m_rtOffset = 0;\n\n COggSplitterFilter(LPUNKNOWN pUnk, HRESULT* phr);\n virtual ~COggSplitterFilter();\n\n // CBaseFilter\n\n STDMETHODIMP_(HRESULT) QueryFilterInfo(FILTER_INFO* pInfo);\n}" (statement_identifier) "COggSplitterFilter" (:) ":" (ERROR) "public CBaseSplitterFilter" (type_identifier) "public" (identifier) "CBaseSplitterFilter" (compound_statement) "{\nprotected:\n CAutoPtr<COggFile> m_pFile;\n HRESULT CreateOutputs(IAsyncReader* pAsyncReader);\n\n bool DemuxInit();\n void DemuxSeek(REFERENCE_TIME rt);\n bool DemuxLoop();\n\n DWORD m_bitstream_serial_number_start = 0;\n DWORD m_bitstream_serial_number_last = 0;\n DWORD m_bitstream_serial_number_Video = DWORD_MAX;\n\npublic:\n REFERENCE_TIME m_rtOffset = 0;\n\n COggSplitterFilter(LPUNKNOWN pUnk, HRESULT* phr);\n virtual ~COggSplitterFilter();\n\n // CBaseFilter\n\n STDMETHODIMP_(HRESULT) QueryFilterInfo(FILTER_INFO* pInfo);\n}" ({) "{" (labeled_statement) "protected:\n CAutoPtr<COggFile> m_pFile;" (statement_identifier) "protected" (:) ":" (expression_statement) "CAutoPtr<COggFile> m_pFile;" (binary_expression) "CAutoPtr<COggFile> m_pFile" (binary_expression) "CAutoPtr<COggFile" (identifier) "CAutoPtr" (<) "<" (identifier) "COggFile" (>) ">" (identifier) "m_pFile" (;) ";" (declaration) "HRESULT CreateOutputs(IAsyncReader* pAsyncReader);" (type_identifier) "HRESULT" (function_declarator) "CreateOutputs(IAsyncReader* pAsyncReader)" (identifier) "CreateOutputs" (parameter_list) "(IAsyncReader* pAsyncReader)" (() "(" (parameter_declaration) "IAsyncReader* pAsyncReader" (type_identifier) "IAsyncReader" (pointer_declarator) "* pAsyncReader" (*) "*" (identifier) "pAsyncReader" ()) ")" (;) ";" (declaration) "bool DemuxInit();" (primitive_type) "bool" (function_declarator) "DemuxInit()" (identifier) "DemuxInit" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "void DemuxSeek(REFERENCE_TIME rt);" (primitive_type) "void" (function_declarator) "DemuxSeek(REFERENCE_TIME rt)" (identifier) "DemuxSeek" (parameter_list) "(REFERENCE_TIME rt)" (() "(" (parameter_declaration) "REFERENCE_TIME rt" (type_identifier) "REFERENCE_TIME" (identifier) "rt" ()) ")" (;) ";" (declaration) "bool DemuxLoop();" (primitive_type) "bool" (function_declarator) "DemuxLoop()" (identifier) "DemuxLoop" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "DWORD m_bitstream_serial_number_start = 0;" (type_identifier) "DWORD" (init_declarator) "m_bitstream_serial_number_start = 0" (identifier) "m_bitstream_serial_number_start" (=) "=" (number_literal) "0" (;) ";" (declaration) "DWORD m_bitstream_serial_number_last = 0;" (type_identifier) "DWORD" (init_declarator) "m_bitstream_serial_number_last = 0" (identifier) "m_bitstream_serial_number_last" (=) "=" (number_literal) "0" (;) ";" (declaration) "DWORD m_bitstream_serial_number_Video = DWORD_MAX;" (type_identifier) "DWORD" (init_declarator) "m_bitstream_serial_number_Video = DWORD_MAX" (identifier) "m_bitstream_serial_number_Video" (=) "=" (identifier) "DWORD_MAX" (;) ";" (labeled_statement) "public:\n REFERENCE_TIME m_rtOffset = 0;" (statement_identifier) "public" (:) ":" (declaration) "REFERENCE_TIME m_rtOffset = 0;" (type_identifier) "REFERENCE_TIME" (init_declarator) "m_rtOffset = 0" (identifier) "m_rtOffset" (=) "=" (number_literal) "0" (;) ";" (declaration) "COggSplitterFilter(LPUNKNOWN pUnk, HRESULT* phr);" (macro_type_specifier) "COggSplitterFilter(LPUNKNOWN" (identifier) "COggSplitterFilter" (() "(" (type_descriptor) "LPUNKNOWN" (type_identifier) "LPUNKNOWN" ()) "" (identifier) "pUnk" (,) "," (ERROR) "HRESULT" (identifier) "HRESULT" (pointer_declarator) "* phr" (*) "*" (identifier) "phr" (ERROR) ")" ()) ")" (;) ";" (declaration) "virtual ~COggSplitterFilter();" (type_identifier) "virtual" (ERROR) "~" (~) "~" (function_declarator) "COggSplitterFilter()" (identifier) "COggSplitterFilter" (parameter_list) "()" (() "(" ()) ")" (;) ";" (comment) "// CBaseFilter" (declaration) "STDMETHODIMP_(HRESULT) QueryFilterInfo(FILTER_INFO* pInfo);" (macro_type_specifier) "STDMETHODIMP_(HRESULT)" (identifier) "STDMETHODIMP_" (() "(" (type_descriptor) "HRESULT" (type_identifier) "HRESULT" ()) ")" (function_declarator) "QueryFilterInfo(FILTER_INFO* pInfo)" (identifier) "QueryFilterInfo" (parameter_list) "(FILTER_INFO* pInfo)" (() "(" (parameter_declaration) "FILTER_INFO* pInfo" (type_identifier) "FILTER_INFO" (pointer_declarator) "* pInfo" (*) "*" (identifier) "pInfo" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (ERROR) "class __declspec(uuid("6D3688CE-3E9D-42F4-92CA-8A11119D25CD"))" (type_identifier) "class" (__declspec) "__declspec" (() "(" (identifier) "uuid" (() "(" (string_literal) ""6D3688CE-3E9D-42F4-92CA-8A11119D25CD"" (") """ (string_content) "6D3688CE-3E9D-42F4-92CA-8A11119D25CD" (") """ ()) ")" ()) ")" (labeled_statement) "COggSourceFilter : public COggSplitterFilter\n{\npublic:\n COggSourceFilter(LPUNKNOWN pUnk, HRESULT* phr);\n}" (statement_identifier) "COggSourceFilter" (:) ":" (ERROR) "public COggSplitterFilter" (type_identifier) "public" (identifier) "COggSplitterFilter" (compound_statement) "{\npublic:\n COggSourceFilter(LPUNKNOWN pUnk, HRESULT* phr);\n}" ({) "{" (labeled_statement) "public:\n COggSourceFilter(LPUNKNOWN pUnk, HRESULT* phr);" (statement_identifier) "public" (:) ":" (declaration) "COggSourceFilter(LPUNKNOWN pUnk, HRESULT* phr);" (macro_type_specifier) "COggSourceFilter(LPUNKNOWN" (identifier) "COggSourceFilter" (() "(" (type_descriptor) "LPUNKNOWN" (type_identifier) "LPUNKNOWN" ()) "" (identifier) "pUnk" (,) "," (ERROR) "HRESULT" (identifier) "HRESULT" (pointer_declarator) "* phr" (*) "*" (identifier) "phr" (ERROR) ")" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";"
1,757
78
{"language": "c", "success": true, "metadata": {"lines": 194, "avg_line_length": 36.88, "nodes": 1161, "errors": 0, "source_hash": "3dd9baf8d8ce7a056378952f1584c068194e0b663d5bcf463618529185258493", "categorized_nodes": 838}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#pragma once\n", "parent": null, "children": [1, 2], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 22, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#pragma", "parent": 0, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "once", "parent": 0, "children": [], "start_point": {"row": 21, "column": 8}, "end_point": {"row": 21, "column": 12}}, {"id": 3, "type": "preproc_include", "text": "#include \"OggFile.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 24, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 8}}, {"id": 5, "type": "string_literal", "text": "\"OggFile.h\"", "parent": 3, "children": [], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 20}}, {"id": 6, "type": "preproc_include", "text": "#include \"../BaseSplitter/BaseSplitter.h\"\n", "parent": null, "children": [7, 8], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 25, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"../BaseSplitter/BaseSplitter.h\"", "parent": 6, "children": [], "start_point": {"row": 24, "column": 9}, "end_point": {"row": 24, "column": 41}}, {"id": 9, "type": "preproc_def", "text": "#define OggSplitterName L\"MPC Ogg Splitter\"\n", "parent": null, "children": [10, 11, 12], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 27, "column": 0}}, {"id": 10, "type": "#define", "text": "#define", "parent": 9, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 7}}, {"id": 11, "type": "identifier", "text": "OggSplitterName", "parent": 9, "children": [], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 23}}, {"id": 12, "type": "preproc_arg", "text": "L\"MPC Ogg Splitter\"", "parent": 9, "children": [], "start_point": {"row": 26, "column": 24}, "end_point": {"row": 26, "column": 43}}, {"id": 13, "type": "preproc_def", "text": "#define OggSourceName L\"MPC Ogg Source\"\n", "parent": null, "children": [14, 15, 16], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 28, "column": 0}}, {"id": 14, "type": "#define", "text": "#define", "parent": 13, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 7}}, {"id": 15, "type": "identifier", "text": "OggSourceName", "parent": 13, "children": [], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 21}}, {"id": 16, "type": "preproc_arg", "text": "L\"MPC Ogg Source\"", "parent": 13, "children": [], "start_point": {"row": 27, "column": 24}, "end_point": {"row": 27, "column": 41}}, {"id": 17, "type": "declaration", "text": "class COggSplitterFilter;", "parent": null, "children": [18], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 25}}, {"id": 18, "type": "identifier", "text": "COggSplitterFilter", "parent": 17, "children": [], "start_point": {"row": 29, "column": 6}, "end_point": {"row": 29, "column": 24}}, {"id": 19, "type": "function_definition", "text": "class COggSplitterOutputPin : public CBaseSplitterOutputPin\n{\nprotected:\n\tstd::map<CStringW, CStringW> m_pComments;\n\n\tCPacketQueue m_queue;\n\tstd::vector<BYTE> m_lastPacketData;\n\tDWORD m_lastseqnum;\n\tREFERENCE_TIME m_rtLast;\n\tbool m_bSetKeyFrame;\n\n\tvoid ResetState(DWORD seqnum = DWORD_MAX);\n\n\tCOggSplitterFilter* m_pFilter = nullptr;\n\npublic:\n\tCOggSplitterOutputPin(LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n\tvoid AddComment(BYTE* p, int len);\n\tCStringW GetComment(CStringW key);\n\n\tvoid HandlePacket(DWORD TrackNumber, BYTE* pData, int len);\n\tHRESULT UnpackPage(OggPage& page);\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len) PURE;\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position) PURE;\n\tCAutoPtr<CPacket> GetPacket();\n\n\tHRESULT DeliverEndFlush();\n\tHRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);\n}", "parent": null, "children": [20, 22], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 60, "column": 1}}, {"id": 20, "type": "ERROR", "text": "COggSplitterOutputPin : public", "parent": 19, "children": [21], "start_point": {"row": 31, "column": 6}, "end_point": {"row": 31, "column": 36}}, {"id": 21, "type": "identifier", "text": "COggSplitterOutputPin", "parent": 20, "children": [], "start_point": {"row": 31, "column": 6}, "end_point": {"row": 31, "column": 27}}, {"id": 22, "type": "identifier", "text": "CBaseSplitterOutputPin", "parent": 19, "children": [], "start_point": {"row": 31, "column": 37}, "end_point": {"row": 31, "column": 59}}, {"id": 23, "type": "labeled_statement", "text": "protected:\n\tstd::map<CStringW, CStringW> m_pComments;", "parent": 19, "children": [24], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 34, "column": 42}}, {"id": 24, "type": "labeled_statement", "text": "std::map<CStringW, CStringW> m_pComments;", "parent": 23, "children": [25], "start_point": {"row": 34, "column": 1}, "end_point": {"row": 34, "column": 42}}, {"id": 25, "type": "statement_identifier", "text": "std", "parent": 24, "children": [], "start_point": {"row": 34, "column": 1}, "end_point": {"row": 34, "column": 4}}, {"id": 26, "type": "comma_expression", "text": "map<CStringW, CStringW> m_pComments", "parent": 24, "children": [27, 31], "start_point": {"row": 34, "column": 6}, "end_point": {"row": 34, "column": 41}}, {"id": 27, "type": "binary_expression", "text": "map<CStringW", "parent": 26, "children": [28, 29, 30], "start_point": {"row": 34, "column": 6}, "end_point": {"row": 34, "column": 18}}, {"id": 28, "type": "identifier", "text": "map", "parent": 27, "children": [], "start_point": {"row": 34, "column": 6}, "end_point": {"row": 34, "column": 9}}, {"id": 29, "type": "<", "text": "<", "parent": 27, "children": [], "start_point": {"row": 34, "column": 9}, "end_point": {"row": 34, "column": 10}}, {"id": 30, "type": "identifier", "text": "CStringW", "parent": 27, "children": [], "start_point": {"row": 34, "column": 10}, "end_point": {"row": 34, "column": 18}}, {"id": 31, "type": "binary_expression", "text": "CStringW> m_pComments", "parent": 26, "children": [32, 33, 34], "start_point": {"row": 34, "column": 20}, "end_point": {"row": 34, "column": 41}}, {"id": 32, "type": "identifier", "text": "CStringW", "parent": 31, "children": [], "start_point": {"row": 34, "column": 20}, "end_point": {"row": 34, "column": 28}}, {"id": 33, "type": ">", "text": ">", "parent": 31, "children": [], "start_point": {"row": 34, "column": 28}, "end_point": {"row": 34, "column": 29}}, {"id": 34, "type": "identifier", "text": "m_pComments", "parent": 31, "children": [], "start_point": {"row": 34, "column": 30}, "end_point": {"row": 34, "column": 41}}, {"id": 35, "type": "declaration", "text": "CPacketQueue m_queue;", "parent": 19, "children": [36, 37], "start_point": {"row": 36, "column": 1}, "end_point": {"row": 36, "column": 22}}, {"id": 36, "type": "type_identifier", "text": "CPacketQueue", "parent": 35, "children": [], "start_point": {"row": 36, "column": 1}, "end_point": {"row": 36, "column": 13}}, {"id": 37, "type": "identifier", "text": "m_queue", "parent": 35, "children": [], "start_point": {"row": 36, "column": 14}, "end_point": {"row": 36, "column": 21}}, {"id": 38, "type": "labeled_statement", "text": "std::vector<BYTE> m_lastPacketData;", "parent": 19, "children": [39], "start_point": {"row": 37, "column": 1}, "end_point": {"row": 37, "column": 36}}, {"id": 39, "type": "statement_identifier", "text": "std", "parent": 38, "children": [], "start_point": {"row": 37, "column": 1}, "end_point": {"row": 37, "column": 4}}, {"id": 40, "type": "binary_expression", "text": "vector<BYTE> m_lastPacketData", "parent": 38, "children": [41, 45, 46], "start_point": {"row": 37, "column": 6}, "end_point": {"row": 37, "column": 35}}, {"id": 41, "type": "binary_expression", "text": "vector<BYTE", "parent": 40, "children": [42, 43, 44], "start_point": {"row": 37, "column": 6}, "end_point": {"row": 37, "column": 17}}, {"id": 42, "type": "identifier", "text": "vector", "parent": 41, "children": [], "start_point": {"row": 37, "column": 6}, "end_point": {"row": 37, "column": 12}}, {"id": 43, "type": "<", "text": "<", "parent": 41, "children": [], "start_point": {"row": 37, "column": 12}, "end_point": {"row": 37, "column": 13}}, {"id": 44, "type": "identifier", "text": "BYTE", "parent": 41, "children": [], "start_point": {"row": 37, "column": 13}, "end_point": {"row": 37, "column": 17}}, {"id": 45, "type": ">", "text": ">", "parent": 40, "children": [], "start_point": {"row": 37, "column": 17}, "end_point": {"row": 37, "column": 18}}, {"id": 46, "type": "identifier", "text": "m_lastPacketData", "parent": 40, "children": [], "start_point": {"row": 37, "column": 19}, "end_point": {"row": 37, "column": 35}}, {"id": 47, "type": "declaration", "text": "DWORD m_lastseqnum;", "parent": 19, "children": [48, 49], "start_point": {"row": 38, "column": 1}, "end_point": {"row": 38, "column": 20}}, {"id": 48, "type": "type_identifier", "text": "DWORD", "parent": 47, "children": [], "start_point": {"row": 38, "column": 1}, "end_point": {"row": 38, "column": 6}}, {"id": 49, "type": "identifier", "text": "m_lastseqnum", "parent": 47, "children": [], "start_point": {"row": 38, "column": 7}, "end_point": {"row": 38, "column": 19}}, {"id": 50, "type": "declaration", "text": "REFERENCE_TIME m_rtLast;", "parent": 19, "children": [51, 52], "start_point": {"row": 39, "column": 1}, "end_point": {"row": 39, "column": 25}}, {"id": 51, "type": "type_identifier", "text": "REFERENCE_TIME", "parent": 50, "children": [], "start_point": {"row": 39, "column": 1}, "end_point": {"row": 39, "column": 15}}, {"id": 52, "type": "identifier", "text": "m_rtLast", "parent": 50, "children": [], "start_point": {"row": 39, "column": 16}, "end_point": {"row": 39, "column": 24}}, {"id": 53, "type": "declaration", "text": "bool m_bSetKeyFrame;", "parent": 19, "children": [54, 55], "start_point": {"row": 40, "column": 1}, "end_point": {"row": 40, "column": 21}}, {"id": 54, "type": "primitive_type", "text": "bool", "parent": 53, "children": [], "start_point": {"row": 40, "column": 1}, "end_point": {"row": 40, "column": 5}}, {"id": 55, "type": "identifier", "text": "m_bSetKeyFrame", "parent": 53, "children": [], "start_point": {"row": 40, "column": 6}, "end_point": {"row": 40, "column": 20}}, {"id": 56, "type": "declaration", "text": "void ResetState(DWORD seqnum = DWORD_MAX);", "parent": 19, "children": [57, 58], "start_point": {"row": 42, "column": 1}, "end_point": {"row": 42, "column": 43}}, {"id": 57, "type": "primitive_type", "text": "void", "parent": 56, "children": [], "start_point": {"row": 42, "column": 1}, "end_point": {"row": 42, "column": 5}}, {"id": 58, "type": "function_declarator", "text": "ResetState(DWORD seqnum = DWORD_MAX)", "parent": 56, "children": [59, 60], "start_point": {"row": 42, "column": 6}, "end_point": {"row": 42, "column": 42}}, {"id": 59, "type": "identifier", "text": "ResetState", "parent": 58, "children": [], "start_point": {"row": 42, "column": 6}, "end_point": {"row": 42, "column": 16}}, {"id": 60, "type": "parameter_list", "text": "(DWORD seqnum = DWORD_MAX)", "parent": 58, "children": [61], "start_point": {"row": 42, "column": 16}, "end_point": {"row": 42, "column": 42}}, {"id": 61, "type": "parameter_declaration", "text": "DWORD seqnum = DWORD_MAX", "parent": 60, "children": [62, 63, 66], "start_point": {"row": 42, "column": 17}, "end_point": {"row": 42, "column": 41}}, {"id": 62, "type": "type_identifier", "text": "DWORD", "parent": 61, "children": [], "start_point": {"row": 42, "column": 17}, "end_point": {"row": 42, "column": 22}}, {"id": 63, "type": "ERROR", "text": "seqnum =", "parent": 61, "children": [64, 65], "start_point": {"row": 42, "column": 23}, "end_point": {"row": 42, "column": 31}}, {"id": 64, "type": "identifier", "text": "seqnum", "parent": 63, "children": [], "start_point": {"row": 42, "column": 23}, "end_point": {"row": 42, "column": 29}}, {"id": 65, "type": "=", "text": "=", "parent": 63, "children": [], "start_point": {"row": 42, "column": 30}, "end_point": {"row": 42, "column": 31}}, {"id": 66, "type": "identifier", "text": "DWORD_MAX", "parent": 61, "children": [], "start_point": {"row": 42, "column": 32}, "end_point": {"row": 42, "column": 41}}, {"id": 67, "type": "declaration", "text": "COggSplitterFilter* m_pFilter = nullptr;", "parent": 19, "children": [68, 69], "start_point": {"row": 44, "column": 1}, "end_point": {"row": 44, "column": 41}}, {"id": 68, "type": "type_identifier", "text": "COggSplitterFilter", "parent": 67, "children": [], "start_point": {"row": 44, "column": 1}, "end_point": {"row": 44, "column": 19}}, {"id": 69, "type": "init_declarator", "text": "* m_pFilter = nullptr", "parent": 67, "children": [70, 73, 74], "start_point": {"row": 44, "column": 19}, "end_point": {"row": 44, "column": 40}}, {"id": 70, "type": "pointer_declarator", "text": "* m_pFilter", "parent": 69, "children": [71, 72], "start_point": {"row": 44, "column": 19}, "end_point": {"row": 44, "column": 30}}, {"id": 71, "type": "*", "text": "*", "parent": 70, "children": [], "start_point": {"row": 44, "column": 19}, "end_point": {"row": 44, "column": 20}}, {"id": 72, "type": "identifier", "text": "m_pFilter", "parent": 70, "children": [], "start_point": {"row": 44, "column": 21}, "end_point": {"row": 44, "column": 30}}, {"id": 73, "type": "=", "text": "=", "parent": 69, "children": [], "start_point": {"row": 44, "column": 31}, "end_point": {"row": 44, "column": 32}}, {"id": 74, "type": "null", "text": "nullptr", "parent": 69, "children": [75], "start_point": {"row": 44, "column": 33}, "end_point": {"row": 44, "column": 40}}, {"id": 75, "type": "nullptr", "text": "nullptr", "parent": 74, "children": [], "start_point": {"row": 44, "column": 33}, "end_point": {"row": 44, "column": 40}}, {"id": 76, "type": "labeled_statement", "text": "public:\n\tCOggSplitterOutputPin(LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 19, "children": [77], "start_point": {"row": 46, "column": 0}, "end_point": {"row": 47, "column": 91}}, {"id": 77, "type": "declaration", "text": "COggSplitterOutputPin(LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 76, "children": [78, 82, 83, 85, 88, 90, 93, 95], "start_point": {"row": 47, "column": 1}, "end_point": {"row": 47, "column": 91}}, {"id": 78, "type": "macro_type_specifier", "text": "COggSplitterOutputPin(LPCWSTR", "parent": 77, "children": [79, 80], "start_point": {"row": 47, "column": 1}, "end_point": {"row": 47, "column": 30}}, {"id": 79, "type": "identifier", "text": "COggSplitterOutputPin", "parent": 78, "children": [], "start_point": {"row": 47, "column": 1}, "end_point": {"row": 47, "column": 22}}, {"id": 80, "type": "type_descriptor", "text": "LPCWSTR", "parent": 78, "children": [81], "start_point": {"row": 47, "column": 23}, "end_point": {"row": 47, "column": 30}}, {"id": 81, "type": "type_identifier", "text": "LPCWSTR", "parent": 80, "children": [], "start_point": {"row": 47, "column": 23}, "end_point": {"row": 47, "column": 30}}, {"id": 82, "type": "identifier", "text": "pName", "parent": 77, "children": [], "start_point": {"row": 47, "column": 31}, "end_point": {"row": 47, "column": 36}}, {"id": 83, "type": "ERROR", "text": "CBaseFilter", "parent": 77, "children": [84], "start_point": {"row": 47, "column": 38}, "end_point": {"row": 47, "column": 49}}, {"id": 84, "type": "identifier", "text": "CBaseFilter", "parent": 83, "children": [], "start_point": {"row": 47, "column": 38}, "end_point": {"row": 47, "column": 49}}, {"id": 85, "type": "pointer_declarator", "text": "* pFilter", "parent": 77, "children": [86, 87], "start_point": {"row": 47, "column": 49}, "end_point": {"row": 47, "column": 58}}, {"id": 86, "type": "*", "text": "*", "parent": 85, "children": [], "start_point": {"row": 47, "column": 49}, "end_point": {"row": 47, "column": 50}}, {"id": 87, "type": "identifier", "text": "pFilter", "parent": 85, "children": [], "start_point": {"row": 47, "column": 51}, "end_point": {"row": 47, "column": 58}}, {"id": 88, "type": "ERROR", "text": "CCritSec", "parent": 77, "children": [89], "start_point": {"row": 47, "column": 60}, "end_point": {"row": 47, "column": 68}}, {"id": 89, "type": "identifier", "text": "CCritSec", "parent": 88, "children": [], "start_point": {"row": 47, "column": 60}, "end_point": {"row": 47, "column": 68}}, {"id": 90, "type": "pointer_declarator", "text": "* pLock", "parent": 77, "children": [91, 92], "start_point": {"row": 47, "column": 68}, "end_point": {"row": 47, "column": 75}}, {"id": 91, "type": "*", "text": "*", "parent": 90, "children": [], "start_point": {"row": 47, "column": 68}, "end_point": {"row": 47, "column": 69}}, {"id": 92, "type": "identifier", "text": "pLock", "parent": 90, "children": [], "start_point": {"row": 47, "column": 70}, "end_point": {"row": 47, "column": 75}}, {"id": 93, "type": "ERROR", "text": "HRESULT", "parent": 77, "children": [94], "start_point": {"row": 47, "column": 77}, "end_point": {"row": 47, "column": 84}}, {"id": 94, "type": "identifier", "text": "HRESULT", "parent": 93, "children": [], "start_point": {"row": 47, "column": 77}, "end_point": {"row": 47, "column": 84}}, {"id": 95, "type": "pointer_declarator", "text": "* phr", "parent": 77, "children": [96, 97], "start_point": {"row": 47, "column": 84}, "end_point": {"row": 47, "column": 89}}, {"id": 96, "type": "*", "text": "*", "parent": 95, "children": [], "start_point": {"row": 47, "column": 84}, "end_point": {"row": 47, "column": 85}}, {"id": 97, "type": "identifier", "text": "phr", "parent": 95, "children": [], "start_point": {"row": 47, "column": 86}, "end_point": {"row": 47, "column": 89}}, {"id": 98, "type": "declaration", "text": "void AddComment(BYTE* p, int len);", "parent": 19, "children": [99, 100], "start_point": {"row": 49, "column": 1}, "end_point": {"row": 49, "column": 35}}, {"id": 99, "type": "primitive_type", "text": "void", "parent": 98, "children": [], "start_point": {"row": 49, "column": 1}, "end_point": {"row": 49, "column": 5}}, {"id": 100, "type": "function_declarator", "text": "AddComment(BYTE* p, int len)", "parent": 98, "children": [101, 102], "start_point": {"row": 49, "column": 6}, "end_point": {"row": 49, "column": 34}}, {"id": 101, "type": "identifier", "text": "AddComment", "parent": 100, "children": [], "start_point": {"row": 49, "column": 6}, "end_point": {"row": 49, "column": 16}}, {"id": 102, "type": "parameter_list", "text": "(BYTE* p, int len)", "parent": 100, "children": [103, 108], "start_point": {"row": 49, "column": 16}, "end_point": {"row": 49, "column": 34}}, {"id": 103, "type": "parameter_declaration", "text": "BYTE* p", "parent": 102, "children": [104, 105], "start_point": {"row": 49, "column": 17}, "end_point": {"row": 49, "column": 24}}, {"id": 104, "type": "type_identifier", "text": "BYTE", "parent": 103, "children": [], "start_point": {"row": 49, "column": 17}, "end_point": {"row": 49, "column": 21}}, {"id": 105, "type": "pointer_declarator", "text": "* p", "parent": 103, "children": [106, 107], "start_point": {"row": 49, "column": 21}, "end_point": {"row": 49, "column": 24}}, {"id": 106, "type": "*", "text": "*", "parent": 105, "children": [], "start_point": {"row": 49, "column": 21}, "end_point": {"row": 49, "column": 22}}, {"id": 107, "type": "identifier", "text": "p", "parent": 105, "children": [], "start_point": {"row": 49, "column": 23}, "end_point": {"row": 49, "column": 24}}, {"id": 108, "type": "parameter_declaration", "text": "int len", "parent": 102, "children": [109, 110], "start_point": {"row": 49, "column": 26}, "end_point": {"row": 49, "column": 33}}, {"id": 109, "type": "primitive_type", "text": "int", "parent": 108, "children": [], "start_point": {"row": 49, "column": 26}, "end_point": {"row": 49, "column": 29}}, {"id": 110, "type": "identifier", "text": "len", "parent": 108, "children": [], "start_point": {"row": 49, "column": 30}, "end_point": {"row": 49, "column": 33}}, {"id": 111, "type": "declaration", "text": "CStringW GetComment(CStringW key);", "parent": 19, "children": [112, 113], "start_point": {"row": 50, "column": 1}, "end_point": {"row": 50, "column": 35}}, {"id": 112, "type": "type_identifier", "text": "CStringW", "parent": 111, "children": [], "start_point": {"row": 50, "column": 1}, "end_point": {"row": 50, "column": 9}}, {"id": 113, "type": "function_declarator", "text": "GetComment(CStringW key)", "parent": 111, "children": [114, 115], "start_point": {"row": 50, "column": 10}, "end_point": {"row": 50, "column": 34}}, {"id": 114, "type": "identifier", "text": "GetComment", "parent": 113, "children": [], "start_point": {"row": 50, "column": 10}, "end_point": {"row": 50, "column": 20}}, {"id": 115, "type": "parameter_list", "text": "(CStringW key)", "parent": 113, "children": [116], "start_point": {"row": 50, "column": 20}, "end_point": {"row": 50, "column": 34}}, {"id": 116, "type": "parameter_declaration", "text": "CStringW key", "parent": 115, "children": [117, 118], "start_point": {"row": 50, "column": 21}, "end_point": {"row": 50, "column": 33}}, {"id": 117, "type": "type_identifier", "text": "CStringW", "parent": 116, "children": [], "start_point": {"row": 50, "column": 21}, "end_point": {"row": 50, "column": 29}}, {"id": 118, "type": "identifier", "text": "key", "parent": 116, "children": [], "start_point": {"row": 50, "column": 30}, "end_point": {"row": 50, "column": 33}}, {"id": 119, "type": "declaration", "text": "void HandlePacket(DWORD TrackNumber, BYTE* pData, int len);", "parent": 19, "children": [120, 121], "start_point": {"row": 52, "column": 1}, "end_point": {"row": 52, "column": 60}}, {"id": 120, "type": "primitive_type", "text": "void", "parent": 119, "children": [], "start_point": {"row": 52, "column": 1}, "end_point": {"row": 52, "column": 5}}, {"id": 121, "type": "function_declarator", "text": "HandlePacket(DWORD TrackNumber, BYTE* pData, int len)", "parent": 119, "children": [122, 123], "start_point": {"row": 52, "column": 6}, "end_point": {"row": 52, "column": 59}}, {"id": 122, "type": "identifier", "text": "HandlePacket", "parent": 121, "children": [], "start_point": {"row": 52, "column": 6}, "end_point": {"row": 52, "column": 18}}, {"id": 123, "type": "parameter_list", "text": "(DWORD TrackNumber, BYTE* pData, int len)", "parent": 121, "children": [124, 127, 132], "start_point": {"row": 52, "column": 18}, "end_point": {"row": 52, "column": 59}}, {"id": 124, "type": "parameter_declaration", "text": "DWORD TrackNumber", "parent": 123, "children": [125, 126], "start_point": {"row": 52, "column": 19}, "end_point": {"row": 52, "column": 36}}, {"id": 125, "type": "type_identifier", "text": "DWORD", "parent": 124, "children": [], "start_point": {"row": 52, "column": 19}, "end_point": {"row": 52, "column": 24}}, {"id": 126, "type": "identifier", "text": "TrackNumber", "parent": 124, "children": [], "start_point": {"row": 52, "column": 25}, "end_point": {"row": 52, "column": 36}}, {"id": 127, "type": "parameter_declaration", "text": "BYTE* pData", "parent": 123, "children": [128, 129], "start_point": {"row": 52, "column": 38}, "end_point": {"row": 52, "column": 49}}, {"id": 128, "type": "type_identifier", "text": "BYTE", "parent": 127, "children": [], "start_point": {"row": 52, "column": 38}, "end_point": {"row": 52, "column": 42}}, {"id": 129, "type": "pointer_declarator", "text": "* pData", "parent": 127, "children": [130, 131], "start_point": {"row": 52, "column": 42}, "end_point": {"row": 52, "column": 49}}, {"id": 130, "type": "*", "text": "*", "parent": 129, "children": [], "start_point": {"row": 52, "column": 42}, "end_point": {"row": 52, "column": 43}}, {"id": 131, "type": "identifier", "text": "pData", "parent": 129, "children": [], "start_point": {"row": 52, "column": 44}, "end_point": {"row": 52, "column": 49}}, {"id": 132, "type": "parameter_declaration", "text": "int len", "parent": 123, "children": [133, 134], "start_point": {"row": 52, "column": 51}, "end_point": {"row": 52, "column": 58}}, {"id": 133, "type": "primitive_type", "text": "int", "parent": 132, "children": [], "start_point": {"row": 52, "column": 51}, "end_point": {"row": 52, "column": 54}}, {"id": 134, "type": "identifier", "text": "len", "parent": 132, "children": [], "start_point": {"row": 52, "column": 55}, "end_point": {"row": 52, "column": 58}}, {"id": 135, "type": "declaration", "text": "HRESULT UnpackPage(OggPage& page);", "parent": 19, "children": [136, 137], "start_point": {"row": 53, "column": 1}, "end_point": {"row": 53, "column": 35}}, {"id": 136, "type": "type_identifier", "text": "HRESULT", "parent": 135, "children": [], "start_point": {"row": 53, "column": 1}, "end_point": {"row": 53, "column": 8}}, {"id": 137, "type": "function_declarator", "text": "UnpackPage(OggPage& page)", "parent": 135, "children": [138, 139], "start_point": {"row": 53, "column": 9}, "end_point": {"row": 53, "column": 34}}, {"id": 138, "type": "identifier", "text": "UnpackPage", "parent": 137, "children": [], "start_point": {"row": 53, "column": 9}, "end_point": {"row": 53, "column": 19}}, {"id": 139, "type": "parameter_list", "text": "(OggPage& page)", "parent": 137, "children": [140], "start_point": {"row": 53, "column": 19}, "end_point": {"row": 53, "column": 34}}, {"id": 140, "type": "parameter_declaration", "text": "OggPage& page", "parent": 139, "children": [141, 142], "start_point": {"row": 53, "column": 20}, "end_point": {"row": 53, "column": 33}}, {"id": 141, "type": "type_identifier", "text": "OggPage", "parent": 140, "children": [], "start_point": {"row": 53, "column": 20}, "end_point": {"row": 53, "column": 27}}, {"id": 142, "type": "identifier", "text": "page", "parent": 140, "children": [], "start_point": {"row": 53, "column": 29}, "end_point": {"row": 53, "column": 33}}, {"id": 143, "type": "declaration", "text": "virtual HRESULT", "parent": 19, "children": [144, 145], "start_point": {"row": 54, "column": 1}, "end_point": {"row": 54, "column": 16}}, {"id": 144, "type": "type_identifier", "text": "virtual", "parent": 143, "children": [], "start_point": {"row": 54, "column": 1}, "end_point": {"row": 54, "column": 8}}, {"id": 145, "type": "identifier", "text": "HRESULT", "parent": 143, "children": [], "start_point": {"row": 54, "column": 9}, "end_point": {"row": 54, "column": 16}}, {"id": 146, "type": "call_expression", "text": "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 19, "children": [147, 148], "start_point": {"row": 54, "column": 17}, "end_point": {"row": 54, "column": 73}}, {"id": 147, "type": "identifier", "text": "UnpackPacket", "parent": 146, "children": [], "start_point": {"row": 54, "column": 17}, "end_point": {"row": 54, "column": 29}}, {"id": 148, "type": "argument_list", "text": "(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 146, "children": [149, 157, 161, 162], "start_point": {"row": 54, "column": 29}, "end_point": {"row": 54, "column": 73}}, {"id": 149, "type": "binary_expression", "text": "CAutoPtr<CPacket>& p", "parent": 148, "children": [150, 154, 155], "start_point": {"row": 54, "column": 30}, "end_point": {"row": 54, "column": 50}}, {"id": 150, "type": "binary_expression", "text": "CAutoPtr<CPacket", "parent": 149, "children": [151, 152, 153], "start_point": {"row": 54, "column": 30}, "end_point": {"row": 54, "column": 46}}, {"id": 151, "type": "identifier", "text": "CAutoPtr", "parent": 150, "children": [], "start_point": {"row": 54, "column": 30}, "end_point": {"row": 54, "column": 38}}, {"id": 152, "type": "<", "text": "<", "parent": 150, "children": [], "start_point": {"row": 54, "column": 38}, "end_point": {"row": 54, "column": 39}}, {"id": 153, "type": "identifier", "text": "CPacket", "parent": 150, "children": [], "start_point": {"row": 54, "column": 39}, "end_point": {"row": 54, "column": 46}}, {"id": 154, "type": ">", "text": ">", "parent": 149, "children": [], "start_point": {"row": 54, "column": 46}, "end_point": {"row": 54, "column": 47}}, {"id": 155, "type": "pointer_expression", "text": "& p", "parent": 149, "children": [156], "start_point": {"row": 54, "column": 47}, "end_point": {"row": 54, "column": 50}}, {"id": 156, "type": "identifier", "text": "p", "parent": 155, "children": [], "start_point": {"row": 54, "column": 49}, "end_point": {"row": 54, "column": 50}}, {"id": 157, "type": "binary_expression", "text": "BYTE* pData", "parent": 148, "children": [158, 159, 160], "start_point": {"row": 54, "column": 52}, "end_point": {"row": 54, "column": 63}}, {"id": 158, "type": "identifier", "text": "BYTE", "parent": 157, "children": [], "start_point": {"row": 54, "column": 52}, "end_point": {"row": 54, "column": 56}}, {"id": 159, "type": "*", "text": "*", "parent": 157, "children": [], "start_point": {"row": 54, "column": 56}, "end_point": {"row": 54, "column": 57}}, {"id": 160, "type": "identifier", "text": "pData", "parent": 157, "children": [], "start_point": {"row": 54, "column": 58}, "end_point": {"row": 54, "column": 63}}, {"id": 161, "type": "identifier", "text": "int", "parent": 148, "children": [], "start_point": {"row": 54, "column": 65}, "end_point": {"row": 54, "column": 68}}, {"id": 162, "type": "ERROR", "text": "len", "parent": 148, "children": [163], "start_point": {"row": 54, "column": 69}, "end_point": {"row": 54, "column": 72}}, {"id": 163, "type": "identifier", "text": "len", "parent": 162, "children": [], "start_point": {"row": 54, "column": 69}, "end_point": {"row": 54, "column": 72}}, {"id": 164, "type": "ERROR", "text": "PURE", "parent": 19, "children": [165], "start_point": {"row": 54, "column": 74}, "end_point": {"row": 54, "column": 78}}, {"id": 165, "type": "identifier", "text": "PURE", "parent": 164, "children": [], "start_point": {"row": 54, "column": 74}, "end_point": {"row": 54, "column": 78}}, {"id": 166, "type": "ERROR", "text": "virtual REFERENCE_TIME GetRefTime(__int64 granule_position) PURE", "parent": 19, "children": [167, 168, 170], "start_point": {"row": 55, "column": 1}, "end_point": {"row": 55, "column": 65}}, {"id": 167, "type": "type_identifier", "text": "virtual", "parent": 166, "children": [], "start_point": {"row": 55, "column": 1}, "end_point": {"row": 55, "column": 8}}, {"id": 168, "type": "ERROR", "text": "REFERENCE_TIME", "parent": 166, "children": [169], "start_point": {"row": 55, "column": 9}, "end_point": {"row": 55, "column": 23}}, {"id": 169, "type": "identifier", "text": "REFERENCE_TIME", "parent": 168, "children": [], "start_point": {"row": 55, "column": 9}, "end_point": {"row": 55, "column": 23}}, {"id": 170, "type": "function_declarator", "text": "GetRefTime(__int64 granule_position) PURE", "parent": 166, "children": [171, 172, 176], "start_point": {"row": 55, "column": 24}, "end_point": {"row": 55, "column": 65}}, {"id": 171, "type": "identifier", "text": "GetRefTime", "parent": 170, "children": [], "start_point": {"row": 55, "column": 24}, "end_point": {"row": 55, "column": 34}}, {"id": 172, "type": "parameter_list", "text": "(__int64 granule_position)", "parent": 170, "children": [173], "start_point": {"row": 55, "column": 34}, "end_point": {"row": 55, "column": 60}}, {"id": 173, "type": "parameter_declaration", "text": "__int64 granule_position", "parent": 172, "children": [174, 175], "start_point": {"row": 55, "column": 35}, "end_point": {"row": 55, "column": 59}}, {"id": 174, "type": "type_identifier", "text": "__int64", "parent": 173, "children": [], "start_point": {"row": 55, "column": 35}, "end_point": {"row": 55, "column": 42}}, {"id": 175, "type": "identifier", "text": "granule_position", "parent": 173, "children": [], "start_point": {"row": 55, "column": 43}, "end_point": {"row": 55, "column": 59}}, {"id": 176, "type": "identifier", "text": "PURE", "parent": 170, "children": [], "start_point": {"row": 55, "column": 61}, "end_point": {"row": 55, "column": 65}}, {"id": 177, "type": "binary_expression", "text": "CAutoPtr<CPacket> GetPacket()", "parent": 19, "children": [178, 182, 183], "start_point": {"row": 56, "column": 1}, "end_point": {"row": 56, "column": 30}}, {"id": 178, "type": "binary_expression", "text": "CAutoPtr<CPacket", "parent": 177, "children": [179, 180, 181], "start_point": {"row": 56, "column": 1}, "end_point": {"row": 56, "column": 17}}, {"id": 179, "type": "identifier", "text": "CAutoPtr", "parent": 178, "children": [], "start_point": {"row": 56, "column": 1}, "end_point": {"row": 56, "column": 9}}, {"id": 180, "type": "<", "text": "<", "parent": 178, "children": [], "start_point": {"row": 56, "column": 9}, "end_point": {"row": 56, "column": 10}}, {"id": 181, "type": "identifier", "text": "CPacket", "parent": 178, "children": [], "start_point": {"row": 56, "column": 10}, "end_point": {"row": 56, "column": 17}}, {"id": 182, "type": ">", "text": ">", "parent": 177, "children": [], "start_point": {"row": 56, "column": 17}, "end_point": {"row": 56, "column": 18}}, {"id": 183, "type": "call_expression", "text": "GetPacket()", "parent": 177, "children": [184, 185], "start_point": {"row": 56, "column": 19}, "end_point": {"row": 56, "column": 30}}, {"id": 184, "type": "identifier", "text": "GetPacket", "parent": 183, "children": [], "start_point": {"row": 56, "column": 19}, "end_point": {"row": 56, "column": 28}}, {"id": 185, "type": "argument_list", "text": "()", "parent": 183, "children": [], "start_point": {"row": 56, "column": 28}, "end_point": {"row": 56, "column": 30}}, {"id": 186, "type": "declaration", "text": "HRESULT DeliverEndFlush();", "parent": 19, "children": [187, 188], "start_point": {"row": 58, "column": 1}, "end_point": {"row": 58, "column": 27}}, {"id": 187, "type": "type_identifier", "text": "HRESULT", "parent": 186, "children": [], "start_point": {"row": 58, "column": 1}, "end_point": {"row": 58, "column": 8}}, {"id": 188, "type": "function_declarator", "text": "DeliverEndFlush()", "parent": 186, "children": [189, 190], "start_point": {"row": 58, "column": 9}, "end_point": {"row": 58, "column": 26}}, {"id": 189, "type": "identifier", "text": "DeliverEndFlush", "parent": 188, "children": [], "start_point": {"row": 58, "column": 9}, "end_point": {"row": 58, "column": 24}}, {"id": 190, "type": "parameter_list", "text": "()", "parent": 188, "children": [], "start_point": {"row": 58, "column": 24}, "end_point": {"row": 58, "column": 26}}, {"id": 191, "type": "declaration", "text": "HRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);", "parent": 19, "children": [192, 193], "start_point": {"row": 59, "column": 1}, "end_point": {"row": 59, "column": 86}}, {"id": 192, "type": "type_identifier", "text": "HRESULT", "parent": 191, "children": [], "start_point": {"row": 59, "column": 1}, "end_point": {"row": 59, "column": 8}}, {"id": 193, "type": "function_declarator", "text": "DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate)", "parent": 191, "children": [194, 195], "start_point": {"row": 59, "column": 9}, "end_point": {"row": 59, "column": 85}}, {"id": 194, "type": "identifier", "text": "DeliverNewSegment", "parent": 193, "children": [], "start_point": {"row": 59, "column": 9}, "end_point": {"row": 59, "column": 26}}, {"id": 195, "type": "parameter_list", "text": "(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate)", "parent": 193, "children": [196, 199, 202], "start_point": {"row": 59, "column": 26}, "end_point": {"row": 59, "column": 85}}, {"id": 196, "type": "parameter_declaration", "text": "REFERENCE_TIME tStart", "parent": 195, "children": [197, 198], "start_point": {"row": 59, "column": 27}, "end_point": {"row": 59, "column": 48}}, {"id": 197, "type": "type_identifier", "text": "REFERENCE_TIME", "parent": 196, "children": [], "start_point": {"row": 59, "column": 27}, "end_point": {"row": 59, "column": 41}}, {"id": 198, "type": "identifier", "text": "tStart", "parent": 196, "children": [], "start_point": {"row": 59, "column": 42}, "end_point": {"row": 59, "column": 48}}, {"id": 199, "type": "parameter_declaration", "text": "REFERENCE_TIME tStop", "parent": 195, "children": [200, 201], "start_point": {"row": 59, "column": 50}, "end_point": {"row": 59, "column": 70}}, {"id": 200, "type": "type_identifier", "text": "REFERENCE_TIME", "parent": 199, "children": [], "start_point": {"row": 59, "column": 50}, "end_point": {"row": 59, "column": 64}}, {"id": 201, "type": "identifier", "text": "tStop", "parent": 199, "children": [], "start_point": {"row": 59, "column": 65}, "end_point": {"row": 59, "column": 70}}, {"id": 202, "type": "parameter_declaration", "text": "double dRate", "parent": 195, "children": [203, 204], "start_point": {"row": 59, "column": 72}, "end_point": {"row": 59, "column": 84}}, {"id": 203, "type": "primitive_type", "text": "double", "parent": 202, "children": [], "start_point": {"row": 59, "column": 72}, "end_point": {"row": 59, "column": 78}}, {"id": 204, "type": "identifier", "text": "dRate", "parent": 202, "children": [], "start_point": {"row": 59, "column": 79}, "end_point": {"row": 59, "column": 84}}, {"id": 205, "type": "function_definition", "text": "class COggVorbisOutputPin : public COggSplitterOutputPin\n{\n\tstd::list<CAutoPtr<CPacket>> m_initpackets;\n\n\tDWORD m_audio_sample_rate;\n\tDWORD m_blocksize[2], m_lastblocksize;\n\tstd::vector<bool> m_blockflags;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\n\tHRESULT DeliverPacket(CAutoPtr<CPacket> p);\n\tHRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);\n\npublic:\n\tCOggVorbisOutputPin(OggVorbisIdHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n\tHRESULT UnpackInitPage(OggPage& page);\n\tbool IsInitialized() {\n\t\treturn m_initpackets.size() >= 3;\n\t}\n}", "parent": null, "children": [206, 208], "start_point": {"row": 62, "column": 0}, "end_point": {"row": 83, "column": 1}}, {"id": 206, "type": "ERROR", "text": "COggVorbisOutputPin : public", "parent": 205, "children": [207], "start_point": {"row": 62, "column": 6}, "end_point": {"row": 62, "column": 34}}, {"id": 207, "type": "identifier", "text": "COggVorbisOutputPin", "parent": 206, "children": [], "start_point": {"row": 62, "column": 6}, "end_point": {"row": 62, "column": 25}}, {"id": 208, "type": "identifier", "text": "COggSplitterOutputPin", "parent": 205, "children": [], "start_point": {"row": 62, "column": 35}, "end_point": {"row": 62, "column": 56}}, {"id": 209, "type": "labeled_statement", "text": "std::list<CAutoPtr<CPacket>> m_initpackets;", "parent": 205, "children": [210], "start_point": {"row": 64, "column": 1}, "end_point": {"row": 64, "column": 44}}, {"id": 210, "type": "statement_identifier", "text": "std", "parent": 209, "children": [], "start_point": {"row": 64, "column": 1}, "end_point": {"row": 64, "column": 4}}, {"id": 211, "type": "binary_expression", "text": "list<CAutoPtr<CPacket>> m_initpackets", "parent": 209, "children": [212, 216, 217], "start_point": {"row": 64, "column": 6}, "end_point": {"row": 64, "column": 43}}, {"id": 212, "type": "binary_expression", "text": "list<CAutoPtr", "parent": 211, "children": [213, 214, 215], "start_point": {"row": 64, "column": 6}, "end_point": {"row": 64, "column": 19}}, {"id": 213, "type": "identifier", "text": "list", "parent": 212, "children": [], "start_point": {"row": 64, "column": 6}, "end_point": {"row": 64, "column": 10}}, {"id": 214, "type": "<", "text": "<", "parent": 212, "children": [], "start_point": {"row": 64, "column": 10}, "end_point": {"row": 64, "column": 11}}, {"id": 215, "type": "identifier", "text": "CAutoPtr", "parent": 212, "children": [], "start_point": {"row": 64, "column": 11}, "end_point": {"row": 64, "column": 19}}, {"id": 216, "type": "<", "text": "<", "parent": 211, "children": [], "start_point": {"row": 64, "column": 19}, "end_point": {"row": 64, "column": 20}}, {"id": 217, "type": "binary_expression", "text": "CPacket>> m_initpackets", "parent": 211, "children": [218, 219, 220], "start_point": {"row": 64, "column": 20}, "end_point": {"row": 64, "column": 43}}, {"id": 218, "type": "identifier", "text": "CPacket", "parent": 217, "children": [], "start_point": {"row": 64, "column": 20}, "end_point": {"row": 64, "column": 27}}, {"id": 219, "type": ">>", "text": ">>", "parent": 217, "children": [], "start_point": {"row": 64, "column": 27}, "end_point": {"row": 64, "column": 29}}, {"id": 220, "type": "identifier", "text": "m_initpackets", "parent": 217, "children": [], "start_point": {"row": 64, "column": 30}, "end_point": {"row": 64, "column": 43}}, {"id": 221, "type": "declaration", "text": "DWORD m_audio_sample_rate;", "parent": 205, "children": [222, 223], "start_point": {"row": 66, "column": 1}, "end_point": {"row": 66, "column": 27}}, {"id": 222, "type": "type_identifier", "text": "DWORD", "parent": 221, "children": [], "start_point": {"row": 66, "column": 1}, "end_point": {"row": 66, "column": 6}}, {"id": 223, "type": "identifier", "text": "m_audio_sample_rate", "parent": 221, "children": [], "start_point": {"row": 66, "column": 7}, "end_point": {"row": 66, "column": 26}}, {"id": 224, "type": "declaration", "text": "DWORD m_blocksize[2], m_lastblocksize;", "parent": 205, "children": [225, 226, 229], "start_point": {"row": 67, "column": 1}, "end_point": {"row": 67, "column": 39}}, {"id": 225, "type": "type_identifier", "text": "DWORD", "parent": 224, "children": [], "start_point": {"row": 67, "column": 1}, "end_point": {"row": 67, "column": 6}}, {"id": 226, "type": "array_declarator", "text": "m_blocksize[2]", "parent": 224, "children": [227, 228], "start_point": {"row": 67, "column": 7}, "end_point": {"row": 67, "column": 21}}, {"id": 227, "type": "identifier", "text": "m_blocksize", "parent": 226, "children": [], "start_point": {"row": 67, "column": 7}, "end_point": {"row": 67, "column": 18}}, {"id": 228, "type": "number_literal", "text": "2", "parent": 226, "children": [], "start_point": {"row": 67, "column": 19}, "end_point": {"row": 67, "column": 20}}, {"id": 229, "type": "identifier", "text": "m_lastblocksize", "parent": 224, "children": [], "start_point": {"row": 67, "column": 23}, "end_point": {"row": 67, "column": 38}}, {"id": 230, "type": "labeled_statement", "text": "std::vector<bool> m_blockflags;", "parent": 205, "children": [231], "start_point": {"row": 68, "column": 1}, "end_point": {"row": 68, "column": 32}}, {"id": 231, "type": "statement_identifier", "text": "std", "parent": 230, "children": [], "start_point": {"row": 68, "column": 1}, "end_point": {"row": 68, "column": 4}}, {"id": 232, "type": "binary_expression", "text": "vector<bool> m_blockflags", "parent": 230, "children": [233, 237, 238], "start_point": {"row": 68, "column": 6}, "end_point": {"row": 68, "column": 31}}, {"id": 233, "type": "binary_expression", "text": "vector<bool", "parent": 232, "children": [234, 235, 236], "start_point": {"row": 68, "column": 6}, "end_point": {"row": 68, "column": 17}}, {"id": 234, "type": "identifier", "text": "vector", "parent": 233, "children": [], "start_point": {"row": 68, "column": 6}, "end_point": {"row": 68, "column": 12}}, {"id": 235, "type": "<", "text": "<", "parent": 233, "children": [], "start_point": {"row": 68, "column": 12}, "end_point": {"row": 68, "column": 13}}, {"id": 236, "type": "identifier", "text": "bool", "parent": 233, "children": [], "start_point": {"row": 68, "column": 13}, "end_point": {"row": 68, "column": 17}}, {"id": 237, "type": ">", "text": ">", "parent": 232, "children": [], "start_point": {"row": 68, "column": 17}, "end_point": {"row": 68, "column": 18}}, {"id": 238, "type": "identifier", "text": "m_blockflags", "parent": 232, "children": [], "start_point": {"row": 68, "column": 19}, "end_point": {"row": 68, "column": 31}}, {"id": 239, "type": "declaration", "text": "virtual HRESULT", "parent": 205, "children": [240, 241], "start_point": {"row": 70, "column": 1}, "end_point": {"row": 70, "column": 16}}, {"id": 240, "type": "type_identifier", "text": "virtual", "parent": 239, "children": [], "start_point": {"row": 70, "column": 1}, "end_point": {"row": 70, "column": 8}}, {"id": 241, "type": "identifier", "text": "HRESULT", "parent": 239, "children": [], "start_point": {"row": 70, "column": 9}, "end_point": {"row": 70, "column": 16}}, {"id": 242, "type": "call_expression", "text": "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 205, "children": [243, 244], "start_point": {"row": 70, "column": 17}, "end_point": {"row": 70, "column": 73}}, {"id": 243, "type": "identifier", "text": "UnpackPacket", "parent": 242, "children": [], "start_point": {"row": 70, "column": 17}, "end_point": {"row": 70, "column": 29}}, {"id": 244, "type": "argument_list", "text": "(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 242, "children": [245, 253, 257, 258], "start_point": {"row": 70, "column": 29}, "end_point": {"row": 70, "column": 73}}, {"id": 245, "type": "binary_expression", "text": "CAutoPtr<CPacket>& p", "parent": 244, "children": [246, 250, 251], "start_point": {"row": 70, "column": 30}, "end_point": {"row": 70, "column": 50}}, {"id": 246, "type": "binary_expression", "text": "CAutoPtr<CPacket", "parent": 245, "children": [247, 248, 249], "start_point": {"row": 70, "column": 30}, "end_point": {"row": 70, "column": 46}}, {"id": 247, "type": "identifier", "text": "CAutoPtr", "parent": 246, "children": [], "start_point": {"row": 70, "column": 30}, "end_point": {"row": 70, "column": 38}}, {"id": 248, "type": "<", "text": "<", "parent": 246, "children": [], "start_point": {"row": 70, "column": 38}, "end_point": {"row": 70, "column": 39}}, {"id": 249, "type": "identifier", "text": "CPacket", "parent": 246, "children": [], "start_point": {"row": 70, "column": 39}, "end_point": {"row": 70, "column": 46}}, {"id": 250, "type": ">", "text": ">", "parent": 245, "children": [], "start_point": {"row": 70, "column": 46}, "end_point": {"row": 70, "column": 47}}, {"id": 251, "type": "pointer_expression", "text": "& p", "parent": 245, "children": [252], "start_point": {"row": 70, "column": 47}, "end_point": {"row": 70, "column": 50}}, {"id": 252, "type": "identifier", "text": "p", "parent": 251, "children": [], "start_point": {"row": 70, "column": 49}, "end_point": {"row": 70, "column": 50}}, {"id": 253, "type": "binary_expression", "text": "BYTE* pData", "parent": 244, "children": [254, 255, 256], "start_point": {"row": 70, "column": 52}, "end_point": {"row": 70, "column": 63}}, {"id": 254, "type": "identifier", "text": "BYTE", "parent": 253, "children": [], "start_point": {"row": 70, "column": 52}, "end_point": {"row": 70, "column": 56}}, {"id": 255, "type": "*", "text": "*", "parent": 253, "children": [], "start_point": {"row": 70, "column": 56}, "end_point": {"row": 70, "column": 57}}, {"id": 256, "type": "identifier", "text": "pData", "parent": 253, "children": [], "start_point": {"row": 70, "column": 58}, "end_point": {"row": 70, "column": 63}}, {"id": 257, "type": "identifier", "text": "int", "parent": 244, "children": [], "start_point": {"row": 70, "column": 65}, "end_point": {"row": 70, "column": 68}}, {"id": 258, "type": "ERROR", "text": "len", "parent": 244, "children": [259], "start_point": {"row": 70, "column": 69}, "end_point": {"row": 70, "column": 72}}, {"id": 259, "type": "identifier", "text": "len", "parent": 258, "children": [], "start_point": {"row": 70, "column": 69}, "end_point": {"row": 70, "column": 72}}, {"id": 260, "type": "declaration", "text": "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);", "parent": 205, "children": [261, 262, 264], "start_point": {"row": 71, "column": 1}, "end_point": {"row": 71, "column": 61}}, {"id": 261, "type": "type_identifier", "text": "virtual", "parent": 260, "children": [], "start_point": {"row": 71, "column": 1}, "end_point": {"row": 71, "column": 8}}, {"id": 262, "type": "ERROR", "text": "REFERENCE_TIME", "parent": 260, "children": [263], "start_point": {"row": 71, "column": 9}, "end_point": {"row": 71, "column": 23}}, {"id": 263, "type": "identifier", "text": "REFERENCE_TIME", "parent": 262, "children": [], "start_point": {"row": 71, "column": 9}, "end_point": {"row": 71, "column": 23}}, {"id": 264, "type": "function_declarator", "text": "GetRefTime(__int64 granule_position)", "parent": 260, "children": [265, 266], "start_point": {"row": 71, "column": 24}, "end_point": {"row": 71, "column": 60}}, {"id": 265, "type": "identifier", "text": "GetRefTime", "parent": 264, "children": [], "start_point": {"row": 71, "column": 24}, "end_point": {"row": 71, "column": 34}}, {"id": 266, "type": "parameter_list", "text": "(__int64 granule_position)", "parent": 264, "children": [267], "start_point": {"row": 71, "column": 34}, "end_point": {"row": 71, "column": 60}}, {"id": 267, "type": "parameter_declaration", "text": "__int64 granule_position", "parent": 266, "children": [268, 269], "start_point": {"row": 71, "column": 35}, "end_point": {"row": 71, "column": 59}}, {"id": 268, "type": "type_identifier", "text": "__int64", "parent": 267, "children": [], "start_point": {"row": 71, "column": 35}, "end_point": {"row": 71, "column": 42}}, {"id": 269, "type": "identifier", "text": "granule_position", "parent": 267, "children": [], "start_point": {"row": 71, "column": 43}, "end_point": {"row": 71, "column": 59}}, {"id": 270, "type": "declaration", "text": "HRESULT DeliverPacket(CAutoPtr<CPacket> p);", "parent": 205, "children": [271, 272], "start_point": {"row": 73, "column": 1}, "end_point": {"row": 73, "column": 44}}, {"id": 271, "type": "type_identifier", "text": "HRESULT", "parent": 270, "children": [], "start_point": {"row": 73, "column": 1}, "end_point": {"row": 73, "column": 8}}, {"id": 272, "type": "function_declarator", "text": "DeliverPacket(CAutoPtr<CPacket> p)", "parent": 270, "children": [273, 274], "start_point": {"row": 73, "column": 9}, "end_point": {"row": 73, "column": 43}}, {"id": 273, "type": "identifier", "text": "DeliverPacket", "parent": 272, "children": [], "start_point": {"row": 73, "column": 9}, "end_point": {"row": 73, "column": 22}}, {"id": 274, "type": "parameter_list", "text": "(CAutoPtr<CPacket> p)", "parent": 272, "children": [275], "start_point": {"row": 73, "column": 22}, "end_point": {"row": 73, "column": 43}}, {"id": 275, "type": "parameter_declaration", "text": "CAutoPtr<CPacket> p", "parent": 274, "children": [276, 277, 281], "start_point": {"row": 73, "column": 23}, "end_point": {"row": 73, "column": 42}}, {"id": 276, "type": "type_identifier", "text": "CAutoPtr", "parent": 275, "children": [], "start_point": {"row": 73, "column": 23}, "end_point": {"row": 73, "column": 31}}, {"id": 277, "type": "ERROR", "text": "<CPacket>", "parent": 275, "children": [278, 279, 280], "start_point": {"row": 73, "column": 31}, "end_point": {"row": 73, "column": 40}}, {"id": 278, "type": "<", "text": "<", "parent": 277, "children": [], "start_point": {"row": 73, "column": 31}, "end_point": {"row": 73, "column": 32}}, {"id": 279, "type": "identifier", "text": "CPacket", "parent": 277, "children": [], "start_point": {"row": 73, "column": 32}, "end_point": {"row": 73, "column": 39}}, {"id": 280, "type": ">", "text": ">", "parent": 277, "children": [], "start_point": {"row": 73, "column": 39}, "end_point": {"row": 73, "column": 40}}, {"id": 281, "type": "identifier", "text": "p", "parent": 275, "children": [], "start_point": {"row": 73, "column": 41}, "end_point": {"row": 73, "column": 42}}, {"id": 282, "type": "declaration", "text": "HRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);", "parent": 205, "children": [283, 284], "start_point": {"row": 74, "column": 1}, "end_point": {"row": 74, "column": 86}}, {"id": 283, "type": "type_identifier", "text": "HRESULT", "parent": 282, "children": [], "start_point": {"row": 74, "column": 1}, "end_point": {"row": 74, "column": 8}}, {"id": 284, "type": "function_declarator", "text": "DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate)", "parent": 282, "children": [285, 286], "start_point": {"row": 74, "column": 9}, "end_point": {"row": 74, "column": 85}}, {"id": 285, "type": "identifier", "text": "DeliverNewSegment", "parent": 284, "children": [], "start_point": {"row": 74, "column": 9}, "end_point": {"row": 74, "column": 26}}, {"id": 286, "type": "parameter_list", "text": "(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate)", "parent": 284, "children": [287, 290, 293], "start_point": {"row": 74, "column": 26}, "end_point": {"row": 74, "column": 85}}, {"id": 287, "type": "parameter_declaration", "text": "REFERENCE_TIME tStart", "parent": 286, "children": [288, 289], "start_point": {"row": 74, "column": 27}, "end_point": {"row": 74, "column": 48}}, {"id": 288, "type": "type_identifier", "text": "REFERENCE_TIME", "parent": 287, "children": [], "start_point": {"row": 74, "column": 27}, "end_point": {"row": 74, "column": 41}}, {"id": 289, "type": "identifier", "text": "tStart", "parent": 287, "children": [], "start_point": {"row": 74, "column": 42}, "end_point": {"row": 74, "column": 48}}, {"id": 290, "type": "parameter_declaration", "text": "REFERENCE_TIME tStop", "parent": 286, "children": [291, 292], "start_point": {"row": 74, "column": 50}, "end_point": {"row": 74, "column": 70}}, {"id": 291, "type": "type_identifier", "text": "REFERENCE_TIME", "parent": 290, "children": [], "start_point": {"row": 74, "column": 50}, "end_point": {"row": 74, "column": 64}}, {"id": 292, "type": "identifier", "text": "tStop", "parent": 290, "children": [], "start_point": {"row": 74, "column": 65}, "end_point": {"row": 74, "column": 70}}, {"id": 293, "type": "parameter_declaration", "text": "double dRate", "parent": 286, "children": [294, 295], "start_point": {"row": 74, "column": 72}, "end_point": {"row": 74, "column": 84}}, {"id": 294, "type": "primitive_type", "text": "double", "parent": 293, "children": [], "start_point": {"row": 74, "column": 72}, "end_point": {"row": 74, "column": 78}}, {"id": 295, "type": "identifier", "text": "dRate", "parent": 293, "children": [], "start_point": {"row": 74, "column": 79}, "end_point": {"row": 74, "column": 84}}, {"id": 296, "type": "labeled_statement", "text": "public:\n\tCOggVorbisOutputPin(OggVorbisIdHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 205, "children": [], "start_point": {"row": 76, "column": 0}, "end_point": {"row": 77, "column": 111}}, {"id": 297, "type": "call_expression", "text": "COggVorbisOutputPin(OggVorbisIdHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 296, "children": [298, 299], "start_point": {"row": 77, "column": 1}, "end_point": {"row": 77, "column": 110}}, {"id": 298, "type": "identifier", "text": "COggVorbisOutputPin", "parent": 297, "children": [], "start_point": {"row": 77, "column": 1}, "end_point": {"row": 77, "column": 20}}, {"id": 299, "type": "argument_list", "text": "(OggVorbisIdHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 297, "children": [300, 304, 305, 307, 311, 315], "start_point": {"row": 77, "column": 20}, "end_point": {"row": 77, "column": 110}}, {"id": 300, "type": "binary_expression", "text": "OggVorbisIdHeader* h", "parent": 299, "children": [301, 302, 303], "start_point": {"row": 77, "column": 21}, "end_point": {"row": 77, "column": 41}}, {"id": 301, "type": "identifier", "text": "OggVorbisIdHeader", "parent": 300, "children": [], "start_point": {"row": 77, "column": 21}, "end_point": {"row": 77, "column": 38}}, {"id": 302, "type": "*", "text": "*", "parent": 300, "children": [], "start_point": {"row": 77, "column": 38}, "end_point": {"row": 77, "column": 39}}, {"id": 303, "type": "identifier", "text": "h", "parent": 300, "children": [], "start_point": {"row": 77, "column": 40}, "end_point": {"row": 77, "column": 41}}, {"id": 304, "type": "identifier", "text": "LPCWSTR", "parent": 299, "children": [], "start_point": {"row": 77, "column": 43}, "end_point": {"row": 77, "column": 50}}, {"id": 305, "type": "ERROR", "text": "pName", "parent": 299, "children": [306], "start_point": {"row": 77, "column": 51}, "end_point": {"row": 77, "column": 56}}, {"id": 306, "type": "identifier", "text": "pName", "parent": 305, "children": [], "start_point": {"row": 77, "column": 51}, "end_point": {"row": 77, "column": 56}}, {"id": 307, "type": "binary_expression", "text": "CBaseFilter* pFilter", "parent": 299, "children": [308, 309, 310], "start_point": {"row": 77, "column": 58}, "end_point": {"row": 77, "column": 78}}, {"id": 308, "type": "identifier", "text": "CBaseFilter", "parent": 307, "children": [], "start_point": {"row": 77, "column": 58}, "end_point": {"row": 77, "column": 69}}, {"id": 309, "type": "*", "text": "*", "parent": 307, "children": [], "start_point": {"row": 77, "column": 69}, "end_point": {"row": 77, "column": 70}}, {"id": 310, "type": "identifier", "text": "pFilter", "parent": 307, "children": [], "start_point": {"row": 77, "column": 71}, "end_point": {"row": 77, "column": 78}}, {"id": 311, "type": "binary_expression", "text": "CCritSec* pLock", "parent": 299, "children": [312, 313, 314], "start_point": {"row": 77, "column": 80}, "end_point": {"row": 77, "column": 95}}, {"id": 312, "type": "identifier", "text": "CCritSec", "parent": 311, "children": [], "start_point": {"row": 77, "column": 80}, "end_point": {"row": 77, "column": 88}}, {"id": 313, "type": "*", "text": "*", "parent": 311, "children": [], "start_point": {"row": 77, "column": 88}, "end_point": {"row": 77, "column": 89}}, {"id": 314, "type": "identifier", "text": "pLock", "parent": 311, "children": [], "start_point": {"row": 77, "column": 90}, "end_point": {"row": 77, "column": 95}}, {"id": 315, "type": "binary_expression", "text": "HRESULT* phr", "parent": 299, "children": [316, 317, 318], "start_point": {"row": 77, "column": 97}, "end_point": {"row": 77, "column": 109}}, {"id": 316, "type": "identifier", "text": "HRESULT", "parent": 315, "children": [], "start_point": {"row": 77, "column": 97}, "end_point": {"row": 77, "column": 104}}, {"id": 317, "type": "*", "text": "*", "parent": 315, "children": [], "start_point": {"row": 77, "column": 104}, "end_point": {"row": 77, "column": 105}}, {"id": 318, "type": "identifier", "text": "phr", "parent": 315, "children": [], "start_point": {"row": 77, "column": 106}, "end_point": {"row": 77, "column": 109}}, {"id": 319, "type": "declaration", "text": "HRESULT UnpackInitPage(OggPage& page);", "parent": 205, "children": [320, 321], "start_point": {"row": 79, "column": 1}, "end_point": {"row": 79, "column": 39}}, {"id": 320, "type": "type_identifier", "text": "HRESULT", "parent": 319, "children": [], "start_point": {"row": 79, "column": 1}, "end_point": {"row": 79, "column": 8}}, {"id": 321, "type": "function_declarator", "text": "UnpackInitPage(OggPage& page)", "parent": 319, "children": [322, 323], "start_point": {"row": 79, "column": 9}, "end_point": {"row": 79, "column": 38}}, {"id": 322, "type": "identifier", "text": "UnpackInitPage", "parent": 321, "children": [], "start_point": {"row": 79, "column": 9}, "end_point": {"row": 79, "column": 23}}, {"id": 323, "type": "parameter_list", "text": "(OggPage& page)", "parent": 321, "children": [324], "start_point": {"row": 79, "column": 23}, "end_point": {"row": 79, "column": 38}}, {"id": 324, "type": "parameter_declaration", "text": "OggPage& page", "parent": 323, "children": [325, 326], "start_point": {"row": 79, "column": 24}, "end_point": {"row": 79, "column": 37}}, {"id": 325, "type": "type_identifier", "text": "OggPage", "parent": 324, "children": [], "start_point": {"row": 79, "column": 24}, "end_point": {"row": 79, "column": 31}}, {"id": 326, "type": "identifier", "text": "page", "parent": 324, "children": [], "start_point": {"row": 79, "column": 33}, "end_point": {"row": 79, "column": 37}}, {"id": 327, "type": "function_definition", "text": "bool IsInitialized() {\n\t\treturn m_initpackets.size() >= 3;\n\t}", "parent": 205, "children": [328, 329], "start_point": {"row": 80, "column": 1}, "end_point": {"row": 82, "column": 2}}, {"id": 328, "type": "primitive_type", "text": "bool", "parent": 327, "children": [], "start_point": {"row": 80, "column": 1}, "end_point": {"row": 80, "column": 5}}, {"id": 329, "type": "function_declarator", "text": "IsInitialized()", "parent": 327, "children": [330, 331], "start_point": {"row": 80, "column": 6}, "end_point": {"row": 80, "column": 21}}, {"id": 330, "type": "identifier", "text": "IsInitialized", "parent": 329, "children": [], "start_point": {"row": 80, "column": 6}, "end_point": {"row": 80, "column": 19}}, {"id": 331, "type": "parameter_list", "text": "()", "parent": 329, "children": [], "start_point": {"row": 80, "column": 19}, "end_point": {"row": 80, "column": 21}}, {"id": 332, "type": "return_statement", "text": "return m_initpackets.size() >= 3;", "parent": 327, "children": [333], "start_point": {"row": 81, "column": 2}, "end_point": {"row": 81, "column": 35}}, {"id": 333, "type": "binary_expression", "text": "m_initpackets.size() >= 3", "parent": 332, "children": [334, 339, 340], "start_point": {"row": 81, "column": 9}, "end_point": {"row": 81, "column": 34}}, {"id": 334, "type": "call_expression", "text": "m_initpackets.size()", "parent": 333, "children": [335, 338], "start_point": {"row": 81, "column": 9}, "end_point": {"row": 81, "column": 29}}, {"id": 335, "type": "field_expression", "text": "m_initpackets.size", "parent": 334, "children": [336, 337], "start_point": {"row": 81, "column": 9}, "end_point": {"row": 81, "column": 27}}, {"id": 336, "type": "identifier", "text": "m_initpackets", "parent": 335, "children": [], "start_point": {"row": 81, "column": 9}, "end_point": {"row": 81, "column": 22}}, {"id": 337, "type": "field_identifier", "text": "size", "parent": 335, "children": [], "start_point": {"row": 81, "column": 23}, "end_point": {"row": 81, "column": 27}}, {"id": 338, "type": "argument_list", "text": "()", "parent": 334, "children": [], "start_point": {"row": 81, "column": 27}, "end_point": {"row": 81, "column": 29}}, {"id": 339, "type": ">=", "text": ">=", "parent": 333, "children": [], "start_point": {"row": 81, "column": 30}, "end_point": {"row": 81, "column": 32}}, {"id": 340, "type": "number_literal", "text": "3", "parent": 333, "children": [], "start_point": {"row": 81, "column": 33}, "end_point": {"row": 81, "column": 34}}, {"id": 341, "type": "function_definition", "text": "class COggFlacOutputPin : public COggSplitterOutputPin\n{\n\tint m_nSamplesPerSec;\n\tint m_nChannels;\n\tWORD m_wBitsPerSample;\n\tint m_nAvgBytesPerSec;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggFlacOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}", "parent": null, "children": [342, 344], "start_point": {"row": 85, "column": 0}, "end_point": {"row": 97, "column": 1}}, {"id": 342, "type": "ERROR", "text": "COggFlacOutputPin : public", "parent": 341, "children": [343], "start_point": {"row": 85, "column": 6}, "end_point": {"row": 85, "column": 32}}, {"id": 343, "type": "identifier", "text": "COggFlacOutputPin", "parent": 342, "children": [], "start_point": {"row": 85, "column": 6}, "end_point": {"row": 85, "column": 23}}, {"id": 344, "type": "identifier", "text": "COggSplitterOutputPin", "parent": 341, "children": [], "start_point": {"row": 85, "column": 33}, "end_point": {"row": 85, "column": 54}}, {"id": 345, "type": "declaration", "text": "int m_nSamplesPerSec;", "parent": 341, "children": [346, 347], "start_point": {"row": 87, "column": 1}, "end_point": {"row": 87, "column": 23}}, {"id": 346, "type": "primitive_type", "text": "int", "parent": 345, "children": [], "start_point": {"row": 87, "column": 1}, "end_point": {"row": 87, "column": 4}}, {"id": 347, "type": "identifier", "text": "m_nSamplesPerSec", "parent": 345, "children": [], "start_point": {"row": 87, "column": 6}, "end_point": {"row": 87, "column": 22}}, {"id": 348, "type": "declaration", "text": "int m_nChannels;", "parent": 341, "children": [349, 350], "start_point": {"row": 88, "column": 1}, "end_point": {"row": 88, "column": 18}}, {"id": 349, "type": "primitive_type", "text": "int", "parent": 348, "children": [], "start_point": {"row": 88, "column": 1}, "end_point": {"row": 88, "column": 4}}, {"id": 350, "type": "identifier", "text": "m_nChannels", "parent": 348, "children": [], "start_point": {"row": 88, "column": 6}, "end_point": {"row": 88, "column": 17}}, {"id": 351, "type": "declaration", "text": "WORD m_wBitsPerSample;", "parent": 341, "children": [352, 353], "start_point": {"row": 89, "column": 1}, "end_point": {"row": 89, "column": 23}}, {"id": 352, "type": "type_identifier", "text": "WORD", "parent": 351, "children": [], "start_point": {"row": 89, "column": 1}, "end_point": {"row": 89, "column": 5}}, {"id": 353, "type": "identifier", "text": "m_wBitsPerSample", "parent": 351, "children": [], "start_point": {"row": 89, "column": 6}, "end_point": {"row": 89, "column": 22}}, {"id": 354, "type": "declaration", "text": "int m_nAvgBytesPerSec;", "parent": 341, "children": [355, 356], "start_point": {"row": 90, "column": 1}, "end_point": {"row": 90, "column": 24}}, {"id": 355, "type": "primitive_type", "text": "int", "parent": 354, "children": [], "start_point": {"row": 90, "column": 1}, "end_point": {"row": 90, "column": 4}}, {"id": 356, "type": "identifier", "text": "m_nAvgBytesPerSec", "parent": 354, "children": [], "start_point": {"row": 90, "column": 6}, "end_point": {"row": 90, "column": 23}}, {"id": 357, "type": "declaration", "text": "virtual HRESULT", "parent": 341, "children": [358, 359], "start_point": {"row": 92, "column": 1}, "end_point": {"row": 92, "column": 16}}, {"id": 358, "type": "type_identifier", "text": "virtual", "parent": 357, "children": [], "start_point": {"row": 92, "column": 1}, "end_point": {"row": 92, "column": 8}}, {"id": 359, "type": "identifier", "text": "HRESULT", "parent": 357, "children": [], "start_point": {"row": 92, "column": 9}, "end_point": {"row": 92, "column": 16}}, {"id": 360, "type": "call_expression", "text": "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 341, "children": [361, 362], "start_point": {"row": 92, "column": 17}, "end_point": {"row": 92, "column": 73}}, {"id": 361, "type": "identifier", "text": "UnpackPacket", "parent": 360, "children": [], "start_point": {"row": 92, "column": 17}, "end_point": {"row": 92, "column": 29}}, {"id": 362, "type": "argument_list", "text": "(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 360, "children": [363, 371, 375, 376], "start_point": {"row": 92, "column": 29}, "end_point": {"row": 92, "column": 73}}, {"id": 363, "type": "binary_expression", "text": "CAutoPtr<CPacket>& p", "parent": 362, "children": [364, 368, 369], "start_point": {"row": 92, "column": 30}, "end_point": {"row": 92, "column": 50}}, {"id": 364, "type": "binary_expression", "text": "CAutoPtr<CPacket", "parent": 363, "children": [365, 366, 367], "start_point": {"row": 92, "column": 30}, "end_point": {"row": 92, "column": 46}}, {"id": 365, "type": "identifier", "text": "CAutoPtr", "parent": 364, "children": [], "start_point": {"row": 92, "column": 30}, "end_point": {"row": 92, "column": 38}}, {"id": 366, "type": "<", "text": "<", "parent": 364, "children": [], "start_point": {"row": 92, "column": 38}, "end_point": {"row": 92, "column": 39}}, {"id": 367, "type": "identifier", "text": "CPacket", "parent": 364, "children": [], "start_point": {"row": 92, "column": 39}, "end_point": {"row": 92, "column": 46}}, {"id": 368, "type": ">", "text": ">", "parent": 363, "children": [], "start_point": {"row": 92, "column": 46}, "end_point": {"row": 92, "column": 47}}, {"id": 369, "type": "pointer_expression", "text": "& p", "parent": 363, "children": [370], "start_point": {"row": 92, "column": 47}, "end_point": {"row": 92, "column": 50}}, {"id": 370, "type": "identifier", "text": "p", "parent": 369, "children": [], "start_point": {"row": 92, "column": 49}, "end_point": {"row": 92, "column": 50}}, {"id": 371, "type": "binary_expression", "text": "BYTE* pData", "parent": 362, "children": [372, 373, 374], "start_point": {"row": 92, "column": 52}, "end_point": {"row": 92, "column": 63}}, {"id": 372, "type": "identifier", "text": "BYTE", "parent": 371, "children": [], "start_point": {"row": 92, "column": 52}, "end_point": {"row": 92, "column": 56}}, {"id": 373, "type": "*", "text": "*", "parent": 371, "children": [], "start_point": {"row": 92, "column": 56}, "end_point": {"row": 92, "column": 57}}, {"id": 374, "type": "identifier", "text": "pData", "parent": 371, "children": [], "start_point": {"row": 92, "column": 58}, "end_point": {"row": 92, "column": 63}}, {"id": 375, "type": "identifier", "text": "int", "parent": 362, "children": [], "start_point": {"row": 92, "column": 65}, "end_point": {"row": 92, "column": 68}}, {"id": 376, "type": "ERROR", "text": "len", "parent": 362, "children": [377], "start_point": {"row": 92, "column": 69}, "end_point": {"row": 92, "column": 72}}, {"id": 377, "type": "identifier", "text": "len", "parent": 376, "children": [], "start_point": {"row": 92, "column": 69}, "end_point": {"row": 92, "column": 72}}, {"id": 378, "type": "declaration", "text": "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);", "parent": 341, "children": [379, 380, 382], "start_point": {"row": 93, "column": 1}, "end_point": {"row": 93, "column": 61}}, {"id": 379, "type": "type_identifier", "text": "virtual", "parent": 378, "children": [], "start_point": {"row": 93, "column": 1}, "end_point": {"row": 93, "column": 8}}, {"id": 380, "type": "ERROR", "text": "REFERENCE_TIME", "parent": 378, "children": [381], "start_point": {"row": 93, "column": 9}, "end_point": {"row": 93, "column": 23}}, {"id": 381, "type": "identifier", "text": "REFERENCE_TIME", "parent": 380, "children": [], "start_point": {"row": 93, "column": 9}, "end_point": {"row": 93, "column": 23}}, {"id": 382, "type": "function_declarator", "text": "GetRefTime(__int64 granule_position)", "parent": 378, "children": [383, 384], "start_point": {"row": 93, "column": 24}, "end_point": {"row": 93, "column": 60}}, {"id": 383, "type": "identifier", "text": "GetRefTime", "parent": 382, "children": [], "start_point": {"row": 93, "column": 24}, "end_point": {"row": 93, "column": 34}}, {"id": 384, "type": "parameter_list", "text": "(__int64 granule_position)", "parent": 382, "children": [385], "start_point": {"row": 93, "column": 34}, "end_point": {"row": 93, "column": 60}}, {"id": 385, "type": "parameter_declaration", "text": "__int64 granule_position", "parent": 384, "children": [386, 387], "start_point": {"row": 93, "column": 35}, "end_point": {"row": 93, "column": 59}}, {"id": 386, "type": "type_identifier", "text": "__int64", "parent": 385, "children": [], "start_point": {"row": 93, "column": 35}, "end_point": {"row": 93, "column": 42}}, {"id": 387, "type": "identifier", "text": "granule_position", "parent": 385, "children": [], "start_point": {"row": 93, "column": 43}, "end_point": {"row": 93, "column": 59}}, {"id": 388, "type": "labeled_statement", "text": "public:\n\tCOggFlacOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 341, "children": [], "start_point": {"row": 95, "column": 0}, "end_point": {"row": 96, "column": 108}}, {"id": 389, "type": "call_expression", "text": "COggFlacOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 388, "children": [390, 391], "start_point": {"row": 96, "column": 1}, "end_point": {"row": 96, "column": 107}}, {"id": 390, "type": "identifier", "text": "COggFlacOutputPin", "parent": 389, "children": [], "start_point": {"row": 96, "column": 1}, "end_point": {"row": 96, "column": 18}}, {"id": 391, "type": "argument_list", "text": "(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 389, "children": [392, 396, 398, 399, 400, 402, 406, 410], "start_point": {"row": 96, "column": 18}, "end_point": {"row": 96, "column": 107}}, {"id": 392, "type": "binary_expression", "text": "BYTE* h", "parent": 391, "children": [393, 394, 395], "start_point": {"row": 96, "column": 19}, "end_point": {"row": 96, "column": 26}}, {"id": 393, "type": "identifier", "text": "BYTE", "parent": 392, "children": [], "start_point": {"row": 96, "column": 19}, "end_point": {"row": 96, "column": 23}}, {"id": 394, "type": "*", "text": "*", "parent": 392, "children": [], "start_point": {"row": 96, "column": 23}, "end_point": {"row": 96, "column": 24}}, {"id": 395, "type": "identifier", "text": "h", "parent": 392, "children": [], "start_point": {"row": 96, "column": 25}, "end_point": {"row": 96, "column": 26}}, {"id": 396, "type": "ERROR", "text": "int", "parent": 391, "children": [397], "start_point": {"row": 96, "column": 28}, "end_point": {"row": 96, "column": 31}}, {"id": 397, "type": "identifier", "text": "int", "parent": 396, "children": [], "start_point": {"row": 96, "column": 28}, "end_point": {"row": 96, "column": 31}}, {"id": 398, "type": "identifier", "text": "nCount", "parent": 391, "children": [], "start_point": {"row": 96, "column": 32}, "end_point": {"row": 96, "column": 38}}, {"id": 399, "type": "identifier", "text": "LPCWSTR", "parent": 391, "children": [], "start_point": {"row": 96, "column": 40}, "end_point": {"row": 96, "column": 47}}, {"id": 400, "type": "ERROR", "text": "pName", "parent": 391, "children": [401], "start_point": {"row": 96, "column": 48}, "end_point": {"row": 96, "column": 53}}, {"id": 401, "type": "identifier", "text": "pName", "parent": 400, "children": [], "start_point": {"row": 96, "column": 48}, "end_point": {"row": 96, "column": 53}}, {"id": 402, "type": "binary_expression", "text": "CBaseFilter* pFilter", "parent": 391, "children": [403, 404, 405], "start_point": {"row": 96, "column": 55}, "end_point": {"row": 96, "column": 75}}, {"id": 403, "type": "identifier", "text": "CBaseFilter", "parent": 402, "children": [], "start_point": {"row": 96, "column": 55}, "end_point": {"row": 96, "column": 66}}, {"id": 404, "type": "*", "text": "*", "parent": 402, "children": [], "start_point": {"row": 96, "column": 66}, "end_point": {"row": 96, "column": 67}}, {"id": 405, "type": "identifier", "text": "pFilter", "parent": 402, "children": [], "start_point": {"row": 96, "column": 68}, "end_point": {"row": 96, "column": 75}}, {"id": 406, "type": "binary_expression", "text": "CCritSec* pLock", "parent": 391, "children": [407, 408, 409], "start_point": {"row": 96, "column": 77}, "end_point": {"row": 96, "column": 92}}, {"id": 407, "type": "identifier", "text": "CCritSec", "parent": 406, "children": [], "start_point": {"row": 96, "column": 77}, "end_point": {"row": 96, "column": 85}}, {"id": 408, "type": "*", "text": "*", "parent": 406, "children": [], "start_point": {"row": 96, "column": 85}, "end_point": {"row": 96, "column": 86}}, {"id": 409, "type": "identifier", "text": "pLock", "parent": 406, "children": [], "start_point": {"row": 96, "column": 87}, "end_point": {"row": 96, "column": 92}}, {"id": 410, "type": "binary_expression", "text": "HRESULT* phr", "parent": 391, "children": [411, 412, 413], "start_point": {"row": 96, "column": 94}, "end_point": {"row": 96, "column": 106}}, {"id": 411, "type": "identifier", "text": "HRESULT", "parent": 410, "children": [], "start_point": {"row": 96, "column": 94}, "end_point": {"row": 96, "column": 101}}, {"id": 412, "type": "*", "text": "*", "parent": 410, "children": [], "start_point": {"row": 96, "column": 101}, "end_point": {"row": 96, "column": 102}}, {"id": 413, "type": "identifier", "text": "phr", "parent": 410, "children": [], "start_point": {"row": 96, "column": 103}, "end_point": {"row": 96, "column": 106}}, {"id": 414, "type": "function_definition", "text": "class COggDirectShowOutputPin : public COggSplitterOutputPin\n{\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggDirectShowOutputPin(AM_MEDIA_TYPE* pmt, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}", "parent": null, "children": [415, 416], "start_point": {"row": 99, "column": 0}, "end_point": {"row": 106, "column": 1}}, {"id": 415, "type": "identifier", "text": "COggDirectShowOutputPin", "parent": 414, "children": [], "start_point": {"row": 99, "column": 6}, "end_point": {"row": 99, "column": 29}}, {"id": 416, "type": "ERROR", "text": ": public COggSplitterOutputPin", "parent": 414, "children": [417], "start_point": {"row": 99, "column": 30}, "end_point": {"row": 99, "column": 60}}, {"id": 417, "type": "identifier", "text": "COggSplitterOutputPin", "parent": 416, "children": [], "start_point": {"row": 99, "column": 39}, "end_point": {"row": 99, "column": 60}}, {"id": 418, "type": "declaration", "text": "virtual HRESULT", "parent": 414, "children": [419, 420], "start_point": {"row": 101, "column": 1}, "end_point": {"row": 101, "column": 16}}, {"id": 419, "type": "type_identifier", "text": "virtual", "parent": 418, "children": [], "start_point": {"row": 101, "column": 1}, "end_point": {"row": 101, "column": 8}}, {"id": 420, "type": "identifier", "text": "HRESULT", "parent": 418, "children": [], "start_point": {"row": 101, "column": 9}, "end_point": {"row": 101, "column": 16}}, {"id": 421, "type": "call_expression", "text": "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 414, "children": [422, 423], "start_point": {"row": 101, "column": 17}, "end_point": {"row": 101, "column": 73}}, {"id": 422, "type": "identifier", "text": "UnpackPacket", "parent": 421, "children": [], "start_point": {"row": 101, "column": 17}, "end_point": {"row": 101, "column": 29}}, {"id": 423, "type": "argument_list", "text": "(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 421, "children": [424, 432, 436, 437], "start_point": {"row": 101, "column": 29}, "end_point": {"row": 101, "column": 73}}, {"id": 424, "type": "binary_expression", "text": "CAutoPtr<CPacket>& p", "parent": 423, "children": [425, 429, 430], "start_point": {"row": 101, "column": 30}, "end_point": {"row": 101, "column": 50}}, {"id": 425, "type": "binary_expression", "text": "CAutoPtr<CPacket", "parent": 424, "children": [426, 427, 428], "start_point": {"row": 101, "column": 30}, "end_point": {"row": 101, "column": 46}}, {"id": 426, "type": "identifier", "text": "CAutoPtr", "parent": 425, "children": [], "start_point": {"row": 101, "column": 30}, "end_point": {"row": 101, "column": 38}}, {"id": 427, "type": "<", "text": "<", "parent": 425, "children": [], "start_point": {"row": 101, "column": 38}, "end_point": {"row": 101, "column": 39}}, {"id": 428, "type": "identifier", "text": "CPacket", "parent": 425, "children": [], "start_point": {"row": 101, "column": 39}, "end_point": {"row": 101, "column": 46}}, {"id": 429, "type": ">", "text": ">", "parent": 424, "children": [], "start_point": {"row": 101, "column": 46}, "end_point": {"row": 101, "column": 47}}, {"id": 430, "type": "pointer_expression", "text": "& p", "parent": 424, "children": [431], "start_point": {"row": 101, "column": 47}, "end_point": {"row": 101, "column": 50}}, {"id": 431, "type": "identifier", "text": "p", "parent": 430, "children": [], "start_point": {"row": 101, "column": 49}, "end_point": {"row": 101, "column": 50}}, {"id": 432, "type": "binary_expression", "text": "BYTE* pData", "parent": 423, "children": [433, 434, 435], "start_point": {"row": 101, "column": 52}, "end_point": {"row": 101, "column": 63}}, {"id": 433, "type": "identifier", "text": "BYTE", "parent": 432, "children": [], "start_point": {"row": 101, "column": 52}, "end_point": {"row": 101, "column": 56}}, {"id": 434, "type": "*", "text": "*", "parent": 432, "children": [], "start_point": {"row": 101, "column": 56}, "end_point": {"row": 101, "column": 57}}, {"id": 435, "type": "identifier", "text": "pData", "parent": 432, "children": [], "start_point": {"row": 101, "column": 58}, "end_point": {"row": 101, "column": 63}}, {"id": 436, "type": "identifier", "text": "int", "parent": 423, "children": [], "start_point": {"row": 101, "column": 65}, "end_point": {"row": 101, "column": 68}}, {"id": 437, "type": "ERROR", "text": "len", "parent": 423, "children": [438], "start_point": {"row": 101, "column": 69}, "end_point": {"row": 101, "column": 72}}, {"id": 438, "type": "identifier", "text": "len", "parent": 437, "children": [], "start_point": {"row": 101, "column": 69}, "end_point": {"row": 101, "column": 72}}, {"id": 439, "type": "declaration", "text": "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);", "parent": 414, "children": [440, 441, 443], "start_point": {"row": 102, "column": 1}, "end_point": {"row": 102, "column": 61}}, {"id": 440, "type": "type_identifier", "text": "virtual", "parent": 439, "children": [], "start_point": {"row": 102, "column": 1}, "end_point": {"row": 102, "column": 8}}, {"id": 441, "type": "ERROR", "text": "REFERENCE_TIME", "parent": 439, "children": [442], "start_point": {"row": 102, "column": 9}, "end_point": {"row": 102, "column": 23}}, {"id": 442, "type": "identifier", "text": "REFERENCE_TIME", "parent": 441, "children": [], "start_point": {"row": 102, "column": 9}, "end_point": {"row": 102, "column": 23}}, {"id": 443, "type": "function_declarator", "text": "GetRefTime(__int64 granule_position)", "parent": 439, "children": [444, 445], "start_point": {"row": 102, "column": 24}, "end_point": {"row": 102, "column": 60}}, {"id": 444, "type": "identifier", "text": "GetRefTime", "parent": 443, "children": [], "start_point": {"row": 102, "column": 24}, "end_point": {"row": 102, "column": 34}}, {"id": 445, "type": "parameter_list", "text": "(__int64 granule_position)", "parent": 443, "children": [446], "start_point": {"row": 102, "column": 34}, "end_point": {"row": 102, "column": 60}}, {"id": 446, "type": "parameter_declaration", "text": "__int64 granule_position", "parent": 445, "children": [447, 448], "start_point": {"row": 102, "column": 35}, "end_point": {"row": 102, "column": 59}}, {"id": 447, "type": "type_identifier", "text": "__int64", "parent": 446, "children": [], "start_point": {"row": 102, "column": 35}, "end_point": {"row": 102, "column": 42}}, {"id": 448, "type": "identifier", "text": "granule_position", "parent": 446, "children": [], "start_point": {"row": 102, "column": 43}, "end_point": {"row": 102, "column": 59}}, {"id": 449, "type": "labeled_statement", "text": "public:\n\tCOggDirectShowOutputPin(AM_MEDIA_TYPE* pmt, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 414, "children": [], "start_point": {"row": 104, "column": 0}, "end_point": {"row": 105, "column": 113}}, {"id": 450, "type": "call_expression", "text": "COggDirectShowOutputPin(AM_MEDIA_TYPE* pmt, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 449, "children": [451, 452], "start_point": {"row": 105, "column": 1}, "end_point": {"row": 105, "column": 112}}, {"id": 451, "type": "identifier", "text": "COggDirectShowOutputPin", "parent": 450, "children": [], "start_point": {"row": 105, "column": 1}, "end_point": {"row": 105, "column": 24}}, {"id": 452, "type": "argument_list", "text": "(AM_MEDIA_TYPE* pmt, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 450, "children": [453, 457, 458, 460, 464, 468], "start_point": {"row": 105, "column": 24}, "end_point": {"row": 105, "column": 112}}, {"id": 453, "type": "binary_expression", "text": "AM_MEDIA_TYPE* pmt", "parent": 452, "children": [454, 455, 456], "start_point": {"row": 105, "column": 25}, "end_point": {"row": 105, "column": 43}}, {"id": 454, "type": "identifier", "text": "AM_MEDIA_TYPE", "parent": 453, "children": [], "start_point": {"row": 105, "column": 25}, "end_point": {"row": 105, "column": 38}}, {"id": 455, "type": "*", "text": "*", "parent": 453, "children": [], "start_point": {"row": 105, "column": 38}, "end_point": {"row": 105, "column": 39}}, {"id": 456, "type": "identifier", "text": "pmt", "parent": 453, "children": [], "start_point": {"row": 105, "column": 40}, "end_point": {"row": 105, "column": 43}}, {"id": 457, "type": "identifier", "text": "LPCWSTR", "parent": 452, "children": [], "start_point": {"row": 105, "column": 45}, "end_point": {"row": 105, "column": 52}}, {"id": 458, "type": "ERROR", "text": "pName", "parent": 452, "children": [459], "start_point": {"row": 105, "column": 53}, "end_point": {"row": 105, "column": 58}}, {"id": 459, "type": "identifier", "text": "pName", "parent": 458, "children": [], "start_point": {"row": 105, "column": 53}, "end_point": {"row": 105, "column": 58}}, {"id": 460, "type": "binary_expression", "text": "CBaseFilter* pFilter", "parent": 452, "children": [461, 462, 463], "start_point": {"row": 105, "column": 60}, "end_point": {"row": 105, "column": 80}}, {"id": 461, "type": "identifier", "text": "CBaseFilter", "parent": 460, "children": [], "start_point": {"row": 105, "column": 60}, "end_point": {"row": 105, "column": 71}}, {"id": 462, "type": "*", "text": "*", "parent": 460, "children": [], "start_point": {"row": 105, "column": 71}, "end_point": {"row": 105, "column": 72}}, {"id": 463, "type": "identifier", "text": "pFilter", "parent": 460, "children": [], "start_point": {"row": 105, "column": 73}, "end_point": {"row": 105, "column": 80}}, {"id": 464, "type": "binary_expression", "text": "CCritSec* pLock", "parent": 452, "children": [465, 466, 467], "start_point": {"row": 105, "column": 82}, "end_point": {"row": 105, "column": 97}}, {"id": 465, "type": "identifier", "text": "CCritSec", "parent": 464, "children": [], "start_point": {"row": 105, "column": 82}, "end_point": {"row": 105, "column": 90}}, {"id": 466, "type": "*", "text": "*", "parent": 464, "children": [], "start_point": {"row": 105, "column": 90}, "end_point": {"row": 105, "column": 91}}, {"id": 467, "type": "identifier", "text": "pLock", "parent": 464, "children": [], "start_point": {"row": 105, "column": 92}, "end_point": {"row": 105, "column": 97}}, {"id": 468, "type": "binary_expression", "text": "HRESULT* phr", "parent": 452, "children": [469, 470, 471], "start_point": {"row": 105, "column": 99}, "end_point": {"row": 105, "column": 111}}, {"id": 469, "type": "identifier", "text": "HRESULT", "parent": 468, "children": [], "start_point": {"row": 105, "column": 99}, "end_point": {"row": 105, "column": 106}}, {"id": 470, "type": "*", "text": "*", "parent": 468, "children": [], "start_point": {"row": 105, "column": 106}, "end_point": {"row": 105, "column": 107}}, {"id": 471, "type": "identifier", "text": "phr", "parent": 468, "children": [], "start_point": {"row": 105, "column": 108}, "end_point": {"row": 105, "column": 111}}, {"id": 472, "type": "function_definition", "text": "class COggStreamOutputPin : public COggSplitterOutputPin\n{\n\t__int64 m_time_unit, m_samples_per_unit;\n\tDWORD m_default_len;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggStreamOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}", "parent": null, "children": [473, 475], "start_point": {"row": 108, "column": 0}, "end_point": {"row": 118, "column": 1}}, {"id": 473, "type": "ERROR", "text": "COggStreamOutputPin : public", "parent": 472, "children": [474], "start_point": {"row": 108, "column": 6}, "end_point": {"row": 108, "column": 34}}, {"id": 474, "type": "identifier", "text": "COggStreamOutputPin", "parent": 473, "children": [], "start_point": {"row": 108, "column": 6}, "end_point": {"row": 108, "column": 25}}, {"id": 475, "type": "identifier", "text": "COggSplitterOutputPin", "parent": 472, "children": [], "start_point": {"row": 108, "column": 35}, "end_point": {"row": 108, "column": 56}}, {"id": 476, "type": "declaration", "text": "__int64 m_time_unit, m_samples_per_unit;", "parent": 472, "children": [477, 478, 479], "start_point": {"row": 110, "column": 1}, "end_point": {"row": 110, "column": 41}}, {"id": 477, "type": "type_identifier", "text": "__int64", "parent": 476, "children": [], "start_point": {"row": 110, "column": 1}, "end_point": {"row": 110, "column": 8}}, {"id": 478, "type": "identifier", "text": "m_time_unit", "parent": 476, "children": [], "start_point": {"row": 110, "column": 9}, "end_point": {"row": 110, "column": 20}}, {"id": 479, "type": "identifier", "text": "m_samples_per_unit", "parent": 476, "children": [], "start_point": {"row": 110, "column": 22}, "end_point": {"row": 110, "column": 40}}, {"id": 480, "type": "declaration", "text": "DWORD m_default_len;", "parent": 472, "children": [481, 482], "start_point": {"row": 111, "column": 1}, "end_point": {"row": 111, "column": 21}}, {"id": 481, "type": "type_identifier", "text": "DWORD", "parent": 480, "children": [], "start_point": {"row": 111, "column": 1}, "end_point": {"row": 111, "column": 6}}, {"id": 482, "type": "identifier", "text": "m_default_len", "parent": 480, "children": [], "start_point": {"row": 111, "column": 7}, "end_point": {"row": 111, "column": 20}}, {"id": 483, "type": "declaration", "text": "virtual HRESULT", "parent": 472, "children": [484, 485], "start_point": {"row": 113, "column": 1}, "end_point": {"row": 113, "column": 16}}, {"id": 484, "type": "type_identifier", "text": "virtual", "parent": 483, "children": [], "start_point": {"row": 113, "column": 1}, "end_point": {"row": 113, "column": 8}}, {"id": 485, "type": "identifier", "text": "HRESULT", "parent": 483, "children": [], "start_point": {"row": 113, "column": 9}, "end_point": {"row": 113, "column": 16}}, {"id": 486, "type": "call_expression", "text": "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 472, "children": [487, 488], "start_point": {"row": 113, "column": 17}, "end_point": {"row": 113, "column": 73}}, {"id": 487, "type": "identifier", "text": "UnpackPacket", "parent": 486, "children": [], "start_point": {"row": 113, "column": 17}, "end_point": {"row": 113, "column": 29}}, {"id": 488, "type": "argument_list", "text": "(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 486, "children": [489, 497, 501, 502], "start_point": {"row": 113, "column": 29}, "end_point": {"row": 113, "column": 73}}, {"id": 489, "type": "binary_expression", "text": "CAutoPtr<CPacket>& p", "parent": 488, "children": [490, 494, 495], "start_point": {"row": 113, "column": 30}, "end_point": {"row": 113, "column": 50}}, {"id": 490, "type": "binary_expression", "text": "CAutoPtr<CPacket", "parent": 489, "children": [491, 492, 493], "start_point": {"row": 113, "column": 30}, "end_point": {"row": 113, "column": 46}}, {"id": 491, "type": "identifier", "text": "CAutoPtr", "parent": 490, "children": [], "start_point": {"row": 113, "column": 30}, "end_point": {"row": 113, "column": 38}}, {"id": 492, "type": "<", "text": "<", "parent": 490, "children": [], "start_point": {"row": 113, "column": 38}, "end_point": {"row": 113, "column": 39}}, {"id": 493, "type": "identifier", "text": "CPacket", "parent": 490, "children": [], "start_point": {"row": 113, "column": 39}, "end_point": {"row": 113, "column": 46}}, {"id": 494, "type": ">", "text": ">", "parent": 489, "children": [], "start_point": {"row": 113, "column": 46}, "end_point": {"row": 113, "column": 47}}, {"id": 495, "type": "pointer_expression", "text": "& p", "parent": 489, "children": [496], "start_point": {"row": 113, "column": 47}, "end_point": {"row": 113, "column": 50}}, {"id": 496, "type": "identifier", "text": "p", "parent": 495, "children": [], "start_point": {"row": 113, "column": 49}, "end_point": {"row": 113, "column": 50}}, {"id": 497, "type": "binary_expression", "text": "BYTE* pData", "parent": 488, "children": [498, 499, 500], "start_point": {"row": 113, "column": 52}, "end_point": {"row": 113, "column": 63}}, {"id": 498, "type": "identifier", "text": "BYTE", "parent": 497, "children": [], "start_point": {"row": 113, "column": 52}, "end_point": {"row": 113, "column": 56}}, {"id": 499, "type": "*", "text": "*", "parent": 497, "children": [], "start_point": {"row": 113, "column": 56}, "end_point": {"row": 113, "column": 57}}, {"id": 500, "type": "identifier", "text": "pData", "parent": 497, "children": [], "start_point": {"row": 113, "column": 58}, "end_point": {"row": 113, "column": 63}}, {"id": 501, "type": "identifier", "text": "int", "parent": 488, "children": [], "start_point": {"row": 113, "column": 65}, "end_point": {"row": 113, "column": 68}}, {"id": 502, "type": "ERROR", "text": "len", "parent": 488, "children": [503], "start_point": {"row": 113, "column": 69}, "end_point": {"row": 113, "column": 72}}, {"id": 503, "type": "identifier", "text": "len", "parent": 502, "children": [], "start_point": {"row": 113, "column": 69}, "end_point": {"row": 113, "column": 72}}, {"id": 504, "type": "declaration", "text": "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);", "parent": 472, "children": [505, 506, 508], "start_point": {"row": 114, "column": 1}, "end_point": {"row": 114, "column": 61}}, {"id": 505, "type": "type_identifier", "text": "virtual", "parent": 504, "children": [], "start_point": {"row": 114, "column": 1}, "end_point": {"row": 114, "column": 8}}, {"id": 506, "type": "ERROR", "text": "REFERENCE_TIME", "parent": 504, "children": [507], "start_point": {"row": 114, "column": 9}, "end_point": {"row": 114, "column": 23}}, {"id": 507, "type": "identifier", "text": "REFERENCE_TIME", "parent": 506, "children": [], "start_point": {"row": 114, "column": 9}, "end_point": {"row": 114, "column": 23}}, {"id": 508, "type": "function_declarator", "text": "GetRefTime(__int64 granule_position)", "parent": 504, "children": [509, 510], "start_point": {"row": 114, "column": 24}, "end_point": {"row": 114, "column": 60}}, {"id": 509, "type": "identifier", "text": "GetRefTime", "parent": 508, "children": [], "start_point": {"row": 114, "column": 24}, "end_point": {"row": 114, "column": 34}}, {"id": 510, "type": "parameter_list", "text": "(__int64 granule_position)", "parent": 508, "children": [511], "start_point": {"row": 114, "column": 34}, "end_point": {"row": 114, "column": 60}}, {"id": 511, "type": "parameter_declaration", "text": "__int64 granule_position", "parent": 510, "children": [512, 513], "start_point": {"row": 114, "column": 35}, "end_point": {"row": 114, "column": 59}}, {"id": 512, "type": "type_identifier", "text": "__int64", "parent": 511, "children": [], "start_point": {"row": 114, "column": 35}, "end_point": {"row": 114, "column": 42}}, {"id": 513, "type": "identifier", "text": "granule_position", "parent": 511, "children": [], "start_point": {"row": 114, "column": 43}, "end_point": {"row": 114, "column": 59}}, {"id": 514, "type": "labeled_statement", "text": "public:\n\tCOggStreamOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 472, "children": [], "start_point": {"row": 116, "column": 0}, "end_point": {"row": 117, "column": 109}}, {"id": 515, "type": "call_expression", "text": "COggStreamOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 514, "children": [516, 517], "start_point": {"row": 117, "column": 1}, "end_point": {"row": 117, "column": 108}}, {"id": 516, "type": "identifier", "text": "COggStreamOutputPin", "parent": 515, "children": [], "start_point": {"row": 117, "column": 1}, "end_point": {"row": 117, "column": 20}}, {"id": 517, "type": "argument_list", "text": "(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 515, "children": [518, 522, 523, 525, 529, 533], "start_point": {"row": 117, "column": 20}, "end_point": {"row": 117, "column": 108}}, {"id": 518, "type": "binary_expression", "text": "OggStreamHeader* h", "parent": 517, "children": [519, 520, 521], "start_point": {"row": 117, "column": 21}, "end_point": {"row": 117, "column": 39}}, {"id": 519, "type": "identifier", "text": "OggStreamHeader", "parent": 518, "children": [], "start_point": {"row": 117, "column": 21}, "end_point": {"row": 117, "column": 36}}, {"id": 520, "type": "*", "text": "*", "parent": 518, "children": [], "start_point": {"row": 117, "column": 36}, "end_point": {"row": 117, "column": 37}}, {"id": 521, "type": "identifier", "text": "h", "parent": 518, "children": [], "start_point": {"row": 117, "column": 38}, "end_point": {"row": 117, "column": 39}}, {"id": 522, "type": "identifier", "text": "LPCWSTR", "parent": 517, "children": [], "start_point": {"row": 117, "column": 41}, "end_point": {"row": 117, "column": 48}}, {"id": 523, "type": "ERROR", "text": "pName", "parent": 517, "children": [524], "start_point": {"row": 117, "column": 49}, "end_point": {"row": 117, "column": 54}}, {"id": 524, "type": "identifier", "text": "pName", "parent": 523, "children": [], "start_point": {"row": 117, "column": 49}, "end_point": {"row": 117, "column": 54}}, {"id": 525, "type": "binary_expression", "text": "CBaseFilter* pFilter", "parent": 517, "children": [526, 527, 528], "start_point": {"row": 117, "column": 56}, "end_point": {"row": 117, "column": 76}}, {"id": 526, "type": "identifier", "text": "CBaseFilter", "parent": 525, "children": [], "start_point": {"row": 117, "column": 56}, "end_point": {"row": 117, "column": 67}}, {"id": 527, "type": "*", "text": "*", "parent": 525, "children": [], "start_point": {"row": 117, "column": 67}, "end_point": {"row": 117, "column": 68}}, {"id": 528, "type": "identifier", "text": "pFilter", "parent": 525, "children": [], "start_point": {"row": 117, "column": 69}, "end_point": {"row": 117, "column": 76}}, {"id": 529, "type": "binary_expression", "text": "CCritSec* pLock", "parent": 517, "children": [530, 531, 532], "start_point": {"row": 117, "column": 78}, "end_point": {"row": 117, "column": 93}}, {"id": 530, "type": "identifier", "text": "CCritSec", "parent": 529, "children": [], "start_point": {"row": 117, "column": 78}, "end_point": {"row": 117, "column": 86}}, {"id": 531, "type": "*", "text": "*", "parent": 529, "children": [], "start_point": {"row": 117, "column": 86}, "end_point": {"row": 117, "column": 87}}, {"id": 532, "type": "identifier", "text": "pLock", "parent": 529, "children": [], "start_point": {"row": 117, "column": 88}, "end_point": {"row": 117, "column": 93}}, {"id": 533, "type": "binary_expression", "text": "HRESULT* phr", "parent": 517, "children": [534, 535, 536], "start_point": {"row": 117, "column": 95}, "end_point": {"row": 117, "column": 107}}, {"id": 534, "type": "identifier", "text": "HRESULT", "parent": 533, "children": [], "start_point": {"row": 117, "column": 95}, "end_point": {"row": 117, "column": 102}}, {"id": 535, "type": "*", "text": "*", "parent": 533, "children": [], "start_point": {"row": 117, "column": 102}, "end_point": {"row": 117, "column": 103}}, {"id": 536, "type": "identifier", "text": "phr", "parent": 533, "children": [], "start_point": {"row": 117, "column": 104}, "end_point": {"row": 117, "column": 107}}, {"id": 537, "type": "function_definition", "text": "class COggVideoOutputPin : public COggStreamOutputPin\n{\npublic:\n\tCOggVideoOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}", "parent": null, "children": [538, 540], "start_point": {"row": 120, "column": 0}, "end_point": {"row": 124, "column": 1}}, {"id": 538, "type": "ERROR", "text": "COggVideoOutputPin : public", "parent": 537, "children": [539], "start_point": {"row": 120, "column": 6}, "end_point": {"row": 120, "column": 33}}, {"id": 539, "type": "identifier", "text": "COggVideoOutputPin", "parent": 538, "children": [], "start_point": {"row": 120, "column": 6}, "end_point": {"row": 120, "column": 24}}, {"id": 540, "type": "identifier", "text": "COggStreamOutputPin", "parent": 537, "children": [], "start_point": {"row": 120, "column": 34}, "end_point": {"row": 120, "column": 53}}, {"id": 541, "type": "labeled_statement", "text": "public:\n\tCOggVideoOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 537, "children": [], "start_point": {"row": 122, "column": 0}, "end_point": {"row": 123, "column": 108}}, {"id": 542, "type": "call_expression", "text": "COggVideoOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 541, "children": [543, 544], "start_point": {"row": 123, "column": 1}, "end_point": {"row": 123, "column": 107}}, {"id": 543, "type": "identifier", "text": "COggVideoOutputPin", "parent": 542, "children": [], "start_point": {"row": 123, "column": 1}, "end_point": {"row": 123, "column": 19}}, {"id": 544, "type": "argument_list", "text": "(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 542, "children": [545, 549, 550, 552, 556, 560], "start_point": {"row": 123, "column": 19}, "end_point": {"row": 123, "column": 107}}, {"id": 545, "type": "binary_expression", "text": "OggStreamHeader* h", "parent": 544, "children": [546, 547, 548], "start_point": {"row": 123, "column": 20}, "end_point": {"row": 123, "column": 38}}, {"id": 546, "type": "identifier", "text": "OggStreamHeader", "parent": 545, "children": [], "start_point": {"row": 123, "column": 20}, "end_point": {"row": 123, "column": 35}}, {"id": 547, "type": "*", "text": "*", "parent": 545, "children": [], "start_point": {"row": 123, "column": 35}, "end_point": {"row": 123, "column": 36}}, {"id": 548, "type": "identifier", "text": "h", "parent": 545, "children": [], "start_point": {"row": 123, "column": 37}, "end_point": {"row": 123, "column": 38}}, {"id": 549, "type": "identifier", "text": "LPCWSTR", "parent": 544, "children": [], "start_point": {"row": 123, "column": 40}, "end_point": {"row": 123, "column": 47}}, {"id": 550, "type": "ERROR", "text": "pName", "parent": 544, "children": [551], "start_point": {"row": 123, "column": 48}, "end_point": {"row": 123, "column": 53}}, {"id": 551, "type": "identifier", "text": "pName", "parent": 550, "children": [], "start_point": {"row": 123, "column": 48}, "end_point": {"row": 123, "column": 53}}, {"id": 552, "type": "binary_expression", "text": "CBaseFilter* pFilter", "parent": 544, "children": [553, 554, 555], "start_point": {"row": 123, "column": 55}, "end_point": {"row": 123, "column": 75}}, {"id": 553, "type": "identifier", "text": "CBaseFilter", "parent": 552, "children": [], "start_point": {"row": 123, "column": 55}, "end_point": {"row": 123, "column": 66}}, {"id": 554, "type": "*", "text": "*", "parent": 552, "children": [], "start_point": {"row": 123, "column": 66}, "end_point": {"row": 123, "column": 67}}, {"id": 555, "type": "identifier", "text": "pFilter", "parent": 552, "children": [], "start_point": {"row": 123, "column": 68}, "end_point": {"row": 123, "column": 75}}, {"id": 556, "type": "binary_expression", "text": "CCritSec* pLock", "parent": 544, "children": [557, 558, 559], "start_point": {"row": 123, "column": 77}, "end_point": {"row": 123, "column": 92}}, {"id": 557, "type": "identifier", "text": "CCritSec", "parent": 556, "children": [], "start_point": {"row": 123, "column": 77}, "end_point": {"row": 123, "column": 85}}, {"id": 558, "type": "*", "text": "*", "parent": 556, "children": [], "start_point": {"row": 123, "column": 85}, "end_point": {"row": 123, "column": 86}}, {"id": 559, "type": "identifier", "text": "pLock", "parent": 556, "children": [], "start_point": {"row": 123, "column": 87}, "end_point": {"row": 123, "column": 92}}, {"id": 560, "type": "binary_expression", "text": "HRESULT* phr", "parent": 544, "children": [561, 562, 563], "start_point": {"row": 123, "column": 94}, "end_point": {"row": 123, "column": 106}}, {"id": 561, "type": "identifier", "text": "HRESULT", "parent": 560, "children": [], "start_point": {"row": 123, "column": 94}, "end_point": {"row": 123, "column": 101}}, {"id": 562, "type": "*", "text": "*", "parent": 560, "children": [], "start_point": {"row": 123, "column": 101}, "end_point": {"row": 123, "column": 102}}, {"id": 563, "type": "identifier", "text": "phr", "parent": 560, "children": [], "start_point": {"row": 123, "column": 103}, "end_point": {"row": 123, "column": 106}}, {"id": 564, "type": "function_definition", "text": "class COggAudioOutputPin : public COggStreamOutputPin\n{\npublic:\n\tCOggAudioOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}", "parent": null, "children": [565, 567], "start_point": {"row": 126, "column": 0}, "end_point": {"row": 130, "column": 1}}, {"id": 565, "type": "ERROR", "text": "COggAudioOutputPin : public", "parent": 564, "children": [566], "start_point": {"row": 126, "column": 6}, "end_point": {"row": 126, "column": 33}}, {"id": 566, "type": "identifier", "text": "COggAudioOutputPin", "parent": 565, "children": [], "start_point": {"row": 126, "column": 6}, "end_point": {"row": 126, "column": 24}}, {"id": 567, "type": "identifier", "text": "COggStreamOutputPin", "parent": 564, "children": [], "start_point": {"row": 126, "column": 34}, "end_point": {"row": 126, "column": 53}}, {"id": 568, "type": "labeled_statement", "text": "public:\n\tCOggAudioOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 564, "children": [], "start_point": {"row": 128, "column": 0}, "end_point": {"row": 129, "column": 108}}, {"id": 569, "type": "call_expression", "text": "COggAudioOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 568, "children": [570, 571], "start_point": {"row": 129, "column": 1}, "end_point": {"row": 129, "column": 107}}, {"id": 570, "type": "identifier", "text": "COggAudioOutputPin", "parent": 569, "children": [], "start_point": {"row": 129, "column": 1}, "end_point": {"row": 129, "column": 19}}, {"id": 571, "type": "argument_list", "text": "(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 569, "children": [572, 576, 577, 579, 583, 587], "start_point": {"row": 129, "column": 19}, "end_point": {"row": 129, "column": 107}}, {"id": 572, "type": "binary_expression", "text": "OggStreamHeader* h", "parent": 571, "children": [573, 574, 575], "start_point": {"row": 129, "column": 20}, "end_point": {"row": 129, "column": 38}}, {"id": 573, "type": "identifier", "text": "OggStreamHeader", "parent": 572, "children": [], "start_point": {"row": 129, "column": 20}, "end_point": {"row": 129, "column": 35}}, {"id": 574, "type": "*", "text": "*", "parent": 572, "children": [], "start_point": {"row": 129, "column": 35}, "end_point": {"row": 129, "column": 36}}, {"id": 575, "type": "identifier", "text": "h", "parent": 572, "children": [], "start_point": {"row": 129, "column": 37}, "end_point": {"row": 129, "column": 38}}, {"id": 576, "type": "identifier", "text": "LPCWSTR", "parent": 571, "children": [], "start_point": {"row": 129, "column": 40}, "end_point": {"row": 129, "column": 47}}, {"id": 577, "type": "ERROR", "text": "pName", "parent": 571, "children": [578], "start_point": {"row": 129, "column": 48}, "end_point": {"row": 129, "column": 53}}, {"id": 578, "type": "identifier", "text": "pName", "parent": 577, "children": [], "start_point": {"row": 129, "column": 48}, "end_point": {"row": 129, "column": 53}}, {"id": 579, "type": "binary_expression", "text": "CBaseFilter* pFilter", "parent": 571, "children": [580, 581, 582], "start_point": {"row": 129, "column": 55}, "end_point": {"row": 129, "column": 75}}, {"id": 580, "type": "identifier", "text": "CBaseFilter", "parent": 579, "children": [], "start_point": {"row": 129, "column": 55}, "end_point": {"row": 129, "column": 66}}, {"id": 581, "type": "*", "text": "*", "parent": 579, "children": [], "start_point": {"row": 129, "column": 66}, "end_point": {"row": 129, "column": 67}}, {"id": 582, "type": "identifier", "text": "pFilter", "parent": 579, "children": [], "start_point": {"row": 129, "column": 68}, "end_point": {"row": 129, "column": 75}}, {"id": 583, "type": "binary_expression", "text": "CCritSec* pLock", "parent": 571, "children": [584, 585, 586], "start_point": {"row": 129, "column": 77}, "end_point": {"row": 129, "column": 92}}, {"id": 584, "type": "identifier", "text": "CCritSec", "parent": 583, "children": [], "start_point": {"row": 129, "column": 77}, "end_point": {"row": 129, "column": 85}}, {"id": 585, "type": "*", "text": "*", "parent": 583, "children": [], "start_point": {"row": 129, "column": 85}, "end_point": {"row": 129, "column": 86}}, {"id": 586, "type": "identifier", "text": "pLock", "parent": 583, "children": [], "start_point": {"row": 129, "column": 87}, "end_point": {"row": 129, "column": 92}}, {"id": 587, "type": "binary_expression", "text": "HRESULT* phr", "parent": 571, "children": [588, 589, 590], "start_point": {"row": 129, "column": 94}, "end_point": {"row": 129, "column": 106}}, {"id": 588, "type": "identifier", "text": "HRESULT", "parent": 587, "children": [], "start_point": {"row": 129, "column": 94}, "end_point": {"row": 129, "column": 101}}, {"id": 589, "type": "*", "text": "*", "parent": 587, "children": [], "start_point": {"row": 129, "column": 101}, "end_point": {"row": 129, "column": 102}}, {"id": 590, "type": "identifier", "text": "phr", "parent": 587, "children": [], "start_point": {"row": 129, "column": 103}, "end_point": {"row": 129, "column": 106}}, {"id": 591, "type": "function_definition", "text": "class COggTextOutputPin : public COggStreamOutputPin\n{\npublic:\n\tCOggTextOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}", "parent": null, "children": [592, 594], "start_point": {"row": 132, "column": 0}, "end_point": {"row": 136, "column": 1}}, {"id": 592, "type": "ERROR", "text": "COggTextOutputPin : public", "parent": 591, "children": [593], "start_point": {"row": 132, "column": 6}, "end_point": {"row": 132, "column": 32}}, {"id": 593, "type": "identifier", "text": "COggTextOutputPin", "parent": 592, "children": [], "start_point": {"row": 132, "column": 6}, "end_point": {"row": 132, "column": 23}}, {"id": 594, "type": "identifier", "text": "COggStreamOutputPin", "parent": 591, "children": [], "start_point": {"row": 132, "column": 33}, "end_point": {"row": 132, "column": 52}}, {"id": 595, "type": "labeled_statement", "text": "public:\n\tCOggTextOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 591, "children": [], "start_point": {"row": 134, "column": 0}, "end_point": {"row": 135, "column": 107}}, {"id": 596, "type": "call_expression", "text": "COggTextOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 595, "children": [597, 598], "start_point": {"row": 135, "column": 1}, "end_point": {"row": 135, "column": 106}}, {"id": 597, "type": "identifier", "text": "COggTextOutputPin", "parent": 596, "children": [], "start_point": {"row": 135, "column": 1}, "end_point": {"row": 135, "column": 18}}, {"id": 598, "type": "argument_list", "text": "(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 596, "children": [599, 603, 604, 606, 610, 614], "start_point": {"row": 135, "column": 18}, "end_point": {"row": 135, "column": 106}}, {"id": 599, "type": "binary_expression", "text": "OggStreamHeader* h", "parent": 598, "children": [600, 601, 602], "start_point": {"row": 135, "column": 19}, "end_point": {"row": 135, "column": 37}}, {"id": 600, "type": "identifier", "text": "OggStreamHeader", "parent": 599, "children": [], "start_point": {"row": 135, "column": 19}, "end_point": {"row": 135, "column": 34}}, {"id": 601, "type": "*", "text": "*", "parent": 599, "children": [], "start_point": {"row": 135, "column": 34}, "end_point": {"row": 135, "column": 35}}, {"id": 602, "type": "identifier", "text": "h", "parent": 599, "children": [], "start_point": {"row": 135, "column": 36}, "end_point": {"row": 135, "column": 37}}, {"id": 603, "type": "identifier", "text": "LPCWSTR", "parent": 598, "children": [], "start_point": {"row": 135, "column": 39}, "end_point": {"row": 135, "column": 46}}, {"id": 604, "type": "ERROR", "text": "pName", "parent": 598, "children": [605], "start_point": {"row": 135, "column": 47}, "end_point": {"row": 135, "column": 52}}, {"id": 605, "type": "identifier", "text": "pName", "parent": 604, "children": [], "start_point": {"row": 135, "column": 47}, "end_point": {"row": 135, "column": 52}}, {"id": 606, "type": "binary_expression", "text": "CBaseFilter* pFilter", "parent": 598, "children": [607, 608, 609], "start_point": {"row": 135, "column": 54}, "end_point": {"row": 135, "column": 74}}, {"id": 607, "type": "identifier", "text": "CBaseFilter", "parent": 606, "children": [], "start_point": {"row": 135, "column": 54}, "end_point": {"row": 135, "column": 65}}, {"id": 608, "type": "*", "text": "*", "parent": 606, "children": [], "start_point": {"row": 135, "column": 65}, "end_point": {"row": 135, "column": 66}}, {"id": 609, "type": "identifier", "text": "pFilter", "parent": 606, "children": [], "start_point": {"row": 135, "column": 67}, "end_point": {"row": 135, "column": 74}}, {"id": 610, "type": "binary_expression", "text": "CCritSec* pLock", "parent": 598, "children": [611, 612, 613], "start_point": {"row": 135, "column": 76}, "end_point": {"row": 135, "column": 91}}, {"id": 611, "type": "identifier", "text": "CCritSec", "parent": 610, "children": [], "start_point": {"row": 135, "column": 76}, "end_point": {"row": 135, "column": 84}}, {"id": 612, "type": "*", "text": "*", "parent": 610, "children": [], "start_point": {"row": 135, "column": 84}, "end_point": {"row": 135, "column": 85}}, {"id": 613, "type": "identifier", "text": "pLock", "parent": 610, "children": [], "start_point": {"row": 135, "column": 86}, "end_point": {"row": 135, "column": 91}}, {"id": 614, "type": "binary_expression", "text": "HRESULT* phr", "parent": 598, "children": [615, 616, 617], "start_point": {"row": 135, "column": 93}, "end_point": {"row": 135, "column": 105}}, {"id": 615, "type": "identifier", "text": "HRESULT", "parent": 614, "children": [], "start_point": {"row": 135, "column": 93}, "end_point": {"row": 135, "column": 100}}, {"id": 616, "type": "*", "text": "*", "parent": 614, "children": [], "start_point": {"row": 135, "column": 100}, "end_point": {"row": 135, "column": 101}}, {"id": 617, "type": "identifier", "text": "phr", "parent": 614, "children": [], "start_point": {"row": 135, "column": 102}, "end_point": {"row": 135, "column": 105}}, {"id": 618, "type": "function_definition", "text": "class COggKateOutputPin : public COggStreamOutputPin\n{\npublic:\n\tCOggKateOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}", "parent": null, "children": [619, 621], "start_point": {"row": 138, "column": 0}, "end_point": {"row": 142, "column": 1}}, {"id": 619, "type": "ERROR", "text": "COggKateOutputPin : public", "parent": 618, "children": [620], "start_point": {"row": 138, "column": 6}, "end_point": {"row": 138, "column": 32}}, {"id": 620, "type": "identifier", "text": "COggKateOutputPin", "parent": 619, "children": [], "start_point": {"row": 138, "column": 6}, "end_point": {"row": 138, "column": 23}}, {"id": 621, "type": "identifier", "text": "COggStreamOutputPin", "parent": 618, "children": [], "start_point": {"row": 138, "column": 33}, "end_point": {"row": 138, "column": 52}}, {"id": 622, "type": "labeled_statement", "text": "public:\n\tCOggKateOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 618, "children": [], "start_point": {"row": 140, "column": 0}, "end_point": {"row": 141, "column": 107}}, {"id": 623, "type": "call_expression", "text": "COggKateOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 622, "children": [624, 625], "start_point": {"row": 141, "column": 1}, "end_point": {"row": 141, "column": 106}}, {"id": 624, "type": "identifier", "text": "COggKateOutputPin", "parent": 623, "children": [], "start_point": {"row": 141, "column": 1}, "end_point": {"row": 141, "column": 18}}, {"id": 625, "type": "argument_list", "text": "(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 623, "children": [626, 630, 631, 633, 637, 641], "start_point": {"row": 141, "column": 18}, "end_point": {"row": 141, "column": 106}}, {"id": 626, "type": "binary_expression", "text": "OggStreamHeader* h", "parent": 625, "children": [627, 628, 629], "start_point": {"row": 141, "column": 19}, "end_point": {"row": 141, "column": 37}}, {"id": 627, "type": "identifier", "text": "OggStreamHeader", "parent": 626, "children": [], "start_point": {"row": 141, "column": 19}, "end_point": {"row": 141, "column": 34}}, {"id": 628, "type": "*", "text": "*", "parent": 626, "children": [], "start_point": {"row": 141, "column": 34}, "end_point": {"row": 141, "column": 35}}, {"id": 629, "type": "identifier", "text": "h", "parent": 626, "children": [], "start_point": {"row": 141, "column": 36}, "end_point": {"row": 141, "column": 37}}, {"id": 630, "type": "identifier", "text": "LPCWSTR", "parent": 625, "children": [], "start_point": {"row": 141, "column": 39}, "end_point": {"row": 141, "column": 46}}, {"id": 631, "type": "ERROR", "text": "pName", "parent": 625, "children": [632], "start_point": {"row": 141, "column": 47}, "end_point": {"row": 141, "column": 52}}, {"id": 632, "type": "identifier", "text": "pName", "parent": 631, "children": [], "start_point": {"row": 141, "column": 47}, "end_point": {"row": 141, "column": 52}}, {"id": 633, "type": "binary_expression", "text": "CBaseFilter* pFilter", "parent": 625, "children": [634, 635, 636], "start_point": {"row": 141, "column": 54}, "end_point": {"row": 141, "column": 74}}, {"id": 634, "type": "identifier", "text": "CBaseFilter", "parent": 633, "children": [], "start_point": {"row": 141, "column": 54}, "end_point": {"row": 141, "column": 65}}, {"id": 635, "type": "*", "text": "*", "parent": 633, "children": [], "start_point": {"row": 141, "column": 65}, "end_point": {"row": 141, "column": 66}}, {"id": 636, "type": "identifier", "text": "pFilter", "parent": 633, "children": [], "start_point": {"row": 141, "column": 67}, "end_point": {"row": 141, "column": 74}}, {"id": 637, "type": "binary_expression", "text": "CCritSec* pLock", "parent": 625, "children": [638, 639, 640], "start_point": {"row": 141, "column": 76}, "end_point": {"row": 141, "column": 91}}, {"id": 638, "type": "identifier", "text": "CCritSec", "parent": 637, "children": [], "start_point": {"row": 141, "column": 76}, "end_point": {"row": 141, "column": 84}}, {"id": 639, "type": "*", "text": "*", "parent": 637, "children": [], "start_point": {"row": 141, "column": 84}, "end_point": {"row": 141, "column": 85}}, {"id": 640, "type": "identifier", "text": "pLock", "parent": 637, "children": [], "start_point": {"row": 141, "column": 86}, "end_point": {"row": 141, "column": 91}}, {"id": 641, "type": "binary_expression", "text": "HRESULT* phr", "parent": 625, "children": [642, 643, 644], "start_point": {"row": 141, "column": 93}, "end_point": {"row": 141, "column": 105}}, {"id": 642, "type": "identifier", "text": "HRESULT", "parent": 641, "children": [], "start_point": {"row": 141, "column": 93}, "end_point": {"row": 141, "column": 100}}, {"id": 643, "type": "*", "text": "*", "parent": 641, "children": [], "start_point": {"row": 141, "column": 100}, "end_point": {"row": 141, "column": 101}}, {"id": 644, "type": "identifier", "text": "phr", "parent": 641, "children": [], "start_point": {"row": 141, "column": 102}, "end_point": {"row": 141, "column": 105}}, {"id": 645, "type": "function_definition", "text": "class COggTheoraOutputPin : public COggSplitterOutputPin\n{\n\tstd::list<CAutoPtr<CPacket>> m_initpackets;\n\tLONG m_KfgShift;\n\tLONG m_KfgMask;\n\tUINT m_nVersion;\n\tREFERENCE_TIME m_rtAvgTimePerFrame;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggTheoraOutputPin(OggPage& page, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n\tHRESULT UnpackInitPage(OggPage& page);\n\tbool IsInitialized() {\n\t\treturn m_initpackets.size() >= 3;\n\t}\n}", "parent": null, "children": [646, 648], "start_point": {"row": 144, "column": 0}, "end_point": {"row": 162, "column": 1}}, {"id": 646, "type": "ERROR", "text": "COggTheoraOutputPin : public", "parent": 645, "children": [647], "start_point": {"row": 144, "column": 6}, "end_point": {"row": 144, "column": 34}}, {"id": 647, "type": "identifier", "text": "COggTheoraOutputPin", "parent": 646, "children": [], "start_point": {"row": 144, "column": 6}, "end_point": {"row": 144, "column": 25}}, {"id": 648, "type": "identifier", "text": "COggSplitterOutputPin", "parent": 645, "children": [], "start_point": {"row": 144, "column": 35}, "end_point": {"row": 144, "column": 56}}, {"id": 649, "type": "labeled_statement", "text": "std::list<CAutoPtr<CPacket>> m_initpackets;", "parent": 645, "children": [650], "start_point": {"row": 146, "column": 1}, "end_point": {"row": 146, "column": 44}}, {"id": 650, "type": "statement_identifier", "text": "std", "parent": 649, "children": [], "start_point": {"row": 146, "column": 1}, "end_point": {"row": 146, "column": 4}}, {"id": 651, "type": "binary_expression", "text": "list<CAutoPtr<CPacket>> m_initpackets", "parent": 649, "children": [652, 656, 657], "start_point": {"row": 146, "column": 6}, "end_point": {"row": 146, "column": 43}}, {"id": 652, "type": "binary_expression", "text": "list<CAutoPtr", "parent": 651, "children": [653, 654, 655], "start_point": {"row": 146, "column": 6}, "end_point": {"row": 146, "column": 19}}, {"id": 653, "type": "identifier", "text": "list", "parent": 652, "children": [], "start_point": {"row": 146, "column": 6}, "end_point": {"row": 146, "column": 10}}, {"id": 654, "type": "<", "text": "<", "parent": 652, "children": [], "start_point": {"row": 146, "column": 10}, "end_point": {"row": 146, "column": 11}}, {"id": 655, "type": "identifier", "text": "CAutoPtr", "parent": 652, "children": [], "start_point": {"row": 146, "column": 11}, "end_point": {"row": 146, "column": 19}}, {"id": 656, "type": "<", "text": "<", "parent": 651, "children": [], "start_point": {"row": 146, "column": 19}, "end_point": {"row": 146, "column": 20}}, {"id": 657, "type": "binary_expression", "text": "CPacket>> m_initpackets", "parent": 651, "children": [658, 659, 660], "start_point": {"row": 146, "column": 20}, "end_point": {"row": 146, "column": 43}}, {"id": 658, "type": "identifier", "text": "CPacket", "parent": 657, "children": [], "start_point": {"row": 146, "column": 20}, "end_point": {"row": 146, "column": 27}}, {"id": 659, "type": ">>", "text": ">>", "parent": 657, "children": [], "start_point": {"row": 146, "column": 27}, "end_point": {"row": 146, "column": 29}}, {"id": 660, "type": "identifier", "text": "m_initpackets", "parent": 657, "children": [], "start_point": {"row": 146, "column": 30}, "end_point": {"row": 146, "column": 43}}, {"id": 661, "type": "declaration", "text": "LONG m_KfgShift;", "parent": 645, "children": [662, 663], "start_point": {"row": 147, "column": 1}, "end_point": {"row": 147, "column": 41}}, {"id": 662, "type": "type_identifier", "text": "LONG", "parent": 661, "children": [], "start_point": {"row": 147, "column": 1}, "end_point": {"row": 147, "column": 5}}, {"id": 663, "type": "identifier", "text": "m_KfgShift", "parent": 661, "children": [], "start_point": {"row": 147, "column": 30}, "end_point": {"row": 147, "column": 40}}, {"id": 664, "type": "declaration", "text": "LONG m_KfgMask;", "parent": 645, "children": [665, 666], "start_point": {"row": 148, "column": 1}, "end_point": {"row": 148, "column": 40}}, {"id": 665, "type": "type_identifier", "text": "LONG", "parent": 664, "children": [], "start_point": {"row": 148, "column": 1}, "end_point": {"row": 148, "column": 5}}, {"id": 666, "type": "identifier", "text": "m_KfgMask", "parent": 664, "children": [], "start_point": {"row": 148, "column": 30}, "end_point": {"row": 148, "column": 39}}, {"id": 667, "type": "declaration", "text": "UINT m_nVersion;", "parent": 645, "children": [668, 669], "start_point": {"row": 149, "column": 1}, "end_point": {"row": 149, "column": 41}}, {"id": 668, "type": "type_identifier", "text": "UINT", "parent": 667, "children": [], "start_point": {"row": 149, "column": 1}, "end_point": {"row": 149, "column": 5}}, {"id": 669, "type": "identifier", "text": "m_nVersion", "parent": 667, "children": [], "start_point": {"row": 149, "column": 30}, "end_point": {"row": 149, "column": 40}}, {"id": 670, "type": "declaration", "text": "REFERENCE_TIME m_rtAvgTimePerFrame;", "parent": 645, "children": [671, 672], "start_point": {"row": 150, "column": 1}, "end_point": {"row": 150, "column": 50}}, {"id": 671, "type": "type_identifier", "text": "REFERENCE_TIME", "parent": 670, "children": [], "start_point": {"row": 150, "column": 1}, "end_point": {"row": 150, "column": 15}}, {"id": 672, "type": "identifier", "text": "m_rtAvgTimePerFrame", "parent": 670, "children": [], "start_point": {"row": 150, "column": 30}, "end_point": {"row": 150, "column": 49}}, {"id": 673, "type": "declaration", "text": "virtual HRESULT", "parent": 645, "children": [674, 675], "start_point": {"row": 152, "column": 1}, "end_point": {"row": 152, "column": 16}}, {"id": 674, "type": "type_identifier", "text": "virtual", "parent": 673, "children": [], "start_point": {"row": 152, "column": 1}, "end_point": {"row": 152, "column": 8}}, {"id": 675, "type": "identifier", "text": "HRESULT", "parent": 673, "children": [], "start_point": {"row": 152, "column": 9}, "end_point": {"row": 152, "column": 16}}, {"id": 676, "type": "call_expression", "text": "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 645, "children": [677, 678], "start_point": {"row": 152, "column": 17}, "end_point": {"row": 152, "column": 73}}, {"id": 677, "type": "identifier", "text": "UnpackPacket", "parent": 676, "children": [], "start_point": {"row": 152, "column": 17}, "end_point": {"row": 152, "column": 29}}, {"id": 678, "type": "argument_list", "text": "(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 676, "children": [679, 687, 691, 692], "start_point": {"row": 152, "column": 29}, "end_point": {"row": 152, "column": 73}}, {"id": 679, "type": "binary_expression", "text": "CAutoPtr<CPacket>& p", "parent": 678, "children": [680, 684, 685], "start_point": {"row": 152, "column": 30}, "end_point": {"row": 152, "column": 50}}, {"id": 680, "type": "binary_expression", "text": "CAutoPtr<CPacket", "parent": 679, "children": [681, 682, 683], "start_point": {"row": 152, "column": 30}, "end_point": {"row": 152, "column": 46}}, {"id": 681, "type": "identifier", "text": "CAutoPtr", "parent": 680, "children": [], "start_point": {"row": 152, "column": 30}, "end_point": {"row": 152, "column": 38}}, {"id": 682, "type": "<", "text": "<", "parent": 680, "children": [], "start_point": {"row": 152, "column": 38}, "end_point": {"row": 152, "column": 39}}, {"id": 683, "type": "identifier", "text": "CPacket", "parent": 680, "children": [], "start_point": {"row": 152, "column": 39}, "end_point": {"row": 152, "column": 46}}, {"id": 684, "type": ">", "text": ">", "parent": 679, "children": [], "start_point": {"row": 152, "column": 46}, "end_point": {"row": 152, "column": 47}}, {"id": 685, "type": "pointer_expression", "text": "& p", "parent": 679, "children": [686], "start_point": {"row": 152, "column": 47}, "end_point": {"row": 152, "column": 50}}, {"id": 686, "type": "identifier", "text": "p", "parent": 685, "children": [], "start_point": {"row": 152, "column": 49}, "end_point": {"row": 152, "column": 50}}, {"id": 687, "type": "binary_expression", "text": "BYTE* pData", "parent": 678, "children": [688, 689, 690], "start_point": {"row": 152, "column": 52}, "end_point": {"row": 152, "column": 63}}, {"id": 688, "type": "identifier", "text": "BYTE", "parent": 687, "children": [], "start_point": {"row": 152, "column": 52}, "end_point": {"row": 152, "column": 56}}, {"id": 689, "type": "*", "text": "*", "parent": 687, "children": [], "start_point": {"row": 152, "column": 56}, "end_point": {"row": 152, "column": 57}}, {"id": 690, "type": "identifier", "text": "pData", "parent": 687, "children": [], "start_point": {"row": 152, "column": 58}, "end_point": {"row": 152, "column": 63}}, {"id": 691, "type": "identifier", "text": "int", "parent": 678, "children": [], "start_point": {"row": 152, "column": 65}, "end_point": {"row": 152, "column": 68}}, {"id": 692, "type": "ERROR", "text": "len", "parent": 678, "children": [693], "start_point": {"row": 152, "column": 69}, "end_point": {"row": 152, "column": 72}}, {"id": 693, "type": "identifier", "text": "len", "parent": 692, "children": [], "start_point": {"row": 152, "column": 69}, "end_point": {"row": 152, "column": 72}}, {"id": 694, "type": "declaration", "text": "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);", "parent": 645, "children": [695, 696, 698], "start_point": {"row": 153, "column": 1}, "end_point": {"row": 153, "column": 61}}, {"id": 695, "type": "type_identifier", "text": "virtual", "parent": 694, "children": [], "start_point": {"row": 153, "column": 1}, "end_point": {"row": 153, "column": 8}}, {"id": 696, "type": "ERROR", "text": "REFERENCE_TIME", "parent": 694, "children": [697], "start_point": {"row": 153, "column": 9}, "end_point": {"row": 153, "column": 23}}, {"id": 697, "type": "identifier", "text": "REFERENCE_TIME", "parent": 696, "children": [], "start_point": {"row": 153, "column": 9}, "end_point": {"row": 153, "column": 23}}, {"id": 698, "type": "function_declarator", "text": "GetRefTime(__int64 granule_position)", "parent": 694, "children": [699, 700], "start_point": {"row": 153, "column": 24}, "end_point": {"row": 153, "column": 60}}, {"id": 699, "type": "identifier", "text": "GetRefTime", "parent": 698, "children": [], "start_point": {"row": 153, "column": 24}, "end_point": {"row": 153, "column": 34}}, {"id": 700, "type": "parameter_list", "text": "(__int64 granule_position)", "parent": 698, "children": [701], "start_point": {"row": 153, "column": 34}, "end_point": {"row": 153, "column": 60}}, {"id": 701, "type": "parameter_declaration", "text": "__int64 granule_position", "parent": 700, "children": [702, 703], "start_point": {"row": 153, "column": 35}, "end_point": {"row": 153, "column": 59}}, {"id": 702, "type": "type_identifier", "text": "__int64", "parent": 701, "children": [], "start_point": {"row": 153, "column": 35}, "end_point": {"row": 153, "column": 42}}, {"id": 703, "type": "identifier", "text": "granule_position", "parent": 701, "children": [], "start_point": {"row": 153, "column": 43}, "end_point": {"row": 153, "column": 59}}, {"id": 704, "type": "labeled_statement", "text": "public:\n\tCOggTheoraOutputPin(OggPage& page, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 645, "children": [], "start_point": {"row": 155, "column": 0}, "end_point": {"row": 156, "column": 104}}, {"id": 705, "type": "call_expression", "text": "COggTheoraOutputPin(OggPage& page, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 704, "children": [706, 707], "start_point": {"row": 156, "column": 1}, "end_point": {"row": 156, "column": 103}}, {"id": 706, "type": "identifier", "text": "COggTheoraOutputPin", "parent": 705, "children": [], "start_point": {"row": 156, "column": 1}, "end_point": {"row": 156, "column": 20}}, {"id": 707, "type": "argument_list", "text": "(OggPage& page, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 705, "children": [708, 711, 712, 714, 718, 722], "start_point": {"row": 156, "column": 20}, "end_point": {"row": 156, "column": 103}}, {"id": 708, "type": "binary_expression", "text": "OggPage& page", "parent": 707, "children": [709, 710], "start_point": {"row": 156, "column": 21}, "end_point": {"row": 156, "column": 34}}, {"id": 709, "type": "identifier", "text": "OggPage", "parent": 708, "children": [], "start_point": {"row": 156, "column": 21}, "end_point": {"row": 156, "column": 28}}, {"id": 710, "type": "identifier", "text": "page", "parent": 708, "children": [], "start_point": {"row": 156, "column": 30}, "end_point": {"row": 156, "column": 34}}, {"id": 711, "type": "identifier", "text": "LPCWSTR", "parent": 707, "children": [], "start_point": {"row": 156, "column": 36}, "end_point": {"row": 156, "column": 43}}, {"id": 712, "type": "ERROR", "text": "pName", "parent": 707, "children": [713], "start_point": {"row": 156, "column": 44}, "end_point": {"row": 156, "column": 49}}, {"id": 713, "type": "identifier", "text": "pName", "parent": 712, "children": [], "start_point": {"row": 156, "column": 44}, "end_point": {"row": 156, "column": 49}}, {"id": 714, "type": "binary_expression", "text": "CBaseFilter* pFilter", "parent": 707, "children": [715, 716, 717], "start_point": {"row": 156, "column": 51}, "end_point": {"row": 156, "column": 71}}, {"id": 715, "type": "identifier", "text": "CBaseFilter", "parent": 714, "children": [], "start_point": {"row": 156, "column": 51}, "end_point": {"row": 156, "column": 62}}, {"id": 716, "type": "*", "text": "*", "parent": 714, "children": [], "start_point": {"row": 156, "column": 62}, "end_point": {"row": 156, "column": 63}}, {"id": 717, "type": "identifier", "text": "pFilter", "parent": 714, "children": [], "start_point": {"row": 156, "column": 64}, "end_point": {"row": 156, "column": 71}}, {"id": 718, "type": "binary_expression", "text": "CCritSec* pLock", "parent": 707, "children": [719, 720, 721], "start_point": {"row": 156, "column": 73}, "end_point": {"row": 156, "column": 88}}, {"id": 719, "type": "identifier", "text": "CCritSec", "parent": 718, "children": [], "start_point": {"row": 156, "column": 73}, "end_point": {"row": 156, "column": 81}}, {"id": 720, "type": "*", "text": "*", "parent": 718, "children": [], "start_point": {"row": 156, "column": 81}, "end_point": {"row": 156, "column": 82}}, {"id": 721, "type": "identifier", "text": "pLock", "parent": 718, "children": [], "start_point": {"row": 156, "column": 83}, "end_point": {"row": 156, "column": 88}}, {"id": 722, "type": "binary_expression", "text": "HRESULT* phr", "parent": 707, "children": [723, 724, 725], "start_point": {"row": 156, "column": 90}, "end_point": {"row": 156, "column": 102}}, {"id": 723, "type": "identifier", "text": "HRESULT", "parent": 722, "children": [], "start_point": {"row": 156, "column": 90}, "end_point": {"row": 156, "column": 97}}, {"id": 724, "type": "*", "text": "*", "parent": 722, "children": [], "start_point": {"row": 156, "column": 97}, "end_point": {"row": 156, "column": 98}}, {"id": 725, "type": "identifier", "text": "phr", "parent": 722, "children": [], "start_point": {"row": 156, "column": 99}, "end_point": {"row": 156, "column": 102}}, {"id": 726, "type": "declaration", "text": "HRESULT UnpackInitPage(OggPage& page);", "parent": 645, "children": [727, 728], "start_point": {"row": 158, "column": 1}, "end_point": {"row": 158, "column": 39}}, {"id": 727, "type": "type_identifier", "text": "HRESULT", "parent": 726, "children": [], "start_point": {"row": 158, "column": 1}, "end_point": {"row": 158, "column": 8}}, {"id": 728, "type": "function_declarator", "text": "UnpackInitPage(OggPage& page)", "parent": 726, "children": [729, 730], "start_point": {"row": 158, "column": 9}, "end_point": {"row": 158, "column": 38}}, {"id": 729, "type": "identifier", "text": "UnpackInitPage", "parent": 728, "children": [], "start_point": {"row": 158, "column": 9}, "end_point": {"row": 158, "column": 23}}, {"id": 730, "type": "parameter_list", "text": "(OggPage& page)", "parent": 728, "children": [731], "start_point": {"row": 158, "column": 23}, "end_point": {"row": 158, "column": 38}}, {"id": 731, "type": "parameter_declaration", "text": "OggPage& page", "parent": 730, "children": [732, 733], "start_point": {"row": 158, "column": 24}, "end_point": {"row": 158, "column": 37}}, {"id": 732, "type": "type_identifier", "text": "OggPage", "parent": 731, "children": [], "start_point": {"row": 158, "column": 24}, "end_point": {"row": 158, "column": 31}}, {"id": 733, "type": "identifier", "text": "page", "parent": 731, "children": [], "start_point": {"row": 158, "column": 33}, "end_point": {"row": 158, "column": 37}}, {"id": 734, "type": "function_definition", "text": "bool IsInitialized() {\n\t\treturn m_initpackets.size() >= 3;\n\t}", "parent": 645, "children": [735, 736], "start_point": {"row": 159, "column": 1}, "end_point": {"row": 161, "column": 2}}, {"id": 735, "type": "primitive_type", "text": "bool", "parent": 734, "children": [], "start_point": {"row": 159, "column": 1}, "end_point": {"row": 159, "column": 5}}, {"id": 736, "type": "function_declarator", "text": "IsInitialized()", "parent": 734, "children": [737, 738], "start_point": {"row": 159, "column": 6}, "end_point": {"row": 159, "column": 21}}, {"id": 737, "type": "identifier", "text": "IsInitialized", "parent": 736, "children": [], "start_point": {"row": 159, "column": 6}, "end_point": {"row": 159, "column": 19}}, {"id": 738, "type": "parameter_list", "text": "()", "parent": 736, "children": [], "start_point": {"row": 159, "column": 19}, "end_point": {"row": 159, "column": 21}}, {"id": 739, "type": "return_statement", "text": "return m_initpackets.size() >= 3;", "parent": 734, "children": [740], "start_point": {"row": 160, "column": 2}, "end_point": {"row": 160, "column": 35}}, {"id": 740, "type": "binary_expression", "text": "m_initpackets.size() >= 3", "parent": 739, "children": [741, 746, 747], "start_point": {"row": 160, "column": 9}, "end_point": {"row": 160, "column": 34}}, {"id": 741, "type": "call_expression", "text": "m_initpackets.size()", "parent": 740, "children": [742, 745], "start_point": {"row": 160, "column": 9}, "end_point": {"row": 160, "column": 29}}, {"id": 742, "type": "field_expression", "text": "m_initpackets.size", "parent": 741, "children": [743, 744], "start_point": {"row": 160, "column": 9}, "end_point": {"row": 160, "column": 27}}, {"id": 743, "type": "identifier", "text": "m_initpackets", "parent": 742, "children": [], "start_point": {"row": 160, "column": 9}, "end_point": {"row": 160, "column": 22}}, {"id": 744, "type": "field_identifier", "text": "size", "parent": 742, "children": [], "start_point": {"row": 160, "column": 23}, "end_point": {"row": 160, "column": 27}}, {"id": 745, "type": "argument_list", "text": "()", "parent": 741, "children": [], "start_point": {"row": 160, "column": 27}, "end_point": {"row": 160, "column": 29}}, {"id": 746, "type": ">=", "text": ">=", "parent": 740, "children": [], "start_point": {"row": 160, "column": 30}, "end_point": {"row": 160, "column": 32}}, {"id": 747, "type": "number_literal", "text": "3", "parent": 740, "children": [], "start_point": {"row": 160, "column": 33}, "end_point": {"row": 160, "column": 34}}, {"id": 748, "type": "function_definition", "text": "class COggDiracOutputPin : public COggSplitterOutputPin\n{\n\tREFERENCE_TIME m_rtAvgTimePerFrame;\n\tbool m_bOldDirac;\n\tbool m_IsInitialized;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggDiracOutputPin(BYTE* p, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n\tHRESULT UnpackInitPage(OggPage& page);\n\tbool IsInitialized() {\n\t\treturn m_IsInitialized;\n\t}\n\tHRESULT InitDirac(BYTE* p, int nCount);\n}", "parent": null, "children": [749, 751], "start_point": {"row": 164, "column": 0}, "end_point": {"row": 181, "column": 1}}, {"id": 749, "type": "ERROR", "text": "COggDiracOutputPin : public", "parent": 748, "children": [750], "start_point": {"row": 164, "column": 6}, "end_point": {"row": 164, "column": 33}}, {"id": 750, "type": "identifier", "text": "COggDiracOutputPin", "parent": 749, "children": [], "start_point": {"row": 164, "column": 6}, "end_point": {"row": 164, "column": 24}}, {"id": 751, "type": "identifier", "text": "COggSplitterOutputPin", "parent": 748, "children": [], "start_point": {"row": 164, "column": 34}, "end_point": {"row": 164, "column": 55}}, {"id": 752, "type": "declaration", "text": "REFERENCE_TIME m_rtAvgTimePerFrame;", "parent": 748, "children": [753, 754], "start_point": {"row": 166, "column": 1}, "end_point": {"row": 166, "column": 36}}, {"id": 753, "type": "type_identifier", "text": "REFERENCE_TIME", "parent": 752, "children": [], "start_point": {"row": 166, "column": 1}, "end_point": {"row": 166, "column": 15}}, {"id": 754, "type": "identifier", "text": "m_rtAvgTimePerFrame", "parent": 752, "children": [], "start_point": {"row": 166, "column": 16}, "end_point": {"row": 166, "column": 35}}, {"id": 755, "type": "declaration", "text": "bool m_bOldDirac;", "parent": 748, "children": [756, 757], "start_point": {"row": 167, "column": 1}, "end_point": {"row": 167, "column": 28}}, {"id": 756, "type": "primitive_type", "text": "bool", "parent": 755, "children": [], "start_point": {"row": 167, "column": 1}, "end_point": {"row": 167, "column": 5}}, {"id": 757, "type": "identifier", "text": "m_bOldDirac", "parent": 755, "children": [], "start_point": {"row": 167, "column": 16}, "end_point": {"row": 167, "column": 27}}, {"id": 758, "type": "declaration", "text": "bool m_IsInitialized;", "parent": 748, "children": [759, 760], "start_point": {"row": 168, "column": 1}, "end_point": {"row": 168, "column": 32}}, {"id": 759, "type": "primitive_type", "text": "bool", "parent": 758, "children": [], "start_point": {"row": 168, "column": 1}, "end_point": {"row": 168, "column": 5}}, {"id": 760, "type": "identifier", "text": "m_IsInitialized", "parent": 758, "children": [], "start_point": {"row": 168, "column": 16}, "end_point": {"row": 168, "column": 31}}, {"id": 761, "type": "declaration", "text": "virtual HRESULT", "parent": 748, "children": [762, 763], "start_point": {"row": 170, "column": 1}, "end_point": {"row": 170, "column": 16}}, {"id": 762, "type": "type_identifier", "text": "virtual", "parent": 761, "children": [], "start_point": {"row": 170, "column": 1}, "end_point": {"row": 170, "column": 8}}, {"id": 763, "type": "identifier", "text": "HRESULT", "parent": 761, "children": [], "start_point": {"row": 170, "column": 9}, "end_point": {"row": 170, "column": 16}}, {"id": 764, "type": "call_expression", "text": "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 748, "children": [765, 766], "start_point": {"row": 170, "column": 17}, "end_point": {"row": 170, "column": 73}}, {"id": 765, "type": "identifier", "text": "UnpackPacket", "parent": 764, "children": [], "start_point": {"row": 170, "column": 17}, "end_point": {"row": 170, "column": 29}}, {"id": 766, "type": "argument_list", "text": "(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 764, "children": [767, 775, 779, 780], "start_point": {"row": 170, "column": 29}, "end_point": {"row": 170, "column": 73}}, {"id": 767, "type": "binary_expression", "text": "CAutoPtr<CPacket>& p", "parent": 766, "children": [768, 772, 773], "start_point": {"row": 170, "column": 30}, "end_point": {"row": 170, "column": 50}}, {"id": 768, "type": "binary_expression", "text": "CAutoPtr<CPacket", "parent": 767, "children": [769, 770, 771], "start_point": {"row": 170, "column": 30}, "end_point": {"row": 170, "column": 46}}, {"id": 769, "type": "identifier", "text": "CAutoPtr", "parent": 768, "children": [], "start_point": {"row": 170, "column": 30}, "end_point": {"row": 170, "column": 38}}, {"id": 770, "type": "<", "text": "<", "parent": 768, "children": [], "start_point": {"row": 170, "column": 38}, "end_point": {"row": 170, "column": 39}}, {"id": 771, "type": "identifier", "text": "CPacket", "parent": 768, "children": [], "start_point": {"row": 170, "column": 39}, "end_point": {"row": 170, "column": 46}}, {"id": 772, "type": ">", "text": ">", "parent": 767, "children": [], "start_point": {"row": 170, "column": 46}, "end_point": {"row": 170, "column": 47}}, {"id": 773, "type": "pointer_expression", "text": "& p", "parent": 767, "children": [774], "start_point": {"row": 170, "column": 47}, "end_point": {"row": 170, "column": 50}}, {"id": 774, "type": "identifier", "text": "p", "parent": 773, "children": [], "start_point": {"row": 170, "column": 49}, "end_point": {"row": 170, "column": 50}}, {"id": 775, "type": "binary_expression", "text": "BYTE* pData", "parent": 766, "children": [776, 777, 778], "start_point": {"row": 170, "column": 52}, "end_point": {"row": 170, "column": 63}}, {"id": 776, "type": "identifier", "text": "BYTE", "parent": 775, "children": [], "start_point": {"row": 170, "column": 52}, "end_point": {"row": 170, "column": 56}}, {"id": 777, "type": "*", "text": "*", "parent": 775, "children": [], "start_point": {"row": 170, "column": 56}, "end_point": {"row": 170, "column": 57}}, {"id": 778, "type": "identifier", "text": "pData", "parent": 775, "children": [], "start_point": {"row": 170, "column": 58}, "end_point": {"row": 170, "column": 63}}, {"id": 779, "type": "identifier", "text": "int", "parent": 766, "children": [], "start_point": {"row": 170, "column": 65}, "end_point": {"row": 170, "column": 68}}, {"id": 780, "type": "ERROR", "text": "len", "parent": 766, "children": [781], "start_point": {"row": 170, "column": 69}, "end_point": {"row": 170, "column": 72}}, {"id": 781, "type": "identifier", "text": "len", "parent": 780, "children": [], "start_point": {"row": 170, "column": 69}, "end_point": {"row": 170, "column": 72}}, {"id": 782, "type": "declaration", "text": "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);", "parent": 748, "children": [783, 784, 786], "start_point": {"row": 171, "column": 1}, "end_point": {"row": 171, "column": 61}}, {"id": 783, "type": "type_identifier", "text": "virtual", "parent": 782, "children": [], "start_point": {"row": 171, "column": 1}, "end_point": {"row": 171, "column": 8}}, {"id": 784, "type": "ERROR", "text": "REFERENCE_TIME", "parent": 782, "children": [785], "start_point": {"row": 171, "column": 9}, "end_point": {"row": 171, "column": 23}}, {"id": 785, "type": "identifier", "text": "REFERENCE_TIME", "parent": 784, "children": [], "start_point": {"row": 171, "column": 9}, "end_point": {"row": 171, "column": 23}}, {"id": 786, "type": "function_declarator", "text": "GetRefTime(__int64 granule_position)", "parent": 782, "children": [787, 788], "start_point": {"row": 171, "column": 24}, "end_point": {"row": 171, "column": 60}}, {"id": 787, "type": "identifier", "text": "GetRefTime", "parent": 786, "children": [], "start_point": {"row": 171, "column": 24}, "end_point": {"row": 171, "column": 34}}, {"id": 788, "type": "parameter_list", "text": "(__int64 granule_position)", "parent": 786, "children": [789], "start_point": {"row": 171, "column": 34}, "end_point": {"row": 171, "column": 60}}, {"id": 789, "type": "parameter_declaration", "text": "__int64 granule_position", "parent": 788, "children": [790, 791], "start_point": {"row": 171, "column": 35}, "end_point": {"row": 171, "column": 59}}, {"id": 790, "type": "type_identifier", "text": "__int64", "parent": 789, "children": [], "start_point": {"row": 171, "column": 35}, "end_point": {"row": 171, "column": 42}}, {"id": 791, "type": "identifier", "text": "granule_position", "parent": 789, "children": [], "start_point": {"row": 171, "column": 43}, "end_point": {"row": 171, "column": 59}}, {"id": 792, "type": "labeled_statement", "text": "public:\n\tCOggDiracOutputPin(BYTE* p, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 748, "children": [], "start_point": {"row": 173, "column": 0}, "end_point": {"row": 174, "column": 109}}, {"id": 793, "type": "call_expression", "text": "COggDiracOutputPin(BYTE* p, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 792, "children": [794, 795], "start_point": {"row": 174, "column": 1}, "end_point": {"row": 174, "column": 108}}, {"id": 794, "type": "identifier", "text": "COggDiracOutputPin", "parent": 793, "children": [], "start_point": {"row": 174, "column": 1}, "end_point": {"row": 174, "column": 19}}, {"id": 795, "type": "argument_list", "text": "(BYTE* p, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 793, "children": [796, 800, 802, 803, 804, 806, 810, 814], "start_point": {"row": 174, "column": 19}, "end_point": {"row": 174, "column": 108}}, {"id": 796, "type": "binary_expression", "text": "BYTE* p", "parent": 795, "children": [797, 798, 799], "start_point": {"row": 174, "column": 20}, "end_point": {"row": 174, "column": 27}}, {"id": 797, "type": "identifier", "text": "BYTE", "parent": 796, "children": [], "start_point": {"row": 174, "column": 20}, "end_point": {"row": 174, "column": 24}}, {"id": 798, "type": "*", "text": "*", "parent": 796, "children": [], "start_point": {"row": 174, "column": 24}, "end_point": {"row": 174, "column": 25}}, {"id": 799, "type": "identifier", "text": "p", "parent": 796, "children": [], "start_point": {"row": 174, "column": 26}, "end_point": {"row": 174, "column": 27}}, {"id": 800, "type": "ERROR", "text": "int", "parent": 795, "children": [801], "start_point": {"row": 174, "column": 29}, "end_point": {"row": 174, "column": 32}}, {"id": 801, "type": "identifier", "text": "int", "parent": 800, "children": [], "start_point": {"row": 174, "column": 29}, "end_point": {"row": 174, "column": 32}}, {"id": 802, "type": "identifier", "text": "nCount", "parent": 795, "children": [], "start_point": {"row": 174, "column": 33}, "end_point": {"row": 174, "column": 39}}, {"id": 803, "type": "identifier", "text": "LPCWSTR", "parent": 795, "children": [], "start_point": {"row": 174, "column": 41}, "end_point": {"row": 174, "column": 48}}, {"id": 804, "type": "ERROR", "text": "pName", "parent": 795, "children": [805], "start_point": {"row": 174, "column": 49}, "end_point": {"row": 174, "column": 54}}, {"id": 805, "type": "identifier", "text": "pName", "parent": 804, "children": [], "start_point": {"row": 174, "column": 49}, "end_point": {"row": 174, "column": 54}}, {"id": 806, "type": "binary_expression", "text": "CBaseFilter* pFilter", "parent": 795, "children": [807, 808, 809], "start_point": {"row": 174, "column": 56}, "end_point": {"row": 174, "column": 76}}, {"id": 807, "type": "identifier", "text": "CBaseFilter", "parent": 806, "children": [], "start_point": {"row": 174, "column": 56}, "end_point": {"row": 174, "column": 67}}, {"id": 808, "type": "*", "text": "*", "parent": 806, "children": [], "start_point": {"row": 174, "column": 67}, "end_point": {"row": 174, "column": 68}}, {"id": 809, "type": "identifier", "text": "pFilter", "parent": 806, "children": [], "start_point": {"row": 174, "column": 69}, "end_point": {"row": 174, "column": 76}}, {"id": 810, "type": "binary_expression", "text": "CCritSec* pLock", "parent": 795, "children": [811, 812, 813], "start_point": {"row": 174, "column": 78}, "end_point": {"row": 174, "column": 93}}, {"id": 811, "type": "identifier", "text": "CCritSec", "parent": 810, "children": [], "start_point": {"row": 174, "column": 78}, "end_point": {"row": 174, "column": 86}}, {"id": 812, "type": "*", "text": "*", "parent": 810, "children": [], "start_point": {"row": 174, "column": 86}, "end_point": {"row": 174, "column": 87}}, {"id": 813, "type": "identifier", "text": "pLock", "parent": 810, "children": [], "start_point": {"row": 174, "column": 88}, "end_point": {"row": 174, "column": 93}}, {"id": 814, "type": "binary_expression", "text": "HRESULT* phr", "parent": 795, "children": [815, 816, 817], "start_point": {"row": 174, "column": 95}, "end_point": {"row": 174, "column": 107}}, {"id": 815, "type": "identifier", "text": "HRESULT", "parent": 814, "children": [], "start_point": {"row": 174, "column": 95}, "end_point": {"row": 174, "column": 102}}, {"id": 816, "type": "*", "text": "*", "parent": 814, "children": [], "start_point": {"row": 174, "column": 102}, "end_point": {"row": 174, "column": 103}}, {"id": 817, "type": "identifier", "text": "phr", "parent": 814, "children": [], "start_point": {"row": 174, "column": 104}, "end_point": {"row": 174, "column": 107}}, {"id": 818, "type": "declaration", "text": "HRESULT UnpackInitPage(OggPage& page);", "parent": 748, "children": [819, 820], "start_point": {"row": 176, "column": 1}, "end_point": {"row": 176, "column": 39}}, {"id": 819, "type": "type_identifier", "text": "HRESULT", "parent": 818, "children": [], "start_point": {"row": 176, "column": 1}, "end_point": {"row": 176, "column": 8}}, {"id": 820, "type": "function_declarator", "text": "UnpackInitPage(OggPage& page)", "parent": 818, "children": [821, 822], "start_point": {"row": 176, "column": 9}, "end_point": {"row": 176, "column": 38}}, {"id": 821, "type": "identifier", "text": "UnpackInitPage", "parent": 820, "children": [], "start_point": {"row": 176, "column": 9}, "end_point": {"row": 176, "column": 23}}, {"id": 822, "type": "parameter_list", "text": "(OggPage& page)", "parent": 820, "children": [823], "start_point": {"row": 176, "column": 23}, "end_point": {"row": 176, "column": 38}}, {"id": 823, "type": "parameter_declaration", "text": "OggPage& page", "parent": 822, "children": [824, 825], "start_point": {"row": 176, "column": 24}, "end_point": {"row": 176, "column": 37}}, {"id": 824, "type": "type_identifier", "text": "OggPage", "parent": 823, "children": [], "start_point": {"row": 176, "column": 24}, "end_point": {"row": 176, "column": 31}}, {"id": 825, "type": "identifier", "text": "page", "parent": 823, "children": [], "start_point": {"row": 176, "column": 33}, "end_point": {"row": 176, "column": 37}}, {"id": 826, "type": "function_definition", "text": "bool IsInitialized() {\n\t\treturn m_IsInitialized;\n\t}", "parent": 748, "children": [827, 828], "start_point": {"row": 177, "column": 1}, "end_point": {"row": 179, "column": 2}}, {"id": 827, "type": "primitive_type", "text": "bool", "parent": 826, "children": [], "start_point": {"row": 177, "column": 1}, "end_point": {"row": 177, "column": 5}}, {"id": 828, "type": "function_declarator", "text": "IsInitialized()", "parent": 826, "children": [829, 830], "start_point": {"row": 177, "column": 6}, "end_point": {"row": 177, "column": 21}}, {"id": 829, "type": "identifier", "text": "IsInitialized", "parent": 828, "children": [], "start_point": {"row": 177, "column": 6}, "end_point": {"row": 177, "column": 19}}, {"id": 830, "type": "parameter_list", "text": "()", "parent": 828, "children": [], "start_point": {"row": 177, "column": 19}, "end_point": {"row": 177, "column": 21}}, {"id": 831, "type": "return_statement", "text": "return m_IsInitialized;", "parent": 826, "children": [832], "start_point": {"row": 178, "column": 2}, "end_point": {"row": 178, "column": 25}}, {"id": 832, "type": "identifier", "text": "m_IsInitialized", "parent": 831, "children": [], "start_point": {"row": 178, "column": 9}, "end_point": {"row": 178, "column": 24}}, {"id": 833, "type": "declaration", "text": "HRESULT InitDirac(BYTE* p, int nCount);", "parent": 748, "children": [834, 835], "start_point": {"row": 180, "column": 1}, "end_point": {"row": 180, "column": 40}}, {"id": 834, "type": "type_identifier", "text": "HRESULT", "parent": 833, "children": [], "start_point": {"row": 180, "column": 1}, "end_point": {"row": 180, "column": 8}}, {"id": 835, "type": "function_declarator", "text": "InitDirac(BYTE* p, int nCount)", "parent": 833, "children": [836, 837], "start_point": {"row": 180, "column": 9}, "end_point": {"row": 180, "column": 39}}, {"id": 836, "type": "identifier", "text": "InitDirac", "parent": 835, "children": [], "start_point": {"row": 180, "column": 9}, "end_point": {"row": 180, "column": 18}}, {"id": 837, "type": "parameter_list", "text": "(BYTE* p, int nCount)", "parent": 835, "children": [838, 843], "start_point": {"row": 180, "column": 18}, "end_point": {"row": 180, "column": 39}}, {"id": 838, "type": "parameter_declaration", "text": "BYTE* p", "parent": 837, "children": [839, 840], "start_point": {"row": 180, "column": 19}, "end_point": {"row": 180, "column": 26}}, {"id": 839, "type": "type_identifier", "text": "BYTE", "parent": 838, "children": [], "start_point": {"row": 180, "column": 19}, "end_point": {"row": 180, "column": 23}}, {"id": 840, "type": "pointer_declarator", "text": "* p", "parent": 838, "children": [841, 842], "start_point": {"row": 180, "column": 23}, "end_point": {"row": 180, "column": 26}}, {"id": 841, "type": "*", "text": "*", "parent": 840, "children": [], "start_point": {"row": 180, "column": 23}, "end_point": {"row": 180, "column": 24}}, {"id": 842, "type": "identifier", "text": "p", "parent": 840, "children": [], "start_point": {"row": 180, "column": 25}, "end_point": {"row": 180, "column": 26}}, {"id": 843, "type": "parameter_declaration", "text": "int nCount", "parent": 837, "children": [844, 845], "start_point": {"row": 180, "column": 28}, "end_point": {"row": 180, "column": 38}}, {"id": 844, "type": "primitive_type", "text": "int", "parent": 843, "children": [], "start_point": {"row": 180, "column": 28}, "end_point": {"row": 180, "column": 31}}, {"id": 845, "type": "identifier", "text": "nCount", "parent": 843, "children": [], "start_point": {"row": 180, "column": 32}, "end_point": {"row": 180, "column": 38}}, {"id": 846, "type": "function_definition", "text": "class COggOpusOutputPin : public COggSplitterOutputPin\n{\n\tint m_SampleRate;\n\tWORD m_Preskip;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggOpusOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}", "parent": null, "children": [847, 849], "start_point": {"row": 183, "column": 0}, "end_point": {"row": 193, "column": 1}}, {"id": 847, "type": "ERROR", "text": "COggOpusOutputPin : public", "parent": 846, "children": [848], "start_point": {"row": 183, "column": 6}, "end_point": {"row": 183, "column": 32}}, {"id": 848, "type": "identifier", "text": "COggOpusOutputPin", "parent": 847, "children": [], "start_point": {"row": 183, "column": 6}, "end_point": {"row": 183, "column": 23}}, {"id": 849, "type": "identifier", "text": "COggSplitterOutputPin", "parent": 846, "children": [], "start_point": {"row": 183, "column": 33}, "end_point": {"row": 183, "column": 54}}, {"id": 850, "type": "declaration", "text": "int m_SampleRate;", "parent": 846, "children": [851, 852], "start_point": {"row": 185, "column": 1}, "end_point": {"row": 185, "column": 19}}, {"id": 851, "type": "primitive_type", "text": "int", "parent": 850, "children": [], "start_point": {"row": 185, "column": 1}, "end_point": {"row": 185, "column": 4}}, {"id": 852, "type": "identifier", "text": "m_SampleRate", "parent": 850, "children": [], "start_point": {"row": 185, "column": 6}, "end_point": {"row": 185, "column": 18}}, {"id": 853, "type": "declaration", "text": "WORD m_Preskip;", "parent": 846, "children": [854, 855], "start_point": {"row": 186, "column": 1}, "end_point": {"row": 186, "column": 16}}, {"id": 854, "type": "type_identifier", "text": "WORD", "parent": 853, "children": [], "start_point": {"row": 186, "column": 1}, "end_point": {"row": 186, "column": 5}}, {"id": 855, "type": "identifier", "text": "m_Preskip", "parent": 853, "children": [], "start_point": {"row": 186, "column": 6}, "end_point": {"row": 186, "column": 15}}, {"id": 856, "type": "declaration", "text": "virtual HRESULT", "parent": 846, "children": [857, 858], "start_point": {"row": 188, "column": 1}, "end_point": {"row": 188, "column": 16}}, {"id": 857, "type": "type_identifier", "text": "virtual", "parent": 856, "children": [], "start_point": {"row": 188, "column": 1}, "end_point": {"row": 188, "column": 8}}, {"id": 858, "type": "identifier", "text": "HRESULT", "parent": 856, "children": [], "start_point": {"row": 188, "column": 9}, "end_point": {"row": 188, "column": 16}}, {"id": 859, "type": "call_expression", "text": "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 846, "children": [860, 861], "start_point": {"row": 188, "column": 17}, "end_point": {"row": 188, "column": 73}}, {"id": 860, "type": "identifier", "text": "UnpackPacket", "parent": 859, "children": [], "start_point": {"row": 188, "column": 17}, "end_point": {"row": 188, "column": 29}}, {"id": 861, "type": "argument_list", "text": "(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 859, "children": [862, 870, 874, 875], "start_point": {"row": 188, "column": 29}, "end_point": {"row": 188, "column": 73}}, {"id": 862, "type": "binary_expression", "text": "CAutoPtr<CPacket>& p", "parent": 861, "children": [863, 867, 868], "start_point": {"row": 188, "column": 30}, "end_point": {"row": 188, "column": 50}}, {"id": 863, "type": "binary_expression", "text": "CAutoPtr<CPacket", "parent": 862, "children": [864, 865, 866], "start_point": {"row": 188, "column": 30}, "end_point": {"row": 188, "column": 46}}, {"id": 864, "type": "identifier", "text": "CAutoPtr", "parent": 863, "children": [], "start_point": {"row": 188, "column": 30}, "end_point": {"row": 188, "column": 38}}, {"id": 865, "type": "<", "text": "<", "parent": 863, "children": [], "start_point": {"row": 188, "column": 38}, "end_point": {"row": 188, "column": 39}}, {"id": 866, "type": "identifier", "text": "CPacket", "parent": 863, "children": [], "start_point": {"row": 188, "column": 39}, "end_point": {"row": 188, "column": 46}}, {"id": 867, "type": ">", "text": ">", "parent": 862, "children": [], "start_point": {"row": 188, "column": 46}, "end_point": {"row": 188, "column": 47}}, {"id": 868, "type": "pointer_expression", "text": "& p", "parent": 862, "children": [869], "start_point": {"row": 188, "column": 47}, "end_point": {"row": 188, "column": 50}}, {"id": 869, "type": "identifier", "text": "p", "parent": 868, "children": [], "start_point": {"row": 188, "column": 49}, "end_point": {"row": 188, "column": 50}}, {"id": 870, "type": "binary_expression", "text": "BYTE* pData", "parent": 861, "children": [871, 872, 873], "start_point": {"row": 188, "column": 52}, "end_point": {"row": 188, "column": 63}}, {"id": 871, "type": "identifier", "text": "BYTE", "parent": 870, "children": [], "start_point": {"row": 188, "column": 52}, "end_point": {"row": 188, "column": 56}}, {"id": 872, "type": "*", "text": "*", "parent": 870, "children": [], "start_point": {"row": 188, "column": 56}, "end_point": {"row": 188, "column": 57}}, {"id": 873, "type": "identifier", "text": "pData", "parent": 870, "children": [], "start_point": {"row": 188, "column": 58}, "end_point": {"row": 188, "column": 63}}, {"id": 874, "type": "identifier", "text": "int", "parent": 861, "children": [], "start_point": {"row": 188, "column": 65}, "end_point": {"row": 188, "column": 68}}, {"id": 875, "type": "ERROR", "text": "len", "parent": 861, "children": [876], "start_point": {"row": 188, "column": 69}, "end_point": {"row": 188, "column": 72}}, {"id": 876, "type": "identifier", "text": "len", "parent": 875, "children": [], "start_point": {"row": 188, "column": 69}, "end_point": {"row": 188, "column": 72}}, {"id": 877, "type": "declaration", "text": "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);", "parent": 846, "children": [878, 879, 881], "start_point": {"row": 189, "column": 1}, "end_point": {"row": 189, "column": 61}}, {"id": 878, "type": "type_identifier", "text": "virtual", "parent": 877, "children": [], "start_point": {"row": 189, "column": 1}, "end_point": {"row": 189, "column": 8}}, {"id": 879, "type": "ERROR", "text": "REFERENCE_TIME", "parent": 877, "children": [880], "start_point": {"row": 189, "column": 9}, "end_point": {"row": 189, "column": 23}}, {"id": 880, "type": "identifier", "text": "REFERENCE_TIME", "parent": 879, "children": [], "start_point": {"row": 189, "column": 9}, "end_point": {"row": 189, "column": 23}}, {"id": 881, "type": "function_declarator", "text": "GetRefTime(__int64 granule_position)", "parent": 877, "children": [882, 883], "start_point": {"row": 189, "column": 24}, "end_point": {"row": 189, "column": 60}}, {"id": 882, "type": "identifier", "text": "GetRefTime", "parent": 881, "children": [], "start_point": {"row": 189, "column": 24}, "end_point": {"row": 189, "column": 34}}, {"id": 883, "type": "parameter_list", "text": "(__int64 granule_position)", "parent": 881, "children": [884], "start_point": {"row": 189, "column": 34}, "end_point": {"row": 189, "column": 60}}, {"id": 884, "type": "parameter_declaration", "text": "__int64 granule_position", "parent": 883, "children": [885, 886], "start_point": {"row": 189, "column": 35}, "end_point": {"row": 189, "column": 59}}, {"id": 885, "type": "type_identifier", "text": "__int64", "parent": 884, "children": [], "start_point": {"row": 189, "column": 35}, "end_point": {"row": 189, "column": 42}}, {"id": 886, "type": "identifier", "text": "granule_position", "parent": 884, "children": [], "start_point": {"row": 189, "column": 43}, "end_point": {"row": 189, "column": 59}}, {"id": 887, "type": "labeled_statement", "text": "public:\n\tCOggOpusOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 846, "children": [], "start_point": {"row": 191, "column": 0}, "end_point": {"row": 192, "column": 108}}, {"id": 888, "type": "call_expression", "text": "COggOpusOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 887, "children": [889, 890], "start_point": {"row": 192, "column": 1}, "end_point": {"row": 192, "column": 107}}, {"id": 889, "type": "identifier", "text": "COggOpusOutputPin", "parent": 888, "children": [], "start_point": {"row": 192, "column": 1}, "end_point": {"row": 192, "column": 18}}, {"id": 890, "type": "argument_list", "text": "(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 888, "children": [891, 895, 897, 898, 899, 901, 905, 909], "start_point": {"row": 192, "column": 18}, "end_point": {"row": 192, "column": 107}}, {"id": 891, "type": "binary_expression", "text": "BYTE* h", "parent": 890, "children": [892, 893, 894], "start_point": {"row": 192, "column": 19}, "end_point": {"row": 192, "column": 26}}, {"id": 892, "type": "identifier", "text": "BYTE", "parent": 891, "children": [], "start_point": {"row": 192, "column": 19}, "end_point": {"row": 192, "column": 23}}, {"id": 893, "type": "*", "text": "*", "parent": 891, "children": [], "start_point": {"row": 192, "column": 23}, "end_point": {"row": 192, "column": 24}}, {"id": 894, "type": "identifier", "text": "h", "parent": 891, "children": [], "start_point": {"row": 192, "column": 25}, "end_point": {"row": 192, "column": 26}}, {"id": 895, "type": "ERROR", "text": "int", "parent": 890, "children": [896], "start_point": {"row": 192, "column": 28}, "end_point": {"row": 192, "column": 31}}, {"id": 896, "type": "identifier", "text": "int", "parent": 895, "children": [], "start_point": {"row": 192, "column": 28}, "end_point": {"row": 192, "column": 31}}, {"id": 897, "type": "identifier", "text": "nCount", "parent": 890, "children": [], "start_point": {"row": 192, "column": 32}, "end_point": {"row": 192, "column": 38}}, {"id": 898, "type": "identifier", "text": "LPCWSTR", "parent": 890, "children": [], "start_point": {"row": 192, "column": 40}, "end_point": {"row": 192, "column": 47}}, {"id": 899, "type": "ERROR", "text": "pName", "parent": 890, "children": [900], "start_point": {"row": 192, "column": 48}, "end_point": {"row": 192, "column": 53}}, {"id": 900, "type": "identifier", "text": "pName", "parent": 899, "children": [], "start_point": {"row": 192, "column": 48}, "end_point": {"row": 192, "column": 53}}, {"id": 901, "type": "binary_expression", "text": "CBaseFilter* pFilter", "parent": 890, "children": [902, 903, 904], "start_point": {"row": 192, "column": 55}, "end_point": {"row": 192, "column": 75}}, {"id": 902, "type": "identifier", "text": "CBaseFilter", "parent": 901, "children": [], "start_point": {"row": 192, "column": 55}, "end_point": {"row": 192, "column": 66}}, {"id": 903, "type": "*", "text": "*", "parent": 901, "children": [], "start_point": {"row": 192, "column": 66}, "end_point": {"row": 192, "column": 67}}, {"id": 904, "type": "identifier", "text": "pFilter", "parent": 901, "children": [], "start_point": {"row": 192, "column": 68}, "end_point": {"row": 192, "column": 75}}, {"id": 905, "type": "binary_expression", "text": "CCritSec* pLock", "parent": 890, "children": [906, 907, 908], "start_point": {"row": 192, "column": 77}, "end_point": {"row": 192, "column": 92}}, {"id": 906, "type": "identifier", "text": "CCritSec", "parent": 905, "children": [], "start_point": {"row": 192, "column": 77}, "end_point": {"row": 192, "column": 85}}, {"id": 907, "type": "*", "text": "*", "parent": 905, "children": [], "start_point": {"row": 192, "column": 85}, "end_point": {"row": 192, "column": 86}}, {"id": 908, "type": "identifier", "text": "pLock", "parent": 905, "children": [], "start_point": {"row": 192, "column": 87}, "end_point": {"row": 192, "column": 92}}, {"id": 909, "type": "binary_expression", "text": "HRESULT* phr", "parent": 890, "children": [910, 911, 912], "start_point": {"row": 192, "column": 94}, "end_point": {"row": 192, "column": 106}}, {"id": 910, "type": "identifier", "text": "HRESULT", "parent": 909, "children": [], "start_point": {"row": 192, "column": 94}, "end_point": {"row": 192, "column": 101}}, {"id": 911, "type": "*", "text": "*", "parent": 909, "children": [], "start_point": {"row": 192, "column": 101}, "end_point": {"row": 192, "column": 102}}, {"id": 912, "type": "identifier", "text": "phr", "parent": 909, "children": [], "start_point": {"row": 192, "column": 103}, "end_point": {"row": 192, "column": 106}}, {"id": 913, "type": "function_definition", "text": "class COggSpeexOutputPin : public COggSplitterOutputPin\n{\n\tint m_SampleRate;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggSpeexOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}", "parent": null, "children": [914, 916], "start_point": {"row": 195, "column": 0}, "end_point": {"row": 204, "column": 1}}, {"id": 914, "type": "ERROR", "text": "COggSpeexOutputPin : public", "parent": 913, "children": [915], "start_point": {"row": 195, "column": 6}, "end_point": {"row": 195, "column": 33}}, {"id": 915, "type": "identifier", "text": "COggSpeexOutputPin", "parent": 914, "children": [], "start_point": {"row": 195, "column": 6}, "end_point": {"row": 195, "column": 24}}, {"id": 916, "type": "identifier", "text": "COggSplitterOutputPin", "parent": 913, "children": [], "start_point": {"row": 195, "column": 34}, "end_point": {"row": 195, "column": 55}}, {"id": 917, "type": "declaration", "text": "int m_SampleRate;", "parent": 913, "children": [918, 919], "start_point": {"row": 197, "column": 1}, "end_point": {"row": 197, "column": 18}}, {"id": 918, "type": "primitive_type", "text": "int", "parent": 917, "children": [], "start_point": {"row": 197, "column": 1}, "end_point": {"row": 197, "column": 4}}, {"id": 919, "type": "identifier", "text": "m_SampleRate", "parent": 917, "children": [], "start_point": {"row": 197, "column": 5}, "end_point": {"row": 197, "column": 17}}, {"id": 920, "type": "declaration", "text": "virtual HRESULT", "parent": 913, "children": [921, 922], "start_point": {"row": 199, "column": 1}, "end_point": {"row": 199, "column": 16}}, {"id": 921, "type": "type_identifier", "text": "virtual", "parent": 920, "children": [], "start_point": {"row": 199, "column": 1}, "end_point": {"row": 199, "column": 8}}, {"id": 922, "type": "identifier", "text": "HRESULT", "parent": 920, "children": [], "start_point": {"row": 199, "column": 9}, "end_point": {"row": 199, "column": 16}}, {"id": 923, "type": "call_expression", "text": "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 913, "children": [924, 925], "start_point": {"row": 199, "column": 17}, "end_point": {"row": 199, "column": 73}}, {"id": 924, "type": "identifier", "text": "UnpackPacket", "parent": 923, "children": [], "start_point": {"row": 199, "column": 17}, "end_point": {"row": 199, "column": 29}}, {"id": 925, "type": "argument_list", "text": "(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 923, "children": [926, 934, 938, 939], "start_point": {"row": 199, "column": 29}, "end_point": {"row": 199, "column": 73}}, {"id": 926, "type": "binary_expression", "text": "CAutoPtr<CPacket>& p", "parent": 925, "children": [927, 931, 932], "start_point": {"row": 199, "column": 30}, "end_point": {"row": 199, "column": 50}}, {"id": 927, "type": "binary_expression", "text": "CAutoPtr<CPacket", "parent": 926, "children": [928, 929, 930], "start_point": {"row": 199, "column": 30}, "end_point": {"row": 199, "column": 46}}, {"id": 928, "type": "identifier", "text": "CAutoPtr", "parent": 927, "children": [], "start_point": {"row": 199, "column": 30}, "end_point": {"row": 199, "column": 38}}, {"id": 929, "type": "<", "text": "<", "parent": 927, "children": [], "start_point": {"row": 199, "column": 38}, "end_point": {"row": 199, "column": 39}}, {"id": 930, "type": "identifier", "text": "CPacket", "parent": 927, "children": [], "start_point": {"row": 199, "column": 39}, "end_point": {"row": 199, "column": 46}}, {"id": 931, "type": ">", "text": ">", "parent": 926, "children": [], "start_point": {"row": 199, "column": 46}, "end_point": {"row": 199, "column": 47}}, {"id": 932, "type": "pointer_expression", "text": "& p", "parent": 926, "children": [933], "start_point": {"row": 199, "column": 47}, "end_point": {"row": 199, "column": 50}}, {"id": 933, "type": "identifier", "text": "p", "parent": 932, "children": [], "start_point": {"row": 199, "column": 49}, "end_point": {"row": 199, "column": 50}}, {"id": 934, "type": "binary_expression", "text": "BYTE* pData", "parent": 925, "children": [935, 936, 937], "start_point": {"row": 199, "column": 52}, "end_point": {"row": 199, "column": 63}}, {"id": 935, "type": "identifier", "text": "BYTE", "parent": 934, "children": [], "start_point": {"row": 199, "column": 52}, "end_point": {"row": 199, "column": 56}}, {"id": 936, "type": "*", "text": "*", "parent": 934, "children": [], "start_point": {"row": 199, "column": 56}, "end_point": {"row": 199, "column": 57}}, {"id": 937, "type": "identifier", "text": "pData", "parent": 934, "children": [], "start_point": {"row": 199, "column": 58}, "end_point": {"row": 199, "column": 63}}, {"id": 938, "type": "identifier", "text": "int", "parent": 925, "children": [], "start_point": {"row": 199, "column": 65}, "end_point": {"row": 199, "column": 68}}, {"id": 939, "type": "ERROR", "text": "len", "parent": 925, "children": [940], "start_point": {"row": 199, "column": 69}, "end_point": {"row": 199, "column": 72}}, {"id": 940, "type": "identifier", "text": "len", "parent": 939, "children": [], "start_point": {"row": 199, "column": 69}, "end_point": {"row": 199, "column": 72}}, {"id": 941, "type": "declaration", "text": "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);", "parent": 913, "children": [942, 943, 945], "start_point": {"row": 200, "column": 1}, "end_point": {"row": 200, "column": 61}}, {"id": 942, "type": "type_identifier", "text": "virtual", "parent": 941, "children": [], "start_point": {"row": 200, "column": 1}, "end_point": {"row": 200, "column": 8}}, {"id": 943, "type": "ERROR", "text": "REFERENCE_TIME", "parent": 941, "children": [944], "start_point": {"row": 200, "column": 9}, "end_point": {"row": 200, "column": 23}}, {"id": 944, "type": "identifier", "text": "REFERENCE_TIME", "parent": 943, "children": [], "start_point": {"row": 200, "column": 9}, "end_point": {"row": 200, "column": 23}}, {"id": 945, "type": "function_declarator", "text": "GetRefTime(__int64 granule_position)", "parent": 941, "children": [946, 947], "start_point": {"row": 200, "column": 24}, "end_point": {"row": 200, "column": 60}}, {"id": 946, "type": "identifier", "text": "GetRefTime", "parent": 945, "children": [], "start_point": {"row": 200, "column": 24}, "end_point": {"row": 200, "column": 34}}, {"id": 947, "type": "parameter_list", "text": "(__int64 granule_position)", "parent": 945, "children": [948], "start_point": {"row": 200, "column": 34}, "end_point": {"row": 200, "column": 60}}, {"id": 948, "type": "parameter_declaration", "text": "__int64 granule_position", "parent": 947, "children": [949, 950], "start_point": {"row": 200, "column": 35}, "end_point": {"row": 200, "column": 59}}, {"id": 949, "type": "type_identifier", "text": "__int64", "parent": 948, "children": [], "start_point": {"row": 200, "column": 35}, "end_point": {"row": 200, "column": 42}}, {"id": 950, "type": "identifier", "text": "granule_position", "parent": 948, "children": [], "start_point": {"row": 200, "column": 43}, "end_point": {"row": 200, "column": 59}}, {"id": 951, "type": "labeled_statement", "text": "public:\n\tCOggSpeexOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 913, "children": [], "start_point": {"row": 202, "column": 0}, "end_point": {"row": 203, "column": 109}}, {"id": 952, "type": "call_expression", "text": "COggSpeexOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 951, "children": [953, 954], "start_point": {"row": 203, "column": 1}, "end_point": {"row": 203, "column": 108}}, {"id": 953, "type": "identifier", "text": "COggSpeexOutputPin", "parent": 952, "children": [], "start_point": {"row": 203, "column": 1}, "end_point": {"row": 203, "column": 19}}, {"id": 954, "type": "argument_list", "text": "(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 952, "children": [955, 959, 961, 962, 963, 965, 969, 973], "start_point": {"row": 203, "column": 19}, "end_point": {"row": 203, "column": 108}}, {"id": 955, "type": "binary_expression", "text": "BYTE* h", "parent": 954, "children": [956, 957, 958], "start_point": {"row": 203, "column": 20}, "end_point": {"row": 203, "column": 27}}, {"id": 956, "type": "identifier", "text": "BYTE", "parent": 955, "children": [], "start_point": {"row": 203, "column": 20}, "end_point": {"row": 203, "column": 24}}, {"id": 957, "type": "*", "text": "*", "parent": 955, "children": [], "start_point": {"row": 203, "column": 24}, "end_point": {"row": 203, "column": 25}}, {"id": 958, "type": "identifier", "text": "h", "parent": 955, "children": [], "start_point": {"row": 203, "column": 26}, "end_point": {"row": 203, "column": 27}}, {"id": 959, "type": "ERROR", "text": "int", "parent": 954, "children": [960], "start_point": {"row": 203, "column": 29}, "end_point": {"row": 203, "column": 32}}, {"id": 960, "type": "identifier", "text": "int", "parent": 959, "children": [], "start_point": {"row": 203, "column": 29}, "end_point": {"row": 203, "column": 32}}, {"id": 961, "type": "identifier", "text": "nCount", "parent": 954, "children": [], "start_point": {"row": 203, "column": 33}, "end_point": {"row": 203, "column": 39}}, {"id": 962, "type": "identifier", "text": "LPCWSTR", "parent": 954, "children": [], "start_point": {"row": 203, "column": 41}, "end_point": {"row": 203, "column": 48}}, {"id": 963, "type": "ERROR", "text": "pName", "parent": 954, "children": [964], "start_point": {"row": 203, "column": 49}, "end_point": {"row": 203, "column": 54}}, {"id": 964, "type": "identifier", "text": "pName", "parent": 963, "children": [], "start_point": {"row": 203, "column": 49}, "end_point": {"row": 203, "column": 54}}, {"id": 965, "type": "binary_expression", "text": "CBaseFilter* pFilter", "parent": 954, "children": [966, 967, 968], "start_point": {"row": 203, "column": 56}, "end_point": {"row": 203, "column": 76}}, {"id": 966, "type": "identifier", "text": "CBaseFilter", "parent": 965, "children": [], "start_point": {"row": 203, "column": 56}, "end_point": {"row": 203, "column": 67}}, {"id": 967, "type": "*", "text": "*", "parent": 965, "children": [], "start_point": {"row": 203, "column": 67}, "end_point": {"row": 203, "column": 68}}, {"id": 968, "type": "identifier", "text": "pFilter", "parent": 965, "children": [], "start_point": {"row": 203, "column": 69}, "end_point": {"row": 203, "column": 76}}, {"id": 969, "type": "binary_expression", "text": "CCritSec* pLock", "parent": 954, "children": [970, 971, 972], "start_point": {"row": 203, "column": 78}, "end_point": {"row": 203, "column": 93}}, {"id": 970, "type": "identifier", "text": "CCritSec", "parent": 969, "children": [], "start_point": {"row": 203, "column": 78}, "end_point": {"row": 203, "column": 86}}, {"id": 971, "type": "*", "text": "*", "parent": 969, "children": [], "start_point": {"row": 203, "column": 86}, "end_point": {"row": 203, "column": 87}}, {"id": 972, "type": "identifier", "text": "pLock", "parent": 969, "children": [], "start_point": {"row": 203, "column": 88}, "end_point": {"row": 203, "column": 93}}, {"id": 973, "type": "binary_expression", "text": "HRESULT* phr", "parent": 954, "children": [974, 975, 976], "start_point": {"row": 203, "column": 95}, "end_point": {"row": 203, "column": 107}}, {"id": 974, "type": "identifier", "text": "HRESULT", "parent": 973, "children": [], "start_point": {"row": 203, "column": 95}, "end_point": {"row": 203, "column": 102}}, {"id": 975, "type": "*", "text": "*", "parent": 973, "children": [], "start_point": {"row": 203, "column": 102}, "end_point": {"row": 203, "column": 103}}, {"id": 976, "type": "identifier", "text": "phr", "parent": 973, "children": [], "start_point": {"row": 203, "column": 104}, "end_point": {"row": 203, "column": 107}}, {"id": 977, "type": "function_definition", "text": "class COggVP8OutputPin : public COggSplitterOutputPin\n{\n\tREFERENCE_TIME m_rtAvgTimePerFrame;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggVP8OutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n}", "parent": null, "children": [978, 980], "start_point": {"row": 206, "column": 0}, "end_point": {"row": 215, "column": 1}}, {"id": 978, "type": "ERROR", "text": "COggVP8OutputPin : public", "parent": 977, "children": [979], "start_point": {"row": 206, "column": 6}, "end_point": {"row": 206, "column": 31}}, {"id": 979, "type": "identifier", "text": "COggVP8OutputPin", "parent": 978, "children": [], "start_point": {"row": 206, "column": 6}, "end_point": {"row": 206, "column": 22}}, {"id": 980, "type": "identifier", "text": "COggSplitterOutputPin", "parent": 977, "children": [], "start_point": {"row": 206, "column": 32}, "end_point": {"row": 206, "column": 53}}, {"id": 981, "type": "declaration", "text": "REFERENCE_TIME m_rtAvgTimePerFrame;", "parent": 977, "children": [982, 983], "start_point": {"row": 208, "column": 1}, "end_point": {"row": 208, "column": 36}}, {"id": 982, "type": "type_identifier", "text": "REFERENCE_TIME", "parent": 981, "children": [], "start_point": {"row": 208, "column": 1}, "end_point": {"row": 208, "column": 15}}, {"id": 983, "type": "identifier", "text": "m_rtAvgTimePerFrame", "parent": 981, "children": [], "start_point": {"row": 208, "column": 16}, "end_point": {"row": 208, "column": 35}}, {"id": 984, "type": "declaration", "text": "virtual HRESULT", "parent": 977, "children": [985, 986], "start_point": {"row": 210, "column": 1}, "end_point": {"row": 210, "column": 16}}, {"id": 985, "type": "type_identifier", "text": "virtual", "parent": 984, "children": [], "start_point": {"row": 210, "column": 1}, "end_point": {"row": 210, "column": 8}}, {"id": 986, "type": "identifier", "text": "HRESULT", "parent": 984, "children": [], "start_point": {"row": 210, "column": 9}, "end_point": {"row": 210, "column": 16}}, {"id": 987, "type": "call_expression", "text": "UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 977, "children": [988, 989], "start_point": {"row": 210, "column": 17}, "end_point": {"row": 210, "column": 73}}, {"id": 988, "type": "identifier", "text": "UnpackPacket", "parent": 987, "children": [], "start_point": {"row": 210, "column": 17}, "end_point": {"row": 210, "column": 29}}, {"id": 989, "type": "argument_list", "text": "(CAutoPtr<CPacket>& p, BYTE* pData, int len)", "parent": 987, "children": [990, 998, 1002, 1003], "start_point": {"row": 210, "column": 29}, "end_point": {"row": 210, "column": 73}}, {"id": 990, "type": "binary_expression", "text": "CAutoPtr<CPacket>& p", "parent": 989, "children": [991, 995, 996], "start_point": {"row": 210, "column": 30}, "end_point": {"row": 210, "column": 50}}, {"id": 991, "type": "binary_expression", "text": "CAutoPtr<CPacket", "parent": 990, "children": [992, 993, 994], "start_point": {"row": 210, "column": 30}, "end_point": {"row": 210, "column": 46}}, {"id": 992, "type": "identifier", "text": "CAutoPtr", "parent": 991, "children": [], "start_point": {"row": 210, "column": 30}, "end_point": {"row": 210, "column": 38}}, {"id": 993, "type": "<", "text": "<", "parent": 991, "children": [], "start_point": {"row": 210, "column": 38}, "end_point": {"row": 210, "column": 39}}, {"id": 994, "type": "identifier", "text": "CPacket", "parent": 991, "children": [], "start_point": {"row": 210, "column": 39}, "end_point": {"row": 210, "column": 46}}, {"id": 995, "type": ">", "text": ">", "parent": 990, "children": [], "start_point": {"row": 210, "column": 46}, "end_point": {"row": 210, "column": 47}}, {"id": 996, "type": "pointer_expression", "text": "& p", "parent": 990, "children": [997], "start_point": {"row": 210, "column": 47}, "end_point": {"row": 210, "column": 50}}, {"id": 997, "type": "identifier", "text": "p", "parent": 996, "children": [], "start_point": {"row": 210, "column": 49}, "end_point": {"row": 210, "column": 50}}, {"id": 998, "type": "binary_expression", "text": "BYTE* pData", "parent": 989, "children": [999, 1000, 1001], "start_point": {"row": 210, "column": 52}, "end_point": {"row": 210, "column": 63}}, {"id": 999, "type": "identifier", "text": "BYTE", "parent": 998, "children": [], "start_point": {"row": 210, "column": 52}, "end_point": {"row": 210, "column": 56}}, {"id": 1000, "type": "*", "text": "*", "parent": 998, "children": [], "start_point": {"row": 210, "column": 56}, "end_point": {"row": 210, "column": 57}}, {"id": 1001, "type": "identifier", "text": "pData", "parent": 998, "children": [], "start_point": {"row": 210, "column": 58}, "end_point": {"row": 210, "column": 63}}, {"id": 1002, "type": "identifier", "text": "int", "parent": 989, "children": [], "start_point": {"row": 210, "column": 65}, "end_point": {"row": 210, "column": 68}}, {"id": 1003, "type": "ERROR", "text": "len", "parent": 989, "children": [1004], "start_point": {"row": 210, "column": 69}, "end_point": {"row": 210, "column": 72}}, {"id": 1004, "type": "identifier", "text": "len", "parent": 1003, "children": [], "start_point": {"row": 210, "column": 69}, "end_point": {"row": 210, "column": 72}}, {"id": 1005, "type": "declaration", "text": "virtual REFERENCE_TIME GetRefTime(__int64 granule_position);", "parent": 977, "children": [1006, 1007, 1009], "start_point": {"row": 211, "column": 1}, "end_point": {"row": 211, "column": 61}}, {"id": 1006, "type": "type_identifier", "text": "virtual", "parent": 1005, "children": [], "start_point": {"row": 211, "column": 1}, "end_point": {"row": 211, "column": 8}}, {"id": 1007, "type": "ERROR", "text": "REFERENCE_TIME", "parent": 1005, "children": [1008], "start_point": {"row": 211, "column": 9}, "end_point": {"row": 211, "column": 23}}, {"id": 1008, "type": "identifier", "text": "REFERENCE_TIME", "parent": 1007, "children": [], "start_point": {"row": 211, "column": 9}, "end_point": {"row": 211, "column": 23}}, {"id": 1009, "type": "function_declarator", "text": "GetRefTime(__int64 granule_position)", "parent": 1005, "children": [1010, 1011], "start_point": {"row": 211, "column": 24}, "end_point": {"row": 211, "column": 60}}, {"id": 1010, "type": "identifier", "text": "GetRefTime", "parent": 1009, "children": [], "start_point": {"row": 211, "column": 24}, "end_point": {"row": 211, "column": 34}}, {"id": 1011, "type": "parameter_list", "text": "(__int64 granule_position)", "parent": 1009, "children": [1012], "start_point": {"row": 211, "column": 34}, "end_point": {"row": 211, "column": 60}}, {"id": 1012, "type": "parameter_declaration", "text": "__int64 granule_position", "parent": 1011, "children": [1013, 1014], "start_point": {"row": 211, "column": 35}, "end_point": {"row": 211, "column": 59}}, {"id": 1013, "type": "type_identifier", "text": "__int64", "parent": 1012, "children": [], "start_point": {"row": 211, "column": 35}, "end_point": {"row": 211, "column": 42}}, {"id": 1014, "type": "identifier", "text": "granule_position", "parent": 1012, "children": [], "start_point": {"row": 211, "column": 43}, "end_point": {"row": 211, "column": 59}}, {"id": 1015, "type": "labeled_statement", "text": "public:\n\tCOggVP8OutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);", "parent": 977, "children": [], "start_point": {"row": 213, "column": 0}, "end_point": {"row": 214, "column": 107}}, {"id": 1016, "type": "call_expression", "text": "COggVP8OutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 1015, "children": [1017, 1018], "start_point": {"row": 214, "column": 1}, "end_point": {"row": 214, "column": 106}}, {"id": 1017, "type": "identifier", "text": "COggVP8OutputPin", "parent": 1016, "children": [], "start_point": {"row": 214, "column": 1}, "end_point": {"row": 214, "column": 17}}, {"id": 1018, "type": "argument_list", "text": "(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr)", "parent": 1016, "children": [1019, 1023, 1025, 1026, 1027, 1029, 1033, 1037], "start_point": {"row": 214, "column": 17}, "end_point": {"row": 214, "column": 106}}, {"id": 1019, "type": "binary_expression", "text": "BYTE* h", "parent": 1018, "children": [1020, 1021, 1022], "start_point": {"row": 214, "column": 18}, "end_point": {"row": 214, "column": 25}}, {"id": 1020, "type": "identifier", "text": "BYTE", "parent": 1019, "children": [], "start_point": {"row": 214, "column": 18}, "end_point": {"row": 214, "column": 22}}, {"id": 1021, "type": "*", "text": "*", "parent": 1019, "children": [], "start_point": {"row": 214, "column": 22}, "end_point": {"row": 214, "column": 23}}, {"id": 1022, "type": "identifier", "text": "h", "parent": 1019, "children": [], "start_point": {"row": 214, "column": 24}, "end_point": {"row": 214, "column": 25}}, {"id": 1023, "type": "ERROR", "text": "int", "parent": 1018, "children": [1024], "start_point": {"row": 214, "column": 27}, "end_point": {"row": 214, "column": 30}}, {"id": 1024, "type": "identifier", "text": "int", "parent": 1023, "children": [], "start_point": {"row": 214, "column": 27}, "end_point": {"row": 214, "column": 30}}, {"id": 1025, "type": "identifier", "text": "nCount", "parent": 1018, "children": [], "start_point": {"row": 214, "column": 31}, "end_point": {"row": 214, "column": 37}}, {"id": 1026, "type": "identifier", "text": "LPCWSTR", "parent": 1018, "children": [], "start_point": {"row": 214, "column": 39}, "end_point": {"row": 214, "column": 46}}, {"id": 1027, "type": "ERROR", "text": "pName", "parent": 1018, "children": [1028], "start_point": {"row": 214, "column": 47}, "end_point": {"row": 214, "column": 52}}, {"id": 1028, "type": "identifier", "text": "pName", "parent": 1027, "children": [], "start_point": {"row": 214, "column": 47}, "end_point": {"row": 214, "column": 52}}, {"id": 1029, "type": "binary_expression", "text": "CBaseFilter* pFilter", "parent": 1018, "children": [1030, 1031, 1032], "start_point": {"row": 214, "column": 54}, "end_point": {"row": 214, "column": 74}}, {"id": 1030, "type": "identifier", "text": "CBaseFilter", "parent": 1029, "children": [], "start_point": {"row": 214, "column": 54}, "end_point": {"row": 214, "column": 65}}, {"id": 1031, "type": "*", "text": "*", "parent": 1029, "children": [], "start_point": {"row": 214, "column": 65}, "end_point": {"row": 214, "column": 66}}, {"id": 1032, "type": "identifier", "text": "pFilter", "parent": 1029, "children": [], "start_point": {"row": 214, "column": 67}, "end_point": {"row": 214, "column": 74}}, {"id": 1033, "type": "binary_expression", "text": "CCritSec* pLock", "parent": 1018, "children": [1034, 1035, 1036], "start_point": {"row": 214, "column": 76}, "end_point": {"row": 214, "column": 91}}, {"id": 1034, "type": "identifier", "text": "CCritSec", "parent": 1033, "children": [], "start_point": {"row": 214, "column": 76}, "end_point": {"row": 214, "column": 84}}, {"id": 1035, "type": "*", "text": "*", "parent": 1033, "children": [], "start_point": {"row": 214, "column": 84}, "end_point": {"row": 214, "column": 85}}, {"id": 1036, "type": "identifier", "text": "pLock", "parent": 1033, "children": [], "start_point": {"row": 214, "column": 86}, "end_point": {"row": 214, "column": 91}}, {"id": 1037, "type": "binary_expression", "text": "HRESULT* phr", "parent": 1018, "children": [1038, 1039, 1040], "start_point": {"row": 214, "column": 93}, "end_point": {"row": 214, "column": 105}}, {"id": 1038, "type": "identifier", "text": "HRESULT", "parent": 1037, "children": [], "start_point": {"row": 214, "column": 93}, "end_point": {"row": 214, "column": 100}}, {"id": 1039, "type": "*", "text": "*", "parent": 1037, "children": [], "start_point": {"row": 214, "column": 100}, "end_point": {"row": 214, "column": 101}}, {"id": 1040, "type": "identifier", "text": "phr", "parent": 1037, "children": [], "start_point": {"row": 214, "column": 102}, "end_point": {"row": 214, "column": 105}}, {"id": 1041, "type": "ERROR", "text": "class __declspec(uuid(\"9FF48807-E133-40AA-826F-9B2959E5232D\"))", "parent": null, "children": [1042, 1043, 1044], "start_point": {"row": 217, "column": 0}, "end_point": {"row": 217, "column": 62}}, {"id": 1042, "type": "__declspec", "text": "__declspec", "parent": 1041, "children": [], "start_point": {"row": 217, "column": 6}, "end_point": {"row": 217, "column": 16}}, {"id": 1043, "type": "identifier", "text": "uuid", "parent": 1041, "children": [], "start_point": {"row": 217, "column": 17}, "end_point": {"row": 217, "column": 21}}, {"id": 1044, "type": "string_literal", "text": "\"9FF48807-E133-40AA-826F-9B2959E5232D\"", "parent": 1041, "children": [], "start_point": {"row": 217, "column": 22}, "end_point": {"row": 217, "column": 60}}, {"id": 1045, "type": "labeled_statement", "text": "COggSplitterFilter : public CBaseSplitterFilter\n{\nprotected:\n\tCAutoPtr<COggFile> m_pFile;\n\tHRESULT CreateOutputs(IAsyncReader* pAsyncReader);\n\n\tbool DemuxInit();\n\tvoid DemuxSeek(REFERENCE_TIME rt);\n\tbool DemuxLoop();\n\n\tDWORD m_bitstream_serial_number_start = 0;\n\tDWORD m_bitstream_serial_number_last = 0;\n\tDWORD m_bitstream_serial_number_Video = DWORD_MAX;\n\npublic:\n\tREFERENCE_TIME m_rtOffset = 0;\n\n\tCOggSplitterFilter(LPUNKNOWN pUnk, HRESULT* phr);\n\tvirtual ~COggSplitterFilter();\n\n\t// CBaseFilter\n\n\tSTDMETHODIMP_(HRESULT) QueryFilterInfo(FILTER_INFO* pInfo);\n}", "parent": null, "children": [1046, 1047], "start_point": {"row": 218, "column": 1}, "end_point": {"row": 241, "column": 1}}, {"id": 1046, "type": "statement_identifier", "text": "COggSplitterFilter", "parent": 1045, "children": [], "start_point": {"row": 218, "column": 1}, "end_point": {"row": 218, "column": 19}}, {"id": 1047, "type": "ERROR", "text": "public CBaseSplitterFilter", "parent": 1045, "children": [1048], "start_point": {"row": 218, "column": 22}, "end_point": {"row": 218, "column": 48}}, {"id": 1048, "type": "identifier", "text": "CBaseSplitterFilter", "parent": 1047, "children": [], "start_point": {"row": 218, "column": 29}, "end_point": {"row": 218, "column": 48}}, {"id": 1049, "type": "labeled_statement", "text": "protected:\n\tCAutoPtr<COggFile> m_pFile;", "parent": 1045, "children": [], "start_point": {"row": 220, "column": 0}, "end_point": {"row": 221, "column": 28}}, {"id": 1050, "type": "binary_expression", "text": "CAutoPtr<COggFile> m_pFile", "parent": 1049, "children": [1051, 1055, 1056], "start_point": {"row": 221, "column": 1}, "end_point": {"row": 221, "column": 27}}, {"id": 1051, "type": "binary_expression", "text": "CAutoPtr<COggFile", "parent": 1050, "children": [1052, 1053, 1054], "start_point": {"row": 221, "column": 1}, "end_point": {"row": 221, "column": 18}}, {"id": 1052, "type": "identifier", "text": "CAutoPtr", "parent": 1051, "children": [], "start_point": {"row": 221, "column": 1}, "end_point": {"row": 221, "column": 9}}, {"id": 1053, "type": "<", "text": "<", "parent": 1051, "children": [], "start_point": {"row": 221, "column": 9}, "end_point": {"row": 221, "column": 10}}, {"id": 1054, "type": "identifier", "text": "COggFile", "parent": 1051, "children": [], "start_point": {"row": 221, "column": 10}, "end_point": {"row": 221, "column": 18}}, {"id": 1055, "type": ">", "text": ">", "parent": 1050, "children": [], "start_point": {"row": 221, "column": 18}, "end_point": {"row": 221, "column": 19}}, {"id": 1056, "type": "identifier", "text": "m_pFile", "parent": 1050, "children": [], "start_point": {"row": 221, "column": 20}, "end_point": {"row": 221, "column": 27}}, {"id": 1057, "type": "declaration", "text": "HRESULT CreateOutputs(IAsyncReader* pAsyncReader);", "parent": 1045, "children": [1058, 1059], "start_point": {"row": 222, "column": 1}, "end_point": {"row": 222, "column": 51}}, {"id": 1058, "type": "type_identifier", "text": "HRESULT", "parent": 1057, "children": [], "start_point": {"row": 222, "column": 1}, "end_point": {"row": 222, "column": 8}}, {"id": 1059, "type": "function_declarator", "text": "CreateOutputs(IAsyncReader* pAsyncReader)", "parent": 1057, "children": [1060, 1061], "start_point": {"row": 222, "column": 9}, "end_point": {"row": 222, "column": 50}}, {"id": 1060, "type": "identifier", "text": "CreateOutputs", "parent": 1059, "children": [], "start_point": {"row": 222, "column": 9}, "end_point": {"row": 222, "column": 22}}, {"id": 1061, "type": "parameter_list", "text": "(IAsyncReader* pAsyncReader)", "parent": 1059, "children": [1062], "start_point": {"row": 222, "column": 22}, "end_point": {"row": 222, "column": 50}}, {"id": 1062, "type": "parameter_declaration", "text": "IAsyncReader* pAsyncReader", "parent": 1061, "children": [1063, 1064], "start_point": {"row": 222, "column": 23}, "end_point": {"row": 222, "column": 49}}, {"id": 1063, "type": "type_identifier", "text": "IAsyncReader", "parent": 1062, "children": [], "start_point": {"row": 222, "column": 23}, "end_point": {"row": 222, "column": 35}}, {"id": 1064, "type": "pointer_declarator", "text": "* pAsyncReader", "parent": 1062, "children": [1065, 1066], "start_point": {"row": 222, "column": 35}, "end_point": {"row": 222, "column": 49}}, {"id": 1065, "type": "*", "text": "*", "parent": 1064, "children": [], "start_point": {"row": 222, "column": 35}, "end_point": {"row": 222, "column": 36}}, {"id": 1066, "type": "identifier", "text": "pAsyncReader", "parent": 1064, "children": [], "start_point": {"row": 222, "column": 37}, "end_point": {"row": 222, "column": 49}}, {"id": 1067, "type": "declaration", "text": "bool DemuxInit();", "parent": 1045, "children": [1068, 1069], "start_point": {"row": 224, "column": 1}, "end_point": {"row": 224, "column": 18}}, {"id": 1068, "type": "primitive_type", "text": "bool", "parent": 1067, "children": [], "start_point": {"row": 224, "column": 1}, "end_point": {"row": 224, "column": 5}}, {"id": 1069, "type": "function_declarator", "text": "DemuxInit()", "parent": 1067, "children": [1070, 1071], "start_point": {"row": 224, "column": 6}, "end_point": {"row": 224, "column": 17}}, {"id": 1070, "type": "identifier", "text": "DemuxInit", "parent": 1069, "children": [], "start_point": {"row": 224, "column": 6}, "end_point": {"row": 224, "column": 15}}, {"id": 1071, "type": "parameter_list", "text": "()", "parent": 1069, "children": [], "start_point": {"row": 224, "column": 15}, "end_point": {"row": 224, "column": 17}}, {"id": 1072, "type": "declaration", "text": "void DemuxSeek(REFERENCE_TIME rt);", "parent": 1045, "children": [1073, 1074], "start_point": {"row": 225, "column": 1}, "end_point": {"row": 225, "column": 35}}, {"id": 1073, "type": "primitive_type", "text": "void", "parent": 1072, "children": [], "start_point": {"row": 225, "column": 1}, "end_point": {"row": 225, "column": 5}}, {"id": 1074, "type": "function_declarator", "text": "DemuxSeek(REFERENCE_TIME rt)", "parent": 1072, "children": [1075, 1076], "start_point": {"row": 225, "column": 6}, "end_point": {"row": 225, "column": 34}}, {"id": 1075, "type": "identifier", "text": "DemuxSeek", "parent": 1074, "children": [], "start_point": {"row": 225, "column": 6}, "end_point": {"row": 225, "column": 15}}, {"id": 1076, "type": "parameter_list", "text": "(REFERENCE_TIME rt)", "parent": 1074, "children": [1077], "start_point": {"row": 225, "column": 15}, "end_point": {"row": 225, "column": 34}}, {"id": 1077, "type": "parameter_declaration", "text": "REFERENCE_TIME rt", "parent": 1076, "children": [1078, 1079], "start_point": {"row": 225, "column": 16}, "end_point": {"row": 225, "column": 33}}, {"id": 1078, "type": "type_identifier", "text": "REFERENCE_TIME", "parent": 1077, "children": [], "start_point": {"row": 225, "column": 16}, "end_point": {"row": 225, "column": 30}}, {"id": 1079, "type": "identifier", "text": "rt", "parent": 1077, "children": [], "start_point": {"row": 225, "column": 31}, "end_point": {"row": 225, "column": 33}}, {"id": 1080, "type": "declaration", "text": "bool DemuxLoop();", "parent": 1045, "children": [1081, 1082], "start_point": {"row": 226, "column": 1}, "end_point": {"row": 226, "column": 18}}, {"id": 1081, "type": "primitive_type", "text": "bool", "parent": 1080, "children": [], "start_point": {"row": 226, "column": 1}, "end_point": {"row": 226, "column": 5}}, {"id": 1082, "type": "function_declarator", "text": "DemuxLoop()", "parent": 1080, "children": [1083, 1084], "start_point": {"row": 226, "column": 6}, "end_point": {"row": 226, "column": 17}}, {"id": 1083, "type": "identifier", "text": "DemuxLoop", "parent": 1082, "children": [], "start_point": {"row": 226, "column": 6}, "end_point": {"row": 226, "column": 15}}, {"id": 1084, "type": "parameter_list", "text": "()", "parent": 1082, "children": [], "start_point": {"row": 226, "column": 15}, "end_point": {"row": 226, "column": 17}}, {"id": 1085, "type": "declaration", "text": "DWORD m_bitstream_serial_number_start = 0;", "parent": 1045, "children": [1086, 1087], "start_point": {"row": 228, "column": 1}, "end_point": {"row": 228, "column": 43}}, {"id": 1086, "type": "type_identifier", "text": "DWORD", "parent": 1085, "children": [], "start_point": {"row": 228, "column": 1}, "end_point": {"row": 228, "column": 6}}, {"id": 1087, "type": "init_declarator", "text": "m_bitstream_serial_number_start = 0", "parent": 1085, "children": [1088, 1089, 1090], "start_point": {"row": 228, "column": 7}, "end_point": {"row": 228, "column": 42}}, {"id": 1088, "type": "identifier", "text": "m_bitstream_serial_number_start", "parent": 1087, "children": [], "start_point": {"row": 228, "column": 7}, "end_point": {"row": 228, "column": 38}}, {"id": 1089, "type": "=", "text": "=", "parent": 1087, "children": [], "start_point": {"row": 228, "column": 39}, "end_point": {"row": 228, "column": 40}}, {"id": 1090, "type": "number_literal", "text": "0", "parent": 1087, "children": [], "start_point": {"row": 228, "column": 41}, "end_point": {"row": 228, "column": 42}}, {"id": 1091, "type": "declaration", "text": "DWORD m_bitstream_serial_number_last = 0;", "parent": 1045, "children": [1092, 1093], "start_point": {"row": 229, "column": 1}, "end_point": {"row": 229, "column": 42}}, {"id": 1092, "type": "type_identifier", "text": "DWORD", "parent": 1091, "children": [], "start_point": {"row": 229, "column": 1}, "end_point": {"row": 229, "column": 6}}, {"id": 1093, "type": "init_declarator", "text": "m_bitstream_serial_number_last = 0", "parent": 1091, "children": [1094, 1095, 1096], "start_point": {"row": 229, "column": 7}, "end_point": {"row": 229, "column": 41}}, {"id": 1094, "type": "identifier", "text": "m_bitstream_serial_number_last", "parent": 1093, "children": [], "start_point": {"row": 229, "column": 7}, "end_point": {"row": 229, "column": 37}}, {"id": 1095, "type": "=", "text": "=", "parent": 1093, "children": [], "start_point": {"row": 229, "column": 38}, "end_point": {"row": 229, "column": 39}}, {"id": 1096, "type": "number_literal", "text": "0", "parent": 1093, "children": [], "start_point": {"row": 229, "column": 40}, "end_point": {"row": 229, "column": 41}}, {"id": 1097, "type": "declaration", "text": "DWORD m_bitstream_serial_number_Video = DWORD_MAX;", "parent": 1045, "children": [1098, 1099], "start_point": {"row": 230, "column": 1}, "end_point": {"row": 230, "column": 51}}, {"id": 1098, "type": "type_identifier", "text": "DWORD", "parent": 1097, "children": [], "start_point": {"row": 230, "column": 1}, "end_point": {"row": 230, "column": 6}}, {"id": 1099, "type": "init_declarator", "text": "m_bitstream_serial_number_Video = DWORD_MAX", "parent": 1097, "children": [1100, 1101, 1102], "start_point": {"row": 230, "column": 7}, "end_point": {"row": 230, "column": 50}}, {"id": 1100, "type": "identifier", "text": "m_bitstream_serial_number_Video", "parent": 1099, "children": [], "start_point": {"row": 230, "column": 7}, "end_point": {"row": 230, "column": 38}}, {"id": 1101, "type": "=", "text": "=", "parent": 1099, "children": [], "start_point": {"row": 230, "column": 39}, "end_point": {"row": 230, "column": 40}}, {"id": 1102, "type": "identifier", "text": "DWORD_MAX", "parent": 1099, "children": [], "start_point": {"row": 230, "column": 41}, "end_point": {"row": 230, "column": 50}}, {"id": 1103, "type": "labeled_statement", "text": "public:\n\tREFERENCE_TIME m_rtOffset = 0;", "parent": 1045, "children": [1104], "start_point": {"row": 232, "column": 0}, "end_point": {"row": 233, "column": 31}}, {"id": 1104, "type": "declaration", "text": "REFERENCE_TIME m_rtOffset = 0;", "parent": 1103, "children": [1105, 1106], "start_point": {"row": 233, "column": 1}, "end_point": {"row": 233, "column": 31}}, {"id": 1105, "type": "type_identifier", "text": "REFERENCE_TIME", "parent": 1104, "children": [], "start_point": {"row": 233, "column": 1}, "end_point": {"row": 233, "column": 15}}, {"id": 1106, "type": "init_declarator", "text": "m_rtOffset = 0", "parent": 1104, "children": [1107, 1108, 1109], "start_point": {"row": 233, "column": 16}, "end_point": {"row": 233, "column": 30}}, {"id": 1107, "type": "identifier", "text": "m_rtOffset", "parent": 1106, "children": [], "start_point": {"row": 233, "column": 16}, "end_point": {"row": 233, "column": 26}}, {"id": 1108, "type": "=", "text": "=", "parent": 1106, "children": [], "start_point": {"row": 233, "column": 27}, "end_point": {"row": 233, "column": 28}}, {"id": 1109, "type": "number_literal", "text": "0", "parent": 1106, "children": [], "start_point": {"row": 233, "column": 29}, "end_point": {"row": 233, "column": 30}}, {"id": 1110, "type": "declaration", "text": "COggSplitterFilter(LPUNKNOWN pUnk, HRESULT* phr);", "parent": 1045, "children": [1111, 1115, 1116, 1118], "start_point": {"row": 235, "column": 1}, "end_point": {"row": 235, "column": 50}}, {"id": 1111, "type": "macro_type_specifier", "text": "COggSplitterFilter(LPUNKNOWN", "parent": 1110, "children": [1112, 1113], "start_point": {"row": 235, "column": 1}, "end_point": {"row": 235, "column": 29}}, {"id": 1112, "type": "identifier", "text": "COggSplitterFilter", "parent": 1111, "children": [], "start_point": {"row": 235, "column": 1}, "end_point": {"row": 235, "column": 19}}, {"id": 1113, "type": "type_descriptor", "text": "LPUNKNOWN", "parent": 1111, "children": [1114], "start_point": {"row": 235, "column": 20}, "end_point": {"row": 235, "column": 29}}, {"id": 1114, "type": "type_identifier", "text": "LPUNKNOWN", "parent": 1113, "children": [], "start_point": {"row": 235, "column": 20}, "end_point": {"row": 235, "column": 29}}, {"id": 1115, "type": "identifier", "text": "pUnk", "parent": 1110, "children": [], "start_point": {"row": 235, "column": 30}, "end_point": {"row": 235, "column": 34}}, {"id": 1116, "type": "ERROR", "text": "HRESULT", "parent": 1110, "children": [1117], "start_point": {"row": 235, "column": 36}, "end_point": {"row": 235, "column": 43}}, {"id": 1117, "type": "identifier", "text": "HRESULT", "parent": 1116, "children": [], "start_point": {"row": 235, "column": 36}, "end_point": {"row": 235, "column": 43}}, {"id": 1118, "type": "pointer_declarator", "text": "* phr", "parent": 1110, "children": [1119, 1120], "start_point": {"row": 235, "column": 43}, "end_point": {"row": 235, "column": 48}}, {"id": 1119, "type": "*", "text": "*", "parent": 1118, "children": [], "start_point": {"row": 235, "column": 43}, "end_point": {"row": 235, "column": 44}}, {"id": 1120, "type": "identifier", "text": "phr", "parent": 1118, "children": [], "start_point": {"row": 235, "column": 45}, "end_point": {"row": 235, "column": 48}}, {"id": 1121, "type": "declaration", "text": "virtual ~COggSplitterFilter();", "parent": 1045, "children": [1122, 1123, 1125], "start_point": {"row": 236, "column": 1}, "end_point": {"row": 236, "column": 31}}, {"id": 1122, "type": "type_identifier", "text": "virtual", "parent": 1121, "children": [], "start_point": {"row": 236, "column": 1}, "end_point": {"row": 236, "column": 8}}, {"id": 1123, "type": "ERROR", "text": "~", "parent": 1121, "children": [1124], "start_point": {"row": 236, "column": 9}, "end_point": {"row": 236, "column": 10}}, {"id": 1124, "type": "~", "text": "~", "parent": 1123, "children": [], "start_point": {"row": 236, "column": 9}, "end_point": {"row": 236, "column": 10}}, {"id": 1125, "type": "function_declarator", "text": "COggSplitterFilter()", "parent": 1121, "children": [1126, 1127], "start_point": {"row": 236, "column": 10}, "end_point": {"row": 236, "column": 30}}, {"id": 1126, "type": "identifier", "text": "COggSplitterFilter", "parent": 1125, "children": [], "start_point": {"row": 236, "column": 10}, "end_point": {"row": 236, "column": 28}}, {"id": 1127, "type": "parameter_list", "text": "()", "parent": 1125, "children": [], "start_point": {"row": 236, "column": 28}, "end_point": {"row": 236, "column": 30}}, {"id": 1128, "type": "declaration", "text": "STDMETHODIMP_(HRESULT) QueryFilterInfo(FILTER_INFO* pInfo);", "parent": 1045, "children": [1129, 1133], "start_point": {"row": 240, "column": 1}, "end_point": {"row": 240, "column": 60}}, {"id": 1129, "type": "macro_type_specifier", "text": "STDMETHODIMP_(HRESULT)", "parent": 1128, "children": [1130, 1131], "start_point": {"row": 240, "column": 1}, "end_point": {"row": 240, "column": 23}}, {"id": 1130, "type": "identifier", "text": "STDMETHODIMP_", "parent": 1129, "children": [], "start_point": {"row": 240, "column": 1}, "end_point": {"row": 240, "column": 14}}, {"id": 1131, "type": "type_descriptor", "text": "HRESULT", "parent": 1129, "children": [1132], "start_point": {"row": 240, "column": 15}, "end_point": {"row": 240, "column": 22}}, {"id": 1132, "type": "type_identifier", "text": "HRESULT", "parent": 1131, "children": [], "start_point": {"row": 240, "column": 15}, "end_point": {"row": 240, "column": 22}}, {"id": 1133, "type": "function_declarator", "text": "QueryFilterInfo(FILTER_INFO* pInfo)", "parent": 1128, "children": [1134, 1135], "start_point": {"row": 240, "column": 24}, "end_point": {"row": 240, "column": 59}}, {"id": 1134, "type": "identifier", "text": "QueryFilterInfo", "parent": 1133, "children": [], "start_point": {"row": 240, "column": 24}, "end_point": {"row": 240, "column": 39}}, {"id": 1135, "type": "parameter_list", "text": "(FILTER_INFO* pInfo)", "parent": 1133, "children": [1136], "start_point": {"row": 240, "column": 39}, "end_point": {"row": 240, "column": 59}}, {"id": 1136, "type": "parameter_declaration", "text": "FILTER_INFO* pInfo", "parent": 1135, "children": [1137, 1138], "start_point": {"row": 240, "column": 40}, "end_point": {"row": 240, "column": 58}}, {"id": 1137, "type": "type_identifier", "text": "FILTER_INFO", "parent": 1136, "children": [], "start_point": {"row": 240, "column": 40}, "end_point": {"row": 240, "column": 51}}, {"id": 1138, "type": "pointer_declarator", "text": "* pInfo", "parent": 1136, "children": [1139, 1140], "start_point": {"row": 240, "column": 51}, "end_point": {"row": 240, "column": 58}}, {"id": 1139, "type": "*", "text": "*", "parent": 1138, "children": [], "start_point": {"row": 240, "column": 51}, "end_point": {"row": 240, "column": 52}}, {"id": 1140, "type": "identifier", "text": "pInfo", "parent": 1138, "children": [], "start_point": {"row": 240, "column": 53}, "end_point": {"row": 240, "column": 58}}, {"id": 1141, "type": "ERROR", "text": "class __declspec(uuid(\"6D3688CE-3E9D-42F4-92CA-8A11119D25CD\"))", "parent": null, "children": [1142, 1143, 1144], "start_point": {"row": 243, "column": 0}, "end_point": {"row": 243, "column": 62}}, {"id": 1142, "type": "__declspec", "text": "__declspec", "parent": 1141, "children": [], "start_point": {"row": 243, "column": 6}, "end_point": {"row": 243, "column": 16}}, {"id": 1143, "type": "identifier", "text": "uuid", "parent": 1141, "children": [], "start_point": {"row": 243, "column": 17}, "end_point": {"row": 243, "column": 21}}, {"id": 1144, "type": "string_literal", "text": "\"6D3688CE-3E9D-42F4-92CA-8A11119D25CD\"", "parent": 1141, "children": [], "start_point": {"row": 243, "column": 22}, "end_point": {"row": 243, "column": 60}}, {"id": 1145, "type": "labeled_statement", "text": "COggSourceFilter : public COggSplitterFilter\n{\npublic:\n\tCOggSourceFilter(LPUNKNOWN pUnk, HRESULT* phr);\n}", "parent": null, "children": [1146, 1147], "start_point": {"row": 244, "column": 1}, "end_point": {"row": 248, "column": 1}}, {"id": 1146, "type": "statement_identifier", "text": "COggSourceFilter", "parent": 1145, "children": [], "start_point": {"row": 244, "column": 1}, "end_point": {"row": 244, "column": 17}}, {"id": 1147, "type": "ERROR", "text": "public COggSplitterFilter", "parent": 1145, "children": [1148], "start_point": {"row": 244, "column": 20}, "end_point": {"row": 244, "column": 45}}, {"id": 1148, "type": "identifier", "text": "COggSplitterFilter", "parent": 1147, "children": [], "start_point": {"row": 244, "column": 27}, "end_point": {"row": 244, "column": 45}}, {"id": 1149, "type": "labeled_statement", "text": "public:\n\tCOggSourceFilter(LPUNKNOWN pUnk, HRESULT* phr);", "parent": 1145, "children": [1150], "start_point": {"row": 246, "column": 0}, "end_point": {"row": 247, "column": 48}}, {"id": 1150, "type": "declaration", "text": "COggSourceFilter(LPUNKNOWN pUnk, HRESULT* phr);", "parent": 1149, "children": [1151, 1155, 1156, 1158], "start_point": {"row": 247, "column": 1}, "end_point": {"row": 247, "column": 48}}, {"id": 1151, "type": "macro_type_specifier", "text": "COggSourceFilter(LPUNKNOWN", "parent": 1150, "children": [1152, 1153], "start_point": {"row": 247, "column": 1}, "end_point": {"row": 247, "column": 27}}, {"id": 1152, "type": "identifier", "text": "COggSourceFilter", "parent": 1151, "children": [], "start_point": {"row": 247, "column": 1}, "end_point": {"row": 247, "column": 17}}, {"id": 1153, "type": "type_descriptor", "text": "LPUNKNOWN", "parent": 1151, "children": [1154], "start_point": {"row": 247, "column": 18}, "end_point": {"row": 247, "column": 27}}, {"id": 1154, "type": "type_identifier", "text": "LPUNKNOWN", "parent": 1153, "children": [], "start_point": {"row": 247, "column": 18}, "end_point": {"row": 247, "column": 27}}, {"id": 1155, "type": "identifier", "text": "pUnk", "parent": 1150, "children": [], "start_point": {"row": 247, "column": 28}, "end_point": {"row": 247, "column": 32}}, {"id": 1156, "type": "ERROR", "text": "HRESULT", "parent": 1150, "children": [1157], "start_point": {"row": 247, "column": 34}, "end_point": {"row": 247, "column": 41}}, {"id": 1157, "type": "identifier", "text": "HRESULT", "parent": 1156, "children": [], "start_point": {"row": 247, "column": 34}, "end_point": {"row": 247, "column": 41}}, {"id": 1158, "type": "pointer_declarator", "text": "* phr", "parent": 1150, "children": [1159, 1160], "start_point": {"row": 247, "column": 41}, "end_point": {"row": 247, "column": 46}}, {"id": 1159, "type": "*", "text": "*", "parent": 1158, "children": [], "start_point": {"row": 247, "column": 41}, "end_point": {"row": 247, "column": 42}}, {"id": 1160, "type": "identifier", "text": "phr", "parent": 1158, "children": [], "start_point": {"row": 247, "column": 43}, "end_point": {"row": 247, "column": 46}}]}, "node_categories": {"declarations": {"functions": [19, 58, 100, 113, 121, 137, 170, 188, 193, 205, 264, 272, 284, 321, 327, 329, 341, 382, 414, 443, 472, 508, 537, 564, 591, 618, 645, 698, 728, 734, 736, 748, 786, 820, 826, 828, 835, 846, 881, 913, 945, 977, 1009, 1059, 1069, 1074, 1082, 1125, 1133], "variables": [17, 35, 47, 50, 53, 56, 61, 67, 77, 98, 103, 108, 111, 116, 119, 124, 127, 132, 135, 140, 143, 173, 186, 191, 196, 199, 202, 221, 224, 239, 260, 267, 270, 275, 282, 287, 290, 293, 319, 324, 345, 348, 351, 354, 357, 378, 385, 418, 439, 446, 476, 480, 483, 504, 511, 661, 664, 667, 670, 673, 694, 701, 726, 731, 752, 755, 758, 761, 782, 789, 818, 823, 833, 838, 843, 850, 853, 856, 877, 884, 917, 920, 941, 948, 981, 984, 1005, 1012, 1057, 1062, 1067, 1072, 1077, 1080, 1085, 1091, 1097, 1104, 1110, 1121, 1128, 1136, 1150], "classes": [], "imports": [3, 4, 6, 7], "modules": [], "enums": []}, "statements": {"expressions": [26, 27, 31, 40, 41, 146, 149, 150, 155, 157, 177, 178, 183, 211, 212, 217, 232, 233, 242, 245, 246, 251, 253, 297, 300, 307, 311, 315, 333, 334, 335, 360, 363, 364, 369, 371, 389, 392, 402, 406, 410, 421, 424, 425, 430, 432, 450, 453, 460, 464, 468, 486, 489, 490, 495, 497, 515, 518, 525, 529, 533, 542, 545, 552, 556, 560, 569, 572, 579, 583, 587, 596, 599, 606, 610, 614, 623, 626, 633, 637, 641, 651, 652, 657, 676, 679, 680, 685, 687, 705, 708, 714, 718, 722, 740, 741, 742, 764, 767, 768, 773, 775, 793, 796, 806, 810, 814, 859, 862, 863, 868, 870, 888, 891, 901, 905, 909, 923, 926, 927, 932, 934, 952, 955, 965, 969, 973, 987, 990, 991, 996, 998, 1016, 1019, 1029, 1033, 1037, 1050, 1051], "assignments": [], "loops": [], "conditionals": [11, 15, 18, 21, 22, 25, 28, 30, 32, 34, 36, 37, 39, 42, 44, 46, 48, 49, 51, 52, 55, 59, 62, 64, 66, 68, 72, 78, 79, 81, 82, 84, 87, 89, 92, 94, 97, 101, 104, 107, 110, 112, 114, 117, 118, 122, 125, 126, 128, 131, 134, 136, 138, 141, 142, 144, 145, 147, 151, 153, 156, 158, 160, 161, 163, 165, 167, 169, 171, 174, 175, 176, 179, 181, 184, 187, 189, 192, 194, 197, 198, 200, 201, 204, 207, 208, 210, 213, 215, 218, 220, 222, 223, 225, 227, 229, 231, 234, 236, 238, 240, 241, 243, 247, 249, 252, 254, 256, 257, 259, 261, 263, 265, 268, 269, 271, 273, 276, 279, 281, 283, 285, 288, 289, 291, 292, 295, 298, 301, 303, 304, 306, 308, 310, 312, 314, 316, 318, 320, 322, 325, 326, 330, 336, 337, 343, 344, 347, 350, 352, 353, 356, 358, 359, 361, 365, 367, 370, 372, 374, 375, 377, 379, 381, 383, 386, 387, 390, 393, 395, 397, 398, 399, 401, 403, 405, 407, 409, 411, 413, 415, 417, 419, 420, 422, 426, 428, 431, 433, 435, 436, 438, 440, 442, 444, 447, 448, 451, 454, 456, 457, 459, 461, 463, 465, 467, 469, 471, 474, 475, 477, 478, 479, 481, 482, 484, 485, 487, 491, 493, 496, 498, 500, 501, 503, 505, 507, 509, 512, 513, 516, 519, 521, 522, 524, 526, 528, 530, 532, 534, 536, 539, 540, 543, 546, 548, 549, 551, 553, 555, 557, 559, 561, 563, 566, 567, 570, 573, 575, 576, 578, 580, 582, 584, 586, 588, 590, 593, 594, 597, 600, 602, 603, 605, 607, 609, 611, 613, 615, 617, 620, 621, 624, 627, 629, 630, 632, 634, 636, 638, 640, 642, 644, 647, 648, 650, 653, 655, 658, 660, 662, 663, 665, 666, 668, 669, 671, 672, 674, 675, 677, 681, 683, 686, 688, 690, 691, 693, 695, 697, 699, 702, 703, 706, 709, 710, 711, 713, 715, 717, 719, 721, 723, 725, 727, 729, 732, 733, 737, 743, 744, 750, 751, 753, 754, 757, 760, 762, 763, 765, 769, 771, 774, 776, 778, 779, 781, 783, 785, 787, 790, 791, 794, 797, 799, 801, 802, 803, 805, 807, 809, 811, 813, 815, 817, 819, 821, 824, 825, 829, 832, 834, 836, 839, 842, 845, 848, 849, 852, 854, 855, 857, 858, 860, 864, 866, 869, 871, 873, 874, 876, 878, 880, 882, 885, 886, 889, 892, 894, 896, 897, 898, 900, 902, 904, 906, 908, 910, 912, 915, 916, 919, 921, 922, 924, 928, 930, 933, 935, 937, 938, 940, 942, 944, 946, 949, 950, 953, 956, 958, 960, 961, 962, 964, 966, 968, 970, 972, 974, 976, 979, 980, 982, 983, 985, 986, 988, 992, 994, 997, 999, 1001, 1002, 1004, 1006, 1008, 1010, 1013, 1014, 1017, 1020, 1022, 1024, 1025, 1026, 1028, 1030, 1032, 1034, 1036, 1038, 1040, 1043, 1046, 1048, 1052, 1054, 1056, 1058, 1060, 1063, 1066, 1070, 1075, 1078, 1079, 1083, 1086, 1088, 1092, 1094, 1098, 1100, 1102, 1105, 1107, 1111, 1112, 1114, 1115, 1117, 1120, 1122, 1126, 1129, 1130, 1132, 1134, 1137, 1140, 1143, 1146, 1148, 1151, 1152, 1154, 1155, 1157, 1160], "returns": [332, 739, 831], "exceptions": []}, "expressions": {"calls": [0], "literals": [5, 8, 228, 340, 747, 1044, 1090, 1096, 1109, 1144], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 19, "universal_type": "function", "name": "COggSplitterOutputPin", "text_snippet": "class COggSplitterOutputPin : public CBaseSplitterOutputPin\n{\nprotected:\n\tstd::map<CStringW, CString"}, {"node_id": 58, "universal_type": "function", "name": "unknown", "text_snippet": "ResetState(DWORD seqnum = DWORD_MAX)"}, {"node_id": 100, "universal_type": "function", "name": "len)", "text_snippet": "AddComment(BYTE* p, int len)"}, {"node_id": 113, "universal_type": "function", "name": "unknown", "text_snippet": "GetComment(CStringW key)"}, {"node_id": 121, "universal_type": "function", "name": "len)", "text_snippet": "HandlePacket(DWORD TrackNumber, BYTE* pData, int len)"}, {"node_id": 137, "universal_type": "function", "name": "unknown", "text_snippet": "UnpackPage(OggPage& page)"}, {"node_id": 170, "universal_type": "function", "name": "unknown", "text_snippet": "GetRefTime(__int64 granule_position) PURE"}, {"node_id": 188, "universal_type": "function", "name": "unknown", "text_snippet": "DeliverEndFlush()"}, {"node_id": 193, "universal_type": "function", "name": "unknown", "text_snippet": "DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate)"}, {"node_id": 205, "universal_type": "function", "name": "COggVorbisOutputPin", "text_snippet": "class COggVorbisOutputPin : public COggSplitterOutputPin\n{\n\tstd::list<CAutoPtr<CPacket>> m_initpacke"}, {"node_id": 264, "universal_type": "function", "name": "unknown", "text_snippet": "GetRefTime(__int64 granule_position)"}, {"node_id": 272, "universal_type": "function", "name": "unknown", "text_snippet": "DeliverPacket(CAutoPtr<CPacket> p)"}, {"node_id": 284, "universal_type": "function", "name": "unknown", "text_snippet": "DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate)"}, {"node_id": 321, "universal_type": "function", "name": "unknown", "text_snippet": "UnpackInitPage(OggPage& page)"}, {"node_id": 327, "universal_type": "function", "name": "IsInitialized", "text_snippet": "bool IsInitialized() {\n\t\treturn m_initpackets.size() >= 3;\n\t}"}, {"node_id": 329, "universal_type": "function", "name": "unknown", "text_snippet": "IsInitialized()"}, {"node_id": 341, "universal_type": "function", "name": "COggFlacOutputPin", "text_snippet": "class COggFlacOutputPin : public COggSplitterOutputPin\n{\n\tint m_nSamplesPerSec;\n\tint m_nChannels;\n"}, {"node_id": 382, "universal_type": "function", "name": "unknown", "text_snippet": "GetRefTime(__int64 granule_position)"}, {"node_id": 414, "universal_type": "function", "name": "COggDirectShowOutputPin", "text_snippet": "class COggDirectShowOutputPin : public COggSplitterOutputPin\n{\n\tvirtual HRESULT UnpackPacket(CAutoPt"}, {"node_id": 443, "universal_type": "function", "name": "unknown", "text_snippet": "GetRefTime(__int64 granule_position)"}, {"node_id": 472, "universal_type": "function", "name": "COggStreamOutputPin", "text_snippet": "class COggStreamOutputPin : public COggSplitterOutputPin\n{\n\t__int64 m_time_unit, m_samples_per_unit;"}, {"node_id": 508, "universal_type": "function", "name": "unknown", "text_snippet": "GetRefTime(__int64 granule_position)"}, {"node_id": 537, "universal_type": "function", "name": "COggVideoOutputPin", "text_snippet": "class COggVideoOutputPin : public COggStreamOutputPin\n{\npublic:\n\tCOggVideoOutputPin(OggStreamHeader*"}, {"node_id": 564, "universal_type": "function", "name": "COggAudioOutputPin", "text_snippet": "class COggAudioOutputPin : public COggStreamOutputPin\n{\npublic:\n\tCOggAudioOutputPin(OggStreamHeader*"}, {"node_id": 591, "universal_type": "function", "name": "COggTextOutputPin", "text_snippet": "class COggTextOutputPin : public COggStreamOutputPin\n{\npublic:\n\tCOggTextOutputPin(OggStreamHeader* h"}, {"node_id": 618, "universal_type": "function", "name": "COggKateOutputPin", "text_snippet": "class COggKateOutputPin : public COggStreamOutputPin\n{\npublic:\n\tCOggKateOutputPin(OggStreamHeader* h"}, {"node_id": 645, "universal_type": "function", "name": "COggTheoraOutputPin", "text_snippet": "class COggTheoraOutputPin : public COggSplitterOutputPin\n{\n\tstd::list<CAutoPtr<CPacket>> m_initpacke"}, {"node_id": 698, "universal_type": "function", "name": "unknown", "text_snippet": "GetRefTime(__int64 granule_position)"}, {"node_id": 728, "universal_type": "function", "name": "unknown", "text_snippet": "UnpackInitPage(OggPage& page)"}, {"node_id": 734, "universal_type": "function", "name": "IsInitialized", "text_snippet": "bool IsInitialized() {\n\t\treturn m_initpackets.size() >= 3;\n\t}"}, {"node_id": 736, "universal_type": "function", "name": "unknown", "text_snippet": "IsInitialized()"}, {"node_id": 748, "universal_type": "function", "name": "COggDiracOutputPin", "text_snippet": "class COggDiracOutputPin : public COggSplitterOutputPin\n{\n\tREFERENCE_TIME m_rtAvgTimePerFrame;\n\tbool"}, {"node_id": 786, "universal_type": "function", "name": "unknown", "text_snippet": "GetRefTime(__int64 granule_position)"}, {"node_id": 820, "universal_type": "function", "name": "unknown", "text_snippet": "UnpackInitPage(OggPage& page)"}, {"node_id": 826, "universal_type": "function", "name": "IsInitialized", "text_snippet": "bool IsInitialized() {\n\t\treturn m_IsInitialized;\n\t}"}, {"node_id": 828, "universal_type": "function", "name": "unknown", "text_snippet": "IsInitialized()"}, {"node_id": 835, "universal_type": "function", "name": "nCount)", "text_snippet": "InitDirac(BYTE* p, int nCount)"}, {"node_id": 846, "universal_type": "function", "name": "COggOpusOutputPin", "text_snippet": "class COggOpusOutputPin : public COggSplitterOutputPin\n{\n\tint m_SampleRate;\n\tWORD m_Preskip;\n\n\tvirt"}, {"node_id": 881, "universal_type": "function", "name": "unknown", "text_snippet": "GetRefTime(__int64 granule_position)"}, {"node_id": 913, "universal_type": "function", "name": "COggSpeexOutputPin", "text_snippet": "class COggSpeexOutputPin : public COggSplitterOutputPin\n{\n\tint m_SampleRate;\n\n\tvirtual HRESULT Unpac"}, {"node_id": 945, "universal_type": "function", "name": "unknown", "text_snippet": "GetRefTime(__int64 granule_position)"}, {"node_id": 977, "universal_type": "function", "name": "COggVP8OutputPin", "text_snippet": "class COggVP8OutputPin : public COggSplitterOutputPin\n{\n\tREFERENCE_TIME m_rtAvgTimePerFrame;\n\n\tvirtu"}, {"node_id": 1009, "universal_type": "function", "name": "unknown", "text_snippet": "GetRefTime(__int64 granule_position)"}, {"node_id": 1059, "universal_type": "function", "name": "unknown", "text_snippet": "CreateOutputs(IAsyncReader* pAsyncReader)"}, {"node_id": 1069, "universal_type": "function", "name": "unknown", "text_snippet": "DemuxInit()"}, {"node_id": 1074, "universal_type": "function", "name": "unknown", "text_snippet": "DemuxSeek(REFERENCE_TIME rt)"}, {"node_id": 1082, "universal_type": "function", "name": "unknown", "text_snippet": "DemuxLoop()"}, {"node_id": 1125, "universal_type": "function", "name": "unknown", "text_snippet": "COggSplitterFilter()"}, {"node_id": 1133, "universal_type": "function", "name": "unknown", "text_snippet": "QueryFilterInfo(FILTER_INFO* pInfo)"}], "class_declarations": [], "import_statements": [{"node_id": 3, "text": "#include \"OggFile.h\"\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include \"../BaseSplitter/BaseSplitter.h\"\n"}, {"node_id": 7, "text": "#include"}]}, "original_source_code": "/*\n * (C) 2003-2006 Gabest\n * (C) 2006-2018 see Authors.txt\n *\n * This file is part of MPC-BE.\n *\n * MPC-BE is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 3 of the License, or\n * (at your option) any later version.\n *\n * MPC-BE is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\n#pragma once\n\n#include \"OggFile.h\"\n#include \"../BaseSplitter/BaseSplitter.h\"\n\n#define OggSplitterName L\"MPC Ogg Splitter\"\n#define OggSourceName L\"MPC Ogg Source\"\n\nclass COggSplitterFilter;\n\nclass COggSplitterOutputPin : public CBaseSplitterOutputPin\n{\nprotected:\n\tstd::map<CStringW, CStringW> m_pComments;\n\n\tCPacketQueue m_queue;\n\tstd::vector<BYTE> m_lastPacketData;\n\tDWORD m_lastseqnum;\n\tREFERENCE_TIME m_rtLast;\n\tbool m_bSetKeyFrame;\n\n\tvoid ResetState(DWORD seqnum = DWORD_MAX);\n\n\tCOggSplitterFilter* m_pFilter = nullptr;\n\npublic:\n\tCOggSplitterOutputPin(LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n\tvoid AddComment(BYTE* p, int len);\n\tCStringW GetComment(CStringW key);\n\n\tvoid HandlePacket(DWORD TrackNumber, BYTE* pData, int len);\n\tHRESULT UnpackPage(OggPage& page);\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len) PURE;\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position) PURE;\n\tCAutoPtr<CPacket> GetPacket();\n\n\tHRESULT DeliverEndFlush();\n\tHRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);\n};\n\nclass COggVorbisOutputPin : public COggSplitterOutputPin\n{\n\tstd::list<CAutoPtr<CPacket>> m_initpackets;\n\n\tDWORD m_audio_sample_rate;\n\tDWORD m_blocksize[2], m_lastblocksize;\n\tstd::vector<bool> m_blockflags;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\n\tHRESULT DeliverPacket(CAutoPtr<CPacket> p);\n\tHRESULT DeliverNewSegment(REFERENCE_TIME tStart, REFERENCE_TIME tStop, double dRate);\n\npublic:\n\tCOggVorbisOutputPin(OggVorbisIdHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n\tHRESULT UnpackInitPage(OggPage& page);\n\tbool IsInitialized() {\n\t\treturn m_initpackets.size() >= 3;\n\t}\n};\n\nclass COggFlacOutputPin : public COggSplitterOutputPin\n{\n\tint m_nSamplesPerSec;\n\tint m_nChannels;\n\tWORD m_wBitsPerSample;\n\tint m_nAvgBytesPerSec;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggFlacOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggDirectShowOutputPin : public COggSplitterOutputPin\n{\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggDirectShowOutputPin(AM_MEDIA_TYPE* pmt, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggStreamOutputPin : public COggSplitterOutputPin\n{\n\t__int64 m_time_unit, m_samples_per_unit;\n\tDWORD m_default_len;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggStreamOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggVideoOutputPin : public COggStreamOutputPin\n{\npublic:\n\tCOggVideoOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggAudioOutputPin : public COggStreamOutputPin\n{\npublic:\n\tCOggAudioOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggTextOutputPin : public COggStreamOutputPin\n{\npublic:\n\tCOggTextOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggKateOutputPin : public COggStreamOutputPin\n{\npublic:\n\tCOggKateOutputPin(OggStreamHeader* h, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggTheoraOutputPin : public COggSplitterOutputPin\n{\n\tstd::list<CAutoPtr<CPacket>> m_initpackets;\n\tLONG m_KfgShift;\n\tLONG m_KfgMask;\n\tUINT m_nVersion;\n\tREFERENCE_TIME m_rtAvgTimePerFrame;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggTheoraOutputPin(OggPage& page, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n\tHRESULT UnpackInitPage(OggPage& page);\n\tbool IsInitialized() {\n\t\treturn m_initpackets.size() >= 3;\n\t}\n};\n\nclass COggDiracOutputPin : public COggSplitterOutputPin\n{\n\tREFERENCE_TIME m_rtAvgTimePerFrame;\n\tbool m_bOldDirac;\n\tbool m_IsInitialized;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggDiracOutputPin(BYTE* p, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n\n\tHRESULT UnpackInitPage(OggPage& page);\n\tbool IsInitialized() {\n\t\treturn m_IsInitialized;\n\t}\n\tHRESULT InitDirac(BYTE* p, int nCount);\n};\n\nclass COggOpusOutputPin : public COggSplitterOutputPin\n{\n\tint m_SampleRate;\n\tWORD m_Preskip;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggOpusOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggSpeexOutputPin : public COggSplitterOutputPin\n{\n\tint m_SampleRate;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggSpeexOutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass COggVP8OutputPin : public COggSplitterOutputPin\n{\n\tREFERENCE_TIME m_rtAvgTimePerFrame;\n\n\tvirtual HRESULT UnpackPacket(CAutoPtr<CPacket>& p, BYTE* pData, int len);\n\tvirtual REFERENCE_TIME GetRefTime(__int64 granule_position);\n\npublic:\n\tCOggVP8OutputPin(BYTE* h, int nCount, LPCWSTR pName, CBaseFilter* pFilter, CCritSec* pLock, HRESULT* phr);\n};\n\nclass __declspec(uuid(\"9FF48807-E133-40AA-826F-9B2959E5232D\"))\n\tCOggSplitterFilter : public CBaseSplitterFilter\n{\nprotected:\n\tCAutoPtr<COggFile> m_pFile;\n\tHRESULT CreateOutputs(IAsyncReader* pAsyncReader);\n\n\tbool DemuxInit();\n\tvoid DemuxSeek(REFERENCE_TIME rt);\n\tbool DemuxLoop();\n\n\tDWORD m_bitstream_serial_number_start = 0;\n\tDWORD m_bitstream_serial_number_last = 0;\n\tDWORD m_bitstream_serial_number_Video = DWORD_MAX;\n\npublic:\n\tREFERENCE_TIME m_rtOffset = 0;\n\n\tCOggSplitterFilter(LPUNKNOWN pUnk, HRESULT* phr);\n\tvirtual ~COggSplitterFilter();\n\n\t// CBaseFilter\n\n\tSTDMETHODIMP_(HRESULT) QueryFilterInfo(FILTER_INFO* pInfo);\n};\n\nclass __declspec(uuid(\"6D3688CE-3E9D-42F4-92CA-8A11119D25CD\"))\n\tCOggSourceFilter : public COggSplitterFilter\n{\npublic:\n\tCOggSourceFilter(LPUNKNOWN pUnk, HRESULT* phr);\n};\n"}
80,540
c
#include "../../../../../src/location/places/qplacemanagerengine_p.h"
69
1
(translation_unit) "#include "../../../../../src/location/places/qplacemanagerengine_p.h"\n" (preproc_include) "#include "../../../../../src/location/places/qplacemanagerengine_p.h"\n" (#include) "#include" (string_literal) ""../../../../../src/location/places/qplacemanagerengine_p.h"" (") """ (string_content) "../../../../../src/location/places/qplacemanagerengine_p.h" (") """
7
0
{"language": "c", "success": true, "metadata": {"lines": 1, "avg_line_length": 69.0, "nodes": 3, "errors": 0, "source_hash": "feccce165db4755d2b0ad048b5cf36d862946facf0d9d7212e170cea65c016a2", "categorized_nodes": 3}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"../../../../../src/location/places/qplacemanagerengine_p.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"../../../../../src/location/places/qplacemanagerengine_p.h\"", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 69}}]}, "node_categories": {"declarations": {"functions": [], "variables": [], "classes": [], "imports": [0, 1], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [2], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include \"../../../../../src/location/places/qplacemanagerengine_p.h\"\n"}, {"node_id": 1, "text": "#include"}]}, "original_source_code": "#include \"../../../../../src/location/places/qplacemanagerengine_p.h\"\n"}
80,541
c
// Copyright 1998-2017 Epic Games, Inc. All Rights Reserved. #pragma once #include "ShooterCharacter.h" #include "ShooterBot.generated.h" UCLASS() class SHOOTERGAME_API AShooterBot : public AShooterCharacter { GENERATED_UCLASS_BODY() virtual bool IsFirstPerson() const override; virtual void FaceRotation(FRotator NewRotation, float DeltaTime = 0.f) override; };
32.27
11
(translation_unit) "// Copyright 1998-2017 Epic Games, Inc. All Rights Reserved.\n\n#pragma once\n\n#include "ShooterCharacter.h"\n#include "ShooterBot.generated.h"\n\nUCLASS()\nclass SHOOTERGAME_API AShooterBot : public AShooterCharacter\n{\n GENERATED_UCLASS_BODY()\n\n virtual bool IsFirstPerson() const override;\n\n virtual void FaceRotation(FRotator NewRotation, float DeltaTime = 0.f) override;\n};" (comment) "// Copyright 1998-2017 Epic Games, Inc. All Rights Reserved." (preproc_call) "#pragma once\n" (preproc_directive) "#pragma" (preproc_arg) "once" (preproc_include) "#include "ShooterCharacter.h"\n" (#include) "#include" (string_literal) ""ShooterCharacter.h"" (") """ (string_content) "ShooterCharacter.h" (") """ (preproc_include) "#include "ShooterBot.generated.h"\n" (#include) "#include" (string_literal) ""ShooterBot.generated.h"" (") """ (string_content) "ShooterBot.generated.h" (") """ (ERROR) "UCLASS()\nclass" (call_expression) "UCLASS()" (identifier) "UCLASS" (argument_list) "()" (() "(" ()) ")" (identifier) "class" (function_definition) "SHOOTERGAME_API AShooterBot : public AShooterCharacter\n{\n GENERATED_UCLASS_BODY()\n\n virtual bool IsFirstPerson() const override;\n\n virtual void FaceRotation(FRotator NewRotation, float DeltaTime = 0.f) override;\n}" (type_identifier) "SHOOTERGAME_API" (ERROR) "AShooterBot : public" (identifier) "AShooterBot" (:) ":" (identifier) "public" (identifier) "AShooterCharacter" (compound_statement) "{\n GENERATED_UCLASS_BODY()\n\n virtual bool IsFirstPerson() const override;\n\n virtual void FaceRotation(FRotator NewRotation, float DeltaTime = 0.f) override;\n}" ({) "{" (ERROR) "GENERATED_UCLASS_BODY()\n\n virtual bool IsFirstPerson() const override" (call_expression) "GENERATED_UCLASS_BODY()" (identifier) "GENERATED_UCLASS_BODY" (argument_list) "()" (() "(" ()) ")" (identifier) "virtual" (primitive_type) "bool" (function_declarator) "IsFirstPerson()" (identifier) "IsFirstPerson" (parameter_list) "()" (() "(" ()) ")" (type_qualifier) "const" (const) "const" (type_identifier) "override" (expression_statement) ";" (;) ";" (declaration) "virtual void FaceRotation(FRotator NewRotation, float DeltaTime = 0.f) override;" (type_identifier) "virtual" (ERROR) "void" (identifier) "void" (init_declarator) "FaceRotation(FRotator NewRotation, float DeltaTime = 0.f) override" (function_declarator) "FaceRotation(FRotator NewRotation, float DeltaTime" (identifier) "FaceRotation" (parameter_list) "(FRotator NewRotation, float DeltaTime" (() "(" (parameter_declaration) "FRotator NewRotation" (type_identifier) "FRotator" (identifier) "NewRotation" (,) "," (parameter_declaration) "float DeltaTime" (primitive_type) "float" (identifier) "DeltaTime" ()) "" (=) "=" (ERROR) "0.f)" (number_literal) "0.f" ()) ")" (identifier) "override" (;) ";" (}) "}" (expression_statement) ";" (;) ";"
77
5
{"language": "c", "success": true, "metadata": {"lines": 11, "avg_line_length": 32.27, "nodes": 46, "errors": 0, "source_hash": "c6fbbaf05bd06044710c84aef974f8c8a60233a25c81d2e180b1fffac16d0f6b", "categorized_nodes": 31}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#pragma once\n", "parent": null, "children": [1, 2], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#pragma", "parent": 0, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "once", "parent": 0, "children": [], "start_point": {"row": 2, "column": 8}, "end_point": {"row": 2, "column": 12}}, {"id": 3, "type": "preproc_include", "text": "#include \"ShooterCharacter.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 5, "type": "string_literal", "text": "\"ShooterCharacter.h\"", "parent": 3, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 29}}, {"id": 6, "type": "preproc_include", "text": "#include \"ShooterBot.generated.h\"\n", "parent": null, "children": [7, 8], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"ShooterBot.generated.h\"", "parent": 6, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 33}}, {"id": 9, "type": "ERROR", "text": "UCLASS()\nclass", "parent": null, "children": [10], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 5}}, {"id": 10, "type": "call_expression", "text": "UCLASS()", "parent": 9, "children": [11, 12], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 8}}, {"id": 11, "type": "identifier", "text": "UCLASS", "parent": 10, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 6}}, {"id": 12, "type": "argument_list", "text": "()", "parent": 10, "children": [], "start_point": {"row": 7, "column": 6}, "end_point": {"row": 7, "column": 8}}, {"id": 13, "type": "function_definition", "text": "SHOOTERGAME_API AShooterBot : public AShooterCharacter\n{\n\tGENERATED_UCLASS_BODY()\n\n\tvirtual bool IsFirstPerson() const override;\n\n\tvirtual void FaceRotation(FRotator NewRotation, float DeltaTime = 0.f) override;\n}", "parent": null, "children": [14, 15, 17], "start_point": {"row": 8, "column": 6}, "end_point": {"row": 15, "column": 1}}, {"id": 14, "type": "type_identifier", "text": "SHOOTERGAME_API", "parent": 13, "children": [], "start_point": {"row": 8, "column": 6}, "end_point": {"row": 8, "column": 21}}, {"id": 15, "type": "ERROR", "text": "AShooterBot : public", "parent": 13, "children": [16], "start_point": {"row": 8, "column": 22}, "end_point": {"row": 8, "column": 42}}, {"id": 16, "type": "identifier", "text": "AShooterBot", "parent": 15, "children": [], "start_point": {"row": 8, "column": 22}, "end_point": {"row": 8, "column": 33}}, {"id": 17, "type": "identifier", "text": "AShooterCharacter", "parent": 13, "children": [], "start_point": {"row": 8, "column": 43}, "end_point": {"row": 8, "column": 60}}, {"id": 18, "type": "ERROR", "text": "GENERATED_UCLASS_BODY()\n\n\tvirtual bool IsFirstPerson() const override", "parent": 13, "children": [19, 22, 23, 24, 27], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 12, "column": 44}}, {"id": 19, "type": "call_expression", "text": "GENERATED_UCLASS_BODY()", "parent": 18, "children": [20, 21], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 24}}, {"id": 20, "type": "identifier", "text": "GENERATED_UCLASS_BODY", "parent": 19, "children": [], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 22}}, {"id": 21, "type": "argument_list", "text": "()", "parent": 19, "children": [], "start_point": {"row": 10, "column": 22}, "end_point": {"row": 10, "column": 24}}, {"id": 22, "type": "identifier", "text": "virtual", "parent": 18, "children": [], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 8}}, {"id": 23, "type": "primitive_type", "text": "bool", "parent": 18, "children": [], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 13}}, {"id": 24, "type": "function_declarator", "text": "IsFirstPerson()", "parent": 18, "children": [25, 26], "start_point": {"row": 12, "column": 14}, "end_point": {"row": 12, "column": 29}}, {"id": 25, "type": "identifier", "text": "IsFirstPerson", "parent": 24, "children": [], "start_point": {"row": 12, "column": 14}, "end_point": {"row": 12, "column": 27}}, {"id": 26, "type": "parameter_list", "text": "()", "parent": 24, "children": [], "start_point": {"row": 12, "column": 27}, "end_point": {"row": 12, "column": 29}}, {"id": 27, "type": "type_identifier", "text": "override", "parent": 18, "children": [], "start_point": {"row": 12, "column": 36}, "end_point": {"row": 12, "column": 44}}, {"id": 28, "type": "declaration", "text": "virtual void FaceRotation(FRotator NewRotation, float DeltaTime = 0.f) override;", "parent": 13, "children": [29, 30, 32], "start_point": {"row": 14, "column": 1}, "end_point": {"row": 14, "column": 81}}, {"id": 29, "type": "type_identifier", "text": "virtual", "parent": 28, "children": [], "start_point": {"row": 14, "column": 1}, "end_point": {"row": 14, "column": 8}}, {"id": 30, "type": "ERROR", "text": "void", "parent": 28, "children": [31], "start_point": {"row": 14, "column": 9}, "end_point": {"row": 14, "column": 13}}, {"id": 31, "type": "identifier", "text": "void", "parent": 30, "children": [], "start_point": {"row": 14, "column": 9}, "end_point": {"row": 14, "column": 13}}, {"id": 32, "type": "init_declarator", "text": "FaceRotation(FRotator NewRotation, float DeltaTime = 0.f) override", "parent": 28, "children": [33, 42, 43, 45], "start_point": {"row": 14, "column": 14}, "end_point": {"row": 14, "column": 80}}, {"id": 33, "type": "function_declarator", "text": "FaceRotation(FRotator NewRotation, float DeltaTime", "parent": 32, "children": [34, 35], "start_point": {"row": 14, "column": 14}, "end_point": {"row": 14, "column": 64}}, {"id": 34, "type": "identifier", "text": "FaceRotation", "parent": 33, "children": [], "start_point": {"row": 14, "column": 14}, "end_point": {"row": 14, "column": 26}}, {"id": 35, "type": "parameter_list", "text": "(FRotator NewRotation, float DeltaTime", "parent": 33, "children": [36, 39], "start_point": {"row": 14, "column": 26}, "end_point": {"row": 14, "column": 64}}, {"id": 36, "type": "parameter_declaration", "text": "FRotator NewRotation", "parent": 35, "children": [37, 38], "start_point": {"row": 14, "column": 27}, "end_point": {"row": 14, "column": 47}}, {"id": 37, "type": "type_identifier", "text": "FRotator", "parent": 36, "children": [], "start_point": {"row": 14, "column": 27}, "end_point": {"row": 14, "column": 35}}, {"id": 38, "type": "identifier", "text": "NewRotation", "parent": 36, "children": [], "start_point": {"row": 14, "column": 36}, "end_point": {"row": 14, "column": 47}}, {"id": 39, "type": "parameter_declaration", "text": "float DeltaTime", "parent": 35, "children": [40, 41], "start_point": {"row": 14, "column": 49}, "end_point": {"row": 14, "column": 64}}, {"id": 40, "type": "primitive_type", "text": "float", "parent": 39, "children": [], "start_point": {"row": 14, "column": 49}, "end_point": {"row": 14, "column": 54}}, {"id": 41, "type": "identifier", "text": "DeltaTime", "parent": 39, "children": [], "start_point": {"row": 14, "column": 55}, "end_point": {"row": 14, "column": 64}}, {"id": 42, "type": "=", "text": "=", "parent": 32, "children": [], "start_point": {"row": 14, "column": 65}, "end_point": {"row": 14, "column": 66}}, {"id": 43, "type": "ERROR", "text": "0.f)", "parent": 32, "children": [44], "start_point": {"row": 14, "column": 67}, "end_point": {"row": 14, "column": 71}}, {"id": 44, "type": "number_literal", "text": "0.f", "parent": 43, "children": [], "start_point": {"row": 14, "column": 67}, "end_point": {"row": 14, "column": 70}}, {"id": 45, "type": "identifier", "text": "override", "parent": 32, "children": [], "start_point": {"row": 14, "column": 72}, "end_point": {"row": 14, "column": 80}}]}, "node_categories": {"declarations": {"functions": [13, 24, 33], "variables": [28, 36, 39], "classes": [], "imports": [3, 4, 6, 7], "modules": [], "enums": []}, "statements": {"expressions": [10, 19], "assignments": [], "loops": [], "conditionals": [11, 14, 16, 17, 20, 22, 25, 27, 29, 31, 34, 37, 38, 41, 45], "returns": [], "exceptions": []}, "expressions": {"calls": [0], "literals": [5, 8, 44], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 13, "universal_type": "function", "name": "IsFirstPerson", "text_snippet": "SHOOTERGAME_API AShooterBot : public AShooterCharacter\n{\n\tGENERATED_UCLASS_BODY()\n\n\tvirtual bool IsF"}, {"node_id": 24, "universal_type": "function", "name": "unknown", "text_snippet": "IsFirstPerson()"}, {"node_id": 33, "universal_type": "function", "name": "unknown", "text_snippet": "FaceRotation(FRotator NewRotation, float DeltaTime"}], "class_declarations": [], "import_statements": [{"node_id": 3, "text": "#include \"ShooterCharacter.h\"\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include \"ShooterBot.generated.h\"\n"}, {"node_id": 7, "text": "#include"}]}, "original_source_code": "// Copyright 1998-2017 Epic Games, Inc. All Rights Reserved.\n\n#pragma once\n\n#include \"ShooterCharacter.h\"\n#include \"ShooterBot.generated.h\"\n\nUCLASS()\nclass SHOOTERGAME_API AShooterBot : public AShooterCharacter\n{\n\tGENERATED_UCLASS_BODY()\n\n\tvirtual bool IsFirstPerson() const override;\n\n\tvirtual void FaceRotation(FRotator NewRotation, float DeltaTime = 0.f) override;\n};"}
80,542
c
#ifndef DUNGEONGAME_REWARD_H #define DUNGEONGAME_REWARD_H #include "PlayableElement.h" class Reward : public PlayableElement{ public: Reward(); private: void toString() override; }; #endif //DUNGEONGAME_REWARD_H
17.5
12
(translation_unit) "#ifndef DUNGEONGAME_REWARD_H\n#define DUNGEONGAME_REWARD_H\n\n\n#include "PlayableElement.h"\n\nclass Reward : public PlayableElement{\npublic:\n Reward();\n\nprivate:\n void toString() override;\n\n};\n\n\n#endif //DUNGEONGAME_REWARD_H\n" (preproc_ifdef) "#ifndef DUNGEONGAME_REWARD_H\n#define DUNGEONGAME_REWARD_H\n\n\n#include "PlayableElement.h"\n\nclass Reward : public PlayableElement{\npublic:\n Reward();\n\nprivate:\n void toString() override;\n\n};\n\n\n#endif" (#ifndef) "#ifndef" (identifier) "DUNGEONGAME_REWARD_H" (preproc_def) "#define DUNGEONGAME_REWARD_H\n" (#define) "#define" (identifier) "DUNGEONGAME_REWARD_H" (preproc_include) "#include "PlayableElement.h"\n" (#include) "#include" (string_literal) ""PlayableElement.h"" (") """ (string_content) "PlayableElement.h" (") """ (function_definition) "class Reward : public PlayableElement{\npublic:\n Reward();\n\nprivate:\n void toString() override;\n\n}" (type_identifier) "class" (ERROR) "Reward : public" (identifier) "Reward" (:) ":" (identifier) "public" (identifier) "PlayableElement" (compound_statement) "{\npublic:\n Reward();\n\nprivate:\n void toString() override;\n\n}" ({) "{" (labeled_statement) "public:\n Reward();" (statement_identifier) "public" (:) ":" (expression_statement) "Reward();" (call_expression) "Reward()" (identifier) "Reward" (argument_list) "()" (() "(" ()) ")" (;) ";" (labeled_statement) "private:\n void toString() override;" (statement_identifier) "private" (:) ":" (ERROR) "void toString() override" (primitive_type) "void" (function_declarator) "toString() override" (identifier) "toString" (parameter_list) "()" (() "(" ()) ")" (identifier) "override" (expression_statement) ";" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (#endif) "#endif" (comment) "//DUNGEONGAME_REWARD_H"
50
2
{"language": "c", "success": true, "metadata": {"lines": 12, "avg_line_length": 17.5, "nodes": 25, "errors": 0, "source_hash": "fede214e99edb3279b34fdd882afddb1fca2fcd9286a235ea3cd7a02f4bd352e", "categorized_nodes": 16}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef DUNGEONGAME_REWARD_H\n#define DUNGEONGAME_REWARD_H\n\n\n#include \"PlayableElement.h\"\n\nclass Reward : public PlayableElement{\npublic:\n Reward();\n\nprivate:\n void toString() override;\n\n};\n\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 24], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 16, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "identifier", "text": "DUNGEONGAME_REWARD_H", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 28}}, {"id": 3, "type": "preproc_def", "text": "#define DUNGEONGAME_REWARD_H\n", "parent": 0, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 5, "type": "identifier", "text": "DUNGEONGAME_REWARD_H", "parent": 3, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 28}}, {"id": 6, "type": "preproc_include", "text": "#include \"PlayableElement.h\"\n", "parent": 0, "children": [7, 8], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"PlayableElement.h\"", "parent": 6, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 28}}, {"id": 9, "type": "function_definition", "text": "class Reward : public PlayableElement{\npublic:\n Reward();\n\nprivate:\n void toString() override;\n\n}", "parent": 0, "children": [10, 12], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 10, "type": "ERROR", "text": "Reward : public", "parent": 9, "children": [11], "start_point": {"row": 6, "column": 6}, "end_point": {"row": 6, "column": 21}}, {"id": 11, "type": "identifier", "text": "Reward", "parent": 10, "children": [], "start_point": {"row": 6, "column": 6}, "end_point": {"row": 6, "column": 12}}, {"id": 12, "type": "identifier", "text": "PlayableElement", "parent": 9, "children": [], "start_point": {"row": 6, "column": 22}, "end_point": {"row": 6, "column": 37}}, {"id": 13, "type": "labeled_statement", "text": "public:\n Reward();", "parent": 9, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 13}}, {"id": 14, "type": "call_expression", "text": "Reward()", "parent": 13, "children": [15, 16], "start_point": {"row": 8, "column": 4}, "end_point": {"row": 8, "column": 12}}, {"id": 15, "type": "identifier", "text": "Reward", "parent": 14, "children": [], "start_point": {"row": 8, "column": 4}, "end_point": {"row": 8, "column": 10}}, {"id": 16, "type": "argument_list", "text": "()", "parent": 14, "children": [], "start_point": {"row": 8, "column": 10}, "end_point": {"row": 8, "column": 12}}, {"id": 17, "type": "labeled_statement", "text": "private:\n void toString() override;", "parent": 9, "children": [18], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 11, "column": 29}}, {"id": 18, "type": "ERROR", "text": "void toString() override", "parent": 17, "children": [19, 20], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 28}}, {"id": 19, "type": "primitive_type", "text": "void", "parent": 18, "children": [], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 8}}, {"id": 20, "type": "function_declarator", "text": "toString() override", "parent": 18, "children": [21, 22, 23], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 28}}, {"id": 21, "type": "identifier", "text": "toString", "parent": 20, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 17}}, {"id": 22, "type": "parameter_list", "text": "()", "parent": 20, "children": [], "start_point": {"row": 11, "column": 17}, "end_point": {"row": 11, "column": 19}}, {"id": 23, "type": "identifier", "text": "override", "parent": 20, "children": [], "start_point": {"row": 11, "column": 20}, "end_point": {"row": 11, "column": 28}}, {"id": 24, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 6}}]}, "node_categories": {"declarations": {"functions": [9, 20], "variables": [], "classes": [], "imports": [6, 7], "modules": [], "enums": []}, "statements": {"expressions": [14], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 11, 12, 15, 21, 23, 24], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [8], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 9, "universal_type": "function", "name": "Reward", "text_snippet": "class Reward : public PlayableElement{\npublic:\n Reward();\n\nprivate:\n void toString() override;"}, {"node_id": 20, "universal_type": "function", "name": "unknown", "text_snippet": "toString() override"}], "class_declarations": [], "import_statements": [{"node_id": 6, "text": "#include \"PlayableElement.h\"\n"}, {"node_id": 7, "text": "#include"}]}, "original_source_code": "#ifndef DUNGEONGAME_REWARD_H\n#define DUNGEONGAME_REWARD_H\n\n\n#include \"PlayableElement.h\"\n\nclass Reward : public PlayableElement{\npublic:\n Reward();\n\nprivate:\n void toString() override;\n\n};\n\n\n#endif //DUNGEONGAME_REWARD_H\n"}
80,543
c
#pragma once #include "node_editor/Node.h" #include "node_editor/Connection.h" namespace QtNodes { class DataModelRegistry; class FlowScene; class NodeDataModel; /// Class performs various operations on the Node and Connection pair. /// An instance should be created on the stack and destroyed when /// the operation is completed class NodeConnectionInteraction { public: NodeConnectionInteraction(Node& node, Connection& connection, FlowScene& scene); /// Can connect when following conditions are met: /// 1) Connection 'requires' a port /// 2) Connection's vacant end is above the node port /// 3) Node port is vacant /// 4) Connection type equals node port type, or there is a registered type conversion that can translate between the two bool canConnect(PortIndex& portIndex, TypeConverter& converter) const; /// 1) Check conditions from 'canConnect' /// 1.5) If the connection is possible but a type conversion is needed, add a converter node to the scene, and connect it properly /// 2) Assign node to required port in Connection /// 3) Assign Connection to empty port in NodeState /// 4) Adjust Connection geometry /// 5) Poke model to initiate data transfer bool tryConnect() const; /// 1) Node and Connection should be already connected /// 2) If so, clear Connection entry in the NodeState /// 3) Propagate invalid data to IN node /// 4) Set Connection end to 'requiring a port' bool disconnect(PortType portToDisconnect) const; private: PortType connectionRequiredPort() const; QPointF connectionEndScenePosition(PortType) const; QPointF nodePortScenePosition(PortType portType, PortIndex portIndex) const; PortIndex nodePortIndexUnderScenePoint(PortType portType, QPointF const& p) const; bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const; private: Node* _node; Connection* _connection; FlowScene* _scene; }; }
40.96
49
(translation_unit) "#pragma once\n\n#include "node_editor/Node.h"\n#include "node_editor/Connection.h"\n\nnamespace QtNodes {\n\nclass DataModelRegistry;\nclass FlowScene;\nclass NodeDataModel;\n\n/// Class performs various operations on the Node and Connection pair.\n/// An instance should be created on the stack and destroyed when\n/// the operation is completed\nclass NodeConnectionInteraction {\n public:\n NodeConnectionInteraction(Node& node,\n Connection& connection,\n FlowScene& scene);\n\n /// Can connect when following conditions are met:\n /// 1) Connection 'requires' a port\n /// 2) Connection's vacant end is above the node port\n /// 3) Node port is vacant\n /// 4) Connection type equals node port type, or there is a registered type conversion that can translate between the two\n bool canConnect(PortIndex& portIndex,\n TypeConverter& converter) const;\n\n /// 1) Check conditions from 'canConnect'\n /// 1.5) If the connection is possible but a type conversion is needed, add a converter node to the scene, and connect it properly\n /// 2) Assign node to required port in Connection\n /// 3) Assign Connection to empty port in NodeState\n /// 4) Adjust Connection geometry\n /// 5) Poke model to initiate data transfer\n bool tryConnect() const;\n\n\n /// 1) Node and Connection should be already connected\n /// 2) If so, clear Connection entry in the NodeState\n /// 3) Propagate invalid data to IN node\n /// 4) Set Connection end to 'requiring a port'\n bool disconnect(PortType portToDisconnect) const;\n\n private:\n\n PortType connectionRequiredPort() const;\n\n QPointF connectionEndScenePosition(PortType) const;\n\n QPointF nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node* _node;\n\n Connection* _connection;\n\n FlowScene* _scene;\n};\n}\n" (preproc_call) "#pragma once\n" (preproc_directive) "#pragma" (preproc_arg) "once" (preproc_include) "#include "node_editor/Node.h"\n" (#include) "#include" (string_literal) ""node_editor/Node.h"" (") """ (string_content) "node_editor/Node.h" (") """ (preproc_include) "#include "node_editor/Connection.h"\n" (#include) "#include" (string_literal) ""node_editor/Connection.h"" (") """ (string_content) "node_editor/Connection.h" (") """ (function_definition) "namespace QtNodes {\n\nclass DataModelRegistry;\nclass FlowScene;\nclass NodeDataModel;\n\n/// Class performs various operations on the Node and Connection pair.\n/// An instance should be created on the stack and destroyed when\n/// the operation is completed\nclass NodeConnectionInteraction {\n public:\n NodeConnectionInteraction(Node& node,\n Connection& connection,\n FlowScene& scene);\n\n /// Can connect when following conditions are met:\n /// 1) Connection 'requires' a port\n /// 2) Connection's vacant end is above the node port\n /// 3) Node port is vacant\n /// 4) Connection type equals node port type, or there is a registered type conversion that can translate between the two\n bool canConnect(PortIndex& portIndex,\n TypeConverter& converter) const;\n\n /// 1) Check conditions from 'canConnect'\n /// 1.5) If the connection is possible but a type conversion is needed, add a converter node to the scene, and connect it properly\n /// 2) Assign node to required port in Connection\n /// 3) Assign Connection to empty port in NodeState\n /// 4) Adjust Connection geometry\n /// 5) Poke model to initiate data transfer\n bool tryConnect() const;\n\n\n /// 1) Node and Connection should be already connected\n /// 2) If so, clear Connection entry in the NodeState\n /// 3) Propagate invalid data to IN node\n /// 4) Set Connection end to 'requiring a port'\n bool disconnect(PortType portToDisconnect) const;\n\n private:\n\n PortType connectionRequiredPort() const;\n\n QPointF connectionEndScenePosition(PortType) const;\n\n QPointF nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node* _node;\n\n Connection* _connection;\n\n FlowScene* _scene;\n};\n}" (type_identifier) "namespace" (identifier) "QtNodes" (compound_statement) "{\n\nclass DataModelRegistry;\nclass FlowScene;\nclass NodeDataModel;\n\n/// Class performs various operations on the Node and Connection pair.\n/// An instance should be created on the stack and destroyed when\n/// the operation is completed\nclass NodeConnectionInteraction {\n public:\n NodeConnectionInteraction(Node& node,\n Connection& connection,\n FlowScene& scene);\n\n /// Can connect when following conditions are met:\n /// 1) Connection 'requires' a port\n /// 2) Connection's vacant end is above the node port\n /// 3) Node port is vacant\n /// 4) Connection type equals node port type, or there is a registered type conversion that can translate between the two\n bool canConnect(PortIndex& portIndex,\n TypeConverter& converter) const;\n\n /// 1) Check conditions from 'canConnect'\n /// 1.5) If the connection is possible but a type conversion is needed, add a converter node to the scene, and connect it properly\n /// 2) Assign node to required port in Connection\n /// 3) Assign Connection to empty port in NodeState\n /// 4) Adjust Connection geometry\n /// 5) Poke model to initiate data transfer\n bool tryConnect() const;\n\n\n /// 1) Node and Connection should be already connected\n /// 2) If so, clear Connection entry in the NodeState\n /// 3) Propagate invalid data to IN node\n /// 4) Set Connection end to 'requiring a port'\n bool disconnect(PortType portToDisconnect) const;\n\n private:\n\n PortType connectionRequiredPort() const;\n\n QPointF connectionEndScenePosition(PortType) const;\n\n QPointF nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node* _node;\n\n Connection* _connection;\n\n FlowScene* _scene;\n};\n}" ({) "{" (declaration) "class DataModelRegistry;" (type_identifier) "class" (identifier) "DataModelRegistry" (;) ";" (declaration) "class FlowScene;" (type_identifier) "class" (identifier) "FlowScene" (;) ";" (declaration) "class NodeDataModel;" (type_identifier) "class" (identifier) "NodeDataModel" (;) ";" (comment) "/// Class performs various operations on the Node and Connection pair." (comment) "/// An instance should be created on the stack and destroyed when" (comment) "/// the operation is completed" (function_definition) "class NodeConnectionInteraction {\n public:\n NodeConnectionInteraction(Node& node,\n Connection& connection,\n FlowScene& scene);\n\n /// Can connect when following conditions are met:\n /// 1) Connection 'requires' a port\n /// 2) Connection's vacant end is above the node port\n /// 3) Node port is vacant\n /// 4) Connection type equals node port type, or there is a registered type conversion that can translate between the two\n bool canConnect(PortIndex& portIndex,\n TypeConverter& converter) const;\n\n /// 1) Check conditions from 'canConnect'\n /// 1.5) If the connection is possible but a type conversion is needed, add a converter node to the scene, and connect it properly\n /// 2) Assign node to required port in Connection\n /// 3) Assign Connection to empty port in NodeState\n /// 4) Adjust Connection geometry\n /// 5) Poke model to initiate data transfer\n bool tryConnect() const;\n\n\n /// 1) Node and Connection should be already connected\n /// 2) If so, clear Connection entry in the NodeState\n /// 3) Propagate invalid data to IN node\n /// 4) Set Connection end to 'requiring a port'\n bool disconnect(PortType portToDisconnect) const;\n\n private:\n\n PortType connectionRequiredPort() const;\n\n QPointF connectionEndScenePosition(PortType) const;\n\n QPointF nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node* _node;\n\n Connection* _connection;\n\n FlowScene* _scene;\n}" (type_identifier) "class" (identifier) "NodeConnectionInteraction" (compound_statement) "{\n public:\n NodeConnectionInteraction(Node& node,\n Connection& connection,\n FlowScene& scene);\n\n /// Can connect when following conditions are met:\n /// 1) Connection 'requires' a port\n /// 2) Connection's vacant end is above the node port\n /// 3) Node port is vacant\n /// 4) Connection type equals node port type, or there is a registered type conversion that can translate between the two\n bool canConnect(PortIndex& portIndex,\n TypeConverter& converter) const;\n\n /// 1) Check conditions from 'canConnect'\n /// 1.5) If the connection is possible but a type conversion is needed, add a converter node to the scene, and connect it properly\n /// 2) Assign node to required port in Connection\n /// 3) Assign Connection to empty port in NodeState\n /// 4) Adjust Connection geometry\n /// 5) Poke model to initiate data transfer\n bool tryConnect() const;\n\n\n /// 1) Node and Connection should be already connected\n /// 2) If so, clear Connection entry in the NodeState\n /// 3) Propagate invalid data to IN node\n /// 4) Set Connection end to 'requiring a port'\n bool disconnect(PortType portToDisconnect) const;\n\n private:\n\n PortType connectionRequiredPort() const;\n\n QPointF connectionEndScenePosition(PortType) const;\n\n QPointF nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node* _node;\n\n Connection* _connection;\n\n FlowScene* _scene;\n}" ({) "{" (labeled_statement) "public:\n NodeConnectionInteraction(Node& node,\n Connection& connection,\n FlowScene& scene);" (statement_identifier) "public" (:) ":" (expression_statement) "NodeConnectionInteraction(Node& node,\n Connection& connection,\n FlowScene& scene);" (call_expression) "NodeConnectionInteraction(Node& node,\n Connection& connection,\n FlowScene& scene)" (identifier) "NodeConnectionInteraction" (argument_list) "(Node& node,\n Connection& connection,\n FlowScene& scene)" (() "(" (binary_expression) "Node& node" (identifier) "Node" (&) "&" (identifier) "node" (,) "," (binary_expression) "Connection& connection" (identifier) "Connection" (&) "&" (identifier) "connection" (,) "," (binary_expression) "FlowScene& scene" (identifier) "FlowScene" (&) "&" (identifier) "scene" ()) ")" (;) ";" (comment) "/// Can connect when following conditions are met:" (comment) "/// 1) Connection 'requires' a port" (comment) "/// 2) Connection's vacant end is above the node port" (comment) "/// 3) Node port is vacant" (comment) "/// 4) Connection type equals node port type, or there is a registered type conversion that can translate between the two" (ERROR) "bool canConnect(PortIndex& portIndex,\n TypeConverter& converter) const" (primitive_type) "bool" (function_declarator) "canConnect(PortIndex& portIndex,\n TypeConverter& converter) const" (identifier) "canConnect" (parameter_list) "(PortIndex& portIndex,\n TypeConverter& converter)" (() "(" (parameter_declaration) "PortIndex& portIndex" (type_identifier) "PortIndex" (ERROR) "&" (&) "&" (identifier) "portIndex" (,) "," (parameter_declaration) "TypeConverter& converter" (type_identifier) "TypeConverter" (ERROR) "&" (&) "&" (identifier) "converter" ()) ")" (identifier) "const" (expression_statement) ";" (;) ";" (comment) "/// 1) Check conditions from 'canConnect'" (comment) "/// 1.5) If the connection is possible but a type conversion is needed, add a converter node to the scene, and connect it properly" (comment) "/// 2) Assign node to required port in Connection" (comment) "/// 3) Assign Connection to empty port in NodeState" (comment) "/// 4) Adjust Connection geometry" (comment) "/// 5) Poke model to initiate data transfer" (ERROR) "bool tryConnect() const" (primitive_type) "bool" (function_declarator) "tryConnect()" (identifier) "tryConnect" (parameter_list) "()" (() "(" ()) ")" (type_qualifier) "const" (const) "const" (expression_statement) ";" (;) ";" (comment) "/// 1) Node and Connection should be already connected" (comment) "/// 2) If so, clear Connection entry in the NodeState" (comment) "/// 3) Propagate invalid data to IN node" (comment) "/// 4) Set Connection end to 'requiring a port'" (ERROR) "bool disconnect(PortType portToDisconnect) const" (primitive_type) "bool" (function_declarator) "disconnect(PortType portToDisconnect) const" (identifier) "disconnect" (parameter_list) "(PortType portToDisconnect)" (() "(" (parameter_declaration) "PortType portToDisconnect" (type_identifier) "PortType" (identifier) "portToDisconnect" ()) ")" (identifier) "const" (expression_statement) ";" (;) ";" (labeled_statement) "private:\n\n PortType connectionRequiredPort() const;" (statement_identifier) "private" (:) ":" (ERROR) "PortType connectionRequiredPort() const" (type_identifier) "PortType" (function_declarator) "connectionRequiredPort() const" (identifier) "connectionRequiredPort" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (expression_statement) ";" (;) ";" (ERROR) "QPointF connectionEndScenePosition(PortType) const;\n\n QPointF nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node* _node;\n\n Connection* _connection;\n\n FlowScene* _scene;" (type_identifier) "QPointF" (function_declarator) "connectionEndScenePosition(PortType)" (identifier) "connectionEndScenePosition" (parameter_list) "(PortType)" (() "(" (identifier) "PortType" ()) ")" (declaration) "const;\n\n QPointF nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node* _node;" (type_qualifier) "const" (const) "const" (ERROR) ";" (;) ";" (type_identifier) "QPointF" (ERROR) "nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node" (function_declarator) "nodePortScenePosition(PortType portType,\n PortIndex portIndex) const" (identifier) "nodePortScenePosition" (parameter_list) "(PortType portType,\n PortIndex portIndex)" (() "(" (parameter_declaration) "PortType portType" (type_identifier) "PortType" (identifier) "portType" (,) "," (parameter_declaration) "PortIndex portIndex" (type_identifier) "PortIndex" (identifier) "portIndex" ()) ")" (identifier) "const" (;) ";" (identifier) "PortIndex" (function_declarator) "nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const" (identifier) "nodePortIndexUnderScenePoint" (parameter_list) "(PortType portType,\n QPointF const& p)" (() "(" (parameter_declaration) "PortType portType" (type_identifier) "PortType" (identifier) "portType" (,) "," (parameter_declaration) "QPointF const& p" (type_identifier) "QPointF" (type_qualifier) "const" (const) "const" (ERROR) "&" (&) "&" (identifier) "p" ()) ")" (identifier) "const" (;) ";" (primitive_type) "bool" (function_declarator) "nodePortIsEmpty(PortType portType, PortIndex portIndex) const" (identifier) "nodePortIsEmpty" (parameter_list) "(PortType portType, PortIndex portIndex)" (() "(" (parameter_declaration) "PortType portType" (type_identifier) "PortType" (identifier) "portType" (,) "," (parameter_declaration) "PortIndex portIndex" (type_identifier) "PortIndex" (identifier) "portIndex" ()) ")" (identifier) "const" (;) ";" (identifier) "private" (:) ":" (identifier) "Node" (pointer_declarator) "* _node" (*) "*" (identifier) "_node" (;) ";" (declaration) "Connection* _connection;" (type_identifier) "Connection" (pointer_declarator) "* _connection" (*) "*" (identifier) "_connection" (;) ";" (declaration) "FlowScene* _scene;" (type_identifier) "FlowScene" (pointer_declarator) "* _scene" (*) "*" (identifier) "_scene" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (}) "}"
224
10
{"language": "c", "success": true, "metadata": {"lines": 49, "avg_line_length": 40.96, "nodes": 115, "errors": 0, "source_hash": "49ab7b262eb11427b37043d75a2457a3592a5c169e6eb5e7233654fb2a4dc9b3", "categorized_nodes": 86}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#pragma once\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#pragma", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "once", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 12}}, {"id": 3, "type": "preproc_include", "text": "#include \"node_editor/Node.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 5, "type": "string_literal", "text": "\"node_editor/Node.h\"", "parent": 3, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 29}}, {"id": 6, "type": "preproc_include", "text": "#include \"node_editor/Connection.h\"\n", "parent": null, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"node_editor/Connection.h\"", "parent": 6, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 35}}, {"id": 9, "type": "function_definition", "text": "namespace QtNodes {\n\nclass DataModelRegistry;\nclass FlowScene;\nclass NodeDataModel;\n\n/// Class performs various operations on the Node and Connection pair.\n/// An instance should be created on the stack and destroyed when\n/// the operation is completed\nclass NodeConnectionInteraction {\n public:\n NodeConnectionInteraction(Node& node,\n Connection& connection,\n FlowScene& scene);\n\n /// Can connect when following conditions are met:\n /// 1) Connection 'requires' a port\n /// 2) Connection's vacant end is above the node port\n /// 3) Node port is vacant\n /// 4) Connection type equals node port type, or there is a registered type conversion that can translate between the two\n bool canConnect(PortIndex& portIndex,\n TypeConverter& converter) const;\n\n /// 1) Check conditions from 'canConnect'\n /// 1.5) If the connection is possible but a type conversion is needed, add a converter node to the scene, and connect it properly\n /// 2) Assign node to required port in Connection\n /// 3) Assign Connection to empty port in NodeState\n /// 4) Adjust Connection geometry\n /// 5) Poke model to initiate data transfer\n bool tryConnect() const;\n\n\n /// 1) Node and Connection should be already connected\n /// 2) If so, clear Connection entry in the NodeState\n /// 3) Propagate invalid data to IN node\n /// 4) Set Connection end to 'requiring a port'\n bool disconnect(PortType portToDisconnect) const;\n\n private:\n\n PortType connectionRequiredPort() const;\n\n QPointF connectionEndScenePosition(PortType) const;\n\n QPointF nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node* _node;\n\n Connection* _connection;\n\n FlowScene* _scene;\n};\n}", "parent": null, "children": [10, 11], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 65, "column": 1}}, {"id": 10, "type": "type_identifier", "text": "namespace", "parent": 9, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 9}}, {"id": 11, "type": "identifier", "text": "QtNodes", "parent": 9, "children": [], "start_point": {"row": 5, "column": 10}, "end_point": {"row": 5, "column": 17}}, {"id": 12, "type": "declaration", "text": "class DataModelRegistry;", "parent": 9, "children": [13], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 24}}, {"id": 13, "type": "identifier", "text": "DataModelRegistry", "parent": 12, "children": [], "start_point": {"row": 7, "column": 6}, "end_point": {"row": 7, "column": 23}}, {"id": 14, "type": "declaration", "text": "class FlowScene;", "parent": 9, "children": [15], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 16}}, {"id": 15, "type": "identifier", "text": "FlowScene", "parent": 14, "children": [], "start_point": {"row": 8, "column": 6}, "end_point": {"row": 8, "column": 15}}, {"id": 16, "type": "declaration", "text": "class NodeDataModel;", "parent": 9, "children": [17], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 20}}, {"id": 17, "type": "identifier", "text": "NodeDataModel", "parent": 16, "children": [], "start_point": {"row": 9, "column": 6}, "end_point": {"row": 9, "column": 19}}, {"id": 18, "type": "function_definition", "text": "class NodeConnectionInteraction {\n public:\n NodeConnectionInteraction(Node& node,\n Connection& connection,\n FlowScene& scene);\n\n /// Can connect when following conditions are met:\n /// 1) Connection 'requires' a port\n /// 2) Connection's vacant end is above the node port\n /// 3) Node port is vacant\n /// 4) Connection type equals node port type, or there is a registered type conversion that can translate between the two\n bool canConnect(PortIndex& portIndex,\n TypeConverter& converter) const;\n\n /// 1) Check conditions from 'canConnect'\n /// 1.5) If the connection is possible but a type conversion is needed, add a converter node to the scene, and connect it properly\n /// 2) Assign node to required port in Connection\n /// 3) Assign Connection to empty port in NodeState\n /// 4) Adjust Connection geometry\n /// 5) Poke model to initiate data transfer\n bool tryConnect() const;\n\n\n /// 1) Node and Connection should be already connected\n /// 2) If so, clear Connection entry in the NodeState\n /// 3) Propagate invalid data to IN node\n /// 4) Set Connection end to 'requiring a port'\n bool disconnect(PortType portToDisconnect) const;\n\n private:\n\n PortType connectionRequiredPort() const;\n\n QPointF connectionEndScenePosition(PortType) const;\n\n QPointF nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node* _node;\n\n Connection* _connection;\n\n FlowScene* _scene;\n}", "parent": 9, "children": [19], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 64, "column": 1}}, {"id": 19, "type": "identifier", "text": "NodeConnectionInteraction", "parent": 18, "children": [], "start_point": {"row": 14, "column": 6}, "end_point": {"row": 14, "column": 31}}, {"id": 20, "type": "labeled_statement", "text": "public:\n NodeConnectionInteraction(Node& node,\n Connection& connection,\n FlowScene& scene);", "parent": 18, "children": [], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 18, "column": 46}}, {"id": 21, "type": "call_expression", "text": "NodeConnectionInteraction(Node& node,\n Connection& connection,\n FlowScene& scene)", "parent": 20, "children": [22, 23], "start_point": {"row": 16, "column": 2}, "end_point": {"row": 18, "column": 45}}, {"id": 22, "type": "identifier", "text": "NodeConnectionInteraction", "parent": 21, "children": [], "start_point": {"row": 16, "column": 2}, "end_point": {"row": 16, "column": 27}}, {"id": 23, "type": "argument_list", "text": "(Node& node,\n Connection& connection,\n FlowScene& scene)", "parent": 21, "children": [24, 27, 30], "start_point": {"row": 16, "column": 27}, "end_point": {"row": 18, "column": 45}}, {"id": 24, "type": "binary_expression", "text": "Node& node", "parent": 23, "children": [25, 26], "start_point": {"row": 16, "column": 28}, "end_point": {"row": 16, "column": 38}}, {"id": 25, "type": "identifier", "text": "Node", "parent": 24, "children": [], "start_point": {"row": 16, "column": 28}, "end_point": {"row": 16, "column": 32}}, {"id": 26, "type": "identifier", "text": "node", "parent": 24, "children": [], "start_point": {"row": 16, "column": 34}, "end_point": {"row": 16, "column": 38}}, {"id": 27, "type": "binary_expression", "text": "Connection& connection", "parent": 23, "children": [28, 29], "start_point": {"row": 17, "column": 28}, "end_point": {"row": 17, "column": 50}}, {"id": 28, "type": "identifier", "text": "Connection", "parent": 27, "children": [], "start_point": {"row": 17, "column": 28}, "end_point": {"row": 17, "column": 38}}, {"id": 29, "type": "identifier", "text": "connection", "parent": 27, "children": [], "start_point": {"row": 17, "column": 40}, "end_point": {"row": 17, "column": 50}}, {"id": 30, "type": "binary_expression", "text": "FlowScene& scene", "parent": 23, "children": [31, 32], "start_point": {"row": 18, "column": 28}, "end_point": {"row": 18, "column": 44}}, {"id": 31, "type": "identifier", "text": "FlowScene", "parent": 30, "children": [], "start_point": {"row": 18, "column": 28}, "end_point": {"row": 18, "column": 37}}, {"id": 32, "type": "identifier", "text": "scene", "parent": 30, "children": [], "start_point": {"row": 18, "column": 39}, "end_point": {"row": 18, "column": 44}}, {"id": 33, "type": "ERROR", "text": "bool canConnect(PortIndex& portIndex,\n TypeConverter& converter) const", "parent": 18, "children": [34, 35], "start_point": {"row": 25, "column": 2}, "end_point": {"row": 26, "column": 49}}, {"id": 34, "type": "primitive_type", "text": "bool", "parent": 33, "children": [], "start_point": {"row": 25, "column": 2}, "end_point": {"row": 25, "column": 6}}, {"id": 35, "type": "function_declarator", "text": "canConnect(PortIndex& portIndex,\n TypeConverter& converter) const", "parent": 33, "children": [36, 37], "start_point": {"row": 25, "column": 7}, "end_point": {"row": 26, "column": 49}}, {"id": 36, "type": "identifier", "text": "canConnect", "parent": 35, "children": [], "start_point": {"row": 25, "column": 7}, "end_point": {"row": 25, "column": 17}}, {"id": 37, "type": "parameter_list", "text": "(PortIndex& portIndex,\n TypeConverter& converter)", "parent": 35, "children": [38, 41], "start_point": {"row": 25, "column": 17}, "end_point": {"row": 26, "column": 43}}, {"id": 38, "type": "parameter_declaration", "text": "PortIndex& portIndex", "parent": 37, "children": [39, 40], "start_point": {"row": 25, "column": 18}, "end_point": {"row": 25, "column": 38}}, {"id": 39, "type": "type_identifier", "text": "PortIndex", "parent": 38, "children": [], "start_point": {"row": 25, "column": 18}, "end_point": {"row": 25, "column": 27}}, {"id": 40, "type": "identifier", "text": "portIndex", "parent": 38, "children": [], "start_point": {"row": 25, "column": 29}, "end_point": {"row": 25, "column": 38}}, {"id": 41, "type": "parameter_declaration", "text": "TypeConverter& converter", "parent": 37, "children": [42, 43], "start_point": {"row": 26, "column": 18}, "end_point": {"row": 26, "column": 42}}, {"id": 42, "type": "type_identifier", "text": "TypeConverter", "parent": 41, "children": [], "start_point": {"row": 26, "column": 18}, "end_point": {"row": 26, "column": 31}}, {"id": 43, "type": "identifier", "text": "converter", "parent": 41, "children": [], "start_point": {"row": 26, "column": 33}, "end_point": {"row": 26, "column": 42}}, {"id": 44, "type": "ERROR", "text": "bool tryConnect() const", "parent": 18, "children": [45, 46], "start_point": {"row": 34, "column": 2}, "end_point": {"row": 34, "column": 25}}, {"id": 45, "type": "primitive_type", "text": "bool", "parent": 44, "children": [], "start_point": {"row": 34, "column": 2}, "end_point": {"row": 34, "column": 6}}, {"id": 46, "type": "function_declarator", "text": "tryConnect()", "parent": 44, "children": [47, 48], "start_point": {"row": 34, "column": 7}, "end_point": {"row": 34, "column": 19}}, {"id": 47, "type": "identifier", "text": "tryConnect", "parent": 46, "children": [], "start_point": {"row": 34, "column": 7}, "end_point": {"row": 34, "column": 17}}, {"id": 48, "type": "parameter_list", "text": "()", "parent": 46, "children": [], "start_point": {"row": 34, "column": 17}, "end_point": {"row": 34, "column": 19}}, {"id": 49, "type": "ERROR", "text": "bool disconnect(PortType portToDisconnect) const", "parent": 18, "children": [50, 51], "start_point": {"row": 41, "column": 2}, "end_point": {"row": 41, "column": 50}}, {"id": 50, "type": "primitive_type", "text": "bool", "parent": 49, "children": [], "start_point": {"row": 41, "column": 2}, "end_point": {"row": 41, "column": 6}}, {"id": 51, "type": "function_declarator", "text": "disconnect(PortType portToDisconnect) const", "parent": 49, "children": [52, 53], "start_point": {"row": 41, "column": 7}, "end_point": {"row": 41, "column": 50}}, {"id": 52, "type": "identifier", "text": "disconnect", "parent": 51, "children": [], "start_point": {"row": 41, "column": 7}, "end_point": {"row": 41, "column": 17}}, {"id": 53, "type": "parameter_list", "text": "(PortType portToDisconnect)", "parent": 51, "children": [54], "start_point": {"row": 41, "column": 17}, "end_point": {"row": 41, "column": 44}}, {"id": 54, "type": "parameter_declaration", "text": "PortType portToDisconnect", "parent": 53, "children": [55, 56], "start_point": {"row": 41, "column": 18}, "end_point": {"row": 41, "column": 43}}, {"id": 55, "type": "type_identifier", "text": "PortType", "parent": 54, "children": [], "start_point": {"row": 41, "column": 18}, "end_point": {"row": 41, "column": 26}}, {"id": 56, "type": "identifier", "text": "portToDisconnect", "parent": 54, "children": [], "start_point": {"row": 41, "column": 27}, "end_point": {"row": 41, "column": 43}}, {"id": 57, "type": "labeled_statement", "text": "private:\n\n PortType connectionRequiredPort() const;", "parent": 18, "children": [58], "start_point": {"row": 43, "column": 1}, "end_point": {"row": 45, "column": 42}}, {"id": 58, "type": "ERROR", "text": "PortType connectionRequiredPort() const", "parent": 57, "children": [59, 60], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 41}}, {"id": 59, "type": "type_identifier", "text": "PortType", "parent": 58, "children": [], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 10}}, {"id": 60, "type": "function_declarator", "text": "connectionRequiredPort() const", "parent": 58, "children": [61, 62], "start_point": {"row": 45, "column": 11}, "end_point": {"row": 45, "column": 41}}, {"id": 61, "type": "identifier", "text": "connectionRequiredPort", "parent": 60, "children": [], "start_point": {"row": 45, "column": 11}, "end_point": {"row": 45, "column": 33}}, {"id": 62, "type": "parameter_list", "text": "()", "parent": 60, "children": [], "start_point": {"row": 45, "column": 33}, "end_point": {"row": 45, "column": 35}}, {"id": 63, "type": "ERROR", "text": "QPointF connectionEndScenePosition(PortType) const;\n\n QPointF nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node* _node;\n\n Connection* _connection;\n\n FlowScene* _scene;", "parent": 18, "children": [64, 65, 69, 105, 110], "start_point": {"row": 47, "column": 2}, "end_point": {"row": 63, "column": 20}}, {"id": 64, "type": "type_identifier", "text": "QPointF", "parent": 63, "children": [], "start_point": {"row": 47, "column": 2}, "end_point": {"row": 47, "column": 9}}, {"id": 65, "type": "function_declarator", "text": "connectionEndScenePosition(PortType)", "parent": 63, "children": [66, 67], "start_point": {"row": 47, "column": 10}, "end_point": {"row": 47, "column": 46}}, {"id": 66, "type": "identifier", "text": "connectionEndScenePosition", "parent": 65, "children": [], "start_point": {"row": 47, "column": 10}, "end_point": {"row": 47, "column": 36}}, {"id": 67, "type": "parameter_list", "text": "(PortType)", "parent": 65, "children": [68], "start_point": {"row": 47, "column": 36}, "end_point": {"row": 47, "column": 46}}, {"id": 68, "type": "identifier", "text": "PortType", "parent": 67, "children": [], "start_point": {"row": 47, "column": 37}, "end_point": {"row": 47, "column": 45}}, {"id": 69, "type": "declaration", "text": "const;\n\n QPointF nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node* _node;", "parent": 63, "children": [70, 71, 102], "start_point": {"row": 47, "column": 47}, "end_point": {"row": 59, "column": 14}}, {"id": 70, "type": "type_identifier", "text": "QPointF", "parent": 69, "children": [], "start_point": {"row": 49, "column": 2}, "end_point": {"row": 49, "column": 9}}, {"id": 71, "type": "ERROR", "text": "nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node", "parent": 69, "children": [72, 81, 82, 91, 92, 101], "start_point": {"row": 49, "column": 10}, "end_point": {"row": 59, "column": 6}}, {"id": 72, "type": "function_declarator", "text": "nodePortScenePosition(PortType portType,\n PortIndex portIndex) const", "parent": 71, "children": [73, 74], "start_point": {"row": 49, "column": 10}, "end_point": {"row": 50, "column": 58}}, {"id": 73, "type": "identifier", "text": "nodePortScenePosition", "parent": 72, "children": [], "start_point": {"row": 49, "column": 10}, "end_point": {"row": 49, "column": 31}}, {"id": 74, "type": "parameter_list", "text": "(PortType portType,\n PortIndex portIndex)", "parent": 72, "children": [75, 78], "start_point": {"row": 49, "column": 31}, "end_point": {"row": 50, "column": 52}}, {"id": 75, "type": "parameter_declaration", "text": "PortType portType", "parent": 74, "children": [76, 77], "start_point": {"row": 49, "column": 32}, "end_point": {"row": 49, "column": 49}}, {"id": 76, "type": "type_identifier", "text": "PortType", "parent": 75, "children": [], "start_point": {"row": 49, "column": 32}, "end_point": {"row": 49, "column": 40}}, {"id": 77, "type": "identifier", "text": "portType", "parent": 75, "children": [], "start_point": {"row": 49, "column": 41}, "end_point": {"row": 49, "column": 49}}, {"id": 78, "type": "parameter_declaration", "text": "PortIndex portIndex", "parent": 74, "children": [79, 80], "start_point": {"row": 50, "column": 32}, "end_point": {"row": 50, "column": 51}}, {"id": 79, "type": "type_identifier", "text": "PortIndex", "parent": 78, "children": [], "start_point": {"row": 50, "column": 32}, "end_point": {"row": 50, "column": 41}}, {"id": 80, "type": "identifier", "text": "portIndex", "parent": 78, "children": [], "start_point": {"row": 50, "column": 42}, "end_point": {"row": 50, "column": 51}}, {"id": 81, "type": "identifier", "text": "PortIndex", "parent": 71, "children": [], "start_point": {"row": 52, "column": 2}, "end_point": {"row": 52, "column": 11}}, {"id": 82, "type": "function_declarator", "text": "nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const", "parent": 71, "children": [83, 84], "start_point": {"row": 52, "column": 12}, "end_point": {"row": 53, "column": 64}}, {"id": 83, "type": "identifier", "text": "nodePortIndexUnderScenePoint", "parent": 82, "children": [], "start_point": {"row": 52, "column": 12}, "end_point": {"row": 52, "column": 40}}, {"id": 84, "type": "parameter_list", "text": "(PortType portType,\n QPointF const& p)", "parent": 82, "children": [85, 88], "start_point": {"row": 52, "column": 40}, "end_point": {"row": 53, "column": 58}}, {"id": 85, "type": "parameter_declaration", "text": "PortType portType", "parent": 84, "children": [86, 87], "start_point": {"row": 52, "column": 41}, "end_point": {"row": 52, "column": 58}}, {"id": 86, "type": "type_identifier", "text": "PortType", "parent": 85, "children": [], "start_point": {"row": 52, "column": 41}, "end_point": {"row": 52, "column": 49}}, {"id": 87, "type": "identifier", "text": "portType", "parent": 85, "children": [], "start_point": {"row": 52, "column": 50}, "end_point": {"row": 52, "column": 58}}, {"id": 88, "type": "parameter_declaration", "text": "QPointF const& p", "parent": 84, "children": [89, 90], "start_point": {"row": 53, "column": 41}, "end_point": {"row": 53, "column": 57}}, {"id": 89, "type": "type_identifier", "text": "QPointF", "parent": 88, "children": [], "start_point": {"row": 53, "column": 41}, "end_point": {"row": 53, "column": 48}}, {"id": 90, "type": "identifier", "text": "p", "parent": 88, "children": [], "start_point": {"row": 53, "column": 56}, "end_point": {"row": 53, "column": 57}}, {"id": 91, "type": "primitive_type", "text": "bool", "parent": 71, "children": [], "start_point": {"row": 55, "column": 2}, "end_point": {"row": 55, "column": 6}}, {"id": 92, "type": "function_declarator", "text": "nodePortIsEmpty(PortType portType, PortIndex portIndex) const", "parent": 71, "children": [93, 94], "start_point": {"row": 55, "column": 7}, "end_point": {"row": 55, "column": 68}}, {"id": 93, "type": "identifier", "text": "nodePortIsEmpty", "parent": 92, "children": [], "start_point": {"row": 55, "column": 7}, "end_point": {"row": 55, "column": 22}}, {"id": 94, "type": "parameter_list", "text": "(PortType portType, PortIndex portIndex)", "parent": 92, "children": [95, 98], "start_point": {"row": 55, "column": 22}, "end_point": {"row": 55, "column": 62}}, {"id": 95, "type": "parameter_declaration", "text": "PortType portType", "parent": 94, "children": [96, 97], "start_point": {"row": 55, "column": 23}, "end_point": {"row": 55, "column": 40}}, {"id": 96, "type": "type_identifier", "text": "PortType", "parent": 95, "children": [], "start_point": {"row": 55, "column": 23}, "end_point": {"row": 55, "column": 31}}, {"id": 97, "type": "identifier", "text": "portType", "parent": 95, "children": [], "start_point": {"row": 55, "column": 32}, "end_point": {"row": 55, "column": 40}}, {"id": 98, "type": "parameter_declaration", "text": "PortIndex portIndex", "parent": 94, "children": [99, 100], "start_point": {"row": 55, "column": 42}, "end_point": {"row": 55, "column": 61}}, {"id": 99, "type": "type_identifier", "text": "PortIndex", "parent": 98, "children": [], "start_point": {"row": 55, "column": 42}, "end_point": {"row": 55, "column": 51}}, {"id": 100, "type": "identifier", "text": "portIndex", "parent": 98, "children": [], "start_point": {"row": 55, "column": 52}, "end_point": {"row": 55, "column": 61}}, {"id": 101, "type": "identifier", "text": "Node", "parent": 71, "children": [], "start_point": {"row": 59, "column": 2}, "end_point": {"row": 59, "column": 6}}, {"id": 102, "type": "pointer_declarator", "text": "* _node", "parent": 69, "children": [103, 104], "start_point": {"row": 59, "column": 6}, "end_point": {"row": 59, "column": 13}}, {"id": 103, "type": "*", "text": "*", "parent": 102, "children": [], "start_point": {"row": 59, "column": 6}, "end_point": {"row": 59, "column": 7}}, {"id": 104, "type": "identifier", "text": "_node", "parent": 102, "children": [], "start_point": {"row": 59, "column": 8}, "end_point": {"row": 59, "column": 13}}, {"id": 105, "type": "declaration", "text": "Connection* _connection;", "parent": 63, "children": [106, 107], "start_point": {"row": 61, "column": 2}, "end_point": {"row": 61, "column": 26}}, {"id": 106, "type": "type_identifier", "text": "Connection", "parent": 105, "children": [], "start_point": {"row": 61, "column": 2}, "end_point": {"row": 61, "column": 12}}, {"id": 107, "type": "pointer_declarator", "text": "* _connection", "parent": 105, "children": [108, 109], "start_point": {"row": 61, "column": 12}, "end_point": {"row": 61, "column": 25}}, {"id": 108, "type": "*", "text": "*", "parent": 107, "children": [], "start_point": {"row": 61, "column": 12}, "end_point": {"row": 61, "column": 13}}, {"id": 109, "type": "identifier", "text": "_connection", "parent": 107, "children": [], "start_point": {"row": 61, "column": 14}, "end_point": {"row": 61, "column": 25}}, {"id": 110, "type": "declaration", "text": "FlowScene* _scene;", "parent": 63, "children": [111, 112], "start_point": {"row": 63, "column": 2}, "end_point": {"row": 63, "column": 20}}, {"id": 111, "type": "type_identifier", "text": "FlowScene", "parent": 110, "children": [], "start_point": {"row": 63, "column": 2}, "end_point": {"row": 63, "column": 11}}, {"id": 112, "type": "pointer_declarator", "text": "* _scene", "parent": 110, "children": [113, 114], "start_point": {"row": 63, "column": 11}, "end_point": {"row": 63, "column": 19}}, {"id": 113, "type": "*", "text": "*", "parent": 112, "children": [], "start_point": {"row": 63, "column": 11}, "end_point": {"row": 63, "column": 12}}, {"id": 114, "type": "identifier", "text": "_scene", "parent": 112, "children": [], "start_point": {"row": 63, "column": 13}, "end_point": {"row": 63, "column": 19}}]}, "node_categories": {"declarations": {"functions": [9, 18, 35, 46, 51, 60, 65, 72, 82, 92], "variables": [12, 14, 16, 38, 41, 54, 69, 75, 78, 85, 88, 95, 98, 105, 110], "classes": [], "imports": [3, 4, 6, 7], "modules": [], "enums": []}, "statements": {"expressions": [21, 24, 27, 30], "assignments": [], "loops": [], "conditionals": [10, 11, 13, 15, 17, 19, 22, 25, 26, 28, 29, 31, 32, 36, 39, 40, 42, 43, 47, 52, 55, 56, 59, 61, 64, 66, 68, 70, 73, 76, 77, 79, 80, 81, 83, 86, 87, 89, 90, 93, 96, 97, 99, 100, 101, 104, 106, 109, 111, 114], "returns": [], "exceptions": []}, "expressions": {"calls": [0], "literals": [5, 8], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 9, "universal_type": "function", "name": "DataModelRegistry;", "text_snippet": "namespace QtNodes {\n\nclass DataModelRegistry;\nclass FlowScene;\nclass NodeDataModel;\n\n/// Class perfo"}, {"node_id": 18, "universal_type": "function", "name": "NodeConnectionInteraction", "text_snippet": "class NodeConnectionInteraction {\n public:\n NodeConnectionInteraction(Node& node,\n "}, {"node_id": 35, "universal_type": "function", "name": "unknown", "text_snippet": "canConnect(PortIndex& portIndex,\n TypeConverter& converter) const"}, {"node_id": 46, "universal_type": "function", "name": "unknown", "text_snippet": "tryConnect()"}, {"node_id": 51, "universal_type": "function", "name": "unknown", "text_snippet": "disconnect(PortType portToDisconnect) const"}, {"node_id": 60, "universal_type": "function", "name": "unknown", "text_snippet": "connectionRequiredPort() const"}, {"node_id": 65, "universal_type": "function", "name": "unknown", "text_snippet": "connectionEndScenePosition(PortType)"}, {"node_id": 72, "universal_type": "function", "name": "unknown", "text_snippet": "nodePortScenePosition(PortType portType,\n PortIndex portIndex) const"}, {"node_id": 82, "universal_type": "function", "name": "unknown", "text_snippet": "nodePortIndexUnderScenePoint(PortType portType,\n QPointF con"}, {"node_id": 92, "universal_type": "function", "name": "unknown", "text_snippet": "nodePortIsEmpty(PortType portType, PortIndex portIndex) const"}], "class_declarations": [], "import_statements": [{"node_id": 3, "text": "#include \"node_editor/Node.h\"\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include \"node_editor/Connection.h\"\n"}, {"node_id": 7, "text": "#include"}]}, "original_source_code": "#pragma once\n\n#include \"node_editor/Node.h\"\n#include \"node_editor/Connection.h\"\n\nnamespace QtNodes {\n\nclass DataModelRegistry;\nclass FlowScene;\nclass NodeDataModel;\n\n/// Class performs various operations on the Node and Connection pair.\n/// An instance should be created on the stack and destroyed when\n/// the operation is completed\nclass NodeConnectionInteraction {\n public:\n NodeConnectionInteraction(Node& node,\n Connection& connection,\n FlowScene& scene);\n\n /// Can connect when following conditions are met:\n /// 1) Connection 'requires' a port\n /// 2) Connection's vacant end is above the node port\n /// 3) Node port is vacant\n /// 4) Connection type equals node port type, or there is a registered type conversion that can translate between the two\n bool canConnect(PortIndex& portIndex,\n TypeConverter& converter) const;\n\n /// 1) Check conditions from 'canConnect'\n /// 1.5) If the connection is possible but a type conversion is needed, add a converter node to the scene, and connect it properly\n /// 2) Assign node to required port in Connection\n /// 3) Assign Connection to empty port in NodeState\n /// 4) Adjust Connection geometry\n /// 5) Poke model to initiate data transfer\n bool tryConnect() const;\n\n\n /// 1) Node and Connection should be already connected\n /// 2) If so, clear Connection entry in the NodeState\n /// 3) Propagate invalid data to IN node\n /// 4) Set Connection end to 'requiring a port'\n bool disconnect(PortType portToDisconnect) const;\n\n private:\n\n PortType connectionRequiredPort() const;\n\n QPointF connectionEndScenePosition(PortType) const;\n\n QPointF nodePortScenePosition(PortType portType,\n PortIndex portIndex) const;\n\n PortIndex nodePortIndexUnderScenePoint(PortType portType,\n QPointF const& p) const;\n\n bool nodePortIsEmpty(PortType portType, PortIndex portIndex) const;\n\n private:\n\n Node* _node;\n\n Connection* _connection;\n\n FlowScene* _scene;\n};\n}\n"}
80,544
c
// ///////////////////////////////////////////////////////////////// // Generated by dtkPluginGenerator // ///////////////////////////////////////////////////////////////// #ifndef ITKINRDATAIMAGEWRITERPLUGINEXPORT_H #define ITKINRDATAIMAGEWRITERPLUGINEXPORT_H #ifdef WIN32 #ifdef itkINRDataImageWriterPlugin_EXPORTS #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllexport) #else #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllimport) #endif #else #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __attribute__ ((visibility ("default"))) #endif #endif
38.73
15
(translation_unit) "// /////////////////////////////////////////////////////////////////\n// Generated by dtkPluginGenerator\n// /////////////////////////////////////////////////////////////////\n\n#ifndef ITKINRDATAIMAGEWRITERPLUGINEXPORT_H\n#define ITKINRDATAIMAGEWRITERPLUGINEXPORT_H\n\n#ifdef WIN32\n #ifdef itkINRDataImageWriterPlugin_EXPORTS\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllexport)\n #else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllimport)\n #endif\n#else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __attribute__ ((visibility ("default")))\n#endif\n\n#endif\n" (comment) "// /////////////////////////////////////////////////////////////////" (comment) "// Generated by dtkPluginGenerator" (comment) "// /////////////////////////////////////////////////////////////////" (preproc_ifdef) "#ifndef ITKINRDATAIMAGEWRITERPLUGINEXPORT_H\n#define ITKINRDATAIMAGEWRITERPLUGINEXPORT_H\n\n#ifdef WIN32\n #ifdef itkINRDataImageWriterPlugin_EXPORTS\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllexport)\n #else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllimport)\n #endif\n#else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __attribute__ ((visibility ("default")))\n#endif\n\n#endif" (#ifndef) "#ifndef" (identifier) "ITKINRDATAIMAGEWRITERPLUGINEXPORT_H" (preproc_def) "#define ITKINRDATAIMAGEWRITERPLUGINEXPORT_H\n" (#define) "#define" (identifier) "ITKINRDATAIMAGEWRITERPLUGINEXPORT_H" (preproc_ifdef) "#ifdef WIN32\n #ifdef itkINRDataImageWriterPlugin_EXPORTS\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllexport)\n #else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllimport)\n #endif\n#else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __attribute__ ((visibility ("default")))\n#endif" (#ifdef) "#ifdef" (identifier) "WIN32" (preproc_ifdef) "#ifdef itkINRDataImageWriterPlugin_EXPORTS\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllexport)\n #else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllimport)\n #endif" (#ifdef) "#ifdef" (identifier) "itkINRDataImageWriterPlugin_EXPORTS" (preproc_def) "#define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllexport)\n" (#define) "#define" (identifier) "ITKINRDATAIMAGEWRITERPLUGIN_EXPORT" (preproc_arg) "__declspec(dllexport)" (preproc_else) "#else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllimport)\n" (#else) "#else" (preproc_def) "#define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllimport)\n" (#define) "#define" (identifier) "ITKINRDATAIMAGEWRITERPLUGIN_EXPORT" (preproc_arg) "__declspec(dllimport)" (#endif) "#endif" (preproc_else) "#else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __attribute__ ((visibility ("default")))\n" (#else) "#else" (preproc_def) "#define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __attribute__ ((visibility ("default")))\n" (#define) "#define" (identifier) "ITKINRDATAIMAGEWRITERPLUGIN_EXPORT" (preproc_arg) "__attribute__ ((visibility ("default")))" (#endif) "#endif" (#endif) "#endif"
35
0
{"language": "c", "success": true, "metadata": {"lines": 15, "avg_line_length": 38.73, "nodes": 31, "errors": 0, "source_hash": "4d46bde9fdd04adc8fad1ae8eb8e80d885dd1e78ae053687c757d3c086f9c818", "categorized_nodes": 16}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef ITKINRDATAIMAGEWRITERPLUGINEXPORT_H\n#define ITKINRDATAIMAGEWRITERPLUGINEXPORT_H\n\n#ifdef WIN32\n #ifdef itkINRDataImageWriterPlugin_EXPORTS\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllexport)\n #else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllimport)\n #endif\n#else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __attribute__ ((visibility (\"default\")))\n#endif\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 30], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 17, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 7}}, {"id": 2, "type": "identifier", "text": "ITKINRDATAIMAGEWRITERPLUGINEXPORT_H", "parent": 0, "children": [], "start_point": {"row": 4, "column": 8}, "end_point": {"row": 4, "column": 43}}, {"id": 3, "type": "preproc_def", "text": "#define ITKINRDATAIMAGEWRITERPLUGINEXPORT_H\n", "parent": 0, "children": [4, 5], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 7}}, {"id": 5, "type": "identifier", "text": "ITKINRDATAIMAGEWRITERPLUGINEXPORT_H", "parent": 3, "children": [], "start_point": {"row": 5, "column": 8}, "end_point": {"row": 5, "column": 43}}, {"id": 6, "type": "preproc_ifdef", "text": "#ifdef WIN32\n #ifdef itkINRDataImageWriterPlugin_EXPORTS\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllexport)\n #else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllimport)\n #endif\n#else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __attribute__ ((visibility (\"default\")))\n#endif", "parent": 0, "children": [7, 8, 9, 23, 29], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 15, "column": 6}}, {"id": 7, "type": "#ifdef", "text": "#ifdef", "parent": 6, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 6}}, {"id": 8, "type": "identifier", "text": "WIN32", "parent": 6, "children": [], "start_point": {"row": 7, "column": 7}, "end_point": {"row": 7, "column": 12}}, {"id": 9, "type": "preproc_ifdef", "text": "#ifdef itkINRDataImageWriterPlugin_EXPORTS\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllexport)\n #else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllimport)\n #endif", "parent": 6, "children": [10, 11, 12, 16, 22], "start_point": {"row": 8, "column": 4}, "end_point": {"row": 12, "column": 10}}, {"id": 10, "type": "#ifdef", "text": "#ifdef", "parent": 9, "children": [], "start_point": {"row": 8, "column": 4}, "end_point": {"row": 8, "column": 10}}, {"id": 11, "type": "identifier", "text": "itkINRDataImageWriterPlugin_EXPORTS", "parent": 9, "children": [], "start_point": {"row": 8, "column": 11}, "end_point": {"row": 8, "column": 46}}, {"id": 12, "type": "preproc_def", "text": "#define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllexport)\n", "parent": 9, "children": [13, 14, 15], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 10, "column": 0}}, {"id": 13, "type": "#define", "text": "#define", "parent": 12, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 15}}, {"id": 14, "type": "identifier", "text": "ITKINRDATAIMAGEWRITERPLUGIN_EXPORT", "parent": 12, "children": [], "start_point": {"row": 9, "column": 16}, "end_point": {"row": 9, "column": 50}}, {"id": 15, "type": "preproc_arg", "text": "__declspec(dllexport)", "parent": 12, "children": [], "start_point": {"row": 9, "column": 51}, "end_point": {"row": 9, "column": 72}}, {"id": 16, "type": "preproc_else", "text": "#else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllimport)\n", "parent": 9, "children": [17, 18], "start_point": {"row": 10, "column": 4}, "end_point": {"row": 12, "column": 0}}, {"id": 17, "type": "#else", "text": "#else", "parent": 16, "children": [], "start_point": {"row": 10, "column": 4}, "end_point": {"row": 10, "column": 9}}, {"id": 18, "type": "preproc_def", "text": "#define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllimport)\n", "parent": 16, "children": [19, 20, 21], "start_point": {"row": 11, "column": 8}, "end_point": {"row": 12, "column": 0}}, {"id": 19, "type": "#define", "text": "#define", "parent": 18, "children": [], "start_point": {"row": 11, "column": 8}, "end_point": {"row": 11, "column": 15}}, {"id": 20, "type": "identifier", "text": "ITKINRDATAIMAGEWRITERPLUGIN_EXPORT", "parent": 18, "children": [], "start_point": {"row": 11, "column": 16}, "end_point": {"row": 11, "column": 50}}, {"id": 21, "type": "preproc_arg", "text": "__declspec(dllimport)", "parent": 18, "children": [], "start_point": {"row": 11, "column": 51}, "end_point": {"row": 11, "column": 72}}, {"id": 22, "type": "#endif", "text": "#endif", "parent": 9, "children": [], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 10}}, {"id": 23, "type": "preproc_else", "text": "#else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __attribute__ ((visibility (\"default\")))\n", "parent": 6, "children": [24, 25], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 15, "column": 0}}, {"id": 24, "type": "#else", "text": "#else", "parent": 23, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 5}}, {"id": 25, "type": "preproc_def", "text": "#define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __attribute__ ((visibility (\"default\")))\n", "parent": 23, "children": [26, 27, 28], "start_point": {"row": 14, "column": 4}, "end_point": {"row": 15, "column": 0}}, {"id": 26, "type": "#define", "text": "#define", "parent": 25, "children": [], "start_point": {"row": 14, "column": 4}, "end_point": {"row": 14, "column": 11}}, {"id": 27, "type": "identifier", "text": "ITKINRDATAIMAGEWRITERPLUGIN_EXPORT", "parent": 25, "children": [], "start_point": {"row": 14, "column": 12}, "end_point": {"row": 14, "column": 46}}, {"id": 28, "type": "preproc_arg", "text": "__attribute__ ((visibility (\"default\")))", "parent": 25, "children": [], "start_point": {"row": 14, "column": 47}, "end_point": {"row": 14, "column": 87}}, {"id": 29, "type": "#endif", "text": "#endif", "parent": 6, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 6}}, {"id": 30, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 6}}]}, "node_categories": {"declarations": {"functions": [], "variables": [], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 6, 7, 8, 9, 10, 11, 14, 20, 22, 27, 29, 30], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [], "class_declarations": [], "import_statements": []}, "original_source_code": "// /////////////////////////////////////////////////////////////////\n// Generated by dtkPluginGenerator\n// /////////////////////////////////////////////////////////////////\n\n#ifndef ITKINRDATAIMAGEWRITERPLUGINEXPORT_H\n#define ITKINRDATAIMAGEWRITERPLUGINEXPORT_H\n\n#ifdef WIN32\n #ifdef itkINRDataImageWriterPlugin_EXPORTS\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllexport)\n #else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __declspec(dllimport)\n #endif\n#else\n #define ITKINRDATAIMAGEWRITERPLUGIN_EXPORT __attribute__ ((visibility (\"default\")))\n#endif\n\n#endif\n"}
80,545
c
#ifndef uuid_guard_749f57a6_a1336058_14a62898_c4731a4a #define uuid_guard_749f57a6_a1336058_14a62898_c4731a4a #include <string> namespace tul{ struct Uuid{ Uuid(); Uuid(const Uuid& obj); Uuid(unsigned long first, unsigned long second); bool operator ==(const Uuid& rhs) const; bool operator !=(const Uuid& rhs) const; //TODO implement the rest of the operators bool operator <(const Uuid& rhs) const; std::string serialize() const; bool unserialize(const std::string& str); unsigned long first; unsigned long second; }; } #endif // uuid_guard_749f57a6_a1336058_14a62898_c4731a4a
30.05
19
(translation_unit) "#ifndef uuid_guard_749f57a6_a1336058_14a62898_c4731a4a\n#define uuid_guard_749f57a6_a1336058_14a62898_c4731a4a\n\n#include <string>\n\nnamespace tul{\n\nstruct Uuid{\n Uuid();\n Uuid(const Uuid& obj);\n Uuid(unsigned long first, unsigned long second);\n\n bool operator ==(const Uuid& rhs) const;\n bool operator !=(const Uuid& rhs) const;\n\n //TODO implement the rest of the operators\n bool operator <(const Uuid& rhs) const;\n\n std::string serialize() const;\n bool unserialize(const std::string& str);\n\n unsigned long first;\n unsigned long second;\n};\n\n}\n\n#endif // uuid_guard_749f57a6_a1336058_14a62898_c4731a4a\n" (preproc_ifdef) "#ifndef uuid_guard_749f57a6_a1336058_14a62898_c4731a4a\n#define uuid_guard_749f57a6_a1336058_14a62898_c4731a4a\n\n#include <string>\n\nnamespace tul{\n\nstruct Uuid{\n Uuid();\n Uuid(const Uuid& obj);\n Uuid(unsigned long first, unsigned long second);\n\n bool operator ==(const Uuid& rhs) const;\n bool operator !=(const Uuid& rhs) const;\n\n //TODO implement the rest of the operators\n bool operator <(const Uuid& rhs) const;\n\n std::string serialize() const;\n bool unserialize(const std::string& str);\n\n unsigned long first;\n unsigned long second;\n};\n\n}\n\n#endif" (#ifndef) "#ifndef" (identifier) "uuid_guard_749f57a6_a1336058_14a62898_c4731a4a" (preproc_def) "#define uuid_guard_749f57a6_a1336058_14a62898_c4731a4a\n" (#define) "#define" (identifier) "uuid_guard_749f57a6_a1336058_14a62898_c4731a4a" (preproc_include) "#include <string>\n" (#include) "#include" (system_lib_string) "<string>" (function_definition) "namespace tul{\n\nstruct Uuid{\n Uuid();\n Uuid(const Uuid& obj);\n Uuid(unsigned long first, unsigned long second);\n\n bool operator ==(const Uuid& rhs) const;\n bool operator !=(const Uuid& rhs) const;\n\n //TODO implement the rest of the operators\n bool operator <(const Uuid& rhs) const;\n\n std::string serialize() const;\n bool unserialize(const std::string& str);\n\n unsigned long first;\n unsigned long second;\n};\n\n}" (type_identifier) "namespace" (identifier) "tul" (compound_statement) "{\n\nstruct Uuid{\n Uuid();\n Uuid(const Uuid& obj);\n Uuid(unsigned long first, unsigned long second);\n\n bool operator ==(const Uuid& rhs) const;\n bool operator !=(const Uuid& rhs) const;\n\n //TODO implement the rest of the operators\n bool operator <(const Uuid& rhs) const;\n\n std::string serialize() const;\n bool unserialize(const std::string& str);\n\n unsigned long first;\n unsigned long second;\n};\n\n}" ({) "{" (struct_specifier) "struct Uuid{\n Uuid();\n Uuid(const Uuid& obj);\n Uuid(unsigned long first, unsigned long second);\n\n bool operator ==(const Uuid& rhs) const;\n bool operator !=(const Uuid& rhs) const;\n\n //TODO implement the rest of the operators\n bool operator <(const Uuid& rhs) const;\n\n std::string serialize() const;\n bool unserialize(const std::string& str);\n\n unsigned long first;\n unsigned long second;\n}" (struct) "struct" (type_identifier) "Uuid" (field_declaration_list) "{\n Uuid();\n Uuid(const Uuid& obj);\n Uuid(unsigned long first, unsigned long second);\n\n bool operator ==(const Uuid& rhs) const;\n bool operator !=(const Uuid& rhs) const;\n\n //TODO implement the rest of the operators\n bool operator <(const Uuid& rhs) const;\n\n std::string serialize() const;\n bool unserialize(const std::string& str);\n\n unsigned long first;\n unsigned long second;\n}" ({) "{" (field_declaration) "Uuid();" (macro_type_specifier) "Uuid()" (identifier) "Uuid" (() "(" (type_descriptor) "" (type_identifier) "" ()) ")" (;) ";" (field_declaration) "Uuid(const Uuid& obj);" (macro_type_specifier) "Uuid(const Uuid& obj)" (identifier) "Uuid" (() "(" (type_descriptor) "const Uuid" (type_qualifier) "const" (const) "const" (type_identifier) "Uuid" (ERROR) "& obj" (&) "&" (identifier) "obj" ()) ")" (;) ";" (field_declaration) "Uuid(unsigned long first, unsigned long second);" (macro_type_specifier) "Uuid(unsigned long first, unsigned long second)" (identifier) "Uuid" (() "(" (ERROR) "unsigned long first," (type_descriptor) "unsigned long first" (sized_type_specifier) "unsigned long first" (unsigned) "unsigned" (long) "long" (type_identifier) "first" (,) "," (type_descriptor) "unsigned long second" (sized_type_specifier) "unsigned long second" (unsigned) "unsigned" (long) "long" (type_identifier) "second" ()) ")" (;) ";" (field_declaration) "bool operator ==(const Uuid& rhs) const;" (primitive_type) "bool" (field_identifier) "operator" (ERROR) "==(const Uuid& rhs) const" (==) "==" (() "(" (const) "const" (identifier) "Uuid" (&) "&" (identifier) "rhs" ()) ")" (const) "const" (;) ";" (field_declaration) "bool operator !=(const Uuid& rhs) const;" (primitive_type) "bool" (field_identifier) "operator" (ERROR) "!=(const Uuid& rhs) const" (!=) "!=" (() "(" (const) "const" (identifier) "Uuid" (&) "&" (identifier) "rhs" ()) ")" (const) "const" (;) ";" (comment) "//TODO implement the rest of the operators" (field_declaration) "bool operator <(const Uuid& rhs) const;" (primitive_type) "bool" (field_identifier) "operator" (ERROR) "<(const Uuid& rhs) const" (<) "<" (() "(" (const) "const" (identifier) "Uuid" (&) "&" (identifier) "rhs" ()) ")" (const) "const" (;) ";" (field_declaration) "std::string serialize() const;" (type_identifier) "std" (ERROR) "::string serialize()" (:) ":" (:) ":" (field_identifier) "string" (function_declarator) "serialize()" (field_identifier) "serialize" (parameter_list) "()" (() "(" ()) ")" (field_identifier) "const" (;) ";" (field_declaration) "bool unserialize(const std::string& str);" (primitive_type) "bool" (field_identifier) "unserialize" (ERROR) "(const std:" (() "(" (type_qualifier) "const" (const) "const" (type_identifier) "std" (:) ":" (bitfield_clause) ":string& str" (:) ":" (binary_expression) "string& str" (identifier) "string" (&) "&" (identifier) "str" (ERROR) ")" ()) ")" (;) ";" (field_declaration) "unsigned long first;" (sized_type_specifier) "unsigned long" (unsigned) "unsigned" (long) "long" (field_identifier) "first" (;) ";" (field_declaration) "unsigned long second;" (sized_type_specifier) "unsigned long" (unsigned) "unsigned" (long) "long" (field_identifier) "second" (;) ";" (}) "}" (;) ";" (}) "}" (#endif) "#endif" (comment) "// uuid_guard_749f57a6_a1336058_14a62898_c4731a4a"
147
8
{"language": "c", "success": true, "metadata": {"lines": 19, "avg_line_length": 30.05, "nodes": 89, "errors": 0, "source_hash": "1f62cfb2e236c4ca6646131a6eeb2e9e06a4ac129ec4bcf3db591d145a743fd5", "categorized_nodes": 60}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef uuid_guard_749f57a6_a1336058_14a62898_c4731a4a\n#define uuid_guard_749f57a6_a1336058_14a62898_c4731a4a\n\n#include <string>\n\nnamespace tul{\n\nstruct Uuid{\n\tUuid();\n\tUuid(const Uuid& obj);\n\tUuid(unsigned long first, unsigned long second);\n\n\tbool operator ==(const Uuid& rhs) const;\n\tbool operator !=(const Uuid& rhs) const;\n\n\t//TODO implement the rest of the operators\n\tbool operator <(const Uuid& rhs) const;\n\n\tstd::string serialize() const;\n\tbool unserialize(const std::string& str);\n\n\tunsigned long first;\n\tunsigned long second;\n};\n\n}\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 88], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 27, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "identifier", "text": "uuid_guard_749f57a6_a1336058_14a62898_c4731a4a", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 54}}, {"id": 3, "type": "preproc_def", "text": "#define uuid_guard_749f57a6_a1336058_14a62898_c4731a4a\n", "parent": 0, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 5, "type": "identifier", "text": "uuid_guard_749f57a6_a1336058_14a62898_c4731a4a", "parent": 3, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 54}}, {"id": 6, "type": "preproc_include", "text": "#include <string>\n", "parent": 0, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<string>", "parent": 6, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 17}}, {"id": 9, "type": "function_definition", "text": "namespace tul{\n\nstruct Uuid{\n\tUuid();\n\tUuid(const Uuid& obj);\n\tUuid(unsigned long first, unsigned long second);\n\n\tbool operator ==(const Uuid& rhs) const;\n\tbool operator !=(const Uuid& rhs) const;\n\n\t//TODO implement the rest of the operators\n\tbool operator <(const Uuid& rhs) const;\n\n\tstd::string serialize() const;\n\tbool unserialize(const std::string& str);\n\n\tunsigned long first;\n\tunsigned long second;\n};\n\n}", "parent": 0, "children": [10, 11], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 25, "column": 1}}, {"id": 10, "type": "type_identifier", "text": "namespace", "parent": 9, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 9}}, {"id": 11, "type": "identifier", "text": "tul", "parent": 9, "children": [], "start_point": {"row": 5, "column": 10}, "end_point": {"row": 5, "column": 13}}, {"id": 12, "type": "struct_specifier", "text": "struct Uuid{\n\tUuid();\n\tUuid(const Uuid& obj);\n\tUuid(unsigned long first, unsigned long second);\n\n\tbool operator ==(const Uuid& rhs) const;\n\tbool operator !=(const Uuid& rhs) const;\n\n\t//TODO implement the rest of the operators\n\tbool operator <(const Uuid& rhs) const;\n\n\tstd::string serialize() const;\n\tbool unserialize(const std::string& str);\n\n\tunsigned long first;\n\tunsigned long second;\n}", "parent": 9, "children": [13, 14], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 23, "column": 1}}, {"id": 13, "type": "struct", "text": "struct", "parent": 12, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 6}}, {"id": 14, "type": "type_identifier", "text": "Uuid", "parent": 12, "children": [], "start_point": {"row": 7, "column": 7}, "end_point": {"row": 7, "column": 11}}, {"id": 15, "type": "field_declaration", "text": "Uuid();", "parent": 12, "children": [16], "start_point": {"row": 8, "column": 1}, "end_point": {"row": 8, "column": 8}}, {"id": 16, "type": "macro_type_specifier", "text": "Uuid()", "parent": 15, "children": [17, 18], "start_point": {"row": 8, "column": 1}, "end_point": {"row": 8, "column": 7}}, {"id": 17, "type": "identifier", "text": "Uuid", "parent": 16, "children": [], "start_point": {"row": 8, "column": 1}, "end_point": {"row": 8, "column": 5}}, {"id": 18, "type": "type_descriptor", "text": "", "parent": 16, "children": [19], "start_point": {"row": 8, "column": 6}, "end_point": {"row": 8, "column": 6}}, {"id": 19, "type": "type_identifier", "text": "", "parent": 18, "children": [], "start_point": {"row": 8, "column": 6}, "end_point": {"row": 8, "column": 6}}, {"id": 20, "type": "field_declaration", "text": "Uuid(const Uuid& obj);", "parent": 12, "children": [21], "start_point": {"row": 9, "column": 1}, "end_point": {"row": 9, "column": 23}}, {"id": 21, "type": "macro_type_specifier", "text": "Uuid(const Uuid& obj)", "parent": 20, "children": [22, 23, 25], "start_point": {"row": 9, "column": 1}, "end_point": {"row": 9, "column": 22}}, {"id": 22, "type": "identifier", "text": "Uuid", "parent": 21, "children": [], "start_point": {"row": 9, "column": 1}, "end_point": {"row": 9, "column": 5}}, {"id": 23, "type": "type_descriptor", "text": "const Uuid", "parent": 21, "children": [24], "start_point": {"row": 9, "column": 6}, "end_point": {"row": 9, "column": 16}}, {"id": 24, "type": "type_identifier", "text": "Uuid", "parent": 23, "children": [], "start_point": {"row": 9, "column": 12}, "end_point": {"row": 9, "column": 16}}, {"id": 25, "type": "ERROR", "text": "& obj", "parent": 21, "children": [26], "start_point": {"row": 9, "column": 16}, "end_point": {"row": 9, "column": 21}}, {"id": 26, "type": "identifier", "text": "obj", "parent": 25, "children": [], "start_point": {"row": 9, "column": 18}, "end_point": {"row": 9, "column": 21}}, {"id": 27, "type": "field_declaration", "text": "Uuid(unsigned long first, unsigned long second);", "parent": 12, "children": [28], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 49}}, {"id": 28, "type": "macro_type_specifier", "text": "Uuid(unsigned long first, unsigned long second)", "parent": 27, "children": [29, 30, 36], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 48}}, {"id": 29, "type": "identifier", "text": "Uuid", "parent": 28, "children": [], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 5}}, {"id": 30, "type": "ERROR", "text": "unsigned long first,", "parent": 28, "children": [31], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 26}}, {"id": 31, "type": "type_descriptor", "text": "unsigned long first", "parent": 30, "children": [32], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 25}}, {"id": 32, "type": "sized_type_specifier", "text": "unsigned long first", "parent": 31, "children": [33, 34, 35], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 25}}, {"id": 33, "type": "unsigned", "text": "unsigned", "parent": 32, "children": [], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 14}}, {"id": 34, "type": "long", "text": "long", "parent": 32, "children": [], "start_point": {"row": 10, "column": 15}, "end_point": {"row": 10, "column": 19}}, {"id": 35, "type": "type_identifier", "text": "first", "parent": 32, "children": [], "start_point": {"row": 10, "column": 20}, "end_point": {"row": 10, "column": 25}}, {"id": 36, "type": "type_descriptor", "text": "unsigned long second", "parent": 28, "children": [37], "start_point": {"row": 10, "column": 27}, "end_point": {"row": 10, "column": 47}}, {"id": 37, "type": "sized_type_specifier", "text": "unsigned long second", "parent": 36, "children": [38, 39, 40], "start_point": {"row": 10, "column": 27}, "end_point": {"row": 10, "column": 47}}, {"id": 38, "type": "unsigned", "text": "unsigned", "parent": 37, "children": [], "start_point": {"row": 10, "column": 27}, "end_point": {"row": 10, "column": 35}}, {"id": 39, "type": "long", "text": "long", "parent": 37, "children": [], "start_point": {"row": 10, "column": 36}, "end_point": {"row": 10, "column": 40}}, {"id": 40, "type": "type_identifier", "text": "second", "parent": 37, "children": [], "start_point": {"row": 10, "column": 41}, "end_point": {"row": 10, "column": 47}}, {"id": 41, "type": "field_declaration", "text": "bool operator ==(const Uuid& rhs) const;", "parent": 12, "children": [42, 43, 44], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 41}}, {"id": 42, "type": "primitive_type", "text": "bool", "parent": 41, "children": [], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 5}}, {"id": 43, "type": "field_identifier", "text": "operator", "parent": 41, "children": [], "start_point": {"row": 12, "column": 6}, "end_point": {"row": 12, "column": 14}}, {"id": 44, "type": "ERROR", "text": "==(const Uuid& rhs) const", "parent": 41, "children": [45, 46, 47], "start_point": {"row": 12, "column": 15}, "end_point": {"row": 12, "column": 40}}, {"id": 45, "type": "==", "text": "==", "parent": 44, "children": [], "start_point": {"row": 12, "column": 15}, "end_point": {"row": 12, "column": 17}}, {"id": 46, "type": "identifier", "text": "Uuid", "parent": 44, "children": [], "start_point": {"row": 12, "column": 24}, "end_point": {"row": 12, "column": 28}}, {"id": 47, "type": "identifier", "text": "rhs", "parent": 44, "children": [], "start_point": {"row": 12, "column": 30}, "end_point": {"row": 12, "column": 33}}, {"id": 48, "type": "field_declaration", "text": "bool operator !=(const Uuid& rhs) const;", "parent": 12, "children": [49, 50, 51], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 41}}, {"id": 49, "type": "primitive_type", "text": "bool", "parent": 48, "children": [], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 5}}, {"id": 50, "type": "field_identifier", "text": "operator", "parent": 48, "children": [], "start_point": {"row": 13, "column": 6}, "end_point": {"row": 13, "column": 14}}, {"id": 51, "type": "ERROR", "text": "!=(const Uuid& rhs) const", "parent": 48, "children": [52, 53, 54], "start_point": {"row": 13, "column": 15}, "end_point": {"row": 13, "column": 40}}, {"id": 52, "type": "!=", "text": "!=", "parent": 51, "children": [], "start_point": {"row": 13, "column": 15}, "end_point": {"row": 13, "column": 17}}, {"id": 53, "type": "identifier", "text": "Uuid", "parent": 51, "children": [], "start_point": {"row": 13, "column": 24}, "end_point": {"row": 13, "column": 28}}, {"id": 54, "type": "identifier", "text": "rhs", "parent": 51, "children": [], "start_point": {"row": 13, "column": 30}, "end_point": {"row": 13, "column": 33}}, {"id": 55, "type": "field_declaration", "text": "bool operator <(const Uuid& rhs) const;", "parent": 12, "children": [56, 57, 58], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 40}}, {"id": 56, "type": "primitive_type", "text": "bool", "parent": 55, "children": [], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 5}}, {"id": 57, "type": "field_identifier", "text": "operator", "parent": 55, "children": [], "start_point": {"row": 16, "column": 6}, "end_point": {"row": 16, "column": 14}}, {"id": 58, "type": "ERROR", "text": "<(const Uuid& rhs) const", "parent": 55, "children": [59, 60, 61], "start_point": {"row": 16, "column": 15}, "end_point": {"row": 16, "column": 39}}, {"id": 59, "type": "<", "text": "<", "parent": 58, "children": [], "start_point": {"row": 16, "column": 15}, "end_point": {"row": 16, "column": 16}}, {"id": 60, "type": "identifier", "text": "Uuid", "parent": 58, "children": [], "start_point": {"row": 16, "column": 23}, "end_point": {"row": 16, "column": 27}}, {"id": 61, "type": "identifier", "text": "rhs", "parent": 58, "children": [], "start_point": {"row": 16, "column": 29}, "end_point": {"row": 16, "column": 32}}, {"id": 62, "type": "field_declaration", "text": "std::string serialize() const;", "parent": 12, "children": [63, 64], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 31}}, {"id": 63, "type": "type_identifier", "text": "std", "parent": 62, "children": [], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 4}}, {"id": 64, "type": "ERROR", "text": "::string serialize()", "parent": 62, "children": [65, 66], "start_point": {"row": 18, "column": 4}, "end_point": {"row": 18, "column": 24}}, {"id": 65, "type": "field_identifier", "text": "string", "parent": 64, "children": [], "start_point": {"row": 18, "column": 6}, "end_point": {"row": 18, "column": 12}}, {"id": 66, "type": "function_declarator", "text": "serialize()", "parent": 64, "children": [67, 68], "start_point": {"row": 18, "column": 13}, "end_point": {"row": 18, "column": 24}}, {"id": 67, "type": "field_identifier", "text": "serialize", "parent": 66, "children": [], "start_point": {"row": 18, "column": 13}, "end_point": {"row": 18, "column": 22}}, {"id": 68, "type": "parameter_list", "text": "()", "parent": 66, "children": [], "start_point": {"row": 18, "column": 22}, "end_point": {"row": 18, "column": 24}}, {"id": 69, "type": "field_declaration", "text": "bool unserialize(const std::string& str);", "parent": 12, "children": [70, 71, 72, 74], "start_point": {"row": 19, "column": 1}, "end_point": {"row": 19, "column": 42}}, {"id": 70, "type": "primitive_type", "text": "bool", "parent": 69, "children": [], "start_point": {"row": 19, "column": 1}, "end_point": {"row": 19, "column": 5}}, {"id": 71, "type": "field_identifier", "text": "unserialize", "parent": 69, "children": [], "start_point": {"row": 19, "column": 6}, "end_point": {"row": 19, "column": 17}}, {"id": 72, "type": "ERROR", "text": "(const std:", "parent": 69, "children": [73], "start_point": {"row": 19, "column": 17}, "end_point": {"row": 19, "column": 28}}, {"id": 73, "type": "type_identifier", "text": "std", "parent": 72, "children": [], "start_point": {"row": 19, "column": 24}, "end_point": {"row": 19, "column": 27}}, {"id": 74, "type": "bitfield_clause", "text": ":string& str", "parent": 69, "children": [75], "start_point": {"row": 19, "column": 28}, "end_point": {"row": 19, "column": 40}}, {"id": 75, "type": "binary_expression", "text": "string& str", "parent": 74, "children": [76, 77], "start_point": {"row": 19, "column": 29}, "end_point": {"row": 19, "column": 40}}, {"id": 76, "type": "identifier", "text": "string", "parent": 75, "children": [], "start_point": {"row": 19, "column": 29}, "end_point": {"row": 19, "column": 35}}, {"id": 77, "type": "identifier", "text": "str", "parent": 75, "children": [], "start_point": {"row": 19, "column": 37}, "end_point": {"row": 19, "column": 40}}, {"id": 78, "type": "field_declaration", "text": "unsigned long first;", "parent": 12, "children": [79, 82], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 21}}, {"id": 79, "type": "sized_type_specifier", "text": "unsigned long", "parent": 78, "children": [80, 81], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 14}}, {"id": 80, "type": "unsigned", "text": "unsigned", "parent": 79, "children": [], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 9}}, {"id": 81, "type": "long", "text": "long", "parent": 79, "children": [], "start_point": {"row": 21, "column": 10}, "end_point": {"row": 21, "column": 14}}, {"id": 82, "type": "field_identifier", "text": "first", "parent": 78, "children": [], "start_point": {"row": 21, "column": 15}, "end_point": {"row": 21, "column": 20}}, {"id": 83, "type": "field_declaration", "text": "unsigned long second;", "parent": 12, "children": [84, 87], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 22}}, {"id": 84, "type": "sized_type_specifier", "text": "unsigned long", "parent": 83, "children": [85, 86], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 14}}, {"id": 85, "type": "unsigned", "text": "unsigned", "parent": 84, "children": [], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 9}}, {"id": 86, "type": "long", "text": "long", "parent": 84, "children": [], "start_point": {"row": 22, "column": 10}, "end_point": {"row": 22, "column": 14}}, {"id": 87, "type": "field_identifier", "text": "second", "parent": 83, "children": [], "start_point": {"row": 22, "column": 15}, "end_point": {"row": 22, "column": 21}}, {"id": 88, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 6}}]}, "node_categories": {"declarations": {"functions": [9, 66], "variables": [15, 20, 27, 41, 48, 55, 62, 69, 78, 83], "classes": [12, 13], "imports": [6, 7], "modules": [], "enums": []}, "statements": {"expressions": [75], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 10, 11, 14, 16, 17, 19, 21, 22, 24, 26, 28, 29, 32, 35, 37, 40, 43, 46, 47, 50, 53, 54, 57, 60, 61, 63, 65, 67, 71, 73, 76, 77, 79, 82, 84, 87, 88], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [8], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": [74]}}, "cross_language_map": {"function_declarations": [{"node_id": 9, "universal_type": "function", "name": "Uuid{", "text_snippet": "namespace tul{\n\nstruct Uuid{\n\tUuid();\n\tUuid(const Uuid& obj);\n\tUuid(unsigned long first, unsigned lo"}, {"node_id": 66, "universal_type": "function", "name": "unknown", "text_snippet": "serialize()"}], "class_declarations": [{"node_id": 12, "universal_type": "class", "name": "Uuid{", "text_snippet": "struct Uuid{\n\tUuid();\n\tUuid(const Uuid& obj);\n\tUuid(unsigned long first, unsigned long second);\n\n\tbo"}, {"node_id": 13, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": [{"node_id": 6, "text": "#include <string>\n"}, {"node_id": 7, "text": "#include"}]}, "original_source_code": "#ifndef uuid_guard_749f57a6_a1336058_14a62898_c4731a4a\n#define uuid_guard_749f57a6_a1336058_14a62898_c4731a4a\n\n#include <string>\n\nnamespace tul{\n\nstruct Uuid{\n\tUuid();\n\tUuid(const Uuid& obj);\n\tUuid(unsigned long first, unsigned long second);\n\n\tbool operator ==(const Uuid& rhs) const;\n\tbool operator !=(const Uuid& rhs) const;\n\n\t//TODO implement the rest of the operators\n\tbool operator <(const Uuid& rhs) const;\n\n\tstd::string serialize() const;\n\tbool unserialize(const std::string& str);\n\n\tunsigned long first;\n\tunsigned long second;\n};\n\n}\n\n#endif // uuid_guard_749f57a6_a1336058_14a62898_c4731a4a\n"}
80,546
c
#pragma once #include <cassert> #include <span> #include <vector> #include <cuda.h> #include <cuda_runtime.h> #include <cuj.h> #include <btrc/utils/cuda/error.h> #include <btrc/utils/scope_guard.h> #include <btrc/utils/uncopyable.h> BTRC_CUDA_BEGIN template<typename T = char> class Buffer : public Uncopyable { public: Buffer(); explicit Buffer(size_t elem_count, const T *cpu_data = nullptr); explicit Buffer(std::span<const T> data); Buffer(Buffer &&other) noexcept; Buffer &operator=(Buffer &&other) noexcept; ~Buffer(); void initialize(size_t elem_count, const T *cpu_data = nullptr); void destroy(); void swap(Buffer &other) noexcept; operator bool() const; bool is_empty() const; size_t get_size() const; size_t get_size_in_bytes() const; operator T *(); operator const T *() const; operator CUdeviceptr(); T *get(); const T *get() const; CUdeviceptr get_device_ptr(); template<typename U> U *as(); template<typename U> const U *as() const; void clear(const T &val); void clear_async(const T &val); void clear_bytes(uint8_t byte); void clear_bytes_async(uint8_t byte); void to_cpu(T *output, size_t beg = 0, size_t end = 0) const; void to_cpu_async(T *output, size_t beg = 0, size_t end = 0) const; void from_cpu(const T *cpu_data, size_t beg = 0, size_t end = 0); void from_cpu_async(const T *cpu_data, size_t beg = 0, size_t end = 0); auto get_cuj_ptr() const; private: size_t elem_count_; T *buffer_; }; // ========================== impl ========================== template<typename T> Buffer<T>::Buffer() : elem_count_(0), buffer_(nullptr) { } template<typename T> Buffer<T>::Buffer(size_t elem_count, const T *cpu_data) : Buffer() { if(elem_count) initialize(elem_count, cpu_data); } template<typename T> Buffer<T>::Buffer(std::span<const T> data) : Buffer(data.size(), data.data()) { } template<typename T> Buffer<T>::Buffer(Buffer &&other) noexcept : Buffer() { swap(other); } template<typename T> Buffer<T> &Buffer<T>::operator=(Buffer &&other) noexcept { swap(other); return *this; } template<typename T> Buffer<T>::~Buffer() { cudaFree(buffer_); } template<typename T> void Buffer<T>::initialize(size_t elem_count, const T *cpu_data) { destroy(); assert(elem_count); elem_count_ = elem_count; throw_on_error(cudaMalloc(&buffer_, sizeof(T) * elem_count)); if(cpu_data) { BTRC_SCOPE_FAIL{ cudaFree(buffer_); }; this->from_cpu(cpu_data); } } template<typename T> void Buffer<T>::destroy() { cudaFree(buffer_); elem_count_ = 0; buffer_ = nullptr; } template<typename T> void Buffer<T>::swap(Buffer &other) noexcept { std::swap(elem_count_, other.elem_count_); std::swap(buffer_, other.buffer_); } template<typename T> Buffer<T>::operator bool() const { return buffer_ != nullptr; } template<typename T> bool Buffer<T>::is_empty() const { return buffer_ == nullptr; } template<typename T> size_t Buffer<T>::get_size() const { return elem_count_; } template<typename T> size_t Buffer<T>::get_size_in_bytes() const { return elem_count_ * sizeof(T); } template<typename T> Buffer<T>::operator T*() { return buffer_; } template<typename T> Buffer<T>::operator const T*() const { return buffer_; } template<typename T> Buffer<T>::operator CUdeviceptr() { return get_device_ptr(); } template<typename T> T *Buffer<T>::get() { return buffer_; } template<typename T> const T *Buffer<T>::get() const { return buffer_; } template<typename T> CUdeviceptr Buffer<T>::get_device_ptr() { return reinterpret_cast<CUdeviceptr>(buffer_); } template<typename T> template<typename U> U *Buffer<T>::as() { return reinterpret_cast<U *>(buffer_); } template<typename T> template<typename U> const U *Buffer<T>::as() const { return reinterpret_cast<const U *>(buffer_); } template<typename T> void Buffer<T>::clear(const T &val) { assert(!is_empty()); std::vector<T> vals(elem_count_, val); this->from_cpu(vals.data()); } template<typename T> void Buffer<T>::clear_async(const T &val) { assert(!is_empty()); std::vector<T> vals(elem_count_, val); from_cpu_async(vals.data()); } template<typename T> void Buffer<T>::clear_bytes(uint8_t byte) { assert(!is_empty()); throw_on_error(cudaMemset(buffer_, byte, get_size_in_bytes())); } template<typename T> void Buffer<T>::clear_bytes_async(uint8_t byte) { assert(!is_empty()); throw_on_error(cudaMemsetAsync(buffer_, byte, get_size_in_bytes())); } template<typename T> void Buffer<T>::from_cpu(const T *cpu_data, size_t beg, size_t end) { if(end <= beg) end = elem_count_; assert(beg < end); const size_t bytes = sizeof(T) * (end - beg); throw_on_error(cudaMemcpy( buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice)); } template<typename T> void Buffer<T>::from_cpu_async(const T *cpu_data, size_t beg, size_t end) { if(end <= beg) end = elem_count_; assert(beg < end); const size_t bytes = sizeof(T) * (end - beg); throw_on_error(cudaMemcpyAsync( buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice)); } template<typename T> void Buffer<T>::to_cpu(T *output, size_t beg, size_t end) const { if(end <= beg) end = elem_count_; assert(beg < end); const size_t bytes = sizeof(T) * (end - beg); throw_on_error(cudaMemcpy( output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost)); } template<typename T> void Buffer<T>::to_cpu_async(T *output, size_t beg, size_t end) const { if(end <= beg) end = elem_count_; assert(beg < end); const size_t bytes = sizeof(T) * (end - beg); throw_on_error(cudaMemcpyAsync( output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost)); } template<typename T> auto Buffer<T>::get_cuj_ptr() const { return cuj::import_pointer(buffer_); } BTRC_CUDA_END
23.16
248
(translation_unit) "#pragma once\n\n#include <cassert>\n#include <span>\n#include <vector>\n\n#include <cuda.h>\n#include <cuda_runtime.h>\n#include <cuj.h>\n\n#include <btrc/utils/cuda/error.h>\n#include <btrc/utils/scope_guard.h>\n#include <btrc/utils/uncopyable.h>\n\nBTRC_CUDA_BEGIN\n\ntemplate<typename T = char>\nclass Buffer : public Uncopyable\n{\npublic:\n\n Buffer();\n\n explicit Buffer(size_t elem_count, const T *cpu_data = nullptr);\n\n explicit Buffer(std::span<const T> data);\n\n Buffer(Buffer &&other) noexcept;\n\n Buffer &operator=(Buffer &&other) noexcept;\n\n ~Buffer();\n\n void initialize(size_t elem_count, const T *cpu_data = nullptr);\n\n void destroy();\n\n void swap(Buffer &other) noexcept;\n\n operator bool() const;\n\n bool is_empty() const;\n\n size_t get_size() const;\n\n size_t get_size_in_bytes() const;\n\n operator T *();\n\n operator const T *() const;\n\n operator CUdeviceptr();\n\n T *get();\n\n const T *get() const;\n\n CUdeviceptr get_device_ptr();\n\n template<typename U>\n U *as();\n\n template<typename U>\n const U *as() const;\n\n void clear(const T &val);\n\n void clear_async(const T &val);\n\n void clear_bytes(uint8_t byte);\n\n void clear_bytes_async(uint8_t byte);\n\n void to_cpu(T *output, size_t beg = 0, size_t end = 0) const;\n\n void to_cpu_async(T *output, size_t beg = 0, size_t end = 0) const;\n\n void from_cpu(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n void from_cpu_async(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n auto get_cuj_ptr() const;\n\nprivate:\n\n size_t elem_count_;\n T *buffer_;\n};\n\n// ========================== impl ==========================\n\ntemplate<typename T>\nBuffer<T>::Buffer()\n : elem_count_(0), buffer_(nullptr)\n{\n \n}\n\ntemplate<typename T>\nBuffer<T>::Buffer(size_t elem_count, const T *cpu_data)\n : Buffer()\n{\n if(elem_count)\n initialize(elem_count, cpu_data);\n}\n\ntemplate<typename T>\nBuffer<T>::Buffer(std::span<const T> data)\n : Buffer(data.size(), data.data())\n{\n \n}\n\ntemplate<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer<T> &Buffer<T>::operator=(Buffer &&other) noexcept\n{\n swap(other);\n return *this;\n}\n\ntemplate<typename T>\nBuffer<T>::~Buffer()\n{\n cudaFree(buffer_);\n}\n\ntemplate<typename T>\nvoid Buffer<T>::initialize(size_t elem_count, const T *cpu_data)\n{\n destroy();\n assert(elem_count);\n elem_count_ = elem_count;\n throw_on_error(cudaMalloc(&buffer_, sizeof(T) * elem_count));\n if(cpu_data)\n {\n BTRC_SCOPE_FAIL{ cudaFree(buffer_); };\n this->from_cpu(cpu_data);\n }\n}\n\ntemplate<typename T>\nvoid Buffer<T>::destroy()\n{\n cudaFree(buffer_);\n elem_count_ = 0;\n buffer_ = nullptr;\n}\n\ntemplate<typename T>\nvoid Buffer<T>::swap(Buffer &other) noexcept\n{\n std::swap(elem_count_, other.elem_count_);\n std::swap(buffer_, other.buffer_);\n}\n\ntemplate<typename T>\nBuffer<T>::operator bool() const\n{\n return buffer_ != nullptr;\n}\n\ntemplate<typename T>\nbool Buffer<T>::is_empty() const\n{\n return buffer_ == nullptr;\n}\n\ntemplate<typename T>\nsize_t Buffer<T>::get_size() const\n{\n return elem_count_;\n}\n\ntemplate<typename T>\nsize_t Buffer<T>::get_size_in_bytes() const\n{\n return elem_count_ * sizeof(T);\n}\n\ntemplate<typename T>\nBuffer<T>::operator T*()\n{\n return buffer_;\n}\n\ntemplate<typename T>\nBuffer<T>::operator const T*() const\n{\n return buffer_;\n}\n\ntemplate<typename T>\nBuffer<T>::operator CUdeviceptr()\n{\n return get_device_ptr();\n}\n\ntemplate<typename T>\nT *Buffer<T>::get()\n{\n return buffer_;\n}\n\ntemplate<typename T>\nconst T *Buffer<T>::get() const\n{\n return buffer_;\n}\n\ntemplate<typename T>\nCUdeviceptr Buffer<T>::get_device_ptr()\n{\n return reinterpret_cast<CUdeviceptr>(buffer_);\n}\n\ntemplate<typename T>\ntemplate<typename U>\nU *Buffer<T>::as()\n{\n return reinterpret_cast<U *>(buffer_);\n}\n\ntemplate<typename T>\ntemplate<typename U>\nconst U *Buffer<T>::as() const\n{\n return reinterpret_cast<const U *>(buffer_);\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear(const T &val)\n{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n this->from_cpu(vals.data());\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_async(const T &val)\n{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n from_cpu_async(vals.data());\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_bytes(uint8_t byte)\n{\n assert(!is_empty());\n throw_on_error(cudaMemset(buffer_, byte, get_size_in_bytes()));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_bytes_async(uint8_t byte)\n{\n assert(!is_empty());\n throw_on_error(cudaMemsetAsync(buffer_, byte, get_size_in_bytes()));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::from_cpu(const T *cpu_data, size_t beg, size_t end)\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::from_cpu_async(const T *cpu_data, size_t beg, size_t end)\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::to_cpu(T *output, size_t beg, size_t end) const\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::to_cpu_async(T *output, size_t beg, size_t end) const\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}\n\ntemplate<typename T>\nauto Buffer<T>::get_cuj_ptr() const\n{\n return cuj::import_pointer(buffer_);\n}\n\nBTRC_CUDA_END\n" (preproc_call) "#pragma once\n" (preproc_directive) "#pragma" (preproc_arg) "once" (preproc_include) "#include <cassert>\n" (#include) "#include" (system_lib_string) "<cassert>" (preproc_include) "#include <span>\n" (#include) "#include" (system_lib_string) "<span>" (preproc_include) "#include <vector>\n" (#include) "#include" (system_lib_string) "<vector>" (preproc_include) "#include <cuda.h>\n" (#include) "#include" (system_lib_string) "<cuda.h>" (preproc_include) "#include <cuda_runtime.h>\n" (#include) "#include" (system_lib_string) "<cuda_runtime.h>" (preproc_include) "#include <cuj.h>\n" (#include) "#include" (system_lib_string) "<cuj.h>" (preproc_include) "#include <btrc/utils/cuda/error.h>\n" (#include) "#include" (system_lib_string) "<btrc/utils/cuda/error.h>" (preproc_include) "#include <btrc/utils/scope_guard.h>\n" (#include) "#include" (system_lib_string) "<btrc/utils/scope_guard.h>" (preproc_include) "#include <btrc/utils/uncopyable.h>\n" (#include) "#include" (system_lib_string) "<btrc/utils/uncopyable.h>" (declaration) "BTRC_CUDA_BEGIN\n\ntemplate<typename T = char>\nclass" (type_identifier) "BTRC_CUDA_BEGIN" (init_declarator) "template<typename T = char>\nclass" (identifier) "template" (ERROR) "<typename T" (<) "<" (identifier) "typename" (identifier) "T" (=) "=" (binary_expression) "char>\nclass" (identifier) "char" (>) ">" (identifier) "class" (;) "" (labeled_statement) "Buffer : public Uncopyable\n{\npublic:\n\n Buffer();\n\n explicit Buffer(size_t elem_count, const T *cpu_data = nullptr);\n\n explicit Buffer(std::span<const T> data);\n\n Buffer(Buffer &&other) noexcept;\n\n Buffer &operator=(Buffer &&other) noexcept;\n\n ~Buffer();\n\n void initialize(size_t elem_count, const T *cpu_data = nullptr);\n\n void destroy();\n\n void swap(Buffer &other) noexcept;\n\n operator bool() const;\n\n bool is_empty() const;\n\n size_t get_size() const;\n\n size_t get_size_in_bytes() const;\n\n operator T *();\n\n operator const T *() const;\n\n operator CUdeviceptr();\n\n T *get();\n\n const T *get() const;\n\n CUdeviceptr get_device_ptr();\n\n template<typename U>\n U *as();\n\n template<typename U>\n const U *as() const;\n\n void clear(const T &val);\n\n void clear_async(const T &val);\n\n void clear_bytes(uint8_t byte);\n\n void clear_bytes_async(uint8_t byte);\n\n void to_cpu(T *output, size_t beg = 0, size_t end = 0) const;\n\n void to_cpu_async(T *output, size_t beg = 0, size_t end = 0) const;\n\n void from_cpu(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n void from_cpu_async(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n auto get_cuj_ptr() const;\n\nprivate:\n\n size_t elem_count_;\n T *buffer_;\n};\n\n// ========================== impl ==========================\n\ntemplate<typename T>\nBuffer<T>::Buffer()\n : elem_count_(0), buffer_(nullptr)\n{\n \n}\n\ntemplate<typename T>\nBuffer<T>::Buffer(size_t elem_count, const T *cpu_data)\n : Buffer()\n{\n if(elem_count)\n initialize(elem_count, cpu_data);\n}" (statement_identifier) "Buffer" (:) ":" (ERROR) "public Uncopyable" (type_identifier) "public" (identifier) "Uncopyable" (compound_statement) "{\npublic:\n\n Buffer();\n\n explicit Buffer(size_t elem_count, const T *cpu_data = nullptr);\n\n explicit Buffer(std::span<const T> data);\n\n Buffer(Buffer &&other) noexcept;\n\n Buffer &operator=(Buffer &&other) noexcept;\n\n ~Buffer();\n\n void initialize(size_t elem_count, const T *cpu_data = nullptr);\n\n void destroy();\n\n void swap(Buffer &other) noexcept;\n\n operator bool() const;\n\n bool is_empty() const;\n\n size_t get_size() const;\n\n size_t get_size_in_bytes() const;\n\n operator T *();\n\n operator const T *() const;\n\n operator CUdeviceptr();\n\n T *get();\n\n const T *get() const;\n\n CUdeviceptr get_device_ptr();\n\n template<typename U>\n U *as();\n\n template<typename U>\n const U *as() const;\n\n void clear(const T &val);\n\n void clear_async(const T &val);\n\n void clear_bytes(uint8_t byte);\n\n void clear_bytes_async(uint8_t byte);\n\n void to_cpu(T *output, size_t beg = 0, size_t end = 0) const;\n\n void to_cpu_async(T *output, size_t beg = 0, size_t end = 0) const;\n\n void from_cpu(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n void from_cpu_async(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n auto get_cuj_ptr() const;\n\nprivate:\n\n size_t elem_count_;\n T *buffer_;\n};\n\n// ========================== impl ==========================\n\ntemplate<typename T>\nBuffer<T>::Buffer()\n : elem_count_(0), buffer_(nullptr)\n{\n \n}\n\ntemplate<typename T>\nBuffer<T>::Buffer(size_t elem_count, const T *cpu_data)\n : Buffer()\n{\n if(elem_count)\n initialize(elem_count, cpu_data);\n}" ({) "{" (labeled_statement) "public:\n\n Buffer();" (statement_identifier) "public" (:) ":" (expression_statement) "Buffer();" (call_expression) "Buffer()" (identifier) "Buffer" (argument_list) "()" (() "(" ()) ")" (;) ";" (declaration) "explicit Buffer(size_t elem_count, const T *cpu_data = nullptr);" (type_identifier) "explicit" (init_declarator) "Buffer(size_t elem_count, const T *cpu_data = nullptr" (function_declarator) "Buffer(size_t elem_count, const T *cpu_data" (identifier) "Buffer" (parameter_list) "(size_t elem_count, const T *cpu_data" (() "(" (parameter_declaration) "size_t elem_count" (primitive_type) "size_t" (identifier) "elem_count" (,) "," (parameter_declaration) "const T *cpu_data" (type_qualifier) "const" (const) "const" (type_identifier) "T" (pointer_declarator) "*cpu_data" (*) "*" (identifier) "cpu_data" ()) "" (=) "=" (null) "nullptr" (nullptr) "nullptr" (ERROR) ")" ()) ")" (;) ";" (declaration) "explicit Buffer(std::span<const T> data);" (type_identifier) "explicit" (function_declarator) "Buffer(std::span<const T> data)" (identifier) "Buffer" (parameter_list) "(std::span<const T> data)" (() "(" (parameter_declaration) "std::span<const T> data" (type_identifier) "std" (ERROR) "::span<const T>" (:) ":" (:) ":" (identifier) "span" (<) "<" (const) "const" (identifier) "T" (>) ">" (identifier) "data" ()) ")" (;) ";" (expression_statement) "Buffer(Buffer &&other) noexcept;" (call_expression) "Buffer(Buffer &&other)" (identifier) "Buffer" (argument_list) "(Buffer &&other)" (() "(" (binary_expression) "Buffer &&other" (identifier) "Buffer" (&&) "&&" (identifier) "other" ()) ")" (ERROR) "noexcept" (identifier) "noexcept" (;) ";" (expression_statement) "Buffer &operator=(Buffer &&other) noexcept;" (binary_expression) "Buffer &operator=(Buffer &&other)" (identifier) "Buffer" (&) "&" (assignment_expression) "operator=(Buffer &&other)" (identifier) "operator" (=) "=" (parenthesized_expression) "(Buffer &&other)" (() "(" (binary_expression) "Buffer &&other" (identifier) "Buffer" (&&) "&&" (identifier) "other" ()) ")" (ERROR) "noexcept" (identifier) "noexcept" (;) ";" (expression_statement) "~Buffer();" (unary_expression) "~Buffer()" (~) "~" (call_expression) "Buffer()" (identifier) "Buffer" (argument_list) "()" (() "(" ()) ")" (;) ";" (declaration) "void initialize(size_t elem_count, const T *cpu_data = nullptr);" (primitive_type) "void" (init_declarator) "initialize(size_t elem_count, const T *cpu_data = nullptr" (function_declarator) "initialize(size_t elem_count, const T *cpu_data" (identifier) "initialize" (parameter_list) "(size_t elem_count, const T *cpu_data" (() "(" (parameter_declaration) "size_t elem_count" (primitive_type) "size_t" (identifier) "elem_count" (,) "," (parameter_declaration) "const T *cpu_data" (type_qualifier) "const" (const) "const" (type_identifier) "T" (pointer_declarator) "*cpu_data" (*) "*" (identifier) "cpu_data" ()) "" (=) "=" (null) "nullptr" (nullptr) "nullptr" (ERROR) ")" ()) ")" (;) ";" (declaration) "void destroy();" (primitive_type) "void" (function_declarator) "destroy()" (identifier) "destroy" (parameter_list) "()" (() "(" ()) ")" (;) ";" (ERROR) "void swap(Buffer &other) noexcept" (primitive_type) "void" (function_declarator) "swap(Buffer &other) noexcept" (identifier) "swap" (parameter_list) "(Buffer &other)" (() "(" (parameter_declaration) "Buffer &other" (type_identifier) "Buffer" (ERROR) "&" (&) "&" (identifier) "other" ()) ")" (identifier) "noexcept" (expression_statement) ";" (;) ";" (function_definition) "operator bool() const;\n\n bool is_empty() const;\n\n size_t get_size() const;\n\n size_t get_size_in_bytes() const;\n\n operator T *();\n\n operator const T *() const;\n\n operator CUdeviceptr();\n\n T *get();\n\n const T *get() const;\n\n CUdeviceptr get_device_ptr();\n\n template<typename U>\n U *as();\n\n template<typename U>\n const U *as() const;\n\n void clear(const T &val);\n\n void clear_async(const T &val);\n\n void clear_bytes(uint8_t byte);\n\n void clear_bytes_async(uint8_t byte);\n\n void to_cpu(T *output, size_t beg = 0, size_t end = 0) const;\n\n void to_cpu_async(T *output, size_t beg = 0, size_t end = 0) const;\n\n void from_cpu(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n void from_cpu_async(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n auto get_cuj_ptr() const;\n\nprivate:\n\n size_t elem_count_;\n T *buffer_;\n};\n\n// ========================== impl ==========================\n\ntemplate<typename T>\nBuffer<T>::Buffer()\n : elem_count_(0), buffer_(nullptr)\n{\n \n}" (type_identifier) "operator" (function_declarator) "bool()" (identifier) "bool" (parameter_list) "()" (() "(" ()) ")" (declaration) "const;\n\n bool is_empty() const;\n\n size_t get_size() const;\n\n size_t get_size_in_bytes() const;\n\n operator T *();" (type_qualifier) "const" (const) "const" (ERROR) ";" (;) ";" (primitive_type) "bool" (ERROR) "is_empty() const;\n\n size_t get_size() const;\n\n size_t get_size_in_bytes() const;\n\n operator T" (function_declarator) "is_empty() const" (identifier) "is_empty" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (primitive_type) "size_t" (function_declarator) "get_size() const" (identifier) "get_size" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (primitive_type) "size_t" (function_declarator) "get_size_in_bytes() const" (identifier) "get_size_in_bytes" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (identifier) "operator" (identifier) "T" (pointer_declarator) "*()" (*) "*" (parenthesized_declarator) "()" (() "(" (identifier) "" ()) ")" (;) ";" (declaration) "operator const T *() const;" (type_identifier) "operator" (type_qualifier) "const" (const) "const" (ERROR) "T" (identifier) "T" (pointer_declarator) "*() const" (*) "*" (ERROR) "()" (() "(" ()) ")" (type_qualifier) "const" (const) "const" (identifier) "" (;) ";" (declaration) "operator CUdeviceptr();" (type_identifier) "operator" (function_declarator) "CUdeviceptr()" (identifier) "CUdeviceptr" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "T *get();" (type_identifier) "T" (pointer_declarator) "*get()" (*) "*" (function_declarator) "get()" (identifier) "get" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "const T *get() const;" (type_qualifier) "const" (const) "const" (type_identifier) "T" (pointer_declarator) "*get() const" (*) "*" (function_declarator) "get() const" (identifier) "get" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (declaration) "CUdeviceptr get_device_ptr();" (type_identifier) "CUdeviceptr" (function_declarator) "get_device_ptr()" (identifier) "get_device_ptr" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "template<typename U>\n U *as();" (type_identifier) "template" (ERROR) "<typename U>\n U" (<) "<" (identifier) "typename" (identifier) "U" (>) ">" (identifier) "U" (pointer_declarator) "*as()" (*) "*" (function_declarator) "as()" (identifier) "as" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "template<typename U>\n const U *as() const;" (type_identifier) "template" (ERROR) "<typename U>\n const U" (<) "<" (identifier) "typename" (identifier) "U" (>) ">" (const) "const" (identifier) "U" (pointer_declarator) "*as() const" (*) "*" (function_declarator) "as() const" (identifier) "as" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (;) ";" (declaration) "void clear(const T &val);" (primitive_type) "void" (function_declarator) "clear(const T &val)" (identifier) "clear" (parameter_list) "(const T &val)" (() "(" (parameter_declaration) "const T &val" (type_qualifier) "const" (const) "const" (type_identifier) "T" (ERROR) "&" (&) "&" (identifier) "val" ()) ")" (;) ";" (declaration) "void clear_async(const T &val);" (primitive_type) "void" (function_declarator) "clear_async(const T &val)" (identifier) "clear_async" (parameter_list) "(const T &val)" (() "(" (parameter_declaration) "const T &val" (type_qualifier) "const" (const) "const" (type_identifier) "T" (ERROR) "&" (&) "&" (identifier) "val" ()) ")" (;) ";" (declaration) "void clear_bytes(uint8_t byte);" (primitive_type) "void" (function_declarator) "clear_bytes(uint8_t byte)" (identifier) "clear_bytes" (parameter_list) "(uint8_t byte)" (() "(" (parameter_declaration) "uint8_t byte" (primitive_type) "uint8_t" (identifier) "byte" ()) ")" (;) ";" (declaration) "void clear_bytes_async(uint8_t byte);" (primitive_type) "void" (function_declarator) "clear_bytes_async(uint8_t byte)" (identifier) "clear_bytes_async" (parameter_list) "(uint8_t byte)" (() "(" (parameter_declaration) "uint8_t byte" (primitive_type) "uint8_t" (identifier) "byte" ()) ")" (;) ";" (declaration) "void to_cpu(T *output, size_t beg = 0, size_t end = 0) const;" (primitive_type) "void" (init_declarator) "to_cpu(T *output, size_t beg = 0" (function_declarator) "to_cpu(T *output, size_t beg" (identifier) "to_cpu" (parameter_list) "(T *output, size_t beg" (() "(" (parameter_declaration) "T *output" (type_identifier) "T" (pointer_declarator) "*output" (*) "*" (identifier) "output" (,) "," (parameter_declaration) "size_t beg" (primitive_type) "size_t" (identifier) "beg" ()) "" (=) "=" (number_literal) "0" (,) "," (init_declarator) "size_t end = 0" (identifier) "size_t" (ERROR) "end" (identifier) "end" (=) "=" (number_literal) "0" (ERROR) ") const" ()) ")" (const) "const" (;) ";" (declaration) "void to_cpu_async(T *output, size_t beg = 0, size_t end = 0) const;" (primitive_type) "void" (init_declarator) "to_cpu_async(T *output, size_t beg = 0" (function_declarator) "to_cpu_async(T *output, size_t beg" (identifier) "to_cpu_async" (parameter_list) "(T *output, size_t beg" (() "(" (parameter_declaration) "T *output" (type_identifier) "T" (pointer_declarator) "*output" (*) "*" (identifier) "output" (,) "," (parameter_declaration) "size_t beg" (primitive_type) "size_t" (identifier) "beg" ()) "" (=) "=" (number_literal) "0" (,) "," (init_declarator) "size_t end = 0" (identifier) "size_t" (ERROR) "end" (identifier) "end" (=) "=" (number_literal) "0" (ERROR) ") const" ()) ")" (const) "const" (;) ";" (declaration) "void from_cpu(const T *cpu_data, size_t beg = 0, size_t end = 0);" (primitive_type) "void" (init_declarator) "from_cpu(const T *cpu_data, size_t beg = 0" (function_declarator) "from_cpu(const T *cpu_data, size_t beg" (identifier) "from_cpu" (parameter_list) "(const T *cpu_data, size_t beg" (() "(" (parameter_declaration) "const T *cpu_data" (type_qualifier) "const" (const) "const" (type_identifier) "T" (pointer_declarator) "*cpu_data" (*) "*" (identifier) "cpu_data" (,) "," (parameter_declaration) "size_t beg" (primitive_type) "size_t" (identifier) "beg" ()) "" (=) "=" (number_literal) "0" (,) "," (init_declarator) "size_t end = 0" (identifier) "size_t" (ERROR) "end" (identifier) "end" (=) "=" (number_literal) "0" (ERROR) ")" ()) ")" (;) ";" (declaration) "void from_cpu_async(const T *cpu_data, size_t beg = 0, size_t end = 0);" (primitive_type) "void" (init_declarator) "from_cpu_async(const T *cpu_data, size_t beg = 0" (function_declarator) "from_cpu_async(const T *cpu_data, size_t beg" (identifier) "from_cpu_async" (parameter_list) "(const T *cpu_data, size_t beg" (() "(" (parameter_declaration) "const T *cpu_data" (type_qualifier) "const" (const) "const" (type_identifier) "T" (pointer_declarator) "*cpu_data" (*) "*" (identifier) "cpu_data" (,) "," (parameter_declaration) "size_t beg" (primitive_type) "size_t" (identifier) "beg" ()) "" (=) "=" (number_literal) "0" (,) "," (init_declarator) "size_t end = 0" (identifier) "size_t" (ERROR) "end" (identifier) "end" (=) "=" (number_literal) "0" (ERROR) ")" ()) ")" (;) ";" (declaration) "auto get_cuj_ptr() const;\n\nprivate:\n\n size_t elem_count_;" (storage_class_specifier) "auto" (auto) "auto" (macro_type_specifier) "get_cuj_ptr() const;\n\nprivate:\n\n size_t" (identifier) "get_cuj_ptr" (() "(" (ERROR) ") const;\n\nprivate:" ()) ")" (type_descriptor) "const;\n\nprivate" (type_qualifier) "const" (const) "const" (ERROR) ";" (;) ";" (type_identifier) "private" (:) ":" (type_descriptor) "size_t" (primitive_type) "size_t" ()) "" (identifier) "elem_count_" (;) ";" (declaration) "T *buffer_;" (type_identifier) "T" (pointer_declarator) "*buffer_" (*) "*" (identifier) "buffer_" (;) ";" (ERROR) "};" (}) "}" (;) ";" (comment) "// ========================== impl ==========================" (ERROR) "template<typename T>\nBuffer<T>::Buffer()\n : elem_count_(0), buffer_(nullptr)" (type_identifier) "template" (ERROR) "<typename T>\nBuffer<T>::Buffer()\n : elem_count_(0)," (<) "<" (identifier) "typename" (identifier) "T" (>) ">" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (:) ":" (:) ":" (function_declarator) "Buffer()\n : elem_count_(0)" (identifier) "Buffer" (parameter_list) "()" (() "(" ()) ")" (ERROR) ":" (:) ":" (call_expression) "elem_count_(0)" (identifier) "elem_count_" (argument_list) "(0)" (() "(" (number_literal) "0" ()) ")" (,) "," (function_declarator) "buffer_(nullptr)" (identifier) "buffer_" (parameter_list) "(nullptr)" (() "(" (parameter_declaration) "nullptr" (type_identifier) "nullptr" ()) ")" (compound_statement) "{\n \n}" ({) "{" (}) "}" (ERROR) "template<typename T>\nBuffer<T>::Buffer(size_t elem_count, const T *cpu_data)\n : Buffer()\n{" (binary_expression) "template<typename T>\nBuffer<T>::Buffer(size_t elem_count, const T *cpu_data)" (binary_expression) "template<typename T>\nBuffer<T" (binary_expression) "template<typename T>\nBuffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "Buffer(size_t elem_count, const T *cpu_data)" (identifier) "Buffer" (argument_list) "(size_t elem_count, const T *cpu_data)" (() "(" (ERROR) "size_t" (identifier) "size_t" (identifier) "elem_count" (,) "," (binary_expression) "const T *cpu_data" (identifier) "const" (ERROR) "T" (identifier) "T" (*) "*" (identifier) "cpu_data" ()) ")" (:) ":" (call_expression) "Buffer()" (identifier) "Buffer" (argument_list) "()" (() "(" ()) ")" ({) "{" (if_statement) "if(elem_count)\n initialize(elem_count, cpu_data);" (if) "if" (parenthesized_expression) "(elem_count)" (() "(" (identifier) "elem_count" ()) ")" (expression_statement) "initialize(elem_count, cpu_data);" (call_expression) "initialize(elem_count, cpu_data)" (identifier) "initialize" (argument_list) "(elem_count, cpu_data)" (() "(" (identifier) "elem_count" (,) "," (identifier) "cpu_data" ()) ")" (;) ";" (}) "}" (ERROR) "template<typename T>\nBuffer<T>::Buffer(std::span<const T> data)\n :" (binary_expression) "template<typename T>\nBuffer<T>::Buffer(std::span<const T> data)" (binary_expression) "template<typename T>\nBuffer<T" (binary_expression) "template<typename T>\nBuffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "Buffer(std::span<const T> data)" (identifier) "Buffer" (argument_list) "(std::span<const T> data)" (() "(" (ERROR) "std::" (identifier) "std" (:) ":" (:) ":" (binary_expression) "span<const T> data" (binary_expression) "span<const" (identifier) "span" (<) "<" (identifier) "const" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "data" ()) ")" (:) ":" (expression_statement) "Buffer(data.size(), data.data())" (call_expression) "Buffer(data.size(), data.data())" (identifier) "Buffer" (argument_list) "(data.size(), data.data())" (() "(" (call_expression) "data.size()" (field_expression) "data.size" (identifier) "data" (.) "." (field_identifier) "size" (argument_list) "()" (() "(" ()) ")" (,) "," (call_expression) "data.data()" (field_expression) "data.data" (identifier) "data" (.) "." (field_identifier) "data" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) "" (compound_statement) "{\n \n}" ({) "{" (}) "}" (ERROR) "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer<T> &Buffer<T>::operator=(Buffer &&other) noexcept" (binary_expression) "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer<T> &Buffer<T>::operator=(Buffer &&other)" (binary_expression) "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer<T> &Buffer<T" (binary_expression) "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer<T> &Buffer" (binary_expression) "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer<T" (binary_expression) "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer" (binary_expression) "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename" (binary_expression) "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other)" (binary_expression) "template<typename T>\nBuffer<T" (binary_expression) "template<typename T>\nBuffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::Buffer(Buffer &&other) noexcept\n : Buffer()\n{" (:) ":" (:) ":" (call_expression) "Buffer(Buffer &&other)" (identifier) "Buffer" (argument_list) "(Buffer &&other)" (() "(" (binary_expression) "Buffer &&other" (identifier) "Buffer" (&&) "&&" (identifier) "other" ()) ")" (identifier) "noexcept" (:) ":" (call_expression) "Buffer()" (identifier) "Buffer" (argument_list) "()" (() "(" ()) ")" ({) "{" (call_expression) "swap(other)" (identifier) "swap" (argument_list) "(other)" (() "(" (identifier) "other" ()) ")" (ERROR) ";\n}\n\ntemplate" (;) ";" (}) "}" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (pointer_expression) "&Buffer" (&) "&" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (assignment_expression) "operator=(Buffer &&other)" (identifier) "operator" (=) "=" (parenthesized_expression) "(Buffer &&other)" (() "(" (binary_expression) "Buffer &&other" (identifier) "Buffer" (&&) "&&" (identifier) "other" ()) ")" (identifier) "noexcept" (compound_statement) "{\n swap(other);\n return *this;\n}" ({) "{" (expression_statement) "swap(other);" (call_expression) "swap(other)" (identifier) "swap" (argument_list) "(other)" (() "(" (identifier) "other" ()) ")" (;) ";" (return_statement) "return *this;" (return) "return" (pointer_expression) "*this" (*) "*" (identifier) "this" (;) ";" (}) "}" (ERROR) "template<typename T>\nBuffer<T>::~Buffer()" (binary_expression) "template<typename T>\nBuffer<T>::~Buffer()" (binary_expression) "template<typename T>\nBuffer<T" (binary_expression) "template<typename T>\nBuffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (unary_expression) "~Buffer()" (~) "~" (call_expression) "Buffer()" (identifier) "Buffer" (argument_list) "()" (() "(" ()) ")" (compound_statement) "{\n cudaFree(buffer_);\n}" ({) "{" (expression_statement) "cudaFree(buffer_);" (call_expression) "cudaFree(buffer_)" (identifier) "cudaFree" (argument_list) "(buffer_)" (() "(" (identifier) "buffer_" ()) ")" (;) ";" (}) "}" (expression_statement) "template<typename T>\nvoid Buffer<T>::initialize(size_t elem_count, const T *cpu_data)\n{\n destroy();" (update_expression) "template<typename T>\nvoid Buffer<T>::initialize(size_t elem_count, const T *cpu_data)\n{\n destroy()" (binary_expression) "template<typename T>\nvoid Buffer<T>::initialize(size_t elem_count, const T *cpu_data)\n{\n destroy()" (binary_expression) "template<typename T>\nvoid Buffer<T" (binary_expression) "template<typename T>\nvoid Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (ERROR) "void" (identifier) "void" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::initialize(size_t elem_count, const T *cpu_data)\n{" (:) ":" (:) ":" (call_expression) "initialize(size_t elem_count, const T *cpu_data)" (identifier) "initialize" (argument_list) "(size_t elem_count, const T *cpu_data)" (() "(" (ERROR) "size_t" (identifier) "size_t" (identifier) "elem_count" (,) "," (binary_expression) "const T *cpu_data" (identifier) "const" (ERROR) "T" (identifier) "T" (*) "*" (identifier) "cpu_data" ()) ")" ({) "{" (call_expression) "destroy()" (identifier) "destroy" (argument_list) "()" (() "(" ()) ")" (--) "" (;) ";" (expression_statement) "assert(elem_count);" (call_expression) "assert(elem_count)" (identifier) "assert" (argument_list) "(elem_count)" (() "(" (identifier) "elem_count" ()) ")" (;) ";" (expression_statement) "elem_count_ = elem_count;" (assignment_expression) "elem_count_ = elem_count" (identifier) "elem_count_" (=) "=" (identifier) "elem_count" (;) ";" (expression_statement) "throw_on_error(cudaMalloc(&buffer_, sizeof(T) * elem_count));" (call_expression) "throw_on_error(cudaMalloc(&buffer_, sizeof(T) * elem_count))" (identifier) "throw_on_error" (argument_list) "(cudaMalloc(&buffer_, sizeof(T) * elem_count))" (() "(" (call_expression) "cudaMalloc(&buffer_, sizeof(T) * elem_count)" (identifier) "cudaMalloc" (argument_list) "(&buffer_, sizeof(T) * elem_count)" (() "(" (pointer_expression) "&buffer_" (&) "&" (identifier) "buffer_" (,) "," (binary_expression) "sizeof(T) * elem_count" (sizeof_expression) "sizeof(T)" (sizeof) "sizeof" (parenthesized_expression) "(T)" (() "(" (identifier) "T" ()) ")" (*) "*" (identifier) "elem_count" ()) ")" ()) ")" (;) ";" (if_statement) "if(cpu_data)\n {\n BTRC_SCOPE_FAIL{ cudaFree(buffer_); };\n this->from_cpu(cpu_data);\n }" (if) "if" (parenthesized_expression) "(cpu_data)" (() "(" (identifier) "cpu_data" ()) ")" (compound_statement) "{\n BTRC_SCOPE_FAIL{ cudaFree(buffer_); };\n this->from_cpu(cpu_data);\n }" ({) "{" (type_identifier) "BTRC_SCOPE_FAIL" (;) "" (compound_statement) "{ cudaFree(buffer_); }" ({) "{" (expression_statement) "cudaFree(buffer_);" (call_expression) "cudaFree(buffer_)" (identifier) "cudaFree" (argument_list) "(buffer_)" (() "(" (identifier) "buffer_" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (expression_statement) "this->from_cpu(cpu_data);" (call_expression) "this->from_cpu(cpu_data)" (field_expression) "this->from_cpu" (identifier) "this" (->) "->" (field_identifier) "from_cpu" (argument_list) "(cpu_data)" (() "(" (identifier) "cpu_data" ()) ")" (;) ";" (}) "}" (ERROR) "}\n\ntemplate<typename T>\nvoid Buffer<T>::destroy()" (}) "}" (binary_expression) "template<typename T>\nvoid Buffer<T>::destroy()" (binary_expression) "template<typename T>\nvoid Buffer<T" (binary_expression) "template<typename T>\nvoid Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (ERROR) "void" (identifier) "void" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "destroy()" (identifier) "destroy" (argument_list) "()" (() "(" ()) ")" (compound_statement) "{\n cudaFree(buffer_);\n elem_count_ = 0;\n buffer_ = nullptr;\n}" ({) "{" (expression_statement) "cudaFree(buffer_);" (call_expression) "cudaFree(buffer_)" (identifier) "cudaFree" (argument_list) "(buffer_)" (() "(" (identifier) "buffer_" ()) ")" (;) ";" (expression_statement) "elem_count_ = 0;" (assignment_expression) "elem_count_ = 0" (identifier) "elem_count_" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "buffer_ = nullptr;" (assignment_expression) "buffer_ = nullptr" (identifier) "buffer_" (=) "=" (null) "nullptr" (nullptr) "nullptr" (;) ";" (}) "}" (ERROR) "template<typename T>\nvoid Buffer<T>::swap(Buffer &other) noexcept" (binary_expression) "template<typename T>\nvoid Buffer<T>::swap(Buffer &other)" (binary_expression) "template<typename T>\nvoid Buffer<T" (binary_expression) "template<typename T>\nvoid Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (ERROR) "void" (identifier) "void" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "swap(Buffer &other)" (identifier) "swap" (argument_list) "(Buffer &other)" (() "(" (binary_expression) "Buffer &other" (identifier) "Buffer" (&) "&" (identifier) "other" ()) ")" (identifier) "noexcept" (compound_statement) "{\n std::swap(elem_count_, other.elem_count_);\n std::swap(buffer_, other.buffer_);\n}" ({) "{" (labeled_statement) "std::swap(elem_count_, other.elem_count_);" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "swap(elem_count_, other.elem_count_);" (call_expression) "swap(elem_count_, other.elem_count_)" (identifier) "swap" (argument_list) "(elem_count_, other.elem_count_)" (() "(" (identifier) "elem_count_" (,) "," (field_expression) "other.elem_count_" (identifier) "other" (.) "." (field_identifier) "elem_count_" ()) ")" (;) ";" (labeled_statement) "std::swap(buffer_, other.buffer_);" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "swap(buffer_, other.buffer_);" (call_expression) "swap(buffer_, other.buffer_)" (identifier) "swap" (argument_list) "(buffer_, other.buffer_)" (() "(" (identifier) "buffer_" (,) "," (field_expression) "other.buffer_" (identifier) "other" (.) "." (field_identifier) "buffer_" ()) ")" (;) ";" (}) "}" (ERROR) "template<typename T>\nBuffer<T>::operator bool() const" (binary_expression) "template<typename T>\nBuffer<T>::operator bool()" (binary_expression) "template<typename T>\nBuffer<T" (binary_expression) "template<typename T>\nBuffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::operator" (:) ":" (:) ":" (identifier) "operator" (call_expression) "bool()" (identifier) "bool" (argument_list) "()" (() "(" ()) ")" (identifier) "const" (compound_statement) "{\n return buffer_ != nullptr;\n}" ({) "{" (return_statement) "return buffer_ != nullptr;" (return) "return" (binary_expression) "buffer_ != nullptr" (identifier) "buffer_" (!=) "!=" (null) "nullptr" (nullptr) "nullptr" (;) ";" (}) "}" (ERROR) "template<typename T>\nbool Buffer<T>::is_empty() const" (binary_expression) "template<typename T>\nbool Buffer<T>::is_empty()" (binary_expression) "template<typename T>\nbool Buffer<T" (binary_expression) "template<typename T>\nbool Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (ERROR) "bool" (identifier) "bool" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "is_empty()" (identifier) "is_empty" (argument_list) "()" (() "(" ()) ")" (identifier) "const" (compound_statement) "{\n return buffer_ == nullptr;\n}" ({) "{" (return_statement) "return buffer_ == nullptr;" (return) "return" (binary_expression) "buffer_ == nullptr" (identifier) "buffer_" (==) "==" (null) "nullptr" (nullptr) "nullptr" (;) ";" (}) "}" (ERROR) "template<typename T>\nsize_t Buffer<T>::get_size() const" (binary_expression) "template<typename T>\nsize_t Buffer<T>::get_size()" (binary_expression) "template<typename T>\nsize_t Buffer<T" (binary_expression) "template<typename T>\nsize_t" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "size_t" (ERROR) "Buffer" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "get_size()" (identifier) "get_size" (argument_list) "()" (() "(" ()) ")" (identifier) "const" (compound_statement) "{\n return elem_count_;\n}" ({) "{" (return_statement) "return elem_count_;" (return) "return" (identifier) "elem_count_" (;) ";" (}) "}" (ERROR) "template<typename T>\nsize_t Buffer<T>::get_size_in_bytes() const" (binary_expression) "template<typename T>\nsize_t Buffer<T>::get_size_in_bytes()" (binary_expression) "template<typename T>\nsize_t Buffer<T" (binary_expression) "template<typename T>\nsize_t" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "size_t" (ERROR) "Buffer" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "get_size_in_bytes()" (identifier) "get_size_in_bytes" (argument_list) "()" (() "(" ()) ")" (identifier) "const" (compound_statement) "{\n return elem_count_ * sizeof(T);\n}" ({) "{" (return_statement) "return elem_count_ * sizeof(T);" (return) "return" (binary_expression) "elem_count_ * sizeof(T)" (identifier) "elem_count_" (*) "*" (sizeof_expression) "sizeof(T)" (sizeof) "sizeof" (parenthesized_expression) "(T)" (() "(" (identifier) "T" ()) ")" (;) ";" (}) "}" (ERROR) "template<typename T>\nBuffer<T>::operator T*()\n{\n return buffer_;\n}\n\ntemplate<typename T>\nBuffer<T>::operator const T*() const\n{\n return buffer_;\n}\n\ntemplate<typename T>\nBuffer<T>::operator CUdeviceptr()\n{\n return get_device_ptr();\n}\n\ntemplate<typename T>\nT *Buffer<T>::get()\n{\n return buffer_;\n}\n\ntemplate<typename T>\nconst T *Buffer<T>::get() const\n{\n return buffer_;\n}\n\ntemplate<typename T>\nCUdeviceptr Buffer<T>::get_device_ptr()\n{\n return reinterpret_cast<CUdeviceptr>(buffer_);\n}\n\ntemplate<typename T>\ntemplate<typename U>\nU *Buffer<T>::as()\n{\n return reinterpret_cast<U *>(buffer_);\n}\n\ntemplate<typename T>\ntemplate<typename U>\nconst U *Buffer<T>::as() const\n{\n return reinterpret_cast<const U *>(buffer_);\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear(const T &val)\n{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n this->from_cpu(vals.data());\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_async(const T &val)\n{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n from_cpu_async(vals.data());\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_bytes(uint8_t byte)\n{\n assert(!is_empty());\n throw_on_error(cudaMemset(buffer_, byte, get_size_in_bytes()));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_bytes_async(uint8_t byte)\n{\n assert(!is_empty());\n throw_on_error(cudaMemsetAsync(buffer_, byte, get_size_in_bytes()));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::from_cpu(const T *cpu_data, size_t beg, size_t end)\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::from_cpu_async(const T *cpu_data, size_t beg, size_t end)\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::to_cpu(T *output, size_t beg, size_t end) const\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::to_cpu_async(T *output, size_t beg, size_t end) const\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}\n\ntemplate<typename T>\nauto Buffer<T>::get_cuj_ptr() const\n{\n return cuj::import_pointer(buffer_);\n}\n\nBTRC_CUDA_END" (binary_expression) "template<typename T>\nBuffer<T" (binary_expression) "template<typename T>\nBuffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::operator" (:) ":" (:) ":" (identifier) "operator" (identifier) "T" (*) "*" (() "(" (ERROR) ")\n{\n return buffer_;\n}" ()) ")" (compound_statement) "{\n return buffer_;\n}" ({) "{" (return_statement) "return buffer_;" (return) "return" (identifier) "buffer_" (;) ";" (}) "}" (binary_expression) "template<typename T>\nBuffer<T" (binary_expression) "template<typename T>\nBuffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::operator const" (:) ":" (:) ":" (identifier) "operator" (identifier) "const" (identifier) "T" (*) "*" (() "(" (ERROR) ") const\n{\n return buffer_;\n}\n\ntemplate<typename T>\nBuffer<T>::operator CUdeviceptr()\n{\n return get_device_ptr();\n}\n\ntemplate<typename T>\nT *Buffer<T>::get()\n{\n return buffer_;\n}\n\ntemplate<typename T>\nconst T *Buffer<T>::get() const\n{\n return buffer_;\n}\n\ntemplate<typename T>\nCUdeviceptr Buffer<T>::get_device_ptr()\n{\n return reinterpret_cast<CUdeviceptr>(buffer_);\n}\n\ntemplate<typename T>\ntemplate<typename U>\nU *Buffer<T>::as()\n{\n return reinterpret_cast<U *>(buffer_);\n}\n\ntemplate<typename T>\ntemplate<typename U>\nconst U *Buffer<T>::as() const\n{\n return reinterpret_cast<const U *>(buffer_);\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear(const T &val)\n{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n this->from_cpu(vals.data());\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_async(const T &val)\n{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n from_cpu_async(vals.data());\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_bytes(uint8_t byte)\n{\n assert(!is_empty());\n throw_on_error(cudaMemset(buffer_, byte, get_size_in_bytes()));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_bytes_async(uint8_t byte)\n{\n assert(!is_empty());\n throw_on_error(cudaMemsetAsync(buffer_, byte, get_size_in_bytes()));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::from_cpu(const T *cpu_data, size_t beg, size_t end)\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::from_cpu_async(const T *cpu_data, size_t beg, size_t end)\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::to_cpu(T *output, size_t beg, size_t end) const\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::to_cpu_async(T *output, size_t beg, size_t end) const\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}\n\ntemplate<typename T>\nauto Buffer<T>::get_cuj_ptr() const" ()) ")" (type_qualifier) "const" (const) "const" (compound_statement) "{\n return buffer_;\n}" ({) "{" (return_statement) "return buffer_;" (return) "return" (identifier) "buffer_" (;) ";" (}) "}" (binary_expression) "template<typename T>\nBuffer<T>::operator CUdeviceptr()" (binary_expression) "template<typename T>\nBuffer<T" (binary_expression) "template<typename T>\nBuffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::operator" (:) ":" (:) ":" (identifier) "operator" (call_expression) "CUdeviceptr()" (identifier) "CUdeviceptr" (argument_list) "()" (() "(" ()) ")" (compound_statement) "{\n return get_device_ptr();\n}" ({) "{" (return_statement) "return get_device_ptr();" (return) "return" (call_expression) "get_device_ptr()" (identifier) "get_device_ptr" (argument_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (binary_expression) "template<typename T>\nT *Buffer<T>::get()" (binary_expression) "template<typename T>\nT *Buffer<T" (binary_expression) "template<typename T>\nT *Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (binary_expression) "T *Buffer" (identifier) "T" (*) "*" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "get()" (identifier) "get" (argument_list) "()" (() "(" ()) ")" (compound_statement) "{\n return buffer_;\n}" ({) "{" (return_statement) "return buffer_;" (return) "return" (identifier) "buffer_" (;) ";" (}) "}" (binary_expression) "template<typename T>\nconst T *Buffer<T>::get()" (binary_expression) "template<typename T>\nconst T *Buffer<T" (binary_expression) "template<typename T>\nconst T *Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (binary_expression) "const T *Buffer" (identifier) "const" (ERROR) "T" (identifier) "T" (*) "*" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "get()" (identifier) "get" (argument_list) "()" (() "(" ()) ")" (identifier) "const" (compound_statement) "{\n return buffer_;\n}" ({) "{" (return_statement) "return buffer_;" (return) "return" (identifier) "buffer_" (;) ";" (}) "}" (binary_expression) "template<typename T>\nCUdeviceptr Buffer<T>::get_device_ptr()" (binary_expression) "template<typename T>\nCUdeviceptr Buffer<T" (binary_expression) "template<typename T>\nCUdeviceptr" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "CUdeviceptr" (ERROR) "Buffer" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "get_device_ptr()" (identifier) "get_device_ptr" (argument_list) "()" (() "(" ()) ")" (compound_statement) "{\n return reinterpret_cast<CUdeviceptr>(buffer_);\n}" ({) "{" (return_statement) "return reinterpret_cast<CUdeviceptr>(buffer_);" (return) "return" (binary_expression) "reinterpret_cast<CUdeviceptr>(buffer_)" (binary_expression) "reinterpret_cast<CUdeviceptr" (identifier) "reinterpret_cast" (<) "<" (identifier) "CUdeviceptr" (>) ">" (parenthesized_expression) "(buffer_)" (() "(" (identifier) "buffer_" ()) ")" (;) ";" (}) "}" (binary_expression) "template<typename T>\ntemplate<typename U>\nU *Buffer<T>::as()" (binary_expression) "template<typename T>\ntemplate<typename U>\nU *Buffer<T" (binary_expression) "template<typename T>\ntemplate<typename U>\nU *Buffer" (binary_expression) "template<typename T>\ntemplate<typename" (binary_expression) "template<typename T>\ntemplate" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "U" (identifier) "U" (>) ">" (binary_expression) "U *Buffer" (identifier) "U" (*) "*" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "as()" (identifier) "as" (argument_list) "()" (() "(" ()) ")" (compound_statement) "{\n return reinterpret_cast<U *>(buffer_);\n}" ({) "{" (return_statement) "return reinterpret_cast<U *>(buffer_);" (return) "return" (binary_expression) "reinterpret_cast<U *>(buffer_)" (binary_expression) "reinterpret_cast<U" (identifier) "reinterpret_cast" (<) "<" (identifier) "U" (ERROR) "*" (*) "*" (>) ">" (parenthesized_expression) "(buffer_)" (() "(" (identifier) "buffer_" ()) ")" (;) ";" (}) "}" (binary_expression) "template<typename T>\ntemplate<typename U>\nconst U *Buffer<T>::as()" (binary_expression) "template<typename T>\ntemplate<typename U>\nconst U *Buffer<T" (binary_expression) "template<typename T>\ntemplate<typename U>\nconst U *Buffer" (binary_expression) "template<typename T>\ntemplate<typename" (binary_expression) "template<typename T>\ntemplate" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "U" (identifier) "U" (>) ">" (binary_expression) "const U *Buffer" (identifier) "const" (ERROR) "U" (identifier) "U" (*) "*" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "as()" (identifier) "as" (argument_list) "()" (() "(" ()) ")" (identifier) "const" (compound_statement) "{\n return reinterpret_cast<const U *>(buffer_);\n}" ({) "{" (return_statement) "return reinterpret_cast<const U *>(buffer_);" (return) "return" (binary_expression) "reinterpret_cast<const U *>(buffer_)" (binary_expression) "reinterpret_cast<const" (identifier) "reinterpret_cast" (<) "<" (identifier) "const" (ERROR) "U *" (identifier) "U" (*) "*" (>) ">" (parenthesized_expression) "(buffer_)" (() "(" (identifier) "buffer_" ()) ")" (;) ";" (}) "}" (binary_expression) "template<typename T>\nvoid Buffer<T>::clear(const T &val)" (binary_expression) "template<typename T>\nvoid Buffer<T" (binary_expression) "template<typename T>\nvoid Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (ERROR) "void" (identifier) "void" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "clear(const T &val)" (identifier) "clear" (argument_list) "(const T &val)" (() "(" (binary_expression) "const T &val" (identifier) "const" (ERROR) "T" (identifier) "T" (&) "&" (identifier) "val" ()) ")" (compound_statement) "{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n this->from_cpu(vals.data());\n}" ({) "{" (expression_statement) "assert(!is_empty());" (call_expression) "assert(!is_empty())" (identifier) "assert" (argument_list) "(!is_empty())" (() "(" (unary_expression) "!is_empty()" (!) "!" (call_expression) "is_empty()" (identifier) "is_empty" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) ";" (labeled_statement) "std::vector<T> vals(elem_count_, val);" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "vector<T> vals(elem_count_, val);" (binary_expression) "vector<T> vals(elem_count_, val)" (binary_expression) "vector<T" (identifier) "vector" (<) "<" (identifier) "T" (>) ">" (call_expression) "vals(elem_count_, val)" (identifier) "vals" (argument_list) "(elem_count_, val)" (() "(" (identifier) "elem_count_" (,) "," (identifier) "val" ()) ")" (;) ";" (expression_statement) "this->from_cpu(vals.data());" (call_expression) "this->from_cpu(vals.data())" (field_expression) "this->from_cpu" (identifier) "this" (->) "->" (field_identifier) "from_cpu" (argument_list) "(vals.data())" (() "(" (call_expression) "vals.data()" (field_expression) "vals.data" (identifier) "vals" (.) "." (field_identifier) "data" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) ";" (}) "}" (binary_expression) "template<typename T>\nvoid Buffer<T>::clear_async(const T &val)" (binary_expression) "template<typename T>\nvoid Buffer<T" (binary_expression) "template<typename T>\nvoid Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (ERROR) "void" (identifier) "void" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "clear_async(const T &val)" (identifier) "clear_async" (argument_list) "(const T &val)" (() "(" (binary_expression) "const T &val" (identifier) "const" (ERROR) "T" (identifier) "T" (&) "&" (identifier) "val" ()) ")" (compound_statement) "{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n from_cpu_async(vals.data());\n}" ({) "{" (expression_statement) "assert(!is_empty());" (call_expression) "assert(!is_empty())" (identifier) "assert" (argument_list) "(!is_empty())" (() "(" (unary_expression) "!is_empty()" (!) "!" (call_expression) "is_empty()" (identifier) "is_empty" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) ";" (labeled_statement) "std::vector<T> vals(elem_count_, val);" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "vector<T> vals(elem_count_, val);" (binary_expression) "vector<T> vals(elem_count_, val)" (binary_expression) "vector<T" (identifier) "vector" (<) "<" (identifier) "T" (>) ">" (call_expression) "vals(elem_count_, val)" (identifier) "vals" (argument_list) "(elem_count_, val)" (() "(" (identifier) "elem_count_" (,) "," (identifier) "val" ()) ")" (;) ";" (expression_statement) "from_cpu_async(vals.data());" (call_expression) "from_cpu_async(vals.data())" (identifier) "from_cpu_async" (argument_list) "(vals.data())" (() "(" (call_expression) "vals.data()" (field_expression) "vals.data" (identifier) "vals" (.) "." (field_identifier) "data" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) ";" (}) "}" (binary_expression) "template<typename T>\nvoid Buffer<T>::clear_bytes(uint8_t byte)" (binary_expression) "template<typename T>\nvoid Buffer<T" (binary_expression) "template<typename T>\nvoid Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (ERROR) "void" (identifier) "void" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "clear_bytes(uint8_t byte)" (identifier) "clear_bytes" (argument_list) "(uint8_t byte)" (() "(" (identifier) "uint8_t" (ERROR) "byte" (identifier) "byte" ()) ")" (compound_statement) "{\n assert(!is_empty());\n throw_on_error(cudaMemset(buffer_, byte, get_size_in_bytes()));\n}" ({) "{" (expression_statement) "assert(!is_empty());" (call_expression) "assert(!is_empty())" (identifier) "assert" (argument_list) "(!is_empty())" (() "(" (unary_expression) "!is_empty()" (!) "!" (call_expression) "is_empty()" (identifier) "is_empty" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) ";" (expression_statement) "throw_on_error(cudaMemset(buffer_, byte, get_size_in_bytes()));" (call_expression) "throw_on_error(cudaMemset(buffer_, byte, get_size_in_bytes()))" (identifier) "throw_on_error" (argument_list) "(cudaMemset(buffer_, byte, get_size_in_bytes()))" (() "(" (call_expression) "cudaMemset(buffer_, byte, get_size_in_bytes())" (identifier) "cudaMemset" (argument_list) "(buffer_, byte, get_size_in_bytes())" (() "(" (identifier) "buffer_" (,) "," (identifier) "byte" (,) "," (call_expression) "get_size_in_bytes()" (identifier) "get_size_in_bytes" (argument_list) "()" (() "(" ()) ")" ()) ")" ()) ")" (;) ";" (}) "}" (binary_expression) "template<typename T>\nvoid Buffer<T>::clear_bytes_async(uint8_t byte)" (binary_expression) "template<typename T>\nvoid Buffer<T" (binary_expression) "template<typename T>\nvoid Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (ERROR) "void" (identifier) "void" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "clear_bytes_async(uint8_t byte)" (identifier) "clear_bytes_async" (argument_list) "(uint8_t byte)" (() "(" (identifier) "uint8_t" (ERROR) "byte" (identifier) "byte" ()) ")" (compound_statement) "{\n assert(!is_empty());\n throw_on_error(cudaMemsetAsync(buffer_, byte, get_size_in_bytes()));\n}" ({) "{" (expression_statement) "assert(!is_empty());" (call_expression) "assert(!is_empty())" (identifier) "assert" (argument_list) "(!is_empty())" (() "(" (unary_expression) "!is_empty()" (!) "!" (call_expression) "is_empty()" (identifier) "is_empty" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) ";" (expression_statement) "throw_on_error(cudaMemsetAsync(buffer_, byte, get_size_in_bytes()));" (call_expression) "throw_on_error(cudaMemsetAsync(buffer_, byte, get_size_in_bytes()))" (identifier) "throw_on_error" (argument_list) "(cudaMemsetAsync(buffer_, byte, get_size_in_bytes()))" (() "(" (call_expression) "cudaMemsetAsync(buffer_, byte, get_size_in_bytes())" (identifier) "cudaMemsetAsync" (argument_list) "(buffer_, byte, get_size_in_bytes())" (() "(" (identifier) "buffer_" (,) "," (identifier) "byte" (,) "," (call_expression) "get_size_in_bytes()" (identifier) "get_size_in_bytes" (argument_list) "()" (() "(" ()) ")" ()) ")" ()) ")" (;) ";" (}) "}" (binary_expression) "template<typename T>\nvoid Buffer<T>::from_cpu(const T *cpu_data, size_t beg, size_t end)" (binary_expression) "template<typename T>\nvoid Buffer<T" (binary_expression) "template<typename T>\nvoid Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (ERROR) "void" (identifier) "void" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "from_cpu(const T *cpu_data, size_t beg, size_t end)" (identifier) "from_cpu" (argument_list) "(const T *cpu_data, size_t beg, size_t end)" (() "(" (binary_expression) "const T *cpu_data" (identifier) "const" (ERROR) "T" (identifier) "T" (*) "*" (identifier) "cpu_data" (,) "," (identifier) "size_t" (ERROR) "beg" (identifier) "beg" (,) "," (identifier) "size_t" (ERROR) "end" (identifier) "end" ()) ")" (compound_statement) "{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}" ({) "{" (if_statement) "if(end <= beg)\n end = elem_count_;" (if) "if" (parenthesized_expression) "(end <= beg)" (() "(" (binary_expression) "end <= beg" (identifier) "end" (<=) "<=" (identifier) "beg" ()) ")" (expression_statement) "end = elem_count_;" (assignment_expression) "end = elem_count_" (identifier) "end" (=) "=" (identifier) "elem_count_" (;) ";" (expression_statement) "assert(beg < end);" (call_expression) "assert(beg < end)" (identifier) "assert" (argument_list) "(beg < end)" (() "(" (binary_expression) "beg < end" (identifier) "beg" (<) "<" (identifier) "end" ()) ")" (;) ";" (declaration) "const size_t bytes = sizeof(T) * (end - beg);" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (init_declarator) "bytes = sizeof(T) * (end - beg)" (identifier) "bytes" (=) "=" (binary_expression) "sizeof(T) * (end - beg)" (sizeof_expression) "sizeof(T)" (sizeof) "sizeof" (parenthesized_expression) "(T)" (() "(" (identifier) "T" ()) ")" (*) "*" (parenthesized_expression) "(end - beg)" (() "(" (binary_expression) "end - beg" (identifier) "end" (-) "-" (identifier) "beg" ()) ")" (;) ";" (expression_statement) "throw_on_error(cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));" (call_expression) "throw_on_error(cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice))" (identifier) "throw_on_error" (argument_list) "(cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice))" (() "(" (call_expression) "cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice)" (identifier) "cudaMemcpy" (argument_list) "(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice)" (() "(" (binary_expression) "buffer_ + beg" (identifier) "buffer_" (+) "+" (identifier) "beg" (,) "," (identifier) "cpu_data" (,) "," (identifier) "bytes" (,) "," (identifier) "cudaMemcpyHostToDevice" ()) ")" ()) ")" (;) ";" (}) "}" (binary_expression) "template<typename T>\nvoid Buffer<T>::from_cpu_async(const T *cpu_data, size_t beg, size_t end)" (binary_expression) "template<typename T>\nvoid Buffer<T" (binary_expression) "template<typename T>\nvoid Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (ERROR) "void" (identifier) "void" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "from_cpu_async(const T *cpu_data, size_t beg, size_t end)" (identifier) "from_cpu_async" (argument_list) "(const T *cpu_data, size_t beg, size_t end)" (() "(" (binary_expression) "const T *cpu_data" (identifier) "const" (ERROR) "T" (identifier) "T" (*) "*" (identifier) "cpu_data" (,) "," (identifier) "size_t" (ERROR) "beg" (identifier) "beg" (,) "," (identifier) "size_t" (ERROR) "end" (identifier) "end" ()) ")" (compound_statement) "{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}" ({) "{" (if_statement) "if(end <= beg)\n end = elem_count_;" (if) "if" (parenthesized_expression) "(end <= beg)" (() "(" (binary_expression) "end <= beg" (identifier) "end" (<=) "<=" (identifier) "beg" ()) ")" (expression_statement) "end = elem_count_;" (assignment_expression) "end = elem_count_" (identifier) "end" (=) "=" (identifier) "elem_count_" (;) ";" (expression_statement) "assert(beg < end);" (call_expression) "assert(beg < end)" (identifier) "assert" (argument_list) "(beg < end)" (() "(" (binary_expression) "beg < end" (identifier) "beg" (<) "<" (identifier) "end" ()) ")" (;) ";" (declaration) "const size_t bytes = sizeof(T) * (end - beg);" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (init_declarator) "bytes = sizeof(T) * (end - beg)" (identifier) "bytes" (=) "=" (binary_expression) "sizeof(T) * (end - beg)" (sizeof_expression) "sizeof(T)" (sizeof) "sizeof" (parenthesized_expression) "(T)" (() "(" (identifier) "T" ()) ")" (*) "*" (parenthesized_expression) "(end - beg)" (() "(" (binary_expression) "end - beg" (identifier) "end" (-) "-" (identifier) "beg" ()) ")" (;) ";" (expression_statement) "throw_on_error(cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));" (call_expression) "throw_on_error(cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice))" (identifier) "throw_on_error" (argument_list) "(cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice))" (() "(" (call_expression) "cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice)" (identifier) "cudaMemcpyAsync" (argument_list) "(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice)" (() "(" (binary_expression) "buffer_ + beg" (identifier) "buffer_" (+) "+" (identifier) "beg" (,) "," (identifier) "cpu_data" (,) "," (identifier) "bytes" (,) "," (identifier) "cudaMemcpyHostToDevice" ()) ")" ()) ")" (;) ";" (}) "}" (binary_expression) "template<typename T>\nvoid Buffer<T>::to_cpu(T *output, size_t beg, size_t end)" (binary_expression) "template<typename T>\nvoid Buffer<T" (binary_expression) "template<typename T>\nvoid Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (ERROR) "void" (identifier) "void" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "to_cpu(T *output, size_t beg, size_t end)" (identifier) "to_cpu" (argument_list) "(T *output, size_t beg, size_t end)" (() "(" (binary_expression) "T *output" (identifier) "T" (*) "*" (identifier) "output" (,) "," (identifier) "size_t" (ERROR) "beg" (identifier) "beg" (,) "," (identifier) "size_t" (ERROR) "end" (identifier) "end" ()) ")" (identifier) "const" (compound_statement) "{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}" ({) "{" (if_statement) "if(end <= beg)\n end = elem_count_;" (if) "if" (parenthesized_expression) "(end <= beg)" (() "(" (binary_expression) "end <= beg" (identifier) "end" (<=) "<=" (identifier) "beg" ()) ")" (expression_statement) "end = elem_count_;" (assignment_expression) "end = elem_count_" (identifier) "end" (=) "=" (identifier) "elem_count_" (;) ";" (expression_statement) "assert(beg < end);" (call_expression) "assert(beg < end)" (identifier) "assert" (argument_list) "(beg < end)" (() "(" (binary_expression) "beg < end" (identifier) "beg" (<) "<" (identifier) "end" ()) ")" (;) ";" (declaration) "const size_t bytes = sizeof(T) * (end - beg);" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (init_declarator) "bytes = sizeof(T) * (end - beg)" (identifier) "bytes" (=) "=" (binary_expression) "sizeof(T) * (end - beg)" (sizeof_expression) "sizeof(T)" (sizeof) "sizeof" (parenthesized_expression) "(T)" (() "(" (identifier) "T" ()) ")" (*) "*" (parenthesized_expression) "(end - beg)" (() "(" (binary_expression) "end - beg" (identifier) "end" (-) "-" (identifier) "beg" ()) ")" (;) ";" (expression_statement) "throw_on_error(cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));" (call_expression) "throw_on_error(cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost))" (identifier) "throw_on_error" (argument_list) "(cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost))" (() "(" (call_expression) "cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost)" (identifier) "cudaMemcpy" (argument_list) "(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost)" (() "(" (identifier) "output" (,) "," (binary_expression) "buffer_ + beg" (identifier) "buffer_" (+) "+" (identifier) "beg" (,) "," (identifier) "bytes" (,) "," (identifier) "cudaMemcpyDeviceToHost" ()) ")" ()) ")" (;) ";" (}) "}" (binary_expression) "template<typename T>\nvoid Buffer<T>::to_cpu_async(T *output, size_t beg, size_t end)" (binary_expression) "template<typename T>\nvoid Buffer<T" (binary_expression) "template<typename T>\nvoid Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (ERROR) "void" (identifier) "void" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "to_cpu_async(T *output, size_t beg, size_t end)" (identifier) "to_cpu_async" (argument_list) "(T *output, size_t beg, size_t end)" (() "(" (binary_expression) "T *output" (identifier) "T" (*) "*" (identifier) "output" (,) "," (identifier) "size_t" (ERROR) "beg" (identifier) "beg" (,) "," (identifier) "size_t" (ERROR) "end" (identifier) "end" ()) ")" (identifier) "const" (compound_statement) "{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}" ({) "{" (if_statement) "if(end <= beg)\n end = elem_count_;" (if) "if" (parenthesized_expression) "(end <= beg)" (() "(" (binary_expression) "end <= beg" (identifier) "end" (<=) "<=" (identifier) "beg" ()) ")" (expression_statement) "end = elem_count_;" (assignment_expression) "end = elem_count_" (identifier) "end" (=) "=" (identifier) "elem_count_" (;) ";" (expression_statement) "assert(beg < end);" (call_expression) "assert(beg < end)" (identifier) "assert" (argument_list) "(beg < end)" (() "(" (binary_expression) "beg < end" (identifier) "beg" (<) "<" (identifier) "end" ()) ")" (;) ";" (declaration) "const size_t bytes = sizeof(T) * (end - beg);" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (init_declarator) "bytes = sizeof(T) * (end - beg)" (identifier) "bytes" (=) "=" (binary_expression) "sizeof(T) * (end - beg)" (sizeof_expression) "sizeof(T)" (sizeof) "sizeof" (parenthesized_expression) "(T)" (() "(" (identifier) "T" ()) ")" (*) "*" (parenthesized_expression) "(end - beg)" (() "(" (binary_expression) "end - beg" (identifier) "end" (-) "-" (identifier) "beg" ()) ")" (;) ";" (expression_statement) "throw_on_error(cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));" (call_expression) "throw_on_error(cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost))" (identifier) "throw_on_error" (argument_list) "(cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost))" (() "(" (call_expression) "cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost)" (identifier) "cudaMemcpyAsync" (argument_list) "(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost)" (() "(" (identifier) "output" (,) "," (binary_expression) "buffer_ + beg" (identifier) "buffer_" (+) "+" (identifier) "beg" (,) "," (identifier) "bytes" (,) "," (identifier) "cudaMemcpyDeviceToHost" ()) ")" ()) ")" (;) ";" (}) "}" (binary_expression) "template<typename T>\nauto Buffer<T>::get_cuj_ptr()" (binary_expression) "template<typename T>\nauto Buffer<T" (binary_expression) "template<typename T>\nauto Buffer" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (ERROR) "auto" (identifier) "auto" (identifier) "Buffer" (<) "<" (identifier) "T" (>) ">" (ERROR) "::" (:) ":" (:) ":" (call_expression) "get_cuj_ptr()" (identifier) "get_cuj_ptr" (argument_list) "()" (() "(" ()) ")" (identifier) "const" (compound_statement) "{\n return cuj::import_pointer(buffer_);\n}" ({) "{" (return_statement) "return cuj::import_pointer(buffer_);" (return) "return" (ERROR) "cuj::" (identifier) "cuj" (:) ":" (:) ":" (call_expression) "import_pointer(buffer_)" (identifier) "import_pointer" (argument_list) "(buffer_)" (() "(" (identifier) "buffer_" ()) ")" (;) ";" (}) "}" (identifier) "BTRC_CUDA_END"
2,303
150
{"language": "c", "success": true, "metadata": {"lines": 248, "avg_line_length": 23.16, "nodes": 1491, "errors": 0, "source_hash": "1cdbe9a0a4bbecaf81ccf87a8852044322593a5eabca4f654ee780cdd18132e7", "categorized_nodes": 969}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#pragma once\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#pragma", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "once", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 12}}, {"id": 3, "type": "preproc_include", "text": "#include <cassert>\n", "parent": null, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<cassert>", "parent": 3, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 18}}, {"id": 6, "type": "preproc_include", "text": "#include <span>\n", "parent": null, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<span>", "parent": 6, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 15}}, {"id": 9, "type": "preproc_include", "text": "#include <vector>\n", "parent": null, "children": [10, 11], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<vector>", "parent": 9, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 17}}, {"id": 12, "type": "preproc_include", "text": "#include <cuda.h>\n", "parent": null, "children": [13, 14], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 8}}, {"id": 14, "type": "system_lib_string", "text": "<cuda.h>", "parent": 12, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 17}}, {"id": 15, "type": "preproc_include", "text": "#include <cuda_runtime.h>\n", "parent": null, "children": [16, 17], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 8}}, {"id": 17, "type": "system_lib_string", "text": "<cuda_runtime.h>", "parent": 15, "children": [], "start_point": {"row": 7, "column": 9}, "end_point": {"row": 7, "column": 25}}, {"id": 18, "type": "preproc_include", "text": "#include <cuj.h>\n", "parent": null, "children": [19, 20], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 8}}, {"id": 20, "type": "system_lib_string", "text": "<cuj.h>", "parent": 18, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 16}}, {"id": 21, "type": "preproc_include", "text": "#include <btrc/utils/cuda/error.h>\n", "parent": null, "children": [22, 23], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 11, "column": 0}}, {"id": 22, "type": "#include", "text": "#include", "parent": 21, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 8}}, {"id": 23, "type": "system_lib_string", "text": "<btrc/utils/cuda/error.h>", "parent": 21, "children": [], "start_point": {"row": 10, "column": 9}, "end_point": {"row": 10, "column": 34}}, {"id": 24, "type": "preproc_include", "text": "#include <btrc/utils/scope_guard.h>\n", "parent": null, "children": [25, 26], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 12, "column": 0}}, {"id": 25, "type": "#include", "text": "#include", "parent": 24, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 8}}, {"id": 26, "type": "system_lib_string", "text": "<btrc/utils/scope_guard.h>", "parent": 24, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 35}}, {"id": 27, "type": "preproc_include", "text": "#include <btrc/utils/uncopyable.h>\n", "parent": null, "children": [28, 29], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 13, "column": 0}}, {"id": 28, "type": "#include", "text": "#include", "parent": 27, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 8}}, {"id": 29, "type": "system_lib_string", "text": "<btrc/utils/uncopyable.h>", "parent": 27, "children": [], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 34}}, {"id": 30, "type": "declaration", "text": "BTRC_CUDA_BEGIN\n\ntemplate<typename T = char>\nclass", "parent": null, "children": [31, 32], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 17, "column": 5}}, {"id": 31, "type": "type_identifier", "text": "BTRC_CUDA_BEGIN", "parent": 30, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 15}}, {"id": 32, "type": "init_declarator", "text": "template<typename T = char>\nclass", "parent": 30, "children": [33, 34, 38, 39], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 17, "column": 5}}, {"id": 33, "type": "identifier", "text": "template", "parent": 32, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 8}}, {"id": 34, "type": "ERROR", "text": "<typename T", "parent": 32, "children": [35, 36, 37], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 19}}, {"id": 35, "type": "<", "text": "<", "parent": 34, "children": [], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 9}}, {"id": 36, "type": "identifier", "text": "typename", "parent": 34, "children": [], "start_point": {"row": 16, "column": 9}, "end_point": {"row": 16, "column": 17}}, {"id": 37, "type": "identifier", "text": "T", "parent": 34, "children": [], "start_point": {"row": 16, "column": 18}, "end_point": {"row": 16, "column": 19}}, {"id": 38, "type": "=", "text": "=", "parent": 32, "children": [], "start_point": {"row": 16, "column": 20}, "end_point": {"row": 16, "column": 21}}, {"id": 39, "type": "binary_expression", "text": "char>\nclass", "parent": 32, "children": [40, 41], "start_point": {"row": 16, "column": 22}, "end_point": {"row": 17, "column": 5}}, {"id": 40, "type": "identifier", "text": "char", "parent": 39, "children": [], "start_point": {"row": 16, "column": 22}, "end_point": {"row": 16, "column": 26}}, {"id": 41, "type": ">", "text": ">", "parent": 39, "children": [], "start_point": {"row": 16, "column": 26}, "end_point": {"row": 16, "column": 27}}, {"id": 42, "type": "labeled_statement", "text": "Buffer : public Uncopyable\n{\npublic:\n\n Buffer();\n\n explicit Buffer(size_t elem_count, const T *cpu_data = nullptr);\n\n explicit Buffer(std::span<const T> data);\n\n Buffer(Buffer &&other) noexcept;\n\n Buffer &operator=(Buffer &&other) noexcept;\n\n ~Buffer();\n\n void initialize(size_t elem_count, const T *cpu_data = nullptr);\n\n void destroy();\n\n void swap(Buffer &other) noexcept;\n\n operator bool() const;\n\n bool is_empty() const;\n\n size_t get_size() const;\n\n size_t get_size_in_bytes() const;\n\n operator T *();\n\n operator const T *() const;\n\n operator CUdeviceptr();\n\n T *get();\n\n const T *get() const;\n\n CUdeviceptr get_device_ptr();\n\n template<typename U>\n U *as();\n\n template<typename U>\n const U *as() const;\n\n void clear(const T &val);\n\n void clear_async(const T &val);\n\n void clear_bytes(uint8_t byte);\n\n void clear_bytes_async(uint8_t byte);\n\n void to_cpu(T *output, size_t beg = 0, size_t end = 0) const;\n\n void to_cpu_async(T *output, size_t beg = 0, size_t end = 0) const;\n\n void from_cpu(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n void from_cpu_async(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n auto get_cuj_ptr() const;\n\nprivate:\n\n size_t elem_count_;\n T *buffer_;\n};\n\n// ========================== impl ==========================\n\ntemplate<typename T>\nBuffer<T>::Buffer()\n : elem_count_(0), buffer_(nullptr)\n{\n \n}\n\ntemplate<typename T>\nBuffer<T>::Buffer(size_t elem_count, const T *cpu_data)\n : Buffer()\n{\n if(elem_count)\n initialize(elem_count, cpu_data);\n}", "parent": null, "children": [43, 44], "start_point": {"row": 17, "column": 6}, "end_point": {"row": 104, "column": 1}}, {"id": 43, "type": "statement_identifier", "text": "Buffer", "parent": 42, "children": [], "start_point": {"row": 17, "column": 6}, "end_point": {"row": 17, "column": 12}}, {"id": 44, "type": "ERROR", "text": "public Uncopyable", "parent": 42, "children": [45], "start_point": {"row": 17, "column": 15}, "end_point": {"row": 17, "column": 32}}, {"id": 45, "type": "identifier", "text": "Uncopyable", "parent": 44, "children": [], "start_point": {"row": 17, "column": 22}, "end_point": {"row": 17, "column": 32}}, {"id": 46, "type": "labeled_statement", "text": "public:\n\n Buffer();", "parent": 42, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 21, "column": 13}}, {"id": 47, "type": "call_expression", "text": "Buffer()", "parent": 46, "children": [48, 49], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 21, "column": 12}}, {"id": 48, "type": "identifier", "text": "Buffer", "parent": 47, "children": [], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 21, "column": 10}}, {"id": 49, "type": "argument_list", "text": "()", "parent": 47, "children": [], "start_point": {"row": 21, "column": 10}, "end_point": {"row": 21, "column": 12}}, {"id": 50, "type": "declaration", "text": "explicit Buffer(size_t elem_count, const T *cpu_data = nullptr);", "parent": 42, "children": [51, 52], "start_point": {"row": 23, "column": 4}, "end_point": {"row": 23, "column": 68}}, {"id": 51, "type": "type_identifier", "text": "explicit", "parent": 50, "children": [], "start_point": {"row": 23, "column": 4}, "end_point": {"row": 23, "column": 12}}, {"id": 52, "type": "init_declarator", "text": "Buffer(size_t elem_count, const T *cpu_data = nullptr", "parent": 50, "children": [53, 64, 65], "start_point": {"row": 23, "column": 13}, "end_point": {"row": 23, "column": 66}}, {"id": 53, "type": "function_declarator", "text": "Buffer(size_t elem_count, const T *cpu_data", "parent": 52, "children": [54, 55], "start_point": {"row": 23, "column": 13}, "end_point": {"row": 23, "column": 56}}, {"id": 54, "type": "identifier", "text": "Buffer", "parent": 53, "children": [], "start_point": {"row": 23, "column": 13}, "end_point": {"row": 23, "column": 19}}, {"id": 55, "type": "parameter_list", "text": "(size_t elem_count, const T *cpu_data", "parent": 53, "children": [56, 59], "start_point": {"row": 23, "column": 19}, "end_point": {"row": 23, "column": 56}}, {"id": 56, "type": "parameter_declaration", "text": "size_t elem_count", "parent": 55, "children": [57, 58], "start_point": {"row": 23, "column": 20}, "end_point": {"row": 23, "column": 37}}, {"id": 57, "type": "primitive_type", "text": "size_t", "parent": 56, "children": [], "start_point": {"row": 23, "column": 20}, "end_point": {"row": 23, "column": 26}}, {"id": 58, "type": "identifier", "text": "elem_count", "parent": 56, "children": [], "start_point": {"row": 23, "column": 27}, "end_point": {"row": 23, "column": 37}}, {"id": 59, "type": "parameter_declaration", "text": "const T *cpu_data", "parent": 55, "children": [60, 61], "start_point": {"row": 23, "column": 39}, "end_point": {"row": 23, "column": 56}}, {"id": 60, "type": "type_identifier", "text": "T", "parent": 59, "children": [], "start_point": {"row": 23, "column": 45}, "end_point": {"row": 23, "column": 46}}, {"id": 61, "type": "pointer_declarator", "text": "*cpu_data", "parent": 59, "children": [62, 63], "start_point": {"row": 23, "column": 47}, "end_point": {"row": 23, "column": 56}}, {"id": 62, "type": "*", "text": "*", "parent": 61, "children": [], "start_point": {"row": 23, "column": 47}, "end_point": {"row": 23, "column": 48}}, {"id": 63, "type": "identifier", "text": "cpu_data", "parent": 61, "children": [], "start_point": {"row": 23, "column": 48}, "end_point": {"row": 23, "column": 56}}, {"id": 64, "type": "=", "text": "=", "parent": 52, "children": [], "start_point": {"row": 23, "column": 57}, "end_point": {"row": 23, "column": 58}}, {"id": 65, "type": "null", "text": "nullptr", "parent": 52, "children": [66], "start_point": {"row": 23, "column": 59}, "end_point": {"row": 23, "column": 66}}, {"id": 66, "type": "nullptr", "text": "nullptr", "parent": 65, "children": [], "start_point": {"row": 23, "column": 59}, "end_point": {"row": 23, "column": 66}}, {"id": 67, "type": "declaration", "text": "explicit Buffer(std::span<const T> data);", "parent": 42, "children": [68, 69], "start_point": {"row": 25, "column": 4}, "end_point": {"row": 25, "column": 45}}, {"id": 68, "type": "type_identifier", "text": "explicit", "parent": 67, "children": [], "start_point": {"row": 25, "column": 4}, "end_point": {"row": 25, "column": 12}}, {"id": 69, "type": "function_declarator", "text": "Buffer(std::span<const T> data)", "parent": 67, "children": [70, 71], "start_point": {"row": 25, "column": 13}, "end_point": {"row": 25, "column": 44}}, {"id": 70, "type": "identifier", "text": "Buffer", "parent": 69, "children": [], "start_point": {"row": 25, "column": 13}, "end_point": {"row": 25, "column": 19}}, {"id": 71, "type": "parameter_list", "text": "(std::span<const T> data)", "parent": 69, "children": [72], "start_point": {"row": 25, "column": 19}, "end_point": {"row": 25, "column": 44}}, {"id": 72, "type": "parameter_declaration", "text": "std::span<const T> data", "parent": 71, "children": [73, 74, 79], "start_point": {"row": 25, "column": 20}, "end_point": {"row": 25, "column": 43}}, {"id": 73, "type": "type_identifier", "text": "std", "parent": 72, "children": [], "start_point": {"row": 25, "column": 20}, "end_point": {"row": 25, "column": 23}}, {"id": 74, "type": "ERROR", "text": "::span<const T>", "parent": 72, "children": [75, 76, 77, 78], "start_point": {"row": 25, "column": 23}, "end_point": {"row": 25, "column": 38}}, {"id": 75, "type": "identifier", "text": "span", "parent": 74, "children": [], "start_point": {"row": 25, "column": 25}, "end_point": {"row": 25, "column": 29}}, {"id": 76, "type": "<", "text": "<", "parent": 74, "children": [], "start_point": {"row": 25, "column": 29}, "end_point": {"row": 25, "column": 30}}, {"id": 77, "type": "identifier", "text": "T", "parent": 74, "children": [], "start_point": {"row": 25, "column": 36}, "end_point": {"row": 25, "column": 37}}, {"id": 78, "type": ">", "text": ">", "parent": 74, "children": [], "start_point": {"row": 25, "column": 37}, "end_point": {"row": 25, "column": 38}}, {"id": 79, "type": "identifier", "text": "data", "parent": 72, "children": [], "start_point": {"row": 25, "column": 39}, "end_point": {"row": 25, "column": 43}}, {"id": 80, "type": "call_expression", "text": "Buffer(Buffer &&other)", "parent": 42, "children": [81, 82], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 26}}, {"id": 81, "type": "identifier", "text": "Buffer", "parent": 80, "children": [], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 10}}, {"id": 82, "type": "argument_list", "text": "(Buffer &&other)", "parent": 80, "children": [83], "start_point": {"row": 27, "column": 10}, "end_point": {"row": 27, "column": 26}}, {"id": 83, "type": "binary_expression", "text": "Buffer &&other", "parent": 82, "children": [84, 85, 86], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 25}}, {"id": 84, "type": "identifier", "text": "Buffer", "parent": 83, "children": [], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 17}}, {"id": 85, "type": "&&", "text": "&&", "parent": 83, "children": [], "start_point": {"row": 27, "column": 18}, "end_point": {"row": 27, "column": 20}}, {"id": 86, "type": "identifier", "text": "other", "parent": 83, "children": [], "start_point": {"row": 27, "column": 20}, "end_point": {"row": 27, "column": 25}}, {"id": 87, "type": "ERROR", "text": "noexcept", "parent": 42, "children": [88], "start_point": {"row": 27, "column": 27}, "end_point": {"row": 27, "column": 35}}, {"id": 88, "type": "identifier", "text": "noexcept", "parent": 87, "children": [], "start_point": {"row": 27, "column": 27}, "end_point": {"row": 27, "column": 35}}, {"id": 89, "type": "binary_expression", "text": "Buffer &operator=(Buffer &&other)", "parent": 42, "children": [90, 91], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 37}}, {"id": 90, "type": "identifier", "text": "Buffer", "parent": 89, "children": [], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 10}}, {"id": 91, "type": "assignment_expression", "text": "operator=(Buffer &&other)", "parent": 89, "children": [92, 93, 94], "start_point": {"row": 29, "column": 12}, "end_point": {"row": 29, "column": 37}}, {"id": 92, "type": "identifier", "text": "operator", "parent": 91, "children": [], "start_point": {"row": 29, "column": 12}, "end_point": {"row": 29, "column": 20}}, {"id": 93, "type": "=", "text": "=", "parent": 91, "children": [], "start_point": {"row": 29, "column": 20}, "end_point": {"row": 29, "column": 21}}, {"id": 94, "type": "parenthesized_expression", "text": "(Buffer &&other)", "parent": 91, "children": [95], "start_point": {"row": 29, "column": 21}, "end_point": {"row": 29, "column": 37}}, {"id": 95, "type": "binary_expression", "text": "Buffer &&other", "parent": 94, "children": [96, 97, 98], "start_point": {"row": 29, "column": 22}, "end_point": {"row": 29, "column": 36}}, {"id": 96, "type": "identifier", "text": "Buffer", "parent": 95, "children": [], "start_point": {"row": 29, "column": 22}, "end_point": {"row": 29, "column": 28}}, {"id": 97, "type": "&&", "text": "&&", "parent": 95, "children": [], "start_point": {"row": 29, "column": 29}, "end_point": {"row": 29, "column": 31}}, {"id": 98, "type": "identifier", "text": "other", "parent": 95, "children": [], "start_point": {"row": 29, "column": 31}, "end_point": {"row": 29, "column": 36}}, {"id": 99, "type": "ERROR", "text": "noexcept", "parent": 42, "children": [100], "start_point": {"row": 29, "column": 38}, "end_point": {"row": 29, "column": 46}}, {"id": 100, "type": "identifier", "text": "noexcept", "parent": 99, "children": [], "start_point": {"row": 29, "column": 38}, "end_point": {"row": 29, "column": 46}}, {"id": 101, "type": "unary_expression", "text": "~Buffer()", "parent": 42, "children": [102, 103], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 13}}, {"id": 102, "type": "~", "text": "~", "parent": 101, "children": [], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 5}}, {"id": 103, "type": "call_expression", "text": "Buffer()", "parent": 101, "children": [104, 105], "start_point": {"row": 31, "column": 5}, "end_point": {"row": 31, "column": 13}}, {"id": 104, "type": "identifier", "text": "Buffer", "parent": 103, "children": [], "start_point": {"row": 31, "column": 5}, "end_point": {"row": 31, "column": 11}}, {"id": 105, "type": "argument_list", "text": "()", "parent": 103, "children": [], "start_point": {"row": 31, "column": 11}, "end_point": {"row": 31, "column": 13}}, {"id": 106, "type": "declaration", "text": "void initialize(size_t elem_count, const T *cpu_data = nullptr);", "parent": 42, "children": [107, 108], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 68}}, {"id": 107, "type": "primitive_type", "text": "void", "parent": 106, "children": [], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 8}}, {"id": 108, "type": "init_declarator", "text": "initialize(size_t elem_count, const T *cpu_data = nullptr", "parent": 106, "children": [109, 120, 121], "start_point": {"row": 33, "column": 9}, "end_point": {"row": 33, "column": 66}}, {"id": 109, "type": "function_declarator", "text": "initialize(size_t elem_count, const T *cpu_data", "parent": 108, "children": [110, 111], "start_point": {"row": 33, "column": 9}, "end_point": {"row": 33, "column": 56}}, {"id": 110, "type": "identifier", "text": "initialize", "parent": 109, "children": [], "start_point": {"row": 33, "column": 9}, "end_point": {"row": 33, "column": 19}}, {"id": 111, "type": "parameter_list", "text": "(size_t elem_count, const T *cpu_data", "parent": 109, "children": [112, 115], "start_point": {"row": 33, "column": 19}, "end_point": {"row": 33, "column": 56}}, {"id": 112, "type": "parameter_declaration", "text": "size_t elem_count", "parent": 111, "children": [113, 114], "start_point": {"row": 33, "column": 20}, "end_point": {"row": 33, "column": 37}}, {"id": 113, "type": "primitive_type", "text": "size_t", "parent": 112, "children": [], "start_point": {"row": 33, "column": 20}, "end_point": {"row": 33, "column": 26}}, {"id": 114, "type": "identifier", "text": "elem_count", "parent": 112, "children": [], "start_point": {"row": 33, "column": 27}, "end_point": {"row": 33, "column": 37}}, {"id": 115, "type": "parameter_declaration", "text": "const T *cpu_data", "parent": 111, "children": [116, 117], "start_point": {"row": 33, "column": 39}, "end_point": {"row": 33, "column": 56}}, {"id": 116, "type": "type_identifier", "text": "T", "parent": 115, "children": [], "start_point": {"row": 33, "column": 45}, "end_point": {"row": 33, "column": 46}}, {"id": 117, "type": "pointer_declarator", "text": "*cpu_data", "parent": 115, "children": [118, 119], "start_point": {"row": 33, "column": 47}, "end_point": {"row": 33, "column": 56}}, {"id": 118, "type": "*", "text": "*", "parent": 117, "children": [], "start_point": {"row": 33, "column": 47}, "end_point": {"row": 33, "column": 48}}, {"id": 119, "type": "identifier", "text": "cpu_data", "parent": 117, "children": [], "start_point": {"row": 33, "column": 48}, "end_point": {"row": 33, "column": 56}}, {"id": 120, "type": "=", "text": "=", "parent": 108, "children": [], "start_point": {"row": 33, "column": 57}, "end_point": {"row": 33, "column": 58}}, {"id": 121, "type": "null", "text": "nullptr", "parent": 108, "children": [122], "start_point": {"row": 33, "column": 59}, "end_point": {"row": 33, "column": 66}}, {"id": 122, "type": "nullptr", "text": "nullptr", "parent": 121, "children": [], "start_point": {"row": 33, "column": 59}, "end_point": {"row": 33, "column": 66}}, {"id": 123, "type": "declaration", "text": "void destroy();", "parent": 42, "children": [124, 125], "start_point": {"row": 35, "column": 4}, "end_point": {"row": 35, "column": 19}}, {"id": 124, "type": "primitive_type", "text": "void", "parent": 123, "children": [], "start_point": {"row": 35, "column": 4}, "end_point": {"row": 35, "column": 8}}, {"id": 125, "type": "function_declarator", "text": "destroy()", "parent": 123, "children": [126, 127], "start_point": {"row": 35, "column": 9}, "end_point": {"row": 35, "column": 18}}, {"id": 126, "type": "identifier", "text": "destroy", "parent": 125, "children": [], "start_point": {"row": 35, "column": 9}, "end_point": {"row": 35, "column": 16}}, {"id": 127, "type": "parameter_list", "text": "()", "parent": 125, "children": [], "start_point": {"row": 35, "column": 16}, "end_point": {"row": 35, "column": 18}}, {"id": 128, "type": "ERROR", "text": "void swap(Buffer &other) noexcept", "parent": 42, "children": [129, 130], "start_point": {"row": 37, "column": 4}, "end_point": {"row": 37, "column": 37}}, {"id": 129, "type": "primitive_type", "text": "void", "parent": 128, "children": [], "start_point": {"row": 37, "column": 4}, "end_point": {"row": 37, "column": 8}}, {"id": 130, "type": "function_declarator", "text": "swap(Buffer &other) noexcept", "parent": 128, "children": [131, 132, 136], "start_point": {"row": 37, "column": 9}, "end_point": {"row": 37, "column": 37}}, {"id": 131, "type": "identifier", "text": "swap", "parent": 130, "children": [], "start_point": {"row": 37, "column": 9}, "end_point": {"row": 37, "column": 13}}, {"id": 132, "type": "parameter_list", "text": "(Buffer &other)", "parent": 130, "children": [133], "start_point": {"row": 37, "column": 13}, "end_point": {"row": 37, "column": 28}}, {"id": 133, "type": "parameter_declaration", "text": "Buffer &other", "parent": 132, "children": [134, 135], "start_point": {"row": 37, "column": 14}, "end_point": {"row": 37, "column": 27}}, {"id": 134, "type": "type_identifier", "text": "Buffer", "parent": 133, "children": [], "start_point": {"row": 37, "column": 14}, "end_point": {"row": 37, "column": 20}}, {"id": 135, "type": "identifier", "text": "other", "parent": 133, "children": [], "start_point": {"row": 37, "column": 22}, "end_point": {"row": 37, "column": 27}}, {"id": 136, "type": "identifier", "text": "noexcept", "parent": 130, "children": [], "start_point": {"row": 37, "column": 29}, "end_point": {"row": 37, "column": 37}}, {"id": 137, "type": "function_definition", "text": "operator bool() const;\n\n bool is_empty() const;\n\n size_t get_size() const;\n\n size_t get_size_in_bytes() const;\n\n operator T *();\n\n operator const T *() const;\n\n operator CUdeviceptr();\n\n T *get();\n\n const T *get() const;\n\n CUdeviceptr get_device_ptr();\n\n template<typename U>\n U *as();\n\n template<typename U>\n const U *as() const;\n\n void clear(const T &val);\n\n void clear_async(const T &val);\n\n void clear_bytes(uint8_t byte);\n\n void clear_bytes_async(uint8_t byte);\n\n void to_cpu(T *output, size_t beg = 0, size_t end = 0) const;\n\n void to_cpu_async(T *output, size_t beg = 0, size_t end = 0) const;\n\n void from_cpu(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n void from_cpu_async(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n auto get_cuj_ptr() const;\n\nprivate:\n\n size_t elem_count_;\n T *buffer_;\n};\n\n// ========================== impl ==========================\n\ntemplate<typename T>\nBuffer<T>::Buffer()\n : elem_count_(0), buffer_(nullptr)\n{\n \n}", "parent": 42, "children": [138, 139, 142, 162, 170, 175, 182, 189, 194, 206, 218, 226, 234, 242, 250, 271, 292, 312, 332, 342, 347, 348], "start_point": {"row": 39, "column": 4}, "end_point": {"row": 96, "column": 1}}, {"id": 138, "type": "type_identifier", "text": "operator", "parent": 137, "children": [], "start_point": {"row": 39, "column": 4}, "end_point": {"row": 39, "column": 12}}, {"id": 139, "type": "function_declarator", "text": "bool()", "parent": 137, "children": [140, 141], "start_point": {"row": 39, "column": 13}, "end_point": {"row": 39, "column": 19}}, {"id": 140, "type": "identifier", "text": "bool", "parent": 139, "children": [], "start_point": {"row": 39, "column": 13}, "end_point": {"row": 39, "column": 17}}, {"id": 141, "type": "parameter_list", "text": "()", "parent": 139, "children": [], "start_point": {"row": 39, "column": 17}, "end_point": {"row": 39, "column": 19}}, {"id": 142, "type": "declaration", "text": "const;\n\n bool is_empty() const;\n\n size_t get_size() const;\n\n size_t get_size_in_bytes() const;\n\n operator T *();", "parent": 137, "children": [143, 144, 158], "start_point": {"row": 39, "column": 20}, "end_point": {"row": 47, "column": 19}}, {"id": 143, "type": "primitive_type", "text": "bool", "parent": 142, "children": [], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 41, "column": 8}}, {"id": 144, "type": "ERROR", "text": "is_empty() const;\n\n size_t get_size() const;\n\n size_t get_size_in_bytes() const;\n\n operator T", "parent": 142, "children": [145, 148, 149, 152, 153, 156, 157], "start_point": {"row": 41, "column": 9}, "end_point": {"row": 47, "column": 14}}, {"id": 145, "type": "function_declarator", "text": "is_empty() const", "parent": 144, "children": [146, 147], "start_point": {"row": 41, "column": 9}, "end_point": {"row": 41, "column": 25}}, {"id": 146, "type": "identifier", "text": "is_empty", "parent": 145, "children": [], "start_point": {"row": 41, "column": 9}, "end_point": {"row": 41, "column": 17}}, {"id": 147, "type": "parameter_list", "text": "()", "parent": 145, "children": [], "start_point": {"row": 41, "column": 17}, "end_point": {"row": 41, "column": 19}}, {"id": 148, "type": "primitive_type", "text": "size_t", "parent": 144, "children": [], "start_point": {"row": 43, "column": 4}, "end_point": {"row": 43, "column": 10}}, {"id": 149, "type": "function_declarator", "text": "get_size() const", "parent": 144, "children": [150, 151], "start_point": {"row": 43, "column": 11}, "end_point": {"row": 43, "column": 27}}, {"id": 150, "type": "identifier", "text": "get_size", "parent": 149, "children": [], "start_point": {"row": 43, "column": 11}, "end_point": {"row": 43, "column": 19}}, {"id": 151, "type": "parameter_list", "text": "()", "parent": 149, "children": [], "start_point": {"row": 43, "column": 19}, "end_point": {"row": 43, "column": 21}}, {"id": 152, "type": "primitive_type", "text": "size_t", "parent": 144, "children": [], "start_point": {"row": 45, "column": 4}, "end_point": {"row": 45, "column": 10}}, {"id": 153, "type": "function_declarator", "text": "get_size_in_bytes() const", "parent": 144, "children": [154, 155], "start_point": {"row": 45, "column": 11}, "end_point": {"row": 45, "column": 36}}, {"id": 154, "type": "identifier", "text": "get_size_in_bytes", "parent": 153, "children": [], "start_point": {"row": 45, "column": 11}, "end_point": {"row": 45, "column": 28}}, {"id": 155, "type": "parameter_list", "text": "()", "parent": 153, "children": [], "start_point": {"row": 45, "column": 28}, "end_point": {"row": 45, "column": 30}}, {"id": 156, "type": "identifier", "text": "operator", "parent": 144, "children": [], "start_point": {"row": 47, "column": 4}, "end_point": {"row": 47, "column": 12}}, {"id": 157, "type": "identifier", "text": "T", "parent": 144, "children": [], "start_point": {"row": 47, "column": 13}, "end_point": {"row": 47, "column": 14}}, {"id": 158, "type": "pointer_declarator", "text": "*()", "parent": 142, "children": [159, 160], "start_point": {"row": 47, "column": 15}, "end_point": {"row": 47, "column": 18}}, {"id": 159, "type": "*", "text": "*", "parent": 158, "children": [], "start_point": {"row": 47, "column": 15}, "end_point": {"row": 47, "column": 16}}, {"id": 160, "type": "parenthesized_declarator", "text": "()", "parent": 158, "children": [161], "start_point": {"row": 47, "column": 16}, "end_point": {"row": 47, "column": 18}}, {"id": 161, "type": "identifier", "text": "", "parent": 160, "children": [], "start_point": {"row": 47, "column": 17}, "end_point": {"row": 47, "column": 17}}, {"id": 162, "type": "declaration", "text": "operator const T *() const;", "parent": 137, "children": [163, 164, 166], "start_point": {"row": 49, "column": 4}, "end_point": {"row": 49, "column": 31}}, {"id": 163, "type": "type_identifier", "text": "operator", "parent": 162, "children": [], "start_point": {"row": 49, "column": 4}, "end_point": {"row": 49, "column": 12}}, {"id": 164, "type": "ERROR", "text": "T", "parent": 162, "children": [165], "start_point": {"row": 49, "column": 19}, "end_point": {"row": 49, "column": 20}}, {"id": 165, "type": "identifier", "text": "T", "parent": 164, "children": [], "start_point": {"row": 49, "column": 19}, "end_point": {"row": 49, "column": 20}}, {"id": 166, "type": "pointer_declarator", "text": "*() const", "parent": 162, "children": [167, 168, 169], "start_point": {"row": 49, "column": 21}, "end_point": {"row": 49, "column": 30}}, {"id": 167, "type": "*", "text": "*", "parent": 166, "children": [], "start_point": {"row": 49, "column": 21}, "end_point": {"row": 49, "column": 22}}, {"id": 168, "type": "ERROR", "text": "()", "parent": 166, "children": [], "start_point": {"row": 49, "column": 22}, "end_point": {"row": 49, "column": 24}}, {"id": 169, "type": "identifier", "text": "", "parent": 166, "children": [], "start_point": {"row": 49, "column": 30}, "end_point": {"row": 49, "column": 30}}, {"id": 170, "type": "declaration", "text": "operator CUdeviceptr();", "parent": 137, "children": [171, 172], "start_point": {"row": 51, "column": 4}, "end_point": {"row": 51, "column": 27}}, {"id": 171, "type": "type_identifier", "text": "operator", "parent": 170, "children": [], "start_point": {"row": 51, "column": 4}, "end_point": {"row": 51, "column": 12}}, {"id": 172, "type": "function_declarator", "text": "CUdeviceptr()", "parent": 170, "children": [173, 174], "start_point": {"row": 51, "column": 13}, "end_point": {"row": 51, "column": 26}}, {"id": 173, "type": "identifier", "text": "CUdeviceptr", "parent": 172, "children": [], "start_point": {"row": 51, "column": 13}, "end_point": {"row": 51, "column": 24}}, {"id": 174, "type": "parameter_list", "text": "()", "parent": 172, "children": [], "start_point": {"row": 51, "column": 24}, "end_point": {"row": 51, "column": 26}}, {"id": 175, "type": "declaration", "text": "T *get();", "parent": 137, "children": [176, 177], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 13}}, {"id": 176, "type": "type_identifier", "text": "T", "parent": 175, "children": [], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 5}}, {"id": 177, "type": "pointer_declarator", "text": "*get()", "parent": 175, "children": [178, 179], "start_point": {"row": 53, "column": 6}, "end_point": {"row": 53, "column": 12}}, {"id": 178, "type": "*", "text": "*", "parent": 177, "children": [], "start_point": {"row": 53, "column": 6}, "end_point": {"row": 53, "column": 7}}, {"id": 179, "type": "function_declarator", "text": "get()", "parent": 177, "children": [180, 181], "start_point": {"row": 53, "column": 7}, "end_point": {"row": 53, "column": 12}}, {"id": 180, "type": "identifier", "text": "get", "parent": 179, "children": [], "start_point": {"row": 53, "column": 7}, "end_point": {"row": 53, "column": 10}}, {"id": 181, "type": "parameter_list", "text": "()", "parent": 179, "children": [], "start_point": {"row": 53, "column": 10}, "end_point": {"row": 53, "column": 12}}, {"id": 182, "type": "declaration", "text": "const T *get() const;", "parent": 137, "children": [183, 184], "start_point": {"row": 55, "column": 4}, "end_point": {"row": 55, "column": 25}}, {"id": 183, "type": "type_identifier", "text": "T", "parent": 182, "children": [], "start_point": {"row": 55, "column": 10}, "end_point": {"row": 55, "column": 11}}, {"id": 184, "type": "pointer_declarator", "text": "*get() const", "parent": 182, "children": [185, 186], "start_point": {"row": 55, "column": 12}, "end_point": {"row": 55, "column": 24}}, {"id": 185, "type": "*", "text": "*", "parent": 184, "children": [], "start_point": {"row": 55, "column": 12}, "end_point": {"row": 55, "column": 13}}, {"id": 186, "type": "function_declarator", "text": "get() const", "parent": 184, "children": [187, 188], "start_point": {"row": 55, "column": 13}, "end_point": {"row": 55, "column": 24}}, {"id": 187, "type": "identifier", "text": "get", "parent": 186, "children": [], "start_point": {"row": 55, "column": 13}, "end_point": {"row": 55, "column": 16}}, {"id": 188, "type": "parameter_list", "text": "()", "parent": 186, "children": [], "start_point": {"row": 55, "column": 16}, "end_point": {"row": 55, "column": 18}}, {"id": 189, "type": "declaration", "text": "CUdeviceptr get_device_ptr();", "parent": 137, "children": [190, 191], "start_point": {"row": 57, "column": 4}, "end_point": {"row": 57, "column": 33}}, {"id": 190, "type": "type_identifier", "text": "CUdeviceptr", "parent": 189, "children": [], "start_point": {"row": 57, "column": 4}, "end_point": {"row": 57, "column": 15}}, {"id": 191, "type": "function_declarator", "text": "get_device_ptr()", "parent": 189, "children": [192, 193], "start_point": {"row": 57, "column": 16}, "end_point": {"row": 57, "column": 32}}, {"id": 192, "type": "identifier", "text": "get_device_ptr", "parent": 191, "children": [], "start_point": {"row": 57, "column": 16}, "end_point": {"row": 57, "column": 30}}, {"id": 193, "type": "parameter_list", "text": "()", "parent": 191, "children": [], "start_point": {"row": 57, "column": 30}, "end_point": {"row": 57, "column": 32}}, {"id": 194, "type": "declaration", "text": "template<typename U>\n U *as();", "parent": 137, "children": [195, 196, 202], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 60, "column": 12}}, {"id": 195, "type": "type_identifier", "text": "template", "parent": 194, "children": [], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 12}}, {"id": 196, "type": "ERROR", "text": "<typename U>\n U", "parent": 194, "children": [197, 198, 199, 200, 201], "start_point": {"row": 59, "column": 12}, "end_point": {"row": 60, "column": 5}}, {"id": 197, "type": "<", "text": "<", "parent": 196, "children": [], "start_point": {"row": 59, "column": 12}, "end_point": {"row": 59, "column": 13}}, {"id": 198, "type": "identifier", "text": "typename", "parent": 196, "children": [], "start_point": {"row": 59, "column": 13}, "end_point": {"row": 59, "column": 21}}, {"id": 199, "type": "identifier", "text": "U", "parent": 196, "children": [], "start_point": {"row": 59, "column": 22}, "end_point": {"row": 59, "column": 23}}, {"id": 200, "type": ">", "text": ">", "parent": 196, "children": [], "start_point": {"row": 59, "column": 23}, "end_point": {"row": 59, "column": 24}}, {"id": 201, "type": "identifier", "text": "U", "parent": 196, "children": [], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 5}}, {"id": 202, "type": "pointer_declarator", "text": "*as()", "parent": 194, "children": [203, 204], "start_point": {"row": 60, "column": 6}, "end_point": {"row": 60, "column": 11}}, {"id": 203, "type": "*", "text": "*", "parent": 202, "children": [], "start_point": {"row": 60, "column": 6}, "end_point": {"row": 60, "column": 7}}, {"id": 204, "type": "function_declarator", "text": "as()", "parent": 202, "children": [205], "start_point": {"row": 60, "column": 7}, "end_point": {"row": 60, "column": 11}}, {"id": 205, "type": "parameter_list", "text": "()", "parent": 204, "children": [], "start_point": {"row": 60, "column": 9}, "end_point": {"row": 60, "column": 11}}, {"id": 206, "type": "declaration", "text": "template<typename U>\n const U *as() const;", "parent": 137, "children": [207, 208, 214], "start_point": {"row": 62, "column": 4}, "end_point": {"row": 63, "column": 24}}, {"id": 207, "type": "type_identifier", "text": "template", "parent": 206, "children": [], "start_point": {"row": 62, "column": 4}, "end_point": {"row": 62, "column": 12}}, {"id": 208, "type": "ERROR", "text": "<typename U>\n const U", "parent": 206, "children": [209, 210, 211, 212, 213], "start_point": {"row": 62, "column": 12}, "end_point": {"row": 63, "column": 11}}, {"id": 209, "type": "<", "text": "<", "parent": 208, "children": [], "start_point": {"row": 62, "column": 12}, "end_point": {"row": 62, "column": 13}}, {"id": 210, "type": "identifier", "text": "typename", "parent": 208, "children": [], "start_point": {"row": 62, "column": 13}, "end_point": {"row": 62, "column": 21}}, {"id": 211, "type": "identifier", "text": "U", "parent": 208, "children": [], "start_point": {"row": 62, "column": 22}, "end_point": {"row": 62, "column": 23}}, {"id": 212, "type": ">", "text": ">", "parent": 208, "children": [], "start_point": {"row": 62, "column": 23}, "end_point": {"row": 62, "column": 24}}, {"id": 213, "type": "identifier", "text": "U", "parent": 208, "children": [], "start_point": {"row": 63, "column": 10}, "end_point": {"row": 63, "column": 11}}, {"id": 214, "type": "pointer_declarator", "text": "*as() const", "parent": 206, "children": [215, 216], "start_point": {"row": 63, "column": 12}, "end_point": {"row": 63, "column": 23}}, {"id": 215, "type": "*", "text": "*", "parent": 214, "children": [], "start_point": {"row": 63, "column": 12}, "end_point": {"row": 63, "column": 13}}, {"id": 216, "type": "function_declarator", "text": "as() const", "parent": 214, "children": [217], "start_point": {"row": 63, "column": 13}, "end_point": {"row": 63, "column": 23}}, {"id": 217, "type": "parameter_list", "text": "()", "parent": 216, "children": [], "start_point": {"row": 63, "column": 15}, "end_point": {"row": 63, "column": 17}}, {"id": 218, "type": "declaration", "text": "void clear(const T &val);", "parent": 137, "children": [219, 220], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 29}}, {"id": 219, "type": "primitive_type", "text": "void", "parent": 218, "children": [], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 8}}, {"id": 220, "type": "function_declarator", "text": "clear(const T &val)", "parent": 218, "children": [221, 222], "start_point": {"row": 65, "column": 9}, "end_point": {"row": 65, "column": 28}}, {"id": 221, "type": "identifier", "text": "clear", "parent": 220, "children": [], "start_point": {"row": 65, "column": 9}, "end_point": {"row": 65, "column": 14}}, {"id": 222, "type": "parameter_list", "text": "(const T &val)", "parent": 220, "children": [223], "start_point": {"row": 65, "column": 14}, "end_point": {"row": 65, "column": 28}}, {"id": 223, "type": "parameter_declaration", "text": "const T &val", "parent": 222, "children": [224, 225], "start_point": {"row": 65, "column": 15}, "end_point": {"row": 65, "column": 27}}, {"id": 224, "type": "type_identifier", "text": "T", "parent": 223, "children": [], "start_point": {"row": 65, "column": 21}, "end_point": {"row": 65, "column": 22}}, {"id": 225, "type": "identifier", "text": "val", "parent": 223, "children": [], "start_point": {"row": 65, "column": 24}, "end_point": {"row": 65, "column": 27}}, {"id": 226, "type": "declaration", "text": "void clear_async(const T &val);", "parent": 137, "children": [227, 228], "start_point": {"row": 67, "column": 4}, "end_point": {"row": 67, "column": 35}}, {"id": 227, "type": "primitive_type", "text": "void", "parent": 226, "children": [], "start_point": {"row": 67, "column": 4}, "end_point": {"row": 67, "column": 8}}, {"id": 228, "type": "function_declarator", "text": "clear_async(const T &val)", "parent": 226, "children": [229, 230], "start_point": {"row": 67, "column": 9}, "end_point": {"row": 67, "column": 34}}, {"id": 229, "type": "identifier", "text": "clear_async", "parent": 228, "children": [], "start_point": {"row": 67, "column": 9}, "end_point": {"row": 67, "column": 20}}, {"id": 230, "type": "parameter_list", "text": "(const T &val)", "parent": 228, "children": [231], "start_point": {"row": 67, "column": 20}, "end_point": {"row": 67, "column": 34}}, {"id": 231, "type": "parameter_declaration", "text": "const T &val", "parent": 230, "children": [232, 233], "start_point": {"row": 67, "column": 21}, "end_point": {"row": 67, "column": 33}}, {"id": 232, "type": "type_identifier", "text": "T", "parent": 231, "children": [], "start_point": {"row": 67, "column": 27}, "end_point": {"row": 67, "column": 28}}, {"id": 233, "type": "identifier", "text": "val", "parent": 231, "children": [], "start_point": {"row": 67, "column": 30}, "end_point": {"row": 67, "column": 33}}, {"id": 234, "type": "declaration", "text": "void clear_bytes(uint8_t byte);", "parent": 137, "children": [235, 236], "start_point": {"row": 69, "column": 4}, "end_point": {"row": 69, "column": 35}}, {"id": 235, "type": "primitive_type", "text": "void", "parent": 234, "children": [], "start_point": {"row": 69, "column": 4}, "end_point": {"row": 69, "column": 8}}, {"id": 236, "type": "function_declarator", "text": "clear_bytes(uint8_t byte)", "parent": 234, "children": [237, 238], "start_point": {"row": 69, "column": 9}, "end_point": {"row": 69, "column": 34}}, {"id": 237, "type": "identifier", "text": "clear_bytes", "parent": 236, "children": [], "start_point": {"row": 69, "column": 9}, "end_point": {"row": 69, "column": 20}}, {"id": 238, "type": "parameter_list", "text": "(uint8_t byte)", "parent": 236, "children": [239], "start_point": {"row": 69, "column": 20}, "end_point": {"row": 69, "column": 34}}, {"id": 239, "type": "parameter_declaration", "text": "uint8_t byte", "parent": 238, "children": [240, 241], "start_point": {"row": 69, "column": 21}, "end_point": {"row": 69, "column": 33}}, {"id": 240, "type": "primitive_type", "text": "uint8_t", "parent": 239, "children": [], "start_point": {"row": 69, "column": 21}, "end_point": {"row": 69, "column": 28}}, {"id": 241, "type": "identifier", "text": "byte", "parent": 239, "children": [], "start_point": {"row": 69, "column": 29}, "end_point": {"row": 69, "column": 33}}, {"id": 242, "type": "declaration", "text": "void clear_bytes_async(uint8_t byte);", "parent": 137, "children": [243, 244], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 41}}, {"id": 243, "type": "primitive_type", "text": "void", "parent": 242, "children": [], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 8}}, {"id": 244, "type": "function_declarator", "text": "clear_bytes_async(uint8_t byte)", "parent": 242, "children": [245, 246], "start_point": {"row": 71, "column": 9}, "end_point": {"row": 71, "column": 40}}, {"id": 245, "type": "identifier", "text": "clear_bytes_async", "parent": 244, "children": [], "start_point": {"row": 71, "column": 9}, "end_point": {"row": 71, "column": 26}}, {"id": 246, "type": "parameter_list", "text": "(uint8_t byte)", "parent": 244, "children": [247], "start_point": {"row": 71, "column": 26}, "end_point": {"row": 71, "column": 40}}, {"id": 247, "type": "parameter_declaration", "text": "uint8_t byte", "parent": 246, "children": [248, 249], "start_point": {"row": 71, "column": 27}, "end_point": {"row": 71, "column": 39}}, {"id": 248, "type": "primitive_type", "text": "uint8_t", "parent": 247, "children": [], "start_point": {"row": 71, "column": 27}, "end_point": {"row": 71, "column": 34}}, {"id": 249, "type": "identifier", "text": "byte", "parent": 247, "children": [], "start_point": {"row": 71, "column": 35}, "end_point": {"row": 71, "column": 39}}, {"id": 250, "type": "declaration", "text": "void to_cpu(T *output, size_t beg = 0, size_t end = 0) const;", "parent": 137, "children": [251, 252, 266, 270], "start_point": {"row": 73, "column": 4}, "end_point": {"row": 73, "column": 65}}, {"id": 251, "type": "primitive_type", "text": "void", "parent": 250, "children": [], "start_point": {"row": 73, "column": 4}, "end_point": {"row": 73, "column": 8}}, {"id": 252, "type": "init_declarator", "text": "to_cpu(T *output, size_t beg = 0", "parent": 250, "children": [253, 264, 265], "start_point": {"row": 73, "column": 9}, "end_point": {"row": 73, "column": 41}}, {"id": 253, "type": "function_declarator", "text": "to_cpu(T *output, size_t beg", "parent": 252, "children": [254, 255], "start_point": {"row": 73, "column": 9}, "end_point": {"row": 73, "column": 37}}, {"id": 254, "type": "identifier", "text": "to_cpu", "parent": 253, "children": [], "start_point": {"row": 73, "column": 9}, "end_point": {"row": 73, "column": 15}}, {"id": 255, "type": "parameter_list", "text": "(T *output, size_t beg", "parent": 253, "children": [256, 261], "start_point": {"row": 73, "column": 15}, "end_point": {"row": 73, "column": 37}}, {"id": 256, "type": "parameter_declaration", "text": "T *output", "parent": 255, "children": [257, 258], "start_point": {"row": 73, "column": 16}, "end_point": {"row": 73, "column": 25}}, {"id": 257, "type": "type_identifier", "text": "T", "parent": 256, "children": [], "start_point": {"row": 73, "column": 16}, "end_point": {"row": 73, "column": 17}}, {"id": 258, "type": "pointer_declarator", "text": "*output", "parent": 256, "children": [259, 260], "start_point": {"row": 73, "column": 18}, "end_point": {"row": 73, "column": 25}}, {"id": 259, "type": "*", "text": "*", "parent": 258, "children": [], "start_point": {"row": 73, "column": 18}, "end_point": {"row": 73, "column": 19}}, {"id": 260, "type": "identifier", "text": "output", "parent": 258, "children": [], "start_point": {"row": 73, "column": 19}, "end_point": {"row": 73, "column": 25}}, {"id": 261, "type": "parameter_declaration", "text": "size_t beg", "parent": 255, "children": [262, 263], "start_point": {"row": 73, "column": 27}, "end_point": {"row": 73, "column": 37}}, {"id": 262, "type": "primitive_type", "text": "size_t", "parent": 261, "children": [], "start_point": {"row": 73, "column": 27}, "end_point": {"row": 73, "column": 33}}, {"id": 263, "type": "identifier", "text": "beg", "parent": 261, "children": [], "start_point": {"row": 73, "column": 34}, "end_point": {"row": 73, "column": 37}}, {"id": 264, "type": "=", "text": "=", "parent": 252, "children": [], "start_point": {"row": 73, "column": 38}, "end_point": {"row": 73, "column": 39}}, {"id": 265, "type": "number_literal", "text": "0", "parent": 252, "children": [], "start_point": {"row": 73, "column": 40}, "end_point": {"row": 73, "column": 41}}, {"id": 266, "type": "init_declarator", "text": "size_t end = 0", "parent": 250, "children": [267, 268, 269], "start_point": {"row": 73, "column": 43}, "end_point": {"row": 73, "column": 57}}, {"id": 267, "type": "identifier", "text": "size_t", "parent": 266, "children": [], "start_point": {"row": 73, "column": 43}, "end_point": {"row": 73, "column": 49}}, {"id": 268, "type": "=", "text": "=", "parent": 266, "children": [], "start_point": {"row": 73, "column": 54}, "end_point": {"row": 73, "column": 55}}, {"id": 269, "type": "number_literal", "text": "0", "parent": 266, "children": [], "start_point": {"row": 73, "column": 56}, "end_point": {"row": 73, "column": 57}}, {"id": 270, "type": "ERROR", "text": ") const", "parent": 250, "children": [], "start_point": {"row": 73, "column": 57}, "end_point": {"row": 73, "column": 64}}, {"id": 271, "type": "declaration", "text": "void to_cpu_async(T *output, size_t beg = 0, size_t end = 0) const;", "parent": 137, "children": [272, 273, 287, 291], "start_point": {"row": 75, "column": 4}, "end_point": {"row": 75, "column": 71}}, {"id": 272, "type": "primitive_type", "text": "void", "parent": 271, "children": [], "start_point": {"row": 75, "column": 4}, "end_point": {"row": 75, "column": 8}}, {"id": 273, "type": "init_declarator", "text": "to_cpu_async(T *output, size_t beg = 0", "parent": 271, "children": [274, 285, 286], "start_point": {"row": 75, "column": 9}, "end_point": {"row": 75, "column": 47}}, {"id": 274, "type": "function_declarator", "text": "to_cpu_async(T *output, size_t beg", "parent": 273, "children": [275, 276], "start_point": {"row": 75, "column": 9}, "end_point": {"row": 75, "column": 43}}, {"id": 275, "type": "identifier", "text": "to_cpu_async", "parent": 274, "children": [], "start_point": {"row": 75, "column": 9}, "end_point": {"row": 75, "column": 21}}, {"id": 276, "type": "parameter_list", "text": "(T *output, size_t beg", "parent": 274, "children": [277, 282], "start_point": {"row": 75, "column": 21}, "end_point": {"row": 75, "column": 43}}, {"id": 277, "type": "parameter_declaration", "text": "T *output", "parent": 276, "children": [278, 279], "start_point": {"row": 75, "column": 22}, "end_point": {"row": 75, "column": 31}}, {"id": 278, "type": "type_identifier", "text": "T", "parent": 277, "children": [], "start_point": {"row": 75, "column": 22}, "end_point": {"row": 75, "column": 23}}, {"id": 279, "type": "pointer_declarator", "text": "*output", "parent": 277, "children": [280, 281], "start_point": {"row": 75, "column": 24}, "end_point": {"row": 75, "column": 31}}, {"id": 280, "type": "*", "text": "*", "parent": 279, "children": [], "start_point": {"row": 75, "column": 24}, "end_point": {"row": 75, "column": 25}}, {"id": 281, "type": "identifier", "text": "output", "parent": 279, "children": [], "start_point": {"row": 75, "column": 25}, "end_point": {"row": 75, "column": 31}}, {"id": 282, "type": "parameter_declaration", "text": "size_t beg", "parent": 276, "children": [283, 284], "start_point": {"row": 75, "column": 33}, "end_point": {"row": 75, "column": 43}}, {"id": 283, "type": "primitive_type", "text": "size_t", "parent": 282, "children": [], "start_point": {"row": 75, "column": 33}, "end_point": {"row": 75, "column": 39}}, {"id": 284, "type": "identifier", "text": "beg", "parent": 282, "children": [], "start_point": {"row": 75, "column": 40}, "end_point": {"row": 75, "column": 43}}, {"id": 285, "type": "=", "text": "=", "parent": 273, "children": [], "start_point": {"row": 75, "column": 44}, "end_point": {"row": 75, "column": 45}}, {"id": 286, "type": "number_literal", "text": "0", "parent": 273, "children": [], "start_point": {"row": 75, "column": 46}, "end_point": {"row": 75, "column": 47}}, {"id": 287, "type": "init_declarator", "text": "size_t end = 0", "parent": 271, "children": [288, 289, 290], "start_point": {"row": 75, "column": 49}, "end_point": {"row": 75, "column": 63}}, {"id": 288, "type": "identifier", "text": "size_t", "parent": 287, "children": [], "start_point": {"row": 75, "column": 49}, "end_point": {"row": 75, "column": 55}}, {"id": 289, "type": "=", "text": "=", "parent": 287, "children": [], "start_point": {"row": 75, "column": 60}, "end_point": {"row": 75, "column": 61}}, {"id": 290, "type": "number_literal", "text": "0", "parent": 287, "children": [], "start_point": {"row": 75, "column": 62}, "end_point": {"row": 75, "column": 63}}, {"id": 291, "type": "ERROR", "text": ") const", "parent": 271, "children": [], "start_point": {"row": 75, "column": 63}, "end_point": {"row": 75, "column": 70}}, {"id": 292, "type": "declaration", "text": "void from_cpu(const T *cpu_data, size_t beg = 0, size_t end = 0);", "parent": 137, "children": [293, 294, 308], "start_point": {"row": 77, "column": 4}, "end_point": {"row": 77, "column": 69}}, {"id": 293, "type": "primitive_type", "text": "void", "parent": 292, "children": [], "start_point": {"row": 77, "column": 4}, "end_point": {"row": 77, "column": 8}}, {"id": 294, "type": "init_declarator", "text": "from_cpu(const T *cpu_data, size_t beg = 0", "parent": 292, "children": [295, 306, 307], "start_point": {"row": 77, "column": 9}, "end_point": {"row": 77, "column": 51}}, {"id": 295, "type": "function_declarator", "text": "from_cpu(const T *cpu_data, size_t beg", "parent": 294, "children": [296, 297], "start_point": {"row": 77, "column": 9}, "end_point": {"row": 77, "column": 47}}, {"id": 296, "type": "identifier", "text": "from_cpu", "parent": 295, "children": [], "start_point": {"row": 77, "column": 9}, "end_point": {"row": 77, "column": 17}}, {"id": 297, "type": "parameter_list", "text": "(const T *cpu_data, size_t beg", "parent": 295, "children": [298, 303], "start_point": {"row": 77, "column": 17}, "end_point": {"row": 77, "column": 47}}, {"id": 298, "type": "parameter_declaration", "text": "const T *cpu_data", "parent": 297, "children": [299, 300], "start_point": {"row": 77, "column": 18}, "end_point": {"row": 77, "column": 35}}, {"id": 299, "type": "type_identifier", "text": "T", "parent": 298, "children": [], "start_point": {"row": 77, "column": 24}, "end_point": {"row": 77, "column": 25}}, {"id": 300, "type": "pointer_declarator", "text": "*cpu_data", "parent": 298, "children": [301, 302], "start_point": {"row": 77, "column": 26}, "end_point": {"row": 77, "column": 35}}, {"id": 301, "type": "*", "text": "*", "parent": 300, "children": [], "start_point": {"row": 77, "column": 26}, "end_point": {"row": 77, "column": 27}}, {"id": 302, "type": "identifier", "text": "cpu_data", "parent": 300, "children": [], "start_point": {"row": 77, "column": 27}, "end_point": {"row": 77, "column": 35}}, {"id": 303, "type": "parameter_declaration", "text": "size_t beg", "parent": 297, "children": [304, 305], "start_point": {"row": 77, "column": 37}, "end_point": {"row": 77, "column": 47}}, {"id": 304, "type": "primitive_type", "text": "size_t", "parent": 303, "children": [], "start_point": {"row": 77, "column": 37}, "end_point": {"row": 77, "column": 43}}, {"id": 305, "type": "identifier", "text": "beg", "parent": 303, "children": [], "start_point": {"row": 77, "column": 44}, "end_point": {"row": 77, "column": 47}}, {"id": 306, "type": "=", "text": "=", "parent": 294, "children": [], "start_point": {"row": 77, "column": 48}, "end_point": {"row": 77, "column": 49}}, {"id": 307, "type": "number_literal", "text": "0", "parent": 294, "children": [], "start_point": {"row": 77, "column": 50}, "end_point": {"row": 77, "column": 51}}, {"id": 308, "type": "init_declarator", "text": "size_t end = 0", "parent": 292, "children": [309, 310, 311], "start_point": {"row": 77, "column": 53}, "end_point": {"row": 77, "column": 67}}, {"id": 309, "type": "identifier", "text": "size_t", "parent": 308, "children": [], "start_point": {"row": 77, "column": 53}, "end_point": {"row": 77, "column": 59}}, {"id": 310, "type": "=", "text": "=", "parent": 308, "children": [], "start_point": {"row": 77, "column": 64}, "end_point": {"row": 77, "column": 65}}, {"id": 311, "type": "number_literal", "text": "0", "parent": 308, "children": [], "start_point": {"row": 77, "column": 66}, "end_point": {"row": 77, "column": 67}}, {"id": 312, "type": "declaration", "text": "void from_cpu_async(const T *cpu_data, size_t beg = 0, size_t end = 0);", "parent": 137, "children": [313, 314, 328], "start_point": {"row": 79, "column": 4}, "end_point": {"row": 79, "column": 75}}, {"id": 313, "type": "primitive_type", "text": "void", "parent": 312, "children": [], "start_point": {"row": 79, "column": 4}, "end_point": {"row": 79, "column": 8}}, {"id": 314, "type": "init_declarator", "text": "from_cpu_async(const T *cpu_data, size_t beg = 0", "parent": 312, "children": [315, 326, 327], "start_point": {"row": 79, "column": 9}, "end_point": {"row": 79, "column": 57}}, {"id": 315, "type": "function_declarator", "text": "from_cpu_async(const T *cpu_data, size_t beg", "parent": 314, "children": [316, 317], "start_point": {"row": 79, "column": 9}, "end_point": {"row": 79, "column": 53}}, {"id": 316, "type": "identifier", "text": "from_cpu_async", "parent": 315, "children": [], "start_point": {"row": 79, "column": 9}, "end_point": {"row": 79, "column": 23}}, {"id": 317, "type": "parameter_list", "text": "(const T *cpu_data, size_t beg", "parent": 315, "children": [318, 323], "start_point": {"row": 79, "column": 23}, "end_point": {"row": 79, "column": 53}}, {"id": 318, "type": "parameter_declaration", "text": "const T *cpu_data", "parent": 317, "children": [319, 320], "start_point": {"row": 79, "column": 24}, "end_point": {"row": 79, "column": 41}}, {"id": 319, "type": "type_identifier", "text": "T", "parent": 318, "children": [], "start_point": {"row": 79, "column": 30}, "end_point": {"row": 79, "column": 31}}, {"id": 320, "type": "pointer_declarator", "text": "*cpu_data", "parent": 318, "children": [321, 322], "start_point": {"row": 79, "column": 32}, "end_point": {"row": 79, "column": 41}}, {"id": 321, "type": "*", "text": "*", "parent": 320, "children": [], "start_point": {"row": 79, "column": 32}, "end_point": {"row": 79, "column": 33}}, {"id": 322, "type": "identifier", "text": "cpu_data", "parent": 320, "children": [], "start_point": {"row": 79, "column": 33}, "end_point": {"row": 79, "column": 41}}, {"id": 323, "type": "parameter_declaration", "text": "size_t beg", "parent": 317, "children": [324, 325], "start_point": {"row": 79, "column": 43}, "end_point": {"row": 79, "column": 53}}, {"id": 324, "type": "primitive_type", "text": "size_t", "parent": 323, "children": [], "start_point": {"row": 79, "column": 43}, "end_point": {"row": 79, "column": 49}}, {"id": 325, "type": "identifier", "text": "beg", "parent": 323, "children": [], "start_point": {"row": 79, "column": 50}, "end_point": {"row": 79, "column": 53}}, {"id": 326, "type": "=", "text": "=", "parent": 314, "children": [], "start_point": {"row": 79, "column": 54}, "end_point": {"row": 79, "column": 55}}, {"id": 327, "type": "number_literal", "text": "0", "parent": 314, "children": [], "start_point": {"row": 79, "column": 56}, "end_point": {"row": 79, "column": 57}}, {"id": 328, "type": "init_declarator", "text": "size_t end = 0", "parent": 312, "children": [329, 330, 331], "start_point": {"row": 79, "column": 59}, "end_point": {"row": 79, "column": 73}}, {"id": 329, "type": "identifier", "text": "size_t", "parent": 328, "children": [], "start_point": {"row": 79, "column": 59}, "end_point": {"row": 79, "column": 65}}, {"id": 330, "type": "=", "text": "=", "parent": 328, "children": [], "start_point": {"row": 79, "column": 70}, "end_point": {"row": 79, "column": 71}}, {"id": 331, "type": "number_literal", "text": "0", "parent": 328, "children": [], "start_point": {"row": 79, "column": 72}, "end_point": {"row": 79, "column": 73}}, {"id": 332, "type": "declaration", "text": "auto get_cuj_ptr() const;\n\nprivate:\n\n size_t elem_count_;", "parent": 137, "children": [333, 335, 341], "start_point": {"row": 81, "column": 4}, "end_point": {"row": 85, "column": 23}}, {"id": 333, "type": "storage_class_specifier", "text": "auto", "parent": 332, "children": [334], "start_point": {"row": 81, "column": 4}, "end_point": {"row": 81, "column": 8}}, {"id": 334, "type": "auto", "text": "auto", "parent": 333, "children": [], "start_point": {"row": 81, "column": 4}, "end_point": {"row": 81, "column": 8}}, {"id": 335, "type": "macro_type_specifier", "text": "get_cuj_ptr() const;\n\nprivate:\n\n size_t", "parent": 332, "children": [336, 337, 339], "start_point": {"row": 81, "column": 9}, "end_point": {"row": 85, "column": 10}}, {"id": 336, "type": "identifier", "text": "get_cuj_ptr", "parent": 335, "children": [], "start_point": {"row": 81, "column": 9}, "end_point": {"row": 81, "column": 20}}, {"id": 337, "type": "ERROR", "text": ") const;\n\nprivate:", "parent": 335, "children": [338], "start_point": {"row": 81, "column": 21}, "end_point": {"row": 83, "column": 8}}, {"id": 338, "type": "type_descriptor", "text": "const;\n\nprivate", "parent": 337, "children": [], "start_point": {"row": 81, "column": 23}, "end_point": {"row": 83, "column": 7}}, {"id": 339, "type": "type_descriptor", "text": "size_t", "parent": 335, "children": [340], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 10}}, {"id": 340, "type": "primitive_type", "text": "size_t", "parent": 339, "children": [], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 10}}, {"id": 341, "type": "identifier", "text": "elem_count_", "parent": 332, "children": [], "start_point": {"row": 85, "column": 11}, "end_point": {"row": 85, "column": 22}}, {"id": 342, "type": "declaration", "text": "T *buffer_;", "parent": 137, "children": [343, 344], "start_point": {"row": 86, "column": 4}, "end_point": {"row": 86, "column": 19}}, {"id": 343, "type": "type_identifier", "text": "T", "parent": 342, "children": [], "start_point": {"row": 86, "column": 4}, "end_point": {"row": 86, "column": 5}}, {"id": 344, "type": "pointer_declarator", "text": "*buffer_", "parent": 342, "children": [345, 346], "start_point": {"row": 86, "column": 10}, "end_point": {"row": 86, "column": 18}}, {"id": 345, "type": "*", "text": "*", "parent": 344, "children": [], "start_point": {"row": 86, "column": 10}, "end_point": {"row": 86, "column": 11}}, {"id": 346, "type": "identifier", "text": "buffer_", "parent": 344, "children": [], "start_point": {"row": 86, "column": 11}, "end_point": {"row": 86, "column": 18}}, {"id": 347, "type": "ERROR", "text": "};", "parent": 137, "children": [], "start_point": {"row": 87, "column": 0}, "end_point": {"row": 87, "column": 2}}, {"id": 348, "type": "ERROR", "text": "template<typename T>\nBuffer<T>::Buffer()\n : elem_count_(0), buffer_(nullptr)", "parent": 137, "children": [349, 350, 366], "start_point": {"row": 91, "column": 0}, "end_point": {"row": 93, "column": 38}}, {"id": 349, "type": "type_identifier", "text": "template", "parent": 348, "children": [], "start_point": {"row": 91, "column": 0}, "end_point": {"row": 91, "column": 8}}, {"id": 350, "type": "ERROR", "text": "<typename T>\nBuffer<T>::Buffer()\n : elem_count_(0),", "parent": 348, "children": [351, 352, 353, 354, 355, 356, 357, 358, 359], "start_point": {"row": 91, "column": 8}, "end_point": {"row": 93, "column": 21}}, {"id": 351, "type": "<", "text": "<", "parent": 350, "children": [], "start_point": {"row": 91, "column": 8}, "end_point": {"row": 91, "column": 9}}, {"id": 352, "type": "identifier", "text": "typename", "parent": 350, "children": [], "start_point": {"row": 91, "column": 9}, "end_point": {"row": 91, "column": 17}}, {"id": 353, "type": "identifier", "text": "T", "parent": 350, "children": [], "start_point": {"row": 91, "column": 18}, "end_point": {"row": 91, "column": 19}}, {"id": 354, "type": ">", "text": ">", "parent": 350, "children": [], "start_point": {"row": 91, "column": 19}, "end_point": {"row": 91, "column": 20}}, {"id": 355, "type": "identifier", "text": "Buffer", "parent": 350, "children": [], "start_point": {"row": 92, "column": 0}, "end_point": {"row": 92, "column": 6}}, {"id": 356, "type": "<", "text": "<", "parent": 350, "children": [], "start_point": {"row": 92, "column": 6}, "end_point": {"row": 92, "column": 7}}, {"id": 357, "type": "identifier", "text": "T", "parent": 350, "children": [], "start_point": {"row": 92, "column": 7}, "end_point": {"row": 92, "column": 8}}, {"id": 358, "type": ">", "text": ">", "parent": 350, "children": [], "start_point": {"row": 92, "column": 8}, "end_point": {"row": 92, "column": 9}}, {"id": 359, "type": "function_declarator", "text": "Buffer()\n : elem_count_(0)", "parent": 350, "children": [360, 361, 362], "start_point": {"row": 92, "column": 11}, "end_point": {"row": 93, "column": 20}}, {"id": 360, "type": "identifier", "text": "Buffer", "parent": 359, "children": [], "start_point": {"row": 92, "column": 11}, "end_point": {"row": 92, "column": 17}}, {"id": 361, "type": "parameter_list", "text": "()", "parent": 359, "children": [], "start_point": {"row": 92, "column": 17}, "end_point": {"row": 92, "column": 19}}, {"id": 362, "type": "call_expression", "text": "elem_count_(0)", "parent": 359, "children": [363, 364], "start_point": {"row": 93, "column": 6}, "end_point": {"row": 93, "column": 20}}, {"id": 363, "type": "identifier", "text": "elem_count_", "parent": 362, "children": [], "start_point": {"row": 93, "column": 6}, "end_point": {"row": 93, "column": 17}}, {"id": 364, "type": "argument_list", "text": "(0)", "parent": 362, "children": [365], "start_point": {"row": 93, "column": 17}, "end_point": {"row": 93, "column": 20}}, {"id": 365, "type": "number_literal", "text": "0", "parent": 364, "children": [], "start_point": {"row": 93, "column": 18}, "end_point": {"row": 93, "column": 19}}, {"id": 366, "type": "function_declarator", "text": "buffer_(nullptr)", "parent": 348, "children": [367, 368], "start_point": {"row": 93, "column": 22}, "end_point": {"row": 93, "column": 38}}, {"id": 367, "type": "identifier", "text": "buffer_", "parent": 366, "children": [], "start_point": {"row": 93, "column": 22}, "end_point": {"row": 93, "column": 29}}, {"id": 368, "type": "parameter_list", "text": "(nullptr)", "parent": 366, "children": [369], "start_point": {"row": 93, "column": 29}, "end_point": {"row": 93, "column": 38}}, {"id": 369, "type": "parameter_declaration", "text": "nullptr", "parent": 368, "children": [370], "start_point": {"row": 93, "column": 30}, "end_point": {"row": 93, "column": 37}}, {"id": 370, "type": "type_identifier", "text": "nullptr", "parent": 369, "children": [], "start_point": {"row": 93, "column": 30}, "end_point": {"row": 93, "column": 37}}, {"id": 371, "type": "ERROR", "text": "template<typename T>\nBuffer<T>::Buffer(size_t elem_count, const T *cpu_data)\n : Buffer()\n{", "parent": 42, "children": [372, 397], "start_point": {"row": 98, "column": 0}, "end_point": {"row": 101, "column": 1}}, {"id": 372, "type": "binary_expression", "text": "template<typename T>\nBuffer<T>::Buffer(size_t elem_count, const T *cpu_data)", "parent": 371, "children": [373, 385, 386], "start_point": {"row": 98, "column": 0}, "end_point": {"row": 99, "column": 55}}, {"id": 373, "type": "binary_expression", "text": "template<typename T>\nBuffer<T", "parent": 372, "children": [374, 383, 384], "start_point": {"row": 98, "column": 0}, "end_point": {"row": 99, "column": 8}}, {"id": 374, "type": "binary_expression", "text": "template<typename T>\nBuffer", "parent": 373, "children": [375, 379, 381, 382], "start_point": {"row": 98, "column": 0}, "end_point": {"row": 99, "column": 6}}, {"id": 375, "type": "binary_expression", "text": "template<typename", "parent": 374, "children": [376, 377, 378], "start_point": {"row": 98, "column": 0}, "end_point": {"row": 98, "column": 17}}, {"id": 376, "type": "identifier", "text": "template", "parent": 375, "children": [], "start_point": {"row": 98, "column": 0}, "end_point": {"row": 98, "column": 8}}, {"id": 377, "type": "<", "text": "<", "parent": 375, "children": [], "start_point": {"row": 98, "column": 8}, "end_point": {"row": 98, "column": 9}}, {"id": 378, "type": "identifier", "text": "typename", "parent": 375, "children": [], "start_point": {"row": 98, "column": 9}, "end_point": {"row": 98, "column": 17}}, {"id": 379, "type": "ERROR", "text": "T", "parent": 374, "children": [380], "start_point": {"row": 98, "column": 18}, "end_point": {"row": 98, "column": 19}}, {"id": 380, "type": "identifier", "text": "T", "parent": 379, "children": [], "start_point": {"row": 98, "column": 18}, "end_point": {"row": 98, "column": 19}}, {"id": 381, "type": ">", "text": ">", "parent": 374, "children": [], "start_point": {"row": 98, "column": 19}, "end_point": {"row": 98, "column": 20}}, {"id": 382, "type": "identifier", "text": "Buffer", "parent": 374, "children": [], "start_point": {"row": 99, "column": 0}, "end_point": {"row": 99, "column": 6}}, {"id": 383, "type": "<", "text": "<", "parent": 373, "children": [], "start_point": {"row": 99, "column": 6}, "end_point": {"row": 99, "column": 7}}, {"id": 384, "type": "identifier", "text": "T", "parent": 373, "children": [], "start_point": {"row": 99, "column": 7}, "end_point": {"row": 99, "column": 8}}, {"id": 385, "type": ">", "text": ">", "parent": 372, "children": [], "start_point": {"row": 99, "column": 8}, "end_point": {"row": 99, "column": 9}}, {"id": 386, "type": "call_expression", "text": "Buffer(size_t elem_count, const T *cpu_data)", "parent": 372, "children": [387, 388], "start_point": {"row": 99, "column": 11}, "end_point": {"row": 99, "column": 55}}, {"id": 387, "type": "identifier", "text": "Buffer", "parent": 386, "children": [], "start_point": {"row": 99, "column": 11}, "end_point": {"row": 99, "column": 17}}, {"id": 388, "type": "argument_list", "text": "(size_t elem_count, const T *cpu_data)", "parent": 386, "children": [389, 391, 392], "start_point": {"row": 99, "column": 17}, "end_point": {"row": 99, "column": 55}}, {"id": 389, "type": "ERROR", "text": "size_t", "parent": 388, "children": [390], "start_point": {"row": 99, "column": 18}, "end_point": {"row": 99, "column": 24}}, {"id": 390, "type": "identifier", "text": "size_t", "parent": 389, "children": [], "start_point": {"row": 99, "column": 18}, "end_point": {"row": 99, "column": 24}}, {"id": 391, "type": "identifier", "text": "elem_count", "parent": 388, "children": [], "start_point": {"row": 99, "column": 25}, "end_point": {"row": 99, "column": 35}}, {"id": 392, "type": "binary_expression", "text": "const T *cpu_data", "parent": 388, "children": [393, 395, 396], "start_point": {"row": 99, "column": 37}, "end_point": {"row": 99, "column": 54}}, {"id": 393, "type": "ERROR", "text": "T", "parent": 392, "children": [394], "start_point": {"row": 99, "column": 43}, "end_point": {"row": 99, "column": 44}}, {"id": 394, "type": "identifier", "text": "T", "parent": 393, "children": [], "start_point": {"row": 99, "column": 43}, "end_point": {"row": 99, "column": 44}}, {"id": 395, "type": "*", "text": "*", "parent": 392, "children": [], "start_point": {"row": 99, "column": 45}, "end_point": {"row": 99, "column": 46}}, {"id": 396, "type": "identifier", "text": "cpu_data", "parent": 392, "children": [], "start_point": {"row": 99, "column": 46}, "end_point": {"row": 99, "column": 54}}, {"id": 397, "type": "call_expression", "text": "Buffer()", "parent": 371, "children": [398, 399], "start_point": {"row": 100, "column": 6}, "end_point": {"row": 100, "column": 14}}, {"id": 398, "type": "identifier", "text": "Buffer", "parent": 397, "children": [], "start_point": {"row": 100, "column": 6}, "end_point": {"row": 100, "column": 12}}, {"id": 399, "type": "argument_list", "text": "()", "parent": 397, "children": [], "start_point": {"row": 100, "column": 12}, "end_point": {"row": 100, "column": 14}}, {"id": 400, "type": "if_statement", "text": "if(elem_count)\n initialize(elem_count, cpu_data);", "parent": 42, "children": [401], "start_point": {"row": 102, "column": 4}, "end_point": {"row": 103, "column": 41}}, {"id": 401, "type": "parenthesized_expression", "text": "(elem_count)", "parent": 400, "children": [402], "start_point": {"row": 102, "column": 6}, "end_point": {"row": 102, "column": 18}}, {"id": 402, "type": "identifier", "text": "elem_count", "parent": 401, "children": [], "start_point": {"row": 102, "column": 7}, "end_point": {"row": 102, "column": 17}}, {"id": 403, "type": "call_expression", "text": "initialize(elem_count, cpu_data)", "parent": 400, "children": [404, 405], "start_point": {"row": 103, "column": 8}, "end_point": {"row": 103, "column": 40}}, {"id": 404, "type": "identifier", "text": "initialize", "parent": 403, "children": [], "start_point": {"row": 103, "column": 8}, "end_point": {"row": 103, "column": 18}}, {"id": 405, "type": "argument_list", "text": "(elem_count, cpu_data)", "parent": 403, "children": [406, 407], "start_point": {"row": 103, "column": 18}, "end_point": {"row": 103, "column": 40}}, {"id": 406, "type": "identifier", "text": "elem_count", "parent": 405, "children": [], "start_point": {"row": 103, "column": 19}, "end_point": {"row": 103, "column": 29}}, {"id": 407, "type": "identifier", "text": "cpu_data", "parent": 405, "children": [], "start_point": {"row": 103, "column": 31}, "end_point": {"row": 103, "column": 39}}, {"id": 408, "type": "ERROR", "text": "template<typename T>\nBuffer<T>::Buffer(std::span<const T> data)\n :", "parent": null, "children": [409], "start_point": {"row": 106, "column": 0}, "end_point": {"row": 108, "column": 5}}, {"id": 409, "type": "binary_expression", "text": "template<typename T>\nBuffer<T>::Buffer(std::span<const T> data)", "parent": 408, "children": [410, 422, 423], "start_point": {"row": 106, "column": 0}, "end_point": {"row": 107, "column": 42}}, {"id": 410, "type": "binary_expression", "text": "template<typename T>\nBuffer<T", "parent": 409, "children": [411, 420, 421], "start_point": {"row": 106, "column": 0}, "end_point": {"row": 107, "column": 8}}, {"id": 411, "type": "binary_expression", "text": "template<typename T>\nBuffer", "parent": 410, "children": [412, 416, 418, 419], "start_point": {"row": 106, "column": 0}, "end_point": {"row": 107, "column": 6}}, {"id": 412, "type": "binary_expression", "text": "template<typename", "parent": 411, "children": [413, 414, 415], "start_point": {"row": 106, "column": 0}, "end_point": {"row": 106, "column": 17}}, {"id": 413, "type": "identifier", "text": "template", "parent": 412, "children": [], "start_point": {"row": 106, "column": 0}, "end_point": {"row": 106, "column": 8}}, {"id": 414, "type": "<", "text": "<", "parent": 412, "children": [], "start_point": {"row": 106, "column": 8}, "end_point": {"row": 106, "column": 9}}, {"id": 415, "type": "identifier", "text": "typename", "parent": 412, "children": [], "start_point": {"row": 106, "column": 9}, "end_point": {"row": 106, "column": 17}}, {"id": 416, "type": "ERROR", "text": "T", "parent": 411, "children": [417], "start_point": {"row": 106, "column": 18}, "end_point": {"row": 106, "column": 19}}, {"id": 417, "type": "identifier", "text": "T", "parent": 416, "children": [], "start_point": {"row": 106, "column": 18}, "end_point": {"row": 106, "column": 19}}, {"id": 418, "type": ">", "text": ">", "parent": 411, "children": [], "start_point": {"row": 106, "column": 19}, "end_point": {"row": 106, "column": 20}}, {"id": 419, "type": "identifier", "text": "Buffer", "parent": 411, "children": [], "start_point": {"row": 107, "column": 0}, "end_point": {"row": 107, "column": 6}}, {"id": 420, "type": "<", "text": "<", "parent": 410, "children": [], "start_point": {"row": 107, "column": 6}, "end_point": {"row": 107, "column": 7}}, {"id": 421, "type": "identifier", "text": "T", "parent": 410, "children": [], "start_point": {"row": 107, "column": 7}, "end_point": {"row": 107, "column": 8}}, {"id": 422, "type": ">", "text": ">", "parent": 409, "children": [], "start_point": {"row": 107, "column": 8}, "end_point": {"row": 107, "column": 9}}, {"id": 423, "type": "call_expression", "text": "Buffer(std::span<const T> data)", "parent": 409, "children": [424, 425], "start_point": {"row": 107, "column": 11}, "end_point": {"row": 107, "column": 42}}, {"id": 424, "type": "identifier", "text": "Buffer", "parent": 423, "children": [], "start_point": {"row": 107, "column": 11}, "end_point": {"row": 107, "column": 17}}, {"id": 425, "type": "argument_list", "text": "(std::span<const T> data)", "parent": 423, "children": [426, 428], "start_point": {"row": 107, "column": 17}, "end_point": {"row": 107, "column": 42}}, {"id": 426, "type": "ERROR", "text": "std::", "parent": 425, "children": [427], "start_point": {"row": 107, "column": 18}, "end_point": {"row": 107, "column": 23}}, {"id": 427, "type": "identifier", "text": "std", "parent": 426, "children": [], "start_point": {"row": 107, "column": 18}, "end_point": {"row": 107, "column": 21}}, {"id": 428, "type": "binary_expression", "text": "span<const T> data", "parent": 425, "children": [429, 432, 434, 435], "start_point": {"row": 107, "column": 23}, "end_point": {"row": 107, "column": 41}}, {"id": 429, "type": "binary_expression", "text": "span<const", "parent": 428, "children": [430, 431], "start_point": {"row": 107, "column": 23}, "end_point": {"row": 107, "column": 33}}, {"id": 430, "type": "identifier", "text": "span", "parent": 429, "children": [], "start_point": {"row": 107, "column": 23}, "end_point": {"row": 107, "column": 27}}, {"id": 431, "type": "<", "text": "<", "parent": 429, "children": [], "start_point": {"row": 107, "column": 27}, "end_point": {"row": 107, "column": 28}}, {"id": 432, "type": "ERROR", "text": "T", "parent": 428, "children": [433], "start_point": {"row": 107, "column": 34}, "end_point": {"row": 107, "column": 35}}, {"id": 433, "type": "identifier", "text": "T", "parent": 432, "children": [], "start_point": {"row": 107, "column": 34}, "end_point": {"row": 107, "column": 35}}, {"id": 434, "type": ">", "text": ">", "parent": 428, "children": [], "start_point": {"row": 107, "column": 35}, "end_point": {"row": 107, "column": 36}}, {"id": 435, "type": "identifier", "text": "data", "parent": 428, "children": [], "start_point": {"row": 107, "column": 37}, "end_point": {"row": 107, "column": 41}}, {"id": 436, "type": "call_expression", "text": "Buffer(data.size(), data.data())", "parent": null, "children": [437, 438], "start_point": {"row": 108, "column": 6}, "end_point": {"row": 108, "column": 38}}, {"id": 437, "type": "identifier", "text": "Buffer", "parent": 436, "children": [], "start_point": {"row": 108, "column": 6}, "end_point": {"row": 108, "column": 12}}, {"id": 438, "type": "argument_list", "text": "(data.size(), data.data())", "parent": 436, "children": [439, 444], "start_point": {"row": 108, "column": 12}, "end_point": {"row": 108, "column": 38}}, {"id": 439, "type": "call_expression", "text": "data.size()", "parent": 438, "children": [440, 443], "start_point": {"row": 108, "column": 13}, "end_point": {"row": 108, "column": 24}}, {"id": 440, "type": "field_expression", "text": "data.size", "parent": 439, "children": [441, 442], "start_point": {"row": 108, "column": 13}, "end_point": {"row": 108, "column": 22}}, {"id": 441, "type": "identifier", "text": "data", "parent": 440, "children": [], "start_point": {"row": 108, "column": 13}, "end_point": {"row": 108, "column": 17}}, {"id": 442, "type": "field_identifier", "text": "size", "parent": 440, "children": [], "start_point": {"row": 108, "column": 18}, "end_point": {"row": 108, "column": 22}}, {"id": 443, "type": "argument_list", "text": "()", "parent": 439, "children": [], "start_point": {"row": 108, "column": 22}, "end_point": {"row": 108, "column": 24}}, {"id": 444, "type": "call_expression", "text": "data.data()", "parent": 438, "children": [445, 448], "start_point": {"row": 108, "column": 26}, "end_point": {"row": 108, "column": 37}}, {"id": 445, "type": "field_expression", "text": "data.data", "parent": 444, "children": [446, 447], "start_point": {"row": 108, "column": 26}, "end_point": {"row": 108, "column": 35}}, {"id": 446, "type": "identifier", "text": "data", "parent": 445, "children": [], "start_point": {"row": 108, "column": 26}, "end_point": {"row": 108, "column": 30}}, {"id": 447, "type": "field_identifier", "text": "data", "parent": 445, "children": [], "start_point": {"row": 108, "column": 31}, "end_point": {"row": 108, "column": 35}}, {"id": 448, "type": "argument_list", "text": "()", "parent": 444, "children": [], "start_point": {"row": 108, "column": 35}, "end_point": {"row": 108, "column": 37}}, {"id": 449, "type": "ERROR", "text": "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer<T> &Buffer<T>::operator=(Buffer &&other) noexcept", "parent": null, "children": [450, 510], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 121, "column": 56}}, {"id": 450, "type": "binary_expression", "text": "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer<T> &Buffer<T>::operator=(Buffer &&other)", "parent": 449, "children": [451, 501, 502], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 121, "column": 47}}, {"id": 451, "type": "binary_expression", "text": "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer<T> &Buffer<T", "parent": 450, "children": [452, 499, 500], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 121, "column": 19}}, {"id": 452, "type": "binary_expression", "text": "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer<T> &Buffer", "parent": 451, "children": [453, 496, 497], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 121, "column": 17}}, {"id": 453, "type": "binary_expression", "text": "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer<T", "parent": 452, "children": [454, 494, 495], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 121, "column": 8}}, {"id": 454, "type": "binary_expression", "text": "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer", "parent": 453, "children": [455, 490, 492, 493], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 121, "column": 6}}, {"id": 455, "type": "binary_expression", "text": "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename", "parent": 454, "children": [456, 486, 488, 489], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 120, "column": 17}}, {"id": 456, "type": "binary_expression", "text": "template<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other)", "parent": 455, "children": [457, 469, 470, 482], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 117, "column": 15}}, {"id": 457, "type": "binary_expression", "text": "template<typename T>\nBuffer<T", "parent": 456, "children": [458, 467, 468], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 114, "column": 8}}, {"id": 458, "type": "binary_expression", "text": "template<typename T>\nBuffer", "parent": 457, "children": [459, 463, 465, 466], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 114, "column": 6}}, {"id": 459, "type": "binary_expression", "text": "template<typename", "parent": 458, "children": [460, 461, 462], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 113, "column": 17}}, {"id": 460, "type": "identifier", "text": "template", "parent": 459, "children": [], "start_point": {"row": 113, "column": 0}, "end_point": {"row": 113, "column": 8}}, {"id": 461, "type": "<", "text": "<", "parent": 459, "children": [], "start_point": {"row": 113, "column": 8}, "end_point": {"row": 113, "column": 9}}, {"id": 462, "type": "identifier", "text": "typename", "parent": 459, "children": [], "start_point": {"row": 113, "column": 9}, "end_point": {"row": 113, "column": 17}}, {"id": 463, "type": "ERROR", "text": "T", "parent": 458, "children": [464], "start_point": {"row": 113, "column": 18}, "end_point": {"row": 113, "column": 19}}, {"id": 464, "type": "identifier", "text": "T", "parent": 463, "children": [], "start_point": {"row": 113, "column": 18}, "end_point": {"row": 113, "column": 19}}, {"id": 465, "type": ">", "text": ">", "parent": 458, "children": [], "start_point": {"row": 113, "column": 19}, "end_point": {"row": 113, "column": 20}}, {"id": 466, "type": "identifier", "text": "Buffer", "parent": 458, "children": [], "start_point": {"row": 114, "column": 0}, "end_point": {"row": 114, "column": 6}}, {"id": 467, "type": "<", "text": "<", "parent": 457, "children": [], "start_point": {"row": 114, "column": 6}, "end_point": {"row": 114, "column": 7}}, {"id": 468, "type": "identifier", "text": "T", "parent": 457, "children": [], "start_point": {"row": 114, "column": 7}, "end_point": {"row": 114, "column": 8}}, {"id": 469, "type": ">", "text": ">", "parent": 456, "children": [], "start_point": {"row": 114, "column": 8}, "end_point": {"row": 114, "column": 9}}, {"id": 470, "type": "ERROR", "text": "::Buffer(Buffer &&other) noexcept\n : Buffer()\n{", "parent": 456, "children": [471, 478, 479], "start_point": {"row": 114, "column": 9}, "end_point": {"row": 116, "column": 1}}, {"id": 471, "type": "call_expression", "text": "Buffer(Buffer &&other)", "parent": 470, "children": [472, 473], "start_point": {"row": 114, "column": 11}, "end_point": {"row": 114, "column": 33}}, {"id": 472, "type": "identifier", "text": "Buffer", "parent": 471, "children": [], "start_point": {"row": 114, "column": 11}, "end_point": {"row": 114, "column": 17}}, {"id": 473, "type": "argument_list", "text": "(Buffer &&other)", "parent": 471, "children": [474], "start_point": {"row": 114, "column": 17}, "end_point": {"row": 114, "column": 33}}, {"id": 474, "type": "binary_expression", "text": "Buffer &&other", "parent": 473, "children": [475, 476, 477], "start_point": {"row": 114, "column": 18}, "end_point": {"row": 114, "column": 32}}, {"id": 475, "type": "identifier", "text": "Buffer", "parent": 474, "children": [], "start_point": {"row": 114, "column": 18}, "end_point": {"row": 114, "column": 24}}, {"id": 476, "type": "&&", "text": "&&", "parent": 474, "children": [], "start_point": {"row": 114, "column": 25}, "end_point": {"row": 114, "column": 27}}, {"id": 477, "type": "identifier", "text": "other", "parent": 474, "children": [], "start_point": {"row": 114, "column": 27}, "end_point": {"row": 114, "column": 32}}, {"id": 478, "type": "identifier", "text": "noexcept", "parent": 470, "children": [], "start_point": {"row": 114, "column": 34}, "end_point": {"row": 114, "column": 42}}, {"id": 479, "type": "call_expression", "text": "Buffer()", "parent": 470, "children": [480, 481], "start_point": {"row": 115, "column": 6}, "end_point": {"row": 115, "column": 14}}, {"id": 480, "type": "identifier", "text": "Buffer", "parent": 479, "children": [], "start_point": {"row": 115, "column": 6}, "end_point": {"row": 115, "column": 12}}, {"id": 481, "type": "argument_list", "text": "()", "parent": 479, "children": [], "start_point": {"row": 115, "column": 12}, "end_point": {"row": 115, "column": 14}}, {"id": 482, "type": "call_expression", "text": "swap(other)", "parent": 456, "children": [483, 484], "start_point": {"row": 117, "column": 4}, "end_point": {"row": 117, "column": 15}}, {"id": 483, "type": "identifier", "text": "swap", "parent": 482, "children": [], "start_point": {"row": 117, "column": 4}, "end_point": {"row": 117, "column": 8}}, {"id": 484, "type": "argument_list", "text": "(other)", "parent": 482, "children": [485], "start_point": {"row": 117, "column": 8}, "end_point": {"row": 117, "column": 15}}, {"id": 485, "type": "identifier", "text": "other", "parent": 484, "children": [], "start_point": {"row": 117, "column": 9}, "end_point": {"row": 117, "column": 14}}, {"id": 486, "type": "ERROR", "text": ";\n}\n\ntemplate", "parent": 455, "children": [487], "start_point": {"row": 117, "column": 15}, "end_point": {"row": 120, "column": 8}}, {"id": 487, "type": "identifier", "text": "template", "parent": 486, "children": [], "start_point": {"row": 120, "column": 0}, "end_point": {"row": 120, "column": 8}}, {"id": 488, "type": "<", "text": "<", "parent": 455, "children": [], "start_point": {"row": 120, "column": 8}, "end_point": {"row": 120, "column": 9}}, {"id": 489, "type": "identifier", "text": "typename", "parent": 455, "children": [], "start_point": {"row": 120, "column": 9}, "end_point": {"row": 120, "column": 17}}, {"id": 490, "type": "ERROR", "text": "T", "parent": 454, "children": [491], "start_point": {"row": 120, "column": 18}, "end_point": {"row": 120, "column": 19}}, {"id": 491, "type": "identifier", "text": "T", "parent": 490, "children": [], "start_point": {"row": 120, "column": 18}, "end_point": {"row": 120, "column": 19}}, {"id": 492, "type": ">", "text": ">", "parent": 454, "children": [], "start_point": {"row": 120, "column": 19}, "end_point": {"row": 120, "column": 20}}, {"id": 493, "type": "identifier", "text": "Buffer", "parent": 454, "children": [], "start_point": {"row": 121, "column": 0}, "end_point": {"row": 121, "column": 6}}, {"id": 494, "type": "<", "text": "<", "parent": 453, "children": [], "start_point": {"row": 121, "column": 6}, "end_point": {"row": 121, "column": 7}}, {"id": 495, "type": "identifier", "text": "T", "parent": 453, "children": [], "start_point": {"row": 121, "column": 7}, "end_point": {"row": 121, "column": 8}}, {"id": 496, "type": ">", "text": ">", "parent": 452, "children": [], "start_point": {"row": 121, "column": 8}, "end_point": {"row": 121, "column": 9}}, {"id": 497, "type": "pointer_expression", "text": "&Buffer", "parent": 452, "children": [498], "start_point": {"row": 121, "column": 10}, "end_point": {"row": 121, "column": 17}}, {"id": 498, "type": "identifier", "text": "Buffer", "parent": 497, "children": [], "start_point": {"row": 121, "column": 11}, "end_point": {"row": 121, "column": 17}}, {"id": 499, "type": "<", "text": "<", "parent": 451, "children": [], "start_point": {"row": 121, "column": 17}, "end_point": {"row": 121, "column": 18}}, {"id": 500, "type": "identifier", "text": "T", "parent": 451, "children": [], "start_point": {"row": 121, "column": 18}, "end_point": {"row": 121, "column": 19}}, {"id": 501, "type": ">", "text": ">", "parent": 450, "children": [], "start_point": {"row": 121, "column": 19}, "end_point": {"row": 121, "column": 20}}, {"id": 502, "type": "assignment_expression", "text": "operator=(Buffer &&other)", "parent": 450, "children": [503, 504, 505], "start_point": {"row": 121, "column": 22}, "end_point": {"row": 121, "column": 47}}, {"id": 503, "type": "identifier", "text": "operator", "parent": 502, "children": [], "start_point": {"row": 121, "column": 22}, "end_point": {"row": 121, "column": 30}}, {"id": 504, "type": "=", "text": "=", "parent": 502, "children": [], "start_point": {"row": 121, "column": 30}, "end_point": {"row": 121, "column": 31}}, {"id": 505, "type": "parenthesized_expression", "text": "(Buffer &&other)", "parent": 502, "children": [506], "start_point": {"row": 121, "column": 31}, "end_point": {"row": 121, "column": 47}}, {"id": 506, "type": "binary_expression", "text": "Buffer &&other", "parent": 505, "children": [507, 508, 509], "start_point": {"row": 121, "column": 32}, "end_point": {"row": 121, "column": 46}}, {"id": 507, "type": "identifier", "text": "Buffer", "parent": 506, "children": [], "start_point": {"row": 121, "column": 32}, "end_point": {"row": 121, "column": 38}}, {"id": 508, "type": "&&", "text": "&&", "parent": 506, "children": [], "start_point": {"row": 121, "column": 39}, "end_point": {"row": 121, "column": 41}}, {"id": 509, "type": "identifier", "text": "other", "parent": 506, "children": [], "start_point": {"row": 121, "column": 41}, "end_point": {"row": 121, "column": 46}}, {"id": 510, "type": "identifier", "text": "noexcept", "parent": 449, "children": [], "start_point": {"row": 121, "column": 48}, "end_point": {"row": 121, "column": 56}}, {"id": 511, "type": "call_expression", "text": "swap(other)", "parent": null, "children": [512, 513], "start_point": {"row": 123, "column": 4}, "end_point": {"row": 123, "column": 15}}, {"id": 512, "type": "identifier", "text": "swap", "parent": 511, "children": [], "start_point": {"row": 123, "column": 4}, "end_point": {"row": 123, "column": 8}}, {"id": 513, "type": "argument_list", "text": "(other)", "parent": 511, "children": [514], "start_point": {"row": 123, "column": 8}, "end_point": {"row": 123, "column": 15}}, {"id": 514, "type": "identifier", "text": "other", "parent": 513, "children": [], "start_point": {"row": 123, "column": 9}, "end_point": {"row": 123, "column": 14}}, {"id": 515, "type": "return_statement", "text": "return *this;", "parent": null, "children": [516], "start_point": {"row": 124, "column": 4}, "end_point": {"row": 124, "column": 17}}, {"id": 516, "type": "pointer_expression", "text": "*this", "parent": 515, "children": [517, 518], "start_point": {"row": 124, "column": 11}, "end_point": {"row": 124, "column": 16}}, {"id": 517, "type": "*", "text": "*", "parent": 516, "children": [], "start_point": {"row": 124, "column": 11}, "end_point": {"row": 124, "column": 12}}, {"id": 518, "type": "identifier", "text": "this", "parent": 516, "children": [], "start_point": {"row": 124, "column": 12}, "end_point": {"row": 124, "column": 16}}, {"id": 519, "type": "ERROR", "text": "template<typename T>\nBuffer<T>::~Buffer()", "parent": null, "children": [520], "start_point": {"row": 127, "column": 0}, "end_point": {"row": 128, "column": 20}}, {"id": 520, "type": "binary_expression", "text": "template<typename T>\nBuffer<T>::~Buffer()", "parent": 519, "children": [521, 533, 534], "start_point": {"row": 127, "column": 0}, "end_point": {"row": 128, "column": 20}}, {"id": 521, "type": "binary_expression", "text": "template<typename T>\nBuffer<T", "parent": 520, "children": [522, 531, 532], "start_point": {"row": 127, "column": 0}, "end_point": {"row": 128, "column": 8}}, {"id": 522, "type": "binary_expression", "text": "template<typename T>\nBuffer", "parent": 521, "children": [523, 527, 529, 530], "start_point": {"row": 127, "column": 0}, "end_point": {"row": 128, "column": 6}}, {"id": 523, "type": "binary_expression", "text": "template<typename", "parent": 522, "children": [524, 525, 526], "start_point": {"row": 127, "column": 0}, "end_point": {"row": 127, "column": 17}}, {"id": 524, "type": "identifier", "text": "template", "parent": 523, "children": [], "start_point": {"row": 127, "column": 0}, "end_point": {"row": 127, "column": 8}}, {"id": 525, "type": "<", "text": "<", "parent": 523, "children": [], "start_point": {"row": 127, "column": 8}, "end_point": {"row": 127, "column": 9}}, {"id": 526, "type": "identifier", "text": "typename", "parent": 523, "children": [], "start_point": {"row": 127, "column": 9}, "end_point": {"row": 127, "column": 17}}, {"id": 527, "type": "ERROR", "text": "T", "parent": 522, "children": [528], "start_point": {"row": 127, "column": 18}, "end_point": {"row": 127, "column": 19}}, {"id": 528, "type": "identifier", "text": "T", "parent": 527, "children": [], "start_point": {"row": 127, "column": 18}, "end_point": {"row": 127, "column": 19}}, {"id": 529, "type": ">", "text": ">", "parent": 522, "children": [], "start_point": {"row": 127, "column": 19}, "end_point": {"row": 127, "column": 20}}, {"id": 530, "type": "identifier", "text": "Buffer", "parent": 522, "children": [], "start_point": {"row": 128, "column": 0}, "end_point": {"row": 128, "column": 6}}, {"id": 531, "type": "<", "text": "<", "parent": 521, "children": [], "start_point": {"row": 128, "column": 6}, "end_point": {"row": 128, "column": 7}}, {"id": 532, "type": "identifier", "text": "T", "parent": 521, "children": [], "start_point": {"row": 128, "column": 7}, "end_point": {"row": 128, "column": 8}}, {"id": 533, "type": ">", "text": ">", "parent": 520, "children": [], "start_point": {"row": 128, "column": 8}, "end_point": {"row": 128, "column": 9}}, {"id": 534, "type": "unary_expression", "text": "~Buffer()", "parent": 520, "children": [535, 536], "start_point": {"row": 128, "column": 11}, "end_point": {"row": 128, "column": 20}}, {"id": 535, "type": "~", "text": "~", "parent": 534, "children": [], "start_point": {"row": 128, "column": 11}, "end_point": {"row": 128, "column": 12}}, {"id": 536, "type": "call_expression", "text": "Buffer()", "parent": 534, "children": [537, 538], "start_point": {"row": 128, "column": 12}, "end_point": {"row": 128, "column": 20}}, {"id": 537, "type": "identifier", "text": "Buffer", "parent": 536, "children": [], "start_point": {"row": 128, "column": 12}, "end_point": {"row": 128, "column": 18}}, {"id": 538, "type": "argument_list", "text": "()", "parent": 536, "children": [], "start_point": {"row": 128, "column": 18}, "end_point": {"row": 128, "column": 20}}, {"id": 539, "type": "call_expression", "text": "cudaFree(buffer_)", "parent": null, "children": [540, 541], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 21}}, {"id": 540, "type": "identifier", "text": "cudaFree", "parent": 539, "children": [], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 12}}, {"id": 541, "type": "argument_list", "text": "(buffer_)", "parent": 539, "children": [542], "start_point": {"row": 130, "column": 12}, "end_point": {"row": 130, "column": 21}}, {"id": 542, "type": "identifier", "text": "buffer_", "parent": 541, "children": [], "start_point": {"row": 130, "column": 13}, "end_point": {"row": 130, "column": 20}}, {"id": 543, "type": "update_expression", "text": "template<typename T>\nvoid Buffer<T>::initialize(size_t elem_count, const T *cpu_data)\n{\n destroy()", "parent": null, "children": [544, 575], "start_point": {"row": 133, "column": 0}, "end_point": {"row": 136, "column": 13}}, {"id": 544, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T>::initialize(size_t elem_count, const T *cpu_data)\n{\n destroy()", "parent": 543, "children": [545, 559, 560, 572], "start_point": {"row": 133, "column": 0}, "end_point": {"row": 136, "column": 13}}, {"id": 545, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T", "parent": 544, "children": [546, 557, 558], "start_point": {"row": 133, "column": 0}, "end_point": {"row": 134, "column": 13}}, {"id": 546, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer", "parent": 545, "children": [547, 551, 553, 554, 556], "start_point": {"row": 133, "column": 0}, "end_point": {"row": 134, "column": 11}}, {"id": 547, "type": "binary_expression", "text": "template<typename", "parent": 546, "children": [548, 549, 550], "start_point": {"row": 133, "column": 0}, "end_point": {"row": 133, "column": 17}}, {"id": 548, "type": "identifier", "text": "template", "parent": 547, "children": [], "start_point": {"row": 133, "column": 0}, "end_point": {"row": 133, "column": 8}}, {"id": 549, "type": "<", "text": "<", "parent": 547, "children": [], "start_point": {"row": 133, "column": 8}, "end_point": {"row": 133, "column": 9}}, {"id": 550, "type": "identifier", "text": "typename", "parent": 547, "children": [], "start_point": {"row": 133, "column": 9}, "end_point": {"row": 133, "column": 17}}, {"id": 551, "type": "ERROR", "text": "T", "parent": 546, "children": [552], "start_point": {"row": 133, "column": 18}, "end_point": {"row": 133, "column": 19}}, {"id": 552, "type": "identifier", "text": "T", "parent": 551, "children": [], "start_point": {"row": 133, "column": 18}, "end_point": {"row": 133, "column": 19}}, {"id": 553, "type": ">", "text": ">", "parent": 546, "children": [], "start_point": {"row": 133, "column": 19}, "end_point": {"row": 133, "column": 20}}, {"id": 554, "type": "ERROR", "text": "void", "parent": 546, "children": [555], "start_point": {"row": 134, "column": 0}, "end_point": {"row": 134, "column": 4}}, {"id": 555, "type": "identifier", "text": "void", "parent": 554, "children": [], "start_point": {"row": 134, "column": 0}, "end_point": {"row": 134, "column": 4}}, {"id": 556, "type": "identifier", "text": "Buffer", "parent": 546, "children": [], "start_point": {"row": 134, "column": 5}, "end_point": {"row": 134, "column": 11}}, {"id": 557, "type": "<", "text": "<", "parent": 545, "children": [], "start_point": {"row": 134, "column": 11}, "end_point": {"row": 134, "column": 12}}, {"id": 558, "type": "identifier", "text": "T", "parent": 545, "children": [], "start_point": {"row": 134, "column": 12}, "end_point": {"row": 134, "column": 13}}, {"id": 559, "type": ">", "text": ">", "parent": 544, "children": [], "start_point": {"row": 134, "column": 13}, "end_point": {"row": 134, "column": 14}}, {"id": 560, "type": "ERROR", "text": "::initialize(size_t elem_count, const T *cpu_data)\n{", "parent": 544, "children": [561], "start_point": {"row": 134, "column": 14}, "end_point": {"row": 135, "column": 1}}, {"id": 561, "type": "call_expression", "text": "initialize(size_t elem_count, const T *cpu_data)", "parent": 560, "children": [562, 563], "start_point": {"row": 134, "column": 16}, "end_point": {"row": 134, "column": 64}}, {"id": 562, "type": "identifier", "text": "initialize", "parent": 561, "children": [], "start_point": {"row": 134, "column": 16}, "end_point": {"row": 134, "column": 26}}, {"id": 563, "type": "argument_list", "text": "(size_t elem_count, const T *cpu_data)", "parent": 561, "children": [564, 566, 567], "start_point": {"row": 134, "column": 26}, "end_point": {"row": 134, "column": 64}}, {"id": 564, "type": "ERROR", "text": "size_t", "parent": 563, "children": [565], "start_point": {"row": 134, "column": 27}, "end_point": {"row": 134, "column": 33}}, {"id": 565, "type": "identifier", "text": "size_t", "parent": 564, "children": [], "start_point": {"row": 134, "column": 27}, "end_point": {"row": 134, "column": 33}}, {"id": 566, "type": "identifier", "text": "elem_count", "parent": 563, "children": [], "start_point": {"row": 134, "column": 34}, "end_point": {"row": 134, "column": 44}}, {"id": 567, "type": "binary_expression", "text": "const T *cpu_data", "parent": 563, "children": [568, 570, 571], "start_point": {"row": 134, "column": 46}, "end_point": {"row": 134, "column": 63}}, {"id": 568, "type": "ERROR", "text": "T", "parent": 567, "children": [569], "start_point": {"row": 134, "column": 52}, "end_point": {"row": 134, "column": 53}}, {"id": 569, "type": "identifier", "text": "T", "parent": 568, "children": [], "start_point": {"row": 134, "column": 52}, "end_point": {"row": 134, "column": 53}}, {"id": 570, "type": "*", "text": "*", "parent": 567, "children": [], "start_point": {"row": 134, "column": 54}, "end_point": {"row": 134, "column": 55}}, {"id": 571, "type": "identifier", "text": "cpu_data", "parent": 567, "children": [], "start_point": {"row": 134, "column": 55}, "end_point": {"row": 134, "column": 63}}, {"id": 572, "type": "call_expression", "text": "destroy()", "parent": 544, "children": [573, 574], "start_point": {"row": 136, "column": 4}, "end_point": {"row": 136, "column": 13}}, {"id": 573, "type": "identifier", "text": "destroy", "parent": 572, "children": [], "start_point": {"row": 136, "column": 4}, "end_point": {"row": 136, "column": 11}}, {"id": 574, "type": "argument_list", "text": "()", "parent": 572, "children": [], "start_point": {"row": 136, "column": 11}, "end_point": {"row": 136, "column": 13}}, {"id": 575, "type": "--", "text": "", "parent": 543, "children": [], "start_point": {"row": 136, "column": 13}, "end_point": {"row": 136, "column": 13}}, {"id": 576, "type": "call_expression", "text": "assert(elem_count)", "parent": null, "children": [577, 578], "start_point": {"row": 137, "column": 4}, "end_point": {"row": 137, "column": 22}}, {"id": 577, "type": "identifier", "text": "assert", "parent": 576, "children": [], "start_point": {"row": 137, "column": 4}, "end_point": {"row": 137, "column": 10}}, {"id": 578, "type": "argument_list", "text": "(elem_count)", "parent": 576, "children": [579], "start_point": {"row": 137, "column": 10}, "end_point": {"row": 137, "column": 22}}, {"id": 579, "type": "identifier", "text": "elem_count", "parent": 578, "children": [], "start_point": {"row": 137, "column": 11}, "end_point": {"row": 137, "column": 21}}, {"id": 580, "type": "assignment_expression", "text": "elem_count_ = elem_count", "parent": null, "children": [581, 582, 583], "start_point": {"row": 138, "column": 4}, "end_point": {"row": 138, "column": 28}}, {"id": 581, "type": "identifier", "text": "elem_count_", "parent": 580, "children": [], "start_point": {"row": 138, "column": 4}, "end_point": {"row": 138, "column": 15}}, {"id": 582, "type": "=", "text": "=", "parent": 580, "children": [], "start_point": {"row": 138, "column": 16}, "end_point": {"row": 138, "column": 17}}, {"id": 583, "type": "identifier", "text": "elem_count", "parent": 580, "children": [], "start_point": {"row": 138, "column": 18}, "end_point": {"row": 138, "column": 28}}, {"id": 584, "type": "call_expression", "text": "throw_on_error(cudaMalloc(&buffer_, sizeof(T) * elem_count))", "parent": null, "children": [585, 586], "start_point": {"row": 139, "column": 4}, "end_point": {"row": 139, "column": 64}}, {"id": 585, "type": "identifier", "text": "throw_on_error", "parent": 584, "children": [], "start_point": {"row": 139, "column": 4}, "end_point": {"row": 139, "column": 18}}, {"id": 586, "type": "argument_list", "text": "(cudaMalloc(&buffer_, sizeof(T) * elem_count))", "parent": 584, "children": [587], "start_point": {"row": 139, "column": 18}, "end_point": {"row": 139, "column": 64}}, {"id": 587, "type": "call_expression", "text": "cudaMalloc(&buffer_, sizeof(T) * elem_count)", "parent": 586, "children": [588, 589], "start_point": {"row": 139, "column": 19}, "end_point": {"row": 139, "column": 63}}, {"id": 588, "type": "identifier", "text": "cudaMalloc", "parent": 587, "children": [], "start_point": {"row": 139, "column": 19}, "end_point": {"row": 139, "column": 29}}, {"id": 589, "type": "argument_list", "text": "(&buffer_, sizeof(T) * elem_count)", "parent": 587, "children": [590, 592], "start_point": {"row": 139, "column": 29}, "end_point": {"row": 139, "column": 63}}, {"id": 590, "type": "pointer_expression", "text": "&buffer_", "parent": 589, "children": [591], "start_point": {"row": 139, "column": 30}, "end_point": {"row": 139, "column": 38}}, {"id": 591, "type": "identifier", "text": "buffer_", "parent": 590, "children": [], "start_point": {"row": 139, "column": 31}, "end_point": {"row": 139, "column": 38}}, {"id": 592, "type": "binary_expression", "text": "sizeof(T) * elem_count", "parent": 589, "children": [593, 596, 597], "start_point": {"row": 139, "column": 40}, "end_point": {"row": 139, "column": 62}}, {"id": 593, "type": "sizeof_expression", "text": "sizeof(T)", "parent": 592, "children": [594], "start_point": {"row": 139, "column": 40}, "end_point": {"row": 139, "column": 49}}, {"id": 594, "type": "parenthesized_expression", "text": "(T)", "parent": 593, "children": [595], "start_point": {"row": 139, "column": 46}, "end_point": {"row": 139, "column": 49}}, {"id": 595, "type": "identifier", "text": "T", "parent": 594, "children": [], "start_point": {"row": 139, "column": 47}, "end_point": {"row": 139, "column": 48}}, {"id": 596, "type": "*", "text": "*", "parent": 592, "children": [], "start_point": {"row": 139, "column": 50}, "end_point": {"row": 139, "column": 51}}, {"id": 597, "type": "identifier", "text": "elem_count", "parent": 592, "children": [], "start_point": {"row": 139, "column": 52}, "end_point": {"row": 139, "column": 62}}, {"id": 598, "type": "if_statement", "text": "if(cpu_data)\n {\n BTRC_SCOPE_FAIL{ cudaFree(buffer_); };\n this->from_cpu(cpu_data);\n }", "parent": null, "children": [599], "start_point": {"row": 140, "column": 4}, "end_point": {"row": 144, "column": 5}}, {"id": 599, "type": "parenthesized_expression", "text": "(cpu_data)", "parent": 598, "children": [600], "start_point": {"row": 140, "column": 6}, "end_point": {"row": 140, "column": 16}}, {"id": 600, "type": "identifier", "text": "cpu_data", "parent": 599, "children": [], "start_point": {"row": 140, "column": 7}, "end_point": {"row": 140, "column": 15}}, {"id": 601, "type": "type_identifier", "text": "BTRC_SCOPE_FAIL", "parent": 598, "children": [], "start_point": {"row": 142, "column": 8}, "end_point": {"row": 142, "column": 23}}, {"id": 602, "type": "call_expression", "text": "cudaFree(buffer_)", "parent": 598, "children": [603, 604], "start_point": {"row": 142, "column": 25}, "end_point": {"row": 142, "column": 42}}, {"id": 603, "type": "identifier", "text": "cudaFree", "parent": 602, "children": [], "start_point": {"row": 142, "column": 25}, "end_point": {"row": 142, "column": 33}}, {"id": 604, "type": "argument_list", "text": "(buffer_)", "parent": 602, "children": [605], "start_point": {"row": 142, "column": 33}, "end_point": {"row": 142, "column": 42}}, {"id": 605, "type": "identifier", "text": "buffer_", "parent": 604, "children": [], "start_point": {"row": 142, "column": 34}, "end_point": {"row": 142, "column": 41}}, {"id": 606, "type": "call_expression", "text": "this->from_cpu(cpu_data)", "parent": 598, "children": [607, 610], "start_point": {"row": 143, "column": 8}, "end_point": {"row": 143, "column": 32}}, {"id": 607, "type": "field_expression", "text": "this->from_cpu", "parent": 606, "children": [608, 609], "start_point": {"row": 143, "column": 8}, "end_point": {"row": 143, "column": 22}}, {"id": 608, "type": "identifier", "text": "this", "parent": 607, "children": [], "start_point": {"row": 143, "column": 8}, "end_point": {"row": 143, "column": 12}}, {"id": 609, "type": "field_identifier", "text": "from_cpu", "parent": 607, "children": [], "start_point": {"row": 143, "column": 14}, "end_point": {"row": 143, "column": 22}}, {"id": 610, "type": "argument_list", "text": "(cpu_data)", "parent": 606, "children": [611], "start_point": {"row": 143, "column": 22}, "end_point": {"row": 143, "column": 32}}, {"id": 611, "type": "identifier", "text": "cpu_data", "parent": 610, "children": [], "start_point": {"row": 143, "column": 23}, "end_point": {"row": 143, "column": 31}}, {"id": 612, "type": "ERROR", "text": "}\n\ntemplate<typename T>\nvoid Buffer<T>::destroy()", "parent": null, "children": [613], "start_point": {"row": 145, "column": 0}, "end_point": {"row": 148, "column": 25}}, {"id": 613, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T>::destroy()", "parent": 612, "children": [614, 628, 629], "start_point": {"row": 147, "column": 0}, "end_point": {"row": 148, "column": 25}}, {"id": 614, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T", "parent": 613, "children": [615, 626, 627], "start_point": {"row": 147, "column": 0}, "end_point": {"row": 148, "column": 13}}, {"id": 615, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer", "parent": 614, "children": [616, 620, 622, 623, 625], "start_point": {"row": 147, "column": 0}, "end_point": {"row": 148, "column": 11}}, {"id": 616, "type": "binary_expression", "text": "template<typename", "parent": 615, "children": [617, 618, 619], "start_point": {"row": 147, "column": 0}, "end_point": {"row": 147, "column": 17}}, {"id": 617, "type": "identifier", "text": "template", "parent": 616, "children": [], "start_point": {"row": 147, "column": 0}, "end_point": {"row": 147, "column": 8}}, {"id": 618, "type": "<", "text": "<", "parent": 616, "children": [], "start_point": {"row": 147, "column": 8}, "end_point": {"row": 147, "column": 9}}, {"id": 619, "type": "identifier", "text": "typename", "parent": 616, "children": [], "start_point": {"row": 147, "column": 9}, "end_point": {"row": 147, "column": 17}}, {"id": 620, "type": "ERROR", "text": "T", "parent": 615, "children": [621], "start_point": {"row": 147, "column": 18}, "end_point": {"row": 147, "column": 19}}, {"id": 621, "type": "identifier", "text": "T", "parent": 620, "children": [], "start_point": {"row": 147, "column": 18}, "end_point": {"row": 147, "column": 19}}, {"id": 622, "type": ">", "text": ">", "parent": 615, "children": [], "start_point": {"row": 147, "column": 19}, "end_point": {"row": 147, "column": 20}}, {"id": 623, "type": "ERROR", "text": "void", "parent": 615, "children": [624], "start_point": {"row": 148, "column": 0}, "end_point": {"row": 148, "column": 4}}, {"id": 624, "type": "identifier", "text": "void", "parent": 623, "children": [], "start_point": {"row": 148, "column": 0}, "end_point": {"row": 148, "column": 4}}, {"id": 625, "type": "identifier", "text": "Buffer", "parent": 615, "children": [], "start_point": {"row": 148, "column": 5}, "end_point": {"row": 148, "column": 11}}, {"id": 626, "type": "<", "text": "<", "parent": 614, "children": [], "start_point": {"row": 148, "column": 11}, "end_point": {"row": 148, "column": 12}}, {"id": 627, "type": "identifier", "text": "T", "parent": 614, "children": [], "start_point": {"row": 148, "column": 12}, "end_point": {"row": 148, "column": 13}}, {"id": 628, "type": ">", "text": ">", "parent": 613, "children": [], "start_point": {"row": 148, "column": 13}, "end_point": {"row": 148, "column": 14}}, {"id": 629, "type": "call_expression", "text": "destroy()", "parent": 613, "children": [630, 631], "start_point": {"row": 148, "column": 16}, "end_point": {"row": 148, "column": 25}}, {"id": 630, "type": "identifier", "text": "destroy", "parent": 629, "children": [], "start_point": {"row": 148, "column": 16}, "end_point": {"row": 148, "column": 23}}, {"id": 631, "type": "argument_list", "text": "()", "parent": 629, "children": [], "start_point": {"row": 148, "column": 23}, "end_point": {"row": 148, "column": 25}}, {"id": 632, "type": "call_expression", "text": "cudaFree(buffer_)", "parent": null, "children": [633, 634], "start_point": {"row": 150, "column": 4}, "end_point": {"row": 150, "column": 21}}, {"id": 633, "type": "identifier", "text": "cudaFree", "parent": 632, "children": [], "start_point": {"row": 150, "column": 4}, "end_point": {"row": 150, "column": 12}}, {"id": 634, "type": "argument_list", "text": "(buffer_)", "parent": 632, "children": [635], "start_point": {"row": 150, "column": 12}, "end_point": {"row": 150, "column": 21}}, {"id": 635, "type": "identifier", "text": "buffer_", "parent": 634, "children": [], "start_point": {"row": 150, "column": 13}, "end_point": {"row": 150, "column": 20}}, {"id": 636, "type": "assignment_expression", "text": "elem_count_ = 0", "parent": null, "children": [637, 638, 639], "start_point": {"row": 151, "column": 4}, "end_point": {"row": 151, "column": 19}}, {"id": 637, "type": "identifier", "text": "elem_count_", "parent": 636, "children": [], "start_point": {"row": 151, "column": 4}, "end_point": {"row": 151, "column": 15}}, {"id": 638, "type": "=", "text": "=", "parent": 636, "children": [], "start_point": {"row": 151, "column": 16}, "end_point": {"row": 151, "column": 17}}, {"id": 639, "type": "number_literal", "text": "0", "parent": 636, "children": [], "start_point": {"row": 151, "column": 18}, "end_point": {"row": 151, "column": 19}}, {"id": 640, "type": "assignment_expression", "text": "buffer_ = nullptr", "parent": null, "children": [641, 642, 643], "start_point": {"row": 152, "column": 4}, "end_point": {"row": 152, "column": 21}}, {"id": 641, "type": "identifier", "text": "buffer_", "parent": 640, "children": [], "start_point": {"row": 152, "column": 4}, "end_point": {"row": 152, "column": 11}}, {"id": 642, "type": "=", "text": "=", "parent": 640, "children": [], "start_point": {"row": 152, "column": 12}, "end_point": {"row": 152, "column": 13}}, {"id": 643, "type": "null", "text": "nullptr", "parent": 640, "children": [644], "start_point": {"row": 152, "column": 14}, "end_point": {"row": 152, "column": 21}}, {"id": 644, "type": "nullptr", "text": "nullptr", "parent": 643, "children": [], "start_point": {"row": 152, "column": 14}, "end_point": {"row": 152, "column": 21}}, {"id": 645, "type": "ERROR", "text": "template<typename T>\nvoid Buffer<T>::swap(Buffer &other) noexcept", "parent": null, "children": [646, 668], "start_point": {"row": 155, "column": 0}, "end_point": {"row": 156, "column": 44}}, {"id": 646, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T>::swap(Buffer &other)", "parent": 645, "children": [647, 661, 662], "start_point": {"row": 155, "column": 0}, "end_point": {"row": 156, "column": 35}}, {"id": 647, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T", "parent": 646, "children": [648, 659, 660], "start_point": {"row": 155, "column": 0}, "end_point": {"row": 156, "column": 13}}, {"id": 648, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer", "parent": 647, "children": [649, 653, 655, 656, 658], "start_point": {"row": 155, "column": 0}, "end_point": {"row": 156, "column": 11}}, {"id": 649, "type": "binary_expression", "text": "template<typename", "parent": 648, "children": [650, 651, 652], "start_point": {"row": 155, "column": 0}, "end_point": {"row": 155, "column": 17}}, {"id": 650, "type": "identifier", "text": "template", "parent": 649, "children": [], "start_point": {"row": 155, "column": 0}, "end_point": {"row": 155, "column": 8}}, {"id": 651, "type": "<", "text": "<", "parent": 649, "children": [], "start_point": {"row": 155, "column": 8}, "end_point": {"row": 155, "column": 9}}, {"id": 652, "type": "identifier", "text": "typename", "parent": 649, "children": [], "start_point": {"row": 155, "column": 9}, "end_point": {"row": 155, "column": 17}}, {"id": 653, "type": "ERROR", "text": "T", "parent": 648, "children": [654], "start_point": {"row": 155, "column": 18}, "end_point": {"row": 155, "column": 19}}, {"id": 654, "type": "identifier", "text": "T", "parent": 653, "children": [], "start_point": {"row": 155, "column": 18}, "end_point": {"row": 155, "column": 19}}, {"id": 655, "type": ">", "text": ">", "parent": 648, "children": [], "start_point": {"row": 155, "column": 19}, "end_point": {"row": 155, "column": 20}}, {"id": 656, "type": "ERROR", "text": "void", "parent": 648, "children": [657], "start_point": {"row": 156, "column": 0}, "end_point": {"row": 156, "column": 4}}, {"id": 657, "type": "identifier", "text": "void", "parent": 656, "children": [], "start_point": {"row": 156, "column": 0}, "end_point": {"row": 156, "column": 4}}, {"id": 658, "type": "identifier", "text": "Buffer", "parent": 648, "children": [], "start_point": {"row": 156, "column": 5}, "end_point": {"row": 156, "column": 11}}, {"id": 659, "type": "<", "text": "<", "parent": 647, "children": [], "start_point": {"row": 156, "column": 11}, "end_point": {"row": 156, "column": 12}}, {"id": 660, "type": "identifier", "text": "T", "parent": 647, "children": [], "start_point": {"row": 156, "column": 12}, "end_point": {"row": 156, "column": 13}}, {"id": 661, "type": ">", "text": ">", "parent": 646, "children": [], "start_point": {"row": 156, "column": 13}, "end_point": {"row": 156, "column": 14}}, {"id": 662, "type": "call_expression", "text": "swap(Buffer &other)", "parent": 646, "children": [663, 664], "start_point": {"row": 156, "column": 16}, "end_point": {"row": 156, "column": 35}}, {"id": 663, "type": "identifier", "text": "swap", "parent": 662, "children": [], "start_point": {"row": 156, "column": 16}, "end_point": {"row": 156, "column": 20}}, {"id": 664, "type": "argument_list", "text": "(Buffer &other)", "parent": 662, "children": [665], "start_point": {"row": 156, "column": 20}, "end_point": {"row": 156, "column": 35}}, {"id": 665, "type": "binary_expression", "text": "Buffer &other", "parent": 664, "children": [666, 667], "start_point": {"row": 156, "column": 21}, "end_point": {"row": 156, "column": 34}}, {"id": 666, "type": "identifier", "text": "Buffer", "parent": 665, "children": [], "start_point": {"row": 156, "column": 21}, "end_point": {"row": 156, "column": 27}}, {"id": 667, "type": "identifier", "text": "other", "parent": 665, "children": [], "start_point": {"row": 156, "column": 29}, "end_point": {"row": 156, "column": 34}}, {"id": 668, "type": "identifier", "text": "noexcept", "parent": 645, "children": [], "start_point": {"row": 156, "column": 36}, "end_point": {"row": 156, "column": 44}}, {"id": 669, "type": "labeled_statement", "text": "std::swap(elem_count_, other.elem_count_);", "parent": null, "children": [670], "start_point": {"row": 158, "column": 4}, "end_point": {"row": 158, "column": 46}}, {"id": 670, "type": "statement_identifier", "text": "std", "parent": 669, "children": [], "start_point": {"row": 158, "column": 4}, "end_point": {"row": 158, "column": 7}}, {"id": 671, "type": "call_expression", "text": "swap(elem_count_, other.elem_count_)", "parent": 669, "children": [672, 673], "start_point": {"row": 158, "column": 9}, "end_point": {"row": 158, "column": 45}}, {"id": 672, "type": "identifier", "text": "swap", "parent": 671, "children": [], "start_point": {"row": 158, "column": 9}, "end_point": {"row": 158, "column": 13}}, {"id": 673, "type": "argument_list", "text": "(elem_count_, other.elem_count_)", "parent": 671, "children": [674, 675], "start_point": {"row": 158, "column": 13}, "end_point": {"row": 158, "column": 45}}, {"id": 674, "type": "identifier", "text": "elem_count_", "parent": 673, "children": [], "start_point": {"row": 158, "column": 14}, "end_point": {"row": 158, "column": 25}}, {"id": 675, "type": "field_expression", "text": "other.elem_count_", "parent": 673, "children": [676, 677], "start_point": {"row": 158, "column": 27}, "end_point": {"row": 158, "column": 44}}, {"id": 676, "type": "identifier", "text": "other", "parent": 675, "children": [], "start_point": {"row": 158, "column": 27}, "end_point": {"row": 158, "column": 32}}, {"id": 677, "type": "field_identifier", "text": "elem_count_", "parent": 675, "children": [], "start_point": {"row": 158, "column": 33}, "end_point": {"row": 158, "column": 44}}, {"id": 678, "type": "labeled_statement", "text": "std::swap(buffer_, other.buffer_);", "parent": null, "children": [679], "start_point": {"row": 159, "column": 4}, "end_point": {"row": 159, "column": 38}}, {"id": 679, "type": "statement_identifier", "text": "std", "parent": 678, "children": [], "start_point": {"row": 159, "column": 4}, "end_point": {"row": 159, "column": 7}}, {"id": 680, "type": "call_expression", "text": "swap(buffer_, other.buffer_)", "parent": 678, "children": [681, 682], "start_point": {"row": 159, "column": 9}, "end_point": {"row": 159, "column": 37}}, {"id": 681, "type": "identifier", "text": "swap", "parent": 680, "children": [], "start_point": {"row": 159, "column": 9}, "end_point": {"row": 159, "column": 13}}, {"id": 682, "type": "argument_list", "text": "(buffer_, other.buffer_)", "parent": 680, "children": [683, 684], "start_point": {"row": 159, "column": 13}, "end_point": {"row": 159, "column": 37}}, {"id": 683, "type": "identifier", "text": "buffer_", "parent": 682, "children": [], "start_point": {"row": 159, "column": 14}, "end_point": {"row": 159, "column": 21}}, {"id": 684, "type": "field_expression", "text": "other.buffer_", "parent": 682, "children": [685, 686], "start_point": {"row": 159, "column": 23}, "end_point": {"row": 159, "column": 36}}, {"id": 685, "type": "identifier", "text": "other", "parent": 684, "children": [], "start_point": {"row": 159, "column": 23}, "end_point": {"row": 159, "column": 28}}, {"id": 686, "type": "field_identifier", "text": "buffer_", "parent": 684, "children": [], "start_point": {"row": 159, "column": 29}, "end_point": {"row": 159, "column": 36}}, {"id": 687, "type": "ERROR", "text": "template<typename T>\nBuffer<T>::operator bool() const", "parent": null, "children": [688], "start_point": {"row": 162, "column": 0}, "end_point": {"row": 163, "column": 32}}, {"id": 688, "type": "binary_expression", "text": "template<typename T>\nBuffer<T>::operator bool()", "parent": 687, "children": [689, 701, 702, 704], "start_point": {"row": 162, "column": 0}, "end_point": {"row": 163, "column": 26}}, {"id": 689, "type": "binary_expression", "text": "template<typename T>\nBuffer<T", "parent": 688, "children": [690, 699, 700], "start_point": {"row": 162, "column": 0}, "end_point": {"row": 163, "column": 8}}, {"id": 690, "type": "binary_expression", "text": "template<typename T>\nBuffer", "parent": 689, "children": [691, 695, 697, 698], "start_point": {"row": 162, "column": 0}, "end_point": {"row": 163, "column": 6}}, {"id": 691, "type": "binary_expression", "text": "template<typename", "parent": 690, "children": [692, 693, 694], "start_point": {"row": 162, "column": 0}, "end_point": {"row": 162, "column": 17}}, {"id": 692, "type": "identifier", "text": "template", "parent": 691, "children": [], "start_point": {"row": 162, "column": 0}, "end_point": {"row": 162, "column": 8}}, {"id": 693, "type": "<", "text": "<", "parent": 691, "children": [], "start_point": {"row": 162, "column": 8}, "end_point": {"row": 162, "column": 9}}, {"id": 694, "type": "identifier", "text": "typename", "parent": 691, "children": [], "start_point": {"row": 162, "column": 9}, "end_point": {"row": 162, "column": 17}}, {"id": 695, "type": "ERROR", "text": "T", "parent": 690, "children": [696], "start_point": {"row": 162, "column": 18}, "end_point": {"row": 162, "column": 19}}, {"id": 696, "type": "identifier", "text": "T", "parent": 695, "children": [], "start_point": {"row": 162, "column": 18}, "end_point": {"row": 162, "column": 19}}, {"id": 697, "type": ">", "text": ">", "parent": 690, "children": [], "start_point": {"row": 162, "column": 19}, "end_point": {"row": 162, "column": 20}}, {"id": 698, "type": "identifier", "text": "Buffer", "parent": 690, "children": [], "start_point": {"row": 163, "column": 0}, "end_point": {"row": 163, "column": 6}}, {"id": 699, "type": "<", "text": "<", "parent": 689, "children": [], "start_point": {"row": 163, "column": 6}, "end_point": {"row": 163, "column": 7}}, {"id": 700, "type": "identifier", "text": "T", "parent": 689, "children": [], "start_point": {"row": 163, "column": 7}, "end_point": {"row": 163, "column": 8}}, {"id": 701, "type": ">", "text": ">", "parent": 688, "children": [], "start_point": {"row": 163, "column": 8}, "end_point": {"row": 163, "column": 9}}, {"id": 702, "type": "ERROR", "text": "::operator", "parent": 688, "children": [703], "start_point": {"row": 163, "column": 9}, "end_point": {"row": 163, "column": 19}}, {"id": 703, "type": "identifier", "text": "operator", "parent": 702, "children": [], "start_point": {"row": 163, "column": 11}, "end_point": {"row": 163, "column": 19}}, {"id": 704, "type": "call_expression", "text": "bool()", "parent": 688, "children": [705, 706], "start_point": {"row": 163, "column": 20}, "end_point": {"row": 163, "column": 26}}, {"id": 705, "type": "identifier", "text": "bool", "parent": 704, "children": [], "start_point": {"row": 163, "column": 20}, "end_point": {"row": 163, "column": 24}}, {"id": 706, "type": "argument_list", "text": "()", "parent": 704, "children": [], "start_point": {"row": 163, "column": 24}, "end_point": {"row": 163, "column": 26}}, {"id": 707, "type": "return_statement", "text": "return buffer_ != nullptr;", "parent": null, "children": [708], "start_point": {"row": 165, "column": 4}, "end_point": {"row": 165, "column": 30}}, {"id": 708, "type": "binary_expression", "text": "buffer_ != nullptr", "parent": 707, "children": [709, 710, 711], "start_point": {"row": 165, "column": 11}, "end_point": {"row": 165, "column": 29}}, {"id": 709, "type": "identifier", "text": "buffer_", "parent": 708, "children": [], "start_point": {"row": 165, "column": 11}, "end_point": {"row": 165, "column": 18}}, {"id": 710, "type": "!=", "text": "!=", "parent": 708, "children": [], "start_point": {"row": 165, "column": 19}, "end_point": {"row": 165, "column": 21}}, {"id": 711, "type": "null", "text": "nullptr", "parent": 708, "children": [712], "start_point": {"row": 165, "column": 22}, "end_point": {"row": 165, "column": 29}}, {"id": 712, "type": "nullptr", "text": "nullptr", "parent": 711, "children": [], "start_point": {"row": 165, "column": 22}, "end_point": {"row": 165, "column": 29}}, {"id": 713, "type": "ERROR", "text": "template<typename T>\nbool Buffer<T>::is_empty() const", "parent": null, "children": [714], "start_point": {"row": 168, "column": 0}, "end_point": {"row": 169, "column": 32}}, {"id": 714, "type": "binary_expression", "text": "template<typename T>\nbool Buffer<T>::is_empty()", "parent": 713, "children": [715, 729, 730], "start_point": {"row": 168, "column": 0}, "end_point": {"row": 169, "column": 26}}, {"id": 715, "type": "binary_expression", "text": "template<typename T>\nbool Buffer<T", "parent": 714, "children": [716, 727, 728], "start_point": {"row": 168, "column": 0}, "end_point": {"row": 169, "column": 13}}, {"id": 716, "type": "binary_expression", "text": "template<typename T>\nbool Buffer", "parent": 715, "children": [717, 721, 723, 724, 726], "start_point": {"row": 168, "column": 0}, "end_point": {"row": 169, "column": 11}}, {"id": 717, "type": "binary_expression", "text": "template<typename", "parent": 716, "children": [718, 719, 720], "start_point": {"row": 168, "column": 0}, "end_point": {"row": 168, "column": 17}}, {"id": 718, "type": "identifier", "text": "template", "parent": 717, "children": [], "start_point": {"row": 168, "column": 0}, "end_point": {"row": 168, "column": 8}}, {"id": 719, "type": "<", "text": "<", "parent": 717, "children": [], "start_point": {"row": 168, "column": 8}, "end_point": {"row": 168, "column": 9}}, {"id": 720, "type": "identifier", "text": "typename", "parent": 717, "children": [], "start_point": {"row": 168, "column": 9}, "end_point": {"row": 168, "column": 17}}, {"id": 721, "type": "ERROR", "text": "T", "parent": 716, "children": [722], "start_point": {"row": 168, "column": 18}, "end_point": {"row": 168, "column": 19}}, {"id": 722, "type": "identifier", "text": "T", "parent": 721, "children": [], "start_point": {"row": 168, "column": 18}, "end_point": {"row": 168, "column": 19}}, {"id": 723, "type": ">", "text": ">", "parent": 716, "children": [], "start_point": {"row": 168, "column": 19}, "end_point": {"row": 168, "column": 20}}, {"id": 724, "type": "ERROR", "text": "bool", "parent": 716, "children": [725], "start_point": {"row": 169, "column": 0}, "end_point": {"row": 169, "column": 4}}, {"id": 725, "type": "identifier", "text": "bool", "parent": 724, "children": [], "start_point": {"row": 169, "column": 0}, "end_point": {"row": 169, "column": 4}}, {"id": 726, "type": "identifier", "text": "Buffer", "parent": 716, "children": [], "start_point": {"row": 169, "column": 5}, "end_point": {"row": 169, "column": 11}}, {"id": 727, "type": "<", "text": "<", "parent": 715, "children": [], "start_point": {"row": 169, "column": 11}, "end_point": {"row": 169, "column": 12}}, {"id": 728, "type": "identifier", "text": "T", "parent": 715, "children": [], "start_point": {"row": 169, "column": 12}, "end_point": {"row": 169, "column": 13}}, {"id": 729, "type": ">", "text": ">", "parent": 714, "children": [], "start_point": {"row": 169, "column": 13}, "end_point": {"row": 169, "column": 14}}, {"id": 730, "type": "call_expression", "text": "is_empty()", "parent": 714, "children": [731, 732], "start_point": {"row": 169, "column": 16}, "end_point": {"row": 169, "column": 26}}, {"id": 731, "type": "identifier", "text": "is_empty", "parent": 730, "children": [], "start_point": {"row": 169, "column": 16}, "end_point": {"row": 169, "column": 24}}, {"id": 732, "type": "argument_list", "text": "()", "parent": 730, "children": [], "start_point": {"row": 169, "column": 24}, "end_point": {"row": 169, "column": 26}}, {"id": 733, "type": "return_statement", "text": "return buffer_ == nullptr;", "parent": null, "children": [734], "start_point": {"row": 171, "column": 4}, "end_point": {"row": 171, "column": 30}}, {"id": 734, "type": "binary_expression", "text": "buffer_ == nullptr", "parent": 733, "children": [735, 736, 737], "start_point": {"row": 171, "column": 11}, "end_point": {"row": 171, "column": 29}}, {"id": 735, "type": "identifier", "text": "buffer_", "parent": 734, "children": [], "start_point": {"row": 171, "column": 11}, "end_point": {"row": 171, "column": 18}}, {"id": 736, "type": "==", "text": "==", "parent": 734, "children": [], "start_point": {"row": 171, "column": 19}, "end_point": {"row": 171, "column": 21}}, {"id": 737, "type": "null", "text": "nullptr", "parent": 734, "children": [738], "start_point": {"row": 171, "column": 22}, "end_point": {"row": 171, "column": 29}}, {"id": 738, "type": "nullptr", "text": "nullptr", "parent": 737, "children": [], "start_point": {"row": 171, "column": 22}, "end_point": {"row": 171, "column": 29}}, {"id": 739, "type": "ERROR", "text": "template<typename T>\nsize_t Buffer<T>::get_size() const", "parent": null, "children": [740], "start_point": {"row": 174, "column": 0}, "end_point": {"row": 175, "column": 34}}, {"id": 740, "type": "binary_expression", "text": "template<typename T>\nsize_t Buffer<T>::get_size()", "parent": 739, "children": [741, 755, 756], "start_point": {"row": 174, "column": 0}, "end_point": {"row": 175, "column": 28}}, {"id": 741, "type": "binary_expression", "text": "template<typename T>\nsize_t Buffer<T", "parent": 740, "children": [742, 751, 753, 754], "start_point": {"row": 174, "column": 0}, "end_point": {"row": 175, "column": 15}}, {"id": 742, "type": "binary_expression", "text": "template<typename T>\nsize_t", "parent": 741, "children": [743, 747, 749, 750], "start_point": {"row": 174, "column": 0}, "end_point": {"row": 175, "column": 6}}, {"id": 743, "type": "binary_expression", "text": "template<typename", "parent": 742, "children": [744, 745, 746], "start_point": {"row": 174, "column": 0}, "end_point": {"row": 174, "column": 17}}, {"id": 744, "type": "identifier", "text": "template", "parent": 743, "children": [], "start_point": {"row": 174, "column": 0}, "end_point": {"row": 174, "column": 8}}, {"id": 745, "type": "<", "text": "<", "parent": 743, "children": [], "start_point": {"row": 174, "column": 8}, "end_point": {"row": 174, "column": 9}}, {"id": 746, "type": "identifier", "text": "typename", "parent": 743, "children": [], "start_point": {"row": 174, "column": 9}, "end_point": {"row": 174, "column": 17}}, {"id": 747, "type": "ERROR", "text": "T", "parent": 742, "children": [748], "start_point": {"row": 174, "column": 18}, "end_point": {"row": 174, "column": 19}}, {"id": 748, "type": "identifier", "text": "T", "parent": 747, "children": [], "start_point": {"row": 174, "column": 18}, "end_point": {"row": 174, "column": 19}}, {"id": 749, "type": ">", "text": ">", "parent": 742, "children": [], "start_point": {"row": 174, "column": 19}, "end_point": {"row": 174, "column": 20}}, {"id": 750, "type": "identifier", "text": "size_t", "parent": 742, "children": [], "start_point": {"row": 175, "column": 0}, "end_point": {"row": 175, "column": 6}}, {"id": 751, "type": "ERROR", "text": "Buffer", "parent": 741, "children": [752], "start_point": {"row": 175, "column": 7}, "end_point": {"row": 175, "column": 13}}, {"id": 752, "type": "identifier", "text": "Buffer", "parent": 751, "children": [], "start_point": {"row": 175, "column": 7}, "end_point": {"row": 175, "column": 13}}, {"id": 753, "type": "<", "text": "<", "parent": 741, "children": [], "start_point": {"row": 175, "column": 13}, "end_point": {"row": 175, "column": 14}}, {"id": 754, "type": "identifier", "text": "T", "parent": 741, "children": [], "start_point": {"row": 175, "column": 14}, "end_point": {"row": 175, "column": 15}}, {"id": 755, "type": ">", "text": ">", "parent": 740, "children": [], "start_point": {"row": 175, "column": 15}, "end_point": {"row": 175, "column": 16}}, {"id": 756, "type": "call_expression", "text": "get_size()", "parent": 740, "children": [757, 758], "start_point": {"row": 175, "column": 18}, "end_point": {"row": 175, "column": 28}}, {"id": 757, "type": "identifier", "text": "get_size", "parent": 756, "children": [], "start_point": {"row": 175, "column": 18}, "end_point": {"row": 175, "column": 26}}, {"id": 758, "type": "argument_list", "text": "()", "parent": 756, "children": [], "start_point": {"row": 175, "column": 26}, "end_point": {"row": 175, "column": 28}}, {"id": 759, "type": "return_statement", "text": "return elem_count_;", "parent": null, "children": [760], "start_point": {"row": 177, "column": 4}, "end_point": {"row": 177, "column": 23}}, {"id": 760, "type": "identifier", "text": "elem_count_", "parent": 759, "children": [], "start_point": {"row": 177, "column": 11}, "end_point": {"row": 177, "column": 22}}, {"id": 761, "type": "ERROR", "text": "template<typename T>\nsize_t Buffer<T>::get_size_in_bytes() const", "parent": null, "children": [762], "start_point": {"row": 180, "column": 0}, "end_point": {"row": 181, "column": 43}}, {"id": 762, "type": "binary_expression", "text": "template<typename T>\nsize_t Buffer<T>::get_size_in_bytes()", "parent": 761, "children": [763, 777, 778], "start_point": {"row": 180, "column": 0}, "end_point": {"row": 181, "column": 37}}, {"id": 763, "type": "binary_expression", "text": "template<typename T>\nsize_t Buffer<T", "parent": 762, "children": [764, 773, 775, 776], "start_point": {"row": 180, "column": 0}, "end_point": {"row": 181, "column": 15}}, {"id": 764, "type": "binary_expression", "text": "template<typename T>\nsize_t", "parent": 763, "children": [765, 769, 771, 772], "start_point": {"row": 180, "column": 0}, "end_point": {"row": 181, "column": 6}}, {"id": 765, "type": "binary_expression", "text": "template<typename", "parent": 764, "children": [766, 767, 768], "start_point": {"row": 180, "column": 0}, "end_point": {"row": 180, "column": 17}}, {"id": 766, "type": "identifier", "text": "template", "parent": 765, "children": [], "start_point": {"row": 180, "column": 0}, "end_point": {"row": 180, "column": 8}}, {"id": 767, "type": "<", "text": "<", "parent": 765, "children": [], "start_point": {"row": 180, "column": 8}, "end_point": {"row": 180, "column": 9}}, {"id": 768, "type": "identifier", "text": "typename", "parent": 765, "children": [], "start_point": {"row": 180, "column": 9}, "end_point": {"row": 180, "column": 17}}, {"id": 769, "type": "ERROR", "text": "T", "parent": 764, "children": [770], "start_point": {"row": 180, "column": 18}, "end_point": {"row": 180, "column": 19}}, {"id": 770, "type": "identifier", "text": "T", "parent": 769, "children": [], "start_point": {"row": 180, "column": 18}, "end_point": {"row": 180, "column": 19}}, {"id": 771, "type": ">", "text": ">", "parent": 764, "children": [], "start_point": {"row": 180, "column": 19}, "end_point": {"row": 180, "column": 20}}, {"id": 772, "type": "identifier", "text": "size_t", "parent": 764, "children": [], "start_point": {"row": 181, "column": 0}, "end_point": {"row": 181, "column": 6}}, {"id": 773, "type": "ERROR", "text": "Buffer", "parent": 763, "children": [774], "start_point": {"row": 181, "column": 7}, "end_point": {"row": 181, "column": 13}}, {"id": 774, "type": "identifier", "text": "Buffer", "parent": 773, "children": [], "start_point": {"row": 181, "column": 7}, "end_point": {"row": 181, "column": 13}}, {"id": 775, "type": "<", "text": "<", "parent": 763, "children": [], "start_point": {"row": 181, "column": 13}, "end_point": {"row": 181, "column": 14}}, {"id": 776, "type": "identifier", "text": "T", "parent": 763, "children": [], "start_point": {"row": 181, "column": 14}, "end_point": {"row": 181, "column": 15}}, {"id": 777, "type": ">", "text": ">", "parent": 762, "children": [], "start_point": {"row": 181, "column": 15}, "end_point": {"row": 181, "column": 16}}, {"id": 778, "type": "call_expression", "text": "get_size_in_bytes()", "parent": 762, "children": [779, 780], "start_point": {"row": 181, "column": 18}, "end_point": {"row": 181, "column": 37}}, {"id": 779, "type": "identifier", "text": "get_size_in_bytes", "parent": 778, "children": [], "start_point": {"row": 181, "column": 18}, "end_point": {"row": 181, "column": 35}}, {"id": 780, "type": "argument_list", "text": "()", "parent": 778, "children": [], "start_point": {"row": 181, "column": 35}, "end_point": {"row": 181, "column": 37}}, {"id": 781, "type": "return_statement", "text": "return elem_count_ * sizeof(T);", "parent": null, "children": [782], "start_point": {"row": 183, "column": 4}, "end_point": {"row": 183, "column": 35}}, {"id": 782, "type": "binary_expression", "text": "elem_count_ * sizeof(T)", "parent": 781, "children": [783, 784, 785], "start_point": {"row": 183, "column": 11}, "end_point": {"row": 183, "column": 34}}, {"id": 783, "type": "identifier", "text": "elem_count_", "parent": 782, "children": [], "start_point": {"row": 183, "column": 11}, "end_point": {"row": 183, "column": 22}}, {"id": 784, "type": "*", "text": "*", "parent": 782, "children": [], "start_point": {"row": 183, "column": 23}, "end_point": {"row": 183, "column": 24}}, {"id": 785, "type": "sizeof_expression", "text": "sizeof(T)", "parent": 782, "children": [786], "start_point": {"row": 183, "column": 25}, "end_point": {"row": 183, "column": 34}}, {"id": 786, "type": "parenthesized_expression", "text": "(T)", "parent": 785, "children": [787], "start_point": {"row": 183, "column": 31}, "end_point": {"row": 183, "column": 34}}, {"id": 787, "type": "identifier", "text": "T", "parent": 786, "children": [], "start_point": {"row": 183, "column": 32}, "end_point": {"row": 183, "column": 33}}, {"id": 788, "type": "ERROR", "text": "template<typename T>\nBuffer<T>::operator T*()\n{\n return buffer_;\n}\n\ntemplate<typename T>\nBuffer<T>::operator const T*() const\n{\n return buffer_;\n}\n\ntemplate<typename T>\nBuffer<T>::operator CUdeviceptr()\n{\n return get_device_ptr();\n}\n\ntemplate<typename T>\nT *Buffer<T>::get()\n{\n return buffer_;\n}\n\ntemplate<typename T>\nconst T *Buffer<T>::get() const\n{\n return buffer_;\n}\n\ntemplate<typename T>\nCUdeviceptr Buffer<T>::get_device_ptr()\n{\n return reinterpret_cast<CUdeviceptr>(buffer_);\n}\n\ntemplate<typename T>\ntemplate<typename U>\nU *Buffer<T>::as()\n{\n return reinterpret_cast<U *>(buffer_);\n}\n\ntemplate<typename T>\ntemplate<typename U>\nconst U *Buffer<T>::as() const\n{\n return reinterpret_cast<const U *>(buffer_);\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear(const T &val)\n{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n this->from_cpu(vals.data());\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_async(const T &val)\n{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n from_cpu_async(vals.data());\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_bytes(uint8_t byte)\n{\n assert(!is_empty());\n throw_on_error(cudaMemset(buffer_, byte, get_size_in_bytes()));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_bytes_async(uint8_t byte)\n{\n assert(!is_empty());\n throw_on_error(cudaMemsetAsync(buffer_, byte, get_size_in_bytes()));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::from_cpu(const T *cpu_data, size_t beg, size_t end)\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::from_cpu_async(const T *cpu_data, size_t beg, size_t end)\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::to_cpu(T *output, size_t beg, size_t end) const\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::to_cpu_async(T *output, size_t beg, size_t end) const\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}\n\ntemplate<typename T>\nauto Buffer<T>::get_cuj_ptr() const\n{\n return cuj::import_pointer(buffer_);\n}\n\nBTRC_CUDA_END", "parent": null, "children": [789, 801, 802, 804, 805, 806, 809, 821, 822, 824, 825, 826, 1490], "start_point": {"row": 186, "column": 0}, "end_point": {"row": 316, "column": 13}}, {"id": 789, "type": "binary_expression", "text": "template<typename T>\nBuffer<T", "parent": 788, "children": [790, 799, 800], "start_point": {"row": 186, "column": 0}, "end_point": {"row": 187, "column": 8}}, {"id": 790, "type": "binary_expression", "text": "template<typename T>\nBuffer", "parent": 789, "children": [791, 795, 797, 798], "start_point": {"row": 186, "column": 0}, "end_point": {"row": 187, "column": 6}}, {"id": 791, "type": "binary_expression", "text": "template<typename", "parent": 790, "children": [792, 793, 794], "start_point": {"row": 186, "column": 0}, "end_point": {"row": 186, "column": 17}}, {"id": 792, "type": "identifier", "text": "template", "parent": 791, "children": [], "start_point": {"row": 186, "column": 0}, "end_point": {"row": 186, "column": 8}}, {"id": 793, "type": "<", "text": "<", "parent": 791, "children": [], "start_point": {"row": 186, "column": 8}, "end_point": {"row": 186, "column": 9}}, {"id": 794, "type": "identifier", "text": "typename", "parent": 791, "children": [], "start_point": {"row": 186, "column": 9}, "end_point": {"row": 186, "column": 17}}, {"id": 795, "type": "ERROR", "text": "T", "parent": 790, "children": [796], "start_point": {"row": 186, "column": 18}, "end_point": {"row": 186, "column": 19}}, {"id": 796, "type": "identifier", "text": "T", "parent": 795, "children": [], "start_point": {"row": 186, "column": 18}, "end_point": {"row": 186, "column": 19}}, {"id": 797, "type": ">", "text": ">", "parent": 790, "children": [], "start_point": {"row": 186, "column": 19}, "end_point": {"row": 186, "column": 20}}, {"id": 798, "type": "identifier", "text": "Buffer", "parent": 790, "children": [], "start_point": {"row": 187, "column": 0}, "end_point": {"row": 187, "column": 6}}, {"id": 799, "type": "<", "text": "<", "parent": 789, "children": [], "start_point": {"row": 187, "column": 6}, "end_point": {"row": 187, "column": 7}}, {"id": 800, "type": "identifier", "text": "T", "parent": 789, "children": [], "start_point": {"row": 187, "column": 7}, "end_point": {"row": 187, "column": 8}}, {"id": 801, "type": ">", "text": ">", "parent": 788, "children": [], "start_point": {"row": 187, "column": 8}, "end_point": {"row": 187, "column": 9}}, {"id": 802, "type": "ERROR", "text": "::operator", "parent": 788, "children": [803], "start_point": {"row": 187, "column": 9}, "end_point": {"row": 187, "column": 19}}, {"id": 803, "type": "identifier", "text": "operator", "parent": 802, "children": [], "start_point": {"row": 187, "column": 11}, "end_point": {"row": 187, "column": 19}}, {"id": 804, "type": "identifier", "text": "T", "parent": 788, "children": [], "start_point": {"row": 187, "column": 20}, "end_point": {"row": 187, "column": 21}}, {"id": 805, "type": "*", "text": "*", "parent": 788, "children": [], "start_point": {"row": 187, "column": 21}, "end_point": {"row": 187, "column": 22}}, {"id": 806, "type": "ERROR", "text": ")\n{\n return buffer_;\n}", "parent": 788, "children": [], "start_point": {"row": 187, "column": 23}, "end_point": {"row": 190, "column": 1}}, {"id": 807, "type": "return_statement", "text": "return buffer_;", "parent": 806, "children": [808], "start_point": {"row": 189, "column": 4}, "end_point": {"row": 189, "column": 19}}, {"id": 808, "type": "identifier", "text": "buffer_", "parent": 807, "children": [], "start_point": {"row": 189, "column": 11}, "end_point": {"row": 189, "column": 18}}, {"id": 809, "type": "binary_expression", "text": "template<typename T>\nBuffer<T", "parent": 788, "children": [810, 819, 820], "start_point": {"row": 192, "column": 0}, "end_point": {"row": 193, "column": 8}}, {"id": 810, "type": "binary_expression", "text": "template<typename T>\nBuffer", "parent": 809, "children": [811, 815, 817, 818], "start_point": {"row": 192, "column": 0}, "end_point": {"row": 193, "column": 6}}, {"id": 811, "type": "binary_expression", "text": "template<typename", "parent": 810, "children": [812, 813, 814], "start_point": {"row": 192, "column": 0}, "end_point": {"row": 192, "column": 17}}, {"id": 812, "type": "identifier", "text": "template", "parent": 811, "children": [], "start_point": {"row": 192, "column": 0}, "end_point": {"row": 192, "column": 8}}, {"id": 813, "type": "<", "text": "<", "parent": 811, "children": [], "start_point": {"row": 192, "column": 8}, "end_point": {"row": 192, "column": 9}}, {"id": 814, "type": "identifier", "text": "typename", "parent": 811, "children": [], "start_point": {"row": 192, "column": 9}, "end_point": {"row": 192, "column": 17}}, {"id": 815, "type": "ERROR", "text": "T", "parent": 810, "children": [816], "start_point": {"row": 192, "column": 18}, "end_point": {"row": 192, "column": 19}}, {"id": 816, "type": "identifier", "text": "T", "parent": 815, "children": [], "start_point": {"row": 192, "column": 18}, "end_point": {"row": 192, "column": 19}}, {"id": 817, "type": ">", "text": ">", "parent": 810, "children": [], "start_point": {"row": 192, "column": 19}, "end_point": {"row": 192, "column": 20}}, {"id": 818, "type": "identifier", "text": "Buffer", "parent": 810, "children": [], "start_point": {"row": 193, "column": 0}, "end_point": {"row": 193, "column": 6}}, {"id": 819, "type": "<", "text": "<", "parent": 809, "children": [], "start_point": {"row": 193, "column": 6}, "end_point": {"row": 193, "column": 7}}, {"id": 820, "type": "identifier", "text": "T", "parent": 809, "children": [], "start_point": {"row": 193, "column": 7}, "end_point": {"row": 193, "column": 8}}, {"id": 821, "type": ">", "text": ">", "parent": 788, "children": [], "start_point": {"row": 193, "column": 8}, "end_point": {"row": 193, "column": 9}}, {"id": 822, "type": "ERROR", "text": "::operator const", "parent": 788, "children": [823], "start_point": {"row": 193, "column": 9}, "end_point": {"row": 193, "column": 25}}, {"id": 823, "type": "identifier", "text": "operator", "parent": 822, "children": [], "start_point": {"row": 193, "column": 11}, "end_point": {"row": 193, "column": 19}}, {"id": 824, "type": "identifier", "text": "T", "parent": 788, "children": [], "start_point": {"row": 193, "column": 26}, "end_point": {"row": 193, "column": 27}}, {"id": 825, "type": "*", "text": "*", "parent": 788, "children": [], "start_point": {"row": 193, "column": 27}, "end_point": {"row": 193, "column": 28}}, {"id": 826, "type": "ERROR", "text": ") const\n{\n return buffer_;\n}\n\ntemplate<typename T>\nBuffer<T>::operator CUdeviceptr()\n{\n return get_device_ptr();\n}\n\ntemplate<typename T>\nT *Buffer<T>::get()\n{\n return buffer_;\n}\n\ntemplate<typename T>\nconst T *Buffer<T>::get() const\n{\n return buffer_;\n}\n\ntemplate<typename T>\nCUdeviceptr Buffer<T>::get_device_ptr()\n{\n return reinterpret_cast<CUdeviceptr>(buffer_);\n}\n\ntemplate<typename T>\ntemplate<typename U>\nU *Buffer<T>::as()\n{\n return reinterpret_cast<U *>(buffer_);\n}\n\ntemplate<typename T>\ntemplate<typename U>\nconst U *Buffer<T>::as() const\n{\n return reinterpret_cast<const U *>(buffer_);\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear(const T &val)\n{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n this->from_cpu(vals.data());\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_async(const T &val)\n{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n from_cpu_async(vals.data());\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_bytes(uint8_t byte)\n{\n assert(!is_empty());\n throw_on_error(cudaMemset(buffer_, byte, get_size_in_bytes()));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_bytes_async(uint8_t byte)\n{\n assert(!is_empty());\n throw_on_error(cudaMemsetAsync(buffer_, byte, get_size_in_bytes()));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::from_cpu(const T *cpu_data, size_t beg, size_t end)\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::from_cpu_async(const T *cpu_data, size_t beg, size_t end)\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::to_cpu(T *output, size_t beg, size_t end) const\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::to_cpu_async(T *output, size_t beg, size_t end) const\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}\n\ntemplate<typename T>\nauto Buffer<T>::get_cuj_ptr() const", "parent": 788, "children": [829, 852, 874, 897, 925, 963, 1002, 1056, 1108, 1149, 1190, 1259, 1328, 1396, 1464], "start_point": {"row": 193, "column": 29}, "end_point": {"row": 311, "column": 35}}, {"id": 827, "type": "return_statement", "text": "return buffer_;", "parent": 826, "children": [828], "start_point": {"row": 195, "column": 4}, "end_point": {"row": 195, "column": 19}}, {"id": 828, "type": "identifier", "text": "buffer_", "parent": 827, "children": [], "start_point": {"row": 195, "column": 11}, "end_point": {"row": 195, "column": 18}}, {"id": 829, "type": "binary_expression", "text": "template<typename T>\nBuffer<T>::operator CUdeviceptr()", "parent": 826, "children": [830, 842, 843, 845], "start_point": {"row": 198, "column": 0}, "end_point": {"row": 199, "column": 33}}, {"id": 830, "type": "binary_expression", "text": "template<typename T>\nBuffer<T", "parent": 829, "children": [831, 840, 841], "start_point": {"row": 198, "column": 0}, "end_point": {"row": 199, "column": 8}}, {"id": 831, "type": "binary_expression", "text": "template<typename T>\nBuffer", "parent": 830, "children": [832, 836, 838, 839], "start_point": {"row": 198, "column": 0}, "end_point": {"row": 199, "column": 6}}, {"id": 832, "type": "binary_expression", "text": "template<typename", "parent": 831, "children": [833, 834, 835], "start_point": {"row": 198, "column": 0}, "end_point": {"row": 198, "column": 17}}, {"id": 833, "type": "identifier", "text": "template", "parent": 832, "children": [], "start_point": {"row": 198, "column": 0}, "end_point": {"row": 198, "column": 8}}, {"id": 834, "type": "<", "text": "<", "parent": 832, "children": [], "start_point": {"row": 198, "column": 8}, "end_point": {"row": 198, "column": 9}}, {"id": 835, "type": "identifier", "text": "typename", "parent": 832, "children": [], "start_point": {"row": 198, "column": 9}, "end_point": {"row": 198, "column": 17}}, {"id": 836, "type": "ERROR", "text": "T", "parent": 831, "children": [837], "start_point": {"row": 198, "column": 18}, "end_point": {"row": 198, "column": 19}}, {"id": 837, "type": "identifier", "text": "T", "parent": 836, "children": [], "start_point": {"row": 198, "column": 18}, "end_point": {"row": 198, "column": 19}}, {"id": 838, "type": ">", "text": ">", "parent": 831, "children": [], "start_point": {"row": 198, "column": 19}, "end_point": {"row": 198, "column": 20}}, {"id": 839, "type": "identifier", "text": "Buffer", "parent": 831, "children": [], "start_point": {"row": 199, "column": 0}, "end_point": {"row": 199, "column": 6}}, {"id": 840, "type": "<", "text": "<", "parent": 830, "children": [], "start_point": {"row": 199, "column": 6}, "end_point": {"row": 199, "column": 7}}, {"id": 841, "type": "identifier", "text": "T", "parent": 830, "children": [], "start_point": {"row": 199, "column": 7}, "end_point": {"row": 199, "column": 8}}, {"id": 842, "type": ">", "text": ">", "parent": 829, "children": [], "start_point": {"row": 199, "column": 8}, "end_point": {"row": 199, "column": 9}}, {"id": 843, "type": "ERROR", "text": "::operator", "parent": 829, "children": [844], "start_point": {"row": 199, "column": 9}, "end_point": {"row": 199, "column": 19}}, {"id": 844, "type": "identifier", "text": "operator", "parent": 843, "children": [], "start_point": {"row": 199, "column": 11}, "end_point": {"row": 199, "column": 19}}, {"id": 845, "type": "call_expression", "text": "CUdeviceptr()", "parent": 829, "children": [846, 847], "start_point": {"row": 199, "column": 20}, "end_point": {"row": 199, "column": 33}}, {"id": 846, "type": "identifier", "text": "CUdeviceptr", "parent": 845, "children": [], "start_point": {"row": 199, "column": 20}, "end_point": {"row": 199, "column": 31}}, {"id": 847, "type": "argument_list", "text": "()", "parent": 845, "children": [], "start_point": {"row": 199, "column": 31}, "end_point": {"row": 199, "column": 33}}, {"id": 848, "type": "return_statement", "text": "return get_device_ptr();", "parent": 826, "children": [849], "start_point": {"row": 201, "column": 4}, "end_point": {"row": 201, "column": 28}}, {"id": 849, "type": "call_expression", "text": "get_device_ptr()", "parent": 848, "children": [850, 851], "start_point": {"row": 201, "column": 11}, "end_point": {"row": 201, "column": 27}}, {"id": 850, "type": "identifier", "text": "get_device_ptr", "parent": 849, "children": [], "start_point": {"row": 201, "column": 11}, "end_point": {"row": 201, "column": 25}}, {"id": 851, "type": "argument_list", "text": "()", "parent": 849, "children": [], "start_point": {"row": 201, "column": 25}, "end_point": {"row": 201, "column": 27}}, {"id": 852, "type": "binary_expression", "text": "template<typename T>\nT *Buffer<T>::get()", "parent": 826, "children": [853, 868, 869], "start_point": {"row": 204, "column": 0}, "end_point": {"row": 205, "column": 19}}, {"id": 853, "type": "binary_expression", "text": "template<typename T>\nT *Buffer<T", "parent": 852, "children": [854, 866, 867], "start_point": {"row": 204, "column": 0}, "end_point": {"row": 205, "column": 11}}, {"id": 854, "type": "binary_expression", "text": "template<typename T>\nT *Buffer", "parent": 853, "children": [855, 859, 861, 862], "start_point": {"row": 204, "column": 0}, "end_point": {"row": 205, "column": 9}}, {"id": 855, "type": "binary_expression", "text": "template<typename", "parent": 854, "children": [856, 857, 858], "start_point": {"row": 204, "column": 0}, "end_point": {"row": 204, "column": 17}}, {"id": 856, "type": "identifier", "text": "template", "parent": 855, "children": [], "start_point": {"row": 204, "column": 0}, "end_point": {"row": 204, "column": 8}}, {"id": 857, "type": "<", "text": "<", "parent": 855, "children": [], "start_point": {"row": 204, "column": 8}, "end_point": {"row": 204, "column": 9}}, {"id": 858, "type": "identifier", "text": "typename", "parent": 855, "children": [], "start_point": {"row": 204, "column": 9}, "end_point": {"row": 204, "column": 17}}, {"id": 859, "type": "ERROR", "text": "T", "parent": 854, "children": [860], "start_point": {"row": 204, "column": 18}, "end_point": {"row": 204, "column": 19}}, {"id": 860, "type": "identifier", "text": "T", "parent": 859, "children": [], "start_point": {"row": 204, "column": 18}, "end_point": {"row": 204, "column": 19}}, {"id": 861, "type": ">", "text": ">", "parent": 854, "children": [], "start_point": {"row": 204, "column": 19}, "end_point": {"row": 204, "column": 20}}, {"id": 862, "type": "binary_expression", "text": "T *Buffer", "parent": 854, "children": [863, 864, 865], "start_point": {"row": 205, "column": 0}, "end_point": {"row": 205, "column": 9}}, {"id": 863, "type": "identifier", "text": "T", "parent": 862, "children": [], "start_point": {"row": 205, "column": 0}, "end_point": {"row": 205, "column": 1}}, {"id": 864, "type": "*", "text": "*", "parent": 862, "children": [], "start_point": {"row": 205, "column": 2}, "end_point": {"row": 205, "column": 3}}, {"id": 865, "type": "identifier", "text": "Buffer", "parent": 862, "children": [], "start_point": {"row": 205, "column": 3}, "end_point": {"row": 205, "column": 9}}, {"id": 866, "type": "<", "text": "<", "parent": 853, "children": [], "start_point": {"row": 205, "column": 9}, "end_point": {"row": 205, "column": 10}}, {"id": 867, "type": "identifier", "text": "T", "parent": 853, "children": [], "start_point": {"row": 205, "column": 10}, "end_point": {"row": 205, "column": 11}}, {"id": 868, "type": ">", "text": ">", "parent": 852, "children": [], "start_point": {"row": 205, "column": 11}, "end_point": {"row": 205, "column": 12}}, {"id": 869, "type": "call_expression", "text": "get()", "parent": 852, "children": [870, 871], "start_point": {"row": 205, "column": 14}, "end_point": {"row": 205, "column": 19}}, {"id": 870, "type": "identifier", "text": "get", "parent": 869, "children": [], "start_point": {"row": 205, "column": 14}, "end_point": {"row": 205, "column": 17}}, {"id": 871, "type": "argument_list", "text": "()", "parent": 869, "children": [], "start_point": {"row": 205, "column": 17}, "end_point": {"row": 205, "column": 19}}, {"id": 872, "type": "return_statement", "text": "return buffer_;", "parent": 826, "children": [873], "start_point": {"row": 207, "column": 4}, "end_point": {"row": 207, "column": 19}}, {"id": 873, "type": "identifier", "text": "buffer_", "parent": 872, "children": [], "start_point": {"row": 207, "column": 11}, "end_point": {"row": 207, "column": 18}}, {"id": 874, "type": "binary_expression", "text": "template<typename T>\nconst T *Buffer<T>::get()", "parent": 826, "children": [875, 891, 892], "start_point": {"row": 210, "column": 0}, "end_point": {"row": 211, "column": 25}}, {"id": 875, "type": "binary_expression", "text": "template<typename T>\nconst T *Buffer<T", "parent": 874, "children": [876, 889, 890], "start_point": {"row": 210, "column": 0}, "end_point": {"row": 211, "column": 17}}, {"id": 876, "type": "binary_expression", "text": "template<typename T>\nconst T *Buffer", "parent": 875, "children": [877, 881, 883, 884], "start_point": {"row": 210, "column": 0}, "end_point": {"row": 211, "column": 15}}, {"id": 877, "type": "binary_expression", "text": "template<typename", "parent": 876, "children": [878, 879, 880], "start_point": {"row": 210, "column": 0}, "end_point": {"row": 210, "column": 17}}, {"id": 878, "type": "identifier", "text": "template", "parent": 877, "children": [], "start_point": {"row": 210, "column": 0}, "end_point": {"row": 210, "column": 8}}, {"id": 879, "type": "<", "text": "<", "parent": 877, "children": [], "start_point": {"row": 210, "column": 8}, "end_point": {"row": 210, "column": 9}}, {"id": 880, "type": "identifier", "text": "typename", "parent": 877, "children": [], "start_point": {"row": 210, "column": 9}, "end_point": {"row": 210, "column": 17}}, {"id": 881, "type": "ERROR", "text": "T", "parent": 876, "children": [882], "start_point": {"row": 210, "column": 18}, "end_point": {"row": 210, "column": 19}}, {"id": 882, "type": "identifier", "text": "T", "parent": 881, "children": [], "start_point": {"row": 210, "column": 18}, "end_point": {"row": 210, "column": 19}}, {"id": 883, "type": ">", "text": ">", "parent": 876, "children": [], "start_point": {"row": 210, "column": 19}, "end_point": {"row": 210, "column": 20}}, {"id": 884, "type": "binary_expression", "text": "const T *Buffer", "parent": 876, "children": [885, 887, 888], "start_point": {"row": 211, "column": 0}, "end_point": {"row": 211, "column": 15}}, {"id": 885, "type": "ERROR", "text": "T", "parent": 884, "children": [886], "start_point": {"row": 211, "column": 6}, "end_point": {"row": 211, "column": 7}}, {"id": 886, "type": "identifier", "text": "T", "parent": 885, "children": [], "start_point": {"row": 211, "column": 6}, "end_point": {"row": 211, "column": 7}}, {"id": 887, "type": "*", "text": "*", "parent": 884, "children": [], "start_point": {"row": 211, "column": 8}, "end_point": {"row": 211, "column": 9}}, {"id": 888, "type": "identifier", "text": "Buffer", "parent": 884, "children": [], "start_point": {"row": 211, "column": 9}, "end_point": {"row": 211, "column": 15}}, {"id": 889, "type": "<", "text": "<", "parent": 875, "children": [], "start_point": {"row": 211, "column": 15}, "end_point": {"row": 211, "column": 16}}, {"id": 890, "type": "identifier", "text": "T", "parent": 875, "children": [], "start_point": {"row": 211, "column": 16}, "end_point": {"row": 211, "column": 17}}, {"id": 891, "type": ">", "text": ">", "parent": 874, "children": [], "start_point": {"row": 211, "column": 17}, "end_point": {"row": 211, "column": 18}}, {"id": 892, "type": "call_expression", "text": "get()", "parent": 874, "children": [893, 894], "start_point": {"row": 211, "column": 20}, "end_point": {"row": 211, "column": 25}}, {"id": 893, "type": "identifier", "text": "get", "parent": 892, "children": [], "start_point": {"row": 211, "column": 20}, "end_point": {"row": 211, "column": 23}}, {"id": 894, "type": "argument_list", "text": "()", "parent": 892, "children": [], "start_point": {"row": 211, "column": 23}, "end_point": {"row": 211, "column": 25}}, {"id": 895, "type": "return_statement", "text": "return buffer_;", "parent": 826, "children": [896], "start_point": {"row": 213, "column": 4}, "end_point": {"row": 213, "column": 19}}, {"id": 896, "type": "identifier", "text": "buffer_", "parent": 895, "children": [], "start_point": {"row": 213, "column": 11}, "end_point": {"row": 213, "column": 18}}, {"id": 897, "type": "binary_expression", "text": "template<typename T>\nCUdeviceptr Buffer<T>::get_device_ptr()", "parent": 826, "children": [898, 912, 913], "start_point": {"row": 216, "column": 0}, "end_point": {"row": 217, "column": 39}}, {"id": 898, "type": "binary_expression", "text": "template<typename T>\nCUdeviceptr Buffer<T", "parent": 897, "children": [899, 908, 910, 911], "start_point": {"row": 216, "column": 0}, "end_point": {"row": 217, "column": 20}}, {"id": 899, "type": "binary_expression", "text": "template<typename T>\nCUdeviceptr", "parent": 898, "children": [900, 904, 906, 907], "start_point": {"row": 216, "column": 0}, "end_point": {"row": 217, "column": 11}}, {"id": 900, "type": "binary_expression", "text": "template<typename", "parent": 899, "children": [901, 902, 903], "start_point": {"row": 216, "column": 0}, "end_point": {"row": 216, "column": 17}}, {"id": 901, "type": "identifier", "text": "template", "parent": 900, "children": [], "start_point": {"row": 216, "column": 0}, "end_point": {"row": 216, "column": 8}}, {"id": 902, "type": "<", "text": "<", "parent": 900, "children": [], "start_point": {"row": 216, "column": 8}, "end_point": {"row": 216, "column": 9}}, {"id": 903, "type": "identifier", "text": "typename", "parent": 900, "children": [], "start_point": {"row": 216, "column": 9}, "end_point": {"row": 216, "column": 17}}, {"id": 904, "type": "ERROR", "text": "T", "parent": 899, "children": [905], "start_point": {"row": 216, "column": 18}, "end_point": {"row": 216, "column": 19}}, {"id": 905, "type": "identifier", "text": "T", "parent": 904, "children": [], "start_point": {"row": 216, "column": 18}, "end_point": {"row": 216, "column": 19}}, {"id": 906, "type": ">", "text": ">", "parent": 899, "children": [], "start_point": {"row": 216, "column": 19}, "end_point": {"row": 216, "column": 20}}, {"id": 907, "type": "identifier", "text": "CUdeviceptr", "parent": 899, "children": [], "start_point": {"row": 217, "column": 0}, "end_point": {"row": 217, "column": 11}}, {"id": 908, "type": "ERROR", "text": "Buffer", "parent": 898, "children": [909], "start_point": {"row": 217, "column": 12}, "end_point": {"row": 217, "column": 18}}, {"id": 909, "type": "identifier", "text": "Buffer", "parent": 908, "children": [], "start_point": {"row": 217, "column": 12}, "end_point": {"row": 217, "column": 18}}, {"id": 910, "type": "<", "text": "<", "parent": 898, "children": [], "start_point": {"row": 217, "column": 18}, "end_point": {"row": 217, "column": 19}}, {"id": 911, "type": "identifier", "text": "T", "parent": 898, "children": [], "start_point": {"row": 217, "column": 19}, "end_point": {"row": 217, "column": 20}}, {"id": 912, "type": ">", "text": ">", "parent": 897, "children": [], "start_point": {"row": 217, "column": 20}, "end_point": {"row": 217, "column": 21}}, {"id": 913, "type": "call_expression", "text": "get_device_ptr()", "parent": 897, "children": [914, 915], "start_point": {"row": 217, "column": 23}, "end_point": {"row": 217, "column": 39}}, {"id": 914, "type": "identifier", "text": "get_device_ptr", "parent": 913, "children": [], "start_point": {"row": 217, "column": 23}, "end_point": {"row": 217, "column": 37}}, {"id": 915, "type": "argument_list", "text": "()", "parent": 913, "children": [], "start_point": {"row": 217, "column": 37}, "end_point": {"row": 217, "column": 39}}, {"id": 916, "type": "return_statement", "text": "return reinterpret_cast<CUdeviceptr>(buffer_);", "parent": 826, "children": [917], "start_point": {"row": 219, "column": 4}, "end_point": {"row": 219, "column": 50}}, {"id": 917, "type": "binary_expression", "text": "reinterpret_cast<CUdeviceptr>(buffer_)", "parent": 916, "children": [918, 922, 923], "start_point": {"row": 219, "column": 11}, "end_point": {"row": 219, "column": 49}}, {"id": 918, "type": "binary_expression", "text": "reinterpret_cast<CUdeviceptr", "parent": 917, "children": [919, 920, 921], "start_point": {"row": 219, "column": 11}, "end_point": {"row": 219, "column": 39}}, {"id": 919, "type": "identifier", "text": "reinterpret_cast", "parent": 918, "children": [], "start_point": {"row": 219, "column": 11}, "end_point": {"row": 219, "column": 27}}, {"id": 920, "type": "<", "text": "<", "parent": 918, "children": [], "start_point": {"row": 219, "column": 27}, "end_point": {"row": 219, "column": 28}}, {"id": 921, "type": "identifier", "text": "CUdeviceptr", "parent": 918, "children": [], "start_point": {"row": 219, "column": 28}, "end_point": {"row": 219, "column": 39}}, {"id": 922, "type": ">", "text": ">", "parent": 917, "children": [], "start_point": {"row": 219, "column": 39}, "end_point": {"row": 219, "column": 40}}, {"id": 923, "type": "parenthesized_expression", "text": "(buffer_)", "parent": 917, "children": [924], "start_point": {"row": 219, "column": 40}, "end_point": {"row": 219, "column": 49}}, {"id": 924, "type": "identifier", "text": "buffer_", "parent": 923, "children": [], "start_point": {"row": 219, "column": 41}, "end_point": {"row": 219, "column": 48}}, {"id": 925, "type": "binary_expression", "text": "template<typename T>\ntemplate<typename U>\nU *Buffer<T>::as()", "parent": 826, "children": [926, 949, 950], "start_point": {"row": 222, "column": 0}, "end_point": {"row": 224, "column": 18}}, {"id": 926, "type": "binary_expression", "text": "template<typename T>\ntemplate<typename U>\nU *Buffer<T", "parent": 925, "children": [927, 947, 948], "start_point": {"row": 222, "column": 0}, "end_point": {"row": 224, "column": 11}}, {"id": 927, "type": "binary_expression", "text": "template<typename T>\ntemplate<typename U>\nU *Buffer", "parent": 926, "children": [928, 940, 942, 943], "start_point": {"row": 222, "column": 0}, "end_point": {"row": 224, "column": 9}}, {"id": 928, "type": "binary_expression", "text": "template<typename T>\ntemplate<typename", "parent": 927, "children": [929, 938, 939], "start_point": {"row": 222, "column": 0}, "end_point": {"row": 223, "column": 17}}, {"id": 929, "type": "binary_expression", "text": "template<typename T>\ntemplate", "parent": 928, "children": [930, 934, 936, 937], "start_point": {"row": 222, "column": 0}, "end_point": {"row": 223, "column": 8}}, {"id": 930, "type": "binary_expression", "text": "template<typename", "parent": 929, "children": [931, 932, 933], "start_point": {"row": 222, "column": 0}, "end_point": {"row": 222, "column": 17}}, {"id": 931, "type": "identifier", "text": "template", "parent": 930, "children": [], "start_point": {"row": 222, "column": 0}, "end_point": {"row": 222, "column": 8}}, {"id": 932, "type": "<", "text": "<", "parent": 930, "children": [], "start_point": {"row": 222, "column": 8}, "end_point": {"row": 222, "column": 9}}, {"id": 933, "type": "identifier", "text": "typename", "parent": 930, "children": [], "start_point": {"row": 222, "column": 9}, "end_point": {"row": 222, "column": 17}}, {"id": 934, "type": "ERROR", "text": "T", "parent": 929, "children": [935], "start_point": {"row": 222, "column": 18}, "end_point": {"row": 222, "column": 19}}, {"id": 935, "type": "identifier", "text": "T", "parent": 934, "children": [], "start_point": {"row": 222, "column": 18}, "end_point": {"row": 222, "column": 19}}, {"id": 936, "type": ">", "text": ">", "parent": 929, "children": [], "start_point": {"row": 222, "column": 19}, "end_point": {"row": 222, "column": 20}}, {"id": 937, "type": "identifier", "text": "template", "parent": 929, "children": [], "start_point": {"row": 223, "column": 0}, "end_point": {"row": 223, "column": 8}}, {"id": 938, "type": "<", "text": "<", "parent": 928, "children": [], "start_point": {"row": 223, "column": 8}, "end_point": {"row": 223, "column": 9}}, {"id": 939, "type": "identifier", "text": "typename", "parent": 928, "children": [], "start_point": {"row": 223, "column": 9}, "end_point": {"row": 223, "column": 17}}, {"id": 940, "type": "ERROR", "text": "U", "parent": 927, "children": [941], "start_point": {"row": 223, "column": 18}, "end_point": {"row": 223, "column": 19}}, {"id": 941, "type": "identifier", "text": "U", "parent": 940, "children": [], "start_point": {"row": 223, "column": 18}, "end_point": {"row": 223, "column": 19}}, {"id": 942, "type": ">", "text": ">", "parent": 927, "children": [], "start_point": {"row": 223, "column": 19}, "end_point": {"row": 223, "column": 20}}, {"id": 943, "type": "binary_expression", "text": "U *Buffer", "parent": 927, "children": [944, 945, 946], "start_point": {"row": 224, "column": 0}, "end_point": {"row": 224, "column": 9}}, {"id": 944, "type": "identifier", "text": "U", "parent": 943, "children": [], "start_point": {"row": 224, "column": 0}, "end_point": {"row": 224, "column": 1}}, {"id": 945, "type": "*", "text": "*", "parent": 943, "children": [], "start_point": {"row": 224, "column": 2}, "end_point": {"row": 224, "column": 3}}, {"id": 946, "type": "identifier", "text": "Buffer", "parent": 943, "children": [], "start_point": {"row": 224, "column": 3}, "end_point": {"row": 224, "column": 9}}, {"id": 947, "type": "<", "text": "<", "parent": 926, "children": [], "start_point": {"row": 224, "column": 9}, "end_point": {"row": 224, "column": 10}}, {"id": 948, "type": "identifier", "text": "T", "parent": 926, "children": [], "start_point": {"row": 224, "column": 10}, "end_point": {"row": 224, "column": 11}}, {"id": 949, "type": ">", "text": ">", "parent": 925, "children": [], "start_point": {"row": 224, "column": 11}, "end_point": {"row": 224, "column": 12}}, {"id": 950, "type": "call_expression", "text": "as()", "parent": 925, "children": [951], "start_point": {"row": 224, "column": 14}, "end_point": {"row": 224, "column": 18}}, {"id": 951, "type": "argument_list", "text": "()", "parent": 950, "children": [], "start_point": {"row": 224, "column": 16}, "end_point": {"row": 224, "column": 18}}, {"id": 952, "type": "return_statement", "text": "return reinterpret_cast<U *>(buffer_);", "parent": 826, "children": [953], "start_point": {"row": 226, "column": 4}, "end_point": {"row": 226, "column": 42}}, {"id": 953, "type": "binary_expression", "text": "reinterpret_cast<U *>(buffer_)", "parent": 952, "children": [954, 958, 960, 961], "start_point": {"row": 226, "column": 11}, "end_point": {"row": 226, "column": 41}}, {"id": 954, "type": "binary_expression", "text": "reinterpret_cast<U", "parent": 953, "children": [955, 956, 957], "start_point": {"row": 226, "column": 11}, "end_point": {"row": 226, "column": 29}}, {"id": 955, "type": "identifier", "text": "reinterpret_cast", "parent": 954, "children": [], "start_point": {"row": 226, "column": 11}, "end_point": {"row": 226, "column": 27}}, {"id": 956, "type": "<", "text": "<", "parent": 954, "children": [], "start_point": {"row": 226, "column": 27}, "end_point": {"row": 226, "column": 28}}, {"id": 957, "type": "identifier", "text": "U", "parent": 954, "children": [], "start_point": {"row": 226, "column": 28}, "end_point": {"row": 226, "column": 29}}, {"id": 958, "type": "ERROR", "text": "*", "parent": 953, "children": [959], "start_point": {"row": 226, "column": 30}, "end_point": {"row": 226, "column": 31}}, {"id": 959, "type": "*", "text": "*", "parent": 958, "children": [], "start_point": {"row": 226, "column": 30}, "end_point": {"row": 226, "column": 31}}, {"id": 960, "type": ">", "text": ">", "parent": 953, "children": [], "start_point": {"row": 226, "column": 31}, "end_point": {"row": 226, "column": 32}}, {"id": 961, "type": "parenthesized_expression", "text": "(buffer_)", "parent": 953, "children": [962], "start_point": {"row": 226, "column": 32}, "end_point": {"row": 226, "column": 41}}, {"id": 962, "type": "identifier", "text": "buffer_", "parent": 961, "children": [], "start_point": {"row": 226, "column": 33}, "end_point": {"row": 226, "column": 40}}, {"id": 963, "type": "binary_expression", "text": "template<typename T>\ntemplate<typename U>\nconst U *Buffer<T>::as()", "parent": 826, "children": [964, 988, 989], "start_point": {"row": 229, "column": 0}, "end_point": {"row": 231, "column": 24}}, {"id": 964, "type": "binary_expression", "text": "template<typename T>\ntemplate<typename U>\nconst U *Buffer<T", "parent": 963, "children": [965, 986, 987], "start_point": {"row": 229, "column": 0}, "end_point": {"row": 231, "column": 17}}, {"id": 965, "type": "binary_expression", "text": "template<typename T>\ntemplate<typename U>\nconst U *Buffer", "parent": 964, "children": [966, 978, 980, 981], "start_point": {"row": 229, "column": 0}, "end_point": {"row": 231, "column": 15}}, {"id": 966, "type": "binary_expression", "text": "template<typename T>\ntemplate<typename", "parent": 965, "children": [967, 976, 977], "start_point": {"row": 229, "column": 0}, "end_point": {"row": 230, "column": 17}}, {"id": 967, "type": "binary_expression", "text": "template<typename T>\ntemplate", "parent": 966, "children": [968, 972, 974, 975], "start_point": {"row": 229, "column": 0}, "end_point": {"row": 230, "column": 8}}, {"id": 968, "type": "binary_expression", "text": "template<typename", "parent": 967, "children": [969, 970, 971], "start_point": {"row": 229, "column": 0}, "end_point": {"row": 229, "column": 17}}, {"id": 969, "type": "identifier", "text": "template", "parent": 968, "children": [], "start_point": {"row": 229, "column": 0}, "end_point": {"row": 229, "column": 8}}, {"id": 970, "type": "<", "text": "<", "parent": 968, "children": [], "start_point": {"row": 229, "column": 8}, "end_point": {"row": 229, "column": 9}}, {"id": 971, "type": "identifier", "text": "typename", "parent": 968, "children": [], "start_point": {"row": 229, "column": 9}, "end_point": {"row": 229, "column": 17}}, {"id": 972, "type": "ERROR", "text": "T", "parent": 967, "children": [973], "start_point": {"row": 229, "column": 18}, "end_point": {"row": 229, "column": 19}}, {"id": 973, "type": "identifier", "text": "T", "parent": 972, "children": [], "start_point": {"row": 229, "column": 18}, "end_point": {"row": 229, "column": 19}}, {"id": 974, "type": ">", "text": ">", "parent": 967, "children": [], "start_point": {"row": 229, "column": 19}, "end_point": {"row": 229, "column": 20}}, {"id": 975, "type": "identifier", "text": "template", "parent": 967, "children": [], "start_point": {"row": 230, "column": 0}, "end_point": {"row": 230, "column": 8}}, {"id": 976, "type": "<", "text": "<", "parent": 966, "children": [], "start_point": {"row": 230, "column": 8}, "end_point": {"row": 230, "column": 9}}, {"id": 977, "type": "identifier", "text": "typename", "parent": 966, "children": [], "start_point": {"row": 230, "column": 9}, "end_point": {"row": 230, "column": 17}}, {"id": 978, "type": "ERROR", "text": "U", "parent": 965, "children": [979], "start_point": {"row": 230, "column": 18}, "end_point": {"row": 230, "column": 19}}, {"id": 979, "type": "identifier", "text": "U", "parent": 978, "children": [], "start_point": {"row": 230, "column": 18}, "end_point": {"row": 230, "column": 19}}, {"id": 980, "type": ">", "text": ">", "parent": 965, "children": [], "start_point": {"row": 230, "column": 19}, "end_point": {"row": 230, "column": 20}}, {"id": 981, "type": "binary_expression", "text": "const U *Buffer", "parent": 965, "children": [982, 984, 985], "start_point": {"row": 231, "column": 0}, "end_point": {"row": 231, "column": 15}}, {"id": 982, "type": "ERROR", "text": "U", "parent": 981, "children": [983], "start_point": {"row": 231, "column": 6}, "end_point": {"row": 231, "column": 7}}, {"id": 983, "type": "identifier", "text": "U", "parent": 982, "children": [], "start_point": {"row": 231, "column": 6}, "end_point": {"row": 231, "column": 7}}, {"id": 984, "type": "*", "text": "*", "parent": 981, "children": [], "start_point": {"row": 231, "column": 8}, "end_point": {"row": 231, "column": 9}}, {"id": 985, "type": "identifier", "text": "Buffer", "parent": 981, "children": [], "start_point": {"row": 231, "column": 9}, "end_point": {"row": 231, "column": 15}}, {"id": 986, "type": "<", "text": "<", "parent": 964, "children": [], "start_point": {"row": 231, "column": 15}, "end_point": {"row": 231, "column": 16}}, {"id": 987, "type": "identifier", "text": "T", "parent": 964, "children": [], "start_point": {"row": 231, "column": 16}, "end_point": {"row": 231, "column": 17}}, {"id": 988, "type": ">", "text": ">", "parent": 963, "children": [], "start_point": {"row": 231, "column": 17}, "end_point": {"row": 231, "column": 18}}, {"id": 989, "type": "call_expression", "text": "as()", "parent": 963, "children": [990], "start_point": {"row": 231, "column": 20}, "end_point": {"row": 231, "column": 24}}, {"id": 990, "type": "argument_list", "text": "()", "parent": 989, "children": [], "start_point": {"row": 231, "column": 22}, "end_point": {"row": 231, "column": 24}}, {"id": 991, "type": "return_statement", "text": "return reinterpret_cast<const U *>(buffer_);", "parent": 826, "children": [992], "start_point": {"row": 233, "column": 4}, "end_point": {"row": 233, "column": 48}}, {"id": 992, "type": "binary_expression", "text": "reinterpret_cast<const U *>(buffer_)", "parent": 991, "children": [993, 996, 999, 1000], "start_point": {"row": 233, "column": 11}, "end_point": {"row": 233, "column": 47}}, {"id": 993, "type": "binary_expression", "text": "reinterpret_cast<const", "parent": 992, "children": [994, 995], "start_point": {"row": 233, "column": 11}, "end_point": {"row": 233, "column": 33}}, {"id": 994, "type": "identifier", "text": "reinterpret_cast", "parent": 993, "children": [], "start_point": {"row": 233, "column": 11}, "end_point": {"row": 233, "column": 27}}, {"id": 995, "type": "<", "text": "<", "parent": 993, "children": [], "start_point": {"row": 233, "column": 27}, "end_point": {"row": 233, "column": 28}}, {"id": 996, "type": "ERROR", "text": "U *", "parent": 992, "children": [997, 998], "start_point": {"row": 233, "column": 34}, "end_point": {"row": 233, "column": 37}}, {"id": 997, "type": "identifier", "text": "U", "parent": 996, "children": [], "start_point": {"row": 233, "column": 34}, "end_point": {"row": 233, "column": 35}}, {"id": 998, "type": "*", "text": "*", "parent": 996, "children": [], "start_point": {"row": 233, "column": 36}, "end_point": {"row": 233, "column": 37}}, {"id": 999, "type": ">", "text": ">", "parent": 992, "children": [], "start_point": {"row": 233, "column": 37}, "end_point": {"row": 233, "column": 38}}, {"id": 1000, "type": "parenthesized_expression", "text": "(buffer_)", "parent": 992, "children": [1001], "start_point": {"row": 233, "column": 38}, "end_point": {"row": 233, "column": 47}}, {"id": 1001, "type": "identifier", "text": "buffer_", "parent": 1000, "children": [], "start_point": {"row": 233, "column": 39}, "end_point": {"row": 233, "column": 46}}, {"id": 1002, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T>::clear(const T &val)", "parent": 826, "children": [1003, 1017, 1018], "start_point": {"row": 236, "column": 0}, "end_point": {"row": 237, "column": 35}}, {"id": 1003, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T", "parent": 1002, "children": [1004, 1015, 1016], "start_point": {"row": 236, "column": 0}, "end_point": {"row": 237, "column": 13}}, {"id": 1004, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer", "parent": 1003, "children": [1005, 1009, 1011, 1012, 1014], "start_point": {"row": 236, "column": 0}, "end_point": {"row": 237, "column": 11}}, {"id": 1005, "type": "binary_expression", "text": "template<typename", "parent": 1004, "children": [1006, 1007, 1008], "start_point": {"row": 236, "column": 0}, "end_point": {"row": 236, "column": 17}}, {"id": 1006, "type": "identifier", "text": "template", "parent": 1005, "children": [], "start_point": {"row": 236, "column": 0}, "end_point": {"row": 236, "column": 8}}, {"id": 1007, "type": "<", "text": "<", "parent": 1005, "children": [], "start_point": {"row": 236, "column": 8}, "end_point": {"row": 236, "column": 9}}, {"id": 1008, "type": "identifier", "text": "typename", "parent": 1005, "children": [], "start_point": {"row": 236, "column": 9}, "end_point": {"row": 236, "column": 17}}, {"id": 1009, "type": "ERROR", "text": "T", "parent": 1004, "children": [1010], "start_point": {"row": 236, "column": 18}, "end_point": {"row": 236, "column": 19}}, {"id": 1010, "type": "identifier", "text": "T", "parent": 1009, "children": [], "start_point": {"row": 236, "column": 18}, "end_point": {"row": 236, "column": 19}}, {"id": 1011, "type": ">", "text": ">", "parent": 1004, "children": [], "start_point": {"row": 236, "column": 19}, "end_point": {"row": 236, "column": 20}}, {"id": 1012, "type": "ERROR", "text": "void", "parent": 1004, "children": [1013], "start_point": {"row": 237, "column": 0}, "end_point": {"row": 237, "column": 4}}, {"id": 1013, "type": "identifier", "text": "void", "parent": 1012, "children": [], "start_point": {"row": 237, "column": 0}, "end_point": {"row": 237, "column": 4}}, {"id": 1014, "type": "identifier", "text": "Buffer", "parent": 1004, "children": [], "start_point": {"row": 237, "column": 5}, "end_point": {"row": 237, "column": 11}}, {"id": 1015, "type": "<", "text": "<", "parent": 1003, "children": [], "start_point": {"row": 237, "column": 11}, "end_point": {"row": 237, "column": 12}}, {"id": 1016, "type": "identifier", "text": "T", "parent": 1003, "children": [], "start_point": {"row": 237, "column": 12}, "end_point": {"row": 237, "column": 13}}, {"id": 1017, "type": ">", "text": ">", "parent": 1002, "children": [], "start_point": {"row": 237, "column": 13}, "end_point": {"row": 237, "column": 14}}, {"id": 1018, "type": "call_expression", "text": "clear(const T &val)", "parent": 1002, "children": [1019, 1020], "start_point": {"row": 237, "column": 16}, "end_point": {"row": 237, "column": 35}}, {"id": 1019, "type": "identifier", "text": "clear", "parent": 1018, "children": [], "start_point": {"row": 237, "column": 16}, "end_point": {"row": 237, "column": 21}}, {"id": 1020, "type": "argument_list", "text": "(const T &val)", "parent": 1018, "children": [1021], "start_point": {"row": 237, "column": 21}, "end_point": {"row": 237, "column": 35}}, {"id": 1021, "type": "binary_expression", "text": "const T &val", "parent": 1020, "children": [1022, 1024], "start_point": {"row": 237, "column": 22}, "end_point": {"row": 237, "column": 34}}, {"id": 1022, "type": "ERROR", "text": "T", "parent": 1021, "children": [1023], "start_point": {"row": 237, "column": 28}, "end_point": {"row": 237, "column": 29}}, {"id": 1023, "type": "identifier", "text": "T", "parent": 1022, "children": [], "start_point": {"row": 237, "column": 28}, "end_point": {"row": 237, "column": 29}}, {"id": 1024, "type": "identifier", "text": "val", "parent": 1021, "children": [], "start_point": {"row": 237, "column": 31}, "end_point": {"row": 237, "column": 34}}, {"id": 1025, "type": "call_expression", "text": "assert(!is_empty())", "parent": 826, "children": [1026, 1027], "start_point": {"row": 239, "column": 4}, "end_point": {"row": 239, "column": 23}}, {"id": 1026, "type": "identifier", "text": "assert", "parent": 1025, "children": [], "start_point": {"row": 239, "column": 4}, "end_point": {"row": 239, "column": 10}}, {"id": 1027, "type": "argument_list", "text": "(!is_empty())", "parent": 1025, "children": [1028], "start_point": {"row": 239, "column": 10}, "end_point": {"row": 239, "column": 23}}, {"id": 1028, "type": "unary_expression", "text": "!is_empty()", "parent": 1027, "children": [1029, 1030], "start_point": {"row": 239, "column": 11}, "end_point": {"row": 239, "column": 22}}, {"id": 1029, "type": "!", "text": "!", "parent": 1028, "children": [], "start_point": {"row": 239, "column": 11}, "end_point": {"row": 239, "column": 12}}, {"id": 1030, "type": "call_expression", "text": "is_empty()", "parent": 1028, "children": [1031, 1032], "start_point": {"row": 239, "column": 12}, "end_point": {"row": 239, "column": 22}}, {"id": 1031, "type": "identifier", "text": "is_empty", "parent": 1030, "children": [], "start_point": {"row": 239, "column": 12}, "end_point": {"row": 239, "column": 20}}, {"id": 1032, "type": "argument_list", "text": "()", "parent": 1030, "children": [], "start_point": {"row": 239, "column": 20}, "end_point": {"row": 239, "column": 22}}, {"id": 1033, "type": "labeled_statement", "text": "std::vector<T> vals(elem_count_, val);", "parent": 826, "children": [1034], "start_point": {"row": 240, "column": 4}, "end_point": {"row": 240, "column": 42}}, {"id": 1034, "type": "statement_identifier", "text": "std", "parent": 1033, "children": [], "start_point": {"row": 240, "column": 4}, "end_point": {"row": 240, "column": 7}}, {"id": 1035, "type": "binary_expression", "text": "vector<T> vals(elem_count_, val)", "parent": 1033, "children": [1036, 1040, 1041], "start_point": {"row": 240, "column": 9}, "end_point": {"row": 240, "column": 41}}, {"id": 1036, "type": "binary_expression", "text": "vector<T", "parent": 1035, "children": [1037, 1038, 1039], "start_point": {"row": 240, "column": 9}, "end_point": {"row": 240, "column": 17}}, {"id": 1037, "type": "identifier", "text": "vector", "parent": 1036, "children": [], "start_point": {"row": 240, "column": 9}, "end_point": {"row": 240, "column": 15}}, {"id": 1038, "type": "<", "text": "<", "parent": 1036, "children": [], "start_point": {"row": 240, "column": 15}, "end_point": {"row": 240, "column": 16}}, {"id": 1039, "type": "identifier", "text": "T", "parent": 1036, "children": [], "start_point": {"row": 240, "column": 16}, "end_point": {"row": 240, "column": 17}}, {"id": 1040, "type": ">", "text": ">", "parent": 1035, "children": [], "start_point": {"row": 240, "column": 17}, "end_point": {"row": 240, "column": 18}}, {"id": 1041, "type": "call_expression", "text": "vals(elem_count_, val)", "parent": 1035, "children": [1042, 1043], "start_point": {"row": 240, "column": 19}, "end_point": {"row": 240, "column": 41}}, {"id": 1042, "type": "identifier", "text": "vals", "parent": 1041, "children": [], "start_point": {"row": 240, "column": 19}, "end_point": {"row": 240, "column": 23}}, {"id": 1043, "type": "argument_list", "text": "(elem_count_, val)", "parent": 1041, "children": [1044, 1045], "start_point": {"row": 240, "column": 23}, "end_point": {"row": 240, "column": 41}}, {"id": 1044, "type": "identifier", "text": "elem_count_", "parent": 1043, "children": [], "start_point": {"row": 240, "column": 24}, "end_point": {"row": 240, "column": 35}}, {"id": 1045, "type": "identifier", "text": "val", "parent": 1043, "children": [], "start_point": {"row": 240, "column": 37}, "end_point": {"row": 240, "column": 40}}, {"id": 1046, "type": "call_expression", "text": "this->from_cpu(vals.data())", "parent": 826, "children": [1047, 1050], "start_point": {"row": 241, "column": 4}, "end_point": {"row": 241, "column": 31}}, {"id": 1047, "type": "field_expression", "text": "this->from_cpu", "parent": 1046, "children": [1048, 1049], "start_point": {"row": 241, "column": 4}, "end_point": {"row": 241, "column": 18}}, {"id": 1048, "type": "identifier", "text": "this", "parent": 1047, "children": [], "start_point": {"row": 241, "column": 4}, "end_point": {"row": 241, "column": 8}}, {"id": 1049, "type": "field_identifier", "text": "from_cpu", "parent": 1047, "children": [], "start_point": {"row": 241, "column": 10}, "end_point": {"row": 241, "column": 18}}, {"id": 1050, "type": "argument_list", "text": "(vals.data())", "parent": 1046, "children": [1051], "start_point": {"row": 241, "column": 18}, "end_point": {"row": 241, "column": 31}}, {"id": 1051, "type": "call_expression", "text": "vals.data()", "parent": 1050, "children": [1052, 1055], "start_point": {"row": 241, "column": 19}, "end_point": {"row": 241, "column": 30}}, {"id": 1052, "type": "field_expression", "text": "vals.data", "parent": 1051, "children": [1053, 1054], "start_point": {"row": 241, "column": 19}, "end_point": {"row": 241, "column": 28}}, {"id": 1053, "type": "identifier", "text": "vals", "parent": 1052, "children": [], "start_point": {"row": 241, "column": 19}, "end_point": {"row": 241, "column": 23}}, {"id": 1054, "type": "field_identifier", "text": "data", "parent": 1052, "children": [], "start_point": {"row": 241, "column": 24}, "end_point": {"row": 241, "column": 28}}, {"id": 1055, "type": "argument_list", "text": "()", "parent": 1051, "children": [], "start_point": {"row": 241, "column": 28}, "end_point": {"row": 241, "column": 30}}, {"id": 1056, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T>::clear_async(const T &val)", "parent": 826, "children": [1057, 1071, 1072], "start_point": {"row": 244, "column": 0}, "end_point": {"row": 245, "column": 41}}, {"id": 1057, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T", "parent": 1056, "children": [1058, 1069, 1070], "start_point": {"row": 244, "column": 0}, "end_point": {"row": 245, "column": 13}}, {"id": 1058, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer", "parent": 1057, "children": [1059, 1063, 1065, 1066, 1068], "start_point": {"row": 244, "column": 0}, "end_point": {"row": 245, "column": 11}}, {"id": 1059, "type": "binary_expression", "text": "template<typename", "parent": 1058, "children": [1060, 1061, 1062], "start_point": {"row": 244, "column": 0}, "end_point": {"row": 244, "column": 17}}, {"id": 1060, "type": "identifier", "text": "template", "parent": 1059, "children": [], "start_point": {"row": 244, "column": 0}, "end_point": {"row": 244, "column": 8}}, {"id": 1061, "type": "<", "text": "<", "parent": 1059, "children": [], "start_point": {"row": 244, "column": 8}, "end_point": {"row": 244, "column": 9}}, {"id": 1062, "type": "identifier", "text": "typename", "parent": 1059, "children": [], "start_point": {"row": 244, "column": 9}, "end_point": {"row": 244, "column": 17}}, {"id": 1063, "type": "ERROR", "text": "T", "parent": 1058, "children": [1064], "start_point": {"row": 244, "column": 18}, "end_point": {"row": 244, "column": 19}}, {"id": 1064, "type": "identifier", "text": "T", "parent": 1063, "children": [], "start_point": {"row": 244, "column": 18}, "end_point": {"row": 244, "column": 19}}, {"id": 1065, "type": ">", "text": ">", "parent": 1058, "children": [], "start_point": {"row": 244, "column": 19}, "end_point": {"row": 244, "column": 20}}, {"id": 1066, "type": "ERROR", "text": "void", "parent": 1058, "children": [1067], "start_point": {"row": 245, "column": 0}, "end_point": {"row": 245, "column": 4}}, {"id": 1067, "type": "identifier", "text": "void", "parent": 1066, "children": [], "start_point": {"row": 245, "column": 0}, "end_point": {"row": 245, "column": 4}}, {"id": 1068, "type": "identifier", "text": "Buffer", "parent": 1058, "children": [], "start_point": {"row": 245, "column": 5}, "end_point": {"row": 245, "column": 11}}, {"id": 1069, "type": "<", "text": "<", "parent": 1057, "children": [], "start_point": {"row": 245, "column": 11}, "end_point": {"row": 245, "column": 12}}, {"id": 1070, "type": "identifier", "text": "T", "parent": 1057, "children": [], "start_point": {"row": 245, "column": 12}, "end_point": {"row": 245, "column": 13}}, {"id": 1071, "type": ">", "text": ">", "parent": 1056, "children": [], "start_point": {"row": 245, "column": 13}, "end_point": {"row": 245, "column": 14}}, {"id": 1072, "type": "call_expression", "text": "clear_async(const T &val)", "parent": 1056, "children": [1073, 1074], "start_point": {"row": 245, "column": 16}, "end_point": {"row": 245, "column": 41}}, {"id": 1073, "type": "identifier", "text": "clear_async", "parent": 1072, "children": [], "start_point": {"row": 245, "column": 16}, "end_point": {"row": 245, "column": 27}}, {"id": 1074, "type": "argument_list", "text": "(const T &val)", "parent": 1072, "children": [1075], "start_point": {"row": 245, "column": 27}, "end_point": {"row": 245, "column": 41}}, {"id": 1075, "type": "binary_expression", "text": "const T &val", "parent": 1074, "children": [1076, 1078], "start_point": {"row": 245, "column": 28}, "end_point": {"row": 245, "column": 40}}, {"id": 1076, "type": "ERROR", "text": "T", "parent": 1075, "children": [1077], "start_point": {"row": 245, "column": 34}, "end_point": {"row": 245, "column": 35}}, {"id": 1077, "type": "identifier", "text": "T", "parent": 1076, "children": [], "start_point": {"row": 245, "column": 34}, "end_point": {"row": 245, "column": 35}}, {"id": 1078, "type": "identifier", "text": "val", "parent": 1075, "children": [], "start_point": {"row": 245, "column": 37}, "end_point": {"row": 245, "column": 40}}, {"id": 1079, "type": "call_expression", "text": "assert(!is_empty())", "parent": 826, "children": [1080, 1081], "start_point": {"row": 247, "column": 4}, "end_point": {"row": 247, "column": 23}}, {"id": 1080, "type": "identifier", "text": "assert", "parent": 1079, "children": [], "start_point": {"row": 247, "column": 4}, "end_point": {"row": 247, "column": 10}}, {"id": 1081, "type": "argument_list", "text": "(!is_empty())", "parent": 1079, "children": [1082], "start_point": {"row": 247, "column": 10}, "end_point": {"row": 247, "column": 23}}, {"id": 1082, "type": "unary_expression", "text": "!is_empty()", "parent": 1081, "children": [1083, 1084], "start_point": {"row": 247, "column": 11}, "end_point": {"row": 247, "column": 22}}, {"id": 1083, "type": "!", "text": "!", "parent": 1082, "children": [], "start_point": {"row": 247, "column": 11}, "end_point": {"row": 247, "column": 12}}, {"id": 1084, "type": "call_expression", "text": "is_empty()", "parent": 1082, "children": [1085, 1086], "start_point": {"row": 247, "column": 12}, "end_point": {"row": 247, "column": 22}}, {"id": 1085, "type": "identifier", "text": "is_empty", "parent": 1084, "children": [], "start_point": {"row": 247, "column": 12}, "end_point": {"row": 247, "column": 20}}, {"id": 1086, "type": "argument_list", "text": "()", "parent": 1084, "children": [], "start_point": {"row": 247, "column": 20}, "end_point": {"row": 247, "column": 22}}, {"id": 1087, "type": "labeled_statement", "text": "std::vector<T> vals(elem_count_, val);", "parent": 826, "children": [1088], "start_point": {"row": 248, "column": 4}, "end_point": {"row": 248, "column": 42}}, {"id": 1088, "type": "statement_identifier", "text": "std", "parent": 1087, "children": [], "start_point": {"row": 248, "column": 4}, "end_point": {"row": 248, "column": 7}}, {"id": 1089, "type": "binary_expression", "text": "vector<T> vals(elem_count_, val)", "parent": 1087, "children": [1090, 1094, 1095], "start_point": {"row": 248, "column": 9}, "end_point": {"row": 248, "column": 41}}, {"id": 1090, "type": "binary_expression", "text": "vector<T", "parent": 1089, "children": [1091, 1092, 1093], "start_point": {"row": 248, "column": 9}, "end_point": {"row": 248, "column": 17}}, {"id": 1091, "type": "identifier", "text": "vector", "parent": 1090, "children": [], "start_point": {"row": 248, "column": 9}, "end_point": {"row": 248, "column": 15}}, {"id": 1092, "type": "<", "text": "<", "parent": 1090, "children": [], "start_point": {"row": 248, "column": 15}, "end_point": {"row": 248, "column": 16}}, {"id": 1093, "type": "identifier", "text": "T", "parent": 1090, "children": [], "start_point": {"row": 248, "column": 16}, "end_point": {"row": 248, "column": 17}}, {"id": 1094, "type": ">", "text": ">", "parent": 1089, "children": [], "start_point": {"row": 248, "column": 17}, "end_point": {"row": 248, "column": 18}}, {"id": 1095, "type": "call_expression", "text": "vals(elem_count_, val)", "parent": 1089, "children": [1096, 1097], "start_point": {"row": 248, "column": 19}, "end_point": {"row": 248, "column": 41}}, {"id": 1096, "type": "identifier", "text": "vals", "parent": 1095, "children": [], "start_point": {"row": 248, "column": 19}, "end_point": {"row": 248, "column": 23}}, {"id": 1097, "type": "argument_list", "text": "(elem_count_, val)", "parent": 1095, "children": [1098, 1099], "start_point": {"row": 248, "column": 23}, "end_point": {"row": 248, "column": 41}}, {"id": 1098, "type": "identifier", "text": "elem_count_", "parent": 1097, "children": [], "start_point": {"row": 248, "column": 24}, "end_point": {"row": 248, "column": 35}}, {"id": 1099, "type": "identifier", "text": "val", "parent": 1097, "children": [], "start_point": {"row": 248, "column": 37}, "end_point": {"row": 248, "column": 40}}, {"id": 1100, "type": "call_expression", "text": "from_cpu_async(vals.data())", "parent": 826, "children": [1101, 1102], "start_point": {"row": 249, "column": 4}, "end_point": {"row": 249, "column": 31}}, {"id": 1101, "type": "identifier", "text": "from_cpu_async", "parent": 1100, "children": [], "start_point": {"row": 249, "column": 4}, "end_point": {"row": 249, "column": 18}}, {"id": 1102, "type": "argument_list", "text": "(vals.data())", "parent": 1100, "children": [1103], "start_point": {"row": 249, "column": 18}, "end_point": {"row": 249, "column": 31}}, {"id": 1103, "type": "call_expression", "text": "vals.data()", "parent": 1102, "children": [1104, 1107], "start_point": {"row": 249, "column": 19}, "end_point": {"row": 249, "column": 30}}, {"id": 1104, "type": "field_expression", "text": "vals.data", "parent": 1103, "children": [1105, 1106], "start_point": {"row": 249, "column": 19}, "end_point": {"row": 249, "column": 28}}, {"id": 1105, "type": "identifier", "text": "vals", "parent": 1104, "children": [], "start_point": {"row": 249, "column": 19}, "end_point": {"row": 249, "column": 23}}, {"id": 1106, "type": "field_identifier", "text": "data", "parent": 1104, "children": [], "start_point": {"row": 249, "column": 24}, "end_point": {"row": 249, "column": 28}}, {"id": 1107, "type": "argument_list", "text": "()", "parent": 1103, "children": [], "start_point": {"row": 249, "column": 28}, "end_point": {"row": 249, "column": 30}}, {"id": 1108, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T>::clear_bytes(uint8_t byte)", "parent": 826, "children": [1109, 1123, 1124], "start_point": {"row": 252, "column": 0}, "end_point": {"row": 253, "column": 41}}, {"id": 1109, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T", "parent": 1108, "children": [1110, 1121, 1122], "start_point": {"row": 252, "column": 0}, "end_point": {"row": 253, "column": 13}}, {"id": 1110, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer", "parent": 1109, "children": [1111, 1115, 1117, 1118, 1120], "start_point": {"row": 252, "column": 0}, "end_point": {"row": 253, "column": 11}}, {"id": 1111, "type": "binary_expression", "text": "template<typename", "parent": 1110, "children": [1112, 1113, 1114], "start_point": {"row": 252, "column": 0}, "end_point": {"row": 252, "column": 17}}, {"id": 1112, "type": "identifier", "text": "template", "parent": 1111, "children": [], "start_point": {"row": 252, "column": 0}, "end_point": {"row": 252, "column": 8}}, {"id": 1113, "type": "<", "text": "<", "parent": 1111, "children": [], "start_point": {"row": 252, "column": 8}, "end_point": {"row": 252, "column": 9}}, {"id": 1114, "type": "identifier", "text": "typename", "parent": 1111, "children": [], "start_point": {"row": 252, "column": 9}, "end_point": {"row": 252, "column": 17}}, {"id": 1115, "type": "ERROR", "text": "T", "parent": 1110, "children": [1116], "start_point": {"row": 252, "column": 18}, "end_point": {"row": 252, "column": 19}}, {"id": 1116, "type": "identifier", "text": "T", "parent": 1115, "children": [], "start_point": {"row": 252, "column": 18}, "end_point": {"row": 252, "column": 19}}, {"id": 1117, "type": ">", "text": ">", "parent": 1110, "children": [], "start_point": {"row": 252, "column": 19}, "end_point": {"row": 252, "column": 20}}, {"id": 1118, "type": "ERROR", "text": "void", "parent": 1110, "children": [1119], "start_point": {"row": 253, "column": 0}, "end_point": {"row": 253, "column": 4}}, {"id": 1119, "type": "identifier", "text": "void", "parent": 1118, "children": [], "start_point": {"row": 253, "column": 0}, "end_point": {"row": 253, "column": 4}}, {"id": 1120, "type": "identifier", "text": "Buffer", "parent": 1110, "children": [], "start_point": {"row": 253, "column": 5}, "end_point": {"row": 253, "column": 11}}, {"id": 1121, "type": "<", "text": "<", "parent": 1109, "children": [], "start_point": {"row": 253, "column": 11}, "end_point": {"row": 253, "column": 12}}, {"id": 1122, "type": "identifier", "text": "T", "parent": 1109, "children": [], "start_point": {"row": 253, "column": 12}, "end_point": {"row": 253, "column": 13}}, {"id": 1123, "type": ">", "text": ">", "parent": 1108, "children": [], "start_point": {"row": 253, "column": 13}, "end_point": {"row": 253, "column": 14}}, {"id": 1124, "type": "call_expression", "text": "clear_bytes(uint8_t byte)", "parent": 1108, "children": [1125, 1126], "start_point": {"row": 253, "column": 16}, "end_point": {"row": 253, "column": 41}}, {"id": 1125, "type": "identifier", "text": "clear_bytes", "parent": 1124, "children": [], "start_point": {"row": 253, "column": 16}, "end_point": {"row": 253, "column": 27}}, {"id": 1126, "type": "argument_list", "text": "(uint8_t byte)", "parent": 1124, "children": [1127, 1128], "start_point": {"row": 253, "column": 27}, "end_point": {"row": 253, "column": 41}}, {"id": 1127, "type": "identifier", "text": "uint8_t", "parent": 1126, "children": [], "start_point": {"row": 253, "column": 28}, "end_point": {"row": 253, "column": 35}}, {"id": 1128, "type": "ERROR", "text": "byte", "parent": 1126, "children": [1129], "start_point": {"row": 253, "column": 36}, "end_point": {"row": 253, "column": 40}}, {"id": 1129, "type": "identifier", "text": "byte", "parent": 1128, "children": [], "start_point": {"row": 253, "column": 36}, "end_point": {"row": 253, "column": 40}}, {"id": 1130, "type": "call_expression", "text": "assert(!is_empty())", "parent": 826, "children": [1131, 1132], "start_point": {"row": 255, "column": 4}, "end_point": {"row": 255, "column": 23}}, {"id": 1131, "type": "identifier", "text": "assert", "parent": 1130, "children": [], "start_point": {"row": 255, "column": 4}, "end_point": {"row": 255, "column": 10}}, {"id": 1132, "type": "argument_list", "text": "(!is_empty())", "parent": 1130, "children": [1133], "start_point": {"row": 255, "column": 10}, "end_point": {"row": 255, "column": 23}}, {"id": 1133, "type": "unary_expression", "text": "!is_empty()", "parent": 1132, "children": [1134, 1135], "start_point": {"row": 255, "column": 11}, "end_point": {"row": 255, "column": 22}}, {"id": 1134, "type": "!", "text": "!", "parent": 1133, "children": [], "start_point": {"row": 255, "column": 11}, "end_point": {"row": 255, "column": 12}}, {"id": 1135, "type": "call_expression", "text": "is_empty()", "parent": 1133, "children": [1136, 1137], "start_point": {"row": 255, "column": 12}, "end_point": {"row": 255, "column": 22}}, {"id": 1136, "type": "identifier", "text": "is_empty", "parent": 1135, "children": [], "start_point": {"row": 255, "column": 12}, "end_point": {"row": 255, "column": 20}}, {"id": 1137, "type": "argument_list", "text": "()", "parent": 1135, "children": [], "start_point": {"row": 255, "column": 20}, "end_point": {"row": 255, "column": 22}}, {"id": 1138, "type": "call_expression", "text": "throw_on_error(cudaMemset(buffer_, byte, get_size_in_bytes()))", "parent": 826, "children": [1139, 1140], "start_point": {"row": 256, "column": 4}, "end_point": {"row": 256, "column": 66}}, {"id": 1139, "type": "identifier", "text": "throw_on_error", "parent": 1138, "children": [], "start_point": {"row": 256, "column": 4}, "end_point": {"row": 256, "column": 18}}, {"id": 1140, "type": "argument_list", "text": "(cudaMemset(buffer_, byte, get_size_in_bytes()))", "parent": 1138, "children": [1141], "start_point": {"row": 256, "column": 18}, "end_point": {"row": 256, "column": 66}}, {"id": 1141, "type": "call_expression", "text": "cudaMemset(buffer_, byte, get_size_in_bytes())", "parent": 1140, "children": [1142, 1143], "start_point": {"row": 256, "column": 19}, "end_point": {"row": 256, "column": 65}}, {"id": 1142, "type": "identifier", "text": "cudaMemset", "parent": 1141, "children": [], "start_point": {"row": 256, "column": 19}, "end_point": {"row": 256, "column": 29}}, {"id": 1143, "type": "argument_list", "text": "(buffer_, byte, get_size_in_bytes())", "parent": 1141, "children": [1144, 1145, 1146], "start_point": {"row": 256, "column": 29}, "end_point": {"row": 256, "column": 65}}, {"id": 1144, "type": "identifier", "text": "buffer_", "parent": 1143, "children": [], "start_point": {"row": 256, "column": 30}, "end_point": {"row": 256, "column": 37}}, {"id": 1145, "type": "identifier", "text": "byte", "parent": 1143, "children": [], "start_point": {"row": 256, "column": 39}, "end_point": {"row": 256, "column": 43}}, {"id": 1146, "type": "call_expression", "text": "get_size_in_bytes()", "parent": 1143, "children": [1147, 1148], "start_point": {"row": 256, "column": 45}, "end_point": {"row": 256, "column": 64}}, {"id": 1147, "type": "identifier", "text": "get_size_in_bytes", "parent": 1146, "children": [], "start_point": {"row": 256, "column": 45}, "end_point": {"row": 256, "column": 62}}, {"id": 1148, "type": "argument_list", "text": "()", "parent": 1146, "children": [], "start_point": {"row": 256, "column": 62}, "end_point": {"row": 256, "column": 64}}, {"id": 1149, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T>::clear_bytes_async(uint8_t byte)", "parent": 826, "children": [1150, 1164, 1165], "start_point": {"row": 259, "column": 0}, "end_point": {"row": 260, "column": 47}}, {"id": 1150, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T", "parent": 1149, "children": [1151, 1162, 1163], "start_point": {"row": 259, "column": 0}, "end_point": {"row": 260, "column": 13}}, {"id": 1151, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer", "parent": 1150, "children": [1152, 1156, 1158, 1159, 1161], "start_point": {"row": 259, "column": 0}, "end_point": {"row": 260, "column": 11}}, {"id": 1152, "type": "binary_expression", "text": "template<typename", "parent": 1151, "children": [1153, 1154, 1155], "start_point": {"row": 259, "column": 0}, "end_point": {"row": 259, "column": 17}}, {"id": 1153, "type": "identifier", "text": "template", "parent": 1152, "children": [], "start_point": {"row": 259, "column": 0}, "end_point": {"row": 259, "column": 8}}, {"id": 1154, "type": "<", "text": "<", "parent": 1152, "children": [], "start_point": {"row": 259, "column": 8}, "end_point": {"row": 259, "column": 9}}, {"id": 1155, "type": "identifier", "text": "typename", "parent": 1152, "children": [], "start_point": {"row": 259, "column": 9}, "end_point": {"row": 259, "column": 17}}, {"id": 1156, "type": "ERROR", "text": "T", "parent": 1151, "children": [1157], "start_point": {"row": 259, "column": 18}, "end_point": {"row": 259, "column": 19}}, {"id": 1157, "type": "identifier", "text": "T", "parent": 1156, "children": [], "start_point": {"row": 259, "column": 18}, "end_point": {"row": 259, "column": 19}}, {"id": 1158, "type": ">", "text": ">", "parent": 1151, "children": [], "start_point": {"row": 259, "column": 19}, "end_point": {"row": 259, "column": 20}}, {"id": 1159, "type": "ERROR", "text": "void", "parent": 1151, "children": [1160], "start_point": {"row": 260, "column": 0}, "end_point": {"row": 260, "column": 4}}, {"id": 1160, "type": "identifier", "text": "void", "parent": 1159, "children": [], "start_point": {"row": 260, "column": 0}, "end_point": {"row": 260, "column": 4}}, {"id": 1161, "type": "identifier", "text": "Buffer", "parent": 1151, "children": [], "start_point": {"row": 260, "column": 5}, "end_point": {"row": 260, "column": 11}}, {"id": 1162, "type": "<", "text": "<", "parent": 1150, "children": [], "start_point": {"row": 260, "column": 11}, "end_point": {"row": 260, "column": 12}}, {"id": 1163, "type": "identifier", "text": "T", "parent": 1150, "children": [], "start_point": {"row": 260, "column": 12}, "end_point": {"row": 260, "column": 13}}, {"id": 1164, "type": ">", "text": ">", "parent": 1149, "children": [], "start_point": {"row": 260, "column": 13}, "end_point": {"row": 260, "column": 14}}, {"id": 1165, "type": "call_expression", "text": "clear_bytes_async(uint8_t byte)", "parent": 1149, "children": [1166, 1167], "start_point": {"row": 260, "column": 16}, "end_point": {"row": 260, "column": 47}}, {"id": 1166, "type": "identifier", "text": "clear_bytes_async", "parent": 1165, "children": [], "start_point": {"row": 260, "column": 16}, "end_point": {"row": 260, "column": 33}}, {"id": 1167, "type": "argument_list", "text": "(uint8_t byte)", "parent": 1165, "children": [1168, 1169], "start_point": {"row": 260, "column": 33}, "end_point": {"row": 260, "column": 47}}, {"id": 1168, "type": "identifier", "text": "uint8_t", "parent": 1167, "children": [], "start_point": {"row": 260, "column": 34}, "end_point": {"row": 260, "column": 41}}, {"id": 1169, "type": "ERROR", "text": "byte", "parent": 1167, "children": [1170], "start_point": {"row": 260, "column": 42}, "end_point": {"row": 260, "column": 46}}, {"id": 1170, "type": "identifier", "text": "byte", "parent": 1169, "children": [], "start_point": {"row": 260, "column": 42}, "end_point": {"row": 260, "column": 46}}, {"id": 1171, "type": "call_expression", "text": "assert(!is_empty())", "parent": 826, "children": [1172, 1173], "start_point": {"row": 262, "column": 4}, "end_point": {"row": 262, "column": 23}}, {"id": 1172, "type": "identifier", "text": "assert", "parent": 1171, "children": [], "start_point": {"row": 262, "column": 4}, "end_point": {"row": 262, "column": 10}}, {"id": 1173, "type": "argument_list", "text": "(!is_empty())", "parent": 1171, "children": [1174], "start_point": {"row": 262, "column": 10}, "end_point": {"row": 262, "column": 23}}, {"id": 1174, "type": "unary_expression", "text": "!is_empty()", "parent": 1173, "children": [1175, 1176], "start_point": {"row": 262, "column": 11}, "end_point": {"row": 262, "column": 22}}, {"id": 1175, "type": "!", "text": "!", "parent": 1174, "children": [], "start_point": {"row": 262, "column": 11}, "end_point": {"row": 262, "column": 12}}, {"id": 1176, "type": "call_expression", "text": "is_empty()", "parent": 1174, "children": [1177, 1178], "start_point": {"row": 262, "column": 12}, "end_point": {"row": 262, "column": 22}}, {"id": 1177, "type": "identifier", "text": "is_empty", "parent": 1176, "children": [], "start_point": {"row": 262, "column": 12}, "end_point": {"row": 262, "column": 20}}, {"id": 1178, "type": "argument_list", "text": "()", "parent": 1176, "children": [], "start_point": {"row": 262, "column": 20}, "end_point": {"row": 262, "column": 22}}, {"id": 1179, "type": "call_expression", "text": "throw_on_error(cudaMemsetAsync(buffer_, byte, get_size_in_bytes()))", "parent": 826, "children": [1180, 1181], "start_point": {"row": 263, "column": 4}, "end_point": {"row": 263, "column": 71}}, {"id": 1180, "type": "identifier", "text": "throw_on_error", "parent": 1179, "children": [], "start_point": {"row": 263, "column": 4}, "end_point": {"row": 263, "column": 18}}, {"id": 1181, "type": "argument_list", "text": "(cudaMemsetAsync(buffer_, byte, get_size_in_bytes()))", "parent": 1179, "children": [1182], "start_point": {"row": 263, "column": 18}, "end_point": {"row": 263, "column": 71}}, {"id": 1182, "type": "call_expression", "text": "cudaMemsetAsync(buffer_, byte, get_size_in_bytes())", "parent": 1181, "children": [1183, 1184], "start_point": {"row": 263, "column": 19}, "end_point": {"row": 263, "column": 70}}, {"id": 1183, "type": "identifier", "text": "cudaMemsetAsync", "parent": 1182, "children": [], "start_point": {"row": 263, "column": 19}, "end_point": {"row": 263, "column": 34}}, {"id": 1184, "type": "argument_list", "text": "(buffer_, byte, get_size_in_bytes())", "parent": 1182, "children": [1185, 1186, 1187], "start_point": {"row": 263, "column": 34}, "end_point": {"row": 263, "column": 70}}, {"id": 1185, "type": "identifier", "text": "buffer_", "parent": 1184, "children": [], "start_point": {"row": 263, "column": 35}, "end_point": {"row": 263, "column": 42}}, {"id": 1186, "type": "identifier", "text": "byte", "parent": 1184, "children": [], "start_point": {"row": 263, "column": 44}, "end_point": {"row": 263, "column": 48}}, {"id": 1187, "type": "call_expression", "text": "get_size_in_bytes()", "parent": 1184, "children": [1188, 1189], "start_point": {"row": 263, "column": 50}, "end_point": {"row": 263, "column": 69}}, {"id": 1188, "type": "identifier", "text": "get_size_in_bytes", "parent": 1187, "children": [], "start_point": {"row": 263, "column": 50}, "end_point": {"row": 263, "column": 67}}, {"id": 1189, "type": "argument_list", "text": "()", "parent": 1187, "children": [], "start_point": {"row": 263, "column": 67}, "end_point": {"row": 263, "column": 69}}, {"id": 1190, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T>::from_cpu(const T *cpu_data, size_t beg, size_t end)", "parent": 826, "children": [1191, 1205, 1206], "start_point": {"row": 266, "column": 0}, "end_point": {"row": 267, "column": 67}}, {"id": 1191, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T", "parent": 1190, "children": [1192, 1203, 1204], "start_point": {"row": 266, "column": 0}, "end_point": {"row": 267, "column": 13}}, {"id": 1192, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer", "parent": 1191, "children": [1193, 1197, 1199, 1200, 1202], "start_point": {"row": 266, "column": 0}, "end_point": {"row": 267, "column": 11}}, {"id": 1193, "type": "binary_expression", "text": "template<typename", "parent": 1192, "children": [1194, 1195, 1196], "start_point": {"row": 266, "column": 0}, "end_point": {"row": 266, "column": 17}}, {"id": 1194, "type": "identifier", "text": "template", "parent": 1193, "children": [], "start_point": {"row": 266, "column": 0}, "end_point": {"row": 266, "column": 8}}, {"id": 1195, "type": "<", "text": "<", "parent": 1193, "children": [], "start_point": {"row": 266, "column": 8}, "end_point": {"row": 266, "column": 9}}, {"id": 1196, "type": "identifier", "text": "typename", "parent": 1193, "children": [], "start_point": {"row": 266, "column": 9}, "end_point": {"row": 266, "column": 17}}, {"id": 1197, "type": "ERROR", "text": "T", "parent": 1192, "children": [1198], "start_point": {"row": 266, "column": 18}, "end_point": {"row": 266, "column": 19}}, {"id": 1198, "type": "identifier", "text": "T", "parent": 1197, "children": [], "start_point": {"row": 266, "column": 18}, "end_point": {"row": 266, "column": 19}}, {"id": 1199, "type": ">", "text": ">", "parent": 1192, "children": [], "start_point": {"row": 266, "column": 19}, "end_point": {"row": 266, "column": 20}}, {"id": 1200, "type": "ERROR", "text": "void", "parent": 1192, "children": [1201], "start_point": {"row": 267, "column": 0}, "end_point": {"row": 267, "column": 4}}, {"id": 1201, "type": "identifier", "text": "void", "parent": 1200, "children": [], "start_point": {"row": 267, "column": 0}, "end_point": {"row": 267, "column": 4}}, {"id": 1202, "type": "identifier", "text": "Buffer", "parent": 1192, "children": [], "start_point": {"row": 267, "column": 5}, "end_point": {"row": 267, "column": 11}}, {"id": 1203, "type": "<", "text": "<", "parent": 1191, "children": [], "start_point": {"row": 267, "column": 11}, "end_point": {"row": 267, "column": 12}}, {"id": 1204, "type": "identifier", "text": "T", "parent": 1191, "children": [], "start_point": {"row": 267, "column": 12}, "end_point": {"row": 267, "column": 13}}, {"id": 1205, "type": ">", "text": ">", "parent": 1190, "children": [], "start_point": {"row": 267, "column": 13}, "end_point": {"row": 267, "column": 14}}, {"id": 1206, "type": "call_expression", "text": "from_cpu(const T *cpu_data, size_t beg, size_t end)", "parent": 1190, "children": [1207, 1208], "start_point": {"row": 267, "column": 16}, "end_point": {"row": 267, "column": 67}}, {"id": 1207, "type": "identifier", "text": "from_cpu", "parent": 1206, "children": [], "start_point": {"row": 267, "column": 16}, "end_point": {"row": 267, "column": 24}}, {"id": 1208, "type": "argument_list", "text": "(const T *cpu_data, size_t beg, size_t end)", "parent": 1206, "children": [1209, 1214, 1215, 1217], "start_point": {"row": 267, "column": 24}, "end_point": {"row": 267, "column": 67}}, {"id": 1209, "type": "binary_expression", "text": "const T *cpu_data", "parent": 1208, "children": [1210, 1212, 1213], "start_point": {"row": 267, "column": 25}, "end_point": {"row": 267, "column": 42}}, {"id": 1210, "type": "ERROR", "text": "T", "parent": 1209, "children": [1211], "start_point": {"row": 267, "column": 31}, "end_point": {"row": 267, "column": 32}}, {"id": 1211, "type": "identifier", "text": "T", "parent": 1210, "children": [], "start_point": {"row": 267, "column": 31}, "end_point": {"row": 267, "column": 32}}, {"id": 1212, "type": "*", "text": "*", "parent": 1209, "children": [], "start_point": {"row": 267, "column": 33}, "end_point": {"row": 267, "column": 34}}, {"id": 1213, "type": "identifier", "text": "cpu_data", "parent": 1209, "children": [], "start_point": {"row": 267, "column": 34}, "end_point": {"row": 267, "column": 42}}, {"id": 1214, "type": "identifier", "text": "size_t", "parent": 1208, "children": [], "start_point": {"row": 267, "column": 44}, "end_point": {"row": 267, "column": 50}}, {"id": 1215, "type": "ERROR", "text": "beg", "parent": 1208, "children": [1216], "start_point": {"row": 267, "column": 51}, "end_point": {"row": 267, "column": 54}}, {"id": 1216, "type": "identifier", "text": "beg", "parent": 1215, "children": [], "start_point": {"row": 267, "column": 51}, "end_point": {"row": 267, "column": 54}}, {"id": 1217, "type": "identifier", "text": "size_t", "parent": 1208, "children": [], "start_point": {"row": 267, "column": 56}, "end_point": {"row": 267, "column": 62}}, {"id": 1218, "type": "if_statement", "text": "if(end <= beg)\n end = elem_count_;", "parent": 826, "children": [1219], "start_point": {"row": 269, "column": 4}, "end_point": {"row": 270, "column": 26}}, {"id": 1219, "type": "parenthesized_expression", "text": "(end <= beg)", "parent": 1218, "children": [1220], "start_point": {"row": 269, "column": 6}, "end_point": {"row": 269, "column": 18}}, {"id": 1220, "type": "binary_expression", "text": "end <= beg", "parent": 1219, "children": [1221, 1222], "start_point": {"row": 269, "column": 7}, "end_point": {"row": 269, "column": 17}}, {"id": 1221, "type": "<=", "text": "<=", "parent": 1220, "children": [], "start_point": {"row": 269, "column": 11}, "end_point": {"row": 269, "column": 13}}, {"id": 1222, "type": "identifier", "text": "beg", "parent": 1220, "children": [], "start_point": {"row": 269, "column": 14}, "end_point": {"row": 269, "column": 17}}, {"id": 1223, "type": "assignment_expression", "text": "end = elem_count_", "parent": 1218, "children": [1224, 1225], "start_point": {"row": 270, "column": 8}, "end_point": {"row": 270, "column": 25}}, {"id": 1224, "type": "=", "text": "=", "parent": 1223, "children": [], "start_point": {"row": 270, "column": 12}, "end_point": {"row": 270, "column": 13}}, {"id": 1225, "type": "identifier", "text": "elem_count_", "parent": 1223, "children": [], "start_point": {"row": 270, "column": 14}, "end_point": {"row": 270, "column": 25}}, {"id": 1226, "type": "call_expression", "text": "assert(beg < end)", "parent": 826, "children": [1227, 1228], "start_point": {"row": 271, "column": 4}, "end_point": {"row": 271, "column": 21}}, {"id": 1227, "type": "identifier", "text": "assert", "parent": 1226, "children": [], "start_point": {"row": 271, "column": 4}, "end_point": {"row": 271, "column": 10}}, {"id": 1228, "type": "argument_list", "text": "(beg < end)", "parent": 1226, "children": [1229], "start_point": {"row": 271, "column": 10}, "end_point": {"row": 271, "column": 21}}, {"id": 1229, "type": "binary_expression", "text": "beg < end", "parent": 1228, "children": [1230, 1231], "start_point": {"row": 271, "column": 11}, "end_point": {"row": 271, "column": 20}}, {"id": 1230, "type": "identifier", "text": "beg", "parent": 1229, "children": [], "start_point": {"row": 271, "column": 11}, "end_point": {"row": 271, "column": 14}}, {"id": 1231, "type": "<", "text": "<", "parent": 1229, "children": [], "start_point": {"row": 271, "column": 15}, "end_point": {"row": 271, "column": 16}}, {"id": 1232, "type": "declaration", "text": "const size_t bytes = sizeof(T) * (end - beg);", "parent": 826, "children": [1233, 1234], "start_point": {"row": 272, "column": 4}, "end_point": {"row": 272, "column": 49}}, {"id": 1233, "type": "primitive_type", "text": "size_t", "parent": 1232, "children": [], "start_point": {"row": 272, "column": 10}, "end_point": {"row": 272, "column": 16}}, {"id": 1234, "type": "init_declarator", "text": "bytes = sizeof(T) * (end - beg)", "parent": 1232, "children": [1235, 1236, 1237], "start_point": {"row": 272, "column": 17}, "end_point": {"row": 272, "column": 48}}, {"id": 1235, "type": "identifier", "text": "bytes", "parent": 1234, "children": [], "start_point": {"row": 272, "column": 17}, "end_point": {"row": 272, "column": 22}}, {"id": 1236, "type": "=", "text": "=", "parent": 1234, "children": [], "start_point": {"row": 272, "column": 23}, "end_point": {"row": 272, "column": 24}}, {"id": 1237, "type": "binary_expression", "text": "sizeof(T) * (end - beg)", "parent": 1234, "children": [1238, 1241, 1242], "start_point": {"row": 272, "column": 25}, "end_point": {"row": 272, "column": 48}}, {"id": 1238, "type": "sizeof_expression", "text": "sizeof(T)", "parent": 1237, "children": [1239], "start_point": {"row": 272, "column": 25}, "end_point": {"row": 272, "column": 34}}, {"id": 1239, "type": "parenthesized_expression", "text": "(T)", "parent": 1238, "children": [1240], "start_point": {"row": 272, "column": 31}, "end_point": {"row": 272, "column": 34}}, {"id": 1240, "type": "identifier", "text": "T", "parent": 1239, "children": [], "start_point": {"row": 272, "column": 32}, "end_point": {"row": 272, "column": 33}}, {"id": 1241, "type": "*", "text": "*", "parent": 1237, "children": [], "start_point": {"row": 272, "column": 35}, "end_point": {"row": 272, "column": 36}}, {"id": 1242, "type": "parenthesized_expression", "text": "(end - beg)", "parent": 1237, "children": [1243], "start_point": {"row": 272, "column": 37}, "end_point": {"row": 272, "column": 48}}, {"id": 1243, "type": "binary_expression", "text": "end - beg", "parent": 1242, "children": [1244, 1245], "start_point": {"row": 272, "column": 38}, "end_point": {"row": 272, "column": 47}}, {"id": 1244, "type": "-", "text": "-", "parent": 1243, "children": [], "start_point": {"row": 272, "column": 42}, "end_point": {"row": 272, "column": 43}}, {"id": 1245, "type": "identifier", "text": "beg", "parent": 1243, "children": [], "start_point": {"row": 272, "column": 44}, "end_point": {"row": 272, "column": 47}}, {"id": 1246, "type": "call_expression", "text": "throw_on_error(cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice))", "parent": 826, "children": [1247, 1248], "start_point": {"row": 273, "column": 4}, "end_point": {"row": 274, "column": 64}}, {"id": 1247, "type": "identifier", "text": "throw_on_error", "parent": 1246, "children": [], "start_point": {"row": 273, "column": 4}, "end_point": {"row": 273, "column": 18}}, {"id": 1248, "type": "argument_list", "text": "(cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice))", "parent": 1246, "children": [1249], "start_point": {"row": 273, "column": 18}, "end_point": {"row": 274, "column": 64}}, {"id": 1249, "type": "call_expression", "text": "cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice)", "parent": 1248, "children": [1250, 1251], "start_point": {"row": 273, "column": 19}, "end_point": {"row": 274, "column": 63}}, {"id": 1250, "type": "identifier", "text": "cudaMemcpy", "parent": 1249, "children": [], "start_point": {"row": 273, "column": 19}, "end_point": {"row": 273, "column": 29}}, {"id": 1251, "type": "argument_list", "text": "(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice)", "parent": 1249, "children": [1252, 1256, 1257, 1258], "start_point": {"row": 273, "column": 29}, "end_point": {"row": 274, "column": 63}}, {"id": 1252, "type": "binary_expression", "text": "buffer_ + beg", "parent": 1251, "children": [1253, 1254, 1255], "start_point": {"row": 274, "column": 8}, "end_point": {"row": 274, "column": 21}}, {"id": 1253, "type": "identifier", "text": "buffer_", "parent": 1252, "children": [], "start_point": {"row": 274, "column": 8}, "end_point": {"row": 274, "column": 15}}, {"id": 1254, "type": "+", "text": "+", "parent": 1252, "children": [], "start_point": {"row": 274, "column": 16}, "end_point": {"row": 274, "column": 17}}, {"id": 1255, "type": "identifier", "text": "beg", "parent": 1252, "children": [], "start_point": {"row": 274, "column": 18}, "end_point": {"row": 274, "column": 21}}, {"id": 1256, "type": "identifier", "text": "cpu_data", "parent": 1251, "children": [], "start_point": {"row": 274, "column": 23}, "end_point": {"row": 274, "column": 31}}, {"id": 1257, "type": "identifier", "text": "bytes", "parent": 1251, "children": [], "start_point": {"row": 274, "column": 33}, "end_point": {"row": 274, "column": 38}}, {"id": 1258, "type": "identifier", "text": "cudaMemcpyHostToDevice", "parent": 1251, "children": [], "start_point": {"row": 274, "column": 40}, "end_point": {"row": 274, "column": 62}}, {"id": 1259, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T>::from_cpu_async(const T *cpu_data, size_t beg, size_t end)", "parent": 826, "children": [1260, 1274, 1275], "start_point": {"row": 277, "column": 0}, "end_point": {"row": 278, "column": 73}}, {"id": 1260, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T", "parent": 1259, "children": [1261, 1272, 1273], "start_point": {"row": 277, "column": 0}, "end_point": {"row": 278, "column": 13}}, {"id": 1261, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer", "parent": 1260, "children": [1262, 1266, 1268, 1269, 1271], "start_point": {"row": 277, "column": 0}, "end_point": {"row": 278, "column": 11}}, {"id": 1262, "type": "binary_expression", "text": "template<typename", "parent": 1261, "children": [1263, 1264, 1265], "start_point": {"row": 277, "column": 0}, "end_point": {"row": 277, "column": 17}}, {"id": 1263, "type": "identifier", "text": "template", "parent": 1262, "children": [], "start_point": {"row": 277, "column": 0}, "end_point": {"row": 277, "column": 8}}, {"id": 1264, "type": "<", "text": "<", "parent": 1262, "children": [], "start_point": {"row": 277, "column": 8}, "end_point": {"row": 277, "column": 9}}, {"id": 1265, "type": "identifier", "text": "typename", "parent": 1262, "children": [], "start_point": {"row": 277, "column": 9}, "end_point": {"row": 277, "column": 17}}, {"id": 1266, "type": "ERROR", "text": "T", "parent": 1261, "children": [1267], "start_point": {"row": 277, "column": 18}, "end_point": {"row": 277, "column": 19}}, {"id": 1267, "type": "identifier", "text": "T", "parent": 1266, "children": [], "start_point": {"row": 277, "column": 18}, "end_point": {"row": 277, "column": 19}}, {"id": 1268, "type": ">", "text": ">", "parent": 1261, "children": [], "start_point": {"row": 277, "column": 19}, "end_point": {"row": 277, "column": 20}}, {"id": 1269, "type": "ERROR", "text": "void", "parent": 1261, "children": [1270], "start_point": {"row": 278, "column": 0}, "end_point": {"row": 278, "column": 4}}, {"id": 1270, "type": "identifier", "text": "void", "parent": 1269, "children": [], "start_point": {"row": 278, "column": 0}, "end_point": {"row": 278, "column": 4}}, {"id": 1271, "type": "identifier", "text": "Buffer", "parent": 1261, "children": [], "start_point": {"row": 278, "column": 5}, "end_point": {"row": 278, "column": 11}}, {"id": 1272, "type": "<", "text": "<", "parent": 1260, "children": [], "start_point": {"row": 278, "column": 11}, "end_point": {"row": 278, "column": 12}}, {"id": 1273, "type": "identifier", "text": "T", "parent": 1260, "children": [], "start_point": {"row": 278, "column": 12}, "end_point": {"row": 278, "column": 13}}, {"id": 1274, "type": ">", "text": ">", "parent": 1259, "children": [], "start_point": {"row": 278, "column": 13}, "end_point": {"row": 278, "column": 14}}, {"id": 1275, "type": "call_expression", "text": "from_cpu_async(const T *cpu_data, size_t beg, size_t end)", "parent": 1259, "children": [1276, 1277], "start_point": {"row": 278, "column": 16}, "end_point": {"row": 278, "column": 73}}, {"id": 1276, "type": "identifier", "text": "from_cpu_async", "parent": 1275, "children": [], "start_point": {"row": 278, "column": 16}, "end_point": {"row": 278, "column": 30}}, {"id": 1277, "type": "argument_list", "text": "(const T *cpu_data, size_t beg, size_t end)", "parent": 1275, "children": [1278, 1283, 1284, 1286], "start_point": {"row": 278, "column": 30}, "end_point": {"row": 278, "column": 73}}, {"id": 1278, "type": "binary_expression", "text": "const T *cpu_data", "parent": 1277, "children": [1279, 1281, 1282], "start_point": {"row": 278, "column": 31}, "end_point": {"row": 278, "column": 48}}, {"id": 1279, "type": "ERROR", "text": "T", "parent": 1278, "children": [1280], "start_point": {"row": 278, "column": 37}, "end_point": {"row": 278, "column": 38}}, {"id": 1280, "type": "identifier", "text": "T", "parent": 1279, "children": [], "start_point": {"row": 278, "column": 37}, "end_point": {"row": 278, "column": 38}}, {"id": 1281, "type": "*", "text": "*", "parent": 1278, "children": [], "start_point": {"row": 278, "column": 39}, "end_point": {"row": 278, "column": 40}}, {"id": 1282, "type": "identifier", "text": "cpu_data", "parent": 1278, "children": [], "start_point": {"row": 278, "column": 40}, "end_point": {"row": 278, "column": 48}}, {"id": 1283, "type": "identifier", "text": "size_t", "parent": 1277, "children": [], "start_point": {"row": 278, "column": 50}, "end_point": {"row": 278, "column": 56}}, {"id": 1284, "type": "ERROR", "text": "beg", "parent": 1277, "children": [1285], "start_point": {"row": 278, "column": 57}, "end_point": {"row": 278, "column": 60}}, {"id": 1285, "type": "identifier", "text": "beg", "parent": 1284, "children": [], "start_point": {"row": 278, "column": 57}, "end_point": {"row": 278, "column": 60}}, {"id": 1286, "type": "identifier", "text": "size_t", "parent": 1277, "children": [], "start_point": {"row": 278, "column": 62}, "end_point": {"row": 278, "column": 68}}, {"id": 1287, "type": "if_statement", "text": "if(end <= beg)\n end = elem_count_;", "parent": 826, "children": [1288], "start_point": {"row": 280, "column": 4}, "end_point": {"row": 281, "column": 26}}, {"id": 1288, "type": "parenthesized_expression", "text": "(end <= beg)", "parent": 1287, "children": [1289], "start_point": {"row": 280, "column": 6}, "end_point": {"row": 280, "column": 18}}, {"id": 1289, "type": "binary_expression", "text": "end <= beg", "parent": 1288, "children": [1290, 1291], "start_point": {"row": 280, "column": 7}, "end_point": {"row": 280, "column": 17}}, {"id": 1290, "type": "<=", "text": "<=", "parent": 1289, "children": [], "start_point": {"row": 280, "column": 11}, "end_point": {"row": 280, "column": 13}}, {"id": 1291, "type": "identifier", "text": "beg", "parent": 1289, "children": [], "start_point": {"row": 280, "column": 14}, "end_point": {"row": 280, "column": 17}}, {"id": 1292, "type": "assignment_expression", "text": "end = elem_count_", "parent": 1287, "children": [1293, 1294], "start_point": {"row": 281, "column": 8}, "end_point": {"row": 281, "column": 25}}, {"id": 1293, "type": "=", "text": "=", "parent": 1292, "children": [], "start_point": {"row": 281, "column": 12}, "end_point": {"row": 281, "column": 13}}, {"id": 1294, "type": "identifier", "text": "elem_count_", "parent": 1292, "children": [], "start_point": {"row": 281, "column": 14}, "end_point": {"row": 281, "column": 25}}, {"id": 1295, "type": "call_expression", "text": "assert(beg < end)", "parent": 826, "children": [1296, 1297], "start_point": {"row": 282, "column": 4}, "end_point": {"row": 282, "column": 21}}, {"id": 1296, "type": "identifier", "text": "assert", "parent": 1295, "children": [], "start_point": {"row": 282, "column": 4}, "end_point": {"row": 282, "column": 10}}, {"id": 1297, "type": "argument_list", "text": "(beg < end)", "parent": 1295, "children": [1298], "start_point": {"row": 282, "column": 10}, "end_point": {"row": 282, "column": 21}}, {"id": 1298, "type": "binary_expression", "text": "beg < end", "parent": 1297, "children": [1299, 1300], "start_point": {"row": 282, "column": 11}, "end_point": {"row": 282, "column": 20}}, {"id": 1299, "type": "identifier", "text": "beg", "parent": 1298, "children": [], "start_point": {"row": 282, "column": 11}, "end_point": {"row": 282, "column": 14}}, {"id": 1300, "type": "<", "text": "<", "parent": 1298, "children": [], "start_point": {"row": 282, "column": 15}, "end_point": {"row": 282, "column": 16}}, {"id": 1301, "type": "declaration", "text": "const size_t bytes = sizeof(T) * (end - beg);", "parent": 826, "children": [1302, 1303], "start_point": {"row": 283, "column": 4}, "end_point": {"row": 283, "column": 49}}, {"id": 1302, "type": "primitive_type", "text": "size_t", "parent": 1301, "children": [], "start_point": {"row": 283, "column": 10}, "end_point": {"row": 283, "column": 16}}, {"id": 1303, "type": "init_declarator", "text": "bytes = sizeof(T) * (end - beg)", "parent": 1301, "children": [1304, 1305, 1306], "start_point": {"row": 283, "column": 17}, "end_point": {"row": 283, "column": 48}}, {"id": 1304, "type": "identifier", "text": "bytes", "parent": 1303, "children": [], "start_point": {"row": 283, "column": 17}, "end_point": {"row": 283, "column": 22}}, {"id": 1305, "type": "=", "text": "=", "parent": 1303, "children": [], "start_point": {"row": 283, "column": 23}, "end_point": {"row": 283, "column": 24}}, {"id": 1306, "type": "binary_expression", "text": "sizeof(T) * (end - beg)", "parent": 1303, "children": [1307, 1310, 1311], "start_point": {"row": 283, "column": 25}, "end_point": {"row": 283, "column": 48}}, {"id": 1307, "type": "sizeof_expression", "text": "sizeof(T)", "parent": 1306, "children": [1308], "start_point": {"row": 283, "column": 25}, "end_point": {"row": 283, "column": 34}}, {"id": 1308, "type": "parenthesized_expression", "text": "(T)", "parent": 1307, "children": [1309], "start_point": {"row": 283, "column": 31}, "end_point": {"row": 283, "column": 34}}, {"id": 1309, "type": "identifier", "text": "T", "parent": 1308, "children": [], "start_point": {"row": 283, "column": 32}, "end_point": {"row": 283, "column": 33}}, {"id": 1310, "type": "*", "text": "*", "parent": 1306, "children": [], "start_point": {"row": 283, "column": 35}, "end_point": {"row": 283, "column": 36}}, {"id": 1311, "type": "parenthesized_expression", "text": "(end - beg)", "parent": 1306, "children": [1312], "start_point": {"row": 283, "column": 37}, "end_point": {"row": 283, "column": 48}}, {"id": 1312, "type": "binary_expression", "text": "end - beg", "parent": 1311, "children": [1313, 1314], "start_point": {"row": 283, "column": 38}, "end_point": {"row": 283, "column": 47}}, {"id": 1313, "type": "-", "text": "-", "parent": 1312, "children": [], "start_point": {"row": 283, "column": 42}, "end_point": {"row": 283, "column": 43}}, {"id": 1314, "type": "identifier", "text": "beg", "parent": 1312, "children": [], "start_point": {"row": 283, "column": 44}, "end_point": {"row": 283, "column": 47}}, {"id": 1315, "type": "call_expression", "text": "throw_on_error(cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice))", "parent": 826, "children": [1316, 1317], "start_point": {"row": 284, "column": 4}, "end_point": {"row": 285, "column": 64}}, {"id": 1316, "type": "identifier", "text": "throw_on_error", "parent": 1315, "children": [], "start_point": {"row": 284, "column": 4}, "end_point": {"row": 284, "column": 18}}, {"id": 1317, "type": "argument_list", "text": "(cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice))", "parent": 1315, "children": [1318], "start_point": {"row": 284, "column": 18}, "end_point": {"row": 285, "column": 64}}, {"id": 1318, "type": "call_expression", "text": "cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice)", "parent": 1317, "children": [1319, 1320], "start_point": {"row": 284, "column": 19}, "end_point": {"row": 285, "column": 63}}, {"id": 1319, "type": "identifier", "text": "cudaMemcpyAsync", "parent": 1318, "children": [], "start_point": {"row": 284, "column": 19}, "end_point": {"row": 284, "column": 34}}, {"id": 1320, "type": "argument_list", "text": "(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice)", "parent": 1318, "children": [1321, 1325, 1326, 1327], "start_point": {"row": 284, "column": 34}, "end_point": {"row": 285, "column": 63}}, {"id": 1321, "type": "binary_expression", "text": "buffer_ + beg", "parent": 1320, "children": [1322, 1323, 1324], "start_point": {"row": 285, "column": 8}, "end_point": {"row": 285, "column": 21}}, {"id": 1322, "type": "identifier", "text": "buffer_", "parent": 1321, "children": [], "start_point": {"row": 285, "column": 8}, "end_point": {"row": 285, "column": 15}}, {"id": 1323, "type": "+", "text": "+", "parent": 1321, "children": [], "start_point": {"row": 285, "column": 16}, "end_point": {"row": 285, "column": 17}}, {"id": 1324, "type": "identifier", "text": "beg", "parent": 1321, "children": [], "start_point": {"row": 285, "column": 18}, "end_point": {"row": 285, "column": 21}}, {"id": 1325, "type": "identifier", "text": "cpu_data", "parent": 1320, "children": [], "start_point": {"row": 285, "column": 23}, "end_point": {"row": 285, "column": 31}}, {"id": 1326, "type": "identifier", "text": "bytes", "parent": 1320, "children": [], "start_point": {"row": 285, "column": 33}, "end_point": {"row": 285, "column": 38}}, {"id": 1327, "type": "identifier", "text": "cudaMemcpyHostToDevice", "parent": 1320, "children": [], "start_point": {"row": 285, "column": 40}, "end_point": {"row": 285, "column": 62}}, {"id": 1328, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T>::to_cpu(T *output, size_t beg, size_t end)", "parent": 826, "children": [1329, 1343, 1344], "start_point": {"row": 288, "column": 0}, "end_point": {"row": 289, "column": 57}}, {"id": 1329, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T", "parent": 1328, "children": [1330, 1341, 1342], "start_point": {"row": 288, "column": 0}, "end_point": {"row": 289, "column": 13}}, {"id": 1330, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer", "parent": 1329, "children": [1331, 1335, 1337, 1338, 1340], "start_point": {"row": 288, "column": 0}, "end_point": {"row": 289, "column": 11}}, {"id": 1331, "type": "binary_expression", "text": "template<typename", "parent": 1330, "children": [1332, 1333, 1334], "start_point": {"row": 288, "column": 0}, "end_point": {"row": 288, "column": 17}}, {"id": 1332, "type": "identifier", "text": "template", "parent": 1331, "children": [], "start_point": {"row": 288, "column": 0}, "end_point": {"row": 288, "column": 8}}, {"id": 1333, "type": "<", "text": "<", "parent": 1331, "children": [], "start_point": {"row": 288, "column": 8}, "end_point": {"row": 288, "column": 9}}, {"id": 1334, "type": "identifier", "text": "typename", "parent": 1331, "children": [], "start_point": {"row": 288, "column": 9}, "end_point": {"row": 288, "column": 17}}, {"id": 1335, "type": "ERROR", "text": "T", "parent": 1330, "children": [1336], "start_point": {"row": 288, "column": 18}, "end_point": {"row": 288, "column": 19}}, {"id": 1336, "type": "identifier", "text": "T", "parent": 1335, "children": [], "start_point": {"row": 288, "column": 18}, "end_point": {"row": 288, "column": 19}}, {"id": 1337, "type": ">", "text": ">", "parent": 1330, "children": [], "start_point": {"row": 288, "column": 19}, "end_point": {"row": 288, "column": 20}}, {"id": 1338, "type": "ERROR", "text": "void", "parent": 1330, "children": [1339], "start_point": {"row": 289, "column": 0}, "end_point": {"row": 289, "column": 4}}, {"id": 1339, "type": "identifier", "text": "void", "parent": 1338, "children": [], "start_point": {"row": 289, "column": 0}, "end_point": {"row": 289, "column": 4}}, {"id": 1340, "type": "identifier", "text": "Buffer", "parent": 1330, "children": [], "start_point": {"row": 289, "column": 5}, "end_point": {"row": 289, "column": 11}}, {"id": 1341, "type": "<", "text": "<", "parent": 1329, "children": [], "start_point": {"row": 289, "column": 11}, "end_point": {"row": 289, "column": 12}}, {"id": 1342, "type": "identifier", "text": "T", "parent": 1329, "children": [], "start_point": {"row": 289, "column": 12}, "end_point": {"row": 289, "column": 13}}, {"id": 1343, "type": ">", "text": ">", "parent": 1328, "children": [], "start_point": {"row": 289, "column": 13}, "end_point": {"row": 289, "column": 14}}, {"id": 1344, "type": "call_expression", "text": "to_cpu(T *output, size_t beg, size_t end)", "parent": 1328, "children": [1345, 1346], "start_point": {"row": 289, "column": 16}, "end_point": {"row": 289, "column": 57}}, {"id": 1345, "type": "identifier", "text": "to_cpu", "parent": 1344, "children": [], "start_point": {"row": 289, "column": 16}, "end_point": {"row": 289, "column": 22}}, {"id": 1346, "type": "argument_list", "text": "(T *output, size_t beg, size_t end)", "parent": 1344, "children": [1347, 1351, 1352, 1354], "start_point": {"row": 289, "column": 22}, "end_point": {"row": 289, "column": 57}}, {"id": 1347, "type": "binary_expression", "text": "T *output", "parent": 1346, "children": [1348, 1349, 1350], "start_point": {"row": 289, "column": 23}, "end_point": {"row": 289, "column": 32}}, {"id": 1348, "type": "identifier", "text": "T", "parent": 1347, "children": [], "start_point": {"row": 289, "column": 23}, "end_point": {"row": 289, "column": 24}}, {"id": 1349, "type": "*", "text": "*", "parent": 1347, "children": [], "start_point": {"row": 289, "column": 25}, "end_point": {"row": 289, "column": 26}}, {"id": 1350, "type": "identifier", "text": "output", "parent": 1347, "children": [], "start_point": {"row": 289, "column": 26}, "end_point": {"row": 289, "column": 32}}, {"id": 1351, "type": "identifier", "text": "size_t", "parent": 1346, "children": [], "start_point": {"row": 289, "column": 34}, "end_point": {"row": 289, "column": 40}}, {"id": 1352, "type": "ERROR", "text": "beg", "parent": 1346, "children": [1353], "start_point": {"row": 289, "column": 41}, "end_point": {"row": 289, "column": 44}}, {"id": 1353, "type": "identifier", "text": "beg", "parent": 1352, "children": [], "start_point": {"row": 289, "column": 41}, "end_point": {"row": 289, "column": 44}}, {"id": 1354, "type": "identifier", "text": "size_t", "parent": 1346, "children": [], "start_point": {"row": 289, "column": 46}, "end_point": {"row": 289, "column": 52}}, {"id": 1355, "type": "if_statement", "text": "if(end <= beg)\n end = elem_count_;", "parent": 826, "children": [1356], "start_point": {"row": 291, "column": 4}, "end_point": {"row": 292, "column": 26}}, {"id": 1356, "type": "parenthesized_expression", "text": "(end <= beg)", "parent": 1355, "children": [1357], "start_point": {"row": 291, "column": 6}, "end_point": {"row": 291, "column": 18}}, {"id": 1357, "type": "binary_expression", "text": "end <= beg", "parent": 1356, "children": [1358, 1359], "start_point": {"row": 291, "column": 7}, "end_point": {"row": 291, "column": 17}}, {"id": 1358, "type": "<=", "text": "<=", "parent": 1357, "children": [], "start_point": {"row": 291, "column": 11}, "end_point": {"row": 291, "column": 13}}, {"id": 1359, "type": "identifier", "text": "beg", "parent": 1357, "children": [], "start_point": {"row": 291, "column": 14}, "end_point": {"row": 291, "column": 17}}, {"id": 1360, "type": "assignment_expression", "text": "end = elem_count_", "parent": 1355, "children": [1361, 1362], "start_point": {"row": 292, "column": 8}, "end_point": {"row": 292, "column": 25}}, {"id": 1361, "type": "=", "text": "=", "parent": 1360, "children": [], "start_point": {"row": 292, "column": 12}, "end_point": {"row": 292, "column": 13}}, {"id": 1362, "type": "identifier", "text": "elem_count_", "parent": 1360, "children": [], "start_point": {"row": 292, "column": 14}, "end_point": {"row": 292, "column": 25}}, {"id": 1363, "type": "call_expression", "text": "assert(beg < end)", "parent": 826, "children": [1364, 1365], "start_point": {"row": 293, "column": 4}, "end_point": {"row": 293, "column": 21}}, {"id": 1364, "type": "identifier", "text": "assert", "parent": 1363, "children": [], "start_point": {"row": 293, "column": 4}, "end_point": {"row": 293, "column": 10}}, {"id": 1365, "type": "argument_list", "text": "(beg < end)", "parent": 1363, "children": [1366], "start_point": {"row": 293, "column": 10}, "end_point": {"row": 293, "column": 21}}, {"id": 1366, "type": "binary_expression", "text": "beg < end", "parent": 1365, "children": [1367, 1368], "start_point": {"row": 293, "column": 11}, "end_point": {"row": 293, "column": 20}}, {"id": 1367, "type": "identifier", "text": "beg", "parent": 1366, "children": [], "start_point": {"row": 293, "column": 11}, "end_point": {"row": 293, "column": 14}}, {"id": 1368, "type": "<", "text": "<", "parent": 1366, "children": [], "start_point": {"row": 293, "column": 15}, "end_point": {"row": 293, "column": 16}}, {"id": 1369, "type": "declaration", "text": "const size_t bytes = sizeof(T) * (end - beg);", "parent": 826, "children": [1370, 1371], "start_point": {"row": 294, "column": 4}, "end_point": {"row": 294, "column": 49}}, {"id": 1370, "type": "primitive_type", "text": "size_t", "parent": 1369, "children": [], "start_point": {"row": 294, "column": 10}, "end_point": {"row": 294, "column": 16}}, {"id": 1371, "type": "init_declarator", "text": "bytes = sizeof(T) * (end - beg)", "parent": 1369, "children": [1372, 1373, 1374], "start_point": {"row": 294, "column": 17}, "end_point": {"row": 294, "column": 48}}, {"id": 1372, "type": "identifier", "text": "bytes", "parent": 1371, "children": [], "start_point": {"row": 294, "column": 17}, "end_point": {"row": 294, "column": 22}}, {"id": 1373, "type": "=", "text": "=", "parent": 1371, "children": [], "start_point": {"row": 294, "column": 23}, "end_point": {"row": 294, "column": 24}}, {"id": 1374, "type": "binary_expression", "text": "sizeof(T) * (end - beg)", "parent": 1371, "children": [1375, 1378, 1379], "start_point": {"row": 294, "column": 25}, "end_point": {"row": 294, "column": 48}}, {"id": 1375, "type": "sizeof_expression", "text": "sizeof(T)", "parent": 1374, "children": [1376], "start_point": {"row": 294, "column": 25}, "end_point": {"row": 294, "column": 34}}, {"id": 1376, "type": "parenthesized_expression", "text": "(T)", "parent": 1375, "children": [1377], "start_point": {"row": 294, "column": 31}, "end_point": {"row": 294, "column": 34}}, {"id": 1377, "type": "identifier", "text": "T", "parent": 1376, "children": [], "start_point": {"row": 294, "column": 32}, "end_point": {"row": 294, "column": 33}}, {"id": 1378, "type": "*", "text": "*", "parent": 1374, "children": [], "start_point": {"row": 294, "column": 35}, "end_point": {"row": 294, "column": 36}}, {"id": 1379, "type": "parenthesized_expression", "text": "(end - beg)", "parent": 1374, "children": [1380], "start_point": {"row": 294, "column": 37}, "end_point": {"row": 294, "column": 48}}, {"id": 1380, "type": "binary_expression", "text": "end - beg", "parent": 1379, "children": [1381, 1382], "start_point": {"row": 294, "column": 38}, "end_point": {"row": 294, "column": 47}}, {"id": 1381, "type": "-", "text": "-", "parent": 1380, "children": [], "start_point": {"row": 294, "column": 42}, "end_point": {"row": 294, "column": 43}}, {"id": 1382, "type": "identifier", "text": "beg", "parent": 1380, "children": [], "start_point": {"row": 294, "column": 44}, "end_point": {"row": 294, "column": 47}}, {"id": 1383, "type": "call_expression", "text": "throw_on_error(cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost))", "parent": 826, "children": [1384, 1385], "start_point": {"row": 295, "column": 4}, "end_point": {"row": 296, "column": 62}}, {"id": 1384, "type": "identifier", "text": "throw_on_error", "parent": 1383, "children": [], "start_point": {"row": 295, "column": 4}, "end_point": {"row": 295, "column": 18}}, {"id": 1385, "type": "argument_list", "text": "(cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost))", "parent": 1383, "children": [1386], "start_point": {"row": 295, "column": 18}, "end_point": {"row": 296, "column": 62}}, {"id": 1386, "type": "call_expression", "text": "cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost)", "parent": 1385, "children": [1387, 1388], "start_point": {"row": 295, "column": 19}, "end_point": {"row": 296, "column": 61}}, {"id": 1387, "type": "identifier", "text": "cudaMemcpy", "parent": 1386, "children": [], "start_point": {"row": 295, "column": 19}, "end_point": {"row": 295, "column": 29}}, {"id": 1388, "type": "argument_list", "text": "(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost)", "parent": 1386, "children": [1389, 1390, 1394, 1395], "start_point": {"row": 295, "column": 29}, "end_point": {"row": 296, "column": 61}}, {"id": 1389, "type": "identifier", "text": "output", "parent": 1388, "children": [], "start_point": {"row": 296, "column": 8}, "end_point": {"row": 296, "column": 14}}, {"id": 1390, "type": "binary_expression", "text": "buffer_ + beg", "parent": 1388, "children": [1391, 1392, 1393], "start_point": {"row": 296, "column": 16}, "end_point": {"row": 296, "column": 29}}, {"id": 1391, "type": "identifier", "text": "buffer_", "parent": 1390, "children": [], "start_point": {"row": 296, "column": 16}, "end_point": {"row": 296, "column": 23}}, {"id": 1392, "type": "+", "text": "+", "parent": 1390, "children": [], "start_point": {"row": 296, "column": 24}, "end_point": {"row": 296, "column": 25}}, {"id": 1393, "type": "identifier", "text": "beg", "parent": 1390, "children": [], "start_point": {"row": 296, "column": 26}, "end_point": {"row": 296, "column": 29}}, {"id": 1394, "type": "identifier", "text": "bytes", "parent": 1388, "children": [], "start_point": {"row": 296, "column": 31}, "end_point": {"row": 296, "column": 36}}, {"id": 1395, "type": "identifier", "text": "cudaMemcpyDeviceToHost", "parent": 1388, "children": [], "start_point": {"row": 296, "column": 38}, "end_point": {"row": 296, "column": 60}}, {"id": 1396, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T>::to_cpu_async(T *output, size_t beg, size_t end)", "parent": 826, "children": [1397, 1411, 1412], "start_point": {"row": 299, "column": 0}, "end_point": {"row": 300, "column": 63}}, {"id": 1397, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer<T", "parent": 1396, "children": [1398, 1409, 1410], "start_point": {"row": 299, "column": 0}, "end_point": {"row": 300, "column": 13}}, {"id": 1398, "type": "binary_expression", "text": "template<typename T>\nvoid Buffer", "parent": 1397, "children": [1399, 1403, 1405, 1406, 1408], "start_point": {"row": 299, "column": 0}, "end_point": {"row": 300, "column": 11}}, {"id": 1399, "type": "binary_expression", "text": "template<typename", "parent": 1398, "children": [1400, 1401, 1402], "start_point": {"row": 299, "column": 0}, "end_point": {"row": 299, "column": 17}}, {"id": 1400, "type": "identifier", "text": "template", "parent": 1399, "children": [], "start_point": {"row": 299, "column": 0}, "end_point": {"row": 299, "column": 8}}, {"id": 1401, "type": "<", "text": "<", "parent": 1399, "children": [], "start_point": {"row": 299, "column": 8}, "end_point": {"row": 299, "column": 9}}, {"id": 1402, "type": "identifier", "text": "typename", "parent": 1399, "children": [], "start_point": {"row": 299, "column": 9}, "end_point": {"row": 299, "column": 17}}, {"id": 1403, "type": "ERROR", "text": "T", "parent": 1398, "children": [1404], "start_point": {"row": 299, "column": 18}, "end_point": {"row": 299, "column": 19}}, {"id": 1404, "type": "identifier", "text": "T", "parent": 1403, "children": [], "start_point": {"row": 299, "column": 18}, "end_point": {"row": 299, "column": 19}}, {"id": 1405, "type": ">", "text": ">", "parent": 1398, "children": [], "start_point": {"row": 299, "column": 19}, "end_point": {"row": 299, "column": 20}}, {"id": 1406, "type": "ERROR", "text": "void", "parent": 1398, "children": [1407], "start_point": {"row": 300, "column": 0}, "end_point": {"row": 300, "column": 4}}, {"id": 1407, "type": "identifier", "text": "void", "parent": 1406, "children": [], "start_point": {"row": 300, "column": 0}, "end_point": {"row": 300, "column": 4}}, {"id": 1408, "type": "identifier", "text": "Buffer", "parent": 1398, "children": [], "start_point": {"row": 300, "column": 5}, "end_point": {"row": 300, "column": 11}}, {"id": 1409, "type": "<", "text": "<", "parent": 1397, "children": [], "start_point": {"row": 300, "column": 11}, "end_point": {"row": 300, "column": 12}}, {"id": 1410, "type": "identifier", "text": "T", "parent": 1397, "children": [], "start_point": {"row": 300, "column": 12}, "end_point": {"row": 300, "column": 13}}, {"id": 1411, "type": ">", "text": ">", "parent": 1396, "children": [], "start_point": {"row": 300, "column": 13}, "end_point": {"row": 300, "column": 14}}, {"id": 1412, "type": "call_expression", "text": "to_cpu_async(T *output, size_t beg, size_t end)", "parent": 1396, "children": [1413, 1414], "start_point": {"row": 300, "column": 16}, "end_point": {"row": 300, "column": 63}}, {"id": 1413, "type": "identifier", "text": "to_cpu_async", "parent": 1412, "children": [], "start_point": {"row": 300, "column": 16}, "end_point": {"row": 300, "column": 28}}, {"id": 1414, "type": "argument_list", "text": "(T *output, size_t beg, size_t end)", "parent": 1412, "children": [1415, 1419, 1420, 1422], "start_point": {"row": 300, "column": 28}, "end_point": {"row": 300, "column": 63}}, {"id": 1415, "type": "binary_expression", "text": "T *output", "parent": 1414, "children": [1416, 1417, 1418], "start_point": {"row": 300, "column": 29}, "end_point": {"row": 300, "column": 38}}, {"id": 1416, "type": "identifier", "text": "T", "parent": 1415, "children": [], "start_point": {"row": 300, "column": 29}, "end_point": {"row": 300, "column": 30}}, {"id": 1417, "type": "*", "text": "*", "parent": 1415, "children": [], "start_point": {"row": 300, "column": 31}, "end_point": {"row": 300, "column": 32}}, {"id": 1418, "type": "identifier", "text": "output", "parent": 1415, "children": [], "start_point": {"row": 300, "column": 32}, "end_point": {"row": 300, "column": 38}}, {"id": 1419, "type": "identifier", "text": "size_t", "parent": 1414, "children": [], "start_point": {"row": 300, "column": 40}, "end_point": {"row": 300, "column": 46}}, {"id": 1420, "type": "ERROR", "text": "beg", "parent": 1414, "children": [1421], "start_point": {"row": 300, "column": 47}, "end_point": {"row": 300, "column": 50}}, {"id": 1421, "type": "identifier", "text": "beg", "parent": 1420, "children": [], "start_point": {"row": 300, "column": 47}, "end_point": {"row": 300, "column": 50}}, {"id": 1422, "type": "identifier", "text": "size_t", "parent": 1414, "children": [], "start_point": {"row": 300, "column": 52}, "end_point": {"row": 300, "column": 58}}, {"id": 1423, "type": "if_statement", "text": "if(end <= beg)\n end = elem_count_;", "parent": 826, "children": [1424], "start_point": {"row": 302, "column": 4}, "end_point": {"row": 303, "column": 26}}, {"id": 1424, "type": "parenthesized_expression", "text": "(end <= beg)", "parent": 1423, "children": [1425], "start_point": {"row": 302, "column": 6}, "end_point": {"row": 302, "column": 18}}, {"id": 1425, "type": "binary_expression", "text": "end <= beg", "parent": 1424, "children": [1426, 1427], "start_point": {"row": 302, "column": 7}, "end_point": {"row": 302, "column": 17}}, {"id": 1426, "type": "<=", "text": "<=", "parent": 1425, "children": [], "start_point": {"row": 302, "column": 11}, "end_point": {"row": 302, "column": 13}}, {"id": 1427, "type": "identifier", "text": "beg", "parent": 1425, "children": [], "start_point": {"row": 302, "column": 14}, "end_point": {"row": 302, "column": 17}}, {"id": 1428, "type": "assignment_expression", "text": "end = elem_count_", "parent": 1423, "children": [1429, 1430], "start_point": {"row": 303, "column": 8}, "end_point": {"row": 303, "column": 25}}, {"id": 1429, "type": "=", "text": "=", "parent": 1428, "children": [], "start_point": {"row": 303, "column": 12}, "end_point": {"row": 303, "column": 13}}, {"id": 1430, "type": "identifier", "text": "elem_count_", "parent": 1428, "children": [], "start_point": {"row": 303, "column": 14}, "end_point": {"row": 303, "column": 25}}, {"id": 1431, "type": "call_expression", "text": "assert(beg < end)", "parent": 826, "children": [1432, 1433], "start_point": {"row": 304, "column": 4}, "end_point": {"row": 304, "column": 21}}, {"id": 1432, "type": "identifier", "text": "assert", "parent": 1431, "children": [], "start_point": {"row": 304, "column": 4}, "end_point": {"row": 304, "column": 10}}, {"id": 1433, "type": "argument_list", "text": "(beg < end)", "parent": 1431, "children": [1434], "start_point": {"row": 304, "column": 10}, "end_point": {"row": 304, "column": 21}}, {"id": 1434, "type": "binary_expression", "text": "beg < end", "parent": 1433, "children": [1435, 1436], "start_point": {"row": 304, "column": 11}, "end_point": {"row": 304, "column": 20}}, {"id": 1435, "type": "identifier", "text": "beg", "parent": 1434, "children": [], "start_point": {"row": 304, "column": 11}, "end_point": {"row": 304, "column": 14}}, {"id": 1436, "type": "<", "text": "<", "parent": 1434, "children": [], "start_point": {"row": 304, "column": 15}, "end_point": {"row": 304, "column": 16}}, {"id": 1437, "type": "declaration", "text": "const size_t bytes = sizeof(T) * (end - beg);", "parent": 826, "children": [1438, 1439], "start_point": {"row": 305, "column": 4}, "end_point": {"row": 305, "column": 49}}, {"id": 1438, "type": "primitive_type", "text": "size_t", "parent": 1437, "children": [], "start_point": {"row": 305, "column": 10}, "end_point": {"row": 305, "column": 16}}, {"id": 1439, "type": "init_declarator", "text": "bytes = sizeof(T) * (end - beg)", "parent": 1437, "children": [1440, 1441, 1442], "start_point": {"row": 305, "column": 17}, "end_point": {"row": 305, "column": 48}}, {"id": 1440, "type": "identifier", "text": "bytes", "parent": 1439, "children": [], "start_point": {"row": 305, "column": 17}, "end_point": {"row": 305, "column": 22}}, {"id": 1441, "type": "=", "text": "=", "parent": 1439, "children": [], "start_point": {"row": 305, "column": 23}, "end_point": {"row": 305, "column": 24}}, {"id": 1442, "type": "binary_expression", "text": "sizeof(T) * (end - beg)", "parent": 1439, "children": [1443, 1446, 1447], "start_point": {"row": 305, "column": 25}, "end_point": {"row": 305, "column": 48}}, {"id": 1443, "type": "sizeof_expression", "text": "sizeof(T)", "parent": 1442, "children": [1444], "start_point": {"row": 305, "column": 25}, "end_point": {"row": 305, "column": 34}}, {"id": 1444, "type": "parenthesized_expression", "text": "(T)", "parent": 1443, "children": [1445], "start_point": {"row": 305, "column": 31}, "end_point": {"row": 305, "column": 34}}, {"id": 1445, "type": "identifier", "text": "T", "parent": 1444, "children": [], "start_point": {"row": 305, "column": 32}, "end_point": {"row": 305, "column": 33}}, {"id": 1446, "type": "*", "text": "*", "parent": 1442, "children": [], "start_point": {"row": 305, "column": 35}, "end_point": {"row": 305, "column": 36}}, {"id": 1447, "type": "parenthesized_expression", "text": "(end - beg)", "parent": 1442, "children": [1448], "start_point": {"row": 305, "column": 37}, "end_point": {"row": 305, "column": 48}}, {"id": 1448, "type": "binary_expression", "text": "end - beg", "parent": 1447, "children": [1449, 1450], "start_point": {"row": 305, "column": 38}, "end_point": {"row": 305, "column": 47}}, {"id": 1449, "type": "-", "text": "-", "parent": 1448, "children": [], "start_point": {"row": 305, "column": 42}, "end_point": {"row": 305, "column": 43}}, {"id": 1450, "type": "identifier", "text": "beg", "parent": 1448, "children": [], "start_point": {"row": 305, "column": 44}, "end_point": {"row": 305, "column": 47}}, {"id": 1451, "type": "call_expression", "text": "throw_on_error(cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost))", "parent": 826, "children": [1452, 1453], "start_point": {"row": 306, "column": 4}, "end_point": {"row": 307, "column": 62}}, {"id": 1452, "type": "identifier", "text": "throw_on_error", "parent": 1451, "children": [], "start_point": {"row": 306, "column": 4}, "end_point": {"row": 306, "column": 18}}, {"id": 1453, "type": "argument_list", "text": "(cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost))", "parent": 1451, "children": [1454], "start_point": {"row": 306, "column": 18}, "end_point": {"row": 307, "column": 62}}, {"id": 1454, "type": "call_expression", "text": "cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost)", "parent": 1453, "children": [1455, 1456], "start_point": {"row": 306, "column": 19}, "end_point": {"row": 307, "column": 61}}, {"id": 1455, "type": "identifier", "text": "cudaMemcpyAsync", "parent": 1454, "children": [], "start_point": {"row": 306, "column": 19}, "end_point": {"row": 306, "column": 34}}, {"id": 1456, "type": "argument_list", "text": "(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost)", "parent": 1454, "children": [1457, 1458, 1462, 1463], "start_point": {"row": 306, "column": 34}, "end_point": {"row": 307, "column": 61}}, {"id": 1457, "type": "identifier", "text": "output", "parent": 1456, "children": [], "start_point": {"row": 307, "column": 8}, "end_point": {"row": 307, "column": 14}}, {"id": 1458, "type": "binary_expression", "text": "buffer_ + beg", "parent": 1456, "children": [1459, 1460, 1461], "start_point": {"row": 307, "column": 16}, "end_point": {"row": 307, "column": 29}}, {"id": 1459, "type": "identifier", "text": "buffer_", "parent": 1458, "children": [], "start_point": {"row": 307, "column": 16}, "end_point": {"row": 307, "column": 23}}, {"id": 1460, "type": "+", "text": "+", "parent": 1458, "children": [], "start_point": {"row": 307, "column": 24}, "end_point": {"row": 307, "column": 25}}, {"id": 1461, "type": "identifier", "text": "beg", "parent": 1458, "children": [], "start_point": {"row": 307, "column": 26}, "end_point": {"row": 307, "column": 29}}, {"id": 1462, "type": "identifier", "text": "bytes", "parent": 1456, "children": [], "start_point": {"row": 307, "column": 31}, "end_point": {"row": 307, "column": 36}}, {"id": 1463, "type": "identifier", "text": "cudaMemcpyDeviceToHost", "parent": 1456, "children": [], "start_point": {"row": 307, "column": 38}, "end_point": {"row": 307, "column": 60}}, {"id": 1464, "type": "binary_expression", "text": "template<typename T>\nauto Buffer<T>::get_cuj_ptr()", "parent": 826, "children": [1465, 1479, 1480], "start_point": {"row": 310, "column": 0}, "end_point": {"row": 311, "column": 29}}, {"id": 1465, "type": "binary_expression", "text": "template<typename T>\nauto Buffer<T", "parent": 1464, "children": [1466, 1477, 1478], "start_point": {"row": 310, "column": 0}, "end_point": {"row": 311, "column": 13}}, {"id": 1466, "type": "binary_expression", "text": "template<typename T>\nauto Buffer", "parent": 1465, "children": [1467, 1471, 1473, 1474, 1476], "start_point": {"row": 310, "column": 0}, "end_point": {"row": 311, "column": 11}}, {"id": 1467, "type": "binary_expression", "text": "template<typename", "parent": 1466, "children": [1468, 1469, 1470], "start_point": {"row": 310, "column": 0}, "end_point": {"row": 310, "column": 17}}, {"id": 1468, "type": "identifier", "text": "template", "parent": 1467, "children": [], "start_point": {"row": 310, "column": 0}, "end_point": {"row": 310, "column": 8}}, {"id": 1469, "type": "<", "text": "<", "parent": 1467, "children": [], "start_point": {"row": 310, "column": 8}, "end_point": {"row": 310, "column": 9}}, {"id": 1470, "type": "identifier", "text": "typename", "parent": 1467, "children": [], "start_point": {"row": 310, "column": 9}, "end_point": {"row": 310, "column": 17}}, {"id": 1471, "type": "ERROR", "text": "T", "parent": 1466, "children": [1472], "start_point": {"row": 310, "column": 18}, "end_point": {"row": 310, "column": 19}}, {"id": 1472, "type": "identifier", "text": "T", "parent": 1471, "children": [], "start_point": {"row": 310, "column": 18}, "end_point": {"row": 310, "column": 19}}, {"id": 1473, "type": ">", "text": ">", "parent": 1466, "children": [], "start_point": {"row": 310, "column": 19}, "end_point": {"row": 310, "column": 20}}, {"id": 1474, "type": "ERROR", "text": "auto", "parent": 1466, "children": [1475], "start_point": {"row": 311, "column": 0}, "end_point": {"row": 311, "column": 4}}, {"id": 1475, "type": "identifier", "text": "auto", "parent": 1474, "children": [], "start_point": {"row": 311, "column": 0}, "end_point": {"row": 311, "column": 4}}, {"id": 1476, "type": "identifier", "text": "Buffer", "parent": 1466, "children": [], "start_point": {"row": 311, "column": 5}, "end_point": {"row": 311, "column": 11}}, {"id": 1477, "type": "<", "text": "<", "parent": 1465, "children": [], "start_point": {"row": 311, "column": 11}, "end_point": {"row": 311, "column": 12}}, {"id": 1478, "type": "identifier", "text": "T", "parent": 1465, "children": [], "start_point": {"row": 311, "column": 12}, "end_point": {"row": 311, "column": 13}}, {"id": 1479, "type": ">", "text": ">", "parent": 1464, "children": [], "start_point": {"row": 311, "column": 13}, "end_point": {"row": 311, "column": 14}}, {"id": 1480, "type": "call_expression", "text": "get_cuj_ptr()", "parent": 1464, "children": [1481, 1482], "start_point": {"row": 311, "column": 16}, "end_point": {"row": 311, "column": 29}}, {"id": 1481, "type": "identifier", "text": "get_cuj_ptr", "parent": 1480, "children": [], "start_point": {"row": 311, "column": 16}, "end_point": {"row": 311, "column": 27}}, {"id": 1482, "type": "argument_list", "text": "()", "parent": 1480, "children": [], "start_point": {"row": 311, "column": 27}, "end_point": {"row": 311, "column": 29}}, {"id": 1483, "type": "return_statement", "text": "return cuj::import_pointer(buffer_);", "parent": 788, "children": [1484, 1486], "start_point": {"row": 313, "column": 4}, "end_point": {"row": 313, "column": 40}}, {"id": 1484, "type": "ERROR", "text": "cuj::", "parent": 1483, "children": [1485], "start_point": {"row": 313, "column": 11}, "end_point": {"row": 313, "column": 16}}, {"id": 1485, "type": "identifier", "text": "cuj", "parent": 1484, "children": [], "start_point": {"row": 313, "column": 11}, "end_point": {"row": 313, "column": 14}}, {"id": 1486, "type": "call_expression", "text": "import_pointer(buffer_)", "parent": 1483, "children": [1487, 1488], "start_point": {"row": 313, "column": 16}, "end_point": {"row": 313, "column": 39}}, {"id": 1487, "type": "identifier", "text": "import_pointer", "parent": 1486, "children": [], "start_point": {"row": 313, "column": 16}, "end_point": {"row": 313, "column": 30}}, {"id": 1488, "type": "argument_list", "text": "(buffer_)", "parent": 1486, "children": [1489], "start_point": {"row": 313, "column": 30}, "end_point": {"row": 313, "column": 39}}, {"id": 1489, "type": "identifier", "text": "buffer_", "parent": 1488, "children": [], "start_point": {"row": 313, "column": 31}, "end_point": {"row": 313, "column": 38}}, {"id": 1490, "type": "identifier", "text": "BTRC_CUDA_END", "parent": 788, "children": [], "start_point": {"row": 316, "column": 0}, "end_point": {"row": 316, "column": 13}}]}, "node_categories": {"declarations": {"functions": [53, 69, 109, 125, 130, 137, 139, 145, 149, 153, 172, 179, 186, 191, 204, 216, 220, 228, 236, 244, 253, 274, 295, 315, 359, 366], "variables": [30, 50, 56, 59, 67, 72, 106, 112, 115, 123, 133, 142, 162, 170, 175, 182, 189, 194, 206, 218, 223, 226, 231, 234, 239, 242, 247, 250, 256, 261, 271, 277, 282, 292, 298, 303, 312, 318, 323, 332, 342, 369, 1232, 1301, 1369, 1437], "classes": [333], "imports": [3, 4, 6, 7, 9, 10, 12, 13, 15, 16, 18, 19, 21, 22, 24, 25, 27, 28], "modules": [], "enums": []}, "statements": {"expressions": [39, 47, 80, 83, 89, 94, 95, 101, 103, 362, 372, 373, 374, 375, 386, 392, 397, 401, 403, 409, 410, 411, 412, 423, 428, 429, 436, 439, 440, 444, 445, 450, 451, 452, 453, 454, 455, 456, 457, 458, 459, 471, 474, 479, 482, 497, 505, 506, 511, 516, 520, 521, 522, 523, 534, 536, 539, 543, 544, 545, 546, 547, 561, 567, 572, 576, 584, 587, 590, 592, 593, 594, 599, 602, 606, 607, 613, 614, 615, 616, 629, 632, 646, 647, 648, 649, 662, 665, 671, 675, 680, 684, 688, 689, 690, 691, 704, 708, 714, 715, 716, 717, 730, 734, 740, 741, 742, 743, 756, 762, 763, 764, 765, 778, 782, 785, 786, 789, 790, 791, 809, 810, 811, 829, 830, 831, 832, 845, 849, 852, 853, 854, 855, 862, 869, 874, 875, 876, 877, 884, 892, 897, 898, 899, 900, 913, 917, 918, 923, 925, 926, 927, 928, 929, 930, 943, 950, 953, 954, 961, 963, 964, 965, 966, 967, 968, 981, 989, 992, 993, 1000, 1002, 1003, 1004, 1005, 1018, 1021, 1025, 1028, 1030, 1035, 1036, 1041, 1046, 1047, 1051, 1052, 1056, 1057, 1058, 1059, 1072, 1075, 1079, 1082, 1084, 1089, 1090, 1095, 1100, 1103, 1104, 1108, 1109, 1110, 1111, 1124, 1130, 1133, 1135, 1138, 1141, 1146, 1149, 1150, 1151, 1152, 1165, 1171, 1174, 1176, 1179, 1182, 1187, 1190, 1191, 1192, 1193, 1206, 1209, 1219, 1220, 1226, 1229, 1237, 1238, 1239, 1242, 1243, 1246, 1249, 1252, 1259, 1260, 1261, 1262, 1275, 1278, 1288, 1289, 1295, 1298, 1306, 1307, 1308, 1311, 1312, 1315, 1318, 1321, 1328, 1329, 1330, 1331, 1344, 1347, 1356, 1357, 1363, 1366, 1374, 1375, 1376, 1379, 1380, 1383, 1386, 1390, 1396, 1397, 1398, 1399, 1412, 1415, 1424, 1425, 1431, 1434, 1442, 1443, 1444, 1447, 1448, 1451, 1454, 1458, 1464, 1465, 1466, 1467, 1480, 1486], "assignments": [91, 502, 580, 636, 640, 1223, 1292, 1360, 1428], "loops": [], "conditionals": [31, 33, 36, 37, 40, 43, 45, 48, 51, 54, 58, 60, 63, 68, 70, 73, 75, 77, 79, 81, 84, 86, 88, 90, 92, 96, 98, 100, 104, 110, 114, 116, 119, 126, 131, 134, 135, 136, 138, 140, 146, 150, 154, 156, 157, 161, 163, 165, 169, 171, 173, 176, 180, 183, 187, 190, 192, 195, 198, 199, 201, 207, 210, 211, 213, 221, 224, 225, 229, 232, 233, 237, 241, 245, 249, 254, 257, 260, 263, 267, 275, 278, 281, 284, 288, 296, 299, 302, 305, 309, 316, 319, 322, 325, 329, 335, 336, 341, 343, 346, 349, 352, 353, 355, 357, 360, 363, 367, 370, 376, 378, 380, 382, 384, 387, 390, 391, 394, 396, 398, 400, 402, 404, 406, 407, 413, 415, 417, 419, 421, 424, 427, 430, 433, 435, 437, 441, 442, 446, 447, 460, 462, 464, 466, 468, 472, 475, 477, 478, 480, 483, 485, 487, 489, 491, 493, 495, 498, 500, 503, 507, 509, 510, 512, 514, 518, 524, 526, 528, 530, 532, 537, 540, 542, 548, 550, 552, 555, 556, 558, 562, 565, 566, 569, 571, 573, 577, 579, 581, 583, 585, 588, 591, 595, 597, 598, 600, 601, 603, 605, 608, 609, 611, 617, 619, 621, 624, 625, 627, 630, 633, 635, 637, 641, 650, 652, 654, 657, 658, 660, 663, 666, 667, 668, 670, 672, 674, 676, 677, 679, 681, 683, 685, 686, 692, 694, 696, 698, 700, 703, 705, 709, 718, 720, 722, 725, 726, 728, 731, 735, 744, 746, 748, 750, 752, 754, 757, 760, 766, 768, 770, 772, 774, 776, 779, 783, 787, 792, 794, 796, 798, 800, 803, 804, 808, 812, 814, 816, 818, 820, 823, 824, 828, 833, 835, 837, 839, 841, 844, 846, 850, 856, 858, 860, 863, 865, 867, 870, 873, 878, 880, 882, 886, 888, 890, 893, 896, 901, 903, 905, 907, 909, 911, 914, 919, 921, 924, 931, 933, 935, 937, 939, 941, 944, 946, 948, 955, 957, 962, 969, 971, 973, 975, 977, 979, 983, 985, 987, 994, 997, 1001, 1006, 1008, 1010, 1013, 1014, 1016, 1019, 1023, 1024, 1026, 1031, 1034, 1037, 1039, 1042, 1044, 1045, 1048, 1049, 1053, 1054, 1060, 1062, 1064, 1067, 1068, 1070, 1073, 1077, 1078, 1080, 1085, 1088, 1091, 1093, 1096, 1098, 1099, 1101, 1105, 1106, 1112, 1114, 1116, 1119, 1120, 1122, 1125, 1127, 1129, 1131, 1136, 1139, 1142, 1144, 1145, 1147, 1153, 1155, 1157, 1160, 1161, 1163, 1166, 1168, 1170, 1172, 1177, 1180, 1183, 1185, 1186, 1188, 1194, 1196, 1198, 1201, 1202, 1204, 1207, 1211, 1213, 1214, 1216, 1217, 1218, 1222, 1225, 1227, 1230, 1235, 1240, 1245, 1247, 1250, 1253, 1255, 1256, 1257, 1258, 1263, 1265, 1267, 1270, 1271, 1273, 1276, 1280, 1282, 1283, 1285, 1286, 1287, 1291, 1294, 1296, 1299, 1304, 1309, 1314, 1316, 1319, 1322, 1324, 1325, 1326, 1327, 1332, 1334, 1336, 1339, 1340, 1342, 1345, 1348, 1350, 1351, 1353, 1354, 1355, 1359, 1362, 1364, 1367, 1372, 1377, 1382, 1384, 1387, 1389, 1391, 1393, 1394, 1395, 1400, 1402, 1404, 1407, 1408, 1410, 1413, 1416, 1418, 1419, 1421, 1422, 1423, 1427, 1430, 1432, 1435, 1440, 1445, 1450, 1452, 1455, 1457, 1459, 1461, 1462, 1463, 1468, 1470, 1472, 1475, 1476, 1478, 1481, 1485, 1487, 1489, 1490], "returns": [515, 707, 733, 759, 781, 807, 827, 848, 872, 895, 916, 952, 991, 1483], "exceptions": []}, "expressions": {"calls": [0], "literals": [5, 8, 11, 14, 17, 20, 23, 26, 29, 265, 269, 286, 290, 307, 311, 327, 331, 365, 639], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 53, "universal_type": "function", "name": "unknown", "text_snippet": "Buffer(size_t elem_count, const T *cpu_data"}, {"node_id": 69, "universal_type": "function", "name": "unknown", "text_snippet": "Buffer(std::span<const T> data)"}, {"node_id": 109, "universal_type": "function", "name": "unknown", "text_snippet": "initialize(size_t elem_count, const T *cpu_data"}, {"node_id": 125, "universal_type": "function", "name": "unknown", "text_snippet": "destroy()"}, {"node_id": 130, "universal_type": "function", "name": "unknown", "text_snippet": "swap(Buffer &other) noexcept"}, {"node_id": 137, "universal_type": "function", "name": "is_empty", "text_snippet": "operator bool() const;\n\n bool is_empty() const;\n\n size_t get_size() const;\n\n size_t get_siz"}, {"node_id": 139, "universal_type": "function", "name": "unknown", "text_snippet": "bool()"}, {"node_id": 145, "universal_type": "function", "name": "unknown", "text_snippet": "is_empty() const"}, {"node_id": 149, "universal_type": "function", "name": "unknown", "text_snippet": "get_size() const"}, {"node_id": 153, "universal_type": "function", "name": "unknown", "text_snippet": "get_size_in_bytes() const"}, {"node_id": 172, "universal_type": "function", "name": "unknown", "text_snippet": "CUdeviceptr()"}, {"node_id": 179, "universal_type": "function", "name": "unknown", "text_snippet": "get()"}, {"node_id": 186, "universal_type": "function", "name": "unknown", "text_snippet": "get() const"}, {"node_id": 191, "universal_type": "function", "name": "unknown", "text_snippet": "get_device_ptr()"}, {"node_id": 204, "universal_type": "function", "name": "unknown", "text_snippet": "as()"}, {"node_id": 216, "universal_type": "function", "name": "unknown", "text_snippet": "as() const"}, {"node_id": 220, "universal_type": "function", "name": "unknown", "text_snippet": "clear(const T &val)"}, {"node_id": 228, "universal_type": "function", "name": "unknown", "text_snippet": "clear_async(const T &val)"}, {"node_id": 236, "universal_type": "function", "name": "unknown", "text_snippet": "clear_bytes(uint8_t byte)"}, {"node_id": 244, "universal_type": "function", "name": "unknown", "text_snippet": "clear_bytes_async(uint8_t byte)"}, {"node_id": 253, "universal_type": "function", "name": "unknown", "text_snippet": "to_cpu(T *output, size_t beg"}, {"node_id": 274, "universal_type": "function", "name": "unknown", "text_snippet": "to_cpu_async(T *output, size_t beg"}, {"node_id": 295, "universal_type": "function", "name": "unknown", "text_snippet": "from_cpu(const T *cpu_data, size_t beg"}, {"node_id": 315, "universal_type": "function", "name": "unknown", "text_snippet": "from_cpu_async(const T *cpu_data, size_t beg"}, {"node_id": 359, "universal_type": "function", "name": "unknown", "text_snippet": "Buffer()\n : elem_count_(0)"}, {"node_id": 366, "universal_type": "function", "name": "unknown", "text_snippet": "buffer_(nullptr)"}], "class_declarations": [{"node_id": 333, "universal_type": "class", "name": "unknown", "text_snippet": "auto"}], "import_statements": [{"node_id": 3, "text": "#include <cassert>\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include <span>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <vector>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include <cuda.h>\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include <cuda_runtime.h>\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include <cuj.h>\n"}, {"node_id": 19, "text": "#include"}, {"node_id": 21, "text": "#include <btrc/utils/cuda/error.h>\n"}, {"node_id": 22, "text": "#include"}, {"node_id": 24, "text": "#include <btrc/utils/scope_guard.h>\n"}, {"node_id": 25, "text": "#include"}, {"node_id": 27, "text": "#include <btrc/utils/uncopyable.h>\n"}, {"node_id": 28, "text": "#include"}]}, "original_source_code": "#pragma once\n\n#include <cassert>\n#include <span>\n#include <vector>\n\n#include <cuda.h>\n#include <cuda_runtime.h>\n#include <cuj.h>\n\n#include <btrc/utils/cuda/error.h>\n#include <btrc/utils/scope_guard.h>\n#include <btrc/utils/uncopyable.h>\n\nBTRC_CUDA_BEGIN\n\ntemplate<typename T = char>\nclass Buffer : public Uncopyable\n{\npublic:\n\n Buffer();\n\n explicit Buffer(size_t elem_count, const T *cpu_data = nullptr);\n\n explicit Buffer(std::span<const T> data);\n\n Buffer(Buffer &&other) noexcept;\n\n Buffer &operator=(Buffer &&other) noexcept;\n\n ~Buffer();\n\n void initialize(size_t elem_count, const T *cpu_data = nullptr);\n\n void destroy();\n\n void swap(Buffer &other) noexcept;\n\n operator bool() const;\n\n bool is_empty() const;\n\n size_t get_size() const;\n\n size_t get_size_in_bytes() const;\n\n operator T *();\n\n operator const T *() const;\n\n operator CUdeviceptr();\n\n T *get();\n\n const T *get() const;\n\n CUdeviceptr get_device_ptr();\n\n template<typename U>\n U *as();\n\n template<typename U>\n const U *as() const;\n\n void clear(const T &val);\n\n void clear_async(const T &val);\n\n void clear_bytes(uint8_t byte);\n\n void clear_bytes_async(uint8_t byte);\n\n void to_cpu(T *output, size_t beg = 0, size_t end = 0) const;\n\n void to_cpu_async(T *output, size_t beg = 0, size_t end = 0) const;\n\n void from_cpu(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n void from_cpu_async(const T *cpu_data, size_t beg = 0, size_t end = 0);\n\n auto get_cuj_ptr() const;\n\nprivate:\n\n size_t elem_count_;\n T *buffer_;\n};\n\n// ========================== impl ==========================\n\ntemplate<typename T>\nBuffer<T>::Buffer()\n : elem_count_(0), buffer_(nullptr)\n{\n \n}\n\ntemplate<typename T>\nBuffer<T>::Buffer(size_t elem_count, const T *cpu_data)\n : Buffer()\n{\n if(elem_count)\n initialize(elem_count, cpu_data);\n}\n\ntemplate<typename T>\nBuffer<T>::Buffer(std::span<const T> data)\n : Buffer(data.size(), data.data())\n{\n \n}\n\ntemplate<typename T>\nBuffer<T>::Buffer(Buffer &&other) noexcept\n : Buffer()\n{\n swap(other);\n}\n\ntemplate<typename T>\nBuffer<T> &Buffer<T>::operator=(Buffer &&other) noexcept\n{\n swap(other);\n return *this;\n}\n\ntemplate<typename T>\nBuffer<T>::~Buffer()\n{\n cudaFree(buffer_);\n}\n\ntemplate<typename T>\nvoid Buffer<T>::initialize(size_t elem_count, const T *cpu_data)\n{\n destroy();\n assert(elem_count);\n elem_count_ = elem_count;\n throw_on_error(cudaMalloc(&buffer_, sizeof(T) * elem_count));\n if(cpu_data)\n {\n BTRC_SCOPE_FAIL{ cudaFree(buffer_); };\n this->from_cpu(cpu_data);\n }\n}\n\ntemplate<typename T>\nvoid Buffer<T>::destroy()\n{\n cudaFree(buffer_);\n elem_count_ = 0;\n buffer_ = nullptr;\n}\n\ntemplate<typename T>\nvoid Buffer<T>::swap(Buffer &other) noexcept\n{\n std::swap(elem_count_, other.elem_count_);\n std::swap(buffer_, other.buffer_);\n}\n\ntemplate<typename T>\nBuffer<T>::operator bool() const\n{\n return buffer_ != nullptr;\n}\n\ntemplate<typename T>\nbool Buffer<T>::is_empty() const\n{\n return buffer_ == nullptr;\n}\n\ntemplate<typename T>\nsize_t Buffer<T>::get_size() const\n{\n return elem_count_;\n}\n\ntemplate<typename T>\nsize_t Buffer<T>::get_size_in_bytes() const\n{\n return elem_count_ * sizeof(T);\n}\n\ntemplate<typename T>\nBuffer<T>::operator T*()\n{\n return buffer_;\n}\n\ntemplate<typename T>\nBuffer<T>::operator const T*() const\n{\n return buffer_;\n}\n\ntemplate<typename T>\nBuffer<T>::operator CUdeviceptr()\n{\n return get_device_ptr();\n}\n\ntemplate<typename T>\nT *Buffer<T>::get()\n{\n return buffer_;\n}\n\ntemplate<typename T>\nconst T *Buffer<T>::get() const\n{\n return buffer_;\n}\n\ntemplate<typename T>\nCUdeviceptr Buffer<T>::get_device_ptr()\n{\n return reinterpret_cast<CUdeviceptr>(buffer_);\n}\n\ntemplate<typename T>\ntemplate<typename U>\nU *Buffer<T>::as()\n{\n return reinterpret_cast<U *>(buffer_);\n}\n\ntemplate<typename T>\ntemplate<typename U>\nconst U *Buffer<T>::as() const\n{\n return reinterpret_cast<const U *>(buffer_);\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear(const T &val)\n{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n this->from_cpu(vals.data());\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_async(const T &val)\n{\n assert(!is_empty());\n std::vector<T> vals(elem_count_, val);\n from_cpu_async(vals.data());\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_bytes(uint8_t byte)\n{\n assert(!is_empty());\n throw_on_error(cudaMemset(buffer_, byte, get_size_in_bytes()));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::clear_bytes_async(uint8_t byte)\n{\n assert(!is_empty());\n throw_on_error(cudaMemsetAsync(buffer_, byte, get_size_in_bytes()));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::from_cpu(const T *cpu_data, size_t beg, size_t end)\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::from_cpu_async(const T *cpu_data, size_t beg, size_t end)\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n buffer_ + beg, cpu_data, bytes, cudaMemcpyHostToDevice));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::to_cpu(T *output, size_t beg, size_t end) const\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpy(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}\n\ntemplate<typename T>\nvoid Buffer<T>::to_cpu_async(T *output, size_t beg, size_t end) const\n{\n if(end <= beg)\n end = elem_count_;\n assert(beg < end);\n const size_t bytes = sizeof(T) * (end - beg);\n throw_on_error(cudaMemcpyAsync(\n output, buffer_ + beg, bytes, cudaMemcpyDeviceToHost));\n}\n\ntemplate<typename T>\nauto Buffer<T>::get_cuj_ptr() const\n{\n return cuj::import_pointer(buffer_);\n}\n\nBTRC_CUDA_END\n"}
80,547
c
#ifndef _INC_GDT #define _INC_GDT 1 #endif /* _INC_GDT */
18.33
3
(translation_unit) "#ifndef _INC_GDT\n#define _INC_GDT 1\n\n#endif /* _INC_GDT */\n" (preproc_ifdef) "#ifndef _INC_GDT\n#define _INC_GDT 1\n\n#endif" (#ifndef) "#ifndef" (identifier) "_INC_GDT" (preproc_def) "#define _INC_GDT 1\n" (#define) "#define" (identifier) "_INC_GDT" (preproc_arg) "1" (#endif) "#endif" (comment) "/* _INC_GDT */"
10
0
{"language": "c", "success": true, "metadata": {"lines": 3, "avg_line_length": 18.33, "nodes": 8, "errors": 0, "source_hash": "72a85d96cec4777fa32728cd1562d54949b3ff53b41b86086120f4e388741b58", "categorized_nodes": 5}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef _INC_GDT\n#define _INC_GDT 1\n\n#endif", "parent": null, "children": [1, 2, 3, 7], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 3, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "identifier", "text": "_INC_GDT", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 16}}, {"id": 3, "type": "preproc_def", "text": "#define _INC_GDT 1\n", "parent": 0, "children": [4, 5, 6], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 5, "type": "identifier", "text": "_INC_GDT", "parent": 3, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 16}}, {"id": 6, "type": "preproc_arg", "text": "1", "parent": 3, "children": [], "start_point": {"row": 1, "column": 17}, "end_point": {"row": 1, "column": 18}}, {"id": 7, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 6}}]}, "node_categories": {"declarations": {"functions": [], "variables": [], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 7], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [], "class_declarations": [], "import_statements": []}, "original_source_code": "#ifndef _INC_GDT\n#define _INC_GDT 1\n\n#endif /* _INC_GDT */\n"}
80,548
c
#include <omp.h> #include <stdio.h> #include <math.h> #include<stdlib.h> #define ArraySize 32678 float Array[ArraySize]; float Ranf(float min, float max) { return min + (((float) rand() * (max-min))/ (float) (RAND_MAX)); } int main( int argc, char *argv[ ] ) { int i,j; double prod; omp_set_num_threads( NUMT ); for (i=0; i< ArraySize-1 ;i++) { Array[i] = Ranf( -1.f, 1.f ); } double time0= omp_get_wtime( ); #pragma omp parallel for shared(Array) private(prod) schedule(TYPE,CHUNK) for (i=0; i< ArraySize-1 ;i++) { prod=1.0; for(j=0; j<=i ;j++) { prod*=Array[j]; } } double time1=omp_get_wtime( ); //printf("Execution time for = %lf\n",time1-time0); long int numMuled = (long int)ArraySize * (long int)(ArraySize+1) / 2; printf("MegaMults/sec = %10.2lf\n",(double)numMuled/(time1-time0)/1000000.); return 0; }
26.13
31
(translation_unit) "#include <omp.h>\n#include <stdio.h>\n#include <math.h>\n#include<stdlib.h>\n\n#define ArraySize 32678\nfloat Array[ArraySize];\n\nfloat Ranf(float min, float max) {\n\n return min + (((float) rand() * (max-min))/ (float) (RAND_MAX));\n}\n\nint main( int argc, char *argv[ ] ) {\n\n int i,j;\n double prod;\n omp_set_num_threads( NUMT );\n\n for (i=0; i< ArraySize-1 ;i++) {\n\n Array[i] = Ranf( -1.f, 1.f );\n }\n double time0= omp_get_wtime( );\n#pragma omp parallel for shared(Array) private(prod) schedule(TYPE,CHUNK) \n for (i=0; i< ArraySize-1 ;i++) {\n prod=1.0;\n for(j=0; j<=i ;j++) {\n\n prod*=Array[j];\n }\n \n } \n double time1=omp_get_wtime( );\n\n //printf("Execution time for = %lf\n",time1-time0);\n long int numMuled = (long int)ArraySize * (long int)(ArraySize+1) / 2;\n printf("MegaMults/sec = %10.2lf\n",(double)numMuled/(time1-time0)/1000000.);\n\n return 0;\n}\n" (preproc_include) "#include <omp.h>\n" (#include) "#include" (system_lib_string) "<omp.h>" (preproc_include) "#include <stdio.h>\n" (#include) "#include" (system_lib_string) "<stdio.h>" (preproc_include) "#include <math.h>\n" (#include) "#include" (system_lib_string) "<math.h>" (preproc_include) "#include<stdlib.h>\n" (#include) "#include" (system_lib_string) "<stdlib.h>" (preproc_def) "#define ArraySize 32678\n" (#define) "#define" (identifier) "ArraySize" (preproc_arg) "32678" (declaration) "float Array[ArraySize];" (primitive_type) "float" (array_declarator) "Array[ArraySize]" (identifier) "Array" ([) "[" (identifier) "ArraySize" (]) "]" (;) ";" (function_definition) "float Ranf(float min, float max) {\n\n return min + (((float) rand() * (max-min))/ (float) (RAND_MAX));\n}" (primitive_type) "float" (function_declarator) "Ranf(float min, float max)" (identifier) "Ranf" (parameter_list) "(float min, float max)" (() "(" (parameter_declaration) "float min" (primitive_type) "float" (identifier) "min" (,) "," (parameter_declaration) "float max" (primitive_type) "float" (identifier) "max" ()) ")" (compound_statement) "{\n\n return min + (((float) rand() * (max-min))/ (float) (RAND_MAX));\n}" ({) "{" (return_statement) "return min + (((float) rand() * (max-min))/ (float) (RAND_MAX));" (return) "return" (binary_expression) "min + (((float) rand() * (max-min))/ (float) (RAND_MAX))" (identifier) "min" (+) "+" (parenthesized_expression) "(((float) rand() * (max-min))/ (float) (RAND_MAX))" (() "(" (binary_expression) "((float) rand() * (max-min))/ (float) (RAND_MAX)" (parenthesized_expression) "((float) rand() * (max-min))" (() "(" (binary_expression) "(float) rand() * (max-min)" (cast_expression) "(float) rand()" (() "(" (type_descriptor) "float" (primitive_type) "float" ()) ")" (call_expression) "rand()" (identifier) "rand" (argument_list) "()" (() "(" ()) ")" (*) "*" (parenthesized_expression) "(max-min)" (() "(" (binary_expression) "max-min" (identifier) "max" (-) "-" (identifier) "min" ()) ")" ()) ")" (/) "/" (cast_expression) "(float) (RAND_MAX)" (() "(" (type_descriptor) "float" (primitive_type) "float" ()) ")" (parenthesized_expression) "(RAND_MAX)" (() "(" (identifier) "RAND_MAX" ()) ")" ()) ")" (;) ";" (}) "}" (function_definition) "int main( int argc, char *argv[ ] ) {\n\n int i,j;\n double prod;\n omp_set_num_threads( NUMT );\n\n for (i=0; i< ArraySize-1 ;i++) {\n\n Array[i] = Ranf( -1.f, 1.f );\n }\n double time0= omp_get_wtime( );\n#pragma omp parallel for shared(Array) private(prod) schedule(TYPE,CHUNK) \n for (i=0; i< ArraySize-1 ;i++) {\n prod=1.0;\n for(j=0; j<=i ;j++) {\n\n prod*=Array[j];\n }\n \n } \n double time1=omp_get_wtime( );\n\n //printf("Execution time for = %lf\n",time1-time0);\n long int numMuled = (long int)ArraySize * (long int)(ArraySize+1) / 2;\n printf("MegaMults/sec = %10.2lf\n",(double)numMuled/(time1-time0)/1000000.);\n\n return 0;\n}" (primitive_type) "int" (function_declarator) "main( int argc, char *argv[ ] )" (identifier) "main" (parameter_list) "( int argc, char *argv[ ] )" (() "(" (parameter_declaration) "int argc" (primitive_type) "int" (identifier) "argc" (,) "," (parameter_declaration) "char *argv[ ]" (primitive_type) "char" (pointer_declarator) "*argv[ ]" (*) "*" (array_declarator) "argv[ ]" (identifier) "argv" ([) "[" (]) "]" ()) ")" (compound_statement) "{\n\n int i,j;\n double prod;\n omp_set_num_threads( NUMT );\n\n for (i=0; i< ArraySize-1 ;i++) {\n\n Array[i] = Ranf( -1.f, 1.f );\n }\n double time0= omp_get_wtime( );\n#pragma omp parallel for shared(Array) private(prod) schedule(TYPE,CHUNK) \n for (i=0; i< ArraySize-1 ;i++) {\n prod=1.0;\n for(j=0; j<=i ;j++) {\n\n prod*=Array[j];\n }\n \n } \n double time1=omp_get_wtime( );\n\n //printf("Execution time for = %lf\n",time1-time0);\n long int numMuled = (long int)ArraySize * (long int)(ArraySize+1) / 2;\n printf("MegaMults/sec = %10.2lf\n",(double)numMuled/(time1-time0)/1000000.);\n\n return 0;\n}" ({) "{" (declaration) "int i,j;" (primitive_type) "int" (identifier) "i" (,) "," (identifier) "j" (;) ";" (declaration) "double prod;" (primitive_type) "double" (identifier) "prod" (;) ";" (expression_statement) "omp_set_num_threads( NUMT );" (call_expression) "omp_set_num_threads( NUMT )" (identifier) "omp_set_num_threads" (argument_list) "( NUMT )" (() "(" (identifier) "NUMT" ()) ")" (;) ";" (for_statement) "for (i=0; i< ArraySize-1 ;i++) {\n\n Array[i] = Ranf( -1.f, 1.f );\n }" (for) "for" (() "(" (assignment_expression) "i=0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i< ArraySize-1" (identifier) "i" (<) "<" (binary_expression) "ArraySize-1" (identifier) "ArraySize" (-) "-" (number_literal) "1" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (compound_statement) "{\n\n Array[i] = Ranf( -1.f, 1.f );\n }" ({) "{" (expression_statement) "Array[i] = Ranf( -1.f, 1.f );" (assignment_expression) "Array[i] = Ranf( -1.f, 1.f )" (subscript_expression) "Array[i]" (identifier) "Array" ([) "[" (identifier) "i" (]) "]" (=) "=" (call_expression) "Ranf( -1.f, 1.f )" (identifier) "Ranf" (argument_list) "( -1.f, 1.f )" (() "(" (number_literal) "-1.f" (,) "," (number_literal) "1.f" ()) ")" (;) ";" (}) "}" (declaration) "double time0= omp_get_wtime( );" (primitive_type) "double" (init_declarator) "time0= omp_get_wtime( )" (identifier) "time0" (=) "=" (call_expression) "omp_get_wtime( )" (identifier) "omp_get_wtime" (argument_list) "( )" (() "(" ()) ")" (;) ";" (preproc_call) "#pragma omp parallel for shared(Array) private(prod) schedule(TYPE,CHUNK) \n" (preproc_directive) "#pragma" (preproc_arg) "omp parallel for shared(Array) private(prod) schedule(TYPE,CHUNK) " (for_statement) "for (i=0; i< ArraySize-1 ;i++) {\n prod=1.0;\n for(j=0; j<=i ;j++) {\n\n prod*=Array[j];\n }\n \n }" (for) "for" (() "(" (assignment_expression) "i=0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i< ArraySize-1" (identifier) "i" (<) "<" (binary_expression) "ArraySize-1" (identifier) "ArraySize" (-) "-" (number_literal) "1" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (compound_statement) "{\n prod=1.0;\n for(j=0; j<=i ;j++) {\n\n prod*=Array[j];\n }\n \n }" ({) "{" (expression_statement) "prod=1.0;" (assignment_expression) "prod=1.0" (identifier) "prod" (=) "=" (number_literal) "1.0" (;) ";" (for_statement) "for(j=0; j<=i ;j++) {\n\n prod*=Array[j];\n }" (for) "for" (() "(" (assignment_expression) "j=0" (identifier) "j" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "j<=i" (identifier) "j" (<=) "<=" (identifier) "i" (;) ";" (update_expression) "j++" (identifier) "j" (++) "++" ()) ")" (compound_statement) "{\n\n prod*=Array[j];\n }" ({) "{" (expression_statement) "prod*=Array[j];" (assignment_expression) "prod*=Array[j]" (identifier) "prod" (*=) "*=" (subscript_expression) "Array[j]" (identifier) "Array" ([) "[" (identifier) "j" (]) "]" (;) ";" (}) "}" (}) "}" (declaration) "double time1=omp_get_wtime( );" (primitive_type) "double" (init_declarator) "time1=omp_get_wtime( )" (identifier) "time1" (=) "=" (call_expression) "omp_get_wtime( )" (identifier) "omp_get_wtime" (argument_list) "( )" (() "(" ()) ")" (;) ";" (comment) "//printf("Execution time for = %lf\n",time1-time0);" (declaration) "long int numMuled = (long int)ArraySize * (long int)(ArraySize+1) / 2;" (sized_type_specifier) "long int" (long) "long" (primitive_type) "int" (init_declarator) "numMuled = (long int)ArraySize * (long int)(ArraySize+1) / 2" (identifier) "numMuled" (=) "=" (binary_expression) "(long int)ArraySize * (long int)(ArraySize+1) / 2" (binary_expression) "(long int)ArraySize * (long int)(ArraySize+1)" (cast_expression) "(long int)ArraySize" (() "(" (type_descriptor) "long int" (sized_type_specifier) "long int" (long) "long" (primitive_type) "int" ()) ")" (identifier) "ArraySize" (*) "*" (cast_expression) "(long int)(ArraySize+1)" (() "(" (type_descriptor) "long int" (sized_type_specifier) "long int" (long) "long" (primitive_type) "int" ()) ")" (parenthesized_expression) "(ArraySize+1)" (() "(" (binary_expression) "ArraySize+1" (identifier) "ArraySize" (+) "+" (number_literal) "1" ()) ")" (/) "/" (number_literal) "2" (;) ";" (expression_statement) "printf("MegaMults/sec = %10.2lf\n",(double)numMuled/(time1-time0)/1000000.);" (call_expression) "printf("MegaMults/sec = %10.2lf\n",(double)numMuled/(time1-time0)/1000000.)" (identifier) "printf" (argument_list) "("MegaMults/sec = %10.2lf\n",(double)numMuled/(time1-time0)/1000000.)" (() "(" (string_literal) ""MegaMults/sec = %10.2lf\n"" (") """ (string_content) "MegaMults/sec = %10.2lf" (escape_sequence) "\n" (") """ (,) "," (binary_expression) "(double)numMuled/(time1-time0)/1000000." (binary_expression) "(double)numMuled/(time1-time0)" (cast_expression) "(double)numMuled" (() "(" (type_descriptor) "double" (primitive_type) "double" ()) ")" (identifier) "numMuled" (/) "/" (parenthesized_expression) "(time1-time0)" (() "(" (binary_expression) "time1-time0" (identifier) "time1" (-) "-" (identifier) "time0" ()) ")" (/) "/" (number_literal) "1000000." ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}"
319
0
{"language": "c", "success": true, "metadata": {"lines": 31, "avg_line_length": 26.13, "nodes": 213, "errors": 0, "source_hash": "a9cdd46a77c5dba90ac5d48051380c01315c2244912a7f651f89add681e54243", "categorized_nodes": 140}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <omp.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<omp.h>", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 16}}, {"id": 3, "type": "preproc_include", "text": "#include <stdio.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<stdio.h>", "parent": 3, "children": [], "start_point": {"row": 1, "column": 9}, "end_point": {"row": 1, "column": 18}}, {"id": 6, "type": "preproc_include", "text": "#include <math.h>\n", "parent": null, "children": [7, 8], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<math.h>", "parent": 6, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 17}}, {"id": 9, "type": "preproc_include", "text": "#include<stdlib.h>\n", "parent": null, "children": [10, 11], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<stdlib.h>", "parent": 9, "children": [], "start_point": {"row": 3, "column": 8}, "end_point": {"row": 3, "column": 18}}, {"id": 12, "type": "preproc_def", "text": "#define ArraySize 32678\n", "parent": null, "children": [13, 14, 15], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 13, "type": "#define", "text": "#define", "parent": 12, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 7}}, {"id": 14, "type": "identifier", "text": "ArraySize", "parent": 12, "children": [], "start_point": {"row": 5, "column": 8}, "end_point": {"row": 5, "column": 17}}, {"id": 15, "type": "preproc_arg", "text": "32678", "parent": 12, "children": [], "start_point": {"row": 5, "column": 18}, "end_point": {"row": 5, "column": 23}}, {"id": 16, "type": "declaration", "text": "float Array[ArraySize];", "parent": null, "children": [17, 18], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 23}}, {"id": 17, "type": "primitive_type", "text": "float", "parent": 16, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 5}}, {"id": 18, "type": "array_declarator", "text": "Array[ArraySize]", "parent": 16, "children": [19, 20], "start_point": {"row": 6, "column": 6}, "end_point": {"row": 6, "column": 22}}, {"id": 19, "type": "identifier", "text": "Array", "parent": 18, "children": [], "start_point": {"row": 6, "column": 6}, "end_point": {"row": 6, "column": 11}}, {"id": 20, "type": "identifier", "text": "ArraySize", "parent": 18, "children": [], "start_point": {"row": 6, "column": 12}, "end_point": {"row": 6, "column": 21}}, {"id": 21, "type": "function_definition", "text": "float Ranf(float min, float max) {\n\n\treturn min + (((float) rand() * (max-min))/ (float) (RAND_MAX));\n}", "parent": null, "children": [22, 23], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 11, "column": 1}}, {"id": 22, "type": "primitive_type", "text": "float", "parent": 21, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 5}}, {"id": 23, "type": "function_declarator", "text": "Ranf(float min, float max)", "parent": 21, "children": [24, 25], "start_point": {"row": 8, "column": 6}, "end_point": {"row": 8, "column": 32}}, {"id": 24, "type": "identifier", "text": "Ranf", "parent": 23, "children": [], "start_point": {"row": 8, "column": 6}, "end_point": {"row": 8, "column": 10}}, {"id": 25, "type": "parameter_list", "text": "(float min, float max)", "parent": 23, "children": [26, 29], "start_point": {"row": 8, "column": 10}, "end_point": {"row": 8, "column": 32}}, {"id": 26, "type": "parameter_declaration", "text": "float min", "parent": 25, "children": [27, 28], "start_point": {"row": 8, "column": 11}, "end_point": {"row": 8, "column": 20}}, {"id": 27, "type": "primitive_type", "text": "float", "parent": 26, "children": [], "start_point": {"row": 8, "column": 11}, "end_point": {"row": 8, "column": 16}}, {"id": 28, "type": "identifier", "text": "min", "parent": 26, "children": [], "start_point": {"row": 8, "column": 17}, "end_point": {"row": 8, "column": 20}}, {"id": 29, "type": "parameter_declaration", "text": "float max", "parent": 25, "children": [30, 31], "start_point": {"row": 8, "column": 22}, "end_point": {"row": 8, "column": 31}}, {"id": 30, "type": "primitive_type", "text": "float", "parent": 29, "children": [], "start_point": {"row": 8, "column": 22}, "end_point": {"row": 8, "column": 27}}, {"id": 31, "type": "identifier", "text": "max", "parent": 29, "children": [], "start_point": {"row": 8, "column": 28}, "end_point": {"row": 8, "column": 31}}, {"id": 32, "type": "return_statement", "text": "return min + (((float) rand() * (max-min))/ (float) (RAND_MAX));", "parent": 21, "children": [33], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 65}}, {"id": 33, "type": "binary_expression", "text": "min + (((float) rand() * (max-min))/ (float) (RAND_MAX))", "parent": 32, "children": [34, 35, 36], "start_point": {"row": 10, "column": 8}, "end_point": {"row": 10, "column": 64}}, {"id": 34, "type": "identifier", "text": "min", "parent": 33, "children": [], "start_point": {"row": 10, "column": 8}, "end_point": {"row": 10, "column": 11}}, {"id": 35, "type": "+", "text": "+", "parent": 33, "children": [], "start_point": {"row": 10, "column": 12}, "end_point": {"row": 10, "column": 13}}, {"id": 36, "type": "parenthesized_expression", "text": "(((float) rand() * (max-min))/ (float) (RAND_MAX))", "parent": 33, "children": [37], "start_point": {"row": 10, "column": 14}, "end_point": {"row": 10, "column": 64}}, {"id": 37, "type": "binary_expression", "text": "((float) rand() * (max-min))/ (float) (RAND_MAX)", "parent": 36, "children": [38, 52, 53], "start_point": {"row": 10, "column": 15}, "end_point": {"row": 10, "column": 63}}, {"id": 38, "type": "parenthesized_expression", "text": "((float) rand() * (max-min))", "parent": 37, "children": [39], "start_point": {"row": 10, "column": 15}, "end_point": {"row": 10, "column": 43}}, {"id": 39, "type": "binary_expression", "text": "(float) rand() * (max-min)", "parent": 38, "children": [40, 46, 47], "start_point": {"row": 10, "column": 16}, "end_point": {"row": 10, "column": 42}}, {"id": 40, "type": "cast_expression", "text": "(float) rand()", "parent": 39, "children": [41, 43], "start_point": {"row": 10, "column": 16}, "end_point": {"row": 10, "column": 30}}, {"id": 41, "type": "type_descriptor", "text": "float", "parent": 40, "children": [42], "start_point": {"row": 10, "column": 17}, "end_point": {"row": 10, "column": 22}}, {"id": 42, "type": "primitive_type", "text": "float", "parent": 41, "children": [], "start_point": {"row": 10, "column": 17}, "end_point": {"row": 10, "column": 22}}, {"id": 43, "type": "call_expression", "text": "rand()", "parent": 40, "children": [44, 45], "start_point": {"row": 10, "column": 24}, "end_point": {"row": 10, "column": 30}}, {"id": 44, "type": "identifier", "text": "rand", "parent": 43, "children": [], "start_point": {"row": 10, "column": 24}, "end_point": {"row": 10, "column": 28}}, {"id": 45, "type": "argument_list", "text": "()", "parent": 43, "children": [], "start_point": {"row": 10, "column": 28}, "end_point": {"row": 10, "column": 30}}, {"id": 46, "type": "*", "text": "*", "parent": 39, "children": [], "start_point": {"row": 10, "column": 31}, "end_point": {"row": 10, "column": 32}}, {"id": 47, "type": "parenthesized_expression", "text": "(max-min)", "parent": 39, "children": [48], "start_point": {"row": 10, "column": 33}, "end_point": {"row": 10, "column": 42}}, {"id": 48, "type": "binary_expression", "text": "max-min", "parent": 47, "children": [49, 50, 51], "start_point": {"row": 10, "column": 34}, "end_point": {"row": 10, "column": 41}}, {"id": 49, "type": "identifier", "text": "max", "parent": 48, "children": [], "start_point": {"row": 10, "column": 34}, "end_point": {"row": 10, "column": 37}}, {"id": 50, "type": "-", "text": "-", "parent": 48, "children": [], "start_point": {"row": 10, "column": 37}, "end_point": {"row": 10, "column": 38}}, {"id": 51, "type": "identifier", "text": "min", "parent": 48, "children": [], "start_point": {"row": 10, "column": 38}, "end_point": {"row": 10, "column": 41}}, {"id": 52, "type": "/", "text": "/", "parent": 37, "children": [], "start_point": {"row": 10, "column": 43}, "end_point": {"row": 10, "column": 44}}, {"id": 53, "type": "cast_expression", "text": "(float) (RAND_MAX)", "parent": 37, "children": [54, 56], "start_point": {"row": 10, "column": 45}, "end_point": {"row": 10, "column": 63}}, {"id": 54, "type": "type_descriptor", "text": "float", "parent": 53, "children": [55], "start_point": {"row": 10, "column": 46}, "end_point": {"row": 10, "column": 51}}, {"id": 55, "type": "primitive_type", "text": "float", "parent": 54, "children": [], "start_point": {"row": 10, "column": 46}, "end_point": {"row": 10, "column": 51}}, {"id": 56, "type": "parenthesized_expression", "text": "(RAND_MAX)", "parent": 53, "children": [57], "start_point": {"row": 10, "column": 53}, "end_point": {"row": 10, "column": 63}}, {"id": 57, "type": "identifier", "text": "RAND_MAX", "parent": 56, "children": [], "start_point": {"row": 10, "column": 54}, "end_point": {"row": 10, "column": 62}}, {"id": 58, "type": "function_definition", "text": "int main( int argc, char *argv[ ] ) {\n\n\tint i,j;\n\tdouble prod;\n\tomp_set_num_threads( NUMT );\n\n\tfor (i=0; i< ArraySize-1 ;i++) {\n\n\t\tArray[i] = Ranf( -1.f, 1.f );\n\t}\n\tdouble time0= omp_get_wtime( );\n#pragma omp parallel for shared(Array) private(prod) schedule(TYPE,CHUNK)\t\n\tfor (i=0; i< ArraySize-1 ;i++) {\n\t\tprod=1.0;\n\t\tfor(j=0; j<=i ;j++) {\n\n\t\t\tprod*=Array[j];\n\t\t}\n\t\t\n\t}\t\n\tdouble time1=omp_get_wtime( );\n\n\t//printf(\"Execution time for = %lf\\n\",time1-time0);\n\tlong int numMuled = (long int)ArraySize * (long int)(ArraySize+1) / 2;\n\tprintf(\"MegaMults/sec = %10.2lf\\n\",(double)numMuled/(time1-time0)/1000000.);\n\n\treturn 0;\n}", "parent": null, "children": [59, 60], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 40, "column": 1}}, {"id": 59, "type": "primitive_type", "text": "int", "parent": 58, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 3}}, {"id": 60, "type": "function_declarator", "text": "main( int argc, char *argv[ ] )", "parent": 58, "children": [61, 62], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 35}}, {"id": 61, "type": "identifier", "text": "main", "parent": 60, "children": [], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 8}}, {"id": 62, "type": "parameter_list", "text": "( int argc, char *argv[ ] )", "parent": 60, "children": [63, 66], "start_point": {"row": 13, "column": 8}, "end_point": {"row": 13, "column": 35}}, {"id": 63, "type": "parameter_declaration", "text": "int argc", "parent": 62, "children": [64, 65], "start_point": {"row": 13, "column": 10}, "end_point": {"row": 13, "column": 18}}, {"id": 64, "type": "primitive_type", "text": "int", "parent": 63, "children": [], "start_point": {"row": 13, "column": 10}, "end_point": {"row": 13, "column": 13}}, {"id": 65, "type": "identifier", "text": "argc", "parent": 63, "children": [], "start_point": {"row": 13, "column": 14}, "end_point": {"row": 13, "column": 18}}, {"id": 66, "type": "parameter_declaration", "text": "char *argv[ ]", "parent": 62, "children": [67, 68], "start_point": {"row": 13, "column": 20}, "end_point": {"row": 13, "column": 33}}, {"id": 67, "type": "primitive_type", "text": "char", "parent": 66, "children": [], "start_point": {"row": 13, "column": 20}, "end_point": {"row": 13, "column": 24}}, {"id": 68, "type": "pointer_declarator", "text": "*argv[ ]", "parent": 66, "children": [69, 70], "start_point": {"row": 13, "column": 25}, "end_point": {"row": 13, "column": 33}}, {"id": 69, "type": "*", "text": "*", "parent": 68, "children": [], "start_point": {"row": 13, "column": 25}, "end_point": {"row": 13, "column": 26}}, {"id": 70, "type": "array_declarator", "text": "argv[ ]", "parent": 68, "children": [71], "start_point": {"row": 13, "column": 26}, "end_point": {"row": 13, "column": 33}}, {"id": 71, "type": "identifier", "text": "argv", "parent": 70, "children": [], "start_point": {"row": 13, "column": 26}, "end_point": {"row": 13, "column": 30}}, {"id": 72, "type": "declaration", "text": "int i,j;", "parent": 58, "children": [73, 74, 75], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 9}}, {"id": 73, "type": "primitive_type", "text": "int", "parent": 72, "children": [], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 4}}, {"id": 74, "type": "identifier", "text": "i", "parent": 72, "children": [], "start_point": {"row": 15, "column": 5}, "end_point": {"row": 15, "column": 6}}, {"id": 75, "type": "identifier", "text": "j", "parent": 72, "children": [], "start_point": {"row": 15, "column": 7}, "end_point": {"row": 15, "column": 8}}, {"id": 76, "type": "declaration", "text": "double prod;", "parent": 58, "children": [77, 78], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 13}}, {"id": 77, "type": "primitive_type", "text": "double", "parent": 76, "children": [], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 7}}, {"id": 78, "type": "identifier", "text": "prod", "parent": 76, "children": [], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 12}}, {"id": 79, "type": "call_expression", "text": "omp_set_num_threads( NUMT )", "parent": 58, "children": [80, 81], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 28}}, {"id": 80, "type": "identifier", "text": "omp_set_num_threads", "parent": 79, "children": [], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 20}}, {"id": 81, "type": "argument_list", "text": "( NUMT )", "parent": 79, "children": [82], "start_point": {"row": 17, "column": 20}, "end_point": {"row": 17, "column": 28}}, {"id": 82, "type": "identifier", "text": "NUMT", "parent": 81, "children": [], "start_point": {"row": 17, "column": 22}, "end_point": {"row": 17, "column": 26}}, {"id": 83, "type": "for_statement", "text": "for (i=0; i< ArraySize-1 ;i++) {\n\n\t\tArray[i] = Ranf( -1.f, 1.f );\n\t}", "parent": 58, "children": [84, 88, 95], "start_point": {"row": 19, "column": 1}, "end_point": {"row": 22, "column": 2}}, {"id": 84, "type": "assignment_expression", "text": "i=0", "parent": 83, "children": [85, 86, 87], "start_point": {"row": 19, "column": 6}, "end_point": {"row": 19, "column": 9}}, {"id": 85, "type": "identifier", "text": "i", "parent": 84, "children": [], "start_point": {"row": 19, "column": 6}, "end_point": {"row": 19, "column": 7}}, {"id": 86, "type": "=", "text": "=", "parent": 84, "children": [], "start_point": {"row": 19, "column": 7}, "end_point": {"row": 19, "column": 8}}, {"id": 87, "type": "number_literal", "text": "0", "parent": 84, "children": [], "start_point": {"row": 19, "column": 8}, "end_point": {"row": 19, "column": 9}}, {"id": 88, "type": "binary_expression", "text": "i< ArraySize-1", "parent": 83, "children": [89, 90, 91], "start_point": {"row": 19, "column": 11}, "end_point": {"row": 19, "column": 25}}, {"id": 89, "type": "identifier", "text": "i", "parent": 88, "children": [], "start_point": {"row": 19, "column": 11}, "end_point": {"row": 19, "column": 12}}, {"id": 90, "type": "<", "text": "<", "parent": 88, "children": [], "start_point": {"row": 19, "column": 12}, "end_point": {"row": 19, "column": 13}}, {"id": 91, "type": "binary_expression", "text": "ArraySize-1", "parent": 88, "children": [92, 93, 94], "start_point": {"row": 19, "column": 14}, "end_point": {"row": 19, "column": 25}}, {"id": 92, "type": "identifier", "text": "ArraySize", "parent": 91, "children": [], "start_point": {"row": 19, "column": 14}, "end_point": {"row": 19, "column": 23}}, {"id": 93, "type": "-", "text": "-", "parent": 91, "children": [], "start_point": {"row": 19, "column": 23}, "end_point": {"row": 19, "column": 24}}, {"id": 94, "type": "number_literal", "text": "1", "parent": 91, "children": [], "start_point": {"row": 19, "column": 24}, "end_point": {"row": 19, "column": 25}}, {"id": 95, "type": "update_expression", "text": "i++", "parent": 83, "children": [96, 97], "start_point": {"row": 19, "column": 27}, "end_point": {"row": 19, "column": 30}}, {"id": 96, "type": "identifier", "text": "i", "parent": 95, "children": [], "start_point": {"row": 19, "column": 27}, "end_point": {"row": 19, "column": 28}}, {"id": 97, "type": "++", "text": "++", "parent": 95, "children": [], "start_point": {"row": 19, "column": 28}, "end_point": {"row": 19, "column": 30}}, {"id": 98, "type": "assignment_expression", "text": "Array[i] = Ranf( -1.f, 1.f )", "parent": 83, "children": [99, 102, 103], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 30}}, {"id": 99, "type": "subscript_expression", "text": "Array[i]", "parent": 98, "children": [100, 101], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 10}}, {"id": 100, "type": "identifier", "text": "Array", "parent": 99, "children": [], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 7}}, {"id": 101, "type": "identifier", "text": "i", "parent": 99, "children": [], "start_point": {"row": 21, "column": 8}, "end_point": {"row": 21, "column": 9}}, {"id": 102, "type": "=", "text": "=", "parent": 98, "children": [], "start_point": {"row": 21, "column": 11}, "end_point": {"row": 21, "column": 12}}, {"id": 103, "type": "call_expression", "text": "Ranf( -1.f, 1.f )", "parent": 98, "children": [104, 105], "start_point": {"row": 21, "column": 13}, "end_point": {"row": 21, "column": 30}}, {"id": 104, "type": "identifier", "text": "Ranf", "parent": 103, "children": [], "start_point": {"row": 21, "column": 13}, "end_point": {"row": 21, "column": 17}}, {"id": 105, "type": "argument_list", "text": "( -1.f, 1.f )", "parent": 103, "children": [106, 107], "start_point": {"row": 21, "column": 17}, "end_point": {"row": 21, "column": 30}}, {"id": 106, "type": "number_literal", "text": "-1.f", "parent": 105, "children": [], "start_point": {"row": 21, "column": 19}, "end_point": {"row": 21, "column": 23}}, {"id": 107, "type": "number_literal", "text": "1.f", "parent": 105, "children": [], "start_point": {"row": 21, "column": 25}, "end_point": {"row": 21, "column": 28}}, {"id": 108, "type": "declaration", "text": "double time0= omp_get_wtime( );", "parent": 58, "children": [109, 110], "start_point": {"row": 23, "column": 1}, "end_point": {"row": 23, "column": 32}}, {"id": 109, "type": "primitive_type", "text": "double", "parent": 108, "children": [], "start_point": {"row": 23, "column": 1}, "end_point": {"row": 23, "column": 7}}, {"id": 110, "type": "init_declarator", "text": "time0= omp_get_wtime( )", "parent": 108, "children": [111, 112, 113], "start_point": {"row": 23, "column": 8}, "end_point": {"row": 23, "column": 31}}, {"id": 111, "type": "identifier", "text": "time0", "parent": 110, "children": [], "start_point": {"row": 23, "column": 8}, "end_point": {"row": 23, "column": 13}}, {"id": 112, "type": "=", "text": "=", "parent": 110, "children": [], "start_point": {"row": 23, "column": 13}, "end_point": {"row": 23, "column": 14}}, {"id": 113, "type": "call_expression", "text": "omp_get_wtime( )", "parent": 110, "children": [114, 115], "start_point": {"row": 23, "column": 15}, "end_point": {"row": 23, "column": 31}}, {"id": 114, "type": "identifier", "text": "omp_get_wtime", "parent": 113, "children": [], "start_point": {"row": 23, "column": 15}, "end_point": {"row": 23, "column": 28}}, {"id": 115, "type": "argument_list", "text": "( )", "parent": 113, "children": [], "start_point": {"row": 23, "column": 28}, "end_point": {"row": 23, "column": 31}}, {"id": 116, "type": "preproc_call", "text": "#pragma omp parallel for shared(Array) private(prod) schedule(TYPE,CHUNK)\t\n", "parent": 58, "children": [117, 118], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 25, "column": 0}}, {"id": 117, "type": "preproc_directive", "text": "#pragma", "parent": 116, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 7}}, {"id": 118, "type": "preproc_arg", "text": "omp parallel for shared(Array) private(prod) schedule(TYPE,CHUNK)\t", "parent": 116, "children": [], "start_point": {"row": 24, "column": 8}, "end_point": {"row": 24, "column": 74}}, {"id": 119, "type": "for_statement", "text": "for (i=0; i< ArraySize-1 ;i++) {\n\t\tprod=1.0;\n\t\tfor(j=0; j<=i ;j++) {\n\n\t\t\tprod*=Array[j];\n\t\t}\n\t\t\n\t}", "parent": 58, "children": [120, 124, 131], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 32, "column": 2}}, {"id": 120, "type": "assignment_expression", "text": "i=0", "parent": 119, "children": [121, 122, 123], "start_point": {"row": 25, "column": 6}, "end_point": {"row": 25, "column": 9}}, {"id": 121, "type": "identifier", "text": "i", "parent": 120, "children": [], "start_point": {"row": 25, "column": 6}, "end_point": {"row": 25, "column": 7}}, {"id": 122, "type": "=", "text": "=", "parent": 120, "children": [], "start_point": {"row": 25, "column": 7}, "end_point": {"row": 25, "column": 8}}, {"id": 123, "type": "number_literal", "text": "0", "parent": 120, "children": [], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 9}}, {"id": 124, "type": "binary_expression", "text": "i< ArraySize-1", "parent": 119, "children": [125, 126, 127], "start_point": {"row": 25, "column": 11}, "end_point": {"row": 25, "column": 25}}, {"id": 125, "type": "identifier", "text": "i", "parent": 124, "children": [], "start_point": {"row": 25, "column": 11}, "end_point": {"row": 25, "column": 12}}, {"id": 126, "type": "<", "text": "<", "parent": 124, "children": [], "start_point": {"row": 25, "column": 12}, "end_point": {"row": 25, "column": 13}}, {"id": 127, "type": "binary_expression", "text": "ArraySize-1", "parent": 124, "children": [128, 129, 130], "start_point": {"row": 25, "column": 14}, "end_point": {"row": 25, "column": 25}}, {"id": 128, "type": "identifier", "text": "ArraySize", "parent": 127, "children": [], "start_point": {"row": 25, "column": 14}, "end_point": {"row": 25, "column": 23}}, {"id": 129, "type": "-", "text": "-", "parent": 127, "children": [], "start_point": {"row": 25, "column": 23}, "end_point": {"row": 25, "column": 24}}, {"id": 130, "type": "number_literal", "text": "1", "parent": 127, "children": [], "start_point": {"row": 25, "column": 24}, "end_point": {"row": 25, "column": 25}}, {"id": 131, "type": "update_expression", "text": "i++", "parent": 119, "children": [132, 133], "start_point": {"row": 25, "column": 27}, "end_point": {"row": 25, "column": 30}}, {"id": 132, "type": "identifier", "text": "i", "parent": 131, "children": [], "start_point": {"row": 25, "column": 27}, "end_point": {"row": 25, "column": 28}}, {"id": 133, "type": "++", "text": "++", "parent": 131, "children": [], "start_point": {"row": 25, "column": 28}, "end_point": {"row": 25, "column": 30}}, {"id": 134, "type": "assignment_expression", "text": "prod=1.0", "parent": 119, "children": [135, 136, 137], "start_point": {"row": 26, "column": 2}, "end_point": {"row": 26, "column": 10}}, {"id": 135, "type": "identifier", "text": "prod", "parent": 134, "children": [], "start_point": {"row": 26, "column": 2}, "end_point": {"row": 26, "column": 6}}, {"id": 136, "type": "=", "text": "=", "parent": 134, "children": [], "start_point": {"row": 26, "column": 6}, "end_point": {"row": 26, "column": 7}}, {"id": 137, "type": "number_literal", "text": "1.0", "parent": 134, "children": [], "start_point": {"row": 26, "column": 7}, "end_point": {"row": 26, "column": 10}}, {"id": 138, "type": "for_statement", "text": "for(j=0; j<=i ;j++) {\n\n\t\t\tprod*=Array[j];\n\t\t}", "parent": 119, "children": [139, 143, 147], "start_point": {"row": 27, "column": 2}, "end_point": {"row": 30, "column": 3}}, {"id": 139, "type": "assignment_expression", "text": "j=0", "parent": 138, "children": [140, 141, 142], "start_point": {"row": 27, "column": 6}, "end_point": {"row": 27, "column": 9}}, {"id": 140, "type": "identifier", "text": "j", "parent": 139, "children": [], "start_point": {"row": 27, "column": 6}, "end_point": {"row": 27, "column": 7}}, {"id": 141, "type": "=", "text": "=", "parent": 139, "children": [], "start_point": {"row": 27, "column": 7}, "end_point": {"row": 27, "column": 8}}, {"id": 142, "type": "number_literal", "text": "0", "parent": 139, "children": [], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 9}}, {"id": 143, "type": "binary_expression", "text": "j<=i", "parent": 138, "children": [144, 145, 146], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 15}}, {"id": 144, "type": "identifier", "text": "j", "parent": 143, "children": [], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 12}}, {"id": 145, "type": "<=", "text": "<=", "parent": 143, "children": [], "start_point": {"row": 27, "column": 12}, "end_point": {"row": 27, "column": 14}}, {"id": 146, "type": "identifier", "text": "i", "parent": 143, "children": [], "start_point": {"row": 27, "column": 14}, "end_point": {"row": 27, "column": 15}}, {"id": 147, "type": "update_expression", "text": "j++", "parent": 138, "children": [148, 149], "start_point": {"row": 27, "column": 17}, "end_point": {"row": 27, "column": 20}}, {"id": 148, "type": "identifier", "text": "j", "parent": 147, "children": [], "start_point": {"row": 27, "column": 17}, "end_point": {"row": 27, "column": 18}}, {"id": 149, "type": "++", "text": "++", "parent": 147, "children": [], "start_point": {"row": 27, "column": 18}, "end_point": {"row": 27, "column": 20}}, {"id": 150, "type": "assignment_expression", "text": "prod*=Array[j]", "parent": 138, "children": [151, 152, 153], "start_point": {"row": 29, "column": 3}, "end_point": {"row": 29, "column": 17}}, {"id": 151, "type": "identifier", "text": "prod", "parent": 150, "children": [], "start_point": {"row": 29, "column": 3}, "end_point": {"row": 29, "column": 7}}, {"id": 152, "type": "*=", "text": "*=", "parent": 150, "children": [], "start_point": {"row": 29, "column": 7}, "end_point": {"row": 29, "column": 9}}, {"id": 153, "type": "subscript_expression", "text": "Array[j]", "parent": 150, "children": [154, 155], "start_point": {"row": 29, "column": 9}, "end_point": {"row": 29, "column": 17}}, {"id": 154, "type": "identifier", "text": "Array", "parent": 153, "children": [], "start_point": {"row": 29, "column": 9}, "end_point": {"row": 29, "column": 14}}, {"id": 155, "type": "identifier", "text": "j", "parent": 153, "children": [], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 16}}, {"id": 156, "type": "declaration", "text": "double time1=omp_get_wtime( );", "parent": 58, "children": [157, 158], "start_point": {"row": 33, "column": 1}, "end_point": {"row": 33, "column": 31}}, {"id": 157, "type": "primitive_type", "text": "double", "parent": 156, "children": [], "start_point": {"row": 33, "column": 1}, "end_point": {"row": 33, "column": 7}}, {"id": 158, "type": "init_declarator", "text": "time1=omp_get_wtime( )", "parent": 156, "children": [159, 160, 161], "start_point": {"row": 33, "column": 8}, "end_point": {"row": 33, "column": 30}}, {"id": 159, "type": "identifier", "text": "time1", "parent": 158, "children": [], "start_point": {"row": 33, "column": 8}, "end_point": {"row": 33, "column": 13}}, {"id": 160, "type": "=", "text": "=", "parent": 158, "children": [], "start_point": {"row": 33, "column": 13}, "end_point": {"row": 33, "column": 14}}, {"id": 161, "type": "call_expression", "text": "omp_get_wtime( )", "parent": 158, "children": [162, 163], "start_point": {"row": 33, "column": 14}, "end_point": {"row": 33, "column": 30}}, {"id": 162, "type": "identifier", "text": "omp_get_wtime", "parent": 161, "children": [], "start_point": {"row": 33, "column": 14}, "end_point": {"row": 33, "column": 27}}, {"id": 163, "type": "argument_list", "text": "( )", "parent": 161, "children": [], "start_point": {"row": 33, "column": 27}, "end_point": {"row": 33, "column": 30}}, {"id": 164, "type": "declaration", "text": "long int numMuled = (long int)ArraySize * (long int)(ArraySize+1) / 2;", "parent": 58, "children": [165, 168], "start_point": {"row": 36, "column": 1}, "end_point": {"row": 36, "column": 71}}, {"id": 165, "type": "sized_type_specifier", "text": "long int", "parent": 164, "children": [166, 167], "start_point": {"row": 36, "column": 1}, "end_point": {"row": 36, "column": 9}}, {"id": 166, "type": "long", "text": "long", "parent": 165, "children": [], "start_point": {"row": 36, "column": 1}, "end_point": {"row": 36, "column": 5}}, {"id": 167, "type": "primitive_type", "text": "int", "parent": 165, "children": [], "start_point": {"row": 36, "column": 6}, "end_point": {"row": 36, "column": 9}}, {"id": 168, "type": "init_declarator", "text": "numMuled = (long int)ArraySize * (long int)(ArraySize+1) / 2", "parent": 164, "children": [169, 170, 171], "start_point": {"row": 36, "column": 10}, "end_point": {"row": 36, "column": 70}}, {"id": 169, "type": "identifier", "text": "numMuled", "parent": 168, "children": [], "start_point": {"row": 36, "column": 10}, "end_point": {"row": 36, "column": 18}}, {"id": 170, "type": "=", "text": "=", "parent": 168, "children": [], "start_point": {"row": 36, "column": 19}, "end_point": {"row": 36, "column": 20}}, {"id": 171, "type": "binary_expression", "text": "(long int)ArraySize * (long int)(ArraySize+1) / 2", "parent": 168, "children": [172, 190, 191], "start_point": {"row": 36, "column": 21}, "end_point": {"row": 36, "column": 70}}, {"id": 172, "type": "binary_expression", "text": "(long int)ArraySize * (long int)(ArraySize+1)", "parent": 171, "children": [173, 179, 180], "start_point": {"row": 36, "column": 21}, "end_point": {"row": 36, "column": 66}}, {"id": 173, "type": "cast_expression", "text": "(long int)ArraySize", "parent": 172, "children": [174, 178], "start_point": {"row": 36, "column": 21}, "end_point": {"row": 36, "column": 40}}, {"id": 174, "type": "type_descriptor", "text": "long int", "parent": 173, "children": [175], "start_point": {"row": 36, "column": 22}, "end_point": {"row": 36, "column": 30}}, {"id": 175, "type": "sized_type_specifier", "text": "long int", "parent": 174, "children": [176, 177], "start_point": {"row": 36, "column": 22}, "end_point": {"row": 36, "column": 30}}, {"id": 176, "type": "long", "text": "long", "parent": 175, "children": [], "start_point": {"row": 36, "column": 22}, "end_point": {"row": 36, "column": 26}}, {"id": 177, "type": "primitive_type", "text": "int", "parent": 175, "children": [], "start_point": {"row": 36, "column": 27}, "end_point": {"row": 36, "column": 30}}, {"id": 178, "type": "identifier", "text": "ArraySize", "parent": 173, "children": [], "start_point": {"row": 36, "column": 31}, "end_point": {"row": 36, "column": 40}}, {"id": 179, "type": "*", "text": "*", "parent": 172, "children": [], "start_point": {"row": 36, "column": 41}, "end_point": {"row": 36, "column": 42}}, {"id": 180, "type": "cast_expression", "text": "(long int)(ArraySize+1)", "parent": 172, "children": [181, 185], "start_point": {"row": 36, "column": 43}, "end_point": {"row": 36, "column": 66}}, {"id": 181, "type": "type_descriptor", "text": "long int", "parent": 180, "children": [182], "start_point": {"row": 36, "column": 44}, "end_point": {"row": 36, "column": 52}}, {"id": 182, "type": "sized_type_specifier", "text": "long int", "parent": 181, "children": [183, 184], "start_point": {"row": 36, "column": 44}, "end_point": {"row": 36, "column": 52}}, {"id": 183, "type": "long", "text": "long", "parent": 182, "children": [], "start_point": {"row": 36, "column": 44}, "end_point": {"row": 36, "column": 48}}, {"id": 184, "type": "primitive_type", "text": "int", "parent": 182, "children": [], "start_point": {"row": 36, "column": 49}, "end_point": {"row": 36, "column": 52}}, {"id": 185, "type": "parenthesized_expression", "text": "(ArraySize+1)", "parent": 180, "children": [186], "start_point": {"row": 36, "column": 53}, "end_point": {"row": 36, "column": 66}}, {"id": 186, "type": "binary_expression", "text": "ArraySize+1", "parent": 185, "children": [187, 188, 189], "start_point": {"row": 36, "column": 54}, "end_point": {"row": 36, "column": 65}}, {"id": 187, "type": "identifier", "text": "ArraySize", "parent": 186, "children": [], "start_point": {"row": 36, "column": 54}, "end_point": {"row": 36, "column": 63}}, {"id": 188, "type": "+", "text": "+", "parent": 186, "children": [], "start_point": {"row": 36, "column": 63}, "end_point": {"row": 36, "column": 64}}, {"id": 189, "type": "number_literal", "text": "1", "parent": 186, "children": [], "start_point": {"row": 36, "column": 64}, "end_point": {"row": 36, "column": 65}}, {"id": 190, "type": "/", "text": "/", "parent": 171, "children": [], "start_point": {"row": 36, "column": 67}, "end_point": {"row": 36, "column": 68}}, {"id": 191, "type": "number_literal", "text": "2", "parent": 171, "children": [], "start_point": {"row": 36, "column": 69}, "end_point": {"row": 36, "column": 70}}, {"id": 192, "type": "call_expression", "text": "printf(\"MegaMults/sec = %10.2lf\\n\",(double)numMuled/(time1-time0)/1000000.)", "parent": 58, "children": [193, 194], "start_point": {"row": 37, "column": 1}, "end_point": {"row": 37, "column": 76}}, {"id": 193, "type": "identifier", "text": "printf", "parent": 192, "children": [], "start_point": {"row": 37, "column": 1}, "end_point": {"row": 37, "column": 7}}, {"id": 194, "type": "argument_list", "text": "(\"MegaMults/sec = %10.2lf\\n\",(double)numMuled/(time1-time0)/1000000.)", "parent": 192, "children": [195, 197], "start_point": {"row": 37, "column": 7}, "end_point": {"row": 37, "column": 76}}, {"id": 195, "type": "string_literal", "text": "\"MegaMults/sec = %10.2lf\\n\"", "parent": 194, "children": [196], "start_point": {"row": 37, "column": 8}, "end_point": {"row": 37, "column": 35}}, {"id": 196, "type": "escape_sequence", "text": "\\n", "parent": 195, "children": [], "start_point": {"row": 37, "column": 32}, "end_point": {"row": 37, "column": 34}}, {"id": 197, "type": "binary_expression", "text": "(double)numMuled/(time1-time0)/1000000.", "parent": 194, "children": [198, 209, 210], "start_point": {"row": 37, "column": 36}, "end_point": {"row": 37, "column": 75}}, {"id": 198, "type": "binary_expression", "text": "(double)numMuled/(time1-time0)", "parent": 197, "children": [199, 203, 204], "start_point": {"row": 37, "column": 36}, "end_point": {"row": 37, "column": 66}}, {"id": 199, "type": "cast_expression", "text": "(double)numMuled", "parent": 198, "children": [200, 202], "start_point": {"row": 37, "column": 36}, "end_point": {"row": 37, "column": 52}}, {"id": 200, "type": "type_descriptor", "text": "double", "parent": 199, "children": [201], "start_point": {"row": 37, "column": 37}, "end_point": {"row": 37, "column": 43}}, {"id": 201, "type": "primitive_type", "text": "double", "parent": 200, "children": [], "start_point": {"row": 37, "column": 37}, "end_point": {"row": 37, "column": 43}}, {"id": 202, "type": "identifier", "text": "numMuled", "parent": 199, "children": [], "start_point": {"row": 37, "column": 44}, "end_point": {"row": 37, "column": 52}}, {"id": 203, "type": "/", "text": "/", "parent": 198, "children": [], "start_point": {"row": 37, "column": 52}, "end_point": {"row": 37, "column": 53}}, {"id": 204, "type": "parenthesized_expression", "text": "(time1-time0)", "parent": 198, "children": [205], "start_point": {"row": 37, "column": 53}, "end_point": {"row": 37, "column": 66}}, {"id": 205, "type": "binary_expression", "text": "time1-time0", "parent": 204, "children": [206, 207, 208], "start_point": {"row": 37, "column": 54}, "end_point": {"row": 37, "column": 65}}, {"id": 206, "type": "identifier", "text": "time1", "parent": 205, "children": [], "start_point": {"row": 37, "column": 54}, "end_point": {"row": 37, "column": 59}}, {"id": 207, "type": "-", "text": "-", "parent": 205, "children": [], "start_point": {"row": 37, "column": 59}, "end_point": {"row": 37, "column": 60}}, {"id": 208, "type": "identifier", "text": "time0", "parent": 205, "children": [], "start_point": {"row": 37, "column": 60}, "end_point": {"row": 37, "column": 65}}, {"id": 209, "type": "/", "text": "/", "parent": 197, "children": [], "start_point": {"row": 37, "column": 66}, "end_point": {"row": 37, "column": 67}}, {"id": 210, "type": "number_literal", "text": "1000000.", "parent": 197, "children": [], "start_point": {"row": 37, "column": 67}, "end_point": {"row": 37, "column": 75}}, {"id": 211, "type": "return_statement", "text": "return 0;", "parent": 58, "children": [212], "start_point": {"row": 39, "column": 1}, "end_point": {"row": 39, "column": 10}}, {"id": 212, "type": "number_literal", "text": "0", "parent": 211, "children": [], "start_point": {"row": 39, "column": 8}, "end_point": {"row": 39, "column": 9}}]}, "node_categories": {"declarations": {"functions": [21, 23, 58, 60], "variables": [16, 26, 29, 63, 66, 72, 76, 108, 156, 164], "classes": [], "imports": [0, 1, 3, 4, 6, 7, 9, 10], "modules": [], "enums": []}, "statements": {"expressions": [33, 36, 37, 38, 39, 40, 43, 47, 48, 53, 56, 79, 88, 91, 95, 99, 103, 113, 124, 127, 131, 143, 147, 153, 161, 171, 172, 173, 180, 185, 186, 192, 197, 198, 199, 204, 205], "assignments": [84, 98, 120, 134, 139, 150], "loops": [83, 119, 138], "conditionals": [14, 19, 20, 24, 28, 31, 34, 44, 49, 51, 57, 61, 65, 71, 74, 75, 78, 80, 82, 85, 89, 92, 96, 100, 101, 104, 111, 114, 121, 125, 128, 132, 135, 140, 144, 146, 148, 151, 154, 155, 159, 162, 165, 169, 175, 178, 182, 187, 193, 202, 206, 208], "returns": [32, 211], "exceptions": []}, "expressions": {"calls": [116], "literals": [2, 5, 8, 11, 87, 94, 106, 107, 123, 130, 137, 142, 189, 191, 195, 210, 212], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 21, "universal_type": "function", "name": "unknown", "text_snippet": "float Ranf(float min, float max) {\n\n\treturn min + (((float) rand() * (max-min))/ (float) (RAND_MAX))"}, {"node_id": 23, "universal_type": "function", "name": "unknown", "text_snippet": "Ranf(float min, float max)"}, {"node_id": 58, "universal_type": "function", "name": "main", "text_snippet": "int main( int argc, char *argv[ ] ) {\n\n\tint i,j;\n\tdouble prod;\n\tomp_set_num_threads( NUMT );\n\n\tfor ("}, {"node_id": 60, "universal_type": "function", "name": "argc,", "text_snippet": "main( int argc, char *argv[ ] )"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <omp.h>\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <stdio.h>\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include <math.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include<stdlib.h>\n"}, {"node_id": 10, "text": "#include"}]}, "original_source_code": "#include <omp.h>\n#include <stdio.h>\n#include <math.h>\n#include<stdlib.h>\n\n#define ArraySize 32678\nfloat Array[ArraySize];\n\nfloat Ranf(float min, float max) {\n\n\treturn min + (((float) rand() * (max-min))/ (float) (RAND_MAX));\n}\n\nint main( int argc, char *argv[ ] ) {\n\n\tint i,j;\n\tdouble prod;\n\tomp_set_num_threads( NUMT );\n\n\tfor (i=0; i< ArraySize-1 ;i++) {\n\n\t\tArray[i] = Ranf( -1.f, 1.f );\n\t}\n\tdouble time0= omp_get_wtime( );\n#pragma omp parallel for shared(Array) private(prod) schedule(TYPE,CHUNK)\t\n\tfor (i=0; i< ArraySize-1 ;i++) {\n\t\tprod=1.0;\n\t\tfor(j=0; j<=i ;j++) {\n\n\t\t\tprod*=Array[j];\n\t\t}\n\t\t\n\t}\t\n\tdouble time1=omp_get_wtime( );\n\n\t//printf(\"Execution time for = %lf\\n\",time1-time0);\n\tlong int numMuled = (long int)ArraySize * (long int)(ArraySize+1) / 2;\n\tprintf(\"MegaMults/sec = %10.2lf\\n\",(double)numMuled/(time1-time0)/1000000.);\n\n\treturn 0;\n}\n"}
80,549
c
/*************************************************************************/ #include <stdio.h> #include <string.h> #ifdef __is_libk # include <kernel/tty.h> #endif /*************************************************************************/ int puts(const char *string) { #ifdef __is_libk terminal_writestr(string); terminal_putchar('\n'); #else // TODO: Implement standard C version # error Need puts() implementation details. #endif return strlen(string) + 1; } /*************************************************************************/
22.4
25
(translation_unit) "/*************************************************************************/ \n \n#include <stdio.h> \n#include <string.h> \n \n#ifdef __is_libk \n# include <kernel/tty.h> \n#endif \n \n/*************************************************************************/ \n \nint puts(const char *string) \n{ \n#ifdef __is_libk \n terminal_writestr(string); \n terminal_putchar('\n'); \n#else \n // TODO: Implement standard C version \n# error Need puts() implementation details. \n#endif \n \n return strlen(string) + 1; \n} \n \n/*************************************************************************/" (comment) "/*************************************************************************/" (preproc_include) "#include <stdio.h> \n" (#include) "#include" (system_lib_string) "<stdio.h>" (preproc_include) "#include <string.h> \n" (#include) "#include" (system_lib_string) "<string.h>" (preproc_ifdef) "#ifdef __is_libk \n# include <kernel/tty.h> \n#endif" (#ifdef) "#ifdef" (identifier) "__is_libk" (preproc_include) "# include <kernel/tty.h> \n" (#include) "# include" (system_lib_string) "<kernel/tty.h>" (#endif) "#endif" (comment) "/*************************************************************************/" (function_definition) "int puts(const char *string) \n{ \n#ifdef __is_libk \n terminal_writestr(string); \n terminal_putchar('\n'); \n#else \n // TODO: Implement standard C version \n# error Need puts() implementation details. \n#endif \n \n return strlen(string) + 1; \n}" (primitive_type) "int" (function_declarator) "puts(const char *string)" (identifier) "puts" (parameter_list) "(const char *string)" (() "(" (parameter_declaration) "const char *string" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "*string" (*) "*" (identifier) "string" ()) ")" (compound_statement) "{ \n#ifdef __is_libk \n terminal_writestr(string); \n terminal_putchar('\n'); \n#else \n // TODO: Implement standard C version \n# error Need puts() implementation details. \n#endif \n \n return strlen(string) + 1; \n}" ({) "{" (preproc_ifdef) "#ifdef __is_libk \n terminal_writestr(string); \n terminal_putchar('\n'); \n#else \n // TODO: Implement standard C version \n# error Need puts() implementation details. \n#endif" (#ifdef) "#ifdef" (identifier) "__is_libk" (expression_statement) "terminal_writestr(string);" (call_expression) "terminal_writestr(string)" (identifier) "terminal_writestr" (argument_list) "(string)" (() "(" (identifier) "string" ()) ")" (;) ";" (expression_statement) "terminal_putchar('\n');" (call_expression) "terminal_putchar('\n')" (identifier) "terminal_putchar" (argument_list) "('\n')" (() "(" (char_literal) "'\n'" (') "'" (escape_sequence) "\n" (') "'" ()) ")" (;) ";" (preproc_else) "#else \n // TODO: Implement standard C version \n# error Need puts() implementation details. \n" (#else) "#else" (comment) "// TODO: Implement standard C version " (preproc_call) "# error Need puts() implementation details. \n" (preproc_directive) "# error" (preproc_arg) "Need puts() implementation details. " (#endif) "#endif" (return_statement) "return strlen(string) + 1;" (return) "return" (binary_expression) "strlen(string) + 1" (call_expression) "strlen(string)" (identifier) "strlen" (argument_list) "(string)" (() "(" (identifier) "string" ()) ")" (+) "+" (number_literal) "1" (;) ";" (}) "}" (comment) "/*************************************************************************/"
75
0
{"language": "c", "success": true, "metadata": {"lines": 25, "avg_line_length": 22.4, "nodes": 51, "errors": 0, "source_hash": "33d852434608296f7b5c51d27807c861ad5532baf2b3e4e619880c2339ef8932", "categorized_nodes": 35}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <stdio.h>\r\n", "parent": null, "children": [1, 2], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<stdio.h>", "parent": 0, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 18}}, {"id": 3, "type": "preproc_include", "text": "#include <string.h>\r\n", "parent": null, "children": [4, 5], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<string.h>", "parent": 3, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 19}}, {"id": 6, "type": "preproc_ifdef", "text": "#ifdef __is_libk\r\n# include <kernel/tty.h>\r\n#endif", "parent": null, "children": [7, 8, 9, 12], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 7, "column": 6}}, {"id": 7, "type": "#ifdef", "text": "#ifdef", "parent": 6, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 6}}, {"id": 8, "type": "identifier", "text": "__is_libk", "parent": 6, "children": [], "start_point": {"row": 5, "column": 7}, "end_point": {"row": 5, "column": 16}}, {"id": 9, "type": "preproc_include", "text": "# include <kernel/tty.h>\r\n", "parent": 6, "children": [10, 11], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 10, "type": "#include", "text": "# include", "parent": 9, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 9}}, {"id": 11, "type": "system_lib_string", "text": "<kernel/tty.h>", "parent": 9, "children": [], "start_point": {"row": 6, "column": 10}, "end_point": {"row": 6, "column": 24}}, {"id": 12, "type": "#endif", "text": "#endif", "parent": 6, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 6}}, {"id": 13, "type": "function_definition", "text": "int puts(const char *string)\r\n{\r\n#ifdef __is_libk\r\n terminal_writestr(string);\r\n terminal_putchar('\\n');\r\n#else\r\n // TODO: Implement standard C version\r\n# error Need puts() implementation details.\r\n#endif\r\n\r\n return strlen(string) + 1;\r\n}", "parent": null, "children": [14, 15], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 22, "column": 1}}, {"id": 14, "type": "primitive_type", "text": "int", "parent": 13, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 3}}, {"id": 15, "type": "function_declarator", "text": "puts(const char *string)", "parent": 13, "children": [16, 17], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 28}}, {"id": 16, "type": "identifier", "text": "puts", "parent": 15, "children": [], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 8}}, {"id": 17, "type": "parameter_list", "text": "(const char *string)", "parent": 15, "children": [18], "start_point": {"row": 11, "column": 8}, "end_point": {"row": 11, "column": 28}}, {"id": 18, "type": "parameter_declaration", "text": "const char *string", "parent": 17, "children": [19, 20], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 27}}, {"id": 19, "type": "primitive_type", "text": "char", "parent": 18, "children": [], "start_point": {"row": 11, "column": 15}, "end_point": {"row": 11, "column": 19}}, {"id": 20, "type": "pointer_declarator", "text": "*string", "parent": 18, "children": [21, 22], "start_point": {"row": 11, "column": 20}, "end_point": {"row": 11, "column": 27}}, {"id": 21, "type": "*", "text": "*", "parent": 20, "children": [], "start_point": {"row": 11, "column": 20}, "end_point": {"row": 11, "column": 21}}, {"id": 22, "type": "identifier", "text": "string", "parent": 20, "children": [], "start_point": {"row": 11, "column": 21}, "end_point": {"row": 11, "column": 27}}, {"id": 23, "type": "preproc_ifdef", "text": "#ifdef __is_libk\r\n terminal_writestr(string);\r\n terminal_putchar('\\n');\r\n#else\r\n // TODO: Implement standard C version\r\n# error Need puts() implementation details.\r\n#endif", "parent": 13, "children": [24, 25, 37, 42], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 19, "column": 6}}, {"id": 24, "type": "#ifdef", "text": "#ifdef", "parent": 23, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 6}}, {"id": 25, "type": "identifier", "text": "__is_libk", "parent": 23, "children": [], "start_point": {"row": 13, "column": 7}, "end_point": {"row": 13, "column": 16}}, {"id": 26, "type": "call_expression", "text": "terminal_writestr(string)", "parent": 23, "children": [27, 28], "start_point": {"row": 14, "column": 4}, "end_point": {"row": 14, "column": 29}}, {"id": 27, "type": "identifier", "text": "terminal_writestr", "parent": 26, "children": [], "start_point": {"row": 14, "column": 4}, "end_point": {"row": 14, "column": 21}}, {"id": 28, "type": "argument_list", "text": "(string)", "parent": 26, "children": [29], "start_point": {"row": 14, "column": 21}, "end_point": {"row": 14, "column": 29}}, {"id": 29, "type": "identifier", "text": "string", "parent": 28, "children": [], "start_point": {"row": 14, "column": 22}, "end_point": {"row": 14, "column": 28}}, {"id": 30, "type": "call_expression", "text": "terminal_putchar('\\n')", "parent": 23, "children": [31, 32], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 26}}, {"id": 31, "type": "identifier", "text": "terminal_putchar", "parent": 30, "children": [], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 20}}, {"id": 32, "type": "argument_list", "text": "('\\n')", "parent": 30, "children": [33], "start_point": {"row": 15, "column": 20}, "end_point": {"row": 15, "column": 26}}, {"id": 33, "type": "char_literal", "text": "'\\n'", "parent": 32, "children": [34, 35, 36], "start_point": {"row": 15, "column": 21}, "end_point": {"row": 15, "column": 25}}, {"id": 34, "type": "'", "text": "'", "parent": 33, "children": [], "start_point": {"row": 15, "column": 21}, "end_point": {"row": 15, "column": 22}}, {"id": 35, "type": "escape_sequence", "text": "\\n", "parent": 33, "children": [], "start_point": {"row": 15, "column": 22}, "end_point": {"row": 15, "column": 24}}, {"id": 36, "type": "'", "text": "'", "parent": 33, "children": [], "start_point": {"row": 15, "column": 24}, "end_point": {"row": 15, "column": 25}}, {"id": 37, "type": "preproc_else", "text": "#else\r\n // TODO: Implement standard C version\r\n# error Need puts() implementation details.\r\n", "parent": 23, "children": [38, 39], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 19, "column": 0}}, {"id": 38, "type": "#else", "text": "#else", "parent": 37, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 5}}, {"id": 39, "type": "preproc_call", "text": "# error Need puts() implementation details.\r\n", "parent": 37, "children": [40, 41], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 19, "column": 0}}, {"id": 40, "type": "preproc_directive", "text": "# error", "parent": 39, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 7}}, {"id": 41, "type": "preproc_arg", "text": "Need puts() implementation details.\r", "parent": 39, "children": [], "start_point": {"row": 18, "column": 8}, "end_point": {"row": 18, "column": 44}}, {"id": 42, "type": "#endif", "text": "#endif", "parent": 23, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 6}}, {"id": 43, "type": "return_statement", "text": "return strlen(string) + 1;", "parent": 13, "children": [44], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 21, "column": 30}}, {"id": 44, "type": "binary_expression", "text": "strlen(string) + 1", "parent": 43, "children": [45, 49, 50], "start_point": {"row": 21, "column": 11}, "end_point": {"row": 21, "column": 29}}, {"id": 45, "type": "call_expression", "text": "strlen(string)", "parent": 44, "children": [46, 47], "start_point": {"row": 21, "column": 11}, "end_point": {"row": 21, "column": 25}}, {"id": 46, "type": "identifier", "text": "strlen", "parent": 45, "children": [], "start_point": {"row": 21, "column": 11}, "end_point": {"row": 21, "column": 17}}, {"id": 47, "type": "argument_list", "text": "(string)", "parent": 45, "children": [48], "start_point": {"row": 21, "column": 17}, "end_point": {"row": 21, "column": 25}}, {"id": 48, "type": "identifier", "text": "string", "parent": 47, "children": [], "start_point": {"row": 21, "column": 18}, "end_point": {"row": 21, "column": 24}}, {"id": 49, "type": "+", "text": "+", "parent": 44, "children": [], "start_point": {"row": 21, "column": 26}, "end_point": {"row": 21, "column": 27}}, {"id": 50, "type": "number_literal", "text": "1", "parent": 44, "children": [], "start_point": {"row": 21, "column": 28}, "end_point": {"row": 21, "column": 29}}]}, "node_categories": {"declarations": {"functions": [13, 15], "variables": [18], "classes": [], "imports": [0, 1, 3, 4, 9, 10], "modules": [], "enums": []}, "statements": {"expressions": [26, 30, 44, 45], "assignments": [], "loops": [], "conditionals": [6, 7, 8, 12, 16, 22, 23, 24, 25, 27, 29, 31, 42, 46, 48], "returns": [43], "exceptions": []}, "expressions": {"calls": [39], "literals": [2, 5, 11, 33, 50], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 13, "universal_type": "function", "name": "puts", "text_snippet": "int puts(const char *string)\r\n{\r\n#ifdef __is_libk\r\n terminal_writestr(string);\r\n terminal_putc"}, {"node_id": 15, "universal_type": "function", "name": "unknown", "text_snippet": "puts(const char *string)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <stdio.h>\r\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <string.h>\r\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 9, "text": "# include <kernel/tty.h>\r\n"}, {"node_id": 10, "text": "# include"}]}, "original_source_code": "/*************************************************************************/\r\n\r\n#include <stdio.h>\r\n#include <string.h>\r\n\r\n#ifdef __is_libk\r\n# include <kernel/tty.h>\r\n#endif\r\n\r\n/*************************************************************************/\r\n\r\nint puts(const char *string)\r\n{\r\n#ifdef __is_libk\r\n terminal_writestr(string);\r\n terminal_putchar('\\n');\r\n#else\r\n // TODO: Implement standard C version\r\n# error Need puts() implementation details.\r\n#endif\r\n\r\n return strlen(string) + 1;\r\n}\r\n\r\n/*************************************************************************/"}
80,550
c
// // UITableView+Category.h // powerlife // // Created by 陈行 on 16/6/3. // Copyright © 2016年 陈行. All rights reserved. // #import <UIKit/UIKit.h> @interface UITableView (Category) - (id)tableViewCellByNibWithIdentifier:(NSString *)identifier; - (id)tableViewCellByClassWithIdentifier:(NSString *)identifier; - (id)tableViewHeaderViewByNibWithIdentifier:(NSString *)identifier; @end
28.69
13
(translation_unit) "//\n// UITableView+Category.h\n// powerlife\n//\n// Created by 陈行 on 16/6/3.\n// Copyright © 2016年 陈行. All rights reserved.\n//\n\n#import <UIKit/UIKit.h>\n\n@interface UITableView (Category)\n\n- (id)tableViewCellByNibWithIdentifier:(NSString *)identifier;\n\n- (id)tableViewCellByClassWithIdentifier:(NSString *)identifier;\n\n- (id)tableViewHeaderViewByNibWithIdentifier:(NSString *)identifier;\n\n@end\n" (comment) "//" (comment) "// UITableView+Category.h" (comment) "// powerlife" (comment) "//" (comment) "// Created by 陈行 on 16/6/3.\n// " (comment) "Copyright © 2016年 陈行. All rights reserved.\n//\n\n#impor" (comment) " <" (preproc_call) "Kit/UIKit.h>\n\n@interface" (preproc_directive) "Kit/UIK" (preproc_arg) "t.h>\n\n@interfac" (ERROR) "UITableView (Category)\n\n- (id)tableViewCellByNibWithIdentifier:(NSString *)identifier;\n\n- (id)ta" (ERROR) "U" (type_identifier) "ITableVie" (function_declarator) " (Category)\n\n- (id)tab" (identifier) " (Category)" (parameter_list) "\n- (id)tab" (() "\n" (identifier) "- (id)ta" ()) "b" (unary_expression) "ViewCellByNibWithIdentifier:(NSString " (-) "V" (cast_expression) "ewCellByNibWithIdentifier:(NSString " (() "e" (type_descriptor) "wC" (type_identifier) "wC" ()) "e" (identifier) "llByNibWithIdentifier:(NSString " (:) "*" (() ")" (binary_expression) "identifier;\n\n- (id)ta" (identifier) "identifi" (*) "r" (ERROR) ";" ()) ";" (identifier) "\n\n- (id)ta" (expression_statement) "b" (;) "b" (ERROR) "ViewCellByClassWithIdentifier:(NSString *)identifier;\n\n- (id)tableViewHeaderViewByNibWithIdentifier:(NSString *)identifier;\n\n@end\n" (binary_expression) "ViewCellByClassWithIdentifier:(NSString *)identifier;\n\n- (id)tableViewHeaderViewByNibWithIdentifier:(NSString *)identifier;\n\n@end\n" (binary_expression) "ViewCellByClassWithIdentifier:(NSString *)identifier;\n\n- (id)tableViewHeaderViewByNibWithIdentifier:(NSString " (binary_expression) "ViewCellByClassWithIdentifier:(NSString *)identifier;\n\n- (id)ta" (unary_expression) "ViewCellByClassWithIdentifier:(NSString " (-) "V" (cast_expression) "ewCellByClassWithIdentifier:(NSString " (() "e" (type_descriptor) "wC" (type_identifier) "wC" ()) "e" (identifier) "llByClassWithIdentifier:(NSString " (ERROR) "*)identifi" (:) "*" (() ")" (identifier) "identifi" (*) "r" (ERROR) ";" ()) ";" (identifier) "\n\n- (id)ta" (ERROR) "b" (;) "b" (-) "V" (cast_expression) "ewHeaderViewByNibWithIdentifier:(NSString " (() "e" (type_descriptor) "wH" (type_identifier) "wH" ()) "e" (identifier) "aderViewByNibWithIdentifier:(NSString " (ERROR) "*)identifi" (:) "*" (() ")" (identifier) "identifi" (*) "r" (ERROR) ";" ()) ";" (identifier) "\n\n@end\n" (;) "" (ERROR) "" (identifier) ""
78
10
{"language": "c", "success": true, "metadata": {"lines": 13, "avg_line_length": 28.69, "nodes": 46, "errors": 0, "source_hash": "d55a9a3953f55f3cc5c9e7f457175f801b9b30064ce38fcd71870a2a8f6e8ff8", "categorized_nodes": 27}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "Kit/UIKit.h>\n\n@interface", "parent": null, "children": [1, 2], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "Kit/UIK", "parent": 0, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "t.h>\n\n@interfac", "parent": 0, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 23}}, {"id": 3, "type": "ERROR", "text": "UITableView (Category)\n\n- (id)tableViewCellByNibWithIdentifier:(NSString *)identifier;\n\n- (id)ta", "parent": null, "children": [4, 5, 6, 10, 16], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 12, "column": 61}}, {"id": 4, "type": "ERROR", "text": "U", "parent": 3, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 1}}, {"id": 5, "type": "type_identifier", "text": "ITableVie", "parent": 3, "children": [], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 10}}, {"id": 6, "type": "function_declarator", "text": " (Category)\n\n- (id)tab", "parent": 3, "children": [7, 8], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 10, "column": 33}}, {"id": 7, "type": "identifier", "text": " (Category)", "parent": 6, "children": [], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 10, "column": 22}}, {"id": 8, "type": "parameter_list", "text": "\n- (id)tab", "parent": 6, "children": [9], "start_point": {"row": 10, "column": 23}, "end_point": {"row": 10, "column": 33}}, {"id": 9, "type": "identifier", "text": "- (id)ta", "parent": 8, "children": [], "start_point": {"row": 10, "column": 24}, "end_point": {"row": 10, "column": 32}}, {"id": 10, "type": "unary_expression", "text": "ViewCellByNibWithIdentifier:(NSString ", "parent": 3, "children": [11, 12], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 38}}, {"id": 11, "type": "-", "text": "V", "parent": 10, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 1}}, {"id": 12, "type": "cast_expression", "text": "ewCellByNibWithIdentifier:(NSString ", "parent": 10, "children": [13, 15], "start_point": {"row": 12, "column": 2}, "end_point": {"row": 12, "column": 38}}, {"id": 13, "type": "type_descriptor", "text": "wC", "parent": 12, "children": [14], "start_point": {"row": 12, "column": 3}, "end_point": {"row": 12, "column": 5}}, {"id": 14, "type": "type_identifier", "text": "wC", "parent": 13, "children": [], "start_point": {"row": 12, "column": 3}, "end_point": {"row": 12, "column": 5}}, {"id": 15, "type": "identifier", "text": "llByNibWithIdentifier:(NSString ", "parent": 12, "children": [], "start_point": {"row": 12, "column": 6}, "end_point": {"row": 12, "column": 38}}, {"id": 16, "type": "binary_expression", "text": "identifier;\n\n- (id)ta", "parent": 3, "children": [17, 18, 19], "start_point": {"row": 12, "column": 40}, "end_point": {"row": 12, "column": 61}}, {"id": 17, "type": "identifier", "text": "identifi", "parent": 16, "children": [], "start_point": {"row": 12, "column": 40}, "end_point": {"row": 12, "column": 48}}, {"id": 18, "type": "*", "text": "r", "parent": 16, "children": [], "start_point": {"row": 12, "column": 49}, "end_point": {"row": 12, "column": 50}}, {"id": 19, "type": "identifier", "text": "\n\n- (id)ta", "parent": 16, "children": [], "start_point": {"row": 12, "column": 51}, "end_point": {"row": 12, "column": 61}}, {"id": 20, "type": "ERROR", "text": "ViewCellByClassWithIdentifier:(NSString *)identifier;\n\n- (id)tableViewHeaderViewByNibWithIdentifier:(NSString *)identifier;\n\n@end\n", "parent": null, "children": [21, 44, 45], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 18, "column": 4}}, {"id": 21, "type": "binary_expression", "text": "ViewCellByClassWithIdentifier:(NSString *)identifier;\n\n- (id)tableViewHeaderViewByNibWithIdentifier:(NSString *)identifier;\n\n@end\n", "parent": 20, "children": [22, 40, 42, 43], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 16, "column": 67}}, {"id": 22, "type": "binary_expression", "text": "ViewCellByClassWithIdentifier:(NSString *)identifier;\n\n- (id)tableViewHeaderViewByNibWithIdentifier:(NSString ", "parent": 21, "children": [23, 34, 35, 36], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 16, "column": 44}}, {"id": 23, "type": "binary_expression", "text": "ViewCellByClassWithIdentifier:(NSString *)identifier;\n\n- (id)ta", "parent": 22, "children": [24, 30, 32, 33], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 63}}, {"id": 24, "type": "unary_expression", "text": "ViewCellByClassWithIdentifier:(NSString ", "parent": 23, "children": [25, 26], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 40}}, {"id": 25, "type": "-", "text": "V", "parent": 24, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 1}}, {"id": 26, "type": "cast_expression", "text": "ewCellByClassWithIdentifier:(NSString ", "parent": 24, "children": [27, 29], "start_point": {"row": 14, "column": 2}, "end_point": {"row": 14, "column": 40}}, {"id": 27, "type": "type_descriptor", "text": "wC", "parent": 26, "children": [28], "start_point": {"row": 14, "column": 3}, "end_point": {"row": 14, "column": 5}}, {"id": 28, "type": "type_identifier", "text": "wC", "parent": 27, "children": [], "start_point": {"row": 14, "column": 3}, "end_point": {"row": 14, "column": 5}}, {"id": 29, "type": "identifier", "text": "llByClassWithIdentifier:(NSString ", "parent": 26, "children": [], "start_point": {"row": 14, "column": 6}, "end_point": {"row": 14, "column": 40}}, {"id": 30, "type": "ERROR", "text": "*)identifi", "parent": 23, "children": [31], "start_point": {"row": 14, "column": 40}, "end_point": {"row": 14, "column": 50}}, {"id": 31, "type": "identifier", "text": "identifi", "parent": 30, "children": [], "start_point": {"row": 14, "column": 42}, "end_point": {"row": 14, "column": 50}}, {"id": 32, "type": "*", "text": "r", "parent": 23, "children": [], "start_point": {"row": 14, "column": 51}, "end_point": {"row": 14, "column": 52}}, {"id": 33, "type": "identifier", "text": "\n\n- (id)ta", "parent": 23, "children": [], "start_point": {"row": 14, "column": 53}, "end_point": {"row": 14, "column": 63}}, {"id": 34, "type": "ERROR", "text": "b", "parent": 22, "children": [], "start_point": {"row": 14, "column": 63}, "end_point": {"row": 14, "column": 64}}, {"id": 35, "type": "-", "text": "V", "parent": 22, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 1}}, {"id": 36, "type": "cast_expression", "text": "ewHeaderViewByNibWithIdentifier:(NSString ", "parent": 22, "children": [37, 39], "start_point": {"row": 16, "column": 2}, "end_point": {"row": 16, "column": 44}}, {"id": 37, "type": "type_descriptor", "text": "wH", "parent": 36, "children": [38], "start_point": {"row": 16, "column": 3}, "end_point": {"row": 16, "column": 5}}, {"id": 38, "type": "type_identifier", "text": "wH", "parent": 37, "children": [], "start_point": {"row": 16, "column": 3}, "end_point": {"row": 16, "column": 5}}, {"id": 39, "type": "identifier", "text": "aderViewByNibWithIdentifier:(NSString ", "parent": 36, "children": [], "start_point": {"row": 16, "column": 6}, "end_point": {"row": 16, "column": 44}}, {"id": 40, "type": "ERROR", "text": "*)identifi", "parent": 21, "children": [41], "start_point": {"row": 16, "column": 44}, "end_point": {"row": 16, "column": 54}}, {"id": 41, "type": "identifier", "text": "identifi", "parent": 40, "children": [], "start_point": {"row": 16, "column": 46}, "end_point": {"row": 16, "column": 54}}, {"id": 42, "type": "*", "text": "r", "parent": 21, "children": [], "start_point": {"row": 16, "column": 55}, "end_point": {"row": 16, "column": 56}}, {"id": 43, "type": "identifier", "text": "\n\n@end\n", "parent": 21, "children": [], "start_point": {"row": 16, "column": 57}, "end_point": {"row": 16, "column": 67}}, {"id": 44, "type": "ERROR", "text": "", "parent": 20, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 1}}, {"id": 45, "type": "identifier", "text": "", "parent": 20, "children": [], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 4}}]}, "node_categories": {"declarations": {"functions": [6], "variables": [], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [10, 12, 16, 21, 22, 23, 24, 26, 36], "assignments": [], "loops": [], "conditionals": [5, 7, 9, 14, 15, 17, 19, 28, 29, 31, 33, 38, 39, 41, 43, 45], "returns": [], "exceptions": []}, "expressions": {"calls": [0], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 6, "universal_type": "function", "name": "unknown", "text_snippet": " (Category)\n\n- (id)tab"}], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// UITableView+Category.h\n// powerlife\n//\n// Created by \u9648\u884c on 16/6/3.\n// Copyright \u00a9 2016\u5e74 \u9648\u884c. All rights reserved.\n//\n\n#import <UIKit/UIKit.h>\n\n@interface UITableView (Category)\n\n- (id)tableViewCellByNibWithIdentifier:(NSString *)identifier;\n\n- (id)tableViewCellByClassWithIdentifier:(NSString *)identifier;\n\n- (id)tableViewHeaderViewByNibWithIdentifier:(NSString *)identifier;\n\n@end\n"}
80,551
c
#include <ctype.h> #include <fenv.h> #include <float.h> #include <math.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #define EPS 1e-5 float compute_function(float a, float b, float c, float x) { return a * powf(x, 2) * sinf(x) + b * x * cosf(x) + c; } float solve_equation(float a, float b, float c, float n) { float left, right, mid, lval, rval, mval; left = -n; right = n; lval = compute_function(a, b, c, left); rval = compute_function(a, b, c, right); while (signbit(lval * rval)) { mid = (left + right) / 2; mval = compute_function(a, b, c, mid); if (fabsf(mval) < EPS) { return mid; } if (signbit(mval * lval)) { right = mid; } else if (signbit(mval * rval)) { left = mid; } } return 0; } int main() { float a, b, c, n, x; int res; res = scanf("%f %f %f %f", &a, &b, &c, &n); if (res != 4) { exit(EXIT_FAILURE); } x = solve_equation(a, b, c, n); if (!x) { printf("0.0\n"); } else { printf("%.5f", x); } }
21.78
45
(translation_unit) "#include <ctype.h>\n#include <fenv.h>\n#include <float.h>\n#include <math.h>\n#include <stdio.h>\n#include <stdlib.h>\n#include <string.h>\n\n#define EPS 1e-5\n\nfloat compute_function(float a, float b, float c, float x) {\n return a * powf(x, 2) * sinf(x) + b * x * cosf(x) + c;\n}\n\nfloat solve_equation(float a, float b, float c, float n) {\n float left, right, mid, lval, rval, mval;\n\n left = -n;\n right = n;\n\n lval = compute_function(a, b, c, left);\n rval = compute_function(a, b, c, right);\n\n while (signbit(lval * rval)) {\n mid = (left + right) / 2;\n mval = compute_function(a, b, c, mid);\n\n if (fabsf(mval) < EPS) {\n return mid;\n }\n\n if (signbit(mval * lval)) {\n right = mid;\n } else if (signbit(mval * rval)) {\n left = mid;\n }\n }\n\n return 0;\n}\n\nint main() {\n float a, b, c, n, x;\n int res;\n\n res = scanf("%f %f %f %f", &a, &b, &c, &n);\n\n if (res != 4) {\n exit(EXIT_FAILURE);\n }\n\n x = solve_equation(a, b, c, n);\n if (!x) {\n printf("0.0\n");\n } else {\n printf("%.5f", x);\n }\n}\n" (preproc_include) "#include <ctype.h>\n" (#include) "#include" (system_lib_string) "<ctype.h>" (preproc_include) "#include <fenv.h>\n" (#include) "#include" (system_lib_string) "<fenv.h>" (preproc_include) "#include <float.h>\n" (#include) "#include" (system_lib_string) "<float.h>" (preproc_include) "#include <math.h>\n" (#include) "#include" (system_lib_string) "<math.h>" (preproc_include) "#include <stdio.h>\n" (#include) "#include" (system_lib_string) "<stdio.h>" (preproc_include) "#include <stdlib.h>\n" (#include) "#include" (system_lib_string) "<stdlib.h>" (preproc_include) "#include <string.h>\n" (#include) "#include" (system_lib_string) "<string.h>" (preproc_def) "#define EPS 1e-5\n" (#define) "#define" (identifier) "EPS" (preproc_arg) "1e-5" (function_definition) "float compute_function(float a, float b, float c, float x) {\n return a * powf(x, 2) * sinf(x) + b * x * cosf(x) + c;\n}" (primitive_type) "float" (function_declarator) "compute_function(float a, float b, float c, float x)" (identifier) "compute_function" (parameter_list) "(float a, float b, float c, float x)" (() "(" (parameter_declaration) "float a" (primitive_type) "float" (identifier) "a" (,) "," (parameter_declaration) "float b" (primitive_type) "float" (identifier) "b" (,) "," (parameter_declaration) "float c" (primitive_type) "float" (identifier) "c" (,) "," (parameter_declaration) "float x" (primitive_type) "float" (identifier) "x" ()) ")" (compound_statement) "{\n return a * powf(x, 2) * sinf(x) + b * x * cosf(x) + c;\n}" ({) "{" (return_statement) "return a * powf(x, 2) * sinf(x) + b * x * cosf(x) + c;" (return) "return" (binary_expression) "a * powf(x, 2) * sinf(x) + b * x * cosf(x) + c" (binary_expression) "a * powf(x, 2) * sinf(x) + b * x * cosf(x)" (binary_expression) "a * powf(x, 2) * sinf(x)" (binary_expression) "a * powf(x, 2)" (identifier) "a" (*) "*" (call_expression) "powf(x, 2)" (identifier) "powf" (argument_list) "(x, 2)" (() "(" (identifier) "x" (,) "," (number_literal) "2" ()) ")" (*) "*" (call_expression) "sinf(x)" (identifier) "sinf" (argument_list) "(x)" (() "(" (identifier) "x" ()) ")" (+) "+" (binary_expression) "b * x * cosf(x)" (binary_expression) "b * x" (identifier) "b" (*) "*" (identifier) "x" (*) "*" (call_expression) "cosf(x)" (identifier) "cosf" (argument_list) "(x)" (() "(" (identifier) "x" ()) ")" (+) "+" (identifier) "c" (;) ";" (}) "}" (function_definition) "float solve_equation(float a, float b, float c, float n) {\n float left, right, mid, lval, rval, mval;\n\n left = -n;\n right = n;\n\n lval = compute_function(a, b, c, left);\n rval = compute_function(a, b, c, right);\n\n while (signbit(lval * rval)) {\n mid = (left + right) / 2;\n mval = compute_function(a, b, c, mid);\n\n if (fabsf(mval) < EPS) {\n return mid;\n }\n\n if (signbit(mval * lval)) {\n right = mid;\n } else if (signbit(mval * rval)) {\n left = mid;\n }\n }\n\n return 0;\n}" (primitive_type) "float" (function_declarator) "solve_equation(float a, float b, float c, float n)" (identifier) "solve_equation" (parameter_list) "(float a, float b, float c, float n)" (() "(" (parameter_declaration) "float a" (primitive_type) "float" (identifier) "a" (,) "," (parameter_declaration) "float b" (primitive_type) "float" (identifier) "b" (,) "," (parameter_declaration) "float c" (primitive_type) "float" (identifier) "c" (,) "," (parameter_declaration) "float n" (primitive_type) "float" (identifier) "n" ()) ")" (compound_statement) "{\n float left, right, mid, lval, rval, mval;\n\n left = -n;\n right = n;\n\n lval = compute_function(a, b, c, left);\n rval = compute_function(a, b, c, right);\n\n while (signbit(lval * rval)) {\n mid = (left + right) / 2;\n mval = compute_function(a, b, c, mid);\n\n if (fabsf(mval) < EPS) {\n return mid;\n }\n\n if (signbit(mval * lval)) {\n right = mid;\n } else if (signbit(mval * rval)) {\n left = mid;\n }\n }\n\n return 0;\n}" ({) "{" (declaration) "float left, right, mid, lval, rval, mval;" (primitive_type) "float" (identifier) "left" (,) "," (identifier) "right" (,) "," (identifier) "mid" (,) "," (identifier) "lval" (,) "," (identifier) "rval" (,) "," (identifier) "mval" (;) ";" (expression_statement) "left = -n;" (assignment_expression) "left = -n" (identifier) "left" (=) "=" (unary_expression) "-n" (-) "-" (identifier) "n" (;) ";" (expression_statement) "right = n;" (assignment_expression) "right = n" (identifier) "right" (=) "=" (identifier) "n" (;) ";" (expression_statement) "lval = compute_function(a, b, c, left);" (assignment_expression) "lval = compute_function(a, b, c, left)" (identifier) "lval" (=) "=" (call_expression) "compute_function(a, b, c, left)" (identifier) "compute_function" (argument_list) "(a, b, c, left)" (() "(" (identifier) "a" (,) "," (identifier) "b" (,) "," (identifier) "c" (,) "," (identifier) "left" ()) ")" (;) ";" (expression_statement) "rval = compute_function(a, b, c, right);" (assignment_expression) "rval = compute_function(a, b, c, right)" (identifier) "rval" (=) "=" (call_expression) "compute_function(a, b, c, right)" (identifier) "compute_function" (argument_list) "(a, b, c, right)" (() "(" (identifier) "a" (,) "," (identifier) "b" (,) "," (identifier) "c" (,) "," (identifier) "right" ()) ")" (;) ";" (while_statement) "while (signbit(lval * rval)) {\n mid = (left + right) / 2;\n mval = compute_function(a, b, c, mid);\n\n if (fabsf(mval) < EPS) {\n return mid;\n }\n\n if (signbit(mval * lval)) {\n right = mid;\n } else if (signbit(mval * rval)) {\n left = mid;\n }\n }" (while) "while" (parenthesized_expression) "(signbit(lval * rval))" (() "(" (call_expression) "signbit(lval * rval)" (identifier) "signbit" (argument_list) "(lval * rval)" (() "(" (binary_expression) "lval * rval" (identifier) "lval" (*) "*" (identifier) "rval" ()) ")" ()) ")" (compound_statement) "{\n mid = (left + right) / 2;\n mval = compute_function(a, b, c, mid);\n\n if (fabsf(mval) < EPS) {\n return mid;\n }\n\n if (signbit(mval * lval)) {\n right = mid;\n } else if (signbit(mval * rval)) {\n left = mid;\n }\n }" ({) "{" (expression_statement) "mid = (left + right) / 2;" (assignment_expression) "mid = (left + right) / 2" (identifier) "mid" (=) "=" (binary_expression) "(left + right) / 2" (parenthesized_expression) "(left + right)" (() "(" (binary_expression) "left + right" (identifier) "left" (+) "+" (identifier) "right" ()) ")" (/) "/" (number_literal) "2" (;) ";" (expression_statement) "mval = compute_function(a, b, c, mid);" (assignment_expression) "mval = compute_function(a, b, c, mid)" (identifier) "mval" (=) "=" (call_expression) "compute_function(a, b, c, mid)" (identifier) "compute_function" (argument_list) "(a, b, c, mid)" (() "(" (identifier) "a" (,) "," (identifier) "b" (,) "," (identifier) "c" (,) "," (identifier) "mid" ()) ")" (;) ";" (if_statement) "if (fabsf(mval) < EPS) {\n return mid;\n }" (if) "if" (parenthesized_expression) "(fabsf(mval) < EPS)" (() "(" (binary_expression) "fabsf(mval) < EPS" (call_expression) "fabsf(mval)" (identifier) "fabsf" (argument_list) "(mval)" (() "(" (identifier) "mval" ()) ")" (<) "<" (identifier) "EPS" ()) ")" (compound_statement) "{\n return mid;\n }" ({) "{" (return_statement) "return mid;" (return) "return" (identifier) "mid" (;) ";" (}) "}" (if_statement) "if (signbit(mval * lval)) {\n right = mid;\n } else if (signbit(mval * rval)) {\n left = mid;\n }" (if) "if" (parenthesized_expression) "(signbit(mval * lval))" (() "(" (call_expression) "signbit(mval * lval)" (identifier) "signbit" (argument_list) "(mval * lval)" (() "(" (binary_expression) "mval * lval" (identifier) "mval" (*) "*" (identifier) "lval" ()) ")" ()) ")" (compound_statement) "{\n right = mid;\n }" ({) "{" (expression_statement) "right = mid;" (assignment_expression) "right = mid" (identifier) "right" (=) "=" (identifier) "mid" (;) ";" (}) "}" (else_clause) "else if (signbit(mval * rval)) {\n left = mid;\n }" (else) "else" (if_statement) "if (signbit(mval * rval)) {\n left = mid;\n }" (if) "if" (parenthesized_expression) "(signbit(mval * rval))" (() "(" (call_expression) "signbit(mval * rval)" (identifier) "signbit" (argument_list) "(mval * rval)" (() "(" (binary_expression) "mval * rval" (identifier) "mval" (*) "*" (identifier) "rval" ()) ")" ()) ")" (compound_statement) "{\n left = mid;\n }" ({) "{" (expression_statement) "left = mid;" (assignment_expression) "left = mid" (identifier) "left" (=) "=" (identifier) "mid" (;) ";" (}) "}" (}) "}" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (function_definition) "int main() {\n float a, b, c, n, x;\n int res;\n\n res = scanf("%f %f %f %f", &a, &b, &c, &n);\n\n if (res != 4) {\n exit(EXIT_FAILURE);\n }\n\n x = solve_equation(a, b, c, n);\n if (!x) {\n printf("0.0\n");\n } else {\n printf("%.5f", x);\n }\n}" (primitive_type) "int" (function_declarator) "main()" (identifier) "main" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n float a, b, c, n, x;\n int res;\n\n res = scanf("%f %f %f %f", &a, &b, &c, &n);\n\n if (res != 4) {\n exit(EXIT_FAILURE);\n }\n\n x = solve_equation(a, b, c, n);\n if (!x) {\n printf("0.0\n");\n } else {\n printf("%.5f", x);\n }\n}" ({) "{" (declaration) "float a, b, c, n, x;" (primitive_type) "float" (identifier) "a" (,) "," (identifier) "b" (,) "," (identifier) "c" (,) "," (identifier) "n" (,) "," (identifier) "x" (;) ";" (declaration) "int res;" (primitive_type) "int" (identifier) "res" (;) ";" (expression_statement) "res = scanf("%f %f %f %f", &a, &b, &c, &n);" (assignment_expression) "res = scanf("%f %f %f %f", &a, &b, &c, &n)" (identifier) "res" (=) "=" (call_expression) "scanf("%f %f %f %f", &a, &b, &c, &n)" (identifier) "scanf" (argument_list) "("%f %f %f %f", &a, &b, &c, &n)" (() "(" (string_literal) ""%f %f %f %f"" (") """ (string_content) "%f %f %f %f" (") """ (,) "," (pointer_expression) "&a" (&) "&" (identifier) "a" (,) "," (pointer_expression) "&b" (&) "&" (identifier) "b" (,) "," (pointer_expression) "&c" (&) "&" (identifier) "c" (,) "," (pointer_expression) "&n" (&) "&" (identifier) "n" ()) ")" (;) ";" (if_statement) "if (res != 4) {\n exit(EXIT_FAILURE);\n }" (if) "if" (parenthesized_expression) "(res != 4)" (() "(" (binary_expression) "res != 4" (identifier) "res" (!=) "!=" (number_literal) "4" ()) ")" (compound_statement) "{\n exit(EXIT_FAILURE);\n }" ({) "{" (expression_statement) "exit(EXIT_FAILURE);" (call_expression) "exit(EXIT_FAILURE)" (identifier) "exit" (argument_list) "(EXIT_FAILURE)" (() "(" (identifier) "EXIT_FAILURE" ()) ")" (;) ";" (}) "}" (expression_statement) "x = solve_equation(a, b, c, n);" (assignment_expression) "x = solve_equation(a, b, c, n)" (identifier) "x" (=) "=" (call_expression) "solve_equation(a, b, c, n)" (identifier) "solve_equation" (argument_list) "(a, b, c, n)" (() "(" (identifier) "a" (,) "," (identifier) "b" (,) "," (identifier) "c" (,) "," (identifier) "n" ()) ")" (;) ";" (if_statement) "if (!x) {\n printf("0.0\n");\n } else {\n printf("%.5f", x);\n }" (if) "if" (parenthesized_expression) "(!x)" (() "(" (unary_expression) "!x" (!) "!" (identifier) "x" ()) ")" (compound_statement) "{\n printf("0.0\n");\n }" ({) "{" (expression_statement) "printf("0.0\n");" (call_expression) "printf("0.0\n")" (identifier) "printf" (argument_list) "("0.0\n")" (() "(" (string_literal) ""0.0\n"" (") """ (string_content) "0.0" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (}) "}" (else_clause) "else {\n printf("%.5f", x);\n }" (else) "else" (compound_statement) "{\n printf("%.5f", x);\n }" ({) "{" (expression_statement) "printf("%.5f", x);" (call_expression) "printf("%.5f", x)" (identifier) "printf" (argument_list) "("%.5f", x)" (() "(" (string_literal) ""%.5f"" (") """ (string_content) "%.5f" (") """ (,) "," (identifier) "x" ()) ")" (;) ";" (}) "}" (}) "}"
433
0
{"language": "c", "success": true, "metadata": {"lines": 45, "avg_line_length": 21.78, "nodes": 263, "errors": 0, "source_hash": "c3a6d99f6965cb631c393f387c55b3cefed8fa0d9ba87bb3193cd85384b5d2d5", "categorized_nodes": 200}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <ctype.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<ctype.h>", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 18}}, {"id": 3, "type": "preproc_include", "text": "#include <fenv.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<fenv.h>", "parent": 3, "children": [], "start_point": {"row": 1, "column": 9}, "end_point": {"row": 1, "column": 17}}, {"id": 6, "type": "preproc_include", "text": "#include <float.h>\n", "parent": null, "children": [7, 8], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<float.h>", "parent": 6, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 18}}, {"id": 9, "type": "preproc_include", "text": "#include <math.h>\n", "parent": null, "children": [10, 11], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<math.h>", "parent": 9, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 17}}, {"id": 12, "type": "preproc_include", "text": "#include <stdio.h>\n", "parent": null, "children": [13, 14], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 14, "type": "system_lib_string", "text": "<stdio.h>", "parent": 12, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 18}}, {"id": 15, "type": "preproc_include", "text": "#include <stdlib.h>\n", "parent": null, "children": [16, 17], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 17, "type": "system_lib_string", "text": "<stdlib.h>", "parent": 15, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 19}}, {"id": 18, "type": "preproc_include", "text": "#include <string.h>\n", "parent": null, "children": [19, 20], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 8}}, {"id": 20, "type": "system_lib_string", "text": "<string.h>", "parent": 18, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 19}}, {"id": 21, "type": "preproc_def", "text": "#define EPS 1e-5\n", "parent": null, "children": [22, 23, 24], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 22, "type": "#define", "text": "#define", "parent": 21, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 7}}, {"id": 23, "type": "identifier", "text": "EPS", "parent": 21, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 11}}, {"id": 24, "type": "preproc_arg", "text": "1e-5", "parent": 21, "children": [], "start_point": {"row": 8, "column": 12}, "end_point": {"row": 8, "column": 16}}, {"id": 25, "type": "function_definition", "text": "float compute_function(float a, float b, float c, float x) {\n return a * powf(x, 2) * sinf(x) + b * x * cosf(x) + c;\n}", "parent": null, "children": [26, 27], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 12, "column": 1}}, {"id": 26, "type": "primitive_type", "text": "float", "parent": 25, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 5}}, {"id": 27, "type": "function_declarator", "text": "compute_function(float a, float b, float c, float x)", "parent": 25, "children": [28, 29], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 58}}, {"id": 28, "type": "identifier", "text": "compute_function", "parent": 27, "children": [], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 22}}, {"id": 29, "type": "parameter_list", "text": "(float a, float b, float c, float x)", "parent": 27, "children": [30, 33, 36, 39], "start_point": {"row": 10, "column": 22}, "end_point": {"row": 10, "column": 58}}, {"id": 30, "type": "parameter_declaration", "text": "float a", "parent": 29, "children": [31, 32], "start_point": {"row": 10, "column": 23}, "end_point": {"row": 10, "column": 30}}, {"id": 31, "type": "primitive_type", "text": "float", "parent": 30, "children": [], "start_point": {"row": 10, "column": 23}, "end_point": {"row": 10, "column": 28}}, {"id": 32, "type": "identifier", "text": "a", "parent": 30, "children": [], "start_point": {"row": 10, "column": 29}, "end_point": {"row": 10, "column": 30}}, {"id": 33, "type": "parameter_declaration", "text": "float b", "parent": 29, "children": [34, 35], "start_point": {"row": 10, "column": 32}, "end_point": {"row": 10, "column": 39}}, {"id": 34, "type": "primitive_type", "text": "float", "parent": 33, "children": [], "start_point": {"row": 10, "column": 32}, "end_point": {"row": 10, "column": 37}}, {"id": 35, "type": "identifier", "text": "b", "parent": 33, "children": [], "start_point": {"row": 10, "column": 38}, "end_point": {"row": 10, "column": 39}}, {"id": 36, "type": "parameter_declaration", "text": "float c", "parent": 29, "children": [37, 38], "start_point": {"row": 10, "column": 41}, "end_point": {"row": 10, "column": 48}}, {"id": 37, "type": "primitive_type", "text": "float", "parent": 36, "children": [], "start_point": {"row": 10, "column": 41}, "end_point": {"row": 10, "column": 46}}, {"id": 38, "type": "identifier", "text": "c", "parent": 36, "children": [], "start_point": {"row": 10, "column": 47}, "end_point": {"row": 10, "column": 48}}, {"id": 39, "type": "parameter_declaration", "text": "float x", "parent": 29, "children": [40, 41], "start_point": {"row": 10, "column": 50}, "end_point": {"row": 10, "column": 57}}, {"id": 40, "type": "primitive_type", "text": "float", "parent": 39, "children": [], "start_point": {"row": 10, "column": 50}, "end_point": {"row": 10, "column": 55}}, {"id": 41, "type": "identifier", "text": "x", "parent": 39, "children": [], "start_point": {"row": 10, "column": 56}, "end_point": {"row": 10, "column": 57}}, {"id": 42, "type": "return_statement", "text": "return a * powf(x, 2) * sinf(x) + b * x * cosf(x) + c;", "parent": 25, "children": [43], "start_point": {"row": 11, "column": 2}, "end_point": {"row": 11, "column": 56}}, {"id": 43, "type": "binary_expression", "text": "a * powf(x, 2) * sinf(x) + b * x * cosf(x) + c", "parent": 42, "children": [44, 70, 71], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 55}}, {"id": 44, "type": "binary_expression", "text": "a * powf(x, 2) * sinf(x) + b * x * cosf(x)", "parent": 43, "children": [45, 59, 60], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 51}}, {"id": 45, "type": "binary_expression", "text": "a * powf(x, 2) * sinf(x)", "parent": 44, "children": [46, 54, 55], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 33}}, {"id": 46, "type": "binary_expression", "text": "a * powf(x, 2)", "parent": 45, "children": [47, 48, 49], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 23}}, {"id": 47, "type": "identifier", "text": "a", "parent": 46, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 10}}, {"id": 48, "type": "*", "text": "*", "parent": 46, "children": [], "start_point": {"row": 11, "column": 11}, "end_point": {"row": 11, "column": 12}}, {"id": 49, "type": "call_expression", "text": "powf(x, 2)", "parent": 46, "children": [50, 51], "start_point": {"row": 11, "column": 13}, "end_point": {"row": 11, "column": 23}}, {"id": 50, "type": "identifier", "text": "powf", "parent": 49, "children": [], "start_point": {"row": 11, "column": 13}, "end_point": {"row": 11, "column": 17}}, {"id": 51, "type": "argument_list", "text": "(x, 2)", "parent": 49, "children": [52, 53], "start_point": {"row": 11, "column": 17}, "end_point": {"row": 11, "column": 23}}, {"id": 52, "type": "identifier", "text": "x", "parent": 51, "children": [], "start_point": {"row": 11, "column": 18}, "end_point": {"row": 11, "column": 19}}, {"id": 53, "type": "number_literal", "text": "2", "parent": 51, "children": [], "start_point": {"row": 11, "column": 21}, "end_point": {"row": 11, "column": 22}}, {"id": 54, "type": "*", "text": "*", "parent": 45, "children": [], "start_point": {"row": 11, "column": 24}, "end_point": {"row": 11, "column": 25}}, {"id": 55, "type": "call_expression", "text": "sinf(x)", "parent": 45, "children": [56, 57], "start_point": {"row": 11, "column": 26}, "end_point": {"row": 11, "column": 33}}, {"id": 56, "type": "identifier", "text": "sinf", "parent": 55, "children": [], "start_point": {"row": 11, "column": 26}, "end_point": {"row": 11, "column": 30}}, {"id": 57, "type": "argument_list", "text": "(x)", "parent": 55, "children": [58], "start_point": {"row": 11, "column": 30}, "end_point": {"row": 11, "column": 33}}, {"id": 58, "type": "identifier", "text": "x", "parent": 57, "children": [], "start_point": {"row": 11, "column": 31}, "end_point": {"row": 11, "column": 32}}, {"id": 59, "type": "+", "text": "+", "parent": 44, "children": [], "start_point": {"row": 11, "column": 34}, "end_point": {"row": 11, "column": 35}}, {"id": 60, "type": "binary_expression", "text": "b * x * cosf(x)", "parent": 44, "children": [61, 65, 66], "start_point": {"row": 11, "column": 36}, "end_point": {"row": 11, "column": 51}}, {"id": 61, "type": "binary_expression", "text": "b * x", "parent": 60, "children": [62, 63, 64], "start_point": {"row": 11, "column": 36}, "end_point": {"row": 11, "column": 41}}, {"id": 62, "type": "identifier", "text": "b", "parent": 61, "children": [], "start_point": {"row": 11, "column": 36}, "end_point": {"row": 11, "column": 37}}, {"id": 63, "type": "*", "text": "*", "parent": 61, "children": [], "start_point": {"row": 11, "column": 38}, "end_point": {"row": 11, "column": 39}}, {"id": 64, "type": "identifier", "text": "x", "parent": 61, "children": [], "start_point": {"row": 11, "column": 40}, "end_point": {"row": 11, "column": 41}}, {"id": 65, "type": "*", "text": "*", "parent": 60, "children": [], "start_point": {"row": 11, "column": 42}, "end_point": {"row": 11, "column": 43}}, {"id": 66, "type": "call_expression", "text": "cosf(x)", "parent": 60, "children": [67, 68], "start_point": {"row": 11, "column": 44}, "end_point": {"row": 11, "column": 51}}, {"id": 67, "type": "identifier", "text": "cosf", "parent": 66, "children": [], "start_point": {"row": 11, "column": 44}, "end_point": {"row": 11, "column": 48}}, {"id": 68, "type": "argument_list", "text": "(x)", "parent": 66, "children": [69], "start_point": {"row": 11, "column": 48}, "end_point": {"row": 11, "column": 51}}, {"id": 69, "type": "identifier", "text": "x", "parent": 68, "children": [], "start_point": {"row": 11, "column": 49}, "end_point": {"row": 11, "column": 50}}, {"id": 70, "type": "+", "text": "+", "parent": 43, "children": [], "start_point": {"row": 11, "column": 52}, "end_point": {"row": 11, "column": 53}}, {"id": 71, "type": "identifier", "text": "c", "parent": 43, "children": [], "start_point": {"row": 11, "column": 54}, "end_point": {"row": 11, "column": 55}}, {"id": 72, "type": "function_definition", "text": "float solve_equation(float a, float b, float c, float n) {\n float left, right, mid, lval, rval, mval;\n\n left = -n;\n right = n;\n\n lval = compute_function(a, b, c, left);\n rval = compute_function(a, b, c, right);\n\n while (signbit(lval * rval)) {\n mid = (left + right) / 2;\n mval = compute_function(a, b, c, mid);\n\n if (fabsf(mval) < EPS) {\n return mid;\n }\n\n if (signbit(mval * lval)) {\n right = mid;\n } else if (signbit(mval * rval)) {\n left = mid;\n }\n }\n\n return 0;\n}", "parent": null, "children": [73, 74], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 39, "column": 1}}, {"id": 73, "type": "primitive_type", "text": "float", "parent": 72, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 5}}, {"id": 74, "type": "function_declarator", "text": "solve_equation(float a, float b, float c, float n)", "parent": 72, "children": [75, 76], "start_point": {"row": 14, "column": 6}, "end_point": {"row": 14, "column": 56}}, {"id": 75, "type": "identifier", "text": "solve_equation", "parent": 74, "children": [], "start_point": {"row": 14, "column": 6}, "end_point": {"row": 14, "column": 20}}, {"id": 76, "type": "parameter_list", "text": "(float a, float b, float c, float n)", "parent": 74, "children": [77, 80, 83, 86], "start_point": {"row": 14, "column": 20}, "end_point": {"row": 14, "column": 56}}, {"id": 77, "type": "parameter_declaration", "text": "float a", "parent": 76, "children": [78, 79], "start_point": {"row": 14, "column": 21}, "end_point": {"row": 14, "column": 28}}, {"id": 78, "type": "primitive_type", "text": "float", "parent": 77, "children": [], "start_point": {"row": 14, "column": 21}, "end_point": {"row": 14, "column": 26}}, {"id": 79, "type": "identifier", "text": "a", "parent": 77, "children": [], "start_point": {"row": 14, "column": 27}, "end_point": {"row": 14, "column": 28}}, {"id": 80, "type": "parameter_declaration", "text": "float b", "parent": 76, "children": [81, 82], "start_point": {"row": 14, "column": 30}, "end_point": {"row": 14, "column": 37}}, {"id": 81, "type": "primitive_type", "text": "float", "parent": 80, "children": [], "start_point": {"row": 14, "column": 30}, "end_point": {"row": 14, "column": 35}}, {"id": 82, "type": "identifier", "text": "b", "parent": 80, "children": [], "start_point": {"row": 14, "column": 36}, "end_point": {"row": 14, "column": 37}}, {"id": 83, "type": "parameter_declaration", "text": "float c", "parent": 76, "children": [84, 85], "start_point": {"row": 14, "column": 39}, "end_point": {"row": 14, "column": 46}}, {"id": 84, "type": "primitive_type", "text": "float", "parent": 83, "children": [], "start_point": {"row": 14, "column": 39}, "end_point": {"row": 14, "column": 44}}, {"id": 85, "type": "identifier", "text": "c", "parent": 83, "children": [], "start_point": {"row": 14, "column": 45}, "end_point": {"row": 14, "column": 46}}, {"id": 86, "type": "parameter_declaration", "text": "float n", "parent": 76, "children": [87, 88], "start_point": {"row": 14, "column": 48}, "end_point": {"row": 14, "column": 55}}, {"id": 87, "type": "primitive_type", "text": "float", "parent": 86, "children": [], "start_point": {"row": 14, "column": 48}, "end_point": {"row": 14, "column": 53}}, {"id": 88, "type": "identifier", "text": "n", "parent": 86, "children": [], "start_point": {"row": 14, "column": 54}, "end_point": {"row": 14, "column": 55}}, {"id": 89, "type": "declaration", "text": "float left, right, mid, lval, rval, mval;", "parent": 72, "children": [90, 91, 92, 93, 94, 95, 96], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 43}}, {"id": 90, "type": "primitive_type", "text": "float", "parent": 89, "children": [], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 7}}, {"id": 91, "type": "identifier", "text": "left", "parent": 89, "children": [], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 12}}, {"id": 92, "type": "identifier", "text": "right", "parent": 89, "children": [], "start_point": {"row": 15, "column": 14}, "end_point": {"row": 15, "column": 19}}, {"id": 93, "type": "identifier", "text": "mid", "parent": 89, "children": [], "start_point": {"row": 15, "column": 21}, "end_point": {"row": 15, "column": 24}}, {"id": 94, "type": "identifier", "text": "lval", "parent": 89, "children": [], "start_point": {"row": 15, "column": 26}, "end_point": {"row": 15, "column": 30}}, {"id": 95, "type": "identifier", "text": "rval", "parent": 89, "children": [], "start_point": {"row": 15, "column": 32}, "end_point": {"row": 15, "column": 36}}, {"id": 96, "type": "identifier", "text": "mval", "parent": 89, "children": [], "start_point": {"row": 15, "column": 38}, "end_point": {"row": 15, "column": 42}}, {"id": 97, "type": "assignment_expression", "text": "left = -n", "parent": 72, "children": [98, 99, 100], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 17, "column": 12}}, {"id": 98, "type": "identifier", "text": "left", "parent": 97, "children": [], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 17, "column": 6}}, {"id": 99, "type": "=", "text": "=", "parent": 97, "children": [], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 17, "column": 9}}, {"id": 100, "type": "unary_expression", "text": "-n", "parent": 97, "children": [101, 102], "start_point": {"row": 17, "column": 10}, "end_point": {"row": 17, "column": 12}}, {"id": 101, "type": "-", "text": "-", "parent": 100, "children": [], "start_point": {"row": 17, "column": 10}, "end_point": {"row": 17, "column": 11}}, {"id": 102, "type": "identifier", "text": "n", "parent": 100, "children": [], "start_point": {"row": 17, "column": 11}, "end_point": {"row": 17, "column": 12}}, {"id": 103, "type": "assignment_expression", "text": "right = n", "parent": 72, "children": [104, 105, 106], "start_point": {"row": 18, "column": 2}, "end_point": {"row": 18, "column": 11}}, {"id": 104, "type": "identifier", "text": "right", "parent": 103, "children": [], "start_point": {"row": 18, "column": 2}, "end_point": {"row": 18, "column": 7}}, {"id": 105, "type": "=", "text": "=", "parent": 103, "children": [], "start_point": {"row": 18, "column": 8}, "end_point": {"row": 18, "column": 9}}, {"id": 106, "type": "identifier", "text": "n", "parent": 103, "children": [], "start_point": {"row": 18, "column": 10}, "end_point": {"row": 18, "column": 11}}, {"id": 107, "type": "assignment_expression", "text": "lval = compute_function(a, b, c, left)", "parent": 72, "children": [108, 109, 110], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 40}}, {"id": 108, "type": "identifier", "text": "lval", "parent": 107, "children": [], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 6}}, {"id": 109, "type": "=", "text": "=", "parent": 107, "children": [], "start_point": {"row": 20, "column": 7}, "end_point": {"row": 20, "column": 8}}, {"id": 110, "type": "call_expression", "text": "compute_function(a, b, c, left)", "parent": 107, "children": [111, 112], "start_point": {"row": 20, "column": 9}, "end_point": {"row": 20, "column": 40}}, {"id": 111, "type": "identifier", "text": "compute_function", "parent": 110, "children": [], "start_point": {"row": 20, "column": 9}, "end_point": {"row": 20, "column": 25}}, {"id": 112, "type": "argument_list", "text": "(a, b, c, left)", "parent": 110, "children": [113, 114, 115, 116], "start_point": {"row": 20, "column": 25}, "end_point": {"row": 20, "column": 40}}, {"id": 113, "type": "identifier", "text": "a", "parent": 112, "children": [], "start_point": {"row": 20, "column": 26}, "end_point": {"row": 20, "column": 27}}, {"id": 114, "type": "identifier", "text": "b", "parent": 112, "children": [], "start_point": {"row": 20, "column": 29}, "end_point": {"row": 20, "column": 30}}, {"id": 115, "type": "identifier", "text": "c", "parent": 112, "children": [], "start_point": {"row": 20, "column": 32}, "end_point": {"row": 20, "column": 33}}, {"id": 116, "type": "identifier", "text": "left", "parent": 112, "children": [], "start_point": {"row": 20, "column": 35}, "end_point": {"row": 20, "column": 39}}, {"id": 117, "type": "assignment_expression", "text": "rval = compute_function(a, b, c, right)", "parent": 72, "children": [118, 119, 120], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 41}}, {"id": 118, "type": "identifier", "text": "rval", "parent": 117, "children": [], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 6}}, {"id": 119, "type": "=", "text": "=", "parent": 117, "children": [], "start_point": {"row": 21, "column": 7}, "end_point": {"row": 21, "column": 8}}, {"id": 120, "type": "call_expression", "text": "compute_function(a, b, c, right)", "parent": 117, "children": [121, 122], "start_point": {"row": 21, "column": 9}, "end_point": {"row": 21, "column": 41}}, {"id": 121, "type": "identifier", "text": "compute_function", "parent": 120, "children": [], "start_point": {"row": 21, "column": 9}, "end_point": {"row": 21, "column": 25}}, {"id": 122, "type": "argument_list", "text": "(a, b, c, right)", "parent": 120, "children": [123, 124, 125, 126], "start_point": {"row": 21, "column": 25}, "end_point": {"row": 21, "column": 41}}, {"id": 123, "type": "identifier", "text": "a", "parent": 122, "children": [], "start_point": {"row": 21, "column": 26}, "end_point": {"row": 21, "column": 27}}, {"id": 124, "type": "identifier", "text": "b", "parent": 122, "children": [], "start_point": {"row": 21, "column": 29}, "end_point": {"row": 21, "column": 30}}, {"id": 125, "type": "identifier", "text": "c", "parent": 122, "children": [], "start_point": {"row": 21, "column": 32}, "end_point": {"row": 21, "column": 33}}, {"id": 126, "type": "identifier", "text": "right", "parent": 122, "children": [], "start_point": {"row": 21, "column": 35}, "end_point": {"row": 21, "column": 40}}, {"id": 127, "type": "while_statement", "text": "while (signbit(lval * rval)) {\n mid = (left + right) / 2;\n mval = compute_function(a, b, c, mid);\n\n if (fabsf(mval) < EPS) {\n return mid;\n }\n\n if (signbit(mval * lval)) {\n right = mid;\n } else if (signbit(mval * rval)) {\n left = mid;\n }\n }", "parent": 72, "children": [128], "start_point": {"row": 23, "column": 2}, "end_point": {"row": 36, "column": 3}}, {"id": 128, "type": "parenthesized_expression", "text": "(signbit(lval * rval))", "parent": 127, "children": [129], "start_point": {"row": 23, "column": 8}, "end_point": {"row": 23, "column": 30}}, {"id": 129, "type": "call_expression", "text": "signbit(lval * rval)", "parent": 128, "children": [130, 131], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 29}}, {"id": 130, "type": "identifier", "text": "signbit", "parent": 129, "children": [], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 16}}, {"id": 131, "type": "argument_list", "text": "(lval * rval)", "parent": 129, "children": [132], "start_point": {"row": 23, "column": 16}, "end_point": {"row": 23, "column": 29}}, {"id": 132, "type": "binary_expression", "text": "lval * rval", "parent": 131, "children": [133, 134, 135], "start_point": {"row": 23, "column": 17}, "end_point": {"row": 23, "column": 28}}, {"id": 133, "type": "identifier", "text": "lval", "parent": 132, "children": [], "start_point": {"row": 23, "column": 17}, "end_point": {"row": 23, "column": 21}}, {"id": 134, "type": "*", "text": "*", "parent": 132, "children": [], "start_point": {"row": 23, "column": 22}, "end_point": {"row": 23, "column": 23}}, {"id": 135, "type": "identifier", "text": "rval", "parent": 132, "children": [], "start_point": {"row": 23, "column": 24}, "end_point": {"row": 23, "column": 28}}, {"id": 136, "type": "assignment_expression", "text": "mid = (left + right) / 2", "parent": 127, "children": [137, 138, 139], "start_point": {"row": 24, "column": 4}, "end_point": {"row": 24, "column": 29}}, {"id": 137, "type": "identifier", "text": "mid", "parent": 136, "children": [], "start_point": {"row": 24, "column": 4}, "end_point": {"row": 24, "column": 7}}, {"id": 138, "type": "=", "text": "=", "parent": 136, "children": [], "start_point": {"row": 24, "column": 9}, "end_point": {"row": 24, "column": 10}}, {"id": 139, "type": "binary_expression", "text": "(left + right) / 2", "parent": 136, "children": [140, 145, 146], "start_point": {"row": 24, "column": 11}, "end_point": {"row": 24, "column": 29}}, {"id": 140, "type": "parenthesized_expression", "text": "(left + right)", "parent": 139, "children": [141], "start_point": {"row": 24, "column": 11}, "end_point": {"row": 24, "column": 25}}, {"id": 141, "type": "binary_expression", "text": "left + right", "parent": 140, "children": [142, 143, 144], "start_point": {"row": 24, "column": 12}, "end_point": {"row": 24, "column": 24}}, {"id": 142, "type": "identifier", "text": "left", "parent": 141, "children": [], "start_point": {"row": 24, "column": 12}, "end_point": {"row": 24, "column": 16}}, {"id": 143, "type": "+", "text": "+", "parent": 141, "children": [], "start_point": {"row": 24, "column": 17}, "end_point": {"row": 24, "column": 18}}, {"id": 144, "type": "identifier", "text": "right", "parent": 141, "children": [], "start_point": {"row": 24, "column": 19}, "end_point": {"row": 24, "column": 24}}, {"id": 145, "type": "/", "text": "/", "parent": 139, "children": [], "start_point": {"row": 24, "column": 26}, "end_point": {"row": 24, "column": 27}}, {"id": 146, "type": "number_literal", "text": "2", "parent": 139, "children": [], "start_point": {"row": 24, "column": 28}, "end_point": {"row": 24, "column": 29}}, {"id": 147, "type": "assignment_expression", "text": "mval = compute_function(a, b, c, mid)", "parent": 127, "children": [148, 149, 150], "start_point": {"row": 25, "column": 4}, "end_point": {"row": 25, "column": 41}}, {"id": 148, "type": "identifier", "text": "mval", "parent": 147, "children": [], "start_point": {"row": 25, "column": 4}, "end_point": {"row": 25, "column": 8}}, {"id": 149, "type": "=", "text": "=", "parent": 147, "children": [], "start_point": {"row": 25, "column": 9}, "end_point": {"row": 25, "column": 10}}, {"id": 150, "type": "call_expression", "text": "compute_function(a, b, c, mid)", "parent": 147, "children": [151, 152], "start_point": {"row": 25, "column": 11}, "end_point": {"row": 25, "column": 41}}, {"id": 151, "type": "identifier", "text": "compute_function", "parent": 150, "children": [], "start_point": {"row": 25, "column": 11}, "end_point": {"row": 25, "column": 27}}, {"id": 152, "type": "argument_list", "text": "(a, b, c, mid)", "parent": 150, "children": [153, 154, 155, 156], "start_point": {"row": 25, "column": 27}, "end_point": {"row": 25, "column": 41}}, {"id": 153, "type": "identifier", "text": "a", "parent": 152, "children": [], "start_point": {"row": 25, "column": 28}, "end_point": {"row": 25, "column": 29}}, {"id": 154, "type": "identifier", "text": "b", "parent": 152, "children": [], "start_point": {"row": 25, "column": 31}, "end_point": {"row": 25, "column": 32}}, {"id": 155, "type": "identifier", "text": "c", "parent": 152, "children": [], "start_point": {"row": 25, "column": 34}, "end_point": {"row": 25, "column": 35}}, {"id": 156, "type": "identifier", "text": "mid", "parent": 152, "children": [], "start_point": {"row": 25, "column": 37}, "end_point": {"row": 25, "column": 40}}, {"id": 157, "type": "if_statement", "text": "if (fabsf(mval) < EPS) {\n return mid;\n }", "parent": 127, "children": [158], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 29, "column": 5}}, {"id": 158, "type": "parenthesized_expression", "text": "(fabsf(mval) < EPS)", "parent": 157, "children": [159], "start_point": {"row": 27, "column": 7}, "end_point": {"row": 27, "column": 26}}, {"id": 159, "type": "binary_expression", "text": "fabsf(mval) < EPS", "parent": 158, "children": [160, 164, 165], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 25}}, {"id": 160, "type": "call_expression", "text": "fabsf(mval)", "parent": 159, "children": [161, 162], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 19}}, {"id": 161, "type": "identifier", "text": "fabsf", "parent": 160, "children": [], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 13}}, {"id": 162, "type": "argument_list", "text": "(mval)", "parent": 160, "children": [163], "start_point": {"row": 27, "column": 13}, "end_point": {"row": 27, "column": 19}}, {"id": 163, "type": "identifier", "text": "mval", "parent": 162, "children": [], "start_point": {"row": 27, "column": 14}, "end_point": {"row": 27, "column": 18}}, {"id": 164, "type": "<", "text": "<", "parent": 159, "children": [], "start_point": {"row": 27, "column": 20}, "end_point": {"row": 27, "column": 21}}, {"id": 165, "type": "identifier", "text": "EPS", "parent": 159, "children": [], "start_point": {"row": 27, "column": 22}, "end_point": {"row": 27, "column": 25}}, {"id": 166, "type": "return_statement", "text": "return mid;", "parent": 157, "children": [167], "start_point": {"row": 28, "column": 6}, "end_point": {"row": 28, "column": 17}}, {"id": 167, "type": "identifier", "text": "mid", "parent": 166, "children": [], "start_point": {"row": 28, "column": 13}, "end_point": {"row": 28, "column": 16}}, {"id": 168, "type": "if_statement", "text": "if (signbit(mval * lval)) {\n right = mid;\n } else if (signbit(mval * rval)) {\n left = mid;\n }", "parent": 127, "children": [169, 181], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 35, "column": 5}}, {"id": 169, "type": "parenthesized_expression", "text": "(signbit(mval * lval))", "parent": 168, "children": [170], "start_point": {"row": 31, "column": 7}, "end_point": {"row": 31, "column": 29}}, {"id": 170, "type": "call_expression", "text": "signbit(mval * lval)", "parent": 169, "children": [171, 172], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 28}}, {"id": 171, "type": "identifier", "text": "signbit", "parent": 170, "children": [], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 15}}, {"id": 172, "type": "argument_list", "text": "(mval * lval)", "parent": 170, "children": [173], "start_point": {"row": 31, "column": 15}, "end_point": {"row": 31, "column": 28}}, {"id": 173, "type": "binary_expression", "text": "mval * lval", "parent": 172, "children": [174, 175, 176], "start_point": {"row": 31, "column": 16}, "end_point": {"row": 31, "column": 27}}, {"id": 174, "type": "identifier", "text": "mval", "parent": 173, "children": [], "start_point": {"row": 31, "column": 16}, "end_point": {"row": 31, "column": 20}}, {"id": 175, "type": "*", "text": "*", "parent": 173, "children": [], "start_point": {"row": 31, "column": 21}, "end_point": {"row": 31, "column": 22}}, {"id": 176, "type": "identifier", "text": "lval", "parent": 173, "children": [], "start_point": {"row": 31, "column": 23}, "end_point": {"row": 31, "column": 27}}, {"id": 177, "type": "assignment_expression", "text": "right = mid", "parent": 168, "children": [178, 179, 180], "start_point": {"row": 32, "column": 6}, "end_point": {"row": 32, "column": 17}}, {"id": 178, "type": "identifier", "text": "right", "parent": 177, "children": [], "start_point": {"row": 32, "column": 6}, "end_point": {"row": 32, "column": 11}}, {"id": 179, "type": "=", "text": "=", "parent": 177, "children": [], "start_point": {"row": 32, "column": 12}, "end_point": {"row": 32, "column": 13}}, {"id": 180, "type": "identifier", "text": "mid", "parent": 177, "children": [], "start_point": {"row": 32, "column": 14}, "end_point": {"row": 32, "column": 17}}, {"id": 181, "type": "else_clause", "text": "else if (signbit(mval * rval)) {\n left = mid;\n }", "parent": 168, "children": [182], "start_point": {"row": 33, "column": 6}, "end_point": {"row": 35, "column": 5}}, {"id": 182, "type": "if_statement", "text": "if (signbit(mval * rval)) {\n left = mid;\n }", "parent": 181, "children": [183], "start_point": {"row": 33, "column": 11}, "end_point": {"row": 35, "column": 5}}, {"id": 183, "type": "parenthesized_expression", "text": "(signbit(mval * rval))", "parent": 182, "children": [184], "start_point": {"row": 33, "column": 14}, "end_point": {"row": 33, "column": 36}}, {"id": 184, "type": "call_expression", "text": "signbit(mval * rval)", "parent": 183, "children": [185, 186], "start_point": {"row": 33, "column": 15}, "end_point": {"row": 33, "column": 35}}, {"id": 185, "type": "identifier", "text": "signbit", "parent": 184, "children": [], "start_point": {"row": 33, "column": 15}, "end_point": {"row": 33, "column": 22}}, {"id": 186, "type": "argument_list", "text": "(mval * rval)", "parent": 184, "children": [187], "start_point": {"row": 33, "column": 22}, "end_point": {"row": 33, "column": 35}}, {"id": 187, "type": "binary_expression", "text": "mval * rval", "parent": 186, "children": [188, 189, 190], "start_point": {"row": 33, "column": 23}, "end_point": {"row": 33, "column": 34}}, {"id": 188, "type": "identifier", "text": "mval", "parent": 187, "children": [], "start_point": {"row": 33, "column": 23}, "end_point": {"row": 33, "column": 27}}, {"id": 189, "type": "*", "text": "*", "parent": 187, "children": [], "start_point": {"row": 33, "column": 28}, "end_point": {"row": 33, "column": 29}}, {"id": 190, "type": "identifier", "text": "rval", "parent": 187, "children": [], "start_point": {"row": 33, "column": 30}, "end_point": {"row": 33, "column": 34}}, {"id": 191, "type": "assignment_expression", "text": "left = mid", "parent": 182, "children": [192, 193, 194], "start_point": {"row": 34, "column": 6}, "end_point": {"row": 34, "column": 16}}, {"id": 192, "type": "identifier", "text": "left", "parent": 191, "children": [], "start_point": {"row": 34, "column": 6}, "end_point": {"row": 34, "column": 10}}, {"id": 193, "type": "=", "text": "=", "parent": 191, "children": [], "start_point": {"row": 34, "column": 11}, "end_point": {"row": 34, "column": 12}}, {"id": 194, "type": "identifier", "text": "mid", "parent": 191, "children": [], "start_point": {"row": 34, "column": 13}, "end_point": {"row": 34, "column": 16}}, {"id": 195, "type": "return_statement", "text": "return 0;", "parent": 72, "children": [196], "start_point": {"row": 38, "column": 2}, "end_point": {"row": 38, "column": 11}}, {"id": 196, "type": "number_literal", "text": "0", "parent": 195, "children": [], "start_point": {"row": 38, "column": 9}, "end_point": {"row": 38, "column": 10}}, {"id": 197, "type": "function_definition", "text": "int main() {\n float a, b, c, n, x;\n int res;\n\n res = scanf(\"%f %f %f %f\", &a, &b, &c, &n);\n\n if (res != 4) {\n exit(EXIT_FAILURE);\n }\n\n x = solve_equation(a, b, c, n);\n if (!x) {\n printf(\"0.0\\n\");\n } else {\n printf(\"%.5f\", x);\n }\n}", "parent": null, "children": [198, 199], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 57, "column": 1}}, {"id": 198, "type": "primitive_type", "text": "int", "parent": 197, "children": [], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 41, "column": 3}}, {"id": 199, "type": "function_declarator", "text": "main()", "parent": 197, "children": [200, 201], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 41, "column": 10}}, {"id": 200, "type": "identifier", "text": "main", "parent": 199, "children": [], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 41, "column": 8}}, {"id": 201, "type": "parameter_list", "text": "()", "parent": 199, "children": [], "start_point": {"row": 41, "column": 8}, "end_point": {"row": 41, "column": 10}}, {"id": 202, "type": "declaration", "text": "float a, b, c, n, x;", "parent": 197, "children": [203, 204, 205, 206, 207, 208], "start_point": {"row": 42, "column": 2}, "end_point": {"row": 42, "column": 22}}, {"id": 203, "type": "primitive_type", "text": "float", "parent": 202, "children": [], "start_point": {"row": 42, "column": 2}, "end_point": {"row": 42, "column": 7}}, {"id": 204, "type": "identifier", "text": "a", "parent": 202, "children": [], "start_point": {"row": 42, "column": 8}, "end_point": {"row": 42, "column": 9}}, {"id": 205, "type": "identifier", "text": "b", "parent": 202, "children": [], "start_point": {"row": 42, "column": 11}, "end_point": {"row": 42, "column": 12}}, {"id": 206, "type": "identifier", "text": "c", "parent": 202, "children": [], "start_point": {"row": 42, "column": 14}, "end_point": {"row": 42, "column": 15}}, {"id": 207, "type": "identifier", "text": "n", "parent": 202, "children": [], "start_point": {"row": 42, "column": 17}, "end_point": {"row": 42, "column": 18}}, {"id": 208, "type": "identifier", "text": "x", "parent": 202, "children": [], "start_point": {"row": 42, "column": 20}, "end_point": {"row": 42, "column": 21}}, {"id": 209, "type": "declaration", "text": "int res;", "parent": 197, "children": [210, 211], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 43, "column": 12}}, {"id": 210, "type": "primitive_type", "text": "int", "parent": 209, "children": [], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 43, "column": 5}}, {"id": 211, "type": "identifier", "text": "res", "parent": 209, "children": [], "start_point": {"row": 43, "column": 8}, "end_point": {"row": 43, "column": 11}}, {"id": 212, "type": "assignment_expression", "text": "res = scanf(\"%f %f %f %f\", &a, &b, &c, &n)", "parent": 197, "children": [213, 214, 215], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 44}}, {"id": 213, "type": "identifier", "text": "res", "parent": 212, "children": [], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 5}}, {"id": 214, "type": "=", "text": "=", "parent": 212, "children": [], "start_point": {"row": 45, "column": 6}, "end_point": {"row": 45, "column": 7}}, {"id": 215, "type": "call_expression", "text": "scanf(\"%f %f %f %f\", &a, &b, &c, &n)", "parent": 212, "children": [216, 217], "start_point": {"row": 45, "column": 8}, "end_point": {"row": 45, "column": 44}}, {"id": 216, "type": "identifier", "text": "scanf", "parent": 215, "children": [], "start_point": {"row": 45, "column": 8}, "end_point": {"row": 45, "column": 13}}, {"id": 217, "type": "argument_list", "text": "(\"%f %f %f %f\", &a, &b, &c, &n)", "parent": 215, "children": [218, 219, 221, 223, 225], "start_point": {"row": 45, "column": 13}, "end_point": {"row": 45, "column": 44}}, {"id": 218, "type": "string_literal", "text": "\"%f %f %f %f\"", "parent": 217, "children": [], "start_point": {"row": 45, "column": 14}, "end_point": {"row": 45, "column": 27}}, {"id": 219, "type": "pointer_expression", "text": "&a", "parent": 217, "children": [220], "start_point": {"row": 45, "column": 29}, "end_point": {"row": 45, "column": 31}}, {"id": 220, "type": "identifier", "text": "a", "parent": 219, "children": [], "start_point": {"row": 45, "column": 30}, "end_point": {"row": 45, "column": 31}}, {"id": 221, "type": "pointer_expression", "text": "&b", "parent": 217, "children": [222], "start_point": {"row": 45, "column": 33}, "end_point": {"row": 45, "column": 35}}, {"id": 222, "type": "identifier", "text": "b", "parent": 221, "children": [], "start_point": {"row": 45, "column": 34}, "end_point": {"row": 45, "column": 35}}, {"id": 223, "type": "pointer_expression", "text": "&c", "parent": 217, "children": [224], "start_point": {"row": 45, "column": 37}, "end_point": {"row": 45, "column": 39}}, {"id": 224, "type": "identifier", "text": "c", "parent": 223, "children": [], "start_point": {"row": 45, "column": 38}, "end_point": {"row": 45, "column": 39}}, {"id": 225, "type": "pointer_expression", "text": "&n", "parent": 217, "children": [226], "start_point": {"row": 45, "column": 41}, "end_point": {"row": 45, "column": 43}}, {"id": 226, "type": "identifier", "text": "n", "parent": 225, "children": [], "start_point": {"row": 45, "column": 42}, "end_point": {"row": 45, "column": 43}}, {"id": 227, "type": "if_statement", "text": "if (res != 4) {\n exit(EXIT_FAILURE);\n }", "parent": 197, "children": [228], "start_point": {"row": 47, "column": 2}, "end_point": {"row": 49, "column": 3}}, {"id": 228, "type": "parenthesized_expression", "text": "(res != 4)", "parent": 227, "children": [229], "start_point": {"row": 47, "column": 5}, "end_point": {"row": 47, "column": 15}}, {"id": 229, "type": "binary_expression", "text": "res != 4", "parent": 228, "children": [230, 231, 232], "start_point": {"row": 47, "column": 6}, "end_point": {"row": 47, "column": 14}}, {"id": 230, "type": "identifier", "text": "res", "parent": 229, "children": [], "start_point": {"row": 47, "column": 6}, "end_point": {"row": 47, "column": 9}}, {"id": 231, "type": "!=", "text": "!=", "parent": 229, "children": [], "start_point": {"row": 47, "column": 10}, "end_point": {"row": 47, "column": 12}}, {"id": 232, "type": "number_literal", "text": "4", "parent": 229, "children": [], "start_point": {"row": 47, "column": 13}, "end_point": {"row": 47, "column": 14}}, {"id": 233, "type": "call_expression", "text": "exit(EXIT_FAILURE)", "parent": 227, "children": [234, 235], "start_point": {"row": 48, "column": 4}, "end_point": {"row": 48, "column": 22}}, {"id": 234, "type": "identifier", "text": "exit", "parent": 233, "children": [], "start_point": {"row": 48, "column": 4}, "end_point": {"row": 48, "column": 8}}, {"id": 235, "type": "argument_list", "text": "(EXIT_FAILURE)", "parent": 233, "children": [236], "start_point": {"row": 48, "column": 8}, "end_point": {"row": 48, "column": 22}}, {"id": 236, "type": "identifier", "text": "EXIT_FAILURE", "parent": 235, "children": [], "start_point": {"row": 48, "column": 9}, "end_point": {"row": 48, "column": 21}}, {"id": 237, "type": "assignment_expression", "text": "x = solve_equation(a, b, c, n)", "parent": 197, "children": [238, 239, 240], "start_point": {"row": 51, "column": 2}, "end_point": {"row": 51, "column": 32}}, {"id": 238, "type": "identifier", "text": "x", "parent": 237, "children": [], "start_point": {"row": 51, "column": 2}, "end_point": {"row": 51, "column": 3}}, {"id": 239, "type": "=", "text": "=", "parent": 237, "children": [], "start_point": {"row": 51, "column": 4}, "end_point": {"row": 51, "column": 5}}, {"id": 240, "type": "call_expression", "text": "solve_equation(a, b, c, n)", "parent": 237, "children": [241, 242], "start_point": {"row": 51, "column": 6}, "end_point": {"row": 51, "column": 32}}, {"id": 241, "type": "identifier", "text": "solve_equation", "parent": 240, "children": [], "start_point": {"row": 51, "column": 6}, "end_point": {"row": 51, "column": 20}}, {"id": 242, "type": "argument_list", "text": "(a, b, c, n)", "parent": 240, "children": [243, 244, 245, 246], "start_point": {"row": 51, "column": 20}, "end_point": {"row": 51, "column": 32}}, {"id": 243, "type": "identifier", "text": "a", "parent": 242, "children": [], "start_point": {"row": 51, "column": 21}, "end_point": {"row": 51, "column": 22}}, {"id": 244, "type": "identifier", "text": "b", "parent": 242, "children": [], "start_point": {"row": 51, "column": 24}, "end_point": {"row": 51, "column": 25}}, {"id": 245, "type": "identifier", "text": "c", "parent": 242, "children": [], "start_point": {"row": 51, "column": 27}, "end_point": {"row": 51, "column": 28}}, {"id": 246, "type": "identifier", "text": "n", "parent": 242, "children": [], "start_point": {"row": 51, "column": 30}, "end_point": {"row": 51, "column": 31}}, {"id": 247, "type": "if_statement", "text": "if (!x) {\n printf(\"0.0\\n\");\n } else {\n printf(\"%.5f\", x);\n }", "parent": 197, "children": [248, 257], "start_point": {"row": 52, "column": 2}, "end_point": {"row": 56, "column": 3}}, {"id": 248, "type": "parenthesized_expression", "text": "(!x)", "parent": 247, "children": [249], "start_point": {"row": 52, "column": 5}, "end_point": {"row": 52, "column": 9}}, {"id": 249, "type": "unary_expression", "text": "!x", "parent": 248, "children": [250, 251], "start_point": {"row": 52, "column": 6}, "end_point": {"row": 52, "column": 8}}, {"id": 250, "type": "!", "text": "!", "parent": 249, "children": [], "start_point": {"row": 52, "column": 6}, "end_point": {"row": 52, "column": 7}}, {"id": 251, "type": "identifier", "text": "x", "parent": 249, "children": [], "start_point": {"row": 52, "column": 7}, "end_point": {"row": 52, "column": 8}}, {"id": 252, "type": "call_expression", "text": "printf(\"0.0\\n\")", "parent": 247, "children": [253, 254], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 19}}, {"id": 253, "type": "identifier", "text": "printf", "parent": 252, "children": [], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 10}}, {"id": 254, "type": "argument_list", "text": "(\"0.0\\n\")", "parent": 252, "children": [255], "start_point": {"row": 53, "column": 10}, "end_point": {"row": 53, "column": 19}}, {"id": 255, "type": "string_literal", "text": "\"0.0\\n\"", "parent": 254, "children": [256], "start_point": {"row": 53, "column": 11}, "end_point": {"row": 53, "column": 18}}, {"id": 256, "type": "escape_sequence", "text": "\\n", "parent": 255, "children": [], "start_point": {"row": 53, "column": 15}, "end_point": {"row": 53, "column": 17}}, {"id": 257, "type": "else_clause", "text": "else {\n printf(\"%.5f\", x);\n }", "parent": 247, "children": [], "start_point": {"row": 54, "column": 4}, "end_point": {"row": 56, "column": 3}}, {"id": 258, "type": "call_expression", "text": "printf(\"%.5f\", x)", "parent": 257, "children": [259, 260], "start_point": {"row": 55, "column": 4}, "end_point": {"row": 55, "column": 21}}, {"id": 259, "type": "identifier", "text": "printf", "parent": 258, "children": [], "start_point": {"row": 55, "column": 4}, "end_point": {"row": 55, "column": 10}}, {"id": 260, "type": "argument_list", "text": "(\"%.5f\", x)", "parent": 258, "children": [261, 262], "start_point": {"row": 55, "column": 10}, "end_point": {"row": 55, "column": 21}}, {"id": 261, "type": "string_literal", "text": "\"%.5f\"", "parent": 260, "children": [], "start_point": {"row": 55, "column": 11}, "end_point": {"row": 55, "column": 17}}, {"id": 262, "type": "identifier", "text": "x", "parent": 260, "children": [], "start_point": {"row": 55, "column": 19}, "end_point": {"row": 55, "column": 20}}]}, "node_categories": {"declarations": {"functions": [25, 27, 72, 74, 197, 199], "variables": [30, 33, 36, 39, 77, 80, 83, 86, 89, 202, 209], "classes": [], "imports": [0, 1, 3, 4, 6, 7, 9, 10, 12, 13, 15, 16, 18, 19], "modules": [], "enums": []}, "statements": {"expressions": [43, 44, 45, 46, 49, 55, 60, 61, 66, 100, 110, 120, 128, 129, 132, 139, 140, 141, 150, 158, 159, 160, 169, 170, 173, 183, 184, 187, 215, 219, 221, 223, 225, 228, 229, 233, 240, 248, 249, 252, 258], "assignments": [97, 103, 107, 117, 136, 147, 177, 191, 212, 237], "loops": [127], "conditionals": [23, 28, 32, 35, 38, 41, 47, 50, 52, 56, 58, 62, 64, 67, 69, 71, 75, 79, 82, 85, 88, 91, 92, 93, 94, 95, 96, 98, 102, 104, 106, 108, 111, 113, 114, 115, 116, 118, 121, 123, 124, 125, 126, 130, 133, 135, 137, 142, 144, 148, 151, 153, 154, 155, 156, 157, 161, 163, 165, 167, 168, 171, 174, 176, 178, 180, 182, 185, 188, 190, 192, 194, 200, 204, 205, 206, 207, 208, 211, 213, 216, 220, 222, 224, 226, 227, 230, 234, 236, 238, 241, 243, 244, 245, 246, 247, 251, 253, 259, 262], "returns": [42, 166, 195], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 8, 11, 14, 17, 20, 53, 146, 196, 218, 232, 255, 261], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 25, "universal_type": "function", "name": "unknown", "text_snippet": "float compute_function(float a, float b, float c, float x) {\n return a * powf(x, 2) * sinf(x) + b *"}, {"node_id": 27, "universal_type": "function", "name": "unknown", "text_snippet": "compute_function(float a, float b, float c, float x)"}, {"node_id": 72, "universal_type": "function", "name": "unknown", "text_snippet": "float solve_equation(float a, float b, float c, float n) {\n float left, right, mid, lval, rval, mva"}, {"node_id": 74, "universal_type": "function", "name": "unknown", "text_snippet": "solve_equation(float a, float b, float c, float n)"}, {"node_id": 197, "universal_type": "function", "name": "main", "text_snippet": "int main() {\n float a, b, c, n, x;\n int res;\n\n res = scanf(\"%f %f %f %f\", &a, &b, &c, &n);\n\n i"}, {"node_id": 199, "universal_type": "function", "name": "unknown", "text_snippet": "main()"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <ctype.h>\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <fenv.h>\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include <float.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <math.h>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include <stdio.h>\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include <stdlib.h>\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include <string.h>\n"}, {"node_id": 19, "text": "#include"}]}, "original_source_code": "#include <ctype.h>\n#include <fenv.h>\n#include <float.h>\n#include <math.h>\n#include <stdio.h>\n#include <stdlib.h>\n#include <string.h>\n\n#define EPS 1e-5\n\nfloat compute_function(float a, float b, float c, float x) {\n return a * powf(x, 2) * sinf(x) + b * x * cosf(x) + c;\n}\n\nfloat solve_equation(float a, float b, float c, float n) {\n float left, right, mid, lval, rval, mval;\n\n left = -n;\n right = n;\n\n lval = compute_function(a, b, c, left);\n rval = compute_function(a, b, c, right);\n\n while (signbit(lval * rval)) {\n mid = (left + right) / 2;\n mval = compute_function(a, b, c, mid);\n\n if (fabsf(mval) < EPS) {\n return mid;\n }\n\n if (signbit(mval * lval)) {\n right = mid;\n } else if (signbit(mval * rval)) {\n left = mid;\n }\n }\n\n return 0;\n}\n\nint main() {\n float a, b, c, n, x;\n int res;\n\n res = scanf(\"%f %f %f %f\", &a, &b, &c, &n);\n\n if (res != 4) {\n exit(EXIT_FAILURE);\n }\n\n x = solve_equation(a, b, c, n);\n if (!x) {\n printf(\"0.0\\n\");\n } else {\n printf(\"%.5f\", x);\n }\n}\n"}
80,552
c
// utilities that being used frequently #include <stdio.h> #include <stdlib.h> #include <string.h> #include "member.h" // swap two integer void swap(int *a, int *b) { int tmp = *a; *a = *b; *b = tmp; } // safely get an integer from stdin int get_int() { const long long MAXI = 0x7fffffff; static char buf[16]; long long input_id = 0; scanf("%15s", buf); for (int i = 0; i < (int)strlen(buf); ++i) { if (buf[i] >= '0' && buf[i] <= '9') // make sure inputs are valid input_id = input_id * 10 + buf[i] - '0'; else return -1; } if (input_id > MAXI) return -1; return (int)input_id; } int my_getline(FILE *stream, char *string, int size) { int p = 0; char c = fgetc(stream); while (c != '\n' && c != EOF && size--) { string[p++] = c; c = fgetc(stream); } string[p] = '\0'; if (c == EOF) return -1; return 0; } // clear shell content void clear_sh() { system("clear || cls"); // compatible with both POSIX and WIN32 api }
24.61
41
(translation_unit) "// utilities that being used frequently\n\n#include <stdio.h>\n#include <stdlib.h>\n#include <string.h>\n\n#include "member.h"\n\n// swap two integer\nvoid swap(int *a, int *b) {\n int tmp = *a;\n *a = *b;\n *b = tmp;\n}\n\n// safely get an integer from stdin\nint get_int() {\n const long long MAXI = 0x7fffffff;\n static char buf[16];\n long long input_id = 0;\n scanf("%15s", buf);\n for (int i = 0; i < (int)strlen(buf); ++i) {\n if (buf[i] >= '0' && buf[i] <= '9') // make sure inputs are valid\n input_id = input_id * 10 + buf[i] - '0';\n else\n return -1;\n }\n if (input_id > MAXI) return -1;\n return (int)input_id;\n}\n\nint my_getline(FILE *stream, char *string, int size) {\n int p = 0;\n char c = fgetc(stream);\n while (c != '\n' && c != EOF && size--) {\n string[p++] = c;\n c = fgetc(stream);\n }\n string[p] = '\0';\n if (c == EOF) return -1;\n return 0;\n}\n\n// clear shell content\nvoid clear_sh() {\n system("clear || cls"); // compatible with both POSIX and WIN32 api\n}\n" (comment) "// utilities that being used frequently" (preproc_include) "#include <stdio.h>\n" (#include) "#include" (system_lib_string) "<stdio.h>" (preproc_include) "#include <stdlib.h>\n" (#include) "#include" (system_lib_string) "<stdlib.h>" (preproc_include) "#include <string.h>\n" (#include) "#include" (system_lib_string) "<string.h>" (preproc_include) "#include "member.h"\n" (#include) "#include" (string_literal) ""member.h"" (") """ (string_content) "member.h" (") """ (comment) "// swap two integer" (function_definition) "void swap(int *a, int *b) {\n int tmp = *a;\n *a = *b;\n *b = tmp;\n}" (primitive_type) "void" (function_declarator) "swap(int *a, int *b)" (identifier) "swap" (parameter_list) "(int *a, int *b)" (() "(" (parameter_declaration) "int *a" (primitive_type) "int" (pointer_declarator) "*a" (*) "*" (identifier) "a" (,) "," (parameter_declaration) "int *b" (primitive_type) "int" (pointer_declarator) "*b" (*) "*" (identifier) "b" ()) ")" (compound_statement) "{\n int tmp = *a;\n *a = *b;\n *b = tmp;\n}" ({) "{" (declaration) "int tmp = *a;" (primitive_type) "int" (init_declarator) "tmp = *a" (identifier) "tmp" (=) "=" (pointer_expression) "*a" (*) "*" (identifier) "a" (;) ";" (expression_statement) "*a = *b;" (assignment_expression) "*a = *b" (pointer_expression) "*a" (*) "*" (identifier) "a" (=) "=" (pointer_expression) "*b" (*) "*" (identifier) "b" (;) ";" (expression_statement) "*b = tmp;" (assignment_expression) "*b = tmp" (pointer_expression) "*b" (*) "*" (identifier) "b" (=) "=" (identifier) "tmp" (;) ";" (}) "}" (comment) "// safely get an integer from stdin" (function_definition) "int get_int() {\n const long long MAXI = 0x7fffffff;\n static char buf[16];\n long long input_id = 0;\n scanf("%15s", buf);\n for (int i = 0; i < (int)strlen(buf); ++i) {\n if (buf[i] >= '0' && buf[i] <= '9') // make sure inputs are valid\n input_id = input_id * 10 + buf[i] - '0';\n else\n return -1;\n }\n if (input_id > MAXI) return -1;\n return (int)input_id;\n}" (primitive_type) "int" (function_declarator) "get_int()" (identifier) "get_int" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n const long long MAXI = 0x7fffffff;\n static char buf[16];\n long long input_id = 0;\n scanf("%15s", buf);\n for (int i = 0; i < (int)strlen(buf); ++i) {\n if (buf[i] >= '0' && buf[i] <= '9') // make sure inputs are valid\n input_id = input_id * 10 + buf[i] - '0';\n else\n return -1;\n }\n if (input_id > MAXI) return -1;\n return (int)input_id;\n}" ({) "{" (declaration) "const long long MAXI = 0x7fffffff;" (type_qualifier) "const" (const) "const" (sized_type_specifier) "long long" (long) "long" (long) "long" (init_declarator) "MAXI = 0x7fffffff" (identifier) "MAXI" (=) "=" (number_literal) "0x7fffffff" (;) ";" (declaration) "static char buf[16];" (storage_class_specifier) "static" (static) "static" (primitive_type) "char" (array_declarator) "buf[16]" (identifier) "buf" ([) "[" (number_literal) "16" (]) "]" (;) ";" (declaration) "long long input_id = 0;" (sized_type_specifier) "long long" (long) "long" (long) "long" (init_declarator) "input_id = 0" (identifier) "input_id" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "scanf("%15s", buf);" (call_expression) "scanf("%15s", buf)" (identifier) "scanf" (argument_list) "("%15s", buf)" (() "(" (string_literal) ""%15s"" (") """ (string_content) "%15s" (") """ (,) "," (identifier) "buf" ()) ")" (;) ";" (for_statement) "for (int i = 0; i < (int)strlen(buf); ++i) {\n if (buf[i] >= '0' && buf[i] <= '9') // make sure inputs are valid\n input_id = input_id * 10 + buf[i] - '0';\n else\n return -1;\n }" (for) "for" (() "(" (declaration) "int i = 0;" (primitive_type) "int" (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i < (int)strlen(buf)" (identifier) "i" (<) "<" (cast_expression) "(int)strlen(buf)" (() "(" (type_descriptor) "int" (primitive_type) "int" ()) ")" (call_expression) "strlen(buf)" (identifier) "strlen" (argument_list) "(buf)" (() "(" (identifier) "buf" ()) ")" (;) ";" (update_expression) "++i" (++) "++" (identifier) "i" ()) ")" (compound_statement) "{\n if (buf[i] >= '0' && buf[i] <= '9') // make sure inputs are valid\n input_id = input_id * 10 + buf[i] - '0';\n else\n return -1;\n }" ({) "{" (if_statement) "if (buf[i] >= '0' && buf[i] <= '9') // make sure inputs are valid\n input_id = input_id * 10 + buf[i] - '0';\n else\n return -1;" (if) "if" (parenthesized_expression) "(buf[i] >= '0' && buf[i] <= '9')" (() "(" (binary_expression) "buf[i] >= '0' && buf[i] <= '9'" (binary_expression) "buf[i] >= '0'" (subscript_expression) "buf[i]" (identifier) "buf" ([) "[" (identifier) "i" (]) "]" (>=) ">=" (char_literal) "'0'" (') "'" (character) "0" (') "'" (&&) "&&" (binary_expression) "buf[i] <= '9'" (subscript_expression) "buf[i]" (identifier) "buf" ([) "[" (identifier) "i" (]) "]" (<=) "<=" (char_literal) "'9'" (') "'" (character) "9" (') "'" ()) ")" (comment) "// make sure inputs are valid" (expression_statement) "input_id = input_id * 10 + buf[i] - '0';" (assignment_expression) "input_id = input_id * 10 + buf[i] - '0'" (identifier) "input_id" (=) "=" (binary_expression) "input_id * 10 + buf[i] - '0'" (binary_expression) "input_id * 10 + buf[i]" (binary_expression) "input_id * 10" (identifier) "input_id" (*) "*" (number_literal) "10" (+) "+" (subscript_expression) "buf[i]" (identifier) "buf" ([) "[" (identifier) "i" (]) "]" (-) "-" (char_literal) "'0'" (') "'" (character) "0" (') "'" (;) ";" (else_clause) "else\n return -1;" (else) "else" (return_statement) "return -1;" (return) "return" (number_literal) "-1" (;) ";" (}) "}" (if_statement) "if (input_id > MAXI) return -1;" (if) "if" (parenthesized_expression) "(input_id > MAXI)" (() "(" (binary_expression) "input_id > MAXI" (identifier) "input_id" (>) ">" (identifier) "MAXI" ()) ")" (return_statement) "return -1;" (return) "return" (number_literal) "-1" (;) ";" (return_statement) "return (int)input_id;" (return) "return" (cast_expression) "(int)input_id" (() "(" (type_descriptor) "int" (primitive_type) "int" ()) ")" (identifier) "input_id" (;) ";" (}) "}" (function_definition) "int my_getline(FILE *stream, char *string, int size) {\n int p = 0;\n char c = fgetc(stream);\n while (c != '\n' && c != EOF && size--) {\n string[p++] = c;\n c = fgetc(stream);\n }\n string[p] = '\0';\n if (c == EOF) return -1;\n return 0;\n}" (primitive_type) "int" (function_declarator) "my_getline(FILE *stream, char *string, int size)" (identifier) "my_getline" (parameter_list) "(FILE *stream, char *string, int size)" (() "(" (parameter_declaration) "FILE *stream" (type_identifier) "FILE" (pointer_declarator) "*stream" (*) "*" (identifier) "stream" (,) "," (parameter_declaration) "char *string" (primitive_type) "char" (pointer_declarator) "*string" (*) "*" (identifier) "string" (,) "," (parameter_declaration) "int size" (primitive_type) "int" (identifier) "size" ()) ")" (compound_statement) "{\n int p = 0;\n char c = fgetc(stream);\n while (c != '\n' && c != EOF && size--) {\n string[p++] = c;\n c = fgetc(stream);\n }\n string[p] = '\0';\n if (c == EOF) return -1;\n return 0;\n}" ({) "{" (declaration) "int p = 0;" (primitive_type) "int" (init_declarator) "p = 0" (identifier) "p" (=) "=" (number_literal) "0" (;) ";" (declaration) "char c = fgetc(stream);" (primitive_type) "char" (init_declarator) "c = fgetc(stream)" (identifier) "c" (=) "=" (call_expression) "fgetc(stream)" (identifier) "fgetc" (argument_list) "(stream)" (() "(" (identifier) "stream" ()) ")" (;) ";" (while_statement) "while (c != '\n' && c != EOF && size--) {\n string[p++] = c;\n c = fgetc(stream);\n }" (while) "while" (parenthesized_expression) "(c != '\n' && c != EOF && size--)" (() "(" (binary_expression) "c != '\n' && c != EOF && size--" (binary_expression) "c != '\n' && c != EOF" (binary_expression) "c != '\n'" (identifier) "c" (!=) "!=" (char_literal) "'\n'" (') "'" (escape_sequence) "\n" (') "'" (&&) "&&" (binary_expression) "c != EOF" (identifier) "c" (!=) "!=" (identifier) "EOF" (&&) "&&" (update_expression) "size--" (identifier) "size" (--) "--" ()) ")" (compound_statement) "{\n string[p++] = c;\n c = fgetc(stream);\n }" ({) "{" (expression_statement) "string[p++] = c;" (assignment_expression) "string[p++] = c" (subscript_expression) "string[p++]" (identifier) "string" ([) "[" (update_expression) "p++" (identifier) "p" (++) "++" (]) "]" (=) "=" (identifier) "c" (;) ";" (expression_statement) "c = fgetc(stream);" (assignment_expression) "c = fgetc(stream)" (identifier) "c" (=) "=" (call_expression) "fgetc(stream)" (identifier) "fgetc" (argument_list) "(stream)" (() "(" (identifier) "stream" ()) ")" (;) ";" (}) "}" (expression_statement) "string[p] = '\0';" (assignment_expression) "string[p] = '\0'" (subscript_expression) "string[p]" (identifier) "string" ([) "[" (identifier) "p" (]) "]" (=) "=" (char_literal) "'\0'" (') "'" (escape_sequence) "\0" (') "'" (;) ";" (if_statement) "if (c == EOF) return -1;" (if) "if" (parenthesized_expression) "(c == EOF)" (() "(" (binary_expression) "c == EOF" (identifier) "c" (==) "==" (identifier) "EOF" ()) ")" (return_statement) "return -1;" (return) "return" (number_literal) "-1" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (comment) "// clear shell content" (function_definition) "void clear_sh() {\n system("clear || cls"); // compatible with both POSIX and WIN32 api\n}" (primitive_type) "void" (function_declarator) "clear_sh()" (identifier) "clear_sh" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n system("clear || cls"); // compatible with both POSIX and WIN32 api\n}" ({) "{" (expression_statement) "system("clear || cls");" (call_expression) "system("clear || cls")" (identifier) "system" (argument_list) "("clear || cls")" (() "(" (string_literal) ""clear || cls"" (") """ (string_content) "clear || cls" (") """ ()) ")" (;) ";" (comment) "// compatible with both POSIX and WIN32 api" (}) "}"
378
0
{"language": "c", "success": true, "metadata": {"lines": 41, "avg_line_length": 24.61, "nodes": 252, "errors": 0, "source_hash": "aa92b34c90036d6e3ec6bf537a470a50f80b8868800bc317648f25b3c7a6a7fc", "categorized_nodes": 159}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <stdio.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<stdio.h>", "parent": 0, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 18}}, {"id": 3, "type": "preproc_include", "text": "#include <stdlib.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<stdlib.h>", "parent": 3, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 19}}, {"id": 6, "type": "preproc_include", "text": "#include <string.h>\n", "parent": null, "children": [7, 8], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<string.h>", "parent": 6, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 19}}, {"id": 9, "type": "preproc_include", "text": "#include \"member.h\"\n", "parent": null, "children": [10, 11], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"member.h\"", "parent": 9, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 19}}, {"id": 12, "type": "function_definition", "text": "void swap(int *a, int *b) {\n int tmp = *a;\n *a = *b;\n *b = tmp;\n}", "parent": null, "children": [13, 14], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 13, "type": "primitive_type", "text": "void", "parent": 12, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 4}}, {"id": 14, "type": "function_declarator", "text": "swap(int *a, int *b)", "parent": 12, "children": [15, 16], "start_point": {"row": 9, "column": 5}, "end_point": {"row": 9, "column": 25}}, {"id": 15, "type": "identifier", "text": "swap", "parent": 14, "children": [], "start_point": {"row": 9, "column": 5}, "end_point": {"row": 9, "column": 9}}, {"id": 16, "type": "parameter_list", "text": "(int *a, int *b)", "parent": 14, "children": [17, 22], "start_point": {"row": 9, "column": 9}, "end_point": {"row": 9, "column": 25}}, {"id": 17, "type": "parameter_declaration", "text": "int *a", "parent": 16, "children": [18, 19], "start_point": {"row": 9, "column": 10}, "end_point": {"row": 9, "column": 16}}, {"id": 18, "type": "primitive_type", "text": "int", "parent": 17, "children": [], "start_point": {"row": 9, "column": 10}, "end_point": {"row": 9, "column": 13}}, {"id": 19, "type": "pointer_declarator", "text": "*a", "parent": 17, "children": [20, 21], "start_point": {"row": 9, "column": 14}, "end_point": {"row": 9, "column": 16}}, {"id": 20, "type": "*", "text": "*", "parent": 19, "children": [], "start_point": {"row": 9, "column": 14}, "end_point": {"row": 9, "column": 15}}, {"id": 21, "type": "identifier", "text": "a", "parent": 19, "children": [], "start_point": {"row": 9, "column": 15}, "end_point": {"row": 9, "column": 16}}, {"id": 22, "type": "parameter_declaration", "text": "int *b", "parent": 16, "children": [23, 24], "start_point": {"row": 9, "column": 18}, "end_point": {"row": 9, "column": 24}}, {"id": 23, "type": "primitive_type", "text": "int", "parent": 22, "children": [], "start_point": {"row": 9, "column": 18}, "end_point": {"row": 9, "column": 21}}, {"id": 24, "type": "pointer_declarator", "text": "*b", "parent": 22, "children": [25, 26], "start_point": {"row": 9, "column": 22}, "end_point": {"row": 9, "column": 24}}, {"id": 25, "type": "*", "text": "*", "parent": 24, "children": [], "start_point": {"row": 9, "column": 22}, "end_point": {"row": 9, "column": 23}}, {"id": 26, "type": "identifier", "text": "b", "parent": 24, "children": [], "start_point": {"row": 9, "column": 23}, "end_point": {"row": 9, "column": 24}}, {"id": 27, "type": "declaration", "text": "int tmp = *a;", "parent": 12, "children": [28, 29], "start_point": {"row": 10, "column": 4}, "end_point": {"row": 10, "column": 17}}, {"id": 28, "type": "primitive_type", "text": "int", "parent": 27, "children": [], "start_point": {"row": 10, "column": 4}, "end_point": {"row": 10, "column": 7}}, {"id": 29, "type": "init_declarator", "text": "tmp = *a", "parent": 27, "children": [30, 31, 32], "start_point": {"row": 10, "column": 8}, "end_point": {"row": 10, "column": 16}}, {"id": 30, "type": "identifier", "text": "tmp", "parent": 29, "children": [], "start_point": {"row": 10, "column": 8}, "end_point": {"row": 10, "column": 11}}, {"id": 31, "type": "=", "text": "=", "parent": 29, "children": [], "start_point": {"row": 10, "column": 12}, "end_point": {"row": 10, "column": 13}}, {"id": 32, "type": "pointer_expression", "text": "*a", "parent": 29, "children": [33, 34], "start_point": {"row": 10, "column": 14}, "end_point": {"row": 10, "column": 16}}, {"id": 33, "type": "*", "text": "*", "parent": 32, "children": [], "start_point": {"row": 10, "column": 14}, "end_point": {"row": 10, "column": 15}}, {"id": 34, "type": "identifier", "text": "a", "parent": 32, "children": [], "start_point": {"row": 10, "column": 15}, "end_point": {"row": 10, "column": 16}}, {"id": 35, "type": "assignment_expression", "text": "*a = *b", "parent": 12, "children": [36, 39, 40], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 11}}, {"id": 36, "type": "pointer_expression", "text": "*a", "parent": 35, "children": [37, 38], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 6}}, {"id": 37, "type": "*", "text": "*", "parent": 36, "children": [], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 5}}, {"id": 38, "type": "identifier", "text": "a", "parent": 36, "children": [], "start_point": {"row": 11, "column": 5}, "end_point": {"row": 11, "column": 6}}, {"id": 39, "type": "=", "text": "=", "parent": 35, "children": [], "start_point": {"row": 11, "column": 7}, "end_point": {"row": 11, "column": 8}}, {"id": 40, "type": "pointer_expression", "text": "*b", "parent": 35, "children": [41, 42], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 11}}, {"id": 41, "type": "*", "text": "*", "parent": 40, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 10}}, {"id": 42, "type": "identifier", "text": "b", "parent": 40, "children": [], "start_point": {"row": 11, "column": 10}, "end_point": {"row": 11, "column": 11}}, {"id": 43, "type": "assignment_expression", "text": "*b = tmp", "parent": 12, "children": [44, 47, 48], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 12}}, {"id": 44, "type": "pointer_expression", "text": "*b", "parent": 43, "children": [45, 46], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 6}}, {"id": 45, "type": "*", "text": "*", "parent": 44, "children": [], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 5}}, {"id": 46, "type": "identifier", "text": "b", "parent": 44, "children": [], "start_point": {"row": 12, "column": 5}, "end_point": {"row": 12, "column": 6}}, {"id": 47, "type": "=", "text": "=", "parent": 43, "children": [], "start_point": {"row": 12, "column": 7}, "end_point": {"row": 12, "column": 8}}, {"id": 48, "type": "identifier", "text": "tmp", "parent": 43, "children": [], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 12}}, {"id": 49, "type": "function_definition", "text": "int get_int() {\n const long long MAXI = 0x7fffffff;\n static char buf[16];\n long long input_id = 0;\n scanf(\"%15s\", buf);\n for (int i = 0; i < (int)strlen(buf); ++i) {\n if (buf[i] >= '0' && buf[i] <= '9') // make sure inputs are valid\n input_id = input_id * 10 + buf[i] - '0';\n else\n return -1;\n }\n if (input_id > MAXI) return -1;\n return (int)input_id;\n}", "parent": null, "children": [50, 51], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 29, "column": 1}}, {"id": 50, "type": "primitive_type", "text": "int", "parent": 49, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 3}}, {"id": 51, "type": "function_declarator", "text": "get_int()", "parent": 49, "children": [52, 53], "start_point": {"row": 16, "column": 4}, "end_point": {"row": 16, "column": 13}}, {"id": 52, "type": "identifier", "text": "get_int", "parent": 51, "children": [], "start_point": {"row": 16, "column": 4}, "end_point": {"row": 16, "column": 11}}, {"id": 53, "type": "parameter_list", "text": "()", "parent": 51, "children": [], "start_point": {"row": 16, "column": 11}, "end_point": {"row": 16, "column": 13}}, {"id": 54, "type": "declaration", "text": "const long long MAXI = 0x7fffffff;", "parent": 49, "children": [55, 58], "start_point": {"row": 17, "column": 4}, "end_point": {"row": 17, "column": 38}}, {"id": 55, "type": "sized_type_specifier", "text": "long long", "parent": 54, "children": [56, 57], "start_point": {"row": 17, "column": 10}, "end_point": {"row": 17, "column": 19}}, {"id": 56, "type": "long", "text": "long", "parent": 55, "children": [], "start_point": {"row": 17, "column": 10}, "end_point": {"row": 17, "column": 14}}, {"id": 57, "type": "long", "text": "long", "parent": 55, "children": [], "start_point": {"row": 17, "column": 15}, "end_point": {"row": 17, "column": 19}}, {"id": 58, "type": "init_declarator", "text": "MAXI = 0x7fffffff", "parent": 54, "children": [59, 60, 61], "start_point": {"row": 17, "column": 20}, "end_point": {"row": 17, "column": 37}}, {"id": 59, "type": "identifier", "text": "MAXI", "parent": 58, "children": [], "start_point": {"row": 17, "column": 20}, "end_point": {"row": 17, "column": 24}}, {"id": 60, "type": "=", "text": "=", "parent": 58, "children": [], "start_point": {"row": 17, "column": 25}, "end_point": {"row": 17, "column": 26}}, {"id": 61, "type": "number_literal", "text": "0x7fffffff", "parent": 58, "children": [], "start_point": {"row": 17, "column": 27}, "end_point": {"row": 17, "column": 37}}, {"id": 62, "type": "declaration", "text": "static char buf[16];", "parent": 49, "children": [63, 64], "start_point": {"row": 18, "column": 4}, "end_point": {"row": 18, "column": 24}}, {"id": 63, "type": "primitive_type", "text": "char", "parent": 62, "children": [], "start_point": {"row": 18, "column": 11}, "end_point": {"row": 18, "column": 15}}, {"id": 64, "type": "array_declarator", "text": "buf[16]", "parent": 62, "children": [65, 66], "start_point": {"row": 18, "column": 16}, "end_point": {"row": 18, "column": 23}}, {"id": 65, "type": "identifier", "text": "buf", "parent": 64, "children": [], "start_point": {"row": 18, "column": 16}, "end_point": {"row": 18, "column": 19}}, {"id": 66, "type": "number_literal", "text": "16", "parent": 64, "children": [], "start_point": {"row": 18, "column": 20}, "end_point": {"row": 18, "column": 22}}, {"id": 67, "type": "declaration", "text": "long long input_id = 0;", "parent": 49, "children": [68, 71], "start_point": {"row": 19, "column": 4}, "end_point": {"row": 19, "column": 27}}, {"id": 68, "type": "sized_type_specifier", "text": "long long", "parent": 67, "children": [69, 70], "start_point": {"row": 19, "column": 4}, "end_point": {"row": 19, "column": 13}}, {"id": 69, "type": "long", "text": "long", "parent": 68, "children": [], "start_point": {"row": 19, "column": 4}, "end_point": {"row": 19, "column": 8}}, {"id": 70, "type": "long", "text": "long", "parent": 68, "children": [], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 13}}, {"id": 71, "type": "init_declarator", "text": "input_id = 0", "parent": 67, "children": [72, 73, 74], "start_point": {"row": 19, "column": 14}, "end_point": {"row": 19, "column": 26}}, {"id": 72, "type": "identifier", "text": "input_id", "parent": 71, "children": [], "start_point": {"row": 19, "column": 14}, "end_point": {"row": 19, "column": 22}}, {"id": 73, "type": "=", "text": "=", "parent": 71, "children": [], "start_point": {"row": 19, "column": 23}, "end_point": {"row": 19, "column": 24}}, {"id": 74, "type": "number_literal", "text": "0", "parent": 71, "children": [], "start_point": {"row": 19, "column": 25}, "end_point": {"row": 19, "column": 26}}, {"id": 75, "type": "call_expression", "text": "scanf(\"%15s\", buf)", "parent": 49, "children": [76, 77], "start_point": {"row": 20, "column": 4}, "end_point": {"row": 20, "column": 22}}, {"id": 76, "type": "identifier", "text": "scanf", "parent": 75, "children": [], "start_point": {"row": 20, "column": 4}, "end_point": {"row": 20, "column": 9}}, {"id": 77, "type": "argument_list", "text": "(\"%15s\", buf)", "parent": 75, "children": [78, 79], "start_point": {"row": 20, "column": 9}, "end_point": {"row": 20, "column": 22}}, {"id": 78, "type": "string_literal", "text": "\"%15s\"", "parent": 77, "children": [], "start_point": {"row": 20, "column": 10}, "end_point": {"row": 20, "column": 16}}, {"id": 79, "type": "identifier", "text": "buf", "parent": 77, "children": [], "start_point": {"row": 20, "column": 18}, "end_point": {"row": 20, "column": 21}}, {"id": 80, "type": "for_statement", "text": "for (int i = 0; i < (int)strlen(buf); ++i) {\n if (buf[i] >= '0' && buf[i] <= '9') // make sure inputs are valid\n input_id = input_id * 10 + buf[i] - '0';\n else\n return -1;\n }", "parent": 49, "children": [81, 87, 97], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 26, "column": 5}}, {"id": 81, "type": "declaration", "text": "int i = 0;", "parent": 80, "children": [82, 83], "start_point": {"row": 21, "column": 9}, "end_point": {"row": 21, "column": 19}}, {"id": 82, "type": "primitive_type", "text": "int", "parent": 81, "children": [], "start_point": {"row": 21, "column": 9}, "end_point": {"row": 21, "column": 12}}, {"id": 83, "type": "init_declarator", "text": "i = 0", "parent": 81, "children": [84, 85, 86], "start_point": {"row": 21, "column": 13}, "end_point": {"row": 21, "column": 18}}, {"id": 84, "type": "identifier", "text": "i", "parent": 83, "children": [], "start_point": {"row": 21, "column": 13}, "end_point": {"row": 21, "column": 14}}, {"id": 85, "type": "=", "text": "=", "parent": 83, "children": [], "start_point": {"row": 21, "column": 15}, "end_point": {"row": 21, "column": 16}}, {"id": 86, "type": "number_literal", "text": "0", "parent": 83, "children": [], "start_point": {"row": 21, "column": 17}, "end_point": {"row": 21, "column": 18}}, {"id": 87, "type": "binary_expression", "text": "i < (int)strlen(buf)", "parent": 80, "children": [88, 89, 90], "start_point": {"row": 21, "column": 20}, "end_point": {"row": 21, "column": 40}}, {"id": 88, "type": "identifier", "text": "i", "parent": 87, "children": [], "start_point": {"row": 21, "column": 20}, "end_point": {"row": 21, "column": 21}}, {"id": 89, "type": "<", "text": "<", "parent": 87, "children": [], "start_point": {"row": 21, "column": 22}, "end_point": {"row": 21, "column": 23}}, {"id": 90, "type": "cast_expression", "text": "(int)strlen(buf)", "parent": 87, "children": [91, 93], "start_point": {"row": 21, "column": 24}, "end_point": {"row": 21, "column": 40}}, {"id": 91, "type": "type_descriptor", "text": "int", "parent": 90, "children": [92], "start_point": {"row": 21, "column": 25}, "end_point": {"row": 21, "column": 28}}, {"id": 92, "type": "primitive_type", "text": "int", "parent": 91, "children": [], "start_point": {"row": 21, "column": 25}, "end_point": {"row": 21, "column": 28}}, {"id": 93, "type": "call_expression", "text": "strlen(buf)", "parent": 90, "children": [94, 95], "start_point": {"row": 21, "column": 29}, "end_point": {"row": 21, "column": 40}}, {"id": 94, "type": "identifier", "text": "strlen", "parent": 93, "children": [], "start_point": {"row": 21, "column": 29}, "end_point": {"row": 21, "column": 35}}, {"id": 95, "type": "argument_list", "text": "(buf)", "parent": 93, "children": [96], "start_point": {"row": 21, "column": 35}, "end_point": {"row": 21, "column": 40}}, {"id": 96, "type": "identifier", "text": "buf", "parent": 95, "children": [], "start_point": {"row": 21, "column": 36}, "end_point": {"row": 21, "column": 39}}, {"id": 97, "type": "update_expression", "text": "++i", "parent": 80, "children": [98, 99], "start_point": {"row": 21, "column": 42}, "end_point": {"row": 21, "column": 45}}, {"id": 98, "type": "++", "text": "++", "parent": 97, "children": [], "start_point": {"row": 21, "column": 42}, "end_point": {"row": 21, "column": 44}}, {"id": 99, "type": "identifier", "text": "i", "parent": 97, "children": [], "start_point": {"row": 21, "column": 44}, "end_point": {"row": 21, "column": 45}}, {"id": 100, "type": "if_statement", "text": "if (buf[i] >= '0' && buf[i] <= '9') // make sure inputs are valid\n input_id = input_id * 10 + buf[i] - '0';\n else\n return -1;", "parent": 80, "children": [101, 140], "start_point": {"row": 22, "column": 8}, "end_point": {"row": 25, "column": 22}}, {"id": 101, "type": "parenthesized_expression", "text": "(buf[i] >= '0' && buf[i] <= '9')", "parent": 100, "children": [102], "start_point": {"row": 22, "column": 11}, "end_point": {"row": 22, "column": 43}}, {"id": 102, "type": "binary_expression", "text": "buf[i] >= '0' && buf[i] <= '9'", "parent": 101, "children": [103, 112, 113], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 42}}, {"id": 103, "type": "binary_expression", "text": "buf[i] >= '0'", "parent": 102, "children": [104, 107, 108], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 25}}, {"id": 104, "type": "subscript_expression", "text": "buf[i]", "parent": 103, "children": [105, 106], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 18}}, {"id": 105, "type": "identifier", "text": "buf", "parent": 104, "children": [], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 15}}, {"id": 106, "type": "identifier", "text": "i", "parent": 104, "children": [], "start_point": {"row": 22, "column": 16}, "end_point": {"row": 22, "column": 17}}, {"id": 107, "type": ">=", "text": ">=", "parent": 103, "children": [], "start_point": {"row": 22, "column": 19}, "end_point": {"row": 22, "column": 21}}, {"id": 108, "type": "char_literal", "text": "'0'", "parent": 103, "children": [109, 110, 111], "start_point": {"row": 22, "column": 22}, "end_point": {"row": 22, "column": 25}}, {"id": 109, "type": "'", "text": "'", "parent": 108, "children": [], "start_point": {"row": 22, "column": 22}, "end_point": {"row": 22, "column": 23}}, {"id": 110, "type": "character", "text": "0", "parent": 108, "children": [], "start_point": {"row": 22, "column": 23}, "end_point": {"row": 22, "column": 24}}, {"id": 111, "type": "'", "text": "'", "parent": 108, "children": [], "start_point": {"row": 22, "column": 24}, "end_point": {"row": 22, "column": 25}}, {"id": 112, "type": "&&", "text": "&&", "parent": 102, "children": [], "start_point": {"row": 22, "column": 26}, "end_point": {"row": 22, "column": 28}}, {"id": 113, "type": "binary_expression", "text": "buf[i] <= '9'", "parent": 102, "children": [114, 117, 118], "start_point": {"row": 22, "column": 29}, "end_point": {"row": 22, "column": 42}}, {"id": 114, "type": "subscript_expression", "text": "buf[i]", "parent": 113, "children": [115, 116], "start_point": {"row": 22, "column": 29}, "end_point": {"row": 22, "column": 35}}, {"id": 115, "type": "identifier", "text": "buf", "parent": 114, "children": [], "start_point": {"row": 22, "column": 29}, "end_point": {"row": 22, "column": 32}}, {"id": 116, "type": "identifier", "text": "i", "parent": 114, "children": [], "start_point": {"row": 22, "column": 33}, "end_point": {"row": 22, "column": 34}}, {"id": 117, "type": "<=", "text": "<=", "parent": 113, "children": [], "start_point": {"row": 22, "column": 36}, "end_point": {"row": 22, "column": 38}}, {"id": 118, "type": "char_literal", "text": "'9'", "parent": 113, "children": [119, 120, 121], "start_point": {"row": 22, "column": 39}, "end_point": {"row": 22, "column": 42}}, {"id": 119, "type": "'", "text": "'", "parent": 118, "children": [], "start_point": {"row": 22, "column": 39}, "end_point": {"row": 22, "column": 40}}, {"id": 120, "type": "character", "text": "9", "parent": 118, "children": [], "start_point": {"row": 22, "column": 40}, "end_point": {"row": 22, "column": 41}}, {"id": 121, "type": "'", "text": "'", "parent": 118, "children": [], "start_point": {"row": 22, "column": 41}, "end_point": {"row": 22, "column": 42}}, {"id": 122, "type": "assignment_expression", "text": "input_id = input_id * 10 + buf[i] - '0'", "parent": 100, "children": [123, 124, 125], "start_point": {"row": 23, "column": 12}, "end_point": {"row": 23, "column": 51}}, {"id": 123, "type": "identifier", "text": "input_id", "parent": 122, "children": [], "start_point": {"row": 23, "column": 12}, "end_point": {"row": 23, "column": 20}}, {"id": 124, "type": "=", "text": "=", "parent": 122, "children": [], "start_point": {"row": 23, "column": 21}, "end_point": {"row": 23, "column": 22}}, {"id": 125, "type": "binary_expression", "text": "input_id * 10 + buf[i] - '0'", "parent": 122, "children": [126, 135, 136], "start_point": {"row": 23, "column": 23}, "end_point": {"row": 23, "column": 51}}, {"id": 126, "type": "binary_expression", "text": "input_id * 10 + buf[i]", "parent": 125, "children": [127, 131, 132], "start_point": {"row": 23, "column": 23}, "end_point": {"row": 23, "column": 45}}, {"id": 127, "type": "binary_expression", "text": "input_id * 10", "parent": 126, "children": [128, 129, 130], "start_point": {"row": 23, "column": 23}, "end_point": {"row": 23, "column": 36}}, {"id": 128, "type": "identifier", "text": "input_id", "parent": 127, "children": [], "start_point": {"row": 23, "column": 23}, "end_point": {"row": 23, "column": 31}}, {"id": 129, "type": "*", "text": "*", "parent": 127, "children": [], "start_point": {"row": 23, "column": 32}, "end_point": {"row": 23, "column": 33}}, {"id": 130, "type": "number_literal", "text": "10", "parent": 127, "children": [], "start_point": {"row": 23, "column": 34}, "end_point": {"row": 23, "column": 36}}, {"id": 131, "type": "+", "text": "+", "parent": 126, "children": [], "start_point": {"row": 23, "column": 37}, "end_point": {"row": 23, "column": 38}}, {"id": 132, "type": "subscript_expression", "text": "buf[i]", "parent": 126, "children": [133, 134], "start_point": {"row": 23, "column": 39}, "end_point": {"row": 23, "column": 45}}, {"id": 133, "type": "identifier", "text": "buf", "parent": 132, "children": [], "start_point": {"row": 23, "column": 39}, "end_point": {"row": 23, "column": 42}}, {"id": 134, "type": "identifier", "text": "i", "parent": 132, "children": [], "start_point": {"row": 23, "column": 43}, "end_point": {"row": 23, "column": 44}}, {"id": 135, "type": "-", "text": "-", "parent": 125, "children": [], "start_point": {"row": 23, "column": 46}, "end_point": {"row": 23, "column": 47}}, {"id": 136, "type": "char_literal", "text": "'0'", "parent": 125, "children": [137, 138, 139], "start_point": {"row": 23, "column": 48}, "end_point": {"row": 23, "column": 51}}, {"id": 137, "type": "'", "text": "'", "parent": 136, "children": [], "start_point": {"row": 23, "column": 48}, "end_point": {"row": 23, "column": 49}}, {"id": 138, "type": "character", "text": "0", "parent": 136, "children": [], "start_point": {"row": 23, "column": 49}, "end_point": {"row": 23, "column": 50}}, {"id": 139, "type": "'", "text": "'", "parent": 136, "children": [], "start_point": {"row": 23, "column": 50}, "end_point": {"row": 23, "column": 51}}, {"id": 140, "type": "else_clause", "text": "else\n return -1;", "parent": 100, "children": [141], "start_point": {"row": 24, "column": 8}, "end_point": {"row": 25, "column": 22}}, {"id": 141, "type": "return_statement", "text": "return -1;", "parent": 140, "children": [142], "start_point": {"row": 25, "column": 12}, "end_point": {"row": 25, "column": 22}}, {"id": 142, "type": "number_literal", "text": "-1", "parent": 141, "children": [], "start_point": {"row": 25, "column": 19}, "end_point": {"row": 25, "column": 21}}, {"id": 143, "type": "if_statement", "text": "if (input_id > MAXI) return -1;", "parent": 49, "children": [144, 149], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 35}}, {"id": 144, "type": "parenthesized_expression", "text": "(input_id > MAXI)", "parent": 143, "children": [145], "start_point": {"row": 27, "column": 7}, "end_point": {"row": 27, "column": 24}}, {"id": 145, "type": "binary_expression", "text": "input_id > MAXI", "parent": 144, "children": [146, 147, 148], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 23}}, {"id": 146, "type": "identifier", "text": "input_id", "parent": 145, "children": [], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 16}}, {"id": 147, "type": ">", "text": ">", "parent": 145, "children": [], "start_point": {"row": 27, "column": 17}, "end_point": {"row": 27, "column": 18}}, {"id": 148, "type": "identifier", "text": "MAXI", "parent": 145, "children": [], "start_point": {"row": 27, "column": 19}, "end_point": {"row": 27, "column": 23}}, {"id": 149, "type": "return_statement", "text": "return -1;", "parent": 143, "children": [150], "start_point": {"row": 27, "column": 25}, "end_point": {"row": 27, "column": 35}}, {"id": 150, "type": "number_literal", "text": "-1", "parent": 149, "children": [], "start_point": {"row": 27, "column": 32}, "end_point": {"row": 27, "column": 34}}, {"id": 151, "type": "return_statement", "text": "return (int)input_id;", "parent": 49, "children": [152], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 28, "column": 25}}, {"id": 152, "type": "cast_expression", "text": "(int)input_id", "parent": 151, "children": [153, 155], "start_point": {"row": 28, "column": 11}, "end_point": {"row": 28, "column": 24}}, {"id": 153, "type": "type_descriptor", "text": "int", "parent": 152, "children": [154], "start_point": {"row": 28, "column": 12}, "end_point": {"row": 28, "column": 15}}, {"id": 154, "type": "primitive_type", "text": "int", "parent": 153, "children": [], "start_point": {"row": 28, "column": 12}, "end_point": {"row": 28, "column": 15}}, {"id": 155, "type": "identifier", "text": "input_id", "parent": 152, "children": [], "start_point": {"row": 28, "column": 16}, "end_point": {"row": 28, "column": 24}}, {"id": 156, "type": "function_definition", "text": "int my_getline(FILE *stream, char *string, int size) {\n int p = 0;\n char c = fgetc(stream);\n while (c != '\\n' && c != EOF && size--) {\n string[p++] = c;\n c = fgetc(stream);\n }\n string[p] = '\\0';\n if (c == EOF) return -1;\n return 0;\n}", "parent": null, "children": [157, 158], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 41, "column": 1}}, {"id": 157, "type": "primitive_type", "text": "int", "parent": 156, "children": [], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 31, "column": 3}}, {"id": 158, "type": "function_declarator", "text": "my_getline(FILE *stream, char *string, int size)", "parent": 156, "children": [159, 160], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 52}}, {"id": 159, "type": "identifier", "text": "my_getline", "parent": 158, "children": [], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 14}}, {"id": 160, "type": "parameter_list", "text": "(FILE *stream, char *string, int size)", "parent": 158, "children": [161, 166, 171], "start_point": {"row": 31, "column": 14}, "end_point": {"row": 31, "column": 52}}, {"id": 161, "type": "parameter_declaration", "text": "FILE *stream", "parent": 160, "children": [162, 163], "start_point": {"row": 31, "column": 15}, "end_point": {"row": 31, "column": 27}}, {"id": 162, "type": "type_identifier", "text": "FILE", "parent": 161, "children": [], "start_point": {"row": 31, "column": 15}, "end_point": {"row": 31, "column": 19}}, {"id": 163, "type": "pointer_declarator", "text": "*stream", "parent": 161, "children": [164, 165], "start_point": {"row": 31, "column": 20}, "end_point": {"row": 31, "column": 27}}, {"id": 164, "type": "*", "text": "*", "parent": 163, "children": [], "start_point": {"row": 31, "column": 20}, "end_point": {"row": 31, "column": 21}}, {"id": 165, "type": "identifier", "text": "stream", "parent": 163, "children": [], "start_point": {"row": 31, "column": 21}, "end_point": {"row": 31, "column": 27}}, {"id": 166, "type": "parameter_declaration", "text": "char *string", "parent": 160, "children": [167, 168], "start_point": {"row": 31, "column": 29}, "end_point": {"row": 31, "column": 41}}, {"id": 167, "type": "primitive_type", "text": "char", "parent": 166, "children": [], "start_point": {"row": 31, "column": 29}, "end_point": {"row": 31, "column": 33}}, {"id": 168, "type": "pointer_declarator", "text": "*string", "parent": 166, "children": [169, 170], "start_point": {"row": 31, "column": 34}, "end_point": {"row": 31, "column": 41}}, {"id": 169, "type": "*", "text": "*", "parent": 168, "children": [], "start_point": {"row": 31, "column": 34}, "end_point": {"row": 31, "column": 35}}, {"id": 170, "type": "identifier", "text": "string", "parent": 168, "children": [], "start_point": {"row": 31, "column": 35}, "end_point": {"row": 31, "column": 41}}, {"id": 171, "type": "parameter_declaration", "text": "int size", "parent": 160, "children": [172, 173], "start_point": {"row": 31, "column": 43}, "end_point": {"row": 31, "column": 51}}, {"id": 172, "type": "primitive_type", "text": "int", "parent": 171, "children": [], "start_point": {"row": 31, "column": 43}, "end_point": {"row": 31, "column": 46}}, {"id": 173, "type": "identifier", "text": "size", "parent": 171, "children": [], "start_point": {"row": 31, "column": 47}, "end_point": {"row": 31, "column": 51}}, {"id": 174, "type": "declaration", "text": "int p = 0;", "parent": 156, "children": [175, 176], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 32, "column": 14}}, {"id": 175, "type": "primitive_type", "text": "int", "parent": 174, "children": [], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 32, "column": 7}}, {"id": 176, "type": "init_declarator", "text": "p = 0", "parent": 174, "children": [177, 178, 179], "start_point": {"row": 32, "column": 8}, "end_point": {"row": 32, "column": 13}}, {"id": 177, "type": "identifier", "text": "p", "parent": 176, "children": [], "start_point": {"row": 32, "column": 8}, "end_point": {"row": 32, "column": 9}}, {"id": 178, "type": "=", "text": "=", "parent": 176, "children": [], "start_point": {"row": 32, "column": 10}, "end_point": {"row": 32, "column": 11}}, {"id": 179, "type": "number_literal", "text": "0", "parent": 176, "children": [], "start_point": {"row": 32, "column": 12}, "end_point": {"row": 32, "column": 13}}, {"id": 180, "type": "declaration", "text": "char c = fgetc(stream);", "parent": 156, "children": [181, 182], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 27}}, {"id": 181, "type": "primitive_type", "text": "char", "parent": 180, "children": [], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 8}}, {"id": 182, "type": "init_declarator", "text": "c = fgetc(stream)", "parent": 180, "children": [183, 184, 185], "start_point": {"row": 33, "column": 9}, "end_point": {"row": 33, "column": 26}}, {"id": 183, "type": "identifier", "text": "c", "parent": 182, "children": [], "start_point": {"row": 33, "column": 9}, "end_point": {"row": 33, "column": 10}}, {"id": 184, "type": "=", "text": "=", "parent": 182, "children": [], "start_point": {"row": 33, "column": 11}, "end_point": {"row": 33, "column": 12}}, {"id": 185, "type": "call_expression", "text": "fgetc(stream)", "parent": 182, "children": [186, 187], "start_point": {"row": 33, "column": 13}, "end_point": {"row": 33, "column": 26}}, {"id": 186, "type": "identifier", "text": "fgetc", "parent": 185, "children": [], "start_point": {"row": 33, "column": 13}, "end_point": {"row": 33, "column": 18}}, {"id": 187, "type": "argument_list", "text": "(stream)", "parent": 185, "children": [188], "start_point": {"row": 33, "column": 18}, "end_point": {"row": 33, "column": 26}}, {"id": 188, "type": "identifier", "text": "stream", "parent": 187, "children": [], "start_point": {"row": 33, "column": 19}, "end_point": {"row": 33, "column": 25}}, {"id": 189, "type": "while_statement", "text": "while (c != '\\n' && c != EOF && size--) {\n string[p++] = c;\n c = fgetc(stream);\n }", "parent": 156, "children": [190], "start_point": {"row": 34, "column": 4}, "end_point": {"row": 37, "column": 5}}, {"id": 190, "type": "parenthesized_expression", "text": "(c != '\\n' && c != EOF && size--)", "parent": 189, "children": [191], "start_point": {"row": 34, "column": 10}, "end_point": {"row": 34, "column": 43}}, {"id": 191, "type": "binary_expression", "text": "c != '\\n' && c != EOF && size--", "parent": 190, "children": [192, 205, 206], "start_point": {"row": 34, "column": 11}, "end_point": {"row": 34, "column": 42}}, {"id": 192, "type": "binary_expression", "text": "c != '\\n' && c != EOF", "parent": 191, "children": [193, 200, 201], "start_point": {"row": 34, "column": 11}, "end_point": {"row": 34, "column": 32}}, {"id": 193, "type": "binary_expression", "text": "c != '\\n'", "parent": 192, "children": [194, 195, 196], "start_point": {"row": 34, "column": 11}, "end_point": {"row": 34, "column": 20}}, {"id": 194, "type": "identifier", "text": "c", "parent": 193, "children": [], "start_point": {"row": 34, "column": 11}, "end_point": {"row": 34, "column": 12}}, {"id": 195, "type": "!=", "text": "!=", "parent": 193, "children": [], "start_point": {"row": 34, "column": 13}, "end_point": {"row": 34, "column": 15}}, {"id": 196, "type": "char_literal", "text": "'\\n'", "parent": 193, "children": [197, 198, 199], "start_point": {"row": 34, "column": 16}, "end_point": {"row": 34, "column": 20}}, {"id": 197, "type": "'", "text": "'", "parent": 196, "children": [], "start_point": {"row": 34, "column": 16}, "end_point": {"row": 34, "column": 17}}, {"id": 198, "type": "escape_sequence", "text": "\\n", "parent": 196, "children": [], "start_point": {"row": 34, "column": 17}, "end_point": {"row": 34, "column": 19}}, {"id": 199, "type": "'", "text": "'", "parent": 196, "children": [], "start_point": {"row": 34, "column": 19}, "end_point": {"row": 34, "column": 20}}, {"id": 200, "type": "&&", "text": "&&", "parent": 192, "children": [], "start_point": {"row": 34, "column": 21}, "end_point": {"row": 34, "column": 23}}, {"id": 201, "type": "binary_expression", "text": "c != EOF", "parent": 192, "children": [202, 203, 204], "start_point": {"row": 34, "column": 24}, "end_point": {"row": 34, "column": 32}}, {"id": 202, "type": "identifier", "text": "c", "parent": 201, "children": [], "start_point": {"row": 34, "column": 24}, "end_point": {"row": 34, "column": 25}}, {"id": 203, "type": "!=", "text": "!=", "parent": 201, "children": [], "start_point": {"row": 34, "column": 26}, "end_point": {"row": 34, "column": 28}}, {"id": 204, "type": "identifier", "text": "EOF", "parent": 201, "children": [], "start_point": {"row": 34, "column": 29}, "end_point": {"row": 34, "column": 32}}, {"id": 205, "type": "&&", "text": "&&", "parent": 191, "children": [], "start_point": {"row": 34, "column": 33}, "end_point": {"row": 34, "column": 35}}, {"id": 206, "type": "update_expression", "text": "size--", "parent": 191, "children": [207, 208], "start_point": {"row": 34, "column": 36}, "end_point": {"row": 34, "column": 42}}, {"id": 207, "type": "identifier", "text": "size", "parent": 206, "children": [], "start_point": {"row": 34, "column": 36}, "end_point": {"row": 34, "column": 40}}, {"id": 208, "type": "--", "text": "--", "parent": 206, "children": [], "start_point": {"row": 34, "column": 40}, "end_point": {"row": 34, "column": 42}}, {"id": 209, "type": "assignment_expression", "text": "string[p++] = c", "parent": 189, "children": [210, 215, 216], "start_point": {"row": 35, "column": 8}, "end_point": {"row": 35, "column": 23}}, {"id": 210, "type": "subscript_expression", "text": "string[p++]", "parent": 209, "children": [211, 212], "start_point": {"row": 35, "column": 8}, "end_point": {"row": 35, "column": 19}}, {"id": 211, "type": "identifier", "text": "string", "parent": 210, "children": [], "start_point": {"row": 35, "column": 8}, "end_point": {"row": 35, "column": 14}}, {"id": 212, "type": "update_expression", "text": "p++", "parent": 210, "children": [213, 214], "start_point": {"row": 35, "column": 15}, "end_point": {"row": 35, "column": 18}}, {"id": 213, "type": "identifier", "text": "p", "parent": 212, "children": [], "start_point": {"row": 35, "column": 15}, "end_point": {"row": 35, "column": 16}}, {"id": 214, "type": "++", "text": "++", "parent": 212, "children": [], "start_point": {"row": 35, "column": 16}, "end_point": {"row": 35, "column": 18}}, {"id": 215, "type": "=", "text": "=", "parent": 209, "children": [], "start_point": {"row": 35, "column": 20}, "end_point": {"row": 35, "column": 21}}, {"id": 216, "type": "identifier", "text": "c", "parent": 209, "children": [], "start_point": {"row": 35, "column": 22}, "end_point": {"row": 35, "column": 23}}, {"id": 217, "type": "assignment_expression", "text": "c = fgetc(stream)", "parent": 189, "children": [218, 219, 220], "start_point": {"row": 36, "column": 8}, "end_point": {"row": 36, "column": 25}}, {"id": 218, "type": "identifier", "text": "c", "parent": 217, "children": [], "start_point": {"row": 36, "column": 8}, "end_point": {"row": 36, "column": 9}}, {"id": 219, "type": "=", "text": "=", "parent": 217, "children": [], "start_point": {"row": 36, "column": 10}, "end_point": {"row": 36, "column": 11}}, {"id": 220, "type": "call_expression", "text": "fgetc(stream)", "parent": 217, "children": [221, 222], "start_point": {"row": 36, "column": 12}, "end_point": {"row": 36, "column": 25}}, {"id": 221, "type": "identifier", "text": "fgetc", "parent": 220, "children": [], "start_point": {"row": 36, "column": 12}, "end_point": {"row": 36, "column": 17}}, {"id": 222, "type": "argument_list", "text": "(stream)", "parent": 220, "children": [223], "start_point": {"row": 36, "column": 17}, "end_point": {"row": 36, "column": 25}}, {"id": 223, "type": "identifier", "text": "stream", "parent": 222, "children": [], "start_point": {"row": 36, "column": 18}, "end_point": {"row": 36, "column": 24}}, {"id": 224, "type": "assignment_expression", "text": "string[p] = '\\0'", "parent": 156, "children": [225, 228, 229], "start_point": {"row": 38, "column": 4}, "end_point": {"row": 38, "column": 20}}, {"id": 225, "type": "subscript_expression", "text": "string[p]", "parent": 224, "children": [226, 227], "start_point": {"row": 38, "column": 4}, "end_point": {"row": 38, "column": 13}}, {"id": 226, "type": "identifier", "text": "string", "parent": 225, "children": [], "start_point": {"row": 38, "column": 4}, "end_point": {"row": 38, "column": 10}}, {"id": 227, "type": "identifier", "text": "p", "parent": 225, "children": [], "start_point": {"row": 38, "column": 11}, "end_point": {"row": 38, "column": 12}}, {"id": 228, "type": "=", "text": "=", "parent": 224, "children": [], "start_point": {"row": 38, "column": 14}, "end_point": {"row": 38, "column": 15}}, {"id": 229, "type": "char_literal", "text": "'\\0'", "parent": 224, "children": [230, 231, 232], "start_point": {"row": 38, "column": 16}, "end_point": {"row": 38, "column": 20}}, {"id": 230, "type": "'", "text": "'", "parent": 229, "children": [], "start_point": {"row": 38, "column": 16}, "end_point": {"row": 38, "column": 17}}, {"id": 231, "type": "escape_sequence", "text": "\\0", "parent": 229, "children": [], "start_point": {"row": 38, "column": 17}, "end_point": {"row": 38, "column": 19}}, {"id": 232, "type": "'", "text": "'", "parent": 229, "children": [], "start_point": {"row": 38, "column": 19}, "end_point": {"row": 38, "column": 20}}, {"id": 233, "type": "if_statement", "text": "if (c == EOF) return -1;", "parent": 156, "children": [234, 239], "start_point": {"row": 39, "column": 4}, "end_point": {"row": 39, "column": 28}}, {"id": 234, "type": "parenthesized_expression", "text": "(c == EOF)", "parent": 233, "children": [235], "start_point": {"row": 39, "column": 7}, "end_point": {"row": 39, "column": 17}}, {"id": 235, "type": "binary_expression", "text": "c == EOF", "parent": 234, "children": [236, 237, 238], "start_point": {"row": 39, "column": 8}, "end_point": {"row": 39, "column": 16}}, {"id": 236, "type": "identifier", "text": "c", "parent": 235, "children": [], "start_point": {"row": 39, "column": 8}, "end_point": {"row": 39, "column": 9}}, {"id": 237, "type": "==", "text": "==", "parent": 235, "children": [], "start_point": {"row": 39, "column": 10}, "end_point": {"row": 39, "column": 12}}, {"id": 238, "type": "identifier", "text": "EOF", "parent": 235, "children": [], "start_point": {"row": 39, "column": 13}, "end_point": {"row": 39, "column": 16}}, {"id": 239, "type": "return_statement", "text": "return -1;", "parent": 233, "children": [240], "start_point": {"row": 39, "column": 18}, "end_point": {"row": 39, "column": 28}}, {"id": 240, "type": "number_literal", "text": "-1", "parent": 239, "children": [], "start_point": {"row": 39, "column": 25}, "end_point": {"row": 39, "column": 27}}, {"id": 241, "type": "return_statement", "text": "return 0;", "parent": 156, "children": [242], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 40, "column": 13}}, {"id": 242, "type": "number_literal", "text": "0", "parent": 241, "children": [], "start_point": {"row": 40, "column": 11}, "end_point": {"row": 40, "column": 12}}, {"id": 243, "type": "function_definition", "text": "void clear_sh() {\n system(\"clear || cls\"); // compatible with both POSIX and WIN32 api\n}", "parent": null, "children": [244, 245], "start_point": {"row": 44, "column": 0}, "end_point": {"row": 46, "column": 1}}, {"id": 244, "type": "primitive_type", "text": "void", "parent": 243, "children": [], "start_point": {"row": 44, "column": 0}, "end_point": {"row": 44, "column": 4}}, {"id": 245, "type": "function_declarator", "text": "clear_sh()", "parent": 243, "children": [246, 247], "start_point": {"row": 44, "column": 5}, "end_point": {"row": 44, "column": 15}}, {"id": 246, "type": "identifier", "text": "clear_sh", "parent": 245, "children": [], "start_point": {"row": 44, "column": 5}, "end_point": {"row": 44, "column": 13}}, {"id": 247, "type": "parameter_list", "text": "()", "parent": 245, "children": [], "start_point": {"row": 44, "column": 13}, "end_point": {"row": 44, "column": 15}}, {"id": 248, "type": "call_expression", "text": "system(\"clear || cls\")", "parent": 243, "children": [249, 250], "start_point": {"row": 45, "column": 4}, "end_point": {"row": 45, "column": 26}}, {"id": 249, "type": "identifier", "text": "system", "parent": 248, "children": [], "start_point": {"row": 45, "column": 4}, "end_point": {"row": 45, "column": 10}}, {"id": 250, "type": "argument_list", "text": "(\"clear || cls\")", "parent": 248, "children": [251], "start_point": {"row": 45, "column": 10}, "end_point": {"row": 45, "column": 26}}, {"id": 251, "type": "string_literal", "text": "\"clear || cls\"", "parent": 250, "children": [], "start_point": {"row": 45, "column": 11}, "end_point": {"row": 45, "column": 25}}]}, "node_categories": {"declarations": {"functions": [12, 14, 49, 51, 156, 158, 243, 245], "variables": [17, 22, 27, 54, 62, 67, 81, 161, 166, 171, 174, 180], "classes": [], "imports": [0, 1, 3, 4, 6, 7, 9, 10], "modules": [], "enums": []}, "statements": {"expressions": [32, 36, 40, 44, 75, 87, 90, 93, 97, 101, 102, 103, 104, 113, 114, 125, 126, 127, 132, 144, 145, 152, 185, 190, 191, 192, 193, 201, 206, 210, 212, 220, 225, 234, 235, 248], "assignments": [35, 43, 122, 209, 217, 224], "loops": [80, 189], "conditionals": [15, 21, 26, 30, 34, 38, 42, 46, 48, 52, 55, 59, 65, 68, 72, 76, 79, 84, 88, 94, 96, 99, 100, 105, 106, 115, 116, 123, 128, 133, 134, 143, 146, 148, 155, 159, 162, 165, 170, 173, 177, 183, 186, 188, 194, 202, 204, 207, 211, 213, 216, 218, 221, 223, 226, 227, 233, 236, 238, 246, 249], "returns": [141, 149, 151, 239, 241], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 8, 11, 61, 66, 74, 78, 86, 108, 118, 130, 136, 142, 150, 179, 196, 229, 240, 242, 251], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 12, "universal_type": "function", "name": "swap", "text_snippet": "void swap(int *a, int *b) {\n int tmp = *a;\n *a = *b;\n *b = tmp;\n}"}, {"node_id": 14, "universal_type": "function", "name": "*b)", "text_snippet": "swap(int *a, int *b)"}, {"node_id": 49, "universal_type": "function", "name": "get_int", "text_snippet": "int get_int() {\n const long long MAXI = 0x7fffffff;\n static char buf[16];\n long long input_"}, {"node_id": 51, "universal_type": "function", "name": "unknown", "text_snippet": "get_int()"}, {"node_id": 156, "universal_type": "function", "name": "my_getline", "text_snippet": "int my_getline(FILE *stream, char *string, int size) {\n int p = 0;\n char c = fgetc(stream);\n "}, {"node_id": 158, "universal_type": "function", "name": "size)", "text_snippet": "my_getline(FILE *stream, char *string, int size)"}, {"node_id": 243, "universal_type": "function", "name": "clear_sh", "text_snippet": "void clear_sh() {\n system(\"clear || cls\"); // compatible with both POSIX and WIN32 api\n}"}, {"node_id": 245, "universal_type": "function", "name": "unknown", "text_snippet": "clear_sh()"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <stdio.h>\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <stdlib.h>\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include <string.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include \"member.h\"\n"}, {"node_id": 10, "text": "#include"}]}, "original_source_code": "// utilities that being used frequently\n\n#include <stdio.h>\n#include <stdlib.h>\n#include <string.h>\n\n#include \"member.h\"\n\n// swap two integer\nvoid swap(int *a, int *b) {\n int tmp = *a;\n *a = *b;\n *b = tmp;\n}\n\n// safely get an integer from stdin\nint get_int() {\n const long long MAXI = 0x7fffffff;\n static char buf[16];\n long long input_id = 0;\n scanf(\"%15s\", buf);\n for (int i = 0; i < (int)strlen(buf); ++i) {\n if (buf[i] >= '0' && buf[i] <= '9') // make sure inputs are valid\n input_id = input_id * 10 + buf[i] - '0';\n else\n return -1;\n }\n if (input_id > MAXI) return -1;\n return (int)input_id;\n}\n\nint my_getline(FILE *stream, char *string, int size) {\n int p = 0;\n char c = fgetc(stream);\n while (c != '\\n' && c != EOF && size--) {\n string[p++] = c;\n c = fgetc(stream);\n }\n string[p] = '\\0';\n if (c == EOF) return -1;\n return 0;\n}\n\n// clear shell content\nvoid clear_sh() {\n system(\"clear || cls\"); // compatible with both POSIX and WIN32 api\n}\n"}
80,553
c
#ifndef __LINK_LIST_H__ #define __LINK_LIST_H__ typedef struct _LIST_ENTRY { struct _LIST_ENTRY *pNext; } LIST_ENTRY, *PLIST_ENTRY; typedef struct _LIST_HEADR { PLIST_ENTRY pHead; PLIST_ENTRY pTail; UCHAR size; } LIST_HEADER, *PLIST_HEADER; static inline VOID initList( IN PLIST_HEADER pList) { pList->pHead = pList->pTail = NULL; pList->size = 0; return; } static inline VOID insertTailList( IN PLIST_HEADER pList, IN PLIST_ENTRY pEntry) { pEntry->pNext = NULL; if (pList->pTail) pList->pTail->pNext = pEntry; else pList->pHead = pEntry; pList->pTail = pEntry; pList->size++; return; } static inline PLIST_ENTRY removeHeadList( IN PLIST_HEADER pList) { PLIST_ENTRY pNext; PLIST_ENTRY pEntry; pEntry = pList->pHead; if (pList->pHead != NULL) { pNext = pList->pHead->pNext; pList->pHead = pNext; if (pNext == NULL) pList->pTail = NULL; pList->size--; } return pEntry; } static inline int getListSize( IN PLIST_HEADER pList) { return pList->size; } static inline PLIST_ENTRY delEntryList( IN PLIST_HEADER pList, IN PLIST_ENTRY pEntry) { PLIST_ENTRY pCurEntry; PLIST_ENTRY pPrvEntry; if(pList->pHead == NULL) return NULL; if(pEntry == pList->pHead) { pCurEntry = pList->pHead; pList->pHead = pCurEntry->pNext; if(pList->pHead == NULL) pList->pTail = NULL; pList->size--; return pCurEntry; } pPrvEntry = pList->pHead; pCurEntry = pPrvEntry->pNext; while(pCurEntry != NULL) { if (pEntry == pCurEntry) { pPrvEntry->pNext = pCurEntry->pNext; if(pEntry == pList->pTail) pList->pTail = pPrvEntry; pList->size--; break; } pPrvEntry = pCurEntry; pCurEntry = pPrvEntry->pNext; } return pCurEntry; } #endif // ___LINK_LIST_H__ //
18.47
88
(translation_unit) "#ifndef __LINK_LIST_H__\n#define __LINK_LIST_H__\n\ntypedef struct _LIST_ENTRY\n{\n struct _LIST_ENTRY *pNext;\n} LIST_ENTRY, *PLIST_ENTRY;\n\ntypedef struct _LIST_HEADR\n{\n PLIST_ENTRY pHead;\n PLIST_ENTRY pTail;\n UCHAR size;\n} LIST_HEADER, *PLIST_HEADER;\n\nstatic inline VOID initList(\n IN PLIST_HEADER pList)\n{\n pList->pHead = pList->pTail = NULL;\n pList->size = 0;\n return;\n}\n\nstatic inline VOID insertTailList(\n IN PLIST_HEADER pList,\n IN PLIST_ENTRY pEntry)\n{\n pEntry->pNext = NULL;\n if (pList->pTail)\n pList->pTail->pNext = pEntry;\n else\n pList->pHead = pEntry;\n pList->pTail = pEntry;\n pList->size++;\n\n return;\n}\n\nstatic inline PLIST_ENTRY removeHeadList(\n IN PLIST_HEADER pList)\n{\n PLIST_ENTRY pNext;\n PLIST_ENTRY pEntry;\n\n pEntry = pList->pHead;\n if (pList->pHead != NULL)\n {\n pNext = pList->pHead->pNext;\n pList->pHead = pNext;\n if (pNext == NULL)\n pList->pTail = NULL;\n pList->size--;\n }\n return pEntry;\n}\n\nstatic inline int getListSize(\n IN PLIST_HEADER pList)\n{\n return pList->size;\n}\n\nstatic inline PLIST_ENTRY delEntryList(\n IN PLIST_HEADER pList,\n IN PLIST_ENTRY pEntry)\n{\n PLIST_ENTRY pCurEntry;\n PLIST_ENTRY pPrvEntry;\n\n if(pList->pHead == NULL)\n return NULL;\n\n if(pEntry == pList->pHead)\n {\n pCurEntry = pList->pHead;\n pList->pHead = pCurEntry->pNext;\n\n if(pList->pHead == NULL)\n pList->pTail = NULL;\n\n pList->size--;\n return pCurEntry;\n }\n\n pPrvEntry = pList->pHead;\n pCurEntry = pPrvEntry->pNext;\n while(pCurEntry != NULL)\n {\n if (pEntry == pCurEntry)\n {\n pPrvEntry->pNext = pCurEntry->pNext;\n\n if(pEntry == pList->pTail)\n pList->pTail = pPrvEntry;\n\n pList->size--;\n break;\n }\n pPrvEntry = pCurEntry;\n pCurEntry = pPrvEntry->pNext;\n }\n\n return pCurEntry;\n}\n\n#endif // ___LINK_LIST_H__ //\n\n" (preproc_ifdef) "#ifndef __LINK_LIST_H__\n#define __LINK_LIST_H__\n\ntypedef struct _LIST_ENTRY\n{\n struct _LIST_ENTRY *pNext;\n} LIST_ENTRY, *PLIST_ENTRY;\n\ntypedef struct _LIST_HEADR\n{\n PLIST_ENTRY pHead;\n PLIST_ENTRY pTail;\n UCHAR size;\n} LIST_HEADER, *PLIST_HEADER;\n\nstatic inline VOID initList(\n IN PLIST_HEADER pList)\n{\n pList->pHead = pList->pTail = NULL;\n pList->size = 0;\n return;\n}\n\nstatic inline VOID insertTailList(\n IN PLIST_HEADER pList,\n IN PLIST_ENTRY pEntry)\n{\n pEntry->pNext = NULL;\n if (pList->pTail)\n pList->pTail->pNext = pEntry;\n else\n pList->pHead = pEntry;\n pList->pTail = pEntry;\n pList->size++;\n\n return;\n}\n\nstatic inline PLIST_ENTRY removeHeadList(\n IN PLIST_HEADER pList)\n{\n PLIST_ENTRY pNext;\n PLIST_ENTRY pEntry;\n\n pEntry = pList->pHead;\n if (pList->pHead != NULL)\n {\n pNext = pList->pHead->pNext;\n pList->pHead = pNext;\n if (pNext == NULL)\n pList->pTail = NULL;\n pList->size--;\n }\n return pEntry;\n}\n\nstatic inline int getListSize(\n IN PLIST_HEADER pList)\n{\n return pList->size;\n}\n\nstatic inline PLIST_ENTRY delEntryList(\n IN PLIST_HEADER pList,\n IN PLIST_ENTRY pEntry)\n{\n PLIST_ENTRY pCurEntry;\n PLIST_ENTRY pPrvEntry;\n\n if(pList->pHead == NULL)\n return NULL;\n\n if(pEntry == pList->pHead)\n {\n pCurEntry = pList->pHead;\n pList->pHead = pCurEntry->pNext;\n\n if(pList->pHead == NULL)\n pList->pTail = NULL;\n\n pList->size--;\n return pCurEntry;\n }\n\n pPrvEntry = pList->pHead;\n pCurEntry = pPrvEntry->pNext;\n while(pCurEntry != NULL)\n {\n if (pEntry == pCurEntry)\n {\n pPrvEntry->pNext = pCurEntry->pNext;\n\n if(pEntry == pList->pTail)\n pList->pTail = pPrvEntry;\n\n pList->size--;\n break;\n }\n pPrvEntry = pCurEntry;\n pCurEntry = pPrvEntry->pNext;\n }\n\n return pCurEntry;\n}\n\n#endif" (#ifndef) "#ifndef" (identifier) "__LINK_LIST_H__" (preproc_def) "#define __LINK_LIST_H__\n" (#define) "#define" (identifier) "__LINK_LIST_H__" (type_definition) "typedef struct _LIST_ENTRY\n{\n struct _LIST_ENTRY *pNext;\n} LIST_ENTRY, *PLIST_ENTRY;" (typedef) "typedef" (struct_specifier) "struct _LIST_ENTRY\n{\n struct _LIST_ENTRY *pNext;\n}" (struct) "struct" (type_identifier) "_LIST_ENTRY" (field_declaration_list) "{\n struct _LIST_ENTRY *pNext;\n}" ({) "{" (field_declaration) "struct _LIST_ENTRY *pNext;" (struct_specifier) "struct _LIST_ENTRY" (struct) "struct" (type_identifier) "_LIST_ENTRY" (pointer_declarator) "*pNext" (*) "*" (field_identifier) "pNext" (;) ";" (}) "}" (type_identifier) "LIST_ENTRY" (,) "," (pointer_declarator) "*PLIST_ENTRY" (*) "*" (type_identifier) "PLIST_ENTRY" (;) ";" (type_definition) "typedef struct _LIST_HEADR\n{\n PLIST_ENTRY pHead;\n PLIST_ENTRY pTail;\n UCHAR size;\n} LIST_HEADER, *PLIST_HEADER;" (typedef) "typedef" (struct_specifier) "struct _LIST_HEADR\n{\n PLIST_ENTRY pHead;\n PLIST_ENTRY pTail;\n UCHAR size;\n}" (struct) "struct" (type_identifier) "_LIST_HEADR" (field_declaration_list) "{\n PLIST_ENTRY pHead;\n PLIST_ENTRY pTail;\n UCHAR size;\n}" ({) "{" (field_declaration) "PLIST_ENTRY pHead;" (type_identifier) "PLIST_ENTRY" (field_identifier) "pHead" (;) ";" (field_declaration) "PLIST_ENTRY pTail;" (type_identifier) "PLIST_ENTRY" (field_identifier) "pTail" (;) ";" (field_declaration) "UCHAR size;" (type_identifier) "UCHAR" (field_identifier) "size" (;) ";" (}) "}" (type_identifier) "LIST_HEADER" (,) "," (pointer_declarator) "*PLIST_HEADER" (*) "*" (type_identifier) "PLIST_HEADER" (;) ";" (function_definition) "static inline VOID initList(\n IN PLIST_HEADER pList)\n{\n pList->pHead = pList->pTail = NULL;\n pList->size = 0;\n return;\n}" (storage_class_specifier) "static" (static) "static" (storage_class_specifier) "inline" (inline) "inline" (type_identifier) "VOID" (function_declarator) "initList(\n IN PLIST_HEADER pList)" (identifier) "initList" (parameter_list) "(\n IN PLIST_HEADER pList)" (() "(" (parameter_declaration) "IN PLIST_HEADER" (type_identifier) "IN" (identifier) "PLIST_HEADER" (ERROR) "pList" (identifier) "pList" ()) ")" (compound_statement) "{\n pList->pHead = pList->pTail = NULL;\n pList->size = 0;\n return;\n}" ({) "{" (expression_statement) "pList->pHead = pList->pTail = NULL;" (assignment_expression) "pList->pHead = pList->pTail = NULL" (field_expression) "pList->pHead" (identifier) "pList" (->) "->" (field_identifier) "pHead" (=) "=" (assignment_expression) "pList->pTail = NULL" (field_expression) "pList->pTail" (identifier) "pList" (->) "->" (field_identifier) "pTail" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (expression_statement) "pList->size = 0;" (assignment_expression) "pList->size = 0" (field_expression) "pList->size" (identifier) "pList" (->) "->" (field_identifier) "size" (=) "=" (number_literal) "0" (;) ";" (return_statement) "return;" (return) "return" (;) ";" (}) "}" (function_definition) "static inline VOID insertTailList(\n IN PLIST_HEADER pList,\n IN PLIST_ENTRY pEntry)\n{\n pEntry->pNext = NULL;\n if (pList->pTail)\n pList->pTail->pNext = pEntry;\n else\n pList->pHead = pEntry;\n pList->pTail = pEntry;\n pList->size++;\n\n return;\n}" (storage_class_specifier) "static" (static) "static" (storage_class_specifier) "inline" (inline) "inline" (type_identifier) "VOID" (function_declarator) "insertTailList(\n IN PLIST_HEADER pList,\n IN PLIST_ENTRY pEntry)" (identifier) "insertTailList" (parameter_list) "(\n IN PLIST_HEADER pList,\n IN PLIST_ENTRY pEntry)" (() "(" (parameter_declaration) "IN PLIST_HEADER" (type_identifier) "IN" (identifier) "PLIST_HEADER" (ERROR) "pList" (identifier) "pList" (,) "," (parameter_declaration) "IN PLIST_ENTRY" (type_identifier) "IN" (identifier) "PLIST_ENTRY" (ERROR) "pEntry" (identifier) "pEntry" ()) ")" (compound_statement) "{\n pEntry->pNext = NULL;\n if (pList->pTail)\n pList->pTail->pNext = pEntry;\n else\n pList->pHead = pEntry;\n pList->pTail = pEntry;\n pList->size++;\n\n return;\n}" ({) "{" (expression_statement) "pEntry->pNext = NULL;" (assignment_expression) "pEntry->pNext = NULL" (field_expression) "pEntry->pNext" (identifier) "pEntry" (->) "->" (field_identifier) "pNext" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (if_statement) "if (pList->pTail)\n pList->pTail->pNext = pEntry;\n else\n pList->pHead = pEntry;" (if) "if" (parenthesized_expression) "(pList->pTail)" (() "(" (field_expression) "pList->pTail" (identifier) "pList" (->) "->" (field_identifier) "pTail" ()) ")" (expression_statement) "pList->pTail->pNext = pEntry;" (assignment_expression) "pList->pTail->pNext = pEntry" (field_expression) "pList->pTail->pNext" (field_expression) "pList->pTail" (identifier) "pList" (->) "->" (field_identifier) "pTail" (->) "->" (field_identifier) "pNext" (=) "=" (identifier) "pEntry" (;) ";" (else_clause) "else\n pList->pHead = pEntry;" (else) "else" (expression_statement) "pList->pHead = pEntry;" (assignment_expression) "pList->pHead = pEntry" (field_expression) "pList->pHead" (identifier) "pList" (->) "->" (field_identifier) "pHead" (=) "=" (identifier) "pEntry" (;) ";" (expression_statement) "pList->pTail = pEntry;" (assignment_expression) "pList->pTail = pEntry" (field_expression) "pList->pTail" (identifier) "pList" (->) "->" (field_identifier) "pTail" (=) "=" (identifier) "pEntry" (;) ";" (expression_statement) "pList->size++;" (update_expression) "pList->size++" (field_expression) "pList->size" (identifier) "pList" (->) "->" (field_identifier) "size" (++) "++" (;) ";" (return_statement) "return;" (return) "return" (;) ";" (}) "}" (function_definition) "static inline PLIST_ENTRY removeHeadList(\n IN PLIST_HEADER pList)\n{\n PLIST_ENTRY pNext;\n PLIST_ENTRY pEntry;\n\n pEntry = pList->pHead;\n if (pList->pHead != NULL)\n {\n pNext = pList->pHead->pNext;\n pList->pHead = pNext;\n if (pNext == NULL)\n pList->pTail = NULL;\n pList->size--;\n }\n return pEntry;\n}" (storage_class_specifier) "static" (static) "static" (storage_class_specifier) "inline" (inline) "inline" (type_identifier) "PLIST_ENTRY" (function_declarator) "removeHeadList(\n IN PLIST_HEADER pList)" (identifier) "removeHeadList" (parameter_list) "(\n IN PLIST_HEADER pList)" (() "(" (parameter_declaration) "IN PLIST_HEADER" (type_identifier) "IN" (identifier) "PLIST_HEADER" (ERROR) "pList" (identifier) "pList" ()) ")" (compound_statement) "{\n PLIST_ENTRY pNext;\n PLIST_ENTRY pEntry;\n\n pEntry = pList->pHead;\n if (pList->pHead != NULL)\n {\n pNext = pList->pHead->pNext;\n pList->pHead = pNext;\n if (pNext == NULL)\n pList->pTail = NULL;\n pList->size--;\n }\n return pEntry;\n}" ({) "{" (declaration) "PLIST_ENTRY pNext;" (type_identifier) "PLIST_ENTRY" (identifier) "pNext" (;) ";" (declaration) "PLIST_ENTRY pEntry;" (type_identifier) "PLIST_ENTRY" (identifier) "pEntry" (;) ";" (expression_statement) "pEntry = pList->pHead;" (assignment_expression) "pEntry = pList->pHead" (identifier) "pEntry" (=) "=" (field_expression) "pList->pHead" (identifier) "pList" (->) "->" (field_identifier) "pHead" (;) ";" (if_statement) "if (pList->pHead != NULL)\n {\n pNext = pList->pHead->pNext;\n pList->pHead = pNext;\n if (pNext == NULL)\n pList->pTail = NULL;\n pList->size--;\n }" (if) "if" (parenthesized_expression) "(pList->pHead != NULL)" (() "(" (binary_expression) "pList->pHead != NULL" (field_expression) "pList->pHead" (identifier) "pList" (->) "->" (field_identifier) "pHead" (!=) "!=" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{\n pNext = pList->pHead->pNext;\n pList->pHead = pNext;\n if (pNext == NULL)\n pList->pTail = NULL;\n pList->size--;\n }" ({) "{" (expression_statement) "pNext = pList->pHead->pNext;" (assignment_expression) "pNext = pList->pHead->pNext" (identifier) "pNext" (=) "=" (field_expression) "pList->pHead->pNext" (field_expression) "pList->pHead" (identifier) "pList" (->) "->" (field_identifier) "pHead" (->) "->" (field_identifier) "pNext" (;) ";" (expression_statement) "pList->pHead = pNext;" (assignment_expression) "pList->pHead = pNext" (field_expression) "pList->pHead" (identifier) "pList" (->) "->" (field_identifier) "pHead" (=) "=" (identifier) "pNext" (;) ";" (if_statement) "if (pNext == NULL)\n pList->pTail = NULL;" (if) "if" (parenthesized_expression) "(pNext == NULL)" (() "(" (binary_expression) "pNext == NULL" (identifier) "pNext" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (expression_statement) "pList->pTail = NULL;" (assignment_expression) "pList->pTail = NULL" (field_expression) "pList->pTail" (identifier) "pList" (->) "->" (field_identifier) "pTail" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (expression_statement) "pList->size--;" (update_expression) "pList->size--" (field_expression) "pList->size" (identifier) "pList" (->) "->" (field_identifier) "size" (--) "--" (;) ";" (}) "}" (return_statement) "return pEntry;" (return) "return" (identifier) "pEntry" (;) ";" (}) "}" (function_definition) "static inline int getListSize(\n IN PLIST_HEADER pList)\n{\n return pList->size;\n}" (storage_class_specifier) "static" (static) "static" (storage_class_specifier) "inline" (inline) "inline" (primitive_type) "int" (function_declarator) "getListSize(\n IN PLIST_HEADER pList)" (identifier) "getListSize" (parameter_list) "(\n IN PLIST_HEADER pList)" (() "(" (parameter_declaration) "IN PLIST_HEADER" (type_identifier) "IN" (identifier) "PLIST_HEADER" (ERROR) "pList" (identifier) "pList" ()) ")" (compound_statement) "{\n return pList->size;\n}" ({) "{" (return_statement) "return pList->size;" (return) "return" (field_expression) "pList->size" (identifier) "pList" (->) "->" (field_identifier) "size" (;) ";" (}) "}" (function_definition) "static inline PLIST_ENTRY delEntryList(\n IN PLIST_HEADER pList,\n IN PLIST_ENTRY pEntry)\n{\n PLIST_ENTRY pCurEntry;\n PLIST_ENTRY pPrvEntry;\n\n if(pList->pHead == NULL)\n return NULL;\n\n if(pEntry == pList->pHead)\n {\n pCurEntry = pList->pHead;\n pList->pHead = pCurEntry->pNext;\n\n if(pList->pHead == NULL)\n pList->pTail = NULL;\n\n pList->size--;\n return pCurEntry;\n }\n\n pPrvEntry = pList->pHead;\n pCurEntry = pPrvEntry->pNext;\n while(pCurEntry != NULL)\n {\n if (pEntry == pCurEntry)\n {\n pPrvEntry->pNext = pCurEntry->pNext;\n\n if(pEntry == pList->pTail)\n pList->pTail = pPrvEntry;\n\n pList->size--;\n break;\n }\n pPrvEntry = pCurEntry;\n pCurEntry = pPrvEntry->pNext;\n }\n\n return pCurEntry;\n}" (storage_class_specifier) "static" (static) "static" (storage_class_specifier) "inline" (inline) "inline" (type_identifier) "PLIST_ENTRY" (function_declarator) "delEntryList(\n IN PLIST_HEADER pList,\n IN PLIST_ENTRY pEntry)" (identifier) "delEntryList" (parameter_list) "(\n IN PLIST_HEADER pList,\n IN PLIST_ENTRY pEntry)" (() "(" (parameter_declaration) "IN PLIST_HEADER" (type_identifier) "IN" (identifier) "PLIST_HEADER" (ERROR) "pList" (identifier) "pList" (,) "," (parameter_declaration) "IN PLIST_ENTRY" (type_identifier) "IN" (identifier) "PLIST_ENTRY" (ERROR) "pEntry" (identifier) "pEntry" ()) ")" (compound_statement) "{\n PLIST_ENTRY pCurEntry;\n PLIST_ENTRY pPrvEntry;\n\n if(pList->pHead == NULL)\n return NULL;\n\n if(pEntry == pList->pHead)\n {\n pCurEntry = pList->pHead;\n pList->pHead = pCurEntry->pNext;\n\n if(pList->pHead == NULL)\n pList->pTail = NULL;\n\n pList->size--;\n return pCurEntry;\n }\n\n pPrvEntry = pList->pHead;\n pCurEntry = pPrvEntry->pNext;\n while(pCurEntry != NULL)\n {\n if (pEntry == pCurEntry)\n {\n pPrvEntry->pNext = pCurEntry->pNext;\n\n if(pEntry == pList->pTail)\n pList->pTail = pPrvEntry;\n\n pList->size--;\n break;\n }\n pPrvEntry = pCurEntry;\n pCurEntry = pPrvEntry->pNext;\n }\n\n return pCurEntry;\n}" ({) "{" (declaration) "PLIST_ENTRY pCurEntry;" (type_identifier) "PLIST_ENTRY" (identifier) "pCurEntry" (;) ";" (declaration) "PLIST_ENTRY pPrvEntry;" (type_identifier) "PLIST_ENTRY" (identifier) "pPrvEntry" (;) ";" (if_statement) "if(pList->pHead == NULL)\n return NULL;" (if) "if" (parenthesized_expression) "(pList->pHead == NULL)" (() "(" (binary_expression) "pList->pHead == NULL" (field_expression) "pList->pHead" (identifier) "pList" (->) "->" (field_identifier) "pHead" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (return_statement) "return NULL;" (return) "return" (null) "NULL" (NULL) "NULL" (;) ";" (if_statement) "if(pEntry == pList->pHead)\n {\n pCurEntry = pList->pHead;\n pList->pHead = pCurEntry->pNext;\n\n if(pList->pHead == NULL)\n pList->pTail = NULL;\n\n pList->size--;\n return pCurEntry;\n }" (if) "if" (parenthesized_expression) "(pEntry == pList->pHead)" (() "(" (binary_expression) "pEntry == pList->pHead" (identifier) "pEntry" (==) "==" (field_expression) "pList->pHead" (identifier) "pList" (->) "->" (field_identifier) "pHead" ()) ")" (compound_statement) "{\n pCurEntry = pList->pHead;\n pList->pHead = pCurEntry->pNext;\n\n if(pList->pHead == NULL)\n pList->pTail = NULL;\n\n pList->size--;\n return pCurEntry;\n }" ({) "{" (expression_statement) "pCurEntry = pList->pHead;" (assignment_expression) "pCurEntry = pList->pHead" (identifier) "pCurEntry" (=) "=" (field_expression) "pList->pHead" (identifier) "pList" (->) "->" (field_identifier) "pHead" (;) ";" (expression_statement) "pList->pHead = pCurEntry->pNext;" (assignment_expression) "pList->pHead = pCurEntry->pNext" (field_expression) "pList->pHead" (identifier) "pList" (->) "->" (field_identifier) "pHead" (=) "=" (field_expression) "pCurEntry->pNext" (identifier) "pCurEntry" (->) "->" (field_identifier) "pNext" (;) ";" (if_statement) "if(pList->pHead == NULL)\n pList->pTail = NULL;" (if) "if" (parenthesized_expression) "(pList->pHead == NULL)" (() "(" (binary_expression) "pList->pHead == NULL" (field_expression) "pList->pHead" (identifier) "pList" (->) "->" (field_identifier) "pHead" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (expression_statement) "pList->pTail = NULL;" (assignment_expression) "pList->pTail = NULL" (field_expression) "pList->pTail" (identifier) "pList" (->) "->" (field_identifier) "pTail" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (expression_statement) "pList->size--;" (update_expression) "pList->size--" (field_expression) "pList->size" (identifier) "pList" (->) "->" (field_identifier) "size" (--) "--" (;) ";" (return_statement) "return pCurEntry;" (return) "return" (identifier) "pCurEntry" (;) ";" (}) "}" (expression_statement) "pPrvEntry = pList->pHead;" (assignment_expression) "pPrvEntry = pList->pHead" (identifier) "pPrvEntry" (=) "=" (field_expression) "pList->pHead" (identifier) "pList" (->) "->" (field_identifier) "pHead" (;) ";" (expression_statement) "pCurEntry = pPrvEntry->pNext;" (assignment_expression) "pCurEntry = pPrvEntry->pNext" (identifier) "pCurEntry" (=) "=" (field_expression) "pPrvEntry->pNext" (identifier) "pPrvEntry" (->) "->" (field_identifier) "pNext" (;) ";" (while_statement) "while(pCurEntry != NULL)\n {\n if (pEntry == pCurEntry)\n {\n pPrvEntry->pNext = pCurEntry->pNext;\n\n if(pEntry == pList->pTail)\n pList->pTail = pPrvEntry;\n\n pList->size--;\n break;\n }\n pPrvEntry = pCurEntry;\n pCurEntry = pPrvEntry->pNext;\n }" (while) "while" (parenthesized_expression) "(pCurEntry != NULL)" (() "(" (binary_expression) "pCurEntry != NULL" (identifier) "pCurEntry" (!=) "!=" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{\n if (pEntry == pCurEntry)\n {\n pPrvEntry->pNext = pCurEntry->pNext;\n\n if(pEntry == pList->pTail)\n pList->pTail = pPrvEntry;\n\n pList->size--;\n break;\n }\n pPrvEntry = pCurEntry;\n pCurEntry = pPrvEntry->pNext;\n }" ({) "{" (if_statement) "if (pEntry == pCurEntry)\n {\n pPrvEntry->pNext = pCurEntry->pNext;\n\n if(pEntry == pList->pTail)\n pList->pTail = pPrvEntry;\n\n pList->size--;\n break;\n }" (if) "if" (parenthesized_expression) "(pEntry == pCurEntry)" (() "(" (binary_expression) "pEntry == pCurEntry" (identifier) "pEntry" (==) "==" (identifier) "pCurEntry" ()) ")" (compound_statement) "{\n pPrvEntry->pNext = pCurEntry->pNext;\n\n if(pEntry == pList->pTail)\n pList->pTail = pPrvEntry;\n\n pList->size--;\n break;\n }" ({) "{" (expression_statement) "pPrvEntry->pNext = pCurEntry->pNext;" (assignment_expression) "pPrvEntry->pNext = pCurEntry->pNext" (field_expression) "pPrvEntry->pNext" (identifier) "pPrvEntry" (->) "->" (field_identifier) "pNext" (=) "=" (field_expression) "pCurEntry->pNext" (identifier) "pCurEntry" (->) "->" (field_identifier) "pNext" (;) ";" (if_statement) "if(pEntry == pList->pTail)\n pList->pTail = pPrvEntry;" (if) "if" (parenthesized_expression) "(pEntry == pList->pTail)" (() "(" (binary_expression) "pEntry == pList->pTail" (identifier) "pEntry" (==) "==" (field_expression) "pList->pTail" (identifier) "pList" (->) "->" (field_identifier) "pTail" ()) ")" (expression_statement) "pList->pTail = pPrvEntry;" (assignment_expression) "pList->pTail = pPrvEntry" (field_expression) "pList->pTail" (identifier) "pList" (->) "->" (field_identifier) "pTail" (=) "=" (identifier) "pPrvEntry" (;) ";" (expression_statement) "pList->size--;" (update_expression) "pList->size--" (field_expression) "pList->size" (identifier) "pList" (->) "->" (field_identifier) "size" (--) "--" (;) ";" (break_statement) "break;" (break) "break" (;) ";" (}) "}" (expression_statement) "pPrvEntry = pCurEntry;" (assignment_expression) "pPrvEntry = pCurEntry" (identifier) "pPrvEntry" (=) "=" (identifier) "pCurEntry" (;) ";" (expression_statement) "pCurEntry = pPrvEntry->pNext;" (assignment_expression) "pCurEntry = pPrvEntry->pNext" (identifier) "pCurEntry" (=) "=" (field_expression) "pPrvEntry->pNext" (identifier) "pPrvEntry" (->) "->" (field_identifier) "pNext" (;) ";" (}) "}" (return_statement) "return pCurEntry;" (return) "return" (identifier) "pCurEntry" (;) ";" (}) "}" (#endif) "#endif" (comment) "// ___LINK_LIST_H__ //"
550
7
{"language": "c", "success": true, "metadata": {"lines": 88, "avg_line_length": 18.47, "nodes": 358, "errors": 0, "source_hash": "eb3f8af28fd98fc99e3ac76d485199409b56fd5638cfd619ff004d0271b1b02f", "categorized_nodes": 275}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef __LINK_LIST_H__\n#define __LINK_LIST_H__\n\ntypedef struct _LIST_ENTRY\n{\n\tstruct _LIST_ENTRY *pNext;\n} LIST_ENTRY, *PLIST_ENTRY;\n\ntypedef struct _LIST_HEADR\n{\n\tPLIST_ENTRY pHead;\n\tPLIST_ENTRY pTail;\n\tUCHAR size;\n} LIST_HEADER, *PLIST_HEADER;\n\nstatic inline VOID initList(\n\tIN PLIST_HEADER pList)\n{\n\tpList->pHead = pList->pTail = NULL;\n\tpList->size = 0;\n\treturn;\n}\n\nstatic inline VOID insertTailList(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)\n{\n\tpEntry->pNext = NULL;\n\tif (pList->pTail)\n\t\tpList->pTail->pNext = pEntry;\n\telse\n\t\tpList->pHead = pEntry;\n\tpList->pTail = pEntry;\n\tpList->size++;\n\n\treturn;\n}\n\nstatic inline PLIST_ENTRY removeHeadList(\n\tIN PLIST_HEADER pList)\n{\n\tPLIST_ENTRY pNext;\n\tPLIST_ENTRY pEntry;\n\n\tpEntry = pList->pHead;\n\tif (pList->pHead != NULL)\n\t{\n\t\tpNext = pList->pHead->pNext;\n\t\tpList->pHead = pNext;\n\t\tif (pNext == NULL)\n\t\t\tpList->pTail = NULL;\n\t\tpList->size--;\n\t}\n\treturn pEntry;\n}\n\nstatic inline int getListSize(\n\tIN PLIST_HEADER pList)\n{\n\treturn pList->size;\n}\n\nstatic inline PLIST_ENTRY delEntryList(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)\n{\n\tPLIST_ENTRY pCurEntry;\n\tPLIST_ENTRY pPrvEntry;\n\n\tif(pList->pHead == NULL)\n\t\treturn NULL;\n\n\tif(pEntry == pList->pHead)\n\t{\n\t\tpCurEntry = pList->pHead;\n\t\tpList->pHead = pCurEntry->pNext;\n\n\t\tif(pList->pHead == NULL)\n\t\t\tpList->pTail = NULL;\n\n\t\tpList->size--;\n\t\treturn pCurEntry;\n\t}\n\n\tpPrvEntry = pList->pHead;\n\tpCurEntry = pPrvEntry->pNext;\n\twhile(pCurEntry != NULL)\n\t{\n\t\tif (pEntry == pCurEntry)\n\t\t{\n\t\t\tpPrvEntry->pNext = pCurEntry->pNext;\n\n\t\t\tif(pEntry == pList->pTail)\n\t\t\t\tpList->pTail = pPrvEntry;\n\n\t\t\tpList->size--;\n\t\t\tbreak;\n\t\t}\n\t\tpPrvEntry = pCurEntry;\n\t\tpCurEntry = pPrvEntry->pNext;\n\t}\n\n\treturn pCurEntry;\n}\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 22, 40, 71, 127, 195, 211, 357], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 106, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 2, "type": "identifier", "text": "__LINK_LIST_H__", "parent": 0, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 23}}, {"id": 3, "type": "preproc_def", "text": "#define __LINK_LIST_H__\n", "parent": 0, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 7}}, {"id": 5, "type": "identifier", "text": "__LINK_LIST_H__", "parent": 3, "children": [], "start_point": {"row": 2, "column": 8}, "end_point": {"row": 2, "column": 23}}, {"id": 6, "type": "type_definition", "text": "typedef struct _LIST_ENTRY\n{\n\tstruct _LIST_ENTRY *pNext;\n} LIST_ENTRY, *PLIST_ENTRY;", "parent": 0, "children": [7, 8, 18, 19], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 7, "column": 27}}, {"id": 7, "type": "typedef", "text": "typedef", "parent": 6, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 7}}, {"id": 8, "type": "struct_specifier", "text": "struct _LIST_ENTRY\n{\n\tstruct _LIST_ENTRY *pNext;\n}", "parent": 6, "children": [9, 10], "start_point": {"row": 4, "column": 8}, "end_point": {"row": 7, "column": 1}}, {"id": 9, "type": "struct", "text": "struct", "parent": 8, "children": [], "start_point": {"row": 4, "column": 8}, "end_point": {"row": 4, "column": 14}}, {"id": 10, "type": "type_identifier", "text": "_LIST_ENTRY", "parent": 8, "children": [], "start_point": {"row": 4, "column": 15}, "end_point": {"row": 4, "column": 26}}, {"id": 11, "type": "field_declaration", "text": "struct _LIST_ENTRY *pNext;", "parent": 8, "children": [12, 15], "start_point": {"row": 6, "column": 1}, "end_point": {"row": 6, "column": 27}}, {"id": 12, "type": "struct_specifier", "text": "struct _LIST_ENTRY", "parent": 11, "children": [13, 14], "start_point": {"row": 6, "column": 1}, "end_point": {"row": 6, "column": 19}}, {"id": 13, "type": "struct", "text": "struct", "parent": 12, "children": [], "start_point": {"row": 6, "column": 1}, "end_point": {"row": 6, "column": 7}}, {"id": 14, "type": "type_identifier", "text": "_LIST_ENTRY", "parent": 12, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 19}}, {"id": 15, "type": "pointer_declarator", "text": "*pNext", "parent": 11, "children": [16, 17], "start_point": {"row": 6, "column": 20}, "end_point": {"row": 6, "column": 26}}, {"id": 16, "type": "*", "text": "*", "parent": 15, "children": [], "start_point": {"row": 6, "column": 20}, "end_point": {"row": 6, "column": 21}}, {"id": 17, "type": "field_identifier", "text": "pNext", "parent": 15, "children": [], "start_point": {"row": 6, "column": 21}, "end_point": {"row": 6, "column": 26}}, {"id": 18, "type": "type_identifier", "text": "LIST_ENTRY", "parent": 6, "children": [], "start_point": {"row": 7, "column": 2}, "end_point": {"row": 7, "column": 12}}, {"id": 19, "type": "pointer_declarator", "text": "*PLIST_ENTRY", "parent": 6, "children": [20, 21], "start_point": {"row": 7, "column": 14}, "end_point": {"row": 7, "column": 26}}, {"id": 20, "type": "*", "text": "*", "parent": 19, "children": [], "start_point": {"row": 7, "column": 14}, "end_point": {"row": 7, "column": 15}}, {"id": 21, "type": "type_identifier", "text": "PLIST_ENTRY", "parent": 19, "children": [], "start_point": {"row": 7, "column": 15}, "end_point": {"row": 7, "column": 26}}, {"id": 22, "type": "type_definition", "text": "typedef struct _LIST_HEADR\n{\n\tPLIST_ENTRY pHead;\n\tPLIST_ENTRY pTail;\n\tUCHAR size;\n} LIST_HEADER, *PLIST_HEADER;", "parent": 0, "children": [23, 24, 36, 37], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 14, "column": 29}}, {"id": 23, "type": "typedef", "text": "typedef", "parent": 22, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 7}}, {"id": 24, "type": "struct_specifier", "text": "struct _LIST_HEADR\n{\n\tPLIST_ENTRY pHead;\n\tPLIST_ENTRY pTail;\n\tUCHAR size;\n}", "parent": 22, "children": [25, 26], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 14, "column": 1}}, {"id": 25, "type": "struct", "text": "struct", "parent": 24, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 14}}, {"id": 26, "type": "type_identifier", "text": "_LIST_HEADR", "parent": 24, "children": [], "start_point": {"row": 9, "column": 15}, "end_point": {"row": 9, "column": 26}}, {"id": 27, "type": "field_declaration", "text": "PLIST_ENTRY pHead;", "parent": 24, "children": [28, 29], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 11, "column": 19}}, {"id": 28, "type": "type_identifier", "text": "PLIST_ENTRY", "parent": 27, "children": [], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 11, "column": 12}}, {"id": 29, "type": "field_identifier", "text": "pHead", "parent": 27, "children": [], "start_point": {"row": 11, "column": 13}, "end_point": {"row": 11, "column": 18}}, {"id": 30, "type": "field_declaration", "text": "PLIST_ENTRY pTail;", "parent": 24, "children": [31, 32], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 19}}, {"id": 31, "type": "type_identifier", "text": "PLIST_ENTRY", "parent": 30, "children": [], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 12}}, {"id": 32, "type": "field_identifier", "text": "pTail", "parent": 30, "children": [], "start_point": {"row": 12, "column": 13}, "end_point": {"row": 12, "column": 18}}, {"id": 33, "type": "field_declaration", "text": "UCHAR size;", "parent": 24, "children": [34, 35], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 12}}, {"id": 34, "type": "type_identifier", "text": "UCHAR", "parent": 33, "children": [], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 6}}, {"id": 35, "type": "field_identifier", "text": "size", "parent": 33, "children": [], "start_point": {"row": 13, "column": 7}, "end_point": {"row": 13, "column": 11}}, {"id": 36, "type": "type_identifier", "text": "LIST_HEADER", "parent": 22, "children": [], "start_point": {"row": 14, "column": 2}, "end_point": {"row": 14, "column": 13}}, {"id": 37, "type": "pointer_declarator", "text": "*PLIST_HEADER", "parent": 22, "children": [38, 39], "start_point": {"row": 14, "column": 15}, "end_point": {"row": 14, "column": 28}}, {"id": 38, "type": "*", "text": "*", "parent": 37, "children": [], "start_point": {"row": 14, "column": 15}, "end_point": {"row": 14, "column": 16}}, {"id": 39, "type": "type_identifier", "text": "PLIST_HEADER", "parent": 37, "children": [], "start_point": {"row": 14, "column": 16}, "end_point": {"row": 14, "column": 28}}, {"id": 40, "type": "function_definition", "text": "static inline VOID initList(\n\tIN PLIST_HEADER pList)\n{\n\tpList->pHead = pList->pTail = NULL;\n\tpList->size = 0;\n\treturn;\n}", "parent": 0, "children": [41, 43, 44], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 22, "column": 1}}, {"id": 41, "type": "storage_class_specifier", "text": "inline", "parent": 40, "children": [42], "start_point": {"row": 16, "column": 7}, "end_point": {"row": 16, "column": 13}}, {"id": 42, "type": "inline", "text": "inline", "parent": 41, "children": [], "start_point": {"row": 16, "column": 7}, "end_point": {"row": 16, "column": 13}}, {"id": 43, "type": "type_identifier", "text": "VOID", "parent": 40, "children": [], "start_point": {"row": 16, "column": 14}, "end_point": {"row": 16, "column": 18}}, {"id": 44, "type": "function_declarator", "text": "initList(\n\tIN PLIST_HEADER pList)", "parent": 40, "children": [45, 46], "start_point": {"row": 16, "column": 19}, "end_point": {"row": 17, "column": 23}}, {"id": 45, "type": "identifier", "text": "initList", "parent": 44, "children": [], "start_point": {"row": 16, "column": 19}, "end_point": {"row": 16, "column": 27}}, {"id": 46, "type": "parameter_list", "text": "(\n\tIN PLIST_HEADER pList)", "parent": 44, "children": [47, 50], "start_point": {"row": 16, "column": 27}, "end_point": {"row": 17, "column": 23}}, {"id": 47, "type": "parameter_declaration", "text": "IN PLIST_HEADER", "parent": 46, "children": [48, 49], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 16}}, {"id": 48, "type": "type_identifier", "text": "IN", "parent": 47, "children": [], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 3}}, {"id": 49, "type": "identifier", "text": "PLIST_HEADER", "parent": 47, "children": [], "start_point": {"row": 17, "column": 4}, "end_point": {"row": 17, "column": 16}}, {"id": 50, "type": "ERROR", "text": "pList", "parent": 46, "children": [51], "start_point": {"row": 17, "column": 17}, "end_point": {"row": 17, "column": 22}}, {"id": 51, "type": "identifier", "text": "pList", "parent": 50, "children": [], "start_point": {"row": 17, "column": 17}, "end_point": {"row": 17, "column": 22}}, {"id": 52, "type": "assignment_expression", "text": "pList->pHead = pList->pTail = NULL", "parent": 40, "children": [53, 56, 57], "start_point": {"row": 19, "column": 1}, "end_point": {"row": 19, "column": 35}}, {"id": 53, "type": "field_expression", "text": "pList->pHead", "parent": 52, "children": [54, 55], "start_point": {"row": 19, "column": 1}, "end_point": {"row": 19, "column": 13}}, {"id": 54, "type": "identifier", "text": "pList", "parent": 53, "children": [], "start_point": {"row": 19, "column": 1}, "end_point": {"row": 19, "column": 6}}, {"id": 55, "type": "field_identifier", "text": "pHead", "parent": 53, "children": [], "start_point": {"row": 19, "column": 8}, "end_point": {"row": 19, "column": 13}}, {"id": 56, "type": "=", "text": "=", "parent": 52, "children": [], "start_point": {"row": 19, "column": 14}, "end_point": {"row": 19, "column": 15}}, {"id": 57, "type": "assignment_expression", "text": "pList->pTail = NULL", "parent": 52, "children": [58, 61, 62], "start_point": {"row": 19, "column": 16}, "end_point": {"row": 19, "column": 35}}, {"id": 58, "type": "field_expression", "text": "pList->pTail", "parent": 57, "children": [59, 60], "start_point": {"row": 19, "column": 16}, "end_point": {"row": 19, "column": 28}}, {"id": 59, "type": "identifier", "text": "pList", "parent": 58, "children": [], "start_point": {"row": 19, "column": 16}, "end_point": {"row": 19, "column": 21}}, {"id": 60, "type": "field_identifier", "text": "pTail", "parent": 58, "children": [], "start_point": {"row": 19, "column": 23}, "end_point": {"row": 19, "column": 28}}, {"id": 61, "type": "=", "text": "=", "parent": 57, "children": [], "start_point": {"row": 19, "column": 29}, "end_point": {"row": 19, "column": 30}}, {"id": 62, "type": "null", "text": "NULL", "parent": 57, "children": [63], "start_point": {"row": 19, "column": 31}, "end_point": {"row": 19, "column": 35}}, {"id": 63, "type": "NULL", "text": "NULL", "parent": 62, "children": [], "start_point": {"row": 19, "column": 31}, "end_point": {"row": 19, "column": 35}}, {"id": 64, "type": "assignment_expression", "text": "pList->size = 0", "parent": 40, "children": [65, 68, 69], "start_point": {"row": 20, "column": 1}, "end_point": {"row": 20, "column": 16}}, {"id": 65, "type": "field_expression", "text": "pList->size", "parent": 64, "children": [66, 67], "start_point": {"row": 20, "column": 1}, "end_point": {"row": 20, "column": 12}}, {"id": 66, "type": "identifier", "text": "pList", "parent": 65, "children": [], "start_point": {"row": 20, "column": 1}, "end_point": {"row": 20, "column": 6}}, {"id": 67, "type": "field_identifier", "text": "size", "parent": 65, "children": [], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 12}}, {"id": 68, "type": "=", "text": "=", "parent": 64, "children": [], "start_point": {"row": 20, "column": 13}, "end_point": {"row": 20, "column": 14}}, {"id": 69, "type": "number_literal", "text": "0", "parent": 64, "children": [], "start_point": {"row": 20, "column": 15}, "end_point": {"row": 20, "column": 16}}, {"id": 70, "type": "return_statement", "text": "return;", "parent": 40, "children": [], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 8}}, {"id": 71, "type": "function_definition", "text": "static inline VOID insertTailList(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)\n{\n\tpEntry->pNext = NULL;\n\tif (pList->pTail)\n\t\tpList->pTail->pNext = pEntry;\n\telse\n\t\tpList->pHead = pEntry;\n\tpList->pTail = pEntry;\n\tpList->size++;\n\n\treturn;\n}", "parent": 0, "children": [72, 74, 75], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 37, "column": 1}}, {"id": 72, "type": "storage_class_specifier", "text": "inline", "parent": 71, "children": [73], "start_point": {"row": 24, "column": 7}, "end_point": {"row": 24, "column": 13}}, {"id": 73, "type": "inline", "text": "inline", "parent": 72, "children": [], "start_point": {"row": 24, "column": 7}, "end_point": {"row": 24, "column": 13}}, {"id": 74, "type": "type_identifier", "text": "VOID", "parent": 71, "children": [], "start_point": {"row": 24, "column": 14}, "end_point": {"row": 24, "column": 18}}, {"id": 75, "type": "function_declarator", "text": "insertTailList(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)", "parent": 71, "children": [76, 77], "start_point": {"row": 24, "column": 19}, "end_point": {"row": 26, "column": 23}}, {"id": 76, "type": "identifier", "text": "insertTailList", "parent": 75, "children": [], "start_point": {"row": 24, "column": 19}, "end_point": {"row": 24, "column": 33}}, {"id": 77, "type": "parameter_list", "text": "(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)", "parent": 75, "children": [78, 81, 83, 86], "start_point": {"row": 24, "column": 33}, "end_point": {"row": 26, "column": 23}}, {"id": 78, "type": "parameter_declaration", "text": "IN PLIST_HEADER", "parent": 77, "children": [79, 80], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 25, "column": 16}}, {"id": 79, "type": "type_identifier", "text": "IN", "parent": 78, "children": [], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 25, "column": 3}}, {"id": 80, "type": "identifier", "text": "PLIST_HEADER", "parent": 78, "children": [], "start_point": {"row": 25, "column": 4}, "end_point": {"row": 25, "column": 16}}, {"id": 81, "type": "ERROR", "text": "pList", "parent": 77, "children": [82], "start_point": {"row": 25, "column": 17}, "end_point": {"row": 25, "column": 22}}, {"id": 82, "type": "identifier", "text": "pList", "parent": 81, "children": [], "start_point": {"row": 25, "column": 17}, "end_point": {"row": 25, "column": 22}}, {"id": 83, "type": "parameter_declaration", "text": "IN PLIST_ENTRY", "parent": 77, "children": [84, 85], "start_point": {"row": 26, "column": 1}, "end_point": {"row": 26, "column": 15}}, {"id": 84, "type": "type_identifier", "text": "IN", "parent": 83, "children": [], "start_point": {"row": 26, "column": 1}, "end_point": {"row": 26, "column": 3}}, {"id": 85, "type": "identifier", "text": "PLIST_ENTRY", "parent": 83, "children": [], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 26, "column": 15}}, {"id": 86, "type": "ERROR", "text": "pEntry", "parent": 77, "children": [87], "start_point": {"row": 26, "column": 16}, "end_point": {"row": 26, "column": 22}}, {"id": 87, "type": "identifier", "text": "pEntry", "parent": 86, "children": [], "start_point": {"row": 26, "column": 16}, "end_point": {"row": 26, "column": 22}}, {"id": 88, "type": "assignment_expression", "text": "pEntry->pNext = NULL", "parent": 71, "children": [89, 92, 93], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 28, "column": 21}}, {"id": 89, "type": "field_expression", "text": "pEntry->pNext", "parent": 88, "children": [90, 91], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 28, "column": 14}}, {"id": 90, "type": "identifier", "text": "pEntry", "parent": 89, "children": [], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 28, "column": 7}}, {"id": 91, "type": "field_identifier", "text": "pNext", "parent": 89, "children": [], "start_point": {"row": 28, "column": 9}, "end_point": {"row": 28, "column": 14}}, {"id": 92, "type": "=", "text": "=", "parent": 88, "children": [], "start_point": {"row": 28, "column": 15}, "end_point": {"row": 28, "column": 16}}, {"id": 93, "type": "null", "text": "NULL", "parent": 88, "children": [94], "start_point": {"row": 28, "column": 17}, "end_point": {"row": 28, "column": 21}}, {"id": 94, "type": "NULL", "text": "NULL", "parent": 93, "children": [], "start_point": {"row": 28, "column": 17}, "end_point": {"row": 28, "column": 21}}, {"id": 95, "type": "if_statement", "text": "if (pList->pTail)\n\t\tpList->pTail->pNext = pEntry;\n\telse\n\t\tpList->pHead = pEntry;", "parent": 71, "children": [96, 108], "start_point": {"row": 29, "column": 1}, "end_point": {"row": 32, "column": 24}}, {"id": 96, "type": "parenthesized_expression", "text": "(pList->pTail)", "parent": 95, "children": [97], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 18}}, {"id": 97, "type": "field_expression", "text": "pList->pTail", "parent": 96, "children": [98, 99], "start_point": {"row": 29, "column": 5}, "end_point": {"row": 29, "column": 17}}, {"id": 98, "type": "identifier", "text": "pList", "parent": 97, "children": [], "start_point": {"row": 29, "column": 5}, "end_point": {"row": 29, "column": 10}}, {"id": 99, "type": "field_identifier", "text": "pTail", "parent": 97, "children": [], "start_point": {"row": 29, "column": 12}, "end_point": {"row": 29, "column": 17}}, {"id": 100, "type": "assignment_expression", "text": "pList->pTail->pNext = pEntry", "parent": 95, "children": [101, 106, 107], "start_point": {"row": 30, "column": 2}, "end_point": {"row": 30, "column": 30}}, {"id": 101, "type": "field_expression", "text": "pList->pTail->pNext", "parent": 100, "children": [102, 105], "start_point": {"row": 30, "column": 2}, "end_point": {"row": 30, "column": 21}}, {"id": 102, "type": "field_expression", "text": "pList->pTail", "parent": 101, "children": [103, 104], "start_point": {"row": 30, "column": 2}, "end_point": {"row": 30, "column": 14}}, {"id": 103, "type": "identifier", "text": "pList", "parent": 102, "children": [], "start_point": {"row": 30, "column": 2}, "end_point": {"row": 30, "column": 7}}, {"id": 104, "type": "field_identifier", "text": "pTail", "parent": 102, "children": [], "start_point": {"row": 30, "column": 9}, "end_point": {"row": 30, "column": 14}}, {"id": 105, "type": "field_identifier", "text": "pNext", "parent": 101, "children": [], "start_point": {"row": 30, "column": 16}, "end_point": {"row": 30, "column": 21}}, {"id": 106, "type": "=", "text": "=", "parent": 100, "children": [], "start_point": {"row": 30, "column": 22}, "end_point": {"row": 30, "column": 23}}, {"id": 107, "type": "identifier", "text": "pEntry", "parent": 100, "children": [], "start_point": {"row": 30, "column": 24}, "end_point": {"row": 30, "column": 30}}, {"id": 108, "type": "else_clause", "text": "else\n\t\tpList->pHead = pEntry;", "parent": 95, "children": [], "start_point": {"row": 31, "column": 1}, "end_point": {"row": 32, "column": 24}}, {"id": 109, "type": "assignment_expression", "text": "pList->pHead = pEntry", "parent": 108, "children": [110, 113, 114], "start_point": {"row": 32, "column": 2}, "end_point": {"row": 32, "column": 23}}, {"id": 110, "type": "field_expression", "text": "pList->pHead", "parent": 109, "children": [111, 112], "start_point": {"row": 32, "column": 2}, "end_point": {"row": 32, "column": 14}}, {"id": 111, "type": "identifier", "text": "pList", "parent": 110, "children": [], "start_point": {"row": 32, "column": 2}, "end_point": {"row": 32, "column": 7}}, {"id": 112, "type": "field_identifier", "text": "pHead", "parent": 110, "children": [], "start_point": {"row": 32, "column": 9}, "end_point": {"row": 32, "column": 14}}, {"id": 113, "type": "=", "text": "=", "parent": 109, "children": [], "start_point": {"row": 32, "column": 15}, "end_point": {"row": 32, "column": 16}}, {"id": 114, "type": "identifier", "text": "pEntry", "parent": 109, "children": [], "start_point": {"row": 32, "column": 17}, "end_point": {"row": 32, "column": 23}}, {"id": 115, "type": "assignment_expression", "text": "pList->pTail = pEntry", "parent": 71, "children": [116, 119, 120], "start_point": {"row": 33, "column": 1}, "end_point": {"row": 33, "column": 22}}, {"id": 116, "type": "field_expression", "text": "pList->pTail", "parent": 115, "children": [117, 118], "start_point": {"row": 33, "column": 1}, "end_point": {"row": 33, "column": 13}}, {"id": 117, "type": "identifier", "text": "pList", "parent": 116, "children": [], "start_point": {"row": 33, "column": 1}, "end_point": {"row": 33, "column": 6}}, {"id": 118, "type": "field_identifier", "text": "pTail", "parent": 116, "children": [], "start_point": {"row": 33, "column": 8}, "end_point": {"row": 33, "column": 13}}, {"id": 119, "type": "=", "text": "=", "parent": 115, "children": [], "start_point": {"row": 33, "column": 14}, "end_point": {"row": 33, "column": 15}}, {"id": 120, "type": "identifier", "text": "pEntry", "parent": 115, "children": [], "start_point": {"row": 33, "column": 16}, "end_point": {"row": 33, "column": 22}}, {"id": 121, "type": "update_expression", "text": "pList->size++", "parent": 71, "children": [122, 125], "start_point": {"row": 34, "column": 1}, "end_point": {"row": 34, "column": 14}}, {"id": 122, "type": "field_expression", "text": "pList->size", "parent": 121, "children": [123, 124], "start_point": {"row": 34, "column": 1}, "end_point": {"row": 34, "column": 12}}, {"id": 123, "type": "identifier", "text": "pList", "parent": 122, "children": [], "start_point": {"row": 34, "column": 1}, "end_point": {"row": 34, "column": 6}}, {"id": 124, "type": "field_identifier", "text": "size", "parent": 122, "children": [], "start_point": {"row": 34, "column": 8}, "end_point": {"row": 34, "column": 12}}, {"id": 125, "type": "++", "text": "++", "parent": 121, "children": [], "start_point": {"row": 34, "column": 12}, "end_point": {"row": 34, "column": 14}}, {"id": 126, "type": "return_statement", "text": "return;", "parent": 71, "children": [], "start_point": {"row": 36, "column": 1}, "end_point": {"row": 36, "column": 8}}, {"id": 127, "type": "function_definition", "text": "static inline PLIST_ENTRY removeHeadList(\n\tIN PLIST_HEADER pList)\n{\n\tPLIST_ENTRY pNext;\n\tPLIST_ENTRY pEntry;\n\n\tpEntry = pList->pHead;\n\tif (pList->pHead != NULL)\n\t{\n\t\tpNext = pList->pHead->pNext;\n\t\tpList->pHead = pNext;\n\t\tif (pNext == NULL)\n\t\t\tpList->pTail = NULL;\n\t\tpList->size--;\n\t}\n\treturn pEntry;\n}", "parent": 0, "children": [128, 130, 131], "start_point": {"row": 39, "column": 0}, "end_point": {"row": 55, "column": 1}}, {"id": 128, "type": "storage_class_specifier", "text": "inline", "parent": 127, "children": [129], "start_point": {"row": 39, "column": 7}, "end_point": {"row": 39, "column": 13}}, {"id": 129, "type": "inline", "text": "inline", "parent": 128, "children": [], "start_point": {"row": 39, "column": 7}, "end_point": {"row": 39, "column": 13}}, {"id": 130, "type": "type_identifier", "text": "PLIST_ENTRY", "parent": 127, "children": [], "start_point": {"row": 39, "column": 14}, "end_point": {"row": 39, "column": 25}}, {"id": 131, "type": "function_declarator", "text": "removeHeadList(\n\tIN PLIST_HEADER pList)", "parent": 127, "children": [132, 133], "start_point": {"row": 39, "column": 26}, "end_point": {"row": 40, "column": 23}}, {"id": 132, "type": "identifier", "text": "removeHeadList", "parent": 131, "children": [], "start_point": {"row": 39, "column": 26}, "end_point": {"row": 39, "column": 40}}, {"id": 133, "type": "parameter_list", "text": "(\n\tIN PLIST_HEADER pList)", "parent": 131, "children": [134, 137], "start_point": {"row": 39, "column": 40}, "end_point": {"row": 40, "column": 23}}, {"id": 134, "type": "parameter_declaration", "text": "IN PLIST_HEADER", "parent": 133, "children": [135, 136], "start_point": {"row": 40, "column": 1}, "end_point": {"row": 40, "column": 16}}, {"id": 135, "type": "type_identifier", "text": "IN", "parent": 134, "children": [], "start_point": {"row": 40, "column": 1}, "end_point": {"row": 40, "column": 3}}, {"id": 136, "type": "identifier", "text": "PLIST_HEADER", "parent": 134, "children": [], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 40, "column": 16}}, {"id": 137, "type": "ERROR", "text": "pList", "parent": 133, "children": [138], "start_point": {"row": 40, "column": 17}, "end_point": {"row": 40, "column": 22}}, {"id": 138, "type": "identifier", "text": "pList", "parent": 137, "children": [], "start_point": {"row": 40, "column": 17}, "end_point": {"row": 40, "column": 22}}, {"id": 139, "type": "declaration", "text": "PLIST_ENTRY pNext;", "parent": 127, "children": [140, 141], "start_point": {"row": 42, "column": 1}, "end_point": {"row": 42, "column": 19}}, {"id": 140, "type": "type_identifier", "text": "PLIST_ENTRY", "parent": 139, "children": [], "start_point": {"row": 42, "column": 1}, "end_point": {"row": 42, "column": 12}}, {"id": 141, "type": "identifier", "text": "pNext", "parent": 139, "children": [], "start_point": {"row": 42, "column": 13}, "end_point": {"row": 42, "column": 18}}, {"id": 142, "type": "declaration", "text": "PLIST_ENTRY pEntry;", "parent": 127, "children": [143, 144], "start_point": {"row": 43, "column": 1}, "end_point": {"row": 43, "column": 20}}, {"id": 143, "type": "type_identifier", "text": "PLIST_ENTRY", "parent": 142, "children": [], "start_point": {"row": 43, "column": 1}, "end_point": {"row": 43, "column": 12}}, {"id": 144, "type": "identifier", "text": "pEntry", "parent": 142, "children": [], "start_point": {"row": 43, "column": 13}, "end_point": {"row": 43, "column": 19}}, {"id": 145, "type": "assignment_expression", "text": "pEntry = pList->pHead", "parent": 127, "children": [146, 147, 148], "start_point": {"row": 45, "column": 1}, "end_point": {"row": 45, "column": 22}}, {"id": 146, "type": "identifier", "text": "pEntry", "parent": 145, "children": [], "start_point": {"row": 45, "column": 1}, "end_point": {"row": 45, "column": 7}}, {"id": 147, "type": "=", "text": "=", "parent": 145, "children": [], "start_point": {"row": 45, "column": 8}, "end_point": {"row": 45, "column": 9}}, {"id": 148, "type": "field_expression", "text": "pList->pHead", "parent": 145, "children": [149, 150], "start_point": {"row": 45, "column": 10}, "end_point": {"row": 45, "column": 22}}, {"id": 149, "type": "identifier", "text": "pList", "parent": 148, "children": [], "start_point": {"row": 45, "column": 10}, "end_point": {"row": 45, "column": 15}}, {"id": 150, "type": "field_identifier", "text": "pHead", "parent": 148, "children": [], "start_point": {"row": 45, "column": 17}, "end_point": {"row": 45, "column": 22}}, {"id": 151, "type": "if_statement", "text": "if (pList->pHead != NULL)\n\t{\n\t\tpNext = pList->pHead->pNext;\n\t\tpList->pHead = pNext;\n\t\tif (pNext == NULL)\n\t\t\tpList->pTail = NULL;\n\t\tpList->size--;\n\t}", "parent": 127, "children": [152], "start_point": {"row": 46, "column": 1}, "end_point": {"row": 53, "column": 2}}, {"id": 152, "type": "parenthesized_expression", "text": "(pList->pHead != NULL)", "parent": 151, "children": [153], "start_point": {"row": 46, "column": 4}, "end_point": {"row": 46, "column": 26}}, {"id": 153, "type": "binary_expression", "text": "pList->pHead != NULL", "parent": 152, "children": [154, 157, 158], "start_point": {"row": 46, "column": 5}, "end_point": {"row": 46, "column": 25}}, {"id": 154, "type": "field_expression", "text": "pList->pHead", "parent": 153, "children": [155, 156], "start_point": {"row": 46, "column": 5}, "end_point": {"row": 46, "column": 17}}, {"id": 155, "type": "identifier", "text": "pList", "parent": 154, "children": [], "start_point": {"row": 46, "column": 5}, "end_point": {"row": 46, "column": 10}}, {"id": 156, "type": "field_identifier", "text": "pHead", "parent": 154, "children": [], "start_point": {"row": 46, "column": 12}, "end_point": {"row": 46, "column": 17}}, {"id": 157, "type": "!=", "text": "!=", "parent": 153, "children": [], "start_point": {"row": 46, "column": 18}, "end_point": {"row": 46, "column": 20}}, {"id": 158, "type": "null", "text": "NULL", "parent": 153, "children": [159], "start_point": {"row": 46, "column": 21}, "end_point": {"row": 46, "column": 25}}, {"id": 159, "type": "NULL", "text": "NULL", "parent": 158, "children": [], "start_point": {"row": 46, "column": 21}, "end_point": {"row": 46, "column": 25}}, {"id": 160, "type": "assignment_expression", "text": "pNext = pList->pHead->pNext", "parent": 151, "children": [161, 162, 163], "start_point": {"row": 48, "column": 2}, "end_point": {"row": 48, "column": 29}}, {"id": 161, "type": "identifier", "text": "pNext", "parent": 160, "children": [], "start_point": {"row": 48, "column": 2}, "end_point": {"row": 48, "column": 7}}, {"id": 162, "type": "=", "text": "=", "parent": 160, "children": [], "start_point": {"row": 48, "column": 8}, "end_point": {"row": 48, "column": 9}}, {"id": 163, "type": "field_expression", "text": "pList->pHead->pNext", "parent": 160, "children": [164, 167], "start_point": {"row": 48, "column": 10}, "end_point": {"row": 48, "column": 29}}, {"id": 164, "type": "field_expression", "text": "pList->pHead", "parent": 163, "children": [165, 166], "start_point": {"row": 48, "column": 10}, "end_point": {"row": 48, "column": 22}}, {"id": 165, "type": "identifier", "text": "pList", "parent": 164, "children": [], "start_point": {"row": 48, "column": 10}, "end_point": {"row": 48, "column": 15}}, {"id": 166, "type": "field_identifier", "text": "pHead", "parent": 164, "children": [], "start_point": {"row": 48, "column": 17}, "end_point": {"row": 48, "column": 22}}, {"id": 167, "type": "field_identifier", "text": "pNext", "parent": 163, "children": [], "start_point": {"row": 48, "column": 24}, "end_point": {"row": 48, "column": 29}}, {"id": 168, "type": "assignment_expression", "text": "pList->pHead = pNext", "parent": 151, "children": [169, 172, 173], "start_point": {"row": 49, "column": 2}, "end_point": {"row": 49, "column": 22}}, {"id": 169, "type": "field_expression", "text": "pList->pHead", "parent": 168, "children": [170, 171], "start_point": {"row": 49, "column": 2}, "end_point": {"row": 49, "column": 14}}, {"id": 170, "type": "identifier", "text": "pList", "parent": 169, "children": [], "start_point": {"row": 49, "column": 2}, "end_point": {"row": 49, "column": 7}}, {"id": 171, "type": "field_identifier", "text": "pHead", "parent": 169, "children": [], "start_point": {"row": 49, "column": 9}, "end_point": {"row": 49, "column": 14}}, {"id": 172, "type": "=", "text": "=", "parent": 168, "children": [], "start_point": {"row": 49, "column": 15}, "end_point": {"row": 49, "column": 16}}, {"id": 173, "type": "identifier", "text": "pNext", "parent": 168, "children": [], "start_point": {"row": 49, "column": 17}, "end_point": {"row": 49, "column": 22}}, {"id": 174, "type": "if_statement", "text": "if (pNext == NULL)\n\t\t\tpList->pTail = NULL;", "parent": 151, "children": [175], "start_point": {"row": 50, "column": 2}, "end_point": {"row": 51, "column": 23}}, {"id": 175, "type": "parenthesized_expression", "text": "(pNext == NULL)", "parent": 174, "children": [176], "start_point": {"row": 50, "column": 5}, "end_point": {"row": 50, "column": 20}}, {"id": 176, "type": "binary_expression", "text": "pNext == NULL", "parent": 175, "children": [177, 178, 179], "start_point": {"row": 50, "column": 6}, "end_point": {"row": 50, "column": 19}}, {"id": 177, "type": "identifier", "text": "pNext", "parent": 176, "children": [], "start_point": {"row": 50, "column": 6}, "end_point": {"row": 50, "column": 11}}, {"id": 178, "type": "==", "text": "==", "parent": 176, "children": [], "start_point": {"row": 50, "column": 12}, "end_point": {"row": 50, "column": 14}}, {"id": 179, "type": "null", "text": "NULL", "parent": 176, "children": [180], "start_point": {"row": 50, "column": 15}, "end_point": {"row": 50, "column": 19}}, {"id": 180, "type": "NULL", "text": "NULL", "parent": 179, "children": [], "start_point": {"row": 50, "column": 15}, "end_point": {"row": 50, "column": 19}}, {"id": 181, "type": "assignment_expression", "text": "pList->pTail = NULL", "parent": 174, "children": [182, 185, 186], "start_point": {"row": 51, "column": 3}, "end_point": {"row": 51, "column": 22}}, {"id": 182, "type": "field_expression", "text": "pList->pTail", "parent": 181, "children": [183, 184], "start_point": {"row": 51, "column": 3}, "end_point": {"row": 51, "column": 15}}, {"id": 183, "type": "identifier", "text": "pList", "parent": 182, "children": [], "start_point": {"row": 51, "column": 3}, "end_point": {"row": 51, "column": 8}}, {"id": 184, "type": "field_identifier", "text": "pTail", "parent": 182, "children": [], "start_point": {"row": 51, "column": 10}, "end_point": {"row": 51, "column": 15}}, {"id": 185, "type": "=", "text": "=", "parent": 181, "children": [], "start_point": {"row": 51, "column": 16}, "end_point": {"row": 51, "column": 17}}, {"id": 186, "type": "null", "text": "NULL", "parent": 181, "children": [187], "start_point": {"row": 51, "column": 18}, "end_point": {"row": 51, "column": 22}}, {"id": 187, "type": "NULL", "text": "NULL", "parent": 186, "children": [], "start_point": {"row": 51, "column": 18}, "end_point": {"row": 51, "column": 22}}, {"id": 188, "type": "update_expression", "text": "pList->size--", "parent": 151, "children": [189, 192], "start_point": {"row": 52, "column": 2}, "end_point": {"row": 52, "column": 15}}, {"id": 189, "type": "field_expression", "text": "pList->size", "parent": 188, "children": [190, 191], "start_point": {"row": 52, "column": 2}, "end_point": {"row": 52, "column": 13}}, {"id": 190, "type": "identifier", "text": "pList", "parent": 189, "children": [], "start_point": {"row": 52, "column": 2}, "end_point": {"row": 52, "column": 7}}, {"id": 191, "type": "field_identifier", "text": "size", "parent": 189, "children": [], "start_point": {"row": 52, "column": 9}, "end_point": {"row": 52, "column": 13}}, {"id": 192, "type": "--", "text": "--", "parent": 188, "children": [], "start_point": {"row": 52, "column": 13}, "end_point": {"row": 52, "column": 15}}, {"id": 193, "type": "return_statement", "text": "return pEntry;", "parent": 127, "children": [194], "start_point": {"row": 54, "column": 1}, "end_point": {"row": 54, "column": 15}}, {"id": 194, "type": "identifier", "text": "pEntry", "parent": 193, "children": [], "start_point": {"row": 54, "column": 8}, "end_point": {"row": 54, "column": 14}}, {"id": 195, "type": "function_definition", "text": "static inline int getListSize(\n\tIN PLIST_HEADER pList)\n{\n\treturn pList->size;\n}", "parent": 0, "children": [196, 198, 199], "start_point": {"row": 57, "column": 0}, "end_point": {"row": 61, "column": 1}}, {"id": 196, "type": "storage_class_specifier", "text": "inline", "parent": 195, "children": [197], "start_point": {"row": 57, "column": 7}, "end_point": {"row": 57, "column": 13}}, {"id": 197, "type": "inline", "text": "inline", "parent": 196, "children": [], "start_point": {"row": 57, "column": 7}, "end_point": {"row": 57, "column": 13}}, {"id": 198, "type": "primitive_type", "text": "int", "parent": 195, "children": [], "start_point": {"row": 57, "column": 14}, "end_point": {"row": 57, "column": 17}}, {"id": 199, "type": "function_declarator", "text": "getListSize(\n\tIN PLIST_HEADER pList)", "parent": 195, "children": [200, 201], "start_point": {"row": 57, "column": 18}, "end_point": {"row": 58, "column": 23}}, {"id": 200, "type": "identifier", "text": "getListSize", "parent": 199, "children": [], "start_point": {"row": 57, "column": 18}, "end_point": {"row": 57, "column": 29}}, {"id": 201, "type": "parameter_list", "text": "(\n\tIN PLIST_HEADER pList)", "parent": 199, "children": [202, 205], "start_point": {"row": 57, "column": 29}, "end_point": {"row": 58, "column": 23}}, {"id": 202, "type": "parameter_declaration", "text": "IN PLIST_HEADER", "parent": 201, "children": [203, 204], "start_point": {"row": 58, "column": 1}, "end_point": {"row": 58, "column": 16}}, {"id": 203, "type": "type_identifier", "text": "IN", "parent": 202, "children": [], "start_point": {"row": 58, "column": 1}, "end_point": {"row": 58, "column": 3}}, {"id": 204, "type": "identifier", "text": "PLIST_HEADER", "parent": 202, "children": [], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 16}}, {"id": 205, "type": "ERROR", "text": "pList", "parent": 201, "children": [206], "start_point": {"row": 58, "column": 17}, "end_point": {"row": 58, "column": 22}}, {"id": 206, "type": "identifier", "text": "pList", "parent": 205, "children": [], "start_point": {"row": 58, "column": 17}, "end_point": {"row": 58, "column": 22}}, {"id": 207, "type": "return_statement", "text": "return pList->size;", "parent": 195, "children": [208], "start_point": {"row": 60, "column": 1}, "end_point": {"row": 60, "column": 20}}, {"id": 208, "type": "field_expression", "text": "pList->size", "parent": 207, "children": [209, 210], "start_point": {"row": 60, "column": 8}, "end_point": {"row": 60, "column": 19}}, {"id": 209, "type": "identifier", "text": "pList", "parent": 208, "children": [], "start_point": {"row": 60, "column": 8}, "end_point": {"row": 60, "column": 13}}, {"id": 210, "type": "field_identifier", "text": "size", "parent": 208, "children": [], "start_point": {"row": 60, "column": 15}, "end_point": {"row": 60, "column": 19}}, {"id": 211, "type": "function_definition", "text": "static inline PLIST_ENTRY delEntryList(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)\n{\n\tPLIST_ENTRY pCurEntry;\n\tPLIST_ENTRY pPrvEntry;\n\n\tif(pList->pHead == NULL)\n\t\treturn NULL;\n\n\tif(pEntry == pList->pHead)\n\t{\n\t\tpCurEntry = pList->pHead;\n\t\tpList->pHead = pCurEntry->pNext;\n\n\t\tif(pList->pHead == NULL)\n\t\t\tpList->pTail = NULL;\n\n\t\tpList->size--;\n\t\treturn pCurEntry;\n\t}\n\n\tpPrvEntry = pList->pHead;\n\tpCurEntry = pPrvEntry->pNext;\n\twhile(pCurEntry != NULL)\n\t{\n\t\tif (pEntry == pCurEntry)\n\t\t{\n\t\t\tpPrvEntry->pNext = pCurEntry->pNext;\n\n\t\t\tif(pEntry == pList->pTail)\n\t\t\t\tpList->pTail = pPrvEntry;\n\n\t\t\tpList->size--;\n\t\t\tbreak;\n\t\t}\n\t\tpPrvEntry = pCurEntry;\n\t\tpCurEntry = pPrvEntry->pNext;\n\t}\n\n\treturn pCurEntry;\n}", "parent": 0, "children": [212, 214, 215], "start_point": {"row": 63, "column": 0}, "end_point": {"row": 104, "column": 1}}, {"id": 212, "type": "storage_class_specifier", "text": "inline", "parent": 211, "children": [213], "start_point": {"row": 63, "column": 7}, "end_point": {"row": 63, "column": 13}}, {"id": 213, "type": "inline", "text": "inline", "parent": 212, "children": [], "start_point": {"row": 63, "column": 7}, "end_point": {"row": 63, "column": 13}}, {"id": 214, "type": "type_identifier", "text": "PLIST_ENTRY", "parent": 211, "children": [], "start_point": {"row": 63, "column": 14}, "end_point": {"row": 63, "column": 25}}, {"id": 215, "type": "function_declarator", "text": "delEntryList(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)", "parent": 211, "children": [216, 217], "start_point": {"row": 63, "column": 26}, "end_point": {"row": 65, "column": 23}}, {"id": 216, "type": "identifier", "text": "delEntryList", "parent": 215, "children": [], "start_point": {"row": 63, "column": 26}, "end_point": {"row": 63, "column": 38}}, {"id": 217, "type": "parameter_list", "text": "(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)", "parent": 215, "children": [218, 221, 223, 226], "start_point": {"row": 63, "column": 38}, "end_point": {"row": 65, "column": 23}}, {"id": 218, "type": "parameter_declaration", "text": "IN PLIST_HEADER", "parent": 217, "children": [219, 220], "start_point": {"row": 64, "column": 1}, "end_point": {"row": 64, "column": 16}}, {"id": 219, "type": "type_identifier", "text": "IN", "parent": 218, "children": [], "start_point": {"row": 64, "column": 1}, "end_point": {"row": 64, "column": 3}}, {"id": 220, "type": "identifier", "text": "PLIST_HEADER", "parent": 218, "children": [], "start_point": {"row": 64, "column": 4}, "end_point": {"row": 64, "column": 16}}, {"id": 221, "type": "ERROR", "text": "pList", "parent": 217, "children": [222], "start_point": {"row": 64, "column": 17}, "end_point": {"row": 64, "column": 22}}, {"id": 222, "type": "identifier", "text": "pList", "parent": 221, "children": [], "start_point": {"row": 64, "column": 17}, "end_point": {"row": 64, "column": 22}}, {"id": 223, "type": "parameter_declaration", "text": "IN PLIST_ENTRY", "parent": 217, "children": [224, 225], "start_point": {"row": 65, "column": 1}, "end_point": {"row": 65, "column": 15}}, {"id": 224, "type": "type_identifier", "text": "IN", "parent": 223, "children": [], "start_point": {"row": 65, "column": 1}, "end_point": {"row": 65, "column": 3}}, {"id": 225, "type": "identifier", "text": "PLIST_ENTRY", "parent": 223, "children": [], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 15}}, {"id": 226, "type": "ERROR", "text": "pEntry", "parent": 217, "children": [227], "start_point": {"row": 65, "column": 16}, "end_point": {"row": 65, "column": 22}}, {"id": 227, "type": "identifier", "text": "pEntry", "parent": 226, "children": [], "start_point": {"row": 65, "column": 16}, "end_point": {"row": 65, "column": 22}}, {"id": 228, "type": "declaration", "text": "PLIST_ENTRY pCurEntry;", "parent": 211, "children": [229, 230], "start_point": {"row": 67, "column": 1}, "end_point": {"row": 67, "column": 23}}, {"id": 229, "type": "type_identifier", "text": "PLIST_ENTRY", "parent": 228, "children": [], "start_point": {"row": 67, "column": 1}, "end_point": {"row": 67, "column": 12}}, {"id": 230, "type": "identifier", "text": "pCurEntry", "parent": 228, "children": [], "start_point": {"row": 67, "column": 13}, "end_point": {"row": 67, "column": 22}}, {"id": 231, "type": "declaration", "text": "PLIST_ENTRY pPrvEntry;", "parent": 211, "children": [232, 233], "start_point": {"row": 68, "column": 1}, "end_point": {"row": 68, "column": 23}}, {"id": 232, "type": "type_identifier", "text": "PLIST_ENTRY", "parent": 231, "children": [], "start_point": {"row": 68, "column": 1}, "end_point": {"row": 68, "column": 12}}, {"id": 233, "type": "identifier", "text": "pPrvEntry", "parent": 231, "children": [], "start_point": {"row": 68, "column": 13}, "end_point": {"row": 68, "column": 22}}, {"id": 234, "type": "if_statement", "text": "if(pList->pHead == NULL)\n\t\treturn NULL;", "parent": 211, "children": [235, 243], "start_point": {"row": 70, "column": 1}, "end_point": {"row": 71, "column": 14}}, {"id": 235, "type": "parenthesized_expression", "text": "(pList->pHead == NULL)", "parent": 234, "children": [236], "start_point": {"row": 70, "column": 3}, "end_point": {"row": 70, "column": 25}}, {"id": 236, "type": "binary_expression", "text": "pList->pHead == NULL", "parent": 235, "children": [237, 240, 241], "start_point": {"row": 70, "column": 4}, "end_point": {"row": 70, "column": 24}}, {"id": 237, "type": "field_expression", "text": "pList->pHead", "parent": 236, "children": [238, 239], "start_point": {"row": 70, "column": 4}, "end_point": {"row": 70, "column": 16}}, {"id": 238, "type": "identifier", "text": "pList", "parent": 237, "children": [], "start_point": {"row": 70, "column": 4}, "end_point": {"row": 70, "column": 9}}, {"id": 239, "type": "field_identifier", "text": "pHead", "parent": 237, "children": [], "start_point": {"row": 70, "column": 11}, "end_point": {"row": 70, "column": 16}}, {"id": 240, "type": "==", "text": "==", "parent": 236, "children": [], "start_point": {"row": 70, "column": 17}, "end_point": {"row": 70, "column": 19}}, {"id": 241, "type": "null", "text": "NULL", "parent": 236, "children": [242], "start_point": {"row": 70, "column": 20}, "end_point": {"row": 70, "column": 24}}, {"id": 242, "type": "NULL", "text": "NULL", "parent": 241, "children": [], "start_point": {"row": 70, "column": 20}, "end_point": {"row": 70, "column": 24}}, {"id": 243, "type": "return_statement", "text": "return NULL;", "parent": 234, "children": [244], "start_point": {"row": 71, "column": 2}, "end_point": {"row": 71, "column": 14}}, {"id": 244, "type": "null", "text": "NULL", "parent": 243, "children": [245], "start_point": {"row": 71, "column": 9}, "end_point": {"row": 71, "column": 13}}, {"id": 245, "type": "NULL", "text": "NULL", "parent": 244, "children": [], "start_point": {"row": 71, "column": 9}, "end_point": {"row": 71, "column": 13}}, {"id": 246, "type": "if_statement", "text": "if(pEntry == pList->pHead)\n\t{\n\t\tpCurEntry = pList->pHead;\n\t\tpList->pHead = pCurEntry->pNext;\n\n\t\tif(pList->pHead == NULL)\n\t\t\tpList->pTail = NULL;\n\n\t\tpList->size--;\n\t\treturn pCurEntry;\n\t}", "parent": 211, "children": [247], "start_point": {"row": 73, "column": 1}, "end_point": {"row": 83, "column": 2}}, {"id": 247, "type": "parenthesized_expression", "text": "(pEntry == pList->pHead)", "parent": 246, "children": [248], "start_point": {"row": 73, "column": 3}, "end_point": {"row": 73, "column": 27}}, {"id": 248, "type": "binary_expression", "text": "pEntry == pList->pHead", "parent": 247, "children": [249, 250, 251], "start_point": {"row": 73, "column": 4}, "end_point": {"row": 73, "column": 26}}, {"id": 249, "type": "identifier", "text": "pEntry", "parent": 248, "children": [], "start_point": {"row": 73, "column": 4}, "end_point": {"row": 73, "column": 10}}, {"id": 250, "type": "==", "text": "==", "parent": 248, "children": [], "start_point": {"row": 73, "column": 11}, "end_point": {"row": 73, "column": 13}}, {"id": 251, "type": "field_expression", "text": "pList->pHead", "parent": 248, "children": [252, 253], "start_point": {"row": 73, "column": 14}, "end_point": {"row": 73, "column": 26}}, {"id": 252, "type": "identifier", "text": "pList", "parent": 251, "children": [], "start_point": {"row": 73, "column": 14}, "end_point": {"row": 73, "column": 19}}, {"id": 253, "type": "field_identifier", "text": "pHead", "parent": 251, "children": [], "start_point": {"row": 73, "column": 21}, "end_point": {"row": 73, "column": 26}}, {"id": 254, "type": "assignment_expression", "text": "pCurEntry = pList->pHead", "parent": 246, "children": [255, 256, 257], "start_point": {"row": 75, "column": 2}, "end_point": {"row": 75, "column": 26}}, {"id": 255, "type": "identifier", "text": "pCurEntry", "parent": 254, "children": [], "start_point": {"row": 75, "column": 2}, "end_point": {"row": 75, "column": 11}}, {"id": 256, "type": "=", "text": "=", "parent": 254, "children": [], "start_point": {"row": 75, "column": 12}, "end_point": {"row": 75, "column": 13}}, {"id": 257, "type": "field_expression", "text": "pList->pHead", "parent": 254, "children": [258, 259], "start_point": {"row": 75, "column": 14}, "end_point": {"row": 75, "column": 26}}, {"id": 258, "type": "identifier", "text": "pList", "parent": 257, "children": [], "start_point": {"row": 75, "column": 14}, "end_point": {"row": 75, "column": 19}}, {"id": 259, "type": "field_identifier", "text": "pHead", "parent": 257, "children": [], "start_point": {"row": 75, "column": 21}, "end_point": {"row": 75, "column": 26}}, {"id": 260, "type": "assignment_expression", "text": "pList->pHead = pCurEntry->pNext", "parent": 246, "children": [261, 264, 265], "start_point": {"row": 76, "column": 2}, "end_point": {"row": 76, "column": 33}}, {"id": 261, "type": "field_expression", "text": "pList->pHead", "parent": 260, "children": [262, 263], "start_point": {"row": 76, "column": 2}, "end_point": {"row": 76, "column": 14}}, {"id": 262, "type": "identifier", "text": "pList", "parent": 261, "children": [], "start_point": {"row": 76, "column": 2}, "end_point": {"row": 76, "column": 7}}, {"id": 263, "type": "field_identifier", "text": "pHead", "parent": 261, "children": [], "start_point": {"row": 76, "column": 9}, "end_point": {"row": 76, "column": 14}}, {"id": 264, "type": "=", "text": "=", "parent": 260, "children": [], "start_point": {"row": 76, "column": 15}, "end_point": {"row": 76, "column": 16}}, {"id": 265, "type": "field_expression", "text": "pCurEntry->pNext", "parent": 260, "children": [266, 267], "start_point": {"row": 76, "column": 17}, "end_point": {"row": 76, "column": 33}}, {"id": 266, "type": "identifier", "text": "pCurEntry", "parent": 265, "children": [], "start_point": {"row": 76, "column": 17}, "end_point": {"row": 76, "column": 26}}, {"id": 267, "type": "field_identifier", "text": "pNext", "parent": 265, "children": [], "start_point": {"row": 76, "column": 28}, "end_point": {"row": 76, "column": 33}}, {"id": 268, "type": "if_statement", "text": "if(pList->pHead == NULL)\n\t\t\tpList->pTail = NULL;", "parent": 246, "children": [269], "start_point": {"row": 78, "column": 2}, "end_point": {"row": 79, "column": 23}}, {"id": 269, "type": "parenthesized_expression", "text": "(pList->pHead == NULL)", "parent": 268, "children": [270], "start_point": {"row": 78, "column": 4}, "end_point": {"row": 78, "column": 26}}, {"id": 270, "type": "binary_expression", "text": "pList->pHead == NULL", "parent": 269, "children": [271, 274, 275], "start_point": {"row": 78, "column": 5}, "end_point": {"row": 78, "column": 25}}, {"id": 271, "type": "field_expression", "text": "pList->pHead", "parent": 270, "children": [272, 273], "start_point": {"row": 78, "column": 5}, "end_point": {"row": 78, "column": 17}}, {"id": 272, "type": "identifier", "text": "pList", "parent": 271, "children": [], "start_point": {"row": 78, "column": 5}, "end_point": {"row": 78, "column": 10}}, {"id": 273, "type": "field_identifier", "text": "pHead", "parent": 271, "children": [], "start_point": {"row": 78, "column": 12}, "end_point": {"row": 78, "column": 17}}, {"id": 274, "type": "==", "text": "==", "parent": 270, "children": [], "start_point": {"row": 78, "column": 18}, "end_point": {"row": 78, "column": 20}}, {"id": 275, "type": "null", "text": "NULL", "parent": 270, "children": [276], "start_point": {"row": 78, "column": 21}, "end_point": {"row": 78, "column": 25}}, {"id": 276, "type": "NULL", "text": "NULL", "parent": 275, "children": [], "start_point": {"row": 78, "column": 21}, "end_point": {"row": 78, "column": 25}}, {"id": 277, "type": "assignment_expression", "text": "pList->pTail = NULL", "parent": 268, "children": [278, 281, 282], "start_point": {"row": 79, "column": 3}, "end_point": {"row": 79, "column": 22}}, {"id": 278, "type": "field_expression", "text": "pList->pTail", "parent": 277, "children": [279, 280], "start_point": {"row": 79, "column": 3}, "end_point": {"row": 79, "column": 15}}, {"id": 279, "type": "identifier", "text": "pList", "parent": 278, "children": [], "start_point": {"row": 79, "column": 3}, "end_point": {"row": 79, "column": 8}}, {"id": 280, "type": "field_identifier", "text": "pTail", "parent": 278, "children": [], "start_point": {"row": 79, "column": 10}, "end_point": {"row": 79, "column": 15}}, {"id": 281, "type": "=", "text": "=", "parent": 277, "children": [], "start_point": {"row": 79, "column": 16}, "end_point": {"row": 79, "column": 17}}, {"id": 282, "type": "null", "text": "NULL", "parent": 277, "children": [283], "start_point": {"row": 79, "column": 18}, "end_point": {"row": 79, "column": 22}}, {"id": 283, "type": "NULL", "text": "NULL", "parent": 282, "children": [], "start_point": {"row": 79, "column": 18}, "end_point": {"row": 79, "column": 22}}, {"id": 284, "type": "update_expression", "text": "pList->size--", "parent": 246, "children": [285, 288], "start_point": {"row": 81, "column": 2}, "end_point": {"row": 81, "column": 15}}, {"id": 285, "type": "field_expression", "text": "pList->size", "parent": 284, "children": [286, 287], "start_point": {"row": 81, "column": 2}, "end_point": {"row": 81, "column": 13}}, {"id": 286, "type": "identifier", "text": "pList", "parent": 285, "children": [], "start_point": {"row": 81, "column": 2}, "end_point": {"row": 81, "column": 7}}, {"id": 287, "type": "field_identifier", "text": "size", "parent": 285, "children": [], "start_point": {"row": 81, "column": 9}, "end_point": {"row": 81, "column": 13}}, {"id": 288, "type": "--", "text": "--", "parent": 284, "children": [], "start_point": {"row": 81, "column": 13}, "end_point": {"row": 81, "column": 15}}, {"id": 289, "type": "return_statement", "text": "return pCurEntry;", "parent": 246, "children": [290], "start_point": {"row": 82, "column": 2}, "end_point": {"row": 82, "column": 19}}, {"id": 290, "type": "identifier", "text": "pCurEntry", "parent": 289, "children": [], "start_point": {"row": 82, "column": 9}, "end_point": {"row": 82, "column": 18}}, {"id": 291, "type": "assignment_expression", "text": "pPrvEntry = pList->pHead", "parent": 211, "children": [292, 293, 294], "start_point": {"row": 85, "column": 1}, "end_point": {"row": 85, "column": 25}}, {"id": 292, "type": "identifier", "text": "pPrvEntry", "parent": 291, "children": [], "start_point": {"row": 85, "column": 1}, "end_point": {"row": 85, "column": 10}}, {"id": 293, "type": "=", "text": "=", "parent": 291, "children": [], "start_point": {"row": 85, "column": 11}, "end_point": {"row": 85, "column": 12}}, {"id": 294, "type": "field_expression", "text": "pList->pHead", "parent": 291, "children": [295, 296], "start_point": {"row": 85, "column": 13}, "end_point": {"row": 85, "column": 25}}, {"id": 295, "type": "identifier", "text": "pList", "parent": 294, "children": [], "start_point": {"row": 85, "column": 13}, "end_point": {"row": 85, "column": 18}}, {"id": 296, "type": "field_identifier", "text": "pHead", "parent": 294, "children": [], "start_point": {"row": 85, "column": 20}, "end_point": {"row": 85, "column": 25}}, {"id": 297, "type": "assignment_expression", "text": "pCurEntry = pPrvEntry->pNext", "parent": 211, "children": [298, 299, 300], "start_point": {"row": 86, "column": 1}, "end_point": {"row": 86, "column": 29}}, {"id": 298, "type": "identifier", "text": "pCurEntry", "parent": 297, "children": [], "start_point": {"row": 86, "column": 1}, "end_point": {"row": 86, "column": 10}}, {"id": 299, "type": "=", "text": "=", "parent": 297, "children": [], "start_point": {"row": 86, "column": 11}, "end_point": {"row": 86, "column": 12}}, {"id": 300, "type": "field_expression", "text": "pPrvEntry->pNext", "parent": 297, "children": [301, 302], "start_point": {"row": 86, "column": 13}, "end_point": {"row": 86, "column": 29}}, {"id": 301, "type": "identifier", "text": "pPrvEntry", "parent": 300, "children": [], "start_point": {"row": 86, "column": 13}, "end_point": {"row": 86, "column": 22}}, {"id": 302, "type": "field_identifier", "text": "pNext", "parent": 300, "children": [], "start_point": {"row": 86, "column": 24}, "end_point": {"row": 86, "column": 29}}, {"id": 303, "type": "while_statement", "text": "while(pCurEntry != NULL)\n\t{\n\t\tif (pEntry == pCurEntry)\n\t\t{\n\t\t\tpPrvEntry->pNext = pCurEntry->pNext;\n\n\t\t\tif(pEntry == pList->pTail)\n\t\t\t\tpList->pTail = pPrvEntry;\n\n\t\t\tpList->size--;\n\t\t\tbreak;\n\t\t}\n\t\tpPrvEntry = pCurEntry;\n\t\tpCurEntry = pPrvEntry->pNext;\n\t}", "parent": 211, "children": [304], "start_point": {"row": 87, "column": 1}, "end_point": {"row": 101, "column": 2}}, {"id": 304, "type": "parenthesized_expression", "text": "(pCurEntry != NULL)", "parent": 303, "children": [305], "start_point": {"row": 87, "column": 6}, "end_point": {"row": 87, "column": 25}}, {"id": 305, "type": "binary_expression", "text": "pCurEntry != NULL", "parent": 304, "children": [306, 307, 308], "start_point": {"row": 87, "column": 7}, "end_point": {"row": 87, "column": 24}}, {"id": 306, "type": "identifier", "text": "pCurEntry", "parent": 305, "children": [], "start_point": {"row": 87, "column": 7}, "end_point": {"row": 87, "column": 16}}, {"id": 307, "type": "!=", "text": "!=", "parent": 305, "children": [], "start_point": {"row": 87, "column": 17}, "end_point": {"row": 87, "column": 19}}, {"id": 308, "type": "null", "text": "NULL", "parent": 305, "children": [309], "start_point": {"row": 87, "column": 20}, "end_point": {"row": 87, "column": 24}}, {"id": 309, "type": "NULL", "text": "NULL", "parent": 308, "children": [], "start_point": {"row": 87, "column": 20}, "end_point": {"row": 87, "column": 24}}, {"id": 310, "type": "if_statement", "text": "if (pEntry == pCurEntry)\n\t\t{\n\t\t\tpPrvEntry->pNext = pCurEntry->pNext;\n\n\t\t\tif(pEntry == pList->pTail)\n\t\t\t\tpList->pTail = pPrvEntry;\n\n\t\t\tpList->size--;\n\t\t\tbreak;\n\t\t}", "parent": 303, "children": [311], "start_point": {"row": 89, "column": 2}, "end_point": {"row": 98, "column": 3}}, {"id": 311, "type": "parenthesized_expression", "text": "(pEntry == pCurEntry)", "parent": 310, "children": [312], "start_point": {"row": 89, "column": 5}, "end_point": {"row": 89, "column": 26}}, {"id": 312, "type": "binary_expression", "text": "pEntry == pCurEntry", "parent": 311, "children": [313, 314, 315], "start_point": {"row": 89, "column": 6}, "end_point": {"row": 89, "column": 25}}, {"id": 313, "type": "identifier", "text": "pEntry", "parent": 312, "children": [], "start_point": {"row": 89, "column": 6}, "end_point": {"row": 89, "column": 12}}, {"id": 314, "type": "==", "text": "==", "parent": 312, "children": [], "start_point": {"row": 89, "column": 13}, "end_point": {"row": 89, "column": 15}}, {"id": 315, "type": "identifier", "text": "pCurEntry", "parent": 312, "children": [], "start_point": {"row": 89, "column": 16}, "end_point": {"row": 89, "column": 25}}, {"id": 316, "type": "assignment_expression", "text": "pPrvEntry->pNext = pCurEntry->pNext", "parent": 310, "children": [317, 320, 321], "start_point": {"row": 91, "column": 3}, "end_point": {"row": 91, "column": 38}}, {"id": 317, "type": "field_expression", "text": "pPrvEntry->pNext", "parent": 316, "children": [318, 319], "start_point": {"row": 91, "column": 3}, "end_point": {"row": 91, "column": 19}}, {"id": 318, "type": "identifier", "text": "pPrvEntry", "parent": 317, "children": [], "start_point": {"row": 91, "column": 3}, "end_point": {"row": 91, "column": 12}}, {"id": 319, "type": "field_identifier", "text": "pNext", "parent": 317, "children": [], "start_point": {"row": 91, "column": 14}, "end_point": {"row": 91, "column": 19}}, {"id": 320, "type": "=", "text": "=", "parent": 316, "children": [], "start_point": {"row": 91, "column": 20}, "end_point": {"row": 91, "column": 21}}, {"id": 321, "type": "field_expression", "text": "pCurEntry->pNext", "parent": 316, "children": [322, 323], "start_point": {"row": 91, "column": 22}, "end_point": {"row": 91, "column": 38}}, {"id": 322, "type": "identifier", "text": "pCurEntry", "parent": 321, "children": [], "start_point": {"row": 91, "column": 22}, "end_point": {"row": 91, "column": 31}}, {"id": 323, "type": "field_identifier", "text": "pNext", "parent": 321, "children": [], "start_point": {"row": 91, "column": 33}, "end_point": {"row": 91, "column": 38}}, {"id": 324, "type": "if_statement", "text": "if(pEntry == pList->pTail)\n\t\t\t\tpList->pTail = pPrvEntry;", "parent": 310, "children": [325], "start_point": {"row": 93, "column": 3}, "end_point": {"row": 94, "column": 29}}, {"id": 325, "type": "parenthesized_expression", "text": "(pEntry == pList->pTail)", "parent": 324, "children": [326], "start_point": {"row": 93, "column": 5}, "end_point": {"row": 93, "column": 29}}, {"id": 326, "type": "binary_expression", "text": "pEntry == pList->pTail", "parent": 325, "children": [327, 328, 329], "start_point": {"row": 93, "column": 6}, "end_point": {"row": 93, "column": 28}}, {"id": 327, "type": "identifier", "text": "pEntry", "parent": 326, "children": [], "start_point": {"row": 93, "column": 6}, "end_point": {"row": 93, "column": 12}}, {"id": 328, "type": "==", "text": "==", "parent": 326, "children": [], "start_point": {"row": 93, "column": 13}, "end_point": {"row": 93, "column": 15}}, {"id": 329, "type": "field_expression", "text": "pList->pTail", "parent": 326, "children": [330, 331], "start_point": {"row": 93, "column": 16}, "end_point": {"row": 93, "column": 28}}, {"id": 330, "type": "identifier", "text": "pList", "parent": 329, "children": [], "start_point": {"row": 93, "column": 16}, "end_point": {"row": 93, "column": 21}}, {"id": 331, "type": "field_identifier", "text": "pTail", "parent": 329, "children": [], "start_point": {"row": 93, "column": 23}, "end_point": {"row": 93, "column": 28}}, {"id": 332, "type": "assignment_expression", "text": "pList->pTail = pPrvEntry", "parent": 324, "children": [333, 336, 337], "start_point": {"row": 94, "column": 4}, "end_point": {"row": 94, "column": 28}}, {"id": 333, "type": "field_expression", "text": "pList->pTail", "parent": 332, "children": [334, 335], "start_point": {"row": 94, "column": 4}, "end_point": {"row": 94, "column": 16}}, {"id": 334, "type": "identifier", "text": "pList", "parent": 333, "children": [], "start_point": {"row": 94, "column": 4}, "end_point": {"row": 94, "column": 9}}, {"id": 335, "type": "field_identifier", "text": "pTail", "parent": 333, "children": [], "start_point": {"row": 94, "column": 11}, "end_point": {"row": 94, "column": 16}}, {"id": 336, "type": "=", "text": "=", "parent": 332, "children": [], "start_point": {"row": 94, "column": 17}, "end_point": {"row": 94, "column": 18}}, {"id": 337, "type": "identifier", "text": "pPrvEntry", "parent": 332, "children": [], "start_point": {"row": 94, "column": 19}, "end_point": {"row": 94, "column": 28}}, {"id": 338, "type": "update_expression", "text": "pList->size--", "parent": 310, "children": [339, 342], "start_point": {"row": 96, "column": 3}, "end_point": {"row": 96, "column": 16}}, {"id": 339, "type": "field_expression", "text": "pList->size", "parent": 338, "children": [340, 341], "start_point": {"row": 96, "column": 3}, "end_point": {"row": 96, "column": 14}}, {"id": 340, "type": "identifier", "text": "pList", "parent": 339, "children": [], "start_point": {"row": 96, "column": 3}, "end_point": {"row": 96, "column": 8}}, {"id": 341, "type": "field_identifier", "text": "size", "parent": 339, "children": [], "start_point": {"row": 96, "column": 10}, "end_point": {"row": 96, "column": 14}}, {"id": 342, "type": "--", "text": "--", "parent": 338, "children": [], "start_point": {"row": 96, "column": 14}, "end_point": {"row": 96, "column": 16}}, {"id": 343, "type": "break_statement", "text": "break;", "parent": 310, "children": [344], "start_point": {"row": 97, "column": 3}, "end_point": {"row": 97, "column": 9}}, {"id": 344, "type": "break", "text": "break", "parent": 343, "children": [], "start_point": {"row": 97, "column": 3}, "end_point": {"row": 97, "column": 8}}, {"id": 345, "type": "assignment_expression", "text": "pPrvEntry = pCurEntry", "parent": 303, "children": [346, 347, 348], "start_point": {"row": 99, "column": 2}, "end_point": {"row": 99, "column": 23}}, {"id": 346, "type": "identifier", "text": "pPrvEntry", "parent": 345, "children": [], "start_point": {"row": 99, "column": 2}, "end_point": {"row": 99, "column": 11}}, {"id": 347, "type": "=", "text": "=", "parent": 345, "children": [], "start_point": {"row": 99, "column": 12}, "end_point": {"row": 99, "column": 13}}, {"id": 348, "type": "identifier", "text": "pCurEntry", "parent": 345, "children": [], "start_point": {"row": 99, "column": 14}, "end_point": {"row": 99, "column": 23}}, {"id": 349, "type": "assignment_expression", "text": "pCurEntry = pPrvEntry->pNext", "parent": 303, "children": [350, 351, 352], "start_point": {"row": 100, "column": 2}, "end_point": {"row": 100, "column": 30}}, {"id": 350, "type": "identifier", "text": "pCurEntry", "parent": 349, "children": [], "start_point": {"row": 100, "column": 2}, "end_point": {"row": 100, "column": 11}}, {"id": 351, "type": "=", "text": "=", "parent": 349, "children": [], "start_point": {"row": 100, "column": 12}, "end_point": {"row": 100, "column": 13}}, {"id": 352, "type": "field_expression", "text": "pPrvEntry->pNext", "parent": 349, "children": [353, 354], "start_point": {"row": 100, "column": 14}, "end_point": {"row": 100, "column": 30}}, {"id": 353, "type": "identifier", "text": "pPrvEntry", "parent": 352, "children": [], "start_point": {"row": 100, "column": 14}, "end_point": {"row": 100, "column": 23}}, {"id": 354, "type": "field_identifier", "text": "pNext", "parent": 352, "children": [], "start_point": {"row": 100, "column": 25}, "end_point": {"row": 100, "column": 30}}, {"id": 355, "type": "return_statement", "text": "return pCurEntry;", "parent": 211, "children": [356], "start_point": {"row": 103, "column": 1}, "end_point": {"row": 103, "column": 18}}, {"id": 356, "type": "identifier", "text": "pCurEntry", "parent": 355, "children": [], "start_point": {"row": 103, "column": 8}, "end_point": {"row": 103, "column": 17}}, {"id": 357, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 106, "column": 0}, "end_point": {"row": 106, "column": 6}}]}, "node_categories": {"declarations": {"functions": [40, 44, 71, 75, 127, 131, 195, 199, 211, 215], "variables": [6, 11, 22, 27, 30, 33, 47, 78, 83, 134, 139, 142, 202, 218, 223, 228, 231], "classes": [8, 9, 12, 13, 24, 25, 41, 72, 128, 196, 212], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [53, 58, 65, 89, 96, 97, 101, 102, 110, 116, 121, 122, 148, 152, 153, 154, 163, 164, 169, 175, 176, 182, 188, 189, 208, 235, 236, 237, 247, 248, 251, 257, 261, 265, 269, 270, 271, 278, 284, 285, 294, 300, 304, 305, 311, 312, 317, 321, 325, 326, 329, 333, 338, 339, 352], "assignments": [52, 57, 64, 88, 100, 109, 115, 145, 160, 168, 181, 254, 260, 277, 291, 297, 316, 332, 345, 349], "loops": [303], "conditionals": [0, 1, 2, 5, 10, 14, 17, 18, 21, 26, 28, 29, 31, 32, 34, 35, 36, 39, 43, 45, 48, 49, 51, 54, 55, 59, 60, 66, 67, 74, 76, 79, 80, 82, 84, 85, 87, 90, 91, 95, 98, 99, 103, 104, 105, 107, 111, 112, 114, 117, 118, 120, 123, 124, 130, 132, 135, 136, 138, 140, 141, 143, 144, 146, 149, 150, 151, 155, 156, 161, 165, 166, 167, 170, 171, 173, 174, 177, 183, 184, 190, 191, 194, 200, 203, 204, 206, 209, 210, 214, 216, 219, 220, 222, 224, 225, 227, 229, 230, 232, 233, 234, 238, 239, 246, 249, 252, 253, 255, 258, 259, 262, 263, 266, 267, 268, 272, 273, 279, 280, 286, 287, 290, 292, 295, 296, 298, 301, 302, 306, 310, 313, 315, 318, 319, 322, 323, 324, 327, 330, 331, 334, 335, 337, 340, 341, 346, 348, 350, 353, 354, 356, 357], "returns": [70, 126, 193, 207, 243, 289, 355], "exceptions": []}, "expressions": {"calls": [], "literals": [69], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 40, "universal_type": "function", "name": "unknown", "text_snippet": "static inline VOID initList(\n\tIN PLIST_HEADER pList)\n{\n\tpList->pHead = pList->pTail = NULL;\n\tpList->"}, {"node_id": 44, "universal_type": "function", "name": "unknown", "text_snippet": "initList(\n\tIN PLIST_HEADER pList)"}, {"node_id": 71, "universal_type": "function", "name": "unknown", "text_snippet": "static inline VOID insertTailList(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)\n{\n\tpEntry->pNext "}, {"node_id": 75, "universal_type": "function", "name": "unknown", "text_snippet": "insertTailList(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)"}, {"node_id": 127, "universal_type": "function", "name": "unknown", "text_snippet": "static inline PLIST_ENTRY removeHeadList(\n\tIN PLIST_HEADER pList)\n{\n\tPLIST_ENTRY pNext;\n\tPLIST_ENTRY"}, {"node_id": 131, "universal_type": "function", "name": "unknown", "text_snippet": "removeHeadList(\n\tIN PLIST_HEADER pList)"}, {"node_id": 195, "universal_type": "function", "name": "getListSize", "text_snippet": "static inline int getListSize(\n\tIN PLIST_HEADER pList)\n{\n\treturn pList->size;\n}"}, {"node_id": 199, "universal_type": "function", "name": "unknown", "text_snippet": "getListSize(\n\tIN PLIST_HEADER pList)"}, {"node_id": 211, "universal_type": "function", "name": "unknown", "text_snippet": "static inline PLIST_ENTRY delEntryList(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)\n{\n\tPLIST_ENT"}, {"node_id": 215, "universal_type": "function", "name": "unknown", "text_snippet": "delEntryList(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)"}], "class_declarations": [{"node_id": 8, "universal_type": "class", "name": "_LIST_ENTRY", "text_snippet": "struct _LIST_ENTRY\n{\n\tstruct _LIST_ENTRY *pNext;\n}"}, {"node_id": 9, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 12, "universal_type": "class", "name": "_LIST_ENTRY", "text_snippet": "struct _LIST_ENTRY"}, {"node_id": 13, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 24, "universal_type": "class", "name": "_LIST_HEADR", "text_snippet": "struct _LIST_HEADR\n{\n\tPLIST_ENTRY pHead;\n\tPLIST_ENTRY pTail;\n\tUCHAR size;\n}"}, {"node_id": 25, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 41, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}, {"node_id": 72, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}, {"node_id": 128, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}, {"node_id": 196, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}, {"node_id": 212, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}], "import_statements": []}, "original_source_code": "\n#ifndef __LINK_LIST_H__\n#define __LINK_LIST_H__\n\ntypedef struct _LIST_ENTRY\n{\n\tstruct _LIST_ENTRY *pNext;\n} LIST_ENTRY, *PLIST_ENTRY;\n\ntypedef struct _LIST_HEADR\n{\n\tPLIST_ENTRY pHead;\n\tPLIST_ENTRY pTail;\n\tUCHAR size;\n} LIST_HEADER, *PLIST_HEADER;\n\nstatic inline VOID initList(\n\tIN PLIST_HEADER pList)\n{\n\tpList->pHead = pList->pTail = NULL;\n\tpList->size = 0;\n\treturn;\n}\n\nstatic inline VOID insertTailList(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)\n{\n\tpEntry->pNext = NULL;\n\tif (pList->pTail)\n\t\tpList->pTail->pNext = pEntry;\n\telse\n\t\tpList->pHead = pEntry;\n\tpList->pTail = pEntry;\n\tpList->size++;\n\n\treturn;\n}\n\nstatic inline PLIST_ENTRY removeHeadList(\n\tIN PLIST_HEADER pList)\n{\n\tPLIST_ENTRY pNext;\n\tPLIST_ENTRY pEntry;\n\n\tpEntry = pList->pHead;\n\tif (pList->pHead != NULL)\n\t{\n\t\tpNext = pList->pHead->pNext;\n\t\tpList->pHead = pNext;\n\t\tif (pNext == NULL)\n\t\t\tpList->pTail = NULL;\n\t\tpList->size--;\n\t}\n\treturn pEntry;\n}\n\nstatic inline int getListSize(\n\tIN PLIST_HEADER pList)\n{\n\treturn pList->size;\n}\n\nstatic inline PLIST_ENTRY delEntryList(\n\tIN PLIST_HEADER pList,\n\tIN PLIST_ENTRY pEntry)\n{\n\tPLIST_ENTRY pCurEntry;\n\tPLIST_ENTRY pPrvEntry;\n\n\tif(pList->pHead == NULL)\n\t\treturn NULL;\n\n\tif(pEntry == pList->pHead)\n\t{\n\t\tpCurEntry = pList->pHead;\n\t\tpList->pHead = pCurEntry->pNext;\n\n\t\tif(pList->pHead == NULL)\n\t\t\tpList->pTail = NULL;\n\n\t\tpList->size--;\n\t\treturn pCurEntry;\n\t}\n\n\tpPrvEntry = pList->pHead;\n\tpCurEntry = pPrvEntry->pNext;\n\twhile(pCurEntry != NULL)\n\t{\n\t\tif (pEntry == pCurEntry)\n\t\t{\n\t\t\tpPrvEntry->pNext = pCurEntry->pNext;\n\n\t\t\tif(pEntry == pList->pTail)\n\t\t\t\tpList->pTail = pPrvEntry;\n\n\t\t\tpList->size--;\n\t\t\tbreak;\n\t\t}\n\t\tpPrvEntry = pCurEntry;\n\t\tpCurEntry = pPrvEntry->pNext;\n\t}\n\n\treturn pCurEntry;\n}\n\n#endif // ___LINK_LIST_H__ //\n\n"}
80,554
c
// // LZPhotoListBrowseViewConfigModel.h // LZPhotoBrowser // // Created by Dear.Q on 2020/3/31. // #import <Foundation/Foundation.h> #import "LZPhotoBrowserAppearanceModel.h" NS_ASSUME_NONNULL_BEGIN @interface LZPhotoListBrowseViewConfigModel : NSObject /// 默认配置 + (LZPhotoListBrowseViewConfigModel * (^)(void))defaultConfig; @property (nonatomic, strong, readonly) id sender; - (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet; // MARK: <设置外观> /// 外观 @property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig; /// 外观设置 - (LZPhotoListBrowseViewConfigModel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet; // MARK: <计算 Frame> /// 最大显示数量 @property (nonatomic, assign, readonly) NSUInteger maxShowCount; /// 图片实际张数 @property (nonatomic, assign, readonly) NSUInteger maxCount; /// 高度 @property (nonatomic, assign, readonly) CGFloat height; /// Frame 数组 @property (nonatomic, strong, readonly) NSArray *frameDataSource; /// 设置图片最大展示张数,默认 4 - (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet; /// 设置图片实际张数,默认 4 - (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet; /// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width - (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet; /// 设置边距,默认 UIEdgeInsetsZero - (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet; /// 设置间距,默认 6.0 - (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet; /// 开始计算高度和 Frame - (LZPhotoListBrowseViewConfigModel * (^)(void))calcu; @end LZPhotoListBrowseViewConfigModel * defaultConfig(void); NS_ASSUME_NONNULL_END
36.14
43
(translation_unit) "//\n// LZPhotoListBrowseViewConfigModel.h\n// LZPhotoBrowser\n//\n// Created by Dear.Q on 2020/3/31.\n//\n\n#import <Foundation/Foundation.h>\n#import "LZPhotoBrowserAppearanceModel.h"\n\nNS_ASSUME_NONNULL_BEGIN\n\n@interface LZPhotoListBrowseViewConfigModel : NSObject\n\n/// 默认配置\n+ (LZPhotoListBrowseViewConfigModel * (^)(void))defaultConfig;\n@property (nonatomic, strong, readonly) id sender;\n- (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <设置外观>\n/// 外观\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig;\n/// 外观设置\n- (LZPhotoListBrowseViewConfigModel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <计算 Frame>\n/// 最大显示数量\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// 图片实际张数\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// 高度\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame 数组\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// 设置图片最大展示张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// 设置边距,默认 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// 开始计算高度和 Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n" (comment) "//" (comment) "// LZPhotoListBrowseViewConfigModel.h" (comment) "// LZPhotoBrowser" (comment) "//" (comment) "// Created by Dear.Q on 2020/3/31." (comment) "//" (preproc_call) "#import <Foundation/Foundation.h>\n" (preproc_directive) "#import" (preproc_arg) "<Foundation/Foundation.h>" (preproc_call) "#import "LZPhotoBrowserAppearanceModel.h"\n" (preproc_directive) "#import" (preproc_arg) ""LZPhotoBrowserAppearanceModel.h"" (declaration) "NS_ASSUME_NONNULL_BEGIN\n\n@interface" (type_identifier) "NS_ASSUME_NONNULL_BEGIN" (ERROR) "@" (ERROR) "@" (identifier) "interface" (;) "" (labeled_statement) "LZPhotoListBrowseViewConfigModel : NSObject\n\n/// 默认配置\n+ (LZPhotoListBrowseViewConfigModel * (^)(void))defaultConfig;\n@property (nonatomic, strong, readonly) id sender;\n- (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <设置外观>\n/// 外观\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig;\n/// 外观设置\n- (LZPhotoListBrowseViewConfigModel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <计算 Frame>\n/// 最大显示数量\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// 图片实际张数\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// 高度\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame 数组\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// 设置图片最大展示张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// 设置边距,默认 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// 开始计算高度和 Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n" (statement_identifier) "LZPhotoListBrowseViewConfigModel" (:) ":" (expression_statement) "NSObject\n\n/// 默认配置\n+ (LZPhotoListBrowseViewConfigModel * (^)(void))defaultConfig;\n@property (nonatomic, strong, readonly) id sender;\n- (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <设置外观>\n/// 外观\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig;\n/// 外观设置\n- (LZPhotoListBrowseViewConfigModel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <计算 Frame>\n/// 最大显示数量\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// 图片实际张数\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// 高度\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame 数组\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// 设置图片最大展示张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// 设置边距,默认 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// 开始计算高度和 Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n" (binary_expression) "NSObject\n\n/// 默认配置\n+ (LZPhotoListBrowseViewConfigModel * (^)(void))defaultConfig;\n@property (nonatomic, strong, readonly) id sender;\n- (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <设置外观>\n/// 外观\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig;\n/// 外观设置\n- (LZPhotoListBrowseViewConfigModel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <计算 Frame>\n/// 最大显示数量\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// 图片实际张数\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// 高度\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame 数组\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// 设置图片最大展示张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// 设置边距,默认 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// 开始计算高度和 Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n" (identifier) "NSObject" (comment) "/// 默认配置\n+ (LZPh" (+) "t" (parenthesized_expression) "ListBrowseViewConfigModel * (^)(void))defaultConfig;\n@property (nonatomic, strong, readonly) id sender;\n- (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <设置外观>\n/// 外观\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig;\n/// 外观设置\n- (LZPhotoListBrowseViewConfigModel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <计算 Frame>\n/// 最大显示数量\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// 图片实际张数\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// 高度\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame 数组\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// 设置图片最大展示张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// 设置边距,默认 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// 开始计算高度和 Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n" (() "L" (ERROR) "istBrowseViewConfigModel * (^)(void))defaultConfig;\n@property (nonatomic, strong, readonly) id sender;" (binary_expression) "istBrowseViewConfigModel * (^)(void))defaultConfig;\n@prope" (identifier) "istBrowseViewConfigModel * (^)(v" (*) "i" (cast_expression) "))defaultConfig;\n@prope" (() ")" (ERROR) ")de" (^) ")" ()) "d" (() "e" (type_descriptor) "faul" (primitive_type) "faul" ()) "t" (ERROR) "C" ()) "C" (identifier) "onfig;\n@prope" (;) "r" (ERROR) "y" (call_expression) " (nonatomic, strong, readonly) id send" (identifier) " (nonato" (argument_list) "ic, strong, readonly) id send" (() "i" (identifier) "c, strong" (,) "," (identifier) "readon" (,) "l" (identifier) ") id sen" ()) "d" (identifier) "r;" (binary_expression) "- (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <设置外观>\n/// 外观\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig;\n/// 外观设置\n- (LZPhotoListBrowseViewConfigModel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <计算 Frame>\n/// 最大显示数量\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// 图片实际张数\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// 高度\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame 数组\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// 设置图片最大展示张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// 设置边距,默认 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// 开始计算高度和 Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n" (binary_expression) "- (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <设置外观>\n/// 外观\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig;\n/// 外观设置\n- (LZPhot" (identifier) "- (LZP" (ERROR) "h" (;) "h" (-) "t" (ERROR) "ListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <设置外观>\n/// 外观\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppea" (parenthesized_expression) "ListBrowseViewConfigModel * (^)(id sender))senderSe" (() "L" (binary_expression) "istBrowseViewConfigModel * (^)(id sender))senderS" (identifier) "istBrowseViewConfigModel * (^)(i" (*) " " (parenthesized_expression) "ender))senderS" (() "e" (ERROR) "nder)" (^) "n" ()) "d" (() "e" (identifier) "r)" (identifier) "sender" ()) "S" ()) "e" (identifier) "t;\n\n// MA" (;) "R" (comment) " <设置外观>\n/// 外观\n@propert" (comment) " (nonatomi" (ERROR) "," (call_expression) " strong, readonly) LZPhotoBrowserAppea" (identifier) " strong," (argument_list) "readonly) LZPhotoBrowserAppea" (() "r" (identifier) "eadonly) " (,) "L" (identifier) "PhotoB" (,) "r" (identifier) "wserAppe" ()) "a" (binary_expression) "anceModel *appearanceConfig;\n/// 外观设置\n- (LZPhot" (identifier) "anceModel *appearanceConfig;\n" (*) "/" (identifier) "/ 外观设置\n- (LZPhot" (ERROR) "o" (;) "o" (comment) "istBrowseViewCon" (-) "i" (binary_expression) "Model * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <计算 Frame>\n/// 最大显示数量\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// 图片实际张数\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// 高度\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame 数组\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// 设置图片最大展示张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// 设置边距,默认 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// 开始计算高度和 Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n" (parenthesized_expression) "Model * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <计算 Frame>\n/// 最大显示数量\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// 图片实际张数\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// 高度\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame 数组\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// 设置图片最大展示张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// 设置边距,默认 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// 开始计算高度和 Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n" (() "M" (ERROR) "odel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <计算 Frame>\n/// 最大显示数量\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// 图片实际张数\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// 高度\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame 数组\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// 设置图片最大展示张数,默认 4\n- (LZPhotoListBro" (binary_expression) "odel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <计算 Frame>\n/// 最" (identifier) "odel * (^)(LZPhotoBrowserAppeara" (*) "c" (cast_expression) "Model *))appearanceConfigSet;\n\n// MARK: <计算 Frame>\n/// 最" (() "M" (ERROR) "ode" (^) "o" ()) "d" (() "e" (type_descriptor) "l *))appearanceConfigSet;\n\n// M" (type_identifier) "l *))appearanceConfigSet;\n\n//" (abstract_pointer_declarator) "M" (*) "M" ()) "A" (ERROR) "R" ()) "R" (identifier) "K: <计算 Frame>\n/// 最" (;) "大" (comment) "数量\n@property (nonatomic" (comment) " assign, readonly) NSU" (ERROR) "n" (call_expression) "teger maxShowCount;\n/// 图片实际张数\n@proper" (identifier) "teger ma" (argument_list) "ShowCount;\n/// 图片实际张数\n@proper" (() "S" (identifier) "howCount;" (,) "\n" (identifier) "// 图片实" (,) "际" (identifier) "数\n@prope" ()) "r" (identifier) "y (nonatom" (identifier) "c, assign, r" (;) "e" (comment) "donly) NSUInteger maxC" (ERROR) "u" (call_expression) "nt;\n/// 高度\n@property (nonatomic, assig" (identifier) "nt;\n/// " (argument_list) "度\n@property (nonatomic, assig" (() "度" (identifier) "\n@propert" (,) "y" (identifier) "(nonat" (,) "o" (identifier) "ic, assi" ()) "g" (identifier) ", readonly" (identifier) " CGFloat" (;) " " (comment) "eight;\n///" (ERROR) "F" (call_expression) "rame 数组\n@property (nonatomic, strong, " (identifier) "rame 数组\n" (argument_list) "property (nonatomic, strong, " (() "p" (identifier) "roperty (" (,) "n" (identifier) "natomi" (,) "c" (identifier) " strong," ()) " " (identifier) "eadonly" (identifier) " NSArr" (;) "a" (comment) " *frameDataSourc" (ERROR) ";" (call_expression) "\n/// 设置图片最大展示张数,默认 4\n- (LZPhotoListBro" (identifier) "\n/// 设置图" (argument_list) "最大展示张数,默认 4\n- (LZPhotoListBro" (() "最" (identifier) "大展示张数,默认 " (,) "4" (identifier) "- (LZP" (,) "h" (identifier) "toListBr" ()) "o" (binary_expression) "seViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// 设置边距,默认 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// 开始计算高度和 Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n" (binary_expression) "seViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// 设置边距,默认 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// 开始计算高度和 Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME" (binary_expression) "seViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// 设置边距,默认 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// 开始计算高度和 Frame\n- (LZPhotoListBrowseViewConfigModel " (binary_expression) "seViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// 设置边距,默认 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (LZ" (binary_expression) "seViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// 设置最大宽度,默认 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGF" (binary_expression) "seViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))m" (binary_expression) "seViewConfigModel * (^)(" (identifier) "seViewC" (*) "n" (identifier) "figModel * (^)(" (ERROR) "N" (;) "N" (comment) "UInteger))maxShowCountSet;\n/// 设置图片实际张数,默认 4\n" (-) " " (parenthesized_expression) "LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))m" (() "L" (binary_expression) "ZPhotoListBrowseViewConfigModel * (^)(NSUInteger))" (identifier) "ZPhotoListBrowseViewConfigModel " (*) " " (parenthesized_expression) "^)(NSUInteger))" (() "^" (ERROR) ")(N" (^) ")" ()) "(" (() "N" (identifier) "SUInteger)" ()) ")" ()) "m" (ERROR) "axCountSet;\n/// " (identifier) "axCountSet;\n///" (;) " " (comment) "置最大宽度,默认 [UIScreen mainScreen].bounds.s" (-) "z" (parenthesized_expression) ".width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGF" (() "." (binary_expression) "width\n- (LZPhotoListBrowseViewConfigModel * (^)(CG" (identifier) "width\n- (LZPhotoListBrowseViewCo" (*) "f" (parenthesized_expression) "gModel * (^)(CG" (() "g" (ERROR) "Mod" (^) "M" ()) "o" (() "d" (identifier) "el * (^)(C" ()) "G" ()) "F" (ERROR) "loat))maxWid" (identifier) "loat))maxWi" (;) "d" (comment) "hSet;\n/// 设置边距,默认 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel " (-) " " (parenthesized_expression) "^)(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (LZ" (() "^" (binary_expression) ")(UIEdgeInsets))insetsSet;\n/// 设置间距,默认 6.0\n- (L" (identifier) ")(UIEdgeInsets))insetsSet;\n/// 设" (*) "间" (parenthesized_expression) ",默认 6.0\n- (L" (() "," (ERROR) "默认 " (^) "默" ()) "认" (() " " (identifier) "6.0\n- (" ()) "L" ()) "Z" (ERROR) "PhotoListBro" (identifier) "PhotoListBr" (;) "o" (comment) "seViewConfigModel * (^)(CGFloat))spacingSe" (-) ";" (parenthesized_expression) "/// 开始计算高度和 Frame\n- (LZPhotoListBrowseViewConfigModel " (() "/" (binary_expression) "// 开始计算高度和 Frame\n- (LZPhotoListBrowseViewConfigModel" (identifier) "// 开始计算高度和 Frame\n- (LZPhotoListB" (*) "o" (parenthesized_expression) "seViewConfigModel" (() "s" (ERROR) "eVi" (^) "e" ()) "V" (() "i" (identifier) "ewConfigMode" ()) "l" ()) " " (ERROR) "* (^)(void" (identifier) "* (^)(voi" (;) "d" (comment) ")calcu;\n\n@end\n\nLZPhotoListBro" (-) "s" (parenthesized_expression) "ViewConfigModel * defaultConfig(void);\n\nNS_ASSUME" (() "V" (binary_expression) "iewConfigModel * defaultConfig(void);\n\nNS_ASSUM" (identifier) "iewConfigModel * defaultConfig(v" (*) "i" (parenthesized_expression) ");\n\nNS_ASSUM" (() ")" (ERROR) ";\n\n" (^) ";" ()) "\n" (() "\n" (identifier) "NS_ASSU" ()) "M" ()) "E" (ERROR) "_NONNULL_EN" (identifier) "_NONNULL_E" (;) "N" (comment) "\n" (-) "" (call_expression) "" (parenthesized_expression) "" (() "" (identifier) "" (ERROR) "" (*) "" (() "" (^) "" ()) "" (argument_list) "" (() "" (identifier) "" ()) "" ()) "" (ERROR) "" (identifier) "" (;) "" (ERROR) "" (identifier) "" (identifier) "" (*) "" (call_expression) "" (identifier) "" (argument_list) "" (() "" (identifier) "" ()) "" ()) "" (;) "" (expression_statement) "" (identifier) "" (;) ""
324
32
{"language": "c", "success": true, "metadata": {"lines": 43, "avg_line_length": 36.14, "nodes": 193, "errors": 0, "source_hash": "f2b4fd4502a0313329b95258838b2703e9b733cae3c2d7c48facbe17e003c2b9", "categorized_nodes": 120}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#import <Foundation/Foundation.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#import", "parent": 0, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "<Foundation/Foundation.h>", "parent": 0, "children": [], "start_point": {"row": 7, "column": 8}, "end_point": {"row": 7, "column": 33}}, {"id": 3, "type": "preproc_call", "text": "#import \"LZPhotoBrowserAppearanceModel.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 4, "type": "preproc_directive", "text": "#import", "parent": 3, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 7}}, {"id": 5, "type": "preproc_arg", "text": "\"LZPhotoBrowserAppearanceModel.h\"", "parent": 3, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 41}}, {"id": 6, "type": "declaration", "text": "NS_ASSUME_NONNULL_BEGIN\n\n@interface", "parent": null, "children": [7, 8, 10], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 12, "column": 10}}, {"id": 7, "type": "type_identifier", "text": "NS_ASSUME_NONNULL_BEGIN", "parent": 6, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 23}}, {"id": 8, "type": "ERROR", "text": "@", "parent": 6, "children": [9], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 1}}, {"id": 9, "type": "ERROR", "text": "@", "parent": 8, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 1}}, {"id": 10, "type": "identifier", "text": "interface", "parent": 6, "children": [], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 10}}, {"id": 11, "type": "labeled_statement", "text": "LZPhotoListBrowseViewConfigModel : NSObject\n\n/// \u9ed8\u8ba4\u914d\u7f6e\n+ (LZPhotoListBrowseViewConfigModel * (^)(void))defaultConfig;\n@property (nonatomic, strong, readonly) id sender;\n- (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <\u8bbe\u7f6e\u5916\u89c2>\n/// \u5916\u89c2\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig;\n/// \u5916\u89c2\u8bbe\u7f6e\n- (LZPhotoListBrowseViewConfigModel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <\u8ba1\u7b97 Frame>\n/// \u6700\u5927\u663e\u793a\u6570\u91cf\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// \u56fe\u7247\u5b9e\u9645\u5f20\u6570\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// \u9ad8\u5ea6\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame \u6570\u7ec4\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// \u8bbe\u7f6e\u56fe\u7247\u6700\u5927\u5c55\u793a\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// \u8bbe\u7f6e\u56fe\u7247\u5b9e\u9645\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// \u8bbe\u7f6e\u6700\u5927\u5bbd\u5ea6\uff0c\u9ed8\u8ba4 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// \u8bbe\u7f6e\u8fb9\u8ddd\uff0c\u9ed8\u8ba4 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// \u8bbe\u7f6e\u95f4\u8ddd\uff0c\u9ed8\u8ba4 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// \u5f00\u59cb\u8ba1\u7b97\u9ad8\u5ea6\u548c Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n", "parent": null, "children": [12], "start_point": {"row": 12, "column": 11}, "end_point": {"row": 49, "column": 55}}, {"id": 12, "type": "statement_identifier", "text": "LZPhotoListBrowseViewConfigModel", "parent": 11, "children": [], "start_point": {"row": 12, "column": 11}, "end_point": {"row": 12, "column": 43}}, {"id": 13, "type": "binary_expression", "text": "NSObject\n\n/// \u9ed8\u8ba4\u914d\u7f6e\n+ (LZPhotoListBrowseViewConfigModel * (^)(void))defaultConfig;\n@property (nonatomic, strong, readonly) id sender;\n- (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <\u8bbe\u7f6e\u5916\u89c2>\n/// \u5916\u89c2\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig;\n/// \u5916\u89c2\u8bbe\u7f6e\n- (LZPhotoListBrowseViewConfigModel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <\u8ba1\u7b97 Frame>\n/// \u6700\u5927\u663e\u793a\u6570\u91cf\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// \u56fe\u7247\u5b9e\u9645\u5f20\u6570\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// \u9ad8\u5ea6\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame \u6570\u7ec4\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// \u8bbe\u7f6e\u56fe\u7247\u6700\u5927\u5c55\u793a\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// \u8bbe\u7f6e\u56fe\u7247\u5b9e\u9645\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// \u8bbe\u7f6e\u6700\u5927\u5bbd\u5ea6\uff0c\u9ed8\u8ba4 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// \u8bbe\u7f6e\u8fb9\u8ddd\uff0c\u9ed8\u8ba4 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// \u8bbe\u7f6e\u95f4\u8ddd\uff0c\u9ed8\u8ba4 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// \u5f00\u59cb\u8ba1\u7b97\u9ad8\u5ea6\u548c Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n", "parent": 11, "children": [14, 15, 16], "start_point": {"row": 12, "column": 46}, "end_point": {"row": 49, "column": 54}}, {"id": 14, "type": "identifier", "text": "NSObject", "parent": 13, "children": [], "start_point": {"row": 12, "column": 46}, "end_point": {"row": 12, "column": 54}}, {"id": 15, "type": "+", "text": "t", "parent": 13, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 1}}, {"id": 16, "type": "parenthesized_expression", "text": "ListBrowseViewConfigModel * (^)(void))defaultConfig;\n@property (nonatomic, strong, readonly) id sender;\n- (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <\u8bbe\u7f6e\u5916\u89c2>\n/// \u5916\u89c2\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig;\n/// \u5916\u89c2\u8bbe\u7f6e\n- (LZPhotoListBrowseViewConfigModel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <\u8ba1\u7b97 Frame>\n/// \u6700\u5927\u663e\u793a\u6570\u91cf\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// \u56fe\u7247\u5b9e\u9645\u5f20\u6570\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// \u9ad8\u5ea6\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame \u6570\u7ec4\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// \u8bbe\u7f6e\u56fe\u7247\u6700\u5927\u5c55\u793a\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// \u8bbe\u7f6e\u56fe\u7247\u5b9e\u9645\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// \u8bbe\u7f6e\u6700\u5927\u5bbd\u5ea6\uff0c\u9ed8\u8ba4 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// \u8bbe\u7f6e\u8fb9\u8ddd\uff0c\u9ed8\u8ba4 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// \u8bbe\u7f6e\u95f4\u8ddd\uff0c\u9ed8\u8ba4 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// \u5f00\u59cb\u8ba1\u7b97\u9ad8\u5ea6\u548c Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n", "parent": 13, "children": [17, 35], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 49, "column": 54}}, {"id": 17, "type": "ERROR", "text": "istBrowseViewConfigModel * (^)(void))defaultConfig;\n@property (nonatomic, strong, readonly) id sender;", "parent": 16, "children": [18, 27, 28, 34], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 16, "column": 42}}, {"id": 18, "type": "binary_expression", "text": "istBrowseViewConfigModel * (^)(void))defaultConfig;\n@prope", "parent": 17, "children": [19, 20, 21], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 61}}, {"id": 19, "type": "identifier", "text": "istBrowseViewConfigModel * (^)(v", "parent": 18, "children": [], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 35}}, {"id": 20, "type": "*", "text": "i", "parent": 18, "children": [], "start_point": {"row": 15, "column": 36}, "end_point": {"row": 15, "column": 37}}, {"id": 21, "type": "cast_expression", "text": "))defaultConfig;\n@prope", "parent": 18, "children": [22, 23, 25, 26], "start_point": {"row": 15, "column": 38}, "end_point": {"row": 15, "column": 61}}, {"id": 22, "type": "ERROR", "text": ")de", "parent": 21, "children": [], "start_point": {"row": 15, "column": 39}, "end_point": {"row": 15, "column": 42}}, {"id": 23, "type": "type_descriptor", "text": "faul", "parent": 21, "children": [24], "start_point": {"row": 15, "column": 42}, "end_point": {"row": 15, "column": 46}}, {"id": 24, "type": "primitive_type", "text": "faul", "parent": 23, "children": [], "start_point": {"row": 15, "column": 42}, "end_point": {"row": 15, "column": 46}}, {"id": 25, "type": "ERROR", "text": "C", "parent": 21, "children": [], "start_point": {"row": 15, "column": 47}, "end_point": {"row": 15, "column": 48}}, {"id": 26, "type": "identifier", "text": "onfig;\n@prope", "parent": 21, "children": [], "start_point": {"row": 15, "column": 48}, "end_point": {"row": 15, "column": 61}}, {"id": 27, "type": "ERROR", "text": "y", "parent": 17, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 1}}, {"id": 28, "type": "call_expression", "text": " (nonatomic, strong, readonly) id send", "parent": 17, "children": [29, 30], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 39}}, {"id": 29, "type": "identifier", "text": " (nonato", "parent": 28, "children": [], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 9}}, {"id": 30, "type": "argument_list", "text": "ic, strong, readonly) id send", "parent": 28, "children": [31, 32, 33], "start_point": {"row": 16, "column": 10}, "end_point": {"row": 16, "column": 39}}, {"id": 31, "type": "identifier", "text": "c, strong", "parent": 30, "children": [], "start_point": {"row": 16, "column": 11}, "end_point": {"row": 16, "column": 20}}, {"id": 32, "type": "identifier", "text": "readon", "parent": 30, "children": [], "start_point": {"row": 16, "column": 22}, "end_point": {"row": 16, "column": 28}}, {"id": 33, "type": "identifier", "text": ") id sen", "parent": 30, "children": [], "start_point": {"row": 16, "column": 30}, "end_point": {"row": 16, "column": 38}}, {"id": 34, "type": "identifier", "text": "r;", "parent": 17, "children": [], "start_point": {"row": 16, "column": 40}, "end_point": {"row": 16, "column": 42}}, {"id": 35, "type": "binary_expression", "text": "- (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <\u8bbe\u7f6e\u5916\u89c2>\n/// \u5916\u89c2\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig;\n/// \u5916\u89c2\u8bbe\u7f6e\n- (LZPhotoListBrowseViewConfigModel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <\u8ba1\u7b97 Frame>\n/// \u6700\u5927\u663e\u793a\u6570\u91cf\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// \u56fe\u7247\u5b9e\u9645\u5f20\u6570\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// \u9ad8\u5ea6\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame \u6570\u7ec4\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// \u8bbe\u7f6e\u56fe\u7247\u6700\u5927\u5c55\u793a\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// \u8bbe\u7f6e\u56fe\u7247\u5b9e\u9645\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// \u8bbe\u7f6e\u6700\u5927\u5bbd\u5ea6\uff0c\u9ed8\u8ba4 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// \u8bbe\u7f6e\u8fb9\u8ddd\uff0c\u9ed8\u8ba4 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// \u8bbe\u7f6e\u95f4\u8ddd\uff0c\u9ed8\u8ba4 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// \u5f00\u59cb\u8ba1\u7b97\u9ad8\u5ea6\u548c Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n", "parent": 16, "children": [36, 61, 62, 63], "start_point": {"row": 16, "column": 43}, "end_point": {"row": 49, "column": 54}}, {"id": 36, "type": "binary_expression", "text": "- (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <\u8bbe\u7f6e\u5916\u89c2>\n/// \u5916\u89c2\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig;\n/// \u5916\u89c2\u8bbe\u7f6e\n- (LZPhot", "parent": 35, "children": [37, 38, 39, 40, 57], "start_point": {"row": 16, "column": 43}, "end_point": {"row": 21, "column": 87}}, {"id": 37, "type": "identifier", "text": "- (LZP", "parent": 36, "children": [], "start_point": {"row": 16, "column": 43}, "end_point": {"row": 16, "column": 49}}, {"id": 38, "type": "ERROR", "text": "h", "parent": 36, "children": [], "start_point": {"row": 16, "column": 49}, "end_point": {"row": 16, "column": 50}}, {"id": 39, "type": "-", "text": "t", "parent": 36, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 40, "type": "ERROR", "text": "ListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <\u8bbe\u7f6e\u5916\u89c2>\n/// \u5916\u89c2\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppea", "parent": 36, "children": [41, 50, 51], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 21, "column": 39}}, {"id": 41, "type": "parenthesized_expression", "text": "ListBrowseViewConfigModel * (^)(id sender))senderSe", "parent": 40, "children": [42], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 17, "column": 53}}, {"id": 42, "type": "binary_expression", "text": "istBrowseViewConfigModel * (^)(id sender))senderS", "parent": 41, "children": [43, 44, 45], "start_point": {"row": 17, "column": 3}, "end_point": {"row": 17, "column": 52}}, {"id": 43, "type": "identifier", "text": "istBrowseViewConfigModel * (^)(i", "parent": 42, "children": [], "start_point": {"row": 17, "column": 3}, "end_point": {"row": 17, "column": 35}}, {"id": 44, "type": "*", "text": " ", "parent": 42, "children": [], "start_point": {"row": 17, "column": 36}, "end_point": {"row": 17, "column": 37}}, {"id": 45, "type": "parenthesized_expression", "text": "ender))senderS", "parent": 42, "children": [46, 49], "start_point": {"row": 17, "column": 38}, "end_point": {"row": 17, "column": 52}}, {"id": 46, "type": "ERROR", "text": "nder)", "parent": 45, "children": [47, 48], "start_point": {"row": 17, "column": 39}, "end_point": {"row": 17, "column": 44}}, {"id": 47, "type": "^", "text": "n", "parent": 46, "children": [], "start_point": {"row": 17, "column": 39}, "end_point": {"row": 17, "column": 40}}, {"id": 48, "type": "identifier", "text": "r)", "parent": 46, "children": [], "start_point": {"row": 17, "column": 42}, "end_point": {"row": 17, "column": 44}}, {"id": 49, "type": "identifier", "text": "sender", "parent": 45, "children": [], "start_point": {"row": 17, "column": 45}, "end_point": {"row": 17, "column": 51}}, {"id": 50, "type": "identifier", "text": "t;\n\n// MA", "parent": 40, "children": [], "start_point": {"row": 17, "column": 53}, "end_point": {"row": 17, "column": 62}}, {"id": 51, "type": "call_expression", "text": " strong, readonly) LZPhotoBrowserAppea", "parent": 40, "children": [52, 53], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 39}}, {"id": 52, "type": "identifier", "text": " strong,", "parent": 51, "children": [], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 9}}, {"id": 53, "type": "argument_list", "text": "readonly) LZPhotoBrowserAppea", "parent": 51, "children": [54, 55, 56], "start_point": {"row": 21, "column": 10}, "end_point": {"row": 21, "column": 39}}, {"id": 54, "type": "identifier", "text": "eadonly) ", "parent": 53, "children": [], "start_point": {"row": 21, "column": 11}, "end_point": {"row": 21, "column": 20}}, {"id": 55, "type": "identifier", "text": "PhotoB", "parent": 53, "children": [], "start_point": {"row": 21, "column": 22}, "end_point": {"row": 21, "column": 28}}, {"id": 56, "type": "identifier", "text": "wserAppe", "parent": 53, "children": [], "start_point": {"row": 21, "column": 30}, "end_point": {"row": 21, "column": 38}}, {"id": 57, "type": "binary_expression", "text": "anceModel *appearanceConfig;\n/// \u5916\u89c2\u8bbe\u7f6e\n- (LZPhot", "parent": 36, "children": [58, 59, 60], "start_point": {"row": 21, "column": 40}, "end_point": {"row": 21, "column": 87}}, {"id": 58, "type": "identifier", "text": "anceModel *appearanceConfig;\n", "parent": 57, "children": [], "start_point": {"row": 21, "column": 40}, "end_point": {"row": 21, "column": 69}}, {"id": 59, "type": "*", "text": "/", "parent": 57, "children": [], "start_point": {"row": 21, "column": 70}, "end_point": {"row": 21, "column": 71}}, {"id": 60, "type": "identifier", "text": "/ \u5916\u89c2\u8bbe\u7f6e\n- (LZPhot", "parent": 57, "children": [], "start_point": {"row": 21, "column": 71}, "end_point": {"row": 21, "column": 87}}, {"id": 61, "type": "ERROR", "text": "o", "parent": 35, "children": [], "start_point": {"row": 21, "column": 87}, "end_point": {"row": 21, "column": 88}}, {"id": 62, "type": "-", "text": "i", "parent": 35, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 1}}, {"id": 63, "type": "binary_expression", "text": "Model * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <\u8ba1\u7b97 Frame>\n/// \u6700\u5927\u663e\u793a\u6570\u91cf\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// \u56fe\u7247\u5b9e\u9645\u5f20\u6570\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// \u9ad8\u5ea6\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame \u6570\u7ec4\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// \u8bbe\u7f6e\u56fe\u7247\u6700\u5927\u5c55\u793a\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// \u8bbe\u7f6e\u56fe\u7247\u5b9e\u9645\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// \u8bbe\u7f6e\u6700\u5927\u5bbd\u5ea6\uff0c\u9ed8\u8ba4 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// \u8bbe\u7f6e\u8fb9\u8ddd\uff0c\u9ed8\u8ba4 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// \u8bbe\u7f6e\u95f4\u8ddd\uff0c\u9ed8\u8ba4 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// \u5f00\u59cb\u8ba1\u7b97\u9ad8\u5ea6\u548c Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n", "parent": 35, "children": [64, 182, 187, 188], "start_point": {"row": 23, "column": 2}, "end_point": {"row": 49, "column": 54}}, {"id": 64, "type": "parenthesized_expression", "text": "Model * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <\u8ba1\u7b97 Frame>\n/// \u6700\u5927\u663e\u793a\u6570\u91cf\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// \u56fe\u7247\u5b9e\u9645\u5f20\u6570\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// \u9ad8\u5ea6\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame \u6570\u7ec4\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// \u8bbe\u7f6e\u56fe\u7247\u6700\u5927\u5c55\u793a\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// \u8bbe\u7f6e\u56fe\u7247\u5b9e\u9645\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// \u8bbe\u7f6e\u6700\u5927\u5bbd\u5ea6\uff0c\u9ed8\u8ba4 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// \u8bbe\u7f6e\u8fb9\u8ddd\uff0c\u9ed8\u8ba4 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// \u8bbe\u7f6e\u95f4\u8ddd\uff0c\u9ed8\u8ba4 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// \u5f00\u59cb\u8ba1\u7b97\u9ad8\u5ea6\u548c Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n", "parent": 63, "children": [65, 111], "start_point": {"row": 23, "column": 2}, "end_point": {"row": 45, "column": 48}}, {"id": 65, "type": "ERROR", "text": "odel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <\u8ba1\u7b97 Frame>\n/// \u6700\u5927\u663e\u793a\u6570\u91cf\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// \u56fe\u7247\u5b9e\u9645\u5f20\u6570\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// \u9ad8\u5ea6\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame \u6570\u7ec4\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// \u8bbe\u7f6e\u56fe\u7247\u6700\u5927\u5c55\u793a\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBro", "parent": 64, "children": [66, 78, 79, 85, 86, 87, 88, 94, 95, 96, 97, 103, 104, 105], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 33, "column": 39}}, {"id": 66, "type": "binary_expression", "text": "odel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <\u8ba1\u7b97 Frame>\n/// \u6700", "parent": 65, "children": [67, 68, 69], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 23, "column": 94}}, {"id": 67, "type": "identifier", "text": "odel * (^)(LZPhotoBrowserAppeara", "parent": 66, "children": [], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 23, "column": 35}}, {"id": 68, "type": "*", "text": "c", "parent": 66, "children": [], "start_point": {"row": 23, "column": 36}, "end_point": {"row": 23, "column": 37}}, {"id": 69, "type": "cast_expression", "text": "Model *))appearanceConfigSet;\n\n// MARK: <\u8ba1\u7b97 Frame>\n/// \u6700", "parent": 66, "children": [70, 72, 76, 77], "start_point": {"row": 23, "column": 38}, "end_point": {"row": 23, "column": 94}}, {"id": 70, "type": "ERROR", "text": "ode", "parent": 69, "children": [71], "start_point": {"row": 23, "column": 39}, "end_point": {"row": 23, "column": 42}}, {"id": 71, "type": "^", "text": "o", "parent": 70, "children": [], "start_point": {"row": 23, "column": 39}, "end_point": {"row": 23, "column": 40}}, {"id": 72, "type": "type_descriptor", "text": "l *))appearanceConfigSet;\n\n// M", "parent": 69, "children": [73, 74], "start_point": {"row": 23, "column": 42}, "end_point": {"row": 23, "column": 73}}, {"id": 73, "type": "type_identifier", "text": "l *))appearanceConfigSet;\n\n//", "parent": 72, "children": [], "start_point": {"row": 23, "column": 42}, "end_point": {"row": 23, "column": 71}}, {"id": 74, "type": "abstract_pointer_declarator", "text": "M", "parent": 72, "children": [75], "start_point": {"row": 23, "column": 72}, "end_point": {"row": 23, "column": 73}}, {"id": 75, "type": "*", "text": "M", "parent": 74, "children": [], "start_point": {"row": 23, "column": 72}, "end_point": {"row": 23, "column": 73}}, {"id": 76, "type": "ERROR", "text": "R", "parent": 69, "children": [], "start_point": {"row": 23, "column": 74}, "end_point": {"row": 23, "column": 75}}, {"id": 77, "type": "identifier", "text": "K: <\u8ba1\u7b97 Frame>\n/// \u6700", "parent": 69, "children": [], "start_point": {"row": 23, "column": 75}, "end_point": {"row": 23, "column": 94}}, {"id": 78, "type": "ERROR", "text": "n", "parent": 65, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 1}}, {"id": 79, "type": "call_expression", "text": "teger maxShowCount;\n/// \u56fe\u7247\u5b9e\u9645\u5f20\u6570\n@proper", "parent": 65, "children": [80, 81], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 39}}, {"id": 80, "type": "identifier", "text": "teger ma", "parent": 79, "children": [], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 9}}, {"id": 81, "type": "argument_list", "text": "ShowCount;\n/// \u56fe\u7247\u5b9e\u9645\u5f20\u6570\n@proper", "parent": 79, "children": [82, 83, 84], "start_point": {"row": 27, "column": 10}, "end_point": {"row": 27, "column": 39}}, {"id": 82, "type": "identifier", "text": "howCount;", "parent": 81, "children": [], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 20}}, {"id": 83, "type": "identifier", "text": "// \u56fe\u7247\u5b9e", "parent": 81, "children": [], "start_point": {"row": 27, "column": 22}, "end_point": {"row": 27, "column": 28}}, {"id": 84, "type": "identifier", "text": "\u6570\n@prope", "parent": 81, "children": [], "start_point": {"row": 27, "column": 30}, "end_point": {"row": 27, "column": 38}}, {"id": 85, "type": "identifier", "text": "y (nonatom", "parent": 65, "children": [], "start_point": {"row": 27, "column": 40}, "end_point": {"row": 27, "column": 50}}, {"id": 86, "type": "identifier", "text": "c, assign, r", "parent": 65, "children": [], "start_point": {"row": 27, "column": 51}, "end_point": {"row": 27, "column": 63}}, {"id": 87, "type": "ERROR", "text": "u", "parent": 65, "children": [], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 1}}, {"id": 88, "type": "call_expression", "text": "nt;\n/// \u9ad8\u5ea6\n@property (nonatomic, assig", "parent": 65, "children": [89, 90], "start_point": {"row": 29, "column": 1}, "end_point": {"row": 29, "column": 39}}, {"id": 89, "type": "identifier", "text": "nt;\n/// ", "parent": 88, "children": [], "start_point": {"row": 29, "column": 1}, "end_point": {"row": 29, "column": 9}}, {"id": 90, "type": "argument_list", "text": "\u5ea6\n@property (nonatomic, assig", "parent": 88, "children": [91, 92, 93], "start_point": {"row": 29, "column": 10}, "end_point": {"row": 29, "column": 39}}, {"id": 91, "type": "identifier", "text": "\n@propert", "parent": 90, "children": [], "start_point": {"row": 29, "column": 11}, "end_point": {"row": 29, "column": 20}}, {"id": 92, "type": "identifier", "text": "(nonat", "parent": 90, "children": [], "start_point": {"row": 29, "column": 22}, "end_point": {"row": 29, "column": 28}}, {"id": 93, "type": "identifier", "text": "ic, assi", "parent": 90, "children": [], "start_point": {"row": 29, "column": 30}, "end_point": {"row": 29, "column": 38}}, {"id": 94, "type": "identifier", "text": ", readonly", "parent": 65, "children": [], "start_point": {"row": 29, "column": 40}, "end_point": {"row": 29, "column": 50}}, {"id": 95, "type": "identifier", "text": " CGFloat", "parent": 65, "children": [], "start_point": {"row": 29, "column": 51}, "end_point": {"row": 29, "column": 59}}, {"id": 96, "type": "ERROR", "text": "F", "parent": 65, "children": [], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 31, "column": 1}}, {"id": 97, "type": "call_expression", "text": "rame \u6570\u7ec4\n@property (nonatomic, strong, ", "parent": 65, "children": [98, 99], "start_point": {"row": 31, "column": 1}, "end_point": {"row": 31, "column": 39}}, {"id": 98, "type": "identifier", "text": "rame \u6570\u7ec4\n", "parent": 97, "children": [], "start_point": {"row": 31, "column": 1}, "end_point": {"row": 31, "column": 9}}, {"id": 99, "type": "argument_list", "text": "property (nonatomic, strong, ", "parent": 97, "children": [100, 101, 102], "start_point": {"row": 31, "column": 10}, "end_point": {"row": 31, "column": 39}}, {"id": 100, "type": "identifier", "text": "roperty (", "parent": 99, "children": [], "start_point": {"row": 31, "column": 11}, "end_point": {"row": 31, "column": 20}}, {"id": 101, "type": "identifier", "text": "natomi", "parent": 99, "children": [], "start_point": {"row": 31, "column": 22}, "end_point": {"row": 31, "column": 28}}, {"id": 102, "type": "identifier", "text": " strong,", "parent": 99, "children": [], "start_point": {"row": 31, "column": 30}, "end_point": {"row": 31, "column": 38}}, {"id": 103, "type": "identifier", "text": "eadonly", "parent": 65, "children": [], "start_point": {"row": 31, "column": 40}, "end_point": {"row": 31, "column": 47}}, {"id": 104, "type": "identifier", "text": " NSArr", "parent": 65, "children": [], "start_point": {"row": 31, "column": 48}, "end_point": {"row": 31, "column": 54}}, {"id": 105, "type": "call_expression", "text": "\n/// \u8bbe\u7f6e\u56fe\u7247\u6700\u5927\u5c55\u793a\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBro", "parent": 65, "children": [106, 107], "start_point": {"row": 33, "column": 1}, "end_point": {"row": 33, "column": 39}}, {"id": 106, "type": "identifier", "text": "\n/// \u8bbe\u7f6e\u56fe", "parent": 105, "children": [], "start_point": {"row": 33, "column": 1}, "end_point": {"row": 33, "column": 9}}, {"id": 107, "type": "argument_list", "text": "\u6700\u5927\u5c55\u793a\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBro", "parent": 105, "children": [108, 109, 110], "start_point": {"row": 33, "column": 10}, "end_point": {"row": 33, "column": 39}}, {"id": 108, "type": "identifier", "text": "\u5927\u5c55\u793a\u5f20\u6570\uff0c\u9ed8\u8ba4 ", "parent": 107, "children": [], "start_point": {"row": 33, "column": 11}, "end_point": {"row": 33, "column": 20}}, {"id": 109, "type": "identifier", "text": "- (LZP", "parent": 107, "children": [], "start_point": {"row": 33, "column": 22}, "end_point": {"row": 33, "column": 28}}, {"id": 110, "type": "identifier", "text": "toListBr", "parent": 107, "children": [], "start_point": {"row": 33, "column": 30}, "end_point": {"row": 33, "column": 38}}, {"id": 111, "type": "binary_expression", "text": "seViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// \u8bbe\u7f6e\u56fe\u7247\u5b9e\u9645\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// \u8bbe\u7f6e\u6700\u5927\u5bbd\u5ea6\uff0c\u9ed8\u8ba4 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// \u8bbe\u7f6e\u8fb9\u8ddd\uff0c\u9ed8\u8ba4 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// \u8bbe\u7f6e\u95f4\u8ddd\uff0c\u9ed8\u8ba4 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// \u5f00\u59cb\u8ba1\u7b97\u9ad8\u5ea6\u548c Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n", "parent": 64, "children": [112, 171, 173, 174], "start_point": {"row": 33, "column": 40}, "end_point": {"row": 45, "column": 47}}, {"id": 112, "type": "binary_expression", "text": "seViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// \u8bbe\u7f6e\u56fe\u7247\u5b9e\u9645\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// \u8bbe\u7f6e\u6700\u5927\u5bbd\u5ea6\uff0c\u9ed8\u8ba4 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// \u8bbe\u7f6e\u8fb9\u8ddd\uff0c\u9ed8\u8ba4 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// \u8bbe\u7f6e\u95f4\u8ddd\uff0c\u9ed8\u8ba4 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// \u5f00\u59cb\u8ba1\u7b97\u9ad8\u5ea6\u548c Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME", "parent": 111, "children": [113, 162, 164, 165], "start_point": {"row": 33, "column": 40}, "end_point": {"row": 43, "column": 51}}, {"id": 113, "type": "binary_expression", "text": "seViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// \u8bbe\u7f6e\u56fe\u7247\u5b9e\u9645\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// \u8bbe\u7f6e\u6700\u5927\u5bbd\u5ea6\uff0c\u9ed8\u8ba4 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// \u8bbe\u7f6e\u8fb9\u8ddd\uff0c\u9ed8\u8ba4 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// \u8bbe\u7f6e\u95f4\u8ddd\uff0c\u9ed8\u8ba4 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// \u5f00\u59cb\u8ba1\u7b97\u9ad8\u5ea6\u548c Frame\n- (LZPhotoListBrowseViewConfigModel ", "parent": 112, "children": [114, 152, 154], "start_point": {"row": 33, "column": 40}, "end_point": {"row": 41, "column": 56}}, {"id": 114, "type": "binary_expression", "text": "seViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// \u8bbe\u7f6e\u56fe\u7247\u5b9e\u9645\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// \u8bbe\u7f6e\u6700\u5927\u5bbd\u5ea6\uff0c\u9ed8\u8ba4 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// \u8bbe\u7f6e\u8fb9\u8ddd\uff0c\u9ed8\u8ba4 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// \u8bbe\u7f6e\u95f4\u8ddd\uff0c\u9ed8\u8ba4 6.0\n- (LZ", "parent": 113, "children": [115, 141, 143, 144], "start_point": {"row": 33, "column": 40}, "end_point": {"row": 39, "column": 51}}, {"id": 115, "type": "binary_expression", "text": "seViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// \u8bbe\u7f6e\u56fe\u7247\u5b9e\u9645\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// \u8bbe\u7f6e\u6700\u5927\u5bbd\u5ea6\uff0c\u9ed8\u8ba4 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGF", "parent": 114, "children": [116, 130, 132, 133], "start_point": {"row": 33, "column": 40}, "end_point": {"row": 37, "column": 54}}, {"id": 116, "type": "binary_expression", "text": "seViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// \u8bbe\u7f6e\u56fe\u7247\u5b9e\u9645\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))m", "parent": 115, "children": [117, 121, 122, 123], "start_point": {"row": 33, "column": 40}, "end_point": {"row": 35, "column": 54}}, {"id": 117, "type": "binary_expression", "text": "seViewConfigModel * (^)(", "parent": 116, "children": [118, 119, 120], "start_point": {"row": 33, "column": 40}, "end_point": {"row": 33, "column": 64}}, {"id": 118, "type": "identifier", "text": "seViewC", "parent": 117, "children": [], "start_point": {"row": 33, "column": 40}, "end_point": {"row": 33, "column": 47}}, {"id": 119, "type": "*", "text": "n", "parent": 117, "children": [], "start_point": {"row": 33, "column": 48}, "end_point": {"row": 33, "column": 49}}, {"id": 120, "type": "identifier", "text": "figModel * (^)(", "parent": 117, "children": [], "start_point": {"row": 33, "column": 49}, "end_point": {"row": 33, "column": 64}}, {"id": 121, "type": "ERROR", "text": "N", "parent": 116, "children": [], "start_point": {"row": 33, "column": 64}, "end_point": {"row": 33, "column": 65}}, {"id": 122, "type": "-", "text": " ", "parent": 116, "children": [], "start_point": {"row": 35, "column": 0}, "end_point": {"row": 35, "column": 1}}, {"id": 123, "type": "parenthesized_expression", "text": "LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))m", "parent": 116, "children": [124], "start_point": {"row": 35, "column": 2}, "end_point": {"row": 35, "column": 54}}, {"id": 124, "type": "binary_expression", "text": "ZPhotoListBrowseViewConfigModel * (^)(NSUInteger))", "parent": 123, "children": [125, 126, 127], "start_point": {"row": 35, "column": 3}, "end_point": {"row": 35, "column": 53}}, {"id": 125, "type": "identifier", "text": "ZPhotoListBrowseViewConfigModel ", "parent": 124, "children": [], "start_point": {"row": 35, "column": 3}, "end_point": {"row": 35, "column": 35}}, {"id": 126, "type": "*", "text": " ", "parent": 124, "children": [], "start_point": {"row": 35, "column": 36}, "end_point": {"row": 35, "column": 37}}, {"id": 127, "type": "parenthesized_expression", "text": "^)(NSUInteger))", "parent": 124, "children": [128, 129], "start_point": {"row": 35, "column": 38}, "end_point": {"row": 35, "column": 53}}, {"id": 128, "type": "ERROR", "text": ")(N", "parent": 127, "children": [], "start_point": {"row": 35, "column": 39}, "end_point": {"row": 35, "column": 42}}, {"id": 129, "type": "identifier", "text": "SUInteger)", "parent": 127, "children": [], "start_point": {"row": 35, "column": 42}, "end_point": {"row": 35, "column": 52}}, {"id": 130, "type": "ERROR", "text": "axCountSet;\n/// ", "parent": 115, "children": [131], "start_point": {"row": 35, "column": 54}, "end_point": {"row": 35, "column": 70}}, {"id": 131, "type": "identifier", "text": "axCountSet;\n///", "parent": 130, "children": [], "start_point": {"row": 35, "column": 54}, "end_point": {"row": 35, "column": 69}}, {"id": 132, "type": "-", "text": "z", "parent": 115, "children": [], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 37, "column": 1}}, {"id": 133, "type": "parenthesized_expression", "text": ".width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGF", "parent": 115, "children": [134], "start_point": {"row": 37, "column": 2}, "end_point": {"row": 37, "column": 54}}, {"id": 134, "type": "binary_expression", "text": "width\n- (LZPhotoListBrowseViewConfigModel * (^)(CG", "parent": 133, "children": [135, 136, 137], "start_point": {"row": 37, "column": 3}, "end_point": {"row": 37, "column": 53}}, {"id": 135, "type": "identifier", "text": "width\n- (LZPhotoListBrowseViewCo", "parent": 134, "children": [], "start_point": {"row": 37, "column": 3}, "end_point": {"row": 37, "column": 35}}, {"id": 136, "type": "*", "text": "f", "parent": 134, "children": [], "start_point": {"row": 37, "column": 36}, "end_point": {"row": 37, "column": 37}}, {"id": 137, "type": "parenthesized_expression", "text": "gModel * (^)(CG", "parent": 134, "children": [138, 140], "start_point": {"row": 37, "column": 38}, "end_point": {"row": 37, "column": 53}}, {"id": 138, "type": "ERROR", "text": "Mod", "parent": 137, "children": [139], "start_point": {"row": 37, "column": 39}, "end_point": {"row": 37, "column": 42}}, {"id": 139, "type": "^", "text": "M", "parent": 138, "children": [], "start_point": {"row": 37, "column": 39}, "end_point": {"row": 37, "column": 40}}, {"id": 140, "type": "identifier", "text": "el * (^)(C", "parent": 137, "children": [], "start_point": {"row": 37, "column": 42}, "end_point": {"row": 37, "column": 52}}, {"id": 141, "type": "ERROR", "text": "loat))maxWid", "parent": 114, "children": [142], "start_point": {"row": 37, "column": 54}, "end_point": {"row": 37, "column": 66}}, {"id": 142, "type": "identifier", "text": "loat))maxWi", "parent": 141, "children": [], "start_point": {"row": 37, "column": 54}, "end_point": {"row": 37, "column": 65}}, {"id": 143, "type": "-", "text": " ", "parent": 114, "children": [], "start_point": {"row": 39, "column": 0}, "end_point": {"row": 39, "column": 1}}, {"id": 144, "type": "parenthesized_expression", "text": "^)(UIEdgeInsets))insetsSet;\n/// \u8bbe\u7f6e\u95f4\u8ddd\uff0c\u9ed8\u8ba4 6.0\n- (LZ", "parent": 114, "children": [145], "start_point": {"row": 39, "column": 2}, "end_point": {"row": 39, "column": 51}}, {"id": 145, "type": "binary_expression", "text": ")(UIEdgeInsets))insetsSet;\n/// \u8bbe\u7f6e\u95f4\u8ddd\uff0c\u9ed8\u8ba4 6.0\n- (L", "parent": 144, "children": [146, 147, 148], "start_point": {"row": 39, "column": 3}, "end_point": {"row": 39, "column": 50}}, {"id": 146, "type": "identifier", "text": ")(UIEdgeInsets))insetsSet;\n/// \u8bbe", "parent": 145, "children": [], "start_point": {"row": 39, "column": 3}, "end_point": {"row": 39, "column": 35}}, {"id": 147, "type": "*", "text": "\u95f4", "parent": 145, "children": [], "start_point": {"row": 39, "column": 36}, "end_point": {"row": 39, "column": 37}}, {"id": 148, "type": "parenthesized_expression", "text": "\uff0c\u9ed8\u8ba4 6.0\n- (L", "parent": 145, "children": [149, 151], "start_point": {"row": 39, "column": 38}, "end_point": {"row": 39, "column": 50}}, {"id": 149, "type": "ERROR", "text": "\u9ed8\u8ba4 ", "parent": 148, "children": [150], "start_point": {"row": 39, "column": 39}, "end_point": {"row": 39, "column": 42}}, {"id": 150, "type": "^", "text": "\u9ed8", "parent": 149, "children": [], "start_point": {"row": 39, "column": 39}, "end_point": {"row": 39, "column": 40}}, {"id": 151, "type": "identifier", "text": "6.0\n- (", "parent": 148, "children": [], "start_point": {"row": 39, "column": 42}, "end_point": {"row": 39, "column": 49}}, {"id": 152, "type": "ERROR", "text": "PhotoListBro", "parent": 113, "children": [153], "start_point": {"row": 39, "column": 51}, "end_point": {"row": 39, "column": 63}}, {"id": 153, "type": "identifier", "text": "PhotoListBr", "parent": 152, "children": [], "start_point": {"row": 39, "column": 51}, "end_point": {"row": 39, "column": 62}}, {"id": 154, "type": "parenthesized_expression", "text": "/// \u5f00\u59cb\u8ba1\u7b97\u9ad8\u5ea6\u548c Frame\n- (LZPhotoListBrowseViewConfigModel ", "parent": 113, "children": [155], "start_point": {"row": 41, "column": 2}, "end_point": {"row": 41, "column": 56}}, {"id": 155, "type": "binary_expression", "text": "// \u5f00\u59cb\u8ba1\u7b97\u9ad8\u5ea6\u548c Frame\n- (LZPhotoListBrowseViewConfigModel", "parent": 154, "children": [156, 157, 158], "start_point": {"row": 41, "column": 3}, "end_point": {"row": 41, "column": 55}}, {"id": 156, "type": "identifier", "text": "// \u5f00\u59cb\u8ba1\u7b97\u9ad8\u5ea6\u548c Frame\n- (LZPhotoListB", "parent": 155, "children": [], "start_point": {"row": 41, "column": 3}, "end_point": {"row": 41, "column": 35}}, {"id": 157, "type": "*", "text": "o", "parent": 155, "children": [], "start_point": {"row": 41, "column": 36}, "end_point": {"row": 41, "column": 37}}, {"id": 158, "type": "parenthesized_expression", "text": "seViewConfigModel", "parent": 155, "children": [159, 161], "start_point": {"row": 41, "column": 38}, "end_point": {"row": 41, "column": 55}}, {"id": 159, "type": "ERROR", "text": "eVi", "parent": 158, "children": [160], "start_point": {"row": 41, "column": 39}, "end_point": {"row": 41, "column": 42}}, {"id": 160, "type": "^", "text": "e", "parent": 159, "children": [], "start_point": {"row": 41, "column": 39}, "end_point": {"row": 41, "column": 40}}, {"id": 161, "type": "identifier", "text": "ewConfigMode", "parent": 158, "children": [], "start_point": {"row": 41, "column": 42}, "end_point": {"row": 41, "column": 54}}, {"id": 162, "type": "ERROR", "text": "* (^)(void", "parent": 112, "children": [163], "start_point": {"row": 41, "column": 56}, "end_point": {"row": 41, "column": 66}}, {"id": 163, "type": "identifier", "text": "* (^)(voi", "parent": 162, "children": [], "start_point": {"row": 41, "column": 56}, "end_point": {"row": 41, "column": 65}}, {"id": 164, "type": "-", "text": "s", "parent": 112, "children": [], "start_point": {"row": 43, "column": 0}, "end_point": {"row": 43, "column": 1}}, {"id": 165, "type": "parenthesized_expression", "text": "ViewConfigModel * defaultConfig(void);\n\nNS_ASSUME", "parent": 112, "children": [166], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 43, "column": 51}}, {"id": 166, "type": "binary_expression", "text": "iewConfigModel * defaultConfig(void);\n\nNS_ASSUM", "parent": 165, "children": [167, 168, 169], "start_point": {"row": 43, "column": 3}, "end_point": {"row": 43, "column": 50}}, {"id": 167, "type": "identifier", "text": "iewConfigModel * defaultConfig(v", "parent": 166, "children": [], "start_point": {"row": 43, "column": 3}, "end_point": {"row": 43, "column": 35}}, {"id": 168, "type": "*", "text": "i", "parent": 166, "children": [], "start_point": {"row": 43, "column": 36}, "end_point": {"row": 43, "column": 37}}, {"id": 169, "type": "parenthesized_expression", "text": ");\n\nNS_ASSUM", "parent": 166, "children": [170], "start_point": {"row": 43, "column": 38}, "end_point": {"row": 43, "column": 50}}, {"id": 170, "type": "identifier", "text": "NS_ASSU", "parent": 169, "children": [], "start_point": {"row": 43, "column": 42}, "end_point": {"row": 43, "column": 49}}, {"id": 171, "type": "ERROR", "text": "_NONNULL_EN", "parent": 111, "children": [172], "start_point": {"row": 43, "column": 51}, "end_point": {"row": 43, "column": 62}}, {"id": 172, "type": "identifier", "text": "_NONNULL_E", "parent": 171, "children": [], "start_point": {"row": 43, "column": 51}, "end_point": {"row": 43, "column": 61}}, {"id": 173, "type": "-", "text": "", "parent": 111, "children": [], "start_point": {"row": 45, "column": 0}, "end_point": {"row": 45, "column": 1}}, {"id": 174, "type": "call_expression", "text": "", "parent": 111, "children": [175, 180], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 47}}, {"id": 175, "type": "parenthesized_expression", "text": "", "parent": 174, "children": [176, 177], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 41}}, {"id": 176, "type": "identifier", "text": "", "parent": 175, "children": [], "start_point": {"row": 45, "column": 3}, "end_point": {"row": 45, "column": 35}}, {"id": 177, "type": "ERROR", "text": "", "parent": 175, "children": [178, 179], "start_point": {"row": 45, "column": 36}, "end_point": {"row": 45, "column": 40}}, {"id": 178, "type": "*", "text": "", "parent": 177, "children": [], "start_point": {"row": 45, "column": 36}, "end_point": {"row": 45, "column": 37}}, {"id": 179, "type": "^", "text": "", "parent": 177, "children": [], "start_point": {"row": 45, "column": 39}, "end_point": {"row": 45, "column": 40}}, {"id": 180, "type": "argument_list", "text": "", "parent": 174, "children": [181], "start_point": {"row": 45, "column": 41}, "end_point": {"row": 45, "column": 47}}, {"id": 181, "type": "identifier", "text": "", "parent": 180, "children": [], "start_point": {"row": 45, "column": 42}, "end_point": {"row": 45, "column": 46}}, {"id": 182, "type": "ERROR", "text": "", "parent": 63, "children": [183, 184, 185, 186], "start_point": {"row": 45, "column": 48}, "end_point": {"row": 49, "column": 32}}, {"id": 183, "type": "identifier", "text": "", "parent": 182, "children": [], "start_point": {"row": 45, "column": 48}, "end_point": {"row": 45, "column": 53}}, {"id": 184, "type": "ERROR", "text": "", "parent": 182, "children": [], "start_point": {"row": 47, "column": 0}, "end_point": {"row": 47, "column": 1}}, {"id": 185, "type": "identifier", "text": "", "parent": 182, "children": [], "start_point": {"row": 47, "column": 1}, "end_point": {"row": 47, "column": 4}}, {"id": 186, "type": "identifier", "text": "", "parent": 182, "children": [], "start_point": {"row": 49, "column": 0}, "end_point": {"row": 49, "column": 32}}, {"id": 187, "type": "*", "text": "", "parent": 63, "children": [], "start_point": {"row": 49, "column": 33}, "end_point": {"row": 49, "column": 34}}, {"id": 188, "type": "call_expression", "text": "", "parent": 63, "children": [189, 190], "start_point": {"row": 49, "column": 35}, "end_point": {"row": 49, "column": 54}}, {"id": 189, "type": "identifier", "text": "", "parent": 188, "children": [], "start_point": {"row": 49, "column": 35}, "end_point": {"row": 49, "column": 48}}, {"id": 190, "type": "argument_list", "text": "", "parent": 188, "children": [191], "start_point": {"row": 49, "column": 48}, "end_point": {"row": 49, "column": 54}}, {"id": 191, "type": "identifier", "text": "", "parent": 190, "children": [], "start_point": {"row": 49, "column": 49}, "end_point": {"row": 49, "column": 53}}, {"id": 192, "type": "identifier", "text": "", "parent": null, "children": [], "start_point": {"row": 51, "column": 0}, "end_point": {"row": 51, "column": 21}}]}, "node_categories": {"declarations": {"functions": [], "variables": [6], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [13, 16, 18, 21, 28, 35, 36, 41, 42, 45, 51, 57, 63, 64, 66, 69, 79, 88, 97, 105, 111, 112, 113, 114, 115, 116, 117, 123, 124, 127, 133, 134, 137, 144, 145, 148, 154, 155, 158, 165, 166, 169, 174, 175, 188], "assignments": [], "loops": [], "conditionals": [7, 10, 12, 14, 19, 26, 29, 31, 32, 33, 34, 37, 43, 48, 49, 50, 52, 54, 55, 56, 58, 60, 67, 73, 77, 80, 82, 83, 84, 85, 86, 89, 91, 92, 93, 94, 95, 98, 100, 101, 102, 103, 104, 106, 108, 109, 110, 118, 120, 125, 129, 131, 135, 140, 142, 146, 151, 153, 156, 161, 163, 167, 170, 172, 176, 181, 183, 185, 186, 189, 191, 192], "returns": [], "exceptions": []}, "expressions": {"calls": [0, 3], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// LZPhotoListBrowseViewConfigModel.h\n// LZPhotoBrowser\n//\n// Created by Dear.Q on 2020/3/31.\n//\n\n#import <Foundation/Foundation.h>\n#import \"LZPhotoBrowserAppearanceModel.h\"\n\nNS_ASSUME_NONNULL_BEGIN\n\n@interface LZPhotoListBrowseViewConfigModel : NSObject\n\n/// \u9ed8\u8ba4\u914d\u7f6e\n+ (LZPhotoListBrowseViewConfigModel * (^)(void))defaultConfig;\n@property (nonatomic, strong, readonly) id sender;\n- (LZPhotoListBrowseViewConfigModel * (^)(id sender))senderSet;\n\n// MARK: <\u8bbe\u7f6e\u5916\u89c2>\n/// \u5916\u89c2\n@property (nonatomic, strong, readonly) LZPhotoBrowserAppearanceModel *appearanceConfig;\n/// \u5916\u89c2\u8bbe\u7f6e\n- (LZPhotoListBrowseViewConfigModel * (^)(LZPhotoBrowserAppearanceModel *))appearanceConfigSet;\n\n// MARK: <\u8ba1\u7b97 Frame>\n/// \u6700\u5927\u663e\u793a\u6570\u91cf\n@property (nonatomic, assign, readonly) NSUInteger maxShowCount;\n/// \u56fe\u7247\u5b9e\u9645\u5f20\u6570\n@property (nonatomic, assign, readonly) NSUInteger maxCount;\n/// \u9ad8\u5ea6\n@property (nonatomic, assign, readonly) CGFloat height;\n/// Frame \u6570\u7ec4\n@property (nonatomic, strong, readonly) NSArray *frameDataSource;\n/// \u8bbe\u7f6e\u56fe\u7247\u6700\u5927\u5c55\u793a\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxShowCountSet;\n/// \u8bbe\u7f6e\u56fe\u7247\u5b9e\u9645\u5f20\u6570\uff0c\u9ed8\u8ba4 4\n- (LZPhotoListBrowseViewConfigModel * (^)(NSUInteger))maxCountSet;\n/// \u8bbe\u7f6e\u6700\u5927\u5bbd\u5ea6\uff0c\u9ed8\u8ba4 [UIScreen mainScreen].bounds.size.width\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))maxWidthSet;\n/// \u8bbe\u7f6e\u8fb9\u8ddd\uff0c\u9ed8\u8ba4 UIEdgeInsetsZero\n- (LZPhotoListBrowseViewConfigModel * (^)(UIEdgeInsets))insetsSet;\n/// \u8bbe\u7f6e\u95f4\u8ddd\uff0c\u9ed8\u8ba4 6.0\n- (LZPhotoListBrowseViewConfigModel * (^)(CGFloat))spacingSet;\n/// \u5f00\u59cb\u8ba1\u7b97\u9ad8\u5ea6\u548c Frame\n- (LZPhotoListBrowseViewConfigModel * (^)(void))calcu;\n\n@end\n\nLZPhotoListBrowseViewConfigModel * defaultConfig(void);\n\nNS_ASSUME_NONNULL_END\n"}
80,555
c
#ifndef GAG_BRANCH_INC #define GAG_BRANCH_INC #include <algorithm> #include <GAGPL/GLYCAN/Linkage.h> #include <GAGPL/GLYCAN/Monosaccharide.h> namespace gag { class Branch : public Unit { private: size_t branch_id; std::vector<Monosaccharide> mono_chain; std::vector<Composition> re_extension; // For glycan, there will be only one reducing end. // The mono_id and the linkage. std::vector<Linkage> links; public: Branch(const size_t id) : branch_id(id), mono_chain(), links() {} Branch(){} void addUnit(Monosaccharide& mono_unit); void addLinkage(const Linkage& link); void addExtension(Composition& compo); std::vector<Linkage> getNeighborLinks(const size_t mono_id); inline size_t getBranchID() const { return branch_id; } inline std::vector<Monosaccharide>& getGlycanChainUnits() { return mono_chain; } inline const std::vector<Monosaccharide>& getGlycanChainUnits() const { return mono_chain; } inline size_t getUnitNum() { return mono_chain.size(); } inline std::vector<Linkage>& getLinkages() { return links; } inline size_t getExtensionNum() { return re_extension.size(); } Composition getExtensionComposition(); inline Monosaccharide& getUnitByID(const size_t id) { return mono_chain.at(id); } // Calculate the mass and composition. The correction of the terminal mass will be considered. void update(); // Useful for calculating fragment mass. Composition getSubComposition(const size_t start, const size_t end); void printStructure(); }; } #endif /* ----- #ifndef GAG_BRANCH_INC ----- */
24.09
67
(translation_unit) "#ifndef GAG_BRANCH_INC\n#define GAG_BRANCH_INC\n\n#include <algorithm>\n#include <GAGPL/GLYCAN/Linkage.h>\n#include <GAGPL/GLYCAN/Monosaccharide.h>\n\nnamespace gag\n{\n class Branch : public Unit\n {\n private:\n size_t branch_id;\n \n std::vector<Monosaccharide> mono_chain;\n std::vector<Composition> re_extension;\n\n // For glycan, there will be only one reducing end.\n \n // The mono_id and the linkage.\n std::vector<Linkage> links;\n\n public:\n Branch(const size_t id)\n : branch_id(id), mono_chain(), links()\n {}\n Branch(){}\n\n void addUnit(Monosaccharide& mono_unit);\n \n void addLinkage(const Linkage& link);\n\n void addExtension(Composition& compo);\n\n std::vector<Linkage> getNeighborLinks(const size_t mono_id);\n\n inline size_t getBranchID() const\n {\n return branch_id;\n }\n\n inline std::vector<Monosaccharide>& getGlycanChainUnits()\n {\n return mono_chain;\n }\n inline const std::vector<Monosaccharide>& getGlycanChainUnits() const\n {\n return mono_chain;\n }\n\n inline size_t getUnitNum()\n {\n return mono_chain.size();\n }\n inline std::vector<Linkage>& getLinkages()\n {\n return links;\n }\n inline size_t getExtensionNum()\n {\n return re_extension.size();\n }\n\n Composition getExtensionComposition();\n\n inline Monosaccharide& getUnitByID(const size_t id)\n {\n return mono_chain.at(id);\n }\n \n // Calculate the mass and composition. The correction of the terminal mass will be considered.\n void update();\n\n // Useful for calculating fragment mass.\n Composition getSubComposition(const size_t start, const size_t end);\n \n void printStructure();\n };\n}\n\n#endif /* ----- #ifndef GAG_BRANCH_INC ----- */\n" (preproc_ifdef) "#ifndef GAG_BRANCH_INC\n#define GAG_BRANCH_INC\n\n#include <algorithm>\n#include <GAGPL/GLYCAN/Linkage.h>\n#include <GAGPL/GLYCAN/Monosaccharide.h>\n\nnamespace gag\n{\n class Branch : public Unit\n {\n private:\n size_t branch_id;\n \n std::vector<Monosaccharide> mono_chain;\n std::vector<Composition> re_extension;\n\n // For glycan, there will be only one reducing end.\n \n // The mono_id and the linkage.\n std::vector<Linkage> links;\n\n public:\n Branch(const size_t id)\n : branch_id(id), mono_chain(), links()\n {}\n Branch(){}\n\n void addUnit(Monosaccharide& mono_unit);\n \n void addLinkage(const Linkage& link);\n\n void addExtension(Composition& compo);\n\n std::vector<Linkage> getNeighborLinks(const size_t mono_id);\n\n inline size_t getBranchID() const\n {\n return branch_id;\n }\n\n inline std::vector<Monosaccharide>& getGlycanChainUnits()\n {\n return mono_chain;\n }\n inline const std::vector<Monosaccharide>& getGlycanChainUnits() const\n {\n return mono_chain;\n }\n\n inline size_t getUnitNum()\n {\n return mono_chain.size();\n }\n inline std::vector<Linkage>& getLinkages()\n {\n return links;\n }\n inline size_t getExtensionNum()\n {\n return re_extension.size();\n }\n\n Composition getExtensionComposition();\n\n inline Monosaccharide& getUnitByID(const size_t id)\n {\n return mono_chain.at(id);\n }\n \n // Calculate the mass and composition. The correction of the terminal mass will be considered.\n void update();\n\n // Useful for calculating fragment mass.\n Composition getSubComposition(const size_t start, const size_t end);\n \n void printStructure();\n };\n}\n\n#endif" (#ifndef) "#ifndef" (identifier) "GAG_BRANCH_INC" (preproc_def) "#define GAG_BRANCH_INC\n" (#define) "#define" (identifier) "GAG_BRANCH_INC" (preproc_include) "#include <algorithm>\n" (#include) "#include" (system_lib_string) "<algorithm>" (preproc_include) "#include <GAGPL/GLYCAN/Linkage.h>\n" (#include) "#include" (system_lib_string) "<GAGPL/GLYCAN/Linkage.h>" (preproc_include) "#include <GAGPL/GLYCAN/Monosaccharide.h>\n" (#include) "#include" (system_lib_string) "<GAGPL/GLYCAN/Monosaccharide.h>" (function_definition) "namespace gag\n{\n class Branch : public Unit\n {\n private:\n size_t branch_id;\n \n std::vector<Monosaccharide> mono_chain;\n std::vector<Composition> re_extension;\n\n // For glycan, there will be only one reducing end.\n \n // The mono_id and the linkage.\n std::vector<Linkage> links;\n\n public:\n Branch(const size_t id)\n : branch_id(id), mono_chain(), links()\n {}\n Branch(){}\n\n void addUnit(Monosaccharide& mono_unit);\n \n void addLinkage(const Linkage& link);\n\n void addExtension(Composition& compo);\n\n std::vector<Linkage> getNeighborLinks(const size_t mono_id);\n\n inline size_t getBranchID() const\n {\n return branch_id;\n }\n\n inline std::vector<Monosaccharide>& getGlycanChainUnits()\n {\n return mono_chain;\n }\n inline const std::vector<Monosaccharide>& getGlycanChainUnits() const\n {\n return mono_chain;\n }\n\n inline size_t getUnitNum()\n {\n return mono_chain.size();\n }\n inline std::vector<Linkage>& getLinkages()\n {\n return links;\n }\n inline size_t getExtensionNum()\n {\n return re_extension.size();\n }\n\n Composition getExtensionComposition();\n\n inline Monosaccharide& getUnitByID(const size_t id)\n {\n return mono_chain.at(id);\n }\n \n // Calculate the mass and composition. The correction of the terminal mass will be considered.\n void update();\n\n // Useful for calculating fragment mass.\n Composition getSubComposition(const size_t start, const size_t end);\n \n void printStructure();\n };\n}" (type_identifier) "namespace" (identifier) "gag" (compound_statement) "{\n class Branch : public Unit\n {\n private:\n size_t branch_id;\n \n std::vector<Monosaccharide> mono_chain;\n std::vector<Composition> re_extension;\n\n // For glycan, there will be only one reducing end.\n \n // The mono_id and the linkage.\n std::vector<Linkage> links;\n\n public:\n Branch(const size_t id)\n : branch_id(id), mono_chain(), links()\n {}\n Branch(){}\n\n void addUnit(Monosaccharide& mono_unit);\n \n void addLinkage(const Linkage& link);\n\n void addExtension(Composition& compo);\n\n std::vector<Linkage> getNeighborLinks(const size_t mono_id);\n\n inline size_t getBranchID() const\n {\n return branch_id;\n }\n\n inline std::vector<Monosaccharide>& getGlycanChainUnits()\n {\n return mono_chain;\n }\n inline const std::vector<Monosaccharide>& getGlycanChainUnits() const\n {\n return mono_chain;\n }\n\n inline size_t getUnitNum()\n {\n return mono_chain.size();\n }\n inline std::vector<Linkage>& getLinkages()\n {\n return links;\n }\n inline size_t getExtensionNum()\n {\n return re_extension.size();\n }\n\n Composition getExtensionComposition();\n\n inline Monosaccharide& getUnitByID(const size_t id)\n {\n return mono_chain.at(id);\n }\n \n // Calculate the mass and composition. The correction of the terminal mass will be considered.\n void update();\n\n // Useful for calculating fragment mass.\n Composition getSubComposition(const size_t start, const size_t end);\n \n void printStructure();\n };\n}" ({) "{" (function_definition) "class Branch : public Unit\n {\n private:\n size_t branch_id;\n \n std::vector<Monosaccharide> mono_chain;\n std::vector<Composition> re_extension;\n\n // For glycan, there will be only one reducing end.\n \n // The mono_id and the linkage.\n std::vector<Linkage> links;\n\n public:\n Branch(const size_t id)\n : branch_id(id), mono_chain(), links()\n {}\n Branch(){}\n\n void addUnit(Monosaccharide& mono_unit);\n \n void addLinkage(const Linkage& link);\n\n void addExtension(Composition& compo);\n\n std::vector<Linkage> getNeighborLinks(const size_t mono_id);\n\n inline size_t getBranchID() const\n {\n return branch_id;\n }\n\n inline std::vector<Monosaccharide>& getGlycanChainUnits()\n {\n return mono_chain;\n }\n inline const std::vector<Monosaccharide>& getGlycanChainUnits() const\n {\n return mono_chain;\n }\n\n inline size_t getUnitNum()\n {\n return mono_chain.size();\n }\n inline std::vector<Linkage>& getLinkages()\n {\n return links;\n }\n inline size_t getExtensionNum()\n {\n return re_extension.size();\n }\n\n Composition getExtensionComposition();\n\n inline Monosaccharide& getUnitByID(const size_t id)\n {\n return mono_chain.at(id);\n }\n \n // Calculate the mass and composition. The correction of the terminal mass will be considered.\n void update();\n\n // Useful for calculating fragment mass.\n Composition getSubComposition(const size_t start, const size_t end);\n \n void printStructure();\n }" (type_identifier) "class" (identifier) "Branch" (ERROR) ": public Unit" (:) ":" (identifier) "public" (identifier) "Unit" (compound_statement) "{\n private:\n size_t branch_id;\n \n std::vector<Monosaccharide> mono_chain;\n std::vector<Composition> re_extension;\n\n // For glycan, there will be only one reducing end.\n \n // The mono_id and the linkage.\n std::vector<Linkage> links;\n\n public:\n Branch(const size_t id)\n : branch_id(id), mono_chain(), links()\n {}\n Branch(){}\n\n void addUnit(Monosaccharide& mono_unit);\n \n void addLinkage(const Linkage& link);\n\n void addExtension(Composition& compo);\n\n std::vector<Linkage> getNeighborLinks(const size_t mono_id);\n\n inline size_t getBranchID() const\n {\n return branch_id;\n }\n\n inline std::vector<Monosaccharide>& getGlycanChainUnits()\n {\n return mono_chain;\n }\n inline const std::vector<Monosaccharide>& getGlycanChainUnits() const\n {\n return mono_chain;\n }\n\n inline size_t getUnitNum()\n {\n return mono_chain.size();\n }\n inline std::vector<Linkage>& getLinkages()\n {\n return links;\n }\n inline size_t getExtensionNum()\n {\n return re_extension.size();\n }\n\n Composition getExtensionComposition();\n\n inline Monosaccharide& getUnitByID(const size_t id)\n {\n return mono_chain.at(id);\n }\n \n // Calculate the mass and composition. The correction of the terminal mass will be considered.\n void update();\n\n // Useful for calculating fragment mass.\n Composition getSubComposition(const size_t start, const size_t end);\n \n void printStructure();\n }" ({) "{" (labeled_statement) "private:\n size_t branch_id;" (statement_identifier) "private" (:) ":" (declaration) "size_t branch_id;" (primitive_type) "size_t" (identifier) "branch_id" (;) ";" (labeled_statement) "std::vector<Monosaccharide> mono_chain;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "vector<Monosaccharide> mono_chain;" (binary_expression) "vector<Monosaccharide> mono_chain" (binary_expression) "vector<Monosaccharide" (identifier) "vector" (<) "<" (identifier) "Monosaccharide" (>) ">" (identifier) "mono_chain" (;) ";" (labeled_statement) "std::vector<Composition> re_extension;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "vector<Composition> re_extension;" (binary_expression) "vector<Composition> re_extension" (binary_expression) "vector<Composition" (identifier) "vector" (<) "<" (identifier) "Composition" (>) ">" (identifier) "re_extension" (;) ";" (comment) "// For glycan, there will be only one reducing end." (comment) "// The mono_id and the linkage." (labeled_statement) "std::vector<Linkage> links;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "vector<Linkage> links;" (binary_expression) "vector<Linkage> links" (binary_expression) "vector<Linkage" (identifier) "vector" (<) "<" (identifier) "Linkage" (>) ">" (identifier) "links" (;) ";" (labeled_statement) "public:\n Branch(const size_t id)\n : branch_id(id), mono_chain(), links()\n {}\n Branch(){}\n\n void addUnit(Monosaccharide& mono_unit);" (statement_identifier) "public" (:) ":" (declaration) "Branch(const size_t id)\n : branch_id(id), mono_chain(), links()\n {}\n Branch(){}\n\n void addUnit(Monosaccharide& mono_unit);" (macro_type_specifier) "Branch(const size_t id)" (identifier) "Branch" (() "(" (type_descriptor) "const size_t" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (ERROR) "id" (identifier) "id" ()) ")" (ERROR) ":" (:) ":" (function_declarator) "branch_id(id)" (identifier) "branch_id" (parameter_list) "(id)" (() "(" (parameter_declaration) "id" (type_identifier) "id" ()) ")" (,) "," (function_declarator) "mono_chain()" (identifier) "mono_chain" (parameter_list) "()" (() "(" ()) ")" (,) "," (ERROR) "links()\n {}\n Branch(){}\n\n void" (function_declarator) "links()" (identifier) "links" (parameter_list) "()" (() "(" ()) ")" ({) "{" (}) "}" (function_declarator) "Branch()" (identifier) "Branch" (parameter_list) "()" (() "(" ()) ")" ({) "{" (}) "}" (primitive_type) "void" (function_declarator) "addUnit(Monosaccharide& mono_unit)" (identifier) "addUnit" (parameter_list) "(Monosaccharide& mono_unit)" (() "(" (parameter_declaration) "Monosaccharide& mono_unit" (type_identifier) "Monosaccharide" (ERROR) "&" (&) "&" (identifier) "mono_unit" ()) ")" (;) ";" (declaration) "void addLinkage(const Linkage& link);" (primitive_type) "void" (function_declarator) "addLinkage(const Linkage& link)" (identifier) "addLinkage" (parameter_list) "(const Linkage& link)" (() "(" (parameter_declaration) "const Linkage& link" (type_qualifier) "const" (const) "const" (type_identifier) "Linkage" (ERROR) "&" (&) "&" (identifier) "link" ()) ")" (;) ";" (declaration) "void addExtension(Composition& compo);" (primitive_type) "void" (function_declarator) "addExtension(Composition& compo)" (identifier) "addExtension" (parameter_list) "(Composition& compo)" (() "(" (parameter_declaration) "Composition& compo" (type_identifier) "Composition" (ERROR) "&" (&) "&" (identifier) "compo" ()) ")" (;) ";" (labeled_statement) "std::vector<Linkage> getNeighborLinks(const size_t mono_id);" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "vector<Linkage> getNeighborLinks(const size_t mono_id);" (binary_expression) "vector<Linkage> getNeighborLinks(const size_t mono_id)" (binary_expression) "vector<Linkage" (identifier) "vector" (<) "<" (identifier) "Linkage" (>) ">" (call_expression) "getNeighborLinks(const size_t mono_id)" (identifier) "getNeighborLinks" (argument_list) "(const size_t mono_id)" (() "(" (ERROR) "const size_t" (identifier) "const" (identifier) "size_t" (identifier) "mono_id" ()) ")" (;) ";" (ERROR) "inline size_t getBranchID() const" (storage_class_specifier) "inline" (inline) "inline" (primitive_type) "size_t" (function_declarator) "getBranchID()" (identifier) "getBranchID" (parameter_list) "()" (() "(" ()) ")" (type_qualifier) "const" (const) "const" (compound_statement) "{\n return branch_id;\n }" ({) "{" (return_statement) "return branch_id;" (return) "return" (identifier) "branch_id" (;) ";" (}) "}" (function_definition) "inline std::vector<Monosaccharide>& getGlycanChainUnits()\n {\n return mono_chain;\n }" (storage_class_specifier) "inline" (inline) "inline" (type_identifier) "std" (ERROR) "::vector<Monosaccharide>&" (:) ":" (:) ":" (identifier) "vector" (<) "<" (identifier) "Monosaccharide" (>) ">" (&) "&" (function_declarator) "getGlycanChainUnits()" (identifier) "getGlycanChainUnits" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n return mono_chain;\n }" ({) "{" (return_statement) "return mono_chain;" (return) "return" (identifier) "mono_chain" (;) ";" (}) "}" (function_definition) "inline const std::vector<Monosaccharide>& getGlycanChainUnits() const\n {\n return mono_chain;\n }\n\n inline size_t getUnitNum()\n {\n return mono_chain.size();\n }\n inline std::vector<Linkage>& getLinkages()\n {\n return links;\n }" (storage_class_specifier) "inline" (inline) "inline" (type_qualifier) "const" (const) "const" (type_identifier) "std" (ERROR) "::vector<Monosaccharide>&" (:) ":" (:) ":" (identifier) "vector" (<) "<" (identifier) "Monosaccharide" (>) ">" (&) "&" (function_declarator) "getGlycanChainUnits()" (identifier) "getGlycanChainUnits" (parameter_list) "()" (() "(" ()) ")" (declaration) "const\n {\n return mono_chain;\n }\n\n inline size_t getUnitNum()\n {\n return mono_chain.size();" (type_qualifier) "const" (const) "const" (ERROR) "{\n return" ({) "{" (return) "return" (type_identifier) "mono_chain" (ERROR) ";\n }\n\n inline size_t getUnitNum()\n {\n return mono_chain." (;) ";" (}) "}" (inline) "inline" (primitive_type) "size_t" (function_declarator) "getUnitNum()" (identifier) "getUnitNum" (parameter_list) "()" (() "(" ()) ")" ({) "{" (return) "return" (identifier) "mono_chain" (.) "." (function_declarator) "size()" (identifier) "size" (parameter_list) "()" (() "(" ()) ")" (;) ";" (ERROR) "}\n inline std::vector<Linkage>& getLinkages()" (}) "}" (storage_class_specifier) "inline" (inline) "inline" (type_identifier) "std" (ERROR) "::vector<Linkage>&" (:) ":" (:) ":" (identifier) "vector" (<) "<" (identifier) "Linkage" (>) ">" (&) "&" (function_declarator) "getLinkages()" (identifier) "getLinkages" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n return links;\n }" ({) "{" (return_statement) "return links;" (return) "return" (identifier) "links" (;) ";" (}) "}" (function_definition) "inline size_t getExtensionNum()\n {\n return re_extension.size();\n }" (storage_class_specifier) "inline" (inline) "inline" (primitive_type) "size_t" (function_declarator) "getExtensionNum()" (identifier) "getExtensionNum" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n return re_extension.size();\n }" ({) "{" (return_statement) "return re_extension.size();" (return) "return" (call_expression) "re_extension.size()" (field_expression) "re_extension.size" (identifier) "re_extension" (.) "." (field_identifier) "size" (argument_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (declaration) "Composition getExtensionComposition();" (type_identifier) "Composition" (function_declarator) "getExtensionComposition()" (identifier) "getExtensionComposition" (parameter_list) "()" (() "(" ()) ")" (;) ";" (function_definition) "inline Monosaccharide& getUnitByID(const size_t id)\n {\n return mono_chain.at(id);\n }" (storage_class_specifier) "inline" (inline) "inline" (type_identifier) "Monosaccharide" (ERROR) "&" (&) "&" (function_declarator) "getUnitByID(const size_t id)" (identifier) "getUnitByID" (parameter_list) "(const size_t id)" (() "(" (parameter_declaration) "const size_t id" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (identifier) "id" ()) ")" (compound_statement) "{\n return mono_chain.at(id);\n }" ({) "{" (return_statement) "return mono_chain.at(id);" (return) "return" (call_expression) "mono_chain.at(id)" (field_expression) "mono_chain.at" (identifier) "mono_chain" (.) "." (field_identifier) "at" (argument_list) "(id)" (() "(" (identifier) "id" ()) ")" (;) ";" (}) "}" (comment) "// Calculate the mass and composition. The correction of the terminal mass will be considered." (declaration) "void update();" (primitive_type) "void" (function_declarator) "update()" (identifier) "update" (parameter_list) "()" (() "(" ()) ")" (;) ";" (comment) "// Useful for calculating fragment mass." (declaration) "Composition getSubComposition(const size_t start, const size_t end);" (type_identifier) "Composition" (function_declarator) "getSubComposition(const size_t start, const size_t end)" (identifier) "getSubComposition" (parameter_list) "(const size_t start, const size_t end)" (() "(" (parameter_declaration) "const size_t start" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (identifier) "start" (,) "," (parameter_declaration) "const size_t end" (type_qualifier) "const" (const) "const" (primitive_type) "size_t" (identifier) "end" ()) ")" (;) ";" (declaration) "void printStructure();" (primitive_type) "void" (function_declarator) "printStructure()" (identifier) "printStructure" (parameter_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (}) "}" (#endif) "#endif" (comment) "/* ----- #ifndef GAG_BRANCH_INC ----- */"
406
20
{"language": "c", "success": true, "metadata": {"lines": 67, "avg_line_length": 24.09, "nodes": 231, "errors": 0, "source_hash": "bb04d00289bc42eee285b8535bfe0c20865ccb6ad08951a6164fc74e26047a43", "categorized_nodes": 155}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef GAG_BRANCH_INC\n#define GAG_BRANCH_INC\n\n#include <algorithm>\n#include <GAGPL/GLYCAN/Linkage.h>\n#include <GAGPL/GLYCAN/Monosaccharide.h>\n\nnamespace gag\n{\n\tclass Branch : public Unit\n\t{\n\t\tprivate:\n\t\t\tsize_t branch_id;\n\t\t\t\n\t\t\tstd::vector<Monosaccharide> mono_chain;\n\t\t\tstd::vector<Composition> re_extension;\n\n\t\t\t// For glycan, there will be only one reducing end.\n\t\t\t\n\t\t\t// The mono_id and the linkage.\n\t\t\tstd::vector<Linkage> links;\n\n\t\tpublic:\n\t\t\tBranch(const size_t id)\n\t\t\t\t: branch_id(id), mono_chain(), links()\n\t\t\t{}\n\t\t\tBranch(){}\n\n\t\t\tvoid addUnit(Monosaccharide& mono_unit);\n\t\t\t\n\t\t\tvoid addLinkage(const Linkage& link);\n\n\t\t\tvoid addExtension(Composition& compo);\n\n\t\t\tstd::vector<Linkage> getNeighborLinks(const size_t mono_id);\n\n\t\t\tinline size_t getBranchID() const\n\t\t\t{\n\t\t\t\treturn branch_id;\n\t\t\t}\n\n\t\t\tinline std::vector<Monosaccharide>& getGlycanChainUnits()\n\t\t\t{\n\t\t\t\treturn mono_chain;\n\t\t\t}\n\t\t\tinline const std::vector<Monosaccharide>& getGlycanChainUnits() const\n\t\t\t{\n\t\t\t\treturn mono_chain;\n\t\t\t}\n\n\t\t\tinline size_t getUnitNum()\n\t\t\t{\n\t\t\t\treturn mono_chain.size();\n\t\t\t}\n\t\t\tinline std::vector<Linkage>& getLinkages()\n\t\t\t{\n\t\t\t\treturn links;\n\t\t\t}\n\t\t\tinline size_t getExtensionNum()\n\t\t\t{\n\t\t\t\treturn re_extension.size();\n\t\t\t}\n\n\t\t\tComposition getExtensionComposition();\n\n\t\t\tinline Monosaccharide& getUnitByID(const size_t id)\n\t\t\t{\n\t\t\t\treturn mono_chain.at(id);\n\t\t\t}\n\t\t\t\n\t\t\t// Calculate the mass and composition. The correction of the terminal mass will be considered.\n\t\t\tvoid update();\n\n\t\t\t// Useful for calculating fragment mass.\n\t\t\tComposition getSubComposition(const size_t start, const size_t end);\n\t\t\n\t\t\tvoid printStructure();\n\t};\n}\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 15, 230], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 80, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "identifier", "text": "GAG_BRANCH_INC", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 23}}, {"id": 3, "type": "preproc_def", "text": "#define GAG_BRANCH_INC\n", "parent": 0, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 5, "type": "identifier", "text": "GAG_BRANCH_INC", "parent": 3, "children": [], "start_point": {"row": 1, "column": 9}, "end_point": {"row": 1, "column": 23}}, {"id": 6, "type": "preproc_include", "text": "#include <algorithm>\n", "parent": 0, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<algorithm>", "parent": 6, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 20}}, {"id": 9, "type": "preproc_include", "text": "#include <GAGPL/GLYCAN/Linkage.h>\n", "parent": 0, "children": [10, 11], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<GAGPL/GLYCAN/Linkage.h>", "parent": 9, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 33}}, {"id": 12, "type": "preproc_include", "text": "#include <GAGPL/GLYCAN/Monosaccharide.h>\n", "parent": 0, "children": [13, 14], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 14, "type": "system_lib_string", "text": "<GAGPL/GLYCAN/Monosaccharide.h>", "parent": 12, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 40}}, {"id": 15, "type": "function_definition", "text": "namespace gag\n{\n\tclass Branch : public Unit\n\t{\n\t\tprivate:\n\t\t\tsize_t branch_id;\n\t\t\t\n\t\t\tstd::vector<Monosaccharide> mono_chain;\n\t\t\tstd::vector<Composition> re_extension;\n\n\t\t\t// For glycan, there will be only one reducing end.\n\t\t\t\n\t\t\t// The mono_id and the linkage.\n\t\t\tstd::vector<Linkage> links;\n\n\t\tpublic:\n\t\t\tBranch(const size_t id)\n\t\t\t\t: branch_id(id), mono_chain(), links()\n\t\t\t{}\n\t\t\tBranch(){}\n\n\t\t\tvoid addUnit(Monosaccharide& mono_unit);\n\t\t\t\n\t\t\tvoid addLinkage(const Linkage& link);\n\n\t\t\tvoid addExtension(Composition& compo);\n\n\t\t\tstd::vector<Linkage> getNeighborLinks(const size_t mono_id);\n\n\t\t\tinline size_t getBranchID() const\n\t\t\t{\n\t\t\t\treturn branch_id;\n\t\t\t}\n\n\t\t\tinline std::vector<Monosaccharide>& getGlycanChainUnits()\n\t\t\t{\n\t\t\t\treturn mono_chain;\n\t\t\t}\n\t\t\tinline const std::vector<Monosaccharide>& getGlycanChainUnits() const\n\t\t\t{\n\t\t\t\treturn mono_chain;\n\t\t\t}\n\n\t\t\tinline size_t getUnitNum()\n\t\t\t{\n\t\t\t\treturn mono_chain.size();\n\t\t\t}\n\t\t\tinline std::vector<Linkage>& getLinkages()\n\t\t\t{\n\t\t\t\treturn links;\n\t\t\t}\n\t\t\tinline size_t getExtensionNum()\n\t\t\t{\n\t\t\t\treturn re_extension.size();\n\t\t\t}\n\n\t\t\tComposition getExtensionComposition();\n\n\t\t\tinline Monosaccharide& getUnitByID(const size_t id)\n\t\t\t{\n\t\t\t\treturn mono_chain.at(id);\n\t\t\t}\n\t\t\t\n\t\t\t// Calculate the mass and composition. The correction of the terminal mass will be considered.\n\t\t\tvoid update();\n\n\t\t\t// Useful for calculating fragment mass.\n\t\t\tComposition getSubComposition(const size_t start, const size_t end);\n\t\t\n\t\t\tvoid printStructure();\n\t};\n}", "parent": 0, "children": [16, 17], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 78, "column": 1}}, {"id": 16, "type": "type_identifier", "text": "namespace", "parent": 15, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 9}}, {"id": 17, "type": "identifier", "text": "gag", "parent": 15, "children": [], "start_point": {"row": 7, "column": 10}, "end_point": {"row": 7, "column": 13}}, {"id": 18, "type": "function_definition", "text": "class Branch : public Unit\n\t{\n\t\tprivate:\n\t\t\tsize_t branch_id;\n\t\t\t\n\t\t\tstd::vector<Monosaccharide> mono_chain;\n\t\t\tstd::vector<Composition> re_extension;\n\n\t\t\t// For glycan, there will be only one reducing end.\n\t\t\t\n\t\t\t// The mono_id and the linkage.\n\t\t\tstd::vector<Linkage> links;\n\n\t\tpublic:\n\t\t\tBranch(const size_t id)\n\t\t\t\t: branch_id(id), mono_chain(), links()\n\t\t\t{}\n\t\t\tBranch(){}\n\n\t\t\tvoid addUnit(Monosaccharide& mono_unit);\n\t\t\t\n\t\t\tvoid addLinkage(const Linkage& link);\n\n\t\t\tvoid addExtension(Composition& compo);\n\n\t\t\tstd::vector<Linkage> getNeighborLinks(const size_t mono_id);\n\n\t\t\tinline size_t getBranchID() const\n\t\t\t{\n\t\t\t\treturn branch_id;\n\t\t\t}\n\n\t\t\tinline std::vector<Monosaccharide>& getGlycanChainUnits()\n\t\t\t{\n\t\t\t\treturn mono_chain;\n\t\t\t}\n\t\t\tinline const std::vector<Monosaccharide>& getGlycanChainUnits() const\n\t\t\t{\n\t\t\t\treturn mono_chain;\n\t\t\t}\n\n\t\t\tinline size_t getUnitNum()\n\t\t\t{\n\t\t\t\treturn mono_chain.size();\n\t\t\t}\n\t\t\tinline std::vector<Linkage>& getLinkages()\n\t\t\t{\n\t\t\t\treturn links;\n\t\t\t}\n\t\t\tinline size_t getExtensionNum()\n\t\t\t{\n\t\t\t\treturn re_extension.size();\n\t\t\t}\n\n\t\t\tComposition getExtensionComposition();\n\n\t\t\tinline Monosaccharide& getUnitByID(const size_t id)\n\t\t\t{\n\t\t\t\treturn mono_chain.at(id);\n\t\t\t}\n\t\t\t\n\t\t\t// Calculate the mass and composition. The correction of the terminal mass will be considered.\n\t\t\tvoid update();\n\n\t\t\t// Useful for calculating fragment mass.\n\t\t\tComposition getSubComposition(const size_t start, const size_t end);\n\t\t\n\t\t\tvoid printStructure();\n\t}", "parent": 15, "children": [19, 20], "start_point": {"row": 9, "column": 1}, "end_point": {"row": 77, "column": 2}}, {"id": 19, "type": "identifier", "text": "Branch", "parent": 18, "children": [], "start_point": {"row": 9, "column": 7}, "end_point": {"row": 9, "column": 13}}, {"id": 20, "type": "ERROR", "text": ": public Unit", "parent": 18, "children": [21], "start_point": {"row": 9, "column": 14}, "end_point": {"row": 9, "column": 27}}, {"id": 21, "type": "identifier", "text": "Unit", "parent": 20, "children": [], "start_point": {"row": 9, "column": 23}, "end_point": {"row": 9, "column": 27}}, {"id": 22, "type": "labeled_statement", "text": "private:\n\t\t\tsize_t branch_id;", "parent": 18, "children": [23], "start_point": {"row": 11, "column": 2}, "end_point": {"row": 12, "column": 20}}, {"id": 23, "type": "declaration", "text": "size_t branch_id;", "parent": 22, "children": [24, 25], "start_point": {"row": 12, "column": 3}, "end_point": {"row": 12, "column": 20}}, {"id": 24, "type": "primitive_type", "text": "size_t", "parent": 23, "children": [], "start_point": {"row": 12, "column": 3}, "end_point": {"row": 12, "column": 9}}, {"id": 25, "type": "identifier", "text": "branch_id", "parent": 23, "children": [], "start_point": {"row": 12, "column": 10}, "end_point": {"row": 12, "column": 19}}, {"id": 26, "type": "labeled_statement", "text": "std::vector<Monosaccharide> mono_chain;", "parent": 18, "children": [27], "start_point": {"row": 14, "column": 3}, "end_point": {"row": 14, "column": 42}}, {"id": 27, "type": "statement_identifier", "text": "std", "parent": 26, "children": [], "start_point": {"row": 14, "column": 3}, "end_point": {"row": 14, "column": 6}}, {"id": 28, "type": "binary_expression", "text": "vector<Monosaccharide> mono_chain", "parent": 26, "children": [29, 33, 34], "start_point": {"row": 14, "column": 8}, "end_point": {"row": 14, "column": 41}}, {"id": 29, "type": "binary_expression", "text": "vector<Monosaccharide", "parent": 28, "children": [30, 31, 32], "start_point": {"row": 14, "column": 8}, "end_point": {"row": 14, "column": 29}}, {"id": 30, "type": "identifier", "text": "vector", "parent": 29, "children": [], "start_point": {"row": 14, "column": 8}, "end_point": {"row": 14, "column": 14}}, {"id": 31, "type": "<", "text": "<", "parent": 29, "children": [], "start_point": {"row": 14, "column": 14}, "end_point": {"row": 14, "column": 15}}, {"id": 32, "type": "identifier", "text": "Monosaccharide", "parent": 29, "children": [], "start_point": {"row": 14, "column": 15}, "end_point": {"row": 14, "column": 29}}, {"id": 33, "type": ">", "text": ">", "parent": 28, "children": [], "start_point": {"row": 14, "column": 29}, "end_point": {"row": 14, "column": 30}}, {"id": 34, "type": "identifier", "text": "mono_chain", "parent": 28, "children": [], "start_point": {"row": 14, "column": 31}, "end_point": {"row": 14, "column": 41}}, {"id": 35, "type": "labeled_statement", "text": "std::vector<Composition> re_extension;", "parent": 18, "children": [36], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 41}}, {"id": 36, "type": "statement_identifier", "text": "std", "parent": 35, "children": [], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 6}}, {"id": 37, "type": "binary_expression", "text": "vector<Composition> re_extension", "parent": 35, "children": [38, 42, 43], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 40}}, {"id": 38, "type": "binary_expression", "text": "vector<Composition", "parent": 37, "children": [39, 40, 41], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 26}}, {"id": 39, "type": "identifier", "text": "vector", "parent": 38, "children": [], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 14}}, {"id": 40, "type": "<", "text": "<", "parent": 38, "children": [], "start_point": {"row": 15, "column": 14}, "end_point": {"row": 15, "column": 15}}, {"id": 41, "type": "identifier", "text": "Composition", "parent": 38, "children": [], "start_point": {"row": 15, "column": 15}, "end_point": {"row": 15, "column": 26}}, {"id": 42, "type": ">", "text": ">", "parent": 37, "children": [], "start_point": {"row": 15, "column": 26}, "end_point": {"row": 15, "column": 27}}, {"id": 43, "type": "identifier", "text": "re_extension", "parent": 37, "children": [], "start_point": {"row": 15, "column": 28}, "end_point": {"row": 15, "column": 40}}, {"id": 44, "type": "labeled_statement", "text": "std::vector<Linkage> links;", "parent": 18, "children": [45], "start_point": {"row": 20, "column": 3}, "end_point": {"row": 20, "column": 30}}, {"id": 45, "type": "statement_identifier", "text": "std", "parent": 44, "children": [], "start_point": {"row": 20, "column": 3}, "end_point": {"row": 20, "column": 6}}, {"id": 46, "type": "binary_expression", "text": "vector<Linkage> links", "parent": 44, "children": [47, 51, 52], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 29}}, {"id": 47, "type": "binary_expression", "text": "vector<Linkage", "parent": 46, "children": [48, 49, 50], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 22}}, {"id": 48, "type": "identifier", "text": "vector", "parent": 47, "children": [], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 14}}, {"id": 49, "type": "<", "text": "<", "parent": 47, "children": [], "start_point": {"row": 20, "column": 14}, "end_point": {"row": 20, "column": 15}}, {"id": 50, "type": "identifier", "text": "Linkage", "parent": 47, "children": [], "start_point": {"row": 20, "column": 15}, "end_point": {"row": 20, "column": 22}}, {"id": 51, "type": ">", "text": ">", "parent": 46, "children": [], "start_point": {"row": 20, "column": 22}, "end_point": {"row": 20, "column": 23}}, {"id": 52, "type": "identifier", "text": "links", "parent": 46, "children": [], "start_point": {"row": 20, "column": 24}, "end_point": {"row": 20, "column": 29}}, {"id": 53, "type": "labeled_statement", "text": "public:\n\t\t\tBranch(const size_t id)\n\t\t\t\t: branch_id(id), mono_chain(), links()\n\t\t\t{}\n\t\t\tBranch(){}\n\n\t\t\tvoid addUnit(Monosaccharide& mono_unit);", "parent": 18, "children": [54], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 28, "column": 43}}, {"id": 54, "type": "declaration", "text": "Branch(const size_t id)\n\t\t\t\t: branch_id(id), mono_chain(), links()\n\t\t\t{}\n\t\t\tBranch(){}\n\n\t\t\tvoid addUnit(Monosaccharide& mono_unit);", "parent": 53, "children": [55, 61, 66, 69, 77], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 28, "column": 43}}, {"id": 55, "type": "macro_type_specifier", "text": "Branch(const size_t id)", "parent": 54, "children": [56, 57, 59], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 23, "column": 26}}, {"id": 56, "type": "identifier", "text": "Branch", "parent": 55, "children": [], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 23, "column": 9}}, {"id": 57, "type": "type_descriptor", "text": "const size_t", "parent": 55, "children": [58], "start_point": {"row": 23, "column": 10}, "end_point": {"row": 23, "column": 22}}, {"id": 58, "type": "primitive_type", "text": "size_t", "parent": 57, "children": [], "start_point": {"row": 23, "column": 16}, "end_point": {"row": 23, "column": 22}}, {"id": 59, "type": "ERROR", "text": "id", "parent": 55, "children": [60], "start_point": {"row": 23, "column": 23}, "end_point": {"row": 23, "column": 25}}, {"id": 60, "type": "identifier", "text": "id", "parent": 59, "children": [], "start_point": {"row": 23, "column": 23}, "end_point": {"row": 23, "column": 25}}, {"id": 61, "type": "function_declarator", "text": "branch_id(id)", "parent": 54, "children": [62, 63], "start_point": {"row": 24, "column": 6}, "end_point": {"row": 24, "column": 19}}, {"id": 62, "type": "identifier", "text": "branch_id", "parent": 61, "children": [], "start_point": {"row": 24, "column": 6}, "end_point": {"row": 24, "column": 15}}, {"id": 63, "type": "parameter_list", "text": "(id)", "parent": 61, "children": [64], "start_point": {"row": 24, "column": 15}, "end_point": {"row": 24, "column": 19}}, {"id": 64, "type": "parameter_declaration", "text": "id", "parent": 63, "children": [65], "start_point": {"row": 24, "column": 16}, "end_point": {"row": 24, "column": 18}}, {"id": 65, "type": "type_identifier", "text": "id", "parent": 64, "children": [], "start_point": {"row": 24, "column": 16}, "end_point": {"row": 24, "column": 18}}, {"id": 66, "type": "function_declarator", "text": "mono_chain()", "parent": 54, "children": [67, 68], "start_point": {"row": 24, "column": 21}, "end_point": {"row": 24, "column": 33}}, {"id": 67, "type": "identifier", "text": "mono_chain", "parent": 66, "children": [], "start_point": {"row": 24, "column": 21}, "end_point": {"row": 24, "column": 31}}, {"id": 68, "type": "parameter_list", "text": "()", "parent": 66, "children": [], "start_point": {"row": 24, "column": 31}, "end_point": {"row": 24, "column": 33}}, {"id": 69, "type": "ERROR", "text": "links()\n\t\t\t{}\n\t\t\tBranch(){}\n\n\t\t\tvoid", "parent": 54, "children": [70, 73, 76], "start_point": {"row": 24, "column": 35}, "end_point": {"row": 28, "column": 7}}, {"id": 70, "type": "function_declarator", "text": "links()", "parent": 69, "children": [71, 72], "start_point": {"row": 24, "column": 35}, "end_point": {"row": 24, "column": 42}}, {"id": 71, "type": "identifier", "text": "links", "parent": 70, "children": [], "start_point": {"row": 24, "column": 35}, "end_point": {"row": 24, "column": 40}}, {"id": 72, "type": "parameter_list", "text": "()", "parent": 70, "children": [], "start_point": {"row": 24, "column": 40}, "end_point": {"row": 24, "column": 42}}, {"id": 73, "type": "function_declarator", "text": "Branch()", "parent": 69, "children": [74, 75], "start_point": {"row": 26, "column": 3}, "end_point": {"row": 26, "column": 11}}, {"id": 74, "type": "identifier", "text": "Branch", "parent": 73, "children": [], "start_point": {"row": 26, "column": 3}, "end_point": {"row": 26, "column": 9}}, {"id": 75, "type": "parameter_list", "text": "()", "parent": 73, "children": [], "start_point": {"row": 26, "column": 9}, "end_point": {"row": 26, "column": 11}}, {"id": 76, "type": "primitive_type", "text": "void", "parent": 69, "children": [], "start_point": {"row": 28, "column": 3}, "end_point": {"row": 28, "column": 7}}, {"id": 77, "type": "function_declarator", "text": "addUnit(Monosaccharide& mono_unit)", "parent": 54, "children": [78, 79], "start_point": {"row": 28, "column": 8}, "end_point": {"row": 28, "column": 42}}, {"id": 78, "type": "identifier", "text": "addUnit", "parent": 77, "children": [], "start_point": {"row": 28, "column": 8}, "end_point": {"row": 28, "column": 15}}, {"id": 79, "type": "parameter_list", "text": "(Monosaccharide& mono_unit)", "parent": 77, "children": [80], "start_point": {"row": 28, "column": 15}, "end_point": {"row": 28, "column": 42}}, {"id": 80, "type": "parameter_declaration", "text": "Monosaccharide& mono_unit", "parent": 79, "children": [81, 82], "start_point": {"row": 28, "column": 16}, "end_point": {"row": 28, "column": 41}}, {"id": 81, "type": "type_identifier", "text": "Monosaccharide", "parent": 80, "children": [], "start_point": {"row": 28, "column": 16}, "end_point": {"row": 28, "column": 30}}, {"id": 82, "type": "identifier", "text": "mono_unit", "parent": 80, "children": [], "start_point": {"row": 28, "column": 32}, "end_point": {"row": 28, "column": 41}}, {"id": 83, "type": "declaration", "text": "void addLinkage(const Linkage& link);", "parent": 18, "children": [84, 85], "start_point": {"row": 30, "column": 3}, "end_point": {"row": 30, "column": 40}}, {"id": 84, "type": "primitive_type", "text": "void", "parent": 83, "children": [], "start_point": {"row": 30, "column": 3}, "end_point": {"row": 30, "column": 7}}, {"id": 85, "type": "function_declarator", "text": "addLinkage(const Linkage& link)", "parent": 83, "children": [86, 87], "start_point": {"row": 30, "column": 8}, "end_point": {"row": 30, "column": 39}}, {"id": 86, "type": "identifier", "text": "addLinkage", "parent": 85, "children": [], "start_point": {"row": 30, "column": 8}, "end_point": {"row": 30, "column": 18}}, {"id": 87, "type": "parameter_list", "text": "(const Linkage& link)", "parent": 85, "children": [88], "start_point": {"row": 30, "column": 18}, "end_point": {"row": 30, "column": 39}}, {"id": 88, "type": "parameter_declaration", "text": "const Linkage& link", "parent": 87, "children": [89, 90], "start_point": {"row": 30, "column": 19}, "end_point": {"row": 30, "column": 38}}, {"id": 89, "type": "type_identifier", "text": "Linkage", "parent": 88, "children": [], "start_point": {"row": 30, "column": 25}, "end_point": {"row": 30, "column": 32}}, {"id": 90, "type": "identifier", "text": "link", "parent": 88, "children": [], "start_point": {"row": 30, "column": 34}, "end_point": {"row": 30, "column": 38}}, {"id": 91, "type": "declaration", "text": "void addExtension(Composition& compo);", "parent": 18, "children": [92, 93], "start_point": {"row": 32, "column": 3}, "end_point": {"row": 32, "column": 41}}, {"id": 92, "type": "primitive_type", "text": "void", "parent": 91, "children": [], "start_point": {"row": 32, "column": 3}, "end_point": {"row": 32, "column": 7}}, {"id": 93, "type": "function_declarator", "text": "addExtension(Composition& compo)", "parent": 91, "children": [94, 95], "start_point": {"row": 32, "column": 8}, "end_point": {"row": 32, "column": 40}}, {"id": 94, "type": "identifier", "text": "addExtension", "parent": 93, "children": [], "start_point": {"row": 32, "column": 8}, "end_point": {"row": 32, "column": 20}}, {"id": 95, "type": "parameter_list", "text": "(Composition& compo)", "parent": 93, "children": [96], "start_point": {"row": 32, "column": 20}, "end_point": {"row": 32, "column": 40}}, {"id": 96, "type": "parameter_declaration", "text": "Composition& compo", "parent": 95, "children": [97, 98], "start_point": {"row": 32, "column": 21}, "end_point": {"row": 32, "column": 39}}, {"id": 97, "type": "type_identifier", "text": "Composition", "parent": 96, "children": [], "start_point": {"row": 32, "column": 21}, "end_point": {"row": 32, "column": 32}}, {"id": 98, "type": "identifier", "text": "compo", "parent": 96, "children": [], "start_point": {"row": 32, "column": 34}, "end_point": {"row": 32, "column": 39}}, {"id": 99, "type": "labeled_statement", "text": "std::vector<Linkage> getNeighborLinks(const size_t mono_id);", "parent": 18, "children": [100], "start_point": {"row": 34, "column": 3}, "end_point": {"row": 34, "column": 63}}, {"id": 100, "type": "statement_identifier", "text": "std", "parent": 99, "children": [], "start_point": {"row": 34, "column": 3}, "end_point": {"row": 34, "column": 6}}, {"id": 101, "type": "binary_expression", "text": "vector<Linkage> getNeighborLinks(const size_t mono_id)", "parent": 99, "children": [102, 106, 107], "start_point": {"row": 34, "column": 8}, "end_point": {"row": 34, "column": 62}}, {"id": 102, "type": "binary_expression", "text": "vector<Linkage", "parent": 101, "children": [103, 104, 105], "start_point": {"row": 34, "column": 8}, "end_point": {"row": 34, "column": 22}}, {"id": 103, "type": "identifier", "text": "vector", "parent": 102, "children": [], "start_point": {"row": 34, "column": 8}, "end_point": {"row": 34, "column": 14}}, {"id": 104, "type": "<", "text": "<", "parent": 102, "children": [], "start_point": {"row": 34, "column": 14}, "end_point": {"row": 34, "column": 15}}, {"id": 105, "type": "identifier", "text": "Linkage", "parent": 102, "children": [], "start_point": {"row": 34, "column": 15}, "end_point": {"row": 34, "column": 22}}, {"id": 106, "type": ">", "text": ">", "parent": 101, "children": [], "start_point": {"row": 34, "column": 22}, "end_point": {"row": 34, "column": 23}}, {"id": 107, "type": "call_expression", "text": "getNeighborLinks(const size_t mono_id)", "parent": 101, "children": [108, 109], "start_point": {"row": 34, "column": 24}, "end_point": {"row": 34, "column": 62}}, {"id": 108, "type": "identifier", "text": "getNeighborLinks", "parent": 107, "children": [], "start_point": {"row": 34, "column": 24}, "end_point": {"row": 34, "column": 40}}, {"id": 109, "type": "argument_list", "text": "(const size_t mono_id)", "parent": 107, "children": [110, 112], "start_point": {"row": 34, "column": 40}, "end_point": {"row": 34, "column": 62}}, {"id": 110, "type": "ERROR", "text": "const size_t", "parent": 109, "children": [111], "start_point": {"row": 34, "column": 41}, "end_point": {"row": 34, "column": 53}}, {"id": 111, "type": "identifier", "text": "size_t", "parent": 110, "children": [], "start_point": {"row": 34, "column": 47}, "end_point": {"row": 34, "column": 53}}, {"id": 112, "type": "identifier", "text": "mono_id", "parent": 109, "children": [], "start_point": {"row": 34, "column": 54}, "end_point": {"row": 34, "column": 61}}, {"id": 113, "type": "ERROR", "text": "inline size_t getBranchID() const", "parent": 18, "children": [114, 116, 117], "start_point": {"row": 36, "column": 3}, "end_point": {"row": 36, "column": 36}}, {"id": 114, "type": "storage_class_specifier", "text": "inline", "parent": 113, "children": [115], "start_point": {"row": 36, "column": 3}, "end_point": {"row": 36, "column": 9}}, {"id": 115, "type": "inline", "text": "inline", "parent": 114, "children": [], "start_point": {"row": 36, "column": 3}, "end_point": {"row": 36, "column": 9}}, {"id": 116, "type": "primitive_type", "text": "size_t", "parent": 113, "children": [], "start_point": {"row": 36, "column": 10}, "end_point": {"row": 36, "column": 16}}, {"id": 117, "type": "function_declarator", "text": "getBranchID()", "parent": 113, "children": [118, 119], "start_point": {"row": 36, "column": 17}, "end_point": {"row": 36, "column": 30}}, {"id": 118, "type": "identifier", "text": "getBranchID", "parent": 117, "children": [], "start_point": {"row": 36, "column": 17}, "end_point": {"row": 36, "column": 28}}, {"id": 119, "type": "parameter_list", "text": "()", "parent": 117, "children": [], "start_point": {"row": 36, "column": 28}, "end_point": {"row": 36, "column": 30}}, {"id": 120, "type": "return_statement", "text": "return branch_id;", "parent": 18, "children": [121], "start_point": {"row": 38, "column": 4}, "end_point": {"row": 38, "column": 21}}, {"id": 121, "type": "identifier", "text": "branch_id", "parent": 120, "children": [], "start_point": {"row": 38, "column": 11}, "end_point": {"row": 38, "column": 20}}, {"id": 122, "type": "function_definition", "text": "inline std::vector<Monosaccharide>& getGlycanChainUnits()\n\t\t\t{\n\t\t\t\treturn mono_chain;\n\t\t\t}", "parent": 18, "children": [123, 125, 126, 131], "start_point": {"row": 41, "column": 3}, "end_point": {"row": 44, "column": 4}}, {"id": 123, "type": "storage_class_specifier", "text": "inline", "parent": 122, "children": [124], "start_point": {"row": 41, "column": 3}, "end_point": {"row": 41, "column": 9}}, {"id": 124, "type": "inline", "text": "inline", "parent": 123, "children": [], "start_point": {"row": 41, "column": 3}, "end_point": {"row": 41, "column": 9}}, {"id": 125, "type": "type_identifier", "text": "std", "parent": 122, "children": [], "start_point": {"row": 41, "column": 10}, "end_point": {"row": 41, "column": 13}}, {"id": 126, "type": "ERROR", "text": "::vector<Monosaccharide>&", "parent": 122, "children": [127, 128, 129, 130], "start_point": {"row": 41, "column": 13}, "end_point": {"row": 41, "column": 38}}, {"id": 127, "type": "identifier", "text": "vector", "parent": 126, "children": [], "start_point": {"row": 41, "column": 15}, "end_point": {"row": 41, "column": 21}}, {"id": 128, "type": "<", "text": "<", "parent": 126, "children": [], "start_point": {"row": 41, "column": 21}, "end_point": {"row": 41, "column": 22}}, {"id": 129, "type": "identifier", "text": "Monosaccharide", "parent": 126, "children": [], "start_point": {"row": 41, "column": 22}, "end_point": {"row": 41, "column": 36}}, {"id": 130, "type": ">", "text": ">", "parent": 126, "children": [], "start_point": {"row": 41, "column": 36}, "end_point": {"row": 41, "column": 37}}, {"id": 131, "type": "function_declarator", "text": "getGlycanChainUnits()", "parent": 122, "children": [132, 133], "start_point": {"row": 41, "column": 39}, "end_point": {"row": 41, "column": 60}}, {"id": 132, "type": "identifier", "text": "getGlycanChainUnits", "parent": 131, "children": [], "start_point": {"row": 41, "column": 39}, "end_point": {"row": 41, "column": 58}}, {"id": 133, "type": "parameter_list", "text": "()", "parent": 131, "children": [], "start_point": {"row": 41, "column": 58}, "end_point": {"row": 41, "column": 60}}, {"id": 134, "type": "return_statement", "text": "return mono_chain;", "parent": 122, "children": [135], "start_point": {"row": 43, "column": 4}, "end_point": {"row": 43, "column": 22}}, {"id": 135, "type": "identifier", "text": "mono_chain", "parent": 134, "children": [], "start_point": {"row": 43, "column": 11}, "end_point": {"row": 43, "column": 21}}, {"id": 136, "type": "function_definition", "text": "inline const std::vector<Monosaccharide>& getGlycanChainUnits() const\n\t\t\t{\n\t\t\t\treturn mono_chain;\n\t\t\t}\n\n\t\t\tinline size_t getUnitNum()\n\t\t\t{\n\t\t\t\treturn mono_chain.size();\n\t\t\t}\n\t\t\tinline std::vector<Linkage>& getLinkages()\n\t\t\t{\n\t\t\t\treturn links;\n\t\t\t}", "parent": 18, "children": [137, 139, 140, 145, 148, 161], "start_point": {"row": 45, "column": 3}, "end_point": {"row": 57, "column": 4}}, {"id": 137, "type": "storage_class_specifier", "text": "inline", "parent": 136, "children": [138], "start_point": {"row": 45, "column": 3}, "end_point": {"row": 45, "column": 9}}, {"id": 138, "type": "inline", "text": "inline", "parent": 137, "children": [], "start_point": {"row": 45, "column": 3}, "end_point": {"row": 45, "column": 9}}, {"id": 139, "type": "type_identifier", "text": "std", "parent": 136, "children": [], "start_point": {"row": 45, "column": 16}, "end_point": {"row": 45, "column": 19}}, {"id": 140, "type": "ERROR", "text": "::vector<Monosaccharide>&", "parent": 136, "children": [141, 142, 143, 144], "start_point": {"row": 45, "column": 19}, "end_point": {"row": 45, "column": 44}}, {"id": 141, "type": "identifier", "text": "vector", "parent": 140, "children": [], "start_point": {"row": 45, "column": 21}, "end_point": {"row": 45, "column": 27}}, {"id": 142, "type": "<", "text": "<", "parent": 140, "children": [], "start_point": {"row": 45, "column": 27}, "end_point": {"row": 45, "column": 28}}, {"id": 143, "type": "identifier", "text": "Monosaccharide", "parent": 140, "children": [], "start_point": {"row": 45, "column": 28}, "end_point": {"row": 45, "column": 42}}, {"id": 144, "type": ">", "text": ">", "parent": 140, "children": [], "start_point": {"row": 45, "column": 42}, "end_point": {"row": 45, "column": 43}}, {"id": 145, "type": "function_declarator", "text": "getGlycanChainUnits()", "parent": 136, "children": [146, 147], "start_point": {"row": 45, "column": 45}, "end_point": {"row": 45, "column": 66}}, {"id": 146, "type": "identifier", "text": "getGlycanChainUnits", "parent": 145, "children": [], "start_point": {"row": 45, "column": 45}, "end_point": {"row": 45, "column": 64}}, {"id": 147, "type": "parameter_list", "text": "()", "parent": 145, "children": [], "start_point": {"row": 45, "column": 64}, "end_point": {"row": 45, "column": 66}}, {"id": 148, "type": "declaration", "text": "const\n\t\t\t{\n\t\t\t\treturn mono_chain;\n\t\t\t}\n\n\t\t\tinline size_t getUnitNum()\n\t\t\t{\n\t\t\t\treturn mono_chain.size();", "parent": 136, "children": [149, 150, 151, 158], "start_point": {"row": 45, "column": 67}, "end_point": {"row": 52, "column": 29}}, {"id": 149, "type": "ERROR", "text": "{\n\t\t\t\treturn", "parent": 148, "children": [], "start_point": {"row": 46, "column": 3}, "end_point": {"row": 47, "column": 10}}, {"id": 150, "type": "type_identifier", "text": "mono_chain", "parent": 148, "children": [], "start_point": {"row": 47, "column": 11}, "end_point": {"row": 47, "column": 21}}, {"id": 151, "type": "ERROR", "text": ";\n\t\t\t}\n\n\t\t\tinline size_t getUnitNum()\n\t\t\t{\n\t\t\t\treturn mono_chain.", "parent": 148, "children": [152, 153, 154, 157], "start_point": {"row": 47, "column": 21}, "end_point": {"row": 52, "column": 22}}, {"id": 152, "type": "inline", "text": "inline", "parent": 151, "children": [], "start_point": {"row": 50, "column": 3}, "end_point": {"row": 50, "column": 9}}, {"id": 153, "type": "primitive_type", "text": "size_t", "parent": 151, "children": [], "start_point": {"row": 50, "column": 10}, "end_point": {"row": 50, "column": 16}}, {"id": 154, "type": "function_declarator", "text": "getUnitNum()", "parent": 151, "children": [155, 156], "start_point": {"row": 50, "column": 17}, "end_point": {"row": 50, "column": 29}}, {"id": 155, "type": "identifier", "text": "getUnitNum", "parent": 154, "children": [], "start_point": {"row": 50, "column": 17}, "end_point": {"row": 50, "column": 27}}, {"id": 156, "type": "parameter_list", "text": "()", "parent": 154, "children": [], "start_point": {"row": 50, "column": 27}, "end_point": {"row": 50, "column": 29}}, {"id": 157, "type": "identifier", "text": "mono_chain", "parent": 151, "children": [], "start_point": {"row": 52, "column": 11}, "end_point": {"row": 52, "column": 21}}, {"id": 158, "type": "function_declarator", "text": "size()", "parent": 148, "children": [159, 160], "start_point": {"row": 52, "column": 22}, "end_point": {"row": 52, "column": 28}}, {"id": 159, "type": "identifier", "text": "size", "parent": 158, "children": [], "start_point": {"row": 52, "column": 22}, "end_point": {"row": 52, "column": 26}}, {"id": 160, "type": "parameter_list", "text": "()", "parent": 158, "children": [], "start_point": {"row": 52, "column": 26}, "end_point": {"row": 52, "column": 28}}, {"id": 161, "type": "ERROR", "text": "}\n\t\t\tinline std::vector<Linkage>& getLinkages()", "parent": 136, "children": [162, 164, 165, 170], "start_point": {"row": 53, "column": 3}, "end_point": {"row": 54, "column": 45}}, {"id": 162, "type": "storage_class_specifier", "text": "inline", "parent": 161, "children": [163], "start_point": {"row": 54, "column": 3}, "end_point": {"row": 54, "column": 9}}, {"id": 163, "type": "inline", "text": "inline", "parent": 162, "children": [], "start_point": {"row": 54, "column": 3}, "end_point": {"row": 54, "column": 9}}, {"id": 164, "type": "type_identifier", "text": "std", "parent": 161, "children": [], "start_point": {"row": 54, "column": 10}, "end_point": {"row": 54, "column": 13}}, {"id": 165, "type": "ERROR", "text": "::vector<Linkage>&", "parent": 161, "children": [166, 167, 168, 169], "start_point": {"row": 54, "column": 13}, "end_point": {"row": 54, "column": 31}}, {"id": 166, "type": "identifier", "text": "vector", "parent": 165, "children": [], "start_point": {"row": 54, "column": 15}, "end_point": {"row": 54, "column": 21}}, {"id": 167, "type": "<", "text": "<", "parent": 165, "children": [], "start_point": {"row": 54, "column": 21}, "end_point": {"row": 54, "column": 22}}, {"id": 168, "type": "identifier", "text": "Linkage", "parent": 165, "children": [], "start_point": {"row": 54, "column": 22}, "end_point": {"row": 54, "column": 29}}, {"id": 169, "type": ">", "text": ">", "parent": 165, "children": [], "start_point": {"row": 54, "column": 29}, "end_point": {"row": 54, "column": 30}}, {"id": 170, "type": "function_declarator", "text": "getLinkages()", "parent": 161, "children": [171, 172], "start_point": {"row": 54, "column": 32}, "end_point": {"row": 54, "column": 45}}, {"id": 171, "type": "identifier", "text": "getLinkages", "parent": 170, "children": [], "start_point": {"row": 54, "column": 32}, "end_point": {"row": 54, "column": 43}}, {"id": 172, "type": "parameter_list", "text": "()", "parent": 170, "children": [], "start_point": {"row": 54, "column": 43}, "end_point": {"row": 54, "column": 45}}, {"id": 173, "type": "return_statement", "text": "return links;", "parent": 136, "children": [174], "start_point": {"row": 56, "column": 4}, "end_point": {"row": 56, "column": 17}}, {"id": 174, "type": "identifier", "text": "links", "parent": 173, "children": [], "start_point": {"row": 56, "column": 11}, "end_point": {"row": 56, "column": 16}}, {"id": 175, "type": "function_definition", "text": "inline size_t getExtensionNum()\n\t\t\t{\n\t\t\t\treturn re_extension.size();\n\t\t\t}", "parent": 18, "children": [176, 178, 179], "start_point": {"row": 58, "column": 3}, "end_point": {"row": 61, "column": 4}}, {"id": 176, "type": "storage_class_specifier", "text": "inline", "parent": 175, "children": [177], "start_point": {"row": 58, "column": 3}, "end_point": {"row": 58, "column": 9}}, {"id": 177, "type": "inline", "text": "inline", "parent": 176, "children": [], "start_point": {"row": 58, "column": 3}, "end_point": {"row": 58, "column": 9}}, {"id": 178, "type": "primitive_type", "text": "size_t", "parent": 175, "children": [], "start_point": {"row": 58, "column": 10}, "end_point": {"row": 58, "column": 16}}, {"id": 179, "type": "function_declarator", "text": "getExtensionNum()", "parent": 175, "children": [180, 181], "start_point": {"row": 58, "column": 17}, "end_point": {"row": 58, "column": 34}}, {"id": 180, "type": "identifier", "text": "getExtensionNum", "parent": 179, "children": [], "start_point": {"row": 58, "column": 17}, "end_point": {"row": 58, "column": 32}}, {"id": 181, "type": "parameter_list", "text": "()", "parent": 179, "children": [], "start_point": {"row": 58, "column": 32}, "end_point": {"row": 58, "column": 34}}, {"id": 182, "type": "return_statement", "text": "return re_extension.size();", "parent": 175, "children": [183], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 31}}, {"id": 183, "type": "call_expression", "text": "re_extension.size()", "parent": 182, "children": [184, 187], "start_point": {"row": 60, "column": 11}, "end_point": {"row": 60, "column": 30}}, {"id": 184, "type": "field_expression", "text": "re_extension.size", "parent": 183, "children": [185, 186], "start_point": {"row": 60, "column": 11}, "end_point": {"row": 60, "column": 28}}, {"id": 185, "type": "identifier", "text": "re_extension", "parent": 184, "children": [], "start_point": {"row": 60, "column": 11}, "end_point": {"row": 60, "column": 23}}, {"id": 186, "type": "field_identifier", "text": "size", "parent": 184, "children": [], "start_point": {"row": 60, "column": 24}, "end_point": {"row": 60, "column": 28}}, {"id": 187, "type": "argument_list", "text": "()", "parent": 183, "children": [], "start_point": {"row": 60, "column": 28}, "end_point": {"row": 60, "column": 30}}, {"id": 188, "type": "declaration", "text": "Composition getExtensionComposition();", "parent": 18, "children": [189, 190], "start_point": {"row": 63, "column": 3}, "end_point": {"row": 63, "column": 41}}, {"id": 189, "type": "type_identifier", "text": "Composition", "parent": 188, "children": [], "start_point": {"row": 63, "column": 3}, "end_point": {"row": 63, "column": 14}}, {"id": 190, "type": "function_declarator", "text": "getExtensionComposition()", "parent": 188, "children": [191, 192], "start_point": {"row": 63, "column": 15}, "end_point": {"row": 63, "column": 40}}, {"id": 191, "type": "identifier", "text": "getExtensionComposition", "parent": 190, "children": [], "start_point": {"row": 63, "column": 15}, "end_point": {"row": 63, "column": 38}}, {"id": 192, "type": "parameter_list", "text": "()", "parent": 190, "children": [], "start_point": {"row": 63, "column": 38}, "end_point": {"row": 63, "column": 40}}, {"id": 193, "type": "function_definition", "text": "inline Monosaccharide& getUnitByID(const size_t id)\n\t\t\t{\n\t\t\t\treturn mono_chain.at(id);\n\t\t\t}", "parent": 18, "children": [194, 196, 197], "start_point": {"row": 65, "column": 3}, "end_point": {"row": 68, "column": 4}}, {"id": 194, "type": "storage_class_specifier", "text": "inline", "parent": 193, "children": [195], "start_point": {"row": 65, "column": 3}, "end_point": {"row": 65, "column": 9}}, {"id": 195, "type": "inline", "text": "inline", "parent": 194, "children": [], "start_point": {"row": 65, "column": 3}, "end_point": {"row": 65, "column": 9}}, {"id": 196, "type": "type_identifier", "text": "Monosaccharide", "parent": 193, "children": [], "start_point": {"row": 65, "column": 10}, "end_point": {"row": 65, "column": 24}}, {"id": 197, "type": "function_declarator", "text": "getUnitByID(const size_t id)", "parent": 193, "children": [198, 199], "start_point": {"row": 65, "column": 26}, "end_point": {"row": 65, "column": 54}}, {"id": 198, "type": "identifier", "text": "getUnitByID", "parent": 197, "children": [], "start_point": {"row": 65, "column": 26}, "end_point": {"row": 65, "column": 37}}, {"id": 199, "type": "parameter_list", "text": "(const size_t id)", "parent": 197, "children": [200], "start_point": {"row": 65, "column": 37}, "end_point": {"row": 65, "column": 54}}, {"id": 200, "type": "parameter_declaration", "text": "const size_t id", "parent": 199, "children": [201, 202], "start_point": {"row": 65, "column": 38}, "end_point": {"row": 65, "column": 53}}, {"id": 201, "type": "primitive_type", "text": "size_t", "parent": 200, "children": [], "start_point": {"row": 65, "column": 44}, "end_point": {"row": 65, "column": 50}}, {"id": 202, "type": "identifier", "text": "id", "parent": 200, "children": [], "start_point": {"row": 65, "column": 51}, "end_point": {"row": 65, "column": 53}}, {"id": 203, "type": "return_statement", "text": "return mono_chain.at(id);", "parent": 193, "children": [204], "start_point": {"row": 67, "column": 4}, "end_point": {"row": 67, "column": 29}}, {"id": 204, "type": "call_expression", "text": "mono_chain.at(id)", "parent": 203, "children": [205, 208], "start_point": {"row": 67, "column": 11}, "end_point": {"row": 67, "column": 28}}, {"id": 205, "type": "field_expression", "text": "mono_chain.at", "parent": 204, "children": [206, 207], "start_point": {"row": 67, "column": 11}, "end_point": {"row": 67, "column": 24}}, {"id": 206, "type": "identifier", "text": "mono_chain", "parent": 205, "children": [], "start_point": {"row": 67, "column": 11}, "end_point": {"row": 67, "column": 21}}, {"id": 207, "type": "field_identifier", "text": "at", "parent": 205, "children": [], "start_point": {"row": 67, "column": 22}, "end_point": {"row": 67, "column": 24}}, {"id": 208, "type": "argument_list", "text": "(id)", "parent": 204, "children": [209], "start_point": {"row": 67, "column": 24}, "end_point": {"row": 67, "column": 28}}, {"id": 209, "type": "identifier", "text": "id", "parent": 208, "children": [], "start_point": {"row": 67, "column": 25}, "end_point": {"row": 67, "column": 27}}, {"id": 210, "type": "declaration", "text": "void update();", "parent": 18, "children": [211, 212], "start_point": {"row": 71, "column": 3}, "end_point": {"row": 71, "column": 17}}, {"id": 211, "type": "primitive_type", "text": "void", "parent": 210, "children": [], "start_point": {"row": 71, "column": 3}, "end_point": {"row": 71, "column": 7}}, {"id": 212, "type": "function_declarator", "text": "update()", "parent": 210, "children": [213, 214], "start_point": {"row": 71, "column": 8}, "end_point": {"row": 71, "column": 16}}, {"id": 213, "type": "identifier", "text": "update", "parent": 212, "children": [], "start_point": {"row": 71, "column": 8}, "end_point": {"row": 71, "column": 14}}, {"id": 214, "type": "parameter_list", "text": "()", "parent": 212, "children": [], "start_point": {"row": 71, "column": 14}, "end_point": {"row": 71, "column": 16}}, {"id": 215, "type": "declaration", "text": "Composition getSubComposition(const size_t start, const size_t end);", "parent": 18, "children": [216, 217], "start_point": {"row": 74, "column": 3}, "end_point": {"row": 74, "column": 71}}, {"id": 216, "type": "type_identifier", "text": "Composition", "parent": 215, "children": [], "start_point": {"row": 74, "column": 3}, "end_point": {"row": 74, "column": 14}}, {"id": 217, "type": "function_declarator", "text": "getSubComposition(const size_t start, const size_t end)", "parent": 215, "children": [218, 219], "start_point": {"row": 74, "column": 15}, "end_point": {"row": 74, "column": 70}}, {"id": 218, "type": "identifier", "text": "getSubComposition", "parent": 217, "children": [], "start_point": {"row": 74, "column": 15}, "end_point": {"row": 74, "column": 32}}, {"id": 219, "type": "parameter_list", "text": "(const size_t start, const size_t end)", "parent": 217, "children": [220, 223], "start_point": {"row": 74, "column": 32}, "end_point": {"row": 74, "column": 70}}, {"id": 220, "type": "parameter_declaration", "text": "const size_t start", "parent": 219, "children": [221, 222], "start_point": {"row": 74, "column": 33}, "end_point": {"row": 74, "column": 51}}, {"id": 221, "type": "primitive_type", "text": "size_t", "parent": 220, "children": [], "start_point": {"row": 74, "column": 39}, "end_point": {"row": 74, "column": 45}}, {"id": 222, "type": "identifier", "text": "start", "parent": 220, "children": [], "start_point": {"row": 74, "column": 46}, "end_point": {"row": 74, "column": 51}}, {"id": 223, "type": "parameter_declaration", "text": "const size_t end", "parent": 219, "children": [224], "start_point": {"row": 74, "column": 53}, "end_point": {"row": 74, "column": 69}}, {"id": 224, "type": "primitive_type", "text": "size_t", "parent": 223, "children": [], "start_point": {"row": 74, "column": 59}, "end_point": {"row": 74, "column": 65}}, {"id": 225, "type": "declaration", "text": "void printStructure();", "parent": 18, "children": [226, 227], "start_point": {"row": 76, "column": 3}, "end_point": {"row": 76, "column": 25}}, {"id": 226, "type": "primitive_type", "text": "void", "parent": 225, "children": [], "start_point": {"row": 76, "column": 3}, "end_point": {"row": 76, "column": 7}}, {"id": 227, "type": "function_declarator", "text": "printStructure()", "parent": 225, "children": [228, 229], "start_point": {"row": 76, "column": 8}, "end_point": {"row": 76, "column": 24}}, {"id": 228, "type": "identifier", "text": "printStructure", "parent": 227, "children": [], "start_point": {"row": 76, "column": 8}, "end_point": {"row": 76, "column": 22}}, {"id": 229, "type": "parameter_list", "text": "()", "parent": 227, "children": [], "start_point": {"row": 76, "column": 22}, "end_point": {"row": 76, "column": 24}}, {"id": 230, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 80, "column": 0}, "end_point": {"row": 80, "column": 6}}]}, "node_categories": {"declarations": {"functions": [15, 18, 61, 66, 70, 73, 77, 85, 93, 117, 122, 131, 136, 145, 154, 158, 170, 175, 179, 190, 193, 197, 212, 217, 227], "variables": [23, 54, 64, 80, 83, 88, 91, 96, 148, 188, 200, 210, 215, 220, 223, 225], "classes": [114, 123, 137, 162, 176, 194], "imports": [6, 7, 9, 10, 12, 13], "modules": [], "enums": []}, "statements": {"expressions": [28, 29, 37, 38, 46, 47, 101, 102, 107, 183, 184, 204, 205], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 16, 17, 19, 21, 25, 27, 30, 32, 34, 36, 39, 41, 43, 45, 48, 50, 52, 55, 56, 60, 62, 65, 67, 71, 74, 78, 81, 82, 86, 89, 90, 94, 97, 98, 100, 103, 105, 108, 111, 112, 118, 121, 125, 127, 129, 132, 135, 139, 141, 143, 146, 150, 155, 157, 159, 164, 166, 168, 171, 174, 180, 185, 186, 189, 191, 196, 198, 202, 206, 207, 209, 213, 216, 218, 222, 228, 230], "returns": [120, 134, 173, 182, 203], "exceptions": []}, "expressions": {"calls": [], "literals": [8, 11, 14], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 15, "universal_type": "function", "name": "Branch", "text_snippet": "namespace gag\n{\n\tclass Branch : public Unit\n\t{\n\t\tprivate:\n\t\t\tsize_t branch_id;\n\t\t\t\n\t\t\tstd::vector<Mo"}, {"node_id": 18, "universal_type": "function", "name": "Branch", "text_snippet": "class Branch : public Unit\n\t{\n\t\tprivate:\n\t\t\tsize_t branch_id;\n\t\t\t\n\t\t\tstd::vector<Monosaccharide> mon"}, {"node_id": 61, "universal_type": "function", "name": "unknown", "text_snippet": "branch_id(id)"}, {"node_id": 66, "universal_type": "function", "name": "unknown", "text_snippet": "mono_chain()"}, {"node_id": 70, "universal_type": "function", "name": "unknown", "text_snippet": "links()"}, {"node_id": 73, "universal_type": "function", "name": "unknown", "text_snippet": "Branch()"}, {"node_id": 77, "universal_type": "function", "name": "unknown", "text_snippet": "addUnit(Monosaccharide& mono_unit)"}, {"node_id": 85, "universal_type": "function", "name": "unknown", "text_snippet": "addLinkage(const Linkage& link)"}, {"node_id": 93, "universal_type": "function", "name": "unknown", "text_snippet": "addExtension(Composition& compo)"}, {"node_id": 117, "universal_type": "function", "name": "unknown", "text_snippet": "getBranchID()"}, {"node_id": 122, "universal_type": "function", "name": "unknown", "text_snippet": "inline std::vector<Monosaccharide>& getGlycanChainUnits()\n\t\t\t{\n\t\t\t\treturn mono_chain;\n\t\t\t}"}, {"node_id": 131, "universal_type": "function", "name": "unknown", "text_snippet": "getGlycanChainUnits()"}, {"node_id": 136, "universal_type": "function", "name": "unknown", "text_snippet": "inline const std::vector<Monosaccharide>& getGlycanChainUnits() const\n\t\t\t{\n\t\t\t\treturn mono_chain;\n\t\t"}, {"node_id": 145, "universal_type": "function", "name": "unknown", "text_snippet": "getGlycanChainUnits()"}, {"node_id": 154, "universal_type": "function", "name": "unknown", "text_snippet": "getUnitNum()"}, {"node_id": 158, "universal_type": "function", "name": "unknown", "text_snippet": "size()"}, {"node_id": 170, "universal_type": "function", "name": "unknown", "text_snippet": "getLinkages()"}, {"node_id": 175, "universal_type": "function", "name": "unknown", "text_snippet": "inline size_t getExtensionNum()\n\t\t\t{\n\t\t\t\treturn re_extension.size();\n\t\t\t}"}, {"node_id": 179, "universal_type": "function", "name": "unknown", "text_snippet": "getExtensionNum()"}, {"node_id": 190, "universal_type": "function", "name": "unknown", "text_snippet": "getExtensionComposition()"}, {"node_id": 193, "universal_type": "function", "name": "unknown", "text_snippet": "inline Monosaccharide& getUnitByID(const size_t id)\n\t\t\t{\n\t\t\t\treturn mono_chain.at(id);\n\t\t\t}"}, {"node_id": 197, "universal_type": "function", "name": "unknown", "text_snippet": "getUnitByID(const size_t id)"}, {"node_id": 212, "universal_type": "function", "name": "unknown", "text_snippet": "update()"}, {"node_id": 217, "universal_type": "function", "name": "unknown", "text_snippet": "getSubComposition(const size_t start, const size_t end)"}, {"node_id": 227, "universal_type": "function", "name": "unknown", "text_snippet": "printStructure()"}], "class_declarations": [{"node_id": 114, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}, {"node_id": 123, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}, {"node_id": 137, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}, {"node_id": 162, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}, {"node_id": 176, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}, {"node_id": 194, "universal_type": "class", "name": "unknown", "text_snippet": "inline"}], "import_statements": [{"node_id": 6, "text": "#include <algorithm>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <GAGPL/GLYCAN/Linkage.h>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include <GAGPL/GLYCAN/Monosaccharide.h>\n"}, {"node_id": 13, "text": "#include"}]}, "original_source_code": "#ifndef GAG_BRANCH_INC\n#define GAG_BRANCH_INC\n\n#include <algorithm>\n#include <GAGPL/GLYCAN/Linkage.h>\n#include <GAGPL/GLYCAN/Monosaccharide.h>\n\nnamespace gag\n{\n\tclass Branch : public Unit\n\t{\n\t\tprivate:\n\t\t\tsize_t branch_id;\n\t\t\t\n\t\t\tstd::vector<Monosaccharide> mono_chain;\n\t\t\tstd::vector<Composition> re_extension;\n\n\t\t\t// For glycan, there will be only one reducing end.\n\t\t\t\n\t\t\t// The mono_id and the linkage.\n\t\t\tstd::vector<Linkage> links;\n\n\t\tpublic:\n\t\t\tBranch(const size_t id)\n\t\t\t\t: branch_id(id), mono_chain(), links()\n\t\t\t{}\n\t\t\tBranch(){}\n\n\t\t\tvoid addUnit(Monosaccharide& mono_unit);\n\t\t\t\n\t\t\tvoid addLinkage(const Linkage& link);\n\n\t\t\tvoid addExtension(Composition& compo);\n\n\t\t\tstd::vector<Linkage> getNeighborLinks(const size_t mono_id);\n\n\t\t\tinline size_t getBranchID() const\n\t\t\t{\n\t\t\t\treturn branch_id;\n\t\t\t}\n\n\t\t\tinline std::vector<Monosaccharide>& getGlycanChainUnits()\n\t\t\t{\n\t\t\t\treturn mono_chain;\n\t\t\t}\n\t\t\tinline const std::vector<Monosaccharide>& getGlycanChainUnits() const\n\t\t\t{\n\t\t\t\treturn mono_chain;\n\t\t\t}\n\n\t\t\tinline size_t getUnitNum()\n\t\t\t{\n\t\t\t\treturn mono_chain.size();\n\t\t\t}\n\t\t\tinline std::vector<Linkage>& getLinkages()\n\t\t\t{\n\t\t\t\treturn links;\n\t\t\t}\n\t\t\tinline size_t getExtensionNum()\n\t\t\t{\n\t\t\t\treturn re_extension.size();\n\t\t\t}\n\n\t\t\tComposition getExtensionComposition();\n\n\t\t\tinline Monosaccharide& getUnitByID(const size_t id)\n\t\t\t{\n\t\t\t\treturn mono_chain.at(id);\n\t\t\t}\n\t\t\t\n\t\t\t// Calculate the mass and composition. The correction of the terminal mass will be considered.\n\t\t\tvoid update();\n\n\t\t\t// Useful for calculating fragment mass.\n\t\t\tComposition getSubComposition(const size_t start, const size_t end);\n\t\t\n\t\t\tvoid printStructure();\n\t};\n}\n\n#endif /* ----- #ifndef GAG_BRANCH_INC ----- */\n"}
80,556
c
// COPYRIGHT <NAME> 2020 //=================================================================== // // TestMeasurementCmd.h // The state chart based command: TestMeasurementCmd // //=================================================================== // // Usage notes: // //=================================================================== //CAA2 Wizard Generation Report // STATECOMMAND //End CAA2 Wizard Generation Report // // May 2020 Creation: Code generated by the CAA wizard Administrator //=================================================================== #ifndef TestMeasurementCmd_H #define TestMeasurementCmd_H #include "CATStateCommand.h" #include "CATBoolean.h" #include "TestMeasurementDlg.h" #include "GeneralClass.h" #include "CATIMeasurableInContext.h" #include "CATIClashFactory.h" #include "CATIClashResult.h" #include "CATIClash.h" #include "CATIConflict.h" class CATIndicationAgent; //---------------------------------------------------------------------- /** * Describe your command here. * <p> * Using this prefered syntax will enable mkdoc to document your class. * <p> * refer to programming resources of Dialog engine framework. * (consult base class description). */ class TestMeasurementCmd: public CATStateCommand { // Allows customization/internationalization of command's messages // --------------------------------------------------------------- DeclareResource( TestMeasurementCmd, CATStateCommand ) public: TestMeasurementCmd(); virtual ~TestMeasurementCmd(); /** * Defines the command automata. * <br> * <i>(states, transitions and agents)</i> */ virtual void BuildGraph(); /** * Action associated to state transitions. */ virtual CATBoolean ActionOne(void * data); CATBoolean ActionExit(void * data); void selectObjAFunc(void * data); void selectObjBFunc(void * data); CATBoolean ActionOK(void * data); void TransToSelectA(void * data); void TransToSelectB(void * data); HRESULT GetMinDistanceByMeasure(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance); CATMathTransformation GetMatrixTransformation( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo ); CATMathTransformation GetAbsTransformation( CATISpecObject_var ispSpecOne ); HRESULT CheckClash(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2); CATBoolean ActionOK2(void * data); HRESULT MeasureByDichotomy(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir); HRESULT MeasureMinDistAmongProducts(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance); CATBoolean ActionOK3(void * data); private: TestMeasurementDlg *_pDlg; CATFrmEditor *_pEditor; CATHSO *_pHSO; GeneralClass *_pGeneralCls; CATFeatureImportAgent * _pSelAAgent; CATFeatureImportAgent * _pSelBAgent; CATDialogAgent * _pSelAFieldAgent; CATDialogAgent * _pSelBFieldAgent; CATBaseUnknown_var _spBUSelectA; CATBaseUnknown_var _spBUSelectB; CATIProduct_var _spiProdSelA; CATIProduct_var _spiProdSelB; }; //---------------------------------------------------------------------- #endif
37.69
86
(translation_unit) "// COPYRIGHT <NAME> 2020\n//===================================================================\n//\n// TestMeasurementCmd.h\n// The state chart based command: TestMeasurementCmd\n//\n//===================================================================\n//\n// Usage notes:\n//\n//===================================================================\n//CAA2 Wizard Generation Report\n// STATECOMMAND\n//End CAA2 Wizard Generation Report\n//\n// May 2020 Creation: Code generated by the CAA wizard Administrator\n//===================================================================\n#ifndef TestMeasurementCmd_H\n#define TestMeasurementCmd_H\n\n#include "CATStateCommand.h"\n#include "CATBoolean.h"\n\n#include "TestMeasurementDlg.h"\n#include "GeneralClass.h"\n\n#include "CATIMeasurableInContext.h"\n\n#include "CATIClashFactory.h"\n#include "CATIClashResult.h"\n#include "CATIClash.h"\n#include "CATIConflict.h"\n\nclass CATIndicationAgent;\n\n//----------------------------------------------------------------------\n\n/**\n * Describe your command here.\n * <p>\n * Using this prefered syntax will enable mkdoc to document your class.\n * <p>\n * refer to programming resources of Dialog engine framework.\n * (consult base class description).\n */\nclass TestMeasurementCmd: public CATStateCommand\n{\n // Allows customization/internationalization of command's messages\n // ---------------------------------------------------------------\n DeclareResource( TestMeasurementCmd, CATStateCommand )\n\n public:\n\n TestMeasurementCmd();\n virtual ~TestMeasurementCmd();\n\n /**\n * Defines the command automata.\n * <br>\n * <i>(states, transitions and agents)</i>\n */\n virtual void BuildGraph();\n\n /**\n * Action associated to state transitions.\n */\n virtual CATBoolean ActionOne(void * data);\n CATBoolean ActionExit(void * data);\n void selectObjAFunc(void * data);\n void selectObjBFunc(void * data);\n CATBoolean ActionOK(void * data);\n void TransToSelectA(void * data);\n void TransToSelectB(void * data);\n HRESULT GetMinDistanceByMeasure(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance);\n CATMathTransformation GetMatrixTransformation( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo );\n CATMathTransformation GetAbsTransformation( CATISpecObject_var ispSpecOne );\n HRESULT CheckClash(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2);\n CATBoolean ActionOK2(void * data);\n HRESULT MeasureByDichotomy(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir);\n HRESULT MeasureMinDistAmongProducts(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance);\n CATBoolean ActionOK3(void * data);\nprivate:\n\n TestMeasurementDlg *_pDlg;\n\n CATFrmEditor *_pEditor;\n\n CATHSO *_pHSO;\n\n GeneralClass *_pGeneralCls;\n\n CATFeatureImportAgent * _pSelAAgent;\n\n CATFeatureImportAgent * _pSelBAgent;\n\n CATDialogAgent * _pSelAFieldAgent;\n\n CATDialogAgent * _pSelBFieldAgent;\n\n CATBaseUnknown_var _spBUSelectA;\n\n CATBaseUnknown_var _spBUSelectB;\n\n CATIProduct_var _spiProdSelA;\n\n CATIProduct_var _spiProdSelB;\n\n};\n\n//----------------------------------------------------------------------\n\n#endif\n" (comment) "// COPYRIGHT <NAME> 2020" (comment) "//===================================================================" (comment) "//" (comment) "// TestMeasurementCmd.h" (comment) "// The state chart based command: TestMeasurementCmd" (comment) "//" (comment) "//===================================================================" (comment) "//" (comment) "// Usage notes:" (comment) "//" (comment) "//===================================================================" (comment) "//CAA2 Wizard Generation Report" (comment) "// STATECOMMAND" (comment) "//End CAA2 Wizard Generation Report" (comment) "//" (comment) "// May 2020 Creation: Code generated by the CAA wizard Administrator" (comment) "//===================================================================" (preproc_ifdef) "#ifndef TestMeasurementCmd_H\n#define TestMeasurementCmd_H\n\n#include "CATStateCommand.h"\n#include "CATBoolean.h"\n\n#include "TestMeasurementDlg.h"\n#include "GeneralClass.h"\n\n#include "CATIMeasurableInContext.h"\n\n#include "CATIClashFactory.h"\n#include "CATIClashResult.h"\n#include "CATIClash.h"\n#include "CATIConflict.h"\n\nclass CATIndicationAgent;\n\n//----------------------------------------------------------------------\n\n/**\n * Describe your command here.\n * <p>\n * Using this prefered syntax will enable mkdoc to document your class.\n * <p>\n * refer to programming resources of Dialog engine framework.\n * (consult base class description).\n */\nclass TestMeasurementCmd: public CATStateCommand\n{\n // Allows customization/internationalization of command's messages\n // ---------------------------------------------------------------\n DeclareResource( TestMeasurementCmd, CATStateCommand )\n\n public:\n\n TestMeasurementCmd();\n virtual ~TestMeasurementCmd();\n\n /**\n * Defines the command automata.\n * <br>\n * <i>(states, transitions and agents)</i>\n */\n virtual void BuildGraph();\n\n /**\n * Action associated to state transitions.\n */\n virtual CATBoolean ActionOne(void * data);\n CATBoolean ActionExit(void * data);\n void selectObjAFunc(void * data);\n void selectObjBFunc(void * data);\n CATBoolean ActionOK(void * data);\n void TransToSelectA(void * data);\n void TransToSelectB(void * data);\n HRESULT GetMinDistanceByMeasure(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance);\n CATMathTransformation GetMatrixTransformation( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo );\n CATMathTransformation GetAbsTransformation( CATISpecObject_var ispSpecOne );\n HRESULT CheckClash(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2);\n CATBoolean ActionOK2(void * data);\n HRESULT MeasureByDichotomy(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir);\n HRESULT MeasureMinDistAmongProducts(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance);\n CATBoolean ActionOK3(void * data);\nprivate:\n\n TestMeasurementDlg *_pDlg;\n\n CATFrmEditor *_pEditor;\n\n CATHSO *_pHSO;\n\n GeneralClass *_pGeneralCls;\n\n CATFeatureImportAgent * _pSelAAgent;\n\n CATFeatureImportAgent * _pSelBAgent;\n\n CATDialogAgent * _pSelAFieldAgent;\n\n CATDialogAgent * _pSelBFieldAgent;\n\n CATBaseUnknown_var _spBUSelectA;\n\n CATBaseUnknown_var _spBUSelectB;\n\n CATIProduct_var _spiProdSelA;\n\n CATIProduct_var _spiProdSelB;\n\n};\n\n//----------------------------------------------------------------------\n\n#endif" (#ifndef) "#ifndef" (identifier) "TestMeasurementCmd_H" (preproc_def) "#define TestMeasurementCmd_H\n" (#define) "#define" (identifier) "TestMeasurementCmd_H" (preproc_include) "#include "CATStateCommand.h"\n" (#include) "#include" (string_literal) ""CATStateCommand.h"" (") """ (string_content) "CATStateCommand.h" (") """ (preproc_include) "#include "CATBoolean.h"\n" (#include) "#include" (string_literal) ""CATBoolean.h"" (") """ (string_content) "CATBoolean.h" (") """ (preproc_include) "#include "TestMeasurementDlg.h"\n" (#include) "#include" (string_literal) ""TestMeasurementDlg.h"" (") """ (string_content) "TestMeasurementDlg.h" (") """ (preproc_include) "#include "GeneralClass.h"\n" (#include) "#include" (string_literal) ""GeneralClass.h"" (") """ (string_content) "GeneralClass.h" (") """ (preproc_include) "#include "CATIMeasurableInContext.h"\n" (#include) "#include" (string_literal) ""CATIMeasurableInContext.h"" (") """ (string_content) "CATIMeasurableInContext.h" (") """ (preproc_include) "#include "CATIClashFactory.h"\n" (#include) "#include" (string_literal) ""CATIClashFactory.h"" (") """ (string_content) "CATIClashFactory.h" (") """ (preproc_include) "#include "CATIClashResult.h"\n" (#include) "#include" (string_literal) ""CATIClashResult.h"" (") """ (string_content) "CATIClashResult.h" (") """ (preproc_include) "#include "CATIClash.h"\n" (#include) "#include" (string_literal) ""CATIClash.h"" (") """ (string_content) "CATIClash.h" (") """ (preproc_include) "#include "CATIConflict.h"\n" (#include) "#include" (string_literal) ""CATIConflict.h"" (") """ (string_content) "CATIConflict.h" (") """ (declaration) "class CATIndicationAgent;" (type_identifier) "class" (identifier) "CATIndicationAgent" (;) ";" (comment) "//----------------------------------------------------------------------" (comment) "/**\n * Describe your command here.\n * <p>\n * Using this prefered syntax will enable mkdoc to document your class.\n * <p>\n * refer to programming resources of Dialog engine framework.\n * (consult base class description).\n */" (function_definition) "class TestMeasurementCmd: public CATStateCommand\n{\n // Allows customization/internationalization of command's messages\n // ---------------------------------------------------------------\n DeclareResource( TestMeasurementCmd, CATStateCommand )\n\n public:\n\n TestMeasurementCmd();\n virtual ~TestMeasurementCmd();\n\n /**\n * Defines the command automata.\n * <br>\n * <i>(states, transitions and agents)</i>\n */\n virtual void BuildGraph();\n\n /**\n * Action associated to state transitions.\n */\n virtual CATBoolean ActionOne(void * data);\n CATBoolean ActionExit(void * data);\n void selectObjAFunc(void * data);\n void selectObjBFunc(void * data);\n CATBoolean ActionOK(void * data);\n void TransToSelectA(void * data);\n void TransToSelectB(void * data);\n HRESULT GetMinDistanceByMeasure(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance);\n CATMathTransformation GetMatrixTransformation( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo );\n CATMathTransformation GetAbsTransformation( CATISpecObject_var ispSpecOne );\n HRESULT CheckClash(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2);\n CATBoolean ActionOK2(void * data);\n HRESULT MeasureByDichotomy(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir);\n HRESULT MeasureMinDistAmongProducts(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance);\n CATBoolean ActionOK3(void * data);\nprivate:\n\n TestMeasurementDlg *_pDlg;\n\n CATFrmEditor *_pEditor;\n\n CATHSO *_pHSO;\n\n GeneralClass *_pGeneralCls;\n\n CATFeatureImportAgent * _pSelAAgent;\n\n CATFeatureImportAgent * _pSelBAgent;\n\n CATDialogAgent * _pSelAFieldAgent;\n\n CATDialogAgent * _pSelBFieldAgent;\n\n CATBaseUnknown_var _spBUSelectA;\n\n CATBaseUnknown_var _spBUSelectB;\n\n CATIProduct_var _spiProdSelA;\n\n CATIProduct_var _spiProdSelB;\n\n}" (type_identifier) "class" (identifier) "TestMeasurementCmd" (ERROR) ": public CATStateCommand" (:) ":" (identifier) "public" (identifier) "CATStateCommand" (compound_statement) "{\n // Allows customization/internationalization of command's messages\n // ---------------------------------------------------------------\n DeclareResource( TestMeasurementCmd, CATStateCommand )\n\n public:\n\n TestMeasurementCmd();\n virtual ~TestMeasurementCmd();\n\n /**\n * Defines the command automata.\n * <br>\n * <i>(states, transitions and agents)</i>\n */\n virtual void BuildGraph();\n\n /**\n * Action associated to state transitions.\n */\n virtual CATBoolean ActionOne(void * data);\n CATBoolean ActionExit(void * data);\n void selectObjAFunc(void * data);\n void selectObjBFunc(void * data);\n CATBoolean ActionOK(void * data);\n void TransToSelectA(void * data);\n void TransToSelectB(void * data);\n HRESULT GetMinDistanceByMeasure(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance);\n CATMathTransformation GetMatrixTransformation( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo );\n CATMathTransformation GetAbsTransformation( CATISpecObject_var ispSpecOne );\n HRESULT CheckClash(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2);\n CATBoolean ActionOK2(void * data);\n HRESULT MeasureByDichotomy(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir);\n HRESULT MeasureMinDistAmongProducts(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance);\n CATBoolean ActionOK3(void * data);\nprivate:\n\n TestMeasurementDlg *_pDlg;\n\n CATFrmEditor *_pEditor;\n\n CATHSO *_pHSO;\n\n GeneralClass *_pGeneralCls;\n\n CATFeatureImportAgent * _pSelAAgent;\n\n CATFeatureImportAgent * _pSelBAgent;\n\n CATDialogAgent * _pSelAFieldAgent;\n\n CATDialogAgent * _pSelBFieldAgent;\n\n CATBaseUnknown_var _spBUSelectA;\n\n CATBaseUnknown_var _spBUSelectB;\n\n CATIProduct_var _spiProdSelA;\n\n CATIProduct_var _spiProdSelB;\n\n}" ({) "{" (comment) "// Allows customization/internationalization of command's messages" (comment) "// ---------------------------------------------------------------" (expression_statement) "DeclareResource( TestMeasurementCmd, CATStateCommand )" (call_expression) "DeclareResource( TestMeasurementCmd, CATStateCommand )" (identifier) "DeclareResource" (argument_list) "( TestMeasurementCmd, CATStateCommand )" (() "(" (identifier) "TestMeasurementCmd" (,) "," (identifier) "CATStateCommand" ()) ")" (;) "" (labeled_statement) "public:\n\n TestMeasurementCmd();" (statement_identifier) "public" (:) ":" (expression_statement) "TestMeasurementCmd();" (call_expression) "TestMeasurementCmd()" (identifier) "TestMeasurementCmd" (argument_list) "()" (() "(" ()) ")" (;) ";" (declaration) "virtual ~TestMeasurementCmd();" (type_identifier) "virtual" (ERROR) "~" (~) "~" (function_declarator) "TestMeasurementCmd()" (identifier) "TestMeasurementCmd" (parameter_list) "()" (() "(" ()) ")" (;) ";" (comment) "/**\n * Defines the command automata.\n * <br>\n * <i>(states, transitions and agents)</i>\n */" (declaration) "virtual void BuildGraph();" (type_identifier) "virtual" (ERROR) "void" (identifier) "void" (function_declarator) "BuildGraph()" (identifier) "BuildGraph" (parameter_list) "()" (() "(" ()) ")" (;) ";" (comment) "/**\n * Action associated to state transitions.\n */" (declaration) "virtual CATBoolean ActionOne(void * data);" (type_identifier) "virtual" (ERROR) "CATBoolean" (identifier) "CATBoolean" (function_declarator) "ActionOne(void * data)" (identifier) "ActionOne" (parameter_list) "(void * data)" (() "(" (parameter_declaration) "void * data" (primitive_type) "void" (pointer_declarator) "* data" (*) "*" (identifier) "data" ()) ")" (;) ";" (declaration) "CATBoolean ActionExit(void * data);" (type_identifier) "CATBoolean" (function_declarator) "ActionExit(void * data)" (identifier) "ActionExit" (parameter_list) "(void * data)" (() "(" (parameter_declaration) "void * data" (primitive_type) "void" (pointer_declarator) "* data" (*) "*" (identifier) "data" ()) ")" (;) ";" (declaration) "void selectObjAFunc(void * data);" (primitive_type) "void" (function_declarator) "selectObjAFunc(void * data)" (identifier) "selectObjAFunc" (parameter_list) "(void * data)" (() "(" (parameter_declaration) "void * data" (primitive_type) "void" (pointer_declarator) "* data" (*) "*" (identifier) "data" ()) ")" (;) ";" (declaration) "void selectObjBFunc(void * data);" (primitive_type) "void" (function_declarator) "selectObjBFunc(void * data)" (identifier) "selectObjBFunc" (parameter_list) "(void * data)" (() "(" (parameter_declaration) "void * data" (primitive_type) "void" (pointer_declarator) "* data" (*) "*" (identifier) "data" ()) ")" (;) ";" (declaration) "CATBoolean ActionOK(void * data);" (type_identifier) "CATBoolean" (function_declarator) "ActionOK(void * data)" (identifier) "ActionOK" (parameter_list) "(void * data)" (() "(" (parameter_declaration) "void * data" (primitive_type) "void" (pointer_declarator) "* data" (*) "*" (identifier) "data" ()) ")" (;) ";" (declaration) "void TransToSelectA(void * data);" (primitive_type) "void" (function_declarator) "TransToSelectA(void * data)" (identifier) "TransToSelectA" (parameter_list) "(void * data)" (() "(" (parameter_declaration) "void * data" (primitive_type) "void" (pointer_declarator) "* data" (*) "*" (identifier) "data" ()) ")" (;) ";" (declaration) "void TransToSelectB(void * data);" (primitive_type) "void" (function_declarator) "TransToSelectB(void * data)" (identifier) "TransToSelectB" (parameter_list) "(void * data)" (() "(" (parameter_declaration) "void * data" (primitive_type) "void" (pointer_declarator) "* data" (*) "*" (identifier) "data" ()) ")" (;) ";" (declaration) "HRESULT GetMinDistanceByMeasure(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance);" (type_identifier) "HRESULT" (function_declarator) "GetMinDistanceByMeasure(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance)" (identifier) "GetMinDistanceByMeasure" (parameter_list) "(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance)" (() "(" (parameter_declaration) "CATISpecObject_var ispiSpec1" (type_identifier) "CATISpecObject_var" (identifier) "ispiSpec1" (,) "," (parameter_declaration) "CATIProduct_var ispiProd1" (type_identifier) "CATIProduct_var" (identifier) "ispiProd1" (,) "," (parameter_declaration) "CATISpecObject_var ispiSpec2" (type_identifier) "CATISpecObject_var" (identifier) "ispiSpec2" (,) "," (parameter_declaration) "CATIProduct_var ispiProd2" (type_identifier) "CATIProduct_var" (identifier) "ispiProd2" (,) "," (parameter_declaration) "CATMathPoint &omathPt1" (type_identifier) "CATMathPoint" (ERROR) "&" (&) "&" (identifier) "omathPt1" (,) "," (parameter_declaration) "CATMathPoint &omathPt2" (type_identifier) "CATMathPoint" (ERROR) "&" (&) "&" (identifier) "omathPt2" (,) "," (parameter_declaration) "double &oDistance" (primitive_type) "double" (ERROR) "&" (&) "&" (identifier) "oDistance" ()) ")" (;) ";" (declaration) "CATMathTransformation GetMatrixTransformation( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo );" (type_identifier) "CATMathTransformation" (function_declarator) "GetMatrixTransformation( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo )" (identifier) "GetMatrixTransformation" (parameter_list) "( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo )" (() "(" (parameter_declaration) "CATISpecObject_var spSpecOne" (type_identifier) "CATISpecObject_var" (identifier) "spSpecOne" (,) "," (parameter_declaration) "CATISpecObject_var spSpecTwo" (type_identifier) "CATISpecObject_var" (identifier) "spSpecTwo" ()) ")" (;) ";" (declaration) "CATMathTransformation GetAbsTransformation( CATISpecObject_var ispSpecOne );" (type_identifier) "CATMathTransformation" (function_declarator) "GetAbsTransformation( CATISpecObject_var ispSpecOne )" (identifier) "GetAbsTransformation" (parameter_list) "( CATISpecObject_var ispSpecOne )" (() "(" (parameter_declaration) "CATISpecObject_var ispSpecOne" (type_identifier) "CATISpecObject_var" (identifier) "ispSpecOne" ()) ")" (;) ";" (declaration) "HRESULT CheckClash(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2);" (type_identifier) "HRESULT" (function_declarator) "CheckClash(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2)" (identifier) "CheckClash" (parameter_list) "(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2)" (() "(" (parameter_declaration) "CATIProduct_var ispiPrd1" (type_identifier) "CATIProduct_var" (identifier) "ispiPrd1" (,) "," (parameter_declaration) "CATIProduct_var ispiPrd2" (type_identifier) "CATIProduct_var" (identifier) "ispiPrd2" ()) ")" (;) ";" (declaration) "CATBoolean ActionOK2(void * data);" (type_identifier) "CATBoolean" (function_declarator) "ActionOK2(void * data)" (identifier) "ActionOK2" (parameter_list) "(void * data)" (() "(" (parameter_declaration) "void * data" (primitive_type) "void" (pointer_declarator) "* data" (*) "*" (identifier) "data" ()) ")" (;) ";" (declaration) "HRESULT MeasureByDichotomy(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir);" (type_identifier) "HRESULT" (function_declarator) "MeasureByDichotomy(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir)" (identifier) "MeasureByDichotomy" (parameter_list) "(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir)" (() "(" (parameter_declaration) "vector<CATIProduct_var> ilstProdA" (type_identifier) "vector" (ERROR) "<CATIProduct_var>" (<) "<" (identifier) "CATIProduct_var" (>) ">" (identifier) "ilstProdA" (,) "," (parameter_declaration) "vector<CATIProduct_var> ilstProdB" (type_identifier) "vector" (ERROR) "<CATIProduct_var>" (<) "<" (identifier) "CATIProduct_var" (>) ">" (identifier) "ilstProdB" (,) "," (parameter_declaration) "CATMathVector iDir" (type_identifier) "CATMathVector" (identifier) "iDir" ()) ")" (;) ";" (declaration) "HRESULT MeasureMinDistAmongProducts(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance);" (type_identifier) "HRESULT" (function_declarator) "MeasureMinDistAmongProducts(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance)" (identifier) "MeasureMinDistAmongProducts" (parameter_list) "(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance)" (() "(" (parameter_declaration) "vector<CATIProduct_var> ilstProdA" (type_identifier) "vector" (ERROR) "<CATIProduct_var>" (<) "<" (identifier) "CATIProduct_var" (>) ">" (identifier) "ilstProdA" (,) "," (parameter_declaration) "vector<CATIProduct_var> ilstProdB" (type_identifier) "vector" (ERROR) "<CATIProduct_var>" (<) "<" (identifier) "CATIProduct_var" (>) ">" (identifier) "ilstProdB" (,) "," (parameter_declaration) "CATMathPoint &oPtA" (type_identifier) "CATMathPoint" (ERROR) "&" (&) "&" (identifier) "oPtA" (,) "," (parameter_declaration) "CATMathPoint &oPtB" (type_identifier) "CATMathPoint" (ERROR) "&" (&) "&" (identifier) "oPtB" (,) "," (parameter_declaration) "double &odDistance" (primitive_type) "double" (ERROR) "&" (&) "&" (identifier) "odDistance" ()) ")" (;) ";" (declaration) "CATBoolean ActionOK3(void * data);" (type_identifier) "CATBoolean" (function_declarator) "ActionOK3(void * data)" (identifier) "ActionOK3" (parameter_list) "(void * data)" (() "(" (parameter_declaration) "void * data" (primitive_type) "void" (pointer_declarator) "* data" (*) "*" (identifier) "data" ()) ")" (;) ";" (labeled_statement) "private:\n\n TestMeasurementDlg *_pDlg;" (statement_identifier) "private" (:) ":" (declaration) "TestMeasurementDlg *_pDlg;" (type_identifier) "TestMeasurementDlg" (pointer_declarator) "*_pDlg" (*) "*" (identifier) "_pDlg" (;) ";" (declaration) "CATFrmEditor *_pEditor;" (type_identifier) "CATFrmEditor" (pointer_declarator) "*_pEditor" (*) "*" (identifier) "_pEditor" (;) ";" (declaration) "CATHSO *_pHSO;" (type_identifier) "CATHSO" (pointer_declarator) "*_pHSO" (*) "*" (identifier) "_pHSO" (;) ";" (declaration) "GeneralClass *_pGeneralCls;" (type_identifier) "GeneralClass" (pointer_declarator) "*_pGeneralCls" (*) "*" (identifier) "_pGeneralCls" (;) ";" (declaration) "CATFeatureImportAgent * _pSelAAgent;" (type_identifier) "CATFeatureImportAgent" (pointer_declarator) "* _pSelAAgent" (*) "*" (identifier) "_pSelAAgent" (;) ";" (declaration) "CATFeatureImportAgent * _pSelBAgent;" (type_identifier) "CATFeatureImportAgent" (pointer_declarator) "* _pSelBAgent" (*) "*" (identifier) "_pSelBAgent" (;) ";" (declaration) "CATDialogAgent * _pSelAFieldAgent;" (type_identifier) "CATDialogAgent" (pointer_declarator) "* _pSelAFieldAgent" (*) "*" (identifier) "_pSelAFieldAgent" (;) ";" (declaration) "CATDialogAgent * _pSelBFieldAgent;" (type_identifier) "CATDialogAgent" (pointer_declarator) "* _pSelBFieldAgent" (*) "*" (identifier) "_pSelBFieldAgent" (;) ";" (declaration) "CATBaseUnknown_var _spBUSelectA;" (type_identifier) "CATBaseUnknown_var" (identifier) "_spBUSelectA" (;) ";" (declaration) "CATBaseUnknown_var _spBUSelectB;" (type_identifier) "CATBaseUnknown_var" (identifier) "_spBUSelectB" (;) ";" (declaration) "CATIProduct_var _spiProdSelA;" (type_identifier) "CATIProduct_var" (identifier) "_spiProdSelA" (;) ";" (declaration) "CATIProduct_var _spiProdSelB;" (type_identifier) "CATIProduct_var" (identifier) "_spiProdSelB" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (comment) "//----------------------------------------------------------------------" (#endif) "#endif"
478
14
{"language": "c", "success": true, "metadata": {"lines": 86, "avg_line_length": 37.69, "nodes": 314, "errors": 0, "source_hash": "7f93a8102332e0affa43a46986b0cb7fc276a66a50039b7757fd9999e1a23672", "categorized_nodes": 225}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef TestMeasurementCmd_H\n#define TestMeasurementCmd_H\n\n#include \"CATStateCommand.h\"\n#include \"CATBoolean.h\"\n\n#include \"TestMeasurementDlg.h\"\n#include \"GeneralClass.h\"\n\n#include \"CATIMeasurableInContext.h\"\n\n#include \"CATIClashFactory.h\"\n#include \"CATIClashResult.h\"\n#include \"CATIClash.h\"\n#include \"CATIConflict.h\"\n\nclass CATIndicationAgent;\n\n//----------------------------------------------------------------------\n\n/**\n * Describe your command here.\n * <p>\n * Using this prefered syntax will enable mkdoc to document your class.\n * <p>\n * refer to programming resources of Dialog engine framework.\n * (consult base class description).\n */\nclass TestMeasurementCmd: public CATStateCommand\n{\n // Allows customization/internationalization of command's messages\n // ---------------------------------------------------------------\n DeclareResource( TestMeasurementCmd, CATStateCommand )\n\n public:\n\n TestMeasurementCmd();\n virtual ~TestMeasurementCmd();\n\n /**\n * Defines the command automata.\n * <br>\n * <i>(states, transitions and agents)</i>\n */\n virtual void BuildGraph();\n\n /**\n * Action associated to state transitions.\n */\n virtual CATBoolean ActionOne(void * data);\n CATBoolean ActionExit(void * data);\n void selectObjAFunc(void * data);\n void selectObjBFunc(void * data);\n CATBoolean ActionOK(void * data);\n void TransToSelectA(void * data);\n void TransToSelectB(void * data);\n HRESULT GetMinDistanceByMeasure(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance);\n CATMathTransformation GetMatrixTransformation( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo );\n CATMathTransformation GetAbsTransformation( CATISpecObject_var ispSpecOne );\n HRESULT CheckClash(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2);\n CATBoolean ActionOK2(void * data);\n HRESULT MeasureByDichotomy(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir);\n HRESULT MeasureMinDistAmongProducts(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance);\n CATBoolean ActionOK3(void * data);\nprivate:\n\n\t TestMeasurementDlg\t\t*_pDlg;\n\n\t CATFrmEditor\t\t\t*_pEditor;\n\n\t CATHSO\t\t\t\t*_pHSO;\n\n\t GeneralClass\t\t\t*_pGeneralCls;\n\n\t CATFeatureImportAgent * _pSelAAgent;\n\n\t CATFeatureImportAgent * _pSelBAgent;\n\n\t CATDialogAgent\t\t* _pSelAFieldAgent;\n\n\t CATDialogAgent\t\t* _pSelBFieldAgent;\n\n\t CATBaseUnknown_var\t_spBUSelectA;\n\n\t CATBaseUnknown_var\t_spBUSelectB;\n\n\t CATIProduct_var\t\t_spiProdSelA;\n\n\t CATIProduct_var\t\t_spiProdSelB;\n\n};\n\n//----------------------------------------------------------------------\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 15, 18, 21, 24, 27, 30, 33, 35, 313], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 111, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 7}}, {"id": 2, "type": "identifier", "text": "TestMeasurementCmd_H", "parent": 0, "children": [], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 17, "column": 28}}, {"id": 3, "type": "preproc_def", "text": "#define TestMeasurementCmd_H\n", "parent": 0, "children": [4, 5], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 19, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 7}}, {"id": 5, "type": "identifier", "text": "TestMeasurementCmd_H", "parent": 3, "children": [], "start_point": {"row": 18, "column": 8}, "end_point": {"row": 18, "column": 28}}, {"id": 6, "type": "preproc_include", "text": "#include \"CATStateCommand.h\"\n", "parent": 0, "children": [7, 8], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 21, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"CATStateCommand.h\"", "parent": 6, "children": [], "start_point": {"row": 20, "column": 9}, "end_point": {"row": 20, "column": 28}}, {"id": 9, "type": "preproc_include", "text": "#include \"CATBoolean.h\"\n", "parent": 0, "children": [10, 11], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 22, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"CATBoolean.h\"", "parent": 9, "children": [], "start_point": {"row": 21, "column": 9}, "end_point": {"row": 21, "column": 23}}, {"id": 12, "type": "preproc_include", "text": "#include \"TestMeasurementDlg.h\"\n", "parent": 0, "children": [13, 14], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 24, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 8}}, {"id": 14, "type": "string_literal", "text": "\"TestMeasurementDlg.h\"", "parent": 12, "children": [], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 31}}, {"id": 15, "type": "preproc_include", "text": "#include \"GeneralClass.h\"\n", "parent": 0, "children": [16, 17], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 25, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 8}}, {"id": 17, "type": "string_literal", "text": "\"GeneralClass.h\"", "parent": 15, "children": [], "start_point": {"row": 24, "column": 9}, "end_point": {"row": 24, "column": 25}}, {"id": 18, "type": "preproc_include", "text": "#include \"CATIMeasurableInContext.h\"\n", "parent": 0, "children": [19, 20], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 27, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 8}}, {"id": 20, "type": "string_literal", "text": "\"CATIMeasurableInContext.h\"", "parent": 18, "children": [], "start_point": {"row": 26, "column": 9}, "end_point": {"row": 26, "column": 36}}, {"id": 21, "type": "preproc_include", "text": "#include \"CATIClashFactory.h\"\n", "parent": 0, "children": [22, 23], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 29, "column": 0}}, {"id": 22, "type": "#include", "text": "#include", "parent": 21, "children": [], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 8}}, {"id": 23, "type": "string_literal", "text": "\"CATIClashFactory.h\"", "parent": 21, "children": [], "start_point": {"row": 28, "column": 9}, "end_point": {"row": 28, "column": 29}}, {"id": 24, "type": "preproc_include", "text": "#include \"CATIClashResult.h\"\n", "parent": 0, "children": [25, 26], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 30, "column": 0}}, {"id": 25, "type": "#include", "text": "#include", "parent": 24, "children": [], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 8}}, {"id": 26, "type": "string_literal", "text": "\"CATIClashResult.h\"", "parent": 24, "children": [], "start_point": {"row": 29, "column": 9}, "end_point": {"row": 29, "column": 28}}, {"id": 27, "type": "preproc_include", "text": "#include \"CATIClash.h\"\n", "parent": 0, "children": [28, 29], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 31, "column": 0}}, {"id": 28, "type": "#include", "text": "#include", "parent": 27, "children": [], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 8}}, {"id": 29, "type": "string_literal", "text": "\"CATIClash.h\"", "parent": 27, "children": [], "start_point": {"row": 30, "column": 9}, "end_point": {"row": 30, "column": 22}}, {"id": 30, "type": "preproc_include", "text": "#include \"CATIConflict.h\"\n", "parent": 0, "children": [31, 32], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 32, "column": 0}}, {"id": 31, "type": "#include", "text": "#include", "parent": 30, "children": [], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 31, "column": 8}}, {"id": 32, "type": "string_literal", "text": "\"CATIConflict.h\"", "parent": 30, "children": [], "start_point": {"row": 31, "column": 9}, "end_point": {"row": 31, "column": 25}}, {"id": 33, "type": "declaration", "text": "class CATIndicationAgent;", "parent": 0, "children": [34], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 33, "column": 25}}, {"id": 34, "type": "identifier", "text": "CATIndicationAgent", "parent": 33, "children": [], "start_point": {"row": 33, "column": 6}, "end_point": {"row": 33, "column": 24}}, {"id": 35, "type": "function_definition", "text": "class TestMeasurementCmd: public CATStateCommand\n{\n // Allows customization/internationalization of command's messages\n // ---------------------------------------------------------------\n DeclareResource( TestMeasurementCmd, CATStateCommand )\n\n public:\n\n TestMeasurementCmd();\n virtual ~TestMeasurementCmd();\n\n /**\n * Defines the command automata.\n * <br>\n * <i>(states, transitions and agents)</i>\n */\n virtual void BuildGraph();\n\n /**\n * Action associated to state transitions.\n */\n virtual CATBoolean ActionOne(void * data);\n CATBoolean ActionExit(void * data);\n void selectObjAFunc(void * data);\n void selectObjBFunc(void * data);\n CATBoolean ActionOK(void * data);\n void TransToSelectA(void * data);\n void TransToSelectB(void * data);\n HRESULT GetMinDistanceByMeasure(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance);\n CATMathTransformation GetMatrixTransformation( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo );\n CATMathTransformation GetAbsTransformation( CATISpecObject_var ispSpecOne );\n HRESULT CheckClash(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2);\n CATBoolean ActionOK2(void * data);\n HRESULT MeasureByDichotomy(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir);\n HRESULT MeasureMinDistAmongProducts(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance);\n CATBoolean ActionOK3(void * data);\nprivate:\n\n\t TestMeasurementDlg\t\t*_pDlg;\n\n\t CATFrmEditor\t\t\t*_pEditor;\n\n\t CATHSO\t\t\t\t*_pHSO;\n\n\t GeneralClass\t\t\t*_pGeneralCls;\n\n\t CATFeatureImportAgent * _pSelAAgent;\n\n\t CATFeatureImportAgent * _pSelBAgent;\n\n\t CATDialogAgent\t\t* _pSelAFieldAgent;\n\n\t CATDialogAgent\t\t* _pSelBFieldAgent;\n\n\t CATBaseUnknown_var\t_spBUSelectA;\n\n\t CATBaseUnknown_var\t_spBUSelectB;\n\n\t CATIProduct_var\t\t_spiProdSelA;\n\n\t CATIProduct_var\t\t_spiProdSelB;\n\n}", "parent": 0, "children": [36, 37], "start_point": {"row": 45, "column": 0}, "end_point": {"row": 107, "column": 1}}, {"id": 36, "type": "identifier", "text": "TestMeasurementCmd", "parent": 35, "children": [], "start_point": {"row": 45, "column": 6}, "end_point": {"row": 45, "column": 24}}, {"id": 37, "type": "ERROR", "text": ": public CATStateCommand", "parent": 35, "children": [38], "start_point": {"row": 45, "column": 24}, "end_point": {"row": 45, "column": 48}}, {"id": 38, "type": "identifier", "text": "CATStateCommand", "parent": 37, "children": [], "start_point": {"row": 45, "column": 33}, "end_point": {"row": 45, "column": 48}}, {"id": 39, "type": "call_expression", "text": "DeclareResource( TestMeasurementCmd, CATStateCommand )", "parent": 35, "children": [40, 41], "start_point": {"row": 49, "column": 2}, "end_point": {"row": 49, "column": 56}}, {"id": 40, "type": "identifier", "text": "DeclareResource", "parent": 39, "children": [], "start_point": {"row": 49, "column": 2}, "end_point": {"row": 49, "column": 17}}, {"id": 41, "type": "argument_list", "text": "( TestMeasurementCmd, CATStateCommand )", "parent": 39, "children": [42, 43], "start_point": {"row": 49, "column": 17}, "end_point": {"row": 49, "column": 56}}, {"id": 42, "type": "identifier", "text": "TestMeasurementCmd", "parent": 41, "children": [], "start_point": {"row": 49, "column": 19}, "end_point": {"row": 49, "column": 37}}, {"id": 43, "type": "identifier", "text": "CATStateCommand", "parent": 41, "children": [], "start_point": {"row": 49, "column": 39}, "end_point": {"row": 49, "column": 54}}, {"id": 44, "type": "labeled_statement", "text": "public:\n\n TestMeasurementCmd();", "parent": 35, "children": [], "start_point": {"row": 51, "column": 2}, "end_point": {"row": 53, "column": 23}}, {"id": 45, "type": "call_expression", "text": "TestMeasurementCmd()", "parent": 44, "children": [46, 47], "start_point": {"row": 53, "column": 2}, "end_point": {"row": 53, "column": 22}}, {"id": 46, "type": "identifier", "text": "TestMeasurementCmd", "parent": 45, "children": [], "start_point": {"row": 53, "column": 2}, "end_point": {"row": 53, "column": 20}}, {"id": 47, "type": "argument_list", "text": "()", "parent": 45, "children": [], "start_point": {"row": 53, "column": 20}, "end_point": {"row": 53, "column": 22}}, {"id": 48, "type": "declaration", "text": "virtual ~TestMeasurementCmd();", "parent": 35, "children": [49, 50, 52], "start_point": {"row": 54, "column": 2}, "end_point": {"row": 54, "column": 32}}, {"id": 49, "type": "type_identifier", "text": "virtual", "parent": 48, "children": [], "start_point": {"row": 54, "column": 2}, "end_point": {"row": 54, "column": 9}}, {"id": 50, "type": "ERROR", "text": "~", "parent": 48, "children": [51], "start_point": {"row": 54, "column": 10}, "end_point": {"row": 54, "column": 11}}, {"id": 51, "type": "~", "text": "~", "parent": 50, "children": [], "start_point": {"row": 54, "column": 10}, "end_point": {"row": 54, "column": 11}}, {"id": 52, "type": "function_declarator", "text": "TestMeasurementCmd()", "parent": 48, "children": [53, 54], "start_point": {"row": 54, "column": 11}, "end_point": {"row": 54, "column": 31}}, {"id": 53, "type": "identifier", "text": "TestMeasurementCmd", "parent": 52, "children": [], "start_point": {"row": 54, "column": 11}, "end_point": {"row": 54, "column": 29}}, {"id": 54, "type": "parameter_list", "text": "()", "parent": 52, "children": [], "start_point": {"row": 54, "column": 29}, "end_point": {"row": 54, "column": 31}}, {"id": 55, "type": "declaration", "text": "virtual void BuildGraph();", "parent": 35, "children": [56, 57, 59], "start_point": {"row": 61, "column": 2}, "end_point": {"row": 61, "column": 32}}, {"id": 56, "type": "type_identifier", "text": "virtual", "parent": 55, "children": [], "start_point": {"row": 61, "column": 2}, "end_point": {"row": 61, "column": 9}}, {"id": 57, "type": "ERROR", "text": "void", "parent": 55, "children": [58], "start_point": {"row": 61, "column": 10}, "end_point": {"row": 61, "column": 14}}, {"id": 58, "type": "identifier", "text": "void", "parent": 57, "children": [], "start_point": {"row": 61, "column": 10}, "end_point": {"row": 61, "column": 14}}, {"id": 59, "type": "function_declarator", "text": "BuildGraph()", "parent": 55, "children": [60, 61], "start_point": {"row": 61, "column": 19}, "end_point": {"row": 61, "column": 31}}, {"id": 60, "type": "identifier", "text": "BuildGraph", "parent": 59, "children": [], "start_point": {"row": 61, "column": 19}, "end_point": {"row": 61, "column": 29}}, {"id": 61, "type": "parameter_list", "text": "()", "parent": 59, "children": [], "start_point": {"row": 61, "column": 29}, "end_point": {"row": 61, "column": 31}}, {"id": 62, "type": "declaration", "text": "virtual CATBoolean ActionOne(void * data);", "parent": 35, "children": [63, 64, 66], "start_point": {"row": 66, "column": 2}, "end_point": {"row": 66, "column": 45}}, {"id": 63, "type": "type_identifier", "text": "virtual", "parent": 62, "children": [], "start_point": {"row": 66, "column": 2}, "end_point": {"row": 66, "column": 9}}, {"id": 64, "type": "ERROR", "text": "CATBoolean", "parent": 62, "children": [65], "start_point": {"row": 66, "column": 10}, "end_point": {"row": 66, "column": 20}}, {"id": 65, "type": "identifier", "text": "CATBoolean", "parent": 64, "children": [], "start_point": {"row": 66, "column": 10}, "end_point": {"row": 66, "column": 20}}, {"id": 66, "type": "function_declarator", "text": "ActionOne(void * data)", "parent": 62, "children": [67, 68], "start_point": {"row": 66, "column": 22}, "end_point": {"row": 66, "column": 44}}, {"id": 67, "type": "identifier", "text": "ActionOne", "parent": 66, "children": [], "start_point": {"row": 66, "column": 22}, "end_point": {"row": 66, "column": 31}}, {"id": 68, "type": "parameter_list", "text": "(void * data)", "parent": 66, "children": [69], "start_point": {"row": 66, "column": 31}, "end_point": {"row": 66, "column": 44}}, {"id": 69, "type": "parameter_declaration", "text": "void * data", "parent": 68, "children": [70, 71], "start_point": {"row": 66, "column": 32}, "end_point": {"row": 66, "column": 43}}, {"id": 70, "type": "primitive_type", "text": "void", "parent": 69, "children": [], "start_point": {"row": 66, "column": 32}, "end_point": {"row": 66, "column": 36}}, {"id": 71, "type": "pointer_declarator", "text": "* data", "parent": 69, "children": [72, 73], "start_point": {"row": 66, "column": 37}, "end_point": {"row": 66, "column": 43}}, {"id": 72, "type": "*", "text": "*", "parent": 71, "children": [], "start_point": {"row": 66, "column": 37}, "end_point": {"row": 66, "column": 38}}, {"id": 73, "type": "identifier", "text": "data", "parent": 71, "children": [], "start_point": {"row": 66, "column": 39}, "end_point": {"row": 66, "column": 43}}, {"id": 74, "type": "declaration", "text": "CATBoolean ActionExit(void * data);", "parent": 35, "children": [75, 76], "start_point": {"row": 67, "column": 2}, "end_point": {"row": 67, "column": 37}}, {"id": 75, "type": "type_identifier", "text": "CATBoolean", "parent": 74, "children": [], "start_point": {"row": 67, "column": 2}, "end_point": {"row": 67, "column": 12}}, {"id": 76, "type": "function_declarator", "text": "ActionExit(void * data)", "parent": 74, "children": [77, 78], "start_point": {"row": 67, "column": 13}, "end_point": {"row": 67, "column": 36}}, {"id": 77, "type": "identifier", "text": "ActionExit", "parent": 76, "children": [], "start_point": {"row": 67, "column": 13}, "end_point": {"row": 67, "column": 23}}, {"id": 78, "type": "parameter_list", "text": "(void * data)", "parent": 76, "children": [79], "start_point": {"row": 67, "column": 23}, "end_point": {"row": 67, "column": 36}}, {"id": 79, "type": "parameter_declaration", "text": "void * data", "parent": 78, "children": [80, 81], "start_point": {"row": 67, "column": 24}, "end_point": {"row": 67, "column": 35}}, {"id": 80, "type": "primitive_type", "text": "void", "parent": 79, "children": [], "start_point": {"row": 67, "column": 24}, "end_point": {"row": 67, "column": 28}}, {"id": 81, "type": "pointer_declarator", "text": "* data", "parent": 79, "children": [82, 83], "start_point": {"row": 67, "column": 29}, "end_point": {"row": 67, "column": 35}}, {"id": 82, "type": "*", "text": "*", "parent": 81, "children": [], "start_point": {"row": 67, "column": 29}, "end_point": {"row": 67, "column": 30}}, {"id": 83, "type": "identifier", "text": "data", "parent": 81, "children": [], "start_point": {"row": 67, "column": 31}, "end_point": {"row": 67, "column": 35}}, {"id": 84, "type": "declaration", "text": "void selectObjAFunc(void * data);", "parent": 35, "children": [85, 86], "start_point": {"row": 68, "column": 2}, "end_point": {"row": 68, "column": 35}}, {"id": 85, "type": "primitive_type", "text": "void", "parent": 84, "children": [], "start_point": {"row": 68, "column": 2}, "end_point": {"row": 68, "column": 6}}, {"id": 86, "type": "function_declarator", "text": "selectObjAFunc(void * data)", "parent": 84, "children": [87, 88], "start_point": {"row": 68, "column": 7}, "end_point": {"row": 68, "column": 34}}, {"id": 87, "type": "identifier", "text": "selectObjAFunc", "parent": 86, "children": [], "start_point": {"row": 68, "column": 7}, "end_point": {"row": 68, "column": 21}}, {"id": 88, "type": "parameter_list", "text": "(void * data)", "parent": 86, "children": [89], "start_point": {"row": 68, "column": 21}, "end_point": {"row": 68, "column": 34}}, {"id": 89, "type": "parameter_declaration", "text": "void * data", "parent": 88, "children": [90, 91], "start_point": {"row": 68, "column": 22}, "end_point": {"row": 68, "column": 33}}, {"id": 90, "type": "primitive_type", "text": "void", "parent": 89, "children": [], "start_point": {"row": 68, "column": 22}, "end_point": {"row": 68, "column": 26}}, {"id": 91, "type": "pointer_declarator", "text": "* data", "parent": 89, "children": [92, 93], "start_point": {"row": 68, "column": 27}, "end_point": {"row": 68, "column": 33}}, {"id": 92, "type": "*", "text": "*", "parent": 91, "children": [], "start_point": {"row": 68, "column": 27}, "end_point": {"row": 68, "column": 28}}, {"id": 93, "type": "identifier", "text": "data", "parent": 91, "children": [], "start_point": {"row": 68, "column": 29}, "end_point": {"row": 68, "column": 33}}, {"id": 94, "type": "declaration", "text": "void selectObjBFunc(void * data);", "parent": 35, "children": [95, 96], "start_point": {"row": 69, "column": 2}, "end_point": {"row": 69, "column": 35}}, {"id": 95, "type": "primitive_type", "text": "void", "parent": 94, "children": [], "start_point": {"row": 69, "column": 2}, "end_point": {"row": 69, "column": 6}}, {"id": 96, "type": "function_declarator", "text": "selectObjBFunc(void * data)", "parent": 94, "children": [97, 98], "start_point": {"row": 69, "column": 7}, "end_point": {"row": 69, "column": 34}}, {"id": 97, "type": "identifier", "text": "selectObjBFunc", "parent": 96, "children": [], "start_point": {"row": 69, "column": 7}, "end_point": {"row": 69, "column": 21}}, {"id": 98, "type": "parameter_list", "text": "(void * data)", "parent": 96, "children": [99], "start_point": {"row": 69, "column": 21}, "end_point": {"row": 69, "column": 34}}, {"id": 99, "type": "parameter_declaration", "text": "void * data", "parent": 98, "children": [100, 101], "start_point": {"row": 69, "column": 22}, "end_point": {"row": 69, "column": 33}}, {"id": 100, "type": "primitive_type", "text": "void", "parent": 99, "children": [], "start_point": {"row": 69, "column": 22}, "end_point": {"row": 69, "column": 26}}, {"id": 101, "type": "pointer_declarator", "text": "* data", "parent": 99, "children": [102, 103], "start_point": {"row": 69, "column": 27}, "end_point": {"row": 69, "column": 33}}, {"id": 102, "type": "*", "text": "*", "parent": 101, "children": [], "start_point": {"row": 69, "column": 27}, "end_point": {"row": 69, "column": 28}}, {"id": 103, "type": "identifier", "text": "data", "parent": 101, "children": [], "start_point": {"row": 69, "column": 29}, "end_point": {"row": 69, "column": 33}}, {"id": 104, "type": "declaration", "text": "CATBoolean ActionOK(void * data);", "parent": 35, "children": [105, 106], "start_point": {"row": 70, "column": 2}, "end_point": {"row": 70, "column": 35}}, {"id": 105, "type": "type_identifier", "text": "CATBoolean", "parent": 104, "children": [], "start_point": {"row": 70, "column": 2}, "end_point": {"row": 70, "column": 12}}, {"id": 106, "type": "function_declarator", "text": "ActionOK(void * data)", "parent": 104, "children": [107, 108], "start_point": {"row": 70, "column": 13}, "end_point": {"row": 70, "column": 34}}, {"id": 107, "type": "identifier", "text": "ActionOK", "parent": 106, "children": [], "start_point": {"row": 70, "column": 13}, "end_point": {"row": 70, "column": 21}}, {"id": 108, "type": "parameter_list", "text": "(void * data)", "parent": 106, "children": [109], "start_point": {"row": 70, "column": 21}, "end_point": {"row": 70, "column": 34}}, {"id": 109, "type": "parameter_declaration", "text": "void * data", "parent": 108, "children": [110, 111], "start_point": {"row": 70, "column": 22}, "end_point": {"row": 70, "column": 33}}, {"id": 110, "type": "primitive_type", "text": "void", "parent": 109, "children": [], "start_point": {"row": 70, "column": 22}, "end_point": {"row": 70, "column": 26}}, {"id": 111, "type": "pointer_declarator", "text": "* data", "parent": 109, "children": [112, 113], "start_point": {"row": 70, "column": 27}, "end_point": {"row": 70, "column": 33}}, {"id": 112, "type": "*", "text": "*", "parent": 111, "children": [], "start_point": {"row": 70, "column": 27}, "end_point": {"row": 70, "column": 28}}, {"id": 113, "type": "identifier", "text": "data", "parent": 111, "children": [], "start_point": {"row": 70, "column": 29}, "end_point": {"row": 70, "column": 33}}, {"id": 114, "type": "declaration", "text": "void TransToSelectA(void * data);", "parent": 35, "children": [115, 116], "start_point": {"row": 71, "column": 2}, "end_point": {"row": 71, "column": 35}}, {"id": 115, "type": "primitive_type", "text": "void", "parent": 114, "children": [], "start_point": {"row": 71, "column": 2}, "end_point": {"row": 71, "column": 6}}, {"id": 116, "type": "function_declarator", "text": "TransToSelectA(void * data)", "parent": 114, "children": [117, 118], "start_point": {"row": 71, "column": 7}, "end_point": {"row": 71, "column": 34}}, {"id": 117, "type": "identifier", "text": "TransToSelectA", "parent": 116, "children": [], "start_point": {"row": 71, "column": 7}, "end_point": {"row": 71, "column": 21}}, {"id": 118, "type": "parameter_list", "text": "(void * data)", "parent": 116, "children": [119], "start_point": {"row": 71, "column": 21}, "end_point": {"row": 71, "column": 34}}, {"id": 119, "type": "parameter_declaration", "text": "void * data", "parent": 118, "children": [120, 121], "start_point": {"row": 71, "column": 22}, "end_point": {"row": 71, "column": 33}}, {"id": 120, "type": "primitive_type", "text": "void", "parent": 119, "children": [], "start_point": {"row": 71, "column": 22}, "end_point": {"row": 71, "column": 26}}, {"id": 121, "type": "pointer_declarator", "text": "* data", "parent": 119, "children": [122, 123], "start_point": {"row": 71, "column": 27}, "end_point": {"row": 71, "column": 33}}, {"id": 122, "type": "*", "text": "*", "parent": 121, "children": [], "start_point": {"row": 71, "column": 27}, "end_point": {"row": 71, "column": 28}}, {"id": 123, "type": "identifier", "text": "data", "parent": 121, "children": [], "start_point": {"row": 71, "column": 29}, "end_point": {"row": 71, "column": 33}}, {"id": 124, "type": "declaration", "text": "void TransToSelectB(void * data);", "parent": 35, "children": [125, 126], "start_point": {"row": 72, "column": 2}, "end_point": {"row": 72, "column": 35}}, {"id": 125, "type": "primitive_type", "text": "void", "parent": 124, "children": [], "start_point": {"row": 72, "column": 2}, "end_point": {"row": 72, "column": 6}}, {"id": 126, "type": "function_declarator", "text": "TransToSelectB(void * data)", "parent": 124, "children": [127, 128], "start_point": {"row": 72, "column": 7}, "end_point": {"row": 72, "column": 34}}, {"id": 127, "type": "identifier", "text": "TransToSelectB", "parent": 126, "children": [], "start_point": {"row": 72, "column": 7}, "end_point": {"row": 72, "column": 21}}, {"id": 128, "type": "parameter_list", "text": "(void * data)", "parent": 126, "children": [129], "start_point": {"row": 72, "column": 21}, "end_point": {"row": 72, "column": 34}}, {"id": 129, "type": "parameter_declaration", "text": "void * data", "parent": 128, "children": [130, 131], "start_point": {"row": 72, "column": 22}, "end_point": {"row": 72, "column": 33}}, {"id": 130, "type": "primitive_type", "text": "void", "parent": 129, "children": [], "start_point": {"row": 72, "column": 22}, "end_point": {"row": 72, "column": 26}}, {"id": 131, "type": "pointer_declarator", "text": "* data", "parent": 129, "children": [132, 133], "start_point": {"row": 72, "column": 27}, "end_point": {"row": 72, "column": 33}}, {"id": 132, "type": "*", "text": "*", "parent": 131, "children": [], "start_point": {"row": 72, "column": 27}, "end_point": {"row": 72, "column": 28}}, {"id": 133, "type": "identifier", "text": "data", "parent": 131, "children": [], "start_point": {"row": 72, "column": 29}, "end_point": {"row": 72, "column": 33}}, {"id": 134, "type": "declaration", "text": "HRESULT GetMinDistanceByMeasure(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance);", "parent": 35, "children": [135, 136], "start_point": {"row": 73, "column": 2}, "end_point": {"row": 73, "column": 209}}, {"id": 135, "type": "type_identifier", "text": "HRESULT", "parent": 134, "children": [], "start_point": {"row": 73, "column": 2}, "end_point": {"row": 73, "column": 9}}, {"id": 136, "type": "function_declarator", "text": "GetMinDistanceByMeasure(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance)", "parent": 134, "children": [137, 138], "start_point": {"row": 73, "column": 10}, "end_point": {"row": 73, "column": 208}}, {"id": 137, "type": "identifier", "text": "GetMinDistanceByMeasure", "parent": 136, "children": [], "start_point": {"row": 73, "column": 10}, "end_point": {"row": 73, "column": 33}}, {"id": 138, "type": "parameter_list", "text": "(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance)", "parent": 136, "children": [139, 142, 145, 148, 151, 154, 157], "start_point": {"row": 73, "column": 33}, "end_point": {"row": 73, "column": 208}}, {"id": 139, "type": "parameter_declaration", "text": "CATISpecObject_var ispiSpec1", "parent": 138, "children": [140, 141], "start_point": {"row": 73, "column": 34}, "end_point": {"row": 73, "column": 62}}, {"id": 140, "type": "type_identifier", "text": "CATISpecObject_var", "parent": 139, "children": [], "start_point": {"row": 73, "column": 34}, "end_point": {"row": 73, "column": 52}}, {"id": 141, "type": "identifier", "text": "ispiSpec1", "parent": 139, "children": [], "start_point": {"row": 73, "column": 53}, "end_point": {"row": 73, "column": 62}}, {"id": 142, "type": "parameter_declaration", "text": "CATIProduct_var ispiProd1", "parent": 138, "children": [143, 144], "start_point": {"row": 73, "column": 63}, "end_point": {"row": 73, "column": 88}}, {"id": 143, "type": "type_identifier", "text": "CATIProduct_var", "parent": 142, "children": [], "start_point": {"row": 73, "column": 63}, "end_point": {"row": 73, "column": 78}}, {"id": 144, "type": "identifier", "text": "ispiProd1", "parent": 142, "children": [], "start_point": {"row": 73, "column": 79}, "end_point": {"row": 73, "column": 88}}, {"id": 145, "type": "parameter_declaration", "text": "CATISpecObject_var ispiSpec2", "parent": 138, "children": [146, 147], "start_point": {"row": 73, "column": 89}, "end_point": {"row": 73, "column": 117}}, {"id": 146, "type": "type_identifier", "text": "CATISpecObject_var", "parent": 145, "children": [], "start_point": {"row": 73, "column": 89}, "end_point": {"row": 73, "column": 107}}, {"id": 147, "type": "identifier", "text": "ispiSpec2", "parent": 145, "children": [], "start_point": {"row": 73, "column": 108}, "end_point": {"row": 73, "column": 117}}, {"id": 148, "type": "parameter_declaration", "text": "CATIProduct_var ispiProd2", "parent": 138, "children": [149, 150], "start_point": {"row": 73, "column": 118}, "end_point": {"row": 73, "column": 143}}, {"id": 149, "type": "type_identifier", "text": "CATIProduct_var", "parent": 148, "children": [], "start_point": {"row": 73, "column": 118}, "end_point": {"row": 73, "column": 133}}, {"id": 150, "type": "identifier", "text": "ispiProd2", "parent": 148, "children": [], "start_point": {"row": 73, "column": 134}, "end_point": {"row": 73, "column": 143}}, {"id": 151, "type": "parameter_declaration", "text": "CATMathPoint &omathPt1", "parent": 138, "children": [152, 153], "start_point": {"row": 73, "column": 144}, "end_point": {"row": 73, "column": 166}}, {"id": 152, "type": "type_identifier", "text": "CATMathPoint", "parent": 151, "children": [], "start_point": {"row": 73, "column": 144}, "end_point": {"row": 73, "column": 156}}, {"id": 153, "type": "identifier", "text": "omathPt1", "parent": 151, "children": [], "start_point": {"row": 73, "column": 158}, "end_point": {"row": 73, "column": 166}}, {"id": 154, "type": "parameter_declaration", "text": "CATMathPoint &omathPt2", "parent": 138, "children": [155, 156], "start_point": {"row": 73, "column": 167}, "end_point": {"row": 73, "column": 189}}, {"id": 155, "type": "type_identifier", "text": "CATMathPoint", "parent": 154, "children": [], "start_point": {"row": 73, "column": 167}, "end_point": {"row": 73, "column": 179}}, {"id": 156, "type": "identifier", "text": "omathPt2", "parent": 154, "children": [], "start_point": {"row": 73, "column": 181}, "end_point": {"row": 73, "column": 189}}, {"id": 157, "type": "parameter_declaration", "text": "double &oDistance", "parent": 138, "children": [158, 159], "start_point": {"row": 73, "column": 190}, "end_point": {"row": 73, "column": 207}}, {"id": 158, "type": "primitive_type", "text": "double", "parent": 157, "children": [], "start_point": {"row": 73, "column": 190}, "end_point": {"row": 73, "column": 196}}, {"id": 159, "type": "identifier", "text": "oDistance", "parent": 157, "children": [], "start_point": {"row": 73, "column": 198}, "end_point": {"row": 73, "column": 207}}, {"id": 160, "type": "declaration", "text": "CATMathTransformation GetMatrixTransformation( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo );", "parent": 35, "children": [161, 162], "start_point": {"row": 74, "column": 2}, "end_point": {"row": 74, "column": 110}}, {"id": 161, "type": "type_identifier", "text": "CATMathTransformation", "parent": 160, "children": [], "start_point": {"row": 74, "column": 2}, "end_point": {"row": 74, "column": 23}}, {"id": 162, "type": "function_declarator", "text": "GetMatrixTransformation( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo )", "parent": 160, "children": [163, 164], "start_point": {"row": 74, "column": 24}, "end_point": {"row": 74, "column": 109}}, {"id": 163, "type": "identifier", "text": "GetMatrixTransformation", "parent": 162, "children": [], "start_point": {"row": 74, "column": 24}, "end_point": {"row": 74, "column": 47}}, {"id": 164, "type": "parameter_list", "text": "( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo )", "parent": 162, "children": [165, 168], "start_point": {"row": 74, "column": 47}, "end_point": {"row": 74, "column": 109}}, {"id": 165, "type": "parameter_declaration", "text": "CATISpecObject_var spSpecOne", "parent": 164, "children": [166, 167], "start_point": {"row": 74, "column": 49}, "end_point": {"row": 74, "column": 77}}, {"id": 166, "type": "type_identifier", "text": "CATISpecObject_var", "parent": 165, "children": [], "start_point": {"row": 74, "column": 49}, "end_point": {"row": 74, "column": 67}}, {"id": 167, "type": "identifier", "text": "spSpecOne", "parent": 165, "children": [], "start_point": {"row": 74, "column": 68}, "end_point": {"row": 74, "column": 77}}, {"id": 168, "type": "parameter_declaration", "text": "CATISpecObject_var spSpecTwo", "parent": 164, "children": [169, 170], "start_point": {"row": 74, "column": 79}, "end_point": {"row": 74, "column": 107}}, {"id": 169, "type": "type_identifier", "text": "CATISpecObject_var", "parent": 168, "children": [], "start_point": {"row": 74, "column": 79}, "end_point": {"row": 74, "column": 97}}, {"id": 170, "type": "identifier", "text": "spSpecTwo", "parent": 168, "children": [], "start_point": {"row": 74, "column": 98}, "end_point": {"row": 74, "column": 107}}, {"id": 171, "type": "declaration", "text": "CATMathTransformation GetAbsTransformation( CATISpecObject_var ispSpecOne );", "parent": 35, "children": [172, 173], "start_point": {"row": 75, "column": 2}, "end_point": {"row": 75, "column": 78}}, {"id": 172, "type": "type_identifier", "text": "CATMathTransformation", "parent": 171, "children": [], "start_point": {"row": 75, "column": 2}, "end_point": {"row": 75, "column": 23}}, {"id": 173, "type": "function_declarator", "text": "GetAbsTransformation( CATISpecObject_var ispSpecOne )", "parent": 171, "children": [174, 175], "start_point": {"row": 75, "column": 24}, "end_point": {"row": 75, "column": 77}}, {"id": 174, "type": "identifier", "text": "GetAbsTransformation", "parent": 173, "children": [], "start_point": {"row": 75, "column": 24}, "end_point": {"row": 75, "column": 44}}, {"id": 175, "type": "parameter_list", "text": "( CATISpecObject_var ispSpecOne )", "parent": 173, "children": [176], "start_point": {"row": 75, "column": 44}, "end_point": {"row": 75, "column": 77}}, {"id": 176, "type": "parameter_declaration", "text": "CATISpecObject_var ispSpecOne", "parent": 175, "children": [177, 178], "start_point": {"row": 75, "column": 46}, "end_point": {"row": 75, "column": 75}}, {"id": 177, "type": "type_identifier", "text": "CATISpecObject_var", "parent": 176, "children": [], "start_point": {"row": 75, "column": 46}, "end_point": {"row": 75, "column": 64}}, {"id": 178, "type": "identifier", "text": "ispSpecOne", "parent": 176, "children": [], "start_point": {"row": 75, "column": 65}, "end_point": {"row": 75, "column": 75}}, {"id": 179, "type": "declaration", "text": "HRESULT CheckClash(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2);", "parent": 35, "children": [180, 181], "start_point": {"row": 76, "column": 2}, "end_point": {"row": 76, "column": 72}}, {"id": 180, "type": "type_identifier", "text": "HRESULT", "parent": 179, "children": [], "start_point": {"row": 76, "column": 2}, "end_point": {"row": 76, "column": 9}}, {"id": 181, "type": "function_declarator", "text": "CheckClash(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2)", "parent": 179, "children": [182, 183], "start_point": {"row": 76, "column": 10}, "end_point": {"row": 76, "column": 71}}, {"id": 182, "type": "identifier", "text": "CheckClash", "parent": 181, "children": [], "start_point": {"row": 76, "column": 10}, "end_point": {"row": 76, "column": 20}}, {"id": 183, "type": "parameter_list", "text": "(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2)", "parent": 181, "children": [184, 187], "start_point": {"row": 76, "column": 20}, "end_point": {"row": 76, "column": 71}}, {"id": 184, "type": "parameter_declaration", "text": "CATIProduct_var ispiPrd1", "parent": 183, "children": [185, 186], "start_point": {"row": 76, "column": 21}, "end_point": {"row": 76, "column": 45}}, {"id": 185, "type": "type_identifier", "text": "CATIProduct_var", "parent": 184, "children": [], "start_point": {"row": 76, "column": 21}, "end_point": {"row": 76, "column": 36}}, {"id": 186, "type": "identifier", "text": "ispiPrd1", "parent": 184, "children": [], "start_point": {"row": 76, "column": 37}, "end_point": {"row": 76, "column": 45}}, {"id": 187, "type": "parameter_declaration", "text": "CATIProduct_var ispiPrd2", "parent": 183, "children": [188, 189], "start_point": {"row": 76, "column": 46}, "end_point": {"row": 76, "column": 70}}, {"id": 188, "type": "type_identifier", "text": "CATIProduct_var", "parent": 187, "children": [], "start_point": {"row": 76, "column": 46}, "end_point": {"row": 76, "column": 61}}, {"id": 189, "type": "identifier", "text": "ispiPrd2", "parent": 187, "children": [], "start_point": {"row": 76, "column": 62}, "end_point": {"row": 76, "column": 70}}, {"id": 190, "type": "declaration", "text": "CATBoolean ActionOK2(void * data);", "parent": 35, "children": [191, 192], "start_point": {"row": 77, "column": 2}, "end_point": {"row": 77, "column": 36}}, {"id": 191, "type": "type_identifier", "text": "CATBoolean", "parent": 190, "children": [], "start_point": {"row": 77, "column": 2}, "end_point": {"row": 77, "column": 12}}, {"id": 192, "type": "function_declarator", "text": "ActionOK2(void * data)", "parent": 190, "children": [193, 194], "start_point": {"row": 77, "column": 13}, "end_point": {"row": 77, "column": 35}}, {"id": 193, "type": "identifier", "text": "ActionOK2", "parent": 192, "children": [], "start_point": {"row": 77, "column": 13}, "end_point": {"row": 77, "column": 22}}, {"id": 194, "type": "parameter_list", "text": "(void * data)", "parent": 192, "children": [195], "start_point": {"row": 77, "column": 22}, "end_point": {"row": 77, "column": 35}}, {"id": 195, "type": "parameter_declaration", "text": "void * data", "parent": 194, "children": [196, 197], "start_point": {"row": 77, "column": 23}, "end_point": {"row": 77, "column": 34}}, {"id": 196, "type": "primitive_type", "text": "void", "parent": 195, "children": [], "start_point": {"row": 77, "column": 23}, "end_point": {"row": 77, "column": 27}}, {"id": 197, "type": "pointer_declarator", "text": "* data", "parent": 195, "children": [198, 199], "start_point": {"row": 77, "column": 28}, "end_point": {"row": 77, "column": 34}}, {"id": 198, "type": "*", "text": "*", "parent": 197, "children": [], "start_point": {"row": 77, "column": 28}, "end_point": {"row": 77, "column": 29}}, {"id": 199, "type": "identifier", "text": "data", "parent": 197, "children": [], "start_point": {"row": 77, "column": 30}, "end_point": {"row": 77, "column": 34}}, {"id": 200, "type": "declaration", "text": "HRESULT MeasureByDichotomy(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir);", "parent": 35, "children": [201, 202], "start_point": {"row": 78, "column": 2}, "end_point": {"row": 78, "column": 117}}, {"id": 201, "type": "type_identifier", "text": "HRESULT", "parent": 200, "children": [], "start_point": {"row": 78, "column": 2}, "end_point": {"row": 78, "column": 9}}, {"id": 202, "type": "function_declarator", "text": "MeasureByDichotomy(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir)", "parent": 200, "children": [203, 204], "start_point": {"row": 78, "column": 10}, "end_point": {"row": 78, "column": 116}}, {"id": 203, "type": "identifier", "text": "MeasureByDichotomy", "parent": 202, "children": [], "start_point": {"row": 78, "column": 10}, "end_point": {"row": 78, "column": 28}}, {"id": 204, "type": "parameter_list", "text": "(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir)", "parent": 202, "children": [205, 212, 219], "start_point": {"row": 78, "column": 28}, "end_point": {"row": 78, "column": 116}}, {"id": 205, "type": "parameter_declaration", "text": "vector<CATIProduct_var> ilstProdA", "parent": 204, "children": [206, 207, 211], "start_point": {"row": 78, "column": 29}, "end_point": {"row": 78, "column": 62}}, {"id": 206, "type": "type_identifier", "text": "vector", "parent": 205, "children": [], "start_point": {"row": 78, "column": 29}, "end_point": {"row": 78, "column": 35}}, {"id": 207, "type": "ERROR", "text": "<CATIProduct_var>", "parent": 205, "children": [208, 209, 210], "start_point": {"row": 78, "column": 35}, "end_point": {"row": 78, "column": 52}}, {"id": 208, "type": "<", "text": "<", "parent": 207, "children": [], "start_point": {"row": 78, "column": 35}, "end_point": {"row": 78, "column": 36}}, {"id": 209, "type": "identifier", "text": "CATIProduct_var", "parent": 207, "children": [], "start_point": {"row": 78, "column": 36}, "end_point": {"row": 78, "column": 51}}, {"id": 210, "type": ">", "text": ">", "parent": 207, "children": [], "start_point": {"row": 78, "column": 51}, "end_point": {"row": 78, "column": 52}}, {"id": 211, "type": "identifier", "text": "ilstProdA", "parent": 205, "children": [], "start_point": {"row": 78, "column": 53}, "end_point": {"row": 78, "column": 62}}, {"id": 212, "type": "parameter_declaration", "text": "vector<CATIProduct_var> ilstProdB", "parent": 204, "children": [213, 214, 218], "start_point": {"row": 78, "column": 63}, "end_point": {"row": 78, "column": 96}}, {"id": 213, "type": "type_identifier", "text": "vector", "parent": 212, "children": [], "start_point": {"row": 78, "column": 63}, "end_point": {"row": 78, "column": 69}}, {"id": 214, "type": "ERROR", "text": "<CATIProduct_var>", "parent": 212, "children": [215, 216, 217], "start_point": {"row": 78, "column": 69}, "end_point": {"row": 78, "column": 86}}, {"id": 215, "type": "<", "text": "<", "parent": 214, "children": [], "start_point": {"row": 78, "column": 69}, "end_point": {"row": 78, "column": 70}}, {"id": 216, "type": "identifier", "text": "CATIProduct_var", "parent": 214, "children": [], "start_point": {"row": 78, "column": 70}, "end_point": {"row": 78, "column": 85}}, {"id": 217, "type": ">", "text": ">", "parent": 214, "children": [], "start_point": {"row": 78, "column": 85}, "end_point": {"row": 78, "column": 86}}, {"id": 218, "type": "identifier", "text": "ilstProdB", "parent": 212, "children": [], "start_point": {"row": 78, "column": 87}, "end_point": {"row": 78, "column": 96}}, {"id": 219, "type": "parameter_declaration", "text": "CATMathVector iDir", "parent": 204, "children": [220, 221], "start_point": {"row": 78, "column": 97}, "end_point": {"row": 78, "column": 115}}, {"id": 220, "type": "type_identifier", "text": "CATMathVector", "parent": 219, "children": [], "start_point": {"row": 78, "column": 97}, "end_point": {"row": 78, "column": 110}}, {"id": 221, "type": "identifier", "text": "iDir", "parent": 219, "children": [], "start_point": {"row": 78, "column": 111}, "end_point": {"row": 78, "column": 115}}, {"id": 222, "type": "declaration", "text": "HRESULT MeasureMinDistAmongProducts(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance);", "parent": 35, "children": [223, 224], "start_point": {"row": 79, "column": 2}, "end_point": {"row": 79, "column": 164}}, {"id": 223, "type": "type_identifier", "text": "HRESULT", "parent": 222, "children": [], "start_point": {"row": 79, "column": 2}, "end_point": {"row": 79, "column": 9}}, {"id": 224, "type": "function_declarator", "text": "MeasureMinDistAmongProducts(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance)", "parent": 222, "children": [225, 226], "start_point": {"row": 79, "column": 10}, "end_point": {"row": 79, "column": 163}}, {"id": 225, "type": "identifier", "text": "MeasureMinDistAmongProducts", "parent": 224, "children": [], "start_point": {"row": 79, "column": 10}, "end_point": {"row": 79, "column": 37}}, {"id": 226, "type": "parameter_list", "text": "(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance)", "parent": 224, "children": [227, 234, 241, 244, 247], "start_point": {"row": 79, "column": 37}, "end_point": {"row": 79, "column": 163}}, {"id": 227, "type": "parameter_declaration", "text": "vector<CATIProduct_var> ilstProdA", "parent": 226, "children": [228, 229, 233], "start_point": {"row": 79, "column": 38}, "end_point": {"row": 79, "column": 71}}, {"id": 228, "type": "type_identifier", "text": "vector", "parent": 227, "children": [], "start_point": {"row": 79, "column": 38}, "end_point": {"row": 79, "column": 44}}, {"id": 229, "type": "ERROR", "text": "<CATIProduct_var>", "parent": 227, "children": [230, 231, 232], "start_point": {"row": 79, "column": 44}, "end_point": {"row": 79, "column": 61}}, {"id": 230, "type": "<", "text": "<", "parent": 229, "children": [], "start_point": {"row": 79, "column": 44}, "end_point": {"row": 79, "column": 45}}, {"id": 231, "type": "identifier", "text": "CATIProduct_var", "parent": 229, "children": [], "start_point": {"row": 79, "column": 45}, "end_point": {"row": 79, "column": 60}}, {"id": 232, "type": ">", "text": ">", "parent": 229, "children": [], "start_point": {"row": 79, "column": 60}, "end_point": {"row": 79, "column": 61}}, {"id": 233, "type": "identifier", "text": "ilstProdA", "parent": 227, "children": [], "start_point": {"row": 79, "column": 62}, "end_point": {"row": 79, "column": 71}}, {"id": 234, "type": "parameter_declaration", "text": "vector<CATIProduct_var> ilstProdB", "parent": 226, "children": [235, 236, 240], "start_point": {"row": 79, "column": 72}, "end_point": {"row": 79, "column": 105}}, {"id": 235, "type": "type_identifier", "text": "vector", "parent": 234, "children": [], "start_point": {"row": 79, "column": 72}, "end_point": {"row": 79, "column": 78}}, {"id": 236, "type": "ERROR", "text": "<CATIProduct_var>", "parent": 234, "children": [237, 238, 239], "start_point": {"row": 79, "column": 78}, "end_point": {"row": 79, "column": 95}}, {"id": 237, "type": "<", "text": "<", "parent": 236, "children": [], "start_point": {"row": 79, "column": 78}, "end_point": {"row": 79, "column": 79}}, {"id": 238, "type": "identifier", "text": "CATIProduct_var", "parent": 236, "children": [], "start_point": {"row": 79, "column": 79}, "end_point": {"row": 79, "column": 94}}, {"id": 239, "type": ">", "text": ">", "parent": 236, "children": [], "start_point": {"row": 79, "column": 94}, "end_point": {"row": 79, "column": 95}}, {"id": 240, "type": "identifier", "text": "ilstProdB", "parent": 234, "children": [], "start_point": {"row": 79, "column": 96}, "end_point": {"row": 79, "column": 105}}, {"id": 241, "type": "parameter_declaration", "text": "CATMathPoint &oPtA", "parent": 226, "children": [242, 243], "start_point": {"row": 79, "column": 106}, "end_point": {"row": 79, "column": 124}}, {"id": 242, "type": "type_identifier", "text": "CATMathPoint", "parent": 241, "children": [], "start_point": {"row": 79, "column": 106}, "end_point": {"row": 79, "column": 118}}, {"id": 243, "type": "identifier", "text": "oPtA", "parent": 241, "children": [], "start_point": {"row": 79, "column": 120}, "end_point": {"row": 79, "column": 124}}, {"id": 244, "type": "parameter_declaration", "text": "CATMathPoint &oPtB", "parent": 226, "children": [245, 246], "start_point": {"row": 79, "column": 125}, "end_point": {"row": 79, "column": 143}}, {"id": 245, "type": "type_identifier", "text": "CATMathPoint", "parent": 244, "children": [], "start_point": {"row": 79, "column": 125}, "end_point": {"row": 79, "column": 137}}, {"id": 246, "type": "identifier", "text": "oPtB", "parent": 244, "children": [], "start_point": {"row": 79, "column": 139}, "end_point": {"row": 79, "column": 143}}, {"id": 247, "type": "parameter_declaration", "text": "double &odDistance", "parent": 226, "children": [248, 249], "start_point": {"row": 79, "column": 144}, "end_point": {"row": 79, "column": 162}}, {"id": 248, "type": "primitive_type", "text": "double", "parent": 247, "children": [], "start_point": {"row": 79, "column": 144}, "end_point": {"row": 79, "column": 150}}, {"id": 249, "type": "identifier", "text": "odDistance", "parent": 247, "children": [], "start_point": {"row": 79, "column": 152}, "end_point": {"row": 79, "column": 162}}, {"id": 250, "type": "declaration", "text": "CATBoolean ActionOK3(void * data);", "parent": 35, "children": [251, 252], "start_point": {"row": 80, "column": 2}, "end_point": {"row": 80, "column": 36}}, {"id": 251, "type": "type_identifier", "text": "CATBoolean", "parent": 250, "children": [], "start_point": {"row": 80, "column": 2}, "end_point": {"row": 80, "column": 12}}, {"id": 252, "type": "function_declarator", "text": "ActionOK3(void * data)", "parent": 250, "children": [253, 254], "start_point": {"row": 80, "column": 13}, "end_point": {"row": 80, "column": 35}}, {"id": 253, "type": "identifier", "text": "ActionOK3", "parent": 252, "children": [], "start_point": {"row": 80, "column": 13}, "end_point": {"row": 80, "column": 22}}, {"id": 254, "type": "parameter_list", "text": "(void * data)", "parent": 252, "children": [255], "start_point": {"row": 80, "column": 22}, "end_point": {"row": 80, "column": 35}}, {"id": 255, "type": "parameter_declaration", "text": "void * data", "parent": 254, "children": [256, 257], "start_point": {"row": 80, "column": 23}, "end_point": {"row": 80, "column": 34}}, {"id": 256, "type": "primitive_type", "text": "void", "parent": 255, "children": [], "start_point": {"row": 80, "column": 23}, "end_point": {"row": 80, "column": 27}}, {"id": 257, "type": "pointer_declarator", "text": "* data", "parent": 255, "children": [258, 259], "start_point": {"row": 80, "column": 28}, "end_point": {"row": 80, "column": 34}}, {"id": 258, "type": "*", "text": "*", "parent": 257, "children": [], "start_point": {"row": 80, "column": 28}, "end_point": {"row": 80, "column": 29}}, {"id": 259, "type": "identifier", "text": "data", "parent": 257, "children": [], "start_point": {"row": 80, "column": 30}, "end_point": {"row": 80, "column": 34}}, {"id": 260, "type": "labeled_statement", "text": "private:\n\n\t TestMeasurementDlg\t\t*_pDlg;", "parent": 35, "children": [261], "start_point": {"row": 81, "column": 0}, "end_point": {"row": 83, "column": 30}}, {"id": 261, "type": "declaration", "text": "TestMeasurementDlg\t\t*_pDlg;", "parent": 260, "children": [262, 263], "start_point": {"row": 83, "column": 3}, "end_point": {"row": 83, "column": 30}}, {"id": 262, "type": "type_identifier", "text": "TestMeasurementDlg", "parent": 261, "children": [], "start_point": {"row": 83, "column": 3}, "end_point": {"row": 83, "column": 21}}, {"id": 263, "type": "pointer_declarator", "text": "*_pDlg", "parent": 261, "children": [264, 265], "start_point": {"row": 83, "column": 23}, "end_point": {"row": 83, "column": 29}}, {"id": 264, "type": "*", "text": "*", "parent": 263, "children": [], "start_point": {"row": 83, "column": 23}, "end_point": {"row": 83, "column": 24}}, {"id": 265, "type": "identifier", "text": "_pDlg", "parent": 263, "children": [], "start_point": {"row": 83, "column": 24}, "end_point": {"row": 83, "column": 29}}, {"id": 266, "type": "declaration", "text": "CATFrmEditor\t\t\t*_pEditor;", "parent": 35, "children": [267, 268], "start_point": {"row": 85, "column": 3}, "end_point": {"row": 85, "column": 28}}, {"id": 267, "type": "type_identifier", "text": "CATFrmEditor", "parent": 266, "children": [], "start_point": {"row": 85, "column": 3}, "end_point": {"row": 85, "column": 15}}, {"id": 268, "type": "pointer_declarator", "text": "*_pEditor", "parent": 266, "children": [269, 270], "start_point": {"row": 85, "column": 18}, "end_point": {"row": 85, "column": 27}}, {"id": 269, "type": "*", "text": "*", "parent": 268, "children": [], "start_point": {"row": 85, "column": 18}, "end_point": {"row": 85, "column": 19}}, {"id": 270, "type": "identifier", "text": "_pEditor", "parent": 268, "children": [], "start_point": {"row": 85, "column": 19}, "end_point": {"row": 85, "column": 27}}, {"id": 271, "type": "declaration", "text": "CATHSO\t\t\t\t*_pHSO;", "parent": 35, "children": [272, 273], "start_point": {"row": 87, "column": 3}, "end_point": {"row": 87, "column": 20}}, {"id": 272, "type": "type_identifier", "text": "CATHSO", "parent": 271, "children": [], "start_point": {"row": 87, "column": 3}, "end_point": {"row": 87, "column": 9}}, {"id": 273, "type": "pointer_declarator", "text": "*_pHSO", "parent": 271, "children": [274, 275], "start_point": {"row": 87, "column": 13}, "end_point": {"row": 87, "column": 19}}, {"id": 274, "type": "*", "text": "*", "parent": 273, "children": [], "start_point": {"row": 87, "column": 13}, "end_point": {"row": 87, "column": 14}}, {"id": 275, "type": "identifier", "text": "_pHSO", "parent": 273, "children": [], "start_point": {"row": 87, "column": 14}, "end_point": {"row": 87, "column": 19}}, {"id": 276, "type": "declaration", "text": "GeneralClass\t\t\t*_pGeneralCls;", "parent": 35, "children": [277, 278], "start_point": {"row": 89, "column": 3}, "end_point": {"row": 89, "column": 32}}, {"id": 277, "type": "type_identifier", "text": "GeneralClass", "parent": 276, "children": [], "start_point": {"row": 89, "column": 3}, "end_point": {"row": 89, "column": 15}}, {"id": 278, "type": "pointer_declarator", "text": "*_pGeneralCls", "parent": 276, "children": [279, 280], "start_point": {"row": 89, "column": 18}, "end_point": {"row": 89, "column": 31}}, {"id": 279, "type": "*", "text": "*", "parent": 278, "children": [], "start_point": {"row": 89, "column": 18}, "end_point": {"row": 89, "column": 19}}, {"id": 280, "type": "identifier", "text": "_pGeneralCls", "parent": 278, "children": [], "start_point": {"row": 89, "column": 19}, "end_point": {"row": 89, "column": 31}}, {"id": 281, "type": "declaration", "text": "CATFeatureImportAgent * _pSelAAgent;", "parent": 35, "children": [282, 283], "start_point": {"row": 91, "column": 3}, "end_point": {"row": 91, "column": 39}}, {"id": 282, "type": "type_identifier", "text": "CATFeatureImportAgent", "parent": 281, "children": [], "start_point": {"row": 91, "column": 3}, "end_point": {"row": 91, "column": 24}}, {"id": 283, "type": "pointer_declarator", "text": "* _pSelAAgent", "parent": 281, "children": [284, 285], "start_point": {"row": 91, "column": 25}, "end_point": {"row": 91, "column": 38}}, {"id": 284, "type": "*", "text": "*", "parent": 283, "children": [], "start_point": {"row": 91, "column": 25}, "end_point": {"row": 91, "column": 26}}, {"id": 285, "type": "identifier", "text": "_pSelAAgent", "parent": 283, "children": [], "start_point": {"row": 91, "column": 27}, "end_point": {"row": 91, "column": 38}}, {"id": 286, "type": "declaration", "text": "CATFeatureImportAgent * _pSelBAgent;", "parent": 35, "children": [287, 288], "start_point": {"row": 93, "column": 3}, "end_point": {"row": 93, "column": 39}}, {"id": 287, "type": "type_identifier", "text": "CATFeatureImportAgent", "parent": 286, "children": [], "start_point": {"row": 93, "column": 3}, "end_point": {"row": 93, "column": 24}}, {"id": 288, "type": "pointer_declarator", "text": "* _pSelBAgent", "parent": 286, "children": [289, 290], "start_point": {"row": 93, "column": 25}, "end_point": {"row": 93, "column": 38}}, {"id": 289, "type": "*", "text": "*", "parent": 288, "children": [], "start_point": {"row": 93, "column": 25}, "end_point": {"row": 93, "column": 26}}, {"id": 290, "type": "identifier", "text": "_pSelBAgent", "parent": 288, "children": [], "start_point": {"row": 93, "column": 27}, "end_point": {"row": 93, "column": 38}}, {"id": 291, "type": "declaration", "text": "CATDialogAgent\t\t* _pSelAFieldAgent;", "parent": 35, "children": [292, 293], "start_point": {"row": 95, "column": 3}, "end_point": {"row": 95, "column": 38}}, {"id": 292, "type": "type_identifier", "text": "CATDialogAgent", "parent": 291, "children": [], "start_point": {"row": 95, "column": 3}, "end_point": {"row": 95, "column": 17}}, {"id": 293, "type": "pointer_declarator", "text": "* _pSelAFieldAgent", "parent": 291, "children": [294, 295], "start_point": {"row": 95, "column": 19}, "end_point": {"row": 95, "column": 37}}, {"id": 294, "type": "*", "text": "*", "parent": 293, "children": [], "start_point": {"row": 95, "column": 19}, "end_point": {"row": 95, "column": 20}}, {"id": 295, "type": "identifier", "text": "_pSelAFieldAgent", "parent": 293, "children": [], "start_point": {"row": 95, "column": 21}, "end_point": {"row": 95, "column": 37}}, {"id": 296, "type": "declaration", "text": "CATDialogAgent\t\t* _pSelBFieldAgent;", "parent": 35, "children": [297, 298], "start_point": {"row": 97, "column": 3}, "end_point": {"row": 97, "column": 38}}, {"id": 297, "type": "type_identifier", "text": "CATDialogAgent", "parent": 296, "children": [], "start_point": {"row": 97, "column": 3}, "end_point": {"row": 97, "column": 17}}, {"id": 298, "type": "pointer_declarator", "text": "* _pSelBFieldAgent", "parent": 296, "children": [299, 300], "start_point": {"row": 97, "column": 19}, "end_point": {"row": 97, "column": 37}}, {"id": 299, "type": "*", "text": "*", "parent": 298, "children": [], "start_point": {"row": 97, "column": 19}, "end_point": {"row": 97, "column": 20}}, {"id": 300, "type": "identifier", "text": "_pSelBFieldAgent", "parent": 298, "children": [], "start_point": {"row": 97, "column": 21}, "end_point": {"row": 97, "column": 37}}, {"id": 301, "type": "declaration", "text": "CATBaseUnknown_var\t_spBUSelectA;", "parent": 35, "children": [302, 303], "start_point": {"row": 99, "column": 3}, "end_point": {"row": 99, "column": 35}}, {"id": 302, "type": "type_identifier", "text": "CATBaseUnknown_var", "parent": 301, "children": [], "start_point": {"row": 99, "column": 3}, "end_point": {"row": 99, "column": 21}}, {"id": 303, "type": "identifier", "text": "_spBUSelectA", "parent": 301, "children": [], "start_point": {"row": 99, "column": 22}, "end_point": {"row": 99, "column": 34}}, {"id": 304, "type": "declaration", "text": "CATBaseUnknown_var\t_spBUSelectB;", "parent": 35, "children": [305, 306], "start_point": {"row": 101, "column": 3}, "end_point": {"row": 101, "column": 35}}, {"id": 305, "type": "type_identifier", "text": "CATBaseUnknown_var", "parent": 304, "children": [], "start_point": {"row": 101, "column": 3}, "end_point": {"row": 101, "column": 21}}, {"id": 306, "type": "identifier", "text": "_spBUSelectB", "parent": 304, "children": [], "start_point": {"row": 101, "column": 22}, "end_point": {"row": 101, "column": 34}}, {"id": 307, "type": "declaration", "text": "CATIProduct_var\t\t_spiProdSelA;", "parent": 35, "children": [308, 309], "start_point": {"row": 103, "column": 3}, "end_point": {"row": 103, "column": 33}}, {"id": 308, "type": "type_identifier", "text": "CATIProduct_var", "parent": 307, "children": [], "start_point": {"row": 103, "column": 3}, "end_point": {"row": 103, "column": 18}}, {"id": 309, "type": "identifier", "text": "_spiProdSelA", "parent": 307, "children": [], "start_point": {"row": 103, "column": 20}, "end_point": {"row": 103, "column": 32}}, {"id": 310, "type": "declaration", "text": "CATIProduct_var\t\t_spiProdSelB;", "parent": 35, "children": [311, 312], "start_point": {"row": 105, "column": 3}, "end_point": {"row": 105, "column": 33}}, {"id": 311, "type": "type_identifier", "text": "CATIProduct_var", "parent": 310, "children": [], "start_point": {"row": 105, "column": 3}, "end_point": {"row": 105, "column": 18}}, {"id": 312, "type": "identifier", "text": "_spiProdSelB", "parent": 310, "children": [], "start_point": {"row": 105, "column": 20}, "end_point": {"row": 105, "column": 32}}, {"id": 313, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 111, "column": 0}, "end_point": {"row": 111, "column": 6}}]}, "node_categories": {"declarations": {"functions": [35, 52, 59, 66, 76, 86, 96, 106, 116, 126, 136, 162, 173, 181, 192, 202, 224, 252], "variables": [33, 48, 55, 62, 69, 74, 79, 84, 89, 94, 99, 104, 109, 114, 119, 124, 129, 134, 139, 142, 145, 148, 151, 154, 157, 160, 165, 168, 171, 176, 179, 184, 187, 190, 195, 200, 205, 212, 219, 222, 227, 234, 241, 244, 247, 250, 255, 261, 266, 271, 276, 281, 286, 291, 296, 301, 304, 307, 310], "classes": [], "imports": [6, 7, 9, 10, 12, 13, 15, 16, 18, 19, 21, 22, 24, 25, 27, 28, 30, 31], "modules": [], "enums": []}, "statements": {"expressions": [39, 45], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 34, 36, 38, 40, 42, 43, 46, 49, 53, 56, 58, 60, 63, 65, 67, 73, 75, 77, 83, 87, 93, 97, 103, 105, 107, 113, 117, 123, 127, 133, 135, 137, 140, 141, 143, 144, 146, 147, 149, 150, 152, 153, 155, 156, 159, 161, 163, 166, 167, 169, 170, 172, 174, 177, 178, 180, 182, 185, 186, 188, 189, 191, 193, 199, 201, 203, 206, 209, 211, 213, 216, 218, 220, 221, 223, 225, 228, 231, 233, 235, 238, 240, 242, 243, 245, 246, 249, 251, 253, 259, 262, 265, 267, 270, 272, 275, 277, 280, 282, 285, 287, 290, 292, 295, 297, 300, 302, 303, 305, 306, 308, 309, 311, 312, 313], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [8, 11, 14, 17, 20, 23, 26, 29, 32], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 35, "universal_type": "function", "name": "TestMeasurementCmd:", "text_snippet": "class TestMeasurementCmd: public CATStateCommand\n{\n // Allows customization/internationalization of"}, {"node_id": 52, "universal_type": "function", "name": "unknown", "text_snippet": "TestMeasurementCmd()"}, {"node_id": 59, "universal_type": "function", "name": "unknown", "text_snippet": "BuildGraph()"}, {"node_id": 66, "universal_type": "function", "name": "unknown", "text_snippet": "ActionOne(void * data)"}, {"node_id": 76, "universal_type": "function", "name": "unknown", "text_snippet": "ActionExit(void * data)"}, {"node_id": 86, "universal_type": "function", "name": "unknown", "text_snippet": "selectObjAFunc(void * data)"}, {"node_id": 96, "universal_type": "function", "name": "unknown", "text_snippet": "selectObjBFunc(void * data)"}, {"node_id": 106, "universal_type": "function", "name": "unknown", "text_snippet": "ActionOK(void * data)"}, {"node_id": 116, "universal_type": "function", "name": "unknown", "text_snippet": "TransToSelectA(void * data)"}, {"node_id": 126, "universal_type": "function", "name": "unknown", "text_snippet": "TransToSelectB(void * data)"}, {"node_id": 136, "universal_type": "function", "name": "unknown", "text_snippet": "GetMinDistanceByMeasure(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var is"}, {"node_id": 162, "universal_type": "function", "name": "unknown", "text_snippet": "GetMatrixTransformation( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo )"}, {"node_id": 173, "universal_type": "function", "name": "unknown", "text_snippet": "GetAbsTransformation( CATISpecObject_var ispSpecOne )"}, {"node_id": 181, "universal_type": "function", "name": "unknown", "text_snippet": "CheckClash(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2)"}, {"node_id": 192, "universal_type": "function", "name": "unknown", "text_snippet": "ActionOK2(void * data)"}, {"node_id": 202, "universal_type": "function", "name": "unknown", "text_snippet": "MeasureByDichotomy(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector"}, {"node_id": 224, "universal_type": "function", "name": "unknown", "text_snippet": "MeasureMinDistAmongProducts(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATM"}, {"node_id": 252, "universal_type": "function", "name": "unknown", "text_snippet": "ActionOK3(void * data)"}], "class_declarations": [], "import_statements": [{"node_id": 6, "text": "#include \"CATStateCommand.h\"\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include \"CATBoolean.h\"\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include \"TestMeasurementDlg.h\"\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include \"GeneralClass.h\"\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include \"CATIMeasurableInContext.h\"\n"}, {"node_id": 19, "text": "#include"}, {"node_id": 21, "text": "#include \"CATIClashFactory.h\"\n"}, {"node_id": 22, "text": "#include"}, {"node_id": 24, "text": "#include \"CATIClashResult.h\"\n"}, {"node_id": 25, "text": "#include"}, {"node_id": 27, "text": "#include \"CATIClash.h\"\n"}, {"node_id": 28, "text": "#include"}, {"node_id": 30, "text": "#include \"CATIConflict.h\"\n"}, {"node_id": 31, "text": "#include"}]}, "original_source_code": "// COPYRIGHT <NAME> 2020\n//===================================================================\n//\n// TestMeasurementCmd.h\n// The state chart based command: TestMeasurementCmd\n//\n//===================================================================\n//\n// Usage notes:\n//\n//===================================================================\n//CAA2 Wizard Generation Report\n// STATECOMMAND\n//End CAA2 Wizard Generation Report\n//\n// May 2020 Creation: Code generated by the CAA wizard Administrator\n//===================================================================\n#ifndef TestMeasurementCmd_H\n#define TestMeasurementCmd_H\n\n#include \"CATStateCommand.h\"\n#include \"CATBoolean.h\"\n\n#include \"TestMeasurementDlg.h\"\n#include \"GeneralClass.h\"\n\n#include \"CATIMeasurableInContext.h\"\n\n#include \"CATIClashFactory.h\"\n#include \"CATIClashResult.h\"\n#include \"CATIClash.h\"\n#include \"CATIConflict.h\"\n\nclass CATIndicationAgent;\n\n//----------------------------------------------------------------------\n\n/**\n * Describe your command here.\n * <p>\n * Using this prefered syntax will enable mkdoc to document your class.\n * <p>\n * refer to programming resources of Dialog engine framework.\n * (consult base class description).\n */\nclass TestMeasurementCmd: public CATStateCommand\n{\n // Allows customization/internationalization of command's messages\n // ---------------------------------------------------------------\n DeclareResource( TestMeasurementCmd, CATStateCommand )\n\n public:\n\n TestMeasurementCmd();\n virtual ~TestMeasurementCmd();\n\n /**\n * Defines the command automata.\n * <br>\n * <i>(states, transitions and agents)</i>\n */\n virtual void BuildGraph();\n\n /**\n * Action associated to state transitions.\n */\n virtual CATBoolean ActionOne(void * data);\n CATBoolean ActionExit(void * data);\n void selectObjAFunc(void * data);\n void selectObjBFunc(void * data);\n CATBoolean ActionOK(void * data);\n void TransToSelectA(void * data);\n void TransToSelectB(void * data);\n HRESULT GetMinDistanceByMeasure(CATISpecObject_var ispiSpec1,CATIProduct_var ispiProd1,CATISpecObject_var ispiSpec2,CATIProduct_var ispiProd2,CATMathPoint &omathPt1,CATMathPoint &omathPt2,double &oDistance);\n CATMathTransformation GetMatrixTransformation( CATISpecObject_var spSpecOne, CATISpecObject_var spSpecTwo );\n CATMathTransformation GetAbsTransformation( CATISpecObject_var ispSpecOne );\n HRESULT CheckClash(CATIProduct_var ispiPrd1,CATIProduct_var ispiPrd2);\n CATBoolean ActionOK2(void * data);\n HRESULT MeasureByDichotomy(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathVector iDir);\n HRESULT MeasureMinDistAmongProducts(vector<CATIProduct_var> ilstProdA,vector<CATIProduct_var> ilstProdB,CATMathPoint &oPtA,CATMathPoint &oPtB,double &odDistance);\n CATBoolean ActionOK3(void * data);\nprivate:\n\n\t TestMeasurementDlg\t\t*_pDlg;\n\n\t CATFrmEditor\t\t\t*_pEditor;\n\n\t CATHSO\t\t\t\t*_pHSO;\n\n\t GeneralClass\t\t\t*_pGeneralCls;\n\n\t CATFeatureImportAgent * _pSelAAgent;\n\n\t CATFeatureImportAgent * _pSelBAgent;\n\n\t CATDialogAgent\t\t* _pSelAFieldAgent;\n\n\t CATDialogAgent\t\t* _pSelBFieldAgent;\n\n\t CATBaseUnknown_var\t_spBUSelectA;\n\n\t CATBaseUnknown_var\t_spBUSelectB;\n\n\t CATIProduct_var\t\t_spiProdSelA;\n\n\t CATIProduct_var\t\t_spiProdSelB;\n\n};\n\n//----------------------------------------------------------------------\n\n#endif\n"}
80,557
c
// // NSBaseDateComponent+Private.h // CustomDatePicker // // Created by <NAME> on 7/5/16. // Copyright © 2016 <NAME>. All rights reserved. // #import "NSBaseDateComponent.h" @interface NSBaseDateComponent (Private) @property (nonatomic, strong, readonly) NSDate *minDate; @property (nonatomic, strong, readonly) NSDate *maxDate; - (NSDateComponents *) getDateComponentsForDate:(NSDate *) date; - (NSDate *) getDateForDateComponents:(NSDateComponents *) components; - (NSArray *) getComponetElements:(NSUInteger) startValue toEndValue:(NSUInteger) endValue status:(BOOL) status; - (NSString *) getStringForValue:(NSUInteger) value; @end
36.76
17
(translation_unit) "//\n// NSBaseDateComponent+Private.h\n// CustomDatePicker\n//\n// Created by <NAME> on 7/5/16.\n// Copyright © 2016 <NAME>. All rights reserved.\n//\n\n\n#import "NSBaseDateComponent.h"\n\n@interface NSBaseDateComponent (Private)\n\n@property (nonatomic, strong, readonly) NSDate *minDate;\n@property (nonatomic, strong, readonly) NSDate *maxDate;\n\n- (NSDateComponents *) getDateComponentsForDate:(NSDate *) date;\n- (NSDate *) getDateForDateComponents:(NSDateComponents *) components;\n- (NSArray *) getComponetElements:(NSUInteger) startValue toEndValue:(NSUInteger) endValue status:(BOOL) status;\n- (NSString *) getStringForValue:(NSUInteger) value;\n\n@end\n" (comment) "//" (comment) "// NSBaseDateComponent+Private.h" (comment) "// CustomDatePicker" (comment) "//" (comment) "// Created by <NAME> on 7/5/16." (comment) "// Copyright © 2016 <NAME>. All rights reserved.\n" (comment) "/\n" (preproc_call) "import "NSBaseDateComponent.h"\n\n" (preproc_directive) "import " (preproc_arg) "NSBaseDateComponent.h"\n" (ERROR) "interface NSBaseDateComponent (Private)\n\n@property (nonatomic, strong, readonly) NSDate *minDate;\n@property (nonatomic, strong, readonly) NSDate *maxDate;\n\n- (NSDateComponents *) getDateComponentsForDate:(NSDate *) date;" (ERROR) "i" (type_identifier) "nterface " (function_declarator) "SBaseDateComponent (Private)\n" (identifier) "SBaseDateComponent " (parameter_list) "Private)\n" (() "P" (identifier) "rivate)" ()) "\n" (ERROR) "p" (ERROR) "p" (declaration) "roperty (nonatomic, strong, readonly) NSDate *minDate;\n" (macro_type_specifier) "roperty (nonatomic, strong, readonly) " (identifier) "roperty " (() "n" (type_descriptor) "onatomic," (type_identifier) "onatomic," (ERROR) " strong, readonly)" (,) " " (identifier) "trong," (,) " " (identifier) "eadonly)" ()) " " (ERROR) "SDate " (identifier) "SDate " (pointer_declarator) "minDate;" (*) "m" (identifier) "inDate;" (;) "\n" (ERROR) "p" (ERROR) "p" (declaration) "roperty (nonatomic, strong, readonly) NSDate *maxDate;\n" (macro_type_specifier) "roperty (nonatomic, strong, readonly) " (identifier) "roperty " (() "n" (type_descriptor) "onatomic," (type_identifier) "onatomic," (ERROR) " strong, readonly)" (,) " " (identifier) "trong," (,) " " (identifier) "eadonly)" ()) " " (ERROR) "SDate " (identifier) "SDate " (pointer_declarator) "maxDate;" (*) "m" (identifier) "axDate;" (;) "\n" (unary_expression) " (NSDateComponents *) getDateComponentsForDate:" (-) " " (cast_expression) "NSDateComponents *) getDateComponentsForDate:" (() "N" (type_descriptor) "SDateComponents *)" (type_identifier) "SDateComponents " (abstract_pointer_declarator) ")" (*) ")" ()) " " (identifier) "etDateComponentsForDate:" (:) "(" (() "N" (binary_expression) "SDate *) date;" (identifier) "SDate " (*) ")" (ERROR) " " ()) " " (identifier) "ate;" (expression_statement) "\n" (;) "\n" (ERROR) " (NSDate *) getDateForDateComponents:(NSDateComponents *) components;\n- (NSArray *) getComponetElements:(NSUInteger) startValue toEndValue:(NSUInteger) endValue status:(BOOL) " (binary_expression) " (NSDate *) getDateForDateComponents:(NSDateComponents *) components;\n- (NSArray *) getComponetElements:" (binary_expression) " (NSDate *) getDateForDateComponents:(NSDateComponents *) components;" (unary_expression) " (NSDate *) getDateForDateComponents:" (-) " " (cast_expression) "NSDate *) getDateForDateComponents:" (() "N" (type_descriptor) "SDate *)" (type_identifier) "SDate " (abstract_pointer_declarator) ")" (*) ")" ()) " " (identifier) "etDateForDateComponents:" (ERROR) "(NSDateComponents " (:) "(" (() "N" (identifier) "SDateComponents " (*) ")" (ERROR) " " ()) " " (identifier) "omponents;" (ERROR) "\n" (;) "\n" (-) " " (cast_expression) "NSArray *) getComponetElements:" (() "N" (type_descriptor) "SArray *)" (type_identifier) "SArray " (abstract_pointer_declarator) ")" (*) ")" ()) " " (identifier) "etComponetElements:" (:) "(" (() "N" (identifier) "SUInteger)" ()) " " (identifier) "tartValue " (identifier) "oEndValue:" (:) "(" (() "N" (identifier) "SUInteger)" ()) " " (identifier) "ndValue " (identifier) "tatus:" (:) "(" (() "B" (identifier) "OOL)" ()) " " (expression_statement) "tatus;\n" (identifier) "tatus;" (;) "\n" (expression_statement) " (NSString *) getStringForValue:(NSUInteger) value;\n" (unary_expression) " (NSString *) getStringForValue:" (-) " " (cast_expression) "NSString *) getStringForValue:" (() "N" (type_descriptor) "SString *)" (type_identifier) "SString " (abstract_pointer_declarator) ")" (*) ")" ()) " " (identifier) "etStringForValue:" (ERROR) "(NSUInteger) value;" (:) "(" (() "N" (identifier) "SUInteger)" ()) " " (identifier) "alue;" (;) "\n" (ERROR) "e" (ERROR) "e" (expression_statement) "nd\n" (identifier) "nd\n" (;) ""
154
18
{"language": "c", "success": true, "metadata": {"lines": 17, "avg_line_length": 36.76, "nodes": 88, "errors": 0, "source_hash": "09662445e0dbf2f836c7bed6d3b15c950ea2b0b57bfa9bbc013f01e54388f647", "categorized_nodes": 54}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "import \"NSBaseDateComponent.h\"\n\n", "parent": null, "children": [1], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 1, "type": "preproc_arg", "text": "NSBaseDateComponent.h\"\n", "parent": 0, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 31}}, {"id": 2, "type": "ERROR", "text": "interface NSBaseDateComponent (Private)\n\n@property (nonatomic, strong, readonly) NSDate *minDate;\n@property (nonatomic, strong, readonly) NSDate *maxDate;\n\n- (NSDateComponents *) getDateComponentsForDate:(NSDate *) date;", "parent": null, "children": [3, 4, 5, 9, 11, 24, 26, 39, 45], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 16, "column": 63}}, {"id": 3, "type": "ERROR", "text": "i", "parent": 2, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 1}}, {"id": 4, "type": "type_identifier", "text": "nterface ", "parent": 2, "children": [], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 11, "column": 10}}, {"id": 5, "type": "function_declarator", "text": "SBaseDateComponent (Private)\n", "parent": 2, "children": [6, 7], "start_point": {"row": 11, "column": 11}, "end_point": {"row": 11, "column": 40}}, {"id": 6, "type": "identifier", "text": "SBaseDateComponent ", "parent": 5, "children": [], "start_point": {"row": 11, "column": 11}, "end_point": {"row": 11, "column": 30}}, {"id": 7, "type": "parameter_list", "text": "Private)\n", "parent": 5, "children": [8], "start_point": {"row": 11, "column": 31}, "end_point": {"row": 11, "column": 40}}, {"id": 8, "type": "identifier", "text": "rivate)", "parent": 7, "children": [], "start_point": {"row": 11, "column": 32}, "end_point": {"row": 11, "column": 39}}, {"id": 9, "type": "ERROR", "text": "p", "parent": 2, "children": [10], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 10, "type": "ERROR", "text": "p", "parent": 9, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 11, "type": "declaration", "text": "roperty (nonatomic, strong, readonly) NSDate *minDate;\n", "parent": 2, "children": [12, 19, 21], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 56}}, {"id": 12, "type": "macro_type_specifier", "text": "roperty (nonatomic, strong, readonly) ", "parent": 11, "children": [13, 14, 16], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 39}}, {"id": 13, "type": "identifier", "text": "roperty ", "parent": 12, "children": [], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 9}}, {"id": 14, "type": "type_descriptor", "text": "onatomic,", "parent": 12, "children": [15], "start_point": {"row": 13, "column": 11}, "end_point": {"row": 13, "column": 20}}, {"id": 15, "type": "type_identifier", "text": "onatomic,", "parent": 14, "children": [], "start_point": {"row": 13, "column": 11}, "end_point": {"row": 13, "column": 20}}, {"id": 16, "type": "ERROR", "text": " strong, readonly)", "parent": 12, "children": [17, 18], "start_point": {"row": 13, "column": 20}, "end_point": {"row": 13, "column": 38}}, {"id": 17, "type": "identifier", "text": "trong,", "parent": 16, "children": [], "start_point": {"row": 13, "column": 22}, "end_point": {"row": 13, "column": 28}}, {"id": 18, "type": "identifier", "text": "eadonly)", "parent": 16, "children": [], "start_point": {"row": 13, "column": 30}, "end_point": {"row": 13, "column": 38}}, {"id": 19, "type": "ERROR", "text": "SDate ", "parent": 11, "children": [20], "start_point": {"row": 13, "column": 40}, "end_point": {"row": 13, "column": 46}}, {"id": 20, "type": "identifier", "text": "SDate ", "parent": 19, "children": [], "start_point": {"row": 13, "column": 40}, "end_point": {"row": 13, "column": 46}}, {"id": 21, "type": "pointer_declarator", "text": "minDate;", "parent": 11, "children": [22, 23], "start_point": {"row": 13, "column": 47}, "end_point": {"row": 13, "column": 55}}, {"id": 22, "type": "*", "text": "m", "parent": 21, "children": [], "start_point": {"row": 13, "column": 47}, "end_point": {"row": 13, "column": 48}}, {"id": 23, "type": "identifier", "text": "inDate;", "parent": 21, "children": [], "start_point": {"row": 13, "column": 48}, "end_point": {"row": 13, "column": 55}}, {"id": 24, "type": "ERROR", "text": "p", "parent": 2, "children": [25], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 1}}, {"id": 25, "type": "ERROR", "text": "p", "parent": 24, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 1}}, {"id": 26, "type": "declaration", "text": "roperty (nonatomic, strong, readonly) NSDate *maxDate;\n", "parent": 2, "children": [27, 34, 36], "start_point": {"row": 14, "column": 1}, "end_point": {"row": 14, "column": 56}}, {"id": 27, "type": "macro_type_specifier", "text": "roperty (nonatomic, strong, readonly) ", "parent": 26, "children": [28, 29, 31], "start_point": {"row": 14, "column": 1}, "end_point": {"row": 14, "column": 39}}, {"id": 28, "type": "identifier", "text": "roperty ", "parent": 27, "children": [], "start_point": {"row": 14, "column": 1}, "end_point": {"row": 14, "column": 9}}, {"id": 29, "type": "type_descriptor", "text": "onatomic,", "parent": 27, "children": [30], "start_point": {"row": 14, "column": 11}, "end_point": {"row": 14, "column": 20}}, {"id": 30, "type": "type_identifier", "text": "onatomic,", "parent": 29, "children": [], "start_point": {"row": 14, "column": 11}, "end_point": {"row": 14, "column": 20}}, {"id": 31, "type": "ERROR", "text": " strong, readonly)", "parent": 27, "children": [32, 33], "start_point": {"row": 14, "column": 20}, "end_point": {"row": 14, "column": 38}}, {"id": 32, "type": "identifier", "text": "trong,", "parent": 31, "children": [], "start_point": {"row": 14, "column": 22}, "end_point": {"row": 14, "column": 28}}, {"id": 33, "type": "identifier", "text": "eadonly)", "parent": 31, "children": [], "start_point": {"row": 14, "column": 30}, "end_point": {"row": 14, "column": 38}}, {"id": 34, "type": "ERROR", "text": "SDate ", "parent": 26, "children": [35], "start_point": {"row": 14, "column": 40}, "end_point": {"row": 14, "column": 46}}, {"id": 35, "type": "identifier", "text": "SDate ", "parent": 34, "children": [], "start_point": {"row": 14, "column": 40}, "end_point": {"row": 14, "column": 46}}, {"id": 36, "type": "pointer_declarator", "text": "maxDate;", "parent": 26, "children": [37, 38], "start_point": {"row": 14, "column": 47}, "end_point": {"row": 14, "column": 55}}, {"id": 37, "type": "*", "text": "m", "parent": 36, "children": [], "start_point": {"row": 14, "column": 47}, "end_point": {"row": 14, "column": 48}}, {"id": 38, "type": "identifier", "text": "axDate;", "parent": 36, "children": [], "start_point": {"row": 14, "column": 48}, "end_point": {"row": 14, "column": 55}}, {"id": 39, "type": "unary_expression", "text": " (NSDateComponents *) getDateComponentsForDate:", "parent": 2, "children": [40, 41], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 47}}, {"id": 40, "type": "-", "text": " ", "parent": 39, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 1}}, {"id": 41, "type": "cast_expression", "text": "NSDateComponents *) getDateComponentsForDate:", "parent": 39, "children": [42, 44], "start_point": {"row": 16, "column": 2}, "end_point": {"row": 16, "column": 47}}, {"id": 42, "type": "type_descriptor", "text": "SDateComponents *)", "parent": 41, "children": [43], "start_point": {"row": 16, "column": 3}, "end_point": {"row": 16, "column": 21}}, {"id": 43, "type": "type_identifier", "text": "SDateComponents ", "parent": 42, "children": [], "start_point": {"row": 16, "column": 3}, "end_point": {"row": 16, "column": 19}}, {"id": 44, "type": "identifier", "text": "etDateComponentsForDate:", "parent": 41, "children": [], "start_point": {"row": 16, "column": 23}, "end_point": {"row": 16, "column": 47}}, {"id": 45, "type": "binary_expression", "text": "SDate *) date;", "parent": 2, "children": [46, 47, 48], "start_point": {"row": 16, "column": 49}, "end_point": {"row": 16, "column": 63}}, {"id": 46, "type": "identifier", "text": "SDate ", "parent": 45, "children": [], "start_point": {"row": 16, "column": 49}, "end_point": {"row": 16, "column": 55}}, {"id": 47, "type": "ERROR", "text": " ", "parent": 45, "children": [], "start_point": {"row": 16, "column": 57}, "end_point": {"row": 16, "column": 58}}, {"id": 48, "type": "identifier", "text": "ate;", "parent": 45, "children": [], "start_point": {"row": 16, "column": 59}, "end_point": {"row": 16, "column": 63}}, {"id": 49, "type": "ERROR", "text": " (NSDate *) getDateForDateComponents:(NSDateComponents *) components;\n- (NSArray *) getComponetElements:(NSUInteger) startValue toEndValue:(NSUInteger) endValue status:(BOOL) ", "parent": null, "children": [50, 68, 69, 70, 71, 72, 73, 74], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 18, "column": 104}}, {"id": 50, "type": "binary_expression", "text": " (NSDate *) getDateForDateComponents:(NSDateComponents *) components;\n- (NSArray *) getComponetElements:", "parent": 49, "children": [51, 62, 63, 64], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 18, "column": 33}}, {"id": 51, "type": "binary_expression", "text": " (NSDate *) getDateForDateComponents:(NSDateComponents *) components;", "parent": 50, "children": [52, 58, 60, 61], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 69}}, {"id": 52, "type": "unary_expression", "text": " (NSDate *) getDateForDateComponents:", "parent": 51, "children": [53, 54], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 37}}, {"id": 53, "type": "-", "text": " ", "parent": 52, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 54, "type": "cast_expression", "text": "NSDate *) getDateForDateComponents:", "parent": 52, "children": [55, 57], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 17, "column": 37}}, {"id": 55, "type": "type_descriptor", "text": "SDate *)", "parent": 54, "children": [56], "start_point": {"row": 17, "column": 3}, "end_point": {"row": 17, "column": 11}}, {"id": 56, "type": "type_identifier", "text": "SDate ", "parent": 55, "children": [], "start_point": {"row": 17, "column": 3}, "end_point": {"row": 17, "column": 9}}, {"id": 57, "type": "identifier", "text": "etDateForDateComponents:", "parent": 54, "children": [], "start_point": {"row": 17, "column": 13}, "end_point": {"row": 17, "column": 37}}, {"id": 58, "type": "ERROR", "text": "(NSDateComponents ", "parent": 51, "children": [59], "start_point": {"row": 17, "column": 37}, "end_point": {"row": 17, "column": 55}}, {"id": 59, "type": "identifier", "text": "SDateComponents ", "parent": 58, "children": [], "start_point": {"row": 17, "column": 39}, "end_point": {"row": 17, "column": 55}}, {"id": 60, "type": "ERROR", "text": " ", "parent": 51, "children": [], "start_point": {"row": 17, "column": 57}, "end_point": {"row": 17, "column": 58}}, {"id": 61, "type": "identifier", "text": "omponents;", "parent": 51, "children": [], "start_point": {"row": 17, "column": 59}, "end_point": {"row": 17, "column": 69}}, {"id": 62, "type": "ERROR", "text": "\n", "parent": 50, "children": [], "start_point": {"row": 17, "column": 69}, "end_point": {"row": 17, "column": 70}}, {"id": 63, "type": "-", "text": " ", "parent": 50, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 1}}, {"id": 64, "type": "cast_expression", "text": "NSArray *) getComponetElements:", "parent": 50, "children": [65, 67], "start_point": {"row": 18, "column": 2}, "end_point": {"row": 18, "column": 33}}, {"id": 65, "type": "type_descriptor", "text": "SArray *)", "parent": 64, "children": [66], "start_point": {"row": 18, "column": 3}, "end_point": {"row": 18, "column": 12}}, {"id": 66, "type": "type_identifier", "text": "SArray ", "parent": 65, "children": [], "start_point": {"row": 18, "column": 3}, "end_point": {"row": 18, "column": 10}}, {"id": 67, "type": "identifier", "text": "etComponetElements:", "parent": 64, "children": [], "start_point": {"row": 18, "column": 14}, "end_point": {"row": 18, "column": 33}}, {"id": 68, "type": "identifier", "text": "SUInteger)", "parent": 49, "children": [], "start_point": {"row": 18, "column": 35}, "end_point": {"row": 18, "column": 45}}, {"id": 69, "type": "identifier", "text": "tartValue ", "parent": 49, "children": [], "start_point": {"row": 18, "column": 47}, "end_point": {"row": 18, "column": 57}}, {"id": 70, "type": "identifier", "text": "oEndValue:", "parent": 49, "children": [], "start_point": {"row": 18, "column": 58}, "end_point": {"row": 18, "column": 68}}, {"id": 71, "type": "identifier", "text": "SUInteger)", "parent": 49, "children": [], "start_point": {"row": 18, "column": 70}, "end_point": {"row": 18, "column": 80}}, {"id": 72, "type": "identifier", "text": "ndValue ", "parent": 49, "children": [], "start_point": {"row": 18, "column": 82}, "end_point": {"row": 18, "column": 90}}, {"id": 73, "type": "identifier", "text": "tatus:", "parent": 49, "children": [], "start_point": {"row": 18, "column": 91}, "end_point": {"row": 18, "column": 97}}, {"id": 74, "type": "identifier", "text": "OOL)", "parent": 49, "children": [], "start_point": {"row": 18, "column": 99}, "end_point": {"row": 18, "column": 103}}, {"id": 75, "type": "identifier", "text": "tatus;", "parent": null, "children": [], "start_point": {"row": 18, "column": 105}, "end_point": {"row": 18, "column": 111}}, {"id": 76, "type": "unary_expression", "text": " (NSString *) getStringForValue:", "parent": null, "children": [77, 78], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 32}}, {"id": 77, "type": "-", "text": " ", "parent": 76, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 1}}, {"id": 78, "type": "cast_expression", "text": "NSString *) getStringForValue:", "parent": 76, "children": [79, 81], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 32}}, {"id": 79, "type": "type_descriptor", "text": "SString *)", "parent": 78, "children": [80], "start_point": {"row": 19, "column": 3}, "end_point": {"row": 19, "column": 13}}, {"id": 80, "type": "type_identifier", "text": "SString ", "parent": 79, "children": [], "start_point": {"row": 19, "column": 3}, "end_point": {"row": 19, "column": 11}}, {"id": 81, "type": "identifier", "text": "etStringForValue:", "parent": 78, "children": [], "start_point": {"row": 19, "column": 15}, "end_point": {"row": 19, "column": 32}}, {"id": 82, "type": "ERROR", "text": "(NSUInteger) value;", "parent": null, "children": [83, 84], "start_point": {"row": 19, "column": 32}, "end_point": {"row": 19, "column": 51}}, {"id": 83, "type": "identifier", "text": "SUInteger)", "parent": 82, "children": [], "start_point": {"row": 19, "column": 34}, "end_point": {"row": 19, "column": 44}}, {"id": 84, "type": "identifier", "text": "alue;", "parent": 82, "children": [], "start_point": {"row": 19, "column": 46}, "end_point": {"row": 19, "column": 51}}, {"id": 85, "type": "ERROR", "text": "e", "parent": null, "children": [86], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 1}}, {"id": 86, "type": "ERROR", "text": "e", "parent": 85, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 1}}, {"id": 87, "type": "identifier", "text": "nd\n", "parent": null, "children": [], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 4}}]}, "node_categories": {"declarations": {"functions": [5], "variables": [11, 26], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [39, 41, 45, 50, 51, 52, 54, 64, 76, 78], "assignments": [], "loops": [], "conditionals": [4, 6, 8, 12, 13, 15, 17, 18, 20, 23, 27, 28, 30, 32, 33, 35, 38, 43, 44, 46, 48, 56, 57, 59, 61, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 80, 81, 83, 84, 87], "returns": [], "exceptions": []}, "expressions": {"calls": [0], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 5, "universal_type": "function", "name": "unknown", "text_snippet": "SBaseDateComponent (Private)\n"}], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// NSBaseDateComponent+Private.h\n// CustomDatePicker\n//\n// Created by <NAME> on 7/5/16.\n// Copyright \u00a9 2016 <NAME>. All rights reserved.\n//\n\n\n#import \"NSBaseDateComponent.h\"\n\n@interface NSBaseDateComponent (Private)\n\n@property (nonatomic, strong, readonly) NSDate *minDate;\n@property (nonatomic, strong, readonly) NSDate *maxDate;\n\n- (NSDateComponents *) getDateComponentsForDate:(NSDate *) date;\n- (NSDate *) getDateForDateComponents:(NSDateComponents *) components;\n- (NSArray *) getComponetElements:(NSUInteger) startValue toEndValue:(NSUInteger) endValue status:(BOOL) status;\n- (NSString *) getStringForValue:(NSUInteger) value;\n\n@end\n"}
80,558
c
// // NSArray+ZHCMessages.h // ZHChat // // Created by aimoke on 16/8/29. // Copyright © 2016年 zhuo. All rights reserved. // #import <Foundation/Foundation.h> @interface NSArray (ZHCMessages) /** * @return The default Emojis. */ +(NSArray *)zhc_getEmojis; @end
18.14
14
(translation_unit) "//\n// NSArray+ZHCMessages.h\n// ZHChat\n//\n// Created by aimoke on 16/8/29.\n// Copyright © 2016年 zhuo. All rights reserved.\n//\n\n#import <Foundation/Foundation.h>\n\n@interface NSArray (ZHCMessages)\n\n/**\n * @return The default Emojis.\n */\n+(NSArray *)zhc_getEmojis;\n\n@end\n" (comment) "//" (comment) "// NSArray+ZHCMessages.h" (comment) "// ZHChat" (comment) "//" (comment) "// Created by aimoke on 16/8/29." (comment) "// Copyright © 2016年 zhuo. All rights reserved.\n//" (comment) "\n#" (preproc_call) "port <Foundation/Foundation.h>\n\n@i" (preproc_directive) "port <F" (preproc_arg) "undation/Foundation.h>\n\n@" (ERROR) "terface NSArray (ZHCMessages)\n\n/" (ERROR) "t" (type_identifier) "erface NS" (function_declarator) "rray (ZHCMessages)\n\n/" (identifier) "rray (Z" (parameter_list) "CMessages)\n\n/" (() "C" (identifier) "Messages)\n\n" ()) "/" (comment) "\n * @return The default Emojis.\n */\n+(" (expression_statement) "SArray *)zhc_getEmojis;\n\n@" (unary_expression) "SArray *)zhc_getEmojis;\n\n" (+) "S" (cast_expression) "Array *)zhc_getEmojis;\n\n" (() "A" (type_descriptor) "rray *)zh" (type_identifier) "rray *)" (abstract_pointer_declarator) "h" (*) "h" ()) "c" (identifier) "_getEmojis;\n\n" (;) "@" (ERROR) "d" (ERROR) "d" (expression_statement) "\n" (identifier) "\n" (;) ""
38
4
{"language": "c", "success": true, "metadata": {"lines": 14, "avg_line_length": 18.14, "nodes": 21, "errors": 0, "source_hash": "8dc93f52875617fc3e0f8039362199284c2ebf2d61d285d1727b227c6e753a15", "categorized_nodes": 10}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "port <Foundation/Foundation.h>\n\n@i", "parent": null, "children": [1, 2], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "port <F", "parent": 0, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "undation/Foundation.h>\n\n@", "parent": 0, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 33}}, {"id": 3, "type": "ERROR", "text": "terface NSArray (ZHCMessages)\n\n/", "parent": null, "children": [4, 5, 6], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 32}}, {"id": 4, "type": "ERROR", "text": "t", "parent": 3, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 1}}, {"id": 5, "type": "type_identifier", "text": "erface NS", "parent": 3, "children": [], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 10}}, {"id": 6, "type": "function_declarator", "text": "rray (ZHCMessages)\n\n/", "parent": 3, "children": [7, 8], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 10, "column": 32}}, {"id": 7, "type": "identifier", "text": "rray (Z", "parent": 6, "children": [], "start_point": {"row": 10, "column": 11}, "end_point": {"row": 10, "column": 18}}, {"id": 8, "type": "parameter_list", "text": "CMessages)\n\n/", "parent": 6, "children": [9], "start_point": {"row": 10, "column": 19}, "end_point": {"row": 10, "column": 32}}, {"id": 9, "type": "identifier", "text": "Messages)\n\n", "parent": 8, "children": [], "start_point": {"row": 10, "column": 20}, "end_point": {"row": 10, "column": 31}}, {"id": 10, "type": "unary_expression", "text": "SArray *)zhc_getEmojis;\n\n", "parent": null, "children": [11, 12], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 25}}, {"id": 11, "type": "+", "text": "S", "parent": 10, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 1}}, {"id": 12, "type": "cast_expression", "text": "Array *)zhc_getEmojis;\n\n", "parent": 10, "children": [13, 17], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 25}}, {"id": 13, "type": "type_descriptor", "text": "rray *)zh", "parent": 12, "children": [14, 15], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 11}}, {"id": 14, "type": "type_identifier", "text": "rray *)", "parent": 13, "children": [], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 9}}, {"id": 15, "type": "abstract_pointer_declarator", "text": "h", "parent": 13, "children": [16], "start_point": {"row": 15, "column": 10}, "end_point": {"row": 15, "column": 11}}, {"id": 16, "type": "*", "text": "h", "parent": 15, "children": [], "start_point": {"row": 15, "column": 10}, "end_point": {"row": 15, "column": 11}}, {"id": 17, "type": "identifier", "text": "_getEmojis;\n\n", "parent": 12, "children": [], "start_point": {"row": 15, "column": 12}, "end_point": {"row": 15, "column": 25}}, {"id": 18, "type": "ERROR", "text": "d", "parent": null, "children": [19], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 19, "type": "ERROR", "text": "d", "parent": 18, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 20, "type": "identifier", "text": "\n", "parent": null, "children": [], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 4}}]}, "node_categories": {"declarations": {"functions": [6], "variables": [], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [10, 12], "assignments": [], "loops": [], "conditionals": [5, 7, 9, 14, 17, 20], "returns": [], "exceptions": []}, "expressions": {"calls": [0], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 6, "universal_type": "function", "name": "unknown", "text_snippet": "rray (ZHCMessages)\n\n/"}], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// NSArray+ZHCMessages.h\n// ZHChat\n//\n// Created by aimoke on 16/8/29.\n// Copyright \u00a9 2016\u5e74 zhuo. All rights reserved.\n//\n\n#import <Foundation/Foundation.h>\n\n@interface NSArray (ZHCMessages)\n\n/**\n * @return The default Emojis.\n */\n+(NSArray *)zhc_getEmojis;\n\n@end\n"}
80,559
c
#ifndef UNTITLED_ITEM_H #define UNTITLED_ITEM_H #include <vector> #include "GameObject.h" #include "Property.h" class Item : public GameObject { public: const std::vector<Property> &getProperties() const; void addProperty(Property aProperty); private: std::vector<Property> properties; }; #endif //UNTITLED_ITEM_H
20.8
15
(translation_unit) "#ifndef UNTITLED_ITEM_H\n#define UNTITLED_ITEM_H\n\n#include <vector>\n#include "GameObject.h"\n#include "Property.h"\n\nclass Item : public GameObject\n{\npublic:\n const std::vector<Property> &getProperties() const;\n\n void addProperty(Property aProperty);\n\nprivate:\n std::vector<Property> properties;\n\n};\n\n\n#endif //UNTITLED_ITEM_H\n" (preproc_ifdef) "#ifndef UNTITLED_ITEM_H\n#define UNTITLED_ITEM_H\n\n#include <vector>\n#include "GameObject.h"\n#include "Property.h"\n\nclass Item : public GameObject\n{\npublic:\n const std::vector<Property> &getProperties() const;\n\n void addProperty(Property aProperty);\n\nprivate:\n std::vector<Property> properties;\n\n};\n\n\n#endif" (#ifndef) "#ifndef" (identifier) "UNTITLED_ITEM_H" (preproc_def) "#define UNTITLED_ITEM_H\n" (#define) "#define" (identifier) "UNTITLED_ITEM_H" (preproc_include) "#include <vector>\n" (#include) "#include" (system_lib_string) "<vector>" (preproc_include) "#include "GameObject.h"\n" (#include) "#include" (string_literal) ""GameObject.h"" (") """ (string_content) "GameObject.h" (") """ (preproc_include) "#include "Property.h"\n" (#include) "#include" (string_literal) ""Property.h"" (") """ (string_content) "Property.h" (") """ (function_definition) "class Item : public GameObject\n{\npublic:\n const std::vector<Property> &getProperties() const;\n\n void addProperty(Property aProperty);\n\nprivate:\n std::vector<Property> properties;\n\n}" (type_identifier) "class" (ERROR) "Item : public" (identifier) "Item" (:) ":" (identifier) "public" (identifier) "GameObject" (compound_statement) "{\npublic:\n const std::vector<Property> &getProperties() const;\n\n void addProperty(Property aProperty);\n\nprivate:\n std::vector<Property> properties;\n\n}" ({) "{" (labeled_statement) "public:\n const std::vector<Property> &getProperties() const;" (statement_identifier) "public" (ERROR) ":\n const std:" (:) ":" (type_qualifier) "const" (const) "const" (type_identifier) "std" (:) ":" (:) ":" (expression_statement) "vector<Property> &getProperties() const;" (binary_expression) "vector<Property> &getProperties()" (binary_expression) "vector<Property" (identifier) "vector" (<) "<" (identifier) "Property" (>) ">" (pointer_expression) "&getProperties()" (&) "&" (call_expression) "getProperties()" (identifier) "getProperties" (argument_list) "()" (() "(" ()) ")" (ERROR) "const" (identifier) "const" (;) ";" (declaration) "void addProperty(Property aProperty);" (primitive_type) "void" (function_declarator) "addProperty(Property aProperty)" (identifier) "addProperty" (parameter_list) "(Property aProperty)" (() "(" (parameter_declaration) "Property aProperty" (type_identifier) "Property" (identifier) "aProperty" ()) ")" (;) ";" (labeled_statement) "private:\n std::vector<Property> properties;" (statement_identifier) "private" (:) ":" (labeled_statement) "std::vector<Property> properties;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "vector<Property> properties;" (binary_expression) "vector<Property> properties" (binary_expression) "vector<Property" (identifier) "vector" (<) "<" (identifier) "Property" (>) ">" (identifier) "properties" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (#endif) "#endif" (comment) "//UNTITLED_ITEM_H"
90
4
{"language": "c", "success": true, "metadata": {"lines": 15, "avg_line_length": 20.8, "nodes": 51, "errors": 0, "source_hash": "b53594221bca9c88732c289bc61b4d1453089639c82262c654aac64c9572d6f3", "categorized_nodes": 37}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef UNTITLED_ITEM_H\n#define UNTITLED_ITEM_H\n\n#include <vector>\n#include \"GameObject.h\"\n#include \"Property.h\"\n\nclass Item : public GameObject\n{\npublic:\n const std::vector<Property> &getProperties() const;\n\n void addProperty(Property aProperty);\n\nprivate:\n std::vector<Property> properties;\n\n};\n\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 15, 50], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 20, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "identifier", "text": "UNTITLED_ITEM_H", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 23}}, {"id": 3, "type": "preproc_def", "text": "#define UNTITLED_ITEM_H\n", "parent": 0, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 5, "type": "identifier", "text": "UNTITLED_ITEM_H", "parent": 3, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 23}}, {"id": 6, "type": "preproc_include", "text": "#include <vector>\n", "parent": 0, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<vector>", "parent": 6, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 17}}, {"id": 9, "type": "preproc_include", "text": "#include \"GameObject.h\"\n", "parent": 0, "children": [10, 11], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"GameObject.h\"", "parent": 9, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 23}}, {"id": 12, "type": "preproc_include", "text": "#include \"Property.h\"\n", "parent": 0, "children": [13, 14], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 14, "type": "string_literal", "text": "\"Property.h\"", "parent": 12, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 21}}, {"id": 15, "type": "function_definition", "text": "class Item : public GameObject\n{\npublic:\n const std::vector<Property> &getProperties() const;\n\n void addProperty(Property aProperty);\n\nprivate:\n std::vector<Property> properties;\n\n}", "parent": 0, "children": [16, 18], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 16, "type": "ERROR", "text": "Item : public", "parent": 15, "children": [17], "start_point": {"row": 7, "column": 6}, "end_point": {"row": 7, "column": 19}}, {"id": 17, "type": "identifier", "text": "Item", "parent": 16, "children": [], "start_point": {"row": 7, "column": 6}, "end_point": {"row": 7, "column": 10}}, {"id": 18, "type": "identifier", "text": "GameObject", "parent": 15, "children": [], "start_point": {"row": 7, "column": 20}, "end_point": {"row": 7, "column": 30}}, {"id": 19, "type": "labeled_statement", "text": "public:\n const std::vector<Property> &getProperties() const;", "parent": 15, "children": [20], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 55}}, {"id": 20, "type": "ERROR", "text": ":\n const std:", "parent": 19, "children": [21], "start_point": {"row": 9, "column": 6}, "end_point": {"row": 10, "column": 14}}, {"id": 21, "type": "type_identifier", "text": "std", "parent": 20, "children": [], "start_point": {"row": 10, "column": 10}, "end_point": {"row": 10, "column": 13}}, {"id": 22, "type": "binary_expression", "text": "vector<Property> &getProperties()", "parent": 19, "children": [23, 27, 28], "start_point": {"row": 10, "column": 15}, "end_point": {"row": 10, "column": 48}}, {"id": 23, "type": "binary_expression", "text": "vector<Property", "parent": 22, "children": [24, 25, 26], "start_point": {"row": 10, "column": 15}, "end_point": {"row": 10, "column": 30}}, {"id": 24, "type": "identifier", "text": "vector", "parent": 23, "children": [], "start_point": {"row": 10, "column": 15}, "end_point": {"row": 10, "column": 21}}, {"id": 25, "type": "<", "text": "<", "parent": 23, "children": [], "start_point": {"row": 10, "column": 21}, "end_point": {"row": 10, "column": 22}}, {"id": 26, "type": "identifier", "text": "Property", "parent": 23, "children": [], "start_point": {"row": 10, "column": 22}, "end_point": {"row": 10, "column": 30}}, {"id": 27, "type": ">", "text": ">", "parent": 22, "children": [], "start_point": {"row": 10, "column": 30}, "end_point": {"row": 10, "column": 31}}, {"id": 28, "type": "pointer_expression", "text": "&getProperties()", "parent": 22, "children": [29], "start_point": {"row": 10, "column": 32}, "end_point": {"row": 10, "column": 48}}, {"id": 29, "type": "call_expression", "text": "getProperties()", "parent": 28, "children": [30, 31], "start_point": {"row": 10, "column": 33}, "end_point": {"row": 10, "column": 48}}, {"id": 30, "type": "identifier", "text": "getProperties", "parent": 29, "children": [], "start_point": {"row": 10, "column": 33}, "end_point": {"row": 10, "column": 46}}, {"id": 31, "type": "argument_list", "text": "()", "parent": 29, "children": [], "start_point": {"row": 10, "column": 46}, "end_point": {"row": 10, "column": 48}}, {"id": 32, "type": "declaration", "text": "void addProperty(Property aProperty);", "parent": 15, "children": [33, 34], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 41}}, {"id": 33, "type": "primitive_type", "text": "void", "parent": 32, "children": [], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 8}}, {"id": 34, "type": "function_declarator", "text": "addProperty(Property aProperty)", "parent": 32, "children": [35, 36], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 40}}, {"id": 35, "type": "identifier", "text": "addProperty", "parent": 34, "children": [], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 20}}, {"id": 36, "type": "parameter_list", "text": "(Property aProperty)", "parent": 34, "children": [37], "start_point": {"row": 12, "column": 20}, "end_point": {"row": 12, "column": 40}}, {"id": 37, "type": "parameter_declaration", "text": "Property aProperty", "parent": 36, "children": [38, 39], "start_point": {"row": 12, "column": 21}, "end_point": {"row": 12, "column": 39}}, {"id": 38, "type": "type_identifier", "text": "Property", "parent": 37, "children": [], "start_point": {"row": 12, "column": 21}, "end_point": {"row": 12, "column": 29}}, {"id": 39, "type": "identifier", "text": "aProperty", "parent": 37, "children": [], "start_point": {"row": 12, "column": 30}, "end_point": {"row": 12, "column": 39}}, {"id": 40, "type": "labeled_statement", "text": "private:\n std::vector<Property> properties;", "parent": 15, "children": [41], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 15, "column": 37}}, {"id": 41, "type": "labeled_statement", "text": "std::vector<Property> properties;", "parent": 40, "children": [42], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 37}}, {"id": 42, "type": "statement_identifier", "text": "std", "parent": 41, "children": [], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 7}}, {"id": 43, "type": "binary_expression", "text": "vector<Property> properties", "parent": 41, "children": [44, 48, 49], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 36}}, {"id": 44, "type": "binary_expression", "text": "vector<Property", "parent": 43, "children": [45, 46, 47], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 24}}, {"id": 45, "type": "identifier", "text": "vector", "parent": 44, "children": [], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 15}}, {"id": 46, "type": "<", "text": "<", "parent": 44, "children": [], "start_point": {"row": 15, "column": 15}, "end_point": {"row": 15, "column": 16}}, {"id": 47, "type": "identifier", "text": "Property", "parent": 44, "children": [], "start_point": {"row": 15, "column": 16}, "end_point": {"row": 15, "column": 24}}, {"id": 48, "type": ">", "text": ">", "parent": 43, "children": [], "start_point": {"row": 15, "column": 24}, "end_point": {"row": 15, "column": 25}}, {"id": 49, "type": "identifier", "text": "properties", "parent": 43, "children": [], "start_point": {"row": 15, "column": 26}, "end_point": {"row": 15, "column": 36}}, {"id": 50, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 6}}]}, "node_categories": {"declarations": {"functions": [15, 34], "variables": [32, 37], "classes": [], "imports": [6, 7, 9, 10, 12, 13], "modules": [], "enums": []}, "statements": {"expressions": [22, 23, 28, 29, 43, 44], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 17, 18, 21, 24, 26, 30, 35, 38, 39, 42, 45, 47, 49, 50], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [8, 11, 14], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 15, "universal_type": "function", "name": "Item", "text_snippet": "class Item : public GameObject\n{\npublic:\n const std::vector<Property> &getProperties() const;\n\n "}, {"node_id": 34, "universal_type": "function", "name": "unknown", "text_snippet": "addProperty(Property aProperty)"}], "class_declarations": [], "import_statements": [{"node_id": 6, "text": "#include <vector>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include \"GameObject.h\"\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include \"Property.h\"\n"}, {"node_id": 13, "text": "#include"}]}, "original_source_code": "#ifndef UNTITLED_ITEM_H\n#define UNTITLED_ITEM_H\n\n#include <vector>\n#include \"GameObject.h\"\n#include \"Property.h\"\n\nclass Item : public GameObject\n{\npublic:\n const std::vector<Property> &getProperties() const;\n\n void addProperty(Property aProperty);\n\nprivate:\n std::vector<Property> properties;\n\n};\n\n\n#endif //UNTITLED_ITEM_H\n"}
80,560
c
#pragma once namespace RaytracingRenderer { class Camera { private: float3 horizontal; float3 vertical; public: float aspect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT; float fov = 1; //values between 0.0-1.15. 0.45, 0.60, and 1 are standard float3 screen_p0; float3 screen_p1; float3 screen_p2; // Camera position: 𝐸 =(0,0,0) and view direction : 𝑉 = (0, 0, 1) and up direction : U = (0, 1, 0) float3 cameraPos = float3(0, 0, 0); float3 cameraLook = float3(0, 0, -1); float3 up = float3(0, 1, 0); //Camera's view matrix float3 cameraRight = normalize(cross(up, cameraLook)); float3 cameraUp = cross(cameraLook, cameraRight); //Camera's pitch + yaw float yaw = 90.f; float pitch = 0.f; float lastX, lastY; bool firstMouse = true; Camera(float3 cameraPos, float fov, float aspect_ratio); Camera(); void updateCameraVectors(); inline void updateFOV(float fov) { this->fov = fov; } inline void updateAspectRatio(float aspect_ratio) { this->aspect_ratio = aspect_ratio; } void updateViewport(); void keyHandler(int key); void mouseHandler(int x, int y); //Calculates new camera look vector float3 getDirection(float yaw, float pitch); }; }
28.59
41
(translation_unit) "ragma once\n\nnamespace RaytracingRenderer {\n\n class Camera\n {\n private:\n float3 horizontal;\n float3 vertical;\n\n public:\n float aspect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n float fov = 1; //values between 0.0-1.15. 0.45, 0.60, and 1 are standard\n float3 screen_p0;\n float3 screen_p1;\n float3 screen_p2;\n // Camera position: 𝐸 =(0,0,0) and view direction : 𝑉 = (0, 0, 1) and up direction : U = (0, 1, 0)\n float3 cameraPos = float3(0, 0, 0);\n float3 cameraLook = float3(0, 0, -1);\n float3 up = float3(0, 1, 0);\n\n //Camera's view matrix\n float3 cameraRight = normalize(cross(up, cameraLook));\n float3 cameraUp = cross(cameraLook, cameraRight);\n\n //Camera's pitch + yaw\n float yaw = 90.f;\n float pitch = 0.f;\n float lastX, lastY;\n\n bool firstMouse = true;\n\n Camera(float3 cameraPos, float fov, float aspect_ratio);\n Camera();\n\n void updateCameraVectors();\n\n inline void updateFOV(float fov) {\n this->fov = fov;\n }\n inline void updateAspectRatio(float aspect_ratio) {\n this->aspect_ratio = aspect_ratio;\n }\n\n void updateViewport();\n void keyHandler(int key);\n void mouseHandler(int x, int y);\n\n //Calculates new camera look vector\n float3 getDirection(float yaw, float pitch);\n };\n}\n" (preproc_call) "ragma once\n\nn" (preproc_directive) "ragma o" (preproc_arg) "ce\n\n" (function_definition) "mespace RaytracingRenderer {\n\n class Camera\n {\n private:\n float3 horizontal;\n float3 vertical;\n\n public:\n float aspect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n float fov = 1; //values between 0.0-1.15. 0.45, 0.60, and 1 are standard\n float3 screen_p0;\n float3 screen_p1;\n float3 screen_p2;\n // Camera position: 𝐸 =(0,0,0) and view direction : 𝑉 = (0, 0, 1) and up direction : U = (0, 1, 0)\n float3 cameraPos = float3(0, 0, 0);\n float3 cameraLook = float3(0, 0, -1);\n float3 up = float3(0, 1, 0);\n\n //Camera's view matrix\n float3 cameraRight = normalize(cross(up, cameraLook));\n float3 cameraUp = cross(cameraLook, cameraRight);\n\n //Camera's pitch + yaw\n float yaw = 90.f;\n float pitch = 0.f;\n float lastX, lastY;\n\n bool firstMouse = true;\n\n Camera(float3 cameraPos, float fov, float aspect_ratio);\n Camera();\n\n void updateCameraVectors();\n\n inline void updateFOV(float fov) {\n this->fov = fov;\n }\n inline void updateAspectRatio(float aspect_ratio) {\n this->aspect_ratio = aspect_ratio;\n }\n\n void updateViewport();\n void keyHandler(int key);\n void mouseHandler(int x, int y);\n\n //Calculates new camera look vector\n float3 getDirection(float yaw, float pitch);\n };\n}\n" (type_identifier) "mespace R" (identifier) "ytracingRenderer {" (compound_statement) "\n class Camera\n {\n private:\n float3 horizontal;\n float3 vertical;\n\n public:\n float aspect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n float fov = 1; //values between 0.0-1.15. 0.45, 0.60, and 1 are standard\n float3 screen_p0;\n float3 screen_p1;\n float3 screen_p2;\n // Camera position: 𝐸 =(0,0,0) and view direction : 𝑉 = (0, 0, 1) and up direction : U = (0, 1, 0)\n float3 cameraPos = float3(0, 0, 0);\n float3 cameraLook = float3(0, 0, -1);\n float3 up = float3(0, 1, 0);\n\n //Camera's view matrix\n float3 cameraRight = normalize(cross(up, cameraLook));\n float3 cameraUp = cross(cameraLook, cameraRight);\n\n //Camera's pitch + yaw\n float yaw = 90.f;\n float pitch = 0.f;\n float lastX, lastY;\n\n bool firstMouse = true;\n\n Camera(float3 cameraPos, float fov, float aspect_ratio);\n Camera();\n\n void updateCameraVectors();\n\n inline void updateFOV(float fov) {\n this->fov = fov;\n }\n inline void updateAspectRatio(float aspect_ratio) {\n this->aspect_ratio = aspect_ratio;\n }\n\n void updateViewport();\n void keyHandler(int key);\n void mouseHandler(int x, int y);\n\n //Calculates new camera look vector\n float3 getDirection(float yaw, float pitch);\n };\n}\n" ({) "\n" (function_definition) "ass Camera\n {\n private:\n float3 horizontal;\n float3 vertical;\n\n public:\n float aspect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n float fov = 1; //values between 0.0-1.15. 0.45, 0.60, and 1 are standard\n float3 screen_p0;\n float3 screen_p1;\n float3 screen_p2;\n // Camera position: 𝐸 =(0,0,0) and view direction : 𝑉 = (0, 0, 1) and up direction : U = (0, 1, 0)\n float3 cameraPos = float3(0, 0, 0);\n float3 cameraLook = float3(0, 0, -1);\n float3 up = float3(0, 1, 0);\n\n //Camera's view matrix\n float3 cameraRight = normalize(cross(up, cameraLook));\n float3 cameraUp = cross(cameraLook, cameraRight);\n\n //Camera's pitch + yaw\n float yaw = 90.f;\n float pitch = 0.f;\n float lastX, lastY;\n\n bool firstMouse = true;\n\n Camera(float3 cameraPos, float fov, float aspect_ratio);\n Camera();\n\n void updateCameraVectors();\n\n inline void updateFOV(float fov) {\n this->fov = fov;\n }\n inline void updateAspectRatio(float aspect_ratio) {\n this->aspect_ratio = aspect_ratio;\n }\n\n void updateViewport();\n void keyHandler(int key);\n void mouseHandler(int x, int y);\n\n //Calculates new camera look vector\n float3 getDirection(float yaw, float pitch);\n };\n}\n" (type_identifier) "ass C" (identifier) "mera\n " (compound_statement) " private:\n float3 horizontal;\n float3 vertical;\n\n public:\n float aspect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n float fov = 1; //values between 0.0-1.15. 0.45, 0.60, and 1 are standard\n float3 screen_p0;\n float3 screen_p1;\n float3 screen_p2;\n // Camera position: 𝐸 =(0,0,0) and view direction : 𝑉 = (0, 0, 1) and up direction : U = (0, 1, 0)\n float3 cameraPos = float3(0, 0, 0);\n float3 cameraLook = float3(0, 0, -1);\n float3 up = float3(0, 1, 0);\n\n //Camera's view matrix\n float3 cameraRight = normalize(cross(up, cameraLook));\n float3 cameraUp = cross(cameraLook, cameraRight);\n\n //Camera's pitch + yaw\n float yaw = 90.f;\n float pitch = 0.f;\n float lastX, lastY;\n\n bool firstMouse = true;\n\n Camera(float3 cameraPos, float fov, float aspect_ratio);\n Camera();\n\n void updateCameraVectors();\n\n inline void updateFOV(float fov) {\n this->fov = fov;\n }\n inline void updateAspectRatio(float aspect_ratio) {\n this->aspect_ratio = aspect_ratio;\n }\n\n void updateViewport();\n void keyHandler(int key);\n void mouseHandler(int x, int y);\n\n //Calculates new camera look vector\n float3 getDirection(float yaw, float pitch);\n };\n}\n" ({) " " (labeled_statement) "ivate:\n float3 horizontal;\n " (statement_identifier) "ivate:\n" (:) " " (declaration) "oat3 horizontal;\n " (type_identifier) "oat3 h" (identifier) "rizontal;\n" (;) " " (declaration) "oat3 vertical;\n\n" (type_identifier) "oat3 v" (identifier) "rtical;\n" (;) "\n" (labeled_statement) "blic:\n float aspect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n " (statement_identifier) "blic:\n" (:) " " (declaration) "oat aspect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n " (primitive_type) "oat a" (init_declarator) "pect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n" (identifier) "pect_ratio =" (=) "(" (binary_expression) "loat)SCRWIDTH / (float)SCRHEIGHT;\n" (cast_expression) "loat)SCRWIDTH /" (() "l" (type_descriptor) "oat)S" (primitive_type) "oat)S" ()) "C" (identifier) "RWIDTH /" (/) "(" (cast_expression) "loat)SCRHEIGHT;\n" (() "l" (type_descriptor) "oat)S" (primitive_type) "oat)S" ()) "C" (identifier) "RHEIGHT;\n" (;) " " (declaration) "oat fov = 1; /" (primitive_type) "oat f" (init_declarator) "v = 1; " (identifier) "v =" (=) "1" (number_literal) " " (;) "/" (comment) "values between 0.0-1.15. 0.45, 0.60, and 1 are standard\n " (declaration) "oat3 screen_p0;\n " (type_identifier) "oat3 s" (identifier) "reen_p0;\n" (;) " " (declaration) "oat3 screen_p1;\n " (type_identifier) "oat3 s" (identifier) "reen_p1;\n" (;) " " (declaration) "oat3 screen_p2;\n " (type_identifier) "oat3 s" (identifier) "reen_p2;\n" (;) " " (comment) " Camera position: 𝐸 =(0,0,0) and view direction : 𝑉 = (0, 0, 1) and up direction : U = (0, 1, 0)\n float" (declaration) "ameraPos = float3(0, 0, 0);\n float" (type_identifier) "ameraP" (init_declarator) "s = float3(0, 0, 0);\n floa" (identifier) "s = float" (=) "(" (call_expression) ", 0, 0);\n floa" (identifier) ", 0, 0" (argument_list) ");\n floa" (() ")" (number_literal) ";" (,) "\n" (number_literal) " " (,) "f" (number_literal) "o" ()) "a" (;) "t" (declaration) "ameraLook = float3(0, 0, -1);\n float" (type_identifier) "ameraL" (init_declarator) "ok = float3(0, 0, -1);\n floa" (identifier) "ok = float" (=) "(" (call_expression) ", 0, -1);\n floa" (identifier) ", 0, -" (argument_list) "1);\n floa" (() "1" (number_literal) ")" (,) ";" (number_literal) " " (,) " " (number_literal) "lo" ()) "a" (;) "t" (declaration) "p = float3(0, 1, 0);\n\n //Ca" (type_identifier) "p = fl" (init_declarator) "at3(0, 1, 0);\n\n //C" (identifier) "at" (=) "(" (call_expression) ", 1, 0);\n\n //C" (identifier) ", 1, 0" (argument_list) ");\n\n //C" (() ")" (number_literal) ";" (,) "\n" (number_literal) " " (,) " " (number_literal) "/" ()) "C" (;) "a" (comment) "'s view matrix\n float" (declaration) "ameraRight = normalize(cross(up, cameraLook));\n float" (type_identifier) "ameraR" (init_declarator) "ght = normalize(cross(up, cameraLook));\n floa" (identifier) "ght = norma" (=) "i" (call_expression) "e(cross(up, cameraLook));\n floa" (identifier) "e(cross(u" (argument_list) "p, cameraLook));\n floa" (() "p" (call_expression) ", cameraLook));\n flo" (identifier) ", cam" (argument_list) "eraLook));\n flo" (() "e" (identifier) "ra" (,) "L" (identifier) "ok));\n fl" ()) "o" ()) "a" (;) "t" (declaration) "ameraUp = cross(cameraLook, cameraRight);\n\n //Ca" (type_identifier) "ameraU" (init_declarator) " = cross(cameraLook, cameraRight);\n\n //C" (identifier) " = cross" (=) "c" (call_expression) "meraLook, cameraRight);\n\n //C" (identifier) "meraL" (argument_list) "ook, cameraRight);\n\n //C" (() "o" (identifier) "ok, camera" (,) "R" (identifier) "ght);\n\n //" ()) "C" (;) "a" (comment) "'s pitch + yaw\n float" (declaration) "w = 90.f;\n float" (primitive_type) "w = 9" (init_declarator) ".f;\n floa" (identifier) ".f;" (=) " " (number_literal) "floa" (;) "t" (declaration) "tch = 0.f;\n float" (primitive_type) "tch =" (init_declarator) "0.f;\n floa" (identifier) "0.f;\n" (=) " " (number_literal) "loa" (;) "t" (declaration) "stX, lastY;\n\n bool" (primitive_type) "stX, " (identifier) "astY;" (,) "\n" (identifier) " boo" (;) "l" (declaration) "stMouse = true;\n\n Cam" (primitive_type) "stMo" (init_declarator) "se = true;\n\n Ca" (identifier) "se = true;" (=) "\n" (true) " Ca" (;) "m" (declaration) "loat3 cameraPos, float fov, float aspect_ratio);\n Came" (macro_type_specifier) "loat3 cameraP" (identifier) "loat3 " (() "c" (type_descriptor) "ameraP" (type_identifier) "ameraP" ()) "" (identifier) "s, float " (,) "f" (identifier) "v, fl" (ERROR) "at " (identifier) "at " (,) "a" (identifier) "pect_" (ERROR) "atio);\n Cam" (identifier) "atio);\n Ca" ()) "m" (;) "e" (expression_statement) ";\n\n voi" (call_expression) ";\n\n vo" (identifier) ";\n\n " (argument_list) "vo" (() "v" ()) "o" (;) "i" (declaration) "ateCameraVectors();\n\n inli" (primitive_type) "ateC" (function_declarator) "meraVectors();\n\n inl" (identifier) "meraVectors();\n\n i" (parameter_list) "nl" (() "n" ()) "l" (;) "i" (function_definition) "oid updateFOV(float fov) {\n this->fov = fov;\n }\n inlin" (storage_class_specifier) "oid up" (inline) "oid up" (primitive_type) "ateF" (function_declarator) "V(float fov) {\n th" (identifier) "V(float f" (parameter_list) "ov) {\n th" (() "o" (parameter_declaration) "v) {\n t" (primitive_type) "v) {\n" (identifier) " t" ()) "h" (compound_statement) "s->fov = fov;\n }\n inlin" ({) "s" (expression_statement) "v = fov;\n }\n i" (assignment_expression) "v = fov;\n }\n " (field_expression) "v = fov;\n" (identifier) "v = " (->) "fo" (field_identifier) "v;\n" (=) " " (identifier) "\n " (;) "i" (}) "n" (function_definition) "oid updateAspectRatio(float aspect_ratio) {\n this->aspect_ratio = aspect_ratio;\n }\n\n void" (storage_class_specifier) "oid up" (inline) "oid up" (primitive_type) "ateA" (function_declarator) "pectRatio(float aspect_ratio) {\n th" (identifier) "pectRatio(float a" (parameter_list) "spect_ratio) {\n th" (() "s" (parameter_declaration) "pect_ratio) {\n t" (primitive_type) "pect_" (identifier) "atio) {\n t" ()) "h" (compound_statement) "s->aspect_ratio = aspect_ratio;\n }\n\n void" ({) "s" (expression_statement) "pect_ratio = aspect_ratio;\n }\n\n " (assignment_expression) "pect_ratio = aspect_ratio;\n }\n\n " (field_expression) "pect_ratio = aspec" (identifier) "pect" (->) "_r" (field_identifier) "atio = aspec" (=) "_" (identifier) "atio;\n }\n\n " (;) " " (}) "d" (declaration) "ateViewport();\n void " (primitive_type) "ateV" (function_declarator) "ewport();\n void" (identifier) "ewport();\n vo" (parameter_list) "id" (() "i" ()) "d" (;) " " (declaration) "Handler(int key);\n void " (primitive_type) "Hand" (function_declarator) "er(int key);\n void" (identifier) "er(int key" (parameter_list) ");\n void" (() ")" (parameter_declaration) ";\n voi" (primitive_type) ";\n " (identifier) "voi" ()) "d" (;) " " (declaration) "seHandler(int x, int y);\n\n //Ca" (primitive_type) "seHa" (function_declarator) "dler(int x, int y);\n\n //C" (identifier) "dler(int x, " (parameter_list) "int y);\n\n //C" (() "i" (parameter_declaration) "nt y)" (primitive_type) "nt " (identifier) ")" (,) ";" (parameter_declaration) "\n //" (primitive_type) "\n " (identifier) "/" ()) "C" (;) "a" (comment) "ates new camera look vector\n float" (declaration) "etDirection(float yaw, float pitch);\n };\n}\n" (type_identifier) "etDire" (function_declarator) "tion(float yaw, float pitch);\n };\n}\n" (identifier) "tion(float y" (parameter_list) "aw, float pitch);\n };\n}\n" (() "a" (parameter_declaration) "w, float " (primitive_type) "w, fl" (identifier) "at " (,) "p" (parameter_declaration) "tch);\n };\n}" (primitive_type) "tch);" (identifier) " };\n}" ()) "\n" (;) "" (}) "" (expression_statement) "" (;) "" (}) ""
314
2
{"language": "c", "success": true, "metadata": {"lines": 41, "avg_line_length": 28.59, "nodes": 205, "errors": 0, "source_hash": "c5f5e48a13aba5799c115cde69dee7616de67337ed60adfccd6d342fb43416ce", "categorized_nodes": 139}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "ragma once\n\nn", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 3}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "ragma o", "parent": 0, "children": [], "start_point": {"row": 0, "column": 3}, "end_point": {"row": 0, "column": 10}}, {"id": 2, "type": "preproc_arg", "text": "ce\n\n", "parent": 0, "children": [], "start_point": {"row": 0, "column": 11}, "end_point": {"row": 0, "column": 15}}, {"id": 3, "type": "function_definition", "text": "mespace RaytracingRenderer {\n\n\tclass Camera\n\t{\n\tprivate:\n\t\tfloat3 horizontal;\n\t\tfloat3 vertical;\n\n\tpublic:\n\t\tfloat aspect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n\t\tfloat fov = 1; //values between 0.0-1.15. 0.45, 0.60, and 1 are standard\n\t\tfloat3 screen_p0;\n\t\tfloat3 screen_p1;\n\t\tfloat3 screen_p2;\n\t\t// Camera position: \ud835\udc38 =(0,0,0) and view direction : \ud835\udc49 = (0, 0, 1) and up direction : U = (0, 1, 0)\n\t\tfloat3 cameraPos = float3(0, 0, 0);\n\t\tfloat3 cameraLook = float3(0, 0, -1);\n\t\tfloat3 up = float3(0, 1, 0);\n\n\t\t//Camera's view matrix\n\t\tfloat3 cameraRight = normalize(cross(up, cameraLook));\n\t\tfloat3 cameraUp = cross(cameraLook, cameraRight);\n\n\t\t//Camera's pitch + yaw\n\t\tfloat yaw = 90.f;\n\t\tfloat pitch = 0.f;\n\t\tfloat lastX, lastY;\n\n\t\tbool firstMouse = true;\n\n \t\tCamera(float3 cameraPos, float fov, float aspect_ratio);\n \t\tCamera();\n\n \t\tvoid updateCameraVectors();\n\n\t\tinline void updateFOV(float fov) {\n\t\t\tthis->fov = fov;\n\t\t}\n\t\tinline void updateAspectRatio(float aspect_ratio) {\n\t\t\tthis->aspect_ratio = aspect_ratio;\n\t\t}\n\n\t\tvoid updateViewport();\n\t\tvoid keyHandler(int key);\n\t\tvoid mouseHandler(int x, int y);\n\n\t\t//Calculates new camera look vector\n\t\tfloat3 getDirection(float yaw, float pitch);\n\t};\n}\n", "parent": null, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 51, "column": 1}}, {"id": 4, "type": "type_identifier", "text": "mespace R", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 9}}, {"id": 5, "type": "identifier", "text": "ytracingRenderer {", "parent": 3, "children": [], "start_point": {"row": 2, "column": 10}, "end_point": {"row": 2, "column": 28}}, {"id": 6, "type": "function_definition", "text": "ass Camera\n\t{\n\tprivate:\n\t\tfloat3 horizontal;\n\t\tfloat3 vertical;\n\n\tpublic:\n\t\tfloat aspect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n\t\tfloat fov = 1; //values between 0.0-1.15. 0.45, 0.60, and 1 are standard\n\t\tfloat3 screen_p0;\n\t\tfloat3 screen_p1;\n\t\tfloat3 screen_p2;\n\t\t// Camera position: \ud835\udc38 =(0,0,0) and view direction : \ud835\udc49 = (0, 0, 1) and up direction : U = (0, 1, 0)\n\t\tfloat3 cameraPos = float3(0, 0, 0);\n\t\tfloat3 cameraLook = float3(0, 0, -1);\n\t\tfloat3 up = float3(0, 1, 0);\n\n\t\t//Camera's view matrix\n\t\tfloat3 cameraRight = normalize(cross(up, cameraLook));\n\t\tfloat3 cameraUp = cross(cameraLook, cameraRight);\n\n\t\t//Camera's pitch + yaw\n\t\tfloat yaw = 90.f;\n\t\tfloat pitch = 0.f;\n\t\tfloat lastX, lastY;\n\n\t\tbool firstMouse = true;\n\n \t\tCamera(float3 cameraPos, float fov, float aspect_ratio);\n \t\tCamera();\n\n \t\tvoid updateCameraVectors();\n\n\t\tinline void updateFOV(float fov) {\n\t\t\tthis->fov = fov;\n\t\t}\n\t\tinline void updateAspectRatio(float aspect_ratio) {\n\t\t\tthis->aspect_ratio = aspect_ratio;\n\t\t}\n\n\t\tvoid updateViewport();\n\t\tvoid keyHandler(int key);\n\t\tvoid mouseHandler(int x, int y);\n\n\t\t//Calculates new camera look vector\n\t\tfloat3 getDirection(float yaw, float pitch);\n\t};\n}\n", "parent": 3, "children": [7, 8], "start_point": {"row": 4, "column": 1}, "end_point": {"row": 50, "column": 2}}, {"id": 7, "type": "type_identifier", "text": "ass C", "parent": 6, "children": [], "start_point": {"row": 4, "column": 1}, "end_point": {"row": 4, "column": 6}}, {"id": 8, "type": "identifier", "text": "mera\n\t", "parent": 6, "children": [], "start_point": {"row": 4, "column": 7}, "end_point": {"row": 4, "column": 13}}, {"id": 9, "type": "labeled_statement", "text": "ivate:\n\t\tfloat3 horizontal;\n\t", "parent": 6, "children": [10, 11], "start_point": {"row": 6, "column": 1}, "end_point": {"row": 7, "column": 20}}, {"id": 10, "type": "statement_identifier", "text": "ivate:\n", "parent": 9, "children": [], "start_point": {"row": 6, "column": 1}, "end_point": {"row": 6, "column": 8}}, {"id": 11, "type": "declaration", "text": "oat3 horizontal;\n\t", "parent": 9, "children": [12, 13], "start_point": {"row": 7, "column": 2}, "end_point": {"row": 7, "column": 20}}, {"id": 12, "type": "type_identifier", "text": "oat3 h", "parent": 11, "children": [], "start_point": {"row": 7, "column": 2}, "end_point": {"row": 7, "column": 8}}, {"id": 13, "type": "identifier", "text": "rizontal;\n", "parent": 11, "children": [], "start_point": {"row": 7, "column": 9}, "end_point": {"row": 7, "column": 19}}, {"id": 14, "type": "declaration", "text": "oat3 vertical;\n\n", "parent": 6, "children": [15, 16], "start_point": {"row": 8, "column": 2}, "end_point": {"row": 8, "column": 18}}, {"id": 15, "type": "type_identifier", "text": "oat3 v", "parent": 14, "children": [], "start_point": {"row": 8, "column": 2}, "end_point": {"row": 8, "column": 8}}, {"id": 16, "type": "identifier", "text": "rtical;\n", "parent": 14, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 17}}, {"id": 17, "type": "labeled_statement", "text": "blic:\n\t\tfloat aspect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n\t", "parent": 6, "children": [18, 19], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 11, "column": 58}}, {"id": 18, "type": "statement_identifier", "text": "blic:\n", "parent": 17, "children": [], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 7}}, {"id": 19, "type": "declaration", "text": "oat aspect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n\t", "parent": 17, "children": [20, 21], "start_point": {"row": 11, "column": 2}, "end_point": {"row": 11, "column": 58}}, {"id": 20, "type": "primitive_type", "text": "oat a", "parent": 19, "children": [], "start_point": {"row": 11, "column": 2}, "end_point": {"row": 11, "column": 7}}, {"id": 21, "type": "init_declarator", "text": "pect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n", "parent": 19, "children": [22, 23], "start_point": {"row": 11, "column": 8}, "end_point": {"row": 11, "column": 57}}, {"id": 22, "type": "identifier", "text": "pect_ratio =", "parent": 21, "children": [], "start_point": {"row": 11, "column": 8}, "end_point": {"row": 11, "column": 20}}, {"id": 23, "type": "binary_expression", "text": "loat)SCRWIDTH / (float)SCRHEIGHT;\n", "parent": 21, "children": [24, 28], "start_point": {"row": 11, "column": 23}, "end_point": {"row": 11, "column": 57}}, {"id": 24, "type": "cast_expression", "text": "loat)SCRWIDTH /", "parent": 23, "children": [25, 27], "start_point": {"row": 11, "column": 23}, "end_point": {"row": 11, "column": 38}}, {"id": 25, "type": "type_descriptor", "text": "oat)S", "parent": 24, "children": [26], "start_point": {"row": 11, "column": 24}, "end_point": {"row": 11, "column": 29}}, {"id": 26, "type": "primitive_type", "text": "oat)S", "parent": 25, "children": [], "start_point": {"row": 11, "column": 24}, "end_point": {"row": 11, "column": 29}}, {"id": 27, "type": "identifier", "text": "RWIDTH /", "parent": 24, "children": [], "start_point": {"row": 11, "column": 30}, "end_point": {"row": 11, "column": 38}}, {"id": 28, "type": "cast_expression", "text": "loat)SCRHEIGHT;\n", "parent": 23, "children": [29, 31], "start_point": {"row": 11, "column": 41}, "end_point": {"row": 11, "column": 57}}, {"id": 29, "type": "type_descriptor", "text": "oat)S", "parent": 28, "children": [30], "start_point": {"row": 11, "column": 42}, "end_point": {"row": 11, "column": 47}}, {"id": 30, "type": "primitive_type", "text": "oat)S", "parent": 29, "children": [], "start_point": {"row": 11, "column": 42}, "end_point": {"row": 11, "column": 47}}, {"id": 31, "type": "identifier", "text": "RHEIGHT;\n", "parent": 28, "children": [], "start_point": {"row": 11, "column": 48}, "end_point": {"row": 11, "column": 57}}, {"id": 32, "type": "declaration", "text": "oat fov = 1; /", "parent": 6, "children": [33, 34], "start_point": {"row": 12, "column": 2}, "end_point": {"row": 12, "column": 16}}, {"id": 33, "type": "primitive_type", "text": "oat f", "parent": 32, "children": [], "start_point": {"row": 12, "column": 2}, "end_point": {"row": 12, "column": 7}}, {"id": 34, "type": "init_declarator", "text": "v = 1; ", "parent": 32, "children": [35, 36, 37], "start_point": {"row": 12, "column": 8}, "end_point": {"row": 12, "column": 15}}, {"id": 35, "type": "identifier", "text": "v =", "parent": 34, "children": [], "start_point": {"row": 12, "column": 8}, "end_point": {"row": 12, "column": 11}}, {"id": 36, "type": "=", "text": "1", "parent": 34, "children": [], "start_point": {"row": 12, "column": 12}, "end_point": {"row": 12, "column": 13}}, {"id": 37, "type": "number_literal", "text": " ", "parent": 34, "children": [], "start_point": {"row": 12, "column": 14}, "end_point": {"row": 12, "column": 15}}, {"id": 38, "type": "declaration", "text": "oat3 screen_p0;\n\t", "parent": 6, "children": [39, 40], "start_point": {"row": 13, "column": 2}, "end_point": {"row": 13, "column": 19}}, {"id": 39, "type": "type_identifier", "text": "oat3 s", "parent": 38, "children": [], "start_point": {"row": 13, "column": 2}, "end_point": {"row": 13, "column": 8}}, {"id": 40, "type": "identifier", "text": "reen_p0;\n", "parent": 38, "children": [], "start_point": {"row": 13, "column": 9}, "end_point": {"row": 13, "column": 18}}, {"id": 41, "type": "declaration", "text": "oat3 screen_p1;\n\t", "parent": 6, "children": [42, 43], "start_point": {"row": 14, "column": 2}, "end_point": {"row": 14, "column": 19}}, {"id": 42, "type": "type_identifier", "text": "oat3 s", "parent": 41, "children": [], "start_point": {"row": 14, "column": 2}, "end_point": {"row": 14, "column": 8}}, {"id": 43, "type": "identifier", "text": "reen_p1;\n", "parent": 41, "children": [], "start_point": {"row": 14, "column": 9}, "end_point": {"row": 14, "column": 18}}, {"id": 44, "type": "declaration", "text": "oat3 screen_p2;\n\t", "parent": 6, "children": [45, 46], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 19}}, {"id": 45, "type": "type_identifier", "text": "oat3 s", "parent": 44, "children": [], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 8}}, {"id": 46, "type": "identifier", "text": "reen_p2;\n", "parent": 44, "children": [], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 18}}, {"id": 47, "type": "declaration", "text": "ameraPos = float3(0, 0, 0);\n\t\tfloat", "parent": 6, "children": [48, 49], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 17, "column": 37}}, {"id": 48, "type": "type_identifier", "text": "ameraP", "parent": 47, "children": [], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 17, "column": 8}}, {"id": 49, "type": "init_declarator", "text": "s = float3(0, 0, 0);\n\t\tfloa", "parent": 47, "children": [50, 51], "start_point": {"row": 17, "column": 9}, "end_point": {"row": 17, "column": 36}}, {"id": 50, "type": "identifier", "text": "s = float", "parent": 49, "children": [], "start_point": {"row": 17, "column": 9}, "end_point": {"row": 17, "column": 18}}, {"id": 51, "type": "call_expression", "text": ", 0, 0);\n\t\tfloa", "parent": 49, "children": [52, 53], "start_point": {"row": 17, "column": 21}, "end_point": {"row": 17, "column": 36}}, {"id": 52, "type": "identifier", "text": ", 0, 0", "parent": 51, "children": [], "start_point": {"row": 17, "column": 21}, "end_point": {"row": 17, "column": 27}}, {"id": 53, "type": "argument_list", "text": ");\n\t\tfloa", "parent": 51, "children": [54, 55], "start_point": {"row": 17, "column": 27}, "end_point": {"row": 17, "column": 36}}, {"id": 54, "type": "number_literal", "text": "\t", "parent": 53, "children": [], "start_point": {"row": 17, "column": 31}, "end_point": {"row": 17, "column": 32}}, {"id": 55, "type": "number_literal", "text": "o", "parent": 53, "children": [], "start_point": {"row": 17, "column": 34}, "end_point": {"row": 17, "column": 35}}, {"id": 56, "type": "declaration", "text": "ameraLook = float3(0, 0, -1);\n\t\tfloat", "parent": 6, "children": [57, 58], "start_point": {"row": 18, "column": 2}, "end_point": {"row": 18, "column": 39}}, {"id": 57, "type": "type_identifier", "text": "ameraL", "parent": 56, "children": [], "start_point": {"row": 18, "column": 2}, "end_point": {"row": 18, "column": 8}}, {"id": 58, "type": "init_declarator", "text": "ok = float3(0, 0, -1);\n\t\tfloa", "parent": 56, "children": [59, 60], "start_point": {"row": 18, "column": 9}, "end_point": {"row": 18, "column": 38}}, {"id": 59, "type": "identifier", "text": "ok = float", "parent": 58, "children": [], "start_point": {"row": 18, "column": 9}, "end_point": {"row": 18, "column": 19}}, {"id": 60, "type": "call_expression", "text": ", 0, -1);\n\t\tfloa", "parent": 58, "children": [61, 62], "start_point": {"row": 18, "column": 22}, "end_point": {"row": 18, "column": 38}}, {"id": 61, "type": "identifier", "text": ", 0, -", "parent": 60, "children": [], "start_point": {"row": 18, "column": 22}, "end_point": {"row": 18, "column": 28}}, {"id": 62, "type": "argument_list", "text": "1);\n\t\tfloa", "parent": 60, "children": [63, 64], "start_point": {"row": 18, "column": 28}, "end_point": {"row": 18, "column": 38}}, {"id": 63, "type": "number_literal", "text": "\t", "parent": 62, "children": [], "start_point": {"row": 18, "column": 32}, "end_point": {"row": 18, "column": 33}}, {"id": 64, "type": "number_literal", "text": "lo", "parent": 62, "children": [], "start_point": {"row": 18, "column": 35}, "end_point": {"row": 18, "column": 37}}, {"id": 65, "type": "declaration", "text": "p = float3(0, 1, 0);\n\n\t\t//Ca", "parent": 6, "children": [66, 67], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 30}}, {"id": 66, "type": "type_identifier", "text": "p = fl", "parent": 65, "children": [], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 8}}, {"id": 67, "type": "init_declarator", "text": "at3(0, 1, 0);\n\n\t\t//C", "parent": 65, "children": [68, 69], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 29}}, {"id": 68, "type": "identifier", "text": "at", "parent": 67, "children": [], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 11}}, {"id": 69, "type": "call_expression", "text": ", 1, 0);\n\n\t\t//C", "parent": 67, "children": [70, 71], "start_point": {"row": 19, "column": 14}, "end_point": {"row": 19, "column": 29}}, {"id": 70, "type": "identifier", "text": ", 1, 0", "parent": 69, "children": [], "start_point": {"row": 19, "column": 14}, "end_point": {"row": 19, "column": 20}}, {"id": 71, "type": "argument_list", "text": ");\n\n\t\t//C", "parent": 69, "children": [72, 73], "start_point": {"row": 19, "column": 20}, "end_point": {"row": 19, "column": 29}}, {"id": 72, "type": "number_literal", "text": "\t", "parent": 71, "children": [], "start_point": {"row": 19, "column": 24}, "end_point": {"row": 19, "column": 25}}, {"id": 73, "type": "number_literal", "text": "/", "parent": 71, "children": [], "start_point": {"row": 19, "column": 27}, "end_point": {"row": 19, "column": 28}}, {"id": 74, "type": "declaration", "text": "ameraRight = normalize(cross(up, cameraLook));\n\t\tfloat", "parent": 6, "children": [75, 76], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 22, "column": 56}}, {"id": 75, "type": "type_identifier", "text": "ameraR", "parent": 74, "children": [], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 22, "column": 8}}, {"id": 76, "type": "init_declarator", "text": "ght = normalize(cross(up, cameraLook));\n\t\tfloa", "parent": 74, "children": [77, 78, 79], "start_point": {"row": 22, "column": 9}, "end_point": {"row": 22, "column": 55}}, {"id": 77, "type": "identifier", "text": "ght = norma", "parent": 76, "children": [], "start_point": {"row": 22, "column": 9}, "end_point": {"row": 22, "column": 20}}, {"id": 78, "type": "=", "text": "i", "parent": 76, "children": [], "start_point": {"row": 22, "column": 21}, "end_point": {"row": 22, "column": 22}}, {"id": 79, "type": "call_expression", "text": "e(cross(up, cameraLook));\n\t\tfloa", "parent": 76, "children": [80, 81], "start_point": {"row": 22, "column": 23}, "end_point": {"row": 22, "column": 55}}, {"id": 80, "type": "identifier", "text": "e(cross(u", "parent": 79, "children": [], "start_point": {"row": 22, "column": 23}, "end_point": {"row": 22, "column": 32}}, {"id": 81, "type": "argument_list", "text": "p, cameraLook));\n\t\tfloa", "parent": 79, "children": [82], "start_point": {"row": 22, "column": 32}, "end_point": {"row": 22, "column": 55}}, {"id": 82, "type": "call_expression", "text": ", cameraLook));\n\t\tflo", "parent": 81, "children": [83, 84], "start_point": {"row": 22, "column": 33}, "end_point": {"row": 22, "column": 54}}, {"id": 83, "type": "identifier", "text": ", cam", "parent": 82, "children": [], "start_point": {"row": 22, "column": 33}, "end_point": {"row": 22, "column": 38}}, {"id": 84, "type": "argument_list", "text": "eraLook));\n\t\tflo", "parent": 82, "children": [85, 86], "start_point": {"row": 22, "column": 38}, "end_point": {"row": 22, "column": 54}}, {"id": 85, "type": "identifier", "text": "ra", "parent": 84, "children": [], "start_point": {"row": 22, "column": 39}, "end_point": {"row": 22, "column": 41}}, {"id": 86, "type": "identifier", "text": "ok));\n\t\tfl", "parent": 84, "children": [], "start_point": {"row": 22, "column": 43}, "end_point": {"row": 22, "column": 53}}, {"id": 87, "type": "declaration", "text": "ameraUp = cross(cameraLook, cameraRight);\n\n\t\t//Ca", "parent": 6, "children": [88, 89], "start_point": {"row": 23, "column": 2}, "end_point": {"row": 23, "column": 51}}, {"id": 88, "type": "type_identifier", "text": "ameraU", "parent": 87, "children": [], "start_point": {"row": 23, "column": 2}, "end_point": {"row": 23, "column": 8}}, {"id": 89, "type": "init_declarator", "text": " = cross(cameraLook, cameraRight);\n\n\t\t//C", "parent": 87, "children": [90, 91, 92], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 50}}, {"id": 90, "type": "identifier", "text": " = cross", "parent": 89, "children": [], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 17}}, {"id": 91, "type": "=", "text": "c", "parent": 89, "children": [], "start_point": {"row": 23, "column": 18}, "end_point": {"row": 23, "column": 19}}, {"id": 92, "type": "call_expression", "text": "meraLook, cameraRight);\n\n\t\t//C", "parent": 89, "children": [93, 94], "start_point": {"row": 23, "column": 20}, "end_point": {"row": 23, "column": 50}}, {"id": 93, "type": "identifier", "text": "meraL", "parent": 92, "children": [], "start_point": {"row": 23, "column": 20}, "end_point": {"row": 23, "column": 25}}, {"id": 94, "type": "argument_list", "text": "ook, cameraRight);\n\n\t\t//C", "parent": 92, "children": [95, 96], "start_point": {"row": 23, "column": 25}, "end_point": {"row": 23, "column": 50}}, {"id": 95, "type": "identifier", "text": "ok, camera", "parent": 94, "children": [], "start_point": {"row": 23, "column": 26}, "end_point": {"row": 23, "column": 36}}, {"id": 96, "type": "identifier", "text": "ght);\n\n\t\t//", "parent": 94, "children": [], "start_point": {"row": 23, "column": 38}, "end_point": {"row": 23, "column": 49}}, {"id": 97, "type": "declaration", "text": "w = 90.f;\n\t\tfloat", "parent": 6, "children": [98, 99], "start_point": {"row": 26, "column": 2}, "end_point": {"row": 26, "column": 19}}, {"id": 98, "type": "primitive_type", "text": "w = 9", "parent": 97, "children": [], "start_point": {"row": 26, "column": 2}, "end_point": {"row": 26, "column": 7}}, {"id": 99, "type": "init_declarator", "text": ".f;\n\t\tfloa", "parent": 97, "children": [100, 101, 102], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 18}}, {"id": 100, "type": "identifier", "text": ".f;", "parent": 99, "children": [], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 11}}, {"id": 101, "type": "=", "text": "\t", "parent": 99, "children": [], "start_point": {"row": 26, "column": 12}, "end_point": {"row": 26, "column": 13}}, {"id": 102, "type": "number_literal", "text": "floa", "parent": 99, "children": [], "start_point": {"row": 26, "column": 14}, "end_point": {"row": 26, "column": 18}}, {"id": 103, "type": "declaration", "text": "tch = 0.f;\n\t\tfloat", "parent": 6, "children": [104, 105], "start_point": {"row": 27, "column": 2}, "end_point": {"row": 27, "column": 20}}, {"id": 104, "type": "primitive_type", "text": "tch =", "parent": 103, "children": [], "start_point": {"row": 27, "column": 2}, "end_point": {"row": 27, "column": 7}}, {"id": 105, "type": "init_declarator", "text": "0.f;\n\t\tfloa", "parent": 103, "children": [106, 107, 108], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 19}}, {"id": 106, "type": "identifier", "text": "0.f;\n", "parent": 105, "children": [], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 13}}, {"id": 107, "type": "=", "text": "\t", "parent": 105, "children": [], "start_point": {"row": 27, "column": 14}, "end_point": {"row": 27, "column": 15}}, {"id": 108, "type": "number_literal", "text": "loa", "parent": 105, "children": [], "start_point": {"row": 27, "column": 16}, "end_point": {"row": 27, "column": 19}}, {"id": 109, "type": "declaration", "text": "stX, lastY;\n\n\t\tbool", "parent": 6, "children": [110, 111, 112], "start_point": {"row": 28, "column": 2}, "end_point": {"row": 28, "column": 21}}, {"id": 110, "type": "primitive_type", "text": "stX, ", "parent": 109, "children": [], "start_point": {"row": 28, "column": 2}, "end_point": {"row": 28, "column": 7}}, {"id": 111, "type": "identifier", "text": "astY;", "parent": 109, "children": [], "start_point": {"row": 28, "column": 8}, "end_point": {"row": 28, "column": 13}}, {"id": 112, "type": "identifier", "text": "\t\tboo", "parent": 109, "children": [], "start_point": {"row": 28, "column": 15}, "end_point": {"row": 28, "column": 20}}, {"id": 113, "type": "declaration", "text": "stMouse = true;\n\n \t\tCam", "parent": 6, "children": [114, 115], "start_point": {"row": 30, "column": 2}, "end_point": {"row": 30, "column": 25}}, {"id": 114, "type": "primitive_type", "text": "stMo", "parent": 113, "children": [], "start_point": {"row": 30, "column": 2}, "end_point": {"row": 30, "column": 6}}, {"id": 115, "type": "init_declarator", "text": "se = true;\n\n \t\tCa", "parent": 113, "children": [116, 117, 118], "start_point": {"row": 30, "column": 7}, "end_point": {"row": 30, "column": 24}}, {"id": 116, "type": "identifier", "text": "se = true;", "parent": 115, "children": [], "start_point": {"row": 30, "column": 7}, "end_point": {"row": 30, "column": 17}}, {"id": 117, "type": "=", "text": "\n", "parent": 115, "children": [], "start_point": {"row": 30, "column": 18}, "end_point": {"row": 30, "column": 19}}, {"id": 118, "type": "true", "text": "\t\tCa", "parent": 115, "children": [], "start_point": {"row": 30, "column": 20}, "end_point": {"row": 30, "column": 24}}, {"id": 119, "type": "declaration", "text": "loat3 cameraPos, float fov, float aspect_ratio);\n \t\tCame", "parent": 6, "children": [120, 124, 125, 126, 128, 129], "start_point": {"row": 32, "column": 3}, "end_point": {"row": 32, "column": 59}}, {"id": 120, "type": "macro_type_specifier", "text": "loat3 cameraP", "parent": 119, "children": [121, 122], "start_point": {"row": 32, "column": 3}, "end_point": {"row": 32, "column": 16}}, {"id": 121, "type": "identifier", "text": "loat3 ", "parent": 120, "children": [], "start_point": {"row": 32, "column": 3}, "end_point": {"row": 32, "column": 9}}, {"id": 122, "type": "type_descriptor", "text": "ameraP", "parent": 120, "children": [123], "start_point": {"row": 32, "column": 10}, "end_point": {"row": 32, "column": 16}}, {"id": 123, "type": "type_identifier", "text": "ameraP", "parent": 122, "children": [], "start_point": {"row": 32, "column": 10}, "end_point": {"row": 32, "column": 16}}, {"id": 124, "type": "identifier", "text": "s, float ", "parent": 119, "children": [], "start_point": {"row": 32, "column": 17}, "end_point": {"row": 32, "column": 26}}, {"id": 125, "type": "identifier", "text": "v, fl", "parent": 119, "children": [], "start_point": {"row": 32, "column": 28}, "end_point": {"row": 32, "column": 33}}, {"id": 126, "type": "ERROR", "text": "at ", "parent": 119, "children": [127], "start_point": {"row": 32, "column": 34}, "end_point": {"row": 32, "column": 37}}, {"id": 127, "type": "identifier", "text": "at ", "parent": 126, "children": [], "start_point": {"row": 32, "column": 34}, "end_point": {"row": 32, "column": 37}}, {"id": 128, "type": "identifier", "text": "pect_", "parent": 119, "children": [], "start_point": {"row": 32, "column": 39}, "end_point": {"row": 32, "column": 44}}, {"id": 129, "type": "ERROR", "text": "atio);\n \t\tCam", "parent": 119, "children": [130], "start_point": {"row": 32, "column": 45}, "end_point": {"row": 32, "column": 58}}, {"id": 130, "type": "identifier", "text": "atio);\n \t\tCa", "parent": 129, "children": [], "start_point": {"row": 32, "column": 45}, "end_point": {"row": 32, "column": 57}}, {"id": 131, "type": "call_expression", "text": ";\n\n \t\tvo", "parent": 6, "children": [132], "start_point": {"row": 33, "column": 3}, "end_point": {"row": 33, "column": 11}}, {"id": 132, "type": "argument_list", "text": "vo", "parent": 131, "children": [], "start_point": {"row": 33, "column": 9}, "end_point": {"row": 33, "column": 11}}, {"id": 133, "type": "declaration", "text": "ateCameraVectors();\n\n\t\tinli", "parent": 6, "children": [134, 135], "start_point": {"row": 35, "column": 3}, "end_point": {"row": 35, "column": 30}}, {"id": 134, "type": "primitive_type", "text": "ateC", "parent": 133, "children": [], "start_point": {"row": 35, "column": 3}, "end_point": {"row": 35, "column": 7}}, {"id": 135, "type": "function_declarator", "text": "meraVectors();\n\n\t\tinl", "parent": 133, "children": [136, 137], "start_point": {"row": 35, "column": 8}, "end_point": {"row": 35, "column": 29}}, {"id": 136, "type": "identifier", "text": "meraVectors();\n\n\t\ti", "parent": 135, "children": [], "start_point": {"row": 35, "column": 8}, "end_point": {"row": 35, "column": 27}}, {"id": 137, "type": "parameter_list", "text": "nl", "parent": 135, "children": [], "start_point": {"row": 35, "column": 27}, "end_point": {"row": 35, "column": 29}}, {"id": 138, "type": "function_definition", "text": "oid updateFOV(float fov) {\n\t\t\tthis->fov = fov;\n\t\t}\n\t\tinlin", "parent": 6, "children": [139, 141, 142], "start_point": {"row": 37, "column": 2}, "end_point": {"row": 39, "column": 3}}, {"id": 139, "type": "storage_class_specifier", "text": "oid up", "parent": 138, "children": [140], "start_point": {"row": 37, "column": 2}, "end_point": {"row": 37, "column": 8}}, {"id": 140, "type": "inline", "text": "oid up", "parent": 139, "children": [], "start_point": {"row": 37, "column": 2}, "end_point": {"row": 37, "column": 8}}, {"id": 141, "type": "primitive_type", "text": "ateF", "parent": 138, "children": [], "start_point": {"row": 37, "column": 9}, "end_point": {"row": 37, "column": 13}}, {"id": 142, "type": "function_declarator", "text": "V(float fov) {\n\t\t\tth", "parent": 138, "children": [143, 144], "start_point": {"row": 37, "column": 14}, "end_point": {"row": 37, "column": 34}}, {"id": 143, "type": "identifier", "text": "V(float f", "parent": 142, "children": [], "start_point": {"row": 37, "column": 14}, "end_point": {"row": 37, "column": 23}}, {"id": 144, "type": "parameter_list", "text": "ov) {\n\t\t\tth", "parent": 142, "children": [145], "start_point": {"row": 37, "column": 23}, "end_point": {"row": 37, "column": 34}}, {"id": 145, "type": "parameter_declaration", "text": "v) {\n\t\t\tt", "parent": 144, "children": [146, 147], "start_point": {"row": 37, "column": 24}, "end_point": {"row": 37, "column": 33}}, {"id": 146, "type": "primitive_type", "text": "v) {\n", "parent": 145, "children": [], "start_point": {"row": 37, "column": 24}, "end_point": {"row": 37, "column": 29}}, {"id": 147, "type": "identifier", "text": "\t\tt", "parent": 145, "children": [], "start_point": {"row": 37, "column": 30}, "end_point": {"row": 37, "column": 33}}, {"id": 148, "type": "assignment_expression", "text": "v = fov;\n\t\t}\n\t\t", "parent": 138, "children": [149, 153, 154], "start_point": {"row": 38, "column": 3}, "end_point": {"row": 38, "column": 18}}, {"id": 149, "type": "field_expression", "text": "v = fov;\n", "parent": 148, "children": [150, 151, 152], "start_point": {"row": 38, "column": 3}, "end_point": {"row": 38, "column": 12}}, {"id": 150, "type": "identifier", "text": "v = ", "parent": 149, "children": [], "start_point": {"row": 38, "column": 3}, "end_point": {"row": 38, "column": 7}}, {"id": 151, "type": "->", "text": "fo", "parent": 149, "children": [], "start_point": {"row": 38, "column": 7}, "end_point": {"row": 38, "column": 9}}, {"id": 152, "type": "field_identifier", "text": "v;\n", "parent": 149, "children": [], "start_point": {"row": 38, "column": 9}, "end_point": {"row": 38, "column": 12}}, {"id": 153, "type": "=", "text": "\t", "parent": 148, "children": [], "start_point": {"row": 38, "column": 13}, "end_point": {"row": 38, "column": 14}}, {"id": 154, "type": "identifier", "text": "\n\t\t", "parent": 148, "children": [], "start_point": {"row": 38, "column": 15}, "end_point": {"row": 38, "column": 18}}, {"id": 155, "type": "function_definition", "text": "oid updateAspectRatio(float aspect_ratio) {\n\t\t\tthis->aspect_ratio = aspect_ratio;\n\t\t}\n\n\t\tvoid", "parent": 6, "children": [156, 158, 159], "start_point": {"row": 40, "column": 2}, "end_point": {"row": 42, "column": 3}}, {"id": 156, "type": "storage_class_specifier", "text": "oid up", "parent": 155, "children": [157], "start_point": {"row": 40, "column": 2}, "end_point": {"row": 40, "column": 8}}, {"id": 157, "type": "inline", "text": "oid up", "parent": 156, "children": [], "start_point": {"row": 40, "column": 2}, "end_point": {"row": 40, "column": 8}}, {"id": 158, "type": "primitive_type", "text": "ateA", "parent": 155, "children": [], "start_point": {"row": 40, "column": 9}, "end_point": {"row": 40, "column": 13}}, {"id": 159, "type": "function_declarator", "text": "pectRatio(float aspect_ratio) {\n\t\t\tth", "parent": 155, "children": [160, 161], "start_point": {"row": 40, "column": 14}, "end_point": {"row": 40, "column": 51}}, {"id": 160, "type": "identifier", "text": "pectRatio(float a", "parent": 159, "children": [], "start_point": {"row": 40, "column": 14}, "end_point": {"row": 40, "column": 31}}, {"id": 161, "type": "parameter_list", "text": "spect_ratio) {\n\t\t\tth", "parent": 159, "children": [162], "start_point": {"row": 40, "column": 31}, "end_point": {"row": 40, "column": 51}}, {"id": 162, "type": "parameter_declaration", "text": "pect_ratio) {\n\t\t\tt", "parent": 161, "children": [163, 164], "start_point": {"row": 40, "column": 32}, "end_point": {"row": 40, "column": 50}}, {"id": 163, "type": "primitive_type", "text": "pect_", "parent": 162, "children": [], "start_point": {"row": 40, "column": 32}, "end_point": {"row": 40, "column": 37}}, {"id": 164, "type": "identifier", "text": "atio) {\n\t\t\tt", "parent": 162, "children": [], "start_point": {"row": 40, "column": 38}, "end_point": {"row": 40, "column": 50}}, {"id": 165, "type": "assignment_expression", "text": "pect_ratio = aspect_ratio;\n\t\t}\n\n\t", "parent": 155, "children": [166, 170, 171], "start_point": {"row": 41, "column": 3}, "end_point": {"row": 41, "column": 36}}, {"id": 166, "type": "field_expression", "text": "pect_ratio = aspec", "parent": 165, "children": [167, 168, 169], "start_point": {"row": 41, "column": 3}, "end_point": {"row": 41, "column": 21}}, {"id": 167, "type": "identifier", "text": "pect", "parent": 166, "children": [], "start_point": {"row": 41, "column": 3}, "end_point": {"row": 41, "column": 7}}, {"id": 168, "type": "->", "text": "_r", "parent": 166, "children": [], "start_point": {"row": 41, "column": 7}, "end_point": {"row": 41, "column": 9}}, {"id": 169, "type": "field_identifier", "text": "atio = aspec", "parent": 166, "children": [], "start_point": {"row": 41, "column": 9}, "end_point": {"row": 41, "column": 21}}, {"id": 170, "type": "=", "text": "_", "parent": 165, "children": [], "start_point": {"row": 41, "column": 22}, "end_point": {"row": 41, "column": 23}}, {"id": 171, "type": "identifier", "text": "atio;\n\t\t}\n\n\t", "parent": 165, "children": [], "start_point": {"row": 41, "column": 24}, "end_point": {"row": 41, "column": 36}}, {"id": 172, "type": "declaration", "text": "ateViewport();\n\t\tvoid ", "parent": 6, "children": [173, 174], "start_point": {"row": 44, "column": 2}, "end_point": {"row": 44, "column": 24}}, {"id": 173, "type": "primitive_type", "text": "ateV", "parent": 172, "children": [], "start_point": {"row": 44, "column": 2}, "end_point": {"row": 44, "column": 6}}, {"id": 174, "type": "function_declarator", "text": "ewport();\n\t\tvoid", "parent": 172, "children": [175, 176], "start_point": {"row": 44, "column": 7}, "end_point": {"row": 44, "column": 23}}, {"id": 175, "type": "identifier", "text": "ewport();\n\t\tvo", "parent": 174, "children": [], "start_point": {"row": 44, "column": 7}, "end_point": {"row": 44, "column": 21}}, {"id": 176, "type": "parameter_list", "text": "id", "parent": 174, "children": [], "start_point": {"row": 44, "column": 21}, "end_point": {"row": 44, "column": 23}}, {"id": 177, "type": "declaration", "text": "Handler(int key);\n\t\tvoid ", "parent": 6, "children": [178, 179], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 27}}, {"id": 178, "type": "primitive_type", "text": "Hand", "parent": 177, "children": [], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 6}}, {"id": 179, "type": "function_declarator", "text": "er(int key);\n\t\tvoid", "parent": 177, "children": [180, 181], "start_point": {"row": 45, "column": 7}, "end_point": {"row": 45, "column": 26}}, {"id": 180, "type": "identifier", "text": "er(int key", "parent": 179, "children": [], "start_point": {"row": 45, "column": 7}, "end_point": {"row": 45, "column": 17}}, {"id": 181, "type": "parameter_list", "text": ");\n\t\tvoid", "parent": 179, "children": [182], "start_point": {"row": 45, "column": 17}, "end_point": {"row": 45, "column": 26}}, {"id": 182, "type": "parameter_declaration", "text": ";\n\t\tvoi", "parent": 181, "children": [183], "start_point": {"row": 45, "column": 18}, "end_point": {"row": 45, "column": 25}}, {"id": 183, "type": "identifier", "text": "voi", "parent": 182, "children": [], "start_point": {"row": 45, "column": 22}, "end_point": {"row": 45, "column": 25}}, {"id": 184, "type": "declaration", "text": "seHandler(int x, int y);\n\n\t\t//Ca", "parent": 6, "children": [185, 186], "start_point": {"row": 46, "column": 2}, "end_point": {"row": 46, "column": 34}}, {"id": 185, "type": "primitive_type", "text": "seHa", "parent": 184, "children": [], "start_point": {"row": 46, "column": 2}, "end_point": {"row": 46, "column": 6}}, {"id": 186, "type": "function_declarator", "text": "dler(int x, int y);\n\n\t\t//C", "parent": 184, "children": [187, 188], "start_point": {"row": 46, "column": 7}, "end_point": {"row": 46, "column": 33}}, {"id": 187, "type": "identifier", "text": "dler(int x, ", "parent": 186, "children": [], "start_point": {"row": 46, "column": 7}, "end_point": {"row": 46, "column": 19}}, {"id": 188, "type": "parameter_list", "text": "int y);\n\n\t\t//C", "parent": 186, "children": [189, 191], "start_point": {"row": 46, "column": 19}, "end_point": {"row": 46, "column": 33}}, {"id": 189, "type": "parameter_declaration", "text": "nt y)", "parent": 188, "children": [190], "start_point": {"row": 46, "column": 20}, "end_point": {"row": 46, "column": 25}}, {"id": 190, "type": "primitive_type", "text": "nt ", "parent": 189, "children": [], "start_point": {"row": 46, "column": 20}, "end_point": {"row": 46, "column": 23}}, {"id": 191, "type": "parameter_declaration", "text": "\n\t\t//", "parent": 188, "children": [192, 193], "start_point": {"row": 46, "column": 27}, "end_point": {"row": 46, "column": 32}}, {"id": 192, "type": "primitive_type", "text": "\n\t\t", "parent": 191, "children": [], "start_point": {"row": 46, "column": 27}, "end_point": {"row": 46, "column": 30}}, {"id": 193, "type": "identifier", "text": "/", "parent": 191, "children": [], "start_point": {"row": 46, "column": 31}, "end_point": {"row": 46, "column": 32}}, {"id": 194, "type": "declaration", "text": "etDirection(float yaw, float pitch);\n\t};\n}\n", "parent": 6, "children": [195, 196], "start_point": {"row": 49, "column": 2}, "end_point": {"row": 49, "column": 46}}, {"id": 195, "type": "type_identifier", "text": "etDire", "parent": 194, "children": [], "start_point": {"row": 49, "column": 2}, "end_point": {"row": 49, "column": 8}}, {"id": 196, "type": "function_declarator", "text": "tion(float yaw, float pitch);\n\t};\n}\n", "parent": 194, "children": [197, 198], "start_point": {"row": 49, "column": 9}, "end_point": {"row": 49, "column": 45}}, {"id": 197, "type": "identifier", "text": "tion(float y", "parent": 196, "children": [], "start_point": {"row": 49, "column": 9}, "end_point": {"row": 49, "column": 21}}, {"id": 198, "type": "parameter_list", "text": "aw, float pitch);\n\t};\n}\n", "parent": 196, "children": [199, 202], "start_point": {"row": 49, "column": 21}, "end_point": {"row": 49, "column": 45}}, {"id": 199, "type": "parameter_declaration", "text": "w, float ", "parent": 198, "children": [200, 201], "start_point": {"row": 49, "column": 22}, "end_point": {"row": 49, "column": 31}}, {"id": 200, "type": "primitive_type", "text": "w, fl", "parent": 199, "children": [], "start_point": {"row": 49, "column": 22}, "end_point": {"row": 49, "column": 27}}, {"id": 201, "type": "identifier", "text": "at ", "parent": 199, "children": [], "start_point": {"row": 49, "column": 28}, "end_point": {"row": 49, "column": 31}}, {"id": 202, "type": "parameter_declaration", "text": "tch);\n\t};\n}", "parent": 198, "children": [203, 204], "start_point": {"row": 49, "column": 33}, "end_point": {"row": 49, "column": 44}}, {"id": 203, "type": "primitive_type", "text": "tch);", "parent": 202, "children": [], "start_point": {"row": 49, "column": 33}, "end_point": {"row": 49, "column": 38}}, {"id": 204, "type": "identifier", "text": "\t};\n}", "parent": 202, "children": [], "start_point": {"row": 49, "column": 39}, "end_point": {"row": 49, "column": 44}}]}, "node_categories": {"declarations": {"functions": [3, 6, 135, 138, 142, 155, 159, 174, 179, 186, 196], "variables": [11, 14, 19, 32, 38, 41, 44, 47, 56, 65, 74, 87, 97, 103, 109, 113, 119, 133, 145, 162, 172, 177, 182, 184, 189, 191, 194, 199, 202], "classes": [139, 156], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [23, 24, 28, 51, 60, 69, 79, 82, 92, 131, 149, 166], "assignments": [148, 165], "loops": [], "conditionals": [4, 5, 7, 8, 10, 12, 13, 15, 16, 18, 22, 27, 31, 35, 39, 40, 42, 43, 45, 46, 48, 50, 52, 57, 59, 61, 66, 68, 70, 75, 77, 80, 83, 85, 86, 88, 90, 93, 95, 96, 100, 106, 111, 112, 116, 120, 121, 123, 124, 125, 127, 128, 130, 136, 143, 147, 150, 152, 154, 160, 164, 167, 169, 171, 175, 180, 183, 187, 193, 195, 197, 201, 204], "returns": [], "exceptions": []}, "expressions": {"calls": [0], "literals": [37, 54, 55, 63, 64, 72, 73, 102, 108], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 3, "universal_type": "function", "name": "Camera", "text_snippet": "mespace RaytracingRenderer {\n\n\tclass Camera\n\t{\n\tprivate:\n\t\tfloat3 horizontal;\n\t\tfloat3 vertical;\n\n\tp"}, {"node_id": 6, "universal_type": "function", "name": "firstMouse", "text_snippet": "ass Camera\n\t{\n\tprivate:\n\t\tfloat3 horizontal;\n\t\tfloat3 vertical;\n\n\tpublic:\n\t\tfloat aspect_ratio = (fl"}, {"node_id": 135, "universal_type": "function", "name": "unknown", "text_snippet": "meraVectors();\n\n\t\tinl"}, {"node_id": 138, "universal_type": "function", "name": "unknown", "text_snippet": "oid updateFOV(float fov) {\n\t\t\tthis->fov = fov;\n\t\t}\n\t\tinlin"}, {"node_id": 142, "universal_type": "function", "name": "unknown", "text_snippet": "V(float fov) {\n\t\t\tth"}, {"node_id": 155, "universal_type": "function", "name": "unknown", "text_snippet": "oid updateAspectRatio(float aspect_ratio) {\n\t\t\tthis->aspect_ratio = aspect_ratio;\n\t\t}\n\n\t\tvoid"}, {"node_id": 159, "universal_type": "function", "name": "unknown", "text_snippet": "pectRatio(float aspect_ratio) {\n\t\t\tth"}, {"node_id": 174, "universal_type": "function", "name": "unknown", "text_snippet": "ewport();\n\t\tvoid"}, {"node_id": 179, "universal_type": "function", "name": "unknown", "text_snippet": "er(int key);\n\t\tvoid"}, {"node_id": 186, "universal_type": "function", "name": "y);", "text_snippet": "dler(int x, int y);\n\n\t\t//C"}, {"node_id": 196, "universal_type": "function", "name": "unknown", "text_snippet": "tion(float yaw, float pitch);\n\t};\n}\n"}], "class_declarations": [{"node_id": 139, "universal_type": "class", "name": "unknown", "text_snippet": "oid up"}, {"node_id": 156, "universal_type": "class", "name": "unknown", "text_snippet": "oid up"}], "import_statements": []}, "original_source_code": "\ufeff#pragma once\n\nnamespace RaytracingRenderer {\n\n\tclass Camera\n\t{\n\tprivate:\n\t\tfloat3 horizontal;\n\t\tfloat3 vertical;\n\n\tpublic:\n\t\tfloat aspect_ratio = (float)SCRWIDTH / (float)SCRHEIGHT;\n\t\tfloat fov = 1; //values between 0.0-1.15. 0.45, 0.60, and 1 are standard\n\t\tfloat3 screen_p0;\n\t\tfloat3 screen_p1;\n\t\tfloat3 screen_p2;\n\t\t// Camera position: \ud835\udc38 =(0,0,0) and view direction : \ud835\udc49 = (0, 0, 1) and up direction : U = (0, 1, 0)\n\t\tfloat3 cameraPos = float3(0, 0, 0);\n\t\tfloat3 cameraLook = float3(0, 0, -1);\n\t\tfloat3 up = float3(0, 1, 0);\n\n\t\t//Camera's view matrix\n\t\tfloat3 cameraRight = normalize(cross(up, cameraLook));\n\t\tfloat3 cameraUp = cross(cameraLook, cameraRight);\n\n\t\t//Camera's pitch + yaw\n\t\tfloat yaw = 90.f;\n\t\tfloat pitch = 0.f;\n\t\tfloat lastX, lastY;\n\n\t\tbool firstMouse = true;\n\n \t\tCamera(float3 cameraPos, float fov, float aspect_ratio);\n \t\tCamera();\n\n \t\tvoid updateCameraVectors();\n\n\t\tinline void updateFOV(float fov) {\n\t\t\tthis->fov = fov;\n\t\t}\n\t\tinline void updateAspectRatio(float aspect_ratio) {\n\t\t\tthis->aspect_ratio = aspect_ratio;\n\t\t}\n\n\t\tvoid updateViewport();\n\t\tvoid keyHandler(int key);\n\t\tvoid mouseHandler(int x, int y);\n\n\t\t//Calculates new camera look vector\n\t\tfloat3 getDirection(float yaw, float pitch);\n\t};\n}\n"}
80,561
c
#define TEST_NAME "shorthash" #include "cmptest.h" #define MAXLEN 64 int main(void) { unsigned char in[MAXLEN]; unsigned char out[crypto_shorthash_BYTES]; unsigned char k[crypto_shorthash_KEYBYTES]; size_t i; size_t j; for (i = 0; i < crypto_shorthash_KEYBYTES; ++i) { k[i] = (unsigned char) i; } for (i = 0; i < MAXLEN; ++i) { in[i] = (unsigned char) i; crypto_shorthash(out, in, (unsigned long long) i, k); for (j = 0; j < crypto_shorthash_BYTES; ++j) { printf("%02x", (unsigned int) out[j]); } printf("\n"); } assert(crypto_shorthash_bytes() > 0); assert(crypto_shorthash_keybytes() > 0); assert(strcmp(crypto_shorthash_primitive(), "siphash24") == 0); assert(crypto_shorthash_bytes() == crypto_shorthash_siphash24_bytes()); assert(crypto_shorthash_keybytes() == crypto_shorthash_siphash24_keybytes()); return 0; }
28.41
34
(translation_unit) "#define TEST_NAME "shorthash" \n#include "cmptest.h" \n \n#define MAXLEN 64 \n \nint \nmain(void) \n{ \n unsigned char in[MAXLEN]; \n unsigned char out[crypto_shorthash_BYTES]; \n unsigned char k[crypto_shorthash_KEYBYTES]; \n size_t i; \n size_t j; \n \n for (i = 0; i < crypto_shorthash_KEYBYTES; ++i) { \n k[i] = (unsigned char) i; \n } \n for (i = 0; i < MAXLEN; ++i) { \n in[i] = (unsigned char) i; \n crypto_shorthash(out, in, (unsigned long long) i, k); \n for (j = 0; j < crypto_shorthash_BYTES; ++j) { \n printf("%02x", (unsigned int) out[j]); \n } \n printf("\n"); \n } \n assert(crypto_shorthash_bytes() > 0); \n assert(crypto_shorthash_keybytes() > 0); \n assert(strcmp(crypto_shorthash_primitive(), "siphash24") == 0); \n assert(crypto_shorthash_bytes() == crypto_shorthash_siphash24_bytes()); \n assert(crypto_shorthash_keybytes() == \n crypto_shorthash_siphash24_keybytes()); \n \n return 0; \n} \n" (preproc_def) "#define TEST_NAME "shorthash" \n" (#define) "#define" (identifier) "TEST_NAME" (preproc_arg) ""shorthash" " (preproc_include) "#include "cmptest.h" \n" (#include) "#include" (string_literal) ""cmptest.h"" (") """ (string_content) "cmptest.h" (") """ (preproc_def) "#define MAXLEN 64 \n" (#define) "#define" (identifier) "MAXLEN" (preproc_arg) "64 " (function_definition) "int \nmain(void) \n{ \n unsigned char in[MAXLEN]; \n unsigned char out[crypto_shorthash_BYTES]; \n unsigned char k[crypto_shorthash_KEYBYTES]; \n size_t i; \n size_t j; \n \n for (i = 0; i < crypto_shorthash_KEYBYTES; ++i) { \n k[i] = (unsigned char) i; \n } \n for (i = 0; i < MAXLEN; ++i) { \n in[i] = (unsigned char) i; \n crypto_shorthash(out, in, (unsigned long long) i, k); \n for (j = 0; j < crypto_shorthash_BYTES; ++j) { \n printf("%02x", (unsigned int) out[j]); \n } \n printf("\n"); \n } \n assert(crypto_shorthash_bytes() > 0); \n assert(crypto_shorthash_keybytes() > 0); \n assert(strcmp(crypto_shorthash_primitive(), "siphash24") == 0); \n assert(crypto_shorthash_bytes() == crypto_shorthash_siphash24_bytes()); \n assert(crypto_shorthash_keybytes() == \n crypto_shorthash_siphash24_keybytes()); \n \n return 0; \n}" (primitive_type) "int" (function_declarator) "main(void)" (identifier) "main" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (compound_statement) "{ \n unsigned char in[MAXLEN]; \n unsigned char out[crypto_shorthash_BYTES]; \n unsigned char k[crypto_shorthash_KEYBYTES]; \n size_t i; \n size_t j; \n \n for (i = 0; i < crypto_shorthash_KEYBYTES; ++i) { \n k[i] = (unsigned char) i; \n } \n for (i = 0; i < MAXLEN; ++i) { \n in[i] = (unsigned char) i; \n crypto_shorthash(out, in, (unsigned long long) i, k); \n for (j = 0; j < crypto_shorthash_BYTES; ++j) { \n printf("%02x", (unsigned int) out[j]); \n } \n printf("\n"); \n } \n assert(crypto_shorthash_bytes() > 0); \n assert(crypto_shorthash_keybytes() > 0); \n assert(strcmp(crypto_shorthash_primitive(), "siphash24") == 0); \n assert(crypto_shorthash_bytes() == crypto_shorthash_siphash24_bytes()); \n assert(crypto_shorthash_keybytes() == \n crypto_shorthash_siphash24_keybytes()); \n \n return 0; \n}" ({) "{" (declaration) "unsigned char in[MAXLEN];" (sized_type_specifier) "unsigned char" (unsigned) "unsigned" (primitive_type) "char" (array_declarator) "in[MAXLEN]" (identifier) "in" ([) "[" (identifier) "MAXLEN" (]) "]" (;) ";" (declaration) "unsigned char out[crypto_shorthash_BYTES];" (sized_type_specifier) "unsigned char" (unsigned) "unsigned" (primitive_type) "char" (array_declarator) "out[crypto_shorthash_BYTES]" (identifier) "out" ([) "[" (identifier) "crypto_shorthash_BYTES" (]) "]" (;) ";" (declaration) "unsigned char k[crypto_shorthash_KEYBYTES];" (sized_type_specifier) "unsigned char" (unsigned) "unsigned" (primitive_type) "char" (array_declarator) "k[crypto_shorthash_KEYBYTES]" (identifier) "k" ([) "[" (identifier) "crypto_shorthash_KEYBYTES" (]) "]" (;) ";" (declaration) "size_t i;" (primitive_type) "size_t" (identifier) "i" (;) ";" (declaration) "size_t j;" (primitive_type) "size_t" (identifier) "j" (;) ";" (for_statement) "for (i = 0; i < crypto_shorthash_KEYBYTES; ++i) { \n k[i] = (unsigned char) i; \n }" (for) "for" (() "(" (assignment_expression) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i < crypto_shorthash_KEYBYTES" (identifier) "i" (<) "<" (identifier) "crypto_shorthash_KEYBYTES" (;) ";" (update_expression) "++i" (++) "++" (identifier) "i" ()) ")" (compound_statement) "{ \n k[i] = (unsigned char) i; \n }" ({) "{" (expression_statement) "k[i] = (unsigned char) i;" (assignment_expression) "k[i] = (unsigned char) i" (subscript_expression) "k[i]" (identifier) "k" ([) "[" (identifier) "i" (]) "]" (=) "=" (cast_expression) "(unsigned char) i" (() "(" (type_descriptor) "unsigned char" (sized_type_specifier) "unsigned char" (unsigned) "unsigned" (primitive_type) "char" ()) ")" (identifier) "i" (;) ";" (}) "}" (for_statement) "for (i = 0; i < MAXLEN; ++i) { \n in[i] = (unsigned char) i; \n crypto_shorthash(out, in, (unsigned long long) i, k); \n for (j = 0; j < crypto_shorthash_BYTES; ++j) { \n printf("%02x", (unsigned int) out[j]); \n } \n printf("\n"); \n }" (for) "for" (() "(" (assignment_expression) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i < MAXLEN" (identifier) "i" (<) "<" (identifier) "MAXLEN" (;) ";" (update_expression) "++i" (++) "++" (identifier) "i" ()) ")" (compound_statement) "{ \n in[i] = (unsigned char) i; \n crypto_shorthash(out, in, (unsigned long long) i, k); \n for (j = 0; j < crypto_shorthash_BYTES; ++j) { \n printf("%02x", (unsigned int) out[j]); \n } \n printf("\n"); \n }" ({) "{" (expression_statement) "in[i] = (unsigned char) i;" (assignment_expression) "in[i] = (unsigned char) i" (subscript_expression) "in[i]" (identifier) "in" ([) "[" (identifier) "i" (]) "]" (=) "=" (cast_expression) "(unsigned char) i" (() "(" (type_descriptor) "unsigned char" (sized_type_specifier) "unsigned char" (unsigned) "unsigned" (primitive_type) "char" ()) ")" (identifier) "i" (;) ";" (expression_statement) "crypto_shorthash(out, in, (unsigned long long) i, k);" (call_expression) "crypto_shorthash(out, in, (unsigned long long) i, k)" (identifier) "crypto_shorthash" (argument_list) "(out, in, (unsigned long long) i, k)" (() "(" (identifier) "out" (,) "," (identifier) "in" (,) "," (cast_expression) "(unsigned long long) i" (() "(" (type_descriptor) "unsigned long long" (sized_type_specifier) "unsigned long long" (unsigned) "unsigned" (long) "long" (long) "long" ()) ")" (identifier) "i" (,) "," (identifier) "k" ()) ")" (;) ";" (for_statement) "for (j = 0; j < crypto_shorthash_BYTES; ++j) { \n printf("%02x", (unsigned int) out[j]); \n }" (for) "for" (() "(" (assignment_expression) "j = 0" (identifier) "j" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "j < crypto_shorthash_BYTES" (identifier) "j" (<) "<" (identifier) "crypto_shorthash_BYTES" (;) ";" (update_expression) "++j" (++) "++" (identifier) "j" ()) ")" (compound_statement) "{ \n printf("%02x", (unsigned int) out[j]); \n }" ({) "{" (expression_statement) "printf("%02x", (unsigned int) out[j]);" (call_expression) "printf("%02x", (unsigned int) out[j])" (identifier) "printf" (argument_list) "("%02x", (unsigned int) out[j])" (() "(" (string_literal) ""%02x"" (") """ (string_content) "%02x" (") """ (,) "," (cast_expression) "(unsigned int) out[j]" (() "(" (type_descriptor) "unsigned int" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" ()) ")" (subscript_expression) "out[j]" (identifier) "out" ([) "[" (identifier) "j" (]) "]" ()) ")" (;) ";" (}) "}" (expression_statement) "printf("\n");" (call_expression) "printf("\n")" (identifier) "printf" (argument_list) "("\n")" (() "(" (string_literal) ""\n"" (") """ (escape_sequence) "\n" (") """ ()) ")" (;) ";" (}) "}" (expression_statement) "assert(crypto_shorthash_bytes() > 0);" (call_expression) "assert(crypto_shorthash_bytes() > 0)" (identifier) "assert" (argument_list) "(crypto_shorthash_bytes() > 0)" (() "(" (binary_expression) "crypto_shorthash_bytes() > 0" (call_expression) "crypto_shorthash_bytes()" (identifier) "crypto_shorthash_bytes" (argument_list) "()" (() "(" ()) ")" (>) ">" (number_literal) "0" ()) ")" (;) ";" (expression_statement) "assert(crypto_shorthash_keybytes() > 0);" (call_expression) "assert(crypto_shorthash_keybytes() > 0)" (identifier) "assert" (argument_list) "(crypto_shorthash_keybytes() > 0)" (() "(" (binary_expression) "crypto_shorthash_keybytes() > 0" (call_expression) "crypto_shorthash_keybytes()" (identifier) "crypto_shorthash_keybytes" (argument_list) "()" (() "(" ()) ")" (>) ">" (number_literal) "0" ()) ")" (;) ";" (expression_statement) "assert(strcmp(crypto_shorthash_primitive(), "siphash24") == 0);" (call_expression) "assert(strcmp(crypto_shorthash_primitive(), "siphash24") == 0)" (identifier) "assert" (argument_list) "(strcmp(crypto_shorthash_primitive(), "siphash24") == 0)" (() "(" (binary_expression) "strcmp(crypto_shorthash_primitive(), "siphash24") == 0" (call_expression) "strcmp(crypto_shorthash_primitive(), "siphash24")" (identifier) "strcmp" (argument_list) "(crypto_shorthash_primitive(), "siphash24")" (() "(" (call_expression) "crypto_shorthash_primitive()" (identifier) "crypto_shorthash_primitive" (argument_list) "()" (() "(" ()) ")" (,) "," (string_literal) ""siphash24"" (") """ (string_content) "siphash24" (") """ ()) ")" (==) "==" (number_literal) "0" ()) ")" (;) ";" (expression_statement) "assert(crypto_shorthash_bytes() == crypto_shorthash_siphash24_bytes());" (call_expression) "assert(crypto_shorthash_bytes() == crypto_shorthash_siphash24_bytes())" (identifier) "assert" (argument_list) "(crypto_shorthash_bytes() == crypto_shorthash_siphash24_bytes())" (() "(" (binary_expression) "crypto_shorthash_bytes() == crypto_shorthash_siphash24_bytes()" (call_expression) "crypto_shorthash_bytes()" (identifier) "crypto_shorthash_bytes" (argument_list) "()" (() "(" ()) ")" (==) "==" (call_expression) "crypto_shorthash_siphash24_bytes()" (identifier) "crypto_shorthash_siphash24_bytes" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) ";" (expression_statement) "assert(crypto_shorthash_keybytes() == \n crypto_shorthash_siphash24_keybytes());" (call_expression) "assert(crypto_shorthash_keybytes() == \n crypto_shorthash_siphash24_keybytes())" (identifier) "assert" (argument_list) "(crypto_shorthash_keybytes() == \n crypto_shorthash_siphash24_keybytes())" (() "(" (binary_expression) "crypto_shorthash_keybytes() == \n crypto_shorthash_siphash24_keybytes()" (call_expression) "crypto_shorthash_keybytes()" (identifier) "crypto_shorthash_keybytes" (argument_list) "()" (() "(" ()) ")" (==) "==" (call_expression) "crypto_shorthash_siphash24_keybytes()" (identifier) "crypto_shorthash_siphash24_keybytes" (argument_list) "()" (() "(" ()) ")" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}"
313
0
{"language": "c", "success": true, "metadata": {"lines": 34, "avg_line_length": 28.41, "nodes": 188, "errors": 0, "source_hash": "6553bdc885b5a112408a9df7fe4f941916ff536d4968819cef1265d5f368e427", "categorized_nodes": 122}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_def", "text": "#define TEST_NAME \"shorthash\"\r\n", "parent": null, "children": [1, 2, 3], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 1, "type": "#define", "text": "#define", "parent": 0, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 2, "type": "identifier", "text": "TEST_NAME", "parent": 0, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 17}}, {"id": 3, "type": "preproc_arg", "text": "\"shorthash\"\r", "parent": 0, "children": [], "start_point": {"row": 1, "column": 18}, "end_point": {"row": 1, "column": 30}}, {"id": 4, "type": "preproc_include", "text": "#include \"cmptest.h\"\r\n", "parent": null, "children": [5, 6], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 5, "type": "#include", "text": "#include", "parent": 4, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 6, "type": "string_literal", "text": "\"cmptest.h\"", "parent": 4, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 20}}, {"id": 7, "type": "preproc_def", "text": "#define MAXLEN 64\r\n", "parent": null, "children": [8, 9, 10], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 8, "type": "#define", "text": "#define", "parent": 7, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 7}}, {"id": 9, "type": "identifier", "text": "MAXLEN", "parent": 7, "children": [], "start_point": {"row": 4, "column": 8}, "end_point": {"row": 4, "column": 14}}, {"id": 10, "type": "preproc_arg", "text": "64\r", "parent": 7, "children": [], "start_point": {"row": 4, "column": 15}, "end_point": {"row": 4, "column": 18}}, {"id": 11, "type": "function_definition", "text": "int\r\nmain(void)\r\n{\r\n unsigned char in[MAXLEN];\r\n unsigned char out[crypto_shorthash_BYTES];\r\n unsigned char k[crypto_shorthash_KEYBYTES];\r\n size_t i;\r\n size_t j;\r\n\r\n for (i = 0; i < crypto_shorthash_KEYBYTES; ++i) {\r\n k[i] = (unsigned char) i;\r\n }\r\n for (i = 0; i < MAXLEN; ++i) {\r\n in[i] = (unsigned char) i;\r\n crypto_shorthash(out, in, (unsigned long long) i, k);\r\n for (j = 0; j < crypto_shorthash_BYTES; ++j) {\r\n printf(\"%02x\", (unsigned int) out[j]);\r\n }\r\n printf(\"\\n\");\r\n }\r\n assert(crypto_shorthash_bytes() > 0);\r\n assert(crypto_shorthash_keybytes() > 0);\r\n assert(strcmp(crypto_shorthash_primitive(), \"siphash24\") == 0);\r\n assert(crypto_shorthash_bytes() == crypto_shorthash_siphash24_bytes());\r\n assert(crypto_shorthash_keybytes() ==\r\n crypto_shorthash_siphash24_keybytes());\r\n\r\n return 0;\r\n}", "parent": null, "children": [12, 13], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 34, "column": 1}}, {"id": 12, "type": "primitive_type", "text": "int", "parent": 11, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 3}}, {"id": 13, "type": "function_declarator", "text": "main(void)", "parent": 11, "children": [14, 15], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 10}}, {"id": 14, "type": "identifier", "text": "main", "parent": 13, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 4}}, {"id": 15, "type": "parameter_list", "text": "(void)", "parent": 13, "children": [16], "start_point": {"row": 7, "column": 4}, "end_point": {"row": 7, "column": 10}}, {"id": 16, "type": "parameter_declaration", "text": "void", "parent": 15, "children": [17], "start_point": {"row": 7, "column": 5}, "end_point": {"row": 7, "column": 9}}, {"id": 17, "type": "primitive_type", "text": "void", "parent": 16, "children": [], "start_point": {"row": 7, "column": 5}, "end_point": {"row": 7, "column": 9}}, {"id": 18, "type": "declaration", "text": "unsigned char in[MAXLEN];", "parent": 11, "children": [19, 22], "start_point": {"row": 9, "column": 4}, "end_point": {"row": 9, "column": 29}}, {"id": 19, "type": "sized_type_specifier", "text": "unsigned char", "parent": 18, "children": [20, 21], "start_point": {"row": 9, "column": 4}, "end_point": {"row": 9, "column": 17}}, {"id": 20, "type": "unsigned", "text": "unsigned", "parent": 19, "children": [], "start_point": {"row": 9, "column": 4}, "end_point": {"row": 9, "column": 12}}, {"id": 21, "type": "primitive_type", "text": "char", "parent": 19, "children": [], "start_point": {"row": 9, "column": 13}, "end_point": {"row": 9, "column": 17}}, {"id": 22, "type": "array_declarator", "text": "in[MAXLEN]", "parent": 18, "children": [23, 24], "start_point": {"row": 9, "column": 18}, "end_point": {"row": 9, "column": 28}}, {"id": 23, "type": "identifier", "text": "in", "parent": 22, "children": [], "start_point": {"row": 9, "column": 18}, "end_point": {"row": 9, "column": 20}}, {"id": 24, "type": "identifier", "text": "MAXLEN", "parent": 22, "children": [], "start_point": {"row": 9, "column": 21}, "end_point": {"row": 9, "column": 27}}, {"id": 25, "type": "declaration", "text": "unsigned char out[crypto_shorthash_BYTES];", "parent": 11, "children": [26, 29], "start_point": {"row": 10, "column": 4}, "end_point": {"row": 10, "column": 46}}, {"id": 26, "type": "sized_type_specifier", "text": "unsigned char", "parent": 25, "children": [27, 28], "start_point": {"row": 10, "column": 4}, "end_point": {"row": 10, "column": 17}}, {"id": 27, "type": "unsigned", "text": "unsigned", "parent": 26, "children": [], "start_point": {"row": 10, "column": 4}, "end_point": {"row": 10, "column": 12}}, {"id": 28, "type": "primitive_type", "text": "char", "parent": 26, "children": [], "start_point": {"row": 10, "column": 13}, "end_point": {"row": 10, "column": 17}}, {"id": 29, "type": "array_declarator", "text": "out[crypto_shorthash_BYTES]", "parent": 25, "children": [30, 31], "start_point": {"row": 10, "column": 18}, "end_point": {"row": 10, "column": 45}}, {"id": 30, "type": "identifier", "text": "out", "parent": 29, "children": [], "start_point": {"row": 10, "column": 18}, "end_point": {"row": 10, "column": 21}}, {"id": 31, "type": "identifier", "text": "crypto_shorthash_BYTES", "parent": 29, "children": [], "start_point": {"row": 10, "column": 22}, "end_point": {"row": 10, "column": 44}}, {"id": 32, "type": "declaration", "text": "unsigned char k[crypto_shorthash_KEYBYTES];", "parent": 11, "children": [33, 36], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 47}}, {"id": 33, "type": "sized_type_specifier", "text": "unsigned char", "parent": 32, "children": [34, 35], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 17}}, {"id": 34, "type": "unsigned", "text": "unsigned", "parent": 33, "children": [], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 12}}, {"id": 35, "type": "primitive_type", "text": "char", "parent": 33, "children": [], "start_point": {"row": 11, "column": 13}, "end_point": {"row": 11, "column": 17}}, {"id": 36, "type": "array_declarator", "text": "k[crypto_shorthash_KEYBYTES]", "parent": 32, "children": [37, 38], "start_point": {"row": 11, "column": 18}, "end_point": {"row": 11, "column": 46}}, {"id": 37, "type": "identifier", "text": "k", "parent": 36, "children": [], "start_point": {"row": 11, "column": 18}, "end_point": {"row": 11, "column": 19}}, {"id": 38, "type": "identifier", "text": "crypto_shorthash_KEYBYTES", "parent": 36, "children": [], "start_point": {"row": 11, "column": 20}, "end_point": {"row": 11, "column": 45}}, {"id": 39, "type": "declaration", "text": "size_t i;", "parent": 11, "children": [40, 41], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 20}}, {"id": 40, "type": "primitive_type", "text": "size_t", "parent": 39, "children": [], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 10}}, {"id": 41, "type": "identifier", "text": "i", "parent": 39, "children": [], "start_point": {"row": 12, "column": 18}, "end_point": {"row": 12, "column": 19}}, {"id": 42, "type": "declaration", "text": "size_t j;", "parent": 11, "children": [43, 44], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 20}}, {"id": 43, "type": "primitive_type", "text": "size_t", "parent": 42, "children": [], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 10}}, {"id": 44, "type": "identifier", "text": "j", "parent": 42, "children": [], "start_point": {"row": 13, "column": 18}, "end_point": {"row": 13, "column": 19}}, {"id": 45, "type": "for_statement", "text": "for (i = 0; i < crypto_shorthash_KEYBYTES; ++i) {\r\n k[i] = (unsigned char) i;\r\n }", "parent": 11, "children": [46, 50, 54], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 17, "column": 5}}, {"id": 46, "type": "assignment_expression", "text": "i = 0", "parent": 45, "children": [47, 48, 49], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 14}}, {"id": 47, "type": "identifier", "text": "i", "parent": 46, "children": [], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 10}}, {"id": 48, "type": "=", "text": "=", "parent": 46, "children": [], "start_point": {"row": 15, "column": 11}, "end_point": {"row": 15, "column": 12}}, {"id": 49, "type": "number_literal", "text": "0", "parent": 46, "children": [], "start_point": {"row": 15, "column": 13}, "end_point": {"row": 15, "column": 14}}, {"id": 50, "type": "binary_expression", "text": "i < crypto_shorthash_KEYBYTES", "parent": 45, "children": [51, 52, 53], "start_point": {"row": 15, "column": 16}, "end_point": {"row": 15, "column": 45}}, {"id": 51, "type": "identifier", "text": "i", "parent": 50, "children": [], "start_point": {"row": 15, "column": 16}, "end_point": {"row": 15, "column": 17}}, {"id": 52, "type": "<", "text": "<", "parent": 50, "children": [], "start_point": {"row": 15, "column": 18}, "end_point": {"row": 15, "column": 19}}, {"id": 53, "type": "identifier", "text": "crypto_shorthash_KEYBYTES", "parent": 50, "children": [], "start_point": {"row": 15, "column": 20}, "end_point": {"row": 15, "column": 45}}, {"id": 54, "type": "update_expression", "text": "++i", "parent": 45, "children": [55, 56], "start_point": {"row": 15, "column": 47}, "end_point": {"row": 15, "column": 50}}, {"id": 55, "type": "++", "text": "++", "parent": 54, "children": [], "start_point": {"row": 15, "column": 47}, "end_point": {"row": 15, "column": 49}}, {"id": 56, "type": "identifier", "text": "i", "parent": 54, "children": [], "start_point": {"row": 15, "column": 49}, "end_point": {"row": 15, "column": 50}}, {"id": 57, "type": "assignment_expression", "text": "k[i] = (unsigned char) i", "parent": 45, "children": [58, 61, 62], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 32}}, {"id": 58, "type": "subscript_expression", "text": "k[i]", "parent": 57, "children": [59, 60], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 12}}, {"id": 59, "type": "identifier", "text": "k", "parent": 58, "children": [], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 9}}, {"id": 60, "type": "identifier", "text": "i", "parent": 58, "children": [], "start_point": {"row": 16, "column": 10}, "end_point": {"row": 16, "column": 11}}, {"id": 61, "type": "=", "text": "=", "parent": 57, "children": [], "start_point": {"row": 16, "column": 13}, "end_point": {"row": 16, "column": 14}}, {"id": 62, "type": "cast_expression", "text": "(unsigned char) i", "parent": 57, "children": [63, 67], "start_point": {"row": 16, "column": 15}, "end_point": {"row": 16, "column": 32}}, {"id": 63, "type": "type_descriptor", "text": "unsigned char", "parent": 62, "children": [64], "start_point": {"row": 16, "column": 16}, "end_point": {"row": 16, "column": 29}}, {"id": 64, "type": "sized_type_specifier", "text": "unsigned char", "parent": 63, "children": [65, 66], "start_point": {"row": 16, "column": 16}, "end_point": {"row": 16, "column": 29}}, {"id": 65, "type": "unsigned", "text": "unsigned", "parent": 64, "children": [], "start_point": {"row": 16, "column": 16}, "end_point": {"row": 16, "column": 24}}, {"id": 66, "type": "primitive_type", "text": "char", "parent": 64, "children": [], "start_point": {"row": 16, "column": 25}, "end_point": {"row": 16, "column": 29}}, {"id": 67, "type": "identifier", "text": "i", "parent": 62, "children": [], "start_point": {"row": 16, "column": 31}, "end_point": {"row": 16, "column": 32}}, {"id": 68, "type": "for_statement", "text": "for (i = 0; i < MAXLEN; ++i) {\r\n in[i] = (unsigned char) i;\r\n crypto_shorthash(out, in, (unsigned long long) i, k);\r\n for (j = 0; j < crypto_shorthash_BYTES; ++j) {\r\n printf(\"%02x\", (unsigned int) out[j]);\r\n }\r\n printf(\"\\n\");\r\n }", "parent": 11, "children": [69, 73, 77], "start_point": {"row": 18, "column": 4}, "end_point": {"row": 25, "column": 5}}, {"id": 69, "type": "assignment_expression", "text": "i = 0", "parent": 68, "children": [70, 71, 72], "start_point": {"row": 18, "column": 9}, "end_point": {"row": 18, "column": 14}}, {"id": 70, "type": "identifier", "text": "i", "parent": 69, "children": [], "start_point": {"row": 18, "column": 9}, "end_point": {"row": 18, "column": 10}}, {"id": 71, "type": "=", "text": "=", "parent": 69, "children": [], "start_point": {"row": 18, "column": 11}, "end_point": {"row": 18, "column": 12}}, {"id": 72, "type": "number_literal", "text": "0", "parent": 69, "children": [], "start_point": {"row": 18, "column": 13}, "end_point": {"row": 18, "column": 14}}, {"id": 73, "type": "binary_expression", "text": "i < MAXLEN", "parent": 68, "children": [74, 75, 76], "start_point": {"row": 18, "column": 16}, "end_point": {"row": 18, "column": 26}}, {"id": 74, "type": "identifier", "text": "i", "parent": 73, "children": [], "start_point": {"row": 18, "column": 16}, "end_point": {"row": 18, "column": 17}}, {"id": 75, "type": "<", "text": "<", "parent": 73, "children": [], "start_point": {"row": 18, "column": 18}, "end_point": {"row": 18, "column": 19}}, {"id": 76, "type": "identifier", "text": "MAXLEN", "parent": 73, "children": [], "start_point": {"row": 18, "column": 20}, "end_point": {"row": 18, "column": 26}}, {"id": 77, "type": "update_expression", "text": "++i", "parent": 68, "children": [78, 79], "start_point": {"row": 18, "column": 28}, "end_point": {"row": 18, "column": 31}}, {"id": 78, "type": "++", "text": "++", "parent": 77, "children": [], "start_point": {"row": 18, "column": 28}, "end_point": {"row": 18, "column": 30}}, {"id": 79, "type": "identifier", "text": "i", "parent": 77, "children": [], "start_point": {"row": 18, "column": 30}, "end_point": {"row": 18, "column": 31}}, {"id": 80, "type": "assignment_expression", "text": "in[i] = (unsigned char) i", "parent": 68, "children": [81, 84, 85], "start_point": {"row": 19, "column": 8}, "end_point": {"row": 19, "column": 33}}, {"id": 81, "type": "subscript_expression", "text": "in[i]", "parent": 80, "children": [82, 83], "start_point": {"row": 19, "column": 8}, "end_point": {"row": 19, "column": 13}}, {"id": 82, "type": "identifier", "text": "in", "parent": 81, "children": [], "start_point": {"row": 19, "column": 8}, "end_point": {"row": 19, "column": 10}}, {"id": 83, "type": "identifier", "text": "i", "parent": 81, "children": [], "start_point": {"row": 19, "column": 11}, "end_point": {"row": 19, "column": 12}}, {"id": 84, "type": "=", "text": "=", "parent": 80, "children": [], "start_point": {"row": 19, "column": 14}, "end_point": {"row": 19, "column": 15}}, {"id": 85, "type": "cast_expression", "text": "(unsigned char) i", "parent": 80, "children": [86, 90], "start_point": {"row": 19, "column": 16}, "end_point": {"row": 19, "column": 33}}, {"id": 86, "type": "type_descriptor", "text": "unsigned char", "parent": 85, "children": [87], "start_point": {"row": 19, "column": 17}, "end_point": {"row": 19, "column": 30}}, {"id": 87, "type": "sized_type_specifier", "text": "unsigned char", "parent": 86, "children": [88, 89], "start_point": {"row": 19, "column": 17}, "end_point": {"row": 19, "column": 30}}, {"id": 88, "type": "unsigned", "text": "unsigned", "parent": 87, "children": [], "start_point": {"row": 19, "column": 17}, "end_point": {"row": 19, "column": 25}}, {"id": 89, "type": "primitive_type", "text": "char", "parent": 87, "children": [], "start_point": {"row": 19, "column": 26}, "end_point": {"row": 19, "column": 30}}, {"id": 90, "type": "identifier", "text": "i", "parent": 85, "children": [], "start_point": {"row": 19, "column": 32}, "end_point": {"row": 19, "column": 33}}, {"id": 91, "type": "call_expression", "text": "crypto_shorthash(out, in, (unsigned long long) i, k)", "parent": 68, "children": [92, 93], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 60}}, {"id": 92, "type": "identifier", "text": "crypto_shorthash", "parent": 91, "children": [], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 24}}, {"id": 93, "type": "argument_list", "text": "(out, in, (unsigned long long) i, k)", "parent": 91, "children": [94, 95, 96, 103], "start_point": {"row": 20, "column": 24}, "end_point": {"row": 20, "column": 60}}, {"id": 94, "type": "identifier", "text": "out", "parent": 93, "children": [], "start_point": {"row": 20, "column": 25}, "end_point": {"row": 20, "column": 28}}, {"id": 95, "type": "identifier", "text": "in", "parent": 93, "children": [], "start_point": {"row": 20, "column": 30}, "end_point": {"row": 20, "column": 32}}, {"id": 96, "type": "cast_expression", "text": "(unsigned long long) i", "parent": 93, "children": [97, 102], "start_point": {"row": 20, "column": 34}, "end_point": {"row": 20, "column": 56}}, {"id": 97, "type": "type_descriptor", "text": "unsigned long long", "parent": 96, "children": [98], "start_point": {"row": 20, "column": 35}, "end_point": {"row": 20, "column": 53}}, {"id": 98, "type": "sized_type_specifier", "text": "unsigned long long", "parent": 97, "children": [99, 100, 101], "start_point": {"row": 20, "column": 35}, "end_point": {"row": 20, "column": 53}}, {"id": 99, "type": "unsigned", "text": "unsigned", "parent": 98, "children": [], "start_point": {"row": 20, "column": 35}, "end_point": {"row": 20, "column": 43}}, {"id": 100, "type": "long", "text": "long", "parent": 98, "children": [], "start_point": {"row": 20, "column": 44}, "end_point": {"row": 20, "column": 48}}, {"id": 101, "type": "long", "text": "long", "parent": 98, "children": [], "start_point": {"row": 20, "column": 49}, "end_point": {"row": 20, "column": 53}}, {"id": 102, "type": "identifier", "text": "i", "parent": 96, "children": [], "start_point": {"row": 20, "column": 55}, "end_point": {"row": 20, "column": 56}}, {"id": 103, "type": "identifier", "text": "k", "parent": 93, "children": [], "start_point": {"row": 20, "column": 58}, "end_point": {"row": 20, "column": 59}}, {"id": 104, "type": "for_statement", "text": "for (j = 0; j < crypto_shorthash_BYTES; ++j) {\r\n printf(\"%02x\", (unsigned int) out[j]);\r\n }", "parent": 68, "children": [105, 109, 113], "start_point": {"row": 21, "column": 8}, "end_point": {"row": 23, "column": 9}}, {"id": 105, "type": "assignment_expression", "text": "j = 0", "parent": 104, "children": [106, 107, 108], "start_point": {"row": 21, "column": 13}, "end_point": {"row": 21, "column": 18}}, {"id": 106, "type": "identifier", "text": "j", "parent": 105, "children": [], "start_point": {"row": 21, "column": 13}, "end_point": {"row": 21, "column": 14}}, {"id": 107, "type": "=", "text": "=", "parent": 105, "children": [], "start_point": {"row": 21, "column": 15}, "end_point": {"row": 21, "column": 16}}, {"id": 108, "type": "number_literal", "text": "0", "parent": 105, "children": [], "start_point": {"row": 21, "column": 17}, "end_point": {"row": 21, "column": 18}}, {"id": 109, "type": "binary_expression", "text": "j < crypto_shorthash_BYTES", "parent": 104, "children": [110, 111, 112], "start_point": {"row": 21, "column": 20}, "end_point": {"row": 21, "column": 46}}, {"id": 110, "type": "identifier", "text": "j", "parent": 109, "children": [], "start_point": {"row": 21, "column": 20}, "end_point": {"row": 21, "column": 21}}, {"id": 111, "type": "<", "text": "<", "parent": 109, "children": [], "start_point": {"row": 21, "column": 22}, "end_point": {"row": 21, "column": 23}}, {"id": 112, "type": "identifier", "text": "crypto_shorthash_BYTES", "parent": 109, "children": [], "start_point": {"row": 21, "column": 24}, "end_point": {"row": 21, "column": 46}}, {"id": 113, "type": "update_expression", "text": "++j", "parent": 104, "children": [114, 115], "start_point": {"row": 21, "column": 48}, "end_point": {"row": 21, "column": 51}}, {"id": 114, "type": "++", "text": "++", "parent": 113, "children": [], "start_point": {"row": 21, "column": 48}, "end_point": {"row": 21, "column": 50}}, {"id": 115, "type": "identifier", "text": "j", "parent": 113, "children": [], "start_point": {"row": 21, "column": 50}, "end_point": {"row": 21, "column": 51}}, {"id": 116, "type": "call_expression", "text": "printf(\"%02x\", (unsigned int) out[j])", "parent": 104, "children": [117, 118], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 49}}, {"id": 117, "type": "identifier", "text": "printf", "parent": 116, "children": [], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 18}}, {"id": 118, "type": "argument_list", "text": "(\"%02x\", (unsigned int) out[j])", "parent": 116, "children": [119, 120], "start_point": {"row": 22, "column": 18}, "end_point": {"row": 22, "column": 49}}, {"id": 119, "type": "string_literal", "text": "\"%02x\"", "parent": 118, "children": [], "start_point": {"row": 22, "column": 19}, "end_point": {"row": 22, "column": 25}}, {"id": 120, "type": "cast_expression", "text": "(unsigned int) out[j]", "parent": 118, "children": [121, 125], "start_point": {"row": 22, "column": 27}, "end_point": {"row": 22, "column": 48}}, {"id": 121, "type": "type_descriptor", "text": "unsigned int", "parent": 120, "children": [122], "start_point": {"row": 22, "column": 28}, "end_point": {"row": 22, "column": 40}}, {"id": 122, "type": "sized_type_specifier", "text": "unsigned int", "parent": 121, "children": [123, 124], "start_point": {"row": 22, "column": 28}, "end_point": {"row": 22, "column": 40}}, {"id": 123, "type": "unsigned", "text": "unsigned", "parent": 122, "children": [], "start_point": {"row": 22, "column": 28}, "end_point": {"row": 22, "column": 36}}, {"id": 124, "type": "primitive_type", "text": "int", "parent": 122, "children": [], "start_point": {"row": 22, "column": 37}, "end_point": {"row": 22, "column": 40}}, {"id": 125, "type": "subscript_expression", "text": "out[j]", "parent": 120, "children": [126, 127], "start_point": {"row": 22, "column": 42}, "end_point": {"row": 22, "column": 48}}, {"id": 126, "type": "identifier", "text": "out", "parent": 125, "children": [], "start_point": {"row": 22, "column": 42}, "end_point": {"row": 22, "column": 45}}, {"id": 127, "type": "identifier", "text": "j", "parent": 125, "children": [], "start_point": {"row": 22, "column": 46}, "end_point": {"row": 22, "column": 47}}, {"id": 128, "type": "call_expression", "text": "printf(\"\\n\")", "parent": 68, "children": [129, 130], "start_point": {"row": 24, "column": 8}, "end_point": {"row": 24, "column": 20}}, {"id": 129, "type": "identifier", "text": "printf", "parent": 128, "children": [], "start_point": {"row": 24, "column": 8}, "end_point": {"row": 24, "column": 14}}, {"id": 130, "type": "argument_list", "text": "(\"\\n\")", "parent": 128, "children": [131], "start_point": {"row": 24, "column": 14}, "end_point": {"row": 24, "column": 20}}, {"id": 131, "type": "string_literal", "text": "\"\\n\"", "parent": 130, "children": [132], "start_point": {"row": 24, "column": 15}, "end_point": {"row": 24, "column": 19}}, {"id": 132, "type": "escape_sequence", "text": "\\n", "parent": 131, "children": [], "start_point": {"row": 24, "column": 16}, "end_point": {"row": 24, "column": 18}}, {"id": 133, "type": "call_expression", "text": "assert(crypto_shorthash_bytes() > 0)", "parent": 11, "children": [134, 135], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 26, "column": 40}}, {"id": 134, "type": "identifier", "text": "assert", "parent": 133, "children": [], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 26, "column": 10}}, {"id": 135, "type": "argument_list", "text": "(crypto_shorthash_bytes() > 0)", "parent": 133, "children": [136], "start_point": {"row": 26, "column": 10}, "end_point": {"row": 26, "column": 40}}, {"id": 136, "type": "binary_expression", "text": "crypto_shorthash_bytes() > 0", "parent": 135, "children": [137, 140, 141], "start_point": {"row": 26, "column": 11}, "end_point": {"row": 26, "column": 39}}, {"id": 137, "type": "call_expression", "text": "crypto_shorthash_bytes()", "parent": 136, "children": [138, 139], "start_point": {"row": 26, "column": 11}, "end_point": {"row": 26, "column": 35}}, {"id": 138, "type": "identifier", "text": "crypto_shorthash_bytes", "parent": 137, "children": [], "start_point": {"row": 26, "column": 11}, "end_point": {"row": 26, "column": 33}}, {"id": 139, "type": "argument_list", "text": "()", "parent": 137, "children": [], "start_point": {"row": 26, "column": 33}, "end_point": {"row": 26, "column": 35}}, {"id": 140, "type": ">", "text": ">", "parent": 136, "children": [], "start_point": {"row": 26, "column": 36}, "end_point": {"row": 26, "column": 37}}, {"id": 141, "type": "number_literal", "text": "0", "parent": 136, "children": [], "start_point": {"row": 26, "column": 38}, "end_point": {"row": 26, "column": 39}}, {"id": 142, "type": "call_expression", "text": "assert(crypto_shorthash_keybytes() > 0)", "parent": 11, "children": [143, 144], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 43}}, {"id": 143, "type": "identifier", "text": "assert", "parent": 142, "children": [], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 10}}, {"id": 144, "type": "argument_list", "text": "(crypto_shorthash_keybytes() > 0)", "parent": 142, "children": [145], "start_point": {"row": 27, "column": 10}, "end_point": {"row": 27, "column": 43}}, {"id": 145, "type": "binary_expression", "text": "crypto_shorthash_keybytes() > 0", "parent": 144, "children": [146, 149, 150], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 42}}, {"id": 146, "type": "call_expression", "text": "crypto_shorthash_keybytes()", "parent": 145, "children": [147, 148], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 38}}, {"id": 147, "type": "identifier", "text": "crypto_shorthash_keybytes", "parent": 146, "children": [], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 36}}, {"id": 148, "type": "argument_list", "text": "()", "parent": 146, "children": [], "start_point": {"row": 27, "column": 36}, "end_point": {"row": 27, "column": 38}}, {"id": 149, "type": ">", "text": ">", "parent": 145, "children": [], "start_point": {"row": 27, "column": 39}, "end_point": {"row": 27, "column": 40}}, {"id": 150, "type": "number_literal", "text": "0", "parent": 145, "children": [], "start_point": {"row": 27, "column": 41}, "end_point": {"row": 27, "column": 42}}, {"id": 151, "type": "call_expression", "text": "assert(strcmp(crypto_shorthash_primitive(), \"siphash24\") == 0)", "parent": 11, "children": [152, 153], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 28, "column": 66}}, {"id": 152, "type": "identifier", "text": "assert", "parent": 151, "children": [], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 28, "column": 10}}, {"id": 153, "type": "argument_list", "text": "(strcmp(crypto_shorthash_primitive(), \"siphash24\") == 0)", "parent": 151, "children": [154], "start_point": {"row": 28, "column": 10}, "end_point": {"row": 28, "column": 66}}, {"id": 154, "type": "binary_expression", "text": "strcmp(crypto_shorthash_primitive(), \"siphash24\") == 0", "parent": 153, "children": [155, 162, 163], "start_point": {"row": 28, "column": 11}, "end_point": {"row": 28, "column": 65}}, {"id": 155, "type": "call_expression", "text": "strcmp(crypto_shorthash_primitive(), \"siphash24\")", "parent": 154, "children": [156, 157], "start_point": {"row": 28, "column": 11}, "end_point": {"row": 28, "column": 60}}, {"id": 156, "type": "identifier", "text": "strcmp", "parent": 155, "children": [], "start_point": {"row": 28, "column": 11}, "end_point": {"row": 28, "column": 17}}, {"id": 157, "type": "argument_list", "text": "(crypto_shorthash_primitive(), \"siphash24\")", "parent": 155, "children": [158, 161], "start_point": {"row": 28, "column": 17}, "end_point": {"row": 28, "column": 60}}, {"id": 158, "type": "call_expression", "text": "crypto_shorthash_primitive()", "parent": 157, "children": [159, 160], "start_point": {"row": 28, "column": 18}, "end_point": {"row": 28, "column": 46}}, {"id": 159, "type": "identifier", "text": "crypto_shorthash_primitive", "parent": 158, "children": [], "start_point": {"row": 28, "column": 18}, "end_point": {"row": 28, "column": 44}}, {"id": 160, "type": "argument_list", "text": "()", "parent": 158, "children": [], "start_point": {"row": 28, "column": 44}, "end_point": {"row": 28, "column": 46}}, {"id": 161, "type": "string_literal", "text": "\"siphash24\"", "parent": 157, "children": [], "start_point": {"row": 28, "column": 48}, "end_point": {"row": 28, "column": 59}}, {"id": 162, "type": "==", "text": "==", "parent": 154, "children": [], "start_point": {"row": 28, "column": 61}, "end_point": {"row": 28, "column": 63}}, {"id": 163, "type": "number_literal", "text": "0", "parent": 154, "children": [], "start_point": {"row": 28, "column": 64}, "end_point": {"row": 28, "column": 65}}, {"id": 164, "type": "call_expression", "text": "assert(crypto_shorthash_bytes() == crypto_shorthash_siphash24_bytes())", "parent": 11, "children": [165, 166], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 74}}, {"id": 165, "type": "identifier", "text": "assert", "parent": 164, "children": [], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 10}}, {"id": 166, "type": "argument_list", "text": "(crypto_shorthash_bytes() == crypto_shorthash_siphash24_bytes())", "parent": 164, "children": [167], "start_point": {"row": 29, "column": 10}, "end_point": {"row": 29, "column": 74}}, {"id": 167, "type": "binary_expression", "text": "crypto_shorthash_bytes() == crypto_shorthash_siphash24_bytes()", "parent": 166, "children": [168, 171, 172], "start_point": {"row": 29, "column": 11}, "end_point": {"row": 29, "column": 73}}, {"id": 168, "type": "call_expression", "text": "crypto_shorthash_bytes()", "parent": 167, "children": [169, 170], "start_point": {"row": 29, "column": 11}, "end_point": {"row": 29, "column": 35}}, {"id": 169, "type": "identifier", "text": "crypto_shorthash_bytes", "parent": 168, "children": [], "start_point": {"row": 29, "column": 11}, "end_point": {"row": 29, "column": 33}}, {"id": 170, "type": "argument_list", "text": "()", "parent": 168, "children": [], "start_point": {"row": 29, "column": 33}, "end_point": {"row": 29, "column": 35}}, {"id": 171, "type": "==", "text": "==", "parent": 167, "children": [], "start_point": {"row": 29, "column": 36}, "end_point": {"row": 29, "column": 38}}, {"id": 172, "type": "call_expression", "text": "crypto_shorthash_siphash24_bytes()", "parent": 167, "children": [173, 174], "start_point": {"row": 29, "column": 39}, "end_point": {"row": 29, "column": 73}}, {"id": 173, "type": "identifier", "text": "crypto_shorthash_siphash24_bytes", "parent": 172, "children": [], "start_point": {"row": 29, "column": 39}, "end_point": {"row": 29, "column": 71}}, {"id": 174, "type": "argument_list", "text": "()", "parent": 172, "children": [], "start_point": {"row": 29, "column": 71}, "end_point": {"row": 29, "column": 73}}, {"id": 175, "type": "call_expression", "text": "assert(crypto_shorthash_keybytes() ==\r\n crypto_shorthash_siphash24_keybytes())", "parent": 11, "children": [176, 177], "start_point": {"row": 30, "column": 4}, "end_point": {"row": 31, "column": 49}}, {"id": 176, "type": "identifier", "text": "assert", "parent": 175, "children": [], "start_point": {"row": 30, "column": 4}, "end_point": {"row": 30, "column": 10}}, {"id": 177, "type": "argument_list", "text": "(crypto_shorthash_keybytes() ==\r\n crypto_shorthash_siphash24_keybytes())", "parent": 175, "children": [178], "start_point": {"row": 30, "column": 10}, "end_point": {"row": 31, "column": 49}}, {"id": 178, "type": "binary_expression", "text": "crypto_shorthash_keybytes() ==\r\n crypto_shorthash_siphash24_keybytes()", "parent": 177, "children": [179, 182, 183], "start_point": {"row": 30, "column": 11}, "end_point": {"row": 31, "column": 48}}, {"id": 179, "type": "call_expression", "text": "crypto_shorthash_keybytes()", "parent": 178, "children": [180, 181], "start_point": {"row": 30, "column": 11}, "end_point": {"row": 30, "column": 38}}, {"id": 180, "type": "identifier", "text": "crypto_shorthash_keybytes", "parent": 179, "children": [], "start_point": {"row": 30, "column": 11}, "end_point": {"row": 30, "column": 36}}, {"id": 181, "type": "argument_list", "text": "()", "parent": 179, "children": [], "start_point": {"row": 30, "column": 36}, "end_point": {"row": 30, "column": 38}}, {"id": 182, "type": "==", "text": "==", "parent": 178, "children": [], "start_point": {"row": 30, "column": 39}, "end_point": {"row": 30, "column": 41}}, {"id": 183, "type": "call_expression", "text": "crypto_shorthash_siphash24_keybytes()", "parent": 178, "children": [184, 185], "start_point": {"row": 31, "column": 11}, "end_point": {"row": 31, "column": 48}}, {"id": 184, "type": "identifier", "text": "crypto_shorthash_siphash24_keybytes", "parent": 183, "children": [], "start_point": {"row": 31, "column": 11}, "end_point": {"row": 31, "column": 46}}, {"id": 185, "type": "argument_list", "text": "()", "parent": 183, "children": [], "start_point": {"row": 31, "column": 46}, "end_point": {"row": 31, "column": 48}}, {"id": 186, "type": "return_statement", "text": "return 0;", "parent": 11, "children": [187], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 13}}, {"id": 187, "type": "number_literal", "text": "0", "parent": 186, "children": [], "start_point": {"row": 33, "column": 11}, "end_point": {"row": 33, "column": 12}}]}, "node_categories": {"declarations": {"functions": [11, 13], "variables": [16, 18, 25, 32, 39, 42], "classes": [], "imports": [4, 5], "modules": [], "enums": []}, "statements": {"expressions": [50, 54, 58, 62, 73, 77, 81, 85, 91, 96, 109, 113, 116, 120, 125, 128, 133, 136, 137, 142, 145, 146, 151, 154, 155, 158, 164, 167, 168, 172, 175, 178, 179, 183], "assignments": [46, 57, 69, 80, 105], "loops": [45, 68, 104], "conditionals": [2, 9, 14, 19, 23, 24, 26, 30, 31, 33, 37, 38, 41, 44, 47, 51, 53, 56, 59, 60, 64, 67, 70, 74, 76, 79, 82, 83, 87, 90, 92, 94, 95, 98, 102, 103, 106, 110, 112, 115, 117, 122, 126, 127, 129, 134, 138, 143, 147, 152, 156, 159, 165, 169, 173, 176, 180, 184], "returns": [186], "exceptions": []}, "expressions": {"calls": [], "literals": [6, 49, 72, 108, 119, 131, 141, 150, 161, 163, 187], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 11, "universal_type": "function", "name": "main", "text_snippet": "int\r\nmain(void)\r\n{\r\n unsigned char in[MAXLEN];\r\n unsigned char out[crypto_shorthash_BYTES];\r\n "}, {"node_id": 13, "universal_type": "function", "name": "unknown", "text_snippet": "main(void)"}], "class_declarations": [], "import_statements": [{"node_id": 4, "text": "#include \"cmptest.h\"\r\n"}, {"node_id": 5, "text": "#include"}]}, "original_source_code": "\r\n#define TEST_NAME \"shorthash\"\r\n#include \"cmptest.h\"\r\n\r\n#define MAXLEN 64\r\n\r\nint\r\nmain(void)\r\n{\r\n unsigned char in[MAXLEN];\r\n unsigned char out[crypto_shorthash_BYTES];\r\n unsigned char k[crypto_shorthash_KEYBYTES];\r\n size_t i;\r\n size_t j;\r\n\r\n for (i = 0; i < crypto_shorthash_KEYBYTES; ++i) {\r\n k[i] = (unsigned char) i;\r\n }\r\n for (i = 0; i < MAXLEN; ++i) {\r\n in[i] = (unsigned char) i;\r\n crypto_shorthash(out, in, (unsigned long long) i, k);\r\n for (j = 0; j < crypto_shorthash_BYTES; ++j) {\r\n printf(\"%02x\", (unsigned int) out[j]);\r\n }\r\n printf(\"\\n\");\r\n }\r\n assert(crypto_shorthash_bytes() > 0);\r\n assert(crypto_shorthash_keybytes() > 0);\r\n assert(strcmp(crypto_shorthash_primitive(), \"siphash24\") == 0);\r\n assert(crypto_shorthash_bytes() == crypto_shorthash_siphash24_bytes());\r\n assert(crypto_shorthash_keybytes() ==\r\n crypto_shorthash_siphash24_keybytes());\r\n\r\n return 0;\r\n}\r\n"}
80,562
c
// // YLNewsSDKModeManager.h // YLInfoFlowSDK // // Created by Apple on 2020/6/23. // Copyright © 2020 com.qujie.tech. All rights reserved. // #import <Foundation/Foundation.h> #import <UIKit/UIKit.h> NS_ASSUME_NONNULL_BEGIN @interface YLNewsSDKVideoTabModeManager : NSObject + (instancetype)shareManager; ///是否是悬停效果 默认为NO @property (assign,nonatomic)BOOL isHoverMode; ///是否有导航栏 默认为NO @property (assign,nonatomic)BOOL isHaveNav; ///是否有tabbar 默认为NO @property (assign,nonatomic)BOOL isHaveTabbar; ///是否需要刷新按钮 默认为NO @property (assign,nonatomic)BOOL isNeedRefreashButton; ///微信分享appid @property (copy,nonatomic)NSString * WXShareAPPID; ///qq分享appid @property (copy,nonatomic)NSString * QQShareAPPID; /// 滚动视图回调(供宿主判断是否可滚动) /// @param scrollview 回调的滚动视图 @property (nonatomic, copy) void(^scrollviewBlock)(UIScrollView *scrollview); /// 新闻/视频展示等数据回调给宿主供埋点 /// @param sdk_newsDataBuryDic 回调数据 @property (nonatomic, copy) void(^sdk_newsDataBuryBlock)(NSDictionary *sdk_newsDataBuryDic); /// 广告数据回调给宿主供埋点 /// @param sdk_adBuryDic 回调的广告埋点数据 @property (nonatomic, copy) void(^sdk_ADBuryBlock)(NSDictionary *sdk_adBuryDic); @end NS_ASSUME_NONNULL_END
29.16
38
(translation_unit) "//\n// YLNewsSDKModeManager.h\n// YLInfoFlowSDK\n//\n// Created by Apple on 2020/6/23.\n// Copyright © 2020 com.qujie.tech. All rights reserved.\n//\n\n#import <Foundation/Foundation.h>\n#import <UIKit/UIKit.h>\n\nNS_ASSUME_NONNULL_BEGIN\n\n@interface YLNewsSDKVideoTabModeManager : NSObject\n\n+ (instancetype)shareManager;\n\n///是否是悬停效果 默认为NO\n@property (assign,nonatomic)BOOL isHoverMode;\n\n///是否有导航栏 默认为NO\n@property (assign,nonatomic)BOOL isHaveNav;\n\n///是否有tabbar 默认为NO\n@property (assign,nonatomic)BOOL isHaveTabbar;\n\n///是否需要刷新按钮 默认为NO\n@property (assign,nonatomic)BOOL isNeedRefreashButton;\n\n///微信分享appid\n@property (copy,nonatomic)NSString * WXShareAPPID;\n///qq分享appid\n@property (copy,nonatomic)NSString * QQShareAPPID;\n\n\n/// 滚动视图回调(供宿主判断是否可滚动)\n/// @param scrollview 回调的滚动视图\n@property (nonatomic, copy) void(^scrollviewBlock)(UIScrollView *scrollview);\n\n\n/// 新闻/视频展示等数据回调给宿主供埋点\n/// @param sdk_newsDataBuryDic 回调数据\n@property (nonatomic, copy) void(^sdk_newsDataBuryBlock)(NSDictionary *sdk_newsDataBuryDic);\n\n/// 广告数据回调给宿主供埋点\n/// @param sdk_adBuryDic 回调的广告埋点数据\n@property (nonatomic, copy) void(^sdk_ADBuryBlock)(NSDictionary *sdk_adBuryDic);\n\n\n@end\n\nNS_ASSUME_NONNULL_END\n" (comment) "//" (comment) "// YLNewsSDKModeManager.h" (comment) "// YLInfoFlowSDK" (comment) "//" (comment) "// Created by Apple on 2020/6/23." (comment) "// Copyright © 2020 com.qujie.tech. All rights reserved.\n" (comment) "/\n" (preproc_call) "import <Foundation/Foundation.h>\n#" (preproc_directive) "import " (preproc_arg) "Foundation/Foundation.h>\n" (preproc_call) "import <UIKit/UIKit.h>\n\n" (preproc_directive) "import " (preproc_arg) "UIKit/UIKit.h>\n" (declaration) "S_ASSUME_NONNULL_BEGIN\n\n@interface " (type_identifier) "S_ASSUME_NONNULL_BEGIN\n" (ERROR) "i" (ERROR) "i" (identifier) "nterface " (;) "" (labeled_statement) "LNewsSDKVideoTabModeManager : NSObject\n\n+ (instancetype)shareManager;\n" (statement_identifier) "LNewsSDKVideoTabModeManager " (:) " " (expression_statement) "SObject\n\n+ (instancetype)shareManager;\n" (binary_expression) "SObject\n\n+ (instancetype)shareManager;" (identifier) "SObject\n" (+) " " (cast_expression) "instancetype)shareManager;" (() "i" (type_descriptor) "nstancetype)" (type_identifier) "nstancetype)" ()) "s" (identifier) "hareManager;" (;) "\n" (comment) "//是否是悬停效果 默认为NO\n@property (assign,no" (ERROR) "atomic)BOOL isHoverMode;\n\n///是否有" (ERROR) "a" (call_expression) "tomic)BOOL isHoverMode;\n\n//" (identifier) "tomic)BO" (argument_list) "L isHoverMode;\n\n//" (() "L" (identifier) " isHov" (,) "e" (identifier) "rMode;\n\n/" ()) "/" (identifier) "/是否有" (expression_statement) "航栏 默认为NO\n@pr" (identifier) "航栏 默认为NO\n@p" (;) "r" (comment) "erty (assign,nonatomic)BOOL isHav" (ERROR) "Nav;\n\n///是否有tabbar 默认为NO\n@proper" (ERROR) "N" (call_expression) "av;\n\n///是否有tabbar 默认为NO\n@pr" (identifier) "av;\n\n///" (argument_list) "否有tabbar 默认为NO\n@pr" (() "否" (identifier) "有tabba" (,) "r" (identifier) " 默认为NO\n@p" ()) "r" (identifier) "oper" (expression_statement) "y (assign," (identifier) "y (assign" (;) "," (comment) "natomic)BOOL isHaveTabbar;\n\n//" (ERROR) "是否需要刷新按钮 默认为NO\n@property (assign" (ERROR) "是" (call_expression) "否需要刷新按钮 默认为NO\n@property (as" (identifier) "否需要刷新按钮 " (argument_list) "认为NO\n@property (as" (() "认" (identifier) "为NO\n@p" (,) "r" (identifier) "operty (a" ()) "s" (identifier) "sign" (expression_statement) "nonatomic)BOO" (identifier) "nonatomic)BO" (;) "O" (comment) "isNeedRefreashButton;\n\n///微信分享appid\n@pr" (ERROR) "perty (copy,nonatomic)NSString *" (ERROR) "p" (call_expression) "erty (copy,nonatomic)NSStri" (identifier) "erty (co" (argument_list) "y,nonatomic)NSStri" (() "y" (identifier) ",nonat" (,) "o" (identifier) "mic)NSStr" ()) "i" (identifier) "ng *" (expression_statement) "WXShareAPPID;\n///qq分享" (identifier) "WXShareAPPID;\n///qq分" (;) "享" (comment) "pid\n@property (copy," (ERROR) "o" (ERROR) "o" (expression_statement) "natomic)NSString * QQShar" (call_expression) "natomic)NSString * QQShar" (identifier) "natomic)" (argument_list) "SString * QQShar" (() "S" (identifier) "Stri" (,) "n" (identifier) "g * QQSha" ()) "r" (;) "" (declaration) "eAPPID;\n\n\n/// 滚动视图回调(供宿主" (type_identifier) "eAPPID;\n" (pointer_declarator) "\n/// 滚动视图回调(供宿" (*) "\n" (identifier) "// 滚动视图回调(供宿" (;) "主" (comment) "断是否可滚动)\n/// @par" (ERROR) "m" (ERROR) "m" (expression_statement) " scrollview 回调的滚动视图\n@prop" (call_expression) " scrollview 回调的滚动视图\n@prop" (identifier) " scrollv" (argument_list) "ew 回调的滚动视图\n@prop" (() "e" (identifier) "w 回调" (,) "的" (identifier) "滚动视图\n@pro" ()) "p" (;) "" (declaration) "erty (nonatomic, copy) v" (type_identifier) "erty (no" (pointer_declarator) "atomic, copy) " (*) "a" (identifier) "omic, copy) " (;) "v" (comment) "(^scrollviewBlock)(UIScrollView *scrollview);\n\n\n/// 新闻/视频展" (comment) "等数据回调给宿主供埋点\n/// @param sdk_newsDataBuryDic " (ERROR) "调" (ERROR) "调" (expression_statement) "数据\n@property (nonatomic, c" (call_expression) "数据\n@property (nonatomic, c" (identifier) "数据\n@prop" (argument_list) "rty (nonatomic, c" (() "r" (identifier) "ty (nonat" (,) "o" (identifier) "ic, " ()) "c" (;) "" (declaration) "py) void(^sdk_newsDataBuryBlock)(NSDictionary *sd" (primitive_type) "py) " (function_declarator) "void(^sdk_newsDataBuryBlock)(NSDictionary *s" (parenthesized_declarator) "void(^sdk_newsData" (() "v" (ERROR) "o" (^) "o" (identifier) "id(^sdk_newsDat" ()) "a" (parameter_list) "BuryBlock)(NSDictionary *s" (() "B" (parameter_declaration) "uryBlock)(NSDictionary *" (type_identifier) "uryBlock)(NS" (pointer_declarator) "ictionary *" (*) "i" (identifier) "ctionary *" ()) "s" (;) "d" (comment) "ewsDataBuryDic);\n\n/// 广告数据回调给宿主供埋点\n/// @param sdk_adBury" (comment) "ic 回调的广告埋点数据\n@property (nonatomic, copy) vo" (ERROR) "d" (ERROR) "d" (expression_statement) "(^sdk_ADBuryBlock)(NSDicti" (call_expression) "(^sdk_ADBuryBlock)(NSDicti" (identifier) "(^sdk_AD" (argument_list) "uryBlock)(NSDicti" (() "u" (identifier) "ryBlock)(" (,) "N" (identifier) "Dict" ()) "i" (;) "" (declaration) "nary *sdk_adBuryDic);\n\n\n@end\n\nNS_ASSUME_NONNULL_END\n" (primitive_type) "nary" (function_declarator) " *sdk_adBuryDic);\n\n\n@end\n\nNS_ASSUME_NONNULL_END\n" (parenthesized_declarator) " *sdk_adBuryDic);\n\n\n@end" (() " " (ERROR) "*" (^) "*" (identifier) "sdk_adBuryDic);\n\n\n@en" ()) "d" (parameter_list) "\n\nNS_ASSUME_NONNULL_END\n" (() "\n" (parameter_declaration) "\nNS_ASSUME_NONNULL_END\n" (type_identifier) "\nNS_ASSUME_N" (pointer_declarator) "NNULL_END\n" (*) "N" (identifier) "NULL_END\n" ()) "" (;) "" (comment) "" (comment) "" (ERROR) "" (ERROR) "" (expression_statement) "" (call_expression) "" (identifier) "" (argument_list) "" (() "" (identifier) "" (,) "" (identifier) "" ()) "" (;) "" (declaration) "" (primitive_type) "" (function_declarator) "" (parenthesized_declarator) "" (() "" (ERROR) "" (^) "" (identifier) "" ()) "" (parameter_list) "" (() "" (parameter_declaration) "" (type_identifier) "" (pointer_declarator) "" (*) "" (identifier) "" ()) "" (;) "" (ERROR) "" (ERROR) "" (declaration) "" (type_identifier) "" (identifier) "" (;) ""
234
25
{"language": "c", "success": true, "metadata": {"lines": 38, "avg_line_length": 29.16, "nodes": 143, "errors": 0, "source_hash": "5cce6aea3b93dddcef442dd6e9c00d4c64cc831d257765a1deceff5b528c0b43", "categorized_nodes": 82}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "import <Foundation/Foundation.h>\n#", "parent": null, "children": [1], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 1, "type": "preproc_arg", "text": "Foundation/Foundation.h>\n", "parent": 0, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 33}}, {"id": 2, "type": "preproc_call", "text": "import <UIKit/UIKit.h>\n\n", "parent": null, "children": [3], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 3, "type": "preproc_arg", "text": "UIKit/UIKit.h>\n", "parent": 2, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 23}}, {"id": 4, "type": "declaration", "text": "S_ASSUME_NONNULL_BEGIN\n\n@interface ", "parent": null, "children": [5, 6, 8], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 13, "column": 10}}, {"id": 5, "type": "type_identifier", "text": "S_ASSUME_NONNULL_BEGIN\n", "parent": 4, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 23}}, {"id": 6, "type": "ERROR", "text": "i", "parent": 4, "children": [7], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 7, "type": "ERROR", "text": "i", "parent": 6, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 8, "type": "identifier", "text": "nterface ", "parent": 4, "children": [], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 10}}, {"id": 9, "type": "labeled_statement", "text": "LNewsSDKVideoTabModeManager : NSObject\n\n+ (instancetype)shareManager;\n", "parent": null, "children": [10], "start_point": {"row": 13, "column": 11}, "end_point": {"row": 15, "column": 29}}, {"id": 10, "type": "statement_identifier", "text": "LNewsSDKVideoTabModeManager ", "parent": 9, "children": [], "start_point": {"row": 13, "column": 11}, "end_point": {"row": 13, "column": 39}}, {"id": 11, "type": "binary_expression", "text": "SObject\n\n+ (instancetype)shareManager;", "parent": 9, "children": [12, 13, 14], "start_point": {"row": 13, "column": 42}, "end_point": {"row": 15, "column": 28}}, {"id": 12, "type": "identifier", "text": "SObject\n", "parent": 11, "children": [], "start_point": {"row": 13, "column": 42}, "end_point": {"row": 13, "column": 50}}, {"id": 13, "type": "+", "text": " ", "parent": 11, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 1}}, {"id": 14, "type": "cast_expression", "text": "instancetype)shareManager;", "parent": 11, "children": [15, 17], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 28}}, {"id": 15, "type": "type_descriptor", "text": "nstancetype)", "parent": 14, "children": [16], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 15}}, {"id": 16, "type": "type_identifier", "text": "nstancetype)", "parent": 15, "children": [], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 15}}, {"id": 17, "type": "identifier", "text": "hareManager;", "parent": 14, "children": [], "start_point": {"row": 15, "column": 16}, "end_point": {"row": 15, "column": 28}}, {"id": 18, "type": "ERROR", "text": "atomic)BOOL isHoverMode;\n\n///\u662f\u5426\u6709", "parent": null, "children": [19, 20, 25], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 32}}, {"id": 19, "type": "ERROR", "text": "a", "parent": 18, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 1}}, {"id": 20, "type": "call_expression", "text": "tomic)BOOL isHoverMode;\n\n//", "parent": 18, "children": [21, 22], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 28}}, {"id": 21, "type": "identifier", "text": "tomic)BO", "parent": 20, "children": [], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 9}}, {"id": 22, "type": "argument_list", "text": "L isHoverMode;\n\n//", "parent": 20, "children": [23, 24], "start_point": {"row": 18, "column": 10}, "end_point": {"row": 18, "column": 28}}, {"id": 23, "type": "identifier", "text": " isHov", "parent": 22, "children": [], "start_point": {"row": 18, "column": 11}, "end_point": {"row": 18, "column": 17}}, {"id": 24, "type": "identifier", "text": "rMode;\n\n/", "parent": 22, "children": [], "start_point": {"row": 18, "column": 18}, "end_point": {"row": 18, "column": 27}}, {"id": 25, "type": "identifier", "text": "/\u662f\u5426\u6709", "parent": 18, "children": [], "start_point": {"row": 18, "column": 28}, "end_point": {"row": 18, "column": 32}}, {"id": 26, "type": "identifier", "text": "\u822a\u680f \u9ed8\u8ba4\u4e3aNO\n@p", "parent": null, "children": [], "start_point": {"row": 18, "column": 33}, "end_point": {"row": 18, "column": 44}}, {"id": 27, "type": "ERROR", "text": "Nav;\n\n///\u662f\u5426\u6709tabbar \u9ed8\u8ba4\u4e3aNO\n@proper", "parent": null, "children": [28, 29, 34], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 32}}, {"id": 28, "type": "ERROR", "text": "N", "parent": 27, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 1}}, {"id": 29, "type": "call_expression", "text": "av;\n\n///\u662f\u5426\u6709tabbar \u9ed8\u8ba4\u4e3aNO\n@pr", "parent": 27, "children": [30, 31], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 28}}, {"id": 30, "type": "identifier", "text": "av;\n\n///", "parent": 29, "children": [], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 9}}, {"id": 31, "type": "argument_list", "text": "\u5426\u6709tabbar \u9ed8\u8ba4\u4e3aNO\n@pr", "parent": 29, "children": [32, 33], "start_point": {"row": 21, "column": 10}, "end_point": {"row": 21, "column": 28}}, {"id": 32, "type": "identifier", "text": "\u6709tabba", "parent": 31, "children": [], "start_point": {"row": 21, "column": 11}, "end_point": {"row": 21, "column": 17}}, {"id": 33, "type": "identifier", "text": " \u9ed8\u8ba4\u4e3aNO\n@p", "parent": 31, "children": [], "start_point": {"row": 21, "column": 18}, "end_point": {"row": 21, "column": 27}}, {"id": 34, "type": "identifier", "text": "oper", "parent": 27, "children": [], "start_point": {"row": 21, "column": 28}, "end_point": {"row": 21, "column": 32}}, {"id": 35, "type": "identifier", "text": "y (assign", "parent": null, "children": [], "start_point": {"row": 21, "column": 33}, "end_point": {"row": 21, "column": 42}}, {"id": 36, "type": "ERROR", "text": "\u662f\u5426\u9700\u8981\u5237\u65b0\u6309\u94ae \u9ed8\u8ba4\u4e3aNO\n@property (assign", "parent": null, "children": [37, 38, 43], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 32}}, {"id": 37, "type": "ERROR", "text": "\u662f", "parent": 36, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 1}}, {"id": 38, "type": "call_expression", "text": "\u5426\u9700\u8981\u5237\u65b0\u6309\u94ae \u9ed8\u8ba4\u4e3aNO\n@property (as", "parent": 36, "children": [39, 40], "start_point": {"row": 24, "column": 1}, "end_point": {"row": 24, "column": 28}}, {"id": 39, "type": "identifier", "text": "\u5426\u9700\u8981\u5237\u65b0\u6309\u94ae ", "parent": 38, "children": [], "start_point": {"row": 24, "column": 1}, "end_point": {"row": 24, "column": 9}}, {"id": 40, "type": "argument_list", "text": "\u8ba4\u4e3aNO\n@property (as", "parent": 38, "children": [41, 42], "start_point": {"row": 24, "column": 10}, "end_point": {"row": 24, "column": 28}}, {"id": 41, "type": "identifier", "text": "\u4e3aNO\n@p", "parent": 40, "children": [], "start_point": {"row": 24, "column": 11}, "end_point": {"row": 24, "column": 17}}, {"id": 42, "type": "identifier", "text": "operty (a", "parent": 40, "children": [], "start_point": {"row": 24, "column": 18}, "end_point": {"row": 24, "column": 27}}, {"id": 43, "type": "identifier", "text": "sign", "parent": 36, "children": [], "start_point": {"row": 24, "column": 28}, "end_point": {"row": 24, "column": 32}}, {"id": 44, "type": "identifier", "text": "nonatomic)BO", "parent": null, "children": [], "start_point": {"row": 24, "column": 33}, "end_point": {"row": 24, "column": 45}}, {"id": 45, "type": "ERROR", "text": "perty (copy,nonatomic)NSString *", "parent": null, "children": [46, 47, 52], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 32}}, {"id": 46, "type": "ERROR", "text": "p", "parent": 45, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 1}}, {"id": 47, "type": "call_expression", "text": "erty (copy,nonatomic)NSStri", "parent": 45, "children": [48, 49], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 28}}, {"id": 48, "type": "identifier", "text": "erty (co", "parent": 47, "children": [], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 9}}, {"id": 49, "type": "argument_list", "text": "y,nonatomic)NSStri", "parent": 47, "children": [50, 51], "start_point": {"row": 27, "column": 10}, "end_point": {"row": 27, "column": 28}}, {"id": 50, "type": "identifier", "text": ",nonat", "parent": 49, "children": [], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 17}}, {"id": 51, "type": "identifier", "text": "mic)NSStr", "parent": 49, "children": [], "start_point": {"row": 27, "column": 18}, "end_point": {"row": 27, "column": 27}}, {"id": 52, "type": "identifier", "text": "ng *", "parent": 45, "children": [], "start_point": {"row": 27, "column": 28}, "end_point": {"row": 27, "column": 32}}, {"id": 53, "type": "identifier", "text": "WXShareAPPID;\n///qq\u5206", "parent": null, "children": [], "start_point": {"row": 27, "column": 33}, "end_point": {"row": 27, "column": 53}}, {"id": 54, "type": "ERROR", "text": "o", "parent": null, "children": [55], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 1}}, {"id": 55, "type": "ERROR", "text": "o", "parent": 54, "children": [], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 1}}, {"id": 56, "type": "call_expression", "text": "natomic)NSString * QQShar", "parent": null, "children": [57, 58], "start_point": {"row": 30, "column": 1}, "end_point": {"row": 30, "column": 26}}, {"id": 57, "type": "identifier", "text": "natomic)", "parent": 56, "children": [], "start_point": {"row": 30, "column": 1}, "end_point": {"row": 30, "column": 9}}, {"id": 58, "type": "argument_list", "text": "SString * QQShar", "parent": 56, "children": [59, 60], "start_point": {"row": 30, "column": 10}, "end_point": {"row": 30, "column": 26}}, {"id": 59, "type": "identifier", "text": "Stri", "parent": 58, "children": [], "start_point": {"row": 30, "column": 11}, "end_point": {"row": 30, "column": 15}}, {"id": 60, "type": "identifier", "text": "g * QQSha", "parent": 58, "children": [], "start_point": {"row": 30, "column": 16}, "end_point": {"row": 30, "column": 25}}, {"id": 61, "type": "declaration", "text": "eAPPID;\n\n\n/// \u6eda\u52a8\u89c6\u56fe\u56de\u8c03\uff08\u4f9b\u5bbf\u4e3b", "parent": null, "children": [62, 63], "start_point": {"row": 30, "column": 26}, "end_point": {"row": 30, "column": 50}}, {"id": 62, "type": "type_identifier", "text": "eAPPID;\n", "parent": 61, "children": [], "start_point": {"row": 30, "column": 26}, "end_point": {"row": 30, "column": 34}}, {"id": 63, "type": "pointer_declarator", "text": "\n/// \u6eda\u52a8\u89c6\u56fe\u56de\u8c03\uff08\u4f9b\u5bbf", "parent": 61, "children": [64, 65], "start_point": {"row": 30, "column": 35}, "end_point": {"row": 30, "column": 49}}, {"id": 64, "type": "*", "text": "\n", "parent": 63, "children": [], "start_point": {"row": 30, "column": 35}, "end_point": {"row": 30, "column": 36}}, {"id": 65, "type": "identifier", "text": "// \u6eda\u52a8\u89c6\u56fe\u56de\u8c03\uff08\u4f9b\u5bbf", "parent": 63, "children": [], "start_point": {"row": 30, "column": 37}, "end_point": {"row": 30, "column": 49}}, {"id": 66, "type": "ERROR", "text": "m", "parent": null, "children": [67], "start_point": {"row": 32, "column": 0}, "end_point": {"row": 32, "column": 1}}, {"id": 67, "type": "ERROR", "text": "m", "parent": 66, "children": [], "start_point": {"row": 32, "column": 0}, "end_point": {"row": 32, "column": 1}}, {"id": 68, "type": "call_expression", "text": " scrollview \u56de\u8c03\u7684\u6eda\u52a8\u89c6\u56fe\n@prop", "parent": null, "children": [69, 70], "start_point": {"row": 32, "column": 1}, "end_point": {"row": 32, "column": 26}}, {"id": 69, "type": "identifier", "text": " scrollv", "parent": 68, "children": [], "start_point": {"row": 32, "column": 1}, "end_point": {"row": 32, "column": 9}}, {"id": 70, "type": "argument_list", "text": "ew \u56de\u8c03\u7684\u6eda\u52a8\u89c6\u56fe\n@prop", "parent": 68, "children": [71, 72], "start_point": {"row": 32, "column": 10}, "end_point": {"row": 32, "column": 26}}, {"id": 71, "type": "identifier", "text": "w \u56de\u8c03", "parent": 70, "children": [], "start_point": {"row": 32, "column": 11}, "end_point": {"row": 32, "column": 15}}, {"id": 72, "type": "identifier", "text": "\u6eda\u52a8\u89c6\u56fe\n@pro", "parent": 70, "children": [], "start_point": {"row": 32, "column": 16}, "end_point": {"row": 32, "column": 25}}, {"id": 73, "type": "declaration", "text": "erty (nonatomic, copy) v", "parent": null, "children": [74, 75], "start_point": {"row": 32, "column": 26}, "end_point": {"row": 32, "column": 50}}, {"id": 74, "type": "type_identifier", "text": "erty (no", "parent": 73, "children": [], "start_point": {"row": 32, "column": 26}, "end_point": {"row": 32, "column": 34}}, {"id": 75, "type": "pointer_declarator", "text": "atomic, copy) ", "parent": 73, "children": [76, 77], "start_point": {"row": 32, "column": 35}, "end_point": {"row": 32, "column": 49}}, {"id": 76, "type": "*", "text": "a", "parent": 75, "children": [], "start_point": {"row": 32, "column": 35}, "end_point": {"row": 32, "column": 36}}, {"id": 77, "type": "identifier", "text": "omic, copy) ", "parent": 75, "children": [], "start_point": {"row": 32, "column": 37}, "end_point": {"row": 32, "column": 49}}, {"id": 78, "type": "ERROR", "text": "\u8c03", "parent": null, "children": [79], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 37, "column": 1}}, {"id": 79, "type": "ERROR", "text": "\u8c03", "parent": 78, "children": [], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 37, "column": 1}}, {"id": 80, "type": "call_expression", "text": "\u6570\u636e\n@property (nonatomic, c", "parent": null, "children": [81, 82], "start_point": {"row": 37, "column": 1}, "end_point": {"row": 37, "column": 27}}, {"id": 81, "type": "identifier", "text": "\u6570\u636e\n@prop", "parent": 80, "children": [], "start_point": {"row": 37, "column": 1}, "end_point": {"row": 37, "column": 9}}, {"id": 82, "type": "argument_list", "text": "rty (nonatomic, c", "parent": 80, "children": [83, 84], "start_point": {"row": 37, "column": 10}, "end_point": {"row": 37, "column": 27}}, {"id": 83, "type": "identifier", "text": "ty (nonat", "parent": 82, "children": [], "start_point": {"row": 37, "column": 11}, "end_point": {"row": 37, "column": 20}}, {"id": 84, "type": "identifier", "text": "ic, ", "parent": 82, "children": [], "start_point": {"row": 37, "column": 22}, "end_point": {"row": 37, "column": 26}}, {"id": 85, "type": "declaration", "text": "py) void(^sdk_newsDataBuryBlock)(NSDictionary *sd", "parent": null, "children": [86, 87], "start_point": {"row": 37, "column": 28}, "end_point": {"row": 37, "column": 77}}, {"id": 86, "type": "primitive_type", "text": "py) ", "parent": 85, "children": [], "start_point": {"row": 37, "column": 28}, "end_point": {"row": 37, "column": 32}}, {"id": 87, "type": "function_declarator", "text": "void(^sdk_newsDataBuryBlock)(NSDictionary *s", "parent": 85, "children": [88, 92], "start_point": {"row": 37, "column": 32}, "end_point": {"row": 37, "column": 76}}, {"id": 88, "type": "parenthesized_declarator", "text": "void(^sdk_newsData", "parent": 87, "children": [89, 91], "start_point": {"row": 37, "column": 32}, "end_point": {"row": 37, "column": 50}}, {"id": 89, "type": "ERROR", "text": "o", "parent": 88, "children": [90], "start_point": {"row": 37, "column": 33}, "end_point": {"row": 37, "column": 34}}, {"id": 90, "type": "^", "text": "o", "parent": 89, "children": [], "start_point": {"row": 37, "column": 33}, "end_point": {"row": 37, "column": 34}}, {"id": 91, "type": "identifier", "text": "id(^sdk_newsDat", "parent": 88, "children": [], "start_point": {"row": 37, "column": 34}, "end_point": {"row": 37, "column": 49}}, {"id": 92, "type": "parameter_list", "text": "BuryBlock)(NSDictionary *s", "parent": 87, "children": [93], "start_point": {"row": 37, "column": 50}, "end_point": {"row": 37, "column": 76}}, {"id": 93, "type": "parameter_declaration", "text": "uryBlock)(NSDictionary *", "parent": 92, "children": [94, 95], "start_point": {"row": 37, "column": 51}, "end_point": {"row": 37, "column": 75}}, {"id": 94, "type": "type_identifier", "text": "uryBlock)(NS", "parent": 93, "children": [], "start_point": {"row": 37, "column": 51}, "end_point": {"row": 37, "column": 63}}, {"id": 95, "type": "pointer_declarator", "text": "ictionary *", "parent": 93, "children": [96, 97], "start_point": {"row": 37, "column": 64}, "end_point": {"row": 37, "column": 75}}, {"id": 96, "type": "*", "text": "i", "parent": 95, "children": [], "start_point": {"row": 37, "column": 64}, "end_point": {"row": 37, "column": 65}}, {"id": 97, "type": "identifier", "text": "ctionary *", "parent": 95, "children": [], "start_point": {"row": 37, "column": 65}, "end_point": {"row": 37, "column": 75}}, {"id": 98, "type": "ERROR", "text": "d", "parent": null, "children": [99], "start_point": {"row": 42, "column": 0}, "end_point": {"row": 42, "column": 1}}, {"id": 99, "type": "ERROR", "text": "d", "parent": 98, "children": [], "start_point": {"row": 42, "column": 0}, "end_point": {"row": 42, "column": 1}}, {"id": 100, "type": "call_expression", "text": "(^sdk_ADBuryBlock)(NSDicti", "parent": null, "children": [101, 102], "start_point": {"row": 42, "column": 1}, "end_point": {"row": 42, "column": 27}}, {"id": 101, "type": "identifier", "text": "(^sdk_AD", "parent": 100, "children": [], "start_point": {"row": 42, "column": 1}, "end_point": {"row": 42, "column": 9}}, {"id": 102, "type": "argument_list", "text": "uryBlock)(NSDicti", "parent": 100, "children": [103, 104], "start_point": {"row": 42, "column": 10}, "end_point": {"row": 42, "column": 27}}, {"id": 103, "type": "identifier", "text": "ryBlock)(", "parent": 102, "children": [], "start_point": {"row": 42, "column": 11}, "end_point": {"row": 42, "column": 20}}, {"id": 104, "type": "identifier", "text": "Dict", "parent": 102, "children": [], "start_point": {"row": 42, "column": 22}, "end_point": {"row": 42, "column": 26}}, {"id": 105, "type": "declaration", "text": "nary *sdk_adBuryDic);\n\n\n@end\n\nNS_ASSUME_NONNULL_END\n", "parent": null, "children": [106, 107], "start_point": {"row": 42, "column": 28}, "end_point": {"row": 42, "column": 92}}, {"id": 106, "type": "primitive_type", "text": "nary", "parent": 105, "children": [], "start_point": {"row": 42, "column": 28}, "end_point": {"row": 42, "column": 32}}, {"id": 107, "type": "function_declarator", "text": " *sdk_adBuryDic);\n\n\n@end\n\nNS_ASSUME_NONNULL_END\n", "parent": 105, "children": [108, 112], "start_point": {"row": 42, "column": 32}, "end_point": {"row": 42, "column": 91}}, {"id": 108, "type": "parenthesized_declarator", "text": " *sdk_adBuryDic);\n\n\n@end", "parent": 107, "children": [109, 111], "start_point": {"row": 42, "column": 32}, "end_point": {"row": 42, "column": 56}}, {"id": 109, "type": "ERROR", "text": "*", "parent": 108, "children": [110], "start_point": {"row": 42, "column": 33}, "end_point": {"row": 42, "column": 34}}, {"id": 110, "type": "^", "text": "*", "parent": 109, "children": [], "start_point": {"row": 42, "column": 33}, "end_point": {"row": 42, "column": 34}}, {"id": 111, "type": "identifier", "text": "sdk_adBuryDic);\n\n\n@en", "parent": 108, "children": [], "start_point": {"row": 42, "column": 34}, "end_point": {"row": 42, "column": 55}}, {"id": 112, "type": "parameter_list", "text": "\n\nNS_ASSUME_NONNULL_END\n", "parent": 107, "children": [113], "start_point": {"row": 42, "column": 56}, "end_point": {"row": 42, "column": 91}}, {"id": 113, "type": "parameter_declaration", "text": "\nNS_ASSUME_NONNULL_END\n", "parent": 112, "children": [114, 115], "start_point": {"row": 42, "column": 57}, "end_point": {"row": 42, "column": 90}}, {"id": 114, "type": "type_identifier", "text": "\nNS_ASSUME_N", "parent": 113, "children": [], "start_point": {"row": 42, "column": 57}, "end_point": {"row": 42, "column": 69}}, {"id": 115, "type": "pointer_declarator", "text": "NNULL_END\n", "parent": 113, "children": [116, 117], "start_point": {"row": 42, "column": 70}, "end_point": {"row": 42, "column": 90}}, {"id": 116, "type": "*", "text": "N", "parent": 115, "children": [], "start_point": {"row": 42, "column": 70}, "end_point": {"row": 42, "column": 71}}, {"id": 117, "type": "identifier", "text": "NULL_END\n", "parent": 115, "children": [], "start_point": {"row": 42, "column": 71}, "end_point": {"row": 42, "column": 90}}, {"id": 118, "type": "ERROR", "text": "", "parent": null, "children": [119], "start_point": {"row": 46, "column": 0}, "end_point": {"row": 46, "column": 1}}, {"id": 119, "type": "ERROR", "text": "", "parent": 118, "children": [], "start_point": {"row": 46, "column": 0}, "end_point": {"row": 46, "column": 1}}, {"id": 120, "type": "call_expression", "text": "", "parent": null, "children": [121, 122], "start_point": {"row": 46, "column": 1}, "end_point": {"row": 46, "column": 27}}, {"id": 121, "type": "identifier", "text": "", "parent": 120, "children": [], "start_point": {"row": 46, "column": 1}, "end_point": {"row": 46, "column": 9}}, {"id": 122, "type": "argument_list", "text": "", "parent": 120, "children": [123, 124], "start_point": {"row": 46, "column": 10}, "end_point": {"row": 46, "column": 27}}, {"id": 123, "type": "identifier", "text": "", "parent": 122, "children": [], "start_point": {"row": 46, "column": 11}, "end_point": {"row": 46, "column": 20}}, {"id": 124, "type": "identifier", "text": "", "parent": 122, "children": [], "start_point": {"row": 46, "column": 22}, "end_point": {"row": 46, "column": 26}}, {"id": 125, "type": "declaration", "text": "", "parent": null, "children": [126, 127], "start_point": {"row": 46, "column": 28}, "end_point": {"row": 46, "column": 80}}, {"id": 126, "type": "primitive_type", "text": "", "parent": 125, "children": [], "start_point": {"row": 46, "column": 28}, "end_point": {"row": 46, "column": 32}}, {"id": 127, "type": "function_declarator", "text": "", "parent": 125, "children": [128, 132], "start_point": {"row": 46, "column": 32}, "end_point": {"row": 46, "column": 79}}, {"id": 128, "type": "parenthesized_declarator", "text": "", "parent": 127, "children": [129, 131], "start_point": {"row": 46, "column": 32}, "end_point": {"row": 46, "column": 50}}, {"id": 129, "type": "ERROR", "text": "", "parent": 128, "children": [130], "start_point": {"row": 46, "column": 33}, "end_point": {"row": 46, "column": 34}}, {"id": 130, "type": "^", "text": "", "parent": 129, "children": [], "start_point": {"row": 46, "column": 33}, "end_point": {"row": 46, "column": 34}}, {"id": 131, "type": "identifier", "text": "", "parent": 128, "children": [], "start_point": {"row": 46, "column": 34}, "end_point": {"row": 46, "column": 49}}, {"id": 132, "type": "parameter_list", "text": "", "parent": 127, "children": [133], "start_point": {"row": 46, "column": 50}, "end_point": {"row": 46, "column": 79}}, {"id": 133, "type": "parameter_declaration", "text": "", "parent": 132, "children": [134, 135], "start_point": {"row": 46, "column": 51}, "end_point": {"row": 46, "column": 78}}, {"id": 134, "type": "type_identifier", "text": "", "parent": 133, "children": [], "start_point": {"row": 46, "column": 51}, "end_point": {"row": 46, "column": 63}}, {"id": 135, "type": "pointer_declarator", "text": "", "parent": 133, "children": [136, 137], "start_point": {"row": 46, "column": 64}, "end_point": {"row": 46, "column": 78}}, {"id": 136, "type": "*", "text": "", "parent": 135, "children": [], "start_point": {"row": 46, "column": 64}, "end_point": {"row": 46, "column": 65}}, {"id": 137, "type": "identifier", "text": "", "parent": 135, "children": [], "start_point": {"row": 46, "column": 65}, "end_point": {"row": 46, "column": 78}}, {"id": 138, "type": "ERROR", "text": "", "parent": null, "children": [139], "start_point": {"row": 49, "column": 0}, "end_point": {"row": 49, "column": 1}}, {"id": 139, "type": "ERROR", "text": "", "parent": 138, "children": [], "start_point": {"row": 49, "column": 0}, "end_point": {"row": 49, "column": 1}}, {"id": 140, "type": "declaration", "text": "", "parent": null, "children": [141, 142], "start_point": {"row": 49, "column": 1}, "end_point": {"row": 51, "column": 21}}, {"id": 141, "type": "type_identifier", "text": "", "parent": 140, "children": [], "start_point": {"row": 49, "column": 1}, "end_point": {"row": 49, "column": 4}}, {"id": 142, "type": "identifier", "text": "", "parent": 140, "children": [], "start_point": {"row": 51, "column": 0}, "end_point": {"row": 51, "column": 21}}]}, "node_categories": {"declarations": {"functions": [87, 107, 127], "variables": [4, 61, 73, 85, 93, 105, 113, 125, 133, 140], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [11, 14, 20, 29, 38, 47, 56, 68, 80, 100, 120], "assignments": [], "loops": [], "conditionals": [5, 8, 10, 12, 16, 17, 21, 23, 24, 25, 26, 30, 32, 33, 34, 35, 39, 41, 42, 43, 44, 48, 50, 51, 52, 53, 57, 59, 60, 62, 65, 69, 71, 72, 74, 77, 81, 83, 84, 91, 94, 97, 101, 103, 104, 111, 114, 117, 121, 123, 124, 131, 134, 137, 141, 142], "returns": [], "exceptions": []}, "expressions": {"calls": [0, 2], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 87, "universal_type": "function", "name": "unknown", "text_snippet": "void(^sdk_newsDataBuryBlock)(NSDictionary *s"}, {"node_id": 107, "universal_type": "function", "name": "unknown", "text_snippet": " *sdk_adBuryDic);\n\n\n@end\n\nNS_ASSUME_NONNULL_END\n"}], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// YLNewsSDKModeManager.h\n// YLInfoFlowSDK\n//\n// Created by Apple on 2020/6/23.\n// Copyright \u00a9 2020 com.qujie.tech. All rights reserved.\n//\n\n#import <Foundation/Foundation.h>\n#import <UIKit/UIKit.h>\n\nNS_ASSUME_NONNULL_BEGIN\n\n@interface YLNewsSDKVideoTabModeManager : NSObject\n\n+ (instancetype)shareManager;\n\n///\u662f\u5426\u662f\u60ac\u505c\u6548\u679c \u9ed8\u8ba4\u4e3aNO\n@property (assign,nonatomic)BOOL isHoverMode;\n\n///\u662f\u5426\u6709\u5bfc\u822a\u680f \u9ed8\u8ba4\u4e3aNO\n@property (assign,nonatomic)BOOL isHaveNav;\n\n///\u662f\u5426\u6709tabbar \u9ed8\u8ba4\u4e3aNO\n@property (assign,nonatomic)BOOL isHaveTabbar;\n\n///\u662f\u5426\u9700\u8981\u5237\u65b0\u6309\u94ae \u9ed8\u8ba4\u4e3aNO\n@property (assign,nonatomic)BOOL isNeedRefreashButton;\n\n///\u5fae\u4fe1\u5206\u4eabappid\n@property (copy,nonatomic)NSString * WXShareAPPID;\n///qq\u5206\u4eabappid\n@property (copy,nonatomic)NSString * QQShareAPPID;\n\n\n/// \u6eda\u52a8\u89c6\u56fe\u56de\u8c03\uff08\u4f9b\u5bbf\u4e3b\u5224\u65ad\u662f\u5426\u53ef\u6eda\u52a8\uff09\n/// @param scrollview \u56de\u8c03\u7684\u6eda\u52a8\u89c6\u56fe\n@property (nonatomic, copy) void(^scrollviewBlock)(UIScrollView *scrollview);\n\n\n/// \u65b0\u95fb/\u89c6\u9891\u5c55\u793a\u7b49\u6570\u636e\u56de\u8c03\u7ed9\u5bbf\u4e3b\u4f9b\u57cb\u70b9\n/// @param sdk_newsDataBuryDic \u56de\u8c03\u6570\u636e\n@property (nonatomic, copy) void(^sdk_newsDataBuryBlock)(NSDictionary *sdk_newsDataBuryDic);\n\n/// \u5e7f\u544a\u6570\u636e\u56de\u8c03\u7ed9\u5bbf\u4e3b\u4f9b\u57cb\u70b9\n/// @param sdk_adBuryDic \u56de\u8c03\u7684\u5e7f\u544a\u57cb\u70b9\u6570\u636e\n@property (nonatomic, copy) void(^sdk_ADBuryBlock)(NSDictionary *sdk_adBuryDic);\n\n\n@end\n\nNS_ASSUME_NONNULL_END\n"}
80,563
c
/****************************************************************************** * xc_pagetab.c * * Function to translate virtual to physical addresses. * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; * version 2.1 of the License. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; If not, see <http://www.gnu.org/licenses/>. */ #include "xc_private.h" #include <xen/hvm/save.h> #define CR0_PG 0x80000000 #define CR4_PAE 0x20 #define PTE_PSE 0x80 #define EFER_LMA 0x400 unsigned long xc_translate_foreign_address(xc_interface *xch, uint32_t dom, int vcpu, unsigned long long virt) { xc_dominfo_t dominfo; uint64_t paddr, mask, pte = 0; int size, level, pt_levels = 2; void *map; if (xc_domain_getinfo(xch, dom, 1, &dominfo) != 1 || dominfo.domid != dom) return 0; /* What kind of paging are we dealing with? */ if (dominfo.hvm) { struct hvm_hw_cpu ctx; if (xc_domain_hvm_getcontext_partial(xch, dom, HVM_SAVE_CODE(CPU), vcpu, &ctx, sizeof ctx) != 0) return 0; if (!(ctx.cr0 & CR0_PG)) return virt >> PAGE_SHIFT; pt_levels = (ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2; paddr = ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull); } else { unsigned int gwidth; vcpu_guest_context_any_t ctx; if (xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0) return 0; if (xc_domain_get_guest_width(xch, dom, &gwidth) != 0) return 0; if (gwidth == 8) { pt_levels = 4; paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3]) << PAGE_SHIFT; } else { pt_levels = 3; paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3]) << PAGE_SHIFT; } } if (pt_levels == 4) { virt &= 0x0000ffffffffffffull; mask = 0x0000ff8000000000ull; } else if (pt_levels == 3) { virt &= 0x00000000ffffffffull; mask = 0x0000007fc0000000ull; } else { virt &= 0x00000000ffffffffull; mask = 0x00000000ffc00000ull; } size = (pt_levels == 2 ? 4 : 8); /* Walk the pagetables */ for (level = pt_levels; level > 0; level--) { paddr += ((virt & mask) >> (xc_ffs64(mask) - 1)) * size; map = xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, paddr >>PAGE_SHIFT); if (!map) return 0; memcpy(&pte, map + (paddr & (PAGE_SIZE - 1)), size); munmap(map, PAGE_SIZE); if (!(pte & 1)) return 0; paddr = pte & 0x000ffffffffff000ull; if (level == 2 && (pte & PTE_PSE)) { mask = ((mask ^ ~-mask) >> 1); /* All bits below first set bit */ return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT; } mask >>= (pt_levels == 2 ? 10 : 9); } return paddr >> PAGE_SHIFT; } /* * Local variables: * mode: C * c-file-style: "BSD" * c-basic-offset: 4 * tab-width: 4 * indent-tabs-mode: nil * End: */
34.6
103
(translation_unit) "/******************************************************************************\n * xc_pagetab.c\n *\n * Function to translate virtual to physical addresses.\n *\n * This library is free software; you can redistribute it and/or\n * modify it under the terms of the GNU Lesser General Public\n * License as published by the Free Software Foundation;\n * version 2.1 of the License.\n *\n * This library is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n * Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public\n * License along with this library; If not, see <http://www.gnu.org/licenses/>.\n */\n\n#include "xc_private.h"\n#include <xen/hvm/save.h>\n\n#define CR0_PG 0x80000000\n#define CR4_PAE 0x20\n#define PTE_PSE 0x80\n#define EFER_LMA 0x400\n\n\nunsigned long xc_translate_foreign_address(xc_interface *xch, uint32_t dom,\n int vcpu, unsigned long long virt)\n{\n xc_dominfo_t dominfo;\n uint64_t paddr, mask, pte = 0;\n int size, level, pt_levels = 2;\n void *map;\n\n if (xc_domain_getinfo(xch, dom, 1, &dominfo) != 1 \n || dominfo.domid != dom)\n return 0;\n\n /* What kind of paging are we dealing with? */\n if (dominfo.hvm) {\n struct hvm_hw_cpu ctx;\n if (xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0)\n return 0;\n if (!(ctx.cr0 & CR0_PG))\n return virt >> PAGE_SHIFT;\n pt_levels = (ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2;\n paddr = ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull);\n } else {\n unsigned int gwidth;\n vcpu_guest_context_any_t ctx;\n if (xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)\n return 0;\n if (xc_domain_get_guest_width(xch, dom, &gwidth) != 0)\n return 0;\n if (gwidth == 8) {\n pt_levels = 4;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;\n } else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }\n }\n\n if (pt_levels == 4) {\n virt &= 0x0000ffffffffffffull;\n mask = 0x0000ff8000000000ull;\n } else if (pt_levels == 3) {\n virt &= 0x00000000ffffffffull;\n mask = 0x0000007fc0000000ull;\n } else {\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }\n size = (pt_levels == 2 ? 4 : 8);\n\n /* Walk the pagetables */\n for (level = pt_levels; level > 0; level--) {\n paddr += ((virt & mask) >> (xc_ffs64(mask) - 1)) * size;\n map = xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT);\n if (!map) \n return 0;\n memcpy(&pte, map + (paddr & (PAGE_SIZE - 1)), size);\n munmap(map, PAGE_SIZE);\n if (!(pte & 1)) \n return 0;\n paddr = pte & 0x000ffffffffff000ull;\n if (level == 2 && (pte & PTE_PSE)) {\n mask = ((mask ^ ~-mask) >> 1); /* All bits below first set bit */\n return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT;\n }\n mask >>= (pt_levels == 2 ? 10 : 9);\n }\n return paddr >> PAGE_SHIFT;\n}\n\n/*\n * Local variables:\n * mode: C\n * c-file-style: "BSD"\n * c-basic-offset: 4\n * tab-width: 4\n * indent-tabs-mode: nil\n * End:\n */\n" (comment) "/******************************************************************************\n * xc_pagetab.c\n *\n * Function to translate virtual to physical addresses.\n *\n * This library is free software; you can redistribute it and/or\n * modify it under the terms of the GNU Lesser General Public\n * License as published by the Free Software Foundation;\n * version 2.1 of the License.\n *\n * This library is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n * Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public\n * License along with this library; If not, see <http://www.gnu.org/licenses/>.\n */" (preproc_include) "#include "xc_private.h"\n" (#include) "#include" (string_literal) ""xc_private.h"" (") """ (string_content) "xc_private.h" (") """ (preproc_include) "#include <xen/hvm/save.h>\n" (#include) "#include" (system_lib_string) "<xen/hvm/save.h>" (preproc_def) "#define CR0_PG 0x80000000\n" (#define) "#define" (identifier) "CR0_PG" (preproc_arg) "0x80000000" (preproc_def) "#define CR4_PAE 0x20\n" (#define) "#define" (identifier) "CR4_PAE" (preproc_arg) "0x20" (preproc_def) "#define PTE_PSE 0x80\n" (#define) "#define" (identifier) "PTE_PSE" (preproc_arg) "0x80" (preproc_def) "#define EFER_LMA 0x400\n" (#define) "#define" (identifier) "EFER_LMA" (preproc_arg) "0x400" (function_definition) "unsigned long xc_translate_foreign_address(xc_interface *xch, uint32_t dom,\n int vcpu, unsigned long long virt)\n{\n xc_dominfo_t dominfo;\n uint64_t paddr, mask, pte = 0;\n int size, level, pt_levels = 2;\n void *map;\n\n if (xc_domain_getinfo(xch, dom, 1, &dominfo) != 1 \n || dominfo.domid != dom)\n return 0;\n\n /* What kind of paging are we dealing with? */\n if (dominfo.hvm) {\n struct hvm_hw_cpu ctx;\n if (xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0)\n return 0;\n if (!(ctx.cr0 & CR0_PG))\n return virt >> PAGE_SHIFT;\n pt_levels = (ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2;\n paddr = ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull);\n } else {\n unsigned int gwidth;\n vcpu_guest_context_any_t ctx;\n if (xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)\n return 0;\n if (xc_domain_get_guest_width(xch, dom, &gwidth) != 0)\n return 0;\n if (gwidth == 8) {\n pt_levels = 4;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;\n } else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }\n }\n\n if (pt_levels == 4) {\n virt &= 0x0000ffffffffffffull;\n mask = 0x0000ff8000000000ull;\n } else if (pt_levels == 3) {\n virt &= 0x00000000ffffffffull;\n mask = 0x0000007fc0000000ull;\n } else {\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }\n size = (pt_levels == 2 ? 4 : 8);\n\n /* Walk the pagetables */\n for (level = pt_levels; level > 0; level--) {\n paddr += ((virt & mask) >> (xc_ffs64(mask) - 1)) * size;\n map = xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT);\n if (!map) \n return 0;\n memcpy(&pte, map + (paddr & (PAGE_SIZE - 1)), size);\n munmap(map, PAGE_SIZE);\n if (!(pte & 1)) \n return 0;\n paddr = pte & 0x000ffffffffff000ull;\n if (level == 2 && (pte & PTE_PSE)) {\n mask = ((mask ^ ~-mask) >> 1); /* All bits below first set bit */\n return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT;\n }\n mask >>= (pt_levels == 2 ? 10 : 9);\n }\n return paddr >> PAGE_SHIFT;\n}" (sized_type_specifier) "unsigned long" (unsigned) "unsigned" (long) "long" (function_declarator) "xc_translate_foreign_address(xc_interface *xch, uint32_t dom,\n int vcpu, unsigned long long virt)" (identifier) "xc_translate_foreign_address" (parameter_list) "(xc_interface *xch, uint32_t dom,\n int vcpu, unsigned long long virt)" (() "(" (parameter_declaration) "xc_interface *xch" (type_identifier) "xc_interface" (pointer_declarator) "*xch" (*) "*" (identifier) "xch" (,) "," (parameter_declaration) "uint32_t dom" (primitive_type) "uint32_t" (identifier) "dom" (,) "," (parameter_declaration) "int vcpu" (primitive_type) "int" (identifier) "vcpu" (,) "," (parameter_declaration) "unsigned long long virt" (sized_type_specifier) "unsigned long long" (unsigned) "unsigned" (long) "long" (long) "long" (identifier) "virt" ()) ")" (compound_statement) "{\n xc_dominfo_t dominfo;\n uint64_t paddr, mask, pte = 0;\n int size, level, pt_levels = 2;\n void *map;\n\n if (xc_domain_getinfo(xch, dom, 1, &dominfo) != 1 \n || dominfo.domid != dom)\n return 0;\n\n /* What kind of paging are we dealing with? */\n if (dominfo.hvm) {\n struct hvm_hw_cpu ctx;\n if (xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0)\n return 0;\n if (!(ctx.cr0 & CR0_PG))\n return virt >> PAGE_SHIFT;\n pt_levels = (ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2;\n paddr = ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull);\n } else {\n unsigned int gwidth;\n vcpu_guest_context_any_t ctx;\n if (xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)\n return 0;\n if (xc_domain_get_guest_width(xch, dom, &gwidth) != 0)\n return 0;\n if (gwidth == 8) {\n pt_levels = 4;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;\n } else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }\n }\n\n if (pt_levels == 4) {\n virt &= 0x0000ffffffffffffull;\n mask = 0x0000ff8000000000ull;\n } else if (pt_levels == 3) {\n virt &= 0x00000000ffffffffull;\n mask = 0x0000007fc0000000ull;\n } else {\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }\n size = (pt_levels == 2 ? 4 : 8);\n\n /* Walk the pagetables */\n for (level = pt_levels; level > 0; level--) {\n paddr += ((virt & mask) >> (xc_ffs64(mask) - 1)) * size;\n map = xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT);\n if (!map) \n return 0;\n memcpy(&pte, map + (paddr & (PAGE_SIZE - 1)), size);\n munmap(map, PAGE_SIZE);\n if (!(pte & 1)) \n return 0;\n paddr = pte & 0x000ffffffffff000ull;\n if (level == 2 && (pte & PTE_PSE)) {\n mask = ((mask ^ ~-mask) >> 1); /* All bits below first set bit */\n return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT;\n }\n mask >>= (pt_levels == 2 ? 10 : 9);\n }\n return paddr >> PAGE_SHIFT;\n}" ({) "{" (declaration) "xc_dominfo_t dominfo;" (type_identifier) "xc_dominfo_t" (identifier) "dominfo" (;) ";" (declaration) "uint64_t paddr, mask, pte = 0;" (primitive_type) "uint64_t" (identifier) "paddr" (,) "," (identifier) "mask" (,) "," (init_declarator) "pte = 0" (identifier) "pte" (=) "=" (number_literal) "0" (;) ";" (declaration) "int size, level, pt_levels = 2;" (primitive_type) "int" (identifier) "size" (,) "," (identifier) "level" (,) "," (init_declarator) "pt_levels = 2" (identifier) "pt_levels" (=) "=" (number_literal) "2" (;) ";" (declaration) "void *map;" (primitive_type) "void" (pointer_declarator) "*map" (*) "*" (identifier) "map" (;) ";" (if_statement) "if (xc_domain_getinfo(xch, dom, 1, &dominfo) != 1 \n || dominfo.domid != dom)\n return 0;" (if) "if" (parenthesized_expression) "(xc_domain_getinfo(xch, dom, 1, &dominfo) != 1 \n || dominfo.domid != dom)" (() "(" (binary_expression) "xc_domain_getinfo(xch, dom, 1, &dominfo) != 1 \n || dominfo.domid != dom" (binary_expression) "xc_domain_getinfo(xch, dom, 1, &dominfo) != 1" (call_expression) "xc_domain_getinfo(xch, dom, 1, &dominfo)" (identifier) "xc_domain_getinfo" (argument_list) "(xch, dom, 1, &dominfo)" (() "(" (identifier) "xch" (,) "," (identifier) "dom" (,) "," (number_literal) "1" (,) "," (pointer_expression) "&dominfo" (&) "&" (identifier) "dominfo" ()) ")" (!=) "!=" (number_literal) "1" (||) "||" (binary_expression) "dominfo.domid != dom" (field_expression) "dominfo.domid" (identifier) "dominfo" (.) "." (field_identifier) "domid" (!=) "!=" (identifier) "dom" ()) ")" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (comment) "/* What kind of paging are we dealing with? */" (if_statement) "if (dominfo.hvm) {\n struct hvm_hw_cpu ctx;\n if (xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0)\n return 0;\n if (!(ctx.cr0 & CR0_PG))\n return virt >> PAGE_SHIFT;\n pt_levels = (ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2;\n paddr = ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull);\n } else {\n unsigned int gwidth;\n vcpu_guest_context_any_t ctx;\n if (xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)\n return 0;\n if (xc_domain_get_guest_width(xch, dom, &gwidth) != 0)\n return 0;\n if (gwidth == 8) {\n pt_levels = 4;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;\n } else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }\n }" (if) "if" (parenthesized_expression) "(dominfo.hvm)" (() "(" (field_expression) "dominfo.hvm" (identifier) "dominfo" (.) "." (field_identifier) "hvm" ()) ")" (compound_statement) "{\n struct hvm_hw_cpu ctx;\n if (xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0)\n return 0;\n if (!(ctx.cr0 & CR0_PG))\n return virt >> PAGE_SHIFT;\n pt_levels = (ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2;\n paddr = ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull);\n }" ({) "{" (declaration) "struct hvm_hw_cpu ctx;" (struct_specifier) "struct hvm_hw_cpu" (struct) "struct" (type_identifier) "hvm_hw_cpu" (identifier) "ctx" (;) ";" (if_statement) "if (xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0)\n return 0;" (if) "if" (parenthesized_expression) "(xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0)" (() "(" (binary_expression) "xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0" (call_expression) "xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx)" (identifier) "xc_domain_hvm_getcontext_partial" (argument_list) "(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx)" (() "(" (identifier) "xch" (,) "," (identifier) "dom" (,) "," (call_expression) "HVM_SAVE_CODE(CPU)" (identifier) "HVM_SAVE_CODE" (argument_list) "(CPU)" (() "(" (identifier) "CPU" ()) ")" (,) "," (identifier) "vcpu" (,) "," (pointer_expression) "&ctx" (&) "&" (identifier) "ctx" (,) "," (sizeof_expression) "sizeof ctx" (sizeof) "sizeof" (identifier) "ctx" ()) ")" (!=) "!=" (number_literal) "0" ()) ")" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (if_statement) "if (!(ctx.cr0 & CR0_PG))\n return virt >> PAGE_SHIFT;" (if) "if" (parenthesized_expression) "(!(ctx.cr0 & CR0_PG))" (() "(" (unary_expression) "!(ctx.cr0 & CR0_PG)" (!) "!" (parenthesized_expression) "(ctx.cr0 & CR0_PG)" (() "(" (binary_expression) "ctx.cr0 & CR0_PG" (field_expression) "ctx.cr0" (identifier) "ctx" (.) "." (field_identifier) "cr0" (&) "&" (identifier) "CR0_PG" ()) ")" ()) ")" (return_statement) "return virt >> PAGE_SHIFT;" (return) "return" (binary_expression) "virt >> PAGE_SHIFT" (identifier) "virt" (>>) ">>" (identifier) "PAGE_SHIFT" (;) ";" (expression_statement) "pt_levels = (ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2;" (assignment_expression) "pt_levels = (ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2" (identifier) "pt_levels" (=) "=" (conditional_expression) "(ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2" (parenthesized_expression) "(ctx.msr_efer&EFER_LMA)" (() "(" (binary_expression) "ctx.msr_efer&EFER_LMA" (field_expression) "ctx.msr_efer" (identifier) "ctx" (.) "." (field_identifier) "msr_efer" (&) "&" (identifier) "EFER_LMA" ()) ")" (?) "?" (number_literal) "4" (:) ":" (conditional_expression) "(ctx.cr4&CR4_PAE) ? 3 : 2" (parenthesized_expression) "(ctx.cr4&CR4_PAE)" (() "(" (binary_expression) "ctx.cr4&CR4_PAE" (field_expression) "ctx.cr4" (identifier) "ctx" (.) "." (field_identifier) "cr4" (&) "&" (identifier) "CR4_PAE" ()) ")" (?) "?" (number_literal) "3" (:) ":" (number_literal) "2" (;) ";" (expression_statement) "paddr = ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull);" (assignment_expression) "paddr = ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull)" (identifier) "paddr" (=) "=" (binary_expression) "ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull)" (field_expression) "ctx.cr3" (identifier) "ctx" (.) "." (field_identifier) "cr3" (&) "&" (parenthesized_expression) "((pt_levels == 3) ? ~0x1full : ~0xfffull)" (() "(" (conditional_expression) "(pt_levels == 3) ? ~0x1full : ~0xfffull" (parenthesized_expression) "(pt_levels == 3)" (() "(" (binary_expression) "pt_levels == 3" (identifier) "pt_levels" (==) "==" (number_literal) "3" ()) ")" (?) "?" (unary_expression) "~0x1full" (~) "~" (number_literal) "0x1full" (:) ":" (unary_expression) "~0xfffull" (~) "~" (number_literal) "0xfffull" ()) ")" (;) ";" (}) "}" (else_clause) "else {\n unsigned int gwidth;\n vcpu_guest_context_any_t ctx;\n if (xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)\n return 0;\n if (xc_domain_get_guest_width(xch, dom, &gwidth) != 0)\n return 0;\n if (gwidth == 8) {\n pt_levels = 4;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;\n } else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }\n }" (else) "else" (compound_statement) "{\n unsigned int gwidth;\n vcpu_guest_context_any_t ctx;\n if (xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)\n return 0;\n if (xc_domain_get_guest_width(xch, dom, &gwidth) != 0)\n return 0;\n if (gwidth == 8) {\n pt_levels = 4;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;\n } else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }\n }" ({) "{" (declaration) "unsigned int gwidth;" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "gwidth" (;) ";" (declaration) "vcpu_guest_context_any_t ctx;" (type_identifier) "vcpu_guest_context_any_t" (identifier) "ctx" (;) ";" (if_statement) "if (xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)\n return 0;" (if) "if" (parenthesized_expression) "(xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)" (() "(" (binary_expression) "xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0" (call_expression) "xc_vcpu_getcontext(xch, dom, vcpu, &ctx)" (identifier) "xc_vcpu_getcontext" (argument_list) "(xch, dom, vcpu, &ctx)" (() "(" (identifier) "xch" (,) "," (identifier) "dom" (,) "," (identifier) "vcpu" (,) "," (pointer_expression) "&ctx" (&) "&" (identifier) "ctx" ()) ")" (!=) "!=" (number_literal) "0" ()) ")" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (if_statement) "if (xc_domain_get_guest_width(xch, dom, &gwidth) != 0)\n return 0;" (if) "if" (parenthesized_expression) "(xc_domain_get_guest_width(xch, dom, &gwidth) != 0)" (() "(" (binary_expression) "xc_domain_get_guest_width(xch, dom, &gwidth) != 0" (call_expression) "xc_domain_get_guest_width(xch, dom, &gwidth)" (identifier) "xc_domain_get_guest_width" (argument_list) "(xch, dom, &gwidth)" (() "(" (identifier) "xch" (,) "," (identifier) "dom" (,) "," (pointer_expression) "&gwidth" (&) "&" (identifier) "gwidth" ()) ")" (!=) "!=" (number_literal) "0" ()) ")" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (if_statement) "if (gwidth == 8) {\n pt_levels = 4;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;\n } else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }" (if) "if" (parenthesized_expression) "(gwidth == 8)" (() "(" (binary_expression) "gwidth == 8" (identifier) "gwidth" (==) "==" (number_literal) "8" ()) ")" (compound_statement) "{\n pt_levels = 4;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;\n }" ({) "{" (expression_statement) "pt_levels = 4;" (assignment_expression) "pt_levels = 4" (identifier) "pt_levels" (=) "=" (number_literal) "4" (;) ";" (expression_statement) "paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;" (assignment_expression) "paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT" (identifier) "paddr" (=) "=" (binary_expression) "(uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT" (cast_expression) "(uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])" (() "(" (type_descriptor) "uint64_t" (primitive_type) "uint64_t" ()) ")" (call_expression) "xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])" (identifier) "xen_cr3_to_pfn_x86_64" (argument_list) "(ctx.x64.ctrlreg[3])" (() "(" (subscript_expression) "ctx.x64.ctrlreg[3]" (field_expression) "ctx.x64.ctrlreg" (field_expression) "ctx.x64" (identifier) "ctx" (.) "." (field_identifier) "x64" (.) "." (field_identifier) "ctrlreg" ([) "[" (number_literal) "3" (]) "]" ()) ")" (<<) "<<" (identifier) "PAGE_SHIFT" (;) ";" (}) "}" (else_clause) "else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }" (else) "else" (compound_statement) "{\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }" ({) "{" (expression_statement) "pt_levels = 3;" (assignment_expression) "pt_levels = 3" (identifier) "pt_levels" (=) "=" (number_literal) "3" (;) ";" (expression_statement) "paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;" (assignment_expression) "paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT" (identifier) "paddr" (=) "=" (binary_expression) "(uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT" (cast_expression) "(uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])" (() "(" (type_descriptor) "uint64_t" (primitive_type) "uint64_t" ()) ")" (call_expression) "xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])" (identifier) "xen_cr3_to_pfn_x86_32" (argument_list) "(ctx.x32.ctrlreg[3])" (() "(" (subscript_expression) "ctx.x32.ctrlreg[3]" (field_expression) "ctx.x32.ctrlreg" (field_expression) "ctx.x32" (identifier) "ctx" (.) "." (field_identifier) "x32" (.) "." (field_identifier) "ctrlreg" ([) "[" (number_literal) "3" (]) "]" ()) ")" (<<) "<<" (identifier) "PAGE_SHIFT" (;) ";" (}) "}" (}) "}" (if_statement) "if (pt_levels == 4) {\n virt &= 0x0000ffffffffffffull;\n mask = 0x0000ff8000000000ull;\n } else if (pt_levels == 3) {\n virt &= 0x00000000ffffffffull;\n mask = 0x0000007fc0000000ull;\n } else {\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }" (if) "if" (parenthesized_expression) "(pt_levels == 4)" (() "(" (binary_expression) "pt_levels == 4" (identifier) "pt_levels" (==) "==" (number_literal) "4" ()) ")" (compound_statement) "{\n virt &= 0x0000ffffffffffffull;\n mask = 0x0000ff8000000000ull;\n }" ({) "{" (expression_statement) "virt &= 0x0000ffffffffffffull;" (assignment_expression) "virt &= 0x0000ffffffffffffull" (identifier) "virt" (&=) "&=" (number_literal) "0x0000ffffffffffffull" (;) ";" (expression_statement) "mask = 0x0000ff8000000000ull;" (assignment_expression) "mask = 0x0000ff8000000000ull" (identifier) "mask" (=) "=" (number_literal) "0x0000ff8000000000ull" (;) ";" (}) "}" (else_clause) "else if (pt_levels == 3) {\n virt &= 0x00000000ffffffffull;\n mask = 0x0000007fc0000000ull;\n } else {\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }" (else) "else" (if_statement) "if (pt_levels == 3) {\n virt &= 0x00000000ffffffffull;\n mask = 0x0000007fc0000000ull;\n } else {\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }" (if) "if" (parenthesized_expression) "(pt_levels == 3)" (() "(" (binary_expression) "pt_levels == 3" (identifier) "pt_levels" (==) "==" (number_literal) "3" ()) ")" (compound_statement) "{\n virt &= 0x00000000ffffffffull;\n mask = 0x0000007fc0000000ull;\n }" ({) "{" (expression_statement) "virt &= 0x00000000ffffffffull;" (assignment_expression) "virt &= 0x00000000ffffffffull" (identifier) "virt" (&=) "&=" (number_literal) "0x00000000ffffffffull" (;) ";" (expression_statement) "mask = 0x0000007fc0000000ull;" (assignment_expression) "mask = 0x0000007fc0000000ull" (identifier) "mask" (=) "=" (number_literal) "0x0000007fc0000000ull" (;) ";" (}) "}" (else_clause) "else {\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }" (else) "else" (compound_statement) "{\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }" ({) "{" (expression_statement) "virt &= 0x00000000ffffffffull;" (assignment_expression) "virt &= 0x00000000ffffffffull" (identifier) "virt" (&=) "&=" (number_literal) "0x00000000ffffffffull" (;) ";" (expression_statement) "mask = 0x00000000ffc00000ull;" (assignment_expression) "mask = 0x00000000ffc00000ull" (identifier) "mask" (=) "=" (number_literal) "0x00000000ffc00000ull" (;) ";" (}) "}" (expression_statement) "size = (pt_levels == 2 ? 4 : 8);" (assignment_expression) "size = (pt_levels == 2 ? 4 : 8)" (identifier) "size" (=) "=" (parenthesized_expression) "(pt_levels == 2 ? 4 : 8)" (() "(" (conditional_expression) "pt_levels == 2 ? 4 : 8" (binary_expression) "pt_levels == 2" (identifier) "pt_levels" (==) "==" (number_literal) "2" (?) "?" (number_literal) "4" (:) ":" (number_literal) "8" ()) ")" (;) ";" (comment) "/* Walk the pagetables */" (for_statement) "for (level = pt_levels; level > 0; level--) {\n paddr += ((virt & mask) >> (xc_ffs64(mask) - 1)) * size;\n map = xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT);\n if (!map) \n return 0;\n memcpy(&pte, map + (paddr & (PAGE_SIZE - 1)), size);\n munmap(map, PAGE_SIZE);\n if (!(pte & 1)) \n return 0;\n paddr = pte & 0x000ffffffffff000ull;\n if (level == 2 && (pte & PTE_PSE)) {\n mask = ((mask ^ ~-mask) >> 1); /* All bits below first set bit */\n return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT;\n }\n mask >>= (pt_levels == 2 ? 10 : 9);\n }" (for) "for" (() "(" (assignment_expression) "level = pt_levels" (identifier) "level" (=) "=" (identifier) "pt_levels" (;) ";" (binary_expression) "level > 0" (identifier) "level" (>) ">" (number_literal) "0" (;) ";" (update_expression) "level--" (identifier) "level" (--) "--" ()) ")" (compound_statement) "{\n paddr += ((virt & mask) >> (xc_ffs64(mask) - 1)) * size;\n map = xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT);\n if (!map) \n return 0;\n memcpy(&pte, map + (paddr & (PAGE_SIZE - 1)), size);\n munmap(map, PAGE_SIZE);\n if (!(pte & 1)) \n return 0;\n paddr = pte & 0x000ffffffffff000ull;\n if (level == 2 && (pte & PTE_PSE)) {\n mask = ((mask ^ ~-mask) >> 1); /* All bits below first set bit */\n return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT;\n }\n mask >>= (pt_levels == 2 ? 10 : 9);\n }" ({) "{" (expression_statement) "paddr += ((virt & mask) >> (xc_ffs64(mask) - 1)) * size;" (assignment_expression) "paddr += ((virt & mask) >> (xc_ffs64(mask) - 1)) * size" (identifier) "paddr" (+=) "+=" (binary_expression) "((virt & mask) >> (xc_ffs64(mask) - 1)) * size" (parenthesized_expression) "((virt & mask) >> (xc_ffs64(mask) - 1))" (() "(" (binary_expression) "(virt & mask) >> (xc_ffs64(mask) - 1)" (parenthesized_expression) "(virt & mask)" (() "(" (binary_expression) "virt & mask" (identifier) "virt" (&) "&" (identifier) "mask" ()) ")" (>>) ">>" (parenthesized_expression) "(xc_ffs64(mask) - 1)" (() "(" (binary_expression) "xc_ffs64(mask) - 1" (call_expression) "xc_ffs64(mask)" (identifier) "xc_ffs64" (argument_list) "(mask)" (() "(" (identifier) "mask" ()) ")" (-) "-" (number_literal) "1" ()) ")" ()) ")" (*) "*" (identifier) "size" (;) ";" (expression_statement) "map = xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT);" (assignment_expression) "map = xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT)" (identifier) "map" (=) "=" (call_expression) "xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT)" (identifier) "xc_map_foreign_range" (argument_list) "(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT)" (() "(" (identifier) "xch" (,) "," (identifier) "dom" (,) "," (identifier) "PAGE_SIZE" (,) "," (identifier) "PROT_READ" (,) "," (binary_expression) "paddr >>PAGE_SHIFT" (identifier) "paddr" (>>) ">>" (identifier) "PAGE_SHIFT" ()) ")" (;) ";" (if_statement) "if (!map) \n return 0;" (if) "if" (parenthesized_expression) "(!map)" (() "(" (unary_expression) "!map" (!) "!" (identifier) "map" ()) ")" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (expression_statement) "memcpy(&pte, map + (paddr & (PAGE_SIZE - 1)), size);" (call_expression) "memcpy(&pte, map + (paddr & (PAGE_SIZE - 1)), size)" (identifier) "memcpy" (argument_list) "(&pte, map + (paddr & (PAGE_SIZE - 1)), size)" (() "(" (pointer_expression) "&pte" (&) "&" (identifier) "pte" (,) "," (binary_expression) "map + (paddr & (PAGE_SIZE - 1))" (identifier) "map" (+) "+" (parenthesized_expression) "(paddr & (PAGE_SIZE - 1))" (() "(" (binary_expression) "paddr & (PAGE_SIZE - 1)" (identifier) "paddr" (&) "&" (parenthesized_expression) "(PAGE_SIZE - 1)" (() "(" (binary_expression) "PAGE_SIZE - 1" (identifier) "PAGE_SIZE" (-) "-" (number_literal) "1" ()) ")" ()) ")" (,) "," (identifier) "size" ()) ")" (;) ";" (expression_statement) "munmap(map, PAGE_SIZE);" (call_expression) "munmap(map, PAGE_SIZE)" (identifier) "munmap" (argument_list) "(map, PAGE_SIZE)" (() "(" (identifier) "map" (,) "," (identifier) "PAGE_SIZE" ()) ")" (;) ";" (if_statement) "if (!(pte & 1)) \n return 0;" (if) "if" (parenthesized_expression) "(!(pte & 1))" (() "(" (unary_expression) "!(pte & 1)" (!) "!" (parenthesized_expression) "(pte & 1)" (() "(" (binary_expression) "pte & 1" (identifier) "pte" (&) "&" (number_literal) "1" ()) ")" ()) ")" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (expression_statement) "paddr = pte & 0x000ffffffffff000ull;" (assignment_expression) "paddr = pte & 0x000ffffffffff000ull" (identifier) "paddr" (=) "=" (binary_expression) "pte & 0x000ffffffffff000ull" (identifier) "pte" (&) "&" (number_literal) "0x000ffffffffff000ull" (;) ";" (if_statement) "if (level == 2 && (pte & PTE_PSE)) {\n mask = ((mask ^ ~-mask) >> 1); /* All bits below first set bit */\n return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT;\n }" (if) "if" (parenthesized_expression) "(level == 2 && (pte & PTE_PSE))" (() "(" (binary_expression) "level == 2 && (pte & PTE_PSE)" (binary_expression) "level == 2" (identifier) "level" (==) "==" (number_literal) "2" (&&) "&&" (parenthesized_expression) "(pte & PTE_PSE)" (() "(" (binary_expression) "pte & PTE_PSE" (identifier) "pte" (&) "&" (identifier) "PTE_PSE" ()) ")" ()) ")" (compound_statement) "{\n mask = ((mask ^ ~-mask) >> 1); /* All bits below first set bit */\n return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT;\n }" ({) "{" (expression_statement) "mask = ((mask ^ ~-mask) >> 1);" (assignment_expression) "mask = ((mask ^ ~-mask) >> 1)" (identifier) "mask" (=) "=" (parenthesized_expression) "((mask ^ ~-mask) >> 1)" (() "(" (binary_expression) "(mask ^ ~-mask) >> 1" (parenthesized_expression) "(mask ^ ~-mask)" (() "(" (binary_expression) "mask ^ ~-mask" (identifier) "mask" (^) "^" (unary_expression) "~-mask" (~) "~" (unary_expression) "-mask" (-) "-" (identifier) "mask" ()) ")" (>>) ">>" (number_literal) "1" ()) ")" (;) ";" (comment) "/* All bits below first set bit */" (return_statement) "return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT;" (return) "return" (binary_expression) "((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT" (parenthesized_expression) "((paddr & ~mask) | (virt & mask))" (() "(" (binary_expression) "(paddr & ~mask) | (virt & mask)" (parenthesized_expression) "(paddr & ~mask)" (() "(" (binary_expression) "paddr & ~mask" (identifier) "paddr" (&) "&" (unary_expression) "~mask" (~) "~" (identifier) "mask" ()) ")" (|) "|" (parenthesized_expression) "(virt & mask)" (() "(" (binary_expression) "virt & mask" (identifier) "virt" (&) "&" (identifier) "mask" ()) ")" ()) ")" (>>) ">>" (identifier) "PAGE_SHIFT" (;) ";" (}) "}" (expression_statement) "mask >>= (pt_levels == 2 ? 10 : 9);" (assignment_expression) "mask >>= (pt_levels == 2 ? 10 : 9)" (identifier) "mask" (>>=) ">>=" (parenthesized_expression) "(pt_levels == 2 ? 10 : 9)" (() "(" (conditional_expression) "pt_levels == 2 ? 10 : 9" (binary_expression) "pt_levels == 2" (identifier) "pt_levels" (==) "==" (number_literal) "2" (?) "?" (number_literal) "10" (:) ":" (number_literal) "9" ()) ")" (;) ";" (}) "}" (return_statement) "return paddr >> PAGE_SHIFT;" (return) "return" (binary_expression) "paddr >> PAGE_SHIFT" (identifier) "paddr" (>>) ">>" (identifier) "PAGE_SHIFT" (;) ";" (}) "}" (comment) "/*\n * Local variables:\n * mode: C\n * c-file-style: "BSD"\n * c-basic-offset: 4\n * tab-width: 4\n * indent-tabs-mode: nil\n * End:\n */"
755
0
{"language": "c", "success": true, "metadata": {"lines": 103, "avg_line_length": 34.6, "nodes": 476, "errors": 0, "source_hash": "0666258078df8fcce04802af0ef8a0f4f86de0742156f35cf62b906073bc3ce0", "categorized_nodes": 363}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"xc_private.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 20, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"xc_private.h\"", "parent": 0, "children": [], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 23}}, {"id": 3, "type": "preproc_include", "text": "#include <xen/hvm/save.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 21, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<xen/hvm/save.h>", "parent": 3, "children": [], "start_point": {"row": 20, "column": 9}, "end_point": {"row": 20, "column": 25}}, {"id": 6, "type": "preproc_def", "text": "#define CR0_PG 0x80000000\n", "parent": null, "children": [7, 8, 9], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 23, "column": 0}}, {"id": 7, "type": "#define", "text": "#define", "parent": 6, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 7}}, {"id": 8, "type": "identifier", "text": "CR0_PG", "parent": 6, "children": [], "start_point": {"row": 22, "column": 8}, "end_point": {"row": 22, "column": 14}}, {"id": 9, "type": "preproc_arg", "text": "0x80000000", "parent": 6, "children": [], "start_point": {"row": 22, "column": 16}, "end_point": {"row": 22, "column": 26}}, {"id": 10, "type": "preproc_def", "text": "#define CR4_PAE 0x20\n", "parent": null, "children": [11, 12, 13], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 24, "column": 0}}, {"id": 11, "type": "#define", "text": "#define", "parent": 10, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 7}}, {"id": 12, "type": "identifier", "text": "CR4_PAE", "parent": 10, "children": [], "start_point": {"row": 23, "column": 8}, "end_point": {"row": 23, "column": 15}}, {"id": 13, "type": "preproc_arg", "text": "0x20", "parent": 10, "children": [], "start_point": {"row": 23, "column": 16}, "end_point": {"row": 23, "column": 20}}, {"id": 14, "type": "preproc_def", "text": "#define PTE_PSE 0x80\n", "parent": null, "children": [15, 16, 17], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 25, "column": 0}}, {"id": 15, "type": "#define", "text": "#define", "parent": 14, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 7}}, {"id": 16, "type": "identifier", "text": "PTE_PSE", "parent": 14, "children": [], "start_point": {"row": 24, "column": 8}, "end_point": {"row": 24, "column": 15}}, {"id": 17, "type": "preproc_arg", "text": "0x80", "parent": 14, "children": [], "start_point": {"row": 24, "column": 16}, "end_point": {"row": 24, "column": 20}}, {"id": 18, "type": "preproc_def", "text": "#define EFER_LMA 0x400\n", "parent": null, "children": [19, 20, 21], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 26, "column": 0}}, {"id": 19, "type": "#define", "text": "#define", "parent": 18, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 7}}, {"id": 20, "type": "identifier", "text": "EFER_LMA", "parent": 18, "children": [], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 16}}, {"id": 21, "type": "preproc_arg", "text": "0x400", "parent": 18, "children": [], "start_point": {"row": 25, "column": 17}, "end_point": {"row": 25, "column": 22}}, {"id": 22, "type": "function_definition", "text": "unsigned long xc_translate_foreign_address(xc_interface *xch, uint32_t dom,\n int vcpu, unsigned long long virt)\n{\n xc_dominfo_t dominfo;\n uint64_t paddr, mask, pte = 0;\n int size, level, pt_levels = 2;\n void *map;\n\n if (xc_domain_getinfo(xch, dom, 1, &dominfo) != 1 \n || dominfo.domid != dom)\n return 0;\n\n /* What kind of paging are we dealing with? */\n if (dominfo.hvm) {\n struct hvm_hw_cpu ctx;\n if (xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0)\n return 0;\n if (!(ctx.cr0 & CR0_PG))\n return virt >> PAGE_SHIFT;\n pt_levels = (ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2;\n paddr = ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull);\n } else {\n unsigned int gwidth;\n vcpu_guest_context_any_t ctx;\n if (xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)\n return 0;\n if (xc_domain_get_guest_width(xch, dom, &gwidth) != 0)\n return 0;\n if (gwidth == 8) {\n pt_levels = 4;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;\n } else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }\n }\n\n if (pt_levels == 4) {\n virt &= 0x0000ffffffffffffull;\n mask = 0x0000ff8000000000ull;\n } else if (pt_levels == 3) {\n virt &= 0x00000000ffffffffull;\n mask = 0x0000007fc0000000ull;\n } else {\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }\n size = (pt_levels == 2 ? 4 : 8);\n\n /* Walk the pagetables */\n for (level = pt_levels; level > 0; level--) {\n paddr += ((virt & mask) >> (xc_ffs64(mask) - 1)) * size;\n map = xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT);\n if (!map) \n return 0;\n memcpy(&pte, map + (paddr & (PAGE_SIZE - 1)), size);\n munmap(map, PAGE_SIZE);\n if (!(pte & 1)) \n return 0;\n paddr = pte & 0x000ffffffffff000ull;\n if (level == 2 && (pte & PTE_PSE)) {\n mask = ((mask ^ ~-mask) >> 1); /* All bits below first set bit */\n return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT;\n }\n mask >>= (pt_levels == 2 ? 10 : 9);\n }\n return paddr >> PAGE_SHIFT;\n}", "parent": null, "children": [23, 26], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 100, "column": 1}}, {"id": 23, "type": "sized_type_specifier", "text": "unsigned long", "parent": 22, "children": [24, 25], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 13}}, {"id": 24, "type": "unsigned", "text": "unsigned", "parent": 23, "children": [], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 8}}, {"id": 25, "type": "long", "text": "long", "parent": 23, "children": [], "start_point": {"row": 28, "column": 9}, "end_point": {"row": 28, "column": 13}}, {"id": 26, "type": "function_declarator", "text": "xc_translate_foreign_address(xc_interface *xch, uint32_t dom,\n int vcpu, unsigned long long virt)", "parent": 22, "children": [27, 28], "start_point": {"row": 28, "column": 14}, "end_point": {"row": 29, "column": 77}}, {"id": 27, "type": "identifier", "text": "xc_translate_foreign_address", "parent": 26, "children": [], "start_point": {"row": 28, "column": 14}, "end_point": {"row": 28, "column": 42}}, {"id": 28, "type": "parameter_list", "text": "(xc_interface *xch, uint32_t dom,\n int vcpu, unsigned long long virt)", "parent": 26, "children": [29, 34, 37, 40], "start_point": {"row": 28, "column": 42}, "end_point": {"row": 29, "column": 77}}, {"id": 29, "type": "parameter_declaration", "text": "xc_interface *xch", "parent": 28, "children": [30, 31], "start_point": {"row": 28, "column": 43}, "end_point": {"row": 28, "column": 60}}, {"id": 30, "type": "type_identifier", "text": "xc_interface", "parent": 29, "children": [], "start_point": {"row": 28, "column": 43}, "end_point": {"row": 28, "column": 55}}, {"id": 31, "type": "pointer_declarator", "text": "*xch", "parent": 29, "children": [32, 33], "start_point": {"row": 28, "column": 56}, "end_point": {"row": 28, "column": 60}}, {"id": 32, "type": "*", "text": "*", "parent": 31, "children": [], "start_point": {"row": 28, "column": 56}, "end_point": {"row": 28, "column": 57}}, {"id": 33, "type": "identifier", "text": "xch", "parent": 31, "children": [], "start_point": {"row": 28, "column": 57}, "end_point": {"row": 28, "column": 60}}, {"id": 34, "type": "parameter_declaration", "text": "uint32_t dom", "parent": 28, "children": [35, 36], "start_point": {"row": 28, "column": 62}, "end_point": {"row": 28, "column": 74}}, {"id": 35, "type": "primitive_type", "text": "uint32_t", "parent": 34, "children": [], "start_point": {"row": 28, "column": 62}, "end_point": {"row": 28, "column": 70}}, {"id": 36, "type": "identifier", "text": "dom", "parent": 34, "children": [], "start_point": {"row": 28, "column": 71}, "end_point": {"row": 28, "column": 74}}, {"id": 37, "type": "parameter_declaration", "text": "int vcpu", "parent": 28, "children": [38, 39], "start_point": {"row": 29, "column": 43}, "end_point": {"row": 29, "column": 51}}, {"id": 38, "type": "primitive_type", "text": "int", "parent": 37, "children": [], "start_point": {"row": 29, "column": 43}, "end_point": {"row": 29, "column": 46}}, {"id": 39, "type": "identifier", "text": "vcpu", "parent": 37, "children": [], "start_point": {"row": 29, "column": 47}, "end_point": {"row": 29, "column": 51}}, {"id": 40, "type": "parameter_declaration", "text": "unsigned long long virt", "parent": 28, "children": [41, 45], "start_point": {"row": 29, "column": 53}, "end_point": {"row": 29, "column": 76}}, {"id": 41, "type": "sized_type_specifier", "text": "unsigned long long", "parent": 40, "children": [42, 43, 44], "start_point": {"row": 29, "column": 53}, "end_point": {"row": 29, "column": 71}}, {"id": 42, "type": "unsigned", "text": "unsigned", "parent": 41, "children": [], "start_point": {"row": 29, "column": 53}, "end_point": {"row": 29, "column": 61}}, {"id": 43, "type": "long", "text": "long", "parent": 41, "children": [], "start_point": {"row": 29, "column": 62}, "end_point": {"row": 29, "column": 66}}, {"id": 44, "type": "long", "text": "long", "parent": 41, "children": [], "start_point": {"row": 29, "column": 67}, "end_point": {"row": 29, "column": 71}}, {"id": 45, "type": "identifier", "text": "virt", "parent": 40, "children": [], "start_point": {"row": 29, "column": 72}, "end_point": {"row": 29, "column": 76}}, {"id": 46, "type": "declaration", "text": "xc_dominfo_t dominfo;", "parent": 22, "children": [47, 48], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 25}}, {"id": 47, "type": "type_identifier", "text": "xc_dominfo_t", "parent": 46, "children": [], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 16}}, {"id": 48, "type": "identifier", "text": "dominfo", "parent": 46, "children": [], "start_point": {"row": 31, "column": 17}, "end_point": {"row": 31, "column": 24}}, {"id": 49, "type": "declaration", "text": "uint64_t paddr, mask, pte = 0;", "parent": 22, "children": [50, 51, 52, 53], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 32, "column": 34}}, {"id": 50, "type": "primitive_type", "text": "uint64_t", "parent": 49, "children": [], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 32, "column": 12}}, {"id": 51, "type": "identifier", "text": "paddr", "parent": 49, "children": [], "start_point": {"row": 32, "column": 13}, "end_point": {"row": 32, "column": 18}}, {"id": 52, "type": "identifier", "text": "mask", "parent": 49, "children": [], "start_point": {"row": 32, "column": 20}, "end_point": {"row": 32, "column": 24}}, {"id": 53, "type": "init_declarator", "text": "pte = 0", "parent": 49, "children": [54, 55, 56], "start_point": {"row": 32, "column": 26}, "end_point": {"row": 32, "column": 33}}, {"id": 54, "type": "identifier", "text": "pte", "parent": 53, "children": [], "start_point": {"row": 32, "column": 26}, "end_point": {"row": 32, "column": 29}}, {"id": 55, "type": "=", "text": "=", "parent": 53, "children": [], "start_point": {"row": 32, "column": 30}, "end_point": {"row": 32, "column": 31}}, {"id": 56, "type": "number_literal", "text": "0", "parent": 53, "children": [], "start_point": {"row": 32, "column": 32}, "end_point": {"row": 32, "column": 33}}, {"id": 57, "type": "declaration", "text": "int size, level, pt_levels = 2;", "parent": 22, "children": [58, 59, 60, 61], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 35}}, {"id": 58, "type": "primitive_type", "text": "int", "parent": 57, "children": [], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 7}}, {"id": 59, "type": "identifier", "text": "size", "parent": 57, "children": [], "start_point": {"row": 33, "column": 8}, "end_point": {"row": 33, "column": 12}}, {"id": 60, "type": "identifier", "text": "level", "parent": 57, "children": [], "start_point": {"row": 33, "column": 14}, "end_point": {"row": 33, "column": 19}}, {"id": 61, "type": "init_declarator", "text": "pt_levels = 2", "parent": 57, "children": [62, 63, 64], "start_point": {"row": 33, "column": 21}, "end_point": {"row": 33, "column": 34}}, {"id": 62, "type": "identifier", "text": "pt_levels", "parent": 61, "children": [], "start_point": {"row": 33, "column": 21}, "end_point": {"row": 33, "column": 30}}, {"id": 63, "type": "=", "text": "=", "parent": 61, "children": [], "start_point": {"row": 33, "column": 31}, "end_point": {"row": 33, "column": 32}}, {"id": 64, "type": "number_literal", "text": "2", "parent": 61, "children": [], "start_point": {"row": 33, "column": 33}, "end_point": {"row": 33, "column": 34}}, {"id": 65, "type": "declaration", "text": "void *map;", "parent": 22, "children": [66, 67], "start_point": {"row": 34, "column": 4}, "end_point": {"row": 34, "column": 14}}, {"id": 66, "type": "primitive_type", "text": "void", "parent": 65, "children": [], "start_point": {"row": 34, "column": 4}, "end_point": {"row": 34, "column": 8}}, {"id": 67, "type": "pointer_declarator", "text": "*map", "parent": 65, "children": [68, 69], "start_point": {"row": 34, "column": 9}, "end_point": {"row": 34, "column": 13}}, {"id": 68, "type": "*", "text": "*", "parent": 67, "children": [], "start_point": {"row": 34, "column": 9}, "end_point": {"row": 34, "column": 10}}, {"id": 69, "type": "identifier", "text": "map", "parent": 67, "children": [], "start_point": {"row": 34, "column": 10}, "end_point": {"row": 34, "column": 13}}, {"id": 70, "type": "if_statement", "text": "if (xc_domain_getinfo(xch, dom, 1, &dominfo) != 1 \n || dominfo.domid != dom)\n return 0;", "parent": 22, "children": [71, 91], "start_point": {"row": 36, "column": 4}, "end_point": {"row": 38, "column": 17}}, {"id": 71, "type": "parenthesized_expression", "text": "(xc_domain_getinfo(xch, dom, 1, &dominfo) != 1 \n || dominfo.domid != dom)", "parent": 70, "children": [72], "start_point": {"row": 36, "column": 7}, "end_point": {"row": 37, "column": 32}}, {"id": 72, "type": "binary_expression", "text": "xc_domain_getinfo(xch, dom, 1, &dominfo) != 1 \n || dominfo.domid != dom", "parent": 71, "children": [73, 84, 85], "start_point": {"row": 36, "column": 8}, "end_point": {"row": 37, "column": 31}}, {"id": 73, "type": "binary_expression", "text": "xc_domain_getinfo(xch, dom, 1, &dominfo) != 1", "parent": 72, "children": [74, 82, 83], "start_point": {"row": 36, "column": 8}, "end_point": {"row": 36, "column": 53}}, {"id": 74, "type": "call_expression", "text": "xc_domain_getinfo(xch, dom, 1, &dominfo)", "parent": 73, "children": [75, 76], "start_point": {"row": 36, "column": 8}, "end_point": {"row": 36, "column": 48}}, {"id": 75, "type": "identifier", "text": "xc_domain_getinfo", "parent": 74, "children": [], "start_point": {"row": 36, "column": 8}, "end_point": {"row": 36, "column": 25}}, {"id": 76, "type": "argument_list", "text": "(xch, dom, 1, &dominfo)", "parent": 74, "children": [77, 78, 79, 80], "start_point": {"row": 36, "column": 25}, "end_point": {"row": 36, "column": 48}}, {"id": 77, "type": "identifier", "text": "xch", "parent": 76, "children": [], "start_point": {"row": 36, "column": 26}, "end_point": {"row": 36, "column": 29}}, {"id": 78, "type": "identifier", "text": "dom", "parent": 76, "children": [], "start_point": {"row": 36, "column": 31}, "end_point": {"row": 36, "column": 34}}, {"id": 79, "type": "number_literal", "text": "1", "parent": 76, "children": [], "start_point": {"row": 36, "column": 36}, "end_point": {"row": 36, "column": 37}}, {"id": 80, "type": "pointer_expression", "text": "&dominfo", "parent": 76, "children": [81], "start_point": {"row": 36, "column": 39}, "end_point": {"row": 36, "column": 47}}, {"id": 81, "type": "identifier", "text": "dominfo", "parent": 80, "children": [], "start_point": {"row": 36, "column": 40}, "end_point": {"row": 36, "column": 47}}, {"id": 82, "type": "!=", "text": "!=", "parent": 73, "children": [], "start_point": {"row": 36, "column": 49}, "end_point": {"row": 36, "column": 51}}, {"id": 83, "type": "number_literal", "text": "1", "parent": 73, "children": [], "start_point": {"row": 36, "column": 52}, "end_point": {"row": 36, "column": 53}}, {"id": 84, "type": "||", "text": "||", "parent": 72, "children": [], "start_point": {"row": 37, "column": 8}, "end_point": {"row": 37, "column": 10}}, {"id": 85, "type": "binary_expression", "text": "dominfo.domid != dom", "parent": 72, "children": [86, 89, 90], "start_point": {"row": 37, "column": 11}, "end_point": {"row": 37, "column": 31}}, {"id": 86, "type": "field_expression", "text": "dominfo.domid", "parent": 85, "children": [87, 88], "start_point": {"row": 37, "column": 11}, "end_point": {"row": 37, "column": 24}}, {"id": 87, "type": "identifier", "text": "dominfo", "parent": 86, "children": [], "start_point": {"row": 37, "column": 11}, "end_point": {"row": 37, "column": 18}}, {"id": 88, "type": "field_identifier", "text": "domid", "parent": 86, "children": [], "start_point": {"row": 37, "column": 19}, "end_point": {"row": 37, "column": 24}}, {"id": 89, "type": "!=", "text": "!=", "parent": 85, "children": [], "start_point": {"row": 37, "column": 25}, "end_point": {"row": 37, "column": 27}}, {"id": 90, "type": "identifier", "text": "dom", "parent": 85, "children": [], "start_point": {"row": 37, "column": 28}, "end_point": {"row": 37, "column": 31}}, {"id": 91, "type": "return_statement", "text": "return 0;", "parent": 70, "children": [92], "start_point": {"row": 38, "column": 8}, "end_point": {"row": 38, "column": 17}}, {"id": 92, "type": "number_literal", "text": "0", "parent": 91, "children": [], "start_point": {"row": 38, "column": 15}, "end_point": {"row": 38, "column": 16}}, {"id": 93, "type": "if_statement", "text": "if (dominfo.hvm) {\n struct hvm_hw_cpu ctx;\n if (xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0)\n return 0;\n if (!(ctx.cr0 & CR0_PG))\n return virt >> PAGE_SHIFT;\n pt_levels = (ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2;\n paddr = ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull);\n } else {\n unsigned int gwidth;\n vcpu_guest_context_any_t ctx;\n if (xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)\n return 0;\n if (xc_domain_get_guest_width(xch, dom, &gwidth) != 0)\n return 0;\n if (gwidth == 8) {\n pt_levels = 4;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;\n } else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }\n }", "parent": 22, "children": [94, 182], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 67, "column": 5}}, {"id": 94, "type": "parenthesized_expression", "text": "(dominfo.hvm)", "parent": 93, "children": [95], "start_point": {"row": 41, "column": 7}, "end_point": {"row": 41, "column": 20}}, {"id": 95, "type": "field_expression", "text": "dominfo.hvm", "parent": 94, "children": [96, 97], "start_point": {"row": 41, "column": 8}, "end_point": {"row": 41, "column": 19}}, {"id": 96, "type": "identifier", "text": "dominfo", "parent": 95, "children": [], "start_point": {"row": 41, "column": 8}, "end_point": {"row": 41, "column": 15}}, {"id": 97, "type": "field_identifier", "text": "hvm", "parent": 95, "children": [], "start_point": {"row": 41, "column": 16}, "end_point": {"row": 41, "column": 19}}, {"id": 98, "type": "declaration", "text": "struct hvm_hw_cpu ctx;", "parent": 93, "children": [99, 102], "start_point": {"row": 42, "column": 8}, "end_point": {"row": 42, "column": 30}}, {"id": 99, "type": "struct_specifier", "text": "struct hvm_hw_cpu", "parent": 98, "children": [100, 101], "start_point": {"row": 42, "column": 8}, "end_point": {"row": 42, "column": 25}}, {"id": 100, "type": "struct", "text": "struct", "parent": 99, "children": [], "start_point": {"row": 42, "column": 8}, "end_point": {"row": 42, "column": 14}}, {"id": 101, "type": "type_identifier", "text": "hvm_hw_cpu", "parent": 99, "children": [], "start_point": {"row": 42, "column": 15}, "end_point": {"row": 42, "column": 25}}, {"id": 102, "type": "identifier", "text": "ctx", "parent": 98, "children": [], "start_point": {"row": 42, "column": 26}, "end_point": {"row": 42, "column": 29}}, {"id": 103, "type": "if_statement", "text": "if (xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0)\n return 0;", "parent": 93, "children": [104, 122], "start_point": {"row": 43, "column": 8}, "end_point": {"row": 46, "column": 21}}, {"id": 104, "type": "parenthesized_expression", "text": "(xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0)", "parent": 103, "children": [105], "start_point": {"row": 43, "column": 11}, "end_point": {"row": 45, "column": 68}}, {"id": 105, "type": "binary_expression", "text": "xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0", "parent": 104, "children": [106, 120, 121], "start_point": {"row": 43, "column": 12}, "end_point": {"row": 45, "column": 67}}, {"id": 106, "type": "call_expression", "text": "xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx)", "parent": 105, "children": [107, 108], "start_point": {"row": 43, "column": 12}, "end_point": {"row": 45, "column": 62}}, {"id": 107, "type": "identifier", "text": "xc_domain_hvm_getcontext_partial", "parent": 106, "children": [], "start_point": {"row": 43, "column": 12}, "end_point": {"row": 43, "column": 44}}, {"id": 108, "type": "argument_list", "text": "(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx)", "parent": 106, "children": [109, 110, 111, 115, 116, 118], "start_point": {"row": 43, "column": 44}, "end_point": {"row": 45, "column": 62}}, {"id": 109, "type": "identifier", "text": "xch", "parent": 108, "children": [], "start_point": {"row": 43, "column": 45}, "end_point": {"row": 43, "column": 48}}, {"id": 110, "type": "identifier", "text": "dom", "parent": 108, "children": [], "start_point": {"row": 43, "column": 50}, "end_point": {"row": 43, "column": 53}}, {"id": 111, "type": "call_expression", "text": "HVM_SAVE_CODE(CPU)", "parent": 108, "children": [112, 113], "start_point": {"row": 44, "column": 45}, "end_point": {"row": 44, "column": 63}}, {"id": 112, "type": "identifier", "text": "HVM_SAVE_CODE", "parent": 111, "children": [], "start_point": {"row": 44, "column": 45}, "end_point": {"row": 44, "column": 58}}, {"id": 113, "type": "argument_list", "text": "(CPU)", "parent": 111, "children": [114], "start_point": {"row": 44, "column": 58}, "end_point": {"row": 44, "column": 63}}, {"id": 114, "type": "identifier", "text": "CPU", "parent": 113, "children": [], "start_point": {"row": 44, "column": 59}, "end_point": {"row": 44, "column": 62}}, {"id": 115, "type": "identifier", "text": "vcpu", "parent": 108, "children": [], "start_point": {"row": 44, "column": 65}, "end_point": {"row": 44, "column": 69}}, {"id": 116, "type": "pointer_expression", "text": "&ctx", "parent": 108, "children": [117], "start_point": {"row": 45, "column": 45}, "end_point": {"row": 45, "column": 49}}, {"id": 117, "type": "identifier", "text": "ctx", "parent": 116, "children": [], "start_point": {"row": 45, "column": 46}, "end_point": {"row": 45, "column": 49}}, {"id": 118, "type": "sizeof_expression", "text": "sizeof ctx", "parent": 108, "children": [119], "start_point": {"row": 45, "column": 51}, "end_point": {"row": 45, "column": 61}}, {"id": 119, "type": "identifier", "text": "ctx", "parent": 118, "children": [], "start_point": {"row": 45, "column": 58}, "end_point": {"row": 45, "column": 61}}, {"id": 120, "type": "!=", "text": "!=", "parent": 105, "children": [], "start_point": {"row": 45, "column": 63}, "end_point": {"row": 45, "column": 65}}, {"id": 121, "type": "number_literal", "text": "0", "parent": 105, "children": [], "start_point": {"row": 45, "column": 66}, "end_point": {"row": 45, "column": 67}}, {"id": 122, "type": "return_statement", "text": "return 0;", "parent": 103, "children": [123], "start_point": {"row": 46, "column": 12}, "end_point": {"row": 46, "column": 21}}, {"id": 123, "type": "number_literal", "text": "0", "parent": 122, "children": [], "start_point": {"row": 46, "column": 19}, "end_point": {"row": 46, "column": 20}}, {"id": 124, "type": "if_statement", "text": "if (!(ctx.cr0 & CR0_PG))\n return virt >> PAGE_SHIFT;", "parent": 93, "children": [125, 134], "start_point": {"row": 47, "column": 8}, "end_point": {"row": 48, "column": 38}}, {"id": 125, "type": "parenthesized_expression", "text": "(!(ctx.cr0 & CR0_PG))", "parent": 124, "children": [126], "start_point": {"row": 47, "column": 11}, "end_point": {"row": 47, "column": 32}}, {"id": 126, "type": "unary_expression", "text": "!(ctx.cr0 & CR0_PG)", "parent": 125, "children": [127, 128], "start_point": {"row": 47, "column": 12}, "end_point": {"row": 47, "column": 31}}, {"id": 127, "type": "!", "text": "!", "parent": 126, "children": [], "start_point": {"row": 47, "column": 12}, "end_point": {"row": 47, "column": 13}}, {"id": 128, "type": "parenthesized_expression", "text": "(ctx.cr0 & CR0_PG)", "parent": 126, "children": [129], "start_point": {"row": 47, "column": 13}, "end_point": {"row": 47, "column": 31}}, {"id": 129, "type": "binary_expression", "text": "ctx.cr0 & CR0_PG", "parent": 128, "children": [130, 133], "start_point": {"row": 47, "column": 14}, "end_point": {"row": 47, "column": 30}}, {"id": 130, "type": "field_expression", "text": "ctx.cr0", "parent": 129, "children": [131, 132], "start_point": {"row": 47, "column": 14}, "end_point": {"row": 47, "column": 21}}, {"id": 131, "type": "identifier", "text": "ctx", "parent": 130, "children": [], "start_point": {"row": 47, "column": 14}, "end_point": {"row": 47, "column": 17}}, {"id": 132, "type": "field_identifier", "text": "cr0", "parent": 130, "children": [], "start_point": {"row": 47, "column": 18}, "end_point": {"row": 47, "column": 21}}, {"id": 133, "type": "identifier", "text": "CR0_PG", "parent": 129, "children": [], "start_point": {"row": 47, "column": 24}, "end_point": {"row": 47, "column": 30}}, {"id": 134, "type": "return_statement", "text": "return virt >> PAGE_SHIFT;", "parent": 124, "children": [135], "start_point": {"row": 48, "column": 12}, "end_point": {"row": 48, "column": 38}}, {"id": 135, "type": "binary_expression", "text": "virt >> PAGE_SHIFT", "parent": 134, "children": [136, 137, 138], "start_point": {"row": 48, "column": 19}, "end_point": {"row": 48, "column": 37}}, {"id": 136, "type": "identifier", "text": "virt", "parent": 135, "children": [], "start_point": {"row": 48, "column": 19}, "end_point": {"row": 48, "column": 23}}, {"id": 137, "type": ">>", "text": ">>", "parent": 135, "children": [], "start_point": {"row": 48, "column": 24}, "end_point": {"row": 48, "column": 26}}, {"id": 138, "type": "identifier", "text": "PAGE_SHIFT", "parent": 135, "children": [], "start_point": {"row": 48, "column": 27}, "end_point": {"row": 48, "column": 37}}, {"id": 139, "type": "assignment_expression", "text": "pt_levels = (ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2", "parent": 93, "children": [140, 141, 142], "start_point": {"row": 49, "column": 8}, "end_point": {"row": 49, "column": 75}}, {"id": 140, "type": "identifier", "text": "pt_levels", "parent": 139, "children": [], "start_point": {"row": 49, "column": 8}, "end_point": {"row": 49, "column": 17}}, {"id": 141, "type": "=", "text": "=", "parent": 139, "children": [], "start_point": {"row": 49, "column": 18}, "end_point": {"row": 49, "column": 19}}, {"id": 142, "type": "conditional_expression", "text": "(ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2", "parent": 139, "children": [143, 149, 150, 151], "start_point": {"row": 49, "column": 20}, "end_point": {"row": 49, "column": 75}}, {"id": 143, "type": "parenthesized_expression", "text": "(ctx.msr_efer&EFER_LMA)", "parent": 142, "children": [144], "start_point": {"row": 49, "column": 20}, "end_point": {"row": 49, "column": 43}}, {"id": 144, "type": "binary_expression", "text": "ctx.msr_efer&EFER_LMA", "parent": 143, "children": [145, 148], "start_point": {"row": 49, "column": 21}, "end_point": {"row": 49, "column": 42}}, {"id": 145, "type": "field_expression", "text": "ctx.msr_efer", "parent": 144, "children": [146, 147], "start_point": {"row": 49, "column": 21}, "end_point": {"row": 49, "column": 33}}, {"id": 146, "type": "identifier", "text": "ctx", "parent": 145, "children": [], "start_point": {"row": 49, "column": 21}, "end_point": {"row": 49, "column": 24}}, {"id": 147, "type": "field_identifier", "text": "msr_efer", "parent": 145, "children": [], "start_point": {"row": 49, "column": 25}, "end_point": {"row": 49, "column": 33}}, {"id": 148, "type": "identifier", "text": "EFER_LMA", "parent": 144, "children": [], "start_point": {"row": 49, "column": 34}, "end_point": {"row": 49, "column": 42}}, {"id": 149, "type": "?", "text": "?", "parent": 142, "children": [], "start_point": {"row": 49, "column": 44}, "end_point": {"row": 49, "column": 45}}, {"id": 150, "type": "number_literal", "text": "4", "parent": 142, "children": [], "start_point": {"row": 49, "column": 46}, "end_point": {"row": 49, "column": 47}}, {"id": 151, "type": "conditional_expression", "text": "(ctx.cr4&CR4_PAE) ? 3 : 2", "parent": 142, "children": [152, 158, 159, 160], "start_point": {"row": 49, "column": 50}, "end_point": {"row": 49, "column": 75}}, {"id": 152, "type": "parenthesized_expression", "text": "(ctx.cr4&CR4_PAE)", "parent": 151, "children": [153], "start_point": {"row": 49, "column": 50}, "end_point": {"row": 49, "column": 67}}, {"id": 153, "type": "binary_expression", "text": "ctx.cr4&CR4_PAE", "parent": 152, "children": [154, 157], "start_point": {"row": 49, "column": 51}, "end_point": {"row": 49, "column": 66}}, {"id": 154, "type": "field_expression", "text": "ctx.cr4", "parent": 153, "children": [155, 156], "start_point": {"row": 49, "column": 51}, "end_point": {"row": 49, "column": 58}}, {"id": 155, "type": "identifier", "text": "ctx", "parent": 154, "children": [], "start_point": {"row": 49, "column": 51}, "end_point": {"row": 49, "column": 54}}, {"id": 156, "type": "field_identifier", "text": "cr4", "parent": 154, "children": [], "start_point": {"row": 49, "column": 55}, "end_point": {"row": 49, "column": 58}}, {"id": 157, "type": "identifier", "text": "CR4_PAE", "parent": 153, "children": [], "start_point": {"row": 49, "column": 59}, "end_point": {"row": 49, "column": 66}}, {"id": 158, "type": "?", "text": "?", "parent": 151, "children": [], "start_point": {"row": 49, "column": 68}, "end_point": {"row": 49, "column": 69}}, {"id": 159, "type": "number_literal", "text": "3", "parent": 151, "children": [], "start_point": {"row": 49, "column": 70}, "end_point": {"row": 49, "column": 71}}, {"id": 160, "type": "number_literal", "text": "2", "parent": 151, "children": [], "start_point": {"row": 49, "column": 74}, "end_point": {"row": 49, "column": 75}}, {"id": 161, "type": "assignment_expression", "text": "paddr = ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull)", "parent": 93, "children": [162, 163, 164], "start_point": {"row": 50, "column": 8}, "end_point": {"row": 50, "column": 67}}, {"id": 162, "type": "identifier", "text": "paddr", "parent": 161, "children": [], "start_point": {"row": 50, "column": 8}, "end_point": {"row": 50, "column": 13}}, {"id": 163, "type": "=", "text": "=", "parent": 161, "children": [], "start_point": {"row": 50, "column": 14}, "end_point": {"row": 50, "column": 15}}, {"id": 164, "type": "binary_expression", "text": "ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull)", "parent": 161, "children": [165, 168], "start_point": {"row": 50, "column": 16}, "end_point": {"row": 50, "column": 67}}, {"id": 165, "type": "field_expression", "text": "ctx.cr3", "parent": 164, "children": [166, 167], "start_point": {"row": 50, "column": 16}, "end_point": {"row": 50, "column": 23}}, {"id": 166, "type": "identifier", "text": "ctx", "parent": 165, "children": [], "start_point": {"row": 50, "column": 16}, "end_point": {"row": 50, "column": 19}}, {"id": 167, "type": "field_identifier", "text": "cr3", "parent": 165, "children": [], "start_point": {"row": 50, "column": 20}, "end_point": {"row": 50, "column": 23}}, {"id": 168, "type": "parenthesized_expression", "text": "((pt_levels == 3) ? ~0x1full : ~0xfffull)", "parent": 164, "children": [169], "start_point": {"row": 50, "column": 26}, "end_point": {"row": 50, "column": 67}}, {"id": 169, "type": "conditional_expression", "text": "(pt_levels == 3) ? ~0x1full : ~0xfffull", "parent": 168, "children": [170, 175, 176, 179], "start_point": {"row": 50, "column": 27}, "end_point": {"row": 50, "column": 66}}, {"id": 170, "type": "parenthesized_expression", "text": "(pt_levels == 3)", "parent": 169, "children": [171], "start_point": {"row": 50, "column": 27}, "end_point": {"row": 50, "column": 43}}, {"id": 171, "type": "binary_expression", "text": "pt_levels == 3", "parent": 170, "children": [172, 173, 174], "start_point": {"row": 50, "column": 28}, "end_point": {"row": 50, "column": 42}}, {"id": 172, "type": "identifier", "text": "pt_levels", "parent": 171, "children": [], "start_point": {"row": 50, "column": 28}, "end_point": {"row": 50, "column": 37}}, {"id": 173, "type": "==", "text": "==", "parent": 171, "children": [], "start_point": {"row": 50, "column": 38}, "end_point": {"row": 50, "column": 40}}, {"id": 174, "type": "number_literal", "text": "3", "parent": 171, "children": [], "start_point": {"row": 50, "column": 41}, "end_point": {"row": 50, "column": 42}}, {"id": 175, "type": "?", "text": "?", "parent": 169, "children": [], "start_point": {"row": 50, "column": 44}, "end_point": {"row": 50, "column": 45}}, {"id": 176, "type": "unary_expression", "text": "~0x1full", "parent": 169, "children": [177, 178], "start_point": {"row": 50, "column": 46}, "end_point": {"row": 50, "column": 54}}, {"id": 177, "type": "~", "text": "~", "parent": 176, "children": [], "start_point": {"row": 50, "column": 46}, "end_point": {"row": 50, "column": 47}}, {"id": 178, "type": "number_literal", "text": "0x1full", "parent": 176, "children": [], "start_point": {"row": 50, "column": 47}, "end_point": {"row": 50, "column": 54}}, {"id": 179, "type": "unary_expression", "text": "~0xfffull", "parent": 169, "children": [180, 181], "start_point": {"row": 50, "column": 57}, "end_point": {"row": 50, "column": 66}}, {"id": 180, "type": "~", "text": "~", "parent": 179, "children": [], "start_point": {"row": 50, "column": 57}, "end_point": {"row": 50, "column": 58}}, {"id": 181, "type": "number_literal", "text": "0xfffull", "parent": 179, "children": [], "start_point": {"row": 50, "column": 58}, "end_point": {"row": 50, "column": 66}}, {"id": 182, "type": "else_clause", "text": "else {\n unsigned int gwidth;\n vcpu_guest_context_any_t ctx;\n if (xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)\n return 0;\n if (xc_domain_get_guest_width(xch, dom, &gwidth) != 0)\n return 0;\n if (gwidth == 8) {\n pt_levels = 4;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;\n } else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }\n }", "parent": 93, "children": [], "start_point": {"row": 51, "column": 6}, "end_point": {"row": 67, "column": 5}}, {"id": 183, "type": "declaration", "text": "unsigned int gwidth;", "parent": 182, "children": [184, 187], "start_point": {"row": 52, "column": 8}, "end_point": {"row": 52, "column": 28}}, {"id": 184, "type": "sized_type_specifier", "text": "unsigned int", "parent": 183, "children": [185, 186], "start_point": {"row": 52, "column": 8}, "end_point": {"row": 52, "column": 20}}, {"id": 185, "type": "unsigned", "text": "unsigned", "parent": 184, "children": [], "start_point": {"row": 52, "column": 8}, "end_point": {"row": 52, "column": 16}}, {"id": 186, "type": "primitive_type", "text": "int", "parent": 184, "children": [], "start_point": {"row": 52, "column": 17}, "end_point": {"row": 52, "column": 20}}, {"id": 187, "type": "identifier", "text": "gwidth", "parent": 183, "children": [], "start_point": {"row": 52, "column": 21}, "end_point": {"row": 52, "column": 27}}, {"id": 188, "type": "declaration", "text": "vcpu_guest_context_any_t ctx;", "parent": 182, "children": [189, 190], "start_point": {"row": 53, "column": 8}, "end_point": {"row": 53, "column": 37}}, {"id": 189, "type": "type_identifier", "text": "vcpu_guest_context_any_t", "parent": 188, "children": [], "start_point": {"row": 53, "column": 8}, "end_point": {"row": 53, "column": 32}}, {"id": 190, "type": "identifier", "text": "ctx", "parent": 188, "children": [], "start_point": {"row": 53, "column": 33}, "end_point": {"row": 53, "column": 36}}, {"id": 191, "type": "if_statement", "text": "if (xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)\n return 0;", "parent": 182, "children": [192, 204], "start_point": {"row": 54, "column": 8}, "end_point": {"row": 55, "column": 21}}, {"id": 192, "type": "parenthesized_expression", "text": "(xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)", "parent": 191, "children": [193], "start_point": {"row": 54, "column": 11}, "end_point": {"row": 54, "column": 58}}, {"id": 193, "type": "binary_expression", "text": "xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0", "parent": 192, "children": [194, 202, 203], "start_point": {"row": 54, "column": 12}, "end_point": {"row": 54, "column": 57}}, {"id": 194, "type": "call_expression", "text": "xc_vcpu_getcontext(xch, dom, vcpu, &ctx)", "parent": 193, "children": [195, 196], "start_point": {"row": 54, "column": 12}, "end_point": {"row": 54, "column": 52}}, {"id": 195, "type": "identifier", "text": "xc_vcpu_getcontext", "parent": 194, "children": [], "start_point": {"row": 54, "column": 12}, "end_point": {"row": 54, "column": 30}}, {"id": 196, "type": "argument_list", "text": "(xch, dom, vcpu, &ctx)", "parent": 194, "children": [197, 198, 199, 200], "start_point": {"row": 54, "column": 30}, "end_point": {"row": 54, "column": 52}}, {"id": 197, "type": "identifier", "text": "xch", "parent": 196, "children": [], "start_point": {"row": 54, "column": 31}, "end_point": {"row": 54, "column": 34}}, {"id": 198, "type": "identifier", "text": "dom", "parent": 196, "children": [], "start_point": {"row": 54, "column": 36}, "end_point": {"row": 54, "column": 39}}, {"id": 199, "type": "identifier", "text": "vcpu", "parent": 196, "children": [], "start_point": {"row": 54, "column": 41}, "end_point": {"row": 54, "column": 45}}, {"id": 200, "type": "pointer_expression", "text": "&ctx", "parent": 196, "children": [201], "start_point": {"row": 54, "column": 47}, "end_point": {"row": 54, "column": 51}}, {"id": 201, "type": "identifier", "text": "ctx", "parent": 200, "children": [], "start_point": {"row": 54, "column": 48}, "end_point": {"row": 54, "column": 51}}, {"id": 202, "type": "!=", "text": "!=", "parent": 193, "children": [], "start_point": {"row": 54, "column": 53}, "end_point": {"row": 54, "column": 55}}, {"id": 203, "type": "number_literal", "text": "0", "parent": 193, "children": [], "start_point": {"row": 54, "column": 56}, "end_point": {"row": 54, "column": 57}}, {"id": 204, "type": "return_statement", "text": "return 0;", "parent": 191, "children": [205], "start_point": {"row": 55, "column": 12}, "end_point": {"row": 55, "column": 21}}, {"id": 205, "type": "number_literal", "text": "0", "parent": 204, "children": [], "start_point": {"row": 55, "column": 19}, "end_point": {"row": 55, "column": 20}}, {"id": 206, "type": "if_statement", "text": "if (xc_domain_get_guest_width(xch, dom, &gwidth) != 0)\n return 0;", "parent": 182, "children": [207, 218], "start_point": {"row": 56, "column": 8}, "end_point": {"row": 57, "column": 21}}, {"id": 207, "type": "parenthesized_expression", "text": "(xc_domain_get_guest_width(xch, dom, &gwidth) != 0)", "parent": 206, "children": [208], "start_point": {"row": 56, "column": 11}, "end_point": {"row": 56, "column": 62}}, {"id": 208, "type": "binary_expression", "text": "xc_domain_get_guest_width(xch, dom, &gwidth) != 0", "parent": 207, "children": [209, 216, 217], "start_point": {"row": 56, "column": 12}, "end_point": {"row": 56, "column": 61}}, {"id": 209, "type": "call_expression", "text": "xc_domain_get_guest_width(xch, dom, &gwidth)", "parent": 208, "children": [210, 211], "start_point": {"row": 56, "column": 12}, "end_point": {"row": 56, "column": 56}}, {"id": 210, "type": "identifier", "text": "xc_domain_get_guest_width", "parent": 209, "children": [], "start_point": {"row": 56, "column": 12}, "end_point": {"row": 56, "column": 37}}, {"id": 211, "type": "argument_list", "text": "(xch, dom, &gwidth)", "parent": 209, "children": [212, 213, 214], "start_point": {"row": 56, "column": 37}, "end_point": {"row": 56, "column": 56}}, {"id": 212, "type": "identifier", "text": "xch", "parent": 211, "children": [], "start_point": {"row": 56, "column": 38}, "end_point": {"row": 56, "column": 41}}, {"id": 213, "type": "identifier", "text": "dom", "parent": 211, "children": [], "start_point": {"row": 56, "column": 43}, "end_point": {"row": 56, "column": 46}}, {"id": 214, "type": "pointer_expression", "text": "&gwidth", "parent": 211, "children": [215], "start_point": {"row": 56, "column": 48}, "end_point": {"row": 56, "column": 55}}, {"id": 215, "type": "identifier", "text": "gwidth", "parent": 214, "children": [], "start_point": {"row": 56, "column": 49}, "end_point": {"row": 56, "column": 55}}, {"id": 216, "type": "!=", "text": "!=", "parent": 208, "children": [], "start_point": {"row": 56, "column": 57}, "end_point": {"row": 56, "column": 59}}, {"id": 217, "type": "number_literal", "text": "0", "parent": 208, "children": [], "start_point": {"row": 56, "column": 60}, "end_point": {"row": 56, "column": 61}}, {"id": 218, "type": "return_statement", "text": "return 0;", "parent": 206, "children": [219], "start_point": {"row": 57, "column": 12}, "end_point": {"row": 57, "column": 21}}, {"id": 219, "type": "number_literal", "text": "0", "parent": 218, "children": [], "start_point": {"row": 57, "column": 19}, "end_point": {"row": 57, "column": 20}}, {"id": 220, "type": "if_statement", "text": "if (gwidth == 8) {\n pt_levels = 4;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;\n } else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }", "parent": 182, "children": [221, 249], "start_point": {"row": 58, "column": 8}, "end_point": {"row": 66, "column": 9}}, {"id": 221, "type": "parenthesized_expression", "text": "(gwidth == 8)", "parent": 220, "children": [222], "start_point": {"row": 58, "column": 11}, "end_point": {"row": 58, "column": 24}}, {"id": 222, "type": "binary_expression", "text": "gwidth == 8", "parent": 221, "children": [223, 224, 225], "start_point": {"row": 58, "column": 12}, "end_point": {"row": 58, "column": 23}}, {"id": 223, "type": "identifier", "text": "gwidth", "parent": 222, "children": [], "start_point": {"row": 58, "column": 12}, "end_point": {"row": 58, "column": 18}}, {"id": 224, "type": "==", "text": "==", "parent": 222, "children": [], "start_point": {"row": 58, "column": 19}, "end_point": {"row": 58, "column": 21}}, {"id": 225, "type": "number_literal", "text": "8", "parent": 222, "children": [], "start_point": {"row": 58, "column": 22}, "end_point": {"row": 58, "column": 23}}, {"id": 226, "type": "assignment_expression", "text": "pt_levels = 4", "parent": 220, "children": [227, 228, 229], "start_point": {"row": 59, "column": 12}, "end_point": {"row": 59, "column": 25}}, {"id": 227, "type": "identifier", "text": "pt_levels", "parent": 226, "children": [], "start_point": {"row": 59, "column": 12}, "end_point": {"row": 59, "column": 21}}, {"id": 228, "type": "=", "text": "=", "parent": 226, "children": [], "start_point": {"row": 59, "column": 22}, "end_point": {"row": 59, "column": 23}}, {"id": 229, "type": "number_literal", "text": "4", "parent": 226, "children": [], "start_point": {"row": 59, "column": 24}, "end_point": {"row": 59, "column": 25}}, {"id": 230, "type": "assignment_expression", "text": "paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT", "parent": 220, "children": [231, 232, 233], "start_point": {"row": 60, "column": 12}, "end_point": {"row": 61, "column": 29}}, {"id": 231, "type": "identifier", "text": "paddr", "parent": 230, "children": [], "start_point": {"row": 60, "column": 12}, "end_point": {"row": 60, "column": 17}}, {"id": 232, "type": "=", "text": "=", "parent": 230, "children": [], "start_point": {"row": 60, "column": 18}, "end_point": {"row": 60, "column": 19}}, {"id": 233, "type": "binary_expression", "text": "(uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT", "parent": 230, "children": [234, 247, 248], "start_point": {"row": 60, "column": 20}, "end_point": {"row": 61, "column": 29}}, {"id": 234, "type": "cast_expression", "text": "(uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])", "parent": 233, "children": [235, 237], "start_point": {"row": 60, "column": 20}, "end_point": {"row": 60, "column": 71}}, {"id": 235, "type": "type_descriptor", "text": "uint64_t", "parent": 234, "children": [236], "start_point": {"row": 60, "column": 21}, "end_point": {"row": 60, "column": 29}}, {"id": 236, "type": "primitive_type", "text": "uint64_t", "parent": 235, "children": [], "start_point": {"row": 60, "column": 21}, "end_point": {"row": 60, "column": 29}}, {"id": 237, "type": "call_expression", "text": "xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])", "parent": 234, "children": [238, 239], "start_point": {"row": 60, "column": 30}, "end_point": {"row": 60, "column": 71}}, {"id": 238, "type": "identifier", "text": "xen_cr3_to_pfn_x86_64", "parent": 237, "children": [], "start_point": {"row": 60, "column": 30}, "end_point": {"row": 60, "column": 51}}, {"id": 239, "type": "argument_list", "text": "(ctx.x64.ctrlreg[3])", "parent": 237, "children": [240], "start_point": {"row": 60, "column": 51}, "end_point": {"row": 60, "column": 71}}, {"id": 240, "type": "subscript_expression", "text": "ctx.x64.ctrlreg[3]", "parent": 239, "children": [241, 246], "start_point": {"row": 60, "column": 52}, "end_point": {"row": 60, "column": 70}}, {"id": 241, "type": "field_expression", "text": "ctx.x64.ctrlreg", "parent": 240, "children": [242, 245], "start_point": {"row": 60, "column": 52}, "end_point": {"row": 60, "column": 67}}, {"id": 242, "type": "field_expression", "text": "ctx.x64", "parent": 241, "children": [243, 244], "start_point": {"row": 60, "column": 52}, "end_point": {"row": 60, "column": 59}}, {"id": 243, "type": "identifier", "text": "ctx", "parent": 242, "children": [], "start_point": {"row": 60, "column": 52}, "end_point": {"row": 60, "column": 55}}, {"id": 244, "type": "field_identifier", "text": "x64", "parent": 242, "children": [], "start_point": {"row": 60, "column": 56}, "end_point": {"row": 60, "column": 59}}, {"id": 245, "type": "field_identifier", "text": "ctrlreg", "parent": 241, "children": [], "start_point": {"row": 60, "column": 60}, "end_point": {"row": 60, "column": 67}}, {"id": 246, "type": "number_literal", "text": "3", "parent": 240, "children": [], "start_point": {"row": 60, "column": 68}, "end_point": {"row": 60, "column": 69}}, {"id": 247, "type": "<<", "text": "<<", "parent": 233, "children": [], "start_point": {"row": 61, "column": 16}, "end_point": {"row": 61, "column": 18}}, {"id": 248, "type": "identifier", "text": "PAGE_SHIFT", "parent": 233, "children": [], "start_point": {"row": 61, "column": 19}, "end_point": {"row": 61, "column": 29}}, {"id": 249, "type": "else_clause", "text": "else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }", "parent": 220, "children": [], "start_point": {"row": 62, "column": 10}, "end_point": {"row": 66, "column": 9}}, {"id": 250, "type": "assignment_expression", "text": "pt_levels = 3", "parent": 249, "children": [251, 252, 253], "start_point": {"row": 63, "column": 12}, "end_point": {"row": 63, "column": 25}}, {"id": 251, "type": "identifier", "text": "pt_levels", "parent": 250, "children": [], "start_point": {"row": 63, "column": 12}, "end_point": {"row": 63, "column": 21}}, {"id": 252, "type": "=", "text": "=", "parent": 250, "children": [], "start_point": {"row": 63, "column": 22}, "end_point": {"row": 63, "column": 23}}, {"id": 253, "type": "number_literal", "text": "3", "parent": 250, "children": [], "start_point": {"row": 63, "column": 24}, "end_point": {"row": 63, "column": 25}}, {"id": 254, "type": "assignment_expression", "text": "paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT", "parent": 249, "children": [255, 256, 257], "start_point": {"row": 64, "column": 12}, "end_point": {"row": 65, "column": 29}}, {"id": 255, "type": "identifier", "text": "paddr", "parent": 254, "children": [], "start_point": {"row": 64, "column": 12}, "end_point": {"row": 64, "column": 17}}, {"id": 256, "type": "=", "text": "=", "parent": 254, "children": [], "start_point": {"row": 64, "column": 18}, "end_point": {"row": 64, "column": 19}}, {"id": 257, "type": "binary_expression", "text": "(uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT", "parent": 254, "children": [258, 271, 272], "start_point": {"row": 64, "column": 20}, "end_point": {"row": 65, "column": 29}}, {"id": 258, "type": "cast_expression", "text": "(uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])", "parent": 257, "children": [259, 261], "start_point": {"row": 64, "column": 20}, "end_point": {"row": 64, "column": 71}}, {"id": 259, "type": "type_descriptor", "text": "uint64_t", "parent": 258, "children": [260], "start_point": {"row": 64, "column": 21}, "end_point": {"row": 64, "column": 29}}, {"id": 260, "type": "primitive_type", "text": "uint64_t", "parent": 259, "children": [], "start_point": {"row": 64, "column": 21}, "end_point": {"row": 64, "column": 29}}, {"id": 261, "type": "call_expression", "text": "xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])", "parent": 258, "children": [262, 263], "start_point": {"row": 64, "column": 30}, "end_point": {"row": 64, "column": 71}}, {"id": 262, "type": "identifier", "text": "xen_cr3_to_pfn_x86_32", "parent": 261, "children": [], "start_point": {"row": 64, "column": 30}, "end_point": {"row": 64, "column": 51}}, {"id": 263, "type": "argument_list", "text": "(ctx.x32.ctrlreg[3])", "parent": 261, "children": [264], "start_point": {"row": 64, "column": 51}, "end_point": {"row": 64, "column": 71}}, {"id": 264, "type": "subscript_expression", "text": "ctx.x32.ctrlreg[3]", "parent": 263, "children": [265, 270], "start_point": {"row": 64, "column": 52}, "end_point": {"row": 64, "column": 70}}, {"id": 265, "type": "field_expression", "text": "ctx.x32.ctrlreg", "parent": 264, "children": [266, 269], "start_point": {"row": 64, "column": 52}, "end_point": {"row": 64, "column": 67}}, {"id": 266, "type": "field_expression", "text": "ctx.x32", "parent": 265, "children": [267, 268], "start_point": {"row": 64, "column": 52}, "end_point": {"row": 64, "column": 59}}, {"id": 267, "type": "identifier", "text": "ctx", "parent": 266, "children": [], "start_point": {"row": 64, "column": 52}, "end_point": {"row": 64, "column": 55}}, {"id": 268, "type": "field_identifier", "text": "x32", "parent": 266, "children": [], "start_point": {"row": 64, "column": 56}, "end_point": {"row": 64, "column": 59}}, {"id": 269, "type": "field_identifier", "text": "ctrlreg", "parent": 265, "children": [], "start_point": {"row": 64, "column": 60}, "end_point": {"row": 64, "column": 67}}, {"id": 270, "type": "number_literal", "text": "3", "parent": 264, "children": [], "start_point": {"row": 64, "column": 68}, "end_point": {"row": 64, "column": 69}}, {"id": 271, "type": "<<", "text": "<<", "parent": 257, "children": [], "start_point": {"row": 65, "column": 16}, "end_point": {"row": 65, "column": 18}}, {"id": 272, "type": "identifier", "text": "PAGE_SHIFT", "parent": 257, "children": [], "start_point": {"row": 65, "column": 19}, "end_point": {"row": 65, "column": 29}}, {"id": 273, "type": "if_statement", "text": "if (pt_levels == 4) {\n virt &= 0x0000ffffffffffffull;\n mask = 0x0000ff8000000000ull;\n } else if (pt_levels == 3) {\n virt &= 0x00000000ffffffffull;\n mask = 0x0000007fc0000000ull;\n } else {\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }", "parent": 22, "children": [274, 287], "start_point": {"row": 69, "column": 4}, "end_point": {"row": 78, "column": 5}}, {"id": 274, "type": "parenthesized_expression", "text": "(pt_levels == 4)", "parent": 273, "children": [275], "start_point": {"row": 69, "column": 7}, "end_point": {"row": 69, "column": 23}}, {"id": 275, "type": "binary_expression", "text": "pt_levels == 4", "parent": 274, "children": [276, 277, 278], "start_point": {"row": 69, "column": 8}, "end_point": {"row": 69, "column": 22}}, {"id": 276, "type": "identifier", "text": "pt_levels", "parent": 275, "children": [], "start_point": {"row": 69, "column": 8}, "end_point": {"row": 69, "column": 17}}, {"id": 277, "type": "==", "text": "==", "parent": 275, "children": [], "start_point": {"row": 69, "column": 18}, "end_point": {"row": 69, "column": 20}}, {"id": 278, "type": "number_literal", "text": "4", "parent": 275, "children": [], "start_point": {"row": 69, "column": 21}, "end_point": {"row": 69, "column": 22}}, {"id": 279, "type": "assignment_expression", "text": "virt &= 0x0000ffffffffffffull", "parent": 273, "children": [280, 281, 282], "start_point": {"row": 70, "column": 8}, "end_point": {"row": 70, "column": 37}}, {"id": 280, "type": "identifier", "text": "virt", "parent": 279, "children": [], "start_point": {"row": 70, "column": 8}, "end_point": {"row": 70, "column": 12}}, {"id": 281, "type": "&=", "text": "&=", "parent": 279, "children": [], "start_point": {"row": 70, "column": 13}, "end_point": {"row": 70, "column": 15}}, {"id": 282, "type": "number_literal", "text": "0x0000ffffffffffffull", "parent": 279, "children": [], "start_point": {"row": 70, "column": 16}, "end_point": {"row": 70, "column": 37}}, {"id": 283, "type": "assignment_expression", "text": "mask = 0x0000ff8000000000ull", "parent": 273, "children": [284, 285, 286], "start_point": {"row": 71, "column": 8}, "end_point": {"row": 71, "column": 37}}, {"id": 284, "type": "identifier", "text": "mask", "parent": 283, "children": [], "start_point": {"row": 71, "column": 8}, "end_point": {"row": 71, "column": 12}}, {"id": 285, "type": "=", "text": "=", "parent": 283, "children": [], "start_point": {"row": 71, "column": 13}, "end_point": {"row": 71, "column": 14}}, {"id": 286, "type": "number_literal", "text": "0x0000ff8000000000ull", "parent": 283, "children": [], "start_point": {"row": 71, "column": 16}, "end_point": {"row": 71, "column": 37}}, {"id": 287, "type": "else_clause", "text": "else if (pt_levels == 3) {\n virt &= 0x00000000ffffffffull;\n mask = 0x0000007fc0000000ull;\n } else {\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }", "parent": 273, "children": [288], "start_point": {"row": 72, "column": 6}, "end_point": {"row": 78, "column": 5}}, {"id": 288, "type": "if_statement", "text": "if (pt_levels == 3) {\n virt &= 0x00000000ffffffffull;\n mask = 0x0000007fc0000000ull;\n } else {\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }", "parent": 287, "children": [289, 302], "start_point": {"row": 72, "column": 11}, "end_point": {"row": 78, "column": 5}}, {"id": 289, "type": "parenthesized_expression", "text": "(pt_levels == 3)", "parent": 288, "children": [290], "start_point": {"row": 72, "column": 14}, "end_point": {"row": 72, "column": 30}}, {"id": 290, "type": "binary_expression", "text": "pt_levels == 3", "parent": 289, "children": [291, 292, 293], "start_point": {"row": 72, "column": 15}, "end_point": {"row": 72, "column": 29}}, {"id": 291, "type": "identifier", "text": "pt_levels", "parent": 290, "children": [], "start_point": {"row": 72, "column": 15}, "end_point": {"row": 72, "column": 24}}, {"id": 292, "type": "==", "text": "==", "parent": 290, "children": [], "start_point": {"row": 72, "column": 25}, "end_point": {"row": 72, "column": 27}}, {"id": 293, "type": "number_literal", "text": "3", "parent": 290, "children": [], "start_point": {"row": 72, "column": 28}, "end_point": {"row": 72, "column": 29}}, {"id": 294, "type": "assignment_expression", "text": "virt &= 0x00000000ffffffffull", "parent": 288, "children": [295, 296, 297], "start_point": {"row": 73, "column": 8}, "end_point": {"row": 73, "column": 37}}, {"id": 295, "type": "identifier", "text": "virt", "parent": 294, "children": [], "start_point": {"row": 73, "column": 8}, "end_point": {"row": 73, "column": 12}}, {"id": 296, "type": "&=", "text": "&=", "parent": 294, "children": [], "start_point": {"row": 73, "column": 13}, "end_point": {"row": 73, "column": 15}}, {"id": 297, "type": "number_literal", "text": "0x00000000ffffffffull", "parent": 294, "children": [], "start_point": {"row": 73, "column": 16}, "end_point": {"row": 73, "column": 37}}, {"id": 298, "type": "assignment_expression", "text": "mask = 0x0000007fc0000000ull", "parent": 288, "children": [299, 300, 301], "start_point": {"row": 74, "column": 8}, "end_point": {"row": 74, "column": 37}}, {"id": 299, "type": "identifier", "text": "mask", "parent": 298, "children": [], "start_point": {"row": 74, "column": 8}, "end_point": {"row": 74, "column": 12}}, {"id": 300, "type": "=", "text": "=", "parent": 298, "children": [], "start_point": {"row": 74, "column": 13}, "end_point": {"row": 74, "column": 14}}, {"id": 301, "type": "number_literal", "text": "0x0000007fc0000000ull", "parent": 298, "children": [], "start_point": {"row": 74, "column": 16}, "end_point": {"row": 74, "column": 37}}, {"id": 302, "type": "else_clause", "text": "else {\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }", "parent": 288, "children": [], "start_point": {"row": 75, "column": 6}, "end_point": {"row": 78, "column": 5}}, {"id": 303, "type": "assignment_expression", "text": "virt &= 0x00000000ffffffffull", "parent": 302, "children": [304, 305, 306], "start_point": {"row": 76, "column": 8}, "end_point": {"row": 76, "column": 37}}, {"id": 304, "type": "identifier", "text": "virt", "parent": 303, "children": [], "start_point": {"row": 76, "column": 8}, "end_point": {"row": 76, "column": 12}}, {"id": 305, "type": "&=", "text": "&=", "parent": 303, "children": [], "start_point": {"row": 76, "column": 13}, "end_point": {"row": 76, "column": 15}}, {"id": 306, "type": "number_literal", "text": "0x00000000ffffffffull", "parent": 303, "children": [], "start_point": {"row": 76, "column": 16}, "end_point": {"row": 76, "column": 37}}, {"id": 307, "type": "assignment_expression", "text": "mask = 0x00000000ffc00000ull", "parent": 302, "children": [308, 309, 310], "start_point": {"row": 77, "column": 8}, "end_point": {"row": 77, "column": 37}}, {"id": 308, "type": "identifier", "text": "mask", "parent": 307, "children": [], "start_point": {"row": 77, "column": 8}, "end_point": {"row": 77, "column": 12}}, {"id": 309, "type": "=", "text": "=", "parent": 307, "children": [], "start_point": {"row": 77, "column": 13}, "end_point": {"row": 77, "column": 14}}, {"id": 310, "type": "number_literal", "text": "0x00000000ffc00000ull", "parent": 307, "children": [], "start_point": {"row": 77, "column": 16}, "end_point": {"row": 77, "column": 37}}, {"id": 311, "type": "assignment_expression", "text": "size = (pt_levels == 2 ? 4 : 8)", "parent": 22, "children": [312, 313, 314], "start_point": {"row": 79, "column": 4}, "end_point": {"row": 79, "column": 35}}, {"id": 312, "type": "identifier", "text": "size", "parent": 311, "children": [], "start_point": {"row": 79, "column": 4}, "end_point": {"row": 79, "column": 8}}, {"id": 313, "type": "=", "text": "=", "parent": 311, "children": [], "start_point": {"row": 79, "column": 9}, "end_point": {"row": 79, "column": 10}}, {"id": 314, "type": "parenthesized_expression", "text": "(pt_levels == 2 ? 4 : 8)", "parent": 311, "children": [315], "start_point": {"row": 79, "column": 11}, "end_point": {"row": 79, "column": 35}}, {"id": 315, "type": "conditional_expression", "text": "pt_levels == 2 ? 4 : 8", "parent": 314, "children": [316, 320, 321, 322], "start_point": {"row": 79, "column": 12}, "end_point": {"row": 79, "column": 34}}, {"id": 316, "type": "binary_expression", "text": "pt_levels == 2", "parent": 315, "children": [317, 318, 319], "start_point": {"row": 79, "column": 12}, "end_point": {"row": 79, "column": 26}}, {"id": 317, "type": "identifier", "text": "pt_levels", "parent": 316, "children": [], "start_point": {"row": 79, "column": 12}, "end_point": {"row": 79, "column": 21}}, {"id": 318, "type": "==", "text": "==", "parent": 316, "children": [], "start_point": {"row": 79, "column": 22}, "end_point": {"row": 79, "column": 24}}, {"id": 319, "type": "number_literal", "text": "2", "parent": 316, "children": [], "start_point": {"row": 79, "column": 25}, "end_point": {"row": 79, "column": 26}}, {"id": 320, "type": "?", "text": "?", "parent": 315, "children": [], "start_point": {"row": 79, "column": 27}, "end_point": {"row": 79, "column": 28}}, {"id": 321, "type": "number_literal", "text": "4", "parent": 315, "children": [], "start_point": {"row": 79, "column": 29}, "end_point": {"row": 79, "column": 30}}, {"id": 322, "type": "number_literal", "text": "8", "parent": 315, "children": [], "start_point": {"row": 79, "column": 33}, "end_point": {"row": 79, "column": 34}}, {"id": 323, "type": "for_statement", "text": "for (level = pt_levels; level > 0; level--) {\n paddr += ((virt & mask) >> (xc_ffs64(mask) - 1)) * size;\n map = xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT);\n if (!map) \n return 0;\n memcpy(&pte, map + (paddr & (PAGE_SIZE - 1)), size);\n munmap(map, PAGE_SIZE);\n if (!(pte & 1)) \n return 0;\n paddr = pte & 0x000ffffffffff000ull;\n if (level == 2 && (pte & PTE_PSE)) {\n mask = ((mask ^ ~-mask) >> 1); /* All bits below first set bit */\n return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT;\n }\n mask >>= (pt_levels == 2 ? 10 : 9);\n }", "parent": 22, "children": [324, 328, 332], "start_point": {"row": 82, "column": 4}, "end_point": {"row": 98, "column": 5}}, {"id": 324, "type": "assignment_expression", "text": "level = pt_levels", "parent": 323, "children": [325, 326, 327], "start_point": {"row": 82, "column": 9}, "end_point": {"row": 82, "column": 26}}, {"id": 325, "type": "identifier", "text": "level", "parent": 324, "children": [], "start_point": {"row": 82, "column": 9}, "end_point": {"row": 82, "column": 14}}, {"id": 326, "type": "=", "text": "=", "parent": 324, "children": [], "start_point": {"row": 82, "column": 15}, "end_point": {"row": 82, "column": 16}}, {"id": 327, "type": "identifier", "text": "pt_levels", "parent": 324, "children": [], "start_point": {"row": 82, "column": 17}, "end_point": {"row": 82, "column": 26}}, {"id": 328, "type": "binary_expression", "text": "level > 0", "parent": 323, "children": [329, 330, 331], "start_point": {"row": 82, "column": 28}, "end_point": {"row": 82, "column": 37}}, {"id": 329, "type": "identifier", "text": "level", "parent": 328, "children": [], "start_point": {"row": 82, "column": 28}, "end_point": {"row": 82, "column": 33}}, {"id": 330, "type": ">", "text": ">", "parent": 328, "children": [], "start_point": {"row": 82, "column": 34}, "end_point": {"row": 82, "column": 35}}, {"id": 331, "type": "number_literal", "text": "0", "parent": 328, "children": [], "start_point": {"row": 82, "column": 36}, "end_point": {"row": 82, "column": 37}}, {"id": 332, "type": "update_expression", "text": "level--", "parent": 323, "children": [333, 334], "start_point": {"row": 82, "column": 39}, "end_point": {"row": 82, "column": 46}}, {"id": 333, "type": "identifier", "text": "level", "parent": 332, "children": [], "start_point": {"row": 82, "column": 39}, "end_point": {"row": 82, "column": 44}}, {"id": 334, "type": "--", "text": "--", "parent": 332, "children": [], "start_point": {"row": 82, "column": 44}, "end_point": {"row": 82, "column": 46}}, {"id": 335, "type": "assignment_expression", "text": "paddr += ((virt & mask) >> (xc_ffs64(mask) - 1)) * size", "parent": 323, "children": [336, 337, 338], "start_point": {"row": 83, "column": 8}, "end_point": {"row": 83, "column": 63}}, {"id": 336, "type": "identifier", "text": "paddr", "parent": 335, "children": [], "start_point": {"row": 83, "column": 8}, "end_point": {"row": 83, "column": 13}}, {"id": 337, "type": "+=", "text": "+=", "parent": 335, "children": [], "start_point": {"row": 83, "column": 14}, "end_point": {"row": 83, "column": 16}}, {"id": 338, "type": "binary_expression", "text": "((virt & mask) >> (xc_ffs64(mask) - 1)) * size", "parent": 335, "children": [339, 354, 355], "start_point": {"row": 83, "column": 17}, "end_point": {"row": 83, "column": 63}}, {"id": 339, "type": "parenthesized_expression", "text": "((virt & mask) >> (xc_ffs64(mask) - 1))", "parent": 338, "children": [340], "start_point": {"row": 83, "column": 17}, "end_point": {"row": 83, "column": 56}}, {"id": 340, "type": "binary_expression", "text": "(virt & mask) >> (xc_ffs64(mask) - 1)", "parent": 339, "children": [341, 345, 346], "start_point": {"row": 83, "column": 18}, "end_point": {"row": 83, "column": 55}}, {"id": 341, "type": "parenthesized_expression", "text": "(virt & mask)", "parent": 340, "children": [342], "start_point": {"row": 83, "column": 18}, "end_point": {"row": 83, "column": 31}}, {"id": 342, "type": "binary_expression", "text": "virt & mask", "parent": 341, "children": [343, 344], "start_point": {"row": 83, "column": 19}, "end_point": {"row": 83, "column": 30}}, {"id": 343, "type": "identifier", "text": "virt", "parent": 342, "children": [], "start_point": {"row": 83, "column": 19}, "end_point": {"row": 83, "column": 23}}, {"id": 344, "type": "identifier", "text": "mask", "parent": 342, "children": [], "start_point": {"row": 83, "column": 26}, "end_point": {"row": 83, "column": 30}}, {"id": 345, "type": ">>", "text": ">>", "parent": 340, "children": [], "start_point": {"row": 83, "column": 32}, "end_point": {"row": 83, "column": 34}}, {"id": 346, "type": "parenthesized_expression", "text": "(xc_ffs64(mask) - 1)", "parent": 340, "children": [347], "start_point": {"row": 83, "column": 35}, "end_point": {"row": 83, "column": 55}}, {"id": 347, "type": "binary_expression", "text": "xc_ffs64(mask) - 1", "parent": 346, "children": [348, 352, 353], "start_point": {"row": 83, "column": 36}, "end_point": {"row": 83, "column": 54}}, {"id": 348, "type": "call_expression", "text": "xc_ffs64(mask)", "parent": 347, "children": [349, 350], "start_point": {"row": 83, "column": 36}, "end_point": {"row": 83, "column": 50}}, {"id": 349, "type": "identifier", "text": "xc_ffs64", "parent": 348, "children": [], "start_point": {"row": 83, "column": 36}, "end_point": {"row": 83, "column": 44}}, {"id": 350, "type": "argument_list", "text": "(mask)", "parent": 348, "children": [351], "start_point": {"row": 83, "column": 44}, "end_point": {"row": 83, "column": 50}}, {"id": 351, "type": "identifier", "text": "mask", "parent": 350, "children": [], "start_point": {"row": 83, "column": 45}, "end_point": {"row": 83, "column": 49}}, {"id": 352, "type": "-", "text": "-", "parent": 347, "children": [], "start_point": {"row": 83, "column": 51}, "end_point": {"row": 83, "column": 52}}, {"id": 353, "type": "number_literal", "text": "1", "parent": 347, "children": [], "start_point": {"row": 83, "column": 53}, "end_point": {"row": 83, "column": 54}}, {"id": 354, "type": "*", "text": "*", "parent": 338, "children": [], "start_point": {"row": 83, "column": 57}, "end_point": {"row": 83, "column": 58}}, {"id": 355, "type": "identifier", "text": "size", "parent": 338, "children": [], "start_point": {"row": 83, "column": 59}, "end_point": {"row": 83, "column": 63}}, {"id": 356, "type": "assignment_expression", "text": "map = xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT)", "parent": 323, "children": [357, 358, 359], "start_point": {"row": 84, "column": 8}, "end_point": {"row": 85, "column": 54}}, {"id": 357, "type": "identifier", "text": "map", "parent": 356, "children": [], "start_point": {"row": 84, "column": 8}, "end_point": {"row": 84, "column": 11}}, {"id": 358, "type": "=", "text": "=", "parent": 356, "children": [], "start_point": {"row": 84, "column": 12}, "end_point": {"row": 84, "column": 13}}, {"id": 359, "type": "call_expression", "text": "xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT)", "parent": 356, "children": [360, 361], "start_point": {"row": 84, "column": 14}, "end_point": {"row": 85, "column": 54}}, {"id": 360, "type": "identifier", "text": "xc_map_foreign_range", "parent": 359, "children": [], "start_point": {"row": 84, "column": 14}, "end_point": {"row": 84, "column": 34}}, {"id": 361, "type": "argument_list", "text": "(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT)", "parent": 359, "children": [362, 363, 364, 365, 366], "start_point": {"row": 84, "column": 34}, "end_point": {"row": 85, "column": 54}}, {"id": 362, "type": "identifier", "text": "xch", "parent": 361, "children": [], "start_point": {"row": 84, "column": 35}, "end_point": {"row": 84, "column": 38}}, {"id": 363, "type": "identifier", "text": "dom", "parent": 361, "children": [], "start_point": {"row": 84, "column": 40}, "end_point": {"row": 84, "column": 43}}, {"id": 364, "type": "identifier", "text": "PAGE_SIZE", "parent": 361, "children": [], "start_point": {"row": 84, "column": 45}, "end_point": {"row": 84, "column": 54}}, {"id": 365, "type": "identifier", "text": "PROT_READ", "parent": 361, "children": [], "start_point": {"row": 84, "column": 56}, "end_point": {"row": 84, "column": 65}}, {"id": 366, "type": "binary_expression", "text": "paddr >>PAGE_SHIFT", "parent": 361, "children": [367, 368, 369], "start_point": {"row": 85, "column": 35}, "end_point": {"row": 85, "column": 53}}, {"id": 367, "type": "identifier", "text": "paddr", "parent": 366, "children": [], "start_point": {"row": 85, "column": 35}, "end_point": {"row": 85, "column": 40}}, {"id": 368, "type": ">>", "text": ">>", "parent": 366, "children": [], "start_point": {"row": 85, "column": 41}, "end_point": {"row": 85, "column": 43}}, {"id": 369, "type": "identifier", "text": "PAGE_SHIFT", "parent": 366, "children": [], "start_point": {"row": 85, "column": 43}, "end_point": {"row": 85, "column": 53}}, {"id": 370, "type": "if_statement", "text": "if (!map) \n return 0;", "parent": 323, "children": [371, 375], "start_point": {"row": 86, "column": 8}, "end_point": {"row": 87, "column": 21}}, {"id": 371, "type": "parenthesized_expression", "text": "(!map)", "parent": 370, "children": [372], "start_point": {"row": 86, "column": 11}, "end_point": {"row": 86, "column": 17}}, {"id": 372, "type": "unary_expression", "text": "!map", "parent": 371, "children": [373, 374], "start_point": {"row": 86, "column": 12}, "end_point": {"row": 86, "column": 16}}, {"id": 373, "type": "!", "text": "!", "parent": 372, "children": [], "start_point": {"row": 86, "column": 12}, "end_point": {"row": 86, "column": 13}}, {"id": 374, "type": "identifier", "text": "map", "parent": 372, "children": [], "start_point": {"row": 86, "column": 13}, "end_point": {"row": 86, "column": 16}}, {"id": 375, "type": "return_statement", "text": "return 0;", "parent": 370, "children": [376], "start_point": {"row": 87, "column": 12}, "end_point": {"row": 87, "column": 21}}, {"id": 376, "type": "number_literal", "text": "0", "parent": 375, "children": [], "start_point": {"row": 87, "column": 19}, "end_point": {"row": 87, "column": 20}}, {"id": 377, "type": "call_expression", "text": "memcpy(&pte, map + (paddr & (PAGE_SIZE - 1)), size)", "parent": 323, "children": [378, 379], "start_point": {"row": 88, "column": 8}, "end_point": {"row": 88, "column": 59}}, {"id": 378, "type": "identifier", "text": "memcpy", "parent": 377, "children": [], "start_point": {"row": 88, "column": 8}, "end_point": {"row": 88, "column": 14}}, {"id": 379, "type": "argument_list", "text": "(&pte, map + (paddr & (PAGE_SIZE - 1)), size)", "parent": 377, "children": [380, 382, 393], "start_point": {"row": 88, "column": 14}, "end_point": {"row": 88, "column": 59}}, {"id": 380, "type": "pointer_expression", "text": "&pte", "parent": 379, "children": [381], "start_point": {"row": 88, "column": 15}, "end_point": {"row": 88, "column": 19}}, {"id": 381, "type": "identifier", "text": "pte", "parent": 380, "children": [], "start_point": {"row": 88, "column": 16}, "end_point": {"row": 88, "column": 19}}, {"id": 382, "type": "binary_expression", "text": "map + (paddr & (PAGE_SIZE - 1))", "parent": 379, "children": [383, 384, 385], "start_point": {"row": 88, "column": 21}, "end_point": {"row": 88, "column": 52}}, {"id": 383, "type": "identifier", "text": "map", "parent": 382, "children": [], "start_point": {"row": 88, "column": 21}, "end_point": {"row": 88, "column": 24}}, {"id": 384, "type": "+", "text": "+", "parent": 382, "children": [], "start_point": {"row": 88, "column": 25}, "end_point": {"row": 88, "column": 26}}, {"id": 385, "type": "parenthesized_expression", "text": "(paddr & (PAGE_SIZE - 1))", "parent": 382, "children": [386], "start_point": {"row": 88, "column": 27}, "end_point": {"row": 88, "column": 52}}, {"id": 386, "type": "binary_expression", "text": "paddr & (PAGE_SIZE - 1)", "parent": 385, "children": [387, 388], "start_point": {"row": 88, "column": 28}, "end_point": {"row": 88, "column": 51}}, {"id": 387, "type": "identifier", "text": "paddr", "parent": 386, "children": [], "start_point": {"row": 88, "column": 28}, "end_point": {"row": 88, "column": 33}}, {"id": 388, "type": "parenthesized_expression", "text": "(PAGE_SIZE - 1)", "parent": 386, "children": [389], "start_point": {"row": 88, "column": 36}, "end_point": {"row": 88, "column": 51}}, {"id": 389, "type": "binary_expression", "text": "PAGE_SIZE - 1", "parent": 388, "children": [390, 391, 392], "start_point": {"row": 88, "column": 37}, "end_point": {"row": 88, "column": 50}}, {"id": 390, "type": "identifier", "text": "PAGE_SIZE", "parent": 389, "children": [], "start_point": {"row": 88, "column": 37}, "end_point": {"row": 88, "column": 46}}, {"id": 391, "type": "-", "text": "-", "parent": 389, "children": [], "start_point": {"row": 88, "column": 47}, "end_point": {"row": 88, "column": 48}}, {"id": 392, "type": "number_literal", "text": "1", "parent": 389, "children": [], "start_point": {"row": 88, "column": 49}, "end_point": {"row": 88, "column": 50}}, {"id": 393, "type": "identifier", "text": "size", "parent": 379, "children": [], "start_point": {"row": 88, "column": 54}, "end_point": {"row": 88, "column": 58}}, {"id": 394, "type": "call_expression", "text": "munmap(map, PAGE_SIZE)", "parent": 323, "children": [395, 396], "start_point": {"row": 89, "column": 8}, "end_point": {"row": 89, "column": 30}}, {"id": 395, "type": "identifier", "text": "munmap", "parent": 394, "children": [], "start_point": {"row": 89, "column": 8}, "end_point": {"row": 89, "column": 14}}, {"id": 396, "type": "argument_list", "text": "(map, PAGE_SIZE)", "parent": 394, "children": [397, 398], "start_point": {"row": 89, "column": 14}, "end_point": {"row": 89, "column": 30}}, {"id": 397, "type": "identifier", "text": "map", "parent": 396, "children": [], "start_point": {"row": 89, "column": 15}, "end_point": {"row": 89, "column": 18}}, {"id": 398, "type": "identifier", "text": "PAGE_SIZE", "parent": 396, "children": [], "start_point": {"row": 89, "column": 20}, "end_point": {"row": 89, "column": 29}}, {"id": 399, "type": "if_statement", "text": "if (!(pte & 1)) \n return 0;", "parent": 323, "children": [400, 407], "start_point": {"row": 90, "column": 8}, "end_point": {"row": 91, "column": 21}}, {"id": 400, "type": "parenthesized_expression", "text": "(!(pte & 1))", "parent": 399, "children": [401], "start_point": {"row": 90, "column": 11}, "end_point": {"row": 90, "column": 23}}, {"id": 401, "type": "unary_expression", "text": "!(pte & 1)", "parent": 400, "children": [402, 403], "start_point": {"row": 90, "column": 12}, "end_point": {"row": 90, "column": 22}}, {"id": 402, "type": "!", "text": "!", "parent": 401, "children": [], "start_point": {"row": 90, "column": 12}, "end_point": {"row": 90, "column": 13}}, {"id": 403, "type": "parenthesized_expression", "text": "(pte & 1)", "parent": 401, "children": [404], "start_point": {"row": 90, "column": 13}, "end_point": {"row": 90, "column": 22}}, {"id": 404, "type": "binary_expression", "text": "pte & 1", "parent": 403, "children": [405, 406], "start_point": {"row": 90, "column": 14}, "end_point": {"row": 90, "column": 21}}, {"id": 405, "type": "identifier", "text": "pte", "parent": 404, "children": [], "start_point": {"row": 90, "column": 14}, "end_point": {"row": 90, "column": 17}}, {"id": 406, "type": "number_literal", "text": "1", "parent": 404, "children": [], "start_point": {"row": 90, "column": 20}, "end_point": {"row": 90, "column": 21}}, {"id": 407, "type": "return_statement", "text": "return 0;", "parent": 399, "children": [408], "start_point": {"row": 91, "column": 12}, "end_point": {"row": 91, "column": 21}}, {"id": 408, "type": "number_literal", "text": "0", "parent": 407, "children": [], "start_point": {"row": 91, "column": 19}, "end_point": {"row": 91, "column": 20}}, {"id": 409, "type": "assignment_expression", "text": "paddr = pte & 0x000ffffffffff000ull", "parent": 323, "children": [410, 411, 412], "start_point": {"row": 92, "column": 8}, "end_point": {"row": 92, "column": 43}}, {"id": 410, "type": "identifier", "text": "paddr", "parent": 409, "children": [], "start_point": {"row": 92, "column": 8}, "end_point": {"row": 92, "column": 13}}, {"id": 411, "type": "=", "text": "=", "parent": 409, "children": [], "start_point": {"row": 92, "column": 14}, "end_point": {"row": 92, "column": 15}}, {"id": 412, "type": "binary_expression", "text": "pte & 0x000ffffffffff000ull", "parent": 409, "children": [413, 414], "start_point": {"row": 92, "column": 16}, "end_point": {"row": 92, "column": 43}}, {"id": 413, "type": "identifier", "text": "pte", "parent": 412, "children": [], "start_point": {"row": 92, "column": 16}, "end_point": {"row": 92, "column": 19}}, {"id": 414, "type": "number_literal", "text": "0x000ffffffffff000ull", "parent": 412, "children": [], "start_point": {"row": 92, "column": 22}, "end_point": {"row": 92, "column": 43}}, {"id": 415, "type": "if_statement", "text": "if (level == 2 && (pte & PTE_PSE)) {\n mask = ((mask ^ ~-mask) >> 1); /* All bits below first set bit */\n return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT;\n }", "parent": 323, "children": [416], "start_point": {"row": 93, "column": 8}, "end_point": {"row": 96, "column": 9}}, {"id": 416, "type": "parenthesized_expression", "text": "(level == 2 && (pte & PTE_PSE))", "parent": 415, "children": [417], "start_point": {"row": 93, "column": 11}, "end_point": {"row": 93, "column": 42}}, {"id": 417, "type": "binary_expression", "text": "level == 2 && (pte & PTE_PSE)", "parent": 416, "children": [418, 422, 423], "start_point": {"row": 93, "column": 12}, "end_point": {"row": 93, "column": 41}}, {"id": 418, "type": "binary_expression", "text": "level == 2", "parent": 417, "children": [419, 420, 421], "start_point": {"row": 93, "column": 12}, "end_point": {"row": 93, "column": 22}}, {"id": 419, "type": "identifier", "text": "level", "parent": 418, "children": [], "start_point": {"row": 93, "column": 12}, "end_point": {"row": 93, "column": 17}}, {"id": 420, "type": "==", "text": "==", "parent": 418, "children": [], "start_point": {"row": 93, "column": 18}, "end_point": {"row": 93, "column": 20}}, {"id": 421, "type": "number_literal", "text": "2", "parent": 418, "children": [], "start_point": {"row": 93, "column": 21}, "end_point": {"row": 93, "column": 22}}, {"id": 422, "type": "&&", "text": "&&", "parent": 417, "children": [], "start_point": {"row": 93, "column": 23}, "end_point": {"row": 93, "column": 25}}, {"id": 423, "type": "parenthesized_expression", "text": "(pte & PTE_PSE)", "parent": 417, "children": [424], "start_point": {"row": 93, "column": 26}, "end_point": {"row": 93, "column": 41}}, {"id": 424, "type": "binary_expression", "text": "pte & PTE_PSE", "parent": 423, "children": [425, 426], "start_point": {"row": 93, "column": 27}, "end_point": {"row": 93, "column": 40}}, {"id": 425, "type": "identifier", "text": "pte", "parent": 424, "children": [], "start_point": {"row": 93, "column": 27}, "end_point": {"row": 93, "column": 30}}, {"id": 426, "type": "identifier", "text": "PTE_PSE", "parent": 424, "children": [], "start_point": {"row": 93, "column": 33}, "end_point": {"row": 93, "column": 40}}, {"id": 427, "type": "assignment_expression", "text": "mask = ((mask ^ ~-mask) >> 1)", "parent": 415, "children": [428, 429, 430], "start_point": {"row": 94, "column": 12}, "end_point": {"row": 94, "column": 41}}, {"id": 428, "type": "identifier", "text": "mask", "parent": 427, "children": [], "start_point": {"row": 94, "column": 12}, "end_point": {"row": 94, "column": 16}}, {"id": 429, "type": "=", "text": "=", "parent": 427, "children": [], "start_point": {"row": 94, "column": 17}, "end_point": {"row": 94, "column": 18}}, {"id": 430, "type": "parenthesized_expression", "text": "((mask ^ ~-mask) >> 1)", "parent": 427, "children": [431], "start_point": {"row": 94, "column": 19}, "end_point": {"row": 94, "column": 41}}, {"id": 431, "type": "binary_expression", "text": "(mask ^ ~-mask) >> 1", "parent": 430, "children": [432, 441, 442], "start_point": {"row": 94, "column": 20}, "end_point": {"row": 94, "column": 40}}, {"id": 432, "type": "parenthesized_expression", "text": "(mask ^ ~-mask)", "parent": 431, "children": [433], "start_point": {"row": 94, "column": 20}, "end_point": {"row": 94, "column": 35}}, {"id": 433, "type": "binary_expression", "text": "mask ^ ~-mask", "parent": 432, "children": [434, 435, 436], "start_point": {"row": 94, "column": 21}, "end_point": {"row": 94, "column": 34}}, {"id": 434, "type": "identifier", "text": "mask", "parent": 433, "children": [], "start_point": {"row": 94, "column": 21}, "end_point": {"row": 94, "column": 25}}, {"id": 435, "type": "^", "text": "^", "parent": 433, "children": [], "start_point": {"row": 94, "column": 26}, "end_point": {"row": 94, "column": 27}}, {"id": 436, "type": "unary_expression", "text": "~-mask", "parent": 433, "children": [437, 438], "start_point": {"row": 94, "column": 28}, "end_point": {"row": 94, "column": 34}}, {"id": 437, "type": "~", "text": "~", "parent": 436, "children": [], "start_point": {"row": 94, "column": 28}, "end_point": {"row": 94, "column": 29}}, {"id": 438, "type": "unary_expression", "text": "-mask", "parent": 436, "children": [439, 440], "start_point": {"row": 94, "column": 29}, "end_point": {"row": 94, "column": 34}}, {"id": 439, "type": "-", "text": "-", "parent": 438, "children": [], "start_point": {"row": 94, "column": 29}, "end_point": {"row": 94, "column": 30}}, {"id": 440, "type": "identifier", "text": "mask", "parent": 438, "children": [], "start_point": {"row": 94, "column": 30}, "end_point": {"row": 94, "column": 34}}, {"id": 441, "type": ">>", "text": ">>", "parent": 431, "children": [], "start_point": {"row": 94, "column": 36}, "end_point": {"row": 94, "column": 38}}, {"id": 442, "type": "number_literal", "text": "1", "parent": 431, "children": [], "start_point": {"row": 94, "column": 39}, "end_point": {"row": 94, "column": 40}}, {"id": 443, "type": "return_statement", "text": "return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT;", "parent": 415, "children": [444], "start_point": {"row": 95, "column": 12}, "end_point": {"row": 95, "column": 67}}, {"id": 444, "type": "binary_expression", "text": "((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT", "parent": 443, "children": [445, 457, 458], "start_point": {"row": 95, "column": 19}, "end_point": {"row": 95, "column": 66}}, {"id": 445, "type": "parenthesized_expression", "text": "((paddr & ~mask) | (virt & mask))", "parent": 444, "children": [446], "start_point": {"row": 95, "column": 19}, "end_point": {"row": 95, "column": 52}}, {"id": 446, "type": "binary_expression", "text": "(paddr & ~mask) | (virt & mask)", "parent": 445, "children": [447, 453], "start_point": {"row": 95, "column": 20}, "end_point": {"row": 95, "column": 51}}, {"id": 447, "type": "parenthesized_expression", "text": "(paddr & ~mask)", "parent": 446, "children": [448], "start_point": {"row": 95, "column": 20}, "end_point": {"row": 95, "column": 35}}, {"id": 448, "type": "binary_expression", "text": "paddr & ~mask", "parent": 447, "children": [449, 450], "start_point": {"row": 95, "column": 21}, "end_point": {"row": 95, "column": 34}}, {"id": 449, "type": "identifier", "text": "paddr", "parent": 448, "children": [], "start_point": {"row": 95, "column": 21}, "end_point": {"row": 95, "column": 26}}, {"id": 450, "type": "unary_expression", "text": "~mask", "parent": 448, "children": [451, 452], "start_point": {"row": 95, "column": 29}, "end_point": {"row": 95, "column": 34}}, {"id": 451, "type": "~", "text": "~", "parent": 450, "children": [], "start_point": {"row": 95, "column": 29}, "end_point": {"row": 95, "column": 30}}, {"id": 452, "type": "identifier", "text": "mask", "parent": 450, "children": [], "start_point": {"row": 95, "column": 30}, "end_point": {"row": 95, "column": 34}}, {"id": 453, "type": "parenthesized_expression", "text": "(virt & mask)", "parent": 446, "children": [454], "start_point": {"row": 95, "column": 38}, "end_point": {"row": 95, "column": 51}}, {"id": 454, "type": "binary_expression", "text": "virt & mask", "parent": 453, "children": [455, 456], "start_point": {"row": 95, "column": 39}, "end_point": {"row": 95, "column": 50}}, {"id": 455, "type": "identifier", "text": "virt", "parent": 454, "children": [], "start_point": {"row": 95, "column": 39}, "end_point": {"row": 95, "column": 43}}, {"id": 456, "type": "identifier", "text": "mask", "parent": 454, "children": [], "start_point": {"row": 95, "column": 46}, "end_point": {"row": 95, "column": 50}}, {"id": 457, "type": ">>", "text": ">>", "parent": 444, "children": [], "start_point": {"row": 95, "column": 53}, "end_point": {"row": 95, "column": 55}}, {"id": 458, "type": "identifier", "text": "PAGE_SHIFT", "parent": 444, "children": [], "start_point": {"row": 95, "column": 56}, "end_point": {"row": 95, "column": 66}}, {"id": 459, "type": "assignment_expression", "text": "mask >>= (pt_levels == 2 ? 10 : 9)", "parent": 323, "children": [460, 461, 462], "start_point": {"row": 97, "column": 8}, "end_point": {"row": 97, "column": 42}}, {"id": 460, "type": "identifier", "text": "mask", "parent": 459, "children": [], "start_point": {"row": 97, "column": 8}, "end_point": {"row": 97, "column": 12}}, {"id": 461, "type": ">>=", "text": ">>=", "parent": 459, "children": [], "start_point": {"row": 97, "column": 13}, "end_point": {"row": 97, "column": 16}}, {"id": 462, "type": "parenthesized_expression", "text": "(pt_levels == 2 ? 10 : 9)", "parent": 459, "children": [463], "start_point": {"row": 97, "column": 17}, "end_point": {"row": 97, "column": 42}}, {"id": 463, "type": "conditional_expression", "text": "pt_levels == 2 ? 10 : 9", "parent": 462, "children": [464, 468, 469, 470], "start_point": {"row": 97, "column": 18}, "end_point": {"row": 97, "column": 41}}, {"id": 464, "type": "binary_expression", "text": "pt_levels == 2", "parent": 463, "children": [465, 466, 467], "start_point": {"row": 97, "column": 18}, "end_point": {"row": 97, "column": 32}}, {"id": 465, "type": "identifier", "text": "pt_levels", "parent": 464, "children": [], "start_point": {"row": 97, "column": 18}, "end_point": {"row": 97, "column": 27}}, {"id": 466, "type": "==", "text": "==", "parent": 464, "children": [], "start_point": {"row": 97, "column": 28}, "end_point": {"row": 97, "column": 30}}, {"id": 467, "type": "number_literal", "text": "2", "parent": 464, "children": [], "start_point": {"row": 97, "column": 31}, "end_point": {"row": 97, "column": 32}}, {"id": 468, "type": "?", "text": "?", "parent": 463, "children": [], "start_point": {"row": 97, "column": 33}, "end_point": {"row": 97, "column": 34}}, {"id": 469, "type": "number_literal", "text": "10", "parent": 463, "children": [], "start_point": {"row": 97, "column": 35}, "end_point": {"row": 97, "column": 37}}, {"id": 470, "type": "number_literal", "text": "9", "parent": 463, "children": [], "start_point": {"row": 97, "column": 40}, "end_point": {"row": 97, "column": 41}}, {"id": 471, "type": "return_statement", "text": "return paddr >> PAGE_SHIFT;", "parent": 22, "children": [472], "start_point": {"row": 99, "column": 4}, "end_point": {"row": 99, "column": 31}}, {"id": 472, "type": "binary_expression", "text": "paddr >> PAGE_SHIFT", "parent": 471, "children": [473, 474, 475], "start_point": {"row": 99, "column": 11}, "end_point": {"row": 99, "column": 30}}, {"id": 473, "type": "identifier", "text": "paddr", "parent": 472, "children": [], "start_point": {"row": 99, "column": 11}, "end_point": {"row": 99, "column": 16}}, {"id": 474, "type": ">>", "text": ">>", "parent": 472, "children": [], "start_point": {"row": 99, "column": 17}, "end_point": {"row": 99, "column": 19}}, {"id": 475, "type": "identifier", "text": "PAGE_SHIFT", "parent": 472, "children": [], "start_point": {"row": 99, "column": 20}, "end_point": {"row": 99, "column": 30}}]}, "node_categories": {"declarations": {"functions": [22, 26], "variables": [29, 34, 37, 40, 46, 49, 57, 65, 98, 183, 188], "classes": [99, 100], "imports": [0, 1, 3, 4], "modules": [], "enums": []}, "statements": {"expressions": [71, 72, 73, 74, 80, 85, 86, 94, 95, 104, 105, 106, 111, 116, 118, 125, 126, 128, 129, 130, 135, 143, 144, 145, 152, 153, 154, 164, 165, 168, 170, 171, 176, 179, 192, 193, 194, 200, 207, 208, 209, 214, 221, 222, 233, 234, 237, 240, 241, 242, 257, 258, 261, 264, 265, 266, 274, 275, 289, 290, 314, 316, 328, 332, 338, 339, 340, 341, 342, 346, 347, 348, 359, 366, 371, 372, 377, 380, 382, 385, 386, 388, 389, 394, 400, 401, 403, 404, 412, 416, 417, 418, 423, 424, 430, 431, 432, 433, 436, 438, 444, 445, 446, 447, 448, 450, 453, 454, 462, 464, 472], "assignments": [139, 161, 226, 230, 250, 254, 279, 283, 294, 298, 303, 307, 311, 324, 335, 356, 409, 427, 459], "loops": [323], "conditionals": [8, 12, 16, 20, 23, 27, 30, 33, 36, 39, 41, 45, 47, 48, 51, 52, 54, 59, 60, 62, 69, 70, 75, 77, 78, 81, 87, 88, 90, 93, 96, 97, 101, 102, 103, 107, 109, 110, 112, 114, 115, 117, 119, 124, 131, 132, 133, 136, 138, 140, 142, 146, 147, 148, 151, 155, 156, 157, 162, 166, 167, 169, 172, 184, 187, 189, 190, 191, 195, 197, 198, 199, 201, 206, 210, 212, 213, 215, 220, 223, 227, 231, 238, 243, 244, 245, 248, 251, 255, 262, 267, 268, 269, 272, 273, 276, 280, 284, 288, 291, 295, 299, 304, 308, 312, 315, 317, 325, 327, 329, 333, 336, 343, 344, 349, 351, 355, 357, 360, 362, 363, 364, 365, 367, 369, 370, 374, 378, 381, 383, 387, 390, 393, 395, 397, 398, 399, 405, 410, 413, 415, 419, 425, 426, 428, 434, 440, 449, 452, 455, 456, 458, 460, 463, 465, 473, 475], "returns": [91, 122, 134, 204, 218, 375, 407, 443, 471], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 56, 64, 79, 83, 92, 121, 123, 150, 159, 160, 174, 178, 181, 203, 205, 217, 219, 225, 229, 246, 253, 270, 278, 282, 286, 293, 297, 301, 306, 310, 319, 321, 322, 331, 353, 376, 392, 406, 408, 414, 421, 442, 467, 469, 470], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 22, "universal_type": "function", "name": "vcpu,", "text_snippet": "unsigned long xc_translate_foreign_address(xc_interface *xch, uint32_t dom,\n "}, {"node_id": 26, "universal_type": "function", "name": "vcpu,", "text_snippet": "xc_translate_foreign_address(xc_interface *xch, uint32_t dom,\n "}], "class_declarations": [{"node_id": 99, "universal_type": "class", "name": "hvm_hw_cpu", "text_snippet": "struct hvm_hw_cpu"}, {"node_id": 100, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": [{"node_id": 0, "text": "#include \"xc_private.h\"\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <xen/hvm/save.h>\n"}, {"node_id": 4, "text": "#include"}]}, "original_source_code": "/******************************************************************************\n * xc_pagetab.c\n *\n * Function to translate virtual to physical addresses.\n *\n * This library is free software; you can redistribute it and/or\n * modify it under the terms of the GNU Lesser General Public\n * License as published by the Free Software Foundation;\n * version 2.1 of the License.\n *\n * This library is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n * Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public\n * License along with this library; If not, see <http://www.gnu.org/licenses/>.\n */\n\n#include \"xc_private.h\"\n#include <xen/hvm/save.h>\n\n#define CR0_PG 0x80000000\n#define CR4_PAE 0x20\n#define PTE_PSE 0x80\n#define EFER_LMA 0x400\n\n\nunsigned long xc_translate_foreign_address(xc_interface *xch, uint32_t dom,\n int vcpu, unsigned long long virt)\n{\n xc_dominfo_t dominfo;\n uint64_t paddr, mask, pte = 0;\n int size, level, pt_levels = 2;\n void *map;\n\n if (xc_domain_getinfo(xch, dom, 1, &dominfo) != 1 \n || dominfo.domid != dom)\n return 0;\n\n /* What kind of paging are we dealing with? */\n if (dominfo.hvm) {\n struct hvm_hw_cpu ctx;\n if (xc_domain_hvm_getcontext_partial(xch, dom,\n HVM_SAVE_CODE(CPU), vcpu,\n &ctx, sizeof ctx) != 0)\n return 0;\n if (!(ctx.cr0 & CR0_PG))\n return virt >> PAGE_SHIFT;\n pt_levels = (ctx.msr_efer&EFER_LMA) ? 4 : (ctx.cr4&CR4_PAE) ? 3 : 2;\n paddr = ctx.cr3 & ((pt_levels == 3) ? ~0x1full : ~0xfffull);\n } else {\n unsigned int gwidth;\n vcpu_guest_context_any_t ctx;\n if (xc_vcpu_getcontext(xch, dom, vcpu, &ctx) != 0)\n return 0;\n if (xc_domain_get_guest_width(xch, dom, &gwidth) != 0)\n return 0;\n if (gwidth == 8) {\n pt_levels = 4;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_64(ctx.x64.ctrlreg[3])\n << PAGE_SHIFT;\n } else {\n pt_levels = 3;\n paddr = (uint64_t)xen_cr3_to_pfn_x86_32(ctx.x32.ctrlreg[3])\n << PAGE_SHIFT;\n }\n }\n\n if (pt_levels == 4) {\n virt &= 0x0000ffffffffffffull;\n mask = 0x0000ff8000000000ull;\n } else if (pt_levels == 3) {\n virt &= 0x00000000ffffffffull;\n mask = 0x0000007fc0000000ull;\n } else {\n virt &= 0x00000000ffffffffull;\n mask = 0x00000000ffc00000ull;\n }\n size = (pt_levels == 2 ? 4 : 8);\n\n /* Walk the pagetables */\n for (level = pt_levels; level > 0; level--) {\n paddr += ((virt & mask) >> (xc_ffs64(mask) - 1)) * size;\n map = xc_map_foreign_range(xch, dom, PAGE_SIZE, PROT_READ, \n paddr >>PAGE_SHIFT);\n if (!map) \n return 0;\n memcpy(&pte, map + (paddr & (PAGE_SIZE - 1)), size);\n munmap(map, PAGE_SIZE);\n if (!(pte & 1)) \n return 0;\n paddr = pte & 0x000ffffffffff000ull;\n if (level == 2 && (pte & PTE_PSE)) {\n mask = ((mask ^ ~-mask) >> 1); /* All bits below first set bit */\n return ((paddr & ~mask) | (virt & mask)) >> PAGE_SHIFT;\n }\n mask >>= (pt_levels == 2 ? 10 : 9);\n }\n return paddr >> PAGE_SHIFT;\n}\n\n/*\n * Local variables:\n * mode: C\n * c-file-style: \"BSD\"\n * c-basic-offset: 4\n * tab-width: 4\n * indent-tabs-mode: nil\n * End:\n */\n"}
80,564
c
// Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT License. See License in the project root for license information. @class MSGraphGroupConversationsCollectionRequest, MSGraphConversationRequestBuilder; #import "MSGraphModels.h" #import "MSCollectionRequestBuilder.h" @interface MSGraphGroupConversationsCollectionRequestBuilder : MSCollectionRequestBuilder - (MSGraphGroupConversationsCollectionRequest *)request; - (MSGraphGroupConversationsCollectionRequest *)requestWithOptions:(NSArray *)options; - (MSGraphConversationRequestBuilder *)conversation:(NSString *)conversation; @end
30.1
21
(translation_unit) "// Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT License. See License in the project root for license information. \n \n \n@class MSGraphGroupConversationsCollectionRequest, MSGraphConversationRequestBuilder; \n \n#import "MSGraphModels.h" \n#import "MSCollectionRequestBuilder.h" \n \n \n \n \n@interface MSGraphGroupConversationsCollectionRequestBuilder : MSCollectionRequestBuilder \n \n- (MSGraphGroupConversationsCollectionRequest *)request; \n \n- (MSGraphGroupConversationsCollectionRequest *)requestWithOptions:(NSArray *)options; \n \n- (MSGraphConversationRequestBuilder *)conversation:(NSString *)conversation; \n \n \n@end \n" (comment) "// Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT License. See License in the project root for license information. " (ERROR) "@" (ERROR) "@" (declaration) "class MSGraphGroupConversationsCollectionRequest, MSGraphConversationRequestBuilder;" (type_identifier) "class" (identifier) "MSGraphGroupConversationsCollectionRequest" (,) "," (identifier) "MSGraphConversationRequestBuilder" (;) ";" (preproc_call) "#import "MSGraphModels.h" \n" (preproc_directive) "#import" (preproc_arg) ""MSGraphModels.h" " (preproc_call) "#import "MSCollectionRequestBuilder.h" \n" (preproc_directive) "#import" (preproc_arg) ""MSCollectionRequestBuilder.h" " (ERROR) "@interface MSGraphGroupConversationsCollectionRequestBuilder : MSCollectionRequestBuilder" (ERROR) "@" (type_identifier) "interface" (identifier) "MSGraphGroupConversationsCollectionRequestBuilder" (:) ":" (identifier) "MSCollectionRequestBuilder" (expression_statement) "- (MSGraphGroupConversationsCollectionRequest *)request;" (unary_expression) "- (MSGraphGroupConversationsCollectionRequest *)request" (-) "-" (cast_expression) "(MSGraphGroupConversationsCollectionRequest *)request" (() "(" (type_descriptor) "MSGraphGroupConversationsCollectionRequest *" (type_identifier) "MSGraphGroupConversationsCollectionRequest" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "request" (;) ";" (ERROR) "- (MSGraphGroupConversationsCollectionRequest *)requestWithOptions:(NSArray *)options; \n \n- (MSGraphConversationRequestBuilder *)conversation:(NSString *)conversation; \n \n \n@end" (binary_expression) "- (MSGraphGroupConversationsCollectionRequest *)requestWithOptions:(NSArray *)options; \n \n- (MSGraphConversationRequestBuilder *)conversation:(NSString *)conversation" (binary_expression) "- (MSGraphGroupConversationsCollectionRequest *)requestWithOptions:(NSArray *)options; \n \n- (MSGraphConversationRequestBuilder *)conversation" (binary_expression) "- (MSGraphGroupConversationsCollectionRequest *)requestWithOptions:(NSArray *)options" (unary_expression) "- (MSGraphGroupConversationsCollectionRequest *)requestWithOptions" (-) "-" (cast_expression) "(MSGraphGroupConversationsCollectionRequest *)requestWithOptions" (() "(" (type_descriptor) "MSGraphGroupConversationsCollectionRequest *" (type_identifier) "MSGraphGroupConversationsCollectionRequest" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "requestWithOptions" (ERROR) ":(NSArray" (:) ":" (() "(" (identifier) "NSArray" (*) "*" (ERROR) ")" ()) ")" (identifier) "options" (ERROR) ";" (;) ";" (-) "-" (cast_expression) "(MSGraphConversationRequestBuilder *)conversation" (() "(" (type_descriptor) "MSGraphConversationRequestBuilder *" (type_identifier) "MSGraphConversationRequestBuilder" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "conversation" (ERROR) ":(NSString" (:) ":" (() "(" (identifier) "NSString" (*) "*" (ERROR) ")" ()) ")" (identifier) "conversation" (;) ";" (ERROR) "@" (identifier) "end"
78
11
{"language": "c", "success": true, "metadata": {"lines": 21, "avg_line_length": 30.1, "nodes": 52, "errors": 0, "source_hash": "d8bca103d7dbcf0eb2d26e37aad6961e689d1569c1d11c246547e302bd7310e1", "categorized_nodes": 26}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "ERROR", "text": "@", "parent": null, "children": [1], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 1}}, {"id": 1, "type": "ERROR", "text": "@", "parent": 0, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 1}}, {"id": 2, "type": "declaration", "text": "class MSGraphGroupConversationsCollectionRequest, MSGraphConversationRequestBuilder;", "parent": null, "children": [3, 4], "start_point": {"row": 3, "column": 1}, "end_point": {"row": 3, "column": 85}}, {"id": 3, "type": "identifier", "text": "MSGraphGroupConversationsCollectionRequest", "parent": 2, "children": [], "start_point": {"row": 3, "column": 7}, "end_point": {"row": 3, "column": 49}}, {"id": 4, "type": "identifier", "text": "MSGraphConversationRequestBuilder", "parent": 2, "children": [], "start_point": {"row": 3, "column": 51}, "end_point": {"row": 3, "column": 84}}, {"id": 5, "type": "preproc_call", "text": "#import \"MSGraphModels.h\"\r\n", "parent": null, "children": [6, 7], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 6, "type": "preproc_directive", "text": "#import", "parent": 5, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 7}}, {"id": 7, "type": "preproc_arg", "text": "\"MSGraphModels.h\"\r", "parent": 5, "children": [], "start_point": {"row": 5, "column": 8}, "end_point": {"row": 5, "column": 26}}, {"id": 8, "type": "preproc_call", "text": "#import \"MSCollectionRequestBuilder.h\"\r\n", "parent": null, "children": [9, 10], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 9, "type": "preproc_directive", "text": "#import", "parent": 8, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 7}}, {"id": 10, "type": "preproc_arg", "text": "\"MSCollectionRequestBuilder.h\"\r", "parent": 8, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 39}}, {"id": 11, "type": "ERROR", "text": "@interface MSGraphGroupConversationsCollectionRequestBuilder : MSCollectionRequestBuilder", "parent": null, "children": [12, 13, 14, 15], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 89}}, {"id": 12, "type": "ERROR", "text": "@", "parent": 11, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 1}}, {"id": 13, "type": "type_identifier", "text": "interface", "parent": 11, "children": [], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 11, "column": 10}}, {"id": 14, "type": "identifier", "text": "MSGraphGroupConversationsCollectionRequestBuilder", "parent": 11, "children": [], "start_point": {"row": 11, "column": 11}, "end_point": {"row": 11, "column": 60}}, {"id": 15, "type": "identifier", "text": "MSCollectionRequestBuilder", "parent": 11, "children": [], "start_point": {"row": 11, "column": 63}, "end_point": {"row": 11, "column": 89}}, {"id": 16, "type": "unary_expression", "text": "- (MSGraphGroupConversationsCollectionRequest *)request", "parent": null, "children": [17, 18], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 55}}, {"id": 17, "type": "-", "text": "-", "parent": 16, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 18, "type": "cast_expression", "text": "(MSGraphGroupConversationsCollectionRequest *)request", "parent": 16, "children": [19, 23], "start_point": {"row": 13, "column": 2}, "end_point": {"row": 13, "column": 55}}, {"id": 19, "type": "type_descriptor", "text": "MSGraphGroupConversationsCollectionRequest *", "parent": 18, "children": [20, 21], "start_point": {"row": 13, "column": 3}, "end_point": {"row": 13, "column": 47}}, {"id": 20, "type": "type_identifier", "text": "MSGraphGroupConversationsCollectionRequest", "parent": 19, "children": [], "start_point": {"row": 13, "column": 3}, "end_point": {"row": 13, "column": 45}}, {"id": 21, "type": "abstract_pointer_declarator", "text": "*", "parent": 19, "children": [22], "start_point": {"row": 13, "column": 46}, "end_point": {"row": 13, "column": 47}}, {"id": 22, "type": "*", "text": "*", "parent": 21, "children": [], "start_point": {"row": 13, "column": 46}, "end_point": {"row": 13, "column": 47}}, {"id": 23, "type": "identifier", "text": "request", "parent": 18, "children": [], "start_point": {"row": 13, "column": 48}, "end_point": {"row": 13, "column": 55}}, {"id": 24, "type": "ERROR", "text": "- (MSGraphGroupConversationsCollectionRequest *)requestWithOptions:(NSArray *)options;\r\n\r\n- (MSGraphConversationRequestBuilder *)conversation:(NSString *)conversation;\r\n\r\n\r\n@end", "parent": null, "children": [25, 51], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 20, "column": 4}}, {"id": 25, "type": "binary_expression", "text": "- (MSGraphGroupConversationsCollectionRequest *)requestWithOptions:(NSArray *)options;\r\n\r\n- (MSGraphConversationRequestBuilder *)conversation:(NSString *)conversation", "parent": 24, "children": [26, 47, 49, 50], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 17, "column": 76}}, {"id": 26, "type": "binary_expression", "text": "- (MSGraphGroupConversationsCollectionRequest *)requestWithOptions:(NSArray *)options;\r\n\r\n- (MSGraphConversationRequestBuilder *)conversation", "parent": 25, "children": [27, 40, 41], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 17, "column": 51}}, {"id": 27, "type": "binary_expression", "text": "- (MSGraphGroupConversationsCollectionRequest *)requestWithOptions:(NSArray *)options", "parent": 26, "children": [28, 36, 38, 39], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 85}}, {"id": 28, "type": "unary_expression", "text": "- (MSGraphGroupConversationsCollectionRequest *)requestWithOptions", "parent": 27, "children": [29, 30], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 66}}, {"id": 29, "type": "-", "text": "-", "parent": 28, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 1}}, {"id": 30, "type": "cast_expression", "text": "(MSGraphGroupConversationsCollectionRequest *)requestWithOptions", "parent": 28, "children": [31, 35], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 66}}, {"id": 31, "type": "type_descriptor", "text": "MSGraphGroupConversationsCollectionRequest *", "parent": 30, "children": [32, 33], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 47}}, {"id": 32, "type": "type_identifier", "text": "MSGraphGroupConversationsCollectionRequest", "parent": 31, "children": [], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 45}}, {"id": 33, "type": "abstract_pointer_declarator", "text": "*", "parent": 31, "children": [34], "start_point": {"row": 15, "column": 46}, "end_point": {"row": 15, "column": 47}}, {"id": 34, "type": "*", "text": "*", "parent": 33, "children": [], "start_point": {"row": 15, "column": 46}, "end_point": {"row": 15, "column": 47}}, {"id": 35, "type": "identifier", "text": "requestWithOptions", "parent": 30, "children": [], "start_point": {"row": 15, "column": 48}, "end_point": {"row": 15, "column": 66}}, {"id": 36, "type": "ERROR", "text": ":(NSArray", "parent": 27, "children": [37], "start_point": {"row": 15, "column": 66}, "end_point": {"row": 15, "column": 75}}, {"id": 37, "type": "identifier", "text": "NSArray", "parent": 36, "children": [], "start_point": {"row": 15, "column": 68}, "end_point": {"row": 15, "column": 75}}, {"id": 38, "type": "*", "text": "*", "parent": 27, "children": [], "start_point": {"row": 15, "column": 76}, "end_point": {"row": 15, "column": 77}}, {"id": 39, "type": "identifier", "text": "options", "parent": 27, "children": [], "start_point": {"row": 15, "column": 78}, "end_point": {"row": 15, "column": 85}}, {"id": 40, "type": "-", "text": "-", "parent": 26, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 41, "type": "cast_expression", "text": "(MSGraphConversationRequestBuilder *)conversation", "parent": 26, "children": [42, 46], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 17, "column": 51}}, {"id": 42, "type": "type_descriptor", "text": "MSGraphConversationRequestBuilder *", "parent": 41, "children": [43, 44], "start_point": {"row": 17, "column": 3}, "end_point": {"row": 17, "column": 38}}, {"id": 43, "type": "type_identifier", "text": "MSGraphConversationRequestBuilder", "parent": 42, "children": [], "start_point": {"row": 17, "column": 3}, "end_point": {"row": 17, "column": 36}}, {"id": 44, "type": "abstract_pointer_declarator", "text": "*", "parent": 42, "children": [45], "start_point": {"row": 17, "column": 37}, "end_point": {"row": 17, "column": 38}}, {"id": 45, "type": "*", "text": "*", "parent": 44, "children": [], "start_point": {"row": 17, "column": 37}, "end_point": {"row": 17, "column": 38}}, {"id": 46, "type": "identifier", "text": "conversation", "parent": 41, "children": [], "start_point": {"row": 17, "column": 39}, "end_point": {"row": 17, "column": 51}}, {"id": 47, "type": "ERROR", "text": ":(NSString", "parent": 25, "children": [48], "start_point": {"row": 17, "column": 51}, "end_point": {"row": 17, "column": 61}}, {"id": 48, "type": "identifier", "text": "NSString", "parent": 47, "children": [], "start_point": {"row": 17, "column": 53}, "end_point": {"row": 17, "column": 61}}, {"id": 49, "type": "*", "text": "*", "parent": 25, "children": [], "start_point": {"row": 17, "column": 62}, "end_point": {"row": 17, "column": 63}}, {"id": 50, "type": "identifier", "text": "conversation", "parent": 25, "children": [], "start_point": {"row": 17, "column": 64}, "end_point": {"row": 17, "column": 76}}, {"id": 51, "type": "ERROR", "text": "@", "parent": 24, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 1}}]}, "node_categories": {"declarations": {"functions": [], "variables": [2], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [16, 18, 25, 26, 27, 28, 30, 41], "assignments": [], "loops": [], "conditionals": [3, 4, 13, 14, 15, 20, 23, 32, 35, 37, 39, 43, 46, 48, 50], "returns": [], "exceptions": []}, "expressions": {"calls": [5, 8], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [], "class_declarations": [], "import_statements": []}, "original_source_code": "// Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT License. See License in the project root for license information.\r\n\r\n\r\n@class MSGraphGroupConversationsCollectionRequest, MSGraphConversationRequestBuilder;\r\n\r\n#import \"MSGraphModels.h\"\r\n#import \"MSCollectionRequestBuilder.h\"\r\n\r\n\r\n\r\n\r\n@interface MSGraphGroupConversationsCollectionRequestBuilder : MSCollectionRequestBuilder\r\n\r\n- (MSGraphGroupConversationsCollectionRequest *)request;\r\n\r\n- (MSGraphGroupConversationsCollectionRequest *)requestWithOptions:(NSArray *)options;\r\n\r\n- (MSGraphConversationRequestBuilder *)conversation:(NSString *)conversation;\r\n\r\n\r\n@end\r\n"}
80,565
c
#include <stdio.h> int main () { int a,b,c; scanf("%d.%d.%d",&a,&b,&c); printf("%02d-%02d-%04d",c,b,a); return 0; }
14
8
(translation_unit) "#include <stdio.h>\nint main ()\n{\n int a,b,c;\n scanf("%d.%d.%d",&a,&b,&c);\n printf("%02d-%02d-%04d",c,b,a);\n return 0;\n}\n" (preproc_include) "#include <stdio.h>\n" (#include) "#include" (system_lib_string) "<stdio.h>" (function_definition) "int main ()\n{\n int a,b,c;\n scanf("%d.%d.%d",&a,&b,&c);\n printf("%02d-%02d-%04d",c,b,a);\n return 0;\n}" (primitive_type) "int" (function_declarator) "main ()" (identifier) "main" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n int a,b,c;\n scanf("%d.%d.%d",&a,&b,&c);\n printf("%02d-%02d-%04d",c,b,a);\n return 0;\n}" ({) "{" (declaration) "int a,b,c;" (primitive_type) "int" (identifier) "a" (,) "," (identifier) "b" (,) "," (identifier) "c" (;) ";" (expression_statement) "scanf("%d.%d.%d",&a,&b,&c);" (call_expression) "scanf("%d.%d.%d",&a,&b,&c)" (identifier) "scanf" (argument_list) "("%d.%d.%d",&a,&b,&c)" (() "(" (string_literal) ""%d.%d.%d"" (") """ (string_content) "%d.%d.%d" (") """ (,) "," (pointer_expression) "&a" (&) "&" (identifier) "a" (,) "," (pointer_expression) "&b" (&) "&" (identifier) "b" (,) "," (pointer_expression) "&c" (&) "&" (identifier) "c" ()) ")" (;) ";" (expression_statement) "printf("%02d-%02d-%04d",c,b,a);" (call_expression) "printf("%02d-%02d-%04d",c,b,a)" (identifier) "printf" (argument_list) "("%02d-%02d-%04d",c,b,a)" (() "(" (string_literal) ""%02d-%02d-%04d"" (") """ (string_content) "%02d-%02d-%04d" (") """ (,) "," (identifier) "c" (,) "," (identifier) "b" (,) "," (identifier) "a" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}"
66
0
{"language": "c", "success": true, "metadata": {"lines": 8, "avg_line_length": 14.0, "nodes": 32, "errors": 0, "source_hash": "58e5a081a8e33d2dff89fbbba7a92a678e02fa27ee015f35dba4a943f6cf8faa", "categorized_nodes": 27}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <stdio.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<stdio.h>", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 18}}, {"id": 3, "type": "function_definition", "text": "int main ()\n{\n\tint a,b,c;\n\tscanf(\"%d.%d.%d\",&a,&b,&c);\n\tprintf(\"%02d-%02d-%04d\",c,b,a);\n\treturn 0;\n}", "parent": null, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 7, "column": 1}}, {"id": 4, "type": "primitive_type", "text": "int", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 3}}, {"id": 5, "type": "function_declarator", "text": "main ()", "parent": 3, "children": [6, 7], "start_point": {"row": 1, "column": 4}, "end_point": {"row": 1, "column": 11}}, {"id": 6, "type": "identifier", "text": "main", "parent": 5, "children": [], "start_point": {"row": 1, "column": 4}, "end_point": {"row": 1, "column": 8}}, {"id": 7, "type": "parameter_list", "text": "()", "parent": 5, "children": [], "start_point": {"row": 1, "column": 9}, "end_point": {"row": 1, "column": 11}}, {"id": 8, "type": "declaration", "text": "int a,b,c;", "parent": 3, "children": [9, 10, 11, 12], "start_point": {"row": 3, "column": 1}, "end_point": {"row": 3, "column": 11}}, {"id": 9, "type": "primitive_type", "text": "int", "parent": 8, "children": [], "start_point": {"row": 3, "column": 1}, "end_point": {"row": 3, "column": 4}}, {"id": 10, "type": "identifier", "text": "a", "parent": 8, "children": [], "start_point": {"row": 3, "column": 5}, "end_point": {"row": 3, "column": 6}}, {"id": 11, "type": "identifier", "text": "b", "parent": 8, "children": [], "start_point": {"row": 3, "column": 7}, "end_point": {"row": 3, "column": 8}}, {"id": 12, "type": "identifier", "text": "c", "parent": 8, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 10}}, {"id": 13, "type": "call_expression", "text": "scanf(\"%d.%d.%d\",&a,&b,&c)", "parent": 3, "children": [14, 15], "start_point": {"row": 4, "column": 1}, "end_point": {"row": 4, "column": 27}}, {"id": 14, "type": "identifier", "text": "scanf", "parent": 13, "children": [], "start_point": {"row": 4, "column": 1}, "end_point": {"row": 4, "column": 6}}, {"id": 15, "type": "argument_list", "text": "(\"%d.%d.%d\",&a,&b,&c)", "parent": 13, "children": [16, 17, 19, 21], "start_point": {"row": 4, "column": 6}, "end_point": {"row": 4, "column": 27}}, {"id": 16, "type": "string_literal", "text": "\"%d.%d.%d\"", "parent": 15, "children": [], "start_point": {"row": 4, "column": 7}, "end_point": {"row": 4, "column": 17}}, {"id": 17, "type": "pointer_expression", "text": "&a", "parent": 15, "children": [18], "start_point": {"row": 4, "column": 18}, "end_point": {"row": 4, "column": 20}}, {"id": 18, "type": "identifier", "text": "a", "parent": 17, "children": [], "start_point": {"row": 4, "column": 19}, "end_point": {"row": 4, "column": 20}}, {"id": 19, "type": "pointer_expression", "text": "&b", "parent": 15, "children": [20], "start_point": {"row": 4, "column": 21}, "end_point": {"row": 4, "column": 23}}, {"id": 20, "type": "identifier", "text": "b", "parent": 19, "children": [], "start_point": {"row": 4, "column": 22}, "end_point": {"row": 4, "column": 23}}, {"id": 21, "type": "pointer_expression", "text": "&c", "parent": 15, "children": [22], "start_point": {"row": 4, "column": 24}, "end_point": {"row": 4, "column": 26}}, {"id": 22, "type": "identifier", "text": "c", "parent": 21, "children": [], "start_point": {"row": 4, "column": 25}, "end_point": {"row": 4, "column": 26}}, {"id": 23, "type": "call_expression", "text": "printf(\"%02d-%02d-%04d\",c,b,a)", "parent": 3, "children": [24, 25], "start_point": {"row": 5, "column": 1}, "end_point": {"row": 5, "column": 31}}, {"id": 24, "type": "identifier", "text": "printf", "parent": 23, "children": [], "start_point": {"row": 5, "column": 1}, "end_point": {"row": 5, "column": 7}}, {"id": 25, "type": "argument_list", "text": "(\"%02d-%02d-%04d\",c,b,a)", "parent": 23, "children": [26, 27, 28, 29], "start_point": {"row": 5, "column": 7}, "end_point": {"row": 5, "column": 31}}, {"id": 26, "type": "string_literal", "text": "\"%02d-%02d-%04d\"", "parent": 25, "children": [], "start_point": {"row": 5, "column": 8}, "end_point": {"row": 5, "column": 24}}, {"id": 27, "type": "identifier", "text": "c", "parent": 25, "children": [], "start_point": {"row": 5, "column": 25}, "end_point": {"row": 5, "column": 26}}, {"id": 28, "type": "identifier", "text": "b", "parent": 25, "children": [], "start_point": {"row": 5, "column": 27}, "end_point": {"row": 5, "column": 28}}, {"id": 29, "type": "identifier", "text": "a", "parent": 25, "children": [], "start_point": {"row": 5, "column": 29}, "end_point": {"row": 5, "column": 30}}, {"id": 30, "type": "return_statement", "text": "return 0;", "parent": 3, "children": [31], "start_point": {"row": 6, "column": 1}, "end_point": {"row": 6, "column": 10}}, {"id": 31, "type": "number_literal", "text": "0", "parent": 30, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 9}}]}, "node_categories": {"declarations": {"functions": [3, 5], "variables": [8], "classes": [], "imports": [0, 1], "modules": [], "enums": []}, "statements": {"expressions": [13, 17, 19, 21, 23], "assignments": [], "loops": [], "conditionals": [6, 10, 11, 12, 14, 18, 20, 22, 24, 27, 28, 29], "returns": [30], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 16, 26, 31], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 3, "universal_type": "function", "name": "main", "text_snippet": "int main ()\n{\n\tint a,b,c;\n\tscanf(\"%d.%d.%d\",&a,&b,&c);\n\tprintf(\"%02d-%02d-%04d\",c,b,a);\n\treturn 0;\n}"}, {"node_id": 5, "universal_type": "function", "name": "unknown", "text_snippet": "main ()"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <stdio.h>\n"}, {"node_id": 1, "text": "#include"}]}, "original_source_code": "#include <stdio.h>\nint main ()\n{\n\tint a,b,c;\n\tscanf(\"%d.%d.%d\",&a,&b,&c);\n\tprintf(\"%02d-%02d-%04d\",c,b,a);\n\treturn 0;\n}\n"}
80,566
c
// SDLAudioPassThruCapabilities.h // #import "SDLRPCMessage.h" @class SDLAudioType; @class SDLBitsPerSample; @class SDLSamplingRate; /** * Describes different audio type configurations for SDLPerformAudioPassThru, e.g. {8kHz,8-bit,PCM} * <p><b>Parameter List</b> * <table border="1" rules="all"> * <tr> * <th>Name</th> * <th>Type</th> * <th>Description</th> * <th>SmartDeviceLink Ver. Available</th> * </tr> * <tr> * <td>samplingRate</td> * <td>SDLSamplingRate * </td> * <td>Describes the sampling rate for AudioPassThru * </td> * <td>SmartDeviceLink 2.0</td> * </tr> * <tr> * <td>bitsPerSample</td> * <td>SDLBitsPerSample * </td> * <td>Describes the sample depth in bit for AudioPassThru * </td> * <td>SmartDeviceLink 2.0</td> * </tr> * <tr> * <td>audioType</td> * <td>SDLAudioType * </td> * <td>Describes the audiotype for AudioPassThru * </td> * <td>SmartDeviceLink 2.0</td> * </tr> * </table> * Since <b>SmartDeviceLink 2.0</b> */ @interface SDLAudioPassThruCapabilities : SDLRPCStruct { } /** * Constructs a newly allocated SDLAudioPassThruCapabilities object */ - (instancetype)init; /** * Constructs a newly allocated SDLAudioPassThruCapabilities object indicated by the Hashtable parameter * @param dict The dictionary to use */ - (instancetype)initWithDictionary:(NSMutableDictionary *)dict; /** * @abstract The sampling rate for AudioPassThru<br> * */ @property (strong) SDLSamplingRate *samplingRate; /** * @abstract The sample depth in bit for AudioPassThru<br> * */ @property (strong) SDLBitsPerSample *bitsPerSample; /** * @abstract The audiotype for AudioPassThru<br> * */ @property (strong) SDLAudioType *audioType; @end
24.88
68
(translation_unit) "// SDLAudioPassThruCapabilities.h\n//\n\n#import "SDLRPCMessage.h"\n\n@class SDLAudioType;\n@class SDLBitsPerSample;\n@class SDLSamplingRate;\n\n\n/**\n * Describes different audio type configurations for SDLPerformAudioPassThru, e.g. {8kHz,8-bit,PCM}\n * <p><b>Parameter List</b>\n * <table border="1" rules="all">\n * <tr>\n * <th>Name</th>\n * <th>Type</th>\n * <th>Description</th>\n * <th>SmartDeviceLink Ver. Available</th>\n * </tr>\n * <tr>\n * <td>samplingRate</td>\n * <td>SDLSamplingRate * </td>\n * <td>Describes the sampling rate for AudioPassThru\n * </td>\n * <td>SmartDeviceLink 2.0</td>\n * </tr>\n * <tr>\n * <td>bitsPerSample</td>\n * <td>SDLBitsPerSample * </td>\n * <td>Describes the sample depth in bit for AudioPassThru\n * </td>\n * <td>SmartDeviceLink 2.0</td>\n * </tr>\n * <tr>\n * <td>audioType</td>\n * <td>SDLAudioType * </td>\n * <td>Describes the audiotype for AudioPassThru\n * </td>\n * <td>SmartDeviceLink 2.0</td>\n * </tr>\n * </table>\n * Since <b>SmartDeviceLink 2.0</b>\n */\n@interface SDLAudioPassThruCapabilities : SDLRPCStruct {\n}\n\n/**\n * Constructs a newly allocated SDLAudioPassThruCapabilities object\n */\n- (instancetype)init;\n/**\n * Constructs a newly allocated SDLAudioPassThruCapabilities object indicated by the Hashtable parameter\n * @param dict The dictionary to use\n */\n- (instancetype)initWithDictionary:(NSMutableDictionary *)dict;\n\n/**\n * @abstract The sampling rate for AudioPassThru<br>\n *\n */\n@property (strong) SDLSamplingRate *samplingRate;\n/**\n * @abstract The sample depth in bit for AudioPassThru<br>\n *\n */\n@property (strong) SDLBitsPerSample *bitsPerSample;\n/**\n * @abstract The audiotype for AudioPassThru<br>\n *\n */\n@property (strong) SDLAudioType *audioType;\n\n@end\n" (comment) "// SDLAudioPassThruCapabilities.h" (comment) "//" (preproc_call) "#import "SDLRPCMessage.h"\n" (preproc_directive) "#import" (preproc_arg) ""SDLRPCMessage.h"" (ERROR) "@" (ERROR) "@" (declaration) "class SDLAudioType;" (type_identifier) "class" (identifier) "SDLAudioType" (;) ";" (ERROR) "@" (ERROR) "@" (declaration) "class SDLBitsPerSample;" (type_identifier) "class" (identifier) "SDLBitsPerSample" (;) ";" (ERROR) "@" (ERROR) "@" (declaration) "class SDLSamplingRate;" (type_identifier) "class" (identifier) "SDLSamplingRate" (;) ";" (comment) "/**\n * Describes different audio type configurations for SDLPerformAudioPassThru, e.g. {8kHz,8-bit,PCM}\n * <p><b>Parameter List</b>\n * <table border="1" rules="all">\n * <tr>\n * <th>Name</th>\n * <th>Type</th>\n * <th>Description</th>\n * <th>SmartDeviceLink Ver. Available</th>\n * </tr>\n * <tr>\n * <td>samplingRate</td>\n * <td>SDLSamplingRate * </td>\n * <td>Describes the sampling rate for AudioPassThru\n * </td>\n * <td>SmartDeviceLink 2.0</td>\n * </tr>\n * <tr>\n * <td>bitsPerSample</td>\n * <td>SDLBitsPerSample * </td>\n * <td>Describes the sample depth in bit for AudioPassThru\n * </td>\n * <td>SmartDeviceLink 2.0</td>\n * </tr>\n * <tr>\n * <td>audioType</td>\n * <td>SDLAudioType * </td>\n * <td>Describes the audiotype for AudioPassThru\n * </td>\n * <td>SmartDeviceLink 2.0</td>\n * </tr>\n * </table>\n * Since <b>SmartDeviceLink 2.0</b>\n */" (ERROR) "@" (ERROR) "@" (function_definition) "interface SDLAudioPassThruCapabilities : SDLRPCStruct {\n}" (type_identifier) "interface" (identifier) "SDLAudioPassThruCapabilities" (ERROR) ": SDLRPCStruct" (:) ":" (identifier) "SDLRPCStruct" (compound_statement) "{\n}" ({) "{" (}) "}" (comment) "/**\n * Constructs a newly allocated SDLAudioPassThruCapabilities object\n */" (expression_statement) "- (instancetype)init;" (unary_expression) "- (instancetype)init" (-) "-" (cast_expression) "(instancetype)init" (() "(" (type_descriptor) "instancetype" (type_identifier) "instancetype" ()) ")" (identifier) "init" (;) ";" (comment) "/**\n * Constructs a newly allocated SDLAudioPassThruCapabilities object indicated by the Hashtable parameter\n * @param dict The dictionary to use\n */" (ERROR) "- (instancetype)initWithDictionary:(NSMutableDictionary *)dict;\n\n/**\n * @abstract The sampling rate for AudioPassThru<br>\n *\n */\n@" (binary_expression) "- (instancetype)initWithDictionary:(NSMutableDictionary *)dict" (unary_expression) "- (instancetype)initWithDictionary" (-) "-" (cast_expression) "(instancetype)initWithDictionary" (() "(" (type_descriptor) "instancetype" (type_identifier) "instancetype" ()) ")" (identifier) "initWithDictionary" (ERROR) ":(NSMutableDictionary" (:) ":" (() "(" (identifier) "NSMutableDictionary" (*) "*" (ERROR) ")" ()) ")" (identifier) "dict" (;) ";" (comment) "/**\n * @abstract The sampling rate for AudioPassThru<br>\n *\n */" (ERROR) "@" (declaration) "property (strong) SDLSamplingRate" (macro_type_specifier) "property (strong)" (identifier) "property" (() "(" (type_descriptor) "strong" (type_identifier) "strong" ()) ")" (identifier) "SDLSamplingRate" (;) "" (expression_statement) "*samplingRate;" (pointer_expression) "*samplingRate" (*) "*" (identifier) "samplingRate" (;) ";" (comment) "/**\n * @abstract The sample depth in bit for AudioPassThru<br>\n *\n */" (ERROR) "@" (ERROR) "@" (declaration) "property (strong) SDLBitsPerSample" (macro_type_specifier) "property (strong)" (identifier) "property" (() "(" (type_descriptor) "strong" (type_identifier) "strong" ()) ")" (identifier) "SDLBitsPerSample" (;) "" (expression_statement) "*bitsPerSample;" (pointer_expression) "*bitsPerSample" (*) "*" (identifier) "bitsPerSample" (;) ";" (comment) "/**\n * @abstract The audiotype for AudioPassThru<br>\n *\n */" (ERROR) "@" (ERROR) "@" (declaration) "property (strong) SDLAudioType" (macro_type_specifier) "property (strong)" (identifier) "property" (() "(" (type_descriptor) "strong" (type_identifier) "strong" ()) ")" (identifier) "SDLAudioType" (;) "" (expression_statement) "*audioType;" (pointer_expression) "*audioType" (*) "*" (identifier) "audioType" (;) ";" (ERROR) "@" (ERROR) "@" (expression_statement) "end" (identifier) "end" (;) ""
122
19
{"language": "c", "success": true, "metadata": {"lines": 68, "avg_line_length": 24.88, "nodes": 74, "errors": 0, "source_hash": "d89dc5468840d4ef81d2d494b6d0d309616192b90cd930b00121cfa457dffea0", "categorized_nodes": 43}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#import \"SDLRPCMessage.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#import", "parent": 0, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "\"SDLRPCMessage.h\"", "parent": 0, "children": [], "start_point": {"row": 3, "column": 8}, "end_point": {"row": 3, "column": 25}}, {"id": 3, "type": "ERROR", "text": "@", "parent": null, "children": [4], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 1}}, {"id": 4, "type": "ERROR", "text": "@", "parent": 3, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 1}}, {"id": 5, "type": "declaration", "text": "class SDLAudioType;", "parent": null, "children": [6], "start_point": {"row": 5, "column": 1}, "end_point": {"row": 5, "column": 20}}, {"id": 6, "type": "identifier", "text": "SDLAudioType", "parent": 5, "children": [], "start_point": {"row": 5, "column": 7}, "end_point": {"row": 5, "column": 19}}, {"id": 7, "type": "ERROR", "text": "@", "parent": null, "children": [8], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 1}}, {"id": 8, "type": "ERROR", "text": "@", "parent": 7, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 1}}, {"id": 9, "type": "declaration", "text": "class SDLBitsPerSample;", "parent": null, "children": [10], "start_point": {"row": 6, "column": 1}, "end_point": {"row": 6, "column": 24}}, {"id": 10, "type": "identifier", "text": "SDLBitsPerSample", "parent": 9, "children": [], "start_point": {"row": 6, "column": 7}, "end_point": {"row": 6, "column": 23}}, {"id": 11, "type": "ERROR", "text": "@", "parent": null, "children": [12], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 1}}, {"id": 12, "type": "ERROR", "text": "@", "parent": 11, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 1}}, {"id": 13, "type": "declaration", "text": "class SDLSamplingRate;", "parent": null, "children": [14], "start_point": {"row": 7, "column": 1}, "end_point": {"row": 7, "column": 23}}, {"id": 14, "type": "identifier", "text": "SDLSamplingRate", "parent": 13, "children": [], "start_point": {"row": 7, "column": 7}, "end_point": {"row": 7, "column": 22}}, {"id": 15, "type": "ERROR", "text": "@", "parent": null, "children": [16], "start_point": {"row": 44, "column": 0}, "end_point": {"row": 44, "column": 1}}, {"id": 16, "type": "ERROR", "text": "@", "parent": 15, "children": [], "start_point": {"row": 44, "column": 0}, "end_point": {"row": 44, "column": 1}}, {"id": 17, "type": "function_definition", "text": "interface SDLAudioPassThruCapabilities : SDLRPCStruct {\n}", "parent": null, "children": [18, 19, 20], "start_point": {"row": 44, "column": 1}, "end_point": {"row": 45, "column": 1}}, {"id": 18, "type": "type_identifier", "text": "interface", "parent": 17, "children": [], "start_point": {"row": 44, "column": 1}, "end_point": {"row": 44, "column": 10}}, {"id": 19, "type": "identifier", "text": "SDLAudioPassThruCapabilities", "parent": 17, "children": [], "start_point": {"row": 44, "column": 11}, "end_point": {"row": 44, "column": 39}}, {"id": 20, "type": "ERROR", "text": ": SDLRPCStruct", "parent": 17, "children": [21], "start_point": {"row": 44, "column": 40}, "end_point": {"row": 44, "column": 54}}, {"id": 21, "type": "identifier", "text": "SDLRPCStruct", "parent": 20, "children": [], "start_point": {"row": 44, "column": 42}, "end_point": {"row": 44, "column": 54}}, {"id": 22, "type": "unary_expression", "text": "- (instancetype)init", "parent": null, "children": [23, 24], "start_point": {"row": 50, "column": 0}, "end_point": {"row": 50, "column": 20}}, {"id": 23, "type": "-", "text": "-", "parent": 22, "children": [], "start_point": {"row": 50, "column": 0}, "end_point": {"row": 50, "column": 1}}, {"id": 24, "type": "cast_expression", "text": "(instancetype)init", "parent": 22, "children": [25, 27], "start_point": {"row": 50, "column": 2}, "end_point": {"row": 50, "column": 20}}, {"id": 25, "type": "type_descriptor", "text": "instancetype", "parent": 24, "children": [26], "start_point": {"row": 50, "column": 3}, "end_point": {"row": 50, "column": 15}}, {"id": 26, "type": "type_identifier", "text": "instancetype", "parent": 25, "children": [], "start_point": {"row": 50, "column": 3}, "end_point": {"row": 50, "column": 15}}, {"id": 27, "type": "identifier", "text": "init", "parent": 24, "children": [], "start_point": {"row": 50, "column": 16}, "end_point": {"row": 50, "column": 20}}, {"id": 28, "type": "ERROR", "text": "- (instancetype)initWithDictionary:(NSMutableDictionary *)dict;\n\n/**\n * @abstract The sampling rate for AudioPassThru<br>\n *\n */\n@", "parent": null, "children": [29, 40], "start_point": {"row": 55, "column": 0}, "end_point": {"row": 61, "column": 1}}, {"id": 29, "type": "binary_expression", "text": "- (instancetype)initWithDictionary:(NSMutableDictionary *)dict", "parent": 28, "children": [30, 36, 38, 39], "start_point": {"row": 55, "column": 0}, "end_point": {"row": 55, "column": 62}}, {"id": 30, "type": "unary_expression", "text": "- (instancetype)initWithDictionary", "parent": 29, "children": [31, 32], "start_point": {"row": 55, "column": 0}, "end_point": {"row": 55, "column": 34}}, {"id": 31, "type": "-", "text": "-", "parent": 30, "children": [], "start_point": {"row": 55, "column": 0}, "end_point": {"row": 55, "column": 1}}, {"id": 32, "type": "cast_expression", "text": "(instancetype)initWithDictionary", "parent": 30, "children": [33, 35], "start_point": {"row": 55, "column": 2}, "end_point": {"row": 55, "column": 34}}, {"id": 33, "type": "type_descriptor", "text": "instancetype", "parent": 32, "children": [34], "start_point": {"row": 55, "column": 3}, "end_point": {"row": 55, "column": 15}}, {"id": 34, "type": "type_identifier", "text": "instancetype", "parent": 33, "children": [], "start_point": {"row": 55, "column": 3}, "end_point": {"row": 55, "column": 15}}, {"id": 35, "type": "identifier", "text": "initWithDictionary", "parent": 32, "children": [], "start_point": {"row": 55, "column": 16}, "end_point": {"row": 55, "column": 34}}, {"id": 36, "type": "ERROR", "text": ":(NSMutableDictionary", "parent": 29, "children": [37], "start_point": {"row": 55, "column": 34}, "end_point": {"row": 55, "column": 55}}, {"id": 37, "type": "identifier", "text": "NSMutableDictionary", "parent": 36, "children": [], "start_point": {"row": 55, "column": 36}, "end_point": {"row": 55, "column": 55}}, {"id": 38, "type": "*", "text": "*", "parent": 29, "children": [], "start_point": {"row": 55, "column": 56}, "end_point": {"row": 55, "column": 57}}, {"id": 39, "type": "identifier", "text": "dict", "parent": 29, "children": [], "start_point": {"row": 55, "column": 58}, "end_point": {"row": 55, "column": 62}}, {"id": 40, "type": "ERROR", "text": "@", "parent": 28, "children": [], "start_point": {"row": 61, "column": 0}, "end_point": {"row": 61, "column": 1}}, {"id": 41, "type": "declaration", "text": "property (strong) SDLSamplingRate", "parent": null, "children": [42, 46], "start_point": {"row": 61, "column": 1}, "end_point": {"row": 61, "column": 34}}, {"id": 42, "type": "macro_type_specifier", "text": "property (strong)", "parent": 41, "children": [43, 44], "start_point": {"row": 61, "column": 1}, "end_point": {"row": 61, "column": 18}}, {"id": 43, "type": "identifier", "text": "property", "parent": 42, "children": [], "start_point": {"row": 61, "column": 1}, "end_point": {"row": 61, "column": 9}}, {"id": 44, "type": "type_descriptor", "text": "strong", "parent": 42, "children": [45], "start_point": {"row": 61, "column": 11}, "end_point": {"row": 61, "column": 17}}, {"id": 45, "type": "type_identifier", "text": "strong", "parent": 44, "children": [], "start_point": {"row": 61, "column": 11}, "end_point": {"row": 61, "column": 17}}, {"id": 46, "type": "identifier", "text": "SDLSamplingRate", "parent": 41, "children": [], "start_point": {"row": 61, "column": 19}, "end_point": {"row": 61, "column": 34}}, {"id": 47, "type": "pointer_expression", "text": "*samplingRate", "parent": null, "children": [48, 49], "start_point": {"row": 61, "column": 35}, "end_point": {"row": 61, "column": 48}}, {"id": 48, "type": "*", "text": "*", "parent": 47, "children": [], "start_point": {"row": 61, "column": 35}, "end_point": {"row": 61, "column": 36}}, {"id": 49, "type": "identifier", "text": "samplingRate", "parent": 47, "children": [], "start_point": {"row": 61, "column": 36}, "end_point": {"row": 61, "column": 48}}, {"id": 50, "type": "ERROR", "text": "@", "parent": null, "children": [51], "start_point": {"row": 66, "column": 0}, "end_point": {"row": 66, "column": 1}}, {"id": 51, "type": "ERROR", "text": "@", "parent": 50, "children": [], "start_point": {"row": 66, "column": 0}, "end_point": {"row": 66, "column": 1}}, {"id": 52, "type": "declaration", "text": "property (strong) SDLBitsPerSample", "parent": null, "children": [53, 57], "start_point": {"row": 66, "column": 1}, "end_point": {"row": 66, "column": 35}}, {"id": 53, "type": "macro_type_specifier", "text": "property (strong)", "parent": 52, "children": [54, 55], "start_point": {"row": 66, "column": 1}, "end_point": {"row": 66, "column": 18}}, {"id": 54, "type": "identifier", "text": "property", "parent": 53, "children": [], "start_point": {"row": 66, "column": 1}, "end_point": {"row": 66, "column": 9}}, {"id": 55, "type": "type_descriptor", "text": "strong", "parent": 53, "children": [56], "start_point": {"row": 66, "column": 11}, "end_point": {"row": 66, "column": 17}}, {"id": 56, "type": "type_identifier", "text": "strong", "parent": 55, "children": [], "start_point": {"row": 66, "column": 11}, "end_point": {"row": 66, "column": 17}}, {"id": 57, "type": "identifier", "text": "SDLBitsPerSample", "parent": 52, "children": [], "start_point": {"row": 66, "column": 19}, "end_point": {"row": 66, "column": 35}}, {"id": 58, "type": "pointer_expression", "text": "*bitsPerSample", "parent": null, "children": [59, 60], "start_point": {"row": 66, "column": 36}, "end_point": {"row": 66, "column": 50}}, {"id": 59, "type": "*", "text": "*", "parent": 58, "children": [], "start_point": {"row": 66, "column": 36}, "end_point": {"row": 66, "column": 37}}, {"id": 60, "type": "identifier", "text": "bitsPerSample", "parent": 58, "children": [], "start_point": {"row": 66, "column": 37}, "end_point": {"row": 66, "column": 50}}, {"id": 61, "type": "ERROR", "text": "@", "parent": null, "children": [62], "start_point": {"row": 71, "column": 0}, "end_point": {"row": 71, "column": 1}}, {"id": 62, "type": "ERROR", "text": "@", "parent": 61, "children": [], "start_point": {"row": 71, "column": 0}, "end_point": {"row": 71, "column": 1}}, {"id": 63, "type": "declaration", "text": "property (strong) SDLAudioType", "parent": null, "children": [64, 68], "start_point": {"row": 71, "column": 1}, "end_point": {"row": 71, "column": 31}}, {"id": 64, "type": "macro_type_specifier", "text": "property (strong)", "parent": 63, "children": [65, 66], "start_point": {"row": 71, "column": 1}, "end_point": {"row": 71, "column": 18}}, {"id": 65, "type": "identifier", "text": "property", "parent": 64, "children": [], "start_point": {"row": 71, "column": 1}, "end_point": {"row": 71, "column": 9}}, {"id": 66, "type": "type_descriptor", "text": "strong", "parent": 64, "children": [67], "start_point": {"row": 71, "column": 11}, "end_point": {"row": 71, "column": 17}}, {"id": 67, "type": "type_identifier", "text": "strong", "parent": 66, "children": [], "start_point": {"row": 71, "column": 11}, "end_point": {"row": 71, "column": 17}}, {"id": 68, "type": "identifier", "text": "SDLAudioType", "parent": 63, "children": [], "start_point": {"row": 71, "column": 19}, "end_point": {"row": 71, "column": 31}}, {"id": 69, "type": "pointer_expression", "text": "*audioType", "parent": null, "children": [70, 71], "start_point": {"row": 71, "column": 32}, "end_point": {"row": 71, "column": 42}}, {"id": 70, "type": "*", "text": "*", "parent": 69, "children": [], "start_point": {"row": 71, "column": 32}, "end_point": {"row": 71, "column": 33}}, {"id": 71, "type": "identifier", "text": "audioType", "parent": 69, "children": [], "start_point": {"row": 71, "column": 33}, "end_point": {"row": 71, "column": 42}}, {"id": 72, "type": "ERROR", "text": "@", "parent": null, "children": [73], "start_point": {"row": 73, "column": 0}, "end_point": {"row": 73, "column": 1}}, {"id": 73, "type": "ERROR", "text": "@", "parent": 72, "children": [], "start_point": {"row": 73, "column": 0}, "end_point": {"row": 73, "column": 1}}]}, "node_categories": {"declarations": {"functions": [17], "variables": [5, 9, 13, 41, 52, 63], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [22, 24, 29, 30, 32, 47, 58, 69], "assignments": [], "loops": [], "conditionals": [6, 10, 14, 18, 19, 21, 26, 27, 34, 35, 37, 39, 42, 43, 45, 46, 49, 53, 54, 56, 57, 60, 64, 65, 67, 68, 71], "returns": [], "exceptions": []}, "expressions": {"calls": [0], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 17, "universal_type": "function", "name": "SDLAudioPassThruCapabilities", "text_snippet": "interface SDLAudioPassThruCapabilities : SDLRPCStruct {\n}"}], "class_declarations": [], "import_statements": []}, "original_source_code": "// SDLAudioPassThruCapabilities.h\n//\n\n#import \"SDLRPCMessage.h\"\n\n@class SDLAudioType;\n@class SDLBitsPerSample;\n@class SDLSamplingRate;\n\n\n/**\n * Describes different audio type configurations for SDLPerformAudioPassThru, e.g. {8kHz,8-bit,PCM}\n * <p><b>Parameter List</b>\n * <table border=\"1\" rules=\"all\">\n * \t\t<tr>\n * \t\t\t<th>Name</th>\n * \t\t\t<th>Type</th>\n * \t\t\t<th>Description</th>\n * \t\t\t<th>SmartDeviceLink Ver. Available</th>\n * \t\t</tr>\n * \t\t<tr>\n * \t\t\t<td>samplingRate</td>\n * \t\t\t<td>SDLSamplingRate * </td>\n * \t\t\t<td>Describes the sampling rate for AudioPassThru\n * \t\t\t</td>\n * \t\t\t<td>SmartDeviceLink 2.0</td>\n * \t\t</tr>\n * \t\t<tr>\n * \t\t\t<td>bitsPerSample</td>\n * \t\t\t<td>SDLBitsPerSample * </td>\n * \t\t\t<td>Describes the sample depth in bit for AudioPassThru\n * \t\t\t</td>\n * \t\t\t<td>SmartDeviceLink 2.0</td>\n * \t\t</tr>\n * \t\t<tr>\n * \t\t\t<td>audioType</td>\n * \t\t\t<td>SDLAudioType * </td>\n * \t\t\t<td>Describes the audiotype for AudioPassThru\n * \t\t\t</td>\n * \t\t\t<td>SmartDeviceLink 2.0</td>\n * \t\t</tr>\n * </table>\n * Since <b>SmartDeviceLink 2.0</b>\n */\n@interface SDLAudioPassThruCapabilities : SDLRPCStruct {\n}\n\n/**\n * Constructs a newly allocated SDLAudioPassThruCapabilities object\n */\n- (instancetype)init;\n/**\n * Constructs a newly allocated SDLAudioPassThruCapabilities object indicated by the Hashtable parameter\n * @param dict The dictionary to use\n */\n- (instancetype)initWithDictionary:(NSMutableDictionary *)dict;\n\n/**\n * @abstract The sampling rate for AudioPassThru<br>\n *\n */\n@property (strong) SDLSamplingRate *samplingRate;\n/**\n * @abstract The sample depth in bit for AudioPassThru<br>\n *\n */\n@property (strong) SDLBitsPerSample *bitsPerSample;\n/**\n * @abstract The audiotype for AudioPassThru<br>\n *\n */\n@property (strong) SDLAudioType *audioType;\n\n@end\n"}
80,567
c
// SPDX-License-Identifier: BSD-2-Clause /* Copyright 2017-2018 <NAME> Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include <cycle/ts/_ts.h> #include <cycle/tsemf/_tsemf.h> #include <cycle/res/_res.h> #include <cycle/_cycle.h> #include <cycle/share/cycle_share.h> #include <cycle/restime/_restime.h> #include <src/bdry.h> #ifdef EMFIELD #error The Predictor Corrector cycle can not be used with EMFIELD #endif #ifndef _RESTIME_PREDICTOR_CORRECTOR #error The Predictor Corrector cycle can only be used with a predictor corrector time discretization method (RK2, RK3, etc) #endif void write_runtime_template(FILE **controlfile){ wfprintf(*controlfile, " %s(\n",_CYCLE_ACTIONNAME); wfprintf(*controlfile, " tmax=1e-4; {simulation time span in seconds}\n" " dt=tmax/30; {physical time step in seconds}\n" ); wfprintf(*controlfile, " if (time>tmax-0.1*dt,\n" " WriteDataFile(outputfilename\".\"round(time/dt));\n" " exit(EXIT_SUCCESS);\n" " );\n" " if (mod(iter,50)==1,\n" " WriteDataFile(outputfilename\".\"round(time/dt));\n" " );\n" ); wfprintf(*controlfile, " UpdateFluid(dt);\n" " printf(\"%%E %%6ld %%9.3f %%E (%%4ld" #ifdef _2DL ",%%4ld" #endif #ifdef _3DL ",%%4ld" #endif ")" " %%s\\n\",\n" " time,iter,effiter_U,ximax,i_ximax,\n" " " #ifdef _2DL "j_ximax," #endif #ifdef _3DL "k_ximax," #endif "clipinfo);\n"); wfprintf(*controlfile, " );\n"); } void runtime_actions_cycle_specific(char *actionname, char **argum, SOAP_codex_t *codex){ #ifdef DISTMPI double delta_effiter_U,effiter_U_mem,delta_effiter_U_max; #endif long l,flux,i,j,k; gl_t *gl; np_t *np; np=*((readcontrolarg_t *)codex->action_args)->np; gl=((readcontrolarg_t *)codex->action_args)->gl; if (strcmp(actionname,"UpdateFluid")==0) { SOAP_substitute_all_argums(argum, codex); if (SOAP_number_argums(*argum)!=1) SOAP_fatal_error(codex,"Number of arguments not equal to 1 in UpdateFluid(); action."); gl->dt=SOAP_get_argum_double(codex,*argum,0); if (gl->dt<=0.0) fatal_error("The time step dt must be positive when calling UpdateFluid."); for_ijk(gl->domain_lim,is,js,ks,ie,je,ke){ l=_ai(gl,i,j,k); if ((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))){ for (flux=0; flux<nf; flux++){ np[l].bs->Um1[flux]=np[l].bs->U[flux]; } } } for (gl->subiter_pc=0; gl->subiter_pc<gl->numsubiter_pc; gl->subiter_pc++){ update_bdry_nodes(np,gl,gl->domain); find_residual(np, gl, gl->domain); find_ximax(np, gl, gl->domain, IJK_UPDATE_YES); #ifdef DISTMPI effiter_U_mem=gl->effiter_U; #endif update_U_predictor_corrector(np, gl, gl->domain); update_linked_nodes(np, gl, TYPELEVEL_FLUID); #ifdef DISTMPI exchange_U(np, gl); delta_effiter_U=gl->effiter_U-effiter_U_mem; MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD); gl->effiter_U=effiter_U_mem+delta_effiter_U_max; #endif } gl->time+=gl->dt; update_runtime_codex_xi_from_gl(gl,codex); add_double_to_codex(codex,"time",gl->time); codex->ACTIONPROCESSED=TRUE; } } void init_cycle(char *argum, SOAP_codex_t *codexcontrol){ np_t **np; gl_t *gl; np=((readcontrolarg_t *)codexcontrol->action_args)->np; gl=((readcontrolarg_t *)codexcontrol->action_args)->gl; resume_nodes_only_in_zone(*np, gl, _zone_intersection(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid)))); SOAP_copy_codex(codexcontrol,&(gl->cycle.codex)); update_bdry_nodes(*np, gl, gl->domain); update_linked_nodes(*np, gl, TYPELEVEL_FLUID); find_residual(*np, gl, gl->domain); find_ximax(*np,gl,gl->domain,IJK_UPDATE_YES); gl->RESIDUAL_ALTERED=FALSE; } void perform_one_iteration(np_t *np, gl_t *gl){ process_code_runtime(np,gl,gl->cycle.code_runtime,&(gl->cycle.codex)); }
36.19
142
(translation_unit) "// SPDX-License-Identifier: BSD-2-Clause\n/*\nCopyright 2017-2018 <NAME>\n\nRedistribution and use in source and binary forms, with or without modification, are\npermitted provided that the following conditions are met:\n\n1. Redistributions of source code must retain the above copyright notice, this list of\n conditions and the following disclaimer.\n\n2. Redistributions in binary form must reproduce the above copyright notice, this list\n of conditions and the following disclaimer in the documentation and/or other\n materials provided with the distribution.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY\nEXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF \nMERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL\nTHE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, \nSPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT\nOF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS \nINTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT\nLIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\nOF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n*/\n\n#include <cycle/ts/_ts.h>\n#include <cycle/tsemf/_tsemf.h>\n#include <cycle/res/_res.h>\n#include <cycle/_cycle.h>\n#include <cycle/share/cycle_share.h>\n#include <cycle/restime/_restime.h>\n#include <src/bdry.h>\n\n#ifdef EMFIELD\n#error The Predictor Corrector cycle can not be used with EMFIELD\n#endif\n\n#ifndef _RESTIME_PREDICTOR_CORRECTOR\n#error The Predictor Corrector cycle can only be used with a predictor corrector time discretization method (RK2, RK3, etc)\n#endif\n\nvoid write_runtime_template(FILE **controlfile){\n wfprintf(*controlfile,\n " %s(\n",_CYCLE_ACTIONNAME);\n wfprintf(*controlfile,\n " tmax=1e-4; {simulation time span in seconds}\n"\n " dt=tmax/30; {physical time step in seconds}\n"\n );\n wfprintf(*controlfile,\n " if (time>tmax-0.1*dt,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " exit(EXIT_SUCCESS);\n"\n " );\n"\n " if (mod(iter,50)==1,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " );\n"\n );\n wfprintf(*controlfile,\n " UpdateFluid(dt);\n"\n " printf(\"%%E %%6ld %%9.3f %%E (%%4ld"\n#ifdef _2DL\n ",%%4ld"\n#endif\n#ifdef _3DL\n ",%%4ld"\n#endif\n ")"\n " %%s\\n\",\n"\n " time,iter,effiter_U,ximax,i_ximax,\n"\n " "\n#ifdef _2DL\n "j_ximax,"\n#endif\n#ifdef _3DL\n "k_ximax,"\n#endif\n "clipinfo);\n");\n\n\n wfprintf(*controlfile,\n " );\n");\n\n}\n\n\n\nvoid runtime_actions_cycle_specific(char *actionname, char **argum, SOAP_codex_t *codex){\n#ifdef DISTMPI\n double delta_effiter_U,effiter_U_mem,delta_effiter_U_max;\n#endif\n long l,flux,i,j,k;\n gl_t *gl;\n np_t *np;\n\n\n np=*((readcontrolarg_t *)codex->action_args)->np;\n gl=((readcontrolarg_t *)codex->action_args)->gl;\n\n if (strcmp(actionname,"UpdateFluid")==0) {\n SOAP_substitute_all_argums(argum, codex);\n if (SOAP_number_argums(*argum)!=1) SOAP_fatal_error(codex,"Number of arguments not equal to 1 in UpdateFluid(); action.");\n gl->dt=SOAP_get_argum_double(codex,*argum,0);\n if (gl->dt<=0.0) fatal_error("The time step dt must be positive when calling UpdateFluid.");\n for_ijk(gl->domain_lim,is,js,ks,ie,je,ke){\n l=_ai(gl,i,j,k);\n if ((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))){\n for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }\n }\n }\n\n for (gl->subiter_pc=0; gl->subiter_pc<gl->numsubiter_pc; gl->subiter_pc++){\n update_bdry_nodes(np,gl,gl->domain); \n find_residual(np, gl, gl->domain);\n find_ximax(np, gl, gl->domain, IJK_UPDATE_YES);\n#ifdef DISTMPI\n effiter_U_mem=gl->effiter_U;\n#endif\n update_U_predictor_corrector(np, gl, gl->domain);\n update_linked_nodes(np, gl, TYPELEVEL_FLUID);\n#ifdef DISTMPI\n exchange_U(np, gl);\n delta_effiter_U=gl->effiter_U-effiter_U_mem;\n MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);\n gl->effiter_U=effiter_U_mem+delta_effiter_U_max;\n#endif\n }\n gl->time+=gl->dt;\n update_runtime_codex_xi_from_gl(gl,codex);\n add_double_to_codex(codex,"time",gl->time); \n codex->ACTIONPROCESSED=TRUE;\n }\n\n\n}\n\n\n\n\nvoid init_cycle(char *argum, SOAP_codex_t *codexcontrol){\n np_t **np;\n gl_t *gl;\n\n np=((readcontrolarg_t *)codexcontrol->action_args)->np;\n gl=((readcontrolarg_t *)codexcontrol->action_args)->gl;\n\n resume_nodes_only_in_zone(*np, gl, _zone_intersection(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))));\n SOAP_copy_codex(codexcontrol,&(gl->cycle.codex));\n update_bdry_nodes(*np, gl, gl->domain);\n update_linked_nodes(*np, gl, TYPELEVEL_FLUID);\n find_residual(*np, gl, gl->domain);\n find_ximax(*np,gl,gl->domain,IJK_UPDATE_YES); \n gl->RESIDUAL_ALTERED=FALSE;\n}\n\n\n\n\nvoid perform_one_iteration(np_t *np, gl_t *gl){\n\n\n process_code_runtime(np,gl,gl->cycle.code_runtime,&(gl->cycle.codex));\n\n\n}\n\n" (comment) "// SPDX-License-Identifier: BSD-2-Clause" (comment) "/*\nCopyright 2017-2018 <NAME>\n\nRedistribution and use in source and binary forms, with or without modification, are\npermitted provided that the following conditions are met:\n\n1. Redistributions of source code must retain the above copyright notice, this list of\n conditions and the following disclaimer.\n\n2. Redistributions in binary form must reproduce the above copyright notice, this list\n of conditions and the following disclaimer in the documentation and/or other\n materials provided with the distribution.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY\nEXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF \nMERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL\nTHE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, \nSPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT\nOF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS \nINTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT\nLIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\nOF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n*/" (preproc_include) "#include <cycle/ts/_ts.h>\n" (#include) "#include" (system_lib_string) "<cycle/ts/_ts.h>" (preproc_include) "#include <cycle/tsemf/_tsemf.h>\n" (#include) "#include" (system_lib_string) "<cycle/tsemf/_tsemf.h>" (preproc_include) "#include <cycle/res/_res.h>\n" (#include) "#include" (system_lib_string) "<cycle/res/_res.h>" (preproc_include) "#include <cycle/_cycle.h>\n" (#include) "#include" (system_lib_string) "<cycle/_cycle.h>" (preproc_include) "#include <cycle/share/cycle_share.h>\n" (#include) "#include" (system_lib_string) "<cycle/share/cycle_share.h>" (preproc_include) "#include <cycle/restime/_restime.h>\n" (#include) "#include" (system_lib_string) "<cycle/restime/_restime.h>" (preproc_include) "#include <src/bdry.h>\n" (#include) "#include" (system_lib_string) "<src/bdry.h>" (preproc_ifdef) "#ifdef EMFIELD\n#error The Predictor Corrector cycle can not be used with EMFIELD\n#endif" (#ifdef) "#ifdef" (identifier) "EMFIELD" (preproc_call) "#error The Predictor Corrector cycle can not be used with EMFIELD\n" (preproc_directive) "#error" (preproc_arg) "The Predictor Corrector cycle can not be used with EMFIELD" (#endif) "#endif" (preproc_ifdef) "#ifndef _RESTIME_PREDICTOR_CORRECTOR\n#error The Predictor Corrector cycle can only be used with a predictor corrector time discretization method (RK2, RK3, etc)\n#endif" (#ifndef) "#ifndef" (identifier) "_RESTIME_PREDICTOR_CORRECTOR" (preproc_call) "#error The Predictor Corrector cycle can only be used with a predictor corrector time discretization method (RK2, RK3, etc)\n" (preproc_directive) "#error" (preproc_arg) "The Predictor Corrector cycle can only be used with a predictor corrector time discretization method (RK2, RK3, etc)" (#endif) "#endif" (function_definition) "void write_runtime_template(FILE **controlfile){\n wfprintf(*controlfile,\n " %s(\n",_CYCLE_ACTIONNAME);\n wfprintf(*controlfile,\n " tmax=1e-4; {simulation time span in seconds}\n"\n " dt=tmax/30; {physical time step in seconds}\n"\n );\n wfprintf(*controlfile,\n " if (time>tmax-0.1*dt,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " exit(EXIT_SUCCESS);\n"\n " );\n"\n " if (mod(iter,50)==1,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " );\n"\n );\n wfprintf(*controlfile,\n " UpdateFluid(dt);\n"\n " printf(\"%%E %%6ld %%9.3f %%E (%%4ld"\n#ifdef _2DL\n ",%%4ld"\n#endif\n#ifdef _3DL\n ",%%4ld"\n#endif\n ")"\n " %%s\\n\",\n"\n " time,iter,effiter_U,ximax,i_ximax,\n"\n " "\n#ifdef _2DL\n "j_ximax,"\n#endif\n#ifdef _3DL\n "k_ximax,"\n#endif\n "clipinfo);\n");\n\n\n wfprintf(*controlfile,\n " );\n");\n\n}" (primitive_type) "void" (function_declarator) "write_runtime_template(FILE **controlfile)" (identifier) "write_runtime_template" (parameter_list) "(FILE **controlfile)" (() "(" (parameter_declaration) "FILE **controlfile" (type_identifier) "FILE" (pointer_declarator) "**controlfile" (*) "*" (pointer_declarator) "*controlfile" (*) "*" (identifier) "controlfile" ()) ")" (compound_statement) "{\n wfprintf(*controlfile,\n " %s(\n",_CYCLE_ACTIONNAME);\n wfprintf(*controlfile,\n " tmax=1e-4; {simulation time span in seconds}\n"\n " dt=tmax/30; {physical time step in seconds}\n"\n );\n wfprintf(*controlfile,\n " if (time>tmax-0.1*dt,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " exit(EXIT_SUCCESS);\n"\n " );\n"\n " if (mod(iter,50)==1,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " );\n"\n );\n wfprintf(*controlfile,\n " UpdateFluid(dt);\n"\n " printf(\"%%E %%6ld %%9.3f %%E (%%4ld"\n#ifdef _2DL\n ",%%4ld"\n#endif\n#ifdef _3DL\n ",%%4ld"\n#endif\n ")"\n " %%s\\n\",\n"\n " time,iter,effiter_U,ximax,i_ximax,\n"\n " "\n#ifdef _2DL\n "j_ximax,"\n#endif\n#ifdef _3DL\n "k_ximax,"\n#endif\n "clipinfo);\n");\n\n\n wfprintf(*controlfile,\n " );\n");\n\n}" ({) "{" (expression_statement) "wfprintf(*controlfile,\n " %s(\n",_CYCLE_ACTIONNAME);" (call_expression) "wfprintf(*controlfile,\n " %s(\n",_CYCLE_ACTIONNAME)" (identifier) "wfprintf" (argument_list) "(*controlfile,\n " %s(\n",_CYCLE_ACTIONNAME)" (() "(" (pointer_expression) "*controlfile" (*) "*" (identifier) "controlfile" (,) "," (string_literal) "" %s(\n"" (") """ (string_content) " %s(" (escape_sequence) "\n" (") """ (,) "," (identifier) "_CYCLE_ACTIONNAME" ()) ")" (;) ";" (expression_statement) "wfprintf(*controlfile,\n " tmax=1e-4; {simulation time span in seconds}\n"\n " dt=tmax/30; {physical time step in seconds}\n"\n );" (call_expression) "wfprintf(*controlfile,\n " tmax=1e-4; {simulation time span in seconds}\n"\n " dt=tmax/30; {physical time step in seconds}\n"\n )" (identifier) "wfprintf" (argument_list) "(*controlfile,\n " tmax=1e-4; {simulation time span in seconds}\n"\n " dt=tmax/30; {physical time step in seconds}\n"\n )" (() "(" (pointer_expression) "*controlfile" (*) "*" (identifier) "controlfile" (,) "," (concatenated_string) "" tmax=1e-4; {simulation time span in seconds}\n"\n " dt=tmax/30; {physical time step in seconds}\n"" (string_literal) "" tmax=1e-4; {simulation time span in seconds}\n"" (") """ (string_content) " tmax=1e-4; {simulation time span in seconds}" (escape_sequence) "\n" (") """ (string_literal) "" dt=tmax/30; {physical time step in seconds}\n"" (") """ (string_content) " dt=tmax/30; {physical time step in seconds}" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (expression_statement) "wfprintf(*controlfile,\n " if (time>tmax-0.1*dt,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " exit(EXIT_SUCCESS);\n"\n " );\n"\n " if (mod(iter,50)==1,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " );\n"\n );" (call_expression) "wfprintf(*controlfile,\n " if (time>tmax-0.1*dt,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " exit(EXIT_SUCCESS);\n"\n " );\n"\n " if (mod(iter,50)==1,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " );\n"\n )" (identifier) "wfprintf" (argument_list) "(*controlfile,\n " if (time>tmax-0.1*dt,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " exit(EXIT_SUCCESS);\n"\n " );\n"\n " if (mod(iter,50)==1,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " );\n"\n )" (() "(" (pointer_expression) "*controlfile" (*) "*" (identifier) "controlfile" (,) "," (concatenated_string) "" if (time>tmax-0.1*dt,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " exit(EXIT_SUCCESS);\n"\n " );\n"\n " if (mod(iter,50)==1,\n"\n " WriteDataFile(outputfilename\".\"round(time/dt));\n"\n " );\n"" (string_literal) "" if (time>tmax-0.1*dt,\n"" (") """ (string_content) " if (time>tmax-0.1*dt," (escape_sequence) "\n" (") """ (string_literal) "" WriteDataFile(outputfilename\".\"round(time/dt));\n"" (") """ (string_content) " WriteDataFile(outputfilename" (escape_sequence) "\"" (string_content) "." (escape_sequence) "\"" (string_content) "round(time/dt));" (escape_sequence) "\n" (") """ (string_literal) "" exit(EXIT_SUCCESS);\n"" (") """ (string_content) " exit(EXIT_SUCCESS);" (escape_sequence) "\n" (") """ (string_literal) "" );\n"" (") """ (string_content) " );" (escape_sequence) "\n" (") """ (string_literal) "" if (mod(iter,50)==1,\n"" (") """ (string_content) " if (mod(iter,50)==1," (escape_sequence) "\n" (") """ (string_literal) "" WriteDataFile(outputfilename\".\"round(time/dt));\n"" (") """ (string_content) " WriteDataFile(outputfilename" (escape_sequence) "\"" (string_content) "." (escape_sequence) "\"" (string_content) "round(time/dt));" (escape_sequence) "\n" (") """ (string_literal) "" );\n"" (") """ (string_content) " );" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (expression_statement) "wfprintf(*controlfile,\n " UpdateFluid(dt);\n"\n " printf(\"%%E %%6ld %%9.3f %%E (%%4ld"\n#ifdef _2DL\n ",%%4ld"\n#endif\n#ifdef _3DL\n ",%%4ld"\n#endif\n ")"\n " %%s\\n\",\n"\n " time,iter,effiter_U,ximax,i_ximax,\n"\n " "\n#ifdef _2DL\n "j_ximax,"\n#endif\n#ifdef _3DL\n "k_ximax,"\n#endif\n "clipinfo);\n");" (call_expression) "wfprintf(*controlfile,\n " UpdateFluid(dt);\n"\n " printf(\"%%E %%6ld %%9.3f %%E (%%4ld"\n#ifdef _2DL\n ",%%4ld"\n#endif\n#ifdef _3DL\n ",%%4ld"\n#endif\n ")"\n " %%s\\n\",\n"\n " time,iter,effiter_U,ximax,i_ximax,\n"\n " "\n#ifdef _2DL\n "j_ximax,"\n#endif\n#ifdef _3DL\n "k_ximax,"\n#endif\n "clipinfo);\n")" (identifier) "wfprintf" (argument_list) "(*controlfile,\n " UpdateFluid(dt);\n"\n " printf(\"%%E %%6ld %%9.3f %%E (%%4ld"\n#ifdef _2DL\n ",%%4ld"\n#endif\n#ifdef _3DL\n ",%%4ld"\n#endif\n ")"\n " %%s\\n\",\n"\n " time,iter,effiter_U,ximax,i_ximax,\n"\n " "\n#ifdef _2DL\n "j_ximax,"\n#endif\n#ifdef _3DL\n "k_ximax,"\n#endif\n "clipinfo);\n")" (() "(" (pointer_expression) "*controlfile" (*) "*" (identifier) "controlfile" (,) "," (ERROR) "" UpdateFluid(dt);\n"\n " printf(\"%%E %%6ld %%9.3f %%E (%%4ld"\n#ifdef _2DL\n ",%%4ld"\n#endif\n#ifdef _3DL\n ",%%4ld"\n#endif\n ")"\n " %%s\\n\",\n"\n " time,iter,effiter_U,ximax,i_ximax,\n"\n " "\n#ifdef _2DL\n "j_ximax,"\n#endif\n#ifdef _3DL\n "k_ximax,"\n#endif" (concatenated_string) "" UpdateFluid(dt);\n"\n " printf(\"%%E %%6ld %%9.3f %%E (%%4ld"\n#ifdef _2DL\n ",%%4ld"" (string_literal) "" UpdateFluid(dt);\n"" (") """ (string_content) " UpdateFluid(dt);" (escape_sequence) "\n" (") """ (string_literal) "" printf(\"%%E %%6ld %%9.3f %%E (%%4ld"" (") """ (string_content) " printf(" (escape_sequence) "\"" (string_content) "%%E %%6ld %%9.3f %%E (%%4ld" (") """ (ERROR) "#ifdef" (#ifdef) "#ifdef" (identifier) "_2DL" (string_literal) "",%%4ld"" (") """ (string_content) ",%%4ld" (") """ (#endif) "#endif" (#ifdef) "#ifdef" (concatenated_string) "_3DL\n ",%%4ld"" (identifier) "_3DL" (string_literal) "",%%4ld"" (") """ (string_content) ",%%4ld" (") """ (#endif) "#endif" (concatenated_string) "")"\n " %%s\\n\",\n"\n " time,iter,effiter_U,ximax,i_ximax,\n"\n " "\n#ifdef _2DL\n "j_ximax,"" (string_literal) "")"" (") """ (string_content) ")" (") """ (string_literal) "" %%s\\n\",\n"" (") """ (string_content) " %%s" (escape_sequence) "\\" (string_content) "n" (escape_sequence) "\"" (string_content) "," (escape_sequence) "\n" (") """ (string_literal) "" time,iter,effiter_U,ximax,i_ximax,\n"" (") """ (string_content) " time,iter,effiter_U,ximax,i_ximax," (escape_sequence) "\n" (") """ (string_literal) "" "" (") """ (string_content) " " (") """ (ERROR) "#ifdef" (#ifdef) "#ifdef" (identifier) "_2DL" (string_literal) ""j_ximax,"" (") """ (string_content) "j_ximax," (") """ (#endif) "#endif" (#ifdef) "#ifdef" (concatenated_string) "_3DL\n "k_ximax,"" (identifier) "_3DL" (string_literal) ""k_ximax,"" (") """ (string_content) "k_ximax," (") """ (#endif) "#endif" (string_literal) ""clipinfo);\n"" (") """ (string_content) "clipinfo);" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (expression_statement) "wfprintf(*controlfile,\n " );\n");" (call_expression) "wfprintf(*controlfile,\n " );\n")" (identifier) "wfprintf" (argument_list) "(*controlfile,\n " );\n")" (() "(" (pointer_expression) "*controlfile" (*) "*" (identifier) "controlfile" (,) "," (string_literal) "" );\n"" (") """ (string_content) " );" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (}) "}" (function_definition) "void runtime_actions_cycle_specific(char *actionname, char **argum, SOAP_codex_t *codex){\n#ifdef DISTMPI\n double delta_effiter_U,effiter_U_mem,delta_effiter_U_max;\n#endif\n long l,flux,i,j,k;\n gl_t *gl;\n np_t *np;\n\n\n np=*((readcontrolarg_t *)codex->action_args)->np;\n gl=((readcontrolarg_t *)codex->action_args)->gl;\n\n if (strcmp(actionname,"UpdateFluid")==0) {\n SOAP_substitute_all_argums(argum, codex);\n if (SOAP_number_argums(*argum)!=1) SOAP_fatal_error(codex,"Number of arguments not equal to 1 in UpdateFluid(); action.");\n gl->dt=SOAP_get_argum_double(codex,*argum,0);\n if (gl->dt<=0.0) fatal_error("The time step dt must be positive when calling UpdateFluid.");\n for_ijk(gl->domain_lim,is,js,ks,ie,je,ke){\n l=_ai(gl,i,j,k);\n if ((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))){\n for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }\n }\n }\n\n for (gl->subiter_pc=0; gl->subiter_pc<gl->numsubiter_pc; gl->subiter_pc++){\n update_bdry_nodes(np,gl,gl->domain); \n find_residual(np, gl, gl->domain);\n find_ximax(np, gl, gl->domain, IJK_UPDATE_YES);\n#ifdef DISTMPI\n effiter_U_mem=gl->effiter_U;\n#endif\n update_U_predictor_corrector(np, gl, gl->domain);\n update_linked_nodes(np, gl, TYPELEVEL_FLUID);\n#ifdef DISTMPI\n exchange_U(np, gl);\n delta_effiter_U=gl->effiter_U-effiter_U_mem;\n MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);\n gl->effiter_U=effiter_U_mem+delta_effiter_U_max;\n#endif\n }\n gl->time+=gl->dt;\n update_runtime_codex_xi_from_gl(gl,codex);\n add_double_to_codex(codex,"time",gl->time); \n codex->ACTIONPROCESSED=TRUE;\n }\n\n\n}" (primitive_type) "void" (function_declarator) "runtime_actions_cycle_specific(char *actionname, char **argum, SOAP_codex_t *codex)" (identifier) "runtime_actions_cycle_specific" (parameter_list) "(char *actionname, char **argum, SOAP_codex_t *codex)" (() "(" (parameter_declaration) "char *actionname" (primitive_type) "char" (pointer_declarator) "*actionname" (*) "*" (identifier) "actionname" (,) "," (parameter_declaration) "char **argum" (primitive_type) "char" (pointer_declarator) "**argum" (*) "*" (pointer_declarator) "*argum" (*) "*" (identifier) "argum" (,) "," (parameter_declaration) "SOAP_codex_t *codex" (type_identifier) "SOAP_codex_t" (pointer_declarator) "*codex" (*) "*" (identifier) "codex" ()) ")" (compound_statement) "{\n#ifdef DISTMPI\n double delta_effiter_U,effiter_U_mem,delta_effiter_U_max;\n#endif\n long l,flux,i,j,k;\n gl_t *gl;\n np_t *np;\n\n\n np=*((readcontrolarg_t *)codex->action_args)->np;\n gl=((readcontrolarg_t *)codex->action_args)->gl;\n\n if (strcmp(actionname,"UpdateFluid")==0) {\n SOAP_substitute_all_argums(argum, codex);\n if (SOAP_number_argums(*argum)!=1) SOAP_fatal_error(codex,"Number of arguments not equal to 1 in UpdateFluid(); action.");\n gl->dt=SOAP_get_argum_double(codex,*argum,0);\n if (gl->dt<=0.0) fatal_error("The time step dt must be positive when calling UpdateFluid.");\n for_ijk(gl->domain_lim,is,js,ks,ie,je,ke){\n l=_ai(gl,i,j,k);\n if ((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))){\n for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }\n }\n }\n\n for (gl->subiter_pc=0; gl->subiter_pc<gl->numsubiter_pc; gl->subiter_pc++){\n update_bdry_nodes(np,gl,gl->domain); \n find_residual(np, gl, gl->domain);\n find_ximax(np, gl, gl->domain, IJK_UPDATE_YES);\n#ifdef DISTMPI\n effiter_U_mem=gl->effiter_U;\n#endif\n update_U_predictor_corrector(np, gl, gl->domain);\n update_linked_nodes(np, gl, TYPELEVEL_FLUID);\n#ifdef DISTMPI\n exchange_U(np, gl);\n delta_effiter_U=gl->effiter_U-effiter_U_mem;\n MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);\n gl->effiter_U=effiter_U_mem+delta_effiter_U_max;\n#endif\n }\n gl->time+=gl->dt;\n update_runtime_codex_xi_from_gl(gl,codex);\n add_double_to_codex(codex,"time",gl->time); \n codex->ACTIONPROCESSED=TRUE;\n }\n\n\n}" ({) "{" (preproc_ifdef) "#ifdef DISTMPI\n double delta_effiter_U,effiter_U_mem,delta_effiter_U_max;\n#endif" (#ifdef) "#ifdef" (identifier) "DISTMPI" (declaration) "double delta_effiter_U,effiter_U_mem,delta_effiter_U_max;" (primitive_type) "double" (identifier) "delta_effiter_U" (,) "," (identifier) "effiter_U_mem" (,) "," (identifier) "delta_effiter_U_max" (;) ";" (#endif) "#endif" (declaration) "long l,flux,i,j,k;" (sized_type_specifier) "long" (long) "long" (identifier) "l" (,) "," (identifier) "flux" (,) "," (identifier) "i" (,) "," (identifier) "j" (,) "," (identifier) "k" (;) ";" (declaration) "gl_t *gl;" (type_identifier) "gl_t" (pointer_declarator) "*gl" (*) "*" (identifier) "gl" (;) ";" (declaration) "np_t *np;" (type_identifier) "np_t" (pointer_declarator) "*np" (*) "*" (identifier) "np" (;) ";" (expression_statement) "np=*((readcontrolarg_t *)codex->action_args)->np;" (assignment_expression) "np=*((readcontrolarg_t *)codex->action_args)->np" (identifier) "np" (=) "=" (pointer_expression) "*((readcontrolarg_t *)codex->action_args)->np" (*) "*" (field_expression) "((readcontrolarg_t *)codex->action_args)->np" (parenthesized_expression) "((readcontrolarg_t *)codex->action_args)" (() "(" (cast_expression) "(readcontrolarg_t *)codex->action_args" (() "(" (type_descriptor) "readcontrolarg_t *" (type_identifier) "readcontrolarg_t" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (field_expression) "codex->action_args" (identifier) "codex" (->) "->" (field_identifier) "action_args" ()) ")" (->) "->" (field_identifier) "np" (;) ";" (expression_statement) "gl=((readcontrolarg_t *)codex->action_args)->gl;" (assignment_expression) "gl=((readcontrolarg_t *)codex->action_args)->gl" (identifier) "gl" (=) "=" (field_expression) "((readcontrolarg_t *)codex->action_args)->gl" (parenthesized_expression) "((readcontrolarg_t *)codex->action_args)" (() "(" (cast_expression) "(readcontrolarg_t *)codex->action_args" (() "(" (type_descriptor) "readcontrolarg_t *" (type_identifier) "readcontrolarg_t" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (field_expression) "codex->action_args" (identifier) "codex" (->) "->" (field_identifier) "action_args" ()) ")" (->) "->" (field_identifier) "gl" (;) ";" (if_statement) "if (strcmp(actionname,"UpdateFluid")==0) {\n SOAP_substitute_all_argums(argum, codex);\n if (SOAP_number_argums(*argum)!=1) SOAP_fatal_error(codex,"Number of arguments not equal to 1 in UpdateFluid(); action.");\n gl->dt=SOAP_get_argum_double(codex,*argum,0);\n if (gl->dt<=0.0) fatal_error("The time step dt must be positive when calling UpdateFluid.");\n for_ijk(gl->domain_lim,is,js,ks,ie,je,ke){\n l=_ai(gl,i,j,k);\n if ((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))){\n for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }\n }\n }\n\n for (gl->subiter_pc=0; gl->subiter_pc<gl->numsubiter_pc; gl->subiter_pc++){\n update_bdry_nodes(np,gl,gl->domain); \n find_residual(np, gl, gl->domain);\n find_ximax(np, gl, gl->domain, IJK_UPDATE_YES);\n#ifdef DISTMPI\n effiter_U_mem=gl->effiter_U;\n#endif\n update_U_predictor_corrector(np, gl, gl->domain);\n update_linked_nodes(np, gl, TYPELEVEL_FLUID);\n#ifdef DISTMPI\n exchange_U(np, gl);\n delta_effiter_U=gl->effiter_U-effiter_U_mem;\n MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);\n gl->effiter_U=effiter_U_mem+delta_effiter_U_max;\n#endif\n }\n gl->time+=gl->dt;\n update_runtime_codex_xi_from_gl(gl,codex);\n add_double_to_codex(codex,"time",gl->time); \n codex->ACTIONPROCESSED=TRUE;\n }" (if) "if" (parenthesized_expression) "(strcmp(actionname,"UpdateFluid")==0)" (() "(" (binary_expression) "strcmp(actionname,"UpdateFluid")==0" (call_expression) "strcmp(actionname,"UpdateFluid")" (identifier) "strcmp" (argument_list) "(actionname,"UpdateFluid")" (() "(" (identifier) "actionname" (,) "," (string_literal) ""UpdateFluid"" (") """ (string_content) "UpdateFluid" (") """ ()) ")" (==) "==" (number_literal) "0" ()) ")" (compound_statement) "{\n SOAP_substitute_all_argums(argum, codex);\n if (SOAP_number_argums(*argum)!=1) SOAP_fatal_error(codex,"Number of arguments not equal to 1 in UpdateFluid(); action.");\n gl->dt=SOAP_get_argum_double(codex,*argum,0);\n if (gl->dt<=0.0) fatal_error("The time step dt must be positive when calling UpdateFluid.");\n for_ijk(gl->domain_lim,is,js,ks,ie,je,ke){\n l=_ai(gl,i,j,k);\n if ((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))){\n for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }\n }\n }\n\n for (gl->subiter_pc=0; gl->subiter_pc<gl->numsubiter_pc; gl->subiter_pc++){\n update_bdry_nodes(np,gl,gl->domain); \n find_residual(np, gl, gl->domain);\n find_ximax(np, gl, gl->domain, IJK_UPDATE_YES);\n#ifdef DISTMPI\n effiter_U_mem=gl->effiter_U;\n#endif\n update_U_predictor_corrector(np, gl, gl->domain);\n update_linked_nodes(np, gl, TYPELEVEL_FLUID);\n#ifdef DISTMPI\n exchange_U(np, gl);\n delta_effiter_U=gl->effiter_U-effiter_U_mem;\n MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);\n gl->effiter_U=effiter_U_mem+delta_effiter_U_max;\n#endif\n }\n gl->time+=gl->dt;\n update_runtime_codex_xi_from_gl(gl,codex);\n add_double_to_codex(codex,"time",gl->time); \n codex->ACTIONPROCESSED=TRUE;\n }" ({) "{" (expression_statement) "SOAP_substitute_all_argums(argum, codex);" (call_expression) "SOAP_substitute_all_argums(argum, codex)" (identifier) "SOAP_substitute_all_argums" (argument_list) "(argum, codex)" (() "(" (identifier) "argum" (,) "," (identifier) "codex" ()) ")" (;) ";" (if_statement) "if (SOAP_number_argums(*argum)!=1) SOAP_fatal_error(codex,"Number of arguments not equal to 1 in UpdateFluid(); action.");" (if) "if" (parenthesized_expression) "(SOAP_number_argums(*argum)!=1)" (() "(" (binary_expression) "SOAP_number_argums(*argum)!=1" (call_expression) "SOAP_number_argums(*argum)" (identifier) "SOAP_number_argums" (argument_list) "(*argum)" (() "(" (pointer_expression) "*argum" (*) "*" (identifier) "argum" ()) ")" (!=) "!=" (number_literal) "1" ()) ")" (expression_statement) "SOAP_fatal_error(codex,"Number of arguments not equal to 1 in UpdateFluid(); action.");" (call_expression) "SOAP_fatal_error(codex,"Number of arguments not equal to 1 in UpdateFluid(); action.")" (identifier) "SOAP_fatal_error" (argument_list) "(codex,"Number of arguments not equal to 1 in UpdateFluid(); action.")" (() "(" (identifier) "codex" (,) "," (string_literal) ""Number of arguments not equal to 1 in UpdateFluid(); action."" (") """ (string_content) "Number of arguments not equal to 1 in UpdateFluid(); action." (") """ ()) ")" (;) ";" (expression_statement) "gl->dt=SOAP_get_argum_double(codex,*argum,0);" (assignment_expression) "gl->dt=SOAP_get_argum_double(codex,*argum,0)" (field_expression) "gl->dt" (identifier) "gl" (->) "->" (field_identifier) "dt" (=) "=" (call_expression) "SOAP_get_argum_double(codex,*argum,0)" (identifier) "SOAP_get_argum_double" (argument_list) "(codex,*argum,0)" (() "(" (identifier) "codex" (,) "," (pointer_expression) "*argum" (*) "*" (identifier) "argum" (,) "," (number_literal) "0" ()) ")" (;) ";" (if_statement) "if (gl->dt<=0.0) fatal_error("The time step dt must be positive when calling UpdateFluid.");" (if) "if" (parenthesized_expression) "(gl->dt<=0.0)" (() "(" (binary_expression) "gl->dt<=0.0" (field_expression) "gl->dt" (identifier) "gl" (->) "->" (field_identifier) "dt" (<=) "<=" (number_literal) "0.0" ()) ")" (expression_statement) "fatal_error("The time step dt must be positive when calling UpdateFluid.");" (call_expression) "fatal_error("The time step dt must be positive when calling UpdateFluid.")" (identifier) "fatal_error" (argument_list) "("The time step dt must be positive when calling UpdateFluid.")" (() "(" (string_literal) ""The time step dt must be positive when calling UpdateFluid."" (") """ (string_content) "The time step dt must be positive when calling UpdateFluid." (") """ ()) ")" (;) ";" (expression_statement) "for_ijk(gl->domain_lim,is,js,ks,ie,je,ke)" (call_expression) "for_ijk(gl->domain_lim,is,js,ks,ie,je,ke)" (identifier) "for_ijk" (argument_list) "(gl->domain_lim,is,js,ks,ie,je,ke)" (() "(" (field_expression) "gl->domain_lim" (identifier) "gl" (->) "->" (field_identifier) "domain_lim" (,) "," (identifier) "is" (,) "," (identifier) "js" (,) "," (identifier) "ks" (,) "," (identifier) "ie" (,) "," (identifier) "je" (,) "," (identifier) "ke" ()) ")" (;) "" (compound_statement) "{\n l=_ai(gl,i,j,k);\n if ((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))){\n for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }\n }\n }" ({) "{" (expression_statement) "l=_ai(gl,i,j,k);" (assignment_expression) "l=_ai(gl,i,j,k)" (identifier) "l" (=) "=" (call_expression) "_ai(gl,i,j,k)" (identifier) "_ai" (argument_list) "(gl,i,j,k)" (() "(" (identifier) "gl" (,) "," (identifier) "i" (,) "," (identifier) "j" (,) "," (identifier) "k" ()) ")" (;) ";" (if_statement) "if ((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))){\n for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }\n }" (if) "if" (parenthesized_expression) "((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID)))" (() "(" (parenthesized_expression) "(is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))" (() "(" (call_expression) "is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID)" (identifier) "is_node_valid" (argument_list) "(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID)" (() "(" (subscript_expression) "np[_ai(gl,i,j,k)]" (identifier) "np" ([) "[" (call_expression) "_ai(gl,i,j,k)" (identifier) "_ai" (argument_list) "(gl,i,j,k)" (() "(" (identifier) "gl" (,) "," (identifier) "i" (,) "," (identifier) "j" (,) "," (identifier) "k" ()) ")" (]) "]" (,) "," (identifier) "TYPELEVEL_FLUID" ()) ")" ()) ")" ()) ")" (compound_statement) "{\n for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }\n }" ({) "{" (for_statement) "for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }" (for) "for" (() "(" (assignment_expression) "flux=0" (identifier) "flux" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "flux<nf" (identifier) "flux" (<) "<" (identifier) "nf" (;) ";" (update_expression) "flux++" (identifier) "flux" (++) "++" ()) ")" (compound_statement) "{\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }" ({) "{" (expression_statement) "np[l].bs->Um1[flux]=np[l].bs->U[flux];" (assignment_expression) "np[l].bs->Um1[flux]=np[l].bs->U[flux]" (subscript_expression) "np[l].bs->Um1[flux]" (field_expression) "np[l].bs->Um1" (field_expression) "np[l].bs" (subscript_expression) "np[l]" (identifier) "np" ([) "[" (identifier) "l" (]) "]" (.) "." (field_identifier) "bs" (->) "->" (field_identifier) "Um1" ([) "[" (identifier) "flux" (]) "]" (=) "=" (subscript_expression) "np[l].bs->U[flux]" (field_expression) "np[l].bs->U" (field_expression) "np[l].bs" (subscript_expression) "np[l]" (identifier) "np" ([) "[" (identifier) "l" (]) "]" (.) "." (field_identifier) "bs" (->) "->" (field_identifier) "U" ([) "[" (identifier) "flux" (]) "]" (;) ";" (}) "}" (}) "}" (}) "}" (for_statement) "for (gl->subiter_pc=0; gl->subiter_pc<gl->numsubiter_pc; gl->subiter_pc++){\n update_bdry_nodes(np,gl,gl->domain); \n find_residual(np, gl, gl->domain);\n find_ximax(np, gl, gl->domain, IJK_UPDATE_YES);\n#ifdef DISTMPI\n effiter_U_mem=gl->effiter_U;\n#endif\n update_U_predictor_corrector(np, gl, gl->domain);\n update_linked_nodes(np, gl, TYPELEVEL_FLUID);\n#ifdef DISTMPI\n exchange_U(np, gl);\n delta_effiter_U=gl->effiter_U-effiter_U_mem;\n MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);\n gl->effiter_U=effiter_U_mem+delta_effiter_U_max;\n#endif\n }" (for) "for" (() "(" (assignment_expression) "gl->subiter_pc=0" (field_expression) "gl->subiter_pc" (identifier) "gl" (->) "->" (field_identifier) "subiter_pc" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "gl->subiter_pc<gl->numsubiter_pc" (field_expression) "gl->subiter_pc" (identifier) "gl" (->) "->" (field_identifier) "subiter_pc" (<) "<" (field_expression) "gl->numsubiter_pc" (identifier) "gl" (->) "->" (field_identifier) "numsubiter_pc" (;) ";" (update_expression) "gl->subiter_pc++" (field_expression) "gl->subiter_pc" (identifier) "gl" (->) "->" (field_identifier) "subiter_pc" (++) "++" ()) ")" (compound_statement) "{\n update_bdry_nodes(np,gl,gl->domain); \n find_residual(np, gl, gl->domain);\n find_ximax(np, gl, gl->domain, IJK_UPDATE_YES);\n#ifdef DISTMPI\n effiter_U_mem=gl->effiter_U;\n#endif\n update_U_predictor_corrector(np, gl, gl->domain);\n update_linked_nodes(np, gl, TYPELEVEL_FLUID);\n#ifdef DISTMPI\n exchange_U(np, gl);\n delta_effiter_U=gl->effiter_U-effiter_U_mem;\n MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);\n gl->effiter_U=effiter_U_mem+delta_effiter_U_max;\n#endif\n }" ({) "{" (expression_statement) "update_bdry_nodes(np,gl,gl->domain);" (call_expression) "update_bdry_nodes(np,gl,gl->domain)" (identifier) "update_bdry_nodes" (argument_list) "(np,gl,gl->domain)" (() "(" (identifier) "np" (,) "," (identifier) "gl" (,) "," (field_expression) "gl->domain" (identifier) "gl" (->) "->" (field_identifier) "domain" ()) ")" (;) ";" (expression_statement) "find_residual(np, gl, gl->domain);" (call_expression) "find_residual(np, gl, gl->domain)" (identifier) "find_residual" (argument_list) "(np, gl, gl->domain)" (() "(" (identifier) "np" (,) "," (identifier) "gl" (,) "," (field_expression) "gl->domain" (identifier) "gl" (->) "->" (field_identifier) "domain" ()) ")" (;) ";" (expression_statement) "find_ximax(np, gl, gl->domain, IJK_UPDATE_YES);" (call_expression) "find_ximax(np, gl, gl->domain, IJK_UPDATE_YES)" (identifier) "find_ximax" (argument_list) "(np, gl, gl->domain, IJK_UPDATE_YES)" (() "(" (identifier) "np" (,) "," (identifier) "gl" (,) "," (field_expression) "gl->domain" (identifier) "gl" (->) "->" (field_identifier) "domain" (,) "," (identifier) "IJK_UPDATE_YES" ()) ")" (;) ";" (preproc_ifdef) "#ifdef DISTMPI\n effiter_U_mem=gl->effiter_U;\n#endif" (#ifdef) "#ifdef" (identifier) "DISTMPI" (expression_statement) "effiter_U_mem=gl->effiter_U;" (assignment_expression) "effiter_U_mem=gl->effiter_U" (identifier) "effiter_U_mem" (=) "=" (field_expression) "gl->effiter_U" (identifier) "gl" (->) "->" (field_identifier) "effiter_U" (;) ";" (#endif) "#endif" (expression_statement) "update_U_predictor_corrector(np, gl, gl->domain);" (call_expression) "update_U_predictor_corrector(np, gl, gl->domain)" (identifier) "update_U_predictor_corrector" (argument_list) "(np, gl, gl->domain)" (() "(" (identifier) "np" (,) "," (identifier) "gl" (,) "," (field_expression) "gl->domain" (identifier) "gl" (->) "->" (field_identifier) "domain" ()) ")" (;) ";" (expression_statement) "update_linked_nodes(np, gl, TYPELEVEL_FLUID);" (call_expression) "update_linked_nodes(np, gl, TYPELEVEL_FLUID)" (identifier) "update_linked_nodes" (argument_list) "(np, gl, TYPELEVEL_FLUID)" (() "(" (identifier) "np" (,) "," (identifier) "gl" (,) "," (identifier) "TYPELEVEL_FLUID" ()) ")" (;) ";" (preproc_ifdef) "#ifdef DISTMPI\n exchange_U(np, gl);\n delta_effiter_U=gl->effiter_U-effiter_U_mem;\n MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);\n gl->effiter_U=effiter_U_mem+delta_effiter_U_max;\n#endif" (#ifdef) "#ifdef" (identifier) "DISTMPI" (expression_statement) "exchange_U(np, gl);" (call_expression) "exchange_U(np, gl)" (identifier) "exchange_U" (argument_list) "(np, gl)" (() "(" (identifier) "np" (,) "," (identifier) "gl" ()) ")" (;) ";" (expression_statement) "delta_effiter_U=gl->effiter_U-effiter_U_mem;" (assignment_expression) "delta_effiter_U=gl->effiter_U-effiter_U_mem" (identifier) "delta_effiter_U" (=) "=" (binary_expression) "gl->effiter_U-effiter_U_mem" (field_expression) "gl->effiter_U" (identifier) "gl" (->) "->" (field_identifier) "effiter_U" (-) "-" (identifier) "effiter_U_mem" (;) ";" (expression_statement) "MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);" (call_expression) "MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD)" (identifier) "MPI_Allreduce" (argument_list) "(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD)" (() "(" (pointer_expression) "&delta_effiter_U" (&) "&" (identifier) "delta_effiter_U" (,) "," (pointer_expression) "&delta_effiter_U_max" (&) "&" (identifier) "delta_effiter_U_max" (,) "," (number_literal) "1" (,) "," (identifier) "MPI_DOUBLE" (,) "," (identifier) "MPI_MAX" (,) "," (identifier) "MPI_COMM_WORLD" ()) ")" (;) ";" (expression_statement) "gl->effiter_U=effiter_U_mem+delta_effiter_U_max;" (assignment_expression) "gl->effiter_U=effiter_U_mem+delta_effiter_U_max" (field_expression) "gl->effiter_U" (identifier) "gl" (->) "->" (field_identifier) "effiter_U" (=) "=" (binary_expression) "effiter_U_mem+delta_effiter_U_max" (identifier) "effiter_U_mem" (+) "+" (identifier) "delta_effiter_U_max" (;) ";" (#endif) "#endif" (}) "}" (expression_statement) "gl->time+=gl->dt;" (assignment_expression) "gl->time+=gl->dt" (field_expression) "gl->time" (identifier) "gl" (->) "->" (field_identifier) "time" (+=) "+=" (field_expression) "gl->dt" (identifier) "gl" (->) "->" (field_identifier) "dt" (;) ";" (expression_statement) "update_runtime_codex_xi_from_gl(gl,codex);" (call_expression) "update_runtime_codex_xi_from_gl(gl,codex)" (identifier) "update_runtime_codex_xi_from_gl" (argument_list) "(gl,codex)" (() "(" (identifier) "gl" (,) "," (identifier) "codex" ()) ")" (;) ";" (expression_statement) "add_double_to_codex(codex,"time",gl->time);" (call_expression) "add_double_to_codex(codex,"time",gl->time)" (identifier) "add_double_to_codex" (argument_list) "(codex,"time",gl->time)" (() "(" (identifier) "codex" (,) "," (string_literal) ""time"" (") """ (string_content) "time" (") """ (,) "," (field_expression) "gl->time" (identifier) "gl" (->) "->" (field_identifier) "time" ()) ")" (;) ";" (expression_statement) "codex->ACTIONPROCESSED=TRUE;" (assignment_expression) "codex->ACTIONPROCESSED=TRUE" (field_expression) "codex->ACTIONPROCESSED" (identifier) "codex" (->) "->" (field_identifier) "ACTIONPROCESSED" (=) "=" (true) "TRUE" (;) ";" (}) "}" (}) "}" (function_definition) "void init_cycle(char *argum, SOAP_codex_t *codexcontrol){\n np_t **np;\n gl_t *gl;\n\n np=((readcontrolarg_t *)codexcontrol->action_args)->np;\n gl=((readcontrolarg_t *)codexcontrol->action_args)->gl;\n\n resume_nodes_only_in_zone(*np, gl, _zone_intersection(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))));\n SOAP_copy_codex(codexcontrol,&(gl->cycle.codex));\n update_bdry_nodes(*np, gl, gl->domain);\n update_linked_nodes(*np, gl, TYPELEVEL_FLUID);\n find_residual(*np, gl, gl->domain);\n find_ximax(*np,gl,gl->domain,IJK_UPDATE_YES); \n gl->RESIDUAL_ALTERED=FALSE;\n}" (primitive_type) "void" (function_declarator) "init_cycle(char *argum, SOAP_codex_t *codexcontrol)" (identifier) "init_cycle" (parameter_list) "(char *argum, SOAP_codex_t *codexcontrol)" (() "(" (parameter_declaration) "char *argum" (primitive_type) "char" (pointer_declarator) "*argum" (*) "*" (identifier) "argum" (,) "," (parameter_declaration) "SOAP_codex_t *codexcontrol" (type_identifier) "SOAP_codex_t" (pointer_declarator) "*codexcontrol" (*) "*" (identifier) "codexcontrol" ()) ")" (compound_statement) "{\n np_t **np;\n gl_t *gl;\n\n np=((readcontrolarg_t *)codexcontrol->action_args)->np;\n gl=((readcontrolarg_t *)codexcontrol->action_args)->gl;\n\n resume_nodes_only_in_zone(*np, gl, _zone_intersection(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))));\n SOAP_copy_codex(codexcontrol,&(gl->cycle.codex));\n update_bdry_nodes(*np, gl, gl->domain);\n update_linked_nodes(*np, gl, TYPELEVEL_FLUID);\n find_residual(*np, gl, gl->domain);\n find_ximax(*np,gl,gl->domain,IJK_UPDATE_YES); \n gl->RESIDUAL_ALTERED=FALSE;\n}" ({) "{" (declaration) "np_t **np;" (type_identifier) "np_t" (pointer_declarator) "**np" (*) "*" (pointer_declarator) "*np" (*) "*" (identifier) "np" (;) ";" (declaration) "gl_t *gl;" (type_identifier) "gl_t" (pointer_declarator) "*gl" (*) "*" (identifier) "gl" (;) ";" (expression_statement) "np=((readcontrolarg_t *)codexcontrol->action_args)->np;" (assignment_expression) "np=((readcontrolarg_t *)codexcontrol->action_args)->np" (identifier) "np" (=) "=" (field_expression) "((readcontrolarg_t *)codexcontrol->action_args)->np" (parenthesized_expression) "((readcontrolarg_t *)codexcontrol->action_args)" (() "(" (cast_expression) "(readcontrolarg_t *)codexcontrol->action_args" (() "(" (type_descriptor) "readcontrolarg_t *" (type_identifier) "readcontrolarg_t" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (field_expression) "codexcontrol->action_args" (identifier) "codexcontrol" (->) "->" (field_identifier) "action_args" ()) ")" (->) "->" (field_identifier) "np" (;) ";" (expression_statement) "gl=((readcontrolarg_t *)codexcontrol->action_args)->gl;" (assignment_expression) "gl=((readcontrolarg_t *)codexcontrol->action_args)->gl" (identifier) "gl" (=) "=" (field_expression) "((readcontrolarg_t *)codexcontrol->action_args)->gl" (parenthesized_expression) "((readcontrolarg_t *)codexcontrol->action_args)" (() "(" (cast_expression) "(readcontrolarg_t *)codexcontrol->action_args" (() "(" (type_descriptor) "readcontrolarg_t *" (type_identifier) "readcontrolarg_t" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (field_expression) "codexcontrol->action_args" (identifier) "codexcontrol" (->) "->" (field_identifier) "action_args" ()) ")" (->) "->" (field_identifier) "gl" (;) ";" (expression_statement) "resume_nodes_only_in_zone(*np, gl, _zone_intersection(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))));" (call_expression) "resume_nodes_only_in_zone(*np, gl, _zone_intersection(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))))" (identifier) "resume_nodes_only_in_zone" (argument_list) "(*np, gl, _zone_intersection(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))))" (() "(" (pointer_expression) "*np" (*) "*" (identifier) "np" (,) "," (identifier) "gl" (,) "," (call_expression) "_zone_intersection(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid)))" (identifier) "_zone_intersection" (argument_list) "(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid)))" (() "(" (field_expression) "gl->domain_all" (identifier) "gl" (->) "->" (field_identifier) "domain_all" (,) "," (call_expression) "_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))" (identifier) "_zone_expansion" (argument_list) "(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))" (() "(" (field_expression) "gl->domain" (identifier) "gl" (->) "->" (field_identifier) "domain" (,) "," (unary_expression) "+max(hbw_res_fluid,hbw_bdry_fluid)" (+) "+" (call_expression) "max(hbw_res_fluid,hbw_bdry_fluid)" (identifier) "max" (argument_list) "(hbw_res_fluid,hbw_bdry_fluid)" (() "(" (identifier) "hbw_res_fluid" (,) "," (identifier) "hbw_bdry_fluid" ()) ")" ()) ")" ()) ")" ()) ")" (;) ";" (expression_statement) "SOAP_copy_codex(codexcontrol,&(gl->cycle.codex));" (call_expression) "SOAP_copy_codex(codexcontrol,&(gl->cycle.codex))" (identifier) "SOAP_copy_codex" (argument_list) "(codexcontrol,&(gl->cycle.codex))" (() "(" (identifier) "codexcontrol" (,) "," (pointer_expression) "&(gl->cycle.codex)" (&) "&" (parenthesized_expression) "(gl->cycle.codex)" (() "(" (field_expression) "gl->cycle.codex" (field_expression) "gl->cycle" (identifier) "gl" (->) "->" (field_identifier) "cycle" (.) "." (field_identifier) "codex" ()) ")" ()) ")" (;) ";" (expression_statement) "update_bdry_nodes(*np, gl, gl->domain);" (call_expression) "update_bdry_nodes(*np, gl, gl->domain)" (identifier) "update_bdry_nodes" (argument_list) "(*np, gl, gl->domain)" (() "(" (pointer_expression) "*np" (*) "*" (identifier) "np" (,) "," (identifier) "gl" (,) "," (field_expression) "gl->domain" (identifier) "gl" (->) "->" (field_identifier) "domain" ()) ")" (;) ";" (expression_statement) "update_linked_nodes(*np, gl, TYPELEVEL_FLUID);" (call_expression) "update_linked_nodes(*np, gl, TYPELEVEL_FLUID)" (identifier) "update_linked_nodes" (argument_list) "(*np, gl, TYPELEVEL_FLUID)" (() "(" (pointer_expression) "*np" (*) "*" (identifier) "np" (,) "," (identifier) "gl" (,) "," (identifier) "TYPELEVEL_FLUID" ()) ")" (;) ";" (expression_statement) "find_residual(*np, gl, gl->domain);" (call_expression) "find_residual(*np, gl, gl->domain)" (identifier) "find_residual" (argument_list) "(*np, gl, gl->domain)" (() "(" (pointer_expression) "*np" (*) "*" (identifier) "np" (,) "," (identifier) "gl" (,) "," (field_expression) "gl->domain" (identifier) "gl" (->) "->" (field_identifier) "domain" ()) ")" (;) ";" (expression_statement) "find_ximax(*np,gl,gl->domain,IJK_UPDATE_YES);" (call_expression) "find_ximax(*np,gl,gl->domain,IJK_UPDATE_YES)" (identifier) "find_ximax" (argument_list) "(*np,gl,gl->domain,IJK_UPDATE_YES)" (() "(" (pointer_expression) "*np" (*) "*" (identifier) "np" (,) "," (identifier) "gl" (,) "," (field_expression) "gl->domain" (identifier) "gl" (->) "->" (field_identifier) "domain" (,) "," (identifier) "IJK_UPDATE_YES" ()) ")" (;) ";" (expression_statement) "gl->RESIDUAL_ALTERED=FALSE;" (assignment_expression) "gl->RESIDUAL_ALTERED=FALSE" (field_expression) "gl->RESIDUAL_ALTERED" (identifier) "gl" (->) "->" (field_identifier) "RESIDUAL_ALTERED" (=) "=" (false) "FALSE" (;) ";" (}) "}" (function_definition) "void perform_one_iteration(np_t *np, gl_t *gl){\n\n\n process_code_runtime(np,gl,gl->cycle.code_runtime,&(gl->cycle.codex));\n\n\n}" (primitive_type) "void" (function_declarator) "perform_one_iteration(np_t *np, gl_t *gl)" (identifier) "perform_one_iteration" (parameter_list) "(np_t *np, gl_t *gl)" (() "(" (parameter_declaration) "np_t *np" (type_identifier) "np_t" (pointer_declarator) "*np" (*) "*" (identifier) "np" (,) "," (parameter_declaration) "gl_t *gl" (type_identifier) "gl_t" (pointer_declarator) "*gl" (*) "*" (identifier) "gl" ()) ")" (compound_statement) "{\n\n\n process_code_runtime(np,gl,gl->cycle.code_runtime,&(gl->cycle.codex));\n\n\n}" ({) "{" (expression_statement) "process_code_runtime(np,gl,gl->cycle.code_runtime,&(gl->cycle.codex));" (call_expression) "process_code_runtime(np,gl,gl->cycle.code_runtime,&(gl->cycle.codex))" (identifier) "process_code_runtime" (argument_list) "(np,gl,gl->cycle.code_runtime,&(gl->cycle.codex))" (() "(" (identifier) "np" (,) "," (identifier) "gl" (,) "," (field_expression) "gl->cycle.code_runtime" (field_expression) "gl->cycle" (identifier) "gl" (->) "->" (field_identifier) "cycle" (.) "." (field_identifier) "code_runtime" (,) "," (pointer_expression) "&(gl->cycle.codex)" (&) "&" (parenthesized_expression) "(gl->cycle.codex)" (() "(" (field_expression) "gl->cycle.codex" (field_expression) "gl->cycle" (identifier) "gl" (->) "->" (field_identifier) "cycle" (.) "." (field_identifier) "codex" ()) ")" ()) ")" (;) ";" (}) "}"
1,096
3
{"language": "c", "success": true, "metadata": {"lines": 142, "avg_line_length": 36.19, "nodes": 651, "errors": 0, "source_hash": "b4ce4a9bf794c5d343f934e4c1da6d9f73e6fe17f1145216db6b87ab3661d08b", "categorized_nodes": 493}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <cycle/ts/_ts.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 26, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<cycle/ts/_ts.h>", "parent": 0, "children": [], "start_point": {"row": 25, "column": 9}, "end_point": {"row": 25, "column": 25}}, {"id": 3, "type": "preproc_include", "text": "#include <cycle/tsemf/_tsemf.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 27, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<cycle/tsemf/_tsemf.h>", "parent": 3, "children": [], "start_point": {"row": 26, "column": 9}, "end_point": {"row": 26, "column": 31}}, {"id": 6, "type": "preproc_include", "text": "#include <cycle/res/_res.h>\n", "parent": null, "children": [7, 8], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 28, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<cycle/res/_res.h>", "parent": 6, "children": [], "start_point": {"row": 27, "column": 9}, "end_point": {"row": 27, "column": 27}}, {"id": 9, "type": "preproc_include", "text": "#include <cycle/_cycle.h>\n", "parent": null, "children": [10, 11], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 29, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<cycle/_cycle.h>", "parent": 9, "children": [], "start_point": {"row": 28, "column": 9}, "end_point": {"row": 28, "column": 25}}, {"id": 12, "type": "preproc_include", "text": "#include <cycle/share/cycle_share.h>\n", "parent": null, "children": [13, 14], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 30, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 8}}, {"id": 14, "type": "system_lib_string", "text": "<cycle/share/cycle_share.h>", "parent": 12, "children": [], "start_point": {"row": 29, "column": 9}, "end_point": {"row": 29, "column": 36}}, {"id": 15, "type": "preproc_include", "text": "#include <cycle/restime/_restime.h>\n", "parent": null, "children": [16, 17], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 31, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 8}}, {"id": 17, "type": "system_lib_string", "text": "<cycle/restime/_restime.h>", "parent": 15, "children": [], "start_point": {"row": 30, "column": 9}, "end_point": {"row": 30, "column": 35}}, {"id": 18, "type": "preproc_include", "text": "#include <src/bdry.h>\n", "parent": null, "children": [19, 20], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 32, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 31, "column": 8}}, {"id": 20, "type": "system_lib_string", "text": "<src/bdry.h>", "parent": 18, "children": [], "start_point": {"row": 31, "column": 9}, "end_point": {"row": 31, "column": 21}}, {"id": 21, "type": "preproc_ifdef", "text": "#ifdef EMFIELD\n#error The Predictor Corrector cycle can not be used with EMFIELD\n#endif", "parent": null, "children": [22, 23, 24, 27], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 35, "column": 6}}, {"id": 22, "type": "#ifdef", "text": "#ifdef", "parent": 21, "children": [], "start_point": {"row": 33, "column": 0}, "end_point": {"row": 33, "column": 6}}, {"id": 23, "type": "identifier", "text": "EMFIELD", "parent": 21, "children": [], "start_point": {"row": 33, "column": 7}, "end_point": {"row": 33, "column": 14}}, {"id": 24, "type": "preproc_call", "text": "#error The Predictor Corrector cycle can not be used with EMFIELD\n", "parent": 21, "children": [25, 26], "start_point": {"row": 34, "column": 0}, "end_point": {"row": 35, "column": 0}}, {"id": 25, "type": "preproc_directive", "text": "#error", "parent": 24, "children": [], "start_point": {"row": 34, "column": 0}, "end_point": {"row": 34, "column": 6}}, {"id": 26, "type": "preproc_arg", "text": "The Predictor Corrector cycle can not be used with EMFIELD", "parent": 24, "children": [], "start_point": {"row": 34, "column": 7}, "end_point": {"row": 34, "column": 65}}, {"id": 27, "type": "#endif", "text": "#endif", "parent": 21, "children": [], "start_point": {"row": 35, "column": 0}, "end_point": {"row": 35, "column": 6}}, {"id": 28, "type": "preproc_ifdef", "text": "#ifndef _RESTIME_PREDICTOR_CORRECTOR\n#error The Predictor Corrector cycle can only be used with a predictor corrector time discretization method (RK2, RK3, etc)\n#endif", "parent": null, "children": [29, 30, 31, 34], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 39, "column": 6}}, {"id": 29, "type": "#ifndef", "text": "#ifndef", "parent": 28, "children": [], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 37, "column": 7}}, {"id": 30, "type": "identifier", "text": "_RESTIME_PREDICTOR_CORRECTOR", "parent": 28, "children": [], "start_point": {"row": 37, "column": 8}, "end_point": {"row": 37, "column": 36}}, {"id": 31, "type": "preproc_call", "text": "#error The Predictor Corrector cycle can only be used with a predictor corrector time discretization method (RK2, RK3, etc)\n", "parent": 28, "children": [32, 33], "start_point": {"row": 38, "column": 0}, "end_point": {"row": 39, "column": 0}}, {"id": 32, "type": "preproc_directive", "text": "#error", "parent": 31, "children": [], "start_point": {"row": 38, "column": 0}, "end_point": {"row": 38, "column": 6}}, {"id": 33, "type": "preproc_arg", "text": "The Predictor Corrector cycle can only be used with a predictor corrector time discretization method (RK2, RK3, etc)", "parent": 31, "children": [], "start_point": {"row": 38, "column": 7}, "end_point": {"row": 38, "column": 123}}, {"id": 34, "type": "#endif", "text": "#endif", "parent": 28, "children": [], "start_point": {"row": 39, "column": 0}, "end_point": {"row": 39, "column": 6}}, {"id": 35, "type": "function_definition", "text": "void write_runtime_template(FILE **controlfile){\n wfprintf(*controlfile,\n \" %s(\\n\",_CYCLE_ACTIONNAME);\n wfprintf(*controlfile,\n \" tmax=1e-4; {simulation time span in seconds}\\n\"\n \" dt=tmax/30; {physical time step in seconds}\\n\"\n );\n wfprintf(*controlfile,\n \" if (time>tmax-0.1*dt,\\n\"\n \" WriteDataFile(outputfilename\\\".\\\"round(time/dt));\\n\"\n \" exit(EXIT_SUCCESS);\\n\"\n \" );\\n\"\n \" if (mod(iter,50)==1,\\n\"\n \" WriteDataFile(outputfilename\\\".\\\"round(time/dt));\\n\"\n \" );\\n\"\n );\n wfprintf(*controlfile,\n \" UpdateFluid(dt);\\n\"\n \" printf(\\\"%%E %%6ld %%9.3f %%E (%%4ld\"\n#ifdef _2DL\n \",%%4ld\"\n#endif\n#ifdef _3DL\n \",%%4ld\"\n#endif\n \")\"\n \" %%s\\\\n\\\",\\n\"\n \" time,iter,effiter_U,ximax,i_ximax,\\n\"\n \" \"\n#ifdef _2DL\n \"j_ximax,\"\n#endif\n#ifdef _3DL\n \"k_ximax,\"\n#endif\n \"clipinfo);\\n\");\n\n\n wfprintf(*controlfile,\n \" );\\n\");\n\n}", "parent": null, "children": [36, 37], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 82, "column": 1}}, {"id": 36, "type": "primitive_type", "text": "void", "parent": 35, "children": [], "start_point": {"row": 41, "column": 0}, "end_point": {"row": 41, "column": 4}}, {"id": 37, "type": "function_declarator", "text": "write_runtime_template(FILE **controlfile)", "parent": 35, "children": [38, 39], "start_point": {"row": 41, "column": 5}, "end_point": {"row": 41, "column": 47}}, {"id": 38, "type": "identifier", "text": "write_runtime_template", "parent": 37, "children": [], "start_point": {"row": 41, "column": 5}, "end_point": {"row": 41, "column": 27}}, {"id": 39, "type": "parameter_list", "text": "(FILE **controlfile)", "parent": 37, "children": [40], "start_point": {"row": 41, "column": 27}, "end_point": {"row": 41, "column": 47}}, {"id": 40, "type": "parameter_declaration", "text": "FILE **controlfile", "parent": 39, "children": [41, 42], "start_point": {"row": 41, "column": 28}, "end_point": {"row": 41, "column": 46}}, {"id": 41, "type": "type_identifier", "text": "FILE", "parent": 40, "children": [], "start_point": {"row": 41, "column": 28}, "end_point": {"row": 41, "column": 32}}, {"id": 42, "type": "pointer_declarator", "text": "**controlfile", "parent": 40, "children": [43, 44], "start_point": {"row": 41, "column": 33}, "end_point": {"row": 41, "column": 46}}, {"id": 43, "type": "*", "text": "*", "parent": 42, "children": [], "start_point": {"row": 41, "column": 33}, "end_point": {"row": 41, "column": 34}}, {"id": 44, "type": "pointer_declarator", "text": "*controlfile", "parent": 42, "children": [45, 46], "start_point": {"row": 41, "column": 34}, "end_point": {"row": 41, "column": 46}}, {"id": 45, "type": "*", "text": "*", "parent": 44, "children": [], "start_point": {"row": 41, "column": 34}, "end_point": {"row": 41, "column": 35}}, {"id": 46, "type": "identifier", "text": "controlfile", "parent": 44, "children": [], "start_point": {"row": 41, "column": 35}, "end_point": {"row": 41, "column": 46}}, {"id": 47, "type": "call_expression", "text": "wfprintf(*controlfile,\n \" %s(\\n\",_CYCLE_ACTIONNAME)", "parent": 35, "children": [48, 49], "start_point": {"row": 42, "column": 2}, "end_point": {"row": 43, "column": 30}}, {"id": 48, "type": "identifier", "text": "wfprintf", "parent": 47, "children": [], "start_point": {"row": 42, "column": 2}, "end_point": {"row": 42, "column": 10}}, {"id": 49, "type": "argument_list", "text": "(*controlfile,\n \" %s(\\n\",_CYCLE_ACTIONNAME)", "parent": 47, "children": [50, 53, 55], "start_point": {"row": 42, "column": 10}, "end_point": {"row": 43, "column": 30}}, {"id": 50, "type": "pointer_expression", "text": "*controlfile", "parent": 49, "children": [51, 52], "start_point": {"row": 42, "column": 11}, "end_point": {"row": 42, "column": 23}}, {"id": 51, "type": "*", "text": "*", "parent": 50, "children": [], "start_point": {"row": 42, "column": 11}, "end_point": {"row": 42, "column": 12}}, {"id": 52, "type": "identifier", "text": "controlfile", "parent": 50, "children": [], "start_point": {"row": 42, "column": 12}, "end_point": {"row": 42, "column": 23}}, {"id": 53, "type": "string_literal", "text": "\" %s(\\n\"", "parent": 49, "children": [54], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 43, "column": 11}}, {"id": 54, "type": "escape_sequence", "text": "\\n", "parent": 53, "children": [], "start_point": {"row": 43, "column": 8}, "end_point": {"row": 43, "column": 10}}, {"id": 55, "type": "identifier", "text": "_CYCLE_ACTIONNAME", "parent": 49, "children": [], "start_point": {"row": 43, "column": 12}, "end_point": {"row": 43, "column": 29}}, {"id": 56, "type": "call_expression", "text": "wfprintf(*controlfile,\n \" tmax=1e-4; {simulation time span in seconds}\\n\"\n \" dt=tmax/30; {physical time step in seconds}\\n\"\n )", "parent": 35, "children": [57, 58], "start_point": {"row": 44, "column": 2}, "end_point": {"row": 47, "column": 3}}, {"id": 57, "type": "identifier", "text": "wfprintf", "parent": 56, "children": [], "start_point": {"row": 44, "column": 2}, "end_point": {"row": 44, "column": 10}}, {"id": 58, "type": "argument_list", "text": "(*controlfile,\n \" tmax=1e-4; {simulation time span in seconds}\\n\"\n \" dt=tmax/30; {physical time step in seconds}\\n\"\n )", "parent": 56, "children": [59, 62], "start_point": {"row": 44, "column": 10}, "end_point": {"row": 47, "column": 3}}, {"id": 59, "type": "pointer_expression", "text": "*controlfile", "parent": 58, "children": [60, 61], "start_point": {"row": 44, "column": 11}, "end_point": {"row": 44, "column": 23}}, {"id": 60, "type": "*", "text": "*", "parent": 59, "children": [], "start_point": {"row": 44, "column": 11}, "end_point": {"row": 44, "column": 12}}, {"id": 61, "type": "identifier", "text": "controlfile", "parent": 59, "children": [], "start_point": {"row": 44, "column": 12}, "end_point": {"row": 44, "column": 23}}, {"id": 62, "type": "concatenated_string", "text": "\" tmax=1e-4; {simulation time span in seconds}\\n\"\n \" dt=tmax/30; {physical time step in seconds}\\n\"", "parent": 58, "children": [63, 65], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 46, "column": 55}}, {"id": 63, "type": "string_literal", "text": "\" tmax=1e-4; {simulation time span in seconds}\\n\"", "parent": 62, "children": [64], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 57}}, {"id": 64, "type": "escape_sequence", "text": "\\n", "parent": 63, "children": [], "start_point": {"row": 45, "column": 54}, "end_point": {"row": 45, "column": 56}}, {"id": 65, "type": "string_literal", "text": "\" dt=tmax/30; {physical time step in seconds}\\n\"", "parent": 62, "children": [66], "start_point": {"row": 46, "column": 2}, "end_point": {"row": 46, "column": 55}}, {"id": 66, "type": "escape_sequence", "text": "\\n", "parent": 65, "children": [], "start_point": {"row": 46, "column": 52}, "end_point": {"row": 46, "column": 54}}, {"id": 67, "type": "call_expression", "text": "wfprintf(*controlfile,\n \" if (time>tmax-0.1*dt,\\n\"\n \" WriteDataFile(outputfilename\\\".\\\"round(time/dt));\\n\"\n \" exit(EXIT_SUCCESS);\\n\"\n \" );\\n\"\n \" if (mod(iter,50)==1,\\n\"\n \" WriteDataFile(outputfilename\\\".\\\"round(time/dt));\\n\"\n \" );\\n\"\n )", "parent": 35, "children": [68, 69], "start_point": {"row": 48, "column": 2}, "end_point": {"row": 56, "column": 3}}, {"id": 68, "type": "identifier", "text": "wfprintf", "parent": 67, "children": [], "start_point": {"row": 48, "column": 2}, "end_point": {"row": 48, "column": 10}}, {"id": 69, "type": "argument_list", "text": "(*controlfile,\n \" if (time>tmax-0.1*dt,\\n\"\n \" WriteDataFile(outputfilename\\\".\\\"round(time/dt));\\n\"\n \" exit(EXIT_SUCCESS);\\n\"\n \" );\\n\"\n \" if (mod(iter,50)==1,\\n\"\n \" WriteDataFile(outputfilename\\\".\\\"round(time/dt));\\n\"\n \" );\\n\"\n )", "parent": 67, "children": [70, 73], "start_point": {"row": 48, "column": 10}, "end_point": {"row": 56, "column": 3}}, {"id": 70, "type": "pointer_expression", "text": "*controlfile", "parent": 69, "children": [71, 72], "start_point": {"row": 48, "column": 11}, "end_point": {"row": 48, "column": 23}}, {"id": 71, "type": "*", "text": "*", "parent": 70, "children": [], "start_point": {"row": 48, "column": 11}, "end_point": {"row": 48, "column": 12}}, {"id": 72, "type": "identifier", "text": "controlfile", "parent": 70, "children": [], "start_point": {"row": 48, "column": 12}, "end_point": {"row": 48, "column": 23}}, {"id": 73, "type": "concatenated_string", "text": "\" if (time>tmax-0.1*dt,\\n\"\n \" WriteDataFile(outputfilename\\\".\\\"round(time/dt));\\n\"\n \" exit(EXIT_SUCCESS);\\n\"\n \" );\\n\"\n \" if (mod(iter,50)==1,\\n\"\n \" WriteDataFile(outputfilename\\\".\\\"round(time/dt));\\n\"\n \" );\\n\"", "parent": 69, "children": [74, 76, 80, 82, 84, 86, 90], "start_point": {"row": 49, "column": 2}, "end_point": {"row": 55, "column": 12}}, {"id": 74, "type": "string_literal", "text": "\" if (time>tmax-0.1*dt,\\n\"", "parent": 73, "children": [75], "start_point": {"row": 49, "column": 2}, "end_point": {"row": 49, "column": 31}}, {"id": 75, "type": "escape_sequence", "text": "\\n", "parent": 74, "children": [], "start_point": {"row": 49, "column": 28}, "end_point": {"row": 49, "column": 30}}, {"id": 76, "type": "string_literal", "text": "\" WriteDataFile(outputfilename\\\".\\\"round(time/dt));\\n\"", "parent": 73, "children": [77, 78, 79], "start_point": {"row": 50, "column": 2}, "end_point": {"row": 50, "column": 61}}, {"id": 77, "type": "escape_sequence", "text": "\\\"", "parent": 76, "children": [], "start_point": {"row": 50, "column": 37}, "end_point": {"row": 50, "column": 39}}, {"id": 78, "type": "escape_sequence", "text": "\\\"", "parent": 76, "children": [], "start_point": {"row": 50, "column": 40}, "end_point": {"row": 50, "column": 42}}, {"id": 79, "type": "escape_sequence", "text": "\\n", "parent": 76, "children": [], "start_point": {"row": 50, "column": 58}, "end_point": {"row": 50, "column": 60}}, {"id": 80, "type": "string_literal", "text": "\" exit(EXIT_SUCCESS);\\n\"", "parent": 73, "children": [81], "start_point": {"row": 51, "column": 2}, "end_point": {"row": 51, "column": 31}}, {"id": 81, "type": "escape_sequence", "text": "\\n", "parent": 80, "children": [], "start_point": {"row": 51, "column": 28}, "end_point": {"row": 51, "column": 30}}, {"id": 82, "type": "string_literal", "text": "\" );\\n\"", "parent": 73, "children": [83], "start_point": {"row": 52, "column": 2}, "end_point": {"row": 52, "column": 12}}, {"id": 83, "type": "escape_sequence", "text": "\\n", "parent": 82, "children": [], "start_point": {"row": 52, "column": 9}, "end_point": {"row": 52, "column": 11}}, {"id": 84, "type": "string_literal", "text": "\" if (mod(iter,50)==1,\\n\"", "parent": 73, "children": [85], "start_point": {"row": 53, "column": 2}, "end_point": {"row": 53, "column": 30}}, {"id": 85, "type": "escape_sequence", "text": "\\n", "parent": 84, "children": [], "start_point": {"row": 53, "column": 27}, "end_point": {"row": 53, "column": 29}}, {"id": 86, "type": "string_literal", "text": "\" WriteDataFile(outputfilename\\\".\\\"round(time/dt));\\n\"", "parent": 73, "children": [87, 88, 89], "start_point": {"row": 54, "column": 2}, "end_point": {"row": 54, "column": 61}}, {"id": 87, "type": "escape_sequence", "text": "\\\"", "parent": 86, "children": [], "start_point": {"row": 54, "column": 37}, "end_point": {"row": 54, "column": 39}}, {"id": 88, "type": "escape_sequence", "text": "\\\"", "parent": 86, "children": [], "start_point": {"row": 54, "column": 40}, "end_point": {"row": 54, "column": 42}}, {"id": 89, "type": "escape_sequence", "text": "\\n", "parent": 86, "children": [], "start_point": {"row": 54, "column": 58}, "end_point": {"row": 54, "column": 60}}, {"id": 90, "type": "string_literal", "text": "\" );\\n\"", "parent": 73, "children": [91], "start_point": {"row": 55, "column": 2}, "end_point": {"row": 55, "column": 12}}, {"id": 91, "type": "escape_sequence", "text": "\\n", "parent": 90, "children": [], "start_point": {"row": 55, "column": 9}, "end_point": {"row": 55, "column": 11}}, {"id": 92, "type": "call_expression", "text": "wfprintf(*controlfile,\n \" UpdateFluid(dt);\\n\"\n \" printf(\\\"%%E %%6ld %%9.3f %%E (%%4ld\"\n#ifdef _2DL\n \",%%4ld\"\n#endif\n#ifdef _3DL\n \",%%4ld\"\n#endif\n \")\"\n \" %%s\\\\n\\\",\\n\"\n \" time,iter,effiter_U,ximax,i_ximax,\\n\"\n \" \"\n#ifdef _2DL\n \"j_ximax,\"\n#endif\n#ifdef _3DL\n \"k_ximax,\"\n#endif\n \"clipinfo);\\n\")", "parent": 35, "children": [93, 94], "start_point": {"row": 57, "column": 2}, "end_point": {"row": 76, "column": 33}}, {"id": 93, "type": "identifier", "text": "wfprintf", "parent": 92, "children": [], "start_point": {"row": 57, "column": 2}, "end_point": {"row": 57, "column": 10}}, {"id": 94, "type": "argument_list", "text": "(*controlfile,\n \" UpdateFluid(dt);\\n\"\n \" printf(\\\"%%E %%6ld %%9.3f %%E (%%4ld\"\n#ifdef _2DL\n \",%%4ld\"\n#endif\n#ifdef _3DL\n \",%%4ld\"\n#endif\n \")\"\n \" %%s\\\\n\\\",\\n\"\n \" time,iter,effiter_U,ximax,i_ximax,\\n\"\n \" \"\n#ifdef _2DL\n \"j_ximax,\"\n#endif\n#ifdef _3DL\n \"k_ximax,\"\n#endif\n \"clipinfo);\\n\")", "parent": 92, "children": [95, 98, 133], "start_point": {"row": 57, "column": 10}, "end_point": {"row": 76, "column": 33}}, {"id": 95, "type": "pointer_expression", "text": "*controlfile", "parent": 94, "children": [96, 97], "start_point": {"row": 57, "column": 11}, "end_point": {"row": 57, "column": 23}}, {"id": 96, "type": "*", "text": "*", "parent": 95, "children": [], "start_point": {"row": 57, "column": 11}, "end_point": {"row": 57, "column": 12}}, {"id": 97, "type": "identifier", "text": "controlfile", "parent": 95, "children": [], "start_point": {"row": 57, "column": 12}, "end_point": {"row": 57, "column": 23}}, {"id": 98, "type": "ERROR", "text": "\" UpdateFluid(dt);\\n\"\n \" printf(\\\"%%E %%6ld %%9.3f %%E (%%4ld\"\n#ifdef _2DL\n \",%%4ld\"\n#endif\n#ifdef _3DL\n \",%%4ld\"\n#endif\n \")\"\n \" %%s\\\\n\\\",\\n\"\n \" time,iter,effiter_U,ximax,i_ximax,\\n\"\n \" \"\n#ifdef _2DL\n \"j_ximax,\"\n#endif\n#ifdef _3DL\n \"k_ximax,\"\n#endif", "parent": 94, "children": [99, 108, 109, 110, 113, 114, 127, 128, 129, 132], "start_point": {"row": 58, "column": 2}, "end_point": {"row": 75, "column": 6}}, {"id": 99, "type": "concatenated_string", "text": "\" UpdateFluid(dt);\\n\"\n \" printf(\\\"%%E %%6ld %%9.3f %%E (%%4ld\"\n#ifdef _2DL\n \",%%4ld\"", "parent": 98, "children": [100, 102, 104, 106, 107], "start_point": {"row": 58, "column": 2}, "end_point": {"row": 61, "column": 26}}, {"id": 100, "type": "string_literal", "text": "\" UpdateFluid(dt);\\n\"", "parent": 99, "children": [101], "start_point": {"row": 58, "column": 2}, "end_point": {"row": 58, "column": 26}}, {"id": 101, "type": "escape_sequence", "text": "\\n", "parent": 100, "children": [], "start_point": {"row": 58, "column": 23}, "end_point": {"row": 58, "column": 25}}, {"id": 102, "type": "string_literal", "text": "\" printf(\\\"%%E %%6ld %%9.3f %%E (%%4ld\"", "parent": 99, "children": [103], "start_point": {"row": 59, "column": 2}, "end_point": {"row": 59, "column": 46}}, {"id": 103, "type": "escape_sequence", "text": "\\\"", "parent": 102, "children": [], "start_point": {"row": 59, "column": 14}, "end_point": {"row": 59, "column": 16}}, {"id": 104, "type": "ERROR", "text": "#ifdef", "parent": 99, "children": [105], "start_point": {"row": 60, "column": 0}, "end_point": {"row": 60, "column": 6}}, {"id": 105, "type": "#ifdef", "text": "#ifdef", "parent": 104, "children": [], "start_point": {"row": 60, "column": 0}, "end_point": {"row": 60, "column": 6}}, {"id": 106, "type": "identifier", "text": "_2DL", "parent": 99, "children": [], "start_point": {"row": 60, "column": 7}, "end_point": {"row": 60, "column": 11}}, {"id": 107, "type": "string_literal", "text": "\",%%4ld\"", "parent": 99, "children": [], "start_point": {"row": 61, "column": 18}, "end_point": {"row": 61, "column": 26}}, {"id": 108, "type": "#endif", "text": "#endif", "parent": 98, "children": [], "start_point": {"row": 62, "column": 0}, "end_point": {"row": 62, "column": 6}}, {"id": 109, "type": "#ifdef", "text": "#ifdef", "parent": 98, "children": [], "start_point": {"row": 63, "column": 0}, "end_point": {"row": 63, "column": 6}}, {"id": 110, "type": "concatenated_string", "text": "_3DL\n \",%%4ld\"", "parent": 98, "children": [111, 112], "start_point": {"row": 63, "column": 7}, "end_point": {"row": 64, "column": 26}}, {"id": 111, "type": "identifier", "text": "_3DL", "parent": 110, "children": [], "start_point": {"row": 63, "column": 7}, "end_point": {"row": 63, "column": 11}}, {"id": 112, "type": "string_literal", "text": "\",%%4ld\"", "parent": 110, "children": [], "start_point": {"row": 64, "column": 18}, "end_point": {"row": 64, "column": 26}}, {"id": 113, "type": "#endif", "text": "#endif", "parent": 98, "children": [], "start_point": {"row": 65, "column": 0}, "end_point": {"row": 65, "column": 6}}, {"id": 114, "type": "concatenated_string", "text": "\")\"\n \" %%s\\\\n\\\",\\n\"\n \" time,iter,effiter_U,ximax,i_ximax,\\n\"\n \" \"\n#ifdef _2DL\n \"j_ximax,\"", "parent": 98, "children": [115, 116, 120, 122, 123, 125, 126], "start_point": {"row": 66, "column": 18}, "end_point": {"row": 71, "column": 28}}, {"id": 115, "type": "string_literal", "text": "\")\"", "parent": 114, "children": [], "start_point": {"row": 66, "column": 18}, "end_point": {"row": 66, "column": 21}}, {"id": 116, "type": "string_literal", "text": "\" %%s\\\\n\\\",\\n\"", "parent": 114, "children": [117, 118, 119], "start_point": {"row": 67, "column": 18}, "end_point": {"row": 67, "column": 33}}, {"id": 117, "type": "escape_sequence", "text": "\\\\", "parent": 116, "children": [], "start_point": {"row": 67, "column": 24}, "end_point": {"row": 67, "column": 26}}, {"id": 118, "type": "escape_sequence", "text": "\\\"", "parent": 116, "children": [], "start_point": {"row": 67, "column": 27}, "end_point": {"row": 67, "column": 29}}, {"id": 119, "type": "escape_sequence", "text": "\\n", "parent": 116, "children": [], "start_point": {"row": 67, "column": 30}, "end_point": {"row": 67, "column": 32}}, {"id": 120, "type": "string_literal", "text": "\" time,iter,effiter_U,ximax,i_ximax,\\n\"", "parent": 114, "children": [121], "start_point": {"row": 68, "column": 2}, "end_point": {"row": 68, "column": 51}}, {"id": 121, "type": "escape_sequence", "text": "\\n", "parent": 120, "children": [], "start_point": {"row": 68, "column": 48}, "end_point": {"row": 68, "column": 50}}, {"id": 122, "type": "string_literal", "text": "\" \"", "parent": 114, "children": [], "start_point": {"row": 69, "column": 2}, "end_point": {"row": 69, "column": 15}}, {"id": 123, "type": "ERROR", "text": "#ifdef", "parent": 114, "children": [124], "start_point": {"row": 70, "column": 0}, "end_point": {"row": 70, "column": 6}}, {"id": 124, "type": "#ifdef", "text": "#ifdef", "parent": 123, "children": [], "start_point": {"row": 70, "column": 0}, "end_point": {"row": 70, "column": 6}}, {"id": 125, "type": "identifier", "text": "_2DL", "parent": 114, "children": [], "start_point": {"row": 70, "column": 7}, "end_point": {"row": 70, "column": 11}}, {"id": 126, "type": "string_literal", "text": "\"j_ximax,\"", "parent": 114, "children": [], "start_point": {"row": 71, "column": 18}, "end_point": {"row": 71, "column": 28}}, {"id": 127, "type": "#endif", "text": "#endif", "parent": 98, "children": [], "start_point": {"row": 72, "column": 0}, "end_point": {"row": 72, "column": 6}}, {"id": 128, "type": "#ifdef", "text": "#ifdef", "parent": 98, "children": [], "start_point": {"row": 73, "column": 0}, "end_point": {"row": 73, "column": 6}}, {"id": 129, "type": "concatenated_string", "text": "_3DL\n \"k_ximax,\"", "parent": 98, "children": [130, 131], "start_point": {"row": 73, "column": 7}, "end_point": {"row": 74, "column": 28}}, {"id": 130, "type": "identifier", "text": "_3DL", "parent": 129, "children": [], "start_point": {"row": 73, "column": 7}, "end_point": {"row": 73, "column": 11}}, {"id": 131, "type": "string_literal", "text": "\"k_ximax,\"", "parent": 129, "children": [], "start_point": {"row": 74, "column": 18}, "end_point": {"row": 74, "column": 28}}, {"id": 132, "type": "#endif", "text": "#endif", "parent": 98, "children": [], "start_point": {"row": 75, "column": 0}, "end_point": {"row": 75, "column": 6}}, {"id": 133, "type": "string_literal", "text": "\"clipinfo);\\n\"", "parent": 94, "children": [134], "start_point": {"row": 76, "column": 18}, "end_point": {"row": 76, "column": 32}}, {"id": 134, "type": "escape_sequence", "text": "\\n", "parent": 133, "children": [], "start_point": {"row": 76, "column": 29}, "end_point": {"row": 76, "column": 31}}, {"id": 135, "type": "call_expression", "text": "wfprintf(*controlfile,\n \" );\\n\")", "parent": 35, "children": [136, 137], "start_point": {"row": 79, "column": 2}, "end_point": {"row": 80, "column": 11}}, {"id": 136, "type": "identifier", "text": "wfprintf", "parent": 135, "children": [], "start_point": {"row": 79, "column": 2}, "end_point": {"row": 79, "column": 10}}, {"id": 137, "type": "argument_list", "text": "(*controlfile,\n \" );\\n\")", "parent": 135, "children": [138, 141], "start_point": {"row": 79, "column": 10}, "end_point": {"row": 80, "column": 11}}, {"id": 138, "type": "pointer_expression", "text": "*controlfile", "parent": 137, "children": [139, 140], "start_point": {"row": 79, "column": 11}, "end_point": {"row": 79, "column": 23}}, {"id": 139, "type": "*", "text": "*", "parent": 138, "children": [], "start_point": {"row": 79, "column": 11}, "end_point": {"row": 79, "column": 12}}, {"id": 140, "type": "identifier", "text": "controlfile", "parent": 138, "children": [], "start_point": {"row": 79, "column": 12}, "end_point": {"row": 79, "column": 23}}, {"id": 141, "type": "string_literal", "text": "\" );\\n\"", "parent": 137, "children": [142], "start_point": {"row": 80, "column": 2}, "end_point": {"row": 80, "column": 10}}, {"id": 142, "type": "escape_sequence", "text": "\\n", "parent": 141, "children": [], "start_point": {"row": 80, "column": 7}, "end_point": {"row": 80, "column": 9}}, {"id": 143, "type": "function_definition", "text": "void runtime_actions_cycle_specific(char *actionname, char **argum, SOAP_codex_t *codex){\n#ifdef DISTMPI\n double delta_effiter_U,effiter_U_mem,delta_effiter_U_max;\n#endif\n long l,flux,i,j,k;\n gl_t *gl;\n np_t *np;\n\n\n np=*((readcontrolarg_t *)codex->action_args)->np;\n gl=((readcontrolarg_t *)codex->action_args)->gl;\n\n if (strcmp(actionname,\"UpdateFluid\")==0) {\n SOAP_substitute_all_argums(argum, codex);\n if (SOAP_number_argums(*argum)!=1) SOAP_fatal_error(codex,\"Number of arguments not equal to 1 in UpdateFluid(); action.\");\n gl->dt=SOAP_get_argum_double(codex,*argum,0);\n if (gl->dt<=0.0) fatal_error(\"The time step dt must be positive when calling UpdateFluid.\");\n for_ijk(gl->domain_lim,is,js,ks,ie,je,ke){\n l=_ai(gl,i,j,k);\n if ((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))){\n for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }\n }\n }\n\n for (gl->subiter_pc=0; gl->subiter_pc<gl->numsubiter_pc; gl->subiter_pc++){\n update_bdry_nodes(np,gl,gl->domain); \n find_residual(np, gl, gl->domain);\n find_ximax(np, gl, gl->domain, IJK_UPDATE_YES);\n#ifdef DISTMPI\n effiter_U_mem=gl->effiter_U;\n#endif\n update_U_predictor_corrector(np, gl, gl->domain);\n update_linked_nodes(np, gl, TYPELEVEL_FLUID);\n#ifdef DISTMPI\n exchange_U(np, gl);\n delta_effiter_U=gl->effiter_U-effiter_U_mem;\n MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);\n gl->effiter_U=effiter_U_mem+delta_effiter_U_max;\n#endif\n }\n gl->time+=gl->dt;\n update_runtime_codex_xi_from_gl(gl,codex);\n add_double_to_codex(codex,\"time\",gl->time); \n codex->ACTIONPROCESSED=TRUE;\n }\n\n\n}", "parent": null, "children": [144, 145], "start_point": {"row": 86, "column": 0}, "end_point": {"row": 135, "column": 1}}, {"id": 144, "type": "primitive_type", "text": "void", "parent": 143, "children": [], "start_point": {"row": 86, "column": 0}, "end_point": {"row": 86, "column": 4}}, {"id": 145, "type": "function_declarator", "text": "runtime_actions_cycle_specific(char *actionname, char **argum, SOAP_codex_t *codex)", "parent": 143, "children": [146, 147], "start_point": {"row": 86, "column": 5}, "end_point": {"row": 86, "column": 88}}, {"id": 146, "type": "identifier", "text": "runtime_actions_cycle_specific", "parent": 145, "children": [], "start_point": {"row": 86, "column": 5}, "end_point": {"row": 86, "column": 35}}, {"id": 147, "type": "parameter_list", "text": "(char *actionname, char **argum, SOAP_codex_t *codex)", "parent": 145, "children": [148, 153, 160], "start_point": {"row": 86, "column": 35}, "end_point": {"row": 86, "column": 88}}, {"id": 148, "type": "parameter_declaration", "text": "char *actionname", "parent": 147, "children": [149, 150], "start_point": {"row": 86, "column": 36}, "end_point": {"row": 86, "column": 52}}, {"id": 149, "type": "primitive_type", "text": "char", "parent": 148, "children": [], "start_point": {"row": 86, "column": 36}, "end_point": {"row": 86, "column": 40}}, {"id": 150, "type": "pointer_declarator", "text": "*actionname", "parent": 148, "children": [151, 152], "start_point": {"row": 86, "column": 41}, "end_point": {"row": 86, "column": 52}}, {"id": 151, "type": "*", "text": "*", "parent": 150, "children": [], "start_point": {"row": 86, "column": 41}, "end_point": {"row": 86, "column": 42}}, {"id": 152, "type": "identifier", "text": "actionname", "parent": 150, "children": [], "start_point": {"row": 86, "column": 42}, "end_point": {"row": 86, "column": 52}}, {"id": 153, "type": "parameter_declaration", "text": "char **argum", "parent": 147, "children": [154, 155], "start_point": {"row": 86, "column": 54}, "end_point": {"row": 86, "column": 66}}, {"id": 154, "type": "primitive_type", "text": "char", "parent": 153, "children": [], "start_point": {"row": 86, "column": 54}, "end_point": {"row": 86, "column": 58}}, {"id": 155, "type": "pointer_declarator", "text": "**argum", "parent": 153, "children": [156, 157], "start_point": {"row": 86, "column": 59}, "end_point": {"row": 86, "column": 66}}, {"id": 156, "type": "*", "text": "*", "parent": 155, "children": [], "start_point": {"row": 86, "column": 59}, "end_point": {"row": 86, "column": 60}}, {"id": 157, "type": "pointer_declarator", "text": "*argum", "parent": 155, "children": [158, 159], "start_point": {"row": 86, "column": 60}, "end_point": {"row": 86, "column": 66}}, {"id": 158, "type": "*", "text": "*", "parent": 157, "children": [], "start_point": {"row": 86, "column": 60}, "end_point": {"row": 86, "column": 61}}, {"id": 159, "type": "identifier", "text": "argum", "parent": 157, "children": [], "start_point": {"row": 86, "column": 61}, "end_point": {"row": 86, "column": 66}}, {"id": 160, "type": "parameter_declaration", "text": "SOAP_codex_t *codex", "parent": 147, "children": [161, 162], "start_point": {"row": 86, "column": 68}, "end_point": {"row": 86, "column": 87}}, {"id": 161, "type": "type_identifier", "text": "SOAP_codex_t", "parent": 160, "children": [], "start_point": {"row": 86, "column": 68}, "end_point": {"row": 86, "column": 80}}, {"id": 162, "type": "pointer_declarator", "text": "*codex", "parent": 160, "children": [163, 164], "start_point": {"row": 86, "column": 81}, "end_point": {"row": 86, "column": 87}}, {"id": 163, "type": "*", "text": "*", "parent": 162, "children": [], "start_point": {"row": 86, "column": 81}, "end_point": {"row": 86, "column": 82}}, {"id": 164, "type": "identifier", "text": "codex", "parent": 162, "children": [], "start_point": {"row": 86, "column": 82}, "end_point": {"row": 86, "column": 87}}, {"id": 165, "type": "preproc_ifdef", "text": "#ifdef DISTMPI\n double delta_effiter_U,effiter_U_mem,delta_effiter_U_max;\n#endif", "parent": 143, "children": [166, 167, 168, 173], "start_point": {"row": 87, "column": 0}, "end_point": {"row": 89, "column": 6}}, {"id": 166, "type": "#ifdef", "text": "#ifdef", "parent": 165, "children": [], "start_point": {"row": 87, "column": 0}, "end_point": {"row": 87, "column": 6}}, {"id": 167, "type": "identifier", "text": "DISTMPI", "parent": 165, "children": [], "start_point": {"row": 87, "column": 7}, "end_point": {"row": 87, "column": 14}}, {"id": 168, "type": "declaration", "text": "double delta_effiter_U,effiter_U_mem,delta_effiter_U_max;", "parent": 165, "children": [169, 170, 171, 172], "start_point": {"row": 88, "column": 2}, "end_point": {"row": 88, "column": 59}}, {"id": 169, "type": "primitive_type", "text": "double", "parent": 168, "children": [], "start_point": {"row": 88, "column": 2}, "end_point": {"row": 88, "column": 8}}, {"id": 170, "type": "identifier", "text": "delta_effiter_U", "parent": 168, "children": [], "start_point": {"row": 88, "column": 9}, "end_point": {"row": 88, "column": 24}}, {"id": 171, "type": "identifier", "text": "effiter_U_mem", "parent": 168, "children": [], "start_point": {"row": 88, "column": 25}, "end_point": {"row": 88, "column": 38}}, {"id": 172, "type": "identifier", "text": "delta_effiter_U_max", "parent": 168, "children": [], "start_point": {"row": 88, "column": 39}, "end_point": {"row": 88, "column": 58}}, {"id": 173, "type": "#endif", "text": "#endif", "parent": 165, "children": [], "start_point": {"row": 89, "column": 0}, "end_point": {"row": 89, "column": 6}}, {"id": 174, "type": "declaration", "text": "long l,flux,i,j,k;", "parent": 143, "children": [175, 177, 178, 179, 180, 181], "start_point": {"row": 90, "column": 2}, "end_point": {"row": 90, "column": 20}}, {"id": 175, "type": "sized_type_specifier", "text": "long", "parent": 174, "children": [176], "start_point": {"row": 90, "column": 2}, "end_point": {"row": 90, "column": 6}}, {"id": 176, "type": "long", "text": "long", "parent": 175, "children": [], "start_point": {"row": 90, "column": 2}, "end_point": {"row": 90, "column": 6}}, {"id": 177, "type": "identifier", "text": "l", "parent": 174, "children": [], "start_point": {"row": 90, "column": 7}, "end_point": {"row": 90, "column": 8}}, {"id": 178, "type": "identifier", "text": "flux", "parent": 174, "children": [], "start_point": {"row": 90, "column": 9}, "end_point": {"row": 90, "column": 13}}, {"id": 179, "type": "identifier", "text": "i", "parent": 174, "children": [], "start_point": {"row": 90, "column": 14}, "end_point": {"row": 90, "column": 15}}, {"id": 180, "type": "identifier", "text": "j", "parent": 174, "children": [], "start_point": {"row": 90, "column": 16}, "end_point": {"row": 90, "column": 17}}, {"id": 181, "type": "identifier", "text": "k", "parent": 174, "children": [], "start_point": {"row": 90, "column": 18}, "end_point": {"row": 90, "column": 19}}, {"id": 182, "type": "declaration", "text": "gl_t *gl;", "parent": 143, "children": [183, 184], "start_point": {"row": 91, "column": 2}, "end_point": {"row": 91, "column": 11}}, {"id": 183, "type": "type_identifier", "text": "gl_t", "parent": 182, "children": [], "start_point": {"row": 91, "column": 2}, "end_point": {"row": 91, "column": 6}}, {"id": 184, "type": "pointer_declarator", "text": "*gl", "parent": 182, "children": [185, 186], "start_point": {"row": 91, "column": 7}, "end_point": {"row": 91, "column": 10}}, {"id": 185, "type": "*", "text": "*", "parent": 184, "children": [], "start_point": {"row": 91, "column": 7}, "end_point": {"row": 91, "column": 8}}, {"id": 186, "type": "identifier", "text": "gl", "parent": 184, "children": [], "start_point": {"row": 91, "column": 8}, "end_point": {"row": 91, "column": 10}}, {"id": 187, "type": "declaration", "text": "np_t *np;", "parent": 143, "children": [188, 189], "start_point": {"row": 92, "column": 2}, "end_point": {"row": 92, "column": 11}}, {"id": 188, "type": "type_identifier", "text": "np_t", "parent": 187, "children": [], "start_point": {"row": 92, "column": 2}, "end_point": {"row": 92, "column": 6}}, {"id": 189, "type": "pointer_declarator", "text": "*np", "parent": 187, "children": [190, 191], "start_point": {"row": 92, "column": 7}, "end_point": {"row": 92, "column": 10}}, {"id": 190, "type": "*", "text": "*", "parent": 189, "children": [], "start_point": {"row": 92, "column": 7}, "end_point": {"row": 92, "column": 8}}, {"id": 191, "type": "identifier", "text": "np", "parent": 189, "children": [], "start_point": {"row": 92, "column": 8}, "end_point": {"row": 92, "column": 10}}, {"id": 192, "type": "assignment_expression", "text": "np=*((readcontrolarg_t *)codex->action_args)->np", "parent": 143, "children": [193, 194, 195], "start_point": {"row": 95, "column": 2}, "end_point": {"row": 95, "column": 50}}, {"id": 193, "type": "identifier", "text": "np", "parent": 192, "children": [], "start_point": {"row": 95, "column": 2}, "end_point": {"row": 95, "column": 4}}, {"id": 194, "type": "=", "text": "=", "parent": 192, "children": [], "start_point": {"row": 95, "column": 4}, "end_point": {"row": 95, "column": 5}}, {"id": 195, "type": "pointer_expression", "text": "*((readcontrolarg_t *)codex->action_args)->np", "parent": 192, "children": [196, 197], "start_point": {"row": 95, "column": 5}, "end_point": {"row": 95, "column": 50}}, {"id": 196, "type": "*", "text": "*", "parent": 195, "children": [], "start_point": {"row": 95, "column": 5}, "end_point": {"row": 95, "column": 6}}, {"id": 197, "type": "field_expression", "text": "((readcontrolarg_t *)codex->action_args)->np", "parent": 195, "children": [198, 207], "start_point": {"row": 95, "column": 6}, "end_point": {"row": 95, "column": 50}}, {"id": 198, "type": "parenthesized_expression", "text": "((readcontrolarg_t *)codex->action_args)", "parent": 197, "children": [199], "start_point": {"row": 95, "column": 6}, "end_point": {"row": 95, "column": 46}}, {"id": 199, "type": "cast_expression", "text": "(readcontrolarg_t *)codex->action_args", "parent": 198, "children": [200, 204], "start_point": {"row": 95, "column": 7}, "end_point": {"row": 95, "column": 45}}, {"id": 200, "type": "type_descriptor", "text": "readcontrolarg_t *", "parent": 199, "children": [201, 202], "start_point": {"row": 95, "column": 8}, "end_point": {"row": 95, "column": 26}}, {"id": 201, "type": "type_identifier", "text": "readcontrolarg_t", "parent": 200, "children": [], "start_point": {"row": 95, "column": 8}, "end_point": {"row": 95, "column": 24}}, {"id": 202, "type": "abstract_pointer_declarator", "text": "*", "parent": 200, "children": [203], "start_point": {"row": 95, "column": 25}, "end_point": {"row": 95, "column": 26}}, {"id": 203, "type": "*", "text": "*", "parent": 202, "children": [], "start_point": {"row": 95, "column": 25}, "end_point": {"row": 95, "column": 26}}, {"id": 204, "type": "field_expression", "text": "codex->action_args", "parent": 199, "children": [205, 206], "start_point": {"row": 95, "column": 27}, "end_point": {"row": 95, "column": 45}}, {"id": 205, "type": "identifier", "text": "codex", "parent": 204, "children": [], "start_point": {"row": 95, "column": 27}, "end_point": {"row": 95, "column": 32}}, {"id": 206, "type": "field_identifier", "text": "action_args", "parent": 204, "children": [], "start_point": {"row": 95, "column": 34}, "end_point": {"row": 95, "column": 45}}, {"id": 207, "type": "field_identifier", "text": "np", "parent": 197, "children": [], "start_point": {"row": 95, "column": 48}, "end_point": {"row": 95, "column": 50}}, {"id": 208, "type": "assignment_expression", "text": "gl=((readcontrolarg_t *)codex->action_args)->gl", "parent": 143, "children": [209, 210, 211], "start_point": {"row": 96, "column": 2}, "end_point": {"row": 96, "column": 49}}, {"id": 209, "type": "identifier", "text": "gl", "parent": 208, "children": [], "start_point": {"row": 96, "column": 2}, "end_point": {"row": 96, "column": 4}}, {"id": 210, "type": "=", "text": "=", "parent": 208, "children": [], "start_point": {"row": 96, "column": 4}, "end_point": {"row": 96, "column": 5}}, {"id": 211, "type": "field_expression", "text": "((readcontrolarg_t *)codex->action_args)->gl", "parent": 208, "children": [212, 221], "start_point": {"row": 96, "column": 5}, "end_point": {"row": 96, "column": 49}}, {"id": 212, "type": "parenthesized_expression", "text": "((readcontrolarg_t *)codex->action_args)", "parent": 211, "children": [213], "start_point": {"row": 96, "column": 5}, "end_point": {"row": 96, "column": 45}}, {"id": 213, "type": "cast_expression", "text": "(readcontrolarg_t *)codex->action_args", "parent": 212, "children": [214, 218], "start_point": {"row": 96, "column": 6}, "end_point": {"row": 96, "column": 44}}, {"id": 214, "type": "type_descriptor", "text": "readcontrolarg_t *", "parent": 213, "children": [215, 216], "start_point": {"row": 96, "column": 7}, "end_point": {"row": 96, "column": 25}}, {"id": 215, "type": "type_identifier", "text": "readcontrolarg_t", "parent": 214, "children": [], "start_point": {"row": 96, "column": 7}, "end_point": {"row": 96, "column": 23}}, {"id": 216, "type": "abstract_pointer_declarator", "text": "*", "parent": 214, "children": [217], "start_point": {"row": 96, "column": 24}, "end_point": {"row": 96, "column": 25}}, {"id": 217, "type": "*", "text": "*", "parent": 216, "children": [], "start_point": {"row": 96, "column": 24}, "end_point": {"row": 96, "column": 25}}, {"id": 218, "type": "field_expression", "text": "codex->action_args", "parent": 213, "children": [219, 220], "start_point": {"row": 96, "column": 26}, "end_point": {"row": 96, "column": 44}}, {"id": 219, "type": "identifier", "text": "codex", "parent": 218, "children": [], "start_point": {"row": 96, "column": 26}, "end_point": {"row": 96, "column": 31}}, {"id": 220, "type": "field_identifier", "text": "action_args", "parent": 218, "children": [], "start_point": {"row": 96, "column": 33}, "end_point": {"row": 96, "column": 44}}, {"id": 221, "type": "field_identifier", "text": "gl", "parent": 211, "children": [], "start_point": {"row": 96, "column": 47}, "end_point": {"row": 96, "column": 49}}, {"id": 222, "type": "if_statement", "text": "if (strcmp(actionname,\"UpdateFluid\")==0) {\n SOAP_substitute_all_argums(argum, codex);\n if (SOAP_number_argums(*argum)!=1) SOAP_fatal_error(codex,\"Number of arguments not equal to 1 in UpdateFluid(); action.\");\n gl->dt=SOAP_get_argum_double(codex,*argum,0);\n if (gl->dt<=0.0) fatal_error(\"The time step dt must be positive when calling UpdateFluid.\");\n for_ijk(gl->domain_lim,is,js,ks,ie,je,ke){\n l=_ai(gl,i,j,k);\n if ((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))){\n for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }\n }\n }\n\n for (gl->subiter_pc=0; gl->subiter_pc<gl->numsubiter_pc; gl->subiter_pc++){\n update_bdry_nodes(np,gl,gl->domain); \n find_residual(np, gl, gl->domain);\n find_ximax(np, gl, gl->domain, IJK_UPDATE_YES);\n#ifdef DISTMPI\n effiter_U_mem=gl->effiter_U;\n#endif\n update_U_predictor_corrector(np, gl, gl->domain);\n update_linked_nodes(np, gl, TYPELEVEL_FLUID);\n#ifdef DISTMPI\n exchange_U(np, gl);\n delta_effiter_U=gl->effiter_U-effiter_U_mem;\n MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);\n gl->effiter_U=effiter_U_mem+delta_effiter_U_max;\n#endif\n }\n gl->time+=gl->dt;\n update_runtime_codex_xi_from_gl(gl,codex);\n add_double_to_codex(codex,\"time\",gl->time); \n codex->ACTIONPROCESSED=TRUE;\n }", "parent": 143, "children": [223], "start_point": {"row": 98, "column": 2}, "end_point": {"row": 132, "column": 3}}, {"id": 223, "type": "parenthesized_expression", "text": "(strcmp(actionname,\"UpdateFluid\")==0)", "parent": 222, "children": [224], "start_point": {"row": 98, "column": 5}, "end_point": {"row": 98, "column": 42}}, {"id": 224, "type": "binary_expression", "text": "strcmp(actionname,\"UpdateFluid\")==0", "parent": 223, "children": [225, 230, 231], "start_point": {"row": 98, "column": 6}, "end_point": {"row": 98, "column": 41}}, {"id": 225, "type": "call_expression", "text": "strcmp(actionname,\"UpdateFluid\")", "parent": 224, "children": [226, 227], "start_point": {"row": 98, "column": 6}, "end_point": {"row": 98, "column": 38}}, {"id": 226, "type": "identifier", "text": "strcmp", "parent": 225, "children": [], "start_point": {"row": 98, "column": 6}, "end_point": {"row": 98, "column": 12}}, {"id": 227, "type": "argument_list", "text": "(actionname,\"UpdateFluid\")", "parent": 225, "children": [228, 229], "start_point": {"row": 98, "column": 12}, "end_point": {"row": 98, "column": 38}}, {"id": 228, "type": "identifier", "text": "actionname", "parent": 227, "children": [], "start_point": {"row": 98, "column": 13}, "end_point": {"row": 98, "column": 23}}, {"id": 229, "type": "string_literal", "text": "\"UpdateFluid\"", "parent": 227, "children": [], "start_point": {"row": 98, "column": 24}, "end_point": {"row": 98, "column": 37}}, {"id": 230, "type": "==", "text": "==", "parent": 224, "children": [], "start_point": {"row": 98, "column": 38}, "end_point": {"row": 98, "column": 40}}, {"id": 231, "type": "number_literal", "text": "0", "parent": 224, "children": [], "start_point": {"row": 98, "column": 40}, "end_point": {"row": 98, "column": 41}}, {"id": 232, "type": "call_expression", "text": "SOAP_substitute_all_argums(argum, codex)", "parent": 222, "children": [233, 234], "start_point": {"row": 99, "column": 4}, "end_point": {"row": 99, "column": 44}}, {"id": 233, "type": "identifier", "text": "SOAP_substitute_all_argums", "parent": 232, "children": [], "start_point": {"row": 99, "column": 4}, "end_point": {"row": 99, "column": 30}}, {"id": 234, "type": "argument_list", "text": "(argum, codex)", "parent": 232, "children": [235, 236], "start_point": {"row": 99, "column": 30}, "end_point": {"row": 99, "column": 44}}, {"id": 235, "type": "identifier", "text": "argum", "parent": 234, "children": [], "start_point": {"row": 99, "column": 31}, "end_point": {"row": 99, "column": 36}}, {"id": 236, "type": "identifier", "text": "codex", "parent": 234, "children": [], "start_point": {"row": 99, "column": 38}, "end_point": {"row": 99, "column": 43}}, {"id": 237, "type": "if_statement", "text": "if (SOAP_number_argums(*argum)!=1) SOAP_fatal_error(codex,\"Number of arguments not equal to 1 in UpdateFluid(); action.\");", "parent": 222, "children": [238], "start_point": {"row": 100, "column": 4}, "end_point": {"row": 100, "column": 126}}, {"id": 238, "type": "parenthesized_expression", "text": "(SOAP_number_argums(*argum)!=1)", "parent": 237, "children": [239], "start_point": {"row": 100, "column": 7}, "end_point": {"row": 100, "column": 38}}, {"id": 239, "type": "binary_expression", "text": "SOAP_number_argums(*argum)!=1", "parent": 238, "children": [240, 246, 247], "start_point": {"row": 100, "column": 8}, "end_point": {"row": 100, "column": 37}}, {"id": 240, "type": "call_expression", "text": "SOAP_number_argums(*argum)", "parent": 239, "children": [241, 242], "start_point": {"row": 100, "column": 8}, "end_point": {"row": 100, "column": 34}}, {"id": 241, "type": "identifier", "text": "SOAP_number_argums", "parent": 240, "children": [], "start_point": {"row": 100, "column": 8}, "end_point": {"row": 100, "column": 26}}, {"id": 242, "type": "argument_list", "text": "(*argum)", "parent": 240, "children": [243], "start_point": {"row": 100, "column": 26}, "end_point": {"row": 100, "column": 34}}, {"id": 243, "type": "pointer_expression", "text": "*argum", "parent": 242, "children": [244, 245], "start_point": {"row": 100, "column": 27}, "end_point": {"row": 100, "column": 33}}, {"id": 244, "type": "*", "text": "*", "parent": 243, "children": [], "start_point": {"row": 100, "column": 27}, "end_point": {"row": 100, "column": 28}}, {"id": 245, "type": "identifier", "text": "argum", "parent": 243, "children": [], "start_point": {"row": 100, "column": 28}, "end_point": {"row": 100, "column": 33}}, {"id": 246, "type": "!=", "text": "!=", "parent": 239, "children": [], "start_point": {"row": 100, "column": 34}, "end_point": {"row": 100, "column": 36}}, {"id": 247, "type": "number_literal", "text": "1", "parent": 239, "children": [], "start_point": {"row": 100, "column": 36}, "end_point": {"row": 100, "column": 37}}, {"id": 248, "type": "call_expression", "text": "SOAP_fatal_error(codex,\"Number of arguments not equal to 1 in UpdateFluid(); action.\")", "parent": 237, "children": [249, 250], "start_point": {"row": 100, "column": 39}, "end_point": {"row": 100, "column": 125}}, {"id": 249, "type": "identifier", "text": "SOAP_fatal_error", "parent": 248, "children": [], "start_point": {"row": 100, "column": 39}, "end_point": {"row": 100, "column": 55}}, {"id": 250, "type": "argument_list", "text": "(codex,\"Number of arguments not equal to 1 in UpdateFluid(); action.\")", "parent": 248, "children": [251, 252], "start_point": {"row": 100, "column": 55}, "end_point": {"row": 100, "column": 125}}, {"id": 251, "type": "identifier", "text": "codex", "parent": 250, "children": [], "start_point": {"row": 100, "column": 56}, "end_point": {"row": 100, "column": 61}}, {"id": 252, "type": "string_literal", "text": "\"Number of arguments not equal to 1 in UpdateFluid(); action.\"", "parent": 250, "children": [], "start_point": {"row": 100, "column": 62}, "end_point": {"row": 100, "column": 124}}, {"id": 253, "type": "assignment_expression", "text": "gl->dt=SOAP_get_argum_double(codex,*argum,0)", "parent": 222, "children": [254, 257, 258], "start_point": {"row": 101, "column": 4}, "end_point": {"row": 101, "column": 48}}, {"id": 254, "type": "field_expression", "text": "gl->dt", "parent": 253, "children": [255, 256], "start_point": {"row": 101, "column": 4}, "end_point": {"row": 101, "column": 10}}, {"id": 255, "type": "identifier", "text": "gl", "parent": 254, "children": [], "start_point": {"row": 101, "column": 4}, "end_point": {"row": 101, "column": 6}}, {"id": 256, "type": "field_identifier", "text": "dt", "parent": 254, "children": [], "start_point": {"row": 101, "column": 8}, "end_point": {"row": 101, "column": 10}}, {"id": 257, "type": "=", "text": "=", "parent": 253, "children": [], "start_point": {"row": 101, "column": 10}, "end_point": {"row": 101, "column": 11}}, {"id": 258, "type": "call_expression", "text": "SOAP_get_argum_double(codex,*argum,0)", "parent": 253, "children": [259, 260], "start_point": {"row": 101, "column": 11}, "end_point": {"row": 101, "column": 48}}, {"id": 259, "type": "identifier", "text": "SOAP_get_argum_double", "parent": 258, "children": [], "start_point": {"row": 101, "column": 11}, "end_point": {"row": 101, "column": 32}}, {"id": 260, "type": "argument_list", "text": "(codex,*argum,0)", "parent": 258, "children": [261, 262, 265], "start_point": {"row": 101, "column": 32}, "end_point": {"row": 101, "column": 48}}, {"id": 261, "type": "identifier", "text": "codex", "parent": 260, "children": [], "start_point": {"row": 101, "column": 33}, "end_point": {"row": 101, "column": 38}}, {"id": 262, "type": "pointer_expression", "text": "*argum", "parent": 260, "children": [263, 264], "start_point": {"row": 101, "column": 39}, "end_point": {"row": 101, "column": 45}}, {"id": 263, "type": "*", "text": "*", "parent": 262, "children": [], "start_point": {"row": 101, "column": 39}, "end_point": {"row": 101, "column": 40}}, {"id": 264, "type": "identifier", "text": "argum", "parent": 262, "children": [], "start_point": {"row": 101, "column": 40}, "end_point": {"row": 101, "column": 45}}, {"id": 265, "type": "number_literal", "text": "0", "parent": 260, "children": [], "start_point": {"row": 101, "column": 46}, "end_point": {"row": 101, "column": 47}}, {"id": 266, "type": "if_statement", "text": "if (gl->dt<=0.0) fatal_error(\"The time step dt must be positive when calling UpdateFluid.\");", "parent": 222, "children": [267], "start_point": {"row": 102, "column": 4}, "end_point": {"row": 102, "column": 96}}, {"id": 267, "type": "parenthesized_expression", "text": "(gl->dt<=0.0)", "parent": 266, "children": [268], "start_point": {"row": 102, "column": 7}, "end_point": {"row": 102, "column": 20}}, {"id": 268, "type": "binary_expression", "text": "gl->dt<=0.0", "parent": 267, "children": [269, 272, 273], "start_point": {"row": 102, "column": 8}, "end_point": {"row": 102, "column": 19}}, {"id": 269, "type": "field_expression", "text": "gl->dt", "parent": 268, "children": [270, 271], "start_point": {"row": 102, "column": 8}, "end_point": {"row": 102, "column": 14}}, {"id": 270, "type": "identifier", "text": "gl", "parent": 269, "children": [], "start_point": {"row": 102, "column": 8}, "end_point": {"row": 102, "column": 10}}, {"id": 271, "type": "field_identifier", "text": "dt", "parent": 269, "children": [], "start_point": {"row": 102, "column": 12}, "end_point": {"row": 102, "column": 14}}, {"id": 272, "type": "<=", "text": "<=", "parent": 268, "children": [], "start_point": {"row": 102, "column": 14}, "end_point": {"row": 102, "column": 16}}, {"id": 273, "type": "number_literal", "text": "0.0", "parent": 268, "children": [], "start_point": {"row": 102, "column": 16}, "end_point": {"row": 102, "column": 19}}, {"id": 274, "type": "call_expression", "text": "fatal_error(\"The time step dt must be positive when calling UpdateFluid.\")", "parent": 266, "children": [275, 276], "start_point": {"row": 102, "column": 21}, "end_point": {"row": 102, "column": 95}}, {"id": 275, "type": "identifier", "text": "fatal_error", "parent": 274, "children": [], "start_point": {"row": 102, "column": 21}, "end_point": {"row": 102, "column": 32}}, {"id": 276, "type": "argument_list", "text": "(\"The time step dt must be positive when calling UpdateFluid.\")", "parent": 274, "children": [277], "start_point": {"row": 102, "column": 32}, "end_point": {"row": 102, "column": 95}}, {"id": 277, "type": "string_literal", "text": "\"The time step dt must be positive when calling UpdateFluid.\"", "parent": 276, "children": [], "start_point": {"row": 102, "column": 33}, "end_point": {"row": 102, "column": 94}}, {"id": 278, "type": "call_expression", "text": "for_ijk(gl->domain_lim,is,js,ks,ie,je,ke)", "parent": 222, "children": [279, 280], "start_point": {"row": 103, "column": 4}, "end_point": {"row": 103, "column": 45}}, {"id": 279, "type": "identifier", "text": "for_ijk", "parent": 278, "children": [], "start_point": {"row": 103, "column": 4}, "end_point": {"row": 103, "column": 11}}, {"id": 280, "type": "argument_list", "text": "(gl->domain_lim,is,js,ks,ie,je,ke)", "parent": 278, "children": [281, 284, 285, 286, 287, 288, 289], "start_point": {"row": 103, "column": 11}, "end_point": {"row": 103, "column": 45}}, {"id": 281, "type": "field_expression", "text": "gl->domain_lim", "parent": 280, "children": [282, 283], "start_point": {"row": 103, "column": 12}, "end_point": {"row": 103, "column": 26}}, {"id": 282, "type": "identifier", "text": "gl", "parent": 281, "children": [], "start_point": {"row": 103, "column": 12}, "end_point": {"row": 103, "column": 14}}, {"id": 283, "type": "field_identifier", "text": "domain_lim", "parent": 281, "children": [], "start_point": {"row": 103, "column": 16}, "end_point": {"row": 103, "column": 26}}, {"id": 284, "type": "identifier", "text": "is", "parent": 280, "children": [], "start_point": {"row": 103, "column": 27}, "end_point": {"row": 103, "column": 29}}, {"id": 285, "type": "identifier", "text": "js", "parent": 280, "children": [], "start_point": {"row": 103, "column": 30}, "end_point": {"row": 103, "column": 32}}, {"id": 286, "type": "identifier", "text": "ks", "parent": 280, "children": [], "start_point": {"row": 103, "column": 33}, "end_point": {"row": 103, "column": 35}}, {"id": 287, "type": "identifier", "text": "ie", "parent": 280, "children": [], "start_point": {"row": 103, "column": 36}, "end_point": {"row": 103, "column": 38}}, {"id": 288, "type": "identifier", "text": "je", "parent": 280, "children": [], "start_point": {"row": 103, "column": 39}, "end_point": {"row": 103, "column": 41}}, {"id": 289, "type": "identifier", "text": "ke", "parent": 280, "children": [], "start_point": {"row": 103, "column": 42}, "end_point": {"row": 103, "column": 44}}, {"id": 290, "type": "assignment_expression", "text": "l=_ai(gl,i,j,k)", "parent": 222, "children": [291, 292, 293], "start_point": {"row": 104, "column": 10}, "end_point": {"row": 104, "column": 25}}, {"id": 291, "type": "identifier", "text": "l", "parent": 290, "children": [], "start_point": {"row": 104, "column": 10}, "end_point": {"row": 104, "column": 11}}, {"id": 292, "type": "=", "text": "=", "parent": 290, "children": [], "start_point": {"row": 104, "column": 11}, "end_point": {"row": 104, "column": 12}}, {"id": 293, "type": "call_expression", "text": "_ai(gl,i,j,k)", "parent": 290, "children": [294, 295], "start_point": {"row": 104, "column": 12}, "end_point": {"row": 104, "column": 25}}, {"id": 294, "type": "identifier", "text": "_ai", "parent": 293, "children": [], "start_point": {"row": 104, "column": 12}, "end_point": {"row": 104, "column": 15}}, {"id": 295, "type": "argument_list", "text": "(gl,i,j,k)", "parent": 293, "children": [296, 297, 298, 299], "start_point": {"row": 104, "column": 15}, "end_point": {"row": 104, "column": 25}}, {"id": 296, "type": "identifier", "text": "gl", "parent": 295, "children": [], "start_point": {"row": 104, "column": 16}, "end_point": {"row": 104, "column": 18}}, {"id": 297, "type": "identifier", "text": "i", "parent": 295, "children": [], "start_point": {"row": 104, "column": 19}, "end_point": {"row": 104, "column": 20}}, {"id": 298, "type": "identifier", "text": "j", "parent": 295, "children": [], "start_point": {"row": 104, "column": 21}, "end_point": {"row": 104, "column": 22}}, {"id": 299, "type": "identifier", "text": "k", "parent": 295, "children": [], "start_point": {"row": 104, "column": 23}, "end_point": {"row": 104, "column": 24}}, {"id": 300, "type": "if_statement", "text": "if ((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))){\n for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }\n }", "parent": 222, "children": [301], "start_point": {"row": 105, "column": 10}, "end_point": {"row": 109, "column": 11}}, {"id": 301, "type": "parenthesized_expression", "text": "((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID)))", "parent": 300, "children": [302], "start_point": {"row": 105, "column": 13}, "end_point": {"row": 105, "column": 65}}, {"id": 302, "type": "parenthesized_expression", "text": "(is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))", "parent": 301, "children": [303], "start_point": {"row": 105, "column": 14}, "end_point": {"row": 105, "column": 64}}, {"id": 303, "type": "call_expression", "text": "is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID)", "parent": 302, "children": [304, 305], "start_point": {"row": 105, "column": 15}, "end_point": {"row": 105, "column": 63}}, {"id": 304, "type": "identifier", "text": "is_node_valid", "parent": 303, "children": [], "start_point": {"row": 105, "column": 15}, "end_point": {"row": 105, "column": 28}}, {"id": 305, "type": "argument_list", "text": "(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID)", "parent": 303, "children": [306, 315], "start_point": {"row": 105, "column": 28}, "end_point": {"row": 105, "column": 63}}, {"id": 306, "type": "subscript_expression", "text": "np[_ai(gl,i,j,k)]", "parent": 305, "children": [307, 308], "start_point": {"row": 105, "column": 29}, "end_point": {"row": 105, "column": 46}}, {"id": 307, "type": "identifier", "text": "np", "parent": 306, "children": [], "start_point": {"row": 105, "column": 29}, "end_point": {"row": 105, "column": 31}}, {"id": 308, "type": "call_expression", "text": "_ai(gl,i,j,k)", "parent": 306, "children": [309, 310], "start_point": {"row": 105, "column": 32}, "end_point": {"row": 105, "column": 45}}, {"id": 309, "type": "identifier", "text": "_ai", "parent": 308, "children": [], "start_point": {"row": 105, "column": 32}, "end_point": {"row": 105, "column": 35}}, {"id": 310, "type": "argument_list", "text": "(gl,i,j,k)", "parent": 308, "children": [311, 312, 313, 314], "start_point": {"row": 105, "column": 35}, "end_point": {"row": 105, "column": 45}}, {"id": 311, "type": "identifier", "text": "gl", "parent": 310, "children": [], "start_point": {"row": 105, "column": 36}, "end_point": {"row": 105, "column": 38}}, {"id": 312, "type": "identifier", "text": "i", "parent": 310, "children": [], "start_point": {"row": 105, "column": 39}, "end_point": {"row": 105, "column": 40}}, {"id": 313, "type": "identifier", "text": "j", "parent": 310, "children": [], "start_point": {"row": 105, "column": 41}, "end_point": {"row": 105, "column": 42}}, {"id": 314, "type": "identifier", "text": "k", "parent": 310, "children": [], "start_point": {"row": 105, "column": 43}, "end_point": {"row": 105, "column": 44}}, {"id": 315, "type": "identifier", "text": "TYPELEVEL_FLUID", "parent": 305, "children": [], "start_point": {"row": 105, "column": 47}, "end_point": {"row": 105, "column": 62}}, {"id": 316, "type": "for_statement", "text": "for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }", "parent": 300, "children": [317, 321, 325], "start_point": {"row": 106, "column": 12}, "end_point": {"row": 108, "column": 13}}, {"id": 317, "type": "assignment_expression", "text": "flux=0", "parent": 316, "children": [318, 319, 320], "start_point": {"row": 106, "column": 17}, "end_point": {"row": 106, "column": 23}}, {"id": 318, "type": "identifier", "text": "flux", "parent": 317, "children": [], "start_point": {"row": 106, "column": 17}, "end_point": {"row": 106, "column": 21}}, {"id": 319, "type": "=", "text": "=", "parent": 317, "children": [], "start_point": {"row": 106, "column": 21}, "end_point": {"row": 106, "column": 22}}, {"id": 320, "type": "number_literal", "text": "0", "parent": 317, "children": [], "start_point": {"row": 106, "column": 22}, "end_point": {"row": 106, "column": 23}}, {"id": 321, "type": "binary_expression", "text": "flux<nf", "parent": 316, "children": [322, 323, 324], "start_point": {"row": 106, "column": 25}, "end_point": {"row": 106, "column": 32}}, {"id": 322, "type": "identifier", "text": "flux", "parent": 321, "children": [], "start_point": {"row": 106, "column": 25}, "end_point": {"row": 106, "column": 29}}, {"id": 323, "type": "<", "text": "<", "parent": 321, "children": [], "start_point": {"row": 106, "column": 29}, "end_point": {"row": 106, "column": 30}}, {"id": 324, "type": "identifier", "text": "nf", "parent": 321, "children": [], "start_point": {"row": 106, "column": 30}, "end_point": {"row": 106, "column": 32}}, {"id": 325, "type": "update_expression", "text": "flux++", "parent": 316, "children": [326, 327], "start_point": {"row": 106, "column": 34}, "end_point": {"row": 106, "column": 40}}, {"id": 326, "type": "identifier", "text": "flux", "parent": 325, "children": [], "start_point": {"row": 106, "column": 34}, "end_point": {"row": 106, "column": 38}}, {"id": 327, "type": "++", "text": "++", "parent": 325, "children": [], "start_point": {"row": 106, "column": 38}, "end_point": {"row": 106, "column": 40}}, {"id": 328, "type": "assignment_expression", "text": "np[l].bs->Um1[flux]=np[l].bs->U[flux]", "parent": 316, "children": [329, 338, 339], "start_point": {"row": 107, "column": 14}, "end_point": {"row": 107, "column": 51}}, {"id": 329, "type": "subscript_expression", "text": "np[l].bs->Um1[flux]", "parent": 328, "children": [330, 337], "start_point": {"row": 107, "column": 14}, "end_point": {"row": 107, "column": 33}}, {"id": 330, "type": "field_expression", "text": "np[l].bs->Um1", "parent": 329, "children": [331, 336], "start_point": {"row": 107, "column": 14}, "end_point": {"row": 107, "column": 27}}, {"id": 331, "type": "field_expression", "text": "np[l].bs", "parent": 330, "children": [332, 335], "start_point": {"row": 107, "column": 14}, "end_point": {"row": 107, "column": 22}}, {"id": 332, "type": "subscript_expression", "text": "np[l]", "parent": 331, "children": [333, 334], "start_point": {"row": 107, "column": 14}, "end_point": {"row": 107, "column": 19}}, {"id": 333, "type": "identifier", "text": "np", "parent": 332, "children": [], "start_point": {"row": 107, "column": 14}, "end_point": {"row": 107, "column": 16}}, {"id": 334, "type": "identifier", "text": "l", "parent": 332, "children": [], "start_point": {"row": 107, "column": 17}, "end_point": {"row": 107, "column": 18}}, {"id": 335, "type": "field_identifier", "text": "bs", "parent": 331, "children": [], "start_point": {"row": 107, "column": 20}, "end_point": {"row": 107, "column": 22}}, {"id": 336, "type": "field_identifier", "text": "Um1", "parent": 330, "children": [], "start_point": {"row": 107, "column": 24}, "end_point": {"row": 107, "column": 27}}, {"id": 337, "type": "identifier", "text": "flux", "parent": 329, "children": [], "start_point": {"row": 107, "column": 28}, "end_point": {"row": 107, "column": 32}}, {"id": 338, "type": "=", "text": "=", "parent": 328, "children": [], "start_point": {"row": 107, "column": 33}, "end_point": {"row": 107, "column": 34}}, {"id": 339, "type": "subscript_expression", "text": "np[l].bs->U[flux]", "parent": 328, "children": [340, 347], "start_point": {"row": 107, "column": 34}, "end_point": {"row": 107, "column": 51}}, {"id": 340, "type": "field_expression", "text": "np[l].bs->U", "parent": 339, "children": [341, 346], "start_point": {"row": 107, "column": 34}, "end_point": {"row": 107, "column": 45}}, {"id": 341, "type": "field_expression", "text": "np[l].bs", "parent": 340, "children": [342, 345], "start_point": {"row": 107, "column": 34}, "end_point": {"row": 107, "column": 42}}, {"id": 342, "type": "subscript_expression", "text": "np[l]", "parent": 341, "children": [343, 344], "start_point": {"row": 107, "column": 34}, "end_point": {"row": 107, "column": 39}}, {"id": 343, "type": "identifier", "text": "np", "parent": 342, "children": [], "start_point": {"row": 107, "column": 34}, "end_point": {"row": 107, "column": 36}}, {"id": 344, "type": "identifier", "text": "l", "parent": 342, "children": [], "start_point": {"row": 107, "column": 37}, "end_point": {"row": 107, "column": 38}}, {"id": 345, "type": "field_identifier", "text": "bs", "parent": 341, "children": [], "start_point": {"row": 107, "column": 40}, "end_point": {"row": 107, "column": 42}}, {"id": 346, "type": "field_identifier", "text": "U", "parent": 340, "children": [], "start_point": {"row": 107, "column": 44}, "end_point": {"row": 107, "column": 45}}, {"id": 347, "type": "identifier", "text": "flux", "parent": 339, "children": [], "start_point": {"row": 107, "column": 46}, "end_point": {"row": 107, "column": 50}}, {"id": 348, "type": "for_statement", "text": "for (gl->subiter_pc=0; gl->subiter_pc<gl->numsubiter_pc; gl->subiter_pc++){\n update_bdry_nodes(np,gl,gl->domain); \n find_residual(np, gl, gl->domain);\n find_ximax(np, gl, gl->domain, IJK_UPDATE_YES);\n#ifdef DISTMPI\n effiter_U_mem=gl->effiter_U;\n#endif\n update_U_predictor_corrector(np, gl, gl->domain);\n update_linked_nodes(np, gl, TYPELEVEL_FLUID);\n#ifdef DISTMPI\n exchange_U(np, gl);\n delta_effiter_U=gl->effiter_U-effiter_U_mem;\n MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);\n gl->effiter_U=effiter_U_mem+delta_effiter_U_max;\n#endif\n }", "parent": 222, "children": [349, 355, 363], "start_point": {"row": 112, "column": 4}, "end_point": {"row": 127, "column": 5}}, {"id": 349, "type": "assignment_expression", "text": "gl->subiter_pc=0", "parent": 348, "children": [350, 353, 354], "start_point": {"row": 112, "column": 9}, "end_point": {"row": 112, "column": 25}}, {"id": 350, "type": "field_expression", "text": "gl->subiter_pc", "parent": 349, "children": [351, 352], "start_point": {"row": 112, "column": 9}, "end_point": {"row": 112, "column": 23}}, {"id": 351, "type": "identifier", "text": "gl", "parent": 350, "children": [], "start_point": {"row": 112, "column": 9}, "end_point": {"row": 112, "column": 11}}, {"id": 352, "type": "field_identifier", "text": "subiter_pc", "parent": 350, "children": [], "start_point": {"row": 112, "column": 13}, "end_point": {"row": 112, "column": 23}}, {"id": 353, "type": "=", "text": "=", "parent": 349, "children": [], "start_point": {"row": 112, "column": 23}, "end_point": {"row": 112, "column": 24}}, {"id": 354, "type": "number_literal", "text": "0", "parent": 349, "children": [], "start_point": {"row": 112, "column": 24}, "end_point": {"row": 112, "column": 25}}, {"id": 355, "type": "binary_expression", "text": "gl->subiter_pc<gl->numsubiter_pc", "parent": 348, "children": [356, 359, 360], "start_point": {"row": 112, "column": 27}, "end_point": {"row": 112, "column": 59}}, {"id": 356, "type": "field_expression", "text": "gl->subiter_pc", "parent": 355, "children": [357, 358], "start_point": {"row": 112, "column": 27}, "end_point": {"row": 112, "column": 41}}, {"id": 357, "type": "identifier", "text": "gl", "parent": 356, "children": [], "start_point": {"row": 112, "column": 27}, "end_point": {"row": 112, "column": 29}}, {"id": 358, "type": "field_identifier", "text": "subiter_pc", "parent": 356, "children": [], "start_point": {"row": 112, "column": 31}, "end_point": {"row": 112, "column": 41}}, {"id": 359, "type": "<", "text": "<", "parent": 355, "children": [], "start_point": {"row": 112, "column": 41}, "end_point": {"row": 112, "column": 42}}, {"id": 360, "type": "field_expression", "text": "gl->numsubiter_pc", "parent": 355, "children": [361, 362], "start_point": {"row": 112, "column": 42}, "end_point": {"row": 112, "column": 59}}, {"id": 361, "type": "identifier", "text": "gl", "parent": 360, "children": [], "start_point": {"row": 112, "column": 42}, "end_point": {"row": 112, "column": 44}}, {"id": 362, "type": "field_identifier", "text": "numsubiter_pc", "parent": 360, "children": [], "start_point": {"row": 112, "column": 46}, "end_point": {"row": 112, "column": 59}}, {"id": 363, "type": "update_expression", "text": "gl->subiter_pc++", "parent": 348, "children": [364, 367], "start_point": {"row": 112, "column": 61}, "end_point": {"row": 112, "column": 77}}, {"id": 364, "type": "field_expression", "text": "gl->subiter_pc", "parent": 363, "children": [365, 366], "start_point": {"row": 112, "column": 61}, "end_point": {"row": 112, "column": 75}}, {"id": 365, "type": "identifier", "text": "gl", "parent": 364, "children": [], "start_point": {"row": 112, "column": 61}, "end_point": {"row": 112, "column": 63}}, {"id": 366, "type": "field_identifier", "text": "subiter_pc", "parent": 364, "children": [], "start_point": {"row": 112, "column": 65}, "end_point": {"row": 112, "column": 75}}, {"id": 367, "type": "++", "text": "++", "parent": 363, "children": [], "start_point": {"row": 112, "column": 75}, "end_point": {"row": 112, "column": 77}}, {"id": 368, "type": "call_expression", "text": "update_bdry_nodes(np,gl,gl->domain)", "parent": 348, "children": [369, 370], "start_point": {"row": 113, "column": 6}, "end_point": {"row": 113, "column": 41}}, {"id": 369, "type": "identifier", "text": "update_bdry_nodes", "parent": 368, "children": [], "start_point": {"row": 113, "column": 6}, "end_point": {"row": 113, "column": 23}}, {"id": 370, "type": "argument_list", "text": "(np,gl,gl->domain)", "parent": 368, "children": [371, 372, 373], "start_point": {"row": 113, "column": 23}, "end_point": {"row": 113, "column": 41}}, {"id": 371, "type": "identifier", "text": "np", "parent": 370, "children": [], "start_point": {"row": 113, "column": 24}, "end_point": {"row": 113, "column": 26}}, {"id": 372, "type": "identifier", "text": "gl", "parent": 370, "children": [], "start_point": {"row": 113, "column": 27}, "end_point": {"row": 113, "column": 29}}, {"id": 373, "type": "field_expression", "text": "gl->domain", "parent": 370, "children": [374, 375], "start_point": {"row": 113, "column": 30}, "end_point": {"row": 113, "column": 40}}, {"id": 374, "type": "identifier", "text": "gl", "parent": 373, "children": [], "start_point": {"row": 113, "column": 30}, "end_point": {"row": 113, "column": 32}}, {"id": 375, "type": "field_identifier", "text": "domain", "parent": 373, "children": [], "start_point": {"row": 113, "column": 34}, "end_point": {"row": 113, "column": 40}}, {"id": 376, "type": "call_expression", "text": "find_residual(np, gl, gl->domain)", "parent": 348, "children": [377, 378], "start_point": {"row": 114, "column": 6}, "end_point": {"row": 114, "column": 39}}, {"id": 377, "type": "identifier", "text": "find_residual", "parent": 376, "children": [], "start_point": {"row": 114, "column": 6}, "end_point": {"row": 114, "column": 19}}, {"id": 378, "type": "argument_list", "text": "(np, gl, gl->domain)", "parent": 376, "children": [379, 380, 381], "start_point": {"row": 114, "column": 19}, "end_point": {"row": 114, "column": 39}}, {"id": 379, "type": "identifier", "text": "np", "parent": 378, "children": [], "start_point": {"row": 114, "column": 20}, "end_point": {"row": 114, "column": 22}}, {"id": 380, "type": "identifier", "text": "gl", "parent": 378, "children": [], "start_point": {"row": 114, "column": 24}, "end_point": {"row": 114, "column": 26}}, {"id": 381, "type": "field_expression", "text": "gl->domain", "parent": 378, "children": [382, 383], "start_point": {"row": 114, "column": 28}, "end_point": {"row": 114, "column": 38}}, {"id": 382, "type": "identifier", "text": "gl", "parent": 381, "children": [], "start_point": {"row": 114, "column": 28}, "end_point": {"row": 114, "column": 30}}, {"id": 383, "type": "field_identifier", "text": "domain", "parent": 381, "children": [], "start_point": {"row": 114, "column": 32}, "end_point": {"row": 114, "column": 38}}, {"id": 384, "type": "call_expression", "text": "find_ximax(np, gl, gl->domain, IJK_UPDATE_YES)", "parent": 348, "children": [385, 386], "start_point": {"row": 115, "column": 6}, "end_point": {"row": 115, "column": 52}}, {"id": 385, "type": "identifier", "text": "find_ximax", "parent": 384, "children": [], "start_point": {"row": 115, "column": 6}, "end_point": {"row": 115, "column": 16}}, {"id": 386, "type": "argument_list", "text": "(np, gl, gl->domain, IJK_UPDATE_YES)", "parent": 384, "children": [387, 388, 389, 392], "start_point": {"row": 115, "column": 16}, "end_point": {"row": 115, "column": 52}}, {"id": 387, "type": "identifier", "text": "np", "parent": 386, "children": [], "start_point": {"row": 115, "column": 17}, "end_point": {"row": 115, "column": 19}}, {"id": 388, "type": "identifier", "text": "gl", "parent": 386, "children": [], "start_point": {"row": 115, "column": 21}, "end_point": {"row": 115, "column": 23}}, {"id": 389, "type": "field_expression", "text": "gl->domain", "parent": 386, "children": [390, 391], "start_point": {"row": 115, "column": 25}, "end_point": {"row": 115, "column": 35}}, {"id": 390, "type": "identifier", "text": "gl", "parent": 389, "children": [], "start_point": {"row": 115, "column": 25}, "end_point": {"row": 115, "column": 27}}, {"id": 391, "type": "field_identifier", "text": "domain", "parent": 389, "children": [], "start_point": {"row": 115, "column": 29}, "end_point": {"row": 115, "column": 35}}, {"id": 392, "type": "identifier", "text": "IJK_UPDATE_YES", "parent": 386, "children": [], "start_point": {"row": 115, "column": 37}, "end_point": {"row": 115, "column": 51}}, {"id": 393, "type": "preproc_ifdef", "text": "#ifdef DISTMPI\n effiter_U_mem=gl->effiter_U;\n#endif", "parent": 348, "children": [394, 395, 402], "start_point": {"row": 116, "column": 0}, "end_point": {"row": 118, "column": 6}}, {"id": 394, "type": "#ifdef", "text": "#ifdef", "parent": 393, "children": [], "start_point": {"row": 116, "column": 0}, "end_point": {"row": 116, "column": 6}}, {"id": 395, "type": "identifier", "text": "DISTMPI", "parent": 393, "children": [], "start_point": {"row": 116, "column": 7}, "end_point": {"row": 116, "column": 14}}, {"id": 396, "type": "assignment_expression", "text": "effiter_U_mem=gl->effiter_U", "parent": 393, "children": [397, 398, 399], "start_point": {"row": 117, "column": 6}, "end_point": {"row": 117, "column": 33}}, {"id": 397, "type": "identifier", "text": "effiter_U_mem", "parent": 396, "children": [], "start_point": {"row": 117, "column": 6}, "end_point": {"row": 117, "column": 19}}, {"id": 398, "type": "=", "text": "=", "parent": 396, "children": [], "start_point": {"row": 117, "column": 19}, "end_point": {"row": 117, "column": 20}}, {"id": 399, "type": "field_expression", "text": "gl->effiter_U", "parent": 396, "children": [400, 401], "start_point": {"row": 117, "column": 20}, "end_point": {"row": 117, "column": 33}}, {"id": 400, "type": "identifier", "text": "gl", "parent": 399, "children": [], "start_point": {"row": 117, "column": 20}, "end_point": {"row": 117, "column": 22}}, {"id": 401, "type": "field_identifier", "text": "effiter_U", "parent": 399, "children": [], "start_point": {"row": 117, "column": 24}, "end_point": {"row": 117, "column": 33}}, {"id": 402, "type": "#endif", "text": "#endif", "parent": 393, "children": [], "start_point": {"row": 118, "column": 0}, "end_point": {"row": 118, "column": 6}}, {"id": 403, "type": "call_expression", "text": "update_U_predictor_corrector(np, gl, gl->domain)", "parent": 348, "children": [404, 405], "start_point": {"row": 119, "column": 6}, "end_point": {"row": 119, "column": 54}}, {"id": 404, "type": "identifier", "text": "update_U_predictor_corrector", "parent": 403, "children": [], "start_point": {"row": 119, "column": 6}, "end_point": {"row": 119, "column": 34}}, {"id": 405, "type": "argument_list", "text": "(np, gl, gl->domain)", "parent": 403, "children": [406, 407, 408], "start_point": {"row": 119, "column": 34}, "end_point": {"row": 119, "column": 54}}, {"id": 406, "type": "identifier", "text": "np", "parent": 405, "children": [], "start_point": {"row": 119, "column": 35}, "end_point": {"row": 119, "column": 37}}, {"id": 407, "type": "identifier", "text": "gl", "parent": 405, "children": [], "start_point": {"row": 119, "column": 39}, "end_point": {"row": 119, "column": 41}}, {"id": 408, "type": "field_expression", "text": "gl->domain", "parent": 405, "children": [409, 410], "start_point": {"row": 119, "column": 43}, "end_point": {"row": 119, "column": 53}}, {"id": 409, "type": "identifier", "text": "gl", "parent": 408, "children": [], "start_point": {"row": 119, "column": 43}, "end_point": {"row": 119, "column": 45}}, {"id": 410, "type": "field_identifier", "text": "domain", "parent": 408, "children": [], "start_point": {"row": 119, "column": 47}, "end_point": {"row": 119, "column": 53}}, {"id": 411, "type": "call_expression", "text": "update_linked_nodes(np, gl, TYPELEVEL_FLUID)", "parent": 348, "children": [412, 413], "start_point": {"row": 120, "column": 6}, "end_point": {"row": 120, "column": 50}}, {"id": 412, "type": "identifier", "text": "update_linked_nodes", "parent": 411, "children": [], "start_point": {"row": 120, "column": 6}, "end_point": {"row": 120, "column": 25}}, {"id": 413, "type": "argument_list", "text": "(np, gl, TYPELEVEL_FLUID)", "parent": 411, "children": [414, 415, 416], "start_point": {"row": 120, "column": 25}, "end_point": {"row": 120, "column": 50}}, {"id": 414, "type": "identifier", "text": "np", "parent": 413, "children": [], "start_point": {"row": 120, "column": 26}, "end_point": {"row": 120, "column": 28}}, {"id": 415, "type": "identifier", "text": "gl", "parent": 413, "children": [], "start_point": {"row": 120, "column": 30}, "end_point": {"row": 120, "column": 32}}, {"id": 416, "type": "identifier", "text": "TYPELEVEL_FLUID", "parent": 413, "children": [], "start_point": {"row": 120, "column": 34}, "end_point": {"row": 120, "column": 49}}, {"id": 417, "type": "preproc_ifdef", "text": "#ifdef DISTMPI\n exchange_U(np, gl);\n delta_effiter_U=gl->effiter_U-effiter_U_mem;\n MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);\n gl->effiter_U=effiter_U_mem+delta_effiter_U_max;\n#endif", "parent": 348, "children": [418, 419, 454], "start_point": {"row": 121, "column": 0}, "end_point": {"row": 126, "column": 6}}, {"id": 418, "type": "#ifdef", "text": "#ifdef", "parent": 417, "children": [], "start_point": {"row": 121, "column": 0}, "end_point": {"row": 121, "column": 6}}, {"id": 419, "type": "identifier", "text": "DISTMPI", "parent": 417, "children": [], "start_point": {"row": 121, "column": 7}, "end_point": {"row": 121, "column": 14}}, {"id": 420, "type": "call_expression", "text": "exchange_U(np, gl)", "parent": 417, "children": [421, 422], "start_point": {"row": 122, "column": 6}, "end_point": {"row": 122, "column": 24}}, {"id": 421, "type": "identifier", "text": "exchange_U", "parent": 420, "children": [], "start_point": {"row": 122, "column": 6}, "end_point": {"row": 122, "column": 16}}, {"id": 422, "type": "argument_list", "text": "(np, gl)", "parent": 420, "children": [423, 424], "start_point": {"row": 122, "column": 16}, "end_point": {"row": 122, "column": 24}}, {"id": 423, "type": "identifier", "text": "np", "parent": 422, "children": [], "start_point": {"row": 122, "column": 17}, "end_point": {"row": 122, "column": 19}}, {"id": 424, "type": "identifier", "text": "gl", "parent": 422, "children": [], "start_point": {"row": 122, "column": 21}, "end_point": {"row": 122, "column": 23}}, {"id": 425, "type": "assignment_expression", "text": "delta_effiter_U=gl->effiter_U-effiter_U_mem", "parent": 417, "children": [426, 427, 428], "start_point": {"row": 123, "column": 6}, "end_point": {"row": 123, "column": 49}}, {"id": 426, "type": "identifier", "text": "delta_effiter_U", "parent": 425, "children": [], "start_point": {"row": 123, "column": 6}, "end_point": {"row": 123, "column": 21}}, {"id": 427, "type": "=", "text": "=", "parent": 425, "children": [], "start_point": {"row": 123, "column": 21}, "end_point": {"row": 123, "column": 22}}, {"id": 428, "type": "binary_expression", "text": "gl->effiter_U-effiter_U_mem", "parent": 425, "children": [429, 432, 433], "start_point": {"row": 123, "column": 22}, "end_point": {"row": 123, "column": 49}}, {"id": 429, "type": "field_expression", "text": "gl->effiter_U", "parent": 428, "children": [430, 431], "start_point": {"row": 123, "column": 22}, "end_point": {"row": 123, "column": 35}}, {"id": 430, "type": "identifier", "text": "gl", "parent": 429, "children": [], "start_point": {"row": 123, "column": 22}, "end_point": {"row": 123, "column": 24}}, {"id": 431, "type": "field_identifier", "text": "effiter_U", "parent": 429, "children": [], "start_point": {"row": 123, "column": 26}, "end_point": {"row": 123, "column": 35}}, {"id": 432, "type": "-", "text": "-", "parent": 428, "children": [], "start_point": {"row": 123, "column": 35}, "end_point": {"row": 123, "column": 36}}, {"id": 433, "type": "identifier", "text": "effiter_U_mem", "parent": 428, "children": [], "start_point": {"row": 123, "column": 36}, "end_point": {"row": 123, "column": 49}}, {"id": 434, "type": "call_expression", "text": "MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD)", "parent": 417, "children": [435, 436], "start_point": {"row": 124, "column": 6}, "end_point": {"row": 124, "column": 99}}, {"id": 435, "type": "identifier", "text": "MPI_Allreduce", "parent": 434, "children": [], "start_point": {"row": 124, "column": 6}, "end_point": {"row": 124, "column": 19}}, {"id": 436, "type": "argument_list", "text": "(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD)", "parent": 434, "children": [437, 439, 441, 442, 443, 444], "start_point": {"row": 124, "column": 19}, "end_point": {"row": 124, "column": 99}}, {"id": 437, "type": "pointer_expression", "text": "&delta_effiter_U", "parent": 436, "children": [438], "start_point": {"row": 124, "column": 20}, "end_point": {"row": 124, "column": 36}}, {"id": 438, "type": "identifier", "text": "delta_effiter_U", "parent": 437, "children": [], "start_point": {"row": 124, "column": 21}, "end_point": {"row": 124, "column": 36}}, {"id": 439, "type": "pointer_expression", "text": "&delta_effiter_U_max", "parent": 436, "children": [440], "start_point": {"row": 124, "column": 38}, "end_point": {"row": 124, "column": 58}}, {"id": 440, "type": "identifier", "text": "delta_effiter_U_max", "parent": 439, "children": [], "start_point": {"row": 124, "column": 39}, "end_point": {"row": 124, "column": 58}}, {"id": 441, "type": "number_literal", "text": "1", "parent": 436, "children": [], "start_point": {"row": 124, "column": 60}, "end_point": {"row": 124, "column": 61}}, {"id": 442, "type": "identifier", "text": "MPI_DOUBLE", "parent": 436, "children": [], "start_point": {"row": 124, "column": 63}, "end_point": {"row": 124, "column": 73}}, {"id": 443, "type": "identifier", "text": "MPI_MAX", "parent": 436, "children": [], "start_point": {"row": 124, "column": 75}, "end_point": {"row": 124, "column": 82}}, {"id": 444, "type": "identifier", "text": "MPI_COMM_WORLD", "parent": 436, "children": [], "start_point": {"row": 124, "column": 84}, "end_point": {"row": 124, "column": 98}}, {"id": 445, "type": "assignment_expression", "text": "gl->effiter_U=effiter_U_mem+delta_effiter_U_max", "parent": 417, "children": [446, 449, 450], "start_point": {"row": 125, "column": 6}, "end_point": {"row": 125, "column": 53}}, {"id": 446, "type": "field_expression", "text": "gl->effiter_U", "parent": 445, "children": [447, 448], "start_point": {"row": 125, "column": 6}, "end_point": {"row": 125, "column": 19}}, {"id": 447, "type": "identifier", "text": "gl", "parent": 446, "children": [], "start_point": {"row": 125, "column": 6}, "end_point": {"row": 125, "column": 8}}, {"id": 448, "type": "field_identifier", "text": "effiter_U", "parent": 446, "children": [], "start_point": {"row": 125, "column": 10}, "end_point": {"row": 125, "column": 19}}, {"id": 449, "type": "=", "text": "=", "parent": 445, "children": [], "start_point": {"row": 125, "column": 19}, "end_point": {"row": 125, "column": 20}}, {"id": 450, "type": "binary_expression", "text": "effiter_U_mem+delta_effiter_U_max", "parent": 445, "children": [451, 452, 453], "start_point": {"row": 125, "column": 20}, "end_point": {"row": 125, "column": 53}}, {"id": 451, "type": "identifier", "text": "effiter_U_mem", "parent": 450, "children": [], "start_point": {"row": 125, "column": 20}, "end_point": {"row": 125, "column": 33}}, {"id": 452, "type": "+", "text": "+", "parent": 450, "children": [], "start_point": {"row": 125, "column": 33}, "end_point": {"row": 125, "column": 34}}, {"id": 453, "type": "identifier", "text": "delta_effiter_U_max", "parent": 450, "children": [], "start_point": {"row": 125, "column": 34}, "end_point": {"row": 125, "column": 53}}, {"id": 454, "type": "#endif", "text": "#endif", "parent": 417, "children": [], "start_point": {"row": 126, "column": 0}, "end_point": {"row": 126, "column": 6}}, {"id": 455, "type": "assignment_expression", "text": "gl->time+=gl->dt", "parent": 222, "children": [456, 459, 460], "start_point": {"row": 128, "column": 4}, "end_point": {"row": 128, "column": 20}}, {"id": 456, "type": "field_expression", "text": "gl->time", "parent": 455, "children": [457, 458], "start_point": {"row": 128, "column": 4}, "end_point": {"row": 128, "column": 12}}, {"id": 457, "type": "identifier", "text": "gl", "parent": 456, "children": [], "start_point": {"row": 128, "column": 4}, "end_point": {"row": 128, "column": 6}}, {"id": 458, "type": "field_identifier", "text": "time", "parent": 456, "children": [], "start_point": {"row": 128, "column": 8}, "end_point": {"row": 128, "column": 12}}, {"id": 459, "type": "+=", "text": "+=", "parent": 455, "children": [], "start_point": {"row": 128, "column": 12}, "end_point": {"row": 128, "column": 14}}, {"id": 460, "type": "field_expression", "text": "gl->dt", "parent": 455, "children": [461, 462], "start_point": {"row": 128, "column": 14}, "end_point": {"row": 128, "column": 20}}, {"id": 461, "type": "identifier", "text": "gl", "parent": 460, "children": [], "start_point": {"row": 128, "column": 14}, "end_point": {"row": 128, "column": 16}}, {"id": 462, "type": "field_identifier", "text": "dt", "parent": 460, "children": [], "start_point": {"row": 128, "column": 18}, "end_point": {"row": 128, "column": 20}}, {"id": 463, "type": "call_expression", "text": "update_runtime_codex_xi_from_gl(gl,codex)", "parent": 222, "children": [464, 465], "start_point": {"row": 129, "column": 4}, "end_point": {"row": 129, "column": 45}}, {"id": 464, "type": "identifier", "text": "update_runtime_codex_xi_from_gl", "parent": 463, "children": [], "start_point": {"row": 129, "column": 4}, "end_point": {"row": 129, "column": 35}}, {"id": 465, "type": "argument_list", "text": "(gl,codex)", "parent": 463, "children": [466, 467], "start_point": {"row": 129, "column": 35}, "end_point": {"row": 129, "column": 45}}, {"id": 466, "type": "identifier", "text": "gl", "parent": 465, "children": [], "start_point": {"row": 129, "column": 36}, "end_point": {"row": 129, "column": 38}}, {"id": 467, "type": "identifier", "text": "codex", "parent": 465, "children": [], "start_point": {"row": 129, "column": 39}, "end_point": {"row": 129, "column": 44}}, {"id": 468, "type": "call_expression", "text": "add_double_to_codex(codex,\"time\",gl->time)", "parent": 222, "children": [469, 470], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 46}}, {"id": 469, "type": "identifier", "text": "add_double_to_codex", "parent": 468, "children": [], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 23}}, {"id": 470, "type": "argument_list", "text": "(codex,\"time\",gl->time)", "parent": 468, "children": [471, 472, 473], "start_point": {"row": 130, "column": 23}, "end_point": {"row": 130, "column": 46}}, {"id": 471, "type": "identifier", "text": "codex", "parent": 470, "children": [], "start_point": {"row": 130, "column": 24}, "end_point": {"row": 130, "column": 29}}, {"id": 472, "type": "string_literal", "text": "\"time\"", "parent": 470, "children": [], "start_point": {"row": 130, "column": 30}, "end_point": {"row": 130, "column": 36}}, {"id": 473, "type": "field_expression", "text": "gl->time", "parent": 470, "children": [474, 475], "start_point": {"row": 130, "column": 37}, "end_point": {"row": 130, "column": 45}}, {"id": 474, "type": "identifier", "text": "gl", "parent": 473, "children": [], "start_point": {"row": 130, "column": 37}, "end_point": {"row": 130, "column": 39}}, {"id": 475, "type": "field_identifier", "text": "time", "parent": 473, "children": [], "start_point": {"row": 130, "column": 41}, "end_point": {"row": 130, "column": 45}}, {"id": 476, "type": "assignment_expression", "text": "codex->ACTIONPROCESSED=TRUE", "parent": 222, "children": [477, 480, 481], "start_point": {"row": 131, "column": 4}, "end_point": {"row": 131, "column": 31}}, {"id": 477, "type": "field_expression", "text": "codex->ACTIONPROCESSED", "parent": 476, "children": [478, 479], "start_point": {"row": 131, "column": 4}, "end_point": {"row": 131, "column": 26}}, {"id": 478, "type": "identifier", "text": "codex", "parent": 477, "children": [], "start_point": {"row": 131, "column": 4}, "end_point": {"row": 131, "column": 9}}, {"id": 479, "type": "field_identifier", "text": "ACTIONPROCESSED", "parent": 477, "children": [], "start_point": {"row": 131, "column": 11}, "end_point": {"row": 131, "column": 26}}, {"id": 480, "type": "=", "text": "=", "parent": 476, "children": [], "start_point": {"row": 131, "column": 26}, "end_point": {"row": 131, "column": 27}}, {"id": 481, "type": "true", "text": "TRUE", "parent": 476, "children": [], "start_point": {"row": 131, "column": 27}, "end_point": {"row": 131, "column": 31}}, {"id": 482, "type": "function_definition", "text": "void init_cycle(char *argum, SOAP_codex_t *codexcontrol){\n np_t **np;\n gl_t *gl;\n\n np=((readcontrolarg_t *)codexcontrol->action_args)->np;\n gl=((readcontrolarg_t *)codexcontrol->action_args)->gl;\n\n resume_nodes_only_in_zone(*np, gl, _zone_intersection(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))));\n SOAP_copy_codex(codexcontrol,&(gl->cycle.codex));\n update_bdry_nodes(*np, gl, gl->domain);\n update_linked_nodes(*np, gl, TYPELEVEL_FLUID);\n find_residual(*np, gl, gl->domain);\n find_ximax(*np,gl,gl->domain,IJK_UPDATE_YES); \n gl->RESIDUAL_ALTERED=FALSE;\n}", "parent": null, "children": [483, 484], "start_point": {"row": 140, "column": 0}, "end_point": {"row": 154, "column": 1}}, {"id": 483, "type": "primitive_type", "text": "void", "parent": 482, "children": [], "start_point": {"row": 140, "column": 0}, "end_point": {"row": 140, "column": 4}}, {"id": 484, "type": "function_declarator", "text": "init_cycle(char *argum, SOAP_codex_t *codexcontrol)", "parent": 482, "children": [485, 486], "start_point": {"row": 140, "column": 5}, "end_point": {"row": 140, "column": 56}}, {"id": 485, "type": "identifier", "text": "init_cycle", "parent": 484, "children": [], "start_point": {"row": 140, "column": 5}, "end_point": {"row": 140, "column": 15}}, {"id": 486, "type": "parameter_list", "text": "(char *argum, SOAP_codex_t *codexcontrol)", "parent": 484, "children": [487, 492], "start_point": {"row": 140, "column": 15}, "end_point": {"row": 140, "column": 56}}, {"id": 487, "type": "parameter_declaration", "text": "char *argum", "parent": 486, "children": [488, 489], "start_point": {"row": 140, "column": 16}, "end_point": {"row": 140, "column": 27}}, {"id": 488, "type": "primitive_type", "text": "char", "parent": 487, "children": [], "start_point": {"row": 140, "column": 16}, "end_point": {"row": 140, "column": 20}}, {"id": 489, "type": "pointer_declarator", "text": "*argum", "parent": 487, "children": [490, 491], "start_point": {"row": 140, "column": 21}, "end_point": {"row": 140, "column": 27}}, {"id": 490, "type": "*", "text": "*", "parent": 489, "children": [], "start_point": {"row": 140, "column": 21}, "end_point": {"row": 140, "column": 22}}, {"id": 491, "type": "identifier", "text": "argum", "parent": 489, "children": [], "start_point": {"row": 140, "column": 22}, "end_point": {"row": 140, "column": 27}}, {"id": 492, "type": "parameter_declaration", "text": "SOAP_codex_t *codexcontrol", "parent": 486, "children": [493, 494], "start_point": {"row": 140, "column": 29}, "end_point": {"row": 140, "column": 55}}, {"id": 493, "type": "type_identifier", "text": "SOAP_codex_t", "parent": 492, "children": [], "start_point": {"row": 140, "column": 29}, "end_point": {"row": 140, "column": 41}}, {"id": 494, "type": "pointer_declarator", "text": "*codexcontrol", "parent": 492, "children": [495, 496], "start_point": {"row": 140, "column": 42}, "end_point": {"row": 140, "column": 55}}, {"id": 495, "type": "*", "text": "*", "parent": 494, "children": [], "start_point": {"row": 140, "column": 42}, "end_point": {"row": 140, "column": 43}}, {"id": 496, "type": "identifier", "text": "codexcontrol", "parent": 494, "children": [], "start_point": {"row": 140, "column": 43}, "end_point": {"row": 140, "column": 55}}, {"id": 497, "type": "declaration", "text": "np_t **np;", "parent": 482, "children": [498, 499], "start_point": {"row": 141, "column": 2}, "end_point": {"row": 141, "column": 12}}, {"id": 498, "type": "type_identifier", "text": "np_t", "parent": 497, "children": [], "start_point": {"row": 141, "column": 2}, "end_point": {"row": 141, "column": 6}}, {"id": 499, "type": "pointer_declarator", "text": "**np", "parent": 497, "children": [500, 501], "start_point": {"row": 141, "column": 7}, "end_point": {"row": 141, "column": 11}}, {"id": 500, "type": "*", "text": "*", "parent": 499, "children": [], "start_point": {"row": 141, "column": 7}, "end_point": {"row": 141, "column": 8}}, {"id": 501, "type": "pointer_declarator", "text": "*np", "parent": 499, "children": [502, 503], "start_point": {"row": 141, "column": 8}, "end_point": {"row": 141, "column": 11}}, {"id": 502, "type": "*", "text": "*", "parent": 501, "children": [], "start_point": {"row": 141, "column": 8}, "end_point": {"row": 141, "column": 9}}, {"id": 503, "type": "identifier", "text": "np", "parent": 501, "children": [], "start_point": {"row": 141, "column": 9}, "end_point": {"row": 141, "column": 11}}, {"id": 504, "type": "declaration", "text": "gl_t *gl;", "parent": 482, "children": [505, 506], "start_point": {"row": 142, "column": 2}, "end_point": {"row": 142, "column": 11}}, {"id": 505, "type": "type_identifier", "text": "gl_t", "parent": 504, "children": [], "start_point": {"row": 142, "column": 2}, "end_point": {"row": 142, "column": 6}}, {"id": 506, "type": "pointer_declarator", "text": "*gl", "parent": 504, "children": [507, 508], "start_point": {"row": 142, "column": 7}, "end_point": {"row": 142, "column": 10}}, {"id": 507, "type": "*", "text": "*", "parent": 506, "children": [], "start_point": {"row": 142, "column": 7}, "end_point": {"row": 142, "column": 8}}, {"id": 508, "type": "identifier", "text": "gl", "parent": 506, "children": [], "start_point": {"row": 142, "column": 8}, "end_point": {"row": 142, "column": 10}}, {"id": 509, "type": "assignment_expression", "text": "np=((readcontrolarg_t *)codexcontrol->action_args)->np", "parent": 482, "children": [510, 511, 512], "start_point": {"row": 144, "column": 2}, "end_point": {"row": 144, "column": 56}}, {"id": 510, "type": "identifier", "text": "np", "parent": 509, "children": [], "start_point": {"row": 144, "column": 2}, "end_point": {"row": 144, "column": 4}}, {"id": 511, "type": "=", "text": "=", "parent": 509, "children": [], "start_point": {"row": 144, "column": 4}, "end_point": {"row": 144, "column": 5}}, {"id": 512, "type": "field_expression", "text": "((readcontrolarg_t *)codexcontrol->action_args)->np", "parent": 509, "children": [513, 522], "start_point": {"row": 144, "column": 5}, "end_point": {"row": 144, "column": 56}}, {"id": 513, "type": "parenthesized_expression", "text": "((readcontrolarg_t *)codexcontrol->action_args)", "parent": 512, "children": [514], "start_point": {"row": 144, "column": 5}, "end_point": {"row": 144, "column": 52}}, {"id": 514, "type": "cast_expression", "text": "(readcontrolarg_t *)codexcontrol->action_args", "parent": 513, "children": [515, 519], "start_point": {"row": 144, "column": 6}, "end_point": {"row": 144, "column": 51}}, {"id": 515, "type": "type_descriptor", "text": "readcontrolarg_t *", "parent": 514, "children": [516, 517], "start_point": {"row": 144, "column": 7}, "end_point": {"row": 144, "column": 25}}, {"id": 516, "type": "type_identifier", "text": "readcontrolarg_t", "parent": 515, "children": [], "start_point": {"row": 144, "column": 7}, "end_point": {"row": 144, "column": 23}}, {"id": 517, "type": "abstract_pointer_declarator", "text": "*", "parent": 515, "children": [518], "start_point": {"row": 144, "column": 24}, "end_point": {"row": 144, "column": 25}}, {"id": 518, "type": "*", "text": "*", "parent": 517, "children": [], "start_point": {"row": 144, "column": 24}, "end_point": {"row": 144, "column": 25}}, {"id": 519, "type": "field_expression", "text": "codexcontrol->action_args", "parent": 514, "children": [520, 521], "start_point": {"row": 144, "column": 26}, "end_point": {"row": 144, "column": 51}}, {"id": 520, "type": "identifier", "text": "codexcontrol", "parent": 519, "children": [], "start_point": {"row": 144, "column": 26}, "end_point": {"row": 144, "column": 38}}, {"id": 521, "type": "field_identifier", "text": "action_args", "parent": 519, "children": [], "start_point": {"row": 144, "column": 40}, "end_point": {"row": 144, "column": 51}}, {"id": 522, "type": "field_identifier", "text": "np", "parent": 512, "children": [], "start_point": {"row": 144, "column": 54}, "end_point": {"row": 144, "column": 56}}, {"id": 523, "type": "assignment_expression", "text": "gl=((readcontrolarg_t *)codexcontrol->action_args)->gl", "parent": 482, "children": [524, 525, 526], "start_point": {"row": 145, "column": 2}, "end_point": {"row": 145, "column": 56}}, {"id": 524, "type": "identifier", "text": "gl", "parent": 523, "children": [], "start_point": {"row": 145, "column": 2}, "end_point": {"row": 145, "column": 4}}, {"id": 525, "type": "=", "text": "=", "parent": 523, "children": [], "start_point": {"row": 145, "column": 4}, "end_point": {"row": 145, "column": 5}}, {"id": 526, "type": "field_expression", "text": "((readcontrolarg_t *)codexcontrol->action_args)->gl", "parent": 523, "children": [527, 536], "start_point": {"row": 145, "column": 5}, "end_point": {"row": 145, "column": 56}}, {"id": 527, "type": "parenthesized_expression", "text": "((readcontrolarg_t *)codexcontrol->action_args)", "parent": 526, "children": [528], "start_point": {"row": 145, "column": 5}, "end_point": {"row": 145, "column": 52}}, {"id": 528, "type": "cast_expression", "text": "(readcontrolarg_t *)codexcontrol->action_args", "parent": 527, "children": [529, 533], "start_point": {"row": 145, "column": 6}, "end_point": {"row": 145, "column": 51}}, {"id": 529, "type": "type_descriptor", "text": "readcontrolarg_t *", "parent": 528, "children": [530, 531], "start_point": {"row": 145, "column": 7}, "end_point": {"row": 145, "column": 25}}, {"id": 530, "type": "type_identifier", "text": "readcontrolarg_t", "parent": 529, "children": [], "start_point": {"row": 145, "column": 7}, "end_point": {"row": 145, "column": 23}}, {"id": 531, "type": "abstract_pointer_declarator", "text": "*", "parent": 529, "children": [532], "start_point": {"row": 145, "column": 24}, "end_point": {"row": 145, "column": 25}}, {"id": 532, "type": "*", "text": "*", "parent": 531, "children": [], "start_point": {"row": 145, "column": 24}, "end_point": {"row": 145, "column": 25}}, {"id": 533, "type": "field_expression", "text": "codexcontrol->action_args", "parent": 528, "children": [534, 535], "start_point": {"row": 145, "column": 26}, "end_point": {"row": 145, "column": 51}}, {"id": 534, "type": "identifier", "text": "codexcontrol", "parent": 533, "children": [], "start_point": {"row": 145, "column": 26}, "end_point": {"row": 145, "column": 38}}, {"id": 535, "type": "field_identifier", "text": "action_args", "parent": 533, "children": [], "start_point": {"row": 145, "column": 40}, "end_point": {"row": 145, "column": 51}}, {"id": 536, "type": "field_identifier", "text": "gl", "parent": 526, "children": [], "start_point": {"row": 145, "column": 54}, "end_point": {"row": 145, "column": 56}}, {"id": 537, "type": "call_expression", "text": "resume_nodes_only_in_zone(*np, gl, _zone_intersection(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))))", "parent": 482, "children": [538, 539], "start_point": {"row": 147, "column": 2}, "end_point": {"row": 147, "column": 135}}, {"id": 538, "type": "identifier", "text": "resume_nodes_only_in_zone", "parent": 537, "children": [], "start_point": {"row": 147, "column": 2}, "end_point": {"row": 147, "column": 27}}, {"id": 539, "type": "argument_list", "text": "(*np, gl, _zone_intersection(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))))", "parent": 537, "children": [540, 543, 544], "start_point": {"row": 147, "column": 27}, "end_point": {"row": 147, "column": 135}}, {"id": 540, "type": "pointer_expression", "text": "*np", "parent": 539, "children": [541, 542], "start_point": {"row": 147, "column": 28}, "end_point": {"row": 147, "column": 31}}, {"id": 541, "type": "*", "text": "*", "parent": 540, "children": [], "start_point": {"row": 147, "column": 28}, "end_point": {"row": 147, "column": 29}}, {"id": 542, "type": "identifier", "text": "np", "parent": 540, "children": [], "start_point": {"row": 147, "column": 29}, "end_point": {"row": 147, "column": 31}}, {"id": 543, "type": "identifier", "text": "gl", "parent": 539, "children": [], "start_point": {"row": 147, "column": 33}, "end_point": {"row": 147, "column": 35}}, {"id": 544, "type": "call_expression", "text": "_zone_intersection(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid)))", "parent": 539, "children": [545, 546], "start_point": {"row": 147, "column": 37}, "end_point": {"row": 147, "column": 134}}, {"id": 545, "type": "identifier", "text": "_zone_intersection", "parent": 544, "children": [], "start_point": {"row": 147, "column": 37}, "end_point": {"row": 147, "column": 55}}, {"id": 546, "type": "argument_list", "text": "(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid)))", "parent": 544, "children": [547, 550], "start_point": {"row": 147, "column": 55}, "end_point": {"row": 147, "column": 134}}, {"id": 547, "type": "field_expression", "text": "gl->domain_all", "parent": 546, "children": [548, 549], "start_point": {"row": 147, "column": 56}, "end_point": {"row": 147, "column": 70}}, {"id": 548, "type": "identifier", "text": "gl", "parent": 547, "children": [], "start_point": {"row": 147, "column": 56}, "end_point": {"row": 147, "column": 58}}, {"id": 549, "type": "field_identifier", "text": "domain_all", "parent": 547, "children": [], "start_point": {"row": 147, "column": 60}, "end_point": {"row": 147, "column": 70}}, {"id": 550, "type": "call_expression", "text": "_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))", "parent": 546, "children": [551, 552], "start_point": {"row": 147, "column": 71}, "end_point": {"row": 147, "column": 133}}, {"id": 551, "type": "identifier", "text": "_zone_expansion", "parent": 550, "children": [], "start_point": {"row": 147, "column": 71}, "end_point": {"row": 147, "column": 86}}, {"id": 552, "type": "argument_list", "text": "(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))", "parent": 550, "children": [553, 556], "start_point": {"row": 147, "column": 86}, "end_point": {"row": 147, "column": 133}}, {"id": 553, "type": "field_expression", "text": "gl->domain", "parent": 552, "children": [554, 555], "start_point": {"row": 147, "column": 87}, "end_point": {"row": 147, "column": 97}}, {"id": 554, "type": "identifier", "text": "gl", "parent": 553, "children": [], "start_point": {"row": 147, "column": 87}, "end_point": {"row": 147, "column": 89}}, {"id": 555, "type": "field_identifier", "text": "domain", "parent": 553, "children": [], "start_point": {"row": 147, "column": 91}, "end_point": {"row": 147, "column": 97}}, {"id": 556, "type": "unary_expression", "text": "+max(hbw_res_fluid,hbw_bdry_fluid)", "parent": 552, "children": [557, 558], "start_point": {"row": 147, "column": 98}, "end_point": {"row": 147, "column": 132}}, {"id": 557, "type": "+", "text": "+", "parent": 556, "children": [], "start_point": {"row": 147, "column": 98}, "end_point": {"row": 147, "column": 99}}, {"id": 558, "type": "call_expression", "text": "max(hbw_res_fluid,hbw_bdry_fluid)", "parent": 556, "children": [559, 560], "start_point": {"row": 147, "column": 99}, "end_point": {"row": 147, "column": 132}}, {"id": 559, "type": "identifier", "text": "max", "parent": 558, "children": [], "start_point": {"row": 147, "column": 99}, "end_point": {"row": 147, "column": 102}}, {"id": 560, "type": "argument_list", "text": "(hbw_res_fluid,hbw_bdry_fluid)", "parent": 558, "children": [561, 562], "start_point": {"row": 147, "column": 102}, "end_point": {"row": 147, "column": 132}}, {"id": 561, "type": "identifier", "text": "hbw_res_fluid", "parent": 560, "children": [], "start_point": {"row": 147, "column": 103}, "end_point": {"row": 147, "column": 116}}, {"id": 562, "type": "identifier", "text": "hbw_bdry_fluid", "parent": 560, "children": [], "start_point": {"row": 147, "column": 117}, "end_point": {"row": 147, "column": 131}}, {"id": 563, "type": "call_expression", "text": "SOAP_copy_codex(codexcontrol,&(gl->cycle.codex))", "parent": 482, "children": [564, 565], "start_point": {"row": 148, "column": 2}, "end_point": {"row": 148, "column": 50}}, {"id": 564, "type": "identifier", "text": "SOAP_copy_codex", "parent": 563, "children": [], "start_point": {"row": 148, "column": 2}, "end_point": {"row": 148, "column": 17}}, {"id": 565, "type": "argument_list", "text": "(codexcontrol,&(gl->cycle.codex))", "parent": 563, "children": [566, 567], "start_point": {"row": 148, "column": 17}, "end_point": {"row": 148, "column": 50}}, {"id": 566, "type": "identifier", "text": "codexcontrol", "parent": 565, "children": [], "start_point": {"row": 148, "column": 18}, "end_point": {"row": 148, "column": 30}}, {"id": 567, "type": "pointer_expression", "text": "&(gl->cycle.codex)", "parent": 565, "children": [568], "start_point": {"row": 148, "column": 31}, "end_point": {"row": 148, "column": 49}}, {"id": 568, "type": "parenthesized_expression", "text": "(gl->cycle.codex)", "parent": 567, "children": [569], "start_point": {"row": 148, "column": 32}, "end_point": {"row": 148, "column": 49}}, {"id": 569, "type": "field_expression", "text": "gl->cycle.codex", "parent": 568, "children": [570, 573], "start_point": {"row": 148, "column": 33}, "end_point": {"row": 148, "column": 48}}, {"id": 570, "type": "field_expression", "text": "gl->cycle", "parent": 569, "children": [571, 572], "start_point": {"row": 148, "column": 33}, "end_point": {"row": 148, "column": 42}}, {"id": 571, "type": "identifier", "text": "gl", "parent": 570, "children": [], "start_point": {"row": 148, "column": 33}, "end_point": {"row": 148, "column": 35}}, {"id": 572, "type": "field_identifier", "text": "cycle", "parent": 570, "children": [], "start_point": {"row": 148, "column": 37}, "end_point": {"row": 148, "column": 42}}, {"id": 573, "type": "field_identifier", "text": "codex", "parent": 569, "children": [], "start_point": {"row": 148, "column": 43}, "end_point": {"row": 148, "column": 48}}, {"id": 574, "type": "call_expression", "text": "update_bdry_nodes(*np, gl, gl->domain)", "parent": 482, "children": [575, 576], "start_point": {"row": 149, "column": 2}, "end_point": {"row": 149, "column": 40}}, {"id": 575, "type": "identifier", "text": "update_bdry_nodes", "parent": 574, "children": [], "start_point": {"row": 149, "column": 2}, "end_point": {"row": 149, "column": 19}}, {"id": 576, "type": "argument_list", "text": "(*np, gl, gl->domain)", "parent": 574, "children": [577, 580, 581], "start_point": {"row": 149, "column": 19}, "end_point": {"row": 149, "column": 40}}, {"id": 577, "type": "pointer_expression", "text": "*np", "parent": 576, "children": [578, 579], "start_point": {"row": 149, "column": 20}, "end_point": {"row": 149, "column": 23}}, {"id": 578, "type": "*", "text": "*", "parent": 577, "children": [], "start_point": {"row": 149, "column": 20}, "end_point": {"row": 149, "column": 21}}, {"id": 579, "type": "identifier", "text": "np", "parent": 577, "children": [], "start_point": {"row": 149, "column": 21}, "end_point": {"row": 149, "column": 23}}, {"id": 580, "type": "identifier", "text": "gl", "parent": 576, "children": [], "start_point": {"row": 149, "column": 25}, "end_point": {"row": 149, "column": 27}}, {"id": 581, "type": "field_expression", "text": "gl->domain", "parent": 576, "children": [582, 583], "start_point": {"row": 149, "column": 29}, "end_point": {"row": 149, "column": 39}}, {"id": 582, "type": "identifier", "text": "gl", "parent": 581, "children": [], "start_point": {"row": 149, "column": 29}, "end_point": {"row": 149, "column": 31}}, {"id": 583, "type": "field_identifier", "text": "domain", "parent": 581, "children": [], "start_point": {"row": 149, "column": 33}, "end_point": {"row": 149, "column": 39}}, {"id": 584, "type": "call_expression", "text": "update_linked_nodes(*np, gl, TYPELEVEL_FLUID)", "parent": 482, "children": [585, 586], "start_point": {"row": 150, "column": 2}, "end_point": {"row": 150, "column": 47}}, {"id": 585, "type": "identifier", "text": "update_linked_nodes", "parent": 584, "children": [], "start_point": {"row": 150, "column": 2}, "end_point": {"row": 150, "column": 21}}, {"id": 586, "type": "argument_list", "text": "(*np, gl, TYPELEVEL_FLUID)", "parent": 584, "children": [587, 590, 591], "start_point": {"row": 150, "column": 21}, "end_point": {"row": 150, "column": 47}}, {"id": 587, "type": "pointer_expression", "text": "*np", "parent": 586, "children": [588, 589], "start_point": {"row": 150, "column": 22}, "end_point": {"row": 150, "column": 25}}, {"id": 588, "type": "*", "text": "*", "parent": 587, "children": [], "start_point": {"row": 150, "column": 22}, "end_point": {"row": 150, "column": 23}}, {"id": 589, "type": "identifier", "text": "np", "parent": 587, "children": [], "start_point": {"row": 150, "column": 23}, "end_point": {"row": 150, "column": 25}}, {"id": 590, "type": "identifier", "text": "gl", "parent": 586, "children": [], "start_point": {"row": 150, "column": 27}, "end_point": {"row": 150, "column": 29}}, {"id": 591, "type": "identifier", "text": "TYPELEVEL_FLUID", "parent": 586, "children": [], "start_point": {"row": 150, "column": 31}, "end_point": {"row": 150, "column": 46}}, {"id": 592, "type": "call_expression", "text": "find_residual(*np, gl, gl->domain)", "parent": 482, "children": [593, 594], "start_point": {"row": 151, "column": 2}, "end_point": {"row": 151, "column": 36}}, {"id": 593, "type": "identifier", "text": "find_residual", "parent": 592, "children": [], "start_point": {"row": 151, "column": 2}, "end_point": {"row": 151, "column": 15}}, {"id": 594, "type": "argument_list", "text": "(*np, gl, gl->domain)", "parent": 592, "children": [595, 598, 599], "start_point": {"row": 151, "column": 15}, "end_point": {"row": 151, "column": 36}}, {"id": 595, "type": "pointer_expression", "text": "*np", "parent": 594, "children": [596, 597], "start_point": {"row": 151, "column": 16}, "end_point": {"row": 151, "column": 19}}, {"id": 596, "type": "*", "text": "*", "parent": 595, "children": [], "start_point": {"row": 151, "column": 16}, "end_point": {"row": 151, "column": 17}}, {"id": 597, "type": "identifier", "text": "np", "parent": 595, "children": [], "start_point": {"row": 151, "column": 17}, "end_point": {"row": 151, "column": 19}}, {"id": 598, "type": "identifier", "text": "gl", "parent": 594, "children": [], "start_point": {"row": 151, "column": 21}, "end_point": {"row": 151, "column": 23}}, {"id": 599, "type": "field_expression", "text": "gl->domain", "parent": 594, "children": [600, 601], "start_point": {"row": 151, "column": 25}, "end_point": {"row": 151, "column": 35}}, {"id": 600, "type": "identifier", "text": "gl", "parent": 599, "children": [], "start_point": {"row": 151, "column": 25}, "end_point": {"row": 151, "column": 27}}, {"id": 601, "type": "field_identifier", "text": "domain", "parent": 599, "children": [], "start_point": {"row": 151, "column": 29}, "end_point": {"row": 151, "column": 35}}, {"id": 602, "type": "call_expression", "text": "find_ximax(*np,gl,gl->domain,IJK_UPDATE_YES)", "parent": 482, "children": [603, 604], "start_point": {"row": 152, "column": 2}, "end_point": {"row": 152, "column": 46}}, {"id": 603, "type": "identifier", "text": "find_ximax", "parent": 602, "children": [], "start_point": {"row": 152, "column": 2}, "end_point": {"row": 152, "column": 12}}, {"id": 604, "type": "argument_list", "text": "(*np,gl,gl->domain,IJK_UPDATE_YES)", "parent": 602, "children": [605, 608, 609, 612], "start_point": {"row": 152, "column": 12}, "end_point": {"row": 152, "column": 46}}, {"id": 605, "type": "pointer_expression", "text": "*np", "parent": 604, "children": [606, 607], "start_point": {"row": 152, "column": 13}, "end_point": {"row": 152, "column": 16}}, {"id": 606, "type": "*", "text": "*", "parent": 605, "children": [], "start_point": {"row": 152, "column": 13}, "end_point": {"row": 152, "column": 14}}, {"id": 607, "type": "identifier", "text": "np", "parent": 605, "children": [], "start_point": {"row": 152, "column": 14}, "end_point": {"row": 152, "column": 16}}, {"id": 608, "type": "identifier", "text": "gl", "parent": 604, "children": [], "start_point": {"row": 152, "column": 17}, "end_point": {"row": 152, "column": 19}}, {"id": 609, "type": "field_expression", "text": "gl->domain", "parent": 604, "children": [610, 611], "start_point": {"row": 152, "column": 20}, "end_point": {"row": 152, "column": 30}}, {"id": 610, "type": "identifier", "text": "gl", "parent": 609, "children": [], "start_point": {"row": 152, "column": 20}, "end_point": {"row": 152, "column": 22}}, {"id": 611, "type": "field_identifier", "text": "domain", "parent": 609, "children": [], "start_point": {"row": 152, "column": 24}, "end_point": {"row": 152, "column": 30}}, {"id": 612, "type": "identifier", "text": "IJK_UPDATE_YES", "parent": 604, "children": [], "start_point": {"row": 152, "column": 31}, "end_point": {"row": 152, "column": 45}}, {"id": 613, "type": "assignment_expression", "text": "gl->RESIDUAL_ALTERED=FALSE", "parent": 482, "children": [614, 617, 618], "start_point": {"row": 153, "column": 2}, "end_point": {"row": 153, "column": 28}}, {"id": 614, "type": "field_expression", "text": "gl->RESIDUAL_ALTERED", "parent": 613, "children": [615, 616], "start_point": {"row": 153, "column": 2}, "end_point": {"row": 153, "column": 22}}, {"id": 615, "type": "identifier", "text": "gl", "parent": 614, "children": [], "start_point": {"row": 153, "column": 2}, "end_point": {"row": 153, "column": 4}}, {"id": 616, "type": "field_identifier", "text": "RESIDUAL_ALTERED", "parent": 614, "children": [], "start_point": {"row": 153, "column": 6}, "end_point": {"row": 153, "column": 22}}, {"id": 617, "type": "=", "text": "=", "parent": 613, "children": [], "start_point": {"row": 153, "column": 22}, "end_point": {"row": 153, "column": 23}}, {"id": 618, "type": "false", "text": "FALSE", "parent": 613, "children": [], "start_point": {"row": 153, "column": 23}, "end_point": {"row": 153, "column": 28}}, {"id": 619, "type": "function_definition", "text": "void perform_one_iteration(np_t *np, gl_t *gl){\n\n\n process_code_runtime(np,gl,gl->cycle.code_runtime,&(gl->cycle.codex));\n\n\n}", "parent": null, "children": [620, 621], "start_point": {"row": 159, "column": 0}, "end_point": {"row": 165, "column": 1}}, {"id": 620, "type": "primitive_type", "text": "void", "parent": 619, "children": [], "start_point": {"row": 159, "column": 0}, "end_point": {"row": 159, "column": 4}}, {"id": 621, "type": "function_declarator", "text": "perform_one_iteration(np_t *np, gl_t *gl)", "parent": 619, "children": [622, 623], "start_point": {"row": 159, "column": 5}, "end_point": {"row": 159, "column": 46}}, {"id": 622, "type": "identifier", "text": "perform_one_iteration", "parent": 621, "children": [], "start_point": {"row": 159, "column": 5}, "end_point": {"row": 159, "column": 26}}, {"id": 623, "type": "parameter_list", "text": "(np_t *np, gl_t *gl)", "parent": 621, "children": [624, 629], "start_point": {"row": 159, "column": 26}, "end_point": {"row": 159, "column": 46}}, {"id": 624, "type": "parameter_declaration", "text": "np_t *np", "parent": 623, "children": [625, 626], "start_point": {"row": 159, "column": 27}, "end_point": {"row": 159, "column": 35}}, {"id": 625, "type": "type_identifier", "text": "np_t", "parent": 624, "children": [], "start_point": {"row": 159, "column": 27}, "end_point": {"row": 159, "column": 31}}, {"id": 626, "type": "pointer_declarator", "text": "*np", "parent": 624, "children": [627, 628], "start_point": {"row": 159, "column": 32}, "end_point": {"row": 159, "column": 35}}, {"id": 627, "type": "*", "text": "*", "parent": 626, "children": [], "start_point": {"row": 159, "column": 32}, "end_point": {"row": 159, "column": 33}}, {"id": 628, "type": "identifier", "text": "np", "parent": 626, "children": [], "start_point": {"row": 159, "column": 33}, "end_point": {"row": 159, "column": 35}}, {"id": 629, "type": "parameter_declaration", "text": "gl_t *gl", "parent": 623, "children": [630, 631], "start_point": {"row": 159, "column": 37}, "end_point": {"row": 159, "column": 45}}, {"id": 630, "type": "type_identifier", "text": "gl_t", "parent": 629, "children": [], "start_point": {"row": 159, "column": 37}, "end_point": {"row": 159, "column": 41}}, {"id": 631, "type": "pointer_declarator", "text": "*gl", "parent": 629, "children": [632, 633], "start_point": {"row": 159, "column": 42}, "end_point": {"row": 159, "column": 45}}, {"id": 632, "type": "*", "text": "*", "parent": 631, "children": [], "start_point": {"row": 159, "column": 42}, "end_point": {"row": 159, "column": 43}}, {"id": 633, "type": "identifier", "text": "gl", "parent": 631, "children": [], "start_point": {"row": 159, "column": 43}, "end_point": {"row": 159, "column": 45}}, {"id": 634, "type": "call_expression", "text": "process_code_runtime(np,gl,gl->cycle.code_runtime,&(gl->cycle.codex))", "parent": 619, "children": [635, 636], "start_point": {"row": 162, "column": 2}, "end_point": {"row": 162, "column": 71}}, {"id": 635, "type": "identifier", "text": "process_code_runtime", "parent": 634, "children": [], "start_point": {"row": 162, "column": 2}, "end_point": {"row": 162, "column": 22}}, {"id": 636, "type": "argument_list", "text": "(np,gl,gl->cycle.code_runtime,&(gl->cycle.codex))", "parent": 634, "children": [637, 638, 639, 644], "start_point": {"row": 162, "column": 22}, "end_point": {"row": 162, "column": 71}}, {"id": 637, "type": "identifier", "text": "np", "parent": 636, "children": [], "start_point": {"row": 162, "column": 23}, "end_point": {"row": 162, "column": 25}}, {"id": 638, "type": "identifier", "text": "gl", "parent": 636, "children": [], "start_point": {"row": 162, "column": 26}, "end_point": {"row": 162, "column": 28}}, {"id": 639, "type": "field_expression", "text": "gl->cycle.code_runtime", "parent": 636, "children": [640, 643], "start_point": {"row": 162, "column": 29}, "end_point": {"row": 162, "column": 51}}, {"id": 640, "type": "field_expression", "text": "gl->cycle", "parent": 639, "children": [641, 642], "start_point": {"row": 162, "column": 29}, "end_point": {"row": 162, "column": 38}}, {"id": 641, "type": "identifier", "text": "gl", "parent": 640, "children": [], "start_point": {"row": 162, "column": 29}, "end_point": {"row": 162, "column": 31}}, {"id": 642, "type": "field_identifier", "text": "cycle", "parent": 640, "children": [], "start_point": {"row": 162, "column": 33}, "end_point": {"row": 162, "column": 38}}, {"id": 643, "type": "field_identifier", "text": "code_runtime", "parent": 639, "children": [], "start_point": {"row": 162, "column": 39}, "end_point": {"row": 162, "column": 51}}, {"id": 644, "type": "pointer_expression", "text": "&(gl->cycle.codex)", "parent": 636, "children": [645], "start_point": {"row": 162, "column": 52}, "end_point": {"row": 162, "column": 70}}, {"id": 645, "type": "parenthesized_expression", "text": "(gl->cycle.codex)", "parent": 644, "children": [646], "start_point": {"row": 162, "column": 53}, "end_point": {"row": 162, "column": 70}}, {"id": 646, "type": "field_expression", "text": "gl->cycle.codex", "parent": 645, "children": [647, 650], "start_point": {"row": 162, "column": 54}, "end_point": {"row": 162, "column": 69}}, {"id": 647, "type": "field_expression", "text": "gl->cycle", "parent": 646, "children": [648, 649], "start_point": {"row": 162, "column": 54}, "end_point": {"row": 162, "column": 63}}, {"id": 648, "type": "identifier", "text": "gl", "parent": 647, "children": [], "start_point": {"row": 162, "column": 54}, "end_point": {"row": 162, "column": 56}}, {"id": 649, "type": "field_identifier", "text": "cycle", "parent": 647, "children": [], "start_point": {"row": 162, "column": 58}, "end_point": {"row": 162, "column": 63}}, {"id": 650, "type": "field_identifier", "text": "codex", "parent": 646, "children": [], "start_point": {"row": 162, "column": 64}, "end_point": {"row": 162, "column": 69}}]}, "node_categories": {"declarations": {"functions": [35, 37, 143, 145, 482, 484, 619, 621], "variables": [40, 148, 153, 160, 168, 174, 182, 187, 487, 492, 497, 504, 624, 629], "classes": [], "imports": [0, 1, 3, 4, 6, 7, 9, 10, 12, 13, 15, 16, 18, 19], "modules": [], "enums": []}, "statements": {"expressions": [47, 50, 56, 59, 67, 70, 92, 95, 135, 138, 195, 197, 198, 199, 204, 211, 212, 213, 218, 223, 224, 225, 232, 238, 239, 240, 243, 248, 254, 258, 262, 267, 268, 269, 274, 278, 281, 293, 301, 302, 303, 306, 308, 321, 325, 329, 330, 331, 332, 339, 340, 341, 342, 350, 355, 356, 360, 363, 364, 368, 373, 376, 381, 384, 389, 399, 403, 408, 411, 420, 428, 429, 434, 437, 439, 446, 450, 456, 460, 463, 468, 473, 477, 512, 513, 514, 519, 526, 527, 528, 533, 537, 540, 544, 547, 550, 553, 556, 558, 563, 567, 568, 569, 570, 574, 577, 581, 584, 587, 592, 595, 599, 602, 605, 609, 614, 634, 639, 640, 644, 645, 646, 647], "assignments": [192, 208, 253, 290, 317, 328, 349, 396, 425, 445, 455, 476, 509, 523, 613], "loops": [316, 348], "conditionals": [21, 22, 23, 27, 28, 29, 30, 34, 38, 41, 46, 48, 52, 55, 57, 61, 68, 72, 93, 97, 105, 106, 108, 109, 111, 113, 124, 125, 127, 128, 130, 132, 136, 140, 146, 152, 159, 161, 164, 165, 166, 167, 170, 171, 172, 173, 175, 177, 178, 179, 180, 181, 183, 186, 188, 191, 193, 201, 205, 206, 207, 209, 215, 219, 220, 221, 222, 226, 228, 233, 235, 236, 237, 241, 245, 249, 251, 255, 256, 259, 261, 264, 266, 270, 271, 275, 279, 282, 283, 284, 285, 286, 287, 288, 289, 291, 294, 296, 297, 298, 299, 300, 304, 307, 309, 311, 312, 313, 314, 315, 318, 322, 324, 326, 333, 334, 335, 336, 337, 343, 344, 345, 346, 347, 351, 352, 357, 358, 361, 362, 365, 366, 369, 371, 372, 374, 375, 377, 379, 380, 382, 383, 385, 387, 388, 390, 391, 392, 393, 394, 395, 397, 400, 401, 402, 404, 406, 407, 409, 410, 412, 414, 415, 416, 417, 418, 419, 421, 423, 424, 426, 430, 431, 433, 435, 438, 440, 442, 443, 444, 447, 448, 451, 453, 454, 457, 458, 461, 462, 464, 466, 467, 469, 471, 474, 475, 478, 479, 485, 491, 493, 496, 498, 503, 505, 508, 510, 516, 520, 521, 522, 524, 530, 534, 535, 536, 538, 542, 543, 545, 548, 549, 551, 554, 555, 559, 561, 562, 564, 566, 571, 572, 573, 575, 579, 580, 582, 583, 585, 589, 590, 591, 593, 597, 598, 600, 601, 603, 607, 608, 610, 611, 612, 615, 616, 622, 625, 628, 630, 633, 635, 637, 638, 641, 642, 643, 648, 649, 650], "returns": [], "exceptions": []}, "expressions": {"calls": [24, 31], "literals": [2, 5, 8, 11, 14, 17, 20, 53, 62, 63, 65, 73, 74, 76, 80, 82, 84, 86, 90, 99, 100, 102, 107, 110, 112, 114, 115, 116, 120, 122, 126, 129, 131, 133, 141, 229, 231, 247, 252, 265, 273, 277, 320, 354, 441, 472], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 35, "universal_type": "function", "name": "write_runtime_template", "text_snippet": "void write_runtime_template(FILE **controlfile){\n wfprintf(*controlfile,\n \" %s(\\n\",_CYCLE_ACTIONN"}, {"node_id": 37, "universal_type": "function", "name": "unknown", "text_snippet": "write_runtime_template(FILE **controlfile)"}, {"node_id": 143, "universal_type": "function", "name": "runtime_actions_cycle_specific", "text_snippet": "void runtime_actions_cycle_specific(char *actionname, char **argum, SOAP_codex_t *codex){\n#ifdef DIS"}, {"node_id": 145, "universal_type": "function", "name": "unknown", "text_snippet": "runtime_actions_cycle_specific(char *actionname, char **argum, SOAP_codex_t *codex)"}, {"node_id": 482, "universal_type": "function", "name": "init_cycle", "text_snippet": "void init_cycle(char *argum, SOAP_codex_t *codexcontrol){\n np_t **np;\n gl_t *gl;\n\n np=((readcontr"}, {"node_id": 484, "universal_type": "function", "name": "unknown", "text_snippet": "init_cycle(char *argum, SOAP_codex_t *codexcontrol)"}, {"node_id": 619, "universal_type": "function", "name": "perform_one_iteration", "text_snippet": "void perform_one_iteration(np_t *np, gl_t *gl){\n\n\n process_code_runtime(np,gl,gl->cycle.code_runtim"}, {"node_id": 621, "universal_type": "function", "name": "unknown", "text_snippet": "perform_one_iteration(np_t *np, gl_t *gl)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <cycle/ts/_ts.h>\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <cycle/tsemf/_tsemf.h>\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include <cycle/res/_res.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <cycle/_cycle.h>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include <cycle/share/cycle_share.h>\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include <cycle/restime/_restime.h>\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include <src/bdry.h>\n"}, {"node_id": 19, "text": "#include"}]}, "original_source_code": "// SPDX-License-Identifier: BSD-2-Clause\n/*\nCopyright 2017-2018 <NAME>\n\nRedistribution and use in source and binary forms, with or without modification, are\npermitted provided that the following conditions are met:\n\n1. Redistributions of source code must retain the above copyright notice, this list of\n conditions and the following disclaimer.\n\n2. Redistributions in binary form must reproduce the above copyright notice, this list\n of conditions and the following disclaimer in the documentation and/or other\n materials provided with the distribution.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND ANY\nEXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF \nMERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL\nTHE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, \nSPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT\nOF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS \nINTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT\nLIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\nOF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n*/\n\n#include <cycle/ts/_ts.h>\n#include <cycle/tsemf/_tsemf.h>\n#include <cycle/res/_res.h>\n#include <cycle/_cycle.h>\n#include <cycle/share/cycle_share.h>\n#include <cycle/restime/_restime.h>\n#include <src/bdry.h>\n\n#ifdef EMFIELD\n#error The Predictor Corrector cycle can not be used with EMFIELD\n#endif\n\n#ifndef _RESTIME_PREDICTOR_CORRECTOR\n#error The Predictor Corrector cycle can only be used with a predictor corrector time discretization method (RK2, RK3, etc)\n#endif\n\nvoid write_runtime_template(FILE **controlfile){\n wfprintf(*controlfile,\n \" %s(\\n\",_CYCLE_ACTIONNAME);\n wfprintf(*controlfile,\n \" tmax=1e-4; {simulation time span in seconds}\\n\"\n \" dt=tmax/30; {physical time step in seconds}\\n\"\n );\n wfprintf(*controlfile,\n \" if (time>tmax-0.1*dt,\\n\"\n \" WriteDataFile(outputfilename\\\".\\\"round(time/dt));\\n\"\n \" exit(EXIT_SUCCESS);\\n\"\n \" );\\n\"\n \" if (mod(iter,50)==1,\\n\"\n \" WriteDataFile(outputfilename\\\".\\\"round(time/dt));\\n\"\n \" );\\n\"\n );\n wfprintf(*controlfile,\n \" UpdateFluid(dt);\\n\"\n \" printf(\\\"%%E %%6ld %%9.3f %%E (%%4ld\"\n#ifdef _2DL\n \",%%4ld\"\n#endif\n#ifdef _3DL\n \",%%4ld\"\n#endif\n \")\"\n \" %%s\\\\n\\\",\\n\"\n \" time,iter,effiter_U,ximax,i_ximax,\\n\"\n \" \"\n#ifdef _2DL\n \"j_ximax,\"\n#endif\n#ifdef _3DL\n \"k_ximax,\"\n#endif\n \"clipinfo);\\n\");\n\n\n wfprintf(*controlfile,\n \" );\\n\");\n\n}\n\n\n\nvoid runtime_actions_cycle_specific(char *actionname, char **argum, SOAP_codex_t *codex){\n#ifdef DISTMPI\n double delta_effiter_U,effiter_U_mem,delta_effiter_U_max;\n#endif\n long l,flux,i,j,k;\n gl_t *gl;\n np_t *np;\n\n\n np=*((readcontrolarg_t *)codex->action_args)->np;\n gl=((readcontrolarg_t *)codex->action_args)->gl;\n\n if (strcmp(actionname,\"UpdateFluid\")==0) {\n SOAP_substitute_all_argums(argum, codex);\n if (SOAP_number_argums(*argum)!=1) SOAP_fatal_error(codex,\"Number of arguments not equal to 1 in UpdateFluid(); action.\");\n gl->dt=SOAP_get_argum_double(codex,*argum,0);\n if (gl->dt<=0.0) fatal_error(\"The time step dt must be positive when calling UpdateFluid.\");\n for_ijk(gl->domain_lim,is,js,ks,ie,je,ke){\n l=_ai(gl,i,j,k);\n if ((is_node_valid(np[_ai(gl,i,j,k)],TYPELEVEL_FLUID))){\n for (flux=0; flux<nf; flux++){\n np[l].bs->Um1[flux]=np[l].bs->U[flux];\n }\n }\n }\n\n for (gl->subiter_pc=0; gl->subiter_pc<gl->numsubiter_pc; gl->subiter_pc++){\n update_bdry_nodes(np,gl,gl->domain); \n find_residual(np, gl, gl->domain);\n find_ximax(np, gl, gl->domain, IJK_UPDATE_YES);\n#ifdef DISTMPI\n effiter_U_mem=gl->effiter_U;\n#endif\n update_U_predictor_corrector(np, gl, gl->domain);\n update_linked_nodes(np, gl, TYPELEVEL_FLUID);\n#ifdef DISTMPI\n exchange_U(np, gl);\n delta_effiter_U=gl->effiter_U-effiter_U_mem;\n MPI_Allreduce(&delta_effiter_U, &delta_effiter_U_max, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);\n gl->effiter_U=effiter_U_mem+delta_effiter_U_max;\n#endif\n }\n gl->time+=gl->dt;\n update_runtime_codex_xi_from_gl(gl,codex);\n add_double_to_codex(codex,\"time\",gl->time); \n codex->ACTIONPROCESSED=TRUE;\n }\n\n\n}\n\n\n\n\nvoid init_cycle(char *argum, SOAP_codex_t *codexcontrol){\n np_t **np;\n gl_t *gl;\n\n np=((readcontrolarg_t *)codexcontrol->action_args)->np;\n gl=((readcontrolarg_t *)codexcontrol->action_args)->gl;\n\n resume_nodes_only_in_zone(*np, gl, _zone_intersection(gl->domain_all,_zone_expansion(gl->domain,+max(hbw_res_fluid,hbw_bdry_fluid))));\n SOAP_copy_codex(codexcontrol,&(gl->cycle.codex));\n update_bdry_nodes(*np, gl, gl->domain);\n update_linked_nodes(*np, gl, TYPELEVEL_FLUID);\n find_residual(*np, gl, gl->domain);\n find_ximax(*np,gl,gl->domain,IJK_UPDATE_YES); \n gl->RESIDUAL_ALTERED=FALSE;\n}\n\n\n\n\nvoid perform_one_iteration(np_t *np, gl_t *gl){\n\n\n process_code_runtime(np,gl,gl->cycle.code_runtime,&(gl->cycle.codex));\n\n\n}\n\n"}
80,568
c
#include "stm32f10x.h" #include "stdio.h" #include "uart.h" #include "delay.h" #include "picc.h" uint8_t pKey[6] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff}; int main() { uint8_t pSnr[4] = {0,0,0,0}; uint8_t pOldSnr[4] = {0,0,0,0}; uint8_t pData[16]; uint8_t i,j, count=0; uartInit(); PCD_Init(); PCD_ConfigIsoType('A'); while(1) { if(PICC_SelectCard(pSnr) == PICC_OK){ count = 0; //when a card is on the PCD, loop returning PICC_OK and PICC_ERR, so reset the count if(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){ printf("new card "); for(i=0; i<4; i++) {pOldSnr[i] = pSnr[i]; printf("%02X", pSnr[4-i]);} printf("\n"); for(i=0; i<64; i++){ PICC_AppRead(pSnr, i, pKey, pKey, pData); printf("addr %02d: ", i); for(j=0;j<16;j++) printf("%02X ", pData[j]); printf("\n"); } } } else { //not Select card if(count<2) count++; else{ count=0; for(i=0;i<4;i++) pOldSnr[i] = 0; } } delay_ms(1000); } }
20.93
45
(translation_unit) "#include "stm32f10x.h"\n#include "stdio.h"\n#include "uart.h"\n#include "delay.h"\n#include "picc.h"\n\nuint8_t pKey[6] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff};\n\n\nint main()\n{\n uint8_t pSnr[4] = {0,0,0,0};\n uint8_t pOldSnr[4] = {0,0,0,0};\n uint8_t pData[16];\n uint8_t i,j, count=0;\n \n uartInit();\n PCD_Init();\n PCD_ConfigIsoType('A');\n\n while(1)\n {\n if(PICC_SelectCard(pSnr) == PICC_OK){\n count = 0; //when a card is on the PCD, loop returning PICC_OK and PICC_ERR, so reset the count\n if(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){\n printf("new card ");\n for(i=0; i<4; i++) {pOldSnr[i] = pSnr[i]; printf("%02X", pSnr[4-i]);}\n printf("\n");\n \n for(i=0; i<64; i++){\n PICC_AppRead(pSnr, i, pKey, pKey, pData);\n printf("addr %02d: ", i);\n for(j=0;j<16;j++)\n printf("%02X ", pData[j]);\n printf("\n");\n }\n }\n } else { //not Select card\n if(count<2) count++;\n else{\n count=0;\n for(i=0;i<4;i++)\n pOldSnr[i] = 0;\n }\n }\n delay_ms(1000);\n }\n}\n\n\n" (preproc_include) "#include "stm32f10x.h"\n" (#include) "#include" (string_literal) ""stm32f10x.h"" (") """ (string_content) "stm32f10x.h" (") """ (preproc_include) "#include "stdio.h"\n" (#include) "#include" (string_literal) ""stdio.h"" (") """ (string_content) "stdio.h" (") """ (preproc_include) "#include "uart.h"\n" (#include) "#include" (string_literal) ""uart.h"" (") """ (string_content) "uart.h" (") """ (preproc_include) "#include "delay.h"\n" (#include) "#include" (string_literal) ""delay.h"" (") """ (string_content) "delay.h" (") """ (preproc_include) "#include "picc.h"\n" (#include) "#include" (string_literal) ""picc.h"" (") """ (string_content) "picc.h" (") """ (declaration) "uint8_t pKey[6] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff};" (primitive_type) "uint8_t" (init_declarator) "pKey[6] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff}" (array_declarator) "pKey[6]" (identifier) "pKey" ([) "[" (number_literal) "6" (]) "]" (=) "=" (initializer_list) "{0xff, 0xff, 0xff, 0xff, 0xff, 0xff}" ({) "{" (number_literal) "0xff" (,) "," (number_literal) "0xff" (,) "," (number_literal) "0xff" (,) "," (number_literal) "0xff" (,) "," (number_literal) "0xff" (,) "," (number_literal) "0xff" (}) "}" (;) ";" (function_definition) "int main()\n{\n uint8_t pSnr[4] = {0,0,0,0};\n uint8_t pOldSnr[4] = {0,0,0,0};\n uint8_t pData[16];\n uint8_t i,j, count=0;\n \n uartInit();\n PCD_Init();\n PCD_ConfigIsoType('A');\n\n while(1)\n {\n if(PICC_SelectCard(pSnr) == PICC_OK){\n count = 0; //when a card is on the PCD, loop returning PICC_OK and PICC_ERR, so reset the count\n if(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){\n printf("new card ");\n for(i=0; i<4; i++) {pOldSnr[i] = pSnr[i]; printf("%02X", pSnr[4-i]);}\n printf("\n");\n \n for(i=0; i<64; i++){\n PICC_AppRead(pSnr, i, pKey, pKey, pData);\n printf("addr %02d: ", i);\n for(j=0;j<16;j++)\n printf("%02X ", pData[j]);\n printf("\n");\n }\n }\n } else { //not Select card\n if(count<2) count++;\n else{\n count=0;\n for(i=0;i<4;i++)\n pOldSnr[i] = 0;\n }\n }\n delay_ms(1000);\n }\n}" (primitive_type) "int" (function_declarator) "main()" (identifier) "main" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n uint8_t pSnr[4] = {0,0,0,0};\n uint8_t pOldSnr[4] = {0,0,0,0};\n uint8_t pData[16];\n uint8_t i,j, count=0;\n \n uartInit();\n PCD_Init();\n PCD_ConfigIsoType('A');\n\n while(1)\n {\n if(PICC_SelectCard(pSnr) == PICC_OK){\n count = 0; //when a card is on the PCD, loop returning PICC_OK and PICC_ERR, so reset the count\n if(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){\n printf("new card ");\n for(i=0; i<4; i++) {pOldSnr[i] = pSnr[i]; printf("%02X", pSnr[4-i]);}\n printf("\n");\n \n for(i=0; i<64; i++){\n PICC_AppRead(pSnr, i, pKey, pKey, pData);\n printf("addr %02d: ", i);\n for(j=0;j<16;j++)\n printf("%02X ", pData[j]);\n printf("\n");\n }\n }\n } else { //not Select card\n if(count<2) count++;\n else{\n count=0;\n for(i=0;i<4;i++)\n pOldSnr[i] = 0;\n }\n }\n delay_ms(1000);\n }\n}" ({) "{" (declaration) "uint8_t pSnr[4] = {0,0,0,0};" (primitive_type) "uint8_t" (init_declarator) "pSnr[4] = {0,0,0,0}" (array_declarator) "pSnr[4]" (identifier) "pSnr" ([) "[" (number_literal) "4" (]) "]" (=) "=" (initializer_list) "{0,0,0,0}" ({) "{" (number_literal) "0" (,) "," (number_literal) "0" (,) "," (number_literal) "0" (,) "," (number_literal) "0" (}) "}" (;) ";" (declaration) "uint8_t pOldSnr[4] = {0,0,0,0};" (primitive_type) "uint8_t" (init_declarator) "pOldSnr[4] = {0,0,0,0}" (array_declarator) "pOldSnr[4]" (identifier) "pOldSnr" ([) "[" (number_literal) "4" (]) "]" (=) "=" (initializer_list) "{0,0,0,0}" ({) "{" (number_literal) "0" (,) "," (number_literal) "0" (,) "," (number_literal) "0" (,) "," (number_literal) "0" (}) "}" (;) ";" (declaration) "uint8_t pData[16];" (primitive_type) "uint8_t" (array_declarator) "pData[16]" (identifier) "pData" ([) "[" (number_literal) "16" (]) "]" (;) ";" (declaration) "uint8_t i,j, count=0;" (primitive_type) "uint8_t" (identifier) "i" (,) "," (identifier) "j" (,) "," (init_declarator) "count=0" (identifier) "count" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "uartInit();" (call_expression) "uartInit()" (identifier) "uartInit" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "PCD_Init();" (call_expression) "PCD_Init()" (identifier) "PCD_Init" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "PCD_ConfigIsoType('A');" (call_expression) "PCD_ConfigIsoType('A')" (identifier) "PCD_ConfigIsoType" (argument_list) "('A')" (() "(" (char_literal) "'A'" (') "'" (character) "A" (') "'" ()) ")" (;) ";" (while_statement) "while(1)\n {\n if(PICC_SelectCard(pSnr) == PICC_OK){\n count = 0; //when a card is on the PCD, loop returning PICC_OK and PICC_ERR, so reset the count\n if(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){\n printf("new card ");\n for(i=0; i<4; i++) {pOldSnr[i] = pSnr[i]; printf("%02X", pSnr[4-i]);}\n printf("\n");\n \n for(i=0; i<64; i++){\n PICC_AppRead(pSnr, i, pKey, pKey, pData);\n printf("addr %02d: ", i);\n for(j=0;j<16;j++)\n printf("%02X ", pData[j]);\n printf("\n");\n }\n }\n } else { //not Select card\n if(count<2) count++;\n else{\n count=0;\n for(i=0;i<4;i++)\n pOldSnr[i] = 0;\n }\n }\n delay_ms(1000);\n }" (while) "while" (parenthesized_expression) "(1)" (() "(" (number_literal) "1" ()) ")" (compound_statement) "{\n if(PICC_SelectCard(pSnr) == PICC_OK){\n count = 0; //when a card is on the PCD, loop returning PICC_OK and PICC_ERR, so reset the count\n if(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){\n printf("new card ");\n for(i=0; i<4; i++) {pOldSnr[i] = pSnr[i]; printf("%02X", pSnr[4-i]);}\n printf("\n");\n \n for(i=0; i<64; i++){\n PICC_AppRead(pSnr, i, pKey, pKey, pData);\n printf("addr %02d: ", i);\n for(j=0;j<16;j++)\n printf("%02X ", pData[j]);\n printf("\n");\n }\n }\n } else { //not Select card\n if(count<2) count++;\n else{\n count=0;\n for(i=0;i<4;i++)\n pOldSnr[i] = 0;\n }\n }\n delay_ms(1000);\n }" ({) "{" (if_statement) "if(PICC_SelectCard(pSnr) == PICC_OK){\n count = 0; //when a card is on the PCD, loop returning PICC_OK and PICC_ERR, so reset the count\n if(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){\n printf("new card ");\n for(i=0; i<4; i++) {pOldSnr[i] = pSnr[i]; printf("%02X", pSnr[4-i]);}\n printf("\n");\n \n for(i=0; i<64; i++){\n PICC_AppRead(pSnr, i, pKey, pKey, pData);\n printf("addr %02d: ", i);\n for(j=0;j<16;j++)\n printf("%02X ", pData[j]);\n printf("\n");\n }\n }\n } else { //not Select card\n if(count<2) count++;\n else{\n count=0;\n for(i=0;i<4;i++)\n pOldSnr[i] = 0;\n }\n }" (if) "if" (parenthesized_expression) "(PICC_SelectCard(pSnr) == PICC_OK)" (() "(" (binary_expression) "PICC_SelectCard(pSnr) == PICC_OK" (call_expression) "PICC_SelectCard(pSnr)" (identifier) "PICC_SelectCard" (argument_list) "(pSnr)" (() "(" (identifier) "pSnr" ()) ")" (==) "==" (identifier) "PICC_OK" ()) ")" (compound_statement) "{\n count = 0; //when a card is on the PCD, loop returning PICC_OK and PICC_ERR, so reset the count\n if(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){\n printf("new card ");\n for(i=0; i<4; i++) {pOldSnr[i] = pSnr[i]; printf("%02X", pSnr[4-i]);}\n printf("\n");\n \n for(i=0; i<64; i++){\n PICC_AppRead(pSnr, i, pKey, pKey, pData);\n printf("addr %02d: ", i);\n for(j=0;j<16;j++)\n printf("%02X ", pData[j]);\n printf("\n");\n }\n }\n }" ({) "{" (expression_statement) "count = 0;" (assignment_expression) "count = 0" (identifier) "count" (=) "=" (number_literal) "0" (;) ";" (comment) "//when a card is on the PCD, loop returning PICC_OK and PICC_ERR, so reset the count" (if_statement) "if(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){\n printf("new card ");\n for(i=0; i<4; i++) {pOldSnr[i] = pSnr[i]; printf("%02X", pSnr[4-i]);}\n printf("\n");\n \n for(i=0; i<64; i++){\n PICC_AppRead(pSnr, i, pKey, pKey, pData);\n printf("addr %02d: ", i);\n for(j=0;j<16;j++)\n printf("%02X ", pData[j]);\n printf("\n");\n }\n }" (if) "if" (parenthesized_expression) "(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK)" (() "(" (binary_expression) "PICC_isNewCard(pSnr, pOldSnr) == PICC_OK" (call_expression) "PICC_isNewCard(pSnr, pOldSnr)" (identifier) "PICC_isNewCard" (argument_list) "(pSnr, pOldSnr)" (() "(" (identifier) "pSnr" (,) "," (identifier) "pOldSnr" ()) ")" (==) "==" (identifier) "PICC_OK" ()) ")" (compound_statement) "{\n printf("new card ");\n for(i=0; i<4; i++) {pOldSnr[i] = pSnr[i]; printf("%02X", pSnr[4-i]);}\n printf("\n");\n \n for(i=0; i<64; i++){\n PICC_AppRead(pSnr, i, pKey, pKey, pData);\n printf("addr %02d: ", i);\n for(j=0;j<16;j++)\n printf("%02X ", pData[j]);\n printf("\n");\n }\n }" ({) "{" (expression_statement) "printf("new card ");" (call_expression) "printf("new card ")" (identifier) "printf" (argument_list) "("new card ")" (() "(" (string_literal) ""new card "" (") """ (string_content) "new card " (") """ ()) ")" (;) ";" (for_statement) "for(i=0; i<4; i++) {pOldSnr[i] = pSnr[i]; printf("%02X", pSnr[4-i]);}" (for) "for" (() "(" (assignment_expression) "i=0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i<4" (identifier) "i" (<) "<" (number_literal) "4" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (compound_statement) "{pOldSnr[i] = pSnr[i]; printf("%02X", pSnr[4-i]);}" ({) "{" (expression_statement) "pOldSnr[i] = pSnr[i];" (assignment_expression) "pOldSnr[i] = pSnr[i]" (subscript_expression) "pOldSnr[i]" (identifier) "pOldSnr" ([) "[" (identifier) "i" (]) "]" (=) "=" (subscript_expression) "pSnr[i]" (identifier) "pSnr" ([) "[" (identifier) "i" (]) "]" (;) ";" (expression_statement) "printf("%02X", pSnr[4-i]);" (call_expression) "printf("%02X", pSnr[4-i])" (identifier) "printf" (argument_list) "("%02X", pSnr[4-i])" (() "(" (string_literal) ""%02X"" (") """ (string_content) "%02X" (") """ (,) "," (subscript_expression) "pSnr[4-i]" (identifier) "pSnr" ([) "[" (binary_expression) "4-i" (number_literal) "4" (-) "-" (identifier) "i" (]) "]" ()) ")" (;) ";" (}) "}" (expression_statement) "printf("\n");" (call_expression) "printf("\n")" (identifier) "printf" (argument_list) "("\n")" (() "(" (string_literal) ""\n"" (") """ (escape_sequence) "\n" (") """ ()) ")" (;) ";" (for_statement) "for(i=0; i<64; i++){\n PICC_AppRead(pSnr, i, pKey, pKey, pData);\n printf("addr %02d: ", i);\n for(j=0;j<16;j++)\n printf("%02X ", pData[j]);\n printf("\n");\n }" (for) "for" (() "(" (assignment_expression) "i=0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i<64" (identifier) "i" (<) "<" (number_literal) "64" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (compound_statement) "{\n PICC_AppRead(pSnr, i, pKey, pKey, pData);\n printf("addr %02d: ", i);\n for(j=0;j<16;j++)\n printf("%02X ", pData[j]);\n printf("\n");\n }" ({) "{" (expression_statement) "PICC_AppRead(pSnr, i, pKey, pKey, pData);" (call_expression) "PICC_AppRead(pSnr, i, pKey, pKey, pData)" (identifier) "PICC_AppRead" (argument_list) "(pSnr, i, pKey, pKey, pData)" (() "(" (identifier) "pSnr" (,) "," (identifier) "i" (,) "," (identifier) "pKey" (,) "," (identifier) "pKey" (,) "," (identifier) "pData" ()) ")" (;) ";" (expression_statement) "printf("addr %02d: ", i);" (call_expression) "printf("addr %02d: ", i)" (identifier) "printf" (argument_list) "("addr %02d: ", i)" (() "(" (string_literal) ""addr %02d: "" (") """ (string_content) "addr %02d: " (") """ (,) "," (identifier) "i" ()) ")" (;) ";" (for_statement) "for(j=0;j<16;j++)\n printf("%02X ", pData[j]);" (for) "for" (() "(" (assignment_expression) "j=0" (identifier) "j" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "j<16" (identifier) "j" (<) "<" (number_literal) "16" (;) ";" (update_expression) "j++" (identifier) "j" (++) "++" ()) ")" (expression_statement) "printf("%02X ", pData[j]);" (call_expression) "printf("%02X ", pData[j])" (identifier) "printf" (argument_list) "("%02X ", pData[j])" (() "(" (string_literal) ""%02X "" (") """ (string_content) "%02X " (") """ (,) "," (subscript_expression) "pData[j]" (identifier) "pData" ([) "[" (identifier) "j" (]) "]" ()) ")" (;) ";" (expression_statement) "printf("\n");" (call_expression) "printf("\n")" (identifier) "printf" (argument_list) "("\n")" (() "(" (string_literal) ""\n"" (") """ (escape_sequence) "\n" (") """ ()) ")" (;) ";" (}) "}" (}) "}" (}) "}" (else_clause) "else { //not Select card\n if(count<2) count++;\n else{\n count=0;\n for(i=0;i<4;i++)\n pOldSnr[i] = 0;\n }\n }" (else) "else" (compound_statement) "{ //not Select card\n if(count<2) count++;\n else{\n count=0;\n for(i=0;i<4;i++)\n pOldSnr[i] = 0;\n }\n }" ({) "{" (comment) "//not Select card" (if_statement) "if(count<2) count++;\n else{\n count=0;\n for(i=0;i<4;i++)\n pOldSnr[i] = 0;\n }" (if) "if" (parenthesized_expression) "(count<2)" (() "(" (binary_expression) "count<2" (identifier) "count" (<) "<" (number_literal) "2" ()) ")" (expression_statement) "count++;" (update_expression) "count++" (identifier) "count" (++) "++" (;) ";" (else_clause) "else{\n count=0;\n for(i=0;i<4;i++)\n pOldSnr[i] = 0;\n }" (else) "else" (compound_statement) "{\n count=0;\n for(i=0;i<4;i++)\n pOldSnr[i] = 0;\n }" ({) "{" (expression_statement) "count=0;" (assignment_expression) "count=0" (identifier) "count" (=) "=" (number_literal) "0" (;) ";" (for_statement) "for(i=0;i<4;i++)\n pOldSnr[i] = 0;" (for) "for" (() "(" (assignment_expression) "i=0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i<4" (identifier) "i" (<) "<" (number_literal) "4" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (expression_statement) "pOldSnr[i] = 0;" (assignment_expression) "pOldSnr[i] = 0" (subscript_expression) "pOldSnr[i]" (identifier) "pOldSnr" ([) "[" (identifier) "i" (]) "]" (=) "=" (number_literal) "0" (;) ";" (}) "}" (}) "}" (expression_statement) "delay_ms(1000);" (call_expression) "delay_ms(1000)" (identifier) "delay_ms" (argument_list) "(1000)" (() "(" (number_literal) "1000" ()) ")" (;) ";" (}) "}" (}) "}"
437
0
{"language": "c", "success": true, "metadata": {"lines": 45, "avg_line_length": 20.93, "nodes": 235, "errors": 0, "source_hash": "9fdd95d7da0e50b6eabe57f398095392d818aa4a8b9ea5119ddb10787bbc8adb", "categorized_nodes": 172}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"stm32f10x.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"stm32f10x.h\"", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 22}}, {"id": 3, "type": "preproc_include", "text": "#include \"stdio.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 8}}, {"id": 5, "type": "string_literal", "text": "\"stdio.h\"", "parent": 3, "children": [], "start_point": {"row": 1, "column": 9}, "end_point": {"row": 1, "column": 18}}, {"id": 6, "type": "preproc_include", "text": "#include \"uart.h\"\n", "parent": null, "children": [7, 8], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"uart.h\"", "parent": 6, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 17}}, {"id": 9, "type": "preproc_include", "text": "#include \"delay.h\"\n", "parent": null, "children": [10, 11], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"delay.h\"", "parent": 9, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 18}}, {"id": 12, "type": "preproc_include", "text": "#include \"picc.h\"\n", "parent": null, "children": [13, 14], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 14, "type": "string_literal", "text": "\"picc.h\"", "parent": 12, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 17}}, {"id": 15, "type": "declaration", "text": "uint8_t pKey[6] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff};", "parent": null, "children": [16, 17], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 55}}, {"id": 16, "type": "primitive_type", "text": "uint8_t", "parent": 15, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 7}}, {"id": 17, "type": "init_declarator", "text": "pKey[6] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff}", "parent": 15, "children": [18, 21, 22], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 54}}, {"id": 18, "type": "array_declarator", "text": "pKey[6]", "parent": 17, "children": [19, 20], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 15}}, {"id": 19, "type": "identifier", "text": "pKey", "parent": 18, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 12}}, {"id": 20, "type": "number_literal", "text": "6", "parent": 18, "children": [], "start_point": {"row": 6, "column": 13}, "end_point": {"row": 6, "column": 14}}, {"id": 21, "type": "=", "text": "=", "parent": 17, "children": [], "start_point": {"row": 6, "column": 16}, "end_point": {"row": 6, "column": 17}}, {"id": 22, "type": "initializer_list", "text": "{0xff, 0xff, 0xff, 0xff, 0xff, 0xff}", "parent": 17, "children": [23, 24, 25, 26, 27, 28], "start_point": {"row": 6, "column": 18}, "end_point": {"row": 6, "column": 54}}, {"id": 23, "type": "number_literal", "text": "0xff", "parent": 22, "children": [], "start_point": {"row": 6, "column": 19}, "end_point": {"row": 6, "column": 23}}, {"id": 24, "type": "number_literal", "text": "0xff", "parent": 22, "children": [], "start_point": {"row": 6, "column": 25}, "end_point": {"row": 6, "column": 29}}, {"id": 25, "type": "number_literal", "text": "0xff", "parent": 22, "children": [], "start_point": {"row": 6, "column": 31}, "end_point": {"row": 6, "column": 35}}, {"id": 26, "type": "number_literal", "text": "0xff", "parent": 22, "children": [], "start_point": {"row": 6, "column": 37}, "end_point": {"row": 6, "column": 41}}, {"id": 27, "type": "number_literal", "text": "0xff", "parent": 22, "children": [], "start_point": {"row": 6, "column": 43}, "end_point": {"row": 6, "column": 47}}, {"id": 28, "type": "number_literal", "text": "0xff", "parent": 22, "children": [], "start_point": {"row": 6, "column": 49}, "end_point": {"row": 6, "column": 53}}, {"id": 29, "type": "function_definition", "text": "int main()\n{\n\tuint8_t pSnr[4] = {0,0,0,0};\n\tuint8_t pOldSnr[4] = {0,0,0,0};\n\tuint8_t pData[16];\n\tuint8_t i,j, count=0;\n\t\n\tuartInit();\n\tPCD_Init();\n\tPCD_ConfigIsoType('A');\n\n\twhile(1)\n\t{\n\t\tif(PICC_SelectCard(pSnr) == PICC_OK){\n\t\t\tcount = 0;\t//when a card is on the PCD, loop returning PICC_OK and PICC_ERR, so reset the count\n\t\t\tif(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){\n\t\t\t\tprintf(\"new card \");\n\t\t\t\tfor(i=0; i<4; i++)\t{pOldSnr[i] = pSnr[i]; printf(\"%02X\", pSnr[4-i]);}\n\t\t\t\tprintf(\"\\n\");\n\t\t\t\t\n\t\t\t\tfor(i=0; i<64; i++){\n\t\t\t\t\tPICC_AppRead(pSnr, i, pKey, pKey, pData);\n\t\t\t\t\tprintf(\"addr %02d: \", i);\n\t\t\t\t\tfor(j=0;j<16;j++)\n\t\t\t\t\t\tprintf(\"%02X \", pData[j]);\n\t\t\t\t\tprintf(\"\\n\");\n\t\t\t\t}\n\t\t\t}\n\t\t}\telse {\t//not Select card\n\t\t\tif(count<2)\tcount++;\n\t\t\telse{\n\t\t\t\tcount=0;\n\t\t\t\tfor(i=0;i<4;i++)\n\t\t\t\t\tpOldSnr[i] = 0;\n\t\t\t}\n\t\t}\n\t\tdelay_ms(1000);\n\t}\n}", "parent": null, "children": [30, 31], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 47, "column": 1}}, {"id": 30, "type": "primitive_type", "text": "int", "parent": 29, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 3}}, {"id": 31, "type": "function_declarator", "text": "main()", "parent": 29, "children": [32, 33], "start_point": {"row": 9, "column": 4}, "end_point": {"row": 9, "column": 10}}, {"id": 32, "type": "identifier", "text": "main", "parent": 31, "children": [], "start_point": {"row": 9, "column": 4}, "end_point": {"row": 9, "column": 8}}, {"id": 33, "type": "parameter_list", "text": "()", "parent": 31, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 10}}, {"id": 34, "type": "declaration", "text": "uint8_t pSnr[4] = {0,0,0,0};", "parent": 29, "children": [35, 36], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 11, "column": 29}}, {"id": 35, "type": "primitive_type", "text": "uint8_t", "parent": 34, "children": [], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 11, "column": 8}}, {"id": 36, "type": "init_declarator", "text": "pSnr[4] = {0,0,0,0}", "parent": 34, "children": [37, 40, 41], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 28}}, {"id": 37, "type": "array_declarator", "text": "pSnr[4]", "parent": 36, "children": [38, 39], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 16}}, {"id": 38, "type": "identifier", "text": "pSnr", "parent": 37, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 13}}, {"id": 39, "type": "number_literal", "text": "4", "parent": 37, "children": [], "start_point": {"row": 11, "column": 14}, "end_point": {"row": 11, "column": 15}}, {"id": 40, "type": "=", "text": "=", "parent": 36, "children": [], "start_point": {"row": 11, "column": 17}, "end_point": {"row": 11, "column": 18}}, {"id": 41, "type": "initializer_list", "text": "{0,0,0,0}", "parent": 36, "children": [42, 43, 44, 45], "start_point": {"row": 11, "column": 19}, "end_point": {"row": 11, "column": 28}}, {"id": 42, "type": "number_literal", "text": "0", "parent": 41, "children": [], "start_point": {"row": 11, "column": 20}, "end_point": {"row": 11, "column": 21}}, {"id": 43, "type": "number_literal", "text": "0", "parent": 41, "children": [], "start_point": {"row": 11, "column": 22}, "end_point": {"row": 11, "column": 23}}, {"id": 44, "type": "number_literal", "text": "0", "parent": 41, "children": [], "start_point": {"row": 11, "column": 24}, "end_point": {"row": 11, "column": 25}}, {"id": 45, "type": "number_literal", "text": "0", "parent": 41, "children": [], "start_point": {"row": 11, "column": 26}, "end_point": {"row": 11, "column": 27}}, {"id": 46, "type": "declaration", "text": "uint8_t pOldSnr[4] = {0,0,0,0};", "parent": 29, "children": [47, 48], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 32}}, {"id": 47, "type": "primitive_type", "text": "uint8_t", "parent": 46, "children": [], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 8}}, {"id": 48, "type": "init_declarator", "text": "pOldSnr[4] = {0,0,0,0}", "parent": 46, "children": [49, 52, 53], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 31}}, {"id": 49, "type": "array_declarator", "text": "pOldSnr[4]", "parent": 48, "children": [50, 51], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 19}}, {"id": 50, "type": "identifier", "text": "pOldSnr", "parent": 49, "children": [], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 16}}, {"id": 51, "type": "number_literal", "text": "4", "parent": 49, "children": [], "start_point": {"row": 12, "column": 17}, "end_point": {"row": 12, "column": 18}}, {"id": 52, "type": "=", "text": "=", "parent": 48, "children": [], "start_point": {"row": 12, "column": 20}, "end_point": {"row": 12, "column": 21}}, {"id": 53, "type": "initializer_list", "text": "{0,0,0,0}", "parent": 48, "children": [54, 55, 56, 57], "start_point": {"row": 12, "column": 22}, "end_point": {"row": 12, "column": 31}}, {"id": 54, "type": "number_literal", "text": "0", "parent": 53, "children": [], "start_point": {"row": 12, "column": 23}, "end_point": {"row": 12, "column": 24}}, {"id": 55, "type": "number_literal", "text": "0", "parent": 53, "children": [], "start_point": {"row": 12, "column": 25}, "end_point": {"row": 12, "column": 26}}, {"id": 56, "type": "number_literal", "text": "0", "parent": 53, "children": [], "start_point": {"row": 12, "column": 27}, "end_point": {"row": 12, "column": 28}}, {"id": 57, "type": "number_literal", "text": "0", "parent": 53, "children": [], "start_point": {"row": 12, "column": 29}, "end_point": {"row": 12, "column": 30}}, {"id": 58, "type": "declaration", "text": "uint8_t pData[16];", "parent": 29, "children": [59, 60], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 19}}, {"id": 59, "type": "primitive_type", "text": "uint8_t", "parent": 58, "children": [], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 13, "column": 8}}, {"id": 60, "type": "array_declarator", "text": "pData[16]", "parent": 58, "children": [61, 62], "start_point": {"row": 13, "column": 9}, "end_point": {"row": 13, "column": 18}}, {"id": 61, "type": "identifier", "text": "pData", "parent": 60, "children": [], "start_point": {"row": 13, "column": 9}, "end_point": {"row": 13, "column": 14}}, {"id": 62, "type": "number_literal", "text": "16", "parent": 60, "children": [], "start_point": {"row": 13, "column": 15}, "end_point": {"row": 13, "column": 17}}, {"id": 63, "type": "declaration", "text": "uint8_t i,j, count=0;", "parent": 29, "children": [64, 65, 66, 67], "start_point": {"row": 14, "column": 1}, "end_point": {"row": 14, "column": 22}}, {"id": 64, "type": "primitive_type", "text": "uint8_t", "parent": 63, "children": [], "start_point": {"row": 14, "column": 1}, "end_point": {"row": 14, "column": 8}}, {"id": 65, "type": "identifier", "text": "i", "parent": 63, "children": [], "start_point": {"row": 14, "column": 9}, "end_point": {"row": 14, "column": 10}}, {"id": 66, "type": "identifier", "text": "j", "parent": 63, "children": [], "start_point": {"row": 14, "column": 11}, "end_point": {"row": 14, "column": 12}}, {"id": 67, "type": "init_declarator", "text": "count=0", "parent": 63, "children": [68, 69, 70], "start_point": {"row": 14, "column": 14}, "end_point": {"row": 14, "column": 21}}, {"id": 68, "type": "identifier", "text": "count", "parent": 67, "children": [], "start_point": {"row": 14, "column": 14}, "end_point": {"row": 14, "column": 19}}, {"id": 69, "type": "=", "text": "=", "parent": 67, "children": [], "start_point": {"row": 14, "column": 19}, "end_point": {"row": 14, "column": 20}}, {"id": 70, "type": "number_literal", "text": "0", "parent": 67, "children": [], "start_point": {"row": 14, "column": 20}, "end_point": {"row": 14, "column": 21}}, {"id": 71, "type": "call_expression", "text": "uartInit()", "parent": 29, "children": [72, 73], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 11}}, {"id": 72, "type": "identifier", "text": "uartInit", "parent": 71, "children": [], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 9}}, {"id": 73, "type": "argument_list", "text": "()", "parent": 71, "children": [], "start_point": {"row": 16, "column": 9}, "end_point": {"row": 16, "column": 11}}, {"id": 74, "type": "call_expression", "text": "PCD_Init()", "parent": 29, "children": [75, 76], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 11}}, {"id": 75, "type": "identifier", "text": "PCD_Init", "parent": 74, "children": [], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 9}}, {"id": 76, "type": "argument_list", "text": "()", "parent": 74, "children": [], "start_point": {"row": 17, "column": 9}, "end_point": {"row": 17, "column": 11}}, {"id": 77, "type": "call_expression", "text": "PCD_ConfigIsoType('A')", "parent": 29, "children": [78, 79], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 23}}, {"id": 78, "type": "identifier", "text": "PCD_ConfigIsoType", "parent": 77, "children": [], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 18}}, {"id": 79, "type": "argument_list", "text": "('A')", "parent": 77, "children": [80], "start_point": {"row": 18, "column": 18}, "end_point": {"row": 18, "column": 23}}, {"id": 80, "type": "char_literal", "text": "'A'", "parent": 79, "children": [81, 82, 83], "start_point": {"row": 18, "column": 19}, "end_point": {"row": 18, "column": 22}}, {"id": 81, "type": "'", "text": "'", "parent": 80, "children": [], "start_point": {"row": 18, "column": 19}, "end_point": {"row": 18, "column": 20}}, {"id": 82, "type": "character", "text": "A", "parent": 80, "children": [], "start_point": {"row": 18, "column": 20}, "end_point": {"row": 18, "column": 21}}, {"id": 83, "type": "'", "text": "'", "parent": 80, "children": [], "start_point": {"row": 18, "column": 21}, "end_point": {"row": 18, "column": 22}}, {"id": 84, "type": "while_statement", "text": "while(1)\n\t{\n\t\tif(PICC_SelectCard(pSnr) == PICC_OK){\n\t\t\tcount = 0;\t//when a card is on the PCD, loop returning PICC_OK and PICC_ERR, so reset the count\n\t\t\tif(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){\n\t\t\t\tprintf(\"new card \");\n\t\t\t\tfor(i=0; i<4; i++)\t{pOldSnr[i] = pSnr[i]; printf(\"%02X\", pSnr[4-i]);}\n\t\t\t\tprintf(\"\\n\");\n\t\t\t\t\n\t\t\t\tfor(i=0; i<64; i++){\n\t\t\t\t\tPICC_AppRead(pSnr, i, pKey, pKey, pData);\n\t\t\t\t\tprintf(\"addr %02d: \", i);\n\t\t\t\t\tfor(j=0;j<16;j++)\n\t\t\t\t\t\tprintf(\"%02X \", pData[j]);\n\t\t\t\t\tprintf(\"\\n\");\n\t\t\t\t}\n\t\t\t}\n\t\t}\telse {\t//not Select card\n\t\t\tif(count<2)\tcount++;\n\t\t\telse{\n\t\t\t\tcount=0;\n\t\t\t\tfor(i=0;i<4;i++)\n\t\t\t\t\tpOldSnr[i] = 0;\n\t\t\t}\n\t\t}\n\t\tdelay_ms(1000);\n\t}", "parent": 29, "children": [85], "start_point": {"row": 20, "column": 1}, "end_point": {"row": 46, "column": 2}}, {"id": 85, "type": "parenthesized_expression", "text": "(1)", "parent": 84, "children": [86], "start_point": {"row": 20, "column": 6}, "end_point": {"row": 20, "column": 9}}, {"id": 86, "type": "number_literal", "text": "1", "parent": 85, "children": [], "start_point": {"row": 20, "column": 7}, "end_point": {"row": 20, "column": 8}}, {"id": 87, "type": "if_statement", "text": "if(PICC_SelectCard(pSnr) == PICC_OK){\n\t\t\tcount = 0;\t//when a card is on the PCD, loop returning PICC_OK and PICC_ERR, so reset the count\n\t\t\tif(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){\n\t\t\t\tprintf(\"new card \");\n\t\t\t\tfor(i=0; i<4; i++)\t{pOldSnr[i] = pSnr[i]; printf(\"%02X\", pSnr[4-i]);}\n\t\t\t\tprintf(\"\\n\");\n\t\t\t\t\n\t\t\t\tfor(i=0; i<64; i++){\n\t\t\t\t\tPICC_AppRead(pSnr, i, pKey, pKey, pData);\n\t\t\t\t\tprintf(\"addr %02d: \", i);\n\t\t\t\t\tfor(j=0;j<16;j++)\n\t\t\t\t\t\tprintf(\"%02X \", pData[j]);\n\t\t\t\t\tprintf(\"\\n\");\n\t\t\t\t}\n\t\t\t}\n\t\t}\telse {\t//not Select card\n\t\t\tif(count<2)\tcount++;\n\t\t\telse{\n\t\t\t\tcount=0;\n\t\t\t\tfor(i=0;i<4;i++)\n\t\t\t\t\tpOldSnr[i] = 0;\n\t\t\t}\n\t\t}", "parent": 84, "children": [88, 198], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 44, "column": 3}}, {"id": 88, "type": "parenthesized_expression", "text": "(PICC_SelectCard(pSnr) == PICC_OK)", "parent": 87, "children": [89], "start_point": {"row": 22, "column": 4}, "end_point": {"row": 22, "column": 38}}, {"id": 89, "type": "binary_expression", "text": "PICC_SelectCard(pSnr) == PICC_OK", "parent": 88, "children": [90, 94, 95], "start_point": {"row": 22, "column": 5}, "end_point": {"row": 22, "column": 37}}, {"id": 90, "type": "call_expression", "text": "PICC_SelectCard(pSnr)", "parent": 89, "children": [91, 92], "start_point": {"row": 22, "column": 5}, "end_point": {"row": 22, "column": 26}}, {"id": 91, "type": "identifier", "text": "PICC_SelectCard", "parent": 90, "children": [], "start_point": {"row": 22, "column": 5}, "end_point": {"row": 22, "column": 20}}, {"id": 92, "type": "argument_list", "text": "(pSnr)", "parent": 90, "children": [93], "start_point": {"row": 22, "column": 20}, "end_point": {"row": 22, "column": 26}}, {"id": 93, "type": "identifier", "text": "pSnr", "parent": 92, "children": [], "start_point": {"row": 22, "column": 21}, "end_point": {"row": 22, "column": 25}}, {"id": 94, "type": "==", "text": "==", "parent": 89, "children": [], "start_point": {"row": 22, "column": 27}, "end_point": {"row": 22, "column": 29}}, {"id": 95, "type": "identifier", "text": "PICC_OK", "parent": 89, "children": [], "start_point": {"row": 22, "column": 30}, "end_point": {"row": 22, "column": 37}}, {"id": 96, "type": "assignment_expression", "text": "count = 0", "parent": 87, "children": [97, 98, 99], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 23, "column": 12}}, {"id": 97, "type": "identifier", "text": "count", "parent": 96, "children": [], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 23, "column": 8}}, {"id": 98, "type": "=", "text": "=", "parent": 96, "children": [], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 10}}, {"id": 99, "type": "number_literal", "text": "0", "parent": 96, "children": [], "start_point": {"row": 23, "column": 11}, "end_point": {"row": 23, "column": 12}}, {"id": 100, "type": "if_statement", "text": "if(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){\n\t\t\t\tprintf(\"new card \");\n\t\t\t\tfor(i=0; i<4; i++)\t{pOldSnr[i] = pSnr[i]; printf(\"%02X\", pSnr[4-i]);}\n\t\t\t\tprintf(\"\\n\");\n\t\t\t\t\n\t\t\t\tfor(i=0; i<64; i++){\n\t\t\t\t\tPICC_AppRead(pSnr, i, pKey, pKey, pData);\n\t\t\t\t\tprintf(\"addr %02d: \", i);\n\t\t\t\t\tfor(j=0;j<16;j++)\n\t\t\t\t\t\tprintf(\"%02X \", pData[j]);\n\t\t\t\t\tprintf(\"\\n\");\n\t\t\t\t}\n\t\t\t}", "parent": 87, "children": [101], "start_point": {"row": 24, "column": 3}, "end_point": {"row": 36, "column": 4}}, {"id": 101, "type": "parenthesized_expression", "text": "(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK)", "parent": 100, "children": [102], "start_point": {"row": 24, "column": 5}, "end_point": {"row": 24, "column": 47}}, {"id": 102, "type": "binary_expression", "text": "PICC_isNewCard(pSnr, pOldSnr) == PICC_OK", "parent": 101, "children": [103, 108, 109], "start_point": {"row": 24, "column": 6}, "end_point": {"row": 24, "column": 46}}, {"id": 103, "type": "call_expression", "text": "PICC_isNewCard(pSnr, pOldSnr)", "parent": 102, "children": [104, 105], "start_point": {"row": 24, "column": 6}, "end_point": {"row": 24, "column": 35}}, {"id": 104, "type": "identifier", "text": "PICC_isNewCard", "parent": 103, "children": [], "start_point": {"row": 24, "column": 6}, "end_point": {"row": 24, "column": 20}}, {"id": 105, "type": "argument_list", "text": "(pSnr, pOldSnr)", "parent": 103, "children": [106, 107], "start_point": {"row": 24, "column": 20}, "end_point": {"row": 24, "column": 35}}, {"id": 106, "type": "identifier", "text": "pSnr", "parent": 105, "children": [], "start_point": {"row": 24, "column": 21}, "end_point": {"row": 24, "column": 25}}, {"id": 107, "type": "identifier", "text": "pOldSnr", "parent": 105, "children": [], "start_point": {"row": 24, "column": 27}, "end_point": {"row": 24, "column": 34}}, {"id": 108, "type": "==", "text": "==", "parent": 102, "children": [], "start_point": {"row": 24, "column": 36}, "end_point": {"row": 24, "column": 38}}, {"id": 109, "type": "identifier", "text": "PICC_OK", "parent": 102, "children": [], "start_point": {"row": 24, "column": 39}, "end_point": {"row": 24, "column": 46}}, {"id": 110, "type": "call_expression", "text": "printf(\"new card \")", "parent": 100, "children": [111, 112], "start_point": {"row": 25, "column": 4}, "end_point": {"row": 25, "column": 23}}, {"id": 111, "type": "identifier", "text": "printf", "parent": 110, "children": [], "start_point": {"row": 25, "column": 4}, "end_point": {"row": 25, "column": 10}}, {"id": 112, "type": "argument_list", "text": "(\"new card \")", "parent": 110, "children": [113], "start_point": {"row": 25, "column": 10}, "end_point": {"row": 25, "column": 23}}, {"id": 113, "type": "string_literal", "text": "\"new card \"", "parent": 112, "children": [], "start_point": {"row": 25, "column": 11}, "end_point": {"row": 25, "column": 22}}, {"id": 114, "type": "for_statement", "text": "for(i=0; i<4; i++)\t{pOldSnr[i] = pSnr[i]; printf(\"%02X\", pSnr[4-i]);}", "parent": 100, "children": [115, 119, 123], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 26, "column": 73}}, {"id": 115, "type": "assignment_expression", "text": "i=0", "parent": 114, "children": [116, 117, 118], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 11}}, {"id": 116, "type": "identifier", "text": "i", "parent": 115, "children": [], "start_point": {"row": 26, "column": 8}, "end_point": {"row": 26, "column": 9}}, {"id": 117, "type": "=", "text": "=", "parent": 115, "children": [], "start_point": {"row": 26, "column": 9}, "end_point": {"row": 26, "column": 10}}, {"id": 118, "type": "number_literal", "text": "0", "parent": 115, "children": [], "start_point": {"row": 26, "column": 10}, "end_point": {"row": 26, "column": 11}}, {"id": 119, "type": "binary_expression", "text": "i<4", "parent": 114, "children": [120, 121, 122], "start_point": {"row": 26, "column": 13}, "end_point": {"row": 26, "column": 16}}, {"id": 120, "type": "identifier", "text": "i", "parent": 119, "children": [], "start_point": {"row": 26, "column": 13}, "end_point": {"row": 26, "column": 14}}, {"id": 121, "type": "<", "text": "<", "parent": 119, "children": [], "start_point": {"row": 26, "column": 14}, "end_point": {"row": 26, "column": 15}}, {"id": 122, "type": "number_literal", "text": "4", "parent": 119, "children": [], "start_point": {"row": 26, "column": 15}, "end_point": {"row": 26, "column": 16}}, {"id": 123, "type": "update_expression", "text": "i++", "parent": 114, "children": [124, 125], "start_point": {"row": 26, "column": 18}, "end_point": {"row": 26, "column": 21}}, {"id": 124, "type": "identifier", "text": "i", "parent": 123, "children": [], "start_point": {"row": 26, "column": 18}, "end_point": {"row": 26, "column": 19}}, {"id": 125, "type": "++", "text": "++", "parent": 123, "children": [], "start_point": {"row": 26, "column": 19}, "end_point": {"row": 26, "column": 21}}, {"id": 126, "type": "assignment_expression", "text": "pOldSnr[i] = pSnr[i]", "parent": 114, "children": [127, 130, 131], "start_point": {"row": 26, "column": 24}, "end_point": {"row": 26, "column": 44}}, {"id": 127, "type": "subscript_expression", "text": "pOldSnr[i]", "parent": 126, "children": [128, 129], "start_point": {"row": 26, "column": 24}, "end_point": {"row": 26, "column": 34}}, {"id": 128, "type": "identifier", "text": "pOldSnr", "parent": 127, "children": [], "start_point": {"row": 26, "column": 24}, "end_point": {"row": 26, "column": 31}}, {"id": 129, "type": "identifier", "text": "i", "parent": 127, "children": [], "start_point": {"row": 26, "column": 32}, "end_point": {"row": 26, "column": 33}}, {"id": 130, "type": "=", "text": "=", "parent": 126, "children": [], "start_point": {"row": 26, "column": 35}, "end_point": {"row": 26, "column": 36}}, {"id": 131, "type": "subscript_expression", "text": "pSnr[i]", "parent": 126, "children": [132, 133], "start_point": {"row": 26, "column": 37}, "end_point": {"row": 26, "column": 44}}, {"id": 132, "type": "identifier", "text": "pSnr", "parent": 131, "children": [], "start_point": {"row": 26, "column": 37}, "end_point": {"row": 26, "column": 41}}, {"id": 133, "type": "identifier", "text": "i", "parent": 131, "children": [], "start_point": {"row": 26, "column": 42}, "end_point": {"row": 26, "column": 43}}, {"id": 134, "type": "call_expression", "text": "printf(\"%02X\", pSnr[4-i])", "parent": 114, "children": [135, 136], "start_point": {"row": 26, "column": 46}, "end_point": {"row": 26, "column": 71}}, {"id": 135, "type": "identifier", "text": "printf", "parent": 134, "children": [], "start_point": {"row": 26, "column": 46}, "end_point": {"row": 26, "column": 52}}, {"id": 136, "type": "argument_list", "text": "(\"%02X\", pSnr[4-i])", "parent": 134, "children": [137, 138], "start_point": {"row": 26, "column": 52}, "end_point": {"row": 26, "column": 71}}, {"id": 137, "type": "string_literal", "text": "\"%02X\"", "parent": 136, "children": [], "start_point": {"row": 26, "column": 53}, "end_point": {"row": 26, "column": 59}}, {"id": 138, "type": "subscript_expression", "text": "pSnr[4-i]", "parent": 136, "children": [139, 140], "start_point": {"row": 26, "column": 61}, "end_point": {"row": 26, "column": 70}}, {"id": 139, "type": "identifier", "text": "pSnr", "parent": 138, "children": [], "start_point": {"row": 26, "column": 61}, "end_point": {"row": 26, "column": 65}}, {"id": 140, "type": "binary_expression", "text": "4-i", "parent": 138, "children": [141, 142, 143], "start_point": {"row": 26, "column": 66}, "end_point": {"row": 26, "column": 69}}, {"id": 141, "type": "number_literal", "text": "4", "parent": 140, "children": [], "start_point": {"row": 26, "column": 66}, "end_point": {"row": 26, "column": 67}}, {"id": 142, "type": "-", "text": "-", "parent": 140, "children": [], "start_point": {"row": 26, "column": 67}, "end_point": {"row": 26, "column": 68}}, {"id": 143, "type": "identifier", "text": "i", "parent": 140, "children": [], "start_point": {"row": 26, "column": 68}, "end_point": {"row": 26, "column": 69}}, {"id": 144, "type": "call_expression", "text": "printf(\"\\n\")", "parent": 100, "children": [145, 146], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 16}}, {"id": 145, "type": "identifier", "text": "printf", "parent": 144, "children": [], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 10}}, {"id": 146, "type": "argument_list", "text": "(\"\\n\")", "parent": 144, "children": [147], "start_point": {"row": 27, "column": 10}, "end_point": {"row": 27, "column": 16}}, {"id": 147, "type": "string_literal", "text": "\"\\n\"", "parent": 146, "children": [148], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 15}}, {"id": 148, "type": "escape_sequence", "text": "\\n", "parent": 147, "children": [], "start_point": {"row": 27, "column": 12}, "end_point": {"row": 27, "column": 14}}, {"id": 149, "type": "for_statement", "text": "for(i=0; i<64; i++){\n\t\t\t\t\tPICC_AppRead(pSnr, i, pKey, pKey, pData);\n\t\t\t\t\tprintf(\"addr %02d: \", i);\n\t\t\t\t\tfor(j=0;j<16;j++)\n\t\t\t\t\t\tprintf(\"%02X \", pData[j]);\n\t\t\t\t\tprintf(\"\\n\");\n\t\t\t\t}", "parent": 100, "children": [150, 154, 158], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 35, "column": 5}}, {"id": 150, "type": "assignment_expression", "text": "i=0", "parent": 149, "children": [151, 152, 153], "start_point": {"row": 29, "column": 8}, "end_point": {"row": 29, "column": 11}}, {"id": 151, "type": "identifier", "text": "i", "parent": 150, "children": [], "start_point": {"row": 29, "column": 8}, "end_point": {"row": 29, "column": 9}}, {"id": 152, "type": "=", "text": "=", "parent": 150, "children": [], "start_point": {"row": 29, "column": 9}, "end_point": {"row": 29, "column": 10}}, {"id": 153, "type": "number_literal", "text": "0", "parent": 150, "children": [], "start_point": {"row": 29, "column": 10}, "end_point": {"row": 29, "column": 11}}, {"id": 154, "type": "binary_expression", "text": "i<64", "parent": 149, "children": [155, 156, 157], "start_point": {"row": 29, "column": 13}, "end_point": {"row": 29, "column": 17}}, {"id": 155, "type": "identifier", "text": "i", "parent": 154, "children": [], "start_point": {"row": 29, "column": 13}, "end_point": {"row": 29, "column": 14}}, {"id": 156, "type": "<", "text": "<", "parent": 154, "children": [], "start_point": {"row": 29, "column": 14}, "end_point": {"row": 29, "column": 15}}, {"id": 157, "type": "number_literal", "text": "64", "parent": 154, "children": [], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 17}}, {"id": 158, "type": "update_expression", "text": "i++", "parent": 149, "children": [159, 160], "start_point": {"row": 29, "column": 19}, "end_point": {"row": 29, "column": 22}}, {"id": 159, "type": "identifier", "text": "i", "parent": 158, "children": [], "start_point": {"row": 29, "column": 19}, "end_point": {"row": 29, "column": 20}}, {"id": 160, "type": "++", "text": "++", "parent": 158, "children": [], "start_point": {"row": 29, "column": 20}, "end_point": {"row": 29, "column": 22}}, {"id": 161, "type": "call_expression", "text": "PICC_AppRead(pSnr, i, pKey, pKey, pData)", "parent": 149, "children": [162, 163], "start_point": {"row": 30, "column": 5}, "end_point": {"row": 30, "column": 45}}, {"id": 162, "type": "identifier", "text": "PICC_AppRead", "parent": 161, "children": [], "start_point": {"row": 30, "column": 5}, "end_point": {"row": 30, "column": 17}}, {"id": 163, "type": "argument_list", "text": "(pSnr, i, pKey, pKey, pData)", "parent": 161, "children": [164, 165, 166, 167, 168], "start_point": {"row": 30, "column": 17}, "end_point": {"row": 30, "column": 45}}, {"id": 164, "type": "identifier", "text": "pSnr", "parent": 163, "children": [], "start_point": {"row": 30, "column": 18}, "end_point": {"row": 30, "column": 22}}, {"id": 165, "type": "identifier", "text": "i", "parent": 163, "children": [], "start_point": {"row": 30, "column": 24}, "end_point": {"row": 30, "column": 25}}, {"id": 166, "type": "identifier", "text": "pKey", "parent": 163, "children": [], "start_point": {"row": 30, "column": 27}, "end_point": {"row": 30, "column": 31}}, {"id": 167, "type": "identifier", "text": "pKey", "parent": 163, "children": [], "start_point": {"row": 30, "column": 33}, "end_point": {"row": 30, "column": 37}}, {"id": 168, "type": "identifier", "text": "pData", "parent": 163, "children": [], "start_point": {"row": 30, "column": 39}, "end_point": {"row": 30, "column": 44}}, {"id": 169, "type": "call_expression", "text": "printf(\"addr %02d: \", i)", "parent": 149, "children": [170, 171], "start_point": {"row": 31, "column": 5}, "end_point": {"row": 31, "column": 29}}, {"id": 170, "type": "identifier", "text": "printf", "parent": 169, "children": [], "start_point": {"row": 31, "column": 5}, "end_point": {"row": 31, "column": 11}}, {"id": 171, "type": "argument_list", "text": "(\"addr %02d: \", i)", "parent": 169, "children": [172, 173], "start_point": {"row": 31, "column": 11}, "end_point": {"row": 31, "column": 29}}, {"id": 172, "type": "string_literal", "text": "\"addr %02d: \"", "parent": 171, "children": [], "start_point": {"row": 31, "column": 12}, "end_point": {"row": 31, "column": 25}}, {"id": 173, "type": "identifier", "text": "i", "parent": 171, "children": [], "start_point": {"row": 31, "column": 27}, "end_point": {"row": 31, "column": 28}}, {"id": 174, "type": "for_statement", "text": "for(j=0;j<16;j++)\n\t\t\t\t\t\tprintf(\"%02X \", pData[j]);", "parent": 149, "children": [175, 179, 183], "start_point": {"row": 32, "column": 5}, "end_point": {"row": 33, "column": 32}}, {"id": 175, "type": "assignment_expression", "text": "j=0", "parent": 174, "children": [176, 177, 178], "start_point": {"row": 32, "column": 9}, "end_point": {"row": 32, "column": 12}}, {"id": 176, "type": "identifier", "text": "j", "parent": 175, "children": [], "start_point": {"row": 32, "column": 9}, "end_point": {"row": 32, "column": 10}}, {"id": 177, "type": "=", "text": "=", "parent": 175, "children": [], "start_point": {"row": 32, "column": 10}, "end_point": {"row": 32, "column": 11}}, {"id": 178, "type": "number_literal", "text": "0", "parent": 175, "children": [], "start_point": {"row": 32, "column": 11}, "end_point": {"row": 32, "column": 12}}, {"id": 179, "type": "binary_expression", "text": "j<16", "parent": 174, "children": [180, 181, 182], "start_point": {"row": 32, "column": 13}, "end_point": {"row": 32, "column": 17}}, {"id": 180, "type": "identifier", "text": "j", "parent": 179, "children": [], "start_point": {"row": 32, "column": 13}, "end_point": {"row": 32, "column": 14}}, {"id": 181, "type": "<", "text": "<", "parent": 179, "children": [], "start_point": {"row": 32, "column": 14}, "end_point": {"row": 32, "column": 15}}, {"id": 182, "type": "number_literal", "text": "16", "parent": 179, "children": [], "start_point": {"row": 32, "column": 15}, "end_point": {"row": 32, "column": 17}}, {"id": 183, "type": "update_expression", "text": "j++", "parent": 174, "children": [184, 185], "start_point": {"row": 32, "column": 18}, "end_point": {"row": 32, "column": 21}}, {"id": 184, "type": "identifier", "text": "j", "parent": 183, "children": [], "start_point": {"row": 32, "column": 18}, "end_point": {"row": 32, "column": 19}}, {"id": 185, "type": "++", "text": "++", "parent": 183, "children": [], "start_point": {"row": 32, "column": 19}, "end_point": {"row": 32, "column": 21}}, {"id": 186, "type": "call_expression", "text": "printf(\"%02X \", pData[j])", "parent": 174, "children": [187, 188], "start_point": {"row": 33, "column": 6}, "end_point": {"row": 33, "column": 31}}, {"id": 187, "type": "identifier", "text": "printf", "parent": 186, "children": [], "start_point": {"row": 33, "column": 6}, "end_point": {"row": 33, "column": 12}}, {"id": 188, "type": "argument_list", "text": "(\"%02X \", pData[j])", "parent": 186, "children": [189, 190], "start_point": {"row": 33, "column": 12}, "end_point": {"row": 33, "column": 31}}, {"id": 189, "type": "string_literal", "text": "\"%02X \"", "parent": 188, "children": [], "start_point": {"row": 33, "column": 13}, "end_point": {"row": 33, "column": 20}}, {"id": 190, "type": "subscript_expression", "text": "pData[j]", "parent": 188, "children": [191, 192], "start_point": {"row": 33, "column": 22}, "end_point": {"row": 33, "column": 30}}, {"id": 191, "type": "identifier", "text": "pData", "parent": 190, "children": [], "start_point": {"row": 33, "column": 22}, "end_point": {"row": 33, "column": 27}}, {"id": 192, "type": "identifier", "text": "j", "parent": 190, "children": [], "start_point": {"row": 33, "column": 28}, "end_point": {"row": 33, "column": 29}}, {"id": 193, "type": "call_expression", "text": "printf(\"\\n\")", "parent": 149, "children": [194, 195], "start_point": {"row": 34, "column": 5}, "end_point": {"row": 34, "column": 17}}, {"id": 194, "type": "identifier", "text": "printf", "parent": 193, "children": [], "start_point": {"row": 34, "column": 5}, "end_point": {"row": 34, "column": 11}}, {"id": 195, "type": "argument_list", "text": "(\"\\n\")", "parent": 193, "children": [196], "start_point": {"row": 34, "column": 11}, "end_point": {"row": 34, "column": 17}}, {"id": 196, "type": "string_literal", "text": "\"\\n\"", "parent": 195, "children": [197], "start_point": {"row": 34, "column": 12}, "end_point": {"row": 34, "column": 16}}, {"id": 197, "type": "escape_sequence", "text": "\\n", "parent": 196, "children": [], "start_point": {"row": 34, "column": 13}, "end_point": {"row": 34, "column": 15}}, {"id": 198, "type": "else_clause", "text": "else {\t//not Select card\n\t\t\tif(count<2)\tcount++;\n\t\t\telse{\n\t\t\t\tcount=0;\n\t\t\t\tfor(i=0;i<4;i++)\n\t\t\t\t\tpOldSnr[i] = 0;\n\t\t\t}\n\t\t}", "parent": 87, "children": [], "start_point": {"row": 37, "column": 4}, "end_point": {"row": 44, "column": 3}}, {"id": 199, "type": "if_statement", "text": "if(count<2)\tcount++;\n\t\t\telse{\n\t\t\t\tcount=0;\n\t\t\t\tfor(i=0;i<4;i++)\n\t\t\t\t\tpOldSnr[i] = 0;\n\t\t\t}", "parent": 198, "children": [200, 208], "start_point": {"row": 38, "column": 3}, "end_point": {"row": 43, "column": 4}}, {"id": 200, "type": "parenthesized_expression", "text": "(count<2)", "parent": 199, "children": [201], "start_point": {"row": 38, "column": 5}, "end_point": {"row": 38, "column": 14}}, {"id": 201, "type": "binary_expression", "text": "count<2", "parent": 200, "children": [202, 203, 204], "start_point": {"row": 38, "column": 6}, "end_point": {"row": 38, "column": 13}}, {"id": 202, "type": "identifier", "text": "count", "parent": 201, "children": [], "start_point": {"row": 38, "column": 6}, "end_point": {"row": 38, "column": 11}}, {"id": 203, "type": "<", "text": "<", "parent": 201, "children": [], "start_point": {"row": 38, "column": 11}, "end_point": {"row": 38, "column": 12}}, {"id": 204, "type": "number_literal", "text": "2", "parent": 201, "children": [], "start_point": {"row": 38, "column": 12}, "end_point": {"row": 38, "column": 13}}, {"id": 205, "type": "update_expression", "text": "count++", "parent": 199, "children": [206, 207], "start_point": {"row": 38, "column": 15}, "end_point": {"row": 38, "column": 22}}, {"id": 206, "type": "identifier", "text": "count", "parent": 205, "children": [], "start_point": {"row": 38, "column": 15}, "end_point": {"row": 38, "column": 20}}, {"id": 207, "type": "++", "text": "++", "parent": 205, "children": [], "start_point": {"row": 38, "column": 20}, "end_point": {"row": 38, "column": 22}}, {"id": 208, "type": "else_clause", "text": "else{\n\t\t\t\tcount=0;\n\t\t\t\tfor(i=0;i<4;i++)\n\t\t\t\t\tpOldSnr[i] = 0;\n\t\t\t}", "parent": 199, "children": [], "start_point": {"row": 39, "column": 3}, "end_point": {"row": 43, "column": 4}}, {"id": 209, "type": "assignment_expression", "text": "count=0", "parent": 208, "children": [210, 211, 212], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 40, "column": 11}}, {"id": 210, "type": "identifier", "text": "count", "parent": 209, "children": [], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 40, "column": 9}}, {"id": 211, "type": "=", "text": "=", "parent": 209, "children": [], "start_point": {"row": 40, "column": 9}, "end_point": {"row": 40, "column": 10}}, {"id": 212, "type": "number_literal", "text": "0", "parent": 209, "children": [], "start_point": {"row": 40, "column": 10}, "end_point": {"row": 40, "column": 11}}, {"id": 213, "type": "for_statement", "text": "for(i=0;i<4;i++)\n\t\t\t\t\tpOldSnr[i] = 0;", "parent": 208, "children": [214, 218, 222], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 42, "column": 20}}, {"id": 214, "type": "assignment_expression", "text": "i=0", "parent": 213, "children": [215, 216, 217], "start_point": {"row": 41, "column": 8}, "end_point": {"row": 41, "column": 11}}, {"id": 215, "type": "identifier", "text": "i", "parent": 214, "children": [], "start_point": {"row": 41, "column": 8}, "end_point": {"row": 41, "column": 9}}, {"id": 216, "type": "=", "text": "=", "parent": 214, "children": [], "start_point": {"row": 41, "column": 9}, "end_point": {"row": 41, "column": 10}}, {"id": 217, "type": "number_literal", "text": "0", "parent": 214, "children": [], "start_point": {"row": 41, "column": 10}, "end_point": {"row": 41, "column": 11}}, {"id": 218, "type": "binary_expression", "text": "i<4", "parent": 213, "children": [219, 220, 221], "start_point": {"row": 41, "column": 12}, "end_point": {"row": 41, "column": 15}}, {"id": 219, "type": "identifier", "text": "i", "parent": 218, "children": [], "start_point": {"row": 41, "column": 12}, "end_point": {"row": 41, "column": 13}}, {"id": 220, "type": "<", "text": "<", "parent": 218, "children": [], "start_point": {"row": 41, "column": 13}, "end_point": {"row": 41, "column": 14}}, {"id": 221, "type": "number_literal", "text": "4", "parent": 218, "children": [], "start_point": {"row": 41, "column": 14}, "end_point": {"row": 41, "column": 15}}, {"id": 222, "type": "update_expression", "text": "i++", "parent": 213, "children": [223, 224], "start_point": {"row": 41, "column": 16}, "end_point": {"row": 41, "column": 19}}, {"id": 223, "type": "identifier", "text": "i", "parent": 222, "children": [], "start_point": {"row": 41, "column": 16}, "end_point": {"row": 41, "column": 17}}, {"id": 224, "type": "++", "text": "++", "parent": 222, "children": [], "start_point": {"row": 41, "column": 17}, "end_point": {"row": 41, "column": 19}}, {"id": 225, "type": "assignment_expression", "text": "pOldSnr[i] = 0", "parent": 213, "children": [226, 229, 230], "start_point": {"row": 42, "column": 5}, "end_point": {"row": 42, "column": 19}}, {"id": 226, "type": "subscript_expression", "text": "pOldSnr[i]", "parent": 225, "children": [227, 228], "start_point": {"row": 42, "column": 5}, "end_point": {"row": 42, "column": 15}}, {"id": 227, "type": "identifier", "text": "pOldSnr", "parent": 226, "children": [], "start_point": {"row": 42, "column": 5}, "end_point": {"row": 42, "column": 12}}, {"id": 228, "type": "identifier", "text": "i", "parent": 226, "children": [], "start_point": {"row": 42, "column": 13}, "end_point": {"row": 42, "column": 14}}, {"id": 229, "type": "=", "text": "=", "parent": 225, "children": [], "start_point": {"row": 42, "column": 16}, "end_point": {"row": 42, "column": 17}}, {"id": 230, "type": "number_literal", "text": "0", "parent": 225, "children": [], "start_point": {"row": 42, "column": 18}, "end_point": {"row": 42, "column": 19}}, {"id": 231, "type": "call_expression", "text": "delay_ms(1000)", "parent": 84, "children": [232, 233], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 16}}, {"id": 232, "type": "identifier", "text": "delay_ms", "parent": 231, "children": [], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 10}}, {"id": 233, "type": "argument_list", "text": "(1000)", "parent": 231, "children": [234], "start_point": {"row": 45, "column": 10}, "end_point": {"row": 45, "column": 16}}, {"id": 234, "type": "number_literal", "text": "1000", "parent": 233, "children": [], "start_point": {"row": 45, "column": 11}, "end_point": {"row": 45, "column": 15}}]}, "node_categories": {"declarations": {"functions": [29, 31], "variables": [15, 34, 46, 58, 63], "classes": [], "imports": [0, 1, 3, 4, 6, 7, 9, 10, 12, 13], "modules": [], "enums": []}, "statements": {"expressions": [71, 74, 77, 85, 88, 89, 90, 101, 102, 103, 110, 119, 123, 127, 131, 134, 138, 140, 144, 154, 158, 161, 169, 179, 183, 186, 190, 193, 200, 201, 205, 218, 222, 226, 231], "assignments": [96, 115, 126, 150, 175, 209, 214, 225], "loops": [84, 114, 149, 174, 213], "conditionals": [19, 32, 38, 50, 61, 65, 66, 68, 72, 75, 78, 87, 91, 93, 95, 97, 100, 104, 106, 107, 109, 111, 116, 120, 124, 128, 129, 132, 133, 135, 139, 143, 145, 151, 155, 159, 162, 164, 165, 166, 167, 168, 170, 173, 176, 180, 184, 187, 191, 192, 194, 199, 202, 206, 210, 215, 219, 223, 227, 228, 232], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 8, 11, 14, 20, 23, 24, 25, 26, 27, 28, 39, 42, 43, 44, 45, 51, 54, 55, 56, 57, 62, 70, 80, 86, 99, 113, 118, 122, 137, 141, 147, 153, 157, 172, 178, 182, 189, 196, 204, 212, 217, 221, 230, 234], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 29, "universal_type": "function", "name": "main", "text_snippet": "int main()\n{\n\tuint8_t pSnr[4] = {0,0,0,0};\n\tuint8_t pOldSnr[4] = {0,0,0,0};\n\tuint8_t pData[16];\n\tuin"}, {"node_id": 31, "universal_type": "function", "name": "unknown", "text_snippet": "main()"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include \"stm32f10x.h\"\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include \"stdio.h\"\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include \"uart.h\"\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include \"delay.h\"\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include \"picc.h\"\n"}, {"node_id": 13, "text": "#include"}]}, "original_source_code": "#include \"stm32f10x.h\"\n#include \"stdio.h\"\n#include \"uart.h\"\n#include \"delay.h\"\n#include \"picc.h\"\n\nuint8_t pKey[6] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff};\n\n\nint main()\n{\n\tuint8_t pSnr[4] = {0,0,0,0};\n\tuint8_t pOldSnr[4] = {0,0,0,0};\n\tuint8_t pData[16];\n\tuint8_t i,j, count=0;\n\t\n\tuartInit();\n\tPCD_Init();\n\tPCD_ConfigIsoType('A');\n\n\twhile(1)\n\t{\n\t\tif(PICC_SelectCard(pSnr) == PICC_OK){\n\t\t\tcount = 0;\t//when a card is on the PCD, loop returning PICC_OK and PICC_ERR, so reset the count\n\t\t\tif(PICC_isNewCard(pSnr, pOldSnr) == PICC_OK){\n\t\t\t\tprintf(\"new card \");\n\t\t\t\tfor(i=0; i<4; i++)\t{pOldSnr[i] = pSnr[i]; printf(\"%02X\", pSnr[4-i]);}\n\t\t\t\tprintf(\"\\n\");\n\t\t\t\t\n\t\t\t\tfor(i=0; i<64; i++){\n\t\t\t\t\tPICC_AppRead(pSnr, i, pKey, pKey, pData);\n\t\t\t\t\tprintf(\"addr %02d: \", i);\n\t\t\t\t\tfor(j=0;j<16;j++)\n\t\t\t\t\t\tprintf(\"%02X \", pData[j]);\n\t\t\t\t\tprintf(\"\\n\");\n\t\t\t\t}\n\t\t\t}\n\t\t}\telse {\t//not Select card\n\t\t\tif(count<2)\tcount++;\n\t\t\telse{\n\t\t\t\tcount=0;\n\t\t\t\tfor(i=0;i<4;i++)\n\t\t\t\t\tpOldSnr[i] = 0;\n\t\t\t}\n\t\t}\n\t\tdelay_ms(1000);\n\t}\n}\n\n\n"}
80,569
c
#include "SDL.h" class checkCollision{ public: bool checkCol(SDL_Rect &A, SDL_Rect &B); };
17.4
5
(translation_unit) "#include "SDL.h"\n\nclass checkCollision{\n\npublic:\n bool checkCol(SDL_Rect &A, SDL_Rect &B);\n\n};" (preproc_include) "#include "SDL.h"\n" (#include) "#include" (string_literal) ""SDL.h"" (") """ (string_content) "SDL.h" (") """ (function_definition) "class checkCollision{\n\npublic:\n bool checkCol(SDL_Rect &A, SDL_Rect &B);\n\n}" (type_identifier) "class" (identifier) "checkCollision" (compound_statement) "{\n\npublic:\n bool checkCol(SDL_Rect &A, SDL_Rect &B);\n\n}" ({) "{" (labeled_statement) "public:\n bool checkCol(SDL_Rect &A, SDL_Rect &B);" (statement_identifier) "public" (:) ":" (declaration) "bool checkCol(SDL_Rect &A, SDL_Rect &B);" (primitive_type) "bool" (function_declarator) "checkCol(SDL_Rect &A, SDL_Rect &B)" (identifier) "checkCol" (parameter_list) "(SDL_Rect &A, SDL_Rect &B)" (() "(" (parameter_declaration) "SDL_Rect &A" (type_identifier) "SDL_Rect" (ERROR) "&" (&) "&" (identifier) "A" (,) "," (parameter_declaration) "SDL_Rect &B" (type_identifier) "SDL_Rect" (ERROR) "&" (&) "&" (identifier) "B" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";"
37
2
{"language": "c", "success": true, "metadata": {"lines": 5, "avg_line_length": 17.4, "nodes": 17, "errors": 0, "source_hash": "51298f559ced4bec22ce6b48bda0b3bb5ac65ebf6ebdd5d476e1faaeb2127186", "categorized_nodes": 14}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"SDL.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"SDL.h\"", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 16}}, {"id": 3, "type": "function_definition", "text": "class checkCollision{\n\npublic:\n\tbool checkCol(SDL_Rect &A, SDL_Rect &B);\n\n}", "parent": null, "children": [4], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 7, "column": 1}}, {"id": 4, "type": "identifier", "text": "checkCollision", "parent": 3, "children": [], "start_point": {"row": 2, "column": 6}, "end_point": {"row": 2, "column": 20}}, {"id": 5, "type": "labeled_statement", "text": "public:\n\tbool checkCol(SDL_Rect &A, SDL_Rect &B);", "parent": 3, "children": [6], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 41}}, {"id": 6, "type": "declaration", "text": "bool checkCol(SDL_Rect &A, SDL_Rect &B);", "parent": 5, "children": [7, 8], "start_point": {"row": 5, "column": 1}, "end_point": {"row": 5, "column": 41}}, {"id": 7, "type": "primitive_type", "text": "bool", "parent": 6, "children": [], "start_point": {"row": 5, "column": 1}, "end_point": {"row": 5, "column": 5}}, {"id": 8, "type": "function_declarator", "text": "checkCol(SDL_Rect &A, SDL_Rect &B)", "parent": 6, "children": [9, 10], "start_point": {"row": 5, "column": 6}, "end_point": {"row": 5, "column": 40}}, {"id": 9, "type": "identifier", "text": "checkCol", "parent": 8, "children": [], "start_point": {"row": 5, "column": 6}, "end_point": {"row": 5, "column": 14}}, {"id": 10, "type": "parameter_list", "text": "(SDL_Rect &A, SDL_Rect &B)", "parent": 8, "children": [11, 14], "start_point": {"row": 5, "column": 14}, "end_point": {"row": 5, "column": 40}}, {"id": 11, "type": "parameter_declaration", "text": "SDL_Rect &A", "parent": 10, "children": [12, 13], "start_point": {"row": 5, "column": 15}, "end_point": {"row": 5, "column": 26}}, {"id": 12, "type": "type_identifier", "text": "SDL_Rect", "parent": 11, "children": [], "start_point": {"row": 5, "column": 15}, "end_point": {"row": 5, "column": 23}}, {"id": 13, "type": "identifier", "text": "A", "parent": 11, "children": [], "start_point": {"row": 5, "column": 25}, "end_point": {"row": 5, "column": 26}}, {"id": 14, "type": "parameter_declaration", "text": "SDL_Rect &B", "parent": 10, "children": [15, 16], "start_point": {"row": 5, "column": 28}, "end_point": {"row": 5, "column": 39}}, {"id": 15, "type": "type_identifier", "text": "SDL_Rect", "parent": 14, "children": [], "start_point": {"row": 5, "column": 28}, "end_point": {"row": 5, "column": 36}}, {"id": 16, "type": "identifier", "text": "B", "parent": 14, "children": [], "start_point": {"row": 5, "column": 38}, "end_point": {"row": 5, "column": 39}}]}, "node_categories": {"declarations": {"functions": [3, 8], "variables": [6, 11, 14], "classes": [], "imports": [0, 1], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [4, 9, 12, 13, 15, 16], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [2], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 3, "universal_type": "function", "name": "checkCollision{", "text_snippet": "class checkCollision{\n\npublic:\n\tbool checkCol(SDL_Rect &A, SDL_Rect &B);\n\n}"}, {"node_id": 8, "universal_type": "function", "name": "unknown", "text_snippet": "checkCol(SDL_Rect &A, SDL_Rect &B)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include \"SDL.h\"\n"}, {"node_id": 1, "text": "#include"}]}, "original_source_code": "#include \"SDL.h\"\n\nclass checkCollision{\n\npublic:\n\tbool checkCol(SDL_Rect &A, SDL_Rect &B);\n\n};"}
80,570
c
/* * (C) <NAME> 2006 */ #include <linux/init.h> #include <linux/kernel.h> #include <linux/console.h> #include <linux/serial_reg.h> #include <asm/addrspace.h> #include <asm/mach-cobalt/cobalt.h> void prom_putchar(char c) { while(!(COBALT_UART[UART_LSR] & UART_LSR_THRE)) ; COBALT_UART[UART_TX] = c; }
19.4
15
(translation_unit) "/*\n * (C) <NAME> 2006\n */\n\n#include <linux/init.h>\n#include <linux/kernel.h>\n#include <linux/console.h>\n#include <linux/serial_reg.h>\n#include <asm/addrspace.h>\n#include <asm/mach-cobalt/cobalt.h>\n\nvoid prom_putchar(char c)\n{\n while(!(COBALT_UART[UART_LSR] & UART_LSR_THRE))\n ;\n\n COBALT_UART[UART_TX] = c;\n}\n" (comment) "/*\n * (C) <NAME> 2006\n */" (preproc_include) "#include <linux/init.h>\n" (#include) "#include" (system_lib_string) "<linux/init.h>" (preproc_include) "#include <linux/kernel.h>\n" (#include) "#include" (system_lib_string) "<linux/kernel.h>" (preproc_include) "#include <linux/console.h>\n" (#include) "#include" (system_lib_string) "<linux/console.h>" (preproc_include) "#include <linux/serial_reg.h>\n" (#include) "#include" (system_lib_string) "<linux/serial_reg.h>" (preproc_include) "#include <asm/addrspace.h>\n" (#include) "#include" (system_lib_string) "<asm/addrspace.h>" (preproc_include) "#include <asm/mach-cobalt/cobalt.h>\n" (#include) "#include" (system_lib_string) "<asm/mach-cobalt/cobalt.h>" (function_definition) "void prom_putchar(char c)\n{\n while(!(COBALT_UART[UART_LSR] & UART_LSR_THRE))\n ;\n\n COBALT_UART[UART_TX] = c;\n}" (primitive_type) "void" (function_declarator) "prom_putchar(char c)" (identifier) "prom_putchar" (parameter_list) "(char c)" (() "(" (parameter_declaration) "char c" (primitive_type) "char" (identifier) "c" ()) ")" (compound_statement) "{\n while(!(COBALT_UART[UART_LSR] & UART_LSR_THRE))\n ;\n\n COBALT_UART[UART_TX] = c;\n}" ({) "{" (while_statement) "while(!(COBALT_UART[UART_LSR] & UART_LSR_THRE))\n ;" (while) "while" (parenthesized_expression) "(!(COBALT_UART[UART_LSR] & UART_LSR_THRE))" (() "(" (unary_expression) "!(COBALT_UART[UART_LSR] & UART_LSR_THRE)" (!) "!" (parenthesized_expression) "(COBALT_UART[UART_LSR] & UART_LSR_THRE)" (() "(" (binary_expression) "COBALT_UART[UART_LSR] & UART_LSR_THRE" (subscript_expression) "COBALT_UART[UART_LSR]" (identifier) "COBALT_UART" ([) "[" (identifier) "UART_LSR" (]) "]" (&) "&" (identifier) "UART_LSR_THRE" ()) ")" ()) ")" (expression_statement) ";" (;) ";" (expression_statement) "COBALT_UART[UART_TX] = c;" (assignment_expression) "COBALT_UART[UART_TX] = c" (subscript_expression) "COBALT_UART[UART_TX]" (identifier) "COBALT_UART" ([) "[" (identifier) "UART_TX" (]) "]" (=) "=" (identifier) "c" (;) ";" (}) "}"
63
0
{"language": "c", "success": true, "metadata": {"lines": 15, "avg_line_length": 19.4, "nodes": 42, "errors": 0, "source_hash": "b34b7f7fc807aafaabf8a50f4e131d18ac19a7ad6e64505d4400cf928c3e8463", "categorized_nodes": 37}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <linux/init.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<linux/init.h>", "parent": 0, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 23}}, {"id": 3, "type": "preproc_include", "text": "#include <linux/kernel.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<linux/kernel.h>", "parent": 3, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 25}}, {"id": 6, "type": "preproc_include", "text": "#include <linux/console.h>\n", "parent": null, "children": [7, 8], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<linux/console.h>", "parent": 6, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 26}}, {"id": 9, "type": "preproc_include", "text": "#include <linux/serial_reg.h>\n", "parent": null, "children": [10, 11], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<linux/serial_reg.h>", "parent": 9, "children": [], "start_point": {"row": 7, "column": 9}, "end_point": {"row": 7, "column": 29}}, {"id": 12, "type": "preproc_include", "text": "#include <asm/addrspace.h>\n", "parent": null, "children": [13, 14], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 8}}, {"id": 14, "type": "system_lib_string", "text": "<asm/addrspace.h>", "parent": 12, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 26}}, {"id": 15, "type": "preproc_include", "text": "#include <asm/mach-cobalt/cobalt.h>\n", "parent": null, "children": [16, 17], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 8}}, {"id": 17, "type": "system_lib_string", "text": "<asm/mach-cobalt/cobalt.h>", "parent": 15, "children": [], "start_point": {"row": 9, "column": 9}, "end_point": {"row": 9, "column": 35}}, {"id": 18, "type": "function_definition", "text": "void prom_putchar(char c)\n{\n\twhile(!(COBALT_UART[UART_LSR] & UART_LSR_THRE))\n\t\t;\n\n\tCOBALT_UART[UART_TX] = c;\n}", "parent": null, "children": [19, 20], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 19, "type": "primitive_type", "text": "void", "parent": 18, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 4}}, {"id": 20, "type": "function_declarator", "text": "prom_putchar(char c)", "parent": 18, "children": [21, 22], "start_point": {"row": 11, "column": 5}, "end_point": {"row": 11, "column": 25}}, {"id": 21, "type": "identifier", "text": "prom_putchar", "parent": 20, "children": [], "start_point": {"row": 11, "column": 5}, "end_point": {"row": 11, "column": 17}}, {"id": 22, "type": "parameter_list", "text": "(char c)", "parent": 20, "children": [23], "start_point": {"row": 11, "column": 17}, "end_point": {"row": 11, "column": 25}}, {"id": 23, "type": "parameter_declaration", "text": "char c", "parent": 22, "children": [24, 25], "start_point": {"row": 11, "column": 18}, "end_point": {"row": 11, "column": 24}}, {"id": 24, "type": "primitive_type", "text": "char", "parent": 23, "children": [], "start_point": {"row": 11, "column": 18}, "end_point": {"row": 11, "column": 22}}, {"id": 25, "type": "identifier", "text": "c", "parent": 23, "children": [], "start_point": {"row": 11, "column": 23}, "end_point": {"row": 11, "column": 24}}, {"id": 26, "type": "while_statement", "text": "while(!(COBALT_UART[UART_LSR] & UART_LSR_THRE))\n\t\t;", "parent": 18, "children": [27], "start_point": {"row": 13, "column": 1}, "end_point": {"row": 14, "column": 3}}, {"id": 27, "type": "parenthesized_expression", "text": "(!(COBALT_UART[UART_LSR] & UART_LSR_THRE))", "parent": 26, "children": [28], "start_point": {"row": 13, "column": 6}, "end_point": {"row": 13, "column": 48}}, {"id": 28, "type": "unary_expression", "text": "!(COBALT_UART[UART_LSR] & UART_LSR_THRE)", "parent": 27, "children": [29, 30], "start_point": {"row": 13, "column": 7}, "end_point": {"row": 13, "column": 47}}, {"id": 29, "type": "!", "text": "!", "parent": 28, "children": [], "start_point": {"row": 13, "column": 7}, "end_point": {"row": 13, "column": 8}}, {"id": 30, "type": "parenthesized_expression", "text": "(COBALT_UART[UART_LSR] & UART_LSR_THRE)", "parent": 28, "children": [31], "start_point": {"row": 13, "column": 8}, "end_point": {"row": 13, "column": 47}}, {"id": 31, "type": "binary_expression", "text": "COBALT_UART[UART_LSR] & UART_LSR_THRE", "parent": 30, "children": [32, 35], "start_point": {"row": 13, "column": 9}, "end_point": {"row": 13, "column": 46}}, {"id": 32, "type": "subscript_expression", "text": "COBALT_UART[UART_LSR]", "parent": 31, "children": [33, 34], "start_point": {"row": 13, "column": 9}, "end_point": {"row": 13, "column": 30}}, {"id": 33, "type": "identifier", "text": "COBALT_UART", "parent": 32, "children": [], "start_point": {"row": 13, "column": 9}, "end_point": {"row": 13, "column": 20}}, {"id": 34, "type": "identifier", "text": "UART_LSR", "parent": 32, "children": [], "start_point": {"row": 13, "column": 21}, "end_point": {"row": 13, "column": 29}}, {"id": 35, "type": "identifier", "text": "UART_LSR_THRE", "parent": 31, "children": [], "start_point": {"row": 13, "column": 33}, "end_point": {"row": 13, "column": 46}}, {"id": 36, "type": "assignment_expression", "text": "COBALT_UART[UART_TX] = c", "parent": 18, "children": [37, 40, 41], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 25}}, {"id": 37, "type": "subscript_expression", "text": "COBALT_UART[UART_TX]", "parent": 36, "children": [38, 39], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 21}}, {"id": 38, "type": "identifier", "text": "COBALT_UART", "parent": 37, "children": [], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 12}}, {"id": 39, "type": "identifier", "text": "UART_TX", "parent": 37, "children": [], "start_point": {"row": 16, "column": 13}, "end_point": {"row": 16, "column": 20}}, {"id": 40, "type": "=", "text": "=", "parent": 36, "children": [], "start_point": {"row": 16, "column": 22}, "end_point": {"row": 16, "column": 23}}, {"id": 41, "type": "identifier", "text": "c", "parent": 36, "children": [], "start_point": {"row": 16, "column": 24}, "end_point": {"row": 16, "column": 25}}]}, "node_categories": {"declarations": {"functions": [18, 20], "variables": [23], "classes": [], "imports": [0, 1, 3, 4, 6, 7, 9, 10, 12, 13, 15, 16], "modules": [], "enums": []}, "statements": {"expressions": [27, 28, 30, 31, 32, 37], "assignments": [36], "loops": [26], "conditionals": [21, 25, 33, 34, 35, 38, 39, 41], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 8, 11, 14, 17], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 18, "universal_type": "function", "name": "prom_putchar", "text_snippet": "void prom_putchar(char c)\n{\n\twhile(!(COBALT_UART[UART_LSR] & UART_LSR_THRE))\n\t\t;\n\n\tCOBALT_UART[UART_"}, {"node_id": 20, "universal_type": "function", "name": "unknown", "text_snippet": "prom_putchar(char c)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <linux/init.h>\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <linux/kernel.h>\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include <linux/console.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <linux/serial_reg.h>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include <asm/addrspace.h>\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include <asm/mach-cobalt/cobalt.h>\n"}, {"node_id": 16, "text": "#include"}]}, "original_source_code": "/*\n * (C) <NAME> 2006\n */\n\n#include <linux/init.h>\n#include <linux/kernel.h>\n#include <linux/console.h>\n#include <linux/serial_reg.h>\n#include <asm/addrspace.h>\n#include <asm/mach-cobalt/cobalt.h>\n\nvoid prom_putchar(char c)\n{\n\twhile(!(COBALT_UART[UART_LSR] & UART_LSR_THRE))\n\t\t;\n\n\tCOBALT_UART[UART_TX] = c;\n}\n"}
80,571
c
/** * \file msg.h * * \brief LoRaWAN application messaging support interfaces * * * Copyright (c) 2020 Microchip Technology Inc. and its subsidiaries. * * \asf_license_start * * \page License * * Subject to your compliance with these terms, you may use Microchip * software and any derivatives exclusively with Microchip products. * It is your responsibility to comply with third party license terms applicable * to your use of third party software (including open source software) that * may accompany Microchip software. * * THIS SOFTWARE IS SUPPLIED BY MICROCHIP "AS IS". NO WARRANTIES, * WHETHER EXPRESS, IMPLIED OR STATUTORY, APPLY TO THIS SOFTWARE, * INCLUDING ANY IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY, * AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT WILL MICROCHIP BE * LIABLE FOR ANY INDIRECT, SPECIAL, PUNITIVE, INCIDENTAL OR CONSEQUENTIAL * LOSS, DAMAGE, COST OR EXPENSE OF ANY KIND WHATSOEVER RELATED TO THE * SOFTWARE, HOWEVER CAUSED, EVEN IF MICROCHIP HAS BEEN ADVISED OF THE * POSSIBILITY OR THE DAMAGES ARE FORESEEABLE. TO THE FULLEST EXTENT * ALLOWED BY LAW, MICROCHIP'S TOTAL LIABILITY ON ALL CLAIMS IN ANY WAY * RELATED TO THIS SOFTWARE WILL NOT EXCEED THE AMOUNT OF FEES, IF ANY, * THAT YOU HAVE PAID DIRECTLY TO MICROCHIP FOR THIS SOFTWARE. * * \asf_license_stop * */ /* * Support and FAQ: visit <a href="https://www.microchip.com/support/">Microchip Support</a> */ #ifndef _MSG_H_ #define _MSG_H_ /************************************************************************/ /* CONSTANTS */ /************************************************************************/ #define MSG_RX_BUFFER_SIZE (255) #define MSG_TX_BUFFER_SIZE (255) #define MSG_FPORT_CB_MAX (5) #define MSG_CLASS_C_INTER_DOWNLINK_TIME_MS (3000) #define MSG_MAX_RX_WINDOW_TIME_MS (3000) /************************************************************************/ /* TYPE DEFINES */ /************************************************************************/ /* * Type of the function callback invoked by messaging interface */ typedef void (*MsgCallback_t)(appCbParams_t *params ); /* * List of status codes returned by messaging interface */ typedef enum _MessageStatus_t { /* if it is possible to post the request to MAC */ APP_RESULT_OK = 0, /* * in all other cases such as duty cycle pending, * previous message retry pending etc. */ APP_RESULT_BUSY } AppResult_t; /* * Structure of the message transmit request */ typedef struct _MessageTx_t { /* Info for the MAC layer send request */ LorawanSendReq_t lorawanReq; /* Number of retries left */ uint8_t retries; /* Delay to elapse before the first transmit */ uint32_t timeout; } MessageTx_t; /* * Structure of the message receive indication */ typedef struct _MessageRx_t { /* Info from the MAC layer receive done */ appCbParams_t params; } MessageRx_t; /* * State of the messaging support */ typedef union _MessageState_t { /* Status bitfield */ uint16_t value; /* Definition of individual bits */ struct { /* * 0 -> messaging interface is idle * 1 -> previous message transaction yet to complete */ uint16_t transactionInProgress : 1; /* * 0 -> no message pending for transmission * 1 -> retry or new message is pending for transmission */ uint16_t txWaiting : 1; /* * 0 -> no new message is received * 1 -> new message received and waiting for processing */ uint16_t rxPending : 1; /* * 0 -> no new message received in class-C RXC_CONT window * 1 -> new message received in class-C RXC_CONT window and pending */ uint16_t classRx2Dl : 1; }; } MessageState_t; /* * Structure of Fport callback info */ typedef struct _FportCallbacks_t { /* Frame port number */ uint8_t port; /* Callback to invoke when new message received in corresponding port */ MsgCallback_t pFunc; } FportCallbacks_t; /************************************************************************/ /* FUNCTION PROTOTYPES */ /************************************************************************/ /* * \brief Initializes the messaging support */ void MSG_Init( void ); /* * \brief Returns the current state of messaging support * * \return State bitfield value (MessageState_t) */ uint16_t MSG_GetState( void ); /* * \brief Requests the MAC layer to send the given data * * \param[in] msgType - (TransmissionType_t) confirmed or unconfirmed * \param[in] port - frame port number * \param[in] * data - pointer to payload data * \param[in] length - length of the payload data * \param[in] timeout - delay to elapse before requesting MAC * * \return Status of the request * APP_RESULT_OK - if request posted to MAC * APP_RESULT_BUSY - if not possible to process the request */ AppResult_t MSG_Send( TransmissionType_t msgType, uint8_t port, uint8_t *data, uint8_t length, uint32_t timeout ); /* * \brief Callback definition to process the received data from MAC * * \param[in] *appHandle - pointer to appHandle from MAC data callback * \param[in] *params - pointer to appCbParams_t from MAC data callback */ void MSG_DataCallback( void *appHandle, appCbParams_t *params ); /* * \brief Sets the callback to invoke for payload received in corresponding fport * * \param[in] port - fport to map the callback * \param[in] callback - pointer to callback function for mapping */ void MSG_SetFPortRxDataAvailCallback( uint8_t port, MsgCallback_t callback ); /* * \brief Sets the default callback to invoke for payload received from MAC. If, * there is a fport-specific mapping available, then default will not be * called in that case. * * \param[in] callback - pointer to callback function to be invoked for payload */ void MSG_SetDefaultRxDataAvailCallback( MsgCallback_t callback ); /* * \brief Sets the callback to invoke for transaction complete event * * \param[in] callback - pointer to callback function */ void MSG_SetTransactionCompleteCallback( MsgCallback_t callback ); /* * \brief Function to run the messaging support. It shall be called from * application to keep this layer running. */ void MSG_Process( void ); /* * \brief Returns if it is possible to transmit now * * \param[in] len - length of the message to transmit * \param[out] *txTime - time-on-air of the given message */ bool MSG_IsTxPossible( uint8_t len, uint32_t *txTime ); #endif // _MSG_H_ /* eof msg.h */
33.29
197
(translation_unit) "/**\n* \file msg.h\n*\n* \brief LoRaWAN application messaging support interfaces\n*\n*\n* Copyright (c) 2020 Microchip Technology Inc. and its subsidiaries.\n*\n* \asf_license_start\n*\n* \page License\n*\n* Subject to your compliance with these terms, you may use Microchip\n* software and any derivatives exclusively with Microchip products.\n* It is your responsibility to comply with third party license terms applicable\n* to your use of third party software (including open source software) that\n* may accompany Microchip software.\n*\n* THIS SOFTWARE IS SUPPLIED BY MICROCHIP "AS IS". NO WARRANTIES,\n* WHETHER EXPRESS, IMPLIED OR STATUTORY, APPLY TO THIS SOFTWARE,\n* INCLUDING ANY IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY,\n* AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT WILL MICROCHIP BE\n* LIABLE FOR ANY INDIRECT, SPECIAL, PUNITIVE, INCIDENTAL OR CONSEQUENTIAL\n* LOSS, DAMAGE, COST OR EXPENSE OF ANY KIND WHATSOEVER RELATED TO THE\n* SOFTWARE, HOWEVER CAUSED, EVEN IF MICROCHIP HAS BEEN ADVISED OF THE\n* POSSIBILITY OR THE DAMAGES ARE FORESEEABLE. TO THE FULLEST EXTENT\n* ALLOWED BY LAW, MICROCHIP'S TOTAL LIABILITY ON ALL CLAIMS IN ANY WAY\n* RELATED TO THIS SOFTWARE WILL NOT EXCEED THE AMOUNT OF FEES, IF ANY,\n* THAT YOU HAVE PAID DIRECTLY TO MICROCHIP FOR THIS SOFTWARE.\n*\n* \asf_license_stop\n*\n*/\n/*\n* Support and FAQ: visit <a href="https://www.microchip.com/support/">Microchip Support</a>\n*/\n#ifndef _MSG_H_\n#define _MSG_H_\n\n/************************************************************************/\n/* CONSTANTS */\n/************************************************************************/\n#define MSG_RX_BUFFER_SIZE (255)\n#define MSG_TX_BUFFER_SIZE (255)\n#define MSG_FPORT_CB_MAX (5)\n#define MSG_CLASS_C_INTER_DOWNLINK_TIME_MS (3000)\n#define MSG_MAX_RX_WINDOW_TIME_MS (3000)\n\n/************************************************************************/\n/* TYPE DEFINES */\n/************************************************************************/\n/*\n* Type of the function callback invoked by messaging interface\n*/\ntypedef void (*MsgCallback_t)(appCbParams_t *params );\n\n/*\n* List of status codes returned by messaging interface\n*/\ntypedef enum _MessageStatus_t\n{\n /* if it is possible to post the request to MAC */\n APP_RESULT_OK = 0,\n /*\n * in all other cases such as duty cycle pending,\n * previous message retry pending etc.\n */\n APP_RESULT_BUSY\n} AppResult_t;\n\n/*\n* Structure of the message transmit request\n*/\ntypedef struct _MessageTx_t\n{\n /* Info for the MAC layer send request */\n LorawanSendReq_t lorawanReq;\n /* Number of retries left */\n uint8_t retries;\n /* Delay to elapse before the first transmit */\n uint32_t timeout;\n} MessageTx_t;\n\n/*\n* Structure of the message receive indication\n*/\ntypedef struct _MessageRx_t\n{\n /* Info from the MAC layer receive done */\n appCbParams_t params;\n} MessageRx_t;\n\n/*\n* State of the messaging support\n*/\ntypedef union _MessageState_t\n{\n /* Status bitfield */\n uint16_t value;\n /* Definition of individual bits */\n struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n };\n} MessageState_t;\n\n/*\n* Structure of Fport callback info\n*/\ntypedef struct _FportCallbacks_t\n{\n /* Frame port number */\n uint8_t port;\n /* Callback to invoke when new message received in corresponding port */\n MsgCallback_t pFunc;\n} FportCallbacks_t;\n\n/************************************************************************/\n/* FUNCTION PROTOTYPES */\n/************************************************************************/\n/*\n* \brief Initializes the messaging support\n*/\nvoid MSG_Init( void );\n\n/*\n* \brief Returns the current state of messaging support\n*\n* \return State bitfield value (MessageState_t)\n*/\nuint16_t MSG_GetState( void );\n\n/*\n* \brief Requests the MAC layer to send the given data\n*\n* \param[in] msgType - (TransmissionType_t) confirmed or unconfirmed\n* \param[in] port - frame port number\n* \param[in] * data - pointer to payload data\n* \param[in] length - length of the payload data\n* \param[in] timeout - delay to elapse before requesting MAC\n*\n* \return Status of the request\n* APP_RESULT_OK - if request posted to MAC\n* APP_RESULT_BUSY - if not possible to process the request\n*/\nAppResult_t MSG_Send( TransmissionType_t msgType, uint8_t port, uint8_t *data,\n uint8_t length, uint32_t timeout );\n\n/*\n* \brief Callback definition to process the received data from MAC\n*\n* \param[in] *appHandle - pointer to appHandle from MAC data callback\n* \param[in] *params - pointer to appCbParams_t from MAC data callback\n*/\nvoid MSG_DataCallback( void *appHandle, appCbParams_t *params );\n\n/*\n* \brief Sets the callback to invoke for payload received in corresponding fport\n*\n* \param[in] port - fport to map the callback\n* \param[in] callback - pointer to callback function for mapping\n*/\nvoid MSG_SetFPortRxDataAvailCallback( uint8_t port, MsgCallback_t callback );\n\n/*\n* \brief Sets the default callback to invoke for payload received from MAC. If,\n* there is a fport-specific mapping available, then default will not be\n* called in that case.\n*\n* \param[in] callback - pointer to callback function to be invoked for payload\n*/\nvoid MSG_SetDefaultRxDataAvailCallback( MsgCallback_t callback );\n\n/*\n* \brief Sets the callback to invoke for transaction complete event\n*\n* \param[in] callback - pointer to callback function\n*/\nvoid MSG_SetTransactionCompleteCallback( MsgCallback_t callback );\n\n/*\n* \brief Function to run the messaging support. It shall be called from\n* application to keep this layer running.\n*/\nvoid MSG_Process( void );\n\n/*\n* \brief Returns if it is possible to transmit now\n*\n* \param[in] len - length of the message to transmit\n* \param[out] *txTime - time-on-air of the given message\n*/\nbool MSG_IsTxPossible( uint8_t len, uint32_t *txTime );\n\n#endif // _MSG_H_\n\n/* eof msg.h */\n" (comment) "/**\n* \file msg.h\n*\n* \brief LoRaWAN application messaging support interfaces\n*\n*\n* Copyright (c) 2020 Microchip Technology Inc. and its subsidiaries.\n*\n* \asf_license_start\n*\n* \page License\n*\n* Subject to your compliance with these terms, you may use Microchip\n* software and any derivatives exclusively with Microchip products.\n* It is your responsibility to comply with third party license terms applicable\n* to your use of third party software (including open source software) that\n* may accompany Microchip software.\n*\n* THIS SOFTWARE IS SUPPLIED BY MICROCHIP "AS IS". NO WARRANTIES,\n* WHETHER EXPRESS, IMPLIED OR STATUTORY, APPLY TO THIS SOFTWARE,\n* INCLUDING ANY IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY,\n* AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT WILL MICROCHIP BE\n* LIABLE FOR ANY INDIRECT, SPECIAL, PUNITIVE, INCIDENTAL OR CONSEQUENTIAL\n* LOSS, DAMAGE, COST OR EXPENSE OF ANY KIND WHATSOEVER RELATED TO THE\n* SOFTWARE, HOWEVER CAUSED, EVEN IF MICROCHIP HAS BEEN ADVISED OF THE\n* POSSIBILITY OR THE DAMAGES ARE FORESEEABLE. TO THE FULLEST EXTENT\n* ALLOWED BY LAW, MICROCHIP'S TOTAL LIABILITY ON ALL CLAIMS IN ANY WAY\n* RELATED TO THIS SOFTWARE WILL NOT EXCEED THE AMOUNT OF FEES, IF ANY,\n* THAT YOU HAVE PAID DIRECTLY TO MICROCHIP FOR THIS SOFTWARE.\n*\n* \asf_license_stop\n*\n*/" (comment) "/*\n* Support and FAQ: visit <a href="https://www.microchip.com/support/">Microchip Support</a>\n*/" (preproc_ifdef) "#ifndef _MSG_H_\n#define _MSG_H_\n\n/************************************************************************/\n/* CONSTANTS */\n/************************************************************************/\n#define MSG_RX_BUFFER_SIZE (255)\n#define MSG_TX_BUFFER_SIZE (255)\n#define MSG_FPORT_CB_MAX (5)\n#define MSG_CLASS_C_INTER_DOWNLINK_TIME_MS (3000)\n#define MSG_MAX_RX_WINDOW_TIME_MS (3000)\n\n/************************************************************************/\n/* TYPE DEFINES */\n/************************************************************************/\n/*\n* Type of the function callback invoked by messaging interface\n*/\ntypedef void (*MsgCallback_t)(appCbParams_t *params );\n\n/*\n* List of status codes returned by messaging interface\n*/\ntypedef enum _MessageStatus_t\n{\n /* if it is possible to post the request to MAC */\n APP_RESULT_OK = 0,\n /*\n * in all other cases such as duty cycle pending,\n * previous message retry pending etc.\n */\n APP_RESULT_BUSY\n} AppResult_t;\n\n/*\n* Structure of the message transmit request\n*/\ntypedef struct _MessageTx_t\n{\n /* Info for the MAC layer send request */\n LorawanSendReq_t lorawanReq;\n /* Number of retries left */\n uint8_t retries;\n /* Delay to elapse before the first transmit */\n uint32_t timeout;\n} MessageTx_t;\n\n/*\n* Structure of the message receive indication\n*/\ntypedef struct _MessageRx_t\n{\n /* Info from the MAC layer receive done */\n appCbParams_t params;\n} MessageRx_t;\n\n/*\n* State of the messaging support\n*/\ntypedef union _MessageState_t\n{\n /* Status bitfield */\n uint16_t value;\n /* Definition of individual bits */\n struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n };\n} MessageState_t;\n\n/*\n* Structure of Fport callback info\n*/\ntypedef struct _FportCallbacks_t\n{\n /* Frame port number */\n uint8_t port;\n /* Callback to invoke when new message received in corresponding port */\n MsgCallback_t pFunc;\n} FportCallbacks_t;\n\n/************************************************************************/\n/* FUNCTION PROTOTYPES */\n/************************************************************************/\n/*\n* \brief Initializes the messaging support\n*/\nvoid MSG_Init( void );\n\n/*\n* \brief Returns the current state of messaging support\n*\n* \return State bitfield value (MessageState_t)\n*/\nuint16_t MSG_GetState( void );\n\n/*\n* \brief Requests the MAC layer to send the given data\n*\n* \param[in] msgType - (TransmissionType_t) confirmed or unconfirmed\n* \param[in] port - frame port number\n* \param[in] * data - pointer to payload data\n* \param[in] length - length of the payload data\n* \param[in] timeout - delay to elapse before requesting MAC\n*\n* \return Status of the request\n* APP_RESULT_OK - if request posted to MAC\n* APP_RESULT_BUSY - if not possible to process the request\n*/\nAppResult_t MSG_Send( TransmissionType_t msgType, uint8_t port, uint8_t *data,\n uint8_t length, uint32_t timeout );\n\n/*\n* \brief Callback definition to process the received data from MAC\n*\n* \param[in] *appHandle - pointer to appHandle from MAC data callback\n* \param[in] *params - pointer to appCbParams_t from MAC data callback\n*/\nvoid MSG_DataCallback( void *appHandle, appCbParams_t *params );\n\n/*\n* \brief Sets the callback to invoke for payload received in corresponding fport\n*\n* \param[in] port - fport to map the callback\n* \param[in] callback - pointer to callback function for mapping\n*/\nvoid MSG_SetFPortRxDataAvailCallback( uint8_t port, MsgCallback_t callback );\n\n/*\n* \brief Sets the default callback to invoke for payload received from MAC. If,\n* there is a fport-specific mapping available, then default will not be\n* called in that case.\n*\n* \param[in] callback - pointer to callback function to be invoked for payload\n*/\nvoid MSG_SetDefaultRxDataAvailCallback( MsgCallback_t callback );\n\n/*\n* \brief Sets the callback to invoke for transaction complete event\n*\n* \param[in] callback - pointer to callback function\n*/\nvoid MSG_SetTransactionCompleteCallback( MsgCallback_t callback );\n\n/*\n* \brief Function to run the messaging support. It shall be called from\n* application to keep this layer running.\n*/\nvoid MSG_Process( void );\n\n/*\n* \brief Returns if it is possible to transmit now\n*\n* \param[in] len - length of the message to transmit\n* \param[out] *txTime - time-on-air of the given message\n*/\nbool MSG_IsTxPossible( uint8_t len, uint32_t *txTime );\n\n#endif" (#ifndef) "#ifndef" (identifier) "_MSG_H_" (preproc_def) "#define _MSG_H_\n" (#define) "#define" (identifier) "_MSG_H_" (comment) "/************************************************************************/" (comment) "/* CONSTANTS */" (comment) "/************************************************************************/" (preproc_def) "#define MSG_RX_BUFFER_SIZE (255)\n" (#define) "#define" (identifier) "MSG_RX_BUFFER_SIZE" (preproc_arg) "(255)" (preproc_def) "#define MSG_TX_BUFFER_SIZE (255)\n" (#define) "#define" (identifier) "MSG_TX_BUFFER_SIZE" (preproc_arg) "(255)" (preproc_def) "#define MSG_FPORT_CB_MAX (5)\n" (#define) "#define" (identifier) "MSG_FPORT_CB_MAX" (preproc_arg) "(5)" (preproc_def) "#define MSG_CLASS_C_INTER_DOWNLINK_TIME_MS (3000)\n" (#define) "#define" (identifier) "MSG_CLASS_C_INTER_DOWNLINK_TIME_MS" (preproc_arg) "(3000)" (preproc_def) "#define MSG_MAX_RX_WINDOW_TIME_MS (3000)\n" (#define) "#define" (identifier) "MSG_MAX_RX_WINDOW_TIME_MS" (preproc_arg) "(3000)" (comment) "/************************************************************************/" (comment) "/* TYPE DEFINES */" (comment) "/************************************************************************/" (comment) "/*\n* Type of the function callback invoked by messaging interface\n*/" (type_definition) "typedef void (*MsgCallback_t)(appCbParams_t *params );" (typedef) "typedef" (primitive_type) "void" (function_declarator) "(*MsgCallback_t)(appCbParams_t *params )" (parenthesized_declarator) "(*MsgCallback_t)" (() "(" (pointer_declarator) "*MsgCallback_t" (*) "*" (type_identifier) "MsgCallback_t" ()) ")" (parameter_list) "(appCbParams_t *params )" (() "(" (parameter_declaration) "appCbParams_t *params" (type_identifier) "appCbParams_t" (pointer_declarator) "*params" (*) "*" (identifier) "params" ()) ")" (;) ";" (comment) "/*\n* List of status codes returned by messaging interface\n*/" (type_definition) "typedef enum _MessageStatus_t\n{\n /* if it is possible to post the request to MAC */\n APP_RESULT_OK = 0,\n /*\n * in all other cases such as duty cycle pending,\n * previous message retry pending etc.\n */\n APP_RESULT_BUSY\n} AppResult_t;" (typedef) "typedef" (enum_specifier) "enum _MessageStatus_t\n{\n /* if it is possible to post the request to MAC */\n APP_RESULT_OK = 0,\n /*\n * in all other cases such as duty cycle pending,\n * previous message retry pending etc.\n */\n APP_RESULT_BUSY\n}" (enum) "enum" (type_identifier) "_MessageStatus_t" (enumerator_list) "{\n /* if it is possible to post the request to MAC */\n APP_RESULT_OK = 0,\n /*\n * in all other cases such as duty cycle pending,\n * previous message retry pending etc.\n */\n APP_RESULT_BUSY\n}" ({) "{" (comment) "/* if it is possible to post the request to MAC */" (enumerator) "APP_RESULT_OK = 0" (identifier) "APP_RESULT_OK" (=) "=" (number_literal) "0" (,) "," (comment) "/*\n * in all other cases such as duty cycle pending,\n * previous message retry pending etc.\n */" (enumerator) "APP_RESULT_BUSY" (identifier) "APP_RESULT_BUSY" (}) "}" (type_identifier) "AppResult_t" (;) ";" (comment) "/*\n* Structure of the message transmit request\n*/" (type_definition) "typedef struct _MessageTx_t\n{\n /* Info for the MAC layer send request */\n LorawanSendReq_t lorawanReq;\n /* Number of retries left */\n uint8_t retries;\n /* Delay to elapse before the first transmit */\n uint32_t timeout;\n} MessageTx_t;" (typedef) "typedef" (struct_specifier) "struct _MessageTx_t\n{\n /* Info for the MAC layer send request */\n LorawanSendReq_t lorawanReq;\n /* Number of retries left */\n uint8_t retries;\n /* Delay to elapse before the first transmit */\n uint32_t timeout;\n}" (struct) "struct" (type_identifier) "_MessageTx_t" (field_declaration_list) "{\n /* Info for the MAC layer send request */\n LorawanSendReq_t lorawanReq;\n /* Number of retries left */\n uint8_t retries;\n /* Delay to elapse before the first transmit */\n uint32_t timeout;\n}" ({) "{" (comment) "/* Info for the MAC layer send request */" (field_declaration) "LorawanSendReq_t lorawanReq;" (type_identifier) "LorawanSendReq_t" (field_identifier) "lorawanReq" (;) ";" (comment) "/* Number of retries left */" (field_declaration) "uint8_t retries;" (primitive_type) "uint8_t" (field_identifier) "retries" (;) ";" (comment) "/* Delay to elapse before the first transmit */" (field_declaration) "uint32_t timeout;" (primitive_type) "uint32_t" (field_identifier) "timeout" (;) ";" (}) "}" (type_identifier) "MessageTx_t" (;) ";" (comment) "/*\n* Structure of the message receive indication\n*/" (type_definition) "typedef struct _MessageRx_t\n{\n /* Info from the MAC layer receive done */\n appCbParams_t params;\n} MessageRx_t;" (typedef) "typedef" (struct_specifier) "struct _MessageRx_t\n{\n /* Info from the MAC layer receive done */\n appCbParams_t params;\n}" (struct) "struct" (type_identifier) "_MessageRx_t" (field_declaration_list) "{\n /* Info from the MAC layer receive done */\n appCbParams_t params;\n}" ({) "{" (comment) "/* Info from the MAC layer receive done */" (field_declaration) "appCbParams_t params;" (type_identifier) "appCbParams_t" (field_identifier) "params" (;) ";" (}) "}" (type_identifier) "MessageRx_t" (;) ";" (comment) "/*\n* State of the messaging support\n*/" (type_definition) "typedef union _MessageState_t\n{\n /* Status bitfield */\n uint16_t value;\n /* Definition of individual bits */\n struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n };\n} MessageState_t;" (typedef) "typedef" (union_specifier) "union _MessageState_t\n{\n /* Status bitfield */\n uint16_t value;\n /* Definition of individual bits */\n struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n };\n}" (union) "union" (type_identifier) "_MessageState_t" (field_declaration_list) "{\n /* Status bitfield */\n uint16_t value;\n /* Definition of individual bits */\n struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n };\n}" ({) "{" (comment) "/* Status bitfield */" (field_declaration) "uint16_t value;" (primitive_type) "uint16_t" (field_identifier) "value" (;) ";" (comment) "/* Definition of individual bits */" (field_declaration) "struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n };" (struct_specifier) "struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n }" (struct) "struct" (field_declaration_list) "{\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n }" ({) "{" (comment) "/*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */" (field_declaration) "uint16_t transactionInProgress : 1;" (primitive_type) "uint16_t" (field_identifier) "transactionInProgress" (bitfield_clause) ": 1" (:) ":" (number_literal) "1" (;) ";" (comment) "/*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */" (field_declaration) "uint16_t txWaiting : 1;" (primitive_type) "uint16_t" (field_identifier) "txWaiting" (bitfield_clause) ": 1" (:) ":" (number_literal) "1" (;) ";" (comment) "/*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */" (field_declaration) "uint16_t rxPending : 1;" (primitive_type) "uint16_t" (field_identifier) "rxPending" (bitfield_clause) ": 1" (:) ":" (number_literal) "1" (;) ";" (comment) "/*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */" (field_declaration) "uint16_t classRx2Dl : 1;" (primitive_type) "uint16_t" (field_identifier) "classRx2Dl" (bitfield_clause) ": 1" (:) ":" (number_literal) "1" (;) ";" (}) "}" (;) ";" (}) "}" (type_identifier) "MessageState_t" (;) ";" (comment) "/*\n* Structure of Fport callback info\n*/" (type_definition) "typedef struct _FportCallbacks_t\n{\n /* Frame port number */\n uint8_t port;\n /* Callback to invoke when new message received in corresponding port */\n MsgCallback_t pFunc;\n} FportCallbacks_t;" (typedef) "typedef" (struct_specifier) "struct _FportCallbacks_t\n{\n /* Frame port number */\n uint8_t port;\n /* Callback to invoke when new message received in corresponding port */\n MsgCallback_t pFunc;\n}" (struct) "struct" (type_identifier) "_FportCallbacks_t" (field_declaration_list) "{\n /* Frame port number */\n uint8_t port;\n /* Callback to invoke when new message received in corresponding port */\n MsgCallback_t pFunc;\n}" ({) "{" (comment) "/* Frame port number */" (field_declaration) "uint8_t port;" (primitive_type) "uint8_t" (field_identifier) "port" (;) ";" (comment) "/* Callback to invoke when new message received in corresponding port */" (field_declaration) "MsgCallback_t pFunc;" (type_identifier) "MsgCallback_t" (field_identifier) "pFunc" (;) ";" (}) "}" (type_identifier) "FportCallbacks_t" (;) ";" (comment) "/************************************************************************/" (comment) "/* FUNCTION PROTOTYPES */" (comment) "/************************************************************************/" (comment) "/*\n* \brief Initializes the messaging support\n*/" (declaration) "void MSG_Init( void );" (primitive_type) "void" (function_declarator) "MSG_Init( void )" (identifier) "MSG_Init" (parameter_list) "( void )" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (;) ";" (comment) "/*\n* \brief Returns the current state of messaging support\n*\n* \return State bitfield value (MessageState_t)\n*/" (declaration) "uint16_t MSG_GetState( void );" (primitive_type) "uint16_t" (function_declarator) "MSG_GetState( void )" (identifier) "MSG_GetState" (parameter_list) "( void )" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (;) ";" (comment) "/*\n* \brief Requests the MAC layer to send the given data\n*\n* \param[in] msgType - (TransmissionType_t) confirmed or unconfirmed\n* \param[in] port - frame port number\n* \param[in] * data - pointer to payload data\n* \param[in] length - length of the payload data\n* \param[in] timeout - delay to elapse before requesting MAC\n*\n* \return Status of the request\n* APP_RESULT_OK - if request posted to MAC\n* APP_RESULT_BUSY - if not possible to process the request\n*/" (declaration) "AppResult_t MSG_Send( TransmissionType_t msgType, uint8_t port, uint8_t *data,\n uint8_t length, uint32_t timeout );" (type_identifier) "AppResult_t" (function_declarator) "MSG_Send( TransmissionType_t msgType, uint8_t port, uint8_t *data,\n uint8_t length, uint32_t timeout )" (identifier) "MSG_Send" (parameter_list) "( TransmissionType_t msgType, uint8_t port, uint8_t *data,\n uint8_t length, uint32_t timeout )" (() "(" (parameter_declaration) "TransmissionType_t msgType" (type_identifier) "TransmissionType_t" (identifier) "msgType" (,) "," (parameter_declaration) "uint8_t port" (primitive_type) "uint8_t" (identifier) "port" (,) "," (parameter_declaration) "uint8_t *data" (primitive_type) "uint8_t" (pointer_declarator) "*data" (*) "*" (identifier) "data" (,) "," (parameter_declaration) "uint8_t length" (primitive_type) "uint8_t" (identifier) "length" (,) "," (parameter_declaration) "uint32_t timeout" (primitive_type) "uint32_t" (identifier) "timeout" ()) ")" (;) ";" (comment) "/*\n* \brief Callback definition to process the received data from MAC\n*\n* \param[in] *appHandle - pointer to appHandle from MAC data callback\n* \param[in] *params - pointer to appCbParams_t from MAC data callback\n*/" (declaration) "void MSG_DataCallback( void *appHandle, appCbParams_t *params );" (primitive_type) "void" (function_declarator) "MSG_DataCallback( void *appHandle, appCbParams_t *params )" (identifier) "MSG_DataCallback" (parameter_list) "( void *appHandle, appCbParams_t *params )" (() "(" (parameter_declaration) "void *appHandle" (primitive_type) "void" (pointer_declarator) "*appHandle" (*) "*" (identifier) "appHandle" (,) "," (parameter_declaration) "appCbParams_t *params" (type_identifier) "appCbParams_t" (pointer_declarator) "*params" (*) "*" (identifier) "params" ()) ")" (;) ";" (comment) "/*\n* \brief Sets the callback to invoke for payload received in corresponding fport\n*\n* \param[in] port - fport to map the callback\n* \param[in] callback - pointer to callback function for mapping\n*/" (declaration) "void MSG_SetFPortRxDataAvailCallback( uint8_t port, MsgCallback_t callback );" (primitive_type) "void" (function_declarator) "MSG_SetFPortRxDataAvailCallback( uint8_t port, MsgCallback_t callback )" (identifier) "MSG_SetFPortRxDataAvailCallback" (parameter_list) "( uint8_t port, MsgCallback_t callback )" (() "(" (parameter_declaration) "uint8_t port" (primitive_type) "uint8_t" (identifier) "port" (,) "," (parameter_declaration) "MsgCallback_t callback" (type_identifier) "MsgCallback_t" (identifier) "callback" ()) ")" (;) ";" (comment) "/*\n* \brief Sets the default callback to invoke for payload received from MAC. If,\n* there is a fport-specific mapping available, then default will not be\n* called in that case.\n*\n* \param[in] callback - pointer to callback function to be invoked for payload\n*/" (declaration) "void MSG_SetDefaultRxDataAvailCallback( MsgCallback_t callback );" (primitive_type) "void" (function_declarator) "MSG_SetDefaultRxDataAvailCallback( MsgCallback_t callback )" (identifier) "MSG_SetDefaultRxDataAvailCallback" (parameter_list) "( MsgCallback_t callback )" (() "(" (parameter_declaration) "MsgCallback_t callback" (type_identifier) "MsgCallback_t" (identifier) "callback" ()) ")" (;) ";" (comment) "/*\n* \brief Sets the callback to invoke for transaction complete event\n*\n* \param[in] callback - pointer to callback function\n*/" (declaration) "void MSG_SetTransactionCompleteCallback( MsgCallback_t callback );" (primitive_type) "void" (function_declarator) "MSG_SetTransactionCompleteCallback( MsgCallback_t callback )" (identifier) "MSG_SetTransactionCompleteCallback" (parameter_list) "( MsgCallback_t callback )" (() "(" (parameter_declaration) "MsgCallback_t callback" (type_identifier) "MsgCallback_t" (identifier) "callback" ()) ")" (;) ";" (comment) "/*\n* \brief Function to run the messaging support. It shall be called from\n* application to keep this layer running.\n*/" (declaration) "void MSG_Process( void );" (primitive_type) "void" (function_declarator) "MSG_Process( void )" (identifier) "MSG_Process" (parameter_list) "( void )" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (;) ";" (comment) "/*\n* \brief Returns if it is possible to transmit now\n*\n* \param[in] len - length of the message to transmit\n* \param[out] *txTime - time-on-air of the given message\n*/" (declaration) "bool MSG_IsTxPossible( uint8_t len, uint32_t *txTime );" (primitive_type) "bool" (function_declarator) "MSG_IsTxPossible( uint8_t len, uint32_t *txTime )" (identifier) "MSG_IsTxPossible" (parameter_list) "( uint8_t len, uint32_t *txTime )" (() "(" (parameter_declaration) "uint8_t len" (primitive_type) "uint8_t" (identifier) "len" (,) "," (parameter_declaration) "uint32_t *txTime" (primitive_type) "uint32_t" (pointer_declarator) "*txTime" (*) "*" (identifier) "txTime" ()) ")" (;) ";" (#endif) "#endif" (comment) "// _MSG_H_" (comment) "/* eof msg.h */"
341
0
{"language": "c", "success": true, "metadata": {"lines": 197, "avg_line_length": 33.29, "nodes": 220, "errors": 0, "source_hash": "9705052bf8abda760b282caad96e8650f2dca2ca2a683b7e879513ac408a6f5d", "categorized_nodes": 145}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef _MSG_H_\n#define _MSG_H_\n\n/************************************************************************/\n/* CONSTANTS */\n/************************************************************************/\n#define MSG_RX_BUFFER_SIZE (255)\n#define MSG_TX_BUFFER_SIZE (255)\n#define MSG_FPORT_CB_MAX (5)\n#define MSG_CLASS_C_INTER_DOWNLINK_TIME_MS (3000)\n#define MSG_MAX_RX_WINDOW_TIME_MS (3000)\n\n/************************************************************************/\n/* TYPE DEFINES */\n/************************************************************************/\n/*\n* Type of the function callback invoked by messaging interface\n*/\ntypedef void (*MsgCallback_t)(appCbParams_t *params );\n\n/*\n* List of status codes returned by messaging interface\n*/\ntypedef enum _MessageStatus_t\n{\n /* if it is possible to post the request to MAC */\n APP_RESULT_OK = 0,\n /*\n * in all other cases such as duty cycle pending,\n * previous message retry pending etc.\n */\n APP_RESULT_BUSY\n} AppResult_t;\n\n/*\n* Structure of the message transmit request\n*/\ntypedef struct _MessageTx_t\n{\n /* Info for the MAC layer send request */\n LorawanSendReq_t lorawanReq;\n /* Number of retries left */\n uint8_t retries;\n /* Delay to elapse before the first transmit */\n uint32_t timeout;\n} MessageTx_t;\n\n/*\n* Structure of the message receive indication\n*/\ntypedef struct _MessageRx_t\n{\n /* Info from the MAC layer receive done */\n appCbParams_t params;\n} MessageRx_t;\n\n/*\n* State of the messaging support\n*/\ntypedef union _MessageState_t\n{\n /* Status bitfield */\n uint16_t value;\n /* Definition of individual bits */\n struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n };\n} MessageState_t;\n\n/*\n* Structure of Fport callback info\n*/\ntypedef struct _FportCallbacks_t\n{\n /* Frame port number */\n uint8_t port;\n /* Callback to invoke when new message received in corresponding port */\n MsgCallback_t pFunc;\n} FportCallbacks_t;\n\n/************************************************************************/\n/* FUNCTION PROTOTYPES */\n/************************************************************************/\n/*\n* \\brief Initializes the messaging support\n*/\nvoid MSG_Init( void );\n\n/*\n* \\brief Returns the current state of messaging support\n*\n* \\return State bitfield value (MessageState_t)\n*/\nuint16_t MSG_GetState( void );\n\n/*\n* \\brief Requests the MAC layer to send the given data\n*\n* \\param[in] msgType - (TransmissionType_t) confirmed or unconfirmed\n* \\param[in] port - frame port number\n* \\param[in] * data - pointer to payload data\n* \\param[in] length - length of the payload data\n* \\param[in] timeout - delay to elapse before requesting MAC\n*\n* \\return Status of the request\n* APP_RESULT_OK - if request posted to MAC\n* APP_RESULT_BUSY - if not possible to process the request\n*/\nAppResult_t MSG_Send( TransmissionType_t msgType, uint8_t port, uint8_t *data,\n uint8_t length, uint32_t timeout );\n\n/*\n* \\brief Callback definition to process the received data from MAC\n*\n* \\param[in] *appHandle - pointer to appHandle from MAC data callback\n* \\param[in] *params - pointer to appCbParams_t from MAC data callback\n*/\nvoid MSG_DataCallback( void *appHandle, appCbParams_t *params );\n\n/*\n* \\brief Sets the callback to invoke for payload received in corresponding fport\n*\n* \\param[in] port - fport to map the callback\n* \\param[in] callback - pointer to callback function for mapping\n*/\nvoid MSG_SetFPortRxDataAvailCallback( uint8_t port, MsgCallback_t callback );\n\n/*\n* \\brief Sets the default callback to invoke for payload received from MAC. If,\n* there is a fport-specific mapping available, then default will not be\n* called in that case.\n*\n* \\param[in] callback - pointer to callback function to be invoked for payload\n*/\nvoid MSG_SetDefaultRxDataAvailCallback( MsgCallback_t callback );\n\n/*\n* \\brief Sets the callback to invoke for transaction complete event\n*\n* \\param[in] callback - pointer to callback function\n*/\nvoid MSG_SetTransactionCompleteCallback( MsgCallback_t callback );\n\n/*\n* \\brief Function to run the messaging support. It shall be called from\n* application to keep this layer running.\n*/\nvoid MSG_Process( void );\n\n/*\n* \\brief Returns if it is possible to transmit now\n*\n* \\param[in] len - length of the message to transmit\n* \\param[out] *txTime - time-on-air of the given message\n*/\nbool MSG_IsTxPossible( uint8_t len, uint32_t *txTime );\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 10, 14, 18, 22, 26, 40, 53, 68, 77, 109, 121, 128, 135, 157, 172, 183, 191, 199, 206, 219], "start_point": {"row": 36, "column": 0}, "end_point": {"row": 212, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 36, "column": 0}, "end_point": {"row": 36, "column": 7}}, {"id": 2, "type": "identifier", "text": "_MSG_H_", "parent": 0, "children": [], "start_point": {"row": 36, "column": 8}, "end_point": {"row": 36, "column": 15}}, {"id": 3, "type": "preproc_def", "text": "#define _MSG_H_\n", "parent": 0, "children": [4, 5], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 38, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 37, "column": 0}, "end_point": {"row": 37, "column": 7}}, {"id": 5, "type": "identifier", "text": "_MSG_H_", "parent": 3, "children": [], "start_point": {"row": 37, "column": 8}, "end_point": {"row": 37, "column": 15}}, {"id": 6, "type": "preproc_def", "text": "#define MSG_RX_BUFFER_SIZE (255)\n", "parent": 0, "children": [7, 8, 9], "start_point": {"row": 42, "column": 0}, "end_point": {"row": 43, "column": 0}}, {"id": 7, "type": "#define", "text": "#define", "parent": 6, "children": [], "start_point": {"row": 42, "column": 0}, "end_point": {"row": 42, "column": 7}}, {"id": 8, "type": "identifier", "text": "MSG_RX_BUFFER_SIZE", "parent": 6, "children": [], "start_point": {"row": 42, "column": 8}, "end_point": {"row": 42, "column": 26}}, {"id": 9, "type": "preproc_arg", "text": "(255)", "parent": 6, "children": [], "start_point": {"row": 42, "column": 44}, "end_point": {"row": 42, "column": 49}}, {"id": 10, "type": "preproc_def", "text": "#define MSG_TX_BUFFER_SIZE (255)\n", "parent": 0, "children": [11, 12, 13], "start_point": {"row": 43, "column": 0}, "end_point": {"row": 44, "column": 0}}, {"id": 11, "type": "#define", "text": "#define", "parent": 10, "children": [], "start_point": {"row": 43, "column": 0}, "end_point": {"row": 43, "column": 7}}, {"id": 12, "type": "identifier", "text": "MSG_TX_BUFFER_SIZE", "parent": 10, "children": [], "start_point": {"row": 43, "column": 8}, "end_point": {"row": 43, "column": 26}}, {"id": 13, "type": "preproc_arg", "text": "(255)", "parent": 10, "children": [], "start_point": {"row": 43, "column": 44}, "end_point": {"row": 43, "column": 49}}, {"id": 14, "type": "preproc_def", "text": "#define MSG_FPORT_CB_MAX (5)\n", "parent": 0, "children": [15, 16, 17], "start_point": {"row": 44, "column": 0}, "end_point": {"row": 45, "column": 0}}, {"id": 15, "type": "#define", "text": "#define", "parent": 14, "children": [], "start_point": {"row": 44, "column": 0}, "end_point": {"row": 44, "column": 7}}, {"id": 16, "type": "identifier", "text": "MSG_FPORT_CB_MAX", "parent": 14, "children": [], "start_point": {"row": 44, "column": 8}, "end_point": {"row": 44, "column": 24}}, {"id": 17, "type": "preproc_arg", "text": "(5)", "parent": 14, "children": [], "start_point": {"row": 44, "column": 44}, "end_point": {"row": 44, "column": 47}}, {"id": 18, "type": "preproc_def", "text": "#define MSG_CLASS_C_INTER_DOWNLINK_TIME_MS (3000)\n", "parent": 0, "children": [19, 20, 21], "start_point": {"row": 45, "column": 0}, "end_point": {"row": 46, "column": 0}}, {"id": 19, "type": "#define", "text": "#define", "parent": 18, "children": [], "start_point": {"row": 45, "column": 0}, "end_point": {"row": 45, "column": 7}}, {"id": 20, "type": "identifier", "text": "MSG_CLASS_C_INTER_DOWNLINK_TIME_MS", "parent": 18, "children": [], "start_point": {"row": 45, "column": 8}, "end_point": {"row": 45, "column": 42}}, {"id": 21, "type": "preproc_arg", "text": "(3000)", "parent": 18, "children": [], "start_point": {"row": 45, "column": 44}, "end_point": {"row": 45, "column": 50}}, {"id": 22, "type": "preproc_def", "text": "#define MSG_MAX_RX_WINDOW_TIME_MS (3000)\n", "parent": 0, "children": [23, 24, 25], "start_point": {"row": 46, "column": 0}, "end_point": {"row": 47, "column": 0}}, {"id": 23, "type": "#define", "text": "#define", "parent": 22, "children": [], "start_point": {"row": 46, "column": 0}, "end_point": {"row": 46, "column": 7}}, {"id": 24, "type": "identifier", "text": "MSG_MAX_RX_WINDOW_TIME_MS", "parent": 22, "children": [], "start_point": {"row": 46, "column": 8}, "end_point": {"row": 46, "column": 33}}, {"id": 25, "type": "preproc_arg", "text": "(3000)", "parent": 22, "children": [], "start_point": {"row": 46, "column": 44}, "end_point": {"row": 46, "column": 50}}, {"id": 26, "type": "type_definition", "text": "typedef void (*MsgCallback_t)(appCbParams_t *params );", "parent": 0, "children": [27, 28, 29], "start_point": {"row": 54, "column": 0}, "end_point": {"row": 54, "column": 54}}, {"id": 27, "type": "typedef", "text": "typedef", "parent": 26, "children": [], "start_point": {"row": 54, "column": 0}, "end_point": {"row": 54, "column": 7}}, {"id": 28, "type": "primitive_type", "text": "void", "parent": 26, "children": [], "start_point": {"row": 54, "column": 8}, "end_point": {"row": 54, "column": 12}}, {"id": 29, "type": "function_declarator", "text": "(*MsgCallback_t)(appCbParams_t *params )", "parent": 26, "children": [30, 34], "start_point": {"row": 54, "column": 13}, "end_point": {"row": 54, "column": 53}}, {"id": 30, "type": "parenthesized_declarator", "text": "(*MsgCallback_t)", "parent": 29, "children": [31], "start_point": {"row": 54, "column": 13}, "end_point": {"row": 54, "column": 29}}, {"id": 31, "type": "pointer_declarator", "text": "*MsgCallback_t", "parent": 30, "children": [32, 33], "start_point": {"row": 54, "column": 14}, "end_point": {"row": 54, "column": 28}}, {"id": 32, "type": "*", "text": "*", "parent": 31, "children": [], "start_point": {"row": 54, "column": 14}, "end_point": {"row": 54, "column": 15}}, {"id": 33, "type": "type_identifier", "text": "MsgCallback_t", "parent": 31, "children": [], "start_point": {"row": 54, "column": 15}, "end_point": {"row": 54, "column": 28}}, {"id": 34, "type": "parameter_list", "text": "(appCbParams_t *params )", "parent": 29, "children": [35], "start_point": {"row": 54, "column": 29}, "end_point": {"row": 54, "column": 53}}, {"id": 35, "type": "parameter_declaration", "text": "appCbParams_t *params", "parent": 34, "children": [36, 37], "start_point": {"row": 54, "column": 30}, "end_point": {"row": 54, "column": 51}}, {"id": 36, "type": "type_identifier", "text": "appCbParams_t", "parent": 35, "children": [], "start_point": {"row": 54, "column": 30}, "end_point": {"row": 54, "column": 43}}, {"id": 37, "type": "pointer_declarator", "text": "*params", "parent": 35, "children": [38, 39], "start_point": {"row": 54, "column": 44}, "end_point": {"row": 54, "column": 51}}, {"id": 38, "type": "*", "text": "*", "parent": 37, "children": [], "start_point": {"row": 54, "column": 44}, "end_point": {"row": 54, "column": 45}}, {"id": 39, "type": "identifier", "text": "params", "parent": 37, "children": [], "start_point": {"row": 54, "column": 45}, "end_point": {"row": 54, "column": 51}}, {"id": 40, "type": "type_definition", "text": "typedef enum _MessageStatus_t\n{\n /* if it is possible to post the request to MAC */\n APP_RESULT_OK = 0,\n /*\n * in all other cases such as duty cycle pending,\n * previous message retry pending etc.\n */\n APP_RESULT_BUSY\n} AppResult_t;", "parent": 0, "children": [41, 42, 52], "start_point": {"row": 59, "column": 0}, "end_point": {"row": 68, "column": 14}}, {"id": 41, "type": "typedef", "text": "typedef", "parent": 40, "children": [], "start_point": {"row": 59, "column": 0}, "end_point": {"row": 59, "column": 7}}, {"id": 42, "type": "enum_specifier", "text": "enum _MessageStatus_t\n{\n /* if it is possible to post the request to MAC */\n APP_RESULT_OK = 0,\n /*\n * in all other cases such as duty cycle pending,\n * previous message retry pending etc.\n */\n APP_RESULT_BUSY\n}", "parent": 40, "children": [43, 44, 45], "start_point": {"row": 59, "column": 8}, "end_point": {"row": 68, "column": 1}}, {"id": 43, "type": "enum", "text": "enum", "parent": 42, "children": [], "start_point": {"row": 59, "column": 8}, "end_point": {"row": 59, "column": 12}}, {"id": 44, "type": "type_identifier", "text": "_MessageStatus_t", "parent": 42, "children": [], "start_point": {"row": 59, "column": 13}, "end_point": {"row": 59, "column": 29}}, {"id": 45, "type": "enumerator_list", "text": "{\n /* if it is possible to post the request to MAC */\n APP_RESULT_OK = 0,\n /*\n * in all other cases such as duty cycle pending,\n * previous message retry pending etc.\n */\n APP_RESULT_BUSY\n}", "parent": 42, "children": [46, 50], "start_point": {"row": 60, "column": 0}, "end_point": {"row": 68, "column": 1}}, {"id": 46, "type": "enumerator", "text": "APP_RESULT_OK = 0", "parent": 45, "children": [47, 48, 49], "start_point": {"row": 62, "column": 4}, "end_point": {"row": 62, "column": 21}}, {"id": 47, "type": "identifier", "text": "APP_RESULT_OK", "parent": 46, "children": [], "start_point": {"row": 62, "column": 4}, "end_point": {"row": 62, "column": 17}}, {"id": 48, "type": "=", "text": "=", "parent": 46, "children": [], "start_point": {"row": 62, "column": 18}, "end_point": {"row": 62, "column": 19}}, {"id": 49, "type": "number_literal", "text": "0", "parent": 46, "children": [], "start_point": {"row": 62, "column": 20}, "end_point": {"row": 62, "column": 21}}, {"id": 50, "type": "enumerator", "text": "APP_RESULT_BUSY", "parent": 45, "children": [51], "start_point": {"row": 67, "column": 4}, "end_point": {"row": 67, "column": 19}}, {"id": 51, "type": "identifier", "text": "APP_RESULT_BUSY", "parent": 50, "children": [], "start_point": {"row": 67, "column": 4}, "end_point": {"row": 67, "column": 19}}, {"id": 52, "type": "type_identifier", "text": "AppResult_t", "parent": 40, "children": [], "start_point": {"row": 68, "column": 2}, "end_point": {"row": 68, "column": 13}}, {"id": 53, "type": "type_definition", "text": "typedef struct _MessageTx_t\n{\n /* Info for the MAC layer send request */\n LorawanSendReq_t lorawanReq;\n /* Number of retries left */\n uint8_t retries;\n /* Delay to elapse before the first transmit */\n uint32_t timeout;\n} MessageTx_t;", "parent": 0, "children": [54, 55, 67], "start_point": {"row": 73, "column": 0}, "end_point": {"row": 81, "column": 14}}, {"id": 54, "type": "typedef", "text": "typedef", "parent": 53, "children": [], "start_point": {"row": 73, "column": 0}, "end_point": {"row": 73, "column": 7}}, {"id": 55, "type": "struct_specifier", "text": "struct _MessageTx_t\n{\n /* Info for the MAC layer send request */\n LorawanSendReq_t lorawanReq;\n /* Number of retries left */\n uint8_t retries;\n /* Delay to elapse before the first transmit */\n uint32_t timeout;\n}", "parent": 53, "children": [56, 57], "start_point": {"row": 73, "column": 8}, "end_point": {"row": 81, "column": 1}}, {"id": 56, "type": "struct", "text": "struct", "parent": 55, "children": [], "start_point": {"row": 73, "column": 8}, "end_point": {"row": 73, "column": 14}}, {"id": 57, "type": "type_identifier", "text": "_MessageTx_t", "parent": 55, "children": [], "start_point": {"row": 73, "column": 15}, "end_point": {"row": 73, "column": 27}}, {"id": 58, "type": "field_declaration", "text": "LorawanSendReq_t lorawanReq;", "parent": 55, "children": [59, 60], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 32}}, {"id": 59, "type": "type_identifier", "text": "LorawanSendReq_t", "parent": 58, "children": [], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 20}}, {"id": 60, "type": "field_identifier", "text": "lorawanReq", "parent": 58, "children": [], "start_point": {"row": 76, "column": 21}, "end_point": {"row": 76, "column": 31}}, {"id": 61, "type": "field_declaration", "text": "uint8_t retries;", "parent": 55, "children": [62, 63], "start_point": {"row": 78, "column": 4}, "end_point": {"row": 78, "column": 20}}, {"id": 62, "type": "primitive_type", "text": "uint8_t", "parent": 61, "children": [], "start_point": {"row": 78, "column": 4}, "end_point": {"row": 78, "column": 11}}, {"id": 63, "type": "field_identifier", "text": "retries", "parent": 61, "children": [], "start_point": {"row": 78, "column": 12}, "end_point": {"row": 78, "column": 19}}, {"id": 64, "type": "field_declaration", "text": "uint32_t timeout;", "parent": 55, "children": [65, 66], "start_point": {"row": 80, "column": 4}, "end_point": {"row": 80, "column": 21}}, {"id": 65, "type": "primitive_type", "text": "uint32_t", "parent": 64, "children": [], "start_point": {"row": 80, "column": 4}, "end_point": {"row": 80, "column": 12}}, {"id": 66, "type": "field_identifier", "text": "timeout", "parent": 64, "children": [], "start_point": {"row": 80, "column": 13}, "end_point": {"row": 80, "column": 20}}, {"id": 67, "type": "type_identifier", "text": "MessageTx_t", "parent": 53, "children": [], "start_point": {"row": 81, "column": 2}, "end_point": {"row": 81, "column": 13}}, {"id": 68, "type": "type_definition", "text": "typedef struct _MessageRx_t\n{\n /* Info from the MAC layer receive done */\n appCbParams_t params;\n} MessageRx_t;", "parent": 0, "children": [69, 70, 76], "start_point": {"row": 86, "column": 0}, "end_point": {"row": 90, "column": 14}}, {"id": 69, "type": "typedef", "text": "typedef", "parent": 68, "children": [], "start_point": {"row": 86, "column": 0}, "end_point": {"row": 86, "column": 7}}, {"id": 70, "type": "struct_specifier", "text": "struct _MessageRx_t\n{\n /* Info from the MAC layer receive done */\n appCbParams_t params;\n}", "parent": 68, "children": [71, 72], "start_point": {"row": 86, "column": 8}, "end_point": {"row": 90, "column": 1}}, {"id": 71, "type": "struct", "text": "struct", "parent": 70, "children": [], "start_point": {"row": 86, "column": 8}, "end_point": {"row": 86, "column": 14}}, {"id": 72, "type": "type_identifier", "text": "_MessageRx_t", "parent": 70, "children": [], "start_point": {"row": 86, "column": 15}, "end_point": {"row": 86, "column": 27}}, {"id": 73, "type": "field_declaration", "text": "appCbParams_t params;", "parent": 70, "children": [74, 75], "start_point": {"row": 89, "column": 4}, "end_point": {"row": 89, "column": 25}}, {"id": 74, "type": "type_identifier", "text": "appCbParams_t", "parent": 73, "children": [], "start_point": {"row": 89, "column": 4}, "end_point": {"row": 89, "column": 17}}, {"id": 75, "type": "field_identifier", "text": "params", "parent": 73, "children": [], "start_point": {"row": 89, "column": 18}, "end_point": {"row": 89, "column": 24}}, {"id": 76, "type": "type_identifier", "text": "MessageRx_t", "parent": 68, "children": [], "start_point": {"row": 90, "column": 2}, "end_point": {"row": 90, "column": 13}}, {"id": 77, "type": "type_definition", "text": "typedef union _MessageState_t\n{\n /* Status bitfield */\n uint16_t value;\n /* Definition of individual bits */\n struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n };\n} MessageState_t;", "parent": 0, "children": [78, 79, 108], "start_point": {"row": 95, "column": 0}, "end_point": {"row": 122, "column": 17}}, {"id": 78, "type": "typedef", "text": "typedef", "parent": 77, "children": [], "start_point": {"row": 95, "column": 0}, "end_point": {"row": 95, "column": 7}}, {"id": 79, "type": "union_specifier", "text": "union _MessageState_t\n{\n /* Status bitfield */\n uint16_t value;\n /* Definition of individual bits */\n struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n };\n}", "parent": 77, "children": [80, 81], "start_point": {"row": 95, "column": 8}, "end_point": {"row": 122, "column": 1}}, {"id": 80, "type": "union", "text": "union", "parent": 79, "children": [], "start_point": {"row": 95, "column": 8}, "end_point": {"row": 95, "column": 13}}, {"id": 81, "type": "type_identifier", "text": "_MessageState_t", "parent": 79, "children": [], "start_point": {"row": 95, "column": 14}, "end_point": {"row": 95, "column": 29}}, {"id": 82, "type": "field_declaration", "text": "uint16_t value;", "parent": 79, "children": [83, 84], "start_point": {"row": 98, "column": 4}, "end_point": {"row": 98, "column": 19}}, {"id": 83, "type": "primitive_type", "text": "uint16_t", "parent": 82, "children": [], "start_point": {"row": 98, "column": 4}, "end_point": {"row": 98, "column": 12}}, {"id": 84, "type": "field_identifier", "text": "value", "parent": 82, "children": [], "start_point": {"row": 98, "column": 13}, "end_point": {"row": 98, "column": 18}}, {"id": 85, "type": "field_declaration", "text": "struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n };", "parent": 79, "children": [86], "start_point": {"row": 100, "column": 4}, "end_point": {"row": 121, "column": 6}}, {"id": 86, "type": "struct_specifier", "text": "struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n }", "parent": 85, "children": [87], "start_point": {"row": 100, "column": 4}, "end_point": {"row": 121, "column": 5}}, {"id": 87, "type": "struct", "text": "struct", "parent": 86, "children": [], "start_point": {"row": 100, "column": 4}, "end_point": {"row": 100, "column": 10}}, {"id": 88, "type": "field_declaration", "text": "uint16_t transactionInProgress : 1;", "parent": 86, "children": [89, 90, 91], "start_point": {"row": 105, "column": 8}, "end_point": {"row": 105, "column": 43}}, {"id": 89, "type": "primitive_type", "text": "uint16_t", "parent": 88, "children": [], "start_point": {"row": 105, "column": 8}, "end_point": {"row": 105, "column": 16}}, {"id": 90, "type": "field_identifier", "text": "transactionInProgress", "parent": 88, "children": [], "start_point": {"row": 105, "column": 17}, "end_point": {"row": 105, "column": 38}}, {"id": 91, "type": "bitfield_clause", "text": ": 1", "parent": 88, "children": [92], "start_point": {"row": 105, "column": 39}, "end_point": {"row": 105, "column": 42}}, {"id": 92, "type": "number_literal", "text": "1", "parent": 91, "children": [], "start_point": {"row": 105, "column": 41}, "end_point": {"row": 105, "column": 42}}, {"id": 93, "type": "field_declaration", "text": "uint16_t txWaiting : 1;", "parent": 86, "children": [94, 95, 96], "start_point": {"row": 110, "column": 8}, "end_point": {"row": 110, "column": 32}}, {"id": 94, "type": "primitive_type", "text": "uint16_t", "parent": 93, "children": [], "start_point": {"row": 110, "column": 8}, "end_point": {"row": 110, "column": 16}}, {"id": 95, "type": "field_identifier", "text": "txWaiting", "parent": 93, "children": [], "start_point": {"row": 110, "column": 17}, "end_point": {"row": 110, "column": 26}}, {"id": 96, "type": "bitfield_clause", "text": ": 1", "parent": 93, "children": [97], "start_point": {"row": 110, "column": 28}, "end_point": {"row": 110, "column": 31}}, {"id": 97, "type": "number_literal", "text": "1", "parent": 96, "children": [], "start_point": {"row": 110, "column": 30}, "end_point": {"row": 110, "column": 31}}, {"id": 98, "type": "field_declaration", "text": "uint16_t rxPending : 1;", "parent": 86, "children": [99, 100, 101], "start_point": {"row": 115, "column": 8}, "end_point": {"row": 115, "column": 32}}, {"id": 99, "type": "primitive_type", "text": "uint16_t", "parent": 98, "children": [], "start_point": {"row": 115, "column": 8}, "end_point": {"row": 115, "column": 16}}, {"id": 100, "type": "field_identifier", "text": "rxPending", "parent": 98, "children": [], "start_point": {"row": 115, "column": 17}, "end_point": {"row": 115, "column": 26}}, {"id": 101, "type": "bitfield_clause", "text": ": 1", "parent": 98, "children": [102], "start_point": {"row": 115, "column": 28}, "end_point": {"row": 115, "column": 31}}, {"id": 102, "type": "number_literal", "text": "1", "parent": 101, "children": [], "start_point": {"row": 115, "column": 30}, "end_point": {"row": 115, "column": 31}}, {"id": 103, "type": "field_declaration", "text": "uint16_t classRx2Dl : 1;", "parent": 86, "children": [104, 105, 106], "start_point": {"row": 120, "column": 8}, "end_point": {"row": 120, "column": 32}}, {"id": 104, "type": "primitive_type", "text": "uint16_t", "parent": 103, "children": [], "start_point": {"row": 120, "column": 8}, "end_point": {"row": 120, "column": 16}}, {"id": 105, "type": "field_identifier", "text": "classRx2Dl", "parent": 103, "children": [], "start_point": {"row": 120, "column": 17}, "end_point": {"row": 120, "column": 27}}, {"id": 106, "type": "bitfield_clause", "text": ": 1", "parent": 103, "children": [107], "start_point": {"row": 120, "column": 28}, "end_point": {"row": 120, "column": 31}}, {"id": 107, "type": "number_literal", "text": "1", "parent": 106, "children": [], "start_point": {"row": 120, "column": 30}, "end_point": {"row": 120, "column": 31}}, {"id": 108, "type": "type_identifier", "text": "MessageState_t", "parent": 77, "children": [], "start_point": {"row": 122, "column": 2}, "end_point": {"row": 122, "column": 16}}, {"id": 109, "type": "type_definition", "text": "typedef struct _FportCallbacks_t\n{\n /* Frame port number */\n uint8_t port;\n /* Callback to invoke when new message received in corresponding port */\n MsgCallback_t pFunc;\n} FportCallbacks_t;", "parent": 0, "children": [110, 111, 120], "start_point": {"row": 127, "column": 0}, "end_point": {"row": 133, "column": 19}}, {"id": 110, "type": "typedef", "text": "typedef", "parent": 109, "children": [], "start_point": {"row": 127, "column": 0}, "end_point": {"row": 127, "column": 7}}, {"id": 111, "type": "struct_specifier", "text": "struct _FportCallbacks_t\n{\n /* Frame port number */\n uint8_t port;\n /* Callback to invoke when new message received in corresponding port */\n MsgCallback_t pFunc;\n}", "parent": 109, "children": [112, 113], "start_point": {"row": 127, "column": 8}, "end_point": {"row": 133, "column": 1}}, {"id": 112, "type": "struct", "text": "struct", "parent": 111, "children": [], "start_point": {"row": 127, "column": 8}, "end_point": {"row": 127, "column": 14}}, {"id": 113, "type": "type_identifier", "text": "_FportCallbacks_t", "parent": 111, "children": [], "start_point": {"row": 127, "column": 15}, "end_point": {"row": 127, "column": 32}}, {"id": 114, "type": "field_declaration", "text": "uint8_t port;", "parent": 111, "children": [115, 116], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 17}}, {"id": 115, "type": "primitive_type", "text": "uint8_t", "parent": 114, "children": [], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 11}}, {"id": 116, "type": "field_identifier", "text": "port", "parent": 114, "children": [], "start_point": {"row": 130, "column": 12}, "end_point": {"row": 130, "column": 16}}, {"id": 117, "type": "field_declaration", "text": "MsgCallback_t pFunc;", "parent": 111, "children": [118, 119], "start_point": {"row": 132, "column": 4}, "end_point": {"row": 132, "column": 24}}, {"id": 118, "type": "type_identifier", "text": "MsgCallback_t", "parent": 117, "children": [], "start_point": {"row": 132, "column": 4}, "end_point": {"row": 132, "column": 17}}, {"id": 119, "type": "field_identifier", "text": "pFunc", "parent": 117, "children": [], "start_point": {"row": 132, "column": 18}, "end_point": {"row": 132, "column": 23}}, {"id": 120, "type": "type_identifier", "text": "FportCallbacks_t", "parent": 109, "children": [], "start_point": {"row": 133, "column": 2}, "end_point": {"row": 133, "column": 18}}, {"id": 121, "type": "declaration", "text": "void MSG_Init( void );", "parent": 0, "children": [122, 123], "start_point": {"row": 141, "column": 0}, "end_point": {"row": 141, "column": 22}}, {"id": 122, "type": "primitive_type", "text": "void", "parent": 121, "children": [], "start_point": {"row": 141, "column": 0}, "end_point": {"row": 141, "column": 4}}, {"id": 123, "type": "function_declarator", "text": "MSG_Init( void )", "parent": 121, "children": [124, 125], "start_point": {"row": 141, "column": 5}, "end_point": {"row": 141, "column": 21}}, {"id": 124, "type": "identifier", "text": "MSG_Init", "parent": 123, "children": [], "start_point": {"row": 141, "column": 5}, "end_point": {"row": 141, "column": 13}}, {"id": 125, "type": "parameter_list", "text": "( void )", "parent": 123, "children": [126], "start_point": {"row": 141, "column": 13}, "end_point": {"row": 141, "column": 21}}, {"id": 126, "type": "parameter_declaration", "text": "void", "parent": 125, "children": [127], "start_point": {"row": 141, "column": 15}, "end_point": {"row": 141, "column": 19}}, {"id": 127, "type": "primitive_type", "text": "void", "parent": 126, "children": [], "start_point": {"row": 141, "column": 15}, "end_point": {"row": 141, "column": 19}}, {"id": 128, "type": "declaration", "text": "uint16_t MSG_GetState( void );", "parent": 0, "children": [129, 130], "start_point": {"row": 148, "column": 0}, "end_point": {"row": 148, "column": 30}}, {"id": 129, "type": "primitive_type", "text": "uint16_t", "parent": 128, "children": [], "start_point": {"row": 148, "column": 0}, "end_point": {"row": 148, "column": 8}}, {"id": 130, "type": "function_declarator", "text": "MSG_GetState( void )", "parent": 128, "children": [131, 132], "start_point": {"row": 148, "column": 9}, "end_point": {"row": 148, "column": 29}}, {"id": 131, "type": "identifier", "text": "MSG_GetState", "parent": 130, "children": [], "start_point": {"row": 148, "column": 9}, "end_point": {"row": 148, "column": 21}}, {"id": 132, "type": "parameter_list", "text": "( void )", "parent": 130, "children": [133], "start_point": {"row": 148, "column": 21}, "end_point": {"row": 148, "column": 29}}, {"id": 133, "type": "parameter_declaration", "text": "void", "parent": 132, "children": [134], "start_point": {"row": 148, "column": 23}, "end_point": {"row": 148, "column": 27}}, {"id": 134, "type": "primitive_type", "text": "void", "parent": 133, "children": [], "start_point": {"row": 148, "column": 23}, "end_point": {"row": 148, "column": 27}}, {"id": 135, "type": "declaration", "text": "AppResult_t MSG_Send( TransmissionType_t msgType, uint8_t port, uint8_t *data,\n uint8_t length, uint32_t timeout );", "parent": 0, "children": [136, 137], "start_point": {"row": 163, "column": 0}, "end_point": {"row": 164, "column": 39}}, {"id": 136, "type": "type_identifier", "text": "AppResult_t", "parent": 135, "children": [], "start_point": {"row": 163, "column": 0}, "end_point": {"row": 163, "column": 11}}, {"id": 137, "type": "function_declarator", "text": "MSG_Send( TransmissionType_t msgType, uint8_t port, uint8_t *data,\n uint8_t length, uint32_t timeout )", "parent": 135, "children": [138, 139], "start_point": {"row": 163, "column": 12}, "end_point": {"row": 164, "column": 38}}, {"id": 138, "type": "identifier", "text": "MSG_Send", "parent": 137, "children": [], "start_point": {"row": 163, "column": 12}, "end_point": {"row": 163, "column": 20}}, {"id": 139, "type": "parameter_list", "text": "( TransmissionType_t msgType, uint8_t port, uint8_t *data,\n uint8_t length, uint32_t timeout )", "parent": 137, "children": [140, 143, 146, 151, 154], "start_point": {"row": 163, "column": 20}, "end_point": {"row": 164, "column": 38}}, {"id": 140, "type": "parameter_declaration", "text": "TransmissionType_t msgType", "parent": 139, "children": [141, 142], "start_point": {"row": 163, "column": 22}, "end_point": {"row": 163, "column": 48}}, {"id": 141, "type": "type_identifier", "text": "TransmissionType_t", "parent": 140, "children": [], "start_point": {"row": 163, "column": 22}, "end_point": {"row": 163, "column": 40}}, {"id": 142, "type": "identifier", "text": "msgType", "parent": 140, "children": [], "start_point": {"row": 163, "column": 41}, "end_point": {"row": 163, "column": 48}}, {"id": 143, "type": "parameter_declaration", "text": "uint8_t port", "parent": 139, "children": [144, 145], "start_point": {"row": 163, "column": 50}, "end_point": {"row": 163, "column": 62}}, {"id": 144, "type": "primitive_type", "text": "uint8_t", "parent": 143, "children": [], "start_point": {"row": 163, "column": 50}, "end_point": {"row": 163, "column": 57}}, {"id": 145, "type": "identifier", "text": "port", "parent": 143, "children": [], "start_point": {"row": 163, "column": 58}, "end_point": {"row": 163, "column": 62}}, {"id": 146, "type": "parameter_declaration", "text": "uint8_t *data", "parent": 139, "children": [147, 148], "start_point": {"row": 163, "column": 64}, "end_point": {"row": 163, "column": 77}}, {"id": 147, "type": "primitive_type", "text": "uint8_t", "parent": 146, "children": [], "start_point": {"row": 163, "column": 64}, "end_point": {"row": 163, "column": 71}}, {"id": 148, "type": "pointer_declarator", "text": "*data", "parent": 146, "children": [149, 150], "start_point": {"row": 163, "column": 72}, "end_point": {"row": 163, "column": 77}}, {"id": 149, "type": "*", "text": "*", "parent": 148, "children": [], "start_point": {"row": 163, "column": 72}, "end_point": {"row": 163, "column": 73}}, {"id": 150, "type": "identifier", "text": "data", "parent": 148, "children": [], "start_point": {"row": 163, "column": 73}, "end_point": {"row": 163, "column": 77}}, {"id": 151, "type": "parameter_declaration", "text": "uint8_t length", "parent": 139, "children": [152, 153], "start_point": {"row": 164, "column": 4}, "end_point": {"row": 164, "column": 18}}, {"id": 152, "type": "primitive_type", "text": "uint8_t", "parent": 151, "children": [], "start_point": {"row": 164, "column": 4}, "end_point": {"row": 164, "column": 11}}, {"id": 153, "type": "identifier", "text": "length", "parent": 151, "children": [], "start_point": {"row": 164, "column": 12}, "end_point": {"row": 164, "column": 18}}, {"id": 154, "type": "parameter_declaration", "text": "uint32_t timeout", "parent": 139, "children": [155, 156], "start_point": {"row": 164, "column": 20}, "end_point": {"row": 164, "column": 36}}, {"id": 155, "type": "primitive_type", "text": "uint32_t", "parent": 154, "children": [], "start_point": {"row": 164, "column": 20}, "end_point": {"row": 164, "column": 28}}, {"id": 156, "type": "identifier", "text": "timeout", "parent": 154, "children": [], "start_point": {"row": 164, "column": 29}, "end_point": {"row": 164, "column": 36}}, {"id": 157, "type": "declaration", "text": "void MSG_DataCallback( void *appHandle, appCbParams_t *params );", "parent": 0, "children": [158, 159], "start_point": {"row": 172, "column": 0}, "end_point": {"row": 172, "column": 64}}, {"id": 158, "type": "primitive_type", "text": "void", "parent": 157, "children": [], "start_point": {"row": 172, "column": 0}, "end_point": {"row": 172, "column": 4}}, {"id": 159, "type": "function_declarator", "text": "MSG_DataCallback( void *appHandle, appCbParams_t *params )", "parent": 157, "children": [160, 161], "start_point": {"row": 172, "column": 5}, "end_point": {"row": 172, "column": 63}}, {"id": 160, "type": "identifier", "text": "MSG_DataCallback", "parent": 159, "children": [], "start_point": {"row": 172, "column": 5}, "end_point": {"row": 172, "column": 21}}, {"id": 161, "type": "parameter_list", "text": "( void *appHandle, appCbParams_t *params )", "parent": 159, "children": [162, 167], "start_point": {"row": 172, "column": 21}, "end_point": {"row": 172, "column": 63}}, {"id": 162, "type": "parameter_declaration", "text": "void *appHandle", "parent": 161, "children": [163, 164], "start_point": {"row": 172, "column": 23}, "end_point": {"row": 172, "column": 38}}, {"id": 163, "type": "primitive_type", "text": "void", "parent": 162, "children": [], "start_point": {"row": 172, "column": 23}, "end_point": {"row": 172, "column": 27}}, {"id": 164, "type": "pointer_declarator", "text": "*appHandle", "parent": 162, "children": [165, 166], "start_point": {"row": 172, "column": 28}, "end_point": {"row": 172, "column": 38}}, {"id": 165, "type": "*", "text": "*", "parent": 164, "children": [], "start_point": {"row": 172, "column": 28}, "end_point": {"row": 172, "column": 29}}, {"id": 166, "type": "identifier", "text": "appHandle", "parent": 164, "children": [], "start_point": {"row": 172, "column": 29}, "end_point": {"row": 172, "column": 38}}, {"id": 167, "type": "parameter_declaration", "text": "appCbParams_t *params", "parent": 161, "children": [168, 169], "start_point": {"row": 172, "column": 40}, "end_point": {"row": 172, "column": 61}}, {"id": 168, "type": "type_identifier", "text": "appCbParams_t", "parent": 167, "children": [], "start_point": {"row": 172, "column": 40}, "end_point": {"row": 172, "column": 53}}, {"id": 169, "type": "pointer_declarator", "text": "*params", "parent": 167, "children": [170, 171], "start_point": {"row": 172, "column": 54}, "end_point": {"row": 172, "column": 61}}, {"id": 170, "type": "*", "text": "*", "parent": 169, "children": [], "start_point": {"row": 172, "column": 54}, "end_point": {"row": 172, "column": 55}}, {"id": 171, "type": "identifier", "text": "params", "parent": 169, "children": [], "start_point": {"row": 172, "column": 55}, "end_point": {"row": 172, "column": 61}}, {"id": 172, "type": "declaration", "text": "void MSG_SetFPortRxDataAvailCallback( uint8_t port, MsgCallback_t callback );", "parent": 0, "children": [173, 174], "start_point": {"row": 180, "column": 0}, "end_point": {"row": 180, "column": 77}}, {"id": 173, "type": "primitive_type", "text": "void", "parent": 172, "children": [], "start_point": {"row": 180, "column": 0}, "end_point": {"row": 180, "column": 4}}, {"id": 174, "type": "function_declarator", "text": "MSG_SetFPortRxDataAvailCallback( uint8_t port, MsgCallback_t callback )", "parent": 172, "children": [175, 176], "start_point": {"row": 180, "column": 5}, "end_point": {"row": 180, "column": 76}}, {"id": 175, "type": "identifier", "text": "MSG_SetFPortRxDataAvailCallback", "parent": 174, "children": [], "start_point": {"row": 180, "column": 5}, "end_point": {"row": 180, "column": 36}}, {"id": 176, "type": "parameter_list", "text": "( uint8_t port, MsgCallback_t callback )", "parent": 174, "children": [177, 180], "start_point": {"row": 180, "column": 36}, "end_point": {"row": 180, "column": 76}}, {"id": 177, "type": "parameter_declaration", "text": "uint8_t port", "parent": 176, "children": [178, 179], "start_point": {"row": 180, "column": 38}, "end_point": {"row": 180, "column": 50}}, {"id": 178, "type": "primitive_type", "text": "uint8_t", "parent": 177, "children": [], "start_point": {"row": 180, "column": 38}, "end_point": {"row": 180, "column": 45}}, {"id": 179, "type": "identifier", "text": "port", "parent": 177, "children": [], "start_point": {"row": 180, "column": 46}, "end_point": {"row": 180, "column": 50}}, {"id": 180, "type": "parameter_declaration", "text": "MsgCallback_t callback", "parent": 176, "children": [181, 182], "start_point": {"row": 180, "column": 52}, "end_point": {"row": 180, "column": 74}}, {"id": 181, "type": "type_identifier", "text": "MsgCallback_t", "parent": 180, "children": [], "start_point": {"row": 180, "column": 52}, "end_point": {"row": 180, "column": 65}}, {"id": 182, "type": "identifier", "text": "callback", "parent": 180, "children": [], "start_point": {"row": 180, "column": 66}, "end_point": {"row": 180, "column": 74}}, {"id": 183, "type": "declaration", "text": "void MSG_SetDefaultRxDataAvailCallback( MsgCallback_t callback );", "parent": 0, "children": [184, 185], "start_point": {"row": 189, "column": 0}, "end_point": {"row": 189, "column": 65}}, {"id": 184, "type": "primitive_type", "text": "void", "parent": 183, "children": [], "start_point": {"row": 189, "column": 0}, "end_point": {"row": 189, "column": 4}}, {"id": 185, "type": "function_declarator", "text": "MSG_SetDefaultRxDataAvailCallback( MsgCallback_t callback )", "parent": 183, "children": [186, 187], "start_point": {"row": 189, "column": 5}, "end_point": {"row": 189, "column": 64}}, {"id": 186, "type": "identifier", "text": "MSG_SetDefaultRxDataAvailCallback", "parent": 185, "children": [], "start_point": {"row": 189, "column": 5}, "end_point": {"row": 189, "column": 38}}, {"id": 187, "type": "parameter_list", "text": "( MsgCallback_t callback )", "parent": 185, "children": [188], "start_point": {"row": 189, "column": 38}, "end_point": {"row": 189, "column": 64}}, {"id": 188, "type": "parameter_declaration", "text": "MsgCallback_t callback", "parent": 187, "children": [189, 190], "start_point": {"row": 189, "column": 40}, "end_point": {"row": 189, "column": 62}}, {"id": 189, "type": "type_identifier", "text": "MsgCallback_t", "parent": 188, "children": [], "start_point": {"row": 189, "column": 40}, "end_point": {"row": 189, "column": 53}}, {"id": 190, "type": "identifier", "text": "callback", "parent": 188, "children": [], "start_point": {"row": 189, "column": 54}, "end_point": {"row": 189, "column": 62}}, {"id": 191, "type": "declaration", "text": "void MSG_SetTransactionCompleteCallback( MsgCallback_t callback );", "parent": 0, "children": [192, 193], "start_point": {"row": 196, "column": 0}, "end_point": {"row": 196, "column": 66}}, {"id": 192, "type": "primitive_type", "text": "void", "parent": 191, "children": [], "start_point": {"row": 196, "column": 0}, "end_point": {"row": 196, "column": 4}}, {"id": 193, "type": "function_declarator", "text": "MSG_SetTransactionCompleteCallback( MsgCallback_t callback )", "parent": 191, "children": [194, 195], "start_point": {"row": 196, "column": 5}, "end_point": {"row": 196, "column": 65}}, {"id": 194, "type": "identifier", "text": "MSG_SetTransactionCompleteCallback", "parent": 193, "children": [], "start_point": {"row": 196, "column": 5}, "end_point": {"row": 196, "column": 39}}, {"id": 195, "type": "parameter_list", "text": "( MsgCallback_t callback )", "parent": 193, "children": [196], "start_point": {"row": 196, "column": 39}, "end_point": {"row": 196, "column": 65}}, {"id": 196, "type": "parameter_declaration", "text": "MsgCallback_t callback", "parent": 195, "children": [197, 198], "start_point": {"row": 196, "column": 41}, "end_point": {"row": 196, "column": 63}}, {"id": 197, "type": "type_identifier", "text": "MsgCallback_t", "parent": 196, "children": [], "start_point": {"row": 196, "column": 41}, "end_point": {"row": 196, "column": 54}}, {"id": 198, "type": "identifier", "text": "callback", "parent": 196, "children": [], "start_point": {"row": 196, "column": 55}, "end_point": {"row": 196, "column": 63}}, {"id": 199, "type": "declaration", "text": "void MSG_Process( void );", "parent": 0, "children": [200, 201], "start_point": {"row": 202, "column": 0}, "end_point": {"row": 202, "column": 25}}, {"id": 200, "type": "primitive_type", "text": "void", "parent": 199, "children": [], "start_point": {"row": 202, "column": 0}, "end_point": {"row": 202, "column": 4}}, {"id": 201, "type": "function_declarator", "text": "MSG_Process( void )", "parent": 199, "children": [202, 203], "start_point": {"row": 202, "column": 5}, "end_point": {"row": 202, "column": 24}}, {"id": 202, "type": "identifier", "text": "MSG_Process", "parent": 201, "children": [], "start_point": {"row": 202, "column": 5}, "end_point": {"row": 202, "column": 16}}, {"id": 203, "type": "parameter_list", "text": "( void )", "parent": 201, "children": [204], "start_point": {"row": 202, "column": 16}, "end_point": {"row": 202, "column": 24}}, {"id": 204, "type": "parameter_declaration", "text": "void", "parent": 203, "children": [205], "start_point": {"row": 202, "column": 18}, "end_point": {"row": 202, "column": 22}}, {"id": 205, "type": "primitive_type", "text": "void", "parent": 204, "children": [], "start_point": {"row": 202, "column": 18}, "end_point": {"row": 202, "column": 22}}, {"id": 206, "type": "declaration", "text": "bool MSG_IsTxPossible( uint8_t len, uint32_t *txTime );", "parent": 0, "children": [207, 208], "start_point": {"row": 210, "column": 0}, "end_point": {"row": 210, "column": 55}}, {"id": 207, "type": "primitive_type", "text": "bool", "parent": 206, "children": [], "start_point": {"row": 210, "column": 0}, "end_point": {"row": 210, "column": 4}}, {"id": 208, "type": "function_declarator", "text": "MSG_IsTxPossible( uint8_t len, uint32_t *txTime )", "parent": 206, "children": [209, 210], "start_point": {"row": 210, "column": 5}, "end_point": {"row": 210, "column": 54}}, {"id": 209, "type": "identifier", "text": "MSG_IsTxPossible", "parent": 208, "children": [], "start_point": {"row": 210, "column": 5}, "end_point": {"row": 210, "column": 21}}, {"id": 210, "type": "parameter_list", "text": "( uint8_t len, uint32_t *txTime )", "parent": 208, "children": [211, 214], "start_point": {"row": 210, "column": 21}, "end_point": {"row": 210, "column": 54}}, {"id": 211, "type": "parameter_declaration", "text": "uint8_t len", "parent": 210, "children": [212, 213], "start_point": {"row": 210, "column": 23}, "end_point": {"row": 210, "column": 34}}, {"id": 212, "type": "primitive_type", "text": "uint8_t", "parent": 211, "children": [], "start_point": {"row": 210, "column": 23}, "end_point": {"row": 210, "column": 30}}, {"id": 213, "type": "identifier", "text": "len", "parent": 211, "children": [], "start_point": {"row": 210, "column": 31}, "end_point": {"row": 210, "column": 34}}, {"id": 214, "type": "parameter_declaration", "text": "uint32_t *txTime", "parent": 210, "children": [215, 216], "start_point": {"row": 210, "column": 36}, "end_point": {"row": 210, "column": 52}}, {"id": 215, "type": "primitive_type", "text": "uint32_t", "parent": 214, "children": [], "start_point": {"row": 210, "column": 36}, "end_point": {"row": 210, "column": 44}}, {"id": 216, "type": "pointer_declarator", "text": "*txTime", "parent": 214, "children": [217, 218], "start_point": {"row": 210, "column": 45}, "end_point": {"row": 210, "column": 52}}, {"id": 217, "type": "*", "text": "*", "parent": 216, "children": [], "start_point": {"row": 210, "column": 45}, "end_point": {"row": 210, "column": 46}}, {"id": 218, "type": "identifier", "text": "txTime", "parent": 216, "children": [], "start_point": {"row": 210, "column": 46}, "end_point": {"row": 210, "column": 52}}, {"id": 219, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 212, "column": 0}, "end_point": {"row": 212, "column": 6}}]}, "node_categories": {"declarations": {"functions": [29, 123, 130, 137, 159, 174, 185, 193, 201, 208], "variables": [26, 35, 40, 53, 58, 61, 64, 68, 73, 77, 82, 85, 88, 93, 98, 103, 109, 114, 117, 121, 126, 128, 133, 135, 140, 143, 146, 151, 154, 157, 162, 167, 172, 177, 180, 183, 188, 191, 196, 199, 204, 206, 211, 214], "classes": [55, 56, 70, 71, 79, 80, 86, 87, 111, 112], "imports": [], "modules": [], "enums": [42, 43, 45, 46, 50]}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 8, 12, 16, 20, 24, 33, 36, 39, 44, 47, 51, 52, 57, 59, 60, 63, 66, 67, 72, 74, 75, 76, 81, 84, 90, 95, 100, 105, 108, 113, 116, 118, 119, 120, 124, 131, 136, 138, 141, 142, 145, 150, 153, 156, 160, 166, 168, 171, 175, 179, 181, 182, 186, 189, 190, 194, 197, 198, 202, 209, 213, 218, 219], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [49, 92, 97, 102, 107], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": [91, 96, 101, 106]}}, "cross_language_map": {"function_declarations": [{"node_id": 29, "universal_type": "function", "name": "unknown", "text_snippet": "(*MsgCallback_t)(appCbParams_t *params )"}, {"node_id": 123, "universal_type": "function", "name": ")", "text_snippet": "MSG_Init( void )"}, {"node_id": 130, "universal_type": "function", "name": ")", "text_snippet": "MSG_GetState( void )"}, {"node_id": 137, "universal_type": "function", "name": "unknown", "text_snippet": "MSG_Send( TransmissionType_t msgType, uint8_t port, uint8_t *data,\n uint8_t length, uint32_t time"}, {"node_id": 159, "universal_type": "function", "name": "*appHandle,", "text_snippet": "MSG_DataCallback( void *appHandle, appCbParams_t *params )"}, {"node_id": 174, "universal_type": "function", "name": "unknown", "text_snippet": "MSG_SetFPortRxDataAvailCallback( uint8_t port, MsgCallback_t callback )"}, {"node_id": 185, "universal_type": "function", "name": "unknown", "text_snippet": "MSG_SetDefaultRxDataAvailCallback( MsgCallback_t callback )"}, {"node_id": 193, "universal_type": "function", "name": "unknown", "text_snippet": "MSG_SetTransactionCompleteCallback( MsgCallback_t callback )"}, {"node_id": 201, "universal_type": "function", "name": ")", "text_snippet": "MSG_Process( void )"}, {"node_id": 208, "universal_type": "function", "name": "unknown", "text_snippet": "MSG_IsTxPossible( uint8_t len, uint32_t *txTime )"}], "class_declarations": [{"node_id": 55, "universal_type": "class", "name": "_MessageTx_t", "text_snippet": "struct _MessageTx_t\n{\n /* Info for the MAC layer send request */\n LorawanSendReq_t lorawanReq;"}, {"node_id": 56, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 70, "universal_type": "class", "name": "_MessageRx_t", "text_snippet": "struct _MessageRx_t\n{\n /* Info from the MAC layer receive done */\n appCbParams_t params;\n}"}, {"node_id": 71, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 79, "universal_type": "class", "name": "_MessageState_t", "text_snippet": "union _MessageState_t\n{\n /* Status bitfield */\n uint16_t value;\n /* Definition of individua"}, {"node_id": 80, "universal_type": "class", "name": "unknown", "text_snippet": "union"}, {"node_id": 86, "universal_type": "class", "name": "{", "text_snippet": "struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message trans"}, {"node_id": 87, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 111, "universal_type": "class", "name": "_FportCallbacks_t", "text_snippet": "struct _FportCallbacks_t\n{\n /* Frame port number */\n uint8_t port;\n /* Callback to invoke w"}, {"node_id": 112, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": []}, "original_source_code": "/**\n* \\file msg.h\n*\n* \\brief LoRaWAN application messaging support interfaces\n*\n*\n* Copyright (c) 2020 Microchip Technology Inc. and its subsidiaries.\n*\n* \\asf_license_start\n*\n* \\page License\n*\n* Subject to your compliance with these terms, you may use Microchip\n* software and any derivatives exclusively with Microchip products.\n* It is your responsibility to comply with third party license terms applicable\n* to your use of third party software (including open source software) that\n* may accompany Microchip software.\n*\n* THIS SOFTWARE IS SUPPLIED BY MICROCHIP \"AS IS\". NO WARRANTIES,\n* WHETHER EXPRESS, IMPLIED OR STATUTORY, APPLY TO THIS SOFTWARE,\n* INCLUDING ANY IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY,\n* AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT WILL MICROCHIP BE\n* LIABLE FOR ANY INDIRECT, SPECIAL, PUNITIVE, INCIDENTAL OR CONSEQUENTIAL\n* LOSS, DAMAGE, COST OR EXPENSE OF ANY KIND WHATSOEVER RELATED TO THE\n* SOFTWARE, HOWEVER CAUSED, EVEN IF MICROCHIP HAS BEEN ADVISED OF THE\n* POSSIBILITY OR THE DAMAGES ARE FORESEEABLE. TO THE FULLEST EXTENT\n* ALLOWED BY LAW, MICROCHIP'S TOTAL LIABILITY ON ALL CLAIMS IN ANY WAY\n* RELATED TO THIS SOFTWARE WILL NOT EXCEED THE AMOUNT OF FEES, IF ANY,\n* THAT YOU HAVE PAID DIRECTLY TO MICROCHIP FOR THIS SOFTWARE.\n*\n* \\asf_license_stop\n*\n*/\n/*\n* Support and FAQ: visit <a href=\"https://www.microchip.com/support/\">Microchip Support</a>\n*/\n#ifndef _MSG_H_\n#define _MSG_H_\n\n/************************************************************************/\n/* CONSTANTS */\n/************************************************************************/\n#define MSG_RX_BUFFER_SIZE (255)\n#define MSG_TX_BUFFER_SIZE (255)\n#define MSG_FPORT_CB_MAX (5)\n#define MSG_CLASS_C_INTER_DOWNLINK_TIME_MS (3000)\n#define MSG_MAX_RX_WINDOW_TIME_MS (3000)\n\n/************************************************************************/\n/* TYPE DEFINES */\n/************************************************************************/\n/*\n* Type of the function callback invoked by messaging interface\n*/\ntypedef void (*MsgCallback_t)(appCbParams_t *params );\n\n/*\n* List of status codes returned by messaging interface\n*/\ntypedef enum _MessageStatus_t\n{\n /* if it is possible to post the request to MAC */\n APP_RESULT_OK = 0,\n /*\n * in all other cases such as duty cycle pending,\n * previous message retry pending etc.\n */\n APP_RESULT_BUSY\n} AppResult_t;\n\n/*\n* Structure of the message transmit request\n*/\ntypedef struct _MessageTx_t\n{\n /* Info for the MAC layer send request */\n LorawanSendReq_t lorawanReq;\n /* Number of retries left */\n uint8_t retries;\n /* Delay to elapse before the first transmit */\n uint32_t timeout;\n} MessageTx_t;\n\n/*\n* Structure of the message receive indication\n*/\ntypedef struct _MessageRx_t\n{\n /* Info from the MAC layer receive done */\n appCbParams_t params;\n} MessageRx_t;\n\n/*\n* State of the messaging support\n*/\ntypedef union _MessageState_t\n{\n /* Status bitfield */\n uint16_t value;\n /* Definition of individual bits */\n struct {\n /*\n * 0 -> messaging interface is idle\n * 1 -> previous message transaction yet to complete\n */\n uint16_t transactionInProgress : 1;\n /*\n * 0 -> no message pending for transmission\n * 1 -> retry or new message is pending for transmission\n */\n uint16_t txWaiting : 1;\n /*\n * 0 -> no new message is received\n * 1 -> new message received and waiting for processing\n */\n uint16_t rxPending : 1;\n /*\n * 0 -> no new message received in class-C RXC_CONT window\n * 1 -> new message received in class-C RXC_CONT window and pending\n */\n uint16_t classRx2Dl : 1;\n };\n} MessageState_t;\n\n/*\n* Structure of Fport callback info\n*/\ntypedef struct _FportCallbacks_t\n{\n /* Frame port number */\n uint8_t port;\n /* Callback to invoke when new message received in corresponding port */\n MsgCallback_t pFunc;\n} FportCallbacks_t;\n\n/************************************************************************/\n/* FUNCTION PROTOTYPES */\n/************************************************************************/\n/*\n* \\brief Initializes the messaging support\n*/\nvoid MSG_Init( void );\n\n/*\n* \\brief Returns the current state of messaging support\n*\n* \\return State bitfield value (MessageState_t)\n*/\nuint16_t MSG_GetState( void );\n\n/*\n* \\brief Requests the MAC layer to send the given data\n*\n* \\param[in] msgType - (TransmissionType_t) confirmed or unconfirmed\n* \\param[in] port - frame port number\n* \\param[in] * data - pointer to payload data\n* \\param[in] length - length of the payload data\n* \\param[in] timeout - delay to elapse before requesting MAC\n*\n* \\return Status of the request\n* APP_RESULT_OK - if request posted to MAC\n* APP_RESULT_BUSY - if not possible to process the request\n*/\nAppResult_t MSG_Send( TransmissionType_t msgType, uint8_t port, uint8_t *data,\n uint8_t length, uint32_t timeout );\n\n/*\n* \\brief Callback definition to process the received data from MAC\n*\n* \\param[in] *appHandle - pointer to appHandle from MAC data callback\n* \\param[in] *params - pointer to appCbParams_t from MAC data callback\n*/\nvoid MSG_DataCallback( void *appHandle, appCbParams_t *params );\n\n/*\n* \\brief Sets the callback to invoke for payload received in corresponding fport\n*\n* \\param[in] port - fport to map the callback\n* \\param[in] callback - pointer to callback function for mapping\n*/\nvoid MSG_SetFPortRxDataAvailCallback( uint8_t port, MsgCallback_t callback );\n\n/*\n* \\brief Sets the default callback to invoke for payload received from MAC. If,\n* there is a fport-specific mapping available, then default will not be\n* called in that case.\n*\n* \\param[in] callback - pointer to callback function to be invoked for payload\n*/\nvoid MSG_SetDefaultRxDataAvailCallback( MsgCallback_t callback );\n\n/*\n* \\brief Sets the callback to invoke for transaction complete event\n*\n* \\param[in] callback - pointer to callback function\n*/\nvoid MSG_SetTransactionCompleteCallback( MsgCallback_t callback );\n\n/*\n* \\brief Function to run the messaging support. It shall be called from\n* application to keep this layer running.\n*/\nvoid MSG_Process( void );\n\n/*\n* \\brief Returns if it is possible to transmit now\n*\n* \\param[in] len - length of the message to transmit\n* \\param[out] *txTime - time-on-air of the given message\n*/\nbool MSG_IsTxPossible( uint8_t len, uint32_t *txTime );\n\n#endif // _MSG_H_\n\n/* eof msg.h */\n"}
80,572
c
#include <stdio.h> #include <stdbool.h> #include <stdlib.h> #include <string.h> bool isAWhitespace(char c){ return c == ' ' || c == '\t' || c == '\n'; } bool isCapital(char c){ if(c >= 'A' && c <= 'Z') return true; return false; } int getNextNonWhitespace(char *str, int index){ int i = index; while(isAWhitespace(str[i]) && str[i] != 0) i++; return i; } int getNextWhitespace(char *str, int index){ int i = index; while(!isAWhitespace(str[i]) && str[i] != 0) i++; return i; } int countFirstCapitals(char *str){ int count = 0, i = 0; while(str[i] != 0){ i = getNextNonWhitespace(str, i); if(str[i] == 0) break; if(isCapital(str[i])) count++; i = getNextWhitespace(str, i); } return count; } int *getFirstCapitals(char *str){ int size = countFirstCapitals(str); int *firstCapitals = malloc(size * sizeof(int)); int i = 0, count = 0; while(str[i] != 0){ i = getNextNonWhitespace(str, i); if(str[i] == 0) break; if(isCapital(str[i])){ firstCapitals[count++] = i; } i = getNextWhitespace(str, i); } return firstCapitals; } char *readLine(){ int size = 64; char *line = malloc(size * sizeof(char)); char c = 0; int i = 0; while(true){ if(i == size){ size = 2 * size; line = realloc(line, size * sizeof(char)); } c = getc(stdin); if(c == '\n'){ line[i++] = 0; break; } line[i++] = c; } line = realloc(line, i * sizeof(char)); return line; } char **readLines(){ int size = 5; const char *end = "end"; char **lines = malloc(sizeof(char *) * size); int i = 0; while(true){ char *next = readLine(); if(!strcmp(next, &end[0])){ free(next); lines[i++] = NULL; break; } lines[i++] = next; // printf("i: %d/%d, %s\n", i, size, lines[i - 1]); if(i == size){ size = 2 * size; lines = realloc(lines, sizeof(char *) * size); } } lines = realloc(lines, i * sizeof(char *)); return lines; } void freeLines(char **lines){ int i = 0; while(lines[i] != NULL){ free(lines[i++]); } free(lines); } char *formatStr(char *old){ char *str = malloc(sizeof(char) * strlen(old) + 1); int i, j, start, end, newpos; bool notFirstWord = false; i = 0; newpos = 0; while(old[i] != 0){ int start = getNextNonWhitespace(old, i); int end = getNextWhitespace(old, start); if(isCapital(old[start])){ if(notFirstWord){ str[newpos++] = ' '; }else{ notFirstWord = true; } for(j = start; j < end; j++){ str[newpos++] = old[j]; } } i = end; } i = 0; while(old[i] != 0){ int start = getNextNonWhitespace(old, i); int end = getNextWhitespace(old, start); if(!isCapital(old[start])){ if(notFirstWord){ str[newpos++] = ' '; }else{ notFirstWord = true; } for(j = start; j < end; j++){ str[newpos++] = old[j]; } } i = end; } str[newpos] = 0; free(old); return str; } void format(char **lines){ int i = 0; while(lines[i] != NULL){ lines[i] = formatStr(lines[i]); i++; } } void printStr(char *str){ char c = 0; while(c = *(str++)){ putc(c, stdout); if(c == '.'){ printf("\n\t"); } } putc('\n', stdout); } void printFormat(char **lines){ int i = 0; while(lines[i] != NULL){ printStr(lines[i]); i++; } } int main(){ char **lines = NULL; int size = 0; char c = 0; int i = 0, j, k; lines = readLines(); format(lines); printFormat(lines); freeLines(lines); return 0; }
18.83
222
(translation_unit) "#include <stdio.h> \n#include <stdbool.h> \n#include <stdlib.h> \n#include <string.h> \n \nbool isAWhitespace(char c){ \n return c == ' ' || c == '\t' || c == '\n'; \n} \n \nbool isCapital(char c){ \n if(c >= 'A' && c <= 'Z') return true; \n return false; \n} \n \nint getNextNonWhitespace(char *str, int index){ \n int i = index; \n while(isAWhitespace(str[i]) && str[i] != 0) i++; \n return i; \n} \n \nint getNextWhitespace(char *str, int index){ \n int i = index; \n while(!isAWhitespace(str[i]) && str[i] != 0) i++; \n return i; \n} \n \nint countFirstCapitals(char *str){ \n int count = 0, i = 0; \n \n while(str[i] != 0){ \n i = getNextNonWhitespace(str, i); \n if(str[i] == 0) break; \n if(isCapital(str[i])) count++; \n i = getNextWhitespace(str, i); \n } \n \n return count; \n} \n \nint *getFirstCapitals(char *str){ \n int size = countFirstCapitals(str); \n int *firstCapitals = malloc(size * sizeof(int)); \n int i = 0, count = 0; \n while(str[i] != 0){ \n i = getNextNonWhitespace(str, i); \n if(str[i] == 0) break; \n if(isCapital(str[i])){ \n firstCapitals[count++] = i; \n } \n i = getNextWhitespace(str, i); \n } \n \n return firstCapitals; \n} \n \nchar *readLine(){ \n int size = 64; \n char *line = malloc(size * sizeof(char)); \n char c = 0; \n int i = 0; \n \n while(true){ \n \n if(i == size){ \n size = 2 * size; \n line = realloc(line, size * sizeof(char)); \n } \n \n c = getc(stdin); \n \n if(c == '\n'){ \n line[i++] = 0; \n break; \n } \n \n line[i++] = c; \n } \n \n line = realloc(line, i * sizeof(char)); \n \n return line; \n} \n \nchar **readLines(){ \n int size = 5; \n const char *end = "end"; \n char **lines = malloc(sizeof(char *) * size); \n int i = 0; \n \n while(true){ \n char *next = readLine(); \n \n if(!strcmp(next, &end[0])){ \n free(next); \n lines[i++] = NULL; \n break; \n } \n \n lines[i++] = next; \n \n // printf("i: %d/%d, %s\n", i, size, lines[i - 1]); \n \n if(i == size){ \n size = 2 * size; \n lines = realloc(lines, sizeof(char *) * size); \n } \n } \n \n lines = realloc(lines, i * sizeof(char *)); \n \n return lines; \n} \n \nvoid freeLines(char **lines){ \n int i = 0; \n \n while(lines[i] != NULL){ \n free(lines[i++]); \n } \n \n free(lines); \n} \n \nchar *formatStr(char *old){ \n char *str = malloc(sizeof(char) * strlen(old) + 1); \n int i, j, start, end, newpos; \n bool notFirstWord = false; \n \n i = 0; \n newpos = 0; \n while(old[i] != 0){ \n int start = getNextNonWhitespace(old, i); \n int end = getNextWhitespace(old, start); \n \n if(isCapital(old[start])){ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n } \n \n i = end; \n } \n \n i = 0; \n while(old[i] != 0){ \n int start = getNextNonWhitespace(old, i); \n int end = getNextWhitespace(old, start); \n \n if(!isCapital(old[start])){ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n } \n \n i = end; \n } \n \n str[newpos] = 0; \n \n free(old); \n return str; \n} \n \nvoid format(char **lines){ \n int i = 0; \n \n while(lines[i] != NULL){ \n lines[i] = formatStr(lines[i]); \n i++; \n } \n} \n \nvoid printStr(char *str){ \n char c = 0; \n while(c = *(str++)){ \n putc(c, stdout); \n \n if(c == '.'){ \n printf("\n\t"); \n } \n } \n putc('\n', stdout); \n} \n \nvoid printFormat(char **lines){ \n int i = 0; \n while(lines[i] != NULL){ \n printStr(lines[i]); \n i++; \n } \n} \n \nint main(){ \n char **lines = NULL; \n int size = 0; \n char c = 0; \n int i = 0, j, k; \n \n lines = readLines(); \n \n format(lines); \n \n printFormat(lines); \n \n freeLines(lines); \n \n return 0; \n} \n" (preproc_include) "#include <stdio.h> \n" (#include) "#include" (system_lib_string) "<stdio.h>" (preproc_include) "#include <stdbool.h> \n" (#include) "#include" (system_lib_string) "<stdbool.h>" (preproc_include) "#include <stdlib.h> \n" (#include) "#include" (system_lib_string) "<stdlib.h>" (preproc_include) "#include <string.h> \n" (#include) "#include" (system_lib_string) "<string.h>" (function_definition) "bool isAWhitespace(char c){ \n return c == ' ' || c == '\t' || c == '\n'; \n}" (primitive_type) "bool" (function_declarator) "isAWhitespace(char c)" (identifier) "isAWhitespace" (parameter_list) "(char c)" (() "(" (parameter_declaration) "char c" (primitive_type) "char" (identifier) "c" ()) ")" (compound_statement) "{ \n return c == ' ' || c == '\t' || c == '\n'; \n}" ({) "{" (return_statement) "return c == ' ' || c == '\t' || c == '\n';" (return) "return" (binary_expression) "c == ' ' || c == '\t' || c == '\n'" (binary_expression) "c == ' ' || c == '\t'" (binary_expression) "c == ' '" (identifier) "c" (==) "==" (char_literal) "' '" (') "'" (character) " " (') "'" (||) "||" (binary_expression) "c == '\t'" (identifier) "c" (==) "==" (char_literal) "'\t'" (') "'" (escape_sequence) "\t" (') "'" (||) "||" (binary_expression) "c == '\n'" (identifier) "c" (==) "==" (char_literal) "'\n'" (') "'" (escape_sequence) "\n" (') "'" (;) ";" (}) "}" (function_definition) "bool isCapital(char c){ \n if(c >= 'A' && c <= 'Z') return true; \n return false; \n}" (primitive_type) "bool" (function_declarator) "isCapital(char c)" (identifier) "isCapital" (parameter_list) "(char c)" (() "(" (parameter_declaration) "char c" (primitive_type) "char" (identifier) "c" ()) ")" (compound_statement) "{ \n if(c >= 'A' && c <= 'Z') return true; \n return false; \n}" ({) "{" (if_statement) "if(c >= 'A' && c <= 'Z') return true;" (if) "if" (parenthesized_expression) "(c >= 'A' && c <= 'Z')" (() "(" (binary_expression) "c >= 'A' && c <= 'Z'" (binary_expression) "c >= 'A'" (identifier) "c" (>=) ">=" (char_literal) "'A'" (') "'" (character) "A" (') "'" (&&) "&&" (binary_expression) "c <= 'Z'" (identifier) "c" (<=) "<=" (char_literal) "'Z'" (') "'" (character) "Z" (') "'" ()) ")" (return_statement) "return true;" (return) "return" (true) "true" (;) ";" (return_statement) "return false;" (return) "return" (false) "false" (;) ";" (}) "}" (function_definition) "int getNextNonWhitespace(char *str, int index){ \n int i = index; \n while(isAWhitespace(str[i]) && str[i] != 0) i++; \n return i; \n}" (primitive_type) "int" (function_declarator) "getNextNonWhitespace(char *str, int index)" (identifier) "getNextNonWhitespace" (parameter_list) "(char *str, int index)" (() "(" (parameter_declaration) "char *str" (primitive_type) "char" (pointer_declarator) "*str" (*) "*" (identifier) "str" (,) "," (parameter_declaration) "int index" (primitive_type) "int" (identifier) "index" ()) ")" (compound_statement) "{ \n int i = index; \n while(isAWhitespace(str[i]) && str[i] != 0) i++; \n return i; \n}" ({) "{" (declaration) "int i = index;" (primitive_type) "int" (init_declarator) "i = index" (identifier) "i" (=) "=" (identifier) "index" (;) ";" (while_statement) "while(isAWhitespace(str[i]) && str[i] != 0) i++;" (while) "while" (parenthesized_expression) "(isAWhitespace(str[i]) && str[i] != 0)" (() "(" (binary_expression) "isAWhitespace(str[i]) && str[i] != 0" (call_expression) "isAWhitespace(str[i])" (identifier) "isAWhitespace" (argument_list) "(str[i])" (() "(" (subscript_expression) "str[i]" (identifier) "str" ([) "[" (identifier) "i" (]) "]" ()) ")" (&&) "&&" (binary_expression) "str[i] != 0" (subscript_expression) "str[i]" (identifier) "str" ([) "[" (identifier) "i" (]) "]" (!=) "!=" (number_literal) "0" ()) ")" (expression_statement) "i++;" (update_expression) "i++" (identifier) "i" (++) "++" (;) ";" (return_statement) "return i;" (return) "return" (identifier) "i" (;) ";" (}) "}" (function_definition) "int getNextWhitespace(char *str, int index){ \n int i = index; \n while(!isAWhitespace(str[i]) && str[i] != 0) i++; \n return i; \n}" (primitive_type) "int" (function_declarator) "getNextWhitespace(char *str, int index)" (identifier) "getNextWhitespace" (parameter_list) "(char *str, int index)" (() "(" (parameter_declaration) "char *str" (primitive_type) "char" (pointer_declarator) "*str" (*) "*" (identifier) "str" (,) "," (parameter_declaration) "int index" (primitive_type) "int" (identifier) "index" ()) ")" (compound_statement) "{ \n int i = index; \n while(!isAWhitespace(str[i]) && str[i] != 0) i++; \n return i; \n}" ({) "{" (declaration) "int i = index;" (primitive_type) "int" (init_declarator) "i = index" (identifier) "i" (=) "=" (identifier) "index" (;) ";" (while_statement) "while(!isAWhitespace(str[i]) && str[i] != 0) i++;" (while) "while" (parenthesized_expression) "(!isAWhitespace(str[i]) && str[i] != 0)" (() "(" (binary_expression) "!isAWhitespace(str[i]) && str[i] != 0" (unary_expression) "!isAWhitespace(str[i])" (!) "!" (call_expression) "isAWhitespace(str[i])" (identifier) "isAWhitespace" (argument_list) "(str[i])" (() "(" (subscript_expression) "str[i]" (identifier) "str" ([) "[" (identifier) "i" (]) "]" ()) ")" (&&) "&&" (binary_expression) "str[i] != 0" (subscript_expression) "str[i]" (identifier) "str" ([) "[" (identifier) "i" (]) "]" (!=) "!=" (number_literal) "0" ()) ")" (expression_statement) "i++;" (update_expression) "i++" (identifier) "i" (++) "++" (;) ";" (return_statement) "return i;" (return) "return" (identifier) "i" (;) ";" (}) "}" (function_definition) "int countFirstCapitals(char *str){ \n int count = 0, i = 0; \n \n while(str[i] != 0){ \n i = getNextNonWhitespace(str, i); \n if(str[i] == 0) break; \n if(isCapital(str[i])) count++; \n i = getNextWhitespace(str, i); \n } \n \n return count; \n}" (primitive_type) "int" (function_declarator) "countFirstCapitals(char *str)" (identifier) "countFirstCapitals" (parameter_list) "(char *str)" (() "(" (parameter_declaration) "char *str" (primitive_type) "char" (pointer_declarator) "*str" (*) "*" (identifier) "str" ()) ")" (compound_statement) "{ \n int count = 0, i = 0; \n \n while(str[i] != 0){ \n i = getNextNonWhitespace(str, i); \n if(str[i] == 0) break; \n if(isCapital(str[i])) count++; \n i = getNextWhitespace(str, i); \n } \n \n return count; \n}" ({) "{" (declaration) "int count = 0, i = 0;" (primitive_type) "int" (init_declarator) "count = 0" (identifier) "count" (=) "=" (number_literal) "0" (,) "," (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (while_statement) "while(str[i] != 0){ \n i = getNextNonWhitespace(str, i); \n if(str[i] == 0) break; \n if(isCapital(str[i])) count++; \n i = getNextWhitespace(str, i); \n }" (while) "while" (parenthesized_expression) "(str[i] != 0)" (() "(" (binary_expression) "str[i] != 0" (subscript_expression) "str[i]" (identifier) "str" ([) "[" (identifier) "i" (]) "]" (!=) "!=" (number_literal) "0" ()) ")" (compound_statement) "{ \n i = getNextNonWhitespace(str, i); \n if(str[i] == 0) break; \n if(isCapital(str[i])) count++; \n i = getNextWhitespace(str, i); \n }" ({) "{" (expression_statement) "i = getNextNonWhitespace(str, i);" (assignment_expression) "i = getNextNonWhitespace(str, i)" (identifier) "i" (=) "=" (call_expression) "getNextNonWhitespace(str, i)" (identifier) "getNextNonWhitespace" (argument_list) "(str, i)" (() "(" (identifier) "str" (,) "," (identifier) "i" ()) ")" (;) ";" (if_statement) "if(str[i] == 0) break;" (if) "if" (parenthesized_expression) "(str[i] == 0)" (() "(" (binary_expression) "str[i] == 0" (subscript_expression) "str[i]" (identifier) "str" ([) "[" (identifier) "i" (]) "]" (==) "==" (number_literal) "0" ()) ")" (break_statement) "break;" (break) "break" (;) ";" (if_statement) "if(isCapital(str[i])) count++;" (if) "if" (parenthesized_expression) "(isCapital(str[i]))" (() "(" (call_expression) "isCapital(str[i])" (identifier) "isCapital" (argument_list) "(str[i])" (() "(" (subscript_expression) "str[i]" (identifier) "str" ([) "[" (identifier) "i" (]) "]" ()) ")" ()) ")" (expression_statement) "count++;" (update_expression) "count++" (identifier) "count" (++) "++" (;) ";" (expression_statement) "i = getNextWhitespace(str, i);" (assignment_expression) "i = getNextWhitespace(str, i)" (identifier) "i" (=) "=" (call_expression) "getNextWhitespace(str, i)" (identifier) "getNextWhitespace" (argument_list) "(str, i)" (() "(" (identifier) "str" (,) "," (identifier) "i" ()) ")" (;) ";" (}) "}" (return_statement) "return count;" (return) "return" (identifier) "count" (;) ";" (}) "}" (function_definition) "int *getFirstCapitals(char *str){ \n int size = countFirstCapitals(str); \n int *firstCapitals = malloc(size * sizeof(int)); \n int i = 0, count = 0; \n while(str[i] != 0){ \n i = getNextNonWhitespace(str, i); \n if(str[i] == 0) break; \n if(isCapital(str[i])){ \n firstCapitals[count++] = i; \n } \n i = getNextWhitespace(str, i); \n } \n \n return firstCapitals; \n}" (primitive_type) "int" (pointer_declarator) "*getFirstCapitals(char *str)" (*) "*" (function_declarator) "getFirstCapitals(char *str)" (identifier) "getFirstCapitals" (parameter_list) "(char *str)" (() "(" (parameter_declaration) "char *str" (primitive_type) "char" (pointer_declarator) "*str" (*) "*" (identifier) "str" ()) ")" (compound_statement) "{ \n int size = countFirstCapitals(str); \n int *firstCapitals = malloc(size * sizeof(int)); \n int i = 0, count = 0; \n while(str[i] != 0){ \n i = getNextNonWhitespace(str, i); \n if(str[i] == 0) break; \n if(isCapital(str[i])){ \n firstCapitals[count++] = i; \n } \n i = getNextWhitespace(str, i); \n } \n \n return firstCapitals; \n}" ({) "{" (declaration) "int size = countFirstCapitals(str);" (primitive_type) "int" (init_declarator) "size = countFirstCapitals(str)" (identifier) "size" (=) "=" (call_expression) "countFirstCapitals(str)" (identifier) "countFirstCapitals" (argument_list) "(str)" (() "(" (identifier) "str" ()) ")" (;) ";" (declaration) "int *firstCapitals = malloc(size * sizeof(int));" (primitive_type) "int" (init_declarator) "*firstCapitals = malloc(size * sizeof(int))" (pointer_declarator) "*firstCapitals" (*) "*" (identifier) "firstCapitals" (=) "=" (call_expression) "malloc(size * sizeof(int))" (identifier) "malloc" (argument_list) "(size * sizeof(int))" (() "(" (binary_expression) "size * sizeof(int)" (identifier) "size" (*) "*" (sizeof_expression) "sizeof(int)" (sizeof) "sizeof" (() "(" (type_descriptor) "int" (primitive_type) "int" ()) ")" ()) ")" (;) ";" (declaration) "int i = 0, count = 0;" (primitive_type) "int" (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (,) "," (init_declarator) "count = 0" (identifier) "count" (=) "=" (number_literal) "0" (;) ";" (while_statement) "while(str[i] != 0){ \n i = getNextNonWhitespace(str, i); \n if(str[i] == 0) break; \n if(isCapital(str[i])){ \n firstCapitals[count++] = i; \n } \n i = getNextWhitespace(str, i); \n }" (while) "while" (parenthesized_expression) "(str[i] != 0)" (() "(" (binary_expression) "str[i] != 0" (subscript_expression) "str[i]" (identifier) "str" ([) "[" (identifier) "i" (]) "]" (!=) "!=" (number_literal) "0" ()) ")" (compound_statement) "{ \n i = getNextNonWhitespace(str, i); \n if(str[i] == 0) break; \n if(isCapital(str[i])){ \n firstCapitals[count++] = i; \n } \n i = getNextWhitespace(str, i); \n }" ({) "{" (expression_statement) "i = getNextNonWhitespace(str, i);" (assignment_expression) "i = getNextNonWhitespace(str, i)" (identifier) "i" (=) "=" (call_expression) "getNextNonWhitespace(str, i)" (identifier) "getNextNonWhitespace" (argument_list) "(str, i)" (() "(" (identifier) "str" (,) "," (identifier) "i" ()) ")" (;) ";" (if_statement) "if(str[i] == 0) break;" (if) "if" (parenthesized_expression) "(str[i] == 0)" (() "(" (binary_expression) "str[i] == 0" (subscript_expression) "str[i]" (identifier) "str" ([) "[" (identifier) "i" (]) "]" (==) "==" (number_literal) "0" ()) ")" (break_statement) "break;" (break) "break" (;) ";" (if_statement) "if(isCapital(str[i])){ \n firstCapitals[count++] = i; \n }" (if) "if" (parenthesized_expression) "(isCapital(str[i]))" (() "(" (call_expression) "isCapital(str[i])" (identifier) "isCapital" (argument_list) "(str[i])" (() "(" (subscript_expression) "str[i]" (identifier) "str" ([) "[" (identifier) "i" (]) "]" ()) ")" ()) ")" (compound_statement) "{ \n firstCapitals[count++] = i; \n }" ({) "{" (expression_statement) "firstCapitals[count++] = i;" (assignment_expression) "firstCapitals[count++] = i" (subscript_expression) "firstCapitals[count++]" (identifier) "firstCapitals" ([) "[" (update_expression) "count++" (identifier) "count" (++) "++" (]) "]" (=) "=" (identifier) "i" (;) ";" (}) "}" (expression_statement) "i = getNextWhitespace(str, i);" (assignment_expression) "i = getNextWhitespace(str, i)" (identifier) "i" (=) "=" (call_expression) "getNextWhitespace(str, i)" (identifier) "getNextWhitespace" (argument_list) "(str, i)" (() "(" (identifier) "str" (,) "," (identifier) "i" ()) ")" (;) ";" (}) "}" (return_statement) "return firstCapitals;" (return) "return" (identifier) "firstCapitals" (;) ";" (}) "}" (function_definition) "char *readLine(){ \n int size = 64; \n char *line = malloc(size * sizeof(char)); \n char c = 0; \n int i = 0; \n \n while(true){ \n \n if(i == size){ \n size = 2 * size; \n line = realloc(line, size * sizeof(char)); \n } \n \n c = getc(stdin); \n \n if(c == '\n'){ \n line[i++] = 0; \n break; \n } \n \n line[i++] = c; \n } \n \n line = realloc(line, i * sizeof(char)); \n \n return line; \n}" (primitive_type) "char" (pointer_declarator) "*readLine()" (*) "*" (function_declarator) "readLine()" (identifier) "readLine" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{ \n int size = 64; \n char *line = malloc(size * sizeof(char)); \n char c = 0; \n int i = 0; \n \n while(true){ \n \n if(i == size){ \n size = 2 * size; \n line = realloc(line, size * sizeof(char)); \n } \n \n c = getc(stdin); \n \n if(c == '\n'){ \n line[i++] = 0; \n break; \n } \n \n line[i++] = c; \n } \n \n line = realloc(line, i * sizeof(char)); \n \n return line; \n}" ({) "{" (declaration) "int size = 64;" (primitive_type) "int" (init_declarator) "size = 64" (identifier) "size" (=) "=" (number_literal) "64" (;) ";" (declaration) "char *line = malloc(size * sizeof(char));" (primitive_type) "char" (init_declarator) "*line = malloc(size * sizeof(char))" (pointer_declarator) "*line" (*) "*" (identifier) "line" (=) "=" (call_expression) "malloc(size * sizeof(char))" (identifier) "malloc" (argument_list) "(size * sizeof(char))" (() "(" (binary_expression) "size * sizeof(char)" (identifier) "size" (*) "*" (sizeof_expression) "sizeof(char)" (sizeof) "sizeof" (() "(" (type_descriptor) "char" (primitive_type) "char" ()) ")" ()) ")" (;) ";" (declaration) "char c = 0;" (primitive_type) "char" (init_declarator) "c = 0" (identifier) "c" (=) "=" (number_literal) "0" (;) ";" (declaration) "int i = 0;" (primitive_type) "int" (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (while_statement) "while(true){ \n \n if(i == size){ \n size = 2 * size; \n line = realloc(line, size * sizeof(char)); \n } \n \n c = getc(stdin); \n \n if(c == '\n'){ \n line[i++] = 0; \n break; \n } \n \n line[i++] = c; \n }" (while) "while" (parenthesized_expression) "(true)" (() "(" (true) "true" ()) ")" (compound_statement) "{ \n \n if(i == size){ \n size = 2 * size; \n line = realloc(line, size * sizeof(char)); \n } \n \n c = getc(stdin); \n \n if(c == '\n'){ \n line[i++] = 0; \n break; \n } \n \n line[i++] = c; \n }" ({) "{" (if_statement) "if(i == size){ \n size = 2 * size; \n line = realloc(line, size * sizeof(char)); \n }" (if) "if" (parenthesized_expression) "(i == size)" (() "(" (binary_expression) "i == size" (identifier) "i" (==) "==" (identifier) "size" ()) ")" (compound_statement) "{ \n size = 2 * size; \n line = realloc(line, size * sizeof(char)); \n }" ({) "{" (expression_statement) "size = 2 * size;" (assignment_expression) "size = 2 * size" (identifier) "size" (=) "=" (binary_expression) "2 * size" (number_literal) "2" (*) "*" (identifier) "size" (;) ";" (expression_statement) "line = realloc(line, size * sizeof(char));" (assignment_expression) "line = realloc(line, size * sizeof(char))" (identifier) "line" (=) "=" (call_expression) "realloc(line, size * sizeof(char))" (identifier) "realloc" (argument_list) "(line, size * sizeof(char))" (() "(" (identifier) "line" (,) "," (binary_expression) "size * sizeof(char)" (identifier) "size" (*) "*" (sizeof_expression) "sizeof(char)" (sizeof) "sizeof" (() "(" (type_descriptor) "char" (primitive_type) "char" ()) ")" ()) ")" (;) ";" (}) "}" (expression_statement) "c = getc(stdin);" (assignment_expression) "c = getc(stdin)" (identifier) "c" (=) "=" (call_expression) "getc(stdin)" (identifier) "getc" (argument_list) "(stdin)" (() "(" (identifier) "stdin" ()) ")" (;) ";" (if_statement) "if(c == '\n'){ \n line[i++] = 0; \n break; \n }" (if) "if" (parenthesized_expression) "(c == '\n')" (() "(" (binary_expression) "c == '\n'" (identifier) "c" (==) "==" (char_literal) "'\n'" (') "'" (escape_sequence) "\n" (') "'" ()) ")" (compound_statement) "{ \n line[i++] = 0; \n break; \n }" ({) "{" (expression_statement) "line[i++] = 0;" (assignment_expression) "line[i++] = 0" (subscript_expression) "line[i++]" (identifier) "line" ([) "[" (update_expression) "i++" (identifier) "i" (++) "++" (]) "]" (=) "=" (number_literal) "0" (;) ";" (break_statement) "break;" (break) "break" (;) ";" (}) "}" (expression_statement) "line[i++] = c;" (assignment_expression) "line[i++] = c" (subscript_expression) "line[i++]" (identifier) "line" ([) "[" (update_expression) "i++" (identifier) "i" (++) "++" (]) "]" (=) "=" (identifier) "c" (;) ";" (}) "}" (expression_statement) "line = realloc(line, i * sizeof(char));" (assignment_expression) "line = realloc(line, i * sizeof(char))" (identifier) "line" (=) "=" (call_expression) "realloc(line, i * sizeof(char))" (identifier) "realloc" (argument_list) "(line, i * sizeof(char))" (() "(" (identifier) "line" (,) "," (binary_expression) "i * sizeof(char)" (identifier) "i" (*) "*" (sizeof_expression) "sizeof(char)" (sizeof) "sizeof" (() "(" (type_descriptor) "char" (primitive_type) "char" ()) ")" ()) ")" (;) ";" (return_statement) "return line;" (return) "return" (identifier) "line" (;) ";" (}) "}" (function_definition) "char **readLines(){ \n int size = 5; \n const char *end = "end"; \n char **lines = malloc(sizeof(char *) * size); \n int i = 0; \n \n while(true){ \n char *next = readLine(); \n \n if(!strcmp(next, &end[0])){ \n free(next); \n lines[i++] = NULL; \n break; \n } \n \n lines[i++] = next; \n \n // printf("i: %d/%d, %s\n", i, size, lines[i - 1]); \n \n if(i == size){ \n size = 2 * size; \n lines = realloc(lines, sizeof(char *) * size); \n } \n } \n \n lines = realloc(lines, i * sizeof(char *)); \n \n return lines; \n}" (primitive_type) "char" (pointer_declarator) "**readLines()" (*) "*" (pointer_declarator) "*readLines()" (*) "*" (function_declarator) "readLines()" (identifier) "readLines" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{ \n int size = 5; \n const char *end = "end"; \n char **lines = malloc(sizeof(char *) * size); \n int i = 0; \n \n while(true){ \n char *next = readLine(); \n \n if(!strcmp(next, &end[0])){ \n free(next); \n lines[i++] = NULL; \n break; \n } \n \n lines[i++] = next; \n \n // printf("i: %d/%d, %s\n", i, size, lines[i - 1]); \n \n if(i == size){ \n size = 2 * size; \n lines = realloc(lines, sizeof(char *) * size); \n } \n } \n \n lines = realloc(lines, i * sizeof(char *)); \n \n return lines; \n}" ({) "{" (declaration) "int size = 5;" (primitive_type) "int" (init_declarator) "size = 5" (identifier) "size" (=) "=" (number_literal) "5" (;) ";" (declaration) "const char *end = "end";" (type_qualifier) "const" (const) "const" (primitive_type) "char" (init_declarator) "*end = "end"" (pointer_declarator) "*end" (*) "*" (identifier) "end" (=) "=" (string_literal) ""end"" (") """ (string_content) "end" (") """ (;) ";" (declaration) "char **lines = malloc(sizeof(char *) * size);" (primitive_type) "char" (init_declarator) "**lines = malloc(sizeof(char *) * size)" (pointer_declarator) "**lines" (*) "*" (pointer_declarator) "*lines" (*) "*" (identifier) "lines" (=) "=" (call_expression) "malloc(sizeof(char *) * size)" (identifier) "malloc" (argument_list) "(sizeof(char *) * size)" (() "(" (binary_expression) "sizeof(char *) * size" (sizeof_expression) "sizeof(char *)" (sizeof) "sizeof" (() "(" (type_descriptor) "char *" (primitive_type) "char" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (*) "*" (identifier) "size" ()) ")" (;) ";" (declaration) "int i = 0;" (primitive_type) "int" (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (while_statement) "while(true){ \n char *next = readLine(); \n \n if(!strcmp(next, &end[0])){ \n free(next); \n lines[i++] = NULL; \n break; \n } \n \n lines[i++] = next; \n \n // printf("i: %d/%d, %s\n", i, size, lines[i - 1]); \n \n if(i == size){ \n size = 2 * size; \n lines = realloc(lines, sizeof(char *) * size); \n } \n }" (while) "while" (parenthesized_expression) "(true)" (() "(" (true) "true" ()) ")" (compound_statement) "{ \n char *next = readLine(); \n \n if(!strcmp(next, &end[0])){ \n free(next); \n lines[i++] = NULL; \n break; \n } \n \n lines[i++] = next; \n \n // printf("i: %d/%d, %s\n", i, size, lines[i - 1]); \n \n if(i == size){ \n size = 2 * size; \n lines = realloc(lines, sizeof(char *) * size); \n } \n }" ({) "{" (declaration) "char *next = readLine();" (primitive_type) "char" (init_declarator) "*next = readLine()" (pointer_declarator) "*next" (*) "*" (identifier) "next" (=) "=" (call_expression) "readLine()" (identifier) "readLine" (argument_list) "()" (() "(" ()) ")" (;) ";" (if_statement) "if(!strcmp(next, &end[0])){ \n free(next); \n lines[i++] = NULL; \n break; \n }" (if) "if" (parenthesized_expression) "(!strcmp(next, &end[0]))" (() "(" (unary_expression) "!strcmp(next, &end[0])" (!) "!" (call_expression) "strcmp(next, &end[0])" (identifier) "strcmp" (argument_list) "(next, &end[0])" (() "(" (identifier) "next" (,) "," (pointer_expression) "&end[0]" (&) "&" (subscript_expression) "end[0]" (identifier) "end" ([) "[" (number_literal) "0" (]) "]" ()) ")" ()) ")" (compound_statement) "{ \n free(next); \n lines[i++] = NULL; \n break; \n }" ({) "{" (expression_statement) "free(next);" (call_expression) "free(next)" (identifier) "free" (argument_list) "(next)" (() "(" (identifier) "next" ()) ")" (;) ";" (expression_statement) "lines[i++] = NULL;" (assignment_expression) "lines[i++] = NULL" (subscript_expression) "lines[i++]" (identifier) "lines" ([) "[" (update_expression) "i++" (identifier) "i" (++) "++" (]) "]" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (break_statement) "break;" (break) "break" (;) ";" (}) "}" (expression_statement) "lines[i++] = next;" (assignment_expression) "lines[i++] = next" (subscript_expression) "lines[i++]" (identifier) "lines" ([) "[" (update_expression) "i++" (identifier) "i" (++) "++" (]) "]" (=) "=" (identifier) "next" (;) ";" (comment) "// printf("i: %d/%d, %s\n", i, size, lines[i - 1]); " (if_statement) "if(i == size){ \n size = 2 * size; \n lines = realloc(lines, sizeof(char *) * size); \n }" (if) "if" (parenthesized_expression) "(i == size)" (() "(" (binary_expression) "i == size" (identifier) "i" (==) "==" (identifier) "size" ()) ")" (compound_statement) "{ \n size = 2 * size; \n lines = realloc(lines, sizeof(char *) * size); \n }" ({) "{" (expression_statement) "size = 2 * size;" (assignment_expression) "size = 2 * size" (identifier) "size" (=) "=" (binary_expression) "2 * size" (number_literal) "2" (*) "*" (identifier) "size" (;) ";" (expression_statement) "lines = realloc(lines, sizeof(char *) * size);" (assignment_expression) "lines = realloc(lines, sizeof(char *) * size)" (identifier) "lines" (=) "=" (call_expression) "realloc(lines, sizeof(char *) * size)" (identifier) "realloc" (argument_list) "(lines, sizeof(char *) * size)" (() "(" (identifier) "lines" (,) "," (binary_expression) "sizeof(char *) * size" (sizeof_expression) "sizeof(char *)" (sizeof) "sizeof" (() "(" (type_descriptor) "char *" (primitive_type) "char" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (*) "*" (identifier) "size" ()) ")" (;) ";" (}) "}" (}) "}" (expression_statement) "lines = realloc(lines, i * sizeof(char *));" (assignment_expression) "lines = realloc(lines, i * sizeof(char *))" (identifier) "lines" (=) "=" (call_expression) "realloc(lines, i * sizeof(char *))" (identifier) "realloc" (argument_list) "(lines, i * sizeof(char *))" (() "(" (identifier) "lines" (,) "," (binary_expression) "i * sizeof(char *)" (identifier) "i" (*) "*" (sizeof_expression) "sizeof(char *)" (sizeof) "sizeof" (() "(" (type_descriptor) "char *" (primitive_type) "char" (abstract_pointer_declarator) "*" (*) "*" ()) ")" ()) ")" (;) ";" (return_statement) "return lines;" (return) "return" (identifier) "lines" (;) ";" (}) "}" (function_definition) "void freeLines(char **lines){ \n int i = 0; \n \n while(lines[i] != NULL){ \n free(lines[i++]); \n } \n \n free(lines); \n}" (primitive_type) "void" (function_declarator) "freeLines(char **lines)" (identifier) "freeLines" (parameter_list) "(char **lines)" (() "(" (parameter_declaration) "char **lines" (primitive_type) "char" (pointer_declarator) "**lines" (*) "*" (pointer_declarator) "*lines" (*) "*" (identifier) "lines" ()) ")" (compound_statement) "{ \n int i = 0; \n \n while(lines[i] != NULL){ \n free(lines[i++]); \n } \n \n free(lines); \n}" ({) "{" (declaration) "int i = 0;" (primitive_type) "int" (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (while_statement) "while(lines[i] != NULL){ \n free(lines[i++]); \n }" (while) "while" (parenthesized_expression) "(lines[i] != NULL)" (() "(" (binary_expression) "lines[i] != NULL" (subscript_expression) "lines[i]" (identifier) "lines" ([) "[" (identifier) "i" (]) "]" (!=) "!=" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{ \n free(lines[i++]); \n }" ({) "{" (expression_statement) "free(lines[i++]);" (call_expression) "free(lines[i++])" (identifier) "free" (argument_list) "(lines[i++])" (() "(" (subscript_expression) "lines[i++]" (identifier) "lines" ([) "[" (update_expression) "i++" (identifier) "i" (++) "++" (]) "]" ()) ")" (;) ";" (}) "}" (expression_statement) "free(lines);" (call_expression) "free(lines)" (identifier) "free" (argument_list) "(lines)" (() "(" (identifier) "lines" ()) ")" (;) ";" (}) "}" (function_definition) "char *formatStr(char *old){ \n char *str = malloc(sizeof(char) * strlen(old) + 1); \n int i, j, start, end, newpos; \n bool notFirstWord = false; \n \n i = 0; \n newpos = 0; \n while(old[i] != 0){ \n int start = getNextNonWhitespace(old, i); \n int end = getNextWhitespace(old, start); \n \n if(isCapital(old[start])){ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n } \n \n i = end; \n } \n \n i = 0; \n while(old[i] != 0){ \n int start = getNextNonWhitespace(old, i); \n int end = getNextWhitespace(old, start); \n \n if(!isCapital(old[start])){ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n } \n \n i = end; \n } \n \n str[newpos] = 0; \n \n free(old); \n return str; \n}" (primitive_type) "char" (pointer_declarator) "*formatStr(char *old)" (*) "*" (function_declarator) "formatStr(char *old)" (identifier) "formatStr" (parameter_list) "(char *old)" (() "(" (parameter_declaration) "char *old" (primitive_type) "char" (pointer_declarator) "*old" (*) "*" (identifier) "old" ()) ")" (compound_statement) "{ \n char *str = malloc(sizeof(char) * strlen(old) + 1); \n int i, j, start, end, newpos; \n bool notFirstWord = false; \n \n i = 0; \n newpos = 0; \n while(old[i] != 0){ \n int start = getNextNonWhitespace(old, i); \n int end = getNextWhitespace(old, start); \n \n if(isCapital(old[start])){ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n } \n \n i = end; \n } \n \n i = 0; \n while(old[i] != 0){ \n int start = getNextNonWhitespace(old, i); \n int end = getNextWhitespace(old, start); \n \n if(!isCapital(old[start])){ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n } \n \n i = end; \n } \n \n str[newpos] = 0; \n \n free(old); \n return str; \n}" ({) "{" (declaration) "char *str = malloc(sizeof(char) * strlen(old) + 1);" (primitive_type) "char" (init_declarator) "*str = malloc(sizeof(char) * strlen(old) + 1)" (pointer_declarator) "*str" (*) "*" (identifier) "str" (=) "=" (call_expression) "malloc(sizeof(char) * strlen(old) + 1)" (identifier) "malloc" (argument_list) "(sizeof(char) * strlen(old) + 1)" (() "(" (binary_expression) "sizeof(char) * strlen(old) + 1" (binary_expression) "sizeof(char) * strlen(old)" (sizeof_expression) "sizeof(char)" (sizeof) "sizeof" (() "(" (type_descriptor) "char" (primitive_type) "char" ()) ")" (*) "*" (call_expression) "strlen(old)" (identifier) "strlen" (argument_list) "(old)" (() "(" (identifier) "old" ()) ")" (+) "+" (number_literal) "1" ()) ")" (;) ";" (declaration) "int i, j, start, end, newpos;" (primitive_type) "int" (identifier) "i" (,) "," (identifier) "j" (,) "," (identifier) "start" (,) "," (identifier) "end" (,) "," (identifier) "newpos" (;) ";" (declaration) "bool notFirstWord = false;" (primitive_type) "bool" (init_declarator) "notFirstWord = false" (identifier) "notFirstWord" (=) "=" (false) "false" (;) ";" (expression_statement) "i = 0;" (assignment_expression) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "newpos = 0;" (assignment_expression) "newpos = 0" (identifier) "newpos" (=) "=" (number_literal) "0" (;) ";" (while_statement) "while(old[i] != 0){ \n int start = getNextNonWhitespace(old, i); \n int end = getNextWhitespace(old, start); \n \n if(isCapital(old[start])){ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n } \n \n i = end; \n }" (while) "while" (parenthesized_expression) "(old[i] != 0)" (() "(" (binary_expression) "old[i] != 0" (subscript_expression) "old[i]" (identifier) "old" ([) "[" (identifier) "i" (]) "]" (!=) "!=" (number_literal) "0" ()) ")" (compound_statement) "{ \n int start = getNextNonWhitespace(old, i); \n int end = getNextWhitespace(old, start); \n \n if(isCapital(old[start])){ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n } \n \n i = end; \n }" ({) "{" (declaration) "int start = getNextNonWhitespace(old, i);" (primitive_type) "int" (init_declarator) "start = getNextNonWhitespace(old, i)" (identifier) "start" (=) "=" (call_expression) "getNextNonWhitespace(old, i)" (identifier) "getNextNonWhitespace" (argument_list) "(old, i)" (() "(" (identifier) "old" (,) "," (identifier) "i" ()) ")" (;) ";" (declaration) "int end = getNextWhitespace(old, start);" (primitive_type) "int" (init_declarator) "end = getNextWhitespace(old, start)" (identifier) "end" (=) "=" (call_expression) "getNextWhitespace(old, start)" (identifier) "getNextWhitespace" (argument_list) "(old, start)" (() "(" (identifier) "old" (,) "," (identifier) "start" ()) ")" (;) ";" (if_statement) "if(isCapital(old[start])){ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n }" (if) "if" (parenthesized_expression) "(isCapital(old[start]))" (() "(" (call_expression) "isCapital(old[start])" (identifier) "isCapital" (argument_list) "(old[start])" (() "(" (subscript_expression) "old[start]" (identifier) "old" ([) "[" (identifier) "start" (]) "]" ()) ")" ()) ")" (compound_statement) "{ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n }" ({) "{" (if_statement) "if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n }" (if) "if" (parenthesized_expression) "(notFirstWord)" (() "(" (identifier) "notFirstWord" ()) ")" (compound_statement) "{ \n str[newpos++] = ' '; \n }" ({) "{" (expression_statement) "str[newpos++] = ' ';" (assignment_expression) "str[newpos++] = ' '" (subscript_expression) "str[newpos++]" (identifier) "str" ([) "[" (update_expression) "newpos++" (identifier) "newpos" (++) "++" (]) "]" (=) "=" (char_literal) "' '" (') "'" (character) " " (') "'" (;) ";" (}) "}" (else_clause) "else{ \n notFirstWord = true; \n }" (else) "else" (compound_statement) "{ \n notFirstWord = true; \n }" ({) "{" (expression_statement) "notFirstWord = true;" (assignment_expression) "notFirstWord = true" (identifier) "notFirstWord" (=) "=" (true) "true" (;) ";" (}) "}" (for_statement) "for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n }" (for) "for" (() "(" (assignment_expression) "j = start" (identifier) "j" (=) "=" (identifier) "start" (;) ";" (binary_expression) "j < end" (identifier) "j" (<) "<" (identifier) "end" (;) ";" (update_expression) "j++" (identifier) "j" (++) "++" ()) ")" (compound_statement) "{ \n str[newpos++] = old[j]; \n }" ({) "{" (expression_statement) "str[newpos++] = old[j];" (assignment_expression) "str[newpos++] = old[j]" (subscript_expression) "str[newpos++]" (identifier) "str" ([) "[" (update_expression) "newpos++" (identifier) "newpos" (++) "++" (]) "]" (=) "=" (subscript_expression) "old[j]" (identifier) "old" ([) "[" (identifier) "j" (]) "]" (;) ";" (}) "}" (}) "}" (expression_statement) "i = end;" (assignment_expression) "i = end" (identifier) "i" (=) "=" (identifier) "end" (;) ";" (}) "}" (expression_statement) "i = 0;" (assignment_expression) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (while_statement) "while(old[i] != 0){ \n int start = getNextNonWhitespace(old, i); \n int end = getNextWhitespace(old, start); \n \n if(!isCapital(old[start])){ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n } \n \n i = end; \n }" (while) "while" (parenthesized_expression) "(old[i] != 0)" (() "(" (binary_expression) "old[i] != 0" (subscript_expression) "old[i]" (identifier) "old" ([) "[" (identifier) "i" (]) "]" (!=) "!=" (number_literal) "0" ()) ")" (compound_statement) "{ \n int start = getNextNonWhitespace(old, i); \n int end = getNextWhitespace(old, start); \n \n if(!isCapital(old[start])){ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n } \n \n i = end; \n }" ({) "{" (declaration) "int start = getNextNonWhitespace(old, i);" (primitive_type) "int" (init_declarator) "start = getNextNonWhitespace(old, i)" (identifier) "start" (=) "=" (call_expression) "getNextNonWhitespace(old, i)" (identifier) "getNextNonWhitespace" (argument_list) "(old, i)" (() "(" (identifier) "old" (,) "," (identifier) "i" ()) ")" (;) ";" (declaration) "int end = getNextWhitespace(old, start);" (primitive_type) "int" (init_declarator) "end = getNextWhitespace(old, start)" (identifier) "end" (=) "=" (call_expression) "getNextWhitespace(old, start)" (identifier) "getNextWhitespace" (argument_list) "(old, start)" (() "(" (identifier) "old" (,) "," (identifier) "start" ()) ")" (;) ";" (if_statement) "if(!isCapital(old[start])){ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n }" (if) "if" (parenthesized_expression) "(!isCapital(old[start]))" (() "(" (unary_expression) "!isCapital(old[start])" (!) "!" (call_expression) "isCapital(old[start])" (identifier) "isCapital" (argument_list) "(old[start])" (() "(" (subscript_expression) "old[start]" (identifier) "old" ([) "[" (identifier) "start" (]) "]" ()) ")" ()) ")" (compound_statement) "{ \n \n if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n } \n \n for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n } \n }" ({) "{" (if_statement) "if(notFirstWord){ \n str[newpos++] = ' '; \n }else{ \n notFirstWord = true; \n }" (if) "if" (parenthesized_expression) "(notFirstWord)" (() "(" (identifier) "notFirstWord" ()) ")" (compound_statement) "{ \n str[newpos++] = ' '; \n }" ({) "{" (expression_statement) "str[newpos++] = ' ';" (assignment_expression) "str[newpos++] = ' '" (subscript_expression) "str[newpos++]" (identifier) "str" ([) "[" (update_expression) "newpos++" (identifier) "newpos" (++) "++" (]) "]" (=) "=" (char_literal) "' '" (') "'" (character) " " (') "'" (;) ";" (}) "}" (else_clause) "else{ \n notFirstWord = true; \n }" (else) "else" (compound_statement) "{ \n notFirstWord = true; \n }" ({) "{" (expression_statement) "notFirstWord = true;" (assignment_expression) "notFirstWord = true" (identifier) "notFirstWord" (=) "=" (true) "true" (;) ";" (}) "}" (for_statement) "for(j = start; j < end; j++){ \n str[newpos++] = old[j]; \n }" (for) "for" (() "(" (assignment_expression) "j = start" (identifier) "j" (=) "=" (identifier) "start" (;) ";" (binary_expression) "j < end" (identifier) "j" (<) "<" (identifier) "end" (;) ";" (update_expression) "j++" (identifier) "j" (++) "++" ()) ")" (compound_statement) "{ \n str[newpos++] = old[j]; \n }" ({) "{" (expression_statement) "str[newpos++] = old[j];" (assignment_expression) "str[newpos++] = old[j]" (subscript_expression) "str[newpos++]" (identifier) "str" ([) "[" (update_expression) "newpos++" (identifier) "newpos" (++) "++" (]) "]" (=) "=" (subscript_expression) "old[j]" (identifier) "old" ([) "[" (identifier) "j" (]) "]" (;) ";" (}) "}" (}) "}" (expression_statement) "i = end;" (assignment_expression) "i = end" (identifier) "i" (=) "=" (identifier) "end" (;) ";" (}) "}" (expression_statement) "str[newpos] = 0;" (assignment_expression) "str[newpos] = 0" (subscript_expression) "str[newpos]" (identifier) "str" ([) "[" (identifier) "newpos" (]) "]" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "free(old);" (call_expression) "free(old)" (identifier) "free" (argument_list) "(old)" (() "(" (identifier) "old" ()) ")" (;) ";" (return_statement) "return str;" (return) "return" (identifier) "str" (;) ";" (}) "}" (function_definition) "void format(char **lines){ \n int i = 0; \n \n while(lines[i] != NULL){ \n lines[i] = formatStr(lines[i]); \n i++; \n } \n}" (primitive_type) "void" (function_declarator) "format(char **lines)" (identifier) "format" (parameter_list) "(char **lines)" (() "(" (parameter_declaration) "char **lines" (primitive_type) "char" (pointer_declarator) "**lines" (*) "*" (pointer_declarator) "*lines" (*) "*" (identifier) "lines" ()) ")" (compound_statement) "{ \n int i = 0; \n \n while(lines[i] != NULL){ \n lines[i] = formatStr(lines[i]); \n i++; \n } \n}" ({) "{" (declaration) "int i = 0;" (primitive_type) "int" (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (while_statement) "while(lines[i] != NULL){ \n lines[i] = formatStr(lines[i]); \n i++; \n }" (while) "while" (parenthesized_expression) "(lines[i] != NULL)" (() "(" (binary_expression) "lines[i] != NULL" (subscript_expression) "lines[i]" (identifier) "lines" ([) "[" (identifier) "i" (]) "]" (!=) "!=" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{ \n lines[i] = formatStr(lines[i]); \n i++; \n }" ({) "{" (expression_statement) "lines[i] = formatStr(lines[i]);" (assignment_expression) "lines[i] = formatStr(lines[i])" (subscript_expression) "lines[i]" (identifier) "lines" ([) "[" (identifier) "i" (]) "]" (=) "=" (call_expression) "formatStr(lines[i])" (identifier) "formatStr" (argument_list) "(lines[i])" (() "(" (subscript_expression) "lines[i]" (identifier) "lines" ([) "[" (identifier) "i" (]) "]" ()) ")" (;) ";" (expression_statement) "i++;" (update_expression) "i++" (identifier) "i" (++) "++" (;) ";" (}) "}" (}) "}" (function_definition) "void printStr(char *str){ \n char c = 0; \n while(c = *(str++)){ \n putc(c, stdout); \n \n if(c == '.'){ \n printf("\n\t"); \n } \n } \n putc('\n', stdout); \n}" (primitive_type) "void" (function_declarator) "printStr(char *str)" (identifier) "printStr" (parameter_list) "(char *str)" (() "(" (parameter_declaration) "char *str" (primitive_type) "char" (pointer_declarator) "*str" (*) "*" (identifier) "str" ()) ")" (compound_statement) "{ \n char c = 0; \n while(c = *(str++)){ \n putc(c, stdout); \n \n if(c == '.'){ \n printf("\n\t"); \n } \n } \n putc('\n', stdout); \n}" ({) "{" (declaration) "char c = 0;" (primitive_type) "char" (init_declarator) "c = 0" (identifier) "c" (=) "=" (number_literal) "0" (;) ";" (while_statement) "while(c = *(str++)){ \n putc(c, stdout); \n \n if(c == '.'){ \n printf("\n\t"); \n } \n }" (while) "while" (parenthesized_expression) "(c = *(str++))" (() "(" (assignment_expression) "c = *(str++)" (identifier) "c" (=) "=" (pointer_expression) "*(str++)" (*) "*" (parenthesized_expression) "(str++)" (() "(" (update_expression) "str++" (identifier) "str" (++) "++" ()) ")" ()) ")" (compound_statement) "{ \n putc(c, stdout); \n \n if(c == '.'){ \n printf("\n\t"); \n } \n }" ({) "{" (expression_statement) "putc(c, stdout);" (call_expression) "putc(c, stdout)" (identifier) "putc" (argument_list) "(c, stdout)" (() "(" (identifier) "c" (,) "," (identifier) "stdout" ()) ")" (;) ";" (if_statement) "if(c == '.'){ \n printf("\n\t"); \n }" (if) "if" (parenthesized_expression) "(c == '.')" (() "(" (binary_expression) "c == '.'" (identifier) "c" (==) "==" (char_literal) "'.'" (') "'" (character) "." (') "'" ()) ")" (compound_statement) "{ \n printf("\n\t"); \n }" ({) "{" (expression_statement) "printf("\n\t");" (call_expression) "printf("\n\t")" (identifier) "printf" (argument_list) "("\n\t")" (() "(" (string_literal) ""\n\t"" (") """ (escape_sequence) "\n" (escape_sequence) "\t" (") """ ()) ")" (;) ";" (}) "}" (}) "}" (expression_statement) "putc('\n', stdout);" (call_expression) "putc('\n', stdout)" (identifier) "putc" (argument_list) "('\n', stdout)" (() "(" (char_literal) "'\n'" (') "'" (escape_sequence) "\n" (') "'" (,) "," (identifier) "stdout" ()) ")" (;) ";" (}) "}" (function_definition) "void printFormat(char **lines){ \n int i = 0; \n while(lines[i] != NULL){ \n printStr(lines[i]); \n i++; \n } \n}" (primitive_type) "void" (function_declarator) "printFormat(char **lines)" (identifier) "printFormat" (parameter_list) "(char **lines)" (() "(" (parameter_declaration) "char **lines" (primitive_type) "char" (pointer_declarator) "**lines" (*) "*" (pointer_declarator) "*lines" (*) "*" (identifier) "lines" ()) ")" (compound_statement) "{ \n int i = 0; \n while(lines[i] != NULL){ \n printStr(lines[i]); \n i++; \n } \n}" ({) "{" (declaration) "int i = 0;" (primitive_type) "int" (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (while_statement) "while(lines[i] != NULL){ \n printStr(lines[i]); \n i++; \n }" (while) "while" (parenthesized_expression) "(lines[i] != NULL)" (() "(" (binary_expression) "lines[i] != NULL" (subscript_expression) "lines[i]" (identifier) "lines" ([) "[" (identifier) "i" (]) "]" (!=) "!=" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{ \n printStr(lines[i]); \n i++; \n }" ({) "{" (expression_statement) "printStr(lines[i]);" (call_expression) "printStr(lines[i])" (identifier) "printStr" (argument_list) "(lines[i])" (() "(" (subscript_expression) "lines[i]" (identifier) "lines" ([) "[" (identifier) "i" (]) "]" ()) ")" (;) ";" (expression_statement) "i++;" (update_expression) "i++" (identifier) "i" (++) "++" (;) ";" (}) "}" (}) "}" (function_definition) "int main(){ \n char **lines = NULL; \n int size = 0; \n char c = 0; \n int i = 0, j, k; \n \n lines = readLines(); \n \n format(lines); \n \n printFormat(lines); \n \n freeLines(lines); \n \n return 0; \n}" (primitive_type) "int" (function_declarator) "main()" (identifier) "main" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{ \n char **lines = NULL; \n int size = 0; \n char c = 0; \n int i = 0, j, k; \n \n lines = readLines(); \n \n format(lines); \n \n printFormat(lines); \n \n freeLines(lines); \n \n return 0; \n}" ({) "{" (declaration) "char **lines = NULL;" (primitive_type) "char" (init_declarator) "**lines = NULL" (pointer_declarator) "**lines" (*) "*" (pointer_declarator) "*lines" (*) "*" (identifier) "lines" (=) "=" (null) "NULL" (NULL) "NULL" (;) ";" (declaration) "int size = 0;" (primitive_type) "int" (init_declarator) "size = 0" (identifier) "size" (=) "=" (number_literal) "0" (;) ";" (declaration) "char c = 0;" (primitive_type) "char" (init_declarator) "c = 0" (identifier) "c" (=) "=" (number_literal) "0" (;) ";" (declaration) "int i = 0, j, k;" (primitive_type) "int" (init_declarator) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (,) "," (identifier) "j" (,) "," (identifier) "k" (;) ";" (expression_statement) "lines = readLines();" (assignment_expression) "lines = readLines()" (identifier) "lines" (=) "=" (call_expression) "readLines()" (identifier) "readLines" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "format(lines);" (call_expression) "format(lines)" (identifier) "format" (argument_list) "(lines)" (() "(" (identifier) "lines" ()) ")" (;) ";" (expression_statement) "printFormat(lines);" (call_expression) "printFormat(lines)" (identifier) "printFormat" (argument_list) "(lines)" (() "(" (identifier) "lines" ()) ")" (;) ";" (expression_statement) "freeLines(lines);" (call_expression) "freeLines(lines)" (identifier) "freeLines" (argument_list) "(lines)" (() "(" (identifier) "lines" ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}"
1,636
0
{"language": "c", "success": true, "metadata": {"lines": 222, "avg_line_length": 18.83, "nodes": 1037, "errors": 0, "source_hash": "6322709a609cfd9e0613bdd448d363f411c654dfa45f8043e93bd919624a4965", "categorized_nodes": 639}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <stdio.h>\r\n", "parent": null, "children": [1, 2], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<stdio.h>", "parent": 0, "children": [], "start_point": {"row": 1, "column": 9}, "end_point": {"row": 1, "column": 18}}, {"id": 3, "type": "preproc_include", "text": "#include <stdbool.h>\r\n", "parent": null, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<stdbool.h>", "parent": 3, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 20}}, {"id": 6, "type": "preproc_include", "text": "#include <stdlib.h>\r\n", "parent": null, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<stdlib.h>", "parent": 6, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 19}}, {"id": 9, "type": "preproc_include", "text": "#include <string.h>\r\n", "parent": null, "children": [10, 11], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<string.h>", "parent": 9, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 19}}, {"id": 12, "type": "function_definition", "text": "bool isAWhitespace(char c){\r\n return c == ' ' || c == '\\t' || c == '\\n';\r\n}", "parent": null, "children": [13, 14], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 8, "column": 1}}, {"id": 13, "type": "primitive_type", "text": "bool", "parent": 12, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 4}}, {"id": 14, "type": "function_declarator", "text": "isAWhitespace(char c)", "parent": 12, "children": [15, 16], "start_point": {"row": 6, "column": 5}, "end_point": {"row": 6, "column": 26}}, {"id": 15, "type": "identifier", "text": "isAWhitespace", "parent": 14, "children": [], "start_point": {"row": 6, "column": 5}, "end_point": {"row": 6, "column": 18}}, {"id": 16, "type": "parameter_list", "text": "(char c)", "parent": 14, "children": [17], "start_point": {"row": 6, "column": 18}, "end_point": {"row": 6, "column": 26}}, {"id": 17, "type": "parameter_declaration", "text": "char c", "parent": 16, "children": [18, 19], "start_point": {"row": 6, "column": 19}, "end_point": {"row": 6, "column": 25}}, {"id": 18, "type": "primitive_type", "text": "char", "parent": 17, "children": [], "start_point": {"row": 6, "column": 19}, "end_point": {"row": 6, "column": 23}}, {"id": 19, "type": "identifier", "text": "c", "parent": 17, "children": [], "start_point": {"row": 6, "column": 24}, "end_point": {"row": 6, "column": 25}}, {"id": 20, "type": "return_statement", "text": "return c == ' ' || c == '\\t' || c == '\\n';", "parent": 12, "children": [21], "start_point": {"row": 7, "column": 4}, "end_point": {"row": 7, "column": 46}}, {"id": 21, "type": "binary_expression", "text": "c == ' ' || c == '\\t' || c == '\\n'", "parent": 20, "children": [22, 38, 39], "start_point": {"row": 7, "column": 11}, "end_point": {"row": 7, "column": 45}}, {"id": 22, "type": "binary_expression", "text": "c == ' ' || c == '\\t'", "parent": 21, "children": [23, 30, 31], "start_point": {"row": 7, "column": 11}, "end_point": {"row": 7, "column": 32}}, {"id": 23, "type": "binary_expression", "text": "c == ' '", "parent": 22, "children": [24, 25, 26], "start_point": {"row": 7, "column": 11}, "end_point": {"row": 7, "column": 19}}, {"id": 24, "type": "identifier", "text": "c", "parent": 23, "children": [], "start_point": {"row": 7, "column": 11}, "end_point": {"row": 7, "column": 12}}, {"id": 25, "type": "==", "text": "==", "parent": 23, "children": [], "start_point": {"row": 7, "column": 13}, "end_point": {"row": 7, "column": 15}}, {"id": 26, "type": "char_literal", "text": "' '", "parent": 23, "children": [27, 28, 29], "start_point": {"row": 7, "column": 16}, "end_point": {"row": 7, "column": 19}}, {"id": 27, "type": "'", "text": "'", "parent": 26, "children": [], "start_point": {"row": 7, "column": 16}, "end_point": {"row": 7, "column": 17}}, {"id": 28, "type": "character", "text": " ", "parent": 26, "children": [], "start_point": {"row": 7, "column": 17}, "end_point": {"row": 7, "column": 18}}, {"id": 29, "type": "'", "text": "'", "parent": 26, "children": [], "start_point": {"row": 7, "column": 18}, "end_point": {"row": 7, "column": 19}}, {"id": 30, "type": "||", "text": "||", "parent": 22, "children": [], "start_point": {"row": 7, "column": 20}, "end_point": {"row": 7, "column": 22}}, {"id": 31, "type": "binary_expression", "text": "c == '\\t'", "parent": 22, "children": [32, 33, 34], "start_point": {"row": 7, "column": 23}, "end_point": {"row": 7, "column": 32}}, {"id": 32, "type": "identifier", "text": "c", "parent": 31, "children": [], "start_point": {"row": 7, "column": 23}, "end_point": {"row": 7, "column": 24}}, {"id": 33, "type": "==", "text": "==", "parent": 31, "children": [], "start_point": {"row": 7, "column": 25}, "end_point": {"row": 7, "column": 27}}, {"id": 34, "type": "char_literal", "text": "'\\t'", "parent": 31, "children": [35, 36, 37], "start_point": {"row": 7, "column": 28}, "end_point": {"row": 7, "column": 32}}, {"id": 35, "type": "'", "text": "'", "parent": 34, "children": [], "start_point": {"row": 7, "column": 28}, "end_point": {"row": 7, "column": 29}}, {"id": 36, "type": "escape_sequence", "text": "\\t", "parent": 34, "children": [], "start_point": {"row": 7, "column": 29}, "end_point": {"row": 7, "column": 31}}, {"id": 37, "type": "'", "text": "'", "parent": 34, "children": [], "start_point": {"row": 7, "column": 31}, "end_point": {"row": 7, "column": 32}}, {"id": 38, "type": "||", "text": "||", "parent": 21, "children": [], "start_point": {"row": 7, "column": 33}, "end_point": {"row": 7, "column": 35}}, {"id": 39, "type": "binary_expression", "text": "c == '\\n'", "parent": 21, "children": [40, 41, 42], "start_point": {"row": 7, "column": 36}, "end_point": {"row": 7, "column": 45}}, {"id": 40, "type": "identifier", "text": "c", "parent": 39, "children": [], "start_point": {"row": 7, "column": 36}, "end_point": {"row": 7, "column": 37}}, {"id": 41, "type": "==", "text": "==", "parent": 39, "children": [], "start_point": {"row": 7, "column": 38}, "end_point": {"row": 7, "column": 40}}, {"id": 42, "type": "char_literal", "text": "'\\n'", "parent": 39, "children": [43, 44, 45], "start_point": {"row": 7, "column": 41}, "end_point": {"row": 7, "column": 45}}, {"id": 43, "type": "'", "text": "'", "parent": 42, "children": [], "start_point": {"row": 7, "column": 41}, "end_point": {"row": 7, "column": 42}}, {"id": 44, "type": "escape_sequence", "text": "\\n", "parent": 42, "children": [], "start_point": {"row": 7, "column": 42}, "end_point": {"row": 7, "column": 44}}, {"id": 45, "type": "'", "text": "'", "parent": 42, "children": [], "start_point": {"row": 7, "column": 44}, "end_point": {"row": 7, "column": 45}}, {"id": 46, "type": "function_definition", "text": "bool isCapital(char c){\r\n if(c >= 'A' && c <= 'Z') return true;\r\n return false;\r\n}", "parent": null, "children": [47, 48], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 13, "column": 1}}, {"id": 47, "type": "primitive_type", "text": "bool", "parent": 46, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 4}}, {"id": 48, "type": "function_declarator", "text": "isCapital(char c)", "parent": 46, "children": [49, 50], "start_point": {"row": 10, "column": 5}, "end_point": {"row": 10, "column": 22}}, {"id": 49, "type": "identifier", "text": "isCapital", "parent": 48, "children": [], "start_point": {"row": 10, "column": 5}, "end_point": {"row": 10, "column": 14}}, {"id": 50, "type": "parameter_list", "text": "(char c)", "parent": 48, "children": [51], "start_point": {"row": 10, "column": 14}, "end_point": {"row": 10, "column": 22}}, {"id": 51, "type": "parameter_declaration", "text": "char c", "parent": 50, "children": [52, 53], "start_point": {"row": 10, "column": 15}, "end_point": {"row": 10, "column": 21}}, {"id": 52, "type": "primitive_type", "text": "char", "parent": 51, "children": [], "start_point": {"row": 10, "column": 15}, "end_point": {"row": 10, "column": 19}}, {"id": 53, "type": "identifier", "text": "c", "parent": 51, "children": [], "start_point": {"row": 10, "column": 20}, "end_point": {"row": 10, "column": 21}}, {"id": 54, "type": "if_statement", "text": "if(c >= 'A' && c <= 'Z') return true;", "parent": 46, "children": [55, 72], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 41}}, {"id": 55, "type": "parenthesized_expression", "text": "(c >= 'A' && c <= 'Z')", "parent": 54, "children": [56], "start_point": {"row": 11, "column": 6}, "end_point": {"row": 11, "column": 28}}, {"id": 56, "type": "binary_expression", "text": "c >= 'A' && c <= 'Z'", "parent": 55, "children": [57, 64, 65], "start_point": {"row": 11, "column": 7}, "end_point": {"row": 11, "column": 27}}, {"id": 57, "type": "binary_expression", "text": "c >= 'A'", "parent": 56, "children": [58, 59, 60], "start_point": {"row": 11, "column": 7}, "end_point": {"row": 11, "column": 15}}, {"id": 58, "type": "identifier", "text": "c", "parent": 57, "children": [], "start_point": {"row": 11, "column": 7}, "end_point": {"row": 11, "column": 8}}, {"id": 59, "type": ">=", "text": ">=", "parent": 57, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 11}}, {"id": 60, "type": "char_literal", "text": "'A'", "parent": 57, "children": [61, 62, 63], "start_point": {"row": 11, "column": 12}, "end_point": {"row": 11, "column": 15}}, {"id": 61, "type": "'", "text": "'", "parent": 60, "children": [], "start_point": {"row": 11, "column": 12}, "end_point": {"row": 11, "column": 13}}, {"id": 62, "type": "character", "text": "A", "parent": 60, "children": [], "start_point": {"row": 11, "column": 13}, "end_point": {"row": 11, "column": 14}}, {"id": 63, "type": "'", "text": "'", "parent": 60, "children": [], "start_point": {"row": 11, "column": 14}, "end_point": {"row": 11, "column": 15}}, {"id": 64, "type": "&&", "text": "&&", "parent": 56, "children": [], "start_point": {"row": 11, "column": 16}, "end_point": {"row": 11, "column": 18}}, {"id": 65, "type": "binary_expression", "text": "c <= 'Z'", "parent": 56, "children": [66, 67, 68], "start_point": {"row": 11, "column": 19}, "end_point": {"row": 11, "column": 27}}, {"id": 66, "type": "identifier", "text": "c", "parent": 65, "children": [], "start_point": {"row": 11, "column": 19}, "end_point": {"row": 11, "column": 20}}, {"id": 67, "type": "<=", "text": "<=", "parent": 65, "children": [], "start_point": {"row": 11, "column": 21}, "end_point": {"row": 11, "column": 23}}, {"id": 68, "type": "char_literal", "text": "'Z'", "parent": 65, "children": [69, 70, 71], "start_point": {"row": 11, "column": 24}, "end_point": {"row": 11, "column": 27}}, {"id": 69, "type": "'", "text": "'", "parent": 68, "children": [], "start_point": {"row": 11, "column": 24}, "end_point": {"row": 11, "column": 25}}, {"id": 70, "type": "character", "text": "Z", "parent": 68, "children": [], "start_point": {"row": 11, "column": 25}, "end_point": {"row": 11, "column": 26}}, {"id": 71, "type": "'", "text": "'", "parent": 68, "children": [], "start_point": {"row": 11, "column": 26}, "end_point": {"row": 11, "column": 27}}, {"id": 72, "type": "return_statement", "text": "return true;", "parent": 54, "children": [73], "start_point": {"row": 11, "column": 29}, "end_point": {"row": 11, "column": 41}}, {"id": 73, "type": "true", "text": "true", "parent": 72, "children": [], "start_point": {"row": 11, "column": 36}, "end_point": {"row": 11, "column": 40}}, {"id": 74, "type": "return_statement", "text": "return false;", "parent": 46, "children": [75], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 17}}, {"id": 75, "type": "false", "text": "false", "parent": 74, "children": [], "start_point": {"row": 12, "column": 11}, "end_point": {"row": 12, "column": 16}}, {"id": 76, "type": "function_definition", "text": "int getNextNonWhitespace(char *str, int index){\r\n int i = index;\r\n while(isAWhitespace(str[i]) && str[i] != 0) i++;\r\n return i;\r\n}", "parent": null, "children": [77, 78], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 19, "column": 1}}, {"id": 77, "type": "primitive_type", "text": "int", "parent": 76, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 3}}, {"id": 78, "type": "function_declarator", "text": "getNextNonWhitespace(char *str, int index)", "parent": 76, "children": [79, 80], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 46}}, {"id": 79, "type": "identifier", "text": "getNextNonWhitespace", "parent": 78, "children": [], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 24}}, {"id": 80, "type": "parameter_list", "text": "(char *str, int index)", "parent": 78, "children": [81, 86], "start_point": {"row": 15, "column": 24}, "end_point": {"row": 15, "column": 46}}, {"id": 81, "type": "parameter_declaration", "text": "char *str", "parent": 80, "children": [82, 83], "start_point": {"row": 15, "column": 25}, "end_point": {"row": 15, "column": 34}}, {"id": 82, "type": "primitive_type", "text": "char", "parent": 81, "children": [], "start_point": {"row": 15, "column": 25}, "end_point": {"row": 15, "column": 29}}, {"id": 83, "type": "pointer_declarator", "text": "*str", "parent": 81, "children": [84, 85], "start_point": {"row": 15, "column": 30}, "end_point": {"row": 15, "column": 34}}, {"id": 84, "type": "*", "text": "*", "parent": 83, "children": [], "start_point": {"row": 15, "column": 30}, "end_point": {"row": 15, "column": 31}}, {"id": 85, "type": "identifier", "text": "str", "parent": 83, "children": [], "start_point": {"row": 15, "column": 31}, "end_point": {"row": 15, "column": 34}}, {"id": 86, "type": "parameter_declaration", "text": "int index", "parent": 80, "children": [87, 88], "start_point": {"row": 15, "column": 36}, "end_point": {"row": 15, "column": 45}}, {"id": 87, "type": "primitive_type", "text": "int", "parent": 86, "children": [], "start_point": {"row": 15, "column": 36}, "end_point": {"row": 15, "column": 39}}, {"id": 88, "type": "identifier", "text": "index", "parent": 86, "children": [], "start_point": {"row": 15, "column": 40}, "end_point": {"row": 15, "column": 45}}, {"id": 89, "type": "declaration", "text": "int i = index;", "parent": 76, "children": [90, 91], "start_point": {"row": 16, "column": 4}, "end_point": {"row": 16, "column": 18}}, {"id": 90, "type": "primitive_type", "text": "int", "parent": 89, "children": [], "start_point": {"row": 16, "column": 4}, "end_point": {"row": 16, "column": 7}}, {"id": 91, "type": "init_declarator", "text": "i = index", "parent": 89, "children": [92, 93, 94], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 17}}, {"id": 92, "type": "identifier", "text": "i", "parent": 91, "children": [], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 9}}, {"id": 93, "type": "=", "text": "=", "parent": 91, "children": [], "start_point": {"row": 16, "column": 10}, "end_point": {"row": 16, "column": 11}}, {"id": 94, "type": "identifier", "text": "index", "parent": 91, "children": [], "start_point": {"row": 16, "column": 12}, "end_point": {"row": 16, "column": 17}}, {"id": 95, "type": "while_statement", "text": "while(isAWhitespace(str[i]) && str[i] != 0) i++;", "parent": 76, "children": [96], "start_point": {"row": 17, "column": 4}, "end_point": {"row": 17, "column": 52}}, {"id": 96, "type": "parenthesized_expression", "text": "(isAWhitespace(str[i]) && str[i] != 0)", "parent": 95, "children": [97], "start_point": {"row": 17, "column": 9}, "end_point": {"row": 17, "column": 47}}, {"id": 97, "type": "binary_expression", "text": "isAWhitespace(str[i]) && str[i] != 0", "parent": 96, "children": [98, 104, 105], "start_point": {"row": 17, "column": 10}, "end_point": {"row": 17, "column": 46}}, {"id": 98, "type": "call_expression", "text": "isAWhitespace(str[i])", "parent": 97, "children": [99, 100], "start_point": {"row": 17, "column": 10}, "end_point": {"row": 17, "column": 31}}, {"id": 99, "type": "identifier", "text": "isAWhitespace", "parent": 98, "children": [], "start_point": {"row": 17, "column": 10}, "end_point": {"row": 17, "column": 23}}, {"id": 100, "type": "argument_list", "text": "(str[i])", "parent": 98, "children": [101], "start_point": {"row": 17, "column": 23}, "end_point": {"row": 17, "column": 31}}, {"id": 101, "type": "subscript_expression", "text": "str[i]", "parent": 100, "children": [102, 103], "start_point": {"row": 17, "column": 24}, "end_point": {"row": 17, "column": 30}}, {"id": 102, "type": "identifier", "text": "str", "parent": 101, "children": [], "start_point": {"row": 17, "column": 24}, "end_point": {"row": 17, "column": 27}}, {"id": 103, "type": "identifier", "text": "i", "parent": 101, "children": [], "start_point": {"row": 17, "column": 28}, "end_point": {"row": 17, "column": 29}}, {"id": 104, "type": "&&", "text": "&&", "parent": 97, "children": [], "start_point": {"row": 17, "column": 32}, "end_point": {"row": 17, "column": 34}}, {"id": 105, "type": "binary_expression", "text": "str[i] != 0", "parent": 97, "children": [106, 109, 110], "start_point": {"row": 17, "column": 35}, "end_point": {"row": 17, "column": 46}}, {"id": 106, "type": "subscript_expression", "text": "str[i]", "parent": 105, "children": [107, 108], "start_point": {"row": 17, "column": 35}, "end_point": {"row": 17, "column": 41}}, {"id": 107, "type": "identifier", "text": "str", "parent": 106, "children": [], "start_point": {"row": 17, "column": 35}, "end_point": {"row": 17, "column": 38}}, {"id": 108, "type": "identifier", "text": "i", "parent": 106, "children": [], "start_point": {"row": 17, "column": 39}, "end_point": {"row": 17, "column": 40}}, {"id": 109, "type": "!=", "text": "!=", "parent": 105, "children": [], "start_point": {"row": 17, "column": 42}, "end_point": {"row": 17, "column": 44}}, {"id": 110, "type": "number_literal", "text": "0", "parent": 105, "children": [], "start_point": {"row": 17, "column": 45}, "end_point": {"row": 17, "column": 46}}, {"id": 111, "type": "update_expression", "text": "i++", "parent": 95, "children": [112, 113], "start_point": {"row": 17, "column": 48}, "end_point": {"row": 17, "column": 51}}, {"id": 112, "type": "identifier", "text": "i", "parent": 111, "children": [], "start_point": {"row": 17, "column": 48}, "end_point": {"row": 17, "column": 49}}, {"id": 113, "type": "++", "text": "++", "parent": 111, "children": [], "start_point": {"row": 17, "column": 49}, "end_point": {"row": 17, "column": 51}}, {"id": 114, "type": "return_statement", "text": "return i;", "parent": 76, "children": [115], "start_point": {"row": 18, "column": 4}, "end_point": {"row": 18, "column": 13}}, {"id": 115, "type": "identifier", "text": "i", "parent": 114, "children": [], "start_point": {"row": 18, "column": 11}, "end_point": {"row": 18, "column": 12}}, {"id": 116, "type": "function_definition", "text": "int getNextWhitespace(char *str, int index){\r\n int i = index;\r\n while(!isAWhitespace(str[i]) && str[i] != 0) i++;\r\n return i;\r\n}", "parent": null, "children": [117, 118], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 25, "column": 1}}, {"id": 117, "type": "primitive_type", "text": "int", "parent": 116, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 3}}, {"id": 118, "type": "function_declarator", "text": "getNextWhitespace(char *str, int index)", "parent": 116, "children": [119, 120], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 21, "column": 43}}, {"id": 119, "type": "identifier", "text": "getNextWhitespace", "parent": 118, "children": [], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 21, "column": 21}}, {"id": 120, "type": "parameter_list", "text": "(char *str, int index)", "parent": 118, "children": [121, 126], "start_point": {"row": 21, "column": 21}, "end_point": {"row": 21, "column": 43}}, {"id": 121, "type": "parameter_declaration", "text": "char *str", "parent": 120, "children": [122, 123], "start_point": {"row": 21, "column": 22}, "end_point": {"row": 21, "column": 31}}, {"id": 122, "type": "primitive_type", "text": "char", "parent": 121, "children": [], "start_point": {"row": 21, "column": 22}, "end_point": {"row": 21, "column": 26}}, {"id": 123, "type": "pointer_declarator", "text": "*str", "parent": 121, "children": [124, 125], "start_point": {"row": 21, "column": 27}, "end_point": {"row": 21, "column": 31}}, {"id": 124, "type": "*", "text": "*", "parent": 123, "children": [], "start_point": {"row": 21, "column": 27}, "end_point": {"row": 21, "column": 28}}, {"id": 125, "type": "identifier", "text": "str", "parent": 123, "children": [], "start_point": {"row": 21, "column": 28}, "end_point": {"row": 21, "column": 31}}, {"id": 126, "type": "parameter_declaration", "text": "int index", "parent": 120, "children": [127, 128], "start_point": {"row": 21, "column": 33}, "end_point": {"row": 21, "column": 42}}, {"id": 127, "type": "primitive_type", "text": "int", "parent": 126, "children": [], "start_point": {"row": 21, "column": 33}, "end_point": {"row": 21, "column": 36}}, {"id": 128, "type": "identifier", "text": "index", "parent": 126, "children": [], "start_point": {"row": 21, "column": 37}, "end_point": {"row": 21, "column": 42}}, {"id": 129, "type": "declaration", "text": "int i = index;", "parent": 116, "children": [130, 131], "start_point": {"row": 22, "column": 4}, "end_point": {"row": 22, "column": 18}}, {"id": 130, "type": "primitive_type", "text": "int", "parent": 129, "children": [], "start_point": {"row": 22, "column": 4}, "end_point": {"row": 22, "column": 7}}, {"id": 131, "type": "init_declarator", "text": "i = index", "parent": 129, "children": [132, 133, 134], "start_point": {"row": 22, "column": 8}, "end_point": {"row": 22, "column": 17}}, {"id": 132, "type": "identifier", "text": "i", "parent": 131, "children": [], "start_point": {"row": 22, "column": 8}, "end_point": {"row": 22, "column": 9}}, {"id": 133, "type": "=", "text": "=", "parent": 131, "children": [], "start_point": {"row": 22, "column": 10}, "end_point": {"row": 22, "column": 11}}, {"id": 134, "type": "identifier", "text": "index", "parent": 131, "children": [], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 17}}, {"id": 135, "type": "while_statement", "text": "while(!isAWhitespace(str[i]) && str[i] != 0) i++;", "parent": 116, "children": [136], "start_point": {"row": 23, "column": 4}, "end_point": {"row": 23, "column": 53}}, {"id": 136, "type": "parenthesized_expression", "text": "(!isAWhitespace(str[i]) && str[i] != 0)", "parent": 135, "children": [137], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 48}}, {"id": 137, "type": "binary_expression", "text": "!isAWhitespace(str[i]) && str[i] != 0", "parent": 136, "children": [138, 146, 147], "start_point": {"row": 23, "column": 10}, "end_point": {"row": 23, "column": 47}}, {"id": 138, "type": "unary_expression", "text": "!isAWhitespace(str[i])", "parent": 137, "children": [139, 140], "start_point": {"row": 23, "column": 10}, "end_point": {"row": 23, "column": 32}}, {"id": 139, "type": "!", "text": "!", "parent": 138, "children": [], "start_point": {"row": 23, "column": 10}, "end_point": {"row": 23, "column": 11}}, {"id": 140, "type": "call_expression", "text": "isAWhitespace(str[i])", "parent": 138, "children": [141, 142], "start_point": {"row": 23, "column": 11}, "end_point": {"row": 23, "column": 32}}, {"id": 141, "type": "identifier", "text": "isAWhitespace", "parent": 140, "children": [], "start_point": {"row": 23, "column": 11}, "end_point": {"row": 23, "column": 24}}, {"id": 142, "type": "argument_list", "text": "(str[i])", "parent": 140, "children": [143], "start_point": {"row": 23, "column": 24}, "end_point": {"row": 23, "column": 32}}, {"id": 143, "type": "subscript_expression", "text": "str[i]", "parent": 142, "children": [144, 145], "start_point": {"row": 23, "column": 25}, "end_point": {"row": 23, "column": 31}}, {"id": 144, "type": "identifier", "text": "str", "parent": 143, "children": [], "start_point": {"row": 23, "column": 25}, "end_point": {"row": 23, "column": 28}}, {"id": 145, "type": "identifier", "text": "i", "parent": 143, "children": [], "start_point": {"row": 23, "column": 29}, "end_point": {"row": 23, "column": 30}}, {"id": 146, "type": "&&", "text": "&&", "parent": 137, "children": [], "start_point": {"row": 23, "column": 33}, "end_point": {"row": 23, "column": 35}}, {"id": 147, "type": "binary_expression", "text": "str[i] != 0", "parent": 137, "children": [148, 151, 152], "start_point": {"row": 23, "column": 36}, "end_point": {"row": 23, "column": 47}}, {"id": 148, "type": "subscript_expression", "text": "str[i]", "parent": 147, "children": [149, 150], "start_point": {"row": 23, "column": 36}, "end_point": {"row": 23, "column": 42}}, {"id": 149, "type": "identifier", "text": "str", "parent": 148, "children": [], "start_point": {"row": 23, "column": 36}, "end_point": {"row": 23, "column": 39}}, {"id": 150, "type": "identifier", "text": "i", "parent": 148, "children": [], "start_point": {"row": 23, "column": 40}, "end_point": {"row": 23, "column": 41}}, {"id": 151, "type": "!=", "text": "!=", "parent": 147, "children": [], "start_point": {"row": 23, "column": 43}, "end_point": {"row": 23, "column": 45}}, {"id": 152, "type": "number_literal", "text": "0", "parent": 147, "children": [], "start_point": {"row": 23, "column": 46}, "end_point": {"row": 23, "column": 47}}, {"id": 153, "type": "update_expression", "text": "i++", "parent": 135, "children": [154, 155], "start_point": {"row": 23, "column": 49}, "end_point": {"row": 23, "column": 52}}, {"id": 154, "type": "identifier", "text": "i", "parent": 153, "children": [], "start_point": {"row": 23, "column": 49}, "end_point": {"row": 23, "column": 50}}, {"id": 155, "type": "++", "text": "++", "parent": 153, "children": [], "start_point": {"row": 23, "column": 50}, "end_point": {"row": 23, "column": 52}}, {"id": 156, "type": "return_statement", "text": "return i;", "parent": 116, "children": [157], "start_point": {"row": 24, "column": 4}, "end_point": {"row": 24, "column": 13}}, {"id": 157, "type": "identifier", "text": "i", "parent": 156, "children": [], "start_point": {"row": 24, "column": 11}, "end_point": {"row": 24, "column": 12}}, {"id": 158, "type": "function_definition", "text": "int countFirstCapitals(char *str){\r\n int count = 0, i = 0;\r\n\r\n while(str[i] != 0){\r\n i = getNextNonWhitespace(str, i);\r\n if(str[i] == 0) break;\r\n if(isCapital(str[i])) count++;\r\n i = getNextWhitespace(str, i);\r\n }\r\n\r\n return count;\r\n}", "parent": null, "children": [159, 160], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 38, "column": 1}}, {"id": 159, "type": "primitive_type", "text": "int", "parent": 158, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 3}}, {"id": 160, "type": "function_declarator", "text": "countFirstCapitals(char *str)", "parent": 158, "children": [161, 162], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 33}}, {"id": 161, "type": "identifier", "text": "countFirstCapitals", "parent": 160, "children": [], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 22}}, {"id": 162, "type": "parameter_list", "text": "(char *str)", "parent": 160, "children": [163], "start_point": {"row": 27, "column": 22}, "end_point": {"row": 27, "column": 33}}, {"id": 163, "type": "parameter_declaration", "text": "char *str", "parent": 162, "children": [164, 165], "start_point": {"row": 27, "column": 23}, "end_point": {"row": 27, "column": 32}}, {"id": 164, "type": "primitive_type", "text": "char", "parent": 163, "children": [], "start_point": {"row": 27, "column": 23}, "end_point": {"row": 27, "column": 27}}, {"id": 165, "type": "pointer_declarator", "text": "*str", "parent": 163, "children": [166, 167], "start_point": {"row": 27, "column": 28}, "end_point": {"row": 27, "column": 32}}, {"id": 166, "type": "*", "text": "*", "parent": 165, "children": [], "start_point": {"row": 27, "column": 28}, "end_point": {"row": 27, "column": 29}}, {"id": 167, "type": "identifier", "text": "str", "parent": 165, "children": [], "start_point": {"row": 27, "column": 29}, "end_point": {"row": 27, "column": 32}}, {"id": 168, "type": "declaration", "text": "int count = 0, i = 0;", "parent": 158, "children": [169, 170, 174], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 28, "column": 25}}, {"id": 169, "type": "primitive_type", "text": "int", "parent": 168, "children": [], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 28, "column": 7}}, {"id": 170, "type": "init_declarator", "text": "count = 0", "parent": 168, "children": [171, 172, 173], "start_point": {"row": 28, "column": 8}, "end_point": {"row": 28, "column": 17}}, {"id": 171, "type": "identifier", "text": "count", "parent": 170, "children": [], "start_point": {"row": 28, "column": 8}, "end_point": {"row": 28, "column": 13}}, {"id": 172, "type": "=", "text": "=", "parent": 170, "children": [], "start_point": {"row": 28, "column": 14}, "end_point": {"row": 28, "column": 15}}, {"id": 173, "type": "number_literal", "text": "0", "parent": 170, "children": [], "start_point": {"row": 28, "column": 16}, "end_point": {"row": 28, "column": 17}}, {"id": 174, "type": "init_declarator", "text": "i = 0", "parent": 168, "children": [175, 176, 177], "start_point": {"row": 28, "column": 19}, "end_point": {"row": 28, "column": 24}}, {"id": 175, "type": "identifier", "text": "i", "parent": 174, "children": [], "start_point": {"row": 28, "column": 19}, "end_point": {"row": 28, "column": 20}}, {"id": 176, "type": "=", "text": "=", "parent": 174, "children": [], "start_point": {"row": 28, "column": 21}, "end_point": {"row": 28, "column": 22}}, {"id": 177, "type": "number_literal", "text": "0", "parent": 174, "children": [], "start_point": {"row": 28, "column": 23}, "end_point": {"row": 28, "column": 24}}, {"id": 178, "type": "while_statement", "text": "while(str[i] != 0){\r\n i = getNextNonWhitespace(str, i);\r\n if(str[i] == 0) break;\r\n if(isCapital(str[i])) count++;\r\n i = getNextWhitespace(str, i);\r\n }", "parent": 158, "children": [179], "start_point": {"row": 30, "column": 4}, "end_point": {"row": 35, "column": 5}}, {"id": 179, "type": "parenthesized_expression", "text": "(str[i] != 0)", "parent": 178, "children": [180], "start_point": {"row": 30, "column": 9}, "end_point": {"row": 30, "column": 22}}, {"id": 180, "type": "binary_expression", "text": "str[i] != 0", "parent": 179, "children": [181, 184, 185], "start_point": {"row": 30, "column": 10}, "end_point": {"row": 30, "column": 21}}, {"id": 181, "type": "subscript_expression", "text": "str[i]", "parent": 180, "children": [182, 183], "start_point": {"row": 30, "column": 10}, "end_point": {"row": 30, "column": 16}}, {"id": 182, "type": "identifier", "text": "str", "parent": 181, "children": [], "start_point": {"row": 30, "column": 10}, "end_point": {"row": 30, "column": 13}}, {"id": 183, "type": "identifier", "text": "i", "parent": 181, "children": [], "start_point": {"row": 30, "column": 14}, "end_point": {"row": 30, "column": 15}}, {"id": 184, "type": "!=", "text": "!=", "parent": 180, "children": [], "start_point": {"row": 30, "column": 17}, "end_point": {"row": 30, "column": 19}}, {"id": 185, "type": "number_literal", "text": "0", "parent": 180, "children": [], "start_point": {"row": 30, "column": 20}, "end_point": {"row": 30, "column": 21}}, {"id": 186, "type": "assignment_expression", "text": "i = getNextNonWhitespace(str, i)", "parent": 178, "children": [187, 188, 189], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 40}}, {"id": 187, "type": "identifier", "text": "i", "parent": 186, "children": [], "start_point": {"row": 31, "column": 8}, "end_point": {"row": 31, "column": 9}}, {"id": 188, "type": "=", "text": "=", "parent": 186, "children": [], "start_point": {"row": 31, "column": 10}, "end_point": {"row": 31, "column": 11}}, {"id": 189, "type": "call_expression", "text": "getNextNonWhitespace(str, i)", "parent": 186, "children": [190, 191], "start_point": {"row": 31, "column": 12}, "end_point": {"row": 31, "column": 40}}, {"id": 190, "type": "identifier", "text": "getNextNonWhitespace", "parent": 189, "children": [], "start_point": {"row": 31, "column": 12}, "end_point": {"row": 31, "column": 32}}, {"id": 191, "type": "argument_list", "text": "(str, i)", "parent": 189, "children": [192, 193], "start_point": {"row": 31, "column": 32}, "end_point": {"row": 31, "column": 40}}, {"id": 192, "type": "identifier", "text": "str", "parent": 191, "children": [], "start_point": {"row": 31, "column": 33}, "end_point": {"row": 31, "column": 36}}, {"id": 193, "type": "identifier", "text": "i", "parent": 191, "children": [], "start_point": {"row": 31, "column": 38}, "end_point": {"row": 31, "column": 39}}, {"id": 194, "type": "if_statement", "text": "if(str[i] == 0) break;", "parent": 178, "children": [195, 202], "start_point": {"row": 32, "column": 8}, "end_point": {"row": 32, "column": 30}}, {"id": 195, "type": "parenthesized_expression", "text": "(str[i] == 0)", "parent": 194, "children": [196], "start_point": {"row": 32, "column": 10}, "end_point": {"row": 32, "column": 23}}, {"id": 196, "type": "binary_expression", "text": "str[i] == 0", "parent": 195, "children": [197, 200, 201], "start_point": {"row": 32, "column": 11}, "end_point": {"row": 32, "column": 22}}, {"id": 197, "type": "subscript_expression", "text": "str[i]", "parent": 196, "children": [198, 199], "start_point": {"row": 32, "column": 11}, "end_point": {"row": 32, "column": 17}}, {"id": 198, "type": "identifier", "text": "str", "parent": 197, "children": [], "start_point": {"row": 32, "column": 11}, "end_point": {"row": 32, "column": 14}}, {"id": 199, "type": "identifier", "text": "i", "parent": 197, "children": [], "start_point": {"row": 32, "column": 15}, "end_point": {"row": 32, "column": 16}}, {"id": 200, "type": "==", "text": "==", "parent": 196, "children": [], "start_point": {"row": 32, "column": 18}, "end_point": {"row": 32, "column": 20}}, {"id": 201, "type": "number_literal", "text": "0", "parent": 196, "children": [], "start_point": {"row": 32, "column": 21}, "end_point": {"row": 32, "column": 22}}, {"id": 202, "type": "break_statement", "text": "break;", "parent": 194, "children": [203], "start_point": {"row": 32, "column": 24}, "end_point": {"row": 32, "column": 30}}, {"id": 203, "type": "break", "text": "break", "parent": 202, "children": [], "start_point": {"row": 32, "column": 24}, "end_point": {"row": 32, "column": 29}}, {"id": 204, "type": "if_statement", "text": "if(isCapital(str[i])) count++;", "parent": 178, "children": [205], "start_point": {"row": 33, "column": 8}, "end_point": {"row": 33, "column": 38}}, {"id": 205, "type": "parenthesized_expression", "text": "(isCapital(str[i]))", "parent": 204, "children": [206], "start_point": {"row": 33, "column": 10}, "end_point": {"row": 33, "column": 29}}, {"id": 206, "type": "call_expression", "text": "isCapital(str[i])", "parent": 205, "children": [207, 208], "start_point": {"row": 33, "column": 11}, "end_point": {"row": 33, "column": 28}}, {"id": 207, "type": "identifier", "text": "isCapital", "parent": 206, "children": [], "start_point": {"row": 33, "column": 11}, "end_point": {"row": 33, "column": 20}}, {"id": 208, "type": "argument_list", "text": "(str[i])", "parent": 206, "children": [209], "start_point": {"row": 33, "column": 20}, "end_point": {"row": 33, "column": 28}}, {"id": 209, "type": "subscript_expression", "text": "str[i]", "parent": 208, "children": [210, 211], "start_point": {"row": 33, "column": 21}, "end_point": {"row": 33, "column": 27}}, {"id": 210, "type": "identifier", "text": "str", "parent": 209, "children": [], "start_point": {"row": 33, "column": 21}, "end_point": {"row": 33, "column": 24}}, {"id": 211, "type": "identifier", "text": "i", "parent": 209, "children": [], "start_point": {"row": 33, "column": 25}, "end_point": {"row": 33, "column": 26}}, {"id": 212, "type": "update_expression", "text": "count++", "parent": 204, "children": [213, 214], "start_point": {"row": 33, "column": 30}, "end_point": {"row": 33, "column": 37}}, {"id": 213, "type": "identifier", "text": "count", "parent": 212, "children": [], "start_point": {"row": 33, "column": 30}, "end_point": {"row": 33, "column": 35}}, {"id": 214, "type": "++", "text": "++", "parent": 212, "children": [], "start_point": {"row": 33, "column": 35}, "end_point": {"row": 33, "column": 37}}, {"id": 215, "type": "assignment_expression", "text": "i = getNextWhitespace(str, i)", "parent": 178, "children": [216, 217, 218], "start_point": {"row": 34, "column": 8}, "end_point": {"row": 34, "column": 37}}, {"id": 216, "type": "identifier", "text": "i", "parent": 215, "children": [], "start_point": {"row": 34, "column": 8}, "end_point": {"row": 34, "column": 9}}, {"id": 217, "type": "=", "text": "=", "parent": 215, "children": [], "start_point": {"row": 34, "column": 10}, "end_point": {"row": 34, "column": 11}}, {"id": 218, "type": "call_expression", "text": "getNextWhitespace(str, i)", "parent": 215, "children": [219, 220], "start_point": {"row": 34, "column": 12}, "end_point": {"row": 34, "column": 37}}, {"id": 219, "type": "identifier", "text": "getNextWhitespace", "parent": 218, "children": [], "start_point": {"row": 34, "column": 12}, "end_point": {"row": 34, "column": 29}}, {"id": 220, "type": "argument_list", "text": "(str, i)", "parent": 218, "children": [221, 222], "start_point": {"row": 34, "column": 29}, "end_point": {"row": 34, "column": 37}}, {"id": 221, "type": "identifier", "text": "str", "parent": 220, "children": [], "start_point": {"row": 34, "column": 30}, "end_point": {"row": 34, "column": 33}}, {"id": 222, "type": "identifier", "text": "i", "parent": 220, "children": [], "start_point": {"row": 34, "column": 35}, "end_point": {"row": 34, "column": 36}}, {"id": 223, "type": "return_statement", "text": "return count;", "parent": 158, "children": [224], "start_point": {"row": 37, "column": 4}, "end_point": {"row": 37, "column": 17}}, {"id": 224, "type": "identifier", "text": "count", "parent": 223, "children": [], "start_point": {"row": 37, "column": 11}, "end_point": {"row": 37, "column": 16}}, {"id": 225, "type": "function_definition", "text": "int *getFirstCapitals(char *str){\r\n int size = countFirstCapitals(str);\r\n int *firstCapitals = malloc(size * sizeof(int));\r\n int i = 0, count = 0;\r\n while(str[i] != 0){\r\n i = getNextNonWhitespace(str, i);\r\n if(str[i] == 0) break;\r\n if(isCapital(str[i])){\r\n firstCapitals[count++] = i;\r\n }\r\n i = getNextWhitespace(str, i);\r\n }\r\n\r\n return firstCapitals;\r\n}", "parent": null, "children": [226, 227], "start_point": {"row": 40, "column": 0}, "end_point": {"row": 54, "column": 1}}, {"id": 226, "type": "primitive_type", "text": "int", "parent": 225, "children": [], "start_point": {"row": 40, "column": 0}, "end_point": {"row": 40, "column": 3}}, {"id": 227, "type": "pointer_declarator", "text": "*getFirstCapitals(char *str)", "parent": 225, "children": [228, 229], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 40, "column": 32}}, {"id": 228, "type": "*", "text": "*", "parent": 227, "children": [], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 40, "column": 5}}, {"id": 229, "type": "function_declarator", "text": "getFirstCapitals(char *str)", "parent": 227, "children": [230, 231], "start_point": {"row": 40, "column": 5}, "end_point": {"row": 40, "column": 32}}, {"id": 230, "type": "identifier", "text": "getFirstCapitals", "parent": 229, "children": [], "start_point": {"row": 40, "column": 5}, "end_point": {"row": 40, "column": 21}}, {"id": 231, "type": "parameter_list", "text": "(char *str)", "parent": 229, "children": [232], "start_point": {"row": 40, "column": 21}, "end_point": {"row": 40, "column": 32}}, {"id": 232, "type": "parameter_declaration", "text": "char *str", "parent": 231, "children": [233, 234], "start_point": {"row": 40, "column": 22}, "end_point": {"row": 40, "column": 31}}, {"id": 233, "type": "primitive_type", "text": "char", "parent": 232, "children": [], "start_point": {"row": 40, "column": 22}, "end_point": {"row": 40, "column": 26}}, {"id": 234, "type": "pointer_declarator", "text": "*str", "parent": 232, "children": [235, 236], "start_point": {"row": 40, "column": 27}, "end_point": {"row": 40, "column": 31}}, {"id": 235, "type": "*", "text": "*", "parent": 234, "children": [], "start_point": {"row": 40, "column": 27}, "end_point": {"row": 40, "column": 28}}, {"id": 236, "type": "identifier", "text": "str", "parent": 234, "children": [], "start_point": {"row": 40, "column": 28}, "end_point": {"row": 40, "column": 31}}, {"id": 237, "type": "declaration", "text": "int size = countFirstCapitals(str);", "parent": 225, "children": [238, 239], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 41, "column": 39}}, {"id": 238, "type": "primitive_type", "text": "int", "parent": 237, "children": [], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 41, "column": 7}}, {"id": 239, "type": "init_declarator", "text": "size = countFirstCapitals(str)", "parent": 237, "children": [240, 241, 242], "start_point": {"row": 41, "column": 8}, "end_point": {"row": 41, "column": 38}}, {"id": 240, "type": "identifier", "text": "size", "parent": 239, "children": [], "start_point": {"row": 41, "column": 8}, "end_point": {"row": 41, "column": 12}}, {"id": 241, "type": "=", "text": "=", "parent": 239, "children": [], "start_point": {"row": 41, "column": 13}, "end_point": {"row": 41, "column": 14}}, {"id": 242, "type": "call_expression", "text": "countFirstCapitals(str)", "parent": 239, "children": [243, 244], "start_point": {"row": 41, "column": 15}, "end_point": {"row": 41, "column": 38}}, {"id": 243, "type": "identifier", "text": "countFirstCapitals", "parent": 242, "children": [], "start_point": {"row": 41, "column": 15}, "end_point": {"row": 41, "column": 33}}, {"id": 244, "type": "argument_list", "text": "(str)", "parent": 242, "children": [245], "start_point": {"row": 41, "column": 33}, "end_point": {"row": 41, "column": 38}}, {"id": 245, "type": "identifier", "text": "str", "parent": 244, "children": [], "start_point": {"row": 41, "column": 34}, "end_point": {"row": 41, "column": 37}}, {"id": 246, "type": "declaration", "text": "int *firstCapitals = malloc(size * sizeof(int));", "parent": 225, "children": [247, 248], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 52}}, {"id": 247, "type": "primitive_type", "text": "int", "parent": 246, "children": [], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 7}}, {"id": 248, "type": "init_declarator", "text": "*firstCapitals = malloc(size * sizeof(int))", "parent": 246, "children": [249, 252, 253], "start_point": {"row": 42, "column": 8}, "end_point": {"row": 42, "column": 51}}, {"id": 249, "type": "pointer_declarator", "text": "*firstCapitals", "parent": 248, "children": [250, 251], "start_point": {"row": 42, "column": 8}, "end_point": {"row": 42, "column": 22}}, {"id": 250, "type": "*", "text": "*", "parent": 249, "children": [], "start_point": {"row": 42, "column": 8}, "end_point": {"row": 42, "column": 9}}, {"id": 251, "type": "identifier", "text": "firstCapitals", "parent": 249, "children": [], "start_point": {"row": 42, "column": 9}, "end_point": {"row": 42, "column": 22}}, {"id": 252, "type": "=", "text": "=", "parent": 248, "children": [], "start_point": {"row": 42, "column": 23}, "end_point": {"row": 42, "column": 24}}, {"id": 253, "type": "call_expression", "text": "malloc(size * sizeof(int))", "parent": 248, "children": [254, 255], "start_point": {"row": 42, "column": 25}, "end_point": {"row": 42, "column": 51}}, {"id": 254, "type": "identifier", "text": "malloc", "parent": 253, "children": [], "start_point": {"row": 42, "column": 25}, "end_point": {"row": 42, "column": 31}}, {"id": 255, "type": "argument_list", "text": "(size * sizeof(int))", "parent": 253, "children": [256], "start_point": {"row": 42, "column": 31}, "end_point": {"row": 42, "column": 51}}, {"id": 256, "type": "binary_expression", "text": "size * sizeof(int)", "parent": 255, "children": [257, 258, 259], "start_point": {"row": 42, "column": 32}, "end_point": {"row": 42, "column": 50}}, {"id": 257, "type": "identifier", "text": "size", "parent": 256, "children": [], "start_point": {"row": 42, "column": 32}, "end_point": {"row": 42, "column": 36}}, {"id": 258, "type": "*", "text": "*", "parent": 256, "children": [], "start_point": {"row": 42, "column": 37}, "end_point": {"row": 42, "column": 38}}, {"id": 259, "type": "sizeof_expression", "text": "sizeof(int)", "parent": 256, "children": [260], "start_point": {"row": 42, "column": 39}, "end_point": {"row": 42, "column": 50}}, {"id": 260, "type": "type_descriptor", "text": "int", "parent": 259, "children": [261], "start_point": {"row": 42, "column": 46}, "end_point": {"row": 42, "column": 49}}, {"id": 261, "type": "primitive_type", "text": "int", "parent": 260, "children": [], "start_point": {"row": 42, "column": 46}, "end_point": {"row": 42, "column": 49}}, {"id": 262, "type": "declaration", "text": "int i = 0, count = 0;", "parent": 225, "children": [263, 264, 268], "start_point": {"row": 43, "column": 4}, "end_point": {"row": 43, "column": 25}}, {"id": 263, "type": "primitive_type", "text": "int", "parent": 262, "children": [], "start_point": {"row": 43, "column": 4}, "end_point": {"row": 43, "column": 7}}, {"id": 264, "type": "init_declarator", "text": "i = 0", "parent": 262, "children": [265, 266, 267], "start_point": {"row": 43, "column": 8}, "end_point": {"row": 43, "column": 13}}, {"id": 265, "type": "identifier", "text": "i", "parent": 264, "children": [], "start_point": {"row": 43, "column": 8}, "end_point": {"row": 43, "column": 9}}, {"id": 266, "type": "=", "text": "=", "parent": 264, "children": [], "start_point": {"row": 43, "column": 10}, "end_point": {"row": 43, "column": 11}}, {"id": 267, "type": "number_literal", "text": "0", "parent": 264, "children": [], "start_point": {"row": 43, "column": 12}, "end_point": {"row": 43, "column": 13}}, {"id": 268, "type": "init_declarator", "text": "count = 0", "parent": 262, "children": [269, 270, 271], "start_point": {"row": 43, "column": 15}, "end_point": {"row": 43, "column": 24}}, {"id": 269, "type": "identifier", "text": "count", "parent": 268, "children": [], "start_point": {"row": 43, "column": 15}, "end_point": {"row": 43, "column": 20}}, {"id": 270, "type": "=", "text": "=", "parent": 268, "children": [], "start_point": {"row": 43, "column": 21}, "end_point": {"row": 43, "column": 22}}, {"id": 271, "type": "number_literal", "text": "0", "parent": 268, "children": [], "start_point": {"row": 43, "column": 23}, "end_point": {"row": 43, "column": 24}}, {"id": 272, "type": "while_statement", "text": "while(str[i] != 0){\r\n i = getNextNonWhitespace(str, i);\r\n if(str[i] == 0) break;\r\n if(isCapital(str[i])){\r\n firstCapitals[count++] = i;\r\n }\r\n i = getNextWhitespace(str, i);\r\n }", "parent": 225, "children": [273], "start_point": {"row": 44, "column": 4}, "end_point": {"row": 51, "column": 5}}, {"id": 273, "type": "parenthesized_expression", "text": "(str[i] != 0)", "parent": 272, "children": [274], "start_point": {"row": 44, "column": 9}, "end_point": {"row": 44, "column": 22}}, {"id": 274, "type": "binary_expression", "text": "str[i] != 0", "parent": 273, "children": [275, 278, 279], "start_point": {"row": 44, "column": 10}, "end_point": {"row": 44, "column": 21}}, {"id": 275, "type": "subscript_expression", "text": "str[i]", "parent": 274, "children": [276, 277], "start_point": {"row": 44, "column": 10}, "end_point": {"row": 44, "column": 16}}, {"id": 276, "type": "identifier", "text": "str", "parent": 275, "children": [], "start_point": {"row": 44, "column": 10}, "end_point": {"row": 44, "column": 13}}, {"id": 277, "type": "identifier", "text": "i", "parent": 275, "children": [], "start_point": {"row": 44, "column": 14}, "end_point": {"row": 44, "column": 15}}, {"id": 278, "type": "!=", "text": "!=", "parent": 274, "children": [], "start_point": {"row": 44, "column": 17}, "end_point": {"row": 44, "column": 19}}, {"id": 279, "type": "number_literal", "text": "0", "parent": 274, "children": [], "start_point": {"row": 44, "column": 20}, "end_point": {"row": 44, "column": 21}}, {"id": 280, "type": "assignment_expression", "text": "i = getNextNonWhitespace(str, i)", "parent": 272, "children": [281, 282, 283], "start_point": {"row": 45, "column": 8}, "end_point": {"row": 45, "column": 40}}, {"id": 281, "type": "identifier", "text": "i", "parent": 280, "children": [], "start_point": {"row": 45, "column": 8}, "end_point": {"row": 45, "column": 9}}, {"id": 282, "type": "=", "text": "=", "parent": 280, "children": [], "start_point": {"row": 45, "column": 10}, "end_point": {"row": 45, "column": 11}}, {"id": 283, "type": "call_expression", "text": "getNextNonWhitespace(str, i)", "parent": 280, "children": [284, 285], "start_point": {"row": 45, "column": 12}, "end_point": {"row": 45, "column": 40}}, {"id": 284, "type": "identifier", "text": "getNextNonWhitespace", "parent": 283, "children": [], "start_point": {"row": 45, "column": 12}, "end_point": {"row": 45, "column": 32}}, {"id": 285, "type": "argument_list", "text": "(str, i)", "parent": 283, "children": [286, 287], "start_point": {"row": 45, "column": 32}, "end_point": {"row": 45, "column": 40}}, {"id": 286, "type": "identifier", "text": "str", "parent": 285, "children": [], "start_point": {"row": 45, "column": 33}, "end_point": {"row": 45, "column": 36}}, {"id": 287, "type": "identifier", "text": "i", "parent": 285, "children": [], "start_point": {"row": 45, "column": 38}, "end_point": {"row": 45, "column": 39}}, {"id": 288, "type": "if_statement", "text": "if(str[i] == 0) break;", "parent": 272, "children": [289, 296], "start_point": {"row": 46, "column": 8}, "end_point": {"row": 46, "column": 30}}, {"id": 289, "type": "parenthesized_expression", "text": "(str[i] == 0)", "parent": 288, "children": [290], "start_point": {"row": 46, "column": 10}, "end_point": {"row": 46, "column": 23}}, {"id": 290, "type": "binary_expression", "text": "str[i] == 0", "parent": 289, "children": [291, 294, 295], "start_point": {"row": 46, "column": 11}, "end_point": {"row": 46, "column": 22}}, {"id": 291, "type": "subscript_expression", "text": "str[i]", "parent": 290, "children": [292, 293], "start_point": {"row": 46, "column": 11}, "end_point": {"row": 46, "column": 17}}, {"id": 292, "type": "identifier", "text": "str", "parent": 291, "children": [], "start_point": {"row": 46, "column": 11}, "end_point": {"row": 46, "column": 14}}, {"id": 293, "type": "identifier", "text": "i", "parent": 291, "children": [], "start_point": {"row": 46, "column": 15}, "end_point": {"row": 46, "column": 16}}, {"id": 294, "type": "==", "text": "==", "parent": 290, "children": [], "start_point": {"row": 46, "column": 18}, "end_point": {"row": 46, "column": 20}}, {"id": 295, "type": "number_literal", "text": "0", "parent": 290, "children": [], "start_point": {"row": 46, "column": 21}, "end_point": {"row": 46, "column": 22}}, {"id": 296, "type": "break_statement", "text": "break;", "parent": 288, "children": [297], "start_point": {"row": 46, "column": 24}, "end_point": {"row": 46, "column": 30}}, {"id": 297, "type": "break", "text": "break", "parent": 296, "children": [], "start_point": {"row": 46, "column": 24}, "end_point": {"row": 46, "column": 29}}, {"id": 298, "type": "if_statement", "text": "if(isCapital(str[i])){\r\n firstCapitals[count++] = i;\r\n }", "parent": 272, "children": [299], "start_point": {"row": 47, "column": 8}, "end_point": {"row": 49, "column": 9}}, {"id": 299, "type": "parenthesized_expression", "text": "(isCapital(str[i]))", "parent": 298, "children": [300], "start_point": {"row": 47, "column": 10}, "end_point": {"row": 47, "column": 29}}, {"id": 300, "type": "call_expression", "text": "isCapital(str[i])", "parent": 299, "children": [301, 302], "start_point": {"row": 47, "column": 11}, "end_point": {"row": 47, "column": 28}}, {"id": 301, "type": "identifier", "text": "isCapital", "parent": 300, "children": [], "start_point": {"row": 47, "column": 11}, "end_point": {"row": 47, "column": 20}}, {"id": 302, "type": "argument_list", "text": "(str[i])", "parent": 300, "children": [303], "start_point": {"row": 47, "column": 20}, "end_point": {"row": 47, "column": 28}}, {"id": 303, "type": "subscript_expression", "text": "str[i]", "parent": 302, "children": [304, 305], "start_point": {"row": 47, "column": 21}, "end_point": {"row": 47, "column": 27}}, {"id": 304, "type": "identifier", "text": "str", "parent": 303, "children": [], "start_point": {"row": 47, "column": 21}, "end_point": {"row": 47, "column": 24}}, {"id": 305, "type": "identifier", "text": "i", "parent": 303, "children": [], "start_point": {"row": 47, "column": 25}, "end_point": {"row": 47, "column": 26}}, {"id": 306, "type": "assignment_expression", "text": "firstCapitals[count++] = i", "parent": 298, "children": [307, 312, 313], "start_point": {"row": 48, "column": 12}, "end_point": {"row": 48, "column": 38}}, {"id": 307, "type": "subscript_expression", "text": "firstCapitals[count++]", "parent": 306, "children": [308, 309], "start_point": {"row": 48, "column": 12}, "end_point": {"row": 48, "column": 34}}, {"id": 308, "type": "identifier", "text": "firstCapitals", "parent": 307, "children": [], "start_point": {"row": 48, "column": 12}, "end_point": {"row": 48, "column": 25}}, {"id": 309, "type": "update_expression", "text": "count++", "parent": 307, "children": [310, 311], "start_point": {"row": 48, "column": 26}, "end_point": {"row": 48, "column": 33}}, {"id": 310, "type": "identifier", "text": "count", "parent": 309, "children": [], "start_point": {"row": 48, "column": 26}, "end_point": {"row": 48, "column": 31}}, {"id": 311, "type": "++", "text": "++", "parent": 309, "children": [], "start_point": {"row": 48, "column": 31}, "end_point": {"row": 48, "column": 33}}, {"id": 312, "type": "=", "text": "=", "parent": 306, "children": [], "start_point": {"row": 48, "column": 35}, "end_point": {"row": 48, "column": 36}}, {"id": 313, "type": "identifier", "text": "i", "parent": 306, "children": [], "start_point": {"row": 48, "column": 37}, "end_point": {"row": 48, "column": 38}}, {"id": 314, "type": "assignment_expression", "text": "i = getNextWhitespace(str, i)", "parent": 272, "children": [315, 316, 317], "start_point": {"row": 50, "column": 8}, "end_point": {"row": 50, "column": 37}}, {"id": 315, "type": "identifier", "text": "i", "parent": 314, "children": [], "start_point": {"row": 50, "column": 8}, "end_point": {"row": 50, "column": 9}}, {"id": 316, "type": "=", "text": "=", "parent": 314, "children": [], "start_point": {"row": 50, "column": 10}, "end_point": {"row": 50, "column": 11}}, {"id": 317, "type": "call_expression", "text": "getNextWhitespace(str, i)", "parent": 314, "children": [318, 319], "start_point": {"row": 50, "column": 12}, "end_point": {"row": 50, "column": 37}}, {"id": 318, "type": "identifier", "text": "getNextWhitespace", "parent": 317, "children": [], "start_point": {"row": 50, "column": 12}, "end_point": {"row": 50, "column": 29}}, {"id": 319, "type": "argument_list", "text": "(str, i)", "parent": 317, "children": [320, 321], "start_point": {"row": 50, "column": 29}, "end_point": {"row": 50, "column": 37}}, {"id": 320, "type": "identifier", "text": "str", "parent": 319, "children": [], "start_point": {"row": 50, "column": 30}, "end_point": {"row": 50, "column": 33}}, {"id": 321, "type": "identifier", "text": "i", "parent": 319, "children": [], "start_point": {"row": 50, "column": 35}, "end_point": {"row": 50, "column": 36}}, {"id": 322, "type": "return_statement", "text": "return firstCapitals;", "parent": 225, "children": [323], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 25}}, {"id": 323, "type": "identifier", "text": "firstCapitals", "parent": 322, "children": [], "start_point": {"row": 53, "column": 11}, "end_point": {"row": 53, "column": 24}}, {"id": 324, "type": "function_definition", "text": "char *readLine(){\r\n int size = 64;\r\n char *line = malloc(size * sizeof(char));\r\n char c = 0;\r\n int i = 0;\r\n\r\n while(true){\r\n \r\n if(i == size){\r\n size = 2 * size;\r\n line = realloc(line, size * sizeof(char));\r\n }\r\n\r\n c = getc(stdin);\r\n \r\n if(c == '\\n'){\r\n line[i++] = 0;\r\n break;\r\n }\r\n\r\n line[i++] = c;\r\n }\r\n\r\n line = realloc(line, i * sizeof(char));\r\n\r\n return line;\r\n}", "parent": null, "children": [325, 326], "start_point": {"row": 56, "column": 0}, "end_point": {"row": 82, "column": 1}}, {"id": 325, "type": "primitive_type", "text": "char", "parent": 324, "children": [], "start_point": {"row": 56, "column": 0}, "end_point": {"row": 56, "column": 4}}, {"id": 326, "type": "pointer_declarator", "text": "*readLine()", "parent": 324, "children": [327, 328], "start_point": {"row": 56, "column": 5}, "end_point": {"row": 56, "column": 16}}, {"id": 327, "type": "*", "text": "*", "parent": 326, "children": [], "start_point": {"row": 56, "column": 5}, "end_point": {"row": 56, "column": 6}}, {"id": 328, "type": "function_declarator", "text": "readLine()", "parent": 326, "children": [329, 330], "start_point": {"row": 56, "column": 6}, "end_point": {"row": 56, "column": 16}}, {"id": 329, "type": "identifier", "text": "readLine", "parent": 328, "children": [], "start_point": {"row": 56, "column": 6}, "end_point": {"row": 56, "column": 14}}, {"id": 330, "type": "parameter_list", "text": "()", "parent": 328, "children": [], "start_point": {"row": 56, "column": 14}, "end_point": {"row": 56, "column": 16}}, {"id": 331, "type": "declaration", "text": "int size = 64;", "parent": 324, "children": [332, 333], "start_point": {"row": 57, "column": 4}, "end_point": {"row": 57, "column": 18}}, {"id": 332, "type": "primitive_type", "text": "int", "parent": 331, "children": [], "start_point": {"row": 57, "column": 4}, "end_point": {"row": 57, "column": 7}}, {"id": 333, "type": "init_declarator", "text": "size = 64", "parent": 331, "children": [334, 335, 336], "start_point": {"row": 57, "column": 8}, "end_point": {"row": 57, "column": 17}}, {"id": 334, "type": "identifier", "text": "size", "parent": 333, "children": [], "start_point": {"row": 57, "column": 8}, "end_point": {"row": 57, "column": 12}}, {"id": 335, "type": "=", "text": "=", "parent": 333, "children": [], "start_point": {"row": 57, "column": 13}, "end_point": {"row": 57, "column": 14}}, {"id": 336, "type": "number_literal", "text": "64", "parent": 333, "children": [], "start_point": {"row": 57, "column": 15}, "end_point": {"row": 57, "column": 17}}, {"id": 337, "type": "declaration", "text": "char *line = malloc(size * sizeof(char));", "parent": 324, "children": [338, 339], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 45}}, {"id": 338, "type": "primitive_type", "text": "char", "parent": 337, "children": [], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 8}}, {"id": 339, "type": "init_declarator", "text": "*line = malloc(size * sizeof(char))", "parent": 337, "children": [340, 343, 344], "start_point": {"row": 58, "column": 9}, "end_point": {"row": 58, "column": 44}}, {"id": 340, "type": "pointer_declarator", "text": "*line", "parent": 339, "children": [341, 342], "start_point": {"row": 58, "column": 9}, "end_point": {"row": 58, "column": 14}}, {"id": 341, "type": "*", "text": "*", "parent": 340, "children": [], "start_point": {"row": 58, "column": 9}, "end_point": {"row": 58, "column": 10}}, {"id": 342, "type": "identifier", "text": "line", "parent": 340, "children": [], "start_point": {"row": 58, "column": 10}, "end_point": {"row": 58, "column": 14}}, {"id": 343, "type": "=", "text": "=", "parent": 339, "children": [], "start_point": {"row": 58, "column": 15}, "end_point": {"row": 58, "column": 16}}, {"id": 344, "type": "call_expression", "text": "malloc(size * sizeof(char))", "parent": 339, "children": [345, 346], "start_point": {"row": 58, "column": 17}, "end_point": {"row": 58, "column": 44}}, {"id": 345, "type": "identifier", "text": "malloc", "parent": 344, "children": [], "start_point": {"row": 58, "column": 17}, "end_point": {"row": 58, "column": 23}}, {"id": 346, "type": "argument_list", "text": "(size * sizeof(char))", "parent": 344, "children": [347], "start_point": {"row": 58, "column": 23}, "end_point": {"row": 58, "column": 44}}, {"id": 347, "type": "binary_expression", "text": "size * sizeof(char)", "parent": 346, "children": [348, 349, 350], "start_point": {"row": 58, "column": 24}, "end_point": {"row": 58, "column": 43}}, {"id": 348, "type": "identifier", "text": "size", "parent": 347, "children": [], "start_point": {"row": 58, "column": 24}, "end_point": {"row": 58, "column": 28}}, {"id": 349, "type": "*", "text": "*", "parent": 347, "children": [], "start_point": {"row": 58, "column": 29}, "end_point": {"row": 58, "column": 30}}, {"id": 350, "type": "sizeof_expression", "text": "sizeof(char)", "parent": 347, "children": [351], "start_point": {"row": 58, "column": 31}, "end_point": {"row": 58, "column": 43}}, {"id": 351, "type": "type_descriptor", "text": "char", "parent": 350, "children": [352], "start_point": {"row": 58, "column": 38}, "end_point": {"row": 58, "column": 42}}, {"id": 352, "type": "primitive_type", "text": "char", "parent": 351, "children": [], "start_point": {"row": 58, "column": 38}, "end_point": {"row": 58, "column": 42}}, {"id": 353, "type": "declaration", "text": "char c = 0;", "parent": 324, "children": [354, 355], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 15}}, {"id": 354, "type": "primitive_type", "text": "char", "parent": 353, "children": [], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 8}}, {"id": 355, "type": "init_declarator", "text": "c = 0", "parent": 353, "children": [356, 357, 358], "start_point": {"row": 59, "column": 9}, "end_point": {"row": 59, "column": 14}}, {"id": 356, "type": "identifier", "text": "c", "parent": 355, "children": [], "start_point": {"row": 59, "column": 9}, "end_point": {"row": 59, "column": 10}}, {"id": 357, "type": "=", "text": "=", "parent": 355, "children": [], "start_point": {"row": 59, "column": 11}, "end_point": {"row": 59, "column": 12}}, {"id": 358, "type": "number_literal", "text": "0", "parent": 355, "children": [], "start_point": {"row": 59, "column": 13}, "end_point": {"row": 59, "column": 14}}, {"id": 359, "type": "declaration", "text": "int i = 0;", "parent": 324, "children": [360, 361], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 14}}, {"id": 360, "type": "primitive_type", "text": "int", "parent": 359, "children": [], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 7}}, {"id": 361, "type": "init_declarator", "text": "i = 0", "parent": 359, "children": [362, 363, 364], "start_point": {"row": 60, "column": 8}, "end_point": {"row": 60, "column": 13}}, {"id": 362, "type": "identifier", "text": "i", "parent": 361, "children": [], "start_point": {"row": 60, "column": 8}, "end_point": {"row": 60, "column": 9}}, {"id": 363, "type": "=", "text": "=", "parent": 361, "children": [], "start_point": {"row": 60, "column": 10}, "end_point": {"row": 60, "column": 11}}, {"id": 364, "type": "number_literal", "text": "0", "parent": 361, "children": [], "start_point": {"row": 60, "column": 12}, "end_point": {"row": 60, "column": 13}}, {"id": 365, "type": "while_statement", "text": "while(true){\r\n \r\n if(i == size){\r\n size = 2 * size;\r\n line = realloc(line, size * sizeof(char));\r\n }\r\n\r\n c = getc(stdin);\r\n \r\n if(c == '\\n'){\r\n line[i++] = 0;\r\n break;\r\n }\r\n\r\n line[i++] = c;\r\n }", "parent": 324, "children": [366], "start_point": {"row": 62, "column": 4}, "end_point": {"row": 77, "column": 5}}, {"id": 366, "type": "parenthesized_expression", "text": "(true)", "parent": 365, "children": [367], "start_point": {"row": 62, "column": 9}, "end_point": {"row": 62, "column": 15}}, {"id": 367, "type": "true", "text": "true", "parent": 366, "children": [], "start_point": {"row": 62, "column": 10}, "end_point": {"row": 62, "column": 14}}, {"id": 368, "type": "if_statement", "text": "if(i == size){\r\n size = 2 * size;\r\n line = realloc(line, size * sizeof(char));\r\n }", "parent": 365, "children": [369], "start_point": {"row": 64, "column": 8}, "end_point": {"row": 67, "column": 9}}, {"id": 369, "type": "parenthesized_expression", "text": "(i == size)", "parent": 368, "children": [370], "start_point": {"row": 64, "column": 10}, "end_point": {"row": 64, "column": 21}}, {"id": 370, "type": "binary_expression", "text": "i == size", "parent": 369, "children": [371, 372, 373], "start_point": {"row": 64, "column": 11}, "end_point": {"row": 64, "column": 20}}, {"id": 371, "type": "identifier", "text": "i", "parent": 370, "children": [], "start_point": {"row": 64, "column": 11}, "end_point": {"row": 64, "column": 12}}, {"id": 372, "type": "==", "text": "==", "parent": 370, "children": [], "start_point": {"row": 64, "column": 13}, "end_point": {"row": 64, "column": 15}}, {"id": 373, "type": "identifier", "text": "size", "parent": 370, "children": [], "start_point": {"row": 64, "column": 16}, "end_point": {"row": 64, "column": 20}}, {"id": 374, "type": "assignment_expression", "text": "size = 2 * size", "parent": 368, "children": [375, 376, 377], "start_point": {"row": 65, "column": 12}, "end_point": {"row": 65, "column": 27}}, {"id": 375, "type": "identifier", "text": "size", "parent": 374, "children": [], "start_point": {"row": 65, "column": 12}, "end_point": {"row": 65, "column": 16}}, {"id": 376, "type": "=", "text": "=", "parent": 374, "children": [], "start_point": {"row": 65, "column": 17}, "end_point": {"row": 65, "column": 18}}, {"id": 377, "type": "binary_expression", "text": "2 * size", "parent": 374, "children": [378, 379, 380], "start_point": {"row": 65, "column": 19}, "end_point": {"row": 65, "column": 27}}, {"id": 378, "type": "number_literal", "text": "2", "parent": 377, "children": [], "start_point": {"row": 65, "column": 19}, "end_point": {"row": 65, "column": 20}}, {"id": 379, "type": "*", "text": "*", "parent": 377, "children": [], "start_point": {"row": 65, "column": 21}, "end_point": {"row": 65, "column": 22}}, {"id": 380, "type": "identifier", "text": "size", "parent": 377, "children": [], "start_point": {"row": 65, "column": 23}, "end_point": {"row": 65, "column": 27}}, {"id": 381, "type": "assignment_expression", "text": "line = realloc(line, size * sizeof(char))", "parent": 368, "children": [382, 383, 384], "start_point": {"row": 66, "column": 12}, "end_point": {"row": 66, "column": 53}}, {"id": 382, "type": "identifier", "text": "line", "parent": 381, "children": [], "start_point": {"row": 66, "column": 12}, "end_point": {"row": 66, "column": 16}}, {"id": 383, "type": "=", "text": "=", "parent": 381, "children": [], "start_point": {"row": 66, "column": 17}, "end_point": {"row": 66, "column": 18}}, {"id": 384, "type": "call_expression", "text": "realloc(line, size * sizeof(char))", "parent": 381, "children": [385, 386], "start_point": {"row": 66, "column": 19}, "end_point": {"row": 66, "column": 53}}, {"id": 385, "type": "identifier", "text": "realloc", "parent": 384, "children": [], "start_point": {"row": 66, "column": 19}, "end_point": {"row": 66, "column": 26}}, {"id": 386, "type": "argument_list", "text": "(line, size * sizeof(char))", "parent": 384, "children": [387, 388], "start_point": {"row": 66, "column": 26}, "end_point": {"row": 66, "column": 53}}, {"id": 387, "type": "identifier", "text": "line", "parent": 386, "children": [], "start_point": {"row": 66, "column": 27}, "end_point": {"row": 66, "column": 31}}, {"id": 388, "type": "binary_expression", "text": "size * sizeof(char)", "parent": 386, "children": [389, 390, 391], "start_point": {"row": 66, "column": 33}, "end_point": {"row": 66, "column": 52}}, {"id": 389, "type": "identifier", "text": "size", "parent": 388, "children": [], "start_point": {"row": 66, "column": 33}, "end_point": {"row": 66, "column": 37}}, {"id": 390, "type": "*", "text": "*", "parent": 388, "children": [], "start_point": {"row": 66, "column": 38}, "end_point": {"row": 66, "column": 39}}, {"id": 391, "type": "sizeof_expression", "text": "sizeof(char)", "parent": 388, "children": [392], "start_point": {"row": 66, "column": 40}, "end_point": {"row": 66, "column": 52}}, {"id": 392, "type": "type_descriptor", "text": "char", "parent": 391, "children": [393], "start_point": {"row": 66, "column": 47}, "end_point": {"row": 66, "column": 51}}, {"id": 393, "type": "primitive_type", "text": "char", "parent": 392, "children": [], "start_point": {"row": 66, "column": 47}, "end_point": {"row": 66, "column": 51}}, {"id": 394, "type": "assignment_expression", "text": "c = getc(stdin)", "parent": 365, "children": [395, 396, 397], "start_point": {"row": 69, "column": 8}, "end_point": {"row": 69, "column": 23}}, {"id": 395, "type": "identifier", "text": "c", "parent": 394, "children": [], "start_point": {"row": 69, "column": 8}, "end_point": {"row": 69, "column": 9}}, {"id": 396, "type": "=", "text": "=", "parent": 394, "children": [], "start_point": {"row": 69, "column": 10}, "end_point": {"row": 69, "column": 11}}, {"id": 397, "type": "call_expression", "text": "getc(stdin)", "parent": 394, "children": [398, 399], "start_point": {"row": 69, "column": 12}, "end_point": {"row": 69, "column": 23}}, {"id": 398, "type": "identifier", "text": "getc", "parent": 397, "children": [], "start_point": {"row": 69, "column": 12}, "end_point": {"row": 69, "column": 16}}, {"id": 399, "type": "argument_list", "text": "(stdin)", "parent": 397, "children": [400], "start_point": {"row": 69, "column": 16}, "end_point": {"row": 69, "column": 23}}, {"id": 400, "type": "identifier", "text": "stdin", "parent": 399, "children": [], "start_point": {"row": 69, "column": 17}, "end_point": {"row": 69, "column": 22}}, {"id": 401, "type": "if_statement", "text": "if(c == '\\n'){\r\n line[i++] = 0;\r\n break;\r\n }", "parent": 365, "children": [402], "start_point": {"row": 71, "column": 8}, "end_point": {"row": 74, "column": 9}}, {"id": 402, "type": "parenthesized_expression", "text": "(c == '\\n')", "parent": 401, "children": [403], "start_point": {"row": 71, "column": 10}, "end_point": {"row": 71, "column": 21}}, {"id": 403, "type": "binary_expression", "text": "c == '\\n'", "parent": 402, "children": [404, 405, 406], "start_point": {"row": 71, "column": 11}, "end_point": {"row": 71, "column": 20}}, {"id": 404, "type": "identifier", "text": "c", "parent": 403, "children": [], "start_point": {"row": 71, "column": 11}, "end_point": {"row": 71, "column": 12}}, {"id": 405, "type": "==", "text": "==", "parent": 403, "children": [], "start_point": {"row": 71, "column": 13}, "end_point": {"row": 71, "column": 15}}, {"id": 406, "type": "char_literal", "text": "'\\n'", "parent": 403, "children": [407, 408, 409], "start_point": {"row": 71, "column": 16}, "end_point": {"row": 71, "column": 20}}, {"id": 407, "type": "'", "text": "'", "parent": 406, "children": [], "start_point": {"row": 71, "column": 16}, "end_point": {"row": 71, "column": 17}}, {"id": 408, "type": "escape_sequence", "text": "\\n", "parent": 406, "children": [], "start_point": {"row": 71, "column": 17}, "end_point": {"row": 71, "column": 19}}, {"id": 409, "type": "'", "text": "'", "parent": 406, "children": [], "start_point": {"row": 71, "column": 19}, "end_point": {"row": 71, "column": 20}}, {"id": 410, "type": "assignment_expression", "text": "line[i++] = 0", "parent": 401, "children": [411, 416, 417], "start_point": {"row": 72, "column": 12}, "end_point": {"row": 72, "column": 25}}, {"id": 411, "type": "subscript_expression", "text": "line[i++]", "parent": 410, "children": [412, 413], "start_point": {"row": 72, "column": 12}, "end_point": {"row": 72, "column": 21}}, {"id": 412, "type": "identifier", "text": "line", "parent": 411, "children": [], "start_point": {"row": 72, "column": 12}, "end_point": {"row": 72, "column": 16}}, {"id": 413, "type": "update_expression", "text": "i++", "parent": 411, "children": [414, 415], "start_point": {"row": 72, "column": 17}, "end_point": {"row": 72, "column": 20}}, {"id": 414, "type": "identifier", "text": "i", "parent": 413, "children": [], "start_point": {"row": 72, "column": 17}, "end_point": {"row": 72, "column": 18}}, {"id": 415, "type": "++", "text": "++", "parent": 413, "children": [], "start_point": {"row": 72, "column": 18}, "end_point": {"row": 72, "column": 20}}, {"id": 416, "type": "=", "text": "=", "parent": 410, "children": [], "start_point": {"row": 72, "column": 22}, "end_point": {"row": 72, "column": 23}}, {"id": 417, "type": "number_literal", "text": "0", "parent": 410, "children": [], "start_point": {"row": 72, "column": 24}, "end_point": {"row": 72, "column": 25}}, {"id": 418, "type": "break_statement", "text": "break;", "parent": 401, "children": [419], "start_point": {"row": 73, "column": 12}, "end_point": {"row": 73, "column": 18}}, {"id": 419, "type": "break", "text": "break", "parent": 418, "children": [], "start_point": {"row": 73, "column": 12}, "end_point": {"row": 73, "column": 17}}, {"id": 420, "type": "assignment_expression", "text": "line[i++] = c", "parent": 365, "children": [421, 426, 427], "start_point": {"row": 76, "column": 8}, "end_point": {"row": 76, "column": 21}}, {"id": 421, "type": "subscript_expression", "text": "line[i++]", "parent": 420, "children": [422, 423], "start_point": {"row": 76, "column": 8}, "end_point": {"row": 76, "column": 17}}, {"id": 422, "type": "identifier", "text": "line", "parent": 421, "children": [], "start_point": {"row": 76, "column": 8}, "end_point": {"row": 76, "column": 12}}, {"id": 423, "type": "update_expression", "text": "i++", "parent": 421, "children": [424, 425], "start_point": {"row": 76, "column": 13}, "end_point": {"row": 76, "column": 16}}, {"id": 424, "type": "identifier", "text": "i", "parent": 423, "children": [], "start_point": {"row": 76, "column": 13}, "end_point": {"row": 76, "column": 14}}, {"id": 425, "type": "++", "text": "++", "parent": 423, "children": [], "start_point": {"row": 76, "column": 14}, "end_point": {"row": 76, "column": 16}}, {"id": 426, "type": "=", "text": "=", "parent": 420, "children": [], "start_point": {"row": 76, "column": 18}, "end_point": {"row": 76, "column": 19}}, {"id": 427, "type": "identifier", "text": "c", "parent": 420, "children": [], "start_point": {"row": 76, "column": 20}, "end_point": {"row": 76, "column": 21}}, {"id": 428, "type": "assignment_expression", "text": "line = realloc(line, i * sizeof(char))", "parent": 324, "children": [429, 430, 431], "start_point": {"row": 79, "column": 4}, "end_point": {"row": 79, "column": 42}}, {"id": 429, "type": "identifier", "text": "line", "parent": 428, "children": [], "start_point": {"row": 79, "column": 4}, "end_point": {"row": 79, "column": 8}}, {"id": 430, "type": "=", "text": "=", "parent": 428, "children": [], "start_point": {"row": 79, "column": 9}, "end_point": {"row": 79, "column": 10}}, {"id": 431, "type": "call_expression", "text": "realloc(line, i * sizeof(char))", "parent": 428, "children": [432, 433], "start_point": {"row": 79, "column": 11}, "end_point": {"row": 79, "column": 42}}, {"id": 432, "type": "identifier", "text": "realloc", "parent": 431, "children": [], "start_point": {"row": 79, "column": 11}, "end_point": {"row": 79, "column": 18}}, {"id": 433, "type": "argument_list", "text": "(line, i * sizeof(char))", "parent": 431, "children": [434, 435], "start_point": {"row": 79, "column": 18}, "end_point": {"row": 79, "column": 42}}, {"id": 434, "type": "identifier", "text": "line", "parent": 433, "children": [], "start_point": {"row": 79, "column": 19}, "end_point": {"row": 79, "column": 23}}, {"id": 435, "type": "binary_expression", "text": "i * sizeof(char)", "parent": 433, "children": [436, 437, 438], "start_point": {"row": 79, "column": 25}, "end_point": {"row": 79, "column": 41}}, {"id": 436, "type": "identifier", "text": "i", "parent": 435, "children": [], "start_point": {"row": 79, "column": 25}, "end_point": {"row": 79, "column": 26}}, {"id": 437, "type": "*", "text": "*", "parent": 435, "children": [], "start_point": {"row": 79, "column": 27}, "end_point": {"row": 79, "column": 28}}, {"id": 438, "type": "sizeof_expression", "text": "sizeof(char)", "parent": 435, "children": [439], "start_point": {"row": 79, "column": 29}, "end_point": {"row": 79, "column": 41}}, {"id": 439, "type": "type_descriptor", "text": "char", "parent": 438, "children": [440], "start_point": {"row": 79, "column": 36}, "end_point": {"row": 79, "column": 40}}, {"id": 440, "type": "primitive_type", "text": "char", "parent": 439, "children": [], "start_point": {"row": 79, "column": 36}, "end_point": {"row": 79, "column": 40}}, {"id": 441, "type": "return_statement", "text": "return line;", "parent": 324, "children": [442], "start_point": {"row": 81, "column": 4}, "end_point": {"row": 81, "column": 16}}, {"id": 442, "type": "identifier", "text": "line", "parent": 441, "children": [], "start_point": {"row": 81, "column": 11}, "end_point": {"row": 81, "column": 15}}, {"id": 443, "type": "function_definition", "text": "char **readLines(){\r\n int size = 5;\r\n const char *end = \"end\";\r\n char **lines = malloc(sizeof(char *) * size);\r\n int i = 0;\r\n\r\n while(true){\r\n char *next = readLine();\r\n\r\n if(!strcmp(next, &end[0])){\r\n free(next);\r\n lines[i++] = NULL;\r\n break;\r\n }\r\n\r\n lines[i++] = next;\r\n\r\n // printf(\"i: %d/%d, %s\\n\", i, size, lines[i - 1]);\r\n \r\n if(i == size){\r\n size = 2 * size;\r\n lines = realloc(lines, sizeof(char *) * size);\r\n }\r\n }\r\n \r\n lines = realloc(lines, i * sizeof(char *));\r\n\r\n return lines;\r\n}", "parent": null, "children": [444, 445], "start_point": {"row": 84, "column": 0}, "end_point": {"row": 112, "column": 1}}, {"id": 444, "type": "primitive_type", "text": "char", "parent": 443, "children": [], "start_point": {"row": 84, "column": 0}, "end_point": {"row": 84, "column": 4}}, {"id": 445, "type": "pointer_declarator", "text": "**readLines()", "parent": 443, "children": [446, 447], "start_point": {"row": 84, "column": 5}, "end_point": {"row": 84, "column": 18}}, {"id": 446, "type": "*", "text": "*", "parent": 445, "children": [], "start_point": {"row": 84, "column": 5}, "end_point": {"row": 84, "column": 6}}, {"id": 447, "type": "pointer_declarator", "text": "*readLines()", "parent": 445, "children": [448, 449], "start_point": {"row": 84, "column": 6}, "end_point": {"row": 84, "column": 18}}, {"id": 448, "type": "*", "text": "*", "parent": 447, "children": [], "start_point": {"row": 84, "column": 6}, "end_point": {"row": 84, "column": 7}}, {"id": 449, "type": "function_declarator", "text": "readLines()", "parent": 447, "children": [450, 451], "start_point": {"row": 84, "column": 7}, "end_point": {"row": 84, "column": 18}}, {"id": 450, "type": "identifier", "text": "readLines", "parent": 449, "children": [], "start_point": {"row": 84, "column": 7}, "end_point": {"row": 84, "column": 16}}, {"id": 451, "type": "parameter_list", "text": "()", "parent": 449, "children": [], "start_point": {"row": 84, "column": 16}, "end_point": {"row": 84, "column": 18}}, {"id": 452, "type": "declaration", "text": "int size = 5;", "parent": 443, "children": [453, 454], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 17}}, {"id": 453, "type": "primitive_type", "text": "int", "parent": 452, "children": [], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 7}}, {"id": 454, "type": "init_declarator", "text": "size = 5", "parent": 452, "children": [455, 456, 457], "start_point": {"row": 85, "column": 8}, "end_point": {"row": 85, "column": 16}}, {"id": 455, "type": "identifier", "text": "size", "parent": 454, "children": [], "start_point": {"row": 85, "column": 8}, "end_point": {"row": 85, "column": 12}}, {"id": 456, "type": "=", "text": "=", "parent": 454, "children": [], "start_point": {"row": 85, "column": 13}, "end_point": {"row": 85, "column": 14}}, {"id": 457, "type": "number_literal", "text": "5", "parent": 454, "children": [], "start_point": {"row": 85, "column": 15}, "end_point": {"row": 85, "column": 16}}, {"id": 458, "type": "declaration", "text": "const char *end = \"end\";", "parent": 443, "children": [459, 460], "start_point": {"row": 86, "column": 4}, "end_point": {"row": 86, "column": 28}}, {"id": 459, "type": "primitive_type", "text": "char", "parent": 458, "children": [], "start_point": {"row": 86, "column": 10}, "end_point": {"row": 86, "column": 14}}, {"id": 460, "type": "init_declarator", "text": "*end = \"end\"", "parent": 458, "children": [461, 463, 464], "start_point": {"row": 86, "column": 15}, "end_point": {"row": 86, "column": 27}}, {"id": 461, "type": "pointer_declarator", "text": "*end", "parent": 460, "children": [462], "start_point": {"row": 86, "column": 15}, "end_point": {"row": 86, "column": 19}}, {"id": 462, "type": "*", "text": "*", "parent": 461, "children": [], "start_point": {"row": 86, "column": 15}, "end_point": {"row": 86, "column": 16}}, {"id": 463, "type": "=", "text": "=", "parent": 460, "children": [], "start_point": {"row": 86, "column": 20}, "end_point": {"row": 86, "column": 21}}, {"id": 464, "type": "string_literal", "text": "\"end\"", "parent": 460, "children": [], "start_point": {"row": 86, "column": 22}, "end_point": {"row": 86, "column": 27}}, {"id": 465, "type": "declaration", "text": "char **lines = malloc(sizeof(char *) * size);", "parent": 443, "children": [466, 467], "start_point": {"row": 87, "column": 4}, "end_point": {"row": 87, "column": 49}}, {"id": 466, "type": "primitive_type", "text": "char", "parent": 465, "children": [], "start_point": {"row": 87, "column": 4}, "end_point": {"row": 87, "column": 8}}, {"id": 467, "type": "init_declarator", "text": "**lines = malloc(sizeof(char *) * size)", "parent": 465, "children": [468, 473, 474], "start_point": {"row": 87, "column": 9}, "end_point": {"row": 87, "column": 48}}, {"id": 468, "type": "pointer_declarator", "text": "**lines", "parent": 467, "children": [469, 470], "start_point": {"row": 87, "column": 9}, "end_point": {"row": 87, "column": 16}}, {"id": 469, "type": "*", "text": "*", "parent": 468, "children": [], "start_point": {"row": 87, "column": 9}, "end_point": {"row": 87, "column": 10}}, {"id": 470, "type": "pointer_declarator", "text": "*lines", "parent": 468, "children": [471, 472], "start_point": {"row": 87, "column": 10}, "end_point": {"row": 87, "column": 16}}, {"id": 471, "type": "*", "text": "*", "parent": 470, "children": [], "start_point": {"row": 87, "column": 10}, "end_point": {"row": 87, "column": 11}}, {"id": 472, "type": "identifier", "text": "lines", "parent": 470, "children": [], "start_point": {"row": 87, "column": 11}, "end_point": {"row": 87, "column": 16}}, {"id": 473, "type": "=", "text": "=", "parent": 467, "children": [], "start_point": {"row": 87, "column": 17}, "end_point": {"row": 87, "column": 18}}, {"id": 474, "type": "call_expression", "text": "malloc(sizeof(char *) * size)", "parent": 467, "children": [475, 476], "start_point": {"row": 87, "column": 19}, "end_point": {"row": 87, "column": 48}}, {"id": 475, "type": "identifier", "text": "malloc", "parent": 474, "children": [], "start_point": {"row": 87, "column": 19}, "end_point": {"row": 87, "column": 25}}, {"id": 476, "type": "argument_list", "text": "(sizeof(char *) * size)", "parent": 474, "children": [477], "start_point": {"row": 87, "column": 25}, "end_point": {"row": 87, "column": 48}}, {"id": 477, "type": "binary_expression", "text": "sizeof(char *) * size", "parent": 476, "children": [478, 483, 484], "start_point": {"row": 87, "column": 26}, "end_point": {"row": 87, "column": 47}}, {"id": 478, "type": "sizeof_expression", "text": "sizeof(char *)", "parent": 477, "children": [479], "start_point": {"row": 87, "column": 26}, "end_point": {"row": 87, "column": 40}}, {"id": 479, "type": "type_descriptor", "text": "char *", "parent": 478, "children": [480, 481], "start_point": {"row": 87, "column": 33}, "end_point": {"row": 87, "column": 39}}, {"id": 480, "type": "primitive_type", "text": "char", "parent": 479, "children": [], "start_point": {"row": 87, "column": 33}, "end_point": {"row": 87, "column": 37}}, {"id": 481, "type": "abstract_pointer_declarator", "text": "*", "parent": 479, "children": [482], "start_point": {"row": 87, "column": 38}, "end_point": {"row": 87, "column": 39}}, {"id": 482, "type": "*", "text": "*", "parent": 481, "children": [], "start_point": {"row": 87, "column": 38}, "end_point": {"row": 87, "column": 39}}, {"id": 483, "type": "*", "text": "*", "parent": 477, "children": [], "start_point": {"row": 87, "column": 41}, "end_point": {"row": 87, "column": 42}}, {"id": 484, "type": "identifier", "text": "size", "parent": 477, "children": [], "start_point": {"row": 87, "column": 43}, "end_point": {"row": 87, "column": 47}}, {"id": 485, "type": "declaration", "text": "int i = 0;", "parent": 443, "children": [486, 487], "start_point": {"row": 88, "column": 4}, "end_point": {"row": 88, "column": 14}}, {"id": 486, "type": "primitive_type", "text": "int", "parent": 485, "children": [], "start_point": {"row": 88, "column": 4}, "end_point": {"row": 88, "column": 7}}, {"id": 487, "type": "init_declarator", "text": "i = 0", "parent": 485, "children": [488, 489, 490], "start_point": {"row": 88, "column": 8}, "end_point": {"row": 88, "column": 13}}, {"id": 488, "type": "identifier", "text": "i", "parent": 487, "children": [], "start_point": {"row": 88, "column": 8}, "end_point": {"row": 88, "column": 9}}, {"id": 489, "type": "=", "text": "=", "parent": 487, "children": [], "start_point": {"row": 88, "column": 10}, "end_point": {"row": 88, "column": 11}}, {"id": 490, "type": "number_literal", "text": "0", "parent": 487, "children": [], "start_point": {"row": 88, "column": 12}, "end_point": {"row": 88, "column": 13}}, {"id": 491, "type": "while_statement", "text": "while(true){\r\n char *next = readLine();\r\n\r\n if(!strcmp(next, &end[0])){\r\n free(next);\r\n lines[i++] = NULL;\r\n break;\r\n }\r\n\r\n lines[i++] = next;\r\n\r\n // printf(\"i: %d/%d, %s\\n\", i, size, lines[i - 1]);\r\n \r\n if(i == size){\r\n size = 2 * size;\r\n lines = realloc(lines, sizeof(char *) * size);\r\n }\r\n }", "parent": 443, "children": [492], "start_point": {"row": 90, "column": 4}, "end_point": {"row": 107, "column": 5}}, {"id": 492, "type": "parenthesized_expression", "text": "(true)", "parent": 491, "children": [493], "start_point": {"row": 90, "column": 9}, "end_point": {"row": 90, "column": 15}}, {"id": 493, "type": "true", "text": "true", "parent": 492, "children": [], "start_point": {"row": 90, "column": 10}, "end_point": {"row": 90, "column": 14}}, {"id": 494, "type": "declaration", "text": "char *next = readLine();", "parent": 491, "children": [495, 496], "start_point": {"row": 91, "column": 8}, "end_point": {"row": 91, "column": 32}}, {"id": 495, "type": "primitive_type", "text": "char", "parent": 494, "children": [], "start_point": {"row": 91, "column": 8}, "end_point": {"row": 91, "column": 12}}, {"id": 496, "type": "init_declarator", "text": "*next = readLine()", "parent": 494, "children": [497, 500, 501], "start_point": {"row": 91, "column": 13}, "end_point": {"row": 91, "column": 31}}, {"id": 497, "type": "pointer_declarator", "text": "*next", "parent": 496, "children": [498, 499], "start_point": {"row": 91, "column": 13}, "end_point": {"row": 91, "column": 18}}, {"id": 498, "type": "*", "text": "*", "parent": 497, "children": [], "start_point": {"row": 91, "column": 13}, "end_point": {"row": 91, "column": 14}}, {"id": 499, "type": "identifier", "text": "next", "parent": 497, "children": [], "start_point": {"row": 91, "column": 14}, "end_point": {"row": 91, "column": 18}}, {"id": 500, "type": "=", "text": "=", "parent": 496, "children": [], "start_point": {"row": 91, "column": 19}, "end_point": {"row": 91, "column": 20}}, {"id": 501, "type": "call_expression", "text": "readLine()", "parent": 496, "children": [502, 503], "start_point": {"row": 91, "column": 21}, "end_point": {"row": 91, "column": 31}}, {"id": 502, "type": "identifier", "text": "readLine", "parent": 501, "children": [], "start_point": {"row": 91, "column": 21}, "end_point": {"row": 91, "column": 29}}, {"id": 503, "type": "argument_list", "text": "()", "parent": 501, "children": [], "start_point": {"row": 91, "column": 29}, "end_point": {"row": 91, "column": 31}}, {"id": 504, "type": "if_statement", "text": "if(!strcmp(next, &end[0])){\r\n free(next);\r\n lines[i++] = NULL;\r\n break;\r\n }", "parent": 491, "children": [505], "start_point": {"row": 93, "column": 8}, "end_point": {"row": 97, "column": 9}}, {"id": 505, "type": "parenthesized_expression", "text": "(!strcmp(next, &end[0]))", "parent": 504, "children": [506], "start_point": {"row": 93, "column": 10}, "end_point": {"row": 93, "column": 34}}, {"id": 506, "type": "unary_expression", "text": "!strcmp(next, &end[0])", "parent": 505, "children": [507, 508], "start_point": {"row": 93, "column": 11}, "end_point": {"row": 93, "column": 33}}, {"id": 507, "type": "!", "text": "!", "parent": 506, "children": [], "start_point": {"row": 93, "column": 11}, "end_point": {"row": 93, "column": 12}}, {"id": 508, "type": "call_expression", "text": "strcmp(next, &end[0])", "parent": 506, "children": [509, 510], "start_point": {"row": 93, "column": 12}, "end_point": {"row": 93, "column": 33}}, {"id": 509, "type": "identifier", "text": "strcmp", "parent": 508, "children": [], "start_point": {"row": 93, "column": 12}, "end_point": {"row": 93, "column": 18}}, {"id": 510, "type": "argument_list", "text": "(next, &end[0])", "parent": 508, "children": [511, 512], "start_point": {"row": 93, "column": 18}, "end_point": {"row": 93, "column": 33}}, {"id": 511, "type": "identifier", "text": "next", "parent": 510, "children": [], "start_point": {"row": 93, "column": 19}, "end_point": {"row": 93, "column": 23}}, {"id": 512, "type": "pointer_expression", "text": "&end[0]", "parent": 510, "children": [513], "start_point": {"row": 93, "column": 25}, "end_point": {"row": 93, "column": 32}}, {"id": 513, "type": "subscript_expression", "text": "end[0]", "parent": 512, "children": [514], "start_point": {"row": 93, "column": 26}, "end_point": {"row": 93, "column": 32}}, {"id": 514, "type": "number_literal", "text": "0", "parent": 513, "children": [], "start_point": {"row": 93, "column": 30}, "end_point": {"row": 93, "column": 31}}, {"id": 515, "type": "call_expression", "text": "free(next)", "parent": 504, "children": [516, 517], "start_point": {"row": 94, "column": 12}, "end_point": {"row": 94, "column": 22}}, {"id": 516, "type": "identifier", "text": "free", "parent": 515, "children": [], "start_point": {"row": 94, "column": 12}, "end_point": {"row": 94, "column": 16}}, {"id": 517, "type": "argument_list", "text": "(next)", "parent": 515, "children": [518], "start_point": {"row": 94, "column": 16}, "end_point": {"row": 94, "column": 22}}, {"id": 518, "type": "identifier", "text": "next", "parent": 517, "children": [], "start_point": {"row": 94, "column": 17}, "end_point": {"row": 94, "column": 21}}, {"id": 519, "type": "assignment_expression", "text": "lines[i++] = NULL", "parent": 504, "children": [520, 525, 526], "start_point": {"row": 95, "column": 12}, "end_point": {"row": 95, "column": 29}}, {"id": 520, "type": "subscript_expression", "text": "lines[i++]", "parent": 519, "children": [521, 522], "start_point": {"row": 95, "column": 12}, "end_point": {"row": 95, "column": 22}}, {"id": 521, "type": "identifier", "text": "lines", "parent": 520, "children": [], "start_point": {"row": 95, "column": 12}, "end_point": {"row": 95, "column": 17}}, {"id": 522, "type": "update_expression", "text": "i++", "parent": 520, "children": [523, 524], "start_point": {"row": 95, "column": 18}, "end_point": {"row": 95, "column": 21}}, {"id": 523, "type": "identifier", "text": "i", "parent": 522, "children": [], "start_point": {"row": 95, "column": 18}, "end_point": {"row": 95, "column": 19}}, {"id": 524, "type": "++", "text": "++", "parent": 522, "children": [], "start_point": {"row": 95, "column": 19}, "end_point": {"row": 95, "column": 21}}, {"id": 525, "type": "=", "text": "=", "parent": 519, "children": [], "start_point": {"row": 95, "column": 23}, "end_point": {"row": 95, "column": 24}}, {"id": 526, "type": "null", "text": "NULL", "parent": 519, "children": [527], "start_point": {"row": 95, "column": 25}, "end_point": {"row": 95, "column": 29}}, {"id": 527, "type": "NULL", "text": "NULL", "parent": 526, "children": [], "start_point": {"row": 95, "column": 25}, "end_point": {"row": 95, "column": 29}}, {"id": 528, "type": "break_statement", "text": "break;", "parent": 504, "children": [529], "start_point": {"row": 96, "column": 12}, "end_point": {"row": 96, "column": 18}}, {"id": 529, "type": "break", "text": "break", "parent": 528, "children": [], "start_point": {"row": 96, "column": 12}, "end_point": {"row": 96, "column": 17}}, {"id": 530, "type": "assignment_expression", "text": "lines[i++] = next", "parent": 491, "children": [531, 536, 537], "start_point": {"row": 99, "column": 8}, "end_point": {"row": 99, "column": 25}}, {"id": 531, "type": "subscript_expression", "text": "lines[i++]", "parent": 530, "children": [532, 533], "start_point": {"row": 99, "column": 8}, "end_point": {"row": 99, "column": 18}}, {"id": 532, "type": "identifier", "text": "lines", "parent": 531, "children": [], "start_point": {"row": 99, "column": 8}, "end_point": {"row": 99, "column": 13}}, {"id": 533, "type": "update_expression", "text": "i++", "parent": 531, "children": [534, 535], "start_point": {"row": 99, "column": 14}, "end_point": {"row": 99, "column": 17}}, {"id": 534, "type": "identifier", "text": "i", "parent": 533, "children": [], "start_point": {"row": 99, "column": 14}, "end_point": {"row": 99, "column": 15}}, {"id": 535, "type": "++", "text": "++", "parent": 533, "children": [], "start_point": {"row": 99, "column": 15}, "end_point": {"row": 99, "column": 17}}, {"id": 536, "type": "=", "text": "=", "parent": 530, "children": [], "start_point": {"row": 99, "column": 19}, "end_point": {"row": 99, "column": 20}}, {"id": 537, "type": "identifier", "text": "next", "parent": 530, "children": [], "start_point": {"row": 99, "column": 21}, "end_point": {"row": 99, "column": 25}}, {"id": 538, "type": "if_statement", "text": "if(i == size){\r\n size = 2 * size;\r\n lines = realloc(lines, sizeof(char *) * size);\r\n }", "parent": 491, "children": [539], "start_point": {"row": 103, "column": 8}, "end_point": {"row": 106, "column": 9}}, {"id": 539, "type": "parenthesized_expression", "text": "(i == size)", "parent": 538, "children": [540], "start_point": {"row": 103, "column": 10}, "end_point": {"row": 103, "column": 21}}, {"id": 540, "type": "binary_expression", "text": "i == size", "parent": 539, "children": [541, 542, 543], "start_point": {"row": 103, "column": 11}, "end_point": {"row": 103, "column": 20}}, {"id": 541, "type": "identifier", "text": "i", "parent": 540, "children": [], "start_point": {"row": 103, "column": 11}, "end_point": {"row": 103, "column": 12}}, {"id": 542, "type": "==", "text": "==", "parent": 540, "children": [], "start_point": {"row": 103, "column": 13}, "end_point": {"row": 103, "column": 15}}, {"id": 543, "type": "identifier", "text": "size", "parent": 540, "children": [], "start_point": {"row": 103, "column": 16}, "end_point": {"row": 103, "column": 20}}, {"id": 544, "type": "assignment_expression", "text": "size = 2 * size", "parent": 538, "children": [545, 546, 547], "start_point": {"row": 104, "column": 12}, "end_point": {"row": 104, "column": 27}}, {"id": 545, "type": "identifier", "text": "size", "parent": 544, "children": [], "start_point": {"row": 104, "column": 12}, "end_point": {"row": 104, "column": 16}}, {"id": 546, "type": "=", "text": "=", "parent": 544, "children": [], "start_point": {"row": 104, "column": 17}, "end_point": {"row": 104, "column": 18}}, {"id": 547, "type": "binary_expression", "text": "2 * size", "parent": 544, "children": [548, 549, 550], "start_point": {"row": 104, "column": 19}, "end_point": {"row": 104, "column": 27}}, {"id": 548, "type": "number_literal", "text": "2", "parent": 547, "children": [], "start_point": {"row": 104, "column": 19}, "end_point": {"row": 104, "column": 20}}, {"id": 549, "type": "*", "text": "*", "parent": 547, "children": [], "start_point": {"row": 104, "column": 21}, "end_point": {"row": 104, "column": 22}}, {"id": 550, "type": "identifier", "text": "size", "parent": 547, "children": [], "start_point": {"row": 104, "column": 23}, "end_point": {"row": 104, "column": 27}}, {"id": 551, "type": "assignment_expression", "text": "lines = realloc(lines, sizeof(char *) * size)", "parent": 538, "children": [552, 553, 554], "start_point": {"row": 105, "column": 12}, "end_point": {"row": 105, "column": 57}}, {"id": 552, "type": "identifier", "text": "lines", "parent": 551, "children": [], "start_point": {"row": 105, "column": 12}, "end_point": {"row": 105, "column": 17}}, {"id": 553, "type": "=", "text": "=", "parent": 551, "children": [], "start_point": {"row": 105, "column": 18}, "end_point": {"row": 105, "column": 19}}, {"id": 554, "type": "call_expression", "text": "realloc(lines, sizeof(char *) * size)", "parent": 551, "children": [555, 556], "start_point": {"row": 105, "column": 20}, "end_point": {"row": 105, "column": 57}}, {"id": 555, "type": "identifier", "text": "realloc", "parent": 554, "children": [], "start_point": {"row": 105, "column": 20}, "end_point": {"row": 105, "column": 27}}, {"id": 556, "type": "argument_list", "text": "(lines, sizeof(char *) * size)", "parent": 554, "children": [557, 558], "start_point": {"row": 105, "column": 27}, "end_point": {"row": 105, "column": 57}}, {"id": 557, "type": "identifier", "text": "lines", "parent": 556, "children": [], "start_point": {"row": 105, "column": 28}, "end_point": {"row": 105, "column": 33}}, {"id": 558, "type": "binary_expression", "text": "sizeof(char *) * size", "parent": 556, "children": [559, 564, 565], "start_point": {"row": 105, "column": 35}, "end_point": {"row": 105, "column": 56}}, {"id": 559, "type": "sizeof_expression", "text": "sizeof(char *)", "parent": 558, "children": [560], "start_point": {"row": 105, "column": 35}, "end_point": {"row": 105, "column": 49}}, {"id": 560, "type": "type_descriptor", "text": "char *", "parent": 559, "children": [561, 562], "start_point": {"row": 105, "column": 42}, "end_point": {"row": 105, "column": 48}}, {"id": 561, "type": "primitive_type", "text": "char", "parent": 560, "children": [], "start_point": {"row": 105, "column": 42}, "end_point": {"row": 105, "column": 46}}, {"id": 562, "type": "abstract_pointer_declarator", "text": "*", "parent": 560, "children": [563], "start_point": {"row": 105, "column": 47}, "end_point": {"row": 105, "column": 48}}, {"id": 563, "type": "*", "text": "*", "parent": 562, "children": [], "start_point": {"row": 105, "column": 47}, "end_point": {"row": 105, "column": 48}}, {"id": 564, "type": "*", "text": "*", "parent": 558, "children": [], "start_point": {"row": 105, "column": 50}, "end_point": {"row": 105, "column": 51}}, {"id": 565, "type": "identifier", "text": "size", "parent": 558, "children": [], "start_point": {"row": 105, "column": 52}, "end_point": {"row": 105, "column": 56}}, {"id": 566, "type": "assignment_expression", "text": "lines = realloc(lines, i * sizeof(char *))", "parent": 443, "children": [567, 568, 569], "start_point": {"row": 109, "column": 4}, "end_point": {"row": 109, "column": 46}}, {"id": 567, "type": "identifier", "text": "lines", "parent": 566, "children": [], "start_point": {"row": 109, "column": 4}, "end_point": {"row": 109, "column": 9}}, {"id": 568, "type": "=", "text": "=", "parent": 566, "children": [], "start_point": {"row": 109, "column": 10}, "end_point": {"row": 109, "column": 11}}, {"id": 569, "type": "call_expression", "text": "realloc(lines, i * sizeof(char *))", "parent": 566, "children": [570, 571], "start_point": {"row": 109, "column": 12}, "end_point": {"row": 109, "column": 46}}, {"id": 570, "type": "identifier", "text": "realloc", "parent": 569, "children": [], "start_point": {"row": 109, "column": 12}, "end_point": {"row": 109, "column": 19}}, {"id": 571, "type": "argument_list", "text": "(lines, i * sizeof(char *))", "parent": 569, "children": [572, 573], "start_point": {"row": 109, "column": 19}, "end_point": {"row": 109, "column": 46}}, {"id": 572, "type": "identifier", "text": "lines", "parent": 571, "children": [], "start_point": {"row": 109, "column": 20}, "end_point": {"row": 109, "column": 25}}, {"id": 573, "type": "binary_expression", "text": "i * sizeof(char *)", "parent": 571, "children": [574, 575, 576], "start_point": {"row": 109, "column": 27}, "end_point": {"row": 109, "column": 45}}, {"id": 574, "type": "identifier", "text": "i", "parent": 573, "children": [], "start_point": {"row": 109, "column": 27}, "end_point": {"row": 109, "column": 28}}, {"id": 575, "type": "*", "text": "*", "parent": 573, "children": [], "start_point": {"row": 109, "column": 29}, "end_point": {"row": 109, "column": 30}}, {"id": 576, "type": "sizeof_expression", "text": "sizeof(char *)", "parent": 573, "children": [577], "start_point": {"row": 109, "column": 31}, "end_point": {"row": 109, "column": 45}}, {"id": 577, "type": "type_descriptor", "text": "char *", "parent": 576, "children": [578, 579], "start_point": {"row": 109, "column": 38}, "end_point": {"row": 109, "column": 44}}, {"id": 578, "type": "primitive_type", "text": "char", "parent": 577, "children": [], "start_point": {"row": 109, "column": 38}, "end_point": {"row": 109, "column": 42}}, {"id": 579, "type": "abstract_pointer_declarator", "text": "*", "parent": 577, "children": [580], "start_point": {"row": 109, "column": 43}, "end_point": {"row": 109, "column": 44}}, {"id": 580, "type": "*", "text": "*", "parent": 579, "children": [], "start_point": {"row": 109, "column": 43}, "end_point": {"row": 109, "column": 44}}, {"id": 581, "type": "return_statement", "text": "return lines;", "parent": 443, "children": [582], "start_point": {"row": 111, "column": 4}, "end_point": {"row": 111, "column": 17}}, {"id": 582, "type": "identifier", "text": "lines", "parent": 581, "children": [], "start_point": {"row": 111, "column": 11}, "end_point": {"row": 111, "column": 16}}, {"id": 583, "type": "function_definition", "text": "void freeLines(char **lines){\r\n int i = 0;\r\n \r\n while(lines[i] != NULL){\r\n free(lines[i++]);\r\n }\r\n\r\n free(lines);\r\n}", "parent": null, "children": [584, 585], "start_point": {"row": 114, "column": 0}, "end_point": {"row": 122, "column": 1}}, {"id": 584, "type": "primitive_type", "text": "void", "parent": 583, "children": [], "start_point": {"row": 114, "column": 0}, "end_point": {"row": 114, "column": 4}}, {"id": 585, "type": "function_declarator", "text": "freeLines(char **lines)", "parent": 583, "children": [586, 587], "start_point": {"row": 114, "column": 5}, "end_point": {"row": 114, "column": 28}}, {"id": 586, "type": "identifier", "text": "freeLines", "parent": 585, "children": [], "start_point": {"row": 114, "column": 5}, "end_point": {"row": 114, "column": 14}}, {"id": 587, "type": "parameter_list", "text": "(char **lines)", "parent": 585, "children": [588], "start_point": {"row": 114, "column": 14}, "end_point": {"row": 114, "column": 28}}, {"id": 588, "type": "parameter_declaration", "text": "char **lines", "parent": 587, "children": [589, 590], "start_point": {"row": 114, "column": 15}, "end_point": {"row": 114, "column": 27}}, {"id": 589, "type": "primitive_type", "text": "char", "parent": 588, "children": [], "start_point": {"row": 114, "column": 15}, "end_point": {"row": 114, "column": 19}}, {"id": 590, "type": "pointer_declarator", "text": "**lines", "parent": 588, "children": [591, 592], "start_point": {"row": 114, "column": 20}, "end_point": {"row": 114, "column": 27}}, {"id": 591, "type": "*", "text": "*", "parent": 590, "children": [], "start_point": {"row": 114, "column": 20}, "end_point": {"row": 114, "column": 21}}, {"id": 592, "type": "pointer_declarator", "text": "*lines", "parent": 590, "children": [593, 594], "start_point": {"row": 114, "column": 21}, "end_point": {"row": 114, "column": 27}}, {"id": 593, "type": "*", "text": "*", "parent": 592, "children": [], "start_point": {"row": 114, "column": 21}, "end_point": {"row": 114, "column": 22}}, {"id": 594, "type": "identifier", "text": "lines", "parent": 592, "children": [], "start_point": {"row": 114, "column": 22}, "end_point": {"row": 114, "column": 27}}, {"id": 595, "type": "declaration", "text": "int i = 0;", "parent": 583, "children": [596, 597], "start_point": {"row": 115, "column": 4}, "end_point": {"row": 115, "column": 14}}, {"id": 596, "type": "primitive_type", "text": "int", "parent": 595, "children": [], "start_point": {"row": 115, "column": 4}, "end_point": {"row": 115, "column": 7}}, {"id": 597, "type": "init_declarator", "text": "i = 0", "parent": 595, "children": [598, 599, 600], "start_point": {"row": 115, "column": 8}, "end_point": {"row": 115, "column": 13}}, {"id": 598, "type": "identifier", "text": "i", "parent": 597, "children": [], "start_point": {"row": 115, "column": 8}, "end_point": {"row": 115, "column": 9}}, {"id": 599, "type": "=", "text": "=", "parent": 597, "children": [], "start_point": {"row": 115, "column": 10}, "end_point": {"row": 115, "column": 11}}, {"id": 600, "type": "number_literal", "text": "0", "parent": 597, "children": [], "start_point": {"row": 115, "column": 12}, "end_point": {"row": 115, "column": 13}}, {"id": 601, "type": "while_statement", "text": "while(lines[i] != NULL){\r\n free(lines[i++]);\r\n }", "parent": 583, "children": [602], "start_point": {"row": 117, "column": 4}, "end_point": {"row": 119, "column": 5}}, {"id": 602, "type": "parenthesized_expression", "text": "(lines[i] != NULL)", "parent": 601, "children": [603], "start_point": {"row": 117, "column": 9}, "end_point": {"row": 117, "column": 27}}, {"id": 603, "type": "binary_expression", "text": "lines[i] != NULL", "parent": 602, "children": [604, 607, 608], "start_point": {"row": 117, "column": 10}, "end_point": {"row": 117, "column": 26}}, {"id": 604, "type": "subscript_expression", "text": "lines[i]", "parent": 603, "children": [605, 606], "start_point": {"row": 117, "column": 10}, "end_point": {"row": 117, "column": 18}}, {"id": 605, "type": "identifier", "text": "lines", "parent": 604, "children": [], "start_point": {"row": 117, "column": 10}, "end_point": {"row": 117, "column": 15}}, {"id": 606, "type": "identifier", "text": "i", "parent": 604, "children": [], "start_point": {"row": 117, "column": 16}, "end_point": {"row": 117, "column": 17}}, {"id": 607, "type": "!=", "text": "!=", "parent": 603, "children": [], "start_point": {"row": 117, "column": 19}, "end_point": {"row": 117, "column": 21}}, {"id": 608, "type": "null", "text": "NULL", "parent": 603, "children": [609], "start_point": {"row": 117, "column": 22}, "end_point": {"row": 117, "column": 26}}, {"id": 609, "type": "NULL", "text": "NULL", "parent": 608, "children": [], "start_point": {"row": 117, "column": 22}, "end_point": {"row": 117, "column": 26}}, {"id": 610, "type": "call_expression", "text": "free(lines[i++])", "parent": 601, "children": [611, 612], "start_point": {"row": 118, "column": 8}, "end_point": {"row": 118, "column": 24}}, {"id": 611, "type": "identifier", "text": "free", "parent": 610, "children": [], "start_point": {"row": 118, "column": 8}, "end_point": {"row": 118, "column": 12}}, {"id": 612, "type": "argument_list", "text": "(lines[i++])", "parent": 610, "children": [613], "start_point": {"row": 118, "column": 12}, "end_point": {"row": 118, "column": 24}}, {"id": 613, "type": "subscript_expression", "text": "lines[i++]", "parent": 612, "children": [614, 615], "start_point": {"row": 118, "column": 13}, "end_point": {"row": 118, "column": 23}}, {"id": 614, "type": "identifier", "text": "lines", "parent": 613, "children": [], "start_point": {"row": 118, "column": 13}, "end_point": {"row": 118, "column": 18}}, {"id": 615, "type": "update_expression", "text": "i++", "parent": 613, "children": [616, 617], "start_point": {"row": 118, "column": 19}, "end_point": {"row": 118, "column": 22}}, {"id": 616, "type": "identifier", "text": "i", "parent": 615, "children": [], "start_point": {"row": 118, "column": 19}, "end_point": {"row": 118, "column": 20}}, {"id": 617, "type": "++", "text": "++", "parent": 615, "children": [], "start_point": {"row": 118, "column": 20}, "end_point": {"row": 118, "column": 22}}, {"id": 618, "type": "call_expression", "text": "free(lines)", "parent": 583, "children": [619, 620], "start_point": {"row": 121, "column": 4}, "end_point": {"row": 121, "column": 15}}, {"id": 619, "type": "identifier", "text": "free", "parent": 618, "children": [], "start_point": {"row": 121, "column": 4}, "end_point": {"row": 121, "column": 8}}, {"id": 620, "type": "argument_list", "text": "(lines)", "parent": 618, "children": [621], "start_point": {"row": 121, "column": 8}, "end_point": {"row": 121, "column": 15}}, {"id": 621, "type": "identifier", "text": "lines", "parent": 620, "children": [], "start_point": {"row": 121, "column": 9}, "end_point": {"row": 121, "column": 14}}, {"id": 622, "type": "function_definition", "text": "char *formatStr(char *old){ \r\n char *str = malloc(sizeof(char) * strlen(old) + 1);\r\n int i, j, start, end, newpos;\r\n bool notFirstWord = false;\r\n\r\n i = 0;\r\n newpos = 0;\r\n while(old[i] != 0){\r\n int start = getNextNonWhitespace(old, i);\r\n int end = getNextWhitespace(old, start);\r\n \r\n if(isCapital(old[start])){\r\n\r\n if(notFirstWord){\r\n str[newpos++] = ' ';\r\n }else{\r\n notFirstWord = true;\r\n }\r\n\r\n for(j = start; j < end; j++){\r\n str[newpos++] = old[j];\r\n }\r\n }\r\n \r\n i = end;\r\n }\r\n\r\n i = 0;\r\n while(old[i] != 0){\r\n int start = getNextNonWhitespace(old, i);\r\n int end = getNextWhitespace(old, start);\r\n \r\n if(!isCapital(old[start])){\r\n\r\n if(notFirstWord){\r\n str[newpos++] = ' ';\r\n }else{\r\n notFirstWord = true;\r\n }\r\n\r\n for(j = start; j < end; j++){\r\n str[newpos++] = old[j];\r\n }\r\n }\r\n \r\n i = end;\r\n }\r\n\r\n str[newpos] = 0;\r\n\r\n free(old);\r\n return str;\r\n}", "parent": null, "children": [623, 624], "start_point": {"row": 124, "column": 0}, "end_point": {"row": 176, "column": 1}}, {"id": 623, "type": "primitive_type", "text": "char", "parent": 622, "children": [], "start_point": {"row": 124, "column": 0}, "end_point": {"row": 124, "column": 4}}, {"id": 624, "type": "pointer_declarator", "text": "*formatStr(char *old)", "parent": 622, "children": [625, 626], "start_point": {"row": 124, "column": 5}, "end_point": {"row": 124, "column": 26}}, {"id": 625, "type": "*", "text": "*", "parent": 624, "children": [], "start_point": {"row": 124, "column": 5}, "end_point": {"row": 124, "column": 6}}, {"id": 626, "type": "function_declarator", "text": "formatStr(char *old)", "parent": 624, "children": [627, 628], "start_point": {"row": 124, "column": 6}, "end_point": {"row": 124, "column": 26}}, {"id": 627, "type": "identifier", "text": "formatStr", "parent": 626, "children": [], "start_point": {"row": 124, "column": 6}, "end_point": {"row": 124, "column": 15}}, {"id": 628, "type": "parameter_list", "text": "(char *old)", "parent": 626, "children": [629], "start_point": {"row": 124, "column": 15}, "end_point": {"row": 124, "column": 26}}, {"id": 629, "type": "parameter_declaration", "text": "char *old", "parent": 628, "children": [630, 631], "start_point": {"row": 124, "column": 16}, "end_point": {"row": 124, "column": 25}}, {"id": 630, "type": "primitive_type", "text": "char", "parent": 629, "children": [], "start_point": {"row": 124, "column": 16}, "end_point": {"row": 124, "column": 20}}, {"id": 631, "type": "pointer_declarator", "text": "*old", "parent": 629, "children": [632, 633], "start_point": {"row": 124, "column": 21}, "end_point": {"row": 124, "column": 25}}, {"id": 632, "type": "*", "text": "*", "parent": 631, "children": [], "start_point": {"row": 124, "column": 21}, "end_point": {"row": 124, "column": 22}}, {"id": 633, "type": "identifier", "text": "old", "parent": 631, "children": [], "start_point": {"row": 124, "column": 22}, "end_point": {"row": 124, "column": 25}}, {"id": 634, "type": "declaration", "text": "char *str = malloc(sizeof(char) * strlen(old) + 1);", "parent": 622, "children": [635, 636], "start_point": {"row": 125, "column": 4}, "end_point": {"row": 125, "column": 55}}, {"id": 635, "type": "primitive_type", "text": "char", "parent": 634, "children": [], "start_point": {"row": 125, "column": 4}, "end_point": {"row": 125, "column": 8}}, {"id": 636, "type": "init_declarator", "text": "*str = malloc(sizeof(char) * strlen(old) + 1)", "parent": 634, "children": [637, 640, 641], "start_point": {"row": 125, "column": 9}, "end_point": {"row": 125, "column": 54}}, {"id": 637, "type": "pointer_declarator", "text": "*str", "parent": 636, "children": [638, 639], "start_point": {"row": 125, "column": 9}, "end_point": {"row": 125, "column": 13}}, {"id": 638, "type": "*", "text": "*", "parent": 637, "children": [], "start_point": {"row": 125, "column": 9}, "end_point": {"row": 125, "column": 10}}, {"id": 639, "type": "identifier", "text": "str", "parent": 637, "children": [], "start_point": {"row": 125, "column": 10}, "end_point": {"row": 125, "column": 13}}, {"id": 640, "type": "=", "text": "=", "parent": 636, "children": [], "start_point": {"row": 125, "column": 14}, "end_point": {"row": 125, "column": 15}}, {"id": 641, "type": "call_expression", "text": "malloc(sizeof(char) * strlen(old) + 1)", "parent": 636, "children": [642, 643], "start_point": {"row": 125, "column": 16}, "end_point": {"row": 125, "column": 54}}, {"id": 642, "type": "identifier", "text": "malloc", "parent": 641, "children": [], "start_point": {"row": 125, "column": 16}, "end_point": {"row": 125, "column": 22}}, {"id": 643, "type": "argument_list", "text": "(sizeof(char) * strlen(old) + 1)", "parent": 641, "children": [644], "start_point": {"row": 125, "column": 22}, "end_point": {"row": 125, "column": 54}}, {"id": 644, "type": "binary_expression", "text": "sizeof(char) * strlen(old) + 1", "parent": 643, "children": [645, 654, 655], "start_point": {"row": 125, "column": 23}, "end_point": {"row": 125, "column": 53}}, {"id": 645, "type": "binary_expression", "text": "sizeof(char) * strlen(old)", "parent": 644, "children": [646, 649, 650], "start_point": {"row": 125, "column": 23}, "end_point": {"row": 125, "column": 49}}, {"id": 646, "type": "sizeof_expression", "text": "sizeof(char)", "parent": 645, "children": [647], "start_point": {"row": 125, "column": 23}, "end_point": {"row": 125, "column": 35}}, {"id": 647, "type": "type_descriptor", "text": "char", "parent": 646, "children": [648], "start_point": {"row": 125, "column": 30}, "end_point": {"row": 125, "column": 34}}, {"id": 648, "type": "primitive_type", "text": "char", "parent": 647, "children": [], "start_point": {"row": 125, "column": 30}, "end_point": {"row": 125, "column": 34}}, {"id": 649, "type": "*", "text": "*", "parent": 645, "children": [], "start_point": {"row": 125, "column": 36}, "end_point": {"row": 125, "column": 37}}, {"id": 650, "type": "call_expression", "text": "strlen(old)", "parent": 645, "children": [651, 652], "start_point": {"row": 125, "column": 38}, "end_point": {"row": 125, "column": 49}}, {"id": 651, "type": "identifier", "text": "strlen", "parent": 650, "children": [], "start_point": {"row": 125, "column": 38}, "end_point": {"row": 125, "column": 44}}, {"id": 652, "type": "argument_list", "text": "(old)", "parent": 650, "children": [653], "start_point": {"row": 125, "column": 44}, "end_point": {"row": 125, "column": 49}}, {"id": 653, "type": "identifier", "text": "old", "parent": 652, "children": [], "start_point": {"row": 125, "column": 45}, "end_point": {"row": 125, "column": 48}}, {"id": 654, "type": "+", "text": "+", "parent": 644, "children": [], "start_point": {"row": 125, "column": 50}, "end_point": {"row": 125, "column": 51}}, {"id": 655, "type": "number_literal", "text": "1", "parent": 644, "children": [], "start_point": {"row": 125, "column": 52}, "end_point": {"row": 125, "column": 53}}, {"id": 656, "type": "declaration", "text": "int i, j, start, end, newpos;", "parent": 622, "children": [657, 658, 659, 660, 661], "start_point": {"row": 126, "column": 4}, "end_point": {"row": 126, "column": 33}}, {"id": 657, "type": "primitive_type", "text": "int", "parent": 656, "children": [], "start_point": {"row": 126, "column": 4}, "end_point": {"row": 126, "column": 7}}, {"id": 658, "type": "identifier", "text": "i", "parent": 656, "children": [], "start_point": {"row": 126, "column": 8}, "end_point": {"row": 126, "column": 9}}, {"id": 659, "type": "identifier", "text": "j", "parent": 656, "children": [], "start_point": {"row": 126, "column": 11}, "end_point": {"row": 126, "column": 12}}, {"id": 660, "type": "identifier", "text": "start", "parent": 656, "children": [], "start_point": {"row": 126, "column": 14}, "end_point": {"row": 126, "column": 19}}, {"id": 661, "type": "identifier", "text": "newpos", "parent": 656, "children": [], "start_point": {"row": 126, "column": 26}, "end_point": {"row": 126, "column": 32}}, {"id": 662, "type": "declaration", "text": "bool notFirstWord = false;", "parent": 622, "children": [663, 664], "start_point": {"row": 127, "column": 4}, "end_point": {"row": 127, "column": 30}}, {"id": 663, "type": "primitive_type", "text": "bool", "parent": 662, "children": [], "start_point": {"row": 127, "column": 4}, "end_point": {"row": 127, "column": 8}}, {"id": 664, "type": "init_declarator", "text": "notFirstWord = false", "parent": 662, "children": [665, 666, 667], "start_point": {"row": 127, "column": 9}, "end_point": {"row": 127, "column": 29}}, {"id": 665, "type": "identifier", "text": "notFirstWord", "parent": 664, "children": [], "start_point": {"row": 127, "column": 9}, "end_point": {"row": 127, "column": 21}}, {"id": 666, "type": "=", "text": "=", "parent": 664, "children": [], "start_point": {"row": 127, "column": 22}, "end_point": {"row": 127, "column": 23}}, {"id": 667, "type": "false", "text": "false", "parent": 664, "children": [], "start_point": {"row": 127, "column": 24}, "end_point": {"row": 127, "column": 29}}, {"id": 668, "type": "assignment_expression", "text": "i = 0", "parent": 622, "children": [669, 670, 671], "start_point": {"row": 129, "column": 4}, "end_point": {"row": 129, "column": 9}}, {"id": 669, "type": "identifier", "text": "i", "parent": 668, "children": [], "start_point": {"row": 129, "column": 4}, "end_point": {"row": 129, "column": 5}}, {"id": 670, "type": "=", "text": "=", "parent": 668, "children": [], "start_point": {"row": 129, "column": 6}, "end_point": {"row": 129, "column": 7}}, {"id": 671, "type": "number_literal", "text": "0", "parent": 668, "children": [], "start_point": {"row": 129, "column": 8}, "end_point": {"row": 129, "column": 9}}, {"id": 672, "type": "assignment_expression", "text": "newpos = 0", "parent": 622, "children": [673, 674, 675], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 14}}, {"id": 673, "type": "identifier", "text": "newpos", "parent": 672, "children": [], "start_point": {"row": 130, "column": 4}, "end_point": {"row": 130, "column": 10}}, {"id": 674, "type": "=", "text": "=", "parent": 672, "children": [], "start_point": {"row": 130, "column": 11}, "end_point": {"row": 130, "column": 12}}, {"id": 675, "type": "number_literal", "text": "0", "parent": 672, "children": [], "start_point": {"row": 130, "column": 13}, "end_point": {"row": 130, "column": 14}}, {"id": 676, "type": "while_statement", "text": "while(old[i] != 0){\r\n int start = getNextNonWhitespace(old, i);\r\n int end = getNextWhitespace(old, start);\r\n \r\n if(isCapital(old[start])){\r\n\r\n if(notFirstWord){\r\n str[newpos++] = ' ';\r\n }else{\r\n notFirstWord = true;\r\n }\r\n\r\n for(j = start; j < end; j++){\r\n str[newpos++] = old[j];\r\n }\r\n }\r\n \r\n i = end;\r\n }", "parent": 622, "children": [677], "start_point": {"row": 131, "column": 4}, "end_point": {"row": 149, "column": 5}}, {"id": 677, "type": "parenthesized_expression", "text": "(old[i] != 0)", "parent": 676, "children": [678], "start_point": {"row": 131, "column": 9}, "end_point": {"row": 131, "column": 22}}, {"id": 678, "type": "binary_expression", "text": "old[i] != 0", "parent": 677, "children": [679, 682, 683], "start_point": {"row": 131, "column": 10}, "end_point": {"row": 131, "column": 21}}, {"id": 679, "type": "subscript_expression", "text": "old[i]", "parent": 678, "children": [680, 681], "start_point": {"row": 131, "column": 10}, "end_point": {"row": 131, "column": 16}}, {"id": 680, "type": "identifier", "text": "old", "parent": 679, "children": [], "start_point": {"row": 131, "column": 10}, "end_point": {"row": 131, "column": 13}}, {"id": 681, "type": "identifier", "text": "i", "parent": 679, "children": [], "start_point": {"row": 131, "column": 14}, "end_point": {"row": 131, "column": 15}}, {"id": 682, "type": "!=", "text": "!=", "parent": 678, "children": [], "start_point": {"row": 131, "column": 17}, "end_point": {"row": 131, "column": 19}}, {"id": 683, "type": "number_literal", "text": "0", "parent": 678, "children": [], "start_point": {"row": 131, "column": 20}, "end_point": {"row": 131, "column": 21}}, {"id": 684, "type": "declaration", "text": "int start = getNextNonWhitespace(old, i);", "parent": 676, "children": [685, 686], "start_point": {"row": 132, "column": 8}, "end_point": {"row": 132, "column": 49}}, {"id": 685, "type": "primitive_type", "text": "int", "parent": 684, "children": [], "start_point": {"row": 132, "column": 8}, "end_point": {"row": 132, "column": 11}}, {"id": 686, "type": "init_declarator", "text": "start = getNextNonWhitespace(old, i)", "parent": 684, "children": [687, 688, 689], "start_point": {"row": 132, "column": 12}, "end_point": {"row": 132, "column": 48}}, {"id": 687, "type": "identifier", "text": "start", "parent": 686, "children": [], "start_point": {"row": 132, "column": 12}, "end_point": {"row": 132, "column": 17}}, {"id": 688, "type": "=", "text": "=", "parent": 686, "children": [], "start_point": {"row": 132, "column": 18}, "end_point": {"row": 132, "column": 19}}, {"id": 689, "type": "call_expression", "text": "getNextNonWhitespace(old, i)", "parent": 686, "children": [690, 691], "start_point": {"row": 132, "column": 20}, "end_point": {"row": 132, "column": 48}}, {"id": 690, "type": "identifier", "text": "getNextNonWhitespace", "parent": 689, "children": [], "start_point": {"row": 132, "column": 20}, "end_point": {"row": 132, "column": 40}}, {"id": 691, "type": "argument_list", "text": "(old, i)", "parent": 689, "children": [692, 693], "start_point": {"row": 132, "column": 40}, "end_point": {"row": 132, "column": 48}}, {"id": 692, "type": "identifier", "text": "old", "parent": 691, "children": [], "start_point": {"row": 132, "column": 41}, "end_point": {"row": 132, "column": 44}}, {"id": 693, "type": "identifier", "text": "i", "parent": 691, "children": [], "start_point": {"row": 132, "column": 46}, "end_point": {"row": 132, "column": 47}}, {"id": 694, "type": "declaration", "text": "int end = getNextWhitespace(old, start);", "parent": 676, "children": [695, 696], "start_point": {"row": 133, "column": 8}, "end_point": {"row": 133, "column": 48}}, {"id": 695, "type": "primitive_type", "text": "int", "parent": 694, "children": [], "start_point": {"row": 133, "column": 8}, "end_point": {"row": 133, "column": 11}}, {"id": 696, "type": "init_declarator", "text": "end = getNextWhitespace(old, start)", "parent": 694, "children": [697, 698], "start_point": {"row": 133, "column": 12}, "end_point": {"row": 133, "column": 47}}, {"id": 697, "type": "=", "text": "=", "parent": 696, "children": [], "start_point": {"row": 133, "column": 16}, "end_point": {"row": 133, "column": 17}}, {"id": 698, "type": "call_expression", "text": "getNextWhitespace(old, start)", "parent": 696, "children": [699, 700], "start_point": {"row": 133, "column": 18}, "end_point": {"row": 133, "column": 47}}, {"id": 699, "type": "identifier", "text": "getNextWhitespace", "parent": 698, "children": [], "start_point": {"row": 133, "column": 18}, "end_point": {"row": 133, "column": 35}}, {"id": 700, "type": "argument_list", "text": "(old, start)", "parent": 698, "children": [701, 702], "start_point": {"row": 133, "column": 35}, "end_point": {"row": 133, "column": 47}}, {"id": 701, "type": "identifier", "text": "old", "parent": 700, "children": [], "start_point": {"row": 133, "column": 36}, "end_point": {"row": 133, "column": 39}}, {"id": 702, "type": "identifier", "text": "start", "parent": 700, "children": [], "start_point": {"row": 133, "column": 41}, "end_point": {"row": 133, "column": 46}}, {"id": 703, "type": "if_statement", "text": "if(isCapital(old[start])){\r\n\r\n if(notFirstWord){\r\n str[newpos++] = ' ';\r\n }else{\r\n notFirstWord = true;\r\n }\r\n\r\n for(j = start; j < end; j++){\r\n str[newpos++] = old[j];\r\n }\r\n }", "parent": 676, "children": [704], "start_point": {"row": 135, "column": 8}, "end_point": {"row": 146, "column": 9}}, {"id": 704, "type": "parenthesized_expression", "text": "(isCapital(old[start]))", "parent": 703, "children": [705], "start_point": {"row": 135, "column": 10}, "end_point": {"row": 135, "column": 33}}, {"id": 705, "type": "call_expression", "text": "isCapital(old[start])", "parent": 704, "children": [706, 707], "start_point": {"row": 135, "column": 11}, "end_point": {"row": 135, "column": 32}}, {"id": 706, "type": "identifier", "text": "isCapital", "parent": 705, "children": [], "start_point": {"row": 135, "column": 11}, "end_point": {"row": 135, "column": 20}}, {"id": 707, "type": "argument_list", "text": "(old[start])", "parent": 705, "children": [708], "start_point": {"row": 135, "column": 20}, "end_point": {"row": 135, "column": 32}}, {"id": 708, "type": "subscript_expression", "text": "old[start]", "parent": 707, "children": [709, 710], "start_point": {"row": 135, "column": 21}, "end_point": {"row": 135, "column": 31}}, {"id": 709, "type": "identifier", "text": "old", "parent": 708, "children": [], "start_point": {"row": 135, "column": 21}, "end_point": {"row": 135, "column": 24}}, {"id": 710, "type": "identifier", "text": "start", "parent": 708, "children": [], "start_point": {"row": 135, "column": 25}, "end_point": {"row": 135, "column": 30}}, {"id": 711, "type": "if_statement", "text": "if(notFirstWord){\r\n str[newpos++] = ' ';\r\n }else{\r\n notFirstWord = true;\r\n }", "parent": 703, "children": [712, 725], "start_point": {"row": 137, "column": 12}, "end_point": {"row": 141, "column": 13}}, {"id": 712, "type": "parenthesized_expression", "text": "(notFirstWord)", "parent": 711, "children": [713], "start_point": {"row": 137, "column": 14}, "end_point": {"row": 137, "column": 28}}, {"id": 713, "type": "identifier", "text": "notFirstWord", "parent": 712, "children": [], "start_point": {"row": 137, "column": 15}, "end_point": {"row": 137, "column": 27}}, {"id": 714, "type": "assignment_expression", "text": "str[newpos++] = ' '", "parent": 711, "children": [715, 720, 721], "start_point": {"row": 138, "column": 16}, "end_point": {"row": 138, "column": 35}}, {"id": 715, "type": "subscript_expression", "text": "str[newpos++]", "parent": 714, "children": [716, 717], "start_point": {"row": 138, "column": 16}, "end_point": {"row": 138, "column": 29}}, {"id": 716, "type": "identifier", "text": "str", "parent": 715, "children": [], "start_point": {"row": 138, "column": 16}, "end_point": {"row": 138, "column": 19}}, {"id": 717, "type": "update_expression", "text": "newpos++", "parent": 715, "children": [718, 719], "start_point": {"row": 138, "column": 20}, "end_point": {"row": 138, "column": 28}}, {"id": 718, "type": "identifier", "text": "newpos", "parent": 717, "children": [], "start_point": {"row": 138, "column": 20}, "end_point": {"row": 138, "column": 26}}, {"id": 719, "type": "++", "text": "++", "parent": 717, "children": [], "start_point": {"row": 138, "column": 26}, "end_point": {"row": 138, "column": 28}}, {"id": 720, "type": "=", "text": "=", "parent": 714, "children": [], "start_point": {"row": 138, "column": 30}, "end_point": {"row": 138, "column": 31}}, {"id": 721, "type": "char_literal", "text": "' '", "parent": 714, "children": [722, 723, 724], "start_point": {"row": 138, "column": 32}, "end_point": {"row": 138, "column": 35}}, {"id": 722, "type": "'", "text": "'", "parent": 721, "children": [], "start_point": {"row": 138, "column": 32}, "end_point": {"row": 138, "column": 33}}, {"id": 723, "type": "character", "text": " ", "parent": 721, "children": [], "start_point": {"row": 138, "column": 33}, "end_point": {"row": 138, "column": 34}}, {"id": 724, "type": "'", "text": "'", "parent": 721, "children": [], "start_point": {"row": 138, "column": 34}, "end_point": {"row": 138, "column": 35}}, {"id": 725, "type": "else_clause", "text": "else{\r\n notFirstWord = true;\r\n }", "parent": 711, "children": [], "start_point": {"row": 139, "column": 13}, "end_point": {"row": 141, "column": 13}}, {"id": 726, "type": "assignment_expression", "text": "notFirstWord = true", "parent": 725, "children": [727, 728, 729], "start_point": {"row": 140, "column": 16}, "end_point": {"row": 140, "column": 35}}, {"id": 727, "type": "identifier", "text": "notFirstWord", "parent": 726, "children": [], "start_point": {"row": 140, "column": 16}, "end_point": {"row": 140, "column": 28}}, {"id": 728, "type": "=", "text": "=", "parent": 726, "children": [], "start_point": {"row": 140, "column": 29}, "end_point": {"row": 140, "column": 30}}, {"id": 729, "type": "true", "text": "true", "parent": 726, "children": [], "start_point": {"row": 140, "column": 31}, "end_point": {"row": 140, "column": 35}}, {"id": 730, "type": "for_statement", "text": "for(j = start; j < end; j++){\r\n str[newpos++] = old[j];\r\n }", "parent": 703, "children": [731, 735, 738], "start_point": {"row": 143, "column": 12}, "end_point": {"row": 145, "column": 13}}, {"id": 731, "type": "assignment_expression", "text": "j = start", "parent": 730, "children": [732, 733, 734], "start_point": {"row": 143, "column": 16}, "end_point": {"row": 143, "column": 25}}, {"id": 732, "type": "identifier", "text": "j", "parent": 731, "children": [], "start_point": {"row": 143, "column": 16}, "end_point": {"row": 143, "column": 17}}, {"id": 733, "type": "=", "text": "=", "parent": 731, "children": [], "start_point": {"row": 143, "column": 18}, "end_point": {"row": 143, "column": 19}}, {"id": 734, "type": "identifier", "text": "start", "parent": 731, "children": [], "start_point": {"row": 143, "column": 20}, "end_point": {"row": 143, "column": 25}}, {"id": 735, "type": "binary_expression", "text": "j < end", "parent": 730, "children": [736, 737], "start_point": {"row": 143, "column": 27}, "end_point": {"row": 143, "column": 34}}, {"id": 736, "type": "identifier", "text": "j", "parent": 735, "children": [], "start_point": {"row": 143, "column": 27}, "end_point": {"row": 143, "column": 28}}, {"id": 737, "type": "<", "text": "<", "parent": 735, "children": [], "start_point": {"row": 143, "column": 29}, "end_point": {"row": 143, "column": 30}}, {"id": 738, "type": "update_expression", "text": "j++", "parent": 730, "children": [739, 740], "start_point": {"row": 143, "column": 36}, "end_point": {"row": 143, "column": 39}}, {"id": 739, "type": "identifier", "text": "j", "parent": 738, "children": [], "start_point": {"row": 143, "column": 36}, "end_point": {"row": 143, "column": 37}}, {"id": 740, "type": "++", "text": "++", "parent": 738, "children": [], "start_point": {"row": 143, "column": 37}, "end_point": {"row": 143, "column": 39}}, {"id": 741, "type": "assignment_expression", "text": "str[newpos++] = old[j]", "parent": 730, "children": [742, 747, 748], "start_point": {"row": 144, "column": 16}, "end_point": {"row": 144, "column": 38}}, {"id": 742, "type": "subscript_expression", "text": "str[newpos++]", "parent": 741, "children": [743, 744], "start_point": {"row": 144, "column": 16}, "end_point": {"row": 144, "column": 29}}, {"id": 743, "type": "identifier", "text": "str", "parent": 742, "children": [], "start_point": {"row": 144, "column": 16}, "end_point": {"row": 144, "column": 19}}, {"id": 744, "type": "update_expression", "text": "newpos++", "parent": 742, "children": [745, 746], "start_point": {"row": 144, "column": 20}, "end_point": {"row": 144, "column": 28}}, {"id": 745, "type": "identifier", "text": "newpos", "parent": 744, "children": [], "start_point": {"row": 144, "column": 20}, "end_point": {"row": 144, "column": 26}}, {"id": 746, "type": "++", "text": "++", "parent": 744, "children": [], "start_point": {"row": 144, "column": 26}, "end_point": {"row": 144, "column": 28}}, {"id": 747, "type": "=", "text": "=", "parent": 741, "children": [], "start_point": {"row": 144, "column": 30}, "end_point": {"row": 144, "column": 31}}, {"id": 748, "type": "subscript_expression", "text": "old[j]", "parent": 741, "children": [749, 750], "start_point": {"row": 144, "column": 32}, "end_point": {"row": 144, "column": 38}}, {"id": 749, "type": "identifier", "text": "old", "parent": 748, "children": [], "start_point": {"row": 144, "column": 32}, "end_point": {"row": 144, "column": 35}}, {"id": 750, "type": "identifier", "text": "j", "parent": 748, "children": [], "start_point": {"row": 144, "column": 36}, "end_point": {"row": 144, "column": 37}}, {"id": 751, "type": "assignment_expression", "text": "i = end", "parent": 676, "children": [752, 753], "start_point": {"row": 148, "column": 8}, "end_point": {"row": 148, "column": 15}}, {"id": 752, "type": "identifier", "text": "i", "parent": 751, "children": [], "start_point": {"row": 148, "column": 8}, "end_point": {"row": 148, "column": 9}}, {"id": 753, "type": "=", "text": "=", "parent": 751, "children": [], "start_point": {"row": 148, "column": 10}, "end_point": {"row": 148, "column": 11}}, {"id": 754, "type": "assignment_expression", "text": "i = 0", "parent": 622, "children": [755, 756, 757], "start_point": {"row": 151, "column": 4}, "end_point": {"row": 151, "column": 9}}, {"id": 755, "type": "identifier", "text": "i", "parent": 754, "children": [], "start_point": {"row": 151, "column": 4}, "end_point": {"row": 151, "column": 5}}, {"id": 756, "type": "=", "text": "=", "parent": 754, "children": [], "start_point": {"row": 151, "column": 6}, "end_point": {"row": 151, "column": 7}}, {"id": 757, "type": "number_literal", "text": "0", "parent": 754, "children": [], "start_point": {"row": 151, "column": 8}, "end_point": {"row": 151, "column": 9}}, {"id": 758, "type": "while_statement", "text": "while(old[i] != 0){\r\n int start = getNextNonWhitespace(old, i);\r\n int end = getNextWhitespace(old, start);\r\n \r\n if(!isCapital(old[start])){\r\n\r\n if(notFirstWord){\r\n str[newpos++] = ' ';\r\n }else{\r\n notFirstWord = true;\r\n }\r\n\r\n for(j = start; j < end; j++){\r\n str[newpos++] = old[j];\r\n }\r\n }\r\n \r\n i = end;\r\n }", "parent": 622, "children": [759], "start_point": {"row": 152, "column": 4}, "end_point": {"row": 170, "column": 5}}, {"id": 759, "type": "parenthesized_expression", "text": "(old[i] != 0)", "parent": 758, "children": [760], "start_point": {"row": 152, "column": 9}, "end_point": {"row": 152, "column": 22}}, {"id": 760, "type": "binary_expression", "text": "old[i] != 0", "parent": 759, "children": [761, 764, 765], "start_point": {"row": 152, "column": 10}, "end_point": {"row": 152, "column": 21}}, {"id": 761, "type": "subscript_expression", "text": "old[i]", "parent": 760, "children": [762, 763], "start_point": {"row": 152, "column": 10}, "end_point": {"row": 152, "column": 16}}, {"id": 762, "type": "identifier", "text": "old", "parent": 761, "children": [], "start_point": {"row": 152, "column": 10}, "end_point": {"row": 152, "column": 13}}, {"id": 763, "type": "identifier", "text": "i", "parent": 761, "children": [], "start_point": {"row": 152, "column": 14}, "end_point": {"row": 152, "column": 15}}, {"id": 764, "type": "!=", "text": "!=", "parent": 760, "children": [], "start_point": {"row": 152, "column": 17}, "end_point": {"row": 152, "column": 19}}, {"id": 765, "type": "number_literal", "text": "0", "parent": 760, "children": [], "start_point": {"row": 152, "column": 20}, "end_point": {"row": 152, "column": 21}}, {"id": 766, "type": "declaration", "text": "int start = getNextNonWhitespace(old, i);", "parent": 758, "children": [767, 768], "start_point": {"row": 153, "column": 8}, "end_point": {"row": 153, "column": 49}}, {"id": 767, "type": "primitive_type", "text": "int", "parent": 766, "children": [], "start_point": {"row": 153, "column": 8}, "end_point": {"row": 153, "column": 11}}, {"id": 768, "type": "init_declarator", "text": "start = getNextNonWhitespace(old, i)", "parent": 766, "children": [769, 770, 771], "start_point": {"row": 153, "column": 12}, "end_point": {"row": 153, "column": 48}}, {"id": 769, "type": "identifier", "text": "start", "parent": 768, "children": [], "start_point": {"row": 153, "column": 12}, "end_point": {"row": 153, "column": 17}}, {"id": 770, "type": "=", "text": "=", "parent": 768, "children": [], "start_point": {"row": 153, "column": 18}, "end_point": {"row": 153, "column": 19}}, {"id": 771, "type": "call_expression", "text": "getNextNonWhitespace(old, i)", "parent": 768, "children": [772, 773], "start_point": {"row": 153, "column": 20}, "end_point": {"row": 153, "column": 48}}, {"id": 772, "type": "identifier", "text": "getNextNonWhitespace", "parent": 771, "children": [], "start_point": {"row": 153, "column": 20}, "end_point": {"row": 153, "column": 40}}, {"id": 773, "type": "argument_list", "text": "(old, i)", "parent": 771, "children": [774, 775], "start_point": {"row": 153, "column": 40}, "end_point": {"row": 153, "column": 48}}, {"id": 774, "type": "identifier", "text": "old", "parent": 773, "children": [], "start_point": {"row": 153, "column": 41}, "end_point": {"row": 153, "column": 44}}, {"id": 775, "type": "identifier", "text": "i", "parent": 773, "children": [], "start_point": {"row": 153, "column": 46}, "end_point": {"row": 153, "column": 47}}, {"id": 776, "type": "declaration", "text": "int end = getNextWhitespace(old, start);", "parent": 758, "children": [777, 778], "start_point": {"row": 154, "column": 8}, "end_point": {"row": 154, "column": 48}}, {"id": 777, "type": "primitive_type", "text": "int", "parent": 776, "children": [], "start_point": {"row": 154, "column": 8}, "end_point": {"row": 154, "column": 11}}, {"id": 778, "type": "init_declarator", "text": "end = getNextWhitespace(old, start)", "parent": 776, "children": [779, 780], "start_point": {"row": 154, "column": 12}, "end_point": {"row": 154, "column": 47}}, {"id": 779, "type": "=", "text": "=", "parent": 778, "children": [], "start_point": {"row": 154, "column": 16}, "end_point": {"row": 154, "column": 17}}, {"id": 780, "type": "call_expression", "text": "getNextWhitespace(old, start)", "parent": 778, "children": [781, 782], "start_point": {"row": 154, "column": 18}, "end_point": {"row": 154, "column": 47}}, {"id": 781, "type": "identifier", "text": "getNextWhitespace", "parent": 780, "children": [], "start_point": {"row": 154, "column": 18}, "end_point": {"row": 154, "column": 35}}, {"id": 782, "type": "argument_list", "text": "(old, start)", "parent": 780, "children": [783, 784], "start_point": {"row": 154, "column": 35}, "end_point": {"row": 154, "column": 47}}, {"id": 783, "type": "identifier", "text": "old", "parent": 782, "children": [], "start_point": {"row": 154, "column": 36}, "end_point": {"row": 154, "column": 39}}, {"id": 784, "type": "identifier", "text": "start", "parent": 782, "children": [], "start_point": {"row": 154, "column": 41}, "end_point": {"row": 154, "column": 46}}, {"id": 785, "type": "if_statement", "text": "if(!isCapital(old[start])){\r\n\r\n if(notFirstWord){\r\n str[newpos++] = ' ';\r\n }else{\r\n notFirstWord = true;\r\n }\r\n\r\n for(j = start; j < end; j++){\r\n str[newpos++] = old[j];\r\n }\r\n }", "parent": 758, "children": [786], "start_point": {"row": 156, "column": 8}, "end_point": {"row": 167, "column": 9}}, {"id": 786, "type": "parenthesized_expression", "text": "(!isCapital(old[start]))", "parent": 785, "children": [787], "start_point": {"row": 156, "column": 10}, "end_point": {"row": 156, "column": 34}}, {"id": 787, "type": "unary_expression", "text": "!isCapital(old[start])", "parent": 786, "children": [788, 789], "start_point": {"row": 156, "column": 11}, "end_point": {"row": 156, "column": 33}}, {"id": 788, "type": "!", "text": "!", "parent": 787, "children": [], "start_point": {"row": 156, "column": 11}, "end_point": {"row": 156, "column": 12}}, {"id": 789, "type": "call_expression", "text": "isCapital(old[start])", "parent": 787, "children": [790, 791], "start_point": {"row": 156, "column": 12}, "end_point": {"row": 156, "column": 33}}, {"id": 790, "type": "identifier", "text": "isCapital", "parent": 789, "children": [], "start_point": {"row": 156, "column": 12}, "end_point": {"row": 156, "column": 21}}, {"id": 791, "type": "argument_list", "text": "(old[start])", "parent": 789, "children": [792], "start_point": {"row": 156, "column": 21}, "end_point": {"row": 156, "column": 33}}, {"id": 792, "type": "subscript_expression", "text": "old[start]", "parent": 791, "children": [793, 794], "start_point": {"row": 156, "column": 22}, "end_point": {"row": 156, "column": 32}}, {"id": 793, "type": "identifier", "text": "old", "parent": 792, "children": [], "start_point": {"row": 156, "column": 22}, "end_point": {"row": 156, "column": 25}}, {"id": 794, "type": "identifier", "text": "start", "parent": 792, "children": [], "start_point": {"row": 156, "column": 26}, "end_point": {"row": 156, "column": 31}}, {"id": 795, "type": "if_statement", "text": "if(notFirstWord){\r\n str[newpos++] = ' ';\r\n }else{\r\n notFirstWord = true;\r\n }", "parent": 785, "children": [796, 809], "start_point": {"row": 158, "column": 12}, "end_point": {"row": 162, "column": 13}}, {"id": 796, "type": "parenthesized_expression", "text": "(notFirstWord)", "parent": 795, "children": [797], "start_point": {"row": 158, "column": 14}, "end_point": {"row": 158, "column": 28}}, {"id": 797, "type": "identifier", "text": "notFirstWord", "parent": 796, "children": [], "start_point": {"row": 158, "column": 15}, "end_point": {"row": 158, "column": 27}}, {"id": 798, "type": "assignment_expression", "text": "str[newpos++] = ' '", "parent": 795, "children": [799, 804, 805], "start_point": {"row": 159, "column": 16}, "end_point": {"row": 159, "column": 35}}, {"id": 799, "type": "subscript_expression", "text": "str[newpos++]", "parent": 798, "children": [800, 801], "start_point": {"row": 159, "column": 16}, "end_point": {"row": 159, "column": 29}}, {"id": 800, "type": "identifier", "text": "str", "parent": 799, "children": [], "start_point": {"row": 159, "column": 16}, "end_point": {"row": 159, "column": 19}}, {"id": 801, "type": "update_expression", "text": "newpos++", "parent": 799, "children": [802, 803], "start_point": {"row": 159, "column": 20}, "end_point": {"row": 159, "column": 28}}, {"id": 802, "type": "identifier", "text": "newpos", "parent": 801, "children": [], "start_point": {"row": 159, "column": 20}, "end_point": {"row": 159, "column": 26}}, {"id": 803, "type": "++", "text": "++", "parent": 801, "children": [], "start_point": {"row": 159, "column": 26}, "end_point": {"row": 159, "column": 28}}, {"id": 804, "type": "=", "text": "=", "parent": 798, "children": [], "start_point": {"row": 159, "column": 30}, "end_point": {"row": 159, "column": 31}}, {"id": 805, "type": "char_literal", "text": "' '", "parent": 798, "children": [806, 807, 808], "start_point": {"row": 159, "column": 32}, "end_point": {"row": 159, "column": 35}}, {"id": 806, "type": "'", "text": "'", "parent": 805, "children": [], "start_point": {"row": 159, "column": 32}, "end_point": {"row": 159, "column": 33}}, {"id": 807, "type": "character", "text": " ", "parent": 805, "children": [], "start_point": {"row": 159, "column": 33}, "end_point": {"row": 159, "column": 34}}, {"id": 808, "type": "'", "text": "'", "parent": 805, "children": [], "start_point": {"row": 159, "column": 34}, "end_point": {"row": 159, "column": 35}}, {"id": 809, "type": "else_clause", "text": "else{\r\n notFirstWord = true;\r\n }", "parent": 795, "children": [], "start_point": {"row": 160, "column": 13}, "end_point": {"row": 162, "column": 13}}, {"id": 810, "type": "assignment_expression", "text": "notFirstWord = true", "parent": 809, "children": [811, 812, 813], "start_point": {"row": 161, "column": 16}, "end_point": {"row": 161, "column": 35}}, {"id": 811, "type": "identifier", "text": "notFirstWord", "parent": 810, "children": [], "start_point": {"row": 161, "column": 16}, "end_point": {"row": 161, "column": 28}}, {"id": 812, "type": "=", "text": "=", "parent": 810, "children": [], "start_point": {"row": 161, "column": 29}, "end_point": {"row": 161, "column": 30}}, {"id": 813, "type": "true", "text": "true", "parent": 810, "children": [], "start_point": {"row": 161, "column": 31}, "end_point": {"row": 161, "column": 35}}, {"id": 814, "type": "for_statement", "text": "for(j = start; j < end; j++){\r\n str[newpos++] = old[j];\r\n }", "parent": 785, "children": [815, 819, 822], "start_point": {"row": 164, "column": 12}, "end_point": {"row": 166, "column": 13}}, {"id": 815, "type": "assignment_expression", "text": "j = start", "parent": 814, "children": [816, 817, 818], "start_point": {"row": 164, "column": 16}, "end_point": {"row": 164, "column": 25}}, {"id": 816, "type": "identifier", "text": "j", "parent": 815, "children": [], "start_point": {"row": 164, "column": 16}, "end_point": {"row": 164, "column": 17}}, {"id": 817, "type": "=", "text": "=", "parent": 815, "children": [], "start_point": {"row": 164, "column": 18}, "end_point": {"row": 164, "column": 19}}, {"id": 818, "type": "identifier", "text": "start", "parent": 815, "children": [], "start_point": {"row": 164, "column": 20}, "end_point": {"row": 164, "column": 25}}, {"id": 819, "type": "binary_expression", "text": "j < end", "parent": 814, "children": [820, 821], "start_point": {"row": 164, "column": 27}, "end_point": {"row": 164, "column": 34}}, {"id": 820, "type": "identifier", "text": "j", "parent": 819, "children": [], "start_point": {"row": 164, "column": 27}, "end_point": {"row": 164, "column": 28}}, {"id": 821, "type": "<", "text": "<", "parent": 819, "children": [], "start_point": {"row": 164, "column": 29}, "end_point": {"row": 164, "column": 30}}, {"id": 822, "type": "update_expression", "text": "j++", "parent": 814, "children": [823, 824], "start_point": {"row": 164, "column": 36}, "end_point": {"row": 164, "column": 39}}, {"id": 823, "type": "identifier", "text": "j", "parent": 822, "children": [], "start_point": {"row": 164, "column": 36}, "end_point": {"row": 164, "column": 37}}, {"id": 824, "type": "++", "text": "++", "parent": 822, "children": [], "start_point": {"row": 164, "column": 37}, "end_point": {"row": 164, "column": 39}}, {"id": 825, "type": "assignment_expression", "text": "str[newpos++] = old[j]", "parent": 814, "children": [826, 831, 832], "start_point": {"row": 165, "column": 16}, "end_point": {"row": 165, "column": 38}}, {"id": 826, "type": "subscript_expression", "text": "str[newpos++]", "parent": 825, "children": [827, 828], "start_point": {"row": 165, "column": 16}, "end_point": {"row": 165, "column": 29}}, {"id": 827, "type": "identifier", "text": "str", "parent": 826, "children": [], "start_point": {"row": 165, "column": 16}, "end_point": {"row": 165, "column": 19}}, {"id": 828, "type": "update_expression", "text": "newpos++", "parent": 826, "children": [829, 830], "start_point": {"row": 165, "column": 20}, "end_point": {"row": 165, "column": 28}}, {"id": 829, "type": "identifier", "text": "newpos", "parent": 828, "children": [], "start_point": {"row": 165, "column": 20}, "end_point": {"row": 165, "column": 26}}, {"id": 830, "type": "++", "text": "++", "parent": 828, "children": [], "start_point": {"row": 165, "column": 26}, "end_point": {"row": 165, "column": 28}}, {"id": 831, "type": "=", "text": "=", "parent": 825, "children": [], "start_point": {"row": 165, "column": 30}, "end_point": {"row": 165, "column": 31}}, {"id": 832, "type": "subscript_expression", "text": "old[j]", "parent": 825, "children": [833, 834], "start_point": {"row": 165, "column": 32}, "end_point": {"row": 165, "column": 38}}, {"id": 833, "type": "identifier", "text": "old", "parent": 832, "children": [], "start_point": {"row": 165, "column": 32}, "end_point": {"row": 165, "column": 35}}, {"id": 834, "type": "identifier", "text": "j", "parent": 832, "children": [], "start_point": {"row": 165, "column": 36}, "end_point": {"row": 165, "column": 37}}, {"id": 835, "type": "assignment_expression", "text": "i = end", "parent": 758, "children": [836, 837], "start_point": {"row": 169, "column": 8}, "end_point": {"row": 169, "column": 15}}, {"id": 836, "type": "identifier", "text": "i", "parent": 835, "children": [], "start_point": {"row": 169, "column": 8}, "end_point": {"row": 169, "column": 9}}, {"id": 837, "type": "=", "text": "=", "parent": 835, "children": [], "start_point": {"row": 169, "column": 10}, "end_point": {"row": 169, "column": 11}}, {"id": 838, "type": "assignment_expression", "text": "str[newpos] = 0", "parent": 622, "children": [839, 842, 843], "start_point": {"row": 172, "column": 4}, "end_point": {"row": 172, "column": 19}}, {"id": 839, "type": "subscript_expression", "text": "str[newpos]", "parent": 838, "children": [840, 841], "start_point": {"row": 172, "column": 4}, "end_point": {"row": 172, "column": 15}}, {"id": 840, "type": "identifier", "text": "str", "parent": 839, "children": [], "start_point": {"row": 172, "column": 4}, "end_point": {"row": 172, "column": 7}}, {"id": 841, "type": "identifier", "text": "newpos", "parent": 839, "children": [], "start_point": {"row": 172, "column": 8}, "end_point": {"row": 172, "column": 14}}, {"id": 842, "type": "=", "text": "=", "parent": 838, "children": [], "start_point": {"row": 172, "column": 16}, "end_point": {"row": 172, "column": 17}}, {"id": 843, "type": "number_literal", "text": "0", "parent": 838, "children": [], "start_point": {"row": 172, "column": 18}, "end_point": {"row": 172, "column": 19}}, {"id": 844, "type": "call_expression", "text": "free(old)", "parent": 622, "children": [845, 846], "start_point": {"row": 174, "column": 4}, "end_point": {"row": 174, "column": 13}}, {"id": 845, "type": "identifier", "text": "free", "parent": 844, "children": [], "start_point": {"row": 174, "column": 4}, "end_point": {"row": 174, "column": 8}}, {"id": 846, "type": "argument_list", "text": "(old)", "parent": 844, "children": [847], "start_point": {"row": 174, "column": 8}, "end_point": {"row": 174, "column": 13}}, {"id": 847, "type": "identifier", "text": "old", "parent": 846, "children": [], "start_point": {"row": 174, "column": 9}, "end_point": {"row": 174, "column": 12}}, {"id": 848, "type": "return_statement", "text": "return str;", "parent": 622, "children": [849], "start_point": {"row": 175, "column": 4}, "end_point": {"row": 175, "column": 15}}, {"id": 849, "type": "identifier", "text": "str", "parent": 848, "children": [], "start_point": {"row": 175, "column": 11}, "end_point": {"row": 175, "column": 14}}, {"id": 850, "type": "function_definition", "text": "void format(char **lines){\r\n int i = 0;\r\n\r\n while(lines[i] != NULL){\r\n lines[i] = formatStr(lines[i]);\r\n i++;\r\n }\r\n}", "parent": null, "children": [851, 852], "start_point": {"row": 178, "column": 0}, "end_point": {"row": 185, "column": 1}}, {"id": 851, "type": "primitive_type", "text": "void", "parent": 850, "children": [], "start_point": {"row": 178, "column": 0}, "end_point": {"row": 178, "column": 4}}, {"id": 852, "type": "function_declarator", "text": "format(char **lines)", "parent": 850, "children": [853, 854], "start_point": {"row": 178, "column": 5}, "end_point": {"row": 178, "column": 25}}, {"id": 853, "type": "identifier", "text": "format", "parent": 852, "children": [], "start_point": {"row": 178, "column": 5}, "end_point": {"row": 178, "column": 11}}, {"id": 854, "type": "parameter_list", "text": "(char **lines)", "parent": 852, "children": [855], "start_point": {"row": 178, "column": 11}, "end_point": {"row": 178, "column": 25}}, {"id": 855, "type": "parameter_declaration", "text": "char **lines", "parent": 854, "children": [856, 857], "start_point": {"row": 178, "column": 12}, "end_point": {"row": 178, "column": 24}}, {"id": 856, "type": "primitive_type", "text": "char", "parent": 855, "children": [], "start_point": {"row": 178, "column": 12}, "end_point": {"row": 178, "column": 16}}, {"id": 857, "type": "pointer_declarator", "text": "**lines", "parent": 855, "children": [858, 859], "start_point": {"row": 178, "column": 17}, "end_point": {"row": 178, "column": 24}}, {"id": 858, "type": "*", "text": "*", "parent": 857, "children": [], "start_point": {"row": 178, "column": 17}, "end_point": {"row": 178, "column": 18}}, {"id": 859, "type": "pointer_declarator", "text": "*lines", "parent": 857, "children": [860, 861], "start_point": {"row": 178, "column": 18}, "end_point": {"row": 178, "column": 24}}, {"id": 860, "type": "*", "text": "*", "parent": 859, "children": [], "start_point": {"row": 178, "column": 18}, "end_point": {"row": 178, "column": 19}}, {"id": 861, "type": "identifier", "text": "lines", "parent": 859, "children": [], "start_point": {"row": 178, "column": 19}, "end_point": {"row": 178, "column": 24}}, {"id": 862, "type": "declaration", "text": "int i = 0;", "parent": 850, "children": [863, 864], "start_point": {"row": 179, "column": 4}, "end_point": {"row": 179, "column": 14}}, {"id": 863, "type": "primitive_type", "text": "int", "parent": 862, "children": [], "start_point": {"row": 179, "column": 4}, "end_point": {"row": 179, "column": 7}}, {"id": 864, "type": "init_declarator", "text": "i = 0", "parent": 862, "children": [865, 866, 867], "start_point": {"row": 179, "column": 8}, "end_point": {"row": 179, "column": 13}}, {"id": 865, "type": "identifier", "text": "i", "parent": 864, "children": [], "start_point": {"row": 179, "column": 8}, "end_point": {"row": 179, "column": 9}}, {"id": 866, "type": "=", "text": "=", "parent": 864, "children": [], "start_point": {"row": 179, "column": 10}, "end_point": {"row": 179, "column": 11}}, {"id": 867, "type": "number_literal", "text": "0", "parent": 864, "children": [], "start_point": {"row": 179, "column": 12}, "end_point": {"row": 179, "column": 13}}, {"id": 868, "type": "while_statement", "text": "while(lines[i] != NULL){\r\n lines[i] = formatStr(lines[i]);\r\n i++;\r\n }", "parent": 850, "children": [869], "start_point": {"row": 181, "column": 4}, "end_point": {"row": 184, "column": 5}}, {"id": 869, "type": "parenthesized_expression", "text": "(lines[i] != NULL)", "parent": 868, "children": [870], "start_point": {"row": 181, "column": 9}, "end_point": {"row": 181, "column": 27}}, {"id": 870, "type": "binary_expression", "text": "lines[i] != NULL", "parent": 869, "children": [871, 874, 875], "start_point": {"row": 181, "column": 10}, "end_point": {"row": 181, "column": 26}}, {"id": 871, "type": "subscript_expression", "text": "lines[i]", "parent": 870, "children": [872, 873], "start_point": {"row": 181, "column": 10}, "end_point": {"row": 181, "column": 18}}, {"id": 872, "type": "identifier", "text": "lines", "parent": 871, "children": [], "start_point": {"row": 181, "column": 10}, "end_point": {"row": 181, "column": 15}}, {"id": 873, "type": "identifier", "text": "i", "parent": 871, "children": [], "start_point": {"row": 181, "column": 16}, "end_point": {"row": 181, "column": 17}}, {"id": 874, "type": "!=", "text": "!=", "parent": 870, "children": [], "start_point": {"row": 181, "column": 19}, "end_point": {"row": 181, "column": 21}}, {"id": 875, "type": "null", "text": "NULL", "parent": 870, "children": [876], "start_point": {"row": 181, "column": 22}, "end_point": {"row": 181, "column": 26}}, {"id": 876, "type": "NULL", "text": "NULL", "parent": 875, "children": [], "start_point": {"row": 181, "column": 22}, "end_point": {"row": 181, "column": 26}}, {"id": 877, "type": "assignment_expression", "text": "lines[i] = formatStr(lines[i])", "parent": 868, "children": [878, 881, 882], "start_point": {"row": 182, "column": 8}, "end_point": {"row": 182, "column": 38}}, {"id": 878, "type": "subscript_expression", "text": "lines[i]", "parent": 877, "children": [879, 880], "start_point": {"row": 182, "column": 8}, "end_point": {"row": 182, "column": 16}}, {"id": 879, "type": "identifier", "text": "lines", "parent": 878, "children": [], "start_point": {"row": 182, "column": 8}, "end_point": {"row": 182, "column": 13}}, {"id": 880, "type": "identifier", "text": "i", "parent": 878, "children": [], "start_point": {"row": 182, "column": 14}, "end_point": {"row": 182, "column": 15}}, {"id": 881, "type": "=", "text": "=", "parent": 877, "children": [], "start_point": {"row": 182, "column": 17}, "end_point": {"row": 182, "column": 18}}, {"id": 882, "type": "call_expression", "text": "formatStr(lines[i])", "parent": 877, "children": [883, 884], "start_point": {"row": 182, "column": 19}, "end_point": {"row": 182, "column": 38}}, {"id": 883, "type": "identifier", "text": "formatStr", "parent": 882, "children": [], "start_point": {"row": 182, "column": 19}, "end_point": {"row": 182, "column": 28}}, {"id": 884, "type": "argument_list", "text": "(lines[i])", "parent": 882, "children": [885], "start_point": {"row": 182, "column": 28}, "end_point": {"row": 182, "column": 38}}, {"id": 885, "type": "subscript_expression", "text": "lines[i]", "parent": 884, "children": [886, 887], "start_point": {"row": 182, "column": 29}, "end_point": {"row": 182, "column": 37}}, {"id": 886, "type": "identifier", "text": "lines", "parent": 885, "children": [], "start_point": {"row": 182, "column": 29}, "end_point": {"row": 182, "column": 34}}, {"id": 887, "type": "identifier", "text": "i", "parent": 885, "children": [], "start_point": {"row": 182, "column": 35}, "end_point": {"row": 182, "column": 36}}, {"id": 888, "type": "update_expression", "text": "i++", "parent": 868, "children": [889, 890], "start_point": {"row": 183, "column": 8}, "end_point": {"row": 183, "column": 11}}, {"id": 889, "type": "identifier", "text": "i", "parent": 888, "children": [], "start_point": {"row": 183, "column": 8}, "end_point": {"row": 183, "column": 9}}, {"id": 890, "type": "++", "text": "++", "parent": 888, "children": [], "start_point": {"row": 183, "column": 9}, "end_point": {"row": 183, "column": 11}}, {"id": 891, "type": "function_definition", "text": "void printStr(char *str){\r\n char c = 0;\r\n while(c = *(str++)){\r\n putc(c, stdout);\r\n\r\n if(c == '.'){\r\n printf(\"\\n\\t\");\r\n }\r\n }\r\n putc('\\n', stdout);\r\n}", "parent": null, "children": [892, 893], "start_point": {"row": 187, "column": 0}, "end_point": {"row": 197, "column": 1}}, {"id": 892, "type": "primitive_type", "text": "void", "parent": 891, "children": [], "start_point": {"row": 187, "column": 0}, "end_point": {"row": 187, "column": 4}}, {"id": 893, "type": "function_declarator", "text": "printStr(char *str)", "parent": 891, "children": [894, 895], "start_point": {"row": 187, "column": 5}, "end_point": {"row": 187, "column": 24}}, {"id": 894, "type": "identifier", "text": "printStr", "parent": 893, "children": [], "start_point": {"row": 187, "column": 5}, "end_point": {"row": 187, "column": 13}}, {"id": 895, "type": "parameter_list", "text": "(char *str)", "parent": 893, "children": [896], "start_point": {"row": 187, "column": 13}, "end_point": {"row": 187, "column": 24}}, {"id": 896, "type": "parameter_declaration", "text": "char *str", "parent": 895, "children": [897, 898], "start_point": {"row": 187, "column": 14}, "end_point": {"row": 187, "column": 23}}, {"id": 897, "type": "primitive_type", "text": "char", "parent": 896, "children": [], "start_point": {"row": 187, "column": 14}, "end_point": {"row": 187, "column": 18}}, {"id": 898, "type": "pointer_declarator", "text": "*str", "parent": 896, "children": [899, 900], "start_point": {"row": 187, "column": 19}, "end_point": {"row": 187, "column": 23}}, {"id": 899, "type": "*", "text": "*", "parent": 898, "children": [], "start_point": {"row": 187, "column": 19}, "end_point": {"row": 187, "column": 20}}, {"id": 900, "type": "identifier", "text": "str", "parent": 898, "children": [], "start_point": {"row": 187, "column": 20}, "end_point": {"row": 187, "column": 23}}, {"id": 901, "type": "declaration", "text": "char c = 0;", "parent": 891, "children": [902, 903], "start_point": {"row": 188, "column": 4}, "end_point": {"row": 188, "column": 15}}, {"id": 902, "type": "primitive_type", "text": "char", "parent": 901, "children": [], "start_point": {"row": 188, "column": 4}, "end_point": {"row": 188, "column": 8}}, {"id": 903, "type": "init_declarator", "text": "c = 0", "parent": 901, "children": [904, 905, 906], "start_point": {"row": 188, "column": 9}, "end_point": {"row": 188, "column": 14}}, {"id": 904, "type": "identifier", "text": "c", "parent": 903, "children": [], "start_point": {"row": 188, "column": 9}, "end_point": {"row": 188, "column": 10}}, {"id": 905, "type": "=", "text": "=", "parent": 903, "children": [], "start_point": {"row": 188, "column": 11}, "end_point": {"row": 188, "column": 12}}, {"id": 906, "type": "number_literal", "text": "0", "parent": 903, "children": [], "start_point": {"row": 188, "column": 13}, "end_point": {"row": 188, "column": 14}}, {"id": 907, "type": "while_statement", "text": "while(c = *(str++)){\r\n putc(c, stdout);\r\n\r\n if(c == '.'){\r\n printf(\"\\n\\t\");\r\n }\r\n }", "parent": 891, "children": [908], "start_point": {"row": 189, "column": 4}, "end_point": {"row": 195, "column": 5}}, {"id": 908, "type": "parenthesized_expression", "text": "(c = *(str++))", "parent": 907, "children": [909], "start_point": {"row": 189, "column": 9}, "end_point": {"row": 189, "column": 23}}, {"id": 909, "type": "assignment_expression", "text": "c = *(str++)", "parent": 908, "children": [910, 911, 912], "start_point": {"row": 189, "column": 10}, "end_point": {"row": 189, "column": 22}}, {"id": 910, "type": "identifier", "text": "c", "parent": 909, "children": [], "start_point": {"row": 189, "column": 10}, "end_point": {"row": 189, "column": 11}}, {"id": 911, "type": "=", "text": "=", "parent": 909, "children": [], "start_point": {"row": 189, "column": 12}, "end_point": {"row": 189, "column": 13}}, {"id": 912, "type": "pointer_expression", "text": "*(str++)", "parent": 909, "children": [913, 914], "start_point": {"row": 189, "column": 14}, "end_point": {"row": 189, "column": 22}}, {"id": 913, "type": "*", "text": "*", "parent": 912, "children": [], "start_point": {"row": 189, "column": 14}, "end_point": {"row": 189, "column": 15}}, {"id": 914, "type": "parenthesized_expression", "text": "(str++)", "parent": 912, "children": [915], "start_point": {"row": 189, "column": 15}, "end_point": {"row": 189, "column": 22}}, {"id": 915, "type": "update_expression", "text": "str++", "parent": 914, "children": [916, 917], "start_point": {"row": 189, "column": 16}, "end_point": {"row": 189, "column": 21}}, {"id": 916, "type": "identifier", "text": "str", "parent": 915, "children": [], "start_point": {"row": 189, "column": 16}, "end_point": {"row": 189, "column": 19}}, {"id": 917, "type": "++", "text": "++", "parent": 915, "children": [], "start_point": {"row": 189, "column": 19}, "end_point": {"row": 189, "column": 21}}, {"id": 918, "type": "call_expression", "text": "putc(c, stdout)", "parent": 907, "children": [919, 920], "start_point": {"row": 190, "column": 8}, "end_point": {"row": 190, "column": 23}}, {"id": 919, "type": "identifier", "text": "putc", "parent": 918, "children": [], "start_point": {"row": 190, "column": 8}, "end_point": {"row": 190, "column": 12}}, {"id": 920, "type": "argument_list", "text": "(c, stdout)", "parent": 918, "children": [921, 922], "start_point": {"row": 190, "column": 12}, "end_point": {"row": 190, "column": 23}}, {"id": 921, "type": "identifier", "text": "c", "parent": 920, "children": [], "start_point": {"row": 190, "column": 13}, "end_point": {"row": 190, "column": 14}}, {"id": 922, "type": "identifier", "text": "stdout", "parent": 920, "children": [], "start_point": {"row": 190, "column": 16}, "end_point": {"row": 190, "column": 22}}, {"id": 923, "type": "if_statement", "text": "if(c == '.'){\r\n printf(\"\\n\\t\");\r\n }", "parent": 907, "children": [924], "start_point": {"row": 192, "column": 8}, "end_point": {"row": 194, "column": 9}}, {"id": 924, "type": "parenthesized_expression", "text": "(c == '.')", "parent": 923, "children": [925], "start_point": {"row": 192, "column": 10}, "end_point": {"row": 192, "column": 20}}, {"id": 925, "type": "binary_expression", "text": "c == '.'", "parent": 924, "children": [926, 927, 928], "start_point": {"row": 192, "column": 11}, "end_point": {"row": 192, "column": 19}}, {"id": 926, "type": "identifier", "text": "c", "parent": 925, "children": [], "start_point": {"row": 192, "column": 11}, "end_point": {"row": 192, "column": 12}}, {"id": 927, "type": "==", "text": "==", "parent": 925, "children": [], "start_point": {"row": 192, "column": 13}, "end_point": {"row": 192, "column": 15}}, {"id": 928, "type": "char_literal", "text": "'.'", "parent": 925, "children": [929, 930], "start_point": {"row": 192, "column": 16}, "end_point": {"row": 192, "column": 19}}, {"id": 929, "type": "'", "text": "'", "parent": 928, "children": [], "start_point": {"row": 192, "column": 16}, "end_point": {"row": 192, "column": 17}}, {"id": 930, "type": "'", "text": "'", "parent": 928, "children": [], "start_point": {"row": 192, "column": 18}, "end_point": {"row": 192, "column": 19}}, {"id": 931, "type": "call_expression", "text": "printf(\"\\n\\t\")", "parent": 923, "children": [932, 933], "start_point": {"row": 193, "column": 12}, "end_point": {"row": 193, "column": 26}}, {"id": 932, "type": "identifier", "text": "printf", "parent": 931, "children": [], "start_point": {"row": 193, "column": 12}, "end_point": {"row": 193, "column": 18}}, {"id": 933, "type": "argument_list", "text": "(\"\\n\\t\")", "parent": 931, "children": [934], "start_point": {"row": 193, "column": 18}, "end_point": {"row": 193, "column": 26}}, {"id": 934, "type": "string_literal", "text": "\"\\n\\t\"", "parent": 933, "children": [935, 936], "start_point": {"row": 193, "column": 19}, "end_point": {"row": 193, "column": 25}}, {"id": 935, "type": "escape_sequence", "text": "\\n", "parent": 934, "children": [], "start_point": {"row": 193, "column": 20}, "end_point": {"row": 193, "column": 22}}, {"id": 936, "type": "escape_sequence", "text": "\\t", "parent": 934, "children": [], "start_point": {"row": 193, "column": 22}, "end_point": {"row": 193, "column": 24}}, {"id": 937, "type": "call_expression", "text": "putc('\\n', stdout)", "parent": 891, "children": [938, 939], "start_point": {"row": 196, "column": 4}, "end_point": {"row": 196, "column": 22}}, {"id": 938, "type": "identifier", "text": "putc", "parent": 937, "children": [], "start_point": {"row": 196, "column": 4}, "end_point": {"row": 196, "column": 8}}, {"id": 939, "type": "argument_list", "text": "('\\n', stdout)", "parent": 937, "children": [940, 944], "start_point": {"row": 196, "column": 8}, "end_point": {"row": 196, "column": 22}}, {"id": 940, "type": "char_literal", "text": "'\\n'", "parent": 939, "children": [941, 942, 943], "start_point": {"row": 196, "column": 9}, "end_point": {"row": 196, "column": 13}}, {"id": 941, "type": "'", "text": "'", "parent": 940, "children": [], "start_point": {"row": 196, "column": 9}, "end_point": {"row": 196, "column": 10}}, {"id": 942, "type": "escape_sequence", "text": "\\n", "parent": 940, "children": [], "start_point": {"row": 196, "column": 10}, "end_point": {"row": 196, "column": 12}}, {"id": 943, "type": "'", "text": "'", "parent": 940, "children": [], "start_point": {"row": 196, "column": 12}, "end_point": {"row": 196, "column": 13}}, {"id": 944, "type": "identifier", "text": "stdout", "parent": 939, "children": [], "start_point": {"row": 196, "column": 15}, "end_point": {"row": 196, "column": 21}}, {"id": 945, "type": "function_definition", "text": "void printFormat(char **lines){\r\n int i = 0;\r\n while(lines[i] != NULL){\r\n printStr(lines[i]);\r\n i++;\r\n }\r\n}", "parent": null, "children": [946, 947], "start_point": {"row": 199, "column": 0}, "end_point": {"row": 205, "column": 1}}, {"id": 946, "type": "primitive_type", "text": "void", "parent": 945, "children": [], "start_point": {"row": 199, "column": 0}, "end_point": {"row": 199, "column": 4}}, {"id": 947, "type": "function_declarator", "text": "printFormat(char **lines)", "parent": 945, "children": [948, 949], "start_point": {"row": 199, "column": 5}, "end_point": {"row": 199, "column": 30}}, {"id": 948, "type": "identifier", "text": "printFormat", "parent": 947, "children": [], "start_point": {"row": 199, "column": 5}, "end_point": {"row": 199, "column": 16}}, {"id": 949, "type": "parameter_list", "text": "(char **lines)", "parent": 947, "children": [950], "start_point": {"row": 199, "column": 16}, "end_point": {"row": 199, "column": 30}}, {"id": 950, "type": "parameter_declaration", "text": "char **lines", "parent": 949, "children": [951, 952], "start_point": {"row": 199, "column": 17}, "end_point": {"row": 199, "column": 29}}, {"id": 951, "type": "primitive_type", "text": "char", "parent": 950, "children": [], "start_point": {"row": 199, "column": 17}, "end_point": {"row": 199, "column": 21}}, {"id": 952, "type": "pointer_declarator", "text": "**lines", "parent": 950, "children": [953, 954], "start_point": {"row": 199, "column": 22}, "end_point": {"row": 199, "column": 29}}, {"id": 953, "type": "*", "text": "*", "parent": 952, "children": [], "start_point": {"row": 199, "column": 22}, "end_point": {"row": 199, "column": 23}}, {"id": 954, "type": "pointer_declarator", "text": "*lines", "parent": 952, "children": [955, 956], "start_point": {"row": 199, "column": 23}, "end_point": {"row": 199, "column": 29}}, {"id": 955, "type": "*", "text": "*", "parent": 954, "children": [], "start_point": {"row": 199, "column": 23}, "end_point": {"row": 199, "column": 24}}, {"id": 956, "type": "identifier", "text": "lines", "parent": 954, "children": [], "start_point": {"row": 199, "column": 24}, "end_point": {"row": 199, "column": 29}}, {"id": 957, "type": "declaration", "text": "int i = 0;", "parent": 945, "children": [958, 959], "start_point": {"row": 200, "column": 4}, "end_point": {"row": 200, "column": 14}}, {"id": 958, "type": "primitive_type", "text": "int", "parent": 957, "children": [], "start_point": {"row": 200, "column": 4}, "end_point": {"row": 200, "column": 7}}, {"id": 959, "type": "init_declarator", "text": "i = 0", "parent": 957, "children": [960, 961, 962], "start_point": {"row": 200, "column": 8}, "end_point": {"row": 200, "column": 13}}, {"id": 960, "type": "identifier", "text": "i", "parent": 959, "children": [], "start_point": {"row": 200, "column": 8}, "end_point": {"row": 200, "column": 9}}, {"id": 961, "type": "=", "text": "=", "parent": 959, "children": [], "start_point": {"row": 200, "column": 10}, "end_point": {"row": 200, "column": 11}}, {"id": 962, "type": "number_literal", "text": "0", "parent": 959, "children": [], "start_point": {"row": 200, "column": 12}, "end_point": {"row": 200, "column": 13}}, {"id": 963, "type": "while_statement", "text": "while(lines[i] != NULL){\r\n printStr(lines[i]);\r\n i++;\r\n }", "parent": 945, "children": [964], "start_point": {"row": 201, "column": 4}, "end_point": {"row": 204, "column": 5}}, {"id": 964, "type": "parenthesized_expression", "text": "(lines[i] != NULL)", "parent": 963, "children": [965], "start_point": {"row": 201, "column": 9}, "end_point": {"row": 201, "column": 27}}, {"id": 965, "type": "binary_expression", "text": "lines[i] != NULL", "parent": 964, "children": [966, 969, 970], "start_point": {"row": 201, "column": 10}, "end_point": {"row": 201, "column": 26}}, {"id": 966, "type": "subscript_expression", "text": "lines[i]", "parent": 965, "children": [967, 968], "start_point": {"row": 201, "column": 10}, "end_point": {"row": 201, "column": 18}}, {"id": 967, "type": "identifier", "text": "lines", "parent": 966, "children": [], "start_point": {"row": 201, "column": 10}, "end_point": {"row": 201, "column": 15}}, {"id": 968, "type": "identifier", "text": "i", "parent": 966, "children": [], "start_point": {"row": 201, "column": 16}, "end_point": {"row": 201, "column": 17}}, {"id": 969, "type": "!=", "text": "!=", "parent": 965, "children": [], "start_point": {"row": 201, "column": 19}, "end_point": {"row": 201, "column": 21}}, {"id": 970, "type": "null", "text": "NULL", "parent": 965, "children": [971], "start_point": {"row": 201, "column": 22}, "end_point": {"row": 201, "column": 26}}, {"id": 971, "type": "NULL", "text": "NULL", "parent": 970, "children": [], "start_point": {"row": 201, "column": 22}, "end_point": {"row": 201, "column": 26}}, {"id": 972, "type": "call_expression", "text": "printStr(lines[i])", "parent": 963, "children": [973, 974], "start_point": {"row": 202, "column": 8}, "end_point": {"row": 202, "column": 26}}, {"id": 973, "type": "identifier", "text": "printStr", "parent": 972, "children": [], "start_point": {"row": 202, "column": 8}, "end_point": {"row": 202, "column": 16}}, {"id": 974, "type": "argument_list", "text": "(lines[i])", "parent": 972, "children": [975], "start_point": {"row": 202, "column": 16}, "end_point": {"row": 202, "column": 26}}, {"id": 975, "type": "subscript_expression", "text": "lines[i]", "parent": 974, "children": [976, 977], "start_point": {"row": 202, "column": 17}, "end_point": {"row": 202, "column": 25}}, {"id": 976, "type": "identifier", "text": "lines", "parent": 975, "children": [], "start_point": {"row": 202, "column": 17}, "end_point": {"row": 202, "column": 22}}, {"id": 977, "type": "identifier", "text": "i", "parent": 975, "children": [], "start_point": {"row": 202, "column": 23}, "end_point": {"row": 202, "column": 24}}, {"id": 978, "type": "update_expression", "text": "i++", "parent": 963, "children": [979, 980], "start_point": {"row": 203, "column": 8}, "end_point": {"row": 203, "column": 11}}, {"id": 979, "type": "identifier", "text": "i", "parent": 978, "children": [], "start_point": {"row": 203, "column": 8}, "end_point": {"row": 203, "column": 9}}, {"id": 980, "type": "++", "text": "++", "parent": 978, "children": [], "start_point": {"row": 203, "column": 9}, "end_point": {"row": 203, "column": 11}}, {"id": 981, "type": "function_definition", "text": "int main(){\r\n char **lines = NULL;\r\n int size = 0;\r\n char c = 0;\r\n int i = 0, j, k;\r\n\r\n lines = readLines();\r\n\r\n format(lines);\r\n\r\n printFormat(lines);\r\n\r\n freeLines(lines);\r\n \r\n return 0;\r\n}", "parent": null, "children": [982, 983], "start_point": {"row": 207, "column": 0}, "end_point": {"row": 222, "column": 1}}, {"id": 982, "type": "primitive_type", "text": "int", "parent": 981, "children": [], "start_point": {"row": 207, "column": 0}, "end_point": {"row": 207, "column": 3}}, {"id": 983, "type": "function_declarator", "text": "main()", "parent": 981, "children": [984, 985], "start_point": {"row": 207, "column": 4}, "end_point": {"row": 207, "column": 10}}, {"id": 984, "type": "identifier", "text": "main", "parent": 983, "children": [], "start_point": {"row": 207, "column": 4}, "end_point": {"row": 207, "column": 8}}, {"id": 985, "type": "parameter_list", "text": "()", "parent": 983, "children": [], "start_point": {"row": 207, "column": 8}, "end_point": {"row": 207, "column": 10}}, {"id": 986, "type": "declaration", "text": "char **lines = NULL;", "parent": 981, "children": [987, 988], "start_point": {"row": 208, "column": 4}, "end_point": {"row": 208, "column": 24}}, {"id": 987, "type": "primitive_type", "text": "char", "parent": 986, "children": [], "start_point": {"row": 208, "column": 4}, "end_point": {"row": 208, "column": 8}}, {"id": 988, "type": "init_declarator", "text": "**lines = NULL", "parent": 986, "children": [989, 994, 995], "start_point": {"row": 208, "column": 9}, "end_point": {"row": 208, "column": 23}}, {"id": 989, "type": "pointer_declarator", "text": "**lines", "parent": 988, "children": [990, 991], "start_point": {"row": 208, "column": 9}, "end_point": {"row": 208, "column": 16}}, {"id": 990, "type": "*", "text": "*", "parent": 989, "children": [], "start_point": {"row": 208, "column": 9}, "end_point": {"row": 208, "column": 10}}, {"id": 991, "type": "pointer_declarator", "text": "*lines", "parent": 989, "children": [992, 993], "start_point": {"row": 208, "column": 10}, "end_point": {"row": 208, "column": 16}}, {"id": 992, "type": "*", "text": "*", "parent": 991, "children": [], "start_point": {"row": 208, "column": 10}, "end_point": {"row": 208, "column": 11}}, {"id": 993, "type": "identifier", "text": "lines", "parent": 991, "children": [], "start_point": {"row": 208, "column": 11}, "end_point": {"row": 208, "column": 16}}, {"id": 994, "type": "=", "text": "=", "parent": 988, "children": [], "start_point": {"row": 208, "column": 17}, "end_point": {"row": 208, "column": 18}}, {"id": 995, "type": "null", "text": "NULL", "parent": 988, "children": [996], "start_point": {"row": 208, "column": 19}, "end_point": {"row": 208, "column": 23}}, {"id": 996, "type": "NULL", "text": "NULL", "parent": 995, "children": [], "start_point": {"row": 208, "column": 19}, "end_point": {"row": 208, "column": 23}}, {"id": 997, "type": "declaration", "text": "int size = 0;", "parent": 981, "children": [998, 999], "start_point": {"row": 209, "column": 4}, "end_point": {"row": 209, "column": 17}}, {"id": 998, "type": "primitive_type", "text": "int", "parent": 997, "children": [], "start_point": {"row": 209, "column": 4}, "end_point": {"row": 209, "column": 7}}, {"id": 999, "type": "init_declarator", "text": "size = 0", "parent": 997, "children": [1000, 1001, 1002], "start_point": {"row": 209, "column": 8}, "end_point": {"row": 209, "column": 16}}, {"id": 1000, "type": "identifier", "text": "size", "parent": 999, "children": [], "start_point": {"row": 209, "column": 8}, "end_point": {"row": 209, "column": 12}}, {"id": 1001, "type": "=", "text": "=", "parent": 999, "children": [], "start_point": {"row": 209, "column": 13}, "end_point": {"row": 209, "column": 14}}, {"id": 1002, "type": "number_literal", "text": "0", "parent": 999, "children": [], "start_point": {"row": 209, "column": 15}, "end_point": {"row": 209, "column": 16}}, {"id": 1003, "type": "declaration", "text": "char c = 0;", "parent": 981, "children": [1004, 1005], "start_point": {"row": 210, "column": 4}, "end_point": {"row": 210, "column": 15}}, {"id": 1004, "type": "primitive_type", "text": "char", "parent": 1003, "children": [], "start_point": {"row": 210, "column": 4}, "end_point": {"row": 210, "column": 8}}, {"id": 1005, "type": "init_declarator", "text": "c = 0", "parent": 1003, "children": [1006, 1007, 1008], "start_point": {"row": 210, "column": 9}, "end_point": {"row": 210, "column": 14}}, {"id": 1006, "type": "identifier", "text": "c", "parent": 1005, "children": [], "start_point": {"row": 210, "column": 9}, "end_point": {"row": 210, "column": 10}}, {"id": 1007, "type": "=", "text": "=", "parent": 1005, "children": [], "start_point": {"row": 210, "column": 11}, "end_point": {"row": 210, "column": 12}}, {"id": 1008, "type": "number_literal", "text": "0", "parent": 1005, "children": [], "start_point": {"row": 210, "column": 13}, "end_point": {"row": 210, "column": 14}}, {"id": 1009, "type": "declaration", "text": "int i = 0, j, k;", "parent": 981, "children": [1010, 1011, 1015, 1016], "start_point": {"row": 211, "column": 4}, "end_point": {"row": 211, "column": 20}}, {"id": 1010, "type": "primitive_type", "text": "int", "parent": 1009, "children": [], "start_point": {"row": 211, "column": 4}, "end_point": {"row": 211, "column": 7}}, {"id": 1011, "type": "init_declarator", "text": "i = 0", "parent": 1009, "children": [1012, 1013, 1014], "start_point": {"row": 211, "column": 8}, "end_point": {"row": 211, "column": 13}}, {"id": 1012, "type": "identifier", "text": "i", "parent": 1011, "children": [], "start_point": {"row": 211, "column": 8}, "end_point": {"row": 211, "column": 9}}, {"id": 1013, "type": "=", "text": "=", "parent": 1011, "children": [], "start_point": {"row": 211, "column": 10}, "end_point": {"row": 211, "column": 11}}, {"id": 1014, "type": "number_literal", "text": "0", "parent": 1011, "children": [], "start_point": {"row": 211, "column": 12}, "end_point": {"row": 211, "column": 13}}, {"id": 1015, "type": "identifier", "text": "j", "parent": 1009, "children": [], "start_point": {"row": 211, "column": 15}, "end_point": {"row": 211, "column": 16}}, {"id": 1016, "type": "identifier", "text": "k", "parent": 1009, "children": [], "start_point": {"row": 211, "column": 18}, "end_point": {"row": 211, "column": 19}}, {"id": 1017, "type": "assignment_expression", "text": "lines = readLines()", "parent": 981, "children": [1018, 1019, 1020], "start_point": {"row": 213, "column": 4}, "end_point": {"row": 213, "column": 23}}, {"id": 1018, "type": "identifier", "text": "lines", "parent": 1017, "children": [], "start_point": {"row": 213, "column": 4}, "end_point": {"row": 213, "column": 9}}, {"id": 1019, "type": "=", "text": "=", "parent": 1017, "children": [], "start_point": {"row": 213, "column": 10}, "end_point": {"row": 213, "column": 11}}, {"id": 1020, "type": "call_expression", "text": "readLines()", "parent": 1017, "children": [1021, 1022], "start_point": {"row": 213, "column": 12}, "end_point": {"row": 213, "column": 23}}, {"id": 1021, "type": "identifier", "text": "readLines", "parent": 1020, "children": [], "start_point": {"row": 213, "column": 12}, "end_point": {"row": 213, "column": 21}}, {"id": 1022, "type": "argument_list", "text": "()", "parent": 1020, "children": [], "start_point": {"row": 213, "column": 21}, "end_point": {"row": 213, "column": 23}}, {"id": 1023, "type": "call_expression", "text": "format(lines)", "parent": 981, "children": [1024, 1025], "start_point": {"row": 215, "column": 4}, "end_point": {"row": 215, "column": 17}}, {"id": 1024, "type": "identifier", "text": "format", "parent": 1023, "children": [], "start_point": {"row": 215, "column": 4}, "end_point": {"row": 215, "column": 10}}, {"id": 1025, "type": "argument_list", "text": "(lines)", "parent": 1023, "children": [1026], "start_point": {"row": 215, "column": 10}, "end_point": {"row": 215, "column": 17}}, {"id": 1026, "type": "identifier", "text": "lines", "parent": 1025, "children": [], "start_point": {"row": 215, "column": 11}, "end_point": {"row": 215, "column": 16}}, {"id": 1027, "type": "call_expression", "text": "printFormat(lines)", "parent": 981, "children": [1028, 1029], "start_point": {"row": 217, "column": 4}, "end_point": {"row": 217, "column": 22}}, {"id": 1028, "type": "identifier", "text": "printFormat", "parent": 1027, "children": [], "start_point": {"row": 217, "column": 4}, "end_point": {"row": 217, "column": 15}}, {"id": 1029, "type": "argument_list", "text": "(lines)", "parent": 1027, "children": [1030], "start_point": {"row": 217, "column": 15}, "end_point": {"row": 217, "column": 22}}, {"id": 1030, "type": "identifier", "text": "lines", "parent": 1029, "children": [], "start_point": {"row": 217, "column": 16}, "end_point": {"row": 217, "column": 21}}, {"id": 1031, "type": "call_expression", "text": "freeLines(lines)", "parent": 981, "children": [1032, 1033], "start_point": {"row": 219, "column": 4}, "end_point": {"row": 219, "column": 20}}, {"id": 1032, "type": "identifier", "text": "freeLines", "parent": 1031, "children": [], "start_point": {"row": 219, "column": 4}, "end_point": {"row": 219, "column": 13}}, {"id": 1033, "type": "argument_list", "text": "(lines)", "parent": 1031, "children": [1034], "start_point": {"row": 219, "column": 13}, "end_point": {"row": 219, "column": 20}}, {"id": 1034, "type": "identifier", "text": "lines", "parent": 1033, "children": [], "start_point": {"row": 219, "column": 14}, "end_point": {"row": 219, "column": 19}}, {"id": 1035, "type": "return_statement", "text": "return 0;", "parent": 981, "children": [1036], "start_point": {"row": 221, "column": 4}, "end_point": {"row": 221, "column": 13}}, {"id": 1036, "type": "number_literal", "text": "0", "parent": 1035, "children": [], "start_point": {"row": 221, "column": 11}, "end_point": {"row": 221, "column": 12}}]}, "node_categories": {"declarations": {"functions": [12, 14, 46, 48, 76, 78, 116, 118, 158, 160, 225, 229, 324, 328, 443, 449, 583, 585, 622, 626, 850, 852, 891, 893, 945, 947, 981, 983], "variables": [17, 51, 81, 86, 89, 121, 126, 129, 163, 168, 232, 237, 246, 262, 331, 337, 353, 359, 452, 458, 465, 485, 494, 588, 595, 629, 634, 656, 662, 684, 694, 766, 776, 855, 862, 896, 901, 950, 957, 986, 997, 1003, 1009], "classes": [], "imports": [0, 1, 3, 4, 6, 7, 9, 10], "modules": [], "enums": []}, "statements": {"expressions": [21, 22, 23, 31, 39, 55, 56, 57, 65, 96, 97, 98, 101, 105, 106, 111, 136, 137, 138, 140, 143, 147, 148, 153, 179, 180, 181, 189, 195, 196, 197, 205, 206, 209, 212, 218, 242, 253, 256, 259, 273, 274, 275, 283, 289, 290, 291, 299, 300, 303, 307, 309, 317, 344, 347, 350, 366, 369, 370, 377, 384, 388, 391, 397, 402, 403, 411, 413, 421, 423, 431, 435, 438, 474, 477, 478, 492, 501, 505, 506, 508, 512, 513, 515, 520, 522, 531, 533, 539, 540, 547, 554, 558, 559, 569, 573, 576, 602, 603, 604, 610, 613, 615, 618, 641, 644, 645, 646, 650, 677, 678, 679, 689, 698, 704, 705, 708, 712, 715, 717, 735, 738, 742, 744, 748, 759, 760, 761, 771, 780, 786, 787, 789, 792, 796, 799, 801, 819, 822, 826, 828, 832, 839, 844, 869, 870, 871, 878, 882, 885, 888, 908, 912, 914, 915, 918, 924, 925, 931, 937, 964, 965, 966, 972, 975, 978, 1020, 1023, 1027, 1031], "assignments": [186, 215, 280, 306, 314, 374, 381, 394, 410, 420, 428, 519, 530, 544, 551, 566, 668, 672, 714, 726, 731, 741, 751, 754, 798, 810, 815, 825, 835, 838, 877, 909, 1017], "loops": [95, 135, 178, 272, 365, 491, 601, 676, 730, 758, 814, 868, 907, 963], "conditionals": [15, 19, 24, 32, 40, 49, 53, 54, 58, 66, 79, 85, 88, 92, 94, 99, 102, 103, 107, 108, 112, 115, 119, 125, 128, 132, 134, 141, 144, 145, 149, 150, 154, 157, 161, 167, 171, 175, 182, 183, 187, 190, 192, 193, 194, 198, 199, 204, 207, 210, 211, 213, 216, 219, 221, 222, 224, 230, 236, 240, 243, 245, 251, 254, 257, 265, 269, 276, 277, 281, 284, 286, 287, 288, 292, 293, 298, 301, 304, 305, 308, 310, 313, 315, 318, 320, 321, 323, 329, 334, 342, 345, 348, 356, 362, 368, 371, 373, 375, 380, 382, 385, 387, 389, 395, 398, 400, 401, 404, 412, 414, 422, 424, 427, 429, 432, 434, 436, 442, 450, 455, 472, 475, 484, 488, 499, 502, 504, 509, 511, 516, 518, 521, 523, 532, 534, 537, 538, 541, 543, 545, 550, 552, 555, 557, 565, 567, 570, 572, 574, 582, 586, 594, 598, 605, 606, 611, 614, 616, 619, 621, 627, 633, 639, 642, 651, 653, 658, 659, 660, 661, 665, 669, 673, 680, 681, 687, 690, 692, 693, 699, 701, 702, 703, 706, 709, 710, 711, 713, 716, 718, 727, 732, 734, 736, 739, 743, 745, 749, 750, 752, 755, 762, 763, 769, 772, 774, 775, 781, 783, 784, 785, 790, 793, 794, 795, 797, 800, 802, 811, 816, 818, 820, 823, 827, 829, 833, 834, 836, 840, 841, 845, 847, 849, 853, 861, 865, 872, 873, 879, 880, 883, 886, 887, 889, 894, 900, 904, 910, 916, 919, 921, 922, 923, 926, 932, 938, 944, 948, 956, 960, 967, 968, 973, 976, 977, 979, 984, 993, 1000, 1006, 1012, 1015, 1016, 1018, 1021, 1024, 1026, 1028, 1030, 1032, 1034], "returns": [20, 72, 74, 114, 156, 223, 322, 441, 581, 848, 1035], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 8, 11, 26, 34, 42, 60, 68, 110, 152, 173, 177, 185, 201, 267, 271, 279, 295, 336, 358, 364, 378, 406, 417, 457, 464, 490, 514, 548, 600, 655, 671, 675, 683, 721, 757, 765, 805, 843, 867, 906, 928, 934, 940, 962, 1002, 1008, 1014, 1036], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 12, "universal_type": "function", "name": "isAWhitespace", "text_snippet": "bool isAWhitespace(char c){\r\n return c == ' ' || c == '\\t' || c == '\\n';\r\n}"}, {"node_id": 14, "universal_type": "function", "name": "unknown", "text_snippet": "isAWhitespace(char c)"}, {"node_id": 46, "universal_type": "function", "name": "isCapital", "text_snippet": "bool isCapital(char c){\r\n if(c >= 'A' && c <= 'Z') return true;\r\n return false;\r\n}"}, {"node_id": 48, "universal_type": "function", "name": "unknown", "text_snippet": "isCapital(char c)"}, {"node_id": 76, "universal_type": "function", "name": "getNextNonWhitespace", "text_snippet": "int getNextNonWhitespace(char *str, int index){\r\n int i = index;\r\n while(isAWhitespace(str[i])"}, {"node_id": 78, "universal_type": "function", "name": "index)", "text_snippet": "getNextNonWhitespace(char *str, int index)"}, {"node_id": 116, "universal_type": "function", "name": "getNextWhitespace", "text_snippet": "int getNextWhitespace(char *str, int index){\r\n int i = index;\r\n while(!isAWhitespace(str[i]) &"}, {"node_id": 118, "universal_type": "function", "name": "index)", "text_snippet": "getNextWhitespace(char *str, int index)"}, {"node_id": 158, "universal_type": "function", "name": "countFirstCapitals", "text_snippet": "int countFirstCapitals(char *str){\r\n int count = 0, i = 0;\r\n\r\n while(str[i] != 0){\r\n i "}, {"node_id": 160, "universal_type": "function", "name": "unknown", "text_snippet": "countFirstCapitals(char *str)"}, {"node_id": 225, "universal_type": "function", "name": "*getFirstCapitals", "text_snippet": "int *getFirstCapitals(char *str){\r\n int size = countFirstCapitals(str);\r\n int *firstCapitals ="}, {"node_id": 229, "universal_type": "function", "name": "unknown", "text_snippet": "getFirstCapitals(char *str)"}, {"node_id": 324, "universal_type": "function", "name": "size", "text_snippet": "char *readLine(){\r\n int size = 64;\r\n char *line = malloc(size * sizeof(char));\r\n char c = 0"}, {"node_id": 328, "universal_type": "function", "name": "unknown", "text_snippet": "readLine()"}, {"node_id": 443, "universal_type": "function", "name": "size", "text_snippet": "char **readLines(){\r\n int size = 5;\r\n const char *end = \"end\";\r\n char **lines = malloc(size"}, {"node_id": 449, "universal_type": "function", "name": "unknown", "text_snippet": "readLines()"}, {"node_id": 583, "universal_type": "function", "name": "freeLines", "text_snippet": "void freeLines(char **lines){\r\n int i = 0;\r\n \r\n while(lines[i] != NULL){\r\n free(line"}, {"node_id": 585, "universal_type": "function", "name": "unknown", "text_snippet": "freeLines(char **lines)"}, {"node_id": 622, "universal_type": "function", "name": "i,", "text_snippet": "char *formatStr(char *old){ \r\n char *str = malloc(sizeof(char) * strlen(old) + 1);\r\n int i, j,"}, {"node_id": 626, "universal_type": "function", "name": "unknown", "text_snippet": "formatStr(char *old)"}, {"node_id": 850, "universal_type": "function", "name": "format", "text_snippet": "void format(char **lines){\r\n int i = 0;\r\n\r\n while(lines[i] != NULL){\r\n lines[i] = forma"}, {"node_id": 852, "universal_type": "function", "name": "unknown", "text_snippet": "format(char **lines)"}, {"node_id": 891, "universal_type": "function", "name": "printStr", "text_snippet": "void printStr(char *str){\r\n char c = 0;\r\n while(c = *(str++)){\r\n putc(c, stdout);\r\n\r\n "}, {"node_id": 893, "universal_type": "function", "name": "unknown", "text_snippet": "printStr(char *str)"}, {"node_id": 945, "universal_type": "function", "name": "printFormat", "text_snippet": "void printFormat(char **lines){\r\n int i = 0;\r\n while(lines[i] != NULL){\r\n printStr(line"}, {"node_id": 947, "universal_type": "function", "name": "unknown", "text_snippet": "printFormat(char **lines)"}, {"node_id": 981, "universal_type": "function", "name": "main", "text_snippet": "int main(){\r\n char **lines = NULL;\r\n int size = 0;\r\n char c = 0;\r\n int i = 0, j, k;\r\n\r\n "}, {"node_id": 983, "universal_type": "function", "name": "unknown", "text_snippet": "main()"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <stdio.h>\r\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <stdbool.h>\r\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include <stdlib.h>\r\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <string.h>\r\n"}, {"node_id": 10, "text": "#include"}]}, "original_source_code": "\r\n#include <stdio.h>\r\n#include <stdbool.h>\r\n#include <stdlib.h>\r\n#include <string.h>\r\n\r\nbool isAWhitespace(char c){\r\n return c == ' ' || c == '\\t' || c == '\\n';\r\n}\r\n\r\nbool isCapital(char c){\r\n if(c >= 'A' && c <= 'Z') return true;\r\n return false;\r\n}\r\n\r\nint getNextNonWhitespace(char *str, int index){\r\n int i = index;\r\n while(isAWhitespace(str[i]) && str[i] != 0) i++;\r\n return i;\r\n}\r\n\r\nint getNextWhitespace(char *str, int index){\r\n int i = index;\r\n while(!isAWhitespace(str[i]) && str[i] != 0) i++;\r\n return i;\r\n}\r\n\r\nint countFirstCapitals(char *str){\r\n int count = 0, i = 0;\r\n\r\n while(str[i] != 0){\r\n i = getNextNonWhitespace(str, i);\r\n if(str[i] == 0) break;\r\n if(isCapital(str[i])) count++;\r\n i = getNextWhitespace(str, i);\r\n }\r\n\r\n return count;\r\n}\r\n\r\nint *getFirstCapitals(char *str){\r\n int size = countFirstCapitals(str);\r\n int *firstCapitals = malloc(size * sizeof(int));\r\n int i = 0, count = 0;\r\n while(str[i] != 0){\r\n i = getNextNonWhitespace(str, i);\r\n if(str[i] == 0) break;\r\n if(isCapital(str[i])){\r\n firstCapitals[count++] = i;\r\n }\r\n i = getNextWhitespace(str, i);\r\n }\r\n\r\n return firstCapitals;\r\n}\r\n\r\nchar *readLine(){\r\n int size = 64;\r\n char *line = malloc(size * sizeof(char));\r\n char c = 0;\r\n int i = 0;\r\n\r\n while(true){\r\n \r\n if(i == size){\r\n size = 2 * size;\r\n line = realloc(line, size * sizeof(char));\r\n }\r\n\r\n c = getc(stdin);\r\n \r\n if(c == '\\n'){\r\n line[i++] = 0;\r\n break;\r\n }\r\n\r\n line[i++] = c;\r\n }\r\n\r\n line = realloc(line, i * sizeof(char));\r\n\r\n return line;\r\n}\r\n\r\nchar **readLines(){\r\n int size = 5;\r\n const char *end = \"end\";\r\n char **lines = malloc(sizeof(char *) * size);\r\n int i = 0;\r\n\r\n while(true){\r\n char *next = readLine();\r\n\r\n if(!strcmp(next, &end[0])){\r\n free(next);\r\n lines[i++] = NULL;\r\n break;\r\n }\r\n\r\n lines[i++] = next;\r\n\r\n // printf(\"i: %d/%d, %s\\n\", i, size, lines[i - 1]);\r\n \r\n if(i == size){\r\n size = 2 * size;\r\n lines = realloc(lines, sizeof(char *) * size);\r\n }\r\n }\r\n \r\n lines = realloc(lines, i * sizeof(char *));\r\n\r\n return lines;\r\n}\r\n\r\nvoid freeLines(char **lines){\r\n int i = 0;\r\n \r\n while(lines[i] != NULL){\r\n free(lines[i++]);\r\n }\r\n\r\n free(lines);\r\n}\r\n\r\nchar *formatStr(char *old){ \r\n char *str = malloc(sizeof(char) * strlen(old) + 1);\r\n int i, j, start, end, newpos;\r\n bool notFirstWord = false;\r\n\r\n i = 0;\r\n newpos = 0;\r\n while(old[i] != 0){\r\n int start = getNextNonWhitespace(old, i);\r\n int end = getNextWhitespace(old, start);\r\n \r\n if(isCapital(old[start])){\r\n\r\n if(notFirstWord){\r\n str[newpos++] = ' ';\r\n }else{\r\n notFirstWord = true;\r\n }\r\n\r\n for(j = start; j < end; j++){\r\n str[newpos++] = old[j];\r\n }\r\n }\r\n \r\n i = end;\r\n }\r\n\r\n i = 0;\r\n while(old[i] != 0){\r\n int start = getNextNonWhitespace(old, i);\r\n int end = getNextWhitespace(old, start);\r\n \r\n if(!isCapital(old[start])){\r\n\r\n if(notFirstWord){\r\n str[newpos++] = ' ';\r\n }else{\r\n notFirstWord = true;\r\n }\r\n\r\n for(j = start; j < end; j++){\r\n str[newpos++] = old[j];\r\n }\r\n }\r\n \r\n i = end;\r\n }\r\n\r\n str[newpos] = 0;\r\n\r\n free(old);\r\n return str;\r\n}\r\n\r\nvoid format(char **lines){\r\n int i = 0;\r\n\r\n while(lines[i] != NULL){\r\n lines[i] = formatStr(lines[i]);\r\n i++;\r\n }\r\n}\r\n\r\nvoid printStr(char *str){\r\n char c = 0;\r\n while(c = *(str++)){\r\n putc(c, stdout);\r\n\r\n if(c == '.'){\r\n printf(\"\\n\\t\");\r\n }\r\n }\r\n putc('\\n', stdout);\r\n}\r\n\r\nvoid printFormat(char **lines){\r\n int i = 0;\r\n while(lines[i] != NULL){\r\n printStr(lines[i]);\r\n i++;\r\n }\r\n}\r\n\r\nint main(){\r\n char **lines = NULL;\r\n int size = 0;\r\n char c = 0;\r\n int i = 0, j, k;\r\n\r\n lines = readLines();\r\n\r\n format(lines);\r\n\r\n printFormat(lines);\r\n\r\n freeLines(lines);\r\n \r\n return 0;\r\n}\r\n"}
80,573
c
#include <wchar.h> wchar_t* wcpcpy(wchar_t* restrict d, const wchar_t* restrict s) { return wcscpy(d, s) + wcslen(s); }
59
2
(translation_unit) "#include <wchar.h>\n\nwchar_t* wcpcpy(wchar_t* restrict d, const wchar_t* restrict s) { return wcscpy(d, s) + wcslen(s); }\n" (preproc_include) "#include <wchar.h>\n" (#include) "#include" (system_lib_string) "<wchar.h>" (function_definition) "wchar_t* wcpcpy(wchar_t* restrict d, const wchar_t* restrict s) { return wcscpy(d, s) + wcslen(s); }" (type_identifier) "wchar_t" (pointer_declarator) "* wcpcpy(wchar_t* restrict d, const wchar_t* restrict s)" (*) "*" (function_declarator) "wcpcpy(wchar_t* restrict d, const wchar_t* restrict s)" (identifier) "wcpcpy" (parameter_list) "(wchar_t* restrict d, const wchar_t* restrict s)" (() "(" (parameter_declaration) "wchar_t* restrict d" (type_identifier) "wchar_t" (pointer_declarator) "* restrict d" (*) "*" (type_qualifier) "restrict" (restrict) "restrict" (identifier) "d" (,) "," (parameter_declaration) "const wchar_t* restrict s" (type_qualifier) "const" (const) "const" (type_identifier) "wchar_t" (pointer_declarator) "* restrict s" (*) "*" (type_qualifier) "restrict" (restrict) "restrict" (identifier) "s" ()) ")" (compound_statement) "{ return wcscpy(d, s) + wcslen(s); }" ({) "{" (return_statement) "return wcscpy(d, s) + wcslen(s);" (return) "return" (binary_expression) "wcscpy(d, s) + wcslen(s)" (call_expression) "wcscpy(d, s)" (identifier) "wcscpy" (argument_list) "(d, s)" (() "(" (identifier) "d" (,) "," (identifier) "s" ()) ")" (+) "+" (call_expression) "wcslen(s)" (identifier) "wcslen" (argument_list) "(s)" (() "(" (identifier) "s" ()) ")" (;) ";" (}) "}"
52
0
{"language": "c", "success": true, "metadata": {"lines": 2, "avg_line_length": 59.0, "nodes": 36, "errors": 0, "source_hash": "ed91e2887e873692714d82bd00f7c9f432499fd7b3338f0f595efb76551718c8", "categorized_nodes": 24}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <wchar.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<wchar.h>", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 18}}, {"id": 3, "type": "function_definition", "text": "wchar_t* wcpcpy(wchar_t* restrict d, const wchar_t* restrict s) { return wcscpy(d, s) + wcslen(s); }", "parent": null, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 100}}, {"id": 4, "type": "type_identifier", "text": "wchar_t", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 7}}, {"id": 5, "type": "pointer_declarator", "text": "* wcpcpy(wchar_t* restrict d, const wchar_t* restrict s)", "parent": 3, "children": [6, 7], "start_point": {"row": 2, "column": 7}, "end_point": {"row": 2, "column": 63}}, {"id": 6, "type": "*", "text": "*", "parent": 5, "children": [], "start_point": {"row": 2, "column": 7}, "end_point": {"row": 2, "column": 8}}, {"id": 7, "type": "function_declarator", "text": "wcpcpy(wchar_t* restrict d, const wchar_t* restrict s)", "parent": 5, "children": [8, 9], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 63}}, {"id": 8, "type": "identifier", "text": "wcpcpy", "parent": 7, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 15}}, {"id": 9, "type": "parameter_list", "text": "(wchar_t* restrict d, const wchar_t* restrict s)", "parent": 7, "children": [10, 17], "start_point": {"row": 2, "column": 15}, "end_point": {"row": 2, "column": 63}}, {"id": 10, "type": "parameter_declaration", "text": "wchar_t* restrict d", "parent": 9, "children": [11, 12], "start_point": {"row": 2, "column": 16}, "end_point": {"row": 2, "column": 35}}, {"id": 11, "type": "type_identifier", "text": "wchar_t", "parent": 10, "children": [], "start_point": {"row": 2, "column": 16}, "end_point": {"row": 2, "column": 23}}, {"id": 12, "type": "pointer_declarator", "text": "* restrict d", "parent": 10, "children": [13, 14, 16], "start_point": {"row": 2, "column": 23}, "end_point": {"row": 2, "column": 35}}, {"id": 13, "type": "*", "text": "*", "parent": 12, "children": [], "start_point": {"row": 2, "column": 23}, "end_point": {"row": 2, "column": 24}}, {"id": 14, "type": "type_qualifier", "text": "restrict", "parent": 12, "children": [15], "start_point": {"row": 2, "column": 25}, "end_point": {"row": 2, "column": 33}}, {"id": 15, "type": "restrict", "text": "restrict", "parent": 14, "children": [], "start_point": {"row": 2, "column": 25}, "end_point": {"row": 2, "column": 33}}, {"id": 16, "type": "identifier", "text": "d", "parent": 12, "children": [], "start_point": {"row": 2, "column": 34}, "end_point": {"row": 2, "column": 35}}, {"id": 17, "type": "parameter_declaration", "text": "const wchar_t* restrict s", "parent": 9, "children": [18, 19], "start_point": {"row": 2, "column": 37}, "end_point": {"row": 2, "column": 62}}, {"id": 18, "type": "type_identifier", "text": "wchar_t", "parent": 17, "children": [], "start_point": {"row": 2, "column": 43}, "end_point": {"row": 2, "column": 50}}, {"id": 19, "type": "pointer_declarator", "text": "* restrict s", "parent": 17, "children": [20, 21, 23], "start_point": {"row": 2, "column": 50}, "end_point": {"row": 2, "column": 62}}, {"id": 20, "type": "*", "text": "*", "parent": 19, "children": [], "start_point": {"row": 2, "column": 50}, "end_point": {"row": 2, "column": 51}}, {"id": 21, "type": "type_qualifier", "text": "restrict", "parent": 19, "children": [22], "start_point": {"row": 2, "column": 52}, "end_point": {"row": 2, "column": 60}}, {"id": 22, "type": "restrict", "text": "restrict", "parent": 21, "children": [], "start_point": {"row": 2, "column": 52}, "end_point": {"row": 2, "column": 60}}, {"id": 23, "type": "identifier", "text": "s", "parent": 19, "children": [], "start_point": {"row": 2, "column": 61}, "end_point": {"row": 2, "column": 62}}, {"id": 24, "type": "return_statement", "text": "return wcscpy(d, s) + wcslen(s);", "parent": 3, "children": [25], "start_point": {"row": 2, "column": 66}, "end_point": {"row": 2, "column": 98}}, {"id": 25, "type": "binary_expression", "text": "wcscpy(d, s) + wcslen(s)", "parent": 24, "children": [26, 31, 32], "start_point": {"row": 2, "column": 73}, "end_point": {"row": 2, "column": 97}}, {"id": 26, "type": "call_expression", "text": "wcscpy(d, s)", "parent": 25, "children": [27, 28], "start_point": {"row": 2, "column": 73}, "end_point": {"row": 2, "column": 85}}, {"id": 27, "type": "identifier", "text": "wcscpy", "parent": 26, "children": [], "start_point": {"row": 2, "column": 73}, "end_point": {"row": 2, "column": 79}}, {"id": 28, "type": "argument_list", "text": "(d, s)", "parent": 26, "children": [29, 30], "start_point": {"row": 2, "column": 79}, "end_point": {"row": 2, "column": 85}}, {"id": 29, "type": "identifier", "text": "d", "parent": 28, "children": [], "start_point": {"row": 2, "column": 80}, "end_point": {"row": 2, "column": 81}}, {"id": 30, "type": "identifier", "text": "s", "parent": 28, "children": [], "start_point": {"row": 2, "column": 83}, "end_point": {"row": 2, "column": 84}}, {"id": 31, "type": "+", "text": "+", "parent": 25, "children": [], "start_point": {"row": 2, "column": 86}, "end_point": {"row": 2, "column": 87}}, {"id": 32, "type": "call_expression", "text": "wcslen(s)", "parent": 25, "children": [33, 34], "start_point": {"row": 2, "column": 88}, "end_point": {"row": 2, "column": 97}}, {"id": 33, "type": "identifier", "text": "wcslen", "parent": 32, "children": [], "start_point": {"row": 2, "column": 88}, "end_point": {"row": 2, "column": 94}}, {"id": 34, "type": "argument_list", "text": "(s)", "parent": 32, "children": [35], "start_point": {"row": 2, "column": 94}, "end_point": {"row": 2, "column": 97}}, {"id": 35, "type": "identifier", "text": "s", "parent": 34, "children": [], "start_point": {"row": 2, "column": 95}, "end_point": {"row": 2, "column": 96}}]}, "node_categories": {"declarations": {"functions": [3, 7], "variables": [10, 17], "classes": [], "imports": [0, 1], "modules": [], "enums": []}, "statements": {"expressions": [25, 26, 32], "assignments": [], "loops": [], "conditionals": [4, 8, 11, 14, 16, 18, 21, 23, 27, 29, 30, 33, 35], "returns": [24], "exceptions": []}, "expressions": {"calls": [], "literals": [2], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 3, "universal_type": "function", "name": "unknown", "text_snippet": "wchar_t* wcpcpy(wchar_t* restrict d, const wchar_t* restrict s) { return wcscpy(d, s) + wcslen(s); }"}, {"node_id": 7, "universal_type": "function", "name": "unknown", "text_snippet": "wcpcpy(wchar_t* restrict d, const wchar_t* restrict s)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <wchar.h>\n"}, {"node_id": 1, "text": "#include"}]}, "original_source_code": "#include <wchar.h>\n\nwchar_t* wcpcpy(wchar_t* restrict d, const wchar_t* restrict s) { return wcscpy(d, s) + wcslen(s); }\n"}
80,574
c
// Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT License. See License in the project root for license information. #include <Foundation/Foundation.h> typedef NS_ENUM(NSInteger, MSGraphScheduleChangeStateValue){ MSGraphScheduleChangeStatePending = 0, MSGraphScheduleChangeStateApproved = 1, MSGraphScheduleChangeStateDeclined = 2, MSGraphScheduleChangeStateUnknownFutureValue = 3, MSGraphScheduleChangeStateEndOfEnum }; @interface MSGraphScheduleChangeState : NSObject +(MSGraphScheduleChangeState*) pending; +(MSGraphScheduleChangeState*) approved; +(MSGraphScheduleChangeState*) declined; +(MSGraphScheduleChangeState*) unknownFutureValue; +(MSGraphScheduleChangeState*) UnknownEnumValue; +(MSGraphScheduleChangeState*) scheduleChangeStateWithEnumValue:(MSGraphScheduleChangeStateValue)val; -(NSString*) ms_toString; @property (nonatomic, readonly) MSGraphScheduleChangeStateValue enumValue; @end @interface NSString (MSGraphScheduleChangeState) - (MSGraphScheduleChangeState*) toMSGraphScheduleChangeState; @end
43.25
24
(translation_unit) "// Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT License. See License in the project root for license information.\n\n\n\n#include <Foundation/Foundation.h>\n\ntypedef NS_ENUM(NSInteger, MSGraphScheduleChangeStateValue){\n\n MSGraphScheduleChangeStatePending = 0,\n MSGraphScheduleChangeStateApproved = 1,\n MSGraphScheduleChangeStateDeclined = 2,\n MSGraphScheduleChangeStateUnknownFutureValue = 3,\n MSGraphScheduleChangeStateEndOfEnum\n};\n\n@interface MSGraphScheduleChangeState : NSObject\n\n+(MSGraphScheduleChangeState*) pending;\n+(MSGraphScheduleChangeState*) approved;\n+(MSGraphScheduleChangeState*) declined;\n+(MSGraphScheduleChangeState*) unknownFutureValue;\n\n+(MSGraphScheduleChangeState*) UnknownEnumValue;\n\n+(MSGraphScheduleChangeState*) scheduleChangeStateWithEnumValue:(MSGraphScheduleChangeStateValue)val;\n-(NSString*) ms_toString;\n\n@property (nonatomic, readonly) MSGraphScheduleChangeStateValue enumValue;\n\n@end\n\n\n@interface NSString (MSGraphScheduleChangeState)\n\n- (MSGraphScheduleChangeState*) toMSGraphScheduleChangeState;\n\n@end\n" (comment) "// Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT License. See License in the project root for license information." (preproc_include) "#include <Foundation/Foundation.h>\n" (#include) "#include" (system_lib_string) "<Foundation/Foundation.h>" (ERROR) "typedef NS_ENUM(NSInteger, MSGraphScheduleChangeStateValue){\n\n MSGraphScheduleChangeStatePending = 0,\n MSGraphScheduleChangeStateApproved = 1,\n MSGraphScheduleChangeStateDeclined = 2,\n MSGraphScheduleChangeStateUnknownFutureValue = 3,\n MSGraphScheduleChangeStateEndOfEnum\n};\n\n@interface MSGraphScheduleChangeState : NSObject\n\n+(MSGraphScheduleChangeState*) pending;\n+(MSGraphScheduleChangeState*) approved;\n+(MSGraphScheduleChangeState*) declined;\n+(MSGraphScheduleChangeState*) unknownFutureValue;\n\n+(MSGraphScheduleChangeState*) UnknownEnumValue;\n\n+(MSGraphScheduleChangeState*) scheduleChangeStateWithEnumValue:(MSGraphScheduleChangeStateValue)val;\n-(NSString*) ms_toString;\n\n@property (nonatomic, readonly) MSGraphScheduleChangeStateValue enumValue;\n\n@end\n\n\n@interface NSString (MSGraphScheduleChangeState)\n\n- (MSGraphScheduleChangeState*) toMSGraphScheduleChangeState;\n\n@end" (typedef) "typedef" (macro_type_specifier) "NS_ENUM(NSInteger, MSGraphScheduleChangeStateValue)" (identifier) "NS_ENUM" (() "(" (ERROR) "NSInteger," (type_descriptor) "NSInteger" (type_identifier) "NSInteger" (,) "," (type_descriptor) "MSGraphScheduleChangeStateValue" (type_identifier) "MSGraphScheduleChangeStateValue" ()) ")" ({) "{" (expression_statement) "MSGraphScheduleChangeStatePending = 0,\n MSGraphScheduleChangeStateApproved = 1,\n MSGraphScheduleChangeStateDeclined = 2,\n MSGraphScheduleChangeStateUnknownFutureValue = 3,\n MSGraphScheduleChangeStateEndOfEnum\n};" (comma_expression) "MSGraphScheduleChangeStatePending = 0,\n MSGraphScheduleChangeStateApproved = 1,\n MSGraphScheduleChangeStateDeclined = 2,\n MSGraphScheduleChangeStateUnknownFutureValue = 3,\n MSGraphScheduleChangeStateEndOfEnum" (assignment_expression) "MSGraphScheduleChangeStatePending = 0" (identifier) "MSGraphScheduleChangeStatePending" (=) "=" (number_literal) "0" (,) "," (comma_expression) "MSGraphScheduleChangeStateApproved = 1,\n MSGraphScheduleChangeStateDeclined = 2,\n MSGraphScheduleChangeStateUnknownFutureValue = 3,\n MSGraphScheduleChangeStateEndOfEnum" (assignment_expression) "MSGraphScheduleChangeStateApproved = 1" (identifier) "MSGraphScheduleChangeStateApproved" (=) "=" (number_literal) "1" (,) "," (comma_expression) "MSGraphScheduleChangeStateDeclined = 2,\n MSGraphScheduleChangeStateUnknownFutureValue = 3,\n MSGraphScheduleChangeStateEndOfEnum" (assignment_expression) "MSGraphScheduleChangeStateDeclined = 2" (identifier) "MSGraphScheduleChangeStateDeclined" (=) "=" (number_literal) "2" (,) "," (comma_expression) "MSGraphScheduleChangeStateUnknownFutureValue = 3,\n MSGraphScheduleChangeStateEndOfEnum" (assignment_expression) "MSGraphScheduleChangeStateUnknownFutureValue = 3" (identifier) "MSGraphScheduleChangeStateUnknownFutureValue" (=) "=" (number_literal) "3" (,) "," (identifier) "MSGraphScheduleChangeStateEndOfEnum" (ERROR) "}" (}) "}" (;) ";" (ERROR) "@interface MSGraphScheduleChangeState : NSObject" (ERROR) "@" (type_identifier) "interface" (identifier) "MSGraphScheduleChangeState" (:) ":" (identifier) "NSObject" (expression_statement) "+(MSGraphScheduleChangeState*) pending;" (unary_expression) "+(MSGraphScheduleChangeState*) pending" (+) "+" (cast_expression) "(MSGraphScheduleChangeState*) pending" (() "(" (type_descriptor) "MSGraphScheduleChangeState*" (type_identifier) "MSGraphScheduleChangeState" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "pending" (;) ";" (expression_statement) "+(MSGraphScheduleChangeState*) approved;" (unary_expression) "+(MSGraphScheduleChangeState*) approved" (+) "+" (cast_expression) "(MSGraphScheduleChangeState*) approved" (() "(" (type_descriptor) "MSGraphScheduleChangeState*" (type_identifier) "MSGraphScheduleChangeState" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "approved" (;) ";" (expression_statement) "+(MSGraphScheduleChangeState*) declined;" (unary_expression) "+(MSGraphScheduleChangeState*) declined" (+) "+" (cast_expression) "(MSGraphScheduleChangeState*) declined" (() "(" (type_descriptor) "MSGraphScheduleChangeState*" (type_identifier) "MSGraphScheduleChangeState" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "declined" (;) ";" (expression_statement) "+(MSGraphScheduleChangeState*) unknownFutureValue;" (unary_expression) "+(MSGraphScheduleChangeState*) unknownFutureValue" (+) "+" (cast_expression) "(MSGraphScheduleChangeState*) unknownFutureValue" (() "(" (type_descriptor) "MSGraphScheduleChangeState*" (type_identifier) "MSGraphScheduleChangeState" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "unknownFutureValue" (;) ";" (expression_statement) "+(MSGraphScheduleChangeState*) UnknownEnumValue;" (unary_expression) "+(MSGraphScheduleChangeState*) UnknownEnumValue" (+) "+" (cast_expression) "(MSGraphScheduleChangeState*) UnknownEnumValue" (() "(" (type_descriptor) "MSGraphScheduleChangeState*" (type_identifier) "MSGraphScheduleChangeState" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "UnknownEnumValue" (;) ";" (expression_statement) "+(MSGraphScheduleChangeState*) scheduleChangeStateWithEnumValue:(MSGraphScheduleChangeStateValue)val;" (unary_expression) "+(MSGraphScheduleChangeState*) scheduleChangeStateWithEnumValue" (+) "+" (cast_expression) "(MSGraphScheduleChangeState*) scheduleChangeStateWithEnumValue" (() "(" (type_descriptor) "MSGraphScheduleChangeState*" (type_identifier) "MSGraphScheduleChangeState" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "scheduleChangeStateWithEnumValue" (ERROR) ":(MSGraphScheduleChangeStateValue)val" (:) ":" (() "(" (identifier) "MSGraphScheduleChangeStateValue" ()) ")" (identifier) "val" (;) ";" (expression_statement) "-(NSString*) ms_toString;" (unary_expression) "-(NSString*) ms_toString" (-) "-" (cast_expression) "(NSString*) ms_toString" (() "(" (type_descriptor) "NSString*" (type_identifier) "NSString" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "ms_toString" (;) ";" (ERROR) "@property (nonatomic, readonly) MSGraphScheduleChangeStateValue" (ERROR) "@" (call_expression) "property (nonatomic, readonly)" (identifier) "property" (argument_list) "(nonatomic, readonly)" (() "(" (identifier) "nonatomic" (,) "," (identifier) "readonly" ()) ")" (identifier) "MSGraphScheduleChangeStateValue" (expression_statement) "enumValue;" (identifier) "enumValue" (;) ";" (ERROR) "@end\n\n\n@interface NSString (MSGraphScheduleChangeState)" (ERROR) "@" (type_identifier) "end" (ERROR) "@interface" (ERROR) "@" (identifier) "interface" (function_declarator) "NSString (MSGraphScheduleChangeState)" (identifier) "NSString" (parameter_list) "(MSGraphScheduleChangeState)" (() "(" (identifier) "MSGraphScheduleChangeState" ()) ")" (expression_statement) "- (MSGraphScheduleChangeState*) toMSGraphScheduleChangeState;" (unary_expression) "- (MSGraphScheduleChangeState*) toMSGraphScheduleChangeState" (-) "-" (cast_expression) "(MSGraphScheduleChangeState*) toMSGraphScheduleChangeState" (() "(" (type_descriptor) "MSGraphScheduleChangeState*" (type_identifier) "MSGraphScheduleChangeState" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "toMSGraphScheduleChangeState" (;) ";" (ERROR) "@" (ERROR) "@" (identifier) "end"
184
14
{"language": "c", "success": true, "metadata": {"lines": 24, "avg_line_length": 43.25, "nodes": 125, "errors": 0, "source_hash": "c71024321570a0d0859039c3e4ae55808f7730d9ba80e3f9f3cee25af0db3e43", "categorized_nodes": 71}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <Foundation/Foundation.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<Foundation/Foundation.h>", "parent": 0, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 34}}, {"id": 3, "type": "ERROR", "text": "typedef NS_ENUM(NSInteger, MSGraphScheduleChangeStateValue){\n\n\tMSGraphScheduleChangeStatePending = 0,\n\tMSGraphScheduleChangeStateApproved = 1,\n\tMSGraphScheduleChangeStateDeclined = 2,\n\tMSGraphScheduleChangeStateUnknownFutureValue = 3,\n MSGraphScheduleChangeStateEndOfEnum\n};\n\n@interface MSGraphScheduleChangeState : NSObject\n\n+(MSGraphScheduleChangeState*) pending;\n+(MSGraphScheduleChangeState*) approved;\n+(MSGraphScheduleChangeState*) declined;\n+(MSGraphScheduleChangeState*) unknownFutureValue;\n\n+(MSGraphScheduleChangeState*) UnknownEnumValue;\n\n+(MSGraphScheduleChangeState*) scheduleChangeStateWithEnumValue:(MSGraphScheduleChangeStateValue)val;\n-(NSString*) ms_toString;\n\n@property (nonatomic, readonly) MSGraphScheduleChangeStateValue enumValue;\n\n@end\n\n\n@interface NSString (MSGraphScheduleChangeState)\n\n- (MSGraphScheduleChangeState*) toMSGraphScheduleChangeState;\n\n@end", "parent": null, "children": [4, 5, 33, 97, 106, 123], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 36, "column": 4}}, {"id": 4, "type": "typedef", "text": "typedef", "parent": 3, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 7}}, {"id": 5, "type": "macro_type_specifier", "text": "NS_ENUM(NSInteger, MSGraphScheduleChangeStateValue)", "parent": 3, "children": [6, 7, 10], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 59}}, {"id": 6, "type": "identifier", "text": "NS_ENUM", "parent": 5, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 15}}, {"id": 7, "type": "ERROR", "text": "NSInteger,", "parent": 5, "children": [8], "start_point": {"row": 6, "column": 16}, "end_point": {"row": 6, "column": 26}}, {"id": 8, "type": "type_descriptor", "text": "NSInteger", "parent": 7, "children": [9], "start_point": {"row": 6, "column": 16}, "end_point": {"row": 6, "column": 25}}, {"id": 9, "type": "type_identifier", "text": "NSInteger", "parent": 8, "children": [], "start_point": {"row": 6, "column": 16}, "end_point": {"row": 6, "column": 25}}, {"id": 10, "type": "type_descriptor", "text": "MSGraphScheduleChangeStateValue", "parent": 5, "children": [11], "start_point": {"row": 6, "column": 27}, "end_point": {"row": 6, "column": 58}}, {"id": 11, "type": "type_identifier", "text": "MSGraphScheduleChangeStateValue", "parent": 10, "children": [], "start_point": {"row": 6, "column": 27}, "end_point": {"row": 6, "column": 58}}, {"id": 12, "type": "comma_expression", "text": "MSGraphScheduleChangeStatePending = 0,\n\tMSGraphScheduleChangeStateApproved = 1,\n\tMSGraphScheduleChangeStateDeclined = 2,\n\tMSGraphScheduleChangeStateUnknownFutureValue = 3,\n MSGraphScheduleChangeStateEndOfEnum", "parent": 3, "children": [13, 17], "start_point": {"row": 8, "column": 1}, "end_point": {"row": 12, "column": 39}}, {"id": 13, "type": "assignment_expression", "text": "MSGraphScheduleChangeStatePending = 0", "parent": 12, "children": [14, 15, 16], "start_point": {"row": 8, "column": 1}, "end_point": {"row": 8, "column": 38}}, {"id": 14, "type": "identifier", "text": "MSGraphScheduleChangeStatePending", "parent": 13, "children": [], "start_point": {"row": 8, "column": 1}, "end_point": {"row": 8, "column": 34}}, {"id": 15, "type": "=", "text": "=", "parent": 13, "children": [], "start_point": {"row": 8, "column": 35}, "end_point": {"row": 8, "column": 36}}, {"id": 16, "type": "number_literal", "text": "0", "parent": 13, "children": [], "start_point": {"row": 8, "column": 37}, "end_point": {"row": 8, "column": 38}}, {"id": 17, "type": "comma_expression", "text": "MSGraphScheduleChangeStateApproved = 1,\n\tMSGraphScheduleChangeStateDeclined = 2,\n\tMSGraphScheduleChangeStateUnknownFutureValue = 3,\n MSGraphScheduleChangeStateEndOfEnum", "parent": 12, "children": [18, 22], "start_point": {"row": 9, "column": 1}, "end_point": {"row": 12, "column": 39}}, {"id": 18, "type": "assignment_expression", "text": "MSGraphScheduleChangeStateApproved = 1", "parent": 17, "children": [19, 20, 21], "start_point": {"row": 9, "column": 1}, "end_point": {"row": 9, "column": 39}}, {"id": 19, "type": "identifier", "text": "MSGraphScheduleChangeStateApproved", "parent": 18, "children": [], "start_point": {"row": 9, "column": 1}, "end_point": {"row": 9, "column": 35}}, {"id": 20, "type": "=", "text": "=", "parent": 18, "children": [], "start_point": {"row": 9, "column": 36}, "end_point": {"row": 9, "column": 37}}, {"id": 21, "type": "number_literal", "text": "1", "parent": 18, "children": [], "start_point": {"row": 9, "column": 38}, "end_point": {"row": 9, "column": 39}}, {"id": 22, "type": "comma_expression", "text": "MSGraphScheduleChangeStateDeclined = 2,\n\tMSGraphScheduleChangeStateUnknownFutureValue = 3,\n MSGraphScheduleChangeStateEndOfEnum", "parent": 17, "children": [23, 27], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 12, "column": 39}}, {"id": 23, "type": "assignment_expression", "text": "MSGraphScheduleChangeStateDeclined = 2", "parent": 22, "children": [24, 25, 26], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 39}}, {"id": 24, "type": "identifier", "text": "MSGraphScheduleChangeStateDeclined", "parent": 23, "children": [], "start_point": {"row": 10, "column": 1}, "end_point": {"row": 10, "column": 35}}, {"id": 25, "type": "=", "text": "=", "parent": 23, "children": [], "start_point": {"row": 10, "column": 36}, "end_point": {"row": 10, "column": 37}}, {"id": 26, "type": "number_literal", "text": "2", "parent": 23, "children": [], "start_point": {"row": 10, "column": 38}, "end_point": {"row": 10, "column": 39}}, {"id": 27, "type": "comma_expression", "text": "MSGraphScheduleChangeStateUnknownFutureValue = 3,\n MSGraphScheduleChangeStateEndOfEnum", "parent": 22, "children": [28, 32], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 12, "column": 39}}, {"id": 28, "type": "assignment_expression", "text": "MSGraphScheduleChangeStateUnknownFutureValue = 3", "parent": 27, "children": [29, 30, 31], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 11, "column": 49}}, {"id": 29, "type": "identifier", "text": "MSGraphScheduleChangeStateUnknownFutureValue", "parent": 28, "children": [], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 11, "column": 45}}, {"id": 30, "type": "=", "text": "=", "parent": 28, "children": [], "start_point": {"row": 11, "column": 46}, "end_point": {"row": 11, "column": 47}}, {"id": 31, "type": "number_literal", "text": "3", "parent": 28, "children": [], "start_point": {"row": 11, "column": 48}, "end_point": {"row": 11, "column": 49}}, {"id": 32, "type": "identifier", "text": "MSGraphScheduleChangeStateEndOfEnum", "parent": 27, "children": [], "start_point": {"row": 12, "column": 4}, "end_point": {"row": 12, "column": 39}}, {"id": 33, "type": "ERROR", "text": "@interface MSGraphScheduleChangeState : NSObject", "parent": 3, "children": [34, 35, 36, 37], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 48}}, {"id": 34, "type": "ERROR", "text": "@", "parent": 33, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 1}}, {"id": 35, "type": "type_identifier", "text": "interface", "parent": 33, "children": [], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 10}}, {"id": 36, "type": "identifier", "text": "MSGraphScheduleChangeState", "parent": 33, "children": [], "start_point": {"row": 15, "column": 11}, "end_point": {"row": 15, "column": 37}}, {"id": 37, "type": "identifier", "text": "NSObject", "parent": 33, "children": [], "start_point": {"row": 15, "column": 40}, "end_point": {"row": 15, "column": 48}}, {"id": 38, "type": "unary_expression", "text": "+(MSGraphScheduleChangeState*) pending", "parent": 3, "children": [39, 40], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 38}}, {"id": 39, "type": "+", "text": "+", "parent": 38, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 40, "type": "cast_expression", "text": "(MSGraphScheduleChangeState*) pending", "parent": 38, "children": [41, 45], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 38}}, {"id": 41, "type": "type_descriptor", "text": "MSGraphScheduleChangeState*", "parent": 40, "children": [42, 43], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 17, "column": 29}}, {"id": 42, "type": "type_identifier", "text": "MSGraphScheduleChangeState", "parent": 41, "children": [], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 17, "column": 28}}, {"id": 43, "type": "abstract_pointer_declarator", "text": "*", "parent": 41, "children": [44], "start_point": {"row": 17, "column": 28}, "end_point": {"row": 17, "column": 29}}, {"id": 44, "type": "*", "text": "*", "parent": 43, "children": [], "start_point": {"row": 17, "column": 28}, "end_point": {"row": 17, "column": 29}}, {"id": 45, "type": "identifier", "text": "pending", "parent": 40, "children": [], "start_point": {"row": 17, "column": 31}, "end_point": {"row": 17, "column": 38}}, {"id": 46, "type": "unary_expression", "text": "+(MSGraphScheduleChangeState*) approved", "parent": 3, "children": [47, 48], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 39}}, {"id": 47, "type": "+", "text": "+", "parent": 46, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 1}}, {"id": 48, "type": "cast_expression", "text": "(MSGraphScheduleChangeState*) approved", "parent": 46, "children": [49, 53], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 39}}, {"id": 49, "type": "type_descriptor", "text": "MSGraphScheduleChangeState*", "parent": 48, "children": [50, 51], "start_point": {"row": 18, "column": 2}, "end_point": {"row": 18, "column": 29}}, {"id": 50, "type": "type_identifier", "text": "MSGraphScheduleChangeState", "parent": 49, "children": [], "start_point": {"row": 18, "column": 2}, "end_point": {"row": 18, "column": 28}}, {"id": 51, "type": "abstract_pointer_declarator", "text": "*", "parent": 49, "children": [52], "start_point": {"row": 18, "column": 28}, "end_point": {"row": 18, "column": 29}}, {"id": 52, "type": "*", "text": "*", "parent": 51, "children": [], "start_point": {"row": 18, "column": 28}, "end_point": {"row": 18, "column": 29}}, {"id": 53, "type": "identifier", "text": "approved", "parent": 48, "children": [], "start_point": {"row": 18, "column": 31}, "end_point": {"row": 18, "column": 39}}, {"id": 54, "type": "unary_expression", "text": "+(MSGraphScheduleChangeState*) declined", "parent": 3, "children": [55, 56], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 39}}, {"id": 55, "type": "+", "text": "+", "parent": 54, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 1}}, {"id": 56, "type": "cast_expression", "text": "(MSGraphScheduleChangeState*) declined", "parent": 54, "children": [57, 61], "start_point": {"row": 19, "column": 1}, "end_point": {"row": 19, "column": 39}}, {"id": 57, "type": "type_descriptor", "text": "MSGraphScheduleChangeState*", "parent": 56, "children": [58, 59], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 29}}, {"id": 58, "type": "type_identifier", "text": "MSGraphScheduleChangeState", "parent": 57, "children": [], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 28}}, {"id": 59, "type": "abstract_pointer_declarator", "text": "*", "parent": 57, "children": [60], "start_point": {"row": 19, "column": 28}, "end_point": {"row": 19, "column": 29}}, {"id": 60, "type": "*", "text": "*", "parent": 59, "children": [], "start_point": {"row": 19, "column": 28}, "end_point": {"row": 19, "column": 29}}, {"id": 61, "type": "identifier", "text": "declined", "parent": 56, "children": [], "start_point": {"row": 19, "column": 31}, "end_point": {"row": 19, "column": 39}}, {"id": 62, "type": "unary_expression", "text": "+(MSGraphScheduleChangeState*) unknownFutureValue", "parent": 3, "children": [63, 64], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 49}}, {"id": 63, "type": "+", "text": "+", "parent": 62, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 1}}, {"id": 64, "type": "cast_expression", "text": "(MSGraphScheduleChangeState*) unknownFutureValue", "parent": 62, "children": [65, 69], "start_point": {"row": 20, "column": 1}, "end_point": {"row": 20, "column": 49}}, {"id": 65, "type": "type_descriptor", "text": "MSGraphScheduleChangeState*", "parent": 64, "children": [66, 67], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 29}}, {"id": 66, "type": "type_identifier", "text": "MSGraphScheduleChangeState", "parent": 65, "children": [], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 28}}, {"id": 67, "type": "abstract_pointer_declarator", "text": "*", "parent": 65, "children": [68], "start_point": {"row": 20, "column": 28}, "end_point": {"row": 20, "column": 29}}, {"id": 68, "type": "*", "text": "*", "parent": 67, "children": [], "start_point": {"row": 20, "column": 28}, "end_point": {"row": 20, "column": 29}}, {"id": 69, "type": "identifier", "text": "unknownFutureValue", "parent": 64, "children": [], "start_point": {"row": 20, "column": 31}, "end_point": {"row": 20, "column": 49}}, {"id": 70, "type": "unary_expression", "text": "+(MSGraphScheduleChangeState*) UnknownEnumValue", "parent": 3, "children": [71, 72], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 47}}, {"id": 71, "type": "+", "text": "+", "parent": 70, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 1}}, {"id": 72, "type": "cast_expression", "text": "(MSGraphScheduleChangeState*) UnknownEnumValue", "parent": 70, "children": [73, 77], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 47}}, {"id": 73, "type": "type_descriptor", "text": "MSGraphScheduleChangeState*", "parent": 72, "children": [74, 75], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 22, "column": 29}}, {"id": 74, "type": "type_identifier", "text": "MSGraphScheduleChangeState", "parent": 73, "children": [], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 22, "column": 28}}, {"id": 75, "type": "abstract_pointer_declarator", "text": "*", "parent": 73, "children": [76], "start_point": {"row": 22, "column": 28}, "end_point": {"row": 22, "column": 29}}, {"id": 76, "type": "*", "text": "*", "parent": 75, "children": [], "start_point": {"row": 22, "column": 28}, "end_point": {"row": 22, "column": 29}}, {"id": 77, "type": "identifier", "text": "UnknownEnumValue", "parent": 72, "children": [], "start_point": {"row": 22, "column": 31}, "end_point": {"row": 22, "column": 47}}, {"id": 78, "type": "unary_expression", "text": "+(MSGraphScheduleChangeState*) scheduleChangeStateWithEnumValue", "parent": 3, "children": [79, 80], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 63}}, {"id": 79, "type": "+", "text": "+", "parent": 78, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 1}}, {"id": 80, "type": "cast_expression", "text": "(MSGraphScheduleChangeState*) scheduleChangeStateWithEnumValue", "parent": 78, "children": [81, 85], "start_point": {"row": 24, "column": 1}, "end_point": {"row": 24, "column": 63}}, {"id": 81, "type": "type_descriptor", "text": "MSGraphScheduleChangeState*", "parent": 80, "children": [82, 83], "start_point": {"row": 24, "column": 2}, "end_point": {"row": 24, "column": 29}}, {"id": 82, "type": "type_identifier", "text": "MSGraphScheduleChangeState", "parent": 81, "children": [], "start_point": {"row": 24, "column": 2}, "end_point": {"row": 24, "column": 28}}, {"id": 83, "type": "abstract_pointer_declarator", "text": "*", "parent": 81, "children": [84], "start_point": {"row": 24, "column": 28}, "end_point": {"row": 24, "column": 29}}, {"id": 84, "type": "*", "text": "*", "parent": 83, "children": [], "start_point": {"row": 24, "column": 28}, "end_point": {"row": 24, "column": 29}}, {"id": 85, "type": "identifier", "text": "scheduleChangeStateWithEnumValue", "parent": 80, "children": [], "start_point": {"row": 24, "column": 31}, "end_point": {"row": 24, "column": 63}}, {"id": 86, "type": "ERROR", "text": ":(MSGraphScheduleChangeStateValue)val", "parent": 3, "children": [87, 88], "start_point": {"row": 24, "column": 63}, "end_point": {"row": 24, "column": 100}}, {"id": 87, "type": "identifier", "text": "MSGraphScheduleChangeStateValue", "parent": 86, "children": [], "start_point": {"row": 24, "column": 65}, "end_point": {"row": 24, "column": 96}}, {"id": 88, "type": "identifier", "text": "val", "parent": 86, "children": [], "start_point": {"row": 24, "column": 97}, "end_point": {"row": 24, "column": 100}}, {"id": 89, "type": "unary_expression", "text": "-(NSString*) ms_toString", "parent": 3, "children": [90, 91], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 24}}, {"id": 90, "type": "-", "text": "-", "parent": 89, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 1}}, {"id": 91, "type": "cast_expression", "text": "(NSString*) ms_toString", "parent": 89, "children": [92, 96], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 25, "column": 24}}, {"id": 92, "type": "type_descriptor", "text": "NSString*", "parent": 91, "children": [93, 94], "start_point": {"row": 25, "column": 2}, "end_point": {"row": 25, "column": 11}}, {"id": 93, "type": "type_identifier", "text": "NSString", "parent": 92, "children": [], "start_point": {"row": 25, "column": 2}, "end_point": {"row": 25, "column": 10}}, {"id": 94, "type": "abstract_pointer_declarator", "text": "*", "parent": 92, "children": [95], "start_point": {"row": 25, "column": 10}, "end_point": {"row": 25, "column": 11}}, {"id": 95, "type": "*", "text": "*", "parent": 94, "children": [], "start_point": {"row": 25, "column": 10}, "end_point": {"row": 25, "column": 11}}, {"id": 96, "type": "identifier", "text": "ms_toString", "parent": 91, "children": [], "start_point": {"row": 25, "column": 13}, "end_point": {"row": 25, "column": 24}}, {"id": 97, "type": "ERROR", "text": "@property (nonatomic, readonly) MSGraphScheduleChangeStateValue", "parent": 3, "children": [98, 99, 104], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 63}}, {"id": 98, "type": "ERROR", "text": "@", "parent": 97, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 1}}, {"id": 99, "type": "call_expression", "text": "property (nonatomic, readonly)", "parent": 97, "children": [100, 101], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 31}}, {"id": 100, "type": "identifier", "text": "property", "parent": 99, "children": [], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 9}}, {"id": 101, "type": "argument_list", "text": "(nonatomic, readonly)", "parent": 99, "children": [102, 103], "start_point": {"row": 27, "column": 10}, "end_point": {"row": 27, "column": 31}}, {"id": 102, "type": "identifier", "text": "nonatomic", "parent": 101, "children": [], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 20}}, {"id": 103, "type": "identifier", "text": "readonly", "parent": 101, "children": [], "start_point": {"row": 27, "column": 22}, "end_point": {"row": 27, "column": 30}}, {"id": 104, "type": "identifier", "text": "MSGraphScheduleChangeStateValue", "parent": 97, "children": [], "start_point": {"row": 27, "column": 32}, "end_point": {"row": 27, "column": 63}}, {"id": 105, "type": "identifier", "text": "enumValue", "parent": 3, "children": [], "start_point": {"row": 27, "column": 64}, "end_point": {"row": 27, "column": 73}}, {"id": 106, "type": "ERROR", "text": "@end\n\n\n@interface NSString (MSGraphScheduleChangeState)", "parent": 3, "children": [107, 108, 111], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 32, "column": 48}}, {"id": 107, "type": "ERROR", "text": "@", "parent": 106, "children": [], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 1}}, {"id": 108, "type": "ERROR", "text": "@interface", "parent": 106, "children": [109, 110], "start_point": {"row": 32, "column": 0}, "end_point": {"row": 32, "column": 10}}, {"id": 109, "type": "ERROR", "text": "@", "parent": 108, "children": [], "start_point": {"row": 32, "column": 0}, "end_point": {"row": 32, "column": 1}}, {"id": 110, "type": "identifier", "text": "interface", "parent": 108, "children": [], "start_point": {"row": 32, "column": 1}, "end_point": {"row": 32, "column": 10}}, {"id": 111, "type": "function_declarator", "text": "NSString (MSGraphScheduleChangeState)", "parent": 106, "children": [112, 113], "start_point": {"row": 32, "column": 11}, "end_point": {"row": 32, "column": 48}}, {"id": 112, "type": "identifier", "text": "NSString", "parent": 111, "children": [], "start_point": {"row": 32, "column": 11}, "end_point": {"row": 32, "column": 19}}, {"id": 113, "type": "parameter_list", "text": "(MSGraphScheduleChangeState)", "parent": 111, "children": [114], "start_point": {"row": 32, "column": 20}, "end_point": {"row": 32, "column": 48}}, {"id": 114, "type": "identifier", "text": "MSGraphScheduleChangeState", "parent": 113, "children": [], "start_point": {"row": 32, "column": 21}, "end_point": {"row": 32, "column": 47}}, {"id": 115, "type": "unary_expression", "text": "- (MSGraphScheduleChangeState*) toMSGraphScheduleChangeState", "parent": 3, "children": [116, 117], "start_point": {"row": 34, "column": 0}, "end_point": {"row": 34, "column": 60}}, {"id": 116, "type": "-", "text": "-", "parent": 115, "children": [], "start_point": {"row": 34, "column": 0}, "end_point": {"row": 34, "column": 1}}, {"id": 117, "type": "cast_expression", "text": "(MSGraphScheduleChangeState*) toMSGraphScheduleChangeState", "parent": 115, "children": [118, 122], "start_point": {"row": 34, "column": 2}, "end_point": {"row": 34, "column": 60}}, {"id": 118, "type": "type_descriptor", "text": "MSGraphScheduleChangeState*", "parent": 117, "children": [119, 120], "start_point": {"row": 34, "column": 3}, "end_point": {"row": 34, "column": 30}}, {"id": 119, "type": "type_identifier", "text": "MSGraphScheduleChangeState", "parent": 118, "children": [], "start_point": {"row": 34, "column": 3}, "end_point": {"row": 34, "column": 29}}, {"id": 120, "type": "abstract_pointer_declarator", "text": "*", "parent": 118, "children": [121], "start_point": {"row": 34, "column": 29}, "end_point": {"row": 34, "column": 30}}, {"id": 121, "type": "*", "text": "*", "parent": 120, "children": [], "start_point": {"row": 34, "column": 29}, "end_point": {"row": 34, "column": 30}}, {"id": 122, "type": "identifier", "text": "toMSGraphScheduleChangeState", "parent": 117, "children": [], "start_point": {"row": 34, "column": 32}, "end_point": {"row": 34, "column": 60}}, {"id": 123, "type": "ERROR", "text": "@", "parent": 3, "children": [124], "start_point": {"row": 36, "column": 0}, "end_point": {"row": 36, "column": 1}}, {"id": 124, "type": "ERROR", "text": "@", "parent": 123, "children": [], "start_point": {"row": 36, "column": 0}, "end_point": {"row": 36, "column": 1}}]}, "node_categories": {"declarations": {"functions": [111], "variables": [], "classes": [], "imports": [0, 1], "modules": [], "enums": []}, "statements": {"expressions": [12, 17, 22, 27, 38, 40, 46, 48, 54, 56, 62, 64, 70, 72, 78, 80, 89, 91, 99, 115, 117], "assignments": [13, 18, 23, 28], "loops": [], "conditionals": [5, 6, 9, 11, 14, 19, 24, 29, 32, 35, 36, 37, 42, 45, 50, 53, 58, 61, 66, 69, 74, 77, 82, 85, 87, 88, 93, 96, 100, 102, 103, 104, 105, 110, 112, 114, 119, 122], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 16, 21, 26, 31], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 111, "universal_type": "function", "name": "unknown", "text_snippet": "NSString (MSGraphScheduleChangeState)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <Foundation/Foundation.h>\n"}, {"node_id": 1, "text": "#include"}]}, "original_source_code": "// Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT License. See License in the project root for license information.\n\n\n\n#include <Foundation/Foundation.h>\n\ntypedef NS_ENUM(NSInteger, MSGraphScheduleChangeStateValue){\n\n\tMSGraphScheduleChangeStatePending = 0,\n\tMSGraphScheduleChangeStateApproved = 1,\n\tMSGraphScheduleChangeStateDeclined = 2,\n\tMSGraphScheduleChangeStateUnknownFutureValue = 3,\n MSGraphScheduleChangeStateEndOfEnum\n};\n\n@interface MSGraphScheduleChangeState : NSObject\n\n+(MSGraphScheduleChangeState*) pending;\n+(MSGraphScheduleChangeState*) approved;\n+(MSGraphScheduleChangeState*) declined;\n+(MSGraphScheduleChangeState*) unknownFutureValue;\n\n+(MSGraphScheduleChangeState*) UnknownEnumValue;\n\n+(MSGraphScheduleChangeState*) scheduleChangeStateWithEnumValue:(MSGraphScheduleChangeStateValue)val;\n-(NSString*) ms_toString;\n\n@property (nonatomic, readonly) MSGraphScheduleChangeStateValue enumValue;\n\n@end\n\n\n@interface NSString (MSGraphScheduleChangeState)\n\n- (MSGraphScheduleChangeState*) toMSGraphScheduleChangeState;\n\n@end\n"}
80,575
c
// // WPAction.h // WonderPush // // Created by <NAME> on 19/02/2020. // Copyright © 2020 WonderPush. All rights reserved. // #import <Foundation/Foundation.h> NS_ASSUME_NONNULL_BEGIN /** Defines the metadata for a IAM action. */ NS_SWIFT_NAME(Action) @interface WPAction : NSObject /** * The URL to follow if the action is clicked. */ @property(nonatomic, nullable, copy, readonly) NSURL *targetUrl; /// Unavailable. - (instancetype)init NS_UNAVAILABLE; @end NS_ASSUME_NONNULL_END
22.29
21
(translation_unit) "//\n// WPAction.h\n// WonderPush\n//\n// Created by <NAME> on 19/02/2020.\n// Copyright © 2020 WonderPush. All rights reserved.\n//\n\n#import <Foundation/Foundation.h>\n\nNS_ASSUME_NONNULL_BEGIN\n\n/** Defines the metadata for a IAM action.\n */\nNS_SWIFT_NAME(Action)\n@interface WPAction : NSObject\n\n/**\n * The URL to follow if the action is clicked.\n */\n@property(nonatomic, nullable, copy, readonly) NSURL *targetUrl;\n\n/// Unavailable.\n- (instancetype)init NS_UNAVAILABLE;\n\n@end\n\nNS_ASSUME_NONNULL_END\n" (comment) "//" (comment) "// WPAction.h" (comment) "// WonderPush" (comment) "//" (comment) "// Created by <NAME> on 19/02/2020." (comment) "// Copyright © 2020 WonderPush. All rights reserved.\n" (comment) "/\n" (preproc_call) "import <Foundation/Foundation.h>\n\n" (preproc_directive) "import " (preproc_arg) "Foundation/Foundation.h>\n" (ERROR) "S_ASSUME_NONNULL_BEGIN\n\n/** Defines the metadata for a IAM action.\n */\nNS_SWIFT_NAME(Action)\n@interface WPAction : NSObject\n\n/**\n * The URL to follow if the action is clicked.\n */\n@property(nonatomic, nullable, copy, readonly) NSURL *targetUrl;\n\n/// Unavailable.\n- (instancetype)init NS_UNAVAILABLE;\n\n@end\n\nNS_ASSUME_NONNULL_END\n" (type_identifier) "S_ASSUME_NONNULL_BEGIN\n" (comment) "** Defines the metadata for a IAM action.\n */\n" (function_declarator) "S_SWIFT_NAME(Action)\n" (identifier) "S_SWIFT_NAME(" (parameter_list) "Action)\n" (() "A" (identifier) "ction)" ()) "\n" (ERROR) "i" (ERROR) "i" (declaration) "nterface WPAction : NSObject\n\n/**\n * The URL to follow if the action is clicked.\n */\n@property(nonatomic, nullable, copy, readonly) NSURL *targetUrl;\n" (type_identifier) "nterface " (ERROR) "PAction : NSObject\n\n/**\n * The URL to follow if the action is clicked.\n */\n@property(nonatomic, nullable, copy, readonly) NSURL " (identifier) "PAction " (:) " " (identifier) "SObject\n" (comment) "**\n * The URL to follow if the action is clicked.\n */\n" (ERROR) "p" (function_declarator) "roperty(nonatomic, nullable, copy, readonly) NSURL " (identifier) "roperty(" (parameter_list) "nonatomic, nullable, copy, readonly) " (() "n" (parameter_declaration) "onatomic," (type_identifier) "onatomic," (,) " " (parameter_declaration) "ullable," (type_identifier) "ullable," (,) " " (parameter_declaration) "opy," (type_identifier) "opy," (,) " " (parameter_declaration) "eadonly)" (type_identifier) "eadonly)" ()) " " (identifier) "SURL " (pointer_declarator) "targetUrl;" (*) "t" (identifier) "argetUrl;" (;) "\n" (comment) "// Unavailable.\n" (ERROR) " (i" (-) " " (() "i" (declaration) "nstancetype)init NS_UNAVAILABLE;\n" (type_identifier) "nstancetype)" (ERROR) "init " ()) "i" (identifier) "nit " (identifier) "S_UNAVAILABLE;" (;) "\n" (ERROR) "e" (ERROR) "e" (type_identifier) "nd\n" (identifier) "S_ASSUME_NONNULL_END\n"
66
9
{"language": "c", "success": true, "metadata": {"lines": 21, "avg_line_length": 22.29, "nodes": 42, "errors": 0, "source_hash": "6d7c48952eb5143f5ce32e2e7e7d3b4668d4c39b2156d4c931891334e543c9ba", "categorized_nodes": 27}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "import <Foundation/Foundation.h>\n\n", "parent": null, "children": [1], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 1, "type": "preproc_arg", "text": "Foundation/Foundation.h>\n", "parent": 0, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 33}}, {"id": 2, "type": "ERROR", "text": "S_ASSUME_NONNULL_BEGIN\n\n/** Defines the metadata for a IAM action.\n */\nNS_SWIFT_NAME(Action)\n@interface WPAction : NSObject\n\n/**\n * The URL to follow if the action is clicked.\n */\n@property(nonatomic, nullable, copy, readonly) NSURL *targetUrl;\n\n/// Unavailable.\n- (instancetype)init NS_UNAVAILABLE;\n\n@end\n\nNS_ASSUME_NONNULL_END\n", "parent": null, "children": [3, 4, 8, 10, 31, 33, 38, 40, 41], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 27, "column": 21}}, {"id": 3, "type": "type_identifier", "text": "S_ASSUME_NONNULL_BEGIN\n", "parent": 2, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 23}}, {"id": 4, "type": "function_declarator", "text": "S_SWIFT_NAME(Action)\n", "parent": 2, "children": [5, 6], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 21}}, {"id": 5, "type": "identifier", "text": "S_SWIFT_NAME(", "parent": 4, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 13}}, {"id": 6, "type": "parameter_list", "text": "Action)\n", "parent": 4, "children": [7], "start_point": {"row": 14, "column": 13}, "end_point": {"row": 14, "column": 21}}, {"id": 7, "type": "identifier", "text": "ction)", "parent": 6, "children": [], "start_point": {"row": 14, "column": 14}, "end_point": {"row": 14, "column": 20}}, {"id": 8, "type": "ERROR", "text": "i", "parent": 2, "children": [9], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 1}}, {"id": 9, "type": "ERROR", "text": "i", "parent": 8, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 1}}, {"id": 10, "type": "declaration", "text": "nterface WPAction : NSObject\n\n/**\n * The URL to follow if the action is clicked.\n */\n@property(nonatomic, nullable, copy, readonly) NSURL *targetUrl;\n", "parent": 2, "children": [11, 12, 28], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 20, "column": 64}}, {"id": 11, "type": "type_identifier", "text": "nterface ", "parent": 10, "children": [], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 10}}, {"id": 12, "type": "ERROR", "text": "PAction : NSObject\n\n/**\n * The URL to follow if the action is clicked.\n */\n@property(nonatomic, nullable, copy, readonly) NSURL ", "parent": 10, "children": [13, 14, 15, 16], "start_point": {"row": 15, "column": 11}, "end_point": {"row": 20, "column": 52}}, {"id": 13, "type": "identifier", "text": "PAction ", "parent": 12, "children": [], "start_point": {"row": 15, "column": 11}, "end_point": {"row": 15, "column": 19}}, {"id": 14, "type": "identifier", "text": "SObject\n", "parent": 12, "children": [], "start_point": {"row": 15, "column": 22}, "end_point": {"row": 15, "column": 30}}, {"id": 15, "type": "ERROR", "text": "p", "parent": 12, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 1}}, {"id": 16, "type": "function_declarator", "text": "roperty(nonatomic, nullable, copy, readonly) NSURL ", "parent": 12, "children": [17, 18, 27], "start_point": {"row": 20, "column": 1}, "end_point": {"row": 20, "column": 52}}, {"id": 17, "type": "identifier", "text": "roperty(", "parent": 16, "children": [], "start_point": {"row": 20, "column": 1}, "end_point": {"row": 20, "column": 9}}, {"id": 18, "type": "parameter_list", "text": "nonatomic, nullable, copy, readonly) ", "parent": 16, "children": [19, 21, 23, 25], "start_point": {"row": 20, "column": 9}, "end_point": {"row": 20, "column": 46}}, {"id": 19, "type": "parameter_declaration", "text": "onatomic,", "parent": 18, "children": [20], "start_point": {"row": 20, "column": 10}, "end_point": {"row": 20, "column": 19}}, {"id": 20, "type": "type_identifier", "text": "onatomic,", "parent": 19, "children": [], "start_point": {"row": 20, "column": 10}, "end_point": {"row": 20, "column": 19}}, {"id": 21, "type": "parameter_declaration", "text": "ullable,", "parent": 18, "children": [22], "start_point": {"row": 20, "column": 21}, "end_point": {"row": 20, "column": 29}}, {"id": 22, "type": "type_identifier", "text": "ullable,", "parent": 21, "children": [], "start_point": {"row": 20, "column": 21}, "end_point": {"row": 20, "column": 29}}, {"id": 23, "type": "parameter_declaration", "text": "opy,", "parent": 18, "children": [24], "start_point": {"row": 20, "column": 31}, "end_point": {"row": 20, "column": 35}}, {"id": 24, "type": "type_identifier", "text": "opy,", "parent": 23, "children": [], "start_point": {"row": 20, "column": 31}, "end_point": {"row": 20, "column": 35}}, {"id": 25, "type": "parameter_declaration", "text": "eadonly)", "parent": 18, "children": [26], "start_point": {"row": 20, "column": 37}, "end_point": {"row": 20, "column": 45}}, {"id": 26, "type": "type_identifier", "text": "eadonly)", "parent": 25, "children": [], "start_point": {"row": 20, "column": 37}, "end_point": {"row": 20, "column": 45}}, {"id": 27, "type": "identifier", "text": "SURL ", "parent": 16, "children": [], "start_point": {"row": 20, "column": 47}, "end_point": {"row": 20, "column": 52}}, {"id": 28, "type": "pointer_declarator", "text": "targetUrl;", "parent": 10, "children": [29, 30], "start_point": {"row": 20, "column": 53}, "end_point": {"row": 20, "column": 63}}, {"id": 29, "type": "*", "text": "t", "parent": 28, "children": [], "start_point": {"row": 20, "column": 53}, "end_point": {"row": 20, "column": 54}}, {"id": 30, "type": "identifier", "text": "argetUrl;", "parent": 28, "children": [], "start_point": {"row": 20, "column": 54}, "end_point": {"row": 20, "column": 63}}, {"id": 31, "type": "ERROR", "text": " (i", "parent": 2, "children": [32], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 3}}, {"id": 32, "type": "-", "text": " ", "parent": 31, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 1}}, {"id": 33, "type": "declaration", "text": "nstancetype)init NS_UNAVAILABLE;\n", "parent": 2, "children": [34, 35, 37], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 23, "column": 36}}, {"id": 34, "type": "type_identifier", "text": "nstancetype)", "parent": 33, "children": [], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 23, "column": 15}}, {"id": 35, "type": "ERROR", "text": "init ", "parent": 33, "children": [36], "start_point": {"row": 23, "column": 15}, "end_point": {"row": 23, "column": 20}}, {"id": 36, "type": "identifier", "text": "nit ", "parent": 35, "children": [], "start_point": {"row": 23, "column": 16}, "end_point": {"row": 23, "column": 20}}, {"id": 37, "type": "identifier", "text": "S_UNAVAILABLE;", "parent": 33, "children": [], "start_point": {"row": 23, "column": 21}, "end_point": {"row": 23, "column": 35}}, {"id": 38, "type": "ERROR", "text": "e", "parent": 2, "children": [39], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 1}}, {"id": 39, "type": "ERROR", "text": "e", "parent": 38, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 1}}, {"id": 40, "type": "type_identifier", "text": "nd\n", "parent": 2, "children": [], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 25, "column": 4}}, {"id": 41, "type": "identifier", "text": "S_ASSUME_NONNULL_END\n", "parent": 2, "children": [], "start_point": {"row": 27, "column": 0}, "end_point": {"row": 27, "column": 21}}]}, "node_categories": {"declarations": {"functions": [4, 16], "variables": [10, 19, 21, 23, 25, 33], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [3, 5, 7, 11, 13, 14, 17, 20, 22, 24, 26, 27, 30, 34, 36, 37, 40, 41], "returns": [], "exceptions": []}, "expressions": {"calls": [0], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 4, "universal_type": "function", "name": "unknown", "text_snippet": "S_SWIFT_NAME(Action)\n"}, {"node_id": 16, "universal_type": "function", "name": "unknown", "text_snippet": "roperty(nonatomic, nullable, copy, readonly) NSURL "}], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// WPAction.h\n// WonderPush\n//\n// Created by <NAME> on 19/02/2020.\n// Copyright \u00a9 2020 WonderPush. All rights reserved.\n//\n\n#import <Foundation/Foundation.h>\n\nNS_ASSUME_NONNULL_BEGIN\n\n/** Defines the metadata for a IAM action.\n */\nNS_SWIFT_NAME(Action)\n@interface WPAction : NSObject\n\n/**\n * The URL to follow if the action is clicked.\n */\n@property(nonatomic, nullable, copy, readonly) NSURL *targetUrl;\n\n/// Unavailable.\n- (instancetype)init NS_UNAVAILABLE;\n\n@end\n\nNS_ASSUME_NONNULL_END\n"}
80,576
c
//------------------------------------------------------------------------------ // <copyright file="Camera.h" company="Microsoft"> // Copyright (c) Microsoft Corporation. All rights reserved. // </copyright> //------------------------------------------------------------------------------ #pragma once #include <windows.h> #include <xnamath.h> class CCamera { public: XMMATRIX View; /// <summary> /// Constructor /// </summary> CCamera(); /// <summary> /// Handles window messages, used to process input /// </summary> /// <param name="hWnd">window message is for</param> /// <param name="uMsg">message</param> /// <param name="wParam">message data</param> /// <param name="lParam">additional message data</param> /// <returns>result of message processing</returns> LRESULT HandleMessages(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam); /// <summary> /// Reset the camera state to initial values /// </summary> void Reset(); /// <summary> /// Update the view matrix /// </summary> void Update(); /// <summary> /// Get the camera's up vector /// </summary> /// <returns>camera's up vector</returns> XMVECTOR GetUp() { return m_up; } /// <summary> /// Get the camera's right vector /// </summary> /// <returns>camera's right vector</returns> XMVECTOR GetRight() { return m_right; } /// <summary> /// Get the camera's position vector /// </summary> /// <returns>camera's position vector</returns> XMVECTOR GetEye() { return m_eye; } private: float m_rotationSpeed; float m_movementSpeed; float m_yaw; float m_pitch; XMVECTOR m_eye; XMVECTOR m_at; XMVECTOR m_up; XMVECTOR m_forward; XMVECTOR m_right; XMVECTOR m_atBasis; XMVECTOR m_upBasis; };
30.17
60
(translation_unit) "------------------------------------------------------------------------------\n// <copyright file="Camera.h" company="Microsoft">\n// Copyright (c) Microsoft Corporation. All rights reserved.\n// </copyright>\n//------------------------------------------------------------------------------\n\n#pragma once\n\n#include <windows.h>\n#include <xnamath.h>\n\nclass CCamera {\npublic:\n XMMATRIX View;\n\n /// <summary>\n /// Constructor\n /// </summary>\n CCamera();\n\n /// <summary>\n /// Handles window messages, used to process input\n /// </summary>\n /// <param name="hWnd">window message is for</param>\n /// <param name="uMsg">message</param>\n /// <param name="wParam">message data</param>\n /// <param name="lParam">additional message data</param>\n /// <returns>result of message processing</returns>\n LRESULT HandleMessages(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);\n\n /// <summary>\n /// Reset the camera state to initial values\n /// </summary>\n void Reset();\n\n /// <summary>\n /// Update the view matrix\n /// </summary>\n void Update();\n\n /// <summary>\n /// Get the camera's up vector\n /// </summary>\n /// <returns>camera's up vector</returns>\n XMVECTOR GetUp() { return m_up; }\n\n /// <summary>\n /// Get the camera's right vector\n /// </summary>\n /// <returns>camera's right vector</returns>\n XMVECTOR GetRight() { return m_right; }\n\n /// <summary>\n /// Get the camera's position vector\n /// </summary>\n /// <returns>camera's position vector</returns>\n XMVECTOR GetEye() { return m_eye; }\n\nprivate:\n float m_rotationSpeed;\n float m_movementSpeed;\n\n float m_yaw;\n float m_pitch;\n\n XMVECTOR m_eye;\n XMVECTOR m_at;\n XMVECTOR m_up;\n XMVECTOR m_forward;\n XMVECTOR m_right;\n\n XMVECTOR m_atBasis;\n XMVECTOR m_upBasis;\n};" (comment) "------------------------------------------------------------------------------\n/" (comment) " <copyright file="Camera.h" company="Microsoft">\n/" (comment) " Copyright (c) Microsoft Corporation. All rights reserved.\n/" (comment) " </copyright>\n/" (comment) "------------------------------------------------------------------------------\n\n" (preproc_call) "ragma once\n\n#" (preproc_directive) "ragma o" (preproc_arg) "ce\n\n" (preproc_include) "nclude <windows.h>\n#i" (#include) "nclude <" (system_lib_string) "indows.h>\n#" (preproc_include) "nclude <xnamath.h>\n\nc" (#include) "nclude <" (system_lib_string) "namath.h>\n\n" (function_definition) "ass CCamera {\npublic:\n XMMATRIX View;\n\n /// <summary>\n /// Constructor\n /// </summary>\n CCamera();\n\n /// <summary>\n /// Handles window messages, used to process input\n /// </summary>\n /// <param name="hWnd">window message is for</param>\n /// <param name="uMsg">message</param>\n /// <param name="wParam">message data</param>\n /// <param name="lParam">additional message data</param>\n /// <returns>result of message processing</returns>\n LRESULT HandleMessages(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);\n\n /// <summary>\n /// Reset the camera state to initial values\n /// </summary>\n void Reset();\n\n /// <summary>\n /// Update the view matrix\n /// </summary>\n void Update();\n\n /// <summary>\n /// Get the camera's up vector\n /// </summary>\n /// <returns>camera's up vector</returns>\n XMVECTOR GetUp() { return m_up; }\n\n /// <summary>\n /// Get the camera's right vector\n /// </summary>\n /// <returns>camera's right vector</returns>\n XMVECTOR GetRight() { return m_right; }\n\n /// <summary>\n /// Get the camera's position vector\n /// </summary>\n /// <returns>camera's position vector</returns>\n XMVECTOR GetEye() { return m_eye; }\n\nprivate:\n float m_rotationSpeed;\n float m_movementSpeed;\n\n float m_yaw;\n float m_pitch;\n\n XMVECTOR m_eye;\n XMVECTOR m_at;\n XMVECTOR m_up;\n XMVECTOR m_forward;\n XMVECTOR m_right;\n\n XMVECTOR m_atBasis;\n XMVECTOR m_upBasis;\n};" (type_identifier) "ass C" (identifier) "amera {" (compound_statement) "public:\n XMMATRIX View;\n\n /// <summary>\n /// Constructor\n /// </summary>\n CCamera();\n\n /// <summary>\n /// Handles window messages, used to process input\n /// </summary>\n /// <param name="hWnd">window message is for</param>\n /// <param name="uMsg">message</param>\n /// <param name="wParam">message data</param>\n /// <param name="lParam">additional message data</param>\n /// <returns>result of message processing</returns>\n LRESULT HandleMessages(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);\n\n /// <summary>\n /// Reset the camera state to initial values\n /// </summary>\n void Reset();\n\n /// <summary>\n /// Update the view matrix\n /// </summary>\n void Update();\n\n /// <summary>\n /// Get the camera's up vector\n /// </summary>\n /// <returns>camera's up vector</returns>\n XMVECTOR GetUp() { return m_up; }\n\n /// <summary>\n /// Get the camera's right vector\n /// </summary>\n /// <returns>camera's right vector</returns>\n XMVECTOR GetRight() { return m_right; }\n\n /// <summary>\n /// Get the camera's position vector\n /// </summary>\n /// <returns>camera's position vector</returns>\n XMVECTOR GetEye() { return m_eye; }\n\nprivate:\n float m_rotationSpeed;\n float m_movementSpeed;\n\n float m_yaw;\n float m_pitch;\n\n XMVECTOR m_eye;\n XMVECTOR m_at;\n XMVECTOR m_up;\n XMVECTOR m_forward;\n XMVECTOR m_right;\n\n XMVECTOR m_atBasis;\n XMVECTOR m_upBasis;\n};" ({) "p" (labeled_statement) "blic:\n XMMATRIX View;\n\n" (statement_identifier) "blic:\n" (:) " " (declaration) "MATRIX View;\n\n" (type_identifier) "MATRIX V" (identifier) "ew;\n" (;) "\n" (comment) "/ <summary>\n " (comment) "/ Constructor\n " (comment) "/ </summary>\n " (expression_statement) "amera();\n\n" (call_expression) "amera();\n" (identifier) "amera()" (argument_list) ";\n" (() ";" ()) "\n" (;) "\n" (comment) "/ <summary>\n " (comment) "/ Handles window messages, used to process input\n " (comment) "/ </summary>\n " (comment) "/ <param name="hWnd">window message is for</param>\n " (comment) "/ <param name="uMsg">message</param>\n " (comment) "/ <param name="wParam">message data</param>\n " (comment) "/ <param name="lParam">additional message data</param>\n " (comment) "/ <returns>result of message processing</returns>\n " (declaration) "ESULT HandleMessages(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);\n\n" (type_identifier) "ESULT H" (function_declarator) "ndleMessages(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);\n" (identifier) "ndleMessages(H" (parameter_list) "WND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);\n" (() "W" (parameter_declaration) "ND hWnd, " (type_identifier) "ND h" (identifier) "nd, " (,) "U" (parameter_declaration) "NT uMsg, " (type_identifier) "NT u" (identifier) "sg, " (,) "W" (parameter_declaration) "ARAM wParam, " (type_identifier) "ARAM w" (identifier) "aram, " (,) "L" (parameter_declaration) "ARAM lParam);" (type_identifier) "ARAM l" (identifier) "aram);" ()) "\n" (;) "\n" (comment) "/ <summary>\n " (comment) "/ Reset the camera state to initial values\n " (comment) "/ </summary>\n " (declaration) "id Reset();\n\n" (primitive_type) "id R" (function_declarator) "set();\n" (identifier) "set()" (parameter_list) ";\n" (() ";" ()) "\n" (;) "\n" (comment) "/ <summary>\n " (comment) "/ Update the view matrix\n " (comment) "/ </summary>\n " (declaration) "id Update();\n\n" (primitive_type) "id U" (function_declarator) "date();\n" (identifier) "date()" (parameter_list) ";\n" (() ";" ()) "\n" (;) "\n" (comment) "/ <summary>\n " (comment) "/ Get the camera's up vector\n " (comment) "/ </summary>\n " (comment) "/ <returns>camera's up vector</returns>\n " (function_definition) "VECTOR GetUp() { return m_up; }\n\n" (type_identifier) "VECTOR " (function_declarator) "tUp() {" (identifier) "tUp()" (parameter_list) " {" (() " " ()) "{" (compound_statement) "return m_up; }\n\n" ({) "r" (return_statement) "turn m_up; }" (return) "turn m" (identifier) "up; " (;) "}" (}) "\n" (comment) "/ <summary>\n " (comment) "/ Get the camera's right vector\n " (comment) "/ </summary>\n " (comment) "/ <returns>camera's right vector</returns>\n " (function_definition) "VECTOR GetRight() { return m_right; }\n\n" (type_identifier) "VECTOR " (function_declarator) "tRight() {" (identifier) "tRight()" (parameter_list) " {" (() " " ()) "{" (compound_statement) "return m_right; }\n\n" ({) "r" (return_statement) "turn m_right; }" (return) "turn m" (identifier) "right; " (;) "}" (}) "\n" (comment) "/ <summary>\n " (comment) "/ Get the camera's position vector\n " (comment) "/ </summary>\n " (comment) "/ <returns>camera's position vector</returns>\n " (function_definition) "VECTOR GetEye() { return m_eye; }\n\n" (type_identifier) "VECTOR " (function_declarator) "tEye() {" (identifier) "tEye()" (parameter_list) " {" (() " " ()) "{" (compound_statement) "return m_eye; }\n\n" ({) "r" (return_statement) "turn m_eye; }" (return) "turn m" (identifier) "eye; " (;) "}" (}) "\n" (labeled_statement) "ivate:\n float m_rotationSpeed;\n " (statement_identifier) "ivate:\n" (:) " " (declaration) "oat m_rotationSpeed;\n " (primitive_type) "oat " (identifier) "rotationSpeed;\n" (;) " " (declaration) "oat m_movementSpeed;\n\n" (primitive_type) "oat " (identifier) "movementSpeed;\n" (;) "\n" (declaration) "oat m_yaw;\n " (primitive_type) "oat " (identifier) "yaw;\n" (;) " " (declaration) "oat m_pitch;\n\n" (primitive_type) "oat " (identifier) "pitch;\n" (;) "\n" (declaration) "VECTOR m_eye;\n " (type_identifier) "VECTOR " (identifier) "eye;\n" (;) " " (declaration) "VECTOR m_at;\n " (type_identifier) "VECTOR " (identifier) "at;\n" (;) " " (declaration) "VECTOR m_up;\n " (type_identifier) "VECTOR " (identifier) "up;\n" (;) " " (declaration) "VECTOR m_forward;\n " (type_identifier) "VECTOR " (identifier) "forward;\n" (;) " " (declaration) "VECTOR m_right;\n\n" (type_identifier) "VECTOR " (identifier) "right;\n" (;) "\n" (declaration) "VECTOR m_atBasis;\n " (type_identifier) "VECTOR " (identifier) "atBasis;\n" (;) " " (declaration) "VECTOR m_upBasis;\n}" (type_identifier) "VECTOR " (identifier) "upBasis;\n" (;) "}" (}) "" (expression_statement) "" (;) ""
194
0
{"language": "c", "success": true, "metadata": {"lines": 60, "avg_line_length": 30.17, "nodes": 97, "errors": 0, "source_hash": "21592431767568d68e17f7a518c43a2687b470f0d766390e2c07be393713b184", "categorized_nodes": 86}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "ragma once\n\n#", "parent": null, "children": [1, 2], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "ragma o", "parent": 0, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "ce\n\n", "parent": 0, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 12}}, {"id": 3, "type": "preproc_include", "text": "nclude <windows.h>\n#i", "parent": null, "children": [4, 5], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 4, "type": "#include", "text": "nclude <", "parent": 3, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "indows.h>\n#", "parent": 3, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 20}}, {"id": 6, "type": "preproc_include", "text": "nclude <xnamath.h>\n\nc", "parent": null, "children": [7, 8], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 7, "type": "#include", "text": "nclude <", "parent": 6, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "namath.h>\n\n", "parent": 6, "children": [], "start_point": {"row": 9, "column": 9}, "end_point": {"row": 9, "column": 20}}, {"id": 9, "type": "function_definition", "text": "ass CCamera {\npublic:\n XMMATRIX View;\n\n /// <summary>\n /// Constructor\n /// </summary>\n CCamera();\n\n /// <summary>\n /// Handles window messages, used to process input\n /// </summary>\n /// <param name=\"hWnd\">window message is for</param>\n /// <param name=\"uMsg\">message</param>\n /// <param name=\"wParam\">message data</param>\n /// <param name=\"lParam\">additional message data</param>\n /// <returns>result of message processing</returns>\n LRESULT HandleMessages(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);\n\n /// <summary>\n /// Reset the camera state to initial values\n /// </summary>\n void Reset();\n\n /// <summary>\n /// Update the view matrix\n /// </summary>\n void Update();\n\n /// <summary>\n /// Get the camera's up vector\n /// </summary>\n /// <returns>camera's up vector</returns>\n XMVECTOR GetUp() { return m_up; }\n\n /// <summary>\n /// Get the camera's right vector\n /// </summary>\n /// <returns>camera's right vector</returns>\n XMVECTOR GetRight() { return m_right; }\n\n /// <summary>\n /// Get the camera's position vector\n /// </summary>\n /// <returns>camera's position vector</returns>\n XMVECTOR GetEye() { return m_eye; }\n\nprivate:\n float m_rotationSpeed;\n float m_movementSpeed;\n\n float m_yaw;\n float m_pitch;\n\n XMVECTOR m_eye;\n XMVECTOR m_at;\n XMVECTOR m_up;\n XMVECTOR m_forward;\n XMVECTOR m_right;\n\n XMVECTOR m_atBasis;\n XMVECTOR m_upBasis;\n};", "parent": null, "children": [10, 11], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 73, "column": 1}}, {"id": 10, "type": "type_identifier", "text": "ass C", "parent": 9, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 5}}, {"id": 11, "type": "identifier", "text": "amera {", "parent": 9, "children": [], "start_point": {"row": 11, "column": 6}, "end_point": {"row": 11, "column": 13}}, {"id": 12, "type": "labeled_statement", "text": "blic:\n XMMATRIX View;\n\n", "parent": 9, "children": [13, 14], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 13, "column": 18}}, {"id": 13, "type": "statement_identifier", "text": "blic:\n", "parent": 12, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 6}}, {"id": 14, "type": "declaration", "text": "MATRIX View;\n\n", "parent": 12, "children": [15, 16], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 18}}, {"id": 15, "type": "type_identifier", "text": "MATRIX V", "parent": 14, "children": [], "start_point": {"row": 13, "column": 4}, "end_point": {"row": 13, "column": 12}}, {"id": 16, "type": "identifier", "text": "ew;\n", "parent": 14, "children": [], "start_point": {"row": 13, "column": 13}, "end_point": {"row": 13, "column": 17}}, {"id": 17, "type": "call_expression", "text": "amera();\n", "parent": 9, "children": [18], "start_point": {"row": 18, "column": 4}, "end_point": {"row": 18, "column": 13}}, {"id": 18, "type": "identifier", "text": "amera()", "parent": 17, "children": [], "start_point": {"row": 18, "column": 4}, "end_point": {"row": 18, "column": 11}}, {"id": 19, "type": "declaration", "text": "ESULT HandleMessages(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);\n\n", "parent": 9, "children": [20, 21], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 28, "column": 79}}, {"id": 20, "type": "type_identifier", "text": "ESULT H", "parent": 19, "children": [], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 28, "column": 11}}, {"id": 21, "type": "function_declarator", "text": "ndleMessages(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);\n", "parent": 19, "children": [22, 23], "start_point": {"row": 28, "column": 12}, "end_point": {"row": 28, "column": 78}}, {"id": 22, "type": "identifier", "text": "ndleMessages(H", "parent": 21, "children": [], "start_point": {"row": 28, "column": 12}, "end_point": {"row": 28, "column": 26}}, {"id": 23, "type": "parameter_list", "text": "WND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);\n", "parent": 21, "children": [24, 27, 30, 33], "start_point": {"row": 28, "column": 26}, "end_point": {"row": 28, "column": 78}}, {"id": 24, "type": "parameter_declaration", "text": "ND hWnd, ", "parent": 23, "children": [25, 26], "start_point": {"row": 28, "column": 27}, "end_point": {"row": 28, "column": 36}}, {"id": 25, "type": "type_identifier", "text": "ND h", "parent": 24, "children": [], "start_point": {"row": 28, "column": 27}, "end_point": {"row": 28, "column": 31}}, {"id": 26, "type": "identifier", "text": "nd, ", "parent": 24, "children": [], "start_point": {"row": 28, "column": 32}, "end_point": {"row": 28, "column": 36}}, {"id": 27, "type": "parameter_declaration", "text": "NT uMsg, ", "parent": 23, "children": [28, 29], "start_point": {"row": 28, "column": 38}, "end_point": {"row": 28, "column": 47}}, {"id": 28, "type": "type_identifier", "text": "NT u", "parent": 27, "children": [], "start_point": {"row": 28, "column": 38}, "end_point": {"row": 28, "column": 42}}, {"id": 29, "type": "identifier", "text": "sg, ", "parent": 27, "children": [], "start_point": {"row": 28, "column": 43}, "end_point": {"row": 28, "column": 47}}, {"id": 30, "type": "parameter_declaration", "text": "ARAM wParam, ", "parent": 23, "children": [31, 32], "start_point": {"row": 28, "column": 49}, "end_point": {"row": 28, "column": 62}}, {"id": 31, "type": "type_identifier", "text": "ARAM w", "parent": 30, "children": [], "start_point": {"row": 28, "column": 49}, "end_point": {"row": 28, "column": 55}}, {"id": 32, "type": "identifier", "text": "aram, ", "parent": 30, "children": [], "start_point": {"row": 28, "column": 56}, "end_point": {"row": 28, "column": 62}}, {"id": 33, "type": "parameter_declaration", "text": "ARAM lParam);", "parent": 23, "children": [34, 35], "start_point": {"row": 28, "column": 64}, "end_point": {"row": 28, "column": 77}}, {"id": 34, "type": "type_identifier", "text": "ARAM l", "parent": 33, "children": [], "start_point": {"row": 28, "column": 64}, "end_point": {"row": 28, "column": 70}}, {"id": 35, "type": "identifier", "text": "aram);", "parent": 33, "children": [], "start_point": {"row": 28, "column": 71}, "end_point": {"row": 28, "column": 77}}, {"id": 36, "type": "declaration", "text": "id Reset();\n\n", "parent": 9, "children": [37, 38], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 17}}, {"id": 37, "type": "primitive_type", "text": "id R", "parent": 36, "children": [], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 8}}, {"id": 38, "type": "function_declarator", "text": "set();\n", "parent": 36, "children": [39], "start_point": {"row": 33, "column": 9}, "end_point": {"row": 33, "column": 16}}, {"id": 39, "type": "identifier", "text": "set()", "parent": 38, "children": [], "start_point": {"row": 33, "column": 9}, "end_point": {"row": 33, "column": 14}}, {"id": 40, "type": "declaration", "text": "id Update();\n\n", "parent": 9, "children": [41, 42], "start_point": {"row": 38, "column": 4}, "end_point": {"row": 38, "column": 18}}, {"id": 41, "type": "primitive_type", "text": "id U", "parent": 40, "children": [], "start_point": {"row": 38, "column": 4}, "end_point": {"row": 38, "column": 8}}, {"id": 42, "type": "function_declarator", "text": "date();\n", "parent": 40, "children": [43], "start_point": {"row": 38, "column": 9}, "end_point": {"row": 38, "column": 17}}, {"id": 43, "type": "identifier", "text": "date()", "parent": 42, "children": [], "start_point": {"row": 38, "column": 9}, "end_point": {"row": 38, "column": 15}}, {"id": 44, "type": "function_definition", "text": "VECTOR GetUp() { return m_up; }\n\n", "parent": 9, "children": [45, 46], "start_point": {"row": 44, "column": 4}, "end_point": {"row": 44, "column": 38}}, {"id": 45, "type": "type_identifier", "text": "VECTOR ", "parent": 44, "children": [], "start_point": {"row": 44, "column": 4}, "end_point": {"row": 44, "column": 12}}, {"id": 46, "type": "function_declarator", "text": "tUp() {", "parent": 44, "children": [47], "start_point": {"row": 44, "column": 14}, "end_point": {"row": 44, "column": 21}}, {"id": 47, "type": "identifier", "text": "tUp()", "parent": 46, "children": [], "start_point": {"row": 44, "column": 14}, "end_point": {"row": 44, "column": 19}}, {"id": 48, "type": "return_statement", "text": "turn m_up; }", "parent": 44, "children": [49], "start_point": {"row": 44, "column": 24}, "end_point": {"row": 44, "column": 36}}, {"id": 49, "type": "identifier", "text": "up; ", "parent": 48, "children": [], "start_point": {"row": 44, "column": 31}, "end_point": {"row": 44, "column": 35}}, {"id": 50, "type": "function_definition", "text": "VECTOR GetRight() { return m_right; }\n\n", "parent": 9, "children": [51, 52], "start_point": {"row": 50, "column": 4}, "end_point": {"row": 50, "column": 44}}, {"id": 51, "type": "type_identifier", "text": "VECTOR ", "parent": 50, "children": [], "start_point": {"row": 50, "column": 4}, "end_point": {"row": 50, "column": 12}}, {"id": 52, "type": "function_declarator", "text": "tRight() {", "parent": 50, "children": [53], "start_point": {"row": 50, "column": 14}, "end_point": {"row": 50, "column": 24}}, {"id": 53, "type": "identifier", "text": "tRight()", "parent": 52, "children": [], "start_point": {"row": 50, "column": 14}, "end_point": {"row": 50, "column": 22}}, {"id": 54, "type": "return_statement", "text": "turn m_right; }", "parent": 50, "children": [55], "start_point": {"row": 50, "column": 27}, "end_point": {"row": 50, "column": 42}}, {"id": 55, "type": "identifier", "text": "right; ", "parent": 54, "children": [], "start_point": {"row": 50, "column": 34}, "end_point": {"row": 50, "column": 41}}, {"id": 56, "type": "function_definition", "text": "VECTOR GetEye() { return m_eye; }\n\n", "parent": 9, "children": [57, 58], "start_point": {"row": 56, "column": 4}, "end_point": {"row": 56, "column": 40}}, {"id": 57, "type": "type_identifier", "text": "VECTOR ", "parent": 56, "children": [], "start_point": {"row": 56, "column": 4}, "end_point": {"row": 56, "column": 12}}, {"id": 58, "type": "function_declarator", "text": "tEye() {", "parent": 56, "children": [59], "start_point": {"row": 56, "column": 14}, "end_point": {"row": 56, "column": 22}}, {"id": 59, "type": "identifier", "text": "tEye()", "parent": 58, "children": [], "start_point": {"row": 56, "column": 14}, "end_point": {"row": 56, "column": 20}}, {"id": 60, "type": "return_statement", "text": "turn m_eye; }", "parent": 56, "children": [61], "start_point": {"row": 56, "column": 25}, "end_point": {"row": 56, "column": 38}}, {"id": 61, "type": "identifier", "text": "eye; ", "parent": 60, "children": [], "start_point": {"row": 56, "column": 32}, "end_point": {"row": 56, "column": 37}}, {"id": 62, "type": "labeled_statement", "text": "ivate:\n float m_rotationSpeed;\n ", "parent": 9, "children": [63, 64], "start_point": {"row": 58, "column": 0}, "end_point": {"row": 59, "column": 30}}, {"id": 63, "type": "statement_identifier", "text": "ivate:\n", "parent": 62, "children": [], "start_point": {"row": 58, "column": 0}, "end_point": {"row": 58, "column": 7}}, {"id": 64, "type": "declaration", "text": "oat m_rotationSpeed;\n ", "parent": 62, "children": [65, 66], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 30}}, {"id": 65, "type": "primitive_type", "text": "oat ", "parent": 64, "children": [], "start_point": {"row": 59, "column": 4}, "end_point": {"row": 59, "column": 9}}, {"id": 66, "type": "identifier", "text": "rotationSpeed;\n", "parent": 64, "children": [], "start_point": {"row": 59, "column": 14}, "end_point": {"row": 59, "column": 29}}, {"id": 67, "type": "declaration", "text": "oat m_movementSpeed;\n\n", "parent": 9, "children": [68, 69], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 30}}, {"id": 68, "type": "primitive_type", "text": "oat ", "parent": 67, "children": [], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 9}}, {"id": 69, "type": "identifier", "text": "movementSpeed;\n", "parent": 67, "children": [], "start_point": {"row": 60, "column": 14}, "end_point": {"row": 60, "column": 29}}, {"id": 70, "type": "declaration", "text": "oat m_yaw;\n ", "parent": 9, "children": [71, 72], "start_point": {"row": 62, "column": 4}, "end_point": {"row": 62, "column": 20}}, {"id": 71, "type": "primitive_type", "text": "oat ", "parent": 70, "children": [], "start_point": {"row": 62, "column": 4}, "end_point": {"row": 62, "column": 9}}, {"id": 72, "type": "identifier", "text": "yaw;\n", "parent": 70, "children": [], "start_point": {"row": 62, "column": 14}, "end_point": {"row": 62, "column": 19}}, {"id": 73, "type": "declaration", "text": "oat m_pitch;\n\n", "parent": 9, "children": [74, 75], "start_point": {"row": 63, "column": 4}, "end_point": {"row": 63, "column": 22}}, {"id": 74, "type": "primitive_type", "text": "oat ", "parent": 73, "children": [], "start_point": {"row": 63, "column": 4}, "end_point": {"row": 63, "column": 9}}, {"id": 75, "type": "identifier", "text": "pitch;\n", "parent": 73, "children": [], "start_point": {"row": 63, "column": 14}, "end_point": {"row": 63, "column": 21}}, {"id": 76, "type": "declaration", "text": "VECTOR m_eye;\n ", "parent": 9, "children": [77, 78], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 20}}, {"id": 77, "type": "type_identifier", "text": "VECTOR ", "parent": 76, "children": [], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 12}}, {"id": 78, "type": "identifier", "text": "eye;\n", "parent": 76, "children": [], "start_point": {"row": 65, "column": 14}, "end_point": {"row": 65, "column": 19}}, {"id": 79, "type": "declaration", "text": "VECTOR m_at;\n ", "parent": 9, "children": [80, 81], "start_point": {"row": 66, "column": 4}, "end_point": {"row": 66, "column": 19}}, {"id": 80, "type": "type_identifier", "text": "VECTOR ", "parent": 79, "children": [], "start_point": {"row": 66, "column": 4}, "end_point": {"row": 66, "column": 12}}, {"id": 81, "type": "identifier", "text": "at;\n", "parent": 79, "children": [], "start_point": {"row": 66, "column": 14}, "end_point": {"row": 66, "column": 18}}, {"id": 82, "type": "declaration", "text": "VECTOR m_up;\n ", "parent": 9, "children": [83, 84], "start_point": {"row": 67, "column": 4}, "end_point": {"row": 67, "column": 19}}, {"id": 83, "type": "type_identifier", "text": "VECTOR ", "parent": 82, "children": [], "start_point": {"row": 67, "column": 4}, "end_point": {"row": 67, "column": 12}}, {"id": 84, "type": "identifier", "text": "up;\n", "parent": 82, "children": [], "start_point": {"row": 67, "column": 14}, "end_point": {"row": 67, "column": 18}}, {"id": 85, "type": "declaration", "text": "VECTOR m_forward;\n ", "parent": 9, "children": [86, 87], "start_point": {"row": 68, "column": 4}, "end_point": {"row": 68, "column": 24}}, {"id": 86, "type": "type_identifier", "text": "VECTOR ", "parent": 85, "children": [], "start_point": {"row": 68, "column": 4}, "end_point": {"row": 68, "column": 12}}, {"id": 87, "type": "identifier", "text": "forward;\n", "parent": 85, "children": [], "start_point": {"row": 68, "column": 14}, "end_point": {"row": 68, "column": 23}}, {"id": 88, "type": "declaration", "text": "VECTOR m_right;\n\n", "parent": 9, "children": [89, 90], "start_point": {"row": 69, "column": 4}, "end_point": {"row": 69, "column": 22}}, {"id": 89, "type": "type_identifier", "text": "VECTOR ", "parent": 88, "children": [], "start_point": {"row": 69, "column": 4}, "end_point": {"row": 69, "column": 12}}, {"id": 90, "type": "identifier", "text": "right;\n", "parent": 88, "children": [], "start_point": {"row": 69, "column": 14}, "end_point": {"row": 69, "column": 21}}, {"id": 91, "type": "declaration", "text": "VECTOR m_atBasis;\n ", "parent": 9, "children": [92, 93], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 24}}, {"id": 92, "type": "type_identifier", "text": "VECTOR ", "parent": 91, "children": [], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 12}}, {"id": 93, "type": "identifier", "text": "atBasis;\n", "parent": 91, "children": [], "start_point": {"row": 71, "column": 14}, "end_point": {"row": 71, "column": 23}}, {"id": 94, "type": "declaration", "text": "VECTOR m_upBasis;\n}", "parent": 9, "children": [95, 96], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 24}}, {"id": 95, "type": "type_identifier", "text": "VECTOR ", "parent": 94, "children": [], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 12}}, {"id": 96, "type": "identifier", "text": "upBasis;\n", "parent": 94, "children": [], "start_point": {"row": 72, "column": 14}, "end_point": {"row": 72, "column": 23}}]}, "node_categories": {"declarations": {"functions": [9, 21, 38, 42, 44, 46, 50, 52, 56, 58], "variables": [14, 19, 24, 27, 30, 33, 36, 40, 64, 67, 70, 73, 76, 79, 82, 85, 88, 91, 94], "classes": [], "imports": [3, 4, 6, 7], "modules": [], "enums": []}, "statements": {"expressions": [17], "assignments": [], "loops": [], "conditionals": [10, 11, 13, 15, 16, 18, 20, 22, 25, 26, 28, 29, 31, 32, 34, 35, 39, 43, 45, 47, 49, 51, 53, 55, 57, 59, 61, 63, 66, 69, 72, 75, 77, 78, 80, 81, 83, 84, 86, 87, 89, 90, 92, 93, 95, 96], "returns": [48, 54, 60], "exceptions": []}, "expressions": {"calls": [0], "literals": [5, 8], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 9, "universal_type": "function", "name": "Reset", "text_snippet": "ass CCamera {\npublic:\n XMMATRIX View;\n\n /// <summary>\n /// Constructor\n /// </summary>\n "}, {"node_id": 21, "universal_type": "function", "name": "unknown", "text_snippet": "ndleMessages(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);\n"}, {"node_id": 38, "universal_type": "function", "name": "unknown", "text_snippet": "set();\n"}, {"node_id": 42, "universal_type": "function", "name": "unknown", "text_snippet": "date();\n"}, {"node_id": 44, "universal_type": "function", "name": "unknown", "text_snippet": "VECTOR GetUp() { return m_up; }\n\n"}, {"node_id": 46, "universal_type": "function", "name": "unknown", "text_snippet": "tUp() {"}, {"node_id": 50, "universal_type": "function", "name": "unknown", "text_snippet": "VECTOR GetRight() { return m_right; }\n\n"}, {"node_id": 52, "universal_type": "function", "name": "unknown", "text_snippet": "tRight() {"}, {"node_id": 56, "universal_type": "function", "name": "unknown", "text_snippet": "VECTOR GetEye() { return m_eye; }\n\n"}, {"node_id": 58, "universal_type": "function", "name": "unknown", "text_snippet": "tEye() {"}], "class_declarations": [], "import_statements": [{"node_id": 3, "text": "nclude <windows.h>\n#i"}, {"node_id": 4, "text": "nclude <"}, {"node_id": 6, "text": "nclude <xnamath.h>\n\nc"}, {"node_id": 7, "text": "nclude <"}]}, "original_source_code": "\ufeff//------------------------------------------------------------------------------\n// <copyright file=\"Camera.h\" company=\"Microsoft\">\n// Copyright (c) Microsoft Corporation. All rights reserved.\n// </copyright>\n//------------------------------------------------------------------------------\n\n#pragma once\n\n#include <windows.h>\n#include <xnamath.h>\n\nclass CCamera {\npublic:\n XMMATRIX View;\n\n /// <summary>\n /// Constructor\n /// </summary>\n CCamera();\n\n /// <summary>\n /// Handles window messages, used to process input\n /// </summary>\n /// <param name=\"hWnd\">window message is for</param>\n /// <param name=\"uMsg\">message</param>\n /// <param name=\"wParam\">message data</param>\n /// <param name=\"lParam\">additional message data</param>\n /// <returns>result of message processing</returns>\n LRESULT HandleMessages(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);\n\n /// <summary>\n /// Reset the camera state to initial values\n /// </summary>\n void Reset();\n\n /// <summary>\n /// Update the view matrix\n /// </summary>\n void Update();\n\n /// <summary>\n /// Get the camera's up vector\n /// </summary>\n /// <returns>camera's up vector</returns>\n XMVECTOR GetUp() { return m_up; }\n\n /// <summary>\n /// Get the camera's right vector\n /// </summary>\n /// <returns>camera's right vector</returns>\n XMVECTOR GetRight() { return m_right; }\n\n /// <summary>\n /// Get the camera's position vector\n /// </summary>\n /// <returns>camera's position vector</returns>\n XMVECTOR GetEye() { return m_eye; }\n\nprivate:\n float m_rotationSpeed;\n float m_movementSpeed;\n\n float m_yaw;\n float m_pitch;\n\n XMVECTOR m_eye;\n XMVECTOR m_at;\n XMVECTOR m_up;\n XMVECTOR m_forward;\n XMVECTOR m_right;\n\n XMVECTOR m_atBasis;\n XMVECTOR m_upBasis;\n};"}
80,577
c
#include <stdlib.h> #include "esp32_spi_io.h" #include "gpiohs.h" #include "sleep.h" #include "sysctl.h" #include <utils.h> #include "spi.h" #include "esp32_spi.h" #if 1 /* ESP32_SOFT_SPI */ #define GPIOHS_OUT_HIGH(io) (*(volatile uint32_t *)0x3800100CU) |= (1 << (io)) #define GPIOHS_OUT_LOWX(io) (*(volatile uint32_t *)0x3800100CU) &= ~(1 << (io)) #define GET_GPIOHS_VALX(io) (((*(volatile uint32_t *)0x38001000U) >> (io)) & 1) uint8_t cs_num = 0, rst_num = 0, rdy_num = 0; static uint8_t _mosi_num = -1; static uint8_t _miso_num = -1; static uint8_t _sclk_num = -1; /* SPI端口初始化 */ //should check io value void esp32_spi_config_io(uint8_t cs, uint8_t rst, uint8_t rdy, uint8_t mosi, uint8_t miso, uint8_t sclk) { //clk gpiohs_set_drive_mode(sclk, GPIO_DM_OUTPUT); gpiohs_set_pin(sclk, 0); //mosi gpiohs_set_drive_mode(mosi, GPIO_DM_OUTPUT); gpiohs_set_pin(mosi, 0); //miso gpiohs_set_drive_mode(miso, GPIO_DM_INPUT_PULL_UP); _mosi_num = mosi; _miso_num = miso; _sclk_num = sclk; cs_num = cs; rdy_num = rdy; rst_num = rst; //if rst <0, use soft reset } uint8_t soft_spi_rw(uint8_t data) { uint8_t i; uint8_t temp = 0; for (i = 0; i < 8; i++) { if (data & 0x80) { GPIOHS_OUT_HIGH(_mosi_num); } else { GPIOHS_OUT_LOWX(_mosi_num); } data <<= 1; GPIOHS_OUT_HIGH(_sclk_num); asm volatile("nop"); asm volatile("nop"); asm volatile("nop"); temp <<= 1; if (GET_GPIOHS_VALX(_miso_num)) { temp++; } GPIOHS_OUT_LOWX(_sclk_num); asm volatile("nop"); asm volatile("nop"); asm volatile("nop"); } return temp; } void soft_spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len) { if (send == NULL && recv == NULL) { printf(" buffer is null\r\n"); return; } #if 0 uint32_t i = 0; do { *(recv + i) = soft_spi_rw(*(send + i)); i++; } while (--len); #else uint32_t i = 0; uint8_t *stmp = NULL, sf = 0; if (send == NULL) { stmp = (uint8_t *)malloc(len * sizeof(uint8_t)); // memset(stmp, 'A', len); sf = 1; } else stmp = send; if (recv == NULL) { do { soft_spi_rw(*(stmp + i)); i++; } while (--len); } else { do { *(recv + i) = soft_spi_rw(*(stmp + i)); i++; } while (--len); } if (sf) free(stmp); #endif } #else static spi_transfer_width_t sipeed_spi_get_frame_size(size_t data_bit_length) { if (data_bit_length < 8) return SPI_TRANS_CHAR; else if (data_bit_length < 16) return SPI_TRANS_SHORT; return SPI_TRANS_INT; } static void sipeed_spi_set_tmod(uint8_t spi_num, uint32_t tmod) { configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2); volatile spi_t *spi_handle = spi[spi_num]; uint8_t tmod_offset = 0; switch (spi_num) { case 0: case 1: tmod_offset = 8; break; case 2: configASSERT(!"Spi Bus 2 Not Support!"); break; case 3: default: tmod_offset = 10; break; } set_bit(&spi_handle->ctrlr0, 3 << tmod_offset, tmod << tmod_offset); } static void sipeed_spi_transfer_data_standard(spi_device_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_buff, uint8_t *rx_buff, size_t len) { configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2); configASSERT(len > 0); size_t index, fifo_len; size_t rx_len = len; size_t tx_len = rx_len; sipeed_spi_set_tmod(spi_num, SPI_TMOD_TRANS_RECV); volatile spi_t *spi_handle = spi[spi_num]; uint8_t dfs_offset; switch (spi_num) { case 0: case 1: dfs_offset = 16; break; case 2: configASSERT(!"Spi Bus 2 Not Support!"); break; case 3: default: dfs_offset = 0; break; } uint32_t data_bit_length = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F; spi_transfer_width_t frame_width = sipeed_spi_get_frame_size(data_bit_length); spi_handle->ctrlr1 = (uint32_t)(tx_len / frame_width - 1); spi_handle->ssienr = 0x01; spi_handle->ser = 1U << chip_select; uint32_t i = 0; while (tx_len) { fifo_len = 32 - spi_handle->txflr; fifo_len = fifo_len < tx_len ? fifo_len : tx_len; switch (frame_width) { case SPI_TRANS_INT: fifo_len = fifo_len / 4 * 4; for (index = 0; index < fifo_len / 4; index++) spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++]; break; case SPI_TRANS_SHORT: fifo_len = fifo_len / 2 * 2; for (index = 0; index < fifo_len / 2; index++) spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++]; break; default: for (index = 0; index < fifo_len; index++) spi_handle->dr[0] = tx_buff[i++]; break; } tx_len -= fifo_len; } while ((spi_handle->sr & 0x05) != 0x04) ; i = 0; while (rx_len) { fifo_len = spi_handle->rxflr; fifo_len = fifo_len < rx_len ? fifo_len : rx_len; switch (frame_width) { case SPI_TRANS_INT: fifo_len = fifo_len / 4 * 4; for (index = 0; index < fifo_len / 4; index++) ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0]; break; case SPI_TRANS_SHORT: fifo_len = fifo_len / 2 * 2; for (index = 0; index < fifo_len / 2; index++) ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0]; break; default: for (index = 0; index < fifo_len; index++) rx_buff[i++] = (uint8_t)spi_handle->dr[0]; break; } rx_len -= fifo_len; } spi_handle->ser = 0x00; spi_handle->ssienr = 0x00; } /* SPI端口初始化 */ void soft_spi_init(void) { printf("hard spi\r\n"); //cs gpiohs_set_drive_mode(ESP32_SPI_CSX_HS_NUM, GPIO_DM_OUTPUT); gpiohs_set_pin(ESP32_SPI_CSX_HS_NUM, 1); //init SPI_DEVICE_1 spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0); printf("set spi clk:%d\r\n", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/ } uint8_t soft_spi_rw(uint8_t data) { uint8_t c; sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, &data, &c, 1); return c; } void soft_spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len) { if (send == NULL && recv == NULL) { printf(" buffer is null\r\n"); return; } #if 0 spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0); #endif //only send if (send && recv == NULL) { spi_send_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len); return; } //only recv if (send == NULL && recv) { spi_receive_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len); return; } //send and recv if (send && recv) { sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len); return; } return; } #endif uint64_t get_millis(void) { return sysctl_get_time_us() / 1000; }
25.95
275
(translation_unit) "#include <stdlib.h>\n#include "esp32_spi_io.h"\n#include "gpiohs.h"\n#include "sleep.h"\n#include "sysctl.h"\n\n#include <utils.h>\n#include "spi.h"\n#include "esp32_spi.h"\n\n#if 1 /* ESP32_SOFT_SPI */\n\n#define GPIOHS_OUT_HIGH(io) (*(volatile uint32_t *)0x3800100CU) |= (1 << (io))\n#define GPIOHS_OUT_LOWX(io) (*(volatile uint32_t *)0x3800100CU) &= ~(1 << (io))\n\n#define GET_GPIOHS_VALX(io) (((*(volatile uint32_t *)0x38001000U) >> (io)) & 1)\n\nuint8_t cs_num = 0, rst_num = 0, rdy_num = 0;\n\nstatic uint8_t _mosi_num = -1;\nstatic uint8_t _miso_num = -1;\nstatic uint8_t _sclk_num = -1;\n\n/* SPI端口初始化 */\n//should check io value\nvoid esp32_spi_config_io(uint8_t cs, uint8_t rst, uint8_t rdy, uint8_t mosi, uint8_t miso, uint8_t sclk)\n{\n //clk\n gpiohs_set_drive_mode(sclk, GPIO_DM_OUTPUT);\n gpiohs_set_pin(sclk, 0);\n //mosi\n gpiohs_set_drive_mode(mosi, GPIO_DM_OUTPUT);\n gpiohs_set_pin(mosi, 0);\n //miso\n gpiohs_set_drive_mode(miso, GPIO_DM_INPUT_PULL_UP);\n\n _mosi_num = mosi;\n _miso_num = miso;\n _sclk_num = sclk;\n\n cs_num = cs;\n rdy_num = rdy;\n rst_num = rst; //if rst <0, use soft reset\n}\n\nuint8_t soft_spi_rw(uint8_t data)\n{\n uint8_t i;\n uint8_t temp = 0;\n for (i = 0; i < 8; i++)\n {\n if (data & 0x80)\n {\n GPIOHS_OUT_HIGH(_mosi_num);\n }\n else\n {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n data <<= 1;\n GPIOHS_OUT_HIGH(_sclk_num);\n\n asm volatile("nop");\n asm volatile("nop");\n asm volatile("nop");\n\n temp <<= 1;\n if (GET_GPIOHS_VALX(_miso_num))\n {\n temp++;\n }\n GPIOHS_OUT_LOWX(_sclk_num);\n\n asm volatile("nop");\n asm volatile("nop");\n asm volatile("nop");\n }\n return temp;\n}\n\nvoid soft_spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(" buffer is null\r\n");\n return;\n }\n\n#if 0\n uint32_t i = 0;\n do\n {\n *(recv + i) = soft_spi_rw(*(send + i));\n i++;\n } while (--len);\n#else\n\n uint32_t i = 0;\n uint8_t *stmp = NULL, sf = 0;\n\n if (send == NULL)\n {\n stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n stmp = send;\n\n if (recv == NULL)\n {\n do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n {\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (sf)\n free(stmp);\n#endif\n}\n\n#else\n\nstatic spi_transfer_width_t sipeed_spi_get_frame_size(size_t data_bit_length)\n{\n if (data_bit_length < 8)\n return SPI_TRANS_CHAR;\n else if (data_bit_length < 16)\n return SPI_TRANS_SHORT;\n return SPI_TRANS_INT;\n}\n\nstatic void sipeed_spi_set_tmod(uint8_t spi_num, uint32_t tmod)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n volatile spi_t *spi_handle = spi[spi_num];\n uint8_t tmod_offset = 0;\n switch (spi_num)\n {\n case 0:\n case 1:\n tmod_offset = 8;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n tmod_offset = 10;\n break;\n }\n set_bit(&spi_handle->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstatic void sipeed_spi_transfer_data_standard(spi_device_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_buff, uint8_t *rx_buff, size_t len)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n configASSERT(len > 0);\n size_t index, fifo_len;\n size_t rx_len = len;\n size_t tx_len = rx_len;\n sipeed_spi_set_tmod(spi_num, SPI_TMOD_TRANS_RECV);\n\n volatile spi_t *spi_handle = spi[spi_num];\n\n uint8_t dfs_offset;\n switch (spi_num)\n {\n case 0:\n case 1:\n dfs_offset = 16;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n dfs_offset = 0;\n break;\n }\n uint32_t data_bit_length = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F;\n spi_transfer_width_t frame_width = sipeed_spi_get_frame_size(data_bit_length);\n spi_handle->ctrlr1 = (uint32_t)(tx_len / frame_width - 1);\n spi_handle->ssienr = 0x01;\n spi_handle->ser = 1U << chip_select;\n uint32_t i = 0;\n while (tx_len)\n {\n fifo_len = 32 - spi_handle->txflr;\n fifo_len = fifo_len < tx_len ? fifo_len : tx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n tx_len -= fifo_len;\n }\n\n while ((spi_handle->sr & 0x05) != 0x04)\n ;\n i = 0;\n while (rx_len)\n {\n fifo_len = spi_handle->rxflr;\n fifo_len = fifo_len < rx_len ? fifo_len : rx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n rx_len -= fifo_len;\n }\n spi_handle->ser = 0x00;\n spi_handle->ssienr = 0x00;\n}\n\n/* SPI端口初始化 */\nvoid soft_spi_init(void)\n{\n printf("hard spi\r\n");\n //cs\n gpiohs_set_drive_mode(ESP32_SPI_CSX_HS_NUM, GPIO_DM_OUTPUT);\n gpiohs_set_pin(ESP32_SPI_CSX_HS_NUM, 1);\n //init SPI_DEVICE_1\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf("set spi clk:%d\r\n", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}\n\nuint8_t soft_spi_rw(uint8_t data)\n{\n uint8_t c;\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nvoid soft_spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(" buffer is null\r\n");\n return;\n }\n\n#if 0\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only send\n if (send && recv == NULL)\n {\n spi_send_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n }\n\n //only recv\n if (send == NULL && recv)\n {\n spi_receive_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n }\n\n //send and recv\n if (send && recv)\n {\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n }\n return;\n}\n\n#endif\n\nuint64_t get_millis(void)\n{\n return sysctl_get_time_us() / 1000;\n}\n" (preproc_include) "#include <stdlib.h>\n" (#include) "#include" (system_lib_string) "<stdlib.h>" (preproc_include) "#include "esp32_spi_io.h"\n" (#include) "#include" (string_literal) ""esp32_spi_io.h"" (") """ (string_content) "esp32_spi_io.h" (") """ (preproc_include) "#include "gpiohs.h"\n" (#include) "#include" (string_literal) ""gpiohs.h"" (") """ (string_content) "gpiohs.h" (") """ (preproc_include) "#include "sleep.h"\n" (#include) "#include" (string_literal) ""sleep.h"" (") """ (string_content) "sleep.h" (") """ (preproc_include) "#include "sysctl.h"\n" (#include) "#include" (string_literal) ""sysctl.h"" (") """ (string_content) "sysctl.h" (") """ (preproc_include) "#include <utils.h>\n" (#include) "#include" (system_lib_string) "<utils.h>" (preproc_include) "#include "spi.h"\n" (#include) "#include" (string_literal) ""spi.h"" (") """ (string_content) "spi.h" (") """ (preproc_include) "#include "esp32_spi.h"\n" (#include) "#include" (string_literal) ""esp32_spi.h"" (") """ (string_content) "esp32_spi.h" (") """ (preproc_if) "#if 1 /* ESP32_SOFT_SPI */\n\n#define GPIOHS_OUT_HIGH(io) (*(volatile uint32_t *)0x3800100CU) |= (1 << (io))\n#define GPIOHS_OUT_LOWX(io) (*(volatile uint32_t *)0x3800100CU) &= ~(1 << (io))\n\n#define GET_GPIOHS_VALX(io) (((*(volatile uint32_t *)0x38001000U) >> (io)) & 1)\n\nuint8_t cs_num = 0, rst_num = 0, rdy_num = 0;\n\nstatic uint8_t _mosi_num = -1;\nstatic uint8_t _miso_num = -1;\nstatic uint8_t _sclk_num = -1;\n\n/* SPI端口初始化 */\n//should check io value\nvoid esp32_spi_config_io(uint8_t cs, uint8_t rst, uint8_t rdy, uint8_t mosi, uint8_t miso, uint8_t sclk)\n{\n //clk\n gpiohs_set_drive_mode(sclk, GPIO_DM_OUTPUT);\n gpiohs_set_pin(sclk, 0);\n //mosi\n gpiohs_set_drive_mode(mosi, GPIO_DM_OUTPUT);\n gpiohs_set_pin(mosi, 0);\n //miso\n gpiohs_set_drive_mode(miso, GPIO_DM_INPUT_PULL_UP);\n\n _mosi_num = mosi;\n _miso_num = miso;\n _sclk_num = sclk;\n\n cs_num = cs;\n rdy_num = rdy;\n rst_num = rst; //if rst <0, use soft reset\n}\n\nuint8_t soft_spi_rw(uint8_t data)\n{\n uint8_t i;\n uint8_t temp = 0;\n for (i = 0; i < 8; i++)\n {\n if (data & 0x80)\n {\n GPIOHS_OUT_HIGH(_mosi_num);\n }\n else\n {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n data <<= 1;\n GPIOHS_OUT_HIGH(_sclk_num);\n\n asm volatile("nop");\n asm volatile("nop");\n asm volatile("nop");\n\n temp <<= 1;\n if (GET_GPIOHS_VALX(_miso_num))\n {\n temp++;\n }\n GPIOHS_OUT_LOWX(_sclk_num);\n\n asm volatile("nop");\n asm volatile("nop");\n asm volatile("nop");\n }\n return temp;\n}\n\nvoid soft_spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(" buffer is null\r\n");\n return;\n }\n\n#if 0\n uint32_t i = 0;\n do\n {\n *(recv + i) = soft_spi_rw(*(send + i));\n i++;\n } while (--len);\n#else\n\n uint32_t i = 0;\n uint8_t *stmp = NULL, sf = 0;\n\n if (send == NULL)\n {\n stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n stmp = send;\n\n if (recv == NULL)\n {\n do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n {\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (sf)\n free(stmp);\n#endif\n}\n\n#else\n\nstatic spi_transfer_width_t sipeed_spi_get_frame_size(size_t data_bit_length)\n{\n if (data_bit_length < 8)\n return SPI_TRANS_CHAR;\n else if (data_bit_length < 16)\n return SPI_TRANS_SHORT;\n return SPI_TRANS_INT;\n}\n\nstatic void sipeed_spi_set_tmod(uint8_t spi_num, uint32_t tmod)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n volatile spi_t *spi_handle = spi[spi_num];\n uint8_t tmod_offset = 0;\n switch (spi_num)\n {\n case 0:\n case 1:\n tmod_offset = 8;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n tmod_offset = 10;\n break;\n }\n set_bit(&spi_handle->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstatic void sipeed_spi_transfer_data_standard(spi_device_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_buff, uint8_t *rx_buff, size_t len)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n configASSERT(len > 0);\n size_t index, fifo_len;\n size_t rx_len = len;\n size_t tx_len = rx_len;\n sipeed_spi_set_tmod(spi_num, SPI_TMOD_TRANS_RECV);\n\n volatile spi_t *spi_handle = spi[spi_num];\n\n uint8_t dfs_offset;\n switch (spi_num)\n {\n case 0:\n case 1:\n dfs_offset = 16;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n dfs_offset = 0;\n break;\n }\n uint32_t data_bit_length = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F;\n spi_transfer_width_t frame_width = sipeed_spi_get_frame_size(data_bit_length);\n spi_handle->ctrlr1 = (uint32_t)(tx_len / frame_width - 1);\n spi_handle->ssienr = 0x01;\n spi_handle->ser = 1U << chip_select;\n uint32_t i = 0;\n while (tx_len)\n {\n fifo_len = 32 - spi_handle->txflr;\n fifo_len = fifo_len < tx_len ? fifo_len : tx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n tx_len -= fifo_len;\n }\n\n while ((spi_handle->sr & 0x05) != 0x04)\n ;\n i = 0;\n while (rx_len)\n {\n fifo_len = spi_handle->rxflr;\n fifo_len = fifo_len < rx_len ? fifo_len : rx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n rx_len -= fifo_len;\n }\n spi_handle->ser = 0x00;\n spi_handle->ssienr = 0x00;\n}\n\n/* SPI端口初始化 */\nvoid soft_spi_init(void)\n{\n printf("hard spi\r\n");\n //cs\n gpiohs_set_drive_mode(ESP32_SPI_CSX_HS_NUM, GPIO_DM_OUTPUT);\n gpiohs_set_pin(ESP32_SPI_CSX_HS_NUM, 1);\n //init SPI_DEVICE_1\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf("set spi clk:%d\r\n", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}\n\nuint8_t soft_spi_rw(uint8_t data)\n{\n uint8_t c;\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nvoid soft_spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(" buffer is null\r\n");\n return;\n }\n\n#if 0\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only send\n if (send && recv == NULL)\n {\n spi_send_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n }\n\n //only recv\n if (send == NULL && recv)\n {\n spi_receive_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n }\n\n //send and recv\n if (send && recv)\n {\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n }\n return;\n}\n\n#endif\n\nuint64_t get_milli" (#if) "#if" (number_literal) "1" (comment) "/* ESP32_SOFT_SPI */" ( ) "\n\n" (preproc_function_def) "#define GPIOHS_OUT_HIGH(io) (*(volatile uint32_t *)0x3800100CU) |= (1 << (io))\n" (#define) "#define" (identifier) "GPIOHS_OUT_HIGH" (preproc_params) "(io)" (() "(" (identifier) "io" ()) ")" (preproc_arg) "(*(volatile uint32_t *)0x3800100CU) |= (1 << (io))" (preproc_function_def) "#define GPIOHS_OUT_LOWX(io) (*(volatile uint32_t *)0x3800100CU) &= ~(1 << (io))\n" (#define) "#define" (identifier) "GPIOHS_OUT_LOWX" (preproc_params) "(io)" (() "(" (identifier) "io" ()) ")" (preproc_arg) "(*(volatile uint32_t *)0x3800100CU) &= ~(1 << (io))" (preproc_function_def) "#define GET_GPIOHS_VALX(io) (((*(volatile uint32_t *)0x38001000U) >> (io)) & 1)\n" (#define) "#define" (identifier) "GET_GPIOHS_VALX" (preproc_params) "(io)" (() "(" (identifier) "io" ()) ")" (preproc_arg) "(((*(volatile uint32_t *)0x38001000U) >> (io)) & 1)" (declaration) "uint8_t cs_num = 0, rst_num = 0, rdy_num = 0;" (primitive_type) "uint8_t" (init_declarator) "cs_num = 0" (identifier) "cs_num" (=) "=" (number_literal) "0" (,) "," (init_declarator) "rst_num = 0" (identifier) "rst_num" (=) "=" (number_literal) "0" (,) "," (init_declarator) "rdy_num = 0" (identifier) "rdy_num" (=) "=" (number_literal) "0" (;) ";" (declaration) "static uint8_t _mosi_num = -1;" (storage_class_specifier) "static" (static) "static" (primitive_type) "uint8_t" (init_declarator) "_mosi_num = -1" (identifier) "_mosi_num" (=) "=" (number_literal) "-1" (;) ";" (declaration) "static uint8_t _miso_num = -1;" (storage_class_specifier) "static" (static) "static" (primitive_type) "uint8_t" (init_declarator) "_miso_num = -1" (identifier) "_miso_num" (=) "=" (number_literal) "-1" (;) ";" (declaration) "static uint8_t _sclk_num = -1;" (storage_class_specifier) "static" (static) "static" (primitive_type) "uint8_t" (init_declarator) "_sclk_num = -1" (identifier) "_sclk_num" (=) "=" (number_literal) "-1" (;) ";" (comment) "/* SPI端口初始化 */\n//should " (comment) "heck io value\nvoid esp3" (function_definition) "_spi_config_io(uint8_t cs, uint8_t rst, uint8_t rdy, uint8_t mosi, uint8_t miso, uint8_t sclk)\n{\n //clk\n gpiohs_set_drive_mode(sclk, GPIO_DM_OUTPUT);\n gpiohs_set_pin(sclk, 0);\n //mosi\n gpiohs_set_drive_mode(mosi, GPIO_DM_OUTPUT);\n gpiohs_set_pin(mosi, 0);\n //miso\n gpiohs_set_drive_mode(miso, GPIO_DM_INPUT_PULL_UP);\n\n _mosi_num = mosi;\n _miso_num = miso;\n _sclk_num = sclk;\n\n cs_num = cs;\n rdy_num = rdy;\n rst_num = rst; //if rst <0, use soft reset\n}\n\nuint8_t " (primitive_type) "_spi" (function_declarator) "config_io(uint8_t cs, uint8_t rst, uint8_t rdy, uint8_t mosi, uint8_t miso, uint8_t sclk)\n{\n //c" (identifier) "config_io(uint8_t c" (parameter_list) "s, uint8_t rst, uint8_t rdy, uint8_t mosi, uint8_t miso, uint8_t sclk)\n{\n //c" (() "s" (parameter_declaration) ", uint8_t " (primitive_type) ", uint8" (identifier) "t " (,) "r" (parameter_declaration) "t, uint8_t " (primitive_type) "t, uint" (identifier) "_t " (,) "r" (parameter_declaration) "y, uint8_t " (primitive_type) "y, uint" (identifier) "_t " (,) "m" (parameter_declaration) "si, uint8_t " (primitive_type) "si, uin" (identifier) "8_t " (,) "m" (parameter_declaration) "so, uint8_t " (primitive_type) "so, uin" (identifier) "8_t " (,) "s" (parameter_declaration) "lk)\n{\n //" (primitive_type) "lk)\n{\n " (identifier) " //" ()) "c" (compound_statement) "k\n gpiohs_set_drive_mode(sclk, GPIO_DM_OUTPUT);\n gpiohs_set_pin(sclk, 0);\n //mosi\n gpiohs_set_drive_mode(mosi, GPIO_DM_OUTPUT);\n gpiohs_set_pin(mosi, 0);\n //miso\n gpiohs_set_drive_mode(miso, GPIO_DM_INPUT_PULL_UP);\n\n _mosi_num = mosi;\n _miso_num = miso;\n _sclk_num = sclk;\n\n cs_num = cs;\n rdy_num = rdy;\n rst_num = rst; //if rst <0, use soft reset\n}\n\nuint8_t " ({) "k" (comment) "gpioh" (expression_statement) "_drive_mode(sclk, GPIO_DM_OUTPUT);\n gpioh" (call_expression) "_drive_mode(sclk, GPIO_DM_OUTPUT);\n gpio" (identifier) "_drive_mode(sclk, GPI" (argument_list) "O_DM_OUTPUT);\n gpio" (() "O" (identifier) "_DM_" (,) "O" (identifier) "TPUT);\n gpi" ()) "o" (;) "h" (expression_statement) "_pin(sclk, 0);\n //mos" (call_expression) "_pin(sclk, 0);\n //mo" (identifier) "_pin(sclk, 0);" (argument_list) "\n //mo" (() "\n" (identifier) " " (,) "/" (number_literal) "m" ()) "o" (;) "s" (comment) " gpioh" (expression_statement) "_drive_mode(mosi, GPIO_DM_OUTPUT);\n gpioh" (call_expression) "_drive_mode(mosi, GPIO_DM_OUTPUT);\n gpio" (identifier) "_drive_mode(mosi, GPI" (argument_list) "O_DM_OUTPUT);\n gpio" (() "O" (identifier) "_DM_" (,) "O" (identifier) "TPUT);\n gpi" ()) "o" (;) "h" (expression_statement) "_pin(mosi, 0);\n //mis" (call_expression) "_pin(mosi, 0);\n //mi" (identifier) "_pin(mosi, 0);" (argument_list) "\n //mi" (() "\n" (identifier) " " (,) "/" (number_literal) "m" ()) "i" (;) "s" (comment) " gpioh" (expression_statement) "_drive_mode(miso, GPIO_DM_INPUT_PULL_UP);\n\n _mos" (call_expression) "_drive_mode(miso, GPIO_DM_INPUT_PULL_UP);\n\n _mo" (identifier) "_drive_mode(miso, GPI" (argument_list) "O_DM_INPUT_PULL_UP);\n\n _mo" (() "O" (identifier) "_DM_" (,) "I" (identifier) "PUT_PULL_UP);\n\n _m" ()) "o" (;) "s" (expression_statement) "= mosi;\n _miso" (assignment_expression) "= mosi;\n _mis" (identifier) "= mosi;\n " (=) " " (identifier) "_mis" (;) "o" (expression_statement) "= miso;\n _sclk" (assignment_expression) "= miso;\n _scl" (identifier) "= miso;\n " (=) " " (identifier) "_scl" (;) "k" (expression_statement) "= sclk;\n\n cs_n" (assignment_expression) "= sclk;\n\n cs_" (identifier) "= sclk;\n\n" (=) " " (identifier) " cs_" (;) "n" (expression_statement) "s;\n rdy_n" (assignment_expression) "s;\n rdy_" (identifier) "s;\n " (=) "r" (identifier) "y_" (;) "n" (expression_statement) "rdy;\n rst_n" (assignment_expression) "rdy;\n rst_" (identifier) "rdy;\n " (=) " " (identifier) "st_" (;) "n" (expression_statement) "rst; //if rst " (assignment_expression) "rst; //if rst" (identifier) "rst; //" (=) "f" (identifier) "rst" (;) " " (comment) "0, use soft reset\n}\n\nuint8_" (}) " " (function_definition) "ft_spi_rw(uint8_t data)\n{\n uint8_t i;\n uint8_t temp = 0;\n for (i = 0; i < 8; i++)\n {\n if (data & 0x80)\n {\n GPIOHS_OUT_HIGH(_mosi_num);\n }\n else\n {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n data <<= 1;\n GPIOHS_OUT_HIGH(_sclk_num);\n\n asm volatile("nop");\n asm volatile("nop");\n asm volatile("nop");\n\n temp <<= 1;\n if (GET_GPIOHS_VALX(_miso_num))\n {\n temp++;\n }\n GPIOHS_OUT_LOWX(_sclk_num);\n\n asm volatile("nop");\n asm volatile("nop");\n asm volatile("nop");\n }\n return temp;\n}\n\nvoid sof" (primitive_type) "ft_spi_" (function_declarator) "w(uint8_t data)\n{\n uin" (identifier) "w(uint8_t d" (parameter_list) "ata)\n{\n uin" (() "a" (parameter_declaration) "ta)\n{\n ui" (primitive_type) "ta)\n{\n " (identifier) " ui" ()) "n" (compound_statement) "8_t i;\n uint8_t temp = 0;\n for (i = 0; i < 8; i++)\n {\n if (data & 0x80)\n {\n GPIOHS_OUT_HIGH(_mosi_num);\n }\n else\n {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n data <<= 1;\n GPIOHS_OUT_HIGH(_sclk_num);\n\n asm volatile("nop");\n asm volatile("nop");\n asm volatile("nop");\n\n temp <<= 1;\n if (GET_GPIOHS_VALX(_miso_num))\n {\n temp++;\n }\n GPIOHS_OUT_LOWX(_sclk_num);\n\n asm volatile("nop");\n asm volatile("nop");\n asm volatile("nop");\n }\n return temp;\n}\n\nvoid sof" ({) "8" (declaration) "\n uint8" (primitive_type) "\n ui" (identifier) "t" (;) "8" (declaration) "mp = 0;\n for (" (primitive_type) "mp = 0;" (init_declarator) " for " (identifier) " " (=) "o" (number_literal) " " (;) "(" (for_statement) "; i < 8; i++)\n {\n if (data & 0x80)\n {\n GPIOHS_OUT_HIGH(_mosi_num);\n }\n else\n {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n data <<= 1;\n GPIOHS_OUT_HIGH(_sclk_num);\n\n asm volatile("nop");\n asm volatile("nop");\n asm volatile("nop");\n\n temp <<= 1;\n if (GET_GPIOHS_VALX(_miso_num))\n {\n temp++;\n }\n GPIOHS_OUT_LOWX(_sclk_num);\n\n asm volatile("nop");\n asm volatile("nop");\n asm volatile("nop");\n }\n retur" (for) "; i" (() "<" (assignment_expression) " 8; i" (identifier) " " (=) ";" (number_literal) "i" (;) "+" (binary_expression) ")\n " (identifier) ")" (<) " " (number_literal) " " (;) " " (update_expression) "\n " (identifier) "\n" (++) " " ()) " " (compound_statement) "if (data & 0x80)\n {\n GPIOHS_OUT_HIGH(_mosi_num);\n }\n else\n {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n data <<= 1;\n GPIOHS_OUT_HIGH(_sclk_num);\n\n asm volatile("nop");\n asm volatile("nop");\n asm volatile("nop");\n\n temp <<= 1;\n if (GET_GPIOHS_VALX(_miso_num))\n {\n temp++;\n }\n GPIOHS_OUT_LOWX(_sclk_num);\n\n asm volatile("nop");\n asm volatile("nop");\n asm volatile("nop");\n }\n retur" ({) "i" (if_statement) " 0x80)\n {\n GPIOHS_OUT_HIGH(_mosi_num);\n }\n else\n {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n d" (if) " 0" (parenthesized_expression) "80)\n {" (() "8" (binary_expression) "0)\n " (identifier) "0)\n " (&) " " (number_literal) " " ()) "{" (compound_statement) " GPIOHS_OUT_HIGH(_mosi_num);\n }\n e" ({) " " (expression_statement) "_HIGH(_mosi_num);\n }" (call_expression) "_HIGH(_mosi_num);\n " (identifier) "_HIGH(_mosi_num" (argument_list) ");\n " (() ")" (identifier) ";\n " ()) " " (;) "}" (}) "e" (else_clause) " {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n d" (else) " {" (compound_statement) " GPIOHS_OUT_LOWX(_mosi_num);\n }\n d" ({) " " (expression_statement) "_LOWX(_mosi_num);\n }" (call_expression) "_LOWX(_mosi_num);\n " (identifier) "_LOWX(_mosi_num" (argument_list) ");\n " (() ")" (identifier) ";\n " ()) " " (;) "}" (}) "d" (expression_statement) ";\n G" (assignment_expression) ";\n " (identifier) ";\n " (<<=) " " (number_literal) " " (;) "G" (expression_statement) "_HIGH(_sclk_num);\n\n " (call_expression) "_HIGH(_sclk_num);\n\n " (identifier) "_HIGH(_sclk_num" (argument_list) ");\n\n " (() ")" (identifier) ";\n\n " ()) " " (;) " " (expression_statement) "le("nop");\n a" (gnu_asm_expression) "le("nop");\n " (asm) "le(" (gnu_asm_qualifier) "nop");\n " (volatile) "nop");\n " (() " " (string_literal) " " (") " " (string_content) " " (") " " ()) " " (;) "a" (expression_statement) "le("nop");\n a" (gnu_asm_expression) "le("nop");\n " (asm) "le(" (gnu_asm_qualifier) "nop");\n " (volatile) "nop");\n " (() " " (string_literal) " " (") " " (string_content) " " (") " " ()) " " (;) "a" (expression_statement) "le("nop");\n\n " (gnu_asm_expression) "le("nop");\n\n " (asm) "le(" (gnu_asm_qualifier) "nop");\n\n" (volatile) "nop");\n\n" (() " " (string_literal) " " (") " " (string_content) " " (") " " ()) " " (;) " " (expression_statement) ";\n i" (assignment_expression) ";\n " (identifier) ";\n " (<<=) " " (number_literal) " " (;) "i" (if_statement) "IOHS_VALX(_miso_num))\n {\n temp++;\n }\n G" (if) "IO" (parenthesized_expression) "S_VALX(_miso_num))\n {" (() "S" (call_expression) "_VALX(_miso_num))\n " (identifier) "_VALX(_miso_num" (argument_list) "))\n " (() ")" (identifier) ")\n " ()) " " ()) "{" (compound_statement) " temp++;\n }\n G" ({) " " (expression_statement) " }" (update_expression) " " (identifier) " " (++) " " (;) "}" (}) "G" (expression_statement) "_LOWX(_sclk_num);\n\n " (call_expression) "_LOWX(_sclk_num);\n\n " (identifier) "_LOWX(_sclk_num" (argument_list) ");\n\n " (() ")" (identifier) ";\n\n " ()) " " (;) " " (expression_statement) "le("nop");\n a" (gnu_asm_expression) "le("nop");\n " (asm) "le(" (gnu_asm_qualifier) "nop");\n " (volatile) "nop");\n " (() " " (string_literal) " " (") " " (string_content) " " (") " " ()) " " (;) "a" (expression_statement) "le("nop");\n a" (gnu_asm_expression) "le("nop");\n " (asm) "le(" (gnu_asm_qualifier) "nop");\n " (volatile) "nop");\n " (() " " (string_literal) " " (") " " (string_content) " " (") " " ()) " " (;) "a" (expression_statement) "le("nop");\n }\n " (gnu_asm_expression) "le("nop");\n }\n " (asm) "le(" (gnu_asm_qualifier) "nop");\n " (volatile) "nop");\n " (() " " (string_literal) " }\n " (") " " (string_content) " }\n" (") " " ()) " " (;) " " (}) "r" (return_statement) "p;\n}\n\nvoid s" (return) "p;\n}\n\n" (identifier) "oid " (;) "s" (}) "f" (function_definition) "spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(" buffer is null\r\n");\n return;\n }\n\n#if 0\n uint32_t i = 0;\n do\n {\n *(recv + i) = soft_spi_rw(*(send + i));\n i++;\n } while (--len);\n#else\n\n uint32_t i = 0;\n uint8_t *stmp = NULL, sf = 0;\n\n if (send == NULL)\n {\n stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n stmp = send;\n\n if (recv == NULL)\n {\n do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n {\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (sf)\n free(stmp);\n#endif\n}\n\n#else\n\ns" (primitive_type) "spi_" (function_declarator) "w_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if " (identifier) "w_len(uint8_t *" (parameter_list) "send, uint8_t *recv, uint32_t len)\n{\n if " (() "s" (parameter_declaration) "end, uint8_t " (primitive_type) "end, ui" (pointer_declarator) "t8_t " (*) "t" (identifier) "8_t " (,) "*" (parameter_declaration) "ecv, uint32_t" (primitive_type) "ecv, ui" (pointer_declarator) "t32_t" (*) "t" (identifier) "32_t" (,) " " (parameter_declaration) "en)\n{\n if" (primitive_type) "en)\n{\n " (identifier) " if" ()) " " (compound_statement) "send == NULL && recv == NULL)\n {\n printf(" buffer is null\r\n");\n return;\n }\n\n#if 0\n uint32_t i = 0;\n do\n {\n *(recv + i) = soft_spi_rw(*(send + i));\n i++;\n } while (--len);\n#else\n\n uint32_t i = 0;\n uint8_t *stmp = NULL, sf = 0;\n\n if (send == NULL)\n {\n stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n stmp = send;\n\n if (recv == NULL)\n {\n do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n {\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (sf)\n free(stmp);\n#endif\n}\n\n#else\n\ns" ({) "s" (if_statement) "= NULL && recv == NULL)\n {\n printf(" buffer is null\r\n");\n return;\n }\n\n#if 0\n " (if) "= " (parenthesized_expression) "ULL && recv == NULL)\n {\n " (() "U" (binary_expression) "LL && recv == NULL)\n {\n " (binary_expression) "LL && recv =" (identifier) "LL &" (==) " r" (null) "cv =" (NULL) "cv =" (&&) " N" (binary_expression) "LL)\n {\n " (identifier) "LL)\n" (==) " " (null) "{\n " (NULL) "{\n " ()) " " (compound_statement) "printf(" buffer is null\r\n");\n return;\n }\n\n#if 0\n " ({) "p" (expression_statement) "uffer is null\r\n");\n r" (call_expression) "uffer is null\r\n");\n " (identifier) "uffer " (argument_list) "is null\r\n");\n " (() "i" (string_literal) "s null\r\n");\n " (") "s" (string_content) " null\r\n");\n " (escape_sequence) " " (escape_sequence) " " (") " " ()) " " (;) "r" (return_statement) " }\n\n#i" (return) " }\n\n#" (;) "i" (}) " " (preproc_if) "uint32_t i = 0;\n do\n {\n *(recv + i) = soft_spi_rw(*(send + i));\n i++;\n } while (--len);\n#else\n\n uint32_t i = 0;\n uint8_t *stmp = NULL, sf = 0;\n\n if (send == NULL)\n {\n stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n stmp = send;\n\n if (recv == NULL)\n {\n do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n {\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (sf)\n free(stmp);\n#endif\n}\n\n#else\n" (#if) "uin" (number_literal) "3" ( ) "2" (declaration) " = 0;\n do\n " (primitive_type) " = 0;\n " (init_declarator) " do\n " (identifier) " " (=) "o" (number_literal) " " (;) " " (do_statement) " *(recv + i) = soft_spi_rw(*(send + i));\n i++;\n } while (--len);\n#else\n\n " (do) " " (compound_statement) "*(recv + i) = soft_spi_rw(*(send + i));\n i++;\n } while (--" ({) "*" (expression_statement) ") = soft_spi_rw(*(send + i));\n i" (assignment_expression) ") = soft_spi_rw(*(send + i));\n " (pointer_expression) ") = soft_sp" (*) ")" (parenthesized_expression) " = soft_sp" (() " " (binary_expression) "= soft_s" (identifier) "= so" (+) "t" (identifier) "s" ()) "p" (=) "_" (call_expression) "w(*(send + i));\n " (identifier) "w(*(send + " (argument_list) "i));\n " (() "i" (pointer_expression) "));\n " (*) ")" (parenthesized_expression) ");\n " (() ")" (binary_expression) ";\n " (identifier) ";\n " (+) " " (identifier) " " ()) " " ()) " " (;) "i" (expression_statement) " whi" (update_expression) " wh" (identifier) " " (++) "wh" (;) "i" (}) "-" (while) "en);\n" (parenthesized_expression) "else\n\n " (() "e" (update_expression) "lse\n\n" (--) "ls" (identifier) "e\n\n" ()) " " (;) " " (preproc_else) " uint32_t i = 0;\n uint8_t *stmp = NULL, sf = 0;\n\n if (send == NULL)\n {\n stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n stmp = send;\n\n if (recv == NULL)\n {\n do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n {\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (sf)\n free(stmp);\n#endif\n}\n" (#else) " uint" (declaration) " = 0;\n uint8" (primitive_type) " = 0;\n " (init_declarator) " uint" (identifier) " " (=) "i" (number_literal) "t" (;) "8" (declaration) "tmp = NULL, sf = 0;\n\n if (" (primitive_type) "tmp = N" (init_declarator) "LL, sf = 0;\n" (pointer_declarator) "LL, s" (*) "L" (identifier) "L, s" (=) " " (null) " 0;\n" (NULL) " 0;\n" (,) "\n" (init_declarator) " if " (identifier) " " (=) "i" (number_literal) " " (;) "(" (if_statement) "= NULL)\n {\n stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n stmp = send;\n\n if (" (if) "= " (parenthesized_expression) "ULL)\n {\n " (() "U" (binary_expression) "LL)\n {\n " (identifier) "LL)\n" (==) " " (null) "{\n " (NULL) "{\n " ()) " " (compound_statement) "stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n" ({) "s" (expression_statement) "nt8_t *)malloc(len * sizeof(uint8_t));\n /" (assignment_expression) "nt8_t *)malloc(len * sizeof(uint8_t));\n " (identifier) "nt8_" (=) " " (cast_expression) ")malloc(len * sizeof(uint8_t));\n " (() ")" (type_descriptor) "malloc(le" (primitive_type) "malloc(" (abstract_pointer_declarator) "e" (*) "e" ()) "n" (call_expression) " * sizeof(uint8_t));\n " (identifier) " * siz" (argument_list) "eof(uint8_t));\n " (() "e" (binary_expression) "of(uint8_t));\n " (identifier) "of(" (*) "i" (sizeof_expression) "t8_t));\n " (sizeof) "t8_t))" (() ";" (type_descriptor) "\n " (primitive_type) "\n " ()) " " ()) " " (;) "/" (comment) "stmp, 'A', len);\n s" (expression_statement) " }\n " (assignment_expression) " }\n " (identifier) " " (=) "\n" (number_literal) " " (;) " " (}) "\n" (else_clause) " stmp = send;\n\n if (" (else) " s" (expression_statement) "d;\n\n if (" (assignment_expression) "d;\n\n if " (identifier) "d;\n\n" (=) " " (identifier) " if " (;) "(" (if_statement) "= NULL)\n {\n do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n {\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (" (if) "= " (parenthesized_expression) "ULL)\n {\n " (() "U" (binary_expression) "LL)\n {\n " (identifier) "LL)\n" (==) " " (null) "{\n " (NULL) "{\n " ()) " " (compound_statement) "do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n" ({) "d" (do_statement) " {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n " (do) " {" (compound_statement) " soft_spi_rw(*(stmp + i));\n i++;\n } while (--" ({) " " (expression_statement) "w(*(stmp + i));\n " (call_expression) "w(*(stmp + i));\n " (identifier) "w(*(stmp + " (argument_list) "i));\n " (() "i" (pointer_expression) "));\n " (*) ")" (parenthesized_expression) ");\n " (() ")" (binary_expression) ";\n " (identifier) ";\n " (+) " " (identifier) " " ()) " " ()) " " (;) " " (expression_statement) " }" (update_expression) " " (identifier) " " (++) " " (;) "}" (}) "-" (while) "en);\n" (parenthesized_expression) " }\n " (() " " (update_expression) " }\n " (--) " " (identifier) "}\n " ()) " " (;) " " (}) "\n" (else_clause) "\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (" (else) "\n " (compound_statement) "do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (" ({) "d" (do_statement) " {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n " (do) " {" (compound_statement) " *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--" ({) " " (expression_statement) ") = soft_spi_rw(*(stmp + i));\n " (assignment_expression) ") = soft_spi_rw(*(stmp + i));\n " (pointer_expression) ") = soft_sp" (*) ")" (parenthesized_expression) " = soft_sp" (() " " (binary_expression) "= soft_s" (identifier) "= so" (+) "t" (identifier) "s" ()) "p" (=) "_" (call_expression) "w(*(stmp + i));\n " (identifier) "w(*(stmp + " (argument_list) "i));\n " (() "i" (pointer_expression) "));\n " (*) ")" (parenthesized_expression) ");\n " (() ")" (binary_expression) ";\n " (identifier) ";\n " (+) " " (identifier) " " ()) " " ()) " " (;) " " (expression_statement) " }" (update_expression) " " (identifier) " " (++) " " (;) "}" (}) "-" (while) "en);\n" (parenthesized_expression) " }\n\n " (() " " (update_expression) " }\n\n" (--) " " (identifier) "}\n\n" ()) " " (;) " " (}) "(" (if_statement) " free(stmp);\n#endif\n}\n" (if) " " (parenthesized_expression) " f" (() " " (identifier) " " ()) "f" (expression_statement) ";\n#endif\n}\n" (call_expression) ";\n#endif\n}" (identifier) ";\n#e" (argument_list) "ndif\n}" (() "n" (identifier) "dif\n" ()) "}" (;) "\n" (#endif) "#else\n" (}) "s" (preproc_else) "tic spi_transfer_width_t sipeed_spi_get_frame_size(size_t data_bit_length)\n{\n if (data_bit_length < 8)\n return SPI_TRANS_CHAR;\n else if (data_bit_length < 16)\n return SPI_TRANS_SHORT;\n return SPI_TRANS_INT;\n}\n\nstatic void sipeed_spi_set_tmod(uint8_t spi_num, uint32_t tmod)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n volatile spi_t *spi_handle = spi[spi_num];\n uint8_t tmod_offset = 0;\n switch (spi_num)\n {\n case 0:\n case 1:\n tmod_offset = 8;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n tmod_offset = 10;\n break;\n }\n set_bit(&spi_handle->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstatic void sipeed_spi_transfer_data_standard(spi_device_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_buff, uint8_t *rx_buff, size_t len)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n configASSERT(len > 0);\n size_t index, fifo_len;\n size_t rx_len = len;\n size_t tx_len = rx_len;\n sipeed_spi_set_tmod(spi_num, SPI_TMOD_TRANS_RECV);\n\n volatile spi_t *spi_handle = spi[spi_num];\n\n uint8_t dfs_offset;\n switch (spi_num)\n {\n case 0:\n case 1:\n dfs_offset = 16;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n dfs_offset = 0;\n break;\n }\n uint32_t data_bit_length = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F;\n spi_transfer_width_t frame_width = sipeed_spi_get_frame_size(data_bit_length);\n spi_handle->ctrlr1 = (uint32_t)(tx_len / frame_width - 1);\n spi_handle->ssienr = 0x01;\n spi_handle->ser = 1U << chip_select;\n uint32_t i = 0;\n while (tx_len)\n {\n fifo_len = 32 - spi_handle->txflr;\n fifo_len = fifo_len < tx_len ? fifo_len : tx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n tx_len -= fifo_len;\n }\n\n while ((spi_handle->sr & 0x05) != 0x04)\n ;\n i = 0;\n while (rx_len)\n {\n fifo_len = spi_handle->rxflr;\n fifo_len = fifo_len < rx_len ? fifo_len : rx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n rx_len -= fifo_len;\n }\n spi_handle->ser = 0x00;\n spi_handle->ssienr = 0x00;\n}\n\n/* SPI端口初始化 */\nvoid soft_spi_init(void)\n{\n printf("hard spi\r\n");\n //cs\n gpiohs_set_drive_mode(ESP32_SPI_CSX_HS_NUM, GPIO_DM_OUTPUT);\n gpiohs_set_pin(ESP32_SPI_CSX_HS_NUM, 1);\n //init SPI_DEVICE_1\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf("set spi clk:%d\r\n", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}\n\nuint8_t soft_spi_rw(uint8_t data)\n{\n uint8_t c;\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nvoid soft_spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(" buffer is null\r\n");\n return;\n }\n\n#if 0\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only send\n if (send && recv == NULL)\n {\n spi_send_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n }\n\n //only recv\n if (send == NULL && recv)\n {\n spi_receive_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n }\n\n //send and recv\n if (send && recv)\n {\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n }\n return;\n}\n\n#endif\n\nuint64_t g" (#else) "tic s" (function_definition) "_transfer_width_t sipeed_spi_get_frame_size(size_t data_bit_length)\n{\n if (data_bit_length < 8)\n return SPI_TRANS_CHAR;\n else if (data_bit_length < 16)\n return SPI_TRANS_SHORT;\n return SPI_TRANS_INT;\n}\n\nstatic v" (storage_class_specifier) "_trans" (static) "_trans" (type_identifier) "er_width_t sipeed_sp" (function_declarator) "_get_frame_size(size_t data_bit_length)\n{\n if " (identifier) "_get_frame_size(size_t da" (parameter_list) "ta_bit_length)\n{\n if " (() "t" (parameter_declaration) "a_bit_length)\n{\n if" (primitive_type) "a_bit_" (identifier) "ength)\n{\n if" ()) " " (compound_statement) "data_bit_length < 8)\n return SPI_TRANS_CHAR;\n else if (data_bit_length < 16)\n return SPI_TRANS_SHORT;\n return SPI_TRANS_INT;\n}\n\nstatic v" ({) "d" (if_statement) "it_length < 8)\n return SPI_TRANS_CHAR;\n else if (data_bit_length < 16)\n return SPI_TRANS_SHORT;\n retur" (if) "it" (parenthesized_expression) "length < 8)\n r" (() "l" (binary_expression) "ength < 8)\n " (identifier) "ength < 8)\n " (<) " " (number_literal) " " ()) "r" (return_statement) "_TRANS_CHAR;\n else " (return) "_TRANS" (identifier) "CHAR;\n else" (;) " " (else_clause) "ata_bit_length < 16)\n return SPI_TRANS_SHORT;\n retur" (else) "ata_" (if_statement) "it_length < 16)\n return SPI_TRANS_SHORT;\n retur" (if) "it" (parenthesized_expression) "length < 16)\n r" (() "l" (binary_expression) "ength < 16)\n " (identifier) "ength < 16)\n " (<) " " (number_literal) " " ()) "r" (return_statement) "_TRANS_SHORT;\n retur" (return) "_TRANS" (identifier) "SHORT;\n retu" (;) "r" (return_statement) "_TRANS_INT;\n}\n\nstatic" (return) "_TRANS" (identifier) "INT;\n}\n\nstati" (;) "c" (}) "v" (function_definition) "d sipeed_spi_set_tmod(uint8_t spi_num, uint32_t tmod)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n volatile spi_t *spi_handle = spi[spi_num];\n uint8_t tmod_offset = 0;\n switch (spi_num)\n {\n case 0:\n case 1:\n tmod_offset = 8;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n tmod_offset = 10;\n break;\n }\n set_bit(&spi_handle->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstatic v" (storage_class_specifier) "d sipe" (static) "d sipe" (primitive_type) "d_sp" (function_declarator) "_set_tmod(uint8_t spi_num, uint32_t tmod)\n{\n con" (identifier) "_set_tmod(uint8_t s" (parameter_list) "pi_num, uint32_t tmod)\n{\n con" (() "p" (parameter_declaration) "i_num, uint32_t" (primitive_type) "i_num, " (identifier) "int32_t" (,) " " (parameter_declaration) "mod)\n{\n co" (primitive_type) "mod)\n{\n " (identifier) " co" ()) "n" (compound_statement) "igASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n volatile spi_t *spi_handle = spi[spi_num];\n uint8_t tmod_offset = 0;\n switch (spi_num)\n {\n case 0:\n case 1:\n tmod_offset = 8;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n tmod_offset = 10;\n break;\n }\n set_bit(&spi_handle->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstatic v" ({) "i" (expression_statement) "RT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n volat" (call_expression) "RT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n vola" (identifier) "RT(spi_num <" (argument_list) " SPI_DEVICE_MAX && spi_num != 2);\n vola" (() " " (binary_expression) "SPI_DEVICE_MAX && spi_num != 2);\n vol" (binary_expression) "SPI_DEVICE_MAX && spi_nu" (identifier) "SPI_DEV" (<) "C" (identifier) "_MAX && spi_nu" (&&) " !" (binary_expression) " 2);\n vol" (identifier) " 2);\n " (!=) " v" (number_literal) "l" ()) "a" (;) "t" (declaration) "pi_t *spi_handle = spi[spi_num];\n uint8" (type_qualifier) "pi_t *sp" (volatile) "pi_t *sp" (type_identifier) "_hand" (init_declarator) "e = spi[spi_num];\n uint" (pointer_declarator) "e = spi[spi" (*) "e" (identifier) " = spi[spi" (=) "n" (subscript_expression) "m];\n uint" (identifier) "m];" ([) "\n" (identifier) " uin" (]) "t" (;) "8" (declaration) "od_offset = 0;\n switc" (primitive_type) "od_offs" (init_declarator) "t = 0;\n swit" (identifier) "t = 0;\n " (=) "w" (number_literal) "t" (;) "c" (switch_statement) "i_num)\n {\n case 0:\n case 1:\n tmod_offset = 8;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n tmod_offset = 10;\n break;\n }\n set_b" (switch) "i_num)" (parenthesized_expression) " {\n " (() " " (identifier) " {\n " ()) " " (compound_statement) " 0:\n case 1:\n tmod_offset = 8;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n tmod_offset = 10;\n break;\n }\n set_b" ({) " " (case_statement) " case " (case) " ca" (number_literal) "e" (:) " " (case_statement) " tmod_offset = 8;\n break;\n case " (case) " " (number_literal) " " (:) "t" (expression_statement) "t = 8;\n b" (assignment_expression) "t = 8;\n " (identifier) "t = 8;\n " (=) " " (number_literal) " " (;) "b" (break_statement) " case " (break) " case" (;) " " (case_statement) " configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case " (case) " " (number_literal) " " (:) "c" (expression_statement) "RT(!"Spi Bus 2 Not Support!");\n b" (call_expression) "RT(!"Spi Bus 2 Not Support!");\n " (identifier) "RT(!"Spi Bus" (argument_list) " 2 Not Support!");\n " (() " " (unary_expression) "2 Not Support!");\n " (!) "2" (string_literal) " Not Support!");\n " (") " " (string_content) "Not Support!");\n " (") " " ()) " " (;) "b" (break_statement) " case " (break) " case" (;) " " (case_statement) " defau" (case) " de" (number_literal) "a" (:) "u" (case_statement) " tmod_offset = 10;\n break;\n }\n " (default) " " (:) "t" (expression_statement) "t = 10;\n b" (assignment_expression) "t = 10;\n " (identifier) "t = 10;\n " (=) " " (number_literal) " " (;) "b" (break_statement) " }\n " (break) " }\n " (;) " " (}) "b" (expression_statement) "pi_handle->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstatic" (call_expression) "pi_handle->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstati" (identifier) "pi_hand" (argument_list) "le->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstati" (() "l" (pointer_expression) "e->ctrlr0, 3 << tmo" (&) "e" (field_expression) "->ctrlr0, 3 << tmo" (identifier) "->ctrlr0, " (->) "3 " (field_identifier) "<< tmo" (,) "d" (binary_expression) "offset, tmod << " (number_literal) "o" (<<) "fs" (identifier) "t, tmod << " (,) "t" (binary_expression) "od_offset);\n}\n\nstat" (identifier) "od_o" (<<) "fs" (identifier) "t);\n}\n\nstat" ()) "i" (;) "c" (}) "v" (function_definition) "d sipeed_spi_transfer_data_standard(spi_device_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_buff, uint8_t *rx_buff, size_t len)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n configASSERT(len > 0);\n size_t index, fifo_len;\n size_t rx_len = len;\n size_t tx_len = rx_len;\n sipeed_spi_set_tmod(spi_num, SPI_TMOD_TRANS_RECV);\n\n volatile spi_t *spi_handle = spi[spi_num];\n\n uint8_t dfs_offset;\n switch (spi_num)\n {\n case 0:\n case 1:\n dfs_offset = 16;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n dfs_offset = 0;\n break;\n }\n uint32_t data_bit_length = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F;\n spi_transfer_width_t frame_width = sipeed_spi_get_frame_size(data_bit_length);\n spi_handle->ctrlr1 = (uint32_t)(tx_len / frame_width - 1);\n spi_handle->ssienr = 0x01;\n spi_handle->ser = 1U << chip_select;\n uint32_t i = 0;\n while (tx_len)\n {\n fifo_len = 32 - spi_handle->txflr;\n fifo_len = fifo_len < tx_len ? fifo_len : tx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n tx_len -= fifo_len;\n }\n\n while ((spi_handle->sr & 0x05) != 0x04)\n ;\n i = 0;\n while (rx_len)\n {\n fifo_len = spi_handle->rxflr;\n fifo_len = fifo_len < rx_len ? fifo_len : rx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n rx_len -= fifo_len;\n }\n spi_handle->ser = 0x00;\n spi_handle->ssienr = 0x00;\n}\n\n/* SPI端口" (storage_class_specifier) "d sipe" (static) "d sipe" (primitive_type) "d_sp" (function_declarator) "_transfer_data_standard(spi_device_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_buff, uint8_t *rx_buff, size_t len)\n{\n con" (identifier) "_transfer_data_standard(spi_devic" (parameter_list) "e_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_buff, uint8_t *rx_buff, size_t len)\n{\n con" (() "e" (parameter_declaration) "_num_t spi_num, spi_chip" (type_identifier) "_num_t spi_num, " (identifier) "pi_chip" (,) "_" (parameter_declaration) "elect_t chip_select, const ui" (type_identifier) "elect_t chip_sele" (identifier) "t, const ui" (,) "n" (parameter_declaration) "8_t *tx_buff, uint8_t " (type_qualifier) "8_t *" (const) "8_t *" (primitive_type) "x_buff," (pointer_declarator) "uint8_t " (*) "u" (identifier) "int8_t " (,) "*" (parameter_declaration) "x_buff, size_t l" (primitive_type) "x_buff," (pointer_declarator) "size_t l" (*) "s" (identifier) "ize_t l" (,) "e" (parameter_declaration) ")\n{\n co" (primitive_type) ")\n{\n " (identifier) " co" ()) "n" (compound_statement) "igASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n configASSERT(len > 0);\n size_t index, fifo_len;\n size_t rx_len = len;\n size_t tx_len = rx_len;\n sipeed_spi_set_tmod(spi_num, SPI_TMOD_TRANS_RECV);\n\n volatile spi_t *spi_handle = spi[spi_num];\n\n uint8_t dfs_offset;\n switch (spi_num)\n {\n case 0:\n case 1:\n dfs_offset = 16;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n dfs_offset = 0;\n break;\n }\n uint32_t data_bit_length = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F;\n spi_transfer_width_t frame_width = sipeed_spi_get_frame_size(data_bit_length);\n spi_handle->ctrlr1 = (uint32_t)(tx_len / frame_width - 1);\n spi_handle->ssienr = 0x01;\n spi_handle->ser = 1U << chip_select;\n uint32_t i = 0;\n while (tx_len)\n {\n fifo_len = 32 - spi_handle->txflr;\n fifo_len = fifo_len < tx_len ? fifo_len : tx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n tx_len -= fifo_len;\n }\n\n while ((spi_handle->sr & 0x05) != 0x04)\n ;\n i = 0;\n while (rx_len)\n {\n fifo_len = spi_handle->rxflr;\n fifo_len = fifo_len < rx_len ? fifo_len : rx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n rx_len -= fifo_len;\n }\n spi_handle->ser = 0x00;\n spi_handle->ssienr = 0x00;\n}\n\n/* SPI端口" ({) "i" (expression_statement) "RT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n confi" (call_expression) "RT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n conf" (identifier) "RT(spi_num <" (argument_list) " SPI_DEVICE_MAX && spi_num != 2);\n conf" (() " " (binary_expression) "SPI_DEVICE_MAX && spi_num != 2);\n con" (binary_expression) "SPI_DEVICE_MAX && spi_nu" (identifier) "SPI_DEV" (<) "C" (identifier) "_MAX && spi_nu" (&&) " !" (binary_expression) " 2);\n con" (identifier) " 2);\n " (!=) " c" (number_literal) "n" ()) "f" (;) "i" (expression_statement) "RT(len > 0);\n size_" (call_expression) "RT(len > 0);\n size" (identifier) "RT(len > 0);" (argument_list) "\n size" (() "\n" (binary_expression) " siz" (identifier) " " (>) "s" (number_literal) "z" ()) "e" (;) "_" (declaration) "ex, fifo_len;\n size_" (primitive_type) "ex, fi" (identifier) "o_len" (,) ";" (identifier) " size" (;) "_" (declaration) "len = len;\n size_" (primitive_type) "len = " (init_declarator) "en;\n size" (identifier) "en;\n " (=) " " (identifier) "ize" (;) "_" (declaration) "len = rx_len;\n sipee" (primitive_type) "len = " (init_declarator) "x_len;\n sipe" (identifier) "x_len;" (=) " " (identifier) " sipe" (;) "e" (expression_statement) "_set_tmod(spi_num, SPI_TMOD_TRANS_RECV);\n\n vola" (call_expression) "_set_tmod(spi_num, SPI_TMOD_TRANS_RECV);\n\n vol" (identifier) "_set_tmod(spi_num, " (argument_list) "SPI_TMOD_TRANS_RECV);\n\n vol" (() "S" (identifier) "PI_TMOD" (,) "_" (identifier) "RANS_RECV);\n\n vo" ()) "l" (;) "a" (declaration) "pi_t *spi_handle = spi[spi_num];\n\n uint" (type_qualifier) "pi_t *sp" (volatile) "pi_t *sp" (type_identifier) "_hand" (init_declarator) "e = spi[spi_num];\n\n uin" (pointer_declarator) "e = spi[spi" (*) "e" (identifier) " = spi[spi" (=) "n" (subscript_expression) "m];\n\n uin" (identifier) "m];" ([) "\n" (identifier) "\n ui" (]) "n" (;) "t" (declaration) "s_offset;\n switc" (primitive_type) "s_offse" (identifier) ";\n swit" (;) "c" (switch_statement) "i_num)\n {\n case 0:\n case 1:\n dfs_offset = 16;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n dfs_offset = 0;\n break;\n }\n uint3" (switch) "i_num)" (parenthesized_expression) " {\n " (() " " (identifier) " {\n " ()) " " (compound_statement) " 0:\n case 1:\n dfs_offset = 16;\n break;\n case 2:\n configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case 3:\n default:\n dfs_offset = 0;\n break;\n }\n uint3" ({) " " (case_statement) " case " (case) " ca" (number_literal) "e" (:) " " (case_statement) " dfs_offset = 16;\n break;\n case " (case) " " (number_literal) " " (:) "d" (expression_statement) " = 16;\n b" (assignment_expression) " = 16;\n " (identifier) " = 16;\n " (=) " " (number_literal) " " (;) "b" (break_statement) " case " (break) " case" (;) " " (case_statement) " configASSERT(!"Spi Bus 2 Not Support!");\n break;\n case " (case) " " (number_literal) " " (:) "c" (expression_statement) "RT(!"Spi Bus 2 Not Support!");\n b" (call_expression) "RT(!"Spi Bus 2 Not Support!");\n " (identifier) "RT(!"Spi Bus" (argument_list) " 2 Not Support!");\n " (() " " (unary_expression) "2 Not Support!");\n " (!) "2" (string_literal) " Not Support!");\n " (") " " (string_content) "Not Support!");\n " (") " " ()) " " (;) "b" (break_statement) " case " (break) " case" (;) " " (case_statement) " defau" (case) " de" (number_literal) "a" (:) "u" (case_statement) " dfs_offset = 0;\n break;\n }\n " (default) " " (:) "d" (expression_statement) " = 0;\n b" (assignment_expression) " = 0;\n " (identifier) " = 0;\n " (=) " " (number_literal) " " (;) "b" (break_statement) " }\n " (break) " }\n " (;) " " (}) "3" (declaration) "ata_bit_length = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F;\n spi_t" (primitive_type) "ata_bit_" (init_declarator) "ength = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F;\n spi_" (identifier) "ength = (spi_ha" (=) "d" (binary_expression) "e->ctrlr0 >> dfs_offset) & 0x1F;\n spi_" (parenthesized_expression) "e->ctrlr0 >> dfs_offset) & 0x1F;\n " (() "e" (binary_expression) "->ctrlr0 >> dfs_offset) & 0x1F;\n" (field_expression) "->ctrlr0 >> dfs_of" (identifier) "->ctrlr0 >" (->) "> " (field_identifier) "dfs_of" (>>) "se" (identifier) ") & 0x1F;\n" ()) " " (&) " " (number_literal) "spi_" (;) "t" (declaration) "er_width_t frame_width = sipeed_spi_get_frame_size(data_bit_length);\n spi_h" (type_identifier) "er_width_t frame_wid" (init_declarator) "h = sipeed_spi_get_frame_size(data_bit_length);\n spi_" (identifier) "h = sipeed_" (=) "p" (call_expression) "_get_frame_size(data_bit_length);\n spi_" (identifier) "_get_frame_size(data_bit_" (argument_list) "length);\n spi_" (() "l" (identifier) "ength);\n spi" ()) "_" (;) "h" (expression_statement) "->ctrlr1 = (uint32_t)(tx_len / frame_width - 1);\n spi_h" (assignment_expression) "->ctrlr1 = (uint32_t)(tx_len / frame_width - 1);\n spi_" (field_expression) "->ctrlr1 = (uint32" (identifier) "->ctrlr1 =" (->) " (" (field_identifier) "uint32" (=) "t" (cast_expression) "(tx_len / frame_width - 1);\n spi_" (() "(" (type_descriptor) "tx_len /" (primitive_type) "tx_len /" ()) " " (parenthesized_expression) "frame_width - 1);\n spi_" (() "f" (binary_expression) "rame_width - 1);\n spi" (binary_expression) "rame_width - 1);\n " (identifier) "rame_w" (/) "d" (identifier) "h - 1);\n " (-) "s" (number_literal) "i" ()) "_" (;) "h" (expression_statement) "->ssienr = 0x01;\n spi_h" (assignment_expression) "->ssienr = 0x01;\n spi_" (field_expression) "->ssienr = 0x01;\n " (identifier) "->ssienr =" (->) " 0" (field_identifier) "x01;\n " (=) " " (number_literal) "spi_" (;) "h" (expression_statement) "->ser = 1U << chip_select;\n uint3" (assignment_expression) "->ser = 1U << chip_select;\n uint" (field_expression) "->ser = 1U << c" (identifier) "->ser = 1U" (->) " <" (field_identifier) "< c" (=) "i" (binary_expression) "_select;\n uint" (number_literal) "_s" (<<) "le" (identifier) "t;\n uint" (;) "3" (declaration) " = 0;\n while" (primitive_type) " = 0;\n " (init_declarator) " whil" (identifier) " " (=) "h" (number_literal) "l" (;) "e" (while_statement) "len)\n {\n fifo_len = 32 - spi_handle->txflr;\n fifo_len = fifo_len < tx_len ? fifo_len : tx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n tx_len -= fifo_len;\n }\n\n whil" (while) "len)\n" (parenthesized_expression) " {\n " (() " " (identifier) " {\n " ()) " " (compound_statement) "fifo_len = 32 - spi_handle->txflr;\n fifo_len = fifo_len < tx_len ? fifo_len : tx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n tx_len -= fifo_len;\n }\n\n whil" ({) "f" (expression_statement) " 32 - spi_handle->txflr;\n f" (assignment_expression) " 32 - spi_handle->txflr;\n " (identifier) " 32 - sp" (=) "_" (binary_expression) "andle->txflr;\n " (number_literal) "an" (-) "l" (field_expression) "->txflr;\n " (identifier) "->txflr;\n " (->) " " (field_identifier) " " (;) "f" (expression_statement) " fifo_len < tx_len ? fifo_len : tx_len;\n s" (assignment_expression) " fifo_len < tx_len ? fifo_len : tx_len;\n " (identifier) " fifo_le" (=) " " (conditional_expression) " tx_len ? fifo_len : tx_len;\n " (binary_expression) " tx_len ? fifo_le" (identifier) " tx_len " (<) " " (identifier) "ifo_le" (?) " " (identifier) " tx_len;" (:) " " (identifier) " " (;) "s" (switch_statement) "ame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n t" (switch) "ame_wi" (parenthesized_expression) "th)\n {" (() "t" (identifier) "h)\n " ()) "{" (compound_statement) "case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n t" ({) "c" (case_statement) "RANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n c" (case) "RANS" (identifier) "INT:\n " (:) " " (expression_statement) " fifo_len / 4 * 4;\n " (assignment_expression) " fifo_len / 4 * 4;\n " (identifier) " fifo_le" (=) " " (binary_expression) " 4 * 4;\n " (binary_expression) " 4 * 4;\n " (identifier) " 4 * 4;\n" (/) " " (number_literal) " " (*) " " (number_literal) " " (;) " " (for_statement) " = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n " (for) " = " (() ";" (assignment_expression) " index < " (identifier) " inde" (=) " " (number_literal) " " (;) "f" (binary_expression) "fo_len / 4; index++)" (identifier) "fo_le" (<) " " (binary_expression) " 4; index++)" (identifier) " 4; inde" (/) "+" (number_literal) ")" (;) "\n" (update_expression) " " (identifier) " " (++) " " ()) " " (expression_statement) "->dr[0] = ((uint32_t *)tx_buff)[i++];\n " (assignment_expression) "->dr[0] = ((uint32_t *)tx_buff)[i++];\n " (subscript_expression) "->dr[0] = ((uint3" (field_expression) "->dr[0] = ((ui" (identifier) "->dr[0] = " (->) "((" (field_identifier) "ui" ([) "n" (number_literal) "t" (]) "3" (=) "_" (subscript_expression) " *)tx_buff)[i++];\n " (parenthesized_expression) " *)tx_buff)[i++];\n " (() " " (cast_expression) "*)tx_buff)[i++];\n " (() "*" (type_descriptor) ")tx_buff)[" (primitive_type) ")tx_buff" (abstract_pointer_declarator) "[" (*) "[" ()) "i" (identifier) "++];\n " ()) " " ([) " " (update_expression) " " (identifier) " " (++) " " (]) " " (;) " " (break_statement) " c" (break) " " (;) "c" (case_statement) "RANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n d" (case) "RANS" (identifier) "SHORT:\n " (:) " " (expression_statement) " fifo_len / 2 * 2;\n " (assignment_expression) " fifo_len / 2 * 2;\n " (identifier) " fifo_le" (=) " " (binary_expression) " 2 * 2;\n " (binary_expression) " 2 * 2;\n " (identifier) " 2 * 2;\n" (/) " " (number_literal) " " (*) " " (number_literal) " " (;) " " (for_statement) " = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n " (for) " = " (() ";" (assignment_expression) " index < " (identifier) " inde" (=) " " (number_literal) " " (;) "f" (binary_expression) "fo_len / 2; index++)" (identifier) "fo_le" (<) " " (binary_expression) " 2; index++)" (identifier) " 2; inde" (/) "+" (number_literal) ")" (;) "\n" (update_expression) " " (identifier) " " (++) " " ()) " " (expression_statement) "->dr[0] = ((uint16_t *)tx_buff)[i++];\n " (assignment_expression) "->dr[0] = ((uint16_t *)tx_buff)[i++];\n " (subscript_expression) "->dr[0] = ((uint1" (field_expression) "->dr[0] = ((ui" (identifier) "->dr[0] = " (->) "((" (field_identifier) "ui" ([) "n" (number_literal) "t" (]) "1" (=) "_" (subscript_expression) " *)tx_buff)[i++];\n " (parenthesized_expression) " *)tx_buff)[i++];\n " (() " " (cast_expression) "*)tx_buff)[i++];\n " (() "*" (type_descriptor) ")tx_buff)[" (primitive_type) ")tx_buff" (abstract_pointer_declarator) "[" (*) "[" ()) "i" (identifier) "++];\n " ()) " " ([) " " (update_expression) " " (identifier) " " (++) " " (]) " " (;) " " (break_statement) " d" (break) " " (;) "d" (case_statement) " for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }" (default) " " (:) " " (for_statement) " = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n " (for) " = " (() ";" (assignment_expression) " index < " (identifier) " inde" (=) " " (number_literal) " " (;) "f" (binary_expression) "fo_len; index++)" (identifier) "fo_le" (<) ";" (identifier) "index++)" (;) "\n" (update_expression) " " (identifier) " " (++) " " ()) " " (expression_statement) "->dr[0] = tx_buff[i++];\n " (assignment_expression) "->dr[0] = tx_buff[i++];\n " (subscript_expression) "->dr[0] = tx_buff" (field_expression) "->dr[0] = tx_b" (identifier) "->dr[0] = " (->) "tx" (field_identifier) "_b" ([) "u" (number_literal) "f" (]) "f" (=) "i" (subscript_expression) "+];\n " (identifier) "+];\n " ([) " " (update_expression) " " (identifier) " " (++) " " (]) " " (;) " " (break_statement) " }" (break) " " (;) "}" (}) "t" (expression_statement) "fifo_len;\n }\n\n " (assignment_expression) "fifo_len;\n }\n\n " (identifier) "fifo_l" (-=) "n;" (identifier) " }\n\n " (;) " " (}) "l" (while_statement) "i_handle->sr & 0x05) != 0x04)\n ;\n i = 0" (while) "i_han" (parenthesized_expression) "le->sr & 0x05) != 0x04)\n ;" (() "l" (binary_expression) "e->sr & 0x05) != 0x04)\n " (parenthesized_expression) "e->sr & 0x05) != 0x04)\n" (() "e" (binary_expression) "->sr & 0x05) != 0x04)" (field_expression) "->sr & 0x05) !" (identifier) "->sr & 0x0" (->) "5)" (field_identifier) " !" (&) " " (number_literal) "x04)" ()) "\n" (!=) " " (number_literal) " " ()) ";" (expression_statement) "0" (;) "0" (expression_statement) " while" (assignment_expression) " whil" (identifier) " " (=) "h" (number_literal) "l" (;) "e" (while_statement) "len)\n {\n fifo_len = spi_handle->rxflr;\n fifo_len = fifo_len < rx_len ? fifo_len : rx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n rx_len -= fifo_len;\n }\n spi_h" (while) "len)\n" (parenthesized_expression) " {\n " (() " " (identifier) " {\n " ()) " " (compound_statement) "fifo_len = spi_handle->rxflr;\n fifo_len = fifo_len < rx_len ? fifo_len : rx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n rx_len -= fifo_len;\n }\n spi_h" ({) "f" (expression_statement) " spi_handle->rxflr;\n f" (assignment_expression) " spi_handle->rxflr;\n " (identifier) " spi_han" (=) "l" (field_expression) "->rxflr;\n " (identifier) "->rxflr;\n " (->) " " (field_identifier) " " (;) "f" (expression_statement) " fifo_len < rx_len ? fifo_len : rx_len;\n s" (assignment_expression) " fifo_len < rx_len ? fifo_len : rx_len;\n " (identifier) " fifo_le" (=) " " (conditional_expression) " rx_len ? fifo_len : rx_len;\n " (binary_expression) " rx_len ? fifo_le" (identifier) " rx_len " (<) " " (identifier) "ifo_le" (?) " " (identifier) " rx_len;" (:) " " (identifier) " " (;) "s" (switch_statement) "ame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n " (switch) "ame_wi" (parenthesized_expression) "th)\n {" (() "t" (identifier) "h)\n " ()) "{" (compound_statement) "case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n " ({) "c" (case_statement) "RANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n c" (case) "RANS" (identifier) "INT:\n " (:) " " (expression_statement) " fifo_len / 4 * 4;\n " (assignment_expression) " fifo_len / 4 * 4;\n " (identifier) " fifo_le" (=) " " (binary_expression) " 4 * 4;\n " (binary_expression) " 4 * 4;\n " (identifier) " 4 * 4;\n" (/) " " (number_literal) " " (*) " " (number_literal) " " (;) " " (for_statement) " = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n " (for) " = " (() ";" (assignment_expression) " index < " (identifier) " inde" (=) " " (number_literal) " " (;) "f" (binary_expression) "fo_len / 4; index++)" (identifier) "fo_le" (<) " " (binary_expression) " 4; index++)" (identifier) " 4; inde" (/) "+" (number_literal) ")" (;) "\n" (update_expression) " " (identifier) " " (++) " " ()) " " (expression_statement) " *)rx_buff)[i++] = spi_handle->dr[0];\n " (assignment_expression) " *)rx_buff)[i++] = spi_handle->dr[0];\n " (subscript_expression) " *)rx_buff)[i++] = spi_han" (parenthesized_expression) " *)rx_buff)[i++] = sp" (() " " (cast_expression) "*)rx_buff)[i++] = s" (() "*" (type_descriptor) ")rx_buff)[" (primitive_type) ")rx_buff" (abstract_pointer_declarator) "[" (*) "[" ()) "i" (identifier) "++] = s" ()) "p" ([) "i" (update_expression) "_ha" (identifier) "_" (++) "ha" (]) "n" (=) "l" (subscript_expression) "->dr[0];\n " (field_expression) "->dr[0];\n " (identifier) "->dr[0];\n " (->) " " (field_identifier) " " ([) " " (number_literal) " " (]) " " (;) " " (break_statement) " c" (break) " " (;) "c" (case_statement) "RANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n d" (case) "RANS" (identifier) "SHORT:\n " (:) " " (expression_statement) " fifo_len / 2 * 2;\n " (assignment_expression) " fifo_len / 2 * 2;\n " (identifier) " fifo_le" (=) " " (binary_expression) " 2 * 2;\n " (binary_expression) " 2 * 2;\n " (identifier) " 2 * 2;\n" (/) " " (number_literal) " " (*) " " (number_literal) " " (;) " " (for_statement) " = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n " (for) " = " (() ";" (assignment_expression) " index < " (identifier) " inde" (=) " " (number_literal) " " (;) "f" (binary_expression) "fo_len / 2; index++)" (identifier) "fo_le" (<) " " (binary_expression) " 2; index++)" (identifier) " 2; inde" (/) "+" (number_literal) ")" (;) "\n" (update_expression) " " (identifier) " " (++) " " ()) " " (expression_statement) " *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n " (assignment_expression) " *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n " (subscript_expression) " *)rx_buff)[i++] = (uint16" (parenthesized_expression) " *)rx_buff)[i++] = (u" (() " " (cast_expression) "*)rx_buff)[i++] = (" (() "*" (type_descriptor) ")rx_buff)[" (primitive_type) ")rx_buff" (abstract_pointer_declarator) "[" (*) "[" ()) "i" (identifier) "++] = (" ()) "u" ([) "i" (update_expression) "nt1" (identifier) "n" (++) "t1" (]) "6" (=) "t" (cast_expression) "spi_handle->dr[0];\n " (() "s" (type_descriptor) "pi_handl" (primitive_type) "pi_handl" ()) "e" (subscript_expression) "->dr[0];\n " (field_expression) "->dr[0];\n " (identifier) "->dr[0];\n " (->) " " (field_identifier) " " ([) " " (number_literal) " " (]) " " (;) " " (break_statement) " d" (break) " " (;) "d" (case_statement) " for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }" (default) " " (:) " " (for_statement) " = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n " (for) " = " (() ";" (assignment_expression) " index < " (identifier) " inde" (=) " " (number_literal) " " (;) "f" (binary_expression) "fo_len; index++)" (identifier) "fo_le" (<) ";" (identifier) "index++)" (;) "\n" (update_expression) " " (identifier) " " (++) " " ()) " " (expression_statement) "+] = (uint8_t)spi_handle->dr[0];\n " (assignment_expression) "+] = (uint8_t)spi_handle->dr[0];\n " (subscript_expression) "+] = (uint8_" (identifier) "+] = (u" ([) "i" (update_expression) "nt8" (identifier) "n" (++) "t8" (]) "_" (=) ")" (cast_expression) "pi_handle->dr[0];\n " (() "p" (type_descriptor) "i_handl" (primitive_type) "i_handl" ()) "e" (subscript_expression) "->dr[0];\n " (field_expression) "->dr[0];\n " (identifier) "->dr[0];\n " (->) " " (field_identifier) " " ([) " " (number_literal) " " (]) " " (;) " " (break_statement) " }" (break) " " (;) "}" (}) " " (expression_statement) "fifo_len;\n }\n " (assignment_expression) "fifo_len;\n }\n " (identifier) "fifo_l" (-=) "n;" (identifier) " }\n " (;) " " (}) "h" (expression_statement) "->ser = 0x00;\n spi_h" (assignment_expression) "->ser = 0x00;\n spi_" (field_expression) "->ser = 0x00;\n " (identifier) "->ser = 0x" (->) "00" (field_identifier) ";\n " (=) " " (number_literal) "spi_" (;) "h" (expression_statement) "->ssienr = 0x00;\n}\n\n/* SPI" (assignment_expression) "->ssienr = 0x00;\n}\n\n/* SP" (field_expression) "->ssienr = 0x00;\n}" (identifier) "->ssienr =" (->) " 0" (field_identifier) "x00;\n}" (=) "\n" (number_literal) "* SP" (;) "I" (}) "口" (comment) "化 */\nvoid soft_spi_init(" (function_definition) "oid)\n{\n printf("hard spi\r\n");\n //cs\n gpiohs_set_drive_mode(ESP32_SPI_CSX_HS_NUM, GPIO_DM_OUTPUT);\n gpiohs_set_pin(ESP32_SPI_CSX_HS_NUM, 1);\n //init SPI_DEVICE_1\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf("set spi clk:%d\r\n", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}\n\nuint8_t soft_spi_r" (primitive_type) "oid)" (function_declarator) "{\n printf("hard " (identifier) "{\n printf(" (parameter_list) ""hard " (() """ (parameter_declaration) "hard" (primitive_type) "hard" ()) " " (compound_statement) "pi\r\n");\n //cs\n gpiohs_set_drive_mode(ESP32_SPI_CSX_HS_NUM, GPIO_DM_OUTPUT);\n gpiohs_set_pin(ESP32_SPI_CSX_HS_NUM, 1);\n //init SPI_DEVICE_1\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf("set spi clk:%d\r\n", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}\n\nuint8_t soft_spi_r" ({) "p" (expression_statement) "");\n //cs\n gpiohs" (call_expression) "");\n //cs\n gpioh" (identifier) "");\n " (argument_list) " //cs\n gpioh" (() " " (string_literal) " //cs\n gpio" (") " " (string_content) "//cs\n " (escape_sequence) " g" (escape_sequence) "pi" (") "o" ()) "h" (;) "s" (comment) "driv" (expression_statement) "e(ESP32_SPI_CSX_HS_NUM, GPIO_DM_OUTPUT);\n gpiohs_set_pin(" (call_expression) "e(ESP32_SPI_CSX_HS_NUM, GPIO_DM_OUTPUT);\n gpiohs_set_pin" (identifier) "e(ESP32_SPI_CSX_HS_NU" (argument_list) "M, GPIO_DM_OUTPUT);\n gpiohs_set_pin" (() "M" (identifier) ", GPIO_DM_OUTPUT);\n " (,) " " (identifier) " gpiohs_set_pi" ()) "n" (;) "(" (expression_statement) "_SPI_CSX_HS_NUM, 1);\n //init SPI_DEVI" (call_expression) "_SPI_CSX_HS_NUM, 1);\n //init SPI_DEV" (identifier) "_SPI_CSX_HS_NU" (argument_list) "M, 1);\n //init SPI_DEV" (() "M" (identifier) ", 1);\n //init SPI" (,) "_" (number_literal) "E" ()) "V" (;) "I" (comment) " spi_init(SPI_DE" (expression_statement) "1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf("set spi" (call_expression) "1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf("set sp" (identifier) "1, SPI_W" (argument_list) "ORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf("set sp" (() "O" (identifier) "RK_MODE_0, S" (,) "P" (identifier) "_FF_STANDARD, 8" (,) "," (identifier) "0);\n printf(" (,) """ (number_literal) "e" (,) "t" (number_literal) "s" ()) "p" (;) "i" (expression_statement) "%d\r\n", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}\n" (call_expression) "%d\r\n", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}" (identifier) "%d\r\n" (argument_list) "", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}" (() """ (string_literal) ", spi_set_clk_rate(S" (") "," (string_content) " spi_set_clk_r" (escape_sequence) "at" (escape_sequence) "e(" (") "S" (,) "P" (call_expression) "_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n" (identifier) "_DEVICE_1, 10000" (argument_list) "00 * 8)); /*set clk rate*/\n" (() "0" (identifier) "0 * 8)); /*s" (,) "e" (binary_expression) " clk rate*/" (number_literal) " clk ra" (*) "e" (number_literal) "/" ()) "\n" ()) "}" (;) "\n" (comment) "uint8_t soft_spi" (}) "r" (function_definition) "uint8_t data)\n{\n uint8_t c;\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nvoid soft_spi_rw_l" (primitive_type) "uint8_t" (function_declarator) "data)\n{\n uint8_t c;\n " (identifier) "data)\n{\n " (parameter_list) " uint8_t c;\n " (() " " (parameter_declaration) "uint8_t c;\n " (primitive_type) "uint8_t" (identifier) "c;\n " ()) " " (compound_statement) " sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nvoid soft_spi_rw_l" ({) " " (declaration) "d_spi_tran" (primitive_type) "d_spi_t" (identifier) "a" (;) "n" (expression_statement) "data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nvo" (call_expression) "data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nv" (identifier) "data_standard(SPI_DEVICE_1, SPI_C" (argument_list) "HIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nv" (() "H" (identifier) "IP_SELECT_0," (,) " " (identifier) "data, &c, 1);\n " (,) " " (pointer_expression) "eturn" (&) "e" (identifier) "turn" (,) " " (pointer_expression) ";\n" (&) ";" (identifier) "\n" (,) "}" (number_literal) "\n" ()) "v" (;) "o" (return_statement) "ft_spi_rw" (return) "ft_spi" (identifier) "r" (;) "w" (}) "l" (function_definition) "(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(" buffer is null\r\n");\n return;\n }\n\n#if 0\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only send\n if (send && recv == NULL)\n {\n spi_send_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n }\n\n //only recv\n if (send == NULL && recv)\n {\n spi_receive_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n }\n\n //send and recv\n if (send && recv)\n {\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n }\n return;\n}\n\n#endif\n\nuint64_t g" (primitive_type) "(uin" (function_declarator) "8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == N" (identifier) "8_t *send, uint" (parameter_list) "8_t *recv, uint32_t len)\n{\n if (send == N" (() "8" (parameter_declaration) "_t *recv, uin" (primitive_type) "_t *rec" (pointer_declarator) ", uin" (*) "," (identifier) " uin" (,) "t" (parameter_declaration) "2_t len)\n{\n " (primitive_type) "2_t len" (pointer_declarator) "\n{\n " (*) "\n" (identifier) "{\n " (,) " " (parameter_declaration) "if (send == " (primitive_type) "if (send" (identifier) "== " ()) "N" (compound_statement) "LL && recv == NULL)\n {\n printf(" buffer is null\r\n");\n return;\n }\n\n#if 0\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only send\n if (send && recv == NULL)\n {\n spi_send_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n }\n\n //only recv\n if (send == NULL && recv)\n {\n spi_receive_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n }\n\n //send and recv\n if (send && recv)\n {\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n }\n return;\n}\n\n#endif\n\nuint64_t g" ({) "L" (if_statement) "recv == NULL)\n {\n printf(" buffer is null\r\n");\n return;\n }\n\n#if 0\n spi_init" (if) "re" (parenthesized_expression) "v == NULL)\n {\n print" (() "v" (binary_expression) " == NULL)\n {\n prin" (binary_expression) " == NULL)\n " (identifier) " == " (==) "UL" (null) ")\n " (NULL) ")\n " (&&) " {" (binary_expression) " prin" (identifier) " " (==) " " (null) "prin" (NULL) "prin" ()) "t" (compound_statement) "uffer is null\r\n");\n return;\n }\n\n#if 0\n spi_init" ({) "u" (expression_statement) "ull\r\n");\n return;\n " (call_expression) "ull\r\n");\n return;\n " (identifier) "ull\r\" (argument_list) "n");\n return;\n " (() "n" (string_literal) "");\n return;\n " (") """ (string_content) ");\n retu" (escape_sequence) "rn" (escape_sequence) ";\n" (") " " ()) " " (;) " " (return_statement) "\n sp" (return) "\n s" (;) "p" (}) "t" (preproc_if) "PI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only send\n " (#if) "PI_" (number_literal) "E" ( ) "V" (expression_statement) "1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only " (call_expression) "1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only" (identifier) "1, SPI_W" (argument_list) "ORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only" (() "O" (identifier) "RK_MODE_0, S" (,) "P" (identifier) "_FF_STANDARD, 8" (,) "," (identifier) "0);\n#endif\n\n " (,) " " (number_literal) "/" (,) "o" (number_literal) "l" ()) "y" (;) " " (#endif) "end\n " (comment) "send && rec" (if_statement) "NULL)\n {\n spi_send_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n }\n\n //only recv\n " (if) "NU" (parenthesized_expression) "L)\n {\n spi_s" (() "L" (binary_expression) ")\n {\n spi_" (identifier) ")\n " (&&) " {" (binary_expression) " spi_" (identifier) " " (==) " " (null) "spi_" (NULL) "spi_" ()) "s" (compound_statement) "ata_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n }\n\n //only recv\n " ({) "a" (expression_statement) "rd(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n " (call_expression) "rd(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n " (identifier) "rd(SPI_DEVICE_1, SPI_C" (argument_list) "HIP_SELECT_0, NULL, 0, send, len);\n return;\n " (() "H" (identifier) "IP_SELECT_0," (,) " " (identifier) "ULL, 0, send, len" (,) ")" (null) "\n " (NULL) "\n " (,) " " (number_literal) " " (,) " " (identifier) "retu" (,) "r" (identifier) ";\n " ()) " " (;) " " (return_statement) "/only r" (return) "/only " (;) "r" (}) " " (comment) "send == NUL" (if_statement) "recv)\n {\n spi_receive_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n }\n\n //send and rec" (if) "re" (parenthesized_expression) "v)\n {\n spi_r" (() "v" (binary_expression) ")\n {\n spi_" (binary_expression) ")\n {\n " (identifier) ")\n " (==) " {" (null) " " (NULL) " " (&&) " " (identifier) "spi_" ()) "r" (compound_statement) "e_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n }\n\n //send and rec" ({) "e" (expression_statement) "ndard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n " (call_expression) "ndard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n " (identifier) "ndard(SPI_DEVICE_1, SPI_C" (argument_list) "HIP_SELECT_0, NULL, 0, recv, len);\n return;\n " (() "H" (identifier) "IP_SELECT_0," (,) " " (identifier) "ULL, 0, recv, len" (,) ")" (null) "\n " (NULL) "\n " (,) " " (number_literal) " " (,) " " (identifier) "retu" (,) "r" (identifier) ";\n " ()) " " (;) " " (return_statement) "/send a" (return) "/send " (;) "a" (}) "c" (comment) "if (send && rec" (if_statement) " {\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n }\n return;\n}\n\n#end" (if) " " (parenthesized_expression) "\n sipee" (() "\n" (binary_expression) " sipe" (identifier) " " (&&) " " (identifier) "sipe" ()) "e" (compound_statement) "_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n }\n return;\n}\n\n#end" ({) "_" (expression_statement) "data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n " (call_expression) "data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n " (identifier) "data_standard(SPI_DEVICE_1, SPI_C" (argument_list) "HIP_SELECT_0, send, recv, len);\n return;\n " (() "H" (identifier) "IP_SELECT_0," (,) " " (identifier) "end, recv, len);\n" (,) " " (identifier) " " (,) " " (identifier) "retu" (,) "r" (identifier) ";\n " ()) " " (;) " " (return_statement) "turn;\n}" (return) "turn;\n" (;) "}" (}) "d" (return_statement) "int64_t" (return) "int64_" (;) "t" (}) "g" (#endif) "_milli" (function_definition) "void)\n{\n return sysctl_get_time_us() / 1000;\n}\n" (primitive_type) "void)\n{\n" (function_declarator) " return sysctl" (identifier) " return " (parameter_list) "sysctl" (() "s" (parameter_declaration) "ysct" (primitive_type) "ysct" ()) "l" (compound_statement) "get_time_us() / 1000;\n}\n" ({) "g" (return_statement) "me_us() / 1000;\n}\n" (return) "me_us(" (binary_expression) " / 1000;\n}\n" (call_expression) " / 1000;\n}\n" (identifier) " / 1000;\n}\n" (argument_list) "" (() "" ()) "" (/) "" (number_literal) "" (;) "" (}) ""
2,055
0
{"language": "c", "success": true, "metadata": {"lines": 275, "avg_line_length": 25.95, "nodes": 1210, "errors": 0, "source_hash": "7af3f8d234a6ebaae40e1586e4ebd9938b67137fe0b163b63aede767e3f07cab", "categorized_nodes": 820}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <stdlib.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<stdlib.h>", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 19}}, {"id": 3, "type": "preproc_include", "text": "#include \"esp32_spi_io.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 8}}, {"id": 5, "type": "string_literal", "text": "\"esp32_spi_io.h\"", "parent": 3, "children": [], "start_point": {"row": 1, "column": 9}, "end_point": {"row": 1, "column": 25}}, {"id": 6, "type": "preproc_include", "text": "#include \"gpiohs.h\"\n", "parent": null, "children": [7, 8], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"gpiohs.h\"", "parent": 6, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 19}}, {"id": 9, "type": "preproc_include", "text": "#include \"sleep.h\"\n", "parent": null, "children": [10, 11], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"sleep.h\"", "parent": 9, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 18}}, {"id": 12, "type": "preproc_include", "text": "#include \"sysctl.h\"\n", "parent": null, "children": [13, 14], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 14, "type": "string_literal", "text": "\"sysctl.h\"", "parent": 12, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 19}}, {"id": 15, "type": "preproc_include", "text": "#include <utils.h>\n", "parent": null, "children": [16, 17], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 8}}, {"id": 17, "type": "system_lib_string", "text": "<utils.h>", "parent": 15, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 18}}, {"id": 18, "type": "preproc_include", "text": "#include \"spi.h\"\n", "parent": null, "children": [19, 20], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 8}}, {"id": 20, "type": "string_literal", "text": "\"spi.h\"", "parent": 18, "children": [], "start_point": {"row": 7, "column": 9}, "end_point": {"row": 7, "column": 16}}, {"id": 21, "type": "preproc_include", "text": "#include \"esp32_spi.h\"\n", "parent": null, "children": [22, 23], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 22, "type": "#include", "text": "#include", "parent": 21, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 8}}, {"id": 23, "type": "string_literal", "text": "\"esp32_spi.h\"", "parent": 21, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 22}}, {"id": 24, "type": "preproc_if", "text": "#if 1 /* ESP32_SOFT_SPI */\n\n#define GPIOHS_OUT_HIGH(io) (*(volatile uint32_t *)0x3800100CU) |= (1 << (io))\n#define GPIOHS_OUT_LOWX(io) (*(volatile uint32_t *)0x3800100CU) &= ~(1 << (io))\n\n#define GET_GPIOHS_VALX(io) (((*(volatile uint32_t *)0x38001000U) >> (io)) & 1)\n\nuint8_t cs_num = 0, rst_num = 0, rdy_num = 0;\n\nstatic uint8_t _mosi_num = -1;\nstatic uint8_t _miso_num = -1;\nstatic uint8_t _sclk_num = -1;\n\n/* SPI\u7aef\u53e3\u521d\u59cb\u5316 */\n//should check io value\nvoid esp32_spi_config_io(uint8_t cs, uint8_t rst, uint8_t rdy, uint8_t mosi, uint8_t miso, uint8_t sclk)\n{\n //clk\n gpiohs_set_drive_mode(sclk, GPIO_DM_OUTPUT);\n gpiohs_set_pin(sclk, 0);\n //mosi\n gpiohs_set_drive_mode(mosi, GPIO_DM_OUTPUT);\n gpiohs_set_pin(mosi, 0);\n //miso\n gpiohs_set_drive_mode(miso, GPIO_DM_INPUT_PULL_UP);\n\n _mosi_num = mosi;\n _miso_num = miso;\n _sclk_num = sclk;\n\n cs_num = cs;\n rdy_num = rdy;\n rst_num = rst; //if rst <0, use soft reset\n}\n\nuint8_t soft_spi_rw(uint8_t data)\n{\n uint8_t i;\n uint8_t temp = 0;\n for (i = 0; i < 8; i++)\n {\n if (data & 0x80)\n {\n GPIOHS_OUT_HIGH(_mosi_num);\n }\n else\n {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n data <<= 1;\n GPIOHS_OUT_HIGH(_sclk_num);\n\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n\n temp <<= 1;\n if (GET_GPIOHS_VALX(_miso_num))\n {\n temp++;\n }\n GPIOHS_OUT_LOWX(_sclk_num);\n\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n }\n return temp;\n}\n\nvoid soft_spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(\" buffer is null\\r\\n\");\n return;\n }\n\n#if 0\n uint32_t i = 0;\n do\n {\n *(recv + i) = soft_spi_rw(*(send + i));\n i++;\n } while (--len);\n#else\n\n uint32_t i = 0;\n uint8_t *stmp = NULL, sf = 0;\n\n if (send == NULL)\n {\n stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n stmp = send;\n\n if (recv == NULL)\n {\n do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n {\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (sf)\n free(stmp);\n#endif\n}\n\n#else\n\nstatic spi_transfer_width_t sipeed_spi_get_frame_size(size_t data_bit_length)\n{\n if (data_bit_length < 8)\n return SPI_TRANS_CHAR;\n else if (data_bit_length < 16)\n return SPI_TRANS_SHORT;\n return SPI_TRANS_INT;\n}\n\nstatic void sipeed_spi_set_tmod(uint8_t spi_num, uint32_t tmod)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n volatile spi_t *spi_handle = spi[spi_num];\n uint8_t tmod_offset = 0;\n switch (spi_num)\n {\n case 0:\n case 1:\n tmod_offset = 8;\n break;\n case 2:\n configASSERT(!\"Spi Bus 2 Not Support!\");\n break;\n case 3:\n default:\n tmod_offset = 10;\n break;\n }\n set_bit(&spi_handle->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstatic void sipeed_spi_transfer_data_standard(spi_device_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_buff, uint8_t *rx_buff, size_t len)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n configASSERT(len > 0);\n size_t index, fifo_len;\n size_t rx_len = len;\n size_t tx_len = rx_len;\n sipeed_spi_set_tmod(spi_num, SPI_TMOD_TRANS_RECV);\n\n volatile spi_t *spi_handle = spi[spi_num];\n\n uint8_t dfs_offset;\n switch (spi_num)\n {\n case 0:\n case 1:\n dfs_offset = 16;\n break;\n case 2:\n configASSERT(!\"Spi Bus 2 Not Support!\");\n break;\n case 3:\n default:\n dfs_offset = 0;\n break;\n }\n uint32_t data_bit_length = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F;\n spi_transfer_width_t frame_width = sipeed_spi_get_frame_size(data_bit_length);\n spi_handle->ctrlr1 = (uint32_t)(tx_len / frame_width - 1);\n spi_handle->ssienr = 0x01;\n spi_handle->ser = 1U << chip_select;\n uint32_t i = 0;\n while (tx_len)\n {\n fifo_len = 32 - spi_handle->txflr;\n fifo_len = fifo_len < tx_len ? fifo_len : tx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n tx_len -= fifo_len;\n }\n\n while ((spi_handle->sr & 0x05) != 0x04)\n ;\n i = 0;\n while (rx_len)\n {\n fifo_len = spi_handle->rxflr;\n fifo_len = fifo_len < rx_len ? fifo_len : rx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n rx_len -= fifo_len;\n }\n spi_handle->ser = 0x00;\n spi_handle->ssienr = 0x00;\n}\n\n/* SPI\u7aef\u53e3\u521d\u59cb\u5316 */\nvoid soft_spi_init(void)\n{\n printf(\"hard spi\\r\\n\");\n //cs\n gpiohs_set_drive_mode(ESP32_SPI_CSX_HS_NUM, GPIO_DM_OUTPUT);\n gpiohs_set_pin(ESP32_SPI_CSX_HS_NUM, 1);\n //init SPI_DEVICE_1\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf(\"set spi clk:%d\\r\\n\", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}\n\nuint8_t soft_spi_rw(uint8_t data)\n{\n uint8_t c;\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nvoid soft_spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(\" buffer is null\\r\\n\");\n return;\n }\n\n#if 0\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only send\n if (send && recv == NULL)\n {\n spi_send_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n }\n\n //only recv\n if (send == NULL && recv)\n {\n spi_receive_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n }\n\n //send and recv\n if (send && recv)\n {\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n }\n return;\n}\n\n#endif\n\nuint64_t get_milli", "parent": null, "children": [25, 26, 27, 28, 34, 40, 46, 60, 66, 72, 78, 150, 237, 401, 1196], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 305, "column": 6}}, {"id": 25, "type": "#if", "text": "#if", "parent": 24, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 3}}, {"id": 26, "type": "number_literal", "text": "1", "parent": 24, "children": [], "start_point": {"row": 10, "column": 4}, "end_point": {"row": 10, "column": 5}}, {"id": 27, "type": "\n", "text": "\n\n", "parent": 24, "children": [], "start_point": {"row": 10, "column": 26}, "end_point": {"row": 12, "column": 0}}, {"id": 28, "type": "preproc_function_def", "text": "#define GPIOHS_OUT_HIGH(io) (*(volatile uint32_t *)0x3800100CU) |= (1 << (io))\n", "parent": 24, "children": [29, 30, 31, 33], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 13, "column": 0}}, {"id": 29, "type": "#define", "text": "#define", "parent": 28, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 7}}, {"id": 30, "type": "identifier", "text": "GPIOHS_OUT_HIGH", "parent": 28, "children": [], "start_point": {"row": 12, "column": 8}, "end_point": {"row": 12, "column": 23}}, {"id": 31, "type": "preproc_params", "text": "(io)", "parent": 28, "children": [32], "start_point": {"row": 12, "column": 23}, "end_point": {"row": 12, "column": 27}}, {"id": 32, "type": "identifier", "text": "io", "parent": 31, "children": [], "start_point": {"row": 12, "column": 24}, "end_point": {"row": 12, "column": 26}}, {"id": 33, "type": "preproc_arg", "text": "(*(volatile uint32_t *)0x3800100CU) |= (1 << (io))", "parent": 28, "children": [], "start_point": {"row": 12, "column": 28}, "end_point": {"row": 12, "column": 78}}, {"id": 34, "type": "preproc_function_def", "text": "#define GPIOHS_OUT_LOWX(io) (*(volatile uint32_t *)0x3800100CU) &= ~(1 << (io))\n", "parent": 24, "children": [35, 36, 37, 39], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 14, "column": 0}}, {"id": 35, "type": "#define", "text": "#define", "parent": 34, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 7}}, {"id": 36, "type": "identifier", "text": "GPIOHS_OUT_LOWX", "parent": 34, "children": [], "start_point": {"row": 13, "column": 8}, "end_point": {"row": 13, "column": 23}}, {"id": 37, "type": "preproc_params", "text": "(io)", "parent": 34, "children": [38], "start_point": {"row": 13, "column": 23}, "end_point": {"row": 13, "column": 27}}, {"id": 38, "type": "identifier", "text": "io", "parent": 37, "children": [], "start_point": {"row": 13, "column": 24}, "end_point": {"row": 13, "column": 26}}, {"id": 39, "type": "preproc_arg", "text": "(*(volatile uint32_t *)0x3800100CU) &= ~(1 << (io))", "parent": 34, "children": [], "start_point": {"row": 13, "column": 28}, "end_point": {"row": 13, "column": 79}}, {"id": 40, "type": "preproc_function_def", "text": "#define GET_GPIOHS_VALX(io) (((*(volatile uint32_t *)0x38001000U) >> (io)) & 1)\n", "parent": 24, "children": [41, 42, 43, 45], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 41, "type": "#define", "text": "#define", "parent": 40, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 7}}, {"id": 42, "type": "identifier", "text": "GET_GPIOHS_VALX", "parent": 40, "children": [], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 23}}, {"id": 43, "type": "preproc_params", "text": "(io)", "parent": 40, "children": [44], "start_point": {"row": 15, "column": 23}, "end_point": {"row": 15, "column": 27}}, {"id": 44, "type": "identifier", "text": "io", "parent": 43, "children": [], "start_point": {"row": 15, "column": 24}, "end_point": {"row": 15, "column": 26}}, {"id": 45, "type": "preproc_arg", "text": "(((*(volatile uint32_t *)0x38001000U) >> (io)) & 1)", "parent": 40, "children": [], "start_point": {"row": 15, "column": 28}, "end_point": {"row": 15, "column": 79}}, {"id": 46, "type": "declaration", "text": "uint8_t cs_num = 0, rst_num = 0, rdy_num = 0;", "parent": 24, "children": [47, 48, 52, 56], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 45}}, {"id": 47, "type": "primitive_type", "text": "uint8_t", "parent": 46, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 7}}, {"id": 48, "type": "init_declarator", "text": "cs_num = 0", "parent": 46, "children": [49, 50, 51], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 17, "column": 18}}, {"id": 49, "type": "identifier", "text": "cs_num", "parent": 48, "children": [], "start_point": {"row": 17, "column": 8}, "end_point": {"row": 17, "column": 14}}, {"id": 50, "type": "=", "text": "=", "parent": 48, "children": [], "start_point": {"row": 17, "column": 15}, "end_point": {"row": 17, "column": 16}}, {"id": 51, "type": "number_literal", "text": "0", "parent": 48, "children": [], "start_point": {"row": 17, "column": 17}, "end_point": {"row": 17, "column": 18}}, {"id": 52, "type": "init_declarator", "text": "rst_num = 0", "parent": 46, "children": [53, 54, 55], "start_point": {"row": 17, "column": 20}, "end_point": {"row": 17, "column": 31}}, {"id": 53, "type": "identifier", "text": "rst_num", "parent": 52, "children": [], "start_point": {"row": 17, "column": 20}, "end_point": {"row": 17, "column": 27}}, {"id": 54, "type": "=", "text": "=", "parent": 52, "children": [], "start_point": {"row": 17, "column": 28}, "end_point": {"row": 17, "column": 29}}, {"id": 55, "type": "number_literal", "text": "0", "parent": 52, "children": [], "start_point": {"row": 17, "column": 30}, "end_point": {"row": 17, "column": 31}}, {"id": 56, "type": "init_declarator", "text": "rdy_num = 0", "parent": 46, "children": [57, 58, 59], "start_point": {"row": 17, "column": 33}, "end_point": {"row": 17, "column": 44}}, {"id": 57, "type": "identifier", "text": "rdy_num", "parent": 56, "children": [], "start_point": {"row": 17, "column": 33}, "end_point": {"row": 17, "column": 40}}, {"id": 58, "type": "=", "text": "=", "parent": 56, "children": [], "start_point": {"row": 17, "column": 41}, "end_point": {"row": 17, "column": 42}}, {"id": 59, "type": "number_literal", "text": "0", "parent": 56, "children": [], "start_point": {"row": 17, "column": 43}, "end_point": {"row": 17, "column": 44}}, {"id": 60, "type": "declaration", "text": "static uint8_t _mosi_num = -1;", "parent": 24, "children": [61, 62], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 30}}, {"id": 61, "type": "primitive_type", "text": "uint8_t", "parent": 60, "children": [], "start_point": {"row": 19, "column": 7}, "end_point": {"row": 19, "column": 14}}, {"id": 62, "type": "init_declarator", "text": "_mosi_num = -1", "parent": 60, "children": [63, 64, 65], "start_point": {"row": 19, "column": 15}, "end_point": {"row": 19, "column": 29}}, {"id": 63, "type": "identifier", "text": "_mosi_num", "parent": 62, "children": [], "start_point": {"row": 19, "column": 15}, "end_point": {"row": 19, "column": 24}}, {"id": 64, "type": "=", "text": "=", "parent": 62, "children": [], "start_point": {"row": 19, "column": 25}, "end_point": {"row": 19, "column": 26}}, {"id": 65, "type": "number_literal", "text": "-1", "parent": 62, "children": [], "start_point": {"row": 19, "column": 27}, "end_point": {"row": 19, "column": 29}}, {"id": 66, "type": "declaration", "text": "static uint8_t _miso_num = -1;", "parent": 24, "children": [67, 68], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 30}}, {"id": 67, "type": "primitive_type", "text": "uint8_t", "parent": 66, "children": [], "start_point": {"row": 20, "column": 7}, "end_point": {"row": 20, "column": 14}}, {"id": 68, "type": "init_declarator", "text": "_miso_num = -1", "parent": 66, "children": [69, 70, 71], "start_point": {"row": 20, "column": 15}, "end_point": {"row": 20, "column": 29}}, {"id": 69, "type": "identifier", "text": "_miso_num", "parent": 68, "children": [], "start_point": {"row": 20, "column": 15}, "end_point": {"row": 20, "column": 24}}, {"id": 70, "type": "=", "text": "=", "parent": 68, "children": [], "start_point": {"row": 20, "column": 25}, "end_point": {"row": 20, "column": 26}}, {"id": 71, "type": "number_literal", "text": "-1", "parent": 68, "children": [], "start_point": {"row": 20, "column": 27}, "end_point": {"row": 20, "column": 29}}, {"id": 72, "type": "declaration", "text": "static uint8_t _sclk_num = -1;", "parent": 24, "children": [73, 74], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 30}}, {"id": 73, "type": "primitive_type", "text": "uint8_t", "parent": 72, "children": [], "start_point": {"row": 21, "column": 7}, "end_point": {"row": 21, "column": 14}}, {"id": 74, "type": "init_declarator", "text": "_sclk_num = -1", "parent": 72, "children": [75, 76, 77], "start_point": {"row": 21, "column": 15}, "end_point": {"row": 21, "column": 29}}, {"id": 75, "type": "identifier", "text": "_sclk_num", "parent": 74, "children": [], "start_point": {"row": 21, "column": 15}, "end_point": {"row": 21, "column": 24}}, {"id": 76, "type": "=", "text": "=", "parent": 74, "children": [], "start_point": {"row": 21, "column": 25}, "end_point": {"row": 21, "column": 26}}, {"id": 77, "type": "number_literal", "text": "-1", "parent": 74, "children": [], "start_point": {"row": 21, "column": 27}, "end_point": {"row": 21, "column": 29}}, {"id": 78, "type": "function_definition", "text": "_spi_config_io(uint8_t cs, uint8_t rst, uint8_t rdy, uint8_t mosi, uint8_t miso, uint8_t sclk)\n{\n //clk\n gpiohs_set_drive_mode(sclk, GPIO_DM_OUTPUT);\n gpiohs_set_pin(sclk, 0);\n //mosi\n gpiohs_set_drive_mode(mosi, GPIO_DM_OUTPUT);\n gpiohs_set_pin(mosi, 0);\n //miso\n gpiohs_set_drive_mode(miso, GPIO_DM_INPUT_PULL_UP);\n\n _mosi_num = mosi;\n _miso_num = miso;\n _sclk_num = sclk;\n\n cs_num = cs;\n rdy_num = rdy;\n rst_num = rst; //if rst <0, use soft reset\n}\n\nuint8_t ", "parent": 24, "children": [79, 80], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 43, "column": 1}}, {"id": 79, "type": "primitive_type", "text": "_spi", "parent": 78, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 4}}, {"id": 80, "type": "function_declarator", "text": "config_io(uint8_t cs, uint8_t rst, uint8_t rdy, uint8_t mosi, uint8_t miso, uint8_t sclk)\n{\n //c", "parent": 78, "children": [81, 82], "start_point": {"row": 25, "column": 5}, "end_point": {"row": 25, "column": 104}}, {"id": 81, "type": "identifier", "text": "config_io(uint8_t c", "parent": 80, "children": [], "start_point": {"row": 25, "column": 5}, "end_point": {"row": 25, "column": 24}}, {"id": 82, "type": "parameter_list", "text": "s, uint8_t rst, uint8_t rdy, uint8_t mosi, uint8_t miso, uint8_t sclk)\n{\n //c", "parent": 80, "children": [83, 86, 89, 92, 95, 98], "start_point": {"row": 25, "column": 24}, "end_point": {"row": 25, "column": 104}}, {"id": 83, "type": "parameter_declaration", "text": ", uint8_t ", "parent": 82, "children": [84, 85], "start_point": {"row": 25, "column": 25}, "end_point": {"row": 25, "column": 35}}, {"id": 84, "type": "primitive_type", "text": ", uint8", "parent": 83, "children": [], "start_point": {"row": 25, "column": 25}, "end_point": {"row": 25, "column": 32}}, {"id": 85, "type": "identifier", "text": "t ", "parent": 83, "children": [], "start_point": {"row": 25, "column": 33}, "end_point": {"row": 25, "column": 35}}, {"id": 86, "type": "parameter_declaration", "text": "t, uint8_t ", "parent": 82, "children": [87, 88], "start_point": {"row": 25, "column": 37}, "end_point": {"row": 25, "column": 48}}, {"id": 87, "type": "primitive_type", "text": "t, uint", "parent": 86, "children": [], "start_point": {"row": 25, "column": 37}, "end_point": {"row": 25, "column": 44}}, {"id": 88, "type": "identifier", "text": "_t ", "parent": 86, "children": [], "start_point": {"row": 25, "column": 45}, "end_point": {"row": 25, "column": 48}}, {"id": 89, "type": "parameter_declaration", "text": "y, uint8_t ", "parent": 82, "children": [90, 91], "start_point": {"row": 25, "column": 50}, "end_point": {"row": 25, "column": 61}}, {"id": 90, "type": "primitive_type", "text": "y, uint", "parent": 89, "children": [], "start_point": {"row": 25, "column": 50}, "end_point": {"row": 25, "column": 57}}, {"id": 91, "type": "identifier", "text": "_t ", "parent": 89, "children": [], "start_point": {"row": 25, "column": 58}, "end_point": {"row": 25, "column": 61}}, {"id": 92, "type": "parameter_declaration", "text": "si, uint8_t ", "parent": 82, "children": [93, 94], "start_point": {"row": 25, "column": 63}, "end_point": {"row": 25, "column": 75}}, {"id": 93, "type": "primitive_type", "text": "si, uin", "parent": 92, "children": [], "start_point": {"row": 25, "column": 63}, "end_point": {"row": 25, "column": 70}}, {"id": 94, "type": "identifier", "text": "8_t ", "parent": 92, "children": [], "start_point": {"row": 25, "column": 71}, "end_point": {"row": 25, "column": 75}}, {"id": 95, "type": "parameter_declaration", "text": "so, uint8_t ", "parent": 82, "children": [96, 97], "start_point": {"row": 25, "column": 77}, "end_point": {"row": 25, "column": 89}}, {"id": 96, "type": "primitive_type", "text": "so, uin", "parent": 95, "children": [], "start_point": {"row": 25, "column": 77}, "end_point": {"row": 25, "column": 84}}, {"id": 97, "type": "identifier", "text": "8_t ", "parent": 95, "children": [], "start_point": {"row": 25, "column": 85}, "end_point": {"row": 25, "column": 89}}, {"id": 98, "type": "parameter_declaration", "text": "lk)\n{\n //", "parent": 82, "children": [99, 100], "start_point": {"row": 25, "column": 91}, "end_point": {"row": 25, "column": 103}}, {"id": 99, "type": "primitive_type", "text": "lk)\n{\n ", "parent": 98, "children": [], "start_point": {"row": 25, "column": 91}, "end_point": {"row": 25, "column": 98}}, {"id": 100, "type": "identifier", "text": " //", "parent": 98, "children": [], "start_point": {"row": 25, "column": 99}, "end_point": {"row": 25, "column": 103}}, {"id": 101, "type": "call_expression", "text": "_drive_mode(sclk, GPIO_DM_OUTPUT);\n gpio", "parent": 78, "children": [102, 103], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 28, "column": 47}}, {"id": 102, "type": "identifier", "text": "_drive_mode(sclk, GPI", "parent": 101, "children": [], "start_point": {"row": 28, "column": 4}, "end_point": {"row": 28, "column": 25}}, {"id": 103, "type": "argument_list", "text": "O_DM_OUTPUT);\n gpio", "parent": 101, "children": [104, 105], "start_point": {"row": 28, "column": 25}, "end_point": {"row": 28, "column": 47}}, {"id": 104, "type": "identifier", "text": "_DM_", "parent": 103, "children": [], "start_point": {"row": 28, "column": 26}, "end_point": {"row": 28, "column": 30}}, {"id": 105, "type": "identifier", "text": "TPUT);\n gpi", "parent": 103, "children": [], "start_point": {"row": 28, "column": 32}, "end_point": {"row": 28, "column": 46}}, {"id": 106, "type": "call_expression", "text": "_pin(sclk, 0);\n //mo", "parent": 78, "children": [107, 108], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 27}}, {"id": 107, "type": "identifier", "text": "_pin(sclk, 0);", "parent": 106, "children": [], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 18}}, {"id": 108, "type": "argument_list", "text": "\n //mo", "parent": 106, "children": [109, 110], "start_point": {"row": 29, "column": 18}, "end_point": {"row": 29, "column": 27}}, {"id": 109, "type": "identifier", "text": " ", "parent": 108, "children": [], "start_point": {"row": 29, "column": 19}, "end_point": {"row": 29, "column": 23}}, {"id": 110, "type": "number_literal", "text": "m", "parent": 108, "children": [], "start_point": {"row": 29, "column": 25}, "end_point": {"row": 29, "column": 26}}, {"id": 111, "type": "call_expression", "text": "_drive_mode(mosi, GPIO_DM_OUTPUT);\n gpio", "parent": 78, "children": [112, 113], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 47}}, {"id": 112, "type": "identifier", "text": "_drive_mode(mosi, GPI", "parent": 111, "children": [], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 25}}, {"id": 113, "type": "argument_list", "text": "O_DM_OUTPUT);\n gpio", "parent": 111, "children": [114, 115], "start_point": {"row": 31, "column": 25}, "end_point": {"row": 31, "column": 47}}, {"id": 114, "type": "identifier", "text": "_DM_", "parent": 113, "children": [], "start_point": {"row": 31, "column": 26}, "end_point": {"row": 31, "column": 30}}, {"id": 115, "type": "identifier", "text": "TPUT);\n gpi", "parent": 113, "children": [], "start_point": {"row": 31, "column": 32}, "end_point": {"row": 31, "column": 46}}, {"id": 116, "type": "call_expression", "text": "_pin(mosi, 0);\n //mi", "parent": 78, "children": [117, 118], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 32, "column": 27}}, {"id": 117, "type": "identifier", "text": "_pin(mosi, 0);", "parent": 116, "children": [], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 32, "column": 18}}, {"id": 118, "type": "argument_list", "text": "\n //mi", "parent": 116, "children": [119, 120], "start_point": {"row": 32, "column": 18}, "end_point": {"row": 32, "column": 27}}, {"id": 119, "type": "identifier", "text": " ", "parent": 118, "children": [], "start_point": {"row": 32, "column": 19}, "end_point": {"row": 32, "column": 23}}, {"id": 120, "type": "number_literal", "text": "m", "parent": 118, "children": [], "start_point": {"row": 32, "column": 25}, "end_point": {"row": 32, "column": 26}}, {"id": 121, "type": "call_expression", "text": "_drive_mode(miso, GPIO_DM_INPUT_PULL_UP);\n\n _mo", "parent": 78, "children": [122, 123], "start_point": {"row": 34, "column": 4}, "end_point": {"row": 34, "column": 54}}, {"id": 122, "type": "identifier", "text": "_drive_mode(miso, GPI", "parent": 121, "children": [], "start_point": {"row": 34, "column": 4}, "end_point": {"row": 34, "column": 25}}, {"id": 123, "type": "argument_list", "text": "O_DM_INPUT_PULL_UP);\n\n _mo", "parent": 121, "children": [124, 125], "start_point": {"row": 34, "column": 25}, "end_point": {"row": 34, "column": 54}}, {"id": 124, "type": "identifier", "text": "_DM_", "parent": 123, "children": [], "start_point": {"row": 34, "column": 26}, "end_point": {"row": 34, "column": 30}}, {"id": 125, "type": "identifier", "text": "PUT_PULL_UP);\n\n _m", "parent": 123, "children": [], "start_point": {"row": 34, "column": 32}, "end_point": {"row": 34, "column": 53}}, {"id": 126, "type": "assignment_expression", "text": "= mosi;\n _mis", "parent": 78, "children": [127, 128, 129], "start_point": {"row": 36, "column": 4}, "end_point": {"row": 36, "column": 20}}, {"id": 127, "type": "identifier", "text": "= mosi;\n ", "parent": 126, "children": [], "start_point": {"row": 36, "column": 4}, "end_point": {"row": 36, "column": 13}}, {"id": 128, "type": "=", "text": " ", "parent": 126, "children": [], "start_point": {"row": 36, "column": 14}, "end_point": {"row": 36, "column": 15}}, {"id": 129, "type": "identifier", "text": "_mis", "parent": 126, "children": [], "start_point": {"row": 36, "column": 16}, "end_point": {"row": 36, "column": 20}}, {"id": 130, "type": "assignment_expression", "text": "= miso;\n _scl", "parent": 78, "children": [131, 132, 133], "start_point": {"row": 37, "column": 4}, "end_point": {"row": 37, "column": 20}}, {"id": 131, "type": "identifier", "text": "= miso;\n ", "parent": 130, "children": [], "start_point": {"row": 37, "column": 4}, "end_point": {"row": 37, "column": 13}}, {"id": 132, "type": "=", "text": " ", "parent": 130, "children": [], "start_point": {"row": 37, "column": 14}, "end_point": {"row": 37, "column": 15}}, {"id": 133, "type": "identifier", "text": "_scl", "parent": 130, "children": [], "start_point": {"row": 37, "column": 16}, "end_point": {"row": 37, "column": 20}}, {"id": 134, "type": "assignment_expression", "text": "= sclk;\n\n cs_", "parent": 78, "children": [135, 136, 137], "start_point": {"row": 38, "column": 4}, "end_point": {"row": 38, "column": 20}}, {"id": 135, "type": "identifier", "text": "= sclk;\n\n", "parent": 134, "children": [], "start_point": {"row": 38, "column": 4}, "end_point": {"row": 38, "column": 13}}, {"id": 136, "type": "=", "text": " ", "parent": 134, "children": [], "start_point": {"row": 38, "column": 14}, "end_point": {"row": 38, "column": 15}}, {"id": 137, "type": "identifier", "text": " cs_", "parent": 134, "children": [], "start_point": {"row": 38, "column": 16}, "end_point": {"row": 38, "column": 20}}, {"id": 138, "type": "assignment_expression", "text": "s;\n rdy_", "parent": 78, "children": [139, 140, 141], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 40, "column": 15}}, {"id": 139, "type": "identifier", "text": "s;\n ", "parent": 138, "children": [], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 40, "column": 10}}, {"id": 140, "type": "=", "text": "r", "parent": 138, "children": [], "start_point": {"row": 40, "column": 11}, "end_point": {"row": 40, "column": 12}}, {"id": 141, "type": "identifier", "text": "y_", "parent": 138, "children": [], "start_point": {"row": 40, "column": 13}, "end_point": {"row": 40, "column": 15}}, {"id": 142, "type": "assignment_expression", "text": "rdy;\n rst_", "parent": 78, "children": [143, 144, 145], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 41, "column": 17}}, {"id": 143, "type": "identifier", "text": "rdy;\n ", "parent": 142, "children": [], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 41, "column": 11}}, {"id": 144, "type": "=", "text": " ", "parent": 142, "children": [], "start_point": {"row": 41, "column": 12}, "end_point": {"row": 41, "column": 13}}, {"id": 145, "type": "identifier", "text": "st_", "parent": 142, "children": [], "start_point": {"row": 41, "column": 14}, "end_point": {"row": 41, "column": 17}}, {"id": 146, "type": "assignment_expression", "text": "rst; //if rst", "parent": 78, "children": [147, 148, 149], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 17}}, {"id": 147, "type": "identifier", "text": "rst; //", "parent": 146, "children": [], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 11}}, {"id": 148, "type": "=", "text": "f", "parent": 146, "children": [], "start_point": {"row": 42, "column": 12}, "end_point": {"row": 42, "column": 13}}, {"id": 149, "type": "identifier", "text": "rst", "parent": 146, "children": [], "start_point": {"row": 42, "column": 14}, "end_point": {"row": 42, "column": 17}}, {"id": 150, "type": "function_definition", "text": "ft_spi_rw(uint8_t data)\n{\n uint8_t i;\n uint8_t temp = 0;\n for (i = 0; i < 8; i++)\n {\n if (data & 0x80)\n {\n GPIOHS_OUT_HIGH(_mosi_num);\n }\n else\n {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n data <<= 1;\n GPIOHS_OUT_HIGH(_sclk_num);\n\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n\n temp <<= 1;\n if (GET_GPIOHS_VALX(_miso_num))\n {\n temp++;\n }\n GPIOHS_OUT_LOWX(_sclk_num);\n\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n }\n return temp;\n}\n\nvoid sof", "parent": 24, "children": [151, 152], "start_point": {"row": 45, "column": 0}, "end_point": {"row": 78, "column": 1}}, {"id": 151, "type": "primitive_type", "text": "ft_spi_", "parent": 150, "children": [], "start_point": {"row": 45, "column": 0}, "end_point": {"row": 45, "column": 7}}, {"id": 152, "type": "function_declarator", "text": "w(uint8_t data)\n{\n uin", "parent": 150, "children": [153, 154], "start_point": {"row": 45, "column": 8}, "end_point": {"row": 45, "column": 33}}, {"id": 153, "type": "identifier", "text": "w(uint8_t d", "parent": 152, "children": [], "start_point": {"row": 45, "column": 8}, "end_point": {"row": 45, "column": 19}}, {"id": 154, "type": "parameter_list", "text": "ata)\n{\n uin", "parent": 152, "children": [155], "start_point": {"row": 45, "column": 19}, "end_point": {"row": 45, "column": 33}}, {"id": 155, "type": "parameter_declaration", "text": "ta)\n{\n ui", "parent": 154, "children": [156, 157], "start_point": {"row": 45, "column": 20}, "end_point": {"row": 45, "column": 32}}, {"id": 156, "type": "primitive_type", "text": "ta)\n{\n ", "parent": 155, "children": [], "start_point": {"row": 45, "column": 20}, "end_point": {"row": 45, "column": 27}}, {"id": 157, "type": "identifier", "text": " ui", "parent": 155, "children": [], "start_point": {"row": 45, "column": 28}, "end_point": {"row": 45, "column": 32}}, {"id": 158, "type": "declaration", "text": "\n uint8", "parent": 150, "children": [159, 160], "start_point": {"row": 47, "column": 4}, "end_point": {"row": 47, "column": 14}}, {"id": 159, "type": "primitive_type", "text": "\n ui", "parent": 158, "children": [], "start_point": {"row": 47, "column": 4}, "end_point": {"row": 47, "column": 11}}, {"id": 160, "type": "identifier", "text": "t", "parent": 158, "children": [], "start_point": {"row": 47, "column": 12}, "end_point": {"row": 47, "column": 13}}, {"id": 161, "type": "declaration", "text": "mp = 0;\n for (", "parent": 150, "children": [162], "start_point": {"row": 48, "column": 4}, "end_point": {"row": 48, "column": 21}}, {"id": 162, "type": "primitive_type", "text": "mp = 0;", "parent": 161, "children": [], "start_point": {"row": 48, "column": 4}, "end_point": {"row": 48, "column": 11}}, {"id": 163, "type": "identifier", "text": " ", "parent": 161, "children": [], "start_point": {"row": 48, "column": 12}, "end_point": {"row": 48, "column": 16}}, {"id": 164, "type": "=", "text": "o", "parent": 161, "children": [], "start_point": {"row": 48, "column": 17}, "end_point": {"row": 48, "column": 18}}, {"id": 165, "type": "number_literal", "text": " ", "parent": 161, "children": [], "start_point": {"row": 48, "column": 19}, "end_point": {"row": 48, "column": 20}}, {"id": 166, "type": "for_statement", "text": "; i < 8; i++)\n {\n if (data & 0x80)\n {\n GPIOHS_OUT_HIGH(_mosi_num);\n }\n else\n {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n data <<= 1;\n GPIOHS_OUT_HIGH(_sclk_num);\n\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n\n temp <<= 1;\n if (GET_GPIOHS_VALX(_miso_num))\n {\n temp++;\n }\n GPIOHS_OUT_LOWX(_sclk_num);\n\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n }\n retur", "parent": 150, "children": [167, 172], "start_point": {"row": 49, "column": 4}, "end_point": {"row": 76, "column": 5}}, {"id": 167, "type": "assignment_expression", "text": " 8; i", "parent": 166, "children": [168, 169], "start_point": {"row": 49, "column": 9}, "end_point": {"row": 49, "column": 14}}, {"id": 168, "type": "identifier", "text": " ", "parent": 167, "children": [], "start_point": {"row": 49, "column": 9}, "end_point": {"row": 49, "column": 10}}, {"id": 169, "type": "number_literal", "text": "i", "parent": 167, "children": [], "start_point": {"row": 49, "column": 13}, "end_point": {"row": 49, "column": 14}}, {"id": 170, "type": "<", "text": " ", "parent": 166, "children": [], "start_point": {"row": 49, "column": 18}, "end_point": {"row": 49, "column": 19}}, {"id": 171, "type": "number_literal", "text": " ", "parent": 166, "children": [], "start_point": {"row": 49, "column": 20}, "end_point": {"row": 49, "column": 21}}, {"id": 172, "type": "update_expression", "text": "\n ", "parent": 166, "children": [173, 174], "start_point": {"row": 49, "column": 23}, "end_point": {"row": 49, "column": 26}}, {"id": 173, "type": "identifier", "text": "\n", "parent": 172, "children": [], "start_point": {"row": 49, "column": 23}, "end_point": {"row": 49, "column": 24}}, {"id": 174, "type": "++", "text": " ", "parent": 172, "children": [], "start_point": {"row": 49, "column": 24}, "end_point": {"row": 49, "column": 26}}, {"id": 175, "type": "if_statement", "text": " 0x80)\n {\n GPIOHS_OUT_HIGH(_mosi_num);\n }\n else\n {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n d", "parent": 166, "children": [176, 184], "start_point": {"row": 51, "column": 8}, "end_point": {"row": 58, "column": 9}}, {"id": 176, "type": "parenthesized_expression", "text": "80)\n {", "parent": 175, "children": [177], "start_point": {"row": 51, "column": 11}, "end_point": {"row": 51, "column": 24}}, {"id": 177, "type": "binary_expression", "text": "0)\n ", "parent": 176, "children": [178, 179, 180], "start_point": {"row": 51, "column": 12}, "end_point": {"row": 51, "column": 23}}, {"id": 178, "type": "identifier", "text": "0)\n ", "parent": 177, "children": [], "start_point": {"row": 51, "column": 12}, "end_point": {"row": 51, "column": 16}}, {"id": 179, "type": "&", "text": " ", "parent": 177, "children": [], "start_point": {"row": 51, "column": 17}, "end_point": {"row": 51, "column": 18}}, {"id": 180, "type": "number_literal", "text": " ", "parent": 177, "children": [], "start_point": {"row": 51, "column": 19}, "end_point": {"row": 51, "column": 23}}, {"id": 181, "type": "call_expression", "text": "_HIGH(_mosi_num);\n ", "parent": 175, "children": [182, 183], "start_point": {"row": 53, "column": 12}, "end_point": {"row": 53, "column": 38}}, {"id": 182, "type": "identifier", "text": "_HIGH(_mosi_num", "parent": 181, "children": [], "start_point": {"row": 53, "column": 12}, "end_point": {"row": 53, "column": 27}}, {"id": 183, "type": "argument_list", "text": ");\n ", "parent": 181, "children": [], "start_point": {"row": 53, "column": 27}, "end_point": {"row": 53, "column": 38}}, {"id": 184, "type": "else_clause", "text": " {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n d", "parent": 175, "children": [], "start_point": {"row": 55, "column": 8}, "end_point": {"row": 58, "column": 9}}, {"id": 185, "type": "call_expression", "text": "_LOWX(_mosi_num);\n ", "parent": 184, "children": [186, 187], "start_point": {"row": 57, "column": 12}, "end_point": {"row": 57, "column": 38}}, {"id": 186, "type": "identifier", "text": "_LOWX(_mosi_num", "parent": 185, "children": [], "start_point": {"row": 57, "column": 12}, "end_point": {"row": 57, "column": 27}}, {"id": 187, "type": "argument_list", "text": ");\n ", "parent": 185, "children": [], "start_point": {"row": 57, "column": 27}, "end_point": {"row": 57, "column": 38}}, {"id": 188, "type": "<<=", "text": " ", "parent": 166, "children": [], "start_point": {"row": 59, "column": 13}, "end_point": {"row": 59, "column": 16}}, {"id": 189, "type": "number_literal", "text": " ", "parent": 166, "children": [], "start_point": {"row": 59, "column": 17}, "end_point": {"row": 59, "column": 18}}, {"id": 190, "type": "call_expression", "text": "_HIGH(_sclk_num);\n\n ", "parent": 166, "children": [191, 192], "start_point": {"row": 60, "column": 8}, "end_point": {"row": 60, "column": 34}}, {"id": 191, "type": "identifier", "text": "_HIGH(_sclk_num", "parent": 190, "children": [], "start_point": {"row": 60, "column": 8}, "end_point": {"row": 60, "column": 23}}, {"id": 192, "type": "argument_list", "text": ");\n\n ", "parent": 190, "children": [], "start_point": {"row": 60, "column": 23}, "end_point": {"row": 60, "column": 34}}, {"id": 193, "type": "gnu_asm_expression", "text": "le(\"nop\");\n ", "parent": 166, "children": [194, 195, 197], "start_point": {"row": 62, "column": 8}, "end_point": {"row": 62, "column": 27}}, {"id": 194, "type": "asm", "text": "le(", "parent": 193, "children": [], "start_point": {"row": 62, "column": 8}, "end_point": {"row": 62, "column": 11}}, {"id": 195, "type": "gnu_asm_qualifier", "text": "nop\");\n ", "parent": 193, "children": [196], "start_point": {"row": 62, "column": 12}, "end_point": {"row": 62, "column": 20}}, {"id": 196, "type": "volatile", "text": "nop\");\n ", "parent": 195, "children": [], "start_point": {"row": 62, "column": 12}, "end_point": {"row": 62, "column": 20}}, {"id": 197, "type": "string_literal", "text": " ", "parent": 193, "children": [], "start_point": {"row": 62, "column": 21}, "end_point": {"row": 62, "column": 26}}, {"id": 198, "type": "gnu_asm_expression", "text": "le(\"nop\");\n ", "parent": 166, "children": [199, 200, 202], "start_point": {"row": 63, "column": 8}, "end_point": {"row": 63, "column": 27}}, {"id": 199, "type": "asm", "text": "le(", "parent": 198, "children": [], "start_point": {"row": 63, "column": 8}, "end_point": {"row": 63, "column": 11}}, {"id": 200, "type": "gnu_asm_qualifier", "text": "nop\");\n ", "parent": 198, "children": [201], "start_point": {"row": 63, "column": 12}, "end_point": {"row": 63, "column": 20}}, {"id": 201, "type": "volatile", "text": "nop\");\n ", "parent": 200, "children": [], "start_point": {"row": 63, "column": 12}, "end_point": {"row": 63, "column": 20}}, {"id": 202, "type": "string_literal", "text": " ", "parent": 198, "children": [], "start_point": {"row": 63, "column": 21}, "end_point": {"row": 63, "column": 26}}, {"id": 203, "type": "gnu_asm_expression", "text": "le(\"nop\");\n\n ", "parent": 166, "children": [204, 205, 207], "start_point": {"row": 64, "column": 8}, "end_point": {"row": 64, "column": 27}}, {"id": 204, "type": "asm", "text": "le(", "parent": 203, "children": [], "start_point": {"row": 64, "column": 8}, "end_point": {"row": 64, "column": 11}}, {"id": 205, "type": "gnu_asm_qualifier", "text": "nop\");\n\n", "parent": 203, "children": [206], "start_point": {"row": 64, "column": 12}, "end_point": {"row": 64, "column": 20}}, {"id": 206, "type": "volatile", "text": "nop\");\n\n", "parent": 205, "children": [], "start_point": {"row": 64, "column": 12}, "end_point": {"row": 64, "column": 20}}, {"id": 207, "type": "string_literal", "text": " ", "parent": 203, "children": [], "start_point": {"row": 64, "column": 21}, "end_point": {"row": 64, "column": 26}}, {"id": 208, "type": "<<=", "text": " ", "parent": 166, "children": [], "start_point": {"row": 66, "column": 13}, "end_point": {"row": 66, "column": 16}}, {"id": 209, "type": "number_literal", "text": " ", "parent": 166, "children": [], "start_point": {"row": 66, "column": 17}, "end_point": {"row": 66, "column": 18}}, {"id": 210, "type": "if_statement", "text": "IOHS_VALX(_miso_num))\n {\n temp++;\n }\n G", "parent": 166, "children": [211], "start_point": {"row": 67, "column": 8}, "end_point": {"row": 70, "column": 9}}, {"id": 211, "type": "parenthesized_expression", "text": "S_VALX(_miso_num))\n {", "parent": 210, "children": [212], "start_point": {"row": 67, "column": 11}, "end_point": {"row": 67, "column": 39}}, {"id": 212, "type": "call_expression", "text": "_VALX(_miso_num))\n ", "parent": 211, "children": [213, 214], "start_point": {"row": 67, "column": 12}, "end_point": {"row": 67, "column": 38}}, {"id": 213, "type": "identifier", "text": "_VALX(_miso_num", "parent": 212, "children": [], "start_point": {"row": 67, "column": 12}, "end_point": {"row": 67, "column": 27}}, {"id": 214, "type": "argument_list", "text": "))\n ", "parent": 212, "children": [], "start_point": {"row": 67, "column": 27}, "end_point": {"row": 67, "column": 38}}, {"id": 215, "type": "update_expression", "text": " ", "parent": 210, "children": [216, 217], "start_point": {"row": 69, "column": 12}, "end_point": {"row": 69, "column": 18}}, {"id": 216, "type": "identifier", "text": " ", "parent": 215, "children": [], "start_point": {"row": 69, "column": 12}, "end_point": {"row": 69, "column": 16}}, {"id": 217, "type": "++", "text": " ", "parent": 215, "children": [], "start_point": {"row": 69, "column": 16}, "end_point": {"row": 69, "column": 18}}, {"id": 218, "type": "call_expression", "text": "_LOWX(_sclk_num);\n\n ", "parent": 166, "children": [219, 220], "start_point": {"row": 71, "column": 8}, "end_point": {"row": 71, "column": 34}}, {"id": 219, "type": "identifier", "text": "_LOWX(_sclk_num", "parent": 218, "children": [], "start_point": {"row": 71, "column": 8}, "end_point": {"row": 71, "column": 23}}, {"id": 220, "type": "argument_list", "text": ");\n\n ", "parent": 218, "children": [], "start_point": {"row": 71, "column": 23}, "end_point": {"row": 71, "column": 34}}, {"id": 221, "type": "gnu_asm_expression", "text": "le(\"nop\");\n ", "parent": 166, "children": [222, 223, 225], "start_point": {"row": 73, "column": 8}, "end_point": {"row": 73, "column": 27}}, {"id": 222, "type": "asm", "text": "le(", "parent": 221, "children": [], "start_point": {"row": 73, "column": 8}, "end_point": {"row": 73, "column": 11}}, {"id": 223, "type": "gnu_asm_qualifier", "text": "nop\");\n ", "parent": 221, "children": [224], "start_point": {"row": 73, "column": 12}, "end_point": {"row": 73, "column": 20}}, {"id": 224, "type": "volatile", "text": "nop\");\n ", "parent": 223, "children": [], "start_point": {"row": 73, "column": 12}, "end_point": {"row": 73, "column": 20}}, {"id": 225, "type": "string_literal", "text": " ", "parent": 221, "children": [], "start_point": {"row": 73, "column": 21}, "end_point": {"row": 73, "column": 26}}, {"id": 226, "type": "gnu_asm_expression", "text": "le(\"nop\");\n ", "parent": 166, "children": [227, 228, 230], "start_point": {"row": 74, "column": 8}, "end_point": {"row": 74, "column": 27}}, {"id": 227, "type": "asm", "text": "le(", "parent": 226, "children": [], "start_point": {"row": 74, "column": 8}, "end_point": {"row": 74, "column": 11}}, {"id": 228, "type": "gnu_asm_qualifier", "text": "nop\");\n ", "parent": 226, "children": [229], "start_point": {"row": 74, "column": 12}, "end_point": {"row": 74, "column": 20}}, {"id": 229, "type": "volatile", "text": "nop\");\n ", "parent": 228, "children": [], "start_point": {"row": 74, "column": 12}, "end_point": {"row": 74, "column": 20}}, {"id": 230, "type": "string_literal", "text": " ", "parent": 226, "children": [], "start_point": {"row": 74, "column": 21}, "end_point": {"row": 74, "column": 26}}, {"id": 231, "type": "gnu_asm_expression", "text": "le(\"nop\");\n }\n ", "parent": 166, "children": [232, 233], "start_point": {"row": 75, "column": 8}, "end_point": {"row": 75, "column": 27}}, {"id": 232, "type": "asm", "text": "le(", "parent": 231, "children": [], "start_point": {"row": 75, "column": 8}, "end_point": {"row": 75, "column": 11}}, {"id": 233, "type": "gnu_asm_qualifier", "text": "nop\");\n ", "parent": 231, "children": [234], "start_point": {"row": 75, "column": 12}, "end_point": {"row": 75, "column": 20}}, {"id": 234, "type": "volatile", "text": "nop\");\n ", "parent": 233, "children": [], "start_point": {"row": 75, "column": 12}, "end_point": {"row": 75, "column": 20}}, {"id": 235, "type": "return_statement", "text": "p;\n}\n\nvoid s", "parent": 150, "children": [236], "start_point": {"row": 77, "column": 4}, "end_point": {"row": 77, "column": 16}}, {"id": 236, "type": "identifier", "text": "oid ", "parent": 235, "children": [], "start_point": {"row": 77, "column": 11}, "end_point": {"row": 77, "column": 15}}, {"id": 237, "type": "function_definition", "text": "spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(\" buffer is null\\r\\n\");\n return;\n }\n\n#if 0\n uint32_t i = 0;\n do\n {\n *(recv + i) = soft_spi_rw(*(send + i));\n i++;\n } while (--len);\n#else\n\n uint32_t i = 0;\n uint8_t *stmp = NULL, sf = 0;\n\n if (send == NULL)\n {\n stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n stmp = send;\n\n if (recv == NULL)\n {\n do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n {\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (sf)\n free(stmp);\n#endif\n}\n\n#else\n\ns", "parent": 24, "children": [238, 239], "start_point": {"row": 80, "column": 0}, "end_point": {"row": 129, "column": 1}}, {"id": 238, "type": "primitive_type", "text": "spi_", "parent": 237, "children": [], "start_point": {"row": 80, "column": 0}, "end_point": {"row": 80, "column": 4}}, {"id": 239, "type": "function_declarator", "text": "w_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if ", "parent": 237, "children": [240, 241], "start_point": {"row": 80, "column": 5}, "end_point": {"row": 80, "column": 64}}, {"id": 240, "type": "identifier", "text": "w_len(uint8_t *", "parent": 239, "children": [], "start_point": {"row": 80, "column": 5}, "end_point": {"row": 80, "column": 20}}, {"id": 241, "type": "parameter_list", "text": "send, uint8_t *recv, uint32_t len)\n{\n if ", "parent": 239, "children": [242, 247, 252], "start_point": {"row": 80, "column": 20}, "end_point": {"row": 80, "column": 64}}, {"id": 242, "type": "parameter_declaration", "text": "end, uint8_t ", "parent": 241, "children": [243, 244], "start_point": {"row": 80, "column": 21}, "end_point": {"row": 80, "column": 34}}, {"id": 243, "type": "primitive_type", "text": "end, ui", "parent": 242, "children": [], "start_point": {"row": 80, "column": 21}, "end_point": {"row": 80, "column": 28}}, {"id": 244, "type": "pointer_declarator", "text": "t8_t ", "parent": 242, "children": [245, 246], "start_point": {"row": 80, "column": 29}, "end_point": {"row": 80, "column": 34}}, {"id": 245, "type": "*", "text": "t", "parent": 244, "children": [], "start_point": {"row": 80, "column": 29}, "end_point": {"row": 80, "column": 30}}, {"id": 246, "type": "identifier", "text": "8_t ", "parent": 244, "children": [], "start_point": {"row": 80, "column": 30}, "end_point": {"row": 80, "column": 34}}, {"id": 247, "type": "parameter_declaration", "text": "ecv, uint32_t", "parent": 241, "children": [248, 249], "start_point": {"row": 80, "column": 36}, "end_point": {"row": 80, "column": 49}}, {"id": 248, "type": "primitive_type", "text": "ecv, ui", "parent": 247, "children": [], "start_point": {"row": 80, "column": 36}, "end_point": {"row": 80, "column": 43}}, {"id": 249, "type": "pointer_declarator", "text": "t32_t", "parent": 247, "children": [250, 251], "start_point": {"row": 80, "column": 44}, "end_point": {"row": 80, "column": 49}}, {"id": 250, "type": "*", "text": "t", "parent": 249, "children": [], "start_point": {"row": 80, "column": 44}, "end_point": {"row": 80, "column": 45}}, {"id": 251, "type": "identifier", "text": "32_t", "parent": 249, "children": [], "start_point": {"row": 80, "column": 45}, "end_point": {"row": 80, "column": 49}}, {"id": 252, "type": "parameter_declaration", "text": "en)\n{\n if", "parent": 241, "children": [253], "start_point": {"row": 80, "column": 51}, "end_point": {"row": 80, "column": 63}}, {"id": 253, "type": "primitive_type", "text": "en)\n{\n ", "parent": 252, "children": [], "start_point": {"row": 80, "column": 51}, "end_point": {"row": 80, "column": 59}}, {"id": 254, "type": "if_statement", "text": "= NULL && recv == NULL)\n {\n printf(\" buffer is null\\r\\n\");\n return;\n }\n\n#if 0\n ", "parent": 237, "children": [255], "start_point": {"row": 82, "column": 4}, "end_point": {"row": 86, "column": 5}}, {"id": 255, "type": "parenthesized_expression", "text": "ULL && recv == NULL)\n {\n ", "parent": 254, "children": [256], "start_point": {"row": 82, "column": 7}, "end_point": {"row": 82, "column": 37}}, {"id": 256, "type": "binary_expression", "text": "LL && recv == NULL)\n {\n ", "parent": 255, "children": [257, 262, 263], "start_point": {"row": 82, "column": 8}, "end_point": {"row": 82, "column": 36}}, {"id": 257, "type": "binary_expression", "text": "LL && recv =", "parent": 256, "children": [258, 259, 260], "start_point": {"row": 82, "column": 8}, "end_point": {"row": 82, "column": 20}}, {"id": 258, "type": "identifier", "text": "LL &", "parent": 257, "children": [], "start_point": {"row": 82, "column": 8}, "end_point": {"row": 82, "column": 12}}, {"id": 259, "type": "==", "text": " r", "parent": 257, "children": [], "start_point": {"row": 82, "column": 13}, "end_point": {"row": 82, "column": 15}}, {"id": 260, "type": "null", "text": "cv =", "parent": 257, "children": [261], "start_point": {"row": 82, "column": 16}, "end_point": {"row": 82, "column": 20}}, {"id": 261, "type": "NULL", "text": "cv =", "parent": 260, "children": [], "start_point": {"row": 82, "column": 16}, "end_point": {"row": 82, "column": 20}}, {"id": 262, "type": "&&", "text": " N", "parent": 256, "children": [], "start_point": {"row": 82, "column": 21}, "end_point": {"row": 82, "column": 23}}, {"id": 263, "type": "binary_expression", "text": "LL)\n {\n ", "parent": 256, "children": [264, 265], "start_point": {"row": 82, "column": 24}, "end_point": {"row": 82, "column": 36}}, {"id": 264, "type": "identifier", "text": "LL)\n", "parent": 263, "children": [], "start_point": {"row": 82, "column": 24}, "end_point": {"row": 82, "column": 28}}, {"id": 265, "type": "==", "text": " ", "parent": 263, "children": [], "start_point": {"row": 82, "column": 29}, "end_point": {"row": 82, "column": 31}}, {"id": 266, "type": "call_expression", "text": "uffer is null\\r\\n\");\n ", "parent": 254, "children": [267, 268], "start_point": {"row": 84, "column": 8}, "end_point": {"row": 84, "column": 37}}, {"id": 267, "type": "identifier", "text": "uffer ", "parent": 266, "children": [], "start_point": {"row": 84, "column": 8}, "end_point": {"row": 84, "column": 14}}, {"id": 268, "type": "argument_list", "text": "is null\\r\\n\");\n ", "parent": 266, "children": [269], "start_point": {"row": 84, "column": 14}, "end_point": {"row": 84, "column": 37}}, {"id": 269, "type": "string_literal", "text": "s null\\r\\n\");\n ", "parent": 268, "children": [270, 271], "start_point": {"row": 84, "column": 15}, "end_point": {"row": 84, "column": 36}}, {"id": 270, "type": "escape_sequence", "text": " ", "parent": 269, "children": [], "start_point": {"row": 84, "column": 31}, "end_point": {"row": 84, "column": 33}}, {"id": 271, "type": "escape_sequence", "text": " ", "parent": 269, "children": [], "start_point": {"row": 84, "column": 33}, "end_point": {"row": 84, "column": 35}}, {"id": 272, "type": "return_statement", "text": " }\n\n#i", "parent": 254, "children": [], "start_point": {"row": 85, "column": 8}, "end_point": {"row": 85, "column": 15}}, {"id": 273, "type": "preproc_if", "text": "uint32_t i = 0;\n do\n {\n *(recv + i) = soft_spi_rw(*(send + i));\n i++;\n } while (--len);\n#else\n\n uint32_t i = 0;\n uint8_t *stmp = NULL, sf = 0;\n\n if (send == NULL)\n {\n stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n stmp = send;\n\n if (recv == NULL)\n {\n do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n {\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (sf)\n free(stmp);\n#endif\n}\n\n#else\n", "parent": 237, "children": [274, 275, 276, 277, 282, 305, 400], "start_point": {"row": 88, "column": 0}, "end_point": {"row": 128, "column": 6}}, {"id": 274, "type": "#if", "text": "uin", "parent": 273, "children": [], "start_point": {"row": 88, "column": 0}, "end_point": {"row": 88, "column": 3}}, {"id": 275, "type": "number_literal", "text": "3", "parent": 273, "children": [], "start_point": {"row": 88, "column": 4}, "end_point": {"row": 88, "column": 5}}, {"id": 276, "type": "\n", "text": "2", "parent": 273, "children": [], "start_point": {"row": 88, "column": 5}, "end_point": {"row": 89, "column": 0}}, {"id": 277, "type": "declaration", "text": " = 0;\n do\n ", "parent": 273, "children": [278], "start_point": {"row": 89, "column": 4}, "end_point": {"row": 89, "column": 19}}, {"id": 278, "type": "primitive_type", "text": " = 0;\n ", "parent": 277, "children": [], "start_point": {"row": 89, "column": 4}, "end_point": {"row": 89, "column": 12}}, {"id": 279, "type": "identifier", "text": " ", "parent": 277, "children": [], "start_point": {"row": 89, "column": 13}, "end_point": {"row": 89, "column": 14}}, {"id": 280, "type": "=", "text": "o", "parent": 277, "children": [], "start_point": {"row": 89, "column": 15}, "end_point": {"row": 89, "column": 16}}, {"id": 281, "type": "number_literal", "text": " ", "parent": 277, "children": [], "start_point": {"row": 89, "column": 17}, "end_point": {"row": 89, "column": 18}}, {"id": 282, "type": "do_statement", "text": " *(recv + i) = soft_spi_rw(*(send + i));\n i++;\n } while (--len);\n#else\n\n ", "parent": 273, "children": [283], "start_point": {"row": 90, "column": 4}, "end_point": {"row": 94, "column": 20}}, {"id": 283, "type": "do", "text": " ", "parent": 282, "children": [], "start_point": {"row": 90, "column": 4}, "end_point": {"row": 90, "column": 6}}, {"id": 284, "type": "assignment_expression", "text": ") = soft_spi_rw(*(send + i));\n ", "parent": 282, "children": [285, 291, 292], "start_point": {"row": 92, "column": 8}, "end_point": {"row": 92, "column": 46}}, {"id": 285, "type": "pointer_expression", "text": ") = soft_sp", "parent": 284, "children": [286], "start_point": {"row": 92, "column": 8}, "end_point": {"row": 92, "column": 19}}, {"id": 286, "type": "parenthesized_expression", "text": " = soft_sp", "parent": 285, "children": [287], "start_point": {"row": 92, "column": 9}, "end_point": {"row": 92, "column": 19}}, {"id": 287, "type": "binary_expression", "text": "= soft_s", "parent": 286, "children": [288, 289, 290], "start_point": {"row": 92, "column": 10}, "end_point": {"row": 92, "column": 18}}, {"id": 288, "type": "identifier", "text": "= so", "parent": 287, "children": [], "start_point": {"row": 92, "column": 10}, "end_point": {"row": 92, "column": 14}}, {"id": 289, "type": "+", "text": "t", "parent": 287, "children": [], "start_point": {"row": 92, "column": 15}, "end_point": {"row": 92, "column": 16}}, {"id": 290, "type": "identifier", "text": "s", "parent": 287, "children": [], "start_point": {"row": 92, "column": 17}, "end_point": {"row": 92, "column": 18}}, {"id": 291, "type": "=", "text": "_", "parent": 284, "children": [], "start_point": {"row": 92, "column": 20}, "end_point": {"row": 92, "column": 21}}, {"id": 292, "type": "call_expression", "text": "w(*(send + i));\n ", "parent": 284, "children": [293, 294], "start_point": {"row": 92, "column": 22}, "end_point": {"row": 92, "column": 46}}, {"id": 293, "type": "identifier", "text": "w(*(send + ", "parent": 292, "children": [], "start_point": {"row": 92, "column": 22}, "end_point": {"row": 92, "column": 33}}, {"id": 294, "type": "argument_list", "text": "i));\n ", "parent": 292, "children": [295], "start_point": {"row": 92, "column": 33}, "end_point": {"row": 92, "column": 46}}, {"id": 295, "type": "pointer_expression", "text": "));\n ", "parent": 294, "children": [296], "start_point": {"row": 92, "column": 34}, "end_point": {"row": 92, "column": 45}}, {"id": 296, "type": "parenthesized_expression", "text": ");\n ", "parent": 295, "children": [], "start_point": {"row": 92, "column": 35}, "end_point": {"row": 92, "column": 45}}, {"id": 297, "type": "+", "text": " ", "parent": 296, "children": [], "start_point": {"row": 92, "column": 41}, "end_point": {"row": 92, "column": 42}}, {"id": 298, "type": "identifier", "text": " ", "parent": 296, "children": [], "start_point": {"row": 92, "column": 43}, "end_point": {"row": 92, "column": 44}}, {"id": 299, "type": "update_expression", "text": " wh", "parent": 282, "children": [300, 301], "start_point": {"row": 93, "column": 8}, "end_point": {"row": 93, "column": 11}}, {"id": 300, "type": "identifier", "text": " ", "parent": 299, "children": [], "start_point": {"row": 93, "column": 8}, "end_point": {"row": 93, "column": 9}}, {"id": 301, "type": "++", "text": "wh", "parent": 299, "children": [], "start_point": {"row": 93, "column": 9}, "end_point": {"row": 93, "column": 11}}, {"id": 302, "type": "update_expression", "text": "lse\n\n", "parent": 282, "children": [303, 304], "start_point": {"row": 94, "column": 13}, "end_point": {"row": 94, "column": 18}}, {"id": 303, "type": "--", "text": "ls", "parent": 302, "children": [], "start_point": {"row": 94, "column": 13}, "end_point": {"row": 94, "column": 15}}, {"id": 304, "type": "identifier", "text": "e\n\n", "parent": 302, "children": [], "start_point": {"row": 94, "column": 15}, "end_point": {"row": 94, "column": 18}}, {"id": 305, "type": "preproc_else", "text": " uint32_t i = 0;\n uint8_t *stmp = NULL, sf = 0;\n\n if (send == NULL)\n {\n stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n stmp = send;\n\n if (recv == NULL)\n {\n do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n {\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (sf)\n free(stmp);\n#endif\n}\n", "parent": 273, "children": [306, 307, 313, 325, 355, 393], "start_point": {"row": 95, "column": 0}, "end_point": {"row": 127, "column": 19}}, {"id": 306, "type": "#else", "text": " uint", "parent": 305, "children": [], "start_point": {"row": 95, "column": 0}, "end_point": {"row": 95, "column": 5}}, {"id": 307, "type": "declaration", "text": " = 0;\n uint8", "parent": 305, "children": [308, 309], "start_point": {"row": 97, "column": 4}, "end_point": {"row": 97, "column": 19}}, {"id": 308, "type": "primitive_type", "text": " = 0;\n ", "parent": 307, "children": [], "start_point": {"row": 97, "column": 4}, "end_point": {"row": 97, "column": 12}}, {"id": 309, "type": "init_declarator", "text": " uint", "parent": 307, "children": [310, 311, 312], "start_point": {"row": 97, "column": 13}, "end_point": {"row": 97, "column": 18}}, {"id": 310, "type": "identifier", "text": " ", "parent": 309, "children": [], "start_point": {"row": 97, "column": 13}, "end_point": {"row": 97, "column": 14}}, {"id": 311, "type": "=", "text": "i", "parent": 309, "children": [], "start_point": {"row": 97, "column": 15}, "end_point": {"row": 97, "column": 16}}, {"id": 312, "type": "number_literal", "text": "t", "parent": 309, "children": [], "start_point": {"row": 97, "column": 17}, "end_point": {"row": 97, "column": 18}}, {"id": 313, "type": "declaration", "text": "tmp = NULL, sf = 0;\n\n if (", "parent": 305, "children": [314, 315], "start_point": {"row": 98, "column": 4}, "end_point": {"row": 98, "column": 33}}, {"id": 314, "type": "primitive_type", "text": "tmp = N", "parent": 313, "children": [], "start_point": {"row": 98, "column": 4}, "end_point": {"row": 98, "column": 11}}, {"id": 315, "type": "init_declarator", "text": "LL, sf = 0;\n", "parent": 313, "children": [316, 319, 320], "start_point": {"row": 98, "column": 12}, "end_point": {"row": 98, "column": 24}}, {"id": 316, "type": "pointer_declarator", "text": "LL, s", "parent": 315, "children": [317, 318], "start_point": {"row": 98, "column": 12}, "end_point": {"row": 98, "column": 17}}, {"id": 317, "type": "*", "text": "L", "parent": 316, "children": [], "start_point": {"row": 98, "column": 12}, "end_point": {"row": 98, "column": 13}}, {"id": 318, "type": "identifier", "text": "L, s", "parent": 316, "children": [], "start_point": {"row": 98, "column": 13}, "end_point": {"row": 98, "column": 17}}, {"id": 319, "type": "=", "text": " ", "parent": 315, "children": [], "start_point": {"row": 98, "column": 18}, "end_point": {"row": 98, "column": 19}}, {"id": 320, "type": "null", "text": " 0;\n", "parent": 315, "children": [321], "start_point": {"row": 98, "column": 20}, "end_point": {"row": 98, "column": 24}}, {"id": 321, "type": "NULL", "text": " 0;\n", "parent": 320, "children": [], "start_point": {"row": 98, "column": 20}, "end_point": {"row": 98, "column": 24}}, {"id": 322, "type": "identifier", "text": " ", "parent": 313, "children": [], "start_point": {"row": 98, "column": 26}, "end_point": {"row": 98, "column": 28}}, {"id": 323, "type": "=", "text": "i", "parent": 313, "children": [], "start_point": {"row": 98, "column": 29}, "end_point": {"row": 98, "column": 30}}, {"id": 324, "type": "number_literal", "text": " ", "parent": 313, "children": [], "start_point": {"row": 98, "column": 31}, "end_point": {"row": 98, "column": 32}}, {"id": 325, "type": "if_statement", "text": "= NULL)\n {\n stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n stmp = send;\n\n if (", "parent": 305, "children": [326, 351], "start_point": {"row": 100, "column": 4}, "end_point": {"row": 107, "column": 20}}, {"id": 326, "type": "parenthesized_expression", "text": "ULL)\n {\n ", "parent": 325, "children": [327], "start_point": {"row": 100, "column": 7}, "end_point": {"row": 100, "column": 21}}, {"id": 327, "type": "binary_expression", "text": "LL)\n {\n ", "parent": 326, "children": [328, 329], "start_point": {"row": 100, "column": 8}, "end_point": {"row": 100, "column": 20}}, {"id": 328, "type": "identifier", "text": "LL)\n", "parent": 327, "children": [], "start_point": {"row": 100, "column": 8}, "end_point": {"row": 100, "column": 12}}, {"id": 329, "type": "==", "text": " ", "parent": 327, "children": [], "start_point": {"row": 100, "column": 13}, "end_point": {"row": 100, "column": 15}}, {"id": 330, "type": "assignment_expression", "text": "nt8_t *)malloc(len * sizeof(uint8_t));\n ", "parent": 325, "children": [331, 332, 333], "start_point": {"row": 102, "column": 8}, "end_point": {"row": 102, "column": 55}}, {"id": 331, "type": "identifier", "text": "nt8_", "parent": 330, "children": [], "start_point": {"row": 102, "column": 8}, "end_point": {"row": 102, "column": 12}}, {"id": 332, "type": "=", "text": " ", "parent": 330, "children": [], "start_point": {"row": 102, "column": 13}, "end_point": {"row": 102, "column": 14}}, {"id": 333, "type": "cast_expression", "text": ")malloc(len * sizeof(uint8_t));\n ", "parent": 330, "children": [334, 338], "start_point": {"row": 102, "column": 15}, "end_point": {"row": 102, "column": 55}}, {"id": 334, "type": "type_descriptor", "text": "malloc(le", "parent": 333, "children": [335, 336], "start_point": {"row": 102, "column": 16}, "end_point": {"row": 102, "column": 25}}, {"id": 335, "type": "primitive_type", "text": "malloc(", "parent": 334, "children": [], "start_point": {"row": 102, "column": 16}, "end_point": {"row": 102, "column": 23}}, {"id": 336, "type": "abstract_pointer_declarator", "text": "e", "parent": 334, "children": [337], "start_point": {"row": 102, "column": 24}, "end_point": {"row": 102, "column": 25}}, {"id": 337, "type": "*", "text": "e", "parent": 336, "children": [], "start_point": {"row": 102, "column": 24}, "end_point": {"row": 102, "column": 25}}, {"id": 338, "type": "call_expression", "text": " * sizeof(uint8_t));\n ", "parent": 333, "children": [339, 340], "start_point": {"row": 102, "column": 26}, "end_point": {"row": 102, "column": 55}}, {"id": 339, "type": "identifier", "text": " * siz", "parent": 338, "children": [], "start_point": {"row": 102, "column": 26}, "end_point": {"row": 102, "column": 32}}, {"id": 340, "type": "argument_list", "text": "eof(uint8_t));\n ", "parent": 338, "children": [341], "start_point": {"row": 102, "column": 32}, "end_point": {"row": 102, "column": 55}}, {"id": 341, "type": "binary_expression", "text": "of(uint8_t));\n ", "parent": 340, "children": [342, 343, 344], "start_point": {"row": 102, "column": 33}, "end_point": {"row": 102, "column": 54}}, {"id": 342, "type": "identifier", "text": "of(", "parent": 341, "children": [], "start_point": {"row": 102, "column": 33}, "end_point": {"row": 102, "column": 36}}, {"id": 343, "type": "*", "text": "i", "parent": 341, "children": [], "start_point": {"row": 102, "column": 37}, "end_point": {"row": 102, "column": 38}}, {"id": 344, "type": "sizeof_expression", "text": "t8_t));\n ", "parent": 341, "children": [345, 346], "start_point": {"row": 102, "column": 39}, "end_point": {"row": 102, "column": 54}}, {"id": 345, "type": "sizeof", "text": "t8_t))", "parent": 344, "children": [], "start_point": {"row": 102, "column": 39}, "end_point": {"row": 102, "column": 45}}, {"id": 346, "type": "type_descriptor", "text": "\n ", "parent": 344, "children": [347], "start_point": {"row": 102, "column": 46}, "end_point": {"row": 102, "column": 53}}, {"id": 347, "type": "primitive_type", "text": "\n ", "parent": 346, "children": [], "start_point": {"row": 102, "column": 46}, "end_point": {"row": 102, "column": 53}}, {"id": 348, "type": "identifier", "text": " ", "parent": 325, "children": [], "start_point": {"row": 104, "column": 8}, "end_point": {"row": 104, "column": 10}}, {"id": 349, "type": "=", "text": "\n", "parent": 325, "children": [], "start_point": {"row": 104, "column": 11}, "end_point": {"row": 104, "column": 12}}, {"id": 350, "type": "number_literal", "text": " ", "parent": 325, "children": [], "start_point": {"row": 104, "column": 13}, "end_point": {"row": 104, "column": 14}}, {"id": 351, "type": "else_clause", "text": " stmp = send;\n\n if (", "parent": 325, "children": [], "start_point": {"row": 106, "column": 4}, "end_point": {"row": 107, "column": 20}}, {"id": 352, "type": "assignment_expression", "text": "d;\n\n if ", "parent": 351, "children": [353, 354], "start_point": {"row": 107, "column": 8}, "end_point": {"row": 107, "column": 19}}, {"id": 353, "type": "identifier", "text": "d;\n\n", "parent": 352, "children": [], "start_point": {"row": 107, "column": 8}, "end_point": {"row": 107, "column": 12}}, {"id": 354, "type": "=", "text": " ", "parent": 352, "children": [], "start_point": {"row": 107, "column": 13}, "end_point": {"row": 107, "column": 14}}, {"id": 355, "type": "if_statement", "text": "= NULL)\n {\n do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n {\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (", "parent": 305, "children": [356, 372], "start_point": {"row": 109, "column": 4}, "end_point": {"row": 124, "column": 5}}, {"id": 356, "type": "parenthesized_expression", "text": "ULL)\n {\n ", "parent": 355, "children": [357], "start_point": {"row": 109, "column": 7}, "end_point": {"row": 109, "column": 21}}, {"id": 357, "type": "binary_expression", "text": "LL)\n {\n ", "parent": 356, "children": [358, 359], "start_point": {"row": 109, "column": 8}, "end_point": {"row": 109, "column": 20}}, {"id": 358, "type": "identifier", "text": "LL)\n", "parent": 357, "children": [], "start_point": {"row": 109, "column": 8}, "end_point": {"row": 109, "column": 12}}, {"id": 359, "type": "==", "text": " ", "parent": 357, "children": [], "start_point": {"row": 109, "column": 13}, "end_point": {"row": 109, "column": 15}}, {"id": 360, "type": "do_statement", "text": " {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n ", "parent": 355, "children": [], "start_point": {"row": 111, "column": 8}, "end_point": {"row": 115, "column": 24}}, {"id": 361, "type": "call_expression", "text": "w(*(stmp + i));\n ", "parent": 360, "children": [362, 363], "start_point": {"row": 113, "column": 12}, "end_point": {"row": 113, "column": 36}}, {"id": 362, "type": "identifier", "text": "w(*(stmp + ", "parent": 361, "children": [], "start_point": {"row": 113, "column": 12}, "end_point": {"row": 113, "column": 23}}, {"id": 363, "type": "argument_list", "text": "i));\n ", "parent": 361, "children": [364], "start_point": {"row": 113, "column": 23}, "end_point": {"row": 113, "column": 36}}, {"id": 364, "type": "pointer_expression", "text": "));\n ", "parent": 363, "children": [365], "start_point": {"row": 113, "column": 24}, "end_point": {"row": 113, "column": 35}}, {"id": 365, "type": "parenthesized_expression", "text": ");\n ", "parent": 364, "children": [], "start_point": {"row": 113, "column": 25}, "end_point": {"row": 113, "column": 35}}, {"id": 366, "type": "+", "text": " ", "parent": 365, "children": [], "start_point": {"row": 113, "column": 31}, "end_point": {"row": 113, "column": 32}}, {"id": 367, "type": "identifier", "text": " ", "parent": 365, "children": [], "start_point": {"row": 113, "column": 33}, "end_point": {"row": 113, "column": 34}}, {"id": 368, "type": "update_expression", "text": " ", "parent": 360, "children": [369, 370], "start_point": {"row": 114, "column": 12}, "end_point": {"row": 114, "column": 15}}, {"id": 369, "type": "identifier", "text": " ", "parent": 368, "children": [], "start_point": {"row": 114, "column": 12}, "end_point": {"row": 114, "column": 13}}, {"id": 370, "type": "++", "text": " ", "parent": 368, "children": [], "start_point": {"row": 114, "column": 13}, "end_point": {"row": 114, "column": 15}}, {"id": 371, "type": "--", "text": " ", "parent": 360, "children": [], "start_point": {"row": 115, "column": 17}, "end_point": {"row": 115, "column": 19}}, {"id": 372, "type": "else_clause", "text": "\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (", "parent": 355, "children": [], "start_point": {"row": 117, "column": 4}, "end_point": {"row": 124, "column": 5}}, {"id": 373, "type": "do_statement", "text": " {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n ", "parent": 372, "children": [], "start_point": {"row": 119, "column": 8}, "end_point": {"row": 123, "column": 24}}, {"id": 374, "type": "assignment_expression", "text": ") = soft_spi_rw(*(stmp + i));\n ", "parent": 373, "children": [375, 381, 382], "start_point": {"row": 121, "column": 12}, "end_point": {"row": 121, "column": 50}}, {"id": 375, "type": "pointer_expression", "text": ") = soft_sp", "parent": 374, "children": [376], "start_point": {"row": 121, "column": 12}, "end_point": {"row": 121, "column": 23}}, {"id": 376, "type": "parenthesized_expression", "text": " = soft_sp", "parent": 375, "children": [377], "start_point": {"row": 121, "column": 13}, "end_point": {"row": 121, "column": 23}}, {"id": 377, "type": "binary_expression", "text": "= soft_s", "parent": 376, "children": [378, 379, 380], "start_point": {"row": 121, "column": 14}, "end_point": {"row": 121, "column": 22}}, {"id": 378, "type": "identifier", "text": "= so", "parent": 377, "children": [], "start_point": {"row": 121, "column": 14}, "end_point": {"row": 121, "column": 18}}, {"id": 379, "type": "+", "text": "t", "parent": 377, "children": [], "start_point": {"row": 121, "column": 19}, "end_point": {"row": 121, "column": 20}}, {"id": 380, "type": "identifier", "text": "s", "parent": 377, "children": [], "start_point": {"row": 121, "column": 21}, "end_point": {"row": 121, "column": 22}}, {"id": 381, "type": "=", "text": "_", "parent": 374, "children": [], "start_point": {"row": 121, "column": 24}, "end_point": {"row": 121, "column": 25}}, {"id": 382, "type": "call_expression", "text": "w(*(stmp + i));\n ", "parent": 374, "children": [383, 384], "start_point": {"row": 121, "column": 26}, "end_point": {"row": 121, "column": 50}}, {"id": 383, "type": "identifier", "text": "w(*(stmp + ", "parent": 382, "children": [], "start_point": {"row": 121, "column": 26}, "end_point": {"row": 121, "column": 37}}, {"id": 384, "type": "argument_list", "text": "i));\n ", "parent": 382, "children": [385], "start_point": {"row": 121, "column": 37}, "end_point": {"row": 121, "column": 50}}, {"id": 385, "type": "pointer_expression", "text": "));\n ", "parent": 384, "children": [386], "start_point": {"row": 121, "column": 38}, "end_point": {"row": 121, "column": 49}}, {"id": 386, "type": "parenthesized_expression", "text": ");\n ", "parent": 385, "children": [], "start_point": {"row": 121, "column": 39}, "end_point": {"row": 121, "column": 49}}, {"id": 387, "type": "+", "text": " ", "parent": 386, "children": [], "start_point": {"row": 121, "column": 45}, "end_point": {"row": 121, "column": 46}}, {"id": 388, "type": "identifier", "text": " ", "parent": 386, "children": [], "start_point": {"row": 121, "column": 47}, "end_point": {"row": 121, "column": 48}}, {"id": 389, "type": "update_expression", "text": " ", "parent": 373, "children": [390, 391], "start_point": {"row": 122, "column": 12}, "end_point": {"row": 122, "column": 15}}, {"id": 390, "type": "identifier", "text": " ", "parent": 389, "children": [], "start_point": {"row": 122, "column": 12}, "end_point": {"row": 122, "column": 13}}, {"id": 391, "type": "++", "text": " ", "parent": 389, "children": [], "start_point": {"row": 122, "column": 13}, "end_point": {"row": 122, "column": 15}}, {"id": 392, "type": "--", "text": " ", "parent": 373, "children": [], "start_point": {"row": 123, "column": 17}, "end_point": {"row": 123, "column": 19}}, {"id": 393, "type": "if_statement", "text": " free(stmp);\n#endif\n}\n", "parent": 305, "children": [394], "start_point": {"row": 126, "column": 4}, "end_point": {"row": 127, "column": 19}}, {"id": 394, "type": "parenthesized_expression", "text": " f", "parent": 393, "children": [395], "start_point": {"row": 126, "column": 7}, "end_point": {"row": 126, "column": 11}}, {"id": 395, "type": "identifier", "text": " ", "parent": 394, "children": [], "start_point": {"row": 126, "column": 8}, "end_point": {"row": 126, "column": 10}}, {"id": 396, "type": "call_expression", "text": ";\n#endif\n}", "parent": 393, "children": [397, 398], "start_point": {"row": 127, "column": 8}, "end_point": {"row": 127, "column": 18}}, {"id": 397, "type": "identifier", "text": ";\n#e", "parent": 396, "children": [], "start_point": {"row": 127, "column": 8}, "end_point": {"row": 127, "column": 12}}, {"id": 398, "type": "argument_list", "text": "ndif\n}", "parent": 396, "children": [399], "start_point": {"row": 127, "column": 12}, "end_point": {"row": 127, "column": 18}}, {"id": 399, "type": "identifier", "text": "dif\n", "parent": 398, "children": [], "start_point": {"row": 127, "column": 13}, "end_point": {"row": 127, "column": 17}}, {"id": 400, "type": "#endif", "text": "#else\n", "parent": 273, "children": [], "start_point": {"row": 128, "column": 0}, "end_point": {"row": 128, "column": 6}}, {"id": 401, "type": "preproc_else", "text": "tic spi_transfer_width_t sipeed_spi_get_frame_size(size_t data_bit_length)\n{\n if (data_bit_length < 8)\n return SPI_TRANS_CHAR;\n else if (data_bit_length < 16)\n return SPI_TRANS_SHORT;\n return SPI_TRANS_INT;\n}\n\nstatic void sipeed_spi_set_tmod(uint8_t spi_num, uint32_t tmod)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n volatile spi_t *spi_handle = spi[spi_num];\n uint8_t tmod_offset = 0;\n switch (spi_num)\n {\n case 0:\n case 1:\n tmod_offset = 8;\n break;\n case 2:\n configASSERT(!\"Spi Bus 2 Not Support!\");\n break;\n case 3:\n default:\n tmod_offset = 10;\n break;\n }\n set_bit(&spi_handle->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstatic void sipeed_spi_transfer_data_standard(spi_device_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_buff, uint8_t *rx_buff, size_t len)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n configASSERT(len > 0);\n size_t index, fifo_len;\n size_t rx_len = len;\n size_t tx_len = rx_len;\n sipeed_spi_set_tmod(spi_num, SPI_TMOD_TRANS_RECV);\n\n volatile spi_t *spi_handle = spi[spi_num];\n\n uint8_t dfs_offset;\n switch (spi_num)\n {\n case 0:\n case 1:\n dfs_offset = 16;\n break;\n case 2:\n configASSERT(!\"Spi Bus 2 Not Support!\");\n break;\n case 3:\n default:\n dfs_offset = 0;\n break;\n }\n uint32_t data_bit_length = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F;\n spi_transfer_width_t frame_width = sipeed_spi_get_frame_size(data_bit_length);\n spi_handle->ctrlr1 = (uint32_t)(tx_len / frame_width - 1);\n spi_handle->ssienr = 0x01;\n spi_handle->ser = 1U << chip_select;\n uint32_t i = 0;\n while (tx_len)\n {\n fifo_len = 32 - spi_handle->txflr;\n fifo_len = fifo_len < tx_len ? fifo_len : tx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n tx_len -= fifo_len;\n }\n\n while ((spi_handle->sr & 0x05) != 0x04)\n ;\n i = 0;\n while (rx_len)\n {\n fifo_len = spi_handle->rxflr;\n fifo_len = fifo_len < rx_len ? fifo_len : rx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n rx_len -= fifo_len;\n }\n spi_handle->ser = 0x00;\n spi_handle->ssienr = 0x00;\n}\n\n/* SPI\u7aef\u53e3\u521d\u59cb\u5316 */\nvoid soft_spi_init(void)\n{\n printf(\"hard spi\\r\\n\");\n //cs\n gpiohs_set_drive_mode(ESP32_SPI_CSX_HS_NUM, GPIO_DM_OUTPUT);\n gpiohs_set_pin(ESP32_SPI_CSX_HS_NUM, 1);\n //init SPI_DEVICE_1\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf(\"set spi clk:%d\\r\\n\", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}\n\nuint8_t soft_spi_rw(uint8_t data)\n{\n uint8_t c;\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nvoid soft_spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(\" buffer is null\\r\\n\");\n return;\n }\n\n#if 0\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only send\n if (send && recv == NULL)\n {\n spi_send_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n }\n\n //only recv\n if (send == NULL && recv)\n {\n spi_receive_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n }\n\n //send and recv\n if (send && recv)\n {\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n }\n return;\n}\n\n#endif\n\nuint64_t g", "parent": 24, "children": [402, 403, 431, 525, 1033, 1078, 1101], "start_point": {"row": 131, "column": 0}, "end_point": {"row": 303, "column": 1}}, {"id": 402, "type": "#else", "text": "tic s", "parent": 401, "children": [], "start_point": {"row": 131, "column": 0}, "end_point": {"row": 131, "column": 5}}, {"id": 403, "type": "function_definition", "text": "_transfer_width_t sipeed_spi_get_frame_size(size_t data_bit_length)\n{\n if (data_bit_length < 8)\n return SPI_TRANS_CHAR;\n else if (data_bit_length < 16)\n return SPI_TRANS_SHORT;\n return SPI_TRANS_INT;\n}\n\nstatic v", "parent": 401, "children": [404, 405, 406], "start_point": {"row": 133, "column": 0}, "end_point": {"row": 140, "column": 1}}, {"id": 404, "type": "storage_class_specifier", "text": "_trans", "parent": 403, "children": [], "start_point": {"row": 133, "column": 0}, "end_point": {"row": 133, "column": 6}}, {"id": 405, "type": "type_identifier", "text": "er_width_t sipeed_sp", "parent": 403, "children": [], "start_point": {"row": 133, "column": 7}, "end_point": {"row": 133, "column": 27}}, {"id": 406, "type": "function_declarator", "text": "_get_frame_size(size_t data_bit_length)\n{\n if ", "parent": 403, "children": [407, 408], "start_point": {"row": 133, "column": 28}, "end_point": {"row": 133, "column": 77}}, {"id": 407, "type": "identifier", "text": "_get_frame_size(size_t da", "parent": 406, "children": [], "start_point": {"row": 133, "column": 28}, "end_point": {"row": 133, "column": 53}}, {"id": 408, "type": "parameter_list", "text": "ta_bit_length)\n{\n if ", "parent": 406, "children": [409], "start_point": {"row": 133, "column": 53}, "end_point": {"row": 133, "column": 77}}, {"id": 409, "type": "parameter_declaration", "text": "a_bit_length)\n{\n if", "parent": 408, "children": [410, 411], "start_point": {"row": 133, "column": 54}, "end_point": {"row": 133, "column": 76}}, {"id": 410, "type": "primitive_type", "text": "a_bit_", "parent": 409, "children": [], "start_point": {"row": 133, "column": 54}, "end_point": {"row": 133, "column": 60}}, {"id": 411, "type": "identifier", "text": "ength)\n{\n if", "parent": 409, "children": [], "start_point": {"row": 133, "column": 61}, "end_point": {"row": 133, "column": 76}}, {"id": 412, "type": "if_statement", "text": "it_length < 8)\n return SPI_TRANS_CHAR;\n else if (data_bit_length < 16)\n return SPI_TRANS_SHORT;\n retur", "parent": 403, "children": [413, 418, 420], "start_point": {"row": 135, "column": 4}, "end_point": {"row": 138, "column": 31}}, {"id": 413, "type": "parenthesized_expression", "text": "length < 8)\n r", "parent": 412, "children": [414], "start_point": {"row": 135, "column": 7}, "end_point": {"row": 135, "column": 28}}, {"id": 414, "type": "binary_expression", "text": "ength < 8)\n ", "parent": 413, "children": [415, 416, 417], "start_point": {"row": 135, "column": 8}, "end_point": {"row": 135, "column": 27}}, {"id": 415, "type": "identifier", "text": "ength < 8)\n ", "parent": 414, "children": [], "start_point": {"row": 135, "column": 8}, "end_point": {"row": 135, "column": 23}}, {"id": 416, "type": "<", "text": " ", "parent": 414, "children": [], "start_point": {"row": 135, "column": 24}, "end_point": {"row": 135, "column": 25}}, {"id": 417, "type": "number_literal", "text": " ", "parent": 414, "children": [], "start_point": {"row": 135, "column": 26}, "end_point": {"row": 135, "column": 27}}, {"id": 418, "type": "return_statement", "text": "_TRANS_CHAR;\n else ", "parent": 412, "children": [419], "start_point": {"row": 136, "column": 8}, "end_point": {"row": 136, "column": 30}}, {"id": 419, "type": "identifier", "text": "CHAR;\n else", "parent": 418, "children": [], "start_point": {"row": 136, "column": 15}, "end_point": {"row": 136, "column": 29}}, {"id": 420, "type": "else_clause", "text": "ata_bit_length < 16)\n return SPI_TRANS_SHORT;\n retur", "parent": 412, "children": [421], "start_point": {"row": 137, "column": 4}, "end_point": {"row": 138, "column": 31}}, {"id": 421, "type": "if_statement", "text": "it_length < 16)\n return SPI_TRANS_SHORT;\n retur", "parent": 420, "children": [422, 427], "start_point": {"row": 137, "column": 9}, "end_point": {"row": 138, "column": 31}}, {"id": 422, "type": "parenthesized_expression", "text": "length < 16)\n r", "parent": 421, "children": [423], "start_point": {"row": 137, "column": 12}, "end_point": {"row": 137, "column": 34}}, {"id": 423, "type": "binary_expression", "text": "ength < 16)\n ", "parent": 422, "children": [424, 425, 426], "start_point": {"row": 137, "column": 13}, "end_point": {"row": 137, "column": 33}}, {"id": 424, "type": "identifier", "text": "ength < 16)\n ", "parent": 423, "children": [], "start_point": {"row": 137, "column": 13}, "end_point": {"row": 137, "column": 28}}, {"id": 425, "type": "<", "text": " ", "parent": 423, "children": [], "start_point": {"row": 137, "column": 29}, "end_point": {"row": 137, "column": 30}}, {"id": 426, "type": "number_literal", "text": " ", "parent": 423, "children": [], "start_point": {"row": 137, "column": 31}, "end_point": {"row": 137, "column": 33}}, {"id": 427, "type": "return_statement", "text": "_TRANS_SHORT;\n retur", "parent": 421, "children": [428], "start_point": {"row": 138, "column": 8}, "end_point": {"row": 138, "column": 31}}, {"id": 428, "type": "identifier", "text": "SHORT;\n retu", "parent": 427, "children": [], "start_point": {"row": 138, "column": 15}, "end_point": {"row": 138, "column": 30}}, {"id": 429, "type": "return_statement", "text": "_TRANS_INT;\n}\n\nstatic", "parent": 403, "children": [430], "start_point": {"row": 139, "column": 4}, "end_point": {"row": 139, "column": 25}}, {"id": 430, "type": "identifier", "text": "INT;\n}\n\nstati", "parent": 429, "children": [], "start_point": {"row": 139, "column": 11}, "end_point": {"row": 139, "column": 24}}, {"id": 431, "type": "function_definition", "text": "d sipeed_spi_set_tmod(uint8_t spi_num, uint32_t tmod)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n volatile spi_t *spi_handle = spi[spi_num];\n uint8_t tmod_offset = 0;\n switch (spi_num)\n {\n case 0:\n case 1:\n tmod_offset = 8;\n break;\n case 2:\n configASSERT(!\"Spi Bus 2 Not Support!\");\n break;\n case 3:\n default:\n tmod_offset = 10;\n break;\n }\n set_bit(&spi_handle->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstatic v", "parent": 401, "children": [432, 433, 434], "start_point": {"row": 142, "column": 0}, "end_point": {"row": 162, "column": 1}}, {"id": 432, "type": "storage_class_specifier", "text": "d sipe", "parent": 431, "children": [], "start_point": {"row": 142, "column": 0}, "end_point": {"row": 142, "column": 6}}, {"id": 433, "type": "primitive_type", "text": "d_sp", "parent": 431, "children": [], "start_point": {"row": 142, "column": 7}, "end_point": {"row": 142, "column": 11}}, {"id": 434, "type": "function_declarator", "text": "_set_tmod(uint8_t spi_num, uint32_t tmod)\n{\n con", "parent": 431, "children": [435, 436], "start_point": {"row": 142, "column": 12}, "end_point": {"row": 142, "column": 63}}, {"id": 435, "type": "identifier", "text": "_set_tmod(uint8_t s", "parent": 434, "children": [], "start_point": {"row": 142, "column": 12}, "end_point": {"row": 142, "column": 31}}, {"id": 436, "type": "parameter_list", "text": "pi_num, uint32_t tmod)\n{\n con", "parent": 434, "children": [437, 440], "start_point": {"row": 142, "column": 31}, "end_point": {"row": 142, "column": 63}}, {"id": 437, "type": "parameter_declaration", "text": "i_num, uint32_t", "parent": 436, "children": [438, 439], "start_point": {"row": 142, "column": 32}, "end_point": {"row": 142, "column": 47}}, {"id": 438, "type": "primitive_type", "text": "i_num, ", "parent": 437, "children": [], "start_point": {"row": 142, "column": 32}, "end_point": {"row": 142, "column": 39}}, {"id": 439, "type": "identifier", "text": "int32_t", "parent": 437, "children": [], "start_point": {"row": 142, "column": 40}, "end_point": {"row": 142, "column": 47}}, {"id": 440, "type": "parameter_declaration", "text": "mod)\n{\n co", "parent": 436, "children": [441, 442], "start_point": {"row": 142, "column": 49}, "end_point": {"row": 142, "column": 62}}, {"id": 441, "type": "primitive_type", "text": "mod)\n{\n ", "parent": 440, "children": [], "start_point": {"row": 142, "column": 49}, "end_point": {"row": 142, "column": 57}}, {"id": 442, "type": "identifier", "text": " co", "parent": 440, "children": [], "start_point": {"row": 142, "column": 58}, "end_point": {"row": 142, "column": 62}}, {"id": 443, "type": "call_expression", "text": "RT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n vola", "parent": 431, "children": [444, 445], "start_point": {"row": 144, "column": 4}, "end_point": {"row": 144, "column": 58}}, {"id": 444, "type": "identifier", "text": "RT(spi_num <", "parent": 443, "children": [], "start_point": {"row": 144, "column": 4}, "end_point": {"row": 144, "column": 16}}, {"id": 445, "type": "argument_list", "text": " SPI_DEVICE_MAX && spi_num != 2);\n vola", "parent": 443, "children": [446], "start_point": {"row": 144, "column": 16}, "end_point": {"row": 144, "column": 58}}, {"id": 446, "type": "binary_expression", "text": "SPI_DEVICE_MAX && spi_num != 2);\n vol", "parent": 445, "children": [447, 451, 452], "start_point": {"row": 144, "column": 17}, "end_point": {"row": 144, "column": 57}}, {"id": 447, "type": "binary_expression", "text": "SPI_DEVICE_MAX && spi_nu", "parent": 446, "children": [448, 449, 450], "start_point": {"row": 144, "column": 17}, "end_point": {"row": 144, "column": 41}}, {"id": 448, "type": "identifier", "text": "SPI_DEV", "parent": 447, "children": [], "start_point": {"row": 144, "column": 17}, "end_point": {"row": 144, "column": 24}}, {"id": 449, "type": "<", "text": "C", "parent": 447, "children": [], "start_point": {"row": 144, "column": 25}, "end_point": {"row": 144, "column": 26}}, {"id": 450, "type": "identifier", "text": "_MAX && spi_nu", "parent": 447, "children": [], "start_point": {"row": 144, "column": 27}, "end_point": {"row": 144, "column": 41}}, {"id": 451, "type": "&&", "text": " !", "parent": 446, "children": [], "start_point": {"row": 144, "column": 42}, "end_point": {"row": 144, "column": 44}}, {"id": 452, "type": "binary_expression", "text": " 2);\n vol", "parent": 446, "children": [453, 454, 455], "start_point": {"row": 144, "column": 45}, "end_point": {"row": 144, "column": 57}}, {"id": 453, "type": "identifier", "text": " 2);\n ", "parent": 452, "children": [], "start_point": {"row": 144, "column": 45}, "end_point": {"row": 144, "column": 52}}, {"id": 454, "type": "!=", "text": " v", "parent": 452, "children": [], "start_point": {"row": 144, "column": 53}, "end_point": {"row": 144, "column": 55}}, {"id": 455, "type": "number_literal", "text": "l", "parent": 452, "children": [], "start_point": {"row": 144, "column": 56}, "end_point": {"row": 144, "column": 57}}, {"id": 456, "type": "declaration", "text": "pi_t *spi_handle = spi[spi_num];\n uint8", "parent": 431, "children": [457, 459, 460], "start_point": {"row": 145, "column": 4}, "end_point": {"row": 145, "column": 46}}, {"id": 457, "type": "type_qualifier", "text": "pi_t *sp", "parent": 456, "children": [458], "start_point": {"row": 145, "column": 4}, "end_point": {"row": 145, "column": 12}}, {"id": 458, "type": "volatile", "text": "pi_t *sp", "parent": 457, "children": [], "start_point": {"row": 145, "column": 4}, "end_point": {"row": 145, "column": 12}}, {"id": 459, "type": "type_identifier", "text": "_hand", "parent": 456, "children": [], "start_point": {"row": 145, "column": 13}, "end_point": {"row": 145, "column": 18}}, {"id": 460, "type": "init_declarator", "text": "e = spi[spi_num];\n uint", "parent": 456, "children": [461, 464, 465], "start_point": {"row": 145, "column": 19}, "end_point": {"row": 145, "column": 45}}, {"id": 461, "type": "pointer_declarator", "text": "e = spi[spi", "parent": 460, "children": [462, 463], "start_point": {"row": 145, "column": 19}, "end_point": {"row": 145, "column": 30}}, {"id": 462, "type": "*", "text": "e", "parent": 461, "children": [], "start_point": {"row": 145, "column": 19}, "end_point": {"row": 145, "column": 20}}, {"id": 463, "type": "identifier", "text": " = spi[spi", "parent": 461, "children": [], "start_point": {"row": 145, "column": 20}, "end_point": {"row": 145, "column": 30}}, {"id": 464, "type": "=", "text": "n", "parent": 460, "children": [], "start_point": {"row": 145, "column": 31}, "end_point": {"row": 145, "column": 32}}, {"id": 465, "type": "subscript_expression", "text": "m];\n uint", "parent": 460, "children": [466, 467], "start_point": {"row": 145, "column": 33}, "end_point": {"row": 145, "column": 45}}, {"id": 466, "type": "identifier", "text": "m];", "parent": 465, "children": [], "start_point": {"row": 145, "column": 33}, "end_point": {"row": 145, "column": 36}}, {"id": 467, "type": "identifier", "text": " uin", "parent": 465, "children": [], "start_point": {"row": 145, "column": 37}, "end_point": {"row": 145, "column": 44}}, {"id": 468, "type": "declaration", "text": "od_offset = 0;\n switc", "parent": 431, "children": [469, 470], "start_point": {"row": 146, "column": 4}, "end_point": {"row": 146, "column": 28}}, {"id": 469, "type": "primitive_type", "text": "od_offs", "parent": 468, "children": [], "start_point": {"row": 146, "column": 4}, "end_point": {"row": 146, "column": 11}}, {"id": 470, "type": "init_declarator", "text": "t = 0;\n swit", "parent": 468, "children": [471, 472, 473], "start_point": {"row": 146, "column": 12}, "end_point": {"row": 146, "column": 27}}, {"id": 471, "type": "identifier", "text": "t = 0;\n ", "parent": 470, "children": [], "start_point": {"row": 146, "column": 12}, "end_point": {"row": 146, "column": 23}}, {"id": 472, "type": "=", "text": "w", "parent": 470, "children": [], "start_point": {"row": 146, "column": 24}, "end_point": {"row": 146, "column": 25}}, {"id": 473, "type": "number_literal", "text": "t", "parent": 470, "children": [], "start_point": {"row": 146, "column": 26}, "end_point": {"row": 146, "column": 27}}, {"id": 474, "type": "switch_statement", "text": "i_num)\n {\n case 0:\n case 1:\n tmod_offset = 8;\n break;\n case 2:\n configASSERT(!\"Spi Bus 2 Not Support!\");\n break;\n case 3:\n default:\n tmod_offset = 10;\n break;\n }\n set_b", "parent": 431, "children": [475], "start_point": {"row": 147, "column": 4}, "end_point": {"row": 160, "column": 5}}, {"id": 475, "type": "switch", "text": "i_num)", "parent": 474, "children": [], "start_point": {"row": 147, "column": 4}, "end_point": {"row": 147, "column": 10}}, {"id": 476, "type": "case_statement", "text": " case ", "parent": 474, "children": [477, 478], "start_point": {"row": 149, "column": 4}, "end_point": {"row": 149, "column": 11}}, {"id": 477, "type": "case", "text": " ca", "parent": 476, "children": [], "start_point": {"row": 149, "column": 4}, "end_point": {"row": 149, "column": 8}}, {"id": 478, "type": "number_literal", "text": "e", "parent": 476, "children": [], "start_point": {"row": 149, "column": 9}, "end_point": {"row": 149, "column": 10}}, {"id": 479, "type": "case_statement", "text": " tmod_offset = 8;\n break;\n case ", "parent": 474, "children": [480, 481, 486], "start_point": {"row": 150, "column": 4}, "end_point": {"row": 152, "column": 14}}, {"id": 480, "type": "case", "text": " ", "parent": 479, "children": [], "start_point": {"row": 150, "column": 4}, "end_point": {"row": 150, "column": 8}}, {"id": 481, "type": "number_literal", "text": " ", "parent": 479, "children": [], "start_point": {"row": 150, "column": 9}, "end_point": {"row": 150, "column": 10}}, {"id": 482, "type": "assignment_expression", "text": "t = 8;\n ", "parent": 479, "children": [483, 484, 485], "start_point": {"row": 151, "column": 8}, "end_point": {"row": 151, "column": 23}}, {"id": 483, "type": "identifier", "text": "t = 8;\n ", "parent": 482, "children": [], "start_point": {"row": 151, "column": 8}, "end_point": {"row": 151, "column": 19}}, {"id": 484, "type": "=", "text": " ", "parent": 482, "children": [], "start_point": {"row": 151, "column": 20}, "end_point": {"row": 151, "column": 21}}, {"id": 485, "type": "number_literal", "text": " ", "parent": 482, "children": [], "start_point": {"row": 151, "column": 22}, "end_point": {"row": 151, "column": 23}}, {"id": 486, "type": "break_statement", "text": " case ", "parent": 479, "children": [487], "start_point": {"row": 152, "column": 8}, "end_point": {"row": 152, "column": 14}}, {"id": 487, "type": "break", "text": " case", "parent": 486, "children": [], "start_point": {"row": 152, "column": 8}, "end_point": {"row": 152, "column": 13}}, {"id": 488, "type": "case_statement", "text": " configASSERT(!\"Spi Bus 2 Not Support!\");\n break;\n case ", "parent": 474, "children": [489, 490, 497], "start_point": {"row": 153, "column": 4}, "end_point": {"row": 155, "column": 14}}, {"id": 489, "type": "case", "text": " ", "parent": 488, "children": [], "start_point": {"row": 153, "column": 4}, "end_point": {"row": 153, "column": 8}}, {"id": 490, "type": "number_literal", "text": " ", "parent": 488, "children": [], "start_point": {"row": 153, "column": 9}, "end_point": {"row": 153, "column": 10}}, {"id": 491, "type": "call_expression", "text": "RT(!\"Spi Bus 2 Not Support!\");\n ", "parent": 488, "children": [492, 493], "start_point": {"row": 154, "column": 8}, "end_point": {"row": 154, "column": 47}}, {"id": 492, "type": "identifier", "text": "RT(!\"Spi Bus", "parent": 491, "children": [], "start_point": {"row": 154, "column": 8}, "end_point": {"row": 154, "column": 20}}, {"id": 493, "type": "argument_list", "text": " 2 Not Support!\");\n ", "parent": 491, "children": [494], "start_point": {"row": 154, "column": 20}, "end_point": {"row": 154, "column": 47}}, {"id": 494, "type": "unary_expression", "text": "2 Not Support!\");\n ", "parent": 493, "children": [495, 496], "start_point": {"row": 154, "column": 21}, "end_point": {"row": 154, "column": 46}}, {"id": 495, "type": "!", "text": "2", "parent": 494, "children": [], "start_point": {"row": 154, "column": 21}, "end_point": {"row": 154, "column": 22}}, {"id": 496, "type": "string_literal", "text": " Not Support!\");\n ", "parent": 494, "children": [], "start_point": {"row": 154, "column": 22}, "end_point": {"row": 154, "column": 46}}, {"id": 497, "type": "break_statement", "text": " case ", "parent": 488, "children": [498], "start_point": {"row": 155, "column": 8}, "end_point": {"row": 155, "column": 14}}, {"id": 498, "type": "break", "text": " case", "parent": 497, "children": [], "start_point": {"row": 155, "column": 8}, "end_point": {"row": 155, "column": 13}}, {"id": 499, "type": "case_statement", "text": " defau", "parent": 474, "children": [500, 501], "start_point": {"row": 156, "column": 4}, "end_point": {"row": 156, "column": 11}}, {"id": 500, "type": "case", "text": " de", "parent": 499, "children": [], "start_point": {"row": 156, "column": 4}, "end_point": {"row": 156, "column": 8}}, {"id": 501, "type": "number_literal", "text": "a", "parent": 499, "children": [], "start_point": {"row": 156, "column": 9}, "end_point": {"row": 156, "column": 10}}, {"id": 502, "type": "case_statement", "text": " tmod_offset = 10;\n break;\n }\n ", "parent": 474, "children": [503], "start_point": {"row": 157, "column": 4}, "end_point": {"row": 159, "column": 14}}, {"id": 503, "type": "default", "text": " ", "parent": 502, "children": [], "start_point": {"row": 157, "column": 4}, "end_point": {"row": 157, "column": 11}}, {"id": 504, "type": "assignment_expression", "text": "t = 10;\n ", "parent": 502, "children": [505, 506, 507], "start_point": {"row": 158, "column": 8}, "end_point": {"row": 158, "column": 24}}, {"id": 505, "type": "identifier", "text": "t = 10;\n ", "parent": 504, "children": [], "start_point": {"row": 158, "column": 8}, "end_point": {"row": 158, "column": 19}}, {"id": 506, "type": "=", "text": " ", "parent": 504, "children": [], "start_point": {"row": 158, "column": 20}, "end_point": {"row": 158, "column": 21}}, {"id": 507, "type": "number_literal", "text": " ", "parent": 504, "children": [], "start_point": {"row": 158, "column": 22}, "end_point": {"row": 158, "column": 24}}, {"id": 508, "type": "call_expression", "text": "pi_handle->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstati", "parent": 431, "children": [509, 510], "start_point": {"row": 161, "column": 4}, "end_point": {"row": 161, "column": 71}}, {"id": 509, "type": "identifier", "text": "pi_hand", "parent": 508, "children": [], "start_point": {"row": 161, "column": 4}, "end_point": {"row": 161, "column": 11}}, {"id": 510, "type": "argument_list", "text": "le->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstati", "parent": 508, "children": [511, 517, 521], "start_point": {"row": 161, "column": 11}, "end_point": {"row": 161, "column": 71}}, {"id": 511, "type": "pointer_expression", "text": "e->ctrlr0, 3 << tmo", "parent": 510, "children": [512, 513], "start_point": {"row": 161, "column": 12}, "end_point": {"row": 161, "column": 31}}, {"id": 512, "type": "&", "text": "e", "parent": 511, "children": [], "start_point": {"row": 161, "column": 12}, "end_point": {"row": 161, "column": 13}}, {"id": 513, "type": "field_expression", "text": "->ctrlr0, 3 << tmo", "parent": 511, "children": [514, 515, 516], "start_point": {"row": 161, "column": 13}, "end_point": {"row": 161, "column": 31}}, {"id": 514, "type": "identifier", "text": "->ctrlr0, ", "parent": 513, "children": [], "start_point": {"row": 161, "column": 13}, "end_point": {"row": 161, "column": 23}}, {"id": 515, "type": "->", "text": "3 ", "parent": 513, "children": [], "start_point": {"row": 161, "column": 23}, "end_point": {"row": 161, "column": 25}}, {"id": 516, "type": "field_identifier", "text": "<< tmo", "parent": 513, "children": [], "start_point": {"row": 161, "column": 25}, "end_point": {"row": 161, "column": 31}}, {"id": 517, "type": "binary_expression", "text": "offset, tmod << ", "parent": 510, "children": [518, 519, 520], "start_point": {"row": 161, "column": 33}, "end_point": {"row": 161, "column": 49}}, {"id": 518, "type": "number_literal", "text": "o", "parent": 517, "children": [], "start_point": {"row": 161, "column": 33}, "end_point": {"row": 161, "column": 34}}, {"id": 519, "type": "<<", "text": "fs", "parent": 517, "children": [], "start_point": {"row": 161, "column": 35}, "end_point": {"row": 161, "column": 37}}, {"id": 520, "type": "identifier", "text": "t, tmod << ", "parent": 517, "children": [], "start_point": {"row": 161, "column": 38}, "end_point": {"row": 161, "column": 49}}, {"id": 521, "type": "binary_expression", "text": "od_offset);\n}\n\nstat", "parent": 510, "children": [522, 523, 524], "start_point": {"row": 161, "column": 51}, "end_point": {"row": 161, "column": 70}}, {"id": 522, "type": "identifier", "text": "od_o", "parent": 521, "children": [], "start_point": {"row": 161, "column": 51}, "end_point": {"row": 161, "column": 55}}, {"id": 523, "type": "<<", "text": "fs", "parent": 521, "children": [], "start_point": {"row": 161, "column": 56}, "end_point": {"row": 161, "column": 58}}, {"id": 524, "type": "identifier", "text": "t);\n}\n\nstat", "parent": 521, "children": [], "start_point": {"row": 161, "column": 59}, "end_point": {"row": 161, "column": 70}}, {"id": 525, "type": "function_definition", "text": "d sipeed_spi_transfer_data_standard(spi_device_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_buff, uint8_t *rx_buff, size_t len)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n configASSERT(len > 0);\n size_t index, fifo_len;\n size_t rx_len = len;\n size_t tx_len = rx_len;\n sipeed_spi_set_tmod(spi_num, SPI_TMOD_TRANS_RECV);\n\n volatile spi_t *spi_handle = spi[spi_num];\n\n uint8_t dfs_offset;\n switch (spi_num)\n {\n case 0:\n case 1:\n dfs_offset = 16;\n break;\n case 2:\n configASSERT(!\"Spi Bus 2 Not Support!\");\n break;\n case 3:\n default:\n dfs_offset = 0;\n break;\n }\n uint32_t data_bit_length = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F;\n spi_transfer_width_t frame_width = sipeed_spi_get_frame_size(data_bit_length);\n spi_handle->ctrlr1 = (uint32_t)(tx_len / frame_width - 1);\n spi_handle->ssienr = 0x01;\n spi_handle->ser = 1U << chip_select;\n uint32_t i = 0;\n while (tx_len)\n {\n fifo_len = 32 - spi_handle->txflr;\n fifo_len = fifo_len < tx_len ? fifo_len : tx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n tx_len -= fifo_len;\n }\n\n while ((spi_handle->sr & 0x05) != 0x04)\n ;\n i = 0;\n while (rx_len)\n {\n fifo_len = spi_handle->rxflr;\n fifo_len = fifo_len < rx_len ? fifo_len : rx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n rx_len -= fifo_len;\n }\n spi_handle->ser = 0x00;\n spi_handle->ssienr = 0x00;\n}\n\n/* SPI\u7aef\u53e3", "parent": 401, "children": [526, 527, 528], "start_point": {"row": 164, "column": 0}, "end_point": {"row": 249, "column": 1}}, {"id": 526, "type": "storage_class_specifier", "text": "d sipe", "parent": 525, "children": [], "start_point": {"row": 164, "column": 0}, "end_point": {"row": 164, "column": 6}}, {"id": 527, "type": "primitive_type", "text": "d_sp", "parent": 525, "children": [], "start_point": {"row": 164, "column": 7}, "end_point": {"row": 164, "column": 11}}, {"id": 528, "type": "function_declarator", "text": "_transfer_data_standard(spi_device_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_buff, uint8_t *rx_buff, size_t len)\n{\n con", "parent": 525, "children": [529, 530], "start_point": {"row": 164, "column": 12}, "end_point": {"row": 164, "column": 156}}, {"id": 529, "type": "identifier", "text": "_transfer_data_standard(spi_devic", "parent": 528, "children": [], "start_point": {"row": 164, "column": 12}, "end_point": {"row": 164, "column": 45}}, {"id": 530, "type": "parameter_list", "text": "e_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_buff, uint8_t *rx_buff, size_t len)\n{\n con", "parent": 528, "children": [531, 534, 537, 543, 548], "start_point": {"row": 164, "column": 45}, "end_point": {"row": 164, "column": 156}}, {"id": 531, "type": "parameter_declaration", "text": "_num_t spi_num, spi_chip", "parent": 530, "children": [532, 533], "start_point": {"row": 164, "column": 46}, "end_point": {"row": 164, "column": 70}}, {"id": 532, "type": "type_identifier", "text": "_num_t spi_num, ", "parent": 531, "children": [], "start_point": {"row": 164, "column": 46}, "end_point": {"row": 164, "column": 62}}, {"id": 533, "type": "identifier", "text": "pi_chip", "parent": 531, "children": [], "start_point": {"row": 164, "column": 63}, "end_point": {"row": 164, "column": 70}}, {"id": 534, "type": "parameter_declaration", "text": "elect_t chip_select, const ui", "parent": 530, "children": [535, 536], "start_point": {"row": 164, "column": 72}, "end_point": {"row": 164, "column": 101}}, {"id": 535, "type": "type_identifier", "text": "elect_t chip_sele", "parent": 534, "children": [], "start_point": {"row": 164, "column": 72}, "end_point": {"row": 164, "column": 89}}, {"id": 536, "type": "identifier", "text": "t, const ui", "parent": 534, "children": [], "start_point": {"row": 164, "column": 90}, "end_point": {"row": 164, "column": 101}}, {"id": 537, "type": "parameter_declaration", "text": "8_t *tx_buff, uint8_t ", "parent": 530, "children": [538, 539, 540], "start_point": {"row": 164, "column": 103}, "end_point": {"row": 164, "column": 125}}, {"id": 538, "type": "type_qualifier", "text": "8_t *", "parent": 537, "children": [], "start_point": {"row": 164, "column": 103}, "end_point": {"row": 164, "column": 108}}, {"id": 539, "type": "primitive_type", "text": "x_buff,", "parent": 537, "children": [], "start_point": {"row": 164, "column": 109}, "end_point": {"row": 164, "column": 116}}, {"id": 540, "type": "pointer_declarator", "text": "uint8_t ", "parent": 537, "children": [541, 542], "start_point": {"row": 164, "column": 117}, "end_point": {"row": 164, "column": 125}}, {"id": 541, "type": "*", "text": "u", "parent": 540, "children": [], "start_point": {"row": 164, "column": 117}, "end_point": {"row": 164, "column": 118}}, {"id": 542, "type": "identifier", "text": "int8_t ", "parent": 540, "children": [], "start_point": {"row": 164, "column": 118}, "end_point": {"row": 164, "column": 125}}, {"id": 543, "type": "parameter_declaration", "text": "x_buff, size_t l", "parent": 530, "children": [544, 545], "start_point": {"row": 164, "column": 127}, "end_point": {"row": 164, "column": 143}}, {"id": 544, "type": "primitive_type", "text": "x_buff,", "parent": 543, "children": [], "start_point": {"row": 164, "column": 127}, "end_point": {"row": 164, "column": 134}}, {"id": 545, "type": "pointer_declarator", "text": "size_t l", "parent": 543, "children": [546, 547], "start_point": {"row": 164, "column": 135}, "end_point": {"row": 164, "column": 143}}, {"id": 546, "type": "*", "text": "s", "parent": 545, "children": [], "start_point": {"row": 164, "column": 135}, "end_point": {"row": 164, "column": 136}}, {"id": 547, "type": "identifier", "text": "ize_t l", "parent": 545, "children": [], "start_point": {"row": 164, "column": 136}, "end_point": {"row": 164, "column": 143}}, {"id": 548, "type": "parameter_declaration", "text": ")\n{\n co", "parent": 530, "children": [549, 550], "start_point": {"row": 164, "column": 145}, "end_point": {"row": 164, "column": 155}}, {"id": 549, "type": "primitive_type", "text": ")\n{\n ", "parent": 548, "children": [], "start_point": {"row": 164, "column": 145}, "end_point": {"row": 164, "column": 151}}, {"id": 550, "type": "identifier", "text": " co", "parent": 548, "children": [], "start_point": {"row": 164, "column": 152}, "end_point": {"row": 164, "column": 155}}, {"id": 551, "type": "call_expression", "text": "RT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n conf", "parent": 525, "children": [552, 553], "start_point": {"row": 166, "column": 4}, "end_point": {"row": 166, "column": 58}}, {"id": 552, "type": "identifier", "text": "RT(spi_num <", "parent": 551, "children": [], "start_point": {"row": 166, "column": 4}, "end_point": {"row": 166, "column": 16}}, {"id": 553, "type": "argument_list", "text": " SPI_DEVICE_MAX && spi_num != 2);\n conf", "parent": 551, "children": [554], "start_point": {"row": 166, "column": 16}, "end_point": {"row": 166, "column": 58}}, {"id": 554, "type": "binary_expression", "text": "SPI_DEVICE_MAX && spi_num != 2);\n con", "parent": 553, "children": [555, 559, 560], "start_point": {"row": 166, "column": 17}, "end_point": {"row": 166, "column": 57}}, {"id": 555, "type": "binary_expression", "text": "SPI_DEVICE_MAX && spi_nu", "parent": 554, "children": [556, 557, 558], "start_point": {"row": 166, "column": 17}, "end_point": {"row": 166, "column": 41}}, {"id": 556, "type": "identifier", "text": "SPI_DEV", "parent": 555, "children": [], "start_point": {"row": 166, "column": 17}, "end_point": {"row": 166, "column": 24}}, {"id": 557, "type": "<", "text": "C", "parent": 555, "children": [], "start_point": {"row": 166, "column": 25}, "end_point": {"row": 166, "column": 26}}, {"id": 558, "type": "identifier", "text": "_MAX && spi_nu", "parent": 555, "children": [], "start_point": {"row": 166, "column": 27}, "end_point": {"row": 166, "column": 41}}, {"id": 559, "type": "&&", "text": " !", "parent": 554, "children": [], "start_point": {"row": 166, "column": 42}, "end_point": {"row": 166, "column": 44}}, {"id": 560, "type": "binary_expression", "text": " 2);\n con", "parent": 554, "children": [561, 562, 563], "start_point": {"row": 166, "column": 45}, "end_point": {"row": 166, "column": 57}}, {"id": 561, "type": "identifier", "text": " 2);\n ", "parent": 560, "children": [], "start_point": {"row": 166, "column": 45}, "end_point": {"row": 166, "column": 52}}, {"id": 562, "type": "!=", "text": " c", "parent": 560, "children": [], "start_point": {"row": 166, "column": 53}, "end_point": {"row": 166, "column": 55}}, {"id": 563, "type": "number_literal", "text": "n", "parent": 560, "children": [], "start_point": {"row": 166, "column": 56}, "end_point": {"row": 166, "column": 57}}, {"id": 564, "type": "call_expression", "text": "RT(len > 0);\n size", "parent": 525, "children": [565, 566], "start_point": {"row": 167, "column": 4}, "end_point": {"row": 167, "column": 25}}, {"id": 565, "type": "identifier", "text": "RT(len > 0);", "parent": 564, "children": [], "start_point": {"row": 167, "column": 4}, "end_point": {"row": 167, "column": 16}}, {"id": 566, "type": "argument_list", "text": "\n size", "parent": 564, "children": [567], "start_point": {"row": 167, "column": 16}, "end_point": {"row": 167, "column": 25}}, {"id": 567, "type": "binary_expression", "text": " siz", "parent": 566, "children": [568, 569, 570], "start_point": {"row": 167, "column": 17}, "end_point": {"row": 167, "column": 24}}, {"id": 568, "type": "identifier", "text": " ", "parent": 567, "children": [], "start_point": {"row": 167, "column": 17}, "end_point": {"row": 167, "column": 20}}, {"id": 569, "type": ">", "text": "s", "parent": 567, "children": [], "start_point": {"row": 167, "column": 21}, "end_point": {"row": 167, "column": 22}}, {"id": 570, "type": "number_literal", "text": "z", "parent": 567, "children": [], "start_point": {"row": 167, "column": 23}, "end_point": {"row": 167, "column": 24}}, {"id": 571, "type": "declaration", "text": "ex, fifo_len;\n size_", "parent": 525, "children": [572, 573, 574], "start_point": {"row": 168, "column": 4}, "end_point": {"row": 168, "column": 27}}, {"id": 572, "type": "primitive_type", "text": "ex, fi", "parent": 571, "children": [], "start_point": {"row": 168, "column": 4}, "end_point": {"row": 168, "column": 10}}, {"id": 573, "type": "identifier", "text": "o_len", "parent": 571, "children": [], "start_point": {"row": 168, "column": 11}, "end_point": {"row": 168, "column": 16}}, {"id": 574, "type": "identifier", "text": " size", "parent": 571, "children": [], "start_point": {"row": 168, "column": 18}, "end_point": {"row": 168, "column": 26}}, {"id": 575, "type": "declaration", "text": "len = len;\n size_", "parent": 525, "children": [576, 577], "start_point": {"row": 169, "column": 4}, "end_point": {"row": 169, "column": 24}}, {"id": 576, "type": "primitive_type", "text": "len = ", "parent": 575, "children": [], "start_point": {"row": 169, "column": 4}, "end_point": {"row": 169, "column": 10}}, {"id": 577, "type": "init_declarator", "text": "en;\n size", "parent": 575, "children": [578, 579, 580], "start_point": {"row": 169, "column": 11}, "end_point": {"row": 169, "column": 23}}, {"id": 578, "type": "identifier", "text": "en;\n ", "parent": 577, "children": [], "start_point": {"row": 169, "column": 11}, "end_point": {"row": 169, "column": 17}}, {"id": 579, "type": "=", "text": " ", "parent": 577, "children": [], "start_point": {"row": 169, "column": 18}, "end_point": {"row": 169, "column": 19}}, {"id": 580, "type": "identifier", "text": "ize", "parent": 577, "children": [], "start_point": {"row": 169, "column": 20}, "end_point": {"row": 169, "column": 23}}, {"id": 581, "type": "declaration", "text": "len = rx_len;\n sipee", "parent": 525, "children": [582, 583], "start_point": {"row": 170, "column": 4}, "end_point": {"row": 170, "column": 27}}, {"id": 582, "type": "primitive_type", "text": "len = ", "parent": 581, "children": [], "start_point": {"row": 170, "column": 4}, "end_point": {"row": 170, "column": 10}}, {"id": 583, "type": "init_declarator", "text": "x_len;\n sipe", "parent": 581, "children": [584, 585, 586], "start_point": {"row": 170, "column": 11}, "end_point": {"row": 170, "column": 26}}, {"id": 584, "type": "identifier", "text": "x_len;", "parent": 583, "children": [], "start_point": {"row": 170, "column": 11}, "end_point": {"row": 170, "column": 17}}, {"id": 585, "type": "=", "text": " ", "parent": 583, "children": [], "start_point": {"row": 170, "column": 18}, "end_point": {"row": 170, "column": 19}}, {"id": 586, "type": "identifier", "text": " sipe", "parent": 583, "children": [], "start_point": {"row": 170, "column": 20}, "end_point": {"row": 170, "column": 26}}, {"id": 587, "type": "call_expression", "text": "_set_tmod(spi_num, SPI_TMOD_TRANS_RECV);\n\n vol", "parent": 525, "children": [588, 589], "start_point": {"row": 171, "column": 4}, "end_point": {"row": 171, "column": 53}}, {"id": 588, "type": "identifier", "text": "_set_tmod(spi_num, ", "parent": 587, "children": [], "start_point": {"row": 171, "column": 4}, "end_point": {"row": 171, "column": 23}}, {"id": 589, "type": "argument_list", "text": "SPI_TMOD_TRANS_RECV);\n\n vol", "parent": 587, "children": [590, 591], "start_point": {"row": 171, "column": 23}, "end_point": {"row": 171, "column": 53}}, {"id": 590, "type": "identifier", "text": "PI_TMOD", "parent": 589, "children": [], "start_point": {"row": 171, "column": 24}, "end_point": {"row": 171, "column": 31}}, {"id": 591, "type": "identifier", "text": "RANS_RECV);\n\n vo", "parent": 589, "children": [], "start_point": {"row": 171, "column": 33}, "end_point": {"row": 171, "column": 52}}, {"id": 592, "type": "declaration", "text": "pi_t *spi_handle = spi[spi_num];\n\n uint", "parent": 525, "children": [593, 595, 596], "start_point": {"row": 173, "column": 4}, "end_point": {"row": 173, "column": 46}}, {"id": 593, "type": "type_qualifier", "text": "pi_t *sp", "parent": 592, "children": [594], "start_point": {"row": 173, "column": 4}, "end_point": {"row": 173, "column": 12}}, {"id": 594, "type": "volatile", "text": "pi_t *sp", "parent": 593, "children": [], "start_point": {"row": 173, "column": 4}, "end_point": {"row": 173, "column": 12}}, {"id": 595, "type": "type_identifier", "text": "_hand", "parent": 592, "children": [], "start_point": {"row": 173, "column": 13}, "end_point": {"row": 173, "column": 18}}, {"id": 596, "type": "init_declarator", "text": "e = spi[spi_num];\n\n uin", "parent": 592, "children": [597, 600, 601], "start_point": {"row": 173, "column": 19}, "end_point": {"row": 173, "column": 45}}, {"id": 597, "type": "pointer_declarator", "text": "e = spi[spi", "parent": 596, "children": [598, 599], "start_point": {"row": 173, "column": 19}, "end_point": {"row": 173, "column": 30}}, {"id": 598, "type": "*", "text": "e", "parent": 597, "children": [], "start_point": {"row": 173, "column": 19}, "end_point": {"row": 173, "column": 20}}, {"id": 599, "type": "identifier", "text": " = spi[spi", "parent": 597, "children": [], "start_point": {"row": 173, "column": 20}, "end_point": {"row": 173, "column": 30}}, {"id": 600, "type": "=", "text": "n", "parent": 596, "children": [], "start_point": {"row": 173, "column": 31}, "end_point": {"row": 173, "column": 32}}, {"id": 601, "type": "subscript_expression", "text": "m];\n\n uin", "parent": 596, "children": [602, 603], "start_point": {"row": 173, "column": 33}, "end_point": {"row": 173, "column": 45}}, {"id": 602, "type": "identifier", "text": "m];", "parent": 601, "children": [], "start_point": {"row": 173, "column": 33}, "end_point": {"row": 173, "column": 36}}, {"id": 603, "type": "identifier", "text": "\n ui", "parent": 601, "children": [], "start_point": {"row": 173, "column": 37}, "end_point": {"row": 173, "column": 44}}, {"id": 604, "type": "declaration", "text": "s_offset;\n switc", "parent": 525, "children": [605, 606], "start_point": {"row": 175, "column": 4}, "end_point": {"row": 175, "column": 23}}, {"id": 605, "type": "primitive_type", "text": "s_offse", "parent": 604, "children": [], "start_point": {"row": 175, "column": 4}, "end_point": {"row": 175, "column": 11}}, {"id": 606, "type": "identifier", "text": ";\n swit", "parent": 604, "children": [], "start_point": {"row": 175, "column": 12}, "end_point": {"row": 175, "column": 22}}, {"id": 607, "type": "switch_statement", "text": "i_num)\n {\n case 0:\n case 1:\n dfs_offset = 16;\n break;\n case 2:\n configASSERT(!\"Spi Bus 2 Not Support!\");\n break;\n case 3:\n default:\n dfs_offset = 0;\n break;\n }\n uint3", "parent": 525, "children": [608], "start_point": {"row": 176, "column": 4}, "end_point": {"row": 189, "column": 5}}, {"id": 608, "type": "switch", "text": "i_num)", "parent": 607, "children": [], "start_point": {"row": 176, "column": 4}, "end_point": {"row": 176, "column": 10}}, {"id": 609, "type": "case_statement", "text": " case ", "parent": 607, "children": [610, 611], "start_point": {"row": 178, "column": 4}, "end_point": {"row": 178, "column": 11}}, {"id": 610, "type": "case", "text": " ca", "parent": 609, "children": [], "start_point": {"row": 178, "column": 4}, "end_point": {"row": 178, "column": 8}}, {"id": 611, "type": "number_literal", "text": "e", "parent": 609, "children": [], "start_point": {"row": 178, "column": 9}, "end_point": {"row": 178, "column": 10}}, {"id": 612, "type": "case_statement", "text": " dfs_offset = 16;\n break;\n case ", "parent": 607, "children": [613, 614, 619], "start_point": {"row": 179, "column": 4}, "end_point": {"row": 181, "column": 14}}, {"id": 613, "type": "case", "text": " ", "parent": 612, "children": [], "start_point": {"row": 179, "column": 4}, "end_point": {"row": 179, "column": 8}}, {"id": 614, "type": "number_literal", "text": " ", "parent": 612, "children": [], "start_point": {"row": 179, "column": 9}, "end_point": {"row": 179, "column": 10}}, {"id": 615, "type": "assignment_expression", "text": " = 16;\n ", "parent": 612, "children": [616, 617, 618], "start_point": {"row": 180, "column": 8}, "end_point": {"row": 180, "column": 23}}, {"id": 616, "type": "identifier", "text": " = 16;\n ", "parent": 615, "children": [], "start_point": {"row": 180, "column": 8}, "end_point": {"row": 180, "column": 18}}, {"id": 617, "type": "=", "text": " ", "parent": 615, "children": [], "start_point": {"row": 180, "column": 19}, "end_point": {"row": 180, "column": 20}}, {"id": 618, "type": "number_literal", "text": " ", "parent": 615, "children": [], "start_point": {"row": 180, "column": 21}, "end_point": {"row": 180, "column": 23}}, {"id": 619, "type": "break_statement", "text": " case ", "parent": 612, "children": [620], "start_point": {"row": 181, "column": 8}, "end_point": {"row": 181, "column": 14}}, {"id": 620, "type": "break", "text": " case", "parent": 619, "children": [], "start_point": {"row": 181, "column": 8}, "end_point": {"row": 181, "column": 13}}, {"id": 621, "type": "case_statement", "text": " configASSERT(!\"Spi Bus 2 Not Support!\");\n break;\n case ", "parent": 607, "children": [622, 623, 630], "start_point": {"row": 182, "column": 4}, "end_point": {"row": 184, "column": 14}}, {"id": 622, "type": "case", "text": " ", "parent": 621, "children": [], "start_point": {"row": 182, "column": 4}, "end_point": {"row": 182, "column": 8}}, {"id": 623, "type": "number_literal", "text": " ", "parent": 621, "children": [], "start_point": {"row": 182, "column": 9}, "end_point": {"row": 182, "column": 10}}, {"id": 624, "type": "call_expression", "text": "RT(!\"Spi Bus 2 Not Support!\");\n ", "parent": 621, "children": [625, 626], "start_point": {"row": 183, "column": 8}, "end_point": {"row": 183, "column": 47}}, {"id": 625, "type": "identifier", "text": "RT(!\"Spi Bus", "parent": 624, "children": [], "start_point": {"row": 183, "column": 8}, "end_point": {"row": 183, "column": 20}}, {"id": 626, "type": "argument_list", "text": " 2 Not Support!\");\n ", "parent": 624, "children": [627], "start_point": {"row": 183, "column": 20}, "end_point": {"row": 183, "column": 47}}, {"id": 627, "type": "unary_expression", "text": "2 Not Support!\");\n ", "parent": 626, "children": [628, 629], "start_point": {"row": 183, "column": 21}, "end_point": {"row": 183, "column": 46}}, {"id": 628, "type": "!", "text": "2", "parent": 627, "children": [], "start_point": {"row": 183, "column": 21}, "end_point": {"row": 183, "column": 22}}, {"id": 629, "type": "string_literal", "text": " Not Support!\");\n ", "parent": 627, "children": [], "start_point": {"row": 183, "column": 22}, "end_point": {"row": 183, "column": 46}}, {"id": 630, "type": "break_statement", "text": " case ", "parent": 621, "children": [631], "start_point": {"row": 184, "column": 8}, "end_point": {"row": 184, "column": 14}}, {"id": 631, "type": "break", "text": " case", "parent": 630, "children": [], "start_point": {"row": 184, "column": 8}, "end_point": {"row": 184, "column": 13}}, {"id": 632, "type": "case_statement", "text": " defau", "parent": 607, "children": [633, 634], "start_point": {"row": 185, "column": 4}, "end_point": {"row": 185, "column": 11}}, {"id": 633, "type": "case", "text": " de", "parent": 632, "children": [], "start_point": {"row": 185, "column": 4}, "end_point": {"row": 185, "column": 8}}, {"id": 634, "type": "number_literal", "text": "a", "parent": 632, "children": [], "start_point": {"row": 185, "column": 9}, "end_point": {"row": 185, "column": 10}}, {"id": 635, "type": "case_statement", "text": " dfs_offset = 0;\n break;\n }\n ", "parent": 607, "children": [636], "start_point": {"row": 186, "column": 4}, "end_point": {"row": 188, "column": 14}}, {"id": 636, "type": "default", "text": " ", "parent": 635, "children": [], "start_point": {"row": 186, "column": 4}, "end_point": {"row": 186, "column": 11}}, {"id": 637, "type": "assignment_expression", "text": " = 0;\n ", "parent": 635, "children": [638, 639, 640], "start_point": {"row": 187, "column": 8}, "end_point": {"row": 187, "column": 22}}, {"id": 638, "type": "identifier", "text": " = 0;\n ", "parent": 637, "children": [], "start_point": {"row": 187, "column": 8}, "end_point": {"row": 187, "column": 18}}, {"id": 639, "type": "=", "text": " ", "parent": 637, "children": [], "start_point": {"row": 187, "column": 19}, "end_point": {"row": 187, "column": 20}}, {"id": 640, "type": "number_literal", "text": " ", "parent": 637, "children": [], "start_point": {"row": 187, "column": 21}, "end_point": {"row": 187, "column": 22}}, {"id": 641, "type": "declaration", "text": "ata_bit_length = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F;\n spi_t", "parent": 525, "children": [642, 643], "start_point": {"row": 190, "column": 4}, "end_point": {"row": 190, "column": 73}}, {"id": 642, "type": "primitive_type", "text": "ata_bit_", "parent": 641, "children": [], "start_point": {"row": 190, "column": 4}, "end_point": {"row": 190, "column": 12}}, {"id": 643, "type": "init_declarator", "text": "ength = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F;\n spi_", "parent": 641, "children": [644, 645, 646], "start_point": {"row": 190, "column": 13}, "end_point": {"row": 190, "column": 72}}, {"id": 644, "type": "identifier", "text": "ength = (spi_ha", "parent": 643, "children": [], "start_point": {"row": 190, "column": 13}, "end_point": {"row": 190, "column": 28}}, {"id": 645, "type": "=", "text": "d", "parent": 643, "children": [], "start_point": {"row": 190, "column": 29}, "end_point": {"row": 190, "column": 30}}, {"id": 646, "type": "binary_expression", "text": "e->ctrlr0 >> dfs_offset) & 0x1F;\n spi_", "parent": 643, "children": [647, 655, 656], "start_point": {"row": 190, "column": 31}, "end_point": {"row": 190, "column": 72}}, {"id": 647, "type": "parenthesized_expression", "text": "e->ctrlr0 >> dfs_offset) & 0x1F;\n ", "parent": 646, "children": [648], "start_point": {"row": 190, "column": 31}, "end_point": {"row": 190, "column": 65}}, {"id": 648, "type": "binary_expression", "text": "->ctrlr0 >> dfs_offset) & 0x1F;\n", "parent": 647, "children": [649, 653, 654], "start_point": {"row": 190, "column": 32}, "end_point": {"row": 190, "column": 64}}, {"id": 649, "type": "field_expression", "text": "->ctrlr0 >> dfs_of", "parent": 648, "children": [650, 651, 652], "start_point": {"row": 190, "column": 32}, "end_point": {"row": 190, "column": 50}}, {"id": 650, "type": "identifier", "text": "->ctrlr0 >", "parent": 649, "children": [], "start_point": {"row": 190, "column": 32}, "end_point": {"row": 190, "column": 42}}, {"id": 651, "type": "->", "text": "> ", "parent": 649, "children": [], "start_point": {"row": 190, "column": 42}, "end_point": {"row": 190, "column": 44}}, {"id": 652, "type": "field_identifier", "text": "dfs_of", "parent": 649, "children": [], "start_point": {"row": 190, "column": 44}, "end_point": {"row": 190, "column": 50}}, {"id": 653, "type": ">>", "text": "se", "parent": 648, "children": [], "start_point": {"row": 190, "column": 51}, "end_point": {"row": 190, "column": 53}}, {"id": 654, "type": "identifier", "text": ") & 0x1F;\n", "parent": 648, "children": [], "start_point": {"row": 190, "column": 54}, "end_point": {"row": 190, "column": 64}}, {"id": 655, "type": "&", "text": " ", "parent": 646, "children": [], "start_point": {"row": 190, "column": 66}, "end_point": {"row": 190, "column": 67}}, {"id": 656, "type": "number_literal", "text": "spi_", "parent": 646, "children": [], "start_point": {"row": 190, "column": 68}, "end_point": {"row": 190, "column": 72}}, {"id": 657, "type": "declaration", "text": "er_width_t frame_width = sipeed_spi_get_frame_size(data_bit_length);\n spi_h", "parent": 525, "children": [658, 659], "start_point": {"row": 191, "column": 4}, "end_point": {"row": 191, "column": 82}}, {"id": 658, "type": "type_identifier", "text": "er_width_t frame_wid", "parent": 657, "children": [], "start_point": {"row": 191, "column": 4}, "end_point": {"row": 191, "column": 24}}, {"id": 659, "type": "init_declarator", "text": "h = sipeed_spi_get_frame_size(data_bit_length);\n spi_", "parent": 657, "children": [660, 661, 662], "start_point": {"row": 191, "column": 25}, "end_point": {"row": 191, "column": 81}}, {"id": 660, "type": "identifier", "text": "h = sipeed_", "parent": 659, "children": [], "start_point": {"row": 191, "column": 25}, "end_point": {"row": 191, "column": 36}}, {"id": 661, "type": "=", "text": "p", "parent": 659, "children": [], "start_point": {"row": 191, "column": 37}, "end_point": {"row": 191, "column": 38}}, {"id": 662, "type": "call_expression", "text": "_get_frame_size(data_bit_length);\n spi_", "parent": 659, "children": [663, 664], "start_point": {"row": 191, "column": 39}, "end_point": {"row": 191, "column": 81}}, {"id": 663, "type": "identifier", "text": "_get_frame_size(data_bit_", "parent": 662, "children": [], "start_point": {"row": 191, "column": 39}, "end_point": {"row": 191, "column": 64}}, {"id": 664, "type": "argument_list", "text": "length);\n spi_", "parent": 662, "children": [665], "start_point": {"row": 191, "column": 64}, "end_point": {"row": 191, "column": 81}}, {"id": 665, "type": "identifier", "text": "ength);\n spi", "parent": 664, "children": [], "start_point": {"row": 191, "column": 65}, "end_point": {"row": 191, "column": 80}}, {"id": 666, "type": "assignment_expression", "text": "->ctrlr1 = (uint32_t)(tx_len / frame_width - 1);\n spi_", "parent": 525, "children": [667, 670, 671], "start_point": {"row": 192, "column": 4}, "end_point": {"row": 192, "column": 61}}, {"id": 667, "type": "field_expression", "text": "->ctrlr1 = (uint32", "parent": 666, "children": [668, 669], "start_point": {"row": 192, "column": 4}, "end_point": {"row": 192, "column": 22}}, {"id": 668, "type": "identifier", "text": "->ctrlr1 =", "parent": 667, "children": [], "start_point": {"row": 192, "column": 4}, "end_point": {"row": 192, "column": 14}}, {"id": 669, "type": "field_identifier", "text": "uint32", "parent": 667, "children": [], "start_point": {"row": 192, "column": 16}, "end_point": {"row": 192, "column": 22}}, {"id": 670, "type": "=", "text": "t", "parent": 666, "children": [], "start_point": {"row": 192, "column": 23}, "end_point": {"row": 192, "column": 24}}, {"id": 671, "type": "cast_expression", "text": "(tx_len / frame_width - 1);\n spi_", "parent": 666, "children": [672, 674], "start_point": {"row": 192, "column": 25}, "end_point": {"row": 192, "column": 61}}, {"id": 672, "type": "type_descriptor", "text": "tx_len /", "parent": 671, "children": [673], "start_point": {"row": 192, "column": 26}, "end_point": {"row": 192, "column": 34}}, {"id": 673, "type": "primitive_type", "text": "tx_len /", "parent": 672, "children": [], "start_point": {"row": 192, "column": 26}, "end_point": {"row": 192, "column": 34}}, {"id": 674, "type": "parenthesized_expression", "text": "frame_width - 1);\n spi_", "parent": 671, "children": [675], "start_point": {"row": 192, "column": 35}, "end_point": {"row": 192, "column": 61}}, {"id": 675, "type": "binary_expression", "text": "rame_width - 1);\n spi", "parent": 674, "children": [676, 680, 681], "start_point": {"row": 192, "column": 36}, "end_point": {"row": 192, "column": 60}}, {"id": 676, "type": "binary_expression", "text": "rame_width - 1);\n ", "parent": 675, "children": [677, 678, 679], "start_point": {"row": 192, "column": 36}, "end_point": {"row": 192, "column": 56}}, {"id": 677, "type": "identifier", "text": "rame_w", "parent": 676, "children": [], "start_point": {"row": 192, "column": 36}, "end_point": {"row": 192, "column": 42}}, {"id": 678, "type": "/", "text": "d", "parent": 676, "children": [], "start_point": {"row": 192, "column": 43}, "end_point": {"row": 192, "column": 44}}, {"id": 679, "type": "identifier", "text": "h - 1);\n ", "parent": 676, "children": [], "start_point": {"row": 192, "column": 45}, "end_point": {"row": 192, "column": 56}}, {"id": 680, "type": "-", "text": "s", "parent": 675, "children": [], "start_point": {"row": 192, "column": 57}, "end_point": {"row": 192, "column": 58}}, {"id": 681, "type": "number_literal", "text": "i", "parent": 675, "children": [], "start_point": {"row": 192, "column": 59}, "end_point": {"row": 192, "column": 60}}, {"id": 682, "type": "assignment_expression", "text": "->ssienr = 0x01;\n spi_", "parent": 525, "children": [683, 687, 688], "start_point": {"row": 193, "column": 4}, "end_point": {"row": 193, "column": 29}}, {"id": 683, "type": "field_expression", "text": "->ssienr = 0x01;\n ", "parent": 682, "children": [684, 685, 686], "start_point": {"row": 193, "column": 4}, "end_point": {"row": 193, "column": 22}}, {"id": 684, "type": "identifier", "text": "->ssienr =", "parent": 683, "children": [], "start_point": {"row": 193, "column": 4}, "end_point": {"row": 193, "column": 14}}, {"id": 685, "type": "->", "text": " 0", "parent": 683, "children": [], "start_point": {"row": 193, "column": 14}, "end_point": {"row": 193, "column": 16}}, {"id": 686, "type": "field_identifier", "text": "x01;\n ", "parent": 683, "children": [], "start_point": {"row": 193, "column": 16}, "end_point": {"row": 193, "column": 22}}, {"id": 687, "type": "=", "text": " ", "parent": 682, "children": [], "start_point": {"row": 193, "column": 23}, "end_point": {"row": 193, "column": 24}}, {"id": 688, "type": "number_literal", "text": "spi_", "parent": 682, "children": [], "start_point": {"row": 193, "column": 25}, "end_point": {"row": 193, "column": 29}}, {"id": 689, "type": "assignment_expression", "text": "->ser = 1U << chip_select;\n uint", "parent": 525, "children": [690, 694, 695], "start_point": {"row": 194, "column": 4}, "end_point": {"row": 194, "column": 39}}, {"id": 690, "type": "field_expression", "text": "->ser = 1U << c", "parent": 689, "children": [691, 692, 693], "start_point": {"row": 194, "column": 4}, "end_point": {"row": 194, "column": 19}}, {"id": 691, "type": "identifier", "text": "->ser = 1U", "parent": 690, "children": [], "start_point": {"row": 194, "column": 4}, "end_point": {"row": 194, "column": 14}}, {"id": 692, "type": "->", "text": " <", "parent": 690, "children": [], "start_point": {"row": 194, "column": 14}, "end_point": {"row": 194, "column": 16}}, {"id": 693, "type": "field_identifier", "text": "< c", "parent": 690, "children": [], "start_point": {"row": 194, "column": 16}, "end_point": {"row": 194, "column": 19}}, {"id": 694, "type": "=", "text": "i", "parent": 689, "children": [], "start_point": {"row": 194, "column": 20}, "end_point": {"row": 194, "column": 21}}, {"id": 695, "type": "binary_expression", "text": "_select;\n uint", "parent": 689, "children": [696, 697, 698], "start_point": {"row": 194, "column": 22}, "end_point": {"row": 194, "column": 39}}, {"id": 696, "type": "number_literal", "text": "_s", "parent": 695, "children": [], "start_point": {"row": 194, "column": 22}, "end_point": {"row": 194, "column": 24}}, {"id": 697, "type": "<<", "text": "le", "parent": 695, "children": [], "start_point": {"row": 194, "column": 25}, "end_point": {"row": 194, "column": 27}}, {"id": 698, "type": "identifier", "text": "t;\n uint", "parent": 695, "children": [], "start_point": {"row": 194, "column": 28}, "end_point": {"row": 194, "column": 39}}, {"id": 699, "type": "declaration", "text": " = 0;\n while", "parent": 525, "children": [700, 701], "start_point": {"row": 195, "column": 4}, "end_point": {"row": 195, "column": 19}}, {"id": 700, "type": "primitive_type", "text": " = 0;\n ", "parent": 699, "children": [], "start_point": {"row": 195, "column": 4}, "end_point": {"row": 195, "column": 12}}, {"id": 701, "type": "init_declarator", "text": " whil", "parent": 699, "children": [702, 703, 704], "start_point": {"row": 195, "column": 13}, "end_point": {"row": 195, "column": 18}}, {"id": 702, "type": "identifier", "text": " ", "parent": 701, "children": [], "start_point": {"row": 195, "column": 13}, "end_point": {"row": 195, "column": 14}}, {"id": 703, "type": "=", "text": "h", "parent": 701, "children": [], "start_point": {"row": 195, "column": 15}, "end_point": {"row": 195, "column": 16}}, {"id": 704, "type": "number_literal", "text": "l", "parent": 701, "children": [], "start_point": {"row": 195, "column": 17}, "end_point": {"row": 195, "column": 18}}, {"id": 705, "type": "while_statement", "text": "len)\n {\n fifo_len = 32 - spi_handle->txflr;\n fifo_len = fifo_len < tx_len ? fifo_len : tx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n tx_len -= fifo_len;\n }\n\n whil", "parent": 525, "children": [], "start_point": {"row": 196, "column": 4}, "end_point": {"row": 218, "column": 5}}, {"id": 706, "type": "assignment_expression", "text": " 32 - spi_handle->txflr;\n ", "parent": 705, "children": [707, 708, 709], "start_point": {"row": 198, "column": 8}, "end_point": {"row": 198, "column": 41}}, {"id": 707, "type": "identifier", "text": " 32 - sp", "parent": 706, "children": [], "start_point": {"row": 198, "column": 8}, "end_point": {"row": 198, "column": 16}}, {"id": 708, "type": "=", "text": "_", "parent": 706, "children": [], "start_point": {"row": 198, "column": 17}, "end_point": {"row": 198, "column": 18}}, {"id": 709, "type": "binary_expression", "text": "andle->txflr;\n ", "parent": 706, "children": [710, 711, 712], "start_point": {"row": 198, "column": 19}, "end_point": {"row": 198, "column": 41}}, {"id": 710, "type": "number_literal", "text": "an", "parent": 709, "children": [], "start_point": {"row": 198, "column": 19}, "end_point": {"row": 198, "column": 21}}, {"id": 711, "type": "-", "text": "l", "parent": 709, "children": [], "start_point": {"row": 198, "column": 22}, "end_point": {"row": 198, "column": 23}}, {"id": 712, "type": "field_expression", "text": "->txflr;\n ", "parent": 709, "children": [713, 714, 715], "start_point": {"row": 198, "column": 24}, "end_point": {"row": 198, "column": 41}}, {"id": 713, "type": "identifier", "text": "->txflr;\n ", "parent": 712, "children": [], "start_point": {"row": 198, "column": 24}, "end_point": {"row": 198, "column": 34}}, {"id": 714, "type": "->", "text": " ", "parent": 712, "children": [], "start_point": {"row": 198, "column": 34}, "end_point": {"row": 198, "column": 36}}, {"id": 715, "type": "field_identifier", "text": " ", "parent": 712, "children": [], "start_point": {"row": 198, "column": 36}, "end_point": {"row": 198, "column": 41}}, {"id": 716, "type": "assignment_expression", "text": " fifo_len < tx_len ? fifo_len : tx_len;\n ", "parent": 705, "children": [717, 718, 719], "start_point": {"row": 199, "column": 8}, "end_point": {"row": 199, "column": 56}}, {"id": 717, "type": "identifier", "text": " fifo_le", "parent": 716, "children": [], "start_point": {"row": 199, "column": 8}, "end_point": {"row": 199, "column": 16}}, {"id": 718, "type": "=", "text": " ", "parent": 716, "children": [], "start_point": {"row": 199, "column": 17}, "end_point": {"row": 199, "column": 18}}, {"id": 719, "type": "conditional_expression", "text": " tx_len ? fifo_len : tx_len;\n ", "parent": 716, "children": [720, 724, 725, 726], "start_point": {"row": 199, "column": 19}, "end_point": {"row": 199, "column": 56}}, {"id": 720, "type": "binary_expression", "text": " tx_len ? fifo_le", "parent": 719, "children": [721, 722, 723], "start_point": {"row": 199, "column": 19}, "end_point": {"row": 199, "column": 36}}, {"id": 721, "type": "identifier", "text": " tx_len ", "parent": 720, "children": [], "start_point": {"row": 199, "column": 19}, "end_point": {"row": 199, "column": 27}}, {"id": 722, "type": "<", "text": " ", "parent": 720, "children": [], "start_point": {"row": 199, "column": 28}, "end_point": {"row": 199, "column": 29}}, {"id": 723, "type": "identifier", "text": "ifo_le", "parent": 720, "children": [], "start_point": {"row": 199, "column": 30}, "end_point": {"row": 199, "column": 36}}, {"id": 724, "type": "?", "text": " ", "parent": 719, "children": [], "start_point": {"row": 199, "column": 37}, "end_point": {"row": 199, "column": 38}}, {"id": 725, "type": "identifier", "text": " tx_len;", "parent": 719, "children": [], "start_point": {"row": 199, "column": 39}, "end_point": {"row": 199, "column": 47}}, {"id": 726, "type": "identifier", "text": " ", "parent": 719, "children": [], "start_point": {"row": 199, "column": 50}, "end_point": {"row": 199, "column": 56}}, {"id": 727, "type": "switch_statement", "text": "ame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n t", "parent": 705, "children": [728, 729], "start_point": {"row": 200, "column": 8}, "end_point": {"row": 216, "column": 9}}, {"id": 728, "type": "switch", "text": "ame_wi", "parent": 727, "children": [], "start_point": {"row": 200, "column": 8}, "end_point": {"row": 200, "column": 14}}, {"id": 729, "type": "parenthesized_expression", "text": "th)\n {", "parent": 727, "children": [730], "start_point": {"row": 200, "column": 15}, "end_point": {"row": 200, "column": 28}}, {"id": 730, "type": "identifier", "text": "h)\n ", "parent": 729, "children": [], "start_point": {"row": 200, "column": 16}, "end_point": {"row": 200, "column": 27}}, {"id": 731, "type": "case_statement", "text": "RANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n c", "parent": 727, "children": [732, 733, 744, 775], "start_point": {"row": 202, "column": 8}, "end_point": {"row": 206, "column": 18}}, {"id": 732, "type": "case", "text": "RANS", "parent": 731, "children": [], "start_point": {"row": 202, "column": 8}, "end_point": {"row": 202, "column": 12}}, {"id": 733, "type": "identifier", "text": "INT:\n ", "parent": 731, "children": [], "start_point": {"row": 202, "column": 13}, "end_point": {"row": 202, "column": 26}}, {"id": 734, "type": "assignment_expression", "text": " fifo_len / 4 * 4;\n ", "parent": 731, "children": [735, 736, 737], "start_point": {"row": 203, "column": 12}, "end_point": {"row": 203, "column": 39}}, {"id": 735, "type": "identifier", "text": " fifo_le", "parent": 734, "children": [], "start_point": {"row": 203, "column": 12}, "end_point": {"row": 203, "column": 20}}, {"id": 736, "type": "=", "text": " ", "parent": 734, "children": [], "start_point": {"row": 203, "column": 21}, "end_point": {"row": 203, "column": 22}}, {"id": 737, "type": "binary_expression", "text": " 4 * 4;\n ", "parent": 734, "children": [738, 742, 743], "start_point": {"row": 203, "column": 23}, "end_point": {"row": 203, "column": 39}}, {"id": 738, "type": "binary_expression", "text": " 4 * 4;\n ", "parent": 737, "children": [739, 740, 741], "start_point": {"row": 203, "column": 23}, "end_point": {"row": 203, "column": 35}}, {"id": 739, "type": "identifier", "text": " 4 * 4;\n", "parent": 738, "children": [], "start_point": {"row": 203, "column": 23}, "end_point": {"row": 203, "column": 31}}, {"id": 740, "type": "/", "text": " ", "parent": 738, "children": [], "start_point": {"row": 203, "column": 32}, "end_point": {"row": 203, "column": 33}}, {"id": 741, "type": "number_literal", "text": " ", "parent": 738, "children": [], "start_point": {"row": 203, "column": 34}, "end_point": {"row": 203, "column": 35}}, {"id": 742, "type": "*", "text": " ", "parent": 737, "children": [], "start_point": {"row": 203, "column": 36}, "end_point": {"row": 203, "column": 37}}, {"id": 743, "type": "number_literal", "text": " ", "parent": 737, "children": [], "start_point": {"row": 203, "column": 38}, "end_point": {"row": 203, "column": 39}}, {"id": 744, "type": "for_statement", "text": " = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n ", "parent": 731, "children": [745, 749, 755], "start_point": {"row": 204, "column": 12}, "end_point": {"row": 205, "column": 63}}, {"id": 745, "type": "assignment_expression", "text": " index < ", "parent": 744, "children": [746, 747, 748], "start_point": {"row": 204, "column": 17}, "end_point": {"row": 204, "column": 26}}, {"id": 746, "type": "identifier", "text": " inde", "parent": 745, "children": [], "start_point": {"row": 204, "column": 17}, "end_point": {"row": 204, "column": 22}}, {"id": 747, "type": "=", "text": " ", "parent": 745, "children": [], "start_point": {"row": 204, "column": 23}, "end_point": {"row": 204, "column": 24}}, {"id": 748, "type": "number_literal", "text": " ", "parent": 745, "children": [], "start_point": {"row": 204, "column": 25}, "end_point": {"row": 204, "column": 26}}, {"id": 749, "type": "binary_expression", "text": "fo_len / 4; index++)", "parent": 744, "children": [750, 751, 752], "start_point": {"row": 204, "column": 28}, "end_point": {"row": 204, "column": 48}}, {"id": 750, "type": "identifier", "text": "fo_le", "parent": 749, "children": [], "start_point": {"row": 204, "column": 28}, "end_point": {"row": 204, "column": 33}}, {"id": 751, "type": "<", "text": " ", "parent": 749, "children": [], "start_point": {"row": 204, "column": 34}, "end_point": {"row": 204, "column": 35}}, {"id": 752, "type": "binary_expression", "text": " 4; index++)", "parent": 749, "children": [753, 754], "start_point": {"row": 204, "column": 36}, "end_point": {"row": 204, "column": 48}}, {"id": 753, "type": "identifier", "text": " 4; inde", "parent": 752, "children": [], "start_point": {"row": 204, "column": 36}, "end_point": {"row": 204, "column": 44}}, {"id": 754, "type": "/", "text": "+", "parent": 752, "children": [], "start_point": {"row": 204, "column": 45}, "end_point": {"row": 204, "column": 46}}, {"id": 755, "type": "update_expression", "text": " ", "parent": 744, "children": [756, 757], "start_point": {"row": 204, "column": 50}, "end_point": {"row": 204, "column": 57}}, {"id": 756, "type": "identifier", "text": " ", "parent": 755, "children": [], "start_point": {"row": 204, "column": 50}, "end_point": {"row": 204, "column": 55}}, {"id": 757, "type": "++", "text": " ", "parent": 755, "children": [], "start_point": {"row": 204, "column": 55}, "end_point": {"row": 204, "column": 57}}, {"id": 758, "type": "assignment_expression", "text": "->dr[0] = ((uint32_t *)tx_buff)[i++];\n ", "parent": 744, "children": [759, 765, 766], "start_point": {"row": 205, "column": 16}, "end_point": {"row": 205, "column": 62}}, {"id": 759, "type": "subscript_expression", "text": "->dr[0] = ((uint3", "parent": 758, "children": [760, 764], "start_point": {"row": 205, "column": 16}, "end_point": {"row": 205, "column": 33}}, {"id": 760, "type": "field_expression", "text": "->dr[0] = ((ui", "parent": 759, "children": [761, 762, 763], "start_point": {"row": 205, "column": 16}, "end_point": {"row": 205, "column": 30}}, {"id": 761, "type": "identifier", "text": "->dr[0] = ", "parent": 760, "children": [], "start_point": {"row": 205, "column": 16}, "end_point": {"row": 205, "column": 26}}, {"id": 762, "type": "->", "text": "((", "parent": 760, "children": [], "start_point": {"row": 205, "column": 26}, "end_point": {"row": 205, "column": 28}}, {"id": 763, "type": "field_identifier", "text": "ui", "parent": 760, "children": [], "start_point": {"row": 205, "column": 28}, "end_point": {"row": 205, "column": 30}}, {"id": 764, "type": "number_literal", "text": "t", "parent": 759, "children": [], "start_point": {"row": 205, "column": 31}, "end_point": {"row": 205, "column": 32}}, {"id": 765, "type": "=", "text": "_", "parent": 758, "children": [], "start_point": {"row": 205, "column": 34}, "end_point": {"row": 205, "column": 35}}, {"id": 766, "type": "subscript_expression", "text": " *)tx_buff)[i++];\n ", "parent": 758, "children": [767, 772], "start_point": {"row": 205, "column": 36}, "end_point": {"row": 205, "column": 62}}, {"id": 767, "type": "parenthesized_expression", "text": " *)tx_buff)[i++];\n ", "parent": 766, "children": [768], "start_point": {"row": 205, "column": 36}, "end_point": {"row": 205, "column": 57}}, {"id": 768, "type": "cast_expression", "text": "*)tx_buff)[i++];\n ", "parent": 767, "children": [769, 771], "start_point": {"row": 205, "column": 37}, "end_point": {"row": 205, "column": 56}}, {"id": 769, "type": "type_descriptor", "text": ")tx_buff)[", "parent": 768, "children": [770], "start_point": {"row": 205, "column": 38}, "end_point": {"row": 205, "column": 48}}, {"id": 770, "type": "primitive_type", "text": ")tx_buff", "parent": 769, "children": [], "start_point": {"row": 205, "column": 38}, "end_point": {"row": 205, "column": 46}}, {"id": 771, "type": "identifier", "text": "++];\n ", "parent": 768, "children": [], "start_point": {"row": 205, "column": 49}, "end_point": {"row": 205, "column": 56}}, {"id": 772, "type": "update_expression", "text": " ", "parent": 766, "children": [773, 774], "start_point": {"row": 205, "column": 58}, "end_point": {"row": 205, "column": 61}}, {"id": 773, "type": "identifier", "text": " ", "parent": 772, "children": [], "start_point": {"row": 205, "column": 58}, "end_point": {"row": 205, "column": 59}}, {"id": 774, "type": "++", "text": " ", "parent": 772, "children": [], "start_point": {"row": 205, "column": 59}, "end_point": {"row": 205, "column": 61}}, {"id": 775, "type": "break_statement", "text": " c", "parent": 731, "children": [776], "start_point": {"row": 206, "column": 12}, "end_point": {"row": 206, "column": 18}}, {"id": 776, "type": "break", "text": " ", "parent": 775, "children": [], "start_point": {"row": 206, "column": 12}, "end_point": {"row": 206, "column": 17}}, {"id": 777, "type": "case_statement", "text": "RANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n d", "parent": 727, "children": [778, 779, 790, 821], "start_point": {"row": 207, "column": 8}, "end_point": {"row": 211, "column": 18}}, {"id": 778, "type": "case", "text": "RANS", "parent": 777, "children": [], "start_point": {"row": 207, "column": 8}, "end_point": {"row": 207, "column": 12}}, {"id": 779, "type": "identifier", "text": "SHORT:\n ", "parent": 777, "children": [], "start_point": {"row": 207, "column": 13}, "end_point": {"row": 207, "column": 28}}, {"id": 780, "type": "assignment_expression", "text": " fifo_len / 2 * 2;\n ", "parent": 777, "children": [781, 782, 783], "start_point": {"row": 208, "column": 12}, "end_point": {"row": 208, "column": 39}}, {"id": 781, "type": "identifier", "text": " fifo_le", "parent": 780, "children": [], "start_point": {"row": 208, "column": 12}, "end_point": {"row": 208, "column": 20}}, {"id": 782, "type": "=", "text": " ", "parent": 780, "children": [], "start_point": {"row": 208, "column": 21}, "end_point": {"row": 208, "column": 22}}, {"id": 783, "type": "binary_expression", "text": " 2 * 2;\n ", "parent": 780, "children": [784, 788, 789], "start_point": {"row": 208, "column": 23}, "end_point": {"row": 208, "column": 39}}, {"id": 784, "type": "binary_expression", "text": " 2 * 2;\n ", "parent": 783, "children": [785, 786, 787], "start_point": {"row": 208, "column": 23}, "end_point": {"row": 208, "column": 35}}, {"id": 785, "type": "identifier", "text": " 2 * 2;\n", "parent": 784, "children": [], "start_point": {"row": 208, "column": 23}, "end_point": {"row": 208, "column": 31}}, {"id": 786, "type": "/", "text": " ", "parent": 784, "children": [], "start_point": {"row": 208, "column": 32}, "end_point": {"row": 208, "column": 33}}, {"id": 787, "type": "number_literal", "text": " ", "parent": 784, "children": [], "start_point": {"row": 208, "column": 34}, "end_point": {"row": 208, "column": 35}}, {"id": 788, "type": "*", "text": " ", "parent": 783, "children": [], "start_point": {"row": 208, "column": 36}, "end_point": {"row": 208, "column": 37}}, {"id": 789, "type": "number_literal", "text": " ", "parent": 783, "children": [], "start_point": {"row": 208, "column": 38}, "end_point": {"row": 208, "column": 39}}, {"id": 790, "type": "for_statement", "text": " = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n ", "parent": 777, "children": [791, 795, 801], "start_point": {"row": 209, "column": 12}, "end_point": {"row": 210, "column": 63}}, {"id": 791, "type": "assignment_expression", "text": " index < ", "parent": 790, "children": [792, 793, 794], "start_point": {"row": 209, "column": 17}, "end_point": {"row": 209, "column": 26}}, {"id": 792, "type": "identifier", "text": " inde", "parent": 791, "children": [], "start_point": {"row": 209, "column": 17}, "end_point": {"row": 209, "column": 22}}, {"id": 793, "type": "=", "text": " ", "parent": 791, "children": [], "start_point": {"row": 209, "column": 23}, "end_point": {"row": 209, "column": 24}}, {"id": 794, "type": "number_literal", "text": " ", "parent": 791, "children": [], "start_point": {"row": 209, "column": 25}, "end_point": {"row": 209, "column": 26}}, {"id": 795, "type": "binary_expression", "text": "fo_len / 2; index++)", "parent": 790, "children": [796, 797, 798], "start_point": {"row": 209, "column": 28}, "end_point": {"row": 209, "column": 48}}, {"id": 796, "type": "identifier", "text": "fo_le", "parent": 795, "children": [], "start_point": {"row": 209, "column": 28}, "end_point": {"row": 209, "column": 33}}, {"id": 797, "type": "<", "text": " ", "parent": 795, "children": [], "start_point": {"row": 209, "column": 34}, "end_point": {"row": 209, "column": 35}}, {"id": 798, "type": "binary_expression", "text": " 2; index++)", "parent": 795, "children": [799, 800], "start_point": {"row": 209, "column": 36}, "end_point": {"row": 209, "column": 48}}, {"id": 799, "type": "identifier", "text": " 2; inde", "parent": 798, "children": [], "start_point": {"row": 209, "column": 36}, "end_point": {"row": 209, "column": 44}}, {"id": 800, "type": "/", "text": "+", "parent": 798, "children": [], "start_point": {"row": 209, "column": 45}, "end_point": {"row": 209, "column": 46}}, {"id": 801, "type": "update_expression", "text": " ", "parent": 790, "children": [802, 803], "start_point": {"row": 209, "column": 50}, "end_point": {"row": 209, "column": 57}}, {"id": 802, "type": "identifier", "text": " ", "parent": 801, "children": [], "start_point": {"row": 209, "column": 50}, "end_point": {"row": 209, "column": 55}}, {"id": 803, "type": "++", "text": " ", "parent": 801, "children": [], "start_point": {"row": 209, "column": 55}, "end_point": {"row": 209, "column": 57}}, {"id": 804, "type": "assignment_expression", "text": "->dr[0] = ((uint16_t *)tx_buff)[i++];\n ", "parent": 790, "children": [805, 811, 812], "start_point": {"row": 210, "column": 16}, "end_point": {"row": 210, "column": 62}}, {"id": 805, "type": "subscript_expression", "text": "->dr[0] = ((uint1", "parent": 804, "children": [806, 810], "start_point": {"row": 210, "column": 16}, "end_point": {"row": 210, "column": 33}}, {"id": 806, "type": "field_expression", "text": "->dr[0] = ((ui", "parent": 805, "children": [807, 808, 809], "start_point": {"row": 210, "column": 16}, "end_point": {"row": 210, "column": 30}}, {"id": 807, "type": "identifier", "text": "->dr[0] = ", "parent": 806, "children": [], "start_point": {"row": 210, "column": 16}, "end_point": {"row": 210, "column": 26}}, {"id": 808, "type": "->", "text": "((", "parent": 806, "children": [], "start_point": {"row": 210, "column": 26}, "end_point": {"row": 210, "column": 28}}, {"id": 809, "type": "field_identifier", "text": "ui", "parent": 806, "children": [], "start_point": {"row": 210, "column": 28}, "end_point": {"row": 210, "column": 30}}, {"id": 810, "type": "number_literal", "text": "t", "parent": 805, "children": [], "start_point": {"row": 210, "column": 31}, "end_point": {"row": 210, "column": 32}}, {"id": 811, "type": "=", "text": "_", "parent": 804, "children": [], "start_point": {"row": 210, "column": 34}, "end_point": {"row": 210, "column": 35}}, {"id": 812, "type": "subscript_expression", "text": " *)tx_buff)[i++];\n ", "parent": 804, "children": [813, 818], "start_point": {"row": 210, "column": 36}, "end_point": {"row": 210, "column": 62}}, {"id": 813, "type": "parenthesized_expression", "text": " *)tx_buff)[i++];\n ", "parent": 812, "children": [814], "start_point": {"row": 210, "column": 36}, "end_point": {"row": 210, "column": 57}}, {"id": 814, "type": "cast_expression", "text": "*)tx_buff)[i++];\n ", "parent": 813, "children": [815, 817], "start_point": {"row": 210, "column": 37}, "end_point": {"row": 210, "column": 56}}, {"id": 815, "type": "type_descriptor", "text": ")tx_buff)[", "parent": 814, "children": [816], "start_point": {"row": 210, "column": 38}, "end_point": {"row": 210, "column": 48}}, {"id": 816, "type": "primitive_type", "text": ")tx_buff", "parent": 815, "children": [], "start_point": {"row": 210, "column": 38}, "end_point": {"row": 210, "column": 46}}, {"id": 817, "type": "identifier", "text": "++];\n ", "parent": 814, "children": [], "start_point": {"row": 210, "column": 49}, "end_point": {"row": 210, "column": 56}}, {"id": 818, "type": "update_expression", "text": " ", "parent": 812, "children": [819, 820], "start_point": {"row": 210, "column": 58}, "end_point": {"row": 210, "column": 61}}, {"id": 819, "type": "identifier", "text": " ", "parent": 818, "children": [], "start_point": {"row": 210, "column": 58}, "end_point": {"row": 210, "column": 59}}, {"id": 820, "type": "++", "text": " ", "parent": 818, "children": [], "start_point": {"row": 210, "column": 59}, "end_point": {"row": 210, "column": 61}}, {"id": 821, "type": "break_statement", "text": " d", "parent": 777, "children": [822], "start_point": {"row": 211, "column": 12}, "end_point": {"row": 211, "column": 18}}, {"id": 822, "type": "break", "text": " ", "parent": 821, "children": [], "start_point": {"row": 211, "column": 12}, "end_point": {"row": 211, "column": 17}}, {"id": 823, "type": "case_statement", "text": " for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }", "parent": 727, "children": [824, 825], "start_point": {"row": 212, "column": 8}, "end_point": {"row": 215, "column": 18}}, {"id": 824, "type": "default", "text": " ", "parent": 823, "children": [], "start_point": {"row": 212, "column": 8}, "end_point": {"row": 212, "column": 15}}, {"id": 825, "type": "for_statement", "text": " = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n ", "parent": 823, "children": [826, 830, 833], "start_point": {"row": 213, "column": 12}, "end_point": {"row": 214, "column": 49}}, {"id": 826, "type": "assignment_expression", "text": " index < ", "parent": 825, "children": [827, 828, 829], "start_point": {"row": 213, "column": 17}, "end_point": {"row": 213, "column": 26}}, {"id": 827, "type": "identifier", "text": " inde", "parent": 826, "children": [], "start_point": {"row": 213, "column": 17}, "end_point": {"row": 213, "column": 22}}, {"id": 828, "type": "=", "text": " ", "parent": 826, "children": [], "start_point": {"row": 213, "column": 23}, "end_point": {"row": 213, "column": 24}}, {"id": 829, "type": "number_literal", "text": " ", "parent": 826, "children": [], "start_point": {"row": 213, "column": 25}, "end_point": {"row": 213, "column": 26}}, {"id": 830, "type": "binary_expression", "text": "fo_len; index++)", "parent": 825, "children": [831, 832], "start_point": {"row": 213, "column": 28}, "end_point": {"row": 213, "column": 44}}, {"id": 831, "type": "identifier", "text": "fo_le", "parent": 830, "children": [], "start_point": {"row": 213, "column": 28}, "end_point": {"row": 213, "column": 33}}, {"id": 832, "type": "identifier", "text": "index++)", "parent": 830, "children": [], "start_point": {"row": 213, "column": 36}, "end_point": {"row": 213, "column": 44}}, {"id": 833, "type": "update_expression", "text": " ", "parent": 825, "children": [834, 835], "start_point": {"row": 213, "column": 46}, "end_point": {"row": 213, "column": 53}}, {"id": 834, "type": "identifier", "text": " ", "parent": 833, "children": [], "start_point": {"row": 213, "column": 46}, "end_point": {"row": 213, "column": 51}}, {"id": 835, "type": "++", "text": " ", "parent": 833, "children": [], "start_point": {"row": 213, "column": 51}, "end_point": {"row": 213, "column": 53}}, {"id": 836, "type": "assignment_expression", "text": "->dr[0] = tx_buff[i++];\n ", "parent": 825, "children": [837, 843, 844], "start_point": {"row": 214, "column": 16}, "end_point": {"row": 214, "column": 48}}, {"id": 837, "type": "subscript_expression", "text": "->dr[0] = tx_buff", "parent": 836, "children": [838, 842], "start_point": {"row": 214, "column": 16}, "end_point": {"row": 214, "column": 33}}, {"id": 838, "type": "field_expression", "text": "->dr[0] = tx_b", "parent": 837, "children": [839, 840, 841], "start_point": {"row": 214, "column": 16}, "end_point": {"row": 214, "column": 30}}, {"id": 839, "type": "identifier", "text": "->dr[0] = ", "parent": 838, "children": [], "start_point": {"row": 214, "column": 16}, "end_point": {"row": 214, "column": 26}}, {"id": 840, "type": "->", "text": "tx", "parent": 838, "children": [], "start_point": {"row": 214, "column": 26}, "end_point": {"row": 214, "column": 28}}, {"id": 841, "type": "field_identifier", "text": "_b", "parent": 838, "children": [], "start_point": {"row": 214, "column": 28}, "end_point": {"row": 214, "column": 30}}, {"id": 842, "type": "number_literal", "text": "f", "parent": 837, "children": [], "start_point": {"row": 214, "column": 31}, "end_point": {"row": 214, "column": 32}}, {"id": 843, "type": "=", "text": "i", "parent": 836, "children": [], "start_point": {"row": 214, "column": 34}, "end_point": {"row": 214, "column": 35}}, {"id": 844, "type": "subscript_expression", "text": "+];\n ", "parent": 836, "children": [845, 846], "start_point": {"row": 214, "column": 36}, "end_point": {"row": 214, "column": 48}}, {"id": 845, "type": "identifier", "text": "+];\n ", "parent": 844, "children": [], "start_point": {"row": 214, "column": 36}, "end_point": {"row": 214, "column": 43}}, {"id": 846, "type": "update_expression", "text": " ", "parent": 844, "children": [847, 848], "start_point": {"row": 214, "column": 44}, "end_point": {"row": 214, "column": 47}}, {"id": 847, "type": "identifier", "text": " ", "parent": 846, "children": [], "start_point": {"row": 214, "column": 44}, "end_point": {"row": 214, "column": 45}}, {"id": 848, "type": "++", "text": " ", "parent": 846, "children": [], "start_point": {"row": 214, "column": 45}, "end_point": {"row": 214, "column": 47}}, {"id": 849, "type": "break", "text": " ", "parent": 823, "children": [], "start_point": {"row": 215, "column": 12}, "end_point": {"row": 215, "column": 17}}, {"id": 850, "type": "assignment_expression", "text": "fifo_len;\n }\n\n ", "parent": 705, "children": [851, 852], "start_point": {"row": 217, "column": 8}, "end_point": {"row": 217, "column": 26}}, {"id": 851, "type": "identifier", "text": "fifo_l", "parent": 850, "children": [], "start_point": {"row": 217, "column": 8}, "end_point": {"row": 217, "column": 14}}, {"id": 852, "type": "-=", "text": "n;", "parent": 850, "children": [], "start_point": {"row": 217, "column": 15}, "end_point": {"row": 217, "column": 17}}, {"id": 853, "type": "while_statement", "text": "i_handle->sr & 0x05) != 0x04)\n ;\n i = 0", "parent": 525, "children": [854], "start_point": {"row": 220, "column": 4}, "end_point": {"row": 221, "column": 9}}, {"id": 854, "type": "parenthesized_expression", "text": "le->sr & 0x05) != 0x04)\n ;", "parent": 853, "children": [855], "start_point": {"row": 220, "column": 10}, "end_point": {"row": 220, "column": 43}}, {"id": 855, "type": "binary_expression", "text": "e->sr & 0x05) != 0x04)\n ", "parent": 854, "children": [856, 864, 865], "start_point": {"row": 220, "column": 11}, "end_point": {"row": 220, "column": 42}}, {"id": 856, "type": "parenthesized_expression", "text": "e->sr & 0x05) != 0x04)\n", "parent": 855, "children": [857], "start_point": {"row": 220, "column": 11}, "end_point": {"row": 220, "column": 34}}, {"id": 857, "type": "binary_expression", "text": "->sr & 0x05) != 0x04)", "parent": 856, "children": [858, 862, 863], "start_point": {"row": 220, "column": 12}, "end_point": {"row": 220, "column": 33}}, {"id": 858, "type": "field_expression", "text": "->sr & 0x05) !", "parent": 857, "children": [859, 860, 861], "start_point": {"row": 220, "column": 12}, "end_point": {"row": 220, "column": 26}}, {"id": 859, "type": "identifier", "text": "->sr & 0x0", "parent": 858, "children": [], "start_point": {"row": 220, "column": 12}, "end_point": {"row": 220, "column": 22}}, {"id": 860, "type": "->", "text": "5)", "parent": 858, "children": [], "start_point": {"row": 220, "column": 22}, "end_point": {"row": 220, "column": 24}}, {"id": 861, "type": "field_identifier", "text": " !", "parent": 858, "children": [], "start_point": {"row": 220, "column": 24}, "end_point": {"row": 220, "column": 26}}, {"id": 862, "type": "&", "text": " ", "parent": 857, "children": [], "start_point": {"row": 220, "column": 27}, "end_point": {"row": 220, "column": 28}}, {"id": 863, "type": "number_literal", "text": "x04)", "parent": 857, "children": [], "start_point": {"row": 220, "column": 29}, "end_point": {"row": 220, "column": 33}}, {"id": 864, "type": "!=", "text": " ", "parent": 855, "children": [], "start_point": {"row": 220, "column": 35}, "end_point": {"row": 220, "column": 37}}, {"id": 865, "type": "number_literal", "text": " ", "parent": 855, "children": [], "start_point": {"row": 220, "column": 38}, "end_point": {"row": 220, "column": 42}}, {"id": 866, "type": "assignment_expression", "text": " whil", "parent": 525, "children": [867, 868, 869], "start_point": {"row": 222, "column": 4}, "end_point": {"row": 222, "column": 9}}, {"id": 867, "type": "identifier", "text": " ", "parent": 866, "children": [], "start_point": {"row": 222, "column": 4}, "end_point": {"row": 222, "column": 5}}, {"id": 868, "type": "=", "text": "h", "parent": 866, "children": [], "start_point": {"row": 222, "column": 6}, "end_point": {"row": 222, "column": 7}}, {"id": 869, "type": "number_literal", "text": "l", "parent": 866, "children": [], "start_point": {"row": 222, "column": 8}, "end_point": {"row": 222, "column": 9}}, {"id": 870, "type": "while_statement", "text": "len)\n {\n fifo_len = spi_handle->rxflr;\n fifo_len = fifo_len < rx_len ? fifo_len : rx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n rx_len -= fifo_len;\n }\n spi_h", "parent": 525, "children": [], "start_point": {"row": 223, "column": 4}, "end_point": {"row": 246, "column": 5}}, {"id": 871, "type": "assignment_expression", "text": " spi_handle->rxflr;\n ", "parent": 870, "children": [872, 873, 874], "start_point": {"row": 225, "column": 8}, "end_point": {"row": 225, "column": 36}}, {"id": 872, "type": "identifier", "text": " spi_han", "parent": 871, "children": [], "start_point": {"row": 225, "column": 8}, "end_point": {"row": 225, "column": 16}}, {"id": 873, "type": "=", "text": "l", "parent": 871, "children": [], "start_point": {"row": 225, "column": 17}, "end_point": {"row": 225, "column": 18}}, {"id": 874, "type": "field_expression", "text": "->rxflr;\n ", "parent": 871, "children": [875, 876, 877], "start_point": {"row": 225, "column": 19}, "end_point": {"row": 225, "column": 36}}, {"id": 875, "type": "identifier", "text": "->rxflr;\n ", "parent": 874, "children": [], "start_point": {"row": 225, "column": 19}, "end_point": {"row": 225, "column": 29}}, {"id": 876, "type": "->", "text": " ", "parent": 874, "children": [], "start_point": {"row": 225, "column": 29}, "end_point": {"row": 225, "column": 31}}, {"id": 877, "type": "field_identifier", "text": " ", "parent": 874, "children": [], "start_point": {"row": 225, "column": 31}, "end_point": {"row": 225, "column": 36}}, {"id": 878, "type": "assignment_expression", "text": " fifo_len < rx_len ? fifo_len : rx_len;\n ", "parent": 870, "children": [879, 880, 881], "start_point": {"row": 226, "column": 8}, "end_point": {"row": 226, "column": 56}}, {"id": 879, "type": "identifier", "text": " fifo_le", "parent": 878, "children": [], "start_point": {"row": 226, "column": 8}, "end_point": {"row": 226, "column": 16}}, {"id": 880, "type": "=", "text": " ", "parent": 878, "children": [], "start_point": {"row": 226, "column": 17}, "end_point": {"row": 226, "column": 18}}, {"id": 881, "type": "conditional_expression", "text": " rx_len ? fifo_len : rx_len;\n ", "parent": 878, "children": [882, 886, 887, 888], "start_point": {"row": 226, "column": 19}, "end_point": {"row": 226, "column": 56}}, {"id": 882, "type": "binary_expression", "text": " rx_len ? fifo_le", "parent": 881, "children": [883, 884, 885], "start_point": {"row": 226, "column": 19}, "end_point": {"row": 226, "column": 36}}, {"id": 883, "type": "identifier", "text": " rx_len ", "parent": 882, "children": [], "start_point": {"row": 226, "column": 19}, "end_point": {"row": 226, "column": 27}}, {"id": 884, "type": "<", "text": " ", "parent": 882, "children": [], "start_point": {"row": 226, "column": 28}, "end_point": {"row": 226, "column": 29}}, {"id": 885, "type": "identifier", "text": "ifo_le", "parent": 882, "children": [], "start_point": {"row": 226, "column": 30}, "end_point": {"row": 226, "column": 36}}, {"id": 886, "type": "?", "text": " ", "parent": 881, "children": [], "start_point": {"row": 226, "column": 37}, "end_point": {"row": 226, "column": 38}}, {"id": 887, "type": "identifier", "text": " rx_len;", "parent": 881, "children": [], "start_point": {"row": 226, "column": 39}, "end_point": {"row": 226, "column": 47}}, {"id": 888, "type": "identifier", "text": " ", "parent": 881, "children": [], "start_point": {"row": 226, "column": 50}, "end_point": {"row": 226, "column": 56}}, {"id": 889, "type": "switch_statement", "text": "ame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n ", "parent": 870, "children": [890, 891], "start_point": {"row": 227, "column": 8}, "end_point": {"row": 243, "column": 9}}, {"id": 890, "type": "switch", "text": "ame_wi", "parent": 889, "children": [], "start_point": {"row": 227, "column": 8}, "end_point": {"row": 227, "column": 14}}, {"id": 891, "type": "parenthesized_expression", "text": "th)\n {", "parent": 889, "children": [892], "start_point": {"row": 227, "column": 15}, "end_point": {"row": 227, "column": 28}}, {"id": 892, "type": "identifier", "text": "h)\n ", "parent": 891, "children": [], "start_point": {"row": 227, "column": 16}, "end_point": {"row": 227, "column": 27}}, {"id": 893, "type": "case_statement", "text": "RANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n c", "parent": 889, "children": [894, 895, 906, 937], "start_point": {"row": 229, "column": 8}, "end_point": {"row": 233, "column": 18}}, {"id": 894, "type": "case", "text": "RANS", "parent": 893, "children": [], "start_point": {"row": 229, "column": 8}, "end_point": {"row": 229, "column": 12}}, {"id": 895, "type": "identifier", "text": "INT:\n ", "parent": 893, "children": [], "start_point": {"row": 229, "column": 13}, "end_point": {"row": 229, "column": 26}}, {"id": 896, "type": "assignment_expression", "text": " fifo_len / 4 * 4;\n ", "parent": 893, "children": [897, 898, 899], "start_point": {"row": 230, "column": 12}, "end_point": {"row": 230, "column": 39}}, {"id": 897, "type": "identifier", "text": " fifo_le", "parent": 896, "children": [], "start_point": {"row": 230, "column": 12}, "end_point": {"row": 230, "column": 20}}, {"id": 898, "type": "=", "text": " ", "parent": 896, "children": [], "start_point": {"row": 230, "column": 21}, "end_point": {"row": 230, "column": 22}}, {"id": 899, "type": "binary_expression", "text": " 4 * 4;\n ", "parent": 896, "children": [900, 904, 905], "start_point": {"row": 230, "column": 23}, "end_point": {"row": 230, "column": 39}}, {"id": 900, "type": "binary_expression", "text": " 4 * 4;\n ", "parent": 899, "children": [901, 902, 903], "start_point": {"row": 230, "column": 23}, "end_point": {"row": 230, "column": 35}}, {"id": 901, "type": "identifier", "text": " 4 * 4;\n", "parent": 900, "children": [], "start_point": {"row": 230, "column": 23}, "end_point": {"row": 230, "column": 31}}, {"id": 902, "type": "/", "text": " ", "parent": 900, "children": [], "start_point": {"row": 230, "column": 32}, "end_point": {"row": 230, "column": 33}}, {"id": 903, "type": "number_literal", "text": " ", "parent": 900, "children": [], "start_point": {"row": 230, "column": 34}, "end_point": {"row": 230, "column": 35}}, {"id": 904, "type": "*", "text": " ", "parent": 899, "children": [], "start_point": {"row": 230, "column": 36}, "end_point": {"row": 230, "column": 37}}, {"id": 905, "type": "number_literal", "text": " ", "parent": 899, "children": [], "start_point": {"row": 230, "column": 38}, "end_point": {"row": 230, "column": 39}}, {"id": 906, "type": "for_statement", "text": " = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n ", "parent": 893, "children": [907, 911, 917], "start_point": {"row": 231, "column": 12}, "end_point": {"row": 232, "column": 63}}, {"id": 907, "type": "assignment_expression", "text": " index < ", "parent": 906, "children": [908, 909, 910], "start_point": {"row": 231, "column": 17}, "end_point": {"row": 231, "column": 26}}, {"id": 908, "type": "identifier", "text": " inde", "parent": 907, "children": [], "start_point": {"row": 231, "column": 17}, "end_point": {"row": 231, "column": 22}}, {"id": 909, "type": "=", "text": " ", "parent": 907, "children": [], "start_point": {"row": 231, "column": 23}, "end_point": {"row": 231, "column": 24}}, {"id": 910, "type": "number_literal", "text": " ", "parent": 907, "children": [], "start_point": {"row": 231, "column": 25}, "end_point": {"row": 231, "column": 26}}, {"id": 911, "type": "binary_expression", "text": "fo_len / 4; index++)", "parent": 906, "children": [912, 913, 914], "start_point": {"row": 231, "column": 28}, "end_point": {"row": 231, "column": 48}}, {"id": 912, "type": "identifier", "text": "fo_le", "parent": 911, "children": [], "start_point": {"row": 231, "column": 28}, "end_point": {"row": 231, "column": 33}}, {"id": 913, "type": "<", "text": " ", "parent": 911, "children": [], "start_point": {"row": 231, "column": 34}, "end_point": {"row": 231, "column": 35}}, {"id": 914, "type": "binary_expression", "text": " 4; index++)", "parent": 911, "children": [915, 916], "start_point": {"row": 231, "column": 36}, "end_point": {"row": 231, "column": 48}}, {"id": 915, "type": "identifier", "text": " 4; inde", "parent": 914, "children": [], "start_point": {"row": 231, "column": 36}, "end_point": {"row": 231, "column": 44}}, {"id": 916, "type": "/", "text": "+", "parent": 914, "children": [], "start_point": {"row": 231, "column": 45}, "end_point": {"row": 231, "column": 46}}, {"id": 917, "type": "update_expression", "text": " ", "parent": 906, "children": [918, 919], "start_point": {"row": 231, "column": 50}, "end_point": {"row": 231, "column": 57}}, {"id": 918, "type": "identifier", "text": " ", "parent": 917, "children": [], "start_point": {"row": 231, "column": 50}, "end_point": {"row": 231, "column": 55}}, {"id": 919, "type": "++", "text": " ", "parent": 917, "children": [], "start_point": {"row": 231, "column": 55}, "end_point": {"row": 231, "column": 57}}, {"id": 920, "type": "assignment_expression", "text": " *)rx_buff)[i++] = spi_handle->dr[0];\n ", "parent": 906, "children": [921, 930, 931], "start_point": {"row": 232, "column": 16}, "end_point": {"row": 232, "column": 62}}, {"id": 921, "type": "subscript_expression", "text": " *)rx_buff)[i++] = spi_han", "parent": 920, "children": [922, 927], "start_point": {"row": 232, "column": 16}, "end_point": {"row": 232, "column": 42}}, {"id": 922, "type": "parenthesized_expression", "text": " *)rx_buff)[i++] = sp", "parent": 921, "children": [923], "start_point": {"row": 232, "column": 16}, "end_point": {"row": 232, "column": 37}}, {"id": 923, "type": "cast_expression", "text": "*)rx_buff)[i++] = s", "parent": 922, "children": [924, 926], "start_point": {"row": 232, "column": 17}, "end_point": {"row": 232, "column": 36}}, {"id": 924, "type": "type_descriptor", "text": ")rx_buff)[", "parent": 923, "children": [925], "start_point": {"row": 232, "column": 18}, "end_point": {"row": 232, "column": 28}}, {"id": 925, "type": "primitive_type", "text": ")rx_buff", "parent": 924, "children": [], "start_point": {"row": 232, "column": 18}, "end_point": {"row": 232, "column": 26}}, {"id": 926, "type": "identifier", "text": "++] = s", "parent": 923, "children": [], "start_point": {"row": 232, "column": 29}, "end_point": {"row": 232, "column": 36}}, {"id": 927, "type": "update_expression", "text": "_ha", "parent": 921, "children": [928, 929], "start_point": {"row": 232, "column": 38}, "end_point": {"row": 232, "column": 41}}, {"id": 928, "type": "identifier", "text": "_", "parent": 927, "children": [], "start_point": {"row": 232, "column": 38}, "end_point": {"row": 232, "column": 39}}, {"id": 929, "type": "++", "text": "ha", "parent": 927, "children": [], "start_point": {"row": 232, "column": 39}, "end_point": {"row": 232, "column": 41}}, {"id": 930, "type": "=", "text": "l", "parent": 920, "children": [], "start_point": {"row": 232, "column": 43}, "end_point": {"row": 232, "column": 44}}, {"id": 931, "type": "subscript_expression", "text": "->dr[0];\n ", "parent": 920, "children": [932, 936], "start_point": {"row": 232, "column": 45}, "end_point": {"row": 232, "column": 62}}, {"id": 932, "type": "field_expression", "text": "->dr[0];\n ", "parent": 931, "children": [933, 934, 935], "start_point": {"row": 232, "column": 45}, "end_point": {"row": 232, "column": 59}}, {"id": 933, "type": "identifier", "text": "->dr[0];\n ", "parent": 932, "children": [], "start_point": {"row": 232, "column": 45}, "end_point": {"row": 232, "column": 55}}, {"id": 934, "type": "->", "text": " ", "parent": 932, "children": [], "start_point": {"row": 232, "column": 55}, "end_point": {"row": 232, "column": 57}}, {"id": 935, "type": "field_identifier", "text": " ", "parent": 932, "children": [], "start_point": {"row": 232, "column": 57}, "end_point": {"row": 232, "column": 59}}, {"id": 936, "type": "number_literal", "text": " ", "parent": 931, "children": [], "start_point": {"row": 232, "column": 60}, "end_point": {"row": 232, "column": 61}}, {"id": 937, "type": "break_statement", "text": " c", "parent": 893, "children": [938], "start_point": {"row": 233, "column": 12}, "end_point": {"row": 233, "column": 18}}, {"id": 938, "type": "break", "text": " ", "parent": 937, "children": [], "start_point": {"row": 233, "column": 12}, "end_point": {"row": 233, "column": 17}}, {"id": 939, "type": "case_statement", "text": "RANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n d", "parent": 889, "children": [940, 941, 952, 986], "start_point": {"row": 234, "column": 8}, "end_point": {"row": 238, "column": 18}}, {"id": 940, "type": "case", "text": "RANS", "parent": 939, "children": [], "start_point": {"row": 234, "column": 8}, "end_point": {"row": 234, "column": 12}}, {"id": 941, "type": "identifier", "text": "SHORT:\n ", "parent": 939, "children": [], "start_point": {"row": 234, "column": 13}, "end_point": {"row": 234, "column": 28}}, {"id": 942, "type": "assignment_expression", "text": " fifo_len / 2 * 2;\n ", "parent": 939, "children": [943, 944, 945], "start_point": {"row": 235, "column": 12}, "end_point": {"row": 235, "column": 39}}, {"id": 943, "type": "identifier", "text": " fifo_le", "parent": 942, "children": [], "start_point": {"row": 235, "column": 12}, "end_point": {"row": 235, "column": 20}}, {"id": 944, "type": "=", "text": " ", "parent": 942, "children": [], "start_point": {"row": 235, "column": 21}, "end_point": {"row": 235, "column": 22}}, {"id": 945, "type": "binary_expression", "text": " 2 * 2;\n ", "parent": 942, "children": [946, 950, 951], "start_point": {"row": 235, "column": 23}, "end_point": {"row": 235, "column": 39}}, {"id": 946, "type": "binary_expression", "text": " 2 * 2;\n ", "parent": 945, "children": [947, 948, 949], "start_point": {"row": 235, "column": 23}, "end_point": {"row": 235, "column": 35}}, {"id": 947, "type": "identifier", "text": " 2 * 2;\n", "parent": 946, "children": [], "start_point": {"row": 235, "column": 23}, "end_point": {"row": 235, "column": 31}}, {"id": 948, "type": "/", "text": " ", "parent": 946, "children": [], "start_point": {"row": 235, "column": 32}, "end_point": {"row": 235, "column": 33}}, {"id": 949, "type": "number_literal", "text": " ", "parent": 946, "children": [], "start_point": {"row": 235, "column": 34}, "end_point": {"row": 235, "column": 35}}, {"id": 950, "type": "*", "text": " ", "parent": 945, "children": [], "start_point": {"row": 235, "column": 36}, "end_point": {"row": 235, "column": 37}}, {"id": 951, "type": "number_literal", "text": " ", "parent": 945, "children": [], "start_point": {"row": 235, "column": 38}, "end_point": {"row": 235, "column": 39}}, {"id": 952, "type": "for_statement", "text": " = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n ", "parent": 939, "children": [953, 957, 963], "start_point": {"row": 236, "column": 12}, "end_point": {"row": 237, "column": 73}}, {"id": 953, "type": "assignment_expression", "text": " index < ", "parent": 952, "children": [954, 955, 956], "start_point": {"row": 236, "column": 17}, "end_point": {"row": 236, "column": 26}}, {"id": 954, "type": "identifier", "text": " inde", "parent": 953, "children": [], "start_point": {"row": 236, "column": 17}, "end_point": {"row": 236, "column": 22}}, {"id": 955, "type": "=", "text": " ", "parent": 953, "children": [], "start_point": {"row": 236, "column": 23}, "end_point": {"row": 236, "column": 24}}, {"id": 956, "type": "number_literal", "text": " ", "parent": 953, "children": [], "start_point": {"row": 236, "column": 25}, "end_point": {"row": 236, "column": 26}}, {"id": 957, "type": "binary_expression", "text": "fo_len / 2; index++)", "parent": 952, "children": [958, 959, 960], "start_point": {"row": 236, "column": 28}, "end_point": {"row": 236, "column": 48}}, {"id": 958, "type": "identifier", "text": "fo_le", "parent": 957, "children": [], "start_point": {"row": 236, "column": 28}, "end_point": {"row": 236, "column": 33}}, {"id": 959, "type": "<", "text": " ", "parent": 957, "children": [], "start_point": {"row": 236, "column": 34}, "end_point": {"row": 236, "column": 35}}, {"id": 960, "type": "binary_expression", "text": " 2; index++)", "parent": 957, "children": [961, 962], "start_point": {"row": 236, "column": 36}, "end_point": {"row": 236, "column": 48}}, {"id": 961, "type": "identifier", "text": " 2; inde", "parent": 960, "children": [], "start_point": {"row": 236, "column": 36}, "end_point": {"row": 236, "column": 44}}, {"id": 962, "type": "/", "text": "+", "parent": 960, "children": [], "start_point": {"row": 236, "column": 45}, "end_point": {"row": 236, "column": 46}}, {"id": 963, "type": "update_expression", "text": " ", "parent": 952, "children": [964, 965], "start_point": {"row": 236, "column": 50}, "end_point": {"row": 236, "column": 57}}, {"id": 964, "type": "identifier", "text": " ", "parent": 963, "children": [], "start_point": {"row": 236, "column": 50}, "end_point": {"row": 236, "column": 55}}, {"id": 965, "type": "++", "text": " ", "parent": 963, "children": [], "start_point": {"row": 236, "column": 55}, "end_point": {"row": 236, "column": 57}}, {"id": 966, "type": "assignment_expression", "text": " *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n ", "parent": 952, "children": [967, 976, 977], "start_point": {"row": 237, "column": 16}, "end_point": {"row": 237, "column": 72}}, {"id": 967, "type": "subscript_expression", "text": " *)rx_buff)[i++] = (uint16", "parent": 966, "children": [968, 973], "start_point": {"row": 237, "column": 16}, "end_point": {"row": 237, "column": 42}}, {"id": 968, "type": "parenthesized_expression", "text": " *)rx_buff)[i++] = (u", "parent": 967, "children": [969], "start_point": {"row": 237, "column": 16}, "end_point": {"row": 237, "column": 37}}, {"id": 969, "type": "cast_expression", "text": "*)rx_buff)[i++] = (", "parent": 968, "children": [970, 972], "start_point": {"row": 237, "column": 17}, "end_point": {"row": 237, "column": 36}}, {"id": 970, "type": "type_descriptor", "text": ")rx_buff)[", "parent": 969, "children": [971], "start_point": {"row": 237, "column": 18}, "end_point": {"row": 237, "column": 28}}, {"id": 971, "type": "primitive_type", "text": ")rx_buff", "parent": 970, "children": [], "start_point": {"row": 237, "column": 18}, "end_point": {"row": 237, "column": 26}}, {"id": 972, "type": "identifier", "text": "++] = (", "parent": 969, "children": [], "start_point": {"row": 237, "column": 29}, "end_point": {"row": 237, "column": 36}}, {"id": 973, "type": "update_expression", "text": "nt1", "parent": 967, "children": [974, 975], "start_point": {"row": 237, "column": 38}, "end_point": {"row": 237, "column": 41}}, {"id": 974, "type": "identifier", "text": "n", "parent": 973, "children": [], "start_point": {"row": 237, "column": 38}, "end_point": {"row": 237, "column": 39}}, {"id": 975, "type": "++", "text": "t1", "parent": 973, "children": [], "start_point": {"row": 237, "column": 39}, "end_point": {"row": 237, "column": 41}}, {"id": 976, "type": "=", "text": "t", "parent": 966, "children": [], "start_point": {"row": 237, "column": 43}, "end_point": {"row": 237, "column": 44}}, {"id": 977, "type": "cast_expression", "text": "spi_handle->dr[0];\n ", "parent": 966, "children": [978, 980], "start_point": {"row": 237, "column": 45}, "end_point": {"row": 237, "column": 72}}, {"id": 978, "type": "type_descriptor", "text": "pi_handl", "parent": 977, "children": [979], "start_point": {"row": 237, "column": 46}, "end_point": {"row": 237, "column": 54}}, {"id": 979, "type": "primitive_type", "text": "pi_handl", "parent": 978, "children": [], "start_point": {"row": 237, "column": 46}, "end_point": {"row": 237, "column": 54}}, {"id": 980, "type": "subscript_expression", "text": "->dr[0];\n ", "parent": 977, "children": [981, 985], "start_point": {"row": 237, "column": 55}, "end_point": {"row": 237, "column": 72}}, {"id": 981, "type": "field_expression", "text": "->dr[0];\n ", "parent": 980, "children": [982, 983, 984], "start_point": {"row": 237, "column": 55}, "end_point": {"row": 237, "column": 69}}, {"id": 982, "type": "identifier", "text": "->dr[0];\n ", "parent": 981, "children": [], "start_point": {"row": 237, "column": 55}, "end_point": {"row": 237, "column": 65}}, {"id": 983, "type": "->", "text": " ", "parent": 981, "children": [], "start_point": {"row": 237, "column": 65}, "end_point": {"row": 237, "column": 67}}, {"id": 984, "type": "field_identifier", "text": " ", "parent": 981, "children": [], "start_point": {"row": 237, "column": 67}, "end_point": {"row": 237, "column": 69}}, {"id": 985, "type": "number_literal", "text": " ", "parent": 980, "children": [], "start_point": {"row": 237, "column": 70}, "end_point": {"row": 237, "column": 71}}, {"id": 986, "type": "break_statement", "text": " d", "parent": 939, "children": [987], "start_point": {"row": 238, "column": 12}, "end_point": {"row": 238, "column": 18}}, {"id": 987, "type": "break", "text": " ", "parent": 986, "children": [], "start_point": {"row": 238, "column": 12}, "end_point": {"row": 238, "column": 17}}, {"id": 988, "type": "case_statement", "text": " for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }", "parent": 889, "children": [989, 990], "start_point": {"row": 239, "column": 8}, "end_point": {"row": 242, "column": 18}}, {"id": 989, "type": "default", "text": " ", "parent": 988, "children": [], "start_point": {"row": 239, "column": 8}, "end_point": {"row": 239, "column": 15}}, {"id": 990, "type": "for_statement", "text": " = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n ", "parent": 988, "children": [991, 995, 998], "start_point": {"row": 240, "column": 12}, "end_point": {"row": 241, "column": 58}}, {"id": 991, "type": "assignment_expression", "text": " index < ", "parent": 990, "children": [992, 993, 994], "start_point": {"row": 240, "column": 17}, "end_point": {"row": 240, "column": 26}}, {"id": 992, "type": "identifier", "text": " inde", "parent": 991, "children": [], "start_point": {"row": 240, "column": 17}, "end_point": {"row": 240, "column": 22}}, {"id": 993, "type": "=", "text": " ", "parent": 991, "children": [], "start_point": {"row": 240, "column": 23}, "end_point": {"row": 240, "column": 24}}, {"id": 994, "type": "number_literal", "text": " ", "parent": 991, "children": [], "start_point": {"row": 240, "column": 25}, "end_point": {"row": 240, "column": 26}}, {"id": 995, "type": "binary_expression", "text": "fo_len; index++)", "parent": 990, "children": [996, 997], "start_point": {"row": 240, "column": 28}, "end_point": {"row": 240, "column": 44}}, {"id": 996, "type": "identifier", "text": "fo_le", "parent": 995, "children": [], "start_point": {"row": 240, "column": 28}, "end_point": {"row": 240, "column": 33}}, {"id": 997, "type": "identifier", "text": "index++)", "parent": 995, "children": [], "start_point": {"row": 240, "column": 36}, "end_point": {"row": 240, "column": 44}}, {"id": 998, "type": "update_expression", "text": " ", "parent": 990, "children": [999, 1000], "start_point": {"row": 240, "column": 46}, "end_point": {"row": 240, "column": 53}}, {"id": 999, "type": "identifier", "text": " ", "parent": 998, "children": [], "start_point": {"row": 240, "column": 46}, "end_point": {"row": 240, "column": 51}}, {"id": 1000, "type": "++", "text": " ", "parent": 998, "children": [], "start_point": {"row": 240, "column": 51}, "end_point": {"row": 240, "column": 53}}, {"id": 1001, "type": "assignment_expression", "text": "+] = (uint8_t)spi_handle->dr[0];\n ", "parent": 990, "children": [1002, 1007], "start_point": {"row": 241, "column": 16}, "end_point": {"row": 241, "column": 57}}, {"id": 1002, "type": "subscript_expression", "text": "+] = (uint8_", "parent": 1001, "children": [1003, 1004], "start_point": {"row": 241, "column": 16}, "end_point": {"row": 241, "column": 28}}, {"id": 1003, "type": "identifier", "text": "+] = (u", "parent": 1002, "children": [], "start_point": {"row": 241, "column": 16}, "end_point": {"row": 241, "column": 23}}, {"id": 1004, "type": "update_expression", "text": "nt8", "parent": 1002, "children": [1005, 1006], "start_point": {"row": 241, "column": 24}, "end_point": {"row": 241, "column": 27}}, {"id": 1005, "type": "identifier", "text": "n", "parent": 1004, "children": [], "start_point": {"row": 241, "column": 24}, "end_point": {"row": 241, "column": 25}}, {"id": 1006, "type": "++", "text": "t8", "parent": 1004, "children": [], "start_point": {"row": 241, "column": 25}, "end_point": {"row": 241, "column": 27}}, {"id": 1007, "type": "cast_expression", "text": "pi_handle->dr[0];\n ", "parent": 1001, "children": [1008, 1010], "start_point": {"row": 241, "column": 31}, "end_point": {"row": 241, "column": 57}}, {"id": 1008, "type": "type_descriptor", "text": "i_handl", "parent": 1007, "children": [1009], "start_point": {"row": 241, "column": 32}, "end_point": {"row": 241, "column": 39}}, {"id": 1009, "type": "primitive_type", "text": "i_handl", "parent": 1008, "children": [], "start_point": {"row": 241, "column": 32}, "end_point": {"row": 241, "column": 39}}, {"id": 1010, "type": "subscript_expression", "text": "->dr[0];\n ", "parent": 1007, "children": [1011, 1015], "start_point": {"row": 241, "column": 40}, "end_point": {"row": 241, "column": 57}}, {"id": 1011, "type": "field_expression", "text": "->dr[0];\n ", "parent": 1010, "children": [1012, 1013, 1014], "start_point": {"row": 241, "column": 40}, "end_point": {"row": 241, "column": 54}}, {"id": 1012, "type": "identifier", "text": "->dr[0];\n ", "parent": 1011, "children": [], "start_point": {"row": 241, "column": 40}, "end_point": {"row": 241, "column": 50}}, {"id": 1013, "type": "->", "text": " ", "parent": 1011, "children": [], "start_point": {"row": 241, "column": 50}, "end_point": {"row": 241, "column": 52}}, {"id": 1014, "type": "field_identifier", "text": " ", "parent": 1011, "children": [], "start_point": {"row": 241, "column": 52}, "end_point": {"row": 241, "column": 54}}, {"id": 1015, "type": "number_literal", "text": " ", "parent": 1010, "children": [], "start_point": {"row": 241, "column": 55}, "end_point": {"row": 241, "column": 56}}, {"id": 1016, "type": "break", "text": " ", "parent": 988, "children": [], "start_point": {"row": 242, "column": 12}, "end_point": {"row": 242, "column": 17}}, {"id": 1017, "type": "assignment_expression", "text": "fifo_len;\n }\n ", "parent": 870, "children": [1018, 1019], "start_point": {"row": 245, "column": 8}, "end_point": {"row": 245, "column": 26}}, {"id": 1018, "type": "identifier", "text": "fifo_l", "parent": 1017, "children": [], "start_point": {"row": 245, "column": 8}, "end_point": {"row": 245, "column": 14}}, {"id": 1019, "type": "-=", "text": "n;", "parent": 1017, "children": [], "start_point": {"row": 245, "column": 15}, "end_point": {"row": 245, "column": 17}}, {"id": 1020, "type": "assignment_expression", "text": "->ser = 0x00;\n spi_", "parent": 525, "children": [1021, 1024, 1025], "start_point": {"row": 247, "column": 4}, "end_point": {"row": 247, "column": 26}}, {"id": 1021, "type": "field_expression", "text": "->ser = 0x00;\n ", "parent": 1020, "children": [1022, 1023], "start_point": {"row": 247, "column": 4}, "end_point": {"row": 247, "column": 19}}, {"id": 1022, "type": "identifier", "text": "->ser = 0x", "parent": 1021, "children": [], "start_point": {"row": 247, "column": 4}, "end_point": {"row": 247, "column": 14}}, {"id": 1023, "type": "->", "text": "00", "parent": 1021, "children": [], "start_point": {"row": 247, "column": 14}, "end_point": {"row": 247, "column": 16}}, {"id": 1024, "type": "=", "text": " ", "parent": 1020, "children": [], "start_point": {"row": 247, "column": 20}, "end_point": {"row": 247, "column": 21}}, {"id": 1025, "type": "number_literal", "text": "spi_", "parent": 1020, "children": [], "start_point": {"row": 247, "column": 22}, "end_point": {"row": 247, "column": 26}}, {"id": 1026, "type": "assignment_expression", "text": "->ssienr = 0x00;\n}\n\n/* SP", "parent": 525, "children": [1027, 1031, 1032], "start_point": {"row": 248, "column": 4}, "end_point": {"row": 248, "column": 29}}, {"id": 1027, "type": "field_expression", "text": "->ssienr = 0x00;\n}", "parent": 1026, "children": [1028, 1029, 1030], "start_point": {"row": 248, "column": 4}, "end_point": {"row": 248, "column": 22}}, {"id": 1028, "type": "identifier", "text": "->ssienr =", "parent": 1027, "children": [], "start_point": {"row": 248, "column": 4}, "end_point": {"row": 248, "column": 14}}, {"id": 1029, "type": "->", "text": " 0", "parent": 1027, "children": [], "start_point": {"row": 248, "column": 14}, "end_point": {"row": 248, "column": 16}}, {"id": 1030, "type": "field_identifier", "text": "x00;\n}", "parent": 1027, "children": [], "start_point": {"row": 248, "column": 16}, "end_point": {"row": 248, "column": 22}}, {"id": 1031, "type": "=", "text": "\n", "parent": 1026, "children": [], "start_point": {"row": 248, "column": 23}, "end_point": {"row": 248, "column": 24}}, {"id": 1032, "type": "number_literal", "text": "* SP", "parent": 1026, "children": [], "start_point": {"row": 248, "column": 25}, "end_point": {"row": 248, "column": 29}}, {"id": 1033, "type": "function_definition", "text": "oid)\n{\n printf(\"hard spi\\r\\n\");\n //cs\n gpiohs_set_drive_mode(ESP32_SPI_CSX_HS_NUM, GPIO_DM_OUTPUT);\n gpiohs_set_pin(ESP32_SPI_CSX_HS_NUM, 1);\n //init SPI_DEVICE_1\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf(\"set spi clk:%d\\r\\n\", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}\n\nuint8_t soft_spi_r", "parent": 401, "children": [1034, 1035], "start_point": {"row": 252, "column": 0}, "end_point": {"row": 261, "column": 1}}, {"id": 1034, "type": "primitive_type", "text": "oid)", "parent": 1033, "children": [], "start_point": {"row": 252, "column": 0}, "end_point": {"row": 252, "column": 4}}, {"id": 1035, "type": "function_declarator", "text": "{\n printf(\"hard ", "parent": 1033, "children": [1036, 1037], "start_point": {"row": 252, "column": 5}, "end_point": {"row": 252, "column": 24}}, {"id": 1036, "type": "identifier", "text": "{\n printf(", "parent": 1035, "children": [], "start_point": {"row": 252, "column": 5}, "end_point": {"row": 252, "column": 18}}, {"id": 1037, "type": "parameter_list", "text": "\"hard ", "parent": 1035, "children": [1038], "start_point": {"row": 252, "column": 18}, "end_point": {"row": 252, "column": 24}}, {"id": 1038, "type": "parameter_declaration", "text": "hard", "parent": 1037, "children": [1039], "start_point": {"row": 252, "column": 19}, "end_point": {"row": 252, "column": 23}}, {"id": 1039, "type": "primitive_type", "text": "hard", "parent": 1038, "children": [], "start_point": {"row": 252, "column": 19}, "end_point": {"row": 252, "column": 23}}, {"id": 1040, "type": "call_expression", "text": "\");\n //cs\n gpioh", "parent": 1033, "children": [1041, 1042], "start_point": {"row": 254, "column": 4}, "end_point": {"row": 254, "column": 26}}, {"id": 1041, "type": "identifier", "text": "\");\n ", "parent": 1040, "children": [], "start_point": {"row": 254, "column": 4}, "end_point": {"row": 254, "column": 10}}, {"id": 1042, "type": "argument_list", "text": " //cs\n gpioh", "parent": 1040, "children": [1043], "start_point": {"row": 254, "column": 10}, "end_point": {"row": 254, "column": 26}}, {"id": 1043, "type": "string_literal", "text": " //cs\n gpio", "parent": 1042, "children": [1044, 1045], "start_point": {"row": 254, "column": 11}, "end_point": {"row": 254, "column": 25}}, {"id": 1044, "type": "escape_sequence", "text": " g", "parent": 1043, "children": [], "start_point": {"row": 254, "column": 20}, "end_point": {"row": 254, "column": 22}}, {"id": 1045, "type": "escape_sequence", "text": "pi", "parent": 1043, "children": [], "start_point": {"row": 254, "column": 22}, "end_point": {"row": 254, "column": 24}}, {"id": 1046, "type": "call_expression", "text": "e(ESP32_SPI_CSX_HS_NUM, GPIO_DM_OUTPUT);\n gpiohs_set_pin", "parent": 1033, "children": [1047, 1048], "start_point": {"row": 256, "column": 4}, "end_point": {"row": 256, "column": 63}}, {"id": 1047, "type": "identifier", "text": "e(ESP32_SPI_CSX_HS_NU", "parent": 1046, "children": [], "start_point": {"row": 256, "column": 4}, "end_point": {"row": 256, "column": 25}}, {"id": 1048, "type": "argument_list", "text": "M, GPIO_DM_OUTPUT);\n gpiohs_set_pin", "parent": 1046, "children": [1049, 1050], "start_point": {"row": 256, "column": 25}, "end_point": {"row": 256, "column": 63}}, {"id": 1049, "type": "identifier", "text": ", GPIO_DM_OUTPUT);\n ", "parent": 1048, "children": [], "start_point": {"row": 256, "column": 26}, "end_point": {"row": 256, "column": 46}}, {"id": 1050, "type": "identifier", "text": " gpiohs_set_pi", "parent": 1048, "children": [], "start_point": {"row": 256, "column": 48}, "end_point": {"row": 256, "column": 62}}, {"id": 1051, "type": "call_expression", "text": "_SPI_CSX_HS_NUM, 1);\n //init SPI_DEV", "parent": 1033, "children": [1052, 1053], "start_point": {"row": 257, "column": 4}, "end_point": {"row": 257, "column": 43}}, {"id": 1052, "type": "identifier", "text": "_SPI_CSX_HS_NU", "parent": 1051, "children": [], "start_point": {"row": 257, "column": 4}, "end_point": {"row": 257, "column": 18}}, {"id": 1053, "type": "argument_list", "text": "M, 1);\n //init SPI_DEV", "parent": 1051, "children": [1054, 1055], "start_point": {"row": 257, "column": 18}, "end_point": {"row": 257, "column": 43}}, {"id": 1054, "type": "identifier", "text": ", 1);\n //init SPI", "parent": 1053, "children": [], "start_point": {"row": 257, "column": 19}, "end_point": {"row": 257, "column": 39}}, {"id": 1055, "type": "number_literal", "text": "E", "parent": 1053, "children": [], "start_point": {"row": 257, "column": 41}, "end_point": {"row": 257, "column": 42}}, {"id": 1056, "type": "call_expression", "text": "1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf(\"set sp", "parent": 1033, "children": [1057, 1058], "start_point": {"row": 259, "column": 4}, "end_point": {"row": 259, "column": 66}}, {"id": 1057, "type": "identifier", "text": "1, SPI_W", "parent": 1056, "children": [], "start_point": {"row": 259, "column": 4}, "end_point": {"row": 259, "column": 12}}, {"id": 1058, "type": "argument_list", "text": "ORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf(\"set sp", "parent": 1056, "children": [1059, 1060, 1061, 1062, 1063], "start_point": {"row": 259, "column": 12}, "end_point": {"row": 259, "column": 66}}, {"id": 1059, "type": "identifier", "text": "RK_MODE_0, S", "parent": 1058, "children": [], "start_point": {"row": 259, "column": 13}, "end_point": {"row": 259, "column": 25}}, {"id": 1060, "type": "identifier", "text": "_FF_STANDARD, 8", "parent": 1058, "children": [], "start_point": {"row": 259, "column": 27}, "end_point": {"row": 259, "column": 42}}, {"id": 1061, "type": "identifier", "text": "0);\n printf(", "parent": 1058, "children": [], "start_point": {"row": 259, "column": 44}, "end_point": {"row": 259, "column": 59}}, {"id": 1062, "type": "number_literal", "text": "e", "parent": 1058, "children": [], "start_point": {"row": 259, "column": 61}, "end_point": {"row": 259, "column": 62}}, {"id": 1063, "type": "number_literal", "text": "s", "parent": 1058, "children": [], "start_point": {"row": 259, "column": 64}, "end_point": {"row": 259, "column": 65}}, {"id": 1064, "type": "call_expression", "text": "%d\\r\\n\", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}", "parent": 1033, "children": [1065, 1066], "start_point": {"row": 260, "column": 4}, "end_point": {"row": 260, "column": 77}}, {"id": 1065, "type": "identifier", "text": "%d\\r\\n", "parent": 1064, "children": [], "start_point": {"row": 260, "column": 4}, "end_point": {"row": 260, "column": 10}}, {"id": 1066, "type": "argument_list", "text": "\", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}", "parent": 1064, "children": [1067, 1070], "start_point": {"row": 260, "column": 10}, "end_point": {"row": 260, "column": 77}}, {"id": 1067, "type": "string_literal", "text": ", spi_set_clk_rate(S", "parent": 1066, "children": [1068, 1069], "start_point": {"row": 260, "column": 11}, "end_point": {"row": 260, "column": 31}}, {"id": 1068, "type": "escape_sequence", "text": "at", "parent": 1067, "children": [], "start_point": {"row": 260, "column": 26}, "end_point": {"row": 260, "column": 28}}, {"id": 1069, "type": "escape_sequence", "text": "e(", "parent": 1067, "children": [], "start_point": {"row": 260, "column": 28}, "end_point": {"row": 260, "column": 30}}, {"id": 1070, "type": "call_expression", "text": "_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n", "parent": 1066, "children": [1071, 1072], "start_point": {"row": 260, "column": 33}, "end_point": {"row": 260, "column": 76}}, {"id": 1071, "type": "identifier", "text": "_DEVICE_1, 10000", "parent": 1070, "children": [], "start_point": {"row": 260, "column": 33}, "end_point": {"row": 260, "column": 49}}, {"id": 1072, "type": "argument_list", "text": "00 * 8)); /*set clk rate*/\n", "parent": 1070, "children": [1073, 1074], "start_point": {"row": 260, "column": 49}, "end_point": {"row": 260, "column": 76}}, {"id": 1073, "type": "identifier", "text": "0 * 8)); /*s", "parent": 1072, "children": [], "start_point": {"row": 260, "column": 50}, "end_point": {"row": 260, "column": 62}}, {"id": 1074, "type": "binary_expression", "text": " clk rate*/", "parent": 1072, "children": [1075, 1076, 1077], "start_point": {"row": 260, "column": 64}, "end_point": {"row": 260, "column": 75}}, {"id": 1075, "type": "number_literal", "text": " clk ra", "parent": 1074, "children": [], "start_point": {"row": 260, "column": 64}, "end_point": {"row": 260, "column": 71}}, {"id": 1076, "type": "*", "text": "e", "parent": 1074, "children": [], "start_point": {"row": 260, "column": 72}, "end_point": {"row": 260, "column": 73}}, {"id": 1077, "type": "number_literal", "text": "/", "parent": 1074, "children": [], "start_point": {"row": 260, "column": 74}, "end_point": {"row": 260, "column": 75}}, {"id": 1078, "type": "function_definition", "text": "uint8_t data)\n{\n uint8_t c;\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nvoid soft_spi_rw_l", "parent": 401, "children": [1079, 1080], "start_point": {"row": 263, "column": 0}, "end_point": {"row": 268, "column": 1}}, {"id": 1079, "type": "primitive_type", "text": "uint8_t", "parent": 1078, "children": [], "start_point": {"row": 263, "column": 0}, "end_point": {"row": 263, "column": 7}}, {"id": 1080, "type": "function_declarator", "text": "data)\n{\n uint8_t c;\n ", "parent": 1078, "children": [1081, 1082], "start_point": {"row": 263, "column": 8}, "end_point": {"row": 263, "column": 33}}, {"id": 1081, "type": "identifier", "text": "data)\n{\n ", "parent": 1080, "children": [], "start_point": {"row": 263, "column": 8}, "end_point": {"row": 263, "column": 19}}, {"id": 1082, "type": "parameter_list", "text": " uint8_t c;\n ", "parent": 1080, "children": [1083], "start_point": {"row": 263, "column": 19}, "end_point": {"row": 263, "column": 33}}, {"id": 1083, "type": "parameter_declaration", "text": "uint8_t c;\n ", "parent": 1082, "children": [1084, 1085], "start_point": {"row": 263, "column": 20}, "end_point": {"row": 263, "column": 32}}, {"id": 1084, "type": "primitive_type", "text": "uint8_t", "parent": 1083, "children": [], "start_point": {"row": 263, "column": 20}, "end_point": {"row": 263, "column": 27}}, {"id": 1085, "type": "identifier", "text": "c;\n ", "parent": 1083, "children": [], "start_point": {"row": 263, "column": 28}, "end_point": {"row": 263, "column": 32}}, {"id": 1086, "type": "declaration", "text": "d_spi_tran", "parent": 1078, "children": [1087, 1088], "start_point": {"row": 265, "column": 4}, "end_point": {"row": 265, "column": 14}}, {"id": 1087, "type": "primitive_type", "text": "d_spi_t", "parent": 1086, "children": [], "start_point": {"row": 265, "column": 4}, "end_point": {"row": 265, "column": 11}}, {"id": 1088, "type": "identifier", "text": "a", "parent": 1086, "children": [], "start_point": {"row": 265, "column": 12}, "end_point": {"row": 265, "column": 13}}, {"id": 1089, "type": "call_expression", "text": "data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nv", "parent": 1078, "children": [1090, 1091], "start_point": {"row": 266, "column": 4}, "end_point": {"row": 266, "column": 84}}, {"id": 1090, "type": "identifier", "text": "data_standard(SPI_DEVICE_1, SPI_C", "parent": 1089, "children": [], "start_point": {"row": 266, "column": 4}, "end_point": {"row": 266, "column": 37}}, {"id": 1091, "type": "argument_list", "text": "HIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nv", "parent": 1089, "children": [1092, 1093, 1094, 1098], "start_point": {"row": 266, "column": 37}, "end_point": {"row": 266, "column": 84}}, {"id": 1092, "type": "identifier", "text": "IP_SELECT_0,", "parent": 1091, "children": [], "start_point": {"row": 266, "column": 38}, "end_point": {"row": 266, "column": 50}}, {"id": 1093, "type": "identifier", "text": "data, &c, 1);\n ", "parent": 1091, "children": [], "start_point": {"row": 266, "column": 52}, "end_point": {"row": 266, "column": 69}}, {"id": 1094, "type": "pointer_expression", "text": "eturn", "parent": 1091, "children": [1095, 1096], "start_point": {"row": 266, "column": 71}, "end_point": {"row": 266, "column": 76}}, {"id": 1095, "type": "&", "text": "e", "parent": 1094, "children": [], "start_point": {"row": 266, "column": 71}, "end_point": {"row": 266, "column": 72}}, {"id": 1096, "type": "identifier", "text": "turn", "parent": 1094, "children": [], "start_point": {"row": 266, "column": 72}, "end_point": {"row": 266, "column": 76}}, {"id": 1097, "type": "identifier", "text": "\n", "parent": 1091, "children": [], "start_point": {"row": 266, "column": 79}, "end_point": {"row": 266, "column": 80}}, {"id": 1098, "type": "number_literal", "text": "\n", "parent": 1091, "children": [], "start_point": {"row": 266, "column": 82}, "end_point": {"row": 266, "column": 83}}, {"id": 1099, "type": "return_statement", "text": "ft_spi_rw", "parent": 1078, "children": [1100], "start_point": {"row": 267, "column": 4}, "end_point": {"row": 267, "column": 13}}, {"id": 1100, "type": "identifier", "text": "r", "parent": 1099, "children": [], "start_point": {"row": 267, "column": 11}, "end_point": {"row": 267, "column": 12}}, {"id": 1101, "type": "function_definition", "text": "(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(\" buffer is null\\r\\n\");\n return;\n }\n\n#if 0\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only send\n if (send && recv == NULL)\n {\n spi_send_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n }\n\n //only recv\n if (send == NULL && recv)\n {\n spi_receive_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n }\n\n //send and recv\n if (send && recv)\n {\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n }\n return;\n}\n\n#endif\n\nuint64_t g", "parent": 401, "children": [1102, 1103], "start_point": {"row": 270, "column": 0}, "end_point": {"row": 303, "column": 1}}, {"id": 1102, "type": "primitive_type", "text": "(uin", "parent": 1101, "children": [], "start_point": {"row": 270, "column": 0}, "end_point": {"row": 270, "column": 4}}, {"id": 1103, "type": "function_declarator", "text": "8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == N", "parent": 1101, "children": [1104, 1105], "start_point": {"row": 270, "column": 5}, "end_point": {"row": 270, "column": 64}}, {"id": 1104, "type": "identifier", "text": "8_t *send, uint", "parent": 1103, "children": [], "start_point": {"row": 270, "column": 5}, "end_point": {"row": 270, "column": 20}}, {"id": 1105, "type": "parameter_list", "text": "8_t *recv, uint32_t len)\n{\n if (send == N", "parent": 1103, "children": [1106, 1110, 1113], "start_point": {"row": 270, "column": 20}, "end_point": {"row": 270, "column": 64}}, {"id": 1106, "type": "parameter_declaration", "text": "_t *recv, uin", "parent": 1105, "children": [1107, 1108], "start_point": {"row": 270, "column": 21}, "end_point": {"row": 270, "column": 34}}, {"id": 1107, "type": "primitive_type", "text": "_t *rec", "parent": 1106, "children": [], "start_point": {"row": 270, "column": 21}, "end_point": {"row": 270, "column": 28}}, {"id": 1108, "type": "pointer_declarator", "text": ", uin", "parent": 1106, "children": [1109], "start_point": {"row": 270, "column": 29}, "end_point": {"row": 270, "column": 34}}, {"id": 1109, "type": "identifier", "text": " uin", "parent": 1108, "children": [], "start_point": {"row": 270, "column": 30}, "end_point": {"row": 270, "column": 34}}, {"id": 1110, "type": "parameter_declaration", "text": "2_t len)\n{\n ", "parent": 1105, "children": [1111], "start_point": {"row": 270, "column": 36}, "end_point": {"row": 270, "column": 49}}, {"id": 1111, "type": "primitive_type", "text": "2_t len", "parent": 1110, "children": [], "start_point": {"row": 270, "column": 36}, "end_point": {"row": 270, "column": 43}}, {"id": 1112, "type": "*", "text": "\n", "parent": 1110, "children": [], "start_point": {"row": 270, "column": 44}, "end_point": {"row": 270, "column": 45}}, {"id": 1113, "type": "parameter_declaration", "text": "if (send == ", "parent": 1105, "children": [1114, 1115], "start_point": {"row": 270, "column": 51}, "end_point": {"row": 270, "column": 63}}, {"id": 1114, "type": "primitive_type", "text": "if (send", "parent": 1113, "children": [], "start_point": {"row": 270, "column": 51}, "end_point": {"row": 270, "column": 59}}, {"id": 1115, "type": "identifier", "text": "== ", "parent": 1113, "children": [], "start_point": {"row": 270, "column": 60}, "end_point": {"row": 270, "column": 63}}, {"id": 1116, "type": "if_statement", "text": "recv == NULL)\n {\n printf(\" buffer is null\\r\\n\");\n return;\n }\n\n#if 0\n spi_init", "parent": 1101, "children": [1117], "start_point": {"row": 272, "column": 4}, "end_point": {"row": 276, "column": 5}}, {"id": 1117, "type": "parenthesized_expression", "text": "v == NULL)\n {\n print", "parent": 1116, "children": [1118], "start_point": {"row": 272, "column": 7}, "end_point": {"row": 272, "column": 37}}, {"id": 1118, "type": "binary_expression", "text": " == NULL)\n {\n prin", "parent": 1117, "children": [1119, 1122], "start_point": {"row": 272, "column": 8}, "end_point": {"row": 272, "column": 36}}, {"id": 1119, "type": "binary_expression", "text": " == NULL)\n ", "parent": 1118, "children": [1120, 1121], "start_point": {"row": 272, "column": 8}, "end_point": {"row": 272, "column": 20}}, {"id": 1120, "type": "identifier", "text": " == ", "parent": 1119, "children": [], "start_point": {"row": 272, "column": 8}, "end_point": {"row": 272, "column": 12}}, {"id": 1121, "type": "==", "text": "UL", "parent": 1119, "children": [], "start_point": {"row": 272, "column": 13}, "end_point": {"row": 272, "column": 15}}, {"id": 1122, "type": "binary_expression", "text": " prin", "parent": 1118, "children": [1123, 1124, 1125], "start_point": {"row": 272, "column": 24}, "end_point": {"row": 272, "column": 36}}, {"id": 1123, "type": "identifier", "text": " ", "parent": 1122, "children": [], "start_point": {"row": 272, "column": 24}, "end_point": {"row": 272, "column": 28}}, {"id": 1124, "type": "==", "text": " ", "parent": 1122, "children": [], "start_point": {"row": 272, "column": 29}, "end_point": {"row": 272, "column": 31}}, {"id": 1125, "type": "null", "text": "prin", "parent": 1122, "children": [1126], "start_point": {"row": 272, "column": 32}, "end_point": {"row": 272, "column": 36}}, {"id": 1126, "type": "NULL", "text": "prin", "parent": 1125, "children": [], "start_point": {"row": 272, "column": 32}, "end_point": {"row": 272, "column": 36}}, {"id": 1127, "type": "call_expression", "text": "ull\\r\\n\");\n return;\n ", "parent": 1116, "children": [1128, 1129], "start_point": {"row": 274, "column": 8}, "end_point": {"row": 274, "column": 37}}, {"id": 1128, "type": "identifier", "text": "ull\\r\\", "parent": 1127, "children": [], "start_point": {"row": 274, "column": 8}, "end_point": {"row": 274, "column": 14}}, {"id": 1129, "type": "argument_list", "text": "n\");\n return;\n ", "parent": 1127, "children": [1130], "start_point": {"row": 274, "column": 14}, "end_point": {"row": 274, "column": 37}}, {"id": 1130, "type": "string_literal", "text": "\");\n return;\n ", "parent": 1129, "children": [1131], "start_point": {"row": 274, "column": 15}, "end_point": {"row": 274, "column": 36}}, {"id": 1131, "type": "escape_sequence", "text": "rn", "parent": 1130, "children": [], "start_point": {"row": 274, "column": 31}, "end_point": {"row": 274, "column": 33}}, {"id": 1132, "type": "return_statement", "text": "\n sp", "parent": 1116, "children": [], "start_point": {"row": 275, "column": 8}, "end_point": {"row": 275, "column": 15}}, {"id": 1133, "type": "preproc_if", "text": "PI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only send\n ", "parent": 1101, "children": [1134, 1135, 1136], "start_point": {"row": 278, "column": 0}, "end_point": {"row": 280, "column": 6}}, {"id": 1134, "type": "#if", "text": "PI_", "parent": 1133, "children": [], "start_point": {"row": 278, "column": 0}, "end_point": {"row": 278, "column": 3}}, {"id": 1135, "type": "number_literal", "text": "E", "parent": 1133, "children": [], "start_point": {"row": 278, "column": 4}, "end_point": {"row": 278, "column": 5}}, {"id": 1136, "type": "\n", "text": "V", "parent": 1133, "children": [], "start_point": {"row": 278, "column": 5}, "end_point": {"row": 279, "column": 0}}, {"id": 1137, "type": "call_expression", "text": "1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only", "parent": 1133, "children": [1138, 1139], "start_point": {"row": 279, "column": 4}, "end_point": {"row": 279, "column": 66}}, {"id": 1138, "type": "identifier", "text": "1, SPI_W", "parent": 1137, "children": [], "start_point": {"row": 279, "column": 4}, "end_point": {"row": 279, "column": 12}}, {"id": 1139, "type": "argument_list", "text": "ORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only", "parent": 1137, "children": [1140, 1141, 1142, 1143, 1144], "start_point": {"row": 279, "column": 12}, "end_point": {"row": 279, "column": 66}}, {"id": 1140, "type": "identifier", "text": "RK_MODE_0, S", "parent": 1139, "children": [], "start_point": {"row": 279, "column": 13}, "end_point": {"row": 279, "column": 25}}, {"id": 1141, "type": "identifier", "text": "_FF_STANDARD, 8", "parent": 1139, "children": [], "start_point": {"row": 279, "column": 27}, "end_point": {"row": 279, "column": 42}}, {"id": 1142, "type": "identifier", "text": "0);\n#endif\n\n ", "parent": 1139, "children": [], "start_point": {"row": 279, "column": 44}, "end_point": {"row": 279, "column": 59}}, {"id": 1143, "type": "number_literal", "text": "/", "parent": 1139, "children": [], "start_point": {"row": 279, "column": 61}, "end_point": {"row": 279, "column": 62}}, {"id": 1144, "type": "number_literal", "text": "l", "parent": 1139, "children": [], "start_point": {"row": 279, "column": 64}, "end_point": {"row": 279, "column": 65}}, {"id": 1145, "type": "if_statement", "text": "NULL)\n {\n spi_send_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n }\n\n //only recv\n ", "parent": 1101, "children": [1146], "start_point": {"row": 283, "column": 4}, "end_point": {"row": 287, "column": 5}}, {"id": 1146, "type": "parenthesized_expression", "text": "L)\n {\n spi_s", "parent": 1145, "children": [1147], "start_point": {"row": 283, "column": 7}, "end_point": {"row": 283, "column": 29}}, {"id": 1147, "type": "binary_expression", "text": ")\n {\n spi_", "parent": 1146, "children": [1148], "start_point": {"row": 283, "column": 8}, "end_point": {"row": 283, "column": 28}}, {"id": 1148, "type": "binary_expression", "text": " spi_", "parent": 1147, "children": [1149, 1150, 1151], "start_point": {"row": 283, "column": 16}, "end_point": {"row": 283, "column": 28}}, {"id": 1149, "type": "identifier", "text": " ", "parent": 1148, "children": [], "start_point": {"row": 283, "column": 16}, "end_point": {"row": 283, "column": 20}}, {"id": 1150, "type": "==", "text": " ", "parent": 1148, "children": [], "start_point": {"row": 283, "column": 21}, "end_point": {"row": 283, "column": 23}}, {"id": 1151, "type": "null", "text": "spi_", "parent": 1148, "children": [1152], "start_point": {"row": 283, "column": 24}, "end_point": {"row": 283, "column": 28}}, {"id": 1152, "type": "NULL", "text": "spi_", "parent": 1151, "children": [], "start_point": {"row": 283, "column": 24}, "end_point": {"row": 283, "column": 28}}, {"id": 1153, "type": "call_expression", "text": "rd(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n ", "parent": 1145, "children": [1154, 1155], "start_point": {"row": 285, "column": 8}, "end_point": {"row": 285, "column": 83}}, {"id": 1154, "type": "identifier", "text": "rd(SPI_DEVICE_1, SPI_C", "parent": 1153, "children": [], "start_point": {"row": 285, "column": 8}, "end_point": {"row": 285, "column": 30}}, {"id": 1155, "type": "argument_list", "text": "HIP_SELECT_0, NULL, 0, send, len);\n return;\n ", "parent": 1153, "children": [1156, 1157, 1158, 1160, 1161], "start_point": {"row": 285, "column": 30}, "end_point": {"row": 285, "column": 83}}, {"id": 1156, "type": "identifier", "text": "IP_SELECT_0,", "parent": 1155, "children": [], "start_point": {"row": 285, "column": 31}, "end_point": {"row": 285, "column": 43}}, {"id": 1157, "type": "identifier", "text": "ULL, 0, send, len", "parent": 1155, "children": [], "start_point": {"row": 285, "column": 45}, "end_point": {"row": 285, "column": 62}}, {"id": 1158, "type": "null", "text": "\n ", "parent": 1155, "children": [1159], "start_point": {"row": 285, "column": 64}, "end_point": {"row": 285, "column": 68}}, {"id": 1159, "type": "NULL", "text": "\n ", "parent": 1158, "children": [], "start_point": {"row": 285, "column": 64}, "end_point": {"row": 285, "column": 68}}, {"id": 1160, "type": "number_literal", "text": " ", "parent": 1155, "children": [], "start_point": {"row": 285, "column": 70}, "end_point": {"row": 285, "column": 71}}, {"id": 1161, "type": "identifier", "text": "retu", "parent": 1155, "children": [], "start_point": {"row": 285, "column": 73}, "end_point": {"row": 285, "column": 77}}, {"id": 1162, "type": "return_statement", "text": "/only r", "parent": 1145, "children": [], "start_point": {"row": 286, "column": 8}, "end_point": {"row": 286, "column": 15}}, {"id": 1163, "type": "if_statement", "text": "recv)\n {\n spi_receive_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n }\n\n //send and rec", "parent": 1101, "children": [1164], "start_point": {"row": 290, "column": 4}, "end_point": {"row": 294, "column": 5}}, {"id": 1164, "type": "parenthesized_expression", "text": "v)\n {\n spi_r", "parent": 1163, "children": [1165], "start_point": {"row": 290, "column": 7}, "end_point": {"row": 290, "column": 29}}, {"id": 1165, "type": "binary_expression", "text": ")\n {\n spi_", "parent": 1164, "children": [1166, 1169, 1170], "start_point": {"row": 290, "column": 8}, "end_point": {"row": 290, "column": 28}}, {"id": 1166, "type": "binary_expression", "text": ")\n {\n ", "parent": 1165, "children": [1167], "start_point": {"row": 290, "column": 8}, "end_point": {"row": 290, "column": 20}}, {"id": 1167, "type": "null", "text": " ", "parent": 1166, "children": [1168], "start_point": {"row": 290, "column": 16}, "end_point": {"row": 290, "column": 20}}, {"id": 1168, "type": "NULL", "text": " ", "parent": 1167, "children": [], "start_point": {"row": 290, "column": 16}, "end_point": {"row": 290, "column": 20}}, {"id": 1169, "type": "&&", "text": " ", "parent": 1165, "children": [], "start_point": {"row": 290, "column": 21}, "end_point": {"row": 290, "column": 23}}, {"id": 1170, "type": "identifier", "text": "spi_", "parent": 1165, "children": [], "start_point": {"row": 290, "column": 24}, "end_point": {"row": 290, "column": 28}}, {"id": 1171, "type": "call_expression", "text": "ndard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n ", "parent": 1163, "children": [1172, 1173], "start_point": {"row": 292, "column": 8}, "end_point": {"row": 292, "column": 86}}, {"id": 1172, "type": "identifier", "text": "ndard(SPI_DEVICE_1, SPI_C", "parent": 1171, "children": [], "start_point": {"row": 292, "column": 8}, "end_point": {"row": 292, "column": 33}}, {"id": 1173, "type": "argument_list", "text": "HIP_SELECT_0, NULL, 0, recv, len);\n return;\n ", "parent": 1171, "children": [1174, 1175, 1176, 1178, 1179], "start_point": {"row": 292, "column": 33}, "end_point": {"row": 292, "column": 86}}, {"id": 1174, "type": "identifier", "text": "IP_SELECT_0,", "parent": 1173, "children": [], "start_point": {"row": 292, "column": 34}, "end_point": {"row": 292, "column": 46}}, {"id": 1175, "type": "identifier", "text": "ULL, 0, recv, len", "parent": 1173, "children": [], "start_point": {"row": 292, "column": 48}, "end_point": {"row": 292, "column": 65}}, {"id": 1176, "type": "null", "text": "\n ", "parent": 1173, "children": [1177], "start_point": {"row": 292, "column": 67}, "end_point": {"row": 292, "column": 71}}, {"id": 1177, "type": "NULL", "text": "\n ", "parent": 1176, "children": [], "start_point": {"row": 292, "column": 67}, "end_point": {"row": 292, "column": 71}}, {"id": 1178, "type": "number_literal", "text": " ", "parent": 1173, "children": [], "start_point": {"row": 292, "column": 73}, "end_point": {"row": 292, "column": 74}}, {"id": 1179, "type": "identifier", "text": "retu", "parent": 1173, "children": [], "start_point": {"row": 292, "column": 76}, "end_point": {"row": 292, "column": 80}}, {"id": 1180, "type": "return_statement", "text": "/send a", "parent": 1163, "children": [], "start_point": {"row": 293, "column": 8}, "end_point": {"row": 293, "column": 15}}, {"id": 1181, "type": "if_statement", "text": " {\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n }\n return;\n}\n\n#end", "parent": 1101, "children": [1182], "start_point": {"row": 297, "column": 4}, "end_point": {"row": 301, "column": 5}}, {"id": 1182, "type": "parenthesized_expression", "text": "\n sipee", "parent": 1181, "children": [1183], "start_point": {"row": 297, "column": 7}, "end_point": {"row": 297, "column": 21}}, {"id": 1183, "type": "binary_expression", "text": " sipe", "parent": 1182, "children": [1184, 1185, 1186], "start_point": {"row": 297, "column": 8}, "end_point": {"row": 297, "column": 20}}, {"id": 1184, "type": "identifier", "text": " ", "parent": 1183, "children": [], "start_point": {"row": 297, "column": 8}, "end_point": {"row": 297, "column": 12}}, {"id": 1185, "type": "&&", "text": " ", "parent": 1183, "children": [], "start_point": {"row": 297, "column": 13}, "end_point": {"row": 297, "column": 15}}, {"id": 1186, "type": "identifier", "text": "sipe", "parent": 1183, "children": [], "start_point": {"row": 297, "column": 16}, "end_point": {"row": 297, "column": 20}}, {"id": 1187, "type": "call_expression", "text": "data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n ", "parent": 1181, "children": [1188, 1189], "start_point": {"row": 299, "column": 8}, "end_point": {"row": 299, "column": 91}}, {"id": 1188, "type": "identifier", "text": "data_standard(SPI_DEVICE_1, SPI_C", "parent": 1187, "children": [], "start_point": {"row": 299, "column": 8}, "end_point": {"row": 299, "column": 41}}, {"id": 1189, "type": "argument_list", "text": "HIP_SELECT_0, send, recv, len);\n return;\n ", "parent": 1187, "children": [1190, 1191, 1192, 1193], "start_point": {"row": 299, "column": 41}, "end_point": {"row": 299, "column": 91}}, {"id": 1190, "type": "identifier", "text": "IP_SELECT_0,", "parent": 1189, "children": [], "start_point": {"row": 299, "column": 42}, "end_point": {"row": 299, "column": 54}}, {"id": 1191, "type": "identifier", "text": "end, recv, len);\n", "parent": 1189, "children": [], "start_point": {"row": 299, "column": 56}, "end_point": {"row": 299, "column": 73}}, {"id": 1192, "type": "identifier", "text": " ", "parent": 1189, "children": [], "start_point": {"row": 299, "column": 75}, "end_point": {"row": 299, "column": 79}}, {"id": 1193, "type": "identifier", "text": "retu", "parent": 1189, "children": [], "start_point": {"row": 299, "column": 81}, "end_point": {"row": 299, "column": 85}}, {"id": 1194, "type": "return_statement", "text": "turn;\n}", "parent": 1181, "children": [], "start_point": {"row": 300, "column": 8}, "end_point": {"row": 300, "column": 15}}, {"id": 1195, "type": "return_statement", "text": "int64_t", "parent": 1101, "children": [], "start_point": {"row": 302, "column": 4}, "end_point": {"row": 302, "column": 11}}, {"id": 1196, "type": "#endif", "text": "_milli", "parent": 24, "children": [], "start_point": {"row": 305, "column": 0}, "end_point": {"row": 305, "column": 6}}, {"id": 1197, "type": "function_definition", "text": "void)\n{\n return sysctl_get_time_us() / 1000;\n}\n", "parent": null, "children": [1198, 1199], "start_point": {"row": 307, "column": 0}, "end_point": {"row": 310, "column": 1}}, {"id": 1198, "type": "primitive_type", "text": "void)\n{\n", "parent": 1197, "children": [], "start_point": {"row": 307, "column": 0}, "end_point": {"row": 307, "column": 8}}, {"id": 1199, "type": "function_declarator", "text": " return sysctl", "parent": 1197, "children": [1200], "start_point": {"row": 307, "column": 9}, "end_point": {"row": 307, "column": 25}}, {"id": 1200, "type": "parameter_list", "text": "sysctl", "parent": 1199, "children": [1201], "start_point": {"row": 307, "column": 19}, "end_point": {"row": 307, "column": 25}}, {"id": 1201, "type": "parameter_declaration", "text": "ysct", "parent": 1200, "children": [1202], "start_point": {"row": 307, "column": 20}, "end_point": {"row": 307, "column": 24}}, {"id": 1202, "type": "primitive_type", "text": "ysct", "parent": 1201, "children": [], "start_point": {"row": 307, "column": 20}, "end_point": {"row": 307, "column": 24}}, {"id": 1203, "type": "return_statement", "text": "me_us() / 1000;\n}\n", "parent": 1197, "children": [1204], "start_point": {"row": 309, "column": 4}, "end_point": {"row": 309, "column": 39}}, {"id": 1204, "type": "binary_expression", "text": " / 1000;\n}\n", "parent": 1203, "children": [1205, 1208, 1209], "start_point": {"row": 309, "column": 11}, "end_point": {"row": 309, "column": 38}}, {"id": 1205, "type": "call_expression", "text": " / 1000;\n}\n", "parent": 1204, "children": [1206, 1207], "start_point": {"row": 309, "column": 11}, "end_point": {"row": 309, "column": 31}}, {"id": 1206, "type": "identifier", "text": " / 1000;\n}\n", "parent": 1205, "children": [], "start_point": {"row": 309, "column": 11}, "end_point": {"row": 309, "column": 29}}, {"id": 1207, "type": "argument_list", "text": "", "parent": 1205, "children": [], "start_point": {"row": 309, "column": 29}, "end_point": {"row": 309, "column": 31}}, {"id": 1208, "type": "/", "text": "", "parent": 1204, "children": [], "start_point": {"row": 309, "column": 32}, "end_point": {"row": 309, "column": 33}}, {"id": 1209, "type": "number_literal", "text": "", "parent": 1204, "children": [], "start_point": {"row": 309, "column": 34}, "end_point": {"row": 309, "column": 38}}]}, "node_categories": {"declarations": {"functions": [28, 34, 40, 78, 80, 150, 152, 237, 239, 403, 406, 431, 434, 525, 528, 1033, 1035, 1078, 1080, 1101, 1103, 1197, 1199], "variables": [46, 60, 66, 72, 83, 86, 89, 92, 95, 98, 155, 158, 161, 242, 247, 252, 277, 307, 313, 409, 437, 440, 456, 468, 531, 534, 537, 543, 548, 571, 575, 581, 592, 604, 641, 657, 699, 1038, 1083, 1086, 1106, 1110, 1113, 1201], "classes": [404, 432, 526], "imports": [0, 1, 3, 4, 6, 7, 9, 10, 12, 13, 15, 16, 18, 19, 21, 22], "modules": [], "enums": []}, "statements": {"expressions": [101, 106, 111, 116, 121, 172, 176, 177, 181, 185, 190, 193, 198, 203, 211, 212, 215, 218, 221, 226, 231, 255, 256, 257, 263, 266, 285, 286, 287, 292, 295, 296, 299, 302, 326, 327, 333, 338, 341, 344, 356, 357, 361, 364, 365, 368, 375, 376, 377, 382, 385, 386, 389, 394, 396, 413, 414, 422, 423, 443, 446, 447, 452, 465, 491, 494, 508, 511, 513, 517, 521, 551, 554, 555, 560, 564, 567, 587, 601, 624, 627, 646, 647, 648, 649, 662, 667, 671, 674, 675, 676, 683, 690, 695, 709, 712, 720, 729, 737, 738, 749, 752, 755, 759, 760, 766, 767, 768, 772, 783, 784, 795, 798, 801, 805, 806, 812, 813, 814, 818, 830, 833, 837, 838, 844, 846, 854, 855, 856, 857, 858, 874, 882, 891, 899, 900, 911, 914, 917, 921, 922, 923, 927, 931, 932, 945, 946, 957, 960, 963, 967, 968, 969, 973, 977, 980, 981, 995, 998, 1002, 1004, 1007, 1010, 1011, 1021, 1027, 1040, 1046, 1051, 1056, 1064, 1070, 1074, 1089, 1094, 1117, 1118, 1119, 1122, 1127, 1137, 1146, 1147, 1148, 1153, 1164, 1165, 1166, 1171, 1182, 1183, 1187, 1204, 1205], "assignments": [126, 130, 134, 138, 142, 146, 167, 284, 330, 352, 374, 482, 504, 615, 637, 666, 682, 689, 706, 716, 734, 745, 758, 780, 791, 804, 826, 836, 850, 866, 871, 878, 896, 907, 920, 942, 953, 966, 991, 1001, 1017, 1020, 1026], "loops": [166, 705, 744, 790, 825, 853, 870, 906, 952, 990], "conditionals": [24, 25, 30, 32, 36, 38, 42, 44, 49, 53, 57, 63, 69, 75, 81, 85, 88, 91, 94, 97, 100, 102, 104, 105, 107, 109, 112, 114, 115, 117, 119, 122, 124, 125, 127, 129, 131, 133, 135, 137, 139, 141, 143, 145, 147, 149, 153, 157, 160, 163, 168, 173, 175, 178, 182, 186, 191, 195, 200, 205, 210, 213, 216, 219, 223, 228, 233, 236, 240, 246, 251, 254, 258, 264, 267, 273, 274, 279, 288, 290, 293, 298, 300, 304, 310, 318, 322, 325, 328, 331, 339, 342, 348, 353, 355, 358, 362, 367, 369, 378, 380, 383, 388, 390, 393, 395, 397, 399, 400, 405, 407, 411, 412, 415, 419, 421, 424, 428, 430, 435, 439, 442, 444, 448, 450, 453, 457, 459, 463, 466, 467, 471, 474, 475, 476, 477, 479, 480, 483, 488, 489, 492, 499, 500, 502, 505, 509, 514, 516, 520, 522, 524, 529, 532, 533, 535, 536, 538, 542, 547, 550, 552, 556, 558, 561, 565, 568, 573, 574, 578, 580, 584, 586, 588, 590, 591, 593, 595, 599, 602, 603, 606, 607, 608, 609, 610, 612, 613, 616, 621, 622, 625, 632, 633, 635, 638, 644, 650, 652, 654, 658, 660, 663, 665, 668, 669, 677, 679, 684, 686, 691, 693, 698, 702, 707, 713, 715, 717, 719, 721, 723, 725, 726, 727, 728, 730, 731, 732, 733, 735, 739, 746, 750, 753, 756, 761, 763, 771, 773, 777, 778, 779, 781, 785, 792, 796, 799, 802, 807, 809, 817, 819, 823, 827, 831, 832, 834, 839, 841, 845, 847, 851, 859, 861, 867, 872, 875, 877, 879, 881, 883, 885, 887, 888, 889, 890, 892, 893, 894, 895, 897, 901, 908, 912, 915, 918, 926, 928, 933, 935, 939, 940, 941, 943, 947, 954, 958, 961, 964, 972, 974, 982, 984, 988, 992, 996, 997, 999, 1003, 1005, 1012, 1014, 1018, 1022, 1028, 1030, 1036, 1041, 1047, 1049, 1050, 1052, 1054, 1057, 1059, 1060, 1061, 1065, 1071, 1073, 1081, 1085, 1088, 1090, 1092, 1093, 1096, 1097, 1100, 1104, 1109, 1115, 1116, 1120, 1123, 1128, 1133, 1134, 1138, 1140, 1141, 1142, 1145, 1149, 1154, 1156, 1157, 1161, 1163, 1170, 1172, 1174, 1175, 1179, 1181, 1184, 1186, 1188, 1190, 1191, 1192, 1193, 1196, 1206], "returns": [235, 272, 418, 427, 429, 1099, 1132, 1162, 1180, 1194, 1195, 1203], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 8, 11, 14, 17, 20, 23, 26, 51, 55, 59, 65, 71, 77, 110, 120, 165, 169, 171, 180, 189, 197, 202, 207, 209, 225, 230, 269, 275, 281, 312, 324, 350, 417, 426, 455, 473, 478, 481, 485, 490, 496, 501, 507, 518, 563, 570, 611, 614, 618, 623, 629, 634, 640, 656, 681, 688, 696, 704, 710, 741, 743, 748, 764, 787, 789, 794, 810, 829, 842, 863, 865, 869, 903, 905, 910, 936, 949, 951, 956, 985, 994, 1015, 1025, 1032, 1043, 1055, 1062, 1063, 1067, 1075, 1077, 1098, 1130, 1135, 1143, 1144, 1160, 1178, 1209], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 28, "universal_type": "function", "name": "unknown", "text_snippet": "#define GPIOHS_OUT_HIGH(io) (*(volatile uint32_t *)0x3800100CU) |= (1 << (io))\n"}, {"node_id": 34, "universal_type": "function", "name": "unknown", "text_snippet": "#define GPIOHS_OUT_LOWX(io) (*(volatile uint32_t *)0x3800100CU) &= ~(1 << (io))\n"}, {"node_id": 40, "universal_type": "function", "name": "unknown", "text_snippet": "#define GET_GPIOHS_VALX(io) (((*(volatile uint32_t *)0x38001000U) >> (io)) & 1)\n"}, {"node_id": 78, "universal_type": "function", "name": "unknown", "text_snippet": "_spi_config_io(uint8_t cs, uint8_t rst, uint8_t rdy, uint8_t mosi, uint8_t miso, uint8_t sclk)\n{\n "}, {"node_id": 80, "universal_type": "function", "name": "unknown", "text_snippet": "config_io(uint8_t cs, uint8_t rst, uint8_t rdy, uint8_t mosi, uint8_t miso, uint8_t sclk)\n{\n //c"}, {"node_id": 150, "universal_type": "function", "name": "sof", "text_snippet": "ft_spi_rw(uint8_t data)\n{\n uint8_t i;\n uint8_t temp = 0;\n for (i = 0; i < 8; i++)\n {\n "}, {"node_id": 152, "universal_type": "function", "name": "unknown", "text_snippet": "w(uint8_t data)\n{\n uin"}, {"node_id": 237, "universal_type": "function", "name": "unknown", "text_snippet": "spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {"}, {"node_id": 239, "universal_type": "function", "name": "unknown", "text_snippet": "w_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if "}, {"node_id": 403, "universal_type": "function", "name": "unknown", "text_snippet": "_transfer_width_t sipeed_spi_get_frame_size(size_t data_bit_length)\n{\n if (data_bit_length < 8)\n "}, {"node_id": 406, "universal_type": "function", "name": "unknown", "text_snippet": "_get_frame_size(size_t data_bit_length)\n{\n if "}, {"node_id": 431, "universal_type": "function", "name": "unknown", "text_snippet": "d sipeed_spi_set_tmod(uint8_t spi_num, uint32_t tmod)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX &&"}, {"node_id": 434, "universal_type": "function", "name": "unknown", "text_snippet": "_set_tmod(uint8_t spi_num, uint32_t tmod)\n{\n con"}, {"node_id": 525, "universal_type": "function", "name": "unknown", "text_snippet": "d sipeed_spi_transfer_data_standard(spi_device_num_t spi_num, spi_chip_select_t chip_select, const u"}, {"node_id": 528, "universal_type": "function", "name": "unknown", "text_snippet": "_transfer_data_standard(spi_device_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_b"}, {"node_id": 1033, "universal_type": "function", "name": "unknown", "text_snippet": "oid)\n{\n printf(\"hard spi\\r\\n\");\n //cs\n gpiohs_set_drive_mode(ESP32_SPI_CSX_HS_NUM, GPIO_DM_"}, {"node_id": 1035, "universal_type": "function", "name": "unknown", "text_snippet": "{\n printf(\"hard "}, {"node_id": 1078, "universal_type": "function", "name": "soft_spi_rw_l", "text_snippet": "uint8_t data)\n{\n uint8_t c;\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0"}, {"node_id": 1080, "universal_type": "function", "name": "unknown", "text_snippet": "data)\n{\n uint8_t c;\n "}, {"node_id": 1101, "universal_type": "function", "name": "unknown", "text_snippet": "(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n p"}, {"node_id": 1103, "universal_type": "function", "name": "unknown", "text_snippet": "8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == N"}, {"node_id": 1197, "universal_type": "function", "name": "unknown", "text_snippet": "void)\n{\n return sysctl_get_time_us() / 1000;\n}\n"}, {"node_id": 1199, "universal_type": "function", "name": "unknown", "text_snippet": " return sysctl"}], "class_declarations": [{"node_id": 404, "universal_type": "class", "name": "unknown", "text_snippet": "_trans"}, {"node_id": 432, "universal_type": "class", "name": "unknown", "text_snippet": "d sipe"}, {"node_id": 526, "universal_type": "class", "name": "unknown", "text_snippet": "d sipe"}], "import_statements": [{"node_id": 0, "text": "#include <stdlib.h>\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include \"esp32_spi_io.h\"\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include \"gpiohs.h\"\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include \"sleep.h\"\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include \"sysctl.h\"\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include <utils.h>\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include \"spi.h\"\n"}, {"node_id": 19, "text": "#include"}, {"node_id": 21, "text": "#include \"esp32_spi.h\"\n"}, {"node_id": 22, "text": "#include"}]}, "original_source_code": "#include <stdlib.h>\n#include \"esp32_spi_io.h\"\n#include \"gpiohs.h\"\n#include \"sleep.h\"\n#include \"sysctl.h\"\n\n#include <utils.h>\n#include \"spi.h\"\n#include \"esp32_spi.h\"\n\n#if 1 /* ESP32_SOFT_SPI */\n\n#define GPIOHS_OUT_HIGH(io) (*(volatile uint32_t *)0x3800100CU) |= (1 << (io))\n#define GPIOHS_OUT_LOWX(io) (*(volatile uint32_t *)0x3800100CU) &= ~(1 << (io))\n\n#define GET_GPIOHS_VALX(io) (((*(volatile uint32_t *)0x38001000U) >> (io)) & 1)\n\nuint8_t cs_num = 0, rst_num = 0, rdy_num = 0;\n\nstatic uint8_t _mosi_num = -1;\nstatic uint8_t _miso_num = -1;\nstatic uint8_t _sclk_num = -1;\n\n/* SPI\u7aef\u53e3\u521d\u59cb\u5316 */\n//should check io value\nvoid esp32_spi_config_io(uint8_t cs, uint8_t rst, uint8_t rdy, uint8_t mosi, uint8_t miso, uint8_t sclk)\n{\n //clk\n gpiohs_set_drive_mode(sclk, GPIO_DM_OUTPUT);\n gpiohs_set_pin(sclk, 0);\n //mosi\n gpiohs_set_drive_mode(mosi, GPIO_DM_OUTPUT);\n gpiohs_set_pin(mosi, 0);\n //miso\n gpiohs_set_drive_mode(miso, GPIO_DM_INPUT_PULL_UP);\n\n _mosi_num = mosi;\n _miso_num = miso;\n _sclk_num = sclk;\n\n cs_num = cs;\n rdy_num = rdy;\n rst_num = rst; //if rst <0, use soft reset\n}\n\nuint8_t soft_spi_rw(uint8_t data)\n{\n uint8_t i;\n uint8_t temp = 0;\n for (i = 0; i < 8; i++)\n {\n if (data & 0x80)\n {\n GPIOHS_OUT_HIGH(_mosi_num);\n }\n else\n {\n GPIOHS_OUT_LOWX(_mosi_num);\n }\n data <<= 1;\n GPIOHS_OUT_HIGH(_sclk_num);\n\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n\n temp <<= 1;\n if (GET_GPIOHS_VALX(_miso_num))\n {\n temp++;\n }\n GPIOHS_OUT_LOWX(_sclk_num);\n\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n asm volatile(\"nop\");\n }\n return temp;\n}\n\nvoid soft_spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(\" buffer is null\\r\\n\");\n return;\n }\n\n#if 0\n uint32_t i = 0;\n do\n {\n *(recv + i) = soft_spi_rw(*(send + i));\n i++;\n } while (--len);\n#else\n\n uint32_t i = 0;\n uint8_t *stmp = NULL, sf = 0;\n\n if (send == NULL)\n {\n stmp = (uint8_t *)malloc(len * sizeof(uint8_t));\n // memset(stmp, 'A', len);\n sf = 1;\n }\n else\n stmp = send;\n\n if (recv == NULL)\n {\n do\n {\n soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n else\n {\n do\n {\n *(recv + i) = soft_spi_rw(*(stmp + i));\n i++;\n } while (--len);\n }\n\n if (sf)\n free(stmp);\n#endif\n}\n\n#else\n\nstatic spi_transfer_width_t sipeed_spi_get_frame_size(size_t data_bit_length)\n{\n if (data_bit_length < 8)\n return SPI_TRANS_CHAR;\n else if (data_bit_length < 16)\n return SPI_TRANS_SHORT;\n return SPI_TRANS_INT;\n}\n\nstatic void sipeed_spi_set_tmod(uint8_t spi_num, uint32_t tmod)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n volatile spi_t *spi_handle = spi[spi_num];\n uint8_t tmod_offset = 0;\n switch (spi_num)\n {\n case 0:\n case 1:\n tmod_offset = 8;\n break;\n case 2:\n configASSERT(!\"Spi Bus 2 Not Support!\");\n break;\n case 3:\n default:\n tmod_offset = 10;\n break;\n }\n set_bit(&spi_handle->ctrlr0, 3 << tmod_offset, tmod << tmod_offset);\n}\n\nstatic void sipeed_spi_transfer_data_standard(spi_device_num_t spi_num, spi_chip_select_t chip_select, const uint8_t *tx_buff, uint8_t *rx_buff, size_t len)\n{\n configASSERT(spi_num < SPI_DEVICE_MAX && spi_num != 2);\n configASSERT(len > 0);\n size_t index, fifo_len;\n size_t rx_len = len;\n size_t tx_len = rx_len;\n sipeed_spi_set_tmod(spi_num, SPI_TMOD_TRANS_RECV);\n\n volatile spi_t *spi_handle = spi[spi_num];\n\n uint8_t dfs_offset;\n switch (spi_num)\n {\n case 0:\n case 1:\n dfs_offset = 16;\n break;\n case 2:\n configASSERT(!\"Spi Bus 2 Not Support!\");\n break;\n case 3:\n default:\n dfs_offset = 0;\n break;\n }\n uint32_t data_bit_length = (spi_handle->ctrlr0 >> dfs_offset) & 0x1F;\n spi_transfer_width_t frame_width = sipeed_spi_get_frame_size(data_bit_length);\n spi_handle->ctrlr1 = (uint32_t)(tx_len / frame_width - 1);\n spi_handle->ssienr = 0x01;\n spi_handle->ser = 1U << chip_select;\n uint32_t i = 0;\n while (tx_len)\n {\n fifo_len = 32 - spi_handle->txflr;\n fifo_len = fifo_len < tx_len ? fifo_len : tx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n spi_handle->dr[0] = ((uint32_t *)tx_buff)[i++];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n spi_handle->dr[0] = ((uint16_t *)tx_buff)[i++];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n spi_handle->dr[0] = tx_buff[i++];\n break;\n }\n tx_len -= fifo_len;\n }\n\n while ((spi_handle->sr & 0x05) != 0x04)\n ;\n i = 0;\n while (rx_len)\n {\n fifo_len = spi_handle->rxflr;\n fifo_len = fifo_len < rx_len ? fifo_len : rx_len;\n switch (frame_width)\n {\n case SPI_TRANS_INT:\n fifo_len = fifo_len / 4 * 4;\n for (index = 0; index < fifo_len / 4; index++)\n ((uint32_t *)rx_buff)[i++] = spi_handle->dr[0];\n break;\n case SPI_TRANS_SHORT:\n fifo_len = fifo_len / 2 * 2;\n for (index = 0; index < fifo_len / 2; index++)\n ((uint16_t *)rx_buff)[i++] = (uint16_t)spi_handle->dr[0];\n break;\n default:\n for (index = 0; index < fifo_len; index++)\n rx_buff[i++] = (uint8_t)spi_handle->dr[0];\n break;\n }\n\n rx_len -= fifo_len;\n }\n spi_handle->ser = 0x00;\n spi_handle->ssienr = 0x00;\n}\n\n/* SPI\u7aef\u53e3\u521d\u59cb\u5316 */\nvoid soft_spi_init(void)\n{\n printf(\"hard spi\\r\\n\");\n //cs\n gpiohs_set_drive_mode(ESP32_SPI_CSX_HS_NUM, GPIO_DM_OUTPUT);\n gpiohs_set_pin(ESP32_SPI_CSX_HS_NUM, 1);\n //init SPI_DEVICE_1\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n printf(\"set spi clk:%d\\r\\n\", spi_set_clk_rate(SPI_DEVICE_1, 1000000 * 8)); /*set clk rate*/\n}\n\nuint8_t soft_spi_rw(uint8_t data)\n{\n uint8_t c;\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, &data, &c, 1);\n return c;\n}\n\nvoid soft_spi_rw_len(uint8_t *send, uint8_t *recv, uint32_t len)\n{\n if (send == NULL && recv == NULL)\n {\n printf(\" buffer is null\\r\\n\");\n return;\n }\n\n#if 0\n spi_init(SPI_DEVICE_1, SPI_WORK_MODE_0, SPI_FF_STANDARD, 8, 0);\n#endif\n\n //only send\n if (send && recv == NULL)\n {\n spi_send_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, send, len);\n return;\n }\n\n //only recv\n if (send == NULL && recv)\n {\n spi_receive_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, NULL, 0, recv, len);\n return;\n }\n\n //send and recv\n if (send && recv)\n {\n sipeed_spi_transfer_data_standard(SPI_DEVICE_1, SPI_CHIP_SELECT_0, send, recv, len);\n return;\n }\n return;\n}\n\n#endif\n\nuint64_t get_millis(void)\n{\n return sysctl_get_time_us() / 1000;\n}\n"}
80,578
c
/* * * (c) 2020 iomonad <<EMAIL>> * * This is part of the KFS Project * See: https://github.com/iomonad/KFS * */ #ifndef MEMORY_H #define MEMORY_H #include <types.h> typedef uint32_t kheap_t; /* Assembly Ref */ extern void *stack_bottom; extern void *stack_top; /* PROTOTYPES */ void __attribute__ ((cold)) install_system_memory(void); /* API */ void *kmalloc(size_t size); #endif /* MEMORY_H */
19.15
20
(translation_unit) "/*\n *\n * (c) 2020 iomonad <<EMAIL>>\n *\n * This is part of the KFS Project\n * See: https://github.com/iomonad/KFS\n *\n */\n#ifndef MEMORY_H\n#define MEMORY_H\n\n#include <types.h>\n\ntypedef uint32_t kheap_t;\n\n/* Assembly Ref */\nextern void *stack_bottom;\nextern void *stack_top;\n\n/* PROTOTYPES */\nvoid __attribute__ ((cold)) install_system_memory(void);\n\n/* API */\nvoid *kmalloc(size_t size);\n\n#endif /* MEMORY_H */\n" (comment) "/*\n *\n * (c) 2020 iomonad <<EMAIL>>\n *\n * This is part of the KFS Project\n * See: https://github.com/iomonad/KFS\n *\n */" (preproc_ifdef) "#ifndef MEMORY_H\n#define MEMORY_H\n\n#include <types.h>\n\ntypedef uint32_t kheap_t;\n\n/* Assembly Ref */\nextern void *stack_bottom;\nextern void *stack_top;\n\n/* PROTOTYPES */\nvoid __attribute__ ((cold)) install_system_memory(void);\n\n/* API */\nvoid *kmalloc(size_t size);\n\n#endif" (#ifndef) "#ifndef" (identifier) "MEMORY_H" (preproc_def) "#define MEMORY_H\n" (#define) "#define" (identifier) "MEMORY_H" (preproc_include) "#include <types.h>\n" (#include) "#include" (system_lib_string) "<types.h>" (type_definition) "typedef uint32_t kheap_t;" (typedef) "typedef" (primitive_type) "uint32_t" (type_identifier) "kheap_t" (;) ";" (comment) "/* Assembly Ref */" (declaration) "extern void *stack_bottom;" (storage_class_specifier) "extern" (extern) "extern" (primitive_type) "void" (pointer_declarator) "*stack_bottom" (*) "*" (identifier) "stack_bottom" (;) ";" (declaration) "extern void *stack_top;" (storage_class_specifier) "extern" (extern) "extern" (primitive_type) "void" (pointer_declarator) "*stack_top" (*) "*" (identifier) "stack_top" (;) ";" (comment) "/* PROTOTYPES */" (declaration) "void __attribute__ ((cold)) install_system_memory(void);" (primitive_type) "void" (attribute_specifier) "__attribute__ ((cold))" (__attribute__) "__attribute__" (() "(" (argument_list) "(cold)" (() "(" (identifier) "cold" ()) ")" ()) ")" (function_declarator) "install_system_memory(void)" (identifier) "install_system_memory" (parameter_list) "(void)" (() "(" (parameter_declaration) "void" (primitive_type) "void" ()) ")" (;) ";" (comment) "/* API */" (declaration) "void *kmalloc(size_t size);" (primitive_type) "void" (pointer_declarator) "*kmalloc(size_t size)" (*) "*" (function_declarator) "kmalloc(size_t size)" (identifier) "kmalloc" (parameter_list) "(size_t size)" (() "(" (parameter_declaration) "size_t size" (primitive_type) "size_t" (identifier) "size" ()) ")" (;) ";" (#endif) "#endif" (comment) "/* MEMORY_H */"
68
0
{"language": "c", "success": true, "metadata": {"lines": 20, "avg_line_length": 19.15, "nodes": 49, "errors": 0, "source_hash": "855f3d0759f0dd1198d70c5b92f9bcd053eddf10317313308774ebe75c64c854", "categorized_nodes": 27}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef MEMORY_H\n#define MEMORY_H\n\n#include <types.h>\n\ntypedef uint32_t kheap_t;\n\n/* Assembly Ref */\nextern void *stack_bottom;\nextern void *stack_top;\n\n/* PROTOTYPES */\nvoid __attribute__ ((cold)) install_system_memory(void);\n\n/* API */\nvoid *kmalloc(size_t size);\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 13, 20, 27, 38, 48], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 25, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 7}}, {"id": 2, "type": "identifier", "text": "MEMORY_H", "parent": 0, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 16}}, {"id": 3, "type": "preproc_def", "text": "#define MEMORY_H\n", "parent": 0, "children": [4, 5], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 7}}, {"id": 5, "type": "identifier", "text": "MEMORY_H", "parent": 3, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 16}}, {"id": 6, "type": "preproc_include", "text": "#include <types.h>\n", "parent": 0, "children": [7, 8], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 12, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<types.h>", "parent": 6, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 18}}, {"id": 9, "type": "type_definition", "text": "typedef uint32_t kheap_t;", "parent": 0, "children": [10, 11, 12], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 25}}, {"id": 10, "type": "typedef", "text": "typedef", "parent": 9, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 7}}, {"id": 11, "type": "primitive_type", "text": "uint32_t", "parent": 9, "children": [], "start_point": {"row": 13, "column": 8}, "end_point": {"row": 13, "column": 16}}, {"id": 12, "type": "type_identifier", "text": "kheap_t", "parent": 9, "children": [], "start_point": {"row": 13, "column": 17}, "end_point": {"row": 13, "column": 24}}, {"id": 13, "type": "declaration", "text": "extern void *stack_bottom;", "parent": 0, "children": [14, 16, 17], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 26}}, {"id": 14, "type": "storage_class_specifier", "text": "extern", "parent": 13, "children": [15], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 6}}, {"id": 15, "type": "extern", "text": "extern", "parent": 14, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 6}}, {"id": 16, "type": "primitive_type", "text": "void", "parent": 13, "children": [], "start_point": {"row": 16, "column": 7}, "end_point": {"row": 16, "column": 11}}, {"id": 17, "type": "pointer_declarator", "text": "*stack_bottom", "parent": 13, "children": [18, 19], "start_point": {"row": 16, "column": 12}, "end_point": {"row": 16, "column": 25}}, {"id": 18, "type": "*", "text": "*", "parent": 17, "children": [], "start_point": {"row": 16, "column": 12}, "end_point": {"row": 16, "column": 13}}, {"id": 19, "type": "identifier", "text": "stack_bottom", "parent": 17, "children": [], "start_point": {"row": 16, "column": 13}, "end_point": {"row": 16, "column": 25}}, {"id": 20, "type": "declaration", "text": "extern void *stack_top;", "parent": 0, "children": [21, 23, 24], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 23}}, {"id": 21, "type": "storage_class_specifier", "text": "extern", "parent": 20, "children": [22], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 6}}, {"id": 22, "type": "extern", "text": "extern", "parent": 21, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 6}}, {"id": 23, "type": "primitive_type", "text": "void", "parent": 20, "children": [], "start_point": {"row": 17, "column": 7}, "end_point": {"row": 17, "column": 11}}, {"id": 24, "type": "pointer_declarator", "text": "*stack_top", "parent": 20, "children": [25, 26], "start_point": {"row": 17, "column": 12}, "end_point": {"row": 17, "column": 22}}, {"id": 25, "type": "*", "text": "*", "parent": 24, "children": [], "start_point": {"row": 17, "column": 12}, "end_point": {"row": 17, "column": 13}}, {"id": 26, "type": "identifier", "text": "stack_top", "parent": 24, "children": [], "start_point": {"row": 17, "column": 13}, "end_point": {"row": 17, "column": 22}}, {"id": 27, "type": "declaration", "text": "void __attribute__ ((cold)) install_system_memory(void);", "parent": 0, "children": [28, 29, 33], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 56}}, {"id": 28, "type": "primitive_type", "text": "void", "parent": 27, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 4}}, {"id": 29, "type": "attribute_specifier", "text": "__attribute__ ((cold))", "parent": 27, "children": [30, 31], "start_point": {"row": 20, "column": 5}, "end_point": {"row": 20, "column": 27}}, {"id": 30, "type": "__attribute__", "text": "__attribute__", "parent": 29, "children": [], "start_point": {"row": 20, "column": 5}, "end_point": {"row": 20, "column": 18}}, {"id": 31, "type": "argument_list", "text": "(cold)", "parent": 29, "children": [32], "start_point": {"row": 20, "column": 20}, "end_point": {"row": 20, "column": 26}}, {"id": 32, "type": "identifier", "text": "cold", "parent": 31, "children": [], "start_point": {"row": 20, "column": 21}, "end_point": {"row": 20, "column": 25}}, {"id": 33, "type": "function_declarator", "text": "install_system_memory(void)", "parent": 27, "children": [34, 35], "start_point": {"row": 20, "column": 28}, "end_point": {"row": 20, "column": 55}}, {"id": 34, "type": "identifier", "text": "install_system_memory", "parent": 33, "children": [], "start_point": {"row": 20, "column": 28}, "end_point": {"row": 20, "column": 49}}, {"id": 35, "type": "parameter_list", "text": "(void)", "parent": 33, "children": [36], "start_point": {"row": 20, "column": 49}, "end_point": {"row": 20, "column": 55}}, {"id": 36, "type": "parameter_declaration", "text": "void", "parent": 35, "children": [37], "start_point": {"row": 20, "column": 50}, "end_point": {"row": 20, "column": 54}}, {"id": 37, "type": "primitive_type", "text": "void", "parent": 36, "children": [], "start_point": {"row": 20, "column": 50}, "end_point": {"row": 20, "column": 54}}, {"id": 38, "type": "declaration", "text": "void *kmalloc(size_t size);", "parent": 0, "children": [39, 40], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 27}}, {"id": 39, "type": "primitive_type", "text": "void", "parent": 38, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 4}}, {"id": 40, "type": "pointer_declarator", "text": "*kmalloc(size_t size)", "parent": 38, "children": [41, 42], "start_point": {"row": 23, "column": 5}, "end_point": {"row": 23, "column": 26}}, {"id": 41, "type": "*", "text": "*", "parent": 40, "children": [], "start_point": {"row": 23, "column": 5}, "end_point": {"row": 23, "column": 6}}, {"id": 42, "type": "function_declarator", "text": "kmalloc(size_t size)", "parent": 40, "children": [43, 44], "start_point": {"row": 23, "column": 6}, "end_point": {"row": 23, "column": 26}}, {"id": 43, "type": "identifier", "text": "kmalloc", "parent": 42, "children": [], "start_point": {"row": 23, "column": 6}, "end_point": {"row": 23, "column": 13}}, {"id": 44, "type": "parameter_list", "text": "(size_t size)", "parent": 42, "children": [45], "start_point": {"row": 23, "column": 13}, "end_point": {"row": 23, "column": 26}}, {"id": 45, "type": "parameter_declaration", "text": "size_t size", "parent": 44, "children": [46, 47], "start_point": {"row": 23, "column": 14}, "end_point": {"row": 23, "column": 25}}, {"id": 46, "type": "primitive_type", "text": "size_t", "parent": 45, "children": [], "start_point": {"row": 23, "column": 14}, "end_point": {"row": 23, "column": 20}}, {"id": 47, "type": "identifier", "text": "size", "parent": 45, "children": [], "start_point": {"row": 23, "column": 21}, "end_point": {"row": 23, "column": 25}}, {"id": 48, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 6}}]}, "node_categories": {"declarations": {"functions": [33, 42], "variables": [9, 13, 20, 27, 36, 38, 45], "classes": [14, 21], "imports": [6, 7], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 12, 19, 26, 29, 32, 34, 43, 47, 48], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [8], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 33, "universal_type": "function", "name": "unknown", "text_snippet": "install_system_memory(void)"}, {"node_id": 42, "universal_type": "function", "name": "unknown", "text_snippet": "kmalloc(size_t size)"}], "class_declarations": [{"node_id": 14, "universal_type": "class", "name": "unknown", "text_snippet": "extern"}, {"node_id": 21, "universal_type": "class", "name": "unknown", "text_snippet": "extern"}], "import_statements": [{"node_id": 6, "text": "#include <types.h>\n"}, {"node_id": 7, "text": "#include"}]}, "original_source_code": "/*\n *\n * (c) 2020 iomonad <<EMAIL>>\n *\n * This is part of the KFS Project\n * See: https://github.com/iomonad/KFS\n *\n */\n#ifndef MEMORY_H\n#define MEMORY_H\n\n#include <types.h>\n\ntypedef uint32_t kheap_t;\n\n/* Assembly Ref */\nextern void *stack_bottom;\nextern void *stack_top;\n\n/* PROTOTYPES */\nvoid __attribute__ ((cold)) install_system_memory(void);\n\n/* API */\nvoid *kmalloc(size_t size);\n\n#endif\t/* MEMORY_H */\n"}
80,579
c
#include <stdio.h> #include <stdlib.h> #define SIZE 32768 char buf[SIZE]; int main(){ FILE *f = fopen("f.txt","rb"); fseek(f,0,SEEK_END); int s = ftell(f); rewind(f); for(int i=0; i<s; i+=SIZE){ if(s-i <= SIZE) fread(buf,1,s-i,f); else fread(buf,1,SIZE,f); } fclose(f); }
17
17
(translation_unit) "#include <stdio.h>\n#include <stdlib.h>\n\n#define SIZE 32768\n\nchar buf[SIZE];\n\nint main(){\n\n FILE *f = fopen("f.txt","rb");\n fseek(f,0,SEEK_END);\n int s = ftell(f);\n rewind(f);\n\n for(int i=0; i<s; i+=SIZE){\n if(s-i <= SIZE)\n fread(buf,1,s-i,f);\n else\n fread(buf,1,SIZE,f);\n }\n fclose(f);\n}\n" (preproc_include) "#include <stdio.h>\n" (#include) "#include" (system_lib_string) "<stdio.h>" (preproc_include) "#include <stdlib.h>\n" (#include) "#include" (system_lib_string) "<stdlib.h>" (preproc_def) "#define SIZE 32768\n" (#define) "#define" (identifier) "SIZE" (preproc_arg) "32768" (declaration) "char buf[SIZE];" (primitive_type) "char" (array_declarator) "buf[SIZE]" (identifier) "buf" ([) "[" (identifier) "SIZE" (]) "]" (;) ";" (function_definition) "int main(){\n\n FILE *f = fopen("f.txt","rb");\n fseek(f,0,SEEK_END);\n int s = ftell(f);\n rewind(f);\n\n for(int i=0; i<s; i+=SIZE){\n if(s-i <= SIZE)\n fread(buf,1,s-i,f);\n else\n fread(buf,1,SIZE,f);\n }\n fclose(f);\n}" (primitive_type) "int" (function_declarator) "main()" (identifier) "main" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n\n FILE *f = fopen("f.txt","rb");\n fseek(f,0,SEEK_END);\n int s = ftell(f);\n rewind(f);\n\n for(int i=0; i<s; i+=SIZE){\n if(s-i <= SIZE)\n fread(buf,1,s-i,f);\n else\n fread(buf,1,SIZE,f);\n }\n fclose(f);\n}" ({) "{" (declaration) "FILE *f = fopen("f.txt","rb");" (type_identifier) "FILE" (init_declarator) "*f = fopen("f.txt","rb")" (pointer_declarator) "*f" (*) "*" (identifier) "f" (=) "=" (call_expression) "fopen("f.txt","rb")" (identifier) "fopen" (argument_list) "("f.txt","rb")" (() "(" (string_literal) ""f.txt"" (") """ (string_content) "f.txt" (") """ (,) "," (string_literal) ""rb"" (") """ (string_content) "rb" (") """ ()) ")" (;) ";" (expression_statement) "fseek(f,0,SEEK_END);" (call_expression) "fseek(f,0,SEEK_END)" (identifier) "fseek" (argument_list) "(f,0,SEEK_END)" (() "(" (identifier) "f" (,) "," (number_literal) "0" (,) "," (identifier) "SEEK_END" ()) ")" (;) ";" (declaration) "int s = ftell(f);" (primitive_type) "int" (init_declarator) "s = ftell(f)" (identifier) "s" (=) "=" (call_expression) "ftell(f)" (identifier) "ftell" (argument_list) "(f)" (() "(" (identifier) "f" ()) ")" (;) ";" (expression_statement) "rewind(f);" (call_expression) "rewind(f)" (identifier) "rewind" (argument_list) "(f)" (() "(" (identifier) "f" ()) ")" (;) ";" (for_statement) "for(int i=0; i<s; i+=SIZE){\n if(s-i <= SIZE)\n fread(buf,1,s-i,f);\n else\n fread(buf,1,SIZE,f);\n }" (for) "for" (() "(" (declaration) "int i=0;" (primitive_type) "int" (init_declarator) "i=0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i<s" (identifier) "i" (<) "<" (identifier) "s" (;) ";" (assignment_expression) "i+=SIZE" (identifier) "i" (+=) "+=" (identifier) "SIZE" ()) ")" (compound_statement) "{\n if(s-i <= SIZE)\n fread(buf,1,s-i,f);\n else\n fread(buf,1,SIZE,f);\n }" ({) "{" (if_statement) "if(s-i <= SIZE)\n fread(buf,1,s-i,f);\n else\n fread(buf,1,SIZE,f);" (if) "if" (parenthesized_expression) "(s-i <= SIZE)" (() "(" (binary_expression) "s-i <= SIZE" (binary_expression) "s-i" (identifier) "s" (-) "-" (identifier) "i" (<=) "<=" (identifier) "SIZE" ()) ")" (expression_statement) "fread(buf,1,s-i,f);" (call_expression) "fread(buf,1,s-i,f)" (identifier) "fread" (argument_list) "(buf,1,s-i,f)" (() "(" (identifier) "buf" (,) "," (number_literal) "1" (,) "," (binary_expression) "s-i" (identifier) "s" (-) "-" (identifier) "i" (,) "," (identifier) "f" ()) ")" (;) ";" (else_clause) "else\n fread(buf,1,SIZE,f);" (else) "else" (expression_statement) "fread(buf,1,SIZE,f);" (call_expression) "fread(buf,1,SIZE,f)" (identifier) "fread" (argument_list) "(buf,1,SIZE,f)" (() "(" (identifier) "buf" (,) "," (number_literal) "1" (,) "," (identifier) "SIZE" (,) "," (identifier) "f" ()) ")" (;) ";" (}) "}" (expression_statement) "fclose(f);" (call_expression) "fclose(f)" (identifier) "fclose" (argument_list) "(f)" (() "(" (identifier) "f" ()) ")" (;) ";" (}) "}"
159
0
{"language": "c", "success": true, "metadata": {"lines": 17, "avg_line_length": 17.0, "nodes": 97, "errors": 0, "source_hash": "d0f97a28af9dcc7e691f280f635729fb5bf2b1ab900cfb070ed71e3a18d3b7b1", "categorized_nodes": 67}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <stdio.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<stdio.h>", "parent": 0, "children": [], "start_point": {"row": 1, "column": 9}, "end_point": {"row": 1, "column": 18}}, {"id": 3, "type": "preproc_include", "text": "#include <stdlib.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<stdlib.h>", "parent": 3, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 19}}, {"id": 6, "type": "preproc_def", "text": "#define SIZE 32768\n", "parent": null, "children": [7, 8, 9], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 7, "type": "#define", "text": "#define", "parent": 6, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 7}}, {"id": 8, "type": "identifier", "text": "SIZE", "parent": 6, "children": [], "start_point": {"row": 4, "column": 8}, "end_point": {"row": 4, "column": 12}}, {"id": 9, "type": "preproc_arg", "text": "32768", "parent": 6, "children": [], "start_point": {"row": 4, "column": 13}, "end_point": {"row": 4, "column": 18}}, {"id": 10, "type": "declaration", "text": "char buf[SIZE];", "parent": null, "children": [11, 12], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 15}}, {"id": 11, "type": "primitive_type", "text": "char", "parent": 10, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 4}}, {"id": 12, "type": "array_declarator", "text": "buf[SIZE]", "parent": 10, "children": [13, 14], "start_point": {"row": 6, "column": 5}, "end_point": {"row": 6, "column": 14}}, {"id": 13, "type": "identifier", "text": "buf", "parent": 12, "children": [], "start_point": {"row": 6, "column": 5}, "end_point": {"row": 6, "column": 8}}, {"id": 14, "type": "identifier", "text": "SIZE", "parent": 12, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 13}}, {"id": 15, "type": "function_definition", "text": "int main(){\n\n FILE *f = fopen(\"f.txt\",\"rb\");\n fseek(f,0,SEEK_END);\n int s = ftell(f);\n rewind(f);\n\n for(int i=0; i<s; i+=SIZE){\n if(s-i <= SIZE)\n fread(buf,1,s-i,f);\n else\n fread(buf,1,SIZE,f);\n }\n fclose(f);\n}", "parent": null, "children": [16, 17], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 22, "column": 1}}, {"id": 16, "type": "primitive_type", "text": "int", "parent": 15, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 3}}, {"id": 17, "type": "function_declarator", "text": "main()", "parent": 15, "children": [18, 19], "start_point": {"row": 8, "column": 4}, "end_point": {"row": 8, "column": 10}}, {"id": 18, "type": "identifier", "text": "main", "parent": 17, "children": [], "start_point": {"row": 8, "column": 4}, "end_point": {"row": 8, "column": 8}}, {"id": 19, "type": "parameter_list", "text": "()", "parent": 17, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 10}}, {"id": 20, "type": "declaration", "text": "FILE *f = fopen(\"f.txt\",\"rb\");", "parent": 15, "children": [21, 22], "start_point": {"row": 10, "column": 2}, "end_point": {"row": 10, "column": 32}}, {"id": 21, "type": "type_identifier", "text": "FILE", "parent": 20, "children": [], "start_point": {"row": 10, "column": 2}, "end_point": {"row": 10, "column": 6}}, {"id": 22, "type": "init_declarator", "text": "*f = fopen(\"f.txt\",\"rb\")", "parent": 20, "children": [23, 26, 27], "start_point": {"row": 10, "column": 7}, "end_point": {"row": 10, "column": 31}}, {"id": 23, "type": "pointer_declarator", "text": "*f", "parent": 22, "children": [24, 25], "start_point": {"row": 10, "column": 7}, "end_point": {"row": 10, "column": 9}}, {"id": 24, "type": "*", "text": "*", "parent": 23, "children": [], "start_point": {"row": 10, "column": 7}, "end_point": {"row": 10, "column": 8}}, {"id": 25, "type": "identifier", "text": "f", "parent": 23, "children": [], "start_point": {"row": 10, "column": 8}, "end_point": {"row": 10, "column": 9}}, {"id": 26, "type": "=", "text": "=", "parent": 22, "children": [], "start_point": {"row": 10, "column": 10}, "end_point": {"row": 10, "column": 11}}, {"id": 27, "type": "call_expression", "text": "fopen(\"f.txt\",\"rb\")", "parent": 22, "children": [28, 29], "start_point": {"row": 10, "column": 12}, "end_point": {"row": 10, "column": 31}}, {"id": 28, "type": "identifier", "text": "fopen", "parent": 27, "children": [], "start_point": {"row": 10, "column": 12}, "end_point": {"row": 10, "column": 17}}, {"id": 29, "type": "argument_list", "text": "(\"f.txt\",\"rb\")", "parent": 27, "children": [30, 31], "start_point": {"row": 10, "column": 17}, "end_point": {"row": 10, "column": 31}}, {"id": 30, "type": "string_literal", "text": "\"f.txt\"", "parent": 29, "children": [], "start_point": {"row": 10, "column": 18}, "end_point": {"row": 10, "column": 25}}, {"id": 31, "type": "string_literal", "text": "\"rb\"", "parent": 29, "children": [], "start_point": {"row": 10, "column": 26}, "end_point": {"row": 10, "column": 30}}, {"id": 32, "type": "call_expression", "text": "fseek(f,0,SEEK_END)", "parent": 15, "children": [33, 34], "start_point": {"row": 11, "column": 2}, "end_point": {"row": 11, "column": 21}}, {"id": 33, "type": "identifier", "text": "fseek", "parent": 32, "children": [], "start_point": {"row": 11, "column": 2}, "end_point": {"row": 11, "column": 7}}, {"id": 34, "type": "argument_list", "text": "(f,0,SEEK_END)", "parent": 32, "children": [35, 36, 37], "start_point": {"row": 11, "column": 7}, "end_point": {"row": 11, "column": 21}}, {"id": 35, "type": "identifier", "text": "f", "parent": 34, "children": [], "start_point": {"row": 11, "column": 8}, "end_point": {"row": 11, "column": 9}}, {"id": 36, "type": "number_literal", "text": "0", "parent": 34, "children": [], "start_point": {"row": 11, "column": 10}, "end_point": {"row": 11, "column": 11}}, {"id": 37, "type": "identifier", "text": "SEEK_END", "parent": 34, "children": [], "start_point": {"row": 11, "column": 12}, "end_point": {"row": 11, "column": 20}}, {"id": 38, "type": "declaration", "text": "int s = ftell(f);", "parent": 15, "children": [39, 40], "start_point": {"row": 12, "column": 2}, "end_point": {"row": 12, "column": 19}}, {"id": 39, "type": "primitive_type", "text": "int", "parent": 38, "children": [], "start_point": {"row": 12, "column": 2}, "end_point": {"row": 12, "column": 5}}, {"id": 40, "type": "init_declarator", "text": "s = ftell(f)", "parent": 38, "children": [41, 42, 43], "start_point": {"row": 12, "column": 6}, "end_point": {"row": 12, "column": 18}}, {"id": 41, "type": "identifier", "text": "s", "parent": 40, "children": [], "start_point": {"row": 12, "column": 6}, "end_point": {"row": 12, "column": 7}}, {"id": 42, "type": "=", "text": "=", "parent": 40, "children": [], "start_point": {"row": 12, "column": 8}, "end_point": {"row": 12, "column": 9}}, {"id": 43, "type": "call_expression", "text": "ftell(f)", "parent": 40, "children": [44, 45], "start_point": {"row": 12, "column": 10}, "end_point": {"row": 12, "column": 18}}, {"id": 44, "type": "identifier", "text": "ftell", "parent": 43, "children": [], "start_point": {"row": 12, "column": 10}, "end_point": {"row": 12, "column": 15}}, {"id": 45, "type": "argument_list", "text": "(f)", "parent": 43, "children": [46], "start_point": {"row": 12, "column": 15}, "end_point": {"row": 12, "column": 18}}, {"id": 46, "type": "identifier", "text": "f", "parent": 45, "children": [], "start_point": {"row": 12, "column": 16}, "end_point": {"row": 12, "column": 17}}, {"id": 47, "type": "call_expression", "text": "rewind(f)", "parent": 15, "children": [48, 49], "start_point": {"row": 13, "column": 2}, "end_point": {"row": 13, "column": 11}}, {"id": 48, "type": "identifier", "text": "rewind", "parent": 47, "children": [], "start_point": {"row": 13, "column": 2}, "end_point": {"row": 13, "column": 8}}, {"id": 49, "type": "argument_list", "text": "(f)", "parent": 47, "children": [50], "start_point": {"row": 13, "column": 8}, "end_point": {"row": 13, "column": 11}}, {"id": 50, "type": "identifier", "text": "f", "parent": 49, "children": [], "start_point": {"row": 13, "column": 9}, "end_point": {"row": 13, "column": 10}}, {"id": 51, "type": "for_statement", "text": "for(int i=0; i<s; i+=SIZE){\n if(s-i <= SIZE)\n fread(buf,1,s-i,f);\n else\n fread(buf,1,SIZE,f);\n }", "parent": 15, "children": [52, 58, 62], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 20, "column": 3}}, {"id": 52, "type": "declaration", "text": "int i=0;", "parent": 51, "children": [53, 54], "start_point": {"row": 15, "column": 6}, "end_point": {"row": 15, "column": 14}}, {"id": 53, "type": "primitive_type", "text": "int", "parent": 52, "children": [], "start_point": {"row": 15, "column": 6}, "end_point": {"row": 15, "column": 9}}, {"id": 54, "type": "init_declarator", "text": "i=0", "parent": 52, "children": [55, 56, 57], "start_point": {"row": 15, "column": 10}, "end_point": {"row": 15, "column": 13}}, {"id": 55, "type": "identifier", "text": "i", "parent": 54, "children": [], "start_point": {"row": 15, "column": 10}, "end_point": {"row": 15, "column": 11}}, {"id": 56, "type": "=", "text": "=", "parent": 54, "children": [], "start_point": {"row": 15, "column": 11}, "end_point": {"row": 15, "column": 12}}, {"id": 57, "type": "number_literal", "text": "0", "parent": 54, "children": [], "start_point": {"row": 15, "column": 12}, "end_point": {"row": 15, "column": 13}}, {"id": 58, "type": "binary_expression", "text": "i<s", "parent": 51, "children": [59, 60, 61], "start_point": {"row": 15, "column": 15}, "end_point": {"row": 15, "column": 18}}, {"id": 59, "type": "identifier", "text": "i", "parent": 58, "children": [], "start_point": {"row": 15, "column": 15}, "end_point": {"row": 15, "column": 16}}, {"id": 60, "type": "<", "text": "<", "parent": 58, "children": [], "start_point": {"row": 15, "column": 16}, "end_point": {"row": 15, "column": 17}}, {"id": 61, "type": "identifier", "text": "s", "parent": 58, "children": [], "start_point": {"row": 15, "column": 17}, "end_point": {"row": 15, "column": 18}}, {"id": 62, "type": "assignment_expression", "text": "i+=SIZE", "parent": 51, "children": [63, 64, 65], "start_point": {"row": 15, "column": 20}, "end_point": {"row": 15, "column": 27}}, {"id": 63, "type": "identifier", "text": "i", "parent": 62, "children": [], "start_point": {"row": 15, "column": 20}, "end_point": {"row": 15, "column": 21}}, {"id": 64, "type": "+=", "text": "+=", "parent": 62, "children": [], "start_point": {"row": 15, "column": 21}, "end_point": {"row": 15, "column": 23}}, {"id": 65, "type": "identifier", "text": "SIZE", "parent": 62, "children": [], "start_point": {"row": 15, "column": 23}, "end_point": {"row": 15, "column": 27}}, {"id": 66, "type": "if_statement", "text": "if(s-i <= SIZE)\n fread(buf,1,s-i,f);\n else\n fread(buf,1,SIZE,f);", "parent": 51, "children": [67, 85], "start_point": {"row": 16, "column": 4}, "end_point": {"row": 19, "column": 26}}, {"id": 67, "type": "parenthesized_expression", "text": "(s-i <= SIZE)", "parent": 66, "children": [68], "start_point": {"row": 16, "column": 6}, "end_point": {"row": 16, "column": 19}}, {"id": 68, "type": "binary_expression", "text": "s-i <= SIZE", "parent": 67, "children": [69, 73, 74], "start_point": {"row": 16, "column": 7}, "end_point": {"row": 16, "column": 18}}, {"id": 69, "type": "binary_expression", "text": "s-i", "parent": 68, "children": [70, 71, 72], "start_point": {"row": 16, "column": 7}, "end_point": {"row": 16, "column": 10}}, {"id": 70, "type": "identifier", "text": "s", "parent": 69, "children": [], "start_point": {"row": 16, "column": 7}, "end_point": {"row": 16, "column": 8}}, {"id": 71, "type": "-", "text": "-", "parent": 69, "children": [], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 9}}, {"id": 72, "type": "identifier", "text": "i", "parent": 69, "children": [], "start_point": {"row": 16, "column": 9}, "end_point": {"row": 16, "column": 10}}, {"id": 73, "type": "<=", "text": "<=", "parent": 68, "children": [], "start_point": {"row": 16, "column": 11}, "end_point": {"row": 16, "column": 13}}, {"id": 74, "type": "identifier", "text": "SIZE", "parent": 68, "children": [], "start_point": {"row": 16, "column": 14}, "end_point": {"row": 16, "column": 18}}, {"id": 75, "type": "call_expression", "text": "fread(buf,1,s-i,f)", "parent": 66, "children": [76, 77], "start_point": {"row": 17, "column": 6}, "end_point": {"row": 17, "column": 24}}, {"id": 76, "type": "identifier", "text": "fread", "parent": 75, "children": [], "start_point": {"row": 17, "column": 6}, "end_point": {"row": 17, "column": 11}}, {"id": 77, "type": "argument_list", "text": "(buf,1,s-i,f)", "parent": 75, "children": [78, 79, 80, 84], "start_point": {"row": 17, "column": 11}, "end_point": {"row": 17, "column": 24}}, {"id": 78, "type": "identifier", "text": "buf", "parent": 77, "children": [], "start_point": {"row": 17, "column": 12}, "end_point": {"row": 17, "column": 15}}, {"id": 79, "type": "number_literal", "text": "1", "parent": 77, "children": [], "start_point": {"row": 17, "column": 16}, "end_point": {"row": 17, "column": 17}}, {"id": 80, "type": "binary_expression", "text": "s-i", "parent": 77, "children": [81, 82, 83], "start_point": {"row": 17, "column": 18}, "end_point": {"row": 17, "column": 21}}, {"id": 81, "type": "identifier", "text": "s", "parent": 80, "children": [], "start_point": {"row": 17, "column": 18}, "end_point": {"row": 17, "column": 19}}, {"id": 82, "type": "-", "text": "-", "parent": 80, "children": [], "start_point": {"row": 17, "column": 19}, "end_point": {"row": 17, "column": 20}}, {"id": 83, "type": "identifier", "text": "i", "parent": 80, "children": [], "start_point": {"row": 17, "column": 20}, "end_point": {"row": 17, "column": 21}}, {"id": 84, "type": "identifier", "text": "f", "parent": 77, "children": [], "start_point": {"row": 17, "column": 22}, "end_point": {"row": 17, "column": 23}}, {"id": 85, "type": "else_clause", "text": "else\n fread(buf,1,SIZE,f);", "parent": 66, "children": [], "start_point": {"row": 18, "column": 4}, "end_point": {"row": 19, "column": 26}}, {"id": 86, "type": "call_expression", "text": "fread(buf,1,SIZE,f)", "parent": 85, "children": [87, 88], "start_point": {"row": 19, "column": 6}, "end_point": {"row": 19, "column": 25}}, {"id": 87, "type": "identifier", "text": "fread", "parent": 86, "children": [], "start_point": {"row": 19, "column": 6}, "end_point": {"row": 19, "column": 11}}, {"id": 88, "type": "argument_list", "text": "(buf,1,SIZE,f)", "parent": 86, "children": [89, 90, 91, 92], "start_point": {"row": 19, "column": 11}, "end_point": {"row": 19, "column": 25}}, {"id": 89, "type": "identifier", "text": "buf", "parent": 88, "children": [], "start_point": {"row": 19, "column": 12}, "end_point": {"row": 19, "column": 15}}, {"id": 90, "type": "number_literal", "text": "1", "parent": 88, "children": [], "start_point": {"row": 19, "column": 16}, "end_point": {"row": 19, "column": 17}}, {"id": 91, "type": "identifier", "text": "SIZE", "parent": 88, "children": [], "start_point": {"row": 19, "column": 18}, "end_point": {"row": 19, "column": 22}}, {"id": 92, "type": "identifier", "text": "f", "parent": 88, "children": [], "start_point": {"row": 19, "column": 23}, "end_point": {"row": 19, "column": 24}}, {"id": 93, "type": "call_expression", "text": "fclose(f)", "parent": 15, "children": [94, 95], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 11}}, {"id": 94, "type": "identifier", "text": "fclose", "parent": 93, "children": [], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 8}}, {"id": 95, "type": "argument_list", "text": "(f)", "parent": 93, "children": [96], "start_point": {"row": 21, "column": 8}, "end_point": {"row": 21, "column": 11}}, {"id": 96, "type": "identifier", "text": "f", "parent": 95, "children": [], "start_point": {"row": 21, "column": 9}, "end_point": {"row": 21, "column": 10}}]}, "node_categories": {"declarations": {"functions": [15, 17], "variables": [10, 20, 38, 52], "classes": [], "imports": [0, 1, 3, 4], "modules": [], "enums": []}, "statements": {"expressions": [27, 32, 43, 47, 58, 67, 68, 69, 75, 80, 86, 93], "assignments": [62], "loops": [51], "conditionals": [8, 13, 14, 18, 21, 25, 28, 33, 35, 37, 41, 44, 46, 48, 50, 55, 59, 61, 63, 65, 66, 70, 72, 74, 76, 78, 81, 83, 84, 87, 89, 91, 92, 94, 96], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 30, 31, 36, 57, 79, 90], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 15, "universal_type": "function", "name": "main", "text_snippet": "int main(){\n\n FILE *f = fopen(\"f.txt\",\"rb\");\n fseek(f,0,SEEK_END);\n int s = ftell(f);\n rewind(f)"}, {"node_id": 17, "universal_type": "function", "name": "unknown", "text_snippet": "main()"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <stdio.h>\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <stdlib.h>\n"}, {"node_id": 4, "text": "#include"}]}, "original_source_code": "\n#include <stdio.h>\n#include <stdlib.h>\n\n#define SIZE 32768\n\nchar buf[SIZE];\n\nint main(){\n\n FILE *f = fopen(\"f.txt\",\"rb\");\n fseek(f,0,SEEK_END);\n int s = ftell(f);\n rewind(f);\n\n for(int i=0; i<s; i+=SIZE){\n if(s-i <= SIZE)\n fread(buf,1,s-i,f);\n else\n fread(buf,1,SIZE,f);\n }\n fclose(f);\n}\n"}
80,580
c
#ifndef AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_ #define AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_ #import <AppKit/AppKit.h> #include <string> @interface ResizesToContentsViewController : NSTabViewController @end namespace av_speech_in_noise { auto nsTabViewControllerWithoutTabControl() -> NSTabViewController *; auto nsButton(const std::string &s, id target, SEL action) -> NSButton *; void addAutolayoutEnabledSubview(NSView *parent, NSView *child); auto subjectWindow() -> NSWindow *; } #endif
37.54
13
(translation_unit) "#ifndef AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_\n#define AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_\n\n#import <AppKit/AppKit.h>\n\n#include <string>\n\n@interface ResizesToContentsViewController : NSTabViewController\n@end\n\nnamespace av_speech_in_noise {\nauto nsTabViewControllerWithoutTabControl() -> NSTabViewController *;\nauto nsButton(const std::string &s, id target, SEL action) -> NSButton *;\nvoid addAutolayoutEnabledSubview(NSView *parent, NSView *child);\nauto subjectWindow() -> NSWindow *;\n}\n\n#endif\n" (preproc_ifdef) "#ifndef AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_\n#define AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_\n\n#import <AppKit/AppKit.h>\n\n#include <string>\n\n@interface ResizesToContentsViewController : NSTabViewController\n@end\n\nnamespace av_speech_in_noise {\nauto nsTabViewControllerWithoutTabControl() -> NSTabViewController *;\nauto nsButton(const std::string &s, id target, SEL action) -> NSButton *;\nvoid addAutolayoutEnabledSubview(NSView *parent, NSView *child);\nauto subjectWindow() -> NSWindow *;\n}\n\n#endif" (#ifndef) "#ifndef" (identifier) "AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_" (preproc_def) "#define AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_\n" (#define) "#define" (identifier) "AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_" (preproc_call) "#import <AppKit/AppKit.h>\n" (preproc_directive) "#import" (preproc_arg) "<AppKit/AppKit.h>" (preproc_include) "#include <string>\n" (#include) "#include" (system_lib_string) "<string>" (ERROR) "@" (ERROR) "@" (function_definition) "interface ResizesToContentsViewController : NSTabViewController\n@end\n\nnamespace av_speech_in_noise {\nauto nsTabViewControllerWithoutTabControl() -> NSTabViewController *;\nauto nsButton(const std::string &s, id target, SEL action) -> NSButton *;\nvoid addAutolayoutEnabledSubview(NSView *parent, NSView *child);\nauto subjectWindow() -> NSWindow *;\n}" (type_identifier) "interface" (ERROR) "ResizesToContentsViewController : NSTabViewController\n@end\n\nnamespace" (identifier) "ResizesToContentsViewController" (:) ":" (identifier) "NSTabViewController" (ERROR) "@" (identifier) "end" (identifier) "namespace" (identifier) "av_speech_in_noise" (compound_statement) "{\nauto nsTabViewControllerWithoutTabControl() -> NSTabViewController *;\nauto nsButton(const std::string &s, id target, SEL action) -> NSButton *;\nvoid addAutolayoutEnabledSubview(NSView *parent, NSView *child);\nauto subjectWindow() -> NSWindow *;\n}" ({) "{" (ERROR) "auto nsTabViewControllerWithoutTabControl() -> NSTabViewController *;\nauto nsButton(const std::string &s, id target, SEL action) -> NSButton *;\nvoid addAutolayoutEnabledSubview(NSView *parent, NSView *child);\nauto subjectWindow() -> NSWindow *;" (storage_class_specifier) "auto" (auto) "auto" (identifier) "nsTabViewControllerWithoutTabControl" (() "(" (ERROR) ") -> NSTabViewController *;\nauto nsButton(const std::string &s, id target, SEL action) -> NSButton *;\nvoid addAutolayoutEnabledSubview(NSView *parent, NSView *child);\nauto subjectWindow() ->" ()) ")" (->) "->" (type_descriptor) "NSTabViewController *" (type_identifier) "NSTabViewController" (abstract_pointer_declarator) "*" (*) "*" (;) ";" (auto) "auto" (macro_type_specifier) "nsButton(const std::string &s, id target, SEL action)" (identifier) "nsButton" (() "(" (ERROR) "const std::string &s, id target, SEL" (type_descriptor) "const std" (type_qualifier) "const" (const) "const" (type_identifier) "std" (:) ":" (:) ":" (identifier) "string" (&) "&" (identifier) "s" (,) "," (identifier) "id" (identifier) "target" (,) "," (identifier) "SEL" (type_descriptor) "action" (type_identifier) "action" ()) ")" (->) "->" (type_descriptor) "NSButton *" (type_identifier) "NSButton" (abstract_pointer_declarator) "*" (*) "*" (;) ";" (primitive_type) "void" (type_descriptor) "addAutolayoutEnabledSubview(NSView *parent, NSView *child)" (type_identifier) "addAutolayoutEnabledSubview" (abstract_function_declarator) "(NSView *parent, NSView *child)" (parameter_list) "(NSView *parent, NSView *child)" (() "(" (parameter_declaration) "NSView *parent" (type_identifier) "NSView" (pointer_declarator) "*parent" (*) "*" (identifier) "parent" (,) "," (parameter_declaration) "NSView *child" (type_identifier) "NSView" (pointer_declarator) "*child" (*) "*" (identifier) "child" ()) ")" (;) ";" (auto) "auto" (type_descriptor) "subjectWindow()" (type_identifier) "subjectWindow" (abstract_function_declarator) "()" (parameter_list) "()" (() "(" ()) ")" (->) "->" (type_descriptor) "NSWindow *" (type_identifier) "NSWindow" (abstract_pointer_declarator) "*" (*) "*" (;) ";" (}) "}" (#endif) "#endif"
102
7
{"language": "c", "success": true, "metadata": {"lines": 13, "avg_line_length": 37.54, "nodes": 73, "errors": 0, "source_hash": "714b06497871302704684dba9e1edb5e60e5e5c8f3fb7144cf5831f3efa65ba7", "categorized_nodes": 39}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_\n#define AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_\n\n#import <AppKit/AppKit.h>\n\n#include <string>\n\n@interface ResizesToContentsViewController : NSTabViewController\n@end\n\nnamespace av_speech_in_noise {\nauto nsTabViewControllerWithoutTabControl() -> NSTabViewController *;\nauto nsButton(const std::string &s, id target, SEL action) -> NSButton *;\nvoid addAutolayoutEnabledSubview(NSView *parent, NSView *child);\nauto subjectWindow() -> NSWindow *;\n}\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 14, 72], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 17, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "identifier", "text": "AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 50}}, {"id": 3, "type": "preproc_def", "text": "#define AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_\n", "parent": 0, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 5, "type": "identifier", "text": "AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_", "parent": 3, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 50}}, {"id": 6, "type": "preproc_call", "text": "#import <AppKit/AppKit.h>\n", "parent": 0, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 7, "type": "preproc_directive", "text": "#import", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 7}}, {"id": 8, "type": "preproc_arg", "text": "<AppKit/AppKit.h>", "parent": 6, "children": [], "start_point": {"row": 3, "column": 8}, "end_point": {"row": 3, "column": 25}}, {"id": 9, "type": "preproc_include", "text": "#include <string>\n", "parent": 0, "children": [10, 11], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<string>", "parent": 9, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 17}}, {"id": 12, "type": "ERROR", "text": "@", "parent": 0, "children": [13], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 1}}, {"id": 13, "type": "ERROR", "text": "@", "parent": 12, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 1}}, {"id": 14, "type": "function_definition", "text": "interface ResizesToContentsViewController : NSTabViewController\n@end\n\nnamespace av_speech_in_noise {\nauto nsTabViewControllerWithoutTabControl() -> NSTabViewController *;\nauto nsButton(const std::string &s, id target, SEL action) -> NSButton *;\nvoid addAutolayoutEnabledSubview(NSView *parent, NSView *child);\nauto subjectWindow() -> NSWindow *;\n}", "parent": 0, "children": [15, 16, 21], "start_point": {"row": 7, "column": 1}, "end_point": {"row": 15, "column": 1}}, {"id": 15, "type": "type_identifier", "text": "interface", "parent": 14, "children": [], "start_point": {"row": 7, "column": 1}, "end_point": {"row": 7, "column": 10}}, {"id": 16, "type": "ERROR", "text": "ResizesToContentsViewController : NSTabViewController\n@end\n\nnamespace", "parent": 14, "children": [17, 18, 19, 20], "start_point": {"row": 7, "column": 11}, "end_point": {"row": 10, "column": 9}}, {"id": 17, "type": "identifier", "text": "ResizesToContentsViewController", "parent": 16, "children": [], "start_point": {"row": 7, "column": 11}, "end_point": {"row": 7, "column": 42}}, {"id": 18, "type": "identifier", "text": "NSTabViewController", "parent": 16, "children": [], "start_point": {"row": 7, "column": 45}, "end_point": {"row": 7, "column": 64}}, {"id": 19, "type": "ERROR", "text": "@", "parent": 16, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 1}}, {"id": 20, "type": "identifier", "text": "namespace", "parent": 16, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 9}}, {"id": 21, "type": "identifier", "text": "av_speech_in_noise", "parent": 14, "children": [], "start_point": {"row": 10, "column": 10}, "end_point": {"row": 10, "column": 28}}, {"id": 22, "type": "ERROR", "text": "auto nsTabViewControllerWithoutTabControl() -> NSTabViewController *;\nauto nsButton(const std::string &s, id target, SEL action) -> NSButton *;\nvoid addAutolayoutEnabledSubview(NSView *parent, NSView *child);\nauto subjectWindow() -> NSWindow *;", "parent": 14, "children": [23, 25, 26, 68], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 14, "column": 35}}, {"id": 23, "type": "storage_class_specifier", "text": "auto", "parent": 22, "children": [24], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 4}}, {"id": 24, "type": "auto", "text": "auto", "parent": 23, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 4}}, {"id": 25, "type": "identifier", "text": "nsTabViewControllerWithoutTabControl", "parent": 22, "children": [], "start_point": {"row": 11, "column": 5}, "end_point": {"row": 11, "column": 41}}, {"id": 26, "type": "ERROR", "text": ") -> NSTabViewController *;\nauto nsButton(const std::string &s, id target, SEL action) -> NSButton *;\nvoid addAutolayoutEnabledSubview(NSView *parent, NSView *child);\nauto subjectWindow() ->", "parent": 22, "children": [27, 31, 32, 44, 48, 49, 63, 64], "start_point": {"row": 11, "column": 42}, "end_point": {"row": 14, "column": 23}}, {"id": 27, "type": "type_descriptor", "text": "NSTabViewController *", "parent": 26, "children": [28, 29], "start_point": {"row": 11, "column": 47}, "end_point": {"row": 11, "column": 68}}, {"id": 28, "type": "type_identifier", "text": "NSTabViewController", "parent": 27, "children": [], "start_point": {"row": 11, "column": 47}, "end_point": {"row": 11, "column": 66}}, {"id": 29, "type": "abstract_pointer_declarator", "text": "*", "parent": 27, "children": [30], "start_point": {"row": 11, "column": 67}, "end_point": {"row": 11, "column": 68}}, {"id": 30, "type": "*", "text": "*", "parent": 29, "children": [], "start_point": {"row": 11, "column": 67}, "end_point": {"row": 11, "column": 68}}, {"id": 31, "type": "auto", "text": "auto", "parent": 26, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 4}}, {"id": 32, "type": "macro_type_specifier", "text": "nsButton(const std::string &s, id target, SEL action)", "parent": 26, "children": [33, 34, 42], "start_point": {"row": 12, "column": 5}, "end_point": {"row": 12, "column": 58}}, {"id": 33, "type": "identifier", "text": "nsButton", "parent": 32, "children": [], "start_point": {"row": 12, "column": 5}, "end_point": {"row": 12, "column": 13}}, {"id": 34, "type": "ERROR", "text": "const std::string &s, id target, SEL", "parent": 32, "children": [35, 37, 38, 39, 40, 41], "start_point": {"row": 12, "column": 14}, "end_point": {"row": 12, "column": 50}}, {"id": 35, "type": "type_descriptor", "text": "const std", "parent": 34, "children": [36], "start_point": {"row": 12, "column": 14}, "end_point": {"row": 12, "column": 23}}, {"id": 36, "type": "type_identifier", "text": "std", "parent": 35, "children": [], "start_point": {"row": 12, "column": 20}, "end_point": {"row": 12, "column": 23}}, {"id": 37, "type": "identifier", "text": "string", "parent": 34, "children": [], "start_point": {"row": 12, "column": 25}, "end_point": {"row": 12, "column": 31}}, {"id": 38, "type": "identifier", "text": "s", "parent": 34, "children": [], "start_point": {"row": 12, "column": 33}, "end_point": {"row": 12, "column": 34}}, {"id": 39, "type": "identifier", "text": "id", "parent": 34, "children": [], "start_point": {"row": 12, "column": 36}, "end_point": {"row": 12, "column": 38}}, {"id": 40, "type": "identifier", "text": "target", "parent": 34, "children": [], "start_point": {"row": 12, "column": 39}, "end_point": {"row": 12, "column": 45}}, {"id": 41, "type": "identifier", "text": "SEL", "parent": 34, "children": [], "start_point": {"row": 12, "column": 47}, "end_point": {"row": 12, "column": 50}}, {"id": 42, "type": "type_descriptor", "text": "action", "parent": 32, "children": [43], "start_point": {"row": 12, "column": 51}, "end_point": {"row": 12, "column": 57}}, {"id": 43, "type": "type_identifier", "text": "action", "parent": 42, "children": [], "start_point": {"row": 12, "column": 51}, "end_point": {"row": 12, "column": 57}}, {"id": 44, "type": "type_descriptor", "text": "NSButton *", "parent": 26, "children": [45, 46], "start_point": {"row": 12, "column": 62}, "end_point": {"row": 12, "column": 72}}, {"id": 45, "type": "type_identifier", "text": "NSButton", "parent": 44, "children": [], "start_point": {"row": 12, "column": 62}, "end_point": {"row": 12, "column": 70}}, {"id": 46, "type": "abstract_pointer_declarator", "text": "*", "parent": 44, "children": [47], "start_point": {"row": 12, "column": 71}, "end_point": {"row": 12, "column": 72}}, {"id": 47, "type": "*", "text": "*", "parent": 46, "children": [], "start_point": {"row": 12, "column": 71}, "end_point": {"row": 12, "column": 72}}, {"id": 48, "type": "primitive_type", "text": "void", "parent": 26, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 4}}, {"id": 49, "type": "type_descriptor", "text": "addAutolayoutEnabledSubview(NSView *parent, NSView *child)", "parent": 26, "children": [50, 51], "start_point": {"row": 13, "column": 5}, "end_point": {"row": 13, "column": 63}}, {"id": 50, "type": "type_identifier", "text": "addAutolayoutEnabledSubview", "parent": 49, "children": [], "start_point": {"row": 13, "column": 5}, "end_point": {"row": 13, "column": 32}}, {"id": 51, "type": "abstract_function_declarator", "text": "(NSView *parent, NSView *child)", "parent": 49, "children": [52], "start_point": {"row": 13, "column": 32}, "end_point": {"row": 13, "column": 63}}, {"id": 52, "type": "parameter_list", "text": "(NSView *parent, NSView *child)", "parent": 51, "children": [53, 58], "start_point": {"row": 13, "column": 32}, "end_point": {"row": 13, "column": 63}}, {"id": 53, "type": "parameter_declaration", "text": "NSView *parent", "parent": 52, "children": [54, 55], "start_point": {"row": 13, "column": 33}, "end_point": {"row": 13, "column": 47}}, {"id": 54, "type": "type_identifier", "text": "NSView", "parent": 53, "children": [], "start_point": {"row": 13, "column": 33}, "end_point": {"row": 13, "column": 39}}, {"id": 55, "type": "pointer_declarator", "text": "*parent", "parent": 53, "children": [56, 57], "start_point": {"row": 13, "column": 40}, "end_point": {"row": 13, "column": 47}}, {"id": 56, "type": "*", "text": "*", "parent": 55, "children": [], "start_point": {"row": 13, "column": 40}, "end_point": {"row": 13, "column": 41}}, {"id": 57, "type": "identifier", "text": "parent", "parent": 55, "children": [], "start_point": {"row": 13, "column": 41}, "end_point": {"row": 13, "column": 47}}, {"id": 58, "type": "parameter_declaration", "text": "NSView *child", "parent": 52, "children": [59, 60], "start_point": {"row": 13, "column": 49}, "end_point": {"row": 13, "column": 62}}, {"id": 59, "type": "type_identifier", "text": "NSView", "parent": 58, "children": [], "start_point": {"row": 13, "column": 49}, "end_point": {"row": 13, "column": 55}}, {"id": 60, "type": "pointer_declarator", "text": "*child", "parent": 58, "children": [61, 62], "start_point": {"row": 13, "column": 56}, "end_point": {"row": 13, "column": 62}}, {"id": 61, "type": "*", "text": "*", "parent": 60, "children": [], "start_point": {"row": 13, "column": 56}, "end_point": {"row": 13, "column": 57}}, {"id": 62, "type": "identifier", "text": "child", "parent": 60, "children": [], "start_point": {"row": 13, "column": 57}, "end_point": {"row": 13, "column": 62}}, {"id": 63, "type": "auto", "text": "auto", "parent": 26, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 4}}, {"id": 64, "type": "type_descriptor", "text": "subjectWindow()", "parent": 26, "children": [65, 66], "start_point": {"row": 14, "column": 5}, "end_point": {"row": 14, "column": 20}}, {"id": 65, "type": "type_identifier", "text": "subjectWindow", "parent": 64, "children": [], "start_point": {"row": 14, "column": 5}, "end_point": {"row": 14, "column": 18}}, {"id": 66, "type": "abstract_function_declarator", "text": "()", "parent": 64, "children": [67], "start_point": {"row": 14, "column": 18}, "end_point": {"row": 14, "column": 20}}, {"id": 67, "type": "parameter_list", "text": "()", "parent": 66, "children": [], "start_point": {"row": 14, "column": 18}, "end_point": {"row": 14, "column": 20}}, {"id": 68, "type": "type_descriptor", "text": "NSWindow *", "parent": 22, "children": [69, 70], "start_point": {"row": 14, "column": 24}, "end_point": {"row": 14, "column": 34}}, {"id": 69, "type": "type_identifier", "text": "NSWindow", "parent": 68, "children": [], "start_point": {"row": 14, "column": 24}, "end_point": {"row": 14, "column": 32}}, {"id": 70, "type": "abstract_pointer_declarator", "text": "*", "parent": 68, "children": [71], "start_point": {"row": 14, "column": 33}, "end_point": {"row": 14, "column": 34}}, {"id": 71, "type": "*", "text": "*", "parent": 70, "children": [], "start_point": {"row": 14, "column": 33}, "end_point": {"row": 14, "column": 34}}, {"id": 72, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 6}}]}, "node_categories": {"declarations": {"functions": [14, 51, 66], "variables": [53, 58], "classes": [23], "imports": [9, 10], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 15, 17, 18, 20, 21, 25, 28, 32, 33, 36, 37, 38, 39, 40, 41, 43, 45, 50, 54, 57, 59, 62, 65, 69, 72], "returns": [], "exceptions": []}, "expressions": {"calls": [6], "literals": [11], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 14, "universal_type": "function", "name": "ResizesToContentsViewController", "text_snippet": "interface ResizesToContentsViewController : NSTabViewController\n@end\n\nnamespace av_speech_in_noise {"}, {"node_id": 51, "universal_type": "function", "name": "unknown", "text_snippet": "(NSView *parent, NSView *child)"}, {"node_id": 66, "universal_type": "function", "name": "unknown", "text_snippet": "()"}], "class_declarations": [{"node_id": 23, "universal_type": "class", "name": "unknown", "text_snippet": "auto"}], "import_statements": [{"node_id": 9, "text": "#include <string>\n"}, {"node_id": 10, "text": "#include"}]}, "original_source_code": "#ifndef AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_\n#define AV_SPEECH_IN_NOISE_MACOS_APPKIT_UTILITY_H_\n\n#import <AppKit/AppKit.h>\n\n#include <string>\n\n@interface ResizesToContentsViewController : NSTabViewController\n@end\n\nnamespace av_speech_in_noise {\nauto nsTabViewControllerWithoutTabControl() -> NSTabViewController *;\nauto nsButton(const std::string &s, id target, SEL action) -> NSButton *;\nvoid addAutolayoutEnabledSubview(NSView *parent, NSView *child);\nauto subjectWindow() -> NSWindow *;\n}\n\n#endif\n"}
80,581
c
#include "config.h" #include "ui.h" static Config watch_config; void config_init() { watch_config.lowbat = false; watch_config.btdisco = false; } bool get_lowbat_notification() { return watch_config.lowbat; } bool get_btdisco_notification() { return watch_config.btdisco; } void set_lowbat_notification(bool state) { watch_config.lowbat = state; if (state) { battery_state_service_subscribe(battery_state_handler); } else { battery_state_service_unsubscribe(); lowbattery_handler(false); } } void set_btdisco_notification(bool state) { watch_config.btdisco = state; if (state) { bluetooth_connection_service_subscribe(bluetooth_connection_handler); } else { bluetooth_connection_service_unsubscribe(); } }
24
30
(translation_unit) "#include "config.h"\n#include "ui.h"\n\nstatic Config watch_config;\n\nvoid config_init() {\n watch_config.lowbat = false;\n watch_config.btdisco = false;\n}\n\nbool get_lowbat_notification() {\n return watch_config.lowbat;\n}\n\nbool get_btdisco_notification() {\n return watch_config.btdisco;\n}\n\nvoid set_lowbat_notification(bool state) {\n watch_config.lowbat = state;\n if (state) {\n battery_state_service_subscribe(battery_state_handler);\n } else {\n battery_state_service_unsubscribe();\n lowbattery_handler(false);\n }\n}\n\nvoid set_btdisco_notification(bool state) {\n watch_config.btdisco = state;\n if (state) {\n bluetooth_connection_service_subscribe(bluetooth_connection_handler);\n } else {\n bluetooth_connection_service_unsubscribe();\n }\n}\n" (preproc_include) "#include "config.h"\n" (#include) "#include" (string_literal) ""config.h"" (") """ (string_content) "config.h" (") """ (preproc_include) "#include "ui.h"\n" (#include) "#include" (string_literal) ""ui.h"" (") """ (string_content) "ui.h" (") """ (declaration) "static Config watch_config;" (storage_class_specifier) "static" (static) "static" (type_identifier) "Config" (identifier) "watch_config" (;) ";" (function_definition) "void config_init() {\n watch_config.lowbat = false;\n watch_config.btdisco = false;\n}" (primitive_type) "void" (function_declarator) "config_init()" (identifier) "config_init" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n watch_config.lowbat = false;\n watch_config.btdisco = false;\n}" ({) "{" (expression_statement) "watch_config.lowbat = false;" (assignment_expression) "watch_config.lowbat = false" (field_expression) "watch_config.lowbat" (identifier) "watch_config" (.) "." (field_identifier) "lowbat" (=) "=" (false) "false" (;) ";" (expression_statement) "watch_config.btdisco = false;" (assignment_expression) "watch_config.btdisco = false" (field_expression) "watch_config.btdisco" (identifier) "watch_config" (.) "." (field_identifier) "btdisco" (=) "=" (false) "false" (;) ";" (}) "}" (function_definition) "bool get_lowbat_notification() {\n return watch_config.lowbat;\n}" (primitive_type) "bool" (function_declarator) "get_lowbat_notification()" (identifier) "get_lowbat_notification" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n return watch_config.lowbat;\n}" ({) "{" (return_statement) "return watch_config.lowbat;" (return) "return" (field_expression) "watch_config.lowbat" (identifier) "watch_config" (.) "." (field_identifier) "lowbat" (;) ";" (}) "}" (function_definition) "bool get_btdisco_notification() {\n return watch_config.btdisco;\n}" (primitive_type) "bool" (function_declarator) "get_btdisco_notification()" (identifier) "get_btdisco_notification" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n return watch_config.btdisco;\n}" ({) "{" (return_statement) "return watch_config.btdisco;" (return) "return" (field_expression) "watch_config.btdisco" (identifier) "watch_config" (.) "." (field_identifier) "btdisco" (;) ";" (}) "}" (function_definition) "void set_lowbat_notification(bool state) {\n watch_config.lowbat = state;\n if (state) {\n battery_state_service_subscribe(battery_state_handler);\n } else {\n battery_state_service_unsubscribe();\n lowbattery_handler(false);\n }\n}" (primitive_type) "void" (function_declarator) "set_lowbat_notification(bool state)" (identifier) "set_lowbat_notification" (parameter_list) "(bool state)" (() "(" (parameter_declaration) "bool state" (primitive_type) "bool" (identifier) "state" ()) ")" (compound_statement) "{\n watch_config.lowbat = state;\n if (state) {\n battery_state_service_subscribe(battery_state_handler);\n } else {\n battery_state_service_unsubscribe();\n lowbattery_handler(false);\n }\n}" ({) "{" (expression_statement) "watch_config.lowbat = state;" (assignment_expression) "watch_config.lowbat = state" (field_expression) "watch_config.lowbat" (identifier) "watch_config" (.) "." (field_identifier) "lowbat" (=) "=" (identifier) "state" (;) ";" (if_statement) "if (state) {\n battery_state_service_subscribe(battery_state_handler);\n } else {\n battery_state_service_unsubscribe();\n lowbattery_handler(false);\n }" (if) "if" (parenthesized_expression) "(state)" (() "(" (identifier) "state" ()) ")" (compound_statement) "{\n battery_state_service_subscribe(battery_state_handler);\n }" ({) "{" (expression_statement) "battery_state_service_subscribe(battery_state_handler);" (call_expression) "battery_state_service_subscribe(battery_state_handler)" (identifier) "battery_state_service_subscribe" (argument_list) "(battery_state_handler)" (() "(" (identifier) "battery_state_handler" ()) ")" (;) ";" (}) "}" (else_clause) "else {\n battery_state_service_unsubscribe();\n lowbattery_handler(false);\n }" (else) "else" (compound_statement) "{\n battery_state_service_unsubscribe();\n lowbattery_handler(false);\n }" ({) "{" (expression_statement) "battery_state_service_unsubscribe();" (call_expression) "battery_state_service_unsubscribe()" (identifier) "battery_state_service_unsubscribe" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "lowbattery_handler(false);" (call_expression) "lowbattery_handler(false)" (identifier) "lowbattery_handler" (argument_list) "(false)" (() "(" (false) "false" ()) ")" (;) ";" (}) "}" (}) "}" (function_definition) "void set_btdisco_notification(bool state) {\n watch_config.btdisco = state;\n if (state) {\n bluetooth_connection_service_subscribe(bluetooth_connection_handler);\n } else {\n bluetooth_connection_service_unsubscribe();\n }\n}" (primitive_type) "void" (function_declarator) "set_btdisco_notification(bool state)" (identifier) "set_btdisco_notification" (parameter_list) "(bool state)" (() "(" (parameter_declaration) "bool state" (primitive_type) "bool" (identifier) "state" ()) ")" (compound_statement) "{\n watch_config.btdisco = state;\n if (state) {\n bluetooth_connection_service_subscribe(bluetooth_connection_handler);\n } else {\n bluetooth_connection_service_unsubscribe();\n }\n}" ({) "{" (expression_statement) "watch_config.btdisco = state;" (assignment_expression) "watch_config.btdisco = state" (field_expression) "watch_config.btdisco" (identifier) "watch_config" (.) "." (field_identifier) "btdisco" (=) "=" (identifier) "state" (;) ";" (if_statement) "if (state) {\n bluetooth_connection_service_subscribe(bluetooth_connection_handler);\n } else {\n bluetooth_connection_service_unsubscribe();\n }" (if) "if" (parenthesized_expression) "(state)" (() "(" (identifier) "state" ()) ")" (compound_statement) "{\n bluetooth_connection_service_subscribe(bluetooth_connection_handler);\n }" ({) "{" (expression_statement) "bluetooth_connection_service_subscribe(bluetooth_connection_handler);" (call_expression) "bluetooth_connection_service_subscribe(bluetooth_connection_handler)" (identifier) "bluetooth_connection_service_subscribe" (argument_list) "(bluetooth_connection_handler)" (() "(" (identifier) "bluetooth_connection_handler" ()) ")" (;) ";" (}) "}" (else_clause) "else {\n bluetooth_connection_service_unsubscribe();\n }" (else) "else" (compound_statement) "{\n bluetooth_connection_service_unsubscribe();\n }" ({) "{" (expression_statement) "bluetooth_connection_service_unsubscribe();" (call_expression) "bluetooth_connection_service_unsubscribe()" (identifier) "bluetooth_connection_service_unsubscribe" (argument_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (}) "}"
191
0
{"language": "c", "success": true, "metadata": {"lines": 30, "avg_line_length": 24.0, "nodes": 98, "errors": 0, "source_hash": "65ffda09dd33478f6978bad9f1d13414472e042bf7da449d19f8e1fbb3d18195", "categorized_nodes": 72}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"config.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"config.h\"", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 19}}, {"id": 3, "type": "preproc_include", "text": "#include \"ui.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 8}}, {"id": 5, "type": "string_literal", "text": "\"ui.h\"", "parent": 3, "children": [], "start_point": {"row": 1, "column": 9}, "end_point": {"row": 1, "column": 15}}, {"id": 6, "type": "declaration", "text": "static Config watch_config;", "parent": null, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 27}}, {"id": 7, "type": "type_identifier", "text": "Config", "parent": 6, "children": [], "start_point": {"row": 3, "column": 7}, "end_point": {"row": 3, "column": 13}}, {"id": 8, "type": "identifier", "text": "watch_config", "parent": 6, "children": [], "start_point": {"row": 3, "column": 14}, "end_point": {"row": 3, "column": 26}}, {"id": 9, "type": "function_definition", "text": "void config_init() {\n watch_config.lowbat = false;\n watch_config.btdisco = false;\n}", "parent": null, "children": [10, 11], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 8, "column": 1}}, {"id": 10, "type": "primitive_type", "text": "void", "parent": 9, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 4}}, {"id": 11, "type": "function_declarator", "text": "config_init()", "parent": 9, "children": [12, 13], "start_point": {"row": 5, "column": 5}, "end_point": {"row": 5, "column": 18}}, {"id": 12, "type": "identifier", "text": "config_init", "parent": 11, "children": [], "start_point": {"row": 5, "column": 5}, "end_point": {"row": 5, "column": 16}}, {"id": 13, "type": "parameter_list", "text": "()", "parent": 11, "children": [], "start_point": {"row": 5, "column": 16}, "end_point": {"row": 5, "column": 18}}, {"id": 14, "type": "assignment_expression", "text": "watch_config.lowbat = false", "parent": 9, "children": [15, 18, 19], "start_point": {"row": 6, "column": 2}, "end_point": {"row": 6, "column": 29}}, {"id": 15, "type": "field_expression", "text": "watch_config.lowbat", "parent": 14, "children": [16, 17], "start_point": {"row": 6, "column": 2}, "end_point": {"row": 6, "column": 21}}, {"id": 16, "type": "identifier", "text": "watch_config", "parent": 15, "children": [], "start_point": {"row": 6, "column": 2}, "end_point": {"row": 6, "column": 14}}, {"id": 17, "type": "field_identifier", "text": "lowbat", "parent": 15, "children": [], "start_point": {"row": 6, "column": 15}, "end_point": {"row": 6, "column": 21}}, {"id": 18, "type": "=", "text": "=", "parent": 14, "children": [], "start_point": {"row": 6, "column": 22}, "end_point": {"row": 6, "column": 23}}, {"id": 19, "type": "false", "text": "false", "parent": 14, "children": [], "start_point": {"row": 6, "column": 24}, "end_point": {"row": 6, "column": 29}}, {"id": 20, "type": "assignment_expression", "text": "watch_config.btdisco = false", "parent": 9, "children": [21, 24, 25], "start_point": {"row": 7, "column": 2}, "end_point": {"row": 7, "column": 30}}, {"id": 21, "type": "field_expression", "text": "watch_config.btdisco", "parent": 20, "children": [22, 23], "start_point": {"row": 7, "column": 2}, "end_point": {"row": 7, "column": 22}}, {"id": 22, "type": "identifier", "text": "watch_config", "parent": 21, "children": [], "start_point": {"row": 7, "column": 2}, "end_point": {"row": 7, "column": 14}}, {"id": 23, "type": "field_identifier", "text": "btdisco", "parent": 21, "children": [], "start_point": {"row": 7, "column": 15}, "end_point": {"row": 7, "column": 22}}, {"id": 24, "type": "=", "text": "=", "parent": 20, "children": [], "start_point": {"row": 7, "column": 23}, "end_point": {"row": 7, "column": 24}}, {"id": 25, "type": "false", "text": "false", "parent": 20, "children": [], "start_point": {"row": 7, "column": 25}, "end_point": {"row": 7, "column": 30}}, {"id": 26, "type": "function_definition", "text": "bool get_lowbat_notification() {\n return watch_config.lowbat;\n}", "parent": null, "children": [27, 28], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 12, "column": 1}}, {"id": 27, "type": "primitive_type", "text": "bool", "parent": 26, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 4}}, {"id": 28, "type": "function_declarator", "text": "get_lowbat_notification()", "parent": 26, "children": [29, 30], "start_point": {"row": 10, "column": 5}, "end_point": {"row": 10, "column": 30}}, {"id": 29, "type": "identifier", "text": "get_lowbat_notification", "parent": 28, "children": [], "start_point": {"row": 10, "column": 5}, "end_point": {"row": 10, "column": 28}}, {"id": 30, "type": "parameter_list", "text": "()", "parent": 28, "children": [], "start_point": {"row": 10, "column": 28}, "end_point": {"row": 10, "column": 30}}, {"id": 31, "type": "return_statement", "text": "return watch_config.lowbat;", "parent": 26, "children": [32], "start_point": {"row": 11, "column": 2}, "end_point": {"row": 11, "column": 29}}, {"id": 32, "type": "field_expression", "text": "watch_config.lowbat", "parent": 31, "children": [33, 34], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 28}}, {"id": 33, "type": "identifier", "text": "watch_config", "parent": 32, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 21}}, {"id": 34, "type": "field_identifier", "text": "lowbat", "parent": 32, "children": [], "start_point": {"row": 11, "column": 22}, "end_point": {"row": 11, "column": 28}}, {"id": 35, "type": "function_definition", "text": "bool get_btdisco_notification() {\n return watch_config.btdisco;\n}", "parent": null, "children": [36, 37], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 16, "column": 1}}, {"id": 36, "type": "primitive_type", "text": "bool", "parent": 35, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 4}}, {"id": 37, "type": "function_declarator", "text": "get_btdisco_notification()", "parent": 35, "children": [38, 39], "start_point": {"row": 14, "column": 5}, "end_point": {"row": 14, "column": 31}}, {"id": 38, "type": "identifier", "text": "get_btdisco_notification", "parent": 37, "children": [], "start_point": {"row": 14, "column": 5}, "end_point": {"row": 14, "column": 29}}, {"id": 39, "type": "parameter_list", "text": "()", "parent": 37, "children": [], "start_point": {"row": 14, "column": 29}, "end_point": {"row": 14, "column": 31}}, {"id": 40, "type": "return_statement", "text": "return watch_config.btdisco;", "parent": 35, "children": [41], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 30}}, {"id": 41, "type": "field_expression", "text": "watch_config.btdisco", "parent": 40, "children": [42, 43], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 29}}, {"id": 42, "type": "identifier", "text": "watch_config", "parent": 41, "children": [], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 21}}, {"id": 43, "type": "field_identifier", "text": "btdisco", "parent": 41, "children": [], "start_point": {"row": 15, "column": 22}, "end_point": {"row": 15, "column": 29}}, {"id": 44, "type": "function_definition", "text": "void set_lowbat_notification(bool state) {\n watch_config.lowbat = state;\n if (state) {\n battery_state_service_subscribe(battery_state_handler);\n } else {\n battery_state_service_unsubscribe();\n lowbattery_handler(false);\n }\n}", "parent": null, "children": [45, 46], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 26, "column": 1}}, {"id": 45, "type": "primitive_type", "text": "void", "parent": 44, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 4}}, {"id": 46, "type": "function_declarator", "text": "set_lowbat_notification(bool state)", "parent": 44, "children": [47, 48], "start_point": {"row": 18, "column": 5}, "end_point": {"row": 18, "column": 40}}, {"id": 47, "type": "identifier", "text": "set_lowbat_notification", "parent": 46, "children": [], "start_point": {"row": 18, "column": 5}, "end_point": {"row": 18, "column": 28}}, {"id": 48, "type": "parameter_list", "text": "(bool state)", "parent": 46, "children": [49], "start_point": {"row": 18, "column": 28}, "end_point": {"row": 18, "column": 40}}, {"id": 49, "type": "parameter_declaration", "text": "bool state", "parent": 48, "children": [50, 51], "start_point": {"row": 18, "column": 29}, "end_point": {"row": 18, "column": 39}}, {"id": 50, "type": "primitive_type", "text": "bool", "parent": 49, "children": [], "start_point": {"row": 18, "column": 29}, "end_point": {"row": 18, "column": 33}}, {"id": 51, "type": "identifier", "text": "state", "parent": 49, "children": [], "start_point": {"row": 18, "column": 34}, "end_point": {"row": 18, "column": 39}}, {"id": 52, "type": "assignment_expression", "text": "watch_config.lowbat = state", "parent": 44, "children": [53, 56, 57], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 29}}, {"id": 53, "type": "field_expression", "text": "watch_config.lowbat", "parent": 52, "children": [54, 55], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 21}}, {"id": 54, "type": "identifier", "text": "watch_config", "parent": 53, "children": [], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 14}}, {"id": 55, "type": "field_identifier", "text": "lowbat", "parent": 53, "children": [], "start_point": {"row": 19, "column": 15}, "end_point": {"row": 19, "column": 21}}, {"id": 56, "type": "=", "text": "=", "parent": 52, "children": [], "start_point": {"row": 19, "column": 22}, "end_point": {"row": 19, "column": 23}}, {"id": 57, "type": "identifier", "text": "state", "parent": 52, "children": [], "start_point": {"row": 19, "column": 24}, "end_point": {"row": 19, "column": 29}}, {"id": 58, "type": "if_statement", "text": "if (state) {\n battery_state_service_subscribe(battery_state_handler);\n } else {\n battery_state_service_unsubscribe();\n lowbattery_handler(false);\n }", "parent": 44, "children": [59, 65], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 25, "column": 3}}, {"id": 59, "type": "parenthesized_expression", "text": "(state)", "parent": 58, "children": [60], "start_point": {"row": 20, "column": 5}, "end_point": {"row": 20, "column": 12}}, {"id": 60, "type": "identifier", "text": "state", "parent": 59, "children": [], "start_point": {"row": 20, "column": 6}, "end_point": {"row": 20, "column": 11}}, {"id": 61, "type": "call_expression", "text": "battery_state_service_subscribe(battery_state_handler)", "parent": 58, "children": [62, 63], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 21, "column": 58}}, {"id": 62, "type": "identifier", "text": "battery_state_service_subscribe", "parent": 61, "children": [], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 21, "column": 35}}, {"id": 63, "type": "argument_list", "text": "(battery_state_handler)", "parent": 61, "children": [64], "start_point": {"row": 21, "column": 35}, "end_point": {"row": 21, "column": 58}}, {"id": 64, "type": "identifier", "text": "battery_state_handler", "parent": 63, "children": [], "start_point": {"row": 21, "column": 36}, "end_point": {"row": 21, "column": 57}}, {"id": 65, "type": "else_clause", "text": "else {\n battery_state_service_unsubscribe();\n lowbattery_handler(false);\n }", "parent": 58, "children": [], "start_point": {"row": 22, "column": 4}, "end_point": {"row": 25, "column": 3}}, {"id": 66, "type": "call_expression", "text": "battery_state_service_unsubscribe()", "parent": 65, "children": [67, 68], "start_point": {"row": 23, "column": 4}, "end_point": {"row": 23, "column": 39}}, {"id": 67, "type": "identifier", "text": "battery_state_service_unsubscribe", "parent": 66, "children": [], "start_point": {"row": 23, "column": 4}, "end_point": {"row": 23, "column": 37}}, {"id": 68, "type": "argument_list", "text": "()", "parent": 66, "children": [], "start_point": {"row": 23, "column": 37}, "end_point": {"row": 23, "column": 39}}, {"id": 69, "type": "call_expression", "text": "lowbattery_handler(false)", "parent": 65, "children": [70, 71], "start_point": {"row": 24, "column": 4}, "end_point": {"row": 24, "column": 29}}, {"id": 70, "type": "identifier", "text": "lowbattery_handler", "parent": 69, "children": [], "start_point": {"row": 24, "column": 4}, "end_point": {"row": 24, "column": 22}}, {"id": 71, "type": "argument_list", "text": "(false)", "parent": 69, "children": [72], "start_point": {"row": 24, "column": 22}, "end_point": {"row": 24, "column": 29}}, {"id": 72, "type": "false", "text": "false", "parent": 71, "children": [], "start_point": {"row": 24, "column": 23}, "end_point": {"row": 24, "column": 28}}, {"id": 73, "type": "function_definition", "text": "void set_btdisco_notification(bool state) {\n watch_config.btdisco = state;\n if (state) {\n bluetooth_connection_service_subscribe(bluetooth_connection_handler);\n } else {\n bluetooth_connection_service_unsubscribe();\n }\n}", "parent": null, "children": [74, 75], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 35, "column": 1}}, {"id": 74, "type": "primitive_type", "text": "void", "parent": 73, "children": [], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 4}}, {"id": 75, "type": "function_declarator", "text": "set_btdisco_notification(bool state)", "parent": 73, "children": [76, 77], "start_point": {"row": 28, "column": 5}, "end_point": {"row": 28, "column": 41}}, {"id": 76, "type": "identifier", "text": "set_btdisco_notification", "parent": 75, "children": [], "start_point": {"row": 28, "column": 5}, "end_point": {"row": 28, "column": 29}}, {"id": 77, "type": "parameter_list", "text": "(bool state)", "parent": 75, "children": [78], "start_point": {"row": 28, "column": 29}, "end_point": {"row": 28, "column": 41}}, {"id": 78, "type": "parameter_declaration", "text": "bool state", "parent": 77, "children": [79, 80], "start_point": {"row": 28, "column": 30}, "end_point": {"row": 28, "column": 40}}, {"id": 79, "type": "primitive_type", "text": "bool", "parent": 78, "children": [], "start_point": {"row": 28, "column": 30}, "end_point": {"row": 28, "column": 34}}, {"id": 80, "type": "identifier", "text": "state", "parent": 78, "children": [], "start_point": {"row": 28, "column": 35}, "end_point": {"row": 28, "column": 40}}, {"id": 81, "type": "assignment_expression", "text": "watch_config.btdisco = state", "parent": 73, "children": [82, 85, 86], "start_point": {"row": 29, "column": 2}, "end_point": {"row": 29, "column": 30}}, {"id": 82, "type": "field_expression", "text": "watch_config.btdisco", "parent": 81, "children": [83, 84], "start_point": {"row": 29, "column": 2}, "end_point": {"row": 29, "column": 22}}, {"id": 83, "type": "identifier", "text": "watch_config", "parent": 82, "children": [], "start_point": {"row": 29, "column": 2}, "end_point": {"row": 29, "column": 14}}, {"id": 84, "type": "field_identifier", "text": "btdisco", "parent": 82, "children": [], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 22}}, {"id": 85, "type": "=", "text": "=", "parent": 81, "children": [], "start_point": {"row": 29, "column": 23}, "end_point": {"row": 29, "column": 24}}, {"id": 86, "type": "identifier", "text": "state", "parent": 81, "children": [], "start_point": {"row": 29, "column": 25}, "end_point": {"row": 29, "column": 30}}, {"id": 87, "type": "if_statement", "text": "if (state) {\n bluetooth_connection_service_subscribe(bluetooth_connection_handler);\n } else {\n bluetooth_connection_service_unsubscribe();\n }", "parent": 73, "children": [88, 94], "start_point": {"row": 30, "column": 2}, "end_point": {"row": 34, "column": 3}}, {"id": 88, "type": "parenthesized_expression", "text": "(state)", "parent": 87, "children": [89], "start_point": {"row": 30, "column": 5}, "end_point": {"row": 30, "column": 12}}, {"id": 89, "type": "identifier", "text": "state", "parent": 88, "children": [], "start_point": {"row": 30, "column": 6}, "end_point": {"row": 30, "column": 11}}, {"id": 90, "type": "call_expression", "text": "bluetooth_connection_service_subscribe(bluetooth_connection_handler)", "parent": 87, "children": [91, 92], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 72}}, {"id": 91, "type": "identifier", "text": "bluetooth_connection_service_subscribe", "parent": 90, "children": [], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 42}}, {"id": 92, "type": "argument_list", "text": "(bluetooth_connection_handler)", "parent": 90, "children": [93], "start_point": {"row": 31, "column": 42}, "end_point": {"row": 31, "column": 72}}, {"id": 93, "type": "identifier", "text": "bluetooth_connection_handler", "parent": 92, "children": [], "start_point": {"row": 31, "column": 43}, "end_point": {"row": 31, "column": 71}}, {"id": 94, "type": "else_clause", "text": "else {\n bluetooth_connection_service_unsubscribe();\n }", "parent": 87, "children": [], "start_point": {"row": 32, "column": 4}, "end_point": {"row": 34, "column": 3}}, {"id": 95, "type": "call_expression", "text": "bluetooth_connection_service_unsubscribe()", "parent": 94, "children": [96, 97], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 46}}, {"id": 96, "type": "identifier", "text": "bluetooth_connection_service_unsubscribe", "parent": 95, "children": [], "start_point": {"row": 33, "column": 4}, "end_point": {"row": 33, "column": 44}}, {"id": 97, "type": "argument_list", "text": "()", "parent": 95, "children": [], "start_point": {"row": 33, "column": 44}, "end_point": {"row": 33, "column": 46}}]}, "node_categories": {"declarations": {"functions": [9, 11, 26, 28, 35, 37, 44, 46, 73, 75], "variables": [6, 49, 78], "classes": [], "imports": [0, 1, 3, 4], "modules": [], "enums": []}, "statements": {"expressions": [15, 21, 32, 41, 53, 59, 61, 66, 69, 82, 88, 90, 95], "assignments": [14, 20, 52, 81], "loops": [], "conditionals": [7, 8, 12, 16, 17, 22, 23, 29, 33, 34, 38, 42, 43, 47, 51, 54, 55, 57, 58, 60, 62, 64, 67, 70, 76, 80, 83, 84, 86, 87, 89, 91, 93, 96], "returns": [31, 40], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 9, "universal_type": "function", "name": "config_init", "text_snippet": "void config_init() {\n watch_config.lowbat = false;\n watch_config.btdisco = false;\n}"}, {"node_id": 11, "universal_type": "function", "name": "unknown", "text_snippet": "config_init()"}, {"node_id": 26, "universal_type": "function", "name": "get_lowbat_notification", "text_snippet": "bool get_lowbat_notification() {\n return watch_config.lowbat;\n}"}, {"node_id": 28, "universal_type": "function", "name": "unknown", "text_snippet": "get_lowbat_notification()"}, {"node_id": 35, "universal_type": "function", "name": "get_btdisco_notification", "text_snippet": "bool get_btdisco_notification() {\n return watch_config.btdisco;\n}"}, {"node_id": 37, "universal_type": "function", "name": "unknown", "text_snippet": "get_btdisco_notification()"}, {"node_id": 44, "universal_type": "function", "name": "set_lowbat_notification", "text_snippet": "void set_lowbat_notification(bool state) {\n watch_config.lowbat = state;\n if (state) {\n battery"}, {"node_id": 46, "universal_type": "function", "name": "unknown", "text_snippet": "set_lowbat_notification(bool state)"}, {"node_id": 73, "universal_type": "function", "name": "set_btdisco_notification", "text_snippet": "void set_btdisco_notification(bool state) {\n watch_config.btdisco = state;\n if (state) {\n bluet"}, {"node_id": 75, "universal_type": "function", "name": "unknown", "text_snippet": "set_btdisco_notification(bool state)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include \"config.h\"\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include \"ui.h\"\n"}, {"node_id": 4, "text": "#include"}]}, "original_source_code": "#include \"config.h\"\n#include \"ui.h\"\n\nstatic Config watch_config;\n\nvoid config_init() {\n watch_config.lowbat = false;\n watch_config.btdisco = false;\n}\n\nbool get_lowbat_notification() {\n return watch_config.lowbat;\n}\n\nbool get_btdisco_notification() {\n return watch_config.btdisco;\n}\n\nvoid set_lowbat_notification(bool state) {\n watch_config.lowbat = state;\n if (state) {\n battery_state_service_subscribe(battery_state_handler);\n } else {\n battery_state_service_unsubscribe();\n lowbattery_handler(false);\n }\n}\n\nvoid set_btdisco_notification(bool state) {\n watch_config.btdisco = state;\n if (state) {\n bluetooth_connection_service_subscribe(bluetooth_connection_handler);\n } else {\n bluetooth_connection_service_unsubscribe();\n }\n}\n"}
80,582
c
#pragma once #include "IStorageBackend.h" #include "IAsyncStorageBackend.h" #include "DatabaseSet.h" #include "ExistenceIndex.h" #include "AsyncStorageTypes.h" #include "VFSQueueTypes.h" #include "MovingAverage.h" #include "PushReplicationService.h" #include <boost/filesystem.hpp> #include <boost/thread.hpp> #include <boost/asio.hpp> #include <iosfwd> #include <deque> #include <string> /** * Namespace for InWorldz virtual file system components */ namespace iwvfs { /** InWorldz virtual file system storage backend. Provides access to an indexed file system that uses the first 3 letters of the hex asset id to set up 4096 folders that each contain a database and index file for local and global assets */ class VFSBackend : public IStorageBackend, public IAsyncStorageBackend { private: const static int DISK_LATENCY_SAMPLE_SIZE = 50; std::string _storageRoot; bool _enablePurge; bool _debugging; bool _stop; ExistenceIndex::ptr _existenceIndex; boost::shared_ptr<boost::thread> _workerThread; boost::mutex _workMutex; boost::condition_variable _workArrived; std::deque<AssetRequest::ptr> _workQueue; boost::asio::io_service& _ioService; boost::asio::deadline_timer _purgeLocalsTimer; bool _isPurgingLocals; int _currentLocalsPurgeIndex; MovingAverage _diskLatencyAvg; MovingAverage _diskOpAvg; PushReplicationService::ptr _pushRepl; bool isLittleEndian(); boost::filesystem::path getFullPathForUUID(const std::string& uuid); void verifyDatabaseDirectory(const std::string& uuid); DatabaseSet::ptr verifyAndopenSetForUUID(const std::string& uuid); void workLoop(); void onPurgeTimer(const boost::system::error_code& error); void unindexLocals(UuidListPtr uuidList, std::string uuidHead); void assetWriteFailed(std::string assetId, std::string reason); void ioLoopFailed(std::string reason); protected: void performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback); void performDiskRead(const std::string& assetId, AsyncGetAssetCallback callback); void performDiskPurge(const std::string& assetId, AsyncAssetPurgeCallback callback); void performDiskPurgeLocals(const std::string& assetId); void performLocalsPhysicalDeletion(const std::string& uuidHead); void performGetStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback); void performGetStoredAssetIds(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback); public: friend class AssetGetRequest; friend class AssetPutRequest; friend class AssetPurgeRequest; friend class DeleteLocalStorageRequest; friend class CollectStatusRequest; friend class GetStoredAssetIdsRequest; public: VFSBackend(const std::string& storageRoot, bool enablePurge, boost::asio::io_service& ioService, PushReplicationService::ptr pushRepl); virtual ~VFSBackend(); virtual Asset::ptr getAsset(const std::string& uuid); virtual void storeAsset(Asset::ptr asset); virtual bool assetExists(const std::string& uuid); virtual void purgeAsset(const std::string& uuid); virtual void getAsset(const std::string& uuid, AsyncGetAssetCallback callBack); virtual void getAsset(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack); virtual void storeAsset(Asset::ptr asset, AsyncStoreAssetCallback callBack); virtual void purgeAsset(const std::string& uuid, AsyncAssetPurgeCallback callBack); virtual void beginPurgeLocals(); virtual void getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback); virtual void getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback); virtual void shutdown(); ExistenceIndex::ptr getIndex(); }; }
40.51
92
(translation_unit) "#pragma once\n\n#include "IStorageBackend.h"\n#include "IAsyncStorageBackend.h"\n#include "DatabaseSet.h"\n#include "ExistenceIndex.h"\n#include "AsyncStorageTypes.h"\n#include "VFSQueueTypes.h"\n#include "MovingAverage.h"\n#include "PushReplicationService.h"\n\n#include <boost/filesystem.hpp>\n#include <boost/thread.hpp>\n#include <boost/asio.hpp>\n#include <iosfwd>\n#include <deque>\n#include <string>\n\n/**\n * Namespace for InWorldz virtual file system components\n */\nnamespace iwvfs\n{\n /**\n InWorldz virtual file system storage backend. Provides access\n to an indexed file system that uses the first 3 letters of the hex\n asset id to set up 4096 folders that each contain a database and index\n file for local and global assets\n */\n class VFSBackend : public IStorageBackend, public IAsyncStorageBackend\n {\n private:\n const static int DISK_LATENCY_SAMPLE_SIZE = 50;\n\n std::string _storageRoot;\n bool _enablePurge;\n\n bool _debugging;\n bool _stop;\n\n ExistenceIndex::ptr _existenceIndex;\n \n boost::shared_ptr<boost::thread> _workerThread;\n boost::mutex _workMutex;\n boost::condition_variable _workArrived;\n\n std::deque<AssetRequest::ptr> _workQueue;\n\n boost::asio::io_service& _ioService;\n\n boost::asio::deadline_timer _purgeLocalsTimer;\n bool _isPurgingLocals;\n int _currentLocalsPurgeIndex;\n\n MovingAverage _diskLatencyAvg;\n MovingAverage _diskOpAvg;\n\n PushReplicationService::ptr _pushRepl;\n\n\n bool isLittleEndian();\n boost::filesystem::path getFullPathForUUID(const std::string& uuid);\n void verifyDatabaseDirectory(const std::string& uuid);\n DatabaseSet::ptr verifyAndopenSetForUUID(const std::string& uuid);\n void workLoop();\n\n void onPurgeTimer(const boost::system::error_code& error);\n \n void unindexLocals(UuidListPtr uuidList, std::string uuidHead);\n\n void assetWriteFailed(std::string assetId, std::string reason);\n void ioLoopFailed(std::string reason);\n\n protected:\n void performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback);\n void performDiskRead(const std::string& assetId, AsyncGetAssetCallback callback);\n void performDiskPurge(const std::string& assetId, AsyncAssetPurgeCallback callback);\n void performDiskPurgeLocals(const std::string& assetId);\n void performLocalsPhysicalDeletion(const std::string& uuidHead);\n void performGetStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n void performGetStoredAssetIds(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n public:\n friend class AssetGetRequest;\n friend class AssetPutRequest;\n friend class AssetPurgeRequest;\n friend class DeleteLocalStorageRequest;\n friend class CollectStatusRequest;\n friend class GetStoredAssetIdsRequest;\n\n public:\n VFSBackend(const std::string& storageRoot, bool enablePurge, boost::asio::io_service& ioService,\n PushReplicationService::ptr pushRepl);\n virtual ~VFSBackend();\n\n virtual Asset::ptr getAsset(const std::string& uuid);\n virtual void storeAsset(Asset::ptr asset);\n virtual bool assetExists(const std::string& uuid);\n virtual void purgeAsset(const std::string& uuid);\n\n virtual void getAsset(const std::string& uuid, AsyncGetAssetCallback callBack);\n virtual void getAsset(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack);\n virtual void storeAsset(Asset::ptr asset, AsyncStoreAssetCallback callBack);\n virtual void purgeAsset(const std::string& uuid, AsyncAssetPurgeCallback callBack);\n\n virtual void beginPurgeLocals();\n\n virtual void getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n virtual void getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n virtual void shutdown();\n\n ExistenceIndex::ptr getIndex();\n };\n\n}" (preproc_call) "#pragma once\n" (preproc_directive) "#pragma" (preproc_arg) "once" (preproc_include) "#include "IStorageBackend.h"\n" (#include) "#include" (string_literal) ""IStorageBackend.h"" (") """ (string_content) "IStorageBackend.h" (") """ (preproc_include) "#include "IAsyncStorageBackend.h"\n" (#include) "#include" (string_literal) ""IAsyncStorageBackend.h"" (") """ (string_content) "IAsyncStorageBackend.h" (") """ (preproc_include) "#include "DatabaseSet.h"\n" (#include) "#include" (string_literal) ""DatabaseSet.h"" (") """ (string_content) "DatabaseSet.h" (") """ (preproc_include) "#include "ExistenceIndex.h"\n" (#include) "#include" (string_literal) ""ExistenceIndex.h"" (") """ (string_content) "ExistenceIndex.h" (") """ (preproc_include) "#include "AsyncStorageTypes.h"\n" (#include) "#include" (string_literal) ""AsyncStorageTypes.h"" (") """ (string_content) "AsyncStorageTypes.h" (") """ (preproc_include) "#include "VFSQueueTypes.h"\n" (#include) "#include" (string_literal) ""VFSQueueTypes.h"" (") """ (string_content) "VFSQueueTypes.h" (") """ (preproc_include) "#include "MovingAverage.h"\n" (#include) "#include" (string_literal) ""MovingAverage.h"" (") """ (string_content) "MovingAverage.h" (") """ (preproc_include) "#include "PushReplicationService.h"\n" (#include) "#include" (string_literal) ""PushReplicationService.h"" (") """ (string_content) "PushReplicationService.h" (") """ (preproc_include) "#include <boost/filesystem.hpp>\n" (#include) "#include" (system_lib_string) "<boost/filesystem.hpp>" (preproc_include) "#include <boost/thread.hpp>\n" (#include) "#include" (system_lib_string) "<boost/thread.hpp>" (preproc_include) "#include <boost/asio.hpp>\n" (#include) "#include" (system_lib_string) "<boost/asio.hpp>" (preproc_include) "#include <iosfwd>\n" (#include) "#include" (system_lib_string) "<iosfwd>" (preproc_include) "#include <deque>\n" (#include) "#include" (system_lib_string) "<deque>" (preproc_include) "#include <string>\n" (#include) "#include" (system_lib_string) "<string>" (comment) "/**\n * Namespace for InWorldz virtual file system components\n */" (function_definition) "namespace iwvfs\n{\n /**\n InWorldz virtual file system storage backend. Provides access\n to an indexed file system that uses the first 3 letters of the hex\n asset id to set up 4096 folders that each contain a database and index\n file for local and global assets\n */\n class VFSBackend : public IStorageBackend, public IAsyncStorageBackend\n {\n private:\n const static int DISK_LATENCY_SAMPLE_SIZE = 50;\n\n std::string _storageRoot;\n bool _enablePurge;\n\n bool _debugging;\n bool _stop;\n\n ExistenceIndex::ptr _existenceIndex;\n \n boost::shared_ptr<boost::thread> _workerThread;\n boost::mutex _workMutex;\n boost::condition_variable _workArrived;\n\n std::deque<AssetRequest::ptr> _workQueue;\n\n boost::asio::io_service& _ioService;\n\n boost::asio::deadline_timer _purgeLocalsTimer;\n bool _isPurgingLocals;\n int _currentLocalsPurgeIndex;\n\n MovingAverage _diskLatencyAvg;\n MovingAverage _diskOpAvg;\n\n PushReplicationService::ptr _pushRepl;\n\n\n bool isLittleEndian();\n boost::filesystem::path getFullPathForUUID(const std::string& uuid);\n void verifyDatabaseDirectory(const std::string& uuid);\n DatabaseSet::ptr verifyAndopenSetForUUID(const std::string& uuid);\n void workLoop();\n\n void onPurgeTimer(const boost::system::error_code& error);\n \n void unindexLocals(UuidListPtr uuidList, std::string uuidHead);\n\n void assetWriteFailed(std::string assetId, std::string reason);\n void ioLoopFailed(std::string reason);\n\n protected:\n void performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback);\n void performDiskRead(const std::string& assetId, AsyncGetAssetCallback callback);\n void performDiskPurge(const std::string& assetId, AsyncAssetPurgeCallback callback);\n void performDiskPurgeLocals(const std::string& assetId);\n void performLocalsPhysicalDeletion(const std::string& uuidHead);\n void performGetStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n void performGetStoredAssetIds(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n public:\n friend class AssetGetRequest;\n friend class AssetPutRequest;\n friend class AssetPurgeRequest;\n friend class DeleteLocalStorageRequest;\n friend class CollectStatusRequest;\n friend class GetStoredAssetIdsRequest;\n\n public:\n VFSBackend(const std::string& storageRoot, bool enablePurge, boost::asio::io_service& ioService,\n PushReplicationService::ptr pushRepl);\n virtual ~VFSBackend();\n\n virtual Asset::ptr getAsset(const std::string& uuid);\n virtual void storeAsset(Asset::ptr asset);\n virtual bool assetExists(const std::string& uuid);\n virtual void purgeAsset(const std::string& uuid);\n\n virtual void getAsset(const std::string& uuid, AsyncGetAssetCallback callBack);\n virtual void getAsset(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack);\n virtual void storeAsset(Asset::ptr asset, AsyncStoreAssetCallback callBack);\n virtual void purgeAsset(const std::string& uuid, AsyncAssetPurgeCallback callBack);\n\n virtual void beginPurgeLocals();\n\n virtual void getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n virtual void getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n virtual void shutdown();\n\n ExistenceIndex::ptr getIndex();\n };\n\n}" (type_identifier) "namespace" (identifier) "iwvfs" (compound_statement) "{\n /**\n InWorldz virtual file system storage backend. Provides access\n to an indexed file system that uses the first 3 letters of the hex\n asset id to set up 4096 folders that each contain a database and index\n file for local and global assets\n */\n class VFSBackend : public IStorageBackend, public IAsyncStorageBackend\n {\n private:\n const static int DISK_LATENCY_SAMPLE_SIZE = 50;\n\n std::string _storageRoot;\n bool _enablePurge;\n\n bool _debugging;\n bool _stop;\n\n ExistenceIndex::ptr _existenceIndex;\n \n boost::shared_ptr<boost::thread> _workerThread;\n boost::mutex _workMutex;\n boost::condition_variable _workArrived;\n\n std::deque<AssetRequest::ptr> _workQueue;\n\n boost::asio::io_service& _ioService;\n\n boost::asio::deadline_timer _purgeLocalsTimer;\n bool _isPurgingLocals;\n int _currentLocalsPurgeIndex;\n\n MovingAverage _diskLatencyAvg;\n MovingAverage _diskOpAvg;\n\n PushReplicationService::ptr _pushRepl;\n\n\n bool isLittleEndian();\n boost::filesystem::path getFullPathForUUID(const std::string& uuid);\n void verifyDatabaseDirectory(const std::string& uuid);\n DatabaseSet::ptr verifyAndopenSetForUUID(const std::string& uuid);\n void workLoop();\n\n void onPurgeTimer(const boost::system::error_code& error);\n \n void unindexLocals(UuidListPtr uuidList, std::string uuidHead);\n\n void assetWriteFailed(std::string assetId, std::string reason);\n void ioLoopFailed(std::string reason);\n\n protected:\n void performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback);\n void performDiskRead(const std::string& assetId, AsyncGetAssetCallback callback);\n void performDiskPurge(const std::string& assetId, AsyncAssetPurgeCallback callback);\n void performDiskPurgeLocals(const std::string& assetId);\n void performLocalsPhysicalDeletion(const std::string& uuidHead);\n void performGetStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n void performGetStoredAssetIds(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n public:\n friend class AssetGetRequest;\n friend class AssetPutRequest;\n friend class AssetPurgeRequest;\n friend class DeleteLocalStorageRequest;\n friend class CollectStatusRequest;\n friend class GetStoredAssetIdsRequest;\n\n public:\n VFSBackend(const std::string& storageRoot, bool enablePurge, boost::asio::io_service& ioService,\n PushReplicationService::ptr pushRepl);\n virtual ~VFSBackend();\n\n virtual Asset::ptr getAsset(const std::string& uuid);\n virtual void storeAsset(Asset::ptr asset);\n virtual bool assetExists(const std::string& uuid);\n virtual void purgeAsset(const std::string& uuid);\n\n virtual void getAsset(const std::string& uuid, AsyncGetAssetCallback callBack);\n virtual void getAsset(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack);\n virtual void storeAsset(Asset::ptr asset, AsyncStoreAssetCallback callBack);\n virtual void purgeAsset(const std::string& uuid, AsyncAssetPurgeCallback callBack);\n\n virtual void beginPurgeLocals();\n\n virtual void getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n virtual void getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n virtual void shutdown();\n\n ExistenceIndex::ptr getIndex();\n };\n\n}" ({) "{" (comment) "/**\n InWorldz virtual file system storage backend. Provides access\n to an indexed file system that uses the first 3 letters of the hex\n asset id to set up 4096 folders that each contain a database and index\n file for local and global assets\n */" (ERROR) "class VFSBackend : public IStorageBackend, public IAsyncStorageBackend" (type_identifier) "class" (ERROR) "VFSBackend : public" (identifier) "VFSBackend" (:) ":" (identifier) "public" (identifier) "IStorageBackend" (,) "," (identifier) "public" (identifier) "IAsyncStorageBackend" (compound_statement) "{\n private:\n const static int DISK_LATENCY_SAMPLE_SIZE = 50;\n\n std::string _storageRoot;\n bool _enablePurge;\n\n bool _debugging;\n bool _stop;\n\n ExistenceIndex::ptr _existenceIndex;\n \n boost::shared_ptr<boost::thread> _workerThread;\n boost::mutex _workMutex;\n boost::condition_variable _workArrived;\n\n std::deque<AssetRequest::ptr> _workQueue;\n\n boost::asio::io_service& _ioService;\n\n boost::asio::deadline_timer _purgeLocalsTimer;\n bool _isPurgingLocals;\n int _currentLocalsPurgeIndex;\n\n MovingAverage _diskLatencyAvg;\n MovingAverage _diskOpAvg;\n\n PushReplicationService::ptr _pushRepl;\n\n\n bool isLittleEndian();\n boost::filesystem::path getFullPathForUUID(const std::string& uuid);\n void verifyDatabaseDirectory(const std::string& uuid);\n DatabaseSet::ptr verifyAndopenSetForUUID(const std::string& uuid);\n void workLoop();\n\n void onPurgeTimer(const boost::system::error_code& error);\n \n void unindexLocals(UuidListPtr uuidList, std::string uuidHead);\n\n void assetWriteFailed(std::string assetId, std::string reason);\n void ioLoopFailed(std::string reason);\n\n protected:\n void performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback);\n void performDiskRead(const std::string& assetId, AsyncGetAssetCallback callback);\n void performDiskPurge(const std::string& assetId, AsyncAssetPurgeCallback callback);\n void performDiskPurgeLocals(const std::string& assetId);\n void performLocalsPhysicalDeletion(const std::string& uuidHead);\n void performGetStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n void performGetStoredAssetIds(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n public:\n friend class AssetGetRequest;\n friend class AssetPutRequest;\n friend class AssetPurgeRequest;\n friend class DeleteLocalStorageRequest;\n friend class CollectStatusRequest;\n friend class GetStoredAssetIdsRequest;\n\n public:\n VFSBackend(const std::string& storageRoot, bool enablePurge, boost::asio::io_service& ioService,\n PushReplicationService::ptr pushRepl);\n virtual ~VFSBackend();\n\n virtual Asset::ptr getAsset(const std::string& uuid);\n virtual void storeAsset(Asset::ptr asset);\n virtual bool assetExists(const std::string& uuid);\n virtual void purgeAsset(const std::string& uuid);\n\n virtual void getAsset(const std::string& uuid, AsyncGetAssetCallback callBack);\n virtual void getAsset(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack);\n virtual void storeAsset(Asset::ptr asset, AsyncStoreAssetCallback callBack);\n virtual void purgeAsset(const std::string& uuid, AsyncAssetPurgeCallback callBack);\n\n virtual void beginPurgeLocals();\n\n virtual void getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n virtual void getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n virtual void shutdown();\n\n ExistenceIndex::ptr getIndex();\n }" ({) "{" (labeled_statement) "private:\n const static int DISK_LATENCY_SAMPLE_SIZE = 50;" (statement_identifier) "private" (:) ":" (declaration) "const static int DISK_LATENCY_SAMPLE_SIZE = 50;" (type_qualifier) "const" (const) "const" (storage_class_specifier) "static" (static) "static" (primitive_type) "int" (init_declarator) "DISK_LATENCY_SAMPLE_SIZE = 50" (identifier) "DISK_LATENCY_SAMPLE_SIZE" (=) "=" (number_literal) "50" (;) ";" (labeled_statement) "std::string _storageRoot;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (declaration) "string _storageRoot;" (type_identifier) "string" (identifier) "_storageRoot" (;) ";" (declaration) "bool _enablePurge;" (primitive_type) "bool" (identifier) "_enablePurge" (;) ";" (declaration) "bool _debugging;" (primitive_type) "bool" (identifier) "_debugging" (;) ";" (declaration) "bool _stop;" (primitive_type) "bool" (identifier) "_stop" (;) ";" (labeled_statement) "ExistenceIndex::ptr _existenceIndex;" (statement_identifier) "ExistenceIndex" (:) ":" (ERROR) ":" (:) ":" (declaration) "ptr _existenceIndex;" (type_identifier) "ptr" (identifier) "_existenceIndex" (;) ";" (labeled_statement) "boost::shared_ptr<boost::thread> _workerThread;" (statement_identifier) "boost" (ERROR) "::shared_ptr<boost:" (:) ":" (:) ":" (binary_expression) "shared_ptr<boost" (identifier) "shared_ptr" (<) "<" (identifier) "boost" (:) ":" (:) ":" (expression_statement) "thread> _workerThread;" (binary_expression) "thread> _workerThread" (identifier) "thread" (>) ">" (identifier) "_workerThread" (;) ";" (labeled_statement) "boost::mutex _workMutex;" (statement_identifier) "boost" (:) ":" (ERROR) ":" (:) ":" (declaration) "mutex _workMutex;" (type_identifier) "mutex" (identifier) "_workMutex" (;) ";" (labeled_statement) "boost::condition_variable _workArrived;" (statement_identifier) "boost" (:) ":" (ERROR) ":" (:) ":" (declaration) "condition_variable _workArrived;" (type_identifier) "condition_variable" (identifier) "_workArrived" (;) ";" (labeled_statement) "std::deque<AssetRequest::ptr> _workQueue;" (statement_identifier) "std" (ERROR) "::deque<AssetRequest:" (:) ":" (:) ":" (binary_expression) "deque<AssetRequest" (identifier) "deque" (<) "<" (identifier) "AssetRequest" (:) ":" (:) ":" (expression_statement) "ptr> _workQueue;" (binary_expression) "ptr> _workQueue" (identifier) "ptr" (>) ">" (identifier) "_workQueue" (;) ";" (labeled_statement) "boost::asio::io_service& _ioService;" (statement_identifier) "boost" (:) ":" (ERROR) ":" (:) ":" (labeled_statement) "asio::io_service& _ioService;" (statement_identifier) "asio" (:) ":" (ERROR) ":" (:) ":" (expression_statement) "io_service& _ioService;" (binary_expression) "io_service& _ioService" (identifier) "io_service" (&) "&" (identifier) "_ioService" (;) ";" (labeled_statement) "boost::asio::deadline_timer _purgeLocalsTimer;" (statement_identifier) "boost" (:) ":" (ERROR) ":" (:) ":" (labeled_statement) "asio::deadline_timer _purgeLocalsTimer;" (statement_identifier) "asio" (:) ":" (ERROR) ":" (:) ":" (declaration) "deadline_timer _purgeLocalsTimer;" (type_identifier) "deadline_timer" (identifier) "_purgeLocalsTimer" (;) ";" (declaration) "bool _isPurgingLocals;" (primitive_type) "bool" (identifier) "_isPurgingLocals" (;) ";" (declaration) "int _currentLocalsPurgeIndex;" (primitive_type) "int" (identifier) "_currentLocalsPurgeIndex" (;) ";" (declaration) "MovingAverage _diskLatencyAvg;" (type_identifier) "MovingAverage" (identifier) "_diskLatencyAvg" (;) ";" (declaration) "MovingAverage _diskOpAvg;" (type_identifier) "MovingAverage" (identifier) "_diskOpAvg" (;) ";" (labeled_statement) "PushReplicationService::ptr _pushRepl;" (statement_identifier) "PushReplicationService" (:) ":" (ERROR) ":" (:) ":" (declaration) "ptr _pushRepl;" (type_identifier) "ptr" (identifier) "_pushRepl" (;) ";" (declaration) "bool isLittleEndian();" (primitive_type) "bool" (function_declarator) "isLittleEndian()" (identifier) "isLittleEndian" (parameter_list) "()" (() "(" ()) ")" (;) ";" (labeled_statement) "boost::filesystem::path getFullPathForUUID(const std::string& uuid);" (statement_identifier) "boost" (:) ":" (ERROR) ":" (:) ":" (labeled_statement) "filesystem::path getFullPathForUUID(const std::string& uuid);" (statement_identifier) "filesystem" (ERROR) "::path getFullPathForUUID(const std:" (:) ":" (:) ":" (type_identifier) "path" (identifier) "getFullPathForUUID" (() "(" (type_qualifier) "const" (const) "const" (type_identifier) "std" (:) ":" (:) ":" (expression_statement) "string& uuid);" (binary_expression) "string& uuid" (identifier) "string" (&) "&" (identifier) "uuid" (ERROR) ")" ()) ")" (;) ";" (declaration) "void verifyDatabaseDirectory(const std::string& uuid);" (primitive_type) "void" (function_declarator) "verifyDatabaseDirectory(const std::string& uuid)" (identifier) "verifyDatabaseDirectory" (parameter_list) "(const std::string& uuid)" (() "(" (parameter_declaration) "const std::string& uuid" (type_qualifier) "const" (const) "const" (type_identifier) "std" (ERROR) "::string&" (:) ":" (:) ":" (identifier) "string" (&) "&" (identifier) "uuid" ()) ")" (;) ";" (labeled_statement) "DatabaseSet::ptr verifyAndopenSetForUUID(const std::string& uuid);" (statement_identifier) "DatabaseSet" (ERROR) "::ptr verifyAndopenSetForUUID(const std:" (:) ":" (:) ":" (type_identifier) "ptr" (identifier) "verifyAndopenSetForUUID" (() "(" (type_qualifier) "const" (const) "const" (type_identifier) "std" (:) ":" (:) ":" (expression_statement) "string& uuid);" (binary_expression) "string& uuid" (identifier) "string" (&) "&" (identifier) "uuid" (ERROR) ")" ()) ")" (;) ";" (declaration) "void workLoop();" (primitive_type) "void" (function_declarator) "workLoop()" (identifier) "workLoop" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "void onPurgeTimer(const boost::system::error_code& error);" (primitive_type) "void" (function_declarator) "onPurgeTimer(const boost::system::error_code& error)" (identifier) "onPurgeTimer" (parameter_list) "(const boost::system::error_code& error)" (() "(" (parameter_declaration) "const boost::system::error_code& error" (type_qualifier) "const" (const) "const" (type_identifier) "boost" (ERROR) "::system::error_code&" (:) ":" (:) ":" (identifier) "system" (:) ":" (:) ":" (identifier) "error_code" (&) "&" (identifier) "error" ()) ")" (;) ";" (declaration) "void unindexLocals(UuidListPtr uuidList, std::string uuidHead);" (primitive_type) "void" (function_declarator) "unindexLocals(UuidListPtr uuidList, std::string uuidHead)" (identifier) "unindexLocals" (parameter_list) "(UuidListPtr uuidList, std::string uuidHead)" (() "(" (parameter_declaration) "UuidListPtr uuidList" (type_identifier) "UuidListPtr" (identifier) "uuidList" (,) "," (parameter_declaration) "std::string uuidHead" (type_identifier) "std" (ERROR) "::string" (:) ":" (:) ":" (identifier) "string" (identifier) "uuidHead" ()) ")" (;) ";" (declaration) "void assetWriteFailed(std::string assetId, std::string reason);" (primitive_type) "void" (function_declarator) "assetWriteFailed(std::string assetId, std::string reason)" (identifier) "assetWriteFailed" (parameter_list) "(std::string assetId, std::string reason)" (() "(" (parameter_declaration) "std::string assetId" (type_identifier) "std" (ERROR) "::string" (:) ":" (:) ":" (identifier) "string" (identifier) "assetId" (,) "," (parameter_declaration) "std::string reason" (type_identifier) "std" (ERROR) "::string" (:) ":" (:) ":" (identifier) "string" (identifier) "reason" ()) ")" (;) ";" (declaration) "void ioLoopFailed(std::string reason);" (primitive_type) "void" (function_declarator) "ioLoopFailed(std::string reason)" (identifier) "ioLoopFailed" (parameter_list) "(std::string reason)" (() "(" (parameter_declaration) "std::string reason" (type_identifier) "std" (ERROR) "::string" (:) ":" (:) ":" (identifier) "string" (identifier) "reason" ()) ")" (;) ";" (labeled_statement) "protected:\n void performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback);" (statement_identifier) "protected" (:) ":" (declaration) "void performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback);" (primitive_type) "void" (function_declarator) "performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback)" (identifier) "performDiskWrite" (parameter_list) "(Asset::ptr asset, AsyncStoreAssetCallback callback)" (() "(" (parameter_declaration) "Asset::ptr asset" (type_identifier) "Asset" (ERROR) "::ptr" (:) ":" (:) ":" (identifier) "ptr" (identifier) "asset" (,) "," (parameter_declaration) "AsyncStoreAssetCallback callback" (type_identifier) "AsyncStoreAssetCallback" (identifier) "callback" ()) ")" (;) ";" (declaration) "void performDiskRead(const std::string& assetId, AsyncGetAssetCallback callback);" (primitive_type) "void" (function_declarator) "performDiskRead(const std::string& assetId, AsyncGetAssetCallback callback)" (identifier) "performDiskRead" (parameter_list) "(const std::string& assetId, AsyncGetAssetCallback callback)" (() "(" (parameter_declaration) "const std::string& assetId" (type_qualifier) "const" (const) "const" (type_identifier) "std" (ERROR) "::string&" (:) ":" (:) ":" (identifier) "string" (&) "&" (identifier) "assetId" (,) "," (parameter_declaration) "AsyncGetAssetCallback callback" (type_identifier) "AsyncGetAssetCallback" (identifier) "callback" ()) ")" (;) ";" (declaration) "void performDiskPurge(const std::string& assetId, AsyncAssetPurgeCallback callback);" (primitive_type) "void" (function_declarator) "performDiskPurge(const std::string& assetId, AsyncAssetPurgeCallback callback)" (identifier) "performDiskPurge" (parameter_list) "(const std::string& assetId, AsyncAssetPurgeCallback callback)" (() "(" (parameter_declaration) "const std::string& assetId" (type_qualifier) "const" (const) "const" (type_identifier) "std" (ERROR) "::string&" (:) ":" (:) ":" (identifier) "string" (&) "&" (identifier) "assetId" (,) "," (parameter_declaration) "AsyncAssetPurgeCallback callback" (type_identifier) "AsyncAssetPurgeCallback" (identifier) "callback" ()) ")" (;) ";" (declaration) "void performDiskPurgeLocals(const std::string& assetId);" (primitive_type) "void" (function_declarator) "performDiskPurgeLocals(const std::string& assetId)" (identifier) "performDiskPurgeLocals" (parameter_list) "(const std::string& assetId)" (() "(" (parameter_declaration) "const std::string& assetId" (type_qualifier) "const" (const) "const" (type_identifier) "std" (ERROR) "::string&" (:) ":" (:) ":" (identifier) "string" (&) "&" (identifier) "assetId" ()) ")" (;) ";" (declaration) "void performLocalsPhysicalDeletion(const std::string& uuidHead);" (primitive_type) "void" (function_declarator) "performLocalsPhysicalDeletion(const std::string& uuidHead)" (identifier) "performLocalsPhysicalDeletion" (parameter_list) "(const std::string& uuidHead)" (() "(" (parameter_declaration) "const std::string& uuidHead" (type_qualifier) "const" (const) "const" (type_identifier) "std" (ERROR) "::string&" (:) ":" (:) ":" (identifier) "string" (&) "&" (identifier) "uuidHead" ()) ")" (;) ";" (ERROR) "void performGetStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback)" (primitive_type) "void" (function_declarator) "performGetStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback" (identifier) "performGetStatus" (parameter_list) "(boost::shared_ptr<std::ostream> journal, boost::function<void()" (() "(" (parameter_declaration) "boost::shared_ptr<std::ostream> journal" (type_identifier) "boost" (ERROR) "::shared_ptr<std::ostream>" (:) ":" (:) ":" (identifier) "shared_ptr" (<) "<" (identifier) "std" (:) ":" (:) ":" (identifier) "ostream" (>) ">" (identifier) "journal" (,) "," (parameter_declaration) "boost::function" (type_identifier) "boost" (ERROR) "::" (:) ":" (:) ":" (identifier) "function" (ERROR) "<void(" (<) "<" (primitive_type) "void" (() "(" ()) ")" (ERROR) ">" (>) ">" (identifier) "completedCallback" ()) ")" (expression_statement) ";" (;) ";" (ERROR) "void performGetStoredAssetIds(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback)" (primitive_type) "void" (function_declarator) "performGetStoredAssetIds(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback" (identifier) "performGetStoredAssetIds" (parameter_list) "(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()" (() "(" (parameter_declaration) "std::string prefix" (type_identifier) "std" (ERROR) "::string" (:) ":" (:) ":" (identifier) "string" (identifier) "prefix" (,) "," (parameter_declaration) "boost::shared_ptr<std::ostream> journal" (type_identifier) "boost" (ERROR) "::shared_ptr<std::ostream>" (:) ":" (:) ":" (identifier) "shared_ptr" (<) "<" (identifier) "std" (:) ":" (:) ":" (identifier) "ostream" (>) ">" (identifier) "journal" (,) "," (parameter_declaration) "boost::function" (type_identifier) "boost" (ERROR) "::" (:) ":" (:) ":" (identifier) "function" (ERROR) "<void(" (<) "<" (primitive_type) "void" (() "(" ()) ")" (ERROR) ">" (>) ">" (identifier) "completedCallback" ()) ")" (expression_statement) ";" (;) ";" (labeled_statement) "public:\n friend class AssetGetRequest;" (statement_identifier) "public" (:) ":" (declaration) "friend class AssetGetRequest;" (type_identifier) "friend" (ERROR) "class" (identifier) "class" (identifier) "AssetGetRequest" (;) ";" (declaration) "friend class AssetPutRequest;" (type_identifier) "friend" (ERROR) "class" (identifier) "class" (identifier) "AssetPutRequest" (;) ";" (declaration) "friend class AssetPurgeRequest;" (type_identifier) "friend" (ERROR) "class" (identifier) "class" (identifier) "AssetPurgeRequest" (;) ";" (declaration) "friend class DeleteLocalStorageRequest;" (type_identifier) "friend" (ERROR) "class" (identifier) "class" (identifier) "DeleteLocalStorageRequest" (;) ";" (declaration) "friend class CollectStatusRequest;" (type_identifier) "friend" (ERROR) "class" (identifier) "class" (identifier) "CollectStatusRequest" (;) ";" (declaration) "friend class GetStoredAssetIdsRequest;" (type_identifier) "friend" (ERROR) "class" (identifier) "class" (identifier) "GetStoredAssetIdsRequest" (;) ";" (labeled_statement) "public:\n VFSBackend(const std::string& storageRoot, bool enablePurge, boost::asio::io_service& ioService,\n PushReplicationService::ptr pushRepl);" (statement_identifier) "public" (:) ":" (labeled_statement) "VFSBackend(const std::string& storageRoot, bool enablePurge, boost::asio::io_service& ioService,\n PushReplicationService::ptr pushRepl);" (statement_identifier) "VFSBackend" (ERROR) "(const std::string& storageRoot, bool enablePurge, boost:" (() "(" (type_descriptor) "const std" (type_qualifier) "const" (const) "const" (type_identifier) "std" (:) ":" (:) ":" (comma_expression) "string& storageRoot, bool enablePurge, boost" (binary_expression) "string& storageRoot" (identifier) "string" (&) "&" (identifier) "storageRoot" (,) "," (ERROR) "bool" (identifier) "bool" (comma_expression) "enablePurge, boost" (identifier) "enablePurge" (,) "," (identifier) "boost" (:) ":" (:) ":" (labeled_statement) "asio::io_service& ioService,\n PushReplicationService::ptr pushRepl);" (statement_identifier) "asio" (ERROR) "::io_service& ioService,\n PushReplicationService:" (:) ":" (:) ":" (comma_expression) "io_service& ioService,\n PushReplicationService" (binary_expression) "io_service& ioService" (identifier) "io_service" (&) "&" (identifier) "ioService" (,) "," (identifier) "PushReplicationService" (:) ":" (:) ":" (declaration) "ptr pushRepl);" (type_identifier) "ptr" (identifier) "pushRepl" (ERROR) ")" ()) ")" (;) ";" (declaration) "virtual ~VFSBackend();" (type_identifier) "virtual" (ERROR) "~" (~) "~" (function_declarator) "VFSBackend()" (identifier) "VFSBackend" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "virtual Asset::ptr getAsset(const std::string& uuid);" (type_identifier) "virtual" (ERROR) "Asset::ptr" (identifier) "Asset" (:) ":" (:) ":" (identifier) "ptr" (function_declarator) "getAsset(const std::string& uuid)" (identifier) "getAsset" (parameter_list) "(const std::string& uuid)" (() "(" (parameter_declaration) "const std::string& uuid" (type_qualifier) "const" (const) "const" (type_identifier) "std" (ERROR) "::string&" (:) ":" (:) ":" (identifier) "string" (&) "&" (identifier) "uuid" ()) ")" (;) ";" (declaration) "virtual void storeAsset(Asset::ptr asset);" (type_identifier) "virtual" (ERROR) "void" (identifier) "void" (function_declarator) "storeAsset(Asset::ptr asset)" (identifier) "storeAsset" (parameter_list) "(Asset::ptr asset)" (() "(" (parameter_declaration) "Asset::ptr asset" (type_identifier) "Asset" (ERROR) "::ptr" (:) ":" (:) ":" (identifier) "ptr" (identifier) "asset" ()) ")" (;) ";" (declaration) "virtual bool assetExists(const std::string& uuid);" (type_identifier) "virtual" (ERROR) "bool" (identifier) "bool" (function_declarator) "assetExists(const std::string& uuid)" (identifier) "assetExists" (parameter_list) "(const std::string& uuid)" (() "(" (parameter_declaration) "const std::string& uuid" (type_qualifier) "const" (const) "const" (type_identifier) "std" (ERROR) "::string&" (:) ":" (:) ":" (identifier) "string" (&) "&" (identifier) "uuid" ()) ")" (;) ";" (declaration) "virtual void purgeAsset(const std::string& uuid);" (type_identifier) "virtual" (ERROR) "void" (identifier) "void" (function_declarator) "purgeAsset(const std::string& uuid)" (identifier) "purgeAsset" (parameter_list) "(const std::string& uuid)" (() "(" (parameter_declaration) "const std::string& uuid" (type_qualifier) "const" (const) "const" (type_identifier) "std" (ERROR) "::string&" (:) ":" (:) ":" (identifier) "string" (&) "&" (identifier) "uuid" ()) ")" (;) ";" (declaration) "virtual void getAsset(const std::string& uuid, AsyncGetAssetCallback callBack);" (type_identifier) "virtual" (ERROR) "void" (identifier) "void" (function_declarator) "getAsset(const std::string& uuid, AsyncGetAssetCallback callBack)" (identifier) "getAsset" (parameter_list) "(const std::string& uuid, AsyncGetAssetCallback callBack)" (() "(" (parameter_declaration) "const std::string& uuid" (type_qualifier) "const" (const) "const" (type_identifier) "std" (ERROR) "::string&" (:) ":" (:) ":" (identifier) "string" (&) "&" (identifier) "uuid" (,) "," (parameter_declaration) "AsyncGetAssetCallback callBack" (type_identifier) "AsyncGetAssetCallback" (identifier) "callBack" ()) ")" (;) ";" (declaration) "virtual void getAsset(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack);" (type_identifier) "virtual" (ERROR) "void" (identifier) "void" (function_declarator) "getAsset(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack)" (identifier) "getAsset" (parameter_list) "(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack)" (() "(" (parameter_declaration) "const std::string& uuid" (type_qualifier) "const" (const) "const" (type_identifier) "std" (ERROR) "::string&" (:) ":" (:) ":" (identifier) "string" (&) "&" (identifier) "uuid" (,) "," (parameter_declaration) "unsigned int flags" (sized_type_specifier) "unsigned int" (unsigned) "unsigned" (primitive_type) "int" (identifier) "flags" (,) "," (parameter_declaration) "AsyncGetAssetCallback callBack" (type_identifier) "AsyncGetAssetCallback" (identifier) "callBack" ()) ")" (;) ";" (declaration) "virtual void storeAsset(Asset::ptr asset, AsyncStoreAssetCallback callBack);" (type_identifier) "virtual" (ERROR) "void" (identifier) "void" (function_declarator) "storeAsset(Asset::ptr asset, AsyncStoreAssetCallback callBack)" (identifier) "storeAsset" (parameter_list) "(Asset::ptr asset, AsyncStoreAssetCallback callBack)" (() "(" (parameter_declaration) "Asset::ptr asset" (type_identifier) "Asset" (ERROR) "::ptr" (:) ":" (:) ":" (identifier) "ptr" (identifier) "asset" (,) "," (parameter_declaration) "AsyncStoreAssetCallback callBack" (type_identifier) "AsyncStoreAssetCallback" (identifier) "callBack" ()) ")" (;) ";" (declaration) "virtual void purgeAsset(const std::string& uuid, AsyncAssetPurgeCallback callBack);" (type_identifier) "virtual" (ERROR) "void" (identifier) "void" (function_declarator) "purgeAsset(const std::string& uuid, AsyncAssetPurgeCallback callBack)" (identifier) "purgeAsset" (parameter_list) "(const std::string& uuid, AsyncAssetPurgeCallback callBack)" (() "(" (parameter_declaration) "const std::string& uuid" (type_qualifier) "const" (const) "const" (type_identifier) "std" (ERROR) "::string&" (:) ":" (:) ":" (identifier) "string" (&) "&" (identifier) "uuid" (,) "," (parameter_declaration) "AsyncAssetPurgeCallback callBack" (type_identifier) "AsyncAssetPurgeCallback" (identifier) "callBack" ()) ")" (;) ";" (declaration) "virtual void beginPurgeLocals();" (type_identifier) "virtual" (ERROR) "void" (identifier) "void" (function_declarator) "beginPurgeLocals()" (identifier) "beginPurgeLocals" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "virtual void getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n virtual void getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n virtual void shutdown();" (type_identifier) "virtual" (ERROR) "void getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n virtual void getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n virtual void" (identifier) "void" (function_declarator) "getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback" (identifier) "getStatus" (parameter_list) "(boost::shared_ptr<std::ostream> journal, boost::function<void()" (() "(" (parameter_declaration) "boost::shared_ptr<std::ostream> journal" (type_identifier) "boost" (ERROR) "::shared_ptr<std::ostream>" (:) ":" (:) ":" (identifier) "shared_ptr" (<) "<" (identifier) "std" (:) ":" (:) ":" (identifier) "ostream" (>) ">" (identifier) "journal" (,) "," (parameter_declaration) "boost::function" (type_identifier) "boost" (ERROR) "::" (:) ":" (:) ":" (identifier) "function" (ERROR) "<void(" (<) "<" (primitive_type) "void" (() "(" ()) ")" (ERROR) ">" (>) ">" (identifier) "completedCallback" ()) ")" (;) ";" (identifier) "virtual" (identifier) "void" (function_declarator) "getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback" (identifier) "getStoredAssetIDsWithPrefix" (parameter_list) "(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()" (() "(" (parameter_declaration) "std::string prefix" (type_identifier) "std" (ERROR) "::string" (:) ":" (:) ":" (identifier) "string" (identifier) "prefix" (,) "," (parameter_declaration) "boost::shared_ptr<std::ostream> journal" (type_identifier) "boost" (ERROR) "::shared_ptr<std::ostream>" (:) ":" (:) ":" (identifier) "shared_ptr" (<) "<" (identifier) "std" (:) ":" (:) ":" (identifier) "ostream" (>) ">" (identifier) "journal" (,) "," (parameter_declaration) "boost::function" (type_identifier) "boost" (ERROR) "::" (:) ":" (:) ":" (identifier) "function" (ERROR) "<void(" (<) "<" (primitive_type) "void" (() "(" ()) ")" (ERROR) ">" (>) ">" (identifier) "completedCallback" ()) ")" (;) ";" (identifier) "virtual" (identifier) "void" (function_declarator) "shutdown()" (identifier) "shutdown" (parameter_list) "()" (() "(" ()) ")" (;) ";" (labeled_statement) "ExistenceIndex::ptr getIndex();" (statement_identifier) "ExistenceIndex" (:) ":" (ERROR) ":" (:) ":" (declaration) "ptr getIndex();" (type_identifier) "ptr" (function_declarator) "getIndex()" (identifier) "getIndex" (parameter_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (}) "}"
975
79
{"language": "c", "success": true, "metadata": {"lines": 92, "avg_line_length": 40.51, "nodes": 576, "errors": 0, "source_hash": "65c3b61d3fd80fa8aa5c1d35d140ae38399bd56feb96acbfabded9a58dd966b7", "categorized_nodes": 420}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#pragma once\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#pragma", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "once", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 12}}, {"id": 3, "type": "preproc_include", "text": "#include \"IStorageBackend.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 5, "type": "string_literal", "text": "\"IStorageBackend.h\"", "parent": 3, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 28}}, {"id": 6, "type": "preproc_include", "text": "#include \"IAsyncStorageBackend.h\"\n", "parent": null, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"IAsyncStorageBackend.h\"", "parent": 6, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 33}}, {"id": 9, "type": "preproc_include", "text": "#include \"DatabaseSet.h\"\n", "parent": null, "children": [10, 11], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"DatabaseSet.h\"", "parent": 9, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 24}}, {"id": 12, "type": "preproc_include", "text": "#include \"ExistenceIndex.h\"\n", "parent": null, "children": [13, 14], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 14, "type": "string_literal", "text": "\"ExistenceIndex.h\"", "parent": 12, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 27}}, {"id": 15, "type": "preproc_include", "text": "#include \"AsyncStorageTypes.h\"\n", "parent": null, "children": [16, 17], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 8}}, {"id": 17, "type": "string_literal", "text": "\"AsyncStorageTypes.h\"", "parent": 15, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 30}}, {"id": 18, "type": "preproc_include", "text": "#include \"VFSQueueTypes.h\"\n", "parent": null, "children": [19, 20], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 8}}, {"id": 20, "type": "string_literal", "text": "\"VFSQueueTypes.h\"", "parent": 18, "children": [], "start_point": {"row": 7, "column": 9}, "end_point": {"row": 7, "column": 26}}, {"id": 21, "type": "preproc_include", "text": "#include \"MovingAverage.h\"\n", "parent": null, "children": [22, 23], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 22, "type": "#include", "text": "#include", "parent": 21, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 8}}, {"id": 23, "type": "string_literal", "text": "\"MovingAverage.h\"", "parent": 21, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 26}}, {"id": 24, "type": "preproc_include", "text": "#include \"PushReplicationService.h\"\n", "parent": null, "children": [25, 26], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 25, "type": "#include", "text": "#include", "parent": 24, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 8}}, {"id": 26, "type": "string_literal", "text": "\"PushReplicationService.h\"", "parent": 24, "children": [], "start_point": {"row": 9, "column": 9}, "end_point": {"row": 9, "column": 35}}, {"id": 27, "type": "preproc_include", "text": "#include <boost/filesystem.hpp>\n", "parent": null, "children": [28, 29], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 12, "column": 0}}, {"id": 28, "type": "#include", "text": "#include", "parent": 27, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 8}}, {"id": 29, "type": "system_lib_string", "text": "<boost/filesystem.hpp>", "parent": 27, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 31}}, {"id": 30, "type": "preproc_include", "text": "#include <boost/thread.hpp>\n", "parent": null, "children": [31, 32], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 13, "column": 0}}, {"id": 31, "type": "#include", "text": "#include", "parent": 30, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 8}}, {"id": 32, "type": "system_lib_string", "text": "<boost/thread.hpp>", "parent": 30, "children": [], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 27}}, {"id": 33, "type": "preproc_include", "text": "#include <boost/asio.hpp>\n", "parent": null, "children": [34, 35], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 14, "column": 0}}, {"id": 34, "type": "#include", "text": "#include", "parent": 33, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 8}}, {"id": 35, "type": "system_lib_string", "text": "<boost/asio.hpp>", "parent": 33, "children": [], "start_point": {"row": 13, "column": 9}, "end_point": {"row": 13, "column": 25}}, {"id": 36, "type": "preproc_include", "text": "#include <iosfwd>\n", "parent": null, "children": [37, 38], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 15, "column": 0}}, {"id": 37, "type": "#include", "text": "#include", "parent": 36, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 8}}, {"id": 38, "type": "system_lib_string", "text": "<iosfwd>", "parent": 36, "children": [], "start_point": {"row": 14, "column": 9}, "end_point": {"row": 14, "column": 17}}, {"id": 39, "type": "preproc_include", "text": "#include <deque>\n", "parent": null, "children": [40, 41], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 40, "type": "#include", "text": "#include", "parent": 39, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 8}}, {"id": 41, "type": "system_lib_string", "text": "<deque>", "parent": 39, "children": [], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 16}}, {"id": 42, "type": "preproc_include", "text": "#include <string>\n", "parent": null, "children": [43, 44], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 17, "column": 0}}, {"id": 43, "type": "#include", "text": "#include", "parent": 42, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 8}}, {"id": 44, "type": "system_lib_string", "text": "<string>", "parent": 42, "children": [], "start_point": {"row": 16, "column": 9}, "end_point": {"row": 16, "column": 17}}, {"id": 45, "type": "function_definition", "text": "namespace iwvfs\n{\n\t/**\n\t\tInWorldz virtual file system storage backend. Provides access\n\t\tto an indexed file system that uses the first 3 letters of the hex\n\t\tasset id to set up 4096 folders that each contain a database and index\n\t\tfile for local and global assets\n\t*/\n\tclass VFSBackend : public IStorageBackend, public IAsyncStorageBackend\n\t{\n\tprivate:\n\t\tconst static int DISK_LATENCY_SAMPLE_SIZE = 50;\n\n\t\tstd::string _storageRoot;\n\t\tbool _enablePurge;\n\n\t\tbool _debugging;\n\t\tbool _stop;\n\n\t\tExistenceIndex::ptr _existenceIndex;\n\t\n\t\tboost::shared_ptr<boost::thread> _workerThread;\n\t\tboost::mutex _workMutex;\n\t\tboost::condition_variable _workArrived;\n\n\t\tstd::deque<AssetRequest::ptr> _workQueue;\n\n\t\tboost::asio::io_service& _ioService;\n\n\t\tboost::asio::deadline_timer _purgeLocalsTimer;\n\t\tbool _isPurgingLocals;\n\t\tint _currentLocalsPurgeIndex;\n\n\t\tMovingAverage _diskLatencyAvg;\n\t\tMovingAverage _diskOpAvg;\n\n\t\tPushReplicationService::ptr _pushRepl;\n\n\n\t\tbool isLittleEndian();\n\t\tboost::filesystem::path getFullPathForUUID(const std::string& uuid);\n\t\tvoid verifyDatabaseDirectory(const std::string& uuid);\n\t\tDatabaseSet::ptr verifyAndopenSetForUUID(const std::string& uuid);\n\t\tvoid workLoop();\n\n\t\tvoid onPurgeTimer(const boost::system::error_code& error);\n\t\t\n\t\tvoid unindexLocals(UuidListPtr uuidList, std::string uuidHead);\n\n\t\tvoid assetWriteFailed(std::string assetId, std::string reason);\n\t\tvoid ioLoopFailed(std::string reason);\n\n\tprotected:\n\t\tvoid performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback);\n\t\tvoid performDiskRead(const std::string& assetId, AsyncGetAssetCallback callback);\n\t\tvoid performDiskPurge(const std::string& assetId, AsyncAssetPurgeCallback callback);\n\t\tvoid performDiskPurgeLocals(const std::string& assetId);\n\t\tvoid performLocalsPhysicalDeletion(const std::string& uuidHead);\n\t\tvoid performGetStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\t\tvoid performGetStoredAssetIds(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n\tpublic:\n\t\tfriend class AssetGetRequest;\n\t\tfriend class AssetPutRequest;\n\t\tfriend class AssetPurgeRequest;\n\t\tfriend class DeleteLocalStorageRequest;\n\t\tfriend class CollectStatusRequest;\n\t\tfriend class GetStoredAssetIdsRequest;\n\n\tpublic:\n\t\tVFSBackend(const std::string& storageRoot, bool enablePurge, boost::asio::io_service& ioService,\n\t\t\tPushReplicationService::ptr pushRepl);\n\t\tvirtual ~VFSBackend();\n\n\t\tvirtual Asset::ptr getAsset(const std::string& uuid);\n\t\tvirtual void storeAsset(Asset::ptr asset);\n\t\tvirtual bool assetExists(const std::string& uuid);\n\t\tvirtual void purgeAsset(const std::string& uuid);\n\n\t\tvirtual void getAsset(const std::string& uuid, AsyncGetAssetCallback callBack);\n\t\tvirtual void getAsset(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack);\n\t\tvirtual void storeAsset(Asset::ptr asset, AsyncStoreAssetCallback callBack);\n\t\tvirtual void purgeAsset(const std::string& uuid, AsyncAssetPurgeCallback callBack);\n\n\t\tvirtual void beginPurgeLocals();\n\n\t\tvirtual void getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\t\tvirtual void getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n\t\tvirtual void shutdown();\n\n\t\tExistenceIndex::ptr getIndex();\n\t};\n\n}", "parent": null, "children": [46, 47], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 115, "column": 1}}, {"id": 46, "type": "type_identifier", "text": "namespace", "parent": 45, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 9}}, {"id": 47, "type": "identifier", "text": "iwvfs", "parent": 45, "children": [], "start_point": {"row": 21, "column": 10}, "end_point": {"row": 21, "column": 15}}, {"id": 48, "type": "ERROR", "text": "class VFSBackend : public IStorageBackend, public IAsyncStorageBackend", "parent": 45, "children": [49, 51, 52], "start_point": {"row": 29, "column": 1}, "end_point": {"row": 29, "column": 71}}, {"id": 49, "type": "ERROR", "text": "VFSBackend : public", "parent": 48, "children": [50], "start_point": {"row": 29, "column": 7}, "end_point": {"row": 29, "column": 26}}, {"id": 50, "type": "identifier", "text": "VFSBackend", "parent": 49, "children": [], "start_point": {"row": 29, "column": 7}, "end_point": {"row": 29, "column": 17}}, {"id": 51, "type": "identifier", "text": "IStorageBackend", "parent": 48, "children": [], "start_point": {"row": 29, "column": 27}, "end_point": {"row": 29, "column": 42}}, {"id": 52, "type": "identifier", "text": "IAsyncStorageBackend", "parent": 48, "children": [], "start_point": {"row": 29, "column": 51}, "end_point": {"row": 29, "column": 71}}, {"id": 53, "type": "labeled_statement", "text": "private:\n\t\tconst static int DISK_LATENCY_SAMPLE_SIZE = 50;", "parent": 45, "children": [54], "start_point": {"row": 31, "column": 1}, "end_point": {"row": 32, "column": 49}}, {"id": 54, "type": "declaration", "text": "const static int DISK_LATENCY_SAMPLE_SIZE = 50;", "parent": 53, "children": [55, 56], "start_point": {"row": 32, "column": 2}, "end_point": {"row": 32, "column": 49}}, {"id": 55, "type": "primitive_type", "text": "int", "parent": 54, "children": [], "start_point": {"row": 32, "column": 15}, "end_point": {"row": 32, "column": 18}}, {"id": 56, "type": "init_declarator", "text": "DISK_LATENCY_SAMPLE_SIZE = 50", "parent": 54, "children": [57, 58, 59], "start_point": {"row": 32, "column": 19}, "end_point": {"row": 32, "column": 48}}, {"id": 57, "type": "identifier", "text": "DISK_LATENCY_SAMPLE_SIZE", "parent": 56, "children": [], "start_point": {"row": 32, "column": 19}, "end_point": {"row": 32, "column": 43}}, {"id": 58, "type": "=", "text": "=", "parent": 56, "children": [], "start_point": {"row": 32, "column": 44}, "end_point": {"row": 32, "column": 45}}, {"id": 59, "type": "number_literal", "text": "50", "parent": 56, "children": [], "start_point": {"row": 32, "column": 46}, "end_point": {"row": 32, "column": 48}}, {"id": 60, "type": "labeled_statement", "text": "std::string _storageRoot;", "parent": 45, "children": [61, 62], "start_point": {"row": 34, "column": 2}, "end_point": {"row": 34, "column": 27}}, {"id": 61, "type": "statement_identifier", "text": "std", "parent": 60, "children": [], "start_point": {"row": 34, "column": 2}, "end_point": {"row": 34, "column": 5}}, {"id": 62, "type": "declaration", "text": "string _storageRoot;", "parent": 60, "children": [63, 64], "start_point": {"row": 34, "column": 7}, "end_point": {"row": 34, "column": 27}}, {"id": 63, "type": "type_identifier", "text": "string", "parent": 62, "children": [], "start_point": {"row": 34, "column": 7}, "end_point": {"row": 34, "column": 13}}, {"id": 64, "type": "identifier", "text": "_storageRoot", "parent": 62, "children": [], "start_point": {"row": 34, "column": 14}, "end_point": {"row": 34, "column": 26}}, {"id": 65, "type": "declaration", "text": "bool _enablePurge;", "parent": 45, "children": [66, 67], "start_point": {"row": 35, "column": 2}, "end_point": {"row": 35, "column": 20}}, {"id": 66, "type": "primitive_type", "text": "bool", "parent": 65, "children": [], "start_point": {"row": 35, "column": 2}, "end_point": {"row": 35, "column": 6}}, {"id": 67, "type": "identifier", "text": "_enablePurge", "parent": 65, "children": [], "start_point": {"row": 35, "column": 7}, "end_point": {"row": 35, "column": 19}}, {"id": 68, "type": "declaration", "text": "bool _debugging;", "parent": 45, "children": [69, 70], "start_point": {"row": 37, "column": 2}, "end_point": {"row": 37, "column": 18}}, {"id": 69, "type": "primitive_type", "text": "bool", "parent": 68, "children": [], "start_point": {"row": 37, "column": 2}, "end_point": {"row": 37, "column": 6}}, {"id": 70, "type": "identifier", "text": "_debugging", "parent": 68, "children": [], "start_point": {"row": 37, "column": 7}, "end_point": {"row": 37, "column": 17}}, {"id": 71, "type": "declaration", "text": "bool _stop;", "parent": 45, "children": [72, 73], "start_point": {"row": 38, "column": 2}, "end_point": {"row": 38, "column": 13}}, {"id": 72, "type": "primitive_type", "text": "bool", "parent": 71, "children": [], "start_point": {"row": 38, "column": 2}, "end_point": {"row": 38, "column": 6}}, {"id": 73, "type": "identifier", "text": "_stop", "parent": 71, "children": [], "start_point": {"row": 38, "column": 7}, "end_point": {"row": 38, "column": 12}}, {"id": 74, "type": "labeled_statement", "text": "ExistenceIndex::ptr _existenceIndex;", "parent": 45, "children": [75, 76], "start_point": {"row": 40, "column": 2}, "end_point": {"row": 40, "column": 38}}, {"id": 75, "type": "statement_identifier", "text": "ExistenceIndex", "parent": 74, "children": [], "start_point": {"row": 40, "column": 2}, "end_point": {"row": 40, "column": 16}}, {"id": 76, "type": "declaration", "text": "ptr _existenceIndex;", "parent": 74, "children": [77, 78], "start_point": {"row": 40, "column": 18}, "end_point": {"row": 40, "column": 38}}, {"id": 77, "type": "type_identifier", "text": "ptr", "parent": 76, "children": [], "start_point": {"row": 40, "column": 18}, "end_point": {"row": 40, "column": 21}}, {"id": 78, "type": "identifier", "text": "_existenceIndex", "parent": 76, "children": [], "start_point": {"row": 40, "column": 22}, "end_point": {"row": 40, "column": 37}}, {"id": 79, "type": "labeled_statement", "text": "boost::shared_ptr<boost::thread> _workerThread;", "parent": 45, "children": [80, 81], "start_point": {"row": 42, "column": 2}, "end_point": {"row": 42, "column": 49}}, {"id": 80, "type": "statement_identifier", "text": "boost", "parent": 79, "children": [], "start_point": {"row": 42, "column": 2}, "end_point": {"row": 42, "column": 7}}, {"id": 81, "type": "ERROR", "text": "::shared_ptr<boost:", "parent": 79, "children": [82], "start_point": {"row": 42, "column": 7}, "end_point": {"row": 42, "column": 26}}, {"id": 82, "type": "binary_expression", "text": "shared_ptr<boost", "parent": 81, "children": [83, 84, 85], "start_point": {"row": 42, "column": 9}, "end_point": {"row": 42, "column": 25}}, {"id": 83, "type": "identifier", "text": "shared_ptr", "parent": 82, "children": [], "start_point": {"row": 42, "column": 9}, "end_point": {"row": 42, "column": 19}}, {"id": 84, "type": "<", "text": "<", "parent": 82, "children": [], "start_point": {"row": 42, "column": 19}, "end_point": {"row": 42, "column": 20}}, {"id": 85, "type": "identifier", "text": "boost", "parent": 82, "children": [], "start_point": {"row": 42, "column": 20}, "end_point": {"row": 42, "column": 25}}, {"id": 86, "type": "binary_expression", "text": "thread> _workerThread", "parent": 79, "children": [87, 88, 89], "start_point": {"row": 42, "column": 27}, "end_point": {"row": 42, "column": 48}}, {"id": 87, "type": "identifier", "text": "thread", "parent": 86, "children": [], "start_point": {"row": 42, "column": 27}, "end_point": {"row": 42, "column": 33}}, {"id": 88, "type": ">", "text": ">", "parent": 86, "children": [], "start_point": {"row": 42, "column": 33}, "end_point": {"row": 42, "column": 34}}, {"id": 89, "type": "identifier", "text": "_workerThread", "parent": 86, "children": [], "start_point": {"row": 42, "column": 35}, "end_point": {"row": 42, "column": 48}}, {"id": 90, "type": "labeled_statement", "text": "boost::mutex _workMutex;", "parent": 45, "children": [91, 92], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 43, "column": 26}}, {"id": 91, "type": "statement_identifier", "text": "boost", "parent": 90, "children": [], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 43, "column": 7}}, {"id": 92, "type": "declaration", "text": "mutex _workMutex;", "parent": 90, "children": [93, 94], "start_point": {"row": 43, "column": 9}, "end_point": {"row": 43, "column": 26}}, {"id": 93, "type": "type_identifier", "text": "mutex", "parent": 92, "children": [], "start_point": {"row": 43, "column": 9}, "end_point": {"row": 43, "column": 14}}, {"id": 94, "type": "identifier", "text": "_workMutex", "parent": 92, "children": [], "start_point": {"row": 43, "column": 15}, "end_point": {"row": 43, "column": 25}}, {"id": 95, "type": "labeled_statement", "text": "boost::condition_variable _workArrived;", "parent": 45, "children": [96, 97], "start_point": {"row": 44, "column": 2}, "end_point": {"row": 44, "column": 41}}, {"id": 96, "type": "statement_identifier", "text": "boost", "parent": 95, "children": [], "start_point": {"row": 44, "column": 2}, "end_point": {"row": 44, "column": 7}}, {"id": 97, "type": "declaration", "text": "condition_variable _workArrived;", "parent": 95, "children": [98, 99], "start_point": {"row": 44, "column": 9}, "end_point": {"row": 44, "column": 41}}, {"id": 98, "type": "type_identifier", "text": "condition_variable", "parent": 97, "children": [], "start_point": {"row": 44, "column": 9}, "end_point": {"row": 44, "column": 27}}, {"id": 99, "type": "identifier", "text": "_workArrived", "parent": 97, "children": [], "start_point": {"row": 44, "column": 28}, "end_point": {"row": 44, "column": 40}}, {"id": 100, "type": "labeled_statement", "text": "std::deque<AssetRequest::ptr> _workQueue;", "parent": 45, "children": [101, 102], "start_point": {"row": 46, "column": 2}, "end_point": {"row": 46, "column": 43}}, {"id": 101, "type": "statement_identifier", "text": "std", "parent": 100, "children": [], "start_point": {"row": 46, "column": 2}, "end_point": {"row": 46, "column": 5}}, {"id": 102, "type": "ERROR", "text": "::deque<AssetRequest:", "parent": 100, "children": [103], "start_point": {"row": 46, "column": 5}, "end_point": {"row": 46, "column": 26}}, {"id": 103, "type": "binary_expression", "text": "deque<AssetRequest", "parent": 102, "children": [104, 105, 106], "start_point": {"row": 46, "column": 7}, "end_point": {"row": 46, "column": 25}}, {"id": 104, "type": "identifier", "text": "deque", "parent": 103, "children": [], "start_point": {"row": 46, "column": 7}, "end_point": {"row": 46, "column": 12}}, {"id": 105, "type": "<", "text": "<", "parent": 103, "children": [], "start_point": {"row": 46, "column": 12}, "end_point": {"row": 46, "column": 13}}, {"id": 106, "type": "identifier", "text": "AssetRequest", "parent": 103, "children": [], "start_point": {"row": 46, "column": 13}, "end_point": {"row": 46, "column": 25}}, {"id": 107, "type": "binary_expression", "text": "ptr> _workQueue", "parent": 100, "children": [108, 109, 110], "start_point": {"row": 46, "column": 27}, "end_point": {"row": 46, "column": 42}}, {"id": 108, "type": "identifier", "text": "ptr", "parent": 107, "children": [], "start_point": {"row": 46, "column": 27}, "end_point": {"row": 46, "column": 30}}, {"id": 109, "type": ">", "text": ">", "parent": 107, "children": [], "start_point": {"row": 46, "column": 30}, "end_point": {"row": 46, "column": 31}}, {"id": 110, "type": "identifier", "text": "_workQueue", "parent": 107, "children": [], "start_point": {"row": 46, "column": 32}, "end_point": {"row": 46, "column": 42}}, {"id": 111, "type": "labeled_statement", "text": "boost::asio::io_service& _ioService;", "parent": 45, "children": [112, 113], "start_point": {"row": 48, "column": 2}, "end_point": {"row": 48, "column": 38}}, {"id": 112, "type": "statement_identifier", "text": "boost", "parent": 111, "children": [], "start_point": {"row": 48, "column": 2}, "end_point": {"row": 48, "column": 7}}, {"id": 113, "type": "labeled_statement", "text": "asio::io_service& _ioService;", "parent": 111, "children": [114], "start_point": {"row": 48, "column": 9}, "end_point": {"row": 48, "column": 38}}, {"id": 114, "type": "statement_identifier", "text": "asio", "parent": 113, "children": [], "start_point": {"row": 48, "column": 9}, "end_point": {"row": 48, "column": 13}}, {"id": 115, "type": "binary_expression", "text": "io_service& _ioService", "parent": 113, "children": [116, 117], "start_point": {"row": 48, "column": 15}, "end_point": {"row": 48, "column": 37}}, {"id": 116, "type": "identifier", "text": "io_service", "parent": 115, "children": [], "start_point": {"row": 48, "column": 15}, "end_point": {"row": 48, "column": 25}}, {"id": 117, "type": "identifier", "text": "_ioService", "parent": 115, "children": [], "start_point": {"row": 48, "column": 27}, "end_point": {"row": 48, "column": 37}}, {"id": 118, "type": "labeled_statement", "text": "boost::asio::deadline_timer _purgeLocalsTimer;", "parent": 45, "children": [119, 120], "start_point": {"row": 50, "column": 2}, "end_point": {"row": 50, "column": 48}}, {"id": 119, "type": "statement_identifier", "text": "boost", "parent": 118, "children": [], "start_point": {"row": 50, "column": 2}, "end_point": {"row": 50, "column": 7}}, {"id": 120, "type": "labeled_statement", "text": "asio::deadline_timer _purgeLocalsTimer;", "parent": 118, "children": [121, 122], "start_point": {"row": 50, "column": 9}, "end_point": {"row": 50, "column": 48}}, {"id": 121, "type": "statement_identifier", "text": "asio", "parent": 120, "children": [], "start_point": {"row": 50, "column": 9}, "end_point": {"row": 50, "column": 13}}, {"id": 122, "type": "declaration", "text": "deadline_timer _purgeLocalsTimer;", "parent": 120, "children": [123, 124], "start_point": {"row": 50, "column": 15}, "end_point": {"row": 50, "column": 48}}, {"id": 123, "type": "type_identifier", "text": "deadline_timer", "parent": 122, "children": [], "start_point": {"row": 50, "column": 15}, "end_point": {"row": 50, "column": 29}}, {"id": 124, "type": "identifier", "text": "_purgeLocalsTimer", "parent": 122, "children": [], "start_point": {"row": 50, "column": 30}, "end_point": {"row": 50, "column": 47}}, {"id": 125, "type": "declaration", "text": "bool _isPurgingLocals;", "parent": 45, "children": [126, 127], "start_point": {"row": 51, "column": 2}, "end_point": {"row": 51, "column": 24}}, {"id": 126, "type": "primitive_type", "text": "bool", "parent": 125, "children": [], "start_point": {"row": 51, "column": 2}, "end_point": {"row": 51, "column": 6}}, {"id": 127, "type": "identifier", "text": "_isPurgingLocals", "parent": 125, "children": [], "start_point": {"row": 51, "column": 7}, "end_point": {"row": 51, "column": 23}}, {"id": 128, "type": "declaration", "text": "int _currentLocalsPurgeIndex;", "parent": 45, "children": [129, 130], "start_point": {"row": 52, "column": 2}, "end_point": {"row": 52, "column": 31}}, {"id": 129, "type": "primitive_type", "text": "int", "parent": 128, "children": [], "start_point": {"row": 52, "column": 2}, "end_point": {"row": 52, "column": 5}}, {"id": 130, "type": "identifier", "text": "_currentLocalsPurgeIndex", "parent": 128, "children": [], "start_point": {"row": 52, "column": 6}, "end_point": {"row": 52, "column": 30}}, {"id": 131, "type": "declaration", "text": "MovingAverage _diskLatencyAvg;", "parent": 45, "children": [132, 133], "start_point": {"row": 54, "column": 2}, "end_point": {"row": 54, "column": 32}}, {"id": 132, "type": "type_identifier", "text": "MovingAverage", "parent": 131, "children": [], "start_point": {"row": 54, "column": 2}, "end_point": {"row": 54, "column": 15}}, {"id": 133, "type": "identifier", "text": "_diskLatencyAvg", "parent": 131, "children": [], "start_point": {"row": 54, "column": 16}, "end_point": {"row": 54, "column": 31}}, {"id": 134, "type": "declaration", "text": "MovingAverage _diskOpAvg;", "parent": 45, "children": [135, 136], "start_point": {"row": 55, "column": 2}, "end_point": {"row": 55, "column": 27}}, {"id": 135, "type": "type_identifier", "text": "MovingAverage", "parent": 134, "children": [], "start_point": {"row": 55, "column": 2}, "end_point": {"row": 55, "column": 15}}, {"id": 136, "type": "identifier", "text": "_diskOpAvg", "parent": 134, "children": [], "start_point": {"row": 55, "column": 16}, "end_point": {"row": 55, "column": 26}}, {"id": 137, "type": "labeled_statement", "text": "PushReplicationService::ptr _pushRepl;", "parent": 45, "children": [138, 139], "start_point": {"row": 57, "column": 2}, "end_point": {"row": 57, "column": 40}}, {"id": 138, "type": "statement_identifier", "text": "PushReplicationService", "parent": 137, "children": [], "start_point": {"row": 57, "column": 2}, "end_point": {"row": 57, "column": 24}}, {"id": 139, "type": "declaration", "text": "ptr _pushRepl;", "parent": 137, "children": [140, 141], "start_point": {"row": 57, "column": 26}, "end_point": {"row": 57, "column": 40}}, {"id": 140, "type": "type_identifier", "text": "ptr", "parent": 139, "children": [], "start_point": {"row": 57, "column": 26}, "end_point": {"row": 57, "column": 29}}, {"id": 141, "type": "identifier", "text": "_pushRepl", "parent": 139, "children": [], "start_point": {"row": 57, "column": 30}, "end_point": {"row": 57, "column": 39}}, {"id": 142, "type": "declaration", "text": "bool isLittleEndian();", "parent": 45, "children": [143, 144], "start_point": {"row": 60, "column": 2}, "end_point": {"row": 60, "column": 24}}, {"id": 143, "type": "primitive_type", "text": "bool", "parent": 142, "children": [], "start_point": {"row": 60, "column": 2}, "end_point": {"row": 60, "column": 6}}, {"id": 144, "type": "function_declarator", "text": "isLittleEndian()", "parent": 142, "children": [145, 146], "start_point": {"row": 60, "column": 7}, "end_point": {"row": 60, "column": 23}}, {"id": 145, "type": "identifier", "text": "isLittleEndian", "parent": 144, "children": [], "start_point": {"row": 60, "column": 7}, "end_point": {"row": 60, "column": 21}}, {"id": 146, "type": "parameter_list", "text": "()", "parent": 144, "children": [], "start_point": {"row": 60, "column": 21}, "end_point": {"row": 60, "column": 23}}, {"id": 147, "type": "labeled_statement", "text": "boost::filesystem::path getFullPathForUUID(const std::string& uuid);", "parent": 45, "children": [148, 149], "start_point": {"row": 61, "column": 2}, "end_point": {"row": 61, "column": 70}}, {"id": 148, "type": "statement_identifier", "text": "boost", "parent": 147, "children": [], "start_point": {"row": 61, "column": 2}, "end_point": {"row": 61, "column": 7}}, {"id": 149, "type": "labeled_statement", "text": "filesystem::path getFullPathForUUID(const std::string& uuid);", "parent": 147, "children": [150, 151], "start_point": {"row": 61, "column": 9}, "end_point": {"row": 61, "column": 70}}, {"id": 150, "type": "statement_identifier", "text": "filesystem", "parent": 149, "children": [], "start_point": {"row": 61, "column": 9}, "end_point": {"row": 61, "column": 19}}, {"id": 151, "type": "ERROR", "text": "::path getFullPathForUUID(const std:", "parent": 149, "children": [152, 153, 154], "start_point": {"row": 61, "column": 19}, "end_point": {"row": 61, "column": 55}}, {"id": 152, "type": "type_identifier", "text": "path", "parent": 151, "children": [], "start_point": {"row": 61, "column": 21}, "end_point": {"row": 61, "column": 25}}, {"id": 153, "type": "identifier", "text": "getFullPathForUUID", "parent": 151, "children": [], "start_point": {"row": 61, "column": 26}, "end_point": {"row": 61, "column": 44}}, {"id": 154, "type": "type_identifier", "text": "std", "parent": 151, "children": [], "start_point": {"row": 61, "column": 51}, "end_point": {"row": 61, "column": 54}}, {"id": 155, "type": "binary_expression", "text": "string& uuid", "parent": 149, "children": [156, 157], "start_point": {"row": 61, "column": 56}, "end_point": {"row": 61, "column": 68}}, {"id": 156, "type": "identifier", "text": "string", "parent": 155, "children": [], "start_point": {"row": 61, "column": 56}, "end_point": {"row": 61, "column": 62}}, {"id": 157, "type": "identifier", "text": "uuid", "parent": 155, "children": [], "start_point": {"row": 61, "column": 64}, "end_point": {"row": 61, "column": 68}}, {"id": 158, "type": "declaration", "text": "void verifyDatabaseDirectory(const std::string& uuid);", "parent": 45, "children": [159, 160], "start_point": {"row": 62, "column": 2}, "end_point": {"row": 62, "column": 56}}, {"id": 159, "type": "primitive_type", "text": "void", "parent": 158, "children": [], "start_point": {"row": 62, "column": 2}, "end_point": {"row": 62, "column": 6}}, {"id": 160, "type": "function_declarator", "text": "verifyDatabaseDirectory(const std::string& uuid)", "parent": 158, "children": [161, 162], "start_point": {"row": 62, "column": 7}, "end_point": {"row": 62, "column": 55}}, {"id": 161, "type": "identifier", "text": "verifyDatabaseDirectory", "parent": 160, "children": [], "start_point": {"row": 62, "column": 7}, "end_point": {"row": 62, "column": 30}}, {"id": 162, "type": "parameter_list", "text": "(const std::string& uuid)", "parent": 160, "children": [163], "start_point": {"row": 62, "column": 30}, "end_point": {"row": 62, "column": 55}}, {"id": 163, "type": "parameter_declaration", "text": "const std::string& uuid", "parent": 162, "children": [164, 165, 167], "start_point": {"row": 62, "column": 31}, "end_point": {"row": 62, "column": 54}}, {"id": 164, "type": "type_identifier", "text": "std", "parent": 163, "children": [], "start_point": {"row": 62, "column": 37}, "end_point": {"row": 62, "column": 40}}, {"id": 165, "type": "ERROR", "text": "::string&", "parent": 163, "children": [166], "start_point": {"row": 62, "column": 40}, "end_point": {"row": 62, "column": 49}}, {"id": 166, "type": "identifier", "text": "string", "parent": 165, "children": [], "start_point": {"row": 62, "column": 42}, "end_point": {"row": 62, "column": 48}}, {"id": 167, "type": "identifier", "text": "uuid", "parent": 163, "children": [], "start_point": {"row": 62, "column": 50}, "end_point": {"row": 62, "column": 54}}, {"id": 168, "type": "labeled_statement", "text": "DatabaseSet::ptr verifyAndopenSetForUUID(const std::string& uuid);", "parent": 45, "children": [169, 170], "start_point": {"row": 63, "column": 2}, "end_point": {"row": 63, "column": 68}}, {"id": 169, "type": "statement_identifier", "text": "DatabaseSet", "parent": 168, "children": [], "start_point": {"row": 63, "column": 2}, "end_point": {"row": 63, "column": 13}}, {"id": 170, "type": "ERROR", "text": "::ptr verifyAndopenSetForUUID(const std:", "parent": 168, "children": [171, 172, 173], "start_point": {"row": 63, "column": 13}, "end_point": {"row": 63, "column": 53}}, {"id": 171, "type": "type_identifier", "text": "ptr", "parent": 170, "children": [], "start_point": {"row": 63, "column": 15}, "end_point": {"row": 63, "column": 18}}, {"id": 172, "type": "identifier", "text": "verifyAndopenSetForUUID", "parent": 170, "children": [], "start_point": {"row": 63, "column": 19}, "end_point": {"row": 63, "column": 42}}, {"id": 173, "type": "type_identifier", "text": "std", "parent": 170, "children": [], "start_point": {"row": 63, "column": 49}, "end_point": {"row": 63, "column": 52}}, {"id": 174, "type": "binary_expression", "text": "string& uuid", "parent": 168, "children": [175, 176], "start_point": {"row": 63, "column": 54}, "end_point": {"row": 63, "column": 66}}, {"id": 175, "type": "identifier", "text": "string", "parent": 174, "children": [], "start_point": {"row": 63, "column": 54}, "end_point": {"row": 63, "column": 60}}, {"id": 176, "type": "identifier", "text": "uuid", "parent": 174, "children": [], "start_point": {"row": 63, "column": 62}, "end_point": {"row": 63, "column": 66}}, {"id": 177, "type": "declaration", "text": "void workLoop();", "parent": 45, "children": [178, 179], "start_point": {"row": 64, "column": 2}, "end_point": {"row": 64, "column": 18}}, {"id": 178, "type": "primitive_type", "text": "void", "parent": 177, "children": [], "start_point": {"row": 64, "column": 2}, "end_point": {"row": 64, "column": 6}}, {"id": 179, "type": "function_declarator", "text": "workLoop()", "parent": 177, "children": [180, 181], "start_point": {"row": 64, "column": 7}, "end_point": {"row": 64, "column": 17}}, {"id": 180, "type": "identifier", "text": "workLoop", "parent": 179, "children": [], "start_point": {"row": 64, "column": 7}, "end_point": {"row": 64, "column": 15}}, {"id": 181, "type": "parameter_list", "text": "()", "parent": 179, "children": [], "start_point": {"row": 64, "column": 15}, "end_point": {"row": 64, "column": 17}}, {"id": 182, "type": "declaration", "text": "void onPurgeTimer(const boost::system::error_code& error);", "parent": 45, "children": [183, 184], "start_point": {"row": 66, "column": 2}, "end_point": {"row": 66, "column": 60}}, {"id": 183, "type": "primitive_type", "text": "void", "parent": 182, "children": [], "start_point": {"row": 66, "column": 2}, "end_point": {"row": 66, "column": 6}}, {"id": 184, "type": "function_declarator", "text": "onPurgeTimer(const boost::system::error_code& error)", "parent": 182, "children": [185, 186], "start_point": {"row": 66, "column": 7}, "end_point": {"row": 66, "column": 59}}, {"id": 185, "type": "identifier", "text": "onPurgeTimer", "parent": 184, "children": [], "start_point": {"row": 66, "column": 7}, "end_point": {"row": 66, "column": 19}}, {"id": 186, "type": "parameter_list", "text": "(const boost::system::error_code& error)", "parent": 184, "children": [187], "start_point": {"row": 66, "column": 19}, "end_point": {"row": 66, "column": 59}}, {"id": 187, "type": "parameter_declaration", "text": "const boost::system::error_code& error", "parent": 186, "children": [188, 189, 192], "start_point": {"row": 66, "column": 20}, "end_point": {"row": 66, "column": 58}}, {"id": 188, "type": "type_identifier", "text": "boost", "parent": 187, "children": [], "start_point": {"row": 66, "column": 26}, "end_point": {"row": 66, "column": 31}}, {"id": 189, "type": "ERROR", "text": "::system::error_code&", "parent": 187, "children": [190, 191], "start_point": {"row": 66, "column": 31}, "end_point": {"row": 66, "column": 52}}, {"id": 190, "type": "identifier", "text": "system", "parent": 189, "children": [], "start_point": {"row": 66, "column": 33}, "end_point": {"row": 66, "column": 39}}, {"id": 191, "type": "identifier", "text": "error_code", "parent": 189, "children": [], "start_point": {"row": 66, "column": 41}, "end_point": {"row": 66, "column": 51}}, {"id": 192, "type": "identifier", "text": "error", "parent": 187, "children": [], "start_point": {"row": 66, "column": 53}, "end_point": {"row": 66, "column": 58}}, {"id": 193, "type": "declaration", "text": "void unindexLocals(UuidListPtr uuidList, std::string uuidHead);", "parent": 45, "children": [194, 195], "start_point": {"row": 68, "column": 2}, "end_point": {"row": 68, "column": 65}}, {"id": 194, "type": "primitive_type", "text": "void", "parent": 193, "children": [], "start_point": {"row": 68, "column": 2}, "end_point": {"row": 68, "column": 6}}, {"id": 195, "type": "function_declarator", "text": "unindexLocals(UuidListPtr uuidList, std::string uuidHead)", "parent": 193, "children": [196, 197], "start_point": {"row": 68, "column": 7}, "end_point": {"row": 68, "column": 64}}, {"id": 196, "type": "identifier", "text": "unindexLocals", "parent": 195, "children": [], "start_point": {"row": 68, "column": 7}, "end_point": {"row": 68, "column": 20}}, {"id": 197, "type": "parameter_list", "text": "(UuidListPtr uuidList, std::string uuidHead)", "parent": 195, "children": [198, 201], "start_point": {"row": 68, "column": 20}, "end_point": {"row": 68, "column": 64}}, {"id": 198, "type": "parameter_declaration", "text": "UuidListPtr uuidList", "parent": 197, "children": [199, 200], "start_point": {"row": 68, "column": 21}, "end_point": {"row": 68, "column": 41}}, {"id": 199, "type": "type_identifier", "text": "UuidListPtr", "parent": 198, "children": [], "start_point": {"row": 68, "column": 21}, "end_point": {"row": 68, "column": 32}}, {"id": 200, "type": "identifier", "text": "uuidList", "parent": 198, "children": [], "start_point": {"row": 68, "column": 33}, "end_point": {"row": 68, "column": 41}}, {"id": 201, "type": "parameter_declaration", "text": "std::string uuidHead", "parent": 197, "children": [202, 203, 205], "start_point": {"row": 68, "column": 43}, "end_point": {"row": 68, "column": 63}}, {"id": 202, "type": "type_identifier", "text": "std", "parent": 201, "children": [], "start_point": {"row": 68, "column": 43}, "end_point": {"row": 68, "column": 46}}, {"id": 203, "type": "ERROR", "text": "::string", "parent": 201, "children": [204], "start_point": {"row": 68, "column": 46}, "end_point": {"row": 68, "column": 54}}, {"id": 204, "type": "identifier", "text": "string", "parent": 203, "children": [], "start_point": {"row": 68, "column": 48}, "end_point": {"row": 68, "column": 54}}, {"id": 205, "type": "identifier", "text": "uuidHead", "parent": 201, "children": [], "start_point": {"row": 68, "column": 55}, "end_point": {"row": 68, "column": 63}}, {"id": 206, "type": "declaration", "text": "void assetWriteFailed(std::string assetId, std::string reason);", "parent": 45, "children": [207, 208], "start_point": {"row": 70, "column": 2}, "end_point": {"row": 70, "column": 65}}, {"id": 207, "type": "primitive_type", "text": "void", "parent": 206, "children": [], "start_point": {"row": 70, "column": 2}, "end_point": {"row": 70, "column": 6}}, {"id": 208, "type": "function_declarator", "text": "assetWriteFailed(std::string assetId, std::string reason)", "parent": 206, "children": [209, 210], "start_point": {"row": 70, "column": 7}, "end_point": {"row": 70, "column": 64}}, {"id": 209, "type": "identifier", "text": "assetWriteFailed", "parent": 208, "children": [], "start_point": {"row": 70, "column": 7}, "end_point": {"row": 70, "column": 23}}, {"id": 210, "type": "parameter_list", "text": "(std::string assetId, std::string reason)", "parent": 208, "children": [211, 216], "start_point": {"row": 70, "column": 23}, "end_point": {"row": 70, "column": 64}}, {"id": 211, "type": "parameter_declaration", "text": "std::string assetId", "parent": 210, "children": [212, 213, 215], "start_point": {"row": 70, "column": 24}, "end_point": {"row": 70, "column": 43}}, {"id": 212, "type": "type_identifier", "text": "std", "parent": 211, "children": [], "start_point": {"row": 70, "column": 24}, "end_point": {"row": 70, "column": 27}}, {"id": 213, "type": "ERROR", "text": "::string", "parent": 211, "children": [214], "start_point": {"row": 70, "column": 27}, "end_point": {"row": 70, "column": 35}}, {"id": 214, "type": "identifier", "text": "string", "parent": 213, "children": [], "start_point": {"row": 70, "column": 29}, "end_point": {"row": 70, "column": 35}}, {"id": 215, "type": "identifier", "text": "assetId", "parent": 211, "children": [], "start_point": {"row": 70, "column": 36}, "end_point": {"row": 70, "column": 43}}, {"id": 216, "type": "parameter_declaration", "text": "std::string reason", "parent": 210, "children": [217, 218, 220], "start_point": {"row": 70, "column": 45}, "end_point": {"row": 70, "column": 63}}, {"id": 217, "type": "type_identifier", "text": "std", "parent": 216, "children": [], "start_point": {"row": 70, "column": 45}, "end_point": {"row": 70, "column": 48}}, {"id": 218, "type": "ERROR", "text": "::string", "parent": 216, "children": [219], "start_point": {"row": 70, "column": 48}, "end_point": {"row": 70, "column": 56}}, {"id": 219, "type": "identifier", "text": "string", "parent": 218, "children": [], "start_point": {"row": 70, "column": 50}, "end_point": {"row": 70, "column": 56}}, {"id": 220, "type": "identifier", "text": "reason", "parent": 216, "children": [], "start_point": {"row": 70, "column": 57}, "end_point": {"row": 70, "column": 63}}, {"id": 221, "type": "declaration", "text": "void ioLoopFailed(std::string reason);", "parent": 45, "children": [222, 223], "start_point": {"row": 71, "column": 2}, "end_point": {"row": 71, "column": 40}}, {"id": 222, "type": "primitive_type", "text": "void", "parent": 221, "children": [], "start_point": {"row": 71, "column": 2}, "end_point": {"row": 71, "column": 6}}, {"id": 223, "type": "function_declarator", "text": "ioLoopFailed(std::string reason)", "parent": 221, "children": [224, 225], "start_point": {"row": 71, "column": 7}, "end_point": {"row": 71, "column": 39}}, {"id": 224, "type": "identifier", "text": "ioLoopFailed", "parent": 223, "children": [], "start_point": {"row": 71, "column": 7}, "end_point": {"row": 71, "column": 19}}, {"id": 225, "type": "parameter_list", "text": "(std::string reason)", "parent": 223, "children": [226], "start_point": {"row": 71, "column": 19}, "end_point": {"row": 71, "column": 39}}, {"id": 226, "type": "parameter_declaration", "text": "std::string reason", "parent": 225, "children": [227, 228, 230], "start_point": {"row": 71, "column": 20}, "end_point": {"row": 71, "column": 38}}, {"id": 227, "type": "type_identifier", "text": "std", "parent": 226, "children": [], "start_point": {"row": 71, "column": 20}, "end_point": {"row": 71, "column": 23}}, {"id": 228, "type": "ERROR", "text": "::string", "parent": 226, "children": [229], "start_point": {"row": 71, "column": 23}, "end_point": {"row": 71, "column": 31}}, {"id": 229, "type": "identifier", "text": "string", "parent": 228, "children": [], "start_point": {"row": 71, "column": 25}, "end_point": {"row": 71, "column": 31}}, {"id": 230, "type": "identifier", "text": "reason", "parent": 226, "children": [], "start_point": {"row": 71, "column": 32}, "end_point": {"row": 71, "column": 38}}, {"id": 231, "type": "labeled_statement", "text": "protected:\n\t\tvoid performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback);", "parent": 45, "children": [232], "start_point": {"row": 73, "column": 1}, "end_point": {"row": 74, "column": 76}}, {"id": 232, "type": "declaration", "text": "void performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback);", "parent": 231, "children": [233, 234], "start_point": {"row": 74, "column": 2}, "end_point": {"row": 74, "column": 76}}, {"id": 233, "type": "primitive_type", "text": "void", "parent": 232, "children": [], "start_point": {"row": 74, "column": 2}, "end_point": {"row": 74, "column": 6}}, {"id": 234, "type": "function_declarator", "text": "performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback)", "parent": 232, "children": [235, 236], "start_point": {"row": 74, "column": 7}, "end_point": {"row": 74, "column": 75}}, {"id": 235, "type": "identifier", "text": "performDiskWrite", "parent": 234, "children": [], "start_point": {"row": 74, "column": 7}, "end_point": {"row": 74, "column": 23}}, {"id": 236, "type": "parameter_list", "text": "(Asset::ptr asset, AsyncStoreAssetCallback callback)", "parent": 234, "children": [237, 242], "start_point": {"row": 74, "column": 23}, "end_point": {"row": 74, "column": 75}}, {"id": 237, "type": "parameter_declaration", "text": "Asset::ptr asset", "parent": 236, "children": [238, 239, 241], "start_point": {"row": 74, "column": 24}, "end_point": {"row": 74, "column": 40}}, {"id": 238, "type": "type_identifier", "text": "Asset", "parent": 237, "children": [], "start_point": {"row": 74, "column": 24}, "end_point": {"row": 74, "column": 29}}, {"id": 239, "type": "ERROR", "text": "::ptr", "parent": 237, "children": [240], "start_point": {"row": 74, "column": 29}, "end_point": {"row": 74, "column": 34}}, {"id": 240, "type": "identifier", "text": "ptr", "parent": 239, "children": [], "start_point": {"row": 74, "column": 31}, "end_point": {"row": 74, "column": 34}}, {"id": 241, "type": "identifier", "text": "asset", "parent": 237, "children": [], "start_point": {"row": 74, "column": 35}, "end_point": {"row": 74, "column": 40}}, {"id": 242, "type": "parameter_declaration", "text": "AsyncStoreAssetCallback callback", "parent": 236, "children": [243, 244], "start_point": {"row": 74, "column": 42}, "end_point": {"row": 74, "column": 74}}, {"id": 243, "type": "type_identifier", "text": "AsyncStoreAssetCallback", "parent": 242, "children": [], "start_point": {"row": 74, "column": 42}, "end_point": {"row": 74, "column": 65}}, {"id": 244, "type": "identifier", "text": "callback", "parent": 242, "children": [], "start_point": {"row": 74, "column": 66}, "end_point": {"row": 74, "column": 74}}, {"id": 245, "type": "declaration", "text": "void performDiskRead(const std::string& assetId, AsyncGetAssetCallback callback);", "parent": 45, "children": [246, 247], "start_point": {"row": 75, "column": 2}, "end_point": {"row": 75, "column": 83}}, {"id": 246, "type": "primitive_type", "text": "void", "parent": 245, "children": [], "start_point": {"row": 75, "column": 2}, "end_point": {"row": 75, "column": 6}}, {"id": 247, "type": "function_declarator", "text": "performDiskRead(const std::string& assetId, AsyncGetAssetCallback callback)", "parent": 245, "children": [248, 249], "start_point": {"row": 75, "column": 7}, "end_point": {"row": 75, "column": 82}}, {"id": 248, "type": "identifier", "text": "performDiskRead", "parent": 247, "children": [], "start_point": {"row": 75, "column": 7}, "end_point": {"row": 75, "column": 22}}, {"id": 249, "type": "parameter_list", "text": "(const std::string& assetId, AsyncGetAssetCallback callback)", "parent": 247, "children": [250, 255], "start_point": {"row": 75, "column": 22}, "end_point": {"row": 75, "column": 82}}, {"id": 250, "type": "parameter_declaration", "text": "const std::string& assetId", "parent": 249, "children": [251, 252, 254], "start_point": {"row": 75, "column": 23}, "end_point": {"row": 75, "column": 49}}, {"id": 251, "type": "type_identifier", "text": "std", "parent": 250, "children": [], "start_point": {"row": 75, "column": 29}, "end_point": {"row": 75, "column": 32}}, {"id": 252, "type": "ERROR", "text": "::string&", "parent": 250, "children": [253], "start_point": {"row": 75, "column": 32}, "end_point": {"row": 75, "column": 41}}, {"id": 253, "type": "identifier", "text": "string", "parent": 252, "children": [], "start_point": {"row": 75, "column": 34}, "end_point": {"row": 75, "column": 40}}, {"id": 254, "type": "identifier", "text": "assetId", "parent": 250, "children": [], "start_point": {"row": 75, "column": 42}, "end_point": {"row": 75, "column": 49}}, {"id": 255, "type": "parameter_declaration", "text": "AsyncGetAssetCallback callback", "parent": 249, "children": [256, 257], "start_point": {"row": 75, "column": 51}, "end_point": {"row": 75, "column": 81}}, {"id": 256, "type": "type_identifier", "text": "AsyncGetAssetCallback", "parent": 255, "children": [], "start_point": {"row": 75, "column": 51}, "end_point": {"row": 75, "column": 72}}, {"id": 257, "type": "identifier", "text": "callback", "parent": 255, "children": [], "start_point": {"row": 75, "column": 73}, "end_point": {"row": 75, "column": 81}}, {"id": 258, "type": "declaration", "text": "void performDiskPurge(const std::string& assetId, AsyncAssetPurgeCallback callback);", "parent": 45, "children": [259, 260], "start_point": {"row": 76, "column": 2}, "end_point": {"row": 76, "column": 86}}, {"id": 259, "type": "primitive_type", "text": "void", "parent": 258, "children": [], "start_point": {"row": 76, "column": 2}, "end_point": {"row": 76, "column": 6}}, {"id": 260, "type": "function_declarator", "text": "performDiskPurge(const std::string& assetId, AsyncAssetPurgeCallback callback)", "parent": 258, "children": [261, 262], "start_point": {"row": 76, "column": 7}, "end_point": {"row": 76, "column": 85}}, {"id": 261, "type": "identifier", "text": "performDiskPurge", "parent": 260, "children": [], "start_point": {"row": 76, "column": 7}, "end_point": {"row": 76, "column": 23}}, {"id": 262, "type": "parameter_list", "text": "(const std::string& assetId, AsyncAssetPurgeCallback callback)", "parent": 260, "children": [263, 268], "start_point": {"row": 76, "column": 23}, "end_point": {"row": 76, "column": 85}}, {"id": 263, "type": "parameter_declaration", "text": "const std::string& assetId", "parent": 262, "children": [264, 265, 267], "start_point": {"row": 76, "column": 24}, "end_point": {"row": 76, "column": 50}}, {"id": 264, "type": "type_identifier", "text": "std", "parent": 263, "children": [], "start_point": {"row": 76, "column": 30}, "end_point": {"row": 76, "column": 33}}, {"id": 265, "type": "ERROR", "text": "::string&", "parent": 263, "children": [266], "start_point": {"row": 76, "column": 33}, "end_point": {"row": 76, "column": 42}}, {"id": 266, "type": "identifier", "text": "string", "parent": 265, "children": [], "start_point": {"row": 76, "column": 35}, "end_point": {"row": 76, "column": 41}}, {"id": 267, "type": "identifier", "text": "assetId", "parent": 263, "children": [], "start_point": {"row": 76, "column": 43}, "end_point": {"row": 76, "column": 50}}, {"id": 268, "type": "parameter_declaration", "text": "AsyncAssetPurgeCallback callback", "parent": 262, "children": [269, 270], "start_point": {"row": 76, "column": 52}, "end_point": {"row": 76, "column": 84}}, {"id": 269, "type": "type_identifier", "text": "AsyncAssetPurgeCallback", "parent": 268, "children": [], "start_point": {"row": 76, "column": 52}, "end_point": {"row": 76, "column": 75}}, {"id": 270, "type": "identifier", "text": "callback", "parent": 268, "children": [], "start_point": {"row": 76, "column": 76}, "end_point": {"row": 76, "column": 84}}, {"id": 271, "type": "declaration", "text": "void performDiskPurgeLocals(const std::string& assetId);", "parent": 45, "children": [272, 273], "start_point": {"row": 77, "column": 2}, "end_point": {"row": 77, "column": 58}}, {"id": 272, "type": "primitive_type", "text": "void", "parent": 271, "children": [], "start_point": {"row": 77, "column": 2}, "end_point": {"row": 77, "column": 6}}, {"id": 273, "type": "function_declarator", "text": "performDiskPurgeLocals(const std::string& assetId)", "parent": 271, "children": [274, 275], "start_point": {"row": 77, "column": 7}, "end_point": {"row": 77, "column": 57}}, {"id": 274, "type": "identifier", "text": "performDiskPurgeLocals", "parent": 273, "children": [], "start_point": {"row": 77, "column": 7}, "end_point": {"row": 77, "column": 29}}, {"id": 275, "type": "parameter_list", "text": "(const std::string& assetId)", "parent": 273, "children": [276], "start_point": {"row": 77, "column": 29}, "end_point": {"row": 77, "column": 57}}, {"id": 276, "type": "parameter_declaration", "text": "const std::string& assetId", "parent": 275, "children": [277, 278, 280], "start_point": {"row": 77, "column": 30}, "end_point": {"row": 77, "column": 56}}, {"id": 277, "type": "type_identifier", "text": "std", "parent": 276, "children": [], "start_point": {"row": 77, "column": 36}, "end_point": {"row": 77, "column": 39}}, {"id": 278, "type": "ERROR", "text": "::string&", "parent": 276, "children": [279], "start_point": {"row": 77, "column": 39}, "end_point": {"row": 77, "column": 48}}, {"id": 279, "type": "identifier", "text": "string", "parent": 278, "children": [], "start_point": {"row": 77, "column": 41}, "end_point": {"row": 77, "column": 47}}, {"id": 280, "type": "identifier", "text": "assetId", "parent": 276, "children": [], "start_point": {"row": 77, "column": 49}, "end_point": {"row": 77, "column": 56}}, {"id": 281, "type": "declaration", "text": "void performLocalsPhysicalDeletion(const std::string& uuidHead);", "parent": 45, "children": [282, 283], "start_point": {"row": 78, "column": 2}, "end_point": {"row": 78, "column": 66}}, {"id": 282, "type": "primitive_type", "text": "void", "parent": 281, "children": [], "start_point": {"row": 78, "column": 2}, "end_point": {"row": 78, "column": 6}}, {"id": 283, "type": "function_declarator", "text": "performLocalsPhysicalDeletion(const std::string& uuidHead)", "parent": 281, "children": [284, 285], "start_point": {"row": 78, "column": 7}, "end_point": {"row": 78, "column": 65}}, {"id": 284, "type": "identifier", "text": "performLocalsPhysicalDeletion", "parent": 283, "children": [], "start_point": {"row": 78, "column": 7}, "end_point": {"row": 78, "column": 36}}, {"id": 285, "type": "parameter_list", "text": "(const std::string& uuidHead)", "parent": 283, "children": [286], "start_point": {"row": 78, "column": 36}, "end_point": {"row": 78, "column": 65}}, {"id": 286, "type": "parameter_declaration", "text": "const std::string& uuidHead", "parent": 285, "children": [287, 288, 290], "start_point": {"row": 78, "column": 37}, "end_point": {"row": 78, "column": 64}}, {"id": 287, "type": "type_identifier", "text": "std", "parent": 286, "children": [], "start_point": {"row": 78, "column": 43}, "end_point": {"row": 78, "column": 46}}, {"id": 288, "type": "ERROR", "text": "::string&", "parent": 286, "children": [289], "start_point": {"row": 78, "column": 46}, "end_point": {"row": 78, "column": 55}}, {"id": 289, "type": "identifier", "text": "string", "parent": 288, "children": [], "start_point": {"row": 78, "column": 48}, "end_point": {"row": 78, "column": 54}}, {"id": 290, "type": "identifier", "text": "uuidHead", "parent": 286, "children": [], "start_point": {"row": 78, "column": 56}, "end_point": {"row": 78, "column": 64}}, {"id": 291, "type": "ERROR", "text": "void performGetStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback)", "parent": 45, "children": [292, 293], "start_point": {"row": 79, "column": 2}, "end_point": {"row": 79, "column": 107}}, {"id": 292, "type": "primitive_type", "text": "void", "parent": 291, "children": [], "start_point": {"row": 79, "column": 2}, "end_point": {"row": 79, "column": 6}}, {"id": 293, "type": "function_declarator", "text": "performGetStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback", "parent": 291, "children": [294, 295, 310, 312], "start_point": {"row": 79, "column": 7}, "end_point": {"row": 79, "column": 106}}, {"id": 294, "type": "identifier", "text": "performGetStatus", "parent": 293, "children": [], "start_point": {"row": 79, "column": 7}, "end_point": {"row": 79, "column": 23}}, {"id": 295, "type": "parameter_list", "text": "(boost::shared_ptr<std::ostream> journal, boost::function<void()", "parent": 293, "children": [296, 305, 307], "start_point": {"row": 79, "column": 23}, "end_point": {"row": 79, "column": 87}}, {"id": 296, "type": "parameter_declaration", "text": "boost::shared_ptr<std::ostream> journal", "parent": 295, "children": [297, 298, 304], "start_point": {"row": 79, "column": 24}, "end_point": {"row": 79, "column": 63}}, {"id": 297, "type": "type_identifier", "text": "boost", "parent": 296, "children": [], "start_point": {"row": 79, "column": 24}, "end_point": {"row": 79, "column": 29}}, {"id": 298, "type": "ERROR", "text": "::shared_ptr<std::ostream>", "parent": 296, "children": [299, 300, 301, 302, 303], "start_point": {"row": 79, "column": 29}, "end_point": {"row": 79, "column": 55}}, {"id": 299, "type": "identifier", "text": "shared_ptr", "parent": 298, "children": [], "start_point": {"row": 79, "column": 31}, "end_point": {"row": 79, "column": 41}}, {"id": 300, "type": "<", "text": "<", "parent": 298, "children": [], "start_point": {"row": 79, "column": 41}, "end_point": {"row": 79, "column": 42}}, {"id": 301, "type": "identifier", "text": "std", "parent": 298, "children": [], "start_point": {"row": 79, "column": 42}, "end_point": {"row": 79, "column": 45}}, {"id": 302, "type": "identifier", "text": "ostream", "parent": 298, "children": [], "start_point": {"row": 79, "column": 47}, "end_point": {"row": 79, "column": 54}}, {"id": 303, "type": ">", "text": ">", "parent": 298, "children": [], "start_point": {"row": 79, "column": 54}, "end_point": {"row": 79, "column": 55}}, {"id": 304, "type": "identifier", "text": "journal", "parent": 296, "children": [], "start_point": {"row": 79, "column": 56}, "end_point": {"row": 79, "column": 63}}, {"id": 305, "type": "parameter_declaration", "text": "boost::function", "parent": 295, "children": [306], "start_point": {"row": 79, "column": 65}, "end_point": {"row": 79, "column": 80}}, {"id": 306, "type": "type_identifier", "text": "boost", "parent": 305, "children": [], "start_point": {"row": 79, "column": 65}, "end_point": {"row": 79, "column": 70}}, {"id": 307, "type": "ERROR", "text": "<void(", "parent": 295, "children": [308, 309], "start_point": {"row": 79, "column": 80}, "end_point": {"row": 79, "column": 86}}, {"id": 308, "type": "<", "text": "<", "parent": 307, "children": [], "start_point": {"row": 79, "column": 80}, "end_point": {"row": 79, "column": 81}}, {"id": 309, "type": "primitive_type", "text": "void", "parent": 307, "children": [], "start_point": {"row": 79, "column": 81}, "end_point": {"row": 79, "column": 85}}, {"id": 310, "type": "ERROR", "text": ">", "parent": 293, "children": [311], "start_point": {"row": 79, "column": 87}, "end_point": {"row": 79, "column": 88}}, {"id": 311, "type": ">", "text": ">", "parent": 310, "children": [], "start_point": {"row": 79, "column": 87}, "end_point": {"row": 79, "column": 88}}, {"id": 312, "type": "identifier", "text": "completedCallback", "parent": 293, "children": [], "start_point": {"row": 79, "column": 89}, "end_point": {"row": 79, "column": 106}}, {"id": 313, "type": "ERROR", "text": "void performGetStoredAssetIds(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback)", "parent": 45, "children": [314, 315], "start_point": {"row": 80, "column": 2}, "end_point": {"row": 80, "column": 135}}, {"id": 314, "type": "primitive_type", "text": "void", "parent": 313, "children": [], "start_point": {"row": 80, "column": 2}, "end_point": {"row": 80, "column": 6}}, {"id": 315, "type": "function_declarator", "text": "performGetStoredAssetIds(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback", "parent": 313, "children": [316, 317, 337, 339], "start_point": {"row": 80, "column": 7}, "end_point": {"row": 80, "column": 134}}, {"id": 316, "type": "identifier", "text": "performGetStoredAssetIds", "parent": 315, "children": [], "start_point": {"row": 80, "column": 7}, "end_point": {"row": 80, "column": 31}}, {"id": 317, "type": "parameter_list", "text": "(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()", "parent": 315, "children": [318, 323, 332, 334], "start_point": {"row": 80, "column": 31}, "end_point": {"row": 80, "column": 115}}, {"id": 318, "type": "parameter_declaration", "text": "std::string prefix", "parent": 317, "children": [319, 320, 322], "start_point": {"row": 80, "column": 32}, "end_point": {"row": 80, "column": 50}}, {"id": 319, "type": "type_identifier", "text": "std", "parent": 318, "children": [], "start_point": {"row": 80, "column": 32}, "end_point": {"row": 80, "column": 35}}, {"id": 320, "type": "ERROR", "text": "::string", "parent": 318, "children": [321], "start_point": {"row": 80, "column": 35}, "end_point": {"row": 80, "column": 43}}, {"id": 321, "type": "identifier", "text": "string", "parent": 320, "children": [], "start_point": {"row": 80, "column": 37}, "end_point": {"row": 80, "column": 43}}, {"id": 322, "type": "identifier", "text": "prefix", "parent": 318, "children": [], "start_point": {"row": 80, "column": 44}, "end_point": {"row": 80, "column": 50}}, {"id": 323, "type": "parameter_declaration", "text": "boost::shared_ptr<std::ostream> journal", "parent": 317, "children": [324, 325, 331], "start_point": {"row": 80, "column": 52}, "end_point": {"row": 80, "column": 91}}, {"id": 324, "type": "type_identifier", "text": "boost", "parent": 323, "children": [], "start_point": {"row": 80, "column": 52}, "end_point": {"row": 80, "column": 57}}, {"id": 325, "type": "ERROR", "text": "::shared_ptr<std::ostream>", "parent": 323, "children": [326, 327, 328, 329, 330], "start_point": {"row": 80, "column": 57}, "end_point": {"row": 80, "column": 83}}, {"id": 326, "type": "identifier", "text": "shared_ptr", "parent": 325, "children": [], "start_point": {"row": 80, "column": 59}, "end_point": {"row": 80, "column": 69}}, {"id": 327, "type": "<", "text": "<", "parent": 325, "children": [], "start_point": {"row": 80, "column": 69}, "end_point": {"row": 80, "column": 70}}, {"id": 328, "type": "identifier", "text": "std", "parent": 325, "children": [], "start_point": {"row": 80, "column": 70}, "end_point": {"row": 80, "column": 73}}, {"id": 329, "type": "identifier", "text": "ostream", "parent": 325, "children": [], "start_point": {"row": 80, "column": 75}, "end_point": {"row": 80, "column": 82}}, {"id": 330, "type": ">", "text": ">", "parent": 325, "children": [], "start_point": {"row": 80, "column": 82}, "end_point": {"row": 80, "column": 83}}, {"id": 331, "type": "identifier", "text": "journal", "parent": 323, "children": [], "start_point": {"row": 80, "column": 84}, "end_point": {"row": 80, "column": 91}}, {"id": 332, "type": "parameter_declaration", "text": "boost::function", "parent": 317, "children": [333], "start_point": {"row": 80, "column": 93}, "end_point": {"row": 80, "column": 108}}, {"id": 333, "type": "type_identifier", "text": "boost", "parent": 332, "children": [], "start_point": {"row": 80, "column": 93}, "end_point": {"row": 80, "column": 98}}, {"id": 334, "type": "ERROR", "text": "<void(", "parent": 317, "children": [335, 336], "start_point": {"row": 80, "column": 108}, "end_point": {"row": 80, "column": 114}}, {"id": 335, "type": "<", "text": "<", "parent": 334, "children": [], "start_point": {"row": 80, "column": 108}, "end_point": {"row": 80, "column": 109}}, {"id": 336, "type": "primitive_type", "text": "void", "parent": 334, "children": [], "start_point": {"row": 80, "column": 109}, "end_point": {"row": 80, "column": 113}}, {"id": 337, "type": "ERROR", "text": ">", "parent": 315, "children": [338], "start_point": {"row": 80, "column": 115}, "end_point": {"row": 80, "column": 116}}, {"id": 338, "type": ">", "text": ">", "parent": 337, "children": [], "start_point": {"row": 80, "column": 115}, "end_point": {"row": 80, "column": 116}}, {"id": 339, "type": "identifier", "text": "completedCallback", "parent": 315, "children": [], "start_point": {"row": 80, "column": 117}, "end_point": {"row": 80, "column": 134}}, {"id": 340, "type": "labeled_statement", "text": "public:\n\t\tfriend class AssetGetRequest;", "parent": 45, "children": [341], "start_point": {"row": 82, "column": 1}, "end_point": {"row": 83, "column": 31}}, {"id": 341, "type": "declaration", "text": "friend class AssetGetRequest;", "parent": 340, "children": [342, 343], "start_point": {"row": 83, "column": 2}, "end_point": {"row": 83, "column": 31}}, {"id": 342, "type": "type_identifier", "text": "friend", "parent": 341, "children": [], "start_point": {"row": 83, "column": 2}, "end_point": {"row": 83, "column": 8}}, {"id": 343, "type": "identifier", "text": "AssetGetRequest", "parent": 341, "children": [], "start_point": {"row": 83, "column": 15}, "end_point": {"row": 83, "column": 30}}, {"id": 344, "type": "declaration", "text": "friend class AssetPutRequest;", "parent": 45, "children": [345, 346], "start_point": {"row": 84, "column": 2}, "end_point": {"row": 84, "column": 31}}, {"id": 345, "type": "type_identifier", "text": "friend", "parent": 344, "children": [], "start_point": {"row": 84, "column": 2}, "end_point": {"row": 84, "column": 8}}, {"id": 346, "type": "identifier", "text": "AssetPutRequest", "parent": 344, "children": [], "start_point": {"row": 84, "column": 15}, "end_point": {"row": 84, "column": 30}}, {"id": 347, "type": "declaration", "text": "friend class AssetPurgeRequest;", "parent": 45, "children": [348, 349], "start_point": {"row": 85, "column": 2}, "end_point": {"row": 85, "column": 33}}, {"id": 348, "type": "type_identifier", "text": "friend", "parent": 347, "children": [], "start_point": {"row": 85, "column": 2}, "end_point": {"row": 85, "column": 8}}, {"id": 349, "type": "identifier", "text": "AssetPurgeRequest", "parent": 347, "children": [], "start_point": {"row": 85, "column": 15}, "end_point": {"row": 85, "column": 32}}, {"id": 350, "type": "declaration", "text": "friend class DeleteLocalStorageRequest;", "parent": 45, "children": [351, 352], "start_point": {"row": 86, "column": 2}, "end_point": {"row": 86, "column": 41}}, {"id": 351, "type": "type_identifier", "text": "friend", "parent": 350, "children": [], "start_point": {"row": 86, "column": 2}, "end_point": {"row": 86, "column": 8}}, {"id": 352, "type": "identifier", "text": "DeleteLocalStorageRequest", "parent": 350, "children": [], "start_point": {"row": 86, "column": 15}, "end_point": {"row": 86, "column": 40}}, {"id": 353, "type": "declaration", "text": "friend class CollectStatusRequest;", "parent": 45, "children": [354, 355], "start_point": {"row": 87, "column": 2}, "end_point": {"row": 87, "column": 36}}, {"id": 354, "type": "type_identifier", "text": "friend", "parent": 353, "children": [], "start_point": {"row": 87, "column": 2}, "end_point": {"row": 87, "column": 8}}, {"id": 355, "type": "identifier", "text": "CollectStatusRequest", "parent": 353, "children": [], "start_point": {"row": 87, "column": 15}, "end_point": {"row": 87, "column": 35}}, {"id": 356, "type": "declaration", "text": "friend class GetStoredAssetIdsRequest;", "parent": 45, "children": [357, 358], "start_point": {"row": 88, "column": 2}, "end_point": {"row": 88, "column": 40}}, {"id": 357, "type": "type_identifier", "text": "friend", "parent": 356, "children": [], "start_point": {"row": 88, "column": 2}, "end_point": {"row": 88, "column": 8}}, {"id": 358, "type": "identifier", "text": "GetStoredAssetIdsRequest", "parent": 356, "children": [], "start_point": {"row": 88, "column": 15}, "end_point": {"row": 88, "column": 39}}, {"id": 359, "type": "labeled_statement", "text": "public:\n\t\tVFSBackend(const std::string& storageRoot, bool enablePurge, boost::asio::io_service& ioService,\n\t\t\tPushReplicationService::ptr pushRepl);", "parent": 45, "children": [360], "start_point": {"row": 90, "column": 1}, "end_point": {"row": 92, "column": 41}}, {"id": 360, "type": "labeled_statement", "text": "VFSBackend(const std::string& storageRoot, bool enablePurge, boost::asio::io_service& ioService,\n\t\t\tPushReplicationService::ptr pushRepl);", "parent": 359, "children": [361, 362, 374], "start_point": {"row": 91, "column": 2}, "end_point": {"row": 92, "column": 41}}, {"id": 361, "type": "statement_identifier", "text": "VFSBackend", "parent": 360, "children": [], "start_point": {"row": 91, "column": 2}, "end_point": {"row": 91, "column": 12}}, {"id": 362, "type": "ERROR", "text": "(const std::string& storageRoot, bool enablePurge, boost:", "parent": 360, "children": [363, 365], "start_point": {"row": 91, "column": 12}, "end_point": {"row": 91, "column": 69}}, {"id": 363, "type": "type_descriptor", "text": "const std", "parent": 362, "children": [364], "start_point": {"row": 91, "column": 13}, "end_point": {"row": 91, "column": 22}}, {"id": 364, "type": "type_identifier", "text": "std", "parent": 363, "children": [], "start_point": {"row": 91, "column": 19}, "end_point": {"row": 91, "column": 22}}, {"id": 365, "type": "comma_expression", "text": "string& storageRoot, bool enablePurge, boost", "parent": 362, "children": [366, 369, 371], "start_point": {"row": 91, "column": 24}, "end_point": {"row": 91, "column": 68}}, {"id": 366, "type": "binary_expression", "text": "string& storageRoot", "parent": 365, "children": [367, 368], "start_point": {"row": 91, "column": 24}, "end_point": {"row": 91, "column": 43}}, {"id": 367, "type": "identifier", "text": "string", "parent": 366, "children": [], "start_point": {"row": 91, "column": 24}, "end_point": {"row": 91, "column": 30}}, {"id": 368, "type": "identifier", "text": "storageRoot", "parent": 366, "children": [], "start_point": {"row": 91, "column": 32}, "end_point": {"row": 91, "column": 43}}, {"id": 369, "type": "ERROR", "text": "bool", "parent": 365, "children": [370], "start_point": {"row": 91, "column": 45}, "end_point": {"row": 91, "column": 49}}, {"id": 370, "type": "identifier", "text": "bool", "parent": 369, "children": [], "start_point": {"row": 91, "column": 45}, "end_point": {"row": 91, "column": 49}}, {"id": 371, "type": "comma_expression", "text": "enablePurge, boost", "parent": 365, "children": [372, 373], "start_point": {"row": 91, "column": 50}, "end_point": {"row": 91, "column": 68}}, {"id": 372, "type": "identifier", "text": "enablePurge", "parent": 371, "children": [], "start_point": {"row": 91, "column": 50}, "end_point": {"row": 91, "column": 61}}, {"id": 373, "type": "identifier", "text": "boost", "parent": 371, "children": [], "start_point": {"row": 91, "column": 63}, "end_point": {"row": 91, "column": 68}}, {"id": 374, "type": "labeled_statement", "text": "asio::io_service& ioService,\n\t\t\tPushReplicationService::ptr pushRepl);", "parent": 360, "children": [375, 376, 382], "start_point": {"row": 91, "column": 70}, "end_point": {"row": 92, "column": 41}}, {"id": 375, "type": "statement_identifier", "text": "asio", "parent": 374, "children": [], "start_point": {"row": 91, "column": 70}, "end_point": {"row": 91, "column": 74}}, {"id": 376, "type": "ERROR", "text": "::io_service& ioService,\n\t\t\tPushReplicationService:", "parent": 374, "children": [377], "start_point": {"row": 91, "column": 74}, "end_point": {"row": 92, "column": 26}}, {"id": 377, "type": "comma_expression", "text": "io_service& ioService,\n\t\t\tPushReplicationService", "parent": 376, "children": [378, 381], "start_point": {"row": 91, "column": 76}, "end_point": {"row": 92, "column": 25}}, {"id": 378, "type": "binary_expression", "text": "io_service& ioService", "parent": 377, "children": [379, 380], "start_point": {"row": 91, "column": 76}, "end_point": {"row": 91, "column": 97}}, {"id": 379, "type": "identifier", "text": "io_service", "parent": 378, "children": [], "start_point": {"row": 91, "column": 76}, "end_point": {"row": 91, "column": 86}}, {"id": 380, "type": "identifier", "text": "ioService", "parent": 378, "children": [], "start_point": {"row": 91, "column": 88}, "end_point": {"row": 91, "column": 97}}, {"id": 381, "type": "identifier", "text": "PushReplicationService", "parent": 377, "children": [], "start_point": {"row": 92, "column": 3}, "end_point": {"row": 92, "column": 25}}, {"id": 382, "type": "declaration", "text": "ptr pushRepl);", "parent": 374, "children": [383, 384], "start_point": {"row": 92, "column": 27}, "end_point": {"row": 92, "column": 41}}, {"id": 383, "type": "type_identifier", "text": "ptr", "parent": 382, "children": [], "start_point": {"row": 92, "column": 27}, "end_point": {"row": 92, "column": 30}}, {"id": 384, "type": "identifier", "text": "pushRepl", "parent": 382, "children": [], "start_point": {"row": 92, "column": 31}, "end_point": {"row": 92, "column": 39}}, {"id": 385, "type": "declaration", "text": "virtual ~VFSBackend();", "parent": 45, "children": [386, 387, 389], "start_point": {"row": 93, "column": 2}, "end_point": {"row": 93, "column": 24}}, {"id": 386, "type": "type_identifier", "text": "virtual", "parent": 385, "children": [], "start_point": {"row": 93, "column": 2}, "end_point": {"row": 93, "column": 9}}, {"id": 387, "type": "ERROR", "text": "~", "parent": 385, "children": [388], "start_point": {"row": 93, "column": 10}, "end_point": {"row": 93, "column": 11}}, {"id": 388, "type": "~", "text": "~", "parent": 387, "children": [], "start_point": {"row": 93, "column": 10}, "end_point": {"row": 93, "column": 11}}, {"id": 389, "type": "function_declarator", "text": "VFSBackend()", "parent": 385, "children": [390, 391], "start_point": {"row": 93, "column": 11}, "end_point": {"row": 93, "column": 23}}, {"id": 390, "type": "identifier", "text": "VFSBackend", "parent": 389, "children": [], "start_point": {"row": 93, "column": 11}, "end_point": {"row": 93, "column": 21}}, {"id": 391, "type": "parameter_list", "text": "()", "parent": 389, "children": [], "start_point": {"row": 93, "column": 21}, "end_point": {"row": 93, "column": 23}}, {"id": 392, "type": "declaration", "text": "virtual Asset::ptr getAsset(const std::string& uuid);", "parent": 45, "children": [393, 394, 397], "start_point": {"row": 95, "column": 2}, "end_point": {"row": 95, "column": 55}}, {"id": 393, "type": "type_identifier", "text": "virtual", "parent": 392, "children": [], "start_point": {"row": 95, "column": 2}, "end_point": {"row": 95, "column": 9}}, {"id": 394, "type": "ERROR", "text": "Asset::ptr", "parent": 392, "children": [395, 396], "start_point": {"row": 95, "column": 10}, "end_point": {"row": 95, "column": 20}}, {"id": 395, "type": "identifier", "text": "Asset", "parent": 394, "children": [], "start_point": {"row": 95, "column": 10}, "end_point": {"row": 95, "column": 15}}, {"id": 396, "type": "identifier", "text": "ptr", "parent": 394, "children": [], "start_point": {"row": 95, "column": 17}, "end_point": {"row": 95, "column": 20}}, {"id": 397, "type": "function_declarator", "text": "getAsset(const std::string& uuid)", "parent": 392, "children": [398, 399], "start_point": {"row": 95, "column": 21}, "end_point": {"row": 95, "column": 54}}, {"id": 398, "type": "identifier", "text": "getAsset", "parent": 397, "children": [], "start_point": {"row": 95, "column": 21}, "end_point": {"row": 95, "column": 29}}, {"id": 399, "type": "parameter_list", "text": "(const std::string& uuid)", "parent": 397, "children": [400], "start_point": {"row": 95, "column": 29}, "end_point": {"row": 95, "column": 54}}, {"id": 400, "type": "parameter_declaration", "text": "const std::string& uuid", "parent": 399, "children": [401, 402, 404], "start_point": {"row": 95, "column": 30}, "end_point": {"row": 95, "column": 53}}, {"id": 401, "type": "type_identifier", "text": "std", "parent": 400, "children": [], "start_point": {"row": 95, "column": 36}, "end_point": {"row": 95, "column": 39}}, {"id": 402, "type": "ERROR", "text": "::string&", "parent": 400, "children": [403], "start_point": {"row": 95, "column": 39}, "end_point": {"row": 95, "column": 48}}, {"id": 403, "type": "identifier", "text": "string", "parent": 402, "children": [], "start_point": {"row": 95, "column": 41}, "end_point": {"row": 95, "column": 47}}, {"id": 404, "type": "identifier", "text": "uuid", "parent": 400, "children": [], "start_point": {"row": 95, "column": 49}, "end_point": {"row": 95, "column": 53}}, {"id": 405, "type": "declaration", "text": "virtual void storeAsset(Asset::ptr asset);", "parent": 45, "children": [406, 407, 409], "start_point": {"row": 96, "column": 2}, "end_point": {"row": 96, "column": 44}}, {"id": 406, "type": "type_identifier", "text": "virtual", "parent": 405, "children": [], "start_point": {"row": 96, "column": 2}, "end_point": {"row": 96, "column": 9}}, {"id": 407, "type": "ERROR", "text": "void", "parent": 405, "children": [408], "start_point": {"row": 96, "column": 10}, "end_point": {"row": 96, "column": 14}}, {"id": 408, "type": "identifier", "text": "void", "parent": 407, "children": [], "start_point": {"row": 96, "column": 10}, "end_point": {"row": 96, "column": 14}}, {"id": 409, "type": "function_declarator", "text": "storeAsset(Asset::ptr asset)", "parent": 405, "children": [410, 411], "start_point": {"row": 96, "column": 15}, "end_point": {"row": 96, "column": 43}}, {"id": 410, "type": "identifier", "text": "storeAsset", "parent": 409, "children": [], "start_point": {"row": 96, "column": 15}, "end_point": {"row": 96, "column": 25}}, {"id": 411, "type": "parameter_list", "text": "(Asset::ptr asset)", "parent": 409, "children": [412], "start_point": {"row": 96, "column": 25}, "end_point": {"row": 96, "column": 43}}, {"id": 412, "type": "parameter_declaration", "text": "Asset::ptr asset", "parent": 411, "children": [413, 414, 416], "start_point": {"row": 96, "column": 26}, "end_point": {"row": 96, "column": 42}}, {"id": 413, "type": "type_identifier", "text": "Asset", "parent": 412, "children": [], "start_point": {"row": 96, "column": 26}, "end_point": {"row": 96, "column": 31}}, {"id": 414, "type": "ERROR", "text": "::ptr", "parent": 412, "children": [415], "start_point": {"row": 96, "column": 31}, "end_point": {"row": 96, "column": 36}}, {"id": 415, "type": "identifier", "text": "ptr", "parent": 414, "children": [], "start_point": {"row": 96, "column": 33}, "end_point": {"row": 96, "column": 36}}, {"id": 416, "type": "identifier", "text": "asset", "parent": 412, "children": [], "start_point": {"row": 96, "column": 37}, "end_point": {"row": 96, "column": 42}}, {"id": 417, "type": "declaration", "text": "virtual bool assetExists(const std::string& uuid);", "parent": 45, "children": [418, 419, 421], "start_point": {"row": 97, "column": 2}, "end_point": {"row": 97, "column": 52}}, {"id": 418, "type": "type_identifier", "text": "virtual", "parent": 417, "children": [], "start_point": {"row": 97, "column": 2}, "end_point": {"row": 97, "column": 9}}, {"id": 419, "type": "ERROR", "text": "bool", "parent": 417, "children": [420], "start_point": {"row": 97, "column": 10}, "end_point": {"row": 97, "column": 14}}, {"id": 420, "type": "identifier", "text": "bool", "parent": 419, "children": [], "start_point": {"row": 97, "column": 10}, "end_point": {"row": 97, "column": 14}}, {"id": 421, "type": "function_declarator", "text": "assetExists(const std::string& uuid)", "parent": 417, "children": [422, 423], "start_point": {"row": 97, "column": 15}, "end_point": {"row": 97, "column": 51}}, {"id": 422, "type": "identifier", "text": "assetExists", "parent": 421, "children": [], "start_point": {"row": 97, "column": 15}, "end_point": {"row": 97, "column": 26}}, {"id": 423, "type": "parameter_list", "text": "(const std::string& uuid)", "parent": 421, "children": [424], "start_point": {"row": 97, "column": 26}, "end_point": {"row": 97, "column": 51}}, {"id": 424, "type": "parameter_declaration", "text": "const std::string& uuid", "parent": 423, "children": [425, 426, 428], "start_point": {"row": 97, "column": 27}, "end_point": {"row": 97, "column": 50}}, {"id": 425, "type": "type_identifier", "text": "std", "parent": 424, "children": [], "start_point": {"row": 97, "column": 33}, "end_point": {"row": 97, "column": 36}}, {"id": 426, "type": "ERROR", "text": "::string&", "parent": 424, "children": [427], "start_point": {"row": 97, "column": 36}, "end_point": {"row": 97, "column": 45}}, {"id": 427, "type": "identifier", "text": "string", "parent": 426, "children": [], "start_point": {"row": 97, "column": 38}, "end_point": {"row": 97, "column": 44}}, {"id": 428, "type": "identifier", "text": "uuid", "parent": 424, "children": [], "start_point": {"row": 97, "column": 46}, "end_point": {"row": 97, "column": 50}}, {"id": 429, "type": "declaration", "text": "virtual void purgeAsset(const std::string& uuid);", "parent": 45, "children": [430, 431, 433], "start_point": {"row": 98, "column": 2}, "end_point": {"row": 98, "column": 51}}, {"id": 430, "type": "type_identifier", "text": "virtual", "parent": 429, "children": [], "start_point": {"row": 98, "column": 2}, "end_point": {"row": 98, "column": 9}}, {"id": 431, "type": "ERROR", "text": "void", "parent": 429, "children": [432], "start_point": {"row": 98, "column": 10}, "end_point": {"row": 98, "column": 14}}, {"id": 432, "type": "identifier", "text": "void", "parent": 431, "children": [], "start_point": {"row": 98, "column": 10}, "end_point": {"row": 98, "column": 14}}, {"id": 433, "type": "function_declarator", "text": "purgeAsset(const std::string& uuid)", "parent": 429, "children": [434, 435], "start_point": {"row": 98, "column": 15}, "end_point": {"row": 98, "column": 50}}, {"id": 434, "type": "identifier", "text": "purgeAsset", "parent": 433, "children": [], "start_point": {"row": 98, "column": 15}, "end_point": {"row": 98, "column": 25}}, {"id": 435, "type": "parameter_list", "text": "(const std::string& uuid)", "parent": 433, "children": [436], "start_point": {"row": 98, "column": 25}, "end_point": {"row": 98, "column": 50}}, {"id": 436, "type": "parameter_declaration", "text": "const std::string& uuid", "parent": 435, "children": [437, 438, 440], "start_point": {"row": 98, "column": 26}, "end_point": {"row": 98, "column": 49}}, {"id": 437, "type": "type_identifier", "text": "std", "parent": 436, "children": [], "start_point": {"row": 98, "column": 32}, "end_point": {"row": 98, "column": 35}}, {"id": 438, "type": "ERROR", "text": "::string&", "parent": 436, "children": [439], "start_point": {"row": 98, "column": 35}, "end_point": {"row": 98, "column": 44}}, {"id": 439, "type": "identifier", "text": "string", "parent": 438, "children": [], "start_point": {"row": 98, "column": 37}, "end_point": {"row": 98, "column": 43}}, {"id": 440, "type": "identifier", "text": "uuid", "parent": 436, "children": [], "start_point": {"row": 98, "column": 45}, "end_point": {"row": 98, "column": 49}}, {"id": 441, "type": "declaration", "text": "virtual void getAsset(const std::string& uuid, AsyncGetAssetCallback callBack);", "parent": 45, "children": [442, 443, 445], "start_point": {"row": 100, "column": 2}, "end_point": {"row": 100, "column": 81}}, {"id": 442, "type": "type_identifier", "text": "virtual", "parent": 441, "children": [], "start_point": {"row": 100, "column": 2}, "end_point": {"row": 100, "column": 9}}, {"id": 443, "type": "ERROR", "text": "void", "parent": 441, "children": [444], "start_point": {"row": 100, "column": 10}, "end_point": {"row": 100, "column": 14}}, {"id": 444, "type": "identifier", "text": "void", "parent": 443, "children": [], "start_point": {"row": 100, "column": 10}, "end_point": {"row": 100, "column": 14}}, {"id": 445, "type": "function_declarator", "text": "getAsset(const std::string& uuid, AsyncGetAssetCallback callBack)", "parent": 441, "children": [446, 447], "start_point": {"row": 100, "column": 15}, "end_point": {"row": 100, "column": 80}}, {"id": 446, "type": "identifier", "text": "getAsset", "parent": 445, "children": [], "start_point": {"row": 100, "column": 15}, "end_point": {"row": 100, "column": 23}}, {"id": 447, "type": "parameter_list", "text": "(const std::string& uuid, AsyncGetAssetCallback callBack)", "parent": 445, "children": [448, 453], "start_point": {"row": 100, "column": 23}, "end_point": {"row": 100, "column": 80}}, {"id": 448, "type": "parameter_declaration", "text": "const std::string& uuid", "parent": 447, "children": [449, 450, 452], "start_point": {"row": 100, "column": 24}, "end_point": {"row": 100, "column": 47}}, {"id": 449, "type": "type_identifier", "text": "std", "parent": 448, "children": [], "start_point": {"row": 100, "column": 30}, "end_point": {"row": 100, "column": 33}}, {"id": 450, "type": "ERROR", "text": "::string&", "parent": 448, "children": [451], "start_point": {"row": 100, "column": 33}, "end_point": {"row": 100, "column": 42}}, {"id": 451, "type": "identifier", "text": "string", "parent": 450, "children": [], "start_point": {"row": 100, "column": 35}, "end_point": {"row": 100, "column": 41}}, {"id": 452, "type": "identifier", "text": "uuid", "parent": 448, "children": [], "start_point": {"row": 100, "column": 43}, "end_point": {"row": 100, "column": 47}}, {"id": 453, "type": "parameter_declaration", "text": "AsyncGetAssetCallback callBack", "parent": 447, "children": [454, 455], "start_point": {"row": 100, "column": 49}, "end_point": {"row": 100, "column": 79}}, {"id": 454, "type": "type_identifier", "text": "AsyncGetAssetCallback", "parent": 453, "children": [], "start_point": {"row": 100, "column": 49}, "end_point": {"row": 100, "column": 70}}, {"id": 455, "type": "identifier", "text": "callBack", "parent": 453, "children": [], "start_point": {"row": 100, "column": 71}, "end_point": {"row": 100, "column": 79}}, {"id": 456, "type": "declaration", "text": "virtual void getAsset(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack);", "parent": 45, "children": [457, 458, 460], "start_point": {"row": 101, "column": 2}, "end_point": {"row": 101, "column": 101}}, {"id": 457, "type": "type_identifier", "text": "virtual", "parent": 456, "children": [], "start_point": {"row": 101, "column": 2}, "end_point": {"row": 101, "column": 9}}, {"id": 458, "type": "ERROR", "text": "void", "parent": 456, "children": [459], "start_point": {"row": 101, "column": 10}, "end_point": {"row": 101, "column": 14}}, {"id": 459, "type": "identifier", "text": "void", "parent": 458, "children": [], "start_point": {"row": 101, "column": 10}, "end_point": {"row": 101, "column": 14}}, {"id": 460, "type": "function_declarator", "text": "getAsset(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack)", "parent": 456, "children": [461, 462], "start_point": {"row": 101, "column": 15}, "end_point": {"row": 101, "column": 100}}, {"id": 461, "type": "identifier", "text": "getAsset", "parent": 460, "children": [], "start_point": {"row": 101, "column": 15}, "end_point": {"row": 101, "column": 23}}, {"id": 462, "type": "parameter_list", "text": "(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack)", "parent": 460, "children": [463, 468, 473], "start_point": {"row": 101, "column": 23}, "end_point": {"row": 101, "column": 100}}, {"id": 463, "type": "parameter_declaration", "text": "const std::string& uuid", "parent": 462, "children": [464, 465, 467], "start_point": {"row": 101, "column": 24}, "end_point": {"row": 101, "column": 47}}, {"id": 464, "type": "type_identifier", "text": "std", "parent": 463, "children": [], "start_point": {"row": 101, "column": 30}, "end_point": {"row": 101, "column": 33}}, {"id": 465, "type": "ERROR", "text": "::string&", "parent": 463, "children": [466], "start_point": {"row": 101, "column": 33}, "end_point": {"row": 101, "column": 42}}, {"id": 466, "type": "identifier", "text": "string", "parent": 465, "children": [], "start_point": {"row": 101, "column": 35}, "end_point": {"row": 101, "column": 41}}, {"id": 467, "type": "identifier", "text": "uuid", "parent": 463, "children": [], "start_point": {"row": 101, "column": 43}, "end_point": {"row": 101, "column": 47}}, {"id": 468, "type": "parameter_declaration", "text": "unsigned int flags", "parent": 462, "children": [469, 472], "start_point": {"row": 101, "column": 49}, "end_point": {"row": 101, "column": 67}}, {"id": 469, "type": "sized_type_specifier", "text": "unsigned int", "parent": 468, "children": [470, 471], "start_point": {"row": 101, "column": 49}, "end_point": {"row": 101, "column": 61}}, {"id": 470, "type": "unsigned", "text": "unsigned", "parent": 469, "children": [], "start_point": {"row": 101, "column": 49}, "end_point": {"row": 101, "column": 57}}, {"id": 471, "type": "primitive_type", "text": "int", "parent": 469, "children": [], "start_point": {"row": 101, "column": 58}, "end_point": {"row": 101, "column": 61}}, {"id": 472, "type": "identifier", "text": "flags", "parent": 468, "children": [], "start_point": {"row": 101, "column": 62}, "end_point": {"row": 101, "column": 67}}, {"id": 473, "type": "parameter_declaration", "text": "AsyncGetAssetCallback callBack", "parent": 462, "children": [474, 475], "start_point": {"row": 101, "column": 69}, "end_point": {"row": 101, "column": 99}}, {"id": 474, "type": "type_identifier", "text": "AsyncGetAssetCallback", "parent": 473, "children": [], "start_point": {"row": 101, "column": 69}, "end_point": {"row": 101, "column": 90}}, {"id": 475, "type": "identifier", "text": "callBack", "parent": 473, "children": [], "start_point": {"row": 101, "column": 91}, "end_point": {"row": 101, "column": 99}}, {"id": 476, "type": "declaration", "text": "virtual void storeAsset(Asset::ptr asset, AsyncStoreAssetCallback callBack);", "parent": 45, "children": [477, 478, 480], "start_point": {"row": 102, "column": 2}, "end_point": {"row": 102, "column": 78}}, {"id": 477, "type": "type_identifier", "text": "virtual", "parent": 476, "children": [], "start_point": {"row": 102, "column": 2}, "end_point": {"row": 102, "column": 9}}, {"id": 478, "type": "ERROR", "text": "void", "parent": 476, "children": [479], "start_point": {"row": 102, "column": 10}, "end_point": {"row": 102, "column": 14}}, {"id": 479, "type": "identifier", "text": "void", "parent": 478, "children": [], "start_point": {"row": 102, "column": 10}, "end_point": {"row": 102, "column": 14}}, {"id": 480, "type": "function_declarator", "text": "storeAsset(Asset::ptr asset, AsyncStoreAssetCallback callBack)", "parent": 476, "children": [481, 482], "start_point": {"row": 102, "column": 15}, "end_point": {"row": 102, "column": 77}}, {"id": 481, "type": "identifier", "text": "storeAsset", "parent": 480, "children": [], "start_point": {"row": 102, "column": 15}, "end_point": {"row": 102, "column": 25}}, {"id": 482, "type": "parameter_list", "text": "(Asset::ptr asset, AsyncStoreAssetCallback callBack)", "parent": 480, "children": [483, 488], "start_point": {"row": 102, "column": 25}, "end_point": {"row": 102, "column": 77}}, {"id": 483, "type": "parameter_declaration", "text": "Asset::ptr asset", "parent": 482, "children": [484, 485, 487], "start_point": {"row": 102, "column": 26}, "end_point": {"row": 102, "column": 42}}, {"id": 484, "type": "type_identifier", "text": "Asset", "parent": 483, "children": [], "start_point": {"row": 102, "column": 26}, "end_point": {"row": 102, "column": 31}}, {"id": 485, "type": "ERROR", "text": "::ptr", "parent": 483, "children": [486], "start_point": {"row": 102, "column": 31}, "end_point": {"row": 102, "column": 36}}, {"id": 486, "type": "identifier", "text": "ptr", "parent": 485, "children": [], "start_point": {"row": 102, "column": 33}, "end_point": {"row": 102, "column": 36}}, {"id": 487, "type": "identifier", "text": "asset", "parent": 483, "children": [], "start_point": {"row": 102, "column": 37}, "end_point": {"row": 102, "column": 42}}, {"id": 488, "type": "parameter_declaration", "text": "AsyncStoreAssetCallback callBack", "parent": 482, "children": [489, 490], "start_point": {"row": 102, "column": 44}, "end_point": {"row": 102, "column": 76}}, {"id": 489, "type": "type_identifier", "text": "AsyncStoreAssetCallback", "parent": 488, "children": [], "start_point": {"row": 102, "column": 44}, "end_point": {"row": 102, "column": 67}}, {"id": 490, "type": "identifier", "text": "callBack", "parent": 488, "children": [], "start_point": {"row": 102, "column": 68}, "end_point": {"row": 102, "column": 76}}, {"id": 491, "type": "declaration", "text": "virtual void purgeAsset(const std::string& uuid, AsyncAssetPurgeCallback callBack);", "parent": 45, "children": [492, 493, 495], "start_point": {"row": 103, "column": 2}, "end_point": {"row": 103, "column": 85}}, {"id": 492, "type": "type_identifier", "text": "virtual", "parent": 491, "children": [], "start_point": {"row": 103, "column": 2}, "end_point": {"row": 103, "column": 9}}, {"id": 493, "type": "ERROR", "text": "void", "parent": 491, "children": [494], "start_point": {"row": 103, "column": 10}, "end_point": {"row": 103, "column": 14}}, {"id": 494, "type": "identifier", "text": "void", "parent": 493, "children": [], "start_point": {"row": 103, "column": 10}, "end_point": {"row": 103, "column": 14}}, {"id": 495, "type": "function_declarator", "text": "purgeAsset(const std::string& uuid, AsyncAssetPurgeCallback callBack)", "parent": 491, "children": [496, 497], "start_point": {"row": 103, "column": 15}, "end_point": {"row": 103, "column": 84}}, {"id": 496, "type": "identifier", "text": "purgeAsset", "parent": 495, "children": [], "start_point": {"row": 103, "column": 15}, "end_point": {"row": 103, "column": 25}}, {"id": 497, "type": "parameter_list", "text": "(const std::string& uuid, AsyncAssetPurgeCallback callBack)", "parent": 495, "children": [498, 503], "start_point": {"row": 103, "column": 25}, "end_point": {"row": 103, "column": 84}}, {"id": 498, "type": "parameter_declaration", "text": "const std::string& uuid", "parent": 497, "children": [499, 500, 502], "start_point": {"row": 103, "column": 26}, "end_point": {"row": 103, "column": 49}}, {"id": 499, "type": "type_identifier", "text": "std", "parent": 498, "children": [], "start_point": {"row": 103, "column": 32}, "end_point": {"row": 103, "column": 35}}, {"id": 500, "type": "ERROR", "text": "::string&", "parent": 498, "children": [501], "start_point": {"row": 103, "column": 35}, "end_point": {"row": 103, "column": 44}}, {"id": 501, "type": "identifier", "text": "string", "parent": 500, "children": [], "start_point": {"row": 103, "column": 37}, "end_point": {"row": 103, "column": 43}}, {"id": 502, "type": "identifier", "text": "uuid", "parent": 498, "children": [], "start_point": {"row": 103, "column": 45}, "end_point": {"row": 103, "column": 49}}, {"id": 503, "type": "parameter_declaration", "text": "AsyncAssetPurgeCallback callBack", "parent": 497, "children": [504, 505], "start_point": {"row": 103, "column": 51}, "end_point": {"row": 103, "column": 83}}, {"id": 504, "type": "type_identifier", "text": "AsyncAssetPurgeCallback", "parent": 503, "children": [], "start_point": {"row": 103, "column": 51}, "end_point": {"row": 103, "column": 74}}, {"id": 505, "type": "identifier", "text": "callBack", "parent": 503, "children": [], "start_point": {"row": 103, "column": 75}, "end_point": {"row": 103, "column": 83}}, {"id": 506, "type": "declaration", "text": "virtual void beginPurgeLocals();", "parent": 45, "children": [507, 508, 510], "start_point": {"row": 105, "column": 2}, "end_point": {"row": 105, "column": 34}}, {"id": 507, "type": "type_identifier", "text": "virtual", "parent": 506, "children": [], "start_point": {"row": 105, "column": 2}, "end_point": {"row": 105, "column": 9}}, {"id": 508, "type": "ERROR", "text": "void", "parent": 506, "children": [509], "start_point": {"row": 105, "column": 10}, "end_point": {"row": 105, "column": 14}}, {"id": 509, "type": "identifier", "text": "void", "parent": 508, "children": [], "start_point": {"row": 105, "column": 10}, "end_point": {"row": 105, "column": 14}}, {"id": 510, "type": "function_declarator", "text": "beginPurgeLocals()", "parent": 506, "children": [511, 512], "start_point": {"row": 105, "column": 15}, "end_point": {"row": 105, "column": 33}}, {"id": 511, "type": "identifier", "text": "beginPurgeLocals", "parent": 510, "children": [], "start_point": {"row": 105, "column": 15}, "end_point": {"row": 105, "column": 31}}, {"id": 512, "type": "parameter_list", "text": "()", "parent": 510, "children": [], "start_point": {"row": 105, "column": 31}, "end_point": {"row": 105, "column": 33}}, {"id": 513, "type": "declaration", "text": "virtual void getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\t\tvirtual void getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n\t\tvirtual void shutdown();", "parent": 45, "children": [514, 515, 566], "start_point": {"row": 107, "column": 2}, "end_point": {"row": 110, "column": 26}}, {"id": 514, "type": "type_identifier", "text": "virtual", "parent": 513, "children": [], "start_point": {"row": 107, "column": 2}, "end_point": {"row": 107, "column": 9}}, {"id": 515, "type": "ERROR", "text": "void getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\t\tvirtual void getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n\t\tvirtual void", "parent": 513, "children": [516, 517, 537, 538, 539, 564, 565], "start_point": {"row": 107, "column": 10}, "end_point": {"row": 110, "column": 14}}, {"id": 516, "type": "identifier", "text": "void", "parent": 515, "children": [], "start_point": {"row": 107, "column": 10}, "end_point": {"row": 107, "column": 14}}, {"id": 517, "type": "function_declarator", "text": "getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback", "parent": 515, "children": [518, 519, 534, 536], "start_point": {"row": 107, "column": 15}, "end_point": {"row": 107, "column": 107}}, {"id": 518, "type": "identifier", "text": "getStatus", "parent": 517, "children": [], "start_point": {"row": 107, "column": 15}, "end_point": {"row": 107, "column": 24}}, {"id": 519, "type": "parameter_list", "text": "(boost::shared_ptr<std::ostream> journal, boost::function<void()", "parent": 517, "children": [520, 529, 531], "start_point": {"row": 107, "column": 24}, "end_point": {"row": 107, "column": 88}}, {"id": 520, "type": "parameter_declaration", "text": "boost::shared_ptr<std::ostream> journal", "parent": 519, "children": [521, 522, 528], "start_point": {"row": 107, "column": 25}, "end_point": {"row": 107, "column": 64}}, {"id": 521, "type": "type_identifier", "text": "boost", "parent": 520, "children": [], "start_point": {"row": 107, "column": 25}, "end_point": {"row": 107, "column": 30}}, {"id": 522, "type": "ERROR", "text": "::shared_ptr<std::ostream>", "parent": 520, "children": [523, 524, 525, 526, 527], "start_point": {"row": 107, "column": 30}, "end_point": {"row": 107, "column": 56}}, {"id": 523, "type": "identifier", "text": "shared_ptr", "parent": 522, "children": [], "start_point": {"row": 107, "column": 32}, "end_point": {"row": 107, "column": 42}}, {"id": 524, "type": "<", "text": "<", "parent": 522, "children": [], "start_point": {"row": 107, "column": 42}, "end_point": {"row": 107, "column": 43}}, {"id": 525, "type": "identifier", "text": "std", "parent": 522, "children": [], "start_point": {"row": 107, "column": 43}, "end_point": {"row": 107, "column": 46}}, {"id": 526, "type": "identifier", "text": "ostream", "parent": 522, "children": [], "start_point": {"row": 107, "column": 48}, "end_point": {"row": 107, "column": 55}}, {"id": 527, "type": ">", "text": ">", "parent": 522, "children": [], "start_point": {"row": 107, "column": 55}, "end_point": {"row": 107, "column": 56}}, {"id": 528, "type": "identifier", "text": "journal", "parent": 520, "children": [], "start_point": {"row": 107, "column": 57}, "end_point": {"row": 107, "column": 64}}, {"id": 529, "type": "parameter_declaration", "text": "boost::function", "parent": 519, "children": [530], "start_point": {"row": 107, "column": 66}, "end_point": {"row": 107, "column": 81}}, {"id": 530, "type": "type_identifier", "text": "boost", "parent": 529, "children": [], "start_point": {"row": 107, "column": 66}, "end_point": {"row": 107, "column": 71}}, {"id": 531, "type": "ERROR", "text": "<void(", "parent": 519, "children": [532, 533], "start_point": {"row": 107, "column": 81}, "end_point": {"row": 107, "column": 87}}, {"id": 532, "type": "<", "text": "<", "parent": 531, "children": [], "start_point": {"row": 107, "column": 81}, "end_point": {"row": 107, "column": 82}}, {"id": 533, "type": "primitive_type", "text": "void", "parent": 531, "children": [], "start_point": {"row": 107, "column": 82}, "end_point": {"row": 107, "column": 86}}, {"id": 534, "type": "ERROR", "text": ">", "parent": 517, "children": [535], "start_point": {"row": 107, "column": 88}, "end_point": {"row": 107, "column": 89}}, {"id": 535, "type": ">", "text": ">", "parent": 534, "children": [], "start_point": {"row": 107, "column": 88}, "end_point": {"row": 107, "column": 89}}, {"id": 536, "type": "identifier", "text": "completedCallback", "parent": 517, "children": [], "start_point": {"row": 107, "column": 90}, "end_point": {"row": 107, "column": 107}}, {"id": 537, "type": "identifier", "text": "virtual", "parent": 515, "children": [], "start_point": {"row": 108, "column": 2}, "end_point": {"row": 108, "column": 9}}, {"id": 538, "type": "identifier", "text": "void", "parent": 515, "children": [], "start_point": {"row": 108, "column": 10}, "end_point": {"row": 108, "column": 14}}, {"id": 539, "type": "function_declarator", "text": "getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback", "parent": 515, "children": [540, 541, 561, 563], "start_point": {"row": 108, "column": 15}, "end_point": {"row": 108, "column": 145}}, {"id": 540, "type": "identifier", "text": "getStoredAssetIDsWithPrefix", "parent": 539, "children": [], "start_point": {"row": 108, "column": 15}, "end_point": {"row": 108, "column": 42}}, {"id": 541, "type": "parameter_list", "text": "(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()", "parent": 539, "children": [542, 547, 556, 558], "start_point": {"row": 108, "column": 42}, "end_point": {"row": 108, "column": 126}}, {"id": 542, "type": "parameter_declaration", "text": "std::string prefix", "parent": 541, "children": [543, 544, 546], "start_point": {"row": 108, "column": 43}, "end_point": {"row": 108, "column": 61}}, {"id": 543, "type": "type_identifier", "text": "std", "parent": 542, "children": [], "start_point": {"row": 108, "column": 43}, "end_point": {"row": 108, "column": 46}}, {"id": 544, "type": "ERROR", "text": "::string", "parent": 542, "children": [545], "start_point": {"row": 108, "column": 46}, "end_point": {"row": 108, "column": 54}}, {"id": 545, "type": "identifier", "text": "string", "parent": 544, "children": [], "start_point": {"row": 108, "column": 48}, "end_point": {"row": 108, "column": 54}}, {"id": 546, "type": "identifier", "text": "prefix", "parent": 542, "children": [], "start_point": {"row": 108, "column": 55}, "end_point": {"row": 108, "column": 61}}, {"id": 547, "type": "parameter_declaration", "text": "boost::shared_ptr<std::ostream> journal", "parent": 541, "children": [548, 549, 555], "start_point": {"row": 108, "column": 63}, "end_point": {"row": 108, "column": 102}}, {"id": 548, "type": "type_identifier", "text": "boost", "parent": 547, "children": [], "start_point": {"row": 108, "column": 63}, "end_point": {"row": 108, "column": 68}}, {"id": 549, "type": "ERROR", "text": "::shared_ptr<std::ostream>", "parent": 547, "children": [550, 551, 552, 553, 554], "start_point": {"row": 108, "column": 68}, "end_point": {"row": 108, "column": 94}}, {"id": 550, "type": "identifier", "text": "shared_ptr", "parent": 549, "children": [], "start_point": {"row": 108, "column": 70}, "end_point": {"row": 108, "column": 80}}, {"id": 551, "type": "<", "text": "<", "parent": 549, "children": [], "start_point": {"row": 108, "column": 80}, "end_point": {"row": 108, "column": 81}}, {"id": 552, "type": "identifier", "text": "std", "parent": 549, "children": [], "start_point": {"row": 108, "column": 81}, "end_point": {"row": 108, "column": 84}}, {"id": 553, "type": "identifier", "text": "ostream", "parent": 549, "children": [], "start_point": {"row": 108, "column": 86}, "end_point": {"row": 108, "column": 93}}, {"id": 554, "type": ">", "text": ">", "parent": 549, "children": [], "start_point": {"row": 108, "column": 93}, "end_point": {"row": 108, "column": 94}}, {"id": 555, "type": "identifier", "text": "journal", "parent": 547, "children": [], "start_point": {"row": 108, "column": 95}, "end_point": {"row": 108, "column": 102}}, {"id": 556, "type": "parameter_declaration", "text": "boost::function", "parent": 541, "children": [557], "start_point": {"row": 108, "column": 104}, "end_point": {"row": 108, "column": 119}}, {"id": 557, "type": "type_identifier", "text": "boost", "parent": 556, "children": [], "start_point": {"row": 108, "column": 104}, "end_point": {"row": 108, "column": 109}}, {"id": 558, "type": "ERROR", "text": "<void(", "parent": 541, "children": [559, 560], "start_point": {"row": 108, "column": 119}, "end_point": {"row": 108, "column": 125}}, {"id": 559, "type": "<", "text": "<", "parent": 558, "children": [], "start_point": {"row": 108, "column": 119}, "end_point": {"row": 108, "column": 120}}, {"id": 560, "type": "primitive_type", "text": "void", "parent": 558, "children": [], "start_point": {"row": 108, "column": 120}, "end_point": {"row": 108, "column": 124}}, {"id": 561, "type": "ERROR", "text": ">", "parent": 539, "children": [562], "start_point": {"row": 108, "column": 126}, "end_point": {"row": 108, "column": 127}}, {"id": 562, "type": ">", "text": ">", "parent": 561, "children": [], "start_point": {"row": 108, "column": 126}, "end_point": {"row": 108, "column": 127}}, {"id": 563, "type": "identifier", "text": "completedCallback", "parent": 539, "children": [], "start_point": {"row": 108, "column": 128}, "end_point": {"row": 108, "column": 145}}, {"id": 564, "type": "identifier", "text": "virtual", "parent": 515, "children": [], "start_point": {"row": 110, "column": 2}, "end_point": {"row": 110, "column": 9}}, {"id": 565, "type": "identifier", "text": "void", "parent": 515, "children": [], "start_point": {"row": 110, "column": 10}, "end_point": {"row": 110, "column": 14}}, {"id": 566, "type": "function_declarator", "text": "shutdown()", "parent": 513, "children": [567, 568], "start_point": {"row": 110, "column": 15}, "end_point": {"row": 110, "column": 25}}, {"id": 567, "type": "identifier", "text": "shutdown", "parent": 566, "children": [], "start_point": {"row": 110, "column": 15}, "end_point": {"row": 110, "column": 23}}, {"id": 568, "type": "parameter_list", "text": "()", "parent": 566, "children": [], "start_point": {"row": 110, "column": 23}, "end_point": {"row": 110, "column": 25}}, {"id": 569, "type": "labeled_statement", "text": "ExistenceIndex::ptr getIndex();", "parent": 45, "children": [570, 571], "start_point": {"row": 112, "column": 2}, "end_point": {"row": 112, "column": 33}}, {"id": 570, "type": "statement_identifier", "text": "ExistenceIndex", "parent": 569, "children": [], "start_point": {"row": 112, "column": 2}, "end_point": {"row": 112, "column": 16}}, {"id": 571, "type": "declaration", "text": "ptr getIndex();", "parent": 569, "children": [572, 573], "start_point": {"row": 112, "column": 18}, "end_point": {"row": 112, "column": 33}}, {"id": 572, "type": "type_identifier", "text": "ptr", "parent": 571, "children": [], "start_point": {"row": 112, "column": 18}, "end_point": {"row": 112, "column": 21}}, {"id": 573, "type": "function_declarator", "text": "getIndex()", "parent": 571, "children": [574, 575], "start_point": {"row": 112, "column": 22}, "end_point": {"row": 112, "column": 32}}, {"id": 574, "type": "identifier", "text": "getIndex", "parent": 573, "children": [], "start_point": {"row": 112, "column": 22}, "end_point": {"row": 112, "column": 30}}, {"id": 575, "type": "parameter_list", "text": "()", "parent": 573, "children": [], "start_point": {"row": 112, "column": 30}, "end_point": {"row": 112, "column": 32}}]}, "node_categories": {"declarations": {"functions": [45, 144, 160, 179, 184, 195, 208, 223, 234, 247, 260, 273, 283, 293, 315, 389, 397, 409, 421, 433, 445, 460, 480, 495, 510, 517, 539, 566, 573], "variables": [54, 62, 65, 68, 71, 76, 92, 97, 122, 125, 128, 131, 134, 139, 142, 158, 163, 177, 182, 187, 193, 198, 201, 206, 211, 216, 221, 226, 232, 237, 242, 245, 250, 255, 258, 263, 268, 271, 276, 281, 286, 296, 305, 318, 323, 332, 341, 344, 347, 350, 353, 356, 382, 385, 392, 400, 405, 412, 417, 424, 429, 436, 441, 448, 453, 456, 463, 468, 473, 476, 483, 488, 491, 498, 503, 506, 513, 520, 529, 542, 547, 556, 571], "classes": [], "imports": [3, 4, 6, 7, 9, 10, 12, 13, 15, 16, 18, 19, 21, 22, 24, 25, 27, 28, 30, 31, 33, 34, 36, 37, 39, 40, 42, 43], "modules": [], "enums": []}, "statements": {"expressions": [82, 86, 103, 107, 115, 155, 174, 365, 366, 371, 377, 378], "assignments": [], "loops": [], "conditionals": [46, 47, 50, 51, 52, 57, 61, 63, 64, 67, 70, 73, 75, 77, 78, 80, 83, 85, 87, 89, 91, 93, 94, 96, 98, 99, 101, 104, 106, 108, 110, 112, 114, 116, 117, 119, 121, 123, 124, 127, 130, 132, 133, 135, 136, 138, 140, 141, 145, 148, 150, 152, 153, 154, 156, 157, 161, 164, 166, 167, 169, 171, 172, 173, 175, 176, 180, 185, 188, 190, 191, 192, 196, 199, 200, 202, 204, 205, 209, 212, 214, 215, 217, 219, 220, 224, 227, 229, 230, 235, 238, 240, 241, 243, 244, 248, 251, 253, 254, 256, 257, 261, 264, 266, 267, 269, 270, 274, 277, 279, 280, 284, 287, 289, 290, 294, 297, 299, 301, 302, 304, 306, 312, 316, 319, 321, 322, 324, 326, 328, 329, 331, 333, 339, 342, 343, 345, 346, 348, 349, 351, 352, 354, 355, 357, 358, 361, 364, 367, 368, 370, 372, 373, 375, 379, 380, 381, 383, 384, 386, 390, 393, 395, 396, 398, 401, 403, 404, 406, 408, 410, 413, 415, 416, 418, 420, 422, 425, 427, 428, 430, 432, 434, 437, 439, 440, 442, 444, 446, 449, 451, 452, 454, 455, 457, 459, 461, 464, 466, 467, 469, 472, 474, 475, 477, 479, 481, 484, 486, 487, 489, 490, 492, 494, 496, 499, 501, 502, 504, 505, 507, 509, 511, 514, 516, 518, 521, 523, 525, 526, 528, 530, 536, 537, 538, 540, 543, 545, 546, 548, 550, 552, 553, 555, 557, 563, 564, 565, 567, 570, 572, 574], "returns": [], "exceptions": []}, "expressions": {"calls": [0], "literals": [5, 8, 11, 14, 17, 20, 23, 26, 29, 32, 35, 38, 41, 44, 59], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 45, "universal_type": "function", "name": "VFSBackend", "text_snippet": "namespace iwvfs\n{\n\t/**\n\t\tInWorldz virtual file system storage backend. Provides access\n\t\tto an inde"}, {"node_id": 144, "universal_type": "function", "name": "unknown", "text_snippet": "isLittleEndian()"}, {"node_id": 160, "universal_type": "function", "name": "unknown", "text_snippet": "verifyDatabaseDirectory(const std::string& uuid)"}, {"node_id": 179, "universal_type": "function", "name": "unknown", "text_snippet": "workLoop()"}, {"node_id": 184, "universal_type": "function", "name": "unknown", "text_snippet": "onPurgeTimer(const boost::system::error_code& error)"}, {"node_id": 195, "universal_type": "function", "name": "unknown", "text_snippet": "unindexLocals(UuidListPtr uuidList, std::string uuidHead)"}, {"node_id": 208, "universal_type": "function", "name": "unknown", "text_snippet": "assetWriteFailed(std::string assetId, std::string reason)"}, {"node_id": 223, "universal_type": "function", "name": "unknown", "text_snippet": "ioLoopFailed(std::string reason)"}, {"node_id": 234, "universal_type": "function", "name": "unknown", "text_snippet": "performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback)"}, {"node_id": 247, "universal_type": "function", "name": "unknown", "text_snippet": "performDiskRead(const std::string& assetId, AsyncGetAssetCallback callback)"}, {"node_id": 260, "universal_type": "function", "name": "unknown", "text_snippet": "performDiskPurge(const std::string& assetId, AsyncAssetPurgeCallback callback)"}, {"node_id": 273, "universal_type": "function", "name": "unknown", "text_snippet": "performDiskPurgeLocals(const std::string& assetId)"}, {"node_id": 283, "universal_type": "function", "name": "unknown", "text_snippet": "performLocalsPhysicalDeletion(const std::string& uuidHead)"}, {"node_id": 293, "universal_type": "function", "name": "unknown", "text_snippet": "performGetStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback"}, {"node_id": 315, "universal_type": "function", "name": "unknown", "text_snippet": "performGetStoredAssetIds(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::functio"}, {"node_id": 389, "universal_type": "function", "name": "unknown", "text_snippet": "VFSBackend()"}, {"node_id": 397, "universal_type": "function", "name": "unknown", "text_snippet": "getAsset(const std::string& uuid)"}, {"node_id": 409, "universal_type": "function", "name": "unknown", "text_snippet": "storeAsset(Asset::ptr asset)"}, {"node_id": 421, "universal_type": "function", "name": "unknown", "text_snippet": "assetExists(const std::string& uuid)"}, {"node_id": 433, "universal_type": "function", "name": "unknown", "text_snippet": "purgeAsset(const std::string& uuid)"}, {"node_id": 445, "universal_type": "function", "name": "unknown", "text_snippet": "getAsset(const std::string& uuid, AsyncGetAssetCallback callBack)"}, {"node_id": 460, "universal_type": "function", "name": "flags,", "text_snippet": "getAsset(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack)"}, {"node_id": 480, "universal_type": "function", "name": "unknown", "text_snippet": "storeAsset(Asset::ptr asset, AsyncStoreAssetCallback callBack)"}, {"node_id": 495, "universal_type": "function", "name": "unknown", "text_snippet": "purgeAsset(const std::string& uuid, AsyncAssetPurgeCallback callBack)"}, {"node_id": 510, "universal_type": "function", "name": "unknown", "text_snippet": "beginPurgeLocals()"}, {"node_id": 517, "universal_type": "function", "name": "unknown", "text_snippet": "getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback"}, {"node_id": 539, "universal_type": "function", "name": "unknown", "text_snippet": "getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::func"}, {"node_id": 566, "universal_type": "function", "name": "unknown", "text_snippet": "shutdown()"}, {"node_id": 573, "universal_type": "function", "name": "unknown", "text_snippet": "getIndex()"}], "class_declarations": [], "import_statements": [{"node_id": 3, "text": "#include \"IStorageBackend.h\"\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include \"IAsyncStorageBackend.h\"\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include \"DatabaseSet.h\"\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include \"ExistenceIndex.h\"\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include \"AsyncStorageTypes.h\"\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include \"VFSQueueTypes.h\"\n"}, {"node_id": 19, "text": "#include"}, {"node_id": 21, "text": "#include \"MovingAverage.h\"\n"}, {"node_id": 22, "text": "#include"}, {"node_id": 24, "text": "#include \"PushReplicationService.h\"\n"}, {"node_id": 25, "text": "#include"}, {"node_id": 27, "text": "#include <boost/filesystem.hpp>\n"}, {"node_id": 28, "text": "#include"}, {"node_id": 30, "text": "#include <boost/thread.hpp>\n"}, {"node_id": 31, "text": "#include"}, {"node_id": 33, "text": "#include <boost/asio.hpp>\n"}, {"node_id": 34, "text": "#include"}, {"node_id": 36, "text": "#include <iosfwd>\n"}, {"node_id": 37, "text": "#include"}, {"node_id": 39, "text": "#include <deque>\n"}, {"node_id": 40, "text": "#include"}, {"node_id": 42, "text": "#include <string>\n"}, {"node_id": 43, "text": "#include"}]}, "original_source_code": "#pragma once\n\n#include \"IStorageBackend.h\"\n#include \"IAsyncStorageBackend.h\"\n#include \"DatabaseSet.h\"\n#include \"ExistenceIndex.h\"\n#include \"AsyncStorageTypes.h\"\n#include \"VFSQueueTypes.h\"\n#include \"MovingAverage.h\"\n#include \"PushReplicationService.h\"\n\n#include <boost/filesystem.hpp>\n#include <boost/thread.hpp>\n#include <boost/asio.hpp>\n#include <iosfwd>\n#include <deque>\n#include <string>\n\n/**\n *\tNamespace for InWorldz virtual file system components\n */\nnamespace iwvfs\n{\n\t/**\n\t\tInWorldz virtual file system storage backend. Provides access\n\t\tto an indexed file system that uses the first 3 letters of the hex\n\t\tasset id to set up 4096 folders that each contain a database and index\n\t\tfile for local and global assets\n\t*/\n\tclass VFSBackend : public IStorageBackend, public IAsyncStorageBackend\n\t{\n\tprivate:\n\t\tconst static int DISK_LATENCY_SAMPLE_SIZE = 50;\n\n\t\tstd::string _storageRoot;\n\t\tbool _enablePurge;\n\n\t\tbool _debugging;\n\t\tbool _stop;\n\n\t\tExistenceIndex::ptr _existenceIndex;\n\t\n\t\tboost::shared_ptr<boost::thread> _workerThread;\n\t\tboost::mutex _workMutex;\n\t\tboost::condition_variable _workArrived;\n\n\t\tstd::deque<AssetRequest::ptr> _workQueue;\n\n\t\tboost::asio::io_service& _ioService;\n\n\t\tboost::asio::deadline_timer _purgeLocalsTimer;\n\t\tbool _isPurgingLocals;\n\t\tint _currentLocalsPurgeIndex;\n\n\t\tMovingAverage _diskLatencyAvg;\n\t\tMovingAverage _diskOpAvg;\n\n\t\tPushReplicationService::ptr _pushRepl;\n\n\n\t\tbool isLittleEndian();\n\t\tboost::filesystem::path getFullPathForUUID(const std::string& uuid);\n\t\tvoid verifyDatabaseDirectory(const std::string& uuid);\n\t\tDatabaseSet::ptr verifyAndopenSetForUUID(const std::string& uuid);\n\t\tvoid workLoop();\n\n\t\tvoid onPurgeTimer(const boost::system::error_code& error);\n\t\t\n\t\tvoid unindexLocals(UuidListPtr uuidList, std::string uuidHead);\n\n\t\tvoid assetWriteFailed(std::string assetId, std::string reason);\n\t\tvoid ioLoopFailed(std::string reason);\n\n\tprotected:\n\t\tvoid performDiskWrite(Asset::ptr asset, AsyncStoreAssetCallback callback);\n\t\tvoid performDiskRead(const std::string& assetId, AsyncGetAssetCallback callback);\n\t\tvoid performDiskPurge(const std::string& assetId, AsyncAssetPurgeCallback callback);\n\t\tvoid performDiskPurgeLocals(const std::string& assetId);\n\t\tvoid performLocalsPhysicalDeletion(const std::string& uuidHead);\n\t\tvoid performGetStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\t\tvoid performGetStoredAssetIds(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n\tpublic:\n\t\tfriend class AssetGetRequest;\n\t\tfriend class AssetPutRequest;\n\t\tfriend class AssetPurgeRequest;\n\t\tfriend class DeleteLocalStorageRequest;\n\t\tfriend class CollectStatusRequest;\n\t\tfriend class GetStoredAssetIdsRequest;\n\n\tpublic:\n\t\tVFSBackend(const std::string& storageRoot, bool enablePurge, boost::asio::io_service& ioService,\n\t\t\tPushReplicationService::ptr pushRepl);\n\t\tvirtual ~VFSBackend();\n\n\t\tvirtual Asset::ptr getAsset(const std::string& uuid);\n\t\tvirtual void storeAsset(Asset::ptr asset);\n\t\tvirtual bool assetExists(const std::string& uuid);\n\t\tvirtual void purgeAsset(const std::string& uuid);\n\n\t\tvirtual void getAsset(const std::string& uuid, AsyncGetAssetCallback callBack);\n\t\tvirtual void getAsset(const std::string& uuid, unsigned int flags, AsyncGetAssetCallback callBack);\n\t\tvirtual void storeAsset(Asset::ptr asset, AsyncStoreAssetCallback callBack);\n\t\tvirtual void purgeAsset(const std::string& uuid, AsyncAssetPurgeCallback callBack);\n\n\t\tvirtual void beginPurgeLocals();\n\n\t\tvirtual void getStatus(boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\t\tvirtual void getStoredAssetIDsWithPrefix(std::string prefix, boost::shared_ptr<std::ostream> journal, boost::function<void()> completedCallback);\n\n\t\tvirtual void shutdown();\n\n\t\tExistenceIndex::ptr getIndex();\n\t};\n\n}"}
80,583
c
/* This file is part of Lwt, released under the MIT license. See LICENSE.md for details, or visit https://github.com/ocsigen/lwt/blob/master/LICENSE.md. */ #include "lwt_config.h" #if !defined(LWT_ON_WINDOWS) #include <caml/memory.h> #include <caml/mlvalues.h> #include <caml/unixsupport.h> #include <errno.h> #include <string.h> #include "lwt_unix.h" #include "unix_readv_writev_utils.h" /* Job and readv primitives for blocking file descriptors. */ struct job_readv { struct lwt_unix_job job; int fd; int error_code; ssize_t result; size_t count; /* Heap-allocated iovec structures. */ struct iovec *iovecs; /* Data to be read into bytes buffers is first read into temporary buffers on the C heap. This is an array of descriptors for copying that data into the actual bytes buffers. The array is terminated by a descriptor whose temporary_buffer member is NULL. */ struct readv_copy_to buffers[]; }; static void worker_readv(struct job_readv *job) { job->result = readv(job->fd, job->iovecs, job->count); job->error_code = errno; } static value result_readv(struct job_readv *job) { struct readv_copy_to *read_buffer; /* If the read is successful, copy data to the OCaml buffers. */ if (job->result != -1) { for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL; ++read_buffer) { memcpy(&Byte(String_val(read_buffer->caml_buffer), read_buffer->offset), read_buffer->temporary_buffer, read_buffer->length); } } /* Free heap-allocated structures and buffers. */ for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL; ++read_buffer) { free(read_buffer->temporary_buffer); caml_remove_generational_global_root(&read_buffer->caml_buffer); } free(job->iovecs); /* Decide on the actual result. */ ssize_t result = job->result; LWT_UNIX_CHECK_JOB(job, result < 0, "readv"); lwt_unix_free_job(&job->job); return Val_long(result); } CAMLprim value lwt_unix_readv_job(value fd, value io_vectors, value val_count) { CAMLparam3(fd, io_vectors, val_count); size_t count = Long_val(val_count); /* The extra struct readv_copy_to (+ 1) is for the final terminator, in case all buffer slices are in bytes buffers. */ LWT_UNIX_INIT_JOB(job, readv, sizeof(struct readv_copy_to) * (count + 1)); job->fd = Int_val(fd); job->count = count; /* Assemble iovec structures on the heap. */ job->iovecs = lwt_unix_malloc(sizeof(struct iovec) * count); flatten_io_vectors(job->iovecs, io_vectors, count, NULL, job->buffers); CAMLreturn(lwt_unix_alloc_job(&job->job)); } #endif
37.35
72
(translation_unit) "/* This file is part of Lwt, released under the MIT license. See LICENSE.md for\n details, or visit https://github.com/ocsigen/lwt/blob/master/LICENSE.md. */\n\n\n\n#include "lwt_config.h"\n\n#if !defined(LWT_ON_WINDOWS)\n\n#include <caml/memory.h>\n#include <caml/mlvalues.h>\n#include <caml/unixsupport.h>\n#include <errno.h>\n#include <string.h>\n\n#include "lwt_unix.h"\n#include "unix_readv_writev_utils.h"\n\n/* Job and readv primitives for blocking file descriptors. */\nstruct job_readv {\n struct lwt_unix_job job;\n int fd;\n int error_code;\n ssize_t result;\n size_t count;\n /* Heap-allocated iovec structures. */\n struct iovec *iovecs;\n /* Data to be read into bytes buffers is first read into temporary buffers\n on the C heap. This is an array of descriptors for copying that data into\n the actual bytes buffers. The array is terminated by a descriptor whose\n temporary_buffer member is NULL. */\n struct readv_copy_to buffers[];\n};\n\nstatic void worker_readv(struct job_readv *job)\n{\n job->result = readv(job->fd, job->iovecs, job->count);\n job->error_code = errno;\n}\n\nstatic value result_readv(struct job_readv *job)\n{\n struct readv_copy_to *read_buffer;\n\n /* If the read is successful, copy data to the OCaml buffers. */\n if (job->result != -1) {\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);\n }\n }\n\n /* Free heap-allocated structures and buffers. */\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n free(read_buffer->temporary_buffer);\n caml_remove_generational_global_root(&read_buffer->caml_buffer);\n }\n free(job->iovecs);\n\n /* Decide on the actual result. */\n ssize_t result = job->result;\n LWT_UNIX_CHECK_JOB(job, result < 0, "readv");\n lwt_unix_free_job(&job->job);\n return Val_long(result);\n}\n\nCAMLprim value lwt_unix_readv_job(value fd, value io_vectors, value val_count)\n{\n CAMLparam3(fd, io_vectors, val_count);\n\n size_t count = Long_val(val_count);\n\n /* The extra struct readv_copy_to (+ 1) is for the final terminator, in case\n all buffer slices are in bytes buffers. */\n LWT_UNIX_INIT_JOB(job, readv, sizeof(struct readv_copy_to) * (count + 1));\n job->fd = Int_val(fd);\n job->count = count;\n\n /* Assemble iovec structures on the heap. */\n job->iovecs = lwt_unix_malloc(sizeof(struct iovec) * count);\n flatten_io_vectors(job->iovecs, io_vectors, count, NULL, job->buffers);\n\n CAMLreturn(lwt_unix_alloc_job(&job->job));\n}\n#endif\n" (comment) "/* This file is part of Lwt, released under the MIT license. See LICENSE.md for\n details, or visit https://github.com/ocsigen/lwt/blob/master/LICENSE.md. */" (preproc_include) "#include "lwt_config.h"\n" (#include) "#include" (string_literal) ""lwt_config.h"" (") """ (string_content) "lwt_config.h" (") """ (preproc_if) "#if !defined(LWT_ON_WINDOWS)\n\n#include <caml/memory.h>\n#include <caml/mlvalues.h>\n#include <caml/unixsupport.h>\n#include <errno.h>\n#include <string.h>\n\n#include "lwt_unix.h"\n#include "unix_readv_writev_utils.h"\n\n/* Job and readv primitives for blocking file descriptors. */\nstruct job_readv {\n struct lwt_unix_job job;\n int fd;\n int error_code;\n ssize_t result;\n size_t count;\n /* Heap-allocated iovec structures. */\n struct iovec *iovecs;\n /* Data to be read into bytes buffers is first read into temporary buffers\n on the C heap. This is an array of descriptors for copying that data into\n the actual bytes buffers. The array is terminated by a descriptor whose\n temporary_buffer member is NULL. */\n struct readv_copy_to buffers[];\n};\n\nstatic void worker_readv(struct job_readv *job)\n{\n job->result = readv(job->fd, job->iovecs, job->count);\n job->error_code = errno;\n}\n\nstatic value result_readv(struct job_readv *job)\n{\n struct readv_copy_to *read_buffer;\n\n /* If the read is successful, copy data to the OCaml buffers. */\n if (job->result != -1) {\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);\n }\n }\n\n /* Free heap-allocated structures and buffers. */\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n free(read_buffer->temporary_buffer);\n caml_remove_generational_global_root(&read_buffer->caml_buffer);\n }\n free(job->iovecs);\n\n /* Decide on the actual result. */\n ssize_t result = job->result;\n LWT_UNIX_CHECK_JOB(job, result < 0, "readv");\n lwt_unix_free_job(&job->job);\n return Val_long(result);\n}\n\nCAMLprim value lwt_unix_readv_job(value fd, value io_vectors, value val_count)\n{\n CAMLparam3(fd, io_vectors, val_count);\n\n size_t count = Long_val(val_count);\n\n /* The extra struct readv_copy_to (+ 1) is for the final terminator, in case\n all buffer slices are in bytes buffers. */\n LWT_UNIX_INIT_JOB(job, readv, sizeof(struct readv_copy_to) * (count + 1));\n job->fd = Int_val(fd);\n job->count = count;\n\n /* Assemble iovec structures on the heap. */\n job->iovecs = lwt_unix_malloc(sizeof(struct iovec) * count);\n flatten_io_vectors(job->iovecs, io_vectors, count, NULL, job->buffers);\n\n CAMLreturn(lwt_unix_alloc_job(&job->job));\n}\n#endif" (#if) "#if" (unary_expression) "!defined(LWT_ON_WINDOWS)" (!) "!" (preproc_defined) "defined(LWT_ON_WINDOWS)" (defined) "defined" (() "(" (identifier) "LWT_ON_WINDOWS" ()) ")" ( ) "\n\n" (preproc_include) "#include <caml/memory.h>\n" (#include) "#include" (system_lib_string) "<caml/memory.h>" (preproc_include) "#include <caml/mlvalues.h>\n" (#include) "#include" (system_lib_string) "<caml/mlvalues.h>" (preproc_include) "#include <caml/unixsupport.h>\n" (#include) "#include" (system_lib_string) "<caml/unixsupport.h>" (preproc_include) "#include <errno.h>\n" (#include) "#include" (system_lib_string) "<errno.h>" (preproc_include) "#include <string.h>\n" (#include) "#include" (system_lib_string) "<string.h>" (preproc_include) "#include "lwt_unix.h"\n" (#include) "#include" (string_literal) ""lwt_unix.h"" (") """ (string_content) "lwt_unix.h" (") """ (preproc_include) "#include "unix_readv_writev_utils.h"\n" (#include) "#include" (string_literal) ""unix_readv_writev_utils.h"" (") """ (string_content) "unix_readv_writev_utils.h" (") """ (comment) "/* Job and readv primitives for blocking file descriptors. */" (struct_specifier) "struct job_readv {\n struct lwt_unix_job job;\n int fd;\n int error_code;\n ssize_t result;\n size_t count;\n /* Heap-allocated iovec structures. */\n struct iovec *iovecs;\n /* Data to be read into bytes buffers is first read into temporary buffers\n on the C heap. This is an array of descriptors for copying that data into\n the actual bytes buffers. The array is terminated by a descriptor whose\n temporary_buffer member is NULL. */\n struct readv_copy_to buffers[];\n}" (struct) "struct" (type_identifier) "job_readv" (field_declaration_list) "{\n struct lwt_unix_job job;\n int fd;\n int error_code;\n ssize_t result;\n size_t count;\n /* Heap-allocated iovec structures. */\n struct iovec *iovecs;\n /* Data to be read into bytes buffers is first read into temporary buffers\n on the C heap. This is an array of descriptors for copying that data into\n the actual bytes buffers. The array is terminated by a descriptor whose\n temporary_buffer member is NULL. */\n struct readv_copy_to buffers[];\n}" ({) "{" (field_declaration) "struct lwt_unix_job job;" (struct_specifier) "struct lwt_unix_job" (struct) "struct" (type_identifier) "lwt_unix_job" (field_identifier) "job" (;) ";" (field_declaration) "int fd;" (primitive_type) "int" (field_identifier) "fd" (;) ";" (field_declaration) "int error_code;" (primitive_type) "int" (field_identifier) "error_code" (;) ";" (field_declaration) "ssize_t result;" (primitive_type) "ssize_t" (field_identifier) "result" (;) ";" (field_declaration) "size_t count;" (primitive_type) "size_t" (field_identifier) "count" (;) ";" (comment) "/* Heap-allocated iovec structures. */" (field_declaration) "struct iovec *iovecs;" (struct_specifier) "struct iovec" (struct) "struct" (type_identifier) "iovec" (pointer_declarator) "*iovecs" (*) "*" (field_identifier) "iovecs" (;) ";" (comment) "/* Data to be read into bytes buffers is first read into temporary buffers\n on the C heap. This is an array of descriptors for copying that data into\n the actual bytes buffers. The array is terminated by a descriptor whose\n temporary_buffer member is NULL. */" (field_declaration) "struct readv_copy_to buffers[];" (struct_specifier) "struct readv_copy_to" (struct) "struct" (type_identifier) "readv_copy_to" (array_declarator) "buffers[]" (field_identifier) "buffers" ([) "[" (]) "]" (;) ";" (}) "}" (;) ";" (function_definition) "static void worker_readv(struct job_readv *job)\n{\n job->result = readv(job->fd, job->iovecs, job->count);\n job->error_code = errno;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "worker_readv(struct job_readv *job)" (identifier) "worker_readv" (parameter_list) "(struct job_readv *job)" (() "(" (parameter_declaration) "struct job_readv *job" (struct_specifier) "struct job_readv" (struct) "struct" (type_identifier) "job_readv" (pointer_declarator) "*job" (*) "*" (identifier) "job" ()) ")" (compound_statement) "{\n job->result = readv(job->fd, job->iovecs, job->count);\n job->error_code = errno;\n}" ({) "{" (expression_statement) "job->result = readv(job->fd, job->iovecs, job->count);" (assignment_expression) "job->result = readv(job->fd, job->iovecs, job->count)" (field_expression) "job->result" (identifier) "job" (->) "->" (field_identifier) "result" (=) "=" (call_expression) "readv(job->fd, job->iovecs, job->count)" (identifier) "readv" (argument_list) "(job->fd, job->iovecs, job->count)" (() "(" (field_expression) "job->fd" (identifier) "job" (->) "->" (field_identifier) "fd" (,) "," (field_expression) "job->iovecs" (identifier) "job" (->) "->" (field_identifier) "iovecs" (,) "," (field_expression) "job->count" (identifier) "job" (->) "->" (field_identifier) "count" ()) ")" (;) ";" (expression_statement) "job->error_code = errno;" (assignment_expression) "job->error_code = errno" (field_expression) "job->error_code" (identifier) "job" (->) "->" (field_identifier) "error_code" (=) "=" (identifier) "errno" (;) ";" (}) "}" (function_definition) "static value result_readv(struct job_readv *job)\n{\n struct readv_copy_to *read_buffer;\n\n /* If the read is successful, copy data to the OCaml buffers. */\n if (job->result != -1) {\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);\n }\n }\n\n /* Free heap-allocated structures and buffers. */\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n free(read_buffer->temporary_buffer);\n caml_remove_generational_global_root(&read_buffer->caml_buffer);\n }\n free(job->iovecs);\n\n /* Decide on the actual result. */\n ssize_t result = job->result;\n LWT_UNIX_CHECK_JOB(job, result < 0, "readv");\n lwt_unix_free_job(&job->job);\n return Val_long(result);\n}" (storage_class_specifier) "static" (static) "static" (type_identifier) "value" (function_declarator) "result_readv(struct job_readv *job)" (identifier) "result_readv" (parameter_list) "(struct job_readv *job)" (() "(" (parameter_declaration) "struct job_readv *job" (struct_specifier) "struct job_readv" (struct) "struct" (type_identifier) "job_readv" (pointer_declarator) "*job" (*) "*" (identifier) "job" ()) ")" (compound_statement) "{\n struct readv_copy_to *read_buffer;\n\n /* If the read is successful, copy data to the OCaml buffers. */\n if (job->result != -1) {\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);\n }\n }\n\n /* Free heap-allocated structures and buffers. */\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n free(read_buffer->temporary_buffer);\n caml_remove_generational_global_root(&read_buffer->caml_buffer);\n }\n free(job->iovecs);\n\n /* Decide on the actual result. */\n ssize_t result = job->result;\n LWT_UNIX_CHECK_JOB(job, result < 0, "readv");\n lwt_unix_free_job(&job->job);\n return Val_long(result);\n}" ({) "{" (declaration) "struct readv_copy_to *read_buffer;" (struct_specifier) "struct readv_copy_to" (struct) "struct" (type_identifier) "readv_copy_to" (pointer_declarator) "*read_buffer" (*) "*" (identifier) "read_buffer" (;) ";" (comment) "/* If the read is successful, copy data to the OCaml buffers. */" (if_statement) "if (job->result != -1) {\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);\n }\n }" (if) "if" (parenthesized_expression) "(job->result != -1)" (() "(" (binary_expression) "job->result != -1" (field_expression) "job->result" (identifier) "job" (->) "->" (field_identifier) "result" (!=) "!=" (number_literal) "-1" ()) ")" (compound_statement) "{\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);\n }\n }" ({) "{" (for_statement) "for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);\n }" (for) "for" (() "(" (assignment_expression) "read_buffer = job->buffers" (identifier) "read_buffer" (=) "=" (field_expression) "job->buffers" (identifier) "job" (->) "->" (field_identifier) "buffers" (;) ";" (binary_expression) "read_buffer->temporary_buffer != NULL" (field_expression) "read_buffer->temporary_buffer" (identifier) "read_buffer" (->) "->" (field_identifier) "temporary_buffer" (!=) "!=" (null) "NULL" (NULL) "NULL" (;) ";" (update_expression) "++read_buffer" (++) "++" (identifier) "read_buffer" ()) ")" (compound_statement) "{\n memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);\n }" ({) "{" (expression_statement) "memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);" (call_expression) "memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length)" (identifier) "memcpy" (argument_list) "(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length)" (() "(" (pointer_expression) "&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset)" (&) "&" (call_expression) "Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset)" (identifier) "Byte" (argument_list) "(String_val(read_buffer->caml_buffer),\n read_buffer->offset)" (() "(" (call_expression) "String_val(read_buffer->caml_buffer)" (identifier) "String_val" (argument_list) "(read_buffer->caml_buffer)" (() "(" (field_expression) "read_buffer->caml_buffer" (identifier) "read_buffer" (->) "->" (field_identifier) "caml_buffer" ()) ")" (,) "," (field_expression) "read_buffer->offset" (identifier) "read_buffer" (->) "->" (field_identifier) "offset" ()) ")" (,) "," (field_expression) "read_buffer->temporary_buffer" (identifier) "read_buffer" (->) "->" (field_identifier) "temporary_buffer" (,) "," (field_expression) "read_buffer->length" (identifier) "read_buffer" (->) "->" (field_identifier) "length" ()) ")" (;) ";" (}) "}" (}) "}" (comment) "/* Free heap-allocated structures and buffers. */" (for_statement) "for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n free(read_buffer->temporary_buffer);\n caml_remove_generational_global_root(&read_buffer->caml_buffer);\n }" (for) "for" (() "(" (assignment_expression) "read_buffer = job->buffers" (identifier) "read_buffer" (=) "=" (field_expression) "job->buffers" (identifier) "job" (->) "->" (field_identifier) "buffers" (;) ";" (binary_expression) "read_buffer->temporary_buffer != NULL" (field_expression) "read_buffer->temporary_buffer" (identifier) "read_buffer" (->) "->" (field_identifier) "temporary_buffer" (!=) "!=" (null) "NULL" (NULL) "NULL" (;) ";" (update_expression) "++read_buffer" (++) "++" (identifier) "read_buffer" ()) ")" (compound_statement) "{\n free(read_buffer->temporary_buffer);\n caml_remove_generational_global_root(&read_buffer->caml_buffer);\n }" ({) "{" (expression_statement) "free(read_buffer->temporary_buffer);" (call_expression) "free(read_buffer->temporary_buffer)" (identifier) "free" (argument_list) "(read_buffer->temporary_buffer)" (() "(" (field_expression) "read_buffer->temporary_buffer" (identifier) "read_buffer" (->) "->" (field_identifier) "temporary_buffer" ()) ")" (;) ";" (expression_statement) "caml_remove_generational_global_root(&read_buffer->caml_buffer);" (call_expression) "caml_remove_generational_global_root(&read_buffer->caml_buffer)" (identifier) "caml_remove_generational_global_root" (argument_list) "(&read_buffer->caml_buffer)" (() "(" (pointer_expression) "&read_buffer->caml_buffer" (&) "&" (field_expression) "read_buffer->caml_buffer" (identifier) "read_buffer" (->) "->" (field_identifier) "caml_buffer" ()) ")" (;) ";" (}) "}" (expression_statement) "free(job->iovecs);" (call_expression) "free(job->iovecs)" (identifier) "free" (argument_list) "(job->iovecs)" (() "(" (field_expression) "job->iovecs" (identifier) "job" (->) "->" (field_identifier) "iovecs" ()) ")" (;) ";" (comment) "/* Decide on the actual result. */" (declaration) "ssize_t result = job->result;" (primitive_type) "ssize_t" (init_declarator) "result = job->result" (identifier) "result" (=) "=" (field_expression) "job->result" (identifier) "job" (->) "->" (field_identifier) "result" (;) ";" (expression_statement) "LWT_UNIX_CHECK_JOB(job, result < 0, "readv");" (call_expression) "LWT_UNIX_CHECK_JOB(job, result < 0, "readv")" (identifier) "LWT_UNIX_CHECK_JOB" (argument_list) "(job, result < 0, "readv")" (() "(" (identifier) "job" (,) "," (binary_expression) "result < 0" (identifier) "result" (<) "<" (number_literal) "0" (,) "," (string_literal) ""readv"" (") """ (string_content) "readv" (") """ ()) ")" (;) ";" (expression_statement) "lwt_unix_free_job(&job->job);" (call_expression) "lwt_unix_free_job(&job->job)" (identifier) "lwt_unix_free_job" (argument_list) "(&job->job)" (() "(" (pointer_expression) "&job->job" (&) "&" (field_expression) "job->job" (identifier) "job" (->) "->" (field_identifier) "job" ()) ")" (;) ";" (return_statement) "return Val_long(result);" (return) "return" (call_expression) "Val_long(result)" (identifier) "Val_long" (argument_list) "(result)" (() "(" (identifier) "result" ()) ")" (;) ";" (}) "}" (function_definition) "CAMLprim value lwt_unix_readv_job(value fd, value io_vectors, value val_count)\n{\n CAMLparam3(fd, io_vectors, val_count);\n\n size_t count = Long_val(val_count);\n\n /* The extra struct readv_copy_to (+ 1) is for the final terminator, in case\n all buffer slices are in bytes buffers. */\n LWT_UNIX_INIT_JOB(job, readv, sizeof(struct readv_copy_to) * (count + 1));\n job->fd = Int_val(fd);\n job->count = count;\n\n /* Assemble iovec structures on the heap. */\n job->iovecs = lwt_unix_malloc(sizeof(struct iovec) * count);\n flatten_io_vectors(job->iovecs, io_vectors, count, NULL, job->buffers);\n\n CAMLreturn(lwt_unix_alloc_job(&job->job));\n}" (type_identifier) "CAMLprim" (ERROR) "value" (identifier) "value" (function_declarator) "lwt_unix_readv_job(value fd, value io_vectors, value val_count)" (identifier) "lwt_unix_readv_job" (parameter_list) "(value fd, value io_vectors, value val_count)" (() "(" (parameter_declaration) "value fd" (type_identifier) "value" (identifier) "fd" (,) "," (parameter_declaration) "value io_vectors" (type_identifier) "value" (identifier) "io_vectors" (,) "," (parameter_declaration) "value val_count" (type_identifier) "value" (identifier) "val_count" ()) ")" (compound_statement) "{\n CAMLparam3(fd, io_vectors, val_count);\n\n size_t count = Long_val(val_count);\n\n /* The extra struct readv_copy_to (+ 1) is for the final terminator, in case\n all buffer slices are in bytes buffers. */\n LWT_UNIX_INIT_JOB(job, readv, sizeof(struct readv_copy_to) * (count + 1));\n job->fd = Int_val(fd);\n job->count = count;\n\n /* Assemble iovec structures on the heap. */\n job->iovecs = lwt_unix_malloc(sizeof(struct iovec) * count);\n flatten_io_vectors(job->iovecs, io_vectors, count, NULL, job->buffers);\n\n CAMLreturn(lwt_unix_alloc_job(&job->job));\n}" ({) "{" (expression_statement) "CAMLparam3(fd, io_vectors, val_count);" (call_expression) "CAMLparam3(fd, io_vectors, val_count)" (identifier) "CAMLparam3" (argument_list) "(fd, io_vectors, val_count)" (() "(" (identifier) "fd" (,) "," (identifier) "io_vectors" (,) "," (identifier) "val_count" ()) ")" (;) ";" (declaration) "size_t count = Long_val(val_count);" (primitive_type) "size_t" (init_declarator) "count = Long_val(val_count)" (identifier) "count" (=) "=" (call_expression) "Long_val(val_count)" (identifier) "Long_val" (argument_list) "(val_count)" (() "(" (identifier) "val_count" ()) ")" (;) ";" (comment) "/* The extra struct readv_copy_to (+ 1) is for the final terminator, in case\n all buffer slices are in bytes buffers. */" (expression_statement) "LWT_UNIX_INIT_JOB(job, readv, sizeof(struct readv_copy_to) * (count + 1));" (call_expression) "LWT_UNIX_INIT_JOB(job, readv, sizeof(struct readv_copy_to) * (count + 1))" (identifier) "LWT_UNIX_INIT_JOB" (argument_list) "(job, readv, sizeof(struct readv_copy_to) * (count + 1))" (() "(" (identifier) "job" (,) "," (identifier) "readv" (,) "," (binary_expression) "sizeof(struct readv_copy_to) * (count + 1)" (sizeof_expression) "sizeof(struct readv_copy_to)" (sizeof) "sizeof" (() "(" (type_descriptor) "struct readv_copy_to" (struct_specifier) "struct readv_copy_to" (struct) "struct" (type_identifier) "readv_copy_to" ()) ")" (*) "*" (parenthesized_expression) "(count + 1)" (() "(" (binary_expression) "count + 1" (identifier) "count" (+) "+" (number_literal) "1" ()) ")" ()) ")" (;) ";" (expression_statement) "job->fd = Int_val(fd);" (assignment_expression) "job->fd = Int_val(fd)" (field_expression) "job->fd" (identifier) "job" (->) "->" (field_identifier) "fd" (=) "=" (call_expression) "Int_val(fd)" (identifier) "Int_val" (argument_list) "(fd)" (() "(" (identifier) "fd" ()) ")" (;) ";" (expression_statement) "job->count = count;" (assignment_expression) "job->count = count" (field_expression) "job->count" (identifier) "job" (->) "->" (field_identifier) "count" (=) "=" (identifier) "count" (;) ";" (comment) "/* Assemble iovec structures on the heap. */" (expression_statement) "job->iovecs = lwt_unix_malloc(sizeof(struct iovec) * count);" (assignment_expression) "job->iovecs = lwt_unix_malloc(sizeof(struct iovec) * count)" (field_expression) "job->iovecs" (identifier) "job" (->) "->" (field_identifier) "iovecs" (=) "=" (call_expression) "lwt_unix_malloc(sizeof(struct iovec) * count)" (identifier) "lwt_unix_malloc" (argument_list) "(sizeof(struct iovec) * count)" (() "(" (binary_expression) "sizeof(struct iovec) * count" (sizeof_expression) "sizeof(struct iovec)" (sizeof) "sizeof" (() "(" (type_descriptor) "struct iovec" (struct_specifier) "struct iovec" (struct) "struct" (type_identifier) "iovec" ()) ")" (*) "*" (identifier) "count" ()) ")" (;) ";" (expression_statement) "flatten_io_vectors(job->iovecs, io_vectors, count, NULL, job->buffers);" (call_expression) "flatten_io_vectors(job->iovecs, io_vectors, count, NULL, job->buffers)" (identifier) "flatten_io_vectors" (argument_list) "(job->iovecs, io_vectors, count, NULL, job->buffers)" (() "(" (field_expression) "job->iovecs" (identifier) "job" (->) "->" (field_identifier) "iovecs" (,) "," (identifier) "io_vectors" (,) "," (identifier) "count" (,) "," (null) "NULL" (NULL) "NULL" (,) "," (field_expression) "job->buffers" (identifier) "job" (->) "->" (field_identifier) "buffers" ()) ")" (;) ";" (expression_statement) "CAMLreturn(lwt_unix_alloc_job(&job->job));" (call_expression) "CAMLreturn(lwt_unix_alloc_job(&job->job))" (identifier) "CAMLreturn" (argument_list) "(lwt_unix_alloc_job(&job->job))" (() "(" (call_expression) "lwt_unix_alloc_job(&job->job)" (identifier) "lwt_unix_alloc_job" (argument_list) "(&job->job)" (() "(" (pointer_expression) "&job->job" (&) "&" (field_expression) "job->job" (identifier) "job" (->) "->" (field_identifier) "job" ()) ")" ()) ")" (;) ";" (}) "}" (#endif) "#endif"
537
1
{"language": "c", "success": true, "metadata": {"lines": 72, "avg_line_length": 37.35, "nodes": 334, "errors": 0, "source_hash": "731fa3785d2b933e08887374d91e8bfea116ce9e586323ac487a8b7de13b650f", "categorized_nodes": 264}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"lwt_config.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"lwt_config.h\"", "parent": 0, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 23}}, {"id": 3, "type": "preproc_if", "text": "#if !defined(LWT_ON_WINDOWS)\n\n#include <caml/memory.h>\n#include <caml/mlvalues.h>\n#include <caml/unixsupport.h>\n#include <errno.h>\n#include <string.h>\n\n#include \"lwt_unix.h\"\n#include \"unix_readv_writev_utils.h\"\n\n/* Job and readv primitives for blocking file descriptors. */\nstruct job_readv {\n struct lwt_unix_job job;\n int fd;\n int error_code;\n ssize_t result;\n size_t count;\n /* Heap-allocated iovec structures. */\n struct iovec *iovecs;\n /* Data to be read into bytes buffers is first read into temporary buffers\n on the C heap. This is an array of descriptors for copying that data into\n the actual bytes buffers. The array is terminated by a descriptor whose\n temporary_buffer member is NULL. */\n struct readv_copy_to buffers[];\n};\n\nstatic void worker_readv(struct job_readv *job)\n{\n job->result = readv(job->fd, job->iovecs, job->count);\n job->error_code = errno;\n}\n\nstatic value result_readv(struct job_readv *job)\n{\n struct readv_copy_to *read_buffer;\n\n /* If the read is successful, copy data to the OCaml buffers. */\n if (job->result != -1) {\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);\n }\n }\n\n /* Free heap-allocated structures and buffers. */\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n free(read_buffer->temporary_buffer);\n caml_remove_generational_global_root(&read_buffer->caml_buffer);\n }\n free(job->iovecs);\n\n /* Decide on the actual result. */\n ssize_t result = job->result;\n LWT_UNIX_CHECK_JOB(job, result < 0, \"readv\");\n lwt_unix_free_job(&job->job);\n return Val_long(result);\n}\n\nCAMLprim value lwt_unix_readv_job(value fd, value io_vectors, value val_count)\n{\n CAMLparam3(fd, io_vectors, val_count);\n\n size_t count = Long_val(val_count);\n\n /* The extra struct readv_copy_to (+ 1) is for the final terminator, in case\n all buffer slices are in bytes buffers. */\n LWT_UNIX_INIT_JOB(job, readv, sizeof(struct readv_copy_to) * (count + 1));\n job->fd = Int_val(fd);\n job->count = count;\n\n /* Assemble iovec structures on the heap. */\n job->iovecs = lwt_unix_malloc(sizeof(struct iovec) * count);\n flatten_io_vectors(job->iovecs, io_vectors, count, NULL, job->buffers);\n\n CAMLreturn(lwt_unix_alloc_job(&job->job));\n}\n#endif", "parent": null, "children": [4, 5, 10, 11, 14, 17, 20, 23, 26, 29, 32, 65, 100, 231, 333], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 87, "column": 6}}, {"id": 4, "type": "#if", "text": "#if", "parent": 3, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 3}}, {"id": 5, "type": "unary_expression", "text": "!defined(LWT_ON_WINDOWS)", "parent": 3, "children": [6, 7], "start_point": {"row": 7, "column": 4}, "end_point": {"row": 7, "column": 28}}, {"id": 6, "type": "!", "text": "!", "parent": 5, "children": [], "start_point": {"row": 7, "column": 4}, "end_point": {"row": 7, "column": 5}}, {"id": 7, "type": "preproc_defined", "text": "defined(LWT_ON_WINDOWS)", "parent": 5, "children": [8, 9], "start_point": {"row": 7, "column": 5}, "end_point": {"row": 7, "column": 28}}, {"id": 8, "type": "defined", "text": "defined", "parent": 7, "children": [], "start_point": {"row": 7, "column": 5}, "end_point": {"row": 7, "column": 12}}, {"id": 9, "type": "identifier", "text": "LWT_ON_WINDOWS", "parent": 7, "children": [], "start_point": {"row": 7, "column": 13}, "end_point": {"row": 7, "column": 27}}, {"id": 10, "type": "\n", "text": "\n\n", "parent": 3, "children": [], "start_point": {"row": 7, "column": 28}, "end_point": {"row": 9, "column": 0}}, {"id": 11, "type": "preproc_include", "text": "#include <caml/memory.h>\n", "parent": 3, "children": [12, 13], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 12, "type": "#include", "text": "#include", "parent": 11, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 8}}, {"id": 13, "type": "system_lib_string", "text": "<caml/memory.h>", "parent": 11, "children": [], "start_point": {"row": 9, "column": 9}, "end_point": {"row": 9, "column": 24}}, {"id": 14, "type": "preproc_include", "text": "#include <caml/mlvalues.h>\n", "parent": 3, "children": [15, 16], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 11, "column": 0}}, {"id": 15, "type": "#include", "text": "#include", "parent": 14, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 8}}, {"id": 16, "type": "system_lib_string", "text": "<caml/mlvalues.h>", "parent": 14, "children": [], "start_point": {"row": 10, "column": 9}, "end_point": {"row": 10, "column": 26}}, {"id": 17, "type": "preproc_include", "text": "#include <caml/unixsupport.h>\n", "parent": 3, "children": [18, 19], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 12, "column": 0}}, {"id": 18, "type": "#include", "text": "#include", "parent": 17, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 8}}, {"id": 19, "type": "system_lib_string", "text": "<caml/unixsupport.h>", "parent": 17, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 29}}, {"id": 20, "type": "preproc_include", "text": "#include <errno.h>\n", "parent": 3, "children": [21, 22], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 13, "column": 0}}, {"id": 21, "type": "#include", "text": "#include", "parent": 20, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 8}}, {"id": 22, "type": "system_lib_string", "text": "<errno.h>", "parent": 20, "children": [], "start_point": {"row": 12, "column": 9}, "end_point": {"row": 12, "column": 18}}, {"id": 23, "type": "preproc_include", "text": "#include <string.h>\n", "parent": 3, "children": [24, 25], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 14, "column": 0}}, {"id": 24, "type": "#include", "text": "#include", "parent": 23, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 8}}, {"id": 25, "type": "system_lib_string", "text": "<string.h>", "parent": 23, "children": [], "start_point": {"row": 13, "column": 9}, "end_point": {"row": 13, "column": 19}}, {"id": 26, "type": "preproc_include", "text": "#include \"lwt_unix.h\"\n", "parent": 3, "children": [27, 28], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 16, "column": 0}}, {"id": 27, "type": "#include", "text": "#include", "parent": 26, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 8}}, {"id": 28, "type": "string_literal", "text": "\"lwt_unix.h\"", "parent": 26, "children": [], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 21}}, {"id": 29, "type": "preproc_include", "text": "#include \"unix_readv_writev_utils.h\"\n", "parent": 3, "children": [30, 31], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 17, "column": 0}}, {"id": 30, "type": "#include", "text": "#include", "parent": 29, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 8}}, {"id": 31, "type": "string_literal", "text": "\"unix_readv_writev_utils.h\"", "parent": 29, "children": [], "start_point": {"row": 16, "column": 9}, "end_point": {"row": 16, "column": 36}}, {"id": 32, "type": "struct_specifier", "text": "struct job_readv {\n struct lwt_unix_job job;\n int fd;\n int error_code;\n ssize_t result;\n size_t count;\n /* Heap-allocated iovec structures. */\n struct iovec *iovecs;\n /* Data to be read into bytes buffers is first read into temporary buffers\n on the C heap. This is an array of descriptors for copying that data into\n the actual bytes buffers. The array is terminated by a descriptor whose\n temporary_buffer member is NULL. */\n struct readv_copy_to buffers[];\n}", "parent": 3, "children": [33, 34], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 32, "column": 1}}, {"id": 33, "type": "struct", "text": "struct", "parent": 32, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 6}}, {"id": 34, "type": "type_identifier", "text": "job_readv", "parent": 32, "children": [], "start_point": {"row": 19, "column": 7}, "end_point": {"row": 19, "column": 16}}, {"id": 35, "type": "field_declaration", "text": "struct lwt_unix_job job;", "parent": 32, "children": [36, 39], "start_point": {"row": 20, "column": 4}, "end_point": {"row": 20, "column": 28}}, {"id": 36, "type": "struct_specifier", "text": "struct lwt_unix_job", "parent": 35, "children": [37, 38], "start_point": {"row": 20, "column": 4}, "end_point": {"row": 20, "column": 23}}, {"id": 37, "type": "struct", "text": "struct", "parent": 36, "children": [], "start_point": {"row": 20, "column": 4}, "end_point": {"row": 20, "column": 10}}, {"id": 38, "type": "type_identifier", "text": "lwt_unix_job", "parent": 36, "children": [], "start_point": {"row": 20, "column": 11}, "end_point": {"row": 20, "column": 23}}, {"id": 39, "type": "field_identifier", "text": "job", "parent": 35, "children": [], "start_point": {"row": 20, "column": 24}, "end_point": {"row": 20, "column": 27}}, {"id": 40, "type": "field_declaration", "text": "int fd;", "parent": 32, "children": [41, 42], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 21, "column": 11}}, {"id": 41, "type": "primitive_type", "text": "int", "parent": 40, "children": [], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 21, "column": 7}}, {"id": 42, "type": "field_identifier", "text": "fd", "parent": 40, "children": [], "start_point": {"row": 21, "column": 8}, "end_point": {"row": 21, "column": 10}}, {"id": 43, "type": "field_declaration", "text": "int error_code;", "parent": 32, "children": [44, 45], "start_point": {"row": 22, "column": 4}, "end_point": {"row": 22, "column": 19}}, {"id": 44, "type": "primitive_type", "text": "int", "parent": 43, "children": [], "start_point": {"row": 22, "column": 4}, "end_point": {"row": 22, "column": 7}}, {"id": 45, "type": "field_identifier", "text": "error_code", "parent": 43, "children": [], "start_point": {"row": 22, "column": 8}, "end_point": {"row": 22, "column": 18}}, {"id": 46, "type": "field_declaration", "text": "ssize_t result;", "parent": 32, "children": [47, 48], "start_point": {"row": 23, "column": 4}, "end_point": {"row": 23, "column": 19}}, {"id": 47, "type": "primitive_type", "text": "ssize_t", "parent": 46, "children": [], "start_point": {"row": 23, "column": 4}, "end_point": {"row": 23, "column": 11}}, {"id": 48, "type": "field_identifier", "text": "result", "parent": 46, "children": [], "start_point": {"row": 23, "column": 12}, "end_point": {"row": 23, "column": 18}}, {"id": 49, "type": "field_declaration", "text": "size_t count;", "parent": 32, "children": [50, 51], "start_point": {"row": 24, "column": 4}, "end_point": {"row": 24, "column": 17}}, {"id": 50, "type": "primitive_type", "text": "size_t", "parent": 49, "children": [], "start_point": {"row": 24, "column": 4}, "end_point": {"row": 24, "column": 10}}, {"id": 51, "type": "field_identifier", "text": "count", "parent": 49, "children": [], "start_point": {"row": 24, "column": 11}, "end_point": {"row": 24, "column": 16}}, {"id": 52, "type": "field_declaration", "text": "struct iovec *iovecs;", "parent": 32, "children": [53, 56], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 26, "column": 25}}, {"id": 53, "type": "struct_specifier", "text": "struct iovec", "parent": 52, "children": [54, 55], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 26, "column": 16}}, {"id": 54, "type": "struct", "text": "struct", "parent": 53, "children": [], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 26, "column": 10}}, {"id": 55, "type": "type_identifier", "text": "iovec", "parent": 53, "children": [], "start_point": {"row": 26, "column": 11}, "end_point": {"row": 26, "column": 16}}, {"id": 56, "type": "pointer_declarator", "text": "*iovecs", "parent": 52, "children": [57, 58], "start_point": {"row": 26, "column": 17}, "end_point": {"row": 26, "column": 24}}, {"id": 57, "type": "*", "text": "*", "parent": 56, "children": [], "start_point": {"row": 26, "column": 17}, "end_point": {"row": 26, "column": 18}}, {"id": 58, "type": "field_identifier", "text": "iovecs", "parent": 56, "children": [], "start_point": {"row": 26, "column": 18}, "end_point": {"row": 26, "column": 24}}, {"id": 59, "type": "field_declaration", "text": "struct readv_copy_to buffers[];", "parent": 32, "children": [60, 63], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 35}}, {"id": 60, "type": "struct_specifier", "text": "struct readv_copy_to", "parent": 59, "children": [61, 62], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 24}}, {"id": 61, "type": "struct", "text": "struct", "parent": 60, "children": [], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 10}}, {"id": 62, "type": "type_identifier", "text": "readv_copy_to", "parent": 60, "children": [], "start_point": {"row": 31, "column": 11}, "end_point": {"row": 31, "column": 24}}, {"id": 63, "type": "array_declarator", "text": "buffers[]", "parent": 59, "children": [64], "start_point": {"row": 31, "column": 25}, "end_point": {"row": 31, "column": 34}}, {"id": 64, "type": "field_identifier", "text": "buffers", "parent": 63, "children": [], "start_point": {"row": 31, "column": 25}, "end_point": {"row": 31, "column": 32}}, {"id": 65, "type": "function_definition", "text": "static void worker_readv(struct job_readv *job)\n{\n job->result = readv(job->fd, job->iovecs, job->count);\n job->error_code = errno;\n}", "parent": 3, "children": [66, 67], "start_point": {"row": 34, "column": 0}, "end_point": {"row": 38, "column": 1}}, {"id": 66, "type": "primitive_type", "text": "void", "parent": 65, "children": [], "start_point": {"row": 34, "column": 7}, "end_point": {"row": 34, "column": 11}}, {"id": 67, "type": "function_declarator", "text": "worker_readv(struct job_readv *job)", "parent": 65, "children": [68, 69], "start_point": {"row": 34, "column": 12}, "end_point": {"row": 34, "column": 47}}, {"id": 68, "type": "identifier", "text": "worker_readv", "parent": 67, "children": [], "start_point": {"row": 34, "column": 12}, "end_point": {"row": 34, "column": 24}}, {"id": 69, "type": "parameter_list", "text": "(struct job_readv *job)", "parent": 67, "children": [70], "start_point": {"row": 34, "column": 24}, "end_point": {"row": 34, "column": 47}}, {"id": 70, "type": "parameter_declaration", "text": "struct job_readv *job", "parent": 69, "children": [71, 74], "start_point": {"row": 34, "column": 25}, "end_point": {"row": 34, "column": 46}}, {"id": 71, "type": "struct_specifier", "text": "struct job_readv", "parent": 70, "children": [72, 73], "start_point": {"row": 34, "column": 25}, "end_point": {"row": 34, "column": 41}}, {"id": 72, "type": "struct", "text": "struct", "parent": 71, "children": [], "start_point": {"row": 34, "column": 25}, "end_point": {"row": 34, "column": 31}}, {"id": 73, "type": "type_identifier", "text": "job_readv", "parent": 71, "children": [], "start_point": {"row": 34, "column": 32}, "end_point": {"row": 34, "column": 41}}, {"id": 74, "type": "pointer_declarator", "text": "*job", "parent": 70, "children": [75, 76], "start_point": {"row": 34, "column": 42}, "end_point": {"row": 34, "column": 46}}, {"id": 75, "type": "*", "text": "*", "parent": 74, "children": [], "start_point": {"row": 34, "column": 42}, "end_point": {"row": 34, "column": 43}}, {"id": 76, "type": "identifier", "text": "job", "parent": 74, "children": [], "start_point": {"row": 34, "column": 43}, "end_point": {"row": 34, "column": 46}}, {"id": 77, "type": "assignment_expression", "text": "job->result = readv(job->fd, job->iovecs, job->count)", "parent": 65, "children": [78, 81, 82], "start_point": {"row": 36, "column": 4}, "end_point": {"row": 36, "column": 57}}, {"id": 78, "type": "field_expression", "text": "job->result", "parent": 77, "children": [79, 80], "start_point": {"row": 36, "column": 4}, "end_point": {"row": 36, "column": 15}}, {"id": 79, "type": "identifier", "text": "job", "parent": 78, "children": [], "start_point": {"row": 36, "column": 4}, "end_point": {"row": 36, "column": 7}}, {"id": 80, "type": "field_identifier", "text": "result", "parent": 78, "children": [], "start_point": {"row": 36, "column": 9}, "end_point": {"row": 36, "column": 15}}, {"id": 81, "type": "=", "text": "=", "parent": 77, "children": [], "start_point": {"row": 36, "column": 16}, "end_point": {"row": 36, "column": 17}}, {"id": 82, "type": "call_expression", "text": "readv(job->fd, job->iovecs, job->count)", "parent": 77, "children": [83, 84], "start_point": {"row": 36, "column": 18}, "end_point": {"row": 36, "column": 57}}, {"id": 83, "type": "identifier", "text": "readv", "parent": 82, "children": [], "start_point": {"row": 36, "column": 18}, "end_point": {"row": 36, "column": 23}}, {"id": 84, "type": "argument_list", "text": "(job->fd, job->iovecs, job->count)", "parent": 82, "children": [85, 88, 91], "start_point": {"row": 36, "column": 23}, "end_point": {"row": 36, "column": 57}}, {"id": 85, "type": "field_expression", "text": "job->fd", "parent": 84, "children": [86, 87], "start_point": {"row": 36, "column": 24}, "end_point": {"row": 36, "column": 31}}, {"id": 86, "type": "identifier", "text": "job", "parent": 85, "children": [], "start_point": {"row": 36, "column": 24}, "end_point": {"row": 36, "column": 27}}, {"id": 87, "type": "field_identifier", "text": "fd", "parent": 85, "children": [], "start_point": {"row": 36, "column": 29}, "end_point": {"row": 36, "column": 31}}, {"id": 88, "type": "field_expression", "text": "job->iovecs", "parent": 84, "children": [89, 90], "start_point": {"row": 36, "column": 33}, "end_point": {"row": 36, "column": 44}}, {"id": 89, "type": "identifier", "text": "job", "parent": 88, "children": [], "start_point": {"row": 36, "column": 33}, "end_point": {"row": 36, "column": 36}}, {"id": 90, "type": "field_identifier", "text": "iovecs", "parent": 88, "children": [], "start_point": {"row": 36, "column": 38}, "end_point": {"row": 36, "column": 44}}, {"id": 91, "type": "field_expression", "text": "job->count", "parent": 84, "children": [92, 93], "start_point": {"row": 36, "column": 46}, "end_point": {"row": 36, "column": 56}}, {"id": 92, "type": "identifier", "text": "job", "parent": 91, "children": [], "start_point": {"row": 36, "column": 46}, "end_point": {"row": 36, "column": 49}}, {"id": 93, "type": "field_identifier", "text": "count", "parent": 91, "children": [], "start_point": {"row": 36, "column": 51}, "end_point": {"row": 36, "column": 56}}, {"id": 94, "type": "assignment_expression", "text": "job->error_code = errno", "parent": 65, "children": [95, 98, 99], "start_point": {"row": 37, "column": 4}, "end_point": {"row": 37, "column": 27}}, {"id": 95, "type": "field_expression", "text": "job->error_code", "parent": 94, "children": [96, 97], "start_point": {"row": 37, "column": 4}, "end_point": {"row": 37, "column": 19}}, {"id": 96, "type": "identifier", "text": "job", "parent": 95, "children": [], "start_point": {"row": 37, "column": 4}, "end_point": {"row": 37, "column": 7}}, {"id": 97, "type": "field_identifier", "text": "error_code", "parent": 95, "children": [], "start_point": {"row": 37, "column": 9}, "end_point": {"row": 37, "column": 19}}, {"id": 98, "type": "=", "text": "=", "parent": 94, "children": [], "start_point": {"row": 37, "column": 20}, "end_point": {"row": 37, "column": 21}}, {"id": 99, "type": "identifier", "text": "errno", "parent": 94, "children": [], "start_point": {"row": 37, "column": 22}, "end_point": {"row": 37, "column": 27}}, {"id": 100, "type": "function_definition", "text": "static value result_readv(struct job_readv *job)\n{\n struct readv_copy_to *read_buffer;\n\n /* If the read is successful, copy data to the OCaml buffers. */\n if (job->result != -1) {\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);\n }\n }\n\n /* Free heap-allocated structures and buffers. */\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n free(read_buffer->temporary_buffer);\n caml_remove_generational_global_root(&read_buffer->caml_buffer);\n }\n free(job->iovecs);\n\n /* Decide on the actual result. */\n ssize_t result = job->result;\n LWT_UNIX_CHECK_JOB(job, result < 0, \"readv\");\n lwt_unix_free_job(&job->job);\n return Val_long(result);\n}", "parent": 3, "children": [101, 102], "start_point": {"row": 40, "column": 0}, "end_point": {"row": 67, "column": 1}}, {"id": 101, "type": "type_identifier", "text": "value", "parent": 100, "children": [], "start_point": {"row": 40, "column": 7}, "end_point": {"row": 40, "column": 12}}, {"id": 102, "type": "function_declarator", "text": "result_readv(struct job_readv *job)", "parent": 100, "children": [103, 104], "start_point": {"row": 40, "column": 13}, "end_point": {"row": 40, "column": 48}}, {"id": 103, "type": "identifier", "text": "result_readv", "parent": 102, "children": [], "start_point": {"row": 40, "column": 13}, "end_point": {"row": 40, "column": 25}}, {"id": 104, "type": "parameter_list", "text": "(struct job_readv *job)", "parent": 102, "children": [105], "start_point": {"row": 40, "column": 25}, "end_point": {"row": 40, "column": 48}}, {"id": 105, "type": "parameter_declaration", "text": "struct job_readv *job", "parent": 104, "children": [106, 109], "start_point": {"row": 40, "column": 26}, "end_point": {"row": 40, "column": 47}}, {"id": 106, "type": "struct_specifier", "text": "struct job_readv", "parent": 105, "children": [107, 108], "start_point": {"row": 40, "column": 26}, "end_point": {"row": 40, "column": 42}}, {"id": 107, "type": "struct", "text": "struct", "parent": 106, "children": [], "start_point": {"row": 40, "column": 26}, "end_point": {"row": 40, "column": 32}}, {"id": 108, "type": "type_identifier", "text": "job_readv", "parent": 106, "children": [], "start_point": {"row": 40, "column": 33}, "end_point": {"row": 40, "column": 42}}, {"id": 109, "type": "pointer_declarator", "text": "*job", "parent": 105, "children": [110, 111], "start_point": {"row": 40, "column": 43}, "end_point": {"row": 40, "column": 47}}, {"id": 110, "type": "*", "text": "*", "parent": 109, "children": [], "start_point": {"row": 40, "column": 43}, "end_point": {"row": 40, "column": 44}}, {"id": 111, "type": "identifier", "text": "job", "parent": 109, "children": [], "start_point": {"row": 40, "column": 44}, "end_point": {"row": 40, "column": 47}}, {"id": 112, "type": "declaration", "text": "struct readv_copy_to *read_buffer;", "parent": 100, "children": [113, 116], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 38}}, {"id": 113, "type": "struct_specifier", "text": "struct readv_copy_to", "parent": 112, "children": [114, 115], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 24}}, {"id": 114, "type": "struct", "text": "struct", "parent": 113, "children": [], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 10}}, {"id": 115, "type": "type_identifier", "text": "readv_copy_to", "parent": 113, "children": [], "start_point": {"row": 42, "column": 11}, "end_point": {"row": 42, "column": 24}}, {"id": 116, "type": "pointer_declarator", "text": "*read_buffer", "parent": 112, "children": [117, 118], "start_point": {"row": 42, "column": 25}, "end_point": {"row": 42, "column": 37}}, {"id": 117, "type": "*", "text": "*", "parent": 116, "children": [], "start_point": {"row": 42, "column": 25}, "end_point": {"row": 42, "column": 26}}, {"id": 118, "type": "identifier", "text": "read_buffer", "parent": 116, "children": [], "start_point": {"row": 42, "column": 26}, "end_point": {"row": 42, "column": 37}}, {"id": 119, "type": "if_statement", "text": "if (job->result != -1) {\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);\n }\n }", "parent": 100, "children": [120], "start_point": {"row": 45, "column": 4}, "end_point": {"row": 52, "column": 5}}, {"id": 120, "type": "parenthesized_expression", "text": "(job->result != -1)", "parent": 119, "children": [121], "start_point": {"row": 45, "column": 7}, "end_point": {"row": 45, "column": 26}}, {"id": 121, "type": "binary_expression", "text": "job->result != -1", "parent": 120, "children": [122, 125, 126], "start_point": {"row": 45, "column": 8}, "end_point": {"row": 45, "column": 25}}, {"id": 122, "type": "field_expression", "text": "job->result", "parent": 121, "children": [123, 124], "start_point": {"row": 45, "column": 8}, "end_point": {"row": 45, "column": 19}}, {"id": 123, "type": "identifier", "text": "job", "parent": 122, "children": [], "start_point": {"row": 45, "column": 8}, "end_point": {"row": 45, "column": 11}}, {"id": 124, "type": "field_identifier", "text": "result", "parent": 122, "children": [], "start_point": {"row": 45, "column": 13}, "end_point": {"row": 45, "column": 19}}, {"id": 125, "type": "!=", "text": "!=", "parent": 121, "children": [], "start_point": {"row": 45, "column": 20}, "end_point": {"row": 45, "column": 22}}, {"id": 126, "type": "number_literal", "text": "-1", "parent": 121, "children": [], "start_point": {"row": 45, "column": 23}, "end_point": {"row": 45, "column": 25}}, {"id": 127, "type": "for_statement", "text": "for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);\n }", "parent": 119, "children": [128, 134, 141], "start_point": {"row": 46, "column": 8}, "end_point": {"row": 51, "column": 9}}, {"id": 128, "type": "assignment_expression", "text": "read_buffer = job->buffers", "parent": 127, "children": [129, 130, 131], "start_point": {"row": 46, "column": 13}, "end_point": {"row": 46, "column": 39}}, {"id": 129, "type": "identifier", "text": "read_buffer", "parent": 128, "children": [], "start_point": {"row": 46, "column": 13}, "end_point": {"row": 46, "column": 24}}, {"id": 130, "type": "=", "text": "=", "parent": 128, "children": [], "start_point": {"row": 46, "column": 25}, "end_point": {"row": 46, "column": 26}}, {"id": 131, "type": "field_expression", "text": "job->buffers", "parent": 128, "children": [132, 133], "start_point": {"row": 46, "column": 27}, "end_point": {"row": 46, "column": 39}}, {"id": 132, "type": "identifier", "text": "job", "parent": 131, "children": [], "start_point": {"row": 46, "column": 27}, "end_point": {"row": 46, "column": 30}}, {"id": 133, "type": "field_identifier", "text": "buffers", "parent": 131, "children": [], "start_point": {"row": 46, "column": 32}, "end_point": {"row": 46, "column": 39}}, {"id": 134, "type": "binary_expression", "text": "read_buffer->temporary_buffer != NULL", "parent": 127, "children": [135, 138, 139], "start_point": {"row": 46, "column": 41}, "end_point": {"row": 46, "column": 78}}, {"id": 135, "type": "field_expression", "text": "read_buffer->temporary_buffer", "parent": 134, "children": [136, 137], "start_point": {"row": 46, "column": 41}, "end_point": {"row": 46, "column": 70}}, {"id": 136, "type": "identifier", "text": "read_buffer", "parent": 135, "children": [], "start_point": {"row": 46, "column": 41}, "end_point": {"row": 46, "column": 52}}, {"id": 137, "type": "field_identifier", "text": "temporary_buffer", "parent": 135, "children": [], "start_point": {"row": 46, "column": 54}, "end_point": {"row": 46, "column": 70}}, {"id": 138, "type": "!=", "text": "!=", "parent": 134, "children": [], "start_point": {"row": 46, "column": 71}, "end_point": {"row": 46, "column": 73}}, {"id": 139, "type": "null", "text": "NULL", "parent": 134, "children": [140], "start_point": {"row": 46, "column": 74}, "end_point": {"row": 46, "column": 78}}, {"id": 140, "type": "NULL", "text": "NULL", "parent": 139, "children": [], "start_point": {"row": 46, "column": 74}, "end_point": {"row": 46, "column": 78}}, {"id": 141, "type": "update_expression", "text": "++read_buffer", "parent": 127, "children": [142, 143], "start_point": {"row": 47, "column": 13}, "end_point": {"row": 47, "column": 26}}, {"id": 142, "type": "++", "text": "++", "parent": 141, "children": [], "start_point": {"row": 47, "column": 13}, "end_point": {"row": 47, "column": 15}}, {"id": 143, "type": "identifier", "text": "read_buffer", "parent": 141, "children": [], "start_point": {"row": 47, "column": 15}, "end_point": {"row": 47, "column": 26}}, {"id": 144, "type": "call_expression", "text": "memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length)", "parent": 127, "children": [145, 146], "start_point": {"row": 48, "column": 12}, "end_point": {"row": 50, "column": 70}}, {"id": 145, "type": "identifier", "text": "memcpy", "parent": 144, "children": [], "start_point": {"row": 48, "column": 12}, "end_point": {"row": 48, "column": 18}}, {"id": 146, "type": "argument_list", "text": "(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length)", "parent": 144, "children": [147, 160, 163], "start_point": {"row": 48, "column": 18}, "end_point": {"row": 50, "column": 70}}, {"id": 147, "type": "pointer_expression", "text": "&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset)", "parent": 146, "children": [148], "start_point": {"row": 48, "column": 19}, "end_point": {"row": 49, "column": 45}}, {"id": 148, "type": "call_expression", "text": "Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset)", "parent": 147, "children": [149, 150], "start_point": {"row": 48, "column": 20}, "end_point": {"row": 49, "column": 45}}, {"id": 149, "type": "identifier", "text": "Byte", "parent": 148, "children": [], "start_point": {"row": 48, "column": 20}, "end_point": {"row": 48, "column": 24}}, {"id": 150, "type": "argument_list", "text": "(String_val(read_buffer->caml_buffer),\n read_buffer->offset)", "parent": 148, "children": [151, 157], "start_point": {"row": 48, "column": 24}, "end_point": {"row": 49, "column": 45}}, {"id": 151, "type": "call_expression", "text": "String_val(read_buffer->caml_buffer)", "parent": 150, "children": [152, 153], "start_point": {"row": 48, "column": 25}, "end_point": {"row": 48, "column": 61}}, {"id": 152, "type": "identifier", "text": "String_val", "parent": 151, "children": [], "start_point": {"row": 48, "column": 25}, "end_point": {"row": 48, "column": 35}}, {"id": 153, "type": "argument_list", "text": "(read_buffer->caml_buffer)", "parent": 151, "children": [154], "start_point": {"row": 48, "column": 35}, "end_point": {"row": 48, "column": 61}}, {"id": 154, "type": "field_expression", "text": "read_buffer->caml_buffer", "parent": 153, "children": [155, 156], "start_point": {"row": 48, "column": 36}, "end_point": {"row": 48, "column": 60}}, {"id": 155, "type": "identifier", "text": "read_buffer", "parent": 154, "children": [], "start_point": {"row": 48, "column": 36}, "end_point": {"row": 48, "column": 47}}, {"id": 156, "type": "field_identifier", "text": "caml_buffer", "parent": 154, "children": [], "start_point": {"row": 48, "column": 49}, "end_point": {"row": 48, "column": 60}}, {"id": 157, "type": "field_expression", "text": "read_buffer->offset", "parent": 150, "children": [158, 159], "start_point": {"row": 49, "column": 25}, "end_point": {"row": 49, "column": 44}}, {"id": 158, "type": "identifier", "text": "read_buffer", "parent": 157, "children": [], "start_point": {"row": 49, "column": 25}, "end_point": {"row": 49, "column": 36}}, {"id": 159, "type": "field_identifier", "text": "offset", "parent": 157, "children": [], "start_point": {"row": 49, "column": 38}, "end_point": {"row": 49, "column": 44}}, {"id": 160, "type": "field_expression", "text": "read_buffer->temporary_buffer", "parent": 146, "children": [161, 162], "start_point": {"row": 50, "column": 19}, "end_point": {"row": 50, "column": 48}}, {"id": 161, "type": "identifier", "text": "read_buffer", "parent": 160, "children": [], "start_point": {"row": 50, "column": 19}, "end_point": {"row": 50, "column": 30}}, {"id": 162, "type": "field_identifier", "text": "temporary_buffer", "parent": 160, "children": [], "start_point": {"row": 50, "column": 32}, "end_point": {"row": 50, "column": 48}}, {"id": 163, "type": "field_expression", "text": "read_buffer->length", "parent": 146, "children": [164, 165], "start_point": {"row": 50, "column": 50}, "end_point": {"row": 50, "column": 69}}, {"id": 164, "type": "identifier", "text": "read_buffer", "parent": 163, "children": [], "start_point": {"row": 50, "column": 50}, "end_point": {"row": 50, "column": 61}}, {"id": 165, "type": "field_identifier", "text": "length", "parent": 163, "children": [], "start_point": {"row": 50, "column": 63}, "end_point": {"row": 50, "column": 69}}, {"id": 166, "type": "for_statement", "text": "for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n free(read_buffer->temporary_buffer);\n caml_remove_generational_global_root(&read_buffer->caml_buffer);\n }", "parent": 100, "children": [167, 173, 180], "start_point": {"row": 55, "column": 4}, "end_point": {"row": 59, "column": 5}}, {"id": 167, "type": "assignment_expression", "text": "read_buffer = job->buffers", "parent": 166, "children": [168, 169, 170], "start_point": {"row": 55, "column": 9}, "end_point": {"row": 55, "column": 35}}, {"id": 168, "type": "identifier", "text": "read_buffer", "parent": 167, "children": [], "start_point": {"row": 55, "column": 9}, "end_point": {"row": 55, "column": 20}}, {"id": 169, "type": "=", "text": "=", "parent": 167, "children": [], "start_point": {"row": 55, "column": 21}, "end_point": {"row": 55, "column": 22}}, {"id": 170, "type": "field_expression", "text": "job->buffers", "parent": 167, "children": [171, 172], "start_point": {"row": 55, "column": 23}, "end_point": {"row": 55, "column": 35}}, {"id": 171, "type": "identifier", "text": "job", "parent": 170, "children": [], "start_point": {"row": 55, "column": 23}, "end_point": {"row": 55, "column": 26}}, {"id": 172, "type": "field_identifier", "text": "buffers", "parent": 170, "children": [], "start_point": {"row": 55, "column": 28}, "end_point": {"row": 55, "column": 35}}, {"id": 173, "type": "binary_expression", "text": "read_buffer->temporary_buffer != NULL", "parent": 166, "children": [174, 177, 178], "start_point": {"row": 55, "column": 37}, "end_point": {"row": 55, "column": 74}}, {"id": 174, "type": "field_expression", "text": "read_buffer->temporary_buffer", "parent": 173, "children": [175, 176], "start_point": {"row": 55, "column": 37}, "end_point": {"row": 55, "column": 66}}, {"id": 175, "type": "identifier", "text": "read_buffer", "parent": 174, "children": [], "start_point": {"row": 55, "column": 37}, "end_point": {"row": 55, "column": 48}}, {"id": 176, "type": "field_identifier", "text": "temporary_buffer", "parent": 174, "children": [], "start_point": {"row": 55, "column": 50}, "end_point": {"row": 55, "column": 66}}, {"id": 177, "type": "!=", "text": "!=", "parent": 173, "children": [], "start_point": {"row": 55, "column": 67}, "end_point": {"row": 55, "column": 69}}, {"id": 178, "type": "null", "text": "NULL", "parent": 173, "children": [179], "start_point": {"row": 55, "column": 70}, "end_point": {"row": 55, "column": 74}}, {"id": 179, "type": "NULL", "text": "NULL", "parent": 178, "children": [], "start_point": {"row": 55, "column": 70}, "end_point": {"row": 55, "column": 74}}, {"id": 180, "type": "update_expression", "text": "++read_buffer", "parent": 166, "children": [181, 182], "start_point": {"row": 56, "column": 9}, "end_point": {"row": 56, "column": 22}}, {"id": 181, "type": "++", "text": "++", "parent": 180, "children": [], "start_point": {"row": 56, "column": 9}, "end_point": {"row": 56, "column": 11}}, {"id": 182, "type": "identifier", "text": "read_buffer", "parent": 180, "children": [], "start_point": {"row": 56, "column": 11}, "end_point": {"row": 56, "column": 22}}, {"id": 183, "type": "call_expression", "text": "free(read_buffer->temporary_buffer)", "parent": 166, "children": [184, 185], "start_point": {"row": 57, "column": 8}, "end_point": {"row": 57, "column": 43}}, {"id": 184, "type": "identifier", "text": "free", "parent": 183, "children": [], "start_point": {"row": 57, "column": 8}, "end_point": {"row": 57, "column": 12}}, {"id": 185, "type": "argument_list", "text": "(read_buffer->temporary_buffer)", "parent": 183, "children": [186], "start_point": {"row": 57, "column": 12}, "end_point": {"row": 57, "column": 43}}, {"id": 186, "type": "field_expression", "text": "read_buffer->temporary_buffer", "parent": 185, "children": [187, 188], "start_point": {"row": 57, "column": 13}, "end_point": {"row": 57, "column": 42}}, {"id": 187, "type": "identifier", "text": "read_buffer", "parent": 186, "children": [], "start_point": {"row": 57, "column": 13}, "end_point": {"row": 57, "column": 24}}, {"id": 188, "type": "field_identifier", "text": "temporary_buffer", "parent": 186, "children": [], "start_point": {"row": 57, "column": 26}, "end_point": {"row": 57, "column": 42}}, {"id": 189, "type": "call_expression", "text": "caml_remove_generational_global_root(&read_buffer->caml_buffer)", "parent": 166, "children": [190, 191], "start_point": {"row": 58, "column": 8}, "end_point": {"row": 58, "column": 71}}, {"id": 190, "type": "identifier", "text": "caml_remove_generational_global_root", "parent": 189, "children": [], "start_point": {"row": 58, "column": 8}, "end_point": {"row": 58, "column": 44}}, {"id": 191, "type": "argument_list", "text": "(&read_buffer->caml_buffer)", "parent": 189, "children": [192], "start_point": {"row": 58, "column": 44}, "end_point": {"row": 58, "column": 71}}, {"id": 192, "type": "pointer_expression", "text": "&read_buffer->caml_buffer", "parent": 191, "children": [193], "start_point": {"row": 58, "column": 45}, "end_point": {"row": 58, "column": 70}}, {"id": 193, "type": "field_expression", "text": "read_buffer->caml_buffer", "parent": 192, "children": [194, 195], "start_point": {"row": 58, "column": 46}, "end_point": {"row": 58, "column": 70}}, {"id": 194, "type": "identifier", "text": "read_buffer", "parent": 193, "children": [], "start_point": {"row": 58, "column": 46}, "end_point": {"row": 58, "column": 57}}, {"id": 195, "type": "field_identifier", "text": "caml_buffer", "parent": 193, "children": [], "start_point": {"row": 58, "column": 59}, "end_point": {"row": 58, "column": 70}}, {"id": 196, "type": "call_expression", "text": "free(job->iovecs)", "parent": 100, "children": [197, 198], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 21}}, {"id": 197, "type": "identifier", "text": "free", "parent": 196, "children": [], "start_point": {"row": 60, "column": 4}, "end_point": {"row": 60, "column": 8}}, {"id": 198, "type": "argument_list", "text": "(job->iovecs)", "parent": 196, "children": [199], "start_point": {"row": 60, "column": 8}, "end_point": {"row": 60, "column": 21}}, {"id": 199, "type": "field_expression", "text": "job->iovecs", "parent": 198, "children": [200, 201], "start_point": {"row": 60, "column": 9}, "end_point": {"row": 60, "column": 20}}, {"id": 200, "type": "identifier", "text": "job", "parent": 199, "children": [], "start_point": {"row": 60, "column": 9}, "end_point": {"row": 60, "column": 12}}, {"id": 201, "type": "field_identifier", "text": "iovecs", "parent": 199, "children": [], "start_point": {"row": 60, "column": 14}, "end_point": {"row": 60, "column": 20}}, {"id": 202, "type": "declaration", "text": "ssize_t result = job->result;", "parent": 100, "children": [203, 204], "start_point": {"row": 63, "column": 4}, "end_point": {"row": 63, "column": 33}}, {"id": 203, "type": "primitive_type", "text": "ssize_t", "parent": 202, "children": [], "start_point": {"row": 63, "column": 4}, "end_point": {"row": 63, "column": 11}}, {"id": 204, "type": "init_declarator", "text": "result = job->result", "parent": 202, "children": [205, 206, 207], "start_point": {"row": 63, "column": 12}, "end_point": {"row": 63, "column": 32}}, {"id": 205, "type": "identifier", "text": "result", "parent": 204, "children": [], "start_point": {"row": 63, "column": 12}, "end_point": {"row": 63, "column": 18}}, {"id": 206, "type": "=", "text": "=", "parent": 204, "children": [], "start_point": {"row": 63, "column": 19}, "end_point": {"row": 63, "column": 20}}, {"id": 207, "type": "field_expression", "text": "job->result", "parent": 204, "children": [208, 209], "start_point": {"row": 63, "column": 21}, "end_point": {"row": 63, "column": 32}}, {"id": 208, "type": "identifier", "text": "job", "parent": 207, "children": [], "start_point": {"row": 63, "column": 21}, "end_point": {"row": 63, "column": 24}}, {"id": 209, "type": "field_identifier", "text": "result", "parent": 207, "children": [], "start_point": {"row": 63, "column": 26}, "end_point": {"row": 63, "column": 32}}, {"id": 210, "type": "call_expression", "text": "LWT_UNIX_CHECK_JOB(job, result < 0, \"readv\")", "parent": 100, "children": [211, 212], "start_point": {"row": 64, "column": 4}, "end_point": {"row": 64, "column": 48}}, {"id": 211, "type": "identifier", "text": "LWT_UNIX_CHECK_JOB", "parent": 210, "children": [], "start_point": {"row": 64, "column": 4}, "end_point": {"row": 64, "column": 22}}, {"id": 212, "type": "argument_list", "text": "(job, result < 0, \"readv\")", "parent": 210, "children": [213, 214, 218], "start_point": {"row": 64, "column": 22}, "end_point": {"row": 64, "column": 48}}, {"id": 213, "type": "identifier", "text": "job", "parent": 212, "children": [], "start_point": {"row": 64, "column": 23}, "end_point": {"row": 64, "column": 26}}, {"id": 214, "type": "binary_expression", "text": "result < 0", "parent": 212, "children": [215, 216, 217], "start_point": {"row": 64, "column": 28}, "end_point": {"row": 64, "column": 38}}, {"id": 215, "type": "identifier", "text": "result", "parent": 214, "children": [], "start_point": {"row": 64, "column": 28}, "end_point": {"row": 64, "column": 34}}, {"id": 216, "type": "<", "text": "<", "parent": 214, "children": [], "start_point": {"row": 64, "column": 35}, "end_point": {"row": 64, "column": 36}}, {"id": 217, "type": "number_literal", "text": "0", "parent": 214, "children": [], "start_point": {"row": 64, "column": 37}, "end_point": {"row": 64, "column": 38}}, {"id": 218, "type": "string_literal", "text": "\"readv\"", "parent": 212, "children": [], "start_point": {"row": 64, "column": 40}, "end_point": {"row": 64, "column": 47}}, {"id": 219, "type": "call_expression", "text": "lwt_unix_free_job(&job->job)", "parent": 100, "children": [220, 221], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 32}}, {"id": 220, "type": "identifier", "text": "lwt_unix_free_job", "parent": 219, "children": [], "start_point": {"row": 65, "column": 4}, "end_point": {"row": 65, "column": 21}}, {"id": 221, "type": "argument_list", "text": "(&job->job)", "parent": 219, "children": [222], "start_point": {"row": 65, "column": 21}, "end_point": {"row": 65, "column": 32}}, {"id": 222, "type": "pointer_expression", "text": "&job->job", "parent": 221, "children": [223], "start_point": {"row": 65, "column": 22}, "end_point": {"row": 65, "column": 31}}, {"id": 223, "type": "field_expression", "text": "job->job", "parent": 222, "children": [224, 225], "start_point": {"row": 65, "column": 23}, "end_point": {"row": 65, "column": 31}}, {"id": 224, "type": "identifier", "text": "job", "parent": 223, "children": [], "start_point": {"row": 65, "column": 23}, "end_point": {"row": 65, "column": 26}}, {"id": 225, "type": "field_identifier", "text": "job", "parent": 223, "children": [], "start_point": {"row": 65, "column": 28}, "end_point": {"row": 65, "column": 31}}, {"id": 226, "type": "return_statement", "text": "return Val_long(result);", "parent": 100, "children": [227], "start_point": {"row": 66, "column": 4}, "end_point": {"row": 66, "column": 28}}, {"id": 227, "type": "call_expression", "text": "Val_long(result)", "parent": 226, "children": [228, 229], "start_point": {"row": 66, "column": 11}, "end_point": {"row": 66, "column": 27}}, {"id": 228, "type": "identifier", "text": "Val_long", "parent": 227, "children": [], "start_point": {"row": 66, "column": 11}, "end_point": {"row": 66, "column": 19}}, {"id": 229, "type": "argument_list", "text": "(result)", "parent": 227, "children": [230], "start_point": {"row": 66, "column": 19}, "end_point": {"row": 66, "column": 27}}, {"id": 230, "type": "identifier", "text": "result", "parent": 229, "children": [], "start_point": {"row": 66, "column": 20}, "end_point": {"row": 66, "column": 26}}, {"id": 231, "type": "function_definition", "text": "CAMLprim value lwt_unix_readv_job(value fd, value io_vectors, value val_count)\n{\n CAMLparam3(fd, io_vectors, val_count);\n\n size_t count = Long_val(val_count);\n\n /* The extra struct readv_copy_to (+ 1) is for the final terminator, in case\n all buffer slices are in bytes buffers. */\n LWT_UNIX_INIT_JOB(job, readv, sizeof(struct readv_copy_to) * (count + 1));\n job->fd = Int_val(fd);\n job->count = count;\n\n /* Assemble iovec structures on the heap. */\n job->iovecs = lwt_unix_malloc(sizeof(struct iovec) * count);\n flatten_io_vectors(job->iovecs, io_vectors, count, NULL, job->buffers);\n\n CAMLreturn(lwt_unix_alloc_job(&job->job));\n}", "parent": 3, "children": [232, 233, 235], "start_point": {"row": 69, "column": 0}, "end_point": {"row": 86, "column": 1}}, {"id": 232, "type": "type_identifier", "text": "CAMLprim", "parent": 231, "children": [], "start_point": {"row": 69, "column": 0}, "end_point": {"row": 69, "column": 8}}, {"id": 233, "type": "ERROR", "text": "value", "parent": 231, "children": [234], "start_point": {"row": 69, "column": 9}, "end_point": {"row": 69, "column": 14}}, {"id": 234, "type": "identifier", "text": "value", "parent": 233, "children": [], "start_point": {"row": 69, "column": 9}, "end_point": {"row": 69, "column": 14}}, {"id": 235, "type": "function_declarator", "text": "lwt_unix_readv_job(value fd, value io_vectors, value val_count)", "parent": 231, "children": [236, 237], "start_point": {"row": 69, "column": 15}, "end_point": {"row": 69, "column": 78}}, {"id": 236, "type": "identifier", "text": "lwt_unix_readv_job", "parent": 235, "children": [], "start_point": {"row": 69, "column": 15}, "end_point": {"row": 69, "column": 33}}, {"id": 237, "type": "parameter_list", "text": "(value fd, value io_vectors, value val_count)", "parent": 235, "children": [238, 241, 244], "start_point": {"row": 69, "column": 33}, "end_point": {"row": 69, "column": 78}}, {"id": 238, "type": "parameter_declaration", "text": "value fd", "parent": 237, "children": [239, 240], "start_point": {"row": 69, "column": 34}, "end_point": {"row": 69, "column": 42}}, {"id": 239, "type": "type_identifier", "text": "value", "parent": 238, "children": [], "start_point": {"row": 69, "column": 34}, "end_point": {"row": 69, "column": 39}}, {"id": 240, "type": "identifier", "text": "fd", "parent": 238, "children": [], "start_point": {"row": 69, "column": 40}, "end_point": {"row": 69, "column": 42}}, {"id": 241, "type": "parameter_declaration", "text": "value io_vectors", "parent": 237, "children": [242, 243], "start_point": {"row": 69, "column": 44}, "end_point": {"row": 69, "column": 60}}, {"id": 242, "type": "type_identifier", "text": "value", "parent": 241, "children": [], "start_point": {"row": 69, "column": 44}, "end_point": {"row": 69, "column": 49}}, {"id": 243, "type": "identifier", "text": "io_vectors", "parent": 241, "children": [], "start_point": {"row": 69, "column": 50}, "end_point": {"row": 69, "column": 60}}, {"id": 244, "type": "parameter_declaration", "text": "value val_count", "parent": 237, "children": [245, 246], "start_point": {"row": 69, "column": 62}, "end_point": {"row": 69, "column": 77}}, {"id": 245, "type": "type_identifier", "text": "value", "parent": 244, "children": [], "start_point": {"row": 69, "column": 62}, "end_point": {"row": 69, "column": 67}}, {"id": 246, "type": "identifier", "text": "val_count", "parent": 244, "children": [], "start_point": {"row": 69, "column": 68}, "end_point": {"row": 69, "column": 77}}, {"id": 247, "type": "call_expression", "text": "CAMLparam3(fd, io_vectors, val_count)", "parent": 231, "children": [248, 249], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 41}}, {"id": 248, "type": "identifier", "text": "CAMLparam3", "parent": 247, "children": [], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 14}}, {"id": 249, "type": "argument_list", "text": "(fd, io_vectors, val_count)", "parent": 247, "children": [250, 251, 252], "start_point": {"row": 71, "column": 14}, "end_point": {"row": 71, "column": 41}}, {"id": 250, "type": "identifier", "text": "fd", "parent": 249, "children": [], "start_point": {"row": 71, "column": 15}, "end_point": {"row": 71, "column": 17}}, {"id": 251, "type": "identifier", "text": "io_vectors", "parent": 249, "children": [], "start_point": {"row": 71, "column": 19}, "end_point": {"row": 71, "column": 29}}, {"id": 252, "type": "identifier", "text": "val_count", "parent": 249, "children": [], "start_point": {"row": 71, "column": 31}, "end_point": {"row": 71, "column": 40}}, {"id": 253, "type": "declaration", "text": "size_t count = Long_val(val_count);", "parent": 231, "children": [254, 255], "start_point": {"row": 73, "column": 4}, "end_point": {"row": 73, "column": 39}}, {"id": 254, "type": "primitive_type", "text": "size_t", "parent": 253, "children": [], "start_point": {"row": 73, "column": 4}, "end_point": {"row": 73, "column": 10}}, {"id": 255, "type": "init_declarator", "text": "count = Long_val(val_count)", "parent": 253, "children": [256, 257, 258], "start_point": {"row": 73, "column": 11}, "end_point": {"row": 73, "column": 38}}, {"id": 256, "type": "identifier", "text": "count", "parent": 255, "children": [], "start_point": {"row": 73, "column": 11}, "end_point": {"row": 73, "column": 16}}, {"id": 257, "type": "=", "text": "=", "parent": 255, "children": [], "start_point": {"row": 73, "column": 17}, "end_point": {"row": 73, "column": 18}}, {"id": 258, "type": "call_expression", "text": "Long_val(val_count)", "parent": 255, "children": [259, 260], "start_point": {"row": 73, "column": 19}, "end_point": {"row": 73, "column": 38}}, {"id": 259, "type": "identifier", "text": "Long_val", "parent": 258, "children": [], "start_point": {"row": 73, "column": 19}, "end_point": {"row": 73, "column": 27}}, {"id": 260, "type": "argument_list", "text": "(val_count)", "parent": 258, "children": [261], "start_point": {"row": 73, "column": 27}, "end_point": {"row": 73, "column": 38}}, {"id": 261, "type": "identifier", "text": "val_count", "parent": 260, "children": [], "start_point": {"row": 73, "column": 28}, "end_point": {"row": 73, "column": 37}}, {"id": 262, "type": "call_expression", "text": "LWT_UNIX_INIT_JOB(job, readv, sizeof(struct readv_copy_to) * (count + 1))", "parent": 231, "children": [263, 264], "start_point": {"row": 77, "column": 4}, "end_point": {"row": 77, "column": 77}}, {"id": 263, "type": "identifier", "text": "LWT_UNIX_INIT_JOB", "parent": 262, "children": [], "start_point": {"row": 77, "column": 4}, "end_point": {"row": 77, "column": 21}}, {"id": 264, "type": "argument_list", "text": "(job, readv, sizeof(struct readv_copy_to) * (count + 1))", "parent": 262, "children": [265, 266, 267], "start_point": {"row": 77, "column": 21}, "end_point": {"row": 77, "column": 77}}, {"id": 265, "type": "identifier", "text": "job", "parent": 264, "children": [], "start_point": {"row": 77, "column": 22}, "end_point": {"row": 77, "column": 25}}, {"id": 266, "type": "identifier", "text": "readv", "parent": 264, "children": [], "start_point": {"row": 77, "column": 27}, "end_point": {"row": 77, "column": 32}}, {"id": 267, "type": "binary_expression", "text": "sizeof(struct readv_copy_to) * (count + 1)", "parent": 264, "children": [268, 273, 274], "start_point": {"row": 77, "column": 34}, "end_point": {"row": 77, "column": 76}}, {"id": 268, "type": "sizeof_expression", "text": "sizeof(struct readv_copy_to)", "parent": 267, "children": [269], "start_point": {"row": 77, "column": 34}, "end_point": {"row": 77, "column": 62}}, {"id": 269, "type": "type_descriptor", "text": "struct readv_copy_to", "parent": 268, "children": [270], "start_point": {"row": 77, "column": 41}, "end_point": {"row": 77, "column": 61}}, {"id": 270, "type": "struct_specifier", "text": "struct readv_copy_to", "parent": 269, "children": [271, 272], "start_point": {"row": 77, "column": 41}, "end_point": {"row": 77, "column": 61}}, {"id": 271, "type": "struct", "text": "struct", "parent": 270, "children": [], "start_point": {"row": 77, "column": 41}, "end_point": {"row": 77, "column": 47}}, {"id": 272, "type": "type_identifier", "text": "readv_copy_to", "parent": 270, "children": [], "start_point": {"row": 77, "column": 48}, "end_point": {"row": 77, "column": 61}}, {"id": 273, "type": "*", "text": "*", "parent": 267, "children": [], "start_point": {"row": 77, "column": 63}, "end_point": {"row": 77, "column": 64}}, {"id": 274, "type": "parenthesized_expression", "text": "(count + 1)", "parent": 267, "children": [275], "start_point": {"row": 77, "column": 65}, "end_point": {"row": 77, "column": 76}}, {"id": 275, "type": "binary_expression", "text": "count + 1", "parent": 274, "children": [276, 277, 278], "start_point": {"row": 77, "column": 66}, "end_point": {"row": 77, "column": 75}}, {"id": 276, "type": "identifier", "text": "count", "parent": 275, "children": [], "start_point": {"row": 77, "column": 66}, "end_point": {"row": 77, "column": 71}}, {"id": 277, "type": "+", "text": "+", "parent": 275, "children": [], "start_point": {"row": 77, "column": 72}, "end_point": {"row": 77, "column": 73}}, {"id": 278, "type": "number_literal", "text": "1", "parent": 275, "children": [], "start_point": {"row": 77, "column": 74}, "end_point": {"row": 77, "column": 75}}, {"id": 279, "type": "assignment_expression", "text": "job->fd = Int_val(fd)", "parent": 231, "children": [280, 283, 284], "start_point": {"row": 78, "column": 4}, "end_point": {"row": 78, "column": 25}}, {"id": 280, "type": "field_expression", "text": "job->fd", "parent": 279, "children": [281, 282], "start_point": {"row": 78, "column": 4}, "end_point": {"row": 78, "column": 11}}, {"id": 281, "type": "identifier", "text": "job", "parent": 280, "children": [], "start_point": {"row": 78, "column": 4}, "end_point": {"row": 78, "column": 7}}, {"id": 282, "type": "field_identifier", "text": "fd", "parent": 280, "children": [], "start_point": {"row": 78, "column": 9}, "end_point": {"row": 78, "column": 11}}, {"id": 283, "type": "=", "text": "=", "parent": 279, "children": [], "start_point": {"row": 78, "column": 12}, "end_point": {"row": 78, "column": 13}}, {"id": 284, "type": "call_expression", "text": "Int_val(fd)", "parent": 279, "children": [285, 286], "start_point": {"row": 78, "column": 14}, "end_point": {"row": 78, "column": 25}}, {"id": 285, "type": "identifier", "text": "Int_val", "parent": 284, "children": [], "start_point": {"row": 78, "column": 14}, "end_point": {"row": 78, "column": 21}}, {"id": 286, "type": "argument_list", "text": "(fd)", "parent": 284, "children": [287], "start_point": {"row": 78, "column": 21}, "end_point": {"row": 78, "column": 25}}, {"id": 287, "type": "identifier", "text": "fd", "parent": 286, "children": [], "start_point": {"row": 78, "column": 22}, "end_point": {"row": 78, "column": 24}}, {"id": 288, "type": "assignment_expression", "text": "job->count = count", "parent": 231, "children": [289, 292, 293], "start_point": {"row": 79, "column": 4}, "end_point": {"row": 79, "column": 22}}, {"id": 289, "type": "field_expression", "text": "job->count", "parent": 288, "children": [290, 291], "start_point": {"row": 79, "column": 4}, "end_point": {"row": 79, "column": 14}}, {"id": 290, "type": "identifier", "text": "job", "parent": 289, "children": [], "start_point": {"row": 79, "column": 4}, "end_point": {"row": 79, "column": 7}}, {"id": 291, "type": "field_identifier", "text": "count", "parent": 289, "children": [], "start_point": {"row": 79, "column": 9}, "end_point": {"row": 79, "column": 14}}, {"id": 292, "type": "=", "text": "=", "parent": 288, "children": [], "start_point": {"row": 79, "column": 15}, "end_point": {"row": 79, "column": 16}}, {"id": 293, "type": "identifier", "text": "count", "parent": 288, "children": [], "start_point": {"row": 79, "column": 17}, "end_point": {"row": 79, "column": 22}}, {"id": 294, "type": "assignment_expression", "text": "job->iovecs = lwt_unix_malloc(sizeof(struct iovec) * count)", "parent": 231, "children": [295, 298, 299], "start_point": {"row": 82, "column": 4}, "end_point": {"row": 82, "column": 63}}, {"id": 295, "type": "field_expression", "text": "job->iovecs", "parent": 294, "children": [296, 297], "start_point": {"row": 82, "column": 4}, "end_point": {"row": 82, "column": 15}}, {"id": 296, "type": "identifier", "text": "job", "parent": 295, "children": [], "start_point": {"row": 82, "column": 4}, "end_point": {"row": 82, "column": 7}}, {"id": 297, "type": "field_identifier", "text": "iovecs", "parent": 295, "children": [], "start_point": {"row": 82, "column": 9}, "end_point": {"row": 82, "column": 15}}, {"id": 298, "type": "=", "text": "=", "parent": 294, "children": [], "start_point": {"row": 82, "column": 16}, "end_point": {"row": 82, "column": 17}}, {"id": 299, "type": "call_expression", "text": "lwt_unix_malloc(sizeof(struct iovec) * count)", "parent": 294, "children": [300, 301], "start_point": {"row": 82, "column": 18}, "end_point": {"row": 82, "column": 63}}, {"id": 300, "type": "identifier", "text": "lwt_unix_malloc", "parent": 299, "children": [], "start_point": {"row": 82, "column": 18}, "end_point": {"row": 82, "column": 33}}, {"id": 301, "type": "argument_list", "text": "(sizeof(struct iovec) * count)", "parent": 299, "children": [302], "start_point": {"row": 82, "column": 33}, "end_point": {"row": 82, "column": 63}}, {"id": 302, "type": "binary_expression", "text": "sizeof(struct iovec) * count", "parent": 301, "children": [303, 308, 309], "start_point": {"row": 82, "column": 34}, "end_point": {"row": 82, "column": 62}}, {"id": 303, "type": "sizeof_expression", "text": "sizeof(struct iovec)", "parent": 302, "children": [304], "start_point": {"row": 82, "column": 34}, "end_point": {"row": 82, "column": 54}}, {"id": 304, "type": "type_descriptor", "text": "struct iovec", "parent": 303, "children": [305], "start_point": {"row": 82, "column": 41}, "end_point": {"row": 82, "column": 53}}, {"id": 305, "type": "struct_specifier", "text": "struct iovec", "parent": 304, "children": [306, 307], "start_point": {"row": 82, "column": 41}, "end_point": {"row": 82, "column": 53}}, {"id": 306, "type": "struct", "text": "struct", "parent": 305, "children": [], "start_point": {"row": 82, "column": 41}, "end_point": {"row": 82, "column": 47}}, {"id": 307, "type": "type_identifier", "text": "iovec", "parent": 305, "children": [], "start_point": {"row": 82, "column": 48}, "end_point": {"row": 82, "column": 53}}, {"id": 308, "type": "*", "text": "*", "parent": 302, "children": [], "start_point": {"row": 82, "column": 55}, "end_point": {"row": 82, "column": 56}}, {"id": 309, "type": "identifier", "text": "count", "parent": 302, "children": [], "start_point": {"row": 82, "column": 57}, "end_point": {"row": 82, "column": 62}}, {"id": 310, "type": "call_expression", "text": "flatten_io_vectors(job->iovecs, io_vectors, count, NULL, job->buffers)", "parent": 231, "children": [311, 312], "start_point": {"row": 83, "column": 4}, "end_point": {"row": 83, "column": 74}}, {"id": 311, "type": "identifier", "text": "flatten_io_vectors", "parent": 310, "children": [], "start_point": {"row": 83, "column": 4}, "end_point": {"row": 83, "column": 22}}, {"id": 312, "type": "argument_list", "text": "(job->iovecs, io_vectors, count, NULL, job->buffers)", "parent": 310, "children": [313, 316, 317, 318, 320], "start_point": {"row": 83, "column": 22}, "end_point": {"row": 83, "column": 74}}, {"id": 313, "type": "field_expression", "text": "job->iovecs", "parent": 312, "children": [314, 315], "start_point": {"row": 83, "column": 23}, "end_point": {"row": 83, "column": 34}}, {"id": 314, "type": "identifier", "text": "job", "parent": 313, "children": [], "start_point": {"row": 83, "column": 23}, "end_point": {"row": 83, "column": 26}}, {"id": 315, "type": "field_identifier", "text": "iovecs", "parent": 313, "children": [], "start_point": {"row": 83, "column": 28}, "end_point": {"row": 83, "column": 34}}, {"id": 316, "type": "identifier", "text": "io_vectors", "parent": 312, "children": [], "start_point": {"row": 83, "column": 36}, "end_point": {"row": 83, "column": 46}}, {"id": 317, "type": "identifier", "text": "count", "parent": 312, "children": [], "start_point": {"row": 83, "column": 48}, "end_point": {"row": 83, "column": 53}}, {"id": 318, "type": "null", "text": "NULL", "parent": 312, "children": [319], "start_point": {"row": 83, "column": 55}, "end_point": {"row": 83, "column": 59}}, {"id": 319, "type": "NULL", "text": "NULL", "parent": 318, "children": [], "start_point": {"row": 83, "column": 55}, "end_point": {"row": 83, "column": 59}}, {"id": 320, "type": "field_expression", "text": "job->buffers", "parent": 312, "children": [321, 322], "start_point": {"row": 83, "column": 61}, "end_point": {"row": 83, "column": 73}}, {"id": 321, "type": "identifier", "text": "job", "parent": 320, "children": [], "start_point": {"row": 83, "column": 61}, "end_point": {"row": 83, "column": 64}}, {"id": 322, "type": "field_identifier", "text": "buffers", "parent": 320, "children": [], "start_point": {"row": 83, "column": 66}, "end_point": {"row": 83, "column": 73}}, {"id": 323, "type": "call_expression", "text": "CAMLreturn(lwt_unix_alloc_job(&job->job))", "parent": 231, "children": [324, 325], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 45}}, {"id": 324, "type": "identifier", "text": "CAMLreturn", "parent": 323, "children": [], "start_point": {"row": 85, "column": 4}, "end_point": {"row": 85, "column": 14}}, {"id": 325, "type": "argument_list", "text": "(lwt_unix_alloc_job(&job->job))", "parent": 323, "children": [326], "start_point": {"row": 85, "column": 14}, "end_point": {"row": 85, "column": 45}}, {"id": 326, "type": "call_expression", "text": "lwt_unix_alloc_job(&job->job)", "parent": 325, "children": [327, 328], "start_point": {"row": 85, "column": 15}, "end_point": {"row": 85, "column": 44}}, {"id": 327, "type": "identifier", "text": "lwt_unix_alloc_job", "parent": 326, "children": [], "start_point": {"row": 85, "column": 15}, "end_point": {"row": 85, "column": 33}}, {"id": 328, "type": "argument_list", "text": "(&job->job)", "parent": 326, "children": [329], "start_point": {"row": 85, "column": 33}, "end_point": {"row": 85, "column": 44}}, {"id": 329, "type": "pointer_expression", "text": "&job->job", "parent": 328, "children": [330], "start_point": {"row": 85, "column": 34}, "end_point": {"row": 85, "column": 43}}, {"id": 330, "type": "field_expression", "text": "job->job", "parent": 329, "children": [331, 332], "start_point": {"row": 85, "column": 35}, "end_point": {"row": 85, "column": 43}}, {"id": 331, "type": "identifier", "text": "job", "parent": 330, "children": [], "start_point": {"row": 85, "column": 35}, "end_point": {"row": 85, "column": 38}}, {"id": 332, "type": "field_identifier", "text": "job", "parent": 330, "children": [], "start_point": {"row": 85, "column": 40}, "end_point": {"row": 85, "column": 43}}, {"id": 333, "type": "#endif", "text": "#endif", "parent": 3, "children": [], "start_point": {"row": 87, "column": 0}, "end_point": {"row": 87, "column": 6}}]}, "node_categories": {"declarations": {"functions": [65, 67, 100, 102, 231, 235], "variables": [35, 40, 43, 46, 49, 52, 59, 70, 105, 112, 202, 238, 241, 244, 253], "classes": [32, 33, 36, 37, 53, 54, 60, 61, 71, 72, 106, 107, 113, 114, 270, 271, 305, 306], "imports": [0, 1, 11, 12, 14, 15, 17, 18, 20, 21, 23, 24, 26, 27, 29, 30], "modules": [], "enums": []}, "statements": {"expressions": [5, 78, 82, 85, 88, 91, 95, 120, 121, 122, 131, 134, 135, 141, 144, 147, 148, 151, 154, 157, 160, 163, 170, 173, 174, 180, 183, 186, 189, 192, 193, 196, 199, 207, 210, 214, 219, 222, 223, 227, 247, 258, 262, 267, 268, 274, 275, 280, 284, 289, 295, 299, 302, 303, 310, 313, 320, 323, 326, 329, 330], "assignments": [77, 94, 128, 167, 279, 288, 294], "loops": [127, 166], "conditionals": [3, 4, 9, 34, 38, 39, 42, 45, 48, 51, 55, 58, 62, 64, 68, 73, 76, 79, 80, 83, 86, 87, 89, 90, 92, 93, 96, 97, 99, 101, 103, 108, 111, 115, 118, 119, 123, 124, 129, 132, 133, 136, 137, 143, 145, 149, 152, 155, 156, 158, 159, 161, 162, 164, 165, 168, 171, 172, 175, 176, 182, 184, 187, 188, 190, 194, 195, 197, 200, 201, 205, 208, 209, 211, 213, 215, 220, 224, 225, 228, 230, 232, 234, 236, 239, 240, 242, 243, 245, 246, 248, 250, 251, 252, 256, 259, 261, 263, 265, 266, 272, 276, 281, 282, 285, 287, 290, 291, 293, 296, 297, 300, 307, 309, 311, 314, 315, 316, 317, 321, 322, 324, 327, 331, 332, 333], "returns": [226], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 13, 16, 19, 22, 25, 28, 31, 126, 217, 218, 278], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 65, "universal_type": "function", "name": "worker_readv", "text_snippet": "static void worker_readv(struct job_readv *job)\n{\n job->result = readv(job->fd, job->iovecs, job-"}, {"node_id": 67, "universal_type": "function", "name": "unknown", "text_snippet": "worker_readv(struct job_readv *job)"}, {"node_id": 100, "universal_type": "function", "name": "readv_copy_to", "text_snippet": "static value result_readv(struct job_readv *job)\n{\n struct readv_copy_to *read_buffer;\n\n /* If"}, {"node_id": 102, "universal_type": "function", "name": "unknown", "text_snippet": "result_readv(struct job_readv *job)"}, {"node_id": 231, "universal_type": "function", "name": "readv_copy_to", "text_snippet": "CAMLprim value lwt_unix_readv_job(value fd, value io_vectors, value val_count)\n{\n CAMLparam3(fd, "}, {"node_id": 235, "universal_type": "function", "name": "unknown", "text_snippet": "lwt_unix_readv_job(value fd, value io_vectors, value val_count)"}], "class_declarations": [{"node_id": 32, "universal_type": "class", "name": "job_readv", "text_snippet": "struct job_readv {\n struct lwt_unix_job job;\n int fd;\n int error_code;\n ssize_t result;\n"}, {"node_id": 33, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 36, "universal_type": "class", "name": "lwt_unix_job", "text_snippet": "struct lwt_unix_job"}, {"node_id": 37, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 53, "universal_type": "class", "name": "iovec", "text_snippet": "struct iovec"}, {"node_id": 54, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 60, "universal_type": "class", "name": "readv_copy_to", "text_snippet": "struct readv_copy_to"}, {"node_id": 61, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 71, "universal_type": "class", "name": "job_readv", "text_snippet": "struct job_readv"}, {"node_id": 72, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 106, "universal_type": "class", "name": "job_readv", "text_snippet": "struct job_readv"}, {"node_id": 107, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 113, "universal_type": "class", "name": "readv_copy_to", "text_snippet": "struct readv_copy_to"}, {"node_id": 114, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 270, "universal_type": "class", "name": "readv_copy_to", "text_snippet": "struct readv_copy_to"}, {"node_id": 271, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 305, "universal_type": "class", "name": "iovec", "text_snippet": "struct iovec"}, {"node_id": 306, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": [{"node_id": 0, "text": "#include \"lwt_config.h\"\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 11, "text": "#include <caml/memory.h>\n"}, {"node_id": 12, "text": "#include"}, {"node_id": 14, "text": "#include <caml/mlvalues.h>\n"}, {"node_id": 15, "text": "#include"}, {"node_id": 17, "text": "#include <caml/unixsupport.h>\n"}, {"node_id": 18, "text": "#include"}, {"node_id": 20, "text": "#include <errno.h>\n"}, {"node_id": 21, "text": "#include"}, {"node_id": 23, "text": "#include <string.h>\n"}, {"node_id": 24, "text": "#include"}, {"node_id": 26, "text": "#include \"lwt_unix.h\"\n"}, {"node_id": 27, "text": "#include"}, {"node_id": 29, "text": "#include \"unix_readv_writev_utils.h\"\n"}, {"node_id": 30, "text": "#include"}]}, "original_source_code": "/* This file is part of Lwt, released under the MIT license. See LICENSE.md for\n details, or visit https://github.com/ocsigen/lwt/blob/master/LICENSE.md. */\n\n\n\n#include \"lwt_config.h\"\n\n#if !defined(LWT_ON_WINDOWS)\n\n#include <caml/memory.h>\n#include <caml/mlvalues.h>\n#include <caml/unixsupport.h>\n#include <errno.h>\n#include <string.h>\n\n#include \"lwt_unix.h\"\n#include \"unix_readv_writev_utils.h\"\n\n/* Job and readv primitives for blocking file descriptors. */\nstruct job_readv {\n struct lwt_unix_job job;\n int fd;\n int error_code;\n ssize_t result;\n size_t count;\n /* Heap-allocated iovec structures. */\n struct iovec *iovecs;\n /* Data to be read into bytes buffers is first read into temporary buffers\n on the C heap. This is an array of descriptors for copying that data into\n the actual bytes buffers. The array is terminated by a descriptor whose\n temporary_buffer member is NULL. */\n struct readv_copy_to buffers[];\n};\n\nstatic void worker_readv(struct job_readv *job)\n{\n job->result = readv(job->fd, job->iovecs, job->count);\n job->error_code = errno;\n}\n\nstatic value result_readv(struct job_readv *job)\n{\n struct readv_copy_to *read_buffer;\n\n /* If the read is successful, copy data to the OCaml buffers. */\n if (job->result != -1) {\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n memcpy(&Byte(String_val(read_buffer->caml_buffer),\n read_buffer->offset),\n read_buffer->temporary_buffer, read_buffer->length);\n }\n }\n\n /* Free heap-allocated structures and buffers. */\n for (read_buffer = job->buffers; read_buffer->temporary_buffer != NULL;\n ++read_buffer) {\n free(read_buffer->temporary_buffer);\n caml_remove_generational_global_root(&read_buffer->caml_buffer);\n }\n free(job->iovecs);\n\n /* Decide on the actual result. */\n ssize_t result = job->result;\n LWT_UNIX_CHECK_JOB(job, result < 0, \"readv\");\n lwt_unix_free_job(&job->job);\n return Val_long(result);\n}\n\nCAMLprim value lwt_unix_readv_job(value fd, value io_vectors, value val_count)\n{\n CAMLparam3(fd, io_vectors, val_count);\n\n size_t count = Long_val(val_count);\n\n /* The extra struct readv_copy_to (+ 1) is for the final terminator, in case\n all buffer slices are in bytes buffers. */\n LWT_UNIX_INIT_JOB(job, readv, sizeof(struct readv_copy_to) * (count + 1));\n job->fd = Int_val(fd);\n job->count = count;\n\n /* Assemble iovec structures on the heap. */\n job->iovecs = lwt_unix_malloc(sizeof(struct iovec) * count);\n flatten_io_vectors(job->iovecs, io_vectors, count, NULL, job->buffers);\n\n CAMLreturn(lwt_unix_alloc_job(&job->job));\n}\n#endif\n"}
80,584
c
#include <stdint.h> #define LED_REGISTERS_MEMORY_ADD 0x10000000 #define IRQ_REGISTERS_MEMORY_ADD 0x10000004 #define LOOP_WAIT_LIMIT 100 uint32_t global_counter = 0; static void putuint(uint32_t i) { *((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD) = i; } static void putuint2(uint32_t i) { *((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD) = i; } uint32_t *irq(uint32_t *regs, uint32_t irqs) { global_counter += 1; putuint2(global_counter); return regs; } void main() { uint32_t number_to_display = 0; uint32_t counter = 0; while (1) { counter = 0; putuint(number_to_display); number_to_display++; while (counter < LOOP_WAIT_LIMIT) { counter++; } } }
21.06
31
(translation_unit) "#include <stdint.h>\n\n#define LED_REGISTERS_MEMORY_ADD 0x10000000\n#define IRQ_REGISTERS_MEMORY_ADD 0x10000004\n\n\n#define LOOP_WAIT_LIMIT 100\n\nuint32_t global_counter = 0;\n\nstatic void putuint(uint32_t i) {\n *((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD) = i;\n}\n\nstatic void putuint2(uint32_t i) {\n *((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD) = i;\n}\n\n\nuint32_t *irq(uint32_t *regs, uint32_t irqs) {\n global_counter += 1;\n putuint2(global_counter);\n return regs;\n}\n\n\nvoid main() {\n uint32_t number_to_display = 0;\n uint32_t counter = 0;\n\n while (1) {\n counter = 0;\n putuint(number_to_display);\n number_to_display++;\n while (counter < LOOP_WAIT_LIMIT) {\n counter++;\n }\n }\n}\n" (preproc_include) "#include <stdint.h>\n" (#include) "#include" (system_lib_string) "<stdint.h>" (preproc_def) "#define LED_REGISTERS_MEMORY_ADD 0x10000000\n" (#define) "#define" (identifier) "LED_REGISTERS_MEMORY_ADD" (preproc_arg) "0x10000000" (preproc_def) "#define IRQ_REGISTERS_MEMORY_ADD 0x10000004\n" (#define) "#define" (identifier) "IRQ_REGISTERS_MEMORY_ADD" (preproc_arg) "0x10000004" (preproc_def) "#define LOOP_WAIT_LIMIT 100\n" (#define) "#define" (identifier) "LOOP_WAIT_LIMIT" (preproc_arg) "100" (declaration) "uint32_t global_counter = 0;" (primitive_type) "uint32_t" (init_declarator) "global_counter = 0" (identifier) "global_counter" (=) "=" (number_literal) "0" (;) ";" (function_definition) "static void putuint(uint32_t i) {\n *((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD) = i;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "putuint(uint32_t i)" (identifier) "putuint" (parameter_list) "(uint32_t i)" (() "(" (parameter_declaration) "uint32_t i" (primitive_type) "uint32_t" (identifier) "i" ()) ")" (compound_statement) "{\n *((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD) = i;\n}" ({) "{" (expression_statement) "*((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD) = i;" (assignment_expression) "*((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD) = i" (pointer_expression) "*((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD)" (*) "*" (parenthesized_expression) "((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD)" (() "(" (cast_expression) "(volatile uint32_t *)LED_REGISTERS_MEMORY_ADD" (() "(" (type_descriptor) "volatile uint32_t *" (type_qualifier) "volatile" (volatile) "volatile" (primitive_type) "uint32_t" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "LED_REGISTERS_MEMORY_ADD" ()) ")" (=) "=" (identifier) "i" (;) ";" (}) "}" (function_definition) "static void putuint2(uint32_t i) {\n *((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD) = i;\n}" (storage_class_specifier) "static" (static) "static" (primitive_type) "void" (function_declarator) "putuint2(uint32_t i)" (identifier) "putuint2" (parameter_list) "(uint32_t i)" (() "(" (parameter_declaration) "uint32_t i" (primitive_type) "uint32_t" (identifier) "i" ()) ")" (compound_statement) "{\n *((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD) = i;\n}" ({) "{" (expression_statement) "*((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD) = i;" (assignment_expression) "*((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD) = i" (pointer_expression) "*((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD)" (*) "*" (parenthesized_expression) "((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD)" (() "(" (cast_expression) "(volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD" (() "(" (type_descriptor) "volatile uint32_t *" (type_qualifier) "volatile" (volatile) "volatile" (primitive_type) "uint32_t" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "IRQ_REGISTERS_MEMORY_ADD" ()) ")" (=) "=" (identifier) "i" (;) ";" (}) "}" (function_definition) "uint32_t *irq(uint32_t *regs, uint32_t irqs) {\n global_counter += 1;\n putuint2(global_counter);\n return regs;\n}" (primitive_type) "uint32_t" (pointer_declarator) "*irq(uint32_t *regs, uint32_t irqs)" (*) "*" (function_declarator) "irq(uint32_t *regs, uint32_t irqs)" (identifier) "irq" (parameter_list) "(uint32_t *regs, uint32_t irqs)" (() "(" (parameter_declaration) "uint32_t *regs" (primitive_type) "uint32_t" (pointer_declarator) "*regs" (*) "*" (identifier) "regs" (,) "," (parameter_declaration) "uint32_t irqs" (primitive_type) "uint32_t" (identifier) "irqs" ()) ")" (compound_statement) "{\n global_counter += 1;\n putuint2(global_counter);\n return regs;\n}" ({) "{" (expression_statement) "global_counter += 1;" (assignment_expression) "global_counter += 1" (identifier) "global_counter" (+=) "+=" (number_literal) "1" (;) ";" (expression_statement) "putuint2(global_counter);" (call_expression) "putuint2(global_counter)" (identifier) "putuint2" (argument_list) "(global_counter)" (() "(" (identifier) "global_counter" ()) ")" (;) ";" (return_statement) "return regs;" (return) "return" (identifier) "regs" (;) ";" (}) "}" (function_definition) "void main() {\n uint32_t number_to_display = 0;\n uint32_t counter = 0;\n\n while (1) {\n counter = 0;\n putuint(number_to_display);\n number_to_display++;\n while (counter < LOOP_WAIT_LIMIT) {\n counter++;\n }\n }\n}" (primitive_type) "void" (function_declarator) "main()" (identifier) "main" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n uint32_t number_to_display = 0;\n uint32_t counter = 0;\n\n while (1) {\n counter = 0;\n putuint(number_to_display);\n number_to_display++;\n while (counter < LOOP_WAIT_LIMIT) {\n counter++;\n }\n }\n}" ({) "{" (declaration) "uint32_t number_to_display = 0;" (primitive_type) "uint32_t" (init_declarator) "number_to_display = 0" (identifier) "number_to_display" (=) "=" (number_literal) "0" (;) ";" (declaration) "uint32_t counter = 0;" (primitive_type) "uint32_t" (init_declarator) "counter = 0" (identifier) "counter" (=) "=" (number_literal) "0" (;) ";" (while_statement) "while (1) {\n counter = 0;\n putuint(number_to_display);\n number_to_display++;\n while (counter < LOOP_WAIT_LIMIT) {\n counter++;\n }\n }" (while) "while" (parenthesized_expression) "(1)" (() "(" (number_literal) "1" ()) ")" (compound_statement) "{\n counter = 0;\n putuint(number_to_display);\n number_to_display++;\n while (counter < LOOP_WAIT_LIMIT) {\n counter++;\n }\n }" ({) "{" (expression_statement) "counter = 0;" (assignment_expression) "counter = 0" (identifier) "counter" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "putuint(number_to_display);" (call_expression) "putuint(number_to_display)" (identifier) "putuint" (argument_list) "(number_to_display)" (() "(" (identifier) "number_to_display" ()) ")" (;) ";" (expression_statement) "number_to_display++;" (update_expression) "number_to_display++" (identifier) "number_to_display" (++) "++" (;) ";" (while_statement) "while (counter < LOOP_WAIT_LIMIT) {\n counter++;\n }" (while) "while" (parenthesized_expression) "(counter < LOOP_WAIT_LIMIT)" (() "(" (binary_expression) "counter < LOOP_WAIT_LIMIT" (identifier) "counter" (<) "<" (identifier) "LOOP_WAIT_LIMIT" ()) ")" (compound_statement) "{\n counter++;\n }" ({) "{" (expression_statement) "counter++;" (update_expression) "counter++" (identifier) "counter" (++) "++" (;) ";" (}) "}" (}) "}" (}) "}"
201
0
{"language": "c", "success": true, "metadata": {"lines": 31, "avg_line_length": 21.06, "nodes": 130, "errors": 0, "source_hash": "8ff37d55e52bd8d7f9c8562117ee019eebdbdd233c1378d42020722b3e6c6aed", "categorized_nodes": 75}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <stdint.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<stdint.h>", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 19}}, {"id": 3, "type": "preproc_def", "text": "#define LED_REGISTERS_MEMORY_ADD 0x10000000\n", "parent": null, "children": [4, 5, 6], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 7}}, {"id": 5, "type": "identifier", "text": "LED_REGISTERS_MEMORY_ADD", "parent": 3, "children": [], "start_point": {"row": 2, "column": 8}, "end_point": {"row": 2, "column": 32}}, {"id": 6, "type": "preproc_arg", "text": "0x10000000", "parent": 3, "children": [], "start_point": {"row": 2, "column": 33}, "end_point": {"row": 2, "column": 43}}, {"id": 7, "type": "preproc_def", "text": "#define IRQ_REGISTERS_MEMORY_ADD 0x10000004\n", "parent": null, "children": [8, 9, 10], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 8, "type": "#define", "text": "#define", "parent": 7, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 7}}, {"id": 9, "type": "identifier", "text": "IRQ_REGISTERS_MEMORY_ADD", "parent": 7, "children": [], "start_point": {"row": 3, "column": 8}, "end_point": {"row": 3, "column": 32}}, {"id": 10, "type": "preproc_arg", "text": "0x10000004", "parent": 7, "children": [], "start_point": {"row": 3, "column": 33}, "end_point": {"row": 3, "column": 43}}, {"id": 11, "type": "preproc_def", "text": "#define LOOP_WAIT_LIMIT 100\n", "parent": null, "children": [12, 13, 14], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 12, "type": "#define", "text": "#define", "parent": 11, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 7}}, {"id": 13, "type": "identifier", "text": "LOOP_WAIT_LIMIT", "parent": 11, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 23}}, {"id": 14, "type": "preproc_arg", "text": "100", "parent": 11, "children": [], "start_point": {"row": 6, "column": 24}, "end_point": {"row": 6, "column": 27}}, {"id": 15, "type": "declaration", "text": "uint32_t global_counter = 0;", "parent": null, "children": [16, 17], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 28}}, {"id": 16, "type": "primitive_type", "text": "uint32_t", "parent": 15, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 8}}, {"id": 17, "type": "init_declarator", "text": "global_counter = 0", "parent": 15, "children": [18, 19, 20], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 27}}, {"id": 18, "type": "identifier", "text": "global_counter", "parent": 17, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 23}}, {"id": 19, "type": "=", "text": "=", "parent": 17, "children": [], "start_point": {"row": 8, "column": 24}, "end_point": {"row": 8, "column": 25}}, {"id": 20, "type": "number_literal", "text": "0", "parent": 17, "children": [], "start_point": {"row": 8, "column": 26}, "end_point": {"row": 8, "column": 27}}, {"id": 21, "type": "function_definition", "text": "static void putuint(uint32_t i) {\n\t*((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD) = i;\n}", "parent": null, "children": [22, 23], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 12, "column": 1}}, {"id": 22, "type": "primitive_type", "text": "void", "parent": 21, "children": [], "start_point": {"row": 10, "column": 7}, "end_point": {"row": 10, "column": 11}}, {"id": 23, "type": "function_declarator", "text": "putuint(uint32_t i)", "parent": 21, "children": [24, 25], "start_point": {"row": 10, "column": 12}, "end_point": {"row": 10, "column": 31}}, {"id": 24, "type": "identifier", "text": "putuint", "parent": 23, "children": [], "start_point": {"row": 10, "column": 12}, "end_point": {"row": 10, "column": 19}}, {"id": 25, "type": "parameter_list", "text": "(uint32_t i)", "parent": 23, "children": [26], "start_point": {"row": 10, "column": 19}, "end_point": {"row": 10, "column": 31}}, {"id": 26, "type": "parameter_declaration", "text": "uint32_t i", "parent": 25, "children": [27, 28], "start_point": {"row": 10, "column": 20}, "end_point": {"row": 10, "column": 30}}, {"id": 27, "type": "primitive_type", "text": "uint32_t", "parent": 26, "children": [], "start_point": {"row": 10, "column": 20}, "end_point": {"row": 10, "column": 28}}, {"id": 28, "type": "identifier", "text": "i", "parent": 26, "children": [], "start_point": {"row": 10, "column": 29}, "end_point": {"row": 10, "column": 30}}, {"id": 29, "type": "assignment_expression", "text": "*((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD) = i", "parent": 21, "children": [30, 41, 42], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 11, "column": 53}}, {"id": 30, "type": "pointer_expression", "text": "*((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD)", "parent": 29, "children": [31, 32], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 11, "column": 49}}, {"id": 31, "type": "*", "text": "*", "parent": 30, "children": [], "start_point": {"row": 11, "column": 1}, "end_point": {"row": 11, "column": 2}}, {"id": 32, "type": "parenthesized_expression", "text": "((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD)", "parent": 30, "children": [33], "start_point": {"row": 11, "column": 2}, "end_point": {"row": 11, "column": 49}}, {"id": 33, "type": "cast_expression", "text": "(volatile uint32_t *)LED_REGISTERS_MEMORY_ADD", "parent": 32, "children": [34, 40], "start_point": {"row": 11, "column": 3}, "end_point": {"row": 11, "column": 48}}, {"id": 34, "type": "type_descriptor", "text": "volatile uint32_t *", "parent": 33, "children": [35, 37, 38], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 23}}, {"id": 35, "type": "type_qualifier", "text": "volatile", "parent": 34, "children": [36], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 12}}, {"id": 36, "type": "volatile", "text": "volatile", "parent": 35, "children": [], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 12}}, {"id": 37, "type": "primitive_type", "text": "uint32_t", "parent": 34, "children": [], "start_point": {"row": 11, "column": 13}, "end_point": {"row": 11, "column": 21}}, {"id": 38, "type": "abstract_pointer_declarator", "text": "*", "parent": 34, "children": [39], "start_point": {"row": 11, "column": 22}, "end_point": {"row": 11, "column": 23}}, {"id": 39, "type": "*", "text": "*", "parent": 38, "children": [], "start_point": {"row": 11, "column": 22}, "end_point": {"row": 11, "column": 23}}, {"id": 40, "type": "identifier", "text": "LED_REGISTERS_MEMORY_ADD", "parent": 33, "children": [], "start_point": {"row": 11, "column": 24}, "end_point": {"row": 11, "column": 48}}, {"id": 41, "type": "=", "text": "=", "parent": 29, "children": [], "start_point": {"row": 11, "column": 50}, "end_point": {"row": 11, "column": 51}}, {"id": 42, "type": "identifier", "text": "i", "parent": 29, "children": [], "start_point": {"row": 11, "column": 52}, "end_point": {"row": 11, "column": 53}}, {"id": 43, "type": "function_definition", "text": "static void putuint2(uint32_t i) {\n\t*((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD) = i;\n}", "parent": null, "children": [44, 45], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 16, "column": 1}}, {"id": 44, "type": "primitive_type", "text": "void", "parent": 43, "children": [], "start_point": {"row": 14, "column": 7}, "end_point": {"row": 14, "column": 11}}, {"id": 45, "type": "function_declarator", "text": "putuint2(uint32_t i)", "parent": 43, "children": [46, 47], "start_point": {"row": 14, "column": 12}, "end_point": {"row": 14, "column": 32}}, {"id": 46, "type": "identifier", "text": "putuint2", "parent": 45, "children": [], "start_point": {"row": 14, "column": 12}, "end_point": {"row": 14, "column": 20}}, {"id": 47, "type": "parameter_list", "text": "(uint32_t i)", "parent": 45, "children": [48], "start_point": {"row": 14, "column": 20}, "end_point": {"row": 14, "column": 32}}, {"id": 48, "type": "parameter_declaration", "text": "uint32_t i", "parent": 47, "children": [49, 50], "start_point": {"row": 14, "column": 21}, "end_point": {"row": 14, "column": 31}}, {"id": 49, "type": "primitive_type", "text": "uint32_t", "parent": 48, "children": [], "start_point": {"row": 14, "column": 21}, "end_point": {"row": 14, "column": 29}}, {"id": 50, "type": "identifier", "text": "i", "parent": 48, "children": [], "start_point": {"row": 14, "column": 30}, "end_point": {"row": 14, "column": 31}}, {"id": 51, "type": "assignment_expression", "text": "*((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD) = i", "parent": 43, "children": [52, 63, 64], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 53}}, {"id": 52, "type": "pointer_expression", "text": "*((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD)", "parent": 51, "children": [53, 54], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 49}}, {"id": 53, "type": "*", "text": "*", "parent": 52, "children": [], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 2}}, {"id": 54, "type": "parenthesized_expression", "text": "((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD)", "parent": 52, "children": [55], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 49}}, {"id": 55, "type": "cast_expression", "text": "(volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD", "parent": 54, "children": [56, 62], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 48}}, {"id": 56, "type": "type_descriptor", "text": "volatile uint32_t *", "parent": 55, "children": [57, 59, 60], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 23}}, {"id": 57, "type": "type_qualifier", "text": "volatile", "parent": 56, "children": [58], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 12}}, {"id": 58, "type": "volatile", "text": "volatile", "parent": 57, "children": [], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 12}}, {"id": 59, "type": "primitive_type", "text": "uint32_t", "parent": 56, "children": [], "start_point": {"row": 15, "column": 13}, "end_point": {"row": 15, "column": 21}}, {"id": 60, "type": "abstract_pointer_declarator", "text": "*", "parent": 56, "children": [61], "start_point": {"row": 15, "column": 22}, "end_point": {"row": 15, "column": 23}}, {"id": 61, "type": "*", "text": "*", "parent": 60, "children": [], "start_point": {"row": 15, "column": 22}, "end_point": {"row": 15, "column": 23}}, {"id": 62, "type": "identifier", "text": "IRQ_REGISTERS_MEMORY_ADD", "parent": 55, "children": [], "start_point": {"row": 15, "column": 24}, "end_point": {"row": 15, "column": 48}}, {"id": 63, "type": "=", "text": "=", "parent": 51, "children": [], "start_point": {"row": 15, "column": 50}, "end_point": {"row": 15, "column": 51}}, {"id": 64, "type": "identifier", "text": "i", "parent": 51, "children": [], "start_point": {"row": 15, "column": 52}, "end_point": {"row": 15, "column": 53}}, {"id": 65, "type": "function_definition", "text": "uint32_t *irq(uint32_t *regs, uint32_t irqs) {\n global_counter += 1;\n putuint2(global_counter);\n return regs;\n}", "parent": null, "children": [66, 67], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 23, "column": 1}}, {"id": 66, "type": "primitive_type", "text": "uint32_t", "parent": 65, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 8}}, {"id": 67, "type": "pointer_declarator", "text": "*irq(uint32_t *regs, uint32_t irqs)", "parent": 65, "children": [68, 69], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 44}}, {"id": 68, "type": "*", "text": "*", "parent": 67, "children": [], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 10}}, {"id": 69, "type": "function_declarator", "text": "irq(uint32_t *regs, uint32_t irqs)", "parent": 67, "children": [70, 71], "start_point": {"row": 19, "column": 10}, "end_point": {"row": 19, "column": 44}}, {"id": 70, "type": "identifier", "text": "irq", "parent": 69, "children": [], "start_point": {"row": 19, "column": 10}, "end_point": {"row": 19, "column": 13}}, {"id": 71, "type": "parameter_list", "text": "(uint32_t *regs, uint32_t irqs)", "parent": 69, "children": [72, 77], "start_point": {"row": 19, "column": 13}, "end_point": {"row": 19, "column": 44}}, {"id": 72, "type": "parameter_declaration", "text": "uint32_t *regs", "parent": 71, "children": [73, 74], "start_point": {"row": 19, "column": 14}, "end_point": {"row": 19, "column": 28}}, {"id": 73, "type": "primitive_type", "text": "uint32_t", "parent": 72, "children": [], "start_point": {"row": 19, "column": 14}, "end_point": {"row": 19, "column": 22}}, {"id": 74, "type": "pointer_declarator", "text": "*regs", "parent": 72, "children": [75, 76], "start_point": {"row": 19, "column": 23}, "end_point": {"row": 19, "column": 28}}, {"id": 75, "type": "*", "text": "*", "parent": 74, "children": [], "start_point": {"row": 19, "column": 23}, "end_point": {"row": 19, "column": 24}}, {"id": 76, "type": "identifier", "text": "regs", "parent": 74, "children": [], "start_point": {"row": 19, "column": 24}, "end_point": {"row": 19, "column": 28}}, {"id": 77, "type": "parameter_declaration", "text": "uint32_t irqs", "parent": 71, "children": [78, 79], "start_point": {"row": 19, "column": 30}, "end_point": {"row": 19, "column": 43}}, {"id": 78, "type": "primitive_type", "text": "uint32_t", "parent": 77, "children": [], "start_point": {"row": 19, "column": 30}, "end_point": {"row": 19, "column": 38}}, {"id": 79, "type": "identifier", "text": "irqs", "parent": 77, "children": [], "start_point": {"row": 19, "column": 39}, "end_point": {"row": 19, "column": 43}}, {"id": 80, "type": "assignment_expression", "text": "global_counter += 1", "parent": 65, "children": [81, 82, 83], "start_point": {"row": 20, "column": 4}, "end_point": {"row": 20, "column": 23}}, {"id": 81, "type": "identifier", "text": "global_counter", "parent": 80, "children": [], "start_point": {"row": 20, "column": 4}, "end_point": {"row": 20, "column": 18}}, {"id": 82, "type": "+=", "text": "+=", "parent": 80, "children": [], "start_point": {"row": 20, "column": 19}, "end_point": {"row": 20, "column": 21}}, {"id": 83, "type": "number_literal", "text": "1", "parent": 80, "children": [], "start_point": {"row": 20, "column": 22}, "end_point": {"row": 20, "column": 23}}, {"id": 84, "type": "call_expression", "text": "putuint2(global_counter)", "parent": 65, "children": [85, 86], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 21, "column": 28}}, {"id": 85, "type": "identifier", "text": "putuint2", "parent": 84, "children": [], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 21, "column": 12}}, {"id": 86, "type": "argument_list", "text": "(global_counter)", "parent": 84, "children": [87], "start_point": {"row": 21, "column": 12}, "end_point": {"row": 21, "column": 28}}, {"id": 87, "type": "identifier", "text": "global_counter", "parent": 86, "children": [], "start_point": {"row": 21, "column": 13}, "end_point": {"row": 21, "column": 27}}, {"id": 88, "type": "return_statement", "text": "return regs;", "parent": 65, "children": [89], "start_point": {"row": 22, "column": 4}, "end_point": {"row": 22, "column": 16}}, {"id": 89, "type": "identifier", "text": "regs", "parent": 88, "children": [], "start_point": {"row": 22, "column": 11}, "end_point": {"row": 22, "column": 15}}, {"id": 90, "type": "function_definition", "text": "void main() {\n\tuint32_t number_to_display = 0;\n\tuint32_t counter = 0;\n\n\twhile (1) {\n\t\tcounter = 0;\n\t\tputuint(number_to_display);\n\t\tnumber_to_display++;\n\t\twhile (counter < LOOP_WAIT_LIMIT) {\n\t\t\tcounter++;\n\t\t}\n\t}\n}", "parent": null, "children": [91, 92], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 38, "column": 1}}, {"id": 91, "type": "primitive_type", "text": "void", "parent": 90, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 4}}, {"id": 92, "type": "function_declarator", "text": "main()", "parent": 90, "children": [93, 94], "start_point": {"row": 26, "column": 5}, "end_point": {"row": 26, "column": 11}}, {"id": 93, "type": "identifier", "text": "main", "parent": 92, "children": [], "start_point": {"row": 26, "column": 5}, "end_point": {"row": 26, "column": 9}}, {"id": 94, "type": "parameter_list", "text": "()", "parent": 92, "children": [], "start_point": {"row": 26, "column": 9}, "end_point": {"row": 26, "column": 11}}, {"id": 95, "type": "declaration", "text": "uint32_t number_to_display = 0;", "parent": 90, "children": [96, 97], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 32}}, {"id": 96, "type": "primitive_type", "text": "uint32_t", "parent": 95, "children": [], "start_point": {"row": 27, "column": 1}, "end_point": {"row": 27, "column": 9}}, {"id": 97, "type": "init_declarator", "text": "number_to_display = 0", "parent": 95, "children": [98, 99, 100], "start_point": {"row": 27, "column": 10}, "end_point": {"row": 27, "column": 31}}, {"id": 98, "type": "identifier", "text": "number_to_display", "parent": 97, "children": [], "start_point": {"row": 27, "column": 10}, "end_point": {"row": 27, "column": 27}}, {"id": 99, "type": "=", "text": "=", "parent": 97, "children": [], "start_point": {"row": 27, "column": 28}, "end_point": {"row": 27, "column": 29}}, {"id": 100, "type": "number_literal", "text": "0", "parent": 97, "children": [], "start_point": {"row": 27, "column": 30}, "end_point": {"row": 27, "column": 31}}, {"id": 101, "type": "declaration", "text": "uint32_t counter = 0;", "parent": 90, "children": [102, 103], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 28, "column": 22}}, {"id": 102, "type": "primitive_type", "text": "uint32_t", "parent": 101, "children": [], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 28, "column": 9}}, {"id": 103, "type": "init_declarator", "text": "counter = 0", "parent": 101, "children": [104, 105, 106], "start_point": {"row": 28, "column": 10}, "end_point": {"row": 28, "column": 21}}, {"id": 104, "type": "identifier", "text": "counter", "parent": 103, "children": [], "start_point": {"row": 28, "column": 10}, "end_point": {"row": 28, "column": 17}}, {"id": 105, "type": "=", "text": "=", "parent": 103, "children": [], "start_point": {"row": 28, "column": 18}, "end_point": {"row": 28, "column": 19}}, {"id": 106, "type": "number_literal", "text": "0", "parent": 103, "children": [], "start_point": {"row": 28, "column": 20}, "end_point": {"row": 28, "column": 21}}, {"id": 107, "type": "while_statement", "text": "while (1) {\n\t\tcounter = 0;\n\t\tputuint(number_to_display);\n\t\tnumber_to_display++;\n\t\twhile (counter < LOOP_WAIT_LIMIT) {\n\t\t\tcounter++;\n\t\t}\n\t}", "parent": 90, "children": [108], "start_point": {"row": 30, "column": 1}, "end_point": {"row": 37, "column": 2}}, {"id": 108, "type": "parenthesized_expression", "text": "(1)", "parent": 107, "children": [109], "start_point": {"row": 30, "column": 7}, "end_point": {"row": 30, "column": 10}}, {"id": 109, "type": "number_literal", "text": "1", "parent": 108, "children": [], "start_point": {"row": 30, "column": 8}, "end_point": {"row": 30, "column": 9}}, {"id": 110, "type": "assignment_expression", "text": "counter = 0", "parent": 107, "children": [111, 112, 113], "start_point": {"row": 31, "column": 2}, "end_point": {"row": 31, "column": 13}}, {"id": 111, "type": "identifier", "text": "counter", "parent": 110, "children": [], "start_point": {"row": 31, "column": 2}, "end_point": {"row": 31, "column": 9}}, {"id": 112, "type": "=", "text": "=", "parent": 110, "children": [], "start_point": {"row": 31, "column": 10}, "end_point": {"row": 31, "column": 11}}, {"id": 113, "type": "number_literal", "text": "0", "parent": 110, "children": [], "start_point": {"row": 31, "column": 12}, "end_point": {"row": 31, "column": 13}}, {"id": 114, "type": "call_expression", "text": "putuint(number_to_display)", "parent": 107, "children": [115, 116], "start_point": {"row": 32, "column": 2}, "end_point": {"row": 32, "column": 28}}, {"id": 115, "type": "identifier", "text": "putuint", "parent": 114, "children": [], "start_point": {"row": 32, "column": 2}, "end_point": {"row": 32, "column": 9}}, {"id": 116, "type": "argument_list", "text": "(number_to_display)", "parent": 114, "children": [117], "start_point": {"row": 32, "column": 9}, "end_point": {"row": 32, "column": 28}}, {"id": 117, "type": "identifier", "text": "number_to_display", "parent": 116, "children": [], "start_point": {"row": 32, "column": 10}, "end_point": {"row": 32, "column": 27}}, {"id": 118, "type": "update_expression", "text": "number_to_display++", "parent": 107, "children": [119, 120], "start_point": {"row": 33, "column": 2}, "end_point": {"row": 33, "column": 21}}, {"id": 119, "type": "identifier", "text": "number_to_display", "parent": 118, "children": [], "start_point": {"row": 33, "column": 2}, "end_point": {"row": 33, "column": 19}}, {"id": 120, "type": "++", "text": "++", "parent": 118, "children": [], "start_point": {"row": 33, "column": 19}, "end_point": {"row": 33, "column": 21}}, {"id": 121, "type": "while_statement", "text": "while (counter < LOOP_WAIT_LIMIT) {\n\t\t\tcounter++;\n\t\t}", "parent": 107, "children": [122], "start_point": {"row": 34, "column": 2}, "end_point": {"row": 36, "column": 3}}, {"id": 122, "type": "parenthesized_expression", "text": "(counter < LOOP_WAIT_LIMIT)", "parent": 121, "children": [123], "start_point": {"row": 34, "column": 8}, "end_point": {"row": 34, "column": 35}}, {"id": 123, "type": "binary_expression", "text": "counter < LOOP_WAIT_LIMIT", "parent": 122, "children": [124, 125, 126], "start_point": {"row": 34, "column": 9}, "end_point": {"row": 34, "column": 34}}, {"id": 124, "type": "identifier", "text": "counter", "parent": 123, "children": [], "start_point": {"row": 34, "column": 9}, "end_point": {"row": 34, "column": 16}}, {"id": 125, "type": "<", "text": "<", "parent": 123, "children": [], "start_point": {"row": 34, "column": 17}, "end_point": {"row": 34, "column": 18}}, {"id": 126, "type": "identifier", "text": "LOOP_WAIT_LIMIT", "parent": 123, "children": [], "start_point": {"row": 34, "column": 19}, "end_point": {"row": 34, "column": 34}}, {"id": 127, "type": "update_expression", "text": "counter++", "parent": 121, "children": [128, 129], "start_point": {"row": 35, "column": 3}, "end_point": {"row": 35, "column": 12}}, {"id": 128, "type": "identifier", "text": "counter", "parent": 127, "children": [], "start_point": {"row": 35, "column": 3}, "end_point": {"row": 35, "column": 10}}, {"id": 129, "type": "++", "text": "++", "parent": 127, "children": [], "start_point": {"row": 35, "column": 10}, "end_point": {"row": 35, "column": 12}}]}, "node_categories": {"declarations": {"functions": [21, 23, 43, 45, 65, 69, 90, 92], "variables": [15, 26, 48, 72, 77, 95, 101], "classes": [], "imports": [0, 1], "modules": [], "enums": []}, "statements": {"expressions": [30, 32, 33, 52, 54, 55, 84, 108, 114, 118, 122, 123, 127], "assignments": [29, 51, 80, 110], "loops": [107, 121], "conditionals": [5, 9, 13, 18, 24, 28, 35, 40, 42, 46, 50, 57, 62, 64, 70, 76, 79, 81, 85, 87, 89, 93, 98, 104, 111, 115, 117, 119, 124, 126, 128], "returns": [88], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 20, 83, 100, 106, 109, 113], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 21, "universal_type": "function", "name": "putuint", "text_snippet": "static void putuint(uint32_t i) {\n\t*((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD) = i;\n}"}, {"node_id": 23, "universal_type": "function", "name": "unknown", "text_snippet": "putuint(uint32_t i)"}, {"node_id": 43, "universal_type": "function", "name": "putuint2", "text_snippet": "static void putuint2(uint32_t i) {\n\t*((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD) = i;\n}"}, {"node_id": 45, "universal_type": "function", "name": "unknown", "text_snippet": "putuint2(uint32_t i)"}, {"node_id": 65, "universal_type": "function", "name": "unknown", "text_snippet": "uint32_t *irq(uint32_t *regs, uint32_t irqs) {\n global_counter += 1;\n putuint2(global_counter)"}, {"node_id": 69, "universal_type": "function", "name": "unknown", "text_snippet": "irq(uint32_t *regs, uint32_t irqs)"}, {"node_id": 90, "universal_type": "function", "name": "main", "text_snippet": "void main() {\n\tuint32_t number_to_display = 0;\n\tuint32_t counter = 0;\n\n\twhile (1) {\n\t\tcounter = 0;\n\t"}, {"node_id": 92, "universal_type": "function", "name": "unknown", "text_snippet": "main()"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <stdint.h>\n"}, {"node_id": 1, "text": "#include"}]}, "original_source_code": "#include <stdint.h>\n\n#define LED_REGISTERS_MEMORY_ADD 0x10000000\n#define IRQ_REGISTERS_MEMORY_ADD 0x10000004\n\n\n#define LOOP_WAIT_LIMIT 100\n\nuint32_t global_counter = 0;\n\nstatic void putuint(uint32_t i) {\n\t*((volatile uint32_t *)LED_REGISTERS_MEMORY_ADD) = i;\n}\n\nstatic void putuint2(uint32_t i) {\n\t*((volatile uint32_t *)IRQ_REGISTERS_MEMORY_ADD) = i;\n}\n\n\nuint32_t *irq(uint32_t *regs, uint32_t irqs) {\n global_counter += 1;\n putuint2(global_counter);\n return regs;\n}\n\n\nvoid main() {\n\tuint32_t number_to_display = 0;\n\tuint32_t counter = 0;\n\n\twhile (1) {\n\t\tcounter = 0;\n\t\tputuint(number_to_display);\n\t\tnumber_to_display++;\n\t\twhile (counter < LOOP_WAIT_LIMIT) {\n\t\t\tcounter++;\n\t\t}\n\t}\n}\n"}
80,585
c
// // TextFieldsCodeObjCViewController.h // AndesUI-demoapp // // Created by <NAME> on 07/10/2020. // Copyright © 2020 MercadoLibre. All rights reserved. // #import <UIKit/UIKit.h> NS_ASSUME_NONNULL_BEGIN @interface TextFieldsCodeObjCViewController : UIViewController @end NS_ASSUME_NONNULL_END
23.92
12
(translation_unit) "//\n// TextFieldsCodeObjCViewController.h\n// AndesUI-demoapp\n//\n// Created by <NAME> on 07/10/2020.\n// Copyright © 2020 MercadoLibre. All rights reserved.\n//\n\n#import <UIKit/UIKit.h>\n\nNS_ASSUME_NONNULL_BEGIN\n\n@interface TextFieldsCodeObjCViewController : UIViewController\n\n@end\n\nNS_ASSUME_NONNULL_END\n" (comment) "//" (comment) "// TextFieldsCodeObjCViewController.h" (comment) "// AndesUI-demoapp" (comment) "//" (comment) "// Created by <NAME> on 07/10/2020." (comment) "// Copyright © 2020 MercadoLibre. All rights reserved.\n" (comment) "/\n" (preproc_call) "import <UIKit/UIKit.h>\n\n" (preproc_directive) "import " (preproc_arg) "UIKit/UIKit.h>\n" (declaration) "S_ASSUME_NONNULL_BEGIN\n\n@interface " (type_identifier) "S_ASSUME_NONNULL_BEGIN\n" (ERROR) "i" (ERROR) "i" (identifier) "nterface " (;) "" (labeled_statement) "extFieldsCodeObjCViewController : UIViewController\n\n@end\n\nNS_ASSUME_NONNULL_END\n" (statement_identifier) "extFieldsCodeObjCViewController " (:) " " (declaration) "IViewController\n\n@end\n\nNS_ASSUME_NONNULL_END\n" (type_identifier) "IViewController\n" (ERROR) "end\n" (ERROR) "e" (identifier) "nd\n" (identifier) "S_ASSUME_NONNULL_END\n" (;) ""
27
4
{"language": "c", "success": true, "metadata": {"lines": 12, "avg_line_length": 23.92, "nodes": 14, "errors": 0, "source_hash": "5119e369cc43c262654aa2febad517676a407067ca31aeb47b0d6ca5a74713d0", "categorized_nodes": 9}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "import <UIKit/UIKit.h>\n\n", "parent": null, "children": [1], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 1, "type": "preproc_arg", "text": "UIKit/UIKit.h>\n", "parent": 0, "children": [], "start_point": {"row": 8, "column": 8}, "end_point": {"row": 8, "column": 23}}, {"id": 2, "type": "declaration", "text": "S_ASSUME_NONNULL_BEGIN\n\n@interface ", "parent": null, "children": [3, 4, 6], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 12, "column": 10}}, {"id": 3, "type": "type_identifier", "text": "S_ASSUME_NONNULL_BEGIN\n", "parent": 2, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 23}}, {"id": 4, "type": "ERROR", "text": "i", "parent": 2, "children": [5], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 1}}, {"id": 5, "type": "ERROR", "text": "i", "parent": 4, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 1}}, {"id": 6, "type": "identifier", "text": "nterface ", "parent": 2, "children": [], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 10}}, {"id": 7, "type": "labeled_statement", "text": "extFieldsCodeObjCViewController : UIViewController\n\n@end\n\nNS_ASSUME_NONNULL_END\n", "parent": null, "children": [8, 9], "start_point": {"row": 12, "column": 11}, "end_point": {"row": 16, "column": 21}}, {"id": 8, "type": "statement_identifier", "text": "extFieldsCodeObjCViewController ", "parent": 7, "children": [], "start_point": {"row": 12, "column": 11}, "end_point": {"row": 12, "column": 43}}, {"id": 9, "type": "declaration", "text": "IViewController\n\n@end\n\nNS_ASSUME_NONNULL_END\n", "parent": 7, "children": [10, 13], "start_point": {"row": 12, "column": 46}, "end_point": {"row": 16, "column": 21}}, {"id": 10, "type": "type_identifier", "text": "IViewController\n", "parent": 9, "children": [], "start_point": {"row": 12, "column": 46}, "end_point": {"row": 12, "column": 62}}, {"id": 11, "type": "ERROR", "text": "e", "parent": 9, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 1}}, {"id": 12, "type": "identifier", "text": "nd\n", "parent": 9, "children": [], "start_point": {"row": 14, "column": 1}, "end_point": {"row": 14, "column": 4}}, {"id": 13, "type": "identifier", "text": "S_ASSUME_NONNULL_END\n", "parent": 9, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 21}}]}, "node_categories": {"declarations": {"functions": [], "variables": [2, 9], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [3, 6, 8, 10, 12, 13], "returns": [], "exceptions": []}, "expressions": {"calls": [0], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [], "class_declarations": [], "import_statements": []}, "original_source_code": "//\n// TextFieldsCodeObjCViewController.h\n// AndesUI-demoapp\n//\n// Created by <NAME> on 07/10/2020.\n// Copyright \u00a9 2020 MercadoLibre. All rights reserved.\n//\n\n#import <UIKit/UIKit.h>\n\nNS_ASSUME_NONNULL_BEGIN\n\n@interface TextFieldsCodeObjCViewController : UIViewController\n\n@end\n\nNS_ASSUME_NONNULL_END\n"}
80,586
c
// // ofxLaserRenderProfile.hpp // ofxLaser // // Created by <NAME> on 13/11/2017. // // #pragma once #include "ofMain.h" namespace ofxLaser { class RenderProfile { public : RenderProfile(string _label = "") { //ofLogNotice("RenderProfile default constructor called "+_label); init(_label); } void init(string _label) { label = _label; speed = 2; acceleration = 4; cornerThreshold = 125; params.setName(label); params.add(speed.set("speed",2,1,40)); params.add(acceleration.set("acceleration",1,0.01,10)); params.add(cornerThreshold.set("corner threshold",90,0,180)); params.add(dotMaxPoints.set("dot max points", 2, 0, 100)); } void setLabel(string _label) { label = _label; params.setName(label); } ofParameter<float> speed; ofParameter<float> acceleration; ofParameter<float> cornerThreshold; ofParameter<int> dotMaxPoints; ofParameterGroup params; private : string label; }; }
20.83
48
(translation_unit) "//\n// ofxLaserRenderProfile.hpp\n// ofxLaser\n//\n// Created by <NAME> on 13/11/2017.\n//\n//\n#pragma once\n#include "ofMain.h"\n\nnamespace ofxLaser {\n\n class RenderProfile {\n public :\n RenderProfile(string _label = "") {\n \n //ofLogNotice("RenderProfile default constructor called "+_label);\n init(_label);\n }\n \n void init(string _label) {\n \n label = _label;\n speed = 2;\n acceleration = 4;\n cornerThreshold = 125;\n \n params.setName(label);\n params.add(speed.set("speed",2,1,40));\n params.add(acceleration.set("acceleration",1,0.01,10));\n params.add(cornerThreshold.set("corner threshold",90,0,180));\n params.add(dotMaxPoints.set("dot max points", 2, 0, 100));\n \n }\n void setLabel(string _label) {\n label = _label;\n params.setName(label);\n } \n \n \n ofParameter<float> speed;\n ofParameter<float> acceleration;\n ofParameter<float> cornerThreshold;\n ofParameter<int> dotMaxPoints;\n \n ofParameterGroup params;\n private :\n string label;\n\n };\n\n}\n" (comment) "//" (comment) "// ofxLaserRenderProfile.hpp" (comment) "// ofxLaser" (comment) "//" (comment) "// Created by <NAME> on 13/11/2017." (comment) "//" (comment) "//" (preproc_call) "#pragma once\n" (preproc_directive) "#pragma" (preproc_arg) "once" (preproc_include) "#include "ofMain.h"\n" (#include) "#include" (string_literal) ""ofMain.h"" (") """ (string_content) "ofMain.h" (") """ (function_definition) "namespace ofxLaser {\n\n class RenderProfile {\n public :\n RenderProfile(string _label = "") {\n \n //ofLogNotice("RenderProfile default constructor called "+_label);\n init(_label);\n }\n \n void init(string _label) {\n \n label = _label;\n speed = 2;\n acceleration = 4;\n cornerThreshold = 125;\n \n params.setName(label);\n params.add(speed.set("speed",2,1,40));\n params.add(acceleration.set("acceleration",1,0.01,10));\n params.add(cornerThreshold.set("corner threshold",90,0,180));\n params.add(dotMaxPoints.set("dot max points", 2, 0, 100));\n \n }\n void setLabel(string _label) {\n label = _label;\n params.setName(label);\n } \n \n \n ofParameter<float> speed;\n ofParameter<float> acceleration;\n ofParameter<float> cornerThreshold;\n ofParameter<int> dotMaxPoints;\n \n ofParameterGroup params;\n private :\n string label;\n\n }" (type_identifier) "namespace" (identifier) "ofxLaser" (compound_statement) "{\n\n class RenderProfile {\n public :\n RenderProfile(string _label = "") {\n \n //ofLogNotice("RenderProfile default constructor called "+_label);\n init(_label);\n }\n \n void init(string _label) {\n \n label = _label;\n speed = 2;\n acceleration = 4;\n cornerThreshold = 125;\n \n params.setName(label);\n params.add(speed.set("speed",2,1,40));\n params.add(acceleration.set("acceleration",1,0.01,10));\n params.add(cornerThreshold.set("corner threshold",90,0,180));\n params.add(dotMaxPoints.set("dot max points", 2, 0, 100));\n \n }\n void setLabel(string _label) {\n label = _label;\n params.setName(label);\n } \n \n \n ofParameter<float> speed;\n ofParameter<float> acceleration;\n ofParameter<float> cornerThreshold;\n ofParameter<int> dotMaxPoints;\n \n ofParameterGroup params;\n private :\n string label;\n\n }" ({) "{" (function_definition) "class RenderProfile {\n public :\n RenderProfile(string _label = "") {\n \n //ofLogNotice("RenderProfile default constructor called "+_label);\n init(_label);\n }" (type_identifier) "class" (identifier) "RenderProfile" (compound_statement) "{\n public :\n RenderProfile(string _label = "") {\n \n //ofLogNotice("RenderProfile default constructor called "+_label);\n init(_label);\n }" ({) "{" (labeled_statement) "public :\n RenderProfile(string _label = "") {\n \n //ofLogNotice("RenderProfile default constructor called "+_label);\n init(_label);" (statement_identifier) "public" (:) ":" (declaration) "RenderProfile(string _label = "") {\n \n //ofLogNotice("RenderProfile default constructor called "+_label);\n init(_label);" (macro_type_specifier) "RenderProfile(string" (identifier) "RenderProfile" (() "(" (type_descriptor) "string" (type_identifier) "string" ()) "" (init_declarator) "_label = "") {\n \n //ofLogNotice("RenderProfile default constructor called "+_label);\n init(_label)" (identifier) "_label" (=) "=" (ERROR) """)" (string_literal) """" (") """ (") """ ()) ")" (initializer_list) "{\n \n //ofLogNotice("RenderProfile default constructor called "+_label);\n init(_label)" ({) "{" (comment) "//ofLogNotice("RenderProfile default constructor called "+_label);" (call_expression) "init(_label)" (identifier) "init" (argument_list) "(_label)" (() "(" (identifier) "_label" ()) ")" (}) "" (;) ";" (}) "}" (function_definition) "void init(string _label) {\n \n label = _label;\n speed = 2;\n acceleration = 4;\n cornerThreshold = 125;\n \n params.setName(label);\n params.add(speed.set("speed",2,1,40));\n params.add(acceleration.set("acceleration",1,0.01,10));\n params.add(cornerThreshold.set("corner threshold",90,0,180));\n params.add(dotMaxPoints.set("dot max points", 2, 0, 100));\n \n }" (primitive_type) "void" (function_declarator) "init(string _label)" (identifier) "init" (parameter_list) "(string _label)" (() "(" (parameter_declaration) "string _label" (type_identifier) "string" (identifier) "_label" ()) ")" (compound_statement) "{\n \n label = _label;\n speed = 2;\n acceleration = 4;\n cornerThreshold = 125;\n \n params.setName(label);\n params.add(speed.set("speed",2,1,40));\n params.add(acceleration.set("acceleration",1,0.01,10));\n params.add(cornerThreshold.set("corner threshold",90,0,180));\n params.add(dotMaxPoints.set("dot max points", 2, 0, 100));\n \n }" ({) "{" (expression_statement) "label = _label;" (assignment_expression) "label = _label" (identifier) "label" (=) "=" (identifier) "_label" (;) ";" (expression_statement) "speed = 2;" (assignment_expression) "speed = 2" (identifier) "speed" (=) "=" (number_literal) "2" (;) ";" (expression_statement) "acceleration = 4;" (assignment_expression) "acceleration = 4" (identifier) "acceleration" (=) "=" (number_literal) "4" (;) ";" (expression_statement) "cornerThreshold = 125;" (assignment_expression) "cornerThreshold = 125" (identifier) "cornerThreshold" (=) "=" (number_literal) "125" (;) ";" (expression_statement) "params.setName(label);" (call_expression) "params.setName(label)" (field_expression) "params.setName" (identifier) "params" (.) "." (field_identifier) "setName" (argument_list) "(label)" (() "(" (identifier) "label" ()) ")" (;) ";" (expression_statement) "params.add(speed.set("speed",2,1,40));" (call_expression) "params.add(speed.set("speed",2,1,40))" (field_expression) "params.add" (identifier) "params" (.) "." (field_identifier) "add" (argument_list) "(speed.set("speed",2,1,40))" (() "(" (call_expression) "speed.set("speed",2,1,40)" (field_expression) "speed.set" (identifier) "speed" (.) "." (field_identifier) "set" (argument_list) "("speed",2,1,40)" (() "(" (string_literal) ""speed"" (") """ (string_content) "speed" (") """ (,) "," (number_literal) "2" (,) "," (number_literal) "1" (,) "," (number_literal) "40" ()) ")" ()) ")" (;) ";" (expression_statement) "params.add(acceleration.set("acceleration",1,0.01,10));" (call_expression) "params.add(acceleration.set("acceleration",1,0.01,10))" (field_expression) "params.add" (identifier) "params" (.) "." (field_identifier) "add" (argument_list) "(acceleration.set("acceleration",1,0.01,10))" (() "(" (call_expression) "acceleration.set("acceleration",1,0.01,10)" (field_expression) "acceleration.set" (identifier) "acceleration" (.) "." (field_identifier) "set" (argument_list) "("acceleration",1,0.01,10)" (() "(" (string_literal) ""acceleration"" (") """ (string_content) "acceleration" (") """ (,) "," (number_literal) "1" (,) "," (number_literal) "0.01" (,) "," (number_literal) "10" ()) ")" ()) ")" (;) ";" (expression_statement) "params.add(cornerThreshold.set("corner threshold",90,0,180));" (call_expression) "params.add(cornerThreshold.set("corner threshold",90,0,180))" (field_expression) "params.add" (identifier) "params" (.) "." (field_identifier) "add" (argument_list) "(cornerThreshold.set("corner threshold",90,0,180))" (() "(" (call_expression) "cornerThreshold.set("corner threshold",90,0,180)" (field_expression) "cornerThreshold.set" (identifier) "cornerThreshold" (.) "." (field_identifier) "set" (argument_list) "("corner threshold",90,0,180)" (() "(" (string_literal) ""corner threshold"" (") """ (string_content) "corner threshold" (") """ (,) "," (number_literal) "90" (,) "," (number_literal) "0" (,) "," (number_literal) "180" ()) ")" ()) ")" (;) ";" (expression_statement) "params.add(dotMaxPoints.set("dot max points", 2, 0, 100));" (call_expression) "params.add(dotMaxPoints.set("dot max points", 2, 0, 100))" (field_expression) "params.add" (identifier) "params" (.) "." (field_identifier) "add" (argument_list) "(dotMaxPoints.set("dot max points", 2, 0, 100))" (() "(" (call_expression) "dotMaxPoints.set("dot max points", 2, 0, 100)" (field_expression) "dotMaxPoints.set" (identifier) "dotMaxPoints" (.) "." (field_identifier) "set" (argument_list) "("dot max points", 2, 0, 100)" (() "(" (string_literal) ""dot max points"" (") """ (string_content) "dot max points" (") """ (,) "," (number_literal) "2" (,) "," (number_literal) "0" (,) "," (number_literal) "100" ()) ")" ()) ")" (;) ";" (}) "}" (function_definition) "void setLabel(string _label) {\n label = _label;\n params.setName(label);\n }" (primitive_type) "void" (function_declarator) "setLabel(string _label)" (identifier) "setLabel" (parameter_list) "(string _label)" (() "(" (parameter_declaration) "string _label" (type_identifier) "string" (identifier) "_label" ()) ")" (compound_statement) "{\n label = _label;\n params.setName(label);\n }" ({) "{" (expression_statement) "label = _label;" (assignment_expression) "label = _label" (identifier) "label" (=) "=" (identifier) "_label" (;) ";" (expression_statement) "params.setName(label);" (call_expression) "params.setName(label)" (field_expression) "params.setName" (identifier) "params" (.) "." (field_identifier) "setName" (argument_list) "(label)" (() "(" (identifier) "label" ()) ")" (;) ";" (}) "}" (expression_statement) "ofParameter<float> speed;" (binary_expression) "ofParameter<float> speed" (binary_expression) "ofParameter<float" (identifier) "ofParameter" (<) "<" (identifier) "float" (>) ">" (identifier) "speed" (;) ";" (expression_statement) "ofParameter<float> acceleration;" (binary_expression) "ofParameter<float> acceleration" (binary_expression) "ofParameter<float" (identifier) "ofParameter" (<) "<" (identifier) "float" (>) ">" (identifier) "acceleration" (;) ";" (expression_statement) "ofParameter<float> cornerThreshold;" (binary_expression) "ofParameter<float> cornerThreshold" (binary_expression) "ofParameter<float" (identifier) "ofParameter" (<) "<" (identifier) "float" (>) ">" (identifier) "cornerThreshold" (;) ";" (expression_statement) "ofParameter<int> dotMaxPoints;" (binary_expression) "ofParameter<int> dotMaxPoints" (binary_expression) "ofParameter<int" (identifier) "ofParameter" (<) "<" (identifier) "int" (>) ">" (identifier) "dotMaxPoints" (;) ";" (declaration) "ofParameterGroup params;" (type_identifier) "ofParameterGroup" (identifier) "params" (;) ";" (labeled_statement) "private :\n string label;" (statement_identifier) "private" (:) ":" (declaration) "string label;" (type_identifier) "string" (identifier) "label" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (ERROR) "}" (}) "}"
299
2
{"language": "c", "success": true, "metadata": {"lines": 48, "avg_line_length": 20.83, "nodes": 166, "errors": 0, "source_hash": "cdf092bf95c36793ad940585476c2ada43cd97c04e8b0dcf383656d8c513e204", "categorized_nodes": 129}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#pragma once\n", "parent": null, "children": [1, 2], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#pragma", "parent": 0, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "once", "parent": 0, "children": [], "start_point": {"row": 7, "column": 8}, "end_point": {"row": 7, "column": 12}}, {"id": 3, "type": "preproc_include", "text": "#include \"ofMain.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 8}}, {"id": 5, "type": "string_literal", "text": "\"ofMain.h\"", "parent": 3, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 19}}, {"id": 6, "type": "function_definition", "text": "namespace ofxLaser {\n\n\tclass RenderProfile {\n\t\tpublic :\n\t\tRenderProfile(string _label = \"\") {\n\t\t\t\n\t\t\t//ofLogNotice(\"RenderProfile default constructor called \"+_label);\n init(_label);\n\t\t}\n\t\t\n\t\tvoid init(string _label) {\n\t\t\t\n label = _label;\n\t\t\tspeed = 2;\n\t\t\tacceleration = 4;\n\t\t\tcornerThreshold = 125;\n\t\t\t\n\t\t\tparams.setName(label);\n\t\t\tparams.add(speed.set(\"speed\",2,1,40));\n\t\t\tparams.add(acceleration.set(\"acceleration\",1,0.01,10));\n\t\t\tparams.add(cornerThreshold.set(\"corner threshold\",90,0,180));\n\t\t\tparams.add(dotMaxPoints.set(\"dot max points\", 2, 0, 100));\n\t\t\t\n\t\t}\n void setLabel(string _label) {\n label = _label;\n params.setName(label);\n } \n\t\t\n \n\t\tofParameter<float> speed;\n\t\tofParameter<float> acceleration;\n\t\tofParameter<float> cornerThreshold;\n\t\tofParameter<int> dotMaxPoints;\n\t\t\n\t\tofParameterGroup params;\n private :\n string label;\n\n\t}", "parent": null, "children": [7, 8], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 49, "column": 2}}, {"id": 7, "type": "type_identifier", "text": "namespace", "parent": 6, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 9}}, {"id": 8, "type": "identifier", "text": "ofxLaser", "parent": 6, "children": [], "start_point": {"row": 10, "column": 10}, "end_point": {"row": 10, "column": 18}}, {"id": 9, "type": "function_definition", "text": "class RenderProfile {\n\t\tpublic :\n\t\tRenderProfile(string _label = \"\") {\n\t\t\t\n\t\t\t//ofLogNotice(\"RenderProfile default constructor called \"+_label);\n init(_label);\n\t\t}", "parent": 6, "children": [10], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 18, "column": 3}}, {"id": 10, "type": "identifier", "text": "RenderProfile", "parent": 9, "children": [], "start_point": {"row": 12, "column": 7}, "end_point": {"row": 12, "column": 20}}, {"id": 11, "type": "labeled_statement", "text": "public :\n\t\tRenderProfile(string _label = \"\") {\n\t\t\t\n\t\t\t//ofLogNotice(\"RenderProfile default constructor called \"+_label);\n init(_label);", "parent": 9, "children": [12], "start_point": {"row": 13, "column": 2}, "end_point": {"row": 17, "column": 25}}, {"id": 12, "type": "declaration", "text": "RenderProfile(string _label = \"\") {\n\t\t\t\n\t\t\t//ofLogNotice(\"RenderProfile default constructor called \"+_label);\n init(_label);", "parent": 11, "children": [13, 17], "start_point": {"row": 14, "column": 2}, "end_point": {"row": 17, "column": 25}}, {"id": 13, "type": "macro_type_specifier", "text": "RenderProfile(string", "parent": 12, "children": [14, 15], "start_point": {"row": 14, "column": 2}, "end_point": {"row": 14, "column": 22}}, {"id": 14, "type": "identifier", "text": "RenderProfile", "parent": 13, "children": [], "start_point": {"row": 14, "column": 2}, "end_point": {"row": 14, "column": 15}}, {"id": 15, "type": "type_descriptor", "text": "string", "parent": 13, "children": [16], "start_point": {"row": 14, "column": 16}, "end_point": {"row": 14, "column": 22}}, {"id": 16, "type": "type_identifier", "text": "string", "parent": 15, "children": [], "start_point": {"row": 14, "column": 16}, "end_point": {"row": 14, "column": 22}}, {"id": 17, "type": "init_declarator", "text": "_label = \"\") {\n\t\t\t\n\t\t\t//ofLogNotice(\"RenderProfile default constructor called \"+_label);\n init(_label)", "parent": 12, "children": [18, 19, 20, 22], "start_point": {"row": 14, "column": 23}, "end_point": {"row": 17, "column": 24}}, {"id": 18, "type": "identifier", "text": "_label", "parent": 17, "children": [], "start_point": {"row": 14, "column": 23}, "end_point": {"row": 14, "column": 29}}, {"id": 19, "type": "=", "text": "=", "parent": 17, "children": [], "start_point": {"row": 14, "column": 30}, "end_point": {"row": 14, "column": 31}}, {"id": 20, "type": "ERROR", "text": "\"\")", "parent": 17, "children": [21], "start_point": {"row": 14, "column": 32}, "end_point": {"row": 14, "column": 35}}, {"id": 21, "type": "string_literal", "text": "\"\"", "parent": 20, "children": [], "start_point": {"row": 14, "column": 32}, "end_point": {"row": 14, "column": 34}}, {"id": 22, "type": "initializer_list", "text": "{\n\t\t\t\n\t\t\t//ofLogNotice(\"RenderProfile default constructor called \"+_label);\n init(_label)", "parent": 17, "children": [23], "start_point": {"row": 14, "column": 36}, "end_point": {"row": 17, "column": 24}}, {"id": 23, "type": "call_expression", "text": "init(_label)", "parent": 22, "children": [24, 25], "start_point": {"row": 17, "column": 12}, "end_point": {"row": 17, "column": 24}}, {"id": 24, "type": "identifier", "text": "init", "parent": 23, "children": [], "start_point": {"row": 17, "column": 12}, "end_point": {"row": 17, "column": 16}}, {"id": 25, "type": "argument_list", "text": "(_label)", "parent": 23, "children": [26], "start_point": {"row": 17, "column": 16}, "end_point": {"row": 17, "column": 24}}, {"id": 26, "type": "identifier", "text": "_label", "parent": 25, "children": [], "start_point": {"row": 17, "column": 17}, "end_point": {"row": 17, "column": 23}}, {"id": 27, "type": "function_definition", "text": "void init(string _label) {\n\t\t\t\n label = _label;\n\t\t\tspeed = 2;\n\t\t\tacceleration = 4;\n\t\t\tcornerThreshold = 125;\n\t\t\t\n\t\t\tparams.setName(label);\n\t\t\tparams.add(speed.set(\"speed\",2,1,40));\n\t\t\tparams.add(acceleration.set(\"acceleration\",1,0.01,10));\n\t\t\tparams.add(cornerThreshold.set(\"corner threshold\",90,0,180));\n\t\t\tparams.add(dotMaxPoints.set(\"dot max points\", 2, 0, 100));\n\t\t\t\n\t\t}", "parent": 6, "children": [28, 29], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 33, "column": 3}}, {"id": 28, "type": "primitive_type", "text": "void", "parent": 27, "children": [], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 6}}, {"id": 29, "type": "function_declarator", "text": "init(string _label)", "parent": 27, "children": [30, 31], "start_point": {"row": 20, "column": 7}, "end_point": {"row": 20, "column": 26}}, {"id": 30, "type": "identifier", "text": "init", "parent": 29, "children": [], "start_point": {"row": 20, "column": 7}, "end_point": {"row": 20, "column": 11}}, {"id": 31, "type": "parameter_list", "text": "(string _label)", "parent": 29, "children": [32], "start_point": {"row": 20, "column": 11}, "end_point": {"row": 20, "column": 26}}, {"id": 32, "type": "parameter_declaration", "text": "string _label", "parent": 31, "children": [33, 34], "start_point": {"row": 20, "column": 12}, "end_point": {"row": 20, "column": 25}}, {"id": 33, "type": "type_identifier", "text": "string", "parent": 32, "children": [], "start_point": {"row": 20, "column": 12}, "end_point": {"row": 20, "column": 18}}, {"id": 34, "type": "identifier", "text": "_label", "parent": 32, "children": [], "start_point": {"row": 20, "column": 19}, "end_point": {"row": 20, "column": 25}}, {"id": 35, "type": "assignment_expression", "text": "label = _label", "parent": 27, "children": [36, 37, 38], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 26}}, {"id": 36, "type": "identifier", "text": "label", "parent": 35, "children": [], "start_point": {"row": 22, "column": 12}, "end_point": {"row": 22, "column": 17}}, {"id": 37, "type": "=", "text": "=", "parent": 35, "children": [], "start_point": {"row": 22, "column": 18}, "end_point": {"row": 22, "column": 19}}, {"id": 38, "type": "identifier", "text": "_label", "parent": 35, "children": [], "start_point": {"row": 22, "column": 20}, "end_point": {"row": 22, "column": 26}}, {"id": 39, "type": "assignment_expression", "text": "speed = 2", "parent": 27, "children": [40, 41, 42], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 23, "column": 12}}, {"id": 40, "type": "identifier", "text": "speed", "parent": 39, "children": [], "start_point": {"row": 23, "column": 3}, "end_point": {"row": 23, "column": 8}}, {"id": 41, "type": "=", "text": "=", "parent": 39, "children": [], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 10}}, {"id": 42, "type": "number_literal", "text": "2", "parent": 39, "children": [], "start_point": {"row": 23, "column": 11}, "end_point": {"row": 23, "column": 12}}, {"id": 43, "type": "assignment_expression", "text": "acceleration = 4", "parent": 27, "children": [44, 45, 46], "start_point": {"row": 24, "column": 3}, "end_point": {"row": 24, "column": 19}}, {"id": 44, "type": "identifier", "text": "acceleration", "parent": 43, "children": [], "start_point": {"row": 24, "column": 3}, "end_point": {"row": 24, "column": 15}}, {"id": 45, "type": "=", "text": "=", "parent": 43, "children": [], "start_point": {"row": 24, "column": 16}, "end_point": {"row": 24, "column": 17}}, {"id": 46, "type": "number_literal", "text": "4", "parent": 43, "children": [], "start_point": {"row": 24, "column": 18}, "end_point": {"row": 24, "column": 19}}, {"id": 47, "type": "assignment_expression", "text": "cornerThreshold = 125", "parent": 27, "children": [48, 49, 50], "start_point": {"row": 25, "column": 3}, "end_point": {"row": 25, "column": 24}}, {"id": 48, "type": "identifier", "text": "cornerThreshold", "parent": 47, "children": [], "start_point": {"row": 25, "column": 3}, "end_point": {"row": 25, "column": 18}}, {"id": 49, "type": "=", "text": "=", "parent": 47, "children": [], "start_point": {"row": 25, "column": 19}, "end_point": {"row": 25, "column": 20}}, {"id": 50, "type": "number_literal", "text": "125", "parent": 47, "children": [], "start_point": {"row": 25, "column": 21}, "end_point": {"row": 25, "column": 24}}, {"id": 51, "type": "call_expression", "text": "params.setName(label)", "parent": 27, "children": [52, 55], "start_point": {"row": 27, "column": 3}, "end_point": {"row": 27, "column": 24}}, {"id": 52, "type": "field_expression", "text": "params.setName", "parent": 51, "children": [53, 54], "start_point": {"row": 27, "column": 3}, "end_point": {"row": 27, "column": 17}}, {"id": 53, "type": "identifier", "text": "params", "parent": 52, "children": [], "start_point": {"row": 27, "column": 3}, "end_point": {"row": 27, "column": 9}}, {"id": 54, "type": "field_identifier", "text": "setName", "parent": 52, "children": [], "start_point": {"row": 27, "column": 10}, "end_point": {"row": 27, "column": 17}}, {"id": 55, "type": "argument_list", "text": "(label)", "parent": 51, "children": [56], "start_point": {"row": 27, "column": 17}, "end_point": {"row": 27, "column": 24}}, {"id": 56, "type": "identifier", "text": "label", "parent": 55, "children": [], "start_point": {"row": 27, "column": 18}, "end_point": {"row": 27, "column": 23}}, {"id": 57, "type": "call_expression", "text": "params.add(speed.set(\"speed\",2,1,40))", "parent": 27, "children": [58, 61], "start_point": {"row": 28, "column": 3}, "end_point": {"row": 28, "column": 40}}, {"id": 58, "type": "field_expression", "text": "params.add", "parent": 57, "children": [59, 60], "start_point": {"row": 28, "column": 3}, "end_point": {"row": 28, "column": 13}}, {"id": 59, "type": "identifier", "text": "params", "parent": 58, "children": [], "start_point": {"row": 28, "column": 3}, "end_point": {"row": 28, "column": 9}}, {"id": 60, "type": "field_identifier", "text": "add", "parent": 58, "children": [], "start_point": {"row": 28, "column": 10}, "end_point": {"row": 28, "column": 13}}, {"id": 61, "type": "argument_list", "text": "(speed.set(\"speed\",2,1,40))", "parent": 57, "children": [62], "start_point": {"row": 28, "column": 13}, "end_point": {"row": 28, "column": 40}}, {"id": 62, "type": "call_expression", "text": "speed.set(\"speed\",2,1,40)", "parent": 61, "children": [63, 66], "start_point": {"row": 28, "column": 14}, "end_point": {"row": 28, "column": 39}}, {"id": 63, "type": "field_expression", "text": "speed.set", "parent": 62, "children": [64, 65], "start_point": {"row": 28, "column": 14}, "end_point": {"row": 28, "column": 23}}, {"id": 64, "type": "identifier", "text": "speed", "parent": 63, "children": [], "start_point": {"row": 28, "column": 14}, "end_point": {"row": 28, "column": 19}}, {"id": 65, "type": "field_identifier", "text": "set", "parent": 63, "children": [], "start_point": {"row": 28, "column": 20}, "end_point": {"row": 28, "column": 23}}, {"id": 66, "type": "argument_list", "text": "(\"speed\",2,1,40)", "parent": 62, "children": [67, 68, 69, 70], "start_point": {"row": 28, "column": 23}, "end_point": {"row": 28, "column": 39}}, {"id": 67, "type": "string_literal", "text": "\"speed\"", "parent": 66, "children": [], "start_point": {"row": 28, "column": 24}, "end_point": {"row": 28, "column": 31}}, {"id": 68, "type": "number_literal", "text": "2", "parent": 66, "children": [], "start_point": {"row": 28, "column": 32}, "end_point": {"row": 28, "column": 33}}, {"id": 69, "type": "number_literal", "text": "1", "parent": 66, "children": [], "start_point": {"row": 28, "column": 34}, "end_point": {"row": 28, "column": 35}}, {"id": 70, "type": "number_literal", "text": "40", "parent": 66, "children": [], "start_point": {"row": 28, "column": 36}, "end_point": {"row": 28, "column": 38}}, {"id": 71, "type": "call_expression", "text": "params.add(acceleration.set(\"acceleration\",1,0.01,10))", "parent": 27, "children": [72, 75], "start_point": {"row": 29, "column": 3}, "end_point": {"row": 29, "column": 57}}, {"id": 72, "type": "field_expression", "text": "params.add", "parent": 71, "children": [73, 74], "start_point": {"row": 29, "column": 3}, "end_point": {"row": 29, "column": 13}}, {"id": 73, "type": "identifier", "text": "params", "parent": 72, "children": [], "start_point": {"row": 29, "column": 3}, "end_point": {"row": 29, "column": 9}}, {"id": 74, "type": "field_identifier", "text": "add", "parent": 72, "children": [], "start_point": {"row": 29, "column": 10}, "end_point": {"row": 29, "column": 13}}, {"id": 75, "type": "argument_list", "text": "(acceleration.set(\"acceleration\",1,0.01,10))", "parent": 71, "children": [76], "start_point": {"row": 29, "column": 13}, "end_point": {"row": 29, "column": 57}}, {"id": 76, "type": "call_expression", "text": "acceleration.set(\"acceleration\",1,0.01,10)", "parent": 75, "children": [77, 80], "start_point": {"row": 29, "column": 14}, "end_point": {"row": 29, "column": 56}}, {"id": 77, "type": "field_expression", "text": "acceleration.set", "parent": 76, "children": [78, 79], "start_point": {"row": 29, "column": 14}, "end_point": {"row": 29, "column": 30}}, {"id": 78, "type": "identifier", "text": "acceleration", "parent": 77, "children": [], "start_point": {"row": 29, "column": 14}, "end_point": {"row": 29, "column": 26}}, {"id": 79, "type": "field_identifier", "text": "set", "parent": 77, "children": [], "start_point": {"row": 29, "column": 27}, "end_point": {"row": 29, "column": 30}}, {"id": 80, "type": "argument_list", "text": "(\"acceleration\",1,0.01,10)", "parent": 76, "children": [81, 82, 83, 84], "start_point": {"row": 29, "column": 30}, "end_point": {"row": 29, "column": 56}}, {"id": 81, "type": "string_literal", "text": "\"acceleration\"", "parent": 80, "children": [], "start_point": {"row": 29, "column": 31}, "end_point": {"row": 29, "column": 45}}, {"id": 82, "type": "number_literal", "text": "1", "parent": 80, "children": [], "start_point": {"row": 29, "column": 46}, "end_point": {"row": 29, "column": 47}}, {"id": 83, "type": "number_literal", "text": "0.01", "parent": 80, "children": [], "start_point": {"row": 29, "column": 48}, "end_point": {"row": 29, "column": 52}}, {"id": 84, "type": "number_literal", "text": "10", "parent": 80, "children": [], "start_point": {"row": 29, "column": 53}, "end_point": {"row": 29, "column": 55}}, {"id": 85, "type": "call_expression", "text": "params.add(cornerThreshold.set(\"corner threshold\",90,0,180))", "parent": 27, "children": [86, 89], "start_point": {"row": 30, "column": 3}, "end_point": {"row": 30, "column": 63}}, {"id": 86, "type": "field_expression", "text": "params.add", "parent": 85, "children": [87, 88], "start_point": {"row": 30, "column": 3}, "end_point": {"row": 30, "column": 13}}, {"id": 87, "type": "identifier", "text": "params", "parent": 86, "children": [], "start_point": {"row": 30, "column": 3}, "end_point": {"row": 30, "column": 9}}, {"id": 88, "type": "field_identifier", "text": "add", "parent": 86, "children": [], "start_point": {"row": 30, "column": 10}, "end_point": {"row": 30, "column": 13}}, {"id": 89, "type": "argument_list", "text": "(cornerThreshold.set(\"corner threshold\",90,0,180))", "parent": 85, "children": [90], "start_point": {"row": 30, "column": 13}, "end_point": {"row": 30, "column": 63}}, {"id": 90, "type": "call_expression", "text": "cornerThreshold.set(\"corner threshold\",90,0,180)", "parent": 89, "children": [91, 94], "start_point": {"row": 30, "column": 14}, "end_point": {"row": 30, "column": 62}}, {"id": 91, "type": "field_expression", "text": "cornerThreshold.set", "parent": 90, "children": [92, 93], "start_point": {"row": 30, "column": 14}, "end_point": {"row": 30, "column": 33}}, {"id": 92, "type": "identifier", "text": "cornerThreshold", "parent": 91, "children": [], "start_point": {"row": 30, "column": 14}, "end_point": {"row": 30, "column": 29}}, {"id": 93, "type": "field_identifier", "text": "set", "parent": 91, "children": [], "start_point": {"row": 30, "column": 30}, "end_point": {"row": 30, "column": 33}}, {"id": 94, "type": "argument_list", "text": "(\"corner threshold\",90,0,180)", "parent": 90, "children": [95, 96, 97, 98], "start_point": {"row": 30, "column": 33}, "end_point": {"row": 30, "column": 62}}, {"id": 95, "type": "string_literal", "text": "\"corner threshold\"", "parent": 94, "children": [], "start_point": {"row": 30, "column": 34}, "end_point": {"row": 30, "column": 52}}, {"id": 96, "type": "number_literal", "text": "90", "parent": 94, "children": [], "start_point": {"row": 30, "column": 53}, "end_point": {"row": 30, "column": 55}}, {"id": 97, "type": "number_literal", "text": "0", "parent": 94, "children": [], "start_point": {"row": 30, "column": 56}, "end_point": {"row": 30, "column": 57}}, {"id": 98, "type": "number_literal", "text": "180", "parent": 94, "children": [], "start_point": {"row": 30, "column": 58}, "end_point": {"row": 30, "column": 61}}, {"id": 99, "type": "call_expression", "text": "params.add(dotMaxPoints.set(\"dot max points\", 2, 0, 100))", "parent": 27, "children": [100, 103], "start_point": {"row": 31, "column": 3}, "end_point": {"row": 31, "column": 60}}, {"id": 100, "type": "field_expression", "text": "params.add", "parent": 99, "children": [101, 102], "start_point": {"row": 31, "column": 3}, "end_point": {"row": 31, "column": 13}}, {"id": 101, "type": "identifier", "text": "params", "parent": 100, "children": [], "start_point": {"row": 31, "column": 3}, "end_point": {"row": 31, "column": 9}}, {"id": 102, "type": "field_identifier", "text": "add", "parent": 100, "children": [], "start_point": {"row": 31, "column": 10}, "end_point": {"row": 31, "column": 13}}, {"id": 103, "type": "argument_list", "text": "(dotMaxPoints.set(\"dot max points\", 2, 0, 100))", "parent": 99, "children": [104], "start_point": {"row": 31, "column": 13}, "end_point": {"row": 31, "column": 60}}, {"id": 104, "type": "call_expression", "text": "dotMaxPoints.set(\"dot max points\", 2, 0, 100)", "parent": 103, "children": [105, 108], "start_point": {"row": 31, "column": 14}, "end_point": {"row": 31, "column": 59}}, {"id": 105, "type": "field_expression", "text": "dotMaxPoints.set", "parent": 104, "children": [106, 107], "start_point": {"row": 31, "column": 14}, "end_point": {"row": 31, "column": 30}}, {"id": 106, "type": "identifier", "text": "dotMaxPoints", "parent": 105, "children": [], "start_point": {"row": 31, "column": 14}, "end_point": {"row": 31, "column": 26}}, {"id": 107, "type": "field_identifier", "text": "set", "parent": 105, "children": [], "start_point": {"row": 31, "column": 27}, "end_point": {"row": 31, "column": 30}}, {"id": 108, "type": "argument_list", "text": "(\"dot max points\", 2, 0, 100)", "parent": 104, "children": [109, 110, 111, 112], "start_point": {"row": 31, "column": 30}, "end_point": {"row": 31, "column": 59}}, {"id": 109, "type": "string_literal", "text": "\"dot max points\"", "parent": 108, "children": [], "start_point": {"row": 31, "column": 31}, "end_point": {"row": 31, "column": 47}}, {"id": 110, "type": "number_literal", "text": "2", "parent": 108, "children": [], "start_point": {"row": 31, "column": 49}, "end_point": {"row": 31, "column": 50}}, {"id": 111, "type": "number_literal", "text": "0", "parent": 108, "children": [], "start_point": {"row": 31, "column": 52}, "end_point": {"row": 31, "column": 53}}, {"id": 112, "type": "number_literal", "text": "100", "parent": 108, "children": [], "start_point": {"row": 31, "column": 55}, "end_point": {"row": 31, "column": 58}}, {"id": 113, "type": "function_definition", "text": "void setLabel(string _label) {\n label = _label;\n params.setName(label);\n }", "parent": 6, "children": [114, 115], "start_point": {"row": 34, "column": 8}, "end_point": {"row": 37, "column": 9}}, {"id": 114, "type": "primitive_type", "text": "void", "parent": 113, "children": [], "start_point": {"row": 34, "column": 8}, "end_point": {"row": 34, "column": 12}}, {"id": 115, "type": "function_declarator", "text": "setLabel(string _label)", "parent": 113, "children": [116, 117], "start_point": {"row": 34, "column": 13}, "end_point": {"row": 34, "column": 36}}, {"id": 116, "type": "identifier", "text": "setLabel", "parent": 115, "children": [], "start_point": {"row": 34, "column": 13}, "end_point": {"row": 34, "column": 21}}, {"id": 117, "type": "parameter_list", "text": "(string _label)", "parent": 115, "children": [118], "start_point": {"row": 34, "column": 21}, "end_point": {"row": 34, "column": 36}}, {"id": 118, "type": "parameter_declaration", "text": "string _label", "parent": 117, "children": [119, 120], "start_point": {"row": 34, "column": 22}, "end_point": {"row": 34, "column": 35}}, {"id": 119, "type": "type_identifier", "text": "string", "parent": 118, "children": [], "start_point": {"row": 34, "column": 22}, "end_point": {"row": 34, "column": 28}}, {"id": 120, "type": "identifier", "text": "_label", "parent": 118, "children": [], "start_point": {"row": 34, "column": 29}, "end_point": {"row": 34, "column": 35}}, {"id": 121, "type": "assignment_expression", "text": "label = _label", "parent": 113, "children": [122, 123, 124], "start_point": {"row": 35, "column": 12}, "end_point": {"row": 35, "column": 26}}, {"id": 122, "type": "identifier", "text": "label", "parent": 121, "children": [], "start_point": {"row": 35, "column": 12}, "end_point": {"row": 35, "column": 17}}, {"id": 123, "type": "=", "text": "=", "parent": 121, "children": [], "start_point": {"row": 35, "column": 18}, "end_point": {"row": 35, "column": 19}}, {"id": 124, "type": "identifier", "text": "_label", "parent": 121, "children": [], "start_point": {"row": 35, "column": 20}, "end_point": {"row": 35, "column": 26}}, {"id": 125, "type": "call_expression", "text": "params.setName(label)", "parent": 113, "children": [126, 129], "start_point": {"row": 36, "column": 12}, "end_point": {"row": 36, "column": 33}}, {"id": 126, "type": "field_expression", "text": "params.setName", "parent": 125, "children": [127, 128], "start_point": {"row": 36, "column": 12}, "end_point": {"row": 36, "column": 26}}, {"id": 127, "type": "identifier", "text": "params", "parent": 126, "children": [], "start_point": {"row": 36, "column": 12}, "end_point": {"row": 36, "column": 18}}, {"id": 128, "type": "field_identifier", "text": "setName", "parent": 126, "children": [], "start_point": {"row": 36, "column": 19}, "end_point": {"row": 36, "column": 26}}, {"id": 129, "type": "argument_list", "text": "(label)", "parent": 125, "children": [130], "start_point": {"row": 36, "column": 26}, "end_point": {"row": 36, "column": 33}}, {"id": 130, "type": "identifier", "text": "label", "parent": 129, "children": [], "start_point": {"row": 36, "column": 27}, "end_point": {"row": 36, "column": 32}}, {"id": 131, "type": "binary_expression", "text": "ofParameter<float> speed", "parent": 6, "children": [132, 136, 137], "start_point": {"row": 40, "column": 2}, "end_point": {"row": 40, "column": 26}}, {"id": 132, "type": "binary_expression", "text": "ofParameter<float", "parent": 131, "children": [133, 134, 135], "start_point": {"row": 40, "column": 2}, "end_point": {"row": 40, "column": 19}}, {"id": 133, "type": "identifier", "text": "ofParameter", "parent": 132, "children": [], "start_point": {"row": 40, "column": 2}, "end_point": {"row": 40, "column": 13}}, {"id": 134, "type": "<", "text": "<", "parent": 132, "children": [], "start_point": {"row": 40, "column": 13}, "end_point": {"row": 40, "column": 14}}, {"id": 135, "type": "identifier", "text": "float", "parent": 132, "children": [], "start_point": {"row": 40, "column": 14}, "end_point": {"row": 40, "column": 19}}, {"id": 136, "type": ">", "text": ">", "parent": 131, "children": [], "start_point": {"row": 40, "column": 19}, "end_point": {"row": 40, "column": 20}}, {"id": 137, "type": "identifier", "text": "speed", "parent": 131, "children": [], "start_point": {"row": 40, "column": 21}, "end_point": {"row": 40, "column": 26}}, {"id": 138, "type": "binary_expression", "text": "ofParameter<float> acceleration", "parent": 6, "children": [139, 143, 144], "start_point": {"row": 41, "column": 2}, "end_point": {"row": 41, "column": 33}}, {"id": 139, "type": "binary_expression", "text": "ofParameter<float", "parent": 138, "children": [140, 141, 142], "start_point": {"row": 41, "column": 2}, "end_point": {"row": 41, "column": 19}}, {"id": 140, "type": "identifier", "text": "ofParameter", "parent": 139, "children": [], "start_point": {"row": 41, "column": 2}, "end_point": {"row": 41, "column": 13}}, {"id": 141, "type": "<", "text": "<", "parent": 139, "children": [], "start_point": {"row": 41, "column": 13}, "end_point": {"row": 41, "column": 14}}, {"id": 142, "type": "identifier", "text": "float", "parent": 139, "children": [], "start_point": {"row": 41, "column": 14}, "end_point": {"row": 41, "column": 19}}, {"id": 143, "type": ">", "text": ">", "parent": 138, "children": [], "start_point": {"row": 41, "column": 19}, "end_point": {"row": 41, "column": 20}}, {"id": 144, "type": "identifier", "text": "acceleration", "parent": 138, "children": [], "start_point": {"row": 41, "column": 21}, "end_point": {"row": 41, "column": 33}}, {"id": 145, "type": "binary_expression", "text": "ofParameter<float> cornerThreshold", "parent": 6, "children": [146, 150, 151], "start_point": {"row": 42, "column": 2}, "end_point": {"row": 42, "column": 36}}, {"id": 146, "type": "binary_expression", "text": "ofParameter<float", "parent": 145, "children": [147, 148, 149], "start_point": {"row": 42, "column": 2}, "end_point": {"row": 42, "column": 19}}, {"id": 147, "type": "identifier", "text": "ofParameter", "parent": 146, "children": [], "start_point": {"row": 42, "column": 2}, "end_point": {"row": 42, "column": 13}}, {"id": 148, "type": "<", "text": "<", "parent": 146, "children": [], "start_point": {"row": 42, "column": 13}, "end_point": {"row": 42, "column": 14}}, {"id": 149, "type": "identifier", "text": "float", "parent": 146, "children": [], "start_point": {"row": 42, "column": 14}, "end_point": {"row": 42, "column": 19}}, {"id": 150, "type": ">", "text": ">", "parent": 145, "children": [], "start_point": {"row": 42, "column": 19}, "end_point": {"row": 42, "column": 20}}, {"id": 151, "type": "identifier", "text": "cornerThreshold", "parent": 145, "children": [], "start_point": {"row": 42, "column": 21}, "end_point": {"row": 42, "column": 36}}, {"id": 152, "type": "binary_expression", "text": "ofParameter<int> dotMaxPoints", "parent": 6, "children": [153, 157, 158], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 43, "column": 31}}, {"id": 153, "type": "binary_expression", "text": "ofParameter<int", "parent": 152, "children": [154, 155, 156], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 43, "column": 17}}, {"id": 154, "type": "identifier", "text": "ofParameter", "parent": 153, "children": [], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 43, "column": 13}}, {"id": 155, "type": "<", "text": "<", "parent": 153, "children": [], "start_point": {"row": 43, "column": 13}, "end_point": {"row": 43, "column": 14}}, {"id": 156, "type": "identifier", "text": "int", "parent": 153, "children": [], "start_point": {"row": 43, "column": 14}, "end_point": {"row": 43, "column": 17}}, {"id": 157, "type": ">", "text": ">", "parent": 152, "children": [], "start_point": {"row": 43, "column": 17}, "end_point": {"row": 43, "column": 18}}, {"id": 158, "type": "identifier", "text": "dotMaxPoints", "parent": 152, "children": [], "start_point": {"row": 43, "column": 19}, "end_point": {"row": 43, "column": 31}}, {"id": 159, "type": "declaration", "text": "ofParameterGroup params;", "parent": 6, "children": [160, 161], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 26}}, {"id": 160, "type": "type_identifier", "text": "ofParameterGroup", "parent": 159, "children": [], "start_point": {"row": 45, "column": 2}, "end_point": {"row": 45, "column": 18}}, {"id": 161, "type": "identifier", "text": "params", "parent": 159, "children": [], "start_point": {"row": 45, "column": 19}, "end_point": {"row": 45, "column": 25}}, {"id": 162, "type": "labeled_statement", "text": "private :\n string label;", "parent": 6, "children": [163], "start_point": {"row": 46, "column": 8}, "end_point": {"row": 47, "column": 21}}, {"id": 163, "type": "declaration", "text": "string label;", "parent": 162, "children": [164, 165], "start_point": {"row": 47, "column": 8}, "end_point": {"row": 47, "column": 21}}, {"id": 164, "type": "type_identifier", "text": "string", "parent": 163, "children": [], "start_point": {"row": 47, "column": 8}, "end_point": {"row": 47, "column": 14}}, {"id": 165, "type": "identifier", "text": "label", "parent": 163, "children": [], "start_point": {"row": 47, "column": 15}, "end_point": {"row": 47, "column": 20}}]}, "node_categories": {"declarations": {"functions": [6, 9, 27, 29, 113, 115], "variables": [12, 32, 118, 159, 163], "classes": [], "imports": [3, 4], "modules": [], "enums": []}, "statements": {"expressions": [23, 51, 52, 57, 58, 62, 63, 71, 72, 76, 77, 85, 86, 90, 91, 99, 100, 104, 105, 125, 126, 131, 132, 138, 139, 145, 146, 152, 153], "assignments": [35, 39, 43, 47, 121], "loops": [], "conditionals": [7, 8, 10, 13, 14, 16, 18, 24, 26, 30, 33, 34, 36, 38, 40, 44, 48, 53, 54, 56, 59, 60, 64, 65, 73, 74, 78, 79, 87, 88, 92, 93, 101, 102, 106, 107, 116, 119, 120, 122, 124, 127, 128, 130, 133, 135, 137, 140, 142, 144, 147, 149, 151, 154, 156, 158, 160, 161, 164, 165], "returns": [], "exceptions": []}, "expressions": {"calls": [0], "literals": [5, 21, 42, 46, 50, 67, 68, 69, 70, 81, 82, 83, 84, 95, 96, 97, 98, 109, 110, 111, 112], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 6, "universal_type": "function", "name": "RenderProfile", "text_snippet": "namespace ofxLaser {\n\n\tclass RenderProfile {\n\t\tpublic :\n\t\tRenderProfile(string _label = \"\") {\n\t\t\t\n\t\t"}, {"node_id": 9, "universal_type": "function", "name": "RenderProfile", "text_snippet": "class RenderProfile {\n\t\tpublic :\n\t\tRenderProfile(string _label = \"\") {\n\t\t\t\n\t\t\t//ofLogNotice(\"RenderP"}, {"node_id": 27, "universal_type": "function", "name": "init", "text_snippet": "void init(string _label) {\n\t\t\t\n label = _label;\n\t\t\tspeed = 2;\n\t\t\tacceleration = 4;\n\t\t\tcor"}, {"node_id": 29, "universal_type": "function", "name": "unknown", "text_snippet": "init(string _label)"}, {"node_id": 113, "universal_type": "function", "name": "setLabel", "text_snippet": "void setLabel(string _label) {\n label = _label;\n params.setName(label);\n "}, {"node_id": 115, "universal_type": "function", "name": "unknown", "text_snippet": "setLabel(string _label)"}], "class_declarations": [], "import_statements": [{"node_id": 3, "text": "#include \"ofMain.h\"\n"}, {"node_id": 4, "text": "#include"}]}, "original_source_code": "//\n// ofxLaserRenderProfile.hpp\n// ofxLaser\n//\n// Created by <NAME> on 13/11/2017.\n//\n//\n#pragma once\n#include \"ofMain.h\"\n\nnamespace ofxLaser {\n\n\tclass RenderProfile {\n\t\tpublic :\n\t\tRenderProfile(string _label = \"\") {\n\t\t\t\n\t\t\t//ofLogNotice(\"RenderProfile default constructor called \"+_label);\n init(_label);\n\t\t}\n\t\t\n\t\tvoid init(string _label) {\n\t\t\t\n label = _label;\n\t\t\tspeed = 2;\n\t\t\tacceleration = 4;\n\t\t\tcornerThreshold = 125;\n\t\t\t\n\t\t\tparams.setName(label);\n\t\t\tparams.add(speed.set(\"speed\",2,1,40));\n\t\t\tparams.add(acceleration.set(\"acceleration\",1,0.01,10));\n\t\t\tparams.add(cornerThreshold.set(\"corner threshold\",90,0,180));\n\t\t\tparams.add(dotMaxPoints.set(\"dot max points\", 2, 0, 100));\n\t\t\t\n\t\t}\n void setLabel(string _label) {\n label = _label;\n params.setName(label);\n } \n\t\t\n \n\t\tofParameter<float> speed;\n\t\tofParameter<float> acceleration;\n\t\tofParameter<float> cornerThreshold;\n\t\tofParameter<int> dotMaxPoints;\n\t\t\n\t\tofParameterGroup params;\n private :\n string label;\n\n\t};\n\n}\n"}
80,587
c
// Copyright 2016-present 650 Industries. All rights reserved. #import <EXGL_CPP/UEXGL.h> #import <ABI39_0_0EXGL/ABI39_0_0EXGLContext.h> #import <ABI39_0_0UMCore/ABI39_0_0UMModuleRegistry.h> NS_ASSUME_NONNULL_BEGIN @interface ABI39_0_0EXGLView : UIView <ABI39_0_0EXGLContextDelegate> - (instancetype)initWithModuleRegistry:(ABI39_0_0UMModuleRegistry *)moduleRegistry; - (UEXGLContextId)exglCtxId; // AR - (void)setArSessionManager:(id)arSessionManager; - (void)maybeStopARSession; @property (nonatomic, copy, nullable) ABI39_0_0UMDirectEventBlock onSurfaceCreate; @property (nonatomic, assign) NSNumber *msaaSamples; // "protected" @property (nonatomic, strong, nullable) ABI39_0_0EXGLContext *glContext; @property (nonatomic, strong, nullable) EAGLContext *uiEaglCtx; @end NS_ASSUME_NONNULL_END
43.22
18
(translation_unit) "// Copyright 2016-present 650 Industries. All rights reserved.\n\n#import <EXGL_CPP/UEXGL.h>\n#import <ABI39_0_0EXGL/ABI39_0_0EXGLContext.h>\n#import <ABI39_0_0UMCore/ABI39_0_0UMModuleRegistry.h>\n\nNS_ASSUME_NONNULL_BEGIN\n\n@interface ABI39_0_0EXGLView : UIView <ABI39_0_0EXGLContextDelegate>\n\n- (instancetype)initWithModuleRegistry:(ABI39_0_0UMModuleRegistry *)moduleRegistry;\n- (UEXGLContextId)exglCtxId;\n\n// AR\n- (void)setArSessionManager:(id)arSessionManager;\n- (void)maybeStopARSession;\n\n@property (nonatomic, copy, nullable) ABI39_0_0UMDirectEventBlock onSurfaceCreate;\n@property (nonatomic, assign) NSNumber *msaaSamples;\n\n// "protected"\n@property (nonatomic, strong, nullable) ABI39_0_0EXGLContext *glContext;\n@property (nonatomic, strong, nullable) EAGLContext *uiEaglCtx;\n\n@end\n\nNS_ASSUME_NONNULL_END\n" (comment) "// Copyright 2016-present 650 Industries. All rights reserved." (preproc_call) "#import <EXGL_CPP/UEXGL.h>\n" (preproc_directive) "#import" (preproc_arg) "<EXGL_CPP/UEXGL.h>" (preproc_call) "#import <ABI39_0_0EXGL/ABI39_0_0EXGLContext.h>\n" (preproc_directive) "#import" (preproc_arg) "<ABI39_0_0EXGL/ABI39_0_0EXGLContext.h>" (preproc_call) "#import <ABI39_0_0UMCore/ABI39_0_0UMModuleRegistry.h>\n" (preproc_directive) "#import" (preproc_arg) "<ABI39_0_0UMCore/ABI39_0_0UMModuleRegistry.h>" (declaration) "NS_ASSUME_NONNULL_BEGIN\n\n@interface" (type_identifier) "NS_ASSUME_NONNULL_BEGIN" (ERROR) "@" (ERROR) "@" (identifier) "interface" (;) "" (labeled_statement) "ABI39_0_0EXGLView : UIView <ABI39_0_0EXGLContextDelegate>\n\n- (instancetype)initWithModuleRegistry:(ABI39_0_0UMModuleRegistry *)moduleRegistry;" (statement_identifier) "ABI39_0_0EXGLView" (ERROR) ": UIView <ABI39_0_0EXGLContextDelegate>\n\n- (instancetype)initWithModuleRegistry" (:) ":" (binary_expression) "UIView <ABI39_0_0EXGLContextDelegate>\n\n- (instancetype)initWithModuleRegistry" (binary_expression) "UIView <ABI39_0_0EXGLContextDelegate" (identifier) "UIView" (<) "<" (identifier) "ABI39_0_0EXGLContextDelegate" (>) ">" (unary_expression) "- (instancetype)initWithModuleRegistry" (-) "-" (cast_expression) "(instancetype)initWithModuleRegistry" (() "(" (type_descriptor) "instancetype" (type_identifier) "instancetype" ()) ")" (identifier) "initWithModuleRegistry" (:) ":" (expression_statement) "(ABI39_0_0UMModuleRegistry *)moduleRegistry;" (cast_expression) "(ABI39_0_0UMModuleRegistry *)moduleRegistry" (() "(" (type_descriptor) "ABI39_0_0UMModuleRegistry *" (type_identifier) "ABI39_0_0UMModuleRegistry" (abstract_pointer_declarator) "*" (*) "*" ()) ")" (identifier) "moduleRegistry" (;) ";" (expression_statement) "- (UEXGLContextId)exglCtxId;" (unary_expression) "- (UEXGLContextId)exglCtxId" (-) "-" (cast_expression) "(UEXGLContextId)exglCtxId" (() "(" (type_descriptor) "UEXGLContextId" (type_identifier) "UEXGLContextId" ()) ")" (identifier) "exglCtxId" (;) ";" (comment) "// AR" (expression_statement) "- (void)setArSessionManager:(id)arSessionManager;" (unary_expression) "- (void)setArSessionManager" (-) "-" (cast_expression) "(void)setArSessionManager" (() "(" (type_descriptor) "void" (primitive_type) "void" ()) ")" (identifier) "setArSessionManager" (ERROR) ":(id)arSessionManager" (:) ":" (() "(" (identifier) "id" ()) ")" (identifier) "arSessionManager" (;) ";" (expression_statement) "- (void)maybeStopARSession;" (unary_expression) "- (void)maybeStopARSession" (-) "-" (cast_expression) "(void)maybeStopARSession" (() "(" (type_descriptor) "void" (primitive_type) "void" ()) ")" (identifier) "maybeStopARSession" (;) ";" (ERROR) "@property (nonatomic, copy, nullable) ABI39_0_0UMDirectEventBlock" (ERROR) "@" (call_expression) "property (nonatomic, copy, nullable)" (identifier) "property" (argument_list) "(nonatomic, copy, nullable)" (() "(" (identifier) "nonatomic" (,) "," (identifier) "copy" (,) "," (identifier) "nullable" ()) ")" (identifier) "ABI39_0_0UMDirectEventBlock" (expression_statement) "onSurfaceCreate;" (identifier) "onSurfaceCreate" (;) ";" (ERROR) "@" (ERROR) "@" (expression_statement) "property (nonatomic, assign)" (call_expression) "property (nonatomic, assign)" (identifier) "property" (argument_list) "(nonatomic, assign)" (() "(" (identifier) "nonatomic" (,) "," (identifier) "assign" ()) ")" (;) "" (declaration) "NSNumber *msaaSamples;" (type_identifier) "NSNumber" (pointer_declarator) "*msaaSamples" (*) "*" (identifier) "msaaSamples" (;) ";" (comment) "// "protected"" (ERROR) "@" (ERROR) "@" (expression_statement) "property (nonatomic, strong, nullable)" (call_expression) "property (nonatomic, strong, nullable)" (identifier) "property" (argument_list) "(nonatomic, strong, nullable)" (() "(" (identifier) "nonatomic" (,) "," (identifier) "strong" (,) "," (identifier) "nullable" ()) ")" (;) "" (declaration) "ABI39_0_0EXGLContext *glContext;" (type_identifier) "ABI39_0_0EXGLContext" (pointer_declarator) "*glContext" (*) "*" (identifier) "glContext" (;) ";" (ERROR) "@" (ERROR) "@" (expression_statement) "property (nonatomic, strong, nullable)" (call_expression) "property (nonatomic, strong, nullable)" (identifier) "property" (argument_list) "(nonatomic, strong, nullable)" (() "(" (identifier) "nonatomic" (,) "," (identifier) "strong" (,) "," (identifier) "nullable" ()) ")" (;) "" (declaration) "EAGLContext *uiEaglCtx;" (type_identifier) "EAGLContext" (pointer_declarator) "*uiEaglCtx" (*) "*" (identifier) "uiEaglCtx" (;) ";" (ERROR) "@" (ERROR) "@" (declaration) "end\n\nNS_ASSUME_NONNULL_END" (type_identifier) "end" (identifier) "NS_ASSUME_NONNULL_END" (;) ""
164
14
{"language": "c", "success": true, "metadata": {"lines": 18, "avg_line_length": 43.22, "nodes": 108, "errors": 0, "source_hash": "6af45983f32627d459dfdc9f8472af716ad502a2f52d8ba2eed80960c867260b", "categorized_nodes": 62}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#import <EXGL_CPP/UEXGL.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#import", "parent": 0, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "<EXGL_CPP/UEXGL.h>", "parent": 0, "children": [], "start_point": {"row": 2, "column": 8}, "end_point": {"row": 2, "column": 26}}, {"id": 3, "type": "preproc_call", "text": "#import <ABI39_0_0EXGL/ABI39_0_0EXGLContext.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 4, "type": "preproc_directive", "text": "#import", "parent": 3, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 7}}, {"id": 5, "type": "preproc_arg", "text": "<ABI39_0_0EXGL/ABI39_0_0EXGLContext.h>", "parent": 3, "children": [], "start_point": {"row": 3, "column": 8}, "end_point": {"row": 3, "column": 46}}, {"id": 6, "type": "preproc_call", "text": "#import <ABI39_0_0UMCore/ABI39_0_0UMModuleRegistry.h>\n", "parent": null, "children": [7, 8], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 7, "type": "preproc_directive", "text": "#import", "parent": 6, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 7}}, {"id": 8, "type": "preproc_arg", "text": "<ABI39_0_0UMCore/ABI39_0_0UMModuleRegistry.h>", "parent": 6, "children": [], "start_point": {"row": 4, "column": 8}, "end_point": {"row": 4, "column": 53}}, {"id": 9, "type": "declaration", "text": "NS_ASSUME_NONNULL_BEGIN\n\n@interface", "parent": null, "children": [10, 11, 13], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 8, "column": 10}}, {"id": 10, "type": "type_identifier", "text": "NS_ASSUME_NONNULL_BEGIN", "parent": 9, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 23}}, {"id": 11, "type": "ERROR", "text": "@", "parent": 9, "children": [12], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 1}}, {"id": 12, "type": "ERROR", "text": "@", "parent": 11, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 1}}, {"id": 13, "type": "identifier", "text": "interface", "parent": 9, "children": [], "start_point": {"row": 8, "column": 1}, "end_point": {"row": 8, "column": 10}}, {"id": 14, "type": "labeled_statement", "text": "ABI39_0_0EXGLView : UIView <ABI39_0_0EXGLContextDelegate>\n\n- (instancetype)initWithModuleRegistry:(ABI39_0_0UMModuleRegistry *)moduleRegistry;", "parent": null, "children": [15, 16], "start_point": {"row": 8, "column": 11}, "end_point": {"row": 10, "column": 83}}, {"id": 15, "type": "statement_identifier", "text": "ABI39_0_0EXGLView", "parent": 14, "children": [], "start_point": {"row": 8, "column": 11}, "end_point": {"row": 8, "column": 28}}, {"id": 16, "type": "ERROR", "text": ": UIView <ABI39_0_0EXGLContextDelegate>\n\n- (instancetype)initWithModuleRegistry", "parent": 14, "children": [17], "start_point": {"row": 8, "column": 29}, "end_point": {"row": 10, "column": 38}}, {"id": 17, "type": "binary_expression", "text": "UIView <ABI39_0_0EXGLContextDelegate>\n\n- (instancetype)initWithModuleRegistry", "parent": 16, "children": [18, 22, 23], "start_point": {"row": 8, "column": 31}, "end_point": {"row": 10, "column": 38}}, {"id": 18, "type": "binary_expression", "text": "UIView <ABI39_0_0EXGLContextDelegate", "parent": 17, "children": [19, 20, 21], "start_point": {"row": 8, "column": 31}, "end_point": {"row": 8, "column": 67}}, {"id": 19, "type": "identifier", "text": "UIView", "parent": 18, "children": [], "start_point": {"row": 8, "column": 31}, "end_point": {"row": 8, "column": 37}}, {"id": 20, "type": "<", "text": "<", "parent": 18, "children": [], "start_point": {"row": 8, "column": 38}, "end_point": {"row": 8, "column": 39}}, {"id": 21, "type": "identifier", "text": "ABI39_0_0EXGLContextDelegate", "parent": 18, "children": [], "start_point": {"row": 8, "column": 39}, "end_point": {"row": 8, "column": 67}}, {"id": 22, "type": ">", "text": ">", "parent": 17, "children": [], "start_point": {"row": 8, "column": 67}, "end_point": {"row": 8, "column": 68}}, {"id": 23, "type": "unary_expression", "text": "- (instancetype)initWithModuleRegistry", "parent": 17, "children": [24, 25], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 38}}, {"id": 24, "type": "-", "text": "-", "parent": 23, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 1}}, {"id": 25, "type": "cast_expression", "text": "(instancetype)initWithModuleRegistry", "parent": 23, "children": [26, 28], "start_point": {"row": 10, "column": 2}, "end_point": {"row": 10, "column": 38}}, {"id": 26, "type": "type_descriptor", "text": "instancetype", "parent": 25, "children": [27], "start_point": {"row": 10, "column": 3}, "end_point": {"row": 10, "column": 15}}, {"id": 27, "type": "type_identifier", "text": "instancetype", "parent": 26, "children": [], "start_point": {"row": 10, "column": 3}, "end_point": {"row": 10, "column": 15}}, {"id": 28, "type": "identifier", "text": "initWithModuleRegistry", "parent": 25, "children": [], "start_point": {"row": 10, "column": 16}, "end_point": {"row": 10, "column": 38}}, {"id": 29, "type": "cast_expression", "text": "(ABI39_0_0UMModuleRegistry *)moduleRegistry", "parent": 14, "children": [30, 34], "start_point": {"row": 10, "column": 39}, "end_point": {"row": 10, "column": 82}}, {"id": 30, "type": "type_descriptor", "text": "ABI39_0_0UMModuleRegistry *", "parent": 29, "children": [31, 32], "start_point": {"row": 10, "column": 40}, "end_point": {"row": 10, "column": 67}}, {"id": 31, "type": "type_identifier", "text": "ABI39_0_0UMModuleRegistry", "parent": 30, "children": [], "start_point": {"row": 10, "column": 40}, "end_point": {"row": 10, "column": 65}}, {"id": 32, "type": "abstract_pointer_declarator", "text": "*", "parent": 30, "children": [33], "start_point": {"row": 10, "column": 66}, "end_point": {"row": 10, "column": 67}}, {"id": 33, "type": "*", "text": "*", "parent": 32, "children": [], "start_point": {"row": 10, "column": 66}, "end_point": {"row": 10, "column": 67}}, {"id": 34, "type": "identifier", "text": "moduleRegistry", "parent": 29, "children": [], "start_point": {"row": 10, "column": 68}, "end_point": {"row": 10, "column": 82}}, {"id": 35, "type": "unary_expression", "text": "- (UEXGLContextId)exglCtxId", "parent": null, "children": [36, 37], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 27}}, {"id": 36, "type": "-", "text": "-", "parent": 35, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 1}}, {"id": 37, "type": "cast_expression", "text": "(UEXGLContextId)exglCtxId", "parent": 35, "children": [38, 40], "start_point": {"row": 11, "column": 2}, "end_point": {"row": 11, "column": 27}}, {"id": 38, "type": "type_descriptor", "text": "UEXGLContextId", "parent": 37, "children": [39], "start_point": {"row": 11, "column": 3}, "end_point": {"row": 11, "column": 17}}, {"id": 39, "type": "type_identifier", "text": "UEXGLContextId", "parent": 38, "children": [], "start_point": {"row": 11, "column": 3}, "end_point": {"row": 11, "column": 17}}, {"id": 40, "type": "identifier", "text": "exglCtxId", "parent": 37, "children": [], "start_point": {"row": 11, "column": 18}, "end_point": {"row": 11, "column": 27}}, {"id": 41, "type": "unary_expression", "text": "- (void)setArSessionManager", "parent": null, "children": [42, 43], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 27}}, {"id": 42, "type": "-", "text": "-", "parent": 41, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 1}}, {"id": 43, "type": "cast_expression", "text": "(void)setArSessionManager", "parent": 41, "children": [44, 46], "start_point": {"row": 14, "column": 2}, "end_point": {"row": 14, "column": 27}}, {"id": 44, "type": "type_descriptor", "text": "void", "parent": 43, "children": [45], "start_point": {"row": 14, "column": 3}, "end_point": {"row": 14, "column": 7}}, {"id": 45, "type": "primitive_type", "text": "void", "parent": 44, "children": [], "start_point": {"row": 14, "column": 3}, "end_point": {"row": 14, "column": 7}}, {"id": 46, "type": "identifier", "text": "setArSessionManager", "parent": 43, "children": [], "start_point": {"row": 14, "column": 8}, "end_point": {"row": 14, "column": 27}}, {"id": 47, "type": "ERROR", "text": ":(id)arSessionManager", "parent": null, "children": [48, 49], "start_point": {"row": 14, "column": 27}, "end_point": {"row": 14, "column": 48}}, {"id": 48, "type": "identifier", "text": "id", "parent": 47, "children": [], "start_point": {"row": 14, "column": 29}, "end_point": {"row": 14, "column": 31}}, {"id": 49, "type": "identifier", "text": "arSessionManager", "parent": 47, "children": [], "start_point": {"row": 14, "column": 32}, "end_point": {"row": 14, "column": 48}}, {"id": 50, "type": "unary_expression", "text": "- (void)maybeStopARSession", "parent": null, "children": [51, 52], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 26}}, {"id": 51, "type": "-", "text": "-", "parent": 50, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 1}}, {"id": 52, "type": "cast_expression", "text": "(void)maybeStopARSession", "parent": 50, "children": [53, 55], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 26}}, {"id": 53, "type": "type_descriptor", "text": "void", "parent": 52, "children": [54], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 7}}, {"id": 54, "type": "primitive_type", "text": "void", "parent": 53, "children": [], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 7}}, {"id": 55, "type": "identifier", "text": "maybeStopARSession", "parent": 52, "children": [], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 26}}, {"id": 56, "type": "ERROR", "text": "@property (nonatomic, copy, nullable) ABI39_0_0UMDirectEventBlock", "parent": null, "children": [57, 58, 64], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 65}}, {"id": 57, "type": "ERROR", "text": "@", "parent": 56, "children": [], "start_point": {"row": 17, "column": 0}, "end_point": {"row": 17, "column": 1}}, {"id": 58, "type": "call_expression", "text": "property (nonatomic, copy, nullable)", "parent": 56, "children": [59, 60], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 37}}, {"id": 59, "type": "identifier", "text": "property", "parent": 58, "children": [], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 9}}, {"id": 60, "type": "argument_list", "text": "(nonatomic, copy, nullable)", "parent": 58, "children": [61, 62, 63], "start_point": {"row": 17, "column": 10}, "end_point": {"row": 17, "column": 37}}, {"id": 61, "type": "identifier", "text": "nonatomic", "parent": 60, "children": [], "start_point": {"row": 17, "column": 11}, "end_point": {"row": 17, "column": 20}}, {"id": 62, "type": "identifier", "text": "copy", "parent": 60, "children": [], "start_point": {"row": 17, "column": 22}, "end_point": {"row": 17, "column": 26}}, {"id": 63, "type": "identifier", "text": "nullable", "parent": 60, "children": [], "start_point": {"row": 17, "column": 28}, "end_point": {"row": 17, "column": 36}}, {"id": 64, "type": "identifier", "text": "ABI39_0_0UMDirectEventBlock", "parent": 56, "children": [], "start_point": {"row": 17, "column": 38}, "end_point": {"row": 17, "column": 65}}, {"id": 65, "type": "identifier", "text": "onSurfaceCreate", "parent": null, "children": [], "start_point": {"row": 17, "column": 66}, "end_point": {"row": 17, "column": 81}}, {"id": 66, "type": "ERROR", "text": "@", "parent": null, "children": [67], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 1}}, {"id": 67, "type": "ERROR", "text": "@", "parent": 66, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 1}}, {"id": 68, "type": "call_expression", "text": "property (nonatomic, assign)", "parent": null, "children": [69, 70], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 29}}, {"id": 69, "type": "identifier", "text": "property", "parent": 68, "children": [], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 9}}, {"id": 70, "type": "argument_list", "text": "(nonatomic, assign)", "parent": 68, "children": [71, 72], "start_point": {"row": 18, "column": 10}, "end_point": {"row": 18, "column": 29}}, {"id": 71, "type": "identifier", "text": "nonatomic", "parent": 70, "children": [], "start_point": {"row": 18, "column": 11}, "end_point": {"row": 18, "column": 20}}, {"id": 72, "type": "identifier", "text": "assign", "parent": 70, "children": [], "start_point": {"row": 18, "column": 22}, "end_point": {"row": 18, "column": 28}}, {"id": 73, "type": "declaration", "text": "NSNumber *msaaSamples;", "parent": null, "children": [74, 75], "start_point": {"row": 18, "column": 30}, "end_point": {"row": 18, "column": 52}}, {"id": 74, "type": "type_identifier", "text": "NSNumber", "parent": 73, "children": [], "start_point": {"row": 18, "column": 30}, "end_point": {"row": 18, "column": 38}}, {"id": 75, "type": "pointer_declarator", "text": "*msaaSamples", "parent": 73, "children": [76, 77], "start_point": {"row": 18, "column": 39}, "end_point": {"row": 18, "column": 51}}, {"id": 76, "type": "*", "text": "*", "parent": 75, "children": [], "start_point": {"row": 18, "column": 39}, "end_point": {"row": 18, "column": 40}}, {"id": 77, "type": "identifier", "text": "msaaSamples", "parent": 75, "children": [], "start_point": {"row": 18, "column": 40}, "end_point": {"row": 18, "column": 51}}, {"id": 78, "type": "ERROR", "text": "@", "parent": null, "children": [79], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 1}}, {"id": 79, "type": "ERROR", "text": "@", "parent": 78, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 1}}, {"id": 80, "type": "call_expression", "text": "property (nonatomic, strong, nullable)", "parent": null, "children": [81, 82], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 39}}, {"id": 81, "type": "identifier", "text": "property", "parent": 80, "children": [], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 9}}, {"id": 82, "type": "argument_list", "text": "(nonatomic, strong, nullable)", "parent": 80, "children": [83, 84, 85], "start_point": {"row": 21, "column": 10}, "end_point": {"row": 21, "column": 39}}, {"id": 83, "type": "identifier", "text": "nonatomic", "parent": 82, "children": [], "start_point": {"row": 21, "column": 11}, "end_point": {"row": 21, "column": 20}}, {"id": 84, "type": "identifier", "text": "strong", "parent": 82, "children": [], "start_point": {"row": 21, "column": 22}, "end_point": {"row": 21, "column": 28}}, {"id": 85, "type": "identifier", "text": "nullable", "parent": 82, "children": [], "start_point": {"row": 21, "column": 30}, "end_point": {"row": 21, "column": 38}}, {"id": 86, "type": "declaration", "text": "ABI39_0_0EXGLContext *glContext;", "parent": null, "children": [87, 88], "start_point": {"row": 21, "column": 40}, "end_point": {"row": 21, "column": 72}}, {"id": 87, "type": "type_identifier", "text": "ABI39_0_0EXGLContext", "parent": 86, "children": [], "start_point": {"row": 21, "column": 40}, "end_point": {"row": 21, "column": 60}}, {"id": 88, "type": "pointer_declarator", "text": "*glContext", "parent": 86, "children": [89, 90], "start_point": {"row": 21, "column": 61}, "end_point": {"row": 21, "column": 71}}, {"id": 89, "type": "*", "text": "*", "parent": 88, "children": [], "start_point": {"row": 21, "column": 61}, "end_point": {"row": 21, "column": 62}}, {"id": 90, "type": "identifier", "text": "glContext", "parent": 88, "children": [], "start_point": {"row": 21, "column": 62}, "end_point": {"row": 21, "column": 71}}, {"id": 91, "type": "ERROR", "text": "@", "parent": null, "children": [92], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 1}}, {"id": 92, "type": "ERROR", "text": "@", "parent": 91, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 1}}, {"id": 93, "type": "call_expression", "text": "property (nonatomic, strong, nullable)", "parent": null, "children": [94, 95], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 39}}, {"id": 94, "type": "identifier", "text": "property", "parent": 93, "children": [], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 9}}, {"id": 95, "type": "argument_list", "text": "(nonatomic, strong, nullable)", "parent": 93, "children": [96, 97, 98], "start_point": {"row": 22, "column": 10}, "end_point": {"row": 22, "column": 39}}, {"id": 96, "type": "identifier", "text": "nonatomic", "parent": 95, "children": [], "start_point": {"row": 22, "column": 11}, "end_point": {"row": 22, "column": 20}}, {"id": 97, "type": "identifier", "text": "strong", "parent": 95, "children": [], "start_point": {"row": 22, "column": 22}, "end_point": {"row": 22, "column": 28}}, {"id": 98, "type": "identifier", "text": "nullable", "parent": 95, "children": [], "start_point": {"row": 22, "column": 30}, "end_point": {"row": 22, "column": 38}}, {"id": 99, "type": "declaration", "text": "EAGLContext *uiEaglCtx;", "parent": null, "children": [100, 101], "start_point": {"row": 22, "column": 40}, "end_point": {"row": 22, "column": 63}}, {"id": 100, "type": "type_identifier", "text": "EAGLContext", "parent": 99, "children": [], "start_point": {"row": 22, "column": 40}, "end_point": {"row": 22, "column": 51}}, {"id": 101, "type": "pointer_declarator", "text": "*uiEaglCtx", "parent": 99, "children": [102, 103], "start_point": {"row": 22, "column": 52}, "end_point": {"row": 22, "column": 62}}, {"id": 102, "type": "*", "text": "*", "parent": 101, "children": [], "start_point": {"row": 22, "column": 52}, "end_point": {"row": 22, "column": 53}}, {"id": 103, "type": "identifier", "text": "uiEaglCtx", "parent": 101, "children": [], "start_point": {"row": 22, "column": 53}, "end_point": {"row": 22, "column": 62}}, {"id": 104, "type": "ERROR", "text": "@", "parent": null, "children": [105], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 1}}, {"id": 105, "type": "ERROR", "text": "@", "parent": 104, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 1}}, {"id": 106, "type": "declaration", "text": "end\n\nNS_ASSUME_NONNULL_END", "parent": null, "children": [107], "start_point": {"row": 24, "column": 1}, "end_point": {"row": 26, "column": 21}}, {"id": 107, "type": "identifier", "text": "NS_ASSUME_NONNULL_END", "parent": 106, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 21}}]}, "node_categories": {"declarations": {"functions": [], "variables": [9, 73, 86, 99, 106], "classes": [], "imports": [], "modules": [], "enums": []}, "statements": {"expressions": [17, 18, 23, 25, 29, 35, 37, 41, 43, 50, 52, 58, 68, 80, 93], "assignments": [], "loops": [], "conditionals": [10, 13, 15, 19, 21, 27, 28, 31, 34, 39, 40, 46, 48, 49, 55, 59, 61, 62, 63, 64, 65, 69, 71, 72, 74, 77, 81, 83, 84, 85, 87, 90, 94, 96, 97, 98, 100, 103, 107], "returns": [], "exceptions": []}, "expressions": {"calls": [0, 3, 6], "literals": [], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [], "class_declarations": [], "import_statements": []}, "original_source_code": "// Copyright 2016-present 650 Industries. All rights reserved.\n\n#import <EXGL_CPP/UEXGL.h>\n#import <ABI39_0_0EXGL/ABI39_0_0EXGLContext.h>\n#import <ABI39_0_0UMCore/ABI39_0_0UMModuleRegistry.h>\n\nNS_ASSUME_NONNULL_BEGIN\n\n@interface ABI39_0_0EXGLView : UIView <ABI39_0_0EXGLContextDelegate>\n\n- (instancetype)initWithModuleRegistry:(ABI39_0_0UMModuleRegistry *)moduleRegistry;\n- (UEXGLContextId)exglCtxId;\n\n// AR\n- (void)setArSessionManager:(id)arSessionManager;\n- (void)maybeStopARSession;\n\n@property (nonatomic, copy, nullable) ABI39_0_0UMDirectEventBlock onSurfaceCreate;\n@property (nonatomic, assign) NSNumber *msaaSamples;\n\n// \"protected\"\n@property (nonatomic, strong, nullable) ABI39_0_0EXGLContext *glContext;\n@property (nonatomic, strong, nullable) EAGLContext *uiEaglCtx;\n\n@end\n\nNS_ASSUME_NONNULL_END\n"}
80,588
c
#pragma once #include "compiler/compiler_warnings_control.h" DISABLE_COMPILER_WARNINGS #include <QObject> RESTORE_COMPILER_WARNINGS class CController; class CAndroidNativeHelper : public QObject { Q_OBJECT public: explicit CAndroidNativeHelper(CController& controller); ~CAndroidNativeHelper(); CController& controller(); static CAndroidNativeHelper* instance(); private: CController& _controller; static CAndroidNativeHelper* _instance; };
16.89
27
(translation_unit) "#pragma once \n \n#include "compiler/compiler_warnings_control.h" \n \nDISABLE_COMPILER_WARNINGS \n#include <QObject> \nRESTORE_COMPILER_WARNINGS \n \nclass CController; \n \nclass CAndroidNativeHelper : public QObject \n{ \n Q_OBJECT \n \npublic: \n explicit CAndroidNativeHelper(CController& controller); \n ~CAndroidNativeHelper(); \n \n CController& controller(); \n \n static CAndroidNativeHelper* instance(); \n \nprivate: \n CController& _controller; \n \n static CAndroidNativeHelper* _instance; \n}; \n" (preproc_call) "#pragma once \n" (preproc_directive) "#pragma" (preproc_arg) "once " (preproc_include) "#include "compiler/compiler_warnings_control.h" \n" (#include) "#include" (string_literal) ""compiler/compiler_warnings_control.h"" (") """ (string_content) "compiler/compiler_warnings_control.h" (") """ (expression_statement) "DISABLE_COMPILER_WARNINGS" (identifier) "DISABLE_COMPILER_WARNINGS" (;) "" (preproc_include) "#include <QObject> \n" (#include) "#include" (system_lib_string) "<QObject>" (declaration) "RESTORE_COMPILER_WARNINGS \n \nclass CController;" (type_identifier) "RESTORE_COMPILER_WARNINGS" (ERROR) "class" (identifier) "class" (identifier) "CController" (;) ";" (function_definition) "class CAndroidNativeHelper : public QObject \n{ \n Q_OBJECT \n \npublic: \n explicit CAndroidNativeHelper(CController& controller); \n ~CAndroidNativeHelper(); \n \n CController& controller(); \n \n static CAndroidNativeHelper* instance(); \n \nprivate: \n CController& _controller; \n \n static CAndroidNativeHelper* _instance; \n}" (type_identifier) "class" (identifier) "CAndroidNativeHelper" (ERROR) ": public QObject" (:) ":" (identifier) "public" (identifier) "QObject" (compound_statement) "{ \n Q_OBJECT \n \npublic: \n explicit CAndroidNativeHelper(CController& controller); \n ~CAndroidNativeHelper(); \n \n CController& controller(); \n \n static CAndroidNativeHelper* instance(); \n \nprivate: \n CController& _controller; \n \n static CAndroidNativeHelper* _instance; \n}" ({) "{" (declaration) "Q_OBJECT \n \npublic: \n explicit CAndroidNativeHelper(CController& controller);" (type_identifier) "Q_OBJECT" (ERROR) "public: \n explicit" (identifier) "public" (:) ":" (identifier) "explicit" (function_declarator) "CAndroidNativeHelper(CController& controller)" (identifier) "CAndroidNativeHelper" (parameter_list) "(CController& controller)" (() "(" (parameter_declaration) "CController& controller" (type_identifier) "CController" (ERROR) "&" (&) "&" (identifier) "controller" ()) ")" (;) ";" (expression_statement) "~CAndroidNativeHelper();" (unary_expression) "~CAndroidNativeHelper()" (~) "~" (call_expression) "CAndroidNativeHelper()" (identifier) "CAndroidNativeHelper" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "CController& controller();" (binary_expression) "CController& controller()" (identifier) "CController" (&) "&" (call_expression) "controller()" (identifier) "controller" (argument_list) "()" (() "(" ()) ")" (;) ";" (declaration) "static CAndroidNativeHelper* instance();" (storage_class_specifier) "static" (static) "static" (type_identifier) "CAndroidNativeHelper" (pointer_declarator) "* instance()" (*) "*" (function_declarator) "instance()" (identifier) "instance" (parameter_list) "()" (() "(" ()) ")" (;) ";" (labeled_statement) "private: \n CController& _controller;" (statement_identifier) "private" (:) ":" (expression_statement) "CController& _controller;" (binary_expression) "CController& _controller" (identifier) "CController" (&) "&" (identifier) "_controller" (;) ";" (declaration) "static CAndroidNativeHelper* _instance;" (storage_class_specifier) "static" (static) "static" (type_identifier) "CAndroidNativeHelper" (pointer_declarator) "* _instance" (*) "*" (identifier) "_instance" (;) ";" (}) "}" (expression_statement) ";" (;) ";"
99
4
{"language": "c", "success": true, "metadata": {"lines": 27, "avg_line_length": 16.89, "nodes": 53, "errors": 0, "source_hash": "6118f31fb3a7a78b1a818f3a0e990cd1319e5e44f6c08662da4dec471a64f999", "categorized_nodes": 39}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_call", "text": "#pragma once\r\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "preproc_directive", "text": "#pragma", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 7}}, {"id": 2, "type": "preproc_arg", "text": "once\r", "parent": 0, "children": [], "start_point": {"row": 0, "column": 8}, "end_point": {"row": 0, "column": 13}}, {"id": 3, "type": "preproc_include", "text": "#include \"compiler/compiler_warnings_control.h\"\r\n", "parent": null, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 5, "type": "string_literal", "text": "\"compiler/compiler_warnings_control.h\"", "parent": 3, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 47}}, {"id": 6, "type": "identifier", "text": "DISABLE_COMPILER_WARNINGS", "parent": null, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 25}}, {"id": 7, "type": "preproc_include", "text": "#include <QObject>\r\n", "parent": null, "children": [8, 9], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 8, "type": "#include", "text": "#include", "parent": 7, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 9, "type": "system_lib_string", "text": "<QObject>", "parent": 7, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 18}}, {"id": 10, "type": "declaration", "text": "RESTORE_COMPILER_WARNINGS\r\n\r\nclass CController;", "parent": null, "children": [11, 12], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 8, "column": 18}}, {"id": 11, "type": "type_identifier", "text": "RESTORE_COMPILER_WARNINGS", "parent": 10, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 25}}, {"id": 12, "type": "identifier", "text": "CController", "parent": 10, "children": [], "start_point": {"row": 8, "column": 6}, "end_point": {"row": 8, "column": 17}}, {"id": 13, "type": "function_definition", "text": "class CAndroidNativeHelper : public QObject\r\n{\r\n\tQ_OBJECT\r\n\r\npublic:\r\n\texplicit CAndroidNativeHelper(CController& controller);\r\n\t~CAndroidNativeHelper();\r\n\r\n\tCController& controller();\r\n\r\n\tstatic CAndroidNativeHelper* instance();\r\n\r\nprivate:\r\n\tCController& _controller;\r\n\r\n\tstatic CAndroidNativeHelper* _instance;\r\n}", "parent": null, "children": [14, 15], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 26, "column": 1}}, {"id": 14, "type": "identifier", "text": "CAndroidNativeHelper", "parent": 13, "children": [], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 26}}, {"id": 15, "type": "ERROR", "text": ": public QObject", "parent": 13, "children": [16], "start_point": {"row": 10, "column": 27}, "end_point": {"row": 10, "column": 43}}, {"id": 16, "type": "identifier", "text": "QObject", "parent": 15, "children": [], "start_point": {"row": 10, "column": 36}, "end_point": {"row": 10, "column": 43}}, {"id": 17, "type": "declaration", "text": "Q_OBJECT\r\n\r\npublic:\r\n\texplicit CAndroidNativeHelper(CController& controller);", "parent": 13, "children": [18, 19, 21], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 15, "column": 56}}, {"id": 18, "type": "type_identifier", "text": "Q_OBJECT", "parent": 17, "children": [], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 9}}, {"id": 19, "type": "ERROR", "text": "public:\r\n\texplicit", "parent": 17, "children": [20], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 15, "column": 9}}, {"id": 20, "type": "identifier", "text": "explicit", "parent": 19, "children": [], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 9}}, {"id": 21, "type": "function_declarator", "text": "CAndroidNativeHelper(CController& controller)", "parent": 17, "children": [22, 23], "start_point": {"row": 15, "column": 10}, "end_point": {"row": 15, "column": 55}}, {"id": 22, "type": "identifier", "text": "CAndroidNativeHelper", "parent": 21, "children": [], "start_point": {"row": 15, "column": 10}, "end_point": {"row": 15, "column": 30}}, {"id": 23, "type": "parameter_list", "text": "(CController& controller)", "parent": 21, "children": [24], "start_point": {"row": 15, "column": 30}, "end_point": {"row": 15, "column": 55}}, {"id": 24, "type": "parameter_declaration", "text": "CController& controller", "parent": 23, "children": [25, 26], "start_point": {"row": 15, "column": 31}, "end_point": {"row": 15, "column": 54}}, {"id": 25, "type": "type_identifier", "text": "CController", "parent": 24, "children": [], "start_point": {"row": 15, "column": 31}, "end_point": {"row": 15, "column": 42}}, {"id": 26, "type": "identifier", "text": "controller", "parent": 24, "children": [], "start_point": {"row": 15, "column": 44}, "end_point": {"row": 15, "column": 54}}, {"id": 27, "type": "unary_expression", "text": "~CAndroidNativeHelper()", "parent": 13, "children": [28, 29], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 24}}, {"id": 28, "type": "~", "text": "~", "parent": 27, "children": [], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 2}}, {"id": 29, "type": "call_expression", "text": "CAndroidNativeHelper()", "parent": 27, "children": [30, 31], "start_point": {"row": 16, "column": 2}, "end_point": {"row": 16, "column": 24}}, {"id": 30, "type": "identifier", "text": "CAndroidNativeHelper", "parent": 29, "children": [], "start_point": {"row": 16, "column": 2}, "end_point": {"row": 16, "column": 22}}, {"id": 31, "type": "argument_list", "text": "()", "parent": 29, "children": [], "start_point": {"row": 16, "column": 22}, "end_point": {"row": 16, "column": 24}}, {"id": 32, "type": "binary_expression", "text": "CController& controller()", "parent": 13, "children": [33, 34], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 26}}, {"id": 33, "type": "identifier", "text": "CController", "parent": 32, "children": [], "start_point": {"row": 18, "column": 1}, "end_point": {"row": 18, "column": 12}}, {"id": 34, "type": "call_expression", "text": "controller()", "parent": 32, "children": [35, 36], "start_point": {"row": 18, "column": 14}, "end_point": {"row": 18, "column": 26}}, {"id": 35, "type": "identifier", "text": "controller", "parent": 34, "children": [], "start_point": {"row": 18, "column": 14}, "end_point": {"row": 18, "column": 24}}, {"id": 36, "type": "argument_list", "text": "()", "parent": 34, "children": [], "start_point": {"row": 18, "column": 24}, "end_point": {"row": 18, "column": 26}}, {"id": 37, "type": "declaration", "text": "static CAndroidNativeHelper* instance();", "parent": 13, "children": [38, 39], "start_point": {"row": 20, "column": 1}, "end_point": {"row": 20, "column": 41}}, {"id": 38, "type": "type_identifier", "text": "CAndroidNativeHelper", "parent": 37, "children": [], "start_point": {"row": 20, "column": 8}, "end_point": {"row": 20, "column": 28}}, {"id": 39, "type": "pointer_declarator", "text": "* instance()", "parent": 37, "children": [40, 41], "start_point": {"row": 20, "column": 28}, "end_point": {"row": 20, "column": 40}}, {"id": 40, "type": "*", "text": "*", "parent": 39, "children": [], "start_point": {"row": 20, "column": 28}, "end_point": {"row": 20, "column": 29}}, {"id": 41, "type": "function_declarator", "text": "instance()", "parent": 39, "children": [42, 43], "start_point": {"row": 20, "column": 30}, "end_point": {"row": 20, "column": 40}}, {"id": 42, "type": "identifier", "text": "instance", "parent": 41, "children": [], "start_point": {"row": 20, "column": 30}, "end_point": {"row": 20, "column": 38}}, {"id": 43, "type": "parameter_list", "text": "()", "parent": 41, "children": [], "start_point": {"row": 20, "column": 38}, "end_point": {"row": 20, "column": 40}}, {"id": 44, "type": "labeled_statement", "text": "private:\r\n\tCController& _controller;", "parent": 13, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 23, "column": 26}}, {"id": 45, "type": "binary_expression", "text": "CController& _controller", "parent": 44, "children": [46, 47], "start_point": {"row": 23, "column": 1}, "end_point": {"row": 23, "column": 25}}, {"id": 46, "type": "identifier", "text": "CController", "parent": 45, "children": [], "start_point": {"row": 23, "column": 1}, "end_point": {"row": 23, "column": 12}}, {"id": 47, "type": "identifier", "text": "_controller", "parent": 45, "children": [], "start_point": {"row": 23, "column": 14}, "end_point": {"row": 23, "column": 25}}, {"id": 48, "type": "declaration", "text": "static CAndroidNativeHelper* _instance;", "parent": 13, "children": [49, 50], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 25, "column": 40}}, {"id": 49, "type": "type_identifier", "text": "CAndroidNativeHelper", "parent": 48, "children": [], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 28}}, {"id": 50, "type": "pointer_declarator", "text": "* _instance", "parent": 48, "children": [51, 52], "start_point": {"row": 25, "column": 28}, "end_point": {"row": 25, "column": 39}}, {"id": 51, "type": "*", "text": "*", "parent": 50, "children": [], "start_point": {"row": 25, "column": 28}, "end_point": {"row": 25, "column": 29}}, {"id": 52, "type": "identifier", "text": "_instance", "parent": 50, "children": [], "start_point": {"row": 25, "column": 30}, "end_point": {"row": 25, "column": 39}}]}, "node_categories": {"declarations": {"functions": [13, 21, 41], "variables": [10, 17, 24, 37, 48], "classes": [], "imports": [3, 4, 7, 8], "modules": [], "enums": []}, "statements": {"expressions": [27, 29, 32, 34, 45], "assignments": [], "loops": [], "conditionals": [6, 11, 12, 14, 16, 18, 20, 22, 25, 26, 30, 33, 35, 38, 42, 46, 47, 49, 52], "returns": [], "exceptions": []}, "expressions": {"calls": [0], "literals": [5, 9], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 13, "universal_type": "function", "name": "CAndroidNativeHelper", "text_snippet": "class CAndroidNativeHelper : public QObject\r\n{\r\n\tQ_OBJECT\r\n\r\npublic:\r\n\texplicit CAndroidNativeHelper"}, {"node_id": 21, "universal_type": "function", "name": "unknown", "text_snippet": "CAndroidNativeHelper(CController& controller)"}, {"node_id": 41, "universal_type": "function", "name": "unknown", "text_snippet": "instance()"}], "class_declarations": [], "import_statements": [{"node_id": 3, "text": "#include \"compiler/compiler_warnings_control.h\"\r\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 7, "text": "#include <QObject>\r\n"}, {"node_id": 8, "text": "#include"}]}, "original_source_code": "#pragma once\r\n\r\n#include \"compiler/compiler_warnings_control.h\"\r\n\r\nDISABLE_COMPILER_WARNINGS\r\n#include <QObject>\r\nRESTORE_COMPILER_WARNINGS\r\n\r\nclass CController;\r\n\r\nclass CAndroidNativeHelper : public QObject\r\n{\r\n\tQ_OBJECT\r\n\r\npublic:\r\n\texplicit CAndroidNativeHelper(CController& controller);\r\n\t~CAndroidNativeHelper();\r\n\r\n\tCController& controller();\r\n\r\n\tstatic CAndroidNativeHelper* instance();\r\n\r\nprivate:\r\n\tCController& _controller;\r\n\r\n\tstatic CAndroidNativeHelper* _instance;\r\n};\r\n"}
80,589
c
/******************************************************************** created: 2010/05/07 filename: IGraphicsSpaceCoordinator.h author: Crazii purpose: *********************************************************************/ #ifndef __Blade_ISpaceCoordinator_h__ #define __Blade_ISpaceCoordinator_h__ #include <interface/IPage.h> #include <interface/public/graphics/IGraphicsSpaceCoordinator.h> #include <interface/ISpace.h> namespace Blade { ////////////////////////////////////////////////////////////////////////// typedef struct SSpaceCoordinatorDesc { TString type; TString defaultSpace; uint32 visiblePage; uint32 pageSize; }COORDINATOR_DESC; ////////////////////////////////////////////////////////////////////////// class BLADE_GRAPHICS_API ISpaceCoordinator : public IGraphicsSpaceCoordinator, public ISpace, public IPagingManager::IListener { public: virtual ~ISpaceCoordinator() {} /* @describe @param @return */ virtual bool initialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0; /************************************************************************/ /* */ /************************************************************************/ /* @describe @param @return */ virtual const TString& getCoordinatorType() const = 0; /* @describe @param @return */ virtual bool initialize(const COORDINATOR_DESC* desc) = 0; /** @describe @param @return */ virtual const COORDINATOR_DESC* getDesc() const = 0; /* @describe @param @return */ virtual size_t getNumSpaces() const = 0; /* @describe @param @return */ virtual ISpace* getSpace(index_t index) const = 0; /* @describe @param @return */ virtual ISpace* getSpace(const TString& name) const = 0; /* @describe @param @return */ virtual ISpace* addSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false) = 0; /* @describe @param @return */ virtual bool removeSpace(const TString& name) = 0; /** @describe x,z in range of [0,COORDINATOR_DESC.visiblePage) @param @return */ virtual ISpace* getSpaceofPage(index_t x, index_t z) const = 0; };//class ISpaceCoordinator extern template class BLADE_GRAPHICS_API Factory<ISpaceCoordinator>; typedef Factory<ISpaceCoordinator> CoordinatorFactory; }//namespace Blade #endif //__Blade_ISpaceCoordinator_h__
25.59
95
(translation_unit) "/********************************************************************\n created: 2010/05/07\n filename: IGraphicsSpaceCoordinator.h\n author: Crazii\n purpose: \n*********************************************************************/\n#ifndef __Blade_ISpaceCoordinator_h__\n#define __Blade_ISpaceCoordinator_h__\n#include <interface/IPage.h>\n#include <interface/public/graphics/IGraphicsSpaceCoordinator.h>\n#include <interface/ISpace.h>\n\nnamespace Blade\n{\n //////////////////////////////////////////////////////////////////////////\n typedef struct SSpaceCoordinatorDesc\n {\n TString type;\n TString defaultSpace;\n uint32 visiblePage;\n uint32 pageSize;\n }COORDINATOR_DESC;\n\n //////////////////////////////////////////////////////////////////////////\n class BLADE_GRAPHICS_API ISpaceCoordinator : public IGraphicsSpaceCoordinator, public ISpace, public IPagingManager::IListener\n {\n public:\n virtual ~ISpaceCoordinator() {}\n\n /*\n @describe \n @param\n @return\n */\n virtual bool initialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0;\n\n /************************************************************************/\n /* */\n /************************************************************************/\n /*\n @describe\n @param\n @return\n */\n virtual const TString& getCoordinatorType() const = 0;\n\n /*\n @describe \n @param \n @return \n */\n virtual bool initialize(const COORDINATOR_DESC* desc) = 0;\n\n /**\n @describe \n @param\n @return\n */\n virtual const COORDINATOR_DESC* getDesc() const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual size_t getNumSpaces() const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* getSpace(index_t index) const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* getSpace(const TString& name) const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* addSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false) = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual bool removeSpace(const TString& name) = 0;\n\n /**\n @describe x,z in range of [0,COORDINATOR_DESC.visiblePage)\n @param\n @return\n */\n virtual ISpace* getSpaceofPage(index_t x, index_t z) const = 0;\n\n };//class ISpaceCoordinator\n\n extern template class BLADE_GRAPHICS_API Factory<ISpaceCoordinator>;\n typedef Factory<ISpaceCoordinator> CoordinatorFactory;\n\n}//namespace Blade\n\n\n#endif //__Blade_ISpaceCoordinator_h__" (comment) "/********************************************************************\n created: 2010/05/07\n filename: IGraphicsSpaceCoordinator.h\n author: Crazii\n purpose: \n*********************************************************************/" (preproc_ifdef) "#ifndef __Blade_ISpaceCoordinator_h__\n#define __Blade_ISpaceCoordinator_h__\n#include <interface/IPage.h>\n#include <interface/public/graphics/IGraphicsSpaceCoordinator.h>\n#include <interface/ISpace.h>\n\nnamespace Blade\n{\n //////////////////////////////////////////////////////////////////////////\n typedef struct SSpaceCoordinatorDesc\n {\n TString type;\n TString defaultSpace;\n uint32 visiblePage;\n uint32 pageSize;\n }COORDINATOR_DESC;\n\n //////////////////////////////////////////////////////////////////////////\n class BLADE_GRAPHICS_API ISpaceCoordinator : public IGraphicsSpaceCoordinator, public ISpace, public IPagingManager::IListener\n {\n public:\n virtual ~ISpaceCoordinator() {}\n\n /*\n @describe \n @param\n @return\n */\n virtual bool initialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0;\n\n /************************************************************************/\n /* */\n /************************************************************************/\n /*\n @describe\n @param\n @return\n */\n virtual const TString& getCoordinatorType() const = 0;\n\n /*\n @describe \n @param \n @return \n */\n virtual bool initialize(const COORDINATOR_DESC* desc) = 0;\n\n /**\n @describe \n @param\n @return\n */\n virtual const COORDINATOR_DESC* getDesc() const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual size_t getNumSpaces() const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* getSpace(index_t index) const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* getSpace(const TString& name) const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* addSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false) = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual bool removeSpace(const TString& name) = 0;\n\n /**\n @describe x,z in range of [0,COORDINATOR_DESC.visiblePage)\n @param\n @return\n */\n virtual ISpace* getSpaceofPage(index_t x, index_t z) const = 0;\n\n };//class ISpaceCoordinator\n\n extern template class BLADE_GRAPHICS_API Factory<ISpaceCoordinator>;\n typedef Factory<ISpaceCoordinator> CoordinatorFactory;\n\n}//namespace Blade\n\n\n#endif" (#ifndef) "#ifndef" (identifier) "__Blade_ISpaceCoordinator_h__" (preproc_def) "#define __Blade_ISpaceCoordinator_h__\n" (#define) "#define" (identifier) "__Blade_ISpaceCoordinator_h__" (preproc_include) "#include <interface/IPage.h>\n" (#include) "#include" (system_lib_string) "<interface/IPage.h>" (preproc_include) "#include <interface/public/graphics/IGraphicsSpaceCoordinator.h>\n" (#include) "#include" (system_lib_string) "<interface/public/graphics/IGraphicsSpaceCoordinator.h>" (preproc_include) "#include <interface/ISpace.h>\n" (#include) "#include" (system_lib_string) "<interface/ISpace.h>" (function_definition) "namespace Blade\n{\n //////////////////////////////////////////////////////////////////////////\n typedef struct SSpaceCoordinatorDesc\n {\n TString type;\n TString defaultSpace;\n uint32 visiblePage;\n uint32 pageSize;\n }COORDINATOR_DESC;\n\n //////////////////////////////////////////////////////////////////////////\n class BLADE_GRAPHICS_API ISpaceCoordinator : public IGraphicsSpaceCoordinator, public ISpace, public IPagingManager::IListener\n {\n public:\n virtual ~ISpaceCoordinator() {}\n\n /*\n @describe \n @param\n @return\n */\n virtual bool initialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0;\n\n /************************************************************************/\n /* */\n /************************************************************************/\n /*\n @describe\n @param\n @return\n */\n virtual const TString& getCoordinatorType() const = 0;\n\n /*\n @describe \n @param \n @return \n */\n virtual bool initialize(const COORDINATOR_DESC* desc) = 0;\n\n /**\n @describe \n @param\n @return\n */\n virtual const COORDINATOR_DESC* getDesc() const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual size_t getNumSpaces() const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* getSpace(index_t index) const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* getSpace(const TString& name) const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* addSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false) = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual bool removeSpace(const TString& name) = 0;\n\n /**\n @describe x,z in range of [0,COORDINATOR_DESC.visiblePage)\n @param\n @return\n */\n virtual ISpace* getSpaceofPage(index_t x, index_t z) const = 0;\n\n };//class ISpaceCoordinator\n\n extern template class BLADE_GRAPHICS_API Factory<ISpaceCoordinator>;\n typedef Factory<ISpaceCoordinator> CoordinatorFactory;\n\n}" (type_identifier) "namespace" (identifier) "Blade" (compound_statement) "{\n //////////////////////////////////////////////////////////////////////////\n typedef struct SSpaceCoordinatorDesc\n {\n TString type;\n TString defaultSpace;\n uint32 visiblePage;\n uint32 pageSize;\n }COORDINATOR_DESC;\n\n //////////////////////////////////////////////////////////////////////////\n class BLADE_GRAPHICS_API ISpaceCoordinator : public IGraphicsSpaceCoordinator, public ISpace, public IPagingManager::IListener\n {\n public:\n virtual ~ISpaceCoordinator() {}\n\n /*\n @describe \n @param\n @return\n */\n virtual bool initialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0;\n\n /************************************************************************/\n /* */\n /************************************************************************/\n /*\n @describe\n @param\n @return\n */\n virtual const TString& getCoordinatorType() const = 0;\n\n /*\n @describe \n @param \n @return \n */\n virtual bool initialize(const COORDINATOR_DESC* desc) = 0;\n\n /**\n @describe \n @param\n @return\n */\n virtual const COORDINATOR_DESC* getDesc() const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual size_t getNumSpaces() const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* getSpace(index_t index) const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* getSpace(const TString& name) const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* addSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false) = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual bool removeSpace(const TString& name) = 0;\n\n /**\n @describe x,z in range of [0,COORDINATOR_DESC.visiblePage)\n @param\n @return\n */\n virtual ISpace* getSpaceofPage(index_t x, index_t z) const = 0;\n\n };//class ISpaceCoordinator\n\n extern template class BLADE_GRAPHICS_API Factory<ISpaceCoordinator>;\n typedef Factory<ISpaceCoordinator> CoordinatorFactory;\n\n}" ({) "{" (comment) "//////////////////////////////////////////////////////////////////////////" (type_definition) "typedef struct SSpaceCoordinatorDesc\n {\n TString type;\n TString defaultSpace;\n uint32 visiblePage;\n uint32 pageSize;\n }COORDINATOR_DESC;" (typedef) "typedef" (struct_specifier) "struct SSpaceCoordinatorDesc\n {\n TString type;\n TString defaultSpace;\n uint32 visiblePage;\n uint32 pageSize;\n }" (struct) "struct" (type_identifier) "SSpaceCoordinatorDesc" (field_declaration_list) "{\n TString type;\n TString defaultSpace;\n uint32 visiblePage;\n uint32 pageSize;\n }" ({) "{" (field_declaration) "TString type;" (type_identifier) "TString" (field_identifier) "type" (;) ";" (field_declaration) "TString defaultSpace;" (type_identifier) "TString" (field_identifier) "defaultSpace" (;) ";" (field_declaration) "uint32 visiblePage;" (type_identifier) "uint32" (field_identifier) "visiblePage" (;) ";" (field_declaration) "uint32 pageSize;" (type_identifier) "uint32" (field_identifier) "pageSize" (;) ";" (}) "}" (type_identifier) "COORDINATOR_DESC" (;) ";" (comment) "//////////////////////////////////////////////////////////////////////////" (declaration) "class BLADE_GRAPHICS_API" (type_identifier) "class" (identifier) "BLADE_GRAPHICS_API" (;) "" (labeled_statement) "ISpaceCoordinator : public IGraphicsSpaceCoordinator, public ISpace, public IPagingManager::IListener\n {\n public:\n virtual ~ISpaceCoordinator() {}\n\n /*\n @describe \n @param\n @return\n */\n virtual bool initialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0;" (statement_identifier) "ISpaceCoordinator" (:) ":" (declaration) "public IGraphicsSpaceCoordinator, public ISpace, public IPagingManager::IListener\n {\n public:\n virtual ~ISpaceCoordinator() {}\n\n /*\n @describe \n @param\n @return\n */\n virtual bool initialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0;" (type_identifier) "public" (identifier) "IGraphicsSpaceCoordinator" (,) "," (identifier) "public" (ERROR) "ISpace" (identifier) "ISpace" (,) "," (ERROR) "public IPagingManager::IListener\n {\n public:\n virtual ~ISpaceCoordinator() {}" (identifier) "public" (identifier) "IPagingManager" (:) ":" (:) ":" (identifier) "IListener" ({) "{" (identifier) "public" (:) ":" (identifier) "virtual" (~) "~" (function_declarator) "ISpaceCoordinator()" (identifier) "ISpaceCoordinator" (parameter_list) "()" (() "(" ()) ")" ({) "{" (}) "}" (comment) "/*\n @describe \n @param\n @return\n */" (ERROR) "virtual bool" (identifier) "virtual" (identifier) "bool" (init_declarator) "initialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0" (function_declarator) "initialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask)" (identifier) "initialize" (parameter_list) "(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask)" (() "(" (parameter_declaration) "ISpaceCoordinator* coorinator" (type_identifier) "ISpaceCoordinator" (pointer_declarator) "* coorinator" (*) "*" (identifier) "coorinator" (,) "," (parameter_declaration) "const AABB& maxBound" (type_qualifier) "const" (const) "const" (type_identifier) "AABB" (ERROR) "&" (&) "&" (identifier) "maxBound" (,) "," (parameter_declaration) "uint32 partitionMask" (type_identifier) "uint32" (identifier) "partitionMask" ()) ")" (=) "=" (number_literal) "0" (;) ";" (comment) "/************************************************************************/" (comment) "/* */" (comment) "/************************************************************************/" (comment) "/*\n @describe\n @param\n @return\n */" (ERROR) "virtual const TString& getCoordinatorType() const = 0;\n\n /*\n @describe \n @param \n @return \n */\n virtual bool initialize(const COORDINATOR_DESC* desc) = 0;\n\n /**\n @describe \n @param\n @return\n */\n virtual const COORDINATOR_DESC* getDesc() const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual size_t getNumSpaces() const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* getSpace(index_t index) const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* getSpace(const TString& name) const = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual ISpace* addSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false) = 0;\n\n /*\n @describe\n @param\n @return\n */\n virtual bool removeSpace(const TString& name) = 0;\n\n /**\n @describe x,z in range of [0,COORDINATOR_DESC.visiblePage)\n @param\n @return\n */\n virtual ISpace* getSpaceofPage(index_t x, index_t z) const = 0;\n\n };//class ISpaceCoordinator\n\n extern template class BLADE_GRAPHICS_API Factory<ISpaceCoordinator>;\n typedef Factory<ISpaceCoordinator> CoordinatorFactory;" (type_identifier) "virtual" (type_qualifier) "const" (const) "const" (ERROR) "TString&" (identifier) "TString" (&) "&" (function_declarator) "getCoordinatorType()" (identifier) "getCoordinatorType" (parameter_list) "()" (() "(" ()) ")" (declaration) "const = 0;\n\n /*\n @describe \n @param \n @return \n */\n virtual bool initialize(const COORDINATOR_DESC* desc) = 0;" (type_qualifier) "const" (const) "const" (ERROR) "= 0;" (=) "=" (number_literal) "0" (;) ";" (comment) "/*\n @describe \n @param \n @return \n */" (type_identifier) "virtual" (ERROR) "bool" (identifier) "bool" (init_declarator) "initialize(const COORDINATOR_DESC* desc) = 0" (function_declarator) "initialize(const COORDINATOR_DESC* desc)" (identifier) "initialize" (parameter_list) "(const COORDINATOR_DESC* desc)" (() "(" (parameter_declaration) "const COORDINATOR_DESC* desc" (type_qualifier) "const" (const) "const" (type_identifier) "COORDINATOR_DESC" (pointer_declarator) "* desc" (*) "*" (identifier) "desc" ()) ")" (=) "=" (number_literal) "0" (;) ";" (comment) "/**\n @describe \n @param\n @return\n */" (declaration) "virtual const COORDINATOR_DESC* getDesc() const = 0;" (type_identifier) "virtual" (type_qualifier) "const" (const) "const" (ERROR) "COORDINATOR_DESC" (identifier) "COORDINATOR_DESC" (init_declarator) "* getDesc() const = 0" (pointer_declarator) "* getDesc() const" (*) "*" (function_declarator) "getDesc() const" (identifier) "getDesc" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (=) "=" (number_literal) "0" (;) ";" (comment) "/*\n @describe\n @param\n @return\n */" (declaration) "virtual size_t getNumSpaces() const = 0;" (type_identifier) "virtual" (ERROR) "size_t" (identifier) "size_t" (init_declarator) "getNumSpaces() const = 0" (function_declarator) "getNumSpaces() const" (identifier) "getNumSpaces" (parameter_list) "()" (() "(" ()) ")" (identifier) "const" (=) "=" (number_literal) "0" (;) ";" (comment) "/*\n @describe\n @param\n @return\n */" (declaration) "virtual ISpace* getSpace(index_t index) const = 0;" (type_identifier) "virtual" (ERROR) "ISpace" (identifier) "ISpace" (init_declarator) "* getSpace(index_t index) const = 0" (pointer_declarator) "* getSpace(index_t index) const" (*) "*" (function_declarator) "getSpace(index_t index) const" (identifier) "getSpace" (parameter_list) "(index_t index)" (() "(" (parameter_declaration) "index_t index" (type_identifier) "index_t" (identifier) "index" ()) ")" (identifier) "const" (=) "=" (number_literal) "0" (;) ";" (comment) "/*\n @describe\n @param\n @return\n */" (declaration) "virtual ISpace* getSpace(const TString& name) const = 0;" (type_identifier) "virtual" (ERROR) "ISpace" (identifier) "ISpace" (init_declarator) "* getSpace(const TString& name) const = 0" (pointer_declarator) "* getSpace(const TString& name) const" (*) "*" (function_declarator) "getSpace(const TString& name) const" (identifier) "getSpace" (parameter_list) "(const TString& name)" (() "(" (parameter_declaration) "const TString& name" (type_qualifier) "const" (const) "const" (type_identifier) "TString" (ERROR) "&" (&) "&" (identifier) "name" ()) ")" (identifier) "const" (=) "=" (number_literal) "0" (;) ";" (comment) "/*\n @describe\n @param\n @return\n */" (declaration) "virtual ISpace* addSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false) = 0;" (type_identifier) "virtual" (ERROR) "ISpace" (identifier) "ISpace" (init_declarator) "* addSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false" (pointer_declarator) "* addSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated" (*) "*" (function_declarator) "addSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated" (identifier) "addSpace" (parameter_list) "(const TString& type,const TString& name, const Vector3& maxSize, bool separated" (() "(" (parameter_declaration) "const TString& type" (type_qualifier) "const" (const) "const" (type_identifier) "TString" (ERROR) "&" (&) "&" (identifier) "type" (,) "," (parameter_declaration) "const TString& name" (type_qualifier) "const" (const) "const" (type_identifier) "TString" (ERROR) "&" (&) "&" (identifier) "name" (,) "," (parameter_declaration) "const Vector3& maxSize" (type_qualifier) "const" (const) "const" (type_identifier) "Vector3" (ERROR) "&" (&) "&" (identifier) "maxSize" (,) "," (parameter_declaration) "bool separated" (primitive_type) "bool" (identifier) "separated" ()) "" (=) "=" (false) "false" (ERROR) ") = 0" ()) ")" (=) "=" (number_literal) "0" (;) ";" (comment) "/*\n @describe\n @param\n @return\n */" (declaration) "virtual bool removeSpace(const TString& name) = 0;" (type_identifier) "virtual" (ERROR) "bool" (identifier) "bool" (init_declarator) "removeSpace(const TString& name) = 0" (function_declarator) "removeSpace(const TString& name)" (identifier) "removeSpace" (parameter_list) "(const TString& name)" (() "(" (parameter_declaration) "const TString& name" (type_qualifier) "const" (const) "const" (type_identifier) "TString" (ERROR) "&" (&) "&" (identifier) "name" ()) ")" (=) "=" (number_literal) "0" (;) ";" (comment) "/**\n @describe x,z in range of [0,COORDINATOR_DESC.visiblePage)\n @param\n @return\n */" (declaration) "virtual ISpace* getSpaceofPage(index_t x, index_t z) const = 0;" (type_identifier) "virtual" (ERROR) "ISpace" (identifier) "ISpace" (init_declarator) "* getSpaceofPage(index_t x, index_t z) const = 0" (pointer_declarator) "* getSpaceofPage(index_t x, index_t z) const" (*) "*" (function_declarator) "getSpaceofPage(index_t x, index_t z) const" (identifier) "getSpaceofPage" (parameter_list) "(index_t x, index_t z)" (() "(" (parameter_declaration) "index_t x" (type_identifier) "index_t" (identifier) "x" (,) "," (parameter_declaration) "index_t z" (type_identifier) "index_t" (identifier) "z" ()) ")" (identifier) "const" (=) "=" (number_literal) "0" (;) ";" (ERROR) "};" (}) "}" (;) ";" (comment) "//class ISpaceCoordinator" (declaration) "extern template class" (storage_class_specifier) "extern" (extern) "extern" (type_identifier) "template" (identifier) "class" (;) "" (declaration) "BLADE_GRAPHICS_API Factory<ISpaceCoordinator>;" (type_identifier) "BLADE_GRAPHICS_API" (ERROR) "Factory<" (identifier) "Factory" (<) "<" (identifier) "ISpaceCoordinator" (ERROR) ">" (>) ">" (;) ";" (declaration) "typedef Factory<ISpaceCoordinator> CoordinatorFactory;" (type_identifier) "typedef" (ERROR) "Factory<ISpaceCoordinator>" (identifier) "Factory" (<) "<" (identifier) "ISpaceCoordinator" (>) ">" (identifier) "CoordinatorFactory" (;) ";" (}) "}" (comment) "//namespace Blade" (#endif) "#endif" (comment) "//__Blade_ISpaceCoordinator_h__"
358
25
{"language": "c", "success": true, "metadata": {"lines": 95, "avg_line_length": 25.59, "nodes": 229, "errors": 0, "source_hash": "aaae73c2694305260cb4984ec0621c9658c9f9cf6b3526aeff7027b3996ffc38", "categorized_nodes": 153}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef __Blade_ISpaceCoordinator_h__\n#define __Blade_ISpaceCoordinator_h__\n#include <interface/IPage.h>\n#include <interface/public/graphics/IGraphicsSpaceCoordinator.h>\n#include <interface/ISpace.h>\n\nnamespace Blade\n{\n\t//////////////////////////////////////////////////////////////////////////\n\ttypedef struct SSpaceCoordinatorDesc\n\t{\n\t\tTString\ttype;\n\t\tTString\tdefaultSpace;\n\t\tuint32\tvisiblePage;\n\t\tuint32\tpageSize;\n\t}COORDINATOR_DESC;\n\n\t//////////////////////////////////////////////////////////////////////////\n\tclass BLADE_GRAPHICS_API ISpaceCoordinator : public IGraphicsSpaceCoordinator, public ISpace, public IPagingManager::IListener\n\t{\n\tpublic:\n\t\tvirtual ~ISpaceCoordinator()\t{}\n\n\t\t/*\n\t\t@describe \n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual bool\t\t\t\tinitialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0;\n\n\t\t/************************************************************************/\n\t\t/* */\n\t\t/************************************************************************/\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual const TString&\t\tgetCoordinatorType() const = 0;\n\n\t\t/*\n\t\t@describe \n\t\t@param \n\t\t@return \n\t\t*/\n\t\tvirtual bool\t\t\t\tinitialize(const COORDINATOR_DESC* desc) = 0;\n\n\t\t/**\n\t\t@describe \n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual const COORDINATOR_DESC*\tgetDesc() const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual size_t\t\t\t\tgetNumSpaces() const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\tgetSpace(index_t index) const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\tgetSpace(const TString& name) const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\taddSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false) = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual bool\t\t\t\tremoveSpace(const TString& name) = 0;\n\n\t\t/**\n\t\t@describe x,z in range of [0,COORDINATOR_DESC.visiblePage)\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\tgetSpaceofPage(index_t x, index_t z) const = 0;\n\n\t};//class ISpaceCoordinator\n\n\textern template class BLADE_GRAPHICS_API Factory<ISpaceCoordinator>;\n\ttypedef Factory<ISpaceCoordinator> CoordinatorFactory;\n\n}//namespace Blade\n\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 15, 228], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 110, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 7}}, {"id": 2, "type": "identifier", "text": "__Blade_ISpaceCoordinator_h__", "parent": 0, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 37}}, {"id": 3, "type": "preproc_def", "text": "#define __Blade_ISpaceCoordinator_h__\n", "parent": 0, "children": [4, 5], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 7}}, {"id": 5, "type": "identifier", "text": "__Blade_ISpaceCoordinator_h__", "parent": 3, "children": [], "start_point": {"row": 7, "column": 8}, "end_point": {"row": 7, "column": 37}}, {"id": 6, "type": "preproc_include", "text": "#include <interface/IPage.h>\n", "parent": 0, "children": [7, 8], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<interface/IPage.h>", "parent": 6, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 28}}, {"id": 9, "type": "preproc_include", "text": "#include <interface/public/graphics/IGraphicsSpaceCoordinator.h>\n", "parent": 0, "children": [10, 11], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 10, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<interface/public/graphics/IGraphicsSpaceCoordinator.h>", "parent": 9, "children": [], "start_point": {"row": 9, "column": 9}, "end_point": {"row": 9, "column": 64}}, {"id": 12, "type": "preproc_include", "text": "#include <interface/ISpace.h>\n", "parent": 0, "children": [13, 14], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 11, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 8}}, {"id": 14, "type": "system_lib_string", "text": "<interface/ISpace.h>", "parent": 12, "children": [], "start_point": {"row": 10, "column": 9}, "end_point": {"row": 10, "column": 29}}, {"id": 15, "type": "function_definition", "text": "namespace Blade\n{\n\t//////////////////////////////////////////////////////////////////////////\n\ttypedef struct SSpaceCoordinatorDesc\n\t{\n\t\tTString\ttype;\n\t\tTString\tdefaultSpace;\n\t\tuint32\tvisiblePage;\n\t\tuint32\tpageSize;\n\t}COORDINATOR_DESC;\n\n\t//////////////////////////////////////////////////////////////////////////\n\tclass BLADE_GRAPHICS_API ISpaceCoordinator : public IGraphicsSpaceCoordinator, public ISpace, public IPagingManager::IListener\n\t{\n\tpublic:\n\t\tvirtual ~ISpaceCoordinator()\t{}\n\n\t\t/*\n\t\t@describe \n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual bool\t\t\t\tinitialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0;\n\n\t\t/************************************************************************/\n\t\t/* */\n\t\t/************************************************************************/\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual const TString&\t\tgetCoordinatorType() const = 0;\n\n\t\t/*\n\t\t@describe \n\t\t@param \n\t\t@return \n\t\t*/\n\t\tvirtual bool\t\t\t\tinitialize(const COORDINATOR_DESC* desc) = 0;\n\n\t\t/**\n\t\t@describe \n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual const COORDINATOR_DESC*\tgetDesc() const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual size_t\t\t\t\tgetNumSpaces() const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\tgetSpace(index_t index) const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\tgetSpace(const TString& name) const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\taddSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false) = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual bool\t\t\t\tremoveSpace(const TString& name) = 0;\n\n\t\t/**\n\t\t@describe x,z in range of [0,COORDINATOR_DESC.visiblePage)\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\tgetSpaceofPage(index_t x, index_t z) const = 0;\n\n\t};//class ISpaceCoordinator\n\n\textern template class BLADE_GRAPHICS_API Factory<ISpaceCoordinator>;\n\ttypedef Factory<ISpaceCoordinator> CoordinatorFactory;\n\n}", "parent": 0, "children": [16, 17], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 107, "column": 1}}, {"id": 16, "type": "type_identifier", "text": "namespace", "parent": 15, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 9}}, {"id": 17, "type": "identifier", "text": "Blade", "parent": 15, "children": [], "start_point": {"row": 12, "column": 10}, "end_point": {"row": 12, "column": 15}}, {"id": 18, "type": "type_definition", "text": "typedef struct SSpaceCoordinatorDesc\n\t{\n\t\tTString\ttype;\n\t\tTString\tdefaultSpace;\n\t\tuint32\tvisiblePage;\n\t\tuint32\tpageSize;\n\t}COORDINATOR_DESC;", "parent": 15, "children": [19, 20, 35], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 21, "column": 19}}, {"id": 19, "type": "typedef", "text": "typedef", "parent": 18, "children": [], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 8}}, {"id": 20, "type": "struct_specifier", "text": "struct SSpaceCoordinatorDesc\n\t{\n\t\tTString\ttype;\n\t\tTString\tdefaultSpace;\n\t\tuint32\tvisiblePage;\n\t\tuint32\tpageSize;\n\t}", "parent": 18, "children": [21, 22], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 21, "column": 2}}, {"id": 21, "type": "struct", "text": "struct", "parent": 20, "children": [], "start_point": {"row": 15, "column": 9}, "end_point": {"row": 15, "column": 15}}, {"id": 22, "type": "type_identifier", "text": "SSpaceCoordinatorDesc", "parent": 20, "children": [], "start_point": {"row": 15, "column": 16}, "end_point": {"row": 15, "column": 37}}, {"id": 23, "type": "field_declaration", "text": "TString\ttype;", "parent": 20, "children": [24, 25], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 17, "column": 15}}, {"id": 24, "type": "type_identifier", "text": "TString", "parent": 23, "children": [], "start_point": {"row": 17, "column": 2}, "end_point": {"row": 17, "column": 9}}, {"id": 25, "type": "field_identifier", "text": "type", "parent": 23, "children": [], "start_point": {"row": 17, "column": 10}, "end_point": {"row": 17, "column": 14}}, {"id": 26, "type": "field_declaration", "text": "TString\tdefaultSpace;", "parent": 20, "children": [27, 28], "start_point": {"row": 18, "column": 2}, "end_point": {"row": 18, "column": 23}}, {"id": 27, "type": "type_identifier", "text": "TString", "parent": 26, "children": [], "start_point": {"row": 18, "column": 2}, "end_point": {"row": 18, "column": 9}}, {"id": 28, "type": "field_identifier", "text": "defaultSpace", "parent": 26, "children": [], "start_point": {"row": 18, "column": 10}, "end_point": {"row": 18, "column": 22}}, {"id": 29, "type": "field_declaration", "text": "uint32\tvisiblePage;", "parent": 20, "children": [30, 31], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 21}}, {"id": 30, "type": "type_identifier", "text": "uint32", "parent": 29, "children": [], "start_point": {"row": 19, "column": 2}, "end_point": {"row": 19, "column": 8}}, {"id": 31, "type": "field_identifier", "text": "visiblePage", "parent": 29, "children": [], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 20}}, {"id": 32, "type": "field_declaration", "text": "uint32\tpageSize;", "parent": 20, "children": [33, 34], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 18}}, {"id": 33, "type": "type_identifier", "text": "uint32", "parent": 32, "children": [], "start_point": {"row": 20, "column": 2}, "end_point": {"row": 20, "column": 8}}, {"id": 34, "type": "field_identifier", "text": "pageSize", "parent": 32, "children": [], "start_point": {"row": 20, "column": 9}, "end_point": {"row": 20, "column": 17}}, {"id": 35, "type": "type_identifier", "text": "COORDINATOR_DESC", "parent": 18, "children": [], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 18}}, {"id": 36, "type": "declaration", "text": "class BLADE_GRAPHICS_API", "parent": 15, "children": [37], "start_point": {"row": 24, "column": 1}, "end_point": {"row": 24, "column": 25}}, {"id": 37, "type": "identifier", "text": "BLADE_GRAPHICS_API", "parent": 36, "children": [], "start_point": {"row": 24, "column": 7}, "end_point": {"row": 24, "column": 25}}, {"id": 38, "type": "labeled_statement", "text": "ISpaceCoordinator : public IGraphicsSpaceCoordinator, public ISpace, public IPagingManager::IListener\n\t{\n\tpublic:\n\t\tvirtual ~ISpaceCoordinator()\t{}\n\n\t\t/*\n\t\t@describe \n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual bool\t\t\t\tinitialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0;", "parent": 15, "children": [39, 40], "start_point": {"row": 24, "column": 26}, "end_point": {"row": 34, "column": 108}}, {"id": 39, "type": "statement_identifier", "text": "ISpaceCoordinator", "parent": 38, "children": [], "start_point": {"row": 24, "column": 26}, "end_point": {"row": 24, "column": 43}}, {"id": 40, "type": "declaration", "text": "public IGraphicsSpaceCoordinator, public ISpace, public IPagingManager::IListener\n\t{\n\tpublic:\n\t\tvirtual ~ISpaceCoordinator()\t{}\n\n\t\t/*\n\t\t@describe \n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual bool\t\t\t\tinitialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0;", "parent": 38, "children": [41, 42, 44, 52, 55], "start_point": {"row": 24, "column": 46}, "end_point": {"row": 34, "column": 108}}, {"id": 41, "type": "identifier", "text": "IGraphicsSpaceCoordinator", "parent": 40, "children": [], "start_point": {"row": 24, "column": 53}, "end_point": {"row": 24, "column": 78}}, {"id": 42, "type": "ERROR", "text": "ISpace", "parent": 40, "children": [43], "start_point": {"row": 24, "column": 87}, "end_point": {"row": 24, "column": 93}}, {"id": 43, "type": "identifier", "text": "ISpace", "parent": 42, "children": [], "start_point": {"row": 24, "column": 87}, "end_point": {"row": 24, "column": 93}}, {"id": 44, "type": "ERROR", "text": "public IPagingManager::IListener\n\t{\n\tpublic:\n\t\tvirtual ~ISpaceCoordinator()\t{}", "parent": 40, "children": [45, 46, 47, 48, 49], "start_point": {"row": 24, "column": 95}, "end_point": {"row": 27, "column": 33}}, {"id": 45, "type": "identifier", "text": "IPagingManager", "parent": 44, "children": [], "start_point": {"row": 24, "column": 102}, "end_point": {"row": 24, "column": 116}}, {"id": 46, "type": "identifier", "text": "IListener", "parent": 44, "children": [], "start_point": {"row": 24, "column": 118}, "end_point": {"row": 24, "column": 127}}, {"id": 47, "type": "identifier", "text": "virtual", "parent": 44, "children": [], "start_point": {"row": 27, "column": 2}, "end_point": {"row": 27, "column": 9}}, {"id": 48, "type": "~", "text": "~", "parent": 44, "children": [], "start_point": {"row": 27, "column": 10}, "end_point": {"row": 27, "column": 11}}, {"id": 49, "type": "function_declarator", "text": "ISpaceCoordinator()", "parent": 44, "children": [50, 51], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 30}}, {"id": 50, "type": "identifier", "text": "ISpaceCoordinator", "parent": 49, "children": [], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 28}}, {"id": 51, "type": "parameter_list", "text": "()", "parent": 49, "children": [], "start_point": {"row": 27, "column": 28}, "end_point": {"row": 27, "column": 30}}, {"id": 52, "type": "ERROR", "text": "virtual bool", "parent": 40, "children": [53, 54], "start_point": {"row": 34, "column": 2}, "end_point": {"row": 34, "column": 14}}, {"id": 53, "type": "identifier", "text": "virtual", "parent": 52, "children": [], "start_point": {"row": 34, "column": 2}, "end_point": {"row": 34, "column": 9}}, {"id": 54, "type": "identifier", "text": "bool", "parent": 52, "children": [], "start_point": {"row": 34, "column": 10}, "end_point": {"row": 34, "column": 14}}, {"id": 55, "type": "init_declarator", "text": "initialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0", "parent": 40, "children": [56, 70, 71], "start_point": {"row": 34, "column": 18}, "end_point": {"row": 34, "column": 107}}, {"id": 56, "type": "function_declarator", "text": "initialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask)", "parent": 55, "children": [57, 58], "start_point": {"row": 34, "column": 18}, "end_point": {"row": 34, "column": 103}}, {"id": 57, "type": "identifier", "text": "initialize", "parent": 56, "children": [], "start_point": {"row": 34, "column": 18}, "end_point": {"row": 34, "column": 28}}, {"id": 58, "type": "parameter_list", "text": "(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask)", "parent": 56, "children": [59, 64, 67], "start_point": {"row": 34, "column": 28}, "end_point": {"row": 34, "column": 103}}, {"id": 59, "type": "parameter_declaration", "text": "ISpaceCoordinator* coorinator", "parent": 58, "children": [60, 61], "start_point": {"row": 34, "column": 29}, "end_point": {"row": 34, "column": 58}}, {"id": 60, "type": "type_identifier", "text": "ISpaceCoordinator", "parent": 59, "children": [], "start_point": {"row": 34, "column": 29}, "end_point": {"row": 34, "column": 46}}, {"id": 61, "type": "pointer_declarator", "text": "* coorinator", "parent": 59, "children": [62, 63], "start_point": {"row": 34, "column": 46}, "end_point": {"row": 34, "column": 58}}, {"id": 62, "type": "*", "text": "*", "parent": 61, "children": [], "start_point": {"row": 34, "column": 46}, "end_point": {"row": 34, "column": 47}}, {"id": 63, "type": "identifier", "text": "coorinator", "parent": 61, "children": [], "start_point": {"row": 34, "column": 48}, "end_point": {"row": 34, "column": 58}}, {"id": 64, "type": "parameter_declaration", "text": "const AABB& maxBound", "parent": 58, "children": [65, 66], "start_point": {"row": 34, "column": 60}, "end_point": {"row": 34, "column": 80}}, {"id": 65, "type": "type_identifier", "text": "AABB", "parent": 64, "children": [], "start_point": {"row": 34, "column": 66}, "end_point": {"row": 34, "column": 70}}, {"id": 66, "type": "identifier", "text": "maxBound", "parent": 64, "children": [], "start_point": {"row": 34, "column": 72}, "end_point": {"row": 34, "column": 80}}, {"id": 67, "type": "parameter_declaration", "text": "uint32 partitionMask", "parent": 58, "children": [68, 69], "start_point": {"row": 34, "column": 82}, "end_point": {"row": 34, "column": 102}}, {"id": 68, "type": "type_identifier", "text": "uint32", "parent": 67, "children": [], "start_point": {"row": 34, "column": 82}, "end_point": {"row": 34, "column": 88}}, {"id": 69, "type": "identifier", "text": "partitionMask", "parent": 67, "children": [], "start_point": {"row": 34, "column": 89}, "end_point": {"row": 34, "column": 102}}, {"id": 70, "type": "=", "text": "=", "parent": 55, "children": [], "start_point": {"row": 34, "column": 104}, "end_point": {"row": 34, "column": 105}}, {"id": 71, "type": "number_literal", "text": "0", "parent": 55, "children": [], "start_point": {"row": 34, "column": 106}, "end_point": {"row": 34, "column": 107}}, {"id": 72, "type": "ERROR", "text": "virtual const TString&\t\tgetCoordinatorType() const = 0;\n\n\t\t/*\n\t\t@describe \n\t\t@param \n\t\t@return \n\t\t*/\n\t\tvirtual bool\t\t\t\tinitialize(const COORDINATOR_DESC* desc) = 0;\n\n\t\t/**\n\t\t@describe \n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual const COORDINATOR_DESC*\tgetDesc() const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual size_t\t\t\t\tgetNumSpaces() const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\tgetSpace(index_t index) const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\tgetSpace(const TString& name) const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\taddSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false) = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual bool\t\t\t\tremoveSpace(const TString& name) = 0;\n\n\t\t/**\n\t\t@describe x,z in range of [0,COORDINATOR_DESC.visiblePage)\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\tgetSpaceofPage(index_t x, index_t z) const = 0;\n\n\t};//class ISpaceCoordinator\n\n\textern template class BLADE_GRAPHICS_API Factory<ISpaceCoordinator>;\n\ttypedef Factory<ISpaceCoordinator> CoordinatorFactory;", "parent": 15, "children": [73, 74, 76, 79, 97, 109, 119, 134, 149, 176, 189, 207, 208, 212, 220], "start_point": {"row": 44, "column": 2}, "end_point": {"row": 105, "column": 55}}, {"id": 73, "type": "type_identifier", "text": "virtual", "parent": 72, "children": [], "start_point": {"row": 44, "column": 2}, "end_point": {"row": 44, "column": 9}}, {"id": 74, "type": "ERROR", "text": "TString&", "parent": 72, "children": [75], "start_point": {"row": 44, "column": 16}, "end_point": {"row": 44, "column": 24}}, {"id": 75, "type": "identifier", "text": "TString", "parent": 74, "children": [], "start_point": {"row": 44, "column": 16}, "end_point": {"row": 44, "column": 23}}, {"id": 76, "type": "function_declarator", "text": "getCoordinatorType()", "parent": 72, "children": [77, 78], "start_point": {"row": 44, "column": 26}, "end_point": {"row": 44, "column": 46}}, {"id": 77, "type": "identifier", "text": "getCoordinatorType", "parent": 76, "children": [], "start_point": {"row": 44, "column": 26}, "end_point": {"row": 44, "column": 44}}, {"id": 78, "type": "parameter_list", "text": "()", "parent": 76, "children": [], "start_point": {"row": 44, "column": 44}, "end_point": {"row": 44, "column": 46}}, {"id": 79, "type": "declaration", "text": "const = 0;\n\n\t\t/*\n\t\t@describe \n\t\t@param \n\t\t@return \n\t\t*/\n\t\tvirtual bool\t\t\t\tinitialize(const COORDINATOR_DESC* desc) = 0;", "parent": 72, "children": [80, 83, 84, 86], "start_point": {"row": 44, "column": 47}, "end_point": {"row": 51, "column": 63}}, {"id": 80, "type": "ERROR", "text": "= 0;", "parent": 79, "children": [81, 82], "start_point": {"row": 44, "column": 53}, "end_point": {"row": 44, "column": 57}}, {"id": 81, "type": "=", "text": "=", "parent": 80, "children": [], "start_point": {"row": 44, "column": 53}, "end_point": {"row": 44, "column": 54}}, {"id": 82, "type": "number_literal", "text": "0", "parent": 80, "children": [], "start_point": {"row": 44, "column": 55}, "end_point": {"row": 44, "column": 56}}, {"id": 83, "type": "type_identifier", "text": "virtual", "parent": 79, "children": [], "start_point": {"row": 51, "column": 2}, "end_point": {"row": 51, "column": 9}}, {"id": 84, "type": "ERROR", "text": "bool", "parent": 79, "children": [85], "start_point": {"row": 51, "column": 10}, "end_point": {"row": 51, "column": 14}}, {"id": 85, "type": "identifier", "text": "bool", "parent": 84, "children": [], "start_point": {"row": 51, "column": 10}, "end_point": {"row": 51, "column": 14}}, {"id": 86, "type": "init_declarator", "text": "initialize(const COORDINATOR_DESC* desc) = 0", "parent": 79, "children": [87, 95, 96], "start_point": {"row": 51, "column": 18}, "end_point": {"row": 51, "column": 62}}, {"id": 87, "type": "function_declarator", "text": "initialize(const COORDINATOR_DESC* desc)", "parent": 86, "children": [88, 89], "start_point": {"row": 51, "column": 18}, "end_point": {"row": 51, "column": 58}}, {"id": 88, "type": "identifier", "text": "initialize", "parent": 87, "children": [], "start_point": {"row": 51, "column": 18}, "end_point": {"row": 51, "column": 28}}, {"id": 89, "type": "parameter_list", "text": "(const COORDINATOR_DESC* desc)", "parent": 87, "children": [90], "start_point": {"row": 51, "column": 28}, "end_point": {"row": 51, "column": 58}}, {"id": 90, "type": "parameter_declaration", "text": "const COORDINATOR_DESC* desc", "parent": 89, "children": [91, 92], "start_point": {"row": 51, "column": 29}, "end_point": {"row": 51, "column": 57}}, {"id": 91, "type": "type_identifier", "text": "COORDINATOR_DESC", "parent": 90, "children": [], "start_point": {"row": 51, "column": 35}, "end_point": {"row": 51, "column": 51}}, {"id": 92, "type": "pointer_declarator", "text": "* desc", "parent": 90, "children": [93, 94], "start_point": {"row": 51, "column": 51}, "end_point": {"row": 51, "column": 57}}, {"id": 93, "type": "*", "text": "*", "parent": 92, "children": [], "start_point": {"row": 51, "column": 51}, "end_point": {"row": 51, "column": 52}}, {"id": 94, "type": "identifier", "text": "desc", "parent": 92, "children": [], "start_point": {"row": 51, "column": 53}, "end_point": {"row": 51, "column": 57}}, {"id": 95, "type": "=", "text": "=", "parent": 86, "children": [], "start_point": {"row": 51, "column": 59}, "end_point": {"row": 51, "column": 60}}, {"id": 96, "type": "number_literal", "text": "0", "parent": 86, "children": [], "start_point": {"row": 51, "column": 61}, "end_point": {"row": 51, "column": 62}}, {"id": 97, "type": "declaration", "text": "virtual const COORDINATOR_DESC*\tgetDesc() const = 0;", "parent": 72, "children": [98, 99, 101], "start_point": {"row": 58, "column": 2}, "end_point": {"row": 58, "column": 54}}, {"id": 98, "type": "type_identifier", "text": "virtual", "parent": 97, "children": [], "start_point": {"row": 58, "column": 2}, "end_point": {"row": 58, "column": 9}}, {"id": 99, "type": "ERROR", "text": "COORDINATOR_DESC", "parent": 97, "children": [100], "start_point": {"row": 58, "column": 16}, "end_point": {"row": 58, "column": 32}}, {"id": 100, "type": "identifier", "text": "COORDINATOR_DESC", "parent": 99, "children": [], "start_point": {"row": 58, "column": 16}, "end_point": {"row": 58, "column": 32}}, {"id": 101, "type": "init_declarator", "text": "*\tgetDesc() const = 0", "parent": 97, "children": [102, 107, 108], "start_point": {"row": 58, "column": 32}, "end_point": {"row": 58, "column": 53}}, {"id": 102, "type": "pointer_declarator", "text": "*\tgetDesc() const", "parent": 101, "children": [103, 104], "start_point": {"row": 58, "column": 32}, "end_point": {"row": 58, "column": 49}}, {"id": 103, "type": "*", "text": "*", "parent": 102, "children": [], "start_point": {"row": 58, "column": 32}, "end_point": {"row": 58, "column": 33}}, {"id": 104, "type": "function_declarator", "text": "getDesc() const", "parent": 102, "children": [105, 106], "start_point": {"row": 58, "column": 34}, "end_point": {"row": 58, "column": 49}}, {"id": 105, "type": "identifier", "text": "getDesc", "parent": 104, "children": [], "start_point": {"row": 58, "column": 34}, "end_point": {"row": 58, "column": 41}}, {"id": 106, "type": "parameter_list", "text": "()", "parent": 104, "children": [], "start_point": {"row": 58, "column": 41}, "end_point": {"row": 58, "column": 43}}, {"id": 107, "type": "=", "text": "=", "parent": 101, "children": [], "start_point": {"row": 58, "column": 50}, "end_point": {"row": 58, "column": 51}}, {"id": 108, "type": "number_literal", "text": "0", "parent": 101, "children": [], "start_point": {"row": 58, "column": 52}, "end_point": {"row": 58, "column": 53}}, {"id": 109, "type": "declaration", "text": "virtual size_t\t\t\t\tgetNumSpaces() const = 0;", "parent": 72, "children": [110, 111, 113], "start_point": {"row": 65, "column": 2}, "end_point": {"row": 65, "column": 45}}, {"id": 110, "type": "type_identifier", "text": "virtual", "parent": 109, "children": [], "start_point": {"row": 65, "column": 2}, "end_point": {"row": 65, "column": 9}}, {"id": 111, "type": "ERROR", "text": "size_t", "parent": 109, "children": [112], "start_point": {"row": 65, "column": 10}, "end_point": {"row": 65, "column": 16}}, {"id": 112, "type": "identifier", "text": "size_t", "parent": 111, "children": [], "start_point": {"row": 65, "column": 10}, "end_point": {"row": 65, "column": 16}}, {"id": 113, "type": "init_declarator", "text": "getNumSpaces() const = 0", "parent": 109, "children": [114, 117, 118], "start_point": {"row": 65, "column": 20}, "end_point": {"row": 65, "column": 44}}, {"id": 114, "type": "function_declarator", "text": "getNumSpaces() const", "parent": 113, "children": [115, 116], "start_point": {"row": 65, "column": 20}, "end_point": {"row": 65, "column": 40}}, {"id": 115, "type": "identifier", "text": "getNumSpaces", "parent": 114, "children": [], "start_point": {"row": 65, "column": 20}, "end_point": {"row": 65, "column": 32}}, {"id": 116, "type": "parameter_list", "text": "()", "parent": 114, "children": [], "start_point": {"row": 65, "column": 32}, "end_point": {"row": 65, "column": 34}}, {"id": 117, "type": "=", "text": "=", "parent": 113, "children": [], "start_point": {"row": 65, "column": 41}, "end_point": {"row": 65, "column": 42}}, {"id": 118, "type": "number_literal", "text": "0", "parent": 113, "children": [], "start_point": {"row": 65, "column": 43}, "end_point": {"row": 65, "column": 44}}, {"id": 119, "type": "declaration", "text": "virtual ISpace*\t\t\t\tgetSpace(index_t index) const = 0;", "parent": 72, "children": [120, 121, 123], "start_point": {"row": 72, "column": 2}, "end_point": {"row": 72, "column": 55}}, {"id": 120, "type": "type_identifier", "text": "virtual", "parent": 119, "children": [], "start_point": {"row": 72, "column": 2}, "end_point": {"row": 72, "column": 9}}, {"id": 121, "type": "ERROR", "text": "ISpace", "parent": 119, "children": [122], "start_point": {"row": 72, "column": 10}, "end_point": {"row": 72, "column": 16}}, {"id": 122, "type": "identifier", "text": "ISpace", "parent": 121, "children": [], "start_point": {"row": 72, "column": 10}, "end_point": {"row": 72, "column": 16}}, {"id": 123, "type": "init_declarator", "text": "*\t\t\t\tgetSpace(index_t index) const = 0", "parent": 119, "children": [124, 132, 133], "start_point": {"row": 72, "column": 16}, "end_point": {"row": 72, "column": 54}}, {"id": 124, "type": "pointer_declarator", "text": "*\t\t\t\tgetSpace(index_t index) const", "parent": 123, "children": [125, 126], "start_point": {"row": 72, "column": 16}, "end_point": {"row": 72, "column": 50}}, {"id": 125, "type": "*", "text": "*", "parent": 124, "children": [], "start_point": {"row": 72, "column": 16}, "end_point": {"row": 72, "column": 17}}, {"id": 126, "type": "function_declarator", "text": "getSpace(index_t index) const", "parent": 124, "children": [127, 128], "start_point": {"row": 72, "column": 21}, "end_point": {"row": 72, "column": 50}}, {"id": 127, "type": "identifier", "text": "getSpace", "parent": 126, "children": [], "start_point": {"row": 72, "column": 21}, "end_point": {"row": 72, "column": 29}}, {"id": 128, "type": "parameter_list", "text": "(index_t index)", "parent": 126, "children": [129], "start_point": {"row": 72, "column": 29}, "end_point": {"row": 72, "column": 44}}, {"id": 129, "type": "parameter_declaration", "text": "index_t index", "parent": 128, "children": [130, 131], "start_point": {"row": 72, "column": 30}, "end_point": {"row": 72, "column": 43}}, {"id": 130, "type": "type_identifier", "text": "index_t", "parent": 129, "children": [], "start_point": {"row": 72, "column": 30}, "end_point": {"row": 72, "column": 37}}, {"id": 131, "type": "identifier", "text": "index", "parent": 129, "children": [], "start_point": {"row": 72, "column": 38}, "end_point": {"row": 72, "column": 43}}, {"id": 132, "type": "=", "text": "=", "parent": 123, "children": [], "start_point": {"row": 72, "column": 51}, "end_point": {"row": 72, "column": 52}}, {"id": 133, "type": "number_literal", "text": "0", "parent": 123, "children": [], "start_point": {"row": 72, "column": 53}, "end_point": {"row": 72, "column": 54}}, {"id": 134, "type": "declaration", "text": "virtual ISpace*\t\t\t\tgetSpace(const TString& name) const = 0;", "parent": 72, "children": [135, 136, 138], "start_point": {"row": 79, "column": 2}, "end_point": {"row": 79, "column": 61}}, {"id": 135, "type": "type_identifier", "text": "virtual", "parent": 134, "children": [], "start_point": {"row": 79, "column": 2}, "end_point": {"row": 79, "column": 9}}, {"id": 136, "type": "ERROR", "text": "ISpace", "parent": 134, "children": [137], "start_point": {"row": 79, "column": 10}, "end_point": {"row": 79, "column": 16}}, {"id": 137, "type": "identifier", "text": "ISpace", "parent": 136, "children": [], "start_point": {"row": 79, "column": 10}, "end_point": {"row": 79, "column": 16}}, {"id": 138, "type": "init_declarator", "text": "*\t\t\t\tgetSpace(const TString& name) const = 0", "parent": 134, "children": [139, 147, 148], "start_point": {"row": 79, "column": 16}, "end_point": {"row": 79, "column": 60}}, {"id": 139, "type": "pointer_declarator", "text": "*\t\t\t\tgetSpace(const TString& name) const", "parent": 138, "children": [140, 141], "start_point": {"row": 79, "column": 16}, "end_point": {"row": 79, "column": 56}}, {"id": 140, "type": "*", "text": "*", "parent": 139, "children": [], "start_point": {"row": 79, "column": 16}, "end_point": {"row": 79, "column": 17}}, {"id": 141, "type": "function_declarator", "text": "getSpace(const TString& name) const", "parent": 139, "children": [142, 143], "start_point": {"row": 79, "column": 21}, "end_point": {"row": 79, "column": 56}}, {"id": 142, "type": "identifier", "text": "getSpace", "parent": 141, "children": [], "start_point": {"row": 79, "column": 21}, "end_point": {"row": 79, "column": 29}}, {"id": 143, "type": "parameter_list", "text": "(const TString& name)", "parent": 141, "children": [144], "start_point": {"row": 79, "column": 29}, "end_point": {"row": 79, "column": 50}}, {"id": 144, "type": "parameter_declaration", "text": "const TString& name", "parent": 143, "children": [145, 146], "start_point": {"row": 79, "column": 30}, "end_point": {"row": 79, "column": 49}}, {"id": 145, "type": "type_identifier", "text": "TString", "parent": 144, "children": [], "start_point": {"row": 79, "column": 36}, "end_point": {"row": 79, "column": 43}}, {"id": 146, "type": "identifier", "text": "name", "parent": 144, "children": [], "start_point": {"row": 79, "column": 45}, "end_point": {"row": 79, "column": 49}}, {"id": 147, "type": "=", "text": "=", "parent": 138, "children": [], "start_point": {"row": 79, "column": 57}, "end_point": {"row": 79, "column": 58}}, {"id": 148, "type": "number_literal", "text": "0", "parent": 138, "children": [], "start_point": {"row": 79, "column": 59}, "end_point": {"row": 79, "column": 60}}, {"id": 149, "type": "declaration", "text": "virtual ISpace*\t\t\t\taddSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false) = 0;", "parent": 72, "children": [150, 151, 153, 173], "start_point": {"row": 86, "column": 2}, "end_point": {"row": 86, "column": 123}}, {"id": 150, "type": "type_identifier", "text": "virtual", "parent": 149, "children": [], "start_point": {"row": 86, "column": 2}, "end_point": {"row": 86, "column": 9}}, {"id": 151, "type": "ERROR", "text": "ISpace", "parent": 149, "children": [152], "start_point": {"row": 86, "column": 10}, "end_point": {"row": 86, "column": 16}}, {"id": 152, "type": "identifier", "text": "ISpace", "parent": 151, "children": [], "start_point": {"row": 86, "column": 10}, "end_point": {"row": 86, "column": 16}}, {"id": 153, "type": "init_declarator", "text": "*\t\t\t\taddSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false", "parent": 149, "children": [154, 171, 172], "start_point": {"row": 86, "column": 16}, "end_point": {"row": 86, "column": 117}}, {"id": 154, "type": "pointer_declarator", "text": "*\t\t\t\taddSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated", "parent": 153, "children": [155, 156], "start_point": {"row": 86, "column": 16}, "end_point": {"row": 86, "column": 109}}, {"id": 155, "type": "*", "text": "*", "parent": 154, "children": [], "start_point": {"row": 86, "column": 16}, "end_point": {"row": 86, "column": 17}}, {"id": 156, "type": "function_declarator", "text": "addSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated", "parent": 154, "children": [157, 158], "start_point": {"row": 86, "column": 21}, "end_point": {"row": 86, "column": 109}}, {"id": 157, "type": "identifier", "text": "addSpace", "parent": 156, "children": [], "start_point": {"row": 86, "column": 21}, "end_point": {"row": 86, "column": 29}}, {"id": 158, "type": "parameter_list", "text": "(const TString& type,const TString& name, const Vector3& maxSize, bool separated", "parent": 156, "children": [159, 162, 165, 168], "start_point": {"row": 86, "column": 29}, "end_point": {"row": 86, "column": 109}}, {"id": 159, "type": "parameter_declaration", "text": "const TString& type", "parent": 158, "children": [160, 161], "start_point": {"row": 86, "column": 30}, "end_point": {"row": 86, "column": 49}}, {"id": 160, "type": "type_identifier", "text": "TString", "parent": 159, "children": [], "start_point": {"row": 86, "column": 36}, "end_point": {"row": 86, "column": 43}}, {"id": 161, "type": "identifier", "text": "type", "parent": 159, "children": [], "start_point": {"row": 86, "column": 45}, "end_point": {"row": 86, "column": 49}}, {"id": 162, "type": "parameter_declaration", "text": "const TString& name", "parent": 158, "children": [163, 164], "start_point": {"row": 86, "column": 50}, "end_point": {"row": 86, "column": 69}}, {"id": 163, "type": "type_identifier", "text": "TString", "parent": 162, "children": [], "start_point": {"row": 86, "column": 56}, "end_point": {"row": 86, "column": 63}}, {"id": 164, "type": "identifier", "text": "name", "parent": 162, "children": [], "start_point": {"row": 86, "column": 65}, "end_point": {"row": 86, "column": 69}}, {"id": 165, "type": "parameter_declaration", "text": "const Vector3& maxSize", "parent": 158, "children": [166, 167], "start_point": {"row": 86, "column": 71}, "end_point": {"row": 86, "column": 93}}, {"id": 166, "type": "type_identifier", "text": "Vector3", "parent": 165, "children": [], "start_point": {"row": 86, "column": 77}, "end_point": {"row": 86, "column": 84}}, {"id": 167, "type": "identifier", "text": "maxSize", "parent": 165, "children": [], "start_point": {"row": 86, "column": 86}, "end_point": {"row": 86, "column": 93}}, {"id": 168, "type": "parameter_declaration", "text": "bool separated", "parent": 158, "children": [169, 170], "start_point": {"row": 86, "column": 95}, "end_point": {"row": 86, "column": 109}}, {"id": 169, "type": "primitive_type", "text": "bool", "parent": 168, "children": [], "start_point": {"row": 86, "column": 95}, "end_point": {"row": 86, "column": 99}}, {"id": 170, "type": "identifier", "text": "separated", "parent": 168, "children": [], "start_point": {"row": 86, "column": 100}, "end_point": {"row": 86, "column": 109}}, {"id": 171, "type": "=", "text": "=", "parent": 153, "children": [], "start_point": {"row": 86, "column": 110}, "end_point": {"row": 86, "column": 111}}, {"id": 172, "type": "false", "text": "false", "parent": 153, "children": [], "start_point": {"row": 86, "column": 112}, "end_point": {"row": 86, "column": 117}}, {"id": 173, "type": "ERROR", "text": ") = 0", "parent": 149, "children": [174, 175], "start_point": {"row": 86, "column": 117}, "end_point": {"row": 86, "column": 122}}, {"id": 174, "type": "=", "text": "=", "parent": 173, "children": [], "start_point": {"row": 86, "column": 119}, "end_point": {"row": 86, "column": 120}}, {"id": 175, "type": "number_literal", "text": "0", "parent": 173, "children": [], "start_point": {"row": 86, "column": 121}, "end_point": {"row": 86, "column": 122}}, {"id": 176, "type": "declaration", "text": "virtual bool\t\t\t\tremoveSpace(const TString& name) = 0;", "parent": 72, "children": [177, 178, 180], "start_point": {"row": 93, "column": 2}, "end_point": {"row": 93, "column": 55}}, {"id": 177, "type": "type_identifier", "text": "virtual", "parent": 176, "children": [], "start_point": {"row": 93, "column": 2}, "end_point": {"row": 93, "column": 9}}, {"id": 178, "type": "ERROR", "text": "bool", "parent": 176, "children": [179], "start_point": {"row": 93, "column": 10}, "end_point": {"row": 93, "column": 14}}, {"id": 179, "type": "identifier", "text": "bool", "parent": 178, "children": [], "start_point": {"row": 93, "column": 10}, "end_point": {"row": 93, "column": 14}}, {"id": 180, "type": "init_declarator", "text": "removeSpace(const TString& name) = 0", "parent": 176, "children": [181, 187, 188], "start_point": {"row": 93, "column": 18}, "end_point": {"row": 93, "column": 54}}, {"id": 181, "type": "function_declarator", "text": "removeSpace(const TString& name)", "parent": 180, "children": [182, 183], "start_point": {"row": 93, "column": 18}, "end_point": {"row": 93, "column": 50}}, {"id": 182, "type": "identifier", "text": "removeSpace", "parent": 181, "children": [], "start_point": {"row": 93, "column": 18}, "end_point": {"row": 93, "column": 29}}, {"id": 183, "type": "parameter_list", "text": "(const TString& name)", "parent": 181, "children": [184], "start_point": {"row": 93, "column": 29}, "end_point": {"row": 93, "column": 50}}, {"id": 184, "type": "parameter_declaration", "text": "const TString& name", "parent": 183, "children": [185, 186], "start_point": {"row": 93, "column": 30}, "end_point": {"row": 93, "column": 49}}, {"id": 185, "type": "type_identifier", "text": "TString", "parent": 184, "children": [], "start_point": {"row": 93, "column": 36}, "end_point": {"row": 93, "column": 43}}, {"id": 186, "type": "identifier", "text": "name", "parent": 184, "children": [], "start_point": {"row": 93, "column": 45}, "end_point": {"row": 93, "column": 49}}, {"id": 187, "type": "=", "text": "=", "parent": 180, "children": [], "start_point": {"row": 93, "column": 51}, "end_point": {"row": 93, "column": 52}}, {"id": 188, "type": "number_literal", "text": "0", "parent": 180, "children": [], "start_point": {"row": 93, "column": 53}, "end_point": {"row": 93, "column": 54}}, {"id": 189, "type": "declaration", "text": "virtual ISpace*\t\t\t\tgetSpaceofPage(index_t x, index_t z) const = 0;", "parent": 72, "children": [190, 191, 193], "start_point": {"row": 100, "column": 2}, "end_point": {"row": 100, "column": 68}}, {"id": 190, "type": "type_identifier", "text": "virtual", "parent": 189, "children": [], "start_point": {"row": 100, "column": 2}, "end_point": {"row": 100, "column": 9}}, {"id": 191, "type": "ERROR", "text": "ISpace", "parent": 189, "children": [192], "start_point": {"row": 100, "column": 10}, "end_point": {"row": 100, "column": 16}}, {"id": 192, "type": "identifier", "text": "ISpace", "parent": 191, "children": [], "start_point": {"row": 100, "column": 10}, "end_point": {"row": 100, "column": 16}}, {"id": 193, "type": "init_declarator", "text": "*\t\t\t\tgetSpaceofPage(index_t x, index_t z) const = 0", "parent": 189, "children": [194, 205, 206], "start_point": {"row": 100, "column": 16}, "end_point": {"row": 100, "column": 67}}, {"id": 194, "type": "pointer_declarator", "text": "*\t\t\t\tgetSpaceofPage(index_t x, index_t z) const", "parent": 193, "children": [195, 196], "start_point": {"row": 100, "column": 16}, "end_point": {"row": 100, "column": 63}}, {"id": 195, "type": "*", "text": "*", "parent": 194, "children": [], "start_point": {"row": 100, "column": 16}, "end_point": {"row": 100, "column": 17}}, {"id": 196, "type": "function_declarator", "text": "getSpaceofPage(index_t x, index_t z) const", "parent": 194, "children": [197, 198], "start_point": {"row": 100, "column": 21}, "end_point": {"row": 100, "column": 63}}, {"id": 197, "type": "identifier", "text": "getSpaceofPage", "parent": 196, "children": [], "start_point": {"row": 100, "column": 21}, "end_point": {"row": 100, "column": 35}}, {"id": 198, "type": "parameter_list", "text": "(index_t x, index_t z)", "parent": 196, "children": [199, 202], "start_point": {"row": 100, "column": 35}, "end_point": {"row": 100, "column": 57}}, {"id": 199, "type": "parameter_declaration", "text": "index_t x", "parent": 198, "children": [200, 201], "start_point": {"row": 100, "column": 36}, "end_point": {"row": 100, "column": 45}}, {"id": 200, "type": "type_identifier", "text": "index_t", "parent": 199, "children": [], "start_point": {"row": 100, "column": 36}, "end_point": {"row": 100, "column": 43}}, {"id": 201, "type": "identifier", "text": "x", "parent": 199, "children": [], "start_point": {"row": 100, "column": 44}, "end_point": {"row": 100, "column": 45}}, {"id": 202, "type": "parameter_declaration", "text": "index_t z", "parent": 198, "children": [203, 204], "start_point": {"row": 100, "column": 47}, "end_point": {"row": 100, "column": 56}}, {"id": 203, "type": "type_identifier", "text": "index_t", "parent": 202, "children": [], "start_point": {"row": 100, "column": 47}, "end_point": {"row": 100, "column": 54}}, {"id": 204, "type": "identifier", "text": "z", "parent": 202, "children": [], "start_point": {"row": 100, "column": 55}, "end_point": {"row": 100, "column": 56}}, {"id": 205, "type": "=", "text": "=", "parent": 193, "children": [], "start_point": {"row": 100, "column": 64}, "end_point": {"row": 100, "column": 65}}, {"id": 206, "type": "number_literal", "text": "0", "parent": 193, "children": [], "start_point": {"row": 100, "column": 66}, "end_point": {"row": 100, "column": 67}}, {"id": 207, "type": "ERROR", "text": "};", "parent": 72, "children": [], "start_point": {"row": 102, "column": 1}, "end_point": {"row": 102, "column": 3}}, {"id": 208, "type": "declaration", "text": "extern template class", "parent": 72, "children": [209, 211], "start_point": {"row": 104, "column": 1}, "end_point": {"row": 104, "column": 22}}, {"id": 209, "type": "storage_class_specifier", "text": "extern", "parent": 208, "children": [210], "start_point": {"row": 104, "column": 1}, "end_point": {"row": 104, "column": 7}}, {"id": 210, "type": "extern", "text": "extern", "parent": 209, "children": [], "start_point": {"row": 104, "column": 1}, "end_point": {"row": 104, "column": 7}}, {"id": 211, "type": "type_identifier", "text": "template", "parent": 208, "children": [], "start_point": {"row": 104, "column": 8}, "end_point": {"row": 104, "column": 16}}, {"id": 212, "type": "declaration", "text": "BLADE_GRAPHICS_API Factory<ISpaceCoordinator>;", "parent": 72, "children": [213, 214, 217, 218], "start_point": {"row": 104, "column": 23}, "end_point": {"row": 104, "column": 69}}, {"id": 213, "type": "type_identifier", "text": "BLADE_GRAPHICS_API", "parent": 212, "children": [], "start_point": {"row": 104, "column": 23}, "end_point": {"row": 104, "column": 41}}, {"id": 214, "type": "ERROR", "text": "Factory<", "parent": 212, "children": [215, 216], "start_point": {"row": 104, "column": 42}, "end_point": {"row": 104, "column": 50}}, {"id": 215, "type": "identifier", "text": "Factory", "parent": 214, "children": [], "start_point": {"row": 104, "column": 42}, "end_point": {"row": 104, "column": 49}}, {"id": 216, "type": "<", "text": "<", "parent": 214, "children": [], "start_point": {"row": 104, "column": 49}, "end_point": {"row": 104, "column": 50}}, {"id": 217, "type": "identifier", "text": "ISpaceCoordinator", "parent": 212, "children": [], "start_point": {"row": 104, "column": 50}, "end_point": {"row": 104, "column": 67}}, {"id": 218, "type": "ERROR", "text": ">", "parent": 212, "children": [219], "start_point": {"row": 104, "column": 67}, "end_point": {"row": 104, "column": 68}}, {"id": 219, "type": ">", "text": ">", "parent": 218, "children": [], "start_point": {"row": 104, "column": 67}, "end_point": {"row": 104, "column": 68}}, {"id": 220, "type": "declaration", "text": "typedef Factory<ISpaceCoordinator> CoordinatorFactory;", "parent": 72, "children": [221, 222, 227], "start_point": {"row": 105, "column": 1}, "end_point": {"row": 105, "column": 55}}, {"id": 221, "type": "type_identifier", "text": "typedef", "parent": 220, "children": [], "start_point": {"row": 105, "column": 1}, "end_point": {"row": 105, "column": 8}}, {"id": 222, "type": "ERROR", "text": "Factory<ISpaceCoordinator>", "parent": 220, "children": [223, 224, 225, 226], "start_point": {"row": 105, "column": 9}, "end_point": {"row": 105, "column": 35}}, {"id": 223, "type": "identifier", "text": "Factory", "parent": 222, "children": [], "start_point": {"row": 105, "column": 9}, "end_point": {"row": 105, "column": 16}}, {"id": 224, "type": "<", "text": "<", "parent": 222, "children": [], "start_point": {"row": 105, "column": 16}, "end_point": {"row": 105, "column": 17}}, {"id": 225, "type": "identifier", "text": "ISpaceCoordinator", "parent": 222, "children": [], "start_point": {"row": 105, "column": 17}, "end_point": {"row": 105, "column": 34}}, {"id": 226, "type": ">", "text": ">", "parent": 222, "children": [], "start_point": {"row": 105, "column": 34}, "end_point": {"row": 105, "column": 35}}, {"id": 227, "type": "identifier", "text": "CoordinatorFactory", "parent": 220, "children": [], "start_point": {"row": 105, "column": 36}, "end_point": {"row": 105, "column": 54}}, {"id": 228, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 110, "column": 0}, "end_point": {"row": 110, "column": 6}}]}, "node_categories": {"declarations": {"functions": [15, 49, 56, 76, 87, 104, 114, 126, 141, 156, 181, 196], "variables": [18, 23, 26, 29, 32, 36, 40, 59, 64, 67, 79, 90, 97, 109, 119, 129, 134, 144, 149, 159, 162, 165, 168, 176, 184, 189, 199, 202, 208, 212, 220], "classes": [20, 21, 209], "imports": [6, 7, 9, 10, 12, 13], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 16, 17, 22, 24, 25, 27, 28, 30, 31, 33, 34, 35, 37, 39, 41, 43, 45, 46, 47, 50, 53, 54, 57, 60, 63, 65, 66, 68, 69, 73, 75, 77, 83, 85, 88, 91, 94, 98, 100, 105, 110, 112, 115, 120, 122, 127, 130, 131, 135, 137, 142, 145, 146, 150, 152, 157, 160, 161, 163, 164, 166, 167, 170, 177, 179, 182, 185, 186, 190, 192, 197, 200, 201, 203, 204, 211, 213, 215, 217, 221, 223, 225, 227, 228], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [8, 11, 14, 71, 82, 96, 108, 118, 133, 148, 175, 188, 206], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 15, "universal_type": "function", "name": "SSpaceCoordinatorDesc", "text_snippet": "namespace Blade\n{\n\t//////////////////////////////////////////////////////////////////////////\n\ttyped"}, {"node_id": 49, "universal_type": "function", "name": "unknown", "text_snippet": "ISpaceCoordinator()"}, {"node_id": 56, "universal_type": "function", "name": "unknown", "text_snippet": "initialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask)"}, {"node_id": 76, "universal_type": "function", "name": "unknown", "text_snippet": "getCoordinatorType()"}, {"node_id": 87, "universal_type": "function", "name": "unknown", "text_snippet": "initialize(const COORDINATOR_DESC* desc)"}, {"node_id": 104, "universal_type": "function", "name": "unknown", "text_snippet": "getDesc() const"}, {"node_id": 114, "universal_type": "function", "name": "unknown", "text_snippet": "getNumSpaces() const"}, {"node_id": 126, "universal_type": "function", "name": "unknown", "text_snippet": "getSpace(index_t index) const"}, {"node_id": 141, "universal_type": "function", "name": "unknown", "text_snippet": "getSpace(const TString& name) const"}, {"node_id": 156, "universal_type": "function", "name": "separated", "text_snippet": "addSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated"}, {"node_id": 181, "universal_type": "function", "name": "unknown", "text_snippet": "removeSpace(const TString& name)"}, {"node_id": 196, "universal_type": "function", "name": "unknown", "text_snippet": "getSpaceofPage(index_t x, index_t z) const"}], "class_declarations": [{"node_id": 20, "universal_type": "class", "name": "SSpaceCoordinatorDesc", "text_snippet": "struct SSpaceCoordinatorDesc\n\t{\n\t\tTString\ttype;\n\t\tTString\tdefaultSpace;\n\t\tuint32\tvisiblePage;\n\t\tuint"}, {"node_id": 21, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}, {"node_id": 209, "universal_type": "class", "name": "unknown", "text_snippet": "extern"}], "import_statements": [{"node_id": 6, "text": "#include <interface/IPage.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <interface/public/graphics/IGraphicsSpaceCoordinator.h>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include <interface/ISpace.h>\n"}, {"node_id": 13, "text": "#include"}]}, "original_source_code": "/********************************************************************\n\tcreated:\t2010/05/07\n\tfilename: \tIGraphicsSpaceCoordinator.h\n\tauthor:\t\tCrazii\n\tpurpose:\t\n*********************************************************************/\n#ifndef __Blade_ISpaceCoordinator_h__\n#define __Blade_ISpaceCoordinator_h__\n#include <interface/IPage.h>\n#include <interface/public/graphics/IGraphicsSpaceCoordinator.h>\n#include <interface/ISpace.h>\n\nnamespace Blade\n{\n\t//////////////////////////////////////////////////////////////////////////\n\ttypedef struct SSpaceCoordinatorDesc\n\t{\n\t\tTString\ttype;\n\t\tTString\tdefaultSpace;\n\t\tuint32\tvisiblePage;\n\t\tuint32\tpageSize;\n\t}COORDINATOR_DESC;\n\n\t//////////////////////////////////////////////////////////////////////////\n\tclass BLADE_GRAPHICS_API ISpaceCoordinator : public IGraphicsSpaceCoordinator, public ISpace, public IPagingManager::IListener\n\t{\n\tpublic:\n\t\tvirtual ~ISpaceCoordinator()\t{}\n\n\t\t/*\n\t\t@describe \n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual bool\t\t\t\tinitialize(ISpaceCoordinator* coorinator, const AABB& maxBound, uint32 partitionMask) = 0;\n\n\t\t/************************************************************************/\n\t\t/* */\n\t\t/************************************************************************/\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual const TString&\t\tgetCoordinatorType() const = 0;\n\n\t\t/*\n\t\t@describe \n\t\t@param \n\t\t@return \n\t\t*/\n\t\tvirtual bool\t\t\t\tinitialize(const COORDINATOR_DESC* desc) = 0;\n\n\t\t/**\n\t\t@describe \n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual const COORDINATOR_DESC*\tgetDesc() const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual size_t\t\t\t\tgetNumSpaces() const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\tgetSpace(index_t index) const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\tgetSpace(const TString& name) const = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\taddSpace(const TString& type,const TString& name, const Vector3& maxSize, bool separated = false) = 0;\n\n\t\t/*\n\t\t@describe\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual bool\t\t\t\tremoveSpace(const TString& name) = 0;\n\n\t\t/**\n\t\t@describe x,z in range of [0,COORDINATOR_DESC.visiblePage)\n\t\t@param\n\t\t@return\n\t\t*/\n\t\tvirtual ISpace*\t\t\t\tgetSpaceofPage(index_t x, index_t z) const = 0;\n\n\t};//class ISpaceCoordinator\n\n\textern template class BLADE_GRAPHICS_API Factory<ISpaceCoordinator>;\n\ttypedef Factory<ISpaceCoordinator> CoordinatorFactory;\n\n}//namespace Blade\n\n\n#endif //__Blade_ISpaceCoordinator_h__"}
80,590
c
/* $NetBSD: machConst.h,v 1.4 1997/06/22 04:09:06 jonathan Exp $ */ #include <mips/cpuregs.h>
30.67
3
(translation_unit) "/* $NetBSD: machConst.h,v 1.4 1997/06/22 04:09:06 jonathan Exp $ */\n\n\n#include <mips/cpuregs.h>\n" (comment) "/* $NetBSD: machConst.h,v 1.4 1997/06/22 04:09:06 jonathan Exp $ */" (preproc_include) "#include <mips/cpuregs.h>\n" (#include) "#include" (system_lib_string) "<mips/cpuregs.h>"
5
0
{"language": "c", "success": true, "metadata": {"lines": 3, "avg_line_length": 30.67, "nodes": 3, "errors": 0, "source_hash": "a2ed058c1a855d1454c896b0245d1f928a479bf7816f8546d23ddda1b22d32f6", "categorized_nodes": 3}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <mips/cpuregs.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<mips/cpuregs.h>", "parent": 0, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 25}}]}, "node_categories": {"declarations": {"functions": [], "variables": [], "classes": [], "imports": [0, 1], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [2], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <mips/cpuregs.h>\n"}, {"node_id": 1, "text": "#include"}]}, "original_source_code": "/*\t$NetBSD: machConst.h,v 1.4 1997/06/22 04:09:06 jonathan Exp $\t*/\n\n\n#include <mips/cpuregs.h>\n"}
80,591
c
#include "lib/stubs/externals/externals_stub.h" #include <stdbool.h> #include <unistd.h> #include <klee/klee.h> static bool pipe_created = false; int pipe(int pipefd[2]) { // http://man7.org/linux/man-pages/man2/pipe.2.html klee_assert(!pipe_created); pipe_created = true; // "The array pipefd is used to return two file descriptors referring to the ends of the pipe. // pipefd[0] refers to the read end of the pipe. // pipefd[1] refers to the write end of the pipe." pipefd[0] = STUB_PIPE_FD_READ; pipefd[1] = STUB_PIPE_FD_WRITE; // "On success, zero is returned. On error, -1 is returned, and errno is set appropriately." return 0; } void stub_pipe_write(const void* buf, size_t len) { // TODO for now, nothing, let's see who reads }
27.92
26
(translation_unit) "#include "lib/stubs/externals/externals_stub.h"\n\n#include <stdbool.h>\n#include <unistd.h>\n\n#include <klee/klee.h>\n\n\nstatic bool pipe_created = false;\n\nint\npipe(int pipefd[2])\n{\n // http://man7.org/linux/man-pages/man2/pipe.2.html\n\n klee_assert(!pipe_created);\n pipe_created = true;\n\n // "The array pipefd is used to return two file descriptors referring to the ends of the pipe.\n // pipefd[0] refers to the read end of the pipe.\n // pipefd[1] refers to the write end of the pipe."\n pipefd[0] = STUB_PIPE_FD_READ;\n pipefd[1] = STUB_PIPE_FD_WRITE;\n\n // "On success, zero is returned. On error, -1 is returned, and errno is set appropriately."\n return 0;\n}\n\n\nvoid\nstub_pipe_write(const void* buf, size_t len)\n{\n // TODO for now, nothing, let's see who reads\n}\n" (preproc_include) "#include "lib/stubs/externals/externals_stub.h"\n" (#include) "#include" (string_literal) ""lib/stubs/externals/externals_stub.h"" (") """ (string_content) "lib/stubs/externals/externals_stub.h" (") """ (preproc_include) "#include <stdbool.h>\n" (#include) "#include" (system_lib_string) "<stdbool.h>" (preproc_include) "#include <unistd.h>\n" (#include) "#include" (system_lib_string) "<unistd.h>" (preproc_include) "#include <klee/klee.h>\n" (#include) "#include" (system_lib_string) "<klee/klee.h>" (declaration) "static bool pipe_created = false;" (storage_class_specifier) "static" (static) "static" (primitive_type) "bool" (init_declarator) "pipe_created = false" (identifier) "pipe_created" (=) "=" (false) "false" (;) ";" (function_definition) "int\npipe(int pipefd[2])\n{\n // http://man7.org/linux/man-pages/man2/pipe.2.html\n\n klee_assert(!pipe_created);\n pipe_created = true;\n\n // "The array pipefd is used to return two file descriptors referring to the ends of the pipe.\n // pipefd[0] refers to the read end of the pipe.\n // pipefd[1] refers to the write end of the pipe."\n pipefd[0] = STUB_PIPE_FD_READ;\n pipefd[1] = STUB_PIPE_FD_WRITE;\n\n // "On success, zero is returned. On error, -1 is returned, and errno is set appropriately."\n return 0;\n}" (primitive_type) "int" (function_declarator) "pipe(int pipefd[2])" (identifier) "pipe" (parameter_list) "(int pipefd[2])" (() "(" (parameter_declaration) "int pipefd[2]" (primitive_type) "int" (array_declarator) "pipefd[2]" (identifier) "pipefd" ([) "[" (number_literal) "2" (]) "]" ()) ")" (compound_statement) "{\n // http://man7.org/linux/man-pages/man2/pipe.2.html\n\n klee_assert(!pipe_created);\n pipe_created = true;\n\n // "The array pipefd is used to return two file descriptors referring to the ends of the pipe.\n // pipefd[0] refers to the read end of the pipe.\n // pipefd[1] refers to the write end of the pipe."\n pipefd[0] = STUB_PIPE_FD_READ;\n pipefd[1] = STUB_PIPE_FD_WRITE;\n\n // "On success, zero is returned. On error, -1 is returned, and errno is set appropriately."\n return 0;\n}" ({) "{" (comment) "// http://man7.org/linux/man-pages/man2/pipe.2.html" (expression_statement) "klee_assert(!pipe_created);" (call_expression) "klee_assert(!pipe_created)" (identifier) "klee_assert" (argument_list) "(!pipe_created)" (() "(" (unary_expression) "!pipe_created" (!) "!" (identifier) "pipe_created" ()) ")" (;) ";" (expression_statement) "pipe_created = true;" (assignment_expression) "pipe_created = true" (identifier) "pipe_created" (=) "=" (true) "true" (;) ";" (comment) "// "The array pipefd is used to return two file descriptors referring to the ends of the pipe." (comment) "// pipefd[0] refers to the read end of the pipe." (comment) "// pipefd[1] refers to the write end of the pipe."" (expression_statement) "pipefd[0] = STUB_PIPE_FD_READ;" (assignment_expression) "pipefd[0] = STUB_PIPE_FD_READ" (subscript_expression) "pipefd[0]" (identifier) "pipefd" ([) "[" (number_literal) "0" (]) "]" (=) "=" (identifier) "STUB_PIPE_FD_READ" (;) ";" (expression_statement) "pipefd[1] = STUB_PIPE_FD_WRITE;" (assignment_expression) "pipefd[1] = STUB_PIPE_FD_WRITE" (subscript_expression) "pipefd[1]" (identifier) "pipefd" ([) "[" (number_literal) "1" (]) "]" (=) "=" (identifier) "STUB_PIPE_FD_WRITE" (;) ";" (comment) "// "On success, zero is returned. On error, -1 is returned, and errno is set appropriately."" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}" (function_definition) "void\nstub_pipe_write(const void* buf, size_t len)\n{\n // TODO for now, nothing, let's see who reads\n}" (primitive_type) "void" (function_declarator) "stub_pipe_write(const void* buf, size_t len)" (identifier) "stub_pipe_write" (parameter_list) "(const void* buf, size_t len)" (() "(" (parameter_declaration) "const void* buf" (type_qualifier) "const" (const) "const" (primitive_type) "void" (pointer_declarator) "* buf" (*) "*" (identifier) "buf" (,) "," (parameter_declaration) "size_t len" (primitive_type) "size_t" (identifier) "len" ()) ")" (compound_statement) "{\n // TODO for now, nothing, let's see who reads\n}" ({) "{" (comment) "// TODO for now, nothing, let's see who reads" (}) "}"
109
0
{"language": "c", "success": true, "metadata": {"lines": 26, "avg_line_length": 27.92, "nodes": 65, "errors": 0, "source_hash": "f0fffca7c9e17f4880ec0ca1cd797cb4e5b6cc1e0edd5332347d7a52306ac4fd", "categorized_nodes": 45}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"lib/stubs/externals/externals_stub.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"lib/stubs/externals/externals_stub.h\"", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 47}}, {"id": 3, "type": "preproc_include", "text": "#include <stdbool.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<stdbool.h>", "parent": 3, "children": [], "start_point": {"row": 2, "column": 9}, "end_point": {"row": 2, "column": 20}}, {"id": 6, "type": "preproc_include", "text": "#include <unistd.h>\n", "parent": null, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 4, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<unistd.h>", "parent": 6, "children": [], "start_point": {"row": 3, "column": 9}, "end_point": {"row": 3, "column": 19}}, {"id": 9, "type": "preproc_include", "text": "#include <klee/klee.h>\n", "parent": null, "children": [10, 11], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<klee/klee.h>", "parent": 9, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 22}}, {"id": 12, "type": "declaration", "text": "static bool pipe_created = false;", "parent": null, "children": [13, 14], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 33}}, {"id": 13, "type": "primitive_type", "text": "bool", "parent": 12, "children": [], "start_point": {"row": 8, "column": 7}, "end_point": {"row": 8, "column": 11}}, {"id": 14, "type": "init_declarator", "text": "pipe_created = false", "parent": 12, "children": [15, 16, 17], "start_point": {"row": 8, "column": 12}, "end_point": {"row": 8, "column": 32}}, {"id": 15, "type": "identifier", "text": "pipe_created", "parent": 14, "children": [], "start_point": {"row": 8, "column": 12}, "end_point": {"row": 8, "column": 24}}, {"id": 16, "type": "=", "text": "=", "parent": 14, "children": [], "start_point": {"row": 8, "column": 25}, "end_point": {"row": 8, "column": 26}}, {"id": 17, "type": "false", "text": "false", "parent": 14, "children": [], "start_point": {"row": 8, "column": 27}, "end_point": {"row": 8, "column": 32}}, {"id": 18, "type": "function_definition", "text": "int\npipe(int pipefd[2])\n{\n\t// http://man7.org/linux/man-pages/man2/pipe.2.html\n\n\tklee_assert(!pipe_created);\n\tpipe_created = true;\n\n\t// \"The array pipefd is used to return two file descriptors referring to the ends of the pipe.\n\t// pipefd[0] refers to the read end of the pipe.\n\t// pipefd[1] refers to the write end of the pipe.\"\n\tpipefd[0] = STUB_PIPE_FD_READ;\n\tpipefd[1] = STUB_PIPE_FD_WRITE;\n\n\t// \"On success, zero is returned. On error, -1 is returned, and errno is set appropriately.\"\n\treturn 0;\n}", "parent": null, "children": [19, 20], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 26, "column": 1}}, {"id": 19, "type": "primitive_type", "text": "int", "parent": 18, "children": [], "start_point": {"row": 10, "column": 0}, "end_point": {"row": 10, "column": 3}}, {"id": 20, "type": "function_declarator", "text": "pipe(int pipefd[2])", "parent": 18, "children": [21, 22], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 19}}, {"id": 21, "type": "identifier", "text": "pipe", "parent": 20, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 4}}, {"id": 22, "type": "parameter_list", "text": "(int pipefd[2])", "parent": 20, "children": [23], "start_point": {"row": 11, "column": 4}, "end_point": {"row": 11, "column": 19}}, {"id": 23, "type": "parameter_declaration", "text": "int pipefd[2]", "parent": 22, "children": [24, 25], "start_point": {"row": 11, "column": 5}, "end_point": {"row": 11, "column": 18}}, {"id": 24, "type": "primitive_type", "text": "int", "parent": 23, "children": [], "start_point": {"row": 11, "column": 5}, "end_point": {"row": 11, "column": 8}}, {"id": 25, "type": "array_declarator", "text": "pipefd[2]", "parent": 23, "children": [26, 27], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 18}}, {"id": 26, "type": "identifier", "text": "pipefd", "parent": 25, "children": [], "start_point": {"row": 11, "column": 9}, "end_point": {"row": 11, "column": 15}}, {"id": 27, "type": "number_literal", "text": "2", "parent": 25, "children": [], "start_point": {"row": 11, "column": 16}, "end_point": {"row": 11, "column": 17}}, {"id": 28, "type": "call_expression", "text": "klee_assert(!pipe_created)", "parent": 18, "children": [29, 30], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 27}}, {"id": 29, "type": "identifier", "text": "klee_assert", "parent": 28, "children": [], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 12}}, {"id": 30, "type": "argument_list", "text": "(!pipe_created)", "parent": 28, "children": [31], "start_point": {"row": 15, "column": 12}, "end_point": {"row": 15, "column": 27}}, {"id": 31, "type": "unary_expression", "text": "!pipe_created", "parent": 30, "children": [32, 33], "start_point": {"row": 15, "column": 13}, "end_point": {"row": 15, "column": 26}}, {"id": 32, "type": "!", "text": "!", "parent": 31, "children": [], "start_point": {"row": 15, "column": 13}, "end_point": {"row": 15, "column": 14}}, {"id": 33, "type": "identifier", "text": "pipe_created", "parent": 31, "children": [], "start_point": {"row": 15, "column": 14}, "end_point": {"row": 15, "column": 26}}, {"id": 34, "type": "assignment_expression", "text": "pipe_created = true", "parent": 18, "children": [35, 36, 37], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 20}}, {"id": 35, "type": "identifier", "text": "pipe_created", "parent": 34, "children": [], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 13}}, {"id": 36, "type": "=", "text": "=", "parent": 34, "children": [], "start_point": {"row": 16, "column": 14}, "end_point": {"row": 16, "column": 15}}, {"id": 37, "type": "true", "text": "true", "parent": 34, "children": [], "start_point": {"row": 16, "column": 16}, "end_point": {"row": 16, "column": 20}}, {"id": 38, "type": "assignment_expression", "text": "pipefd[0] = STUB_PIPE_FD_READ", "parent": 18, "children": [39, 42, 43], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 30}}, {"id": 39, "type": "subscript_expression", "text": "pipefd[0]", "parent": 38, "children": [40, 41], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 10}}, {"id": 40, "type": "identifier", "text": "pipefd", "parent": 39, "children": [], "start_point": {"row": 21, "column": 1}, "end_point": {"row": 21, "column": 7}}, {"id": 41, "type": "number_literal", "text": "0", "parent": 39, "children": [], "start_point": {"row": 21, "column": 8}, "end_point": {"row": 21, "column": 9}}, {"id": 42, "type": "=", "text": "=", "parent": 38, "children": [], "start_point": {"row": 21, "column": 11}, "end_point": {"row": 21, "column": 12}}, {"id": 43, "type": "identifier", "text": "STUB_PIPE_FD_READ", "parent": 38, "children": [], "start_point": {"row": 21, "column": 13}, "end_point": {"row": 21, "column": 30}}, {"id": 44, "type": "assignment_expression", "text": "pipefd[1] = STUB_PIPE_FD_WRITE", "parent": 18, "children": [45, 48, 49], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 31}}, {"id": 45, "type": "subscript_expression", "text": "pipefd[1]", "parent": 44, "children": [46, 47], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 10}}, {"id": 46, "type": "identifier", "text": "pipefd", "parent": 45, "children": [], "start_point": {"row": 22, "column": 1}, "end_point": {"row": 22, "column": 7}}, {"id": 47, "type": "number_literal", "text": "1", "parent": 45, "children": [], "start_point": {"row": 22, "column": 8}, "end_point": {"row": 22, "column": 9}}, {"id": 48, "type": "=", "text": "=", "parent": 44, "children": [], "start_point": {"row": 22, "column": 11}, "end_point": {"row": 22, "column": 12}}, {"id": 49, "type": "identifier", "text": "STUB_PIPE_FD_WRITE", "parent": 44, "children": [], "start_point": {"row": 22, "column": 13}, "end_point": {"row": 22, "column": 31}}, {"id": 50, "type": "return_statement", "text": "return 0;", "parent": 18, "children": [51], "start_point": {"row": 25, "column": 1}, "end_point": {"row": 25, "column": 10}}, {"id": 51, "type": "number_literal", "text": "0", "parent": 50, "children": [], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 9}}, {"id": 52, "type": "function_definition", "text": "void\nstub_pipe_write(const void* buf, size_t len)\n{\n\t// TODO for now, nothing, let's see who reads\n}", "parent": null, "children": [53, 54], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 33, "column": 1}}, {"id": 53, "type": "primitive_type", "text": "void", "parent": 52, "children": [], "start_point": {"row": 29, "column": 0}, "end_point": {"row": 29, "column": 4}}, {"id": 54, "type": "function_declarator", "text": "stub_pipe_write(const void* buf, size_t len)", "parent": 52, "children": [55, 56], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 44}}, {"id": 55, "type": "identifier", "text": "stub_pipe_write", "parent": 54, "children": [], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 15}}, {"id": 56, "type": "parameter_list", "text": "(const void* buf, size_t len)", "parent": 54, "children": [57, 62], "start_point": {"row": 30, "column": 15}, "end_point": {"row": 30, "column": 44}}, {"id": 57, "type": "parameter_declaration", "text": "const void* buf", "parent": 56, "children": [58, 59], "start_point": {"row": 30, "column": 16}, "end_point": {"row": 30, "column": 31}}, {"id": 58, "type": "primitive_type", "text": "void", "parent": 57, "children": [], "start_point": {"row": 30, "column": 22}, "end_point": {"row": 30, "column": 26}}, {"id": 59, "type": "pointer_declarator", "text": "* buf", "parent": 57, "children": [60, 61], "start_point": {"row": 30, "column": 26}, "end_point": {"row": 30, "column": 31}}, {"id": 60, "type": "*", "text": "*", "parent": 59, "children": [], "start_point": {"row": 30, "column": 26}, "end_point": {"row": 30, "column": 27}}, {"id": 61, "type": "identifier", "text": "buf", "parent": 59, "children": [], "start_point": {"row": 30, "column": 28}, "end_point": {"row": 30, "column": 31}}, {"id": 62, "type": "parameter_declaration", "text": "size_t len", "parent": 56, "children": [63, 64], "start_point": {"row": 30, "column": 33}, "end_point": {"row": 30, "column": 43}}, {"id": 63, "type": "primitive_type", "text": "size_t", "parent": 62, "children": [], "start_point": {"row": 30, "column": 33}, "end_point": {"row": 30, "column": 39}}, {"id": 64, "type": "identifier", "text": "len", "parent": 62, "children": [], "start_point": {"row": 30, "column": 40}, "end_point": {"row": 30, "column": 43}}]}, "node_categories": {"declarations": {"functions": [18, 20, 52, 54], "variables": [12, 23, 57, 62], "classes": [], "imports": [0, 1, 3, 4, 6, 7, 9, 10], "modules": [], "enums": []}, "statements": {"expressions": [28, 31, 39, 45], "assignments": [34, 38, 44], "loops": [], "conditionals": [15, 21, 26, 29, 33, 35, 40, 43, 46, 49, 55, 61, 64], "returns": [50], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 8, 11, 27, 41, 47, 51], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 18, "universal_type": "function", "name": "pipe", "text_snippet": "int\npipe(int pipefd[2])\n{\n\t// http://man7.org/linux/man-pages/man2/pipe.2.html\n\n\tklee_assert(!pipe_c"}, {"node_id": 20, "universal_type": "function", "name": "unknown", "text_snippet": "pipe(int pipefd[2])"}, {"node_id": 52, "universal_type": "function", "name": "stub_pipe_write", "text_snippet": "void\nstub_pipe_write(const void* buf, size_t len)\n{\n\t// TODO for now, nothing, let's see who reads\n}"}, {"node_id": 54, "universal_type": "function", "name": "unknown", "text_snippet": "stub_pipe_write(const void* buf, size_t len)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include \"lib/stubs/externals/externals_stub.h\"\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <stdbool.h>\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include <unistd.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <klee/klee.h>\n"}, {"node_id": 10, "text": "#include"}]}, "original_source_code": "#include \"lib/stubs/externals/externals_stub.h\"\n\n#include <stdbool.h>\n#include <unistd.h>\n\n#include <klee/klee.h>\n\n\nstatic bool pipe_created = false;\n\nint\npipe(int pipefd[2])\n{\n\t// http://man7.org/linux/man-pages/man2/pipe.2.html\n\n\tklee_assert(!pipe_created);\n\tpipe_created = true;\n\n\t// \"The array pipefd is used to return two file descriptors referring to the ends of the pipe.\n\t// pipefd[0] refers to the read end of the pipe.\n\t// pipefd[1] refers to the write end of the pipe.\"\n\tpipefd[0] = STUB_PIPE_FD_READ;\n\tpipefd[1] = STUB_PIPE_FD_WRITE;\n\n\t// \"On success, zero is returned. On error, -1 is returned, and errno is set appropriately.\"\n\treturn 0;\n}\n\n\nvoid\nstub_pipe_write(const void* buf, size_t len)\n{\n\t// TODO for now, nothing, let's see who reads\n}\n"}
80,592
c
// This is a personal academic project. Dear PVS-Studio, please check it. // PVS-Studio Static Code Analyzer for C, C++ and C#: http://www.viva64.com // This is a personal academic project. Dear PVS-Studio, please check it. // PVS-Studio Static Code Analyzer for C, C++ and C#: http://www.viva64.com #include "include/test_mm.h" #define MAX_BLOCKS 128 #define MAX_MEMORY 1024 //Should be around 80% of memory managed by the MM typedef struct MM_rq{ void *address; uint32_t size; }mm_rq; void test_mm(){ mm_rq mm_rqs[MAX_BLOCKS]; while (1){ uint8_t rq = 0; int32_t total = 0; // Request as many blocks as we can while(rq < MAX_BLOCKS && total < MAX_MEMORY){ mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1; mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size); // TODO: Port this call as required if(mm_rqs[rq].address == 0) { printfd("malloc: NULL pointer returned\n"); // exit(-1); break; } total += mm_rqs[rq].size; rq++; } // Set uint32_t i; for (i = 0; i < rq; i++) if (mm_rqs[i].address != 0) memset(mm_rqs[i].address, i, mm_rqs[i].size); // TODO: Port this call as required // Check for (i = 0; i < rq; i++) if (mm_rqs[i].address != 0) if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size)) printfd("memcheck: ERROR!\n"); // TODO: Port this call as required // Free for (i = 0; i < rq; i++) if (mm_rqs[i].address != 0) sys_free(mm_rqs[i].address); // TODO: Port this call as required } } int main_test_mm(int argc, char **argv) { test_mm(); sys_sem_post("pipe"); return 0; }
33.02
49
(translation_unit) "// This is a personal academic project. Dear PVS-Studio, please check it.\n// PVS-Studio Static Code Analyzer for C, C++ and C#: http://www.viva64.com\n// This is a personal academic project. Dear PVS-Studio, please check it.\n// PVS-Studio Static Code Analyzer for C, C++ and C#: http://www.viva64.com\n#include "include/test_mm.h"\n\n#define MAX_BLOCKS 128\n#define MAX_MEMORY 1024 //Should be around 80% of memory managed by the MM\n\ntypedef struct MM_rq{\n void *address;\n uint32_t size;\n}mm_rq;\n\nvoid test_mm(){\n mm_rq mm_rqs[MAX_BLOCKS];\n while (1){\n uint8_t rq = 0;\n int32_t total = 0;\n\n // Request as many blocks as we can\n while(rq < MAX_BLOCKS && total < MAX_MEMORY){\n mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1;\n mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size); // TODO: Port this call as required\n if(mm_rqs[rq].address == 0) {\n printfd("malloc: NULL pointer returned\n");\n // exit(-1);\n break;\n }\n total += mm_rqs[rq].size;\n rq++;\n }\n\n // Set\n uint32_t i;\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n memset(mm_rqs[i].address, i, mm_rqs[i].size); // TODO: Port this call as required\n\n // Check\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd("memcheck: ERROR!\n"); // TODO: Port this call as required\n\n // Free\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n sys_free(mm_rqs[i].address); // TODO: Port this call as required\n } \n}\n\nint main_test_mm(int argc, char **argv) {\n test_mm();\n sys_sem_post("pipe");\n return 0;\n}" (comment) "// This is a personal academic project. Dear PVS-Studio, please check it." (comment) "// PVS-Studio Static Code Analyzer for C, C++ and C#: http://www.viva64.com" (comment) "// This is a personal academic project. Dear PVS-Studio, please check it." (comment) "// PVS-Studio Static Code Analyzer for C, C++ and C#: http://www.viva64.com" (preproc_include) "#include "include/test_mm.h"\n" (#include) "#include" (string_literal) ""include/test_mm.h"" (") """ (string_content) "include/test_mm.h" (") """ (preproc_def) "#define MAX_BLOCKS 128\n" (#define) "#define" (identifier) "MAX_BLOCKS" (preproc_arg) "128" (preproc_def) "#define MAX_MEMORY 1024 //Should be around 80% of memory managed by the MM\n" (#define) "#define" (identifier) "MAX_MEMORY" (preproc_arg) "1024 //Should be around 80% of memory managed by the MM" (type_definition) "typedef struct MM_rq{\n void *address;\n uint32_t size;\n}mm_rq;" (typedef) "typedef" (struct_specifier) "struct MM_rq{\n void *address;\n uint32_t size;\n}" (struct) "struct" (type_identifier) "MM_rq" (field_declaration_list) "{\n void *address;\n uint32_t size;\n}" ({) "{" (field_declaration) "void *address;" (primitive_type) "void" (pointer_declarator) "*address" (*) "*" (field_identifier) "address" (;) ";" (field_declaration) "uint32_t size;" (primitive_type) "uint32_t" (field_identifier) "size" (;) ";" (}) "}" (type_identifier) "mm_rq" (;) ";" (function_definition) "void test_mm(){\n mm_rq mm_rqs[MAX_BLOCKS];\n while (1){\n uint8_t rq = 0;\n int32_t total = 0;\n\n // Request as many blocks as we can\n while(rq < MAX_BLOCKS && total < MAX_MEMORY){\n mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1;\n mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size); // TODO: Port this call as required\n if(mm_rqs[rq].address == 0) {\n printfd("malloc: NULL pointer returned\n");\n // exit(-1);\n break;\n }\n total += mm_rqs[rq].size;\n rq++;\n }\n\n // Set\n uint32_t i;\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n memset(mm_rqs[i].address, i, mm_rqs[i].size); // TODO: Port this call as required\n\n // Check\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd("memcheck: ERROR!\n"); // TODO: Port this call as required\n\n // Free\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n sys_free(mm_rqs[i].address); // TODO: Port this call as required\n } \n}" (primitive_type) "void" (function_declarator) "test_mm()" (identifier) "test_mm" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{\n mm_rq mm_rqs[MAX_BLOCKS];\n while (1){\n uint8_t rq = 0;\n int32_t total = 0;\n\n // Request as many blocks as we can\n while(rq < MAX_BLOCKS && total < MAX_MEMORY){\n mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1;\n mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size); // TODO: Port this call as required\n if(mm_rqs[rq].address == 0) {\n printfd("malloc: NULL pointer returned\n");\n // exit(-1);\n break;\n }\n total += mm_rqs[rq].size;\n rq++;\n }\n\n // Set\n uint32_t i;\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n memset(mm_rqs[i].address, i, mm_rqs[i].size); // TODO: Port this call as required\n\n // Check\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd("memcheck: ERROR!\n"); // TODO: Port this call as required\n\n // Free\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n sys_free(mm_rqs[i].address); // TODO: Port this call as required\n } \n}" ({) "{" (declaration) "mm_rq mm_rqs[MAX_BLOCKS];" (type_identifier) "mm_rq" (array_declarator) "mm_rqs[MAX_BLOCKS]" (identifier) "mm_rqs" ([) "[" (identifier) "MAX_BLOCKS" (]) "]" (;) ";" (while_statement) "while (1){\n uint8_t rq = 0;\n int32_t total = 0;\n\n // Request as many blocks as we can\n while(rq < MAX_BLOCKS && total < MAX_MEMORY){\n mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1;\n mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size); // TODO: Port this call as required\n if(mm_rqs[rq].address == 0) {\n printfd("malloc: NULL pointer returned\n");\n // exit(-1);\n break;\n }\n total += mm_rqs[rq].size;\n rq++;\n }\n\n // Set\n uint32_t i;\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n memset(mm_rqs[i].address, i, mm_rqs[i].size); // TODO: Port this call as required\n\n // Check\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd("memcheck: ERROR!\n"); // TODO: Port this call as required\n\n // Free\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n sys_free(mm_rqs[i].address); // TODO: Port this call as required\n }" (while) "while" (parenthesized_expression) "(1)" (() "(" (number_literal) "1" ()) ")" (compound_statement) "{\n uint8_t rq = 0;\n int32_t total = 0;\n\n // Request as many blocks as we can\n while(rq < MAX_BLOCKS && total < MAX_MEMORY){\n mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1;\n mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size); // TODO: Port this call as required\n if(mm_rqs[rq].address == 0) {\n printfd("malloc: NULL pointer returned\n");\n // exit(-1);\n break;\n }\n total += mm_rqs[rq].size;\n rq++;\n }\n\n // Set\n uint32_t i;\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n memset(mm_rqs[i].address, i, mm_rqs[i].size); // TODO: Port this call as required\n\n // Check\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd("memcheck: ERROR!\n"); // TODO: Port this call as required\n\n // Free\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n sys_free(mm_rqs[i].address); // TODO: Port this call as required\n }" ({) "{" (declaration) "uint8_t rq = 0;" (primitive_type) "uint8_t" (init_declarator) "rq = 0" (identifier) "rq" (=) "=" (number_literal) "0" (;) ";" (declaration) "int32_t total = 0;" (primitive_type) "int32_t" (init_declarator) "total = 0" (identifier) "total" (=) "=" (number_literal) "0" (;) ";" (comment) "// Request as many blocks as we can" (while_statement) "while(rq < MAX_BLOCKS && total < MAX_MEMORY){\n mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1;\n mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size); // TODO: Port this call as required\n if(mm_rqs[rq].address == 0) {\n printfd("malloc: NULL pointer returned\n");\n // exit(-1);\n break;\n }\n total += mm_rqs[rq].size;\n rq++;\n }" (while) "while" (parenthesized_expression) "(rq < MAX_BLOCKS && total < MAX_MEMORY)" (() "(" (binary_expression) "rq < MAX_BLOCKS && total < MAX_MEMORY" (binary_expression) "rq < MAX_BLOCKS" (identifier) "rq" (<) "<" (identifier) "MAX_BLOCKS" (&&) "&&" (binary_expression) "total < MAX_MEMORY" (identifier) "total" (<) "<" (identifier) "MAX_MEMORY" ()) ")" (compound_statement) "{\n mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1;\n mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size); // TODO: Port this call as required\n if(mm_rqs[rq].address == 0) {\n printfd("malloc: NULL pointer returned\n");\n // exit(-1);\n break;\n }\n total += mm_rqs[rq].size;\n rq++;\n }" ({) "{" (expression_statement) "mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1;" (assignment_expression) "mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1" (field_expression) "mm_rqs[rq].size" (subscript_expression) "mm_rqs[rq]" (identifier) "mm_rqs" ([) "[" (identifier) "rq" (]) "]" (.) "." (field_identifier) "size" (=) "=" (binary_expression) "GetUniform(MAX_MEMORY - total - 1) + 1" (call_expression) "GetUniform(MAX_MEMORY - total - 1)" (identifier) "GetUniform" (argument_list) "(MAX_MEMORY - total - 1)" (() "(" (binary_expression) "MAX_MEMORY - total - 1" (binary_expression) "MAX_MEMORY - total" (identifier) "MAX_MEMORY" (-) "-" (identifier) "total" (-) "-" (number_literal) "1" ()) ")" (+) "+" (number_literal) "1" (;) ";" (expression_statement) "mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size);" (assignment_expression) "mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size)" (field_expression) "mm_rqs[rq].address" (subscript_expression) "mm_rqs[rq]" (identifier) "mm_rqs" ([) "[" (identifier) "rq" (]) "]" (.) "." (field_identifier) "address" (=) "=" (call_expression) "sys_malloc(mm_rqs[rq].size)" (identifier) "sys_malloc" (argument_list) "(mm_rqs[rq].size)" (() "(" (field_expression) "mm_rqs[rq].size" (subscript_expression) "mm_rqs[rq]" (identifier) "mm_rqs" ([) "[" (identifier) "rq" (]) "]" (.) "." (field_identifier) "size" ()) ")" (;) ";" (comment) "// TODO: Port this call as required" (if_statement) "if(mm_rqs[rq].address == 0) {\n printfd("malloc: NULL pointer returned\n");\n // exit(-1);\n break;\n }" (if) "if" (parenthesized_expression) "(mm_rqs[rq].address == 0)" (() "(" (binary_expression) "mm_rqs[rq].address == 0" (field_expression) "mm_rqs[rq].address" (subscript_expression) "mm_rqs[rq]" (identifier) "mm_rqs" ([) "[" (identifier) "rq" (]) "]" (.) "." (field_identifier) "address" (==) "==" (number_literal) "0" ()) ")" (compound_statement) "{\n printfd("malloc: NULL pointer returned\n");\n // exit(-1);\n break;\n }" ({) "{" (expression_statement) "printfd("malloc: NULL pointer returned\n");" (call_expression) "printfd("malloc: NULL pointer returned\n")" (identifier) "printfd" (argument_list) "("malloc: NULL pointer returned\n")" (() "(" (string_literal) ""malloc: NULL pointer returned\n"" (") """ (string_content) "malloc: NULL pointer returned" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (comment) "// exit(-1);" (break_statement) "break;" (break) "break" (;) ";" (}) "}" (expression_statement) "total += mm_rqs[rq].size;" (assignment_expression) "total += mm_rqs[rq].size" (identifier) "total" (+=) "+=" (field_expression) "mm_rqs[rq].size" (subscript_expression) "mm_rqs[rq]" (identifier) "mm_rqs" ([) "[" (identifier) "rq" (]) "]" (.) "." (field_identifier) "size" (;) ";" (expression_statement) "rq++;" (update_expression) "rq++" (identifier) "rq" (++) "++" (;) ";" (}) "}" (comment) "// Set" (declaration) "uint32_t i;" (primitive_type) "uint32_t" (identifier) "i" (;) ";" (for_statement) "for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n memset(mm_rqs[i].address, i, mm_rqs[i].size);" (for) "for" (() "(" (assignment_expression) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i < rq" (identifier) "i" (<) "<" (identifier) "rq" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (if_statement) "if (mm_rqs[i].address != 0)\n memset(mm_rqs[i].address, i, mm_rqs[i].size);" (if) "if" (parenthesized_expression) "(mm_rqs[i].address != 0)" (() "(" (binary_expression) "mm_rqs[i].address != 0" (field_expression) "mm_rqs[i].address" (subscript_expression) "mm_rqs[i]" (identifier) "mm_rqs" ([) "[" (identifier) "i" (]) "]" (.) "." (field_identifier) "address" (!=) "!=" (number_literal) "0" ()) ")" (expression_statement) "memset(mm_rqs[i].address, i, mm_rqs[i].size);" (call_expression) "memset(mm_rqs[i].address, i, mm_rqs[i].size)" (identifier) "memset" (argument_list) "(mm_rqs[i].address, i, mm_rqs[i].size)" (() "(" (field_expression) "mm_rqs[i].address" (subscript_expression) "mm_rqs[i]" (identifier) "mm_rqs" ([) "[" (identifier) "i" (]) "]" (.) "." (field_identifier) "address" (,) "," (identifier) "i" (,) "," (field_expression) "mm_rqs[i].size" (subscript_expression) "mm_rqs[i]" (identifier) "mm_rqs" ([) "[" (identifier) "i" (]) "]" (.) "." (field_identifier) "size" ()) ")" (;) ";" (comment) "// TODO: Port this call as required" (comment) "// Check" (for_statement) "for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd("memcheck: ERROR!\n");" (for) "for" (() "(" (assignment_expression) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i < rq" (identifier) "i" (<) "<" (identifier) "rq" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (if_statement) "if (mm_rqs[i].address != 0)\n if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd("memcheck: ERROR!\n");" (if) "if" (parenthesized_expression) "(mm_rqs[i].address != 0)" (() "(" (binary_expression) "mm_rqs[i].address != 0" (field_expression) "mm_rqs[i].address" (subscript_expression) "mm_rqs[i]" (identifier) "mm_rqs" ([) "[" (identifier) "i" (]) "]" (.) "." (field_identifier) "address" (!=) "!=" (number_literal) "0" ()) ")" (if_statement) "if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd("memcheck: ERROR!\n");" (if) "if" (parenthesized_expression) "(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))" (() "(" (unary_expression) "!memcheck(mm_rqs[i].address, i, mm_rqs[i].size)" (!) "!" (call_expression) "memcheck(mm_rqs[i].address, i, mm_rqs[i].size)" (identifier) "memcheck" (argument_list) "(mm_rqs[i].address, i, mm_rqs[i].size)" (() "(" (field_expression) "mm_rqs[i].address" (subscript_expression) "mm_rqs[i]" (identifier) "mm_rqs" ([) "[" (identifier) "i" (]) "]" (.) "." (field_identifier) "address" (,) "," (identifier) "i" (,) "," (field_expression) "mm_rqs[i].size" (subscript_expression) "mm_rqs[i]" (identifier) "mm_rqs" ([) "[" (identifier) "i" (]) "]" (.) "." (field_identifier) "size" ()) ")" ()) ")" (expression_statement) "printfd("memcheck: ERROR!\n");" (call_expression) "printfd("memcheck: ERROR!\n")" (identifier) "printfd" (argument_list) "("memcheck: ERROR!\n")" (() "(" (string_literal) ""memcheck: ERROR!\n"" (") """ (string_content) "memcheck: ERROR!" (escape_sequence) "\n" (") """ ()) ")" (;) ";" (comment) "// TODO: Port this call as required" (comment) "// Free" (for_statement) "for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n sys_free(mm_rqs[i].address);" (for) "for" (() "(" (assignment_expression) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i < rq" (identifier) "i" (<) "<" (identifier) "rq" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (if_statement) "if (mm_rqs[i].address != 0)\n sys_free(mm_rqs[i].address);" (if) "if" (parenthesized_expression) "(mm_rqs[i].address != 0)" (() "(" (binary_expression) "mm_rqs[i].address != 0" (field_expression) "mm_rqs[i].address" (subscript_expression) "mm_rqs[i]" (identifier) "mm_rqs" ([) "[" (identifier) "i" (]) "]" (.) "." (field_identifier) "address" (!=) "!=" (number_literal) "0" ()) ")" (expression_statement) "sys_free(mm_rqs[i].address);" (call_expression) "sys_free(mm_rqs[i].address)" (identifier) "sys_free" (argument_list) "(mm_rqs[i].address)" (() "(" (field_expression) "mm_rqs[i].address" (subscript_expression) "mm_rqs[i]" (identifier) "mm_rqs" ([) "[" (identifier) "i" (]) "]" (.) "." (field_identifier) "address" ()) ")" (;) ";" (comment) "// TODO: Port this call as required" (}) "}" (}) "}" (function_definition) "int main_test_mm(int argc, char **argv) {\n test_mm();\n sys_sem_post("pipe");\n return 0;\n}" (primitive_type) "int" (function_declarator) "main_test_mm(int argc, char **argv)" (identifier) "main_test_mm" (parameter_list) "(int argc, char **argv)" (() "(" (parameter_declaration) "int argc" (primitive_type) "int" (identifier) "argc" (,) "," (parameter_declaration) "char **argv" (primitive_type) "char" (pointer_declarator) "**argv" (*) "*" (pointer_declarator) "*argv" (*) "*" (identifier) "argv" ()) ")" (compound_statement) "{\n test_mm();\n sys_sem_post("pipe");\n return 0;\n}" ({) "{" (expression_statement) "test_mm();" (call_expression) "test_mm()" (identifier) "test_mm" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "sys_sem_post("pipe");" (call_expression) "sys_sem_post("pipe")" (identifier) "sys_sem_post" (argument_list) "("pipe")" (() "(" (string_literal) ""pipe"" (") """ (string_content) "pipe" (") """ ()) ")" (;) ";" (return_statement) "return 0;" (return) "return" (number_literal) "0" (;) ";" (}) "}"
441
0
{"language": "c", "success": true, "metadata": {"lines": 49, "avg_line_length": 33.02, "nodes": 263, "errors": 0, "source_hash": "e9fe35159abd51b0e63103e69c83a16a28c18bc8063539b92409be674ca438f6", "categorized_nodes": 197}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"include/test_mm.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"include/test_mm.h\"", "parent": 0, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 28}}, {"id": 3, "type": "preproc_def", "text": "#define MAX_BLOCKS 128\n", "parent": null, "children": [4, 5, 6], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 7}}, {"id": 5, "type": "identifier", "text": "MAX_BLOCKS", "parent": 3, "children": [], "start_point": {"row": 6, "column": 8}, "end_point": {"row": 6, "column": 18}}, {"id": 6, "type": "preproc_arg", "text": "128", "parent": 3, "children": [], "start_point": {"row": 6, "column": 19}, "end_point": {"row": 6, "column": 22}}, {"id": 7, "type": "preproc_def", "text": "#define MAX_MEMORY 1024 //Should be around 80% of memory managed by the MM\n", "parent": null, "children": [8, 9, 10], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 8, "type": "#define", "text": "#define", "parent": 7, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 7}}, {"id": 9, "type": "identifier", "text": "MAX_MEMORY", "parent": 7, "children": [], "start_point": {"row": 7, "column": 8}, "end_point": {"row": 7, "column": 18}}, {"id": 10, "type": "preproc_arg", "text": "1024 //Should be around 80% of memory managed by the MM", "parent": 7, "children": [], "start_point": {"row": 7, "column": 19}, "end_point": {"row": 7, "column": 74}}, {"id": 11, "type": "type_definition", "text": "typedef struct MM_rq{\n void *address;\n uint32_t size;\n}mm_rq;", "parent": null, "children": [12, 13, 24], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 12, "column": 7}}, {"id": 12, "type": "typedef", "text": "typedef", "parent": 11, "children": [], "start_point": {"row": 9, "column": 0}, "end_point": {"row": 9, "column": 7}}, {"id": 13, "type": "struct_specifier", "text": "struct MM_rq{\n void *address;\n uint32_t size;\n}", "parent": 11, "children": [14, 15], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 12, "column": 1}}, {"id": 14, "type": "struct", "text": "struct", "parent": 13, "children": [], "start_point": {"row": 9, "column": 8}, "end_point": {"row": 9, "column": 14}}, {"id": 15, "type": "type_identifier", "text": "MM_rq", "parent": 13, "children": [], "start_point": {"row": 9, "column": 15}, "end_point": {"row": 9, "column": 20}}, {"id": 16, "type": "field_declaration", "text": "void *address;", "parent": 13, "children": [17, 18], "start_point": {"row": 10, "column": 2}, "end_point": {"row": 10, "column": 16}}, {"id": 17, "type": "primitive_type", "text": "void", "parent": 16, "children": [], "start_point": {"row": 10, "column": 2}, "end_point": {"row": 10, "column": 6}}, {"id": 18, "type": "pointer_declarator", "text": "*address", "parent": 16, "children": [19, 20], "start_point": {"row": 10, "column": 7}, "end_point": {"row": 10, "column": 15}}, {"id": 19, "type": "*", "text": "*", "parent": 18, "children": [], "start_point": {"row": 10, "column": 7}, "end_point": {"row": 10, "column": 8}}, {"id": 20, "type": "field_identifier", "text": "address", "parent": 18, "children": [], "start_point": {"row": 10, "column": 8}, "end_point": {"row": 10, "column": 15}}, {"id": 21, "type": "field_declaration", "text": "uint32_t size;", "parent": 13, "children": [22, 23], "start_point": {"row": 11, "column": 2}, "end_point": {"row": 11, "column": 16}}, {"id": 22, "type": "primitive_type", "text": "uint32_t", "parent": 21, "children": [], "start_point": {"row": 11, "column": 2}, "end_point": {"row": 11, "column": 10}}, {"id": 23, "type": "field_identifier", "text": "size", "parent": 21, "children": [], "start_point": {"row": 11, "column": 11}, "end_point": {"row": 11, "column": 15}}, {"id": 24, "type": "type_identifier", "text": "mm_rq", "parent": 11, "children": [], "start_point": {"row": 12, "column": 1}, "end_point": {"row": 12, "column": 6}}, {"id": 25, "type": "function_definition", "text": "void test_mm(){\n mm_rq mm_rqs[MAX_BLOCKS];\n while (1){\n uint8_t rq = 0;\n int32_t total = 0;\n\n // Request as many blocks as we can\n while(rq < MAX_BLOCKS && total < MAX_MEMORY){\n mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1;\n mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size); // TODO: Port this call as required\n if(mm_rqs[rq].address == 0) {\n printfd(\"malloc: NULL pointer returned\\n\");\n // exit(-1);\n break;\n }\n total += mm_rqs[rq].size;\n rq++;\n }\n\n // Set\n uint32_t i;\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n memset(mm_rqs[i].address, i, mm_rqs[i].size); // TODO: Port this call as required\n\n // Check\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd(\"memcheck: ERROR!\\n\"); // TODO: Port this call as required\n\n // Free\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n sys_free(mm_rqs[i].address); // TODO: Port this call as required\n } \n}", "parent": null, "children": [26, 27], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 50, "column": 1}}, {"id": 26, "type": "primitive_type", "text": "void", "parent": 25, "children": [], "start_point": {"row": 14, "column": 0}, "end_point": {"row": 14, "column": 4}}, {"id": 27, "type": "function_declarator", "text": "test_mm()", "parent": 25, "children": [28, 29], "start_point": {"row": 14, "column": 5}, "end_point": {"row": 14, "column": 14}}, {"id": 28, "type": "identifier", "text": "test_mm", "parent": 27, "children": [], "start_point": {"row": 14, "column": 5}, "end_point": {"row": 14, "column": 12}}, {"id": 29, "type": "parameter_list", "text": "()", "parent": 27, "children": [], "start_point": {"row": 14, "column": 12}, "end_point": {"row": 14, "column": 14}}, {"id": 30, "type": "declaration", "text": "mm_rq mm_rqs[MAX_BLOCKS];", "parent": 25, "children": [31, 32], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 27}}, {"id": 31, "type": "type_identifier", "text": "mm_rq", "parent": 30, "children": [], "start_point": {"row": 15, "column": 2}, "end_point": {"row": 15, "column": 7}}, {"id": 32, "type": "array_declarator", "text": "mm_rqs[MAX_BLOCKS]", "parent": 30, "children": [33, 34], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 26}}, {"id": 33, "type": "identifier", "text": "mm_rqs", "parent": 32, "children": [], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 14}}, {"id": 34, "type": "identifier", "text": "MAX_BLOCKS", "parent": 32, "children": [], "start_point": {"row": 15, "column": 15}, "end_point": {"row": 15, "column": 25}}, {"id": 35, "type": "while_statement", "text": "while (1){\n uint8_t rq = 0;\n int32_t total = 0;\n\n // Request as many blocks as we can\n while(rq < MAX_BLOCKS && total < MAX_MEMORY){\n mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1;\n mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size); // TODO: Port this call as required\n if(mm_rqs[rq].address == 0) {\n printfd(\"malloc: NULL pointer returned\\n\");\n // exit(-1);\n break;\n }\n total += mm_rqs[rq].size;\n rq++;\n }\n\n // Set\n uint32_t i;\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n memset(mm_rqs[i].address, i, mm_rqs[i].size); // TODO: Port this call as required\n\n // Check\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd(\"memcheck: ERROR!\\n\"); // TODO: Port this call as required\n\n // Free\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n sys_free(mm_rqs[i].address); // TODO: Port this call as required\n }", "parent": 25, "children": [36], "start_point": {"row": 16, "column": 2}, "end_point": {"row": 49, "column": 3}}, {"id": 36, "type": "parenthesized_expression", "text": "(1)", "parent": 35, "children": [37], "start_point": {"row": 16, "column": 8}, "end_point": {"row": 16, "column": 11}}, {"id": 37, "type": "number_literal", "text": "1", "parent": 36, "children": [], "start_point": {"row": 16, "column": 9}, "end_point": {"row": 16, "column": 10}}, {"id": 38, "type": "declaration", "text": "uint8_t rq = 0;", "parent": 35, "children": [39, 40], "start_point": {"row": 17, "column": 4}, "end_point": {"row": 17, "column": 19}}, {"id": 39, "type": "primitive_type", "text": "uint8_t", "parent": 38, "children": [], "start_point": {"row": 17, "column": 4}, "end_point": {"row": 17, "column": 11}}, {"id": 40, "type": "init_declarator", "text": "rq = 0", "parent": 38, "children": [41, 42, 43], "start_point": {"row": 17, "column": 12}, "end_point": {"row": 17, "column": 18}}, {"id": 41, "type": "identifier", "text": "rq", "parent": 40, "children": [], "start_point": {"row": 17, "column": 12}, "end_point": {"row": 17, "column": 14}}, {"id": 42, "type": "=", "text": "=", "parent": 40, "children": [], "start_point": {"row": 17, "column": 15}, "end_point": {"row": 17, "column": 16}}, {"id": 43, "type": "number_literal", "text": "0", "parent": 40, "children": [], "start_point": {"row": 17, "column": 17}, "end_point": {"row": 17, "column": 18}}, {"id": 44, "type": "declaration", "text": "int32_t total = 0;", "parent": 35, "children": [45, 46], "start_point": {"row": 18, "column": 4}, "end_point": {"row": 18, "column": 22}}, {"id": 45, "type": "primitive_type", "text": "int32_t", "parent": 44, "children": [], "start_point": {"row": 18, "column": 4}, "end_point": {"row": 18, "column": 11}}, {"id": 46, "type": "init_declarator", "text": "total = 0", "parent": 44, "children": [47, 48, 49], "start_point": {"row": 18, "column": 12}, "end_point": {"row": 18, "column": 21}}, {"id": 47, "type": "identifier", "text": "total", "parent": 46, "children": [], "start_point": {"row": 18, "column": 12}, "end_point": {"row": 18, "column": 17}}, {"id": 48, "type": "=", "text": "=", "parent": 46, "children": [], "start_point": {"row": 18, "column": 18}, "end_point": {"row": 18, "column": 19}}, {"id": 49, "type": "number_literal", "text": "0", "parent": 46, "children": [], "start_point": {"row": 18, "column": 20}, "end_point": {"row": 18, "column": 21}}, {"id": 50, "type": "while_statement", "text": "while(rq < MAX_BLOCKS && total < MAX_MEMORY){\n mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1;\n mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size); // TODO: Port this call as required\n if(mm_rqs[rq].address == 0) {\n printfd(\"malloc: NULL pointer returned\\n\");\n // exit(-1);\n break;\n }\n total += mm_rqs[rq].size;\n rq++;\n }", "parent": 35, "children": [51], "start_point": {"row": 21, "column": 4}, "end_point": {"row": 31, "column": 5}}, {"id": 51, "type": "parenthesized_expression", "text": "(rq < MAX_BLOCKS && total < MAX_MEMORY)", "parent": 50, "children": [52], "start_point": {"row": 21, "column": 9}, "end_point": {"row": 21, "column": 48}}, {"id": 52, "type": "binary_expression", "text": "rq < MAX_BLOCKS && total < MAX_MEMORY", "parent": 51, "children": [53, 57, 58], "start_point": {"row": 21, "column": 10}, "end_point": {"row": 21, "column": 47}}, {"id": 53, "type": "binary_expression", "text": "rq < MAX_BLOCKS", "parent": 52, "children": [54, 55, 56], "start_point": {"row": 21, "column": 10}, "end_point": {"row": 21, "column": 25}}, {"id": 54, "type": "identifier", "text": "rq", "parent": 53, "children": [], "start_point": {"row": 21, "column": 10}, "end_point": {"row": 21, "column": 12}}, {"id": 55, "type": "<", "text": "<", "parent": 53, "children": [], "start_point": {"row": 21, "column": 13}, "end_point": {"row": 21, "column": 14}}, {"id": 56, "type": "identifier", "text": "MAX_BLOCKS", "parent": 53, "children": [], "start_point": {"row": 21, "column": 15}, "end_point": {"row": 21, "column": 25}}, {"id": 57, "type": "&&", "text": "&&", "parent": 52, "children": [], "start_point": {"row": 21, "column": 26}, "end_point": {"row": 21, "column": 28}}, {"id": 58, "type": "binary_expression", "text": "total < MAX_MEMORY", "parent": 52, "children": [59, 60, 61], "start_point": {"row": 21, "column": 29}, "end_point": {"row": 21, "column": 47}}, {"id": 59, "type": "identifier", "text": "total", "parent": 58, "children": [], "start_point": {"row": 21, "column": 29}, "end_point": {"row": 21, "column": 34}}, {"id": 60, "type": "<", "text": "<", "parent": 58, "children": [], "start_point": {"row": 21, "column": 35}, "end_point": {"row": 21, "column": 36}}, {"id": 61, "type": "identifier", "text": "MAX_MEMORY", "parent": 58, "children": [], "start_point": {"row": 21, "column": 37}, "end_point": {"row": 21, "column": 47}}, {"id": 62, "type": "assignment_expression", "text": "mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1", "parent": 50, "children": [63, 68, 69], "start_point": {"row": 22, "column": 6}, "end_point": {"row": 22, "column": 62}}, {"id": 63, "type": "field_expression", "text": "mm_rqs[rq].size", "parent": 62, "children": [64, 67], "start_point": {"row": 22, "column": 6}, "end_point": {"row": 22, "column": 21}}, {"id": 64, "type": "subscript_expression", "text": "mm_rqs[rq]", "parent": 63, "children": [65, 66], "start_point": {"row": 22, "column": 6}, "end_point": {"row": 22, "column": 16}}, {"id": 65, "type": "identifier", "text": "mm_rqs", "parent": 64, "children": [], "start_point": {"row": 22, "column": 6}, "end_point": {"row": 22, "column": 12}}, {"id": 66, "type": "identifier", "text": "rq", "parent": 64, "children": [], "start_point": {"row": 22, "column": 13}, "end_point": {"row": 22, "column": 15}}, {"id": 67, "type": "field_identifier", "text": "size", "parent": 63, "children": [], "start_point": {"row": 22, "column": 17}, "end_point": {"row": 22, "column": 21}}, {"id": 68, "type": "=", "text": "=", "parent": 62, "children": [], "start_point": {"row": 22, "column": 22}, "end_point": {"row": 22, "column": 23}}, {"id": 69, "type": "binary_expression", "text": "GetUniform(MAX_MEMORY - total - 1) + 1", "parent": 62, "children": [70, 80, 81], "start_point": {"row": 22, "column": 24}, "end_point": {"row": 22, "column": 62}}, {"id": 70, "type": "call_expression", "text": "GetUniform(MAX_MEMORY - total - 1)", "parent": 69, "children": [71, 72], "start_point": {"row": 22, "column": 24}, "end_point": {"row": 22, "column": 58}}, {"id": 71, "type": "identifier", "text": "GetUniform", "parent": 70, "children": [], "start_point": {"row": 22, "column": 24}, "end_point": {"row": 22, "column": 34}}, {"id": 72, "type": "argument_list", "text": "(MAX_MEMORY - total - 1)", "parent": 70, "children": [73], "start_point": {"row": 22, "column": 34}, "end_point": {"row": 22, "column": 58}}, {"id": 73, "type": "binary_expression", "text": "MAX_MEMORY - total - 1", "parent": 72, "children": [74, 78, 79], "start_point": {"row": 22, "column": 35}, "end_point": {"row": 22, "column": 57}}, {"id": 74, "type": "binary_expression", "text": "MAX_MEMORY - total", "parent": 73, "children": [75, 76, 77], "start_point": {"row": 22, "column": 35}, "end_point": {"row": 22, "column": 53}}, {"id": 75, "type": "identifier", "text": "MAX_MEMORY", "parent": 74, "children": [], "start_point": {"row": 22, "column": 35}, "end_point": {"row": 22, "column": 45}}, {"id": 76, "type": "-", "text": "-", "parent": 74, "children": [], "start_point": {"row": 22, "column": 46}, "end_point": {"row": 22, "column": 47}}, {"id": 77, "type": "identifier", "text": "total", "parent": 74, "children": [], "start_point": {"row": 22, "column": 48}, "end_point": {"row": 22, "column": 53}}, {"id": 78, "type": "-", "text": "-", "parent": 73, "children": [], "start_point": {"row": 22, "column": 54}, "end_point": {"row": 22, "column": 55}}, {"id": 79, "type": "number_literal", "text": "1", "parent": 73, "children": [], "start_point": {"row": 22, "column": 56}, "end_point": {"row": 22, "column": 57}}, {"id": 80, "type": "+", "text": "+", "parent": 69, "children": [], "start_point": {"row": 22, "column": 59}, "end_point": {"row": 22, "column": 60}}, {"id": 81, "type": "number_literal", "text": "1", "parent": 69, "children": [], "start_point": {"row": 22, "column": 61}, "end_point": {"row": 22, "column": 62}}, {"id": 82, "type": "assignment_expression", "text": "mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size)", "parent": 50, "children": [83, 88, 89], "start_point": {"row": 23, "column": 6}, "end_point": {"row": 23, "column": 54}}, {"id": 83, "type": "field_expression", "text": "mm_rqs[rq].address", "parent": 82, "children": [84, 87], "start_point": {"row": 23, "column": 6}, "end_point": {"row": 23, "column": 24}}, {"id": 84, "type": "subscript_expression", "text": "mm_rqs[rq]", "parent": 83, "children": [85, 86], "start_point": {"row": 23, "column": 6}, "end_point": {"row": 23, "column": 16}}, {"id": 85, "type": "identifier", "text": "mm_rqs", "parent": 84, "children": [], "start_point": {"row": 23, "column": 6}, "end_point": {"row": 23, "column": 12}}, {"id": 86, "type": "identifier", "text": "rq", "parent": 84, "children": [], "start_point": {"row": 23, "column": 13}, "end_point": {"row": 23, "column": 15}}, {"id": 87, "type": "field_identifier", "text": "address", "parent": 83, "children": [], "start_point": {"row": 23, "column": 17}, "end_point": {"row": 23, "column": 24}}, {"id": 88, "type": "=", "text": "=", "parent": 82, "children": [], "start_point": {"row": 23, "column": 25}, "end_point": {"row": 23, "column": 26}}, {"id": 89, "type": "call_expression", "text": "sys_malloc(mm_rqs[rq].size)", "parent": 82, "children": [90, 91], "start_point": {"row": 23, "column": 27}, "end_point": {"row": 23, "column": 54}}, {"id": 90, "type": "identifier", "text": "sys_malloc", "parent": 89, "children": [], "start_point": {"row": 23, "column": 27}, "end_point": {"row": 23, "column": 37}}, {"id": 91, "type": "argument_list", "text": "(mm_rqs[rq].size)", "parent": 89, "children": [92], "start_point": {"row": 23, "column": 37}, "end_point": {"row": 23, "column": 54}}, {"id": 92, "type": "field_expression", "text": "mm_rqs[rq].size", "parent": 91, "children": [93, 96], "start_point": {"row": 23, "column": 38}, "end_point": {"row": 23, "column": 53}}, {"id": 93, "type": "subscript_expression", "text": "mm_rqs[rq]", "parent": 92, "children": [94, 95], "start_point": {"row": 23, "column": 38}, "end_point": {"row": 23, "column": 48}}, {"id": 94, "type": "identifier", "text": "mm_rqs", "parent": 93, "children": [], "start_point": {"row": 23, "column": 38}, "end_point": {"row": 23, "column": 44}}, {"id": 95, "type": "identifier", "text": "rq", "parent": 93, "children": [], "start_point": {"row": 23, "column": 45}, "end_point": {"row": 23, "column": 47}}, {"id": 96, "type": "field_identifier", "text": "size", "parent": 92, "children": [], "start_point": {"row": 23, "column": 49}, "end_point": {"row": 23, "column": 53}}, {"id": 97, "type": "if_statement", "text": "if(mm_rqs[rq].address == 0) {\n printfd(\"malloc: NULL pointer returned\\n\");\n // exit(-1);\n break;\n }", "parent": 50, "children": [98], "start_point": {"row": 24, "column": 6}, "end_point": {"row": 28, "column": 7}}, {"id": 98, "type": "parenthesized_expression", "text": "(mm_rqs[rq].address == 0)", "parent": 97, "children": [99], "start_point": {"row": 24, "column": 8}, "end_point": {"row": 24, "column": 33}}, {"id": 99, "type": "binary_expression", "text": "mm_rqs[rq].address == 0", "parent": 98, "children": [100, 105, 106], "start_point": {"row": 24, "column": 9}, "end_point": {"row": 24, "column": 32}}, {"id": 100, "type": "field_expression", "text": "mm_rqs[rq].address", "parent": 99, "children": [101, 104], "start_point": {"row": 24, "column": 9}, "end_point": {"row": 24, "column": 27}}, {"id": 101, "type": "subscript_expression", "text": "mm_rqs[rq]", "parent": 100, "children": [102, 103], "start_point": {"row": 24, "column": 9}, "end_point": {"row": 24, "column": 19}}, {"id": 102, "type": "identifier", "text": "mm_rqs", "parent": 101, "children": [], "start_point": {"row": 24, "column": 9}, "end_point": {"row": 24, "column": 15}}, {"id": 103, "type": "identifier", "text": "rq", "parent": 101, "children": [], "start_point": {"row": 24, "column": 16}, "end_point": {"row": 24, "column": 18}}, {"id": 104, "type": "field_identifier", "text": "address", "parent": 100, "children": [], "start_point": {"row": 24, "column": 20}, "end_point": {"row": 24, "column": 27}}, {"id": 105, "type": "==", "text": "==", "parent": 99, "children": [], "start_point": {"row": 24, "column": 28}, "end_point": {"row": 24, "column": 30}}, {"id": 106, "type": "number_literal", "text": "0", "parent": 99, "children": [], "start_point": {"row": 24, "column": 31}, "end_point": {"row": 24, "column": 32}}, {"id": 107, "type": "call_expression", "text": "printfd(\"malloc: NULL pointer returned\\n\")", "parent": 97, "children": [108, 109], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 50}}, {"id": 108, "type": "identifier", "text": "printfd", "parent": 107, "children": [], "start_point": {"row": 25, "column": 8}, "end_point": {"row": 25, "column": 15}}, {"id": 109, "type": "argument_list", "text": "(\"malloc: NULL pointer returned\\n\")", "parent": 107, "children": [110], "start_point": {"row": 25, "column": 15}, "end_point": {"row": 25, "column": 50}}, {"id": 110, "type": "string_literal", "text": "\"malloc: NULL pointer returned\\n\"", "parent": 109, "children": [111], "start_point": {"row": 25, "column": 16}, "end_point": {"row": 25, "column": 49}}, {"id": 111, "type": "escape_sequence", "text": "\\n", "parent": 110, "children": [], "start_point": {"row": 25, "column": 46}, "end_point": {"row": 25, "column": 48}}, {"id": 112, "type": "break_statement", "text": "break;", "parent": 97, "children": [113], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 14}}, {"id": 113, "type": "break", "text": "break", "parent": 112, "children": [], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 13}}, {"id": 114, "type": "assignment_expression", "text": "total += mm_rqs[rq].size", "parent": 50, "children": [115, 116, 117], "start_point": {"row": 29, "column": 6}, "end_point": {"row": 29, "column": 30}}, {"id": 115, "type": "identifier", "text": "total", "parent": 114, "children": [], "start_point": {"row": 29, "column": 6}, "end_point": {"row": 29, "column": 11}}, {"id": 116, "type": "+=", "text": "+=", "parent": 114, "children": [], "start_point": {"row": 29, "column": 12}, "end_point": {"row": 29, "column": 14}}, {"id": 117, "type": "field_expression", "text": "mm_rqs[rq].size", "parent": 114, "children": [118, 121], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 30}}, {"id": 118, "type": "subscript_expression", "text": "mm_rqs[rq]", "parent": 117, "children": [119, 120], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 25}}, {"id": 119, "type": "identifier", "text": "mm_rqs", "parent": 118, "children": [], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 21}}, {"id": 120, "type": "identifier", "text": "rq", "parent": 118, "children": [], "start_point": {"row": 29, "column": 22}, "end_point": {"row": 29, "column": 24}}, {"id": 121, "type": "field_identifier", "text": "size", "parent": 117, "children": [], "start_point": {"row": 29, "column": 26}, "end_point": {"row": 29, "column": 30}}, {"id": 122, "type": "update_expression", "text": "rq++", "parent": 50, "children": [123, 124], "start_point": {"row": 30, "column": 6}, "end_point": {"row": 30, "column": 10}}, {"id": 123, "type": "identifier", "text": "rq", "parent": 122, "children": [], "start_point": {"row": 30, "column": 6}, "end_point": {"row": 30, "column": 8}}, {"id": 124, "type": "++", "text": "++", "parent": 122, "children": [], "start_point": {"row": 30, "column": 8}, "end_point": {"row": 30, "column": 10}}, {"id": 125, "type": "declaration", "text": "uint32_t i;", "parent": 35, "children": [126, 127], "start_point": {"row": 34, "column": 4}, "end_point": {"row": 34, "column": 15}}, {"id": 126, "type": "primitive_type", "text": "uint32_t", "parent": 125, "children": [], "start_point": {"row": 34, "column": 4}, "end_point": {"row": 34, "column": 12}}, {"id": 127, "type": "identifier", "text": "i", "parent": 125, "children": [], "start_point": {"row": 34, "column": 13}, "end_point": {"row": 34, "column": 14}}, {"id": 128, "type": "for_statement", "text": "for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n memset(mm_rqs[i].address, i, mm_rqs[i].size);", "parent": 35, "children": [129, 133, 137, 140], "start_point": {"row": 35, "column": 4}, "end_point": {"row": 37, "column": 53}}, {"id": 129, "type": "assignment_expression", "text": "i = 0", "parent": 128, "children": [130, 131, 132], "start_point": {"row": 35, "column": 9}, "end_point": {"row": 35, "column": 14}}, {"id": 130, "type": "identifier", "text": "i", "parent": 129, "children": [], "start_point": {"row": 35, "column": 9}, "end_point": {"row": 35, "column": 10}}, {"id": 131, "type": "=", "text": "=", "parent": 129, "children": [], "start_point": {"row": 35, "column": 11}, "end_point": {"row": 35, "column": 12}}, {"id": 132, "type": "number_literal", "text": "0", "parent": 129, "children": [], "start_point": {"row": 35, "column": 13}, "end_point": {"row": 35, "column": 14}}, {"id": 133, "type": "binary_expression", "text": "i < rq", "parent": 128, "children": [134, 135, 136], "start_point": {"row": 35, "column": 16}, "end_point": {"row": 35, "column": 22}}, {"id": 134, "type": "identifier", "text": "i", "parent": 133, "children": [], "start_point": {"row": 35, "column": 16}, "end_point": {"row": 35, "column": 17}}, {"id": 135, "type": "<", "text": "<", "parent": 133, "children": [], "start_point": {"row": 35, "column": 18}, "end_point": {"row": 35, "column": 19}}, {"id": 136, "type": "identifier", "text": "rq", "parent": 133, "children": [], "start_point": {"row": 35, "column": 20}, "end_point": {"row": 35, "column": 22}}, {"id": 137, "type": "update_expression", "text": "i++", "parent": 128, "children": [138, 139], "start_point": {"row": 35, "column": 24}, "end_point": {"row": 35, "column": 27}}, {"id": 138, "type": "identifier", "text": "i", "parent": 137, "children": [], "start_point": {"row": 35, "column": 24}, "end_point": {"row": 35, "column": 25}}, {"id": 139, "type": "++", "text": "++", "parent": 137, "children": [], "start_point": {"row": 35, "column": 25}, "end_point": {"row": 35, "column": 27}}, {"id": 140, "type": "if_statement", "text": "if (mm_rqs[i].address != 0)\n memset(mm_rqs[i].address, i, mm_rqs[i].size);", "parent": 128, "children": [141], "start_point": {"row": 36, "column": 6}, "end_point": {"row": 37, "column": 53}}, {"id": 141, "type": "parenthesized_expression", "text": "(mm_rqs[i].address != 0)", "parent": 140, "children": [142], "start_point": {"row": 36, "column": 9}, "end_point": {"row": 36, "column": 33}}, {"id": 142, "type": "binary_expression", "text": "mm_rqs[i].address != 0", "parent": 141, "children": [143, 148, 149], "start_point": {"row": 36, "column": 10}, "end_point": {"row": 36, "column": 32}}, {"id": 143, "type": "field_expression", "text": "mm_rqs[i].address", "parent": 142, "children": [144, 147], "start_point": {"row": 36, "column": 10}, "end_point": {"row": 36, "column": 27}}, {"id": 144, "type": "subscript_expression", "text": "mm_rqs[i]", "parent": 143, "children": [145, 146], "start_point": {"row": 36, "column": 10}, "end_point": {"row": 36, "column": 19}}, {"id": 145, "type": "identifier", "text": "mm_rqs", "parent": 144, "children": [], "start_point": {"row": 36, "column": 10}, "end_point": {"row": 36, "column": 16}}, {"id": 146, "type": "identifier", "text": "i", "parent": 144, "children": [], "start_point": {"row": 36, "column": 17}, "end_point": {"row": 36, "column": 18}}, {"id": 147, "type": "field_identifier", "text": "address", "parent": 143, "children": [], "start_point": {"row": 36, "column": 20}, "end_point": {"row": 36, "column": 27}}, {"id": 148, "type": "!=", "text": "!=", "parent": 142, "children": [], "start_point": {"row": 36, "column": 28}, "end_point": {"row": 36, "column": 30}}, {"id": 149, "type": "number_literal", "text": "0", "parent": 142, "children": [], "start_point": {"row": 36, "column": 31}, "end_point": {"row": 36, "column": 32}}, {"id": 150, "type": "call_expression", "text": "memset(mm_rqs[i].address, i, mm_rqs[i].size)", "parent": 140, "children": [151, 152], "start_point": {"row": 37, "column": 8}, "end_point": {"row": 37, "column": 52}}, {"id": 151, "type": "identifier", "text": "memset", "parent": 150, "children": [], "start_point": {"row": 37, "column": 8}, "end_point": {"row": 37, "column": 14}}, {"id": 152, "type": "argument_list", "text": "(mm_rqs[i].address, i, mm_rqs[i].size)", "parent": 150, "children": [153, 158, 159], "start_point": {"row": 37, "column": 14}, "end_point": {"row": 37, "column": 52}}, {"id": 153, "type": "field_expression", "text": "mm_rqs[i].address", "parent": 152, "children": [154, 157], "start_point": {"row": 37, "column": 15}, "end_point": {"row": 37, "column": 32}}, {"id": 154, "type": "subscript_expression", "text": "mm_rqs[i]", "parent": 153, "children": [155, 156], "start_point": {"row": 37, "column": 15}, "end_point": {"row": 37, "column": 24}}, {"id": 155, "type": "identifier", "text": "mm_rqs", "parent": 154, "children": [], "start_point": {"row": 37, "column": 15}, "end_point": {"row": 37, "column": 21}}, {"id": 156, "type": "identifier", "text": "i", "parent": 154, "children": [], "start_point": {"row": 37, "column": 22}, "end_point": {"row": 37, "column": 23}}, {"id": 157, "type": "field_identifier", "text": "address", "parent": 153, "children": [], "start_point": {"row": 37, "column": 25}, "end_point": {"row": 37, "column": 32}}, {"id": 158, "type": "identifier", "text": "i", "parent": 152, "children": [], "start_point": {"row": 37, "column": 34}, "end_point": {"row": 37, "column": 35}}, {"id": 159, "type": "field_expression", "text": "mm_rqs[i].size", "parent": 152, "children": [160, 163], "start_point": {"row": 37, "column": 37}, "end_point": {"row": 37, "column": 51}}, {"id": 160, "type": "subscript_expression", "text": "mm_rqs[i]", "parent": 159, "children": [161, 162], "start_point": {"row": 37, "column": 37}, "end_point": {"row": 37, "column": 46}}, {"id": 161, "type": "identifier", "text": "mm_rqs", "parent": 160, "children": [], "start_point": {"row": 37, "column": 37}, "end_point": {"row": 37, "column": 43}}, {"id": 162, "type": "identifier", "text": "i", "parent": 160, "children": [], "start_point": {"row": 37, "column": 44}, "end_point": {"row": 37, "column": 45}}, {"id": 163, "type": "field_identifier", "text": "size", "parent": 159, "children": [], "start_point": {"row": 37, "column": 47}, "end_point": {"row": 37, "column": 51}}, {"id": 164, "type": "for_statement", "text": "for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd(\"memcheck: ERROR!\\n\");", "parent": 35, "children": [165, 169, 173, 176], "start_point": {"row": 40, "column": 4}, "end_point": {"row": 43, "column": 40}}, {"id": 165, "type": "assignment_expression", "text": "i = 0", "parent": 164, "children": [166, 167, 168], "start_point": {"row": 40, "column": 9}, "end_point": {"row": 40, "column": 14}}, {"id": 166, "type": "identifier", "text": "i", "parent": 165, "children": [], "start_point": {"row": 40, "column": 9}, "end_point": {"row": 40, "column": 10}}, {"id": 167, "type": "=", "text": "=", "parent": 165, "children": [], "start_point": {"row": 40, "column": 11}, "end_point": {"row": 40, "column": 12}}, {"id": 168, "type": "number_literal", "text": "0", "parent": 165, "children": [], "start_point": {"row": 40, "column": 13}, "end_point": {"row": 40, "column": 14}}, {"id": 169, "type": "binary_expression", "text": "i < rq", "parent": 164, "children": [170, 171, 172], "start_point": {"row": 40, "column": 16}, "end_point": {"row": 40, "column": 22}}, {"id": 170, "type": "identifier", "text": "i", "parent": 169, "children": [], "start_point": {"row": 40, "column": 16}, "end_point": {"row": 40, "column": 17}}, {"id": 171, "type": "<", "text": "<", "parent": 169, "children": [], "start_point": {"row": 40, "column": 18}, "end_point": {"row": 40, "column": 19}}, {"id": 172, "type": "identifier", "text": "rq", "parent": 169, "children": [], "start_point": {"row": 40, "column": 20}, "end_point": {"row": 40, "column": 22}}, {"id": 173, "type": "update_expression", "text": "i++", "parent": 164, "children": [174, 175], "start_point": {"row": 40, "column": 24}, "end_point": {"row": 40, "column": 27}}, {"id": 174, "type": "identifier", "text": "i", "parent": 173, "children": [], "start_point": {"row": 40, "column": 24}, "end_point": {"row": 40, "column": 25}}, {"id": 175, "type": "++", "text": "++", "parent": 173, "children": [], "start_point": {"row": 40, "column": 25}, "end_point": {"row": 40, "column": 27}}, {"id": 176, "type": "if_statement", "text": "if (mm_rqs[i].address != 0)\n if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd(\"memcheck: ERROR!\\n\");", "parent": 164, "children": [177, 186], "start_point": {"row": 41, "column": 6}, "end_point": {"row": 43, "column": 40}}, {"id": 177, "type": "parenthesized_expression", "text": "(mm_rqs[i].address != 0)", "parent": 176, "children": [178], "start_point": {"row": 41, "column": 9}, "end_point": {"row": 41, "column": 33}}, {"id": 178, "type": "binary_expression", "text": "mm_rqs[i].address != 0", "parent": 177, "children": [179, 184, 185], "start_point": {"row": 41, "column": 10}, "end_point": {"row": 41, "column": 32}}, {"id": 179, "type": "field_expression", "text": "mm_rqs[i].address", "parent": 178, "children": [180, 183], "start_point": {"row": 41, "column": 10}, "end_point": {"row": 41, "column": 27}}, {"id": 180, "type": "subscript_expression", "text": "mm_rqs[i]", "parent": 179, "children": [181, 182], "start_point": {"row": 41, "column": 10}, "end_point": {"row": 41, "column": 19}}, {"id": 181, "type": "identifier", "text": "mm_rqs", "parent": 180, "children": [], "start_point": {"row": 41, "column": 10}, "end_point": {"row": 41, "column": 16}}, {"id": 182, "type": "identifier", "text": "i", "parent": 180, "children": [], "start_point": {"row": 41, "column": 17}, "end_point": {"row": 41, "column": 18}}, {"id": 183, "type": "field_identifier", "text": "address", "parent": 179, "children": [], "start_point": {"row": 41, "column": 20}, "end_point": {"row": 41, "column": 27}}, {"id": 184, "type": "!=", "text": "!=", "parent": 178, "children": [], "start_point": {"row": 41, "column": 28}, "end_point": {"row": 41, "column": 30}}, {"id": 185, "type": "number_literal", "text": "0", "parent": 178, "children": [], "start_point": {"row": 41, "column": 31}, "end_point": {"row": 41, "column": 32}}, {"id": 186, "type": "if_statement", "text": "if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd(\"memcheck: ERROR!\\n\");", "parent": 176, "children": [187], "start_point": {"row": 42, "column": 8}, "end_point": {"row": 43, "column": 40}}, {"id": 187, "type": "parenthesized_expression", "text": "(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))", "parent": 186, "children": [188], "start_point": {"row": 42, "column": 10}, "end_point": {"row": 42, "column": 59}}, {"id": 188, "type": "unary_expression", "text": "!memcheck(mm_rqs[i].address, i, mm_rqs[i].size)", "parent": 187, "children": [189, 190], "start_point": {"row": 42, "column": 11}, "end_point": {"row": 42, "column": 58}}, {"id": 189, "type": "!", "text": "!", "parent": 188, "children": [], "start_point": {"row": 42, "column": 11}, "end_point": {"row": 42, "column": 12}}, {"id": 190, "type": "call_expression", "text": "memcheck(mm_rqs[i].address, i, mm_rqs[i].size)", "parent": 188, "children": [191, 192], "start_point": {"row": 42, "column": 12}, "end_point": {"row": 42, "column": 58}}, {"id": 191, "type": "identifier", "text": "memcheck", "parent": 190, "children": [], "start_point": {"row": 42, "column": 12}, "end_point": {"row": 42, "column": 20}}, {"id": 192, "type": "argument_list", "text": "(mm_rqs[i].address, i, mm_rqs[i].size)", "parent": 190, "children": [193, 198, 199], "start_point": {"row": 42, "column": 20}, "end_point": {"row": 42, "column": 58}}, {"id": 193, "type": "field_expression", "text": "mm_rqs[i].address", "parent": 192, "children": [194, 197], "start_point": {"row": 42, "column": 21}, "end_point": {"row": 42, "column": 38}}, {"id": 194, "type": "subscript_expression", "text": "mm_rqs[i]", "parent": 193, "children": [195, 196], "start_point": {"row": 42, "column": 21}, "end_point": {"row": 42, "column": 30}}, {"id": 195, "type": "identifier", "text": "mm_rqs", "parent": 194, "children": [], "start_point": {"row": 42, "column": 21}, "end_point": {"row": 42, "column": 27}}, {"id": 196, "type": "identifier", "text": "i", "parent": 194, "children": [], "start_point": {"row": 42, "column": 28}, "end_point": {"row": 42, "column": 29}}, {"id": 197, "type": "field_identifier", "text": "address", "parent": 193, "children": [], "start_point": {"row": 42, "column": 31}, "end_point": {"row": 42, "column": 38}}, {"id": 198, "type": "identifier", "text": "i", "parent": 192, "children": [], "start_point": {"row": 42, "column": 40}, "end_point": {"row": 42, "column": 41}}, {"id": 199, "type": "field_expression", "text": "mm_rqs[i].size", "parent": 192, "children": [200, 203], "start_point": {"row": 42, "column": 43}, "end_point": {"row": 42, "column": 57}}, {"id": 200, "type": "subscript_expression", "text": "mm_rqs[i]", "parent": 199, "children": [201, 202], "start_point": {"row": 42, "column": 43}, "end_point": {"row": 42, "column": 52}}, {"id": 201, "type": "identifier", "text": "mm_rqs", "parent": 200, "children": [], "start_point": {"row": 42, "column": 43}, "end_point": {"row": 42, "column": 49}}, {"id": 202, "type": "identifier", "text": "i", "parent": 200, "children": [], "start_point": {"row": 42, "column": 50}, "end_point": {"row": 42, "column": 51}}, {"id": 203, "type": "field_identifier", "text": "size", "parent": 199, "children": [], "start_point": {"row": 42, "column": 53}, "end_point": {"row": 42, "column": 57}}, {"id": 204, "type": "call_expression", "text": "printfd(\"memcheck: ERROR!\\n\")", "parent": 186, "children": [205, 206], "start_point": {"row": 43, "column": 10}, "end_point": {"row": 43, "column": 39}}, {"id": 205, "type": "identifier", "text": "printfd", "parent": 204, "children": [], "start_point": {"row": 43, "column": 10}, "end_point": {"row": 43, "column": 17}}, {"id": 206, "type": "argument_list", "text": "(\"memcheck: ERROR!\\n\")", "parent": 204, "children": [207], "start_point": {"row": 43, "column": 17}, "end_point": {"row": 43, "column": 39}}, {"id": 207, "type": "string_literal", "text": "\"memcheck: ERROR!\\n\"", "parent": 206, "children": [208], "start_point": {"row": 43, "column": 18}, "end_point": {"row": 43, "column": 38}}, {"id": 208, "type": "escape_sequence", "text": "\\n", "parent": 207, "children": [], "start_point": {"row": 43, "column": 35}, "end_point": {"row": 43, "column": 37}}, {"id": 209, "type": "for_statement", "text": "for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n sys_free(mm_rqs[i].address);", "parent": 35, "children": [210, 214, 218, 221], "start_point": {"row": 46, "column": 4}, "end_point": {"row": 48, "column": 36}}, {"id": 210, "type": "assignment_expression", "text": "i = 0", "parent": 209, "children": [211, 212, 213], "start_point": {"row": 46, "column": 9}, "end_point": {"row": 46, "column": 14}}, {"id": 211, "type": "identifier", "text": "i", "parent": 210, "children": [], "start_point": {"row": 46, "column": 9}, "end_point": {"row": 46, "column": 10}}, {"id": 212, "type": "=", "text": "=", "parent": 210, "children": [], "start_point": {"row": 46, "column": 11}, "end_point": {"row": 46, "column": 12}}, {"id": 213, "type": "number_literal", "text": "0", "parent": 210, "children": [], "start_point": {"row": 46, "column": 13}, "end_point": {"row": 46, "column": 14}}, {"id": 214, "type": "binary_expression", "text": "i < rq", "parent": 209, "children": [215, 216, 217], "start_point": {"row": 46, "column": 16}, "end_point": {"row": 46, "column": 22}}, {"id": 215, "type": "identifier", "text": "i", "parent": 214, "children": [], "start_point": {"row": 46, "column": 16}, "end_point": {"row": 46, "column": 17}}, {"id": 216, "type": "<", "text": "<", "parent": 214, "children": [], "start_point": {"row": 46, "column": 18}, "end_point": {"row": 46, "column": 19}}, {"id": 217, "type": "identifier", "text": "rq", "parent": 214, "children": [], "start_point": {"row": 46, "column": 20}, "end_point": {"row": 46, "column": 22}}, {"id": 218, "type": "update_expression", "text": "i++", "parent": 209, "children": [219, 220], "start_point": {"row": 46, "column": 24}, "end_point": {"row": 46, "column": 27}}, {"id": 219, "type": "identifier", "text": "i", "parent": 218, "children": [], "start_point": {"row": 46, "column": 24}, "end_point": {"row": 46, "column": 25}}, {"id": 220, "type": "++", "text": "++", "parent": 218, "children": [], "start_point": {"row": 46, "column": 25}, "end_point": {"row": 46, "column": 27}}, {"id": 221, "type": "if_statement", "text": "if (mm_rqs[i].address != 0)\n sys_free(mm_rqs[i].address);", "parent": 209, "children": [222], "start_point": {"row": 47, "column": 6}, "end_point": {"row": 48, "column": 36}}, {"id": 222, "type": "parenthesized_expression", "text": "(mm_rqs[i].address != 0)", "parent": 221, "children": [223], "start_point": {"row": 47, "column": 9}, "end_point": {"row": 47, "column": 33}}, {"id": 223, "type": "binary_expression", "text": "mm_rqs[i].address != 0", "parent": 222, "children": [224, 229, 230], "start_point": {"row": 47, "column": 10}, "end_point": {"row": 47, "column": 32}}, {"id": 224, "type": "field_expression", "text": "mm_rqs[i].address", "parent": 223, "children": [225, 228], "start_point": {"row": 47, "column": 10}, "end_point": {"row": 47, "column": 27}}, {"id": 225, "type": "subscript_expression", "text": "mm_rqs[i]", "parent": 224, "children": [226, 227], "start_point": {"row": 47, "column": 10}, "end_point": {"row": 47, "column": 19}}, {"id": 226, "type": "identifier", "text": "mm_rqs", "parent": 225, "children": [], "start_point": {"row": 47, "column": 10}, "end_point": {"row": 47, "column": 16}}, {"id": 227, "type": "identifier", "text": "i", "parent": 225, "children": [], "start_point": {"row": 47, "column": 17}, "end_point": {"row": 47, "column": 18}}, {"id": 228, "type": "field_identifier", "text": "address", "parent": 224, "children": [], "start_point": {"row": 47, "column": 20}, "end_point": {"row": 47, "column": 27}}, {"id": 229, "type": "!=", "text": "!=", "parent": 223, "children": [], "start_point": {"row": 47, "column": 28}, "end_point": {"row": 47, "column": 30}}, {"id": 230, "type": "number_literal", "text": "0", "parent": 223, "children": [], "start_point": {"row": 47, "column": 31}, "end_point": {"row": 47, "column": 32}}, {"id": 231, "type": "call_expression", "text": "sys_free(mm_rqs[i].address)", "parent": 221, "children": [232, 233], "start_point": {"row": 48, "column": 8}, "end_point": {"row": 48, "column": 35}}, {"id": 232, "type": "identifier", "text": "sys_free", "parent": 231, "children": [], "start_point": {"row": 48, "column": 8}, "end_point": {"row": 48, "column": 16}}, {"id": 233, "type": "argument_list", "text": "(mm_rqs[i].address)", "parent": 231, "children": [234], "start_point": {"row": 48, "column": 16}, "end_point": {"row": 48, "column": 35}}, {"id": 234, "type": "field_expression", "text": "mm_rqs[i].address", "parent": 233, "children": [235, 238], "start_point": {"row": 48, "column": 17}, "end_point": {"row": 48, "column": 34}}, {"id": 235, "type": "subscript_expression", "text": "mm_rqs[i]", "parent": 234, "children": [236, 237], "start_point": {"row": 48, "column": 17}, "end_point": {"row": 48, "column": 26}}, {"id": 236, "type": "identifier", "text": "mm_rqs", "parent": 235, "children": [], "start_point": {"row": 48, "column": 17}, "end_point": {"row": 48, "column": 23}}, {"id": 237, "type": "identifier", "text": "i", "parent": 235, "children": [], "start_point": {"row": 48, "column": 24}, "end_point": {"row": 48, "column": 25}}, {"id": 238, "type": "field_identifier", "text": "address", "parent": 234, "children": [], "start_point": {"row": 48, "column": 27}, "end_point": {"row": 48, "column": 34}}, {"id": 239, "type": "function_definition", "text": "int main_test_mm(int argc, char **argv) {\n test_mm();\n sys_sem_post(\"pipe\");\n return 0;\n}", "parent": null, "children": [240, 241], "start_point": {"row": 52, "column": 0}, "end_point": {"row": 56, "column": 1}}, {"id": 240, "type": "primitive_type", "text": "int", "parent": 239, "children": [], "start_point": {"row": 52, "column": 0}, "end_point": {"row": 52, "column": 3}}, {"id": 241, "type": "function_declarator", "text": "main_test_mm(int argc, char **argv)", "parent": 239, "children": [242, 243], "start_point": {"row": 52, "column": 4}, "end_point": {"row": 52, "column": 39}}, {"id": 242, "type": "identifier", "text": "main_test_mm", "parent": 241, "children": [], "start_point": {"row": 52, "column": 4}, "end_point": {"row": 52, "column": 16}}, {"id": 243, "type": "parameter_list", "text": "(int argc, char **argv)", "parent": 241, "children": [244, 247], "start_point": {"row": 52, "column": 16}, "end_point": {"row": 52, "column": 39}}, {"id": 244, "type": "parameter_declaration", "text": "int argc", "parent": 243, "children": [245, 246], "start_point": {"row": 52, "column": 17}, "end_point": {"row": 52, "column": 25}}, {"id": 245, "type": "primitive_type", "text": "int", "parent": 244, "children": [], "start_point": {"row": 52, "column": 17}, "end_point": {"row": 52, "column": 20}}, {"id": 246, "type": "identifier", "text": "argc", "parent": 244, "children": [], "start_point": {"row": 52, "column": 21}, "end_point": {"row": 52, "column": 25}}, {"id": 247, "type": "parameter_declaration", "text": "char **argv", "parent": 243, "children": [248, 249], "start_point": {"row": 52, "column": 27}, "end_point": {"row": 52, "column": 38}}, {"id": 248, "type": "primitive_type", "text": "char", "parent": 247, "children": [], "start_point": {"row": 52, "column": 27}, "end_point": {"row": 52, "column": 31}}, {"id": 249, "type": "pointer_declarator", "text": "**argv", "parent": 247, "children": [250, 251], "start_point": {"row": 52, "column": 32}, "end_point": {"row": 52, "column": 38}}, {"id": 250, "type": "*", "text": "*", "parent": 249, "children": [], "start_point": {"row": 52, "column": 32}, "end_point": {"row": 52, "column": 33}}, {"id": 251, "type": "pointer_declarator", "text": "*argv", "parent": 249, "children": [252, 253], "start_point": {"row": 52, "column": 33}, "end_point": {"row": 52, "column": 38}}, {"id": 252, "type": "*", "text": "*", "parent": 251, "children": [], "start_point": {"row": 52, "column": 33}, "end_point": {"row": 52, "column": 34}}, {"id": 253, "type": "identifier", "text": "argv", "parent": 251, "children": [], "start_point": {"row": 52, "column": 34}, "end_point": {"row": 52, "column": 38}}, {"id": 254, "type": "call_expression", "text": "test_mm()", "parent": 239, "children": [255, 256], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 13}}, {"id": 255, "type": "identifier", "text": "test_mm", "parent": 254, "children": [], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 11}}, {"id": 256, "type": "argument_list", "text": "()", "parent": 254, "children": [], "start_point": {"row": 53, "column": 11}, "end_point": {"row": 53, "column": 13}}, {"id": 257, "type": "call_expression", "text": "sys_sem_post(\"pipe\")", "parent": 239, "children": [258, 259], "start_point": {"row": 54, "column": 4}, "end_point": {"row": 54, "column": 24}}, {"id": 258, "type": "identifier", "text": "sys_sem_post", "parent": 257, "children": [], "start_point": {"row": 54, "column": 4}, "end_point": {"row": 54, "column": 16}}, {"id": 259, "type": "argument_list", "text": "(\"pipe\")", "parent": 257, "children": [260], "start_point": {"row": 54, "column": 16}, "end_point": {"row": 54, "column": 24}}, {"id": 260, "type": "string_literal", "text": "\"pipe\"", "parent": 259, "children": [], "start_point": {"row": 54, "column": 17}, "end_point": {"row": 54, "column": 23}}, {"id": 261, "type": "return_statement", "text": "return 0;", "parent": 239, "children": [262], "start_point": {"row": 55, "column": 4}, "end_point": {"row": 55, "column": 13}}, {"id": 262, "type": "number_literal", "text": "0", "parent": 261, "children": [], "start_point": {"row": 55, "column": 11}, "end_point": {"row": 55, "column": 12}}]}, "node_categories": {"declarations": {"functions": [25, 27, 239, 241], "variables": [11, 16, 21, 30, 38, 44, 125, 244, 247], "classes": [13, 14], "imports": [0, 1], "modules": [], "enums": []}, "statements": {"expressions": [36, 51, 52, 53, 58, 63, 64, 69, 70, 73, 74, 83, 84, 89, 92, 93, 98, 99, 100, 101, 107, 117, 118, 122, 133, 137, 141, 142, 143, 144, 150, 153, 154, 159, 160, 169, 173, 177, 178, 179, 180, 187, 188, 190, 193, 194, 199, 200, 204, 214, 218, 222, 223, 224, 225, 231, 234, 235, 254, 257], "assignments": [62, 82, 114, 129, 165, 210], "loops": [35, 50, 128, 164, 209], "conditionals": [5, 9, 15, 20, 23, 24, 28, 31, 33, 34, 41, 47, 54, 56, 59, 61, 65, 66, 67, 71, 75, 77, 85, 86, 87, 90, 94, 95, 96, 97, 102, 103, 104, 108, 115, 119, 120, 121, 123, 127, 130, 134, 136, 138, 140, 145, 146, 147, 151, 155, 156, 157, 158, 161, 162, 163, 166, 170, 172, 174, 176, 181, 182, 183, 186, 191, 195, 196, 197, 198, 201, 202, 203, 205, 211, 215, 217, 219, 221, 226, 227, 228, 232, 236, 237, 238, 242, 246, 253, 255, 258], "returns": [261], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 37, 43, 49, 79, 81, 106, 110, 132, 149, 168, 185, 207, 213, 230, 260, 262], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 25, "universal_type": "function", "name": "test_mm", "text_snippet": "void test_mm(){\n mm_rq mm_rqs[MAX_BLOCKS];\n while (1){\n uint8_t rq = 0;\n int32_t total = 0;\n"}, {"node_id": 27, "universal_type": "function", "name": "unknown", "text_snippet": "test_mm()"}, {"node_id": 239, "universal_type": "function", "name": "main_test_mm", "text_snippet": "int main_test_mm(int argc, char **argv) {\n test_mm();\n sys_sem_post(\"pipe\");\n return 0;\n}"}, {"node_id": 241, "universal_type": "function", "name": "unknown", "text_snippet": "main_test_mm(int argc, char **argv)"}], "class_declarations": [{"node_id": 13, "universal_type": "class", "name": "MM_rq{", "text_snippet": "struct MM_rq{\n void *address;\n uint32_t size;\n}"}, {"node_id": 14, "universal_type": "class", "name": "unknown", "text_snippet": "struct"}], "import_statements": [{"node_id": 0, "text": "#include \"include/test_mm.h\"\n"}, {"node_id": 1, "text": "#include"}]}, "original_source_code": "// This is a personal academic project. Dear PVS-Studio, please check it.\n// PVS-Studio Static Code Analyzer for C, C++ and C#: http://www.viva64.com\n// This is a personal academic project. Dear PVS-Studio, please check it.\n// PVS-Studio Static Code Analyzer for C, C++ and C#: http://www.viva64.com\n#include \"include/test_mm.h\"\n\n#define MAX_BLOCKS 128\n#define MAX_MEMORY 1024 //Should be around 80% of memory managed by the MM\n\ntypedef struct MM_rq{\n void *address;\n uint32_t size;\n}mm_rq;\n\nvoid test_mm(){\n mm_rq mm_rqs[MAX_BLOCKS];\n while (1){\n uint8_t rq = 0;\n int32_t total = 0;\n\n // Request as many blocks as we can\n while(rq < MAX_BLOCKS && total < MAX_MEMORY){\n mm_rqs[rq].size = GetUniform(MAX_MEMORY - total - 1) + 1;\n mm_rqs[rq].address = sys_malloc(mm_rqs[rq].size); // TODO: Port this call as required\n if(mm_rqs[rq].address == 0) {\n printfd(\"malloc: NULL pointer returned\\n\");\n // exit(-1);\n break;\n }\n total += mm_rqs[rq].size;\n rq++;\n }\n\n // Set\n uint32_t i;\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n memset(mm_rqs[i].address, i, mm_rqs[i].size); // TODO: Port this call as required\n\n // Check\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n if(!memcheck(mm_rqs[i].address, i, mm_rqs[i].size))\n printfd(\"memcheck: ERROR!\\n\"); // TODO: Port this call as required\n\n // Free\n for (i = 0; i < rq; i++)\n if (mm_rqs[i].address != 0)\n sys_free(mm_rqs[i].address); // TODO: Port this call as required\n } \n}\n\nint main_test_mm(int argc, char **argv) {\n test_mm();\n sys_sem_post(\"pipe\");\n return 0;\n}"}
80,593
c
/* * This file and its contents are supplied under the terms of the * Common Development and Distribution License ("CDDL"), version 1.0. * You may only use this file in accordance with the terms of version * 1.0 of the CDDL. * * A full copy of the text of the CDDL should have accompanied this * source. A copy of the CDDL is also available via the Internet at * http://www.illumos.org/license/CDDL. */ /* * Copyright 2019, Joyent, Inc. */ /* * Verify various bad read conditions fail successfully. */ #include <err.h> #include <stdlib.h> #include <sys/types.h> #include <sys/stat.h> #include <fcntl.h> #include <strings.h> #include <unistd.h> #include <errno.h> #include <sys/usb/clients/ccid/uccid.h> int main(int argc, char *argv[]) { int fd; uccid_cmd_txn_begin_t begin; ssize_t ret; char buf[500]; if (argc != 2) { errx(EXIT_FAILURE, "missing required ccid path"); } if ((fd = open(argv[1], O_RDWR)) < 0) { err(EXIT_FAILURE, "failed to open %s", argv[1]); } bzero(&begin, sizeof (begin)); begin.uct_version = UCCID_CURRENT_VERSION; /* * Read without having a transaction */ ret = read(fd, buf, sizeof (buf)); if (ret != -1) { errx(EXIT_FAILURE, "read succeeded when it should have failed " "(EACCES case), returned %ld", ret); } if (errno != EACCES) { errx(EXIT_FAILURE, "found wrong value for errno. Expected " "%d, received %d", EACCES, errno); } if (ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin) != 0) { err(EXIT_FAILURE, "failed to issue begin ioctl"); } ret = read(fd, buf, sizeof (buf)); if (ret != -1) { errx(EXIT_FAILURE, "read succeeded when it should have failed " "(ENODATA case), returned %ld", ret); } if (errno != ENODATA) { errx(EXIT_FAILURE, "found wrong value for errno. Expected " "%d, received %d", ENODATA, errno); } return (0); }
26.71
66
(translation_unit) "/*\n * This file and its contents are supplied under the terms of the\n * Common Development and Distribution License ("CDDL"), version 1.0.\n * You may only use this file in accordance with the terms of version\n * 1.0 of the CDDL.\n *\n * A full copy of the text of the CDDL should have accompanied this\n * source. A copy of the CDDL is also available via the Internet at\n * http://www.illumos.org/license/CDDL.\n */\n\n/*\n * Copyright 2019, Joyent, Inc.\n */\n\n/*\n * Verify various bad read conditions fail successfully.\n */\n\n#include <err.h>\n#include <stdlib.h>\n#include <sys/types.h>\n#include <sys/stat.h>\n#include <fcntl.h>\n#include <strings.h>\n#include <unistd.h>\n#include <errno.h>\n\n#include <sys/usb/clients/ccid/uccid.h>\n\nint\nmain(int argc, char *argv[])\n{\n int fd;\n uccid_cmd_txn_begin_t begin;\n ssize_t ret;\n char buf[500];\n\n if (argc != 2) {\n errx(EXIT_FAILURE, "missing required ccid path");\n }\n\n if ((fd = open(argv[1], O_RDWR)) < 0) {\n err(EXIT_FAILURE, "failed to open %s", argv[1]);\n }\n\n bzero(&begin, sizeof (begin));\n begin.uct_version = UCCID_CURRENT_VERSION;\n\n /*\n * Read without having a transaction\n */\n ret = read(fd, buf, sizeof (buf));\n if (ret != -1) {\n errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(EACCES case), returned %ld", ret);\n }\n\n if (errno != EACCES) {\n errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", EACCES, errno);\n }\n\n if (ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin) != 0) {\n err(EXIT_FAILURE, "failed to issue begin ioctl");\n }\n\n ret = read(fd, buf, sizeof (buf));\n if (ret != -1) {\n errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(ENODATA case), returned %ld", ret);\n }\n\n if (errno != ENODATA) {\n errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", ENODATA, errno);\n }\n\n return (0);\n}\n" (comment) "/*\n * This file and its contents are supplied under the terms of the\n * Common Development and Distribution License ("CDDL"), version 1.0.\n * You may only use this file in accordance with the terms of version\n * 1.0 of the CDDL.\n *\n * A full copy of the text of the CDDL should have accompanied this\n * source. A copy of the CDDL is also available via the Internet at\n * http://www.illumos.org/license/CDDL.\n */" (comment) "/*\n * Copyright 2019, Joyent, Inc.\n */" (comment) "/*\n * Verify various bad read conditions fail successfully.\n */" (preproc_include) "#include <err.h>\n" (#include) "#include" (system_lib_string) "<err.h>" (preproc_include) "#include <stdlib.h>\n" (#include) "#include" (system_lib_string) "<stdlib.h>" (preproc_include) "#include <sys/types.h>\n" (#include) "#include" (system_lib_string) "<sys/types.h>" (preproc_include) "#include <sys/stat.h>\n" (#include) "#include" (system_lib_string) "<sys/stat.h>" (preproc_include) "#include <fcntl.h>\n" (#include) "#include" (system_lib_string) "<fcntl.h>" (preproc_include) "#include <strings.h>\n" (#include) "#include" (system_lib_string) "<strings.h>" (preproc_include) "#include <unistd.h>\n" (#include) "#include" (system_lib_string) "<unistd.h>" (preproc_include) "#include <errno.h>\n" (#include) "#include" (system_lib_string) "<errno.h>" (preproc_include) "#include <sys/usb/clients/ccid/uccid.h>\n" (#include) "#include" (system_lib_string) "<sys/usb/clients/ccid/uccid.h>" (function_definition) "int\nmain(int argc, char *argv[])\n{\n int fd;\n uccid_cmd_txn_begin_t begin;\n ssize_t ret;\n char buf[500];\n\n if (argc != 2) {\n errx(EXIT_FAILURE, "missing required ccid path");\n }\n\n if ((fd = open(argv[1], O_RDWR)) < 0) {\n err(EXIT_FAILURE, "failed to open %s", argv[1]);\n }\n\n bzero(&begin, sizeof (begin));\n begin.uct_version = UCCID_CURRENT_VERSION;\n\n /*\n * Read without having a transaction\n */\n ret = read(fd, buf, sizeof (buf));\n if (ret != -1) {\n errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(EACCES case), returned %ld", ret);\n }\n\n if (errno != EACCES) {\n errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", EACCES, errno);\n }\n\n if (ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin) != 0) {\n err(EXIT_FAILURE, "failed to issue begin ioctl");\n }\n\n ret = read(fd, buf, sizeof (buf));\n if (ret != -1) {\n errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(ENODATA case), returned %ld", ret);\n }\n\n if (errno != ENODATA) {\n errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", ENODATA, errno);\n }\n\n return (0);\n}" (primitive_type) "int" (function_declarator) "main(int argc, char *argv[])" (identifier) "main" (parameter_list) "(int argc, char *argv[])" (() "(" (parameter_declaration) "int argc" (primitive_type) "int" (identifier) "argc" (,) "," (parameter_declaration) "char *argv[]" (primitive_type) "char" (pointer_declarator) "*argv[]" (*) "*" (array_declarator) "argv[]" (identifier) "argv" ([) "[" (]) "]" ()) ")" (compound_statement) "{\n int fd;\n uccid_cmd_txn_begin_t begin;\n ssize_t ret;\n char buf[500];\n\n if (argc != 2) {\n errx(EXIT_FAILURE, "missing required ccid path");\n }\n\n if ((fd = open(argv[1], O_RDWR)) < 0) {\n err(EXIT_FAILURE, "failed to open %s", argv[1]);\n }\n\n bzero(&begin, sizeof (begin));\n begin.uct_version = UCCID_CURRENT_VERSION;\n\n /*\n * Read without having a transaction\n */\n ret = read(fd, buf, sizeof (buf));\n if (ret != -1) {\n errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(EACCES case), returned %ld", ret);\n }\n\n if (errno != EACCES) {\n errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", EACCES, errno);\n }\n\n if (ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin) != 0) {\n err(EXIT_FAILURE, "failed to issue begin ioctl");\n }\n\n ret = read(fd, buf, sizeof (buf));\n if (ret != -1) {\n errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(ENODATA case), returned %ld", ret);\n }\n\n if (errno != ENODATA) {\n errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", ENODATA, errno);\n }\n\n return (0);\n}" ({) "{" (declaration) "int fd;" (primitive_type) "int" (identifier) "fd" (;) ";" (declaration) "uccid_cmd_txn_begin_t begin;" (type_identifier) "uccid_cmd_txn_begin_t" (identifier) "begin" (;) ";" (declaration) "ssize_t ret;" (primitive_type) "ssize_t" (identifier) "ret" (;) ";" (declaration) "char buf[500];" (primitive_type) "char" (array_declarator) "buf[500]" (identifier) "buf" ([) "[" (number_literal) "500" (]) "]" (;) ";" (if_statement) "if (argc != 2) {\n errx(EXIT_FAILURE, "missing required ccid path");\n }" (if) "if" (parenthesized_expression) "(argc != 2)" (() "(" (binary_expression) "argc != 2" (identifier) "argc" (!=) "!=" (number_literal) "2" ()) ")" (compound_statement) "{\n errx(EXIT_FAILURE, "missing required ccid path");\n }" ({) "{" (expression_statement) "errx(EXIT_FAILURE, "missing required ccid path");" (call_expression) "errx(EXIT_FAILURE, "missing required ccid path")" (identifier) "errx" (argument_list) "(EXIT_FAILURE, "missing required ccid path")" (() "(" (identifier) "EXIT_FAILURE" (,) "," (string_literal) ""missing required ccid path"" (") """ (string_content) "missing required ccid path" (") """ ()) ")" (;) ";" (}) "}" (if_statement) "if ((fd = open(argv[1], O_RDWR)) < 0) {\n err(EXIT_FAILURE, "failed to open %s", argv[1]);\n }" (if) "if" (parenthesized_expression) "((fd = open(argv[1], O_RDWR)) < 0)" (() "(" (binary_expression) "(fd = open(argv[1], O_RDWR)) < 0" (parenthesized_expression) "(fd = open(argv[1], O_RDWR))" (() "(" (assignment_expression) "fd = open(argv[1], O_RDWR)" (identifier) "fd" (=) "=" (call_expression) "open(argv[1], O_RDWR)" (identifier) "open" (argument_list) "(argv[1], O_RDWR)" (() "(" (subscript_expression) "argv[1]" (identifier) "argv" ([) "[" (number_literal) "1" (]) "]" (,) "," (identifier) "O_RDWR" ()) ")" ()) ")" (<) "<" (number_literal) "0" ()) ")" (compound_statement) "{\n err(EXIT_FAILURE, "failed to open %s", argv[1]);\n }" ({) "{" (expression_statement) "err(EXIT_FAILURE, "failed to open %s", argv[1]);" (call_expression) "err(EXIT_FAILURE, "failed to open %s", argv[1])" (identifier) "err" (argument_list) "(EXIT_FAILURE, "failed to open %s", argv[1])" (() "(" (identifier) "EXIT_FAILURE" (,) "," (string_literal) ""failed to open %s"" (") """ (string_content) "failed to open %s" (") """ (,) "," (subscript_expression) "argv[1]" (identifier) "argv" ([) "[" (number_literal) "1" (]) "]" ()) ")" (;) ";" (}) "}" (expression_statement) "bzero(&begin, sizeof (begin));" (call_expression) "bzero(&begin, sizeof (begin))" (identifier) "bzero" (argument_list) "(&begin, sizeof (begin))" (() "(" (pointer_expression) "&begin" (&) "&" (identifier) "begin" (,) "," (sizeof_expression) "sizeof (begin)" (sizeof) "sizeof" (parenthesized_expression) "(begin)" (() "(" (identifier) "begin" ()) ")" ()) ")" (;) ";" (expression_statement) "begin.uct_version = UCCID_CURRENT_VERSION;" (assignment_expression) "begin.uct_version = UCCID_CURRENT_VERSION" (field_expression) "begin.uct_version" (identifier) "begin" (.) "." (field_identifier) "uct_version" (=) "=" (identifier) "UCCID_CURRENT_VERSION" (;) ";" (comment) "/*\n * Read without having a transaction\n */" (expression_statement) "ret = read(fd, buf, sizeof (buf));" (assignment_expression) "ret = read(fd, buf, sizeof (buf))" (identifier) "ret" (=) "=" (call_expression) "read(fd, buf, sizeof (buf))" (identifier) "read" (argument_list) "(fd, buf, sizeof (buf))" (() "(" (identifier) "fd" (,) "," (identifier) "buf" (,) "," (sizeof_expression) "sizeof (buf)" (sizeof) "sizeof" (parenthesized_expression) "(buf)" (() "(" (identifier) "buf" ()) ")" ()) ")" (;) ";" (if_statement) "if (ret != -1) {\n errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(EACCES case), returned %ld", ret);\n }" (if) "if" (parenthesized_expression) "(ret != -1)" (() "(" (binary_expression) "ret != -1" (identifier) "ret" (!=) "!=" (number_literal) "-1" ()) ")" (compound_statement) "{\n errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(EACCES case), returned %ld", ret);\n }" ({) "{" (expression_statement) "errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(EACCES case), returned %ld", ret);" (call_expression) "errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(EACCES case), returned %ld", ret)" (identifier) "errx" (argument_list) "(EXIT_FAILURE, "read succeeded when it should have failed "\n "(EACCES case), returned %ld", ret)" (() "(" (identifier) "EXIT_FAILURE" (,) "," (concatenated_string) ""read succeeded when it should have failed "\n "(EACCES case), returned %ld"" (string_literal) ""read succeeded when it should have failed "" (") """ (string_content) "read succeeded when it should have failed " (") """ (string_literal) ""(EACCES case), returned %ld"" (") """ (string_content) "(EACCES case), returned %ld" (") """ (,) "," (identifier) "ret" ()) ")" (;) ";" (}) "}" (if_statement) "if (errno != EACCES) {\n errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", EACCES, errno);\n }" (if) "if" (parenthesized_expression) "(errno != EACCES)" (() "(" (binary_expression) "errno != EACCES" (identifier) "errno" (!=) "!=" (identifier) "EACCES" ()) ")" (compound_statement) "{\n errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", EACCES, errno);\n }" ({) "{" (expression_statement) "errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", EACCES, errno);" (call_expression) "errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", EACCES, errno)" (identifier) "errx" (argument_list) "(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", EACCES, errno)" (() "(" (identifier) "EXIT_FAILURE" (,) "," (concatenated_string) ""found wrong value for errno. Expected "\n "%d, received %d"" (string_literal) ""found wrong value for errno. Expected "" (") """ (string_content) "found wrong value for errno. Expected " (") """ (string_literal) ""%d, received %d"" (") """ (string_content) "%d, received %d" (") """ (,) "," (identifier) "EACCES" (,) "," (identifier) "errno" ()) ")" (;) ";" (}) "}" (if_statement) "if (ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin) != 0) {\n err(EXIT_FAILURE, "failed to issue begin ioctl");\n }" (if) "if" (parenthesized_expression) "(ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin) != 0)" (() "(" (binary_expression) "ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin) != 0" (call_expression) "ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin)" (identifier) "ioctl" (argument_list) "(fd, UCCID_CMD_TXN_BEGIN, &begin)" (() "(" (identifier) "fd" (,) "," (identifier) "UCCID_CMD_TXN_BEGIN" (,) "," (pointer_expression) "&begin" (&) "&" (identifier) "begin" ()) ")" (!=) "!=" (number_literal) "0" ()) ")" (compound_statement) "{\n err(EXIT_FAILURE, "failed to issue begin ioctl");\n }" ({) "{" (expression_statement) "err(EXIT_FAILURE, "failed to issue begin ioctl");" (call_expression) "err(EXIT_FAILURE, "failed to issue begin ioctl")" (identifier) "err" (argument_list) "(EXIT_FAILURE, "failed to issue begin ioctl")" (() "(" (identifier) "EXIT_FAILURE" (,) "," (string_literal) ""failed to issue begin ioctl"" (") """ (string_content) "failed to issue begin ioctl" (") """ ()) ")" (;) ";" (}) "}" (expression_statement) "ret = read(fd, buf, sizeof (buf));" (assignment_expression) "ret = read(fd, buf, sizeof (buf))" (identifier) "ret" (=) "=" (call_expression) "read(fd, buf, sizeof (buf))" (identifier) "read" (argument_list) "(fd, buf, sizeof (buf))" (() "(" (identifier) "fd" (,) "," (identifier) "buf" (,) "," (sizeof_expression) "sizeof (buf)" (sizeof) "sizeof" (parenthesized_expression) "(buf)" (() "(" (identifier) "buf" ()) ")" ()) ")" (;) ";" (if_statement) "if (ret != -1) {\n errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(ENODATA case), returned %ld", ret);\n }" (if) "if" (parenthesized_expression) "(ret != -1)" (() "(" (binary_expression) "ret != -1" (identifier) "ret" (!=) "!=" (number_literal) "-1" ()) ")" (compound_statement) "{\n errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(ENODATA case), returned %ld", ret);\n }" ({) "{" (expression_statement) "errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(ENODATA case), returned %ld", ret);" (call_expression) "errx(EXIT_FAILURE, "read succeeded when it should have failed "\n "(ENODATA case), returned %ld", ret)" (identifier) "errx" (argument_list) "(EXIT_FAILURE, "read succeeded when it should have failed "\n "(ENODATA case), returned %ld", ret)" (() "(" (identifier) "EXIT_FAILURE" (,) "," (concatenated_string) ""read succeeded when it should have failed "\n "(ENODATA case), returned %ld"" (string_literal) ""read succeeded when it should have failed "" (") """ (string_content) "read succeeded when it should have failed " (") """ (string_literal) ""(ENODATA case), returned %ld"" (") """ (string_content) "(ENODATA case), returned %ld" (") """ (,) "," (identifier) "ret" ()) ")" (;) ";" (}) "}" (if_statement) "if (errno != ENODATA) {\n errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", ENODATA, errno);\n }" (if) "if" (parenthesized_expression) "(errno != ENODATA)" (() "(" (binary_expression) "errno != ENODATA" (identifier) "errno" (!=) "!=" (identifier) "ENODATA" ()) ")" (compound_statement) "{\n errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", ENODATA, errno);\n }" ({) "{" (expression_statement) "errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", ENODATA, errno);" (call_expression) "errx(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", ENODATA, errno)" (identifier) "errx" (argument_list) "(EXIT_FAILURE, "found wrong value for errno. Expected "\n "%d, received %d", ENODATA, errno)" (() "(" (identifier) "EXIT_FAILURE" (,) "," (concatenated_string) ""found wrong value for errno. Expected "\n "%d, received %d"" (string_literal) ""found wrong value for errno. Expected "" (") """ (string_content) "found wrong value for errno. Expected " (") """ (string_literal) ""%d, received %d"" (") """ (string_content) "%d, received %d" (") """ (,) "," (identifier) "ENODATA" (,) "," (identifier) "errno" ()) ")" (;) ";" (}) "}" (return_statement) "return (0);" (return) "return" (parenthesized_expression) "(0)" (() "(" (number_literal) "0" ()) ")" (;) ";" (}) "}"
388
0
{"language": "c", "success": true, "metadata": {"lines": 66, "avg_line_length": 26.71, "nodes": 199, "errors": 0, "source_hash": "2bc1be5dae4f09e04248afac58dd2c38c18664803648a0a9a83a94964f30b5bb", "categorized_nodes": 165}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <err.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 20, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 19, "column": 0}, "end_point": {"row": 19, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<err.h>", "parent": 0, "children": [], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 16}}, {"id": 3, "type": "preproc_include", "text": "#include <stdlib.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 21, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<stdlib.h>", "parent": 3, "children": [], "start_point": {"row": 20, "column": 9}, "end_point": {"row": 20, "column": 19}}, {"id": 6, "type": "preproc_include", "text": "#include <sys/types.h>\n", "parent": null, "children": [7, 8], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 22, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 21, "column": 0}, "end_point": {"row": 21, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<sys/types.h>", "parent": 6, "children": [], "start_point": {"row": 21, "column": 9}, "end_point": {"row": 21, "column": 22}}, {"id": 9, "type": "preproc_include", "text": "#include <sys/stat.h>\n", "parent": null, "children": [10, 11], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 23, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 22, "column": 0}, "end_point": {"row": 22, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<sys/stat.h>", "parent": 9, "children": [], "start_point": {"row": 22, "column": 9}, "end_point": {"row": 22, "column": 21}}, {"id": 12, "type": "preproc_include", "text": "#include <fcntl.h>\n", "parent": null, "children": [13, 14], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 24, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 23, "column": 0}, "end_point": {"row": 23, "column": 8}}, {"id": 14, "type": "system_lib_string", "text": "<fcntl.h>", "parent": 12, "children": [], "start_point": {"row": 23, "column": 9}, "end_point": {"row": 23, "column": 18}}, {"id": 15, "type": "preproc_include", "text": "#include <strings.h>\n", "parent": null, "children": [16, 17], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 25, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 24, "column": 0}, "end_point": {"row": 24, "column": 8}}, {"id": 17, "type": "system_lib_string", "text": "<strings.h>", "parent": 15, "children": [], "start_point": {"row": 24, "column": 9}, "end_point": {"row": 24, "column": 20}}, {"id": 18, "type": "preproc_include", "text": "#include <unistd.h>\n", "parent": null, "children": [19, 20], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 26, "column": 0}}, {"id": 19, "type": "#include", "text": "#include", "parent": 18, "children": [], "start_point": {"row": 25, "column": 0}, "end_point": {"row": 25, "column": 8}}, {"id": 20, "type": "system_lib_string", "text": "<unistd.h>", "parent": 18, "children": [], "start_point": {"row": 25, "column": 9}, "end_point": {"row": 25, "column": 19}}, {"id": 21, "type": "preproc_include", "text": "#include <errno.h>\n", "parent": null, "children": [22, 23], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 27, "column": 0}}, {"id": 22, "type": "#include", "text": "#include", "parent": 21, "children": [], "start_point": {"row": 26, "column": 0}, "end_point": {"row": 26, "column": 8}}, {"id": 23, "type": "system_lib_string", "text": "<errno.h>", "parent": 21, "children": [], "start_point": {"row": 26, "column": 9}, "end_point": {"row": 26, "column": 18}}, {"id": 24, "type": "preproc_include", "text": "#include <sys/usb/clients/ccid/uccid.h>\n", "parent": null, "children": [25, 26], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 29, "column": 0}}, {"id": 25, "type": "#include", "text": "#include", "parent": 24, "children": [], "start_point": {"row": 28, "column": 0}, "end_point": {"row": 28, "column": 8}}, {"id": 26, "type": "system_lib_string", "text": "<sys/usb/clients/ccid/uccid.h>", "parent": 24, "children": [], "start_point": {"row": 28, "column": 9}, "end_point": {"row": 28, "column": 39}}, {"id": 27, "type": "function_definition", "text": "int\nmain(int argc, char *argv[])\n{\n\tint fd;\n\tuccid_cmd_txn_begin_t begin;\n\tssize_t ret;\n\tchar buf[500];\n\n\tif (argc != 2) {\n\t\terrx(EXIT_FAILURE, \"missing required ccid path\");\n\t}\n\n\tif ((fd = open(argv[1], O_RDWR)) < 0) {\n\t\terr(EXIT_FAILURE, \"failed to open %s\", argv[1]);\n\t}\n\n\tbzero(&begin, sizeof (begin));\n\tbegin.uct_version = UCCID_CURRENT_VERSION;\n\n\t/*\n\t * Read without having a transaction\n\t */\n\tret = read(fd, buf, sizeof (buf));\n\tif (ret != -1) {\n\t\terrx(EXIT_FAILURE, \"read succeeded when it should have failed \"\n\t\t \"(EACCES case), returned %ld\", ret);\n\t}\n\n\tif (errno != EACCES) {\n\t\terrx(EXIT_FAILURE, \"found wrong value for errno. Expected \"\n\t\t \"%d, received %d\", EACCES, errno);\n\t}\n\n\tif (ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin) != 0) {\n\t\terr(EXIT_FAILURE, \"failed to issue begin ioctl\");\n\t}\n\n\tret = read(fd, buf, sizeof (buf));\n\tif (ret != -1) {\n\t\terrx(EXIT_FAILURE, \"read succeeded when it should have failed \"\n\t\t \"(ENODATA case), returned %ld\", ret);\n\t}\n\n\tif (errno != ENODATA) {\n\t\terrx(EXIT_FAILURE, \"found wrong value for errno. Expected \"\n\t\t \"%d, received %d\", ENODATA, errno);\n\t}\n\n\treturn (0);\n}", "parent": null, "children": [28, 29], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 79, "column": 1}}, {"id": 28, "type": "primitive_type", "text": "int", "parent": 27, "children": [], "start_point": {"row": 30, "column": 0}, "end_point": {"row": 30, "column": 3}}, {"id": 29, "type": "function_declarator", "text": "main(int argc, char *argv[])", "parent": 27, "children": [30, 31], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 31, "column": 28}}, {"id": 30, "type": "identifier", "text": "main", "parent": 29, "children": [], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 31, "column": 4}}, {"id": 31, "type": "parameter_list", "text": "(int argc, char *argv[])", "parent": 29, "children": [32, 35], "start_point": {"row": 31, "column": 4}, "end_point": {"row": 31, "column": 28}}, {"id": 32, "type": "parameter_declaration", "text": "int argc", "parent": 31, "children": [33, 34], "start_point": {"row": 31, "column": 5}, "end_point": {"row": 31, "column": 13}}, {"id": 33, "type": "primitive_type", "text": "int", "parent": 32, "children": [], "start_point": {"row": 31, "column": 5}, "end_point": {"row": 31, "column": 8}}, {"id": 34, "type": "identifier", "text": "argc", "parent": 32, "children": [], "start_point": {"row": 31, "column": 9}, "end_point": {"row": 31, "column": 13}}, {"id": 35, "type": "parameter_declaration", "text": "char *argv[]", "parent": 31, "children": [36, 37], "start_point": {"row": 31, "column": 15}, "end_point": {"row": 31, "column": 27}}, {"id": 36, "type": "primitive_type", "text": "char", "parent": 35, "children": [], "start_point": {"row": 31, "column": 15}, "end_point": {"row": 31, "column": 19}}, {"id": 37, "type": "pointer_declarator", "text": "*argv[]", "parent": 35, "children": [38, 39], "start_point": {"row": 31, "column": 20}, "end_point": {"row": 31, "column": 27}}, {"id": 38, "type": "*", "text": "*", "parent": 37, "children": [], "start_point": {"row": 31, "column": 20}, "end_point": {"row": 31, "column": 21}}, {"id": 39, "type": "array_declarator", "text": "argv[]", "parent": 37, "children": [40], "start_point": {"row": 31, "column": 21}, "end_point": {"row": 31, "column": 27}}, {"id": 40, "type": "identifier", "text": "argv", "parent": 39, "children": [], "start_point": {"row": 31, "column": 21}, "end_point": {"row": 31, "column": 25}}, {"id": 41, "type": "declaration", "text": "int fd;", "parent": 27, "children": [42, 43], "start_point": {"row": 33, "column": 1}, "end_point": {"row": 33, "column": 8}}, {"id": 42, "type": "primitive_type", "text": "int", "parent": 41, "children": [], "start_point": {"row": 33, "column": 1}, "end_point": {"row": 33, "column": 4}}, {"id": 43, "type": "identifier", "text": "fd", "parent": 41, "children": [], "start_point": {"row": 33, "column": 5}, "end_point": {"row": 33, "column": 7}}, {"id": 44, "type": "declaration", "text": "uccid_cmd_txn_begin_t begin;", "parent": 27, "children": [45], "start_point": {"row": 34, "column": 1}, "end_point": {"row": 34, "column": 29}}, {"id": 45, "type": "type_identifier", "text": "uccid_cmd_txn_begin_t", "parent": 44, "children": [], "start_point": {"row": 34, "column": 1}, "end_point": {"row": 34, "column": 22}}, {"id": 46, "type": "declaration", "text": "ssize_t ret;", "parent": 27, "children": [47, 48], "start_point": {"row": 35, "column": 1}, "end_point": {"row": 35, "column": 13}}, {"id": 47, "type": "primitive_type", "text": "ssize_t", "parent": 46, "children": [], "start_point": {"row": 35, "column": 1}, "end_point": {"row": 35, "column": 8}}, {"id": 48, "type": "identifier", "text": "ret", "parent": 46, "children": [], "start_point": {"row": 35, "column": 9}, "end_point": {"row": 35, "column": 12}}, {"id": 49, "type": "declaration", "text": "char buf[500];", "parent": 27, "children": [50, 51], "start_point": {"row": 36, "column": 1}, "end_point": {"row": 36, "column": 15}}, {"id": 50, "type": "primitive_type", "text": "char", "parent": 49, "children": [], "start_point": {"row": 36, "column": 1}, "end_point": {"row": 36, "column": 5}}, {"id": 51, "type": "array_declarator", "text": "buf[500]", "parent": 49, "children": [52, 53], "start_point": {"row": 36, "column": 6}, "end_point": {"row": 36, "column": 14}}, {"id": 52, "type": "identifier", "text": "buf", "parent": 51, "children": [], "start_point": {"row": 36, "column": 6}, "end_point": {"row": 36, "column": 9}}, {"id": 53, "type": "number_literal", "text": "500", "parent": 51, "children": [], "start_point": {"row": 36, "column": 10}, "end_point": {"row": 36, "column": 13}}, {"id": 54, "type": "if_statement", "text": "if (argc != 2) {\n\t\terrx(EXIT_FAILURE, \"missing required ccid path\");\n\t}", "parent": 27, "children": [55], "start_point": {"row": 38, "column": 1}, "end_point": {"row": 40, "column": 2}}, {"id": 55, "type": "parenthesized_expression", "text": "(argc != 2)", "parent": 54, "children": [56], "start_point": {"row": 38, "column": 4}, "end_point": {"row": 38, "column": 15}}, {"id": 56, "type": "binary_expression", "text": "argc != 2", "parent": 55, "children": [57, 58, 59], "start_point": {"row": 38, "column": 5}, "end_point": {"row": 38, "column": 14}}, {"id": 57, "type": "identifier", "text": "argc", "parent": 56, "children": [], "start_point": {"row": 38, "column": 5}, "end_point": {"row": 38, "column": 9}}, {"id": 58, "type": "!=", "text": "!=", "parent": 56, "children": [], "start_point": {"row": 38, "column": 10}, "end_point": {"row": 38, "column": 12}}, {"id": 59, "type": "number_literal", "text": "2", "parent": 56, "children": [], "start_point": {"row": 38, "column": 13}, "end_point": {"row": 38, "column": 14}}, {"id": 60, "type": "call_expression", "text": "errx(EXIT_FAILURE, \"missing required ccid path\")", "parent": 54, "children": [61, 62], "start_point": {"row": 39, "column": 2}, "end_point": {"row": 39, "column": 50}}, {"id": 61, "type": "identifier", "text": "errx", "parent": 60, "children": [], "start_point": {"row": 39, "column": 2}, "end_point": {"row": 39, "column": 6}}, {"id": 62, "type": "argument_list", "text": "(EXIT_FAILURE, \"missing required ccid path\")", "parent": 60, "children": [63, 64], "start_point": {"row": 39, "column": 6}, "end_point": {"row": 39, "column": 50}}, {"id": 63, "type": "identifier", "text": "EXIT_FAILURE", "parent": 62, "children": [], "start_point": {"row": 39, "column": 7}, "end_point": {"row": 39, "column": 19}}, {"id": 64, "type": "string_literal", "text": "\"missing required ccid path\"", "parent": 62, "children": [], "start_point": {"row": 39, "column": 21}, "end_point": {"row": 39, "column": 49}}, {"id": 65, "type": "if_statement", "text": "if ((fd = open(argv[1], O_RDWR)) < 0) {\n\t\terr(EXIT_FAILURE, \"failed to open %s\", argv[1]);\n\t}", "parent": 27, "children": [66], "start_point": {"row": 42, "column": 1}, "end_point": {"row": 44, "column": 2}}, {"id": 66, "type": "parenthesized_expression", "text": "((fd = open(argv[1], O_RDWR)) < 0)", "parent": 65, "children": [67], "start_point": {"row": 42, "column": 4}, "end_point": {"row": 42, "column": 38}}, {"id": 67, "type": "binary_expression", "text": "(fd = open(argv[1], O_RDWR)) < 0", "parent": 66, "children": [68, 79, 80], "start_point": {"row": 42, "column": 5}, "end_point": {"row": 42, "column": 37}}, {"id": 68, "type": "parenthesized_expression", "text": "(fd = open(argv[1], O_RDWR))", "parent": 67, "children": [69], "start_point": {"row": 42, "column": 5}, "end_point": {"row": 42, "column": 33}}, {"id": 69, "type": "assignment_expression", "text": "fd = open(argv[1], O_RDWR)", "parent": 68, "children": [70, 71, 72], "start_point": {"row": 42, "column": 6}, "end_point": {"row": 42, "column": 32}}, {"id": 70, "type": "identifier", "text": "fd", "parent": 69, "children": [], "start_point": {"row": 42, "column": 6}, "end_point": {"row": 42, "column": 8}}, {"id": 71, "type": "=", "text": "=", "parent": 69, "children": [], "start_point": {"row": 42, "column": 9}, "end_point": {"row": 42, "column": 10}}, {"id": 72, "type": "call_expression", "text": "open(argv[1], O_RDWR)", "parent": 69, "children": [73, 74], "start_point": {"row": 42, "column": 11}, "end_point": {"row": 42, "column": 32}}, {"id": 73, "type": "identifier", "text": "open", "parent": 72, "children": [], "start_point": {"row": 42, "column": 11}, "end_point": {"row": 42, "column": 15}}, {"id": 74, "type": "argument_list", "text": "(argv[1], O_RDWR)", "parent": 72, "children": [75, 78], "start_point": {"row": 42, "column": 15}, "end_point": {"row": 42, "column": 32}}, {"id": 75, "type": "subscript_expression", "text": "argv[1]", "parent": 74, "children": [76, 77], "start_point": {"row": 42, "column": 16}, "end_point": {"row": 42, "column": 23}}, {"id": 76, "type": "identifier", "text": "argv", "parent": 75, "children": [], "start_point": {"row": 42, "column": 16}, "end_point": {"row": 42, "column": 20}}, {"id": 77, "type": "number_literal", "text": "1", "parent": 75, "children": [], "start_point": {"row": 42, "column": 21}, "end_point": {"row": 42, "column": 22}}, {"id": 78, "type": "identifier", "text": "O_RDWR", "parent": 74, "children": [], "start_point": {"row": 42, "column": 25}, "end_point": {"row": 42, "column": 31}}, {"id": 79, "type": "<", "text": "<", "parent": 67, "children": [], "start_point": {"row": 42, "column": 34}, "end_point": {"row": 42, "column": 35}}, {"id": 80, "type": "number_literal", "text": "0", "parent": 67, "children": [], "start_point": {"row": 42, "column": 36}, "end_point": {"row": 42, "column": 37}}, {"id": 81, "type": "call_expression", "text": "err(EXIT_FAILURE, \"failed to open %s\", argv[1])", "parent": 65, "children": [82, 83], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 43, "column": 49}}, {"id": 82, "type": "identifier", "text": "err", "parent": 81, "children": [], "start_point": {"row": 43, "column": 2}, "end_point": {"row": 43, "column": 5}}, {"id": 83, "type": "argument_list", "text": "(EXIT_FAILURE, \"failed to open %s\", argv[1])", "parent": 81, "children": [84, 85, 86], "start_point": {"row": 43, "column": 5}, "end_point": {"row": 43, "column": 49}}, {"id": 84, "type": "identifier", "text": "EXIT_FAILURE", "parent": 83, "children": [], "start_point": {"row": 43, "column": 6}, "end_point": {"row": 43, "column": 18}}, {"id": 85, "type": "string_literal", "text": "\"failed to open %s\"", "parent": 83, "children": [], "start_point": {"row": 43, "column": 20}, "end_point": {"row": 43, "column": 39}}, {"id": 86, "type": "subscript_expression", "text": "argv[1]", "parent": 83, "children": [87, 88], "start_point": {"row": 43, "column": 41}, "end_point": {"row": 43, "column": 48}}, {"id": 87, "type": "identifier", "text": "argv", "parent": 86, "children": [], "start_point": {"row": 43, "column": 41}, "end_point": {"row": 43, "column": 45}}, {"id": 88, "type": "number_literal", "text": "1", "parent": 86, "children": [], "start_point": {"row": 43, "column": 46}, "end_point": {"row": 43, "column": 47}}, {"id": 89, "type": "call_expression", "text": "bzero(&begin, sizeof (begin))", "parent": 27, "children": [90, 91], "start_point": {"row": 46, "column": 1}, "end_point": {"row": 46, "column": 30}}, {"id": 90, "type": "identifier", "text": "bzero", "parent": 89, "children": [], "start_point": {"row": 46, "column": 1}, "end_point": {"row": 46, "column": 6}}, {"id": 91, "type": "argument_list", "text": "(&begin, sizeof (begin))", "parent": 89, "children": [92, 93], "start_point": {"row": 46, "column": 6}, "end_point": {"row": 46, "column": 30}}, {"id": 92, "type": "pointer_expression", "text": "&begin", "parent": 91, "children": [], "start_point": {"row": 46, "column": 7}, "end_point": {"row": 46, "column": 13}}, {"id": 93, "type": "sizeof_expression", "text": "sizeof (begin)", "parent": 91, "children": [94], "start_point": {"row": 46, "column": 15}, "end_point": {"row": 46, "column": 29}}, {"id": 94, "type": "parenthesized_expression", "text": "(begin)", "parent": 93, "children": [], "start_point": {"row": 46, "column": 22}, "end_point": {"row": 46, "column": 29}}, {"id": 95, "type": "assignment_expression", "text": "begin.uct_version = UCCID_CURRENT_VERSION", "parent": 27, "children": [96, 98, 99], "start_point": {"row": 47, "column": 1}, "end_point": {"row": 47, "column": 42}}, {"id": 96, "type": "field_expression", "text": "begin.uct_version", "parent": 95, "children": [97], "start_point": {"row": 47, "column": 1}, "end_point": {"row": 47, "column": 18}}, {"id": 97, "type": "field_identifier", "text": "uct_version", "parent": 96, "children": [], "start_point": {"row": 47, "column": 7}, "end_point": {"row": 47, "column": 18}}, {"id": 98, "type": "=", "text": "=", "parent": 95, "children": [], "start_point": {"row": 47, "column": 19}, "end_point": {"row": 47, "column": 20}}, {"id": 99, "type": "identifier", "text": "UCCID_CURRENT_VERSION", "parent": 95, "children": [], "start_point": {"row": 47, "column": 21}, "end_point": {"row": 47, "column": 42}}, {"id": 100, "type": "assignment_expression", "text": "ret = read(fd, buf, sizeof (buf))", "parent": 27, "children": [101, 102, 103], "start_point": {"row": 52, "column": 1}, "end_point": {"row": 52, "column": 34}}, {"id": 101, "type": "identifier", "text": "ret", "parent": 100, "children": [], "start_point": {"row": 52, "column": 1}, "end_point": {"row": 52, "column": 4}}, {"id": 102, "type": "=", "text": "=", "parent": 100, "children": [], "start_point": {"row": 52, "column": 5}, "end_point": {"row": 52, "column": 6}}, {"id": 103, "type": "call_expression", "text": "read(fd, buf, sizeof (buf))", "parent": 100, "children": [104, 105], "start_point": {"row": 52, "column": 7}, "end_point": {"row": 52, "column": 34}}, {"id": 104, "type": "identifier", "text": "read", "parent": 103, "children": [], "start_point": {"row": 52, "column": 7}, "end_point": {"row": 52, "column": 11}}, {"id": 105, "type": "argument_list", "text": "(fd, buf, sizeof (buf))", "parent": 103, "children": [106, 107, 108], "start_point": {"row": 52, "column": 11}, "end_point": {"row": 52, "column": 34}}, {"id": 106, "type": "identifier", "text": "fd", "parent": 105, "children": [], "start_point": {"row": 52, "column": 12}, "end_point": {"row": 52, "column": 14}}, {"id": 107, "type": "identifier", "text": "buf", "parent": 105, "children": [], "start_point": {"row": 52, "column": 16}, "end_point": {"row": 52, "column": 19}}, {"id": 108, "type": "sizeof_expression", "text": "sizeof (buf)", "parent": 105, "children": [109], "start_point": {"row": 52, "column": 21}, "end_point": {"row": 52, "column": 33}}, {"id": 109, "type": "parenthesized_expression", "text": "(buf)", "parent": 108, "children": [110], "start_point": {"row": 52, "column": 28}, "end_point": {"row": 52, "column": 33}}, {"id": 110, "type": "identifier", "text": "buf", "parent": 109, "children": [], "start_point": {"row": 52, "column": 29}, "end_point": {"row": 52, "column": 32}}, {"id": 111, "type": "if_statement", "text": "if (ret != -1) {\n\t\terrx(EXIT_FAILURE, \"read succeeded when it should have failed \"\n\t\t \"(EACCES case), returned %ld\", ret);\n\t}", "parent": 27, "children": [112], "start_point": {"row": 53, "column": 1}, "end_point": {"row": 56, "column": 2}}, {"id": 112, "type": "parenthesized_expression", "text": "(ret != -1)", "parent": 111, "children": [113], "start_point": {"row": 53, "column": 4}, "end_point": {"row": 53, "column": 15}}, {"id": 113, "type": "binary_expression", "text": "ret != -1", "parent": 112, "children": [114, 115, 116], "start_point": {"row": 53, "column": 5}, "end_point": {"row": 53, "column": 14}}, {"id": 114, "type": "identifier", "text": "ret", "parent": 113, "children": [], "start_point": {"row": 53, "column": 5}, "end_point": {"row": 53, "column": 8}}, {"id": 115, "type": "!=", "text": "!=", "parent": 113, "children": [], "start_point": {"row": 53, "column": 9}, "end_point": {"row": 53, "column": 11}}, {"id": 116, "type": "number_literal", "text": "-1", "parent": 113, "children": [], "start_point": {"row": 53, "column": 12}, "end_point": {"row": 53, "column": 14}}, {"id": 117, "type": "call_expression", "text": "errx(EXIT_FAILURE, \"read succeeded when it should have failed \"\n\t\t \"(EACCES case), returned %ld\", ret)", "parent": 111, "children": [118, 119], "start_point": {"row": 54, "column": 2}, "end_point": {"row": 55, "column": 41}}, {"id": 118, "type": "identifier", "text": "errx", "parent": 117, "children": [], "start_point": {"row": 54, "column": 2}, "end_point": {"row": 54, "column": 6}}, {"id": 119, "type": "argument_list", "text": "(EXIT_FAILURE, \"read succeeded when it should have failed \"\n\t\t \"(EACCES case), returned %ld\", ret)", "parent": 117, "children": [120, 121, 124], "start_point": {"row": 54, "column": 6}, "end_point": {"row": 55, "column": 41}}, {"id": 120, "type": "identifier", "text": "EXIT_FAILURE", "parent": 119, "children": [], "start_point": {"row": 54, "column": 7}, "end_point": {"row": 54, "column": 19}}, {"id": 121, "type": "concatenated_string", "text": "\"read succeeded when it should have failed \"\n\t\t \"(EACCES case), returned %ld\"", "parent": 119, "children": [122, 123], "start_point": {"row": 54, "column": 21}, "end_point": {"row": 55, "column": 35}}, {"id": 122, "type": "string_literal", "text": "\"read succeeded when it should have failed \"", "parent": 121, "children": [], "start_point": {"row": 54, "column": 21}, "end_point": {"row": 54, "column": 65}}, {"id": 123, "type": "string_literal", "text": "\"(EACCES case), returned %ld\"", "parent": 121, "children": [], "start_point": {"row": 55, "column": 6}, "end_point": {"row": 55, "column": 35}}, {"id": 124, "type": "identifier", "text": "ret", "parent": 119, "children": [], "start_point": {"row": 55, "column": 37}, "end_point": {"row": 55, "column": 40}}, {"id": 125, "type": "if_statement", "text": "if (errno != EACCES) {\n\t\terrx(EXIT_FAILURE, \"found wrong value for errno. Expected \"\n\t\t \"%d, received %d\", EACCES, errno);\n\t}", "parent": 27, "children": [126], "start_point": {"row": 58, "column": 1}, "end_point": {"row": 61, "column": 2}}, {"id": 126, "type": "parenthesized_expression", "text": "(errno != EACCES)", "parent": 125, "children": [127], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 21}}, {"id": 127, "type": "binary_expression", "text": "errno != EACCES", "parent": 126, "children": [128, 129, 130], "start_point": {"row": 58, "column": 5}, "end_point": {"row": 58, "column": 20}}, {"id": 128, "type": "identifier", "text": "errno", "parent": 127, "children": [], "start_point": {"row": 58, "column": 5}, "end_point": {"row": 58, "column": 10}}, {"id": 129, "type": "!=", "text": "!=", "parent": 127, "children": [], "start_point": {"row": 58, "column": 11}, "end_point": {"row": 58, "column": 13}}, {"id": 130, "type": "identifier", "text": "EACCES", "parent": 127, "children": [], "start_point": {"row": 58, "column": 14}, "end_point": {"row": 58, "column": 20}}, {"id": 131, "type": "call_expression", "text": "errx(EXIT_FAILURE, \"found wrong value for errno. Expected \"\n\t\t \"%d, received %d\", EACCES, errno)", "parent": 125, "children": [132, 133], "start_point": {"row": 59, "column": 2}, "end_point": {"row": 60, "column": 39}}, {"id": 132, "type": "identifier", "text": "errx", "parent": 131, "children": [], "start_point": {"row": 59, "column": 2}, "end_point": {"row": 59, "column": 6}}, {"id": 133, "type": "argument_list", "text": "(EXIT_FAILURE, \"found wrong value for errno. Expected \"\n\t\t \"%d, received %d\", EACCES, errno)", "parent": 131, "children": [134, 135, 138, 139], "start_point": {"row": 59, "column": 6}, "end_point": {"row": 60, "column": 39}}, {"id": 134, "type": "identifier", "text": "EXIT_FAILURE", "parent": 133, "children": [], "start_point": {"row": 59, "column": 7}, "end_point": {"row": 59, "column": 19}}, {"id": 135, "type": "concatenated_string", "text": "\"found wrong value for errno. Expected \"\n\t\t \"%d, received %d\"", "parent": 133, "children": [136, 137], "start_point": {"row": 59, "column": 21}, "end_point": {"row": 60, "column": 23}}, {"id": 136, "type": "string_literal", "text": "\"found wrong value for errno. Expected \"", "parent": 135, "children": [], "start_point": {"row": 59, "column": 21}, "end_point": {"row": 59, "column": 61}}, {"id": 137, "type": "string_literal", "text": "\"%d, received %d\"", "parent": 135, "children": [], "start_point": {"row": 60, "column": 6}, "end_point": {"row": 60, "column": 23}}, {"id": 138, "type": "identifier", "text": "EACCES", "parent": 133, "children": [], "start_point": {"row": 60, "column": 25}, "end_point": {"row": 60, "column": 31}}, {"id": 139, "type": "identifier", "text": "errno", "parent": 133, "children": [], "start_point": {"row": 60, "column": 33}, "end_point": {"row": 60, "column": 38}}, {"id": 140, "type": "if_statement", "text": "if (ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin) != 0) {\n\t\terr(EXIT_FAILURE, \"failed to issue begin ioctl\");\n\t}", "parent": 27, "children": [141], "start_point": {"row": 63, "column": 1}, "end_point": {"row": 65, "column": 2}}, {"id": 141, "type": "parenthesized_expression", "text": "(ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin) != 0)", "parent": 140, "children": [142], "start_point": {"row": 63, "column": 4}, "end_point": {"row": 63, "column": 49}}, {"id": 142, "type": "binary_expression", "text": "ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin) != 0", "parent": 141, "children": [143, 149, 150], "start_point": {"row": 63, "column": 5}, "end_point": {"row": 63, "column": 48}}, {"id": 143, "type": "call_expression", "text": "ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin)", "parent": 142, "children": [144, 145], "start_point": {"row": 63, "column": 5}, "end_point": {"row": 63, "column": 43}}, {"id": 144, "type": "identifier", "text": "ioctl", "parent": 143, "children": [], "start_point": {"row": 63, "column": 5}, "end_point": {"row": 63, "column": 10}}, {"id": 145, "type": "argument_list", "text": "(fd, UCCID_CMD_TXN_BEGIN, &begin)", "parent": 143, "children": [146, 147, 148], "start_point": {"row": 63, "column": 10}, "end_point": {"row": 63, "column": 43}}, {"id": 146, "type": "identifier", "text": "fd", "parent": 145, "children": [], "start_point": {"row": 63, "column": 11}, "end_point": {"row": 63, "column": 13}}, {"id": 147, "type": "identifier", "text": "UCCID_CMD_TXN_BEGIN", "parent": 145, "children": [], "start_point": {"row": 63, "column": 15}, "end_point": {"row": 63, "column": 34}}, {"id": 148, "type": "pointer_expression", "text": "&begin", "parent": 145, "children": [], "start_point": {"row": 63, "column": 36}, "end_point": {"row": 63, "column": 42}}, {"id": 149, "type": "!=", "text": "!=", "parent": 142, "children": [], "start_point": {"row": 63, "column": 44}, "end_point": {"row": 63, "column": 46}}, {"id": 150, "type": "number_literal", "text": "0", "parent": 142, "children": [], "start_point": {"row": 63, "column": 47}, "end_point": {"row": 63, "column": 48}}, {"id": 151, "type": "call_expression", "text": "err(EXIT_FAILURE, \"failed to issue begin ioctl\")", "parent": 140, "children": [152, 153], "start_point": {"row": 64, "column": 2}, "end_point": {"row": 64, "column": 50}}, {"id": 152, "type": "identifier", "text": "err", "parent": 151, "children": [], "start_point": {"row": 64, "column": 2}, "end_point": {"row": 64, "column": 5}}, {"id": 153, "type": "argument_list", "text": "(EXIT_FAILURE, \"failed to issue begin ioctl\")", "parent": 151, "children": [154, 155], "start_point": {"row": 64, "column": 5}, "end_point": {"row": 64, "column": 50}}, {"id": 154, "type": "identifier", "text": "EXIT_FAILURE", "parent": 153, "children": [], "start_point": {"row": 64, "column": 6}, "end_point": {"row": 64, "column": 18}}, {"id": 155, "type": "string_literal", "text": "\"failed to issue begin ioctl\"", "parent": 153, "children": [], "start_point": {"row": 64, "column": 20}, "end_point": {"row": 64, "column": 49}}, {"id": 156, "type": "assignment_expression", "text": "ret = read(fd, buf, sizeof (buf))", "parent": 27, "children": [157, 158, 159], "start_point": {"row": 67, "column": 1}, "end_point": {"row": 67, "column": 34}}, {"id": 157, "type": "identifier", "text": "ret", "parent": 156, "children": [], "start_point": {"row": 67, "column": 1}, "end_point": {"row": 67, "column": 4}}, {"id": 158, "type": "=", "text": "=", "parent": 156, "children": [], "start_point": {"row": 67, "column": 5}, "end_point": {"row": 67, "column": 6}}, {"id": 159, "type": "call_expression", "text": "read(fd, buf, sizeof (buf))", "parent": 156, "children": [160, 161], "start_point": {"row": 67, "column": 7}, "end_point": {"row": 67, "column": 34}}, {"id": 160, "type": "identifier", "text": "read", "parent": 159, "children": [], "start_point": {"row": 67, "column": 7}, "end_point": {"row": 67, "column": 11}}, {"id": 161, "type": "argument_list", "text": "(fd, buf, sizeof (buf))", "parent": 159, "children": [162, 163, 164], "start_point": {"row": 67, "column": 11}, "end_point": {"row": 67, "column": 34}}, {"id": 162, "type": "identifier", "text": "fd", "parent": 161, "children": [], "start_point": {"row": 67, "column": 12}, "end_point": {"row": 67, "column": 14}}, {"id": 163, "type": "identifier", "text": "buf", "parent": 161, "children": [], "start_point": {"row": 67, "column": 16}, "end_point": {"row": 67, "column": 19}}, {"id": 164, "type": "sizeof_expression", "text": "sizeof (buf)", "parent": 161, "children": [165], "start_point": {"row": 67, "column": 21}, "end_point": {"row": 67, "column": 33}}, {"id": 165, "type": "parenthesized_expression", "text": "(buf)", "parent": 164, "children": [166], "start_point": {"row": 67, "column": 28}, "end_point": {"row": 67, "column": 33}}, {"id": 166, "type": "identifier", "text": "buf", "parent": 165, "children": [], "start_point": {"row": 67, "column": 29}, "end_point": {"row": 67, "column": 32}}, {"id": 167, "type": "if_statement", "text": "if (ret != -1) {\n\t\terrx(EXIT_FAILURE, \"read succeeded when it should have failed \"\n\t\t \"(ENODATA case), returned %ld\", ret);\n\t}", "parent": 27, "children": [168], "start_point": {"row": 68, "column": 1}, "end_point": {"row": 71, "column": 2}}, {"id": 168, "type": "parenthesized_expression", "text": "(ret != -1)", "parent": 167, "children": [169], "start_point": {"row": 68, "column": 4}, "end_point": {"row": 68, "column": 15}}, {"id": 169, "type": "binary_expression", "text": "ret != -1", "parent": 168, "children": [170, 171, 172], "start_point": {"row": 68, "column": 5}, "end_point": {"row": 68, "column": 14}}, {"id": 170, "type": "identifier", "text": "ret", "parent": 169, "children": [], "start_point": {"row": 68, "column": 5}, "end_point": {"row": 68, "column": 8}}, {"id": 171, "type": "!=", "text": "!=", "parent": 169, "children": [], "start_point": {"row": 68, "column": 9}, "end_point": {"row": 68, "column": 11}}, {"id": 172, "type": "number_literal", "text": "-1", "parent": 169, "children": [], "start_point": {"row": 68, "column": 12}, "end_point": {"row": 68, "column": 14}}, {"id": 173, "type": "call_expression", "text": "errx(EXIT_FAILURE, \"read succeeded when it should have failed \"\n\t\t \"(ENODATA case), returned %ld\", ret)", "parent": 167, "children": [174, 175], "start_point": {"row": 69, "column": 2}, "end_point": {"row": 70, "column": 42}}, {"id": 174, "type": "identifier", "text": "errx", "parent": 173, "children": [], "start_point": {"row": 69, "column": 2}, "end_point": {"row": 69, "column": 6}}, {"id": 175, "type": "argument_list", "text": "(EXIT_FAILURE, \"read succeeded when it should have failed \"\n\t\t \"(ENODATA case), returned %ld\", ret)", "parent": 173, "children": [176, 177, 180], "start_point": {"row": 69, "column": 6}, "end_point": {"row": 70, "column": 42}}, {"id": 176, "type": "identifier", "text": "EXIT_FAILURE", "parent": 175, "children": [], "start_point": {"row": 69, "column": 7}, "end_point": {"row": 69, "column": 19}}, {"id": 177, "type": "concatenated_string", "text": "\"read succeeded when it should have failed \"\n\t\t \"(ENODATA case), returned %ld\"", "parent": 175, "children": [178, 179], "start_point": {"row": 69, "column": 21}, "end_point": {"row": 70, "column": 36}}, {"id": 178, "type": "string_literal", "text": "\"read succeeded when it should have failed \"", "parent": 177, "children": [], "start_point": {"row": 69, "column": 21}, "end_point": {"row": 69, "column": 65}}, {"id": 179, "type": "string_literal", "text": "\"(ENODATA case), returned %ld\"", "parent": 177, "children": [], "start_point": {"row": 70, "column": 6}, "end_point": {"row": 70, "column": 36}}, {"id": 180, "type": "identifier", "text": "ret", "parent": 175, "children": [], "start_point": {"row": 70, "column": 38}, "end_point": {"row": 70, "column": 41}}, {"id": 181, "type": "if_statement", "text": "if (errno != ENODATA) {\n\t\terrx(EXIT_FAILURE, \"found wrong value for errno. Expected \"\n\t\t \"%d, received %d\", ENODATA, errno);\n\t}", "parent": 27, "children": [182], "start_point": {"row": 73, "column": 1}, "end_point": {"row": 76, "column": 2}}, {"id": 182, "type": "parenthesized_expression", "text": "(errno != ENODATA)", "parent": 181, "children": [183], "start_point": {"row": 73, "column": 4}, "end_point": {"row": 73, "column": 22}}, {"id": 183, "type": "binary_expression", "text": "errno != ENODATA", "parent": 182, "children": [184, 185, 186], "start_point": {"row": 73, "column": 5}, "end_point": {"row": 73, "column": 21}}, {"id": 184, "type": "identifier", "text": "errno", "parent": 183, "children": [], "start_point": {"row": 73, "column": 5}, "end_point": {"row": 73, "column": 10}}, {"id": 185, "type": "!=", "text": "!=", "parent": 183, "children": [], "start_point": {"row": 73, "column": 11}, "end_point": {"row": 73, "column": 13}}, {"id": 186, "type": "identifier", "text": "ENODATA", "parent": 183, "children": [], "start_point": {"row": 73, "column": 14}, "end_point": {"row": 73, "column": 21}}, {"id": 187, "type": "call_expression", "text": "errx(EXIT_FAILURE, \"found wrong value for errno. Expected \"\n\t\t \"%d, received %d\", ENODATA, errno)", "parent": 181, "children": [188, 189], "start_point": {"row": 74, "column": 2}, "end_point": {"row": 75, "column": 40}}, {"id": 188, "type": "identifier", "text": "errx", "parent": 187, "children": [], "start_point": {"row": 74, "column": 2}, "end_point": {"row": 74, "column": 6}}, {"id": 189, "type": "argument_list", "text": "(EXIT_FAILURE, \"found wrong value for errno. Expected \"\n\t\t \"%d, received %d\", ENODATA, errno)", "parent": 187, "children": [190, 191, 194, 195], "start_point": {"row": 74, "column": 6}, "end_point": {"row": 75, "column": 40}}, {"id": 190, "type": "identifier", "text": "EXIT_FAILURE", "parent": 189, "children": [], "start_point": {"row": 74, "column": 7}, "end_point": {"row": 74, "column": 19}}, {"id": 191, "type": "concatenated_string", "text": "\"found wrong value for errno. Expected \"\n\t\t \"%d, received %d\"", "parent": 189, "children": [192, 193], "start_point": {"row": 74, "column": 21}, "end_point": {"row": 75, "column": 23}}, {"id": 192, "type": "string_literal", "text": "\"found wrong value for errno. Expected \"", "parent": 191, "children": [], "start_point": {"row": 74, "column": 21}, "end_point": {"row": 74, "column": 61}}, {"id": 193, "type": "string_literal", "text": "\"%d, received %d\"", "parent": 191, "children": [], "start_point": {"row": 75, "column": 6}, "end_point": {"row": 75, "column": 23}}, {"id": 194, "type": "identifier", "text": "ENODATA", "parent": 189, "children": [], "start_point": {"row": 75, "column": 25}, "end_point": {"row": 75, "column": 32}}, {"id": 195, "type": "identifier", "text": "errno", "parent": 189, "children": [], "start_point": {"row": 75, "column": 34}, "end_point": {"row": 75, "column": 39}}, {"id": 196, "type": "return_statement", "text": "return (0);", "parent": 27, "children": [197], "start_point": {"row": 78, "column": 1}, "end_point": {"row": 78, "column": 12}}, {"id": 197, "type": "parenthesized_expression", "text": "(0)", "parent": 196, "children": [198], "start_point": {"row": 78, "column": 8}, "end_point": {"row": 78, "column": 11}}, {"id": 198, "type": "number_literal", "text": "0", "parent": 197, "children": [], "start_point": {"row": 78, "column": 9}, "end_point": {"row": 78, "column": 10}}]}, "node_categories": {"declarations": {"functions": [27, 29], "variables": [32, 35, 41, 44, 46, 49], "classes": [], "imports": [0, 1, 3, 4, 6, 7, 9, 10, 12, 13, 15, 16, 18, 19, 21, 22, 24, 25], "modules": [], "enums": []}, "statements": {"expressions": [55, 56, 60, 66, 67, 68, 72, 75, 81, 86, 89, 92, 93, 94, 96, 103, 108, 109, 112, 113, 117, 126, 127, 131, 141, 142, 143, 148, 151, 159, 164, 165, 168, 169, 173, 182, 183, 187, 197], "assignments": [69, 95, 100, 156], "loops": [], "conditionals": [30, 34, 40, 43, 45, 48, 52, 54, 57, 61, 63, 65, 70, 73, 76, 78, 82, 84, 87, 90, 97, 99, 101, 104, 106, 107, 110, 111, 114, 118, 120, 124, 125, 128, 130, 132, 134, 138, 139, 140, 144, 146, 147, 152, 154, 157, 160, 162, 163, 166, 167, 170, 174, 176, 180, 181, 184, 186, 188, 190, 194, 195], "returns": [196], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 8, 11, 14, 17, 20, 23, 26, 53, 59, 64, 77, 80, 85, 88, 116, 121, 122, 123, 135, 136, 137, 150, 155, 172, 177, 178, 179, 191, 192, 193, 198], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 27, "universal_type": "function", "name": "main", "text_snippet": "int\nmain(int argc, char *argv[])\n{\n\tint fd;\n\tuccid_cmd_txn_begin_t begin;\n\tssize_t ret;\n\tchar buf[50"}, {"node_id": 29, "universal_type": "function", "name": "unknown", "text_snippet": "main(int argc, char *argv[])"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <err.h>\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <stdlib.h>\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include <sys/types.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <sys/stat.h>\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include <fcntl.h>\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include <strings.h>\n"}, {"node_id": 16, "text": "#include"}, {"node_id": 18, "text": "#include <unistd.h>\n"}, {"node_id": 19, "text": "#include"}, {"node_id": 21, "text": "#include <errno.h>\n"}, {"node_id": 22, "text": "#include"}, {"node_id": 24, "text": "#include <sys/usb/clients/ccid/uccid.h>\n"}, {"node_id": 25, "text": "#include"}]}, "original_source_code": "/*\n * This file and its contents are supplied under the terms of the\n * Common Development and Distribution License (\"CDDL\"), version 1.0.\n * You may only use this file in accordance with the terms of version\n * 1.0 of the CDDL.\n *\n * A full copy of the text of the CDDL should have accompanied this\n * source. A copy of the CDDL is also available via the Internet at\n * http://www.illumos.org/license/CDDL.\n */\n\n/*\n * Copyright 2019, Joyent, Inc.\n */\n\n/*\n * Verify various bad read conditions fail successfully.\n */\n\n#include <err.h>\n#include <stdlib.h>\n#include <sys/types.h>\n#include <sys/stat.h>\n#include <fcntl.h>\n#include <strings.h>\n#include <unistd.h>\n#include <errno.h>\n\n#include <sys/usb/clients/ccid/uccid.h>\n\nint\nmain(int argc, char *argv[])\n{\n\tint fd;\n\tuccid_cmd_txn_begin_t begin;\n\tssize_t ret;\n\tchar buf[500];\n\n\tif (argc != 2) {\n\t\terrx(EXIT_FAILURE, \"missing required ccid path\");\n\t}\n\n\tif ((fd = open(argv[1], O_RDWR)) < 0) {\n\t\terr(EXIT_FAILURE, \"failed to open %s\", argv[1]);\n\t}\n\n\tbzero(&begin, sizeof (begin));\n\tbegin.uct_version = UCCID_CURRENT_VERSION;\n\n\t/*\n\t * Read without having a transaction\n\t */\n\tret = read(fd, buf, sizeof (buf));\n\tif (ret != -1) {\n\t\terrx(EXIT_FAILURE, \"read succeeded when it should have failed \"\n\t\t \"(EACCES case), returned %ld\", ret);\n\t}\n\n\tif (errno != EACCES) {\n\t\terrx(EXIT_FAILURE, \"found wrong value for errno. Expected \"\n\t\t \"%d, received %d\", EACCES, errno);\n\t}\n\n\tif (ioctl(fd, UCCID_CMD_TXN_BEGIN, &begin) != 0) {\n\t\terr(EXIT_FAILURE, \"failed to issue begin ioctl\");\n\t}\n\n\tret = read(fd, buf, sizeof (buf));\n\tif (ret != -1) {\n\t\terrx(EXIT_FAILURE, \"read succeeded when it should have failed \"\n\t\t \"(ENODATA case), returned %ld\", ret);\n\t}\n\n\tif (errno != ENODATA) {\n\t\terrx(EXIT_FAILURE, \"found wrong value for errno. Expected \"\n\t\t \"%d, received %d\", ENODATA, errno);\n\t}\n\n\treturn (0);\n}\n"}
80,594
c
/****************************************************************************** * Copyright (C) 2002 - 2021 Xilinx, Inc. All rights reserved. * SPDX-License-Identifier: MIT ******************************************************************************/ /*****************************************************************************/ /** * * @file xgpio_g.c * @addtogroup gpio_v4_8 * @{ * * This file contains a configuration table that specifies the configuration * of GPIO devices in the system. * * <pre> * MODIFICATION HISTORY: * * Ver Who Date Changes * ----- ---- -------- ----------------------------------------------- * 1.00a rmm 02/04/02 First release * 2.00a jhl 12/16/02 Update for dual channel and interrupt support * 2.11a mta 03/21/07 Updated to new coding style * 4.0 sha 07/15/15 Added XPAR_XGPIO_NUM_INSTANCES macro to control * config table parameters. * </pre> * ******************************************************************************/ /***************************** Include Files *********************************/ #include "xgpio.h" #include "xparameters.h" /************************** Constant Definitions *****************************/ /**************************** Type Definitions *******************************/ /***************** Macros (Inline Functions) Definitions *********************/ /************************** Function Prototypes ******************************/ /************************** Variable Prototypes ******************************/ /** * This table contains configuration information for each GPIO device * in the system. */ XGpio_Config XGpio_ConfigTable[] = { { #ifdef XPAR_XGPIO_NUM_INSTANCES XPAR_GPIO_0_DEVICE_ID, XPAR_GPIO_0_BASEADDR, XPAR_GPIO_0_INTERRUPT_PRESENT, XPAR_GPIO_0_IS_DUAL #endif } }; /** @} */
32.44
54
(translation_unit) "/******************************************************************************\n* Copyright (C) 2002 - 2021 Xilinx, Inc. All rights reserved.\n* SPDX-License-Identifier: MIT\n******************************************************************************/\n\n/*****************************************************************************/\n/**\n*\n* @file xgpio_g.c\n* @addtogroup gpio_v4_8\n* @{\n*\n* This file contains a configuration table that specifies the configuration\n* of GPIO devices in the system.\n*\n* <pre>\n* MODIFICATION HISTORY:\n*\n* Ver Who Date Changes\n* ----- ---- -------- -----------------------------------------------\n* 1.00a rmm 02/04/02 First release\n* 2.00a jhl 12/16/02 Update for dual channel and interrupt support\n* 2.11a mta 03/21/07 Updated to new coding style\n* 4.0 sha 07/15/15 Added XPAR_XGPIO_NUM_INSTANCES macro to control\n* config table parameters.\n* </pre>\n*\n******************************************************************************/\n\n/***************************** Include Files *********************************/\n\n#include "xgpio.h"\n#include "xparameters.h"\n\n/************************** Constant Definitions *****************************/\n\n\n/**************************** Type Definitions *******************************/\n\n\n/***************** Macros (Inline Functions) Definitions *********************/\n\n\n/************************** Function Prototypes ******************************/\n\n\n/************************** Variable Prototypes ******************************/\n\n/**\n * This table contains configuration information for each GPIO device\n * in the system.\n */\nXGpio_Config XGpio_ConfigTable[] = {\n {\n#ifdef XPAR_XGPIO_NUM_INSTANCES\n XPAR_GPIO_0_DEVICE_ID,\n XPAR_GPIO_0_BASEADDR,\n XPAR_GPIO_0_INTERRUPT_PRESENT,\n XPAR_GPIO_0_IS_DUAL\n#endif\n }\n};\n/** @} */\n" (comment) "/******************************************************************************\n* Copyright (C) 2002 - 2021 Xilinx, Inc. All rights reserved.\n* SPDX-License-Identifier: MIT\n******************************************************************************/" (comment) "/*****************************************************************************/" (comment) "/**\n*\n* @file xgpio_g.c\n* @addtogroup gpio_v4_8\n* @{\n*\n* This file contains a configuration table that specifies the configuration\n* of GPIO devices in the system.\n*\n* <pre>\n* MODIFICATION HISTORY:\n*\n* Ver Who Date Changes\n* ----- ---- -------- -----------------------------------------------\n* 1.00a rmm 02/04/02 First release\n* 2.00a jhl 12/16/02 Update for dual channel and interrupt support\n* 2.11a mta 03/21/07 Updated to new coding style\n* 4.0 sha 07/15/15 Added XPAR_XGPIO_NUM_INSTANCES macro to control\n* config table parameters.\n* </pre>\n*\n******************************************************************************/" (comment) "/***************************** Include Files *********************************/" (preproc_include) "#include "xgpio.h"\n" (#include) "#include" (string_literal) ""xgpio.h"" (") """ (string_content) "xgpio.h" (") """ (preproc_include) "#include "xparameters.h"\n" (#include) "#include" (string_literal) ""xparameters.h"" (") """ (string_content) "xparameters.h" (") """ (comment) "/************************** Constant Definitions *****************************/" (comment) "/**************************** Type Definitions *******************************/" (comment) "/***************** Macros (Inline Functions) Definitions *********************/" (comment) "/************************** Function Prototypes ******************************/" (comment) "/************************** Variable Prototypes ******************************/" (comment) "/**\n * This table contains configuration information for each GPIO device\n * in the system.\n */" (declaration) "XGpio_Config XGpio_ConfigTable[] = {\n {\n#ifdef XPAR_XGPIO_NUM_INSTANCES\n XPAR_GPIO_0_DEVICE_ID,\n XPAR_GPIO_0_BASEADDR,\n XPAR_GPIO_0_INTERRUPT_PRESENT,\n XPAR_GPIO_0_IS_DUAL\n#endif\n }\n};" (type_identifier) "XGpio_Config" (init_declarator) "XGpio_ConfigTable[] = {\n {\n#ifdef XPAR_XGPIO_NUM_INSTANCES\n XPAR_GPIO_0_DEVICE_ID,\n XPAR_GPIO_0_BASEADDR,\n XPAR_GPIO_0_INTERRUPT_PRESENT,\n XPAR_GPIO_0_IS_DUAL\n#endif\n }\n}" (array_declarator) "XGpio_ConfigTable[]" (identifier) "XGpio_ConfigTable" ([) "[" (]) "]" (=) "=" (initializer_list) "{\n {\n#ifdef XPAR_XGPIO_NUM_INSTANCES\n XPAR_GPIO_0_DEVICE_ID,\n XPAR_GPIO_0_BASEADDR,\n XPAR_GPIO_0_INTERRUPT_PRESENT,\n XPAR_GPIO_0_IS_DUAL\n#endif\n }\n}" ({) "{" (initializer_list) "{\n#ifdef XPAR_XGPIO_NUM_INSTANCES\n XPAR_GPIO_0_DEVICE_ID,\n XPAR_GPIO_0_BASEADDR,\n XPAR_GPIO_0_INTERRUPT_PRESENT,\n XPAR_GPIO_0_IS_DUAL\n#endif\n }" ({) "{" (ERROR) "#ifdef XPAR_XGPIO_NUM_INSTANCES" (#ifdef) "#ifdef" (identifier) "XPAR_XGPIO_NUM_INSTANCES" (identifier) "XPAR_GPIO_0_DEVICE_ID" (,) "," (identifier) "XPAR_GPIO_0_BASEADDR" (,) "," (identifier) "XPAR_GPIO_0_INTERRUPT_PRESENT" (,) "," (identifier) "XPAR_GPIO_0_IS_DUAL" (ERROR) "#endif" (#endif) "#endif" (}) "}" (}) "}" (;) ";" (comment) "/** @} */"
51
2
{"language": "c", "success": true, "metadata": {"lines": 54, "avg_line_length": 32.44, "nodes": 23, "errors": 0, "source_hash": "895b2e8ac806597c0d28ebfb0fddb714fa030f008cfc5ed909951e5bc71cb2d7", "categorized_nodes": 16}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"xgpio.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 32, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 31, "column": 0}, "end_point": {"row": 31, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"xgpio.h\"", "parent": 0, "children": [], "start_point": {"row": 31, "column": 9}, "end_point": {"row": 31, "column": 18}}, {"id": 3, "type": "preproc_include", "text": "#include \"xparameters.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 32, "column": 0}, "end_point": {"row": 33, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 32, "column": 0}, "end_point": {"row": 32, "column": 8}}, {"id": 5, "type": "string_literal", "text": "\"xparameters.h\"", "parent": 3, "children": [], "start_point": {"row": 32, "column": 9}, "end_point": {"row": 32, "column": 24}}, {"id": 6, "type": "declaration", "text": "XGpio_Config XGpio_ConfigTable[] = {\n\t{\n#ifdef XPAR_XGPIO_NUM_INSTANCES\n\t XPAR_GPIO_0_DEVICE_ID,\n\t XPAR_GPIO_0_BASEADDR,\n\t XPAR_GPIO_0_INTERRUPT_PRESENT,\n\t XPAR_GPIO_0_IS_DUAL\n#endif\n\t}\n};", "parent": null, "children": [7, 8], "start_point": {"row": 52, "column": 0}, "end_point": {"row": 61, "column": 2}}, {"id": 7, "type": "type_identifier", "text": "XGpio_Config", "parent": 6, "children": [], "start_point": {"row": 52, "column": 0}, "end_point": {"row": 52, "column": 12}}, {"id": 8, "type": "init_declarator", "text": "XGpio_ConfigTable[] = {\n\t{\n#ifdef XPAR_XGPIO_NUM_INSTANCES\n\t XPAR_GPIO_0_DEVICE_ID,\n\t XPAR_GPIO_0_BASEADDR,\n\t XPAR_GPIO_0_INTERRUPT_PRESENT,\n\t XPAR_GPIO_0_IS_DUAL\n#endif\n\t}\n}", "parent": 6, "children": [9, 11, 12], "start_point": {"row": 52, "column": 13}, "end_point": {"row": 61, "column": 1}}, {"id": 9, "type": "array_declarator", "text": "XGpio_ConfigTable[]", "parent": 8, "children": [10], "start_point": {"row": 52, "column": 13}, "end_point": {"row": 52, "column": 32}}, {"id": 10, "type": "identifier", "text": "XGpio_ConfigTable", "parent": 9, "children": [], "start_point": {"row": 52, "column": 13}, "end_point": {"row": 52, "column": 30}}, {"id": 11, "type": "=", "text": "=", "parent": 8, "children": [], "start_point": {"row": 52, "column": 33}, "end_point": {"row": 52, "column": 34}}, {"id": 12, "type": "initializer_list", "text": "{\n\t{\n#ifdef XPAR_XGPIO_NUM_INSTANCES\n\t XPAR_GPIO_0_DEVICE_ID,\n\t XPAR_GPIO_0_BASEADDR,\n\t XPAR_GPIO_0_INTERRUPT_PRESENT,\n\t XPAR_GPIO_0_IS_DUAL\n#endif\n\t}\n}", "parent": 8, "children": [13], "start_point": {"row": 52, "column": 35}, "end_point": {"row": 61, "column": 1}}, {"id": 13, "type": "initializer_list", "text": "{\n#ifdef XPAR_XGPIO_NUM_INSTANCES\n\t XPAR_GPIO_0_DEVICE_ID,\n\t XPAR_GPIO_0_BASEADDR,\n\t XPAR_GPIO_0_INTERRUPT_PRESENT,\n\t XPAR_GPIO_0_IS_DUAL\n#endif\n\t}", "parent": 12, "children": [14, 17, 18, 19, 20, 21], "start_point": {"row": 53, "column": 1}, "end_point": {"row": 60, "column": 2}}, {"id": 14, "type": "ERROR", "text": "#ifdef XPAR_XGPIO_NUM_INSTANCES", "parent": 13, "children": [15, 16], "start_point": {"row": 54, "column": 0}, "end_point": {"row": 54, "column": 31}}, {"id": 15, "type": "#ifdef", "text": "#ifdef", "parent": 14, "children": [], "start_point": {"row": 54, "column": 0}, "end_point": {"row": 54, "column": 6}}, {"id": 16, "type": "identifier", "text": "XPAR_XGPIO_NUM_INSTANCES", "parent": 14, "children": [], "start_point": {"row": 54, "column": 7}, "end_point": {"row": 54, "column": 31}}, {"id": 17, "type": "identifier", "text": "XPAR_GPIO_0_DEVICE_ID", "parent": 13, "children": [], "start_point": {"row": 55, "column": 2}, "end_point": {"row": 55, "column": 23}}, {"id": 18, "type": "identifier", "text": "XPAR_GPIO_0_BASEADDR", "parent": 13, "children": [], "start_point": {"row": 56, "column": 2}, "end_point": {"row": 56, "column": 22}}, {"id": 19, "type": "identifier", "text": "XPAR_GPIO_0_INTERRUPT_PRESENT", "parent": 13, "children": [], "start_point": {"row": 57, "column": 2}, "end_point": {"row": 57, "column": 31}}, {"id": 20, "type": "identifier", "text": "XPAR_GPIO_0_IS_DUAL", "parent": 13, "children": [], "start_point": {"row": 58, "column": 2}, "end_point": {"row": 58, "column": 21}}, {"id": 21, "type": "ERROR", "text": "#endif", "parent": 13, "children": [22], "start_point": {"row": 59, "column": 0}, "end_point": {"row": 59, "column": 6}}, {"id": 22, "type": "#endif", "text": "#endif", "parent": 21, "children": [], "start_point": {"row": 59, "column": 0}, "end_point": {"row": 59, "column": 6}}]}, "node_categories": {"declarations": {"functions": [], "variables": [6], "classes": [], "imports": [0, 1, 3, 4], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [7, 10, 15, 16, 17, 18, 19, 20, 22], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include \"xgpio.h\"\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include \"xparameters.h\"\n"}, {"node_id": 4, "text": "#include"}]}, "original_source_code": "/******************************************************************************\n* Copyright (C) 2002 - 2021 Xilinx, Inc. All rights reserved.\n* SPDX-License-Identifier: MIT\n******************************************************************************/\n\n/*****************************************************************************/\n/**\n*\n* @file xgpio_g.c\n* @addtogroup gpio_v4_8\n* @{\n*\n* This file contains a configuration table that specifies the configuration\n* of GPIO devices in the system.\n*\n* <pre>\n* MODIFICATION HISTORY:\n*\n* Ver Who Date Changes\n* ----- ---- -------- -----------------------------------------------\n* 1.00a rmm 02/04/02 First release\n* 2.00a jhl 12/16/02 Update for dual channel and interrupt support\n* 2.11a mta 03/21/07 Updated to new coding style\n* 4.0 sha 07/15/15 Added XPAR_XGPIO_NUM_INSTANCES macro to control\n*\t\t config table parameters.\n* </pre>\n*\n******************************************************************************/\n\n/***************************** Include Files *********************************/\n\n#include \"xgpio.h\"\n#include \"xparameters.h\"\n\n/************************** Constant Definitions *****************************/\n\n\n/**************************** Type Definitions *******************************/\n\n\n/***************** Macros (Inline Functions) Definitions *********************/\n\n\n/************************** Function Prototypes ******************************/\n\n\n/************************** Variable Prototypes ******************************/\n\n/**\n * This table contains configuration information for each GPIO device\n * in the system.\n */\nXGpio_Config XGpio_ConfigTable[] = {\n\t{\n#ifdef XPAR_XGPIO_NUM_INSTANCES\n\t XPAR_GPIO_0_DEVICE_ID,\n\t XPAR_GPIO_0_BASEADDR,\n\t XPAR_GPIO_0_INTERRUPT_PRESENT,\n\t XPAR_GPIO_0_IS_DUAL\n#endif\n\t}\n};\n/** @} */\n"}
80,595
c
#include <containers/containers.h> #include <mutex> namespace lambda { namespace foundation { class FrameHeap { public: friend FrameHeap* GetFrameHeap(); static constexpr uint32_t kHeapCount = 5u; static constexpr uint32_t kHistoryCount = 10u; FrameHeap(); ~FrameHeap(); void update(); void* alloc(uint32_t size); void* realloc(void* prev, uint32_t prev_size, uint32_t new_size); template<typename T> inline void deconstruct(T* t) { t->~T(); } template<typename T> inline T* construct() { T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); new (allocated) T(); return allocated; } template<typename T, typename ...Args> inline T* construct(Args&& ...args) { T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); new (allocated) T(eastl::forward<Args>(args)...); return allocated; } uint32_t currentHeapSize(); private: uint32_t current_frame_heap_; uint32_t current_history_; uint32_t allocated_; void* frame_heaps_[kHeapCount]; uint32_t heap_sizes_[kHeapCount]; uint32_t size_history_[kHistoryCount]; Vector<void*> temp_allocs_[kHeapCount]; std::mutex mutex_; protected: static FrameHeap* s_frame_heap_; }; extern FrameHeap* GetFrameHeap(); } }
23.81
59
(translation_unit) "#include <containers/containers.h> \n#include <mutex> \n \nnamespace lambda \n{ \n namespace foundation \n { \n class FrameHeap \n { \n public: \n friend FrameHeap* GetFrameHeap(); \n static constexpr uint32_t kHeapCount = 5u; \n static constexpr uint32_t kHistoryCount = 10u; \n \n FrameHeap(); \n ~FrameHeap(); \n void update(); \n void* alloc(uint32_t size); \n void* realloc(void* prev, uint32_t prev_size, uint32_t new_size); \n template<typename T> \n inline void deconstruct(T* t) \n { \n t->~T(); \n } \n template<typename T> \n inline T* construct() \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(); \n return allocated; \n } \n template<typename T, typename ...Args> \n inline T* construct(Args&& ...args) \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(eastl::forward<Args>(args)...); \n return allocated; \n } \n \n uint32_t currentHeapSize(); \n \n private: \n uint32_t current_frame_heap_; \n uint32_t current_history_; \n \n uint32_t allocated_; \n void* frame_heaps_[kHeapCount]; \n uint32_t heap_sizes_[kHeapCount]; \n uint32_t size_history_[kHistoryCount]; \n Vector<void*> temp_allocs_[kHeapCount]; \n std::mutex mutex_; \n \n protected: \n static FrameHeap* s_frame_heap_; \n }; \n \n extern FrameHeap* GetFrameHeap(); \n } \n}" (preproc_include) "#include <containers/containers.h> \n" (#include) "#include" (system_lib_string) "<containers/containers.h>" (preproc_include) "#include <mutex> \n" (#include) "#include" (system_lib_string) "<mutex>" (function_definition) "namespace lambda \n{ \n namespace foundation \n { \n class FrameHeap \n { \n public: \n friend FrameHeap* GetFrameHeap(); \n static constexpr uint32_t kHeapCount = 5u; \n static constexpr uint32_t kHistoryCount = 10u; \n \n FrameHeap(); \n ~FrameHeap(); \n void update(); \n void* alloc(uint32_t size); \n void* realloc(void* prev, uint32_t prev_size, uint32_t new_size); \n template<typename T> \n inline void deconstruct(T* t) \n { \n t->~T(); \n } \n template<typename T> \n inline T* construct() \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(); \n return allocated; \n } \n template<typename T, typename ...Args> \n inline T* construct(Args&& ...args) \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(eastl::forward<Args>(args)...); \n return allocated; \n } \n \n uint32_t currentHeapSize(); \n \n private: \n uint32_t current_frame_heap_; \n uint32_t current_history_; \n \n uint32_t allocated_; \n void* frame_heaps_[kHeapCount]; \n uint32_t heap_sizes_[kHeapCount]; \n uint32_t size_history_[kHistoryCount]; \n Vector<void*> temp_allocs_[kHeapCount]; \n std::mutex mutex_; \n \n protected: \n static FrameHeap* s_frame_heap_; \n }; \n \n extern FrameHeap* GetFrameHeap(); \n } \n}" (type_identifier) "namespace" (identifier) "lambda" (compound_statement) "{ \n namespace foundation \n { \n class FrameHeap \n { \n public: \n friend FrameHeap* GetFrameHeap(); \n static constexpr uint32_t kHeapCount = 5u; \n static constexpr uint32_t kHistoryCount = 10u; \n \n FrameHeap(); \n ~FrameHeap(); \n void update(); \n void* alloc(uint32_t size); \n void* realloc(void* prev, uint32_t prev_size, uint32_t new_size); \n template<typename T> \n inline void deconstruct(T* t) \n { \n t->~T(); \n } \n template<typename T> \n inline T* construct() \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(); \n return allocated; \n } \n template<typename T, typename ...Args> \n inline T* construct(Args&& ...args) \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(eastl::forward<Args>(args)...); \n return allocated; \n } \n \n uint32_t currentHeapSize(); \n \n private: \n uint32_t current_frame_heap_; \n uint32_t current_history_; \n \n uint32_t allocated_; \n void* frame_heaps_[kHeapCount]; \n uint32_t heap_sizes_[kHeapCount]; \n uint32_t size_history_[kHistoryCount]; \n Vector<void*> temp_allocs_[kHeapCount]; \n std::mutex mutex_; \n \n protected: \n static FrameHeap* s_frame_heap_; \n }; \n \n extern FrameHeap* GetFrameHeap(); \n } \n}" ({) "{" (function_definition) "namespace foundation \n { \n class FrameHeap \n { \n public: \n friend FrameHeap* GetFrameHeap(); \n static constexpr uint32_t kHeapCount = 5u; \n static constexpr uint32_t kHistoryCount = 10u; \n \n FrameHeap(); \n ~FrameHeap(); \n void update(); \n void* alloc(uint32_t size); \n void* realloc(void* prev, uint32_t prev_size, uint32_t new_size); \n template<typename T> \n inline void deconstruct(T* t) \n { \n t->~T(); \n } \n template<typename T> \n inline T* construct() \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(); \n return allocated; \n } \n template<typename T, typename ...Args> \n inline T* construct(Args&& ...args) \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(eastl::forward<Args>(args)...); \n return allocated; \n } \n \n uint32_t currentHeapSize(); \n \n private: \n uint32_t current_frame_heap_; \n uint32_t current_history_; \n \n uint32_t allocated_; \n void* frame_heaps_[kHeapCount]; \n uint32_t heap_sizes_[kHeapCount]; \n uint32_t size_history_[kHistoryCount]; \n Vector<void*> temp_allocs_[kHeapCount]; \n std::mutex mutex_; \n \n protected: \n static FrameHeap* s_frame_heap_; \n }; \n \n extern FrameHeap* GetFrameHeap(); \n }" (type_identifier) "namespace" (identifier) "foundation" (compound_statement) "{ \n class FrameHeap \n { \n public: \n friend FrameHeap* GetFrameHeap(); \n static constexpr uint32_t kHeapCount = 5u; \n static constexpr uint32_t kHistoryCount = 10u; \n \n FrameHeap(); \n ~FrameHeap(); \n void update(); \n void* alloc(uint32_t size); \n void* realloc(void* prev, uint32_t prev_size, uint32_t new_size); \n template<typename T> \n inline void deconstruct(T* t) \n { \n t->~T(); \n } \n template<typename T> \n inline T* construct() \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(); \n return allocated; \n } \n template<typename T, typename ...Args> \n inline T* construct(Args&& ...args) \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(eastl::forward<Args>(args)...); \n return allocated; \n } \n \n uint32_t currentHeapSize(); \n \n private: \n uint32_t current_frame_heap_; \n uint32_t current_history_; \n \n uint32_t allocated_; \n void* frame_heaps_[kHeapCount]; \n uint32_t heap_sizes_[kHeapCount]; \n uint32_t size_history_[kHistoryCount]; \n Vector<void*> temp_allocs_[kHeapCount]; \n std::mutex mutex_; \n \n protected: \n static FrameHeap* s_frame_heap_; \n }; \n \n extern FrameHeap* GetFrameHeap(); \n }" ({) "{" (function_definition) "class FrameHeap \n { \n public: \n friend FrameHeap* GetFrameHeap(); \n static constexpr uint32_t kHeapCount = 5u; \n static constexpr uint32_t kHistoryCount = 10u; \n \n FrameHeap(); \n ~FrameHeap(); \n void update(); \n void* alloc(uint32_t size); \n void* realloc(void* prev, uint32_t prev_size, uint32_t new_size); \n template<typename T> \n inline void deconstruct(T* t) \n { \n t->~T(); \n } \n template<typename T> \n inline T* construct() \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(); \n return allocated; \n } \n template<typename T, typename ...Args> \n inline T* construct(Args&& ...args) \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(eastl::forward<Args>(args)...); \n return allocated; \n } \n \n uint32_t currentHeapSize(); \n \n private: \n uint32_t current_frame_heap_; \n uint32_t current_history_; \n \n uint32_t allocated_; \n void* frame_heaps_[kHeapCount]; \n uint32_t heap_sizes_[kHeapCount]; \n uint32_t size_history_[kHistoryCount]; \n Vector<void*> temp_allocs_[kHeapCount]; \n std::mutex mutex_; \n \n protected: \n static FrameHeap* s_frame_heap_; \n }" (type_identifier) "class" (identifier) "FrameHeap" (compound_statement) "{ \n public: \n friend FrameHeap* GetFrameHeap(); \n static constexpr uint32_t kHeapCount = 5u; \n static constexpr uint32_t kHistoryCount = 10u; \n \n FrameHeap(); \n ~FrameHeap(); \n void update(); \n void* alloc(uint32_t size); \n void* realloc(void* prev, uint32_t prev_size, uint32_t new_size); \n template<typename T> \n inline void deconstruct(T* t) \n { \n t->~T(); \n } \n template<typename T> \n inline T* construct() \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(); \n return allocated; \n } \n template<typename T, typename ...Args> \n inline T* construct(Args&& ...args) \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(eastl::forward<Args>(args)...); \n return allocated; \n } \n \n uint32_t currentHeapSize(); \n \n private: \n uint32_t current_frame_heap_; \n uint32_t current_history_; \n \n uint32_t allocated_; \n void* frame_heaps_[kHeapCount]; \n uint32_t heap_sizes_[kHeapCount]; \n uint32_t size_history_[kHistoryCount]; \n Vector<void*> temp_allocs_[kHeapCount]; \n std::mutex mutex_; \n \n protected: \n static FrameHeap* s_frame_heap_; \n }" ({) "{" (labeled_statement) "public: \n friend FrameHeap* GetFrameHeap();" (statement_identifier) "public" (:) ":" (declaration) "friend FrameHeap* GetFrameHeap();" (type_identifier) "friend" (ERROR) "FrameHeap" (identifier) "FrameHeap" (pointer_declarator) "* GetFrameHeap()" (*) "*" (function_declarator) "GetFrameHeap()" (identifier) "GetFrameHeap" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "static constexpr uint32_t kHeapCount = 5u;" (storage_class_specifier) "static" (static) "static" (type_qualifier) "constexpr" (constexpr) "constexpr" (primitive_type) "uint32_t" (init_declarator) "kHeapCount = 5u" (identifier) "kHeapCount" (=) "=" (number_literal) "5u" (;) ";" (declaration) "static constexpr uint32_t kHistoryCount = 10u;" (storage_class_specifier) "static" (static) "static" (type_qualifier) "constexpr" (constexpr) "constexpr" (primitive_type) "uint32_t" (init_declarator) "kHistoryCount = 10u" (identifier) "kHistoryCount" (=) "=" (number_literal) "10u" (;) ";" (expression_statement) "FrameHeap();" (call_expression) "FrameHeap()" (identifier) "FrameHeap" (argument_list) "()" (() "(" ()) ")" (;) ";" (expression_statement) "~FrameHeap();" (unary_expression) "~FrameHeap()" (~) "~" (call_expression) "FrameHeap()" (identifier) "FrameHeap" (argument_list) "()" (() "(" ()) ")" (;) ";" (declaration) "void update();" (primitive_type) "void" (function_declarator) "update()" (identifier) "update" (parameter_list) "()" (() "(" ()) ")" (;) ";" (declaration) "void* alloc(uint32_t size);" (primitive_type) "void" (pointer_declarator) "* alloc(uint32_t size)" (*) "*" (function_declarator) "alloc(uint32_t size)" (identifier) "alloc" (parameter_list) "(uint32_t size)" (() "(" (parameter_declaration) "uint32_t size" (primitive_type) "uint32_t" (identifier) "size" ()) ")" (;) ";" (declaration) "void* realloc(void* prev, uint32_t prev_size, uint32_t new_size);" (primitive_type) "void" (pointer_declarator) "* realloc(void* prev, uint32_t prev_size, uint32_t new_size)" (*) "*" (function_declarator) "realloc(void* prev, uint32_t prev_size, uint32_t new_size)" (identifier) "realloc" (parameter_list) "(void* prev, uint32_t prev_size, uint32_t new_size)" (() "(" (parameter_declaration) "void* prev" (primitive_type) "void" (pointer_declarator) "* prev" (*) "*" (identifier) "prev" (,) "," (parameter_declaration) "uint32_t prev_size" (primitive_type) "uint32_t" (identifier) "prev_size" (,) "," (parameter_declaration) "uint32_t new_size" (primitive_type) "uint32_t" (identifier) "new_size" ()) ")" (;) ";" (expression_statement) "template<typename T> \n inline" (binary_expression) "template<typename T> \n inline" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "inline" (;) "" (function_definition) "void deconstruct(T* t) \n { \n t->~T(); \n }" (primitive_type) "void" (function_declarator) "deconstruct(T* t)" (identifier) "deconstruct" (parameter_list) "(T* t)" (() "(" (parameter_declaration) "T* t" (type_identifier) "T" (pointer_declarator) "* t" (*) "*" (identifier) "t" ()) ")" (compound_statement) "{ \n t->~T(); \n }" ({) "{" (expression_statement) "t->~T();" (call_expression) "t->~T()" (field_expression) "t->~T" (identifier) "t" (->) "->" (ERROR) "~" (~) "~" (field_identifier) "T" (argument_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (expression_statement) "template<typename T> \n inline" (binary_expression) "template<typename T> \n inline" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (>) ">" (identifier) "inline" (;) "" (function_definition) "T* construct() \n { \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(); \n return allocated; \n }" (type_identifier) "T" (pointer_declarator) "* construct()" (*) "*" (function_declarator) "construct()" (identifier) "construct" (parameter_list) "()" (() "(" ()) ")" (compound_statement) "{ \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(); \n return allocated; \n }" ({) "{" (declaration) "T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));" (type_identifier) "T" (init_declarator) "* allocated = reinterpret_cast<T*>(alloc(sizeof(T)))" (pointer_declarator) "* allocated" (*) "*" (identifier) "allocated" (=) "=" (binary_expression) "reinterpret_cast<T*>(alloc(sizeof(T)))" (binary_expression) "reinterpret_cast<T" (identifier) "reinterpret_cast" (<) "<" (identifier) "T" (ERROR) "*" (*) "*" (>) ">" (parenthesized_expression) "(alloc(sizeof(T)))" (() "(" (call_expression) "alloc(sizeof(T))" (identifier) "alloc" (argument_list) "(sizeof(T))" (() "(" (sizeof_expression) "sizeof(T)" (sizeof) "sizeof" (parenthesized_expression) "(T)" (() "(" (identifier) "T" ()) ")" ()) ")" ()) ")" (;) ";" (declaration) "new (allocated) T();" (macro_type_specifier) "new (allocated)" (identifier) "new" (() "(" (type_descriptor) "allocated" (type_identifier) "allocated" ()) ")" (function_declarator) "T()" (identifier) "T" (parameter_list) "()" (() "(" ()) ")" (;) ";" (return_statement) "return allocated;" (return) "return" (identifier) "allocated" (;) ";" (}) "}" (expression_statement) "template<typename T, typename ...Args> \n inline T* construct(Args&& ...args)" (comma_expression) "template<typename T, typename ...Args> \n inline T* construct(Args&& ...args)" (binary_expression) "template<typename" (identifier) "template" (<) "<" (identifier) "typename" (ERROR) "T" (identifier) "T" (,) "," (binary_expression) "typename ...Args> \n inline T* construct(Args&& ...args)" (identifier) "typename" (ERROR) "...Args" (...) "..." (identifier) "Args" (>) ">" (binary_expression) "inline T* construct(Args&& ...args)" (identifier) "inline" (ERROR) "T" (identifier) "T" (*) "*" (call_expression) "construct(Args&& ...args)" (identifier) "construct" (argument_list) "(Args&& ...args)" (() "(" (binary_expression) "Args&& ...args" (identifier) "Args" (&&) "&&" (ERROR) "..." (.) "." (.) "." (.) "." (identifier) "args" ()) ")" (;) "" (compound_statement) "{ \n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T))); \n new (allocated) T(eastl::forward<Args>(args)...); \n return allocated; \n }" ({) "{" (declaration) "T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));" (type_identifier) "T" (init_declarator) "* allocated = reinterpret_cast<T*>(alloc(sizeof(T)))" (pointer_declarator) "* allocated" (*) "*" (identifier) "allocated" (=) "=" (binary_expression) "reinterpret_cast<T*>(alloc(sizeof(T)))" (binary_expression) "reinterpret_cast<T" (identifier) "reinterpret_cast" (<) "<" (identifier) "T" (ERROR) "*" (*) "*" (>) ">" (parenthesized_expression) "(alloc(sizeof(T)))" (() "(" (call_expression) "alloc(sizeof(T))" (identifier) "alloc" (argument_list) "(sizeof(T))" (() "(" (sizeof_expression) "sizeof(T)" (sizeof) "sizeof" (parenthesized_expression) "(T)" (() "(" (identifier) "T" ()) ")" ()) ")" ()) ")" (;) ";" (declaration) "new (allocated) T(eastl::forward<Args>(args)...);" (macro_type_specifier) "new (allocated)" (identifier) "new" (() "(" (type_descriptor) "allocated" (type_identifier) "allocated" ()) ")" (function_declarator) "T(eastl::forward<Args>(args)" (identifier) "T" (parameter_list) "(eastl::forward<Args>(args)" (() "(" (parameter_declaration) "eastl::forward<Args>(args" (type_identifier) "eastl" (ERROR) "::forward<Args>(" (:) ":" (:) ":" (identifier) "forward" (<) "<" (identifier) "Args" (>) ">" (() "(" (identifier) "args" ()) ")" (ERROR) "...)" (...) "..." ()) ")" (;) ";" (return_statement) "return allocated;" (return) "return" (identifier) "allocated" (;) ";" (}) "}" (declaration) "uint32_t currentHeapSize();" (primitive_type) "uint32_t" (function_declarator) "currentHeapSize()" (identifier) "currentHeapSize" (parameter_list) "()" (() "(" ()) ")" (;) ";" (labeled_statement) "private: \n uint32_t current_frame_heap_;" (statement_identifier) "private" (:) ":" (declaration) "uint32_t current_frame_heap_;" (primitive_type) "uint32_t" (identifier) "current_frame_heap_" (;) ";" (declaration) "uint32_t current_history_;" (primitive_type) "uint32_t" (identifier) "current_history_" (;) ";" (declaration) "uint32_t allocated_;" (primitive_type) "uint32_t" (identifier) "allocated_" (;) ";" (declaration) "void* frame_heaps_[kHeapCount];" (primitive_type) "void" (pointer_declarator) "* frame_heaps_[kHeapCount]" (*) "*" (array_declarator) "frame_heaps_[kHeapCount]" (identifier) "frame_heaps_" ([) "[" (identifier) "kHeapCount" (]) "]" (;) ";" (declaration) "uint32_t heap_sizes_[kHeapCount];" (primitive_type) "uint32_t" (array_declarator) "heap_sizes_[kHeapCount]" (identifier) "heap_sizes_" ([) "[" (identifier) "kHeapCount" (]) "]" (;) ";" (declaration) "uint32_t size_history_[kHistoryCount];" (primitive_type) "uint32_t" (array_declarator) "size_history_[kHistoryCount]" (identifier) "size_history_" ([) "[" (identifier) "kHistoryCount" (]) "]" (;) ";" (expression_statement) "Vector<void*> temp_allocs_[kHeapCount];" (binary_expression) "Vector<void*> temp_allocs_[kHeapCount]" (binary_expression) "Vector<void" (identifier) "Vector" (<) "<" (identifier) "void" (ERROR) "*" (*) "*" (>) ">" (subscript_expression) "temp_allocs_[kHeapCount]" (identifier) "temp_allocs_" ([) "[" (identifier) "kHeapCount" (]) "]" (;) ";" (labeled_statement) "std::mutex mutex_;" (statement_identifier) "std" (:) ":" (ERROR) ":" (:) ":" (declaration) "mutex mutex_;" (type_identifier) "mutex" (identifier) "mutex_" (;) ";" (labeled_statement) "protected: \n static FrameHeap* s_frame_heap_;" (statement_identifier) "protected" (:) ":" (declaration) "static FrameHeap* s_frame_heap_;" (storage_class_specifier) "static" (static) "static" (type_identifier) "FrameHeap" (pointer_declarator) "* s_frame_heap_" (*) "*" (identifier) "s_frame_heap_" (;) ";" (}) "}" (expression_statement) ";" (;) ";" (declaration) "extern FrameHeap* GetFrameHeap();" (storage_class_specifier) "extern" (extern) "extern" (type_identifier) "FrameHeap" (pointer_declarator) "* GetFrameHeap()" (*) "*" (function_declarator) "GetFrameHeap()" (identifier) "GetFrameHeap" (parameter_list) "()" (() "(" ()) ")" (;) ";" (}) "}" (}) "}"
426
14
{"language": "c", "success": true, "metadata": {"lines": 59, "avg_line_length": 23.81, "nodes": 281, "errors": 0, "source_hash": "df535b26edc87a79a7eba9325c5ca1f2d5d67b085c4bdb883fcf5d1078ecc967", "categorized_nodes": 173}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <containers/containers.h>\r\n", "parent": null, "children": [1, 2], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 1, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 0, "column": 0}, "end_point": {"row": 0, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<containers/containers.h>", "parent": 0, "children": [], "start_point": {"row": 0, "column": 9}, "end_point": {"row": 0, "column": 34}}, {"id": 3, "type": "preproc_include", "text": "#include <mutex>\r\n", "parent": null, "children": [4, 5], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 2, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<mutex>", "parent": 3, "children": [], "start_point": {"row": 1, "column": 9}, "end_point": {"row": 1, "column": 16}}, {"id": 6, "type": "function_definition", "text": "namespace lambda\r\n{\r\n namespace foundation\r\n {\r\n class FrameHeap\r\n {\r\n public:\r\n friend FrameHeap* GetFrameHeap();\r\n static constexpr uint32_t kHeapCount = 5u;\r\n static constexpr uint32_t kHistoryCount = 10u;\r\n\r\n\t\t\tFrameHeap();\r\n\t\t\t~FrameHeap();\r\n void update();\r\n void* alloc(uint32_t size);\r\n\t\t\tvoid* realloc(void* prev, uint32_t prev_size, uint32_t new_size);\r\n\t\t\ttemplate<typename T>\r\n\t\t\tinline void deconstruct(T* t)\r\n\t\t\t{\r\n\t\t\t\tt->~T();\r\n\t\t\t}\r\n template<typename T>\r\n inline T* construct()\r\n {\r\n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));\r\n new (allocated) T();\r\n return allocated;\r\n }\r\n template<typename T, typename ...Args>\r\n inline T* construct(Args&& ...args)\r\n {\r\n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));\r\n new (allocated) T(eastl::forward<Args>(args)...);\r\n return allocated;\r\n }\r\n\r\n uint32_t currentHeapSize();\r\n\r\n private:\r\n uint32_t current_frame_heap_;\r\n uint32_t current_history_;\r\n\r\n uint32_t allocated_;\r\n void* frame_heaps_[kHeapCount];\r\n uint32_t heap_sizes_[kHeapCount];\r\n uint32_t size_history_[kHistoryCount];\r\n Vector<void*> temp_allocs_[kHeapCount];\r\n\t\t\tstd::mutex mutex_;\r\n\r\n protected:\r\n static FrameHeap* s_frame_heap_;\r\n };\r\n\r\n extern FrameHeap* GetFrameHeap();\r\n }\r\n}", "parent": null, "children": [7, 8], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 58, "column": 1}}, {"id": 7, "type": "type_identifier", "text": "namespace", "parent": 6, "children": [], "start_point": {"row": 3, "column": 0}, "end_point": {"row": 3, "column": 9}}, {"id": 8, "type": "identifier", "text": "lambda", "parent": 6, "children": [], "start_point": {"row": 3, "column": 10}, "end_point": {"row": 3, "column": 16}}, {"id": 9, "type": "function_definition", "text": "namespace foundation\r\n {\r\n class FrameHeap\r\n {\r\n public:\r\n friend FrameHeap* GetFrameHeap();\r\n static constexpr uint32_t kHeapCount = 5u;\r\n static constexpr uint32_t kHistoryCount = 10u;\r\n\r\n\t\t\tFrameHeap();\r\n\t\t\t~FrameHeap();\r\n void update();\r\n void* alloc(uint32_t size);\r\n\t\t\tvoid* realloc(void* prev, uint32_t prev_size, uint32_t new_size);\r\n\t\t\ttemplate<typename T>\r\n\t\t\tinline void deconstruct(T* t)\r\n\t\t\t{\r\n\t\t\t\tt->~T();\r\n\t\t\t}\r\n template<typename T>\r\n inline T* construct()\r\n {\r\n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));\r\n new (allocated) T();\r\n return allocated;\r\n }\r\n template<typename T, typename ...Args>\r\n inline T* construct(Args&& ...args)\r\n {\r\n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));\r\n new (allocated) T(eastl::forward<Args>(args)...);\r\n return allocated;\r\n }\r\n\r\n uint32_t currentHeapSize();\r\n\r\n private:\r\n uint32_t current_frame_heap_;\r\n uint32_t current_history_;\r\n\r\n uint32_t allocated_;\r\n void* frame_heaps_[kHeapCount];\r\n uint32_t heap_sizes_[kHeapCount];\r\n uint32_t size_history_[kHistoryCount];\r\n Vector<void*> temp_allocs_[kHeapCount];\r\n\t\t\tstd::mutex mutex_;\r\n\r\n protected:\r\n static FrameHeap* s_frame_heap_;\r\n };\r\n\r\n extern FrameHeap* GetFrameHeap();\r\n }", "parent": 6, "children": [10, 11], "start_point": {"row": 5, "column": 2}, "end_point": {"row": 57, "column": 3}}, {"id": 10, "type": "type_identifier", "text": "namespace", "parent": 9, "children": [], "start_point": {"row": 5, "column": 2}, "end_point": {"row": 5, "column": 11}}, {"id": 11, "type": "identifier", "text": "foundation", "parent": 9, "children": [], "start_point": {"row": 5, "column": 12}, "end_point": {"row": 5, "column": 22}}, {"id": 12, "type": "function_definition", "text": "class FrameHeap\r\n {\r\n public:\r\n friend FrameHeap* GetFrameHeap();\r\n static constexpr uint32_t kHeapCount = 5u;\r\n static constexpr uint32_t kHistoryCount = 10u;\r\n\r\n\t\t\tFrameHeap();\r\n\t\t\t~FrameHeap();\r\n void update();\r\n void* alloc(uint32_t size);\r\n\t\t\tvoid* realloc(void* prev, uint32_t prev_size, uint32_t new_size);\r\n\t\t\ttemplate<typename T>\r\n\t\t\tinline void deconstruct(T* t)\r\n\t\t\t{\r\n\t\t\t\tt->~T();\r\n\t\t\t}\r\n template<typename T>\r\n inline T* construct()\r\n {\r\n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));\r\n new (allocated) T();\r\n return allocated;\r\n }\r\n template<typename T, typename ...Args>\r\n inline T* construct(Args&& ...args)\r\n {\r\n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));\r\n new (allocated) T(eastl::forward<Args>(args)...);\r\n return allocated;\r\n }\r\n\r\n uint32_t currentHeapSize();\r\n\r\n private:\r\n uint32_t current_frame_heap_;\r\n uint32_t current_history_;\r\n\r\n uint32_t allocated_;\r\n void* frame_heaps_[kHeapCount];\r\n uint32_t heap_sizes_[kHeapCount];\r\n uint32_t size_history_[kHistoryCount];\r\n Vector<void*> temp_allocs_[kHeapCount];\r\n\t\t\tstd::mutex mutex_;\r\n\r\n protected:\r\n static FrameHeap* s_frame_heap_;\r\n }", "parent": 9, "children": [13], "start_point": {"row": 7, "column": 4}, "end_point": {"row": 54, "column": 5}}, {"id": 13, "type": "identifier", "text": "FrameHeap", "parent": 12, "children": [], "start_point": {"row": 7, "column": 10}, "end_point": {"row": 7, "column": 19}}, {"id": 14, "type": "labeled_statement", "text": "public:\r\n friend FrameHeap* GetFrameHeap();", "parent": 12, "children": [15], "start_point": {"row": 9, "column": 4}, "end_point": {"row": 10, "column": 39}}, {"id": 15, "type": "declaration", "text": "friend FrameHeap* GetFrameHeap();", "parent": 14, "children": [16, 17, 19], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 39}}, {"id": 16, "type": "type_identifier", "text": "friend", "parent": 15, "children": [], "start_point": {"row": 10, "column": 6}, "end_point": {"row": 10, "column": 12}}, {"id": 17, "type": "ERROR", "text": "FrameHeap", "parent": 15, "children": [18], "start_point": {"row": 10, "column": 13}, "end_point": {"row": 10, "column": 22}}, {"id": 18, "type": "identifier", "text": "FrameHeap", "parent": 17, "children": [], "start_point": {"row": 10, "column": 13}, "end_point": {"row": 10, "column": 22}}, {"id": 19, "type": "pointer_declarator", "text": "* GetFrameHeap()", "parent": 15, "children": [20, 21], "start_point": {"row": 10, "column": 22}, "end_point": {"row": 10, "column": 38}}, {"id": 20, "type": "*", "text": "*", "parent": 19, "children": [], "start_point": {"row": 10, "column": 22}, "end_point": {"row": 10, "column": 23}}, {"id": 21, "type": "function_declarator", "text": "GetFrameHeap()", "parent": 19, "children": [22, 23], "start_point": {"row": 10, "column": 24}, "end_point": {"row": 10, "column": 38}}, {"id": 22, "type": "identifier", "text": "GetFrameHeap", "parent": 21, "children": [], "start_point": {"row": 10, "column": 24}, "end_point": {"row": 10, "column": 36}}, {"id": 23, "type": "parameter_list", "text": "()", "parent": 21, "children": [], "start_point": {"row": 10, "column": 36}, "end_point": {"row": 10, "column": 38}}, {"id": 24, "type": "declaration", "text": "static constexpr uint32_t kHeapCount = 5u;", "parent": 12, "children": [25, 27, 28], "start_point": {"row": 11, "column": 6}, "end_point": {"row": 11, "column": 51}}, {"id": 25, "type": "type_qualifier", "text": "constexpr", "parent": 24, "children": [26], "start_point": {"row": 11, "column": 13}, "end_point": {"row": 11, "column": 22}}, {"id": 26, "type": "constexpr", "text": "constexpr", "parent": 25, "children": [], "start_point": {"row": 11, "column": 13}, "end_point": {"row": 11, "column": 22}}, {"id": 27, "type": "primitive_type", "text": "uint32_t", "parent": 24, "children": [], "start_point": {"row": 11, "column": 23}, "end_point": {"row": 11, "column": 31}}, {"id": 28, "type": "init_declarator", "text": "kHeapCount = 5u", "parent": 24, "children": [29, 30, 31], "start_point": {"row": 11, "column": 32}, "end_point": {"row": 11, "column": 50}}, {"id": 29, "type": "identifier", "text": "kHeapCount", "parent": 28, "children": [], "start_point": {"row": 11, "column": 32}, "end_point": {"row": 11, "column": 42}}, {"id": 30, "type": "=", "text": "=", "parent": 28, "children": [], "start_point": {"row": 11, "column": 46}, "end_point": {"row": 11, "column": 47}}, {"id": 31, "type": "number_literal", "text": "5u", "parent": 28, "children": [], "start_point": {"row": 11, "column": 48}, "end_point": {"row": 11, "column": 50}}, {"id": 32, "type": "declaration", "text": "static constexpr uint32_t kHistoryCount = 10u;", "parent": 12, "children": [33, 35, 36], "start_point": {"row": 12, "column": 6}, "end_point": {"row": 12, "column": 52}}, {"id": 33, "type": "type_qualifier", "text": "constexpr", "parent": 32, "children": [34], "start_point": {"row": 12, "column": 13}, "end_point": {"row": 12, "column": 22}}, {"id": 34, "type": "constexpr", "text": "constexpr", "parent": 33, "children": [], "start_point": {"row": 12, "column": 13}, "end_point": {"row": 12, "column": 22}}, {"id": 35, "type": "primitive_type", "text": "uint32_t", "parent": 32, "children": [], "start_point": {"row": 12, "column": 23}, "end_point": {"row": 12, "column": 31}}, {"id": 36, "type": "init_declarator", "text": "kHistoryCount = 10u", "parent": 32, "children": [37, 38, 39], "start_point": {"row": 12, "column": 32}, "end_point": {"row": 12, "column": 51}}, {"id": 37, "type": "identifier", "text": "kHistoryCount", "parent": 36, "children": [], "start_point": {"row": 12, "column": 32}, "end_point": {"row": 12, "column": 45}}, {"id": 38, "type": "=", "text": "=", "parent": 36, "children": [], "start_point": {"row": 12, "column": 46}, "end_point": {"row": 12, "column": 47}}, {"id": 39, "type": "number_literal", "text": "10u", "parent": 36, "children": [], "start_point": {"row": 12, "column": 48}, "end_point": {"row": 12, "column": 51}}, {"id": 40, "type": "call_expression", "text": "FrameHeap()", "parent": 12, "children": [41, 42], "start_point": {"row": 14, "column": 3}, "end_point": {"row": 14, "column": 14}}, {"id": 41, "type": "identifier", "text": "FrameHeap", "parent": 40, "children": [], "start_point": {"row": 14, "column": 3}, "end_point": {"row": 14, "column": 12}}, {"id": 42, "type": "argument_list", "text": "()", "parent": 40, "children": [], "start_point": {"row": 14, "column": 12}, "end_point": {"row": 14, "column": 14}}, {"id": 43, "type": "unary_expression", "text": "~FrameHeap()", "parent": 12, "children": [44, 45], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 15}}, {"id": 44, "type": "~", "text": "~", "parent": 43, "children": [], "start_point": {"row": 15, "column": 3}, "end_point": {"row": 15, "column": 4}}, {"id": 45, "type": "call_expression", "text": "FrameHeap()", "parent": 43, "children": [46, 47], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 15}}, {"id": 46, "type": "identifier", "text": "FrameHeap", "parent": 45, "children": [], "start_point": {"row": 15, "column": 4}, "end_point": {"row": 15, "column": 13}}, {"id": 47, "type": "argument_list", "text": "()", "parent": 45, "children": [], "start_point": {"row": 15, "column": 13}, "end_point": {"row": 15, "column": 15}}, {"id": 48, "type": "declaration", "text": "void update();", "parent": 12, "children": [49, 50], "start_point": {"row": 16, "column": 6}, "end_point": {"row": 16, "column": 20}}, {"id": 49, "type": "primitive_type", "text": "void", "parent": 48, "children": [], "start_point": {"row": 16, "column": 6}, "end_point": {"row": 16, "column": 10}}, {"id": 50, "type": "function_declarator", "text": "update()", "parent": 48, "children": [51, 52], "start_point": {"row": 16, "column": 11}, "end_point": {"row": 16, "column": 19}}, {"id": 51, "type": "identifier", "text": "update", "parent": 50, "children": [], "start_point": {"row": 16, "column": 11}, "end_point": {"row": 16, "column": 17}}, {"id": 52, "type": "parameter_list", "text": "()", "parent": 50, "children": [], "start_point": {"row": 16, "column": 17}, "end_point": {"row": 16, "column": 19}}, {"id": 53, "type": "declaration", "text": "void* alloc(uint32_t size);", "parent": 12, "children": [54, 55], "start_point": {"row": 17, "column": 6}, "end_point": {"row": 17, "column": 33}}, {"id": 54, "type": "primitive_type", "text": "void", "parent": 53, "children": [], "start_point": {"row": 17, "column": 6}, "end_point": {"row": 17, "column": 10}}, {"id": 55, "type": "pointer_declarator", "text": "* alloc(uint32_t size)", "parent": 53, "children": [56, 57], "start_point": {"row": 17, "column": 10}, "end_point": {"row": 17, "column": 32}}, {"id": 56, "type": "*", "text": "*", "parent": 55, "children": [], "start_point": {"row": 17, "column": 10}, "end_point": {"row": 17, "column": 11}}, {"id": 57, "type": "function_declarator", "text": "alloc(uint32_t size)", "parent": 55, "children": [58, 59], "start_point": {"row": 17, "column": 12}, "end_point": {"row": 17, "column": 32}}, {"id": 58, "type": "identifier", "text": "alloc", "parent": 57, "children": [], "start_point": {"row": 17, "column": 12}, "end_point": {"row": 17, "column": 17}}, {"id": 59, "type": "parameter_list", "text": "(uint32_t size)", "parent": 57, "children": [60], "start_point": {"row": 17, "column": 17}, "end_point": {"row": 17, "column": 32}}, {"id": 60, "type": "parameter_declaration", "text": "uint32_t size", "parent": 59, "children": [61, 62], "start_point": {"row": 17, "column": 18}, "end_point": {"row": 17, "column": 31}}, {"id": 61, "type": "primitive_type", "text": "uint32_t", "parent": 60, "children": [], "start_point": {"row": 17, "column": 18}, "end_point": {"row": 17, "column": 26}}, {"id": 62, "type": "identifier", "text": "size", "parent": 60, "children": [], "start_point": {"row": 17, "column": 27}, "end_point": {"row": 17, "column": 31}}, {"id": 63, "type": "declaration", "text": "void* realloc(void* prev, uint32_t prev_size, uint32_t new_size);", "parent": 12, "children": [64, 65], "start_point": {"row": 18, "column": 3}, "end_point": {"row": 18, "column": 68}}, {"id": 64, "type": "primitive_type", "text": "void", "parent": 63, "children": [], "start_point": {"row": 18, "column": 3}, "end_point": {"row": 18, "column": 7}}, {"id": 65, "type": "pointer_declarator", "text": "* realloc(void* prev, uint32_t prev_size, uint32_t new_size)", "parent": 63, "children": [66, 67], "start_point": {"row": 18, "column": 7}, "end_point": {"row": 18, "column": 67}}, {"id": 66, "type": "*", "text": "*", "parent": 65, "children": [], "start_point": {"row": 18, "column": 7}, "end_point": {"row": 18, "column": 8}}, {"id": 67, "type": "function_declarator", "text": "realloc(void* prev, uint32_t prev_size, uint32_t new_size)", "parent": 65, "children": [68, 69], "start_point": {"row": 18, "column": 9}, "end_point": {"row": 18, "column": 67}}, {"id": 68, "type": "identifier", "text": "realloc", "parent": 67, "children": [], "start_point": {"row": 18, "column": 9}, "end_point": {"row": 18, "column": 16}}, {"id": 69, "type": "parameter_list", "text": "(void* prev, uint32_t prev_size, uint32_t new_size)", "parent": 67, "children": [70, 75, 78], "start_point": {"row": 18, "column": 16}, "end_point": {"row": 18, "column": 67}}, {"id": 70, "type": "parameter_declaration", "text": "void* prev", "parent": 69, "children": [71, 72], "start_point": {"row": 18, "column": 17}, "end_point": {"row": 18, "column": 27}}, {"id": 71, "type": "primitive_type", "text": "void", "parent": 70, "children": [], "start_point": {"row": 18, "column": 17}, "end_point": {"row": 18, "column": 21}}, {"id": 72, "type": "pointer_declarator", "text": "* prev", "parent": 70, "children": [73, 74], "start_point": {"row": 18, "column": 21}, "end_point": {"row": 18, "column": 27}}, {"id": 73, "type": "*", "text": "*", "parent": 72, "children": [], "start_point": {"row": 18, "column": 21}, "end_point": {"row": 18, "column": 22}}, {"id": 74, "type": "identifier", "text": "prev", "parent": 72, "children": [], "start_point": {"row": 18, "column": 23}, "end_point": {"row": 18, "column": 27}}, {"id": 75, "type": "parameter_declaration", "text": "uint32_t prev_size", "parent": 69, "children": [76, 77], "start_point": {"row": 18, "column": 29}, "end_point": {"row": 18, "column": 47}}, {"id": 76, "type": "primitive_type", "text": "uint32_t", "parent": 75, "children": [], "start_point": {"row": 18, "column": 29}, "end_point": {"row": 18, "column": 37}}, {"id": 77, "type": "identifier", "text": "prev_size", "parent": 75, "children": [], "start_point": {"row": 18, "column": 38}, "end_point": {"row": 18, "column": 47}}, {"id": 78, "type": "parameter_declaration", "text": "uint32_t new_size", "parent": 69, "children": [79, 80], "start_point": {"row": 18, "column": 49}, "end_point": {"row": 18, "column": 66}}, {"id": 79, "type": "primitive_type", "text": "uint32_t", "parent": 78, "children": [], "start_point": {"row": 18, "column": 49}, "end_point": {"row": 18, "column": 57}}, {"id": 80, "type": "identifier", "text": "new_size", "parent": 78, "children": [], "start_point": {"row": 18, "column": 58}, "end_point": {"row": 18, "column": 66}}, {"id": 81, "type": "binary_expression", "text": "template<typename T>\r\n\t\t\tinline", "parent": 12, "children": [82, 86, 88, 89], "start_point": {"row": 19, "column": 3}, "end_point": {"row": 20, "column": 9}}, {"id": 82, "type": "binary_expression", "text": "template<typename", "parent": 81, "children": [83, 84, 85], "start_point": {"row": 19, "column": 3}, "end_point": {"row": 19, "column": 20}}, {"id": 83, "type": "identifier", "text": "template", "parent": 82, "children": [], "start_point": {"row": 19, "column": 3}, "end_point": {"row": 19, "column": 11}}, {"id": 84, "type": "<", "text": "<", "parent": 82, "children": [], "start_point": {"row": 19, "column": 11}, "end_point": {"row": 19, "column": 12}}, {"id": 85, "type": "identifier", "text": "typename", "parent": 82, "children": [], "start_point": {"row": 19, "column": 12}, "end_point": {"row": 19, "column": 20}}, {"id": 86, "type": "ERROR", "text": "T", "parent": 81, "children": [87], "start_point": {"row": 19, "column": 21}, "end_point": {"row": 19, "column": 22}}, {"id": 87, "type": "identifier", "text": "T", "parent": 86, "children": [], "start_point": {"row": 19, "column": 21}, "end_point": {"row": 19, "column": 22}}, {"id": 88, "type": ">", "text": ">", "parent": 81, "children": [], "start_point": {"row": 19, "column": 22}, "end_point": {"row": 19, "column": 23}}, {"id": 89, "type": "identifier", "text": "inline", "parent": 81, "children": [], "start_point": {"row": 20, "column": 3}, "end_point": {"row": 20, "column": 9}}, {"id": 90, "type": "function_definition", "text": "void deconstruct(T* t)\r\n\t\t\t{\r\n\t\t\t\tt->~T();\r\n\t\t\t}", "parent": 12, "children": [91, 92], "start_point": {"row": 20, "column": 10}, "end_point": {"row": 23, "column": 4}}, {"id": 91, "type": "primitive_type", "text": "void", "parent": 90, "children": [], "start_point": {"row": 20, "column": 10}, "end_point": {"row": 20, "column": 14}}, {"id": 92, "type": "function_declarator", "text": "deconstruct(T* t)", "parent": 90, "children": [93, 94], "start_point": {"row": 20, "column": 15}, "end_point": {"row": 20, "column": 32}}, {"id": 93, "type": "identifier", "text": "deconstruct", "parent": 92, "children": [], "start_point": {"row": 20, "column": 15}, "end_point": {"row": 20, "column": 26}}, {"id": 94, "type": "parameter_list", "text": "(T* t)", "parent": 92, "children": [95], "start_point": {"row": 20, "column": 26}, "end_point": {"row": 20, "column": 32}}, {"id": 95, "type": "parameter_declaration", "text": "T* t", "parent": 94, "children": [96, 97], "start_point": {"row": 20, "column": 27}, "end_point": {"row": 20, "column": 31}}, {"id": 96, "type": "type_identifier", "text": "T", "parent": 95, "children": [], "start_point": {"row": 20, "column": 27}, "end_point": {"row": 20, "column": 28}}, {"id": 97, "type": "pointer_declarator", "text": "* t", "parent": 95, "children": [98, 99], "start_point": {"row": 20, "column": 28}, "end_point": {"row": 20, "column": 31}}, {"id": 98, "type": "*", "text": "*", "parent": 97, "children": [], "start_point": {"row": 20, "column": 28}, "end_point": {"row": 20, "column": 29}}, {"id": 99, "type": "identifier", "text": "t", "parent": 97, "children": [], "start_point": {"row": 20, "column": 30}, "end_point": {"row": 20, "column": 31}}, {"id": 100, "type": "call_expression", "text": "t->~T()", "parent": 90, "children": [101, 106], "start_point": {"row": 22, "column": 4}, "end_point": {"row": 22, "column": 11}}, {"id": 101, "type": "field_expression", "text": "t->~T", "parent": 100, "children": [102, 103, 105], "start_point": {"row": 22, "column": 4}, "end_point": {"row": 22, "column": 9}}, {"id": 102, "type": "identifier", "text": "t", "parent": 101, "children": [], "start_point": {"row": 22, "column": 4}, "end_point": {"row": 22, "column": 5}}, {"id": 103, "type": "ERROR", "text": "~", "parent": 101, "children": [104], "start_point": {"row": 22, "column": 7}, "end_point": {"row": 22, "column": 8}}, {"id": 104, "type": "~", "text": "~", "parent": 103, "children": [], "start_point": {"row": 22, "column": 7}, "end_point": {"row": 22, "column": 8}}, {"id": 105, "type": "field_identifier", "text": "T", "parent": 101, "children": [], "start_point": {"row": 22, "column": 8}, "end_point": {"row": 22, "column": 9}}, {"id": 106, "type": "argument_list", "text": "()", "parent": 100, "children": [], "start_point": {"row": 22, "column": 9}, "end_point": {"row": 22, "column": 11}}, {"id": 107, "type": "binary_expression", "text": "template<typename T>\r\n inline", "parent": 12, "children": [108, 112, 114, 115], "start_point": {"row": 24, "column": 6}, "end_point": {"row": 25, "column": 12}}, {"id": 108, "type": "binary_expression", "text": "template<typename", "parent": 107, "children": [109, 110, 111], "start_point": {"row": 24, "column": 6}, "end_point": {"row": 24, "column": 23}}, {"id": 109, "type": "identifier", "text": "template", "parent": 108, "children": [], "start_point": {"row": 24, "column": 6}, "end_point": {"row": 24, "column": 14}}, {"id": 110, "type": "<", "text": "<", "parent": 108, "children": [], "start_point": {"row": 24, "column": 14}, "end_point": {"row": 24, "column": 15}}, {"id": 111, "type": "identifier", "text": "typename", "parent": 108, "children": [], "start_point": {"row": 24, "column": 15}, "end_point": {"row": 24, "column": 23}}, {"id": 112, "type": "ERROR", "text": "T", "parent": 107, "children": [113], "start_point": {"row": 24, "column": 24}, "end_point": {"row": 24, "column": 25}}, {"id": 113, "type": "identifier", "text": "T", "parent": 112, "children": [], "start_point": {"row": 24, "column": 24}, "end_point": {"row": 24, "column": 25}}, {"id": 114, "type": ">", "text": ">", "parent": 107, "children": [], "start_point": {"row": 24, "column": 25}, "end_point": {"row": 24, "column": 26}}, {"id": 115, "type": "identifier", "text": "inline", "parent": 107, "children": [], "start_point": {"row": 25, "column": 6}, "end_point": {"row": 25, "column": 12}}, {"id": 116, "type": "function_definition", "text": "T* construct()\r\n {\r\n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));\r\n new (allocated) T();\r\n return allocated;\r\n }", "parent": 12, "children": [117, 118], "start_point": {"row": 25, "column": 13}, "end_point": {"row": 30, "column": 7}}, {"id": 117, "type": "type_identifier", "text": "T", "parent": 116, "children": [], "start_point": {"row": 25, "column": 13}, "end_point": {"row": 25, "column": 14}}, {"id": 118, "type": "pointer_declarator", "text": "* construct()", "parent": 116, "children": [119, 120], "start_point": {"row": 25, "column": 14}, "end_point": {"row": 25, "column": 27}}, {"id": 119, "type": "*", "text": "*", "parent": 118, "children": [], "start_point": {"row": 25, "column": 14}, "end_point": {"row": 25, "column": 15}}, {"id": 120, "type": "function_declarator", "text": "construct()", "parent": 118, "children": [121, 122], "start_point": {"row": 25, "column": 16}, "end_point": {"row": 25, "column": 27}}, {"id": 121, "type": "identifier", "text": "construct", "parent": 120, "children": [], "start_point": {"row": 25, "column": 16}, "end_point": {"row": 25, "column": 25}}, {"id": 122, "type": "parameter_list", "text": "()", "parent": 120, "children": [], "start_point": {"row": 25, "column": 25}, "end_point": {"row": 25, "column": 27}}, {"id": 123, "type": "declaration", "text": "T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));", "parent": 116, "children": [124, 125], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 62}}, {"id": 124, "type": "type_identifier", "text": "T", "parent": 123, "children": [], "start_point": {"row": 27, "column": 8}, "end_point": {"row": 27, "column": 9}}, {"id": 125, "type": "init_declarator", "text": "* allocated = reinterpret_cast<T*>(alloc(sizeof(T)))", "parent": 123, "children": [126, 129, 130], "start_point": {"row": 27, "column": 9}, "end_point": {"row": 27, "column": 61}}, {"id": 126, "type": "pointer_declarator", "text": "* allocated", "parent": 125, "children": [127, 128], "start_point": {"row": 27, "column": 9}, "end_point": {"row": 27, "column": 20}}, {"id": 127, "type": "*", "text": "*", "parent": 126, "children": [], "start_point": {"row": 27, "column": 9}, "end_point": {"row": 27, "column": 10}}, {"id": 128, "type": "identifier", "text": "allocated", "parent": 126, "children": [], "start_point": {"row": 27, "column": 11}, "end_point": {"row": 27, "column": 20}}, {"id": 129, "type": "=", "text": "=", "parent": 125, "children": [], "start_point": {"row": 27, "column": 21}, "end_point": {"row": 27, "column": 22}}, {"id": 130, "type": "binary_expression", "text": "reinterpret_cast<T*>(alloc(sizeof(T)))", "parent": 125, "children": [131, 135, 137, 138], "start_point": {"row": 27, "column": 23}, "end_point": {"row": 27, "column": 61}}, {"id": 131, "type": "binary_expression", "text": "reinterpret_cast<T", "parent": 130, "children": [132, 133, 134], "start_point": {"row": 27, "column": 23}, "end_point": {"row": 27, "column": 41}}, {"id": 132, "type": "identifier", "text": "reinterpret_cast", "parent": 131, "children": [], "start_point": {"row": 27, "column": 23}, "end_point": {"row": 27, "column": 39}}, {"id": 133, "type": "<", "text": "<", "parent": 131, "children": [], "start_point": {"row": 27, "column": 39}, "end_point": {"row": 27, "column": 40}}, {"id": 134, "type": "identifier", "text": "T", "parent": 131, "children": [], "start_point": {"row": 27, "column": 40}, "end_point": {"row": 27, "column": 41}}, {"id": 135, "type": "ERROR", "text": "*", "parent": 130, "children": [136], "start_point": {"row": 27, "column": 41}, "end_point": {"row": 27, "column": 42}}, {"id": 136, "type": "*", "text": "*", "parent": 135, "children": [], "start_point": {"row": 27, "column": 41}, "end_point": {"row": 27, "column": 42}}, {"id": 137, "type": ">", "text": ">", "parent": 130, "children": [], "start_point": {"row": 27, "column": 42}, "end_point": {"row": 27, "column": 43}}, {"id": 138, "type": "parenthesized_expression", "text": "(alloc(sizeof(T)))", "parent": 130, "children": [139], "start_point": {"row": 27, "column": 43}, "end_point": {"row": 27, "column": 61}}, {"id": 139, "type": "call_expression", "text": "alloc(sizeof(T))", "parent": 138, "children": [140, 141], "start_point": {"row": 27, "column": 44}, "end_point": {"row": 27, "column": 60}}, {"id": 140, "type": "identifier", "text": "alloc", "parent": 139, "children": [], "start_point": {"row": 27, "column": 44}, "end_point": {"row": 27, "column": 49}}, {"id": 141, "type": "argument_list", "text": "(sizeof(T))", "parent": 139, "children": [142], "start_point": {"row": 27, "column": 49}, "end_point": {"row": 27, "column": 60}}, {"id": 142, "type": "sizeof_expression", "text": "sizeof(T)", "parent": 141, "children": [143], "start_point": {"row": 27, "column": 50}, "end_point": {"row": 27, "column": 59}}, {"id": 143, "type": "parenthesized_expression", "text": "(T)", "parent": 142, "children": [144], "start_point": {"row": 27, "column": 56}, "end_point": {"row": 27, "column": 59}}, {"id": 144, "type": "identifier", "text": "T", "parent": 143, "children": [], "start_point": {"row": 27, "column": 57}, "end_point": {"row": 27, "column": 58}}, {"id": 145, "type": "declaration", "text": "new (allocated) T();", "parent": 116, "children": [146, 149], "start_point": {"row": 28, "column": 8}, "end_point": {"row": 28, "column": 28}}, {"id": 146, "type": "macro_type_specifier", "text": "new (allocated)", "parent": 145, "children": [147], "start_point": {"row": 28, "column": 8}, "end_point": {"row": 28, "column": 23}}, {"id": 147, "type": "type_descriptor", "text": "allocated", "parent": 146, "children": [148], "start_point": {"row": 28, "column": 13}, "end_point": {"row": 28, "column": 22}}, {"id": 148, "type": "type_identifier", "text": "allocated", "parent": 147, "children": [], "start_point": {"row": 28, "column": 13}, "end_point": {"row": 28, "column": 22}}, {"id": 149, "type": "function_declarator", "text": "T()", "parent": 145, "children": [150, 151], "start_point": {"row": 28, "column": 24}, "end_point": {"row": 28, "column": 27}}, {"id": 150, "type": "identifier", "text": "T", "parent": 149, "children": [], "start_point": {"row": 28, "column": 24}, "end_point": {"row": 28, "column": 25}}, {"id": 151, "type": "parameter_list", "text": "()", "parent": 149, "children": [], "start_point": {"row": 28, "column": 25}, "end_point": {"row": 28, "column": 27}}, {"id": 152, "type": "return_statement", "text": "return allocated;", "parent": 116, "children": [153], "start_point": {"row": 29, "column": 8}, "end_point": {"row": 29, "column": 25}}, {"id": 153, "type": "identifier", "text": "allocated", "parent": 152, "children": [], "start_point": {"row": 29, "column": 15}, "end_point": {"row": 29, "column": 24}}, {"id": 154, "type": "comma_expression", "text": "template<typename T, typename ...Args>\r\n inline T* construct(Args&& ...args)", "parent": 12, "children": [155, 159, 161], "start_point": {"row": 31, "column": 6}, "end_point": {"row": 32, "column": 41}}, {"id": 155, "type": "binary_expression", "text": "template<typename", "parent": 154, "children": [156, 157, 158], "start_point": {"row": 31, "column": 6}, "end_point": {"row": 31, "column": 23}}, {"id": 156, "type": "identifier", "text": "template", "parent": 155, "children": [], "start_point": {"row": 31, "column": 6}, "end_point": {"row": 31, "column": 14}}, {"id": 157, "type": "<", "text": "<", "parent": 155, "children": [], "start_point": {"row": 31, "column": 14}, "end_point": {"row": 31, "column": 15}}, {"id": 158, "type": "identifier", "text": "typename", "parent": 155, "children": [], "start_point": {"row": 31, "column": 15}, "end_point": {"row": 31, "column": 23}}, {"id": 159, "type": "ERROR", "text": "T", "parent": 154, "children": [160], "start_point": {"row": 31, "column": 24}, "end_point": {"row": 31, "column": 25}}, {"id": 160, "type": "identifier", "text": "T", "parent": 159, "children": [], "start_point": {"row": 31, "column": 24}, "end_point": {"row": 31, "column": 25}}, {"id": 161, "type": "binary_expression", "text": "typename ...Args>\r\n inline T* construct(Args&& ...args)", "parent": 154, "children": [162, 163, 165, 166], "start_point": {"row": 31, "column": 27}, "end_point": {"row": 32, "column": 41}}, {"id": 162, "type": "identifier", "text": "typename", "parent": 161, "children": [], "start_point": {"row": 31, "column": 27}, "end_point": {"row": 31, "column": 35}}, {"id": 163, "type": "ERROR", "text": "...Args", "parent": 161, "children": [164], "start_point": {"row": 31, "column": 36}, "end_point": {"row": 31, "column": 43}}, {"id": 164, "type": "identifier", "text": "Args", "parent": 163, "children": [], "start_point": {"row": 31, "column": 39}, "end_point": {"row": 31, "column": 43}}, {"id": 165, "type": ">", "text": ">", "parent": 161, "children": [], "start_point": {"row": 31, "column": 43}, "end_point": {"row": 31, "column": 44}}, {"id": 166, "type": "binary_expression", "text": "inline T* construct(Args&& ...args)", "parent": 161, "children": [167, 168, 170, 171], "start_point": {"row": 32, "column": 6}, "end_point": {"row": 32, "column": 41}}, {"id": 167, "type": "identifier", "text": "inline", "parent": 166, "children": [], "start_point": {"row": 32, "column": 6}, "end_point": {"row": 32, "column": 12}}, {"id": 168, "type": "ERROR", "text": "T", "parent": 166, "children": [169], "start_point": {"row": 32, "column": 13}, "end_point": {"row": 32, "column": 14}}, {"id": 169, "type": "identifier", "text": "T", "parent": 168, "children": [], "start_point": {"row": 32, "column": 13}, "end_point": {"row": 32, "column": 14}}, {"id": 170, "type": "*", "text": "*", "parent": 166, "children": [], "start_point": {"row": 32, "column": 14}, "end_point": {"row": 32, "column": 15}}, {"id": 171, "type": "call_expression", "text": "construct(Args&& ...args)", "parent": 166, "children": [172, 173], "start_point": {"row": 32, "column": 16}, "end_point": {"row": 32, "column": 41}}, {"id": 172, "type": "identifier", "text": "construct", "parent": 171, "children": [], "start_point": {"row": 32, "column": 16}, "end_point": {"row": 32, "column": 25}}, {"id": 173, "type": "argument_list", "text": "(Args&& ...args)", "parent": 171, "children": [174], "start_point": {"row": 32, "column": 25}, "end_point": {"row": 32, "column": 41}}, {"id": 174, "type": "binary_expression", "text": "Args&& ...args", "parent": 173, "children": [175, 176, 177], "start_point": {"row": 32, "column": 26}, "end_point": {"row": 32, "column": 40}}, {"id": 175, "type": "identifier", "text": "Args", "parent": 174, "children": [], "start_point": {"row": 32, "column": 26}, "end_point": {"row": 32, "column": 30}}, {"id": 176, "type": "&&", "text": "&&", "parent": 174, "children": [], "start_point": {"row": 32, "column": 30}, "end_point": {"row": 32, "column": 32}}, {"id": 177, "type": "identifier", "text": "args", "parent": 174, "children": [], "start_point": {"row": 32, "column": 36}, "end_point": {"row": 32, "column": 40}}, {"id": 178, "type": "declaration", "text": "T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));", "parent": 12, "children": [179, 180], "start_point": {"row": 34, "column": 8}, "end_point": {"row": 34, "column": 62}}, {"id": 179, "type": "type_identifier", "text": "T", "parent": 178, "children": [], "start_point": {"row": 34, "column": 8}, "end_point": {"row": 34, "column": 9}}, {"id": 180, "type": "init_declarator", "text": "* allocated = reinterpret_cast<T*>(alloc(sizeof(T)))", "parent": 178, "children": [181, 184, 185], "start_point": {"row": 34, "column": 9}, "end_point": {"row": 34, "column": 61}}, {"id": 181, "type": "pointer_declarator", "text": "* allocated", "parent": 180, "children": [182, 183], "start_point": {"row": 34, "column": 9}, "end_point": {"row": 34, "column": 20}}, {"id": 182, "type": "*", "text": "*", "parent": 181, "children": [], "start_point": {"row": 34, "column": 9}, "end_point": {"row": 34, "column": 10}}, {"id": 183, "type": "identifier", "text": "allocated", "parent": 181, "children": [], "start_point": {"row": 34, "column": 11}, "end_point": {"row": 34, "column": 20}}, {"id": 184, "type": "=", "text": "=", "parent": 180, "children": [], "start_point": {"row": 34, "column": 21}, "end_point": {"row": 34, "column": 22}}, {"id": 185, "type": "binary_expression", "text": "reinterpret_cast<T*>(alloc(sizeof(T)))", "parent": 180, "children": [186, 190, 192, 193], "start_point": {"row": 34, "column": 23}, "end_point": {"row": 34, "column": 61}}, {"id": 186, "type": "binary_expression", "text": "reinterpret_cast<T", "parent": 185, "children": [187, 188, 189], "start_point": {"row": 34, "column": 23}, "end_point": {"row": 34, "column": 41}}, {"id": 187, "type": "identifier", "text": "reinterpret_cast", "parent": 186, "children": [], "start_point": {"row": 34, "column": 23}, "end_point": {"row": 34, "column": 39}}, {"id": 188, "type": "<", "text": "<", "parent": 186, "children": [], "start_point": {"row": 34, "column": 39}, "end_point": {"row": 34, "column": 40}}, {"id": 189, "type": "identifier", "text": "T", "parent": 186, "children": [], "start_point": {"row": 34, "column": 40}, "end_point": {"row": 34, "column": 41}}, {"id": 190, "type": "ERROR", "text": "*", "parent": 185, "children": [191], "start_point": {"row": 34, "column": 41}, "end_point": {"row": 34, "column": 42}}, {"id": 191, "type": "*", "text": "*", "parent": 190, "children": [], "start_point": {"row": 34, "column": 41}, "end_point": {"row": 34, "column": 42}}, {"id": 192, "type": ">", "text": ">", "parent": 185, "children": [], "start_point": {"row": 34, "column": 42}, "end_point": {"row": 34, "column": 43}}, {"id": 193, "type": "parenthesized_expression", "text": "(alloc(sizeof(T)))", "parent": 185, "children": [194], "start_point": {"row": 34, "column": 43}, "end_point": {"row": 34, "column": 61}}, {"id": 194, "type": "call_expression", "text": "alloc(sizeof(T))", "parent": 193, "children": [195, 196], "start_point": {"row": 34, "column": 44}, "end_point": {"row": 34, "column": 60}}, {"id": 195, "type": "identifier", "text": "alloc", "parent": 194, "children": [], "start_point": {"row": 34, "column": 44}, "end_point": {"row": 34, "column": 49}}, {"id": 196, "type": "argument_list", "text": "(sizeof(T))", "parent": 194, "children": [197], "start_point": {"row": 34, "column": 49}, "end_point": {"row": 34, "column": 60}}, {"id": 197, "type": "sizeof_expression", "text": "sizeof(T)", "parent": 196, "children": [198], "start_point": {"row": 34, "column": 50}, "end_point": {"row": 34, "column": 59}}, {"id": 198, "type": "parenthesized_expression", "text": "(T)", "parent": 197, "children": [199], "start_point": {"row": 34, "column": 56}, "end_point": {"row": 34, "column": 59}}, {"id": 199, "type": "identifier", "text": "T", "parent": 198, "children": [], "start_point": {"row": 34, "column": 57}, "end_point": {"row": 34, "column": 58}}, {"id": 200, "type": "declaration", "text": "new (allocated) T(eastl::forward<Args>(args)...);", "parent": 12, "children": [201, 204, 215], "start_point": {"row": 35, "column": 8}, "end_point": {"row": 35, "column": 57}}, {"id": 201, "type": "macro_type_specifier", "text": "new (allocated)", "parent": 200, "children": [202], "start_point": {"row": 35, "column": 8}, "end_point": {"row": 35, "column": 23}}, {"id": 202, "type": "type_descriptor", "text": "allocated", "parent": 201, "children": [203], "start_point": {"row": 35, "column": 13}, "end_point": {"row": 35, "column": 22}}, {"id": 203, "type": "type_identifier", "text": "allocated", "parent": 202, "children": [], "start_point": {"row": 35, "column": 13}, "end_point": {"row": 35, "column": 22}}, {"id": 204, "type": "function_declarator", "text": "T(eastl::forward<Args>(args)", "parent": 200, "children": [205, 206], "start_point": {"row": 35, "column": 24}, "end_point": {"row": 35, "column": 52}}, {"id": 205, "type": "identifier", "text": "T", "parent": 204, "children": [], "start_point": {"row": 35, "column": 24}, "end_point": {"row": 35, "column": 25}}, {"id": 206, "type": "parameter_list", "text": "(eastl::forward<Args>(args)", "parent": 204, "children": [207], "start_point": {"row": 35, "column": 25}, "end_point": {"row": 35, "column": 52}}, {"id": 207, "type": "parameter_declaration", "text": "eastl::forward<Args>(args", "parent": 206, "children": [208, 209, 214], "start_point": {"row": 35, "column": 26}, "end_point": {"row": 35, "column": 51}}, {"id": 208, "type": "type_identifier", "text": "eastl", "parent": 207, "children": [], "start_point": {"row": 35, "column": 26}, "end_point": {"row": 35, "column": 31}}, {"id": 209, "type": "ERROR", "text": "::forward<Args>(", "parent": 207, "children": [210, 211, 212, 213], "start_point": {"row": 35, "column": 31}, "end_point": {"row": 35, "column": 47}}, {"id": 210, "type": "identifier", "text": "forward", "parent": 209, "children": [], "start_point": {"row": 35, "column": 33}, "end_point": {"row": 35, "column": 40}}, {"id": 211, "type": "<", "text": "<", "parent": 209, "children": [], "start_point": {"row": 35, "column": 40}, "end_point": {"row": 35, "column": 41}}, {"id": 212, "type": "identifier", "text": "Args", "parent": 209, "children": [], "start_point": {"row": 35, "column": 41}, "end_point": {"row": 35, "column": 45}}, {"id": 213, "type": ">", "text": ">", "parent": 209, "children": [], "start_point": {"row": 35, "column": 45}, "end_point": {"row": 35, "column": 46}}, {"id": 214, "type": "identifier", "text": "args", "parent": 207, "children": [], "start_point": {"row": 35, "column": 47}, "end_point": {"row": 35, "column": 51}}, {"id": 215, "type": "ERROR", "text": "...)", "parent": 200, "children": [], "start_point": {"row": 35, "column": 52}, "end_point": {"row": 35, "column": 56}}, {"id": 216, "type": "return_statement", "text": "return allocated;", "parent": 12, "children": [217], "start_point": {"row": 36, "column": 8}, "end_point": {"row": 36, "column": 25}}, {"id": 217, "type": "identifier", "text": "allocated", "parent": 216, "children": [], "start_point": {"row": 36, "column": 15}, "end_point": {"row": 36, "column": 24}}, {"id": 218, "type": "declaration", "text": "uint32_t currentHeapSize();", "parent": 12, "children": [219, 220], "start_point": {"row": 39, "column": 6}, "end_point": {"row": 39, "column": 33}}, {"id": 219, "type": "primitive_type", "text": "uint32_t", "parent": 218, "children": [], "start_point": {"row": 39, "column": 6}, "end_point": {"row": 39, "column": 14}}, {"id": 220, "type": "function_declarator", "text": "currentHeapSize()", "parent": 218, "children": [221, 222], "start_point": {"row": 39, "column": 15}, "end_point": {"row": 39, "column": 32}}, {"id": 221, "type": "identifier", "text": "currentHeapSize", "parent": 220, "children": [], "start_point": {"row": 39, "column": 15}, "end_point": {"row": 39, "column": 30}}, {"id": 222, "type": "parameter_list", "text": "()", "parent": 220, "children": [], "start_point": {"row": 39, "column": 30}, "end_point": {"row": 39, "column": 32}}, {"id": 223, "type": "labeled_statement", "text": "private:\r\n uint32_t current_frame_heap_;", "parent": 12, "children": [224], "start_point": {"row": 41, "column": 4}, "end_point": {"row": 42, "column": 35}}, {"id": 224, "type": "declaration", "text": "uint32_t current_frame_heap_;", "parent": 223, "children": [225, 226], "start_point": {"row": 42, "column": 6}, "end_point": {"row": 42, "column": 35}}, {"id": 225, "type": "primitive_type", "text": "uint32_t", "parent": 224, "children": [], "start_point": {"row": 42, "column": 6}, "end_point": {"row": 42, "column": 14}}, {"id": 226, "type": "identifier", "text": "current_frame_heap_", "parent": 224, "children": [], "start_point": {"row": 42, "column": 15}, "end_point": {"row": 42, "column": 34}}, {"id": 227, "type": "declaration", "text": "uint32_t current_history_;", "parent": 12, "children": [228, 229], "start_point": {"row": 43, "column": 6}, "end_point": {"row": 43, "column": 32}}, {"id": 228, "type": "primitive_type", "text": "uint32_t", "parent": 227, "children": [], "start_point": {"row": 43, "column": 6}, "end_point": {"row": 43, "column": 14}}, {"id": 229, "type": "identifier", "text": "current_history_", "parent": 227, "children": [], "start_point": {"row": 43, "column": 15}, "end_point": {"row": 43, "column": 31}}, {"id": 230, "type": "declaration", "text": "uint32_t allocated_;", "parent": 12, "children": [231, 232], "start_point": {"row": 45, "column": 6}, "end_point": {"row": 45, "column": 26}}, {"id": 231, "type": "primitive_type", "text": "uint32_t", "parent": 230, "children": [], "start_point": {"row": 45, "column": 6}, "end_point": {"row": 45, "column": 14}}, {"id": 232, "type": "identifier", "text": "allocated_", "parent": 230, "children": [], "start_point": {"row": 45, "column": 15}, "end_point": {"row": 45, "column": 25}}, {"id": 233, "type": "declaration", "text": "void* frame_heaps_[kHeapCount];", "parent": 12, "children": [234, 235], "start_point": {"row": 46, "column": 6}, "end_point": {"row": 46, "column": 40}}, {"id": 234, "type": "primitive_type", "text": "void", "parent": 233, "children": [], "start_point": {"row": 46, "column": 6}, "end_point": {"row": 46, "column": 10}}, {"id": 235, "type": "pointer_declarator", "text": "* frame_heaps_[kHeapCount]", "parent": 233, "children": [236, 237], "start_point": {"row": 46, "column": 10}, "end_point": {"row": 46, "column": 39}}, {"id": 236, "type": "*", "text": "*", "parent": 235, "children": [], "start_point": {"row": 46, "column": 10}, "end_point": {"row": 46, "column": 11}}, {"id": 237, "type": "array_declarator", "text": "frame_heaps_[kHeapCount]", "parent": 235, "children": [238, 239], "start_point": {"row": 46, "column": 15}, "end_point": {"row": 46, "column": 39}}, {"id": 238, "type": "identifier", "text": "frame_heaps_", "parent": 237, "children": [], "start_point": {"row": 46, "column": 15}, "end_point": {"row": 46, "column": 27}}, {"id": 239, "type": "identifier", "text": "kHeapCount", "parent": 237, "children": [], "start_point": {"row": 46, "column": 28}, "end_point": {"row": 46, "column": 38}}, {"id": 240, "type": "declaration", "text": "uint32_t heap_sizes_[kHeapCount];", "parent": 12, "children": [241, 242], "start_point": {"row": 47, "column": 6}, "end_point": {"row": 47, "column": 39}}, {"id": 241, "type": "primitive_type", "text": "uint32_t", "parent": 240, "children": [], "start_point": {"row": 47, "column": 6}, "end_point": {"row": 47, "column": 14}}, {"id": 242, "type": "array_declarator", "text": "heap_sizes_[kHeapCount]", "parent": 240, "children": [243, 244], "start_point": {"row": 47, "column": 15}, "end_point": {"row": 47, "column": 38}}, {"id": 243, "type": "identifier", "text": "heap_sizes_", "parent": 242, "children": [], "start_point": {"row": 47, "column": 15}, "end_point": {"row": 47, "column": 26}}, {"id": 244, "type": "identifier", "text": "kHeapCount", "parent": 242, "children": [], "start_point": {"row": 47, "column": 27}, "end_point": {"row": 47, "column": 37}}, {"id": 245, "type": "declaration", "text": "uint32_t size_history_[kHistoryCount];", "parent": 12, "children": [246, 247], "start_point": {"row": 48, "column": 6}, "end_point": {"row": 48, "column": 44}}, {"id": 246, "type": "primitive_type", "text": "uint32_t", "parent": 245, "children": [], "start_point": {"row": 48, "column": 6}, "end_point": {"row": 48, "column": 14}}, {"id": 247, "type": "array_declarator", "text": "size_history_[kHistoryCount]", "parent": 245, "children": [248, 249], "start_point": {"row": 48, "column": 15}, "end_point": {"row": 48, "column": 43}}, {"id": 248, "type": "identifier", "text": "size_history_", "parent": 247, "children": [], "start_point": {"row": 48, "column": 15}, "end_point": {"row": 48, "column": 28}}, {"id": 249, "type": "identifier", "text": "kHistoryCount", "parent": 247, "children": [], "start_point": {"row": 48, "column": 29}, "end_point": {"row": 48, "column": 42}}, {"id": 250, "type": "binary_expression", "text": "Vector<void*> temp_allocs_[kHeapCount]", "parent": 12, "children": [251, 255, 257, 258], "start_point": {"row": 49, "column": 6}, "end_point": {"row": 49, "column": 44}}, {"id": 251, "type": "binary_expression", "text": "Vector<void", "parent": 250, "children": [252, 253, 254], "start_point": {"row": 49, "column": 6}, "end_point": {"row": 49, "column": 17}}, {"id": 252, "type": "identifier", "text": "Vector", "parent": 251, "children": [], "start_point": {"row": 49, "column": 6}, "end_point": {"row": 49, "column": 12}}, {"id": 253, "type": "<", "text": "<", "parent": 251, "children": [], "start_point": {"row": 49, "column": 12}, "end_point": {"row": 49, "column": 13}}, {"id": 254, "type": "identifier", "text": "void", "parent": 251, "children": [], "start_point": {"row": 49, "column": 13}, "end_point": {"row": 49, "column": 17}}, {"id": 255, "type": "ERROR", "text": "*", "parent": 250, "children": [256], "start_point": {"row": 49, "column": 17}, "end_point": {"row": 49, "column": 18}}, {"id": 256, "type": "*", "text": "*", "parent": 255, "children": [], "start_point": {"row": 49, "column": 17}, "end_point": {"row": 49, "column": 18}}, {"id": 257, "type": ">", "text": ">", "parent": 250, "children": [], "start_point": {"row": 49, "column": 18}, "end_point": {"row": 49, "column": 19}}, {"id": 258, "type": "subscript_expression", "text": "temp_allocs_[kHeapCount]", "parent": 250, "children": [259, 260], "start_point": {"row": 49, "column": 20}, "end_point": {"row": 49, "column": 44}}, {"id": 259, "type": "identifier", "text": "temp_allocs_", "parent": 258, "children": [], "start_point": {"row": 49, "column": 20}, "end_point": {"row": 49, "column": 32}}, {"id": 260, "type": "identifier", "text": "kHeapCount", "parent": 258, "children": [], "start_point": {"row": 49, "column": 33}, "end_point": {"row": 49, "column": 43}}, {"id": 261, "type": "labeled_statement", "text": "std::mutex mutex_;", "parent": 12, "children": [262, 263], "start_point": {"row": 50, "column": 3}, "end_point": {"row": 50, "column": 21}}, {"id": 262, "type": "statement_identifier", "text": "std", "parent": 261, "children": [], "start_point": {"row": 50, "column": 3}, "end_point": {"row": 50, "column": 6}}, {"id": 263, "type": "declaration", "text": "mutex mutex_;", "parent": 261, "children": [264, 265], "start_point": {"row": 50, "column": 8}, "end_point": {"row": 50, "column": 21}}, {"id": 264, "type": "type_identifier", "text": "mutex", "parent": 263, "children": [], "start_point": {"row": 50, "column": 8}, "end_point": {"row": 50, "column": 13}}, {"id": 265, "type": "identifier", "text": "mutex_", "parent": 263, "children": [], "start_point": {"row": 50, "column": 14}, "end_point": {"row": 50, "column": 20}}, {"id": 266, "type": "labeled_statement", "text": "protected:\r\n static FrameHeap* s_frame_heap_;", "parent": 12, "children": [267], "start_point": {"row": 52, "column": 4}, "end_point": {"row": 53, "column": 38}}, {"id": 267, "type": "declaration", "text": "static FrameHeap* s_frame_heap_;", "parent": 266, "children": [268, 269], "start_point": {"row": 53, "column": 6}, "end_point": {"row": 53, "column": 38}}, {"id": 268, "type": "type_identifier", "text": "FrameHeap", "parent": 267, "children": [], "start_point": {"row": 53, "column": 13}, "end_point": {"row": 53, "column": 22}}, {"id": 269, "type": "pointer_declarator", "text": "* s_frame_heap_", "parent": 267, "children": [270, 271], "start_point": {"row": 53, "column": 22}, "end_point": {"row": 53, "column": 37}}, {"id": 270, "type": "*", "text": "*", "parent": 269, "children": [], "start_point": {"row": 53, "column": 22}, "end_point": {"row": 53, "column": 23}}, {"id": 271, "type": "identifier", "text": "s_frame_heap_", "parent": 269, "children": [], "start_point": {"row": 53, "column": 24}, "end_point": {"row": 53, "column": 37}}, {"id": 272, "type": "declaration", "text": "extern FrameHeap* GetFrameHeap();", "parent": 9, "children": [273, 275, 276], "start_point": {"row": 56, "column": 4}, "end_point": {"row": 56, "column": 37}}, {"id": 273, "type": "storage_class_specifier", "text": "extern", "parent": 272, "children": [274], "start_point": {"row": 56, "column": 4}, "end_point": {"row": 56, "column": 10}}, {"id": 274, "type": "extern", "text": "extern", "parent": 273, "children": [], "start_point": {"row": 56, "column": 4}, "end_point": {"row": 56, "column": 10}}, {"id": 275, "type": "type_identifier", "text": "FrameHeap", "parent": 272, "children": [], "start_point": {"row": 56, "column": 11}, "end_point": {"row": 56, "column": 20}}, {"id": 276, "type": "pointer_declarator", "text": "* GetFrameHeap()", "parent": 272, "children": [277, 278], "start_point": {"row": 56, "column": 20}, "end_point": {"row": 56, "column": 36}}, {"id": 277, "type": "*", "text": "*", "parent": 276, "children": [], "start_point": {"row": 56, "column": 20}, "end_point": {"row": 56, "column": 21}}, {"id": 278, "type": "function_declarator", "text": "GetFrameHeap()", "parent": 276, "children": [279, 280], "start_point": {"row": 56, "column": 22}, "end_point": {"row": 56, "column": 36}}, {"id": 279, "type": "identifier", "text": "GetFrameHeap", "parent": 278, "children": [], "start_point": {"row": 56, "column": 22}, "end_point": {"row": 56, "column": 34}}, {"id": 280, "type": "parameter_list", "text": "()", "parent": 278, "children": [], "start_point": {"row": 56, "column": 34}, "end_point": {"row": 56, "column": 36}}]}, "node_categories": {"declarations": {"functions": [6, 9, 12, 21, 50, 57, 67, 90, 92, 116, 120, 149, 204, 220, 278], "variables": [15, 24, 32, 48, 53, 60, 63, 70, 75, 78, 95, 123, 145, 178, 200, 207, 218, 224, 227, 230, 233, 240, 245, 263, 267, 272], "classes": [273], "imports": [0, 1, 3, 4], "modules": [], "enums": []}, "statements": {"expressions": [40, 43, 45, 81, 82, 100, 101, 107, 108, 130, 131, 138, 139, 142, 143, 154, 155, 161, 166, 171, 174, 185, 186, 193, 194, 197, 198, 250, 251, 258], "assignments": [], "loops": [], "conditionals": [7, 8, 10, 11, 13, 16, 18, 22, 25, 29, 33, 37, 41, 46, 51, 58, 62, 68, 74, 77, 80, 83, 85, 87, 89, 93, 96, 99, 102, 105, 109, 111, 113, 115, 117, 121, 124, 128, 132, 134, 140, 144, 146, 148, 150, 153, 156, 158, 160, 162, 164, 167, 169, 172, 175, 177, 179, 183, 187, 189, 195, 199, 201, 203, 205, 208, 210, 212, 214, 217, 221, 226, 229, 232, 238, 239, 243, 244, 248, 249, 252, 254, 259, 260, 262, 264, 265, 268, 271, 275, 279], "returns": [152, 216], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 31, 39], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 6, "universal_type": "function", "name": "FrameHeap", "text_snippet": "namespace lambda\r\n{\r\n namespace foundation\r\n {\r\n class FrameHeap\r\n {\r\n public:\r\n fri"}, {"node_id": 9, "universal_type": "function", "name": "FrameHeap", "text_snippet": "namespace foundation\r\n {\r\n class FrameHeap\r\n {\r\n public:\r\n friend FrameHeap* GetFrame"}, {"node_id": 12, "universal_type": "function", "name": "FrameHeap", "text_snippet": "class FrameHeap\r\n {\r\n public:\r\n friend FrameHeap* GetFrameHeap();\r\n static constexpr"}, {"node_id": 21, "universal_type": "function", "name": "unknown", "text_snippet": "GetFrameHeap()"}, {"node_id": 50, "universal_type": "function", "name": "unknown", "text_snippet": "update()"}, {"node_id": 57, "universal_type": "function", "name": "unknown", "text_snippet": "alloc(uint32_t size)"}, {"node_id": 67, "universal_type": "function", "name": "unknown", "text_snippet": "realloc(void* prev, uint32_t prev_size, uint32_t new_size)"}, {"node_id": 90, "universal_type": "function", "name": "deconstruct", "text_snippet": "void deconstruct(T* t)\r\n\t\t\t{\r\n\t\t\t\tt->~T();\r\n\t\t\t}"}, {"node_id": 92, "universal_type": "function", "name": "unknown", "text_snippet": "deconstruct(T* t)"}, {"node_id": 116, "universal_type": "function", "name": "unknown", "text_snippet": "T* construct()\r\n {\r\n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));\r\n new"}, {"node_id": 120, "universal_type": "function", "name": "unknown", "text_snippet": "construct()"}, {"node_id": 149, "universal_type": "function", "name": "unknown", "text_snippet": "T()"}, {"node_id": 204, "universal_type": "function", "name": "unknown", "text_snippet": "T(eastl::forward<Args>(args)"}, {"node_id": 220, "universal_type": "function", "name": "unknown", "text_snippet": "currentHeapSize()"}, {"node_id": 278, "universal_type": "function", "name": "unknown", "text_snippet": "GetFrameHeap()"}], "class_declarations": [{"node_id": 273, "universal_type": "class", "name": "unknown", "text_snippet": "extern"}], "import_statements": [{"node_id": 0, "text": "#include <containers/containers.h>\r\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <mutex>\r\n"}, {"node_id": 4, "text": "#include"}]}, "original_source_code": "#include <containers/containers.h>\r\n#include <mutex>\r\n\r\nnamespace lambda\r\n{\r\n namespace foundation\r\n {\r\n class FrameHeap\r\n {\r\n public:\r\n friend FrameHeap* GetFrameHeap();\r\n static constexpr uint32_t kHeapCount = 5u;\r\n static constexpr uint32_t kHistoryCount = 10u;\r\n\r\n\t\t\tFrameHeap();\r\n\t\t\t~FrameHeap();\r\n void update();\r\n void* alloc(uint32_t size);\r\n\t\t\tvoid* realloc(void* prev, uint32_t prev_size, uint32_t new_size);\r\n\t\t\ttemplate<typename T>\r\n\t\t\tinline void deconstruct(T* t)\r\n\t\t\t{\r\n\t\t\t\tt->~T();\r\n\t\t\t}\r\n template<typename T>\r\n inline T* construct()\r\n {\r\n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));\r\n new (allocated) T();\r\n return allocated;\r\n }\r\n template<typename T, typename ...Args>\r\n inline T* construct(Args&& ...args)\r\n {\r\n T* allocated = reinterpret_cast<T*>(alloc(sizeof(T)));\r\n new (allocated) T(eastl::forward<Args>(args)...);\r\n return allocated;\r\n }\r\n\r\n uint32_t currentHeapSize();\r\n\r\n private:\r\n uint32_t current_frame_heap_;\r\n uint32_t current_history_;\r\n\r\n uint32_t allocated_;\r\n void* frame_heaps_[kHeapCount];\r\n uint32_t heap_sizes_[kHeapCount];\r\n uint32_t size_history_[kHistoryCount];\r\n Vector<void*> temp_allocs_[kHeapCount];\r\n\t\t\tstd::mutex mutex_;\r\n\r\n protected:\r\n static FrameHeap* s_frame_heap_;\r\n };\r\n\r\n extern FrameHeap* GetFrameHeap();\r\n }\r\n}"}
80,596
c
// Copyright (C) 2019 <NAME> <<EMAIL>> #ifndef LINALG_IO_H #define LINALG_IO_H #include <stdio.h> #include "datatypes/vector.h" #include "linalg/linalg.h" // Uses the format string to scan for a 2d or 3d vector to add to the // (resizable) array. bool v2_sscanf(char *buf, const char *fmt, vector *a); bool v3_sscanf(char *buf, const char *fmt, vector *a); // Takes a vector containing 2n floats and returns an array of vec2. vec2 *v2_array_pack(vector *a); vec3 *v3_array_pack(vector *a); vec2 *v2_array_read(FILE *f, int *n); #endif
34.67
15
(translation_unit) "// Copyright (C) 2019 <NAME> <<EMAIL>>\n#ifndef LINALG_IO_H\n#define LINALG_IO_H\n\n#include <stdio.h>\n\n#include "datatypes/vector.h"\n#include "linalg/linalg.h"\n\n// Uses the format string to scan for a 2d or 3d vector to add to the\n// (resizable) array.\nbool v2_sscanf(char *buf, const char *fmt, vector *a);\nbool v3_sscanf(char *buf, const char *fmt, vector *a);\n\n// Takes a vector containing 2n floats and returns an array of vec2.\nvec2 *v2_array_pack(vector *a);\nvec3 *v3_array_pack(vector *a);\n\nvec2 *v2_array_read(FILE *f, int *n);\n\n#endif\n" (comment) "// Copyright (C) 2019 <NAME> <<EMAIL>>" (preproc_ifdef) "#ifndef LINALG_IO_H\n#define LINALG_IO_H\n\n#include <stdio.h>\n\n#include "datatypes/vector.h"\n#include "linalg/linalg.h"\n\n// Uses the format string to scan for a 2d or 3d vector to add to the\n// (resizable) array.\nbool v2_sscanf(char *buf, const char *fmt, vector *a);\nbool v3_sscanf(char *buf, const char *fmt, vector *a);\n\n// Takes a vector containing 2n floats and returns an array of vec2.\nvec2 *v2_array_pack(vector *a);\nvec3 *v3_array_pack(vector *a);\n\nvec2 *v2_array_read(FILE *f, int *n);\n\n#endif" (#ifndef) "#ifndef" (identifier) "LINALG_IO_H" (preproc_def) "#define LINALG_IO_H\n" (#define) "#define" (identifier) "LINALG_IO_H" (preproc_include) "#include <stdio.h>\n" (#include) "#include" (system_lib_string) "<stdio.h>" (preproc_include) "#include "datatypes/vector.h"\n" (#include) "#include" (string_literal) ""datatypes/vector.h"" (") """ (string_content) "datatypes/vector.h" (") """ (preproc_include) "#include "linalg/linalg.h"\n" (#include) "#include" (string_literal) ""linalg/linalg.h"" (") """ (string_content) "linalg/linalg.h" (") """ (comment) "// Uses the format string to scan for a 2d or 3d vector to add to the" (comment) "// (resizable) array." (declaration) "bool v2_sscanf(char *buf, const char *fmt, vector *a);" (primitive_type) "bool" (function_declarator) "v2_sscanf(char *buf, const char *fmt, vector *a)" (identifier) "v2_sscanf" (parameter_list) "(char *buf, const char *fmt, vector *a)" (() "(" (parameter_declaration) "char *buf" (primitive_type) "char" (pointer_declarator) "*buf" (*) "*" (identifier) "buf" (,) "," (parameter_declaration) "const char *fmt" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "*fmt" (*) "*" (identifier) "fmt" (,) "," (parameter_declaration) "vector *a" (type_identifier) "vector" (pointer_declarator) "*a" (*) "*" (identifier) "a" ()) ")" (;) ";" (declaration) "bool v3_sscanf(char *buf, const char *fmt, vector *a);" (primitive_type) "bool" (function_declarator) "v3_sscanf(char *buf, const char *fmt, vector *a)" (identifier) "v3_sscanf" (parameter_list) "(char *buf, const char *fmt, vector *a)" (() "(" (parameter_declaration) "char *buf" (primitive_type) "char" (pointer_declarator) "*buf" (*) "*" (identifier) "buf" (,) "," (parameter_declaration) "const char *fmt" (type_qualifier) "const" (const) "const" (primitive_type) "char" (pointer_declarator) "*fmt" (*) "*" (identifier) "fmt" (,) "," (parameter_declaration) "vector *a" (type_identifier) "vector" (pointer_declarator) "*a" (*) "*" (identifier) "a" ()) ")" (;) ";" (comment) "// Takes a vector containing 2n floats and returns an array of vec2." (declaration) "vec2 *v2_array_pack(vector *a);" (type_identifier) "vec2" (pointer_declarator) "*v2_array_pack(vector *a)" (*) "*" (function_declarator) "v2_array_pack(vector *a)" (identifier) "v2_array_pack" (parameter_list) "(vector *a)" (() "(" (parameter_declaration) "vector *a" (type_identifier) "vector" (pointer_declarator) "*a" (*) "*" (identifier) "a" ()) ")" (;) ";" (declaration) "vec3 *v3_array_pack(vector *a);" (type_identifier) "vec3" (pointer_declarator) "*v3_array_pack(vector *a)" (*) "*" (function_declarator) "v3_array_pack(vector *a)" (identifier) "v3_array_pack" (parameter_list) "(vector *a)" (() "(" (parameter_declaration) "vector *a" (type_identifier) "vector" (pointer_declarator) "*a" (*) "*" (identifier) "a" ()) ")" (;) ";" (declaration) "vec2 *v2_array_read(FILE *f, int *n);" (type_identifier) "vec2" (pointer_declarator) "*v2_array_read(FILE *f, int *n)" (*) "*" (function_declarator) "v2_array_read(FILE *f, int *n)" (identifier) "v2_array_read" (parameter_list) "(FILE *f, int *n)" (() "(" (parameter_declaration) "FILE *f" (type_identifier) "FILE" (pointer_declarator) "*f" (*) "*" (identifier) "f" (,) "," (parameter_declaration) "int *n" (primitive_type) "int" (pointer_declarator) "*n" (*) "*" (identifier) "n" ()) ")" (;) ";" (#endif) "#endif"
132
0
{"language": "c", "success": true, "metadata": {"lines": 15, "avg_line_length": 34.67, "nodes": 97, "errors": 0, "source_hash": "6f647be633a6e8a6fbecf23fcb4fb35f343b7c6065af04d7134c72e3e5262ff4", "categorized_nodes": 57}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_ifdef", "text": "#ifndef LINALG_IO_H\n#define LINALG_IO_H\n\n#include <stdio.h>\n\n#include \"datatypes/vector.h\"\n#include \"linalg/linalg.h\"\n\n// Uses the format string to scan for a 2d or 3d vector to add to the\n// (resizable) array.\nbool v2_sscanf(char *buf, const char *fmt, vector *a);\nbool v3_sscanf(char *buf, const char *fmt, vector *a);\n\n// Takes a vector containing 2n floats and returns an array of vec2.\nvec2 *v2_array_pack(vector *a);\nvec3 *v3_array_pack(vector *a);\n\nvec2 *v2_array_read(FILE *f, int *n);\n\n#endif", "parent": null, "children": [1, 2, 3, 6, 9, 12, 15, 35, 55, 67, 79, 96], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 20, "column": 6}}, {"id": 1, "type": "#ifndef", "text": "#ifndef", "parent": 0, "children": [], "start_point": {"row": 1, "column": 0}, "end_point": {"row": 1, "column": 7}}, {"id": 2, "type": "identifier", "text": "LINALG_IO_H", "parent": 0, "children": [], "start_point": {"row": 1, "column": 8}, "end_point": {"row": 1, "column": 19}}, {"id": 3, "type": "preproc_def", "text": "#define LINALG_IO_H\n", "parent": 0, "children": [4, 5], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 3, "column": 0}}, {"id": 4, "type": "#define", "text": "#define", "parent": 3, "children": [], "start_point": {"row": 2, "column": 0}, "end_point": {"row": 2, "column": 7}}, {"id": 5, "type": "identifier", "text": "LINALG_IO_H", "parent": 3, "children": [], "start_point": {"row": 2, "column": 8}, "end_point": {"row": 2, "column": 19}}, {"id": 6, "type": "preproc_include", "text": "#include <stdio.h>\n", "parent": 0, "children": [7, 8], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<stdio.h>", "parent": 6, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 18}}, {"id": 9, "type": "preproc_include", "text": "#include \"datatypes/vector.h\"\n", "parent": 0, "children": [10, 11], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"datatypes/vector.h\"", "parent": 9, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 29}}, {"id": 12, "type": "preproc_include", "text": "#include \"linalg/linalg.h\"\n", "parent": 0, "children": [13, 14], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 8, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 7, "column": 0}, "end_point": {"row": 7, "column": 8}}, {"id": 14, "type": "string_literal", "text": "\"linalg/linalg.h\"", "parent": 12, "children": [], "start_point": {"row": 7, "column": 9}, "end_point": {"row": 7, "column": 26}}, {"id": 15, "type": "declaration", "text": "bool v2_sscanf(char *buf, const char *fmt, vector *a);", "parent": 0, "children": [16, 17], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 54}}, {"id": 16, "type": "primitive_type", "text": "bool", "parent": 15, "children": [], "start_point": {"row": 11, "column": 0}, "end_point": {"row": 11, "column": 4}}, {"id": 17, "type": "function_declarator", "text": "v2_sscanf(char *buf, const char *fmt, vector *a)", "parent": 15, "children": [18, 19], "start_point": {"row": 11, "column": 5}, "end_point": {"row": 11, "column": 53}}, {"id": 18, "type": "identifier", "text": "v2_sscanf", "parent": 17, "children": [], "start_point": {"row": 11, "column": 5}, "end_point": {"row": 11, "column": 14}}, {"id": 19, "type": "parameter_list", "text": "(char *buf, const char *fmt, vector *a)", "parent": 17, "children": [20, 25, 30], "start_point": {"row": 11, "column": 14}, "end_point": {"row": 11, "column": 53}}, {"id": 20, "type": "parameter_declaration", "text": "char *buf", "parent": 19, "children": [21, 22], "start_point": {"row": 11, "column": 15}, "end_point": {"row": 11, "column": 24}}, {"id": 21, "type": "primitive_type", "text": "char", "parent": 20, "children": [], "start_point": {"row": 11, "column": 15}, "end_point": {"row": 11, "column": 19}}, {"id": 22, "type": "pointer_declarator", "text": "*buf", "parent": 20, "children": [23, 24], "start_point": {"row": 11, "column": 20}, "end_point": {"row": 11, "column": 24}}, {"id": 23, "type": "*", "text": "*", "parent": 22, "children": [], "start_point": {"row": 11, "column": 20}, "end_point": {"row": 11, "column": 21}}, {"id": 24, "type": "identifier", "text": "buf", "parent": 22, "children": [], "start_point": {"row": 11, "column": 21}, "end_point": {"row": 11, "column": 24}}, {"id": 25, "type": "parameter_declaration", "text": "const char *fmt", "parent": 19, "children": [26, 27], "start_point": {"row": 11, "column": 26}, "end_point": {"row": 11, "column": 41}}, {"id": 26, "type": "primitive_type", "text": "char", "parent": 25, "children": [], "start_point": {"row": 11, "column": 32}, "end_point": {"row": 11, "column": 36}}, {"id": 27, "type": "pointer_declarator", "text": "*fmt", "parent": 25, "children": [28, 29], "start_point": {"row": 11, "column": 37}, "end_point": {"row": 11, "column": 41}}, {"id": 28, "type": "*", "text": "*", "parent": 27, "children": [], "start_point": {"row": 11, "column": 37}, "end_point": {"row": 11, "column": 38}}, {"id": 29, "type": "identifier", "text": "fmt", "parent": 27, "children": [], "start_point": {"row": 11, "column": 38}, "end_point": {"row": 11, "column": 41}}, {"id": 30, "type": "parameter_declaration", "text": "vector *a", "parent": 19, "children": [31, 32], "start_point": {"row": 11, "column": 43}, "end_point": {"row": 11, "column": 52}}, {"id": 31, "type": "type_identifier", "text": "vector", "parent": 30, "children": [], "start_point": {"row": 11, "column": 43}, "end_point": {"row": 11, "column": 49}}, {"id": 32, "type": "pointer_declarator", "text": "*a", "parent": 30, "children": [33, 34], "start_point": {"row": 11, "column": 50}, "end_point": {"row": 11, "column": 52}}, {"id": 33, "type": "*", "text": "*", "parent": 32, "children": [], "start_point": {"row": 11, "column": 50}, "end_point": {"row": 11, "column": 51}}, {"id": 34, "type": "identifier", "text": "a", "parent": 32, "children": [], "start_point": {"row": 11, "column": 51}, "end_point": {"row": 11, "column": 52}}, {"id": 35, "type": "declaration", "text": "bool v3_sscanf(char *buf, const char *fmt, vector *a);", "parent": 0, "children": [36, 37], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 54}}, {"id": 36, "type": "primitive_type", "text": "bool", "parent": 35, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 4}}, {"id": 37, "type": "function_declarator", "text": "v3_sscanf(char *buf, const char *fmt, vector *a)", "parent": 35, "children": [38, 39], "start_point": {"row": 12, "column": 5}, "end_point": {"row": 12, "column": 53}}, {"id": 38, "type": "identifier", "text": "v3_sscanf", "parent": 37, "children": [], "start_point": {"row": 12, "column": 5}, "end_point": {"row": 12, "column": 14}}, {"id": 39, "type": "parameter_list", "text": "(char *buf, const char *fmt, vector *a)", "parent": 37, "children": [40, 45, 50], "start_point": {"row": 12, "column": 14}, "end_point": {"row": 12, "column": 53}}, {"id": 40, "type": "parameter_declaration", "text": "char *buf", "parent": 39, "children": [41, 42], "start_point": {"row": 12, "column": 15}, "end_point": {"row": 12, "column": 24}}, {"id": 41, "type": "primitive_type", "text": "char", "parent": 40, "children": [], "start_point": {"row": 12, "column": 15}, "end_point": {"row": 12, "column": 19}}, {"id": 42, "type": "pointer_declarator", "text": "*buf", "parent": 40, "children": [43, 44], "start_point": {"row": 12, "column": 20}, "end_point": {"row": 12, "column": 24}}, {"id": 43, "type": "*", "text": "*", "parent": 42, "children": [], "start_point": {"row": 12, "column": 20}, "end_point": {"row": 12, "column": 21}}, {"id": 44, "type": "identifier", "text": "buf", "parent": 42, "children": [], "start_point": {"row": 12, "column": 21}, "end_point": {"row": 12, "column": 24}}, {"id": 45, "type": "parameter_declaration", "text": "const char *fmt", "parent": 39, "children": [46, 47], "start_point": {"row": 12, "column": 26}, "end_point": {"row": 12, "column": 41}}, {"id": 46, "type": "primitive_type", "text": "char", "parent": 45, "children": [], "start_point": {"row": 12, "column": 32}, "end_point": {"row": 12, "column": 36}}, {"id": 47, "type": "pointer_declarator", "text": "*fmt", "parent": 45, "children": [48, 49], "start_point": {"row": 12, "column": 37}, "end_point": {"row": 12, "column": 41}}, {"id": 48, "type": "*", "text": "*", "parent": 47, "children": [], "start_point": {"row": 12, "column": 37}, "end_point": {"row": 12, "column": 38}}, {"id": 49, "type": "identifier", "text": "fmt", "parent": 47, "children": [], "start_point": {"row": 12, "column": 38}, "end_point": {"row": 12, "column": 41}}, {"id": 50, "type": "parameter_declaration", "text": "vector *a", "parent": 39, "children": [51, 52], "start_point": {"row": 12, "column": 43}, "end_point": {"row": 12, "column": 52}}, {"id": 51, "type": "type_identifier", "text": "vector", "parent": 50, "children": [], "start_point": {"row": 12, "column": 43}, "end_point": {"row": 12, "column": 49}}, {"id": 52, "type": "pointer_declarator", "text": "*a", "parent": 50, "children": [53, 54], "start_point": {"row": 12, "column": 50}, "end_point": {"row": 12, "column": 52}}, {"id": 53, "type": "*", "text": "*", "parent": 52, "children": [], "start_point": {"row": 12, "column": 50}, "end_point": {"row": 12, "column": 51}}, {"id": 54, "type": "identifier", "text": "a", "parent": 52, "children": [], "start_point": {"row": 12, "column": 51}, "end_point": {"row": 12, "column": 52}}, {"id": 55, "type": "declaration", "text": "vec2 *v2_array_pack(vector *a);", "parent": 0, "children": [56, 57], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 31}}, {"id": 56, "type": "type_identifier", "text": "vec2", "parent": 55, "children": [], "start_point": {"row": 15, "column": 0}, "end_point": {"row": 15, "column": 4}}, {"id": 57, "type": "pointer_declarator", "text": "*v2_array_pack(vector *a)", "parent": 55, "children": [58, 59], "start_point": {"row": 15, "column": 5}, "end_point": {"row": 15, "column": 30}}, {"id": 58, "type": "*", "text": "*", "parent": 57, "children": [], "start_point": {"row": 15, "column": 5}, "end_point": {"row": 15, "column": 6}}, {"id": 59, "type": "function_declarator", "text": "v2_array_pack(vector *a)", "parent": 57, "children": [60, 61], "start_point": {"row": 15, "column": 6}, "end_point": {"row": 15, "column": 30}}, {"id": 60, "type": "identifier", "text": "v2_array_pack", "parent": 59, "children": [], "start_point": {"row": 15, "column": 6}, "end_point": {"row": 15, "column": 19}}, {"id": 61, "type": "parameter_list", "text": "(vector *a)", "parent": 59, "children": [62], "start_point": {"row": 15, "column": 19}, "end_point": {"row": 15, "column": 30}}, {"id": 62, "type": "parameter_declaration", "text": "vector *a", "parent": 61, "children": [63, 64], "start_point": {"row": 15, "column": 20}, "end_point": {"row": 15, "column": 29}}, {"id": 63, "type": "type_identifier", "text": "vector", "parent": 62, "children": [], "start_point": {"row": 15, "column": 20}, "end_point": {"row": 15, "column": 26}}, {"id": 64, "type": "pointer_declarator", "text": "*a", "parent": 62, "children": [65, 66], "start_point": {"row": 15, "column": 27}, "end_point": {"row": 15, "column": 29}}, {"id": 65, "type": "*", "text": "*", "parent": 64, "children": [], "start_point": {"row": 15, "column": 27}, "end_point": {"row": 15, "column": 28}}, {"id": 66, "type": "identifier", "text": "a", "parent": 64, "children": [], "start_point": {"row": 15, "column": 28}, "end_point": {"row": 15, "column": 29}}, {"id": 67, "type": "declaration", "text": "vec3 *v3_array_pack(vector *a);", "parent": 0, "children": [68, 69], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 31}}, {"id": 68, "type": "type_identifier", "text": "vec3", "parent": 67, "children": [], "start_point": {"row": 16, "column": 0}, "end_point": {"row": 16, "column": 4}}, {"id": 69, "type": "pointer_declarator", "text": "*v3_array_pack(vector *a)", "parent": 67, "children": [70, 71], "start_point": {"row": 16, "column": 5}, "end_point": {"row": 16, "column": 30}}, {"id": 70, "type": "*", "text": "*", "parent": 69, "children": [], "start_point": {"row": 16, "column": 5}, "end_point": {"row": 16, "column": 6}}, {"id": 71, "type": "function_declarator", "text": "v3_array_pack(vector *a)", "parent": 69, "children": [72, 73], "start_point": {"row": 16, "column": 6}, "end_point": {"row": 16, "column": 30}}, {"id": 72, "type": "identifier", "text": "v3_array_pack", "parent": 71, "children": [], "start_point": {"row": 16, "column": 6}, "end_point": {"row": 16, "column": 19}}, {"id": 73, "type": "parameter_list", "text": "(vector *a)", "parent": 71, "children": [74], "start_point": {"row": 16, "column": 19}, "end_point": {"row": 16, "column": 30}}, {"id": 74, "type": "parameter_declaration", "text": "vector *a", "parent": 73, "children": [75, 76], "start_point": {"row": 16, "column": 20}, "end_point": {"row": 16, "column": 29}}, {"id": 75, "type": "type_identifier", "text": "vector", "parent": 74, "children": [], "start_point": {"row": 16, "column": 20}, "end_point": {"row": 16, "column": 26}}, {"id": 76, "type": "pointer_declarator", "text": "*a", "parent": 74, "children": [77, 78], "start_point": {"row": 16, "column": 27}, "end_point": {"row": 16, "column": 29}}, {"id": 77, "type": "*", "text": "*", "parent": 76, "children": [], "start_point": {"row": 16, "column": 27}, "end_point": {"row": 16, "column": 28}}, {"id": 78, "type": "identifier", "text": "a", "parent": 76, "children": [], "start_point": {"row": 16, "column": 28}, "end_point": {"row": 16, "column": 29}}, {"id": 79, "type": "declaration", "text": "vec2 *v2_array_read(FILE *f, int *n);", "parent": 0, "children": [80, 81], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 37}}, {"id": 80, "type": "type_identifier", "text": "vec2", "parent": 79, "children": [], "start_point": {"row": 18, "column": 0}, "end_point": {"row": 18, "column": 4}}, {"id": 81, "type": "pointer_declarator", "text": "*v2_array_read(FILE *f, int *n)", "parent": 79, "children": [82, 83], "start_point": {"row": 18, "column": 5}, "end_point": {"row": 18, "column": 36}}, {"id": 82, "type": "*", "text": "*", "parent": 81, "children": [], "start_point": {"row": 18, "column": 5}, "end_point": {"row": 18, "column": 6}}, {"id": 83, "type": "function_declarator", "text": "v2_array_read(FILE *f, int *n)", "parent": 81, "children": [84, 85], "start_point": {"row": 18, "column": 6}, "end_point": {"row": 18, "column": 36}}, {"id": 84, "type": "identifier", "text": "v2_array_read", "parent": 83, "children": [], "start_point": {"row": 18, "column": 6}, "end_point": {"row": 18, "column": 19}}, {"id": 85, "type": "parameter_list", "text": "(FILE *f, int *n)", "parent": 83, "children": [86, 91], "start_point": {"row": 18, "column": 19}, "end_point": {"row": 18, "column": 36}}, {"id": 86, "type": "parameter_declaration", "text": "FILE *f", "parent": 85, "children": [87, 88], "start_point": {"row": 18, "column": 20}, "end_point": {"row": 18, "column": 27}}, {"id": 87, "type": "type_identifier", "text": "FILE", "parent": 86, "children": [], "start_point": {"row": 18, "column": 20}, "end_point": {"row": 18, "column": 24}}, {"id": 88, "type": "pointer_declarator", "text": "*f", "parent": 86, "children": [89, 90], "start_point": {"row": 18, "column": 25}, "end_point": {"row": 18, "column": 27}}, {"id": 89, "type": "*", "text": "*", "parent": 88, "children": [], "start_point": {"row": 18, "column": 25}, "end_point": {"row": 18, "column": 26}}, {"id": 90, "type": "identifier", "text": "f", "parent": 88, "children": [], "start_point": {"row": 18, "column": 26}, "end_point": {"row": 18, "column": 27}}, {"id": 91, "type": "parameter_declaration", "text": "int *n", "parent": 85, "children": [92, 93], "start_point": {"row": 18, "column": 29}, "end_point": {"row": 18, "column": 35}}, {"id": 92, "type": "primitive_type", "text": "int", "parent": 91, "children": [], "start_point": {"row": 18, "column": 29}, "end_point": {"row": 18, "column": 32}}, {"id": 93, "type": "pointer_declarator", "text": "*n", "parent": 91, "children": [94, 95], "start_point": {"row": 18, "column": 33}, "end_point": {"row": 18, "column": 35}}, {"id": 94, "type": "*", "text": "*", "parent": 93, "children": [], "start_point": {"row": 18, "column": 33}, "end_point": {"row": 18, "column": 34}}, {"id": 95, "type": "identifier", "text": "n", "parent": 93, "children": [], "start_point": {"row": 18, "column": 34}, "end_point": {"row": 18, "column": 35}}, {"id": 96, "type": "#endif", "text": "#endif", "parent": 0, "children": [], "start_point": {"row": 20, "column": 0}, "end_point": {"row": 20, "column": 6}}]}, "node_categories": {"declarations": {"functions": [17, 37, 59, 71, 83], "variables": [15, 20, 25, 30, 35, 40, 45, 50, 55, 62, 67, 74, 79, 86, 91], "classes": [], "imports": [6, 7, 9, 10, 12, 13], "modules": [], "enums": []}, "statements": {"expressions": [], "assignments": [], "loops": [], "conditionals": [0, 1, 2, 5, 18, 24, 29, 31, 34, 38, 44, 49, 51, 54, 56, 60, 63, 66, 68, 72, 75, 78, 80, 84, 87, 90, 95, 96], "returns": [], "exceptions": []}, "expressions": {"calls": [], "literals": [8, 11, 14], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 17, "universal_type": "function", "name": "unknown", "text_snippet": "v2_sscanf(char *buf, const char *fmt, vector *a)"}, {"node_id": 37, "universal_type": "function", "name": "unknown", "text_snippet": "v3_sscanf(char *buf, const char *fmt, vector *a)"}, {"node_id": 59, "universal_type": "function", "name": "unknown", "text_snippet": "v2_array_pack(vector *a)"}, {"node_id": 71, "universal_type": "function", "name": "unknown", "text_snippet": "v3_array_pack(vector *a)"}, {"node_id": 83, "universal_type": "function", "name": "*n)", "text_snippet": "v2_array_read(FILE *f, int *n)"}], "class_declarations": [], "import_statements": [{"node_id": 6, "text": "#include <stdio.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include \"datatypes/vector.h\"\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include \"linalg/linalg.h\"\n"}, {"node_id": 13, "text": "#include"}]}, "original_source_code": "// Copyright (C) 2019 <NAME> <<EMAIL>>\n#ifndef LINALG_IO_H\n#define LINALG_IO_H\n\n#include <stdio.h>\n\n#include \"datatypes/vector.h\"\n#include \"linalg/linalg.h\"\n\n// Uses the format string to scan for a 2d or 3d vector to add to the\n// (resizable) array.\nbool v2_sscanf(char *buf, const char *fmt, vector *a);\nbool v3_sscanf(char *buf, const char *fmt, vector *a);\n\n// Takes a vector containing 2n floats and returns an array of vec2.\nvec2 *v2_array_pack(vector *a);\nvec3 *v3_array_pack(vector *a);\n\nvec2 *v2_array_read(FILE *f, int *n);\n\n#endif\n"}
80,597
c
/*********************************************************** Copyright (c) 1987 X Consortium Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. Except as contained in this notice, the name of the X Consortium shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Software without prior written authorization from the X Consortium. Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts. All Rights Reserved Permission to use, copy, modify, and distribute this software and its documentation for any purpose and without fee is hereby granted, provided that the above copyright notice appear in all copies and that both that copyright notice and this permission notice appear in supporting documentation, and that the name of Digital not be used in advertising or publicity pertaining to distribution of the software without specific, written prior permission. DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ******************************************************************/ /* $XConsortium: mipoly.c,v 5.1 94/04/17 20:27:41 keith Exp $ */ /* * mipoly.c * * Written by <NAME>; June 1986 * * Draw polygons. This routine translates the point by the * origin if pGC->miTranslate is non-zero, and calls * to the appropriate routine to actually scan convert the * polygon. */ #include "X.h" #include "windowstr.h" #include "gcstruct.h" #include "pixmapstr.h" #include "mi.h" #include "miscstruct.h" void miFillPolygon(dst, pgc, shape, mode, count, pPts) DrawablePtr dst; register GCPtr pgc; int shape, mode; register int count; DDXPointPtr pPts; { int i; register int xorg, yorg; register DDXPointPtr ppt; if (count == 0) return; ppt = pPts; if (pgc->miTranslate) { xorg = dst->x; yorg = dst->y; if (mode == CoordModeOrigin) { for (i = 0; i<count; i++) { ppt->x += xorg; ppt++->y += yorg; } } else { ppt->x += xorg; ppt++->y += yorg; for (i = 1; i<count; i++) { ppt->x += (ppt-1)->x; ppt->y += (ppt-1)->y; ppt++; } } } else { if (mode == CoordModePrevious) { ppt++; for (i = 1; i<count; i++) { ppt->x += (ppt-1)->x; ppt->y += (ppt-1)->y; ppt++; } } } if (shape == Convex) miFillConvexPoly(dst, pgc, count, pPts); else miFillGeneralPoly(dst, pgc, count, pPts); }
34.47
111
(translation_unit) "/***********************************************************\n\nCopyright (c) 1987 X Consortium\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the "Software"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in\nall copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nX CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN\nAN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\nCONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n\nExcept as contained in this notice, the name of the X Consortium shall not be\nused in advertising or otherwise to promote the sale, use or other dealings\nin this Software without prior written authorization from the X Consortium.\n\n\nCopyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts.\n\n All Rights Reserved\n\nPermission to use, copy, modify, and distribute this software and its \ndocumentation for any purpose and without fee is hereby granted, \nprovided that the above copyright notice appear in all copies and that\nboth that copyright notice and this permission notice appear in \nsupporting documentation, and that the name of Digital not be\nused in advertising or publicity pertaining to distribution of the\nsoftware without specific, written prior permission. \n\nDIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING\nALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL\nDIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR\nANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,\nWHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,\nARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS\nSOFTWARE.\n\n******************************************************************/\n/* $XConsortium: mipoly.c,v 5.1 94/04/17 20:27:41 keith Exp $ */\n/*\n * mipoly.c\n *\n * Written by <NAME>; June 1986\n *\n * Draw polygons. This routine translates the point by the\n * origin if pGC->miTranslate is non-zero, and calls\n * to the appropriate routine to actually scan convert the\n * polygon.\n */\n#include "X.h"\n#include "windowstr.h"\n#include "gcstruct.h"\n#include "pixmapstr.h"\n#include "mi.h"\n#include "miscstruct.h"\n\n\nvoid\nmiFillPolygon(dst, pgc, shape, mode, count, pPts)\n DrawablePtr dst;\n register GCPtr pgc;\n int shape, mode;\n register int count;\n DDXPointPtr pPts;\n{\n int i;\n register int xorg, yorg;\n register DDXPointPtr ppt;\n\n if (count == 0)\n return;\n\n ppt = pPts;\n if (pgc->miTranslate)\n {\n xorg = dst->x;\n yorg = dst->y;\n\n if (mode == CoordModeOrigin) \n {\n for (i = 0; i<count; i++) \n { \n ppt->x += xorg;\n ppt++->y += yorg;\n }\n }\n else \n {\n ppt->x += xorg;\n ppt++->y += yorg;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }\n }\n else\n {\n if (mode == CoordModePrevious)\n {\n ppt++;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }\n }\n if (shape == Convex)\n miFillConvexPoly(dst, pgc, count, pPts);\n else\n miFillGeneralPoly(dst, pgc, count, pPts);\n}\n" (comment) "/***********************************************************\n\nCopyright (c) 1987 X Consortium\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the "Software"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in\nall copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nX CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN\nAN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\nCONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n\nExcept as contained in this notice, the name of the X Consortium shall not be\nused in advertising or otherwise to promote the sale, use or other dealings\nin this Software without prior written authorization from the X Consortium.\n\n\nCopyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts.\n\n All Rights Reserved\n\nPermission to use, copy, modify, and distribute this software and its \ndocumentation for any purpose and without fee is hereby granted, \nprovided that the above copyright notice appear in all copies and that\nboth that copyright notice and this permission notice appear in \nsupporting documentation, and that the name of Digital not be\nused in advertising or publicity pertaining to distribution of the\nsoftware without specific, written prior permission. \n\nDIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING\nALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL\nDIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR\nANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,\nWHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,\nARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS\nSOFTWARE.\n\n******************************************************************/" (comment) "/* $XConsortium: mipoly.c,v 5.1 94/04/17 20:27:41 keith Exp $ */" (comment) "/*\n * mipoly.c\n *\n * Written by <NAME>; June 1986\n *\n * Draw polygons. This routine translates the point by the\n * origin if pGC->miTranslate is non-zero, and calls\n * to the appropriate routine to actually scan convert the\n * polygon.\n */" (preproc_include) "#include "X.h"\n" (#include) "#include" (string_literal) ""X.h"" (") """ (string_content) "X.h" (") """ (preproc_include) "#include "windowstr.h"\n" (#include) "#include" (string_literal) ""windowstr.h"" (") """ (string_content) "windowstr.h" (") """ (preproc_include) "#include "gcstruct.h"\n" (#include) "#include" (string_literal) ""gcstruct.h"" (") """ (string_content) "gcstruct.h" (") """ (preproc_include) "#include "pixmapstr.h"\n" (#include) "#include" (string_literal) ""pixmapstr.h"" (") """ (string_content) "pixmapstr.h" (") """ (preproc_include) "#include "mi.h"\n" (#include) "#include" (string_literal) ""mi.h"" (") """ (string_content) "mi.h" (") """ (preproc_include) "#include "miscstruct.h"\n" (#include) "#include" (string_literal) ""miscstruct.h"" (") """ (string_content) "miscstruct.h" (") """ (function_definition) "void\nmiFillPolygon(dst, pgc, shape, mode, count, pPts)\n DrawablePtr dst;\n register GCPtr pgc;\n int shape, mode;\n register int count;\n DDXPointPtr pPts;\n{\n int i;\n register int xorg, yorg;\n register DDXPointPtr ppt;\n\n if (count == 0)\n return;\n\n ppt = pPts;\n if (pgc->miTranslate)\n {\n xorg = dst->x;\n yorg = dst->y;\n\n if (mode == CoordModeOrigin) \n {\n for (i = 0; i<count; i++) \n { \n ppt->x += xorg;\n ppt++->y += yorg;\n }\n }\n else \n {\n ppt->x += xorg;\n ppt++->y += yorg;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }\n }\n else\n {\n if (mode == CoordModePrevious)\n {\n ppt++;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }\n }\n if (shape == Convex)\n miFillConvexPoly(dst, pgc, count, pPts);\n else\n miFillGeneralPoly(dst, pgc, count, pPts);\n}" (primitive_type) "void" (function_declarator) "miFillPolygon(dst, pgc, shape, mode, count, pPts)" (identifier) "miFillPolygon" (parameter_list) "(dst, pgc, shape, mode, count, pPts)" (() "(" (identifier) "dst" (,) "," (identifier) "pgc" (,) "," (identifier) "shape" (,) "," (identifier) "mode" (,) "," (identifier) "count" (,) "," (identifier) "pPts" ()) ")" (declaration) "DrawablePtr dst;" (type_identifier) "DrawablePtr" (identifier) "dst" (;) ";" (declaration) "register GCPtr pgc;" (storage_class_specifier) "register" (register) "register" (type_identifier) "GCPtr" (identifier) "pgc" (;) ";" (declaration) "int shape, mode;" (primitive_type) "int" (identifier) "shape" (,) "," (identifier) "mode" (;) ";" (declaration) "register int count;" (storage_class_specifier) "register" (register) "register" (primitive_type) "int" (identifier) "count" (;) ";" (declaration) "DDXPointPtr pPts;" (type_identifier) "DDXPointPtr" (identifier) "pPts" (;) ";" (compound_statement) "{\n int i;\n register int xorg, yorg;\n register DDXPointPtr ppt;\n\n if (count == 0)\n return;\n\n ppt = pPts;\n if (pgc->miTranslate)\n {\n xorg = dst->x;\n yorg = dst->y;\n\n if (mode == CoordModeOrigin) \n {\n for (i = 0; i<count; i++) \n { \n ppt->x += xorg;\n ppt++->y += yorg;\n }\n }\n else \n {\n ppt->x += xorg;\n ppt++->y += yorg;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }\n }\n else\n {\n if (mode == CoordModePrevious)\n {\n ppt++;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }\n }\n if (shape == Convex)\n miFillConvexPoly(dst, pgc, count, pPts);\n else\n miFillGeneralPoly(dst, pgc, count, pPts);\n}" ({) "{" (declaration) "int i;" (primitive_type) "int" (identifier) "i" (;) ";" (declaration) "register int xorg, yorg;" (storage_class_specifier) "register" (register) "register" (primitive_type) "int" (identifier) "xorg" (,) "," (identifier) "yorg" (;) ";" (declaration) "register DDXPointPtr ppt;" (storage_class_specifier) "register" (register) "register" (type_identifier) "DDXPointPtr" (identifier) "ppt" (;) ";" (if_statement) "if (count == 0)\n return;" (if) "if" (parenthesized_expression) "(count == 0)" (() "(" (binary_expression) "count == 0" (identifier) "count" (==) "==" (number_literal) "0" ()) ")" (return_statement) "return;" (return) "return" (;) ";" (expression_statement) "ppt = pPts;" (assignment_expression) "ppt = pPts" (identifier) "ppt" (=) "=" (identifier) "pPts" (;) ";" (if_statement) "if (pgc->miTranslate)\n {\n xorg = dst->x;\n yorg = dst->y;\n\n if (mode == CoordModeOrigin) \n {\n for (i = 0; i<count; i++) \n { \n ppt->x += xorg;\n ppt++->y += yorg;\n }\n }\n else \n {\n ppt->x += xorg;\n ppt++->y += yorg;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }\n }\n else\n {\n if (mode == CoordModePrevious)\n {\n ppt++;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }\n }" (if) "if" (parenthesized_expression) "(pgc->miTranslate)" (() "(" (field_expression) "pgc->miTranslate" (identifier) "pgc" (->) "->" (field_identifier) "miTranslate" ()) ")" (compound_statement) "{\n xorg = dst->x;\n yorg = dst->y;\n\n if (mode == CoordModeOrigin) \n {\n for (i = 0; i<count; i++) \n { \n ppt->x += xorg;\n ppt++->y += yorg;\n }\n }\n else \n {\n ppt->x += xorg;\n ppt++->y += yorg;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }\n }" ({) "{" (expression_statement) "xorg = dst->x;" (assignment_expression) "xorg = dst->x" (identifier) "xorg" (=) "=" (field_expression) "dst->x" (identifier) "dst" (->) "->" (field_identifier) "x" (;) ";" (expression_statement) "yorg = dst->y;" (assignment_expression) "yorg = dst->y" (identifier) "yorg" (=) "=" (field_expression) "dst->y" (identifier) "dst" (->) "->" (field_identifier) "y" (;) ";" (if_statement) "if (mode == CoordModeOrigin) \n {\n for (i = 0; i<count; i++) \n { \n ppt->x += xorg;\n ppt++->y += yorg;\n }\n }\n else \n {\n ppt->x += xorg;\n ppt++->y += yorg;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }" (if) "if" (parenthesized_expression) "(mode == CoordModeOrigin)" (() "(" (binary_expression) "mode == CoordModeOrigin" (identifier) "mode" (==) "==" (identifier) "CoordModeOrigin" ()) ")" (compound_statement) "{\n for (i = 0; i<count; i++) \n { \n ppt->x += xorg;\n ppt++->y += yorg;\n }\n }" ({) "{" (for_statement) "for (i = 0; i<count; i++) \n { \n ppt->x += xorg;\n ppt++->y += yorg;\n }" (for) "for" (() "(" (assignment_expression) "i = 0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (binary_expression) "i<count" (identifier) "i" (<) "<" (identifier) "count" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (compound_statement) "{ \n ppt->x += xorg;\n ppt++->y += yorg;\n }" ({) "{" (expression_statement) "ppt->x += xorg;" (assignment_expression) "ppt->x += xorg" (field_expression) "ppt->x" (identifier) "ppt" (->) "->" (field_identifier) "x" (+=) "+=" (identifier) "xorg" (;) ";" (expression_statement) "ppt++->y += yorg;" (assignment_expression) "ppt++->y += yorg" (field_expression) "ppt++->y" (update_expression) "ppt++" (identifier) "ppt" (++) "++" (->) "->" (field_identifier) "y" (+=) "+=" (identifier) "yorg" (;) ";" (}) "}" (}) "}" (else_clause) "else \n {\n ppt->x += xorg;\n ppt++->y += yorg;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }" (else) "else" (compound_statement) "{\n ppt->x += xorg;\n ppt++->y += yorg;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }" ({) "{" (expression_statement) "ppt->x += xorg;" (assignment_expression) "ppt->x += xorg" (field_expression) "ppt->x" (identifier) "ppt" (->) "->" (field_identifier) "x" (+=) "+=" (identifier) "xorg" (;) ";" (expression_statement) "ppt++->y += yorg;" (assignment_expression) "ppt++->y += yorg" (field_expression) "ppt++->y" (update_expression) "ppt++" (identifier) "ppt" (++) "++" (->) "->" (field_identifier) "y" (+=) "+=" (identifier) "yorg" (;) ";" (for_statement) "for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }" (for) "for" (() "(" (assignment_expression) "i = 1" (identifier) "i" (=) "=" (number_literal) "1" (;) ";" (binary_expression) "i<count" (identifier) "i" (<) "<" (identifier) "count" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (compound_statement) "{\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }" ({) "{" (expression_statement) "ppt->x += (ppt-1)->x;" (assignment_expression) "ppt->x += (ppt-1)->x" (field_expression) "ppt->x" (identifier) "ppt" (->) "->" (field_identifier) "x" (+=) "+=" (field_expression) "(ppt-1)->x" (parenthesized_expression) "(ppt-1)" (() "(" (binary_expression) "ppt-1" (identifier) "ppt" (-) "-" (number_literal) "1" ()) ")" (->) "->" (field_identifier) "x" (;) ";" (expression_statement) "ppt->y += (ppt-1)->y;" (assignment_expression) "ppt->y += (ppt-1)->y" (field_expression) "ppt->y" (identifier) "ppt" (->) "->" (field_identifier) "y" (+=) "+=" (field_expression) "(ppt-1)->y" (parenthesized_expression) "(ppt-1)" (() "(" (binary_expression) "ppt-1" (identifier) "ppt" (-) "-" (number_literal) "1" ()) ")" (->) "->" (field_identifier) "y" (;) ";" (expression_statement) "ppt++;" (update_expression) "ppt++" (identifier) "ppt" (++) "++" (;) ";" (}) "}" (}) "}" (}) "}" (else_clause) "else\n {\n if (mode == CoordModePrevious)\n {\n ppt++;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }\n }" (else) "else" (compound_statement) "{\n if (mode == CoordModePrevious)\n {\n ppt++;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }\n }" ({) "{" (if_statement) "if (mode == CoordModePrevious)\n {\n ppt++;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }" (if) "if" (parenthesized_expression) "(mode == CoordModePrevious)" (() "(" (binary_expression) "mode == CoordModePrevious" (identifier) "mode" (==) "==" (identifier) "CoordModePrevious" ()) ")" (compound_statement) "{\n ppt++;\n for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }\n }" ({) "{" (expression_statement) "ppt++;" (update_expression) "ppt++" (identifier) "ppt" (++) "++" (;) ";" (for_statement) "for (i = 1; i<count; i++) \n {\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }" (for) "for" (() "(" (assignment_expression) "i = 1" (identifier) "i" (=) "=" (number_literal) "1" (;) ";" (binary_expression) "i<count" (identifier) "i" (<) "<" (identifier) "count" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (compound_statement) "{\n ppt->x += (ppt-1)->x;\n ppt->y += (ppt-1)->y;\n ppt++;\n }" ({) "{" (expression_statement) "ppt->x += (ppt-1)->x;" (assignment_expression) "ppt->x += (ppt-1)->x" (field_expression) "ppt->x" (identifier) "ppt" (->) "->" (field_identifier) "x" (+=) "+=" (field_expression) "(ppt-1)->x" (parenthesized_expression) "(ppt-1)" (() "(" (binary_expression) "ppt-1" (identifier) "ppt" (-) "-" (number_literal) "1" ()) ")" (->) "->" (field_identifier) "x" (;) ";" (expression_statement) "ppt->y += (ppt-1)->y;" (assignment_expression) "ppt->y += (ppt-1)->y" (field_expression) "ppt->y" (identifier) "ppt" (->) "->" (field_identifier) "y" (+=) "+=" (field_expression) "(ppt-1)->y" (parenthesized_expression) "(ppt-1)" (() "(" (binary_expression) "ppt-1" (identifier) "ppt" (-) "-" (number_literal) "1" ()) ")" (->) "->" (field_identifier) "y" (;) ";" (expression_statement) "ppt++;" (update_expression) "ppt++" (identifier) "ppt" (++) "++" (;) ";" (}) "}" (}) "}" (}) "}" (if_statement) "if (shape == Convex)\n miFillConvexPoly(dst, pgc, count, pPts);\n else\n miFillGeneralPoly(dst, pgc, count, pPts);" (if) "if" (parenthesized_expression) "(shape == Convex)" (() "(" (binary_expression) "shape == Convex" (identifier) "shape" (==) "==" (identifier) "Convex" ()) ")" (expression_statement) "miFillConvexPoly(dst, pgc, count, pPts);" (call_expression) "miFillConvexPoly(dst, pgc, count, pPts)" (identifier) "miFillConvexPoly" (argument_list) "(dst, pgc, count, pPts)" (() "(" (identifier) "dst" (,) "," (identifier) "pgc" (,) "," (identifier) "count" (,) "," (identifier) "pPts" ()) ")" (;) ";" (else_clause) "else\n miFillGeneralPoly(dst, pgc, count, pPts);" (else) "else" (expression_statement) "miFillGeneralPoly(dst, pgc, count, pPts);" (call_expression) "miFillGeneralPoly(dst, pgc, count, pPts)" (identifier) "miFillGeneralPoly" (argument_list) "(dst, pgc, count, pPts)" (() "(" (identifier) "dst" (,) "," (identifier) "pgc" (,) "," (identifier) "count" (,) "," (identifier) "pPts" ()) ")" (;) ";" (}) "}"
413
0
{"language": "c", "success": true, "metadata": {"lines": 111, "avg_line_length": 34.47, "nodes": 247, "errors": 0, "source_hash": "c437ad1b5dfc629a309bc1d8e837f1e2bdefb10cde9e09e9c0779ebdb5a4655c", "categorized_nodes": 199}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include \"X.h\"\n", "parent": null, "children": [1, 2], "start_point": {"row": 58, "column": 0}, "end_point": {"row": 59, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 58, "column": 0}, "end_point": {"row": 58, "column": 8}}, {"id": 2, "type": "string_literal", "text": "\"X.h\"", "parent": 0, "children": [], "start_point": {"row": 58, "column": 9}, "end_point": {"row": 58, "column": 14}}, {"id": 3, "type": "preproc_include", "text": "#include \"windowstr.h\"\n", "parent": null, "children": [4, 5], "start_point": {"row": 59, "column": 0}, "end_point": {"row": 60, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 59, "column": 0}, "end_point": {"row": 59, "column": 8}}, {"id": 5, "type": "string_literal", "text": "\"windowstr.h\"", "parent": 3, "children": [], "start_point": {"row": 59, "column": 9}, "end_point": {"row": 59, "column": 22}}, {"id": 6, "type": "preproc_include", "text": "#include \"gcstruct.h\"\n", "parent": null, "children": [7, 8], "start_point": {"row": 60, "column": 0}, "end_point": {"row": 61, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 60, "column": 0}, "end_point": {"row": 60, "column": 8}}, {"id": 8, "type": "string_literal", "text": "\"gcstruct.h\"", "parent": 6, "children": [], "start_point": {"row": 60, "column": 9}, "end_point": {"row": 60, "column": 21}}, {"id": 9, "type": "preproc_include", "text": "#include \"pixmapstr.h\"\n", "parent": null, "children": [10, 11], "start_point": {"row": 61, "column": 0}, "end_point": {"row": 62, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 61, "column": 0}, "end_point": {"row": 61, "column": 8}}, {"id": 11, "type": "string_literal", "text": "\"pixmapstr.h\"", "parent": 9, "children": [], "start_point": {"row": 61, "column": 9}, "end_point": {"row": 61, "column": 22}}, {"id": 12, "type": "preproc_include", "text": "#include \"mi.h\"\n", "parent": null, "children": [13, 14], "start_point": {"row": 62, "column": 0}, "end_point": {"row": 63, "column": 0}}, {"id": 13, "type": "#include", "text": "#include", "parent": 12, "children": [], "start_point": {"row": 62, "column": 0}, "end_point": {"row": 62, "column": 8}}, {"id": 14, "type": "string_literal", "text": "\"mi.h\"", "parent": 12, "children": [], "start_point": {"row": 62, "column": 9}, "end_point": {"row": 62, "column": 15}}, {"id": 15, "type": "preproc_include", "text": "#include \"miscstruct.h\"\n", "parent": null, "children": [16, 17], "start_point": {"row": 63, "column": 0}, "end_point": {"row": 64, "column": 0}}, {"id": 16, "type": "#include", "text": "#include", "parent": 15, "children": [], "start_point": {"row": 63, "column": 0}, "end_point": {"row": 63, "column": 8}}, {"id": 17, "type": "string_literal", "text": "\"miscstruct.h\"", "parent": 15, "children": [], "start_point": {"row": 63, "column": 9}, "end_point": {"row": 63, "column": 23}}, {"id": 18, "type": "function_definition", "text": "void\nmiFillPolygon(dst, pgc, shape, mode, count, pPts)\n DrawablePtr\t\tdst;\n register GCPtr\tpgc;\n int\t\t\tshape, mode;\n register int\tcount;\n DDXPointPtr\t\tpPts;\n{\n int\t\t\ti;\n register int\txorg, yorg;\n register DDXPointPtr ppt;\n\n if (count == 0)\n\treturn;\n\n ppt = pPts;\n if (pgc->miTranslate)\n {\n\txorg = dst->x;\n\tyorg = dst->y;\n\n if (mode == CoordModeOrigin) \n {\n\t for (i = 0; i<count; i++) \n { \n\t ppt->x += xorg;\n\t ppt++->y += yorg;\n\t }\n }\n else \n {\n\t ppt->x += xorg;\n\t ppt++->y += yorg;\n\t for (i = 1; i<count; i++) \n {\n\t ppt->x += (ppt-1)->x;\n\t ppt->y += (ppt-1)->y;\n\t ppt++;\n\t }\n }\n }\n else\n {\n\tif (mode == CoordModePrevious)\n {\n\t ppt++;\n\t for (i = 1; i<count; i++) \n {\n\t ppt->x += (ppt-1)->x;\n\t ppt->y += (ppt-1)->y;\n\t ppt++;\n\t }\n }\n }\n if (shape == Convex)\n\tmiFillConvexPoly(dst, pgc, count, pPts);\n else\n\tmiFillGeneralPoly(dst, pgc, count, pPts);\n}", "parent": null, "children": [19, 20, 29, 32, 37, 41, 46], "start_point": {"row": 66, "column": 0}, "end_point": {"row": 124, "column": 1}}, {"id": 19, "type": "primitive_type", "text": "void", "parent": 18, "children": [], "start_point": {"row": 66, "column": 0}, "end_point": {"row": 66, "column": 4}}, {"id": 20, "type": "function_declarator", "text": "miFillPolygon(dst, pgc, shape, mode, count, pPts)", "parent": 18, "children": [21, 22], "start_point": {"row": 67, "column": 0}, "end_point": {"row": 67, "column": 49}}, {"id": 21, "type": "identifier", "text": "miFillPolygon", "parent": 20, "children": [], "start_point": {"row": 67, "column": 0}, "end_point": {"row": 67, "column": 13}}, {"id": 22, "type": "parameter_list", "text": "(dst, pgc, shape, mode, count, pPts)", "parent": 20, "children": [23, 24, 25, 26, 27, 28], "start_point": {"row": 67, "column": 13}, "end_point": {"row": 67, "column": 49}}, {"id": 23, "type": "identifier", "text": "dst", "parent": 22, "children": [], "start_point": {"row": 67, "column": 14}, "end_point": {"row": 67, "column": 17}}, {"id": 24, "type": "identifier", "text": "pgc", "parent": 22, "children": [], "start_point": {"row": 67, "column": 19}, "end_point": {"row": 67, "column": 22}}, {"id": 25, "type": "identifier", "text": "shape", "parent": 22, "children": [], "start_point": {"row": 67, "column": 24}, "end_point": {"row": 67, "column": 29}}, {"id": 26, "type": "identifier", "text": "mode", "parent": 22, "children": [], "start_point": {"row": 67, "column": 31}, "end_point": {"row": 67, "column": 35}}, {"id": 27, "type": "identifier", "text": "count", "parent": 22, "children": [], "start_point": {"row": 67, "column": 37}, "end_point": {"row": 67, "column": 42}}, {"id": 28, "type": "identifier", "text": "pPts", "parent": 22, "children": [], "start_point": {"row": 67, "column": 44}, "end_point": {"row": 67, "column": 48}}, {"id": 29, "type": "declaration", "text": "DrawablePtr\t\tdst;", "parent": 18, "children": [30, 31], "start_point": {"row": 68, "column": 4}, "end_point": {"row": 68, "column": 21}}, {"id": 30, "type": "type_identifier", "text": "DrawablePtr", "parent": 29, "children": [], "start_point": {"row": 68, "column": 4}, "end_point": {"row": 68, "column": 15}}, {"id": 31, "type": "identifier", "text": "dst", "parent": 29, "children": [], "start_point": {"row": 68, "column": 17}, "end_point": {"row": 68, "column": 20}}, {"id": 32, "type": "declaration", "text": "register GCPtr\tpgc;", "parent": 18, "children": [33, 35, 36], "start_point": {"row": 69, "column": 4}, "end_point": {"row": 69, "column": 23}}, {"id": 33, "type": "storage_class_specifier", "text": "register", "parent": 32, "children": [34], "start_point": {"row": 69, "column": 4}, "end_point": {"row": 69, "column": 12}}, {"id": 34, "type": "register", "text": "register", "parent": 33, "children": [], "start_point": {"row": 69, "column": 4}, "end_point": {"row": 69, "column": 12}}, {"id": 35, "type": "type_identifier", "text": "GCPtr", "parent": 32, "children": [], "start_point": {"row": 69, "column": 13}, "end_point": {"row": 69, "column": 18}}, {"id": 36, "type": "identifier", "text": "pgc", "parent": 32, "children": [], "start_point": {"row": 69, "column": 19}, "end_point": {"row": 69, "column": 22}}, {"id": 37, "type": "declaration", "text": "int\t\t\tshape, mode;", "parent": 18, "children": [38, 39, 40], "start_point": {"row": 70, "column": 4}, "end_point": {"row": 70, "column": 22}}, {"id": 38, "type": "primitive_type", "text": "int", "parent": 37, "children": [], "start_point": {"row": 70, "column": 4}, "end_point": {"row": 70, "column": 7}}, {"id": 39, "type": "identifier", "text": "shape", "parent": 37, "children": [], "start_point": {"row": 70, "column": 10}, "end_point": {"row": 70, "column": 15}}, {"id": 40, "type": "identifier", "text": "mode", "parent": 37, "children": [], "start_point": {"row": 70, "column": 17}, "end_point": {"row": 70, "column": 21}}, {"id": 41, "type": "declaration", "text": "register int\tcount;", "parent": 18, "children": [42, 44, 45], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 23}}, {"id": 42, "type": "storage_class_specifier", "text": "register", "parent": 41, "children": [43], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 12}}, {"id": 43, "type": "register", "text": "register", "parent": 42, "children": [], "start_point": {"row": 71, "column": 4}, "end_point": {"row": 71, "column": 12}}, {"id": 44, "type": "primitive_type", "text": "int", "parent": 41, "children": [], "start_point": {"row": 71, "column": 13}, "end_point": {"row": 71, "column": 16}}, {"id": 45, "type": "identifier", "text": "count", "parent": 41, "children": [], "start_point": {"row": 71, "column": 17}, "end_point": {"row": 71, "column": 22}}, {"id": 46, "type": "declaration", "text": "DDXPointPtr\t\tpPts;", "parent": 18, "children": [47, 48], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 22}}, {"id": 47, "type": "type_identifier", "text": "DDXPointPtr", "parent": 46, "children": [], "start_point": {"row": 72, "column": 4}, "end_point": {"row": 72, "column": 15}}, {"id": 48, "type": "identifier", "text": "pPts", "parent": 46, "children": [], "start_point": {"row": 72, "column": 17}, "end_point": {"row": 72, "column": 21}}, {"id": 49, "type": "declaration", "text": "int\t\t\ti;", "parent": 18, "children": [50, 51], "start_point": {"row": 74, "column": 4}, "end_point": {"row": 74, "column": 12}}, {"id": 50, "type": "primitive_type", "text": "int", "parent": 49, "children": [], "start_point": {"row": 74, "column": 4}, "end_point": {"row": 74, "column": 7}}, {"id": 51, "type": "identifier", "text": "i", "parent": 49, "children": [], "start_point": {"row": 74, "column": 10}, "end_point": {"row": 74, "column": 11}}, {"id": 52, "type": "declaration", "text": "register int\txorg, yorg;", "parent": 18, "children": [53, 55, 56, 57], "start_point": {"row": 75, "column": 4}, "end_point": {"row": 75, "column": 28}}, {"id": 53, "type": "storage_class_specifier", "text": "register", "parent": 52, "children": [54], "start_point": {"row": 75, "column": 4}, "end_point": {"row": 75, "column": 12}}, {"id": 54, "type": "register", "text": "register", "parent": 53, "children": [], "start_point": {"row": 75, "column": 4}, "end_point": {"row": 75, "column": 12}}, {"id": 55, "type": "primitive_type", "text": "int", "parent": 52, "children": [], "start_point": {"row": 75, "column": 13}, "end_point": {"row": 75, "column": 16}}, {"id": 56, "type": "identifier", "text": "xorg", "parent": 52, "children": [], "start_point": {"row": 75, "column": 17}, "end_point": {"row": 75, "column": 21}}, {"id": 57, "type": "identifier", "text": "yorg", "parent": 52, "children": [], "start_point": {"row": 75, "column": 23}, "end_point": {"row": 75, "column": 27}}, {"id": 58, "type": "declaration", "text": "register DDXPointPtr ppt;", "parent": 18, "children": [59, 61, 62], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 29}}, {"id": 59, "type": "storage_class_specifier", "text": "register", "parent": 58, "children": [60], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 12}}, {"id": 60, "type": "register", "text": "register", "parent": 59, "children": [], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 12}}, {"id": 61, "type": "type_identifier", "text": "DDXPointPtr", "parent": 58, "children": [], "start_point": {"row": 76, "column": 13}, "end_point": {"row": 76, "column": 24}}, {"id": 62, "type": "identifier", "text": "ppt", "parent": 58, "children": [], "start_point": {"row": 76, "column": 25}, "end_point": {"row": 76, "column": 28}}, {"id": 63, "type": "if_statement", "text": "if (count == 0)\n\treturn;", "parent": 18, "children": [64, 69], "start_point": {"row": 78, "column": 4}, "end_point": {"row": 79, "column": 8}}, {"id": 64, "type": "parenthesized_expression", "text": "(count == 0)", "parent": 63, "children": [65], "start_point": {"row": 78, "column": 7}, "end_point": {"row": 78, "column": 19}}, {"id": 65, "type": "binary_expression", "text": "count == 0", "parent": 64, "children": [66, 67, 68], "start_point": {"row": 78, "column": 8}, "end_point": {"row": 78, "column": 18}}, {"id": 66, "type": "identifier", "text": "count", "parent": 65, "children": [], "start_point": {"row": 78, "column": 8}, "end_point": {"row": 78, "column": 13}}, {"id": 67, "type": "==", "text": "==", "parent": 65, "children": [], "start_point": {"row": 78, "column": 14}, "end_point": {"row": 78, "column": 16}}, {"id": 68, "type": "number_literal", "text": "0", "parent": 65, "children": [], "start_point": {"row": 78, "column": 17}, "end_point": {"row": 78, "column": 18}}, {"id": 69, "type": "return_statement", "text": "return;", "parent": 63, "children": [], "start_point": {"row": 79, "column": 1}, "end_point": {"row": 79, "column": 8}}, {"id": 70, "type": "assignment_expression", "text": "ppt = pPts", "parent": 18, "children": [71, 72, 73], "start_point": {"row": 81, "column": 4}, "end_point": {"row": 81, "column": 14}}, {"id": 71, "type": "identifier", "text": "ppt", "parent": 70, "children": [], "start_point": {"row": 81, "column": 4}, "end_point": {"row": 81, "column": 7}}, {"id": 72, "type": "=", "text": "=", "parent": 70, "children": [], "start_point": {"row": 81, "column": 8}, "end_point": {"row": 81, "column": 9}}, {"id": 73, "type": "identifier", "text": "pPts", "parent": 70, "children": [], "start_point": {"row": 81, "column": 10}, "end_point": {"row": 81, "column": 14}}, {"id": 74, "type": "if_statement", "text": "if (pgc->miTranslate)\n {\n\txorg = dst->x;\n\tyorg = dst->y;\n\n if (mode == CoordModeOrigin) \n {\n\t for (i = 0; i<count; i++) \n { \n\t ppt->x += xorg;\n\t ppt++->y += yorg;\n\t }\n }\n else \n {\n\t ppt->x += xorg;\n\t ppt++->y += yorg;\n\t for (i = 1; i<count; i++) \n {\n\t ppt->x += (ppt-1)->x;\n\t ppt->y += (ppt-1)->y;\n\t ppt++;\n\t }\n }\n }\n else\n {\n\tif (mode == CoordModePrevious)\n {\n\t ppt++;\n\t for (i = 1; i<count; i++) \n {\n\t ppt->x += (ppt-1)->x;\n\t ppt->y += (ppt-1)->y;\n\t ppt++;\n\t }\n }\n }", "parent": 18, "children": [75, 177], "start_point": {"row": 82, "column": 4}, "end_point": {"row": 119, "column": 5}}, {"id": 75, "type": "parenthesized_expression", "text": "(pgc->miTranslate)", "parent": 74, "children": [76], "start_point": {"row": 82, "column": 7}, "end_point": {"row": 82, "column": 25}}, {"id": 76, "type": "field_expression", "text": "pgc->miTranslate", "parent": 75, "children": [77, 78], "start_point": {"row": 82, "column": 8}, "end_point": {"row": 82, "column": 24}}, {"id": 77, "type": "identifier", "text": "pgc", "parent": 76, "children": [], "start_point": {"row": 82, "column": 8}, "end_point": {"row": 82, "column": 11}}, {"id": 78, "type": "field_identifier", "text": "miTranslate", "parent": 76, "children": [], "start_point": {"row": 82, "column": 13}, "end_point": {"row": 82, "column": 24}}, {"id": 79, "type": "assignment_expression", "text": "xorg = dst->x", "parent": 74, "children": [80, 81, 82], "start_point": {"row": 84, "column": 1}, "end_point": {"row": 84, "column": 14}}, {"id": 80, "type": "identifier", "text": "xorg", "parent": 79, "children": [], "start_point": {"row": 84, "column": 1}, "end_point": {"row": 84, "column": 5}}, {"id": 81, "type": "=", "text": "=", "parent": 79, "children": [], "start_point": {"row": 84, "column": 6}, "end_point": {"row": 84, "column": 7}}, {"id": 82, "type": "field_expression", "text": "dst->x", "parent": 79, "children": [83, 84], "start_point": {"row": 84, "column": 8}, "end_point": {"row": 84, "column": 14}}, {"id": 83, "type": "identifier", "text": "dst", "parent": 82, "children": [], "start_point": {"row": 84, "column": 8}, "end_point": {"row": 84, "column": 11}}, {"id": 84, "type": "field_identifier", "text": "x", "parent": 82, "children": [], "start_point": {"row": 84, "column": 13}, "end_point": {"row": 84, "column": 14}}, {"id": 85, "type": "assignment_expression", "text": "yorg = dst->y", "parent": 74, "children": [86, 87, 88], "start_point": {"row": 85, "column": 1}, "end_point": {"row": 85, "column": 14}}, {"id": 86, "type": "identifier", "text": "yorg", "parent": 85, "children": [], "start_point": {"row": 85, "column": 1}, "end_point": {"row": 85, "column": 5}}, {"id": 87, "type": "=", "text": "=", "parent": 85, "children": [], "start_point": {"row": 85, "column": 6}, "end_point": {"row": 85, "column": 7}}, {"id": 88, "type": "field_expression", "text": "dst->y", "parent": 85, "children": [89, 90], "start_point": {"row": 85, "column": 8}, "end_point": {"row": 85, "column": 14}}, {"id": 89, "type": "identifier", "text": "dst", "parent": 88, "children": [], "start_point": {"row": 85, "column": 8}, "end_point": {"row": 85, "column": 11}}, {"id": 90, "type": "field_identifier", "text": "y", "parent": 88, "children": [], "start_point": {"row": 85, "column": 13}, "end_point": {"row": 85, "column": 14}}, {"id": 91, "type": "if_statement", "text": "if (mode == CoordModeOrigin) \n {\n\t for (i = 0; i<count; i++) \n { \n\t ppt->x += xorg;\n\t ppt++->y += yorg;\n\t }\n }\n else \n {\n\t ppt->x += xorg;\n\t ppt++->y += yorg;\n\t for (i = 1; i<count; i++) \n {\n\t ppt->x += (ppt-1)->x;\n\t ppt->y += (ppt-1)->y;\n\t ppt++;\n\t }\n }", "parent": 74, "children": [92, 123], "start_point": {"row": 87, "column": 8}, "end_point": {"row": 105, "column": 9}}, {"id": 92, "type": "parenthesized_expression", "text": "(mode == CoordModeOrigin)", "parent": 91, "children": [93], "start_point": {"row": 87, "column": 11}, "end_point": {"row": 87, "column": 36}}, {"id": 93, "type": "binary_expression", "text": "mode == CoordModeOrigin", "parent": 92, "children": [94, 95, 96], "start_point": {"row": 87, "column": 12}, "end_point": {"row": 87, "column": 35}}, {"id": 94, "type": "identifier", "text": "mode", "parent": 93, "children": [], "start_point": {"row": 87, "column": 12}, "end_point": {"row": 87, "column": 16}}, {"id": 95, "type": "==", "text": "==", "parent": 93, "children": [], "start_point": {"row": 87, "column": 17}, "end_point": {"row": 87, "column": 19}}, {"id": 96, "type": "identifier", "text": "CoordModeOrigin", "parent": 93, "children": [], "start_point": {"row": 87, "column": 20}, "end_point": {"row": 87, "column": 35}}, {"id": 97, "type": "for_statement", "text": "for (i = 0; i<count; i++) \n { \n\t ppt->x += xorg;\n\t ppt++->y += yorg;\n\t }", "parent": 91, "children": [98, 102, 106], "start_point": {"row": 89, "column": 9}, "end_point": {"row": 93, "column": 10}}, {"id": 98, "type": "assignment_expression", "text": "i = 0", "parent": 97, "children": [99, 100, 101], "start_point": {"row": 89, "column": 14}, "end_point": {"row": 89, "column": 19}}, {"id": 99, "type": "identifier", "text": "i", "parent": 98, "children": [], "start_point": {"row": 89, "column": 14}, "end_point": {"row": 89, "column": 15}}, {"id": 100, "type": "=", "text": "=", "parent": 98, "children": [], "start_point": {"row": 89, "column": 16}, "end_point": {"row": 89, "column": 17}}, {"id": 101, "type": "number_literal", "text": "0", "parent": 98, "children": [], "start_point": {"row": 89, "column": 18}, "end_point": {"row": 89, "column": 19}}, {"id": 102, "type": "binary_expression", "text": "i<count", "parent": 97, "children": [103, 104, 105], "start_point": {"row": 89, "column": 21}, "end_point": {"row": 89, "column": 28}}, {"id": 103, "type": "identifier", "text": "i", "parent": 102, "children": [], "start_point": {"row": 89, "column": 21}, "end_point": {"row": 89, "column": 22}}, {"id": 104, "type": "<", "text": "<", "parent": 102, "children": [], "start_point": {"row": 89, "column": 22}, "end_point": {"row": 89, "column": 23}}, {"id": 105, "type": "identifier", "text": "count", "parent": 102, "children": [], "start_point": {"row": 89, "column": 23}, "end_point": {"row": 89, "column": 28}}, {"id": 106, "type": "update_expression", "text": "i++", "parent": 97, "children": [107, 108], "start_point": {"row": 89, "column": 30}, "end_point": {"row": 89, "column": 33}}, {"id": 107, "type": "identifier", "text": "i", "parent": 106, "children": [], "start_point": {"row": 89, "column": 30}, "end_point": {"row": 89, "column": 31}}, {"id": 108, "type": "++", "text": "++", "parent": 106, "children": [], "start_point": {"row": 89, "column": 31}, "end_point": {"row": 89, "column": 33}}, {"id": 109, "type": "assignment_expression", "text": "ppt->x += xorg", "parent": 97, "children": [110, 113, 114], "start_point": {"row": 91, "column": 13}, "end_point": {"row": 91, "column": 27}}, {"id": 110, "type": "field_expression", "text": "ppt->x", "parent": 109, "children": [111, 112], "start_point": {"row": 91, "column": 13}, "end_point": {"row": 91, "column": 19}}, {"id": 111, "type": "identifier", "text": "ppt", "parent": 110, "children": [], "start_point": {"row": 91, "column": 13}, "end_point": {"row": 91, "column": 16}}, {"id": 112, "type": "field_identifier", "text": "x", "parent": 110, "children": [], "start_point": {"row": 91, "column": 18}, "end_point": {"row": 91, "column": 19}}, {"id": 113, "type": "+=", "text": "+=", "parent": 109, "children": [], "start_point": {"row": 91, "column": 20}, "end_point": {"row": 91, "column": 22}}, {"id": 114, "type": "identifier", "text": "xorg", "parent": 109, "children": [], "start_point": {"row": 91, "column": 23}, "end_point": {"row": 91, "column": 27}}, {"id": 115, "type": "assignment_expression", "text": "ppt++->y += yorg", "parent": 97, "children": [116, 121, 122], "start_point": {"row": 92, "column": 13}, "end_point": {"row": 92, "column": 29}}, {"id": 116, "type": "field_expression", "text": "ppt++->y", "parent": 115, "children": [117, 120], "start_point": {"row": 92, "column": 13}, "end_point": {"row": 92, "column": 21}}, {"id": 117, "type": "update_expression", "text": "ppt++", "parent": 116, "children": [118, 119], "start_point": {"row": 92, "column": 13}, "end_point": {"row": 92, "column": 18}}, {"id": 118, "type": "identifier", "text": "ppt", "parent": 117, "children": [], "start_point": {"row": 92, "column": 13}, "end_point": {"row": 92, "column": 16}}, {"id": 119, "type": "++", "text": "++", "parent": 117, "children": [], "start_point": {"row": 92, "column": 16}, "end_point": {"row": 92, "column": 18}}, {"id": 120, "type": "field_identifier", "text": "y", "parent": 116, "children": [], "start_point": {"row": 92, "column": 20}, "end_point": {"row": 92, "column": 21}}, {"id": 121, "type": "+=", "text": "+=", "parent": 115, "children": [], "start_point": {"row": 92, "column": 22}, "end_point": {"row": 92, "column": 24}}, {"id": 122, "type": "identifier", "text": "yorg", "parent": 115, "children": [], "start_point": {"row": 92, "column": 25}, "end_point": {"row": 92, "column": 29}}, {"id": 123, "type": "else_clause", "text": "else \n {\n\t ppt->x += xorg;\n\t ppt++->y += yorg;\n\t for (i = 1; i<count; i++) \n {\n\t ppt->x += (ppt-1)->x;\n\t ppt->y += (ppt-1)->y;\n\t ppt++;\n\t }\n }", "parent": 91, "children": [], "start_point": {"row": 95, "column": 8}, "end_point": {"row": 105, "column": 9}}, {"id": 124, "type": "assignment_expression", "text": "ppt->x += xorg", "parent": 123, "children": [125, 128, 129], "start_point": {"row": 97, "column": 5}, "end_point": {"row": 97, "column": 19}}, {"id": 125, "type": "field_expression", "text": "ppt->x", "parent": 124, "children": [126, 127], "start_point": {"row": 97, "column": 5}, "end_point": {"row": 97, "column": 11}}, {"id": 126, "type": "identifier", "text": "ppt", "parent": 125, "children": [], "start_point": {"row": 97, "column": 5}, "end_point": {"row": 97, "column": 8}}, {"id": 127, "type": "field_identifier", "text": "x", "parent": 125, "children": [], "start_point": {"row": 97, "column": 10}, "end_point": {"row": 97, "column": 11}}, {"id": 128, "type": "+=", "text": "+=", "parent": 124, "children": [], "start_point": {"row": 97, "column": 12}, "end_point": {"row": 97, "column": 14}}, {"id": 129, "type": "identifier", "text": "xorg", "parent": 124, "children": [], "start_point": {"row": 97, "column": 15}, "end_point": {"row": 97, "column": 19}}, {"id": 130, "type": "assignment_expression", "text": "ppt++->y += yorg", "parent": 123, "children": [131, 136, 137], "start_point": {"row": 98, "column": 5}, "end_point": {"row": 98, "column": 21}}, {"id": 131, "type": "field_expression", "text": "ppt++->y", "parent": 130, "children": [132, 135], "start_point": {"row": 98, "column": 5}, "end_point": {"row": 98, "column": 13}}, {"id": 132, "type": "update_expression", "text": "ppt++", "parent": 131, "children": [133, 134], "start_point": {"row": 98, "column": 5}, "end_point": {"row": 98, "column": 10}}, {"id": 133, "type": "identifier", "text": "ppt", "parent": 132, "children": [], "start_point": {"row": 98, "column": 5}, "end_point": {"row": 98, "column": 8}}, {"id": 134, "type": "++", "text": "++", "parent": 132, "children": [], "start_point": {"row": 98, "column": 8}, "end_point": {"row": 98, "column": 10}}, {"id": 135, "type": "field_identifier", "text": "y", "parent": 131, "children": [], "start_point": {"row": 98, "column": 12}, "end_point": {"row": 98, "column": 13}}, {"id": 136, "type": "+=", "text": "+=", "parent": 130, "children": [], "start_point": {"row": 98, "column": 14}, "end_point": {"row": 98, "column": 16}}, {"id": 137, "type": "identifier", "text": "yorg", "parent": 130, "children": [], "start_point": {"row": 98, "column": 17}, "end_point": {"row": 98, "column": 21}}, {"id": 138, "type": "for_statement", "text": "for (i = 1; i<count; i++) \n {\n\t ppt->x += (ppt-1)->x;\n\t ppt->y += (ppt-1)->y;\n\t ppt++;\n\t }", "parent": 123, "children": [139, 143, 147], "start_point": {"row": 99, "column": 5}, "end_point": {"row": 104, "column": 6}}, {"id": 139, "type": "assignment_expression", "text": "i = 1", "parent": 138, "children": [140, 141, 142], "start_point": {"row": 99, "column": 10}, "end_point": {"row": 99, "column": 15}}, {"id": 140, "type": "identifier", "text": "i", "parent": 139, "children": [], "start_point": {"row": 99, "column": 10}, "end_point": {"row": 99, "column": 11}}, {"id": 141, "type": "=", "text": "=", "parent": 139, "children": [], "start_point": {"row": 99, "column": 12}, "end_point": {"row": 99, "column": 13}}, {"id": 142, "type": "number_literal", "text": "1", "parent": 139, "children": [], "start_point": {"row": 99, "column": 14}, "end_point": {"row": 99, "column": 15}}, {"id": 143, "type": "binary_expression", "text": "i<count", "parent": 138, "children": [144, 145, 146], "start_point": {"row": 99, "column": 17}, "end_point": {"row": 99, "column": 24}}, {"id": 144, "type": "identifier", "text": "i", "parent": 143, "children": [], "start_point": {"row": 99, "column": 17}, "end_point": {"row": 99, "column": 18}}, {"id": 145, "type": "<", "text": "<", "parent": 143, "children": [], "start_point": {"row": 99, "column": 18}, "end_point": {"row": 99, "column": 19}}, {"id": 146, "type": "identifier", "text": "count", "parent": 143, "children": [], "start_point": {"row": 99, "column": 19}, "end_point": {"row": 99, "column": 24}}, {"id": 147, "type": "update_expression", "text": "i++", "parent": 138, "children": [148, 149], "start_point": {"row": 99, "column": 26}, "end_point": {"row": 99, "column": 29}}, {"id": 148, "type": "identifier", "text": "i", "parent": 147, "children": [], "start_point": {"row": 99, "column": 26}, "end_point": {"row": 99, "column": 27}}, {"id": 149, "type": "++", "text": "++", "parent": 147, "children": [], "start_point": {"row": 99, "column": 27}, "end_point": {"row": 99, "column": 29}}, {"id": 150, "type": "assignment_expression", "text": "ppt->x += (ppt-1)->x", "parent": 138, "children": [151, 154, 155], "start_point": {"row": 101, "column": 9}, "end_point": {"row": 101, "column": 29}}, {"id": 151, "type": "field_expression", "text": "ppt->x", "parent": 150, "children": [152, 153], "start_point": {"row": 101, "column": 9}, "end_point": {"row": 101, "column": 15}}, {"id": 152, "type": "identifier", "text": "ppt", "parent": 151, "children": [], "start_point": {"row": 101, "column": 9}, "end_point": {"row": 101, "column": 12}}, {"id": 153, "type": "field_identifier", "text": "x", "parent": 151, "children": [], "start_point": {"row": 101, "column": 14}, "end_point": {"row": 101, "column": 15}}, {"id": 154, "type": "+=", "text": "+=", "parent": 150, "children": [], "start_point": {"row": 101, "column": 16}, "end_point": {"row": 101, "column": 18}}, {"id": 155, "type": "field_expression", "text": "(ppt-1)->x", "parent": 150, "children": [156, 161], "start_point": {"row": 101, "column": 19}, "end_point": {"row": 101, "column": 29}}, {"id": 156, "type": "parenthesized_expression", "text": "(ppt-1)", "parent": 155, "children": [157], "start_point": {"row": 101, "column": 19}, "end_point": {"row": 101, "column": 26}}, {"id": 157, "type": "binary_expression", "text": "ppt-1", "parent": 156, "children": [158, 159, 160], "start_point": {"row": 101, "column": 20}, "end_point": {"row": 101, "column": 25}}, {"id": 158, "type": "identifier", "text": "ppt", "parent": 157, "children": [], "start_point": {"row": 101, "column": 20}, "end_point": {"row": 101, "column": 23}}, {"id": 159, "type": "-", "text": "-", "parent": 157, "children": [], "start_point": {"row": 101, "column": 23}, "end_point": {"row": 101, "column": 24}}, {"id": 160, "type": "number_literal", "text": "1", "parent": 157, "children": [], "start_point": {"row": 101, "column": 24}, "end_point": {"row": 101, "column": 25}}, {"id": 161, "type": "field_identifier", "text": "x", "parent": 155, "children": [], "start_point": {"row": 101, "column": 28}, "end_point": {"row": 101, "column": 29}}, {"id": 162, "type": "assignment_expression", "text": "ppt->y += (ppt-1)->y", "parent": 138, "children": [163, 166, 167], "start_point": {"row": 102, "column": 9}, "end_point": {"row": 102, "column": 29}}, {"id": 163, "type": "field_expression", "text": "ppt->y", "parent": 162, "children": [164, 165], "start_point": {"row": 102, "column": 9}, "end_point": {"row": 102, "column": 15}}, {"id": 164, "type": "identifier", "text": "ppt", "parent": 163, "children": [], "start_point": {"row": 102, "column": 9}, "end_point": {"row": 102, "column": 12}}, {"id": 165, "type": "field_identifier", "text": "y", "parent": 163, "children": [], "start_point": {"row": 102, "column": 14}, "end_point": {"row": 102, "column": 15}}, {"id": 166, "type": "+=", "text": "+=", "parent": 162, "children": [], "start_point": {"row": 102, "column": 16}, "end_point": {"row": 102, "column": 18}}, {"id": 167, "type": "field_expression", "text": "(ppt-1)->y", "parent": 162, "children": [168, 173], "start_point": {"row": 102, "column": 19}, "end_point": {"row": 102, "column": 29}}, {"id": 168, "type": "parenthesized_expression", "text": "(ppt-1)", "parent": 167, "children": [169], "start_point": {"row": 102, "column": 19}, "end_point": {"row": 102, "column": 26}}, {"id": 169, "type": "binary_expression", "text": "ppt-1", "parent": 168, "children": [170, 171, 172], "start_point": {"row": 102, "column": 20}, "end_point": {"row": 102, "column": 25}}, {"id": 170, "type": "identifier", "text": "ppt", "parent": 169, "children": [], "start_point": {"row": 102, "column": 20}, "end_point": {"row": 102, "column": 23}}, {"id": 171, "type": "-", "text": "-", "parent": 169, "children": [], "start_point": {"row": 102, "column": 23}, "end_point": {"row": 102, "column": 24}}, {"id": 172, "type": "number_literal", "text": "1", "parent": 169, "children": [], "start_point": {"row": 102, "column": 24}, "end_point": {"row": 102, "column": 25}}, {"id": 173, "type": "field_identifier", "text": "y", "parent": 167, "children": [], "start_point": {"row": 102, "column": 28}, "end_point": {"row": 102, "column": 29}}, {"id": 174, "type": "update_expression", "text": "ppt++", "parent": 138, "children": [175, 176], "start_point": {"row": 103, "column": 9}, "end_point": {"row": 103, "column": 14}}, {"id": 175, "type": "identifier", "text": "ppt", "parent": 174, "children": [], "start_point": {"row": 103, "column": 9}, "end_point": {"row": 103, "column": 12}}, {"id": 176, "type": "++", "text": "++", "parent": 174, "children": [], "start_point": {"row": 103, "column": 12}, "end_point": {"row": 103, "column": 14}}, {"id": 177, "type": "else_clause", "text": "else\n {\n\tif (mode == CoordModePrevious)\n {\n\t ppt++;\n\t for (i = 1; i<count; i++) \n {\n\t ppt->x += (ppt-1)->x;\n\t ppt->y += (ppt-1)->y;\n\t ppt++;\n\t }\n }\n }", "parent": 74, "children": [], "start_point": {"row": 107, "column": 4}, "end_point": {"row": 119, "column": 5}}, {"id": 178, "type": "if_statement", "text": "if (mode == CoordModePrevious)\n {\n\t ppt++;\n\t for (i = 1; i<count; i++) \n {\n\t ppt->x += (ppt-1)->x;\n\t ppt->y += (ppt-1)->y;\n\t ppt++;\n\t }\n }", "parent": 177, "children": [179], "start_point": {"row": 109, "column": 1}, "end_point": {"row": 118, "column": 9}}, {"id": 179, "type": "parenthesized_expression", "text": "(mode == CoordModePrevious)", "parent": 178, "children": [180], "start_point": {"row": 109, "column": 4}, "end_point": {"row": 109, "column": 31}}, {"id": 180, "type": "binary_expression", "text": "mode == CoordModePrevious", "parent": 179, "children": [181, 182, 183], "start_point": {"row": 109, "column": 5}, "end_point": {"row": 109, "column": 30}}, {"id": 181, "type": "identifier", "text": "mode", "parent": 180, "children": [], "start_point": {"row": 109, "column": 5}, "end_point": {"row": 109, "column": 9}}, {"id": 182, "type": "==", "text": "==", "parent": 180, "children": [], "start_point": {"row": 109, "column": 10}, "end_point": {"row": 109, "column": 12}}, {"id": 183, "type": "identifier", "text": "CoordModePrevious", "parent": 180, "children": [], "start_point": {"row": 109, "column": 13}, "end_point": {"row": 109, "column": 30}}, {"id": 184, "type": "update_expression", "text": "ppt++", "parent": 178, "children": [185, 186], "start_point": {"row": 111, "column": 5}, "end_point": {"row": 111, "column": 10}}, {"id": 185, "type": "identifier", "text": "ppt", "parent": 184, "children": [], "start_point": {"row": 111, "column": 5}, "end_point": {"row": 111, "column": 8}}, {"id": 186, "type": "++", "text": "++", "parent": 184, "children": [], "start_point": {"row": 111, "column": 8}, "end_point": {"row": 111, "column": 10}}, {"id": 187, "type": "for_statement", "text": "for (i = 1; i<count; i++) \n {\n\t ppt->x += (ppt-1)->x;\n\t ppt->y += (ppt-1)->y;\n\t ppt++;\n\t }", "parent": 178, "children": [188, 192, 196], "start_point": {"row": 112, "column": 5}, "end_point": {"row": 117, "column": 6}}, {"id": 188, "type": "assignment_expression", "text": "i = 1", "parent": 187, "children": [189, 190, 191], "start_point": {"row": 112, "column": 10}, "end_point": {"row": 112, "column": 15}}, {"id": 189, "type": "identifier", "text": "i", "parent": 188, "children": [], "start_point": {"row": 112, "column": 10}, "end_point": {"row": 112, "column": 11}}, {"id": 190, "type": "=", "text": "=", "parent": 188, "children": [], "start_point": {"row": 112, "column": 12}, "end_point": {"row": 112, "column": 13}}, {"id": 191, "type": "number_literal", "text": "1", "parent": 188, "children": [], "start_point": {"row": 112, "column": 14}, "end_point": {"row": 112, "column": 15}}, {"id": 192, "type": "binary_expression", "text": "i<count", "parent": 187, "children": [193, 194, 195], "start_point": {"row": 112, "column": 17}, "end_point": {"row": 112, "column": 24}}, {"id": 193, "type": "identifier", "text": "i", "parent": 192, "children": [], "start_point": {"row": 112, "column": 17}, "end_point": {"row": 112, "column": 18}}, {"id": 194, "type": "<", "text": "<", "parent": 192, "children": [], "start_point": {"row": 112, "column": 18}, "end_point": {"row": 112, "column": 19}}, {"id": 195, "type": "identifier", "text": "count", "parent": 192, "children": [], "start_point": {"row": 112, "column": 19}, "end_point": {"row": 112, "column": 24}}, {"id": 196, "type": "update_expression", "text": "i++", "parent": 187, "children": [197, 198], "start_point": {"row": 112, "column": 26}, "end_point": {"row": 112, "column": 29}}, {"id": 197, "type": "identifier", "text": "i", "parent": 196, "children": [], "start_point": {"row": 112, "column": 26}, "end_point": {"row": 112, "column": 27}}, {"id": 198, "type": "++", "text": "++", "parent": 196, "children": [], "start_point": {"row": 112, "column": 27}, "end_point": {"row": 112, "column": 29}}, {"id": 199, "type": "assignment_expression", "text": "ppt->x += (ppt-1)->x", "parent": 187, "children": [200, 203, 204], "start_point": {"row": 114, "column": 9}, "end_point": {"row": 114, "column": 29}}, {"id": 200, "type": "field_expression", "text": "ppt->x", "parent": 199, "children": [201, 202], "start_point": {"row": 114, "column": 9}, "end_point": {"row": 114, "column": 15}}, {"id": 201, "type": "identifier", "text": "ppt", "parent": 200, "children": [], "start_point": {"row": 114, "column": 9}, "end_point": {"row": 114, "column": 12}}, {"id": 202, "type": "field_identifier", "text": "x", "parent": 200, "children": [], "start_point": {"row": 114, "column": 14}, "end_point": {"row": 114, "column": 15}}, {"id": 203, "type": "+=", "text": "+=", "parent": 199, "children": [], "start_point": {"row": 114, "column": 16}, "end_point": {"row": 114, "column": 18}}, {"id": 204, "type": "field_expression", "text": "(ppt-1)->x", "parent": 199, "children": [205, 210], "start_point": {"row": 114, "column": 19}, "end_point": {"row": 114, "column": 29}}, {"id": 205, "type": "parenthesized_expression", "text": "(ppt-1)", "parent": 204, "children": [206], "start_point": {"row": 114, "column": 19}, "end_point": {"row": 114, "column": 26}}, {"id": 206, "type": "binary_expression", "text": "ppt-1", "parent": 205, "children": [207, 208, 209], "start_point": {"row": 114, "column": 20}, "end_point": {"row": 114, "column": 25}}, {"id": 207, "type": "identifier", "text": "ppt", "parent": 206, "children": [], "start_point": {"row": 114, "column": 20}, "end_point": {"row": 114, "column": 23}}, {"id": 208, "type": "-", "text": "-", "parent": 206, "children": [], "start_point": {"row": 114, "column": 23}, "end_point": {"row": 114, "column": 24}}, {"id": 209, "type": "number_literal", "text": "1", "parent": 206, "children": [], "start_point": {"row": 114, "column": 24}, "end_point": {"row": 114, "column": 25}}, {"id": 210, "type": "field_identifier", "text": "x", "parent": 204, "children": [], "start_point": {"row": 114, "column": 28}, "end_point": {"row": 114, "column": 29}}, {"id": 211, "type": "assignment_expression", "text": "ppt->y += (ppt-1)->y", "parent": 187, "children": [212, 215, 216], "start_point": {"row": 115, "column": 9}, "end_point": {"row": 115, "column": 29}}, {"id": 212, "type": "field_expression", "text": "ppt->y", "parent": 211, "children": [213, 214], "start_point": {"row": 115, "column": 9}, "end_point": {"row": 115, "column": 15}}, {"id": 213, "type": "identifier", "text": "ppt", "parent": 212, "children": [], "start_point": {"row": 115, "column": 9}, "end_point": {"row": 115, "column": 12}}, {"id": 214, "type": "field_identifier", "text": "y", "parent": 212, "children": [], "start_point": {"row": 115, "column": 14}, "end_point": {"row": 115, "column": 15}}, {"id": 215, "type": "+=", "text": "+=", "parent": 211, "children": [], "start_point": {"row": 115, "column": 16}, "end_point": {"row": 115, "column": 18}}, {"id": 216, "type": "field_expression", "text": "(ppt-1)->y", "parent": 211, "children": [217, 222], "start_point": {"row": 115, "column": 19}, "end_point": {"row": 115, "column": 29}}, {"id": 217, "type": "parenthesized_expression", "text": "(ppt-1)", "parent": 216, "children": [218], "start_point": {"row": 115, "column": 19}, "end_point": {"row": 115, "column": 26}}, {"id": 218, "type": "binary_expression", "text": "ppt-1", "parent": 217, "children": [219, 220, 221], "start_point": {"row": 115, "column": 20}, "end_point": {"row": 115, "column": 25}}, {"id": 219, "type": "identifier", "text": "ppt", "parent": 218, "children": [], "start_point": {"row": 115, "column": 20}, "end_point": {"row": 115, "column": 23}}, {"id": 220, "type": "-", "text": "-", "parent": 218, "children": [], "start_point": {"row": 115, "column": 23}, "end_point": {"row": 115, "column": 24}}, {"id": 221, "type": "number_literal", "text": "1", "parent": 218, "children": [], "start_point": {"row": 115, "column": 24}, "end_point": {"row": 115, "column": 25}}, {"id": 222, "type": "field_identifier", "text": "y", "parent": 216, "children": [], "start_point": {"row": 115, "column": 28}, "end_point": {"row": 115, "column": 29}}, {"id": 223, "type": "update_expression", "text": "ppt++", "parent": 187, "children": [224, 225], "start_point": {"row": 116, "column": 9}, "end_point": {"row": 116, "column": 14}}, {"id": 224, "type": "identifier", "text": "ppt", "parent": 223, "children": [], "start_point": {"row": 116, "column": 9}, "end_point": {"row": 116, "column": 12}}, {"id": 225, "type": "++", "text": "++", "parent": 223, "children": [], "start_point": {"row": 116, "column": 12}, "end_point": {"row": 116, "column": 14}}, {"id": 226, "type": "if_statement", "text": "if (shape == Convex)\n\tmiFillConvexPoly(dst, pgc, count, pPts);\n else\n\tmiFillGeneralPoly(dst, pgc, count, pPts);", "parent": 18, "children": [227, 239], "start_point": {"row": 120, "column": 4}, "end_point": {"row": 123, "column": 42}}, {"id": 227, "type": "parenthesized_expression", "text": "(shape == Convex)", "parent": 226, "children": [228], "start_point": {"row": 120, "column": 7}, "end_point": {"row": 120, "column": 24}}, {"id": 228, "type": "binary_expression", "text": "shape == Convex", "parent": 227, "children": [229, 230, 231], "start_point": {"row": 120, "column": 8}, "end_point": {"row": 120, "column": 23}}, {"id": 229, "type": "identifier", "text": "shape", "parent": 228, "children": [], "start_point": {"row": 120, "column": 8}, "end_point": {"row": 120, "column": 13}}, {"id": 230, "type": "==", "text": "==", "parent": 228, "children": [], "start_point": {"row": 120, "column": 14}, "end_point": {"row": 120, "column": 16}}, {"id": 231, "type": "identifier", "text": "Convex", "parent": 228, "children": [], "start_point": {"row": 120, "column": 17}, "end_point": {"row": 120, "column": 23}}, {"id": 232, "type": "call_expression", "text": "miFillConvexPoly(dst, pgc, count, pPts)", "parent": 226, "children": [233, 234], "start_point": {"row": 121, "column": 1}, "end_point": {"row": 121, "column": 40}}, {"id": 233, "type": "identifier", "text": "miFillConvexPoly", "parent": 232, "children": [], "start_point": {"row": 121, "column": 1}, "end_point": {"row": 121, "column": 17}}, {"id": 234, "type": "argument_list", "text": "(dst, pgc, count, pPts)", "parent": 232, "children": [235, 236, 237, 238], "start_point": {"row": 121, "column": 17}, "end_point": {"row": 121, "column": 40}}, {"id": 235, "type": "identifier", "text": "dst", "parent": 234, "children": [], "start_point": {"row": 121, "column": 18}, "end_point": {"row": 121, "column": 21}}, {"id": 236, "type": "identifier", "text": "pgc", "parent": 234, "children": [], "start_point": {"row": 121, "column": 23}, "end_point": {"row": 121, "column": 26}}, {"id": 237, "type": "identifier", "text": "count", "parent": 234, "children": [], "start_point": {"row": 121, "column": 28}, "end_point": {"row": 121, "column": 33}}, {"id": 238, "type": "identifier", "text": "pPts", "parent": 234, "children": [], "start_point": {"row": 121, "column": 35}, "end_point": {"row": 121, "column": 39}}, {"id": 239, "type": "else_clause", "text": "else\n\tmiFillGeneralPoly(dst, pgc, count, pPts);", "parent": 226, "children": [], "start_point": {"row": 122, "column": 4}, "end_point": {"row": 123, "column": 42}}, {"id": 240, "type": "call_expression", "text": "miFillGeneralPoly(dst, pgc, count, pPts)", "parent": 239, "children": [241, 242], "start_point": {"row": 123, "column": 1}, "end_point": {"row": 123, "column": 41}}, {"id": 241, "type": "identifier", "text": "miFillGeneralPoly", "parent": 240, "children": [], "start_point": {"row": 123, "column": 1}, "end_point": {"row": 123, "column": 18}}, {"id": 242, "type": "argument_list", "text": "(dst, pgc, count, pPts)", "parent": 240, "children": [243, 244, 245, 246], "start_point": {"row": 123, "column": 18}, "end_point": {"row": 123, "column": 41}}, {"id": 243, "type": "identifier", "text": "dst", "parent": 242, "children": [], "start_point": {"row": 123, "column": 19}, "end_point": {"row": 123, "column": 22}}, {"id": 244, "type": "identifier", "text": "pgc", "parent": 242, "children": [], "start_point": {"row": 123, "column": 24}, "end_point": {"row": 123, "column": 27}}, {"id": 245, "type": "identifier", "text": "count", "parent": 242, "children": [], "start_point": {"row": 123, "column": 29}, "end_point": {"row": 123, "column": 34}}, {"id": 246, "type": "identifier", "text": "pPts", "parent": 242, "children": [], "start_point": {"row": 123, "column": 36}, "end_point": {"row": 123, "column": 40}}]}, "node_categories": {"declarations": {"functions": [18, 20], "variables": [29, 32, 37, 41, 46, 49, 52, 58], "classes": [33, 42, 53, 59], "imports": [0, 1, 3, 4, 6, 7, 9, 10, 12, 13, 15, 16], "modules": [], "enums": []}, "statements": {"expressions": [64, 65, 75, 76, 82, 88, 92, 93, 102, 106, 110, 116, 117, 125, 131, 132, 143, 147, 151, 155, 156, 157, 163, 167, 168, 169, 174, 179, 180, 184, 192, 196, 200, 204, 205, 206, 212, 216, 217, 218, 223, 227, 228, 232, 240], "assignments": [70, 79, 85, 98, 109, 115, 124, 130, 139, 150, 162, 188, 199, 211], "loops": [97, 138, 187], "conditionals": [21, 23, 24, 25, 26, 27, 28, 30, 31, 35, 36, 39, 40, 45, 47, 48, 51, 56, 57, 61, 62, 63, 66, 71, 73, 74, 77, 78, 80, 83, 84, 86, 89, 90, 91, 94, 96, 99, 103, 105, 107, 111, 112, 114, 118, 120, 122, 126, 127, 129, 133, 135, 137, 140, 144, 146, 148, 152, 153, 158, 161, 164, 165, 170, 173, 175, 178, 181, 183, 185, 189, 193, 195, 197, 201, 202, 207, 210, 213, 214, 219, 222, 224, 226, 229, 231, 233, 235, 236, 237, 238, 241, 243, 244, 245, 246], "returns": [69], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 8, 11, 14, 17, 68, 101, 142, 160, 172, 191, 209, 221], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 18, "universal_type": "function", "name": "miFillPolygon", "text_snippet": "void\nmiFillPolygon(dst, pgc, shape, mode, count, pPts)\n DrawablePtr\t\tdst;\n register GCPtr\tpgc;"}, {"node_id": 20, "universal_type": "function", "name": "unknown", "text_snippet": "miFillPolygon(dst, pgc, shape, mode, count, pPts)"}], "class_declarations": [{"node_id": 33, "universal_type": "class", "name": "unknown", "text_snippet": "register"}, {"node_id": 42, "universal_type": "class", "name": "unknown", "text_snippet": "register"}, {"node_id": 53, "universal_type": "class", "name": "unknown", "text_snippet": "register"}, {"node_id": 59, "universal_type": "class", "name": "unknown", "text_snippet": "register"}], "import_statements": [{"node_id": 0, "text": "#include \"X.h\"\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include \"windowstr.h\"\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include \"gcstruct.h\"\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include \"pixmapstr.h\"\n"}, {"node_id": 10, "text": "#include"}, {"node_id": 12, "text": "#include \"mi.h\"\n"}, {"node_id": 13, "text": "#include"}, {"node_id": 15, "text": "#include \"miscstruct.h\"\n"}, {"node_id": 16, "text": "#include"}]}, "original_source_code": "/***********************************************************\n\nCopyright (c) 1987 X Consortium\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in\nall copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nX CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN\nAN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\nCONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n\nExcept as contained in this notice, the name of the X Consortium shall not be\nused in advertising or otherwise to promote the sale, use or other dealings\nin this Software without prior written authorization from the X Consortium.\n\n\nCopyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts.\n\n All Rights Reserved\n\nPermission to use, copy, modify, and distribute this software and its \ndocumentation for any purpose and without fee is hereby granted, \nprovided that the above copyright notice appear in all copies and that\nboth that copyright notice and this permission notice appear in \nsupporting documentation, and that the name of Digital not be\nused in advertising or publicity pertaining to distribution of the\nsoftware without specific, written prior permission. \n\nDIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING\nALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL\nDIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR\nANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,\nWHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,\nARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS\nSOFTWARE.\n\n******************************************************************/\n/* $XConsortium: mipoly.c,v 5.1 94/04/17 20:27:41 keith Exp $ */\n/*\n * mipoly.c\n *\n * Written by <NAME>; June 1986\n *\n * Draw polygons. This routine translates the point by the\n * origin if pGC->miTranslate is non-zero, and calls\n * to the appropriate routine to actually scan convert the\n * polygon.\n */\n#include \"X.h\"\n#include \"windowstr.h\"\n#include \"gcstruct.h\"\n#include \"pixmapstr.h\"\n#include \"mi.h\"\n#include \"miscstruct.h\"\n\n\nvoid\nmiFillPolygon(dst, pgc, shape, mode, count, pPts)\n DrawablePtr\t\tdst;\n register GCPtr\tpgc;\n int\t\t\tshape, mode;\n register int\tcount;\n DDXPointPtr\t\tpPts;\n{\n int\t\t\ti;\n register int\txorg, yorg;\n register DDXPointPtr ppt;\n\n if (count == 0)\n\treturn;\n\n ppt = pPts;\n if (pgc->miTranslate)\n {\n\txorg = dst->x;\n\tyorg = dst->y;\n\n if (mode == CoordModeOrigin) \n {\n\t for (i = 0; i<count; i++) \n { \n\t ppt->x += xorg;\n\t ppt++->y += yorg;\n\t }\n }\n else \n {\n\t ppt->x += xorg;\n\t ppt++->y += yorg;\n\t for (i = 1; i<count; i++) \n {\n\t ppt->x += (ppt-1)->x;\n\t ppt->y += (ppt-1)->y;\n\t ppt++;\n\t }\n }\n }\n else\n {\n\tif (mode == CoordModePrevious)\n {\n\t ppt++;\n\t for (i = 1; i<count; i++) \n {\n\t ppt->x += (ppt-1)->x;\n\t ppt->y += (ppt-1)->y;\n\t ppt++;\n\t }\n }\n }\n if (shape == Convex)\n\tmiFillConvexPoly(dst, pgc, count, pPts);\n else\n\tmiFillGeneralPoly(dst, pgc, count, pPts);\n}\n"}
80,598
c
/* * cidr_get - Get and return various semi-raw bits of info */ #include <errno.h> #include <stdlib.h> #include <string.h> #include <libcidr.h> /* Get the prefix length */ int cidr_get_pflen(const CIDR *block) { int i, j; int foundnmh; int pflen; if(block==NULL) { errno = EFAULT; return(-1); } /* Where do we start? */ if(block->proto==CIDR_IPV4) i=12; else if(block->proto==CIDR_IPV6) i=0; else { errno = ENOENT; /* Bad errno */ return(-1); /* Unknown */ } /* * We're intentionally not supporting non-contiguous netmasks. So, * if we find one, bomb out. */ foundnmh=0; pflen=0; for(/* i */ ; i<=15 ; i++) { for(j=7 ; j>=0 ; j--) { if((block->mask)[i] & (1<<j)) { /* * This is a network bit (1). If we've already seen a * host bit (0), we need to bomb. */ if(foundnmh==1) { errno = EINVAL; return(-1); } pflen++; } else foundnmh=1; /* A host bit */ } } /* If we get here, return the length */ return(pflen); } /* Get the address bits */ uint8_t * cidr_get_addr(const CIDR *addr) { uint8_t *toret; if(addr==NULL) { errno = EFAULT; return(NULL); } toret = malloc(16*sizeof(uint8_t)); if(toret==NULL) { errno = ENOMEM; return(NULL); } /* Copy 'em in */ memcpy(toret, addr->addr, sizeof(addr->addr)); return(toret); } /* Get the netmask bits */ uint8_t * cidr_get_mask(const CIDR *addr) { uint8_t *toret; if(addr==NULL) { errno = EFAULT; return(NULL); } toret = malloc(16*sizeof(uint8_t)); if(toret==NULL) { errno = ENOMEM; return(NULL); } /* Copy 'em in */ memcpy(toret, addr->mask, sizeof(addr->mask)); return(toret); } /* Get the protocol */ int cidr_get_proto(const CIDR *addr) { if(addr==NULL) { errno = EFAULT; return(-1); } return(addr->proto); }
14.88
114
(translation_unit) "/*\n * cidr_get - Get and return various semi-raw bits of info\n */\n\n#include <errno.h>\n#include <stdlib.h>\n#include <string.h>\n\n#include <libcidr.h>\n\n\n/* Get the prefix length */\nint\ncidr_get_pflen(const CIDR *block)\n{\n int i, j;\n int foundnmh;\n int pflen;\n\n if(block==NULL)\n {\n errno = EFAULT;\n return(-1);\n }\n\n /* Where do we start? */\n if(block->proto==CIDR_IPV4)\n i=12;\n else if(block->proto==CIDR_IPV6)\n i=0;\n else\n {\n errno = ENOENT; /* Bad errno */\n return(-1); /* Unknown */\n }\n\n /*\n * We're intentionally not supporting non-contiguous netmasks. So,\n * if we find one, bomb out.\n */\n foundnmh=0;\n pflen=0;\n for(/* i */ ; i<=15 ; i++)\n {\n for(j=7 ; j>=0 ; j--)\n {\n if((block->mask)[i] & (1<<j))\n {\n /*\n * This is a network bit (1). If we've already seen a\n * host bit (0), we need to bomb.\n */\n if(foundnmh==1)\n {\n errno = EINVAL;\n return(-1);\n }\n\n pflen++;\n }\n else\n foundnmh=1; /* A host bit */\n }\n }\n\n /* If we get here, return the length */\n return(pflen);\n}\n\n\n/* Get the address bits */\nuint8_t *\ncidr_get_addr(const CIDR *addr)\n{\n uint8_t *toret;\n\n if(addr==NULL)\n {\n errno = EFAULT;\n return(NULL);\n }\n\n toret = malloc(16*sizeof(uint8_t));\n if(toret==NULL)\n {\n errno = ENOMEM;\n return(NULL);\n }\n\n /* Copy 'em in */\n memcpy(toret, addr->addr, sizeof(addr->addr));\n\n return(toret);\n}\n\n\n/* Get the netmask bits */\nuint8_t *\ncidr_get_mask(const CIDR *addr)\n{\n uint8_t *toret;\n\n if(addr==NULL)\n {\n errno = EFAULT;\n return(NULL);\n }\n\n toret = malloc(16*sizeof(uint8_t));\n if(toret==NULL)\n {\n errno = ENOMEM;\n return(NULL);\n }\n\n /* Copy 'em in */\n memcpy(toret, addr->mask, sizeof(addr->mask));\n\n return(toret);\n}\n\n\n/* Get the protocol */\nint\ncidr_get_proto(const CIDR *addr)\n{\n\n if(addr==NULL)\n {\n errno = EFAULT;\n return(-1);\n }\n\n return(addr->proto);\n}\n" (comment) "/*\n * cidr_get - Get and return various semi-raw bits of info\n */" (preproc_include) "#include <errno.h>\n" (#include) "#include" (system_lib_string) "<errno.h>" (preproc_include) "#include <stdlib.h>\n" (#include) "#include" (system_lib_string) "<stdlib.h>" (preproc_include) "#include <string.h>\n" (#include) "#include" (system_lib_string) "<string.h>" (preproc_include) "#include <libcidr.h>\n" (#include) "#include" (system_lib_string) "<libcidr.h>" (comment) "/* Get the prefix length */" (function_definition) "int\ncidr_get_pflen(const CIDR *block)\n{\n int i, j;\n int foundnmh;\n int pflen;\n\n if(block==NULL)\n {\n errno = EFAULT;\n return(-1);\n }\n\n /* Where do we start? */\n if(block->proto==CIDR_IPV4)\n i=12;\n else if(block->proto==CIDR_IPV6)\n i=0;\n else\n {\n errno = ENOENT; /* Bad errno */\n return(-1); /* Unknown */\n }\n\n /*\n * We're intentionally not supporting non-contiguous netmasks. So,\n * if we find one, bomb out.\n */\n foundnmh=0;\n pflen=0;\n for(/* i */ ; i<=15 ; i++)\n {\n for(j=7 ; j>=0 ; j--)\n {\n if((block->mask)[i] & (1<<j))\n {\n /*\n * This is a network bit (1). If we've already seen a\n * host bit (0), we need to bomb.\n */\n if(foundnmh==1)\n {\n errno = EINVAL;\n return(-1);\n }\n\n pflen++;\n }\n else\n foundnmh=1; /* A host bit */\n }\n }\n\n /* If we get here, return the length */\n return(pflen);\n}" (primitive_type) "int" (function_declarator) "cidr_get_pflen(const CIDR *block)" (identifier) "cidr_get_pflen" (parameter_list) "(const CIDR *block)" (() "(" (parameter_declaration) "const CIDR *block" (type_qualifier) "const" (const) "const" (type_identifier) "CIDR" (pointer_declarator) "*block" (*) "*" (identifier) "block" ()) ")" (compound_statement) "{\n int i, j;\n int foundnmh;\n int pflen;\n\n if(block==NULL)\n {\n errno = EFAULT;\n return(-1);\n }\n\n /* Where do we start? */\n if(block->proto==CIDR_IPV4)\n i=12;\n else if(block->proto==CIDR_IPV6)\n i=0;\n else\n {\n errno = ENOENT; /* Bad errno */\n return(-1); /* Unknown */\n }\n\n /*\n * We're intentionally not supporting non-contiguous netmasks. So,\n * if we find one, bomb out.\n */\n foundnmh=0;\n pflen=0;\n for(/* i */ ; i<=15 ; i++)\n {\n for(j=7 ; j>=0 ; j--)\n {\n if((block->mask)[i] & (1<<j))\n {\n /*\n * This is a network bit (1). If we've already seen a\n * host bit (0), we need to bomb.\n */\n if(foundnmh==1)\n {\n errno = EINVAL;\n return(-1);\n }\n\n pflen++;\n }\n else\n foundnmh=1; /* A host bit */\n }\n }\n\n /* If we get here, return the length */\n return(pflen);\n}" ({) "{" (declaration) "int i, j;" (primitive_type) "int" (identifier) "i" (,) "," (identifier) "j" (;) ";" (declaration) "int foundnmh;" (primitive_type) "int" (identifier) "foundnmh" (;) ";" (declaration) "int pflen;" (primitive_type) "int" (identifier) "pflen" (;) ";" (if_statement) "if(block==NULL)\n {\n errno = EFAULT;\n return(-1);\n }" (if) "if" (parenthesized_expression) "(block==NULL)" (() "(" (binary_expression) "block==NULL" (identifier) "block" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{\n errno = EFAULT;\n return(-1);\n }" ({) "{" (expression_statement) "errno = EFAULT;" (assignment_expression) "errno = EFAULT" (identifier) "errno" (=) "=" (identifier) "EFAULT" (;) ";" (return_statement) "return(-1);" (return) "return" (parenthesized_expression) "(-1)" (() "(" (number_literal) "-1" ()) ")" (;) ";" (}) "}" (comment) "/* Where do we start? */" (if_statement) "if(block->proto==CIDR_IPV4)\n i=12;\n else if(block->proto==CIDR_IPV6)\n i=0;\n else\n {\n errno = ENOENT; /* Bad errno */\n return(-1); /* Unknown */\n }" (if) "if" (parenthesized_expression) "(block->proto==CIDR_IPV4)" (() "(" (binary_expression) "block->proto==CIDR_IPV4" (field_expression) "block->proto" (identifier) "block" (->) "->" (field_identifier) "proto" (==) "==" (identifier) "CIDR_IPV4" ()) ")" (expression_statement) "i=12;" (assignment_expression) "i=12" (identifier) "i" (=) "=" (number_literal) "12" (;) ";" (else_clause) "else if(block->proto==CIDR_IPV6)\n i=0;\n else\n {\n errno = ENOENT; /* Bad errno */\n return(-1); /* Unknown */\n }" (else) "else" (if_statement) "if(block->proto==CIDR_IPV6)\n i=0;\n else\n {\n errno = ENOENT; /* Bad errno */\n return(-1); /* Unknown */\n }" (if) "if" (parenthesized_expression) "(block->proto==CIDR_IPV6)" (() "(" (binary_expression) "block->proto==CIDR_IPV6" (field_expression) "block->proto" (identifier) "block" (->) "->" (field_identifier) "proto" (==) "==" (identifier) "CIDR_IPV6" ()) ")" (expression_statement) "i=0;" (assignment_expression) "i=0" (identifier) "i" (=) "=" (number_literal) "0" (;) ";" (else_clause) "else\n {\n errno = ENOENT; /* Bad errno */\n return(-1); /* Unknown */\n }" (else) "else" (compound_statement) "{\n errno = ENOENT; /* Bad errno */\n return(-1); /* Unknown */\n }" ({) "{" (expression_statement) "errno = ENOENT;" (assignment_expression) "errno = ENOENT" (identifier) "errno" (=) "=" (identifier) "ENOENT" (;) ";" (comment) "/* Bad errno */" (return_statement) "return(-1);" (return) "return" (parenthesized_expression) "(-1)" (() "(" (number_literal) "-1" ()) ")" (;) ";" (comment) "/* Unknown */" (}) "}" (comment) "/*\n * We're intentionally not supporting non-contiguous netmasks. So,\n * if we find one, bomb out.\n */" (expression_statement) "foundnmh=0;" (assignment_expression) "foundnmh=0" (identifier) "foundnmh" (=) "=" (number_literal) "0" (;) ";" (expression_statement) "pflen=0;" (assignment_expression) "pflen=0" (identifier) "pflen" (=) "=" (number_literal) "0" (;) ";" (for_statement) "for(/* i */ ; i<=15 ; i++)\n {\n for(j=7 ; j>=0 ; j--)\n {\n if((block->mask)[i] & (1<<j))\n {\n /*\n * This is a network bit (1). If we've already seen a\n * host bit (0), we need to bomb.\n */\n if(foundnmh==1)\n {\n errno = EINVAL;\n return(-1);\n }\n\n pflen++;\n }\n else\n foundnmh=1; /* A host bit */\n }\n }" (for) "for" (() "(" (comment) "/* i */" (;) ";" (binary_expression) "i<=15" (identifier) "i" (<=) "<=" (number_literal) "15" (;) ";" (update_expression) "i++" (identifier) "i" (++) "++" ()) ")" (compound_statement) "{\n for(j=7 ; j>=0 ; j--)\n {\n if((block->mask)[i] & (1<<j))\n {\n /*\n * This is a network bit (1). If we've already seen a\n * host bit (0), we need to bomb.\n */\n if(foundnmh==1)\n {\n errno = EINVAL;\n return(-1);\n }\n\n pflen++;\n }\n else\n foundnmh=1; /* A host bit */\n }\n }" ({) "{" (for_statement) "for(j=7 ; j>=0 ; j--)\n {\n if((block->mask)[i] & (1<<j))\n {\n /*\n * This is a network bit (1). If we've already seen a\n * host bit (0), we need to bomb.\n */\n if(foundnmh==1)\n {\n errno = EINVAL;\n return(-1);\n }\n\n pflen++;\n }\n else\n foundnmh=1; /* A host bit */\n }" (for) "for" (() "(" (assignment_expression) "j=7" (identifier) "j" (=) "=" (number_literal) "7" (;) ";" (binary_expression) "j>=0" (identifier) "j" (>=) ">=" (number_literal) "0" (;) ";" (update_expression) "j--" (identifier) "j" (--) "--" ()) ")" (compound_statement) "{\n if((block->mask)[i] & (1<<j))\n {\n /*\n * This is a network bit (1). If we've already seen a\n * host bit (0), we need to bomb.\n */\n if(foundnmh==1)\n {\n errno = EINVAL;\n return(-1);\n }\n\n pflen++;\n }\n else\n foundnmh=1; /* A host bit */\n }" ({) "{" (if_statement) "if((block->mask)[i] & (1<<j))\n {\n /*\n * This is a network bit (1). If we've already seen a\n * host bit (0), we need to bomb.\n */\n if(foundnmh==1)\n {\n errno = EINVAL;\n return(-1);\n }\n\n pflen++;\n }\n else\n foundnmh=1;" (if) "if" (parenthesized_expression) "((block->mask)[i] & (1<<j))" (() "(" (binary_expression) "(block->mask)[i] & (1<<j)" (subscript_expression) "(block->mask)[i]" (parenthesized_expression) "(block->mask)" (() "(" (field_expression) "block->mask" (identifier) "block" (->) "->" (field_identifier) "mask" ()) ")" ([) "[" (identifier) "i" (]) "]" (&) "&" (parenthesized_expression) "(1<<j)" (() "(" (binary_expression) "1<<j" (number_literal) "1" (<<) "<<" (identifier) "j" ()) ")" ()) ")" (compound_statement) "{\n /*\n * This is a network bit (1). If we've already seen a\n * host bit (0), we need to bomb.\n */\n if(foundnmh==1)\n {\n errno = EINVAL;\n return(-1);\n }\n\n pflen++;\n }" ({) "{" (comment) "/*\n * This is a network bit (1). If we've already seen a\n * host bit (0), we need to bomb.\n */" (if_statement) "if(foundnmh==1)\n {\n errno = EINVAL;\n return(-1);\n }" (if) "if" (parenthesized_expression) "(foundnmh==1)" (() "(" (binary_expression) "foundnmh==1" (identifier) "foundnmh" (==) "==" (number_literal) "1" ()) ")" (compound_statement) "{\n errno = EINVAL;\n return(-1);\n }" ({) "{" (expression_statement) "errno = EINVAL;" (assignment_expression) "errno = EINVAL" (identifier) "errno" (=) "=" (identifier) "EINVAL" (;) ";" (return_statement) "return(-1);" (return) "return" (parenthesized_expression) "(-1)" (() "(" (number_literal) "-1" ()) ")" (;) ";" (}) "}" (expression_statement) "pflen++;" (update_expression) "pflen++" (identifier) "pflen" (++) "++" (;) ";" (}) "}" (else_clause) "else\n foundnmh=1;" (else) "else" (expression_statement) "foundnmh=1;" (assignment_expression) "foundnmh=1" (identifier) "foundnmh" (=) "=" (number_literal) "1" (;) ";" (comment) "/* A host bit */" (}) "}" (}) "}" (comment) "/* If we get here, return the length */" (return_statement) "return(pflen);" (return) "return" (parenthesized_expression) "(pflen)" (() "(" (identifier) "pflen" ()) ")" (;) ";" (}) "}" (comment) "/* Get the address bits */" (function_definition) "uint8_t *\ncidr_get_addr(const CIDR *addr)\n{\n uint8_t *toret;\n\n if(addr==NULL)\n {\n errno = EFAULT;\n return(NULL);\n }\n\n toret = malloc(16*sizeof(uint8_t));\n if(toret==NULL)\n {\n errno = ENOMEM;\n return(NULL);\n }\n\n /* Copy 'em in */\n memcpy(toret, addr->addr, sizeof(addr->addr));\n\n return(toret);\n}" (primitive_type) "uint8_t" (pointer_declarator) "*\ncidr_get_addr(const CIDR *addr)" (*) "*" (function_declarator) "cidr_get_addr(const CIDR *addr)" (identifier) "cidr_get_addr" (parameter_list) "(const CIDR *addr)" (() "(" (parameter_declaration) "const CIDR *addr" (type_qualifier) "const" (const) "const" (type_identifier) "CIDR" (pointer_declarator) "*addr" (*) "*" (identifier) "addr" ()) ")" (compound_statement) "{\n uint8_t *toret;\n\n if(addr==NULL)\n {\n errno = EFAULT;\n return(NULL);\n }\n\n toret = malloc(16*sizeof(uint8_t));\n if(toret==NULL)\n {\n errno = ENOMEM;\n return(NULL);\n }\n\n /* Copy 'em in */\n memcpy(toret, addr->addr, sizeof(addr->addr));\n\n return(toret);\n}" ({) "{" (declaration) "uint8_t *toret;" (primitive_type) "uint8_t" (pointer_declarator) "*toret" (*) "*" (identifier) "toret" (;) ";" (if_statement) "if(addr==NULL)\n {\n errno = EFAULT;\n return(NULL);\n }" (if) "if" (parenthesized_expression) "(addr==NULL)" (() "(" (binary_expression) "addr==NULL" (identifier) "addr" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{\n errno = EFAULT;\n return(NULL);\n }" ({) "{" (expression_statement) "errno = EFAULT;" (assignment_expression) "errno = EFAULT" (identifier) "errno" (=) "=" (identifier) "EFAULT" (;) ";" (return_statement) "return(NULL);" (return) "return" (parenthesized_expression) "(NULL)" (() "(" (null) "NULL" (NULL) "NULL" ()) ")" (;) ";" (}) "}" (expression_statement) "toret = malloc(16*sizeof(uint8_t));" (assignment_expression) "toret = malloc(16*sizeof(uint8_t))" (identifier) "toret" (=) "=" (call_expression) "malloc(16*sizeof(uint8_t))" (identifier) "malloc" (argument_list) "(16*sizeof(uint8_t))" (() "(" (binary_expression) "16*sizeof(uint8_t)" (number_literal) "16" (*) "*" (sizeof_expression) "sizeof(uint8_t)" (sizeof) "sizeof" (() "(" (type_descriptor) "uint8_t" (primitive_type) "uint8_t" ()) ")" ()) ")" (;) ";" (if_statement) "if(toret==NULL)\n {\n errno = ENOMEM;\n return(NULL);\n }" (if) "if" (parenthesized_expression) "(toret==NULL)" (() "(" (binary_expression) "toret==NULL" (identifier) "toret" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{\n errno = ENOMEM;\n return(NULL);\n }" ({) "{" (expression_statement) "errno = ENOMEM;" (assignment_expression) "errno = ENOMEM" (identifier) "errno" (=) "=" (identifier) "ENOMEM" (;) ";" (return_statement) "return(NULL);" (return) "return" (parenthesized_expression) "(NULL)" (() "(" (null) "NULL" (NULL) "NULL" ()) ")" (;) ";" (}) "}" (comment) "/* Copy 'em in */" (expression_statement) "memcpy(toret, addr->addr, sizeof(addr->addr));" (call_expression) "memcpy(toret, addr->addr, sizeof(addr->addr))" (identifier) "memcpy" (argument_list) "(toret, addr->addr, sizeof(addr->addr))" (() "(" (identifier) "toret" (,) "," (field_expression) "addr->addr" (identifier) "addr" (->) "->" (field_identifier) "addr" (,) "," (sizeof_expression) "sizeof(addr->addr)" (sizeof) "sizeof" (parenthesized_expression) "(addr->addr)" (() "(" (field_expression) "addr->addr" (identifier) "addr" (->) "->" (field_identifier) "addr" ()) ")" ()) ")" (;) ";" (return_statement) "return(toret);" (return) "return" (parenthesized_expression) "(toret)" (() "(" (identifier) "toret" ()) ")" (;) ";" (}) "}" (comment) "/* Get the netmask bits */" (function_definition) "uint8_t *\ncidr_get_mask(const CIDR *addr)\n{\n uint8_t *toret;\n\n if(addr==NULL)\n {\n errno = EFAULT;\n return(NULL);\n }\n\n toret = malloc(16*sizeof(uint8_t));\n if(toret==NULL)\n {\n errno = ENOMEM;\n return(NULL);\n }\n\n /* Copy 'em in */\n memcpy(toret, addr->mask, sizeof(addr->mask));\n\n return(toret);\n}" (primitive_type) "uint8_t" (pointer_declarator) "*\ncidr_get_mask(const CIDR *addr)" (*) "*" (function_declarator) "cidr_get_mask(const CIDR *addr)" (identifier) "cidr_get_mask" (parameter_list) "(const CIDR *addr)" (() "(" (parameter_declaration) "const CIDR *addr" (type_qualifier) "const" (const) "const" (type_identifier) "CIDR" (pointer_declarator) "*addr" (*) "*" (identifier) "addr" ()) ")" (compound_statement) "{\n uint8_t *toret;\n\n if(addr==NULL)\n {\n errno = EFAULT;\n return(NULL);\n }\n\n toret = malloc(16*sizeof(uint8_t));\n if(toret==NULL)\n {\n errno = ENOMEM;\n return(NULL);\n }\n\n /* Copy 'em in */\n memcpy(toret, addr->mask, sizeof(addr->mask));\n\n return(toret);\n}" ({) "{" (declaration) "uint8_t *toret;" (primitive_type) "uint8_t" (pointer_declarator) "*toret" (*) "*" (identifier) "toret" (;) ";" (if_statement) "if(addr==NULL)\n {\n errno = EFAULT;\n return(NULL);\n }" (if) "if" (parenthesized_expression) "(addr==NULL)" (() "(" (binary_expression) "addr==NULL" (identifier) "addr" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{\n errno = EFAULT;\n return(NULL);\n }" ({) "{" (expression_statement) "errno = EFAULT;" (assignment_expression) "errno = EFAULT" (identifier) "errno" (=) "=" (identifier) "EFAULT" (;) ";" (return_statement) "return(NULL);" (return) "return" (parenthesized_expression) "(NULL)" (() "(" (null) "NULL" (NULL) "NULL" ()) ")" (;) ";" (}) "}" (expression_statement) "toret = malloc(16*sizeof(uint8_t));" (assignment_expression) "toret = malloc(16*sizeof(uint8_t))" (identifier) "toret" (=) "=" (call_expression) "malloc(16*sizeof(uint8_t))" (identifier) "malloc" (argument_list) "(16*sizeof(uint8_t))" (() "(" (binary_expression) "16*sizeof(uint8_t)" (number_literal) "16" (*) "*" (sizeof_expression) "sizeof(uint8_t)" (sizeof) "sizeof" (() "(" (type_descriptor) "uint8_t" (primitive_type) "uint8_t" ()) ")" ()) ")" (;) ";" (if_statement) "if(toret==NULL)\n {\n errno = ENOMEM;\n return(NULL);\n }" (if) "if" (parenthesized_expression) "(toret==NULL)" (() "(" (binary_expression) "toret==NULL" (identifier) "toret" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{\n errno = ENOMEM;\n return(NULL);\n }" ({) "{" (expression_statement) "errno = ENOMEM;" (assignment_expression) "errno = ENOMEM" (identifier) "errno" (=) "=" (identifier) "ENOMEM" (;) ";" (return_statement) "return(NULL);" (return) "return" (parenthesized_expression) "(NULL)" (() "(" (null) "NULL" (NULL) "NULL" ()) ")" (;) ";" (}) "}" (comment) "/* Copy 'em in */" (expression_statement) "memcpy(toret, addr->mask, sizeof(addr->mask));" (call_expression) "memcpy(toret, addr->mask, sizeof(addr->mask))" (identifier) "memcpy" (argument_list) "(toret, addr->mask, sizeof(addr->mask))" (() "(" (identifier) "toret" (,) "," (field_expression) "addr->mask" (identifier) "addr" (->) "->" (field_identifier) "mask" (,) "," (sizeof_expression) "sizeof(addr->mask)" (sizeof) "sizeof" (parenthesized_expression) "(addr->mask)" (() "(" (field_expression) "addr->mask" (identifier) "addr" (->) "->" (field_identifier) "mask" ()) ")" ()) ")" (;) ";" (return_statement) "return(toret);" (return) "return" (parenthesized_expression) "(toret)" (() "(" (identifier) "toret" ()) ")" (;) ";" (}) "}" (comment) "/* Get the protocol */" (function_definition) "int\ncidr_get_proto(const CIDR *addr)\n{\n\n if(addr==NULL)\n {\n errno = EFAULT;\n return(-1);\n }\n\n return(addr->proto);\n}" (primitive_type) "int" (function_declarator) "cidr_get_proto(const CIDR *addr)" (identifier) "cidr_get_proto" (parameter_list) "(const CIDR *addr)" (() "(" (parameter_declaration) "const CIDR *addr" (type_qualifier) "const" (const) "const" (type_identifier) "CIDR" (pointer_declarator) "*addr" (*) "*" (identifier) "addr" ()) ")" (compound_statement) "{\n\n if(addr==NULL)\n {\n errno = EFAULT;\n return(-1);\n }\n\n return(addr->proto);\n}" ({) "{" (if_statement) "if(addr==NULL)\n {\n errno = EFAULT;\n return(-1);\n }" (if) "if" (parenthesized_expression) "(addr==NULL)" (() "(" (binary_expression) "addr==NULL" (identifier) "addr" (==) "==" (null) "NULL" (NULL) "NULL" ()) ")" (compound_statement) "{\n errno = EFAULT;\n return(-1);\n }" ({) "{" (expression_statement) "errno = EFAULT;" (assignment_expression) "errno = EFAULT" (identifier) "errno" (=) "=" (identifier) "EFAULT" (;) ";" (return_statement) "return(-1);" (return) "return" (parenthesized_expression) "(-1)" (() "(" (number_literal) "-1" ()) ")" (;) ";" (}) "}" (return_statement) "return(addr->proto);" (return) "return" (parenthesized_expression) "(addr->proto)" (() "(" (field_expression) "addr->proto" (identifier) "addr" (->) "->" (field_identifier) "proto" ()) ")" (;) ";" (}) "}"
571
0
{"language": "c", "success": true, "metadata": {"lines": 114, "avg_line_length": 14.88, "nodes": 322, "errors": 0, "source_hash": "35e9fd9dccfc440350aa5be6e07bbad26e660b0289bfe9fa7b14ecb608e94d29", "categorized_nodes": 229}, "ast": {"root": "translation_unit", "nodes": [{"id": 0, "type": "preproc_include", "text": "#include <errno.h>\n", "parent": null, "children": [1, 2], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 5, "column": 0}}, {"id": 1, "type": "#include", "text": "#include", "parent": 0, "children": [], "start_point": {"row": 4, "column": 0}, "end_point": {"row": 4, "column": 8}}, {"id": 2, "type": "system_lib_string", "text": "<errno.h>", "parent": 0, "children": [], "start_point": {"row": 4, "column": 9}, "end_point": {"row": 4, "column": 18}}, {"id": 3, "type": "preproc_include", "text": "#include <stdlib.h>\n", "parent": null, "children": [4, 5], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 6, "column": 0}}, {"id": 4, "type": "#include", "text": "#include", "parent": 3, "children": [], "start_point": {"row": 5, "column": 0}, "end_point": {"row": 5, "column": 8}}, {"id": 5, "type": "system_lib_string", "text": "<stdlib.h>", "parent": 3, "children": [], "start_point": {"row": 5, "column": 9}, "end_point": {"row": 5, "column": 19}}, {"id": 6, "type": "preproc_include", "text": "#include <string.h>\n", "parent": null, "children": [7, 8], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 7, "column": 0}}, {"id": 7, "type": "#include", "text": "#include", "parent": 6, "children": [], "start_point": {"row": 6, "column": 0}, "end_point": {"row": 6, "column": 8}}, {"id": 8, "type": "system_lib_string", "text": "<string.h>", "parent": 6, "children": [], "start_point": {"row": 6, "column": 9}, "end_point": {"row": 6, "column": 19}}, {"id": 9, "type": "preproc_include", "text": "#include <libcidr.h>\n", "parent": null, "children": [10, 11], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 9, "column": 0}}, {"id": 10, "type": "#include", "text": "#include", "parent": 9, "children": [], "start_point": {"row": 8, "column": 0}, "end_point": {"row": 8, "column": 8}}, {"id": 11, "type": "system_lib_string", "text": "<libcidr.h>", "parent": 9, "children": [], "start_point": {"row": 8, "column": 9}, "end_point": {"row": 8, "column": 20}}, {"id": 12, "type": "function_definition", "text": "int\ncidr_get_pflen(const CIDR *block)\n{\n\tint i, j;\n\tint foundnmh;\n\tint pflen;\n\n\tif(block==NULL)\n\t{\n\t\terrno = EFAULT;\n\t\treturn(-1);\n\t}\n\n\t/* Where do we start? */\n\tif(block->proto==CIDR_IPV4)\n\t\ti=12;\n\telse if(block->proto==CIDR_IPV6)\n\t\ti=0;\n\telse\n\t{\n\t\terrno = ENOENT; /* Bad errno */\n\t\treturn(-1); /* Unknown */\n\t}\n\n\t/*\n\t * We're intentionally not supporting non-contiguous netmasks. So,\n\t * if we find one, bomb out.\n\t */\n\tfoundnmh=0;\n\tpflen=0;\n\tfor(/* i */ ; i<=15 ; i++)\n\t{\n\t\tfor(j=7 ; j>=0 ; j--)\n\t\t{\n\t\t\tif((block->mask)[i] & (1<<j))\n\t\t\t{\n\t\t\t\t/*\n\t\t\t\t * This is a network bit (1). If we've already seen a\n\t\t\t\t * host bit (0), we need to bomb.\n\t\t\t\t */\n\t\t\t\tif(foundnmh==1)\n\t\t\t\t{\n\t\t\t\t\terrno = EINVAL;\n\t\t\t\t\treturn(-1);\n\t\t\t\t}\n\n\t\t\t\tpflen++;\n\t\t\t}\n\t\t\telse\n\t\t\t\tfoundnmh=1; /* A host bit */\n\t\t}\n\t}\n\n\t/* If we get here, return the length */\n\treturn(pflen);\n}", "parent": null, "children": [13, 14], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 67, "column": 1}}, {"id": 13, "type": "primitive_type", "text": "int", "parent": 12, "children": [], "start_point": {"row": 12, "column": 0}, "end_point": {"row": 12, "column": 3}}, {"id": 14, "type": "function_declarator", "text": "cidr_get_pflen(const CIDR *block)", "parent": 12, "children": [15, 16], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 33}}, {"id": 15, "type": "identifier", "text": "cidr_get_pflen", "parent": 14, "children": [], "start_point": {"row": 13, "column": 0}, "end_point": {"row": 13, "column": 14}}, {"id": 16, "type": "parameter_list", "text": "(const CIDR *block)", "parent": 14, "children": [17], "start_point": {"row": 13, "column": 14}, "end_point": {"row": 13, "column": 33}}, {"id": 17, "type": "parameter_declaration", "text": "const CIDR *block", "parent": 16, "children": [18, 19], "start_point": {"row": 13, "column": 15}, "end_point": {"row": 13, "column": 32}}, {"id": 18, "type": "type_identifier", "text": "CIDR", "parent": 17, "children": [], "start_point": {"row": 13, "column": 21}, "end_point": {"row": 13, "column": 25}}, {"id": 19, "type": "pointer_declarator", "text": "*block", "parent": 17, "children": [20, 21], "start_point": {"row": 13, "column": 26}, "end_point": {"row": 13, "column": 32}}, {"id": 20, "type": "*", "text": "*", "parent": 19, "children": [], "start_point": {"row": 13, "column": 26}, "end_point": {"row": 13, "column": 27}}, {"id": 21, "type": "identifier", "text": "block", "parent": 19, "children": [], "start_point": {"row": 13, "column": 27}, "end_point": {"row": 13, "column": 32}}, {"id": 22, "type": "declaration", "text": "int i, j;", "parent": 12, "children": [23, 24, 25], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 10}}, {"id": 23, "type": "primitive_type", "text": "int", "parent": 22, "children": [], "start_point": {"row": 15, "column": 1}, "end_point": {"row": 15, "column": 4}}, {"id": 24, "type": "identifier", "text": "i", "parent": 22, "children": [], "start_point": {"row": 15, "column": 5}, "end_point": {"row": 15, "column": 6}}, {"id": 25, "type": "identifier", "text": "j", "parent": 22, "children": [], "start_point": {"row": 15, "column": 8}, "end_point": {"row": 15, "column": 9}}, {"id": 26, "type": "declaration", "text": "int foundnmh;", "parent": 12, "children": [27, 28], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 14}}, {"id": 27, "type": "primitive_type", "text": "int", "parent": 26, "children": [], "start_point": {"row": 16, "column": 1}, "end_point": {"row": 16, "column": 4}}, {"id": 28, "type": "identifier", "text": "foundnmh", "parent": 26, "children": [], "start_point": {"row": 16, "column": 5}, "end_point": {"row": 16, "column": 13}}, {"id": 29, "type": "declaration", "text": "int pflen;", "parent": 12, "children": [30, 31], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 11}}, {"id": 30, "type": "primitive_type", "text": "int", "parent": 29, "children": [], "start_point": {"row": 17, "column": 1}, "end_point": {"row": 17, "column": 4}}, {"id": 31, "type": "identifier", "text": "pflen", "parent": 29, "children": [], "start_point": {"row": 17, "column": 5}, "end_point": {"row": 17, "column": 10}}, {"id": 32, "type": "if_statement", "text": "if(block==NULL)\n\t{\n\t\terrno = EFAULT;\n\t\treturn(-1);\n\t}", "parent": 12, "children": [33], "start_point": {"row": 19, "column": 1}, "end_point": {"row": 23, "column": 2}}, {"id": 33, "type": "parenthesized_expression", "text": "(block==NULL)", "parent": 32, "children": [34], "start_point": {"row": 19, "column": 3}, "end_point": {"row": 19, "column": 16}}, {"id": 34, "type": "binary_expression", "text": "block==NULL", "parent": 33, "children": [35, 36, 37], "start_point": {"row": 19, "column": 4}, "end_point": {"row": 19, "column": 15}}, {"id": 35, "type": "identifier", "text": "block", "parent": 34, "children": [], "start_point": {"row": 19, "column": 4}, "end_point": {"row": 19, "column": 9}}, {"id": 36, "type": "==", "text": "==", "parent": 34, "children": [], "start_point": {"row": 19, "column": 9}, "end_point": {"row": 19, "column": 11}}, {"id": 37, "type": "null", "text": "NULL", "parent": 34, "children": [38], "start_point": {"row": 19, "column": 11}, "end_point": {"row": 19, "column": 15}}, {"id": 38, "type": "NULL", "text": "NULL", "parent": 37, "children": [], "start_point": {"row": 19, "column": 11}, "end_point": {"row": 19, "column": 15}}, {"id": 39, "type": "assignment_expression", "text": "errno = EFAULT", "parent": 32, "children": [40, 41, 42], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 16}}, {"id": 40, "type": "identifier", "text": "errno", "parent": 39, "children": [], "start_point": {"row": 21, "column": 2}, "end_point": {"row": 21, "column": 7}}, {"id": 41, "type": "=", "text": "=", "parent": 39, "children": [], "start_point": {"row": 21, "column": 8}, "end_point": {"row": 21, "column": 9}}, {"id": 42, "type": "identifier", "text": "EFAULT", "parent": 39, "children": [], "start_point": {"row": 21, "column": 10}, "end_point": {"row": 21, "column": 16}}, {"id": 43, "type": "return_statement", "text": "return(-1);", "parent": 32, "children": [44], "start_point": {"row": 22, "column": 2}, "end_point": {"row": 22, "column": 13}}, {"id": 44, "type": "parenthesized_expression", "text": "(-1)", "parent": 43, "children": [45], "start_point": {"row": 22, "column": 8}, "end_point": {"row": 22, "column": 12}}, {"id": 45, "type": "number_literal", "text": "-1", "parent": 44, "children": [], "start_point": {"row": 22, "column": 9}, "end_point": {"row": 22, "column": 11}}, {"id": 46, "type": "if_statement", "text": "if(block->proto==CIDR_IPV4)\n\t\ti=12;\n\telse if(block->proto==CIDR_IPV6)\n\t\ti=0;\n\telse\n\t{\n\t\terrno = ENOENT; /* Bad errno */\n\t\treturn(-1); /* Unknown */\n\t}", "parent": 12, "children": [47, 58], "start_point": {"row": 26, "column": 1}, "end_point": {"row": 34, "column": 2}}, {"id": 47, "type": "parenthesized_expression", "text": "(block->proto==CIDR_IPV4)", "parent": 46, "children": [48], "start_point": {"row": 26, "column": 3}, "end_point": {"row": 26, "column": 28}}, {"id": 48, "type": "binary_expression", "text": "block->proto==CIDR_IPV4", "parent": 47, "children": [49, 52, 53], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 26, "column": 27}}, {"id": 49, "type": "field_expression", "text": "block->proto", "parent": 48, "children": [50, 51], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 26, "column": 16}}, {"id": 50, "type": "identifier", "text": "block", "parent": 49, "children": [], "start_point": {"row": 26, "column": 4}, "end_point": {"row": 26, "column": 9}}, {"id": 51, "type": "field_identifier", "text": "proto", "parent": 49, "children": [], "start_point": {"row": 26, "column": 11}, "end_point": {"row": 26, "column": 16}}, {"id": 52, "type": "==", "text": "==", "parent": 48, "children": [], "start_point": {"row": 26, "column": 16}, "end_point": {"row": 26, "column": 18}}, {"id": 53, "type": "identifier", "text": "CIDR_IPV4", "parent": 48, "children": [], "start_point": {"row": 26, "column": 18}, "end_point": {"row": 26, "column": 27}}, {"id": 54, "type": "assignment_expression", "text": "i=12", "parent": 46, "children": [55, 56, 57], "start_point": {"row": 27, "column": 2}, "end_point": {"row": 27, "column": 6}}, {"id": 55, "type": "identifier", "text": "i", "parent": 54, "children": [], "start_point": {"row": 27, "column": 2}, "end_point": {"row": 27, "column": 3}}, {"id": 56, "type": "=", "text": "=", "parent": 54, "children": [], "start_point": {"row": 27, "column": 3}, "end_point": {"row": 27, "column": 4}}, {"id": 57, "type": "number_literal", "text": "12", "parent": 54, "children": [], "start_point": {"row": 27, "column": 4}, "end_point": {"row": 27, "column": 6}}, {"id": 58, "type": "else_clause", "text": "else if(block->proto==CIDR_IPV6)\n\t\ti=0;\n\telse\n\t{\n\t\terrno = ENOENT; /* Bad errno */\n\t\treturn(-1); /* Unknown */\n\t}", "parent": 46, "children": [59], "start_point": {"row": 28, "column": 1}, "end_point": {"row": 34, "column": 2}}, {"id": 59, "type": "if_statement", "text": "if(block->proto==CIDR_IPV6)\n\t\ti=0;\n\telse\n\t{\n\t\terrno = ENOENT; /* Bad errno */\n\t\treturn(-1); /* Unknown */\n\t}", "parent": 58, "children": [60, 71], "start_point": {"row": 28, "column": 6}, "end_point": {"row": 34, "column": 2}}, {"id": 60, "type": "parenthesized_expression", "text": "(block->proto==CIDR_IPV6)", "parent": 59, "children": [61], "start_point": {"row": 28, "column": 8}, "end_point": {"row": 28, "column": 33}}, {"id": 61, "type": "binary_expression", "text": "block->proto==CIDR_IPV6", "parent": 60, "children": [62, 65, 66], "start_point": {"row": 28, "column": 9}, "end_point": {"row": 28, "column": 32}}, {"id": 62, "type": "field_expression", "text": "block->proto", "parent": 61, "children": [63, 64], "start_point": {"row": 28, "column": 9}, "end_point": {"row": 28, "column": 21}}, {"id": 63, "type": "identifier", "text": "block", "parent": 62, "children": [], "start_point": {"row": 28, "column": 9}, "end_point": {"row": 28, "column": 14}}, {"id": 64, "type": "field_identifier", "text": "proto", "parent": 62, "children": [], "start_point": {"row": 28, "column": 16}, "end_point": {"row": 28, "column": 21}}, {"id": 65, "type": "==", "text": "==", "parent": 61, "children": [], "start_point": {"row": 28, "column": 21}, "end_point": {"row": 28, "column": 23}}, {"id": 66, "type": "identifier", "text": "CIDR_IPV6", "parent": 61, "children": [], "start_point": {"row": 28, "column": 23}, "end_point": {"row": 28, "column": 32}}, {"id": 67, "type": "assignment_expression", "text": "i=0", "parent": 59, "children": [68, 69, 70], "start_point": {"row": 29, "column": 2}, "end_point": {"row": 29, "column": 5}}, {"id": 68, "type": "identifier", "text": "i", "parent": 67, "children": [], "start_point": {"row": 29, "column": 2}, "end_point": {"row": 29, "column": 3}}, {"id": 69, "type": "=", "text": "=", "parent": 67, "children": [], "start_point": {"row": 29, "column": 3}, "end_point": {"row": 29, "column": 4}}, {"id": 70, "type": "number_literal", "text": "0", "parent": 67, "children": [], "start_point": {"row": 29, "column": 4}, "end_point": {"row": 29, "column": 5}}, {"id": 71, "type": "else_clause", "text": "else\n\t{\n\t\terrno = ENOENT; /* Bad errno */\n\t\treturn(-1); /* Unknown */\n\t}", "parent": 59, "children": [], "start_point": {"row": 30, "column": 1}, "end_point": {"row": 34, "column": 2}}, {"id": 72, "type": "assignment_expression", "text": "errno = ENOENT", "parent": 71, "children": [73, 74, 75], "start_point": {"row": 32, "column": 2}, "end_point": {"row": 32, "column": 16}}, {"id": 73, "type": "identifier", "text": "errno", "parent": 72, "children": [], "start_point": {"row": 32, "column": 2}, "end_point": {"row": 32, "column": 7}}, {"id": 74, "type": "=", "text": "=", "parent": 72, "children": [], "start_point": {"row": 32, "column": 8}, "end_point": {"row": 32, "column": 9}}, {"id": 75, "type": "identifier", "text": "ENOENT", "parent": 72, "children": [], "start_point": {"row": 32, "column": 10}, "end_point": {"row": 32, "column": 16}}, {"id": 76, "type": "return_statement", "text": "return(-1);", "parent": 71, "children": [77], "start_point": {"row": 33, "column": 2}, "end_point": {"row": 33, "column": 13}}, {"id": 77, "type": "parenthesized_expression", "text": "(-1)", "parent": 76, "children": [78], "start_point": {"row": 33, "column": 8}, "end_point": {"row": 33, "column": 12}}, {"id": 78, "type": "number_literal", "text": "-1", "parent": 77, "children": [], "start_point": {"row": 33, "column": 9}, "end_point": {"row": 33, "column": 11}}, {"id": 79, "type": "assignment_expression", "text": "foundnmh=0", "parent": 12, "children": [80, 81, 82], "start_point": {"row": 40, "column": 1}, "end_point": {"row": 40, "column": 11}}, {"id": 80, "type": "identifier", "text": "foundnmh", "parent": 79, "children": [], "start_point": {"row": 40, "column": 1}, "end_point": {"row": 40, "column": 9}}, {"id": 81, "type": "=", "text": "=", "parent": 79, "children": [], "start_point": {"row": 40, "column": 9}, "end_point": {"row": 40, "column": 10}}, {"id": 82, "type": "number_literal", "text": "0", "parent": 79, "children": [], "start_point": {"row": 40, "column": 10}, "end_point": {"row": 40, "column": 11}}, {"id": 83, "type": "assignment_expression", "text": "pflen=0", "parent": 12, "children": [84, 85, 86], "start_point": {"row": 41, "column": 1}, "end_point": {"row": 41, "column": 8}}, {"id": 84, "type": "identifier", "text": "pflen", "parent": 83, "children": [], "start_point": {"row": 41, "column": 1}, "end_point": {"row": 41, "column": 6}}, {"id": 85, "type": "=", "text": "=", "parent": 83, "children": [], "start_point": {"row": 41, "column": 6}, "end_point": {"row": 41, "column": 7}}, {"id": 86, "type": "number_literal", "text": "0", "parent": 83, "children": [], "start_point": {"row": 41, "column": 7}, "end_point": {"row": 41, "column": 8}}, {"id": 87, "type": "for_statement", "text": "for(/* i */ ; i<=15 ; i++)\n\t{\n\t\tfor(j=7 ; j>=0 ; j--)\n\t\t{\n\t\t\tif((block->mask)[i] & (1<<j))\n\t\t\t{\n\t\t\t\t/*\n\t\t\t\t * This is a network bit (1). If we've already seen a\n\t\t\t\t * host bit (0), we need to bomb.\n\t\t\t\t */\n\t\t\t\tif(foundnmh==1)\n\t\t\t\t{\n\t\t\t\t\terrno = EINVAL;\n\t\t\t\t\treturn(-1);\n\t\t\t\t}\n\n\t\t\t\tpflen++;\n\t\t\t}\n\t\t\telse\n\t\t\t\tfoundnmh=1; /* A host bit */\n\t\t}\n\t}", "parent": 12, "children": [88, 92], "start_point": {"row": 42, "column": 1}, "end_point": {"row": 63, "column": 2}}, {"id": 88, "type": "binary_expression", "text": "i<=15", "parent": 87, "children": [89, 90, 91], "start_point": {"row": 42, "column": 15}, "end_point": {"row": 42, "column": 20}}, {"id": 89, "type": "identifier", "text": "i", "parent": 88, "children": [], "start_point": {"row": 42, "column": 15}, "end_point": {"row": 42, "column": 16}}, {"id": 90, "type": "<=", "text": "<=", "parent": 88, "children": [], "start_point": {"row": 42, "column": 16}, "end_point": {"row": 42, "column": 18}}, {"id": 91, "type": "number_literal", "text": "15", "parent": 88, "children": [], "start_point": {"row": 42, "column": 18}, "end_point": {"row": 42, "column": 20}}, {"id": 92, "type": "update_expression", "text": "i++", "parent": 87, "children": [93, 94], "start_point": {"row": 42, "column": 23}, "end_point": {"row": 42, "column": 26}}, {"id": 93, "type": "identifier", "text": "i", "parent": 92, "children": [], "start_point": {"row": 42, "column": 23}, "end_point": {"row": 42, "column": 24}}, {"id": 94, "type": "++", "text": "++", "parent": 92, "children": [], "start_point": {"row": 42, "column": 24}, "end_point": {"row": 42, "column": 26}}, {"id": 95, "type": "for_statement", "text": "for(j=7 ; j>=0 ; j--)\n\t\t{\n\t\t\tif((block->mask)[i] & (1<<j))\n\t\t\t{\n\t\t\t\t/*\n\t\t\t\t * This is a network bit (1). If we've already seen a\n\t\t\t\t * host bit (0), we need to bomb.\n\t\t\t\t */\n\t\t\t\tif(foundnmh==1)\n\t\t\t\t{\n\t\t\t\t\terrno = EINVAL;\n\t\t\t\t\treturn(-1);\n\t\t\t\t}\n\n\t\t\t\tpflen++;\n\t\t\t}\n\t\t\telse\n\t\t\t\tfoundnmh=1; /* A host bit */\n\t\t}", "parent": 87, "children": [96, 100, 104], "start_point": {"row": 44, "column": 2}, "end_point": {"row": 62, "column": 3}}, {"id": 96, "type": "assignment_expression", "text": "j=7", "parent": 95, "children": [97, 98, 99], "start_point": {"row": 44, "column": 6}, "end_point": {"row": 44, "column": 9}}, {"id": 97, "type": "identifier", "text": "j", "parent": 96, "children": [], "start_point": {"row": 44, "column": 6}, "end_point": {"row": 44, "column": 7}}, {"id": 98, "type": "=", "text": "=", "parent": 96, "children": [], "start_point": {"row": 44, "column": 7}, "end_point": {"row": 44, "column": 8}}, {"id": 99, "type": "number_literal", "text": "7", "parent": 96, "children": [], "start_point": {"row": 44, "column": 8}, "end_point": {"row": 44, "column": 9}}, {"id": 100, "type": "binary_expression", "text": "j>=0", "parent": 95, "children": [101, 102, 103], "start_point": {"row": 44, "column": 12}, "end_point": {"row": 44, "column": 16}}, {"id": 101, "type": "identifier", "text": "j", "parent": 100, "children": [], "start_point": {"row": 44, "column": 12}, "end_point": {"row": 44, "column": 13}}, {"id": 102, "type": ">=", "text": ">=", "parent": 100, "children": [], "start_point": {"row": 44, "column": 13}, "end_point": {"row": 44, "column": 15}}, {"id": 103, "type": "number_literal", "text": "0", "parent": 100, "children": [], "start_point": {"row": 44, "column": 15}, "end_point": {"row": 44, "column": 16}}, {"id": 104, "type": "update_expression", "text": "j--", "parent": 95, "children": [105, 106], "start_point": {"row": 44, "column": 19}, "end_point": {"row": 44, "column": 22}}, {"id": 105, "type": "identifier", "text": "j", "parent": 104, "children": [], "start_point": {"row": 44, "column": 19}, "end_point": {"row": 44, "column": 20}}, {"id": 106, "type": "--", "text": "--", "parent": 104, "children": [], "start_point": {"row": 44, "column": 20}, "end_point": {"row": 44, "column": 22}}, {"id": 107, "type": "if_statement", "text": "if((block->mask)[i] & (1<<j))\n\t\t\t{\n\t\t\t\t/*\n\t\t\t\t * This is a network bit (1). If we've already seen a\n\t\t\t\t * host bit (0), we need to bomb.\n\t\t\t\t */\n\t\t\t\tif(foundnmh==1)\n\t\t\t\t{\n\t\t\t\t\terrno = EINVAL;\n\t\t\t\t\treturn(-1);\n\t\t\t\t}\n\n\t\t\t\tpflen++;\n\t\t\t}\n\t\t\telse\n\t\t\t\tfoundnmh=1;", "parent": 95, "children": [108, 137], "start_point": {"row": 46, "column": 3}, "end_point": {"row": 61, "column": 15}}, {"id": 108, "type": "parenthesized_expression", "text": "((block->mask)[i] & (1<<j))", "parent": 107, "children": [109], "start_point": {"row": 46, "column": 5}, "end_point": {"row": 46, "column": 32}}, {"id": 109, "type": "binary_expression", "text": "(block->mask)[i] & (1<<j)", "parent": 108, "children": [110, 116], "start_point": {"row": 46, "column": 6}, "end_point": {"row": 46, "column": 31}}, {"id": 110, "type": "subscript_expression", "text": "(block->mask)[i]", "parent": 109, "children": [111, 115], "start_point": {"row": 46, "column": 6}, "end_point": {"row": 46, "column": 22}}, {"id": 111, "type": "parenthesized_expression", "text": "(block->mask)", "parent": 110, "children": [112], "start_point": {"row": 46, "column": 6}, "end_point": {"row": 46, "column": 19}}, {"id": 112, "type": "field_expression", "text": "block->mask", "parent": 111, "children": [113, 114], "start_point": {"row": 46, "column": 7}, "end_point": {"row": 46, "column": 18}}, {"id": 113, "type": "identifier", "text": "block", "parent": 112, "children": [], "start_point": {"row": 46, "column": 7}, "end_point": {"row": 46, "column": 12}}, {"id": 114, "type": "field_identifier", "text": "mask", "parent": 112, "children": [], "start_point": {"row": 46, "column": 14}, "end_point": {"row": 46, "column": 18}}, {"id": 115, "type": "identifier", "text": "i", "parent": 110, "children": [], "start_point": {"row": 46, "column": 20}, "end_point": {"row": 46, "column": 21}}, {"id": 116, "type": "parenthesized_expression", "text": "(1<<j)", "parent": 109, "children": [117], "start_point": {"row": 46, "column": 25}, "end_point": {"row": 46, "column": 31}}, {"id": 117, "type": "binary_expression", "text": "1<<j", "parent": 116, "children": [118, 119, 120], "start_point": {"row": 46, "column": 26}, "end_point": {"row": 46, "column": 30}}, {"id": 118, "type": "number_literal", "text": "1", "parent": 117, "children": [], "start_point": {"row": 46, "column": 26}, "end_point": {"row": 46, "column": 27}}, {"id": 119, "type": "<<", "text": "<<", "parent": 117, "children": [], "start_point": {"row": 46, "column": 27}, "end_point": {"row": 46, "column": 29}}, {"id": 120, "type": "identifier", "text": "j", "parent": 117, "children": [], "start_point": {"row": 46, "column": 29}, "end_point": {"row": 46, "column": 30}}, {"id": 121, "type": "if_statement", "text": "if(foundnmh==1)\n\t\t\t\t{\n\t\t\t\t\terrno = EINVAL;\n\t\t\t\t\treturn(-1);\n\t\t\t\t}", "parent": 107, "children": [122], "start_point": {"row": 52, "column": 4}, "end_point": {"row": 56, "column": 5}}, {"id": 122, "type": "parenthesized_expression", "text": "(foundnmh==1)", "parent": 121, "children": [123], "start_point": {"row": 52, "column": 6}, "end_point": {"row": 52, "column": 19}}, {"id": 123, "type": "binary_expression", "text": "foundnmh==1", "parent": 122, "children": [124, 125, 126], "start_point": {"row": 52, "column": 7}, "end_point": {"row": 52, "column": 18}}, {"id": 124, "type": "identifier", "text": "foundnmh", "parent": 123, "children": [], "start_point": {"row": 52, "column": 7}, "end_point": {"row": 52, "column": 15}}, {"id": 125, "type": "==", "text": "==", "parent": 123, "children": [], "start_point": {"row": 52, "column": 15}, "end_point": {"row": 52, "column": 17}}, {"id": 126, "type": "number_literal", "text": "1", "parent": 123, "children": [], "start_point": {"row": 52, "column": 17}, "end_point": {"row": 52, "column": 18}}, {"id": 127, "type": "assignment_expression", "text": "errno = EINVAL", "parent": 121, "children": [128, 129, 130], "start_point": {"row": 54, "column": 5}, "end_point": {"row": 54, "column": 19}}, {"id": 128, "type": "identifier", "text": "errno", "parent": 127, "children": [], "start_point": {"row": 54, "column": 5}, "end_point": {"row": 54, "column": 10}}, {"id": 129, "type": "=", "text": "=", "parent": 127, "children": [], "start_point": {"row": 54, "column": 11}, "end_point": {"row": 54, "column": 12}}, {"id": 130, "type": "identifier", "text": "EINVAL", "parent": 127, "children": [], "start_point": {"row": 54, "column": 13}, "end_point": {"row": 54, "column": 19}}, {"id": 131, "type": "return_statement", "text": "return(-1);", "parent": 121, "children": [132], "start_point": {"row": 55, "column": 5}, "end_point": {"row": 55, "column": 16}}, {"id": 132, "type": "parenthesized_expression", "text": "(-1)", "parent": 131, "children": [133], "start_point": {"row": 55, "column": 11}, "end_point": {"row": 55, "column": 15}}, {"id": 133, "type": "number_literal", "text": "-1", "parent": 132, "children": [], "start_point": {"row": 55, "column": 12}, "end_point": {"row": 55, "column": 14}}, {"id": 134, "type": "update_expression", "text": "pflen++", "parent": 107, "children": [135, 136], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 11}}, {"id": 135, "type": "identifier", "text": "pflen", "parent": 134, "children": [], "start_point": {"row": 58, "column": 4}, "end_point": {"row": 58, "column": 9}}, {"id": 136, "type": "++", "text": "++", "parent": 134, "children": [], "start_point": {"row": 58, "column": 9}, "end_point": {"row": 58, "column": 11}}, {"id": 137, "type": "else_clause", "text": "else\n\t\t\t\tfoundnmh=1;", "parent": 107, "children": [], "start_point": {"row": 60, "column": 3}, "end_point": {"row": 61, "column": 15}}, {"id": 138, "type": "assignment_expression", "text": "foundnmh=1", "parent": 137, "children": [139, 140, 141], "start_point": {"row": 61, "column": 4}, "end_point": {"row": 61, "column": 14}}, {"id": 139, "type": "identifier", "text": "foundnmh", "parent": 138, "children": [], "start_point": {"row": 61, "column": 4}, "end_point": {"row": 61, "column": 12}}, {"id": 140, "type": "=", "text": "=", "parent": 138, "children": [], "start_point": {"row": 61, "column": 12}, "end_point": {"row": 61, "column": 13}}, {"id": 141, "type": "number_literal", "text": "1", "parent": 138, "children": [], "start_point": {"row": 61, "column": 13}, "end_point": {"row": 61, "column": 14}}, {"id": 142, "type": "return_statement", "text": "return(pflen);", "parent": 12, "children": [143], "start_point": {"row": 66, "column": 1}, "end_point": {"row": 66, "column": 15}}, {"id": 143, "type": "parenthesized_expression", "text": "(pflen)", "parent": 142, "children": [144], "start_point": {"row": 66, "column": 7}, "end_point": {"row": 66, "column": 14}}, {"id": 144, "type": "identifier", "text": "pflen", "parent": 143, "children": [], "start_point": {"row": 66, "column": 8}, "end_point": {"row": 66, "column": 13}}, {"id": 145, "type": "function_definition", "text": "uint8_t *\ncidr_get_addr(const CIDR *addr)\n{\n\tuint8_t *toret;\n\n\tif(addr==NULL)\n\t{\n\t\terrno = EFAULT;\n\t\treturn(NULL);\n\t}\n\n\ttoret = malloc(16*sizeof(uint8_t));\n\tif(toret==NULL)\n\t{\n\t\terrno = ENOMEM;\n\t\treturn(NULL);\n\t}\n\n\t/* Copy 'em in */\n\tmemcpy(toret, addr->addr, sizeof(addr->addr));\n\n\treturn(toret);\n}", "parent": null, "children": [146, 147], "start_point": {"row": 71, "column": 0}, "end_point": {"row": 93, "column": 1}}, {"id": 146, "type": "primitive_type", "text": "uint8_t", "parent": 145, "children": [], "start_point": {"row": 71, "column": 0}, "end_point": {"row": 71, "column": 7}}, {"id": 147, "type": "pointer_declarator", "text": "*\ncidr_get_addr(const CIDR *addr)", "parent": 145, "children": [148, 149], "start_point": {"row": 71, "column": 8}, "end_point": {"row": 72, "column": 31}}, {"id": 148, "type": "*", "text": "*", "parent": 147, "children": [], "start_point": {"row": 71, "column": 8}, "end_point": {"row": 71, "column": 9}}, {"id": 149, "type": "function_declarator", "text": "cidr_get_addr(const CIDR *addr)", "parent": 147, "children": [150, 151], "start_point": {"row": 72, "column": 0}, "end_point": {"row": 72, "column": 31}}, {"id": 150, "type": "identifier", "text": "cidr_get_addr", "parent": 149, "children": [], "start_point": {"row": 72, "column": 0}, "end_point": {"row": 72, "column": 13}}, {"id": 151, "type": "parameter_list", "text": "(const CIDR *addr)", "parent": 149, "children": [152], "start_point": {"row": 72, "column": 13}, "end_point": {"row": 72, "column": 31}}, {"id": 152, "type": "parameter_declaration", "text": "const CIDR *addr", "parent": 151, "children": [153, 154], "start_point": {"row": 72, "column": 14}, "end_point": {"row": 72, "column": 30}}, {"id": 153, "type": "type_identifier", "text": "CIDR", "parent": 152, "children": [], "start_point": {"row": 72, "column": 20}, "end_point": {"row": 72, "column": 24}}, {"id": 154, "type": "pointer_declarator", "text": "*addr", "parent": 152, "children": [155, 156], "start_point": {"row": 72, "column": 25}, "end_point": {"row": 72, "column": 30}}, {"id": 155, "type": "*", "text": "*", "parent": 154, "children": [], "start_point": {"row": 72, "column": 25}, "end_point": {"row": 72, "column": 26}}, {"id": 156, "type": "identifier", "text": "addr", "parent": 154, "children": [], "start_point": {"row": 72, "column": 26}, "end_point": {"row": 72, "column": 30}}, {"id": 157, "type": "declaration", "text": "uint8_t *toret;", "parent": 145, "children": [158, 159], "start_point": {"row": 74, "column": 1}, "end_point": {"row": 74, "column": 16}}, {"id": 158, "type": "primitive_type", "text": "uint8_t", "parent": 157, "children": [], "start_point": {"row": 74, "column": 1}, "end_point": {"row": 74, "column": 8}}, {"id": 159, "type": "pointer_declarator", "text": "*toret", "parent": 157, "children": [160, 161], "start_point": {"row": 74, "column": 9}, "end_point": {"row": 74, "column": 15}}, {"id": 160, "type": "*", "text": "*", "parent": 159, "children": [], "start_point": {"row": 74, "column": 9}, "end_point": {"row": 74, "column": 10}}, {"id": 161, "type": "identifier", "text": "toret", "parent": 159, "children": [], "start_point": {"row": 74, "column": 10}, "end_point": {"row": 74, "column": 15}}, {"id": 162, "type": "if_statement", "text": "if(addr==NULL)\n\t{\n\t\terrno = EFAULT;\n\t\treturn(NULL);\n\t}", "parent": 145, "children": [163], "start_point": {"row": 76, "column": 1}, "end_point": {"row": 80, "column": 2}}, {"id": 163, "type": "parenthesized_expression", "text": "(addr==NULL)", "parent": 162, "children": [164], "start_point": {"row": 76, "column": 3}, "end_point": {"row": 76, "column": 15}}, {"id": 164, "type": "binary_expression", "text": "addr==NULL", "parent": 163, "children": [165, 166, 167], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 14}}, {"id": 165, "type": "identifier", "text": "addr", "parent": 164, "children": [], "start_point": {"row": 76, "column": 4}, "end_point": {"row": 76, "column": 8}}, {"id": 166, "type": "==", "text": "==", "parent": 164, "children": [], "start_point": {"row": 76, "column": 8}, "end_point": {"row": 76, "column": 10}}, {"id": 167, "type": "null", "text": "NULL", "parent": 164, "children": [168], "start_point": {"row": 76, "column": 10}, "end_point": {"row": 76, "column": 14}}, {"id": 168, "type": "NULL", "text": "NULL", "parent": 167, "children": [], "start_point": {"row": 76, "column": 10}, "end_point": {"row": 76, "column": 14}}, {"id": 169, "type": "assignment_expression", "text": "errno = EFAULT", "parent": 162, "children": [170, 171, 172], "start_point": {"row": 78, "column": 2}, "end_point": {"row": 78, "column": 16}}, {"id": 170, "type": "identifier", "text": "errno", "parent": 169, "children": [], "start_point": {"row": 78, "column": 2}, "end_point": {"row": 78, "column": 7}}, {"id": 171, "type": "=", "text": "=", "parent": 169, "children": [], "start_point": {"row": 78, "column": 8}, "end_point": {"row": 78, "column": 9}}, {"id": 172, "type": "identifier", "text": "EFAULT", "parent": 169, "children": [], "start_point": {"row": 78, "column": 10}, "end_point": {"row": 78, "column": 16}}, {"id": 173, "type": "return_statement", "text": "return(NULL);", "parent": 162, "children": [174], "start_point": {"row": 79, "column": 2}, "end_point": {"row": 79, "column": 15}}, {"id": 174, "type": "parenthesized_expression", "text": "(NULL)", "parent": 173, "children": [175], "start_point": {"row": 79, "column": 8}, "end_point": {"row": 79, "column": 14}}, {"id": 175, "type": "null", "text": "NULL", "parent": 174, "children": [176], "start_point": {"row": 79, "column": 9}, "end_point": {"row": 79, "column": 13}}, {"id": 176, "type": "NULL", "text": "NULL", "parent": 175, "children": [], "start_point": {"row": 79, "column": 9}, "end_point": {"row": 79, "column": 13}}, {"id": 177, "type": "assignment_expression", "text": "toret = malloc(16*sizeof(uint8_t))", "parent": 145, "children": [178, 179, 180], "start_point": {"row": 82, "column": 1}, "end_point": {"row": 82, "column": 35}}, {"id": 178, "type": "identifier", "text": "toret", "parent": 177, "children": [], "start_point": {"row": 82, "column": 1}, "end_point": {"row": 82, "column": 6}}, {"id": 179, "type": "=", "text": "=", "parent": 177, "children": [], "start_point": {"row": 82, "column": 7}, "end_point": {"row": 82, "column": 8}}, {"id": 180, "type": "call_expression", "text": "malloc(16*sizeof(uint8_t))", "parent": 177, "children": [181, 182], "start_point": {"row": 82, "column": 9}, "end_point": {"row": 82, "column": 35}}, {"id": 181, "type": "identifier", "text": "malloc", "parent": 180, "children": [], "start_point": {"row": 82, "column": 9}, "end_point": {"row": 82, "column": 15}}, {"id": 182, "type": "argument_list", "text": "(16*sizeof(uint8_t))", "parent": 180, "children": [183], "start_point": {"row": 82, "column": 15}, "end_point": {"row": 82, "column": 35}}, {"id": 183, "type": "binary_expression", "text": "16*sizeof(uint8_t)", "parent": 182, "children": [184, 185, 186], "start_point": {"row": 82, "column": 16}, "end_point": {"row": 82, "column": 34}}, {"id": 184, "type": "number_literal", "text": "16", "parent": 183, "children": [], "start_point": {"row": 82, "column": 16}, "end_point": {"row": 82, "column": 18}}, {"id": 185, "type": "*", "text": "*", "parent": 183, "children": [], "start_point": {"row": 82, "column": 18}, "end_point": {"row": 82, "column": 19}}, {"id": 186, "type": "sizeof_expression", "text": "sizeof(uint8_t)", "parent": 183, "children": [187], "start_point": {"row": 82, "column": 19}, "end_point": {"row": 82, "column": 34}}, {"id": 187, "type": "type_descriptor", "text": "uint8_t", "parent": 186, "children": [188], "start_point": {"row": 82, "column": 26}, "end_point": {"row": 82, "column": 33}}, {"id": 188, "type": "primitive_type", "text": "uint8_t", "parent": 187, "children": [], "start_point": {"row": 82, "column": 26}, "end_point": {"row": 82, "column": 33}}, {"id": 189, "type": "if_statement", "text": "if(toret==NULL)\n\t{\n\t\terrno = ENOMEM;\n\t\treturn(NULL);\n\t}", "parent": 145, "children": [190], "start_point": {"row": 83, "column": 1}, "end_point": {"row": 87, "column": 2}}, {"id": 190, "type": "parenthesized_expression", "text": "(toret==NULL)", "parent": 189, "children": [191], "start_point": {"row": 83, "column": 3}, "end_point": {"row": 83, "column": 16}}, {"id": 191, "type": "binary_expression", "text": "toret==NULL", "parent": 190, "children": [192, 193, 194], "start_point": {"row": 83, "column": 4}, "end_point": {"row": 83, "column": 15}}, {"id": 192, "type": "identifier", "text": "toret", "parent": 191, "children": [], "start_point": {"row": 83, "column": 4}, "end_point": {"row": 83, "column": 9}}, {"id": 193, "type": "==", "text": "==", "parent": 191, "children": [], "start_point": {"row": 83, "column": 9}, "end_point": {"row": 83, "column": 11}}, {"id": 194, "type": "null", "text": "NULL", "parent": 191, "children": [195], "start_point": {"row": 83, "column": 11}, "end_point": {"row": 83, "column": 15}}, {"id": 195, "type": "NULL", "text": "NULL", "parent": 194, "children": [], "start_point": {"row": 83, "column": 11}, "end_point": {"row": 83, "column": 15}}, {"id": 196, "type": "assignment_expression", "text": "errno = ENOMEM", "parent": 189, "children": [197, 198, 199], "start_point": {"row": 85, "column": 2}, "end_point": {"row": 85, "column": 16}}, {"id": 197, "type": "identifier", "text": "errno", "parent": 196, "children": [], "start_point": {"row": 85, "column": 2}, "end_point": {"row": 85, "column": 7}}, {"id": 198, "type": "=", "text": "=", "parent": 196, "children": [], "start_point": {"row": 85, "column": 8}, "end_point": {"row": 85, "column": 9}}, {"id": 199, "type": "identifier", "text": "ENOMEM", "parent": 196, "children": [], "start_point": {"row": 85, "column": 10}, "end_point": {"row": 85, "column": 16}}, {"id": 200, "type": "return_statement", "text": "return(NULL);", "parent": 189, "children": [201], "start_point": {"row": 86, "column": 2}, "end_point": {"row": 86, "column": 15}}, {"id": 201, "type": "parenthesized_expression", "text": "(NULL)", "parent": 200, "children": [202], "start_point": {"row": 86, "column": 8}, "end_point": {"row": 86, "column": 14}}, {"id": 202, "type": "null", "text": "NULL", "parent": 201, "children": [203], "start_point": {"row": 86, "column": 9}, "end_point": {"row": 86, "column": 13}}, {"id": 203, "type": "NULL", "text": "NULL", "parent": 202, "children": [], "start_point": {"row": 86, "column": 9}, "end_point": {"row": 86, "column": 13}}, {"id": 204, "type": "call_expression", "text": "memcpy(toret, addr->addr, sizeof(addr->addr))", "parent": 145, "children": [205, 206], "start_point": {"row": 90, "column": 1}, "end_point": {"row": 90, "column": 46}}, {"id": 205, "type": "identifier", "text": "memcpy", "parent": 204, "children": [], "start_point": {"row": 90, "column": 1}, "end_point": {"row": 90, "column": 7}}, {"id": 206, "type": "argument_list", "text": "(toret, addr->addr, sizeof(addr->addr))", "parent": 204, "children": [207, 208, 211], "start_point": {"row": 90, "column": 7}, "end_point": {"row": 90, "column": 46}}, {"id": 207, "type": "identifier", "text": "toret", "parent": 206, "children": [], "start_point": {"row": 90, "column": 8}, "end_point": {"row": 90, "column": 13}}, {"id": 208, "type": "field_expression", "text": "addr->addr", "parent": 206, "children": [209, 210], "start_point": {"row": 90, "column": 15}, "end_point": {"row": 90, "column": 25}}, {"id": 209, "type": "identifier", "text": "addr", "parent": 208, "children": [], "start_point": {"row": 90, "column": 15}, "end_point": {"row": 90, "column": 19}}, {"id": 210, "type": "field_identifier", "text": "addr", "parent": 208, "children": [], "start_point": {"row": 90, "column": 21}, "end_point": {"row": 90, "column": 25}}, {"id": 211, "type": "sizeof_expression", "text": "sizeof(addr->addr)", "parent": 206, "children": [212], "start_point": {"row": 90, "column": 27}, "end_point": {"row": 90, "column": 45}}, {"id": 212, "type": "parenthesized_expression", "text": "(addr->addr)", "parent": 211, "children": [213], "start_point": {"row": 90, "column": 33}, "end_point": {"row": 90, "column": 45}}, {"id": 213, "type": "field_expression", "text": "addr->addr", "parent": 212, "children": [214, 215], "start_point": {"row": 90, "column": 34}, "end_point": {"row": 90, "column": 44}}, {"id": 214, "type": "identifier", "text": "addr", "parent": 213, "children": [], "start_point": {"row": 90, "column": 34}, "end_point": {"row": 90, "column": 38}}, {"id": 215, "type": "field_identifier", "text": "addr", "parent": 213, "children": [], "start_point": {"row": 90, "column": 40}, "end_point": {"row": 90, "column": 44}}, {"id": 216, "type": "return_statement", "text": "return(toret);", "parent": 145, "children": [217], "start_point": {"row": 92, "column": 1}, "end_point": {"row": 92, "column": 15}}, {"id": 217, "type": "parenthesized_expression", "text": "(toret)", "parent": 216, "children": [218], "start_point": {"row": 92, "column": 7}, "end_point": {"row": 92, "column": 14}}, {"id": 218, "type": "identifier", "text": "toret", "parent": 217, "children": [], "start_point": {"row": 92, "column": 8}, "end_point": {"row": 92, "column": 13}}, {"id": 219, "type": "function_definition", "text": "uint8_t *\ncidr_get_mask(const CIDR *addr)\n{\n\tuint8_t *toret;\n\n\tif(addr==NULL)\n\t{\n\t\terrno = EFAULT;\n\t\treturn(NULL);\n\t}\n\n\ttoret = malloc(16*sizeof(uint8_t));\n\tif(toret==NULL)\n\t{\n\t\terrno = ENOMEM;\n\t\treturn(NULL);\n\t}\n\n\t/* Copy 'em in */\n\tmemcpy(toret, addr->mask, sizeof(addr->mask));\n\n\treturn(toret);\n}", "parent": null, "children": [220, 221], "start_point": {"row": 97, "column": 0}, "end_point": {"row": 119, "column": 1}}, {"id": 220, "type": "primitive_type", "text": "uint8_t", "parent": 219, "children": [], "start_point": {"row": 97, "column": 0}, "end_point": {"row": 97, "column": 7}}, {"id": 221, "type": "pointer_declarator", "text": "*\ncidr_get_mask(const CIDR *addr)", "parent": 219, "children": [222, 223], "start_point": {"row": 97, "column": 8}, "end_point": {"row": 98, "column": 31}}, {"id": 222, "type": "*", "text": "*", "parent": 221, "children": [], "start_point": {"row": 97, "column": 8}, "end_point": {"row": 97, "column": 9}}, {"id": 223, "type": "function_declarator", "text": "cidr_get_mask(const CIDR *addr)", "parent": 221, "children": [224, 225], "start_point": {"row": 98, "column": 0}, "end_point": {"row": 98, "column": 31}}, {"id": 224, "type": "identifier", "text": "cidr_get_mask", "parent": 223, "children": [], "start_point": {"row": 98, "column": 0}, "end_point": {"row": 98, "column": 13}}, {"id": 225, "type": "parameter_list", "text": "(const CIDR *addr)", "parent": 223, "children": [226], "start_point": {"row": 98, "column": 13}, "end_point": {"row": 98, "column": 31}}, {"id": 226, "type": "parameter_declaration", "text": "const CIDR *addr", "parent": 225, "children": [227, 228], "start_point": {"row": 98, "column": 14}, "end_point": {"row": 98, "column": 30}}, {"id": 227, "type": "type_identifier", "text": "CIDR", "parent": 226, "children": [], "start_point": {"row": 98, "column": 20}, "end_point": {"row": 98, "column": 24}}, {"id": 228, "type": "pointer_declarator", "text": "*addr", "parent": 226, "children": [229, 230], "start_point": {"row": 98, "column": 25}, "end_point": {"row": 98, "column": 30}}, {"id": 229, "type": "*", "text": "*", "parent": 228, "children": [], "start_point": {"row": 98, "column": 25}, "end_point": {"row": 98, "column": 26}}, {"id": 230, "type": "identifier", "text": "addr", "parent": 228, "children": [], "start_point": {"row": 98, "column": 26}, "end_point": {"row": 98, "column": 30}}, {"id": 231, "type": "declaration", "text": "uint8_t *toret;", "parent": 219, "children": [232, 233], "start_point": {"row": 100, "column": 1}, "end_point": {"row": 100, "column": 16}}, {"id": 232, "type": "primitive_type", "text": "uint8_t", "parent": 231, "children": [], "start_point": {"row": 100, "column": 1}, "end_point": {"row": 100, "column": 8}}, {"id": 233, "type": "pointer_declarator", "text": "*toret", "parent": 231, "children": [234, 235], "start_point": {"row": 100, "column": 9}, "end_point": {"row": 100, "column": 15}}, {"id": 234, "type": "*", "text": "*", "parent": 233, "children": [], "start_point": {"row": 100, "column": 9}, "end_point": {"row": 100, "column": 10}}, {"id": 235, "type": "identifier", "text": "toret", "parent": 233, "children": [], "start_point": {"row": 100, "column": 10}, "end_point": {"row": 100, "column": 15}}, {"id": 236, "type": "if_statement", "text": "if(addr==NULL)\n\t{\n\t\terrno = EFAULT;\n\t\treturn(NULL);\n\t}", "parent": 219, "children": [237], "start_point": {"row": 102, "column": 1}, "end_point": {"row": 106, "column": 2}}, {"id": 237, "type": "parenthesized_expression", "text": "(addr==NULL)", "parent": 236, "children": [238], "start_point": {"row": 102, "column": 3}, "end_point": {"row": 102, "column": 15}}, {"id": 238, "type": "binary_expression", "text": "addr==NULL", "parent": 237, "children": [239, 240, 241], "start_point": {"row": 102, "column": 4}, "end_point": {"row": 102, "column": 14}}, {"id": 239, "type": "identifier", "text": "addr", "parent": 238, "children": [], "start_point": {"row": 102, "column": 4}, "end_point": {"row": 102, "column": 8}}, {"id": 240, "type": "==", "text": "==", "parent": 238, "children": [], "start_point": {"row": 102, "column": 8}, "end_point": {"row": 102, "column": 10}}, {"id": 241, "type": "null", "text": "NULL", "parent": 238, "children": [242], "start_point": {"row": 102, "column": 10}, "end_point": {"row": 102, "column": 14}}, {"id": 242, "type": "NULL", "text": "NULL", "parent": 241, "children": [], "start_point": {"row": 102, "column": 10}, "end_point": {"row": 102, "column": 14}}, {"id": 243, "type": "assignment_expression", "text": "errno = EFAULT", "parent": 236, "children": [244, 245, 246], "start_point": {"row": 104, "column": 2}, "end_point": {"row": 104, "column": 16}}, {"id": 244, "type": "identifier", "text": "errno", "parent": 243, "children": [], "start_point": {"row": 104, "column": 2}, "end_point": {"row": 104, "column": 7}}, {"id": 245, "type": "=", "text": "=", "parent": 243, "children": [], "start_point": {"row": 104, "column": 8}, "end_point": {"row": 104, "column": 9}}, {"id": 246, "type": "identifier", "text": "EFAULT", "parent": 243, "children": [], "start_point": {"row": 104, "column": 10}, "end_point": {"row": 104, "column": 16}}, {"id": 247, "type": "return_statement", "text": "return(NULL);", "parent": 236, "children": [248], "start_point": {"row": 105, "column": 2}, "end_point": {"row": 105, "column": 15}}, {"id": 248, "type": "parenthesized_expression", "text": "(NULL)", "parent": 247, "children": [249], "start_point": {"row": 105, "column": 8}, "end_point": {"row": 105, "column": 14}}, {"id": 249, "type": "null", "text": "NULL", "parent": 248, "children": [250], "start_point": {"row": 105, "column": 9}, "end_point": {"row": 105, "column": 13}}, {"id": 250, "type": "NULL", "text": "NULL", "parent": 249, "children": [], "start_point": {"row": 105, "column": 9}, "end_point": {"row": 105, "column": 13}}, {"id": 251, "type": "assignment_expression", "text": "toret = malloc(16*sizeof(uint8_t))", "parent": 219, "children": [252, 253, 254], "start_point": {"row": 108, "column": 1}, "end_point": {"row": 108, "column": 35}}, {"id": 252, "type": "identifier", "text": "toret", "parent": 251, "children": [], "start_point": {"row": 108, "column": 1}, "end_point": {"row": 108, "column": 6}}, {"id": 253, "type": "=", "text": "=", "parent": 251, "children": [], "start_point": {"row": 108, "column": 7}, "end_point": {"row": 108, "column": 8}}, {"id": 254, "type": "call_expression", "text": "malloc(16*sizeof(uint8_t))", "parent": 251, "children": [255, 256], "start_point": {"row": 108, "column": 9}, "end_point": {"row": 108, "column": 35}}, {"id": 255, "type": "identifier", "text": "malloc", "parent": 254, "children": [], "start_point": {"row": 108, "column": 9}, "end_point": {"row": 108, "column": 15}}, {"id": 256, "type": "argument_list", "text": "(16*sizeof(uint8_t))", "parent": 254, "children": [257], "start_point": {"row": 108, "column": 15}, "end_point": {"row": 108, "column": 35}}, {"id": 257, "type": "binary_expression", "text": "16*sizeof(uint8_t)", "parent": 256, "children": [258, 259, 260], "start_point": {"row": 108, "column": 16}, "end_point": {"row": 108, "column": 34}}, {"id": 258, "type": "number_literal", "text": "16", "parent": 257, "children": [], "start_point": {"row": 108, "column": 16}, "end_point": {"row": 108, "column": 18}}, {"id": 259, "type": "*", "text": "*", "parent": 257, "children": [], "start_point": {"row": 108, "column": 18}, "end_point": {"row": 108, "column": 19}}, {"id": 260, "type": "sizeof_expression", "text": "sizeof(uint8_t)", "parent": 257, "children": [261], "start_point": {"row": 108, "column": 19}, "end_point": {"row": 108, "column": 34}}, {"id": 261, "type": "type_descriptor", "text": "uint8_t", "parent": 260, "children": [262], "start_point": {"row": 108, "column": 26}, "end_point": {"row": 108, "column": 33}}, {"id": 262, "type": "primitive_type", "text": "uint8_t", "parent": 261, "children": [], "start_point": {"row": 108, "column": 26}, "end_point": {"row": 108, "column": 33}}, {"id": 263, "type": "if_statement", "text": "if(toret==NULL)\n\t{\n\t\terrno = ENOMEM;\n\t\treturn(NULL);\n\t}", "parent": 219, "children": [264], "start_point": {"row": 109, "column": 1}, "end_point": {"row": 113, "column": 2}}, {"id": 264, "type": "parenthesized_expression", "text": "(toret==NULL)", "parent": 263, "children": [265], "start_point": {"row": 109, "column": 3}, "end_point": {"row": 109, "column": 16}}, {"id": 265, "type": "binary_expression", "text": "toret==NULL", "parent": 264, "children": [266, 267, 268], "start_point": {"row": 109, "column": 4}, "end_point": {"row": 109, "column": 15}}, {"id": 266, "type": "identifier", "text": "toret", "parent": 265, "children": [], "start_point": {"row": 109, "column": 4}, "end_point": {"row": 109, "column": 9}}, {"id": 267, "type": "==", "text": "==", "parent": 265, "children": [], "start_point": {"row": 109, "column": 9}, "end_point": {"row": 109, "column": 11}}, {"id": 268, "type": "null", "text": "NULL", "parent": 265, "children": [269], "start_point": {"row": 109, "column": 11}, "end_point": {"row": 109, "column": 15}}, {"id": 269, "type": "NULL", "text": "NULL", "parent": 268, "children": [], "start_point": {"row": 109, "column": 11}, "end_point": {"row": 109, "column": 15}}, {"id": 270, "type": "assignment_expression", "text": "errno = ENOMEM", "parent": 263, "children": [271, 272, 273], "start_point": {"row": 111, "column": 2}, "end_point": {"row": 111, "column": 16}}, {"id": 271, "type": "identifier", "text": "errno", "parent": 270, "children": [], "start_point": {"row": 111, "column": 2}, "end_point": {"row": 111, "column": 7}}, {"id": 272, "type": "=", "text": "=", "parent": 270, "children": [], "start_point": {"row": 111, "column": 8}, "end_point": {"row": 111, "column": 9}}, {"id": 273, "type": "identifier", "text": "ENOMEM", "parent": 270, "children": [], "start_point": {"row": 111, "column": 10}, "end_point": {"row": 111, "column": 16}}, {"id": 274, "type": "return_statement", "text": "return(NULL);", "parent": 263, "children": [275], "start_point": {"row": 112, "column": 2}, "end_point": {"row": 112, "column": 15}}, {"id": 275, "type": "parenthesized_expression", "text": "(NULL)", "parent": 274, "children": [276], "start_point": {"row": 112, "column": 8}, "end_point": {"row": 112, "column": 14}}, {"id": 276, "type": "null", "text": "NULL", "parent": 275, "children": [277], "start_point": {"row": 112, "column": 9}, "end_point": {"row": 112, "column": 13}}, {"id": 277, "type": "NULL", "text": "NULL", "parent": 276, "children": [], "start_point": {"row": 112, "column": 9}, "end_point": {"row": 112, "column": 13}}, {"id": 278, "type": "call_expression", "text": "memcpy(toret, addr->mask, sizeof(addr->mask))", "parent": 219, "children": [279, 280], "start_point": {"row": 116, "column": 1}, "end_point": {"row": 116, "column": 46}}, {"id": 279, "type": "identifier", "text": "memcpy", "parent": 278, "children": [], "start_point": {"row": 116, "column": 1}, "end_point": {"row": 116, "column": 7}}, {"id": 280, "type": "argument_list", "text": "(toret, addr->mask, sizeof(addr->mask))", "parent": 278, "children": [281, 282, 285], "start_point": {"row": 116, "column": 7}, "end_point": {"row": 116, "column": 46}}, {"id": 281, "type": "identifier", "text": "toret", "parent": 280, "children": [], "start_point": {"row": 116, "column": 8}, "end_point": {"row": 116, "column": 13}}, {"id": 282, "type": "field_expression", "text": "addr->mask", "parent": 280, "children": [283, 284], "start_point": {"row": 116, "column": 15}, "end_point": {"row": 116, "column": 25}}, {"id": 283, "type": "identifier", "text": "addr", "parent": 282, "children": [], "start_point": {"row": 116, "column": 15}, "end_point": {"row": 116, "column": 19}}, {"id": 284, "type": "field_identifier", "text": "mask", "parent": 282, "children": [], "start_point": {"row": 116, "column": 21}, "end_point": {"row": 116, "column": 25}}, {"id": 285, "type": "sizeof_expression", "text": "sizeof(addr->mask)", "parent": 280, "children": [286], "start_point": {"row": 116, "column": 27}, "end_point": {"row": 116, "column": 45}}, {"id": 286, "type": "parenthesized_expression", "text": "(addr->mask)", "parent": 285, "children": [287], "start_point": {"row": 116, "column": 33}, "end_point": {"row": 116, "column": 45}}, {"id": 287, "type": "field_expression", "text": "addr->mask", "parent": 286, "children": [288, 289], "start_point": {"row": 116, "column": 34}, "end_point": {"row": 116, "column": 44}}, {"id": 288, "type": "identifier", "text": "addr", "parent": 287, "children": [], "start_point": {"row": 116, "column": 34}, "end_point": {"row": 116, "column": 38}}, {"id": 289, "type": "field_identifier", "text": "mask", "parent": 287, "children": [], "start_point": {"row": 116, "column": 40}, "end_point": {"row": 116, "column": 44}}, {"id": 290, "type": "return_statement", "text": "return(toret);", "parent": 219, "children": [291], "start_point": {"row": 118, "column": 1}, "end_point": {"row": 118, "column": 15}}, {"id": 291, "type": "parenthesized_expression", "text": "(toret)", "parent": 290, "children": [292], "start_point": {"row": 118, "column": 7}, "end_point": {"row": 118, "column": 14}}, {"id": 292, "type": "identifier", "text": "toret", "parent": 291, "children": [], "start_point": {"row": 118, "column": 8}, "end_point": {"row": 118, "column": 13}}, {"id": 293, "type": "function_definition", "text": "int\ncidr_get_proto(const CIDR *addr)\n{\n\n\tif(addr==NULL)\n\t{\n\t\terrno = EFAULT;\n\t\treturn(-1);\n\t}\n\n\treturn(addr->proto);\n}", "parent": null, "children": [294, 295], "start_point": {"row": 123, "column": 0}, "end_point": {"row": 134, "column": 1}}, {"id": 294, "type": "primitive_type", "text": "int", "parent": 293, "children": [], "start_point": {"row": 123, "column": 0}, "end_point": {"row": 123, "column": 3}}, {"id": 295, "type": "function_declarator", "text": "cidr_get_proto(const CIDR *addr)", "parent": 293, "children": [296, 297], "start_point": {"row": 124, "column": 0}, "end_point": {"row": 124, "column": 32}}, {"id": 296, "type": "identifier", "text": "cidr_get_proto", "parent": 295, "children": [], "start_point": {"row": 124, "column": 0}, "end_point": {"row": 124, "column": 14}}, {"id": 297, "type": "parameter_list", "text": "(const CIDR *addr)", "parent": 295, "children": [298], "start_point": {"row": 124, "column": 14}, "end_point": {"row": 124, "column": 32}}, {"id": 298, "type": "parameter_declaration", "text": "const CIDR *addr", "parent": 297, "children": [299, 300], "start_point": {"row": 124, "column": 15}, "end_point": {"row": 124, "column": 31}}, {"id": 299, "type": "type_identifier", "text": "CIDR", "parent": 298, "children": [], "start_point": {"row": 124, "column": 21}, "end_point": {"row": 124, "column": 25}}, {"id": 300, "type": "pointer_declarator", "text": "*addr", "parent": 298, "children": [301, 302], "start_point": {"row": 124, "column": 26}, "end_point": {"row": 124, "column": 31}}, {"id": 301, "type": "*", "text": "*", "parent": 300, "children": [], "start_point": {"row": 124, "column": 26}, "end_point": {"row": 124, "column": 27}}, {"id": 302, "type": "identifier", "text": "addr", "parent": 300, "children": [], "start_point": {"row": 124, "column": 27}, "end_point": {"row": 124, "column": 31}}, {"id": 303, "type": "if_statement", "text": "if(addr==NULL)\n\t{\n\t\terrno = EFAULT;\n\t\treturn(-1);\n\t}", "parent": 293, "children": [304], "start_point": {"row": 127, "column": 1}, "end_point": {"row": 131, "column": 2}}, {"id": 304, "type": "parenthesized_expression", "text": "(addr==NULL)", "parent": 303, "children": [305], "start_point": {"row": 127, "column": 3}, "end_point": {"row": 127, "column": 15}}, {"id": 305, "type": "binary_expression", "text": "addr==NULL", "parent": 304, "children": [306, 307, 308], "start_point": {"row": 127, "column": 4}, "end_point": {"row": 127, "column": 14}}, {"id": 306, "type": "identifier", "text": "addr", "parent": 305, "children": [], "start_point": {"row": 127, "column": 4}, "end_point": {"row": 127, "column": 8}}, {"id": 307, "type": "==", "text": "==", "parent": 305, "children": [], "start_point": {"row": 127, "column": 8}, "end_point": {"row": 127, "column": 10}}, {"id": 308, "type": "null", "text": "NULL", "parent": 305, "children": [309], "start_point": {"row": 127, "column": 10}, "end_point": {"row": 127, "column": 14}}, {"id": 309, "type": "NULL", "text": "NULL", "parent": 308, "children": [], "start_point": {"row": 127, "column": 10}, "end_point": {"row": 127, "column": 14}}, {"id": 310, "type": "assignment_expression", "text": "errno = EFAULT", "parent": 303, "children": [311, 312, 313], "start_point": {"row": 129, "column": 2}, "end_point": {"row": 129, "column": 16}}, {"id": 311, "type": "identifier", "text": "errno", "parent": 310, "children": [], "start_point": {"row": 129, "column": 2}, "end_point": {"row": 129, "column": 7}}, {"id": 312, "type": "=", "text": "=", "parent": 310, "children": [], "start_point": {"row": 129, "column": 8}, "end_point": {"row": 129, "column": 9}}, {"id": 313, "type": "identifier", "text": "EFAULT", "parent": 310, "children": [], "start_point": {"row": 129, "column": 10}, "end_point": {"row": 129, "column": 16}}, {"id": 314, "type": "return_statement", "text": "return(-1);", "parent": 303, "children": [315], "start_point": {"row": 130, "column": 2}, "end_point": {"row": 130, "column": 13}}, {"id": 315, "type": "parenthesized_expression", "text": "(-1)", "parent": 314, "children": [316], "start_point": {"row": 130, "column": 8}, "end_point": {"row": 130, "column": 12}}, {"id": 316, "type": "number_literal", "text": "-1", "parent": 315, "children": [], "start_point": {"row": 130, "column": 9}, "end_point": {"row": 130, "column": 11}}, {"id": 317, "type": "return_statement", "text": "return(addr->proto);", "parent": 293, "children": [318], "start_point": {"row": 133, "column": 1}, "end_point": {"row": 133, "column": 21}}, {"id": 318, "type": "parenthesized_expression", "text": "(addr->proto)", "parent": 317, "children": [319], "start_point": {"row": 133, "column": 7}, "end_point": {"row": 133, "column": 20}}, {"id": 319, "type": "field_expression", "text": "addr->proto", "parent": 318, "children": [320, 321], "start_point": {"row": 133, "column": 8}, "end_point": {"row": 133, "column": 19}}, {"id": 320, "type": "identifier", "text": "addr", "parent": 319, "children": [], "start_point": {"row": 133, "column": 8}, "end_point": {"row": 133, "column": 12}}, {"id": 321, "type": "field_identifier", "text": "proto", "parent": 319, "children": [], "start_point": {"row": 133, "column": 14}, "end_point": {"row": 133, "column": 19}}]}, "node_categories": {"declarations": {"functions": [12, 14, 145, 149, 219, 223, 293, 295], "variables": [17, 22, 26, 29, 152, 157, 226, 231, 298], "classes": [], "imports": [0, 1, 3, 4, 6, 7, 9, 10], "modules": [], "enums": []}, "statements": {"expressions": [33, 34, 44, 47, 48, 49, 60, 61, 62, 77, 88, 92, 100, 104, 108, 109, 110, 111, 112, 116, 117, 122, 123, 132, 134, 143, 163, 164, 174, 180, 183, 186, 190, 191, 201, 204, 208, 211, 212, 213, 217, 237, 238, 248, 254, 257, 260, 264, 265, 275, 278, 282, 285, 286, 287, 291, 304, 305, 315, 318, 319], "assignments": [39, 54, 67, 72, 79, 83, 96, 127, 138, 169, 177, 196, 243, 251, 270, 310], "loops": [87, 95], "conditionals": [15, 18, 21, 24, 25, 28, 31, 32, 35, 40, 42, 46, 50, 51, 53, 55, 59, 63, 64, 66, 68, 73, 75, 80, 84, 89, 93, 97, 101, 105, 107, 113, 114, 115, 120, 121, 124, 128, 130, 135, 139, 144, 150, 153, 156, 161, 162, 165, 170, 172, 178, 181, 189, 192, 197, 199, 205, 207, 209, 210, 214, 215, 218, 224, 227, 230, 235, 236, 239, 244, 246, 252, 255, 263, 266, 271, 273, 279, 281, 283, 284, 288, 289, 292, 296, 299, 302, 303, 306, 311, 313, 320, 321], "returns": [43, 76, 131, 142, 173, 200, 216, 247, 274, 290, 314, 317], "exceptions": []}, "expressions": {"calls": [], "literals": [2, 5, 8, 11, 45, 57, 70, 78, 82, 86, 91, 99, 103, 118, 126, 133, 141, 184, 258, 316], "identifiers": [], "binary_operations": [], "unary_operations": [], "member_access": []}}, "cross_language_map": {"function_declarations": [{"node_id": 12, "universal_type": "function", "name": "cidr_get_pflen", "text_snippet": "int\ncidr_get_pflen(const CIDR *block)\n{\n\tint i, j;\n\tint foundnmh;\n\tint pflen;\n\n\tif(block==NULL)\n\t{\n\t"}, {"node_id": 14, "universal_type": "function", "name": "unknown", "text_snippet": "cidr_get_pflen(const CIDR *block)"}, {"node_id": 145, "universal_type": "function", "name": "unknown", "text_snippet": "uint8_t *\ncidr_get_addr(const CIDR *addr)\n{\n\tuint8_t *toret;\n\n\tif(addr==NULL)\n\t{\n\t\terrno = EFAULT;\n\t"}, {"node_id": 149, "universal_type": "function", "name": "unknown", "text_snippet": "cidr_get_addr(const CIDR *addr)"}, {"node_id": 219, "universal_type": "function", "name": "unknown", "text_snippet": "uint8_t *\ncidr_get_mask(const CIDR *addr)\n{\n\tuint8_t *toret;\n\n\tif(addr==NULL)\n\t{\n\t\terrno = EFAULT;\n\t"}, {"node_id": 223, "universal_type": "function", "name": "unknown", "text_snippet": "cidr_get_mask(const CIDR *addr)"}, {"node_id": 293, "universal_type": "function", "name": "cidr_get_proto", "text_snippet": "int\ncidr_get_proto(const CIDR *addr)\n{\n\n\tif(addr==NULL)\n\t{\n\t\terrno = EFAULT;\n\t\treturn(-1);\n\t}\n\n\tretu"}, {"node_id": 295, "universal_type": "function", "name": "unknown", "text_snippet": "cidr_get_proto(const CIDR *addr)"}], "class_declarations": [], "import_statements": [{"node_id": 0, "text": "#include <errno.h>\n"}, {"node_id": 1, "text": "#include"}, {"node_id": 3, "text": "#include <stdlib.h>\n"}, {"node_id": 4, "text": "#include"}, {"node_id": 6, "text": "#include <string.h>\n"}, {"node_id": 7, "text": "#include"}, {"node_id": 9, "text": "#include <libcidr.h>\n"}, {"node_id": 10, "text": "#include"}]}, "original_source_code": "/*\n * cidr_get - Get and return various semi-raw bits of info\n */\n\n#include <errno.h>\n#include <stdlib.h>\n#include <string.h>\n\n#include <libcidr.h>\n\n\n/* Get the prefix length */\nint\ncidr_get_pflen(const CIDR *block)\n{\n\tint i, j;\n\tint foundnmh;\n\tint pflen;\n\n\tif(block==NULL)\n\t{\n\t\terrno = EFAULT;\n\t\treturn(-1);\n\t}\n\n\t/* Where do we start? */\n\tif(block->proto==CIDR_IPV4)\n\t\ti=12;\n\telse if(block->proto==CIDR_IPV6)\n\t\ti=0;\n\telse\n\t{\n\t\terrno = ENOENT; /* Bad errno */\n\t\treturn(-1); /* Unknown */\n\t}\n\n\t/*\n\t * We're intentionally not supporting non-contiguous netmasks. So,\n\t * if we find one, bomb out.\n\t */\n\tfoundnmh=0;\n\tpflen=0;\n\tfor(/* i */ ; i<=15 ; i++)\n\t{\n\t\tfor(j=7 ; j>=0 ; j--)\n\t\t{\n\t\t\tif((block->mask)[i] & (1<<j))\n\t\t\t{\n\t\t\t\t/*\n\t\t\t\t * This is a network bit (1). If we've already seen a\n\t\t\t\t * host bit (0), we need to bomb.\n\t\t\t\t */\n\t\t\t\tif(foundnmh==1)\n\t\t\t\t{\n\t\t\t\t\terrno = EINVAL;\n\t\t\t\t\treturn(-1);\n\t\t\t\t}\n\n\t\t\t\tpflen++;\n\t\t\t}\n\t\t\telse\n\t\t\t\tfoundnmh=1; /* A host bit */\n\t\t}\n\t}\n\n\t/* If we get here, return the length */\n\treturn(pflen);\n}\n\n\n/* Get the address bits */\nuint8_t *\ncidr_get_addr(const CIDR *addr)\n{\n\tuint8_t *toret;\n\n\tif(addr==NULL)\n\t{\n\t\terrno = EFAULT;\n\t\treturn(NULL);\n\t}\n\n\ttoret = malloc(16*sizeof(uint8_t));\n\tif(toret==NULL)\n\t{\n\t\terrno = ENOMEM;\n\t\treturn(NULL);\n\t}\n\n\t/* Copy 'em in */\n\tmemcpy(toret, addr->addr, sizeof(addr->addr));\n\n\treturn(toret);\n}\n\n\n/* Get the netmask bits */\nuint8_t *\ncidr_get_mask(const CIDR *addr)\n{\n\tuint8_t *toret;\n\n\tif(addr==NULL)\n\t{\n\t\terrno = EFAULT;\n\t\treturn(NULL);\n\t}\n\n\ttoret = malloc(16*sizeof(uint8_t));\n\tif(toret==NULL)\n\t{\n\t\terrno = ENOMEM;\n\t\treturn(NULL);\n\t}\n\n\t/* Copy 'em in */\n\tmemcpy(toret, addr->mask, sizeof(addr->mask));\n\n\treturn(toret);\n}\n\n\n/* Get the protocol */\nint\ncidr_get_proto(const CIDR *addr)\n{\n\n\tif(addr==NULL)\n\t{\n\t\terrno = EFAULT;\n\t\treturn(-1);\n\t}\n\n\treturn(addr->proto);\n}\n"}
80,599