2022-12-04 00:07:26 +03:00
|
|
|
|
#include <tree_sitter/parser.h>
|
|
|
|
|
|
|
|
|
|
#if defined(__GNUC__) || defined(__clang__)
|
|
|
|
|
#pragma GCC diagnostic push
|
|
|
|
|
#pragma GCC diagnostic ignored "-Wmissing-field-initializers"
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#define LANGUAGE_VERSION 14
|
2022-12-09 15:02:21 +03:00
|
|
|
|
#define STATE_COUNT 105
|
2022-12-09 14:09:39 +03:00
|
|
|
|
#define LARGE_STATE_COUNT 2
|
|
|
|
|
#define SYMBOL_COUNT 80
|
2022-12-09 12:36:31 +03:00
|
|
|
|
#define ALIAS_COUNT 1
|
2022-12-09 14:09:39 +03:00
|
|
|
|
#define TOKEN_COUNT 42
|
2022-12-04 18:35:37 +03:00
|
|
|
|
#define EXTERNAL_TOKEN_COUNT 0
|
2022-12-04 03:21:42 +03:00
|
|
|
|
#define FIELD_COUNT 0
|
2022-12-09 14:09:39 +03:00
|
|
|
|
#define MAX_ALIAS_SEQUENCE_LENGTH 5
|
2022-12-08 01:15:09 +03:00
|
|
|
|
#define PRODUCTION_ID_COUNT 3
|
2022-12-04 00:07:26 +03:00
|
|
|
|
|
|
|
|
|
enum {
|
2022-12-09 12:36:31 +03:00
|
|
|
|
sym__identifier = 1,
|
2022-12-09 14:09:39 +03:00
|
|
|
|
anon_sym_ = 2,
|
|
|
|
|
anon_sym_LBRACE = 3,
|
|
|
|
|
anon_sym_RBRACE = 4,
|
|
|
|
|
anon_sym_direction = 5,
|
|
|
|
|
anon_sym_shape = 6,
|
|
|
|
|
anon_sym_label = 7,
|
|
|
|
|
anon_sym_constraint = 8,
|
|
|
|
|
anon_sym_icon = 9,
|
|
|
|
|
anon_sym_style = 10,
|
|
|
|
|
anon_sym_width = 11,
|
|
|
|
|
anon_sym_height = 12,
|
|
|
|
|
anon_sym_3d = 13,
|
|
|
|
|
anon_sym_opacity = 14,
|
|
|
|
|
anon_sym_fill = 15,
|
|
|
|
|
anon_sym_stroke = 16,
|
|
|
|
|
anon_sym_stroke_DASHwidth = 17,
|
|
|
|
|
anon_sym_stroke_DASHdash = 18,
|
|
|
|
|
anon_sym_border_DASHradius = 19,
|
|
|
|
|
anon_sym_font_DASHcolor = 20,
|
|
|
|
|
anon_sym_shadow = 21,
|
|
|
|
|
anon_sym_multiple = 22,
|
|
|
|
|
anon_sym_animated = 23,
|
|
|
|
|
anon_sym_link = 24,
|
|
|
|
|
sym__text_attr_key = 25,
|
|
|
|
|
anon_sym_source_DASHarrowhead = 26,
|
|
|
|
|
anon_sym_target_DASHarrowhead = 27,
|
|
|
|
|
sym__dash = 28,
|
|
|
|
|
anon_sym_COLON = 29,
|
|
|
|
|
sym_arrow = 30,
|
|
|
|
|
sym_dot = 31,
|
|
|
|
|
sym__unquoted_string = 32,
|
|
|
|
|
anon_sym_SQUOTE = 33,
|
|
|
|
|
aux_sym_string_token1 = 34,
|
|
|
|
|
anon_sym_DQUOTE = 35,
|
|
|
|
|
aux_sym_string_token2 = 36,
|
|
|
|
|
anon_sym_BQUOTE = 37,
|
|
|
|
|
aux_sym_string_token3 = 38,
|
|
|
|
|
sym_line_comment = 39,
|
|
|
|
|
sym__eol = 40,
|
|
|
|
|
anon_sym_SEMI = 41,
|
|
|
|
|
sym_source_file = 42,
|
|
|
|
|
sym__root_definition = 43,
|
|
|
|
|
sym_connection = 44,
|
|
|
|
|
sym__connection_path = 45,
|
|
|
|
|
sym__connection_block = 46,
|
|
|
|
|
sym__connection_block_definition = 47,
|
|
|
|
|
sym_container = 48,
|
|
|
|
|
sym__container_block = 49,
|
|
|
|
|
sym__container_block_definition = 50,
|
|
|
|
|
sym_shape = 51,
|
|
|
|
|
sym_shape_key = 52,
|
|
|
|
|
sym__root_attribute = 53,
|
|
|
|
|
sym__root_attr_key = 54,
|
|
|
|
|
sym__shape_attribute = 55,
|
|
|
|
|
sym__base_shape_attribute = 56,
|
|
|
|
|
sym__shape_attr_key = 57,
|
|
|
|
|
sym__style_attribute = 58,
|
|
|
|
|
sym__style_attribute_block = 59,
|
|
|
|
|
sym__inner_style_attribute = 60,
|
|
|
|
|
sym__style_attr_key = 61,
|
|
|
|
|
sym__common_style_attr_key = 62,
|
|
|
|
|
sym__connection_attribute = 63,
|
|
|
|
|
sym__connection_arrowhead_attribute = 64,
|
|
|
|
|
sym__connection_arrowhead_attr_key = 65,
|
|
|
|
|
sym_label = 66,
|
|
|
|
|
sym_attr_value = 67,
|
|
|
|
|
sym__colon = 68,
|
|
|
|
|
sym_string = 69,
|
|
|
|
|
sym__end = 70,
|
|
|
|
|
aux_sym_source_file_repeat1 = 71,
|
|
|
|
|
aux_sym_connection_repeat1 = 72,
|
|
|
|
|
aux_sym__connection_path_repeat1 = 73,
|
|
|
|
|
aux_sym__connection_block_repeat1 = 74,
|
|
|
|
|
aux_sym__container_block_repeat1 = 75,
|
|
|
|
|
aux_sym__style_attribute_block_repeat1 = 76,
|
|
|
|
|
aux_sym_string_repeat1 = 77,
|
|
|
|
|
aux_sym_string_repeat2 = 78,
|
|
|
|
|
aux_sym_string_repeat3 = 79,
|
|
|
|
|
alias_sym_container_key = 80,
|
2022-12-04 00:07:26 +03:00
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
static const char * const ts_symbol_names[] = {
|
|
|
|
|
[ts_builtin_sym_end] = "end",
|
2022-12-09 12:36:31 +03:00
|
|
|
|
[sym__identifier] = "_identifier",
|
2022-12-09 14:09:39 +03:00
|
|
|
|
[anon_sym_] = " |