I had errors (wrong # of args) while using compiled
code (tclcompiler -> tbcload) which uses procs with
"args" argument.
In generic/tclProc.c line 460 VAR_IS_ARGS is set for
precompiled code but inside the if-statement for the
default-value. I moved this code outside and my
problems went away.
--- tclProc.c 2006-01-23 08:42:05.000000000 +0100
+++ tclProc.c.orig 2006-01-23 08:41:18.000000000 +0100
@@ -457,12 +457,12 @@
ckfree((char *) fieldValues);
goto procError;
}
- }
- if ((i == numArgs - 1)
- && (localPtr->nameLength == 4)
- && (localPtr->name[0] == 'a')
- && (strcmp(localPtr->name, "args") == 0)) {
- localPtr->flags |= VAR_IS_ARGS;
+ if ((i == numArgs - 1)
+ && (localPtr->nameLength == 4)
+ && (localPtr->name[0] == 'a')
+ && (strcmp(localPtr->name,
"args") == 0)) {
+ localPtr->flags |= VAR_IS_ARGS;
+ }
}
localPtr = localPtr->nextPtr;
|