Namespace type
Example
ns { F f(x) x * 2; }
Direct parent types
- Hash
Hash type. Maps unique keys to their values. Key-Value pairs are stored and iterated in insertion order. Currently Hash type has several limitations: Hash keys are hashed using internal hash() function which can not be overwritten. The internal hash() multimethod exposed to NGS code but adding methods to it or setting "hash" to some other function will not affect operation of Hashes. Hash values are compared using internal is_equal() function which can not be overwritten. Both hash() and is_equal() currently handle only Int, Str and arbitrary objects. Comparison of arbitrary objects is done by comparing their addresses in memory. Direct subtypes: 1
Constructors
- Namespace()
Creates empty Namespace Returns
Namespace
Methods
- .=(t:Type, field:Str, ns:Namespace) Source: stdlib.ngs:2292
Undocumented Automatically called by NGS for syntax
SUBTYPE_OF_NAMEDINSTANCES.NamedInstances = ...