the inevitable C formatting/brace style flamewar

Lubos Lunak l.lunak at suse.cz
Tue Oct 9 08:26:20 PDT 2012


On Friday 17 of August 2012, Jan Holesovsky wrote:
> Hi Michael,
>
> Michael Stahl píše v Čt 16. 08. 2012 v 19:07 +0200:
> > if memory serves i've reviewed 2 patches in the last 3 months or so that
> > added a statement to a 1-line then or else clause that was indented but
> > did not have braces, and the author indented his new line and forgot the
> > braces.  clearly that indicates to me that syntax significant
> > indentation (as in Haskell or Python) is an excellent idea that prevents
> > bugs
>
> How comes that clang does not have a warning for that?  Or does it
> have? ;-)
>
> If it does not, and yet these errors happen so often - it might be
> useful to create a check for that based on the recent Lubos' clang
> magic.  EasyHack, maybe?

 For the record, the warning is now in as a part of the Clang compile plugin.

-- 
 Lubos Lunak
 l.lunak at suse.cz


More information about the LibreOffice mailing list