Prism Ruby parser
Loading...
Searching...
No Matches
ast.hpp
Go to the documentation of this file.
1/*----------------------------------------------------------------------------*/
2/* This file is generated by the templates/template.rb script and should not */
3/* be modified manually. See */
4/* templates/include/prism/ast.hpp.erb */
5/* if you are looking to modify the */
6/* template */
7/*----------------------------------------------------------------------------*/
8
15#ifndef PRISM_AST_HPP
16#define PRISM_AST_HPP
17
18#include "prism/compiler/cplusplus.hpp"
19
20#include "prism/ast.h"
21#include "prism/node_type.hpp"
22
23#include <cstddef>
24#include <type_traits>
25
26namespace prism {
27
28/* Each node struct is cast to and from pm_node_t, which C++ allows only
29 * because the struct is standard-layout with pm_node_t as its first member. */
30
32template <> struct node_type<pm_alias_global_variable_node_t> : std::integral_constant<pm_node_type_t, PM_ALIAS_GLOBAL_VARIABLE_NODE> {};
33static_assert(std::is_standard_layout_v<pm_alias_global_variable_node_t> && offsetof(pm_alias_global_variable_node_t, base) == 0, "pm_alias_global_variable_node_t must begin with its pm_node_t");
34
36template <> struct node_type<pm_alias_method_node_t> : std::integral_constant<pm_node_type_t, PM_ALIAS_METHOD_NODE> {};
37static_assert(std::is_standard_layout_v<pm_alias_method_node_t> && offsetof(pm_alias_method_node_t, base) == 0, "pm_alias_method_node_t must begin with its pm_node_t");
38
40template <> struct node_type<pm_alternation_pattern_node_t> : std::integral_constant<pm_node_type_t, PM_ALTERNATION_PATTERN_NODE> {};
41static_assert(std::is_standard_layout_v<pm_alternation_pattern_node_t> && offsetof(pm_alternation_pattern_node_t, base) == 0, "pm_alternation_pattern_node_t must begin with its pm_node_t");
42
44template <> struct node_type<pm_and_node_t> : std::integral_constant<pm_node_type_t, PM_AND_NODE> {};
45static_assert(std::is_standard_layout_v<pm_and_node_t> && offsetof(pm_and_node_t, base) == 0, "pm_and_node_t must begin with its pm_node_t");
46
48template <> struct node_type<pm_arguments_node_t> : std::integral_constant<pm_node_type_t, PM_ARGUMENTS_NODE> {};
49static_assert(std::is_standard_layout_v<pm_arguments_node_t> && offsetof(pm_arguments_node_t, base) == 0, "pm_arguments_node_t must begin with its pm_node_t");
50
52template <> struct node_type<pm_array_node_t> : std::integral_constant<pm_node_type_t, PM_ARRAY_NODE> {};
53static_assert(std::is_standard_layout_v<pm_array_node_t> && offsetof(pm_array_node_t, base) == 0, "pm_array_node_t must begin with its pm_node_t");
54
56template <> struct node_type<pm_array_pattern_node_t> : std::integral_constant<pm_node_type_t, PM_ARRAY_PATTERN_NODE> {};
57static_assert(std::is_standard_layout_v<pm_array_pattern_node_t> && offsetof(pm_array_pattern_node_t, base) == 0, "pm_array_pattern_node_t must begin with its pm_node_t");
58
60template <> struct node_type<pm_assoc_node_t> : std::integral_constant<pm_node_type_t, PM_ASSOC_NODE> {};
61static_assert(std::is_standard_layout_v<pm_assoc_node_t> && offsetof(pm_assoc_node_t, base) == 0, "pm_assoc_node_t must begin with its pm_node_t");
62
64template <> struct node_type<pm_assoc_splat_node_t> : std::integral_constant<pm_node_type_t, PM_ASSOC_SPLAT_NODE> {};
65static_assert(std::is_standard_layout_v<pm_assoc_splat_node_t> && offsetof(pm_assoc_splat_node_t, base) == 0, "pm_assoc_splat_node_t must begin with its pm_node_t");
66
68template <> struct node_type<pm_back_reference_read_node_t> : std::integral_constant<pm_node_type_t, PM_BACK_REFERENCE_READ_NODE> {};
69static_assert(std::is_standard_layout_v<pm_back_reference_read_node_t> && offsetof(pm_back_reference_read_node_t, base) == 0, "pm_back_reference_read_node_t must begin with its pm_node_t");
70
72template <> struct node_type<pm_begin_node_t> : std::integral_constant<pm_node_type_t, PM_BEGIN_NODE> {};
73static_assert(std::is_standard_layout_v<pm_begin_node_t> && offsetof(pm_begin_node_t, base) == 0, "pm_begin_node_t must begin with its pm_node_t");
74
76template <> struct node_type<pm_block_argument_node_t> : std::integral_constant<pm_node_type_t, PM_BLOCK_ARGUMENT_NODE> {};
77static_assert(std::is_standard_layout_v<pm_block_argument_node_t> && offsetof(pm_block_argument_node_t, base) == 0, "pm_block_argument_node_t must begin with its pm_node_t");
78
80template <> struct node_type<pm_block_local_variable_node_t> : std::integral_constant<pm_node_type_t, PM_BLOCK_LOCAL_VARIABLE_NODE> {};
81static_assert(std::is_standard_layout_v<pm_block_local_variable_node_t> && offsetof(pm_block_local_variable_node_t, base) == 0, "pm_block_local_variable_node_t must begin with its pm_node_t");
82
84template <> struct node_type<pm_block_node_t> : std::integral_constant<pm_node_type_t, PM_BLOCK_NODE> {};
85static_assert(std::is_standard_layout_v<pm_block_node_t> && offsetof(pm_block_node_t, base) == 0, "pm_block_node_t must begin with its pm_node_t");
86
88template <> struct node_type<pm_block_parameter_node_t> : std::integral_constant<pm_node_type_t, PM_BLOCK_PARAMETER_NODE> {};
89static_assert(std::is_standard_layout_v<pm_block_parameter_node_t> && offsetof(pm_block_parameter_node_t, base) == 0, "pm_block_parameter_node_t must begin with its pm_node_t");
90
92template <> struct node_type<pm_block_parameters_node_t> : std::integral_constant<pm_node_type_t, PM_BLOCK_PARAMETERS_NODE> {};
93static_assert(std::is_standard_layout_v<pm_block_parameters_node_t> && offsetof(pm_block_parameters_node_t, base) == 0, "pm_block_parameters_node_t must begin with its pm_node_t");
94
96template <> struct node_type<pm_break_node_t> : std::integral_constant<pm_node_type_t, PM_BREAK_NODE> {};
97static_assert(std::is_standard_layout_v<pm_break_node_t> && offsetof(pm_break_node_t, base) == 0, "pm_break_node_t must begin with its pm_node_t");
98
100template <> struct node_type<pm_call_and_write_node_t> : std::integral_constant<pm_node_type_t, PM_CALL_AND_WRITE_NODE> {};
101static_assert(std::is_standard_layout_v<pm_call_and_write_node_t> && offsetof(pm_call_and_write_node_t, base) == 0, "pm_call_and_write_node_t must begin with its pm_node_t");
102
104template <> struct node_type<pm_call_node_t> : std::integral_constant<pm_node_type_t, PM_CALL_NODE> {};
105static_assert(std::is_standard_layout_v<pm_call_node_t> && offsetof(pm_call_node_t, base) == 0, "pm_call_node_t must begin with its pm_node_t");
106
108template <> struct node_type<pm_call_operator_write_node_t> : std::integral_constant<pm_node_type_t, PM_CALL_OPERATOR_WRITE_NODE> {};
109static_assert(std::is_standard_layout_v<pm_call_operator_write_node_t> && offsetof(pm_call_operator_write_node_t, base) == 0, "pm_call_operator_write_node_t must begin with its pm_node_t");
110
112template <> struct node_type<pm_call_or_write_node_t> : std::integral_constant<pm_node_type_t, PM_CALL_OR_WRITE_NODE> {};
113static_assert(std::is_standard_layout_v<pm_call_or_write_node_t> && offsetof(pm_call_or_write_node_t, base) == 0, "pm_call_or_write_node_t must begin with its pm_node_t");
114
116template <> struct node_type<pm_call_target_node_t> : std::integral_constant<pm_node_type_t, PM_CALL_TARGET_NODE> {};
117static_assert(std::is_standard_layout_v<pm_call_target_node_t> && offsetof(pm_call_target_node_t, base) == 0, "pm_call_target_node_t must begin with its pm_node_t");
118
120template <> struct node_type<pm_capture_pattern_node_t> : std::integral_constant<pm_node_type_t, PM_CAPTURE_PATTERN_NODE> {};
121static_assert(std::is_standard_layout_v<pm_capture_pattern_node_t> && offsetof(pm_capture_pattern_node_t, base) == 0, "pm_capture_pattern_node_t must begin with its pm_node_t");
122
124template <> struct node_type<pm_case_match_node_t> : std::integral_constant<pm_node_type_t, PM_CASE_MATCH_NODE> {};
125static_assert(std::is_standard_layout_v<pm_case_match_node_t> && offsetof(pm_case_match_node_t, base) == 0, "pm_case_match_node_t must begin with its pm_node_t");
126
128template <> struct node_type<pm_case_node_t> : std::integral_constant<pm_node_type_t, PM_CASE_NODE> {};
129static_assert(std::is_standard_layout_v<pm_case_node_t> && offsetof(pm_case_node_t, base) == 0, "pm_case_node_t must begin with its pm_node_t");
130
132template <> struct node_type<pm_class_node_t> : std::integral_constant<pm_node_type_t, PM_CLASS_NODE> {};
133static_assert(std::is_standard_layout_v<pm_class_node_t> && offsetof(pm_class_node_t, base) == 0, "pm_class_node_t must begin with its pm_node_t");
134
136template <> struct node_type<pm_class_variable_and_write_node_t> : std::integral_constant<pm_node_type_t, PM_CLASS_VARIABLE_AND_WRITE_NODE> {};
137static_assert(std::is_standard_layout_v<pm_class_variable_and_write_node_t> && offsetof(pm_class_variable_and_write_node_t, base) == 0, "pm_class_variable_and_write_node_t must begin with its pm_node_t");
138
140template <> struct node_type<pm_class_variable_operator_write_node_t> : std::integral_constant<pm_node_type_t, PM_CLASS_VARIABLE_OPERATOR_WRITE_NODE> {};
141static_assert(std::is_standard_layout_v<pm_class_variable_operator_write_node_t> && offsetof(pm_class_variable_operator_write_node_t, base) == 0, "pm_class_variable_operator_write_node_t must begin with its pm_node_t");
142
144template <> struct node_type<pm_class_variable_or_write_node_t> : std::integral_constant<pm_node_type_t, PM_CLASS_VARIABLE_OR_WRITE_NODE> {};
145static_assert(std::is_standard_layout_v<pm_class_variable_or_write_node_t> && offsetof(pm_class_variable_or_write_node_t, base) == 0, "pm_class_variable_or_write_node_t must begin with its pm_node_t");
146
148template <> struct node_type<pm_class_variable_read_node_t> : std::integral_constant<pm_node_type_t, PM_CLASS_VARIABLE_READ_NODE> {};
149static_assert(std::is_standard_layout_v<pm_class_variable_read_node_t> && offsetof(pm_class_variable_read_node_t, base) == 0, "pm_class_variable_read_node_t must begin with its pm_node_t");
150
152template <> struct node_type<pm_class_variable_target_node_t> : std::integral_constant<pm_node_type_t, PM_CLASS_VARIABLE_TARGET_NODE> {};
153static_assert(std::is_standard_layout_v<pm_class_variable_target_node_t> && offsetof(pm_class_variable_target_node_t, base) == 0, "pm_class_variable_target_node_t must begin with its pm_node_t");
154
156template <> struct node_type<pm_class_variable_write_node_t> : std::integral_constant<pm_node_type_t, PM_CLASS_VARIABLE_WRITE_NODE> {};
157static_assert(std::is_standard_layout_v<pm_class_variable_write_node_t> && offsetof(pm_class_variable_write_node_t, base) == 0, "pm_class_variable_write_node_t must begin with its pm_node_t");
158
160template <> struct node_type<pm_constant_and_write_node_t> : std::integral_constant<pm_node_type_t, PM_CONSTANT_AND_WRITE_NODE> {};
161static_assert(std::is_standard_layout_v<pm_constant_and_write_node_t> && offsetof(pm_constant_and_write_node_t, base) == 0, "pm_constant_and_write_node_t must begin with its pm_node_t");
162
164template <> struct node_type<pm_constant_operator_write_node_t> : std::integral_constant<pm_node_type_t, PM_CONSTANT_OPERATOR_WRITE_NODE> {};
165static_assert(std::is_standard_layout_v<pm_constant_operator_write_node_t> && offsetof(pm_constant_operator_write_node_t, base) == 0, "pm_constant_operator_write_node_t must begin with its pm_node_t");
166
168template <> struct node_type<pm_constant_or_write_node_t> : std::integral_constant<pm_node_type_t, PM_CONSTANT_OR_WRITE_NODE> {};
169static_assert(std::is_standard_layout_v<pm_constant_or_write_node_t> && offsetof(pm_constant_or_write_node_t, base) == 0, "pm_constant_or_write_node_t must begin with its pm_node_t");
170
172template <> struct node_type<pm_constant_path_and_write_node_t> : std::integral_constant<pm_node_type_t, PM_CONSTANT_PATH_AND_WRITE_NODE> {};
173static_assert(std::is_standard_layout_v<pm_constant_path_and_write_node_t> && offsetof(pm_constant_path_and_write_node_t, base) == 0, "pm_constant_path_and_write_node_t must begin with its pm_node_t");
174
176template <> struct node_type<pm_constant_path_node_t> : std::integral_constant<pm_node_type_t, PM_CONSTANT_PATH_NODE> {};
177static_assert(std::is_standard_layout_v<pm_constant_path_node_t> && offsetof(pm_constant_path_node_t, base) == 0, "pm_constant_path_node_t must begin with its pm_node_t");
178
180template <> struct node_type<pm_constant_path_operator_write_node_t> : std::integral_constant<pm_node_type_t, PM_CONSTANT_PATH_OPERATOR_WRITE_NODE> {};
181static_assert(std::is_standard_layout_v<pm_constant_path_operator_write_node_t> && offsetof(pm_constant_path_operator_write_node_t, base) == 0, "pm_constant_path_operator_write_node_t must begin with its pm_node_t");
182
184template <> struct node_type<pm_constant_path_or_write_node_t> : std::integral_constant<pm_node_type_t, PM_CONSTANT_PATH_OR_WRITE_NODE> {};
185static_assert(std::is_standard_layout_v<pm_constant_path_or_write_node_t> && offsetof(pm_constant_path_or_write_node_t, base) == 0, "pm_constant_path_or_write_node_t must begin with its pm_node_t");
186
188template <> struct node_type<pm_constant_path_target_node_t> : std::integral_constant<pm_node_type_t, PM_CONSTANT_PATH_TARGET_NODE> {};
189static_assert(std::is_standard_layout_v<pm_constant_path_target_node_t> && offsetof(pm_constant_path_target_node_t, base) == 0, "pm_constant_path_target_node_t must begin with its pm_node_t");
190
192template <> struct node_type<pm_constant_path_write_node_t> : std::integral_constant<pm_node_type_t, PM_CONSTANT_PATH_WRITE_NODE> {};
193static_assert(std::is_standard_layout_v<pm_constant_path_write_node_t> && offsetof(pm_constant_path_write_node_t, base) == 0, "pm_constant_path_write_node_t must begin with its pm_node_t");
194
196template <> struct node_type<pm_constant_read_node_t> : std::integral_constant<pm_node_type_t, PM_CONSTANT_READ_NODE> {};
197static_assert(std::is_standard_layout_v<pm_constant_read_node_t> && offsetof(pm_constant_read_node_t, base) == 0, "pm_constant_read_node_t must begin with its pm_node_t");
198
200template <> struct node_type<pm_constant_target_node_t> : std::integral_constant<pm_node_type_t, PM_CONSTANT_TARGET_NODE> {};
201static_assert(std::is_standard_layout_v<pm_constant_target_node_t> && offsetof(pm_constant_target_node_t, base) == 0, "pm_constant_target_node_t must begin with its pm_node_t");
202
204template <> struct node_type<pm_constant_write_node_t> : std::integral_constant<pm_node_type_t, PM_CONSTANT_WRITE_NODE> {};
205static_assert(std::is_standard_layout_v<pm_constant_write_node_t> && offsetof(pm_constant_write_node_t, base) == 0, "pm_constant_write_node_t must begin with its pm_node_t");
206
208template <> struct node_type<pm_def_node_t> : std::integral_constant<pm_node_type_t, PM_DEF_NODE> {};
209static_assert(std::is_standard_layout_v<pm_def_node_t> && offsetof(pm_def_node_t, base) == 0, "pm_def_node_t must begin with its pm_node_t");
210
212template <> struct node_type<pm_defined_node_t> : std::integral_constant<pm_node_type_t, PM_DEFINED_NODE> {};
213static_assert(std::is_standard_layout_v<pm_defined_node_t> && offsetof(pm_defined_node_t, base) == 0, "pm_defined_node_t must begin with its pm_node_t");
214
216template <> struct node_type<pm_else_node_t> : std::integral_constant<pm_node_type_t, PM_ELSE_NODE> {};
217static_assert(std::is_standard_layout_v<pm_else_node_t> && offsetof(pm_else_node_t, base) == 0, "pm_else_node_t must begin with its pm_node_t");
218
220template <> struct node_type<pm_embedded_statements_node_t> : std::integral_constant<pm_node_type_t, PM_EMBEDDED_STATEMENTS_NODE> {};
221static_assert(std::is_standard_layout_v<pm_embedded_statements_node_t> && offsetof(pm_embedded_statements_node_t, base) == 0, "pm_embedded_statements_node_t must begin with its pm_node_t");
222
224template <> struct node_type<pm_embedded_variable_node_t> : std::integral_constant<pm_node_type_t, PM_EMBEDDED_VARIABLE_NODE> {};
225static_assert(std::is_standard_layout_v<pm_embedded_variable_node_t> && offsetof(pm_embedded_variable_node_t, base) == 0, "pm_embedded_variable_node_t must begin with its pm_node_t");
226
228template <> struct node_type<pm_ensure_node_t> : std::integral_constant<pm_node_type_t, PM_ENSURE_NODE> {};
229static_assert(std::is_standard_layout_v<pm_ensure_node_t> && offsetof(pm_ensure_node_t, base) == 0, "pm_ensure_node_t must begin with its pm_node_t");
230
232template <> struct node_type<pm_error_recovery_node_t> : std::integral_constant<pm_node_type_t, PM_ERROR_RECOVERY_NODE> {};
233static_assert(std::is_standard_layout_v<pm_error_recovery_node_t> && offsetof(pm_error_recovery_node_t, base) == 0, "pm_error_recovery_node_t must begin with its pm_node_t");
234
236template <> struct node_type<pm_false_node_t> : std::integral_constant<pm_node_type_t, PM_FALSE_NODE> {};
237static_assert(std::is_standard_layout_v<pm_false_node_t> && offsetof(pm_false_node_t, base) == 0, "pm_false_node_t must begin with its pm_node_t");
238
240template <> struct node_type<pm_find_pattern_node_t> : std::integral_constant<pm_node_type_t, PM_FIND_PATTERN_NODE> {};
241static_assert(std::is_standard_layout_v<pm_find_pattern_node_t> && offsetof(pm_find_pattern_node_t, base) == 0, "pm_find_pattern_node_t must begin with its pm_node_t");
242
244template <> struct node_type<pm_flip_flop_node_t> : std::integral_constant<pm_node_type_t, PM_FLIP_FLOP_NODE> {};
245static_assert(std::is_standard_layout_v<pm_flip_flop_node_t> && offsetof(pm_flip_flop_node_t, base) == 0, "pm_flip_flop_node_t must begin with its pm_node_t");
246
248template <> struct node_type<pm_float_node_t> : std::integral_constant<pm_node_type_t, PM_FLOAT_NODE> {};
249static_assert(std::is_standard_layout_v<pm_float_node_t> && offsetof(pm_float_node_t, base) == 0, "pm_float_node_t must begin with its pm_node_t");
250
252template <> struct node_type<pm_for_node_t> : std::integral_constant<pm_node_type_t, PM_FOR_NODE> {};
253static_assert(std::is_standard_layout_v<pm_for_node_t> && offsetof(pm_for_node_t, base) == 0, "pm_for_node_t must begin with its pm_node_t");
254
256template <> struct node_type<pm_forwarding_arguments_node_t> : std::integral_constant<pm_node_type_t, PM_FORWARDING_ARGUMENTS_NODE> {};
257static_assert(std::is_standard_layout_v<pm_forwarding_arguments_node_t> && offsetof(pm_forwarding_arguments_node_t, base) == 0, "pm_forwarding_arguments_node_t must begin with its pm_node_t");
258
260template <> struct node_type<pm_forwarding_parameter_node_t> : std::integral_constant<pm_node_type_t, PM_FORWARDING_PARAMETER_NODE> {};
261static_assert(std::is_standard_layout_v<pm_forwarding_parameter_node_t> && offsetof(pm_forwarding_parameter_node_t, base) == 0, "pm_forwarding_parameter_node_t must begin with its pm_node_t");
262
264template <> struct node_type<pm_forwarding_super_node_t> : std::integral_constant<pm_node_type_t, PM_FORWARDING_SUPER_NODE> {};
265static_assert(std::is_standard_layout_v<pm_forwarding_super_node_t> && offsetof(pm_forwarding_super_node_t, base) == 0, "pm_forwarding_super_node_t must begin with its pm_node_t");
266
268template <> struct node_type<pm_global_variable_and_write_node_t> : std::integral_constant<pm_node_type_t, PM_GLOBAL_VARIABLE_AND_WRITE_NODE> {};
269static_assert(std::is_standard_layout_v<pm_global_variable_and_write_node_t> && offsetof(pm_global_variable_and_write_node_t, base) == 0, "pm_global_variable_and_write_node_t must begin with its pm_node_t");
270
272template <> struct node_type<pm_global_variable_operator_write_node_t> : std::integral_constant<pm_node_type_t, PM_GLOBAL_VARIABLE_OPERATOR_WRITE_NODE> {};
273static_assert(std::is_standard_layout_v<pm_global_variable_operator_write_node_t> && offsetof(pm_global_variable_operator_write_node_t, base) == 0, "pm_global_variable_operator_write_node_t must begin with its pm_node_t");
274
276template <> struct node_type<pm_global_variable_or_write_node_t> : std::integral_constant<pm_node_type_t, PM_GLOBAL_VARIABLE_OR_WRITE_NODE> {};
277static_assert(std::is_standard_layout_v<pm_global_variable_or_write_node_t> && offsetof(pm_global_variable_or_write_node_t, base) == 0, "pm_global_variable_or_write_node_t must begin with its pm_node_t");
278
280template <> struct node_type<pm_global_variable_read_node_t> : std::integral_constant<pm_node_type_t, PM_GLOBAL_VARIABLE_READ_NODE> {};
281static_assert(std::is_standard_layout_v<pm_global_variable_read_node_t> && offsetof(pm_global_variable_read_node_t, base) == 0, "pm_global_variable_read_node_t must begin with its pm_node_t");
282
284template <> struct node_type<pm_global_variable_target_node_t> : std::integral_constant<pm_node_type_t, PM_GLOBAL_VARIABLE_TARGET_NODE> {};
285static_assert(std::is_standard_layout_v<pm_global_variable_target_node_t> && offsetof(pm_global_variable_target_node_t, base) == 0, "pm_global_variable_target_node_t must begin with its pm_node_t");
286
288template <> struct node_type<pm_global_variable_write_node_t> : std::integral_constant<pm_node_type_t, PM_GLOBAL_VARIABLE_WRITE_NODE> {};
289static_assert(std::is_standard_layout_v<pm_global_variable_write_node_t> && offsetof(pm_global_variable_write_node_t, base) == 0, "pm_global_variable_write_node_t must begin with its pm_node_t");
290
292template <> struct node_type<pm_hash_node_t> : std::integral_constant<pm_node_type_t, PM_HASH_NODE> {};
293static_assert(std::is_standard_layout_v<pm_hash_node_t> && offsetof(pm_hash_node_t, base) == 0, "pm_hash_node_t must begin with its pm_node_t");
294
296template <> struct node_type<pm_hash_pattern_node_t> : std::integral_constant<pm_node_type_t, PM_HASH_PATTERN_NODE> {};
297static_assert(std::is_standard_layout_v<pm_hash_pattern_node_t> && offsetof(pm_hash_pattern_node_t, base) == 0, "pm_hash_pattern_node_t must begin with its pm_node_t");
298
300template <> struct node_type<pm_if_node_t> : std::integral_constant<pm_node_type_t, PM_IF_NODE> {};
301static_assert(std::is_standard_layout_v<pm_if_node_t> && offsetof(pm_if_node_t, base) == 0, "pm_if_node_t must begin with its pm_node_t");
302
304template <> struct node_type<pm_imaginary_node_t> : std::integral_constant<pm_node_type_t, PM_IMAGINARY_NODE> {};
305static_assert(std::is_standard_layout_v<pm_imaginary_node_t> && offsetof(pm_imaginary_node_t, base) == 0, "pm_imaginary_node_t must begin with its pm_node_t");
306
308template <> struct node_type<pm_implicit_node_t> : std::integral_constant<pm_node_type_t, PM_IMPLICIT_NODE> {};
309static_assert(std::is_standard_layout_v<pm_implicit_node_t> && offsetof(pm_implicit_node_t, base) == 0, "pm_implicit_node_t must begin with its pm_node_t");
310
312template <> struct node_type<pm_implicit_rest_node_t> : std::integral_constant<pm_node_type_t, PM_IMPLICIT_REST_NODE> {};
313static_assert(std::is_standard_layout_v<pm_implicit_rest_node_t> && offsetof(pm_implicit_rest_node_t, base) == 0, "pm_implicit_rest_node_t must begin with its pm_node_t");
314
316template <> struct node_type<pm_in_node_t> : std::integral_constant<pm_node_type_t, PM_IN_NODE> {};
317static_assert(std::is_standard_layout_v<pm_in_node_t> && offsetof(pm_in_node_t, base) == 0, "pm_in_node_t must begin with its pm_node_t");
318
320template <> struct node_type<pm_index_and_write_node_t> : std::integral_constant<pm_node_type_t, PM_INDEX_AND_WRITE_NODE> {};
321static_assert(std::is_standard_layout_v<pm_index_and_write_node_t> && offsetof(pm_index_and_write_node_t, base) == 0, "pm_index_and_write_node_t must begin with its pm_node_t");
322
324template <> struct node_type<pm_index_operator_write_node_t> : std::integral_constant<pm_node_type_t, PM_INDEX_OPERATOR_WRITE_NODE> {};
325static_assert(std::is_standard_layout_v<pm_index_operator_write_node_t> && offsetof(pm_index_operator_write_node_t, base) == 0, "pm_index_operator_write_node_t must begin with its pm_node_t");
326
328template <> struct node_type<pm_index_or_write_node_t> : std::integral_constant<pm_node_type_t, PM_INDEX_OR_WRITE_NODE> {};
329static_assert(std::is_standard_layout_v<pm_index_or_write_node_t> && offsetof(pm_index_or_write_node_t, base) == 0, "pm_index_or_write_node_t must begin with its pm_node_t");
330
332template <> struct node_type<pm_index_target_node_t> : std::integral_constant<pm_node_type_t, PM_INDEX_TARGET_NODE> {};
333static_assert(std::is_standard_layout_v<pm_index_target_node_t> && offsetof(pm_index_target_node_t, base) == 0, "pm_index_target_node_t must begin with its pm_node_t");
334
336template <> struct node_type<pm_instance_variable_and_write_node_t> : std::integral_constant<pm_node_type_t, PM_INSTANCE_VARIABLE_AND_WRITE_NODE> {};
337static_assert(std::is_standard_layout_v<pm_instance_variable_and_write_node_t> && offsetof(pm_instance_variable_and_write_node_t, base) == 0, "pm_instance_variable_and_write_node_t must begin with its pm_node_t");
338
340template <> struct node_type<pm_instance_variable_operator_write_node_t> : std::integral_constant<pm_node_type_t, PM_INSTANCE_VARIABLE_OPERATOR_WRITE_NODE> {};
341static_assert(std::is_standard_layout_v<pm_instance_variable_operator_write_node_t> && offsetof(pm_instance_variable_operator_write_node_t, base) == 0, "pm_instance_variable_operator_write_node_t must begin with its pm_node_t");
342
344template <> struct node_type<pm_instance_variable_or_write_node_t> : std::integral_constant<pm_node_type_t, PM_INSTANCE_VARIABLE_OR_WRITE_NODE> {};
345static_assert(std::is_standard_layout_v<pm_instance_variable_or_write_node_t> && offsetof(pm_instance_variable_or_write_node_t, base) == 0, "pm_instance_variable_or_write_node_t must begin with its pm_node_t");
346
348template <> struct node_type<pm_instance_variable_read_node_t> : std::integral_constant<pm_node_type_t, PM_INSTANCE_VARIABLE_READ_NODE> {};
349static_assert(std::is_standard_layout_v<pm_instance_variable_read_node_t> && offsetof(pm_instance_variable_read_node_t, base) == 0, "pm_instance_variable_read_node_t must begin with its pm_node_t");
350
352template <> struct node_type<pm_instance_variable_target_node_t> : std::integral_constant<pm_node_type_t, PM_INSTANCE_VARIABLE_TARGET_NODE> {};
353static_assert(std::is_standard_layout_v<pm_instance_variable_target_node_t> && offsetof(pm_instance_variable_target_node_t, base) == 0, "pm_instance_variable_target_node_t must begin with its pm_node_t");
354
356template <> struct node_type<pm_instance_variable_write_node_t> : std::integral_constant<pm_node_type_t, PM_INSTANCE_VARIABLE_WRITE_NODE> {};
357static_assert(std::is_standard_layout_v<pm_instance_variable_write_node_t> && offsetof(pm_instance_variable_write_node_t, base) == 0, "pm_instance_variable_write_node_t must begin with its pm_node_t");
358
360template <> struct node_type<pm_integer_node_t> : std::integral_constant<pm_node_type_t, PM_INTEGER_NODE> {};
361static_assert(std::is_standard_layout_v<pm_integer_node_t> && offsetof(pm_integer_node_t, base) == 0, "pm_integer_node_t must begin with its pm_node_t");
362
364template <> struct node_type<pm_interpolated_match_last_line_node_t> : std::integral_constant<pm_node_type_t, PM_INTERPOLATED_MATCH_LAST_LINE_NODE> {};
365static_assert(std::is_standard_layout_v<pm_interpolated_match_last_line_node_t> && offsetof(pm_interpolated_match_last_line_node_t, base) == 0, "pm_interpolated_match_last_line_node_t must begin with its pm_node_t");
366
368template <> struct node_type<pm_interpolated_regular_expression_node_t> : std::integral_constant<pm_node_type_t, PM_INTERPOLATED_REGULAR_EXPRESSION_NODE> {};
369static_assert(std::is_standard_layout_v<pm_interpolated_regular_expression_node_t> && offsetof(pm_interpolated_regular_expression_node_t, base) == 0, "pm_interpolated_regular_expression_node_t must begin with its pm_node_t");
370
372template <> struct node_type<pm_interpolated_string_node_t> : std::integral_constant<pm_node_type_t, PM_INTERPOLATED_STRING_NODE> {};
373static_assert(std::is_standard_layout_v<pm_interpolated_string_node_t> && offsetof(pm_interpolated_string_node_t, base) == 0, "pm_interpolated_string_node_t must begin with its pm_node_t");
374
376template <> struct node_type<pm_interpolated_symbol_node_t> : std::integral_constant<pm_node_type_t, PM_INTERPOLATED_SYMBOL_NODE> {};
377static_assert(std::is_standard_layout_v<pm_interpolated_symbol_node_t> && offsetof(pm_interpolated_symbol_node_t, base) == 0, "pm_interpolated_symbol_node_t must begin with its pm_node_t");
378
380template <> struct node_type<pm_interpolated_x_string_node_t> : std::integral_constant<pm_node_type_t, PM_INTERPOLATED_X_STRING_NODE> {};
381static_assert(std::is_standard_layout_v<pm_interpolated_x_string_node_t> && offsetof(pm_interpolated_x_string_node_t, base) == 0, "pm_interpolated_x_string_node_t must begin with its pm_node_t");
382
384template <> struct node_type<pm_it_local_variable_read_node_t> : std::integral_constant<pm_node_type_t, PM_IT_LOCAL_VARIABLE_READ_NODE> {};
385static_assert(std::is_standard_layout_v<pm_it_local_variable_read_node_t> && offsetof(pm_it_local_variable_read_node_t, base) == 0, "pm_it_local_variable_read_node_t must begin with its pm_node_t");
386
388template <> struct node_type<pm_it_parameters_node_t> : std::integral_constant<pm_node_type_t, PM_IT_PARAMETERS_NODE> {};
389static_assert(std::is_standard_layout_v<pm_it_parameters_node_t> && offsetof(pm_it_parameters_node_t, base) == 0, "pm_it_parameters_node_t must begin with its pm_node_t");
390
392template <> struct node_type<pm_keyword_hash_node_t> : std::integral_constant<pm_node_type_t, PM_KEYWORD_HASH_NODE> {};
393static_assert(std::is_standard_layout_v<pm_keyword_hash_node_t> && offsetof(pm_keyword_hash_node_t, base) == 0, "pm_keyword_hash_node_t must begin with its pm_node_t");
394
396template <> struct node_type<pm_keyword_rest_parameter_node_t> : std::integral_constant<pm_node_type_t, PM_KEYWORD_REST_PARAMETER_NODE> {};
397static_assert(std::is_standard_layout_v<pm_keyword_rest_parameter_node_t> && offsetof(pm_keyword_rest_parameter_node_t, base) == 0, "pm_keyword_rest_parameter_node_t must begin with its pm_node_t");
398
400template <> struct node_type<pm_lambda_node_t> : std::integral_constant<pm_node_type_t, PM_LAMBDA_NODE> {};
401static_assert(std::is_standard_layout_v<pm_lambda_node_t> && offsetof(pm_lambda_node_t, base) == 0, "pm_lambda_node_t must begin with its pm_node_t");
402
404template <> struct node_type<pm_local_variable_and_write_node_t> : std::integral_constant<pm_node_type_t, PM_LOCAL_VARIABLE_AND_WRITE_NODE> {};
405static_assert(std::is_standard_layout_v<pm_local_variable_and_write_node_t> && offsetof(pm_local_variable_and_write_node_t, base) == 0, "pm_local_variable_and_write_node_t must begin with its pm_node_t");
406
408template <> struct node_type<pm_local_variable_operator_write_node_t> : std::integral_constant<pm_node_type_t, PM_LOCAL_VARIABLE_OPERATOR_WRITE_NODE> {};
409static_assert(std::is_standard_layout_v<pm_local_variable_operator_write_node_t> && offsetof(pm_local_variable_operator_write_node_t, base) == 0, "pm_local_variable_operator_write_node_t must begin with its pm_node_t");
410
412template <> struct node_type<pm_local_variable_or_write_node_t> : std::integral_constant<pm_node_type_t, PM_LOCAL_VARIABLE_OR_WRITE_NODE> {};
413static_assert(std::is_standard_layout_v<pm_local_variable_or_write_node_t> && offsetof(pm_local_variable_or_write_node_t, base) == 0, "pm_local_variable_or_write_node_t must begin with its pm_node_t");
414
416template <> struct node_type<pm_local_variable_read_node_t> : std::integral_constant<pm_node_type_t, PM_LOCAL_VARIABLE_READ_NODE> {};
417static_assert(std::is_standard_layout_v<pm_local_variable_read_node_t> && offsetof(pm_local_variable_read_node_t, base) == 0, "pm_local_variable_read_node_t must begin with its pm_node_t");
418
420template <> struct node_type<pm_local_variable_target_node_t> : std::integral_constant<pm_node_type_t, PM_LOCAL_VARIABLE_TARGET_NODE> {};
421static_assert(std::is_standard_layout_v<pm_local_variable_target_node_t> && offsetof(pm_local_variable_target_node_t, base) == 0, "pm_local_variable_target_node_t must begin with its pm_node_t");
422
424template <> struct node_type<pm_local_variable_write_node_t> : std::integral_constant<pm_node_type_t, PM_LOCAL_VARIABLE_WRITE_NODE> {};
425static_assert(std::is_standard_layout_v<pm_local_variable_write_node_t> && offsetof(pm_local_variable_write_node_t, base) == 0, "pm_local_variable_write_node_t must begin with its pm_node_t");
426
428template <> struct node_type<pm_match_last_line_node_t> : std::integral_constant<pm_node_type_t, PM_MATCH_LAST_LINE_NODE> {};
429static_assert(std::is_standard_layout_v<pm_match_last_line_node_t> && offsetof(pm_match_last_line_node_t, base) == 0, "pm_match_last_line_node_t must begin with its pm_node_t");
430
432template <> struct node_type<pm_match_predicate_node_t> : std::integral_constant<pm_node_type_t, PM_MATCH_PREDICATE_NODE> {};
433static_assert(std::is_standard_layout_v<pm_match_predicate_node_t> && offsetof(pm_match_predicate_node_t, base) == 0, "pm_match_predicate_node_t must begin with its pm_node_t");
434
436template <> struct node_type<pm_match_required_node_t> : std::integral_constant<pm_node_type_t, PM_MATCH_REQUIRED_NODE> {};
437static_assert(std::is_standard_layout_v<pm_match_required_node_t> && offsetof(pm_match_required_node_t, base) == 0, "pm_match_required_node_t must begin with its pm_node_t");
438
440template <> struct node_type<pm_match_write_node_t> : std::integral_constant<pm_node_type_t, PM_MATCH_WRITE_NODE> {};
441static_assert(std::is_standard_layout_v<pm_match_write_node_t> && offsetof(pm_match_write_node_t, base) == 0, "pm_match_write_node_t must begin with its pm_node_t");
442
444template <> struct node_type<pm_module_node_t> : std::integral_constant<pm_node_type_t, PM_MODULE_NODE> {};
445static_assert(std::is_standard_layout_v<pm_module_node_t> && offsetof(pm_module_node_t, base) == 0, "pm_module_node_t must begin with its pm_node_t");
446
448template <> struct node_type<pm_multi_target_node_t> : std::integral_constant<pm_node_type_t, PM_MULTI_TARGET_NODE> {};
449static_assert(std::is_standard_layout_v<pm_multi_target_node_t> && offsetof(pm_multi_target_node_t, base) == 0, "pm_multi_target_node_t must begin with its pm_node_t");
450
452template <> struct node_type<pm_multi_write_node_t> : std::integral_constant<pm_node_type_t, PM_MULTI_WRITE_NODE> {};
453static_assert(std::is_standard_layout_v<pm_multi_write_node_t> && offsetof(pm_multi_write_node_t, base) == 0, "pm_multi_write_node_t must begin with its pm_node_t");
454
456template <> struct node_type<pm_next_node_t> : std::integral_constant<pm_node_type_t, PM_NEXT_NODE> {};
457static_assert(std::is_standard_layout_v<pm_next_node_t> && offsetof(pm_next_node_t, base) == 0, "pm_next_node_t must begin with its pm_node_t");
458
460template <> struct node_type<pm_nil_node_t> : std::integral_constant<pm_node_type_t, PM_NIL_NODE> {};
461static_assert(std::is_standard_layout_v<pm_nil_node_t> && offsetof(pm_nil_node_t, base) == 0, "pm_nil_node_t must begin with its pm_node_t");
462
464template <> struct node_type<pm_no_block_parameter_node_t> : std::integral_constant<pm_node_type_t, PM_NO_BLOCK_PARAMETER_NODE> {};
465static_assert(std::is_standard_layout_v<pm_no_block_parameter_node_t> && offsetof(pm_no_block_parameter_node_t, base) == 0, "pm_no_block_parameter_node_t must begin with its pm_node_t");
466
468template <> struct node_type<pm_no_keywords_parameter_node_t> : std::integral_constant<pm_node_type_t, PM_NO_KEYWORDS_PARAMETER_NODE> {};
469static_assert(std::is_standard_layout_v<pm_no_keywords_parameter_node_t> && offsetof(pm_no_keywords_parameter_node_t, base) == 0, "pm_no_keywords_parameter_node_t must begin with its pm_node_t");
470
472template <> struct node_type<pm_numbered_parameters_node_t> : std::integral_constant<pm_node_type_t, PM_NUMBERED_PARAMETERS_NODE> {};
473static_assert(std::is_standard_layout_v<pm_numbered_parameters_node_t> && offsetof(pm_numbered_parameters_node_t, base) == 0, "pm_numbered_parameters_node_t must begin with its pm_node_t");
474
476template <> struct node_type<pm_numbered_reference_read_node_t> : std::integral_constant<pm_node_type_t, PM_NUMBERED_REFERENCE_READ_NODE> {};
477static_assert(std::is_standard_layout_v<pm_numbered_reference_read_node_t> && offsetof(pm_numbered_reference_read_node_t, base) == 0, "pm_numbered_reference_read_node_t must begin with its pm_node_t");
478
480template <> struct node_type<pm_optional_keyword_parameter_node_t> : std::integral_constant<pm_node_type_t, PM_OPTIONAL_KEYWORD_PARAMETER_NODE> {};
481static_assert(std::is_standard_layout_v<pm_optional_keyword_parameter_node_t> && offsetof(pm_optional_keyword_parameter_node_t, base) == 0, "pm_optional_keyword_parameter_node_t must begin with its pm_node_t");
482
484template <> struct node_type<pm_optional_parameter_node_t> : std::integral_constant<pm_node_type_t, PM_OPTIONAL_PARAMETER_NODE> {};
485static_assert(std::is_standard_layout_v<pm_optional_parameter_node_t> && offsetof(pm_optional_parameter_node_t, base) == 0, "pm_optional_parameter_node_t must begin with its pm_node_t");
486
488template <> struct node_type<pm_or_node_t> : std::integral_constant<pm_node_type_t, PM_OR_NODE> {};
489static_assert(std::is_standard_layout_v<pm_or_node_t> && offsetof(pm_or_node_t, base) == 0, "pm_or_node_t must begin with its pm_node_t");
490
492template <> struct node_type<pm_parameters_node_t> : std::integral_constant<pm_node_type_t, PM_PARAMETERS_NODE> {};
493static_assert(std::is_standard_layout_v<pm_parameters_node_t> && offsetof(pm_parameters_node_t, base) == 0, "pm_parameters_node_t must begin with its pm_node_t");
494
496template <> struct node_type<pm_parentheses_node_t> : std::integral_constant<pm_node_type_t, PM_PARENTHESES_NODE> {};
497static_assert(std::is_standard_layout_v<pm_parentheses_node_t> && offsetof(pm_parentheses_node_t, base) == 0, "pm_parentheses_node_t must begin with its pm_node_t");
498
500template <> struct node_type<pm_pinned_expression_node_t> : std::integral_constant<pm_node_type_t, PM_PINNED_EXPRESSION_NODE> {};
501static_assert(std::is_standard_layout_v<pm_pinned_expression_node_t> && offsetof(pm_pinned_expression_node_t, base) == 0, "pm_pinned_expression_node_t must begin with its pm_node_t");
502
504template <> struct node_type<pm_pinned_variable_node_t> : std::integral_constant<pm_node_type_t, PM_PINNED_VARIABLE_NODE> {};
505static_assert(std::is_standard_layout_v<pm_pinned_variable_node_t> && offsetof(pm_pinned_variable_node_t, base) == 0, "pm_pinned_variable_node_t must begin with its pm_node_t");
506
508template <> struct node_type<pm_post_execution_node_t> : std::integral_constant<pm_node_type_t, PM_POST_EXECUTION_NODE> {};
509static_assert(std::is_standard_layout_v<pm_post_execution_node_t> && offsetof(pm_post_execution_node_t, base) == 0, "pm_post_execution_node_t must begin with its pm_node_t");
510
512template <> struct node_type<pm_pre_execution_node_t> : std::integral_constant<pm_node_type_t, PM_PRE_EXECUTION_NODE> {};
513static_assert(std::is_standard_layout_v<pm_pre_execution_node_t> && offsetof(pm_pre_execution_node_t, base) == 0, "pm_pre_execution_node_t must begin with its pm_node_t");
514
516template <> struct node_type<pm_program_node_t> : std::integral_constant<pm_node_type_t, PM_PROGRAM_NODE> {};
517static_assert(std::is_standard_layout_v<pm_program_node_t> && offsetof(pm_program_node_t, base) == 0, "pm_program_node_t must begin with its pm_node_t");
518
520template <> struct node_type<pm_range_node_t> : std::integral_constant<pm_node_type_t, PM_RANGE_NODE> {};
521static_assert(std::is_standard_layout_v<pm_range_node_t> && offsetof(pm_range_node_t, base) == 0, "pm_range_node_t must begin with its pm_node_t");
522
524template <> struct node_type<pm_rational_node_t> : std::integral_constant<pm_node_type_t, PM_RATIONAL_NODE> {};
525static_assert(std::is_standard_layout_v<pm_rational_node_t> && offsetof(pm_rational_node_t, base) == 0, "pm_rational_node_t must begin with its pm_node_t");
526
528template <> struct node_type<pm_redo_node_t> : std::integral_constant<pm_node_type_t, PM_REDO_NODE> {};
529static_assert(std::is_standard_layout_v<pm_redo_node_t> && offsetof(pm_redo_node_t, base) == 0, "pm_redo_node_t must begin with its pm_node_t");
530
532template <> struct node_type<pm_regular_expression_node_t> : std::integral_constant<pm_node_type_t, PM_REGULAR_EXPRESSION_NODE> {};
533static_assert(std::is_standard_layout_v<pm_regular_expression_node_t> && offsetof(pm_regular_expression_node_t, base) == 0, "pm_regular_expression_node_t must begin with its pm_node_t");
534
536template <> struct node_type<pm_required_keyword_parameter_node_t> : std::integral_constant<pm_node_type_t, PM_REQUIRED_KEYWORD_PARAMETER_NODE> {};
537static_assert(std::is_standard_layout_v<pm_required_keyword_parameter_node_t> && offsetof(pm_required_keyword_parameter_node_t, base) == 0, "pm_required_keyword_parameter_node_t must begin with its pm_node_t");
538
540template <> struct node_type<pm_required_parameter_node_t> : std::integral_constant<pm_node_type_t, PM_REQUIRED_PARAMETER_NODE> {};
541static_assert(std::is_standard_layout_v<pm_required_parameter_node_t> && offsetof(pm_required_parameter_node_t, base) == 0, "pm_required_parameter_node_t must begin with its pm_node_t");
542
544template <> struct node_type<pm_rescue_modifier_node_t> : std::integral_constant<pm_node_type_t, PM_RESCUE_MODIFIER_NODE> {};
545static_assert(std::is_standard_layout_v<pm_rescue_modifier_node_t> && offsetof(pm_rescue_modifier_node_t, base) == 0, "pm_rescue_modifier_node_t must begin with its pm_node_t");
546
548template <> struct node_type<pm_rescue_node_t> : std::integral_constant<pm_node_type_t, PM_RESCUE_NODE> {};
549static_assert(std::is_standard_layout_v<pm_rescue_node_t> && offsetof(pm_rescue_node_t, base) == 0, "pm_rescue_node_t must begin with its pm_node_t");
550
552template <> struct node_type<pm_rest_parameter_node_t> : std::integral_constant<pm_node_type_t, PM_REST_PARAMETER_NODE> {};
553static_assert(std::is_standard_layout_v<pm_rest_parameter_node_t> && offsetof(pm_rest_parameter_node_t, base) == 0, "pm_rest_parameter_node_t must begin with its pm_node_t");
554
556template <> struct node_type<pm_retry_node_t> : std::integral_constant<pm_node_type_t, PM_RETRY_NODE> {};
557static_assert(std::is_standard_layout_v<pm_retry_node_t> && offsetof(pm_retry_node_t, base) == 0, "pm_retry_node_t must begin with its pm_node_t");
558
560template <> struct node_type<pm_return_node_t> : std::integral_constant<pm_node_type_t, PM_RETURN_NODE> {};
561static_assert(std::is_standard_layout_v<pm_return_node_t> && offsetof(pm_return_node_t, base) == 0, "pm_return_node_t must begin with its pm_node_t");
562
564template <> struct node_type<pm_self_node_t> : std::integral_constant<pm_node_type_t, PM_SELF_NODE> {};
565static_assert(std::is_standard_layout_v<pm_self_node_t> && offsetof(pm_self_node_t, base) == 0, "pm_self_node_t must begin with its pm_node_t");
566
568template <> struct node_type<pm_shareable_constant_node_t> : std::integral_constant<pm_node_type_t, PM_SHAREABLE_CONSTANT_NODE> {};
569static_assert(std::is_standard_layout_v<pm_shareable_constant_node_t> && offsetof(pm_shareable_constant_node_t, base) == 0, "pm_shareable_constant_node_t must begin with its pm_node_t");
570
572template <> struct node_type<pm_singleton_class_node_t> : std::integral_constant<pm_node_type_t, PM_SINGLETON_CLASS_NODE> {};
573static_assert(std::is_standard_layout_v<pm_singleton_class_node_t> && offsetof(pm_singleton_class_node_t, base) == 0, "pm_singleton_class_node_t must begin with its pm_node_t");
574
576template <> struct node_type<pm_source_encoding_node_t> : std::integral_constant<pm_node_type_t, PM_SOURCE_ENCODING_NODE> {};
577static_assert(std::is_standard_layout_v<pm_source_encoding_node_t> && offsetof(pm_source_encoding_node_t, base) == 0, "pm_source_encoding_node_t must begin with its pm_node_t");
578
580template <> struct node_type<pm_source_file_node_t> : std::integral_constant<pm_node_type_t, PM_SOURCE_FILE_NODE> {};
581static_assert(std::is_standard_layout_v<pm_source_file_node_t> && offsetof(pm_source_file_node_t, base) == 0, "pm_source_file_node_t must begin with its pm_node_t");
582
584template <> struct node_type<pm_source_line_node_t> : std::integral_constant<pm_node_type_t, PM_SOURCE_LINE_NODE> {};
585static_assert(std::is_standard_layout_v<pm_source_line_node_t> && offsetof(pm_source_line_node_t, base) == 0, "pm_source_line_node_t must begin with its pm_node_t");
586
588template <> struct node_type<pm_splat_node_t> : std::integral_constant<pm_node_type_t, PM_SPLAT_NODE> {};
589static_assert(std::is_standard_layout_v<pm_splat_node_t> && offsetof(pm_splat_node_t, base) == 0, "pm_splat_node_t must begin with its pm_node_t");
590
592template <> struct node_type<pm_statements_node_t> : std::integral_constant<pm_node_type_t, PM_STATEMENTS_NODE> {};
593static_assert(std::is_standard_layout_v<pm_statements_node_t> && offsetof(pm_statements_node_t, base) == 0, "pm_statements_node_t must begin with its pm_node_t");
594
596template <> struct node_type<pm_string_node_t> : std::integral_constant<pm_node_type_t, PM_STRING_NODE> {};
597static_assert(std::is_standard_layout_v<pm_string_node_t> && offsetof(pm_string_node_t, base) == 0, "pm_string_node_t must begin with its pm_node_t");
598
600template <> struct node_type<pm_super_node_t> : std::integral_constant<pm_node_type_t, PM_SUPER_NODE> {};
601static_assert(std::is_standard_layout_v<pm_super_node_t> && offsetof(pm_super_node_t, base) == 0, "pm_super_node_t must begin with its pm_node_t");
602
604template <> struct node_type<pm_symbol_node_t> : std::integral_constant<pm_node_type_t, PM_SYMBOL_NODE> {};
605static_assert(std::is_standard_layout_v<pm_symbol_node_t> && offsetof(pm_symbol_node_t, base) == 0, "pm_symbol_node_t must begin with its pm_node_t");
606
608template <> struct node_type<pm_true_node_t> : std::integral_constant<pm_node_type_t, PM_TRUE_NODE> {};
609static_assert(std::is_standard_layout_v<pm_true_node_t> && offsetof(pm_true_node_t, base) == 0, "pm_true_node_t must begin with its pm_node_t");
610
612template <> struct node_type<pm_undef_node_t> : std::integral_constant<pm_node_type_t, PM_UNDEF_NODE> {};
613static_assert(std::is_standard_layout_v<pm_undef_node_t> && offsetof(pm_undef_node_t, base) == 0, "pm_undef_node_t must begin with its pm_node_t");
614
616template <> struct node_type<pm_unless_node_t> : std::integral_constant<pm_node_type_t, PM_UNLESS_NODE> {};
617static_assert(std::is_standard_layout_v<pm_unless_node_t> && offsetof(pm_unless_node_t, base) == 0, "pm_unless_node_t must begin with its pm_node_t");
618
620template <> struct node_type<pm_until_node_t> : std::integral_constant<pm_node_type_t, PM_UNTIL_NODE> {};
621static_assert(std::is_standard_layout_v<pm_until_node_t> && offsetof(pm_until_node_t, base) == 0, "pm_until_node_t must begin with its pm_node_t");
622
624template <> struct node_type<pm_when_node_t> : std::integral_constant<pm_node_type_t, PM_WHEN_NODE> {};
625static_assert(std::is_standard_layout_v<pm_when_node_t> && offsetof(pm_when_node_t, base) == 0, "pm_when_node_t must begin with its pm_node_t");
626
628template <> struct node_type<pm_while_node_t> : std::integral_constant<pm_node_type_t, PM_WHILE_NODE> {};
629static_assert(std::is_standard_layout_v<pm_while_node_t> && offsetof(pm_while_node_t, base) == 0, "pm_while_node_t must begin with its pm_node_t");
630
632template <> struct node_type<pm_x_string_node_t> : std::integral_constant<pm_node_type_t, PM_X_STRING_NODE> {};
633static_assert(std::is_standard_layout_v<pm_x_string_node_t> && offsetof(pm_x_string_node_t, base) == 0, "pm_x_string_node_t must begin with its pm_node_t");
634
636template <> struct node_type<pm_yield_node_t> : std::integral_constant<pm_node_type_t, PM_YIELD_NODE> {};
637static_assert(std::is_standard_layout_v<pm_yield_node_t> && offsetof(pm_yield_node_t, base) == 0, "pm_yield_node_t must begin with its pm_node_t");
638
639}
640
641#endif
The abstract syntax tree.
The traits that map node structs to node types.
AliasGlobalVariableNode.
Definition ast.h:1170
AliasMethodNode.
Definition ast.h:1217
AlternationPatternNode.
Definition ast.h:1276
AndNode.
Definition ast.h:1323
ArgumentsNode.
Definition ast.h:1383
ArrayNode.
Definition ast.h:1413
ArrayPatternNode.
Definition ast.h:1473
AssocNode.
Definition ast.h:1556
AssocSplatNode.
Definition ast.h:1612
BackReferenceReadNode.
Definition ast.h:1649
BeginNode.
Definition ast.h:1679
BlockArgumentNode.
Definition ast.h:1756
BlockLocalVariableNode.
Definition ast.h:1796
BlockNode.
Definition ast.h:1823
BlockParameterNode.
Definition ast.h:1898
BlockParametersNode.
Definition ast.h:1951
BreakNode.
Definition ast.h:2024
CallAndWriteNode.
Definition ast.h:2067
CallNode.
Definition ast.h:2175
CallOperatorWriteNode.
Definition ast.h:2300
CallOrWriteNode.
Definition ast.h:2403
CallTargetNode.
Definition ast.h:2504
CapturePatternNode.
Definition ast.h:2561
CaseMatchNode.
Definition ast.h:2610
CaseNode.
Definition ast.h:2679
ClassNode.
Definition ast.h:2746
ClassVariableAndWriteNode.
Definition ast.h:2832
ClassVariableOperatorWriteNode.
Definition ast.h:2889
ClassVariableOrWriteNode.
Definition ast.h:2931
ClassVariableReadNode.
Definition ast.h:2968
ClassVariableTargetNode.
Definition ast.h:2996
ClassVariableWriteNode.
Definition ast.h:3018
ConstantAndWriteNode.
Definition ast.h:3079
ConstantOperatorWriteNode.
Definition ast.h:3116
ConstantOrWriteNode.
Definition ast.h:3158
ConstantPathAndWriteNode.
Definition ast.h:3195
ConstantPathNode.
Definition ast.h:3227
ConstantPathOperatorWriteNode.
Definition ast.h:3293
ConstantPathOrWriteNode.
Definition ast.h:3330
ConstantPathTargetNode.
Definition ast.h:3362
ConstantPathWriteNode.
Definition ast.h:3405
ConstantReadNode.
Definition ast.h:3455
ConstantTargetNode.
Definition ast.h:3483
ConstantWriteNode.
Definition ast.h:3505
DefNode.
Definition ast.h:3567
DefinedNode.
Definition ast.h:3644
ElseNode.
Definition ast.h:3681
EmbeddedStatementsNode.
Definition ast.h:3713
EmbeddedVariableNode.
Definition ast.h:3745
EnsureNode.
Definition ast.h:3776
ErrorRecoveryNode.
Definition ast.h:3805
FalseNode.
Definition ast.h:3829
FindPatternNode.
Definition ast.h:3855
FlipFlopNode.
Definition ast.h:3950
FloatNode.
Definition ast.h:3982
ForNode.
Definition ast.h:4006
ForwardingArgumentsNode.
Definition ast.h:4097
ForwardingParameterNode.
Definition ast.h:4115
ForwardingSuperNode.
Definition ast.h:4137
GlobalVariableAndWriteNode.
Definition ast.h:4172
GlobalVariableOperatorWriteNode.
Definition ast.h:4209
GlobalVariableOrWriteNode.
Definition ast.h:4251
GlobalVariableReadNode.
Definition ast.h:4288
GlobalVariableTargetNode.
Definition ast.h:4316
GlobalVariableWriteNode.
Definition ast.h:4338
HashNode.
Definition ast.h:4399
HashPatternNode.
Definition ast.h:4458
IfNode.
Definition ast.h:4546
ImaginaryNode.
Definition ast.h:4651
ImplicitNode.
Definition ast.h:4679
ImplicitRestNode.
Definition ast.h:4710
InNode.
Definition ast.h:4727
IndexAndWriteNode.
Definition ast.h:4770
IndexOperatorWriteNode.
Definition ast.h:4833
IndexOrWriteNode.
Definition ast.h:4901
IndexTargetNode.
Definition ast.h:4972
InstanceVariableAndWriteNode.
Definition ast.h:5014
InstanceVariableOperatorWriteNode.
Definition ast.h:5051
InstanceVariableOrWriteNode.
Definition ast.h:5093
InstanceVariableReadNode.
Definition ast.h:5130
InstanceVariableTargetNode.
Definition ast.h:5158
InstanceVariableWriteNode.
Definition ast.h:5180
IntegerNode.
Definition ast.h:5247
InterpolatedMatchLastLineNode.
Definition ast.h:5284
InterpolatedRegularExpressionNode.
Definition ast.h:5329
InterpolatedStringNode.
Definition ast.h:5365
InterpolatedSymbolNode.
Definition ast.h:5397
InterpolatedXStringNode.
Definition ast.h:5429
ItLocalVariableReadNode.
Definition ast.h:5461
ItParametersNode.
Definition ast.h:5478
KeywordHashNode.
Definition ast.h:5498
KeywordRestParameterNode.
Definition ast.h:5524
LambdaNode.
Definition ast.h:5556
LocalVariableAndWriteNode.
Definition ast.h:5603
LocalVariableOperatorWriteNode.
Definition ast.h:5645
LocalVariableOrWriteNode.
Definition ast.h:5692
LocalVariableReadNode.
Definition ast.h:5734
LocalVariableTargetNode.
Definition ast.h:5782
LocalVariableWriteNode.
Definition ast.h:5809
MatchLastLineNode.
Definition ast.h:5900
MatchPredicateNode.
Definition ast.h:5937
MatchRequiredNode.
Definition ast.h:5969
MatchWriteNode.
Definition ast.h:6055
ModuleNode.
Definition ast.h:6082
MultiTargetNode.
Definition ast.h:6134
MultiWriteNode.
Definition ast.h:6216
NextNode.
Definition ast.h:6318
NilNode.
Definition ast.h:6345
NoBlockParameterNode.
Definition ast.h:6363
NoKeywordsParameterNode.
Definition ast.h:6391
NumberedParametersNode.
Definition ast.h:6418
NumberedReferenceReadNode.
Definition ast.h:6440
OptionalKeywordParameterNode.
Definition ast.h:6474
OptionalParameterNode.
Definition ast.h:6510
OrNode.
Definition ast.h:6547
ParametersNode.
Definition ast.h:6601
ParenthesesNode.
Definition ast.h:6656
PinnedExpressionNode.
Definition ast.h:6688
PinnedVariableNode.
Definition ast.h:6745
PostExecutionNode.
Definition ast.h:6782
PreExecutionNode.
Definition ast.h:6819
ProgramNode.
Definition ast.h:6853
RangeNode.
Definition ast.h:6886
RationalNode.
Definition ast.h:6943
RedoNode.
Definition ast.h:6978
RegularExpressionNode.
Definition ast.h:7008
RequiredKeywordParameterNode.
Definition ast.h:7049
RequiredParameterNode.
Definition ast.h:7080
RescueModifierNode.
Definition ast.h:7102
RescueNode.
Definition ast.h:7139
RestParameterNode.
Definition ast.h:7195
RetryNode.
Definition ast.h:7227
ReturnNode.
Definition ast.h:7244
SelfNode.
Definition ast.h:7271
ShareableConstantNode.
Definition ast.h:7294
SingletonClassNode.
Definition ast.h:7318
SourceEncodingNode.
Definition ast.h:7365
SourceFileNode.
Definition ast.h:7388
SourceLineNode.
Definition ast.h:7412
SplatNode.
Definition ast.h:7429
StatementsNode.
Definition ast.h:7456
StringNode.
Definition ast.h:7490
SuperNode.
Definition ast.h:7532
SymbolNode.
Definition ast.h:7584
TrueNode.
Definition ast.h:7621
UndefNode.
Definition ast.h:7638
UnlessNode.
Definition ast.h:7668
UntilNode.
Definition ast.h:7758
WhenNode.
Definition ast.h:7802
WhileNode.
Definition ast.h:7845
XStringNode.
Definition ast.h:7891
YieldNode.
Definition ast.h:7928
Maps a node struct to its node type, as in node_type<pm_call_node_t>::value being PM_CALL_NODE.
Definition node_type.hpp:22