prism 0.16.0 → 0.17.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (86) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +16 -1
  3. data/Makefile +6 -0
  4. data/README.md +1 -1
  5. data/config.yml +50 -35
  6. data/docs/fuzzing.md +1 -1
  7. data/docs/serialization.md +28 -29
  8. data/ext/prism/api_node.c +802 -770
  9. data/ext/prism/api_pack.c +20 -9
  10. data/ext/prism/extension.c +464 -162
  11. data/ext/prism/extension.h +1 -1
  12. data/include/prism/ast.h +3173 -763
  13. data/include/prism/defines.h +32 -9
  14. data/include/prism/diagnostic.h +36 -3
  15. data/include/prism/enc/pm_encoding.h +118 -28
  16. data/include/prism/node.h +38 -13
  17. data/include/prism/options.h +204 -0
  18. data/include/prism/pack.h +44 -33
  19. data/include/prism/parser.h +445 -200
  20. data/include/prism/prettyprint.h +12 -1
  21. data/include/prism/regexp.h +16 -2
  22. data/include/prism/util/pm_buffer.h +94 -16
  23. data/include/prism/util/pm_char.h +162 -48
  24. data/include/prism/util/pm_constant_pool.h +126 -32
  25. data/include/prism/util/pm_list.h +68 -38
  26. data/include/prism/util/pm_memchr.h +18 -3
  27. data/include/prism/util/pm_newline_list.h +70 -27
  28. data/include/prism/util/pm_state_stack.h +25 -7
  29. data/include/prism/util/pm_string.h +115 -27
  30. data/include/prism/util/pm_string_list.h +25 -6
  31. data/include/prism/util/pm_strncasecmp.h +32 -0
  32. data/include/prism/util/pm_strpbrk.h +31 -17
  33. data/include/prism/version.h +27 -2
  34. data/include/prism.h +224 -31
  35. data/lib/prism/compiler.rb +6 -3
  36. data/lib/prism/debug.rb +23 -7
  37. data/lib/prism/dispatcher.rb +33 -18
  38. data/lib/prism/dsl.rb +10 -5
  39. data/lib/prism/ffi.rb +132 -80
  40. data/lib/prism/lex_compat.rb +25 -15
  41. data/lib/prism/mutation_compiler.rb +10 -5
  42. data/lib/prism/node.rb +370 -135
  43. data/lib/prism/node_ext.rb +1 -1
  44. data/lib/prism/node_inspector.rb +1 -1
  45. data/lib/prism/pack.rb +79 -40
  46. data/lib/prism/parse_result/comments.rb +7 -2
  47. data/lib/prism/parse_result/newlines.rb +4 -0
  48. data/lib/prism/parse_result.rb +150 -30
  49. data/lib/prism/pattern.rb +11 -0
  50. data/lib/prism/ripper_compat.rb +28 -10
  51. data/lib/prism/serialize.rb +86 -54
  52. data/lib/prism/visitor.rb +10 -3
  53. data/lib/prism.rb +20 -2
  54. data/prism.gemspec +4 -2
  55. data/rbi/prism.rbi +104 -60
  56. data/rbi/prism_static.rbi +16 -2
  57. data/sig/prism.rbs +72 -43
  58. data/sig/prism_static.rbs +14 -1
  59. data/src/diagnostic.c +56 -53
  60. data/src/enc/pm_big5.c +1 -0
  61. data/src/enc/pm_euc_jp.c +1 -0
  62. data/src/enc/pm_gbk.c +1 -0
  63. data/src/enc/pm_shift_jis.c +1 -0
  64. data/src/enc/pm_tables.c +316 -80
  65. data/src/enc/pm_unicode.c +53 -8
  66. data/src/enc/pm_windows_31j.c +1 -0
  67. data/src/node.c +334 -321
  68. data/src/options.c +170 -0
  69. data/src/prettyprint.c +74 -47
  70. data/src/prism.c +1642 -856
  71. data/src/regexp.c +151 -95
  72. data/src/serialize.c +44 -20
  73. data/src/token_type.c +3 -1
  74. data/src/util/pm_buffer.c +45 -15
  75. data/src/util/pm_char.c +103 -57
  76. data/src/util/pm_constant_pool.c +51 -21
  77. data/src/util/pm_list.c +12 -4
  78. data/src/util/pm_memchr.c +5 -3
  79. data/src/util/pm_newline_list.c +20 -12
  80. data/src/util/pm_state_stack.c +9 -3
  81. data/src/util/pm_string.c +95 -85
  82. data/src/util/pm_string_list.c +14 -15
  83. data/src/util/pm_strncasecmp.c +10 -3
  84. data/src/util/pm_strpbrk.c +25 -19
  85. metadata +5 -3
  86. data/docs/prism.png +0 -0
data/include/prism/ast.h CHANGED
@@ -5,6 +5,11 @@
5
5
  /* if you are looking to modify the */
6
6
  /* template */
7
7
  /******************************************************************************/
8
+ /**
9
+ * @file ast.h
10
+ *
11
+ * The abstract syntax tree.
12
+ */
8
13
  #ifndef PRISM_AST_H
9
14
  #define PRISM_AST_H
10
15
 
@@ -16,1969 +21,4374 @@
16
21
  #include <stddef.h>
17
22
  #include <stdint.h>
18
23
 
19
- // This enum represents every type of token in the Ruby source.
24
+ /**
25
+ * This enum represents every type of token in the Ruby source.
26
+ */
20
27
  typedef enum pm_token_type {
21
- PM_TOKEN_EOF = 1, // final token in the file
22
- PM_TOKEN_MISSING, // a token that was expected but not found
23
- PM_TOKEN_NOT_PROVIDED, // a token that was not present but it is okay
24
- PM_TOKEN_AMPERSAND, // &
25
- PM_TOKEN_AMPERSAND_AMPERSAND, // &&
26
- PM_TOKEN_AMPERSAND_AMPERSAND_EQUAL, // &&=
27
- PM_TOKEN_AMPERSAND_DOT, // &.
28
- PM_TOKEN_AMPERSAND_EQUAL, // &=
29
- PM_TOKEN_BACKTICK, // `
30
- PM_TOKEN_BACK_REFERENCE, // a back reference
31
- PM_TOKEN_BANG, // ! or !@
32
- PM_TOKEN_BANG_EQUAL, // !=
33
- PM_TOKEN_BANG_TILDE, // !~
34
- PM_TOKEN_BRACE_LEFT, // {
35
- PM_TOKEN_BRACE_RIGHT, // }
36
- PM_TOKEN_BRACKET_LEFT, // [
37
- PM_TOKEN_BRACKET_LEFT_ARRAY, // [ for the beginning of an array
38
- PM_TOKEN_BRACKET_LEFT_RIGHT, // []
39
- PM_TOKEN_BRACKET_LEFT_RIGHT_EQUAL, // []=
40
- PM_TOKEN_BRACKET_RIGHT, // ]
41
- PM_TOKEN_CARET, // ^
42
- PM_TOKEN_CARET_EQUAL, // ^=
43
- PM_TOKEN_CHARACTER_LITERAL, // a character literal
44
- PM_TOKEN_CLASS_VARIABLE, // a class variable
45
- PM_TOKEN_COLON, // :
46
- PM_TOKEN_COLON_COLON, // ::
47
- PM_TOKEN_COMMA, // ,
48
- PM_TOKEN_COMMENT, // a comment
49
- PM_TOKEN_CONSTANT, // a constant
50
- PM_TOKEN_DOT, // .
51
- PM_TOKEN_DOT_DOT, // ..
52
- PM_TOKEN_DOT_DOT_DOT, // ...
53
- PM_TOKEN_EMBDOC_BEGIN, // =begin
54
- PM_TOKEN_EMBDOC_END, // =end
55
- PM_TOKEN_EMBDOC_LINE, // a line inside of embedded documentation
56
- PM_TOKEN_EMBEXPR_BEGIN, // #{
57
- PM_TOKEN_EMBEXPR_END, // }
58
- PM_TOKEN_EMBVAR, // #
59
- PM_TOKEN_EQUAL, // =
60
- PM_TOKEN_EQUAL_EQUAL, // ==
61
- PM_TOKEN_EQUAL_EQUAL_EQUAL, // ===
62
- PM_TOKEN_EQUAL_GREATER, // =>
63
- PM_TOKEN_EQUAL_TILDE, // =~
64
- PM_TOKEN_FLOAT, // a floating point number
65
- PM_TOKEN_FLOAT_IMAGINARY, // a floating pointer number with an imaginary suffix
66
- PM_TOKEN_FLOAT_RATIONAL, // a floating pointer number with a rational suffix
67
- PM_TOKEN_FLOAT_RATIONAL_IMAGINARY, // a floating pointer number with a rational and imaginary suffix
68
- PM_TOKEN_GLOBAL_VARIABLE, // a global variable
69
- PM_TOKEN_GREATER, // >
70
- PM_TOKEN_GREATER_EQUAL, // >=
71
- PM_TOKEN_GREATER_GREATER, // >>
72
- PM_TOKEN_GREATER_GREATER_EQUAL, // >>=
73
- PM_TOKEN_HEREDOC_END, // the end of a heredoc
74
- PM_TOKEN_HEREDOC_START, // the start of a heredoc
75
- PM_TOKEN_IDENTIFIER, // an identifier
76
- PM_TOKEN_IGNORED_NEWLINE, // an ignored newline
77
- PM_TOKEN_INSTANCE_VARIABLE, // an instance variable
78
- PM_TOKEN_INTEGER, // an integer (any base)
79
- PM_TOKEN_INTEGER_IMAGINARY, // an integer with an imaginary suffix
80
- PM_TOKEN_INTEGER_RATIONAL, // an integer with a rational suffix
81
- PM_TOKEN_INTEGER_RATIONAL_IMAGINARY, // an integer with a rational and imaginary suffix
82
- PM_TOKEN_KEYWORD_ALIAS, // alias
83
- PM_TOKEN_KEYWORD_AND, // and
84
- PM_TOKEN_KEYWORD_BEGIN, // begin
85
- PM_TOKEN_KEYWORD_BEGIN_UPCASE, // BEGIN
86
- PM_TOKEN_KEYWORD_BREAK, // break
87
- PM_TOKEN_KEYWORD_CASE, // case
88
- PM_TOKEN_KEYWORD_CLASS, // class
89
- PM_TOKEN_KEYWORD_DEF, // def
90
- PM_TOKEN_KEYWORD_DEFINED, // defined?
91
- PM_TOKEN_KEYWORD_DO, // do
92
- PM_TOKEN_KEYWORD_DO_LOOP, // do keyword for a predicate in a while, until, or for loop
93
- PM_TOKEN_KEYWORD_ELSE, // else
94
- PM_TOKEN_KEYWORD_ELSIF, // elsif
95
- PM_TOKEN_KEYWORD_END, // end
96
- PM_TOKEN_KEYWORD_END_UPCASE, // END
97
- PM_TOKEN_KEYWORD_ENSURE, // ensure
98
- PM_TOKEN_KEYWORD_FALSE, // false
99
- PM_TOKEN_KEYWORD_FOR, // for
100
- PM_TOKEN_KEYWORD_IF, // if
101
- PM_TOKEN_KEYWORD_IF_MODIFIER, // if in the modifier form
102
- PM_TOKEN_KEYWORD_IN, // in
103
- PM_TOKEN_KEYWORD_MODULE, // module
104
- PM_TOKEN_KEYWORD_NEXT, // next
105
- PM_TOKEN_KEYWORD_NIL, // nil
106
- PM_TOKEN_KEYWORD_NOT, // not
107
- PM_TOKEN_KEYWORD_OR, // or
108
- PM_TOKEN_KEYWORD_REDO, // redo
109
- PM_TOKEN_KEYWORD_RESCUE, // rescue
110
- PM_TOKEN_KEYWORD_RESCUE_MODIFIER, // rescue in the modifier form
111
- PM_TOKEN_KEYWORD_RETRY, // retry
112
- PM_TOKEN_KEYWORD_RETURN, // return
113
- PM_TOKEN_KEYWORD_SELF, // self
114
- PM_TOKEN_KEYWORD_SUPER, // super
115
- PM_TOKEN_KEYWORD_THEN, // then
116
- PM_TOKEN_KEYWORD_TRUE, // true
117
- PM_TOKEN_KEYWORD_UNDEF, // undef
118
- PM_TOKEN_KEYWORD_UNLESS, // unless
119
- PM_TOKEN_KEYWORD_UNLESS_MODIFIER, // unless in the modifier form
120
- PM_TOKEN_KEYWORD_UNTIL, // until
121
- PM_TOKEN_KEYWORD_UNTIL_MODIFIER, // until in the modifier form
122
- PM_TOKEN_KEYWORD_WHEN, // when
123
- PM_TOKEN_KEYWORD_WHILE, // while
124
- PM_TOKEN_KEYWORD_WHILE_MODIFIER, // while in the modifier form
125
- PM_TOKEN_KEYWORD_YIELD, // yield
126
- PM_TOKEN_KEYWORD___ENCODING__, // __ENCODING__
127
- PM_TOKEN_KEYWORD___FILE__, // __FILE__
128
- PM_TOKEN_KEYWORD___LINE__, // __LINE__
129
- PM_TOKEN_LABEL, // a label
130
- PM_TOKEN_LABEL_END, // the end of a label
131
- PM_TOKEN_LAMBDA_BEGIN, // {
132
- PM_TOKEN_LESS, // <
133
- PM_TOKEN_LESS_EQUAL, // <=
134
- PM_TOKEN_LESS_EQUAL_GREATER, // <=>
135
- PM_TOKEN_LESS_LESS, // <<
136
- PM_TOKEN_LESS_LESS_EQUAL, // <<=
137
- PM_TOKEN_METHOD_NAME, // a method name
138
- PM_TOKEN_MINUS, // -
139
- PM_TOKEN_MINUS_EQUAL, // -=
140
- PM_TOKEN_MINUS_GREATER, // ->
141
- PM_TOKEN_NEWLINE, // a newline character outside of other tokens
142
- PM_TOKEN_NUMBERED_REFERENCE, // a numbered reference to a capture group in the previous regular expression match
143
- PM_TOKEN_PARENTHESIS_LEFT, // (
144
- PM_TOKEN_PARENTHESIS_LEFT_PARENTHESES, // ( for a parentheses node
145
- PM_TOKEN_PARENTHESIS_RIGHT, // )
146
- PM_TOKEN_PERCENT, // %
147
- PM_TOKEN_PERCENT_EQUAL, // %=
148
- PM_TOKEN_PERCENT_LOWER_I, // %i
149
- PM_TOKEN_PERCENT_LOWER_W, // %w
150
- PM_TOKEN_PERCENT_LOWER_X, // %x
151
- PM_TOKEN_PERCENT_UPPER_I, // %I
152
- PM_TOKEN_PERCENT_UPPER_W, // %W
153
- PM_TOKEN_PIPE, // |
154
- PM_TOKEN_PIPE_EQUAL, // |=
155
- PM_TOKEN_PIPE_PIPE, // ||
156
- PM_TOKEN_PIPE_PIPE_EQUAL, // ||=
157
- PM_TOKEN_PLUS, // +
158
- PM_TOKEN_PLUS_EQUAL, // +=
159
- PM_TOKEN_QUESTION_MARK, // ?
160
- PM_TOKEN_REGEXP_BEGIN, // the beginning of a regular expression
161
- PM_TOKEN_REGEXP_END, // the end of a regular expression
162
- PM_TOKEN_SEMICOLON, // ;
163
- PM_TOKEN_SLASH, // /
164
- PM_TOKEN_SLASH_EQUAL, // /=
165
- PM_TOKEN_STAR, // *
166
- PM_TOKEN_STAR_EQUAL, // *=
167
- PM_TOKEN_STAR_STAR, // **
168
- PM_TOKEN_STAR_STAR_EQUAL, // **=
169
- PM_TOKEN_STRING_BEGIN, // the beginning of a string
170
- PM_TOKEN_STRING_CONTENT, // the contents of a string
171
- PM_TOKEN_STRING_END, // the end of a string
172
- PM_TOKEN_SYMBOL_BEGIN, // the beginning of a symbol
173
- PM_TOKEN_TILDE, // ~ or ~@
174
- PM_TOKEN_UAMPERSAND, // unary &
175
- PM_TOKEN_UCOLON_COLON, // unary ::
176
- PM_TOKEN_UDOT_DOT, // unary ..
177
- PM_TOKEN_UDOT_DOT_DOT, // unary ...
178
- PM_TOKEN_UMINUS, // -@
179
- PM_TOKEN_UMINUS_NUM, // -@ for a number
180
- PM_TOKEN_UPLUS, // +@
181
- PM_TOKEN_USTAR, // unary *
182
- PM_TOKEN_USTAR_STAR, // unary **
183
- PM_TOKEN_WORDS_SEP, // a separator between words in a list
184
- PM_TOKEN___END__, // marker for the point in the file at which the parser should stop
185
- PM_TOKEN_MAXIMUM, // the maximum token value
28
+ /** final token in the file */
29
+ PM_TOKEN_EOF = 1,
30
+
31
+ /** a token that was expected but not found */
32
+ PM_TOKEN_MISSING,
33
+
34
+ /** a token that was not present but it is okay */
35
+ PM_TOKEN_NOT_PROVIDED,
36
+
37
+ /** & */
38
+ PM_TOKEN_AMPERSAND,
39
+
40
+ /** && */
41
+ PM_TOKEN_AMPERSAND_AMPERSAND,
42
+
43
+ /** &&= */
44
+ PM_TOKEN_AMPERSAND_AMPERSAND_EQUAL,
45
+
46
+ /** &. */
47
+ PM_TOKEN_AMPERSAND_DOT,
48
+
49
+ /** &= */
50
+ PM_TOKEN_AMPERSAND_EQUAL,
51
+
52
+ /** ` */
53
+ PM_TOKEN_BACKTICK,
54
+
55
+ /** a back reference */
56
+ PM_TOKEN_BACK_REFERENCE,
57
+
58
+ /** ! or !@ */
59
+ PM_TOKEN_BANG,
60
+
61
+ /** != */
62
+ PM_TOKEN_BANG_EQUAL,
63
+
64
+ /** !~ */
65
+ PM_TOKEN_BANG_TILDE,
66
+
67
+ /** { */
68
+ PM_TOKEN_BRACE_LEFT,
69
+
70
+ /** } */
71
+ PM_TOKEN_BRACE_RIGHT,
72
+
73
+ /** [ */
74
+ PM_TOKEN_BRACKET_LEFT,
75
+
76
+ /** [ for the beginning of an array */
77
+ PM_TOKEN_BRACKET_LEFT_ARRAY,
78
+
79
+ /** [] */
80
+ PM_TOKEN_BRACKET_LEFT_RIGHT,
81
+
82
+ /** []= */
83
+ PM_TOKEN_BRACKET_LEFT_RIGHT_EQUAL,
84
+
85
+ /** ] */
86
+ PM_TOKEN_BRACKET_RIGHT,
87
+
88
+ /** ^ */
89
+ PM_TOKEN_CARET,
90
+
91
+ /** ^= */
92
+ PM_TOKEN_CARET_EQUAL,
93
+
94
+ /** a character literal */
95
+ PM_TOKEN_CHARACTER_LITERAL,
96
+
97
+ /** a class variable */
98
+ PM_TOKEN_CLASS_VARIABLE,
99
+
100
+ /** : */
101
+ PM_TOKEN_COLON,
102
+
103
+ /** :: */
104
+ PM_TOKEN_COLON_COLON,
105
+
106
+ /** , */
107
+ PM_TOKEN_COMMA,
108
+
109
+ /** a comment */
110
+ PM_TOKEN_COMMENT,
111
+
112
+ /** a constant */
113
+ PM_TOKEN_CONSTANT,
114
+
115
+ /** the . call operator */
116
+ PM_TOKEN_DOT,
117
+
118
+ /** the .. range operator */
119
+ PM_TOKEN_DOT_DOT,
120
+
121
+ /** the ... range operator or forwarding parameter */
122
+ PM_TOKEN_DOT_DOT_DOT,
123
+
124
+ /** =begin */
125
+ PM_TOKEN_EMBDOC_BEGIN,
126
+
127
+ /** =end */
128
+ PM_TOKEN_EMBDOC_END,
129
+
130
+ /** a line inside of embedded documentation */
131
+ PM_TOKEN_EMBDOC_LINE,
132
+
133
+ /** #{ */
134
+ PM_TOKEN_EMBEXPR_BEGIN,
135
+
136
+ /** } */
137
+ PM_TOKEN_EMBEXPR_END,
138
+
139
+ /** # */
140
+ PM_TOKEN_EMBVAR,
141
+
142
+ /** = */
143
+ PM_TOKEN_EQUAL,
144
+
145
+ /** == */
146
+ PM_TOKEN_EQUAL_EQUAL,
147
+
148
+ /** === */
149
+ PM_TOKEN_EQUAL_EQUAL_EQUAL,
150
+
151
+ /** => */
152
+ PM_TOKEN_EQUAL_GREATER,
153
+
154
+ /** =~ */
155
+ PM_TOKEN_EQUAL_TILDE,
156
+
157
+ /** a floating point number */
158
+ PM_TOKEN_FLOAT,
159
+
160
+ /** a floating pointer number with an imaginary suffix */
161
+ PM_TOKEN_FLOAT_IMAGINARY,
162
+
163
+ /** a floating pointer number with a rational suffix */
164
+ PM_TOKEN_FLOAT_RATIONAL,
165
+
166
+ /** a floating pointer number with a rational and imaginary suffix */
167
+ PM_TOKEN_FLOAT_RATIONAL_IMAGINARY,
168
+
169
+ /** a global variable */
170
+ PM_TOKEN_GLOBAL_VARIABLE,
171
+
172
+ /** > */
173
+ PM_TOKEN_GREATER,
174
+
175
+ /** >= */
176
+ PM_TOKEN_GREATER_EQUAL,
177
+
178
+ /** >> */
179
+ PM_TOKEN_GREATER_GREATER,
180
+
181
+ /** >>= */
182
+ PM_TOKEN_GREATER_GREATER_EQUAL,
183
+
184
+ /** the end of a heredoc */
185
+ PM_TOKEN_HEREDOC_END,
186
+
187
+ /** the start of a heredoc */
188
+ PM_TOKEN_HEREDOC_START,
189
+
190
+ /** an identifier */
191
+ PM_TOKEN_IDENTIFIER,
192
+
193
+ /** an ignored newline */
194
+ PM_TOKEN_IGNORED_NEWLINE,
195
+
196
+ /** an instance variable */
197
+ PM_TOKEN_INSTANCE_VARIABLE,
198
+
199
+ /** an integer (any base) */
200
+ PM_TOKEN_INTEGER,
201
+
202
+ /** an integer with an imaginary suffix */
203
+ PM_TOKEN_INTEGER_IMAGINARY,
204
+
205
+ /** an integer with a rational suffix */
206
+ PM_TOKEN_INTEGER_RATIONAL,
207
+
208
+ /** an integer with a rational and imaginary suffix */
209
+ PM_TOKEN_INTEGER_RATIONAL_IMAGINARY,
210
+
211
+ /** alias */
212
+ PM_TOKEN_KEYWORD_ALIAS,
213
+
214
+ /** and */
215
+ PM_TOKEN_KEYWORD_AND,
216
+
217
+ /** begin */
218
+ PM_TOKEN_KEYWORD_BEGIN,
219
+
220
+ /** BEGIN */
221
+ PM_TOKEN_KEYWORD_BEGIN_UPCASE,
222
+
223
+ /** break */
224
+ PM_TOKEN_KEYWORD_BREAK,
225
+
226
+ /** case */
227
+ PM_TOKEN_KEYWORD_CASE,
228
+
229
+ /** class */
230
+ PM_TOKEN_KEYWORD_CLASS,
231
+
232
+ /** def */
233
+ PM_TOKEN_KEYWORD_DEF,
234
+
235
+ /** defined? */
236
+ PM_TOKEN_KEYWORD_DEFINED,
237
+
238
+ /** do */
239
+ PM_TOKEN_KEYWORD_DO,
240
+
241
+ /** do keyword for a predicate in a while, until, or for loop */
242
+ PM_TOKEN_KEYWORD_DO_LOOP,
243
+
244
+ /** else */
245
+ PM_TOKEN_KEYWORD_ELSE,
246
+
247
+ /** elsif */
248
+ PM_TOKEN_KEYWORD_ELSIF,
249
+
250
+ /** end */
251
+ PM_TOKEN_KEYWORD_END,
252
+
253
+ /** END */
254
+ PM_TOKEN_KEYWORD_END_UPCASE,
255
+
256
+ /** ensure */
257
+ PM_TOKEN_KEYWORD_ENSURE,
258
+
259
+ /** false */
260
+ PM_TOKEN_KEYWORD_FALSE,
261
+
262
+ /** for */
263
+ PM_TOKEN_KEYWORD_FOR,
264
+
265
+ /** if */
266
+ PM_TOKEN_KEYWORD_IF,
267
+
268
+ /** if in the modifier form */
269
+ PM_TOKEN_KEYWORD_IF_MODIFIER,
270
+
271
+ /** in */
272
+ PM_TOKEN_KEYWORD_IN,
273
+
274
+ /** module */
275
+ PM_TOKEN_KEYWORD_MODULE,
276
+
277
+ /** next */
278
+ PM_TOKEN_KEYWORD_NEXT,
279
+
280
+ /** nil */
281
+ PM_TOKEN_KEYWORD_NIL,
282
+
283
+ /** not */
284
+ PM_TOKEN_KEYWORD_NOT,
285
+
286
+ /** or */
287
+ PM_TOKEN_KEYWORD_OR,
288
+
289
+ /** redo */
290
+ PM_TOKEN_KEYWORD_REDO,
291
+
292
+ /** rescue */
293
+ PM_TOKEN_KEYWORD_RESCUE,
294
+
295
+ /** rescue in the modifier form */
296
+ PM_TOKEN_KEYWORD_RESCUE_MODIFIER,
297
+
298
+ /** retry */
299
+ PM_TOKEN_KEYWORD_RETRY,
300
+
301
+ /** return */
302
+ PM_TOKEN_KEYWORD_RETURN,
303
+
304
+ /** self */
305
+ PM_TOKEN_KEYWORD_SELF,
306
+
307
+ /** super */
308
+ PM_TOKEN_KEYWORD_SUPER,
309
+
310
+ /** then */
311
+ PM_TOKEN_KEYWORD_THEN,
312
+
313
+ /** true */
314
+ PM_TOKEN_KEYWORD_TRUE,
315
+
316
+ /** undef */
317
+ PM_TOKEN_KEYWORD_UNDEF,
318
+
319
+ /** unless */
320
+ PM_TOKEN_KEYWORD_UNLESS,
321
+
322
+ /** unless in the modifier form */
323
+ PM_TOKEN_KEYWORD_UNLESS_MODIFIER,
324
+
325
+ /** until */
326
+ PM_TOKEN_KEYWORD_UNTIL,
327
+
328
+ /** until in the modifier form */
329
+ PM_TOKEN_KEYWORD_UNTIL_MODIFIER,
330
+
331
+ /** when */
332
+ PM_TOKEN_KEYWORD_WHEN,
333
+
334
+ /** while */
335
+ PM_TOKEN_KEYWORD_WHILE,
336
+
337
+ /** while in the modifier form */
338
+ PM_TOKEN_KEYWORD_WHILE_MODIFIER,
339
+
340
+ /** yield */
341
+ PM_TOKEN_KEYWORD_YIELD,
342
+
343
+ /** __ENCODING__ */
344
+ PM_TOKEN_KEYWORD___ENCODING__,
345
+
346
+ /** __FILE__ */
347
+ PM_TOKEN_KEYWORD___FILE__,
348
+
349
+ /** __LINE__ */
350
+ PM_TOKEN_KEYWORD___LINE__,
351
+
352
+ /** a label */
353
+ PM_TOKEN_LABEL,
354
+
355
+ /** the end of a label */
356
+ PM_TOKEN_LABEL_END,
357
+
358
+ /** { */
359
+ PM_TOKEN_LAMBDA_BEGIN,
360
+
361
+ /** < */
362
+ PM_TOKEN_LESS,
363
+
364
+ /** <= */
365
+ PM_TOKEN_LESS_EQUAL,
366
+
367
+ /** <=> */
368
+ PM_TOKEN_LESS_EQUAL_GREATER,
369
+
370
+ /** << */
371
+ PM_TOKEN_LESS_LESS,
372
+
373
+ /** <<= */
374
+ PM_TOKEN_LESS_LESS_EQUAL,
375
+
376
+ /** a method name */
377
+ PM_TOKEN_METHOD_NAME,
378
+
379
+ /** - */
380
+ PM_TOKEN_MINUS,
381
+
382
+ /** -= */
383
+ PM_TOKEN_MINUS_EQUAL,
384
+
385
+ /** -> */
386
+ PM_TOKEN_MINUS_GREATER,
387
+
388
+ /** a newline character outside of other tokens */
389
+ PM_TOKEN_NEWLINE,
390
+
391
+ /** a numbered reference to a capture group in the previous regular expression match */
392
+ PM_TOKEN_NUMBERED_REFERENCE,
393
+
394
+ /** ( */
395
+ PM_TOKEN_PARENTHESIS_LEFT,
396
+
397
+ /** ( for a parentheses node */
398
+ PM_TOKEN_PARENTHESIS_LEFT_PARENTHESES,
399
+
400
+ /** ) */
401
+ PM_TOKEN_PARENTHESIS_RIGHT,
402
+
403
+ /** % */
404
+ PM_TOKEN_PERCENT,
405
+
406
+ /** %= */
407
+ PM_TOKEN_PERCENT_EQUAL,
408
+
409
+ /** %i */
410
+ PM_TOKEN_PERCENT_LOWER_I,
411
+
412
+ /** %w */
413
+ PM_TOKEN_PERCENT_LOWER_W,
414
+
415
+ /** %x */
416
+ PM_TOKEN_PERCENT_LOWER_X,
417
+
418
+ /** %I */
419
+ PM_TOKEN_PERCENT_UPPER_I,
420
+
421
+ /** %W */
422
+ PM_TOKEN_PERCENT_UPPER_W,
423
+
424
+ /** | */
425
+ PM_TOKEN_PIPE,
426
+
427
+ /** |= */
428
+ PM_TOKEN_PIPE_EQUAL,
429
+
430
+ /** || */
431
+ PM_TOKEN_PIPE_PIPE,
432
+
433
+ /** ||= */
434
+ PM_TOKEN_PIPE_PIPE_EQUAL,
435
+
436
+ /** + */
437
+ PM_TOKEN_PLUS,
438
+
439
+ /** += */
440
+ PM_TOKEN_PLUS_EQUAL,
441
+
442
+ /** ? */
443
+ PM_TOKEN_QUESTION_MARK,
444
+
445
+ /** the beginning of a regular expression */
446
+ PM_TOKEN_REGEXP_BEGIN,
447
+
448
+ /** the end of a regular expression */
449
+ PM_TOKEN_REGEXP_END,
450
+
451
+ /** ; */
452
+ PM_TOKEN_SEMICOLON,
453
+
454
+ /** / */
455
+ PM_TOKEN_SLASH,
456
+
457
+ /** /= */
458
+ PM_TOKEN_SLASH_EQUAL,
459
+
460
+ /** * */
461
+ PM_TOKEN_STAR,
462
+
463
+ /** *= */
464
+ PM_TOKEN_STAR_EQUAL,
465
+
466
+ /** ** */
467
+ PM_TOKEN_STAR_STAR,
468
+
469
+ /** **= */
470
+ PM_TOKEN_STAR_STAR_EQUAL,
471
+
472
+ /** the beginning of a string */
473
+ PM_TOKEN_STRING_BEGIN,
474
+
475
+ /** the contents of a string */
476
+ PM_TOKEN_STRING_CONTENT,
477
+
478
+ /** the end of a string */
479
+ PM_TOKEN_STRING_END,
480
+
481
+ /** the beginning of a symbol */
482
+ PM_TOKEN_SYMBOL_BEGIN,
483
+
484
+ /** ~ or ~@ */
485
+ PM_TOKEN_TILDE,
486
+
487
+ /** unary & */
488
+ PM_TOKEN_UAMPERSAND,
489
+
490
+ /** unary :: */
491
+ PM_TOKEN_UCOLON_COLON,
492
+
493
+ /** unary .. operator */
494
+ PM_TOKEN_UDOT_DOT,
495
+
496
+ /** unary ... operator */
497
+ PM_TOKEN_UDOT_DOT_DOT,
498
+
499
+ /** -@ */
500
+ PM_TOKEN_UMINUS,
501
+
502
+ /** -@ for a number */
503
+ PM_TOKEN_UMINUS_NUM,
504
+
505
+ /** +@ */
506
+ PM_TOKEN_UPLUS,
507
+
508
+ /** unary * */
509
+ PM_TOKEN_USTAR,
510
+
511
+ /** unary ** */
512
+ PM_TOKEN_USTAR_STAR,
513
+
514
+ /** a separator between words in a list */
515
+ PM_TOKEN_WORDS_SEP,
516
+
517
+ /** marker for the point in the file at which the parser should stop */
518
+ PM_TOKEN___END__,
519
+
520
+ /** The maximum token value. */
521
+ PM_TOKEN_MAXIMUM,
186
522
  } pm_token_type_t;
