]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/grob-pq-engraver.cc
Fix some bugs in the dynamic engraver and PostScript backend
[lilypond.git] / lily / grob-pq-engraver.cc
index 80d072b404fff458548a8ccb1b9b435f5bffbe7b..e4e8b944f968aefd5647185bc9f2ef21c87a560f 100644 (file)
@@ -15,14 +15,13 @@ struct Grob_pq_entry
 {
   Grob *grob_;
   Moment end_;
+  static int compare (Grob_pq_entry const &a,
+                     Grob_pq_entry const &b)
+  {
+    return Moment::compare (a.end_, b.end_);
+  }
 };
 
-bool
-operator< (Grob_pq_entry const &a, Grob_pq_entry const &b)
-{
-  return a.end_ < b.end_;
-}
-
 class Grob_pq_engraver : public Engraver
 {
 public:
@@ -96,7 +95,7 @@ Grob_pq_engraver::stop_translation_timestep ()
   while (scm_is_pair (busy) && *unsmob_moment (scm_caar (busy)) == now)
     busy = scm_cdr (busy);
 
-  vector_sort (started_now_, less<Grob_pq_entry> ());
+  vector_sort (started_now_, Grob_pq_entry::compare);
   SCM lst = SCM_EOL;
   SCM *tail = &lst;
   for (vsize i = 0; i < started_now_.size (); i++)