]> git.donarmstrong.com Git - lilypond.git/commitdiff
Issue 5125: Don't use SCM_CELL_WORD_1 internal
authorDavid Kastrup <dak@gnu.org>
Mon, 24 Apr 2017 18:38:51 +0000 (20:38 +0200)
committerDavid Kastrup <dak@gnu.org>
Wed, 3 May 2017 23:20:56 +0000 (01:20 +0200)
lily/duration.cc
lily/pitch.cc

index 0c6fa4dd5f55c89b5fe628276c04b47acc3f7cc4..880b22c46a3575d1fc37bf78943d45992ca1ba8b 100644 (file)
@@ -152,8 +152,8 @@ Duration::print_smob (SCM port, scm_print_state *) const
 SCM
 Duration::equal_p (SCM a, SCM b)
 {
-  Duration *p = (Duration *) SCM_CELL_WORD_1 (a);
-  Duration *q = (Duration *) SCM_CELL_WORD_1 (b);
+  Duration *p = unsmob<Duration> (a);
+  Duration *q = unsmob<Duration> (b);
 
   bool eq = p->dots_ == q->dots_
             && p->durlog_ == q->durlog_
index 9e46bba70e6ff1d2360a66292427f312b4b5f5c8..ee03ac44d8db2e53a782e0732acb766e23b6914a 100644 (file)
@@ -238,8 +238,8 @@ Pitch::print_smob (SCM port, scm_print_state *) const
 SCM
 Pitch::equal_p (SCM a, SCM b)
 {
-  Pitch *p = (Pitch *) SCM_CELL_WORD_1 (a);
-  Pitch *q = (Pitch *) SCM_CELL_WORD_1 (b);
+  Pitch *p = unsmob<Pitch> (a);
+  Pitch *q = unsmob<Pitch> (b);
 
   bool eq = p->notename_ == q->notename_
             && p->octave_ == q->octave_