187
523
 
188
- // This struct represents a token in the Ruby source. We use it to track both
189
- // type and location information.
524
+ /**
525
+ * This struct represents a token in the Ruby source. We use it to track both
526
+ * type and location information.
527
+ */
190
528
  typedef struct {
529
+ /** The type of the token. */
191
530
  pm_token_type_t type;
531
+
532
+ /** A pointer to the start location of the token in the source. */
192
533
  const uint8_t *start;
534
+
535
+ /** A pointer to the end location of the token in the source. */
193
536
  const uint8_t *end;
194
537
  } pm_token_t;
195
538
 
196
- // This represents a range of bytes in the source string to which a node or
197
- // token corresponds.
539
+ /**
540
+ * This represents a range of bytes in the source string to which a node or
541
+ * token corresponds.
542
+ */
198
543
  typedef struct {
544
+ /** A pointer to the start location of the range in the source. */
199
545
  const uint8_t *start;
546
+
547
+ /** A pointer to the end location of the range in the source. */
200
548
  const uint8_t *end;
201
549
  } pm_location_t;
202
550
 
203
551
  struct pm_node;
204
552
 
553
+ /**
554
+ * A list of nodes in the source, most often used for lists of children.
555
+ */
205
556
  typedef struct pm_node_list {
206
- struct pm_node **nodes;
557
+ /** The number of nodes in the list. */
207
558
  size_t size;
559
+
560
+ /** The capacity of the list that has been allocated. */
208
561
  size_t capacity;
562
+
563
+ /** The nodes in the list. */
564
+ struct pm_node **nodes;
209
565
  } pm_node_list_t;
210
566
 
567
+ /**
568
+ * This enum represents every type of node in the Ruby syntax tree.
569
+ */
211
570
  enum pm_node_type {
571
+ /** AliasGlobalVariableNode */
212
572
  PM_ALIAS_GLOBAL_VARIABLE_NODE = 1,
573
+
574
+ /** AliasMethodNode */
213
575
  PM_ALIAS_METHOD_NODE = 2,
576
+
577
+ /** AlternationPatternNode */
214
578
  PM_ALTERNATION_PATTERN_NODE = 3,
579
+
580
+ /** AndNode */
215
581
  PM_AND_NODE = 4,
582
+
583
+ /** ArgumentsNode */
216
584
  PM_ARGUMENTS_NODE = 5,
585
+
586
+ /** ArrayNode */
217
587
  PM_ARRAY_NODE = 6,
588
+
589
+ /** ArrayPatternNode */
218
590
  PM_ARRAY_PATTERN_NODE = 7,
591
+
592
+ /** AssocNode */
219
593
  PM_ASSOC_NODE = 8,
594
+
595
+ /** AssocSplatNode */
220
596
  PM_ASSOC_SPLAT_NODE = 9,
597
+
598
+ /** BackReferenceReadNode */
221
599
  PM_BACK_REFERENCE_READ_NODE = 10,
600
+
601
+ /** BeginNode */
222
602
  PM_BEGIN_NODE = 11,
603
+
604
+ /** BlockArgumentNode */
223
605
  PM_BLOCK_ARGUMENT_NODE = 12,
606
+
607
+ /** BlockLocalVariableNode */
224
608
  PM_BLOCK_LOCAL_VARIABLE_NODE = 13,
609
+
610
+ /** BlockNode */
225
611
  PM_BLOCK_NODE = 14,
612
+
613
+ /** BlockParameterNode */
226
614
  PM_BLOCK_PARAMETER_NODE = 15,
615
+
616
+ /** BlockParametersNode */
227
617
  PM_BLOCK_PARAMETERS_NODE = 16,
618
+
619
+ /** BreakNode */
228
620
  PM_BREAK_NODE = 17,
621
+
622
+ /** CallAndWriteNode */
229
623
  PM_CALL_AND_WRITE_NODE = 18,
624
+
625
+ /** CallNode */
230
626
  PM_CALL_NODE = 19,
627
+
628
+ /** CallOperatorWriteNode */
231
629
  PM_CALL_OPERATOR_WRITE_NODE = 20,
630
+
631
+ /** CallOrWriteNode */
232
632
  PM_CALL_OR_WRITE_NODE = 21,
633
+
634
+ /** CapturePatternNode */
233
635
  PM_CAPTURE_PATTERN_NODE = 22,
636
+
637
+ /** CaseNode */
234
638
  PM_CASE_NODE = 23,
639
+
640
+ /** ClassNode */
235
641
  PM_CLASS_NODE = 24,
642
+
643
+ /** ClassVariableAndWriteNode */
236
644
  PM_CLASS_VARIABLE_AND_WRITE_NODE = 25,
645
+
646
+ /** ClassVariableOperatorWriteNode */
237
647
  PM_CLASS_VARIABLE_OPERATOR_WRITE_NODE = 26,
648
+
649
+ /** ClassVariableOrWriteNode */
238
650
  PM_CLASS_VARIABLE_OR_WRITE_NODE = 27,
651
+
652
+ /** ClassVariableReadNode */
239
653
  PM_CLASS_VARIABLE_READ_NODE = 28,
654
+
655
+ /** ClassVariableTargetNode */
240
656
  PM_CLASS_VARIABLE_TARGET_NODE = 29,
657
+
658
+ /** ClassVariableWriteNode */
241
659
  PM_CLASS_VARIABLE_WRITE_NODE = 30,
660
+
661
+ /** ConstantAndWriteNode */
242
662
  PM_CONSTANT_AND_WRITE_NODE = 31,
663
+
664
+ /** ConstantOperatorWriteNode */
243
665
  PM_CONSTANT_OPERATOR_WRITE_NODE = 32,
666
+
667
+ /** ConstantOrWriteNode */
244
668
  PM_CONSTANT_OR_WRITE_NODE = 33,
669
+
670
+ /** ConstantPathAndWriteNode */
245
671
  PM_CONSTANT_PATH_AND_WRITE_NODE = 34,
672
+
673
+ /** ConstantPathNode */
246
674
  PM_CONSTANT_PATH_NODE = 35,
675
+
676
+ /** ConstantPathOperatorWriteNode */
247
677
  PM_CONSTANT_PATH_OPERATOR_WRITE_NODE = 36,
678
+
679
+ /** ConstantPathOrWriteNode */
248
680
  PM_CONSTANT_PATH_OR_WRITE_NODE = 37,
681
+
682
+ /** ConstantPathTargetNode */
249
683
  PM_CONSTANT_PATH_TARGET_NODE = 38,
684
+
685
+ /** ConstantPathWriteNode */
250
686
  PM_CONSTANT_PATH_WRITE_NODE = 39,
687
+
688
+ /** ConstantReadNode */
251
689
  PM_CONSTANT_READ_NODE = 40,
690
+
691
+ /** ConstantTargetNode */
252
692
  PM_CONSTANT_TARGET_NODE = 41,
693
+
694
+ /** ConstantWriteNode */
253
695
  PM_CONSTANT_WRITE_NODE = 42,
696
+
697
+ /** DefNode */
254
698
  PM_DEF_NODE = 43,
699
+
700
+ /** DefinedNode */
255
701
  PM_DEFINED_NODE = 44,
702
+
703
+ /** ElseNode */
256
704
  PM_ELSE_NODE = 45,
705
+
706
+ /** EmbeddedStatementsNode */
257
707
  PM_EMBEDDED_STATEMENTS_NODE = 46,
708
+
709
+ /** EmbeddedVariableNode */
258
710
  PM_EMBEDDED_VARIABLE_NODE = 47,
711
+
712
+ /** EnsureNode */
259
713
  PM_ENSURE_NODE = 48,
714
+
715
+ /** FalseNode */
260
716
  PM_FALSE_NODE = 49,
717
+
718
+ /** FindPatternNode */
261
719
  PM_FIND_PATTERN_NODE = 50,
720
+
721
+ /** FlipFlopNode */
262
722
  PM_FLIP_FLOP_NODE = 51,
723
+
724
+ /** FloatNode */
263
725
  PM_FLOAT_NODE = 52,
726
+
727
+ /** ForNode */
264
728
  PM_FOR_NODE = 53,
729
+
730
+ /** ForwardingArgumentsNode */
265
731
  PM_FORWARDING_ARGUMENTS_NODE = 54,
732
+
733
+ /** ForwardingParameterNode */
266
734
  PM_FORWARDING_PARAMETER_NODE = 55,
735
+
736
+ /** ForwardingSuperNode */
267
737
  PM_FORWARDING_SUPER_NODE = 56,
738
+
739
+ /** GlobalVariableAndWriteNode */
268
740
  PM_GLOBAL_VARIABLE_AND_WRITE_NODE = 57,
741
+
742
+ /** GlobalVariableOperatorWriteNode */
269
743
  PM_GLOBAL_VARIABLE_OPERATOR_WRITE_NODE = 58,
744
+
745
+ /** GlobalVariableOrWriteNode */
270
746
  PM_GLOBAL_VARIABLE_OR_WRITE_NODE = 59,
747
+
748
+ /** GlobalVariableReadNode */
271
749
  PM_GLOBAL_VARIABLE_READ_NODE = 60,
750
+
751
+ /** GlobalVariableTargetNode */
272
752
  PM_GLOBAL_VARIABLE_TARGET_NODE = 61,
753
+
754
+ /** GlobalVariableWriteNode */
273
755
  PM_GLOBAL_VARIABLE_WRITE_NODE = 62,
756
+
757
+ /** HashNode */
274
758
  PM_HASH_NODE = 63,
759
+
760
+ /** HashPatternNode */
275
761
  PM_HASH_PATTERN_NODE = 64,
762
+
763
+ /** IfNode */
276
764
  PM_IF_NODE = 65,
765
+
766
+ /** ImaginaryNode */
277
767
  PM_IMAGINARY_NODE = 66,
768
+
769
+ /** ImplicitNode */
278
770
  PM_IMPLICIT_NODE = 67,
771
+
772
+ /** InNode */
279
773
  PM_IN_NODE = 68,
774
+
775
+ /** IndexAndWriteNode */
280
776
  PM_INDEX_AND_WRITE_NODE = 69,
777
+
778
+ /** IndexOperatorWriteNode */
281
779
  PM_INDEX_OPERATOR_WRITE_NODE = 70,
780
+
781
+ /** IndexOrWriteNode */
282
782
  PM_INDEX_OR_WRITE_NODE = 71,
783
+
784
+ /** InstanceVariableAndWriteNode */
283
785
  PM_INSTANCE_VARIABLE_AND_WRITE_NODE = 72,
786
+
787
+ /** InstanceVariableOperatorWriteNode */
284
788
  PM_INSTANCE_VARIABLE_OPERATOR_WRITE_NODE = 73,
789
+
790
+ /** InstanceVariableOrWriteNode */
285
791
  PM_INSTANCE_VARIABLE_OR_WRITE_NODE = 74,
792
+
793
+ /** InstanceVariableReadNode */
286
794
  PM_INSTANCE_VARIABLE_READ_NODE = 75,
795
+
796
+ /** InstanceVariableTargetNode */
287
797
  PM_INSTANCE_VARIABLE_TARGET_NODE = 76,
798
+
799
+ /** InstanceVariableWriteNode */
288
800
  PM_INSTANCE_VARIABLE_WRITE_NODE = 77,
801
+
802
+ /** IntegerNode */
289
803
  PM_INTEGER_NODE = 78,
804
+
805
+ /** InterpolatedMatchLastLineNode */
290
806
  PM_INTERPOLATED_MATCH_LAST_LINE_NODE = 79,
807
+
808
+ /** InterpolatedRegularExpressionNode */
291
809
  PM_INTERPOLATED_REGULAR_EXPRESSION_NODE = 80,
810
+
811
+ /** InterpolatedStringNode */
292
812
  PM_INTERPOLATED_STRING_NODE = 81,
813
+
814
+ /** InterpolatedSymbolNode */
293
815
  PM_INTERPOLATED_SYMBOL_NODE = 82,
816
+
817
+ /** InterpolatedXStringNode */
294
818
  PM_INTERPOLATED_X_STRING_NODE = 83,
819
+
820
+ /** KeywordHashNode */
295
821
  PM_KEYWORD_HASH_NODE = 84,
296
- PM_KEYWORD_PARAMETER_NODE = 85,
297
- PM_KEYWORD_REST_PARAMETER_NODE = 86,
298
- PM_LAMBDA_NODE = 87,
299
- PM_LOCAL_VARIABLE_AND_WRITE_NODE = 88,
300
- PM_LOCAL_VARIABLE_OPERATOR_WRITE_NODE = 89,
301
- PM_LOCAL_VARIABLE_OR_WRITE_NODE = 90,
302
- PM_LOCAL_VARIABLE_READ_NODE = 91,
303
- PM_LOCAL_VARIABLE_TARGET_NODE = 92,
304
- PM_LOCAL_VARIABLE_WRITE_NODE = 93,
305
- PM_MATCH_LAST_LINE_NODE = 94,
306
- PM_MATCH_PREDICATE_NODE = 95,
307
- PM_MATCH_REQUIRED_NODE = 96,
308
- PM_MATCH_WRITE_NODE = 97,
309
- PM_MISSING_NODE = 98,
310
- PM_MODULE_NODE = 99,
311
- PM_MULTI_TARGET_NODE = 100,
312
- PM_MULTI_WRITE_NODE = 101,
313
- PM_NEXT_NODE = 102,
314
- PM_NIL_NODE = 103,
315
- PM_NO_KEYWORDS_PARAMETER_NODE = 104,
316
- PM_NUMBERED_REFERENCE_READ_NODE = 105,
822
+
823
+ /** KeywordRestParameterNode */
824
+ PM_KEYWORD_REST_PARAMETER_NODE = 85,
825
+
826
+ /** LambdaNode */
827
+ PM_LAMBDA_NODE = 86,
828
+
829
+ /** LocalVariableAndWriteNode */
830
+ PM_LOCAL_VARIABLE_AND_WRITE_NODE = 87,
831
+
832
+ /** LocalVariableOperatorWriteNode */
833
+ PM_LOCAL_VARIABLE_OPERATOR_WRITE_NODE = 88,
834
+
835
+ /** LocalVariableOrWriteNode */
836
+ PM_LOCAL_VARIABLE_OR_WRITE_NODE = 89,
837
+
838
+ /** LocalVariableReadNode */
839
+ PM_LOCAL_VARIABLE_READ_NODE = 90,
840
+
841
+ /** LocalVariableTargetNode */
842
+ PM_LOCAL_VARIABLE_TARGET_NODE = 91,
843
+
844
+ /** LocalVariableWriteNode */
845
+ PM_LOCAL_VARIABLE_WRITE_NODE = 92,
846
+
847
+ /** MatchLastLineNode */
848
+ PM_MATCH_LAST_LINE_NODE = 93,
849
+
850
+ /** MatchPredicateNode */
851
+ PM_MATCH_PREDICATE_NODE = 94,
852
+
853
+ /** MatchRequiredNode */
854
+ PM_MATCH_REQUIRED_NODE = 95,
855
+
856
+ /** MatchWriteNode */
857
+ PM_MATCH_WRITE_NODE = 96,
858
+
859
+ /** MissingNode */
860
+ PM_MISSING_NODE = 97,
861
+
862
+ /** ModuleNode */
863
+ PM_MODULE_NODE = 98,
864
+
865
+ /** MultiTargetNode */
866
+ PM_MULTI_TARGET_NODE = 99,
867
+
868
+ /** MultiWriteNode */
869
+ PM_MULTI_WRITE_NODE = 100,
870
+
871
+ /** NextNode */
872
+ PM_NEXT_NODE = 101,
873
+
874
+ /** NilNode */
875
+ PM_NIL_NODE = 102,
876
+
877
+ /** NoKeywordsParameterNode */
878
+ PM_NO_KEYWORDS_PARAMETER_NODE = 103,
879
+
880
+ /** NumberedReferenceReadNode */
881
+ PM_NUMBERED_REFERENCE_READ_NODE = 104,
882
+
883
+ /** OptionalKeywordParameterNode */
884
+ PM_OPTIONAL_KEYWORD_PARAMETER_NODE = 105,
885
+
886
+ /** OptionalParameterNode */
317
887
  PM_OPTIONAL_PARAMETER_NODE = 106,
888
+
889
+ /** OrNode */
318
890
  PM_OR_NODE = 107,
891
+
892
+ /** ParametersNode */
319
893
  PM_PARAMETERS_NODE = 108,
894
+
895
+ /** ParenthesesNode */
320
896
  PM_PARENTHESES_NODE = 109,
897
+
898
+ /** PinnedExpressionNode */
321
899
  PM_PINNED_EXPRESSION_NODE = 110,
900
+
901
+ /** PinnedVariableNode */
322
902
  PM_PINNED_VARIABLE_NODE = 111,
903
+
904
+ /** PostExecutionNode */
323
905
  PM_POST_EXECUTION_NODE = 112,
906
+
907
+ /** PreExecutionNode */
324
908
  PM_PRE_EXECUTION_NODE = 113,
909
+
910
+ /** ProgramNode */
325
911
  PM_PROGRAM_NODE = 114,
912
+
913
+ /** RangeNode */
326
914
  PM_RANGE_NODE = 115,
915
+
916
+ /** RationalNode */
327
917
  PM_RATIONAL_NODE = 116,
918
+
919
+ /** RedoNode */
328
920
  PM_REDO_NODE = 117,
921
+
922
+ /** RegularExpressionNode */
329
923
  PM_REGULAR_EXPRESSION_NODE = 118,
330
- PM_REQUIRED_PARAMETER_NODE = 119,
331
- PM_RESCUE_MODIFIER_NODE = 120,
332
- PM_RESCUE_NODE = 121,
333
- PM_REST_PARAMETER_NODE = 122,
334
- PM_RETRY_NODE = 123,
335
- PM_RETURN_NODE = 124,
336
- PM_SELF_NODE = 125,
337
- PM_SINGLETON_CLASS_NODE = 126,
338
- PM_SOURCE_ENCODING_NODE = 127,
339
- PM_SOURCE_FILE_NODE = 128,
340
- PM_SOURCE_LINE_NODE = 129,
341
- PM_SPLAT_NODE = 130,
342
- PM_STATEMENTS_NODE = 131,
343
- PM_STRING_CONCAT_NODE = 132,
344
- PM_STRING_NODE = 133,
345
- PM_SUPER_NODE = 134,
346
- PM_SYMBOL_NODE = 135,
347
- PM_TRUE_NODE = 136,
348
- PM_UNDEF_NODE = 137,
349
- PM_UNLESS_NODE = 138,
350
- PM_UNTIL_NODE = 139,
351
- PM_WHEN_NODE = 140,
352
- PM_WHILE_NODE = 141,
353
- PM_X_STRING_NODE = 142,
354
- PM_YIELD_NODE = 143,
924
+
925
+ /** RequiredKeywordParameterNode */
926
+ PM_REQUIRED_KEYWORD_PARAMETER_NODE = 119,
927
+
928
+ /** RequiredParameterNode */
929
+ PM_REQUIRED_PARAMETER_NODE = 120,
930
+
931
+ /** RescueModifierNode */
932
+ PM_RESCUE_MODIFIER_NODE = 121,
933
+
934
+ /** RescueNode */
935
+ PM_RESCUE_NODE = 122,
936
+
937
+ /** RestParameterNode */
938
+ PM_REST_PARAMETER_NODE = 123,
939
+
940
+ /** RetryNode */
941
+ PM_RETRY_NODE = 124,
942
+
943
+ /** ReturnNode */
944
+ PM_RETURN_NODE = 125,
945
+
946
+ /** SelfNode */
947
+ PM_SELF_NODE = 126,
948
+
949
+ /** SingletonClassNode */
950
+ PM_SINGLETON_CLASS_NODE = 127,
951
+
952
+ /** SourceEncodingNode */
953
+ PM_SOURCE_ENCODING_NODE = 128,
954
+
955
+ /** SourceFileNode */
956
+ PM_SOURCE_FILE_NODE = 129,
957
+
958
+ /** SourceLineNode */
959
+ PM_SOURCE_LINE_NODE = 130,
960
+
961
+ /** SplatNode */
962
+ PM_SPLAT_NODE = 131,
963
+
964
+ /** StatementsNode */
965
+ PM_STATEMENTS_NODE = 132,
966
+
967
+ /** StringConcatNode */
968
+ PM_STRING_CONCAT_NODE = 133,
969
+
970
+ /** StringNode */
971
+ PM_STRING_NODE = 134,
972
+
973
+ /** SuperNode */
974
+ PM_SUPER_NODE = 135,
975
+
976
+ /** SymbolNode */
977
+ PM_SYMBOL_NODE = 136,
978
+
979
+ /** TrueNode */
980
+ PM_TRUE_NODE = 137,
981
+
982
+ /** UndefNode */
983
+ PM_UNDEF_NODE = 138,
984
+
985
+ /** UnlessNode */
986
+ PM_UNLESS_NODE = 139,
987
+
988
+ /** UntilNode */
989
+ PM_UNTIL_NODE = 140,
990
+
991
+ /** WhenNode */
992
+ PM_WHEN_NODE = 141,
993
+
994
+ /** WhileNode */
995
+ PM_WHILE_NODE = 142,
996
+
997
+ /** XStringNode */
998
+ PM_X_STRING_NODE = 143,
999
+
1000
+ /** YieldNode */
1001
+ PM_YIELD_NODE = 144,
1002
+
1003
+ /** A special kind of node used for compilation. */
355
1004
  PM_SCOPE_NODE
356
1005
  };
