lilypond-auto
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Lilypond-auto] Issue 3098 in lilypond: Parser diagnostics failing to re


From: lilypond
Subject: [Lilypond-auto] Issue 3098 in lilypond: Parser diagnostics failing to recognise \on-the-fly arguments as procedure type
Date: Thu, 10 Jan 2013 01:56:12 +0000

Status: Accepted
Owner: ----
Labels: Type-Defect

New issue 3098 by address@hidden: Parser diagnostics failing to recognise \on-the-fly arguments as procedure type
http://code.google.com/p/lilypond/issues/detail?id=3098

Ian Hulin posted to lilypond-devel:

http://lists.gnu.org/archive/html/lilypond-devel/2013-01/msg00027.html

and then again to bug-lilypond with more information about his problem, as follows:

Hi all
Firstly apologies if I've not done too much investigation into this but
I'm currently working off my netbook from hospital.

I've been using Mark Wilmer's LyUtil package which looks really useful,
but I want to see whether the coe has uncovered something that gets the
parser confused.

LyUtil kicks off with a music function entry point with this inerface
definition

#(define* (ly-score:process prefix scorehead parthead
  movements instruments
  #:key transpose? include-parts? include-score? include-midi?
   (score-size 12) (part-size 24)                                  (score-paper 
#{ \paper
{} #})
(part-paper #{ \paper {} #})
(score-layout #{ \layout {} #}) (part-layout #{ \layout {} #})
(part-overrides '())
(frontmatter #{ \markuplist {} #}))

   (set-paper-staff-size score-paper score-size)
   (set-paper-staff-size part-paper part-size)
   (if include-score?
       (with-fluids ((ignore-cues? #t))
         (let ((score-book
           #{ \book { \paper { $score-paper }
                \markuplist { $frontmatter } } #}))
           (for-each
            (lambda (el)
              (ly:book-add-score!
               score-book
               (ly-score:make-score (car el) (cadr el)
                 instruments #t transpose? score-layout include-midi?)))
            movements)
           (ly:book-set-header! score-book (ly-score:alist->module scorehead))
           (ly:book-process score-book score-paper score-layout prefix))))
   (if include-parts?
       (ly-score:process-part prefix parthead movements instruments
part-layout part-paper part-overrides)))

i
However, if I code the #:score-paper parameter with is sort of thing:

 #:score-paper
    #{
      \paper {
        #(set-paper-size "a3")
        oddFooterMarkup =  \markup{
           \fill-line{ \fromproperty #'header:title
              \center-column {
                \on-the-fly #first-page
                  \fromproperty #'header:publisher
                  \on-the-fly #last-page
                   \fromproperty #'header:copyright
                   \fromproperty #'header:tagline
                    }
            \bold \fontsize #3 %\on-the-fly #not-first-page
            \fromproperty #'page:page-number-string
        }
     }
  #}

Gives these diagnosics:

Processing
`/home/ian/Dropbox/MusicScoresDevelopment/ZadokThePriest/Coronation
Anthem 1.ly'
Parsing...
/home/ian/Dropbox/MusicScoresDevelopment/ZadokThePriest/Coronation
Anthem 1.ly:236:39: error: GUILE signaled an error for the expression
beginning here
                          \on-the-fly #
                                       first-page
/home/ian/Dropbox/MusicScoresDevelopment/ZadokThePriest/Coronation
Anthem 1.ly:236:38: error: wrong type for argument 1.  Expecting
procedure, found #<unspecified>
                          \on-the-fly
                                      #first-page
/home/ian/Dropbox/MusicScoresDevelopment/ZadokThePriest/Coronation
Anthem 1.ly:79:1: error: GUILE signaled an error for the expression
beginning here
#
 (ly-score:process
Unbound variable: first-page
Wrong type argument in position 1: (#<unspecified> . #f)
fatal error: failed files:
"/home/ian/Dropbox/MusicScoresDevelopment/ZadokThePriest/Coronation
Anthem 1.ly"
Exited with return code 1.

I suspect this could be a LilyPond bug rather than LyUtils.  Would
anyone with better access to resources have an opportunity to investigate.

Cheers and a Happy New Year to all 'Ponders
Ian Hulin



======================================================================
I cannot provide a truly minimal example, so here are pointers to all
necessary files to investigate:

Hi David,
Here are the links to the files on my DropBox public folder.

Bits of LyUtil needed:

http://dl.dropbox.com/u/3492570/OnTheFlyTest/ly-score.ly[1]
http://dl.dropbox.com/u/3492570/OnTheFlyTest/ly-score-instruments.ly[2]
http://dl.dropbox.com/u/3492570/OnTheFlyTest/ly-score-time-sig.ly[3]

Project Files
http://dl.dropbox.com/u/3492570/OnTheFlyTest/OnTheFly.ly[4]     
        (this one has the \on-the-fly calls enabled. )
http://dl.dropbox.com/u/3492570/OnTheFlyTest/OnTheFly2.ly[5]
        (this one has the \on-the-fly calls commented out. )
Files in sub-folder for Allegro movement
http://dl.dropbox.com/u/3492570/OnTheFlyTest/Allegro/cello.ly[6]
http://dl.dropbox.com/u/3492570/OnTheFlyTest/Allegro/time_signature.ly[7]
http://dl.dropbox.com/u/3492570/OnTheFlyTest/Allegro/viola.ly[8]
http://dl.dropbox.com/u/3492570/OnTheFlyTest/Allegro/violin2.ly[9]
http://dl.dropbox.com/u/3492570/OnTheFlyTest/Allegro/violin1.ly[10]

Running OnTheFly2.ly does everything it apparently needs to do ad
produces all the output, but produces a "squawk" -

---------------------------------------------------------------
Processing `/home/ian/Dropbox/Public/OnTheFlyTest/OnTheFly2.ly'
Parsing...
Interpreting music...
Interpreting music...
Preprocessing graphical objects...
MIDI output to `OnTheFly2.midi'...
Finding the ideal number of pages...
Fitting music on 1 page...
Drawing systems...
Layout output to `OnTheFly2.ps'...
Converting to `./OnTheFly2.pdf'...
Interpreting music...
Preprocessing graphical objects...
Calculating page and line breaks (1 possible page breaks)...[1]
Drawing systems...
Layout output to `OnTheFly2-violin1.ps'...
Converting to `./OnTheFly2-violin1.pdf'...
Interpreting music...
Preprocessing graphical objects...
Calculating page and line breaks (1 possible page breaks)...[1]
Drawing systems...
Layout output to `OnTheFly2-violin2.ps'...
Converting to `./OnTheFly2-violin2.pdf'...
Interpreting music...
Preprocessing graphical objects...
Calculating page and line breaks (1 possible page breaks)...[1]
Drawing systems...
Layout output to `OnTheFly2-viola.ps'...
Converting to `./OnTheFly2-viola.pdf'...
Interpreting music...
Preprocessing graphical objects...
Calculating page and line breaks (1 possible page breaks)...[1]
Drawing systems...
Layout output to `OnTheFly2-cello.ps'...
Converting to `./OnTheFly2-cello.pdf'...
/home/ian/Dropbox/Public/OnTheFlyTest/OnTheFly2.ly:88:5: error: syntax
error, unexpected end of input
    )

Using default for paper (violin . 1).
Using default for layout (violin . 1).
Using default for paper (violin . 2).
Using default for layout (violin . 2).
Using default for paper viola.
Using default for layout viola.
Using default for paper cello.
Using default for layout cello.
fatal error: failed files:
"/home/ian/Dropbox/Public/OnTheFlyTest/OnTheFly2.ly"
Exited with return code 1.
---------------------------------------------------------------

Compiling OnTheFly.ly
gives the following output:
================================================================
Starting lilypond 2.17.9 [OnTheFly.ly]...
Processing `/home/ian/Dropbox/Public/OnTheFlyTest/OnTheFly.ly'
Parsing...
/home/ian/Dropbox/Public/OnTheFlyTest/OnTheFly.ly:53:39: error: GUILE
signaled an error for the expression beginning here
                          \on-the-fly #
                                       first-page
/home/ian/Dropbox/Public/OnTheFlyTest/OnTheFly.ly:53:38: error: wrong
type for argument 1.  Expecting procedure, found #<unspecified>
                          \on-the-fly
                                      #first-page
/home/ian/Dropbox/Public/OnTheFlyTest/OnTheFly.ly:9:1: error: GUILE
signaled an error for the expression beginning here
#
 (ly-score:process
/home/ian/Dropbox/Public/OnTheFlyTest/OnTheFly.ly:88:5: error: syntax
error, unexpected end of input
    )

Unbound variable: first-page
Wrong type argument in position 1: (#<unspecified> . #f)
fatal error: failed files:
"/home/ian/Dropbox/Public/OnTheFlyTest/OnTheFly.ly"
Exited with return code 1.
====================================================================

Thanks for looking at this,

Cheers,
Ian






reply via email to

[Prev in Thread] Current Thread [Next in Thread]