@herb-tools/node 0.7.5 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (117) hide show
  1. package/binding.gyp +8 -4
  2. package/dist/herb-node.esm.js +6 -6
  3. package/dist/herb-node.esm.js.map +1 -1
  4. package/extension/error_helpers.cpp +67 -9
  5. package/extension/error_helpers.h +4 -2
  6. package/extension/extension_helpers.cpp +12 -5
  7. package/extension/extension_helpers.h +4 -2
  8. package/extension/herb.cpp +10 -42
  9. package/extension/libherb/analyze.c +420 -171
  10. package/extension/libherb/analyze.h +10 -2
  11. package/extension/libherb/analyze_helpers.c +5 -0
  12. package/extension/libherb/analyze_helpers.h +3 -0
  13. package/extension/libherb/analyze_missing_end.c +147 -0
  14. package/extension/libherb/analyze_transform.c +196 -0
  15. package/extension/libherb/analyzed_ruby.c +23 -2
  16. package/extension/libherb/analyzed_ruby.h +4 -2
  17. package/extension/libherb/ast_node.c +5 -5
  18. package/extension/libherb/ast_node.h +2 -2
  19. package/extension/libherb/ast_nodes.c +180 -180
  20. package/extension/libherb/ast_nodes.h +68 -67
  21. package/extension/libherb/ast_pretty_print.c +233 -233
  22. package/extension/libherb/ast_pretty_print.h +3 -3
  23. package/extension/libherb/element_source.c +7 -6
  24. package/extension/libherb/element_source.h +3 -1
  25. package/extension/libherb/errors.c +247 -127
  26. package/extension/libherb/errors.h +31 -15
  27. package/extension/libherb/extract.c +92 -34
  28. package/extension/libherb/extract.h +4 -4
  29. package/extension/libherb/herb.c +37 -49
  30. package/extension/libherb/herb.h +6 -7
  31. package/extension/libherb/html_util.c +34 -96
  32. package/extension/libherb/html_util.h +4 -5
  33. package/extension/libherb/include/analyze.h +10 -2
  34. package/extension/libherb/include/analyze_helpers.h +3 -0
  35. package/extension/libherb/include/analyzed_ruby.h +4 -2
  36. package/extension/libherb/include/ast_node.h +2 -2
  37. package/extension/libherb/include/ast_nodes.h +68 -67
  38. package/extension/libherb/include/ast_pretty_print.h +3 -3
  39. package/extension/libherb/include/element_source.h +3 -1
  40. package/extension/libherb/include/errors.h +31 -15
  41. package/extension/libherb/include/extract.h +4 -4
  42. package/extension/libherb/include/herb.h +6 -7
  43. package/extension/libherb/include/html_util.h +4 -5
  44. package/extension/libherb/include/lexer.h +1 -3
  45. package/extension/libherb/include/lexer_peek_helpers.h +14 -14
  46. package/extension/libherb/include/lexer_struct.h +3 -2
  47. package/extension/libherb/include/macros.h +4 -0
  48. package/extension/libherb/include/parser.h +12 -6
  49. package/extension/libherb/include/parser_helpers.h +25 -15
  50. package/extension/libherb/include/pretty_print.h +38 -28
  51. package/extension/libherb/include/token.h +5 -8
  52. package/extension/libherb/include/utf8.h +3 -2
  53. package/extension/libherb/include/util/hb_arena.h +31 -0
  54. package/extension/libherb/include/util/hb_arena_debug.h +8 -0
  55. package/extension/libherb/include/util/hb_array.h +33 -0
  56. package/extension/libherb/include/util/hb_buffer.h +34 -0
  57. package/extension/libherb/include/util/hb_string.h +29 -0
  58. package/extension/libherb/include/util/hb_system.h +9 -0
  59. package/extension/libherb/include/util.h +3 -14
  60. package/extension/libherb/include/version.h +1 -1
  61. package/extension/libherb/include/visitor.h +1 -1
  62. package/extension/libherb/io.c +7 -4
  63. package/extension/libherb/lexer.c +61 -88
  64. package/extension/libherb/lexer.h +1 -3
  65. package/extension/libherb/lexer_peek_helpers.c +35 -37
  66. package/extension/libherb/lexer_peek_helpers.h +14 -14
  67. package/extension/libherb/lexer_struct.h +3 -2
  68. package/extension/libherb/macros.h +4 -0
  69. package/extension/libherb/main.c +19 -23
  70. package/extension/libherb/parser.c +282 -201
  71. package/extension/libherb/parser.h +12 -6
  72. package/extension/libherb/parser_helpers.c +46 -40
  73. package/extension/libherb/parser_helpers.h +25 -15
  74. package/extension/libherb/parser_match_tags.c +316 -0
  75. package/extension/libherb/pretty_print.c +82 -106
  76. package/extension/libherb/pretty_print.h +38 -28
  77. package/extension/libherb/token.c +18 -65
  78. package/extension/libherb/token.h +5 -8
  79. package/extension/libherb/utf8.c +4 -4
  80. package/extension/libherb/utf8.h +3 -2
  81. package/extension/libherb/util/hb_arena.c +179 -0
  82. package/extension/libherb/util/hb_arena.h +31 -0
  83. package/extension/libherb/util/hb_arena_debug.c +237 -0
  84. package/extension/libherb/util/hb_arena_debug.h +8 -0
  85. package/extension/libherb/{array.c → util/hb_array.c} +26 -27
  86. package/extension/libherb/util/hb_array.h +33 -0
  87. package/extension/libherb/util/hb_buffer.c +203 -0
  88. package/extension/libherb/util/hb_buffer.h +34 -0
  89. package/extension/libherb/util/hb_string.c +85 -0
  90. package/extension/libherb/util/hb_string.h +29 -0
  91. package/extension/libherb/util/hb_system.c +30 -0
  92. package/extension/libherb/util/hb_system.h +9 -0
  93. package/extension/libherb/util.c +29 -99
  94. package/extension/libherb/util.h +3 -14
  95. package/extension/libherb/version.h +1 -1
  96. package/extension/libherb/visitor.c +55 -55
  97. package/extension/libherb/visitor.h +1 -1
  98. package/extension/nodes.cpp +40 -40
  99. package/extension/nodes.h +2 -2
  100. package/extension/prism/include/prism/ast.h +31 -1
  101. package/extension/prism/include/prism/diagnostic.h +1 -0
  102. package/extension/prism/include/prism/version.h +3 -3
  103. package/extension/prism/src/diagnostic.c +3 -1
  104. package/extension/prism/src/prism.c +130 -71
  105. package/extension/prism/src/util/pm_string.c +6 -8
  106. package/package.json +3 -3
  107. package/extension/libherb/array.h +0 -33
  108. package/extension/libherb/buffer.c +0 -241
  109. package/extension/libherb/buffer.h +0 -39
  110. package/extension/libherb/include/array.h +0 -33
  111. package/extension/libherb/include/buffer.h +0 -39
  112. package/extension/libherb/include/json.h +0 -28
  113. package/extension/libherb/include/memory.h +0 -12
  114. package/extension/libherb/json.c +0 -205
  115. package/extension/libherb/json.h +0 -28
  116. package/extension/libherb/memory.c +0 -53
  117. package/extension/libherb/memory.h +0 -12
