[antlr-interest] BNF to ANTLR

Loring Craymer lgcraymer at yahoo.com
Wed Nov 4 11:05:04 PST 2009


Actually, this is easier to do automatically.  Any BNF dialect takes about 2 pages for parser + lexer description of the BNF in ANTLR; it is very easy to write a translator from one BNF dialect to another (ANTLR).  You will still have to rework the resulting grammar.

--Loring



----- Original Message ----
> From: Jim Idle <jimi at temporal-wave.com>
> To: "antlr-interest at antlr.org" <antlr-interest at antlr.org>
> Sent: Wed, November 4, 2009 8:05:12 AM
> Subject: Re: [antlr-interest] BNF to ANTLR
> 
> Much better to do it by hand. ANTLRs EBNF notation is close, but remember that 
> ANTLR is LL() and not LALR, which most bnf definitions from normative specs are 
> aimed at. Use ANTLRWorks and build slowly and you should pick it up quite 
> quickly if you understand BNF well.
> 
> Jim
> 
> > -----Original Message-----
> > From: antlr-interest-bounces at antlr.org [mailto:antlr-interest-
> > bounces at antlr.org] On Behalf Of Stefan Frey
> > Sent: Wednesday, November 04, 2009 6:33 AM
> > To: antlr-interest at antlr.org
> > Subject: [antlr-interest] BNF to ANTLR
> > 
> > Hi im quite new to ANTLR and compiler generation.
> > I have a grammer written in BNF and need to convert it
> > to the Format ANTLR supports. So ist there a better/quicker
> > solution than by doing it by hand?
> > 
> > Cheers Stefan
> > 
> > List: http://www.antlr.org/mailman/listinfo/antlr-interest
> > Unsubscribe: http://www.antlr.org/mailman/options/antlr-interest/your-
> > email-address
> 
> 
> 
> 
> List: http://www.antlr.org/mailman/listinfo/antlr-interest
> Unsubscribe: 
> http://www.antlr.org/mailman/options/antlr-interest/your-email-address



      


More information about the antlr-interest mailing list