357
1006
 
1007
+ /**
1008
+ * This is the type of node embedded in the node struct. We explicitly control
1009
+ * the size of it here to avoid having the variable-width enum.
1010
+ */
358
1011
  typedef uint16_t pm_node_type_t;
1012
+
1013
+ /**
1014
+ * These are the flags embedded in the node struct. We explicitly control the
1015
+ * size of it here to avoid having the variable-width enum.
1016
+ */
359
1017
  typedef uint16_t pm_node_flags_t;
360
1018
 
361
- // We store the flags enum in every node in the tree. Some flags are common to
362
- // all nodes (the ones listed below). Others are specific to certain node types.
1019
+ /**
1020
+ * We store the flags enum in every node in the tree. Some flags are common to
1021
+ * all nodes (the ones listed below). Others are specific to certain node types.
1022
+ */
363
1023
  #define PM_NODE_FLAG_BITS (sizeof(pm_node_flags_t) * 8)
1024
+
364
1025
  static const pm_node_flags_t PM_NODE_FLAG_NEWLINE = (1 << (PM_NODE_FLAG_BITS - 1));
365
1026
  static const pm_node_flags_t PM_NODE_FLAG_STATIC_LITERAL = (1 << (PM_NODE_FLAG_BITS - 2));
366
1027
  static const pm_node_flags_t PM_NODE_FLAG_COMMON_MASK = (1 << (PM_NODE_FLAG_BITS - 1)) | (1 << (PM_NODE_FLAG_BITS - 2));
367
1028
 
368
- // For easy access, we define some macros to check node type
369
- #define PM_NODE_TYPE(node) ((enum pm_node_type)node->type)
1029
+ /**
1030
+ * Cast the type to an enum to allow the compiler to provide exhaustiveness
1031
+ * checking.
1032
+ */
1033
+ #define PM_NODE_TYPE(node) ((enum pm_node_type) node->type)
1034
+
1035
+ /**
1036
+ * Return true if the type of the given node matches the given type.
1037
+ */
370
1038
  #define PM_NODE_TYPE_P(node, type) (PM_NODE_TYPE(node) == (type))
371
1039
 
372
- // This is the overall tagged union representing a node in the syntax tree.
1040
+ /**
1041
+ * This is the base structure that represents a node in the syntax tree. It is
1042
+ * embedded into every node type.
1043
+ */
373
1044
  typedef struct pm_node {
374
- // This represents the type of the node. It somewhat maps to the nodes that
375
- // existed in the original grammar and ripper, but it's not a 1:1 mapping.
1045
+ /**
1046
+ * This represents the type of the node. It somewhat maps to the nodes that
1047
+ * existed in the original grammar and ripper, but it's not a 1:1 mapping.
1048
+ */
376
1049
  pm_node_type_t type;
377
1050
 
378
- // This represents any flags on the node
1051
+ /**
1052
+ * This represents any flags on the node. Some are common to all nodes, and
1053
+ * some are specific to the type of node.
1054
+ */
379
1055
  pm_node_flags_t flags;
380
1056
 
381
- // This is the location of the node in the source. It's a range of bytes
382
- // containing a start and an end.
1057
+ /**
1058
+ * This is the location of the node in the source. It's a range of bytes
1059
+ * containing a start and an end.
1060
+ */
383
1061
  pm_location_t location;
384
1062
  } pm_node_t;
385
1063
 
386
- // AliasGlobalVariableNode
387
- //
388
- // Type: PM_ALIAS_GLOBAL_VARIABLE_NODE
1064
+ /**
1065
+ * AliasGlobalVariableNode
1066
+ *
1067
+ * Type: PM_ALIAS_GLOBAL_VARIABLE_NODE
1068
+ *
1069
+ * @extends pm_node_t
1070
+ */
389
1071
  typedef struct pm_alias_global_variable_node {
1072
+ /** The embedded base node. */
390
1073
  pm_node_t base;
1074
+
1075
+ /** AliasGlobalVariableNode#new_name */
391
1076
  struct pm_node *new_name;
1077
+
1078
+ /** AliasGlobalVariableNode#old_name */
392
1079
  struct pm_node *old_name;
1080
+
1081
+ /** AliasGlobalVariableNode#keyword_loc */
393
1082
  pm_location_t keyword_loc;
394
1083
  } pm_alias_global_variable_node_t;
395
1084
 
396
- // AliasMethodNode
397
- //
398
- // Type: PM_ALIAS_METHOD_NODE
1085
+ /**
1086
+ * AliasMethodNode
1087
+ *
1088
+ * Type: PM_ALIAS_METHOD_NODE
1089
+ *
1090
+ * @extends pm_node_t
1091
+ */
399
1092
  typedef struct pm_alias_method_node {
1093
+ /** The embedded base node. */
400
1094
  pm_node_t base;
1095
+
1096
+ /** AliasMethodNode#new_name */
401
1097
  struct pm_node *new_name;
1098
+
1099
+ /** AliasMethodNode#old_name */
402
1100
  struct pm_node *old_name;
1101
+
1102
+ /** AliasMethodNode#keyword_loc */
403
1103
  pm_location_t keyword_loc;
404
1104
  } pm_alias_method_node_t;
405
1105
 
406
- // AlternationPatternNode
407
- //
408
- // Type: PM_ALTERNATION_PATTERN_NODE
1106
+ /**
1107
+ * AlternationPatternNode
1108
+ *
1109
+ * Type: PM_ALTERNATION_PATTERN_NODE
1110
+ *
1111
+ * @extends pm_node_t
1112
+ */
409
1113
  typedef struct pm_alternation_pattern_node {
1114
+ /** The embedded base node. */
410
1115
  pm_node_t base;
1116
+
1117
+ /** AlternationPatternNode#left */
411
1118
  struct pm_node *left;
1119
+
1120
+ /** AlternationPatternNode#right */
412
1121
  struct pm_node *right;
1122
+
1123
+ /** AlternationPatternNode#operator_loc */
413
1124
  pm_location_t operator_loc;
414
1125
  } pm_alternation_pattern_node_t;
415
1126
 
416
- // AndNode
417
- //
418
- // Type: PM_AND_NODE
1127
+ /**
1128
+ * AndNode
1129
+ *
1130
+ * Type: PM_AND_NODE
1131
+ *
1132
+ * @extends pm_node_t
1133
+ */
419
1134
  typedef struct pm_and_node {
1135
+ /** The embedded base node. */
420
1136
  pm_node_t base;
1137
+
1138
+ /** AndNode#left */
421
1139
  struct pm_node *left;
1140
+
1141
+ /** AndNode#right */
422
1142
  struct pm_node *right;
1143
+
1144
+ /** AndNode#operator_loc */
423
1145
  pm_location_t operator_loc;
424
1146
  } pm_and_node_t;
425
1147
 
426
- // ArgumentsNode
427
- //
428
- // Type: PM_ARGUMENTS_NODE
429
- // Flags:
430
- // PM_ARGUMENTS_NODE_FLAGS_KEYWORD_SPLAT
1148
+ /**
1149
+ * ArgumentsNode
1150
+ *
1151
+ * Type: PM_ARGUMENTS_NODE
1152
+ * Flags:
1153
+ * PM_ARGUMENTS_NODE_FLAGS_KEYWORD_SPLAT
1154
+ *
1155
+ * @extends pm_node_t
1156
+ */
431
1157
  typedef struct pm_arguments_node {
1158
+ /** The embedded base node. */
432
1159
  pm_node_t base;
1160
+
1161
+ /** ArgumentsNode#arguments */
433
1162
  struct pm_node_list arguments;
434
1163
  } pm_arguments_node_t;
435
1164
 
436
- // ArrayNode
437
- //
438
- // Type: PM_ARRAY_NODE
1165
+ /**
1166
+ * ArrayNode
1167
+ *
1168
+ * Type: PM_ARRAY_NODE
1169
+ *
1170
+ * @extends pm_node_t
1171
+ */
439
1172
  typedef struct pm_array_node {
1173
+ /** The embedded base node. */
440
1174
  pm_node_t base;
1175
+
1176
+ /** ArrayNode#elements */
441
1177
  struct pm_node_list elements;
1178
+
1179
+ /** ArrayNode#opening_loc */
442
1180
  pm_location_t opening_loc;
1181
+
1182
+ /** ArrayNode#closing_loc */
443
1183
  pm_location_t closing_loc;
444
1184
  } pm_array_node_t;
445
1185
 
446
- // ArrayPatternNode
447
- //
448
- // Type: PM_ARRAY_PATTERN_NODE
1186
+ /**
1187
+ * ArrayPatternNode
1188
+ *
1189
+ * Type: PM_ARRAY_PATTERN_NODE
1190
+ *
1191
+ * @extends pm_node_t
1192
+ */
449
1193
  typedef struct pm_array_pattern_node {
1194
+ /** The embedded base node. */
450
1195
  pm_node_t base;
1196
+
1197
+ /** ArrayPatternNode#constant */
451
1198
  struct pm_node *constant;
1199
+
1200
+ /** ArrayPatternNode#requireds */
452
1201
  struct pm_node_list requireds;
1202
+
1203
+ /** ArrayPatternNode#rest */
453
1204
  struct pm_node *rest;
1205
+
1206
+ /** ArrayPatternNode#posts */
454
1207
  struct pm_node_list posts;
1208
+
1209
+ /** ArrayPatternNode#opening_loc */
455
1210
  pm_location_t opening_loc;
1211
+
1212
+ /** ArrayPatternNode#closing_loc */
456
1213
  pm_location_t closing_loc;
457
1214
  } pm_array_pattern_node_t;
458
1215
 
459
- // AssocNode
460
- //
461
- // Type: PM_ASSOC_NODE
1216
+ /**
1217
+ * AssocNode
1218
+ *
1219
+ * Type: PM_ASSOC_NODE
1220
+ *
1221
+ * @extends pm_node_t
1222
+ */
462
1223
  typedef struct pm_assoc_node {
1224
+ /** The embedded base node. */
463
1225
  pm_node_t base;
1226
+
1227
+ /** AssocNode#key */
464
1228
  struct pm_node *key;
1229
+
1230
+ /** AssocNode#value */
465
1231
  struct pm_node *value;
1232
+
1233
+ /** AssocNode#operator_loc */
466
1234
  pm_location_t operator_loc;
467
1235
  } pm_assoc_node_t;
468
1236
 
469
- // AssocSplatNode
470
- //
471
- // Type: PM_ASSOC_SPLAT_NODE
1237
+ /**
1238
+ * AssocSplatNode
1239
+ *
1240
+ * Type: PM_ASSOC_SPLAT_NODE
1241
+ *
1242
+ * @extends pm_node_t
1243
+ */
472
1244
  typedef struct pm_assoc_splat_node {
1245
+ /** The embedded base node. */
473
1246
  pm_node_t base;
1247
+
1248
+ /** AssocSplatNode#value */
474
1249
  struct pm_node *value;
1250
+
1251
+ /** AssocSplatNode#operator_loc */
475
1252
  pm_location_t operator_loc;
476
1253
  } pm_assoc_splat_node_t;
477
1254
 
478
- // BackReferenceReadNode
479
- //
480
- // Type: PM_BACK_REFERENCE_READ_NODE
1255
+ /**
1256
+ * BackReferenceReadNode
1257
+ *
1258
+ * Type: PM_BACK_REFERENCE_READ_NODE
1259
+ *
1260
+ * @extends pm_node_t
1261
+ */
481
1262
  typedef struct pm_back_reference_read_node {
1263
+ /** The embedded base node. */
482
1264
  pm_node_t base;
1265
+
1266
+ /** BackReferenceReadNode#name */
483
1267
  pm_constant_id_t name;
484
1268
  } pm_back_reference_read_node_t;
485
1269
 
486
- // BeginNode
487
- //
488
- // Type: PM_BEGIN_NODE
1270
+ /**
1271
+ * BeginNode
1272
+ *
1273
+ * Type: PM_BEGIN_NODE
1274
+ *
1275
+ * @extends pm_node_t
1276
+ */
489
1277
  typedef struct pm_begin_node {
1278
+ /** The embedded base node. */
490
1279
  pm_node_t base;
1280
+
1281
+ /** BeginNode#begin_keyword_loc */
491
1282
  pm_location_t begin_keyword_loc;
1283
+
1284
+ /** BeginNode#statements */
492
1285
  struct pm_statements_node *statements;
1286
+
1287
+ /** BeginNode#rescue_clause */
493
1288
  struct pm_rescue_node *rescue_clause;
1289
+
1290
+ /** BeginNode#else_clause */
494
1291
  struct pm_else_node *else_clause;
1292
+
1293
+ /** BeginNode#ensure_clause */
495
1294
  struct pm_ensure_node *ensure_clause;
1295
+
1296
+ /** BeginNode#end_keyword_loc */
496
1297
  pm_location_t end_keyword_loc;
497
1298
  } pm_begin_node_t;
498
1299
 
499
- // BlockArgumentNode
500
- //
501
- // Type: PM_BLOCK_ARGUMENT_NODE
1300
+ /**
1301
+ * BlockArgumentNode
1302
+ *
1303
+ * Type: PM_BLOCK_ARGUMENT_NODE
1304
+ *
1305
+ * @extends pm_node_t
1306
+ */
502
1307
  typedef struct pm_block_argument_node {
1308
+ /** The embedded base node. */
503
1309
  pm_node_t base;
1310
+
1311
+ /** BlockArgumentNode#expression */
504
1312
  struct pm_node *expression;
1313
+
1314
+ /** BlockArgumentNode#operator_loc */
505
1315
  pm_location_t operator_loc;
506
1316
  } pm_block_argument_node_t;
507
1317
 
508
- // BlockLocalVariableNode
509
- //
510
- // Type: PM_BLOCK_LOCAL_VARIABLE_NODE
1318
+ /**
1319
+ * BlockLocalVariableNode
1320
+ *
1321
+ * Type: PM_BLOCK_LOCAL_VARIABLE_NODE
1322
+ *
1323
+ * @extends pm_node_t
1324
+ */
511
1325
  typedef struct pm_block_local_variable_node {
1326
+ /** The embedded base node. */
512
1327
  pm_node_t base;
1328
+
1329
+ /** BlockLocalVariableNode#name */
513
1330
  pm_constant_id_t name;
514
1331
  } pm_block_local_variable_node_t;
515
1332
 
516
- // BlockNode
517
- //
518
- // Type: PM_BLOCK_NODE
1333
+ /**
1334
+ * BlockNode
1335
+ *
1336
+ * Type: PM_BLOCK_NODE
1337
+ *
1338
+ * @extends pm_node_t
1339
+ */
519
1340
  typedef struct pm_block_node {
1341
+ /** The embedded base node. */
520
1342
  pm_node_t base;
1343
+
1344
+ /** BlockNode#locals */
521
1345
  pm_constant_id_list_t locals;
1346
+
1347
+ /** BlockNode#parameters */
522
1348
  struct pm_block_parameters_node *parameters;
1349
+
1350
+ /** BlockNode#body */
523
1351
  struct pm_node *body;
1352
+
1353
+ /** BlockNode#opening_loc */
524
1354
  pm_location_t opening_loc;
1355
+
1356
+ /** BlockNode#closing_loc */
525
1357
  pm_location_t closing_loc;
526
1358
  } pm_block_node_t;
527
1359
 
528
- // BlockParameterNode
529
- //
530
- // Type: PM_BLOCK_PARAMETER_NODE
1360
+ /**
1361
+ * BlockParameterNode
1362
+ *
1363
+ * Type: PM_BLOCK_PARAMETER_NODE
1364
+ *
1365
+ * @extends pm_node_t
1366
+ */
531
1367
  typedef struct pm_block_parameter_node {
1368
+ /** The embedded base node. */
532
1369
  pm_node_t base;
1370
+
1371
+ /** BlockParameterNode#name */
533
1372
  pm_constant_id_t name;
1373
+
1374
+ /** BlockParameterNode#name_loc */
534
1375
  pm_location_t name_loc;
1376
+
1377
+ /** BlockParameterNode#operator_loc */
535
1378
  pm_location_t operator_loc;
536
1379
  } pm_block_parameter_node_t;
537
1380
 
538
- // BlockParametersNode
539
- //
540
- // Type: PM_BLOCK_PARAMETERS_NODE
1381
+ /**
1382
+ * BlockParametersNode
1383
+ *
1384
+ * Type: PM_BLOCK_PARAMETERS_NODE
1385
+ *
1386
+ * @extends pm_node_t
1387
+ */
541
1388
  typedef struct pm_block_parameters_node {
1389
+ /** The embedded base node. */
542
1390
  pm_node_t base;
1391
+
1392
+ /** BlockParametersNode#parameters */
543
1393
  struct pm_parameters_node *parameters;
1394
+
1395
+ /** BlockParametersNode#locals */
544
1396
  struct pm_node_list locals;
1397
+
1398
+ /** BlockParametersNode#opening_loc */
545
1399
  pm_location_t opening_loc;
1400
+
1401
+ /** BlockParametersNode#closing_loc */
546
1402
  pm_location_t closing_loc;
547
1403
  } pm_block_parameters_node_t;
548
1404
 
549
- // BreakNode
550
- //
551
- // Type: PM_BREAK_NODE
1405
+ /**
1406
+ * BreakNode
1407
+ *
1408
+ * Type: PM_BREAK_NODE
1409
+ *
1410
+ * @extends pm_node_t
1411
+ */
552
1412
  typedef struct pm_break_node {
1413
+ /** The embedded base node. */
553
1414
  pm_node_t base;
1415
+
1416
+ /** BreakNode#arguments */
554
1417
  struct pm_arguments_node *arguments;
1418
+
1419
+ /** BreakNode#keyword_loc */
555
1420
  pm_location_t keyword_loc;
556
1421
  } pm_break_node_t;
557
1422
 
558
- // CallAndWriteNode
559
- //
560
- // Type: PM_CALL_AND_WRITE_NODE
561
- // Flags:
562
- // PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
563
- // PM_CALL_NODE_FLAGS_VARIABLE_CALL
1423
+ /**
1424
+ * CallAndWriteNode
1425
+ *
1426
+ * Type: PM_CALL_AND_WRITE_NODE
1427
+ * Flags:
1428
+ * PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
1429
+ * PM_CALL_NODE_FLAGS_VARIABLE_CALL
1430
+ *
1431
+ * @extends pm_node_t
1432
+ */
564
1433
  typedef struct pm_call_and_write_node {
1434
+ /** The embedded base node. */
565
1435
  pm_node_t base;
1436
+
1437
+ /** CallAndWriteNode#receiver */
566
1438
  struct pm_node *receiver;
1439
+
1440
+ /** CallAndWriteNode#call_operator_loc */
567
1441
  pm_location_t call_operator_loc;
1442
+
1443
+ /** CallAndWriteNode#message_loc */
568
1444
  pm_location_t message_loc;
1445
+
1446
+ /** CallAndWriteNode#read_name */
569
1447
  pm_constant_id_t read_name;
1448
+
1449
+ /** CallAndWriteNode#write_name */
570
1450
  pm_constant_id_t write_name;
1451
+
1452
+ /** CallAndWriteNode#operator_loc */
571
1453
  pm_location_t operator_loc;
1454
+
1455
+ /** CallAndWriteNode#value */
572
1456
  struct pm_node *value;
573
1457
  } pm_call_and_write_node_t;
574
1458
 
575
- // CallNode
576
- //
577
- // Type: PM_CALL_NODE
578
- // Flags:
579
- // PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
580
- // PM_CALL_NODE_FLAGS_VARIABLE_CALL
1459
+ /**
1460
+ * CallNode
1461
+ *
1462
+ * Type: PM_CALL_NODE
1463
+ * Flags:
1464
+ * PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
1465
+ * PM_CALL_NODE_FLAGS_VARIABLE_CALL
1466
+ *
1467
+ * @extends pm_node_t
1468
+ */
581
1469
  typedef struct pm_call_node {
1470
+ /** The embedded base node. */
582
1471
  pm_node_t base;
1472
+
1473
+ /** CallNode#receiver */
583
1474
  struct pm_node *receiver;
1475
+
1476
+ /** CallNode#call_operator_loc */
584
1477
  pm_location_t call_operator_loc;
1478
+
1479
+ /** CallNode#message_loc */
585
1480
  pm_location_t message_loc;
1481
+
1482
+ /** CallNode#opening_loc */
586
1483
  pm_location_t opening_loc;
1484
+
1485
+ /** CallNode#arguments */
587
1486
  struct pm_arguments_node *arguments;
1487
+
1488
+ /** CallNode#closing_loc */
588
1489
  pm_location_t closing_loc;
1490
+
1491
+ /** CallNode#block */
589
1492
  struct pm_node *block;
1493
+
1494
+ /** CallNode#name */
590
1495
  pm_constant_id_t name;
591
1496
  } pm_call_node_t;
592
1497
 
593
- // CallOperatorWriteNode
594
- //
595
- // Type: PM_CALL_OPERATOR_WRITE_NODE
596
- // Flags:
597
- // PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
598
- // PM_CALL_NODE_FLAGS_VARIABLE_CALL
1498
+ /**
1499
+ * CallOperatorWriteNode
1500
+ *
1501
+ * Type: PM_CALL_OPERATOR_WRITE_NODE
1502
+ * Flags:
1503
+ * PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
1504
+ * PM_CALL_NODE_FLAGS_VARIABLE_CALL
1505
+ *
1506
+ * @extends pm_node_t
1507
+ */
599
1508
  typedef struct pm_call_operator_write_node {
1509
+ /** The embedded base node. */
600
1510
  pm_node_t base;
1511
+
1512
+ /** CallOperatorWriteNode#receiver */
601
1513
  struct pm_node *receiver;
1514
+
1515
+ /** CallOperatorWriteNode#call_operator_loc */
602
1516
  pm_location_t call_operator_loc;
1517
+
1518
+ /** CallOperatorWriteNode#message_loc */
603
1519
  pm_location_t message_loc;
1520
+
1521
+ /** CallOperatorWriteNode#read_name */
604
1522
  pm_constant_id_t read_name;
1523
+
1524
+ /** CallOperatorWriteNode#write_name */
605
1525
  pm_constant_id_t write_name;
1526
+
1527
+ /** CallOperatorWriteNode#operator */
606
1528
  pm_constant_id_t operator;
1529
+
1530
+ /** CallOperatorWriteNode#operator_loc */
607
1531
  pm_location_t operator_loc;
1532
+
1533
+ /** CallOperatorWriteNode#value */
608
1534
  struct pm_node *value;
609
1535
  } pm_call_operator_write_node_t;
