Mercurial > hg > octave-lyh
diff libinterp/parse-tree/oct-parse.yy @ 16109:229eb14653fd
new entry point for parser
* oct-parse.yy (octave_parse_input): New function.
(parse_fcn_file, eval_string): Use it instead of yyparse.
* toplev.cc (main_loop): Use it instead of octave_parse.
* input.cc (get_debug_input): Use it instead of octave_parse.
* oct-parse.h (octave_parse_input): Provide decl.
(octave_parse): Delete decl.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Tue, 26 Feb 2013 00:45:43 -0500 |
parents | 6434f70f0ee0 |
children | 7302f8a4df83 |
line wrap: on
line diff
--- a/libinterp/parse-tree/oct-parse.yy +++ b/libinterp/parse-tree/oct-parse.yy @@ -3587,7 +3587,7 @@ global_command = 0; - int status = yyparse (); + int status = octave_parse_input (); // Use an unwind-protect cleanup function so that the // global_command list will be deleted in the event of an @@ -4355,7 +4355,7 @@ symbol_table::scope_id scope = symbol_table::top_scope (); frame.add_fcn (symbol_table::unmark_forced_variables, scope); - parse_status = yyparse (); + parse_status = octave_parse_input (); tree_statement_list *command_list = global_command; @@ -4464,6 +4464,12 @@ } } +int +octave_parse_input (void) +{ + octave_parse (); +} + DEFUN (eval, args, nargout, "-*- texinfo -*-\n\ @deftypefn {Built-in Function} {} eval (@var{try})\n\