diff options
| author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-08-15 07:08:07 (GMT) |
|---|---|---|
| committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-08-15 07:08:07 (GMT) |
| commit | 02ccd2a2ba84111c45dab93d4f3b80191e45108e (patch) | |
| tree | 6518028407edba465c523492cb32bc3dd7f72fc0 /generic/tclIndexObj.c | |
| parent | 831e40a351cc05df4e170c4606d090020bd80b3a (diff) | |
| parent | 6e2f02a5a6a694d1c1ad853307791acf1fd85c92 (diff) | |
| download | tcl-02ccd2a2ba84111c45dab93d4f3b80191e45108e.zip tcl-02ccd2a2ba84111c45dab93d4f3b80191e45108e.tar.gz tcl-02ccd2a2ba84111c45dab93d4f3b80191e45108e.tar.bz2 | |
Eliminate "register" keyword _everywhere_ in Tcl. This keyword is deprecated in C++ (removed in C++17, even), and essentially does nothing with most modern compilers
Diffstat (limited to 'generic/tclIndexObj.c')
| -rw-r--r-- | generic/tclIndexObj.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/generic/tclIndexObj.c b/generic/tclIndexObj.c index 919db92..e7c3b46 100644 --- a/generic/tclIndexObj.c +++ b/generic/tclIndexObj.c @@ -426,7 +426,7 @@ Tcl_GetIndexFromObjStruct( static int SetIndexFromAny( Tcl_Interp *interp, /* Used for error reporting if not NULL. */ - register Tcl_Obj *objPtr) /* The object to convert. */ + Tcl_Obj *objPtr) /* The object to convert. */ { if (interp) { Tcl_SetObjResult(interp, Tcl_NewStringObj( @@ -458,7 +458,7 @@ UpdateStringOfIndex( Tcl_Obj *objPtr) { IndexRep *indexRep = TclFetchIntRep(objPtr, &indexType)->twoPtrValue.ptr1; - register const char *indexStr = EXPAND_OF(indexRep); + const char *indexStr = EXPAND_OF(indexRep); Tcl_InitStringRep(objPtr, indexStr, strlen(indexStr)); } @@ -967,7 +967,7 @@ Tcl_WrongNumArgs( const Tcl_ObjIntRep *irPtr; if ((irPtr = TclFetchIntRep(origObjv[i], &indexType))) { - register IndexRep *indexRep = irPtr->twoPtrValue.ptr1; + IndexRep *indexRep = irPtr->twoPtrValue.ptr1; elementStr = EXPAND_OF(indexRep); elemLen = strlen(elementStr); @@ -1016,7 +1016,7 @@ Tcl_WrongNumArgs( const Tcl_ObjIntRep *irPtr; if ((irPtr = TclFetchIntRep(objv[i], &indexType))) { - register IndexRep *indexRep = irPtr->twoPtrValue.ptr1; + IndexRep *indexRep = irPtr->twoPtrValue.ptr1; Tcl_AppendStringsToObj(objPtr, EXPAND_OF(indexRep), NULL); } else { @@ -1107,14 +1107,14 @@ Tcl_ParseArgsObjv( * successful exit. Will include the name of * the command. */ int nrem; /* Size of leftovers.*/ - register const Tcl_ArgvInfo *infoPtr; + const Tcl_ArgvInfo *infoPtr; /* Pointer to the current entry in the table * of argument descriptions. */ const Tcl_ArgvInfo *matchPtr; /* Descriptor that matches current argument */ Tcl_Obj *curArg; /* Current argument */ const char *str = NULL; - register char c; /* Second character of current arg (used for + char c; /* Second character of current arg (used for * quick check for matching; use 2nd char. * because first char. will almost always be * '-'). */ @@ -1362,7 +1362,7 @@ PrintUsage( /* Array of command-specific argument * descriptions. */ { - register const Tcl_ArgvInfo *infoPtr; + const Tcl_ArgvInfo *infoPtr; int width, numSpaces; #define NUM_SPACES 20 static const char spaces[] = " "; |
