# HG changeset patch # User John W. Eaton # Date 1207246189 14400 # Node ID 97e535ec65dbbe421531a70facbaf83238d7bb75 # Parent a9d25da4ed9c2890b4f5ea801b68803571358309 make_constant: stash original text for strings diff --git a/src/ChangeLog b/src/ChangeLog --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,5 +1,7 @@ 2008-04-03 John W. Eaton + * parse.y (make_constant): Also stash original text for strings. + * ov-fcn-handle.cc (octave_fcn_handle::subsref): Don't call next_subsref here. diff --git a/src/parse.y b/src/parse.y --- a/src/parse.y +++ b/src/parse.y @@ -1697,8 +1697,12 @@ case DQ_STRING: case SQ_STRING: { - octave_value tmp (tok_val->text (), op == DQ_STRING ? '"' : '\''); + char delim = op == DQ_STRING ? '"' : '\''; + octave_value tmp (tok_val->text (), delim); retval = new tree_constant (tmp, l, c); + // FIXME -- maybe this should also be handled by + // tok_val->text_rep () for character strings? + retval->stash_original_text (delim + tok_val->text () + delim); } break;