summaryrefslogtreecommitdiffstats
path: root/generic/tclCompile.c
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2010-01-30 16:33:25 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2010-01-30 16:33:25 (GMT)
commit1543f6fbfc86e643435f8db696b104c0327f92e7 (patch)
tree8f37ec0b8c0aca813318fc602941b066f8fd80f2 /generic/tclCompile.c
parent8f9f9d5b20e83bc7ee369eb5a7ba6d66076bf0e6 (diff)
downloadtcl-1543f6fbfc86e643435f8db696b104c0327f92e7.zip
tcl-1543f6fbfc86e643435f8db696b104c0327f92e7.tar.gz
tcl-1543f6fbfc86e643435f8db696b104c0327f92e7.tar.bz2
Make the [unset] command be bytecode compiled.
Diffstat (limited to 'generic/tclCompile.c')
-rw-r--r--generic/tclCompile.c19
1 files changed, 17 insertions, 2 deletions
diff --git a/generic/tclCompile.c b/generic/tclCompile.c
index 57e3a9d..726aefb 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.179 2009/11/18 21:59:50 nijtmans Exp $
+ * RCS: @(#) $Id: tclCompile.c,v 1.180 2010/01/30 16:33:25 dkf Exp $
*/
#include "tclInt.h"
@@ -399,6 +399,7 @@ InstructionDesc const tclInstructionTable[] = {
* stknext */
{"existStk", 1, 0, 0, {OPERAND_NONE}},
/* Test if general variable exists; unparsed variable name is stktop*/
+
{"nop", 1, 0, 0, {OPERAND_NONE}},
/* Do nothing */
{"returnCodeBranch", 1, -1, 0, {OPERAND_NONE}},
@@ -406,9 +407,23 @@ InstructionDesc const tclInstructionTable[] = {
* ERROR: +1; RETURN: +3; BREAK: +5; CONTINUE: +7;
* Other non-OK: +9
*/
+
+ {"unsetScalar", 6, 0, 2, {OPERAND_UINT1, OPERAND_LVT4}},
+ /* Make scalar variable at index op2 in call frame cease to exist;
+ * op1 is 1 for errors on problems, 0 otherwise */
+ {"unsetArray", 6, -1, 2, {OPERAND_UINT1, OPERAND_LVT4}},
+ /* Make array element cease to exist; array at slot op2, element is
+ * stktop; op1 is 1 for errors on problems, 0 otherwise */
+ {"unsetArrayStk", 2, -2, 1, {OPERAND_UINT1}},
+ /* Make array element cease to exist; element is stktop, array name is
+ * stknext; op1 is 1 for errors on problems, 0 otherwise */
+ {"unsetStk", 2, -1, 1, {OPERAND_UINT1}},
+ /* Make general variable cease to exist; unparsed variable name is
+ * stktop; op1 is 1 for errors on problems, 0 otherwise */
+
{NULL, 0, 0, 0, {OPERAND_NONE}}
};
-
+
/*
* Prototypes for procedures defined later in this file:
*/