diff options
Diffstat (limited to 'generic/tclBasic.c')
-rw-r--r-- | generic/tclBasic.c | 92 |
1 files changed, 46 insertions, 46 deletions
diff --git a/generic/tclBasic.c b/generic/tclBasic.c index 53a5614..0120466 100644 --- a/generic/tclBasic.c +++ b/generic/tclBasic.c @@ -682,7 +682,7 @@ buildInfoObjCmd( if (p) { memcpy(buf, (char *)clientData, p - (char *)clientData); buf[p - (char *)clientData] = '\0'; - Tcl_AppendResult(interp, buf, NULL); + Tcl_AppendResult(interp, buf, (void *)NULL); } return TCL_OK; } else if (len == 10 && !strcmp(arg, "patchlevel")) { @@ -691,7 +691,7 @@ buildInfoObjCmd( if (p) { memcpy(buf, (char *)clientData, p - (char *)clientData); buf[p - (char *)clientData] = '\0'; - Tcl_AppendResult(interp, buf, NULL); + Tcl_AppendResult(interp, buf, (void *)NULL); } return TCL_OK; } else if (len == 6 && !strcmp(arg, "commit")) { @@ -701,9 +701,9 @@ buildInfoObjCmd( char buf[80]; memcpy(buf, p+1, q - p - 1); buf[q - p - 1] = '\0'; - Tcl_AppendResult(interp, buf, NULL); + Tcl_AppendResult(interp, buf, (void *)NULL); } else { - Tcl_AppendResult(interp, p+1, NULL); + Tcl_AppendResult(interp, p+1, (void *)NULL); } } return TCL_OK; @@ -717,29 +717,29 @@ buildInfoObjCmd( char buf[16]; memcpy(buf, p+1, q - p - 1); buf[q - p - 1] = '\0'; - Tcl_AppendResult(interp, buf, NULL); + Tcl_AppendResult(interp, buf, (void *)NULL); } else { - Tcl_AppendResult(interp, p+1, NULL); + Tcl_AppendResult(interp, p+1, (void *)NULL); } return TCL_OK; } p = strchr(p+1, '.'); } - Tcl_AppendResult(interp, "0", NULL); + Tcl_AppendResult(interp, "0", (void *)NULL); return TCL_OK; } const char *p = strchr((char *)clientData, '.'); while (p) { if (!strncmp(p+1, arg, len) && ((p[len+1] == '.') || (p[len+1] == '\0'))) { - Tcl_AppendResult(interp, "1", NULL); + Tcl_AppendResult(interp, "1", (void *)NULL); return TCL_OK; } p = strchr(p+1, '.'); } - Tcl_AppendResult(interp, "0", NULL); + Tcl_AppendResult(interp, "0", (void *)NULL); return TCL_OK; } - Tcl_AppendResult(interp, (char *)clientData, NULL); + Tcl_AppendResult(interp, (char *)clientData, (void *)NULL); return TCL_OK; } @@ -1522,7 +1522,7 @@ BadEnsembleSubcommand( Tcl_SetObjResult(interp, Tcl_ObjPrintf( "not allowed to invoke subcommand %s of %s", infoPtr->commandName, infoPtr->ensembleNsName)); - Tcl_SetErrorCode(interp, "TCL", "SAFE", "SUBCOMMAND", NULL); + Tcl_SetErrorCode(interp, "TCL", "SAFE", "SUBCOMMAND", (void *)NULL); return TCL_ERROR; } @@ -2228,7 +2228,7 @@ Tcl_HideCommand( Tcl_SetObjResult(interp, Tcl_NewStringObj( "cannot use namespace qualifiers in hidden command" " token (rename)", TCL_INDEX_NONE)); - Tcl_SetErrorCode(interp, "TCL", "VALUE", "HIDDENTOKEN", NULL); + Tcl_SetErrorCode(interp, "TCL", "VALUE", "HIDDENTOKEN", (void *)NULL); return TCL_ERROR; } @@ -2253,7 +2253,7 @@ Tcl_HideCommand( Tcl_SetObjResult(interp, Tcl_NewStringObj( "can only hide global namespace commands (use rename then hide)", TCL_INDEX_NONE)); - Tcl_SetErrorCode(interp, "TCL", "HIDE", "NON_GLOBAL", NULL); + Tcl_SetErrorCode(interp, "TCL", "HIDE", "NON_GLOBAL", (void *)NULL); return TCL_ERROR; } @@ -2279,7 +2279,7 @@ Tcl_HideCommand( Tcl_SetObjResult(interp, Tcl_ObjPrintf( "hidden command named \"%s\" already exists", hiddenCmdToken)); - Tcl_SetErrorCode(interp, "TCL", "HIDE", "ALREADY_HIDDEN", NULL); + Tcl_SetErrorCode(interp, "TCL", "HIDE", "ALREADY_HIDDEN", (void *)NULL); return TCL_ERROR; } @@ -2383,7 +2383,7 @@ Tcl_ExposeCommand( Tcl_SetObjResult(interp, Tcl_NewStringObj( "cannot expose to a namespace (use expose to toplevel, then rename)", TCL_INDEX_NONE)); - Tcl_SetErrorCode(interp, "TCL", "EXPOSE", "NON_GLOBAL", NULL); + Tcl_SetErrorCode(interp, "TCL", "EXPOSE", "NON_GLOBAL", (void *)NULL); return TCL_ERROR; } @@ -2400,7 +2400,7 @@ Tcl_ExposeCommand( Tcl_SetObjResult(interp, Tcl_ObjPrintf( "unknown hidden command \"%s\"", hiddenCmdToken)); Tcl_SetErrorCode(interp, "TCL", "LOOKUP", "HIDDENTOKEN", - hiddenCmdToken, NULL); + hiddenCmdToken, (void *)NULL); return TCL_ERROR; } cmdPtr = (Command *)Tcl_GetHashValue(hPtr); @@ -2438,7 +2438,7 @@ Tcl_ExposeCommand( if (!isNew) { Tcl_SetObjResult(interp, Tcl_ObjPrintf( "exposed command \"%s\" already exists", cmdName)); - Tcl_SetErrorCode(interp, "TCL", "EXPOSE", "COMMAND_EXISTS", NULL); + Tcl_SetErrorCode(interp, "TCL", "EXPOSE", "COMMAND_EXISTS", (void *)NULL); return TCL_ERROR; } @@ -3118,7 +3118,7 @@ TclRenameCommand( "can't %s \"%s\": command doesn't exist", ((newName == NULL)||(*newName == '\0'))? "delete":"rename", oldName)); - Tcl_SetErrorCode(interp, "TCL", "LOOKUP", "COMMAND", oldName, NULL); + Tcl_SetErrorCode(interp, "TCL", "LOOKUP", "COMMAND", oldName, (void *)NULL); return TCL_ERROR; } @@ -3149,7 +3149,7 @@ TclRenameCommand( if ((newNsPtr == NULL) || (newTail == NULL)) { Tcl_SetObjResult(interp, Tcl_ObjPrintf( "can't rename to \"%s\": bad command name", newName)); - Tcl_SetErrorCode(interp, "TCL", "VALUE", "COMMAND", NULL); + Tcl_SetErrorCode(interp, "TCL", "VALUE", "COMMAND", (void *)NULL); result = TCL_ERROR; goto done; } @@ -3157,7 +3157,7 @@ TclRenameCommand( Tcl_SetObjResult(interp, Tcl_ObjPrintf( "can't rename to \"%s\": command already exists", newName)); Tcl_SetErrorCode(interp, "TCL", "OPERATION", "RENAME", - "TARGET_EXISTS", NULL); + "TARGET_EXISTS", (void *)NULL); result = TCL_ERROR; goto done; } @@ -4274,7 +4274,7 @@ Tcl_GetMathFuncInfo( if (cmdPtr == NULL) { Tcl_SetObjResult(interp, Tcl_ObjPrintf( "unknown math function \"%s\"", name)); - Tcl_SetErrorCode(interp, "TCL", "LOOKUP", "MATHFUNC", name, NULL); + Tcl_SetErrorCode(interp, "TCL", "LOOKUP", "MATHFUNC", name, (void *)NULL); *numArgsPtr = -1; *argTypesPtr = NULL; *procPtr = NULL; @@ -4393,7 +4393,7 @@ TclInterpReady( Tcl_SetObjResult(interp, Tcl_NewStringObj( "attempt to call eval in deleted interpreter", TCL_INDEX_NONE)); Tcl_SetErrorCode(interp, "TCL", "IDELETE", - "attempt to call eval in deleted interpreter", NULL); + "attempt to call eval in deleted interpreter", (void *)NULL); return TCL_ERROR; } @@ -4421,7 +4421,7 @@ TclInterpReady( Tcl_SetObjResult(interp, Tcl_NewStringObj( "too many nested evaluations (infinite loop?)", TCL_INDEX_NONE)); - Tcl_SetErrorCode(interp, "TCL", "LIMIT", "STACK", NULL); + Tcl_SetErrorCode(interp, "TCL", "LIMIT", "STACK", (void *)NULL); return TCL_ERROR; } @@ -4555,7 +4555,7 @@ Tcl_Canceled( } Tcl_SetObjResult(interp, Tcl_NewStringObj(message, TCL_INDEX_NONE)); - Tcl_SetErrorCode(interp, "TCL", "CANCEL", id, message, NULL); + Tcl_SetErrorCode(interp, "TCL", "CANCEL", id, message, (void *)NULL); } /* @@ -4845,7 +4845,7 @@ EvalObjvCore( Tcl_SetObjResult(interp, Tcl_ObjPrintf( "attempt to invoke a deleted command")); - Tcl_SetErrorCode(interp, "TCL", "EVAL", "DELETEDCOMMAND", NULL); + Tcl_SetErrorCode(interp, "TCL", "EVAL", "DELETEDCOMMAND", (void *)NULL); return TCL_ERROR; } } @@ -5244,7 +5244,7 @@ TEOV_NotFound( Tcl_SetObjResult(interp, Tcl_ObjPrintf( "invalid command name \"%s\"", TclGetString(objv[0]))); Tcl_SetErrorCode(interp, "TCL", "LOOKUP", "COMMAND", - TclGetString(objv[0]), NULL); + TclGetString(objv[0]), (void *)NULL); /* * Release any resources we locked and allocated during the handler @@ -6853,7 +6853,7 @@ ProcessUnexpectedResult( "command returned bad code: %d", returnCode)); } snprintf(buf, sizeof(buf), "%d", returnCode); - Tcl_SetErrorCode(interp, "TCL", "UNEXPECTED_RESULT_CODE", buf, NULL); + Tcl_SetErrorCode(interp, "TCL", "UNEXPECTED_RESULT_CODE", buf, (void *)NULL); } /* @@ -7201,7 +7201,7 @@ TclNRInvoke( Tcl_SetObjResult(interp, Tcl_ObjPrintf( "invalid hidden command name \"%s\"", cmdName)); Tcl_SetErrorCode(interp, "TCL", "LOOKUP", "HIDDENTOKEN", cmdName, - NULL); + (void *)NULL); return TCL_ERROR; } cmdPtr = (Command *)Tcl_GetHashValue(hPtr); @@ -7408,7 +7408,7 @@ Tcl_AddObjErrorInfo( iPtr->errorInfo = iPtr->objResultPtr; Tcl_IncrRefCount(iPtr->errorInfo); if (!iPtr->errorCode) { - Tcl_SetErrorCode(interp, "NONE", NULL); + Tcl_SetErrorCode(interp, "NONE", (void *)NULL); } } @@ -7845,7 +7845,7 @@ ExprIsqrtFunc( Tcl_SetObjResult(interp, Tcl_NewStringObj( "square root of negative argument", TCL_INDEX_NONE)); Tcl_SetErrorCode(interp, "ARITH", "DOMAIN", - "domain error: argument not in valid range", NULL); + "domain error: argument not in valid range", (void *)NULL); return TCL_ERROR; } @@ -8954,7 +8954,7 @@ MathFuncWrongNumArgs( Tcl_SetObjResult(interp, Tcl_ObjPrintf( "%s arguments for math function \"%s\"", (found < expected ? "not enough" : "too many"), name)); - Tcl_SetErrorCode(interp, "TCL", "WRONGARGS", NULL); + Tcl_SetErrorCode(interp, "TCL", "WRONGARGS", (void *)NULL); } #ifdef USE_DTRACE @@ -9375,7 +9375,7 @@ TclNRTailcallObjCmd( if (!(iPtr->varFramePtr->isProcCallFrame & 1)) { Tcl_SetObjResult(interp, Tcl_NewStringObj( "tailcall can only be called from a proc, lambda or method", TCL_INDEX_NONE)); - Tcl_SetErrorCode(interp, "TCL", "TAILCALL", "ILLEGAL", NULL); + Tcl_SetErrorCode(interp, "TCL", "TAILCALL", "ILLEGAL", (void *)NULL); return TCL_ERROR; } @@ -9537,7 +9537,7 @@ TclNRYieldObjCmd( if (!corPtr) { Tcl_SetObjResult(interp, Tcl_NewStringObj( "yield can only be called in a coroutine", TCL_INDEX_NONE)); - Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "ILLEGAL_YIELD", NULL); + Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "ILLEGAL_YIELD", (void *)NULL); return TCL_ERROR; } @@ -9570,7 +9570,7 @@ TclNRYieldToObjCmd( if (!corPtr) { Tcl_SetObjResult(interp, Tcl_NewStringObj( "yieldto can only be called in a coroutine", TCL_INDEX_NONE)); - Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "ILLEGAL_YIELD", NULL); + Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "ILLEGAL_YIELD", (void *)NULL); return TCL_ERROR; } @@ -9578,7 +9578,7 @@ TclNRYieldToObjCmd( Tcl_SetObjResult(interp, Tcl_NewStringObj( "yieldto called in deleted namespace", TCL_INDEX_NONE)); Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "YIELDTO_IN_DELETED", - NULL); + (void *)NULL); return TCL_ERROR; } @@ -9814,7 +9814,7 @@ TclNRCoroutineActivateCallback( Tcl_SetObjResult(interp, Tcl_NewStringObj( "cannot yield: C stack busy", TCL_INDEX_NONE)); Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "CANT_YIELD", - NULL); + (void *)NULL); return TCL_ERROR; } @@ -9903,7 +9903,7 @@ CoroTypeObjCmd( Tcl_SetObjResult(interp, Tcl_NewStringObj( "can only get coroutine type of a coroutine", TCL_INDEX_NONE)); Tcl_SetErrorCode(interp, "TCL", "LOOKUP", "COROUTINE", - TclGetString(objv[1]), NULL); + TclGetString(objv[1]), (void *)NULL); return TCL_ERROR; } @@ -9933,7 +9933,7 @@ CoroTypeObjCmd( default: Tcl_SetObjResult(interp, Tcl_NewStringObj( "unknown coroutine type", TCL_INDEX_NONE)); - Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "BAD_TYPE", NULL); + Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "BAD_TYPE", (void *)NULL); return TCL_ERROR; } } @@ -9963,7 +9963,7 @@ GetCoroutineFromObj( if ((!cmdPtr) || (cmdPtr->nreProc != TclNRInterpCoroutine)) { Tcl_SetObjResult(interp, Tcl_NewStringObj(errMsg, TCL_INDEX_NONE)); Tcl_SetErrorCode(interp, "TCL", "LOOKUP", "COROUTINE", - TclGetString(objPtr), NULL); + TclGetString(objPtr), (void *)NULL); return NULL; } return (CoroutineData *)cmdPtr->objClientData; @@ -9996,7 +9996,7 @@ TclNRCoroInjectObjCmd( if (!COR_IS_SUSPENDED(corPtr)) { Tcl_SetObjResult(interp, Tcl_NewStringObj( "can only inject a command into a suspended coroutine", TCL_INDEX_NONE)); - Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "ACTIVE", NULL); + Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "ACTIVE", (void *)NULL); return TCL_ERROR; } @@ -10042,7 +10042,7 @@ TclNRCoroProbeObjCmd( Tcl_SetObjResult(interp, Tcl_NewStringObj( "can only inject a probe command into a suspended coroutine", TCL_INDEX_NONE)); - Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "ACTIVE", NULL); + Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "ACTIVE", (void *)NULL); return TCL_ERROR; } @@ -10233,7 +10233,7 @@ NRInjectObjCmd( if (!COR_IS_SUSPENDED(corPtr)) { Tcl_SetObjResult(interp, Tcl_NewStringObj( "can only inject a command into a suspended coroutine", TCL_INDEX_NONE)); - Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "ACTIVE", NULL); + Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "ACTIVE", (void *)NULL); return TCL_ERROR; } @@ -10263,7 +10263,7 @@ TclNRInterpCoroutine( Tcl_SetObjResult(interp, Tcl_ObjPrintf( "coroutine \"%s\" is already running", TclGetString(objv[0]))); - Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "BUSY", NULL); + Tcl_SetErrorCode(interp, "TCL", "COROUTINE", "BUSY", (void *)NULL); return TCL_ERROR; } @@ -10287,7 +10287,7 @@ TclNRInterpCoroutine( Tcl_SetObjResult(interp, Tcl_NewStringObj("wrong coro nargs; how did we get here? " "not implemented!", TCL_INDEX_NONE)); - Tcl_SetErrorCode(interp, "TCL", "WRONGARGS", NULL); + Tcl_SetErrorCode(interp, "TCL", "WRONGARGS", (void *)NULL); return TCL_ERROR; } /* fallthrough */ @@ -10341,14 +10341,14 @@ TclNRCoroutineObjCmd( Tcl_SetObjResult(interp, Tcl_ObjPrintf( "can't create procedure \"%s\": unknown namespace", procName)); - Tcl_SetErrorCode(interp, "TCL", "LOOKUP", "NAMESPACE", NULL); + Tcl_SetErrorCode(interp, "TCL", "LOOKUP", "NAMESPACE", (void *)NULL); return TCL_ERROR; } if (simpleName == NULL) { Tcl_SetObjResult(interp, Tcl_ObjPrintf( "can't create procedure \"%s\": bad procedure name", procName)); - Tcl_SetErrorCode(interp, "TCL", "VALUE", "COMMAND", procName, NULL); + Tcl_SetErrorCode(interp, "TCL", "VALUE", "COMMAND", procName, (void *)NULL); return TCL_ERROR; } |