summaryrefslogtreecommitdiffstats
path: root/generic/tclCompile.c
diff options
context:
space:
mode:
authorMiguel Sofer <miguel.sofer@gmail.com>2010-04-29 23:39:32 (GMT)
committerMiguel Sofer <miguel.sofer@gmail.com>2010-04-29 23:39:32 (GMT)
commit86ab7e21814dcb7876a4002e7bb8f582cc5fb606 (patch)
treee43c3dcb657d68ea7a183a4b50ebdd353d55a73a /generic/tclCompile.c
parent4afa4db89195f756601d2fd640f605e4eb1896cd (diff)
downloadtcl-86ab7e21814dcb7876a4002e7bb8f582cc5fb606.zip
tcl-86ab7e21814dcb7876a4002e7bb8f582cc5fb606.tar.gz
tcl-86ab7e21814dcb7876a4002e7bb8f582cc5fb606.tar.bz2
* generic/tclCompExpr.c: Slight change in the literal sharing
* generic/tclCompile.c: mechanism to avoid shimmering of * generic/tclCompile.h: command names. * generic/tclLiteral.c:
Diffstat (limited to 'generic/tclCompile.c')
-rw-r--r--generic/tclCompile.c17
1 files changed, 4 insertions, 13 deletions
diff --git a/generic/tclCompile.c b/generic/tclCompile.c
index d788d43..c9598bd 100644
--- a/generic/tclCompile.c
+++ b/generic/tclCompile.c
@@ -11,7 +11,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclCompile.c,v 1.184 2010/03/05 14:34:04 dkf Exp $
+ * RCS: @(#) $Id: tclCompile.c,v 1.185 2010/04/29 23:39:32 msofer Exp $
*/
#include "tclInt.h"
@@ -1731,26 +1731,17 @@ TclCompileScript(
/*
* No compile procedure so push the word. If the command
* was found, push a CmdName object to reduce runtime
- * lookups. Avoid sharing this literal among different
- * namespaces to reduce shimmering.
+ * lookups. Mark this as a command name literal to reduce
+ * shimmering.
*/
- objIndex = TclRegisterNewNSLiteral(envPtr,
+ objIndex = TclRegisterNewCmdLiteral(envPtr,
tokenPtr[1].start, tokenPtr[1].size);
if (cmdPtr != NULL) {
TclSetCmdNameObj(interp,
envPtr->literalArrayPtr[objIndex].objPtr,
cmdPtr);
}
- if ((wordIdx == 0) && (parsePtr->numWords == 1)) {
- /*
- * Single word script: unshare the command name to
- * avoid shimmering between bytecode and cmdName
- * representations. [Bug 458361]
- */
-
- TclHideLiteral(interp, envPtr, objIndex);
- }
} else {
/*
* Simple argument word of a command. We reach this if and