Skip to Content.
Sympa Menu

freetds - Re: element of style

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Brian Bruns <camber AT ais.org>
  • To: TDS Development Group <freetds AT franklin.metalab.unc.edu>
  • Subject: Re: element of style
  • Date: Sat, 24 Aug 2002 12:58:10 -0400 (EDT)


On 24 Aug 2002, Frediano Ziglio wrote:

> Il sab, 2002-08-24 alle 13:26, Brian Bruns ha scritto:
> > On 24 Aug 2002, Frediano Ziglio wrote:
> >
> > > Il sab, 2002-08-24 alle 09:09, James K.Lowden ha scritto:
> > > > Contributors,
> > > >
> > > > There are several places in e.g. tds/convert.c that use comparisons to
> > > > very strange decimal numbers. I'd like to see us use hex instead,
> > > > when
> > > > we're looking for overflow conditions and such.
> > >
> > > Sound right..
> > > Perhaps should best to add a CodingStyle document to FreeTDS...
> >
> > http://www.freetds.org/CodingStyle
> >
>
> Should be
> switch(x) {
> case XXX:
> ...
> break;
> ...
> }
> or
> switch(x) {
> case XXX:
> ...
> break;
> ...
> }
> ?
> (I prefer first type)

Most code is written in the second style. I personally don't care as long
as we are all doing the same thing on this. Time for a straw poll?

>
> struct XXX {
> ...
> };
> or
> struct XXX
> {
> ...
> };
> ?
> (I prefer second type)

Second type it is. All the typedefs in the header files do this, although
I notice some recent code going with the first style. I'll make some
notes in the doc.

> freddy77
>
>





Archive powered by MHonArc 2.6.24.

Top of Page