From da196c33450ded41b2370bf956f7d3cd7b081069 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Mon, 28 Nov 2022 12:58:18 +0000 Subject: No reservation for TIP #648 any more in stub table. --- generic/tcl.decls | 17 +++++++---------- generic/tclArithSeries.c | 26 +++++++++++++------------- generic/tclArithSeries.h | 4 ++-- generic/tclDecls.h | 26 ++++++++++++++------------ generic/tclStubInit.c | 8 ++++---- 5 files changed, 40 insertions(+), 41 deletions(-) diff --git a/generic/tcl.decls b/generic/tcl.decls index 6283089..a9c042c 100644 --- a/generic/tcl.decls +++ b/generic/tcl.decls @@ -2552,27 +2552,23 @@ declare 683 { int Tcl_GetEncodingNulLength(Tcl_Encoding encoding) } -# TIP #648 (reserved) -#declare 684 { -# Tcl_Obj *Tcl_NewWideUIntObj(Tcl_WideUInt wideValue) -#} -#declare 685 { -# void Tcl_SetWideUIntObj(Tcl_Obj *objPtr, Tcl_WideUInt uwideValue) -#} - # TIP #650 -declare 686 { +declare 684 { int Tcl_GetWideUIntFromObj(Tcl_Interp *interp, Tcl_Obj *objPtr, Tcl_WideUInt *uwidePtr) } # TIP 651 -declare 687 { +declare 685 { Tcl_Obj *Tcl_DStringToObj(Tcl_DString *dsPtr) } # ----- BASELINE -- FOR -- 8.7.0 / 9.0.0 ----- # +declare 687 { + void TclUnusedStubEntry(void) +} + ############################################################################## # Define the platform specific public Tcl interface. These functions are only @@ -2662,6 +2658,7 @@ export { const char *TclZipfs_AppHook(int *argc, char ***argv) } + # Local Variables: # mode: tcl # End: diff --git a/generic/tclArithSeries.c b/generic/tclArithSeries.c index c32c443..b278644 100755 --- a/generic/tclArithSeries.c +++ b/generic/tclArithSeries.c @@ -149,7 +149,7 @@ TclNewArithSeriesInt(Tcl_WideInt start, Tcl_WideInt end, Tcl_WideInt step, Tcl_W arithSeriesRepPtr->start = start; arithSeriesRepPtr->end = end; arithSeriesRepPtr->step = step; - arithSeriesRepPtr->len1 = length; + arithSeriesRepPtr->len = length; arithSeriesRepPtr->elements = NULL; arithSeriesPtr->internalRep.twoPtrValue.ptr1 = arithSeriesRepPtr; arithSeriesPtr->internalRep.twoPtrValue.ptr2 = NULL; @@ -196,7 +196,7 @@ TclNewArithSeriesDbl(double start, double end, double step, Tcl_WideInt len) arithSeriesRepPtr->start = start; arithSeriesRepPtr->end = end; arithSeriesRepPtr->step = step; - arithSeriesRepPtr->len1 = length; + arithSeriesRepPtr->len = length; arithSeriesRepPtr->elements = NULL; arithSeriesPtr->internalRep.twoPtrValue.ptr1 = arithSeriesRepPtr; arithSeriesPtr->internalRep.twoPtrValue.ptr2 = NULL; @@ -429,7 +429,7 @@ TclArithSeriesObjIndex(Tcl_Obj *arithSeriesPtr, Tcl_WideInt index, Tcl_Obj **ele Tcl_Panic("TclArithSeriesObjIndex called with a not ArithSeries Obj."); } arithSeriesRepPtr = ArithSeriesRepPtr(arithSeriesPtr); - if (index < 0 || index >= arithSeriesRepPtr->len1) { + if (index < 0 || index >= arithSeriesRepPtr->len) { return TCL_ERROR; } /* List[i] = Start + (Step * index) */ @@ -462,7 +462,7 @@ Tcl_Size TclArithSeriesObjLength(Tcl_Obj *arithSeriesPtr) { ArithSeries *arithSeriesRepPtr = (ArithSeries*) arithSeriesPtr->internalRep.twoPtrValue.ptr1; - return arithSeriesRepPtr->len1; + return arithSeriesRepPtr->len; } /* @@ -491,7 +491,7 @@ FreeArithSeriesInternalRep(Tcl_Obj *arithSeriesPtr) if (arithSeriesRepPtr->elements) { Tcl_WideInt i; Tcl_Obj**elmts = arithSeriesRepPtr->elements; - for(i=0; ilen1; i++) { + for(i=0; ilen; i++) { if (elmts[i]) { Tcl_DecrRefCount(elmts[i]); } @@ -581,7 +581,7 @@ UpdateStringOfArithSeries(Tcl_Obj *arithSeriesPtr) /* * Pass 1: estimate space. */ - for (i = 0; i < arithSeriesRepPtr->len1; i++) { + for (i = 0; i < arithSeriesRepPtr->len; i++) { TclArithSeriesObjIndex(arithSeriesPtr, i, &elemObj); elem = TclGetStringFromObj(elemObj, &slen); Tcl_DecrRefCount(elemObj); @@ -594,7 +594,7 @@ UpdateStringOfArithSeries(Tcl_Obj *arithSeriesPtr) */ p = Tcl_InitStringRep(arithSeriesPtr, NULL, length); - for (i = 0; i < arithSeriesRepPtr->len1; i++) { + for (i = 0; i < arithSeriesRepPtr->len; i++) { TclArithSeriesObjIndex(arithSeriesPtr, i, &elemObj); elem = TclGetStringFromObj(elemObj, &slen); strcpy(p, elem); @@ -727,7 +727,7 @@ TclArithSeriesObjRange( if (interp) { Tcl_SetObjResult(interp, Tcl_ObjPrintf("index %d is out of bounds 0 to %" - "d", fromIdx, (arithSeriesRepPtr->len1-1))); + "d", fromIdx, (arithSeriesRepPtr->len-1))); Tcl_SetErrorCode(interp, "TCL", "MEMORY", NULL); } return NULL; @@ -737,7 +737,7 @@ TclArithSeriesObjRange( if (interp) { Tcl_SetObjResult(interp, Tcl_ObjPrintf("index %d is out of bounds 0 to %" - "d", fromIdx, (arithSeriesRepPtr->len1-1))); + "d", fromIdx, (arithSeriesRepPtr->len-1))); Tcl_SetErrorCode(interp, "TCL", "MEMORY", NULL); } return NULL; @@ -780,7 +780,7 @@ TclArithSeriesObjRange( arithSeriesDblRepPtr->start = start; arithSeriesDblRepPtr->end = end; arithSeriesDblRepPtr->step = step; - arithSeriesDblRepPtr->len1 = (end-start+step)/step; + arithSeriesDblRepPtr->len = (end-start+step)/step; arithSeriesDblRepPtr->elements = NULL; } else { @@ -791,7 +791,7 @@ TclArithSeriesObjRange( arithSeriesRepPtr->start = start; arithSeriesRepPtr->end = end; arithSeriesRepPtr->step = step; - arithSeriesRepPtr->len1 = (end-start+step)/step; + arithSeriesRepPtr->len = (end-start+step)/step; arithSeriesRepPtr->elements = NULL; } @@ -847,7 +847,7 @@ TclArithSeriesGetElements( int i, objc; ArithSeriesGetInternalRep(objPtr, arithSeriesRepPtr); - objc = arithSeriesRepPtr->len1; + objc = arithSeriesRepPtr->len; if (objc > 0) { if (arithSeriesRepPtr->elements) { /* If this exists, it has already been populated */ @@ -929,7 +929,7 @@ TclArithSeriesObjReverse( ArithSeriesGetInternalRep(arithSeriesPtr, arithSeriesRepPtr); isDouble = arithSeriesRepPtr->isDouble; - len = arithSeriesRepPtr->len1; + len = arithSeriesRepPtr->len; TclArithSeriesObjIndex(arithSeriesPtr, (len-1), &startObj); Tcl_IncrRefCount(startObj); diff --git a/generic/tclArithSeries.h b/generic/tclArithSeries.h index f855f6f..1daacdd 100644 --- a/generic/tclArithSeries.h +++ b/generic/tclArithSeries.h @@ -16,7 +16,7 @@ * but it's faster to cache it inside the internal representation. */ typedef struct ArithSeries { - Tcl_Size len1; + Tcl_Size len; Tcl_Obj **elements; int isDouble; Tcl_WideInt start; @@ -24,7 +24,7 @@ typedef struct ArithSeries { Tcl_WideInt step; } ArithSeries; typedef struct ArithSeriesDbl { - Tcl_Size len1; + Tcl_Size len; Tcl_Obj **elements; int isDouble; double start; diff --git a/generic/tclDecls.h b/generic/tclDecls.h index eb15582..75fc17e 100644 --- a/generic/tclDecls.h +++ b/generic/tclDecls.h @@ -2040,13 +2040,14 @@ EXTERN int Tcl_RemoveChannelMode(Tcl_Interp *interp, Tcl_Channel chan, int mode); /* 683 */ EXTERN int Tcl_GetEncodingNulLength(Tcl_Encoding encoding); -/* Slot 684 is reserved */ -/* Slot 685 is reserved */ -/* 686 */ +/* 684 */ EXTERN int Tcl_GetWideUIntFromObj(Tcl_Interp *interp, Tcl_Obj *objPtr, Tcl_WideUInt *uwidePtr); -/* 687 */ +/* 685 */ EXTERN Tcl_Obj * Tcl_DStringToObj(Tcl_DString *dsPtr); +/* Slot 686 is reserved */ +/* 687 */ +EXTERN void TclUnusedStubEntry(void); typedef struct { const struct TclPlatStubs *tclPlatStubs; @@ -2766,10 +2767,10 @@ typedef struct TclStubs { int (*tcl_GetNumber) (Tcl_Interp *interp, const char *bytes, size_t numBytes, void **clientDataPtr, int *typePtr); /* 681 */ int (*tcl_RemoveChannelMode) (Tcl_Interp *interp, Tcl_Channel chan, int mode); /* 682 */ int (*tcl_GetEncodingNulLength) (Tcl_Encoding encoding); /* 683 */ - void (*reserved684)(void); - void (*reserved685)(void); - int (*tcl_GetWideUIntFromObj) (Tcl_Interp *interp, Tcl_Obj *objPtr, Tcl_WideUInt *uwidePtr); /* 686 */ - Tcl_Obj * (*tcl_DStringToObj) (Tcl_DString *dsPtr); /* 687 */ + int (*tcl_GetWideUIntFromObj) (Tcl_Interp *interp, Tcl_Obj *objPtr, Tcl_WideUInt *uwidePtr); /* 684 */ + Tcl_Obj * (*tcl_DStringToObj) (Tcl_DString *dsPtr); /* 685 */ + void (*reserved686)(void); + void (*tclUnusedStubEntry) (void); /* 687 */ } TclStubs; extern const TclStubs *tclStubsPtr; @@ -4168,12 +4169,13 @@ extern const TclStubs *tclStubsPtr; (tclStubsPtr->tcl_RemoveChannelMode) /* 682 */ #define Tcl_GetEncodingNulLength \ (tclStubsPtr->tcl_GetEncodingNulLength) /* 683 */ -/* Slot 684 is reserved */ -/* Slot 685 is reserved */ #define Tcl_GetWideUIntFromObj \ - (tclStubsPtr->tcl_GetWideUIntFromObj) /* 686 */ + (tclStubsPtr->tcl_GetWideUIntFromObj) /* 684 */ #define Tcl_DStringToObj \ - (tclStubsPtr->tcl_DStringToObj) /* 687 */ + (tclStubsPtr->tcl_DStringToObj) /* 685 */ +/* Slot 686 is reserved */ +#define TclUnusedStubEntry \ + (tclStubsPtr->tclUnusedStubEntry) /* 687 */ #endif /* defined(USE_TCL_STUBS) */ diff --git a/generic/tclStubInit.c b/generic/tclStubInit.c index 865effe..ddc0bc9 100644 --- a/generic/tclStubInit.c +++ b/generic/tclStubInit.c @@ -2055,10 +2055,10 @@ const TclStubs tclStubs = { Tcl_GetNumber, /* 681 */ Tcl_RemoveChannelMode, /* 682 */ Tcl_GetEncodingNulLength, /* 683 */ - 0, /* 684 */ - 0, /* 685 */ - Tcl_GetWideUIntFromObj, /* 686 */ - Tcl_DStringToObj, /* 687 */ + Tcl_GetWideUIntFromObj, /* 684 */ + Tcl_DStringToObj, /* 685 */ + 0, /* 686 */ + TclUnusedStubEntry, /* 687 */ }; /* !END!: Do not edit above this line. */ -- cgit v0.12