diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-02-01 20:36:01 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-02-01 20:36:01 (GMT) |
commit | eee14742522aed25744851879c80a96134de7369 (patch) | |
tree | 5650ddb981ce76c5b4348123db6def9c4be1aa68 /generic/tclIndexObj.c | |
parent | a6ecb97fa5846d7930c9649f008c490d06e8b054 (diff) | |
parent | 3106f9a6955f9df9de5df5879319b6e4393ab702 (diff) | |
download | tcl-eee14742522aed25744851879c80a96134de7369.zip tcl-eee14742522aed25744851879c80a96134de7369.tar.gz tcl-eee14742522aed25744851879c80a96134de7369.tar.bz2 |
Another (big) round of int -> size_t enhancements. So Tcl can handle string >2GiB in more places.
Diffstat (limited to 'generic/tclIndexObj.c')
-rw-r--r-- | generic/tclIndexObj.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/generic/tclIndexObj.c b/generic/tclIndexObj.c index 33656d6..eec6efa 100644 --- a/generic/tclIndexObj.c +++ b/generic/tclIndexObj.c @@ -143,7 +143,7 @@ GetIndexFromObjList( return TCL_OK; } - tablePtr[t] = Tcl_GetString(objv[t]); + tablePtr[t] = TclGetString(objv[t]); } tablePtr[objc] = NULL; @@ -544,7 +544,7 @@ PrefixMatchObjCmd( return TCL_ERROR; } i++; - message = Tcl_GetString(objv[i]); + message = TclGetString(objv[i]); break; case PRFMATCH_ERROR: if (i > objc-4) { @@ -634,7 +634,8 @@ PrefixAllObjCmd( int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ { - int tableObjc, result, t, length, elemLength; + int tableObjc, result, t; + size_t length, elemLength; const char *string, *elemString; Tcl_Obj **tableObjv, *resultPtr; @@ -691,7 +692,8 @@ PrefixLongestObjCmd( int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ { - int tableObjc, result, i, t, length, elemLength, resultLength; + int tableObjc, result, t; + size_t i, length, elemLength, resultLength; const char *string, *elemString, *resultString; Tcl_Obj **tableObjv; @@ -1124,7 +1126,7 @@ Tcl_ParseArgsObjv( (int *) infoPtr->dstPtr) == TCL_ERROR) { Tcl_SetObjResult(interp, Tcl_ObjPrintf( "expected integer argument for \"%s\" but got \"%s\"", - infoPtr->keyStr, Tcl_GetString(objv[srcIndex]))); + infoPtr->keyStr, TclGetString(objv[srcIndex]))); goto error; } srcIndex++; @@ -1135,7 +1137,7 @@ Tcl_ParseArgsObjv( goto missingArg; } *((const char **) infoPtr->dstPtr) = - Tcl_GetString(objv[srcIndex]); + TclGetString(objv[srcIndex]); srcIndex++; objc--; break; @@ -1157,7 +1159,7 @@ Tcl_ParseArgsObjv( (double *) infoPtr->dstPtr) == TCL_ERROR) { Tcl_SetObjResult(interp, Tcl_ObjPrintf( "expected floating-point argument for \"%s\" but got \"%s\"", - infoPtr->keyStr, Tcl_GetString(objv[srcIndex]))); + infoPtr->keyStr, TclGetString(objv[srcIndex]))); goto error; } srcIndex++; |