A module for virtual vectors. Many of the functions defined here are imitations of Haskell's list operations, and to a first approximation they behave accordingly.
A virtual vector is normally guaranteed not to be present in the generated code. The only exceptions are:
- when it is explicitly forced using the functions
- when it is the input or output of a program
- when it is accessed by a function outside the Feldspar.Vector API, for
Note also that most operations only introduce a small constant overhead on the vector. The exceptions are
These functions introduce overhead that is linear in the length of the vector.