Complete.Org: Mailing Lists: Archives: freeciv-dev: February 2004:
[Freeciv-Dev] Re: (PR#7369) [RFC] Coding style
Home

[Freeciv-Dev] Re: (PR#7369) [RFC] Coding style

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: undisclosed-recipients: ;
Subject: [Freeciv-Dev] Re: (PR#7369) [RFC] Coding style
From: "Raimar Falke" <i-freeciv-lists@xxxxxxxxxxxxx>
Date: Mon, 2 Feb 2004 00:54:50 -0800
Reply-to: rt@xxxxxxxxxxx

<URL: http://rt.freeciv.org/Ticket/Display.html?id=7369 >

On Mon, Feb 02, 2004 at 12:33:45AM -0800, Jason Short wrote:
> > We currently have both
> >
> > int foo()
> > {
> >   return p->bar;
> > }
> >
> > and
> >
> > int foo()
> > {
> >   return (p->bar);
> > }
> >
> > Can we change to coding style so that one is preferred?

> Note that the first is formatted "properly" according to the style
> guide

I searched the style guide before I posted this one and found
nothing. While it contains examples of the first one it doesn't state
anything about what should be used and what not.

> (and most editors will give you this).  AFAIK the style guide does not
> specify a formatting for the second (and editors may be inconsistent).

> So my preference would be: no-parenthesis for single-line,
> parenthesis for multi-line.

While this is also my personal preference it is inconsistent.

        Raimar

-- 
 email: rf13@xxxxxxxxxxxxxxxxx
 "Your mail could not be delivered to the following Address:
  VTCMC.VTLPR@xxxxxxxxxxxxx        ** Unassigned error message **"




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