Having written a D2 parser a few month ago in the hope it will be helpful to Visual D (just finds it way into the plugin right now), I've noticed quite some inaccuracies in the "official" grammar on the website. Some of these are probably already in bugzilla, some of them might be personal taste and should be discussed, though.

I've set up a comparison with some notes here:

http://www.dsource.org/projects/visuald/wiki/GrammarComparison

The parser was written manually, so the proposed grammar was not directly used to generate the parser and might still contain errors.

I've extracted the website grammar using some combination of scripts from the ddoc sources, so if there is interest, I can dig them up...

Rainer

Walter Bright wrote:
On 3/28/2011 9:02 AM, Luca Boasso wrote:
A complete D grammar is one of the objectives of my GSOC 2011 ANTLR
proposal, if I got accepted you will have one :)

The complete grammar should be part of the D spec. Please post any errors/fixes to the existing one to bugzilla!

Reply via email to