Subject: Re: [boost] Can we suppress integer_traits warnings?
From: John Maddock (john_at_[hidden])
Date: 2009-10-26 11:08:54
>> Sure, but we need to fix the *library header file* so it doesn't
>> emit warnings even when the user has asked for those warnings: we do
>> this already for long long usage within Boost, but I can't find a
>> workaround for constants with LL suffixes.
> Maybe #pragma GCC system_header is an option?
Ahah! That certainly seems to work, adding:
#if defined(__GNUC__) && ((__GNUC__ > 3) || ((__GNUC__ == 3) &&
(__GNUC_MINOR__ > 3)))
// The following code emits warnings when built with -pedantic, and there
// to be no other way of suppressing these warnings as use of __extension__
// effect, so declare the rest of this header a system header.
# pragma GCC system_header
near the end of the header, suppresses those warnings.
Any downsides or objections to this?
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk