Module ketos::name [] [src]

Implements name interning and containers using names as keys.

Modules

standard_names

Contains constants standard name values; interned names which are universal to all programs.

Structs

Name

Represents a name interned within a NameStore.

NameDebugger

Displays a NameDebug value using standard formatting.

NameDisplayer

Displays a NameDisplay value using standard formatting.

NameInputConversion

Converts module-local names loaded from bytecode files into global names in a running interpreter.

NameIter

Iterator over names stored in a NameStore.

NameMap

Maps names to values in a sorted Vec

NameMapSlice

Maps names to values in a sorted boxed slice.

NameOutputConversion

Converts global names in a running interpreter into module-local names, retaining string representations, which can be written to a bytecode file.

NameSet

Represents a set of names

NameSetSlice

Represents a set of names.

NameStore

Maps interned Name values to their String representations

SetIter

Iterates over names in a NameSet or NameSetSlice.

Constants

NUM_STANDARD_NAMES

Number of standard names

NUM_STANDARD_VALUES

Number of names, starting at 0, which refer to standard values.

NUM_SYSTEM_FNS

Number of names, starting at 0, which refer to system functions.

NUM_SYSTEM_OPERATORS

Number of system operators, beginning at SYSTEM_OPERATORS_BEGIN.

SYSTEM_OPERATORS_BEGIN

First standard name which refers to a system operator.

SYSTEM_OPERATORS_END

One-past-the-end of standard names which refer to system operators.

Traits

NameDebug

Represents a value which can produce debugging output and may contain one or more interned Name values.

NameDisplay

Represents a value which can produce user-facing output and may contain one or more interned Name values.

Functions

debug_names

Returns a NameDebugger wrapper around a value.

display_names

Returns a NameDisplayer wrapper around a value.

get_standard_name

Returns the standard name for the given integer value, if it exists.

get_standard_name_for

Returns the standard name for the given string representation, if one exists.

get_system_fn

Returns the system function for the given name, if one exists.

is_standard_name

Returns whether the given name is a standard name.

is_standard_value

Returns whether a standard value corresponds to the given name.

is_system_fn

Returns whether the given name corresponds to a system function.

is_system_operator

Returns whether the given name corresponds to a system operator.

standard_name

Returns the string representation of the given name, if it is a standard name.