nsf.c

Clone Tools
  • last updated 5 hours ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
nsf.c - removed obsolete function AssertionAppendPrePost() - removed obsolete function NsfNSCopyCmdsCmd() and ::nsf::nscopycmd (handled now more general on scripting level in the "copy" method)

nx.tcl:

- "copy" method: fixed copying of class-level per-object methods

- extended regression tests

  1. … 5 more files in changeset.
nsf.c - fixed a potental crash for objects having a wrapperless alias defined

Merge with remote branch

Make sure that the original error message is preserved when calling destroy after a failed CMD or INITCMD

  1. … 1 more file in changeset.
nsf.c - fixed a bug in "info methods returns" in cases, where no returns info was available. - we can "/obj/ copy" now objects/classes containing * aliases * setter * ensemble methods * method protections Instead of handling cmd copying in NsfNSCopyCmdsCmd, it is replaced now by introspection. - extended regression test

  1. … 5 more files in changeset.
- improved handling of required configure parameters when classes are changed dynamically. When configure parameter are defined required, checking for the absence of required parameter was only performed at creation time. When objects were re-classed or their classes extended with required parameters, later calls to configure did not trigger exceptions. Now we check for the existence of the instance variable which addresses most of these points, but in future we might wish a more general solution (see comment for futures releases)

  1. … 2 more files in changeset.
- when creation with an required configure parameter failed, delete the half-baked object to avoid confusing states.

  1. … 4 more files in changeset.
nx.tcl: - renamed variable option "-config" to "-configurable" to make its intention clearer

  1. … 11 more files in changeset.
nx.tcl: - replaced functionality of "/obj/ configure" by "/obj/ info configure" to re-enable semantics of the plain configure method, even when called without arguments. "/obj/ info configure" is actually a convenience method to allow to write o1 info configure instead of o1 info lookup configure syntax

  1. … 7 more files in changeset.
nsf.c - fixed potential inifinite loop in pattern matching for precedence lists - cget: make error message closer to tcl conventions - extended regression test

  1. … 4 more files in changeset.
- renamed initblock parameter from __initcmd to __initblock - renamed nsf::configure parameter from "keepinitcmds" to "keepcmds" - saving "keepcmds" in an associative array named "__cmd(/parameternName)" to allow saving of multiple parmeters with less nameclash danger (when application stays away from variables stating with double underscore)

  1. … 17 more files in changeset.
- changed enumeration values for "-source" in "info lookup methods" "info lookup slots" "info methods" "info slots" of "all|application|baseclasses" to "all|application|system" for consistencey with "nsf::my" and "nsf::dispatch" which uses "-system" as well

  1. … 4 more files in changeset.
Cleanup of nsfAPI.decls - remove unneeded enumeration types - use "typeName" to shorten reported names of parameters - use camel case for reported names

  1. … 4 more files in changeset.
- changed ::nsf::parametersyntax(..) to ::nsf::parameter::syntax(..) - xotcl2: adjusted manual parameter syntax entries to new conventions

  1. … 6 more files in changeset.
- added implementation for slots with traces+types for classes - exception for incorrect defaults are thrown during slot creation - extended nsf::is, added parameter * ?-configure? -- accept configure paramter options * ?-name /name/? -- provide a parameter name for error message - simplified nx.tcl by using new nsf::is - extended regression test

  1. … 6 more files in changeset.
- added partly implementation for slots with traces+types for classes

  1. … 3 more files in changeset.
- nsf.c: fix crash when "nsf::my" is called with a single argument outside the object context.

  1. … 1 more file in changeset.
- fix assert

- removed some TODOs from tests/parameters.test

- parameter dispositions:

We differentiate now between "initcmd" and "cmd": an "initcmd" is only

evaluated once, but one can provide configure values for this parameter

later. a "cmd" is executed on every evaluation, it is only possible

to pass cmds to it. The trailing argument of the configure parameters

(used e.g. for scripted object/class definitions) is now of type "cmd".

Implementation not yet complete (object cases are not correct).

  1. … 8 more files in changeset.
- C-code Generator: added "-typeName" for enumeration types that allows for disambiguation of enumerations with different argument names. Before that, the argument name determined the c-type of the enumeration. Therefore it was not possible to use argName "-type" for two different functions with a different list of enumerators.

- changed "-methodtype" to simply "-type" in

/obj/ info methods ... ?-type all|scripted|builtin|alias|forwarder|object|setter|nsfproc? ...

/obj/ info object methods ... ?-type all|scripted|builtin|alias|forwarder|object|setter|nsfproc? ...

/obj/ info lookup methods ... ?-type all|scripted|builtin|alias|forwarder|object|setter|nsfproc? ...

  1. … 14 more files in changeset.
- minor code cleanup

  1. … 1 more file in changeset.
- streamlined AddSlotObjects()

- nsf.c: handle full-qualified name for private slots (AddSlotObjects()) - extended regression test

  1. … 2 more files in changeset.
- extended parameter extractor: new functionality ::nsf::parameter get default /parameter/ ?/varname/? ::nsf::parameter get type /parameter/ /obj/ info parameter get default /parameter/ ?/varname/? /obj/ info parameter get type /parameter/

  1. … 6 more files in changeset.
Method and configure parameter reform, Part 3: - added

/cls/ info lookup variables -> list of handles

/obj/ info lookup object variables -> list of handles

/obj/ info variable definition|name|parameter /handle/

- nx.tcl: added forward compatible scripted implementation of "lmap"

- nsf.c: handle names for private slots in pattern provided to AddSlotObjects(),

used e.g. in "info lookup slots /pattern/"

  1. … 7 more files in changeset.
- nx.tcl: handle "incremental" in slot reconfigure - nx.tcl: change defaultAccessor to "none"

  1. … 20 more files in changeset.
- Method and configure parameter reform

/cls/ info configure parameters ?pattern? -> list of params

/cls/ info configure syntax -> syntax output

/obj/ info method parameters /methodName/ ?/pattern/? -> list of params

/obj/ info method syntax -> syntax output

/obj/ info lookup configure parameter ?/pattern/? -> list of params

/obj/ info lookup configure syntax -> syntax output

/cls/ info parameter list|name|syntax /param/ -> value

  1. … 14 more files in changeset.
- avoid crash in case NsfParameterGetCmd() is passed a plain value

- initialize stub-tables only once

- syntax formatter: use /value/ for denoting placeholder in "... info method syntax ..."

  1. … 11 more files in changeset.