[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: error duplicated in the log (if the error is in a variable copied in
From: |
David Kastrup |
Subject: |
Re: error duplicated in the log (if the error is in a variable copied in two contexts) |
Date: |
Sat, 22 Feb 2014 10:58:52 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) |
Federico Bruni <address@hidden> writes:
> As you can see in the example below, an error in a variable which is
> present in two contexts (Staff and TabStaff) is printed twice:
>
> \version "2.19.1"
>
> music = \relative c' {
> c4 d e f g |
> }
>
> \score {
> \new StaffGroup <<
> \new Staff <<
> \context Voice { \clef "G_8" \music }
> >>
> \new TabStaff <<
> \context TabVoice { \clef "moderntab" \music }
> >>
> >>
> }
>
> produces the following log:
>
> ###
> Parsing...
> Interpreting music...
> document.ly: warning: barcheck failed at: 1/4
> c4 d e f g
> |
> document.ly: warning: barcheck failed at: 1/4
> c4 d e f g
> |
> Preprocessing graphical objects...
> Finding the ideal number of pages...
> Fitting music on 1 page...
> ###
>
> I'm not sure if it's a bug. But the duplication can be a bit annoying when
> you work on a big file containing many errors (for example, because it's
> the result of an export which doesn't produce good lilypond code). I know I
> can skip the duplicate, but a cleaner log would be nice.
>
> Would it be possible to print only once occurrence of an error in a
> variable?
It's not the same error. I can perfectly well write
\new Staff { \time 5/4 \music }
or
\new Staff { \partial 4 \music }
and either will not trigger a barcheck error. So it's not that \music
contains an error: whether it is an error (and how much the bar check is
actually off) or not depends on the context in which it is used.
--
David Kastrup