store-0.7.6: Fast binary serialization

Safe Haskell | None
Language | Haskell2010

Data.Store.TH.Internal

Contents

- TH functions for generating Store instances
- Misc utilties used in Store test
- Orphan instances

Synopsis

- deriveManyStoreFromStorable :: (Type -> Bool) -> Q [Dec]
- deriveTupleStoreInstance :: Int -> Dec
- deriveGenericInstance :: Cxt -> Type -> Dec
- deriveManyStorePrimVector :: Q [Dec]
- deriveManyStoreUnboxVector :: Q [Dec]
- deriveStore :: Cxt -> Type -> [DataCon] -> Q Dec
- makeStore :: Name -> Q [Dec]
- getAllInstanceTypes1 :: Name -> Q [Type]
- isMonoType :: Type -> Bool

# TH functions for generating Store instances

deriveManyStoreFromStorable :: (Type -> Bool) -> Q [Dec] Source #

deriveTupleStoreInstance :: Int -> Dec Source #

deriveGenericInstance :: Cxt -> Type -> Dec Source #

deriveManyStorePrimVector :: Q [Dec] Source #

deriveManyStoreUnboxVector :: Q [Dec] Source #

deriveStore :: Cxt -> Type -> [DataCon] -> Q Dec Source #

makeStore :: Name -> Q [Dec] Source #

Given the name of a type, generate a Store instance for it, assuming that all type variables also need to be Store instances.

Note that when used with datatypes that require type variables, the ScopedTypeVariables extension is required.

# Misc utilties used in Store test

getAllInstanceTypes1 :: Name -> Q [Type] Source #

isMonoType :: Type -> Bool Source #

# Orphan instances

Deriver (Store a) Source # |
Instance details Methods runDeriver :: Proxy (Store a) -> Cxt -> Type -> Q [Dec] Source #