summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--generic/tclDisassemble.c4
-rw-r--r--generic/tclExecute.c2
-rw-r--r--generic/tclInt.h4
-rw-r--r--generic/tclProc.c6
4 files changed, 8 insertions, 8 deletions
diff --git a/generic/tclDisassemble.c b/generic/tclDisassemble.c
index ff12770..f0dd908 100644
--- a/generic/tclDisassemble.c
+++ b/generic/tclDisassemble.c
@@ -321,7 +321,7 @@ DisassembleByteCodeObj(
int numCompiledLocals = procPtr->numCompiledLocals;
Tcl_AppendPrintfToObj(bufferObj,
- " Proc %p, refCt %" TCL_Z_MODIFIER "u, args %d, compiled locals %d\n",
+ " Proc %p, refCt %" TCL_Z_MODIFIER "u, args %" TCL_Z_MODIFIER "u, compiled locals %d\n",
procPtr, procPtr->refCount, procPtr->numArgs,
numCompiledLocals);
if (numCompiledLocals > 0) {
@@ -542,7 +542,7 @@ FormatInstruction(
unsigned char *codeStart = codePtr->codeStart;
unsigned pcOffset = pc - codeStart;
int opnd = 0, i, j, numBytes = 1;
- int localCt = procPtr ? procPtr->numCompiledLocals : 0;
+ int localCt = procPtr ? (int)procPtr->numCompiledLocals : 0;
CompiledLocal *localPtr = procPtr ? procPtr->firstLocalPtr : NULL;
char suffixBuffer[128]; /* Additional info to print after main opcode
* and immediates. */
diff --git a/generic/tclExecute.c b/generic/tclExecute.c
index 9fbf803..2db63da 100644
--- a/generic/tclExecute.c
+++ b/generic/tclExecute.c
@@ -8703,7 +8703,7 @@ PrintByteCodeInfo(
#endif /* TCL_COMPILE_STATS */
if (procPtr != NULL) {
fprintf(stdout,
- " Proc 0x%p, refCt %" TCL_Z_MODIFIER "u, args %d, compiled locals %d\n",
+ " Proc 0x%p, refCt %" TCL_Z_MODIFIER "u, args %" TCL_Z_MODIFIER "u, compiled locals %" TCL_Z_MODIFIER "u\n",
procPtr, procPtr->refCount, procPtr->numArgs,
procPtr->numCompiledLocals);
}
diff --git a/generic/tclInt.h b/generic/tclInt.h
index 54d9ef9..29e5009 100644
--- a/generic/tclInt.h
+++ b/generic/tclInt.h
@@ -983,8 +983,8 @@ typedef struct Proc {
* procedure. */
Tcl_Obj *bodyPtr; /* Points to the ByteCode object for
* procedure's body command. */
- int numArgs; /* Number of formal parameters. */
- int numCompiledLocals; /* Count of local variables recognized by the
+ size_t numArgs; /* Number of formal parameters. */
+ size_t numCompiledLocals; /* Count of local variables recognized by the
* compiler including arguments and
* temporaries. */
CompiledLocal *firstLocalPtr;
diff --git a/generic/tclProc.c b/generic/tclProc.c
index 37821d2..7940cb1 100644
--- a/generic/tclProc.c
+++ b/generic/tclProc.c
@@ -490,10 +490,10 @@ TclCreateProc(
}
if (precompiled) {
- if (numArgs > (size_t)procPtr->numArgs) {
+ if (numArgs > procPtr->numArgs) {
Tcl_SetObjResult(interp, Tcl_ObjPrintf(
"procedure \"%s\": arg list contains %" TCL_Z_MODIFIER "u entries, "
- "precompiled header expects %d", procName, numArgs,
+ "precompiled header expects %" TCL_Z_MODIFIER "u", procName, numArgs,
procPtr->numArgs));
Tcl_SetErrorCode(interp, "TCL", "OPERATION", "PROC",
"BYTECODELIES", NULL);
@@ -1946,7 +1946,7 @@ TclProcCompileProc(
iPtr->compiledProcPtr = procPtr;
- if (procPtr->numCompiledLocals > procPtr->numArgs) {
+ if ((int)procPtr->numCompiledLocals > (int)procPtr->numArgs) {
CompiledLocal *clPtr = procPtr->firstLocalPtr;
CompiledLocal *lastPtr = NULL;
int i, numArgs = procPtr->numArgs;