On Sunday, 12 June 2016 at 06:45:58 UTC, Russel Winder wrote:
I should know this, but…

Is there an official D grammar (EBNF or otherwise) or is the language
defined by the DMD parser?

I am looking to continue Kingsley's DLanguage IntelliJ IDEA plugin and for that it is necessary to have a grammar specification. Kingsley has been working on one, but there may be differences between it and 2.071. Given the compilers and all the supporting tools either there is one language specification they all work with or there is a lot of fragmented viewpoints as to what D actually is. I am hoping the latter is not the case.

Officially, the grammar is defined throughout the specification pages, e.g. on http://dlang.org/spec/grammar.html.

Practically, not sure how complete / correct it is, though I know it has been kept up to date by people working on compilers and parsers.

Pragmatically, there's this: https://github.com/Hackerpilot/DGrammar

Reply via email to