lilypond-user
[Top][All Lists]
Advanced

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

Re: error handling


From: Jean Abou Samra
Subject: Re: error handling
Date: Tue, 5 Jul 2022 00:34:56 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.11.0

On 7/5/22 00:22, Thomas Morley wrote:
Currently I'm doing some huge scheme-coding.

Again and again I get error messages like:

$ lilydevel event-chords.ly
GNU LilyPond 2.23.9 (running Guile 2.2)
[...]
Processing `event-chords.ly'
Parsing...srfi/srfi-1.scm:432:2: In procedure last:
In procedure car: Wrong type argument in position 1 (expecting pair): ()

This is a SHITTY message!


Agreed, I've been annoyed by this too. We have a real problem
here.


For now I switch back to a guile-1 version where I get:

$ lilypond event-chords.ly
GNU LilyPond 2.22.1
Processing `event-chords.ly'
Parsing...../zither-tab-functions.ly:129:29: In procedure last in
expression (map last v-r-m-elts-raw):
../zither-tab-functions.ly:129:29: Wrong type argument in position 1
(expecting pair): ()

That's an error message, helpful and pointing to the problem.

Alas, it's easy to predict I'll use features not available in older versions.
What to do then?

Looking through srfi/srfi-1.scm? Ok, bullshit. (statement just for fun LOL)
Looking through hundreds of code lines?
Really? Even using advanced searching features ...
Really?

Any hope it will improve?


Yes. We should be using compile rather than primitive-eval to run Scheme
code. But before that we need to check the performance impact, and
possibly that will reveal we need to hide it behind an option. And we
need to check that this behaves the same w.r.t. modules, which are a
complicated grey area that also changed in Guile 2. And to find a way
to have line numbers make sense; last time I looked, the Overlay_string_port
hack didn't work anymore for some reason.

In short: there's a fair bit of work to be done. The problem is actually
tracked in https://gitlab.com/lilypond/lilypond/-/issues/5992

Jean




reply via email to

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