bug-gnulib
[Top][All Lists]
Advanced

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

[Bug-gnulib] Re: getaddrinfo


From: Simon Josefsson
Subject: [Bug-gnulib] Re: getaddrinfo
Date: Tue, 09 Nov 2004 18:23:54 +0100
User-agent: Gnus/5.110003 (No Gnus v0.3) Emacs/21.3.50 (gnu/linux)

address@hidden (Bob Proulx) writes:

> Simon Josefsson wrote:
>> > > +  if (hints &&
>> > GNU coding style (section "Formatting Your Source Code") recommends
>> > to put the operator && into the next line.
>> 
>> I'm using "indent", which seem to miss that.  Fixed manually.
>
> The -bbo option.  In your ~/.indent.pro file:
>
>   --break-before-boolean-operator
>
> But this should be the default with GNU indent.  From the manual for
> version 2.2.9:
>
>      As of version 1.2, the default style of GNU `indent' is the GNU
>   style.  Thus, it is no longer necessary to specify the option `-gnu' to
>   obtain this format, although doing so will not cause an error.  Option
>   settings which correspond to the GNU style are:
>
>        -nbad -bap -nbc -bbo -bl -bli2 -bls -ncdb -nce -cp1 -cs -di2
>        -ndj -nfc1 -nfca -hnl -i2 -ip5 -lp -pcs -nprs -psl -saf -sai
>        -saw -nsc -nsob
>
> Perhaps you have an opposing option in your ~/.indent.pro file?

Nope.  I'm using 2.2.9.  I found the same style in many of my files,
and I'm using indent on all of them.  I can reproduce it by running
indent on a file containing:

void
shishi_key_value_set (Shishi_key * key, const char *value)
{
  if (value &&
      shishi_cipher_keylen (key->type) > 0 &&
      shishi_cipher_keylen (key->type) <= MAX_KEY_LEN)
    memcpy (key->value, value, shishi_cipher_keylen (key->type));
}





reply via email to

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