summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--generic/tcl.decls2
-rw-r--r--generic/tclDecls.h24
-rw-r--r--generic/tclInt.decls2
-rw-r--r--generic/tclIntDecls.h6
-rw-r--r--generic/tclProc.c75
-rw-r--r--generic/tclStubInit.c11
6 files changed, 61 insertions, 59 deletions
diff --git a/generic/tcl.decls b/generic/tcl.decls
index 6b67e77..0c18c78 100644
--- a/generic/tcl.decls
+++ b/generic/tcl.decls
@@ -2325,7 +2325,7 @@ declare 630 {
# ----- BASELINE -- FOR -- 8.6.0 ----- #
-declare 675 {
+declare 681 {
void TclUnusedStubEntry(void)
}
diff --git a/generic/tclDecls.h b/generic/tclDecls.h
index f2eed87..8731144 100644
--- a/generic/tclDecls.h
+++ b/generic/tclDecls.h
@@ -1859,7 +1859,13 @@ EXTERN void Tcl_ZlibStreamSetCompressionDictionary(
/* Slot 672 is reserved */
/* Slot 673 is reserved */
/* Slot 674 is reserved */
-/* 675 */
+/* Slot 675 is reserved */
+/* Slot 676 is reserved */
+/* Slot 677 is reserved */
+/* Slot 678 is reserved */
+/* Slot 679 is reserved */
+/* Slot 680 is reserved */
+/* 681 */
EXTERN void TclUnusedStubEntry(void);
typedef struct {
@@ -2571,7 +2577,13 @@ typedef struct TclStubs {
void (*reserved672)(void);
void (*reserved673)(void);
void (*reserved674)(void);
- void (*tclUnusedStubEntry) (void); /* 675 */
+ void (*reserved675)(void);
+ void (*reserved676)(void);
+ void (*reserved677)(void);
+ void (*reserved678)(void);
+ void (*reserved679)(void);
+ void (*reserved680)(void);
+ void (*tclUnusedStubEntry) (void); /* 681 */
} TclStubs;
extern const TclStubs *tclStubsPtr;
@@ -3908,8 +3920,14 @@ extern const TclStubs *tclStubsPtr;
/* Slot 672 is reserved */
/* Slot 673 is reserved */
/* Slot 674 is reserved */
+/* Slot 675 is reserved */
+/* Slot 676 is reserved */
+/* Slot 677 is reserved */
+/* Slot 678 is reserved */
+/* Slot 679 is reserved */
+/* Slot 680 is reserved */
#define TclUnusedStubEntry \
- (tclStubsPtr->tclUnusedStubEntry) /* 675 */
+ (tclStubsPtr->tclUnusedStubEntry) /* 681 */
#endif /* defined(USE_TCL_STUBS) */
diff --git a/generic/tclInt.decls b/generic/tclInt.decls
index 0e909a2..c2d8253 100644
--- a/generic/tclInt.decls
+++ b/generic/tclInt.decls
@@ -175,7 +175,7 @@ declare 38 {
const char **simpleNamePtr)
}
declare 39 {
- TclObjCmdProcType TclGetObjInterpProc(void)
+ Tcl_ObjCmdProc *TclGetObjInterpProc(void)
}
declare 40 {
int TclGetOpenMode(Tcl_Interp *interp, const char *str, int *seekFlagPtr)
diff --git a/generic/tclIntDecls.h b/generic/tclIntDecls.h
index 0282259..c524608 100644
--- a/generic/tclIntDecls.h
+++ b/generic/tclIntDecls.h
@@ -143,7 +143,7 @@ EXTERN int TclGetNamespaceForQualName(Tcl_Interp *interp,
Namespace **actualCxtPtrPtr,
const char **simpleNamePtr);
/* 39 */
-EXTERN TclObjCmdProcType TclGetObjInterpProc(void);
+EXTERN Tcl_ObjCmdProc * TclGetObjInterpProc(void);
/* 40 */
EXTERN int TclGetOpenMode(Tcl_Interp *interp, const char *str,
int *seekFlagPtr);
@@ -692,7 +692,7 @@ typedef struct TclIntStubs {
void (*reserved36)(void);
int (*tclGetLoadedPackages) (Tcl_Interp *interp, const char *targetName); /* 37 */
int (*tclGetNamespaceForQualName) (Tcl_Interp *interp, const char *qualName, Namespace *cxtNsPtr, int flags, Namespace **nsPtrPtr, Namespace **altNsPtrPtr, Namespace **actualCxtPtrPtr, const char **simpleNamePtr); /* 38 */
- TclObjCmdProcType (*tclGetObjInterpProc) (void); /* 39 */
+ Tcl_ObjCmdProc * (*tclGetObjInterpProc) (void); /* 39 */
int (*tclGetOpenMode) (Tcl_Interp *interp, const char *str, int *seekFlagPtr); /* 40 */
Tcl_Command (*tclGetOriginalCommand) (Tcl_Command command); /* 41 */
CONST86 char * (*tclpGetUserHome) (const char *name, Tcl_DString *bufferPtr); /* 42 */
@@ -1377,6 +1377,8 @@ extern const TclIntStubs *tclIntStubsPtr;
#undef TclSetStartupScriptPath
#undef TclBackgroundException
#undef TclUnusedStubEntry
+#undef TclObjInterpProc
+#define TclObjInterpProc TclGetObjInterpProc()
#if defined(USE_TCL_STUBS) && defined(TCL_NO_DEPRECATED)
# undef Tcl_SetStartupScript
diff --git a/generic/tclProc.c b/generic/tclProc.c
index 7550bfa..97a32a6 100644
--- a/generic/tclProc.c
+++ b/generic/tclProc.c
@@ -163,8 +163,8 @@ Tcl_ProcObjCmd(
* Create the data structure to represent the procedure.
*/
- if (TclCreateProc(interp, nsPtr, simpleName, objv[2], objv[3],
- &procPtr) != TCL_OK) {
+ if (TclCreateProc(interp, nsPtr, simpleName, objv[2],
+ objv[3], &procPtr) != TCL_OK) {
Tcl_AddErrorInfo(interp, "\n (creating proc \"");
Tcl_AddErrorInfo(interp, simpleName);
Tcl_AddErrorInfo(interp, "\")");
@@ -200,7 +200,6 @@ Tcl_ProcObjCmd(
CmdFrame *contextPtr = (CmdFrame *)TclStackAlloc(interp, sizeof(CmdFrame));
*contextPtr = *iPtr->cmdFramePtr;
-
if (contextPtr->type == TCL_LOCATION_BC) {
/*
* Retrieve source information from the bytecode, if possible. If
@@ -255,7 +254,7 @@ Tcl_ProcObjCmd(
* is able to trigger this situation.
*/
- CmdFrame *cfOldPtr = Tcl_GetHashValue(hePtr);
+ CmdFrame *cfOldPtr = (CmdFrame *)Tcl_GetHashValue(hePtr);
if (cfOldPtr->type == TCL_LOCATION_SOURCE) {
Tcl_DecrRefCount(cfOldPtr->data.eval.path);
@@ -541,7 +540,7 @@ TclCreateProc(
* (its value was kept the same as pre VarReform to simplify
* tbcload's processing of older byetcodes).
*
- * The only other flag vlaue that is important to retrieve from
+ * The only other flag value that is important to retrieve from
* precompiled procs is VAR_TEMPORARY (also unchanged). It is
* needed later when retrieving the variable names.
*/
@@ -861,7 +860,7 @@ Uplevel_Callback(
Tcl_Interp *interp,
int result)
{
- CallFrame *savedVarFramePtr = data[0];
+ CallFrame *savedVarFramePtr = (CallFrame *)data[0];
if (result == TCL_ERROR) {
Tcl_AppendObjToErrorInfo(interp, Tcl_ObjPrintf(
@@ -876,15 +875,14 @@ Uplevel_Callback(
return result;
}
- /* ARGSUSED */
int
Tcl_UplevelObjCmd(
- ClientData dummy, /* Not used. */
+ ClientData clientData,
Tcl_Interp *interp, /* Current interpreter. */
int objc, /* Number of arguments. */
Tcl_Obj *const objv[]) /* Argument objects. */
{
- return Tcl_NRCallObjProc(interp, TclNRUplevelObjCmd, dummy, objc, objv);
+ return Tcl_NRCallObjProc(interp, TclNRUplevelObjCmd, clientData, objc, objv);
}
int
@@ -1045,7 +1043,7 @@ TclIsProc(
cmdPtr = (Command *) origCmd;
}
if (cmdPtr->deleteProc == TclProcDeleteProc) {
- return cmdPtr->objClientData;
+ return (Proc *)cmdPtr->objClientData;
}
return NULL;
}
@@ -1067,7 +1065,7 @@ ProcWrongNumArgs(
numArgs = framePtr->procPtr->numArgs;
desiredObjs = (Tcl_Obj **)TclStackAlloc(interp,
- (int) sizeof(Tcl_Obj *) * (numArgs+1));
+ sizeof(Tcl_Obj *) * (numArgs+1));
if (framePtr->isProcCallFrame & FRAME_IS_LAMBDA) {
desiredObjs[0] = Tcl_NewStringObj("lambdaExpr", -1);
@@ -1318,7 +1316,7 @@ InitLocalCache(
Var *varPtr;
LocalCache *localCachePtr;
CompiledLocal *localPtr;
- int new;
+ int isNew;
/*
* Cache the names and initial values of local variables; store the
@@ -1339,7 +1337,7 @@ InitLocalCache(
} else {
*namePtr = TclCreateLiteral(iPtr, localPtr->name,
localPtr->nameLength, /* hash */ (unsigned int) -1,
- &new, /* nsPtr */ NULL, 0, NULL);
+ &isNew, /* nsPtr */ NULL, 0, NULL);
Tcl_IncrRefCount(*namePtr);
}
@@ -1414,7 +1412,7 @@ InitArgsAndLocals(
* parameters.
*/
- varPtr = TclStackAlloc(interp, localCt * sizeof(Var));
+ varPtr = (Var *)TclStackAlloc(interp, localCt * sizeof(Var));
framePtr->compiledLocals = varPtr;
framePtr->numCompiledLocals = localCt;
@@ -1552,7 +1550,7 @@ TclPushProcCallFrame(
int isLambda) /* 1 if this is a call by ApplyObjCmd: it
* needs special rules for error msg */
{
- Proc *procPtr = clientData;
+ Proc *procPtr = (Proc *)clientData;
Namespace *nsPtr = procPtr->cmdPtr->nsPtr;
CallFrame *framePtr, **framePtrPtr;
int result;
@@ -1635,6 +1633,7 @@ TclPushProcCallFrame(
*----------------------------------------------------------------------
*/
+#undef TclObjInterpProc
int
TclObjInterpProc(
ClientData clientData, /* Record describing procedure to be
@@ -1795,7 +1794,7 @@ InterpProcNR2(
Interp *iPtr = (Interp *) interp;
Proc *procPtr = iPtr->varFramePtr->procPtr;
CallFrame *freePtr;
- Tcl_Obj *procNameObj = data[0];
+ Tcl_Obj *procNameObj = (Tcl_Obj *)data[0];
ProcErrorProc *errorProc = (ProcErrorProc *)data[1];
if (TCL_DTRACE_PROC_RETURN_ENABLED()) {
@@ -2033,7 +2032,7 @@ TclProcCompileProc(
*/
iPtr->invokeWord = 0;
- iPtr->invokeCmdFramePtr = (hePtr ? Tcl_GetHashValue(hePtr) : NULL);
+ iPtr->invokeCmdFramePtr = hePtr ? (CmdFrame *)Tcl_GetHashValue(hePtr) : NULL;
TclSetByteCodeFromAny(interp, bodyPtr, NULL, NULL);
iPtr->invokeCmdFramePtr = NULL;
TclPopStackFrame(interp);
@@ -2108,7 +2107,7 @@ void
TclProcDeleteProc(
ClientData clientData) /* Procedure to be deleted. */
{
- Proc *procPtr = clientData;
+ Proc *procPtr = (Proc *)clientData;
if (procPtr->refCount-- <= 1) {
TclProcCleanupProc(procPtr);
@@ -2190,7 +2189,7 @@ TclProcCleanupProc(
return;
}
- cfPtr = (CmdFrame *) Tcl_GetHashValue(hePtr);
+ cfPtr = (CmdFrame *)Tcl_GetHashValue(hePtr);
if (cfPtr) {
if (cfPtr->type == TCL_LOCATION_SOURCE) {
@@ -2271,10 +2270,10 @@ TclUpdateReturnInfo(
*----------------------------------------------------------------------
*/
-TclObjCmdProcType
+Tcl_ObjCmdProc *
TclGetObjInterpProc(void)
{
- return (TclObjCmdProcType) TclObjInterpProc;
+ return TclObjInterpProc;
}
/*
@@ -2497,7 +2496,7 @@ SetLambdaFromAny(
*/
if (iPtr->cmdFramePtr) {
- CmdFrame *contextPtr = TclStackAlloc(interp, sizeof(CmdFrame));
+ CmdFrame *contextPtr = (CmdFrame *)TclStackAlloc(interp, sizeof(CmdFrame));
*contextPtr = *iPtr->cmdFramePtr;
if (contextPtr->type == TCL_LOCATION_BC) {
@@ -2616,12 +2615,12 @@ SetLambdaFromAny(
int
Tcl_ApplyObjCmd(
- ClientData dummy, /* Not used. */
+ ClientData clientData,
Tcl_Interp *interp, /* Current interpreter. */
int objc, /* Number of arguments. */
Tcl_Obj *const objv[]) /* Argument objects. */
{
- return Tcl_NRCallObjProc(interp, TclNRApplyObjCmd, dummy, objc, objv);
+ return Tcl_NRCallObjProc(interp, TclNRApplyObjCmd, clientData, objc, objv);
}
int
@@ -2653,30 +2652,6 @@ TclNRApplyObjCmd(
procPtr = lambdaPtr->internalRep.twoPtrValue.ptr1;
}
-#define JOE_EXTENSION 0
-/*
- * Note: this code is NOT FUNCTIONAL due to the NR implementation; DO NOT
- * ENABLE! Leaving here as reminder to (a) TIP the suggestion, and (b) adapt
- * the code. (MS)
- */
-
-#if JOE_EXTENSION
- else {
- /*
- * Joe English's suggestion to allow cmdNames to function as lambdas.
- */
-
- Tcl_Obj *elemPtr;
- int numElem;
-
- if ((lambdaPtr->typePtr == &tclCmdNameType) ||
- (TclListObjGetElements(interp, lambdaPtr, &numElem,
- &elemPtr) == TCL_OK && numElem == 1)) {
- return Tcl_EvalObjv(interp, objc-1, objv+1, 0);
- }
- }
-#endif
-
if ((procPtr == NULL) || (procPtr->iPtr != iPtr)) {
result = SetLambdaFromAny(interp, lambdaPtr);
if (result != TCL_OK) {
@@ -2696,7 +2671,7 @@ TclNRApplyObjCmd(
return TCL_ERROR;
}
- extraPtr = TclStackAlloc(interp, sizeof(ApplyExtraData));
+ extraPtr = (ApplyExtraData *)TclStackAlloc(interp, sizeof(ApplyExtraData));
memset(&extraPtr->cmd, 0, sizeof(Command));
procPtr->cmdPtr = &extraPtr->cmd;
extraPtr->cmd.nsPtr = (Namespace *) nsPtr;
@@ -2731,7 +2706,7 @@ ApplyNR2(
Tcl_Interp *interp,
int result)
{
- ApplyExtraData *extraPtr = data[0];
+ ApplyExtraData *extraPtr = (ApplyExtraData *)data[0];
TclStackFree(interp, extraPtr);
return result;
diff --git a/generic/tclStubInit.c b/generic/tclStubInit.c
index 93efecd..7f21d83 100644
--- a/generic/tclStubInit.c
+++ b/generic/tclStubInit.c
@@ -54,6 +54,7 @@
#undef TclBN_mp_tc_and
#undef TclBN_mp_tc_or
#undef TclBN_mp_tc_xor
+#undef TclObjInterpProc
#define TclBN_mp_tc_and TclBN_mp_and
#define TclBN_mp_tc_or TclBN_mp_or
#define TclBN_mp_tc_xor TclBN_mp_xor
@@ -225,7 +226,7 @@ void *TclWinGetTclInstance()
int
TclpGetPid(Tcl_Pid pid)
{
- return (int) (size_t) pid;
+ return (int)(size_t)pid;
}
static void
@@ -1665,7 +1666,13 @@ const TclStubs tclStubs = {
0, /* 672 */
0, /* 673 */
0, /* 674 */
- TclUnusedStubEntry, /* 675 */
+ 0, /* 675 */
+ 0, /* 676 */
+ 0, /* 677 */
+ 0, /* 678 */
+ 0, /* 679 */
+ 0, /* 680 */
+ TclUnusedStubEntry, /* 681 */
};
/* !END!: Do not edit above this line. */