xref: /PHP-8.2/ext/tokenizer/tokenizer_data.c (revision 59d257d1)
1 /*
2    +----------------------------------------------------------------------+
3    | Copyright (c) The PHP Group                                          |
4    +----------------------------------------------------------------------+
5    | This source file is subject to version 3.01 of the PHP license,      |
6    | that is bundled with this package in the file LICENSE, and is        |
7    | available through the world-wide-web at the following url:           |
8    | https://www.php.net/license/3_01.txt                                 |
9    | If you did not receive a copy of the PHP license and are unable to   |
10    | obtain it through the world-wide-web, please send a note to          |
11    | license@php.net so we can mail you a copy immediately.               |
12    +----------------------------------------------------------------------+
13    | Author: Johannes Schlueter <johannes@php.net>                        |
14    +----------------------------------------------------------------------+
15 */
16 
17 /*
18    DO NOT EDIT THIS FILE!
19    This file is generated using tokenizer_data_gen.php
20 */
21 
22 #include "php.h"
23 #include "zend.h"
24 #include <zend_language_parser.h>
25 
get_token_type_name(int token_type)26 char *get_token_type_name(int token_type)
27 {
28 	switch (token_type) {
29 
30 		case T_LNUMBER: return "T_LNUMBER";
31 		case T_DNUMBER: return "T_DNUMBER";
32 		case T_STRING: return "T_STRING";
33 		case T_NAME_FULLY_QUALIFIED: return "T_NAME_FULLY_QUALIFIED";
34 		case T_NAME_RELATIVE: return "T_NAME_RELATIVE";
35 		case T_NAME_QUALIFIED: return "T_NAME_QUALIFIED";
36 		case T_VARIABLE: return "T_VARIABLE";
37 		case T_INLINE_HTML: return "T_INLINE_HTML";
38 		case T_ENCAPSED_AND_WHITESPACE: return "T_ENCAPSED_AND_WHITESPACE";
39 		case T_CONSTANT_ENCAPSED_STRING: return "T_CONSTANT_ENCAPSED_STRING";
40 		case T_STRING_VARNAME: return "T_STRING_VARNAME";
41 		case T_NUM_STRING: return "T_NUM_STRING";
42 		case T_INCLUDE: return "T_INCLUDE";
43 		case T_INCLUDE_ONCE: return "T_INCLUDE_ONCE";
44 		case T_EVAL: return "T_EVAL";
45 		case T_REQUIRE: return "T_REQUIRE";
46 		case T_REQUIRE_ONCE: return "T_REQUIRE_ONCE";
47 		case T_LOGICAL_OR: return "T_LOGICAL_OR";
48 		case T_LOGICAL_XOR: return "T_LOGICAL_XOR";
49 		case T_LOGICAL_AND: return "T_LOGICAL_AND";
50 		case T_PRINT: return "T_PRINT";
51 		case T_YIELD: return "T_YIELD";
52 		case T_YIELD_FROM: return "T_YIELD_FROM";
53 		case T_INSTANCEOF: return "T_INSTANCEOF";
54 		case T_NEW: return "T_NEW";
55 		case T_CLONE: return "T_CLONE";
56 		case T_EXIT: return "T_EXIT";
57 		case T_IF: return "T_IF";
58 		case T_ELSEIF: return "T_ELSEIF";
59 		case T_ELSE: return "T_ELSE";
60 		case T_ENDIF: return "T_ENDIF";
61 		case T_ECHO: return "T_ECHO";
62 		case T_DO: return "T_DO";
63 		case T_WHILE: return "T_WHILE";
64 		case T_ENDWHILE: return "T_ENDWHILE";
65 		case T_FOR: return "T_FOR";
66 		case T_ENDFOR: return "T_ENDFOR";
67 		case T_FOREACH: return "T_FOREACH";
68 		case T_ENDFOREACH: return "T_ENDFOREACH";
69 		case T_DECLARE: return "T_DECLARE";
70 		case T_ENDDECLARE: return "T_ENDDECLARE";
71 		case T_AS: return "T_AS";
72 		case T_SWITCH: return "T_SWITCH";
73 		case T_ENDSWITCH: return "T_ENDSWITCH";
74 		case T_CASE: return "T_CASE";
75 		case T_DEFAULT: return "T_DEFAULT";
76 		case T_MATCH: return "T_MATCH";
77 		case T_BREAK: return "T_BREAK";
78 		case T_CONTINUE: return "T_CONTINUE";
79 		case T_GOTO: return "T_GOTO";
80 		case T_FUNCTION: return "T_FUNCTION";
81 		case T_FN: return "T_FN";
82 		case T_CONST: return "T_CONST";
83 		case T_RETURN: return "T_RETURN";
84 		case T_TRY: return "T_TRY";
85 		case T_CATCH: return "T_CATCH";
86 		case T_FINALLY: return "T_FINALLY";
87 		case T_THROW: return "T_THROW";
88 		case T_USE: return "T_USE";
89 		case T_INSTEADOF: return "T_INSTEADOF";
90 		case T_GLOBAL: return "T_GLOBAL";
91 		case T_STATIC: return "T_STATIC";
92 		case T_ABSTRACT: return "T_ABSTRACT";
93 		case T_FINAL: return "T_FINAL";
94 		case T_PRIVATE: return "T_PRIVATE";
95 		case T_PROTECTED: return "T_PROTECTED";
96 		case T_PUBLIC: return "T_PUBLIC";
97 		case T_READONLY: return "T_READONLY";
98 		case T_VAR: return "T_VAR";
99 		case T_UNSET: return "T_UNSET";
100 		case T_ISSET: return "T_ISSET";
101 		case T_EMPTY: return "T_EMPTY";
102 		case T_HALT_COMPILER: return "T_HALT_COMPILER";
103 		case T_CLASS: return "T_CLASS";
104 		case T_TRAIT: return "T_TRAIT";
105 		case T_INTERFACE: return "T_INTERFACE";
106 		case T_ENUM: return "T_ENUM";
107 		case T_EXTENDS: return "T_EXTENDS";
108 		case T_IMPLEMENTS: return "T_IMPLEMENTS";
109 		case T_NAMESPACE: return "T_NAMESPACE";
110 		case T_LIST: return "T_LIST";
111 		case T_ARRAY: return "T_ARRAY";
112 		case T_CALLABLE: return "T_CALLABLE";
113 		case T_LINE: return "T_LINE";
114 		case T_FILE: return "T_FILE";
115 		case T_DIR: return "T_DIR";
116 		case T_CLASS_C: return "T_CLASS_C";
117 		case T_TRAIT_C: return "T_TRAIT_C";
118 		case T_METHOD_C: return "T_METHOD_C";
119 		case T_FUNC_C: return "T_FUNC_C";
120 		case T_NS_C: return "T_NS_C";
121 		case T_ATTRIBUTE: return "T_ATTRIBUTE";
122 		case T_PLUS_EQUAL: return "T_PLUS_EQUAL";
123 		case T_MINUS_EQUAL: return "T_MINUS_EQUAL";
124 		case T_MUL_EQUAL: return "T_MUL_EQUAL";
125 		case T_DIV_EQUAL: return "T_DIV_EQUAL";
126 		case T_CONCAT_EQUAL: return "T_CONCAT_EQUAL";
127 		case T_MOD_EQUAL: return "T_MOD_EQUAL";
128 		case T_AND_EQUAL: return "T_AND_EQUAL";
129 		case T_OR_EQUAL: return "T_OR_EQUAL";
130 		case T_XOR_EQUAL: return "T_XOR_EQUAL";
131 		case T_SL_EQUAL: return "T_SL_EQUAL";
132 		case T_SR_EQUAL: return "T_SR_EQUAL";
133 		case T_COALESCE_EQUAL: return "T_COALESCE_EQUAL";
134 		case T_BOOLEAN_OR: return "T_BOOLEAN_OR";
135 		case T_BOOLEAN_AND: return "T_BOOLEAN_AND";
136 		case T_IS_EQUAL: return "T_IS_EQUAL";
137 		case T_IS_NOT_EQUAL: return "T_IS_NOT_EQUAL";
138 		case T_IS_IDENTICAL: return "T_IS_IDENTICAL";
139 		case T_IS_NOT_IDENTICAL: return "T_IS_NOT_IDENTICAL";
140 		case T_IS_SMALLER_OR_EQUAL: return "T_IS_SMALLER_OR_EQUAL";
141 		case T_IS_GREATER_OR_EQUAL: return "T_IS_GREATER_OR_EQUAL";
142 		case T_SPACESHIP: return "T_SPACESHIP";
143 		case T_SL: return "T_SL";
144 		case T_SR: return "T_SR";
145 		case T_INC: return "T_INC";
146 		case T_DEC: return "T_DEC";
147 		case T_INT_CAST: return "T_INT_CAST";
148 		case T_DOUBLE_CAST: return "T_DOUBLE_CAST";
149 		case T_STRING_CAST: return "T_STRING_CAST";
150 		case T_ARRAY_CAST: return "T_ARRAY_CAST";
151 		case T_OBJECT_CAST: return "T_OBJECT_CAST";
152 		case T_BOOL_CAST: return "T_BOOL_CAST";
153 		case T_UNSET_CAST: return "T_UNSET_CAST";
154 		case T_OBJECT_OPERATOR: return "T_OBJECT_OPERATOR";
155 		case T_NULLSAFE_OBJECT_OPERATOR: return "T_NULLSAFE_OBJECT_OPERATOR";
156 		case T_DOUBLE_ARROW: return "T_DOUBLE_ARROW";
157 		case T_COMMENT: return "T_COMMENT";
158 		case T_DOC_COMMENT: return "T_DOC_COMMENT";
159 		case T_OPEN_TAG: return "T_OPEN_TAG";
160 		case T_OPEN_TAG_WITH_ECHO: return "T_OPEN_TAG_WITH_ECHO";
161 		case T_CLOSE_TAG: return "T_CLOSE_TAG";
162 		case T_WHITESPACE: return "T_WHITESPACE";
163 		case T_START_HEREDOC: return "T_START_HEREDOC";
164 		case T_END_HEREDOC: return "T_END_HEREDOC";
165 		case T_DOLLAR_OPEN_CURLY_BRACES: return "T_DOLLAR_OPEN_CURLY_BRACES";
166 		case T_CURLY_OPEN: return "T_CURLY_OPEN";
167 		case T_PAAMAYIM_NEKUDOTAYIM: return "T_DOUBLE_COLON";
168 		case T_NS_SEPARATOR: return "T_NS_SEPARATOR";
169 		case T_ELLIPSIS: return "T_ELLIPSIS";
170 		case T_COALESCE: return "T_COALESCE";
171 		case T_POW: return "T_POW";
172 		case T_POW_EQUAL: return "T_POW_EQUAL";
173 		case T_AMPERSAND_FOLLOWED_BY_VAR_OR_VARARG: return "T_AMPERSAND_FOLLOWED_BY_VAR_OR_VARARG";
174 		case T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG: return "T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG";
175 		case T_BAD_CHARACTER: return "T_BAD_CHARACTER";
176 
177 	}
178 	return NULL;
179 }
180 
181