Safe Haskell | None |
---|
- type family PRepr a
- class PR (PRepr a) => PA a where
- toPRepr :: a -> PRepr a
- fromPRepr :: PRepr a -> a
- toArrPRepr :: PData a -> PData (PRepr a)
- fromArrPRepr :: PData (PRepr a) -> PData a
- toArrPReprs :: PDatas a -> PDatas (PRepr a)
- fromArrPReprs :: PDatas (PRepr a) -> PDatas a
- toNestedArrPRepr :: PA a => PData (PArray a) -> PData (PArray (PRepr a))
- validPA :: PA a => PData a -> Bool
- nfPA :: PA a => PData a -> ()
- similarPA :: PA a => a -> a -> Bool
- coversPA :: PA a => Bool -> PData a -> Int -> Bool
- pprpPA :: PA a => a -> Doc
- pprpDataPA :: PA a => PData a -> Doc
- typeRepPA :: PA a => a -> TypeRep
- typeRepDataPA :: PA a => PData a -> TypeRep
- typeRepDatasPA :: PA a => PDatas a -> TypeRep
- emptyPA :: PA a => PData a
- replicatePA :: PA a => Int -> a -> PData a
- replicatesPA :: PA a => Segd -> PData a -> PData a
- appendPA :: PA a => PData a -> PData a -> PData a
- appendsPA :: PA a => Segd -> VSegd -> PDatas a -> VSegd -> PDatas a -> PData a
- lengthPA :: PA a => PData a -> Int
- indexPA :: PA a => PData a -> Int -> a
- indexsPA :: PA a => PDatas a -> Array (Int, Int) -> PData a
- indexvsPA :: PA a => PDatas a -> VSegd -> Array (Int, Int) -> PData a
- bpermutePA :: PA a => PData a -> Array Int -> PData a
- extractPA :: PA a => PData a -> Int -> Int -> PData a
- extractssPA :: PA a => PDatas a -> SSegd -> PData a
- extractvsPA :: PA a => PDatas a -> VSegd -> PData a
- packByTagPA :: PA a => PData a -> Array Tag -> Tag -> PData a
- combine2PA :: PA a => Sel2 -> PData a -> PData a -> PData a
- fromVectorPA :: PA a => Vector a -> PData a
- toVectorPA :: PA a => PData a -> Vector a
- emptydPA :: PA a => PDatas a
- singletondPA :: PA a => PData a -> PDatas a
- lengthdPA :: PA a => PDatas a -> Int
- indexdPA :: PA a => PDatas a -> Int -> PData a
- appenddPA :: PA a => PDatas a -> PDatas a -> PDatas a
- fromVectordPA :: PA a => Vector (PData a) -> PDatas a
- toVectordPA :: PA a => PDatas a -> Vector (PData a)
- mkPNestedPA :: PA a => VSegd -> PDatas a -> Segd -> PData a -> PData (PArray a)
- concatPA :: PA a => PData (PArray a) -> PData a
- concatlPA :: PA a => PData (PArray (PArray a)) -> PData (PArray a)
- unconcatPA :: (PA a, PA b) => PData (PArray a) -> PData b -> PData (PArray b)
- appendlPA :: PA a => PData (PArray a) -> PData (PArray a) -> PData (PArray a)
- indexlPA :: PA a => PData (PArray a) -> PData Int -> PData a
- slicelPA :: PA a => PData Int -> PData Int -> PData (PArray a) -> PData (PArray a)
- unpackPA :: PA a => PArray a -> PData (PRepr a)
- type family PRepr a
- ziplPA :: (PA a, PA b) => PData (PArray a) -> PData (PArray b) -> PData (PArray (a, b))
Documentation
Family of Representable types. These are the types that we know how to
represent generically. PRepr
takes an arbitrary type and produces the
generic type we use to represent it.
Instances for simple types are defined by the library. For algebraic types, it's up to the vectoriser/client module to create a suitable instance.
class PR (PRepr a) => PA a whereSource
A PA dictionary contains the functions that we use to convert a representable type to and from its generic representation.
The conversions methods should all be O(1).
fromPRepr :: PRepr a -> aSource
toArrPRepr :: PData a -> PData (PRepr a)Source
fromArrPRepr :: PData (PRepr a) -> PData aSource
toArrPReprs :: PDatas a -> PDatas (PRepr a)Source
fromArrPReprs :: PDatas (PRepr a) -> PDatas aSource
PA Bool | |
PA Double | |
PA Int | |
PA Integer | |
PA Ordering | |
PA Word8 | |
PA () | |
PA Void | |
(PR (PRepr (PArray a)), PA a) => PA (PArray a) | |
(PR (PRepr (Either a b)), PR a, PR b) => PA (Either a b) | |
(PR (PRepr (a, b)), PA a, PA b) => PA (a, b) | |
(PR (PRepr (:-> a b)), PA a, PA b) => PA (:-> a b) | |
(PR (PRepr (a, b, c)), PA a, PA b, PA c) => PA (a, b, c) | |
(PR (PRepr (a, b, c, d)), PA a, PA b, PA c, PA d) => PA (a, b, c, d) | |
(PR (PRepr (a, b, c, d, e)), PA a, PA b, PA c, PA d, PA e) => PA (a, b, c, d, e) | |
(PR (PRepr (a, b, c, d, e, f)), PA a, PA b, PA c, PA d, PA e, PA f) => PA (a, b, c, d, e, f) | |
(PR (PRepr (a, b, c, d, e, f, g)), PA a, PA b, PA c, PA d, PA e, PA f, PA g) => PA (a, b, c, d, e, f, g) |
toNestedArrPRepr :: PA a => PData (PArray a) -> PData (PArray (PRepr a))Source
Convert a nested array to its generic representation.
House Keeping
pprpDataPA :: PA a => PData a -> DocSource
typeRepDataPA :: PA a => PData a -> TypeRepSource
typeRepDatasPA :: PA a => PDatas a -> TypeRepSource
Constructors
replicatePA :: PA a => Int -> a -> PData aSource
Projections
Pack and Combine
Conversions
fromVectorPA :: PA a => Vector a -> PData aSource
toVectorPA :: PA a => PData a -> Vector aSource
PDatas
singletondPA :: PA a => PData a -> PDatas aSource
Nested Arrays
mkPNestedPA :: PA a => VSegd -> PDatas a -> Segd -> PData a -> PData (PArray a)Source
Conatruct a nested array.
Tuple Arrays
Family of Representable types. These are the types that we know how to
represent generically. PRepr
takes an arbitrary type and produces the
generic type we use to represent it.
Instances for simple types are defined by the library. For algebraic types, it's up to the vectoriser/client module to create a suitable instance.