[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond
From: |
Helge Kruse |
Subject: |
Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond? |
Date: |
Mon, 20 Feb 2012 07:26:05 +0100 |
User-agent: |
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:10.0.2) Gecko/20120216 Thunderbird/10.0.2 |
Am 19.02.2012 11:48, schrieb Michael Hendry:
> So it would be:
>
> #define debugging
>
> ... several pages of code ...
>
> #ifdef debugging
> ... print something on the screen, and await a user response ...
> #endif
>
> ... several more pages of code ...
>
> #ifdef debugging
> ... do something else that's useful in the debugging process ...
> #endif
>
> ... and so on ...
>
>
> I envisage a series of #define statements at the head of the main .ly
file
> such as:
>
> #define concert_part
> #define guitar_part
> #undef alto_part
> #define clarinet_part
Ok, if you want to use the C preprocessor syntax, you can just use the C
preprocessor. Add a short script the passes your source file through the
C preprocessor to a temporary file and start Lilypond with that file.
If you just don't have your C compiler at the PC you can use a
preprocessor implementation like this: http://mcpp.sourceforge.net/
Helge
- Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, (continued)
- Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, Francisco Vila, 2012/02/24
- Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, Michael Hendry, 2012/02/25
- Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, David Kastrup, 2012/02/25
- Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, Michael Hendry, 2012/02/26
- Re: Is there an equivalent of #define ... #ifndef ... #endif inlilypond?, Phil Holmes, 2012/02/26
- Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, David Kastrup, 2012/02/26
- Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, Thomas Morley, 2012/02/24
- Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, David Kastrup, 2012/02/25
- Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, David Kastrup, 2012/02/25
- Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, David Kastrup, 2012/02/24
- Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?,
Helge Kruse <=
Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, David Kastrup, 2012/02/19
Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, Saul Tobin, 2012/02/19
Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, Urs Liska, 2012/02/20
Re: Is there an equivalent of #define ... #ifndef ... #endif in lilypond?, Christ van Willegen, 2012/02/20