singletons-2.4.1: A framework for generating singleton types

Copyright(C) 2014 Jan Stolarek Richard Eisenberg
LicenseBSD-style (see LICENSE)
MaintainerJan Stolarek (jan.stolarek@p.lodz.pl)
Stabilityexperimental
Portabilitynon-portable
Safe HaskellNone
LanguageHaskell2010

Data.Promotion.Prelude.Show

Contents

Description

Exports a promoted version of Show

Synopsis

Documentation

class PShow (a :: Type) #

Associated Types

type ShowsPrec (arg :: Nat) (arg :: a) (arg :: Symbol) :: Symbol #

type Show_ (arg :: a) :: Symbol #

type ShowList (arg :: [a]) (arg :: Symbol) :: Symbol #

Instances
PShow Bool # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow Ordering # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow Nat #

Note that this instance is really, really slow, since it uses an inefficient, inductive definition of division behind the hood.

Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow Symbol # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow () # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow Void # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow [a] # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow (Maybe a) # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow (NonEmpty a) # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow (Either a b) # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow (a, b) # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow (a, b, c) # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow (a, b, c, d) # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow (a, b, c, d, e) # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow (a, b, c, d, e, f) # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

PShow (a, b, c, d, e, f, g) # 
Instance details

Defined in Data.Singletons.Prelude.Show

Associated Types

type ShowsPrec arg arg arg :: Symbol #

type Show_ arg :: Symbol #

type ShowList arg arg :: Symbol #

type SymbolS = Symbol -> Symbol #

The shows functions return a function that prepends the output Symbol to an existing Symbol. This allows constant-time concatenation of results using function composition.

type SChar = Symbol #

GHC currently has no notion of type-level Chars, so we fake them with single-character Symbols.

show_ :: Show a => a -> String #

show, but with an extra underscore so that its promoted counterpart (Show_) will not clash with the Show class.

type (<>) a b = AppendSymbol a b infixr 6 #

The promoted analogue of '(<>)' for Symbols. This uses the special AppendSymbol type family from GHC.TypeLits.

type family Shows (a :: a) (a :: Symbol) :: Symbol where ... #

Equations

Shows s a_6989586621679696530 = Apply (Apply (Apply ShowsPrecSym0 (FromInteger 0)) s) a_6989586621679696530 

type family ShowListWith (a :: TyFun a (TyFun Symbol Symbol -> Type) -> Type) (a :: [a]) (a :: Symbol) :: Symbol where ... #

Equations

ShowListWith _ '[] s = Apply (Apply (<>@#@$) "[]") s 
ShowListWith showx ((:) x xs) s = Apply (Apply (<>@#@$) "[") (Apply (Apply showx x) (Apply (Let6989586621679696492ShowlSym4 showx x xs s) xs)) 

type family ShowChar (a :: Symbol) (a :: Symbol) :: Symbol where ... #

Equations

ShowChar a_6989586621679696397 a_6989586621679696399 = Apply (Apply (<>@#@$) a_6989586621679696397) a_6989586621679696399 

type family ShowString (a :: Symbol) (a :: Symbol) :: Symbol where ... #

Equations

ShowString a_6989586621679696375 a_6989586621679696377 = Apply (Apply (<>@#@$) a_6989586621679696375) a_6989586621679696377 

type family ShowParen (a :: Bool) (a :: TyFun Symbol Symbol -> Type) (a :: Symbol) :: Symbol where ... #

Equations

ShowParen b p a_6989586621679696427 = Apply (Case_6989586621679696432 b p a_6989586621679696427 b) a_6989586621679696427 

type family ShowSpace (a :: Symbol) :: Symbol where ... #

Equations

ShowSpace a_6989586621679696357 = Apply (Apply Lambda_6989586621679696364Sym0 a_6989586621679696357) a_6989586621679696357 

type family ShowCommaSpace (a :: Symbol) :: Symbol where ... #

Equations

ShowCommaSpace a_6989586621679696390 = Apply (Apply ShowStringSym0 ", ") a_6989586621679696390 

type family AppPrec :: Nat where ... #

Equations

AppPrec = FromInteger 10 

type family AppPrec1 :: Nat where ... #

Equations

AppPrec1 = FromInteger 11 

Defunctionalization symbols

data ShowsPrecSym0 (l :: TyFun Nat (TyFun a6989586621679694510 (TyFun Symbol Symbol -> Type) -> Type)) #

Instances
SuppressUnusedWarnings (ShowsPrecSym0 :: TyFun Nat (TyFun a6989586621679694510 (TyFun Symbol Symbol -> Type) -> Type) -> *) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowsPrecSym0 :: TyFun Nat (TyFun a6989586621679694510 (TyFun Symbol Symbol -> Type) -> Type) -> *) (l :: Nat) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowsPrecSym0 :: TyFun Nat (TyFun a6989586621679694510 (TyFun Symbol Symbol -> Type) -> Type) -> *) (l :: Nat) = (ShowsPrecSym1 l :: TyFun a6989586621679694510 (TyFun Symbol Symbol -> Type) -> *)

data ShowsPrecSym1 (l :: Nat) (l :: TyFun a6989586621679694510 (TyFun Symbol Symbol -> Type)) #

Instances
SuppressUnusedWarnings (ShowsPrecSym1 :: Nat -> TyFun a6989586621679694510 (TyFun Symbol Symbol -> Type) -> *) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowsPrecSym1 l1 :: TyFun a6989586621679694510 (TyFun Symbol Symbol -> Type) -> *) (l2 :: a6989586621679694510) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowsPrecSym1 l1 :: TyFun a6989586621679694510 (TyFun Symbol Symbol -> Type) -> *) (l2 :: a6989586621679694510) = ShowsPrecSym2 l1 l2

data ShowsPrecSym2 (l :: Nat) (l :: a6989586621679694510) (l :: TyFun Symbol Symbol) #

Instances
SuppressUnusedWarnings (ShowsPrecSym2 :: Nat -> a6989586621679694510 -> TyFun Symbol Symbol -> *) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowsPrecSym2 l1 l2 :: TyFun Symbol Symbol -> *) (l3 :: Symbol) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowsPrecSym2 l1 l2 :: TyFun Symbol Symbol -> *) (l3 :: Symbol) = ShowsPrec l1 l2 l3

