source file of the GNU LilyPond music typesetter
- (c) 2005--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
+ (c) 2005--2009 Han-Wen Nienhuys <hanwen@xs4all.nl>
*/
#include "grob-array.hh"
Grob_array::Grob_array ()
{
- ordered_ = false;
+ ordered_ = true;
}
vector<Grob*> &
grobs_.clear ();
}
+void
+Grob_array::remove_duplicates ()
+{
+ assert (!ordered_);
+
+ vector_sort (grobs_, less<Grob*> ());
+ ::uniq (grobs_);
+}
+
bool
Grob_array::empty () const
{
ga->add (unsmob_grob (scm_car (s)));
return arr_scm;
}
+