[Klug-general] Obscure C at saturday's meeting

James Morris jwm.art.net at gmail.com
Mon Nov 29 16:22:59 UTC 2010


On 29 November 2010 12:53, Dan Attwood <danattwood at gmail.com> wrote:
>
>>
>> And for exactly this reason there has been a policy in places I have
>> worked of running any C code through the C beautifier automatically as part
>> of the version control check-in process.  This has the advantage that coders
>> arbitrarily rearranging the code in their preferred style whilst editing
>> does not look like a change, and that all code retrieved is always in the
>> house style, which makes for easier debugging.
>>
> someone at barcamp was talking about do just this. Although they went one
> step further where if it fell outside of some rules then they would stop it
> from compiling and spit it back at the developer

But for people learning to code, they're very useful constructs to
understand as to why such and such is happening rather than what might
be expected to happen - as long as the beginner understand that it is
usually better to write code that is clear than write code that is
clever (when there is the choice).



More information about the Kent mailing list