[antlr-interest] Meaning of the {synpred} objects in the Clif.g (ISO Common Logic) parser

Jim Idle jimi at temporal-wave.com
Wed Jan 30 08:26:00 PST 2008


The interpreter cannot execute predicates, you need to run it in the
debugger. The syntactic predicates are used to attempt a parse of the
input stream and match the tokens in the predicate. If they match then
that alt is taken, if they do not then that alt is rejected. 

 

Jim

 

From: John Black [mailto:JohnBlack at kashori.com] 
Sent: Wednesday, January 30, 2008 5:44 AM
To: antlr-interest at antlr.org; pando-devel at lists.sourceforge.net;
billanderson at users.sourceforge.net
Subject: [antlr-interest] Meaning of the {synpred} objects in the Clif.g
(ISO Common Logic) parser

 

I have been viewing the Clif.g [1] grammar in AntlrWorks and I am
puzzled by the errors the interpreter produces when I try to parse some
clif strings with that GUI when loaded with that grammer. Here is an
example:

 

*  FailedPredicateException(sentence,{synpred41}?) 

 

I am also curious about boxes shown in the 'Syntax Diagram' with such
names as '{synpred41}',  '{synpred42}', '{synpred43}', shown when
looking at the 'sentence' goal. Can someone point me to documentation
that explains these objects? Or is someone willing to explain them to
me? Also, do they have any affect on the operation of the parser? 

 

I am interested in this now that ISO Common Logic has become an official
ISO standard [2] for symbolic logic and conceptual graphs. Also, I am
interested in helping to get the "ISO Common Logic Tools" [3]
SourceForge project jump started. 

 

Cheers,

John Black

www.kashori.com

 

 

 

1.
http://pando.svn.sourceforge.net/viewvc/pando/code/modules/parsers/src/n
et/sf/pando/parsers/clif3/grammar/Clif3.g?view=log

 

2.
http://www.iso.org/iso/iso_catalogue/catalogue_tc/catalogue_detail.htm?c
snumber=39175

 

3. http://sourceforge.net/projects/common-logic/


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org/pipermail/antlr-interest/attachments/20080130/b52bb78f/attachment.html 


More information about the antlr-interest mailing list