Thanks for all the suggestions.

I'll work to get them onto our list.  If we are able to use your patches as is, 
we might get back to you about copyright assignment.

Thanks,
Dan

--
Daniel P. Valentine

On Jun 15, 2015, at 2:53 PM, Tim Hentenaar <t...@hentenaar.com> wrote:

> Initializer lists wern't being properly detected as block
> initializers and thus were being formatted with a newline forced after
> the opening brace.
> 
> The newly added -sar option will add spaces between the braces and the
> inner part of the initializer for those who prefer it. I've alwo added
> this to the K&R style, as this style can be clearly seen in The C
> Programming Language 2nd Ed.
> ---
> ChangeLog         |  3 +++
> doc/indent.texi   | 46 ++++++++++++++++++++++++++++++++++++++++++++++
> regression/TEST   |  3 ++-
> src/args.c        |  6 +++++-
> src/handletoken.c | 19 +++++++++++++++++--
> src/indent.h      |  1 +
> 6 files changed, 74 insertions(+), 4 deletions(-)
> 
> diff --git a/ChangeLog b/ChangeLog
> index 3807fe2..facc512 100644
> --- a/ChangeLog
> +++ b/ChangeLog
> @@ -1,5 +1,8 @@
> 2015-06-15 Tim Hentenaar <t...@hentenaar.com>
>    * Added -par to -kr.
> +    * Fixed detection of struct initializer lists as block_init.
> +    * Added an option (-sar/--spaces-around-initializers) to add a space
> +      after the lbrace and before the rbrace of struct initializers.
> 
> 2015-06-14 Tim Hentenaar <t...@hentenaar.com>
>    * Added an option (-as/--align-with-spaces) which if indenting with
> diff --git a/doc/indent.texi b/doc/indent.texi
> index 68ea82d..858c632 100644
> --- a/doc/indent.texi
> +++ b/doc/indent.texi
> @@ -1214,6 +1214,45 @@ int one(void)
> @end group
> @end example
> 
> +@noindent
> +@kindex -sar

_______________________________________________
bug-indent mailing list
bug-indent@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-indent

Reply via email to