610
1536
 
611
- // CallOrWriteNode
612
- //
613
- // Type: PM_CALL_OR_WRITE_NODE
614
- // Flags:
615
- // PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
616
- // PM_CALL_NODE_FLAGS_VARIABLE_CALL
1537
+ /**
1538
+ * CallOrWriteNode
1539
+ *
1540
+ * Type: PM_CALL_OR_WRITE_NODE
1541
+ * Flags:
1542
+ * PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
1543
+ * PM_CALL_NODE_FLAGS_VARIABLE_CALL
1544
+ *
1545
+ * @extends pm_node_t
1546
+ */
617
1547
  typedef struct pm_call_or_write_node {
1548
+ /** The embedded base node. */
618
1549
  pm_node_t base;
1550
+
1551
+ /** CallOrWriteNode#receiver */
619
1552
  struct pm_node *receiver;
1553
+
1554
+ /** CallOrWriteNode#call_operator_loc */
620
1555
  pm_location_t call_operator_loc;
1556
+
1557
+ /** CallOrWriteNode#message_loc */
621
1558
  pm_location_t message_loc;
1559
+
1560
+ /** CallOrWriteNode#read_name */
622
1561
  pm_constant_id_t read_name;
1562
+
1563
+ /** CallOrWriteNode#write_name */
623
1564
  pm_constant_id_t write_name;
1565
+
1566
+ /** CallOrWriteNode#operator_loc */
624
1567
  pm_location_t operator_loc;
1568
+
1569
+ /** CallOrWriteNode#value */
625
1570
  struct pm_node *value;
626
1571
  } pm_call_or_write_node_t;
627
1572
 
628
- // CapturePatternNode
629
- //
630
- // Type: PM_CAPTURE_PATTERN_NODE
1573
+ /**
1574
+ * CapturePatternNode
1575
+ *
1576
+ * Type: PM_CAPTURE_PATTERN_NODE
1577
+ *
1578
+ * @extends pm_node_t
1579
+ */
631
1580
  typedef struct pm_capture_pattern_node {
1581
+ /** The embedded base node. */
632
1582
  pm_node_t base;
1583
+
1584
+ /** CapturePatternNode#value */
633
1585
  struct pm_node *value;
1586
+
1587
+ /** CapturePatternNode#target */
634
1588
  struct pm_node *target;
1589
+
1590
+ /** CapturePatternNode#operator_loc */
635
1591
  pm_location_t operator_loc;
636
1592
  } pm_capture_pattern_node_t;
637
1593
 
638
- // CaseNode
639
- //
640
- // Type: PM_CASE_NODE
1594
+ /**
1595
+ * CaseNode
1596
+ *
1597
+ * Type: PM_CASE_NODE
1598
+ *
1599
+ * @extends pm_node_t
1600
+ */
641
1601
  typedef struct pm_case_node {
1602
+ /** The embedded base node. */
642
1603
  pm_node_t base;
1604
+
1605
+ /** CaseNode#predicate */
643
1606
  struct pm_node *predicate;
1607
+
1608
+ /** CaseNode#conditions */
644
1609
  struct pm_node_list conditions;
1610
+
1611
+ /** CaseNode#consequent */
645
1612
  struct pm_else_node *consequent;
1613
+
1614
+ /** CaseNode#case_keyword_loc */
646
1615
  pm_location_t case_keyword_loc;
1616
+
1617
+ /** CaseNode#end_keyword_loc */
647
1618
  pm_location_t end_keyword_loc;
648
1619
  } pm_case_node_t;
649
1620
 
650
- // ClassNode
651
- //
652
- // Type: PM_CLASS_NODE
1621
+ /**
1622
+ * ClassNode
1623
+ *
1624
+ * Type: PM_CLASS_NODE
1625
+ *
1626
+ * @extends pm_node_t
1627
+ */
653
1628
  typedef struct pm_class_node {
1629
+ /** The embedded base node. */
654
1630
  pm_node_t base;
1631
+
1632
+ /** ClassNode#locals */
655
1633
  pm_constant_id_list_t locals;
1634
+
1635
+ /** ClassNode#class_keyword_loc */
656
1636
  pm_location_t class_keyword_loc;
1637
+
1638
+ /** ClassNode#constant_path */
657
1639
  struct pm_node *constant_path;
1640
+
1641
+ /** ClassNode#inheritance_operator_loc */
658
1642
  pm_location_t inheritance_operator_loc;
1643
+
1644
+ /** ClassNode#superclass */
659
1645
  struct pm_node *superclass;
1646
+
1647
+ /** ClassNode#body */
660
1648
  struct pm_node *body;
1649
+
1650
+ /** ClassNode#end_keyword_loc */
661
1651
  pm_location_t end_keyword_loc;
1652
+
1653
+ /** ClassNode#name */
662
1654
  pm_constant_id_t name;
663
1655
  } pm_class_node_t;
664
1656
 
665
- // ClassVariableAndWriteNode
666
- //
667
- // Type: PM_CLASS_VARIABLE_AND_WRITE_NODE
1657
+ /**
1658
+ * ClassVariableAndWriteNode
1659
+ *
1660
+ * Type: PM_CLASS_VARIABLE_AND_WRITE_NODE
1661
+ *
1662
+ * @extends pm_node_t
1663
+ */
668
1664
  typedef struct pm_class_variable_and_write_node {
1665
+ /** The embedded base node. */
669
1666
  pm_node_t base;
1667
+
1668
+ /** ClassVariableAndWriteNode#name */
670
1669
  pm_constant_id_t name;
1670
+
1671
+ /** ClassVariableAndWriteNode#name_loc */
671
1672
  pm_location_t name_loc;
1673
+
1674
+ /** ClassVariableAndWriteNode#operator_loc */
672
1675
  pm_location_t operator_loc;
1676
+
1677
+ /** ClassVariableAndWriteNode#value */
673
1678
  struct pm_node *value;
674
1679
  } pm_class_variable_and_write_node_t;
675
1680
 
676
- // ClassVariableOperatorWriteNode
677
- //
678
- // Type: PM_CLASS_VARIABLE_OPERATOR_WRITE_NODE
1681
+ /**
1682
+ * ClassVariableOperatorWriteNode
1683
+ *
1684
+ * Type: PM_CLASS_VARIABLE_OPERATOR_WRITE_NODE
1685
+ *
1686
+ * @extends pm_node_t
1687
+ */
679
1688
  typedef struct pm_class_variable_operator_write_node {
1689
+ /** The embedded base node. */
680
1690
  pm_node_t base;
1691
+
1692
+ /** ClassVariableOperatorWriteNode#name */
681
1693
  pm_constant_id_t name;
1694
+
1695
+ /** ClassVariableOperatorWriteNode#name_loc */
682
1696
  pm_location_t name_loc;
1697
+
1698
+ /** ClassVariableOperatorWriteNode#operator_loc */
683
1699
  pm_location_t operator_loc;
1700
+
1701
+ /** ClassVariableOperatorWriteNode#value */
684
1702
  struct pm_node *value;
1703
+
1704
+ /** ClassVariableOperatorWriteNode#operator */
685
1705
  pm_constant_id_t operator;
686
1706
  } pm_class_variable_operator_write_node_t;
687
1707
 
688
- // ClassVariableOrWriteNode
689
- //
690
- // Type: PM_CLASS_VARIABLE_OR_WRITE_NODE
1708
+ /**
1709
+ * ClassVariableOrWriteNode
1710
+ *
1711
+ * Type: PM_CLASS_VARIABLE_OR_WRITE_NODE
1712
+ *
1713
+ * @extends pm_node_t
1714
+ */
691
1715
  typedef struct pm_class_variable_or_write_node {
1716
+ /** The embedded base node. */
692
1717
  pm_node_t base;
1718
+
1719
+ /** ClassVariableOrWriteNode#name */
693
1720
  pm_constant_id_t name;
1721
+
1722
+ /** ClassVariableOrWriteNode#name_loc */
694
1723
  pm_location_t name_loc;
1724
+
1725
+ /** ClassVariableOrWriteNode#operator_loc */
695
1726
  pm_location_t operator_loc;
1727
+
1728
+ /** ClassVariableOrWriteNode#value */
696
1729
  struct pm_node *value;
697
1730
  } pm_class_variable_or_write_node_t;
698
1731
 
699
- // ClassVariableReadNode
700
- //
701
- // Type: PM_CLASS_VARIABLE_READ_NODE
1732
+ /**
1733
+ * ClassVariableReadNode
1734
+ *
1735
+ * Type: PM_CLASS_VARIABLE_READ_NODE
1736
+ *
1737
+ * @extends pm_node_t
1738
+ */
702
1739
  typedef struct pm_class_variable_read_node {
1740
+ /** The embedded base node. */
703
1741
  pm_node_t base;
1742
+
1743
+ /** ClassVariableReadNode#name */
704
1744
  pm_constant_id_t name;
705
1745
  } pm_class_variable_read_node_t;
706
1746
 
707
- // ClassVariableTargetNode
708
- //
709
- // Type: PM_CLASS_VARIABLE_TARGET_NODE
1747
+ /**
1748
+ * ClassVariableTargetNode
1749
+ *
1750
+ * Type: PM_CLASS_VARIABLE_TARGET_NODE
1751
+ *
1752
+ * @extends pm_node_t
1753
+ */
710
1754
  typedef struct pm_class_variable_target_node {
1755
+ /** The embedded base node. */
711
1756
  pm_node_t base;
1757
+
1758
+ /** ClassVariableTargetNode#name */
712
1759
  pm_constant_id_t name;
713
1760
  } pm_class_variable_target_node_t;
714
1761
 
715
- // ClassVariableWriteNode
716
- //
717
- // Type: PM_CLASS_VARIABLE_WRITE_NODE
1762
+ /**
1763
+ * ClassVariableWriteNode
1764
+ *
1765
+ * Type: PM_CLASS_VARIABLE_WRITE_NODE
1766
+ *
1767
+ * @extends pm_node_t
1768
+ */
718
1769
  typedef struct pm_class_variable_write_node {
1770
+ /** The embedded base node. */
719
1771
  pm_node_t base;
1772
+
1773
+ /** ClassVariableWriteNode#name */
720
1774
  pm_constant_id_t name;
1775
+
1776
+ /** ClassVariableWriteNode#name_loc */
721
1777
  pm_location_t name_loc;
1778
+
1779
+ /** ClassVariableWriteNode#value */
722
1780
  struct pm_node *value;
1781
+
1782
+ /** ClassVariableWriteNode#operator_loc */
723
1783
  pm_location_t operator_loc;
724
1784
  } pm_class_variable_write_node_t;
725
1785
 
726
- // ConstantAndWriteNode
727
- //
728
- // Type: PM_CONSTANT_AND_WRITE_NODE
1786
+ /**
1787
+ * ConstantAndWriteNode
1788
+ *
1789
+ * Type: PM_CONSTANT_AND_WRITE_NODE
1790
+ *
1791
+ * @extends pm_node_t
1792
+ */
729
1793
  typedef struct pm_constant_and_write_node {
1794
+ /** The embedded base node. */
730
1795
  pm_node_t base;
1796
+
1797
+ /** ConstantAndWriteNode#name */
731
1798
  pm_constant_id_t name;
1799
+
1800
+ /** ConstantAndWriteNode#name_loc */
732
1801
  pm_location_t name_loc;
1802
+
1803
+ /** ConstantAndWriteNode#operator_loc */
733
1804
  pm_location_t operator_loc;
1805
+
1806
+ /** ConstantAndWriteNode#value */
734
1807
  struct pm_node *value;
735
1808
  } pm_constant_and_write_node_t;
736
1809
 
737
- // ConstantOperatorWriteNode
738
- //
739
- // Type: PM_CONSTANT_OPERATOR_WRITE_NODE
1810
+ /**
1811
+ * ConstantOperatorWriteNode
1812
+ *
1813
+ * Type: PM_CONSTANT_OPERATOR_WRITE_NODE
1814
+ *
1815
+ * @extends pm_node_t
1816
+ */
740
1817
  typedef struct pm_constant_operator_write_node {
1818
+ /** The embedded base node. */
741
1819
  pm_node_t base;
1820
+
1821
+ /** ConstantOperatorWriteNode#name */
742
1822
  pm_constant_id_t name;
1823
+
1824
+ /** ConstantOperatorWriteNode#name_loc */
743
1825
  pm_location_t name_loc;
1826
+
1827
+ /** ConstantOperatorWriteNode#operator_loc */
744
1828
  pm_location_t operator_loc;
1829
+
1830
+ /** ConstantOperatorWriteNode#value */
745
1831
  struct pm_node *value;
1832
+
1833
+ /** ConstantOperatorWriteNode#operator */
746
1834
  pm_constant_id_t operator;
747
1835
  } pm_constant_operator_write_node_t;
748
1836
 
749
- // ConstantOrWriteNode
750
- //
751
- // Type: PM_CONSTANT_OR_WRITE_NODE
1837
+ /**
1838
+ * ConstantOrWriteNode
1839
+ *
1840
+ * Type: PM_CONSTANT_OR_WRITE_NODE
1841
+ *
1842
+ * @extends pm_node_t
1843
+ */
752
1844
  typedef struct pm_constant_or_write_node {
1845
+ /** The embedded base node. */
753
1846
  pm_node_t base;
1847
+
1848
+ /** ConstantOrWriteNode#name */
754
1849
  pm_constant_id_t name;
1850
+
1851
+ /** ConstantOrWriteNode#name_loc */
755
1852
  pm_location_t name_loc;
1853
+
1854
+ /** ConstantOrWriteNode#operator_loc */
756
1855
  pm_location_t operator_loc;
1856
+
1857
+ /** ConstantOrWriteNode#value */
757
1858
  struct pm_node *value;
758
1859
  } pm_constant_or_write_node_t;
759
1860
 
760
- // ConstantPathAndWriteNode
761
- //
762
- // Type: PM_CONSTANT_PATH_AND_WRITE_NODE
1861
+ /**
1862
+ * ConstantPathAndWriteNode
1863
+ *
1864
+ * Type: PM_CONSTANT_PATH_AND_WRITE_NODE
1865
+ *
1866
+ * @extends pm_node_t
1867
+ */
763
1868
  typedef struct pm_constant_path_and_write_node {
1869
+ /** The embedded base node. */
764
1870
  pm_node_t base;
1871
+
1872
+ /** ConstantPathAndWriteNode#target */
765
1873
  struct pm_constant_path_node *target;
1874
+
1875
+ /** ConstantPathAndWriteNode#operator_loc */
766
1876
  pm_location_t operator_loc;
1877
+
1878
+ /** ConstantPathAndWriteNode#value */
767
1879
  struct pm_node *value;
768
1880
  } pm_constant_path_and_write_node_t;
769
1881
 
770
- // ConstantPathNode
771
- //
772
- // Type: PM_CONSTANT_PATH_NODE
1882
+ /**
1883
+ * ConstantPathNode
1884
+ *
1885
+ * Type: PM_CONSTANT_PATH_NODE
1886
+ *
1887
+ * @extends pm_node_t
1888
+ */
773
1889
  typedef struct pm_constant_path_node {
1890
+ /** The embedded base node. */
774
1891
  pm_node_t base;
1892
+
1893
+ /** ConstantPathNode#parent */
775
1894
  struct pm_node *parent;
1895
+
1896
+ /** ConstantPathNode#child */
776
1897
  struct pm_node *child;
1898
+
1899
+ /** ConstantPathNode#delimiter_loc */
777
1900
  pm_location_t delimiter_loc;
778
1901
  } pm_constant_path_node_t;
779
1902
 
780
- // ConstantPathOperatorWriteNode
781
- //
782
- // Type: PM_CONSTANT_PATH_OPERATOR_WRITE_NODE
1903
+ /**
1904
+ * ConstantPathOperatorWriteNode
1905
+ *
1906
+ * Type: PM_CONSTANT_PATH_OPERATOR_WRITE_NODE
1907
+ *
1908
+ * @extends pm_node_t
1909
+ */
783
1910
  typedef struct pm_constant_path_operator_write_node {
1911
+ /** The embedded base node. */
784
1912
  pm_node_t base;
1913
+
1914
+ /** ConstantPathOperatorWriteNode#target */
785
1915
  struct pm_constant_path_node *target;
1916
+
1917
+ /** ConstantPathOperatorWriteNode#operator_loc */
786
1918
  pm_location_t operator_loc;
1919
+
1920
+ /** ConstantPathOperatorWriteNode#value */
787
1921
  struct pm_node *value;
1922
+
1923
+ /** ConstantPathOperatorWriteNode#operator */
788
1924
  pm_constant_id_t operator;
789
1925
  } pm_constant_path_operator_write_node_t;
790
1926
 
791
- // ConstantPathOrWriteNode
792
- //
793
- // Type: PM_CONSTANT_PATH_OR_WRITE_NODE
1927
+ /**
1928
+ * ConstantPathOrWriteNode
1929
+ *
1930
+ * Type: PM_CONSTANT_PATH_OR_WRITE_NODE
1931
+ *
1932
+ * @extends pm_node_t
1933
+ */
794
1934
  typedef struct pm_constant_path_or_write_node {
1935
+ /** The embedded base node. */
795
1936
  pm_node_t base;
1937
+
1938
+ /** ConstantPathOrWriteNode#target */
796
1939
  struct pm_constant_path_node *target;
1940
+
1941
+ /** ConstantPathOrWriteNode#operator_loc */
797
1942
  pm_location_t operator_loc;
1943
+
1944
+ /** ConstantPathOrWriteNode#value */
798
1945
  struct pm_node *value;
799
1946
  } pm_constant_path_or_write_node_t;
800
1947
 
801
- // ConstantPathTargetNode
802
- //
803
- // Type: PM_CONSTANT_PATH_TARGET_NODE
1948
+ /**
1949
+ * ConstantPathTargetNode
1950
+ *
1951
+ * Type: PM_CONSTANT_PATH_TARGET_NODE
1952
+ *
1953
+ * @extends pm_node_t
1954
+ */
804
1955
  typedef struct pm_constant_path_target_node {
1956
+ /** The embedded base node. */
805
1957
  pm_node_t base;
1958
+
1959
+ /** ConstantPathTargetNode#parent */
806
1960
  struct pm_node *parent;
1961
+
1962
+ /** ConstantPathTargetNode#child */
807
1963
  struct pm_node *child;
1964
+
1965
+ /** ConstantPathTargetNode#delimiter_loc */
808
1966
  pm_location_t delimiter_loc;
809
1967
  } pm_constant_path_target_node_t;
810
1968
 
811
- // ConstantPathWriteNode
812
- //
813
- // Type: PM_CONSTANT_PATH_WRITE_NODE
1969
+ /**
1970
+ * ConstantPathWriteNode
1971
+ *
1972
+ * Type: PM_CONSTANT_PATH_WRITE_NODE
1973
+ *
1974
+ * @extends pm_node_t
1975
+ */
814
1976
  typedef struct pm_constant_path_write_node {
1977
+ /** The embedded base node. */
815
1978
  pm_node_t base;
1979
+
1980
+ /** ConstantPathWriteNode#target */
816
1981
  struct pm_constant_path_node *target;
1982
+
1983
+ /** ConstantPathWriteNode#operator_loc */
817
1984
  pm_location_t operator_loc;
1985
+
1986
+ /** ConstantPathWriteNode#value */
818
1987
  struct pm_node *value;
819
1988
  } pm_constant_path_write_node_t;
820
1989
 
821
- // ConstantReadNode
822
- //
823
- // Type: PM_CONSTANT_READ_NODE
1990
+ /**
1991
+ * ConstantReadNode
1992
+ *
1993
+ * Type: PM_CONSTANT_READ_NODE
1994
+ *
1995
+ * @extends pm_node_t
1996
+ */
824
1997
  typedef struct pm_constant_read_node {
1998
+ /** The embedded base node. */
825
1999
  pm_node_t base;
2000
+
2001
+ /** ConstantReadNode#name */
826
2002
  pm_constant_id_t name;
827
2003
  } pm_constant_read_node_t;
828
2004
 
829
- // ConstantTargetNode
830
- //
831
- // Type: PM_CONSTANT_TARGET_NODE
2005
+ /**
2006
+ * ConstantTargetNode
2007
+ *
2008
+ * Type: PM_CONSTANT_TARGET_NODE
2009
+ *
2010
+ * @extends pm_node_t
2011
+ */
832
2012
  typedef struct pm_constant_target_node {
2013
+ /** The embedded base node. */
833
2014
  pm_node_t base;
2015
+
2016
+ /** ConstantTargetNode#name */
834
2017
  pm_constant_id_t name;
835
2018
  } pm_constant_target_node_t;
836
2019
 
837
- // ConstantWriteNode
838
- //
839
- // Type: PM_CONSTANT_WRITE_NODE
2020
+ /**
2021
+ * ConstantWriteNode
2022
+ *
2023
+ * Type: PM_CONSTANT_WRITE_NODE
2024
+ *
2025
+ * @extends pm_node_t
2026
+ */
840
2027
  typedef struct pm_constant_write_node {
2028
+ /** The embedded base node. */
841
2029
  pm_node_t base;
2030
+
2031
+ /** ConstantWriteNode#name */
842
2032
  pm_constant_id_t name;
2033
+
2034
+ /** ConstantWriteNode#name_loc */
843
2035
  pm_location_t name_loc;
2036
+
2037
+ /** ConstantWriteNode#value */
844
2038
  struct pm_node *value;
2039
+
2040
+ /** ConstantWriteNode#operator_loc */
845
2041
  pm_location_t operator_loc;
846
2042
  } pm_constant_write_node_t;
847
2043
 
848
- // DefNode
849
- //
850
- // Type: PM_DEF_NODE
2044
+ /**
2045
+ * DefNode
2046
+ *
2047
+ * Type: PM_DEF_NODE
2048
+ *
2049
+ * @extends pm_node_t
2050
+ */
851
2051
  typedef struct pm_def_node {
2052
+ /** The embedded base node. */
852
2053
  pm_node_t base;
2054
+
2055
+ /** DefNode#name */
853
2056
  pm_constant_id_t name;
2057
+
2058
+ /** DefNode#name_loc */
854
2059
  pm_location_t name_loc;
2060
+
2061
+ /** DefNode#receiver */
855
2062
  struct pm_node *receiver;
2063
+
2064
+ /** DefNode#parameters */
856
2065
  struct pm_parameters_node *parameters;
2066
+
2067
+ /** DefNode#body */
857
2068
  struct pm_node *body;
2069
+
2070
+ /** DefNode#locals */
858
2071
  pm_constant_id_list_t locals;
2072
+
2073
+ /** DefNode#def_keyword_loc */
859
2074
  pm_location_t def_keyword_loc;
2075
+
2076
+ /** DefNode#operator_loc */
860
2077
  pm_location_t operator_loc;
2078
+
2079
+ /** DefNode#lparen_loc */
861
2080
  pm_location_t lparen_loc;
2081
+
2082
+ /** DefNode#rparen_loc */
862
2083
  pm_location_t rparen_loc;
2084
+
2085
+ /** DefNode#equal_loc */
863
2086
  pm_location_t equal_loc;
2087
+
2088
+ /** DefNode#end_keyword_loc */
864
2089
  pm_location_t end_keyword_loc;
865
2090
  } pm_def_node_t;
866
2091
 
867
- // DefinedNode
868
- //
869
- // Type: PM_DEFINED_NODE
2092
+ /**
2093
+ * DefinedNode
2094
+ *
2095
+ * Type: PM_DEFINED_NODE
2096
+ *
2097
+ * @extends pm_node_t
2098
+ */
870
2099
  typedef struct pm_defined_node {
2100
+ /** The embedded base node. */
871
2101
  pm_node_t base;
2102
+
2103
+ /** DefinedNode#lparen_loc */
872
2104
  pm_location_t lparen_loc;
2105
+
2106
+ /** DefinedNode#value */
873
2107
  struct pm_node *value;
2108
+
2109
+ /** DefinedNode#rparen_loc */
874
2110
  pm_location_t rparen_loc;
2111
+
2112
+ /** DefinedNode#keyword_loc */
875
2113
  pm_location_t keyword_loc;
876
2114
  } pm_defined_node_t;
877
2115
 
878
- // ElseNode
879
- //
880
- // Type: PM_ELSE_NODE
2116
+ /**
2117
+ * ElseNode
2118
+ *
2119
+ * Type: PM_ELSE_NODE
2120
+ *
2121
+ * @extends pm_node_t
2122
+ */
881
2123
  typedef struct pm_else_node {
2124
+ /** The embedded base node. */
882
2125
  pm_node_t base;
2126
+
2127
+ /** ElseNode#else_keyword_loc */
883
2128
  pm_location_t else_keyword_loc;
2129
+
2130
+ /** ElseNode#statements */
884
2131
  struct pm_statements_node *statements;
2132
+
2133
+ /** ElseNode#end_keyword_loc */
885
2134
  pm_location_t end_keyword_loc;
886
2135
  } pm_else_node_t;
887
2136
 