type ShowsPrecSym3 (t :: Nat) (t :: a6989586621679694510) (t :: Symbol) = ShowsPrec t t t #

data Show_Sym0 (l :: TyFun a6989586621679694510 Symbol) #

Instances
SuppressUnusedWarnings (Show_Sym0 :: TyFun a6989586621679694510 Symbol -> *) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (Show_Sym0 :: TyFun a Symbol -> *) (l :: a) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (Show_Sym0 :: TyFun a Symbol -> *) (l :: a) = Show_ l

type Show_Sym1 (t :: a6989586621679694510) = Show_ t #

data ShowListSym0 (l :: TyFun [a6989586621679694510] (TyFun Symbol Symbol -> Type)) #

Instances
SuppressUnusedWarnings (ShowListSym0 :: TyFun [a6989586621679694510] (TyFun Symbol Symbol -> Type) -> *) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowListSym0 :: TyFun [a6989586621679694510] (TyFun Symbol Symbol -> Type) -> *) (l :: [a6989586621679694510]) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowListSym0 :: TyFun [a6989586621679694510] (TyFun Symbol Symbol -> Type) -> *) (l :: [a6989586621679694510]) = ShowListSym1 l

data ShowListSym1 (l :: [a6989586621679694510]) (l :: TyFun Symbol Symbol) #

Instances
SuppressUnusedWarnings (ShowListSym1 :: [a6989586621679694510] -> TyFun Symbol Symbol -> *) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowListSym1 l1 :: TyFun Symbol Symbol -> *) (l2 :: Symbol) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowListSym1 l1 :: TyFun Symbol Symbol -> *) (l2 :: Symbol) = ShowList l1 l2

type ShowListSym2 (t :: [a6989586621679694510]) (t :: Symbol) = ShowList t t #

