fancy 0.5.0 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (111) hide show
  1. data/AUTHORS +2 -0
  2. data/README.md +6 -1
  3. data/bin/fancy +6 -0
  4. data/bin/ifancy +44 -3
  5. data/boot/fancy_ext/module.rb +4 -0
  6. data/boot/fancy_ext/object.rb +4 -0
  7. data/boot/rbx-compiler/compiler/ast/block.rb +29 -1
  8. data/boot/rbx-compiler/compiler/ast/identifier.rb +6 -0
  9. data/boot/rbx-compiler/compiler/ast/message_send.rb +1 -0
  10. data/boot/rbx-compiler/parser/fancy_parser.bundle +0 -0
  11. data/boot/rbx-compiler/parser/lexer.lex +2 -0
  12. data/boot/rbx-compiler/parser/parser.rb +6 -0
  13. data/boot/rbx-compiler/parser/parser.y +14 -1
  14. data/doc/api/fancy.jsonp +1 -1
  15. data/doc/features.md +24 -0
  16. data/examples/99bottles.fy +5 -0
  17. data/examples/conditions_exceptions.fy +9 -0
  18. data/examples/conditions_parsing.fy +68 -0
  19. data/examples/greeter.fy +9 -0
  20. data/examples/html_generator.fy +59 -29
  21. data/examples/webserver/webserver.fy +8 -11
  22. data/lib/argv.fy +6 -0
  23. data/lib/array.fy +17 -35
  24. data/lib/block.fy +82 -1
  25. data/lib/boot.fy +4 -2
  26. data/lib/compiler.fy +2 -2
  27. data/lib/compiler/ast/block.fy +24 -20
  28. data/lib/compiler/ast/message_send.fy +11 -0
  29. data/lib/contracts.fy +60 -0
  30. data/lib/dynamic_slot_object.fy +61 -0
  31. data/lib/enumerable.fy +432 -394
  32. data/lib/enumerator.fy +152 -150
  33. data/lib/fdoc.fy +4 -17
  34. data/lib/fiber.fy +4 -10
  35. data/lib/file.fy +33 -25
  36. data/lib/future.fy +59 -5
  37. data/lib/hash.fy +54 -1
  38. data/lib/html.fy +107 -0
  39. data/lib/kvo.fy +173 -0
  40. data/lib/main.fy +6 -2
  41. data/lib/message_sink.fy +19 -0
  42. data/lib/number.fy +48 -0
  43. data/lib/object.fy +65 -13
  44. data/lib/package.fy +12 -2
  45. data/lib/package/dependency.fy +13 -0
  46. data/lib/package/dependency_installer.fy +27 -0
  47. data/lib/package/installer.fy +4 -10
  48. data/lib/package/uninstaller.fy +1 -3
  49. data/lib/parser/ext/lexer.lex +8 -3
  50. data/lib/parser/ext/parser.y +4 -1
  51. data/lib/parser/methods.fy +7 -3
  52. data/lib/range.fy +1 -1
  53. data/lib/rbx.fy +2 -1
  54. data/lib/rbx/array.fy +28 -12
  55. data/lib/rbx/bignum.fy +1 -1
  56. data/lib/rbx/block.fy +27 -0
  57. data/lib/rbx/console.fy +6 -6
  58. data/lib/rbx/date.fy +6 -1
  59. data/lib/rbx/documentation.fy +8 -3
  60. data/lib/rbx/exception.fy +5 -0
  61. data/lib/rbx/file.fy +40 -7
  62. data/lib/rbx/fixnum.fy +12 -1
  63. data/lib/rbx/method.fy +9 -2
  64. data/lib/rbx/module.fy +24 -0
  65. data/lib/rbx/regexp.fy +8 -0
  66. data/lib/rbx/string.fy +23 -7
  67. data/lib/rbx/tcp_server.fy +4 -2
  68. data/lib/rbx/tcp_socket.fy +14 -0
  69. data/lib/remote_object.fy +59 -0
  70. data/lib/set.fy +15 -4
  71. data/lib/string.fy +38 -5
  72. data/lib/stringio.fy +1 -0
  73. data/lib/symbol.fy +4 -0
  74. data/lib/system.fy +22 -0
  75. data/lib/thread_pool.fy +2 -2
  76. data/lib/tuple.fy +18 -1
  77. data/lib/vars.fy +17 -0
  78. data/lib/version.fy +1 -1
  79. data/ruby_lib/fancy +6 -0
  80. data/tests/array.fy +30 -0
  81. data/tests/block.fy +106 -0
  82. data/tests/class.fy +19 -0
  83. data/tests/enumerable.fy +1 -1
  84. data/tests/enumerator.fy +5 -5
  85. data/tests/file.fy +28 -0
  86. data/tests/fixnum.fy +0 -50
  87. data/tests/future.fy +9 -24
  88. data/tests/hash.fy +35 -0
  89. data/tests/html.fy +33 -0
  90. data/tests/kvo.fy +101 -0
  91. data/tests/number.fy +75 -0
  92. data/tests/object.fy +50 -3
  93. data/tests/string.fy +19 -10
  94. data/tests/symbol.fy +5 -0
  95. data/tests/tuple.fy +7 -0
  96. data/tools/fancy-mode.el +5 -1
  97. metadata +22 -21
  98. data/boot/compiler/parser/ext/fancy_parser.bundle +0 -0
  99. data/boot/rbx-compiler/parser/Makefile +0 -156
  100. data/boot/rbx-compiler/parser/lexer.c +0 -2310
  101. data/boot/rbx-compiler/parser/lexer.h +0 -315
  102. data/boot/rbx-compiler/parser/parser.c +0 -2946
  103. data/boot/rbx-compiler/parser/parser.h +0 -151
  104. data/lib/fiber_pool.fy +0 -78
  105. data/lib/method.fy +0 -6
  106. data/lib/parser/ext/Makefile +0 -156
  107. data/lib/parser/ext/fancy_parser.bundle +0 -0
  108. data/lib/parser/ext/lexer.c +0 -2392
  109. data/lib/parser/ext/lexer.h +0 -315
  110. data/lib/parser/ext/parser.c +0 -3251
  111. data/lib/parser/ext/parser.h +0 -161
