lilypond-user
[Top][All Lists]
Advanced

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

Re: Attach a debugger to LilyPond


From: Urs Liska
Subject: Re: Attach a debugger to LilyPond
Date: Wed, 25 Sep 2019 16:31:14 +0000

Hi Andrew, 

thanks for the comments.

25. September 2019 11:30, "Andrew Bernard" <address@hidden> schrieb:

> Hi Urs,
> 
> I am the most ignorant of all when it comes to lilypond internal 
> processing, but I recall in the past when I have tried to put diagnostic 
> print statements in Scheme inside music functions that they come out of 
> order sometimes in unpredictable ways. I recall DK pointing out that the 
> function in question for that one operation gets called repeatedly as 
> the code is parsed and compiled and the layout engine does its passes 
> and print statements don't therefore work in a nice straightforward 
> linear order, and can be very misleading. I may have the details wrong 
> here, and I cant remember the specific problem I was using the function 
> for, but I mention this to say that debugging Scheme inside Frescobaldi 
> may be fraught with deep complexity. I don't know, but I would be 
> worried. I'd like for somebody enlightened in these matters to comment. 
> [I am happy for this to be dismissed as nonsense!]

I *think* what you're referring to is the fact that when you do print debugging 
with Scheme's "display" or related functions their output will come much later 
than anticipated. OTOH if you issue ly:message (and related procedures) the 
printing will be done immediately and is definitely sufficient for print 
debugging.

However, this is of course unrelated to an actual debugger with the idea of 
stepping through the code of a LilyPond input file, and any information would 
be appreciated.

Urs

> 
> Andrew
> 
> On 25/9/19 4:23 pm, Urs Liska wrote:
> 
>> a question on the Frescobaldi mailing list got me thinking: is it possible 
>> (or could it be made
>> possible with reasonable effort) to attach a debugger to a LilyPond 
>> compilation process?
>> 
>> Probably there would be quite some managing to be done because there's no 
>> simple relation of code
>> steps like in a programming language, but if the LilyPond parser (or the 
>> Scheme parser) could be
>> hooked into it would be terrific if we could make Frescobaldi step through 
>> the input files (or
>> probably one would rather want to set a breakpoint, e.g. in a music function 
>> and then step through
>> that function to better understand what it's doing).
> 
> _______________________________________________
> lilypond-user mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/lilypond-user



reply via email to

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