]> git.donarmstrong.com Git - lilypond.git/commitdiff
* lily/tie-column.cc (set_manual_tie_configuration): new function.
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Mon, 12 Sep 2005 12:46:49 +0000 (12:46 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Mon, 12 Sep 2005 12:46:49 +0000 (12:46 +0000)
* lily/laissez-vibrer-tie.cc: new file.

* lily/tie-column.cc (set_tie_config_directions): new function
(final_shape_adjustment): new function.
(shift_small_ties): new function.

* lily/tie-column.cc (set_chord_outline): new function.

147 files changed:
ChangeLog
Documentation/topdocs/NEWS.tely
VERSION
flower/file-cookie.cc
flower/file-name.cc
flower/file-path.cc
flower/getopt-long.cc
flower/include/array.hh
flower/include/array.icc
flower/include/axis.hh
flower/include/compare.hh
flower/include/cons.hh
flower/include/cpu-timer.hh
flower/include/file-cookie.hh
flower/include/flower-proto.hh
flower/include/getopt-long.hh
flower/include/interval.tcc
flower/include/libc-extension.hh
flower/include/memory-stream.hh
flower/include/parse-afm.hh
flower/include/real.hh
flower/include/string-convert.hh
flower/include/string-data.icc
flower/include/string-handle.icc
flower/include/string.hh
flower/include/virtual-methods.hh
flower/libc-extension.cc
flower/memory-stream.cc
flower/offset.cc
flower/parse-afm.cc
flower/polynomial.cc
flower/rational.cc
flower/real.cc
flower/rtti.cc
flower/string-convert.cc
flower/string.cc
flower/stringutil.cc
flower/warn.cc
lily/accidental-engraver.cc
lily/accidental-placement.cc
lily/afm.cc
lily/align-interface.cc
lily/bar-line.cc
lily/beam-concave.cc
lily/beam-quanting.cc
lily/beam.cc
lily/bezier-bow.cc
lily/bezier.cc
lily/binary-source-file.cc
lily/book.cc
lily/break-align-interface.cc
lily/break-substitution.cc
lily/clef-engraver.cc
lily/cluster.cc
lily/completion-note-heads-engraver.cc
lily/custos.cc
lily/dimension-cache.cc
lily/dot-column.cc
lily/drum-note-engraver.cc
lily/easy-notation.cc
lily/file-name-map.cc
lily/font-metric.cc
lily/font-select.cc
lily/function-documentation.cc
lily/general-scheme.cc
lily/global-context.cc
lily/gourlay-breaking.cc
lily/grob-property.cc
lily/grob.cc
lily/includable-lexer.cc
lily/include/afm.hh
lily/include/context.hh
lily/include/includable-lexer.hh
lily/include/midi-stream.hh
lily/include/misc.hh
lily/include/moment.hh
lily/include/object-key-dumper.hh
lily/include/object-key-undumper.hh
lily/include/open-type-font.hh
lily/include/source-file.hh
lily/include/stencil.hh
lily/include/stream.hh
lily/include/tweak-registration.hh
lily/input.cc
lily/keyword.cc
lily/least-squares.cc
lily/ledger-line-spanner.cc
lily/lexer.ll
lily/lily-guile.cc
lily/lily-lexer.cc
lily/line-spanner.cc
lily/lookup.cc
lily/lyric-extender.cc
lily/lyric-hyphen.cc
lily/main.cc
lily/mark-engraver.cc
lily/mensural-ligature.cc
lily/metronome-engraver.cc
lily/midi-def.cc
lily/midi-stream.cc
lily/misc.cc
lily/modified-font-metric.cc
lily/moment.cc
lily/music-iterator.cc
lily/note-collision.cc
lily/note-column.cc
lily/note-head.cc
lily/note-heads-engraver.cc
lily/open-type-font.cc
lily/pango-select.cc
lily/paper-outputter.cc
lily/parse-scm.cc
lily/parser.yy
lily/percent-repeat-item.cc
lily/performance.cc
lily/pfb.cc
lily/program-option.cc
lily/rest-collision.cc
lily/scm-hash.cc
lily/score.cc
lily/side-position-interface.cc
lily/simple-spacer-scheme.cc
lily/simple-spacer.cc
lily/slur-configuration.cc
lily/slur-scoring.cc
lily/slur.cc
lily/source-file.cc
lily/spaceable-grob.cc
lily/spacing-spanner.cc
lily/spanner.cc
lily/staff-spacing.cc
lily/staff-symbol-referencer.cc
lily/stem.cc
lily/stencil-scheme.cc
lily/stencil.cc
lily/system-start-delimiter.cc
lily/system.cc
lily/tab-note-heads-engraver.cc
lily/text-interface.cc
lily/tie-column.cc
lily/tie-helper.cc
lily/tie.cc
lily/tuplet-bracket.cc
lily/vaticana-ligature.cc
lily/volta-bracket.cc
python/midi.c
stepmake/stepmake/c++-vars.make

index ad9d55db976f86dafcf38b83548b0f547082943a..50086508d9f27be42d57ee1e2041051a65d9de45 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
 
 2005-09-08  Jan Nieuwenhuizen  <janneke@gnu.org>
 
+       * Documentation/user/lilypond.tely: Spell Baßtuba in UTF-8 (Werner). 
+
+       * lily, flower: Include C++ iso C headers.  Import namespace std
+       throughout.
+
+       * lily/side-position-interface.cc: 
+       * lily/scm-hash.cc: 
+       * lily/note-head.cc: 
+       * lily/include/includable-lexer.hh: 
+       * flower/include/string-data.icc: Remove using std::*.
+
+       * lily, flower: Include C++ iso C headers.  Import namespace std
+       throughout.
+
+       * lily/side-position-interface.cc: 
+       * lily/scm-hash.cc: 
+       * lily/note-head.cc: 
+       * lily/include/includable-lexer.hh: 
+       * flower/include/string-data.icc: Remove using std::*.
+
        * Documentation/user/instrument-notation.itely (Entering lyrics):
        Multiple latin-1->utf-8 conversion fix.
 
index 84d3c63bc8a466f8398af5240861048e1cee477d..0d655dda0a16214a6627d32cc6b7af0b2c233529 100644 (file)
@@ -1,4 +1,4 @@
-\input texinfo @c -*-texinfo-*-
+\input texinfo @c -*- coding: utf-8; mode: texinfo; -*-
 @setfilename NEWS.info
 @settitle NEWS
 
@@ -90,7 +90,7 @@ specify tie formatting
 
 This improvement has been sponsored by Bertalan Fodor, Jay Hamilton,
 Kieren MacMillan, Steve Doonan, Trevor Baca, and Vicente Solsona
-Dellá.
+Dell¡.
 
 @item
 Formatting of isolated, single ties has been improved. Now, ties avoid
@@ -106,7 +106,7 @@ staff lines, flags and dots, without compromising their shape.
 
 This improvement has been sponsored by Bertalan Fodor, Jay Hamilton,
 Kieren MacMillan, Steve Doonan, Trevor Baca, and Vicente Solsona
-Dellá.
+Dell¡.
  
 
 @item  @textanchor{repeat-counter}
@@ -251,7 +251,9 @@ Nested tuplets are automatically positioned,
 }
 @end lilypond
 
-This feature was sponsored by Trevor Baca.
+@c This feature was sponsored by Trevor Baca.
+@c where does this fail?
+This feature was sponsored by Trevor Bača.
 
 @item
 Music expressions can be displayed, in LilyPond notation, using the
diff --git a/VERSION b/VERSION
index ce8dc973f6ece76b759b4211c0190a6212a0878f..b539d4a30cdae6fd3a4aeed0f7197191f002bee0 100644 (file)
--- a/VERSION
+++ b/VERSION
@@ -2,5 +2,5 @@ PACKAGE_NAME=LilyPond
 MAJOR_VERSION=2
 MINOR_VERSION=7
 PATCH_LEVEL=10
-MY_PATCH_LEVEL=
+MY_PATCH_LEVEL=namespace
 
index c173b087bcbb664ea28d19a14050e82b4f7d5beb..8f4c9c4f85be8372c6407808090d7c38bc54a6f1 100644 (file)
@@ -1,6 +1,7 @@
 
-#include <assert.h>
+#include <cassert>
 #include <cstdio>
+using namespace std;
 
 #include "memory-stream.hh"
 
index af0cac2c2c2c0553689d2f9eb2dfcaf9fe4982bd..b29307814513ccca6d0150a8203eb56482422000 100644 (file)
@@ -11,6 +11,7 @@
 
 #include <cstdio>
 #include <cerrno>
+using namespace std;
 
 #include "config.hh"
 
index d15c92caf4ca18a4bc9b548cab84612300002d19..c66909eae37de55333548cde84a50f414fe9d24c 100644 (file)
@@ -11,6 +11,7 @@
 
 #include <cstdio>
 #include <cerrno>
+using namespace std;
 
 #include "config.hh"
 #if HAVE_SYS_STAT_H
index dd74d8aff7a1d873cefa6a8c50b198a4aac1417a..31cab7a22d8a97429a0f5bc5d74e9a96c142fa02 100644 (file)
@@ -11,6 +11,7 @@
 #include <cstdlib>
 
 #include <iostream>
+using namespace std;
 
 #include "config.hh"
 #include "string-convert.hh"
index 938b1c0ce8554852390bc01dc61f8235e20cb0f6..4f2c3c3d0f425b02744ec32c51c8b17c546c0299 100644 (file)
@@ -3,10 +3,11 @@
 
   Distributed under GNU GPL
 */
-
 #ifndef ARRAY_H
 #define ARRAY_H
+
 #include <cassert>
