diff options
author | dgp <dgp@users.sourceforge.net> | 2017-12-15 16:50:50 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2017-12-15 16:50:50 (GMT) |
commit | 67f6f5cdb190d17b5178a5d5c8d090440bbc1005 (patch) | |
tree | cbf232910656e5ba9ce6703d5220f37299f28760 /generic | |
parent | 4fb66d5d55a3239a342ae799da586966fe8326cf (diff) | |
download | tcl-67f6f5cdb190d17b5178a5d5c8d090440bbc1005.zip tcl-67f6f5cdb190d17b5178a5d5c8d090440bbc1005.tar.gz tcl-67f6f5cdb190d17b5178a5d5c8d090440bbc1005.tar.bz2 |
Revert the (int -> size_t) transition of the "cmdEpoch" field of
the struct Command that was part of [ff3f6a12a8d099ef], and related changes.
This change broke the ability of Itcl 3.4 built against Tcl 8.6 headers
to successfully [load] into and operate in a Tcl 8.7 interp.
"Command" is a private struct, and Itcl 3 should have respected that, but
it has not, and changing the size of the cmdEpoch field broke the ability
of Itcl 3 to operate on later fields of the struct, notably the deleteProc,
which it makes extensive use of.
I believe we should keep the change in the Tcl 9 sources.
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclBasic.c | 2 | ||||
-rw-r--r-- | generic/tclInt.h | 2 | ||||
-rw-r--r-- | generic/tclObj.c | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/generic/tclBasic.c b/generic/tclBasic.c index 406d0b1..292b466 100644 --- a/generic/tclBasic.c +++ b/generic/tclBasic.c @@ -4789,7 +4789,7 @@ TEOV_RunEnterTraces( { Interp *iPtr = (Interp *) interp; Command *cmdPtr = *cmdPtrPtr; - size_t newEpoch, cmdEpoch = cmdPtr->cmdEpoch; + int newEpoch, cmdEpoch = cmdPtr->cmdEpoch; int length, traceCode = TCL_OK; const char *command = TclGetStringFromObj(commandPtr, &length); diff --git a/generic/tclInt.h b/generic/tclInt.h index ad1d9c6..49d88aa 100644 --- a/generic/tclInt.h +++ b/generic/tclInt.h @@ -1639,7 +1639,7 @@ typedef struct Command { * representing a command's name in a ByteCode * instruction sequence. This structure can be * freed when refCount becomes zero. */ - size_t cmdEpoch; /* Incremented to invalidate any references + int cmdEpoch; /* Incremented to invalidate any references * that point to this command when it is * renamed, deleted, hidden, or exposed. */ CompileProc *compileProc; /* Procedure called to compile command. NULL diff --git a/generic/tclObj.c b/generic/tclObj.c index 1a00011..1aa24f2 100644 --- a/generic/tclObj.c +++ b/generic/tclObj.c @@ -354,7 +354,7 @@ typedef struct ResolvedCmdName { * Before using the cached pointer, we check * if the namespace's epoch was incremented; * if so, this cached pointer is invalid. */ - size_t cmdEpoch; /* Value of the command's cmdEpoch when this + int cmdEpoch; /* Value of the command's cmdEpoch when this * pointer was cached. Before using the cached * pointer, we check if the cmd's epoch was * incremented; if so, the cmd was renamed, |