summaryrefslogtreecommitdiffstats
path: root/generic/tclIndexObj.c
diff options
context:
space:
mode:
authornijtmans <nijtmans@noemail.net>2008-11-25 23:19:00 (GMT)
committernijtmans <nijtmans@noemail.net>2008-11-25 23:19:00 (GMT)
commit20fd93f8e6a747704067cf29603a49e92fcd6a59 (patch)
tree30839af6e8ba95ccd3b3546349a8e12b36608a0b /generic/tclIndexObj.c
parente661b944f8f8f0d7a888c644369a13d5b85509c7 (diff)
downloadtcl-20fd93f8e6a747704067cf29603a49e92fcd6a59.zip
tcl-20fd93f8e6a747704067cf29603a49e92fcd6a59.tar.gz
tcl-20fd93f8e6a747704067cf29603a49e92fcd6a59.tar.bz2
Eliminate 3 calls to Tcl_SetResult, as
examples how it should have been done. purpose: contribute in the TIP #340 discussion. FossilOrigin-Name: 8956424338db83843798b810325dcbd246489b5e
Diffstat (limited to 'generic/tclIndexObj.c')
-rw-r--r--generic/tclIndexObj.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/generic/tclIndexObj.c b/generic/tclIndexObj.c
index f04db71..d0fb382 100644
--- a/generic/tclIndexObj.c
+++ b/generic/tclIndexObj.c
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclIndexObj.c,v 1.46 2008/10/14 22:37:53 nijtmans Exp $
+ * RCS: @(#) $Id: tclIndexObj.c,v 1.47 2008/11/25 23:19:02 nijtmans Exp $
*/
#include "tclInt.h"
@@ -1263,7 +1263,7 @@ Tcl_ParseArgsObjv(
sprintf(buf, "bad argument type %d in Tcl_ArgvInfo",
infoPtr->type);
- Tcl_SetResult(interp, buf, TCL_VOLATILE);
+ Tcl_SetObjResult(interp, Tcl_NewStringObj(buf, -1));
goto error;
}
}