.
D 2014-10-11T04:09:46.072
L index\sObject\sType
P 7cbf464117ed21df6c835cf8c98e6dbf794d6eb8
U dgp
W 1562
<h1>Source Files</h1>
* [/finfo?name=generic/tclIndexObj.c|tclIndexObj.c]
<h1>Public Interface</h1>
* Tcl_GetIndexFromObj
* Tcl_GetIndexFromObjStruct
* Tcl_WrongNumArgs
* Tcl_ParseArgsObjv
<h1>Private Interface</h1>
* TclInitPrefixCmd
* TclGetCompletionCodeFromObj
<h1>Directly Depends On Public Interface Of</h1>
* [Tcl_Obj System]
* [Allocation]
* [string Object Type]
* [Parsing and Evaluation]
* [namespace]
* [list Object Type]
* [UTF-8 Strings]
* [numeric Object Types]
<h1>Directly Depends On Private Interface of</h1>
* [Tcl_Obj System]
* [namespace]
* [String Processing]
* [Bytecode]
* [List Parsing]
* [numeric Object Type]
<h1>Discussion</h1>
An "index" value remembers the lookup of a string in a table of
strings.
Unless Object Types change a lot, the routines SetIndexFromAny and
UpdateStringOfIndex do not need to exist. The object type is a caching
one only, saving a table lookup result. There are no pure "index" values.
<b>Tcl_WrongNumArgs</b> is piled high with hackery, special cases
and ugliness to bend it into useful service for ensembles, and possibly
Itcl command variants as well. Surely a do-over with a clear vision of
the support task from the beginning could be better.
The completion codes extractor might be good public.
There's no need to worry about INT_MAX restrictions here. These tools
are for looking up in small tables of small strings via linear search.
No need for major sophistication here.
Z 91b702a3ac64986f311bb14914f7a76a