STL_MSFT created this revision. STL_MSFT added reviewers: EricWF, mclow.lists. STL_MSFT added a subscriber: cfe-commits.
In atomics.types.generic/address.pass.cpp, use T(0) for consistency. Fixes MSVC "error C2593: 'operator ==' is ambiguous". There is almost certainly an MSVC compiler bug involved here (which I haven't reduced yet). However, T(0) was used previously in the test, so using it here increases consistency, in addition to making all compilers happy. http://reviews.llvm.org/D21714 Files: test/std/atomics/atomics.types.generic/address.pass.cpp Index: test/std/atomics/atomics.types.generic/address.pass.cpp =================================================================== --- test/std/atomics/atomics.types.generic/address.pass.cpp +++ test/std/atomics/atomics.types.generic/address.pass.cpp @@ -123,7 +123,7 @@ { _ALIGNAS_TYPE(A) char storage[sizeof(A)] = {23}; A& zero = *new (storage) A(); - assert(zero == 0); + assert(zero == T(0)); zero.~A(); } }
Index: test/std/atomics/atomics.types.generic/address.pass.cpp =================================================================== --- test/std/atomics/atomics.types.generic/address.pass.cpp +++ test/std/atomics/atomics.types.generic/address.pass.cpp @@ -123,7 +123,7 @@ { _ALIGNAS_TYPE(A) char storage[sizeof(A)] = {23}; A& zero = *new (storage) A(); - assert(zero == 0); + assert(zero == T(0)); zero.~A(); } }
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits