I had the same problem with vc 7.1.
Strange. I never had problems like this with vc7.1
It's very easy to reproduce the problem. Create project with two
source files (e.g. a.cpp and b.cpp) both with the same content:
-- begin
#include
-- end
When you try to compile you get two errors:
b.obj : error LNK2005: "struct
check_is_small_t::boost::check_is_small_t
boost::test_tools::`anonymous namespace'::check_is_small"
(?check_is_small@?A0xa003c394@test_tools@boost@@3Ucheck_is_small_t@23@A)
already defined in a.obj
b.obj : error LNK2005: "struct
check_is_close_t::boost::check_is_close_t
boost::test_tools::`anonymous namespace'::check_is_close"
(?check_is_close@?A0xa003c394@test_tools@boost@@3Ucheck_is_close_t@23@A)
already defined in a.obj
boost version 1.33.1.
If you add 'static' to all
variables definitions in anonymous namespaces it works fine.
But anonimous namespace should do the trick itself!
Agree. Seems like compiler bug to me.
Roman.