@@ -1,315 +0,0 @@
1
- #ifndef yyHEADER_H
2
- #define yyHEADER_H 1
3
- #define yyIN_HEADER 1
4
-
5
- #line 6 "lexer.h"
6
-
7
- #line 8 "lexer.h"
8
-
9
- #define YY_INT_ALIGNED short int
10
-
11
- /* A lexical scanner generated by flex */
12
-
13
- #define FLEX_SCANNER
14
- #define YY_FLEX_MAJOR_VERSION 2
15
- #define YY_FLEX_MINOR_VERSION 5
16
- #define YY_FLEX_SUBMINOR_VERSION 35
17
- #if YY_FLEX_SUBMINOR_VERSION > 0
18
- #define FLEX_BETA
19
- #endif
20
-
21
- /* First, we deal with platform-specific or compiler-specific issues. */
22
-
23
- /* begin standard C headers. */
24
- #include <stdio.h>
25
- #include <string.h>
26
- #include <errno.h>
27
- #include <stdlib.h>
28
-
29
- /* end standard C headers. */
30
-
31
- /* flex integer type definitions */
32
-
33
- #ifndef FLEXINT_H
34
- #define FLEXINT_H
35
-
36
- /* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
37
-
38
- #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
39
-
40
- /* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
41
- * if you want the limit (max/min) macros for int types.
42
- */
43
- #ifndef __STDC_LIMIT_MACROS
44
- #define __STDC_LIMIT_MACROS 1
45
- #endif
46
-
47
- #include <inttypes.h>
48
- typedef int8_t flex_int8_t;
49
- typedef uint8_t flex_uint8_t;
50
- typedef int16_t flex_int16_t;
51
- typedef uint16_t flex_uint16_t;
52
- typedef int32_t flex_int32_t;
53
- typedef uint32_t flex_uint32_t;
54
- #else
55
- typedef signed char flex_int8_t;
56
- typedef short int flex_int16_t;
57
- typedef int flex_int32_t;
58
- typedef unsigned char flex_uint8_t;
59
- typedef unsigned short int flex_uint16_t;
60
- typedef unsigned int flex_uint32_t;
61
- #endif /* ! C99 */
62
-
63
- /* Limits of integral types. */
64
- #ifndef INT8_MIN
65
- #define INT8_MIN (-128)
66
- #endif
67
- #ifndef INT16_MIN
68
- #define INT16_MIN (-32767-1)
69
- #endif
70
- #ifndef INT32_MIN
71
- #define INT32_MIN (-2147483647-1)
72
- #endif
73
- #ifndef INT8_MAX
74
- #define INT8_MAX (127)
75
- #endif
76
- #ifndef INT16_MAX
77
- #define INT16_MAX (32767)
78
- #endif
79
- #ifndef INT32_MAX
80
- #define INT32_MAX (2147483647)
81
- #endif
82
- #ifndef UINT8_MAX
83
- #define UINT8_MAX (255U)
84
- #endif
85
- #ifndef UINT16_MAX
86
- #define UINT16_MAX (65535U)
87
- #endif
88
- #ifndef UINT32_MAX
89
- #define UINT32_MAX (4294967295U)
90
- #endif
91
-
92
- #endif /* ! FLEXINT_H */
93
-
94
- #ifdef __cplusplus
95
-
96
- /* The "const" storage-class-modifier is valid. */
97
- #define YY_USE_CONST
98
-
99
- #else /* ! __cplusplus */
100
-
101
- /* C99 requires __STDC__ to be defined as 1. */
102
- #if defined (__STDC__)
103
-
104
- #define YY_USE_CONST
105
-
106
- #endif /* defined (__STDC__) */
107
- #endif /* ! __cplusplus */
108
-
109
- #ifdef YY_USE_CONST
110
- #define yyconst const
111
- #else
112
- #define yyconst
113
- #endif
114
-
115
- /* Size of default input buffer. */
116
- #ifndef YY_BUF_SIZE
117
- #define YY_BUF_SIZE 16384
118
- #endif
119
-
120
- #ifndef YY_TYPEDEF_YY_BUFFER_STATE
121
- #define YY_TYPEDEF_YY_BUFFER_STATE
122
- typedef struct yy_buffer_state *YY_BUFFER_STATE;
123
- #endif
124
-
125
- #ifndef YY_TYPEDEF_YY_SIZE_T
126
- #define YY_TYPEDEF_YY_SIZE_T
127
- typedef size_t yy_size_t;
128
- #endif
129
-
130
- extern yy_size_t yyleng;
131
-
132
- extern FILE *yyin, *yyout;
133
-
134
- #ifndef YY_STRUCT_YY_BUFFER_STATE
135
- #define YY_STRUCT_YY_BUFFER_STATE
136
- struct yy_buffer_state
137
- {
138
- FILE *yy_input_file;
139
-
140
- char *yy_ch_buf; /* input buffer */
141
- char *yy_buf_pos; /* current position in input buffer */
142
-
143
- /* Size of input buffer in bytes, not including room for EOB
144
- * characters.
145
- */
146
- yy_size_t yy_buf_size;
147
-
148
- /* Number of characters read into yy_ch_buf, not including EOB
149
- * characters.
150
- */
151
- yy_size_t yy_n_chars;
152
-
153
- /* Whether we "own" the buffer - i.e., we know we created it,
154
- * and can realloc() it to grow it, and should free() it to
155
- * delete it.
156
- */
157
- int yy_is_our_buffer;
158
-
159
- /* Whether this is an "interactive" input source; if so, and
160
- * if we're using stdio for input, then we want to use getc()
161
- * instead of fread(), to make sure we stop fetching input after
162
- * each newline.
163
- */
164
- int yy_is_interactive;
165
-
166
- /* Whether we're considered to be at the beginning of a line.
167
- * If so, '^' rules will be active on the next match, otherwise
168
- * not.
169
- */
170
- int yy_at_bol;
171
-
172
- int yy_bs_lineno; /**< The line count. */
173
- int yy_bs_column; /**< The column count. */
174
-
175
- /* Whether to try to fill the input buffer when we reach the
176
- * end of it.
177
- */
178
- int yy_fill_buffer;
179
-
180
- int yy_buffer_status;
181
-
182
- };
183
- #endif /* !YY_STRUCT_YY_BUFFER_STATE */
184
-
185
- void yyrestart (FILE *input_file );
186
- void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer );
187
- YY_BUFFER_STATE yy_create_buffer (FILE *file,int size );
188
- void yy_delete_buffer (YY_BUFFER_STATE b );
189
- void yy_flush_buffer (YY_BUFFER_STATE b );
190
- void yypush_buffer_state (YY_BUFFER_STATE new_buffer );
191
- void yypop_buffer_state (void );
192
-
193
- YY_BUFFER_STATE yy_scan_buffer (char *base,yy_size_t size );
194
- YY_BUFFER_STATE yy_scan_string (yyconst char *yy_str );
195
- YY_BUFFER_STATE yy_scan_bytes (yyconst char *bytes,yy_size_t len );
196
-
197
- void *yyalloc (yy_size_t );
198
- void *yyrealloc (void *,yy_size_t );
199
- void yyfree (void * );
200
-
201
- extern int yylineno;
202
-
203
- extern char *yytext;
204
- #define yytext_ptr yytext
205
-
206
- #ifdef YY_HEADER_EXPORT_START_CONDITIONS
207
- #define INITIAL 0
208
-
209
- #endif
210
-
211
- #ifndef YY_NO_UNISTD_H
212
- /* Special case for "unistd.h", since it is non-ANSI. We include it way
213
- * down here because we want the user's section 1 to have been scanned first.
214
- * The user has a chance to override it with an option.
215
- */
216
- #include <unistd.h>
217
- #endif
218
-
219
- #ifndef YY_EXTRA_TYPE
220
- #define YY_EXTRA_TYPE void *
221
- #endif
222
-
223
- /* Accessor methods to globals.
224
- These are made visible to non-reentrant scanners for convenience. */
225
-
226
- int yylex_destroy (void );
227
-
228
- int yyget_debug (void );
229
-
230
- void yyset_debug (int debug_flag );
231
-
232
- YY_EXTRA_TYPE yyget_extra (void );
233
-
234
- void yyset_extra (YY_EXTRA_TYPE user_defined );
235
-
236
- FILE *yyget_in (void );
237
-
238
- void yyset_in (FILE * in_str );
239
-
240
- FILE *yyget_out (void );
241
-
242
- void yyset_out (FILE * out_str );
243
-
244
- yy_size_t yyget_leng (void );
245
-
246
- char *yyget_text (void );
247
-
248
- int yyget_lineno (void );
249
-
250
- void yyset_lineno (int line_number );
251
-
252
- /* Macros after this point can all be overridden by user definitions in
253
- * section 1.
254
- */
255
-
256
- #ifndef YY_SKIP_YYWRAP
257
- #ifdef __cplusplus
258
- extern "C" int yywrap (void );
259
- #else
260
- extern int yywrap (void );
261
- #endif
262
- #endif
263
-
264
- #ifndef yytext_ptr
265
- static void yy_flex_strncpy (char *,yyconst char *,int );
266
- #endif
267
-
268
- #ifdef YY_NEED_STRLEN
269
- static int yy_flex_strlen (yyconst char * );
270
- #endif
271
-
272
- #ifndef YY_NO_INPUT
273
-
274
- #endif
275
-
276
- /* Amount of stuff to slurp up with each read. */
277
- #ifndef YY_READ_BUF_SIZE
278
- #define YY_READ_BUF_SIZE 8192
279
- #endif
280
-
281
- /* Number of entries by which start-condition stack grows. */
282
- #ifndef YY_START_STACK_INCR
283
- #define YY_START_STACK_INCR 25
284
- #endif
285
-
286
- /* Default declaration of generated scanner - a define so the user can
287
- * easily add parameters.
288
- */
289
- #ifndef YY_DECL
290
- #define YY_DECL_IS_OURS 1
291
-
292
- extern int yylex (void);
293
-
294
- #define YY_DECL int yylex (void)
295
- #endif /* !YY_DECL */
296
-
297
- /* yy_get_previous_state - get the state just before the EOB char was reached */
298
-
299
- #undef YY_NEW_FILE
300
- #undef YY_FLUSH_BUFFER
301
- #undef yy_set_bol
302
- #undef yy_new_buffer
303
- #undef yy_set_interactive
304
- #undef YY_DO_BEFORE_ACTION
305
-
306
- #ifdef YY_DECL_IS_OURS
307
- #undef YY_DECL_IS_OURS
308
- #undef YY_DECL
309
- #endif
310
-
311
- #line 175 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/lexer.lex"
312
-
313
- #line 314 "lexer.h"
314
- #undef yyIN_HEADER
315
- #endif /* yyHEADER_H */
@@ -1,2946 +0,0 @@
1
- /* A Bison parser, made by GNU Bison 2.3. */
2
-
3
- /* Skeleton implementation for Bison's Yacc-like parsers in C
4
-
5
- Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
6
- Free Software Foundation, Inc.
7
-
8
- This program is free software; you can redistribute it and/or modify
9
- it under the terms of the GNU General Public License as published by
10
- the Free Software Foundation; either version 2, or (at your option)
11
- any later version.
12
-
13
- This program is distributed in the hope that it will be useful,
14
- but WITHOUT ANY WARRANTY; without even the implied warranty of
15
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
- GNU General Public License for more details.
17
-
18
- You should have received a copy of the GNU General Public License
19
- along with this program; if not, write to the Free Software
20
- Foundation, Inc., 51 Franklin Street, Fifth Floor,
21
- Boston, MA 02110-1301, USA. */
22
-
23
- /* As a special exception, you may create a larger work that contains
24
- part or all of the Bison parser skeleton and distribute that work
25
- under terms of your choice, so long as that work isn't itself a
26
- parser generator using the skeleton or a modified version thereof
27
- as a parser skeleton. Alternatively, if you modify or redistribute
28
- the parser skeleton itself, you may (at your option) remove this
29
- special exception, which will cause the skeleton and the resulting
30
- Bison output files to be licensed under the GNU General Public
31
- License without this special exception.
32
-
33
- This special exception was added by the Free Software Foundation in
34
- version 2.2 of Bison. */
35
-
36
- /* C LALR(1) parser skeleton written by Richard Stallman, by
37
- simplifying the original so-called "semantic" parser. */
38
-
39
- /* All symbols defined below should begin with yy or YY, to avoid
40
- infringing on user name space. This should be done even for local
41
- variables, as they might otherwise be expanded by user macros.
42
- There are some unavoidable exceptions within include files to
43
- define necessary library symbols; they are noted "INFRINGES ON
44
- USER NAME SPACE" below. */
45
-
46
- /* Identify Bison output. */
47
- #define YYBISON 1
48
-
49
- /* Bison version. */
50
- #define YYBISON_VERSION "2.3"
51
-
52
- /* Skeleton name. */
53
- #define YYSKELETON_NAME "yacc.c"
54
-
55
- /* Pure parsers. */
56
- #define YYPURE 0
57
-
58
- /* Using locations. */
59
- #define YYLSP_NEEDED 0
60
-
61
-
62
-
63
- /* Tokens. */
64
- #ifndef YYTOKENTYPE
65
- # define YYTOKENTYPE
66
- /* Put the tokens into the symbol table, so that GDB and other debuggers
67
- know about them. */
68
- enum yytokentype {
69
- LPAREN = 258,
70
- RPAREN = 259,
71
- LCURLY = 260,
72
- RCURLY = 261,
73
- LBRACKET = 262,
74
- RBRACKET = 263,
75
- LEFTHASH = 264,
76
- RIGHTHASH = 265,
77
- STAB = 266,
78
- ARROW = 267,
79
- THIN_ARROW = 268,
80
- COMMA = 269,
81
- SEMI = 270,
82
- NL = 271,
83
- COLON = 272,
84
- RETURN_LOCAL = 273,
85
- RETURN = 274,
86
- TRY = 275,
87
- CATCH = 276,
88
- FINALLY = 277,
89
- RETRY = 278,
90
- SUPER = 279,
91
- CLASS = 280,
92
- DEF = 281,
93
- DOT = 282,
94
- DOLLAR = 283,
95
- EQUALS = 284,
96
- MATCH = 285,
97
- CASE = 286,
98
- IDENTIFIER = 287,
99
- RUBY_SEND_OPEN = 288,
100
- RUBY_OPER_OPEN = 289,
101
- CONSTANT = 290,
102
- INTEGER_LITERAL = 291,
103
- HEX_LITERAL = 292,
104
- OCT_LITERAL = 293,
105
- BIN_LITERAL = 294,
106
- DOUBLE_LITERAL = 295,
107
- STRING_LITERAL = 296,
108
- MULTI_STRING_LITERAL = 297,
109
- SYMBOL_LITERAL = 298,
110
- REGEX_LITERAL = 299,
111
- OPERATOR = 300
112
- };
113
- #endif
114
- /* Tokens. */
115
- #define LPAREN 258
116
- #define RPAREN 259
117
- #define LCURLY 260
118
- #define RCURLY 261
119
- #define LBRACKET 262
120
- #define RBRACKET 263
121
- #define LEFTHASH 264
122
- #define RIGHTHASH 265
123
- #define STAB 266
124
- #define ARROW 267
125
- #define THIN_ARROW 268
126
- #define COMMA 269
127
- #define SEMI 270
128
- #define NL 271
129
- #define COLON 272
130
- #define RETURN_LOCAL 273
131
- #define RETURN 274
132
- #define TRY 275
133
- #define CATCH 276
134
- #define FINALLY 277
135
- #define RETRY 278
136
- #define SUPER 279
137
- #define CLASS 280
138
- #define DEF 281
139
- #define DOT 282
140
- #define DOLLAR 283
141
- #define EQUALS 284
142
- #define MATCH 285
143
- #define CASE 286
144
- #define IDENTIFIER 287
145
- #define RUBY_SEND_OPEN 288
146
- #define RUBY_OPER_OPEN 289
147
- #define CONSTANT 290
148
- #define INTEGER_LITERAL 291
149
- #define HEX_LITERAL 292
150
- #define OCT_LITERAL 293
151
- #define BIN_LITERAL 294
152
- #define DOUBLE_LITERAL 295
153
- #define STRING_LITERAL 296
154
- #define MULTI_STRING_LITERAL 297
155
- #define SYMBOL_LITERAL 298
156
- #define REGEX_LITERAL 299
157
- #define OPERATOR 300
158
-
159
-
160
-
161
-
162
- /* Copy the first part of user declarations. */
163
- #line 1 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
164
-
165
- #include "ruby.h"
166
-
167
- int yyerror(VALUE, char *s);
168
- int yylex(VALUE);
169
-
170
- VALUE fy_terminal_node(VALUE, char *);
171
- VALUE fy_terminal_node_from(VALUE, char *, char*);
172
-
173
- extern int yylineno;
174
- extern char *yytext;
175
-
176
-
177
-
178
- /* Enabling traces. */
179
- #ifndef YYDEBUG
180
- # define YYDEBUG 0
181
- #endif
182
-
183
- /* Enabling verbose error messages. */
184
- #ifdef YYERROR_VERBOSE
185
- # undef YYERROR_VERBOSE
186
- # define YYERROR_VERBOSE 1
187
- #else
188
- # define YYERROR_VERBOSE 0
189
- #endif
190
-
191
- /* Enabling the token table. */
192
- #ifndef YYTOKEN_TABLE
193
- # define YYTOKEN_TABLE 0
194
- #endif
195
-
196
- #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
197
- typedef union YYSTYPE
198
- #line 18 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
199
- {
200
- VALUE object;
201
- ID symbol;
202
- }
203
- /* Line 193 of yacc.c. */
204
- #line 205 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.c"
205
- YYSTYPE;
206
- # define yystype YYSTYPE /* obsolescent; will be withdrawn */
207
- # define YYSTYPE_IS_DECLARED 1
208
- # define YYSTYPE_IS_TRIVIAL 1
209
- #endif
210
-
211
-
212
-
213
- /* Copy the second part of user declarations. */
214
-
215
-
216
- /* Line 216 of yacc.c. */
217
- #line 218 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.c"
218
-
219
- #ifdef short
220
- # undef short
221
- #endif
222
-
223
- #ifdef YYTYPE_UINT8
224
- typedef YYTYPE_UINT8 yytype_uint8;
225
- #else
226
- typedef unsigned char yytype_uint8;
227
- #endif
228
-
229
- #ifdef YYTYPE_INT8
230
- typedef YYTYPE_INT8 yytype_int8;
231
- #elif (defined __STDC__ || defined __C99__FUNC__ \
232
- || defined __cplusplus || defined _MSC_VER)
233
- typedef signed char yytype_int8;
234
- #else
235
- typedef short int yytype_int8;
236
- #endif
237
-
238
- #ifdef YYTYPE_UINT16
239
- typedef YYTYPE_UINT16 yytype_uint16;
240
- #else
241
- typedef unsigned short int yytype_uint16;
242
- #endif
243
-
244
- #ifdef YYTYPE_INT16
245
- typedef YYTYPE_INT16 yytype_int16;
246
- #else
247
- typedef short int yytype_int16;
248
- #endif
249
-
250
- #ifndef YYSIZE_T
251
- # ifdef __SIZE_TYPE__
252
- # define YYSIZE_T __SIZE_TYPE__
253
- # elif defined size_t
254
- # define YYSIZE_T size_t
255
- # elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \
256
- || defined __cplusplus || defined _MSC_VER)
257
- # include <stddef.h> /* INFRINGES ON USER NAME SPACE */
258
- # define YYSIZE_T size_t
259
- # else
260
- # define YYSIZE_T unsigned int
261
- # endif
262
- #endif
263
-
264
- #define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
265
-
266
- #ifndef YY_
267
- # if defined YYENABLE_NLS && YYENABLE_NLS
268
- # if ENABLE_NLS
269
- # include <libintl.h> /* INFRINGES ON USER NAME SPACE */
270
- # define YY_(msgid) dgettext ("bison-runtime", msgid)
271
- # endif
272
- # endif
273
- # ifndef YY_
274
- # define YY_(msgid) msgid
275
- # endif
276
- #endif
277
-
278
- /* Suppress unused-variable warnings by "using" E. */
279
- #if ! defined lint || defined __GNUC__
280
- # define YYUSE(e) ((void) (e))
281
- #else
282
- # define YYUSE(e) /* empty */
283
- #endif
284
-
285
- /* Identity function, used to suppress warnings about constant conditions. */
286
- #ifndef lint
287
- # define YYID(n) (n)
288
- #else
289
- #if (defined __STDC__ || defined __C99__FUNC__ \
290
- || defined __cplusplus || defined _MSC_VER)
291
- static int
292
- YYID (int i)
293
- #else
294
- static int
295
- YYID (i)
296
- int i;
297
- #endif
298
- {
299
- return i;
300
- }
301
- #endif
302
-
303
- #if ! defined yyoverflow || YYERROR_VERBOSE
304
-
305
- /* The parser invokes alloca or malloc; define the necessary symbols. */
306
-
307
- # ifdef YYSTACK_USE_ALLOCA
308
- # if YYSTACK_USE_ALLOCA
309
- # ifdef __GNUC__
310
- # define YYSTACK_ALLOC __builtin_alloca
311
- # elif defined __BUILTIN_VA_ARG_INCR
312
- # include <alloca.h> /* INFRINGES ON USER NAME SPACE */
313
- # elif defined _AIX
314
- # define YYSTACK_ALLOC __alloca
315
- # elif defined _MSC_VER
316
- # include <malloc.h> /* INFRINGES ON USER NAME SPACE */
317
- # define alloca _alloca
318
- # else
319
- # define YYSTACK_ALLOC alloca
320
- # if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
321
- || defined __cplusplus || defined _MSC_VER)
322
- # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
323
- # ifndef _STDLIB_H
324
- # define _STDLIB_H 1
325
- # endif
326
- # endif
327
- # endif
328
- # endif
329
- # endif
330
-
331
- # ifdef YYSTACK_ALLOC
332
- /* Pacify GCC's `empty if-body' warning. */
333
- # define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0))
334
- # ifndef YYSTACK_ALLOC_MAXIMUM
335
- /* The OS might guarantee only one guard page at the bottom of the stack,
336
- and a page size can be as small as 4096 bytes. So we cannot safely
337
- invoke alloca (N) if N exceeds 4096. Use a slightly smaller number
338
- to allow for a few compiler-allocated temporary stack slots. */
339
- # define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
340
- # endif
341
- # else
342
- # define YYSTACK_ALLOC YYMALLOC
343
- # define YYSTACK_FREE YYFREE
344
- # ifndef YYSTACK_ALLOC_MAXIMUM
345
- # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
346
- # endif
347
- # if (defined __cplusplus && ! defined _STDLIB_H \
348
- && ! ((defined YYMALLOC || defined malloc) \
349
- && (defined YYFREE || defined free)))
350
- # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
351
- # ifndef _STDLIB_H
352
- # define _STDLIB_H 1
353
- # endif
354
- # endif
355
- # ifndef YYMALLOC
356
- # define YYMALLOC malloc
357
- # if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
358
- || defined __cplusplus || defined _MSC_VER)
359
- void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
360
- # endif
361
- # endif
362
- # ifndef YYFREE
363
- # define YYFREE free
364
- # if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
365
- || defined __cplusplus || defined _MSC_VER)
366
- void free (void *); /* INFRINGES ON USER NAME SPACE */
367
- # endif
368
- # endif
369
- # endif
370
- #endif /* ! defined yyoverflow || YYERROR_VERBOSE */
371
-
372
-
373
- #if (! defined yyoverflow \
374
- && (! defined __cplusplus \
375
- || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
376
-
377
- /* A type that is properly aligned for any stack member. */
378
- union yyalloc
379
- {
380
- yytype_int16 yyss;
381
- YYSTYPE yyvs;
382
- };
383
-
384
- /* The size of the maximum gap between one aligned stack and the next. */
385
- # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
386
-
387
- /* The size of an array large to enough to hold all stacks, each with
388
- N elements. */
389
- # define YYSTACK_BYTES(N) \
390
- ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \
391
- + YYSTACK_GAP_MAXIMUM)
392
-
393
- /* Copy COUNT objects from FROM to TO. The source and destination do
394
- not overlap. */
395
- # ifndef YYCOPY
396
- # if defined __GNUC__ && 1 < __GNUC__
397
- # define YYCOPY(To, From, Count) \
398
- __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
399
- # else
400
- # define YYCOPY(To, From, Count) \
401
- do \
402
- { \
403
- YYSIZE_T yyi; \
404
- for (yyi = 0; yyi < (Count); yyi++) \
405
- (To)[yyi] = (From)[yyi]; \
406
- } \
407
- while (YYID (0))
408
- # endif
409
- # endif
410
-
411
- /* Relocate STACK from its old location to the new one. The
412
- local variables YYSIZE and YYSTACKSIZE give the old and new number of
413
- elements in the stack, and YYPTR gives the new location of the
414
- stack. Advance YYPTR to a properly aligned location for the next
415
- stack. */
416
- # define YYSTACK_RELOCATE(Stack) \
417
- do \
418
- { \
419
- YYSIZE_T yynewbytes; \
420
- YYCOPY (&yyptr->Stack, Stack, yysize); \
421
- Stack = &yyptr->Stack; \
422
- yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
423
- yyptr += yynewbytes / sizeof (*yyptr); \
424
- } \
425
- while (YYID (0))
426
-
427
- #endif
428
-
429
- /* YYFINAL -- State number of the termination state. */
430
- #define YYFINAL 98
431
- /* YYLAST -- Last index in YYTABLE. */
432
- #define YYLAST 1120
433
-
434
- /* YYNTOKENS -- Number of terminals. */
435
- #define YYNTOKENS 46
436
- /* YYNNTS -- Number of nonterminals. */
437
- #define YYNNTS 72
438
- /* YYNRULES -- Number of rules. */
439
- #define YYNRULES 169
440
- /* YYNRULES -- Number of states. */
441
- #define YYNSTATES 281
442
-
443
- /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
444
- #define YYUNDEFTOK 2
445
- #define YYMAXUTOK 300
446
-
447
- #define YYTRANSLATE(YYX) \
448
- ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
449
-
450
- /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */
451
- static const yytype_uint8 yytranslate[] =
452
- {
453
- 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
454
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
455
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
456
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
457
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
458
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
459
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
460
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
461
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
462
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
463
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
464
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
465
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
466
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
467
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
468
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
469
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
470
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
471
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
472
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
473
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
474
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
475
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
476
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
477
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
478
- 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
479
- 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
480
- 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
481
- 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
482
- 35, 36, 37, 38, 39, 40, 41, 42, 43, 44,
483
- 45
484
- };
485
-
486
- #if YYDEBUG
487
- /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
488
- YYRHS. */
489
- static const yytype_uint16 yyprhs[] =
490
- {
491
- 0, 0, 3, 4, 6, 8, 10, 13, 15, 18,
492
- 19, 21, 23, 25, 27, 30, 33, 36, 42, 46,
493
- 48, 50, 52, 54, 56, 58, 60, 62, 64, 66,
494
- 68, 70, 72, 74, 76, 82, 86, 91, 93, 97,
495
- 99, 101, 103, 105, 107, 109, 111, 113, 117, 120,
496
- 122, 125, 127, 129, 131, 133, 136, 138, 142, 145,
497
- 151, 156, 158, 160, 162, 164, 166, 168, 172, 174,
498
- 177, 180, 189, 191, 195, 199, 202, 206, 209, 214,
499
- 218, 223, 227, 232, 238, 246, 252, 259, 268, 271,
500
- 274, 276, 278, 280, 284, 287, 290, 294, 296, 299,
501
- 303, 309, 314, 321, 325, 329, 334, 339, 345, 347,
502
- 351, 353, 356, 361, 365, 368, 372, 378, 380, 383,
503
- 385, 388, 389, 392, 394, 396, 398, 400, 402, 404,
504
- 406, 408, 410, 412, 414, 416, 418, 420, 422, 424,
505
- 426, 428, 430, 432, 434, 436, 438, 444, 446, 451,
506
- 454, 458, 464, 468, 470, 476, 480, 487, 489, 491,
507
- 493, 496, 498, 502, 508, 517, 525, 527, 530, 535
508
- };
509
-
510
- /* YYRHS -- A `-1'-separated list of the rules' RHS. */
511
- static const yytype_int8 yyrhs[] =
512
- {
513
- 47, 0, -1, -1, 52, -1, 49, -1, 15, -1,
514
- 48, 48, -1, 16, -1, 49, 16, -1, -1, 49,
515
- -1, 54, -1, 55, -1, 51, -1, 52, 51, -1,
516
- 48, 52, -1, 52, 48, -1, 5, 50, 52, 50,
517
- 6, -1, 5, 50, 6, -1, 56, -1, 63, -1,
518
- 64, -1, 70, -1, 65, -1, 90, -1, 115, -1,
519
- 81, -1, 86, -1, 84, -1, 87, -1, 103, -1,
520
- 61, -1, 24, -1, 23, -1, 3, 50, 55, 50,
521
- 4, -1, 55, 27, 50, -1, 61, 29, 50, 55,
522
- -1, 57, -1, 62, 29, 105, -1, 45, -1, 35,
523
- -1, 32, -1, 30, -1, 25, -1, 66, -1, 60,
524
- -1, 61, -1, 62, 14, 61, -1, 18, 55, -1,
525
- 18, -1, 19, 55, -1, 19, -1, 68, -1, 69,
526
- -1, 59, -1, 66, 59, -1, 26, -1, 25, 66,
527
- 53, -1, 25, 66, -1, 25, 66, 17, 66, 53,
528
- -1, 25, 66, 17, 66, -1, 75, -1, 76, -1,
529
- 77, -1, 78, -1, 79, -1, 80, -1, 60, 17,
530
- 60, -1, 71, -1, 72, 71, -1, 72, 74, -1,
531
- 60, 17, 60, 3, 50, 55, 50, 4, -1, 73,
532
- -1, 74, 50, 73, -1, 67, 72, 53, -1, 67,
533
- 72, -1, 67, 60, 53, -1, 67, 60, -1, 67,
534
- 61, 72, 53, -1, 67, 61, 72, -1, 67, 61,
535
- 60, 53, -1, 67, 61, 60, -1, 67, 58, 60,
536
- 53, -1, 67, 7, 60, 8, 53, -1, 67, 7,
537
- 60, 8, 17, 60, 53, -1, 67, 61, 58, 60,
538
- 53, -1, 67, 61, 7, 60, 8, 53, -1, 67,
539
- 61, 7, 60, 8, 17, 60, 53, -1, 55, 60,
540
- -1, 55, 88, -1, 88, -1, 33, -1, 34, -1,
541
- 55, 82, 85, -1, 82, 85, -1, 4, 108, -1,
542
- 105, 4, 108, -1, 4, -1, 105, 4, -1, 55,
543
- 58, 89, -1, 55, 58, 27, 50, 89, -1, 55,
544
- 7, 55, 8, -1, 55, 7, 55, 8, 17, 89,
545
- -1, 55, 83, 85, -1, 60, 17, 89, -1, 60,
546
- 17, 50, 89, -1, 88, 60, 17, 89, -1, 88,
547
- 60, 17, 50, 89, -1, 61, -1, 3, 55, 4,
548
- -1, 103, -1, 28, 55, -1, 20, 53, 93, 94,
549
- -1, 20, 53, 92, -1, 21, 53, -1, 21, 55,
550
- 53, -1, 21, 55, 12, 60, 53, -1, 91, -1,
551
- 92, 91, -1, 91, -1, 93, 91, -1, -1, 22,
552
- 53, -1, 36, -1, 40, -1, 41, -1, 42, -1,
553
- 43, -1, 44, -1, 37, -1, 38, -1, 39, -1,
554
- 95, -1, 100, -1, 101, -1, 102, -1, 96, -1,
555
- 97, -1, 98, -1, 107, -1, 104, -1, 99, -1,
556
- 108, -1, 109, -1, 110, -1, 106, -1, 7, 50,
557
- 105, 50, 8, -1, 55, -1, 105, 14, 50, 55,
558
- -1, 105, 14, -1, 7, 50, 8, -1, 9, 50,
559
- 114, 50, 10, -1, 9, 50, 10, -1, 53, -1,
560
- 11, 111, 11, 50, 53, -1, 3, 105, 4, -1,
561
- 3, 55, 27, 27, 55, 4, -1, 113, -1, 112,
562
- -1, 60, -1, 112, 60, -1, 60, -1, 113, 14,
563
- 60, -1, 55, 50, 12, 50, 55, -1, 114, 14,
564
- 50, 55, 50, 12, 50, 55, -1, 30, 55, 5,
565
- 50, 116, 50, 6, -1, 117, -1, 116, 117, -1,
566
- 31, 55, 13, 52, -1, 31, 55, 13, 11, 111,
567
- 11, 52, -1
568
- };
569
-
570
- /* YYRLINE[YYN] -- source line where rule number YYN was defined. */
571
- static const yytype_uint16 yyrline[] =
572
- {
573
- 0, 152, 152, 153, 158, 159, 160, 163, 164, 167,
574
- 168, 171, 172, 175, 178, 181, 184, 189, 192, 197,
575
- 198, 199, 202, 203, 204, 205, 206, 207, 208, 209,
576
- 210, 211, 212, 213, 214, 217, 222, 225, 228, 233,
577
- 238, 243, 246, 249, 254, 255, 258, 261, 266, 269,
578
- 274, 277, 282, 283, 286, 289, 294, 297, 300, 305,
579
- 308, 313, 314, 315, 316, 317, 318, 321, 326, 329,
580
- 332, 337, 342, 345, 350, 353, 359, 362, 368, 371,
581
- 376, 379, 384, 387, 391, 397, 400, 404, 410, 413,
582
- 416, 425, 429, 434, 437, 447, 450, 453, 456, 461,
583
- 464, 467, 471, 477, 483, 486, 489, 492, 497, 500,
584
- 503, 506, 511, 514, 519, 522, 525, 530, 533, 538,
585
- 541, 544, 549, 554, 558, 562, 565, 569, 573, 578,
586
- 584, 590, 596, 597, 598, 599, 600, 601, 602, 603,
587
- 604, 605, 606, 607, 608, 611, 614, 619, 622, 625,
588
- 630, 635, 638, 643, 646, 651, 656, 661, 662, 665,
589
- 668, 673, 676, 681, 684, 689, 694, 697, 702, 705
590
- };
591
- #endif
592
-
593
- #if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
594
- /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
595
- First, the terminals, then, starting at YYNTOKENS, nonterminals. */
596
- static const char *const yytname[] =
597
- {
598
- "$end", "error", "$undefined", "LPAREN", "RPAREN", "LCURLY", "RCURLY",
599
- "LBRACKET", "RBRACKET", "LEFTHASH", "RIGHTHASH", "STAB", "ARROW",
600
- "THIN_ARROW", "COMMA", "SEMI", "NL", "COLON", "RETURN_LOCAL", "RETURN",
601
- "TRY", "CATCH", "FINALLY", "RETRY", "SUPER", "CLASS", "DEF", "DOT",
602
- "DOLLAR", "EQUALS", "MATCH", "CASE", "IDENTIFIER", "RUBY_SEND_OPEN",
603
- "RUBY_OPER_OPEN", "CONSTANT", "INTEGER_LITERAL", "HEX_LITERAL",
604
- "OCT_LITERAL", "BIN_LITERAL", "DOUBLE_LITERAL", "STRING_LITERAL",
605
- "MULTI_STRING_LITERAL", "SYMBOL_LITERAL", "REGEX_LITERAL", "OPERATOR",
606
- "$accept", "programm", "delim", "nls", "space", "code",
607
- "expression_list", "expression_block", "statement", "exp", "assignment",
608
- "multiple_assignment", "operator", "constant", "identifier",
609
- "any_identifier", "identifier_list", "return_local_statement",
610
- "return_statement", "class_def", "const_identifier", "def",
611
- "class_no_super", "class_super", "method_def", "method_arg",
612
- "method_args", "method_arg_default", "method_args_default",
613
- "method_w_args", "method_no_args", "class_method_w_args",
614
- "class_method_no_args", "operator_def", "class_operator_def",
615
- "message_send", "ruby_send_open", "ruby_oper_open", "ruby_send",
616
- "ruby_args", "operator_send", "ruby_oper_send", "send_args", "arg_exp",
617
- "try_catch_block", "catch_block", "required_catch_blocks",
618
- "catch_blocks", "finally_block", "integer_literal", "double_literal",
619
- "string_literal", "symbol_literal", "regex_literal", "hex_literal",
620
- "oct_literal", "bin_literal", "literal_value", "array_literal",
621
- "exp_comma_list", "empty_array", "hash_literal", "block_literal",
622
- "tuple_literal", "range_literal", "block_args",
623
- "block_args_without_comma", "block_args_with_comma", "key_value_list",
624
- "match_expr", "match_body", "match_clause", 0
625
- };
626
- #endif
627
-
628
- # ifdef YYPRINT
629
- /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
630
- token YYLEX-NUM. */
631
- static const yytype_uint16 yytoknum[] =
632
- {
633
- 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
634
- 265, 266, 267, 268, 269, 270, 271, 272, 273, 274,
635
- 275, 276, 277, 278, 279, 280, 281, 282, 283, 284,
636
- 285, 286, 287, 288, 289, 290, 291, 292, 293, 294,
637
- 295, 296, 297, 298, 299, 300
638
- };
639
- # endif
640
-
641
- /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
642
- static const yytype_uint8 yyr1[] =
643
- {
644
- 0, 46, 47, 47, 48, 48, 48, 49, 49, 50,
645
- 50, 51, 51, 52, 52, 52, 52, 53, 53, 54,
646
- 54, 54, 55, 55, 55, 55, 55, 55, 55, 55,
647
- 55, 55, 55, 55, 55, 55, 56, 56, 57, 58,
648
- 59, 60, 60, 60, 61, 61, 62, 62, 63, 63,
649
- 64, 64, 65, 65, 66, 66, 67, 68, 68, 69,
650
- 69, 70, 70, 70, 70, 70, 70, 71, 72, 72,
651
- 72, 73, 74, 74, 75, 75, 76, 76, 77, 77,
652
- 78, 78, 79, 79, 79, 80, 80, 80, 81, 81,
653
- 81, 82, 83, 84, 84, 85, 85, 85, 85, 86,
654
- 86, 86, 86, 87, 88, 88, 88, 88, 89, 89,
655
- 89, 89, 90, 90, 91, 91, 91, 92, 92, 93,
656
- 93, 93, 94, 95, 96, 97, 97, 98, 99, 100,
657
- 101, 102, 103, 103, 103, 103, 103, 103, 103, 103,
658
- 103, 103, 103, 103, 103, 104, 104, 105, 105, 105,
659
- 106, 107, 107, 108, 108, 109, 110, 111, 111, 112,
660
- 112, 113, 113, 114, 114, 115, 116, 116, 117, 117
661
- };
662
-
663
- /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
664
- static const yytype_uint8 yyr2[] =
665
- {
666
- 0, 2, 0, 1, 1, 1, 2, 1, 2, 0,
667
- 1, 1, 1, 1, 2, 2, 2, 5, 3, 1,
668
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
669
- 1, 1, 1, 1, 5, 3, 4, 1, 3, 1,
670
- 1, 1, 1, 1, 1, 1, 1, 3, 2, 1,
671
- 2, 1, 1, 1, 1, 2, 1, 3, 2, 5,
672
- 4, 1, 1, 1, 1, 1, 1, 3, 1, 2,
673
- 2, 8, 1, 3, 3, 2, 3, 2, 4, 3,
674
- 4, 3, 4, 5, 7, 5, 6, 8, 2, 2,
675
- 1, 1, 1, 3, 2, 2, 3, 1, 2, 3,
676
- 5, 4, 6, 3, 3, 4, 4, 5, 1, 3,
677
- 1, 2, 4, 3, 2, 3, 5, 1, 2, 1,
678
- 2, 0, 2, 1, 1, 1, 1, 1, 1, 1,
679
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
680
- 1, 1, 1, 1, 1, 1, 5, 1, 4, 2,
681
- 3, 5, 3, 1, 5, 3, 6, 1, 1, 1,
682
- 2, 1, 3, 5, 8, 7, 1, 2, 4, 7
683
- };
684
-
685
- /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
686
- STATE-NUM when YYTABLE doesn't specify something else to do. Zero
687
- means the default is an error. */
688
- static const yytype_uint8 yydefact[] =
689
- {
690
- 2, 0, 9, 9, 9, 0, 5, 7, 49, 51,
691
- 0, 33, 32, 43, 56, 42, 41, 91, 40, 123,
692
- 129, 130, 131, 124, 125, 126, 127, 128, 0, 0,
693
- 4, 13, 3, 153, 11, 12, 19, 37, 54, 45,
694
- 31, 0, 20, 21, 23, 44, 0, 52, 53, 22,
695
- 61, 62, 63, 64, 65, 66, 26, 0, 28, 27,
696
- 29, 90, 24, 132, 136, 137, 138, 141, 133, 134,
697
- 135, 30, 140, 145, 139, 142, 143, 144, 25, 10,
698
- 0, 147, 31, 0, 0, 0, 0, 43, 42, 159,
699
- 0, 158, 157, 48, 50, 121, 58, 0, 1, 0,
700
- 15, 8, 16, 14, 0, 9, 92, 39, 0, 88,
701
- 0, 0, 89, 0, 9, 0, 0, 55, 0, 0,
702
- 77, 0, 68, 75, 97, 147, 94, 0, 0, 9,
703
- 9, 155, 9, 18, 9, 150, 9, 152, 9, 9,
704
- 9, 160, 0, 0, 117, 113, 0, 0, 57, 9,
705
- 6, 0, 35, 0, 9, 0, 45, 108, 99, 110,
706
- 93, 103, 0, 104, 0, 47, 38, 0, 0, 0,
707
- 76, 0, 0, 81, 79, 74, 0, 69, 72, 70,
708
- 95, 98, 0, 0, 0, 0, 4, 0, 0, 0,
709
- 9, 0, 0, 162, 114, 0, 118, 0, 120, 112,
710
- 60, 0, 101, 147, 0, 111, 105, 36, 0, 82,
711
- 67, 0, 0, 80, 78, 0, 0, 96, 0, 106,
712
- 34, 0, 148, 17, 146, 9, 0, 151, 154, 0,
713
- 115, 122, 59, 0, 9, 166, 0, 109, 100, 0,
714
- 83, 0, 85, 67, 0, 73, 107, 156, 0, 9,
715
- 0, 0, 0, 167, 102, 0, 0, 86, 9, 0,
716
- 163, 0, 116, 0, 165, 84, 0, 0, 0, 9,
717
- 0, 168, 87, 9, 0, 0, 0, 164, 0, 71,
718
- 169
719
- };
720
-
721
- /* YYDEFGOTO[NTERM-NUM]. */
722
- static const yytype_int16 yydefgoto[] =
723
- {
724
- -1, 28, 102, 79, 152, 31, 100, 33, 34, 35,
725
- 36, 37, 108, 38, 39, 82, 41, 42, 43, 44,
726
- 45, 46, 47, 48, 49, 122, 123, 178, 179, 50,
727
- 51, 52, 53, 54, 55, 56, 57, 111, 58, 126,
728
- 59, 60, 61, 158, 62, 144, 145, 146, 199, 63,
729
- 64, 65, 66, 67, 68, 69, 70, 71, 72, 127,
730
- 73, 74, 75, 76, 77, 90, 91, 92, 139, 78,
731
- 234, 235
732
- };
733
-
734
- /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
735
- STATE-NUM. */
736
- #define YYPACT_NINF -118
737
- static const yytype_int16 yypact[] =
738
- {
739
- 666, 750, 2, 2, 2, 218, -118, -118, 918, 918,
740
- 15, -118, -118, 27, -118, 918, -118, -118, -118, -118,
741
- -118, -118, -118, -118, -118, -118, -118, -118, 66, 666,
742
- 70, -118, 666, -118, -118, 554, -118, -118, -118, 72,
743
- -5, 5, -118, -118, -118, 27, 48, -118, -118, -118,
744
- -118, -118, -118, -118, -118, -118, -118, 792, -118, -118,
745
- -118, 218, -118, -118, -118, -118, -118, -118, -118, -118,
746
- -118, -118, -118, -118, -118, -118, -118, -118, -118, 70,
747
- 918, 576, -118, 13, 624, 834, 876, -118, -118, 84,
748
- 96, 218, 102, 554, 554, 89, 6, 181, -118, 666,
749
- 666, -118, 86, -118, 918, 2, -118, -118, 960, 72,
750
- 792, 792, 218, 1002, 2, 105, 918, -118, 218, 218,
751
- 287, 165, -118, 42, 33, 554, -118, 83, 103, 363,
752
- 52, -118, 1089, -118, 666, -118, 21, -118, 363, 76,
753
- 2, -118, 218, 918, 107, 89, 97, 27, -118, 2,
754
- 86, 506, -118, 918, 2, 918, -118, -118, -118, -118,
755
- -118, -118, 1044, -118, 918, -118, 118, 128, 15, 218,
756
- -118, 218, 218, 23, 42, -118, 136, -118, -118, 143,
757
- -118, 33, 1002, 141, 918, 918, 70, 150, 155, 157,
758
- 2, 161, 15, -118, -118, 200, -118, 15, -118, -118,
759
- 25, 146, 162, 18, 1044, 24, -118, 554, 60, -118,
760
- -118, 159, 15, -118, -118, 218, 218, -118, 1044, -118,
761
- -118, 151, 554, -118, -118, 2, 918, -118, -118, 218,
762
- -118, -118, -118, 918, 45, -118, 1044, -118, -118, 218,
763
- -118, 65, -118, 171, 163, -118, -118, -118, 918, 363,
764
- 15, 535, 183, -118, -118, 15, 218, -118, 2, 218,
765
- 554, 175, -118, 708, -118, -118, 15, 918, 171, 2,
766
- 218, 666, -118, 363, 918, 189, 188, 554, 666, -118,
767
- 666
768
- };
769
-
770
- /* YYPGOTO[NTERM-NUM]. */
771
- static const yytype_int16 yypgoto[] =
772
- {
773
- -118, -118, 10, 4, 12, -29, 1, 304, -118, 113,
774
- -118, -118, -40, -43, 230, 0, -118, -118, -118, -118,
775
- -8, -118, -118, -118, -118, -115, 80, -13, -118, -118,
776
- -118, -118, -118, -118, -118, -118, 325, -118, -118, 32,
777
- -118, -118, 368, -71, -118, -22, -118, -118, -118, -118,
778
- -118, -118, -118, -118, -118, -118, -118, -87, -118, 11,
779
- -118, -118, -117, -118, -118, -61, -118, -118, -118, -118,
780
- -118, -18
781
- };
782
-
783
- /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
784
- positive, shift that token. If negative, reduce the rule which
785
- number is the opposite. If zero, do what YYDEFACT says.
786
- If YYTABLE_NINF, syntax error. */
787
- #define YYTABLE_NINF -162
788
- static const yytype_int16 yytable[] =
789
- {
790
- 40, 32, 117, 103, 30, 96, 119, 180, 177, -46,
791
- 29, 2, 83, 80, 84, 85, 86, 131, 7, 115,
792
- 2, 159, 237, 147, 114, 104, 159, 132, 2, 40,
793
- 2, 104, 40, 30, 116, 132, 30, 7, 2, 99,
794
- 169, 18, 163, 87, 5, 130, 121, 2, 88, 87,
795
- 16, 17, 106, 117, 88, 118, 16, 17, 106, 177,
796
- 18, 7, 18, 107, 217, 2, 98, 87, 7, 107,
797
- 2, 103, 88, 87, 16, 159, 233, 239, 88, 184,
798
- 16, 172, 256, 18, 40, 134, 101, 181, 30, 113,
799
- 190, 206, 7, 107, 29, 159, 136, 132, -161, 40,
800
- 40, 6, 7, 30, 30, 103, 30, 140, 157, 99,
801
- 143, 219, 150, 157, 81, 165, 142, 159, 143, 197,
802
- 182, 93, 94, 196, 198, 162, 164, 166, 97, -119,
803
- 87, 159, 132, 238, 40, 88, 208, 16, 186, 200,
804
- 18, 183, 160, 161, 185, 220, 187, 246, 188, 159,
805
- 189, 191, 192, 215, 30, 247, 223, 117, 104, 7,
806
- 150, 201, 157, 224, 83, 254, 204, 241, -9, 225,
807
- 125, 227, 171, -9, 258, -9, 87, 233, 105, 236,
808
- 259, 88, 157, 16, 17, 106, 149, 269, 104, 264,
809
- 87, 216, 279, 129, 218, 88, 107, 16, 125, 138,
810
- 278, 174, 226, 245, 157, 2, 87, 104, 105, 275,
811
- 107, 88, 229, 16, 17, 106, 253, 151, 157, 0,
812
- 0, 0, 0, 125, 125, 87, 107, 105, 0, 125,
813
- 88, 0, 16, 17, 106, 89, 157, 248, 0, 0,
814
- 0, 0, 103, 87, 0, 107, 252, 0, 88, 0,
815
- 16, 103, 0, 0, 0, 0, 195, 0, 0, 0,
816
- 0, 261, 0, 40, 271, 109, 203, 30, 205, 0,
817
- 267, 40, 0, 29, 0, 30, 120, 207, 40, 280,
818
- 40, 274, 186, 0, 30, 276, 0, 0, 29, 0,
819
- 192, 128, 2, 0, -45, 0, 0, 221, 222, 0,
820
- 0, 0, 0, 0, 169, 0, 0, 0, 0, 0,
821
- 0, 109, -45, 0, 95, 0, 0, -45, 0, -45,
822
- 0, 141, 0, 109, 109, 0, 0, 109, 0, 0,
823
- 0, 0, -45, 0, 0, 0, 0, 0, 156, 249,
824
- 0, 0, 128, 156, 0, 156, 251, 0, 167, 168,
825
- 0, 173, 0, 176, 0, 109, 0, 0, 0, 109,
826
- 110, 260, 0, 0, 0, 0, 0, 0, 109, 0,
827
- 104, 0, 193, 0, 0, 0, 0, 0, 0, 7,
828
- 273, 109, 0, 0, 0, 0, 0, 277, 87, 0,
829
- 105, 0, 156, 88, 0, 16, 17, 106, 0, 210,
830
- 148, 211, 212, 112, 176, 0, 110, 0, 107, 0,
831
- 0, 0, 156, 0, 0, 0, 0, 0, 110, 110,
832
- 0, 0, 110, 0, 170, 109, 0, 175, 0, 0,
833
- 0, 0, 0, 109, 156, 109, 0, 109, 0, 0,
834
- 0, 0, 0, 0, 0, 243, 244, 194, 156, 112,
835
- 110, 109, 109, 0, 110, 0, 0, 0, 0, 250,
836
- 0, 112, 112, 110, 0, 112, 156, 0, 0, 255,
837
- 0, 0, 209, 0, 0, 0, 110, 213, 214, 109,
838
- 0, 109, 0, 0, 0, 0, 266, 0, 0, 268,
839
- 109, 0, 0, 112, 0, 0, 228, 112, 0, 230,
840
- 89, 231, 0, 109, 232, 0, 112, 109, 0, 0,
841
- 0, 0, 240, 104, 202, 0, 242, 0, 0, 112,
842
- 110, 0, 0, 0, 0, 0, 0, 0, 110, 0,
843
- 110, 87, 110, 105, 0, 0, 88, 0, 16, 17,
844
- 106, 0, 104, 0, 0, 257, 110, 110, 263, 0,
845
- 0, 107, 0, 0, 262, 0, 0, 0, 0, 265,
846
- 87, 104, 105, 112, 0, 88, 0, 16, 17, 106,
847
- 272, 112, 0, 112, 110, 112, 110, 0, 0, 87,
848
- 107, 105, 0, 104, 88, 110, 16, 17, 106, 112,
849
- 112, 0, 0, 0, 0, 0, 0, 0, 110, 107,
850
- 0, 87, 110, 130, 0, 0, 88, 0, 16, 17,
851
- 106, 0, 0, 0, 0, 0, 0, 112, 0, 112,
852
- 0, 107, 0, 0, 0, 0, 0, 1, 112, 2,
853
- 133, 3, 0, 4, 0, 5, 0, 0, 0, 6,
854
- 7, 112, 8, 9, 10, 112, 0, 11, 12, 13,
855
- 14, 0, 0, 0, 15, 0, 16, 17, 0, 18,
856
- 19, 20, 21, 22, 23, 24, 25, 26, 27, 1,
857
- 0, 2, 0, 3, 0, 4, 0, 5, 0, 0,
858
- 0, 6, 7, 0, 8, 9, 10, 0, 0, 11,
859
- 12, 13, 14, 0, 0, 0, 15, 0, 16, 17,
860
- 0, 18, 19, 20, 21, 22, 23, 24, 25, 26,
861
- 27, 1, 0, 2, 0, 3, 0, 4, 0, 270,
862
- 0, 0, 0, 6, 7, 0, 8, 9, 10, 0,
863
- 0, 11, 12, 13, 14, 0, 0, 0, 15, 0,
864
- 16, 17, 0, 18, 19, 20, 21, 22, 23, 24,
865
- 25, 26, 27, 1, 0, 2, 0, 3, 0, 4,
866
- 0, 5, 0, 0, 0, 0, 7, 0, 0, 0,
867
- 10, 0, 0, 11, 12, 13, 14, 0, 0, 0,
868
- 15, 0, 16, 17, 0, 18, 19, 20, 21, 22,
869
- 23, 24, 25, 26, 27, 1, 124, 2, 0, 3,
870
- 0, 4, 0, 5, 0, 0, 0, 0, 0, 0,
871
- 0, 0, 10, 0, 0, 11, 12, 13, 14, 0,
872
- 0, 0, 15, 0, 16, 17, 0, 18, 19, 20,
873
- 21, 22, 23, 24, 25, 26, 27, 1, 0, 2,
874
- 0, 3, 135, 4, 0, 5, 0, 0, 0, 0,
875
- 0, 0, 0, 0, 10, 0, 0, 11, 12, 13,
876
- 14, 0, 0, 0, 15, 0, 16, 17, 0, 18,
877
- 19, 20, 21, 22, 23, 24, 25, 26, 27, 1,
878
- 0, 2, 0, 3, 0, 4, 137, 5, 0, 0,
879
- 0, 0, 0, 0, 0, 0, 10, 0, 0, 11,
880
- 12, 13, 14, 0, 0, 0, 15, 0, 16, 17,
881
- 0, 18, 19, 20, 21, 22, 23, 24, 25, 26,
882
- 27, 1, 0, 2, 0, 3, 0, 4, 0, 5,
883
- 0, 0, 0, 0, 0, 0, 0, 0, 10, 0,
884
- 0, 11, 12, 13, 14, 0, 0, 0, 15, 0,
885
- 16, 17, 0, 18, 19, 20, 21, 22, 23, 24,
886
- 25, 26, 27, 153, 0, 2, 0, 3, 0, 4,
887
- 0, 5, 0, 0, 0, 0, 0, 0, 0, 0,
888
- 0, 0, 0, 0, 0, 87, 0, 154, 155, 0,
889
- 88, 0, 16, 0, 0, 18, 19, 20, 21, 22,
890
- 23, 24, 25, 26, 27, 153, 0, 2, 0, 3,
891
- 0, 4, 0, 5, 0, 0, 0, 0, 7, 0,
892
- 0, 0, 0, 0, 0, 0, 0, 87, 0, 0,
893
- 155, 0, 88, 0, 16, 0, 0, 18, 19, 20,
894
- 21, 22, 23, 24, 25, 26, 27, 153, 0, 2,
895
- 0, 3, 0, 4, 0, 5, 0, 0, 0, 0,
896
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 87,
897
- 0, 0, 155, 0, 88, 0, 16, 0, 0, 18,
898
- 19, 20, 21, 22, 23, 24, 25, 26, 27, -149,
899
- 0, 0, 0, -149, 0, -149, 0, -149, 0, 0,
900
- 0, 0, 0, -149, -149, 7, 0, -149, -149, 0,
901
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
902
- -149
903
- };
904
-
905
- static const yytype_int16 yycheck[] =
906
- {
907
- 0, 0, 45, 32, 0, 13, 46, 124, 123, 14,
908
- 0, 5, 1, 1, 2, 3, 4, 4, 16, 14,
909
- 5, 108, 4, 17, 29, 7, 113, 14, 5, 29,
910
- 5, 7, 32, 29, 29, 14, 32, 16, 5, 29,
911
- 17, 35, 113, 25, 11, 27, 46, 5, 30, 25,
912
- 32, 33, 34, 96, 30, 7, 32, 33, 34, 174,
913
- 35, 16, 35, 45, 181, 5, 0, 25, 16, 45,
914
- 5, 100, 30, 25, 32, 162, 31, 17, 30, 27,
915
- 32, 121, 17, 35, 84, 84, 16, 4, 84, 17,
916
- 14, 162, 16, 45, 84, 182, 85, 14, 14, 99,
917
- 100, 15, 16, 99, 100, 134, 102, 11, 108, 99,
918
- 21, 182, 102, 113, 1, 115, 14, 204, 21, 22,
919
- 17, 8, 9, 145, 146, 113, 114, 116, 15, 22,
920
- 25, 218, 14, 204, 134, 30, 8, 32, 134, 147,
921
- 35, 129, 110, 111, 132, 4, 134, 218, 136, 236,
922
- 138, 139, 140, 17, 150, 4, 6, 200, 7, 16,
923
- 150, 149, 162, 8, 153, 236, 154, 8, 25, 12,
924
- 57, 10, 7, 30, 3, 32, 25, 31, 27, 17,
925
- 17, 30, 182, 32, 33, 34, 5, 12, 7, 6,
926
- 25, 179, 4, 80, 182, 30, 45, 32, 85, 86,
927
- 11, 121, 190, 216, 204, 5, 25, 7, 27, 270,
928
- 45, 30, 12, 32, 33, 34, 234, 104, 218, -1,
929
- -1, -1, -1, 110, 111, 25, 45, 27, -1, 116,
930
- 30, -1, 32, 33, 34, 5, 236, 225, -1, -1,
931
- -1, -1, 271, 25, -1, 45, 234, -1, 30, -1,
932
- 32, 280, -1, -1, -1, -1, 143, -1, -1, -1,
933
- -1, 249, -1, 263, 263, 35, 153, 263, 155, -1,
934
- 258, 271, -1, 263, -1, 271, 46, 164, 278, 278,
935
- 280, 269, 278, -1, 280, 273, -1, -1, 278, -1,
936
- 278, 61, 5, -1, 7, -1, -1, 184, 185, -1,
937
- -1, -1, -1, -1, 17, -1, -1, -1, -1, -1,
938
- -1, 81, 25, -1, 10, -1, -1, 30, -1, 32,
939
- -1, 91, -1, 93, 94, -1, -1, 97, -1, -1,
940
- -1, -1, 45, -1, -1, -1, -1, -1, 108, 226,
941
- -1, -1, 112, 113, -1, 115, 233, -1, 118, 119,
942
- -1, 121, -1, 123, -1, 125, -1, -1, -1, 129,
943
- 35, 248, -1, -1, -1, -1, -1, -1, 138, -1,
944
- 7, -1, 142, -1, -1, -1, -1, -1, -1, 16,
945
- 267, 151, -1, -1, -1, -1, -1, 274, 25, -1,
946
- 27, -1, 162, 30, -1, 32, 33, 34, -1, 169,
947
- 96, 171, 172, 35, 174, -1, 81, -1, 45, -1,
948
- -1, -1, 182, -1, -1, -1, -1, -1, 93, 94,
949
- -1, -1, 97, -1, 120, 195, -1, 123, -1, -1,
950
- -1, -1, -1, 203, 204, 205, -1, 207, -1, -1,
951
- -1, -1, -1, -1, -1, 215, 216, 143, 218, 81,
952
- 125, 221, 222, -1, 129, -1, -1, -1, -1, 229,
953
- -1, 93, 94, 138, -1, 97, 236, -1, -1, 239,
954
- -1, -1, 168, -1, -1, -1, 151, 173, 174, 249,
955
- -1, 251, -1, -1, -1, -1, 256, -1, -1, 259,
956
- 260, -1, -1, 125, -1, -1, 192, 129, -1, 195,
957
- 270, 197, -1, 273, 200, -1, 138, 277, -1, -1,
958
- -1, -1, 208, 7, 8, -1, 212, -1, -1, 151,
959
- 195, -1, -1, -1, -1, -1, -1, -1, 203, -1,
960
- 205, 25, 207, 27, -1, -1, 30, -1, 32, 33,
961
- 34, -1, 7, -1, -1, 241, 221, 222, 13, -1,
962
- -1, 45, -1, -1, 250, -1, -1, -1, -1, 255,
963
- 25, 7, 27, 195, -1, 30, -1, 32, 33, 34,
964
- 266, 203, -1, 205, 249, 207, 251, -1, -1, 25,
965
- 45, 27, -1, 7, 30, 260, 32, 33, 34, 221,
966
- 222, -1, -1, -1, -1, -1, -1, -1, 273, 45,
967
- -1, 25, 277, 27, -1, -1, 30, -1, 32, 33,
968
- 34, -1, -1, -1, -1, -1, -1, 249, -1, 251,
969
- -1, 45, -1, -1, -1, -1, -1, 3, 260, 5,
970
- 6, 7, -1, 9, -1, 11, -1, -1, -1, 15,
971
- 16, 273, 18, 19, 20, 277, -1, 23, 24, 25,
972
- 26, -1, -1, -1, 30, -1, 32, 33, -1, 35,
973
- 36, 37, 38, 39, 40, 41, 42, 43, 44, 3,
974
- -1, 5, -1, 7, -1, 9, -1, 11, -1, -1,
975
- -1, 15, 16, -1, 18, 19, 20, -1, -1, 23,
976
- 24, 25, 26, -1, -1, -1, 30, -1, 32, 33,
977
- -1, 35, 36, 37, 38, 39, 40, 41, 42, 43,
978
- 44, 3, -1, 5, -1, 7, -1, 9, -1, 11,
979
- -1, -1, -1, 15, 16, -1, 18, 19, 20, -1,
980
- -1, 23, 24, 25, 26, -1, -1, -1, 30, -1,
981
- 32, 33, -1, 35, 36, 37, 38, 39, 40, 41,
982
- 42, 43, 44, 3, -1, 5, -1, 7, -1, 9,
983
- -1, 11, -1, -1, -1, -1, 16, -1, -1, -1,
984
- 20, -1, -1, 23, 24, 25, 26, -1, -1, -1,
985
- 30, -1, 32, 33, -1, 35, 36, 37, 38, 39,
986
- 40, 41, 42, 43, 44, 3, 4, 5, -1, 7,
987
- -1, 9, -1, 11, -1, -1, -1, -1, -1, -1,
988
- -1, -1, 20, -1, -1, 23, 24, 25, 26, -1,
989
- -1, -1, 30, -1, 32, 33, -1, 35, 36, 37,
990
- 38, 39, 40, 41, 42, 43, 44, 3, -1, 5,
991
- -1, 7, 8, 9, -1, 11, -1, -1, -1, -1,
992
- -1, -1, -1, -1, 20, -1, -1, 23, 24, 25,
993
- 26, -1, -1, -1, 30, -1, 32, 33, -1, 35,
994
- 36, 37, 38, 39, 40, 41, 42, 43, 44, 3,
995
- -1, 5, -1, 7, -1, 9, 10, 11, -1, -1,
996
- -1, -1, -1, -1, -1, -1, 20, -1, -1, 23,
997
- 24, 25, 26, -1, -1, -1, 30, -1, 32, 33,
998
- -1, 35, 36, 37, 38, 39, 40, 41, 42, 43,
999
- 44, 3, -1, 5, -1, 7, -1, 9, -1, 11,
1000
- -1, -1, -1, -1, -1, -1, -1, -1, 20, -1,
1001
- -1, 23, 24, 25, 26, -1, -1, -1, 30, -1,
1002
- 32, 33, -1, 35, 36, 37, 38, 39, 40, 41,
1003
- 42, 43, 44, 3, -1, 5, -1, 7, -1, 9,
1004
- -1, 11, -1, -1, -1, -1, -1, -1, -1, -1,
1005
- -1, -1, -1, -1, -1, 25, -1, 27, 28, -1,
1006
- 30, -1, 32, -1, -1, 35, 36, 37, 38, 39,
1007
- 40, 41, 42, 43, 44, 3, -1, 5, -1, 7,
1008
- -1, 9, -1, 11, -1, -1, -1, -1, 16, -1,
1009
- -1, -1, -1, -1, -1, -1, -1, 25, -1, -1,
1010
- 28, -1, 30, -1, 32, -1, -1, 35, 36, 37,
1011
- 38, 39, 40, 41, 42, 43, 44, 3, -1, 5,
1012
- -1, 7, -1, 9, -1, 11, -1, -1, -1, -1,
1013
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 25,
1014
- -1, -1, 28, -1, 30, -1, 32, -1, -1, 35,
1015
- 36, 37, 38, 39, 40, 41, 42, 43, 44, 0,
1016
- -1, -1, -1, 4, -1, 6, -1, 8, -1, -1,
1017
- -1, -1, -1, 14, 15, 16, -1, 18, 19, -1,
1018
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1019
- 31
1020
- };
1021
-
1022
- /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
1023
- symbol of state STATE-NUM. */
1024
- static const yytype_uint8 yystos[] =
1025
- {
1026
- 0, 3, 5, 7, 9, 11, 15, 16, 18, 19,
1027
- 20, 23, 24, 25, 26, 30, 32, 33, 35, 36,
1028
- 37, 38, 39, 40, 41, 42, 43, 44, 47, 48,
1029
- 49, 51, 52, 53, 54, 55, 56, 57, 59, 60,
1030
- 61, 62, 63, 64, 65, 66, 67, 68, 69, 70,
1031
- 75, 76, 77, 78, 79, 80, 81, 82, 84, 86,
1032
- 87, 88, 90, 95, 96, 97, 98, 99, 100, 101,
1033
- 102, 103, 104, 106, 107, 108, 109, 110, 115, 49,
1034
- 50, 55, 61, 105, 50, 50, 50, 25, 30, 60,
1035
- 111, 112, 113, 55, 55, 53, 66, 55, 0, 48,
1036
- 52, 16, 48, 51, 7, 27, 34, 45, 58, 60,
1037
- 82, 83, 88, 17, 29, 14, 29, 59, 7, 58,
1038
- 60, 61, 71, 72, 4, 55, 85, 105, 60, 55,
1039
- 27, 4, 14, 6, 52, 8, 105, 10, 55, 114,
1040
- 11, 60, 14, 21, 91, 92, 93, 17, 53, 5,
1041
- 48, 55, 50, 3, 27, 28, 60, 61, 89, 103,
1042
- 85, 85, 50, 89, 50, 61, 105, 60, 60, 17,
1043
- 53, 7, 58, 60, 72, 53, 60, 71, 73, 74,
1044
- 108, 4, 17, 50, 27, 50, 49, 50, 50, 50,
1045
- 14, 50, 50, 60, 53, 55, 91, 22, 91, 94,
1046
- 66, 50, 8, 55, 50, 55, 89, 55, 8, 53,
1047
- 60, 60, 60, 53, 53, 17, 50, 108, 50, 89,
1048
- 4, 55, 55, 6, 8, 12, 50, 10, 53, 12,
1049
- 53, 53, 53, 31, 116, 117, 17, 4, 89, 17,
1050
- 53, 8, 53, 60, 60, 73, 89, 4, 50, 55,
1051
- 60, 55, 50, 117, 89, 60, 17, 53, 3, 17,
1052
- 55, 50, 53, 13, 6, 53, 60, 50, 60, 12,
1053
- 11, 52, 53, 55, 50, 111, 50, 55, 11, 4,
1054
- 52
1055
- };
1056
-
1057
- #define yyerrok (yyerrstatus = 0)
1058
- #define yyclearin (yychar = YYEMPTY)
1059
- #define YYEMPTY (-2)
1060
- #define YYEOF 0
1061
-
1062
- #define YYACCEPT goto yyacceptlab
1063
- #define YYABORT goto yyabortlab
1064
- #define YYERROR goto yyerrorlab
1065
-
1066
-
1067
- /* Like YYERROR except do call yyerror. This remains here temporarily
1068
- to ease the transition to the new meaning of YYERROR, for GCC.
1069
- Once GCC version 2 has supplanted version 1, this can go. */
1070
-
1071
- #define YYFAIL goto yyerrlab
1072
-
1073
- #define YYRECOVERING() (!!yyerrstatus)
1074
-
1075
- #define YYBACKUP(Token, Value) \
1076
- do \
1077
- if (yychar == YYEMPTY && yylen == 1) \
1078
- { \
1079
- yychar = (Token); \
1080
- yylval = (Value); \
1081
- yytoken = YYTRANSLATE (yychar); \
1082
- YYPOPSTACK (1); \
1083
- goto yybackup; \
1084
- } \
1085
- else \
1086
- { \
1087
- yyerror (self, YY_("syntax error: cannot back up")); \
1088
- YYERROR; \
1089
- } \
1090
- while (YYID (0))
1091
-
1092
-
1093
- #define YYTERROR 1
1094
- #define YYERRCODE 256
1095
-
1096
-
1097
- /* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
1098
- If N is 0, then set CURRENT to the empty location which ends
1099
- the previous symbol: RHS[0] (always defined). */
1100
-
1101
- #define YYRHSLOC(Rhs, K) ((Rhs)[K])
1102
- #ifndef YYLLOC_DEFAULT
1103
- # define YYLLOC_DEFAULT(Current, Rhs, N) \
1104
- do \
1105
- if (YYID (N)) \
1106
- { \
1107
- (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \
1108
- (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \
1109
- (Current).last_line = YYRHSLOC (Rhs, N).last_line; \
1110
- (Current).last_column = YYRHSLOC (Rhs, N).last_column; \
1111
- } \
1112
- else \
1113
- { \
1114
- (Current).first_line = (Current).last_line = \
1115
- YYRHSLOC (Rhs, 0).last_line; \
1116
- (Current).first_column = (Current).last_column = \
1117
- YYRHSLOC (Rhs, 0).last_column; \
1118
- } \
1119
- while (YYID (0))
1120
- #endif
1121
-
1122
-
1123
- /* YY_LOCATION_PRINT -- Print the location on the stream.
1124
- This macro was not mandated originally: define only if we know
1125
- we won't break user code: when these are the locations we know. */
1126
-
1127
- #ifndef YY_LOCATION_PRINT
1128
- # if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
1129
- # define YY_LOCATION_PRINT(File, Loc) \
1130
- fprintf (File, "%d.%d-%d.%d", \
1131
- (Loc).first_line, (Loc).first_column, \
1132
- (Loc).last_line, (Loc).last_column)
1133
- # else
1134
- # define YY_LOCATION_PRINT(File, Loc) ((void) 0)
1135
- # endif
1136
- #endif
1137
-
1138
-
1139
- /* YYLEX -- calling `yylex' with the right arguments. */
1140
-
1141
- #ifdef YYLEX_PARAM
1142
- # define YYLEX yylex (YYLEX_PARAM)
1143
- #else
1144
- # define YYLEX yylex (self)
1145
- #endif
1146
-
1147
- /* Enable debugging if requested. */
1148
- #if YYDEBUG
1149
-
1150
- # ifndef YYFPRINTF
1151
- # include <stdio.h> /* INFRINGES ON USER NAME SPACE */
1152
- # define YYFPRINTF fprintf
1153
- # endif
1154
-
1155
- # define YYDPRINTF(Args) \
1156
- do { \
1157
- if (yydebug) \
1158
- YYFPRINTF Args; \
1159
- } while (YYID (0))
1160
-
1161
- # define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
1162
- do { \
1163
- if (yydebug) \
1164
- { \
1165
- YYFPRINTF (stderr, "%s ", Title); \
1166
- yy_symbol_print (stderr, \
1167
- Type, Value, self); \
1168
- YYFPRINTF (stderr, "\n"); \
1169
- } \
1170
- } while (YYID (0))
1171
-
1172
-
1173
- /*--------------------------------.
1174
- | Print this symbol on YYOUTPUT. |
1175
- `--------------------------------*/
1176
-
1177
- /*ARGSUSED*/
1178
- #if (defined __STDC__ || defined __C99__FUNC__ \
1179
- || defined __cplusplus || defined _MSC_VER)
1180
- static void
1181
- yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, VALUE self)
1182
- #else
1183
- static void
1184
- yy_symbol_value_print (yyoutput, yytype, yyvaluep, self)
1185
- FILE *yyoutput;
1186
- int yytype;
1187
- YYSTYPE const * const yyvaluep;
1188
- VALUE self;
1189
- #endif
1190
- {
1191
- if (!yyvaluep)
1192
- return;
1193
- YYUSE (self);
1194
- # ifdef YYPRINT
1195
- if (yytype < YYNTOKENS)
1196
- YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
1197
- # else
1198
- YYUSE (yyoutput);
1199
- # endif
1200
- switch (yytype)
1201
- {
1202
- default:
1203
- break;
1204
- }
1205
- }
1206
-
1207
-
1208
- /*--------------------------------.
1209
- | Print this symbol on YYOUTPUT. |
1210
- `--------------------------------*/
1211
-
1212
- #if (defined __STDC__ || defined __C99__FUNC__ \
1213
- || defined __cplusplus || defined _MSC_VER)
1214
- static void
1215
- yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, VALUE self)
1216
- #else
1217
- static void
1218
- yy_symbol_print (yyoutput, yytype, yyvaluep, self)
1219
- FILE *yyoutput;
1220
- int yytype;
1221
- YYSTYPE const * const yyvaluep;
1222
- VALUE self;
1223
- #endif
1224
- {
1225
- if (yytype < YYNTOKENS)
1226
- YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
1227
- else
1228
- YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);
1229
-
1230
- yy_symbol_value_print (yyoutput, yytype, yyvaluep, self);
1231
- YYFPRINTF (yyoutput, ")");
1232
- }
1233
-
1234
- /*------------------------------------------------------------------.
1235
- | yy_stack_print -- Print the state stack from its BOTTOM up to its |
1236
- | TOP (included). |
1237
- `------------------------------------------------------------------*/
1238
-
1239
- #if (defined __STDC__ || defined __C99__FUNC__ \
1240
- || defined __cplusplus || defined _MSC_VER)
1241
- static void
1242
- yy_stack_print (yytype_int16 *bottom, yytype_int16 *top)
1243
- #else
1244
- static void
1245
- yy_stack_print (bottom, top)
1246
- yytype_int16 *bottom;
1247
- yytype_int16 *top;
1248
- #endif
1249
- {
1250
- YYFPRINTF (stderr, "Stack now");
1251
- for (; bottom <= top; ++bottom)
1252
- YYFPRINTF (stderr, " %d", *bottom);
1253
- YYFPRINTF (stderr, "\n");
1254
- }
1255
-
1256
- # define YY_STACK_PRINT(Bottom, Top) \
1257
- do { \
1258
- if (yydebug) \
1259
- yy_stack_print ((Bottom), (Top)); \
1260
- } while (YYID (0))
1261
-
1262
-
1263
- /*------------------------------------------------.
1264
- | Report that the YYRULE is going to be reduced. |
1265
- `------------------------------------------------*/
1266
-
1267
- #if (defined __STDC__ || defined __C99__FUNC__ \
1268
- || defined __cplusplus || defined _MSC_VER)
1269
- static void
1270
- yy_reduce_print (YYSTYPE *yyvsp, int yyrule, VALUE self)
1271
- #else
1272
- static void
1273
- yy_reduce_print (yyvsp, yyrule, self)
1274
- YYSTYPE *yyvsp;
1275
- int yyrule;
1276
- VALUE self;
1277
- #endif
1278
- {
1279
- int yynrhs = yyr2[yyrule];
1280
- int yyi;
1281
- unsigned long int yylno = yyrline[yyrule];
1282
- YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
1283
- yyrule - 1, yylno);
1284
- /* The symbols being reduced. */
1285
- for (yyi = 0; yyi < yynrhs; yyi++)
1286
- {
1287
- fprintf (stderr, " $%d = ", yyi + 1);
1288
- yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi],
1289
- &(yyvsp[(yyi + 1) - (yynrhs)])
1290
- , self);
1291
- fprintf (stderr, "\n");
1292
- }
1293
- }
1294
-
1295
- # define YY_REDUCE_PRINT(Rule) \
1296
- do { \
1297
- if (yydebug) \
1298
- yy_reduce_print (yyvsp, Rule, self); \
1299
- } while (YYID (0))
1300
-
1301
- /* Nonzero means print parse trace. It is left uninitialized so that
1302
- multiple parsers can coexist. */
1303
- int yydebug;
1304
- #else /* !YYDEBUG */
1305
- # define YYDPRINTF(Args)
1306
- # define YY_SYMBOL_PRINT(Title, Type, Value, Location)
1307
- # define YY_STACK_PRINT(Bottom, Top)
1308
- # define YY_REDUCE_PRINT(Rule)
1309
- #endif /* !YYDEBUG */
1310
-
1311
-
1312
- /* YYINITDEPTH -- initial size of the parser's stacks. */
1313
- #ifndef YYINITDEPTH
1314
- # define YYINITDEPTH 200
1315
- #endif
1316
-
1317
- /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
1318
- if the built-in stack extension method is used).
1319
-
1320
- Do not make this value too large; the results are undefined if
1321
- YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
1322
- evaluated with infinite-precision integer arithmetic. */
1323
-
1324
- #ifndef YYMAXDEPTH
1325
- # define YYMAXDEPTH 10000
1326
- #endif
1327
-
1328
-
1329
-
1330
- #if YYERROR_VERBOSE
1331
-
1332
- # ifndef yystrlen
1333
- # if defined __GLIBC__ && defined _STRING_H
1334
- # define yystrlen strlen
1335
- # else
1336
- /* Return the length of YYSTR. */
1337
- #if (defined __STDC__ || defined __C99__FUNC__ \
1338
- || defined __cplusplus || defined _MSC_VER)
1339
- static YYSIZE_T
1340
- yystrlen (const char *yystr)
1341
- #else
1342
- static YYSIZE_T
1343
- yystrlen (yystr)
1344
- const char *yystr;
1345
- #endif
1346
- {
1347
- YYSIZE_T yylen;
1348
- for (yylen = 0; yystr[yylen]; yylen++)
1349
- continue;
1350
- return yylen;
1351
- }
1352
- # endif
1353
- # endif
1354
-
1355
- # ifndef yystpcpy
1356
- # if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
1357
- # define yystpcpy stpcpy
1358
- # else
1359
- /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
1360
- YYDEST. */
1361
- #if (defined __STDC__ || defined __C99__FUNC__ \
1362
- || defined __cplusplus || defined _MSC_VER)
1363
- static char *
1364
- yystpcpy (char *yydest, const char *yysrc)
1365
- #else
1366
- static char *
1367
- yystpcpy (yydest, yysrc)
1368
- char *yydest;
1369
- const char *yysrc;
1370
- #endif
1371
- {
1372
- char *yyd = yydest;
1373
- const char *yys = yysrc;
1374
-
1375
- while ((*yyd++ = *yys++) != '\0')
1376
- continue;
1377
-
1378
- return yyd - 1;
1379
- }
1380
- # endif
1381
- # endif
1382
-
1383
- # ifndef yytnamerr
1384
- /* Copy to YYRES the contents of YYSTR after stripping away unnecessary
1385
- quotes and backslashes, so that it's suitable for yyerror. The
1386
- heuristic is that double-quoting is unnecessary unless the string
1387
- contains an apostrophe, a comma, or backslash (other than
1388
- backslash-backslash). YYSTR is taken from yytname. If YYRES is
1389
- null, do not copy; instead, return the length of what the result
1390
- would have been. */
1391
- static YYSIZE_T
1392
- yytnamerr (char *yyres, const char *yystr)
1393
- {
1394
- if (*yystr == '"')
1395
- {
1396
- YYSIZE_T yyn = 0;
1397
- char const *yyp = yystr;
1398
-
1399
- for (;;)
1400
- switch (*++yyp)
1401
- {
1402
- case '\'':
1403
- case ',':
1404
- goto do_not_strip_quotes;
1405
-
1406
- case '\\':
1407
- if (*++yyp != '\\')
1408
- goto do_not_strip_quotes;
1409
- /* Fall through. */
1410
- default:
1411
- if (yyres)
1412
- yyres[yyn] = *yyp;
1413
- yyn++;
1414
- break;
1415
-
1416
- case '"':
1417
- if (yyres)
1418
- yyres[yyn] = '\0';
1419
- return yyn;
1420
- }
1421
- do_not_strip_quotes: ;
1422
- }
1423
-
1424
- if (! yyres)
1425
- return yystrlen (yystr);
1426
-
1427
- return yystpcpy (yyres, yystr) - yyres;
1428
- }
1429
- # endif
1430
-
1431
- /* Copy into YYRESULT an error message about the unexpected token
1432
- YYCHAR while in state YYSTATE. Return the number of bytes copied,
1433
- including the terminating null byte. If YYRESULT is null, do not
1434
- copy anything; just return the number of bytes that would be
1435
- copied. As a special case, return 0 if an ordinary "syntax error"
1436
- message will do. Return YYSIZE_MAXIMUM if overflow occurs during
1437
- size calculation. */
1438
- static YYSIZE_T
1439
- yysyntax_error (char *yyresult, int yystate, int yychar)
1440
- {
1441
- int yyn = yypact[yystate];
1442
-
1443
- if (! (YYPACT_NINF < yyn && yyn <= YYLAST))
1444
- return 0;
1445
- else
1446
- {
1447
- int yytype = YYTRANSLATE (yychar);
1448
- YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]);
1449
- YYSIZE_T yysize = yysize0;
1450
- YYSIZE_T yysize1;
1451
- int yysize_overflow = 0;
1452
- enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
1453
- char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
1454
- int yyx;
1455
-
1456
- # if 0
1457
- /* This is so xgettext sees the translatable formats that are
1458
- constructed on the fly. */
1459
- YY_("syntax error, unexpected %s");
1460
- YY_("syntax error, unexpected %s, expecting %s");
1461
- YY_("syntax error, unexpected %s, expecting %s or %s");
1462
- YY_("syntax error, unexpected %s, expecting %s or %s or %s");
1463
- YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s");
1464
- # endif
1465
- char *yyfmt;
1466
- char const *yyf;
1467
- static char const yyunexpected[] = "syntax error, unexpected %s";
1468
- static char const yyexpecting[] = ", expecting %s";
1469
- static char const yyor[] = " or %s";
1470
- char yyformat[sizeof yyunexpected
1471
- + sizeof yyexpecting - 1
1472
- + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2)
1473
- * (sizeof yyor - 1))];
1474
- char const *yyprefix = yyexpecting;
1475
-
1476
- /* Start YYX at -YYN if negative to avoid negative indexes in
1477
- YYCHECK. */
1478
- int yyxbegin = yyn < 0 ? -yyn : 0;
1479
-
1480
- /* Stay within bounds of both yycheck and yytname. */
1481
- int yychecklim = YYLAST - yyn + 1;
1482
- int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
1483
- int yycount = 1;
1484
-
1485
- yyarg[0] = yytname[yytype];
1486
- yyfmt = yystpcpy (yyformat, yyunexpected);
1487
-
1488
- for (yyx = yyxbegin; yyx < yyxend; ++yyx)
1489
- if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR)
1490
- {
1491
- if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
1492
- {
1493
- yycount = 1;
1494
- yysize = yysize0;
1495
- yyformat[sizeof yyunexpected - 1] = '\0';
1496
- break;
1497
- }
1498
- yyarg[yycount++] = yytname[yyx];
1499
- yysize1 = yysize + yytnamerr (0, yytname[yyx]);
1500
- yysize_overflow |= (yysize1 < yysize);
1501
- yysize = yysize1;
1502
- yyfmt = yystpcpy (yyfmt, yyprefix);
1503
- yyprefix = yyor;
1504
- }
1505
-
1506
- yyf = YY_(yyformat);
1507
- yysize1 = yysize + yystrlen (yyf);
1508
- yysize_overflow |= (yysize1 < yysize);
1509
- yysize = yysize1;
1510
-
1511
- if (yysize_overflow)
1512
- return YYSIZE_MAXIMUM;
1513
-
1514
- if (yyresult)
1515
- {
1516
- /* Avoid sprintf, as that infringes on the user's name space.
1517
- Don't have undefined behavior even if the translation
1518
- produced a string with the wrong number of "%s"s. */
1519
- char *yyp = yyresult;
1520
- int yyi = 0;
1521
- while ((*yyp = *yyf) != '\0')
1522
- {
1523
- if (*yyp == '%' && yyf[1] == 's' && yyi < yycount)
1524
- {
1525
- yyp += yytnamerr (yyp, yyarg[yyi++]);
1526
- yyf += 2;
1527
- }
1528
- else
1529
- {
1530
- yyp++;
1531
- yyf++;
1532
- }
1533
- }
1534
- }
1535
- return yysize;
1536
- }
1537
- }
1538
- #endif /* YYERROR_VERBOSE */
1539
-
1540
-
1541
- /*-----------------------------------------------.
1542
- | Release the memory associated to this symbol. |
1543
- `-----------------------------------------------*/
1544
-
1545
- /*ARGSUSED*/
1546
- #if (defined __STDC__ || defined __C99__FUNC__ \
1547
- || defined __cplusplus || defined _MSC_VER)
1548
- static void
1549
- yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, VALUE self)
1550
- #else
1551
- static void
1552
- yydestruct (yymsg, yytype, yyvaluep, self)
1553
- const char *yymsg;
1554
- int yytype;
1555
- YYSTYPE *yyvaluep;
1556
- VALUE self;
1557
- #endif
1558
- {
1559
- YYUSE (yyvaluep);
1560
- YYUSE (self);
1561
-
1562
- if (!yymsg)
1563
- yymsg = "Deleting";
1564
- YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
1565
-
1566
- switch (yytype)
1567
- {
1568
-
1569
- default:
1570
- break;
1571
- }
1572
- }
1573
-
1574
-
1575
- /* Prevent warnings from -Wmissing-prototypes. */
1576
-
1577
- #ifdef YYPARSE_PARAM
1578
- #if defined __STDC__ || defined __cplusplus
1579
- int yyparse (void *YYPARSE_PARAM);
1580
- #else
1581
- int yyparse ();
1582
- #endif
1583
- #else /* ! YYPARSE_PARAM */
1584
- #if defined __STDC__ || defined __cplusplus
1585
- int yyparse (VALUE self);
1586
- #else
1587
- int yyparse ();
1588
- #endif
1589
- #endif /* ! YYPARSE_PARAM */
1590
-
1591
-
1592
-
1593
- /* The look-ahead symbol. */
1594
- int yychar;
1595
-
1596
- /* The semantic value of the look-ahead symbol. */
1597
- YYSTYPE yylval;
1598
-
1599
- /* Number of syntax errors so far. */
1600
- int yynerrs;
1601
-
1602
-
1603
-
1604
- /*----------.
1605
- | yyparse. |
1606
- `----------*/
1607
-
1608
- #ifdef YYPARSE_PARAM
1609
- #if (defined __STDC__ || defined __C99__FUNC__ \
1610
- || defined __cplusplus || defined _MSC_VER)
1611
- int
1612
- yyparse (void *YYPARSE_PARAM)
1613
- #else
1614
- int
1615
- yyparse (YYPARSE_PARAM)
1616
- void *YYPARSE_PARAM;
1617
- #endif
1618
- #else /* ! YYPARSE_PARAM */
1619
- #if (defined __STDC__ || defined __C99__FUNC__ \
1620
- || defined __cplusplus || defined _MSC_VER)
1621
- int
1622
- yyparse (VALUE self)
1623
- #else
1624
- int
1625
- yyparse (self)
1626
- VALUE self;
1627
- #endif
1628
- #endif
1629
- {
1630
-
1631
- int yystate;
1632
- int yyn;
1633
- int yyresult;
1634
- /* Number of tokens to shift before error messages enabled. */
1635
- int yyerrstatus;
1636
- /* Look-ahead token as an internal (translated) token number. */
1637
- int yytoken = 0;
1638
- #if YYERROR_VERBOSE
1639
- /* Buffer for error messages, and its allocated size. */
1640
- char yymsgbuf[128];
1641
- char *yymsg = yymsgbuf;
1642
- YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
1643
- #endif
1644
-
1645
- /* Three stacks and their tools:
1646
- `yyss': related to states,
1647
- `yyvs': related to semantic values,
1648
- `yyls': related to locations.
1649
-
1650
- Refer to the stacks thru separate pointers, to allow yyoverflow
1651
- to reallocate them elsewhere. */
1652
-
1653
- /* The state stack. */
1654
- yytype_int16 yyssa[YYINITDEPTH];
1655
- yytype_int16 *yyss = yyssa;
1656
- yytype_int16 *yyssp;
1657
-
1658
- /* The semantic value stack. */
1659
- YYSTYPE yyvsa[YYINITDEPTH];
1660
- YYSTYPE *yyvs = yyvsa;
1661
- YYSTYPE *yyvsp;
1662
-
1663
-
1664
-
1665
- #define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N))
1666
-
1667
- YYSIZE_T yystacksize = YYINITDEPTH;
1668
-
1669
- /* The variables used to return semantic value and location from the
1670
- action routines. */
1671
- YYSTYPE yyval;
1672
-
1673
-
1674
- /* The number of symbols on the RHS of the reduced rule.
1675
- Keep to zero when no symbol should be popped. */
1676
- int yylen = 0;
1677
-
1678
- YYDPRINTF ((stderr, "Starting parse\n"));
1679
-
1680
- yystate = 0;
1681
- yyerrstatus = 0;
1682
- yynerrs = 0;
1683
- yychar = YYEMPTY; /* Cause a token to be read. */
1684
-
1685
- /* Initialize stack pointers.
1686
- Waste one element of value and location stack
1687
- so that they stay on the same level as the state stack.
1688
- The wasted elements are never initialized. */
1689
-
1690
- yyssp = yyss;
1691
- yyvsp = yyvs;
1692
-
1693
- goto yysetstate;
1694
-
1695
- /*------------------------------------------------------------.
1696
- | yynewstate -- Push a new state, which is found in yystate. |
1697
- `------------------------------------------------------------*/
1698
- yynewstate:
1699
- /* In all cases, when you get here, the value and location stacks
1700
- have just been pushed. So pushing a state here evens the stacks. */
1701
- yyssp++;
1702
-
1703
- yysetstate:
1704
- *yyssp = yystate;
1705
-
1706
- if (yyss + yystacksize - 1 <= yyssp)
1707
- {
1708
- /* Get the current used size of the three stacks, in elements. */
1709
- YYSIZE_T yysize = yyssp - yyss + 1;
1710
-
1711
- #ifdef yyoverflow
1712
- {
1713
- /* Give user a chance to reallocate the stack. Use copies of
1714
- these so that the &'s don't force the real ones into
1715
- memory. */
1716
- YYSTYPE *yyvs1 = yyvs;
1717
- yytype_int16 *yyss1 = yyss;
1718
-
1719
-
1720
- /* Each stack pointer address is followed by the size of the
1721
- data in use in that stack, in bytes. This used to be a
1722
- conditional around just the two extra args, but that might
1723
- be undefined if yyoverflow is a macro. */
1724
- yyoverflow (YY_("memory exhausted"),
1725
- &yyss1, yysize * sizeof (*yyssp),
1726
- &yyvs1, yysize * sizeof (*yyvsp),
1727
-
1728
- &yystacksize);
1729
-
1730
- yyss = yyss1;
1731
- yyvs = yyvs1;
1732
- }
1733
- #else /* no yyoverflow */
1734
- # ifndef YYSTACK_RELOCATE
1735
- goto yyexhaustedlab;
1736
- # else
1737
- /* Extend the stack our own way. */
1738
- if (YYMAXDEPTH <= yystacksize)
1739
- goto yyexhaustedlab;
1740
- yystacksize *= 2;
1741
- if (YYMAXDEPTH < yystacksize)
1742
- yystacksize = YYMAXDEPTH;
1743
-
1744
- {
1745
- yytype_int16 *yyss1 = yyss;
1746
- union yyalloc *yyptr =
1747
- (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
1748
- if (! yyptr)
1749
- goto yyexhaustedlab;
1750
- YYSTACK_RELOCATE (yyss);
1751
- YYSTACK_RELOCATE (yyvs);
1752
-
1753
- # undef YYSTACK_RELOCATE
1754
- if (yyss1 != yyssa)
1755
- YYSTACK_FREE (yyss1);
1756
- }
1757
- # endif
1758
- #endif /* no yyoverflow */
1759
-
1760
- yyssp = yyss + yysize - 1;
1761
- yyvsp = yyvs + yysize - 1;
1762
-
1763
-
1764
- YYDPRINTF ((stderr, "Stack size increased to %lu\n",
1765
- (unsigned long int) yystacksize));
1766
-
1767
- if (yyss + yystacksize - 1 <= yyssp)
1768
- YYABORT;
1769
- }
1770
-
1771
- YYDPRINTF ((stderr, "Entering state %d\n", yystate));
1772
-
1773
- goto yybackup;
1774
-
1775
- /*-----------.
1776
- | yybackup. |
1777
- `-----------*/
1778
- yybackup:
1779
-
1780
- /* Do appropriate processing given the current state. Read a
1781
- look-ahead token if we need one and don't already have one. */
1782
-
1783
- /* First try to decide what to do without reference to look-ahead token. */
1784
- yyn = yypact[yystate];
1785
- if (yyn == YYPACT_NINF)
1786
- goto yydefault;
1787
-
1788
- /* Not known => get a look-ahead token if don't already have one. */
1789
-
1790
- /* YYCHAR is either YYEMPTY or YYEOF or a valid look-ahead symbol. */
1791
- if (yychar == YYEMPTY)
1792
- {
1793
- YYDPRINTF ((stderr, "Reading a token: "));
1794
- yychar = YYLEX;
1795
- }
1796
-
1797
- if (yychar <= YYEOF)
1798
- {
1799
- yychar = yytoken = YYEOF;
1800
- YYDPRINTF ((stderr, "Now at end of input.\n"));
1801
- }
1802
- else
1803
- {
1804
- yytoken = YYTRANSLATE (yychar);
1805
- YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
1806
- }
1807
-
1808
- /* If the proper action on seeing token YYTOKEN is to reduce or to
1809
- detect an error, take that action. */
1810
- yyn += yytoken;
1811
- if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
1812
- goto yydefault;
1813
- yyn = yytable[yyn];
1814
- if (yyn <= 0)
1815
- {
1816
- if (yyn == 0 || yyn == YYTABLE_NINF)
1817
- goto yyerrlab;
1818
- yyn = -yyn;
1819
- goto yyreduce;
1820
- }
1821
-
1822
- if (yyn == YYFINAL)
1823
- YYACCEPT;
1824
-
1825
- /* Count tokens shifted since error; after three, turn off error
1826
- status. */
1827
- if (yyerrstatus)
1828
- yyerrstatus--;
1829
-
1830
- /* Shift the look-ahead token. */
1831
- YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
1832
-
1833
- /* Discard the shifted token unless it is eof. */
1834
- if (yychar != YYEOF)
1835
- yychar = YYEMPTY;
1836
-
1837
- yystate = yyn;
1838
- *++yyvsp = yylval;
1839
-
1840
- goto yynewstate;
1841
-
1842
-
1843
- /*-----------------------------------------------------------.
1844
- | yydefault -- do the default action for the current state. |
1845
- `-----------------------------------------------------------*/
1846
- yydefault:
1847
- yyn = yydefact[yystate];
1848
- if (yyn == 0)
1849
- goto yyerrlab;
1850
- goto yyreduce;
1851
-
1852
-
1853
- /*-----------------------------.
1854
- | yyreduce -- Do a reduction. |
1855
- `-----------------------------*/
1856
- yyreduce:
1857
- /* yyn is the number of a rule to reduce with. */
1858
- yylen = yyr2[yyn];
1859
-
1860
- /* If YYLEN is nonzero, implement the default value of the action:
1861
- `$$ = $1'.
1862
-
1863
- Otherwise, the following line sets YYVAL to garbage.
1864
- This behavior is undocumented and Bison
1865
- users should not rely upon it. Assigning to YYVAL
1866
- unconditionally makes the parser a bit smaller, and it avoids a
1867
- GCC warning that YYVAL may be used uninitialized. */
1868
- yyval = yyvsp[1-yylen];
1869
-
1870
-
1871
- YY_REDUCE_PRINT (yyn);
1872
- switch (yyn)
1873
- {
1874
- case 3:
1875
- #line 153 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1876
- {
1877
- rb_funcall(self, rb_intern("body="), 1, (yyvsp[(1) - (1)].object));
1878
- ;}
1879
- break;
1880
-
1881
- case 13:
1882
- #line 175 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1883
- {
1884
- (yyval.object) = rb_funcall(self, rb_intern("expr_list"), 2, INT2NUM(yylineno), (yyvsp[(1) - (1)].object));
1885
- ;}
1886
- break;
1887
-
1888
- case 14:
1889
- #line 178 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1890
- {
1891
- (yyval.object) = rb_funcall(self, rb_intern("expr_list"), 3, INT2NUM(yylineno), (yyvsp[(2) - (2)].object), (yyvsp[(1) - (2)].object));
1892
- ;}
1893
- break;
1894
-
1895
- case 15:
1896
- #line 181 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1897
- {
1898
- (yyval.object) = (yyvsp[(2) - (2)].object);
1899
- ;}
1900
- break;
1901
-
1902
- case 16:
1903
- #line 184 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1904
- {
1905
- (yyval.object) = (yyvsp[(1) - (2)].object);
1906
- ;}
1907
- break;
1908
-
1909
- case 17:
1910
- #line 189 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1911
- {
1912
- (yyval.object) = (yyvsp[(3) - (5)].object);
1913
- ;}
1914
- break;
1915
-
1916
- case 18:
1917
- #line 192 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1918
- {
1919
- (yyval.object) = rb_funcall(self, rb_intern("expr_list"), 1, INT2NUM(yylineno));
1920
- ;}
1921
- break;
1922
-
1923
- case 32:
1924
- #line 212 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1925
- { (yyval.object) = rb_funcall(self, rb_intern("super_exp"), 1, INT2NUM(yylineno)); ;}
1926
- break;
1927
-
1928
- case 33:
1929
- #line 213 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1930
- { (yyval.object) = rb_funcall(self, rb_intern("retry_exp"), 1, INT2NUM(yylineno)); ;}
1931
- break;
1932
-
1933
- case 34:
1934
- #line 214 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1935
- {
1936
- (yyval.object) = (yyvsp[(3) - (5)].object);
1937
- ;}
1938
- break;
1939
-
1940
- case 35:
1941
- #line 217 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1942
- {
1943
- (yyval.object) = (yyvsp[(1) - (3)].object);
1944
- ;}
1945
- break;
1946
-
1947
- case 36:
1948
- #line 222 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1949
- {
1950
- (yyval.object) = rb_funcall(self, rb_intern("assignment"), 3, INT2NUM(yylineno), (yyvsp[(1) - (4)].object), (yyvsp[(4) - (4)].object));
1951
- ;}
1952
- break;
1953
-
1954
- case 38:
1955
- #line 228 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1956
- {
1957
- (yyval.object) = rb_funcall(self, rb_intern("multiple_assignment"), 3, INT2NUM(yylineno), (yyvsp[(1) - (3)].object), (yyvsp[(3) - (3)].object));
1958
- ;}
1959
- break;
1960
-
1961
- case 39:
1962
- #line 233 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1963
- {
1964
- (yyval.object) = fy_terminal_node(self, "identifier");
1965
- ;}
1966
- break;
1967
-
1968
- case 40:
1969
- #line 238 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1970
- {
1971
- (yyval.object) = fy_terminal_node(self, "identifier");
1972
- ;}
1973
- break;
1974
-
1975
- case 41:
1976
- #line 243 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1977
- {
1978
- (yyval.object) = fy_terminal_node(self, "identifier");
1979
- ;}
1980
- break;
1981
-
1982
- case 42:
1983
- #line 246 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1984
- {
1985
- (yyval.object) = fy_terminal_node_from(self, "identifier", "match");
1986
- ;}
1987
- break;
1988
-
1989
- case 43:
1990
- #line 249 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1991
- {
1992
- (yyval.object) = fy_terminal_node_from(self, "identifier", "class");
1993
- ;}
1994
- break;
1995
-
1996
- case 46:
1997
- #line 258 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
1998
- {
1999
- (yyval.object) = (yyvsp[(1) - (1)].object);
2000
- ;}
2001
- break;
2002
-
2003
- case 47:
2004
- #line 261 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2005
- {
2006
- (yyval.object) = rb_funcall(self, rb_intern("identifier_list"), 3, INT2NUM(yylineno), (yyvsp[(1) - (3)].object), (yyvsp[(3) - (3)].object));
2007
- ;}
2008
- break;
2009
-
2010
- case 48:
2011
- #line 266 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2012
- {
2013
- (yyval.object) = rb_funcall(self, rb_intern("return_local"), 2, INT2NUM(yylineno), (yyvsp[(2) - (2)].object));
2014
- ;}
2015
- break;
2016
-
2017
- case 49:
2018
- #line 269 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2019
- {
2020
- (yyval.object) = rb_funcall(self, rb_intern("return_local"), 1, INT2NUM(yylineno));
2021
- ;}
2022
- break;
2023
-
2024
- case 50:
2025
- #line 274 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2026
- {
2027
- (yyval.object) = rb_funcall(self, rb_intern("return_stmt"), 2, INT2NUM(yylineno), (yyvsp[(2) - (2)].object));
2028
- ;}
2029
- break;
2030
-
2031
- case 51:
2032
- #line 277 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2033
- {
2034
- (yyval.object) = rb_funcall(self, rb_intern("return_stmt"), 1, INT2NUM(yylineno));
2035
- ;}
2036
- break;
2037
-
2038
- case 54:
2039
- #line 286 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2040
- {
2041
- (yyval.object) = rb_funcall(self, rb_intern("const_identifier"), 2, INT2NUM(yylineno), (yyvsp[(1) - (1)].object));
2042
- ;}
2043
- break;
2044
-
2045
- case 55:
2046
- #line 289 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2047
- {
2048
- (yyval.object) = rb_funcall(self, rb_intern("const_identifier"), 3, INT2NUM(yylineno), (yyvsp[(2) - (2)].object), (yyvsp[(1) - (2)].object));
2049
- ;}
2050
- break;
2051
-
2052
- case 56:
2053
- #line 294 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2054
- { (yyval.object) = rb_intern("public"); ;}
2055
- break;
2056
-
2057
- case 57:
2058
- #line 297 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2059
- {
2060
- (yyval.object) = rb_funcall(self, rb_intern("class_def"), 4, INT2NUM(yylineno), (yyvsp[(2) - (3)].object), Qnil, (yyvsp[(3) - (3)].object));
2061
- ;}
2062
- break;
2063
-
2064
- case 58:
2065
- #line 300 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2066
- {
2067
- (yyval.object) = rb_funcall(self, rb_intern("class_def"), 3, INT2NUM(yylineno), (yyvsp[(2) - (2)].object), Qnil);
2068
- ;}
2069
- break;
2070
-
2071
- case 59:
2072
- #line 305 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2073
- {
2074
- (yyval.object) = rb_funcall(self, rb_intern("class_def"), 4, INT2NUM(yylineno), (yyvsp[(2) - (5)].object), (yyvsp[(4) - (5)].object), (yyvsp[(5) - (5)].object));
2075
- ;}
2076
- break;
2077
-
2078
- case 60:
2079
- #line 308 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2080
- {
2081
- (yyval.object) = rb_funcall(self, rb_intern("class_def"), 3, INT2NUM(yylineno), (yyvsp[(2) - (4)].object), (yyvsp[(4) - (4)].object));
2082
- ;}
2083
- break;
2084
-
2085
- case 67:
2086
- #line 321 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2087
- {
2088
- (yyval.object) = rb_funcall(self, rb_intern("method_arg"), 3, INT2NUM(yylineno), (yyvsp[(1) - (3)].object), (yyvsp[(3) - (3)].object));
2089
- ;}
2090
- break;
2091
-
2092
- case 68:
2093
- #line 326 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2094
- {
2095
- (yyval.object) = rb_funcall(self, rb_intern("expr_ary"), 2, INT2NUM(yylineno), (yyvsp[(1) - (1)].object));
2096
- ;}
2097
- break;
2098
-
2099
- case 69:
2100
- #line 329 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2101
- {
2102
- (yyval.object) = rb_funcall(self, rb_intern("expr_ary"), 3, INT2NUM(yylineno), (yyvsp[(2) - (2)].object), (yyvsp[(1) - (2)].object));
2103
- ;}
2104
- break;
2105
-
2106
- case 70:
2107
- #line 332 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2108
- {
2109
- (yyval.object) = rb_funcall(self, rb_intern("expr_ary"), 3, INT2NUM(yylineno), (yyvsp[(2) - (2)].object), (yyvsp[(1) - (2)].object));
2110
- ;}
2111
- break;
2112
-
2113
- case 71:
2114
- #line 337 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2115
- {
2116
- (yyval.object) = rb_funcall(self, rb_intern("method_arg"), 4, INT2NUM(yylineno), (yyvsp[(1) - (8)].object), (yyvsp[(3) - (8)].object), (yyvsp[(6) - (8)].object));
2117
- ;}
2118
- break;
2119
-
2120
- case 72:
2121
- #line 342 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2122
- {
2123
- (yyval.object) = rb_funcall(self, rb_intern("expr_ary"), 2, INT2NUM(yylineno), (yyvsp[(1) - (1)].object));
2124
- ;}
2125
- break;
2126
-
2127
- case 73:
2128
- #line 345 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2129
- {
2130
- (yyval.object) = rb_funcall(self, rb_intern("expr_ary"), 3, INT2NUM(yylineno), (yyvsp[(3) - (3)].object), (yyvsp[(1) - (3)].object));
2131
- ;}
2132
- break;
2133
-
2134
- case 74:
2135
- #line 350 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2136
- {
2137
- (yyval.object) = rb_funcall(self, rb_intern("method_def_expand"), 4, INT2NUM(yylineno), (yyvsp[(2) - (3)].object), (yyvsp[(3) - (3)].object), (yyvsp[(1) - (3)].object));
2138
- ;}
2139
- break;
2140
-
2141
- case 75:
2142
- #line 353 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2143
- {
2144
- (yyval.object) = rb_funcall(self, rb_intern("method_def_expand"), 4, INT2NUM(yylineno), (yyvsp[(2) - (2)].object), Qnil, (yyvsp[(1) - (2)].object));
2145
- ;}
2146
- break;
2147
-
2148
- case 76:
2149
- #line 359 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2150
- {
2151
- (yyval.object) = rb_funcall(self, rb_intern("method_def_no_args"), 4, INT2NUM(yylineno), (yyvsp[(2) - (3)].object), (yyvsp[(3) - (3)].object), (yyvsp[(1) - (3)].object));
2152
- ;}
2153
- break;
2154
-
2155
- case 77:
2156
- #line 362 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2157
- {
2158
- (yyval.object) = rb_funcall(self, rb_intern("method_def_no_args"), 4, INT2NUM(yylineno), (yyvsp[(2) - (2)].object), Qnil, (yyvsp[(1) - (2)].object));
2159
- ;}
2160
- break;
2161
-
2162
- case 78:
2163
- #line 368 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2164
- {
2165
- (yyval.object) = rb_funcall(self, rb_intern("sin_method_def_expand"), 5, INT2NUM(yylineno), (yyvsp[(2) - (4)].object), (yyvsp[(3) - (4)].object), (yyvsp[(4) - (4)].object), (yyvsp[(1) - (4)].object));
2166
- ;}
2167
- break;
2168
-
2169
- case 79:
2170
- #line 371 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2171
- {
2172
- (yyval.object) = rb_funcall(self, rb_intern("sin_method_def_expand"), 5, INT2NUM(yylineno), (yyvsp[(2) - (3)].object), (yyvsp[(3) - (3)].object), Qnil, (yyvsp[(1) - (3)].object));
2173
- ;}
2174
- break;
2175
-
2176
- case 80:
2177
- #line 376 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2178
- {
2179
- (yyval.object) = rb_funcall(self, rb_intern("sin_method_def_no_args"), 5, INT2NUM(yylineno), (yyvsp[(2) - (4)].object), (yyvsp[(3) - (4)].object), (yyvsp[(4) - (4)].object), (yyvsp[(1) - (4)].object));
2180
- ;}
2181
- break;
2182
-
2183
- case 81:
2184
- #line 379 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2185
- {
2186
- (yyval.object) = rb_funcall(self, rb_intern("sin_method_def_no_args"), 5, INT2NUM(yylineno), (yyvsp[(2) - (3)].object), (yyvsp[(3) - (3)].object), Qnil, (yyvsp[(1) - (3)].object));
2187
- ;}
2188
- break;
2189
-
2190
- case 82:
2191
- #line 384 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2192
- {
2193
- (yyval.object) = rb_funcall(self, rb_intern("operator_def"), 5, INT2NUM(yylineno), (yyvsp[(2) - (4)].object), (yyvsp[(3) - (4)].object), (yyvsp[(4) - (4)].object), (yyvsp[(1) - (4)].object));
2194
- ;}
2195
- break;
2196
-
2197
- case 83:
2198
- #line 387 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2199
- {
2200
- (yyval.object) = rb_funcall(self, rb_intern("operator_def"), 5,
2201
- INT2NUM(yylineno), fy_terminal_node_from(self, "identifier", "[]"), (yyvsp[(3) - (5)].object), (yyvsp[(5) - (5)].object), (yyvsp[(1) - (5)].object));
2202
- ;}
2203
- break;
2204
-
2205
- case 84:
2206
- #line 391 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2207
- {
2208
- (yyval.object) = rb_funcall(self, rb_intern("operator_def_multi"), 6,
2209
- INT2NUM(yylineno), fy_terminal_node_from(self, "identifier", "[]:"), (yyvsp[(7) - (7)].object), (yyvsp[(1) - (7)].object), (yyvsp[(3) - (7)].object), (yyvsp[(6) - (7)].object));
2210
- ;}
2211
- break;
2212
-
2213
- case 85:
2214
- #line 397 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2215
- {
2216
- (yyval.object) = rb_funcall(self, rb_intern("sin_operator_def"), 6, INT2NUM(yylineno), (yyvsp[(2) - (5)].object), (yyvsp[(3) - (5)].object), (yyvsp[(4) - (5)].object), (yyvsp[(5) - (5)].object), (yyvsp[(1) - (5)].object));
2217
- ;}
2218
- break;
2219
-
2220
- case 86:
2221
- #line 400 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2222
- {
2223
- (yyval.object) = rb_funcall(self, rb_intern("sin_operator_def"), 6,
2224
- INT2NUM(yylineno), (yyvsp[(2) - (6)].object), fy_terminal_node_from(self, "identifier", "[]"), (yyvsp[(4) - (6)].object), (yyvsp[(6) - (6)].object), (yyvsp[(1) - (6)].object));
2225
- ;}
2226
- break;
2227
-
2228
- case 87:
2229
- #line 404 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2230
- {
2231
- (yyval.object) = rb_funcall(self, rb_intern("sin_operator_def_multi"), 7,
2232
- INT2NUM(yylineno), (yyvsp[(2) - (8)].object), fy_terminal_node_from(self, "identifier", "[]"), (yyvsp[(8) - (8)].object), (yyvsp[(1) - (8)].object), (yyvsp[(4) - (8)].object), (yyvsp[(7) - (8)].object));
2233
- ;}
2234
- break;
2235
-
2236
- case 88:
2237
- #line 410 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2238
- {
2239
- (yyval.object) = rb_funcall(self, rb_intern("msg_send_basic"), 3, INT2NUM(yylineno), (yyvsp[(1) - (2)].object), (yyvsp[(2) - (2)].object));
2240
- ;}
2241
- break;
2242
-
2243
- case 89:
2244
- #line 413 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2245
- {
2246
- (yyval.object) = rb_funcall(self, rb_intern("msg_send_args"), 3, INT2NUM(yylineno), (yyvsp[(1) - (2)].object), (yyvsp[(2) - (2)].object));
2247
- ;}
2248
- break;
2249
-
2250
- case 90:
2251
- #line 416 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2252
- {
2253
- (yyval.object) = rb_funcall(self, rb_intern("msg_send_args"), 3, INT2NUM(yylineno), Qnil, (yyvsp[(1) - (1)].object));
2254
- ;}
2255
- break;
2256
-
2257
- case 91:
2258
- #line 425 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2259
- {
2260
- // remove the trailing left paren and create an identifier.
2261
- (yyval.object) = fy_terminal_node(self, "ruby_send_open");
2262
- ;}
2263
- break;
2264
-
2265
- case 92:
2266
- #line 429 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2267
- {
2268
- // remove the trailing left paren and create an identifier.
2269
- (yyval.object) = fy_terminal_node(self, "ruby_send_open");
2270
- ;}
2271
- break;
2272
-
2273
- case 93:
2274
- #line 434 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2275
- {
2276
- (yyval.object) = rb_funcall(self, rb_intern("msg_send_ruby"), 4, INT2NUM(yylineno), (yyvsp[(1) - (3)].object), (yyvsp[(2) - (3)].object), (yyvsp[(3) - (3)].object));
2277
- ;}
2278
- break;
2279
-
2280
- case 94:
2281
- #line 437 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2282
- {
2283
- (yyval.object) = rb_funcall(self, rb_intern("msg_send_ruby"), 4, INT2NUM(yylineno), Qnil, (yyvsp[(1) - (2)].object), (yyvsp[(2) - (2)].object));
2284
- ;}
2285
- break;
2286
-
2287
- case 95:
2288
- #line 447 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2289
- {
2290
- (yyval.object) = rb_funcall(self, rb_intern("ruby_args"), 3, INT2NUM(yylineno), Qnil, (yyvsp[(2) - (2)].object));
2291
- ;}
2292
- break;
2293
-
2294
- case 96:
2295
- #line 450 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2296
- {
2297
- (yyval.object) = rb_funcall(self, rb_intern("ruby_args"), 3, INT2NUM(yylineno), (yyvsp[(1) - (3)].object), (yyvsp[(3) - (3)].object));
2298
- ;}
2299
- break;
2300
-
2301
- case 97:
2302
- #line 453 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2303
- {
2304
- (yyval.object) = rb_funcall(self, rb_intern("ruby_args"), 1, INT2NUM(yylineno));
2305
- ;}
2306
- break;
2307
-
2308
- case 98:
2309
- #line 456 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2310
- {
2311
- (yyval.object) = rb_funcall(self, rb_intern("ruby_args"), 2, INT2NUM(yylineno), (yyvsp[(1) - (2)].object));
2312
- ;}
2313
- break;
2314
-
2315
- case 99:
2316
- #line 461 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2317
- {
2318
- (yyval.object) = rb_funcall(self, rb_intern("oper_send_basic"), 4, INT2NUM(yylineno), (yyvsp[(1) - (3)].object), (yyvsp[(2) - (3)].object), (yyvsp[(3) - (3)].object));
2319
- ;}
2320
- break;
2321
-
2322
- case 100:
2323
- #line 464 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2324
- {
2325
- (yyval.object) = rb_funcall(self, rb_intern("oper_send_basic"), 4, INT2NUM(yylineno), (yyvsp[(1) - (5)].object), (yyvsp[(2) - (5)].object), (yyvsp[(5) - (5)].object));
2326
- ;}
2327
- break;
2328
-
2329
- case 101:
2330
- #line 467 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2331
- {
2332
- (yyval.object) = rb_funcall(self, rb_intern("oper_send_basic"), 4,
2333
- INT2NUM(yylineno), (yyvsp[(1) - (4)].object), fy_terminal_node_from(self, "identifier", "[]"), (yyvsp[(3) - (4)].object));
2334
- ;}
2335
- break;
2336
-
2337
- case 102:
2338
- #line 471 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2339
- {
2340
- (yyval.object) = rb_funcall(self, rb_intern("oper_send_multi"), 4,
2341
- INT2NUM(yylineno), (yyvsp[(1) - (6)].object), fy_terminal_node_from(self, "identifier", "[]"), (yyvsp[(3) - (6)].object), (yyvsp[(6) - (6)].object));
2342
- ;}
2343
- break;
2344
-
2345
- case 103:
2346
- #line 477 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2347
- {
2348
- (yyval.object) = rb_funcall(self, rb_intern("msg_send_ruby"), 4, INT2NUM(yylineno), (yyvsp[(1) - (3)].object), (yyvsp[(2) - (3)].object), (yyvsp[(3) - (3)].object));
2349
- ;}
2350
- break;
2351
-
2352
- case 104:
2353
- #line 483 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2354
- {
2355
- (yyval.object) = rb_funcall(self, rb_intern("send_args"), 3, INT2NUM(yylineno), (yyvsp[(1) - (3)].object), (yyvsp[(3) - (3)].object));
2356
- ;}
2357
- break;
2358
-
2359
- case 105:
2360
- #line 486 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2361
- {
2362
- (yyval.object) = rb_funcall(self, rb_intern("send_args"), 3, INT2NUM(yylineno), (yyvsp[(1) - (4)].object), (yyvsp[(4) - (4)].object));
2363
- ;}
2364
- break;
2365
-
2366
- case 106:
2367
- #line 489 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2368
- {
2369
- (yyval.object) = rb_funcall(self, rb_intern("send_args"), 4, INT2NUM(yylineno), (yyvsp[(2) - (4)].object), (yyvsp[(4) - (4)].object), (yyvsp[(1) - (4)].object));
2370
- ;}
2371
- break;
2372
-
2373
- case 107:
2374
- #line 492 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2375
- {
2376
- (yyval.object) = rb_funcall(self, rb_intern("send_args"), 4, INT2NUM(yylineno), (yyvsp[(2) - (5)].object), (yyvsp[(5) - (5)].object), (yyvsp[(1) - (5)].object));
2377
- ;}
2378
- break;
2379
-
2380
- case 108:
2381
- #line 497 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2382
- {
2383
- (yyval.object) = (yyvsp[(1) - (1)].object);
2384
- ;}
2385
- break;
2386
-
2387
- case 109:
2388
- #line 500 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2389
- {
2390
- (yyval.object) = (yyvsp[(2) - (3)].object);
2391
- ;}
2392
- break;
2393
-
2394
- case 110:
2395
- #line 503 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2396
- {
2397
- (yyval.object) = (yyvsp[(1) - (1)].object);
2398
- ;}
2399
- break;
2400
-
2401
- case 111:
2402
- #line 506 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2403
- {
2404
- (yyval.object) = (yyvsp[(2) - (2)].object);
2405
- ;}
2406
- break;
2407
-
2408
- case 112:
2409
- #line 511 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2410
- {
2411
- (yyval.object) = rb_funcall(self, rb_intern("try_catch_finally"), 4, INT2NUM(yylineno), (yyvsp[(2) - (4)].object), (yyvsp[(3) - (4)].object), (yyvsp[(4) - (4)].object));
2412
- ;}
2413
- break;
2414
-
2415
- case 113:
2416
- #line 514 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2417
- {
2418
- (yyval.object) = rb_funcall(self, rb_intern("try_catch_finally"), 3, INT2NUM(yylineno), (yyvsp[(2) - (3)].object), (yyvsp[(3) - (3)].object));
2419
- ;}
2420
- break;
2421
-
2422
- case 114:
2423
- #line 519 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2424
- {
2425
- (yyval.object) = rb_funcall(self, rb_intern("catch_handler"), 2, INT2NUM(yylineno), (yyvsp[(2) - (2)].object));
2426
- ;}
2427
- break;
2428
-
2429
- case 115:
2430
- #line 522 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2431
- {
2432
- (yyval.object) = rb_funcall(self, rb_intern("catch_handler"), 3, INT2NUM(yylineno), (yyvsp[(3) - (3)].object), (yyvsp[(2) - (3)].object));
2433
- ;}
2434
- break;
2435
-
2436
- case 116:
2437
- #line 525 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2438
- {
2439
- (yyval.object) = rb_funcall(self, rb_intern("catch_handler"), 4, INT2NUM(yylineno), (yyvsp[(5) - (5)].object), (yyvsp[(2) - (5)].object), (yyvsp[(4) - (5)].object));
2440
- ;}
2441
- break;
2442
-
2443
- case 117:
2444
- #line 530 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2445
- {
2446
- (yyval.object) = rb_funcall(self, rb_intern("catch_handlers"), 2, INT2NUM(yylineno), (yyvsp[(1) - (1)].object));
2447
- ;}
2448
- break;
2449
-
2450
- case 118:
2451
- #line 533 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2452
- {
2453
- (yyval.object) = rb_funcall(self, rb_intern("catch_handlers"), 3, INT2NUM(yylineno), (yyvsp[(2) - (2)].object), (yyvsp[(1) - (2)].object));
2454
- ;}
2455
- break;
2456
-
2457
- case 119:
2458
- #line 538 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2459
- {
2460
- (yyval.object) = rb_funcall(self, rb_intern("catch_handlers"), 2, INT2NUM(yylineno), (yyvsp[(1) - (1)].object));
2461
- ;}
2462
- break;
2463
-
2464
- case 120:
2465
- #line 541 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2466
- {
2467
- (yyval.object) = rb_funcall(self, rb_intern("catch_handlers"), 3, INT2NUM(yylineno), (yyvsp[(2) - (2)].object), (yyvsp[(1) - (2)].object));
2468
- ;}
2469
- break;
2470
-
2471
- case 121:
2472
- #line 544 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2473
- {
2474
- (yyval.object) = rb_funcall(self, rb_intern("catch_handlers"), 1, INT2NUM(yylineno));
2475
- ;}
2476
- break;
2477
-
2478
- case 122:
2479
- #line 549 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2480
- {
2481
- (yyval.object) = (yyvsp[(2) - (2)].object);
2482
- ;}
2483
- break;
2484
-
2485
- case 123:
2486
- #line 554 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2487
- {
2488
- (yyval.object) = fy_terminal_node(self, "integer_literal");
2489
- ;}
2490
- break;
2491
-
2492
- case 124:
2493
- #line 558 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2494
- {
2495
- (yyval.object) = fy_terminal_node(self, "double_literal");
2496
- ;}
2497
- break;
2498
-
2499
- case 125:
2500
- #line 562 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2501
- {
2502
- (yyval.object) = fy_terminal_node(self, "string_literal");
2503
- ;}
2504
- break;
2505
-
2506
- case 126:
2507
- #line 565 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2508
- {
2509
- (yyval.object) = fy_terminal_node(self, "multiline_string_literal");
2510
- ;}
2511
- break;
2512
-
2513
- case 127:
2514
- #line 569 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2515
- {
2516
- (yyval.object) = fy_terminal_node(self, "symbol_literal");
2517
- ;}
2518
- break;
2519
-
2520
- case 128:
2521
- #line 573 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2522
- {
2523
- (yyval.object) = fy_terminal_node(self, "regex_literal");
2524
- ;}
2525
- break;
2526
-
2527
- case 129:
2528
- #line 578 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2529
- {
2530
- (yyval.object) = rb_funcall(self, rb_intern("integer_literal"), 3,
2531
- INT2NUM(yylineno), rb_str_new2(yytext), INT2NUM(16));
2532
- ;}
2533
- break;
2534
-
2535
- case 130:
2536
- #line 584 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2537
- {
2538
- (yyval.object) = rb_funcall(self, rb_intern("integer_literal"), 3,
2539
- INT2NUM(yylineno), rb_str_new2(yytext), INT2NUM(8));
2540
- ;}
2541
- break;
2542
-
2543
- case 131:
2544
- #line 590 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2545
- {
2546
- (yyval.object) = rb_funcall(self, rb_intern("integer_literal"), 3,
2547
- INT2NUM(yylineno), rb_str_new2(yytext), INT2NUM(2));
2548
- ;}
2549
- break;
2550
-
2551
- case 145:
2552
- #line 611 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2553
- {
2554
- (yyval.object) = (yyvsp[(1) - (1)].object);
2555
- ;}
2556
- break;
2557
-
2558
- case 146:
2559
- #line 614 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2560
- {
2561
- (yyval.object) = rb_funcall(self, rb_intern("array_literal"), 2, INT2NUM(yylineno), (yyvsp[(3) - (5)].object));
2562
- ;}
2563
- break;
2564
-
2565
- case 147:
2566
- #line 619 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2567
- {
2568
- (yyval.object) = rb_funcall(self, rb_intern("expr_ary"), 2, INT2NUM(yylineno), (yyvsp[(1) - (1)].object));
2569
- ;}
2570
- break;
2571
-
2572
- case 148:
2573
- #line 622 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2574
- {
2575
- (yyval.object) = rb_funcall(self, rb_intern("expr_ary"), 3, INT2NUM(yylineno), (yyvsp[(4) - (4)].object), (yyvsp[(1) - (4)].object));
2576
- ;}
2577
- break;
2578
-
2579
- case 149:
2580
- #line 625 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2581
- {
2582
- (yyval.object) = (yyvsp[(1) - (2)].object);
2583
- ;}
2584
- break;
2585
-
2586
- case 150:
2587
- #line 630 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2588
- {
2589
- (yyval.object) = rb_funcall(self, rb_intern("array_literal"), 1, INT2NUM(yylineno));
2590
- ;}
2591
- break;
2592
-
2593
- case 151:
2594
- #line 635 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2595
- {
2596
- (yyval.object) = rb_funcall(self, rb_intern("hash_literal"), 2, INT2NUM(yylineno), (yyvsp[(3) - (5)].object));
2597
- ;}
2598
- break;
2599
-
2600
- case 152:
2601
- #line 638 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2602
- {
2603
- (yyval.object) = rb_funcall(self, rb_intern("hash_literal"), 1, INT2NUM(yylineno));
2604
- ;}
2605
- break;
2606
-
2607
- case 153:
2608
- #line 643 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2609
- {
2610
- (yyval.object) = rb_funcall(self, rb_intern("block_literal"), 3, INT2NUM(yylineno), Qnil, (yyvsp[(1) - (1)].object));
2611
- ;}
2612
- break;
2613
-
2614
- case 154:
2615
- #line 646 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2616
- {
2617
- (yyval.object) = rb_funcall(self, rb_intern("block_literal"), 3, INT2NUM(yylineno), (yyvsp[(2) - (5)].object), (yyvsp[(5) - (5)].object));
2618
- ;}
2619
- break;
2620
-
2621
- case 155:
2622
- #line 651 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2623
- {
2624
- (yyval.object) = rb_funcall(self, rb_intern("tuple_literal"), 2, INT2NUM(yylineno), (yyvsp[(2) - (3)].object));
2625
- ;}
2626
- break;
2627
-
2628
- case 156:
2629
- #line 656 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2630
- {
2631
- (yyval.object) = rb_funcall(self, rb_intern("range_literal"), 3, INT2NUM(yylineno), (yyvsp[(2) - (6)].object), (yyvsp[(5) - (6)].object));
2632
- ;}
2633
- break;
2634
-
2635
- case 159:
2636
- #line 665 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2637
- {
2638
- (yyval.object) = rb_funcall(self, rb_intern("block_args"), 2, INT2NUM(yylineno), (yyvsp[(1) - (1)].object));
2639
- ;}
2640
- break;
2641
-
2642
- case 160:
2643
- #line 668 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2644
- {
2645
- (yyval.object) = rb_funcall(self, rb_intern("block_args"), 3, INT2NUM(yylineno), (yyvsp[(2) - (2)].object), (yyvsp[(1) - (2)].object));
2646
- ;}
2647
- break;
2648
-
2649
- case 161:
2650
- #line 673 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2651
- {
2652
- (yyval.object) = rb_funcall(self, rb_intern("block_args"), 2, INT2NUM(yylineno), (yyvsp[(1) - (1)].object));
2653
- ;}
2654
- break;
2655
-
2656
- case 162:
2657
- #line 676 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2658
- {
2659
- (yyval.object) = rb_funcall(self, rb_intern("block_args"), 3, INT2NUM(yylineno), (yyvsp[(3) - (3)].object), (yyvsp[(1) - (3)].object));
2660
- ;}
2661
- break;
2662
-
2663
- case 163:
2664
- #line 681 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2665
- {
2666
- (yyval.object) = rb_funcall(self, rb_intern("key_value_list"), 3, INT2NUM(yylineno), (yyvsp[(1) - (5)].object), (yyvsp[(5) - (5)].object));
2667
- ;}
2668
- break;
2669
-
2670
- case 164:
2671
- #line 684 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2672
- {
2673
- (yyval.object) = rb_funcall(self, rb_intern("key_value_list"), 4, INT2NUM(yylineno), (yyvsp[(4) - (8)].object), (yyvsp[(8) - (8)].object), (yyvsp[(1) - (8)].object));
2674
- ;}
2675
- break;
2676
-
2677
- case 165:
2678
- #line 689 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2679
- {
2680
- (yyval.object) = rb_funcall(self, rb_intern("match_expr"), 3, INT2NUM(yylineno), (yyvsp[(2) - (7)].object), (yyvsp[(5) - (7)].object));
2681
- ;}
2682
- break;
2683
-
2684
- case 166:
2685
- #line 694 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2686
- {
2687
- (yyval.object) = rb_funcall(self, rb_intern("match_body"), 2, INT2NUM(yylineno), (yyvsp[(1) - (1)].object));
2688
- ;}
2689
- break;
2690
-
2691
- case 167:
2692
- #line 697 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2693
- {
2694
- (yyval.object) = rb_funcall(self, rb_intern("match_body"), 3, INT2NUM(yylineno), (yyvsp[(2) - (2)].object), (yyvsp[(1) - (2)].object));
2695
- ;}
2696
- break;
2697
-
2698
- case 168:
2699
- #line 702 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2700
- {
2701
- (yyval.object) = rb_funcall(self, rb_intern("match_clause"), 3, INT2NUM(yylineno), (yyvsp[(2) - (4)].object), (yyvsp[(4) - (4)].object));
2702
- ;}
2703
- break;
2704
-
2705
- case 169:
2706
- #line 705 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2707
- {
2708
- (yyval.object) = rb_funcall(self, rb_intern("match_clause"), 4, INT2NUM(yylineno), (yyvsp[(2) - (7)].object), (yyvsp[(7) - (7)].object), (yyvsp[(5) - (7)].object));
2709
- ;}
2710
- break;
2711
-
2712
-
2713
- /* Line 1267 of yacc.c. */
2714
- #line 2715 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.c"
2715
- default: break;
2716
- }
2717
- YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
2718
-
2719
- YYPOPSTACK (yylen);
2720
- yylen = 0;
2721
- YY_STACK_PRINT (yyss, yyssp);
2722
-
2723
- *++yyvsp = yyval;
2724
-
2725
-
2726
- /* Now `shift' the result of the reduction. Determine what state
2727
- that goes to, based on the state we popped back to and the rule
2728
- number reduced by. */
2729
-
2730
- yyn = yyr1[yyn];
2731
-
2732
- yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
2733
- if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
2734
- yystate = yytable[yystate];
2735
- else
2736
- yystate = yydefgoto[yyn - YYNTOKENS];
2737
-
2738
- goto yynewstate;
2739
-
2740
-
2741
- /*------------------------------------.
2742
- | yyerrlab -- here on detecting error |
2743
- `------------------------------------*/
2744
- yyerrlab:
2745
- /* If not already recovering from an error, report this error. */
2746
- if (!yyerrstatus)
2747
- {
2748
- ++yynerrs;
2749
- #if ! YYERROR_VERBOSE
2750
- yyerror (self, YY_("syntax error"));
2751
- #else
2752
- {
2753
- YYSIZE_T yysize = yysyntax_error (0, yystate, yychar);
2754
- if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM)
2755
- {
2756
- YYSIZE_T yyalloc = 2 * yysize;
2757
- if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM))
2758
- yyalloc = YYSTACK_ALLOC_MAXIMUM;
2759
- if (yymsg != yymsgbuf)
2760
- YYSTACK_FREE (yymsg);
2761
- yymsg = (char *) YYSTACK_ALLOC (yyalloc);
2762
- if (yymsg)
2763
- yymsg_alloc = yyalloc;
2764
- else
2765
- {
2766
- yymsg = yymsgbuf;
2767
- yymsg_alloc = sizeof yymsgbuf;
2768
- }
2769
- }
2770
-
2771
- if (0 < yysize && yysize <= yymsg_alloc)
2772
- {
2773
- (void) yysyntax_error (yymsg, yystate, yychar);
2774
- yyerror (self, yymsg);
2775
- }
2776
- else
2777
- {
2778
- yyerror (self, YY_("syntax error"));
2779
- if (yysize != 0)
2780
- goto yyexhaustedlab;
2781
- }
2782
- }
2783
- #endif
2784
- }
2785
-
2786
-
2787
-
2788
- if (yyerrstatus == 3)
2789
- {
2790
- /* If just tried and failed to reuse look-ahead token after an
2791
- error, discard it. */
2792
-
2793
- if (yychar <= YYEOF)
2794
- {
2795
- /* Return failure if at end of input. */
2796
- if (yychar == YYEOF)
2797
- YYABORT;
2798
- }
2799
- else
2800
- {
2801
- yydestruct ("Error: discarding",
2802
- yytoken, &yylval, self);
2803
- yychar = YYEMPTY;
2804
- }
2805
- }
2806
-
2807
- /* Else will try to reuse look-ahead token after shifting the error
2808
- token. */
2809
- goto yyerrlab1;
2810
-
2811
-
2812
- /*---------------------------------------------------.
2813
- | yyerrorlab -- error raised explicitly by YYERROR. |
2814
- `---------------------------------------------------*/
2815
- yyerrorlab:
2816
-
2817
- /* Pacify compilers like GCC when the user code never invokes
2818
- YYERROR and the label yyerrorlab therefore never appears in user
2819
- code. */
2820
- if (/*CONSTCOND*/ 0)
2821
- goto yyerrorlab;
2822
-
2823
- /* Do not reclaim the symbols of the rule which action triggered
2824
- this YYERROR. */
2825
- YYPOPSTACK (yylen);
2826
- yylen = 0;
2827
- YY_STACK_PRINT (yyss, yyssp);
2828
- yystate = *yyssp;
2829
- goto yyerrlab1;
2830
-
2831
-
2832
- /*-------------------------------------------------------------.
2833
- | yyerrlab1 -- common code for both syntax error and YYERROR. |
2834
- `-------------------------------------------------------------*/
2835
- yyerrlab1:
2836
- yyerrstatus = 3; /* Each real token shifted decrements this. */
2837
-
2838
- for (;;)
2839
- {
2840
- yyn = yypact[yystate];
2841
- if (yyn != YYPACT_NINF)
2842
- {
2843
- yyn += YYTERROR;
2844
- if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
2845
- {
2846
- yyn = yytable[yyn];
2847
- if (0 < yyn)
2848
- break;
2849
- }
2850
- }
2851
-
2852
- /* Pop the current state because it cannot handle the error token. */
2853
- if (yyssp == yyss)
2854
- YYABORT;
2855
-
2856
-
2857
- yydestruct ("Error: popping",
2858
- yystos[yystate], yyvsp, self);
2859
- YYPOPSTACK (1);
2860
- yystate = *yyssp;
2861
- YY_STACK_PRINT (yyss, yyssp);
2862
- }
2863
-
2864
- if (yyn == YYFINAL)
2865
- YYACCEPT;
2866
-
2867
- *++yyvsp = yylval;
2868
-
2869
-
2870
- /* Shift the error token. */
2871
- YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
2872
-
2873
- yystate = yyn;
2874
- goto yynewstate;
2875
-
2876
-
2877
- /*-------------------------------------.
2878
- | yyacceptlab -- YYACCEPT comes here. |
2879
- `-------------------------------------*/
2880
- yyacceptlab:
2881
- yyresult = 0;
2882
- goto yyreturn;
2883
-
2884
- /*-----------------------------------.
2885
- | yyabortlab -- YYABORT comes here. |
2886
- `-----------------------------------*/
2887
- yyabortlab:
2888
- yyresult = 1;
2889
- goto yyreturn;
2890
-
2891
- #ifndef yyoverflow
2892
- /*-------------------------------------------------.
2893
- | yyexhaustedlab -- memory exhaustion comes here. |
2894
- `-------------------------------------------------*/
2895
- yyexhaustedlab:
2896
- yyerror (self, YY_("memory exhausted"));
2897
- yyresult = 2;
2898
- /* Fall through. */
2899
- #endif
2900
-
2901
- yyreturn:
2902
- if (yychar != YYEOF && yychar != YYEMPTY)
2903
- yydestruct ("Cleanup: discarding lookahead",
2904
- yytoken, &yylval, self);
2905
- /* Do not reclaim the symbols of the rule which action triggered
2906
- this YYABORT or YYACCEPT. */
2907
- YYPOPSTACK (yylen);
2908
- YY_STACK_PRINT (yyss, yyssp);
2909
- while (yyssp != yyss)
2910
- {
2911
- yydestruct ("Cleanup: popping",
2912
- yystos[*yyssp], yyvsp, self);
2913
- YYPOPSTACK (1);
2914
- }
2915
- #ifndef yyoverflow
2916
- if (yyss != yyssa)
2917
- YYSTACK_FREE (yyss);
2918
- #endif
2919
- #if YYERROR_VERBOSE
2920
- if (yymsg != yymsgbuf)
2921
- YYSTACK_FREE (yymsg);
2922
- #endif
2923
- /* Make sure YYID is used. */
2924
- return YYID (yyresult);
2925
- }
2926
-
2927
-
2928
- #line 710 "/Users/backtype/projects/fancy/boot/rbx-compiler/parser/parser.y"
2929
-
2930
-
2931
-
2932
- VALUE fy_terminal_node(VALUE self, char* method) {
2933
- return rb_funcall(self, rb_intern(method), 2, INT2NUM(yylineno), rb_str_new2(yytext));
2934
- }
2935
-
2936
- VALUE fy_terminal_node_from(VALUE self, char* method, char* text) {
2937
- return rb_funcall(self, rb_intern(method), 2, INT2NUM(yylineno), rb_str_new2(text));
2938
- }
2939
-
2940
- int yyerror(VALUE self, char *s)
2941
- {
2942
- rb_funcall(self, rb_intern("parse_error"), 2, INT2NUM(yylineno), rb_str_new2(yytext));
2943
- return 1;
2944
- }
2945
-
2946
-