D Grammar in BNF Text Form?

Robert Schadek via Digitalmars-d digitalmars-d at puremagic.com
Fri Jun 6 05:00:02 PDT 2014


On 06/06/2014 12:29 PM, Tom Browder via Digitalmars-d wrote:
> Can anyone point me to a text version of the D grammar in some kind of
> BNF or EBNF format?  The D lang web site's info is close, but it's
> buried in html which I'ld rather not have to wrestle with.
>
> My purpose is to attempt to write a D language parser in Perl using
> Damian Conway's Regex::Grammars module (on CPAN).
>
> Thanks.
>
> Best regards,
>
> -Tom
The site says it creates recursive decent parser. D does not even fit
into lalr1. So it will not work, unless you can inject handwritten parse
function for the critical parts


More information about the Digitalmars-d mailing list