GNU Octave  4.2.1
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.4. */
2 
3 /* Bison interface for Yacc-like parsers in C
4 
5  Copyright (C) 1984, 1989-1990, 2000-2015 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_LIBINTERP_PARSE_TREE_OCT_PARSE_H_INCLUDED
34 # define YY_OCTAVE_LIBINTERP_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  EXPR_AND_AND = 270,
69  EXPR_OR_OR = 271,
70  EXPR_AND = 272,
71  EXPR_OR = 273,
72  EXPR_NOT = 274,
73  EXPR_LT = 275,
74  EXPR_LE = 276,
75  EXPR_EQ = 277,
76  EXPR_NE = 278,
77  EXPR_GE = 279,
78  EXPR_GT = 280,
79  LEFTDIV = 281,
80  EMUL = 282,
81  EDIV = 283,
82  ELEFTDIV = 284,
83  EPLUS = 285,
84  EMINUS = 286,
85  HERMITIAN = 287,
86  TRANSPOSE = 288,
87  PLUS_PLUS = 289,
88  MINUS_MINUS = 290,
89  POW = 291,
90  EPOW = 292,
91  NUM = 293,
92  IMAG_NUM = 294,
93  STRUCT_ELT = 295,
94  NAME = 296,
95  END = 297,
96  DQ_STRING = 298,
97  SQ_STRING = 299,
98  FOR = 300,
99  PARFOR = 301,
100  WHILE = 302,
101  DO = 303,
102  UNTIL = 304,
103  IF = 305,
104  ELSEIF = 306,
105  ELSE = 307,
106  SWITCH = 308,
107  CASE = 309,
108  OTHERWISE = 310,
109  BREAK = 311,
110  CONTINUE = 312,
111  FUNC_RET = 313,
112  UNWIND = 314,
113  CLEANUP = 315,
114  TRY = 316,
115  CATCH = 317,
116  GLOBAL = 318,
117  PERSISTENT = 319,
118  FCN_HANDLE = 320,
119  CLASSDEF = 321,
120  PROPERTIES = 322,
121  METHODS = 323,
122  EVENTS = 324,
123  ENUMERATION = 325,
124  METAQUERY = 326,
126  FQ_IDENT = 328,
127  GET = 329,
128  SET = 330,
129  FCN = 331,
132  INPUT_FILE = 334,
133  UNARY = 335
134  };
135 #endif
136 /* Tokens. */
137 #define ADD_EQ 258
138 #define SUB_EQ 259
139 #define MUL_EQ 260
140 #define DIV_EQ 261
141 #define LEFTDIV_EQ 262
142 #define POW_EQ 263
143 #define EMUL_EQ 264
144 #define EDIV_EQ 265
145 #define ELEFTDIV_EQ 266
146 #define EPOW_EQ 267
147 #define AND_EQ 268
148 #define OR_EQ 269
149 #define EXPR_AND_AND 270
150 #define EXPR_OR_OR 271
151 #define EXPR_AND 272
152 #define EXPR_OR 273
153 #define EXPR_NOT 274
154 #define EXPR_LT 275
155 #define EXPR_LE 276
156 #define EXPR_EQ 277
157 #define EXPR_NE 278
158 #define EXPR_GE 279
159 #define EXPR_GT 280
160 #define LEFTDIV 281
161 #define EMUL 282
162 #define EDIV 283
163 #define ELEFTDIV 284
164 #define EPLUS 285
165 #define EMINUS 286
166 #define HERMITIAN 287
167 #define TRANSPOSE 288
168 #define PLUS_PLUS 289
169 #define MINUS_MINUS 290
170 #define POW 291
171 #define EPOW 292
172 #define NUM 293
173 #define IMAG_NUM 294
174 #define STRUCT_ELT 295
175 #define NAME 296
176 #define END 297
177 #define DQ_STRING 298
178 #define SQ_STRING 299
179 #define FOR 300
180 #define PARFOR 301
181 #define WHILE 302
182 #define DO 303
183 #define UNTIL 304
184 #define IF 305
185 #define ELSEIF 306
186 #define ELSE 307
187 #define SWITCH 308
188 #define CASE 309
189 #define OTHERWISE 310
190 #define BREAK 311
191 #define CONTINUE 312
192 #define FUNC_RET 313
193 #define UNWIND 314
194 #define CLEANUP 315
195 #define TRY 316
196 #define CATCH 317
197 #define GLOBAL 318
198 #define PERSISTENT 319
199 #define FCN_HANDLE 320
200 #define CLASSDEF 321
201 #define PROPERTIES 322
202 #define METHODS 323
203 #define EVENTS 324
204 #define ENUMERATION 325
205 #define METAQUERY 326
206 #define SUPERCLASSREF 327
207 #define FQ_IDENT 328
208 #define GET 329
209 #define SET 330
210 #define FCN 331
211 #define LEXICAL_ERROR 332
212 #define END_OF_INPUT 333
213 #define INPUT_FILE 334
214 #define UNARY 335
215 
216 /* Value type. */
217 #if ! defined OCTAVE_STYPE && ! defined OCTAVE_STYPE_IS_DECLARED
218 
220 {
221 #line 141 "libinterp/parse-tree/oct-parse.yy" /* yacc.c:1909 */
222 
224 
225  // The type of the basic tokens returned by the lexer.
227 
228  // Comment strings that we need to deal with mid-rule.
230 
231  // Types for the nonterminals we generate.
260 
278 
279 #line 280 "libinterp/parse-tree/oct-parse.h" /* yacc.c:1909 */
280 };
281 
283 # define OCTAVE_STYPE_IS_TRIVIAL 1
284 # define OCTAVE_STYPE_IS_DECLARED 1
285 #endif
286 
287 
288 
289 #ifndef YYPUSH_MORE_DEFINED
290 # define YYPUSH_MORE_DEFINED
291 enum { YYPUSH_MORE = 4 };
292 #endif
293 
295 
297 int octave_push_parse (octave_pstate *ps, int pushed_char, OCTAVE_STYPE const *pushed_val, octave::base_parser& parser);
301 
302 #endif /* !YY_OCTAVE_LIBINTERP_PARSE_TREE_OCT_PARSE_H_INCLUDED */
#define AND_EQ
Definition: oct-parse.h:147
tree_decl_init_list * tree_decl_init_list_type
Definition: oct-parse.h:255
tree_classdef_enum_block * tree_classdef_enum_block_type
Definition: oct-parse.h:277
int octave_parse(octave::base_parser &parser)
Definition: oct-parse.cc:2949
tree_expression * tree_expression_type
Definition: oct-parse.h:236
tree_switch_case_list * tree_switch_case_list_type
Definition: oct-parse.h:253
#define EMUL
Definition: oct-parse.h:161
#define EVENTS
Definition: oct-parse.h:203
tree_classdef_superclass * tree_classdef_superclass_type
Definition: oct-parse.h:264
tree_if_command_list * tree_if_command_list_type
Definition: oct-parse.h:250
tree_command * tree_command_type
Definition: oct-parse.h:247
tree_classdef_methods_list * tree_classdef_methods_list_type
Definition: oct-parse.h:270
#define EXPR_GE
Definition: oct-parse.h:158
tree_classdef_property * tree_classdef_property_type
Definition: oct-parse.h:267
tree_decl_command * tree_decl_command_type
Definition: oct-parse.h:256
int octave_pull_parse(octave_pstate *ps, octave::base_parser &parser)
Definition: oct-parse.cc:2955
tree_colon_expression * tree_colon_expression_type
Definition: oct-parse.h:244
#define NUM
Definition: oct-parse.h:172
#define EMINUS
Definition: oct-parse.h:165
#define INPUT_FILE
Definition: oct-parse.h:213
#define MUL_EQ
Definition: oct-parse.h:139
#define HERMITIAN
Definition: oct-parse.h:166
#define EXPR_NE
Definition: oct-parse.h:157
#define FQ_IDENT
Definition: oct-parse.h:207
#define EDIV
Definition: oct-parse.h:162
tree * tree_type
Definition: oct-parse.h:233
tree_argument_list * tree_argument_list_type
Definition: oct-parse.h:245
#define NAME
Definition: oct-parse.h:175
#define IF
Definition: oct-parse.h:184
#define OR_EQ
Definition: oct-parse.h:148
#define DO
Definition: oct-parse.h:182
#define DIV_EQ
Definition: oct-parse.h:140
#define METHODS
Definition: oct-parse.h:202
#define EXPR_LT
Definition: oct-parse.h:154
#define LEFTDIV_EQ
Definition: oct-parse.h:141
tree_index_expression * tree_index_expression_type
Definition: oct-parse.h:243
tree_classdef_superclass_list * tree_classdef_superclass_list_type
Definition: oct-parse.h:265
#define WHILE
Definition: oct-parse.h:181
tree_classdef_methods_block * tree_classdef_methods_block_type
Definition: oct-parse.h:271
#define EXPR_AND
Definition: oct-parse.h:151
#define LEFTDIV
Definition: oct-parse.h:160
tree_matrix * tree_matrix_type
Definition: oct-parse.h:234
int dummy_type
Definition: oct-parse.h:223
#define PLUS_PLUS
Definition: oct-parse.h:168
#define EXPR_LE
Definition: oct-parse.h:155
tree_statement_list * tree_statement_list_type
Definition: oct-parse.h:258
#define SWITCH
Definition: oct-parse.h:187
This class gets nodes and searchs inside of 'info files'.
Definition: parser.h:52
#define SET
Definition: oct-parse.h:209
#define UNTIL
Definition: oct-parse.h:183
#define EXPR_OR
Definition: oct-parse.h:152
#define METAQUERY
Definition: oct-parse.h:205
#define ELEFTDIV
Definition: oct-parse.h:163
#define EXPR_NOT
Definition: oct-parse.h:153
tree_if_command * tree_if_command_type
Definition: oct-parse.h:248
#define TRY
Definition: oct-parse.h:195
tree_cell * tree_cell_type
Definition: oct-parse.h:235
#define EXPR_OR_OR
Definition: oct-parse.h:150
tree_classdef_properties_block * tree_classdef_properties_block_type
Definition: oct-parse.h:269
#define PROPERTIES
Definition: oct-parse.h:201
#define LEXICAL_ERROR
Definition: oct-parse.h:211
void octave_pstate_delete(octave_pstate *ps)
Definition: oct-parse.cc:2995
#define GLOBAL
Definition: oct-parse.h:197
tree_funcall * tree_funcall_type
Definition: oct-parse.h:239
#define CATCH
Definition: oct-parse.h:196
tree_classdef_property_list * tree_classdef_property_list_type
Definition: oct-parse.h:268
#define MINUS_MINUS
Definition: oct-parse.h:169
#define FCN_HANDLE
Definition: oct-parse.h:199
tree_anon_fcn_handle * tree_anon_fcn_handle_type
Definition: oct-parse.h:241
tree_classdef_attribute_list * tree_classdef_attribute_list_type
Definition: oct-parse.h:263
char punct_type
Definition: oct-parse.h:232
#define EPLUS
Definition: oct-parse.h:164
tree_switch_command * tree_switch_command_type
Definition: oct-parse.h:251
#define EPOW_EQ
Definition: oct-parse.h:146
tree_constant * tree_constant_type
Definition: oct-parse.h:237
tree_classdef_body * tree_classdef_body_type
Definition: oct-parse.h:266
#define CLEANUP
Definition: oct-parse.h:194
#define FCN
Definition: oct-parse.h:210
tree_classdef_enum * tree_classdef_enum_type
Definition: oct-parse.h:275
#define EXPR_EQ
Definition: oct-parse.h:156
#define TRANSPOSE
Definition: oct-parse.h:167
#define BREAK
Definition: oct-parse.h:190
tree_parameter_list * tree_parameter_list_type
Definition: oct-parse.h:246
#define ENUMERATION
Definition: oct-parse.h:204
tree_function_def * tree_function_def_type
Definition: oct-parse.h:240
#define FUNC_RET
Definition: oct-parse.h:192
octave_tokentype
Definition: oct-parse.h:54
#define ELEFTDIV_EQ
Definition: oct-parse.h:145
#define EPOW
Definition: oct-parse.h:171
#define EDIV_EQ
Definition: oct-parse.h:144
#define ADD_EQ
Definition: oct-parse.h:137
tree_classdef_events_list * tree_classdef_events_list_type
Definition: oct-parse.h:273
#define END_OF_INPUT
Definition: oct-parse.h:212
tree_classdef_events_block * tree_classdef_events_block_type
Definition: oct-parse.h:274
#define EXPR_AND_AND
Definition: oct-parse.h:149
tree_classdef_attribute * tree_classdef_attribute_type
Definition: oct-parse.h:262
octave_pstate * octave_pstate_new(void)
Definition: oct-parse.cc:2984
#define OTHERWISE
Definition: oct-parse.h:189
#define CLASSDEF
Definition: oct-parse.h:200
#define EMUL_EQ
Definition: oct-parse.h:143
#define EXPR_GT
Definition: oct-parse.h:159
#define DQ_STRING
Definition: oct-parse.h:177
#define PERSISTENT
Definition: oct-parse.h:198
octave_comment_list * comment_type
Definition: oct-parse.h:229
tree_switch_case * tree_switch_case_type
Definition: oct-parse.h:252
tree_statement * tree_statement_type
Definition: oct-parse.h:257
#define SUPERCLASSREF
Definition: oct-parse.h:206
#define SQ_STRING
Definition: oct-parse.h:178
Definition: pt.h:39
int octave_push_parse(octave_pstate *ps, int pushed_char, OCTAVE_STYPE const *pushed_val, octave::base_parser &parser)
Definition: oct-parse.cc:3023
tree_classdef_event * tree_classdef_event_type
Definition: oct-parse.h:272
#define FOR
Definition: oct-parse.h:179
#define POW_EQ
Definition: oct-parse.h:142
tree_fcn_handle * tree_fcn_handle_type
Definition: oct-parse.h:238
#define ELSEIF
Definition: oct-parse.h:185
#define END
Definition: oct-parse.h:176
tree_identifier * tree_identifier_type
Definition: oct-parse.h:242
#define GET
Definition: oct-parse.h:208
#define PARFOR
Definition: oct-parse.h:180
tree_if_clause * tree_if_clause_type
Definition: oct-parse.h:249
#define CASE
Definition: oct-parse.h:188
#define ELSE
Definition: oct-parse.h:186
#define POW
Definition: oct-parse.h:170
token * tok_val
Definition: oct-parse.h:226
#define STRUCT_ELT
Definition: oct-parse.h:174
int octave_debug
#define SUB_EQ
Definition: oct-parse.h:138
#define IMAG_NUM
Definition: oct-parse.h:173
#define CONTINUE
Definition: oct-parse.h:191
octave_user_function * octave_user_function_type
Definition: oct-parse.h:259
#define UNARY
Definition: oct-parse.h:214
tree_decl_elt * tree_decl_elt_type
Definition: oct-parse.h:254
tree_classdef_enum_list * tree_classdef_enum_list_type
Definition: oct-parse.h:276
tree_classdef * tree_classdef_type
Definition: oct-parse.h:261
Definition: token.h:32
#define UNWIND
Definition: oct-parse.h:193