Ruby: prism/token_type.c Source File

Ruby 3.3.4p94 (2024-07-09 revision be1089c8ec5ba40e09b1553e36b3174bf4014d9d)

token_type.c
1/******************************************************************************/
2/* This file is generated by the templates/template.rb script and should not */
3/* be modified manually. See */
4/* templates/src/token_type.c.erb */
5/* if you are looking to modify the */
6/* template */
7/******************************************************************************/
8#include <string.h>
9
10#include "prism/ast.h"
11
15 PRISM_EXPORTED_FUNCTION const char *
16pm_token_type_to_str(pm_token_type_t token_type)
17{
18 switch (token_type) {
19 case PM_TOKEN_EOF:
20 return "EOF";
21 case PM_TOKEN_MISSING:
22 return "MISSING";
23 case PM_TOKEN_NOT_PROVIDED:
24 return "NOT_PROVIDED";
25 case PM_TOKEN_AMPERSAND:
26 return "AMPERSAND";
27 case PM_TOKEN_AMPERSAND_AMPERSAND:
28 return "AMPERSAND_AMPERSAND";
29 case PM_TOKEN_AMPERSAND_AMPERSAND_EQUAL:
30 return "AMPERSAND_AMPERSAND_EQUAL";
31 case PM_TOKEN_AMPERSAND_DOT:
32 return "AMPERSAND_DOT";
33 case PM_TOKEN_AMPERSAND_EQUAL:
34 return "AMPERSAND_EQUAL";
35 case PM_TOKEN_BACKTICK:
36 return "BACKTICK";
37 case PM_TOKEN_BACK_REFERENCE:
38 return "BACK_REFERENCE";
39 case PM_TOKEN_BANG:
40 return "BANG";
41 case PM_TOKEN_BANG_EQUAL:
42 return "BANG_EQUAL";
43 case PM_TOKEN_BANG_TILDE:
44 return "BANG_TILDE";
45 case PM_TOKEN_BRACE_LEFT:
46 return "BRACE_LEFT";
47 case PM_TOKEN_BRACE_RIGHT:
48 return "BRACE_RIGHT";
49 case PM_TOKEN_BRACKET_LEFT:
50 return "BRACKET_LEFT";
51 case PM_TOKEN_BRACKET_LEFT_ARRAY:
52 return "BRACKET_LEFT_ARRAY";
53 case PM_TOKEN_BRACKET_LEFT_RIGHT:
54 return "BRACKET_LEFT_RIGHT";
55 case PM_TOKEN_BRACKET_LEFT_RIGHT_EQUAL:
56 return "BRACKET_LEFT_RIGHT_EQUAL";
57 case PM_TOKEN_BRACKET_RIGHT:
58 return "BRACKET_RIGHT";
59 case PM_TOKEN_CARET:
60 return "CARET";
61 case PM_TOKEN_CARET_EQUAL:
62 return "CARET_EQUAL";
63 case PM_TOKEN_CHARACTER_LITERAL:
64 return "CHARACTER_LITERAL";
65 case PM_TOKEN_CLASS_VARIABLE:
66 return "CLASS_VARIABLE";
67 case PM_TOKEN_COLON:
68 return "COLON";
69 case PM_TOKEN_COLON_COLON:
70 return "COLON_COLON";
71 case PM_TOKEN_COMMA:
72 return "COMMA";
73 case PM_TOKEN_COMMENT:
74 return "COMMENT";
75 case PM_TOKEN_CONSTANT:
76 return "CONSTANT";
77 case PM_TOKEN_DOT:
78 return "DOT";
79 case PM_TOKEN_DOT_DOT:
80 return "DOT_DOT";
81 case PM_TOKEN_DOT_DOT_DOT:
82 return "DOT_DOT_DOT";
83 case PM_TOKEN_EMBDOC_BEGIN:
84 return "EMBDOC_BEGIN";
85 case PM_TOKEN_EMBDOC_END:
86 return "EMBDOC_END";
87 case PM_TOKEN_EMBDOC_LINE:
88 return "EMBDOC_LINE";
89 case PM_TOKEN_EMBEXPR_BEGIN:
90 return "EMBEXPR_BEGIN";
91 case PM_TOKEN_EMBEXPR_END:
92 return "EMBEXPR_END";
93 case PM_TOKEN_EMBVAR:
94 return "EMBVAR";
95 case PM_TOKEN_EQUAL:
96 return "EQUAL";
97 case PM_TOKEN_EQUAL_EQUAL:
98 return "EQUAL_EQUAL";
99 case PM_TOKEN_EQUAL_EQUAL_EQUAL:
100 return "EQUAL_EQUAL_EQUAL";
101 case PM_TOKEN_EQUAL_GREATER:
102 return "EQUAL_GREATER";
103 case PM_TOKEN_EQUAL_TILDE:
104 return "EQUAL_TILDE";
105 case PM_TOKEN_FLOAT:
106 return "FLOAT";
107 case PM_TOKEN_FLOAT_IMAGINARY:
108 return "FLOAT_IMAGINARY";
109 case PM_TOKEN_FLOAT_RATIONAL:
110 return "FLOAT_RATIONAL";
111 case PM_TOKEN_FLOAT_RATIONAL_IMAGINARY:
112 return "FLOAT_RATIONAL_IMAGINARY";
113 case PM_TOKEN_GLOBAL_VARIABLE:
114 return "GLOBAL_VARIABLE";
115 case PM_TOKEN_GREATER:
116 return "GREATER";
117 case PM_TOKEN_GREATER_EQUAL:
118 return "GREATER_EQUAL";
119 case PM_TOKEN_GREATER_GREATER:
120 return "GREATER_GREATER";
121 case PM_TOKEN_GREATER_GREATER_EQUAL:
122 return "GREATER_GREATER_EQUAL";
123 case PM_TOKEN_HEREDOC_END:
124 return "HEREDOC_END";
125 case PM_TOKEN_HEREDOC_START:
126 return "HEREDOC_START";
127 case PM_TOKEN_IDENTIFIER:
128 return "IDENTIFIER";
129 case PM_TOKEN_IGNORED_NEWLINE:
130 return "IGNORED_NEWLINE";
131 case PM_TOKEN_INSTANCE_VARIABLE:
132 return "INSTANCE_VARIABLE";
133 case PM_TOKEN_INTEGER:
134 return "INTEGER";
135 case PM_TOKEN_INTEGER_IMAGINARY:
136 return "INTEGER_IMAGINARY";
137 case PM_TOKEN_INTEGER_RATIONAL:
138 return "INTEGER_RATIONAL";
139 case PM_TOKEN_INTEGER_RATIONAL_IMAGINARY:
140 return "INTEGER_RATIONAL_IMAGINARY";
141 case PM_TOKEN_KEYWORD_ALIAS:
142 return "KEYWORD_ALIAS";
143 case PM_TOKEN_KEYWORD_AND:
144 return "KEYWORD_AND";
145 case PM_TOKEN_KEYWORD_BEGIN:
146 return "KEYWORD_BEGIN";
147 case PM_TOKEN_KEYWORD_BEGIN_UPCASE:
148 return "KEYWORD_BEGIN_UPCASE";
149 case PM_TOKEN_KEYWORD_BREAK:
150 return "KEYWORD_BREAK";
151 case PM_TOKEN_KEYWORD_CASE:
152 return "KEYWORD_CASE";
153 case PM_TOKEN_KEYWORD_CLASS:
154 return "KEYWORD_CLASS";
155 case PM_TOKEN_KEYWORD_DEF:
156 return "KEYWORD_DEF";
157 case PM_TOKEN_KEYWORD_DEFINED:
158 return "KEYWORD_DEFINED";
159 case PM_TOKEN_KEYWORD_DO:
160 return "KEYWORD_DO";
161 case PM_TOKEN_KEYWORD_DO_LOOP:
162 return "KEYWORD_DO_LOOP";
163 case PM_TOKEN_KEYWORD_ELSE:
164 return "KEYWORD_ELSE";
165 case PM_TOKEN_KEYWORD_ELSIF:
166 return "KEYWORD_ELSIF";
167 case PM_TOKEN_KEYWORD_END:
168 return "KEYWORD_END";
169 case PM_TOKEN_KEYWORD_END_UPCASE:
170 return "KEYWORD_END_UPCASE";
171 case PM_TOKEN_KEYWORD_ENSURE:
172 return "KEYWORD_ENSURE";
173 case PM_TOKEN_KEYWORD_FALSE:
174 return "KEYWORD_FALSE";
175 case PM_TOKEN_KEYWORD_FOR:
176 return "KEYWORD_FOR";
177 case PM_TOKEN_KEYWORD_IF:
178 return "KEYWORD_IF";
179 case PM_TOKEN_KEYWORD_IF_MODIFIER:
180 return "KEYWORD_IF_MODIFIER";
181 case PM_TOKEN_KEYWORD_IN:
182 return "KEYWORD_IN";
183 case PM_TOKEN_KEYWORD_MODULE:
184 return "KEYWORD_MODULE";
185 case PM_TOKEN_KEYWORD_NEXT:
186 return "KEYWORD_NEXT";
187 case PM_TOKEN_KEYWORD_NIL:
188 return "KEYWORD_NIL";
189 case PM_TOKEN_KEYWORD_NOT:
190 return "KEYWORD_NOT";
191 case PM_TOKEN_KEYWORD_OR:
192 return "KEYWORD_OR";
193 case PM_TOKEN_KEYWORD_REDO:
194 return "KEYWORD_REDO";
195 case PM_TOKEN_KEYWORD_RESCUE:
196 return "KEYWORD_RESCUE";
197 case PM_TOKEN_KEYWORD_RESCUE_MODIFIER:
198 return "KEYWORD_RESCUE_MODIFIER";
199 case PM_TOKEN_KEYWORD_RETRY:
200 return "KEYWORD_RETRY";
201 case PM_TOKEN_KEYWORD_RETURN:
202 return "KEYWORD_RETURN";
203 case PM_TOKEN_KEYWORD_SELF:
204 return "KEYWORD_SELF";
205 case PM_TOKEN_KEYWORD_SUPER:
206 return "KEYWORD_SUPER";
207 case PM_TOKEN_KEYWORD_THEN:
208 return "KEYWORD_THEN";
209 case PM_TOKEN_KEYWORD_TRUE:
210 return "KEYWORD_TRUE";
211 case PM_TOKEN_KEYWORD_UNDEF:
212 return "KEYWORD_UNDEF";
213 case PM_TOKEN_KEYWORD_UNLESS:
214 return "KEYWORD_UNLESS";
215 case PM_TOKEN_KEYWORD_UNLESS_MODIFIER:
216 return "KEYWORD_UNLESS_MODIFIER";
217 case PM_TOKEN_KEYWORD_UNTIL:
218 return "KEYWORD_UNTIL";
219 case PM_TOKEN_KEYWORD_UNTIL_MODIFIER:
220 return "KEYWORD_UNTIL_MODIFIER";
221 case PM_TOKEN_KEYWORD_WHEN:
222 return "KEYWORD_WHEN";
223 case PM_TOKEN_KEYWORD_WHILE:
224 return "KEYWORD_WHILE";
225 case PM_TOKEN_KEYWORD_WHILE_MODIFIER:
226 return "KEYWORD_WHILE_MODIFIER";
227 case PM_TOKEN_KEYWORD_YIELD:
228 return "KEYWORD_YIELD";
229 case PM_TOKEN_KEYWORD___ENCODING__:
230 return "KEYWORD___ENCODING__";
231 case PM_TOKEN_KEYWORD___FILE__:
232 return "KEYWORD___FILE__";
233 case PM_TOKEN_KEYWORD___LINE__:
234 return "KEYWORD___LINE__";
235 case PM_TOKEN_LABEL:
236 return "LABEL";
237 case PM_TOKEN_LABEL_END:
238 return "LABEL_END";
239 case PM_TOKEN_LAMBDA_BEGIN:
240 return "LAMBDA_BEGIN";
241 case PM_TOKEN_LESS:
242 return "LESS";
243 case PM_TOKEN_LESS_EQUAL:
244 return "LESS_EQUAL";
245 case PM_TOKEN_LESS_EQUAL_GREATER:
246 return "LESS_EQUAL_GREATER";
247 case PM_TOKEN_LESS_LESS:
248 return "LESS_LESS";
249 case PM_TOKEN_LESS_LESS_EQUAL:
250 return "LESS_LESS_EQUAL";
251 case PM_TOKEN_METHOD_NAME:
252 return "METHOD_NAME";
253 case PM_TOKEN_MINUS:
254 return "MINUS";
255 case PM_TOKEN_MINUS_EQUAL:
256 return "MINUS_EQUAL";
257 case PM_TOKEN_MINUS_GREATER:
258 return "MINUS_GREATER";
259 case PM_TOKEN_NEWLINE:
260 return "NEWLINE";
261 case PM_TOKEN_NUMBERED_REFERENCE:
262 return "NUMBERED_REFERENCE";
263 case PM_TOKEN_PARENTHESIS_LEFT:
264 return "PARENTHESIS_LEFT";
265 case PM_TOKEN_PARENTHESIS_LEFT_PARENTHESES:
266 return "PARENTHESIS_LEFT_PARENTHESES";
267 case PM_TOKEN_PARENTHESIS_RIGHT:
268 return "PARENTHESIS_RIGHT";
269 case PM_TOKEN_PERCENT:
270 return "PERCENT";
271 case PM_TOKEN_PERCENT_EQUAL:
272 return "PERCENT_EQUAL";
273 case PM_TOKEN_PERCENT_LOWER_I:
274 return "PERCENT_LOWER_I";
275 case PM_TOKEN_PERCENT_LOWER_W:
276 return "PERCENT_LOWER_W";
277 case PM_TOKEN_PERCENT_LOWER_X:
278 return "PERCENT_LOWER_X";
279 case PM_TOKEN_PERCENT_UPPER_I:
280 return "PERCENT_UPPER_I";
281 case PM_TOKEN_PERCENT_UPPER_W:
282 return "PERCENT_UPPER_W";
283 case PM_TOKEN_PIPE:
284 return "PIPE";
285 case PM_TOKEN_PIPE_EQUAL:
286 return "PIPE_EQUAL";
287 case PM_TOKEN_PIPE_PIPE:
288 return "PIPE_PIPE";
289 case PM_TOKEN_PIPE_PIPE_EQUAL:
290 return "PIPE_PIPE_EQUAL";
291 case PM_TOKEN_PLUS:
292 return "PLUS";
293 case PM_TOKEN_PLUS_EQUAL:
294 return "PLUS_EQUAL";
295 case PM_TOKEN_QUESTION_MARK:
296 return "QUESTION_MARK";
297 case PM_TOKEN_REGEXP_BEGIN:
298 return "REGEXP_BEGIN";
299 case PM_TOKEN_REGEXP_END:
300 return "REGEXP_END";
301 case PM_TOKEN_SEMICOLON:
302 return "SEMICOLON";
303 case PM_TOKEN_SLASH:
304 return "SLASH";
305 case PM_TOKEN_SLASH_EQUAL:
306 return "SLASH_EQUAL";
307 case PM_TOKEN_STAR:
308 return "STAR";
309 case PM_TOKEN_STAR_EQUAL:
310 return "STAR_EQUAL";
311 case PM_TOKEN_STAR_STAR:
312 return "STAR_STAR";
313 case PM_TOKEN_STAR_STAR_EQUAL:
314 return "STAR_STAR_EQUAL";
315 case PM_TOKEN_STRING_BEGIN:
316 return "STRING_BEGIN";
317 case PM_TOKEN_STRING_CONTENT:
318 return "STRING_CONTENT";
319 case PM_TOKEN_STRING_END:
320 return "STRING_END";
321 case PM_TOKEN_SYMBOL_BEGIN:
322 return "SYMBOL_BEGIN";
323 case PM_TOKEN_TILDE:
324 return "TILDE";
325 case PM_TOKEN_UAMPERSAND:
326 return "UAMPERSAND";
327 case PM_TOKEN_UCOLON_COLON:
328 return "UCOLON_COLON";
329 case PM_TOKEN_UDOT_DOT:
330 return "UDOT_DOT";
331 case PM_TOKEN_UDOT_DOT_DOT:
332 return "UDOT_DOT_DOT";
333 case PM_TOKEN_UMINUS:
334 return "UMINUS";
335 case PM_TOKEN_UMINUS_NUM:
336 return "UMINUS_NUM";
337 case PM_TOKEN_UPLUS:
338 return "UPLUS";
339 case PM_TOKEN_USTAR:
340 return "USTAR";
341 case PM_TOKEN_USTAR_STAR:
342 return "USTAR_STAR";
343 case PM_TOKEN_WORDS_SEP:
344 return "WORDS_SEP";
345 case PM_TOKEN___END__:
346 return "__END__";
347 case PM_TOKEN_MAXIMUM:
348 return "MAXIMUM";
349 }
350 return "\0";
351}
ast.h
The abstract syntax tree.
pm_token_type_t
enum pm_token_type pm_token_type_t
This enum represents every type of token in the Ruby source.
PM_TOKEN_STAR_STAR
@ PM_TOKEN_STAR_STAR
**
Definition ast.h:467
PM_TOKEN_DOT_DOT_DOT
@ PM_TOKEN_DOT_DOT_DOT
the ... range operator or forwarding parameter
Definition ast.h:122
PM_TOKEN_MINUS_EQUAL
@ PM_TOKEN_MINUS_EQUAL
-=
Definition ast.h:383
PM_TOKEN_IGNORED_NEWLINE
@ PM_TOKEN_IGNORED_NEWLINE
an ignored newline
Definition ast.h:194
PM_TOKEN_BANG_EQUAL
@ PM_TOKEN_BANG_EQUAL
!=
Definition ast.h:62
PM_TOKEN_KEYWORD___FILE__
@ PM_TOKEN_KEYWORD___FILE__
FILE
Definition ast.h:347
PM_TOKEN_KEYWORD_WHEN
@ PM_TOKEN_KEYWORD_WHEN
when
Definition ast.h:332
PM_TOKEN_FLOAT
@ PM_TOKEN_FLOAT
a floating point number
Definition ast.h:158
PM_TOKEN_PLUS_EQUAL
@ PM_TOKEN_PLUS_EQUAL
+=
Definition ast.h:440
PM_TOKEN_DOT_DOT
@ PM_TOKEN_DOT_DOT
the .
Definition ast.h:119
PM_TOKEN_UDOT_DOT
@ PM_TOKEN_UDOT_DOT
unary .
Definition ast.h:494
PM_TOKEN_AMPERSAND_DOT
@ PM_TOKEN_AMPERSAND_DOT
&.
Definition ast.h:47
PM_TOKEN_NEWLINE
@ PM_TOKEN_NEWLINE
a newline character outside of other tokens
Definition ast.h:389
PM_TOKEN_NUMBERED_REFERENCE
@ PM_TOKEN_NUMBERED_REFERENCE
a numbered reference to a capture group in the previous regular expression match
Definition ast.h:392
PM_TOKEN_AMPERSAND
@ PM_TOKEN_AMPERSAND
&
Definition ast.h:38
PM_TOKEN_KEYWORD_YIELD
@ PM_TOKEN_KEYWORD_YIELD
yield
Definition ast.h:341
PM_TOKEN_KEYWORD_END
@ PM_TOKEN_KEYWORD_END
end
Definition ast.h:251
PM_TOKEN_LAMBDA_BEGIN
@ PM_TOKEN_LAMBDA_BEGIN
{
Definition ast.h:359
PM_TOKEN_KEYWORD_UNTIL_MODIFIER
@ PM_TOKEN_KEYWORD_UNTIL_MODIFIER
until in the modifier form
Definition ast.h:329
PM_TOKEN_EQUAL_EQUAL_EQUAL
@ PM_TOKEN_EQUAL_EQUAL_EQUAL
===
Definition ast.h:149
PM_TOKEN_INTEGER_RATIONAL
@ PM_TOKEN_INTEGER_RATIONAL
an integer with a rational suffix
Definition ast.h:206
PM_TOKEN_USTAR
@ PM_TOKEN_USTAR
unary *
Definition ast.h:509
PM_TOKEN_TILDE
@ PM_TOKEN_TILDE
~ or ~@
Definition ast.h:485
PM_TOKEN_KEYWORD___ENCODING__
@ PM_TOKEN_KEYWORD___ENCODING__
ENCODING
Definition ast.h:344
PM_TOKEN_REGEXP_END
@ PM_TOKEN_REGEXP_END
the end of a regular expression
Definition ast.h:449
PM_TOKEN_KEYWORD_UNTIL
@ PM_TOKEN_KEYWORD_UNTIL
until
Definition ast.h:326
PM_TOKEN_COMMA
@ PM_TOKEN_COMMA
,
Definition ast.h:107
PM_TOKEN_MAXIMUM
@ PM_TOKEN_MAXIMUM
The maximum token value.
Definition ast.h:521
PM_TOKEN_GREATER
@ PM_TOKEN_GREATER
‍
Definition ast.h:173
PM_TOKEN_INTEGER
@ PM_TOKEN_INTEGER
an integer (any base)
Definition ast.h:200
PM_TOKEN_SLASH_EQUAL
@ PM_TOKEN_SLASH_EQUAL
/=
Definition ast.h:458
PM_TOKEN_UMINUS_NUM
@ PM_TOKEN_UMINUS_NUM
-@ for a number
Definition ast.h:503
PM_TOKEN_EMBVAR
@ PM_TOKEN_EMBVAR
Definition ast.h:140
PM_TOKEN_KEYWORD_UNLESS_MODIFIER
@ PM_TOKEN_KEYWORD_UNLESS_MODIFIER
unless in the modifier form
Definition ast.h:323
PM_TOKEN_INTEGER_RATIONAL_IMAGINARY
@ PM_TOKEN_INTEGER_RATIONAL_IMAGINARY
an integer with a rational and imaginary suffix
Definition ast.h:209
PM_TOKEN_FLOAT_RATIONAL_IMAGINARY
@ PM_TOKEN_FLOAT_RATIONAL_IMAGINARY
a floating pointer number with a rational and imaginary suffix
Definition ast.h:167
PM_TOKEN_BRACKET_LEFT_RIGHT
@ PM_TOKEN_BRACKET_LEFT_RIGHT
[]
Definition ast.h:80
PM_TOKEN_AMPERSAND_AMPERSAND_EQUAL
@ PM_TOKEN_AMPERSAND_AMPERSAND_EQUAL
&&=
Definition ast.h:44
PM_TOKEN_KEYWORD_CLASS
@ PM_TOKEN_KEYWORD_CLASS
class
Definition ast.h:230
PM_TOKEN_KEYWORD_BEGIN
@ PM_TOKEN_KEYWORD_BEGIN
begin
Definition ast.h:218
PM_TOKEN_NOT_PROVIDED
@ PM_TOKEN_NOT_PROVIDED
a token that was not present but it is okay
Definition ast.h:35
PM_TOKEN_USTAR_STAR
@ PM_TOKEN_USTAR_STAR
unary **
Definition ast.h:512
PM_TOKEN_GREATER_GREATER_EQUAL
@ PM_TOKEN_GREATER_GREATER_EQUAL
‍>=
Definition ast.h:182
PM_TOKEN_PERCENT_EQUAL
@ PM_TOKEN_PERCENT_EQUAL
%=
Definition ast.h:407
PM_TOKEN_PERCENT
@ PM_TOKEN_PERCENT
%
Definition ast.h:404
PM_TOKEN_KEYWORD_IN
@ PM_TOKEN_KEYWORD_IN
in
Definition ast.h:272
PM_TOKEN_BANG
@ PM_TOKEN_BANG
! or !@
Definition ast.h:59
PM_TOKEN_KEYWORD_NOT
@ PM_TOKEN_KEYWORD_NOT
not
Definition ast.h:284
PM_TOKEN_BRACKET_LEFT_ARRAY
@ PM_TOKEN_BRACKET_LEFT_ARRAY
[ for the beginning of an array
Definition ast.h:77
PM_TOKEN_HEREDOC_END
@ PM_TOKEN_HEREDOC_END
the end of a heredoc
Definition ast.h:185
PM_TOKEN_HEREDOC_START
@ PM_TOKEN_HEREDOC_START
the start of a heredoc
Definition ast.h:188
PM_TOKEN_KEYWORD_DEFINED
@ PM_TOKEN_KEYWORD_DEFINED
defined?
Definition ast.h:236
PM_TOKEN_UCOLON_COLON
@ PM_TOKEN_UCOLON_COLON
unary ::
Definition ast.h:491
PM_TOKEN_LABEL_END
@ PM_TOKEN_LABEL_END
the end of a label
Definition ast.h:356
PM_TOKEN_EQUAL_GREATER
@ PM_TOKEN_EQUAL_GREATER
=>
Definition ast.h:152
PM_TOKEN_KEYWORD_UNLESS
@ PM_TOKEN_KEYWORD_UNLESS
unless
Definition ast.h:320
PM_TOKEN_KEYWORD_ENSURE
@ PM_TOKEN_KEYWORD_ENSURE
ensure
Definition ast.h:257
PM_TOKEN_AMPERSAND_EQUAL
@ PM_TOKEN_AMPERSAND_EQUAL
&=
Definition ast.h:50
PM_TOKEN_EQUAL_EQUAL
@ PM_TOKEN_EQUAL_EQUAL
==
Definition ast.h:146
PM_TOKEN_UPLUS
@ PM_TOKEN_UPLUS
+@
Definition ast.h:506
PM_TOKEN_FLOAT_IMAGINARY
@ PM_TOKEN_FLOAT_IMAGINARY
a floating pointer number with an imaginary suffix
Definition ast.h:161
PM_TOKEN_KEYWORD_BEGIN_UPCASE
@ PM_TOKEN_KEYWORD_BEGIN_UPCASE
BEGIN.
Definition ast.h:221
PM_TOKEN_LESS_EQUAL_GREATER
@ PM_TOKEN_LESS_EQUAL_GREATER
<=>
Definition ast.h:368
PM_TOKEN_KEYWORD_RESCUE_MODIFIER
@ PM_TOKEN_KEYWORD_RESCUE_MODIFIER
rescue in the modifier form
Definition ast.h:296
PM_TOKEN_MISSING
@ PM_TOKEN_MISSING
a token that was expected but not found
Definition ast.h:32
PM_TOKEN_MINUS_GREATER
@ PM_TOKEN_MINUS_GREATER
->
Definition ast.h:386
PM_TOKEN_KEYWORD_FALSE
@ PM_TOKEN_KEYWORD_FALSE
false
Definition ast.h:260
PM_TOKEN_PIPE_PIPE_EQUAL
@ PM_TOKEN_PIPE_PIPE_EQUAL
||=
Definition ast.h:434
PM_TOKEN_KEYWORD_IF
@ PM_TOKEN_KEYWORD_IF
if
Definition ast.h:266
PM_TOKEN_EMBEXPR_BEGIN
@ PM_TOKEN_EMBEXPR_BEGIN
#{
Definition ast.h:134
PM_TOKEN_PARENTHESIS_LEFT_PARENTHESES
@ PM_TOKEN_PARENTHESIS_LEFT_PARENTHESES
( for a parentheses node
Definition ast.h:398
PM_TOKEN_EMBDOC_END
@ PM_TOKEN_EMBDOC_END
=end
Definition ast.h:128
PM_TOKEN_KEYWORD_ELSE
@ PM_TOKEN_KEYWORD_ELSE
else
Definition ast.h:245
PM_TOKEN_BACK_REFERENCE
@ PM_TOKEN_BACK_REFERENCE
a back reference
Definition ast.h:56
PM_TOKEN_BRACKET_LEFT
@ PM_TOKEN_BRACKET_LEFT
[
Definition ast.h:74
PM_TOKEN_EOF
@ PM_TOKEN_EOF
final token in the file
Definition ast.h:29
PM_TOKEN_PIPE_PIPE
@ PM_TOKEN_PIPE_PIPE
||
Definition ast.h:431
PM_TOKEN_KEYWORD_NIL
@ PM_TOKEN_KEYWORD_NIL
nil
Definition ast.h:281
PM_TOKEN_PERCENT_UPPER_W
@ PM_TOKEN_PERCENT_UPPER_W
W
Definition ast.h:422
PM_TOKEN_KEYWORD_RETURN
@ PM_TOKEN_KEYWORD_RETURN
return
Definition ast.h:302
PM_TOKEN_CLASS_VARIABLE
@ PM_TOKEN_CLASS_VARIABLE
a class variable
Definition ast.h:98
PM_TOKEN_PIPE
@ PM_TOKEN_PIPE
|
Definition ast.h:425
PM_TOKEN_PARENTHESIS_LEFT
@ PM_TOKEN_PARENTHESIS_LEFT
(
Definition ast.h:395
PM_TOKEN_BANG_TILDE
@ PM_TOKEN_BANG_TILDE
!~
Definition ast.h:65
PM_TOKEN_DOT
@ PM_TOKEN_DOT
the .
Definition ast.h:116
PM_TOKEN_PARENTHESIS_RIGHT
@ PM_TOKEN_PARENTHESIS_RIGHT
)
Definition ast.h:401
PM_TOKEN_KEYWORD_RESCUE
@ PM_TOKEN_KEYWORD_RESCUE
rescue
Definition ast.h:293
PM_TOKEN_INSTANCE_VARIABLE
@ PM_TOKEN_INSTANCE_VARIABLE
an instance variable
Definition ast.h:197
PM_TOKEN_PIPE_EQUAL
@ PM_TOKEN_PIPE_EQUAL
|=
Definition ast.h:428
PM_TOKEN_BRACKET_LEFT_RIGHT_EQUAL
@ PM_TOKEN_BRACKET_LEFT_RIGHT_EQUAL
[]=
Definition ast.h:83
PM_TOKEN_UAMPERSAND
@ PM_TOKEN_UAMPERSAND
unary &
Definition ast.h:488
PM_TOKEN_MINUS
@ PM_TOKEN_MINUS
Definition ast.h:380
PM_TOKEN_CONSTANT
@ PM_TOKEN_CONSTANT
a constant
Definition ast.h:113
PM_TOKEN_IDENTIFIER
@ PM_TOKEN_IDENTIFIER
an identifier
Definition ast.h:191
PM_TOKEN_EMBDOC_BEGIN
@ PM_TOKEN_EMBDOC_BEGIN
=begin
Definition ast.h:125
PM_TOKEN_STAR_EQUAL
@ PM_TOKEN_STAR_EQUAL
*=
Definition ast.h:464
PM_TOKEN_KEYWORD_OR
@ PM_TOKEN_KEYWORD_OR
or
Definition ast.h:287
PM_TOKEN_KEYWORD_AND
@ PM_TOKEN_KEYWORD_AND
and
Definition ast.h:215
PM_TOKEN_LESS
@ PM_TOKEN_LESS
<
Definition ast.h:362
PM_TOKEN_KEYWORD_BREAK
@ PM_TOKEN_KEYWORD_BREAK
break
Definition ast.h:224
PM_TOKEN_PERCENT_LOWER_W
@ PM_TOKEN_PERCENT_LOWER_W
w
Definition ast.h:413
PM_TOKEN_SYMBOL_BEGIN
@ PM_TOKEN_SYMBOL_BEGIN
the beginning of a symbol
Definition ast.h:482
PM_TOKEN_METHOD_NAME
@ PM_TOKEN_METHOD_NAME
a method name
Definition ast.h:377
PM_TOKEN_KEYWORD_CASE
@ PM_TOKEN_KEYWORD_CASE
case
Definition ast.h:227
PM_TOKEN_WORDS_SEP
@ PM_TOKEN_WORDS_SEP
a separator between words in a list
Definition ast.h:515
PM_TOKEN_FLOAT_RATIONAL
@ PM_TOKEN_FLOAT_RATIONAL
a floating pointer number with a rational suffix
Definition ast.h:164
PM_TOKEN_LESS_LESS_EQUAL
@ PM_TOKEN_LESS_LESS_EQUAL
<<=
Definition ast.h:374
PM_TOKEN_EMBDOC_LINE
@ PM_TOKEN_EMBDOC_LINE
a line inside of embedded documentation
Definition ast.h:131
PM_TOKEN_KEYWORD_SUPER
@ PM_TOKEN_KEYWORD_SUPER
super
Definition ast.h:308
PM_TOKEN_KEYWORD_DO
@ PM_TOKEN_KEYWORD_DO
do
Definition ast.h:239
PM_TOKEN_KEYWORD_REDO
@ PM_TOKEN_KEYWORD_REDO
redo
Definition ast.h:290
PM_TOKEN_EQUAL_TILDE
@ PM_TOKEN_EQUAL_TILDE
=~
Definition ast.h:155
PM_TOKEN_EMBEXPR_END
@ PM_TOKEN_EMBEXPR_END
}
Definition ast.h:137
PM_TOKEN_KEYWORD_END_UPCASE
@ PM_TOKEN_KEYWORD_END_UPCASE
END.
Definition ast.h:254
PM_TOKEN_KEYWORD___LINE__
@ PM_TOKEN_KEYWORD___LINE__
LINE
Definition ast.h:350
PM_TOKEN_STRING_END
@ PM_TOKEN_STRING_END
the end of a string
Definition ast.h:479
PM_TOKEN_STRING_CONTENT
@ PM_TOKEN_STRING_CONTENT
the contents of a string
Definition ast.h:476
PM_TOKEN_BRACE_LEFT
@ PM_TOKEN_BRACE_LEFT
{
Definition ast.h:68
PM_TOKEN_COLON_COLON
@ PM_TOKEN_COLON_COLON
::
Definition ast.h:104
PM_TOKEN_GREATER_GREATER
@ PM_TOKEN_GREATER_GREATER
‍
Definition ast.h:179
PM_TOKEN_PERCENT_LOWER_X
@ PM_TOKEN_PERCENT_LOWER_X
x
Definition ast.h:416
PM_TOKEN_KEYWORD_SELF
@ PM_TOKEN_KEYWORD_SELF
self
Definition ast.h:305
PM_TOKEN_PERCENT_LOWER_I
@ PM_TOKEN_PERCENT_LOWER_I
i
Definition ast.h:410
PM_TOKEN_KEYWORD_ALIAS
@ PM_TOKEN_KEYWORD_ALIAS
alias
Definition ast.h:212
PM_TOKEN_GLOBAL_VARIABLE
@ PM_TOKEN_GLOBAL_VARIABLE
a global variable
Definition ast.h:170
PM_TOKEN_KEYWORD_IF_MODIFIER
@ PM_TOKEN_KEYWORD_IF_MODIFIER
if in the modifier form
Definition ast.h:269
PM_TOKEN_SLASH
@ PM_TOKEN_SLASH
/
Definition ast.h:455
PM_TOKEN_KEYWORD_RETRY
@ PM_TOKEN_KEYWORD_RETRY
retry
Definition ast.h:299
PM_TOKEN_COLON
@ PM_TOKEN_COLON
:
Definition ast.h:101
PM_TOKEN_KEYWORD_UNDEF
@ PM_TOKEN_KEYWORD_UNDEF
undef
Definition ast.h:317
PM_TOKEN_BRACKET_RIGHT
@ PM_TOKEN_BRACKET_RIGHT
]
Definition ast.h:86
PM_TOKEN_KEYWORD_FOR
@ PM_TOKEN_KEYWORD_FOR
for
Definition ast.h:263
PM_TOKEN_KEYWORD_THEN
@ PM_TOKEN_KEYWORD_THEN
then
Definition ast.h:311
PM_TOKEN_QUESTION_MARK
@ PM_TOKEN_QUESTION_MARK
?
Definition ast.h:443
PM_TOKEN___END__
@ PM_TOKEN___END__
marker for the point in the file at which the parser should stop
Definition ast.h:518
PM_TOKEN_KEYWORD_WHILE
@ PM_TOKEN_KEYWORD_WHILE
while
Definition ast.h:335
PM_TOKEN_EQUAL
@ PM_TOKEN_EQUAL
=
Definition ast.h:143
PM_TOKEN_KEYWORD_DEF
@ PM_TOKEN_KEYWORD_DEF
def
Definition ast.h:233
PM_TOKEN_UDOT_DOT_DOT
@ PM_TOKEN_UDOT_DOT_DOT
unary ... operator
Definition ast.h:497
PM_TOKEN_STAR
@ PM_TOKEN_STAR
Definition ast.h:461
PM_TOKEN_KEYWORD_WHILE_MODIFIER
@ PM_TOKEN_KEYWORD_WHILE_MODIFIER
while in the modifier form
Definition ast.h:338
PM_TOKEN_KEYWORD_TRUE
@ PM_TOKEN_KEYWORD_TRUE
true
Definition ast.h:314
PM_TOKEN_BRACE_RIGHT
@ PM_TOKEN_BRACE_RIGHT
}
Definition ast.h:71
PM_TOKEN_SEMICOLON
@ PM_TOKEN_SEMICOLON
;
Definition ast.h:452
PM_TOKEN_REGEXP_BEGIN
@ PM_TOKEN_REGEXP_BEGIN
the beginning of a regular expression
Definition ast.h:446
PM_TOKEN_CARET
@ PM_TOKEN_CARET
^
Definition ast.h:89
PM_TOKEN_PERCENT_UPPER_I
@ PM_TOKEN_PERCENT_UPPER_I
I
Definition ast.h:419
PM_TOKEN_KEYWORD_DO_LOOP
@ PM_TOKEN_KEYWORD_DO_LOOP
do keyword for a predicate in a while, until, or for loop
Definition ast.h:242
PM_TOKEN_KEYWORD_MODULE
@ PM_TOKEN_KEYWORD_MODULE
module
Definition ast.h:275
PM_TOKEN_PLUS
@ PM_TOKEN_PLUS
Definition ast.h:437
PM_TOKEN_KEYWORD_NEXT
@ PM_TOKEN_KEYWORD_NEXT
next
Definition ast.h:278
PM_TOKEN_BACKTICK
@ PM_TOKEN_BACKTICK
`
Definition ast.h:53
PM_TOKEN_INTEGER_IMAGINARY
@ PM_TOKEN_INTEGER_IMAGINARY
an integer with an imaginary suffix
Definition ast.h:203
PM_TOKEN_LABEL
@ PM_TOKEN_LABEL
a label
Definition ast.h:353
PM_TOKEN_STAR_STAR_EQUAL
@ PM_TOKEN_STAR_STAR_EQUAL
**=
Definition ast.h:470
PM_TOKEN_CHARACTER_LITERAL
@ PM_TOKEN_CHARACTER_LITERAL
a character literal
Definition ast.h:95
PM_TOKEN_AMPERSAND_AMPERSAND
@ PM_TOKEN_AMPERSAND_AMPERSAND
&&
Definition ast.h:41
PM_TOKEN_UMINUS
@ PM_TOKEN_UMINUS
-@
Definition ast.h:500
PM_TOKEN_LESS_LESS
@ PM_TOKEN_LESS_LESS
<<
Definition ast.h:371
PM_TOKEN_GREATER_EQUAL
@ PM_TOKEN_GREATER_EQUAL
>=
Definition ast.h:176
PM_TOKEN_COMMENT
@ PM_TOKEN_COMMENT
a comment
Definition ast.h:110
PM_TOKEN_CARET_EQUAL
@ PM_TOKEN_CARET_EQUAL
^=
Definition ast.h:92
PM_TOKEN_KEYWORD_ELSIF
@ PM_TOKEN_KEYWORD_ELSIF
elsif
Definition ast.h:248
PM_TOKEN_STRING_BEGIN
@ PM_TOKEN_STRING_BEGIN
the beginning of a string
Definition ast.h:473
PM_TOKEN_LESS_EQUAL
@ PM_TOKEN_LESS_EQUAL
<=
Definition ast.h:365
PRISM_EXPORTED_FUNCTION
#define PRISM_EXPORTED_FUNCTION
By default, we compile with -fvisibility=hidden.
Definition defines.h:32
pm_token_type_to_str
PRISM_EXPORTED_FUNCTION const char * pm_token_type_to_str(pm_token_type_t token_type)
Returns a string representation of the given token type.
Definition token_type.c:16