Re: [libvirt] [PATCH v2 22/22] bracket-spacing: Add syntax-check for unnecessary curly brackets

2014-11-13 Thread Eric Blake
On 11/13/2014 07:37 AM, Martin Kletzander wrote: > We're looking for three consecutive lines, first one is a if/for/while > with a condition and start of body, second one is a body with one and > only semicolon and third is end of the body by itself. > > Signed-off-by: Martin Kletzander > --- >

Re: [libvirt] [PATCH v2 22/22] bracket-spacing: Add syntax-check for unnecessary curly brackets

2014-11-13 Thread Eric Blake
On 11/13/2014 04:18 PM, John Ferlan wrote: > > [1]I have to say the error one gets if they violate this rule: > > maint.mk: incorrect whitespace, see HACKING for rules > make: *** [bracket-spacing-check] Error 1 > Maybe we should change the message in cfg.mk to state 'incorrect formatting' inst

Re: [libvirt] [PATCH v2 22/22] bracket-spacing: Add syntax-check for unnecessary curly brackets

2014-11-13 Thread John Ferlan
On 11/13/2014 09:37 AM, Martin Kletzander wrote: > We're looking for three consecutive lines, first one is a if/for/while > with a condition and start of body, second one is a body with one and > only semicolon and third is end of the body by itself. > And because of a later ";;" check - one ca

[libvirt] [PATCH v2 22/22] bracket-spacing: Add syntax-check for unnecessary curly brackets

2014-11-13 Thread Martin Kletzander
We're looking for three consecutive lines, first one is a if/for/while with a condition and start of body, second one is a body with one and only semicolon and third is end of the body by itself. Signed-off-by: Martin Kletzander --- build-aux/bracket-spacing.pl | 35 +