]> git.donarmstrong.com Git - lilypond.git/commitdiff
lilypond-0.0.23
authorfred <fred>
Sun, 24 Mar 2002 19:27:55 +0000 (19:27 +0000)
committerfred <fred>
Sun, 24 Mar 2002 19:27:55 +0000 (19:27 +0000)
src/voice.cc

index f4372893afa62993b60ccb7a1faf5a2ddaa8996f..334d1b4a5f6b5c2bce0adc89ac4a11eca5a71258 100644 (file)
@@ -27,17 +27,20 @@ Voice::print() const
 {
 #ifndef NPRINT
     mtor << "start: "<< start<<eol;
-    for (iter_top(elts,vec); vec.ok(); vec++)
-       vec->print();
+    for (iter_top(elts,i); i.ok(); i++)
+       i->print();
 #endif
 }
 
 Moment
 Voice::last() const
 {
-    Moment l =start;
-    for (iter_top(elts,vec); vec.ok(); vec++)
-       l  += vec->duration;
+    Moment l =0;
+    if (elts.size())
+       l = start;
+    
+    for (iter_top(elts,i); i.ok(); i++)
+       l  += i->duration;
     return l;
 }
 /****************************************************************/