nsf.c

Clone Tools
  • last updated 9 hours ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
* nsf.c (ParamOptionParse, ParamDefinitionParse, ParamDefsParse), parameters.test: Small "type=" converterArg reform. Provided additional parameter in param-parser machinery, to communicate a (namespace) qualifier into ParamOptionParse. This way, the unqualified type=* values are now expanded to qualified names (definition scope): method parameters, nsf::is, nsf::parseargs, setter methods. Type=* in object parameters are currently expanded at the slot level, could also be added. New tests were added, existing ones adjusted to reflect the new behaviour.

  1. … 2 more files in changeset.
- new command "tnsf::definitionnamespace" - experiment with command in regression test

  1. … 3 more files in changeset.
fix typo in comment

- implement substdefaultoptions (for now, just providing the bitmask) - add substdefault.test - rename static function ParamParse() to ParamDefinitionParse() - break overlong lines

  1. … 4 more files in changeset.
Silence gcc8

Use snprintf() instead of sprintf() to protect better against potential buffer overflows

  1. … 8 more files in changeset.
Remove old-style CompiledColonLocalsLookup and use colonLocalVarCache variant instead.

Improve portability (restict length of literal strings <= 4095)

Adress literal limitaton in ISO C99, that requires compilers to support

only strings up to 4095 bytes. As a consequence, we have to split

the compiled-in literal commands into two parts.

  1. … 7 more files in changeset.
prefer boolean test, remove commented-out code

* nsf.c (ParamParse): Fix crash when ParamParse is called with an empty-string argument, e.g. nsf::parameter::info type "". Tests provided.

  1. … 1 more file in changeset.
* nsf.c (NsfParseArgsCmd): Fix another edge case (empty spec and/or empty argv), added more tests. See also TODO.

  1. … 1 more file in changeset.
* nsf.c (NsfParseArgsCmd): Fix nsf::parseargs for the case of Tcl-only params, otherwise, it crashes due to an uninitialized params structure. Added some tests.

  1. … 1 more file in changeset.
* nsf.c (ParamDefsParse): Fix small typo "allowedOptinons" -> "allowedOptions"

* nsfDebug.c (NsfInitPkgConfig): Provide NSF configuration data via the TIP 59 interface (::nsf::pkgconfig).

  1. … 5 more files in changeset.
Remove unneeded function

Don't allow bytearrays as name of non-pos args

We try to address the problem, that the argument parser might add string reps to Tcl_Objs

without string reps. This is in particular nasty for pure byte arrays in Tcl 8.6, which

are defined as having no string. We do not want to change purtiy just by passing

such values in arguments,

  1. … 1 more file in changeset.
Adjust print format to recent changes

nsf.c, nsfInt.h, nsfObj.c: Make epoch counters unsigned ints, so doubling the number of possible epochs.

  1. … 2 more files in changeset.
* nsf.c: Unify cmd flags cast (unsigned long -> unsigned int)

* nsf.c (ObjectCmdMethodDispatch): Simplify and cleanup condition expressions.

nsf.c (ObjectCmdMethodDispatch), submethods.test: Enable private checking on ensembles, added test cases to capture the intented behaviour behind -local and/or private for ensemble methods.

  1. … 1 more file in changeset.
move GetObj() after tests of non-null asserts

Cleanup: Don't shadow variable names.

Merge branch 'master' of ssh://alice.wu-wien.ac.at/usr/local/src/git-repo/nsf

* nsf.c (NsfMethodForwardCmd): Provide correct scoping condition when requesting a method handle for a submethod forwarder. Added basic tests.

  1. … 1 more file in changeset.
Merge branch 'master' of ssh://alice.wu-wien.ac.at/usr/local/src/git-repo/nsf

* nsf.c, nsfStack.c: Bump copyright years.

  1. … 1 more file in changeset.
* nsf.c (ObjectCmdMethodDispatch), protected.test: For ensemble (submethod) dispatches, since ever, call protection had not been enforced at all. This commit enables call protection (protected) for ensembles and adds basic tests. * nsfStack.c (GetSelfObj): To allow one to resolve the self reference at arbitrary callstack levels, separate GetSelfObj into GetSelfObj (macro) for the topmost self and GetSelfObj2.

  1. … 2 more files in changeset.
Merge branch 'master' of ssh://alice.wu-wien.ac.at/usr/local/src/git-repo/nsf

fix typo