jacob navia <> writes:
> Le 17/02/11 19:53, Ian Collins a ecrit :
[...]
>> But the files will be cached on the local host.
>>
>
> Yes, and the cost of inclusion can be avoided with
> #pragma once
Which is of course non-standard, but it's widely implemented.
Implementing it correctly in the presence of, for example, symbolic
links that refer to the same file can be tricky.
> or the old
> #ifndef __STDHEADERS_H
> #define __STDHEADERS_H
> ...
> #endif
Which still incurs the cost of scanning the entire file (unless the
compiler specifically optimizes this case, as I understand gcc does).
Note that the identifier __STDHEADERS_H is reserved to the
implementation.
--
Keith Thompson (The_Other_Keith)
kst- <http://www.ghoti.net/~kst>
Nokia
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"