On Mon, Dec 25, 2023 Michael Van Canneyt wrote: > In short: To make a EBNF grammar which is 100% correct is not so simple > and will make the scheme extremely difficult to understand for a reader. > So I prefer to present a simpler version, and mention some limitations > only in the text ... > There are simply so many exceptions and limitations that the 100% correct > diagram would be incomprehensible and needlessly complicated if you tried to > capture every aspect for the full 100%.
If the EBNF grammar is only a guide provided as documentation for a human reader then you might want that. But if the EBNF grammar is used to drive a parser then it needs to be fully complete, accurate, and machine readable (see below). On Sat, Dec 16, 2023 Adriaan van Os wrote: > Anyway, I strive to make the syntax complete and correct. When it is ready, > I can send it in to be added as an Appendix to the Language Reference > manual. I have an ebfn-driven general (back-parsing) parser that already > works for Oberon-0 end UCSD-Pascal. So, the ebnf can be tested. Is your parser able to read and validate the EBNF grammar itself for syntax and correctness (i.e. the grammar is complete and consistent) ? Can your parser be used with the EBNF grammar to parse and validate Pascal code and report syntax problems? _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal