GNU Octave  4.0.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
oct-parse.h
Go to the documentation of this file.
1 /* A Bison parser, made by GNU Bison 3.0.2. */
2 
3 /* Bison interface for Yacc-like parsers in C
4 
5  Copyright (C) 1984, 1989-1990, 2000-2013 Free Software Foundation, Inc.
6 
7  This program is free software: you can redistribute it and/or modify
8  it under the terms of the GNU General Public License as published by
9  the Free Software Foundation, either version 3 of the License, or
10  (at your option) any later version.
11 
12  This program is distributed in the hope that it will be useful,
13  but WITHOUT ANY WARRANTY; without even the implied warranty of
14  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  GNU General Public License for more details.
16 
17  You should have received a copy of the GNU General Public License
18  along with this program. If not, see <http://www.gnu.org/licenses/>. */
19 
20 /* As a special exception, you may create a larger work that contains
21  part or all of the Bison parser skeleton and distribute that work
22  under terms of your choice, so long as that work isn't itself a
23  parser generator using the skeleton or a modified version thereof
24  as a parser skeleton. Alternatively, if you modify or redistribute
25  the parser skeleton itself, you may (at your option) remove this
26  special exception, which will cause the skeleton and the resulting
27  Bison output files to be licensed under the GNU General Public
28  License without this special exception.
29 
30  This special exception was added by the Free Software Foundation in
31  version 2.2 of Bison. */
32 
33 #ifndef YY_OCTAVE_PARSE_TREE_OCT_PARSE_H_INCLUDED
34 # define YY_OCTAVE_PARSE_TREE_OCT_PARSE_H_INCLUDED
35 /* Debug traces. */
36 #ifndef OCTAVE_DEBUG
37 # if defined YYDEBUG
38 #if YYDEBUG
39 # define OCTAVE_DEBUG 1
40 # else
41 # define OCTAVE_DEBUG 0
42 # endif
43 # else /* ! defined YYDEBUG */
44 # define OCTAVE_DEBUG 0
45 # endif /* ! defined YYDEBUG */
46 #endif /* ! defined OCTAVE_DEBUG */
47 #if OCTAVE_DEBUG
48 extern int octave_debug;
49 #endif
50 
51 /* Token type. */
52 #ifndef OCTAVE_TOKENTYPE
53 # define OCTAVE_TOKENTYPE
55  {
56  ADD_EQ = 258,
57  SUB_EQ = 259,
58  MUL_EQ = 260,
59  DIV_EQ = 261,
60  LEFTDIV_EQ = 262,
61  POW_EQ = 263,
62  EMUL_EQ = 264,
63  EDIV_EQ = 265,
64  ELEFTDIV_EQ = 266,
65  EPOW_EQ = 267,
66  AND_EQ = 268,
67  OR_EQ = 269,
68  LSHIFT_EQ = 270,
69  RSHIFT_EQ = 271,
70  LSHIFT = 272,
71  RSHIFT = 273,
72  EXPR_AND_AND = 274,
73  EXPR_OR_OR = 275,
74  EXPR_AND = 276,
75  EXPR_OR = 277,
76  EXPR_NOT = 278,
77  EXPR_LT = 279,
78  EXPR_LE = 280,
79  EXPR_EQ = 281,
80  EXPR_NE = 282,
81  EXPR_GE = 283,
82  EXPR_GT = 284,
83  LEFTDIV = 285,
84  EMUL = 286,
85  EDIV = 287,
86  ELEFTDIV = 288,
87  EPLUS = 289,
88  EMINUS = 290,
89  HERMITIAN = 291,
90  TRANSPOSE = 292,
91  PLUS_PLUS = 293,
92  MINUS_MINUS = 294,
93  POW = 295,
94  EPOW = 296,
95  NUM = 297,
96  IMAG_NUM = 298,
97  STRUCT_ELT = 299,
98  NAME = 300,
99  END = 301,
100  DQ_STRING = 302,
101  SQ_STRING = 303,
102  FOR = 304,
103  PARFOR = 305,
104  WHILE = 306,
105  DO = 307,
106  UNTIL = 308,
107  IF = 309,
108  ELSEIF = 310,
109  ELSE = 311,
110  SWITCH = 312,
111  CASE = 313,
112  OTHERWISE = 314,
113  BREAK = 315,
114  CONTINUE = 316,
115  FUNC_RET = 317,
116  UNWIND = 318,
117  CLEANUP = 319,
118  TRY = 320,
119  CATCH = 321,
120  GLOBAL = 322,
121  PERSISTENT = 323,
122  FCN_HANDLE = 324,
123  CLASSDEF = 325,
124  PROPERTIES = 326,
125  METHODS = 327,
126  EVENTS = 328,
127  ENUMERATION = 329,
128  METAQUERY = 330,
130  FQ_IDENT = 332,
131  GET = 333,
132  SET = 334,
133  FCN = 335,
136  INPUT_FILE = 338,
137  UNARY = 339
138  };
139 #endif
140 /* Tokens. */
141 #define ADD_EQ 258
142 #define SUB_EQ 259
143 #define MUL_EQ 260
144 #define DIV_EQ 261
145 #define LEFTDIV_EQ 262
146 #define POW_EQ 263
147 #define EMUL_EQ 264
148 #define EDIV_EQ 265
149 #define ELEFTDIV_EQ 266
150 #define EPOW_EQ 267
151 #define AND_EQ 268
152 #define OR_EQ 269
153 #define LSHIFT_EQ 270
154 #define RSHIFT_EQ 271
155 #define LSHIFT 272
156 #define RSHIFT 273
157 #define EXPR_AND_AND 274
158 #define EXPR_OR_OR 275
159 #define EXPR_AND 276
160 #define EXPR_OR 277
161 #define EXPR_NOT 278
162 #define EXPR_LT 279
163 #define EXPR_LE 280
164 #define EXPR_EQ 281
165 #define EXPR_NE 282
166 #define EXPR_GE 283
167 #define EXPR_GT 284
168 #define LEFTDIV 285
169 #define EMUL 286
170 #define EDIV 287
171 #define ELEFTDIV 288
172 #define EPLUS 289
173 #define EMINUS 290
174 #define HERMITIAN 291
175 #define TRANSPOSE 292
176 #define PLUS_PLUS 293
177 #define MINUS_MINUS 294
178 #define POW 295
179 #define EPOW 296
180 #define NUM 297
181 #define IMAG_NUM 298
182 #define STRUCT_ELT 299
183 #define NAME 300
184 #define END 301
185 #define DQ_STRING 302
186 #define SQ_STRING 303
187 #define FOR 304
188 #define PARFOR 305
189 #define WHILE 306
190 #define DO 307
191 #define UNTIL 308
192 #define IF 309
193 #define ELSEIF 310
194 #define ELSE 311
195 #define SWITCH 312
196 #define CASE 313
197 #define OTHERWISE 314
198 #define BREAK 315
199 #define CONTINUE 316
200 #define FUNC_RET 317
201 #define UNWIND 318
202 #define CLEANUP 319
203 #define TRY 320
204 #define CATCH 321
205 #define GLOBAL 322
206 #define PERSISTENT 323
207 #define FCN_HANDLE 324
208 #define CLASSDEF 325
209 #define PROPERTIES 326
210 #define METHODS 327
211 #define EVENTS 328
212 #define ENUMERATION 329
213 #define METAQUERY 330
214 #define SUPERCLASSREF 331
215 #define FQ_IDENT 332
216 #define GET 333
217 #define SET 334
218 #define FCN 335
219 #define END_OF_INPUT 336
220 #define LEXICAL_ERROR 337
221 #define INPUT_FILE 338
222 #define UNARY 339
223 
224 /* Value type. */
225 #if ! defined OCTAVE_STYPE && ! defined OCTAVE_STYPE_IS_DECLARED
228 {
229 #line 150 "parse-tree/oct-parse.yy" /* yacc.c:1909 */
230 
232 
233  // The type of the basic tokens returned by the lexer.
235 
236  // Comment strings that we need to deal with mid-rule.
238 
239  // Types for the nonterminals we generate.
268 
286 
287 #line 288 "parse-tree/oct-parse.h" /* yacc.c:1909 */
288 };
289 # define OCTAVE_STYPE_IS_TRIVIAL 1
290 # define OCTAVE_STYPE_IS_DECLARED 1
291 #endif
292 
293 
294 
295 #ifndef YYPUSH_MORE_DEFINED
296 # define YYPUSH_MORE_DEFINED
297 enum { YYPUSH_MORE = 4 };
298 #endif
299 
301 
303 int octave_push_parse (octave_pstate *ps, int pushed_char, OCTAVE_STYPE const *pushed_val, octave_base_parser& parser);
307 
308 #endif /* !YY_OCTAVE_PARSE_TREE_OCT_PARSE_H_INCLUDED */
#define AND_EQ
Definition: oct-parse.h:151
#define RSHIFT_EQ
Definition: oct-parse.h:154
tree_decl_init_list * tree_decl_init_list_type
Definition: oct-parse.h:263
tree_classdef_enum_block * tree_classdef_enum_block_type
Definition: oct-parse.h:285
tree_expression * tree_expression_type
Definition: oct-parse.h:244
tree_switch_case_list * tree_switch_case_list_type
Definition: oct-parse.h:261
int octave_parse(octave_base_parser &parser)
Definition: oct-parse.cc:2984
#define EMUL
Definition: oct-parse.h:169
#define EVENTS
Definition: oct-parse.h:211
tree_classdef_superclass * tree_classdef_superclass_type
Definition: oct-parse.h:272
tree_if_command_list * tree_if_command_list_type
Definition: oct-parse.h:258
tree_command * tree_command_type
Definition: oct-parse.h:255
tree_classdef_methods_list * tree_classdef_methods_list_type
Definition: oct-parse.h:278
#define EXPR_GE
Definition: oct-parse.h:166
tree_classdef_property * tree_classdef_property_type
Definition: oct-parse.h:275
tree_decl_command * tree_decl_command_type
Definition: oct-parse.h:264
tree_colon_expression * tree_colon_expression_type
Definition: oct-parse.h:252
#define NUM
Definition: oct-parse.h:180
#define EMINUS
Definition: oct-parse.h:173
#define INPUT_FILE
Definition: oct-parse.h:221
#define MUL_EQ
Definition: oct-parse.h:143
#define HERMITIAN
Definition: oct-parse.h:174
#define EXPR_NE
Definition: oct-parse.h:165
#define FQ_IDENT
Definition: oct-parse.h:215
#define EDIV
Definition: oct-parse.h:170
tree * tree_type
Definition: oct-parse.h:241
tree_argument_list * tree_argument_list_type
Definition: oct-parse.h:253
#define NAME
Definition: oct-parse.h:183
#define IF
Definition: oct-parse.h:192
#define OR_EQ
Definition: oct-parse.h:152
#define DO
Definition: oct-parse.h:190
#define DIV_EQ
Definition: oct-parse.h:144
#define METHODS
Definition: oct-parse.h:210
#define EXPR_LT
Definition: oct-parse.h:162
#define LEFTDIV_EQ
Definition: oct-parse.h:145
tree_index_expression * tree_index_expression_type
Definition: oct-parse.h:251
tree_classdef_superclass_list * tree_classdef_superclass_list_type
Definition: oct-parse.h:273
#define WHILE
Definition: oct-parse.h:189
tree_classdef_methods_block * tree_classdef_methods_block_type
Definition: oct-parse.h:279
#define EXPR_AND
Definition: oct-parse.h:159
#define LEFTDIV
Definition: oct-parse.h:168
tree_matrix * tree_matrix_type
Definition: oct-parse.h:242
#define LSHIFT_EQ
Definition: oct-parse.h:153
int dummy_type
Definition: oct-parse.h:231
#define PLUS_PLUS
Definition: oct-parse.h:176
#define EXPR_LE
Definition: oct-parse.h:163
tree_statement_list * tree_statement_list_type
Definition: oct-parse.h:266
#define SWITCH
Definition: oct-parse.h:195
This class gets nodes and searchs inside of 'info files'.
Definition: parser.h:49
#define SET
Definition: oct-parse.h:217
#define UNTIL
Definition: oct-parse.h:191
#define EXPR_OR
Definition: oct-parse.h:160
#define METAQUERY
Definition: oct-parse.h:213
#define LSHIFT
Definition: oct-parse.h:155
#define ELEFTDIV
Definition: oct-parse.h:171
#define EXPR_NOT
Definition: oct-parse.h:161
tree_if_command * tree_if_command_type
Definition: oct-parse.h:256
#define TRY
Definition: oct-parse.h:203
tree_cell * tree_cell_type
Definition: oct-parse.h:243
#define EXPR_OR_OR
Definition: oct-parse.h:158
tree_classdef_properties_block * tree_classdef_properties_block_type
Definition: oct-parse.h:277
#define PROPERTIES
Definition: oct-parse.h:209
#define LEXICAL_ERROR
Definition: oct-parse.h:220
int octave_push_parse(octave_pstate *ps, int pushed_char, OCTAVE_STYPE const *pushed_val, octave_base_parser &parser)
Definition: oct-parse.cc:3058
void octave_pstate_delete(octave_pstate *ps)
Definition: oct-parse.cc:3030
#define GLOBAL
Definition: oct-parse.h:205
tree_funcall * tree_funcall_type
Definition: oct-parse.h:247
#define CATCH
Definition: oct-parse.h:204
tree_classdef_property_list * tree_classdef_property_list_type
Definition: oct-parse.h:276
#define MINUS_MINUS
Definition: oct-parse.h:177
#define FCN_HANDLE
Definition: oct-parse.h:207
tree_anon_fcn_handle * tree_anon_fcn_handle_type
Definition: oct-parse.h:249
tree_classdef_attribute_list * tree_classdef_attribute_list_type
Definition: oct-parse.h:271
char punct_type
Definition: oct-parse.h:240
#define EPLUS
Definition: oct-parse.h:172
tree_switch_command * tree_switch_command_type
Definition: oct-parse.h:259
#define EPOW_EQ
Definition: oct-parse.h:150
tree_constant * tree_constant_type
Definition: oct-parse.h:245
tree_classdef_body * tree_classdef_body_type
Definition: oct-parse.h:274
#define CLEANUP
Definition: oct-parse.h:202
#define FCN
Definition: oct-parse.h:218
tree_classdef_enum * tree_classdef_enum_type
Definition: oct-parse.h:283
#define EXPR_EQ
Definition: oct-parse.h:164
#define TRANSPOSE
Definition: oct-parse.h:175
#define BREAK
Definition: oct-parse.h:198
tree_parameter_list * tree_parameter_list_type
Definition: oct-parse.h:254
#define ENUMERATION
Definition: oct-parse.h:212
tree_function_def * tree_function_def_type
Definition: oct-parse.h:248
#define FUNC_RET
Definition: oct-parse.h:200
octave_tokentype
Definition: oct-parse.h:54
#define ELEFTDIV_EQ
Definition: oct-parse.h:149
#define EPOW
Definition: oct-parse.h:179
#define EDIV_EQ
Definition: oct-parse.h:148
#define ADD_EQ
Definition: oct-parse.h:141
tree_classdef_events_list * tree_classdef_events_list_type
Definition: oct-parse.h:281
#define END_OF_INPUT
Definition: oct-parse.h:219
tree_classdef_events_block * tree_classdef_events_block_type
Definition: oct-parse.h:282
#define EXPR_AND_AND
Definition: oct-parse.h:157
tree_classdef_attribute * tree_classdef_attribute_type
Definition: oct-parse.h:270
octave_pstate * octave_pstate_new(void)
Definition: oct-parse.cc:3019
int octave_pull_parse(octave_pstate *ps, octave_base_parser &parser)
Definition: oct-parse.cc:2990
#define OTHERWISE
Definition: oct-parse.h:197
#define CLASSDEF
Definition: oct-parse.h:208
#define EMUL_EQ
Definition: oct-parse.h:147
#define EXPR_GT
Definition: oct-parse.h:167
#define DQ_STRING
Definition: oct-parse.h:185
#define PERSISTENT
Definition: oct-parse.h:206
octave_comment_list * comment_type
Definition: oct-parse.h:237
tree_switch_case * tree_switch_case_type
Definition: oct-parse.h:260
tree_statement * tree_statement_type
Definition: oct-parse.h:265
#define SUPERCLASSREF
Definition: oct-parse.h:214
#define SQ_STRING
Definition: oct-parse.h:186
Definition: pt.h:35
tree_classdef_event * tree_classdef_event_type
Definition: oct-parse.h:280
#define FOR
Definition: oct-parse.h:187
#define POW_EQ
Definition: oct-parse.h:146
tree_fcn_handle * tree_fcn_handle_type
Definition: oct-parse.h:246
#define ELSEIF
Definition: oct-parse.h:193
#define END
Definition: oct-parse.h:184
tree_identifier * tree_identifier_type
Definition: oct-parse.h:250
#define RSHIFT
Definition: oct-parse.h:156
#define GET
Definition: oct-parse.h:216
#define PARFOR
Definition: oct-parse.h:188
tree_if_clause * tree_if_clause_type
Definition: oct-parse.h:257
#define CASE
Definition: oct-parse.h:196
#define ELSE
Definition: oct-parse.h:194
#define POW
Definition: oct-parse.h:178
token * tok_val
Definition: oct-parse.h:234
#define STRUCT_ELT
Definition: oct-parse.h:182
int octave_debug
#define SUB_EQ
Definition: oct-parse.h:142
#define IMAG_NUM
Definition: oct-parse.h:181
#define CONTINUE
Definition: oct-parse.h:199
octave_user_function * octave_user_function_type
Definition: oct-parse.h:267
#define UNARY
Definition: oct-parse.h:222
tree_decl_elt * tree_decl_elt_type
Definition: oct-parse.h:262
tree_classdef_enum_list * tree_classdef_enum_list_type
Definition: oct-parse.h:284
tree_classdef * tree_classdef_type
Definition: oct-parse.h:269
Definition: token.h:30
#define UNWIND
Definition: oct-parse.h:201