GNU Octave  8.1.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
oct-parse.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

union  OCTAVE_STYPE
 

Macros

#define OCTAVE_DEBUG   0
 
#define OCTAVE_STYPE_IS_DECLARED   1
 
#define OCTAVE_STYPE_IS_TRIVIAL   1
 
#define OCTAVE_TOKENTYPE
 
#define YYPUSH_MORE_DEFINED
 

Typedefs

typedef struct octave_pstate octave_pstate
 
typedef union OCTAVE_STYPE OCTAVE_STYPE
 
typedef enum octave_tokentype octave_token_kind_t
 

Enumerations

enum  { YYPUSH_MORE = 4 }
 
enum  octave_tokentype {
  OCTAVE_EMPTY = -2 , OCTAVE_EOF = 0 , OCTAVE_error = 256 , OCTAVE_UNDEF = 257 ,
  ADD_EQ = 258 , SUB_EQ = 259 , MUL_EQ = 260 , DIV_EQ = 261 ,
  LEFTDIV_EQ = 262 , POW_EQ = 263 , EMUL_EQ = 264 , EDIV_EQ = 265 ,
  ELEFTDIV_EQ = 266 , EPOW_EQ = 267 , AND_EQ = 268 , OR_EQ = 269 ,
  EXPR_AND_AND = 270 , EXPR_OR_OR = 271 , EXPR_AND = 272 , EXPR_OR = 273 ,
  EXPR_LT = 274 , EXPR_LE = 275 , EXPR_EQ = 276 , EXPR_NE = 277 ,
  EXPR_GE = 278 , EXPR_GT = 279 , LEFTDIV = 280 , EMUL = 281 ,
  EDIV = 282 , ELEFTDIV = 283 , HERMITIAN = 284 , TRANSPOSE = 285 ,
  PLUS_PLUS = 286 , MINUS_MINUS = 287 , POW = 288 , EPOW = 289 ,
  NUMBER = 290 , STRUCT_ELT = 291 , NAME = 292 , END = 293 ,
  DQ_STRING = 294 , SQ_STRING = 295 , FOR = 296 , PARFOR = 297 ,
  WHILE = 298 , DO = 299 , UNTIL = 300 , SPMD = 301 ,
  IF = 302 , ELSEIF = 303 , ELSE = 304 , SWITCH = 305 ,
  CASE = 306 , OTHERWISE = 307 , BREAK = 308 , CONTINUE = 309 ,
  FUNC_RET = 310 , UNWIND = 311 , CLEANUP = 312 , TRY = 313 ,
  CATCH = 314 , GLOBAL = 315 , PERSISTENT = 316 , FCN_HANDLE = 317 ,
  CLASSDEF = 318 , PROPERTIES = 319 , METHODS = 320 , EVENTS = 321 ,
  ENUMERATION = 322 , METAQUERY = 323 , SUPERCLASSREF = 324 , FQ_IDENT = 325 ,
  GET = 326 , SET = 327 , FCN = 328 , ARGUMENTS = 329 ,
  LEXICAL_ERROR = 330 , END_OF_INPUT = 331 , INPUT_FILE = 332 , UNARY = 333
}
 

Functions

int octave_parse (octave::base_parser &parser)
 
void octave_pstate_delete (octave_pstate *ps)
 
octave_pstateoctave_pstate_new (void)
 
int octave_pull_parse (octave_pstate *ps, octave::base_parser &parser)
 
int octave_push_parse (octave_pstate *ps, int pushed_char, OCTAVE_STYPE const *pushed_val, octave::base_parser &parser)
 

Macro Definition Documentation

◆ OCTAVE_DEBUG

#define OCTAVE_DEBUG   0

Definition at line 49 of file oct-parse.h.

◆ OCTAVE_STYPE_IS_DECLARED

#define OCTAVE_STYPE_IS_DECLARED   1

Definition at line 219 of file oct-parse.h.

◆ OCTAVE_STYPE_IS_TRIVIAL

#define OCTAVE_STYPE_IS_TRIVIAL   1

Definition at line 218 of file oct-parse.h.

◆ OCTAVE_TOKENTYPE

#define OCTAVE_TOKENTYPE

Definition at line 58 of file oct-parse.h.

◆ YYPUSH_MORE_DEFINED

#define YYPUSH_MORE_DEFINED

Definition at line 226 of file oct-parse.h.

Typedef Documentation

◆ octave_pstate

typedef struct octave_pstate octave_pstate

Definition at line 1 of file oct-parse.h.

◆ OCTAVE_STYPE

typedef union OCTAVE_STYPE OCTAVE_STYPE

Definition at line 1 of file oct-parse.h.

◆ octave_token_kind_t

Definition at line 1 of file oct-parse.h.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
YYPUSH_MORE 

Definition at line 227 of file oct-parse.h.

◆ octave_tokentype

