gstreamer: Update from 1.15+ git master
[vala-gnome.git] / vala / valagenietokentype.vala
blobbc7bea24a1a27df5e8d36a8ee30446e3b32f4db8
1 /* valagenietokentype.vala
3 * Copyright (C) 2008-2012 Jamie McCracken, Jürg Billeter
4 * Based on code by Jürg Billeter
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20 * Author:
21 * Jamie McCracken jamiemcc gnome org
24 using GLib;
26 public enum Vala.Genie.TokenType {
27 NONE,
28 ABSTRACT,
29 ARRAY,
30 AS,
31 ASSERT,
32 ASSIGN,
33 ASSIGN_ADD,
34 ASSIGN_BITWISE_AND,
35 ASSIGN_BITWISE_OR,
36 ASSIGN_BITWISE_XOR,
37 ASSIGN_DIV,
38 ASSIGN_MUL,
39 ASSIGN_PERCENT,
40 ASSIGN_SHIFT_LEFT,
41 ASSIGN_SUB,
42 ASYNC,
43 BITWISE_AND,
44 BITWISE_OR,
45 BREAK,
46 CARRET,
47 CASE,
48 CHARACTER_LITERAL,
49 CLASS,
50 CLOSE_BRACE,
51 CLOSE_BRACKET,
52 CLOSE_PARENS,
53 CLOSE_REGEX_LITERAL,
54 CLOSE_TEMPLATE,
55 COLON,
56 COMMA,
57 CONST,
58 CONSTRUCT,
59 CONTINUE,
60 DEDENT,
61 DEF,
62 DEFAULT,
63 DELEGATE,
64 DELETE,
65 DICT,
66 DIV,
67 DO,
68 DOT,
69 DOWNTO,
70 DYNAMIC,
71 ELLIPSIS,
72 ELSE,
73 ENUM,
74 ENSURES,
75 ERRORDOMAIN,
76 EOF,
77 EOL,
78 EVENT,
79 EXCEPT,
80 EXTERN,
81 FALSE,
82 FINAL,
83 FINALLY,
84 FOR,
85 GET,
86 HASH,
87 IDENTIFIER,
88 IF,
89 IMPLEMENTS,
90 IN,
91 INDENT,
92 INIT,
93 INLINE,
94 INTEGER_LITERAL,
95 INTERFACE,
96 INTERNAL,
97 INTERR,
98 IS,
99 ISA,
100 LAMBDA,
101 LIST,
102 LOCK,
103 MINUS,
104 NAMESPACE,
105 NEW,
106 NULL,
108 OUT,
109 OP_AND,
110 OP_DEC,
111 OP_EQ,
112 OP_GE,
113 OP_GT,
114 OP_INC,
115 OP_LE,
116 OP_LT,
117 OP_NE,
118 OP_NEG,
119 OP_OR,
120 OP_PTR,
121 OP_SHIFT_LEFT,
122 OPEN_BRACE,
123 OPEN_BRACKET,
124 OPEN_PARENS,
125 OPEN_REGEX_LITERAL,
126 OPEN_TEMPLATE,
127 OVERRIDE,
128 OWNED,
129 PARAMS,
130 PASS,
131 PERCENT,
132 PLUS,
133 PRINT,
134 PRIVATE,
135 PROP,
136 PROTECTED,
137 PUBLIC,
138 RAISE,
139 RAISES,
140 READONLY,
141 REAL_LITERAL,
142 REF,
143 REGEX_LITERAL,
144 REQUIRES,
145 RETURN,
146 SEALED,
147 SEMICOLON,
148 SET,
149 SIZEOF,
150 STAR,
151 STATIC,
152 STRING_LITERAL,
153 STRUCT,
154 SUPER,
155 TEMPLATE_STRING_LITERAL,
156 THIS,
157 TILDE,
159 TRUE,
160 TRY,
161 TYPEOF,
162 UNOWNED,
163 USES,
164 VAR,
165 VERBATIM_STRING_LITERAL,
166 VIRTUAL,
167 VOID,
168 VOLATILE,
169 WEAK,
170 WHEN,
171 WHILE,
172 WRITEONLY,
173 YIELD;
175 public unowned string to_string () {
176 switch (this) {
177 case ABSTRACT: return "`abstract'";
178 case ARRAY: return "`array'";
179 case AS: return "`as'";
180 case ASSERT: return "`assert'";
181 case ASSIGN: return "`='";
182 case ASSIGN_ADD: return "`+='";
183 case ASSIGN_BITWISE_AND: return "`&='";
184 case ASSIGN_BITWISE_OR: return "`|='";
185 case ASSIGN_BITWISE_XOR: return "`^='";
186 case ASSIGN_DIV: return "`/='";
187 case ASSIGN_MUL: return "`*='";
188 case ASSIGN_PERCENT: return "`%='";
189 case ASSIGN_SHIFT_LEFT: return "`<<='";
190 case ASSIGN_SUB: return "`-='";
191 case ASYNC: return "`async'";
192 case BITWISE_AND: return "`&'";
193 case BITWISE_OR: return "`|'";
194 case BREAK: return "`break'";
195 case CARRET: return "`^'";
196 case CASE: return "`case'";
197 case CHARACTER_LITERAL: return "character literal";
198 case CLASS: return "`class'";
199 case CLOSE_BRACE: return "`}'";
200 case CLOSE_BRACKET: return "`]'";
201 case CLOSE_PARENS: return "`)'";
202 case CLOSE_REGEX_LITERAL: return "`/'";
203 case CLOSE_TEMPLATE: return "close template";
204 case COLON: return "`:'";
205 case COMMA: return "`,'";
206 case CONST: return "`const'";
207 case CONSTRUCT: return "`construct'";
208 case CONTINUE: return "`continue'";
209 case DEDENT: return "`dedent'";
210 case DEF: return "`def'";
211 case DEFAULT: return "`default'";
212 case DELEGATE: return "`delegate'";
213 case DELETE: return "`delete'";
214 case DICT: return "`dict'";
215 case DIV: return "`/'";
216 case DO: return "`do'";
217 case DOT: return "`.'";
218 case DOWNTO: return "`downto'";
219 case DYNAMIC: return "`dynamic'";
220 case ELLIPSIS: return "`...'";
221 case ELSE: return "`else'";
222 case ENUM: return "`enum'";
223 case ENSURES: return "`ensures'";
224 case ERRORDOMAIN: return "`errordomain'";
225 case EOF: return "end of file";
226 case EOL: return "end of line";
227 case EVENT: return "event";
228 case EXCEPT: return "`except'";
229 case EXTERN: return "`extern'";
230 case FALSE: return "`false'";
231 case FINAL: return "`final'";
232 case FINALLY: return "`finally'";
233 case FOR: return "`for'";
234 case GET: return "`get'";
235 case HASH: return "`hash'";
236 case IDENTIFIER: return "identifier";
237 case IF: return "`if'";
238 case IMPLEMENTS: return "`implements'";
239 case IN: return "`in'";
240 case INDENT: return "`tab indent'";
241 case INIT: return "`init'";
242 case INLINE: return "`inline'";
243 case INTEGER_LITERAL: return "integer literal";
244 case INTERFACE: return "`interface'";
245 case INTERNAL: return "`internal'";
246 case INTERR: return "`?'";
247 case IS: return "`is'";
248 case ISA: return "`isa'";
249 case LAMBDA: return "`=>'";
250 case LIST: return "`list'";
251 case LOCK: return "`lock'";
252 case MINUS: return "`-'";
253 case NAMESPACE: return "`namespace'";
254 case NEW: return "`new'";
255 case NULL: return "`null'";
256 case OF: return "`of'";
257 case OUT: return "`out'";
258 case OP_AND: return "`and'";
259 case OP_DEC: return "`--'";
260 case OP_EQ: return "`=='";
261 case OP_GE: return "`>='";
262 case OP_GT: return "`>'";
263 case OP_INC: return "`++'";
264 case OP_LE: return "`<='";
265 case OP_LT: return "`<'";
266 case OP_NE: return "`!='";
267 case OP_NEG: return "`!'";
268 case OP_OR: return "`or'";
269 case OP_PTR: return "`->'";
270 case OP_SHIFT_LEFT: return "`<<'";
271 case OPEN_BRACE: return "`{'";
272 case OPEN_BRACKET: return "`['";
273 case OPEN_PARENS: return "`('";
274 case OPEN_REGEX_LITERAL: return "`/'";
275 case OPEN_TEMPLATE: return "open template";
276 case OVERRIDE: return "`override'";
277 case OWNED: return "`owned'";
278 case PARAMS: return "`params'";
279 case PASS: return "`pass'";
280 case PERCENT: return "`%'";
281 case PLUS: return "`+'";
282 case PRINT: return "`print'";
283 case PRIVATE: return "`private'";
284 case PROP: return "`prop'";
285 case PROTECTED: return "`protected'";
286 case PUBLIC: return "`public'";
287 case RAISE: return "`raise'";
288 case RAISES: return "`raises'";
289 case READONLY: return "`readonly'";
290 case REAL_LITERAL: return "real literal";
291 case REF: return "`ref'";
292 case REGEX_LITERAL: return "regex literal";
293 case REQUIRES: return "`requires'";
294 case RETURN: return "`return'";
295 case SEALED: return "`sealed'";
296 case SEMICOLON: return "`;'";
297 case SET: return "`set'";
298 case SIZEOF: return "`sizeof'";
299 case STAR: return "`*'";
300 case STATIC: return "`static'";
301 case STRING_LITERAL: return "string literal";
302 case STRUCT: return "`struct'";
303 case SUPER: return "`super'";
304 case TEMPLATE_STRING_LITERAL: return "template string literal";
305 case THIS: return "`self'";
306 case TILDE: return "`~'";
307 case TO: return "`to'";
308 case TRUE: return "`true'";
309 case TRY: return "`try'";
310 case TYPEOF: return "`typeof'";
311 case UNOWNED: return "`unowned'";
312 case USES: return "`uses'";
313 case VAR: return "`var'";
314 case VERBATIM_STRING_LITERAL: return "verbatim string literal";
315 case VIRTUAL: return "`virtual'";
316 case VOID: return "`void'";
317 case VOLATILE: return "`volatile'";
318 case WEAK: return "`weak'";
319 case WHEN: return "`when'";
320 case WHILE: return "`while'";
321 case WRITEONLY: return "`writeonly'";
322 case YIELD: return "`yield'";
323 default: return "unknown token";