[Top][All Lists]

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

Re: The life of a Grob

From: Han-Wen Nienhuys
Subject: Re: The life of a Grob
Date: Sun, 17 Sep 2006 01:20:01 +0200
User-agent: Thunderbird (X11/20060913)

Joe Neeman wrote:
On Sat, 2006-09-16 at 16:29 +0200, Han-Wen Nienhuys wrote:
Some comments:

* can you add another macro layer, so __LINE__ and __FILE__ aren't sprinkled around in the code? For good measure, you could also add __FUNCTION__ .
How about something like the attached patch? I "overload" get_property
so that it can take a SCM directly. Then I can replace every
internal_get_property with get_property.

Clever! This means that we can do away with the whole internal_FOO business, right? (also for some other functions, I expect.)
Can you prepare a patch that removes all the internal_XXX  ?

+  protect ();
+  if (ly_is_procedure (modification_callback))
+      scm_apply_0 (modification_callback,
+                  scm_list_n (self_scm (), scm_makfrom0str (file), 
scm_from_int (line),
+                              sym, v, SCM_UNDEFINED));
+  unprotect ();
this protection should not be necessary: as self_scm is passed as Stack variable it will be GC protected.

I was getting segfaults in scm_gc_mark and this magically solved it.
Being in dirty hack mode, I didn't investigate further. But you're

ok, but to get this in lily, we have to get it out of dirty hack mode.


Han-Wen Nienhuys - address@hidden -

LilyPond Software Design
 -- Code for Music Notation

reply via email to

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