summaryrefslogtreecommitdiff
path: root/src/compiler/GF/Compile/PGFtoProlog.hs
diff options
context:
space:
mode:
authorkr.angelov <kr.angelov@gmail.com>2012-08-29 11:43:02 +0000
committerkr.angelov <kr.angelov@gmail.com>2012-08-29 11:43:02 +0000
commitf8fe23fda7b97d5301bfb2ec1d89ce9967c5b200 (patch)
treea2db1d1dbe1cd294a7f323abb0123ea8c551fc82 /src/compiler/GF/Compile/PGFtoProlog.hs
parent27196778ace6de265407947a21a5b0eb3fd0caf8 (diff)
A basic infrastructure for generating Teyjus bytecode from the GF abstract syntax
Diffstat (limited to 'src/compiler/GF/Compile/PGFtoProlog.hs')
-rw-r--r--src/compiler/GF/Compile/PGFtoProlog.hs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/compiler/GF/Compile/PGFtoProlog.hs b/src/compiler/GF/Compile/PGFtoProlog.hs
index 03a29871b..de50d86d1 100644
--- a/src/compiler/GF/Compile/PGFtoProlog.hs
+++ b/src/compiler/GF/Compile/PGFtoProlog.hs
@@ -49,16 +49,16 @@ plAbstract name abs
(f, v) <- Map.assocs (aflags abs)] ++++
plFacts name "cat" 2 "(?Type, ?[X:Type,...])"
[[plType cat args, plHypos hypos'] |
- (cat, (hypos, _)) <- Map.assocs (cats abs),
+ (cat, (hypos, _, _)) <- Map.assocs (cats abs),
let ((_, subst), hypos') = mapAccumL alphaConvertHypo emptyEnv hypos,
let args = reverse [EFun x | (_,x) <- subst]] ++++
plFacts name "fun" 3 "(?Fun, ?Type, ?[X:Type,...])"
[[plp fun, plType cat args, plHypos hypos] |
- (fun, (typ, _, _, _)) <- Map.assocs (funs abs),
+ (fun, (typ, _, _, _, _)) <- Map.assocs (funs abs),
let (_, DTyp hypos cat args) = alphaConvert emptyEnv typ] ++++
plFacts name "def" 2 "(?Fun, ?Expr)"
[[plp fun, plp expr] |
- (fun, (_, _, Just eqs, _)) <- Map.assocs (funs abs),
+ (fun, (_, _, Just eqs, _, _)) <- Map.assocs (funs abs),
let (_, expr) = alphaConvert emptyEnv eqs]
)
where plType cat args = plTerm (plp cat) (map plp args)