On Fri, Aug 28, 2009 at 7:29 AM, Reinhold Kainhofer<reinh...@kainhofer.com> wrote:
>> - get_property_setting() should take SCMs rather than const char* , so >> you save runtime lookups. > > I don't exactly understand what you mean by this... The two parameters of > get_property_setting are passed on the get_property, which call > internal_get_property (symbol2scm (...)) on them. Of course, I could do the > symbol2scm before calling get_property_setting and then call > internal_get_property there, but I don't see how this will save anything (in > particular, since the context property names will be dynamically built from > the start_type: (start_type + "Text").c_str () > > The only thing that might be optimized is the fixed-name event properties. But > that saves one symbol2scm call for hairpins and two for text crescendi. Is > this really worth the trouble of handling the two property names differently > to > save on symbol2scm call? Sorry - I only took a brief look. It might not be worth the trouble in this case, but in general it is better for the C++ part to work with SCMs, so the symbol lookups can be memoized in the caller. -- Han-Wen Nienhuys - han...@xs4all.nl - http://www.xs4all.nl/~hanwen _______________________________________________ lilypond-devel mailing list lilypond-devel@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-devel