tclAPI.h

Clone Tools
  • last updated 16 hours ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
- gentclAPI.tcl: * renamed "nsfCmd" to simply "cmd", since the code can generate arbitrary tcl commands * allow type "int" in the .decls files - nsf.c * move several functions from "static" to "external" to make the code generator usable for submodules as well

  1. … 7 more files in changeset.
* added methods ::nsf::methods::object::class and ::nsf::methods::class::superclass in order to make faster and nicer looking objectparameters (compared with forwarders) * nx: changed parameter -class to use ::nsf::methods::object::class * ns: fixed chicken egg problem of method objectparameter needing objectparameter by creating/destroying slot Class::slot::dummy; otherwise default values for slots would not be available * reduced verbosity of parameter forwarder

  1. … 6 more files in changeset.
* provided a fast path implementation for "defaultmethod" * provided default system methods for "init", "defaultmethod" and "unknown" * provided handles for system methods "alloc", "dealloc", "recreate", and "defaultmethod" * strip in dispatch invocations of "unknown" potental leading colons * removed c-level implementation of init again, since scripted one can be used now as well in registration of createobjectsystem * reduced verbosity * added defintions such that these methods can be loaded via ::nsf::method::require ::nx::Object unknown

  1. … 6 more files in changeset.
* added C-implemented method "init" for orthogonality * allow specification of system method handles in nsf::createobjectsystem * automatically register alias, when system-method handle was provided and a same-named method is defined

  1. … 5 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 names of var handling commands in nsf: ::nsf::existsvar => ::nsf::var::exists ::nsf::importvar => ::nsf::var::import ::nsf::setvar => ::nsf::var::set

  1. … 12 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.
- fixed potential crash with -param:switch - added "... info method exists ...."

  1. … 6 more files in changeset.
DTrace: * added "nsf::configure dtrace on|off" for skipping package initialization (to be handled in D script) * make compliation clean

  1. … 7 more files in changeset.
- cleanup and documentation of nsf-specific interp state - nsf::configure: added an option "profile on|off" (per default off)

  1. … 5 more files in changeset.
- The fix of yesterdays subst reference counting bug triggered an other problem: If the last arg was "args", the flags array for checking the need for decr of refcounts was not extended. There are multiple possible fixes, i have just extended the flags array for now as well. - When profiling is activated, perform now a more sane shutdown order, all hash tables are now correctly freed. - Improve behavior, when object system creation fails - Drop function NsfProfilePrint()

  1. … 5 more files in changeset.
- nx.tcl: provide caching for computed values of object slots to make method objectparameter nearly twice as fast; direct changes on slots require a reconfigure call. - nsf.c: removed SUBST from shadow commands (does not appear to be necessary any more) - nsf.c: fixing a memory leak (some substituted values were not freed correctly) - nsf.c: fix potential crash for epoched cmds - some minor updates for profiling support

  1. … 8 more files in changeset.
- removed c-implementation of method vwait, it was replaced by "vwait :varName". We had to allow flag TCL_GLOBAL_ONLY in InterpColonVarResolver(), since Tcl vwait implementation calls it with that flag. - added a scripted implementation for vwait in xotcl2

  1. … 8 more files in changeset.
- provide full list of initializers

  1. … 1 more file in changeset.
- furter c cleanup

  1. … 2 more files in changeset.
- removed leftover -public flag in nsf::method - general cleanup: removed unused arguments

  1. … 7 more files in changeset.
- added flag "-ad" to ::nsf::proc for obtaining the semantics of ad_proc in OpenACS (boolean with no arguments, append "_p" to variable names) - added "... info method definition ..." for nsfprocs - new function DStringAppendQualName() to append qualified name to a DString - removed obsolete function NSCmdFullName()

  1. … 3 more files in changeset.
- added methodtype "nsfproc" to "... info methods ...", to be used with namespace qualified names - return "nsfproc" as methodtype for nsfprocs - refactored InvokeShadowedProc() - some minor code cleanup and improved documentation

  1. … 5 more files in changeset.
- added experimental ::nsf::proc for realization of procs with next scripting argument passing. These nsf::procs improve the orthogonality of the code (using e.g. nonpos args and value checker for procs) and allows the same introspection interface (info method parameter|parametersyntax, ...)

  1. … 6 more files in changeset.
- some minor renaming

  1. … 1 more file in changeset.
- defined nsf::deprecated as tcl proc, using ::nsf::log - some minor refactoring

  1. … 5 more files in changeset.
- added missing required

  1. … 1 more file in changeset.
- generic/gentclAPI.decls: Set the ::nsf::setter parameter as required, otherwise ::nsf::setter crashes upon omitting the parameter/setter name. - library/lib/doc-tools.tcl: Reduced verbosity

  1. … 2 more files in changeset.
- streamlined error messages - removed NsfErrBadVal() and replaced it with a generalized version of NsfObjErrType(

  1. … 7 more files in changeset.
- made error messages more consistent - improved error messages for "returns" and "nsf::is" (omit parameter name)

  1. … 11 more files in changeset.
- changed relation handling by evaluating the relationcmd in the parent context to keep evaluation order. - extend introspection "nsf::configure objectsystem": the command returns now all system methods in the syntax of nsf::createobjectsystem - "nsf::createobjectsystem" creates now a warning when an existing objectsystem is redefined and ignores the new definition attempt. This was done with the purpose to allow "package forget nx; package require nx" - Allow overwriting of redefine protected method during bootstrap to ease "package forget nx; package require nx" - forward had just "-objscope", no general "-frame method|object". Since forwarder have client data, they always push a method frame. So, the situation is different to nsd::alias and ::nsf::dispatch. Therefore, the flag "-objscope" was renamed to "-objectframe" to provide better consistency with "-frame object" - fixed bug, where error handling of invalid options in ForwardProcessOptions() could lead to a crash - return forwardoption "-earlybinding" via instrospection - extended regression test

  1. … 14 more files in changeset.
- gentclApi.tcl: added optimizer rule for single argument of type tclobj - improved speed of CompiledLocalsLookup slightly

  1. … 3 more files in changeset.
- added a few more small optimization. - code-generator: don't call argument parser, when no arguments are specified

  1. … 6 more files in changeset.
- removed bug-alert from nx.tcl (wrong false-positives for compiled locals in slots) - added a few small optimization. nsf appears to run on the shootout benchmark the same speed like a year ago (which much less functionality)

  1. … 5 more files in changeset.
- implemented exported command ::nsf::self as fast conveniance replacement for "::nsf::current object".

  1. … 8 more files in changeset.