Date: prev next · Thread: first prev next last
2013 Archives by date, by thread · List index


On 03/22/2013 06:41 PM, Michael Stahl wrote:
On 22/03/13 18:25, Stephan Bergmann wrote:
On 03/21/2013 05:28 PM, Jan Holesovsky wrote:
* Kill include guards in .hxx, and use #pragma once instead
          + makes the headers nicer
          + the benchmark available on the net seems to suggest it speeds
            up MSVC
          + Lubos' test seems to suggest that there is ~no difference for
            gcc
        + consensus: let's just do it after 4.0.2 is out

The only drawback I can find is that #pragma once is non-standard and
therefore
<http://gcc.gnu.org/onlinedocs/gcc-4.7.2/cpp/Alternatives-to-Wrapper-_0023ifndef.html#Alternatives-to-Wrapper-_0023ifndef>---arguably
rightly so---recommends against its use.

hmm... does that really matter?

Hopefully not. But if the claimed MSVC speedup was non-existent, it would be humble to go with the (not completely inadequate, after all) standard means and avoid one potential pitfall. (/Every/ deviation from the standard, however minuscule, is bound to bite us one day down the road.) Or maybe not. Anyway, I should probably have inserted "very minor" before "drawback," or even kept away from the keyboard entirely... ;)

Stephan

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.