888
- // EmbeddedStatementsNode
889
- //
890
- // Type: PM_EMBEDDED_STATEMENTS_NODE
2137
+ /**
2138
+ * EmbeddedStatementsNode
2139
+ *
2140
+ * Type: PM_EMBEDDED_STATEMENTS_NODE
2141
+ *
2142
+ * @extends pm_node_t
2143
+ */
891
2144
  typedef struct pm_embedded_statements_node {
2145
+ /** The embedded base node. */
892
2146
  pm_node_t base;
2147
+
2148
+ /** EmbeddedStatementsNode#opening_loc */
893
2149
  pm_location_t opening_loc;
2150
+
2151
+ /** EmbeddedStatementsNode#statements */
894
2152
  struct pm_statements_node *statements;
2153
+
2154
+ /** EmbeddedStatementsNode#closing_loc */
895
2155
  pm_location_t closing_loc;
896
2156
  } pm_embedded_statements_node_t;
897
2157
 
898
- // EmbeddedVariableNode
899
- //
900
- // Type: PM_EMBEDDED_VARIABLE_NODE
2158
+ /**
2159
+ * EmbeddedVariableNode
2160
+ *
2161
+ * Type: PM_EMBEDDED_VARIABLE_NODE
2162
+ *
2163
+ * @extends pm_node_t
2164
+ */
901
2165
  typedef struct pm_embedded_variable_node {
2166
+ /** The embedded base node. */
902
2167
  pm_node_t base;
2168
+
2169
+ /** EmbeddedVariableNode#operator_loc */
903
2170
  pm_location_t operator_loc;
2171
+
2172
+ /** EmbeddedVariableNode#variable */
904
2173
  struct pm_node *variable;
905
2174
  } pm_embedded_variable_node_t;
906
2175
 
907
- // EnsureNode
908
- //
909
- // Type: PM_ENSURE_NODE
2176
+ /**
2177
+ * EnsureNode
2178
+ *
2179
+ * Type: PM_ENSURE_NODE
2180
+ *
2181
+ * @extends pm_node_t
2182
+ */
910
2183
  typedef struct pm_ensure_node {
2184
+ /** The embedded base node. */
911
2185
  pm_node_t base;
2186
+
2187
+ /** EnsureNode#ensure_keyword_loc */
912
2188
  pm_location_t ensure_keyword_loc;
2189
+
2190
+ /** EnsureNode#statements */
913
2191
  struct pm_statements_node *statements;
2192
+
2193
+ /** EnsureNode#end_keyword_loc */
914
2194
  pm_location_t end_keyword_loc;
915
2195
  } pm_ensure_node_t;
916
2196
 
917
- // FalseNode
918
- //
919
- // Type: PM_FALSE_NODE
2197
+ /**
2198
+ * FalseNode
2199
+ *
2200
+ * Type: PM_FALSE_NODE
2201
+ *
2202
+ * @extends pm_node_t
2203
+ */
920
2204
  typedef struct pm_false_node {
2205
+ /** The embedded base node. */
921
2206
  pm_node_t base;
922
2207
  } pm_false_node_t;
923
2208
 
924
- // FindPatternNode
925
- //
926
- // Type: PM_FIND_PATTERN_NODE
2209
+ /**
2210
+ * FindPatternNode
2211
+ *
2212
+ * Type: PM_FIND_PATTERN_NODE
2213
+ *
2214
+ * @extends pm_node_t
2215
+ */
927
2216
  typedef struct pm_find_pattern_node {
2217
+ /** The embedded base node. */
928
2218
  pm_node_t base;
2219
+
2220
+ /** FindPatternNode#constant */
929
2221
  struct pm_node *constant;
2222
+
2223
+ /** FindPatternNode#left */
930
2224
  struct pm_node *left;
2225
+
2226
+ /** FindPatternNode#requireds */
931
2227
  struct pm_node_list requireds;
2228
+
2229
+ /** FindPatternNode#right */
932
2230
  struct pm_node *right;
2231
+
2232
+ /** FindPatternNode#opening_loc */
933
2233
  pm_location_t opening_loc;
2234
+
2235
+ /** FindPatternNode#closing_loc */
934
2236
  pm_location_t closing_loc;
935
2237
  } pm_find_pattern_node_t;
936
2238
 
937
- // FlipFlopNode
938
- //
939
- // Type: PM_FLIP_FLOP_NODE
940
- // Flags:
941
- // PM_RANGE_FLAGS_EXCLUDE_END
2239
+ /**
2240
+ * FlipFlopNode
2241
+ *
2242
+ * Type: PM_FLIP_FLOP_NODE
2243
+ * Flags:
2244
+ * PM_RANGE_FLAGS_EXCLUDE_END
2245
+ *
2246
+ * @extends pm_node_t
2247
+ */
942
2248
  typedef struct pm_flip_flop_node {
2249
+ /** The embedded base node. */
943
2250
  pm_node_t base;
2251
+
2252
+ /** FlipFlopNode#left */
944
2253
  struct pm_node *left;
2254
+
2255
+ /** FlipFlopNode#right */
945
2256
  struct pm_node *right;
2257
+
2258
+ /** FlipFlopNode#operator_loc */
946
2259
  pm_location_t operator_loc;
947
2260
  } pm_flip_flop_node_t;
948
2261
 
949
- // FloatNode
950
- //
951
- // Type: PM_FLOAT_NODE
2262
+ /**
2263
+ * FloatNode
2264
+ *
2265
+ * Type: PM_FLOAT_NODE
2266
+ *
2267
+ * @extends pm_node_t
2268
+ */
952
2269
  typedef struct pm_float_node {
2270
+ /** The embedded base node. */
953
2271
  pm_node_t base;
954
2272
  } pm_float_node_t;
955
2273
 
956
- // ForNode
957
- //
958
- // Type: PM_FOR_NODE
2274
+ /**
2275
+ * ForNode
2276
+ *
2277
+ * Type: PM_FOR_NODE
2278
+ *
2279
+ * @extends pm_node_t
2280
+ */
959
2281
  typedef struct pm_for_node {
2282
+ /** The embedded base node. */
960
2283
  pm_node_t base;
2284
+
2285
+ /** ForNode#index */
961
2286
  struct pm_node *index;
2287
+
2288
+ /** ForNode#collection */
962
2289
  struct pm_node *collection;
2290
+
2291
+ /** ForNode#statements */
963
2292
  struct pm_statements_node *statements;
2293
+
2294
+ /** ForNode#for_keyword_loc */
964
2295
  pm_location_t for_keyword_loc;
2296
+
2297
+ /** ForNode#in_keyword_loc */
965
2298
  pm_location_t in_keyword_loc;
2299
+
2300
+ /** ForNode#do_keyword_loc */
966
2301
  pm_location_t do_keyword_loc;
2302
+
2303
+ /** ForNode#end_keyword_loc */
967
2304
  pm_location_t end_keyword_loc;
968
2305
  } pm_for_node_t;
969
2306
 
970
- // ForwardingArgumentsNode
971
- //
972
- // Type: PM_FORWARDING_ARGUMENTS_NODE
2307
+ /**
2308
+ * ForwardingArgumentsNode
2309
+ *
2310
+ * Type: PM_FORWARDING_ARGUMENTS_NODE
2311
+ *
2312
+ * @extends pm_node_t
2313
+ */
973
2314
  typedef struct pm_forwarding_arguments_node {
2315
+ /** The embedded base node. */
974
2316
  pm_node_t base;
975
2317
  } pm_forwarding_arguments_node_t;
976
2318
 
977
- // ForwardingParameterNode
978
- //
979
- // Type: PM_FORWARDING_PARAMETER_NODE
2319
+ /**
2320
+ * ForwardingParameterNode
2321
+ *
2322
+ * Type: PM_FORWARDING_PARAMETER_NODE
2323
+ *
2324
+ * @extends pm_node_t
2325
+ */
980
2326
  typedef struct pm_forwarding_parameter_node {
2327
+ /** The embedded base node. */
981
2328
  pm_node_t base;
982
2329
  } pm_forwarding_parameter_node_t;
983
2330
 
984
- // ForwardingSuperNode
985
- //
986
- // Type: PM_FORWARDING_SUPER_NODE
2331
+ /**
2332
+ * ForwardingSuperNode
2333
+ *
2334
+ * Type: PM_FORWARDING_SUPER_NODE
2335
+ *
2336
+ * @extends pm_node_t
2337
+ */
987
2338
  typedef struct pm_forwarding_super_node {
2339
+ /** The embedded base node. */
988
2340
  pm_node_t base;
2341
+
2342
+ /** ForwardingSuperNode#block */
989
2343
  struct pm_block_node *block;
990
2344
  } pm_forwarding_super_node_t;
991
2345
 
992
- // GlobalVariableAndWriteNode
993
- //
994
- // Type: PM_GLOBAL_VARIABLE_AND_WRITE_NODE
2346
+ /**
2347
+ * GlobalVariableAndWriteNode
2348
+ *
2349
+ * Type: PM_GLOBAL_VARIABLE_AND_WRITE_NODE
2350
+ *
2351
+ * @extends pm_node_t
2352
+ */
995
2353
  typedef struct pm_global_variable_and_write_node {
2354
+ /** The embedded base node. */
996
2355
  pm_node_t base;
2356
+
2357
+ /** GlobalVariableAndWriteNode#name */
997
2358
  pm_constant_id_t name;
2359
+
2360
+ /** GlobalVariableAndWriteNode#name_loc */
998
2361
  pm_location_t name_loc;
2362
+
2363
+ /** GlobalVariableAndWriteNode#operator_loc */
999
2364
  pm_location_t operator_loc;
2365
+
2366
+ /** GlobalVariableAndWriteNode#value */
1000
2367
  struct pm_node *value;
1001
2368
  } pm_global_variable_and_write_node_t;
1002
2369
 
1003
- // GlobalVariableOperatorWriteNode
1004
- //
1005
- // Type: PM_GLOBAL_VARIABLE_OPERATOR_WRITE_NODE
2370
+ /**
2371
+ * GlobalVariableOperatorWriteNode
2372
+ *
2373
+ * Type: PM_GLOBAL_VARIABLE_OPERATOR_WRITE_NODE
2374
+ *
2375
+ * @extends pm_node_t
2376
+ */
1006
2377
  typedef struct pm_global_variable_operator_write_node {
2378
+ /** The embedded base node. */
1007
2379
  pm_node_t base;
2380
+
2381
+ /** GlobalVariableOperatorWriteNode#name */
1008
2382
  pm_constant_id_t name;
2383
+
2384
+ /** GlobalVariableOperatorWriteNode#name_loc */
1009
2385
  pm_location_t name_loc;
2386
+
2387
+ /** GlobalVariableOperatorWriteNode#operator_loc */
1010
2388
  pm_location_t operator_loc;
2389
+
2390
+ /** GlobalVariableOperatorWriteNode#value */
1011
2391
  struct pm_node *value;
2392
+
2393
+ /** GlobalVariableOperatorWriteNode#operator */
1012
2394
  pm_constant_id_t operator;
1013
2395
  } pm_global_variable_operator_write_node_t;
1014
2396
 
1015
- // GlobalVariableOrWriteNode
1016
- //
1017
- // Type: PM_GLOBAL_VARIABLE_OR_WRITE_NODE
2397
+ /**
2398
+ * GlobalVariableOrWriteNode
2399
+ *
2400
+ * Type: PM_GLOBAL_VARIABLE_OR_WRITE_NODE
2401
+ *
2402
+ * @extends pm_node_t
2403
+ */
1018
2404
  typedef struct pm_global_variable_or_write_node {
2405
+ /** The embedded base node. */
1019
2406
  pm_node_t base;
2407
+
2408
+ /** GlobalVariableOrWriteNode#name */
1020
2409
  pm_constant_id_t name;
2410
+
2411
+ /** GlobalVariableOrWriteNode#name_loc */
1021
2412
  pm_location_t name_loc;
2413
+
2414
+ /** GlobalVariableOrWriteNode#operator_loc */
1022
2415
  pm_location_t operator_loc;
2416
+
2417
+ /** GlobalVariableOrWriteNode#value */
1023
2418
  struct pm_node *value;
1024
2419
  } pm_global_variable_or_write_node_t;
1025
2420
 
1026
- // GlobalVariableReadNode
1027
- //
1028
- // Type: PM_GLOBAL_VARIABLE_READ_NODE
2421
+ /**
2422
+ * GlobalVariableReadNode
2423
+ *
2424
+ * Type: PM_GLOBAL_VARIABLE_READ_NODE
2425
+ *
2426
+ * @extends pm_node_t
2427
+ */
1029
2428
  typedef struct pm_global_variable_read_node {
2429
+ /** The embedded base node. */
1030
2430
  pm_node_t base;
2431
+
2432
+ /** GlobalVariableReadNode#name */
1031
2433
  pm_constant_id_t name;
1032
2434
  } pm_global_variable_read_node_t;
1033
2435
 
1034
- // GlobalVariableTargetNode
1035
- //
1036
- // Type: PM_GLOBAL_VARIABLE_TARGET_NODE
2436
+ /**
2437
+ * GlobalVariableTargetNode
2438
+ *
2439
+ * Type: PM_GLOBAL_VARIABLE_TARGET_NODE
2440
+ *
2441
+ * @extends pm_node_t
2442
+ */
1037
2443
  typedef struct pm_global_variable_target_node {
2444
+ /** The embedded base node. */
1038
2445
  pm_node_t base;
2446
+
2447
+ /** GlobalVariableTargetNode#name */
1039
2448
  pm_constant_id_t name;
1040
2449
  } pm_global_variable_target_node_t;
1041
2450
 
1042
- // GlobalVariableWriteNode
1043
- //
1044
- // Type: PM_GLOBAL_VARIABLE_WRITE_NODE
2451
+ /**
2452
+ * GlobalVariableWriteNode
2453
+ *
2454
+ * Type: PM_GLOBAL_VARIABLE_WRITE_NODE
2455
+ *
2456
+ * @extends pm_node_t
2457
+ */
1045
2458
  typedef struct pm_global_variable_write_node {
2459
+ /** The embedded base node. */
1046
2460
  pm_node_t base;
2461
+
2462
+ /** GlobalVariableWriteNode#name */
1047
2463
  pm_constant_id_t name;
2464
+
2465
+ /** GlobalVariableWriteNode#name_loc */
1048
2466
  pm_location_t name_loc;
2467
+
2468
+ /** GlobalVariableWriteNode#value */
1049
2469
  struct pm_node *value;
2470
+
2471
+ /** GlobalVariableWriteNode#operator_loc */
1050
2472
  pm_location_t operator_loc;
1051
2473
  } pm_global_variable_write_node_t;
1052
2474
 
1053
- // HashNode
1054
- //
1055
- // Type: PM_HASH_NODE
2475
+ /**
2476
+ * HashNode
2477
+ *
2478
+ * Type: PM_HASH_NODE
2479
+ *
2480
+ * @extends pm_node_t
2481
+ */
1056
2482
  typedef struct pm_hash_node {
2483
+ /** The embedded base node. */
1057
2484
  pm_node_t base;
2485
+
2486
+ /** HashNode#opening_loc */
1058
2487
  pm_location_t opening_loc;
2488
+
2489
+ /** HashNode#elements */
1059
2490
  struct pm_node_list elements;
2491
+
2492
+ /** HashNode#closing_loc */
1060
2493
  pm_location_t closing_loc;
1061
2494
  } pm_hash_node_t;
1062
2495
 
1063
- // HashPatternNode
1064
- //
1065
- // Type: PM_HASH_PATTERN_NODE
2496
+ /**
2497
+ * HashPatternNode
2498
+ *
2499
+ * Type: PM_HASH_PATTERN_NODE
2500
+ *
2501
+ * @extends pm_node_t
2502
+ */
1066
2503
  typedef struct pm_hash_pattern_node {
2504
+ /** The embedded base node. */
1067
2505
  pm_node_t base;
2506
+
2507
+ /** HashPatternNode#constant */
1068
2508
  struct pm_node *constant;
2509
+
2510
+ /** HashPatternNode#elements */
1069
2511
  struct pm_node_list elements;
2512
+
2513
+ /** HashPatternNode#rest */
1070
2514
  struct pm_node *rest;
2515
+
2516
+ /** HashPatternNode#opening_loc */
1071
2517
  pm_location_t opening_loc;
2518
+
2519
+ /** HashPatternNode#closing_loc */
1072
2520
  pm_location_t closing_loc;
1073
2521
  } pm_hash_pattern_node_t;
1074
2522
 
1075
- // IfNode
1076
- //
1077
- // Type: PM_IF_NODE
2523
+ /**
2524
+ * IfNode
2525
+ *
2526
+ * Type: PM_IF_NODE
2527
+ *
2528
+ * @extends pm_node_t
2529
+ */
1078
2530
  typedef struct pm_if_node {
2531
+ /** The embedded base node. */
1079
2532
  pm_node_t base;
2533
+
2534
+ /** IfNode#if_keyword_loc */
1080
2535
  pm_location_t if_keyword_loc;
2536
+
2537
+ /** IfNode#predicate */
1081
2538
  struct pm_node *predicate;
2539
+
2540
+ /** IfNode#statements */
1082
2541
  struct pm_statements_node *statements;
2542
+
2543
+ /** IfNode#consequent */
1083
2544
  struct pm_node *consequent;
2545
+
2546
+ /** IfNode#end_keyword_loc */
1084
2547
  pm_location_t end_keyword_loc;
1085
2548
  } pm_if_node_t;
1086
2549
 
1087
- // ImaginaryNode
1088
- //
1089
- // Type: PM_IMAGINARY_NODE
2550
+ /**
2551
+ * ImaginaryNode
2552
+ *
2553
+ * Type: PM_IMAGINARY_NODE
2554
+ *
2555
+ * @extends pm_node_t
2556
+ */
1090
2557
  typedef struct pm_imaginary_node {
2558
+ /** The embedded base node. */
1091
2559
  pm_node_t base;
2560
+
2561
+ /** ImaginaryNode#numeric */
1092
2562
  struct pm_node *numeric;
1093
2563
  } pm_imaginary_node_t;
1094
2564
 
1095
- // ImplicitNode
1096
- //
1097
- // Type: PM_IMPLICIT_NODE
2565
+ /**
2566
+ * ImplicitNode
2567
+ *
2568
+ * Type: PM_IMPLICIT_NODE
2569
+ *
2570
+ * @extends pm_node_t
2571
+ */
1098
2572
  typedef struct pm_implicit_node {
2573
+ /** The embedded base node. */
1099
2574
  pm_node_t base;
2575
+
2576
+ /** ImplicitNode#value */
1100
2577
  struct pm_node *value;
1101
2578
  } pm_implicit_node_t;
1102
2579
 
1103
- // InNode
1104
- //
1105
- // Type: PM_IN_NODE
2580
+ /**
2581
+ * InNode
2582
+ *
2583
+ * Type: PM_IN_NODE
2584
+ *
2585
+ * @extends pm_node_t
2586
+ */
1106
2587
  typedef struct pm_in_node {
2588
+ /** The embedded base node. */
1107
2589
  pm_node_t base;
2590
+
2591
+ /** InNode#pattern */
1108
2592
  struct pm_node *pattern;
2593
+
2594
+ /** InNode#statements */
1109
2595
  struct pm_statements_node *statements;
2596
+
2597
+ /** InNode#in_loc */
1110
2598
  pm_location_t in_loc;
2599
+
2600
+ /** InNode#then_loc */
1111
2601
  pm_location_t then_loc;
1112
2602
  } pm_in_node_t;
1113
2603
 
1114
- // IndexAndWriteNode
1115
- //
1116
- // Type: PM_INDEX_AND_WRITE_NODE
1117
- // Flags:
1118
- // PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
1119
- // PM_CALL_NODE_FLAGS_VARIABLE_CALL
2604
+ /**
2605
+ * IndexAndWriteNode
2606
+ *
2607
+ * Type: PM_INDEX_AND_WRITE_NODE
2608
+ * Flags:
2609
+ * PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
2610
+ * PM_CALL_NODE_FLAGS_VARIABLE_CALL
2611
+ *
2612
+ * @extends pm_node_t
2613
+ */
1120
2614
  typedef struct pm_index_and_write_node {
2615
+ /** The embedded base node. */
1121
2616
  pm_node_t base;
2617
+
2618
+ /** IndexAndWriteNode#receiver */
1122
2619
  struct pm_node *receiver;
2620
+
2621
+ /** IndexAndWriteNode#call_operator_loc */
1123
2622
  pm_location_t call_operator_loc;
2623
+
2624
+ /** IndexAndWriteNode#opening_loc */
1124
2625
  pm_location_t opening_loc;
2626
+
2627
+ /** IndexAndWriteNode#arguments */
1125
2628
  struct pm_arguments_node *arguments;
2629
+
2630
+ /** IndexAndWriteNode#closing_loc */
1126
2631
  pm_location_t closing_loc;
2632
+
2633
+ /** IndexAndWriteNode#block */
1127
2634
  struct pm_node *block;
2635
+
2636
+ /** IndexAndWriteNode#operator_loc */
1128
2637
  pm_location_t operator_loc;
2638
+
2639
+ /** IndexAndWriteNode#value */
1129
2640
  struct pm_node *value;
1130
2641
  } pm_index_and_write_node_t;
1131
2642
 
1132
- // IndexOperatorWriteNode
1133
- //
1134
- // Type: PM_INDEX_OPERATOR_WRITE_NODE
1135
- // Flags:
1136
- // PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
1137
- // PM_CALL_NODE_FLAGS_VARIABLE_CALL
2643
+ /**
2644
+ * IndexOperatorWriteNode
2645
+ *
2646
+ * Type: PM_INDEX_OPERATOR_WRITE_NODE
2647
+ * Flags:
2648
+ * PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
2649
+ * PM_CALL_NODE_FLAGS_VARIABLE_CALL
2650
+ *
2651
+ * @extends pm_node_t
2652
+ */
1138
2653
  typedef struct pm_index_operator_write_node {
2654
+ /** The embedded base node. */
1139
2655
  pm_node_t base;
2656
+
2657
+ /** IndexOperatorWriteNode#receiver */
1140
2658
  struct pm_node *receiver;
2659
+
2660
+ /** IndexOperatorWriteNode#call_operator_loc */
1141
2661
  pm_location_t call_operator_loc;
2662
+
2663
+ /** IndexOperatorWriteNode#opening_loc */
1142
2664
  pm_location_t opening_loc;
2665
+
2666
+ /** IndexOperatorWriteNode#arguments */
1143
2667
  struct pm_arguments_node *arguments;
2668
+
2669
+ /** IndexOperatorWriteNode#closing_loc */
1144
2670
  pm_location_t closing_loc;
2671
+
2672
+ /** IndexOperatorWriteNode#block */
1145
2673
  struct pm_node *block;
2674
+
2675
+ /** IndexOperatorWriteNode#operator */
1146
2676
  pm_constant_id_t operator;
2677
+
2678
+ /** IndexOperatorWriteNode#operator_loc */
1147
2679
  pm_location_t operator_loc;
2680
+
2681
+ /** IndexOperatorWriteNode#value */
1148
2682
  struct pm_node *value;
1149
2683
  } pm_index_operator_write_node_t;
1150
2684
 
1151
- // IndexOrWriteNode
1152
- //
1153
- // Type: PM_INDEX_OR_WRITE_NODE
1154
- // Flags:
1155
- // PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
1156
- // PM_CALL_NODE_FLAGS_VARIABLE_CALL
2685
+ /**
2686
+ * IndexOrWriteNode
2687
+ *
2688
+ * Type: PM_INDEX_OR_WRITE_NODE
2689
+ * Flags:
2690
+ * PM_CALL_NODE_FLAGS_SAFE_NAVIGATION
2691
+ * PM_CALL_NODE_FLAGS_VARIABLE_CALL
2692
+ *
2693
+ * @extends pm_node_t
2694
+ */
1157
2695
  typedef struct pm_index_or_write_node {
2696
+ /** The embedded base node. */
1158
2697
  pm_node_t base;
2698
+
2699
+ /** IndexOrWriteNode#receiver */
1159
2700
  struct pm_node *receiver;
2701
+
2702
+ /** IndexOrWriteNode#call_operator_loc */
1160
2703
  pm_location_t call_operator_loc;
2704
+
2705
+ /** IndexOrWriteNode#opening_loc */
1161
2706
  pm_location_t opening_loc;
2707
+
2708
+ /** IndexOrWriteNode#arguments */
1162
2709
  struct pm_arguments_node *arguments;
2710
+
2711
+ /** IndexOrWriteNode#closing_loc */
1163
2712
  pm_location_t closing_loc;
2713
+
2714
+ /** IndexOrWriteNode#block */
1164
2715
  struct pm_node *block;
2716
+
2717
+ /** IndexOrWriteNode#operator_loc */
1165
2718
  pm_location_t operator_loc;
2719
+
2720
+ /** IndexOrWriteNode#value */
1166
2721
  struct pm_node *value;
1167
2722
  } pm_index_or_write_node_t;
1168
2723
 
1169
- // InstanceVariableAndWriteNode
1170
- //
1171
- // Type: PM_INSTANCE_VARIABLE_AND_WRITE_NODE
2724
+ /**
2725
+ * InstanceVariableAndWriteNode
2726
+ *
2727
+ * Type: PM_INSTANCE_VARIABLE_AND_WRITE_NODE
2728
+ *
2729
+ * @extends pm_node_t
2730
+ */
1172
2731
  typedef struct pm_instance_variable_and_write_node {
2732
+ /** The embedded base node. */
1173
2733
  pm_node_t base;
2734
+
2735
+ /** InstanceVariableAndWriteNode#name */
1174
2736
  pm_constant_id_t name;
2737
+
2738
+ /** InstanceVariableAndWriteNode#name_loc */
1175
2739
  pm_location_t name_loc;
2740
+
2741
+ /** InstanceVariableAndWriteNode#operator_loc */
1176
2742
  pm_location_t operator_loc;
2743
+
2744
+ /** InstanceVariableAndWriteNode#value */
1177
2745
  struct pm_node *value;
1178
2746
  } pm_instance_variable_and_write_node_t;
