ajhc- Haskell compiler that produce binary through C language

Safe HaskellNone




data Id Source


Eq Id 
Ord Id 
Show IdSet 
Show Id 
Binary IdSet 
Binary Id 
GenName Id 
Intjection Id 
FromAtom Id 
FreeVars TVr IdSet

determine free variables of a binding site

FreeVars E IdSet 
FreeVars ARules IdSet 
FreeVars Rule IdSet

we delete the free variables of the heads of a rule from the rule's free variables. the reason for doing this is that the rule cannot fire if all its heads are in scope, and if it were not done then many functions seem recursive when they arn't actually.

FreeVars Comb IdSet 
DocLike d => PPrint d Id 
Monad m => NameMonad Id (IdNameT m) 
FreeVars E [Id] 
FreeVars E (IdMap (Maybe E)) 
FreeVars E (IdMap TVr) 
FreeVars Rule [Id] 
FreeVars Comb [Id] 
Show v => Show (IdMap v) 
Binary a => Binary (IdMap a) 
FreeVars (Alt E) IdSet 
FreeVars (Alt E) (IdMap TVr) 

data IdNameT m a Source

Name monad transformer.

va1 :: IdSource

some convinience anonymous ids

va2 :: IdSource

some convinience anonymous ids

va3 :: IdSource

some convinience anonymous ids

va4 :: IdSource

some convinience anonymous ids

va5 :: IdSource

some convinience anonymous ids

sillyId :: IdSource

A occasionally useful random ethereal id

isInvalidId :: Id -> BoolSource

id isn't anonymous or atom-mapped

idSetToIdMap :: (Id -> a) -> IdSet -> IdMap aSource

mapMaybeIdMap :: (a -> Maybe b) -> IdMap a -> IdMap bSource

idMapToList :: IdMap a -> [(Id, a)]Source

newIds :: IdSet -> [Id]Source

find some temporary ids that are not members of the set, useful for generating a small number of local unique names.



:: Int

a seed value, useful for speeding up finding a unique id

-> (Id -> Bool)

whether an Id is acceptable

-> Id

your new Id

fromId :: Monad m => Id -> m NameSource

runIdNameT :: Monad m => IdNameT m a -> m (a, IdSet)Source

Run the name monad transformer.