Enumerator
OCTAVE_EMPTY 
OCTAVE_EOF 
OCTAVE_error 
OCTAVE_UNDEF 
ADD_EQ 
SUB_EQ 
MUL_EQ 
DIV_EQ 
LEFTDIV_EQ 
POW_EQ 
EMUL_EQ 
EDIV_EQ 
ELEFTDIV_EQ 
EPOW_EQ 
AND_EQ 
OR_EQ 
EXPR_AND_AND 
EXPR_OR_OR 
EXPR_AND 
EXPR_OR 
EXPR_LT 
EXPR_LE 
EXPR_EQ 
EXPR_NE 
EXPR_GE 
EXPR_GT 
LEFTDIV 
EMUL 
EDIV 
ELEFTDIV 
HERMITIAN 
TRANSPOSE 
PLUS_PLUS 
MINUS_MINUS 
POW 
EPOW 
NUMBER 
STRUCT_ELT 
NAME 
END 
DQ_STRING 
SQ_STRING 
FOR 
PARFOR 
WHILE 
DO 
UNTIL 
SPMD 
IF 
ELSEIF 
ELSE 
SWITCH 
CASE 
OTHERWISE 
BREAK 
CONTINUE 
FUNC_RET 
UNWIND 
CLEANUP 
TRY 
CATCH 
GLOBAL 
PERSISTENT 
FCN_HANDLE 
CLASSDEF 
PROPERTIES 
METHODS 
EVENTS 
ENUMERATION 
METAQUERY 
SUPERCLASSREF 
FQ_IDENT 
GET 
SET 
FCN 
ARGUMENTS 
LEXICAL_ERROR 
END_OF_INPUT 
INPUT_FILE 
UNARY 

Definition at line 59 of file oct-parse.h.

Function Documentation

◆ octave_parse()

int octave_parse ( octave::base_parser &  parser)

Definition at line 3050 of file oct-parse.cc.

References YY_, yyerror, yypstate, yypstate_delete, yypstate_new, and yypull_parse.

◆ octave_pstate_delete()

void octave_pstate_delete ( octave_pstate ps)

Definition at line 3120 of file oct-parse.cc.

References YYFREE, yyss, yyssa, and YYSTACK_FREE.

◆ octave_pstate_new()

octave_pstate* octave_pstate_new ( void  )

◆ octave_pull_parse()

int octave_pull_parse ( octave_pstate ps,
octave::base_parser &  parser 
)

Definition at line 3064 of file oct-parse.cc.

References scanner, YY_ASSERT, yylex, yylval, YYPUSH_MORE, yypush_parse, and YYSTYPE.

Referenced by parser::run().

◆ octave_push_parse()

int octave_push_parse ( octave_pstate ps,
int  pushed_char,
OCTAVE_STYPE const *  pushed_val,
octave::base_parser &  parser 
)

Definition at line 3141 of file oct-parse.cc.

