]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/folded-repeat-iterator.cc
(LY_DEFINE): remove Protected_scm global variable.
[lilypond.git] / lily / folded-repeat-iterator.cc
index 3963c5dd4b719b9407cd4854eb103d93a53be04f..17ef87275e1dc2d17342e8326790760253c9321d 100644 (file)
@@ -3,7 +3,7 @@
 
   source file of the GNU LilyPond music typesetter
 
-  (c) 1999--2005 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+  (c) 1999--2005 Han-Wen Nienhuys <hanwen@xs4all.nl>
 */
 
 #include "folded-repeat-iterator.hh"
@@ -35,9 +35,7 @@ Moment
 Folded_repeat_iterator::pending_moment () const
 {
   if (main_iter_)
-    {
-      return main_iter_->pending_moment ();
-    }
+    return main_iter_->pending_moment ();
   else
     return main_length_mom_ + alternative_iter_->pending_moment ();
 }
@@ -72,9 +70,7 @@ Folded_repeat_iterator::process (Moment m)
     }
 
   if (!main_iter_ && !alternative_iter_)
-    {
-      enter_alternative ();
-    }
+    enter_alternative ();
 
   if (alternative_iter_)
     {
@@ -113,7 +109,7 @@ Folded_repeat_iterator::enter_alternative ()
       alternative_iter_ = s;
       alternative_iter_->construct_children ();
 
-      scm_gc_unprotect_object (s->self_scm ());
+      s->unprotect ();
     }
 }
 
@@ -121,9 +117,7 @@ Music_iterator *
 Folded_repeat_iterator::try_music_in_children (Music *m) const
 {
   if (main_iter_)
-    {
-      return main_iter_->try_music (m);
-    }
+    return main_iter_->try_music (m);
   if (alternative_iter_)
     return alternative_iter_->try_music (m);
   return 0;