1179
2747
 
1180
- // InstanceVariableOperatorWriteNode
1181
- //
1182
- // Type: PM_INSTANCE_VARIABLE_OPERATOR_WRITE_NODE
2748
+ /**
2749
+ * InstanceVariableOperatorWriteNode
2750
+ *
2751
+ * Type: PM_INSTANCE_VARIABLE_OPERATOR_WRITE_NODE
2752
+ *
2753
+ * @extends pm_node_t
2754
+ */
1183
2755
  typedef struct pm_instance_variable_operator_write_node {
2756
+ /** The embedded base node. */
1184
2757
  pm_node_t base;
2758
+
2759
+ /** InstanceVariableOperatorWriteNode#name */
1185
2760
  pm_constant_id_t name;
2761
+
2762
+ /** InstanceVariableOperatorWriteNode#name_loc */
1186
2763
  pm_location_t name_loc;
2764
+
2765
+ /** InstanceVariableOperatorWriteNode#operator_loc */
1187
2766
  pm_location_t operator_loc;
2767
+
2768
+ /** InstanceVariableOperatorWriteNode#value */
1188
2769
  struct pm_node *value;
2770
+
2771
+ /** InstanceVariableOperatorWriteNode#operator */
1189
2772
  pm_constant_id_t operator;
1190
2773
  } pm_instance_variable_operator_write_node_t;
1191
2774
 
1192
- // InstanceVariableOrWriteNode
1193
- //
1194
- // Type: PM_INSTANCE_VARIABLE_OR_WRITE_NODE
2775
+ /**
2776
+ * InstanceVariableOrWriteNode
2777
+ *
2778
+ * Type: PM_INSTANCE_VARIABLE_OR_WRITE_NODE
2779
+ *
2780
+ * @extends pm_node_t
2781
+ */
1195
2782
  typedef struct pm_instance_variable_or_write_node {
2783
+ /** The embedded base node. */
1196
2784
  pm_node_t base;
2785
+
2786
+ /** InstanceVariableOrWriteNode#name */
1197
2787
  pm_constant_id_t name;
2788
+
2789
+ /** InstanceVariableOrWriteNode#name_loc */
1198
2790
  pm_location_t name_loc;
2791
+
2792
+ /** InstanceVariableOrWriteNode#operator_loc */
1199
2793
  pm_location_t operator_loc;
2794
+
2795
+ /** InstanceVariableOrWriteNode#value */
1200
2796
  struct pm_node *value;
1201
2797
  } pm_instance_variable_or_write_node_t;
1202
2798
 
1203
- // InstanceVariableReadNode
1204
- //
1205
- // Type: PM_INSTANCE_VARIABLE_READ_NODE
2799
+ /**
2800
+ * InstanceVariableReadNode
2801
+ *
2802
+ * Type: PM_INSTANCE_VARIABLE_READ_NODE
2803
+ *
2804
+ * @extends pm_node_t
2805
+ */
1206
2806
  typedef struct pm_instance_variable_read_node {
2807
+ /** The embedded base node. */
1207
2808
  pm_node_t base;
2809
+
2810
+ /** InstanceVariableReadNode#name */
1208
2811
  pm_constant_id_t name;
1209
2812
  } pm_instance_variable_read_node_t;
1210
2813
 
1211
- // InstanceVariableTargetNode
1212
- //
1213
- // Type: PM_INSTANCE_VARIABLE_TARGET_NODE
2814
+ /**
2815
+ * InstanceVariableTargetNode
2816
+ *
2817
+ * Type: PM_INSTANCE_VARIABLE_TARGET_NODE
2818
+ *
2819
+ * @extends pm_node_t
2820
+ */
1214
2821
  typedef struct pm_instance_variable_target_node {
2822
+ /** The embedded base node. */
1215
2823
  pm_node_t base;
2824
+
2825
+ /** InstanceVariableTargetNode#name */
1216
2826
  pm_constant_id_t name;
1217
2827
  } pm_instance_variable_target_node_t;
1218
2828
 
1219
- // InstanceVariableWriteNode
1220
- //
1221
- // Type: PM_INSTANCE_VARIABLE_WRITE_NODE
2829
+ /**
2830
+ * InstanceVariableWriteNode
2831
+ *
2832
+ * Type: PM_INSTANCE_VARIABLE_WRITE_NODE
2833
+ *
2834
+ * @extends pm_node_t
2835
+ */
1222
2836
  typedef struct pm_instance_variable_write_node {
2837
+ /** The embedded base node. */
1223
2838
  pm_node_t base;
2839
+
2840
+ /** InstanceVariableWriteNode#name */
1224
2841
  pm_constant_id_t name;
2842
+
2843
+ /** InstanceVariableWriteNode#name_loc */
1225
2844
  pm_location_t name_loc;
2845
+
2846
+ /** InstanceVariableWriteNode#value */
1226
2847
  struct pm_node *value;
2848
+
2849
+ /** InstanceVariableWriteNode#operator_loc */
1227
2850
  pm_location_t operator_loc;
1228
2851
  } pm_instance_variable_write_node_t;
1229
2852
 
1230
- // IntegerNode
1231
- //
1232
- // Type: PM_INTEGER_NODE
1233
- // Flags:
1234
- // PM_INTEGER_BASE_FLAGS_BINARY
1235
- // PM_INTEGER_BASE_FLAGS_OCTAL
1236
- // PM_INTEGER_BASE_FLAGS_DECIMAL
1237
- // PM_INTEGER_BASE_FLAGS_HEXADECIMAL
2853
+ /**
2854
+ * IntegerNode
2855
+ *
2856
+ * Type: PM_INTEGER_NODE
2857
+ * Flags:
2858
+ * PM_INTEGER_BASE_FLAGS_BINARY
2859
+ * PM_INTEGER_BASE_FLAGS_OCTAL
2860
+ * PM_INTEGER_BASE_FLAGS_DECIMAL
2861
+ * PM_INTEGER_BASE_FLAGS_HEXADECIMAL
2862
+ *
2863
+ * @extends pm_node_t
2864
+ */
1238
2865
  typedef struct pm_integer_node {
2866
+ /** The embedded base node. */
1239
2867
  pm_node_t base;
1240
2868
  } pm_integer_node_t;
1241
2869
 
1242
- // InterpolatedMatchLastLineNode
1243
- //
1244
- // Type: PM_INTERPOLATED_MATCH_LAST_LINE_NODE
1245
- // Flags:
1246
- // PM_REGULAR_EXPRESSION_FLAGS_IGNORE_CASE
1247
- // PM_REGULAR_EXPRESSION_FLAGS_EXTENDED
1248
- // PM_REGULAR_EXPRESSION_FLAGS_MULTI_LINE
1249
- // PM_REGULAR_EXPRESSION_FLAGS_ONCE
1250
- // PM_REGULAR_EXPRESSION_FLAGS_EUC_JP
1251
- // PM_REGULAR_EXPRESSION_FLAGS_ASCII_8BIT
1252
- // PM_REGULAR_EXPRESSION_FLAGS_WINDOWS_31J
1253
- // PM_REGULAR_EXPRESSION_FLAGS_UTF_8
2870
+ /**
2871
+ * InterpolatedMatchLastLineNode
2872
+ *
2873
+ * Type: PM_INTERPOLATED_MATCH_LAST_LINE_NODE
2874
+ * Flags:
2875
+ * PM_REGULAR_EXPRESSION_FLAGS_IGNORE_CASE
2876
+ * PM_REGULAR_EXPRESSION_FLAGS_EXTENDED
2877
+ * PM_REGULAR_EXPRESSION_FLAGS_MULTI_LINE
2878
+ * PM_REGULAR_EXPRESSION_FLAGS_ONCE
2879
+ * PM_REGULAR_EXPRESSION_FLAGS_EUC_JP
2880
+ * PM_REGULAR_EXPRESSION_FLAGS_ASCII_8BIT
2881
+ * PM_REGULAR_EXPRESSION_FLAGS_WINDOWS_31J
2882
+ * PM_REGULAR_EXPRESSION_FLAGS_UTF_8
2883
+ *
2884
+ * @extends pm_node_t
2885
+ */
1254
2886
  typedef struct pm_interpolated_match_last_line_node {
2887
+ /** The embedded base node. */
1255
2888
  pm_node_t base;
2889
+
2890
+ /** InterpolatedMatchLastLineNode#opening_loc */
1256
2891
  pm_location_t opening_loc;
2892
+
2893
+ /** InterpolatedMatchLastLineNode#parts */
1257
2894
  struct pm_node_list parts;
2895
+
2896
+ /** InterpolatedMatchLastLineNode#closing_loc */
1258
2897
  pm_location_t closing_loc;
1259
2898
  } pm_interpolated_match_last_line_node_t;
1260
2899
 
1261
- // InterpolatedRegularExpressionNode
1262
- //
1263
- // Type: PM_INTERPOLATED_REGULAR_EXPRESSION_NODE
1264
- // Flags:
1265
- // PM_REGULAR_EXPRESSION_FLAGS_IGNORE_CASE
1266
- // PM_REGULAR_EXPRESSION_FLAGS_EXTENDED
1267
- // PM_REGULAR_EXPRESSION_FLAGS_MULTI_LINE
1268
- // PM_REGULAR_EXPRESSION_FLAGS_ONCE
1269
- // PM_REGULAR_EXPRESSION_FLAGS_EUC_JP
1270
- // PM_REGULAR_EXPRESSION_FLAGS_ASCII_8BIT
1271
- // PM_REGULAR_EXPRESSION_FLAGS_WINDOWS_31J
1272
- // PM_REGULAR_EXPRESSION_FLAGS_UTF_8
2900
+ /**
2901
+ * InterpolatedRegularExpressionNode
2902
+ *
2903
+ * Type: PM_INTERPOLATED_REGULAR_EXPRESSION_NODE
2904
+ * Flags:
2905
+ * PM_REGULAR_EXPRESSION_FLAGS_IGNORE_CASE
2906
+ * PM_REGULAR_EXPRESSION_FLAGS_EXTENDED
2907
+ * PM_REGULAR_EXPRESSION_FLAGS_MULTI_LINE
2908
+ * PM_REGULAR_EXPRESSION_FLAGS_ONCE
2909
+ * PM_REGULAR_EXPRESSION_FLAGS_EUC_JP
2910
+ * PM_REGULAR_EXPRESSION_FLAGS_ASCII_8BIT
2911
+ * PM_REGULAR_EXPRESSION_FLAGS_WINDOWS_31J
2912
+ * PM_REGULAR_EXPRESSION_FLAGS_UTF_8
2913
+ *
2914
+ * @extends pm_node_t
2915
+ */
1273
2916
  typedef struct pm_interpolated_regular_expression_node {
2917
+ /** The embedded base node. */
1274
2918
  pm_node_t base;
2919
+
2920
+ /** InterpolatedRegularExpressionNode#opening_loc */
1275
2921
  pm_location_t opening_loc;
2922
+
2923
+ /** InterpolatedRegularExpressionNode#parts */
1276
2924
  struct pm_node_list parts;
2925
+
2926
+ /** InterpolatedRegularExpressionNode#closing_loc */
1277
2927
  pm_location_t closing_loc;
1278
2928
  } pm_interpolated_regular_expression_node_t;
1279
2929
 
1280
- // InterpolatedStringNode
1281
- //
1282
- // Type: PM_INTERPOLATED_STRING_NODE
2930
+ /**
2931
+ * InterpolatedStringNode
2932
+ *
2933
+ * Type: PM_INTERPOLATED_STRING_NODE
2934
+ *
2935
+ * @extends pm_node_t
2936
+ */
1283
2937
  typedef struct pm_interpolated_string_node {
2938
+ /** The embedded base node. */
1284
2939
  pm_node_t base;
2940
+
2941
+ /** InterpolatedStringNode#opening_loc */
1285
2942
  pm_location_t opening_loc;
2943
+
2944
+ /** InterpolatedStringNode#parts */
1286
2945
  struct pm_node_list parts;
2946
+
2947
+ /** InterpolatedStringNode#closing_loc */
1287
2948
  pm_location_t closing_loc;
1288
2949
  } pm_interpolated_string_node_t;
1289
2950
 
1290
- // InterpolatedSymbolNode
1291
- //
1292
- // Type: PM_INTERPOLATED_SYMBOL_NODE
2951
+ /**
2952
+ * InterpolatedSymbolNode
2953
+ *
2954
+ * Type: PM_INTERPOLATED_SYMBOL_NODE
2955
+ *
2956
+ * @extends pm_node_t
2957
+ */
1293
2958
  typedef struct pm_interpolated_symbol_node {
2959
+ /** The embedded base node. */
1294
2960
  pm_node_t base;
2961
+
2962
+ /** InterpolatedSymbolNode#opening_loc */
1295
2963
  pm_location_t opening_loc;
2964
+
2965
+ /** InterpolatedSymbolNode#parts */
1296
2966
  struct pm_node_list parts;
2967
+
2968
+ /** InterpolatedSymbolNode#closing_loc */
1297
2969
  pm_location_t closing_loc;
1298
2970
  } pm_interpolated_symbol_node_t;
1299
2971
 
1300
- // InterpolatedXStringNode
1301
- //
1302
- // Type: PM_INTERPOLATED_X_STRING_NODE
2972
+ /**
2973
+ * InterpolatedXStringNode
2974
+ *
2975
+ * Type: PM_INTERPOLATED_X_STRING_NODE
2976
+ *
2977
+ * @extends pm_node_t
2978
+ */
1303
2979
  typedef struct pm_interpolated_x_string_node {
2980
+ /** The embedded base node. */
1304
2981
  pm_node_t base;
2982
+
2983
+ /** InterpolatedXStringNode#opening_loc */
1305
2984
  pm_location_t opening_loc;
2985
+
2986
+ /** InterpolatedXStringNode#parts */
1306
2987
  struct pm_node_list parts;
2988
+
2989
+ /** InterpolatedXStringNode#closing_loc */
1307
2990
  pm_location_t closing_loc;
1308
2991
  } pm_interpolated_x_string_node_t;
1309
2992
 
1310
- // KeywordHashNode
1311
- //
1312
- // Type: PM_KEYWORD_HASH_NODE
2993
+ /**
2994
+ * KeywordHashNode
2995
+ *
2996
+ * Type: PM_KEYWORD_HASH_NODE
2997
+ *
2998
+ * @extends pm_node_t
2999
+ */
1313
3000
  typedef struct pm_keyword_hash_node {
3001
+ /** The embedded base node. */
1314
3002
  pm_node_t base;
3003
+
3004
+ /** KeywordHashNode#elements */
1315
3005
  struct pm_node_list elements;
1316
3006
  } pm_keyword_hash_node_t;
1317
3007
 
1318
- // KeywordParameterNode
1319
- //
1320
- // Type: PM_KEYWORD_PARAMETER_NODE
1321
- typedef struct pm_keyword_parameter_node {
1322
- pm_node_t base;
1323
- pm_constant_id_t name;
1324
- pm_location_t name_loc;
1325
- struct pm_node *value;
1326
- } pm_keyword_parameter_node_t;
1327
-
1328
- // KeywordRestParameterNode
1329
- //
1330
- // Type: PM_KEYWORD_REST_PARAMETER_NODE
3008
+ /**
3009
+ * KeywordRestParameterNode
3010
+ *
3011
+ * Type: PM_KEYWORD_REST_PARAMETER_NODE
3012
+ *
3013
+ * @extends pm_node_t
3014
+ */
1331
3015
  typedef struct pm_keyword_rest_parameter_node {
3016
+ /** The embedded base node. */
1332
3017
  pm_node_t base;
3018
+
3019
+ /** KeywordRestParameterNode#name */
1333
3020
  pm_constant_id_t name;
3021
+
3022
+ /** KeywordRestParameterNode#name_loc */
1334
3023
  pm_location_t name_loc;
3024
+
3025
+ /** KeywordRestParameterNode#operator_loc */
1335
3026
  pm_location_t operator_loc;
1336
3027
  } pm_keyword_rest_parameter_node_t;
1337
3028
 
1338
- // LambdaNode
1339
- //
1340
- // Type: PM_LAMBDA_NODE
3029
+ /**
3030
+ * LambdaNode
3031
+ *
3032
+ * Type: PM_LAMBDA_NODE
3033
+ *
3034
+ * @extends pm_node_t
3035
+ */
1341
3036
  typedef struct pm_lambda_node {
3037
+ /** The embedded base node. */
1342
3038
  pm_node_t base;
3039
+
3040
+ /** LambdaNode#locals */
1343
3041
  pm_constant_id_list_t locals;
3042
+
3043
+ /** LambdaNode#operator_loc */
1344
3044
  pm_location_t operator_loc;
3045
+
3046
+ /** LambdaNode#opening_loc */
1345
3047
  pm_location_t opening_loc;
3048
+
3049
+ /** LambdaNode#closing_loc */
1346
3050
  pm_location_t closing_loc;
3051
+
3052
+ /** LambdaNode#parameters */
1347
3053
  struct pm_block_parameters_node *parameters;
3054
+
3055
+ /** LambdaNode#body */
1348
3056
  struct pm_node *body;
1349
3057
  } pm_lambda_node_t;
1350
3058
 
1351
- // LocalVariableAndWriteNode
1352
- //
1353
- // Type: PM_LOCAL_VARIABLE_AND_WRITE_NODE
3059
+ /**
3060
+ * LocalVariableAndWriteNode
3061
+ *
3062
+ * Type: PM_LOCAL_VARIABLE_AND_WRITE_NODE
3063
+ *
3064
+ * @extends pm_node_t
3065
+ */
1354
3066
  typedef struct pm_local_variable_and_write_node {
3067
+ /** The embedded base node. */
1355
3068
  pm_node_t base;
3069
+
3070
+ /** LocalVariableAndWriteNode#name_loc */
1356
3071
  pm_location_t name_loc;
3072
+
3073
+ /** LocalVariableAndWriteNode#operator_loc */
1357
3074
  pm_location_t operator_loc;
3075
+
3076
+ /** LocalVariableAndWriteNode#value */
1358
3077
  struct pm_node *value;
3078
+
3079
+ /** LocalVariableAndWriteNode#name */
1359
3080
  pm_constant_id_t name;
3081
+
3082
+ /** LocalVariableAndWriteNode#depth */
1360
3083
  uint32_t depth;
1361
3084
  } pm_local_variable_and_write_node_t;
1362
3085
 
1363
- // LocalVariableOperatorWriteNode
1364
- //
1365
- // Type: PM_LOCAL_VARIABLE_OPERATOR_WRITE_NODE
3086
+ /**
3087
+ * LocalVariableOperatorWriteNode
3088
+ *
3089
+ * Type: PM_LOCAL_VARIABLE_OPERATOR_WRITE_NODE
3090
+ *
3091
+ * @extends pm_node_t
3092
+ */
1366
3093
  typedef struct pm_local_variable_operator_write_node {
3094
+ /** The embedded base node. */
1367
3095
  pm_node_t base;
3096
+
3097
+ /** LocalVariableOperatorWriteNode#name_loc */
1368
3098
  pm_location_t name_loc;
3099
+
3100
+ /** LocalVariableOperatorWriteNode#operator_loc */
1369
3101
  pm_location_t operator_loc;
3102
+
3103
+ /** LocalVariableOperatorWriteNode#value */
1370
3104
  struct pm_node *value;
3105
+
3106
+ /** LocalVariableOperatorWriteNode#name */
1371
3107
  pm_constant_id_t name;
3108
+
3109
+ /** LocalVariableOperatorWriteNode#operator */
1372
3110
  pm_constant_id_t operator;
3111
+
3112
+ /** LocalVariableOperatorWriteNode#depth */
1373
3113
  uint32_t depth;
1374
3114
  } pm_local_variable_operator_write_node_t;
1375
3115
 
1376
- // LocalVariableOrWriteNode
1377
- //
1378
- // Type: PM_LOCAL_VARIABLE_OR_WRITE_NODE
3116
+ /**
3117
+ * LocalVariableOrWriteNode
3118
+ *
3119
+ * Type: PM_LOCAL_VARIABLE_OR_WRITE_NODE
3120
+ *
3121
+ * @extends pm_node_t
3122
+ */
1379
3123
  typedef struct pm_local_variable_or_write_node {
3124
+ /** The embedded base node. */
1380
3125
  pm_node_t base;
3126
+
3127
+ /** LocalVariableOrWriteNode#name_loc */
1381
3128
  pm_location_t name_loc;
3129
+
3130
+ /** LocalVariableOrWriteNode#operator_loc */
1382
3131
  pm_location_t operator_loc;
3132
+
3133
+ /** LocalVariableOrWriteNode#value */
1383
3134
  struct pm_node *value;
3135
+
3136
+ /** LocalVariableOrWriteNode#name */
1384
3137
  pm_constant_id_t name;
3138
+
3139
+ /** LocalVariableOrWriteNode#depth */
1385
3140
  uint32_t depth;
1386
3141
  } pm_local_variable_or_write_node_t;
1387
3142
 
1388
- // LocalVariableReadNode
1389
- //
1390
- // Type: PM_LOCAL_VARIABLE_READ_NODE
3143
+ /**
3144
+ * LocalVariableReadNode
3145
+ *
3146
+ * Type: PM_LOCAL_VARIABLE_READ_NODE
3147
+ *
3148
+ * @extends pm_node_t
3149
+ */
1391
3150
  typedef struct pm_local_variable_read_node {
3151
+ /** The embedded base node. */
1392
3152
  pm_node_t base;
3153
+
3154
+ /** LocalVariableReadNode#name */
1393
3155
  pm_constant_id_t name;
3156
+
3157
+ /** LocalVariableReadNode#depth */
1394
3158
  uint32_t depth;
1395
3159
  } pm_local_variable_read_node_t;
1396
3160
 
1397
- // LocalVariableTargetNode
1398
- //
1399
- // Type: PM_LOCAL_VARIABLE_TARGET_NODE
3161
+ /**
3162
+ * LocalVariableTargetNode
3163
+ *
3164
+ * Type: PM_LOCAL_VARIABLE_TARGET_NODE
3165
+ *
3166
+ * @extends pm_node_t
3167
+ */
1400
3168
  typedef struct pm_local_variable_target_node {
3169
+ /** The embedded base node. */
1401
3170
  pm_node_t base;
3171
+
3172
+ /** LocalVariableTargetNode#name */
1402
3173
  pm_constant_id_t name;
3174
+
3175
+ /** LocalVariableTargetNode#depth */
1403
3176
  uint32_t depth;
1404
3177
  } pm_local_variable_target_node_t;
1405
3178
 
1406
- // LocalVariableWriteNode
1407
- //
1408
- // Type: PM_LOCAL_VARIABLE_WRITE_NODE
3179
+ /**
3180
+ * LocalVariableWriteNode
3181
+ *
3182
+ * Type: PM_LOCAL_VARIABLE_WRITE_NODE
3183
+ *
3184
+ * @extends pm_node_t
3185
+ */
1409
3186
  typedef struct pm_local_variable_write_node {
3187
+ /** The embedded base node. */
1410
3188
  pm_node_t base;
3189
+
3190
+ /** LocalVariableWriteNode#name */
1411
3191
  pm_constant_id_t name;
3192
+
3193
+ /** LocalVariableWriteNode#depth */
1412
3194
  uint32_t depth;
3195
+
3196
+ /** LocalVariableWriteNode#name_loc */
1413
3197
  pm_location_t name_loc;
3198
+
3199
+ /** LocalVariableWriteNode#value */
1414
3200
  struct pm_node *value;
3201
+
3202
+ /** LocalVariableWriteNode#operator_loc */
1415
3203
  pm_location_t operator_loc;
1416
3204
  } pm_local_variable_write_node_t;
1417
3205
 
1418
- // MatchLastLineNode
1419
- //
1420
- // Type: PM_MATCH_LAST_LINE_NODE
1421
- // Flags:
1422
- // PM_REGULAR_EXPRESSION_FLAGS_IGNORE_CASE
1423
- // PM_REGULAR_EXPRESSION_FLAGS_EXTENDED
1424
- // PM_REGULAR_EXPRESSION_FLAGS_MULTI_LINE
1425
- // PM_REGULAR_EXPRESSION_FLAGS_ONCE
1426
- // PM_REGULAR_EXPRESSION_FLAGS_EUC_JP
1427
- // PM_REGULAR_EXPRESSION_FLAGS_ASCII_8BIT
1428
- // PM_REGULAR_EXPRESSION_FLAGS_WINDOWS_31J
1429
- // PM_REGULAR_EXPRESSION_FLAGS_UTF_8
3206
+ /**
3207
+ * MatchLastLineNode
3208
+ *
3209
+ * Type: PM_MATCH_LAST_LINE_NODE
3210
+ * Flags:
3211
+ * PM_REGULAR_EXPRESSION_FLAGS_IGNORE_CASE
3212
+ * PM_REGULAR_EXPRESSION_FLAGS_EXTENDED
3213
+ * PM_REGULAR_EXPRESSION_FLAGS_MULTI_LINE
3214
+ * PM_REGULAR_EXPRESSION_FLAGS_ONCE
3215
+ * PM_REGULAR_EXPRESSION_FLAGS_EUC_JP
3216
+ * PM_REGULAR_EXPRESSION_FLAGS_ASCII_8BIT
3217
+ * PM_REGULAR_EXPRESSION_FLAGS_WINDOWS_31J
3218
+ * PM_REGULAR_EXPRESSION_FLAGS_UTF_8
3219
+ *
3220
+ * @extends pm_node_t
3221
+ */
1430
3222
  typedef struct pm_match_last_line_node {
3223
+ /** The embedded base node. */
1431
3224
  pm_node_t base;
3225
+
3226
+ /** MatchLastLineNode#opening_loc */
1432
3227
  pm_location_t opening_loc;
3228
+
3229
+ /** MatchLastLineNode#content_loc */
1433
3230
  pm_location_t content_loc;
3231
+
3232
+ /** MatchLastLineNode#closing_loc */
1434
3233
  pm_location_t closing_loc;
3234
+
3235
+ /** MatchLastLineNode#unescaped */
1435
3236
  pm_string_t unescaped;
1436
3237
  } pm_match_last_line_node_t;
