From db2f30b77c6664f90231b9eeb14d3ba1d92925cc Mon Sep 17 00:00:00 2001 From: Beman Date: Mon, 13 May 2013 11:05:31 -0400 Subject: [PATCH] Better fix that works with more compilers, old and new, VC++ and GCC. --- test/endian_test.cpp | 2 +- test/msvc2012/endian_test/endian_test.vcxproj | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/test/endian_test.cpp b/test/endian_test.cpp index 72fb00c..e67715f 100644 --- a/test/endian_test.cpp +++ b/test/endian_test.cpp @@ -74,7 +74,7 @@ namespace ++v; // verify integer_cover_operators being applied to this type - // will fail to compile if no endian<> specialization is present - Endian x = v+v; + Endian x(v+v); if ( x == x ) // silence warning return; } diff --git a/test/msvc2012/endian_test/endian_test.vcxproj b/test/msvc2012/endian_test/endian_test.vcxproj index 359903c..740a2e8 100644 --- a/test/msvc2012/endian_test/endian_test.vcxproj +++ b/test/msvc2012/endian_test/endian_test.vcxproj @@ -61,6 +61,7 @@ EditAndContinue + Level3 true