X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=lily%2Fprob.cc;h=d05a33e4f3aa60387ad40a612deaf01a6d952a54;hb=5d84bfad4626892bcffd05adcced53c8a2329047;hp=37dad6246b34a00b2e0d3019ef0322849168ce85;hpb=e0af94bb8939bc6f4998db6294010baa77139092;p=lilypond.git diff --git a/lily/prob.cc b/lily/prob.cc index 37dad6246b..d05a33e4f3 100644 --- a/lily/prob.cc +++ b/lily/prob.cc @@ -24,7 +24,7 @@ #include "profile.hh" -const char Prob::type_p_name_[] = "ly:prob?"; +const char * const Prob::type_p_name_ = "ly:prob?"; SCM Prob::equal_p (SCM sa, SCM sb) @@ -36,7 +36,7 @@ Prob::equal_p (SCM sa, SCM sb) equality; e.g., that two probs are equal iff they can be distinguished by calls to ly:prob-property. */ - Prob *probs[2] = {Prob::unsmob (sa), Prob::unsmob (sb)}; + Prob *probs[2] = {unsmob (sa), unsmob (sb)}; SCM props[2][2]; int i; @@ -62,7 +62,7 @@ Prob::equal_p (SCM sa, SCM sb) SCM aval = scm_cdar (aprop); SCM bval = scm_cdar (bprop); if (!scm_is_eq (scm_caar (aprop), scm_caar (bprop)) - || (!(Input::is_smob (aval) && Input::is_smob (bval)) + || (!(unsmob (aval) && unsmob (bval)) && !ly_is_equal (aval, bval))) return SCM_BOOL_F; } @@ -113,7 +113,7 @@ Prob::derived_mark () const } SCM -Prob::mark_smob () +Prob::mark_smob () const { ASSERT_LIVE_IS_ALLOWED (self_scm ()); @@ -124,7 +124,7 @@ Prob::mark_smob () } int -Prob::print_smob (SCM port, scm_print_state *) +Prob::print_smob (SCM port, scm_print_state *) const { scm_puts ("#<", port); scm_puts ("Prob: ", port); @@ -141,7 +141,7 @@ Prob::print_smob (SCM port, scm_print_state *) SCM Prob::internal_get_property (SCM sym) const { -#ifndef NDEBUG +#ifdef DEBUG if (profile_property_accesses) note_property_access (&prob_property_lookup_table, sym); #endif @@ -192,5 +192,5 @@ Prob::name () const if (scm_is_symbol (nm)) return ly_symbol2string (nm); else - return this->class_name (); + return class_name (); }