[][src]Function leo_ast::types::type_::inner_array_type

pub fn inner_array_type(element_type: Type, dimensions: ArrayDimensions) -> Type

Returns the type of the inner array given an array element and array dimensions.

If the array has no dimensions, then an inner array does not exist. Simply return the given element type.

If the array has dimensions, then an inner array exists. Create a new type for the inner array. The element type of the new array should be the same as the old array. The dimensions of the new array should be the old array dimensions with the first dimension removed.