Hi Kai,

you wrote:
> On 15 Dec 2006 23:02:08 +0100, Thorsten Behrens
> <[EMAIL PROTECTED]> wrote:
> > BTW, and referring to external header guards: while I'm generally with
> > you regarding the degradation in readability (and increase in
> > coupling), are you really sure that all compilers we've in use
> > properly detect that case, and refrain from opening and parsing the
> > same header file multiple times?
> 
> Aah. Let me rephrase. Are -you- really sure the external include guard
> optimization provides enough benefit on all the compilers we are using
> to make it worthwhile to degrade readability by adding noise? Ie. is
> this a modest gain in machine time compared to a perhaps much costlier
> loss of human time? Can you provide some numbers to support this
> optimization or should we perhaps be conservative and not use it? ;-)
> 
ok, seems we've deadlocked here. ;-)

Point is, the vast majority of the code uses that idiom as of today,
and I'm reluctant to advice people of the contrary (as long as there
are build time degradations on at least one prominent platform, at
least when building on a network volume). Rather sooner than later,
all used compilers will perform this optimization by themselves, and
I'd say let's add the rule then. I'm relatively indifferent about
this, though - if people think it's ok to start removing external
header guards right now (because it will take years to clean them up
anyway), I'd be fine with that, too.

Cheers,

-- Thorsten

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to