Module static_array

Source
Expand description

An extension for working with static arrays.

The extension collections.static_arrays models globally available constant arrays of TypeBound::Copyable values.

The type static_array<T> is parameterised by its element type. Note that unlike collections.array.array the length of a static array is not tracked in type args.

The CustomConst StaticArrayValue is the only manner by which a value of static_array type can be obtained.

Operations provided:

  • get<T: Copyable>: [static_array<T>, prelude.usize] -> [[] + [T]]
  • len<T: Copyable>: [static_array<T>] -> [prelude.usize]

Structs§

EXTENSION
Extension for array operations.
StaticArrayOp
Concrete array operation.
StaticArrayOpDefIter
An iterator over the variants of StaticArrayOpDef
StaticArrayValue
Statically sized array of values, all of the same TypeBound::Copyable type.

Enums§

StaticArrayOpDef

Constants§

EXTENSION_ID
Reported unique name of the extension
STATIC_ARRAY_TYPENAME
Reported unique name of the array type.
VERSION
Extension version.

Traits§

StaticArrayOpBuilder
A trait for building static array operations in a dataflow graph.

Functions§

static_array_custom_type
Instantiate a new static_array CustomType given an element type.
static_array_type
Instantiate a new static_array Type given an element type.