unbound-0.2: Generic support for programming with names and binders

MaintainerStephanie Weirich <sweirich@cis.upenn.edu>



XXX write me



rR1 :: forall ctx[a18LQ] a[a1FY]. Rep a[a1FY] => R1 ctx[a18LQ] (R a[a1FY])Source

rR :: forall a[a1FY]. Rep a[a1FY] => R (R a[a1FY])Source

data Name a Source

Names are things that get bound. This type is intentionally abstract; to create a Name you can use string2Name or integer2Name. The type parameter is a tag, or sort, which tells us what sorts of things this name may stand for. The sort must be an instance of the Rep type class.


Nm (R a) (String, Integer) 
Bn (R a) Integer Integer 


(Rep a[a18ML], Sat (ctx[a18QA] (R a[a18ML])), Sat (ctx[a18QA] (String, Integer)), Sat (ctx[a18QA] Integer)) => Rep1 ctx[a18QA] (Name a[a18ML]) 
Rep a => Subst b (Name a) 
Eq (Name a) 
Ord (Name a) 
Show (Name a) 
Rep a[a18ML] => Rep (Name a[a18ML]) 
Rep a => Alpha (Name a) 

rName1 :: forall ctx[a18QA] a[a18ML]. Rep a[a18ML] => ctx[a18QA] (R a[a18ML]) -> ctx[a18QA] (String, Integer) -> ctx[a18QA] Integer -> R1 ctx[a18QA] (Name a[a18ML])Source

rName :: forall a[a18ML]. Rep a[a18ML] => R (Name a[a18ML])Source

data AnyName Source

A name with a hidden (existentially quantified) sort.


forall a . Rep a => AnyName (Name a) 

rAnyName1 :: forall ctx[a18Tc]. R1 ctx[a18Tc] AnyNameSource

name2 :: Rep a => Name aSource

name3 :: Rep a => Name aSource

name4 :: Rep a => Name aSource

name5 :: Rep a => Name aSource

name6 :: Rep a => Name aSource

name7 :: Rep a => Name aSource

name8 :: Rep a => Name aSource

name9 :: Rep a => Name aSource

name1 :: Rep a => Name aSource

name2Integer :: Name a -> IntegerSource

Get the integer index of a Name.

name2String :: Name a -> StringSource

Get the string part of a Name.

anyName2Integer :: AnyName -> IntegerSource

Get the integer index of an AnyName.

anyName2String :: AnyName -> StringSource

Get the string part of an AnyName.

integer2Name :: Rep a => Integer -> Name aSource

Create a Name from an Integer.

string2Name :: Rep a => String -> Name aSource

Create a Name from a String.

s2n :: Rep a => String -> Name aSource

Convenient synonym for string2Name.

makeName :: Rep a => String -> Integer -> Name aSource

Create a Name from a String and an Integer index.

getR :: Name a -> R aSource

Determine the sort of a Name.

translate :: Rep b => Name a -> Name bSource

Change the sort of a name