method-require.test

Clone Tools
  • last updated 17 hours ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
- test.tcl: * don't export Test per-default * define Test as nx::Test * make Test parameter count 1 the default, change to higher numbers where needed

  1. … 15 more files in changeset.
- nsf.c: made potentially unknown clientData more safe (error message, when something is passed via clientData to a method expecting an object/class as clientData). - renamed NsfNoDispatchObjectError() to NsfDispatchClientDataError(), extended interface - Makefile.in: fixed name methods.test

  1. … 8 more files in changeset.
* Hopefully the last big naming change: Instead of writing "C class-object method foo {} {...}" one can write now "C class method foo {} {...}" to define a class method named "foo" for class "C". This naming change became possible by defining XOTcl's "class" (and "superclass") as object parameter only. To change a class of an object o, one has to use "o configure -class NEWCLASS". The term "object-class" looks alien to language beginners, the term "class" is much more straightforward. Changing classes or superclasses is seldomly used by typicall application programs.

For already existing nx scripts, changing "object-class" into

class should be straightforward.

* various documentation updates (migration guide, nx tutorial)

  1. … 22 more files in changeset.
- nx: * removed methods ::nx::Class.alloc and ::nx::Class.dealloc from predefined method-set

* added defintions such that these methods can be loaded via

::nsf::method::require ::nx::Class alloc

::nsf::method::require ::nx::Class dealloc

* make explicit that "method ... require" returns a method-handle

* removed misleading reference in error message, when a class-spefic

method was called on an object; solution is somewhat dangerous for

potentially unknwon client data

* added regression tests

  1. … 9 more files in changeset.
- changed named of method handling commands in nsf: ::nsf::provide_method => ::nsf::method::provide ::nsf::require_method => ::nsf::method::require

  1. … 6 more files in changeset.
- changed named of method handling commands in nsf: ::nsf::methodproperty => ::nsf::method::property ::nsf::method => ::nsf::method::create ::nsf::methoddelete => ::nsf::method::delete ::nsf::alias => ::nsf::method::alias ::nsf::forward => ::nsf::method::forward ::nsf::setter => ::nsf::method::setter (updated regression test, docs, ...)

  1. … 24 more files in changeset.
- Make sure that DispatchDestroyMethod() calls as well protected destructors - New function NSCheckNamespace() as replacement for NSCheckForParent() - pass parentNsPtr around instead of recomputing it in NSCheckForParent() - removed unneeded argument from NSGetFreshNamespace() - switched to dstring operations in NameInNamespaceObj() (seems slightly faster) - factored out NSRequireParentObject() - by the measures above, we obtained some speed improvements - moved some more debug output to be controlled by the debuglevel - extended regression test with testcases for creation of parent objects via method "__unknown"

  1. … 3 more files in changeset.
- fixed langauge hooks for emacs

  1. … 12 more files in changeset.
- renamed nx regression tests .test to follow tcl conventions

    • -0
    • +59
    ./method-require.test
  1. … 35 more files in changeset.