diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2016-12-20 09:46:14 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2016-12-20 09:46:14 (GMT) |
commit | 47957139fb510e8cb49eea9050f6107756ac83d7 (patch) | |
tree | 2206551d9434c9ab017193f88a6445c8a57c23a8 /generic/tclCompile.c | |
parent | b258cc76aba7c7cb1906d863944bb4cd6ea5d1a4 (diff) | |
download | tcl-47957139fb510e8cb49eea9050f6107756ac83d7.zip tcl-47957139fb510e8cb49eea9050f6107756ac83d7.tar.gz tcl-47957139fb510e8cb49eea9050f6107756ac83d7.tar.bz2 |
more internal use of size_t in stead of int.
Diffstat (limited to 'generic/tclCompile.c')
-rw-r--r-- | generic/tclCompile.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/generic/tclCompile.c b/generic/tclCompile.c index c0724ee..7e6a5af 100644 --- a/generic/tclCompile.c +++ b/generic/tclCompile.c @@ -765,7 +765,8 @@ TclSetByteCodeFromAny( Interp *iPtr = (Interp *) interp; CompileEnv compEnv; /* Compilation environment structure allocated * in frame. */ - int length, result = TCL_OK; + size_t length; + int result = TCL_OK; const char *stringPtr; Proc *procPtr = iPtr->compiledProcPtr; ContLineLoc *clLocPtr; @@ -780,7 +781,8 @@ TclSetByteCodeFromAny( } #endif - stringPtr = TclGetStringFromObj(objPtr, &length); + stringPtr = TclGetString(objPtr); + length = objPtr->length; /* * TIP #280: Pick up the CmdFrame in which the BC compiler was invoked and @@ -2976,7 +2978,8 @@ TclFindCompiledLocal( varNamePtr = &cachePtr->varName0; for (i=0; i < cachePtr->numVars; varNamePtr++, i++) { if (*varNamePtr) { - localName = TclGetStringFromObj(*varNamePtr, &len); + localName = TclGetString(*varNamePtr); + len = (*varNamePtr)->length; if ((len == nameBytes) && !strncmp(name, localName, len)) { return i; } |