@@ -1,5 +1,5 @@
1
1
  // NOTE: This file is generated by the templates/template.rb script and should not
2
- // be modified manually. See /Users/marcoroth/Development/herb-release-0.7.5/templates/src/include/ast_nodes.h.erb
2
+ // be modified manually. See /Users/marcoroth/Development/herb-release-0.8.0/templates/src/include/ast_nodes.h.erb
3
3
 
4
4
  #ifndef HERB_AST_NODES_H
5
5
  #define HERB_AST_NODES_H
@@ -7,13 +7,14 @@
7
7
  #include <stdbool.h>
8
8
  #include <prism.h>
9
9
 
10
- #include "array.h"
11
- #include "buffer.h"
12
- #include "position.h"
13
- #include "location.h"
14
- #include "token_struct.h"
15
10
  #include "analyzed_ruby.h"
16
11
  #include "element_source.h"
12
+ #include "location.h"
13
+ #include "position.h"
14
+ #include "token_struct.h"
15
+ #include "util/hb_array.h"
16
+ #include "util/hb_buffer.h"
17
+ #include "util/hb_string.h"
17
18
 
18
19
  typedef enum {
19
20
  AST_DOCUMENT_NODE,
@@ -53,13 +54,13 @@ typedef struct AST_NODE_STRUCT {
53
54
  ast_node_type_T type;
54
55
  location_T location;
55
56
  // maybe a range too?
56
- array_T* errors;
57
+ hb_array_T* errors;
57
58
  } AST_NODE_T;
58
59
 
59
60
 
60
61
  typedef struct AST_DOCUMENT_NODE_STRUCT {
61
62
  AST_NODE_T base;
62
- array_T* children;
63
+ hb_array_T* children;
63
64
  } AST_DOCUMENT_NODE_T;
64
65
 
65
66
  typedef struct AST_LITERAL_NODE_STRUCT {
@@ -72,7 +73,7 @@ typedef struct AST_HTML_OPEN_TAG_NODE_STRUCT {
72
73
  token_T* tag_opening;
73
74
  token_T* tag_name;
74
75
  token_T* tag_closing;
75
- array_T* children;
76
+ hb_array_T* children;
76
77
  bool is_void;
77
78
  } AST_HTML_OPEN_TAG_NODE_T;
78
79
 
@@ -80,7 +81,7 @@ typedef struct AST_HTML_CLOSE_TAG_NODE_STRUCT {
80
81
  AST_NODE_T base;
81
82
  token_T* tag_opening;
82
83
  token_T* tag_name;
83
- array_T* children;
84
+ hb_array_T* children;
84
85
  token_T* tag_closing;
85
86
  } AST_HTML_CLOSE_TAG_NODE_T;
86
87
 
@@ -88,7 +89,7 @@ typedef struct AST_HTML_ELEMENT_NODE_STRUCT {
88
89
  AST_NODE_T base;
89
90
  struct AST_HTML_OPEN_TAG_NODE_STRUCT* open_tag;
90
91
  token_T* tag_name;
91
- array_T* body;
92
+ hb_array_T* body;
92
93
  struct AST_HTML_CLOSE_TAG_NODE_STRUCT* close_tag;
93
94
  bool is_void;
94
95
  element_source_t source;
@@ -97,14 +98,14 @@ typedef struct AST_HTML_ELEMENT_NODE_STRUCT {
97
98
  typedef struct AST_HTML_ATTRIBUTE_VALUE_NODE_STRUCT {
98
99
  AST_NODE_T base;
99
100
  token_T* open_quote;
100
- array_T* children;
101
+ hb_array_T* children;
101
102
  token_T* close_quote;
102
103
  bool quoted;
103
104
  } AST_HTML_ATTRIBUTE_VALUE_NODE_T;
104
105
 
105
106
  typedef struct AST_HTML_ATTRIBUTE_NAME_NODE_STRUCT {
106
107
  AST_NODE_T base;
107
- array_T* children;
108
+ hb_array_T* children;
108
109
  } AST_HTML_ATTRIBUTE_NAME_NODE_T;
109
110
 
110
111
  typedef struct AST_HTML_ATTRIBUTE_NODE_STRUCT {
@@ -122,28 +123,28 @@ typedef struct AST_HTML_TEXT_NODE_STRUCT {
122
123
  typedef struct AST_HTML_COMMENT_NODE_STRUCT {
123
124
  AST_NODE_T base;
124
125
  token_T* comment_start;
125
- array_T* children;
126
+ hb_array_T* children;
126
127
  token_T* comment_end;
127
128
  } AST_HTML_COMMENT_NODE_T;
128
129
 
129
130
  typedef struct AST_HTML_DOCTYPE_NODE_STRUCT {
130
131
  AST_NODE_T base;
131
132
  token_T* tag_opening;
132
- array_T* children;
133
+ hb_array_T* children;
133
134
  token_T* tag_closing;
134
135
  } AST_HTML_DOCTYPE_NODE_T;
135
136
 
136
137
  typedef struct AST_XML_DECLARATION_NODE_STRUCT {
137
138
  AST_NODE_T base;
138
139
  token_T* tag_opening;
139
- array_T* children;
140
+ hb_array_T* children;
140
141
  token_T* tag_closing;
141
142
  } AST_XML_DECLARATION_NODE_T;
142
143
 
143
144
  typedef struct AST_CDATA_NODE_STRUCT {
144
145
  AST_NODE_T base;
145
146
  token_T* tag_opening;
146
- array_T* children;
147
+ hb_array_T* children;
147
148
  token_T* tag_closing;
148
149
  } AST_CDATA_NODE_T;
149
150
 
@@ -174,7 +175,7 @@ typedef struct AST_ERB_ELSE_NODE_STRUCT {
174
175
  token_T* tag_opening;
175
176
  token_T* content;
176
177
  token_T* tag_closing;
177
- array_T* statements;
178
+ hb_array_T* statements;
178
179
  } AST_ERB_ELSE_NODE_T;
179
180
 
180
181
  typedef struct AST_ERB_IF_NODE_STRUCT {
@@ -182,7 +183,7 @@ typedef struct AST_ERB_IF_NODE_STRUCT {
182
183
  token_T* tag_opening;
183
184
  token_T* content;
184
185
  token_T* tag_closing;
185
- array_T* statements;
186
+ hb_array_T* statements;
186
187
  struct AST_NODE_STRUCT* subsequent;
187
188
  struct AST_ERB_END_NODE_STRUCT* end_node;
188
189
  } AST_ERB_IF_NODE_T;
@@ -192,7 +193,7 @@ typedef struct AST_ERB_BLOCK_NODE_STRUCT {
192
193
  token_T* tag_opening;
193
194
  token_T* content;
194
195
  token_T* tag_closing;
195
- array_T* body;
196
+ hb_array_T* body;
196
197
  struct AST_ERB_END_NODE_STRUCT* end_node;
197
198
  } AST_ERB_BLOCK_NODE_T;
198
199
 
@@ -201,7 +202,7 @@ typedef struct AST_ERB_WHEN_NODE_STRUCT {
201
202
  token_T* tag_opening;
202
203
  token_T* content;
203
204
  token_T* tag_closing;
204
- array_T* statements;
205
+ hb_array_T* statements;
205
206
  } AST_ERB_WHEN_NODE_T;
206
207
 
207
208
  typedef struct AST_ERB_CASE_NODE_STRUCT {
@@ -209,8 +210,8 @@ typedef struct AST_ERB_CASE_NODE_STRUCT {
209
210
  token_T* tag_opening;
210
211
  token_T* content;
211
212
  token_T* tag_closing;
212
- array_T* children;
213
- array_T* conditions;
213
+ hb_array_T* children;
214
+ hb_array_T* conditions;
214
215
  struct AST_ERB_ELSE_NODE_STRUCT* else_clause;
215
216
  struct AST_ERB_END_NODE_STRUCT* end_node;
216
217
  } AST_ERB_CASE_NODE_T;
@@ -220,8 +221,8 @@ typedef struct AST_ERB_CASE_MATCH_NODE_STRUCT {
220
221
  token_T* tag_opening;
221
222
  token_T* content;
222
223
  token_T* tag_closing;
223
- array_T* children;
224
- array_T* conditions;
224
+ hb_array_T* children;
225
+ hb_array_T* conditions;
225
226
  struct AST_ERB_ELSE_NODE_STRUCT* else_clause;
226
227
  struct AST_ERB_END_NODE_STRUCT* end_node;
227
228
  } AST_ERB_CASE_MATCH_NODE_T;
@@ -231,7 +232,7 @@ typedef struct AST_ERB_WHILE_NODE_STRUCT {
231
232
  token_T* tag_opening;
232
233
  token_T* content;
233
234
  token_T* tag_closing;
234
- array_T* statements;
235
+ hb_array_T* statements;
235
236
  struct AST_ERB_END_NODE_STRUCT* end_node;
236
237
  } AST_ERB_WHILE_NODE_T;
237
238
 
@@ -240,7 +241,7 @@ typedef struct AST_ERB_UNTIL_NODE_STRUCT {
240
241
  token_T* tag_opening;
241
242
  token_T* content;
242
243
  token_T* tag_closing;
243
- array_T* statements;
244
+ hb_array_T* statements;
244
245
  struct AST_ERB_END_NODE_STRUCT* end_node;
245
246
  } AST_ERB_UNTIL_NODE_T;
246
247
 
@@ -249,7 +250,7 @@ typedef struct AST_ERB_FOR_NODE_STRUCT {
249
250
  token_T* tag_opening;
250
251
  token_T* content;
251
252
  token_T* tag_closing;
252
- array_T* statements;
253
+ hb_array_T* statements;
253
254
  struct AST_ERB_END_NODE_STRUCT* end_node;
254
255
  } AST_ERB_FOR_NODE_T;
255
256
 
@@ -258,7 +259,7 @@ typedef struct AST_ERB_RESCUE_NODE_STRUCT {
258
259
  token_T* tag_opening;
259
260
  token_T* content;
260
261
  token_T* tag_closing;
261
- array_T* statements;
262
+ hb_array_T* statements;
262
263
  struct AST_ERB_RESCUE_NODE_STRUCT* subsequent;
263
264
  } AST_ERB_RESCUE_NODE_T;
264
265
 
@@ -267,7 +268,7 @@ typedef struct AST_ERB_ENSURE_NODE_STRUCT {
267
268
  token_T* tag_opening;
268
269
  token_T* content;
269
270
  token_T* tag_closing;
270
- array_T* statements;
271
+ hb_array_T* statements;
271
272
  } AST_ERB_ENSURE_NODE_T;
272
273
 
273
274
  typedef struct AST_ERB_BEGIN_NODE_STRUCT {
@@ -275,7 +276,7 @@ typedef struct AST_ERB_BEGIN_NODE_STRUCT {
275
276
  token_T* tag_opening;
276
277
  token_T* content;
277
278
  token_T* tag_closing;
278
- array_T* statements;
279
+ hb_array_T* statements;
279
280
  struct AST_ERB_RESCUE_NODE_STRUCT* rescue_clause;
280
281
  struct AST_ERB_ELSE_NODE_STRUCT* else_clause;
281
282
  struct AST_ERB_ENSURE_NODE_STRUCT* ensure_clause;
@@ -287,7 +288,7 @@ typedef struct AST_ERB_UNLESS_NODE_STRUCT {
287
288
  token_T* tag_opening;
288
289
  token_T* content;
289
290
  token_T* tag_closing;
290
- array_T* statements;
291
+ hb_array_T* statements;
291
292
  struct AST_ERB_ELSE_NODE_STRUCT* else_clause;
292
293
  struct AST_ERB_END_NODE_STRUCT* end_node;
293
294
  } AST_ERB_UNLESS_NODE_T;
@@ -304,42 +305,42 @@ typedef struct AST_ERB_IN_NODE_STRUCT {
304
305
  token_T* tag_opening;
305
306
  token_T* content;
306
307
  token_T* tag_closing;
307
- array_T* statements;
308
+ hb_array_T* statements;
308
309
  } AST_ERB_IN_NODE_T;
309
310
 
310
- AST_DOCUMENT_NODE_T* ast_document_node_init(array_T* children, position_T start_position, position_T end_position, array_T* errors);
311
- AST_LITERAL_NODE_T* ast_literal_node_init(const char* content, position_T start_position, position_T end_position, array_T* errors);
312
- AST_HTML_OPEN_TAG_NODE_T* ast_html_open_tag_node_init(token_T* tag_opening, token_T* tag_name, token_T* tag_closing, array_T* children, bool is_void, position_T start_position, position_T end_position, array_T* errors);
313
- AST_HTML_CLOSE_TAG_NODE_T* ast_html_close_tag_node_init(token_T* tag_opening, token_T* tag_name, array_T* children, token_T* tag_closing, position_T start_position, position_T end_position, array_T* errors);
314
- AST_HTML_ELEMENT_NODE_T* ast_html_element_node_init(struct AST_HTML_OPEN_TAG_NODE_STRUCT* open_tag, token_T* tag_name, array_T* body, struct AST_HTML_CLOSE_TAG_NODE_STRUCT* close_tag, bool is_void, element_source_t source, position_T start_position, position_T end_position, array_T* errors);
315
- AST_HTML_ATTRIBUTE_VALUE_NODE_T* ast_html_attribute_value_node_init(token_T* open_quote, array_T* children, token_T* close_quote, bool quoted, position_T start_position, position_T end_position, array_T* errors);
316
- AST_HTML_ATTRIBUTE_NAME_NODE_T* ast_html_attribute_name_node_init(array_T* children, position_T start_position, position_T end_position, array_T* errors);
317
- AST_HTML_ATTRIBUTE_NODE_T* ast_html_attribute_node_init(struct AST_HTML_ATTRIBUTE_NAME_NODE_STRUCT* name, token_T* equals, struct AST_HTML_ATTRIBUTE_VALUE_NODE_STRUCT* value, position_T start_position, position_T end_position, array_T* errors);
318
- AST_HTML_TEXT_NODE_T* ast_html_text_node_init(const char* content, position_T start_position, position_T end_position, array_T* errors);
319
- AST_HTML_COMMENT_NODE_T* ast_html_comment_node_init(token_T* comment_start, array_T* children, token_T* comment_end, position_T start_position, position_T end_position, array_T* errors);
320
- AST_HTML_DOCTYPE_NODE_T* ast_html_doctype_node_init(token_T* tag_opening, array_T* children, token_T* tag_closing, position_T start_position, position_T end_position, array_T* errors);
321
- AST_XML_DECLARATION_NODE_T* ast_xml_declaration_node_init(token_T* tag_opening, array_T* children, token_T* tag_closing, position_T start_position, position_T end_position, array_T* errors);
322
- AST_CDATA_NODE_T* ast_cdata_node_init(token_T* tag_opening, array_T* children, token_T* tag_closing, position_T start_position, position_T end_position, array_T* errors);
323
- AST_WHITESPACE_NODE_T* ast_whitespace_node_init(token_T* value, position_T start_position, position_T end_position, array_T* errors);
324
- AST_ERB_CONTENT_NODE_T* ast_erb_content_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, analyzed_ruby_T* analyzed_ruby, bool parsed, bool valid, position_T start_position, position_T end_position, array_T* errors);
325
- AST_ERB_END_NODE_T* ast_erb_end_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, position_T start_position, position_T end_position, array_T* errors);
326
- AST_ERB_ELSE_NODE_T* ast_erb_else_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* statements, position_T start_position, position_T end_position, array_T* errors);
327
- AST_ERB_IF_NODE_T* ast_erb_if_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* statements, struct AST_NODE_STRUCT* subsequent, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, array_T* errors);
328
- AST_ERB_BLOCK_NODE_T* ast_erb_block_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* body, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, array_T* errors);
329
- AST_ERB_WHEN_NODE_T* ast_erb_when_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* statements, position_T start_position, position_T end_position, array_T* errors);
330
- AST_ERB_CASE_NODE_T* ast_erb_case_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* children, array_T* conditions, struct AST_ERB_ELSE_NODE_STRUCT* else_clause, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, array_T* errors);
331
- AST_ERB_CASE_MATCH_NODE_T* ast_erb_case_match_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* children, array_T* conditions, struct AST_ERB_ELSE_NODE_STRUCT* else_clause, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, array_T* errors);
332
- AST_ERB_WHILE_NODE_T* ast_erb_while_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* statements, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, array_T* errors);
333
- AST_ERB_UNTIL_NODE_T* ast_erb_until_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* statements, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, array_T* errors);
334
- AST_ERB_FOR_NODE_T* ast_erb_for_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* statements, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, array_T* errors);
335
- AST_ERB_RESCUE_NODE_T* ast_erb_rescue_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* statements, struct AST_ERB_RESCUE_NODE_STRUCT* subsequent, position_T start_position, position_T end_position, array_T* errors);
336
- AST_ERB_ENSURE_NODE_T* ast_erb_ensure_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* statements, position_T start_position, position_T end_position, array_T* errors);
337
- AST_ERB_BEGIN_NODE_T* ast_erb_begin_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* statements, struct AST_ERB_RESCUE_NODE_STRUCT* rescue_clause, struct AST_ERB_ELSE_NODE_STRUCT* else_clause, struct AST_ERB_ENSURE_NODE_STRUCT* ensure_clause, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, array_T* errors);
338
- AST_ERB_UNLESS_NODE_T* ast_erb_unless_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* statements, struct AST_ERB_ELSE_NODE_STRUCT* else_clause, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, array_T* errors);
339
- AST_ERB_YIELD_NODE_T* ast_erb_yield_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, position_T start_position, position_T end_position, array_T* errors);
340
- AST_ERB_IN_NODE_T* ast_erb_in_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, array_T* statements, position_T start_position, position_T end_position, array_T* errors);
341
-
342
- const char* ast_node_type_to_string(AST_NODE_T* node);
343
- const char* ast_node_human_type(AST_NODE_T* node);
311
+ AST_DOCUMENT_NODE_T* ast_document_node_init(hb_array_T* children, position_T start_position, position_T end_position, hb_array_T* errors);
312
+ AST_LITERAL_NODE_T* ast_literal_node_init(const char* content, position_T start_position, position_T end_position, hb_array_T* errors);
313
+ AST_HTML_OPEN_TAG_NODE_T* ast_html_open_tag_node_init(token_T* tag_opening, token_T* tag_name, token_T* tag_closing, hb_array_T* children, bool is_void, position_T start_position, position_T end_position, hb_array_T* errors);
314
+ AST_HTML_CLOSE_TAG_NODE_T* ast_html_close_tag_node_init(token_T* tag_opening, token_T* tag_name, hb_array_T* children, token_T* tag_closing, position_T start_position, position_T end_position, hb_array_T* errors);
315
+ AST_HTML_ELEMENT_NODE_T* ast_html_element_node_init(struct AST_HTML_OPEN_TAG_NODE_STRUCT* open_tag, token_T* tag_name, hb_array_T* body, struct AST_HTML_CLOSE_TAG_NODE_STRUCT* close_tag, bool is_void, element_source_t source, position_T start_position, position_T end_position, hb_array_T* errors);
316
+ AST_HTML_ATTRIBUTE_VALUE_NODE_T* ast_html_attribute_value_node_init(token_T* open_quote, hb_array_T* children, token_T* close_quote, bool quoted, position_T start_position, position_T end_position, hb_array_T* errors);
317
+ AST_HTML_ATTRIBUTE_NAME_NODE_T* ast_html_attribute_name_node_init(hb_array_T* children, position_T start_position, position_T end_position, hb_array_T* errors);
318
+ AST_HTML_ATTRIBUTE_NODE_T* ast_html_attribute_node_init(struct AST_HTML_ATTRIBUTE_NAME_NODE_STRUCT* name, token_T* equals, struct AST_HTML_ATTRIBUTE_VALUE_NODE_STRUCT* value, position_T start_position, position_T end_position, hb_array_T* errors);
319
+ AST_HTML_TEXT_NODE_T* ast_html_text_node_init(const char* content, position_T start_position, position_T end_position, hb_array_T* errors);
320
+ AST_HTML_COMMENT_NODE_T* ast_html_comment_node_init(token_T* comment_start, hb_array_T* children, token_T* comment_end, position_T start_position, position_T end_position, hb_array_T* errors);
321
+ AST_HTML_DOCTYPE_NODE_T* ast_html_doctype_node_init(token_T* tag_opening, hb_array_T* children, token_T* tag_closing, position_T start_position, position_T end_position, hb_array_T* errors);
322
+ AST_XML_DECLARATION_NODE_T* ast_xml_declaration_node_init(token_T* tag_opening, hb_array_T* children, token_T* tag_closing, position_T start_position, position_T end_position, hb_array_T* errors);
323
+ AST_CDATA_NODE_T* ast_cdata_node_init(token_T* tag_opening, hb_array_T* children, token_T* tag_closing, position_T start_position, position_T end_position, hb_array_T* errors);
324
+ AST_WHITESPACE_NODE_T* ast_whitespace_node_init(token_T* value, position_T start_position, position_T end_position, hb_array_T* errors);
325
+ AST_ERB_CONTENT_NODE_T* ast_erb_content_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, analyzed_ruby_T* analyzed_ruby, bool parsed, bool valid, position_T start_position, position_T end_position, hb_array_T* errors);
326
+ AST_ERB_END_NODE_T* ast_erb_end_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, position_T start_position, position_T end_position, hb_array_T* errors);
327
+ AST_ERB_ELSE_NODE_T* ast_erb_else_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* statements, position_T start_position, position_T end_position, hb_array_T* errors);
328
+ AST_ERB_IF_NODE_T* ast_erb_if_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* statements, struct AST_NODE_STRUCT* subsequent, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, hb_array_T* errors);
329
+ AST_ERB_BLOCK_NODE_T* ast_erb_block_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* body, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, hb_array_T* errors);
330
+ AST_ERB_WHEN_NODE_T* ast_erb_when_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* statements, position_T start_position, position_T end_position, hb_array_T* errors);
331
+ AST_ERB_CASE_NODE_T* ast_erb_case_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* children, hb_array_T* conditions, struct AST_ERB_ELSE_NODE_STRUCT* else_clause, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, hb_array_T* errors);
332
+ AST_ERB_CASE_MATCH_NODE_T* ast_erb_case_match_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* children, hb_array_T* conditions, struct AST_ERB_ELSE_NODE_STRUCT* else_clause, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, hb_array_T* errors);
333
+ AST_ERB_WHILE_NODE_T* ast_erb_while_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* statements, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, hb_array_T* errors);
334
+ AST_ERB_UNTIL_NODE_T* ast_erb_until_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* statements, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, hb_array_T* errors);
335
+ AST_ERB_FOR_NODE_T* ast_erb_for_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* statements, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, hb_array_T* errors);
336
+ AST_ERB_RESCUE_NODE_T* ast_erb_rescue_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* statements, struct AST_ERB_RESCUE_NODE_STRUCT* subsequent, position_T start_position, position_T end_position, hb_array_T* errors);
337
+ AST_ERB_ENSURE_NODE_T* ast_erb_ensure_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* statements, position_T start_position, position_T end_position, hb_array_T* errors);
338
+ AST_ERB_BEGIN_NODE_T* ast_erb_begin_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* statements, struct AST_ERB_RESCUE_NODE_STRUCT* rescue_clause, struct AST_ERB_ELSE_NODE_STRUCT* else_clause, struct AST_ERB_ENSURE_NODE_STRUCT* ensure_clause, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, hb_array_T* errors);
339
+ AST_ERB_UNLESS_NODE_T* ast_erb_unless_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* statements, struct AST_ERB_ELSE_NODE_STRUCT* else_clause, struct AST_ERB_END_NODE_STRUCT* end_node, position_T start_position, position_T end_position, hb_array_T* errors);
340
+ AST_ERB_YIELD_NODE_T* ast_erb_yield_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, position_T start_position, position_T end_position, hb_array_T* errors);
341
+ AST_ERB_IN_NODE_T* ast_erb_in_node_init(token_T* tag_opening, token_T* content, token_T* tag_closing, hb_array_T* statements, position_T start_position, position_T end_position, hb_array_T* errors);
342
+
343
+ hb_string_T ast_node_type_to_string(AST_NODE_T* node);
344
+ hb_string_T ast_node_human_type(AST_NODE_T* node);
344
345
 
345
346
  #endif