+using namespace std;
 
 #ifndef INLINE
 #define INLINE inline
index f5ccafee74e866d540d927d211cb4ef821e3c3d6..a3b0c1af87b087749a4330c5cbed235a0a3d2b14 100644 (file)
@@ -80,7 +80,8 @@ void
 Array<T>::OK () const
 {
   assert (max_ >= size_ && size_ >= 0);
-  if (max_) assert (array_);
+  if (max_)
+    assert (array_);
 }
 
 template<class T> INLINE
index bafd572cb67cd906a45f0ddb30dd4e376ce170a1..f0ffb4187094d1a8bb397adc6823d3b9c0e20055 100644 (file)
@@ -10,6 +10,7 @@
 #define AXES_HH
 
 #include <cassert>
+using namespace std;
 
 enum Axis
   {
index a0d7ed98fa97cd122214f02b05d1b0bd2072a0b2..891f040f489b5347dfef75a4cd1a04bc1817f1e0 100644 (file)
     prefix ONE_OPERATOR (type, function, !=)                           \
     prefix ONE_OPERATOR (type, function, <)                            \
     prefix ONE_OPERATOR (type, function, <=)                           \
+    /* namespace std { */                                              \
     prefix inline type max (type t1, type t2) { return (t1 > t2) ? t1 : t2; } \
-  prefix inline type min (type t1, type t2) { return (t1 < t2) ? t1 : t2; } \
-                                                                       \
-  prefix bool operator < (type t1, type t2) /* stupid fix to allow ; */
+    prefix inline type min (type t1, type t2) { return (t1 < t2) ? t1 : t2; } \
+  /* } */                                                              \
+  /* stupid fix to allow ; */                                          \
+  prefix bool operator < (type t1, type t2)
 
 #define INSTANTIATE_COMPARE(type, func) TEMPLATE_INSTANTIATE_COMPARE (type, func,)
 
index 5f7238173b7059b43601ae2fa06e67437ff0f69a..cb63fd2e2f878aef51b0e444bd062e3d2da78c84 100644 (file)
@@ -10,6 +10,7 @@
 #define CONS_HH
 
 #include <cassert>
+using namespace std;
 
 template<class T>
 class Cons
index 47aae73f04d8c57142077cf709b9880a6f8f1ae3..eb9dc211652ab15ab9abb3a7b3d2abec8581a841 100644 (file)
@@ -10,6 +10,7 @@
 #define CPU_TIMER_HH
 
 #include <ctime>
+using namespace std;
 
 #include "real.hh"
 
index 3945df90ed12bd2971f08cafaa47d4954e517b5e..ab163ea3eb3d8c20ef7b1680de936424c0880510 100644 (file)
@@ -2,9 +2,12 @@
 extern "C" {
 #endif
 
-#include <stdio.h>
 #include <unistd.h>
 
+#include <cstdio>
+using namespace std;
+
+
 #if (! defined (__off64_t) && ! defined (__off64_t_defined)) || ! defined (__cplusplus)
 #define off64_t unsigned long long
 #endif
index 0b16ff11d303e56dd342cfa2c9cd7e143e763051..9b9d6a8b3961e5a5347a258d1b1b58531068677c 100644 (file)
@@ -5,8 +5,8 @@
   (c) 1996--2005 Han-Wen Nienhuys
 */
 
-#ifndef FPROTO_HH
-#define FPROTO_HH
+#ifndef FLOWER_PROTO_HH
+#define FLOWER_PROTO_HH
 
 char const *flower_version_str0 ();
 
@@ -57,5 +57,4 @@ struct File_storage;
 struct Mapped_file_storage;
 struct Simple_file_storage;
 
-#endif // FPROTO_HH
-
+#endif /* FLOWER_PROTO_HH */
index 92f305dd84a921c1a3dcf621877d8545c4dbdc03..c186ce85bb4906f24bfb4c25c751d3b06ee3774a 100644 (file)
@@ -2,6 +2,7 @@
 #define GETOPT_LONG_HH
 
 #include <cstdio>
+using namespace std;
 
 #include "string.hh"
 
index 3cee682cbc4c06c8f9ee3a9b33cc91ca468ee4a2..0ac8de264fba7a8a9353652405b248a4e33fc7d8 100644 (file)
@@ -11,6 +11,7 @@
 
 #include <cassert>
 #include <cmath>
+using namespace std;
 
 #include "interval.hh"
 #include "string.hh"
index ff85fef84101b280a3a242564723b12f20e676ed..abf5a549d1a68bf5888834da3277122adb4e6495 100644 (file)
@@ -9,8 +9,9 @@
 #ifndef LIBC_EXTENSION_HH
 #define LIBC_EXTENSION_HH
 
-#include <stddef.h>
-#include <stdarg.h>
+#include <cstddef>
+#include <cstdarg>
+using namespace std;
 
 #include "config.hh"
 
@@ -22,6 +23,18 @@ void *memmem (void const *haystack, int haystack_len,
              void const *needle, int needle_len);
 #endif /* HAVE_MEMMEM */
 
+#if ! HAVE_MEMRCHR
+unsigned char *memrchr (unsigned char const *p, int n, char c);
+#endif
+
+#if ! HAVE_MEMREV
+unsigned char *memrev (unsigned char *byte, int length_i);
+#endif
+
+double my_round (double);
+
+/* namespace std { */
+  
 #if ! HAVE_SNPRINTF            /* GNU extension. */
 int snprintf (char *str, size_t n, char const *format, ...);
 #endif
@@ -36,14 +49,6 @@ int isinf (double x);
 #endif
 #endif
 
-#if ! HAVE_MEMRCHR
-unsigned char *memrchr (unsigned char const *p, int n, char c);
-#endif
-
-#if ! HAVE_MEMREV
-unsigned char *memrev (unsigned char *byte, int length_i);
-#endif
-
-double my_round (double);
+/* }; */
 
 #endif /* LIBC_EXTENSION_HH */
index c082a2397249cd54a71dc223c5c8105a9dd26219..6d29e091feae326bbf40fff6bb00a9841b883fcf 100644 (file)
@@ -9,8 +9,9 @@
 #ifndef MEMORY_STREAM_HH
 #define MEMORY_STREAM_HH
 
-#include <stdio.h>
+#include <cstdio>
 #include <unistd.h>
+using namespace std;
 
 #include "libc-extension.hh"
 #include "file-cookie.hh"
index 3003339ee9594962c73ff28a6e070e9f46cf5bb7..074e98e8e1335bfafa279ee8bca35e7f58ccaac8 100644 (file)
@@ -80,6 +80,7 @@
  */
 
 #include <cstdio>
+using namespace std;
 
 #define BOOL int
 #define FLAGS int
index f4248f5d2fa8a2e26fedecd07c6104ddd7ee9c91..598c35199a5c095824dcc3fd399bd82f91211d90 100644 (file)
 #include <algorithm>
 #include <climits>
 #include <cmath>
+using namespace std;
+
 
 typedef double Real;
 extern const Real infinity_f;
-using namespace std;
-using std::isnan;
-using std::isinf;
-using std::fabs;
 
+/* namespace std { */
+  
 template<class T> inline T abs (T x)
 {
   return x > 0 ? x : -x;
 }
 
+/* } namespace std */
+
+inline Real
+distance (Real x, Real y)
+{
+  return abs (x - y);
+}
+
 template<class T> inline int sign (T x)
 {
   if (x)
@@ -37,10 +45,4 @@ template<class T> inline T sqr (T x)
   return x * x;
 }
 
-inline Real
-distance (Real x, Real y)
-{
-  return abs (x - y);
-}
-
 #endif
index 8a694742dcc3228677242d2ace095a53be426c88..5bc8a7dd56604738a92bf9524d146705a1443e10 100644 (file)
@@ -7,6 +7,7 @@
 #define STRING_CONVERT_HH
 
 #include <cstdarg>
+using namespace std;
 
 #include "string.hh"
 
index a87354cac539cc56a79a5c5a0a7a59325fb57d65..fac7bd056eed88442284da71c44a864698de9fce 100644 (file)
@@ -14,8 +14,7 @@
 #include <algorithm>
 #include <cassert>
 #include <cstring>
-#include <memory.h>
-
+#include <memory>
 using namespace std;
 
 const int INITIALMAX = 8;
index edda14efef795768e581c093dea0d058a24c8c4f..7e6342dfb8b9da293e44b5517e63a22d01bd277a 100644 (file)
@@ -11,8 +11,8 @@ source file of Flower lib
 #define STRINGHANDLE_INL
 
 #include <cassert>
-
-#include <memory.h>
+#include <memory>
+using namespace std;
 
 #include "string-data.hh"
 #include "string-handle.hh"
index 91c3f2082f682f8bac135effde321500b86af0e7..ed5773e73c96ed2b9259aeddbeac9c1d1d432575 100644 (file)
@@ -17,6 +17,7 @@
 class ostream;
 #endif
 #endif
+using namespace std;
 
 #include "arithmetic-operator.hh"
 #include "string-handle.hh"
@@ -174,8 +175,8 @@ String to_string (char const *format, ...);
 */
 
 #include "international.hh"
-
 #include "compare.hh"
+
 INSTANTIATE_COMPARE (String const &, String::compare);
 
 #ifdef STRING_UTILS_INLINED
index c7746c84f8aad671bc28638c8145faa6587eeb49..bf460b9d210ef2f9aeb1d099d3bc16f8b4de6094 100644 (file)
 #define VIRTUAL_METHODS_HH
 
 #include <typeinfo>
+using namespace std;
 
 #define classname(class_ptr) demangle_classname (typeid (* (class_ptr)))
 
 char const *
-demangle_classname (std::type_info const &);
+demangle_classname (type_info const &);
 
 /* Virtual copy constructor.  Make up for C++'s lack of a standard
    factory or clone () function.  Uses a typeof hack.  Usage:
index 7b9b5d7821c265389a6a07e6ac793c65c376321a..f6268e1849ccec04889770dd909388bfcaeaf85a 100644 (file)
@@ -11,6 +11,7 @@
 #include <cstdio>
 #include <cstring>
 #include <cctype>
+using namespace std;
 
 #include "libc-extension.hh"
 
@@ -36,25 +37,6 @@ strnupr (char *start, int n)
   return start;
 }
 
-/*
-  There are some strange problems with round() on early glibcs.
-*/
-double
-my_round (double x)
-{
-  return floor (x -0.5)+ 1.0;
-}
-
-#ifndef isinf
-#if !HAVE_ISINF
-int
-isinf (double x)
-{
-  return x && (x == x/ 2);
-}
-#endif
-#endif
-
 #if !HAVE_MEMMEM
 
 /** locate a substring. #memmem# finds the first occurrence of
@@ -132,6 +114,27 @@ memrev (unsigned char *byte, int length)
   return byte;
 }
 
+/*
+  There are some strange problems with round() on early glibcs.
+*/
+double
+my_round (double x)
+{
+  return floor (x -0.5)+ 1.0;
+}
+
+/* namespace std { */
+  
+#ifndef isinf
+#if !HAVE_ISINF
+int
+isinf (double x)
+{
+  return x && (x == x/ 2);
+}
+#endif
+#endif
+
 #if ! HAVE_SNPRINTF
 int
 snprintf (char *str, size_t n, char const *format, ...)
@@ -157,3 +160,4 @@ vsnprintf (char *str, size_t n, char const *format, va_list args)
 }
 #endif
 
+/* } namespace std */
index 0fcedb75651041cdded14512e604fcf13723b2aa..129bd8600cb4eff22e9a989972fef5da09e1208e 100644 (file)
@@ -6,9 +6,10 @@
   (c) 2005 Han-Wen Nienhuys <hanwen@xs4all.nl>
 */
 
-#include <assert.h>
-#include <string.h>
-#include <stdlib.h>
+#include <cassert>
+#include <cstring>
+#include <cstdlib>
+using namespace std;
 
 #include "memory-stream.hh"
 
index 39e1e0b6da9a16713d63ce25e63a055e2c9a6aba..a4e7ee90e9fbdf7b414f4041919be0645b0931bf 100644 (file)
@@ -81,7 +81,8 @@ Offset::arg () const
 Real
 Offset::length () const
 {
-  return sqrt (sqr (coordinate_a_[X_AXIS]) + sqr (coordinate_a_[Y_AXIS]));
+  return sqrt (sqr (coordinate_a_[X_AXIS])
+                   + sqr (coordinate_a_[Y_AXIS]));
 }
 
 bool
index d5147f1d7465640f6cbdfa97511f64c43ce0a711..b65665738f310d8e99af89800f6fbbb83642152b 100644 (file)
@@ -73,6 +73,7 @@ Morten Welinder <terra@diku.dk> September 1999.
 #include <cerrno>
 #include <cmath>
 #include <cstring>
+using namespace std;
 
 #include <sys/file.h>
 
index 906c948c9f905c0c725a0e9a81e45d4bb7f6cf46..82617d3db45136710ce31eb0b6ec321a5e284e71 100644 (file)
@@ -7,6 +7,7 @@
 #include "polynomial.hh"
 
 #include <cmath>
+using namespace std;
 
 /*
   Een beter milieu begint bij uzelf. Hergebruik!
@@ -16,7 +17,7 @@
 */
 
 Real
-Polynomial::eval (Real x)const
+Polynomial::eval (Real x) const
 {
   Real p = 0.0;
 
@@ -87,7 +88,7 @@ Polynomial::clean ()
     We only do relative comparisons. Absolute comparisons break down in
     degenerate cases.  */
   while (degree () > 0
-        && (fabs (coefs_.top ()) < FUDGE *fabs (coefs_.top (1))
+        && (fabs (coefs_.top ()) < FUDGE * fabs (coefs_.top (1))
             || !coefs_.top ()))
     coefs_.pop ();
 }
@@ -193,8 +194,7 @@ inline Real cubic_root (Real x)
     return pow (x, 1.0 / 3.0);
   else if (x < 0.0)
     return -pow (-x, 1.0 / 3.0);
-  else
-    return 0.0;
+  return 0.0;
 }
 
 static bool
@@ -240,21 +240,25 @@ Polynomial::solve_cubic ()const
        sol.push (-u);
       }
     }
