[Development] kdelibs coding style

Alan Alpert 416365416c at gmail.com
Tue Apr 30 22:04:40 CEST 2013


On Tue, Apr 30, 2013 at 12:38 PM, Lorn Potter <lorn.potter at gmail.com> wrote:
>
> On 01/05/2013, at 2:47 AM, Oswald Buddenhagen <oswald.buddenhagen at digia.com> wrote:
>
>> On Tue, Apr 30, 2013 at 09:01:51AM -0700, Thiago Macieira wrote:
>>> On segunda-feira, 29 de abril de 2013 23.30.59, André Pönitz wrote:
>>>> The rules are ok as they are (pretty much as _any_ set of consistently
>>>> applied and not-completely-weird rules). Opening them up only leads to
>>>> more review bikeshedding.
>>>>
>>>> It's not that people actively change coding style in old Qt code, and
>>>> there's always the "don't stick to the rules if it makes you look bad"
>>>> excuse.
>>>
>>> Let's not try to change any of the rules, since this leads to bikeshedding,
>>> like André said. It clearly has already become that.
>>>
>> so let's meta-bikeshed instead?
>>
>>> So let's just change the interpretation: the "don't stick to the rules" allows
>>> us to accept a slightly different style if that makes it nicer. That should be
>>> enough to apply to the case of braces in single-line ifs.
>>>
>> now, that is kinda ridiculous. the cop-out rule exists to justify
>> exceptions in corner cases, not to give everyone a free pass for their
>> coding style preferences.
>
> If I recall, it was also to give developers a little freedom in their expression.

I had assumed it was also to prevent people wasting time on big
arguments over whitespace. So long as the code isn't a hideous mess
then you are permitted to focus on more important edits.

Drawing it back to Thiago's question, the style guides sound close
enough already that I don't think we'll get real gains by worrying
about it. I feel that the cost of a few extra braces here or a few
fewer braces there is less than a twenty e-mail debate, which seems to
be the alternative ;) .

--
Alan Alpert



More information about the Development mailing list