teak-llvm/libcxx/test/std/utilities/function.objects
Stephan T. Lavavej 3d26ee2921 [libcxx] [test] Fix MSVC warnings C4127 and C6326 about constants.
MSVC has compiler warnings C4127 "conditional expression is constant" (enabled
by /W4) and C6326 "Potential comparison of a constant with another constant"
(enabled by /analyze). They're potentially useful, although they're slightly
annoying to library devs who know what they're doing. In the latest version of
the compiler, C4127 is suppressed when the compiler sees simple tests like
"if (name_of_thing)", so extracting comparison expressions into named
constants is a workaround. At the same time, using std::integral_constant
avoids C6326, which doesn't look at template arguments.

test/std/containers/sequences/vector.bool/emplace.pass.cpp
Replace 1 == 1 with true, which is the same as far as the library is concerned.

Fixes D28837.

llvm-svn: 292432
2017-01-18 20:09:56 +00:00
..
arithmetic.operations [libcxx] [test] Fix MSVC warning C4244 "conversion from 'X' to 'Y', possible loss of data", part 2/7. 2016-12-08 21:38:01 +00:00
bind fix newly failing c++03 tests 2016-12-24 00:40:45 +00:00
bitwise.operations [libcxx] [test] Replace _LIBCPP_STD_VER with TEST_STD_VER. 2016-11-04 20:26:59 +00:00
comparisons Enable the -Wsign-compare warning to better support MSVC 2016-12-11 05:31:00 +00:00
func.def
func.invoke Add void_t and invoke feature test macros 2016-10-14 07:19:52 +00:00
func.memfn Replace __cplusplus comparisons and dialect __has_feature checks with TEST_STD_VER. 2016-06-14 21:31:42 +00:00
func.not_fn Fix unused parameters and variables 2016-12-23 23:37:52 +00:00
func.require Move INVOKE tests into test/libcxx sub-tree. 2016-04-29 01:52:57 +00:00
func.wrap Fix PR31489 - std::function self-swap segfaults 2016-12-29 20:03:55 +00:00
logical.operations [libcxx] [test] Replace _LIBCPP_STD_VER with TEST_STD_VER. 2016-11-04 20:26:59 +00:00
negators In C++03, a bunch of the arithmetic/logical/comparison functors (such as negate/bit_not.pass/logical_not) were defined as deriving from unary_funtion. That restriction was removed in C++11, but the tests still check for this. Change the test to look for the embedded types first_argument/second_argument/result_type. No change to the library, just more standards-compliant tests. Thanks to STL @ Microsoft for the suggestion. 2015-01-07 21:51:30 +00:00
refwrap Remove all instances of _LIBCPP_HAS_NO_RVALUE_REFERENCES from test/std/utilities 2016-10-01 10:46:01 +00:00
unord.hash [libcxx] [test] Fix MSVC warnings C4127 and C6326 about constants. 2017-01-18 20:09:56 +00:00