X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=lily%2Finclude%2Fduration.hh;h=303fecbeffcb8f97eeaf2e19162196807e418967;hb=cb0b407e567feca71cbc5f9479a06b266c69a26c;hp=aa9f66e01656dc119c2be5ca070cd565d405f936;hpb=a6bd229f7fe1dc4a03478e14ccc0c0c66b225061;p=lilypond.git diff --git a/lily/include/duration.hh b/lily/include/duration.hh index aa9f66e016..303fecbeff 100644 --- a/lily/include/duration.hh +++ b/lily/include/duration.hh @@ -1,7 +1,7 @@ /* This file is part of LilyPond, the GNU music typesetter. - Copyright (C) 1997--2010 Jan Nieuwenhuizen + Copyright (C) 1997--2015 Jan Nieuwenhuizen LilyPond is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -25,14 +25,15 @@ /** A musical duration. */ -struct Duration +struct Duration : public Simple_smob { -public: - + static SCM equal_p (SCM, SCM); + int print_smob (SCM, scm_print_state *) const; + static const char type_p_name_[]; Duration (); Duration (int, int); Duration (Rational, bool scale); - string to_string () const; + std::string to_string () const; Duration compressed (Rational) const; Rational get_length () const; @@ -43,7 +44,6 @@ public: static int compare (Duration const &, Duration const &); DECLARE_SCHEME_CALLBACK (less_p, (SCM a, SCM b)); - DECLARE_SIMPLE_SMOBS (Duration); private: /// Logarithm of the base duration. @@ -54,7 +54,7 @@ private: }; INSTANTIATE_COMPARE (Duration, Duration::compare); -DECLARE_UNSMOB (Duration, duration); -#endif // DURATION_HH +extern SCM Duration_type_p_proc; +#endif // DURATION_HH