References ADD_EQ, AND_EQ, base_parser::append_args_validation_list(), base_parser::append_argument_list(), base_parser::append_cell_row(), base_parser::append_classdef_attribute(), base_parser::append_classdef_enum(), base_parser::append_classdef_enum_block(), base_parser::append_classdef_event(), base_parser::append_classdef_events_block(), base_parser::append_classdef_method(), base_parser::append_classdef_methods_block(), base_parser::append_classdef_properties_block(), base_parser::append_classdef_property(), base_parser::append_classdef_superclass(), base_parser::append_decl_init_list(), base_parser::append_function_body(), base_parser::append_if_clause(), base_parser::append_matrix_row(), base_parser::append_parameter_list(), base_parser::append_statement_list(), base_parser::append_switch_case(), base_parser::bison_error(), DIV_EQ, EDIV, EDIV_EQ, ELEFTDIV, ELEFTDIV_EQ, EMUL, EMUL_EQ, base_parser::end_token_error(), base_parser::end_token_ok(), base_parser::endfunction_found(), EPOW, EPOW_EQ, EXPR_AND, EXPR_AND_AND, EXPR_EQ, EXPR_GE, EXPR_GT, EXPR_LE, EXPR_LT, EXPR_NE, EXPR_OR, EXPR_OR_OR, base_parser::finish_cell(), base_parser::finish_classdef_external_method(), base_parser::finish_classdef_file(), base_parser::finish_if_command(), base_parser::finish_input(), base_parser::finish_matrix(), base_parser::finish_switch_command(), FOR, base_lexer::get_comment(), GLOBAL, HERMITIAN, lexer::input_from_eval_string(), LEFTDIV, LEFTDIV_EQ, lexical_feedback::m_arguments_is_keyword, lexical_feedback::m_at_beginning_of_statement, lexical_feedback::m_classdef_element_names_are_keywords, lexical_feedback::m_defining_fcn, lexical_feedback::m_looking_at_anon_fcn_args, lexical_feedback::m_looking_at_decl_list, lexical_feedback::m_looking_at_function_handle, lexical_feedback::m_looking_at_indirect_ref, lexical_feedback::m_looking_at_matrix_or_assign_lhs, lexical_feedback::m_looking_at_parameter_list, lexical_feedback::m_looking_at_return_list, lexical_feedback::m_looking_for_object_index, lexical_feedback::m_maybe_classdef_get_set_method, lexical_feedback::m_nesting_level, lexical_feedback::m_parsed_function_name, lexical_feedback::m_parsing_anon_fcn_body, lexical_feedback::m_parsing_classdef, lexical_feedback::m_parsing_classdef_decl, lexical_feedback::m_parsing_classdef_get_method, lexical_feedback::m_parsing_classdef_set_method, lexical_feedback::m_parsing_classdef_superclass, lexical_feedback::m_reading_classdef_file, lexical_feedback::m_reading_fcn_file, lexical_feedback::m_reading_script_file, lexical_feedback::m_symtab_context, base_parser::make_anon_fcn_handle(), base_parser::make_arg_size_spec(), base_parser::make_arg_validation(), base_parser::make_arg_validation_fcns(), base_parser::make_args_attribute_list(), base_parser::make_args_validation_list(), base_parser::make_argument_list(), base_parser::make_arguments_block(), base_parser::make_assign_op(), base_parser::make_binary_op(), base_parser::make_black_hole(), base_parser::make_boolean_op(), base_parser::make_break_command(), base_parser::make_cell(), base_parser::make_classdef(), base_parser::make_classdef_attribute(), base_parser::make_classdef_attribute_list(), base_parser::make_classdef_body(), base_parser::make_classdef_enum(), base_parser::make_classdef_enum_block(), base_parser::make_classdef_enum_list(), base_parser::make_classdef_event(), base_parser::make_classdef_events_block(), base_parser::make_classdef_events_list(), base_parser::make_classdef_methods_block(), base_parser::make_classdef_methods_list(), base_parser::make_classdef_properties_block(), base_parser::make_classdef_property(), base_parser::make_classdef_property_list(), base_parser::make_classdef_superclass(), base_parser::make_classdef_superclass_list(), base_parser::make_colon_expression(), base_parser::make_constant(), base_parser::make_continue_command(), base_parser::make_decl_command(), base_parser::make_decl_elt(), base_parser::make_decl_init_list(), base_parser::make_default_switch_case(), base_parser::make_do_until_command(), base_parser::make_else_clause(), base_parser::make_elseif_clause(), base_parser::make_end(), base_parser::make_fcn_handle(), base_parser::make_fcn_name(), base_parser::make_for_command(), base_parser::make_function(), base_parser::make_identifier(), base_parser::make_index_expression(), base_parser::make_indirect_ref(), base_parser::make_matrix(), base_parser::make_metaclass_query(), base_parser::make_not_classdef_attribute(), base_parser::make_parameter_list(), base_parser::make_postfix_op(), base_parser::make_prefix_op(), base_parser::make_return_command(), base_parser::make_script(), base_parser::make_spmd_command(), base_parser::make_statement(), base_parser::make_statement_list(), base_parser::make_superclass_ref(), base_parser::make_switch_case(), base_parser::make_switch_case_list(), base_parser::make_try_command(), base_parser::make_unwind_command(), base_parser::make_while_command(), lexical_feedback::mark_as_variables(), base_parser::maybe_convert_to_braindead_shortcircuit(), MINUS_MINUS, MUL_EQ, OCTAVE_EMPTY, OCTAVE_EOF, OCTAVE_error, OCTAVE_UNDEF, OCTAVE_YYUSE, OR_EQ, PARFOR, base_parser::parsing_local_functions(), PERSISTENT, PLUS_PLUS, lexical_feedback::symbol_table_context::pop(), POW, POW_EQ, lexical_feedback::symbol_table_context::push(), base_parser::push_fcn_symtab(), lexical_feedback::bbp_nesting_level::remove(), base_parser::set_stmt_print_flag(), base_parser::start_classdef_external_method(), base_parser::start_if_command(), SUB_EQ, TRANSPOSE, base_parser::validate_array_list(), base_parser::validate_matrix_for_assignment(), base_parser::validate_param_list(), base_parser::validate_primary_fcn(), YY_, YY_ACCESSING_SYMBOL, YY_ASSERT, YY_CAST, YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN, YY_IGNORE_MAYBE_UNINITIALIZED_END, YY_IGNORE_USELESS_CAST_BEGIN, YY_IGNORE_USELESS_CAST_END, YY_INITIAL_VALUE, YY_REDUCE_PRINT, YY_STACK_PRINT, YY_SYMBOL_PRINT, YYABORT, YYACCEPT, yyalloc, yycheck, yydefact, yydefgoto, yydestruct(), YYDPRINTF, yyerror, YYERROR, yyerrstatus, YYFINAL, YYLAST, yylval, YYMAXDEPTH, yynerrs, YYNOMEM, YYNSTATES, YYNTOKENS, yypact, yypact_value_is_default, yypgoto, YYPOPSTACK, yypstate_clear, YYPTRDIFF_T, YYPUSH_MORE, yyr1, yyr2, YYSIZE_T, YYSIZEOF, yyss, yyssa, yyssp, YYSTACK_ALLOC, YYSTACK_BYTES, YYSTACK_FREE, YYSTACK_RELOCATE, yystacksize, yystate, YYSTYPE, YYSYMBOL_YYEMPTY, YYSYMBOL_YYEOF, YYSYMBOL_YYerror, yytable, yytable_value_is_error, YYTRANSLATE, yyvs, and yyvsp.

Referenced by push_parser::run().