@[inline_if_reduce]
Auxiliary definition for List.toArray
.
List.toArrayAux as r = r ++ as.toArray
Equations
Instances For
@[match_pattern, inline, export lean_list_to_array]
Converts a List α
into an Array α
by repeatedly pushing elements from the list onto an empty
array. O(|xs|)
.
Use List.toArray
instead of calling this function directly. At runtime, this operation implements
both List.toArray
and Array.mk
.