Boost logo

Boost Testing :

Subject: Re: [Boost-testing] Disable test if not compiling with c++11
From: John Maddock (jz.maddock_at_[hidden])
Date: 2016-07-17 03:43:31


> But I say limited because not many compilers will set the language
> predef even if they support some particular C++11 feature you need.
> And depending on the language feature you could also use the Boost
> Config check utility [2].
>

It cut's both ways: there are compilers that don't set __cplusplus to
the 2011 value but which will none the less compile your code, others
which do, but which will not compile your code. So I would be inclined
to use the actual config check macros you use in your code in the
Boost.Config build checks. Also add some #ifdef's to the test case
source so it becomes a "do nothing" test on compilers that don't support
the features you're using.

HTH, John.

>
> [1]
> <http://www.boost.org/doc/libs/1_61_0/libs/predef/doc/html/predef/check_utilities.html>
> [2]
> <http://www.boost.org/doc/libs/1_61_0/libs/config/doc/html/boost_config/build_config.html>
>
>
> --
> -- Rene Rivera
> -- Grafik - Don't Assume Anything
> -- Robot Dreams - http://robot-dreams.net <http://robot-dreams.net/>
> -- rrivera/acm.org
> <http://acm.org/> (msn) - grafikrobot/aim,yahoo,skype,efnet,gmail
>
>
> _______________________________________________
> Boost-Testing mailing list
> Boost-Testing_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-testing


Boost-testing list run by mbergal at meta-comm.com