Subject: Re: [boost] BOOST_MSVC vs. _MSC_VER wrt #pragma warning
From: John Maddock (john_at_[hidden])
Date: 2009-12-01 06:19:13
>I understand that BOOST_MSVC is needed to detect MSVC because other
> compilers besides MSVC define _MSC_VER.
> But what about #ifdefing #pragma warning, should it use _MSC_VER or
> BOOST_MSVC? The reason why the ifdefing is needed is to prevent GCC
> and other compilers issuing a warning about #pragma warning, but
> presumably compilers that have _MSC_VER defined wouldn't warn about
> that, would they?
Well one would hope not, but I'm not so sure about Como, and even Borland
used to define _MSC_VER at one point - and they definitely didn't support
My gut feeling is that if BOOST_MSVC is available then make use of it, but I
could be wrong... John.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk