Higher-order functions in GF

140 views
Skip to first unread message

Erik Flood

unread,
Apr 13, 2011, 10:27:26 AM4/13/11
to Grammatical Framework
Hi,

I'm new at GF and I'm trying to implement quantifiers as described in
the tutorial (Lesson 5) on GF's homepage:

My grammar is as follows:

abstract Logic = {
cat
Ind ; Prop ;
fun
All : (Ind -> Prop) -> Prop ;
Eq : Ind -> Ind -> Prop ;
}

concrete LogicEng of Logic = {

lin
Eq a b = {s = "(" ++ a.s ++ "=" ++ b.s ++ ")"} ;
All B = {s = "(" ++ "All" ++ B.$0 ++ ")" ++ B.s} ;
}


But i cannot parse or linearize any expression, I only receive an
error message saying "Category S is not in scope" when I for example
run "gr".

What am I doing wrong?

Best regards

Erik Flood

Krasimir Angelov

unread,
Apr 13, 2011, 10:32:17 AM4/13/11
to gf-...@googlegroups.com, Erik Flood
Try:

gr -cat=Prop

Regards,
Krasimir


2011/4/13 Erik Flood <erik.n...@gmail.com>:

Reply all
Reply to author
Forward
0 new messages