diff options
author | dgp <dgp@users.sourceforge.net> | 2013-08-06 04:15:16 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2013-08-06 04:15:16 (GMT) |
commit | b3b497f42cfe1a533488c23fb8dfd706e7bb59a6 (patch) | |
tree | f88d7e06cf4d84b785efd54e3c57abbc059a78f0 /generic/tclCmdIL.c | |
parent | aa01137e0e936cc97ab7ba3c80ab39b7772938f0 (diff) | |
download | tcl-b3b497f42cfe1a533488c23fb8dfd706e7bb59a6.zip tcl-b3b497f42cfe1a533488c23fb8dfd706e7bb59a6.tar.gz tcl-b3b497f42cfe1a533488c23fb8dfd706e7bb59a6.tar.bz2 |
The value TCL_LOCATION_EVAL_LIST in the type field of a CmdFrame appears to
exist only for the sake of taking great pains to make sure that pure list
values remain pure list values.
The value of pure list values is no longer what it once was. For a long long
time now, any canonical list values have been equally good. This branch
is Work In Progress eliminating the complication of the additional type value.
Currently some minor botches are breaking execution tracing tests.
Diffstat (limited to 'generic/tclCmdIL.c')
-rw-r--r-- | generic/tclCmdIL.c | 25 |
1 files changed, 5 insertions, 20 deletions
diff --git a/generic/tclCmdIL.c b/generic/tclCmdIL.c index 0e33392..4046903 100644 --- a/generic/tclCmdIL.c +++ b/generic/tclCmdIL.c @@ -1302,30 +1302,15 @@ TclInfoFrame( */ ADD_PAIR("type", Tcl_NewStringObj(typeString[framePtr->type], -1)); - ADD_PAIR("line", Tcl_NewIntObj(framePtr->line[0])); + if (framePtr->line) { + ADD_PAIR("line", Tcl_NewIntObj(framePtr->line[0])); + } else { + ADD_PAIR("line", Tcl_NewIntObj(1)); + } ADD_PAIR("cmd", Tcl_NewStringObj(framePtr->cmd.str.cmd, framePtr->cmd.str.len)); break; - case TCL_LOCATION_EVAL_LIST: - /* - * List optimized evaluation. Type, line, cmd, the latter through - * listPtr, possibly a frame. - */ - - ADD_PAIR("type", Tcl_NewStringObj(typeString[framePtr->type], -1)); - ADD_PAIR("line", Tcl_NewIntObj(1)); - - /* - * We put a duplicate of the command list obj into the result to - * ensure that the 'pure List'-property of the command itself is not - * destroyed. Otherwise the query here would disable the list - * optimization path in Tcl_EvalObjEx. - */ - - ADD_PAIR("cmd", Tcl_DuplicateObj(framePtr->cmd.listPtr)); - break; - case TCL_LOCATION_PREBC: /* * Precompiled. Result contains the type as signal, nothing else. |