Re: astyle issues

From: Robert Collins <robertc@dont-contact.us>
Date: 23 Feb 2003 01:27:14 +1100

On Sun, 2003-02-23 at 01:21, Henrik Nordstrom wrote:
> There seems to be a couple very annoying bugs in the astyle styling...

Urk. Ok.

> 1. bitfields
>
> unsigned int transparent:
> 1; /* transparent proxy */
>
> Issues:
> Broken into multiple lines after the :
> Always flushed fully to the left, not indented.
>
> Should read:
> unsigned int transparent:1 /* transparent proxy */

Does one of the astyle patches you mentioned address this?

IIRC it's the break-blocks flag that causes this. The reason we use that
flag is to separate functions:

int
foo ()
{
}
int bar ()
{
}

without break blocks won't change. With it, it becomes:

int
foo ()
{
}

int
bar ()
{
}

> 2. struct and typedef "inline" variable declarations
>
> struct
> {
> [...]
> }
>
> Wais;
>
> Issues:
> Blank line between the } and the variable/typedef name.
>
> Should read:
>
> struct
> {
> [...]
> } Wais;

I don't think this is a biggy: as we get more OOP, anonymous structs
will dissappear almost completely.

-- 
GPG key available at: <http://users.bigpond.net.au/robertc/keys.txt>.

Received on Sat Feb 22 2003 - 07:27:22 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:19:17 MST