Hoogle Search

Within LTS Haskell 24.52 (ghc-9.10.3)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. class DeriveUniverseSome a

    universe-some Data.Universe.Some.TH

    Derive the UniverseSome n instance.

    >>> :set -XGADTs -XTemplateHaskell -XStandaloneDeriving
    
    >>> import Data.Universe.Class (universe)
    
    >>> import Data.GADT.Show
    
    >>> data Tag b a where IntTag :: Tag b Int; BoolTag :: b -> Tag b Bool
    
    >>> deriving instance Show b => Show (Tag b a)
    
    >>> instance Show b => GShow (Tag b) where gshowsPrec = showsPrec
    
    (data Unused is to workaround bug in older GHCi) >>> data Unused; $(deriveUniverseSome ''Tag)
    >>> universe :: [Some (Tag (Maybe Bool))]
    [Some IntTag,Some (BoolTag Nothing),Some (BoolTag (Just False)),Some (BoolTag (Just True))]
    
    deriveUniverseSome variant taking a Name guesses simple class constraints. If you need more specific, you can specify them: (Note: on older GHCs this will warn, as the instance definition doesn't have all methods defined).
    >>> data Tag b a where IntTag :: Tag b Int; BoolTag :: b -> Tag b Bool
    
    >>> deriving instance Show b => Show (Tag b a)
    
    >>> instance Show b => GShow (Tag b) where gshowsPrec = showsPrec
    
    >>> data Unused; $(deriveUniverseSome ([d| instance Universe b => UniverseSome (Tag b) |] :: DecsQ))
    ...
    
    >>> universe :: [Some (Tag (Maybe Bool))]
    [Some IntTag,Some (BoolTag Nothing),Some (BoolTag (Just False)),Some (BoolTag (Just True))]
    

  2. DeriveKeyPairError :: String -> HPKEError

    hpke Crypto.HPKE

    No documentation available.

  3. class Deriver cls

    th-utilities TH.Derive

    Instances of Deriver describe a default way of creating an instance for a particular typeclass. For example, if I wanted to write something that derives Eq instances, I would write a instance Deriver (Eq a).

  4. module Text.Earley.Derived

    Derived operators.

  5. module Data.Aeson.DeriveNoPrefix

    Template Haskell macros to derive ToJSON/FromJSON instances in a more prefix-friendly manner. See https://gitlab.com/igrep/deriveJsonNoPrefix#readme.

  6. data DeriveConfig

    grisette Grisette.Internal.TH.Derivation.Common

    Configuration for deriving instances for a data type.

  7. DeriveConfig :: [(Int, EvalModeConfig)] -> [Int] -> [(Int, Int)] -> [Int] -> Bool -> Bool -> Bool -> Bool -> DeriveConfig

    grisette Grisette.Internal.TH.Derivation.Common

    No documentation available.

  8. module Grisette.Internal.TH.Derivation.DeriveAllSyms

    No documentation available.

  9. module Grisette.Internal.TH.Derivation.DeriveBinary

    No documentation available.

  10. module Grisette.Internal.TH.Derivation.DeriveCereal

    No documentation available.

Page 81 of many | Previous | Next