2 moment.hh -- declare Moment
4 source file of the GNU LilyPond music typesetter
6 (c) 1999--2000 Han-Wen Nienhuys <hanwen@cs.uu.nl>
14 #include "rational.hh"
17 Rationals with glue for Guilification;
19 FIXME: remove self_scm_ and then remove this class */
20 struct Moment : public Rational
22 Moment () { self_scm_ = SCM_EOL; }
23 Moment (int m) : Rational (m) {self_scm_ = SCM_EOL; }
24 Moment (int m, int n) : Rational (m,n) {self_scm_ = SCM_EOL; }
25 Moment (Rational m) : Rational (m) {self_scm_ = SCM_EOL; }
31 SCM smobify (Moment*);
32 Moment * unsmob_moment (SCM);
34 IMPLEMENT_ARITHMETIC_OPERATOR (Moment, / );
35 IMPLEMENT_ARITHMETIC_OPERATOR (Moment, + );
36 IMPLEMENT_ARITHMETIC_OPERATOR (Moment, * );
37 IMPLEMENT_ARITHMETIC_OPERATOR (Moment, - );
38 IMPLEMENT_ARITHMETIC_OPERATOR (Moment, % );
40 INSTANTIATE_COMPARE (Moment const&, Rational::compare);
44 A really big time-moment.
46 Windhoze-suck-suck-suck-suck-suck-thank-you-cygnus
48 I get tired of all these incompatibilities. Let's just assume that
49 INT_MAX is really, really, really big.
51 Can't we name this Saint_jut_mom (Sintjuttemis ?) */
53 /* URG ! WE HAVE TWO RATIONAL INFINITIES! */
54 const Moment infinity_mom = INT_MAX;
56 #endif /* MOMENT_HH */