From c75e578cb3af78543a31ac6ad4676324c9ce6b6c Mon Sep 17 00:00:00 2001 From: dgp Date: Tue, 23 Jul 2013 18:01:36 +0000 Subject: Stop checking stack depth in [catch] compiler. Stack depth is checked in compiles of *all* Tcl commands/scripts/bodies in debug builds already. --- generic/tclCompCmds.c | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/generic/tclCompCmds.c b/generic/tclCompCmds.c index 7fe0728..bde6f96 100644 --- a/generic/tclCompCmds.c +++ b/generic/tclCompCmds.c @@ -544,7 +544,6 @@ TclCompileCatchCmd( JumpFixup jumpFixup; Tcl_Token *cmdTokenPtr, *resultNameTokenPtr, *optsNameTokenPtr; int resultIndex, optsIndex, range; - int initStackDepth = envPtr->currStackDepth; DefineLineInformation; /* TIP #280 */ /* @@ -742,15 +741,6 @@ TclCompileCatchCmd( TclEmitOpcode( INST_POP, envPtr); } - /* - * Result of all this, on either branch, should have been to leave one - * operand -- the return code -- on the stack. - */ - - if (envPtr->currStackDepth != initStackDepth + 1) { - Tcl_Panic("in TclCompileCatchCmd, currStackDepth = %d should be %d", - envPtr->currStackDepth, initStackDepth+1); - } return TCL_OK; } -- cgit v0.12