The standard library dynamic_rw_vector package implements vectors which spontaneously expand as needed to contain requested slots.
The dynamic_rw_vector package implements an anonymous api.
The dynamic_rw_vector api source code is in src/lib/src/dynamic-rw-vector.pkg.
See also: expanding_rw_vector in src/lib/src/expanding-rw-vector.pkg.
The above information is manually maintained and may contain errors.
api { Rw_Vector X = ...; Vector X = Vector(X ); maximum_vector_length : Int; make_rw_vector : (Int , X) -> Rw_Vector(X ); from_list : List(X ) -> Rw_Vector(X ); from_fn : (Int , (Int -> X)) -> Rw_Vector(X ); length : Rw_Vector(X ) -> Int; get : (Rw_Vector(X ) , Int) -> X; _[] : (Rw_Vector(X ) , Int) -> X; set : (Rw_Vector(X ) , Int , X) -> Void; _[]:= : (Rw_Vector(X ) , Int , X) -> Void; to_vector : Rw_Vector(X ) -> Vector(X ); copy : {at:Int, from:Rw_Vector(X ), into:Rw_Vector(X )} -> Void; copy_vector : {at:Int, from:Vector(X ), into:Rw_Vector(X )} -> Void; apply : (X -> Void) -> Rw_Vector(X ) -> Void; keyed_apply : ((Int , X) -> Void) -> Rw_Vector(X ) -> Void; map_in_place : (X -> X) -> Rw_Vector(X ) -> Void; keyed_map_in_place : ((Int , X) -> X) -> Rw_Vector(X ) -> Void; fold_forward : ((X , Y) -> Y) -> Y -> Rw_Vector(X ) -> Y; fold_backward : ((X , Y) -> Y) -> Y -> Rw_Vector(X ) -> Y; keyed_fold_forward : ((Int , X , Y) -> Y) -> Y -> Rw_Vector(X ) -> Y; keyed_fold_backward : ((Int , X , Y) -> Y) -> Y -> Rw_Vector(X ) -> Y; find : (X -> Bool) -> Rw_Vector(X ) -> Null_Or(X ); keyed_find : ((Int , X) -> Bool) -> Rw_Vector(X ) -> Null_Or(((Int , X)) ); exists : (X -> Bool) -> Rw_Vector(X ) -> Bool; all : (X -> Bool) -> Rw_Vector(X ) -> Bool; compare_sequences : ((X , X) -> Order) -> (Rw_Vector(X ) , Rw_Vector(X )) -> Order; from_array : (rw_vector::Rw_Vector(X ) , X , Int) -> Rw_Vector(X ); base_array : Rw_Vector(X ) -> rw_vector::Rw_Vector(X ); check_array : (Rw_Vector(X ) , rw_vector::Rw_Vector(X )) -> Void; clear : (Rw_Vector(X ) , Int) -> Void; expand_to : (Rw_Vector(X ) , Int) -> Void;};