-  else if (D < 0) {            /* Casus irreducibilis: three real solutions */
-    Real phi = 1.0 / 3 * acos (-q / sqrt (-cb));
-    Real t = 2 * sqrt (-p);
-
-    sol.push (t * cos (phi));
-    sol.push (-t * cos (phi + M_PI / 3));
-    sol.push (-t * cos (phi - M_PI / 3));
-  }
-  else {                       /* one real solution */
-    Real sqrt_D = sqrt (D);
-    Real u = cubic_root (sqrt_D - q);
-    Real v = -cubic_root (sqrt_D + q);
-
-    sol.push (u + v);
-  }
+  else if (D < 0)
+    {
+    /* Casus irreducibilis: three real solutions */
+      Real phi = 1.0 / 3 * acos (-q / sqrt (-cb));
+      Real t = 2 * sqrt (-p);
+
+      sol.push (t * cos (phi));
+      sol.push (-t * cos (phi + M_PI / 3));
+      sol.push (-t * cos (phi - M_PI / 3));
+    }
+  else
+    {
+      /* one real solution */
+      Real sqrt_D = sqrt (D);
+      Real u = cubic_root (sqrt_D - q);
+      Real v = -cubic_root (sqrt_D + q);
+
+      sol.push (u + v);
+    }
 
   /* resubstitute */
   Real sub = 1.0 / 3 * A;
index 133187ef99f3d1c02ed848addd30463dd9ffabc9..65672f5bcbb3547e1553a54c9d9e8388f4460c3e 100644 (file)
@@ -10,6 +10,7 @@
 
 #include <cmath>
 #include <cstdlib>
+using namespace std;
 
 #include "string-convert.hh"
 #include "libc-extension.hh"
index 7f57b1474bdff3b4e93394d5eccb05da84d638ec..9d880ac9299c9855f0ee9d082e945941d40ab0cf 100644 (file)
@@ -1,5 +1,6 @@
 #include "real.hh"
 
 #include <cmath>
+using namespace std;
 
 const Real infinity_f = HUGE_VAL;
index 0c48f7fe90a18ad5cd6d07efa0d17f9f5c616be7..39941f8f74e296b92f84092360dad3b7dd1bcef2 100644 (file)
@@ -1,9 +1,10 @@
 #include <cctype>
+using namespace std;
 
 #include "virtual-methods.hh"
 
 char const *
