summaryrefslogtreecommitdiffstats
path: root/generic/tclIndexObj.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2016-07-08 10:28:48 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2016-07-08 10:28:48 (GMT)
commitf84ad84e4153f7bdce3247e5f5ab7477e74db51f (patch)
tree2b8995478cfb59e408b65de66a7a0c682f23bca7 /generic/tclIndexObj.c
parent72476cdd50825cebaea367188325e69ea5a8ff40 (diff)
downloadtcl-f84ad84e4153f7bdce3247e5f5ab7477e74db51f.zip
tcl-f84ad84e4153f7bdce3247e5f5ab7477e74db51f.tar.gz
tcl-f84ad84e4153f7bdce3247e5f5ab7477e74db51f.tar.bz2
Micro-optimization: Use TclGetStringFromObj in stead of Tcl_GetStringFromObj in many places where possible.
Diffstat (limited to 'generic/tclIndexObj.c')
-rw-r--r--generic/tclIndexObj.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/generic/tclIndexObj.c b/generic/tclIndexObj.c
index 0e0ddc9..2281d22 100644
--- a/generic/tclIndexObj.c
+++ b/generic/tclIndexObj.c
@@ -712,10 +712,10 @@ PrefixAllObjCmd(
return result;
}
resultPtr = Tcl_NewListObj(0, NULL);
- string = Tcl_GetStringFromObj(objv[2], &length);
+ string = TclGetStringFromObj(objv[2], &length);
for (t = 0; t < tableObjc; t++) {
- elemString = Tcl_GetStringFromObj(tableObjv[t], &elemLength);
+ elemString = TclGetStringFromObj(tableObjv[t], &elemLength);
/*
* A prefix cannot match if it is longest.
@@ -768,13 +768,13 @@ PrefixLongestObjCmd(
if (result != TCL_OK) {
return result;
}
- string = Tcl_GetStringFromObj(objv[2], &length);
+ string = TclGetStringFromObj(objv[2], &length);
resultString = NULL;
resultLength = 0;
for (t = 0; t < tableObjc; t++) {
- elemString = Tcl_GetStringFromObj(tableObjv[t], &elemLength);
+ elemString = TclGetStringFromObj(tableObjv[t], &elemLength);
/*
* First check if the prefix string matches the element. A prefix
@@ -1148,7 +1148,7 @@ Tcl_ParseArgsObjv(
curArg = objv[srcIndex];
srcIndex++;
objc--;
- str = Tcl_GetStringFromObj(curArg, &length);
+ str = TclGetStringFromObj(curArg, &length);
if (length > 0) {
c = str[1];
} else {