Index: generic/nsf.c =================================================================== diff -u -rd76911cc976778b999b80c4540e79c72bb01c75c -re603015e6a5c3e138080ccea8b7c4c9c8e868bef --- generic/nsf.c (.../nsf.c) (revision d76911cc976778b999b80c4540e79c72bb01c75c) +++ generic/nsf.c (.../nsf.c) (revision e603015e6a5c3e138080ccea8b7c4c9c8e868bef) @@ -12007,7 +12007,7 @@ static int ParamParse(Tcl_Interp *interp, Tcl_Obj *procNameObj, Tcl_Obj *arg, int disallowedFlags, Nsf_Param *paramPtr, int *possibleUnknowns, int *plainParams, int *nrNonposArgs) { - int result, npac, isNonposArgument; + int result, npac, isNonposArgument, parensCount; size_t length, j; CONST char *argString, *argName; Tcl_Obj **npav; @@ -12044,9 +12044,23 @@ /*fprintf(stderr, "... parsing '%s', name '%s' argString '%s' \n", ObjStr(arg), argName, argString);*/ - /* find the first ':' */ + /* + * Find the first ':' outside of parens; the name of the parameter might be + * in array syntax, the array index might contain ":", "," etc. + */ + parensCount = 0; for (j=0; j 0 && argString[j] == ')') { + parensCount --; + continue; + } + if (argString[j] == '(') { + parensCount ++; + continue; + } + if (parensCount == 0 && argString[j] == ':') { + break; + } } if (argString[j] == ':') { @@ -23285,6 +23299,17 @@ } /* +objectInfoMethod name NsfObjInfoNameMethod { +} +*/ +static int +NsfObjInfoNameMethod(Tcl_Interp *interp, NsfObject *object) { + + Tcl_SetObjResult(interp, Tcl_NewStringObj(Tcl_GetCommandName(interp, object->id), -1)); + return TCL_OK; +} + +/* objectInfoMethod parent NsfObjInfoParentMethod { } */