From: fred Date: Wed, 27 Mar 2002 02:04:58 +0000 (+0000) Subject: lilypond-1.5.28 X-Git-Tag: release/1.5.59~361 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=410ba38944a01f157f796d00b613ee0e6140c4e1;p=lilypond.git lilypond-1.5.28 --- diff --git a/lily/include/lily-guile.hh b/lily/include/lily-guile.hh index 7788833f4b..79bf4ca69e 100644 --- a/lily/include/lily-guile.hh +++ b/lily/include/lily-guile.hh @@ -101,9 +101,6 @@ SCM ly_truncate_list (int k, SCM l ); #endif -#ifdef CACHE_SYMBOLS - - /* We don't use gh_symbol2scm directly, since it has const-correctness problems in GUILE 1.3.4 @@ -111,6 +108,9 @@ SCM ly_truncate_list (int k, SCM l ); */ SCM my_gh_symbol2scm (const char* x); +#ifdef CACHE_SYMBOLS + + /* Using this trick we cache the value of gh_symbol2scm ("fooo") where "fooo" is a constant string. This is done at the cost of one static @@ -129,7 +129,7 @@ SCM my_gh_symbol2scm (const char* x); value = gh_symbol2scm ((char*) (x)); \ value; }) #else -inline SCM ly_symbol2scm(char const* x) { return gh_symbol2scm((x)); } +inline SCM ly_symbol2scm(char const* x) { return my_gh_symbol2scm((x)); } #endif