Messages in this thread | | | Date | Mon, 14 Jul 2014 09:02:18 -0700 | From | Jeremiah Mahler <> | Subject | Re: [PATCH] xillybus: place 'else' on same line as '}' |
| |
Eli,
On Mon, Jul 14, 2014 at 09:40:39AM +0300, Eli Billauer wrote: > Hi, > > Thanks for this. > > And since I looked at the part in Codingstyle that deals with if-else, I > found another few mistakes regarding braces around a single statement. The > rules say, it turns out, that if one of the clauses in an if-else is longer > than one statement, both clauses should be wrapped with braces. This rule is > broken in lines 162, 536 and 613 of the same file. >
I just looked through CodingStyle, and you are right. If braces are used on one branch they should be used on all branches.
Interestingly, checkpatch.pl doesn't warn about these.
> ...
Cheers, -- Jeremiah Mahler jmmahler@gmail.com http://github.com/jmahler
| |