1437
3238
 
1438
- // MatchPredicateNode
1439
- //
1440
- // Type: PM_MATCH_PREDICATE_NODE
3239
+ /**
3240
+ * MatchPredicateNode
3241
+ *
3242
+ * Type: PM_MATCH_PREDICATE_NODE
3243
+ *
3244
+ * @extends pm_node_t
3245
+ */
1441
3246
  typedef struct pm_match_predicate_node {
3247
+ /** The embedded base node. */
1442
3248
  pm_node_t base;
3249
+
3250
+ /** MatchPredicateNode#value */
1443
3251
  struct pm_node *value;
3252
+
3253
+ /** MatchPredicateNode#pattern */
1444
3254
  struct pm_node *pattern;
3255
+
3256
+ /** MatchPredicateNode#operator_loc */
1445
3257
  pm_location_t operator_loc;
1446
3258
  } pm_match_predicate_node_t;
1447
3259
 
1448
- // MatchRequiredNode
1449
- //
1450
- // Type: PM_MATCH_REQUIRED_NODE
3260
+ /**
3261
+ * MatchRequiredNode
3262
+ *
3263
+ * Type: PM_MATCH_REQUIRED_NODE
3264
+ *
3265
+ * @extends pm_node_t
3266
+ */
1451
3267
  typedef struct pm_match_required_node {
3268
+ /** The embedded base node. */
1452
3269
  pm_node_t base;
3270
+
3271
+ /** MatchRequiredNode#value */
1453
3272
  struct pm_node *value;
3273
+
3274
+ /** MatchRequiredNode#pattern */
1454
3275
  struct pm_node *pattern;
3276
+
3277
+ /** MatchRequiredNode#operator_loc */
1455
3278
  pm_location_t operator_loc;
1456
3279
  } pm_match_required_node_t;
1457
3280
 
1458
- // MatchWriteNode
1459
- //
1460
- // Type: PM_MATCH_WRITE_NODE
3281
+ /**
3282
+ * MatchWriteNode
3283
+ *
3284
+ * Type: PM_MATCH_WRITE_NODE
3285
+ *
3286
+ * @extends pm_node_t
3287
+ */
1461
3288
  typedef struct pm_match_write_node {
3289
+ /** The embedded base node. */
1462
3290
  pm_node_t base;
3291
+
3292
+ /** MatchWriteNode#call */
1463
3293
  struct pm_call_node *call;
3294
+
3295
+ /** MatchWriteNode#locals */
1464
3296
  pm_constant_id_list_t locals;
1465
3297
  } pm_match_write_node_t;
1466
3298
 
1467
- // MissingNode
1468
- //
1469
- // Type: PM_MISSING_NODE
3299
+ /**
3300
+ * MissingNode
3301
+ *
3302
+ * Type: PM_MISSING_NODE
3303
+ *
3304
+ * @extends pm_node_t
3305
+ */
1470
3306
  typedef struct pm_missing_node {
3307
+ /** The embedded base node. */
1471
3308
  pm_node_t base;
1472
3309
  } pm_missing_node_t;
1473
3310
 
1474
- // ModuleNode
1475
- //
1476
- // Type: PM_MODULE_NODE
3311
+ /**
3312
+ * ModuleNode
3313
+ *
3314
+ * Type: PM_MODULE_NODE
3315
+ *
3316
+ * @extends pm_node_t
3317
+ */
1477
3318
  typedef struct pm_module_node {
3319
+ /** The embedded base node. */
1478
3320
  pm_node_t base;
3321
+
3322
+ /** ModuleNode#locals */
1479
3323
  pm_constant_id_list_t locals;
3324
+
3325
+ /** ModuleNode#module_keyword_loc */
1480
3326
  pm_location_t module_keyword_loc;
3327
+
3328
+ /** ModuleNode#constant_path */
1481
3329
  struct pm_node *constant_path;
3330
+
3331
+ /** ModuleNode#body */
1482
3332
  struct pm_node *body;
3333
+
3334
+ /** ModuleNode#end_keyword_loc */
1483
3335
  pm_location_t end_keyword_loc;
3336
+
3337
+ /** ModuleNode#name */
1484
3338
  pm_constant_id_t name;
1485
3339
  } pm_module_node_t;
1486
3340
 
1487
- // MultiTargetNode
1488
- //
1489
- // Type: PM_MULTI_TARGET_NODE
3341
+ /**
3342
+ * MultiTargetNode
3343
+ *
3344
+ * Type: PM_MULTI_TARGET_NODE
3345
+ *
3346
+ * @extends pm_node_t
3347
+ */
1490
3348
  typedef struct pm_multi_target_node {
3349
+ /** The embedded base node. */
1491
3350
  pm_node_t base;
3351
+
3352
+ /** MultiTargetNode#lefts */
1492
3353
  struct pm_node_list lefts;
3354
+
3355
+ /** MultiTargetNode#rest */
1493
3356
  struct pm_node *rest;
3357
+
3358
+ /** MultiTargetNode#rights */
1494
3359
  struct pm_node_list rights;
3360
+
3361
+ /** MultiTargetNode#lparen_loc */
1495
3362
  pm_location_t lparen_loc;
3363
+
3364
+ /** MultiTargetNode#rparen_loc */
1496
3365
  pm_location_t rparen_loc;
1497
3366
  } pm_multi_target_node_t;
1498
3367
 
1499
- // MultiWriteNode
1500
- //
1501
- // Type: PM_MULTI_WRITE_NODE
3368
+ /**
3369
+ * MultiWriteNode
3370
+ *
3371
+ * Type: PM_MULTI_WRITE_NODE
3372
+ *
3373
+ * @extends pm_node_t
3374
+ */
1502
3375
  typedef struct pm_multi_write_node {
3376
+ /** The embedded base node. */
1503
3377
  pm_node_t base;
3378
+
3379
+ /** MultiWriteNode#lefts */
1504
3380
  struct pm_node_list lefts;
3381
+
3382
+ /** MultiWriteNode#rest */
1505
3383
  struct pm_node *rest;
3384
+
3385
+ /** MultiWriteNode#rights */
1506
3386
  struct pm_node_list rights;
3387
+
3388
+ /** MultiWriteNode#lparen_loc */
1507
3389
  pm_location_t lparen_loc;
3390
+
3391
+ /** MultiWriteNode#rparen_loc */
1508
3392
  pm_location_t rparen_loc;
3393
+
3394
+ /** MultiWriteNode#operator_loc */
1509
3395
  pm_location_t operator_loc;
3396
+
3397
+ /** MultiWriteNode#value */
1510
3398
  struct pm_node *value;
1511
3399
  } pm_multi_write_node_t;
1512
3400
 
1513
- // NextNode
1514
- //
1515
- // Type: PM_NEXT_NODE
3401
+ /**
3402
+ * NextNode
3403
+ *
3404
+ * Type: PM_NEXT_NODE
3405
+ *
3406
+ * @extends pm_node_t
3407
+ */
1516
3408
  typedef struct pm_next_node {
3409
+ /** The embedded base node. */
1517
3410
  pm_node_t base;
3411
+
3412
+ /** NextNode#arguments */
1518
3413
  struct pm_arguments_node *arguments;
3414
+
3415
+ /** NextNode#keyword_loc */
1519
3416
  pm_location_t keyword_loc;
1520
3417
  } pm_next_node_t;
1521
3418
 
1522
- // NilNode
1523
- //
1524
- // Type: PM_NIL_NODE
3419
+ /**
3420
+ * NilNode
3421
+ *
3422
+ * Type: PM_NIL_NODE
3423
+ *
3424
+ * @extends pm_node_t
3425
+ */
1525
3426
  typedef struct pm_nil_node {
3427
+ /** The embedded base node. */
1526
3428
  pm_node_t base;
1527
3429
  } pm_nil_node_t;
1528
3430
 
1529
- // NoKeywordsParameterNode
1530
- //
1531
- // Type: PM_NO_KEYWORDS_PARAMETER_NODE
3431
+ /**
3432
+ * NoKeywordsParameterNode
3433
+ *
3434
+ * Type: PM_NO_KEYWORDS_PARAMETER_NODE
3435
+ *
3436
+ * @extends pm_node_t
3437
+ */
1532
3438
  typedef struct pm_no_keywords_parameter_node {
3439
+ /** The embedded base node. */
1533
3440
  pm_node_t base;
3441
+
3442
+ /** NoKeywordsParameterNode#operator_loc */
1534
3443
  pm_location_t operator_loc;
3444
+
3445
+ /** NoKeywordsParameterNode#keyword_loc */
1535
3446
  pm_location_t keyword_loc;
1536
3447
  } pm_no_keywords_parameter_node_t;
1537
3448
 
1538
- // NumberedReferenceReadNode
1539
- //
1540
- // Type: PM_NUMBERED_REFERENCE_READ_NODE
3449
+ /**
3450
+ * NumberedReferenceReadNode
3451
+ *
3452
+ * Type: PM_NUMBERED_REFERENCE_READ_NODE
3453
+ *
3454
+ * @extends pm_node_t
3455
+ */
1541
3456
  typedef struct pm_numbered_reference_read_node {
3457
+ /** The embedded base node. */
1542
3458
  pm_node_t base;
3459
+
3460
+ /** NumberedReferenceReadNode#number */
1543
3461
  uint32_t number;
1544
3462
  } pm_numbered_reference_read_node_t;
1545
3463
 
1546
- // OptionalParameterNode
1547
- //
1548
- // Type: PM_OPTIONAL_PARAMETER_NODE
3464
+ /**
3465
+ * OptionalKeywordParameterNode
3466
+ *
3467
+ * Type: PM_OPTIONAL_KEYWORD_PARAMETER_NODE
3468
+ *
3469
+ * @extends pm_node_t
3470
+ */
3471
+ typedef struct pm_optional_keyword_parameter_node {
3472
+ /** The embedded base node. */
3473
+ pm_node_t base;
3474
+
3475
+ /** OptionalKeywordParameterNode#name */
3476
+ pm_constant_id_t name;
3477
+
3478
+ /** OptionalKeywordParameterNode#name_loc */
3479
+ pm_location_t name_loc;
3480
+
3481
+ /** OptionalKeywordParameterNode#value */
3482
+ struct pm_node *value;
3483
+ } pm_optional_keyword_parameter_node_t;
3484
+
3485
+ /**
3486
+ * OptionalParameterNode
3487
+ *
3488
+ * Type: PM_OPTIONAL_PARAMETER_NODE
3489
+ *
3490
+ * @extends pm_node_t
3491
+ */
1549
3492
  typedef struct pm_optional_parameter_node {
3493
+ /** The embedded base node. */
1550
3494
  pm_node_t base;
3495
+
3496
+ /** OptionalParameterNode#name */
1551
3497
  pm_constant_id_t name;
3498
+
3499
+ /** OptionalParameterNode#name_loc */
1552
3500
  pm_location_t name_loc;
3501
+
3502
+ /** OptionalParameterNode#operator_loc */
1553
3503
  pm_location_t operator_loc;
3504
+
3505
+ /** OptionalParameterNode#value */
1554
3506
  struct pm_node *value;
1555
3507
  } pm_optional_parameter_node_t;
1556
3508
 
1557
- // OrNode
1558
- //
1559
- // Type: PM_OR_NODE
3509
+ /**
3510
+ * OrNode
3511
+ *
3512
+ * Type: PM_OR_NODE
3513
+ *
3514
+ * @extends pm_node_t
3515
+ */
1560
3516
  typedef struct pm_or_node {
3517
+ /** The embedded base node. */
1561
3518
  pm_node_t base;
3519
+
3520
+ /** OrNode#left */
1562
3521
  struct pm_node *left;
3522
+
3523
+ /** OrNode#right */
1563
3524
  struct pm_node *right;
3525
+
3526
+ /** OrNode#operator_loc */
1564
3527
  pm_location_t operator_loc;
1565
3528
  } pm_or_node_t;
1566
3529
 
1567
- // ParametersNode
1568
- //
1569
- // Type: PM_PARAMETERS_NODE
3530
+ /**
3531
+ * ParametersNode
3532
+ *
3533
+ * Type: PM_PARAMETERS_NODE
3534
+ *
3535
+ * @extends pm_node_t
3536
+ */
1570
3537
  typedef struct pm_parameters_node {
3538
+ /** The embedded base node. */
1571
3539
  pm_node_t base;
3540
+
3541
+ /** ParametersNode#requireds */
1572
3542
  struct pm_node_list requireds;
3543
+
3544
+ /** ParametersNode#optionals */
1573
3545
  struct pm_node_list optionals;
3546
+
3547
+ /** ParametersNode#rest */
1574
3548
  struct pm_rest_parameter_node *rest;
3549
+
3550
+ /** ParametersNode#posts */
1575
3551
  struct pm_node_list posts;
3552
+
3553
+ /** ParametersNode#keywords */
1576
3554
  struct pm_node_list keywords;
3555
+
3556
+ /** ParametersNode#keyword_rest */
1577
3557
  struct pm_node *keyword_rest;
3558
+
3559
+ /** ParametersNode#block */
1578
3560
  struct pm_block_parameter_node *block;
1579
3561
  } pm_parameters_node_t;
1580
3562
 
1581
- // ParenthesesNode
1582
- //
1583
- // Type: PM_PARENTHESES_NODE
3563
+ /**
3564
+ * ParenthesesNode
3565
+ *
3566
+ * Type: PM_PARENTHESES_NODE
3567
+ *
3568
+ * @extends pm_node_t
3569
+ */
1584
3570
  typedef struct pm_parentheses_node {
3571
+ /** The embedded base node. */
1585
3572
  pm_node_t base;
3573
+
3574
+ /** ParenthesesNode#body */
1586
3575
  struct pm_node *body;
3576
+
3577
+ /** ParenthesesNode#opening_loc */
1587
3578
  pm_location_t opening_loc;
3579
+
3580
+ /** ParenthesesNode#closing_loc */
1588
3581
  pm_location_t closing_loc;
1589
3582
  } pm_parentheses_node_t;
1590
3583
 
1591
- // PinnedExpressionNode
1592
- //
1593
- // Type: PM_PINNED_EXPRESSION_NODE
3584
+ /**
3585
+ * PinnedExpressionNode
3586
+ *
3587
+ * Type: PM_PINNED_EXPRESSION_NODE
3588
+ *
3589
+ * @extends pm_node_t
3590
+ */
1594
3591
  typedef struct pm_pinned_expression_node {
3592
+ /** The embedded base node. */
1595
3593
  pm_node_t base;
3594
+
3595
+ /** PinnedExpressionNode#expression */
1596
3596
  struct pm_node *expression;
3597
+
3598
+ /** PinnedExpressionNode#operator_loc */
1597
3599
  pm_location_t operator_loc;
3600
+
3601
+ /** PinnedExpressionNode#lparen_loc */
1598
3602
  pm_location_t lparen_loc;
3603
+
3604
+ /** PinnedExpressionNode#rparen_loc */
1599
3605
  pm_location_t rparen_loc;
1600
3606
  } pm_pinned_expression_node_t;
1601
3607
 
1602
- // PinnedVariableNode
1603
- //
1604
- // Type: PM_PINNED_VARIABLE_NODE
3608
+ /**
3609
+ * PinnedVariableNode
3610
+ *
3611
+ * Type: PM_PINNED_VARIABLE_NODE
3612
+ *
3613
+ * @extends pm_node_t
3614
+ */
1605
3615
  typedef struct pm_pinned_variable_node {
3616
+ /** The embedded base node. */
1606
3617
  pm_node_t base;
3618
+
3619
+ /** PinnedVariableNode#variable */
1607
3620
  struct pm_node *variable;
3621
+
3622
+ /** PinnedVariableNode#operator_loc */
1608
3623
  pm_location_t operator_loc;
1609
3624
  } pm_pinned_variable_node_t;
1610
3625
 
1611
- // PostExecutionNode
1612
- //
1613
- // Type: PM_POST_EXECUTION_NODE
3626
+ /**
3627
+ * PostExecutionNode
3628
+ *
3629
+ * Type: PM_POST_EXECUTION_NODE
3630
+ *
3631
+ * @extends pm_node_t
3632
+ */
1614
3633
  typedef struct pm_post_execution_node {
3634
+ /** The embedded base node. */
1615
3635
  pm_node_t base;
3636
+
3637
+ /** PostExecutionNode#statements */
1616
3638
  struct pm_statements_node *statements;
3639
+
3640
+ /** PostExecutionNode#keyword_loc */
1617
3641
  pm_location_t keyword_loc;
3642
+
3643
+ /** PostExecutionNode#opening_loc */
1618
3644
  pm_location_t opening_loc;
3645
+
3646
+ /** PostExecutionNode#closing_loc */
1619
3647
  pm_location_t closing_loc;
1620
3648
  } pm_post_execution_node_t;
1621
3649
 
1622
- // PreExecutionNode
1623
- //
1624
- // Type: PM_PRE_EXECUTION_NODE
3650
+ /**
3651
+ * PreExecutionNode
3652
+ *
3653
+ * Type: PM_PRE_EXECUTION_NODE
3654
+ *
3655
+ * @extends pm_node_t
3656
+ */
1625
3657
  typedef struct pm_pre_execution_node {
3658
+ /** The embedded base node. */
1626
3659
  pm_node_t base;
3660
+
3661
+ /** PreExecutionNode#statements */
1627
3662
  struct pm_statements_node *statements;
3663
+
3664
+ /** PreExecutionNode#keyword_loc */
1628
3665
  pm_location_t keyword_loc;
3666
+
3667
+ /** PreExecutionNode#opening_loc */
1629
3668
  pm_location_t opening_loc;
3669
+
3670
+ /** PreExecutionNode#closing_loc */
1630
3671
  pm_location_t closing_loc;
1631
3672
  } pm_pre_execution_node_t;
1632
3673
 
1633
- // ProgramNode
1634
- //
1635
- // Type: PM_PROGRAM_NODE
3674
+ /**
3675
+ * ProgramNode
3676
+ *
3677
+ * Type: PM_PROGRAM_NODE
3678
+ *
3679
+ * @extends pm_node_t
3680
+ */
1636
3681
  typedef struct pm_program_node {
3682
+ /** The embedded base node. */
1637
3683
  pm_node_t base;
3684
+
3685
+ /** ProgramNode#locals */
1638
3686
  pm_constant_id_list_t locals;
3687
+
3688
+ /** ProgramNode#statements */
1639
3689
  struct pm_statements_node *statements;
1640
3690
  } pm_program_node_t;
1641
3691
 
1642
- // RangeNode
1643
- //
1644
- // Type: PM_RANGE_NODE
1645
- // Flags:
1646
- // PM_RANGE_FLAGS_EXCLUDE_END
3692
+ /**
3693
+ * RangeNode
3694
+ *
3695
+ * Type: PM_RANGE_NODE
3696
+ * Flags:
3697
+ * PM_RANGE_FLAGS_EXCLUDE_END
3698
+ *
3699
+ * @extends pm_node_t
3700
+ */
1647
3701
  typedef struct pm_range_node {
3702
+ /** The embedded base node. */
1648
3703
  pm_node_t base;
3704
+
3705
+ /** RangeNode#left */
1649
3706
  struct pm_node *left;
3707
+
3708
+ /** RangeNode#right */
1650
3709
  struct pm_node *right;
3710
+
3711
+ /** RangeNode#operator_loc */
1651
3712
  pm_location_t operator_loc;
1652
3713
  } pm_range_node_t;
1653
3714
 
1654
- // RationalNode
1655
- //
1656
- // Type: PM_RATIONAL_NODE
3715
+ /**
3716
+ * RationalNode
3717
+ *
3718
+ * Type: PM_RATIONAL_NODE
3719
+ *
3720
+ * @extends pm_node_t
3721
+ */
1657
3722
  typedef struct pm_rational_node {
3723
+ /** The embedded base node. */
1658
3724
  pm_node_t base;
3725
+
3726
+ /** RationalNode#numeric */
1659
3727
  struct pm_node *numeric;
1660
3728
  } pm_rational_node_t;
1661
3729
 
1662
- // RedoNode
1663
- //
1664
- // Type: PM_REDO_NODE
3730
+ /**
3731
+ * RedoNode
3732
+ *
3733
+ * Type: PM_REDO_NODE
3734
+ *
3735
+ * @extends pm_node_t
3736
+ */
1665
3737
  typedef struct pm_redo_node {
3738
+ /** The embedded base node. */
1666
3739
  pm_node_t base;
1667
3740
  } pm_redo_node_t;
1668
3741
 
1669
- // RegularExpressionNode
1670
- //
1671
- // Type: PM_REGULAR_EXPRESSION_NODE
1672
- // Flags:
1673
- // PM_REGULAR_EXPRESSION_FLAGS_IGNORE_CASE
1674
- // PM_REGULAR_EXPRESSION_FLAGS_EXTENDED
1675
- // PM_REGULAR_EXPRESSION_FLAGS_MULTI_LINE
1676
- // PM_REGULAR_EXPRESSION_FLAGS_ONCE
1677
- // PM_REGULAR_EXPRESSION_FLAGS_EUC_JP
1678
- // PM_REGULAR_EXPRESSION_FLAGS_ASCII_8BIT
1679
- // PM_REGULAR_EXPRESSION_FLAGS_WINDOWS_31J
1680
- // PM_REGULAR_EXPRESSION_FLAGS_UTF_8
3742
+ /**
3743
+ * RegularExpressionNode
3744
+ *
3745
+ * Type: PM_REGULAR_EXPRESSION_NODE
3746
+ * Flags:
3747
+ * PM_REGULAR_EXPRESSION_FLAGS_IGNORE_CASE
3748
+ * PM_REGULAR_EXPRESSION_FLAGS_EXTENDED
3749
+ * PM_REGULAR_EXPRESSION_FLAGS_MULTI_LINE
3750
+ * PM_REGULAR_EXPRESSION_FLAGS_ONCE
3751
+ * PM_REGULAR_EXPRESSION_FLAGS_EUC_JP
3752
+ * PM_REGULAR_EXPRESSION_FLAGS_ASCII_8BIT
3753
+ * PM_REGULAR_EXPRESSION_FLAGS_WINDOWS_31J
3754
+ * PM_REGULAR_EXPRESSION_FLAGS_UTF_8
3755
+ *
3756
+ * @extends pm_node_t
3757
+ */
1681
3758
  typedef struct pm_regular_expression_node {
3759
+ /** The embedded base node. */
1682
3760
  pm_node_t base;
3761
+
3762
+ /** RegularExpressionNode#opening_loc */
1683
3763
  pm_location_t opening_loc;
3764
+
3765
+ /** RegularExpressionNode#content_loc */
1684
3766
  pm_location_t content_loc;
3767
+
3768
+ /** RegularExpressionNode#closing_loc */
1685
3769
  pm_location_t closing_loc;
3770
+
3771
+ /** RegularExpressionNode#unescaped */
1686
3772
  pm_string_t unescaped;
1687
3773
  } pm_regular_expression_node_t;
1688
3774
 
1689
- // RequiredParameterNode
1690
- //
1691
- // Type: PM_REQUIRED_PARAMETER_NODE
3775
+ /**
3776
+ * RequiredKeywordParameterNode
3777
+ *
3778
+ * Type: PM_REQUIRED_KEYWORD_PARAMETER_NODE
3779
+ *
3780
+ * @extends pm_node_t
3781
+ */
3782
+ typedef struct pm_required_keyword_parameter_node {
3783
+ /** The embedded base node. */
3784
+ pm_node_t base;
3785
+
3786
+ /** RequiredKeywordParameterNode#name */
3787
+ pm_constant_id_t name;
3788
+
3789
+ /** RequiredKeywordParameterNode#name_loc */
3790
+ pm_location_t name_loc;
3791
+ } pm_required_keyword_parameter_node_t;
3792
+
3793
+ /**
3794
+ * RequiredParameterNode
3795
+ *
3796
+ * Type: PM_REQUIRED_PARAMETER_NODE
3797
+ *
3798
+ * @extends pm_node_t
3799
+ */
1692
3800
  typedef struct pm_required_parameter_node {
3801
+ /** The embedded base node. */
1693
3802
  pm_node_t base;
3803
+
3804
+ /** RequiredParameterNode#name */
1694
3805
  pm_constant_id_t name;
1695
3806
  } pm_required_parameter_node_t;
1696
3807
 
1697
- // RescueModifierNode
1698
- //
1699
- // Type: PM_RESCUE_MODIFIER_NODE
3808
+ /**
3809
+ * RescueModifierNode
3810
+ *
3811
+ * Type: PM_RESCUE_MODIFIER_NODE
3812
+ *
3813
+ * @extends pm_node_t
3814
+ */
1700
3815
  typedef struct pm_rescue_modifier_node {
3816
+ /** The embedded base node. */
1701
3817
  pm_node_t base;
3818
+
3819
+ /** RescueModifierNode#expression */
1702
3820
  struct pm_node *expression;
3821
+
3822
+ /** RescueModifierNode#keyword_loc */
1703
3823
  pm_location_t keyword_loc;
3824
+
3825
+ /** RescueModifierNode#rescue_expression */
1704
3826
  struct pm_node *rescue_expression;
1705
3827
  } pm_rescue_modifier_node_t;
