summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2013-06-05 20:23:41 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2013-06-05 20:23:41 (GMT)
commit936acef29cdd2e9fce4a278453e2b2150c5b9c96 (patch)
tree4ec527b605bb4c5aa939565a8dd5d3108f59492c /generic
parent64edc0ede7a6c7770bc5f152e97aa48674ed6682 (diff)
parentad80ea28de240aaa62b0140e919648ac3081d54f (diff)
downloadtcl-936acef29cdd2e9fce4a278453e2b2150c5b9c96.zip
tcl-936acef29cdd2e9fce4a278453e2b2150c5b9c96.tar.gz
tcl-936acef29cdd2e9fce4a278453e2b2150c5b9c96.tar.bz2
merge fixes
Diffstat (limited to 'generic')
-rw-r--r--generic/tclCompCmds.c12
-rw-r--r--generic/tclExecute.c14
2 files changed, 9 insertions, 17 deletions
diff --git a/generic/tclCompCmds.c b/generic/tclCompCmds.c
index 8cb5fcd..253f9a8 100644
--- a/generic/tclCompCmds.c
+++ b/generic/tclCompCmds.c
@@ -499,12 +499,6 @@ TclCompileBreakCmd(
TclCleanupStackForBreakContinue(envPtr, auxPtr);
TclAddLoopBreakFixup(envPtr, auxPtr);
-
- /*
- * Instructions that raise exceptions don't really have to follow the
- * usual stack management rules, but the cleanup code does.
- */
-
TclAdjustStackDepth(1, envPtr);
} else {
/*
@@ -834,12 +828,6 @@ TclCompileContinueCmd(
TclCleanupStackForBreakContinue(envPtr, auxPtr);
TclAddLoopContinueFixup(envPtr, auxPtr);
-
- /*
- * Instructions that raise exceptions don't really have to follow the
- * usual stack management rules, but the cleanup code does.
- */
-
TclAdjustStackDepth(1, envPtr);
} else {
/*
diff --git a/generic/tclExecute.c b/generic/tclExecute.c
index 98ce51e..443fb85 100644
--- a/generic/tclExecute.c
+++ b/generic/tclExecute.c
@@ -257,7 +257,7 @@ VarHashCreateVar(
/* Verify the stack depth, only when no expansion is in progress */
-#if TCL_COMPILE_DEBUG
+#ifdef TCL_COMPILE_DEBUG
#define CHECK_STACK() \
do { \
ValidatePcAndStackTop(codePtr, pc, CURR_DEPTH, \
@@ -2630,7 +2630,7 @@ TEBCresume(
Tcl_Panic("max size for a Tcl value (%d bytes) exceeded",
INT_MAX);
}
-#if !TCL_COMPILE_DEBUG
+#ifndef TCL_COMPILE_DEBUG
if (bytes != tclEmptyStringRep && !Tcl_IsShared(objResultPtr)) {
TclFreeIntRep(objResultPtr);
objResultPtr->bytes = ckrealloc(bytes, length+appendLen+1);
@@ -2666,7 +2666,7 @@ TEBCresume(
Tcl_Panic("max size for a Tcl value (%d bytes) exceeded",
INT_MAX);
}
-#if !TCL_COMPILE_DEBUG
+#ifndef TCL_COMPILE_DEBUG
if (!Tcl_IsShared(objResultPtr)) {
bytes = (char *) Tcl_SetByteArrayLength(objResultPtr,
length + appendLen);
@@ -2728,6 +2728,10 @@ TEBCresume(
CLANG_ASSERT(auxObjList);
objc = CURR_DEPTH - auxObjList->internalRep.ptrAndLongRep.value;
POP_TAUX_OBJ();
+#ifdef TCL_COMPILE_DEBUG
+ /* Ugly abuse! */
+ starting = 1;
+#endif
NEXT_INST_V(1, objc, 0);
case INST_EXPAND_STKTOP: {
@@ -6836,7 +6840,7 @@ TEBCresume(
*/
processExceptionReturn:
-#if TCL_COMPILE_DEBUG
+#ifdef TCL_COMPILE_DEBUG
switch (*pc) {
case INST_INVOKE_STK1:
opnd = TclGetUInt1AtPtr(pc+1);
@@ -6893,7 +6897,7 @@ TEBCresume(
rangePtr->codeOffset, rangePtr->continueOffset));
NEXT_INST_F(0, 0, 0);
}
-#if TCL_COMPILE_DEBUG
+#ifdef TCL_COMPILE_DEBUG
if (traceInstructions) {
objPtr = Tcl_GetObjResult(interp);
if ((result != TCL_ERROR) && (result != TCL_RETURN)) {