]> git.donarmstrong.com Git - lilypond.git/blobdiff - flower/include/real.hh
Only set commandColumn in NoteSpacing if no right-item was encountered.
[lilypond.git] / flower / include / real.hh
index 73131dd7d3a0a510e62b8cb7492ba7d811313b28..5d8457e42a84cc32e6e35cd02f82c6324c41e0e4 100644 (file)
@@ -3,51 +3,51 @@
 
   source file of the Flower Library
 
-  (c)  1997--2000 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+  (c) 1997--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
 */
 
-
 #ifndef REAL_HH
 #define REAL_HH
 
+#include <algorithm>
+#include <climits>
+
+/*
+  MacOS 10.3 uses g++ 3.3 which doesn't have isinf()
+ */
+// #include <cmath>
+#include <math.h>
+using namespace std;
 
-#include <limits.h>
 
 typedef double Real;
 extern const Real infinity_f;
 
+/* namespace std { */
+  
 template<class T> inline T abs (T x)
 {
   return x > 0 ? x : -x;
 }
 
-template<class T> inline int sign (T x)
-{
-  if (x)
-    return x > T(0) ? 1 : -1;
-  return 0;
-}
+/* } namespace std */
 
-template<class T> inline T max (T x, T y)
-{
-  return x >? y;
-}
-
-template<class T> inline T sqr (T x)
+inline Real
+distance (Real x, Real y)
 {
-  return x*x;
+  return abs (x - y);
 }
 
-
-template<class T> inline T min (T x, T y)
+template<class T> inline int sign (T x)
 {
-  return x <? y;
+  if (x)
+    return x > T (0) ? 1 : -1;
+  return 0;
 }
 
-inline Real
-distance (Real x,Real y)
+template<class T> inline T sqr (T x)
 {
-    return abs (x-y);
+  return x * x;
 }
 
 #endif