lilypond-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074)


From: Neil Puttock
Subject: Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074)
Date: Sun, 3 Jul 2011 14:25:12 +0100

On 3 July 2011 12:49, Graham Percival <address@hidden> wrote:

> I've spent a few minutes skimming through it without finding
> anything disagreeable.

A few fishy looking changes:

   int lily_cookie_fprintf (void *file, char const *format, ...)
-    __attribute__ ((format (printf, 2, 3)));
+  __attribute__ ((format (printf, 2, 3)));

It looks like the function attribute isn't associated with the function above.

diff --git a/flower/include/matrix.hh b/flower/include/matrix.hh

index 6a9576c..4f8f7d4 100644 (file)


--- a/flower/include/matrix.hh
+++ b/flower/include/matrix.hh
@@ -22,8 +22,8 @@

 #include "std-vector.hh"

-template<class T, class A=std::allocator<T> >
-class Matrix
+template < class T, class A = std::allocator<T>
+> class Matrix

templates are a bit messed up

 {
 public:
   Matrix<T, A> ()
@@ -32,7 +32,7 @@ public:
   }

   Matrix<T, A> (vsize rows, vsize columns, T const &t)
-  : data_(rows * columns, t)
+    : data_ (rows *columns, t)

misinterpreted multiplication sign

diff --git a/flower/include/rational.hh b/flower/include/rational.hh

index bf01c8b..b0dd95b 100644 (file)


--- a/flower/include/rational.hh
+++ b/flower/include/rational.hh
@@ -74,7 +74,8 @@ public:
   Rational (Rational const &r) { copy (r);}
   Rational &operator = (Rational const &r)
   {
-    copy (r); return *this;
+    copy (r);
+    return *this;
   }

   Rational &operator *= (Rational);
@@ -89,11 +90,11 @@ public:

 #include "arithmetic-operator.hh"

-IMPLEMENT_ARITHMETIC_OPERATOR (Rational, /);
+IMPLEMENT_ARITHMETIC_OPERATOR (Rational, / );
 IMPLEMENT_ARITHMETIC_OPERATOR (Rational, +);
 IMPLEMENT_ARITHMETIC_OPERATOR (Rational, *);
 IMPLEMENT_ARITHMETIC_OPERATOR (Rational, -);
-IMPLEMENT_ARITHMETIC_OPERATOR (Rational, %);
+IMPLEMENT_ARITHMETIC_OPERATOR (Rational, % );

extra space before closing parenthesis

diff --git a/flower/rational.cc b/flower/rational.cc

index fbac400..2d57eeb 100644 (file)


--- a/flower/rational.cc
+++ b/flower/rational.cc
@@ -133,7 +131,6 @@ Rational::mod_rat (Rational div) const
   return r;
 }

-
 /*
   copy & paste from scm_gcd (GUILE).
  */
@@ -162,7 +159,7 @@ gcd (I64 u, I64 v)
       else
         {
           t = u;
-        b3:
+b3:

goto label unindented

diff --git a/lily/audio-item.cc b/lily/audio-item.cc

index 5c9150f..4b3ee81 100644 (file)


--- a/lily/audio-item.cc
+++ b/lily/audio-item.cc
@@ -39,18 +39,12 @@ Audio_item::get_column () const
 }

 Audio_item::Audio_item ()
-  : audio_column_ (0)
-  , channel_ (0)
+  : audio_column_ (0), channel_ (0)
 {
 }

ctor init list move to single line

Cheers,
Neil



reply via email to

[Prev in Thread] Current Thread [Next in Thread]