diff options
| author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2024-05-27 11:04:53 (GMT) |
|---|---|---|
| committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2024-05-27 11:04:53 (GMT) |
| commit | 1019fc7dc38c97beab50b4151eaccf9de1174683 (patch) | |
| tree | 744bc526ea038b9ed87bfa3f99bf2df661c0c104 /generic/tclExecute.c | |
| parent | 85d98f92fd33696034aab9f92955dc12ea3972ee (diff) | |
| download | tcl-1019fc7dc38c97beab50b4151eaccf9de1174683.zip tcl-1019fc7dc38c97beab50b4151eaccf9de1174683.tar.gz tcl-1019fc7dc38c97beab50b4151eaccf9de1174683.tar.bz2 | |
Eliminate TclPrintByteCodeObj()'s 'interp' argument, which is not used.
Diffstat (limited to 'generic/tclExecute.c')
| -rw-r--r-- | generic/tclExecute.c | 29 |
1 files changed, 12 insertions, 17 deletions
diff --git a/generic/tclExecute.c b/generic/tclExecute.c index 380a0a3..cdecc08 100644 --- a/generic/tclExecute.c +++ b/generic/tclExecute.c @@ -1520,12 +1520,7 @@ CompileExprObj( codePtr->localCachePtr = iPtr->varFramePtr->localCachePtr; codePtr->localCachePtr->refCount++; } -#ifdef TCL_COMPILE_DEBUG - if (tclTraceCompile == 2) { - TclPrintByteCodeObj(interp, objPtr); - fflush(stdout); - } -#endif /* TCL_COMPILE_DEBUG */ + TclDebugPrintByteCodeObj(objPtr); } return codePtr; } @@ -2082,8 +2077,8 @@ TEBCresume( Tcl_Obj **tosPtr; /* Cached pointer to top of evaluation * stack. */ const unsigned char *pc = (const unsigned char *)data[1]; - /* The current program counter. */ - unsigned char inst; /* The currently running instruction */ + /* The current program counter. */ + unsigned char inst; /* The currently running instruction */ /* * Transfer variables - needed only between opcodes, but not while @@ -2092,7 +2087,7 @@ TEBCresume( int cleanup = PTR2INT(data[2]); Tcl_Obj *objResultPtr; - int checkInterp = 0; /* Indicates when a check of interp readyness + int checkInterp = 0; /* Indicates when a check of interp readyness * is necessary. Set by CACHE_STACK_INFO() */ /* @@ -2146,7 +2141,7 @@ TEBCresume( goto cleanup0; } else { - /* resume from invocation */ + /* resume from invocation */ CACHE_STACK_INFO(); NRE_ASSERT(iPtr->cmdFramePtr == bcFramePtr); @@ -2446,7 +2441,7 @@ TEBCresume( } else { fprintf(stdout, "%" TCL_SIZE_MODIFIER "d: (%" TCL_T_MODIFIER "d) yielding value \"%.30s\"\n", iPtr->numLevels, (pc - codePtr->codeStart), - Tcl_GetString(OBJ_AT_TOS)); + TclGetString(OBJ_AT_TOS)); } fflush(stdout); } @@ -6687,7 +6682,7 @@ TEBCresume( numVars = varListPtr->numVars; listVarPtr = LOCAL(listTmpIndex); - /* Do not use TclListObjCopy here - shimmers arithseries to list */ + /* Do not use TclListObjCopy here - shimmers arithseries to list */ listPtr = Tcl_DuplicateObj(listVarPtr->value.objPtr); TclListObjGetElements(interp, listPtr, &listLen, &elements); @@ -9440,21 +9435,21 @@ TclGetSourceFromFrame( Tcl_Obj *const objv[]) { if (cfPtr == NULL) { - return Tcl_NewListObj(objc, objv); + return Tcl_NewListObj(objc, objv); } if (cfPtr->cmdObj == NULL) { - if (cfPtr->cmd == NULL) { + if (cfPtr->cmd == NULL) { ByteCode *codePtr = (ByteCode *) cfPtr->data.tebc.codePtr; - cfPtr->cmd = GetSrcInfoForPc((unsigned char *) + cfPtr->cmd = GetSrcInfoForPc((unsigned char *) cfPtr->data.tebc.pc, codePtr, &cfPtr->len, NULL, NULL); - } + } if (cfPtr->cmd) { cfPtr->cmdObj = Tcl_NewStringObj(cfPtr->cmd, cfPtr->len); } else { cfPtr->cmdObj = Tcl_NewListObj(objc, objv); } - Tcl_IncrRefCount(cfPtr->cmdObj); + Tcl_IncrRefCount(cfPtr->cmdObj); } return cfPtr->cmdObj; } |
