diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2023-04-13 14:02:23 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2023-04-13 14:02:23 (GMT) |
commit | 4307d0a739ddfd9545e59a0ccf16067fc2dab2a2 (patch) | |
tree | f399cf6578abde4532ed6b0f40ae2aa562eff10d | |
parent | 9c0541d0e4b22e9f9e12d754ba7c9bb1c430a0a8 (diff) | |
download | tcl-4307d0a739ddfd9545e59a0ccf16067fc2dab2a2.zip tcl-4307d0a739ddfd9545e59a0ccf16067fc2dab2a2.tar.gz tcl-4307d0a739ddfd9545e59a0ccf16067fc2dab2a2.tar.bz2 |
Follow-up to previous commit: Let's not break TIP #627 either. Also adapt documentation (will be needed to be done anyway)
-rw-r--r-- | doc/Class.3 | 2 | ||||
-rw-r--r-- | doc/CrtAlias.3 | 2 | ||||
-rw-r--r-- | doc/Eval.3 | 2 | ||||
-rw-r--r-- | doc/FileSystem.3 | 6 | ||||
-rw-r--r-- | doc/ListObj.3 | 12 | ||||
-rw-r--r-- | doc/Method.3 | 6 | ||||
-rw-r--r-- | doc/NRE.3 | 2 | ||||
-rw-r--r-- | doc/PkgRequire.3 | 2 | ||||
-rw-r--r-- | doc/StringObj.3 | 20 | ||||
-rw-r--r-- | doc/WrongNumArgs.3 | 2 | ||||
-rw-r--r-- | generic/tcl.decls | 2 | ||||
-rw-r--r-- | generic/tclBasic.c | 2 | ||||
-rw-r--r-- | generic/tclDecls.h | 4 | ||||
-rw-r--r-- | generic/tclOO.h | 2 | ||||
-rw-r--r-- | win/tclWinFCmd.c | 6 | ||||
-rw-r--r-- | win/tclWinInit.c | 2 | ||||
-rw-r--r-- | win/tclWinSerial.c | 4 |
17 files changed, 39 insertions, 39 deletions
diff --git a/doc/Class.3 b/doc/Class.3 index c029595..508b864 100644 --- a/doc/Class.3 +++ b/doc/Class.3 @@ -81,7 +81,7 @@ automatically selected. The name of the namespace to create for the object's private use, or NULL if a new unused name is to be automatically selected. The namespace must not already exist. -.AP size_t objc in +.AP Tcl_Size objc in The number of elements in the \fIobjv\fR array. .AP "Tcl_Obj *const" *objv in The arguments to the command to create the instance of the class. diff --git a/doc/CrtAlias.3 b/doc/CrtAlias.3 index 12494bf..0deb17b 100644 --- a/doc/CrtAlias.3 +++ b/doc/CrtAlias.3 @@ -74,7 +74,7 @@ Count of additional arguments to pass to the alias command. .AP "const char *const" *argv in Vector of strings, the additional arguments to pass to the alias command. This storage is owned by the caller. -.AP size_t objc in +.AP Tcl_Size objc in Count of additional value arguments to pass to the aliased command. .AP Tcl_Obj **objv in Vector of Tcl_Obj structures, the additional value arguments to pass to @@ -50,7 +50,7 @@ ORed combination of flag bits that specify additional options. \fBTCL_EVAL_GLOBAL\fR and \fBTCL_EVAL_DIRECT\fR are currently supported. .AP "const char" *fileName in Name of a file containing a Tcl script. -.AP size_t objc in +.AP Tcl_Size objc in The number of values in the array pointed to by \fIobjv\fR; this is also the number of words in the command. .AP Tcl_Obj **objv in diff --git a/doc/FileSystem.3 b/doc/FileSystem.3 index 3387f50..b2c5769 100644 --- a/doc/FileSystem.3 +++ b/doc/FileSystem.3 @@ -220,7 +220,7 @@ The second of two path values to compare. The value may be converted to \fBpath\fR type. .AP Tcl_Obj *listObj in The list of path elements to operate on with a \fBjoin\fR operation. -.AP size_t elements in +.AP Tcl_Size elements in The number of elements in the \fIlistObj\fR which should be joined together. If TCL_INDEX_NONE, then all elements are joined. .AP Tcl_Obj **errorPtr out @@ -269,11 +269,11 @@ allowed for the \fImode\fR argument to the Tcl \fBopen\fR command. .AP int permissions in POSIX-style permission flags such as 0644. If a new file is created, these permissions will be set on the created file. -.AP "size_t \&| int" *lenPtr out +.AP "ptrdiff_t \&| int" *lenPtr out If non-NULL, filled with the number of elements in the split path. .AP Tcl_Obj *basePtr in The base path on to which to join the given elements. May be NULL. -.AP size_t objc in +.AP Tcl_Size objc in The number of elements in \fIobjv\fR. .AP "Tcl_Obj *const" objv[] in The elements to join to the given base path. diff --git a/doc/ListObj.3 b/doc/ListObj.3 index a0ed5c9..7c35603 100644 --- a/doc/ListObj.3 +++ b/doc/ListObj.3 @@ -59,13 +59,13 @@ points to the Tcl value that will be appended to \fIlistPtr\fR. For \fBTcl_SetListObj\fR, this points to the Tcl value that will be converted to a list value containing the \fIobjc\fR elements of the array referenced by \fIobjv\fR. -.AP "size_t \&| int" *objcPtr in +.AP "ptrdiff_t \&| int" *objcPtr in Points to location where \fBTcl_ListObjGetElements\fR stores the number of element values in \fIlistPtr\fR. .AP Tcl_Obj ***objvPtr out A location where \fBTcl_ListObjGetElements\fR stores a pointer to an array of pointers to the element values of \fIlistPtr\fR. -.AP size_t objc in +.AP Tcl_Size objc in The number of Tcl values that \fBTcl_NewListObj\fR will insert into a new list value, and \fBTcl_ListObjReplace\fR will insert into \fIlistPtr\fR. @@ -76,21 +76,21 @@ An array of pointers to values. \fBTcl_NewListObj\fR will insert these values into a new list value and \fBTcl_ListObjReplace\fR will insert them into an existing \fIlistPtr\fR. Each value will become a separate list element. -.AP "size_t \&| int" *lengthPtr out +.AP "ptrdiff_t \&| int" *lengthPtr out Points to location where \fBTcl_ListObjLength\fR stores the length of the list. -.AP size_t index in +.AP Tcl_Size index in Index of the list element that \fBTcl_ListObjIndex\fR is to return. The first element has index 0. .AP Tcl_Obj **objPtrPtr out Points to place where \fBTcl_ListObjIndex\fR is to store a pointer to the resulting list element value. -.AP size_t first in +.AP Tcl_Size first in Index of the starting list element that \fBTcl_ListObjReplace\fR is to replace. The list's first element has index 0. -.AP size_t count in +.AP Tcl_Size count in The number of elements that \fBTcl_ListObjReplace\fR is to replace. .BE diff --git a/doc/Method.3 b/doc/Method.3 index c3a6b64..377fc5a 100644 --- a/doc/Method.3 +++ b/doc/Method.3 @@ -58,7 +58,7 @@ Tcl_Method Tcl_Object \fBTcl_ObjectContextObject\fR(\fIcontext\fR) .sp -size_t +Tcl_Size \fBTcl_ObjectContextSkippedArgs\fR(\fIcontext\fR) .SH ARGUMENTS .AS void *clientData in @@ -95,11 +95,11 @@ A reference to a method to query. .AP Tcl_ObjectContext context in A reference to a method-call context. Note that client code \fImust not\fR retain a reference to a context. -.AP size_t objc in +.AP Tcl_Size objc in The number of arguments to pass to the method implementation. .AP "Tcl_Obj *const" *objv in An array of arguments to pass to the method implementation. -.AP size_t skip in +.AP Tcl_Size skip in The number of arguments passed to the method implementation that do not represent "real" arguments. .BE @@ -69,7 +69,7 @@ and \fIobjProc\fR. .AP Tcl_CmdDeleteProc *deleteProc in/out Called before \fIcmdName\fR is deleted from the interpreter, allowing for command-specific cleanup. May be NULL. -.AP size_t objc in +.AP Tcl_Size objc in Number of items in \fIobjv\fR. .AP Tcl_Obj **objv in Words in the command. diff --git a/doc/PkgRequire.3 b/doc/PkgRequire.3 index 8932135..1b76ed6 100644 --- a/doc/PkgRequire.3 +++ b/doc/PkgRequire.3 @@ -55,7 +55,7 @@ Pointer to place to store the value associated with the matching package. It is only changed if the pointer is not NULL and the function completed successfully. The storage can be any pointer type with the same size as a void pointer. -.AP size_t objc in +.AP Tcl_Size objc in Number of requirements. .AP Tcl_Obj* objv[] in Array of requirements. diff --git a/doc/StringObj.3 b/doc/StringObj.3 index 2d41018..e6144aa 100644 --- a/doc/StringObj.3 +++ b/doc/StringObj.3 @@ -40,7 +40,7 @@ Tcl_UniChar * int \fBTcl_GetUniChar\fR(\fIobjPtr, index\fR) .sp -size_t +Tcl_Size \fBTcl_GetCharLength\fR(\fIobjPtr\fR) .sp Tcl_Obj * @@ -91,7 +91,7 @@ unless \fInumChars\fR is \fBTCL_INDEX_NONE\fR. (Applications needing null bytes should represent them as the two-byte sequence \fI\e300\e200\fR, use \fBTcl_ExternalToUtf\fR to convert, or \fBTcl_NewByteArrayObj\fR if the string is a collection of uninterpreted bytes.) -.AP size_t length in +.AP Tcl_Size length in The number of bytes to copy from \fIbytes\fR when initializing, setting, or appending to a string value. If \fBTCL_INDEX_NONE\fR, all bytes up to the first null are used. @@ -100,17 +100,17 @@ Points to the first byte of an array of Unicode characters used to set or append to a string value. This byte array may contain embedded null characters unless \fInumChars\fR is \fBTCL_INDEX_NONE\fR. -.AP size_t numChars in +.AP Tcl_Size numChars in The number of Unicode characters to copy from \fIunicode\fR when initializing, setting, or appending to a string value. If \fBTCL_INDEX_NONE\fR, all characters up to the first null character are used. -.AP size_t index in +.AP Tcl_Size index in The index of the Unicode character to return. -.AP size_t first in +.AP Tcl_Size first in The index of the first Unicode character in the Unicode range to be returned as a new value. If \fBTCL_INDEX_NONE\fR, behave the same as if the value was 0. -.AP size_t last in +.AP Tcl_Size last in The index of the last Unicode character in the Unicode range to be returned as a new value. If \fBTCL_INDEX_NONE\fR, take all characters up to the last one available. @@ -118,7 +118,7 @@ the last one available. Points to a value to manipulate. .AP Tcl_Obj *appendObjPtr in The value to append to \fIobjPtr\fR in \fBTcl_AppendObjToObj\fR. -.AP "size_t \&| int" *lengthPtr out +.AP "ptrdiff_t \&| int" *lengthPtr out The location where \fBTcl_GetStringFromObj\fR will store the length of a value's string representation. May be (int *)NULL when not used. .AP "const char" *string in @@ -126,7 +126,7 @@ Null-terminated string value to append to \fIobjPtr\fR. .AP va_list argList in An argument list which must have been initialized using \fBva_start\fR, and cleared using \fBva_end\fR. -.AP size_t limit in +.AP Tcl_Size limit in Maximum number of bytes to be appended. .AP "const char" *ellipsis in Suffix to append when the limit leads to string truncation. @@ -135,11 +135,11 @@ If NULL is passed then the suffix is used. .AP "const char" *format in Format control string including % conversion specifiers. -.AP size_t objc in +.AP Tcl_Size objc in The number of elements to format or concatenate. .AP Tcl_Obj *objv[] in The array of values to format or concatenate. -.AP size_t newLength in +.AP Tcl_Size newLength in New length for the string value of \fIobjPtr\fR, not including the final null character. .BE diff --git a/doc/WrongNumArgs.3 b/doc/WrongNumArgs.3 index b501d36..0d00c0b 100644 --- a/doc/WrongNumArgs.3 +++ b/doc/WrongNumArgs.3 @@ -19,7 +19,7 @@ Tcl_WrongNumArgs \- generate standard error message for wrong number of argument .AP Tcl_Interp interp in Interpreter in which error will be reported: error message gets stored in its result value. -.AP size_t objc in +.AP Tcl_Size objc in Number of leading arguments from \fIobjv\fR to include in error message. .AP "Tcl_Obj *const" objv[] in diff --git a/generic/tcl.decls b/generic/tcl.decls index a888ec8..ea09b45 100644 --- a/generic/tcl.decls +++ b/generic/tcl.decls @@ -2592,7 +2592,7 @@ declare 678 { } declare 679 { int Tcl_NRCallObjProc2(Tcl_Interp *interp, Tcl_ObjCmdProc2 *objProc2, - void *clientData, size_t objc, Tcl_Obj *const objv[]) + void *clientData, ptrdiff_t objc, Tcl_Obj *const objv[]) } # TIP #638. diff --git a/generic/tclBasic.c b/generic/tclBasic.c index d767ce3..74ff935 100644 --- a/generic/tclBasic.c +++ b/generic/tclBasic.c @@ -8505,7 +8505,7 @@ Tcl_NRCallObjProc2( Tcl_Interp *interp, Tcl_ObjCmdProc2 *objProc, void *clientData, - size_t objc, + ptrdiff_t objc, Tcl_Obj *const objv[]) { if (objc > INT_MAX) { diff --git a/generic/tclDecls.h b/generic/tclDecls.h index 308168d..55660b4 100644 --- a/generic/tclDecls.h +++ b/generic/tclDecls.h @@ -1842,7 +1842,7 @@ EXTERN Tcl_Command Tcl_NRCreateCommand2(Tcl_Interp *interp, /* 679 */ EXTERN int Tcl_NRCallObjProc2(Tcl_Interp *interp, Tcl_ObjCmdProc2 *objProc2, void *clientData, - size_t objc, Tcl_Obj *const objv[]); + ptrdiff_t objc, Tcl_Obj *const objv[]); /* 680 */ EXTERN int Tcl_GetNumberFromObj(Tcl_Interp *interp, Tcl_Obj *objPtr, void **clientDataPtr, @@ -2556,7 +2556,7 @@ typedef struct TclStubs { Tcl_Command (*tcl_CreateObjCommand2) (Tcl_Interp *interp, const char *cmdName, Tcl_ObjCmdProc2 *proc2, void *clientData, Tcl_CmdDeleteProc *deleteProc); /* 676 */ Tcl_Trace (*tcl_CreateObjTrace2) (Tcl_Interp *interp, Tcl_Size level, int flags, Tcl_CmdObjTraceProc2 *objProc2, void *clientData, Tcl_CmdObjTraceDeleteProc *delProc); /* 677 */ Tcl_Command (*tcl_NRCreateCommand2) (Tcl_Interp *interp, const char *cmdName, Tcl_ObjCmdProc2 *proc, Tcl_ObjCmdProc2 *nreProc2, void *clientData, Tcl_CmdDeleteProc *deleteProc); /* 678 */ - int (*tcl_NRCallObjProc2) (Tcl_Interp *interp, Tcl_ObjCmdProc2 *objProc2, void *clientData, size_t objc, Tcl_Obj *const objv[]); /* 679 */ + int (*tcl_NRCallObjProc2) (Tcl_Interp *interp, Tcl_ObjCmdProc2 *objProc2, void *clientData, ptrdiff_t objc, Tcl_Obj *const objv[]); /* 679 */ int (*tcl_GetNumberFromObj) (Tcl_Interp *interp, Tcl_Obj *objPtr, void **clientDataPtr, int *typePtr); /* 680 */ 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 */ diff --git a/generic/tclOO.h b/generic/tclOO.h index 6f18491..775bd32 100644 --- a/generic/tclOO.h +++ b/generic/tclOO.h @@ -63,7 +63,7 @@ typedef struct Tcl_ObjectContext_ *Tcl_ObjectContext; typedef int (Tcl_MethodCallProc)(void *clientData, Tcl_Interp *interp, Tcl_ObjectContext objectContext, int objc, Tcl_Obj *const *objv); typedef int (Tcl_MethodCallProc2)(void *clientData, Tcl_Interp *interp, - Tcl_ObjectContext objectContext, size_t objc, Tcl_Obj *const *objv); + Tcl_ObjectContext objectContext, ptrdiff_t objc, Tcl_Obj *const *objv); typedef void (Tcl_MethodDeleteProc)(void *clientData); typedef int (Tcl_CloneProc)(Tcl_Interp *interp, void *oldClientData, void **newClientData); diff --git a/win/tclWinFCmd.c b/win/tclWinFCmd.c index 422c70c..0451035 100644 --- a/win/tclWinFCmd.c +++ b/win/tclWinFCmd.c @@ -309,7 +309,8 @@ DoRenameFile( if (srcAttr & FILE_ATTRIBUTE_DIRECTORY) { WCHAR *nativeSrcRest, *nativeDstRest; const char **srcArgv, **dstArgv; - size_t size, srcArgc, dstArgc; + size_t size; + Tcl_Size srcArgc, dstArgc; WCHAR nativeSrcPath[MAX_PATH]; WCHAR nativeDstPath[MAX_PATH]; Tcl_DString srcString, dstString; @@ -1595,9 +1596,8 @@ ConvertFileNameFormat( int longShort, /* 0 to short name, 1 to long name. */ Tcl_Obj **attributePtrPtr) /* A pointer to return the object with. */ { - size_t pathc, i; + Tcl_Size pathc, i, length; Tcl_Obj *splitPath; - size_t length; splitPath = Tcl_FSSplitPath(fileName, &pathc); diff --git a/win/tclWinInit.c b/win/tclWinInit.c index bb9ef66..b58c897 100644 --- a/win/tclWinInit.c +++ b/win/tclWinInit.c @@ -198,7 +198,7 @@ AppendEnvironment( Tcl_Obj *pathPtr, const char *lib) { - size_t pathc; + Tcl_Size pathc; WCHAR wBuf[MAX_PATH]; char buf[MAX_PATH * 3]; Tcl_Obj *objPtr; diff --git a/win/tclWinSerial.c b/win/tclWinSerial.c index b712cfd..d8f8447 100644 --- a/win/tclWinSerial.c +++ b/win/tclWinSerial.c @@ -1624,7 +1624,7 @@ SerialSetOptionProc( size_t len, vlen; Tcl_DString ds; const WCHAR *native; - size_t argc; + Tcl_Size argc; const char **argv; infoPtr = (SerialInfo *) instanceData; @@ -1820,7 +1820,7 @@ SerialSetOptionProc( */ if ((len > 4) && (strncmp(optionName, "-ttycontrol", len) == 0)) { - size_t i; + Tcl_Size i; int res = TCL_OK; if (Tcl_SplitList(interp, value, &argc, &argv) == TCL_ERROR) { |