diff options
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclEnsemble.c | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/generic/tclEnsemble.c b/generic/tclEnsemble.c index e37ad1a..1c91734 100644 --- a/generic/tclEnsemble.c +++ b/generic/tclEnsemble.c @@ -1832,7 +1832,6 @@ NsEnsembleImplementationCmdNR( Tcl_Obj *copyPtr; /* The actual list of words to dispatch to. * Will be freed by the dispatch engine. */ int prefixObjc, copyObjc; - Interp *iPtr = (Interp *) interp; /* * Get the prefix that we're rewriting to. To do this we need to @@ -1876,40 +1875,12 @@ NsEnsembleImplementationCmdNR( * count both as inserted and removed arguments. */ -#if 1 if (TclInitRewriteEnsemble(interp, 2 + ensemblePtr->numParameters, prefixObjc + ensemblePtr->numParameters, objv)) { TclNRAddCallback(interp, TclClearRootEnsemble, NULL, NULL, NULL, NULL); } -#else - - if (iPtr->ensembleRewrite.sourceObjs == NULL) { - iPtr->ensembleRewrite.sourceObjs = objv; - iPtr->ensembleRewrite.numRemovedObjs = - 2 + ensemblePtr->numParameters; - iPtr->ensembleRewrite.numInsertedObjs = - prefixObjc + ensemblePtr->numParameters; - TclNRAddCallback(interp, TclClearRootEnsemble, NULL, NULL, NULL, - NULL); - } else { - register int ni = 2 + ensemblePtr->numParameters - - iPtr->ensembleRewrite.numInsertedObjs; - /* Position in objv of new front of insertion - * relative to old one. */ - if (ni > 0) { -//fprintf(stdout, "COVER\n"); fflush(stdout); - iPtr->ensembleRewrite.numRemovedObjs += ni; - iPtr->ensembleRewrite.numInsertedObjs - = prefixObjc + ensemblePtr->numParameters; - } else { - iPtr->ensembleRewrite.numInsertedObjs += prefixObjc-2; - } - } - -#endif - /* * Hand off to the target command. */ @@ -2018,18 +1989,13 @@ TclInitRewriteEnsemble( int isRootEnsemble = (iPtr->ensembleRewrite.sourceObjs == NULL); if (isRootEnsemble) { -//fprintf(stdout, "SET-SOURCE: '%s'\n", Tcl_GetString(objv[0])); fflush(stdout); iPtr->ensembleRewrite.sourceObjs = objv; iPtr->ensembleRewrite.numRemovedObjs = numRemoved; iPtr->ensembleRewrite.numInsertedObjs = numInserted; } else { int numIns = iPtr->ensembleRewrite.numInsertedObjs; -//fprintf(stdout, "Pre-SOURCE: '%s'\n", -//Tcl_GetString(iPtr->ensembleRewrite.sourceObjs[0])); fflush(stdout); - if (numIns < numRemoved) { -//fprintf(stdout, "COVER2\n"); fflush(stdout); iPtr->ensembleRewrite.numRemovedObjs += numRemoved - numIns; iPtr->ensembleRewrite.numInsertedObjs = numInserted; } else { |