Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data Defns terms types = Defns {}
- type DefnsF f terms types = Defns (f terms) (f types)
- type DefnsF2 f g terms types = Defns (f (g terms)) (f (g types))
- type DefnsF3 f g h terms types = Defns (f (g (h terms))) (f (g (h types)))
- type DefnsF4 f g h i terms types = Defns (f (g (h (i terms)))) (f (g (h (i types))))
- alignDefnsWith :: Semialign f => (These a b -> c) -> Defns (f a) (f b) -> f c
- defnsAreEmpty :: (Foldable f, Foldable g) => Defns (f a) (g b) -> Bool
- fromTerms :: Monoid types => terms -> Defns terms types
- fromTypes :: Monoid terms => types -> Defns terms types
- hoistDefnsF :: (forall x. f x -> g x) -> DefnsF f a b -> DefnsF g a b
- mapDefns :: (a -> b) -> Defns a a -> Defns b b
- unzipDefns :: Defns (tm1, tm2) (ty1, ty2) -> (Defns tm1 ty1, Defns tm2 ty2)
- unzipDefnsWith :: (tm1 -> (tm2, tm3)) -> (ty1 -> (ty2, ty3)) -> Defns tm1 ty1 -> (Defns tm2 ty2, Defns tm3 ty3)
- zipDefns :: Defns tm1 ty1 -> Defns tm2 ty2 -> Defns (tm1, tm2) (ty1, ty2)
- zipDefnsWith :: (tm1 -> tm2 -> tm3) -> (ty1 -> ty2 -> ty3) -> Defns tm1 ty1 -> Defns tm2 ty2 -> Defns tm3 ty3
- zipDefnsWith3 :: (tm1 -> tm2 -> tm3 -> tm4) -> (ty1 -> ty2 -> ty3 -> ty4) -> Defns tm1 ty1 -> Defns tm2 ty2 -> Defns tm3 ty3 -> Defns tm4 ty4
- zipDefnsWith4 :: (tm1 -> tm2 -> tm3 -> tm4 -> tm5) -> (ty1 -> ty2 -> ty3 -> ty4 -> ty5) -> Defns tm1 ty1 -> Defns tm2 ty2 -> Defns tm3 ty3 -> Defns tm4 ty4 -> Defns tm5 ty5
Documentation
data Defns terms types Source #
Definitions (terms and types) in a namespace.
Instances
Bifoldable Defns Source # | |
Bifunctor Defns Source # | |
Bitraversable Defns Source # | |
Defined in Unison.Util.Defns bitraverse :: Applicative f => (a -> f c) -> (b -> f d) -> Defns a b -> f (Defns c d) # | |
Functor (Defns terms) Source # | |
(Monoid terms, Monoid types) => Monoid (Defns terms types) Source # | |
(Semigroup terms, Semigroup types) => Semigroup (Defns terms types) Source # | |
Generic (Defns terms types) Source # | |
(Show terms, Show types) => Show (Defns terms types) Source # | |
type Rep (Defns terms types) Source # | |
Defined in Unison.Util.Defns type Rep (Defns terms types) = D1 ('MetaData "Defns" "Unison.Util.Defns" "unison-core1-0.0.0-6SyLKzwOxrt37WukuFZrYQ" 'False) (C1 ('MetaCons "Defns" 'PrefixI 'True) (S1 ('MetaSel ('Just "terms") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 terms) :*: S1 ('MetaSel ('Just "types") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 types))) |
type DefnsF f terms types = Defns (f terms) (f types) Source #
A common shape of definitions - terms and types are stored in the same structure.
hoistDefnsF :: (forall x. f x -> g x) -> DefnsF f a b -> DefnsF g a b Source #
unzipDefnsWith :: (tm1 -> (tm2, tm3)) -> (ty1 -> (ty2, ty3)) -> Defns tm1 ty1 -> (Defns tm2 ty2, Defns tm3 ty3) Source #
zipDefnsWith :: (tm1 -> tm2 -> tm3) -> (ty1 -> ty2 -> ty3) -> Defns tm1 ty1 -> Defns tm2 ty2 -> Defns tm3 ty3 Source #