]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/include/misc.hh
Merge commit 'origin/dev/jneeman' into systems-per-page
[lilypond.git] / lily / include / misc.hh
index fad61b1ad381e33ddbdc3f164f08b0757935d6f6..12392c0cacd804dcee2db84c0e0aaec93ef0651a 100644 (file)
@@ -3,7 +3,7 @@
 
   source file of the GNU LilyPond music typesetter
 
-  (c) 2005--2007 Han-Wen Nienhuys <hanwen@xs4all.nl>
+  (c) 2005--2009 Han-Wen Nienhuys <hanwen@xs4all.nl>
 */
 
 #ifndef MISC_HH
@@ -28,6 +28,13 @@ sign (int i)
   else return 0;
 }
 
+inline int
+shift_left (int value, int shiftamount)
+{
+ if (shiftamount < 0) return (value >> -shiftamount); 
+  else return (value << shiftamount);
+}
+
 inline Real
 linear_interpolate (Real x, Real x1, Real x2, Real y1, Real y2)
 {