RepLib-0.2.1: Generic programming library with representation typesSource codeContentsIndex
Data.RepLib.R1
Portabilitynon-portable
Stabilityexperimental
Maintainersweirich@cis.upenn.edu
Description
Synopsis
data R1 ctx a where
Int1 :: R1 ctx Int
Char1 :: R1 ctx Char
Integer1 :: R1 ctx Integer
Float1 :: R1 ctx Float
Double1 :: R1 ctx Double
Rational1 :: R1 ctx Rational
IOError1 :: R1 ctx IOError
IO1 :: Rep a => ctx a -> R1 ctx (IO a)
Arrow1 :: (Rep a, Rep b) => ctx a -> ctx b -> R1 ctx (a -> b)
Data1 :: DT -> [Con ctx a] -> R1 ctx a
class Sat a where
dict :: a
class Rep a => Rep1 ctx a where
rep1 :: R1 ctx a
getRep :: Rep b => c b -> R b
toR :: R1 c a -> R a
rTup2_1 :: forall a b ctx. (Rep a, Rep b) => ctx a -> ctx b -> R1 ctx (a, b)
rList1 :: forall a ctx. Rep a => ctx a -> ctx [a] -> R1 ctx [a]
rNil1 :: Con ctx [a]
rCons1 :: Rep a => ctx a -> ctx [a] -> Con ctx [a]
Documentation
data R1 ctx a whereSource
Constructors
Int1 :: R1 ctx Int
Char1 :: R1 ctx Char
Integer1 :: R1 ctx Integer
Float1 :: R1 ctx Float
Double1 :: R1 ctx Double
Rational1 :: R1 ctx Rational
IOError1 :: R1 ctx IOError
IO1 :: Rep a => ctx a -> R1 ctx (IO a)
Arrow1 :: (Rep a, Rep b) => ctx a -> ctx b -> R1 ctx (a -> b)
Data1 :: DT -> [Con ctx a] -> R1 ctx a
show/hide Instances
Show (R1 c a)
class Sat a whereSource
Methods
dict :: aSource
show/hide Instances
Show a => Sat (ShowD a)
Bounded a => Sat (BoundedD a)
Ord a => Sat (OrdD a)
Eq a => Sat (EqD a)
Shrink a => Sat (ShrinkD a)
Enumerate a => Sat (EnumerateD a)
Generate a => Sat (GenerateD a)
Zero a => Sat (ZeroD a)
GSum a => Sat (GSumD a)
Lreduce b a => Sat (LreduceD b a)
Rreduce b a => Sat (RreduceD b a)
(Unify n a b, Subst n a b, Occurs n a b) => Sat (UnifySubD n a b)
class Rep a => Rep1 ctx a whereSource
Methods
rep1 :: R1 ctx aSource
show/hide Instances
Rep1 ctx ()
Rep1 ctx Rational
Rep1 ctx IOError
Rep1 ctx Double
Rep1 ctx Float
Rep1 ctx Integer
Rep1 ctx Char
Rep1 ctx Int
Rep1 ctx[a70m] Bool
Rep1 ctx[a6ZG] Ordering
(Rep a, Sat (ctx a), Sat (ctx ([] a))) => Rep1 ctx ([] a)
(Rep a, Sat (ctx a)) => Rep1 ctx (IO a)
(Rep a[a1ko], Sat (ctx[a70c] a[a1ko])) => Rep1 ctx[a70c] (Maybe a[a1ko])
(Rep a, Sat (ctx a), Rep b, Sat (ctx b)) => Rep1 ctx ((,) a b)
(Rep a, Rep b, Sat (ctx a), Sat (ctx b)) => Rep1 ctx (a -> b)
(Rep a[a6ZO], Rep b[a6ZN], Sat (ctx[a6ZX] a[a6ZO]), Sat (ctx[a6ZX] b[a6ZN])) => Rep1 ctx[a6ZX] (Either a[a6ZO] b[a6ZN])
(Rep a[12], Rep b[13], Rep c[14], Sat (ctx[a6Zo] a[12]), Sat (ctx[a6Zo] b[13]), Sat (ctx[a6Zo] c[14])) => Rep1 ctx[a6Zo] ((,,) a[12] b[13] c[14])
(Rep a[12], Rep b[13], Rep c[14], Rep d[15], Sat (ctx[a6Z1] a[12]), Sat (ctx[a6Z1] b[13]), Sat (ctx[a6Z1] c[14]), Sat (ctx[a6Z1] d[15])) => Rep1 ctx[a6Z1] ((,,,) a[12] b[13] c[14] d[15])
(Rep a[12], Rep b[13], Rep c[14], Rep d[15], Rep e[16], Sat (ctx[a6Yz] a[12]), Sat (ctx[a6Yz] b[13]), Sat (ctx[a6Yz] c[14]), Sat (ctx[a6Yz] d[15]), Sat (ctx[a6Yz] e[16])) => Rep1 ctx[a6Yz] ((,,,,) a[12] b[13] c[14] d[15] e[16])
(Rep a[12], Rep b[13], Rep c[14], Rep d[15], Rep e[16], Rep f[17], Sat (ctx[a6Y2] a[12]), Sat (ctx[a6Y2] b[13]), Sat (ctx[a6Y2] c[14]), Sat (ctx[a6Y2] d[15]), Sat (ctx[a6Y2] e[16]), Sat (ctx[a6Y2] f[17])) => Rep1 ctx[a6Y2] ((,,,,,) a[12] b[13] c[14] d[15] e[16] f[17])
(Rep a[12], Rep b[13], Rep c[14], Rep d[15], Rep e[16], Rep f[17], Rep g[18], Sat (ctx[a6Xq] a[12]), Sat (ctx[a6Xq] b[13]), Sat (ctx[a6Xq] c[14]), Sat (ctx[a6Xq] d[15]), Sat (ctx[a6Xq] e[16]), Sat (ctx[a6Xq] f[17]), Sat (ctx[a6Xq] g[18])) => Rep1 ctx[a6Xq] ((,,,,,,) a[12] b[13] c[14] d[15] e[16] f[17] g[18])
getRep :: Rep b => c b -> R bSource
Access a representation, given a proxy
toR :: R1 c a -> R aSource
Transform a parameterized rep to a vanilla rep
rTup2_1 :: forall a b ctx. (Rep a, Rep b) => ctx a -> ctx b -> R1 ctx (a, b)Source
rList1 :: forall a ctx. Rep a => ctx a -> ctx [a] -> R1 ctx [a]Source
rNil1 :: Con ctx [a]Source
rCons1 :: Rep a => ctx a -> ctx [a] -> Con ctx [a]Source
Produced by Haddock version 2.4.2