diff options
Diffstat (limited to 'generic/tclBasic.c')
| -rw-r--r-- | generic/tclBasic.c | 32 |
1 files changed, 17 insertions, 15 deletions
diff --git a/generic/tclBasic.c b/generic/tclBasic.c index 714bb6f..f46c2bf 100644 --- a/generic/tclBasic.c +++ b/generic/tclBasic.c @@ -184,6 +184,7 @@ static Tcl_NRPostProc DTraceCmdReturn; #else # define DTraceCmdReturn NULL #endif /* USE_DTRACE */ +static Tcl_ObjCmdProc InvokeStringCommand; static Tcl_ObjCmdProc ExprAbsFunc; static Tcl_ObjCmdProc ExprBinaryFunc; static Tcl_ObjCmdProc ExprBoolFunc; @@ -212,6 +213,7 @@ static void MathFuncWrongNumArgs(Tcl_Interp *interp, int expected, static Tcl_NRPostProc NRCoroutineCallerCallback; static Tcl_NRPostProc NRCoroutineExitCallback; static Tcl_NRPostProc NRCommand; +static Tcl_CmdProc InvokeObjectCommand; static void ProcessUnexpectedResult(Tcl_Interp *interp, int returnCode); @@ -1068,10 +1070,10 @@ Tcl_CreateInterp(void) * Tcl_CreateCommand, because it's faster (there's no need to check for a * preexisting command by the same name). If a command has a Tcl_CmdProc * but no Tcl_ObjCmdProc, set the Tcl_ObjCmdProc to - * TclInvokeStringCommand. This is an object-based wrapper function that + * InvokeStringCommand. This is an object-based wrapper function that * extracts strings, calls the string function, and creates an object for * the result. Similarly, if a command has a Tcl_ObjCmdProc but no - * Tcl_CmdProc, set the Tcl_CmdProc to TclInvokeObjectCommand. + * Tcl_CmdProc, set the Tcl_CmdProc to InvokeObjectCommand. */ for (cmdInfoPtr = builtInCmds; cmdInfoPtr->name != NULL; cmdInfoPtr++) { @@ -1090,7 +1092,7 @@ Tcl_CreateInterp(void) cmdPtr->refCount = 1; cmdPtr->cmdEpoch = 0; cmdPtr->compileProc = cmdInfoPtr->compileProc; - cmdPtr->proc = TclInvokeObjectCommand; + cmdPtr->proc = InvokeObjectCommand; cmdPtr->clientData = cmdPtr; cmdPtr->objProc = cmdInfoPtr->objProc; cmdPtr->objClientData = NULL; @@ -2479,7 +2481,7 @@ Tcl_ExposeCommand( * In the future, when cmdName is seen as the name of a command by * Tcl_Eval, proc will be called. To support the bytecode interpreter, * the command is created with a wrapper Tcl_ObjCmdProc - * (TclInvokeStringCommand) that eventually calls proc. When the command + * (InvokeStringCommand) that eventually calls proc. When the command * is deleted from the table, deleteProc will be called. See the manual * entry for details on the calling sequence. * @@ -2621,7 +2623,7 @@ Tcl_CreateCommand( cmdPtr->refCount = 1; cmdPtr->cmdEpoch = 0; cmdPtr->compileProc = NULL; - cmdPtr->objProc = TclInvokeStringCommand; + cmdPtr->objProc = InvokeStringCommand; cmdPtr->objClientData = cmdPtr; cmdPtr->proc = proc; cmdPtr->clientData = clientData; @@ -2910,7 +2912,7 @@ TclCreateObjCommandInNs( cmdPtr->compileProc = NULL; cmdPtr->objProc = proc; cmdPtr->objClientData = clientData; - cmdPtr->proc = TclInvokeObjectCommand; + cmdPtr->proc = InvokeObjectCommand; cmdPtr->clientData = cmdPtr; cmdPtr->deleteProc = deleteProc; cmdPtr->deleteData = clientData; @@ -2951,7 +2953,7 @@ TclCreateObjCommandInNs( /* *---------------------------------------------------------------------- * - * TclInvokeStringCommand -- + * InvokeStringCommand -- * * "Wrapper" Tcl_ObjCmdProc used to call an existing string-based * Tcl_CmdProc if no object-based function exists for a command. A @@ -2964,13 +2966,13 @@ TclCreateObjCommandInNs( * * Side effects: * Besides those side effects of the called Tcl_CmdProc, - * TclInvokeStringCommand allocates and frees storage. + * InvokeStringCommand allocates and frees storage. * *---------------------------------------------------------------------- */ int -TclInvokeStringCommand( +InvokeStringCommand( void *clientData, /* Points to command's Command structure. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ @@ -2999,7 +3001,7 @@ TclInvokeStringCommand( /* *---------------------------------------------------------------------- * - * TclInvokeObjectCommand -- + * InvokeObjectCommand -- * * "Wrapper" Tcl_CmdProc used to call an existing object-based * Tcl_ObjCmdProc if no string-based function exists for a command. A @@ -3012,13 +3014,13 @@ TclInvokeStringCommand( * * Side effects: * Besides those side effects of the called Tcl_ObjCmdProc, - * TclInvokeObjectCommand allocates and frees storage. + * InvokeObjectCommand allocates and frees storage. * *---------------------------------------------------------------------- */ int -TclInvokeObjectCommand( +InvokeObjectCommand( void *clientData, /* Points to command's Command structure. */ Tcl_Interp *interp, /* Current interpreter. */ int argc, /* Number of arguments. */ @@ -3375,7 +3377,7 @@ Tcl_SetCommandInfoFromToken( cmdPtr->proc = infoPtr->proc; cmdPtr->clientData = infoPtr->clientData; if (infoPtr->objProc == NULL) { - cmdPtr->objProc = TclInvokeStringCommand; + cmdPtr->objProc = InvokeStringCommand; cmdPtr->objClientData = cmdPtr; cmdPtr->nreProc = NULL; } else { @@ -3487,7 +3489,7 @@ Tcl_GetCommandInfoFromToken( cmdPtr = (Command *) cmd; infoPtr->isNativeObjectProc = - (cmdPtr->objProc != TclInvokeStringCommand); + (cmdPtr->objProc != InvokeStringCommand); infoPtr->objProc = cmdPtr->objProc; infoPtr->objClientData = cmdPtr->objClientData; infoPtr->proc = cmdPtr->proc; @@ -8588,7 +8590,7 @@ Tcl_NRCallObjProc2( * Side effects: * If no command named "cmdName" already exists for interp, one is * created. Otherwise, if a command does exist, then if the object-based - * Tcl_ObjCmdProc is TclInvokeStringCommand, we assume Tcl_CreateCommand + * Tcl_ObjCmdProc is InvokeStringCommand, we assume Tcl_CreateCommand * was called previously for the same command and just set its * Tcl_ObjCmdProc to the argument "proc"; otherwise, we delete the old * command. |
