Contents
Index
Translator.Prolog.Relational
Synopsis
type
TransM
a = State
TransState
a
type
VarMapping
=
StrictMap
Term
Term
data
TransState
=
TS
{
varmap
::
VarMapping
used
:: Int
}
newMapping
::
Term
->
Term
->
TransM
()
lookupBothSM
:: Ord a =>
StrictMap
a a -> a -> Maybe a
hasMapping
::
Term
->
TransM
(Maybe
Term
)
mkNewVar
::
TransM
Term
normalizePredicate
:: (
Predicate
, [
Clause
]) -> (
Predicate
, [
Clause
])
normalizeClause
::
Clause
-> (
Clause
,
VarMapping
)
normalizeClause'
::
Clause
->
TransM
Clause
normalizeHead
::
Atom
->
TransM
Atom
normalizeTail
:: [
Atom
] ->
TransM
[
Atom
]
normalizeAtom
::
Atom
->
TransM
Atom
replaceTermWithFresh
::
Term
->
TransM
Term
renameBoundVars
::
Term
->
TransM
Term
normalizeTerm
::
Term
->
TransM
Term
translateProlog
::
Module
Predicate
Clause
->
Module
Predicate
Relational
translatePredicate
::
Predicate
-> [
Clause
] -> [
Relational
]
translateClause
:: (
Clause
,
VarMapping
) ->
Relational
translateAtom
::
VarMapping
->
Atom
->
Relational
translateMappings
::
VarMapping
->
Relational
constructPerm
::
VarMapping
->
Atom
->
Perm
fillPerm
::
Vector
->
Vector
->
Vector
invertPerm
::
Perm
->
Perm
Produced by
Haddock
version 0.6