[Boost.Test][Boot.Timer v2] header only boost.test conflicts with Boot.Timer V2
This following simple snippet would yield an error with visual studio 2015 for both boost1.60.61:
boost/timer/timer.hpp(32): error C2757: 'timer': a symbol with this name already exists and therefore this name cannot be used as a namespace name
// compiled with cl.exe /EHsc
#define BOOST_TEST_MODULE test
#include
Le 29/05/16 à 08:59, Tan, Tom (Shanghai) a écrit :
This following simple snippet would yield an error with visual studio 2015 for both boost1.60.61:
boost/timer/timer.hpp(32): error C2757: 'timer': a symbol with this name already exists and therefore this name cannot be used as a namespace name
[snip]
It looks like Boost.Test is relying on boost.timer v1, which is deprecated in documentation and conflict with V2.
Hi, This is a known issue: - https://svn.boost.org/trac/boost/ticket/9434 - https://svn.boost.org/trac/boost/ticket/7397 - http://lists.boost.org/Archives/boost/2013/10/207072.php - http://lists.boost.org/Archives/boost/2015/01/219127.php However, I do not know if Timer v2 has a header only option now, I believe it is not (since I haven't created a ticket ...). Raffi
On 29/05/16 17:04, Raffi Enficiaud wrote:
Le 29/05/16 à 08:59, Tan, Tom (Shanghai) a écrit :
This following simple snippet would yield an error with visual studio 2015 for both boost1.60.61:
boost/timer/timer.hpp(32): error C2757: 'timer': a symbol with this name already exists and therefore this name cannot be used as a namespace name
[snip]
It looks like Boost.Test is relying on boost.timer v1, which is deprecated in documentation and conflict with V2.
Hi,
This is a known issue: - https://svn.boost.org/trac/boost/ticket/9434 - https://svn.boost.org/trac/boost/ticket/7397 - http://lists.boost.org/Archives/boost/2013/10/207072.php - http://lists.boost.org/Archives/boost/2015/01/219127.php
And after going through the pain of trying to make this a run time option (other boost dependencies still saw this break) I actually think the original patch is the best way to deal with this "now" as it relied (as I recall) on using a #define to choose the correct Boost.Timer. Such an approach seems fairly standard in boost after-all. Jamie
However, I do not know if Timer v2 has a header only option now, I believe it is not (since I haven't created a ticket ...).
Raffi
_______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
participants (3)
-
Jamie Allsop
-
Raffi Enficiaud
-
Tan, Tom (Shanghai)