1706
3828
 
1707
- // RescueNode
1708
- //
1709
- // Type: PM_RESCUE_NODE
3829
+ /**
3830
+ * RescueNode
3831
+ *
3832
+ * Type: PM_RESCUE_NODE
3833
+ *
3834
+ * @extends pm_node_t
3835
+ */
1710
3836
  typedef struct pm_rescue_node {
3837
+ /** The embedded base node. */
1711
3838
  pm_node_t base;
3839
+
3840
+ /** RescueNode#keyword_loc */
1712
3841
  pm_location_t keyword_loc;
3842
+
3843
+ /** RescueNode#exceptions */
1713
3844
  struct pm_node_list exceptions;
3845
+
3846
+ /** RescueNode#operator_loc */
1714
3847
  pm_location_t operator_loc;
3848
+
3849
+ /** RescueNode#reference */
1715
3850
  struct pm_node *reference;
3851
+
3852
+ /** RescueNode#statements */
1716
3853
  struct pm_statements_node *statements;
3854
+
3855
+ /** RescueNode#consequent */
1717
3856
  struct pm_rescue_node *consequent;
1718
3857
  } pm_rescue_node_t;
1719
3858
 
1720
- // RestParameterNode
1721
- //
1722
- // Type: PM_REST_PARAMETER_NODE
3859
+ /**
3860
+ * RestParameterNode
3861
+ *
3862
+ * Type: PM_REST_PARAMETER_NODE
3863
+ *
3864
+ * @extends pm_node_t
3865
+ */
1723
3866
  typedef struct pm_rest_parameter_node {
3867
+ /** The embedded base node. */
1724
3868
  pm_node_t base;
3869
+
3870
+ /** RestParameterNode#name */
1725
3871
  pm_constant_id_t name;
3872
+
3873
+ /** RestParameterNode#name_loc */
1726
3874
  pm_location_t name_loc;
3875
+
3876
+ /** RestParameterNode#operator_loc */
1727
3877
  pm_location_t operator_loc;
1728
3878
  } pm_rest_parameter_node_t;
1729
3879
 
1730
- // RetryNode
1731
- //
1732
- // Type: PM_RETRY_NODE
3880
+ /**
3881
+ * RetryNode
3882
+ *
3883
+ * Type: PM_RETRY_NODE
3884
+ *
3885
+ * @extends pm_node_t
3886
+ */
1733
3887
  typedef struct pm_retry_node {
3888
+ /** The embedded base node. */
1734
3889
  pm_node_t base;
1735
3890
  } pm_retry_node_t;
1736
3891
 
1737
- // ReturnNode
1738
- //
1739
- // Type: PM_RETURN_NODE
3892
+ /**
3893
+ * ReturnNode
3894
+ *
3895
+ * Type: PM_RETURN_NODE
3896
+ *
3897
+ * @extends pm_node_t
3898
+ */
1740
3899
  typedef struct pm_return_node {
3900
+ /** The embedded base node. */
1741
3901
  pm_node_t base;
3902
+
3903
+ /** ReturnNode#keyword_loc */
1742
3904
  pm_location_t keyword_loc;
3905
+
3906
+ /** ReturnNode#arguments */
1743
3907
  struct pm_arguments_node *arguments;
1744
3908
  } pm_return_node_t;
1745
3909
 
1746
- // SelfNode
1747
- //
1748
- // Type: PM_SELF_NODE
3910
+ /**
3911
+ * SelfNode
3912
+ *
3913
+ * Type: PM_SELF_NODE
3914
+ *
3915
+ * @extends pm_node_t
3916
+ */
1749
3917
  typedef struct pm_self_node {
3918
+ /** The embedded base node. */
1750
3919
  pm_node_t base;
1751
3920
  } pm_self_node_t;
1752
3921
 
1753
- // SingletonClassNode
1754
- //
1755
- // Type: PM_SINGLETON_CLASS_NODE
3922
+ /**
3923
+ * SingletonClassNode
3924
+ *
3925
+ * Type: PM_SINGLETON_CLASS_NODE
3926
+ *
3927
+ * @extends pm_node_t
3928
+ */
1756
3929
  typedef struct pm_singleton_class_node {
3930
+ /** The embedded base node. */
1757
3931
  pm_node_t base;
3932
+
3933
+ /** SingletonClassNode#locals */
1758
3934
  pm_constant_id_list_t locals;
3935
+
3936
+ /** SingletonClassNode#class_keyword_loc */
1759
3937
  pm_location_t class_keyword_loc;
3938
+
3939
+ /** SingletonClassNode#operator_loc */
1760
3940
  pm_location_t operator_loc;
3941
+
3942
+ /** SingletonClassNode#expression */
1761
3943
  struct pm_node *expression;
3944
+
3945
+ /** SingletonClassNode#body */
1762
3946
  struct pm_node *body;
3947
+
3948
+ /** SingletonClassNode#end_keyword_loc */
1763
3949
  pm_location_t end_keyword_loc;
1764
3950
  } pm_singleton_class_node_t;
1765
3951
 
1766
- // SourceEncodingNode
1767
- //
1768
- // Type: PM_SOURCE_ENCODING_NODE
3952
+ /**
3953
+ * SourceEncodingNode
3954
+ *
3955
+ * Type: PM_SOURCE_ENCODING_NODE
3956
+ *
3957
+ * @extends pm_node_t
3958
+ */
1769
3959
  typedef struct pm_source_encoding_node {
3960
+ /** The embedded base node. */
1770
3961
  pm_node_t base;
1771
3962
  } pm_source_encoding_node_t;
1772
3963
 
1773
- // SourceFileNode
1774
- //
1775
- // Type: PM_SOURCE_FILE_NODE
3964
+ /**
3965
+ * SourceFileNode
3966
+ *
3967
+ * Type: PM_SOURCE_FILE_NODE
3968
+ *
3969
+ * @extends pm_node_t
3970
+ */
1776
3971
  typedef struct pm_source_file_node {
3972
+ /** The embedded base node. */
1777
3973
  pm_node_t base;
3974
+
3975
+ /** SourceFileNode#filepath */
1778
3976
  pm_string_t filepath;
1779
3977
  } pm_source_file_node_t;
1780
3978
 
1781
- // SourceLineNode
1782
- //
1783
- // Type: PM_SOURCE_LINE_NODE
3979
+ /**
3980
+ * SourceLineNode
3981
+ *
3982
+ * Type: PM_SOURCE_LINE_NODE
3983
+ *
3984
+ * @extends pm_node_t
3985
+ */
1784
3986
  typedef struct pm_source_line_node {
3987
+ /** The embedded base node. */
1785
3988
  pm_node_t base;
1786
3989
  } pm_source_line_node_t;
1787
3990
 
1788
- // SplatNode
1789
- //
1790
- // Type: PM_SPLAT_NODE
3991
+ /**
3992
+ * SplatNode
3993
+ *
3994
+ * Type: PM_SPLAT_NODE
3995
+ *
3996
+ * @extends pm_node_t
3997
+ */
1791
3998
  typedef struct pm_splat_node {
3999
+ /** The embedded base node. */
1792
4000
  pm_node_t base;
4001
+
4002
+ /** SplatNode#operator_loc */
1793
4003
  pm_location_t operator_loc;
4004
+
4005
+ /** SplatNode#expression */
1794
4006
  struct pm_node *expression;
1795
4007
  } pm_splat_node_t;
1796
4008
 
1797
- // StatementsNode
1798
- //
1799
- // Type: PM_STATEMENTS_NODE
4009
+ /**
4010
+ * StatementsNode
4011
+ *
4012
+ * Type: PM_STATEMENTS_NODE
4013
+ *
4014
+ * @extends pm_node_t
4015
+ */
1800
4016
  typedef struct pm_statements_node {
4017
+ /** The embedded base node. */
1801
4018
  pm_node_t base;
4019
+
4020
+ /** StatementsNode#body */
1802
4021
  struct pm_node_list body;
1803
4022
  } pm_statements_node_t;
1804
4023
 
1805
- // StringConcatNode
1806
- //
1807
- // Type: PM_STRING_CONCAT_NODE
4024
+ /**
4025
+ * StringConcatNode
4026
+ *
4027
+ * Type: PM_STRING_CONCAT_NODE
4028
+ *
4029
+ * @extends pm_node_t
4030
+ */
1808
4031
  typedef struct pm_string_concat_node {
4032
+ /** The embedded base node. */
1809
4033
  pm_node_t base;
4034
+
4035
+ /** StringConcatNode#left */
1810
4036
  struct pm_node *left;
4037
+
4038
+ /** StringConcatNode#right */
1811
4039
  struct pm_node *right;
1812
4040
  } pm_string_concat_node_t;
1813
4041
 
1814
- // StringNode
1815
- //
1816
- // Type: PM_STRING_NODE
1817
- // Flags:
1818
- // PM_STRING_FLAGS_FROZEN
4042
+ /**
4043
+ * StringNode
4044
+ *
4045
+ * Type: PM_STRING_NODE
4046
+ * Flags:
4047
+ * PM_STRING_FLAGS_FROZEN
4048
+ *
4049
+ * @extends pm_node_t
4050
+ */
1819
4051
  typedef struct pm_string_node {
4052
+ /** The embedded base node. */
1820
4053
  pm_node_t base;
4054
+
4055
+ /** StringNode#opening_loc */
1821
4056
  pm_location_t opening_loc;
4057
+
4058
+ /** StringNode#content_loc */
1822
4059
  pm_location_t content_loc;
4060
+
4061
+ /** StringNode#closing_loc */
1823
4062
  pm_location_t closing_loc;
4063
+
4064
+ /** StringNode#unescaped */
1824
4065
  pm_string_t unescaped;
1825
4066
  } pm_string_node_t;
1826
4067
 
1827
- // SuperNode
1828
- //
1829
- // Type: PM_SUPER_NODE
4068
+ /**
4069
+ * SuperNode
4070
+ *
4071
+ * Type: PM_SUPER_NODE
4072
+ *
4073
+ * @extends pm_node_t
4074
+ */
1830
4075
  typedef struct pm_super_node {
4076
+ /** The embedded base node. */
1831
4077
  pm_node_t base;
4078
+
4079
+ /** SuperNode#keyword_loc */
1832
4080
  pm_location_t keyword_loc;
4081
+
4082
+ /** SuperNode#lparen_loc */
1833
4083
  pm_location_t lparen_loc;
4084
+
4085
+ /** SuperNode#arguments */
1834
4086
  struct pm_arguments_node *arguments;
4087
+
4088
+ /** SuperNode#rparen_loc */
1835
4089
  pm_location_t rparen_loc;
4090
+
4091
+ /** SuperNode#block */
1836
4092
  struct pm_node *block;
1837
4093
  } pm_super_node_t;
1838
4094
 
1839
- // SymbolNode
1840
- //
1841
- // Type: PM_SYMBOL_NODE
4095
+ /**
4096
+ * SymbolNode
4097
+ *
4098
+ * Type: PM_SYMBOL_NODE
4099
+ *
4100
+ * @extends pm_node_t
4101
+ */
1842
4102
  typedef struct pm_symbol_node {
4103
+ /** The embedded base node. */
1843
4104
  pm_node_t base;
4105
+
4106
+ /** SymbolNode#opening_loc */
1844
4107
  pm_location_t opening_loc;
4108
+
4109
+ /** SymbolNode#value_loc */
1845
4110
  pm_location_t value_loc;
4111
+
4112
+ /** SymbolNode#closing_loc */
1846
4113
  pm_location_t closing_loc;
4114
+
4115
+ /** SymbolNode#unescaped */
1847
4116
  pm_string_t unescaped;
1848
4117
  } pm_symbol_node_t;
1849
4118
 
1850
- // TrueNode
1851
- //
1852
- // Type: PM_TRUE_NODE
4119
+ /**
4120
+ * TrueNode
4121
+ *
4122
+ * Type: PM_TRUE_NODE
4123
+ *
4124
+ * @extends pm_node_t
4125
+ */
1853
4126
  typedef struct pm_true_node {
4127
+ /** The embedded base node. */
1854
4128
  pm_node_t base;
1855
4129
  } pm_true_node_t;
1856
4130
 
1857
- // UndefNode
1858
- //
1859
- // Type: PM_UNDEF_NODE
4131
+ /**
4132
+ * UndefNode
4133
+ *
4134
+ * Type: PM_UNDEF_NODE
4135
+ *
4136
+ * @extends pm_node_t
4137
+ */
1860
4138
  typedef struct pm_undef_node {
4139
+ /** The embedded base node. */
1861
4140
  pm_node_t base;
4141
+
4142
+ /** UndefNode#names */
1862
4143
  struct pm_node_list names;
4144
+
4145
+ /** UndefNode#keyword_loc */
1863
4146
  pm_location_t keyword_loc;
1864
4147
  } pm_undef_node_t;
1865
4148
 
1866
- // UnlessNode
1867
- //
1868
- // Type: PM_UNLESS_NODE
4149
+ /**
4150
+ * UnlessNode
4151
+ *
4152
+ * Type: PM_UNLESS_NODE
4153
+ *
4154
+ * @extends pm_node_t
4155
+ */
1869
4156
  typedef struct pm_unless_node {
4157
+ /** The embedded base node. */
1870
4158
  pm_node_t base;
4159
+
4160
+ /** UnlessNode#keyword_loc */
1871
4161
  pm_location_t keyword_loc;
4162
+
4163
+ /** UnlessNode#predicate */
1872
4164
  struct pm_node *predicate;
4165
+
4166
+ /** UnlessNode#statements */
1873
4167
  struct pm_statements_node *statements;
4168
+
4169
+ /** UnlessNode#consequent */
1874
4170
  struct pm_else_node *consequent;
4171
+
4172
+ /** UnlessNode#end_keyword_loc */
1875
4173
  pm_location_t end_keyword_loc;
1876
4174
  } pm_unless_node_t;
1877
4175
 
1878
- // UntilNode
1879
- //
1880
- // Type: PM_UNTIL_NODE
1881
- // Flags:
1882
- // PM_LOOP_FLAGS_BEGIN_MODIFIER
4176
+ /**
4177
+ * UntilNode
4178
+ *
4179
+ * Type: PM_UNTIL_NODE
4180
+ * Flags:
4181
+ * PM_LOOP_FLAGS_BEGIN_MODIFIER
4182
+ *
4183
+ * @extends pm_node_t
4184
+ */
1883
4185
  typedef struct pm_until_node {
4186
+ /** The embedded base node. */
1884
4187
  pm_node_t base;
4188
+
4189
+ /** UntilNode#keyword_loc */
1885
4190
  pm_location_t keyword_loc;
4191
+
4192
+ /** UntilNode#closing_loc */
1886
4193
  pm_location_t closing_loc;
4194
+
4195
+ /** UntilNode#predicate */
1887
4196
  struct pm_node *predicate;
4197
+
4198
+ /** UntilNode#statements */
1888
4199
  struct pm_statements_node *statements;
1889
4200
  } pm_until_node_t;
1890
4201
 
1891
- // WhenNode
1892
- //
1893
- // Type: PM_WHEN_NODE
4202
+ /**
4203
+ * WhenNode
4204
+ *
4205
+ * Type: PM_WHEN_NODE
4206
+ *
4207
+ * @extends pm_node_t
4208
+ */
1894
4209
  typedef struct pm_when_node {
4210
+ /** The embedded base node. */
1895
4211
  pm_node_t base;
4212
+
4213
+ /** WhenNode#keyword_loc */
1896
4214
  pm_location_t keyword_loc;
4215
+
4216
+ /** WhenNode#conditions */
1897
4217
  struct pm_node_list conditions;
4218
+
4219
+ /** WhenNode#statements */
1898
4220
  struct pm_statements_node *statements;
1899
4221
  } pm_when_node_t;
1900
4222
 
1901
- // WhileNode
1902
- //
1903
- // Type: PM_WHILE_NODE
1904
- // Flags:
1905
- // PM_LOOP_FLAGS_BEGIN_MODIFIER
4223
+ /**
4224
+ * WhileNode
4225
+ *
4226
+ * Type: PM_WHILE_NODE
4227
+ * Flags:
4228
+ * PM_LOOP_FLAGS_BEGIN_MODIFIER
4229
+ *
4230
+ * @extends pm_node_t
4231
+ */
1906
4232
  typedef struct pm_while_node {
4233
+ /** The embedded base node. */
1907
4234
  pm_node_t base;
4235
+
4236
+ /** WhileNode#keyword_loc */
1908
4237
  pm_location_t keyword_loc;
4238
+
4239
+ /** WhileNode#closing_loc */
1909
4240
  pm_location_t closing_loc;
4241
+
4242
+ /** WhileNode#predicate */
1910
4243
  struct pm_node *predicate;
4244
+
4245
+ /** WhileNode#statements */
1911
4246
  struct pm_statements_node *statements;
1912
4247
  } pm_while_node_t;
1913
4248
 
1914
- // XStringNode
1915
- //
1916
- // Type: PM_X_STRING_NODE
4249
+ /**
4250
+ * XStringNode
4251
+ *
4252
+ * Type: PM_X_STRING_NODE
4253
+ *
4254
+ * @extends pm_node_t
4255
+ */
1917
4256
  typedef struct pm_x_string_node {
4257
+ /** The embedded base node. */
1918
4258
  pm_node_t base;
4259
+
4260
+ /** XStringNode#opening_loc */
1919
4261
  pm_location_t opening_loc;
4262
+
4263
+ /** XStringNode#content_loc */
1920
4264
  pm_location_t content_loc;
4265
+
4266
+ /** XStringNode#closing_loc */
1921
4267
  pm_location_t closing_loc;
4268
+
4269
+ /** XStringNode#unescaped */
1922
4270
  pm_string_t unescaped;
1923
4271
  } pm_x_string_node_t;
1924
4272
 
1925
- // YieldNode
1926
- //
1927
- // Type: PM_YIELD_NODE
4273
+ /**
4274
+ * YieldNode
4275
+ *
4276
+ * Type: PM_YIELD_NODE
4277
+ *
4278
+ * @extends pm_node_t
4279
+ */
1928
4280
  typedef struct pm_yield_node {
4281
+ /** The embedded base node. */
1929
4282
  pm_node_t base;
4283
+
4284
+ /** YieldNode#keyword_loc */
1930
4285
  pm_location_t keyword_loc;
4286
+
4287
+ /** YieldNode#lparen_loc */
1931
4288
  pm_location_t lparen_loc;
4289
+
4290
+ /** YieldNode#arguments */
1932
4291
  struct pm_arguments_node *arguments;
4292
+
4293
+ /** YieldNode#rparen_loc */
1933
4294
  pm_location_t rparen_loc;
1934
4295
  } pm_yield_node_t;
1935
4296
 
1936
- // ArgumentsNodeFlags
4297
+ /**
4298
+ * Flags for arguments nodes.
4299
+ */
1937
4300
  typedef enum pm_arguments_node_flags {
1938
- PM_ARGUMENTS_NODE_FLAGS_KEYWORD_SPLAT = 1 << 0,
4301
+ /** if arguments contain keyword splat */
4302
+ PM_ARGUMENTS_NODE_FLAGS_KEYWORD_SPLAT = 1,
1939
4303
  } pm_arguments_node_flags_t;
1940
4304
 
1941
- // CallNodeFlags
4305
+ /**
4306
+ * Flags for call nodes.
4307
+ */
1942
4308
  typedef enum pm_call_node_flags {
1943
- PM_CALL_NODE_FLAGS_SAFE_NAVIGATION = 1 << 0,
1944
- PM_CALL_NODE_FLAGS_VARIABLE_CALL = 1 << 1,
4309
+ /** &. operator */
4310
+ PM_CALL_NODE_FLAGS_SAFE_NAVIGATION = 1,
4311
+
4312
+ /** a call that could have been a local variable */
4313
+ PM_CALL_NODE_FLAGS_VARIABLE_CALL = 2,
1945
4314
  } pm_call_node_flags_t;
1946
4315
 
1947
- // IntegerBaseFlags
4316
+ /**
4317
+ * Flags for integer nodes that correspond to the base of the integer.
4318
+ */
1948
4319
  typedef enum pm_integer_base_flags {
1949
- PM_INTEGER_BASE_FLAGS_BINARY = 1 << 0,
1950
- PM_INTEGER_BASE_FLAGS_OCTAL = 1 << 1,
1951
- PM_INTEGER_BASE_FLAGS_DECIMAL = 1 << 2,
1952
- PM_INTEGER_BASE_FLAGS_HEXADECIMAL = 1 << 3,
4320
+ /** 0b prefix */
4321
+ PM_INTEGER_BASE_FLAGS_BINARY = 1,
4322
+
4323
+ /** 0o or 0 prefix */
4324
+ PM_INTEGER_BASE_FLAGS_OCTAL = 2,
4325
+
4326
+ /** 0d or no prefix */
4327
+ PM_INTEGER_BASE_FLAGS_DECIMAL = 4,
4328
+
4329
+ /** 0x prefix */
4330
+ PM_INTEGER_BASE_FLAGS_HEXADECIMAL = 8,
1953
4331
  } pm_integer_base_flags_t;
1954
4332
 
1955
- // LoopFlags
4333
+ /**
4334
+ * Flags for while and until loop nodes.
4335
+ */
1956
4336
  typedef enum pm_loop_flags {
1957
- PM_LOOP_FLAGS_BEGIN_MODIFIER = 1 << 0,
4337
+ /** a loop after a begin statement, so the body is executed first before the condition */
4338
+ PM_LOOP_FLAGS_BEGIN_MODIFIER = 1,
1958
4339
  } pm_loop_flags_t;
1959
4340
 
1960
- // RangeFlags
4341
+ /**
4342
+ * Flags for range and flip-flop nodes.
4343
+ */
1961
4344
  typedef enum pm_range_flags {
1962
- PM_RANGE_FLAGS_EXCLUDE_END = 1 << 0,
4345
+ /** ... operator */
4346
+ PM_RANGE_FLAGS_EXCLUDE_END = 1,
1963
4347
  } pm_range_flags_t;
1964
4348
 
1965
- // RegularExpressionFlags
4349
+ /**
4350
+ * Flags for regular expression and match last line nodes.
4351
+ */
1966
4352
  typedef enum pm_regular_expression_flags {
1967
- PM_REGULAR_EXPRESSION_FLAGS_IGNORE_CASE = 1 << 0,
1968
- PM_REGULAR_EXPRESSION_FLAGS_EXTENDED = 1 << 1,
1969
- PM_REGULAR_EXPRESSION_FLAGS_MULTI_LINE = 1 << 2,
1970
- PM_REGULAR_EXPRESSION_FLAGS_ONCE = 1 << 3,
1971
- PM_REGULAR_EXPRESSION_FLAGS_EUC_JP = 1 << 4,
1972
- PM_REGULAR_EXPRESSION_FLAGS_ASCII_8BIT = 1 << 5,
1973
- PM_REGULAR_EXPRESSION_FLAGS_WINDOWS_31J = 1 << 6,
1974
- PM_REGULAR_EXPRESSION_FLAGS_UTF_8 = 1 << 7,
4353
+ /** i - ignores the case of characters when matching */
4354
+ PM_REGULAR_EXPRESSION_FLAGS_IGNORE_CASE = 1,
4355
+
4356
+ /** x - ignores whitespace and allows comments in regular expressions */
4357
+ PM_REGULAR_EXPRESSION_FLAGS_EXTENDED = 2,
4358
+
4359
+ /** m - allows $ to match the end of lines within strings */
4360
+ PM_REGULAR_EXPRESSION_FLAGS_MULTI_LINE = 4,
4361
+
4362
+ /** o - only interpolates values into the regular expression once */
4363
+ PM_REGULAR_EXPRESSION_FLAGS_ONCE = 8,
4364
+
4365
+ /** e - forces the EUC-JP encoding */
4366
+ PM_REGULAR_EXPRESSION_FLAGS_EUC_JP = 16,
4367
+
4368
+ /** n - forces the ASCII-8BIT encoding */
4369
+ PM_REGULAR_EXPRESSION_FLAGS_ASCII_8BIT = 32,
4370
+
4371
+ /** s - forces the Windows-31J encoding */
4372
+ PM_REGULAR_EXPRESSION_FLAGS_WINDOWS_31J = 64,
4373
+
4374
+ /** u - forces the UTF-8 encoding */
4375
+ PM_REGULAR_EXPRESSION_FLAGS_UTF_8 = 128,
1975
4376
  } pm_regular_expression_flags_t;
1976
4377
 
1977
- // StringFlags
4378
+ /**
4379
+ * Flags for string nodes.
4380
+ */
1978
4381
  typedef enum pm_string_flags {
1979
- PM_STRING_FLAGS_FROZEN = 1 << 0,
4382
+ /** frozen by virtue of a `frozen_string_literal` comment */
4383
+ PM_STRING_FLAGS_FROZEN = 1,
1980
4384
  } pm_string_flags_t;
1981
4385
 
4386
+ /**
4387
+ * When we're serializing to Java, we want to skip serializing the location
4388
+ * fields as they won't be used by JRuby or TruffleRuby. This boolean allows us
4389
+ * to specify that through the environment. It will never be true except for in
4390
+ * those build systems.
4391
+ */
1982
4392
  #define PRISM_SERIALIZE_ONLY_SEMANTICS_FIELDS false
1983
4393
 
1984
- #endif // PRISM_AST_H
4394
+ #endif