Expand description
Collection (sequence/array) DynamicTypes that retain a fully
resolved element DynamicType.
The public TypeDescriptor keeps only a shallow element descriptor
(element_type: Box<TypeDescriptor>) — enough for scalar elements, but it
drops the members of a composite element (sequence<Struct> etc.), which
the reflective codec needs to recurse. Rather than widen the core type model
(and the TypeObject bridge that builds on it), this module constructs the
collection DynamicType with the resolved element kept as its single
synthetic member (index 0). resolved_element reads it back; the codec
prefers it and falls back to rebuilding a scalar element from the descriptor
when absent (so collections built the plain way still decode).
Functions§
- array_
of - Build an
Element[dims...]array type that retains the fully-resolvedelementtype. - resolved_
element - The resolved element
DynamicTypeof a collection, if one was attached viasequence_of/array_of. ReturnsNonefor collections that carry only a shallow scalar element descriptor (the codec rebuilds those itself). - sequence_
of - Build a
sequence<Element>type (bound0= unbounded) that retains the fully-resolvedelementtype for the reflective codec.