pub fn flatten_compose<'arenas>(
    ty: Handle<Type>,
    components: &'arenas [Handle<Expression>],
    expressions: &'arenas Arena<Expression>,
    types: &'arenas UniqueArena<Type>
) -> impl Iterator<Item = Handle<Expression>> + 'arenas
Available on crate feature wgpu only.
Expand description

Return an iterator over the individual components assembled by a Compose expression.

Given ty and components from an Expression::Compose, return an iterator over the components of the resulting value.

Normally, this would just be an iterator over components. However, Compose expressions can concatenate vectors, in which case the i’th value being composed is not generally the i’th element of components. This function consults ty to decide if this concatenation is occuring, and returns an iterator that produces the components of the result of the Compose expression in either case.