]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/include/moment.hh
release: 1.3.74
[lilypond.git] / lily / include / moment.hh
index 53942657fc730b019e072a7853af0506617ee083..0bd535a6d5c7c9d5edd6174b626c53fdbf227958 100644 (file)
@@ -3,7 +3,7 @@
   
   source file of the GNU LilyPond music typesetter
   
-  (c) 1999 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+  (c) 1999--2000 Han-Wen Nienhuys <hanwen@cs.uu.nl>
   
  */
 
 
 /**
    Rationals with glue for Guilification;
- */
-struct Moment : public Rational
+
+   FIXME: remove self_scm_ and then remove this class */
+class Moment : public Rational
 {
-  Moment () { self_scm_ = SCM_EOL; }
-  Moment (int m) : Rational (m) {self_scm_ = SCM_EOL; }
-  Moment (int m, int n) : Rational (m,n) {self_scm_ = SCM_EOL; }
-  Moment (Rational m) : Rational (m) {self_scm_ = SCM_EOL; }
-  ~Moment ();
-  
-  DECLARE_SMOBS;
+  DECLARE_SIMPLE_SMOBS(Moment,);
+public:
+  Moment () { }
+  Moment (int m) : Rational (m) { }
+  Moment (int m, int n) : Rational (m,n) { }
+  Moment (Rational m) : Rational (m) { }
+
+  /*
+    Deliver a copy of THIS as a smobified SCM
+   */
+  SCM make_scm () const; 
 };
 
+
+Moment * unsmob_moment (SCM);
+
 IMPLEMENT_ARITHMETIC_OPERATOR (Moment, / );
 IMPLEMENT_ARITHMETIC_OPERATOR (Moment, + );
 IMPLEMENT_ARITHMETIC_OPERATOR (Moment, * );