[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074)
From: |
Keith OHara |
Subject: |
Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074) |
Date: |
Sun, 03 Jul 2011 12:13:27 -0700 |
User-agent: |
Opera Mail/11.50 (Win32) |
On Sun, 03 Jul 2011 05:18:32 -0700, Carl Sorensen <address@hidden> wrote:
if (Score *newscore = unsmob_score (entry))
- *t = scm_cons (newscore->clone ()->unprotect (), SCM_EOL);
+ * t = scm_cons (newscore->clone ()->unprotect (), SCM_EOL);
else if (Page_marker *marker = unsmob_page_marker (entry))
- *t = scm_cons (marker->clone ()->unprotect (), SCM_EOL);
+ * t = scm_cons (marker->clone ()->unprotect (), SCM_EOL);
Astyle bug. She gets this wrong confused iff the condition contains an
assignment.
int
-Book::print_smob (SCM, SCM p, scm_print_state*)
+Book::print_smob (SCM, SCM p, scm_print_state *)
{
Astyle being consistent. GNU puts the * (and similarly, &) next to the name in
declarations, char *p, so we included --align-pointer=name in the astyle option
list.
On Sun, 03 Jul 2011 06:25:12 -0700, Neil Puttock <address@hidden> wrote:
A few fishy looking changes:
int lily_cookie_fprintf (void *file, char const *format, ...)
- __attribute__ ((format (printf, 2, 3)));
+ __attribute__ ((format (printf, 2, 3)));
Astyle bad. It would be better if she indents line-broken headers/statements,
when there are no operators to align on.
-template<class T, class A=std::allocator<T> >
-class Matrix
+template < class T, class A = std::allocator<T>
+> class Matrix
Prefilter bad, I think. The original fixcc prefilter padded, then tried to un-pad,
these <>. I /thought/ I had removed all this.
Matrix<T, A> (vsize rows, vsize columns, T const &t)
- : data_(rows * columns, t)
+ : data_ (rows *columns, t)
Astyle bad. Thinks rows might be a typedef (but it cannot be, here).
-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, % );
Astyle inconsistent. Although macros do violate C syntax.
- b3:
+b3:
goto label unindented
G> We could use --indent-labels for this
Probably best to let astyle un-indent goto labels, rather than follow the block
structure, because goto functions completely outside the block structure.
--- 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
G> I'm surprised astyle gets this wrong!
Prefilter bad (so you are right to be surprised). It closes the linebreak
before a dangling comma, whereas it should swap ',' with '\n' -- or maybe just
leave these alone.
Looks like I should reduce the pre-filter further, but I'm tired of poring over
diffs and regexps (because I made several passes earlier) so I'll do it later
in the day. Thanks for setting up the branch, Graham.
Anything left in our pre-filter could be converted to patches to submit for Astyle, as
I've done already for "foo ((bar *)fim)".
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), (continued)
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), percival . music . ca, 2011/07/03
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), k-ohara5a5a, 2011/07/03
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Keith OHara, 2011/07/03
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Neil Puttock, 2011/07/03
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Graham Percival, 2011/07/03
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Neil Puttock, 2011/07/03
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Graham Percival, 2011/07/03
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074),
Keith OHara <=
Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), k-ohara5a5a, 2011/07/03
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Trevor Daniels, 2011/07/04
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Jan Nieuwenhuizen, 2011/07/04
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Graham Percival, 2011/07/04
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Reinhold Kainhofer, 2011/07/04
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Carl Sorensen, 2011/07/04
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Jan Nieuwenhuizen, 2011/07/04
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Graham Percival, 2011/07/04
- Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Jan Nieuwenhuizen, 2011/07/05
Re: Adapt fixcc.py to use Astyle instead of emacs (issue4662074), Trevor Daniels, 2011/07/04