]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/spacing-engraver.cc
Issue 4376: Add LY_ASSERT_DERIVED_SMOB macro
[lilypond.git] / lily / spacing-engraver.cc
index b0d43ec8bb86fad20be2775b6430f71f1bdff72b..a8e21253e6ec6667af647a213069ce30e1a45ff3 100644 (file)
@@ -1,7 +1,7 @@
 /*
   This file is part of LilyPond, the GNU music typesetter.
 
-  Copyright (C) 1999--2014 Han-Wen Nienhuys <hanwen@xs4all.nl>
+  Copyright (C) 1999--2015 Han-Wen Nienhuys <hanwen@xs4all.nl>
 
   LilyPond is free software: you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published by
@@ -194,7 +194,7 @@ void
 Spacing_engraver::stop_translation_timestep ()
 {
   Paper_column *musical_column
-    = dynamic_cast<Paper_column *> (Grob::unsmob (get_property ("currentMusicalColumn")));
+    = derived_unsmob<Paper_column> (get_property ("currentMusicalColumn"));
 
   if (!spacing_)
     start_spanner ();
@@ -204,7 +204,7 @@ Spacing_engraver::stop_translation_timestep ()
   ->set_object ("spacing", spacing_->self_scm ());
 
   SCM proportional = get_property ("proportionalNotationDuration");
-  if (Moment::unsmob (proportional))
+  if (Moment::is_smob (proportional))
     {
       musical_column->set_property ("shortest-playing-duration", proportional);
       musical_column->set_property ("shortest-starter-duration", proportional);