data (<>@#@$) l #

Instances
SuppressUnusedWarnings (<>@#@$) # 
Instance details

Defined in Data.Singletons.TypeLits.Internal

type Apply (<>@#@$) (l :: Symbol) # 
Instance details

Defined in Data.Singletons.TypeLits.Internal

type Apply (<>@#@$) (l :: Symbol) = (<>@#@$$) l

data (l :: Symbol) <>@#@$$ l #

Instances
SuppressUnusedWarnings (<>@#@$$) # 
Instance details

Defined in Data.Singletons.TypeLits.Internal

type Apply ((<>@#@$$) l1 :: TyFun Symbol Symbol -> *) (l2 :: Symbol) # 
Instance details

Defined in Data.Singletons.TypeLits.Internal

type Apply ((<>@#@$$) l1 :: TyFun Symbol Symbol -> *) (l2 :: Symbol) = l1 <> l2

type (<>@#@$$$) (t :: Symbol) (t :: Symbol) = (<>) t t #

data ShowsSym0 (l :: TyFun a6989586621679694495 (TyFun Symbol Symbol -> Type)) #

Instances
SuppressUnusedWarnings (ShowsSym0 :: TyFun a6989586621679694495 (TyFun Symbol Symbol -> Type) -> *) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowsSym0 :: TyFun a6989586621679694495 (TyFun Symbol Symbol -> Type) -> *) (l :: a6989586621679694495) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowsSym0 :: TyFun a6989586621679694495 (TyFun Symbol Symbol -> Type) -> *) (l :: a6989586621679694495) = ShowsSym1 l

data ShowsSym1 (l :: a6989586621679694495) (l :: TyFun Symbol Symbol) #

Instances
SuppressUnusedWarnings (ShowsSym1 :: a6989586621679694495 -> TyFun Symbol Symbol -> *) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowsSym1 l1 :: TyFun Symbol Symbol -> *) (l2 :: Symbol) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowsSym1 l1 :: TyFun Symbol Symbol -> *) (l2 :: Symbol) = Shows l1 l2

type ShowsSym2 (t :: a6989586621679694495) (t :: Symbol) = Shows t t #

data ShowListWithSym0 (l :: TyFun (TyFun a6989586621679694494 (TyFun Symbol Symbol -> Type) -> Type) (TyFun [a6989586621679694494] (TyFun Symbol Symbol -> Type) -> Type)) #

Instances
SuppressUnusedWarnings (ShowListWithSym0 :: TyFun (TyFun a6989586621679694494 (TyFun Symbol Symbol -> Type) -> Type) (TyFun [a6989586621679694494] (TyFun Symbol Symbol -> Type) -> Type) -> *) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowListWithSym0 :: TyFun (TyFun a6989586621679694494 (TyFun Symbol Symbol -> Type) -> Type) (TyFun [a6989586621679694494] (TyFun Symbol Symbol -> Type) -> Type) -> *) (l :: TyFun a6989586621679694494 (TyFun Symbol Symbol -> Type) -> Type) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowListWithSym0 :: TyFun (TyFun a6989586621679694494 (TyFun Symbol Symbol -> Type) -> Type) (TyFun [a6989586621679694494] (TyFun Symbol Symbol -> Type) -> Type) -> *) (l :: TyFun a6989586621679694494 (TyFun Symbol Symbol -> Type) -> Type) = ShowListWithSym1 l

data ShowListWithSym1 (l :: TyFun a6989586621679694494 (TyFun Symbol Symbol -> Type) -> Type) (l :: TyFun [a6989586621679694494] (TyFun Symbol Symbol -> Type)) #

Instances
SuppressUnusedWarnings (ShowListWithSym1 :: (TyFun a6989586621679694494 (TyFun Symbol Symbol -> Type) -> Type) -> TyFun [a6989586621679694494] (TyFun Symbol Symbol -> Type) -> *) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowListWithSym1 l1 :: TyFun [a6989586621679694494] (TyFun Symbol Symbol -> Type) -> *) (l2 :: [a6989586621679694494]) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowListWithSym1 l1 :: TyFun [a6989586621679694494] (TyFun Symbol Symbol -> Type) -> *) (l2 :: [a6989586621679694494]) = ShowListWithSym2 l1 l2

data ShowListWithSym2 (l :: TyFun a6989586621679694494 (TyFun Symbol Symbol -> Type) -> Type) (l :: [a6989586621679694494]) (l :: TyFun Symbol Symbol) #

Instances
SuppressUnusedWarnings (ShowListWithSym2 :: (TyFun a6989586621679694494 (TyFun Symbol Symbol -> Type) -> Type) -> [a6989586621679694494] -> TyFun Symbol Symbol -> *) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowListWithSym2 l1 l2 :: TyFun Symbol Symbol -> *) (l3 :: Symbol) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowListWithSym2 l1 l2 :: TyFun Symbol Symbol -> *) (l3 :: Symbol) = ShowListWith l1 l2 l3

type ShowListWithSym3 (t :: TyFun a6989586621679694494 (TyFun Symbol Symbol -> Type) -> Type) (t :: [a6989586621679694494]) (t :: Symbol) = ShowListWith t t t #

data ShowCharSym1 (l :: Symbol) (l :: TyFun Symbol Symbol) #

Instances
SuppressUnusedWarnings ShowCharSym1 # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowCharSym1 l1 :: TyFun Symbol Symbol -> *) (l2 :: Symbol) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowCharSym1 l1 :: TyFun Symbol Symbol -> *) (l2 :: Symbol) = ShowChar l1 l2

type ShowCharSym2 (t :: Symbol) (t :: Symbol) = ShowChar t t #

data ShowStringSym1 (l :: Symbol) (l :: TyFun Symbol Symbol) #

Instances
SuppressUnusedWarnings ShowStringSym1 # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowStringSym1 l1 :: TyFun Symbol Symbol -> *) (l2 :: Symbol) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowStringSym1 l1 :: TyFun Symbol Symbol -> *) (l2 :: Symbol) = ShowString l1 l2

type ShowStringSym2 (t :: Symbol) (t :: Symbol) = ShowString t t #

data ShowParenSym2 (l :: Bool) (l :: TyFun Symbol Symbol -> Type) (l :: TyFun Symbol Symbol) #

Instances
SuppressUnusedWarnings ShowParenSym2 # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowParenSym2 l1 l2 :: TyFun Symbol Symbol -> *) (l3 :: Symbol) # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply (ShowParenSym2 l1 l2 :: TyFun Symbol Symbol -> *) (l3 :: Symbol) = ShowParen l1 l2 l3

data ShowSpaceSym0 (l :: TyFun Symbol Symbol) #

Instances
SuppressUnusedWarnings ShowSpaceSym0 # 
Instance details

Defined in Data.Singletons.Prelude.Show

type Apply ShowSpaceSym0 (l :: Symbol) # 
Instance details

Defined in Data.Singletons.Prelude.Show