lilypond-devel
[Top][All Lists]
Advanced

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

Re: Transposable guitar fret diagrams


From: Carl D. Sorensen
Subject: Re: Transposable guitar fret diagrams
Date: Wed, 6 Aug 2008 20:29:00 -0600



On 8/6/08 7:47 PM, "Han-Wen Nienhuys" <address@hidden> wrote:

> looks good to me
>
> +  (define (flatten l)
> +    (cond ((null? l) '())
> +          ((pair? l)
> +           (append (flatten (car l)) (flatten (cdr l))))
> +          (else (list l))))
>
> i'd wager we already have this somewhere, if not can you move this to
> scm/lily-library.scm?

We actually had it twice -- as flatten-list in scm/lily-library.scm and as
flatten in scm/song-util.scm.

I deleted it from song-util.scm; I grep'd for usage of flatten and couldn't
find any.

>
>
> On Wed, Aug 6, 2008 at 9:26 PM, Carl D. Sorensen <address@hidden> wrote:
>
>> 2) Can you give me any clues about how to set up LilyPond debugging so that
>> I might be able to track down the source of the error that occurs when I
>> load ly/predefined-fretboards-init.ly in property-init.ly?
>
> try running with --verbose ; that will switch on Scheme stacktraces
> for errors.  Or is that not what you mean?

I ran with --verbose, and proved that the error was in parsing
predefined-fretboards-init, but the error didn't make any sense to me.
Here's the relevant part.

[/Users/Carl/lilypond-working/out/share/lilypond/current/ly/predefined-fretb
oards-init.lyBacktrace:
In unknown file:
   ?:  0* [lilypond-main ("fretboardtest.ly")]
In /Users/Carl/lilypond-working/out/share/lilypond/current/scm/lily.scm:
 660:  1* (let* ((failed #)) (if (ly:get-option #) (begin #)) ...)
 660:  2* [lilypond-all ("fretboardtest.ly")]
 676:  3  (let* ((failed #) (separate-logs #) (ping-log #) ...) (gc) ...)
 688:  4* [for-each #<procedure #f (x)> ("fretboardtest.ly")]
In unknown file:
   ?:  5* [#<procedure #f (x)> "fretboardtest.ly"]
In /Users/Carl/lilypond-working/out/share/lilypond/current/scm/lily.scm:
 690:  6* (let* (# # #) (if separate-logs #) (if ping-log #) ...)
 705:  7* [lilypond-file #<procedure #f (key failed-file)>
"fretboardtest.ly"]
 742:  8  [catch ly-file-failed #<procedure #f ()> #<procedure #f (x .
args)>]
In unknown file:
   ?:  9* [#<procedure #f ()>]
In /Users/Carl/lilypond-working/out/share/lilypond/current/scm/lily.scm:
 743: 10* [ly:parse-file "fretboardtest.ly"]
In unknown file:
   ?: 11* [{#<undefined>}]

/Users/Carl/lilypond-working/out/share/lilypond/current/scm/lily.scm:743:21:
In procedure apply in expression (ly:parse-file file-name):
/Users/Carl/lilypond-working/out/share/lilypond/current/scm/lily.scm:743:21:
Wrong type argument in position 1: #<undefined>



I considered that I was including the file in two different locations, so I
moved it to the end of ly/declarations-init.ly.  When I did this, everything
worked just fine.

I'm a bit concerned about this, because I never did track down the source of
the error.  But it does work.

I've pushed the changes to git.

Thanks for all your help on this.

Carl





reply via email to

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