-demangle_classname (std::type_info const &t)
+demangle_classname (type_info const &t)
 {
   char const *s = t.name ();
   while (isdigit (*s))
index af4d9931bdb027acea187ba446e2ab6953913ac3..7e771c8e73c7b510079ea68fe7679bd3bf5f524a 100644 (file)
@@ -8,6 +8,7 @@
 
 #include <cstring>
 #include <cstdio>
+using namespace std;
 
 #include "libc-extension.hh"
 #include "rational.hh"
index c4c7d49abf39b1c617b4dbf918ca317ba8ab4ef6..79995a1c76306e0212843c669ecb4d43ec65bbc2 100644 (file)
@@ -16,6 +16,7 @@
 #include <cstring>
 
 #include <iostream>
+using namespace std;
 
 #include "libc-extension.hh"
 #include "string-convert.hh"
@@ -232,8 +233,9 @@ String::index (String searchfor) const
 {
   char const *me = strh_.to_str0 ();
 
-  char const *p = (char const *)
-    memmem (me, length (), searchfor.to_str0 (), searchfor.length ());
+  char const *p
+    = (char const *) memmem (me, length (),
+                            searchfor.to_str0 (), searchfor.length ());
 
   if (p)
     return p - me;
index 0e42eac4e4eae161cf7ef091837e7dd59b656b97..8516a275522f724f74f25ae06dbba1bcd4317b63 100644 (file)
@@ -31,7 +31,9 @@
 
 #ifdef STRING_DEBUG
 #include <sys/types.h>
-#include <memory.h>
+#include <memory>
+using namespace std;
+
 void *
 mymemmove (void *dest, void const *src, size_t n)
 {
index 8ac73541b6cf0cc30f2559f32b24c1896ae7424a..6399aad4b7bf5bbed00bcd40509c3d7f21a260d3 100644 (file)
@@ -10,6 +10,7 @@
 
 #include <cstdlib>
 #include <cstdio>
+using namespace std;
 
 /* Is progress indication at NEWLINE?  */
 static bool progress_newline = true;
index d81d9a3c361d04d66622f5a7f4ca4a535d1fde2d..4a875fcfe2dd321d6b1357ec8debc5c19eacf206 100644 (file)
@@ -225,7 +225,8 @@ number_accidentals_from_sig (bool *different, SCM sig, Pitch *pitch,
 
       if (alter == prev)
        num = 0;
-      else if ((abs (alter) < abs (prev) || prev * alter < 0) && alter != 0)
+      else if ((abs (alter) < abs (prev)
+               || prev * alter < 0) && alter != 0)
        num = 2;
       *different = (alter != prev);
     }
index 5eff0dfc45dc9a2741ed16b82612019e8384f037..d4e6a340f84069610d8fa1ec1a0b395fb6385d08 100644 (file)
@@ -6,7 +6,8 @@
   (c) 2002--2005 Han-Wen Nienhuys <hanwen@cs.uu.nl>
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "accidental-placement.hh"
 #include "skyline.hh"
index e5b463ce5a5313d1ab68eda63921e99997d756ac..95f138090abc29bace0eda1fa066ff1ab8f0ae75 100644 (file)
@@ -9,6 +9,7 @@
 #include "afm.hh"
 
 #include <cstring>
+using namespace std;
 
 #include "warn.hh"
 #include "libc-extension.hh"
@@ -75,7 +76,7 @@ Adobe_font_metric::find_char_metric (String nm) const
 int
 Adobe_font_metric::name_to_index (String name) const
 {
-  std::map<String, int>::const_iterator ai = name_to_metric_dict_.find (name);
+  map<String, int>::const_iterator ai = name_to_metric_dict_.find (name);
   if (ai == name_to_metric_dict_.end ())
     return -1;
   return (*ai).second;
index adbe9d199cf14d5a19f118ef6f360f827ae15986..1b661e8f9ed8028c1c6a2f2606023ae58c731247 100644 (file)
@@ -181,10 +181,7 @@ Align_interface::align_elements_to_extents (Grob *me, Axis a)
       */
       dy *= stacking_dir;
       if (j)
-       {
-         dy = min (max (dy, threshold[SMALLER]),
-                   threshold[BIGGER]);
-       }
+       dy = min (max (dy, threshold[SMALLER]), threshold[BIGGER]);
 
       where_f += stacking_dir * dy;
       total.unite (dims[j] + where_f);
index a0a9ccdae41c322b9fb3101f6cb0c94e54ec6a96..ecc8ac70d6935b14aa8afc6b226ae0c090223490 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "bar-line.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "all-font-metrics.hh"
 #include "font-interface.hh"
index edd95394a50f38f7e5cd1337d9ac6129075f818d..1866e52f278dc00e23469523d661739eee62b952 100644 (file)
@@ -2,7 +2,8 @@
   Determine whether a beam is concave.
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "pointer-group-interface.hh"
 #include "array.hh"
index 0ee1a01b4145d5b3371635e1a718a590fe7d9da9..d8544b9b18de2c402e0a875874b73104ffe8d28c 100644 (file)
@@ -10,7 +10,8 @@
 #include "beam.hh"
 
 #include <algorithm>
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "warn.hh"
 #include "staff-symbol-referencer.hh"
@@ -401,7 +402,8 @@ Beam::score_slopes_dy (Real yl, Real yr,
       && sign (dy_damp) != sign (dy))
     dem += parameters->DAMPING_DIRECTION_PENALTY;
 
-  dem += parameters->MUSICAL_DIRECTION_FACTOR *max (0.0, (fabs (dy) - fabs (dy_mus)));
+  dem += parameters->MUSICAL_DIRECTION_FACTOR
+    * max (0.0, (fabs (dy) - fabs (dy_mus)));
 
   Real slope_penalty = parameters->IDEAL_SLOPE_FACTOR;
 
index 4ad02de78df99239c5ce2a9fb515ad96b94d854f..0b3ca786c42763734f9dee6e86317a6ba8fba1d2 100644 (file)
@@ -24,7 +24,8 @@
   - beam_translation is the offset between Y centers of the beam.
 */
 
-#include <math.h> // tanh.
+#include <cmath> // tanh.
+using namespace std;
 
 #include "beam.hh"
 #include "interval-set.hh"
@@ -780,7 +781,7 @@ set_minimum_dy (Grob *me, Real *dy)
       Real hang = 1.0 - (thickness - slt) / 2;
 
       *dy = sign (*dy) * max (fabs (*dy),
-                             min (min (sit, inter), hang));
+                                  min (min (sit, inter), hang));
     }
 }
 
@@ -1402,12 +1403,28 @@ Beam::get_direction_beam_count (Grob *me, Direction d)
 
 ADD_INTERFACE (Beam, "beam-interface",
               "A beam. \n\n"
-              "The @code{thickness} property is the weight of beams, and is measured "
-              "in  staffspace",
-              "knee positioning-done position-callbacks "
-              "concaveness dir-function quant-score auto-knee-gap gap "
-              "gap-count chord-tremolo beamed-stem-shorten shorten least-squares-dy "
-              "details damping inspect-quants flag-width-function "
-              "neutral-direction positions space-function break-overshoot "
-              "thickness");
-
+              "The @code{thickness} property is the weight of beams, "
+              "measured in staffspace",
+              "auto-knee-gap "
+              "beamed-stem-shorten "
+              "break-overshoot "
+              "chord-tremolo "
+              "concaveness "
+              "damping "
+              "details "
+              "dir-function "
+              "flag-width-function "
+              "gap "
+              "gap-count "
+              "inspect-quants "
+              "knee "
+              "least-squares-dy "
+              "neutral-direction "
+              "position-callbacks "
+              "positioning-done "
+              "positions "
+              "quant-score "
+              "shorten "
+              "space-function "
+              "thickness "
+              );
index a86a9841071d2f22e91625c8fb11bd6e15579bed..fcc6df45f4ce1e898ec3167f244861a6a050dd8a 100644 (file)
@@ -6,7 +6,8 @@
   (c) 1998--2005 Jan Nieuwenhuizen <janneke@gnu.org>
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "misc.hh"
 #include "bezier.hh"
@@ -98,8 +99,7 @@ get_slur_indent_height (Real *indent, Real *height,
   *height = slur_height (width, h_inf, r_0);
 
   Real q = 2 * h_inf / max_fraction;
-  *indent
-    = 2 * h_inf - sqr (q) * max_fraction / (width + q);
+  *indent = 2 * h_inf - sqr (q) * max_fraction / (width + q);
 }
 
 Bezier
index d6ecd0b3135ba1fce8766b3d473cb6c16c415ef6..09bcd54a1a80b755a18231623f0ec81c170a0fab 100644 (file)
@@ -6,7 +6,8 @@
   (c) 1998--2005 Jan Nieuwenhuizen <janneke@gnu.org>
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "bezier.hh"
 #include "warn.hh"
index 2c726df90de1f2a677826866578ab877d50ca336..180991781d89d41896af81eb001db501585bba7b 100644 (file)
@@ -7,6 +7,7 @@
 */
 
 #include <climits>             // INT_MAX
+using namespace std;
 
 #include "binary-source-file.hh"
 #include "string-convert.hh"
index 0c3106e3fa2037ff9c8240eff1f4154331e34225..96a66ce00cb0c9ad81b748857b938fb23e4d4507 100644 (file)
@@ -9,6 +9,7 @@
 #include "book.hh"
 
 #include <cstdio>
+using namespace std;
 
 #include "lilypond-key.hh"
 #include "global-context.hh"
index 211058779a4ae810d8b97fa9bd40e0424eecfdd6..c06c267001b4f67d2980c08d7aeb6d06d559a25c 100644 (file)
@@ -6,7 +6,8 @@
   (c) 1997--2005 Han-Wen Nienhuys <hanwen@cs.uu.nl>
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "break-align-interface.hh"
 
index 5f6edb9cebbb37cddba8e1e7842509c95d897740..bed8b97c8613938f17a2dbe156db4b5bf928de61 100644 (file)
@@ -8,6 +8,7 @@
 
 #include <cstdio>
 #include <cstdlib>
+using namespace std;
 
 #include "grob-array.hh"
 #include "item.hh"
index fa54f7a8dc047cf6de9fee6d1a113d1ce7defd18..c0fb2fe4b1463fe1751ac02e408939ec26322619 100644 (file)
@@ -9,6 +9,7 @@
 */
 
 #include <cctype>
+using namespace std;
 
 #include "context.hh"
 #include "bar-line.hh"
index 10b408a88fcaaaa54c15bec78efb4934804dcbd9..b089e5cb5a3df58720a0c734f1c801b14a41ad29 100644 (file)
@@ -11,6 +11,7 @@
 #include "cluster.hh"
 
 #include <cstdio>
+using namespace std;
 
 #include "spanner.hh"
 #include "item.hh"
index ede37181b9b84485566242f8c8966689053604ce..b313fea1052c88d46ce21e371bce37c4a2034754 100644 (file)
@@ -5,6 +5,7 @@
 */
 
 #include <cctype>
+using namespace std;
 
 #include "rhythmic-head.hh"
 #include "output-def.hh"
index 515e04f761f76b285b7ce8de638dfc3cc6b81889..ae32e8562b671052ce440a2502b5d1829f63d0bd 100644 (file)
@@ -14,7 +14,8 @@
 */
 
 #include <cstdio>
-#include <math.h> // rint
+#include <cmath> // rint
+using namespace std;
 
 #include "custos.hh"
 #include "direction.hh"
index e4dd194632bbdb1d8fff1ec741fd3ad1077cb301..3254e5e81971b4b7c4fdbcdd27e0917658a13ea6 100644 (file)
@@ -6,7 +6,8 @@
   (c) 1998--2005 Han-Wen Nienhuys <hanwen@cs.uu.nl>
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "dimension-cache.hh"
 #include "warn.hh"
index 0acae3b414c9acabdb4a777106b6c72e7b9b2faa..a8d3e735705ade449ad9f21c3392383a3a76f4c8 100644 (file)
@@ -9,8 +9,9 @@
 #include "dot-column.hh"
 
 #include <cstdio>
-#include <math.h>
+#include <cmath>
 #include <map>
+using namespace std;
 
 #include "dots.hh"
 #include "rhythmic-head.hh"
@@ -82,7 +83,7 @@ struct Dot_position
   }
 };
 
