[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Lilypond BNF
From: |
Nicolas Sceaux |
Subject: |
Re: Lilypond BNF |
Date: |
Tue, 26 Jul 2005 21:30:19 +0200 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (darwin) |
Carl Sorensen <address@hidden> writes:
> Almost a year ago, Pedro Kroger was working on a bnf description of
> lilypond. (see http://lists.gnu.org/archive/html/lilypond-
> devel/2004-10/msg00074.html). Han-Wen suggested hacking Bison so that
> it would produce the BNF directly from the .yy file.
>
> I went a different direction, and produced a python script that ignores
> all the C++ stuff in parser.yy, resulting in a BNF description of
> lilypond that is generated directly from the parser.
>
> I've attached the script (yy2bnf.py), along with the result of running
> the script on the current CVS version of parser.yy (lilypond.bnf).
>
> I'd like to suggest that lilypond.bnf be added to the documentation, to
> be automatically generated as part of the make process, using yy2bnf.py.
>
> Thanks,
>
> Carl Sorensen
It might be a good idea to process the output of `bison -v parser.yy`:
parser.output contains the rules, and lists terminals and non-terminals,
with references to the rules where they appear (and some more
informations).
nicolas
- Lilypond BNF, Carl Sorensen, 2005/07/26
- Re: Lilypond BNF,
Nicolas Sceaux <=
- Re: Lilypond BNF, Han-Wen Nienhuys, 2005/07/26
- Re: Lilypond BNF, Carl Sorensen, 2005/07/26
- Re: Lilypond BNF, Han-Wen Nienhuys, 2005/07/26
- Re: Lilypond BNF, Carl Sorensen, 2005/07/26
- Re: Lilypond BNF, Carl Sorensen, 2005/07/27
- Re: Lilypond BNF, Juergen Reuter, 2005/07/27
- Re: Lilypond BNF, Carl Sorensen, 2005/07/27
- Re: Lilypond BNF, Nicolas Sceaux, 2005/07/27
- Re: Lilypond BNF, Carl Sorensen, 2005/07/27