Index: TODO =================================================================== diff -u -r3cbf24ff95e38976cdc905ec0e8014d9d754ad6f -r0a38046eb4aac6c36ac7c72dc8b0fe6da43f7c6e --- TODO (.../TODO) (revision 3cbf24ff95e38976cdc905ec0e8014d9d754ad6f) +++ TODO (.../TODO) (revision 0a38046eb4aac6c36ac7c72dc8b0fe6da43f7c6e) @@ -5114,7 +5114,12 @@ of nx::VariableSlot) - renamed nsf::relation to nsf::relation::set and added nsf::relation::get in accordance with nsf::var::get +- fixed unary argument passing notation for "-nocomplain" + of nsf::var and for 42 other options of other commands +nx.tcl: +- added flag -nocomplain to "/obj/ /prop/ unset ?-nocomplain?" + ======================================================================== TODO: - TODO: rename "slotassign" to "slotset"? Index: generic/nsfAPI.decls =================================================================== diff -u -r3cbf24ff95e38976cdc905ec0e8014d9d754ad6f -r0a38046eb4aac6c36ac7c72dc8b0fe6da43f7c6e --- generic/nsfAPI.decls (.../nsfAPI.decls) (revision 3cbf24ff95e38976cdc905ec0e8014d9d754ad6f) +++ generic/nsfAPI.decls (.../nsfAPI.decls) (revision 0a38046eb4aac6c36ac7c72dc8b0fe6da43f7c6e) @@ -52,22 +52,22 @@ } cmd "dispatch" NsfDispatchCmd { {-argName "object" -required 1 -type object} - {-argName "-intrinsic" -required 0 -nrargs 0} - {-argName "-system" -required 0 -nrargs 0} + {-argName "-intrinsic" -required 0 -nrargs 0 -type switch} + {-argName "-system" -required 0 -nrargs 0 -type switch} {-argName "command" -required 1 -type tclobj} {-argName "args" -type args} } {-nxdoc 1} cmd finalize NsfFinalizeCmd { - {-argName "-keepvars" -required 0 -nrargs 0} + {-argName "-keepvars" -required 0 -nrargs 0 -type switch} } {-nxdoc 1} cmd interp NsfInterpObjCmd { {-argName "name" -required 1} {-argName "args" -type allargs} } {-nxdoc 1} cmd is NsfIsCmd { - {-argName "-complain" -nrargs 0} - {-argName "-configure" -nrargs 0} + {-argName "-complain" -nrargs 0 -type switch} + {-argName "-configure" -nrargs 0 -type switch} {-argName "-name" -required 0} {-argName "constraint" -required 1 -type tclobj} {-argName "value" -required 1 -type tclobj} @@ -89,8 +89,8 @@ } cmd parameter::specs NsfParameterSpecsCmd { - {-argName "-configure" -nrargs 0 -required 0} - {-argName "-nonposargs" -nrargs 0 -required 0} + {-argName "-configure" -nrargs 0 -required 0 -type switch} + {-argName "-nonposargs" -nrargs 0 -required 0 -type switch} {-argName "slotobjs" -required 1 -type tclobj} } @@ -114,7 +114,7 @@ cmd "method::create" NsfMethodCreateCmd { {-argName "object" -required 1 -type object} {-argName "-checkalways" -required 0 -nrargs 0 -type switch} - {-argName "-inner-namespace" -nrargs 0} + {-argName "-inner-namespace" -nrargs 0 -type switch} {-argName "-per-object" -required 0 -nrargs 0 -type switch} {-argName "-reg-object" -required 0 -type object} {-argName "methodName" -required 1 -type tclobj} @@ -127,7 +127,7 @@ cmd "method::asmcreate" NsfAsmMethodCreateCmd { {-argName "object" -required 1 -type object} {-argName "-checkalways" -required 0 -nrargs 0 -type switch} - {-argName "-inner-namespace" -nrargs 0} + {-argName "-inner-namespace" -nrargs 0 -type switch} {-argName "-per-object" -required 0 -nrargs 0 -type switch} {-argName "-reg-object" -required 0 -nrargs 1 -type object} {-argName "name" -required 1 -type tclobj} @@ -145,11 +145,11 @@ {-argName "-per-object" -required 0 -nrargs 0 -type switch} {-argName "method" -required 1 -type tclobj} {-argName "-default" -type tclobj} - {-argName "-earlybinding" -nrargs 0} + {-argName "-earlybinding" -nrargs 0 -type switch} {-argName "-onerror" -type tclobj} {-argName "-prefix" -type tclobj} {-argName "-frame" -nrargs 1 -type "object|method|default" -default default} - {-argName "-verbose" -nrargs 0} + {-argName "-verbose" -nrargs 0 -type switch} {-argName "target" -type tclobj} {-argName "args" -type args} } {-nxdoc 1} @@ -199,9 +199,9 @@ } {-nxdoc 1} cmd my NsfMyCmd { - {-argName "-intrinsic" -nrargs 0} - {-argName "-local" -nrargs 0} - {-argName "-system" -nrargs 0} + {-argName "-intrinsic" -nrargs 0 -type switch} + {-argName "-local" -nrargs 0 -type switch} + {-argName "-system" -nrargs 0 -type switch} {-argName "methodName" -required 1 -type tclobj} {-argName "args" -type args} } {-nxdoc 1} @@ -243,12 +243,12 @@ # var cmds # cmd "var::exists" NsfVarExistsCmd { - {-argName "-array" -required 0 -nrargs 0} + {-argName "-array" -required 0 -nrargs 0 -type switch} {-argName "object" -required 1 -type object} {-argName "varName" -required 1} } {-nxdoc 1} cmd "var::get" NsfVarGetCmd { - {-argName "-array" -required 0 -nrargs 0} + {-argName "-array" -required 0 -nrargs 0 -type switch} {-argName "object" -required 1 -type object} {-argName "varName" -required 1 -type tclobj} } {-nxdoc 1} @@ -258,13 +258,13 @@ {-argName "args" -type args} } {-nxdoc 1} cmd "var::set" NsfVarSetCmd { - {-argName "-array" -required 0 -nrargs 0} + {-argName "-array" -required 0 -nrargs 0 -type switch} {-argName "object" -required 1 -type object} {-argName "varName" -required 1 -type tclobj} {-argName "value" -required 0 -type tclobj} } {-nxdoc 1} cmd "var::unset" NsfVarUnsetCmd { - {-argName "-nocomplain" -required 0 -nrargs 0} + {-argName "-nocomplain" -required 0 -nrargs 0 -type switch} {-argName "object" -required 1 -type object} {-argName "varName" -required 1 -type tclobj} } {-nxdoc 1} @@ -273,8 +273,8 @@ # object methods # objectMethod autoname NsfOAutonameMethod { - {-argName "-instance" -nrargs 0} - {-argName "-reset" -nrargs 0} + {-argName "-instance" -nrargs 0 -type switch} + {-argName "-reset" -nrargs 0 -type switch} {-argName "name" -required 1 -type tclobj} } @@ -392,12 +392,12 @@ {-argName "filter" -required 1} } objectInfoMethod filtermethods NsfObjInfoFiltermethodsMethod { - {-argName "-guards" -nrargs 0} - {-argName "-order" -nrargs 0} + {-argName "-guards" -nrargs 0 -type switch} + {-argName "-order" -nrargs 0 -type switch} {-argName "pattern"} } objectInfoMethod forward NsfObjInfoForwardMethod { - {-argName "-definition" -nrargs 0} + {-argName "-definition" -nrargs 0 -type switch} {-argName "name"} } objectInfoMethod hasmixin NsfObjInfoHasMixinMethod { @@ -419,10 +419,10 @@ } objectInfoMethod lookupmethods NsfObjInfoLookupMethodsMethod { {-argName "-callprotection" -type "all|public|protected|private" -default all} - {-argName "-incontext" -nrargs 0} + {-argName "-incontext" -nrargs 0 -type switch} {-argName "-type" -typeName "methodtype" -type "all|scripted|builtin|alias|forwarder|object|setter|nsfproc"} - {-argName "-nomixins" -nrargs 0} - {-argName "-path" -nrargs 0} + {-argName "-nomixins" -nrargs 0 -type switch} + {-argName "-path" -nrargs 0 -type switch} {-argName "-source" -type "all|application|system" -default all} {-argName "pattern" -required 0} } @@ -438,13 +438,13 @@ objectInfoMethod methods NsfObjInfoMethodsMethod { {-argName "-callprotection" -type "all|public|protected|private" -default all} {-argName "-type" -typeName "methodtype" -type "all|scripted|builtin|alias|forwarder|object|setter|nsfproc"} - {-argName "-path" -nrargs 0} + {-argName "-path" -nrargs 0 -type switch} {-argName "pattern" -required 0} } objectInfoMethod mixinclasses NsfObjInfoMixinclassesMethod { - {-argName "-guards" -nrargs 0} - {-argName "-heritage" -nrargs 0} + {-argName "-guards" -nrargs 0 -type switch} + {-argName "-heritage" -nrargs 0 -type switch} {-argName "pattern" -type objpattern} } objectInfoMethod mixinguard NsfObjInfoMixinguardMethod { @@ -459,7 +459,7 @@ {-argName "pattern" -required 0} } objectInfoMethod precedence NsfObjInfoPrecedenceMethod { - {-argName "-intrinsic" -nrargs 0} + {-argName "-intrinsic" -nrargs 0 -type switch} {-argName "pattern" -required 0} } objectInfoMethod slotobjects NsfObjInfoSlotobjectsMethod { @@ -477,18 +477,18 @@ {-argName "filter" -required 1} } classInfoMethod filtermethods NsfClassInfoFiltermethodsMethod { - {-argName "-guards" -nrargs 0} + {-argName "-guards" -nrargs 0 -type switch} {-argName "pattern"} } classInfoMethod forward NsfClassInfoForwardMethod { - {-argName "-definition" -nrargs 0} + {-argName "-definition" -nrargs 0 -type switch} {-argName "name"} } classInfoMethod heritage NsfClassInfoHeritageMethod { {-argName "pattern"} } classInfoMethod instances NsfClassInfoInstancesMethod { - {-argName "-closure" -nrargs 0} + {-argName "-closure" -nrargs 0 -type switch} {-argName "pattern" -type objpattern} } @@ -498,38 +498,38 @@ } classInfoMethod methods NsfClassInfoMethodsMethod { {-argName "-callprotection" -type "all|public|protected|private" -default all} - {-argName "-closure" -nrargs 0} + {-argName "-closure" -nrargs 0 -type switch} {-argName "-type" -nrargs 1 -typeName "methodtype" -type "all|scripted|builtin|alias|forwarder|object|setter|nsfproc"} - {-argName "-path" -nrargs 0} + {-argName "-path" -nrargs 0 -type switch} {-argName "-source" -nrargs 1 -type "all|application|system" -default all} {-argName "pattern"} } classInfoMethod mixinclasses NsfClassInfoMixinclassesMethod { - {-argName "-closure" -nrargs 0} - {-argName "-guards" -nrargs 0} - {-argName "-heritage" -nrargs 0} + {-argName "-closure" -nrargs 0 -type switch} + {-argName "-guards" -nrargs 0 -type switch} + {-argName "-heritage" -nrargs 0 -type switch} {-argName "pattern" -type objpattern} } classInfoMethod mixinguard NsfClassInfoMixinguardMethod { {-argName "mixin" -required 1} } classInfoMethod mixinof NsfClassInfoMixinOfMethod { - {-argName "-closure" -nrargs 0} + {-argName "-closure" -nrargs 0 -type switch} {-argName "-scope" -required 0 -type "all|class|object"} {-argName "pattern" -type objpattern} } classInfoMethod slotobjects NsfClassInfoSlotobjectsMethod { - {-argName "-closure" -nrargs 0} + {-argName "-closure" -nrargs 0 -type switch} {-argName "-source" -type "all|application|system" -default all} {-argName "-type" -required 0 -type class} {-argName "pattern" -required 0} } classInfoMethod subclass NsfClassInfoSubclassMethod { - {-argName "-closure" -nrargs 0} + {-argName "-closure" -nrargs 0 -type switch} {-argName "pattern" -type objpattern} } classInfoMethod superclass NsfClassInfoSuperclassMethod { - {-argName "-closure" -nrargs 0} + {-argName "-closure" -nrargs 0 -type switch} {-argName "pattern" -type tclobj} } Index: generic/nsfAPI.h =================================================================== diff -u -r3cbf24ff95e38976cdc905ec0e8014d9d754ad6f -r0a38046eb4aac6c36ac7c72dc8b0fe6da43f7c6e --- generic/nsfAPI.h (.../nsfAPI.h) (revision 3cbf24ff95e38976cdc905ec0e8014d9d754ad6f) +++ generic/nsfAPI.h (.../nsfAPI.h) (revision 0a38046eb4aac6c36ac7c72dc8b0fe6da43f7c6e) @@ -3144,18 +3144,18 @@ {"filter", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::class::info::filtermethods", NsfClassInfoFiltermethodsMethodStub, 2, { - {"-guards", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-guards", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"pattern", 0, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::class::info::forward", NsfClassInfoForwardMethodStub, 2, { - {"-definition", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-definition", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"name", 0, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::class::info::heritage", NsfClassInfoHeritageMethodStub, 1, { {"pattern", 0, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::class::info::instances", NsfClassInfoInstancesMethodStub, 2, { - {"-closure", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-closure", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"pattern", 0, 1, ConvertToObjpattern, NULL,NULL,"objpattern",NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::class::info::method", NsfClassInfoMethodMethodStub, 2, { @@ -3164,44 +3164,44 @@ }, {"::nsf::methods::class::info::methods", NsfClassInfoMethodsMethodStub, 6, { {"-callprotection", 0|NSF_ARG_IS_ENUMERATION, 1, ConvertToCallprotection, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-closure", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-closure", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"-type", 0|NSF_ARG_IS_ENUMERATION, 1, ConvertToMethodtype, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-path", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-path", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"-source", 0|NSF_ARG_IS_ENUMERATION, 1, ConvertToSource, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"pattern", 0, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::class::info::mixinof", NsfClassInfoMixinOfMethodStub, 3, { - {"-closure", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-closure", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"-scope", 0|NSF_ARG_IS_ENUMERATION, 1, ConvertToScope, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"pattern", 0, 1, ConvertToObjpattern, NULL,NULL,"objpattern",NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::class::info::mixinclasses", NsfClassInfoMixinclassesMethodStub, 4, { - {"-closure", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-guards", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-heritage", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-closure", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, + {"-guards", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, + {"-heritage", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"pattern", 0, 1, ConvertToObjpattern, NULL,NULL,"objpattern",NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::class::info::mixinguard", NsfClassInfoMixinguardMethodStub, 1, { {"mixin", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::class::info::slotobjects", NsfClassInfoSlotobjectsMethodStub, 4, { - {"-closure", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-closure", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"-source", 0|NSF_ARG_IS_ENUMERATION, 1, ConvertToSource, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"-type", 0, 1, Nsf_ConvertTo_Class, NULL,NULL,"class",NULL,NULL,NULL,NULL,NULL}, {"pattern", 0, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::class::info::subclass", NsfClassInfoSubclassMethodStub, 2, { - {"-closure", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-closure", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"pattern", 0, 1, ConvertToObjpattern, NULL,NULL,"objpattern",NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::class::info::superclass", NsfClassInfoSuperclassMethodStub, 2, { - {"-closure", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-closure", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"pattern", 0, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::method::asmcreate", NsfAsmMethodCreateCmdStub, 8, { {"object", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Object, NULL,NULL,"object",NULL,NULL,NULL,NULL,NULL}, {"-checkalways", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, - {"-inner-namespace", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-inner-namespace", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"-per-object", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"-reg-object", 0, 1, Nsf_ConvertTo_Object, NULL,NULL,"object",NULL,NULL,NULL,NULL,NULL}, {"name", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, @@ -3242,21 +3242,21 @@ }, {"::nsf::dispatch", NsfDispatchCmdStub, 5, { {"object", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Object, NULL,NULL,"object",NULL,NULL,NULL,NULL,NULL}, - {"-intrinsic", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-system", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-intrinsic", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, + {"-system", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"command", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"args", 0, 1, ConvertToNothing, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::finalize", NsfFinalizeCmdStub, 1, { - {"-keepvars", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} + {"-keepvars", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::interp", NsfInterpObjCmdStub, 2, { {"name", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"args", 0, 1, ConvertToNothing, NULL,NULL,"allargs",NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::is", NsfIsCmdStub, 5, { - {"-complain", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-configure", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-complain", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, + {"-configure", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"-name", 0, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"constraint", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"value", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} @@ -3276,7 +3276,7 @@ {"::nsf::method::create", NsfMethodCreateCmdStub, 10, { {"object", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Object, NULL,NULL,"object",NULL,NULL,NULL,NULL,NULL}, {"-checkalways", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, - {"-inner-namespace", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-inner-namespace", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"-per-object", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"-reg-object", 0, 1, Nsf_ConvertTo_Object, NULL,NULL,"object",NULL,NULL,NULL,NULL,NULL}, {"methodName", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, @@ -3295,11 +3295,11 @@ {"-per-object", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"method", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"-default", 0, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-earlybinding", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-earlybinding", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"-onerror", 0, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"-prefix", 0, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"-frame", 0|NSF_ARG_IS_ENUMERATION, 1, ConvertToFrame, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-verbose", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-verbose", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"target", 0, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"args", 0, 1, ConvertToNothing, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, @@ -3319,9 +3319,9 @@ {"parameter", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::my", NsfMyCmdStub, 5, { - {"-intrinsic", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-local", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-system", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-intrinsic", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, + {"-local", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, + {"-system", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"methodName", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"args", 0, 1, ConvertToNothing, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, @@ -3365,8 +3365,8 @@ {"object", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Object, NULL,NULL,"object",NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::parameter::specs", NsfParameterSpecsCmdStub, 3, { - {"-configure", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-nonposargs", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-configure", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, + {"-nonposargs", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"slotobjs", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::proc", NsfProcCmdStub, 5, { @@ -3401,12 +3401,12 @@ {NULL, 0, 0, NULL, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::var::exists", NsfVarExistsCmdStub, 3, { - {"-array", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-array", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"object", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Object, NULL,NULL,"object",NULL,NULL,NULL,NULL,NULL}, {"varName", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::var::get", NsfVarGetCmdStub, 3, { - {"-array", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-array", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"object", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Object, NULL,NULL,"object",NULL,NULL,NULL,NULL,NULL}, {"varName", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, @@ -3415,19 +3415,19 @@ {"args", 0, 1, ConvertToNothing, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::var::set", NsfVarSetCmdStub, 4, { - {"-array", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-array", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"object", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Object, NULL,NULL,"object",NULL,NULL,NULL,NULL,NULL}, {"varName", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"value", 0, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::var::unset", NsfVarUnsetCmdStub, 3, { - {"-nocomplain", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-nocomplain", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"object", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Object, NULL,NULL,"object",NULL,NULL,NULL,NULL,NULL}, {"varName", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::object::autoname", NsfOAutonameMethodStub, 3, { - {"-instance", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-reset", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-instance", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, + {"-reset", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"name", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_Tclobj, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::object::cget", NsfOCgetMethodStub, 1, { @@ -3488,12 +3488,12 @@ {"filter", NSF_ARG_REQUIRED, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::object::info::filtermethods", NsfObjInfoFiltermethodsMethodStub, 3, { - {"-guards", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-order", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-guards", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, + {"-order", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"pattern", 0, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::object::info::forward", NsfObjInfoForwardMethodStub, 2, { - {"-definition", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-definition", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"name", 0, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::object::info::hasmixin", NsfObjInfoHasMixinMethodStub, 1, { @@ -3516,10 +3516,10 @@ }, {"::nsf::methods::object::info::lookupmethods", NsfObjInfoLookupMethodsMethodStub, 7, { {"-callprotection", 0|NSF_ARG_IS_ENUMERATION, 1, ConvertToCallprotection, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-incontext", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-incontext", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"-type", 0|NSF_ARG_IS_ENUMERATION, 1, ConvertToMethodtype, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-nomixins", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-path", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-nomixins", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, + {"-path", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"-source", 0|NSF_ARG_IS_ENUMERATION, 1, ConvertToSource, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"pattern", 0, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, @@ -3535,12 +3535,12 @@ {"::nsf::methods::object::info::methods", NsfObjInfoMethodsMethodStub, 4, { {"-callprotection", 0|NSF_ARG_IS_ENUMERATION, 1, ConvertToCallprotection, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, {"-type", 0|NSF_ARG_IS_ENUMERATION, 1, ConvertToMethodtype, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-path", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-path", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"pattern", 0, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::object::info::mixinclasses", NsfObjInfoMixinclassesMethodStub, 3, { - {"-guards", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, - {"-heritage", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-guards", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, + {"-heritage", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"pattern", 0, 1, ConvertToObjpattern, NULL,NULL,"objpattern",NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::object::info::mixinguard", NsfObjInfoMixinguardMethodStub, 1, { @@ -3557,7 +3557,7 @@ {NULL, 0, 0, NULL, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::object::info::precedence", NsfObjInfoPrecedenceMethodStub, 2, { - {"-intrinsic", 0, 0, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}, + {"-intrinsic", 0, 0, Nsf_ConvertTo_Boolean, NULL,NULL,"switch",NULL,NULL,NULL,NULL,NULL}, {"pattern", 0, 1, Nsf_ConvertTo_String, NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}} }, {"::nsf::methods::object::info::slotobjects", NsfObjInfoSlotobjectsMethodStub, 2, { Index: library/nx/nx.tcl =================================================================== diff -u -r3cbf24ff95e38976cdc905ec0e8014d9d754ad6f -r0a38046eb4aac6c36ac7c72dc8b0fe6da43f7c6e --- library/nx/nx.tcl (.../nx.tcl) (revision 3cbf24ff95e38976cdc905ec0e8014d9d754ad6f) +++ library/nx/nx.tcl (.../nx.tcl) (revision 0a38046eb4aac6c36ac7c72dc8b0fe6da43f7c6e) @@ -2043,9 +2043,8 @@ ::nsf::method::alias ::nx::VariableSlot value=get ::nsf::var::get ::nsf::method::alias ::nx::VariableSlot value=set ::nsf::var::set - ::nx::VariableSlot public method value=unset {obj prop} { - puts stderr "::nsf::var::unset $obj $prop" - ::nsf::var::unset $obj $prop + ::nx::VariableSlot public method value=unset {obj prop -nocomplain:switch} { + ::nsf::var::unset -nocomplain=$nocomplain $obj $prop } ::nx::VariableSlot public method value=add {obj prop value {pos 0}} { Index: tests/accessor.test =================================================================== diff -u -r6ad766595b0095a72fb7b3a1d6d34960a013b464 -r0a38046eb4aac6c36ac7c72dc8b0fe6da43f7c6e --- tests/accessor.test (.../accessor.test) (revision 6ad766595b0095a72fb7b3a1d6d34960a013b464) +++ tests/accessor.test (.../accessor.test) (revision 0a38046eb4aac6c36ac7c72dc8b0fe6da43f7c6e) @@ -41,6 +41,11 @@ ? {c1 p2a set 2} 2 ? {c1 p2a unset} "" ? {c1 cget -p2a} {can't read "p2a": no such variable} +puts stderr ====1 + ? {c1 p2a unset} {can't unset "p2a": no such variable} +puts stderr ====2 + ? {c1 p2a unset -nocomplain} "" +puts stderr ====3 puts [C info method definition p2b] ? {c1 cget -p2b} 3