-typedef std::map<int, Dot_position> Dot_configuration;
+typedef map<int, Dot_position> Dot_configuration;
 
 /*
   Value CFG according.
index 02bb19f1d1644827ed7e03c593d2a97463d3bcac..13204180a60bb8a5458f6869c5f91b650d72fde4 100644 (file)
@@ -5,6 +5,7 @@
 */
 
 #include <cctype>
+using namespace std;
 
 #include "rhythmic-head.hh"
 #include "engraver.hh"
index bd24ffbab2f699a4646bc8c04b7776f1100ca881..879ded5483b3ffa5c1b8db5a9e4368759fcc5082 100644 (file)
@@ -8,6 +8,9 @@
 
 #include "note-head.hh"
 
+#include <cctype>
+using namespace std;
+
 #include "text-interface.hh"
 #include "grob.hh"
 #include "output-def.hh"
@@ -16,7 +19,6 @@
 #include "font-interface.hh"
 #include "staff-symbol-referencer.hh"
 #include "stem.hh"
-#include <cctype>
 
 MAKE_SCHEME_CALLBACK (Note_head, brew_ez_stencil, 1);
 SCM
index de656168cb0ce98ab6442aadf44b1b5de9913c3c..11000e10b540c67c5b5827edef09eee46b7edece 100644 (file)
@@ -7,11 +7,12 @@
 */
 
 #include <map>
+using namespace std;
 
 #include "file-name-map.hh"
 #include "lily-guile.hh"
 
-std::map<String, String> file_name_map_global;
+map<String, String> file_name_map_global;
 
 String
 map_file_name (String s)
index 5909b7ee9561e8f1b99c571d66dcab20d162d4af..48ec34183efb254194720dda876274f96b9452ad 100644 (file)
@@ -10,8 +10,9 @@
 
 #include "font-metric.hh"
 
-#include <math.h>
+#include <cmath>
 #include <cctype>
+using namespace std;
 
 #include "dimensions.hh"
 #include "modified-font-metric.hh"
index 61030405fb7786ec9feb535b5fa5d5a901738374..c91f713b176b6c52719c03f1edc7e8cb3af819c6 100644 (file)
@@ -6,7 +6,8 @@
   (c) 2003--2005 Han-Wen Nienhuys <hanwen@xs4all.nl>
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "dimensions.hh"
 #include "all-font-metrics.hh"
index 124d6b5539459a50de52c417dec7de5a8f74a2d0..9a1fb9daefdfba3c9de8d2e1ea885ca56cf33fca 100644 (file)
@@ -7,6 +7,7 @@
 */
 
 #include <cstring>
+using namespace std;
 
 #include "protected-scm.hh"
 #include "string.hh"
index 2c1fb2bbc07b5665f28d60a62c6c99cf0b900d21..d5f07b53d029df439fa6d6a44cd4f150abec9e8f 100644 (file)
@@ -9,9 +9,10 @@
 
 #include "config.hh"
 
-#include <math.h>  /* isinf */
-#include <stdio.h>
-#include <string.h>  /* memset */
+#include <cmath>  /* isinf */
+#include <cstdio>
+#include <cstring>  /* memset */
+using namespace std;
 
 #include "international.hh"
 #include "libc-extension.hh"
index 3ecc3b9aafa77057379a1c97c314f643ae9b6eba..922015717d184e7a0a245866708966a834baaaac 100644 (file)
@@ -9,6 +9,7 @@
 #include "global-context.hh"
 
 #include <cstdio>
+using namespace std;
 
 #include "warn.hh"
 #include "music.hh"
index 6310acb874599b7ec82bc078c03bb362ade7c1c0..f5d78b9f51d3e15345ddff6aa3e01b715cef67cf 100644 (file)
@@ -8,8 +8,9 @@
 
 #include "gourlay-breaking.hh"
 
-#include <math.h>              // rint
+#include <cmath>               // rint
 #include <cstdio>
+using namespace std;
 
 #include "warn.hh"
 #include "main.hh"
index bf1663e530e8527094dfc28b96af89bc3ea96cb5..04acbf4fc17e303f62d2fb2f1f9e2ec161b5ab1c 100644 (file)
@@ -3,7 +3,8 @@
 */
 
 #include <cstring>
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "main.hh"
 #include "input-smob.hh"
index b8b82271ca9803444bf7d7a77565b296abe15f35..cfb8c319f9f31b23489386f99878ef14f5f8036c 100644 (file)
@@ -9,7 +9,8 @@
 #include "grob.hh"
 
 #include <cstring>
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "main.hh"
 #include "input-smob.hh"
index 7cde6bfc3724ac7b063ce50251175835ca091ace..df4802fa936701b13102071e4a99fd21060c83d6 100644 (file)
@@ -9,6 +9,7 @@
 #include "includable-lexer.hh"
 
 #include <sstream>
+using namespace std;
 
 #include "config.hh"
 #include "file-path.hh"
index 3f815e946127cacd609500fe15d7594cf92e2f13..7f436f470a2edf8f4820de3e30fdb68598b31309 100644 (file)
@@ -11,6 +11,7 @@
 #define AFM_HH
 
 #include <map>
+using namespace std;
 
 #include "array.hh"
 #include "font-metric.hh"
@@ -40,7 +41,7 @@ protected:
   AFM_CharMetricInfo const *find_ascii_metric (int) const;
 
   Array<int> ascii_to_metric_idx_;
-  std::map<String, int> name_to_metric_dict_;
+  map<String, int> name_to_metric_dict_;
 
   Adobe_font_metric (AFM_Font_info *);
 };
index df053d160b4cf9aae479dc7507e1cf284963d1a7..ca7a40b5602bf40516ca04b4f1506d85928a5834 100644 (file)
@@ -10,6 +10,7 @@
 #define CONTEXT_HH
 
 #include <map>
+using namespace std;
 
 #include "moment.hh"
 #include "lily-proto.hh"
@@ -28,8 +29,8 @@ private:
   int iterator_count_;
   bool init_;
 
-  std::map<String, int> grob_counts_;
-  std::map<String, int> context_counts_;
+  map<String, int> grob_counts_;
+  map<String, int> context_counts_;
 
 protected:
   Object_key const *key_;
index b7edcbb29e8debac5b597dcfde53dcefecba3474..afeb4a35bc255fa089e256a70bda2e5f94e21bb7 100644 (file)
@@ -10,7 +10,6 @@
 #define INCLUDABLE_LEXER_HH
 
 #ifndef LEXER_CC
-using namespace std;
 #include <FlexLexer.h>
 #endif
 
index 6387feb38377af63d7599acb2f808aa171eb26de..4c8ed07edc32c9347800bebe8d0a371883921fa0 100644 (file)
@@ -8,6 +8,7 @@
 #define MIDI_STREAM_HH
 
 #include <cstdio>
+using namespace std;
 
 #include "string.hh"
 
index b40e936e9ef67dce20abca556281d629190a8b9a..8ea878cc2efe3387bb2ff6e7748d3296b924a6c0 100644 (file)
@@ -10,6 +10,7 @@
 #define MISC_HH
 
 #include <cstdlib>
+using namespace std;
 
 #include "array.hh"
 #include "interval.hh"
index ba8164f0319550c0997553d1eb93cb446a81a3e3..4c0b68e1ee8ff7ff44d19567d2f7574046d5fc23 100644 (file)
@@ -63,7 +63,7 @@ INSTANTIATE_COMPARE (Moment const &, Moment::compare);
 Moment robust_scm2moment (SCM, Moment);
 
 #ifdef STREAM_SUPPORT
-std::ostream &operator << (std::ostream &, Moment const &);
+ostream &operator << (ostream &, Moment const &);
 #endif
 
 bool moment_less (SCM a, SCM b);
index 457b273c44fba5cab088f1357001977dd74129b2..df5db430355ffd293ba045f944122766f32ea5bd 100644 (file)
 #define OBJECT_KEY_DUMPER_HH
 
 #include <map>
+using namespace std;
 
 #include "object-key.hh"
 
