Mercurial > octave-antonio
diff libinterp/parse-tree/lex.ll @ 19858:77f65eabac20 stable
avoid crash when __FILE__ is used at top level (bug #44363)
* lex.ll (octave_base_lexer::is_keyword_token): Call correct
constructor for magic_file_kw.
* token.h, token.cc (token::token (int, const char *, int, int)):
New constructor.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Wed, 25 Feb 2015 11:33:39 -0500 |
parents | 446c46af4b42 |
children | 734a77207e2e |
line wrap: on
line diff
--- a/libinterp/parse-tree/lex.ll Fri Feb 06 08:31:09 2015 -0800 +++ b/libinterp/parse-tree/lex.ll Wed Feb 25 11:33:39 2015 -0500 @@ -2453,8 +2453,7 @@ if ((reading_fcn_file || reading_script_file || reading_classdef_file) && ! fcn_file_full_name.empty ()) - tok_val = new token (magic_file_kw, true, - fcn_file_full_name, l, c); + tok_val = new token (magic_file_kw, fcn_file_full_name, l, c); else tok_val = new token (magic_file_kw, "stdin", l, c); }