-typedef std::map<Object_key const *, Object_key const *, Object_key_less> Key_to_key_map;
-typedef std::map<Object_key const *, int> Pointer_to_int_map;
-typedef std::map<int, Object_key const *> Int_to_key_map;
+typedef map<Object_key const *, Object_key const *, Object_key_less> Key_to_key_map;
+typedef map<Object_key const *, int> Pointer_to_int_map;
+typedef map<int, Object_key const *> Int_to_key_map;
 
 class Object_key_dumper
 {
index 02d98aab1a95ba57b3b3c709bf5bcace3950f4a6..8380dee545d8d34bb910cd472ac3e480fd55aa6c 100644 (file)
 #define OBJECT_KEY_UNDUMPER_HH
 
 #include <map>
+using namespace std;
+
 #include "object-key.hh"
 
-typedef std::map<int, Object_key const *> Int_to_key_map;
+typedef map<int, Object_key const *> Int_to_key_map;
 
 struct Object_key_undumper
 {
index 05d6f54d3387f00284079c3cc75eb3dfe0a55d93..e75b4c62d4280efac1b1658d32f488cdf469aa9a 100644 (file)
 #define OPEN_TYPE_FONT_HH
 
 #include <map>
+using namespace std;
+
 #include "freetype.hh"
 #include "font-metric.hh"
 
-typedef std::map<FT_UInt, FT_ULong> Index_to_charcode_map;
+typedef map<FT_UInt, FT_ULong> Index_to_charcode_map;
 Index_to_charcode_map make_index_to_charcode_map (FT_Face face);
 
 class Open_type_font : public Font_metric
index 1a610703489611b7b16c02443cdc6ea0183eb4bb..7668c41efee86d22cadc6b1a7d17484cec97a003 100644 (file)
@@ -10,6 +10,7 @@
 #define SOURCE_FILE_HH
 
 #include <iostream>
+using namespace std;
 
 #include "string.hh"
 #include "protected-scm.hh"
@@ -33,7 +34,7 @@ public:
 
   char const *to_str0 () const;
   virtual String quote_input (char const *pos_str0) const;
-  std::istream *get_istream ();
+  istream *get_istream ();
   bool contains (char const *pos_str0) const;
   int length () const;
   virtual int get_line (char const *pos_str0) const;
@@ -66,7 +67,7 @@ public:
 
 private:
   Link_array<char> newline_locations_;
-  std::istream *istream_;
+  istream *istream_;
   char *contents_str0_;
   int length_;
   void load_stdin ();
index 3349cbdd352c7876f61bd9b9ebd15b4b02c45759..8b57763d79f9821f236ea3f493a37aa4d54da4bd 100644 (file)
@@ -9,6 +9,7 @@
 #define STENCIL_HH
 
 #include <cstdlib>             // size_t
+using namespace std;
 
 #include "lily-proto.hh"
 #include "box.hh"
index c3a26f108cf9084d3c5f650fdf99092ce1b16d3d..1178fc51ae23b8b32583049c8deeda81fea00e1a 100644 (file)
 
 #include <iostream>
 #include <sstream>
+using namespace std;
 
 #include "string.hh"
 
 #if __GNUC__ > 2
-std::ostream *open_file_stream (String file_name,
-                               std::ios_base::openmode mode = std::ios::out);
+ostream *open_file_stream (String file_name,
+                               ios_base::openmode mode = ios::out);
 #else
-std::ostream *open_file_stream (String file_name, int mode = ios::out);
+ostream *open_file_stream (String file_name, int mode = ios::out);
 #endif
-void close_file_stream (std::ostream *os);
+void close_file_stream (ostream *os);
 
 #endif /* STREAM_HH */
 
index ea52b1e41b61e11de52013ff2a8ac831b12976b9..468145f7aa4f8b1aa9c64a1fcc027bde4d28c954 100644 (file)
 #define TWEAK_REGISTRATION_HH
 
 #include <map>
+using namespace std;
 
 #include "lily-proto.hh"
 #include "object-key.hh"
 
-typedef std::map<Object_key const *, SCM, Object_key_less> Tweak_map;
+typedef map<Object_key const *, SCM, Object_key_less> Tweak_map;
 
 class Tweak_registry
 {
index d6d33e2247556afc63b81c5e785d418ba535b32b..3d377f60f7e6147c41e5b1b50f74adb7c5b1d7ab 100644 (file)
@@ -9,6 +9,7 @@
 #include "input.hh"
 
 #include <cstdio>
+using namespace std;
 
 #include "source.hh"
 #include "source-file.hh"
index 70c84e59e2a6bfc9719f08dd62d41a171ba51444..684bc189e36a4f08768321b8549a763e3d56fafe 100644 (file)
@@ -6,6 +6,7 @@
 
 #include <cstring>
 #include <cstdlib>
+using namespace std;
 
 /* for qsort */
 int tabcmp (Keyword_ent const &p1, Keyword_ent const &p2)
index f6d70478ce324920a8dfb4c3c430ba3ed62fa173..b851c434eb651d0091d50b88f89a4260a6e19c27 100644 (file)
@@ -33,7 +33,7 @@ minimise_least_squares (Real *coef, Real *offset,
   *coef = 0.0;
   *offset = 0.;
 
-  Real den = (N *sqx - sqr (sx));
+  Real den = (N * sqx - sqr (sx));
   if (!N || !den)
     {
       programming_error ("minimise_least_squares ():  Nothing to minimise");
index fe094e681f6fb8bed7006b2e9defc958f1adc154..1cf32af56f6f35b3c137a54ce52bad366d5df671 100644 (file)
@@ -7,6 +7,7 @@
 */
 
 #include <map>
+using namespace std;
 
 #include "item.hh"
 #include "note-head.hh"
@@ -188,7 +189,7 @@ struct Ledger_request
   }
 };
 
-typedef std::map < int, Drul_array<Ledger_request> > Ledger_requests;
+typedef map < int, Drul_array<Ledger_request> > Ledger_requests;
 
 /*
   TODO: ledger share a lot of info. Lots of room to optimize away
index bb9ee2271a641e89f5e966272216dfba1172b0b7..a5fbdb6a94473bfb6ef976912a13973844e6a807 100644 (file)
  */
 
 
-#include <stdio.h>
-#include <ctype.h>
-#include <errno.h>
+
+#include <cstdio>
+#include <cctype>
+#include <cerrno>
 
 /* Flex >= 2.5.29 fix; FlexLexer.h's multiple include bracing breaks
    when building the actual lexer.  */
@@ -32,7 +33,6 @@
 #define LEXER_CC
 
 #include <iostream>
-
 using namespace std;
 
 #include "music-function.hh"
@@ -952,3 +952,35 @@ music_function_type (SCM func)
 
        return MUSIC_FUNCTION_SCM;
 }
+
+/* Shut up lexer warnings.  */
+#if YY_STACK_USED
+
+static void
+yy_push_state (int)
+{
+}
+
+static void
+yy_pop_state ()
+{
+}
+
+static int
+yy_top_state ()
+{
+  return 0;
+}
+
+static void
+silence_lexer_warnings ()
+{
+   (void) yy_start_stack_ptr;
+   (void) yy_start_stack_depth;
+   (void) yy_start_stack;
+   (void) yy_push_state;
+   (void) yy_pop_state;
+   (void) yy_top_state;
+   (void) silence_lexer_warnings;
+}
+#endif
index 856c9d30cd3afa8567e35caec43507affa7c9ee0..664dcf2905b9ddc7d3dfccc82b523a44a83ee9b0 100644 (file)
@@ -13,6 +13,7 @@
 #include <cstdlib>
 #include <cstring> /* strdup, strchr */
 #include <cctype>
+using namespace std;
 
 #include "config.hh"
 
index ad16d150e52c680d8fddaac034f0dc4259a14555..57475d37d340f98c48e97b1d41016017d3985a4c 100644 (file)
@@ -10,6 +10,7 @@
 
 #include <cctype>
 #include <sstream>
+using namespace std;
 
 #include "scm-hash.hh"
 #include "interval.hh"
index 96841816a5d25e618b5fd20dc710f94c7981b1b3..cbfe9dd306f6895cec23f74f3ad6a08fc0905473 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "line-spanner.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "spanner.hh"
 #include "output-def.hh"
index 91e67d1510e1fa09368bd0de640c1f234c602c5d..f87be0b3e105068ddfb596531cd3916e97815953 100644 (file)
@@ -10,8 +10,9 @@
 
 #include "lookup.hh"
 
-#include <math.h>
+#include <cmath>
 #include <cctype>
+using namespace std;
 
 #include "line-interface.hh"
 #include "warn.hh"
index ad8b108e78320c0b64128265ce5825ac1a079ea2..ebf3c41ce5c906a459834af8cae066defc92fa9a 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "lyric-extender.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "warn.hh"
 #include "lookup.hh"
index f02721122679d298fcba82270776cd351399dba0..f68719595bd1e3c54484ca773e9c89705ceac554 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "lyric-hyphen.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "lookup.hh"
 #include "output-def.hh"
index 8aba4701fe4fa6906b9ebd36e2afcd29ffb294da..3fc4637273fef75ecfb01678f162d57381d35090 100644 (file)
 #include <cassert>
 #include <clocale>
 #include <cstring>
+#include <cerrno>
+using namespace std;
+
 #include <unistd.h>
-#include <errno.h>
 #include <sys/types.h>
 #include <sys/stat.h>
 
index 2e4bae6f27e9395bddc6ee78434735bb44daefd0..897475e6af103c11a9c8f46d3abeb91a546cbfea 100644 (file)
@@ -7,6 +7,7 @@
 */
 
 #include <cctype>
+using namespace std;
 
 #include "bar-line.hh"
 #include "context.hh"
index add51960b9b2a3fe990b43cc0ddecc195eec33b1..250a0f9411ec1d88671320633b1d5441032af647 100644 (file)
@@ -7,7 +7,8 @@
   Pal Benko <benkop@freestart.hu>
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "mensural-ligature.hh"
 #include "item.hh"
index 15375e542bbabb57b47cca64c4e6c0d5a2cdb6e8..803244967f6621afc081dc7b4da4fb08473ac7c4 100644 (file)
@@ -7,6 +7,7 @@
 */
 
 #include <cctype>
+using namespace std;
 
 #include "engraver.hh"
 
index 0905c4c2f742d242dc419944c299d64c9b143623..a80667501654871f127dc418a7ea556abe3f3578 100644 (file)
@@ -6,7 +6,8 @@
   (c) 1997--2005 Jan Nieuwenhuizen <janneke@gnu.org>
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "misc.hh"
 #include "output-def.hh"
index 87a1b581d3f7d99dba15e837e304ff33eea51749..ffe5196b637c94b88a50ee2becf0acbade54ba02 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "midi-stream.hh"
 
-#include <errno.h>
+#include <cerrno>
+using namespace std;
 
 #include "stream.hh"
 #include "string-convert.hh"
index bb8a05201c103904bd3a3e2aa8900c5db260e855..809c1b7169f8ed0cd326ec8ced4f17caf2370b5e 100644 (file)
@@ -7,7 +7,8 @@
   Jan Nieuwenhuizen <janneke@gnu.org>
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "misc.hh"
 #include "string.hh"
index 5a616198aad4bf9b830d702f00b228f059999c08..e3f419cf7665fcaa96cdb4e20e3b2b6176fddf68 100644 (file)
@@ -6,6 +6,7 @@
   (c) 1999--2005 Han-Wen Nienhuys <hanwen@cs.uu.nl>
 */
 #include <cctype>
+using namespace std;
 
 #include "modified-font-metric.hh"
 #include "pango-font.hh"
index 90c3a2da2c47550f01f005a75c8285a3e1ebc6e1..d561aa7607b0509648bcc9335be5b6c3de3b666a 100644 (file)
@@ -172,8 +172,8 @@ Moment::operator - () const
 }
 
 #ifdef STREAM_SUPPORT
-std::ostream &
-operator << (std::ostream &os, Moment const &m)
+ostream &
+operator << (ostream &os, Moment const &m)
 {
   os << m.to_string ();
   return os;
index 022573f675f2026cf3595d7d6e1e358412fb493b..600eb2e702fcc7ff9eae340fe222383cfa2c89f0 100644 (file)
@@ -13,6 +13,7 @@
 #include "music-iterator.hh"
 
 #include <cstdio>
+using namespace std;
 
 #include "warn.hh"
 #include "context.hh"
index cbb4d07a7479500e65addc75bc41ead3373e71b6..353c40037b381e5ae1e70a8a7828e03496384003 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "note-collision.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "warn.hh"
 #include "note-column.hh"
index 1729e6b432fb23bf70bf85bef2228044b52c2943..974f220b79de2803b1ab656379e7cfaf69ff2021 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "note-column.hh"
 
-#include <math.h>              // ceil
+#include <cmath>               // ceil
+using namespace std;
 
 #include "axis-group-interface.hh"
 #include "stem.hh"
index fd7efe124f474765a186de7a150a620826c83b47..416dd0e2b9c36fb081436d6814205a8584d5ce1e 100644 (file)
@@ -8,10 +8,9 @@
 
 #include "note-head.hh"
 
-#include <math.h>
+#include <cmath>
 #include <cctype>
 #include <algorithm>           //  min, max
-
 using namespace std;
 
 #include "directional-element-interface.hh"
index c5731ab396150f8ed63d70850e8ab15a143a1fe6..34c65a1cbdd3af945c209a527974cf952f352260 100644 (file)
@@ -7,6 +7,7 @@
 #include "engraver.hh"
 
 #include <cctype>
+using namespace std;
 
 #include "rhythmic-head.hh"
 #include "output-def.hh"
index cd0c67c0572959f0a356dff016ed95399d1e67a1..a82a14f0e9067c87dd39a24757bee9e470512d68 100644 (file)
@@ -8,8 +8,10 @@
 
 #include "open-type-font.hh"
 
+#include <cstdio>
+using namespace std;
+
 #include <freetype/tttables.h>
-#include <stdio.h>
 
 #include "dimensions.hh"
 #include "modified-font-metric.hh"
index 31f9f79e772eed906cd3de3c116b1cd2a177875a..3f654ff3243eda6ed909d77d9299b0026ceaa628 100644 (file)
@@ -5,7 +5,8 @@
 
   (c) 2004--2005 Han-Wen Nienhuys <hanwen@xs4all.nl>
 */
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "dimensions.hh"
 #include "all-font-metrics.hh"
index de9c16fc87d9fa5e8dd141cd5f2dcc4054cbd6b1..e69d33bd950cc46e465dbc2e705af53a7cbb5f07 100644 (file)
@@ -9,8 +9,9 @@
 
 #include "paper-outputter.hh"
 
-#include <math.h>
+#include <cmath>
 #include <ctime>
+using namespace std;
 
 #include "dimensions.hh"
 #include "file-name.hh"
index db09db8754e5ccdb42c27203c2c08853cdd48a86..7cb8b34c099dce21694ecc2b9b444e51066f4271 100644 (file)
@@ -9,6 +9,7 @@
 #include "parse-scm.hh"
 
 #include <cstdio>
+using namespace std;
 
 #include "main.hh"
 #include "paper-book.hh"
index 3b72ec290b2d4674412423b4bfd87c362f3f08ac..475e556acea80761653b541511bd110aaf4d2321 100644 (file)
@@ -20,10 +20,10 @@ FIXME:
 
 #include "config.hh"
 
-#include <ctype.h>
-#include <stdlib.h>
-#include <stdio.h>
-
+#include <cctype>
+#include <cstdlib>
+#include <cstdio>
+using namespace std;
 
 #include "book.hh"
 #include "context-def.hh"
index a8c2a4d0ab69612429614784ff99142045cbfcd7..f3d81ba5434ce9cde5939a32bbe2b29b0bf9beef 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "percent-repeat-item.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "lookup.hh"
 #include "font-interface.hh"
index 087522ebb4456c1debec539cbb5ca573a95a0e87..985901c01cac1466af0dbfde49288548b131f614 100644 (file)
@@ -9,6 +9,7 @@
 #include "performance.hh"
 
 #include <ctime>
+using namespace std;
 
 #include "audio-column.hh"
 #include "audio-staff.hh"
index f255cb846e30eeb93aa0f68d2cdb0d6c0bed9196..8d1753de5ac83530f83da3530d6f3d3c14645f2d 100644 (file)
@@ -9,6 +9,7 @@
 #include <cstdlib>
 #include <cstdio>
 #include <cstring>
+using namespace std;
 
 #include "program-option.hh"
 #include "source-file.hh"
index de93d2dd76c25fc052f7e6cde092ec7912b519d3..03173d9c2730cf7564ff8744aa7bbac21d71df90 100644 (file)
@@ -9,7 +9,8 @@
 #include "program-option.hh"
 
 #include <cstdio>
-#include <string.h>
+#include <cstring>
+using namespace std;
 
 #include "string-convert.hh"
 #include "protected-scm.hh"
index 8ad587e88bd91a4b1a205821e38091b43780cec7..21ec8c9166816d161dd0e4b01e06d375edfabf71 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "rest-collision.hh"
 
-#include <math.h>              // ceil.
+#include <cmath>               // ceil.
+using namespace std;
 
 #include "warn.hh"
 #include "note-column.hh"
index b68af1d4ee91ad60b611cce3a694213d09628836..785facd09803080ac16c5cbcc5a8235fc3a0891e 100644 (file)
 
 #include <cstdio>
 #include <algorithm>
+using namespace std;
 
 #include "ly-smobs.icc"
 
-using namespace std;
-
 /*
   Return: number of objects.
 */
@@ -84,8 +83,8 @@ Scheme_hash_table::print_smob (SCM s, SCM p, scm_print_state*)
 }
 
 bool
-Scheme_hash_table::try_retrieve (SCM k, SCM *v)
-{
+Scheme_hash_table::try_retrieve (SCM k, SCM *v){
+
   SCM handle = scm_hashq_get_handle (hash_tab_, k);
   if (scm_is_pair (handle))
     {
index 75935f57eff3b7009ea8150f991a5a4207f72e73..b47c6d099b60bc0399ae04d08418ee5692fc4a2a 100644 (file)
@@ -9,6 +9,7 @@
 #include "score.hh"
 
 #include <cstdio>
+using namespace std;
 
 #include "book.hh"
 #include "cpu-timer.hh"
index 97790b3830dd5c3395808485e78d6af77326b5fb..05539cd1e3cc2af3783606c230a2937c5b46d364 100644 (file)
@@ -8,8 +8,9 @@
 
 #include "side-position-interface.hh"
 
-#include <math.h>              // ceil.
+#include <cmath>               // ceil.
 #include <algorithm>
+using namespace std;
 
 #include "note-head.hh"
 #include "warn.hh"
@@ -21,8 +22,6 @@
 #include "staff-symbol-referencer.hh"
 #include "string-convert.hh"
 
-using namespace std;
-
 void
 Side_position_interface::add_support (Grob *me, Grob *e)
 {
index 59027b3c3855f60f0a5bf9253e4eb1462b62c57e..6c95f421244b93abe912cd9e524ef7568e4b515f 100644 (file)
@@ -7,7 +7,8 @@
 */
 
 #include <cstdio>
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "paper-column.hh"
 #include "spring.hh"
index a37f040c86206122844051bc5fd343db864c16e3..2cccb6d83c435b75d510f8b45ce8cb3cd9167b22 100644 (file)
@@ -10,7 +10,8 @@
 */
 
 #include <cstdio>
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "libc-extension.hh"   // isinf
 #include "simple-spacer.hh"
index 4e14589d81e8b54e419f21a47f03a9688b854e72..6f86fd432a3d29ea86b89ccd73fd91f284af2eed 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "slur-configuration.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "stem.hh"
 #include "warn.hh"
index b5a91f467867cba24bbce69eb5123992614720ac..bcb65320ed5d6029e400321a0cb0d34d750f220c 100644 (file)
@@ -7,7 +7,8 @@
   Jan Nieuwenhuizen <janneke@gnu.org>
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "slur-scoring.hh"
 #include "libc-extension.hh"
@@ -471,7 +472,8 @@ Slur_score_state::get_y_attachment_range () const
       if (extremes_[d].note_column_)
        {
          end_ys[d] = dir_
-           * max (max (dir_ * (base_attachments_[d][Y_AXIS] + parameters_.region_size_ * dir_),
+           * max (max (dir_ * (base_attachments_[d][Y_AXIS]
+                                         + parameters_.region_size_ * dir_),
                        dir_ * (dir_ + extremes_[d].note_column_->extent (common_[Y_AXIS], Y_AXIS)[dir_])),
                   dir_ * base_attachments_[-d][Y_AXIS]);
        }
index bdf75392418e40f7c6029052853fcc16847e1169..8159e0dd3dc81fffff267a2d381a496f3baec188 100644 (file)
@@ -9,7 +9,8 @@
 
 #include "slur.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "beam.hh"
 #include "bezier.hh"
index 74bb5c3b40ac75c7954fd7db20c8048b0b9124e9..13661d77ef6e5682cef7be0c37b0c5f49ead168b 100644 (file)
@@ -14,7 +14,7 @@
 #if HAVE_UTF8_WCHAR_H
 #include <utf8/wchar.h>  /* mbrtowc */
 #else
-#include <wchar.h> /* mbrtowc */
+#include <cwchar> /* mbrtowc */
 #endif
 
 #include <cstdio>
@@ -25,6 +25,7 @@
 #include <strstream>
 #define istringstream(x) istrstream (x, length ())
 #endif
+using namespace std;
 
 #include "warn.hh"
 #include "file-name-map.hh"
@@ -128,17 +129,17 @@ Source_file::tell () const
   return pos_str0_ - contents_str0_;
 }
 
-std::istream *
+istream *
 Source_file::get_istream ()
 {
   if (!istream_)
     {
       if (length ()) // can-t this be done without such a hack?
-       istream_ = new std::istringstream (to_str0 ());
+       istream_ = new istringstream (to_str0 ());
       else
        {
-         istream_ = new std::istringstream ("");
-         istream_->setstate (std::ios::eofbit);
+         istream_ = new istringstream ("");
+         istream_->setstate (ios::eofbit);
          //      istream_->set (ios::eofbit);
        }
     }
index 4c78ab82403c054efdbed21798ca205b7a84a05b..12012be46d9df5500148977af8b5675f18691082 100644 (file)
@@ -9,7 +9,8 @@
 #include "spaceable-grob.hh"
 
 #include <cstdio>
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "warn.hh"
 #include "spring.hh"
index 2b9da0b80262071741f2b2fe9b19fa81c3fc4d91..0581deb8bd6951990d01e39007cabf383d4b1065 100644 (file)
@@ -6,8 +6,9 @@
   (c) 1999--2005 Han-Wen Nienhuys <hanwen@cs.uu.nl>
 */
 
-#include <math.h>
+#include <cmath>
 #include <cstdio>
+using namespace std;
 
 #include "spacing-spanner.hh"
 #include "paper-column.hh"
index 2c961fffc17f203d62f069cf526f86adbf57da6c..33e1a7cb2493af773da4b44bd654993becb97e91 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "spanner.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "pointer-group-interface.hh"
 #include "libc-extension.hh"
index 735436e14219fe464e7ddd599b46a602e75dd9f2..48e0c09f6b246569b63dd086e9deb4e643b65f9a 100644 (file)
@@ -9,6 +9,7 @@
 #include "staff-spacing.hh"
 
 #include <cstdio>
+using namespace std;
 
 #include "paper-column.hh"
 #include "separation-item.hh"
@@ -76,8 +77,7 @@ Staff_spacing::next_note_correction (Grob *me,
            stem_posns.intersect (bar_size);
 
            Real corr = min (abs (stem_posns.length () / 7.0), 1.0);
-           corr
-             *= robust_scm2double (me->get_property ("stem-spacing-correction"), 1);
+           corr *= robust_scm2double (me->get_property ("stem-spacing-correction"), 1);
 
            if (d != DOWN)
              corr = 0.0;
index 80db80ba065d40e7d8689812a7e5b606b1077468..7ad89794f9cbf1580bc9156fc54c8b12c12e5af0 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "staff-symbol-referencer.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "staff-symbol.hh"
 #include "output-def.hh"
index bd42bbb1e93e95b771158f1aa091a1b7f2accb48..06940e387f91426153e05f6837b6fc7d57183b21 100644 (file)
@@ -15,7 +15,8 @@
 
 #include "stem.hh"
 
-#include <math.h>              // rint
+#include <cmath>               // rint
+using namespace std;
 
 #include "lookup.hh"
 #include "directional-element-interface.hh"
@@ -608,7 +609,8 @@ Stem::width_callback (SCM e, SCM ax)
 
   if (is_invisible (me))
     r.set_empty ();
-  else if (unsmob_grob (me->get_object ("beam")) || abs (duration_log (me)) <= 2)
+  else if (unsmob_grob (me->get_object ("beam"))
+          || abs (duration_log (me)) <= 2)
     {
       r = Interval (-1, 1);
       r *= thickness (me) / 2;
index cc046d51c341d78b8141598368d324be17d1ed92..1bf2eab21387312447a1411fa8a8ff86049b9102 100644 (file)
@@ -6,7 +6,8 @@
   (c) 1997--2005 Han-Wen Nienhuys <hanwen@cs.uu.nl>
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "font-metric.hh"
 #include "libc-extension.hh"
index b8bad87875afade6df082406940f629f33a23dce..fd8a19d3e2987b68061939ba968a2e7994c7f439 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "stencil.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "dimensions.hh"
 #include "font-metric.hh"
index 24be5bb59581554249385243571755f367a61724..33ba97f16524635cef4cb70545b3fed1194f64d5 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "system-start-delimiter.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "spanner.hh"
 #include "axis-group-interface.hh"
index 932e7ce8c631beec322bfd9ce069ac03f7032b51..4ce6a9c00ec876c7aed5c4ae545a2b94f7182323 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "system.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "align-interface.hh"
 #include "axis-group-interface.hh"
index 2aad5ce6ee4de9535e803fd6e25bbf28a943fdc7..49a760bec1400cd554b21c796378dab357e1213e 100644 (file)
@@ -8,6 +8,7 @@
 
 #include <cctype>
 #include <cstdio>
+using namespace std;
 
 #include "rhythmic-head.hh"
 #include "output-def.hh"
index ab23ee70e5b6c4e76a92d3db84bffd20d95a08bf..4c28ee8671373ecd3304da89fad76a938b3d8052 100644 (file)
@@ -9,7 +9,8 @@
 
 #include "text-interface.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "main.hh"
 #include "config.hh"
index df6b7f18c8c893d283cdcb51632841da3fd995f9..76d45004cba8fc0ed34e35e765bf8c8c173a888c 100644 (file)
@@ -8,8 +8,7 @@
 
 #include "tie-column.hh"
 
-#include <math.h>
-#include <map>
+#include <cmath>
 
 #include "skyline.hh"
 #include "warn.hh"
@@ -20,6 +19,8 @@
 #include "directional-element-interface.hh"
 #include "tie-column-format.hh"
 
+using namespace std;
+
 void
 Tie_column::add_tie (Grob *me, Grob *tie)
 {
@@ -93,7 +94,7 @@ Tie_column::new_directions (Grob *me)
   if (ties.size() == 1)
     {
       Tie::set_default_control_points (ties[0]);
-      return ;
+      return;
     }
   
   ties.sort (&Tie::compare);
index 132e7c303cb7494baa50e0ebb77c0642056c8a98..8d5a427615f9f217016fb343ecc938d38d7adc31 100644 (file)
@@ -7,7 +7,8 @@
 
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "tie.hh"
 #include "bezier.hh"
index cf2c4d5a389f3c73e292690ca2d23f9d27ac2064..40664a67e7006f83def3cba8fc00551390f0ac16 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "tie.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "spanner.hh"
 #include "lookup.hh"
index 3442e2d522ec91ed67ba18cf0220fb0b38afaab3..a95e66611072fc377c2e2e10aefa11bacabd4563 100644 (file)
@@ -29,7 +29,8 @@
   todo: handle breaking elegantly.
 */
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "tuplet-bracket.hh"
 #include "line-interface.hh"
index 62a72141a1a0f42e2d86d14febce17a0fe37044f..eefe2fe760dc85ae4fa292957d64a0f2db51cbb6 100644 (file)
@@ -8,7 +8,8 @@
 
 #include "vaticana-ligature.hh"
 
-#include <math.h>
+#include <cmath>
+using namespace std;
 
 #include "item.hh"
 #include "font-interface.hh"
index 10e4a228b02d4d95dd2dca0a2a0c2cca54c3b064..36b7e5cf0d4937f4a009f297ae3303477d1aa888 100644 (file)
@@ -7,6 +7,7 @@
 */
 
 #include <cstring>
+using namespace std;
 
 #include "warn.hh"
 #include "font-interface.hh"
index 5d5e7fba470c3c0954fbc8bc05d4cc3dde51c255..168e9f774928c1560afa068be77ebd5fec5d4610 100644 (file)
@@ -34,7 +34,7 @@ static PyObject *Midi_warning;
 static PyObject *
 midi_error (char const *func, char *s)
 {
-  char*dest = (char*) malloc (sizeof (char) * (strlen (func) + strlen (s) + 1));
+  char *dest = (char*) malloc (sizeof (char) * (strlen (func) + strlen (s) + 1));
   strcpy (dest, func);
   strcat (dest, s);
   PyErr_SetString (Midi_error, dest);
index 40d03d1aa0f905df1f7a4b4c1f3887952c4e0cb0..d5e67b889c0a7477bab3d68a7ef801e341ba0ac0 100644 (file)
@@ -2,6 +2,9 @@
 include $(stepdir)/compile-vars.make
 
 EXTRA_CXXFLAGS= -W -Wall -Wconversion
+#ifeq ($(MY_PATCH_LEVEL),)
+EXTRA_CXXFLAGS += -Werror
+#endif
 
 ALL_CXXFLAGS = $(CXXFLAGS) $(ICFLAGS) $(DEFINES) $(addprefix -I,$(INCLUDES)) $(USER_CFLAGS) $(EXTRA_CFLAGS) $(MODULE_CFLAGS) $($(PACKAGE)_CFLAGS) $($(PACKAGE)_CXXFLAGS) $(USER_CXXFLAGS) $(EXTRA_CXXFLAGS) $(MODULE_CXXFLAGS)