[libc++] [test] Fix nodiscard_extensions.pass.cpp in _LIBCPP_DEBUG mode.
authorArthur O'Dwyer <arthur.j.odwyer@gmail.com>
Thu, 22 Apr 2021 16:15:09 +0000 (12:15 -0400)
committerArthur O'Dwyer <arthur.j.odwyer@gmail.com>
Thu, 22 Apr 2021 16:17:32 +0000 (12:17 -0400)
commit5dfbcc5ae953b786f493ce5e9d78a4b5c5e55229
tree4d5c6c757cc1f147cc9a7139808c922dc5ef6bd2
parent123ae425669e3e06f173958cc686ef6f81e498a8
[libc++] [test] Fix nodiscard_extensions.pass.cpp in _LIBCPP_DEBUG mode.

`std::clamp(2, 1, 3, std::greater<int>())` has UB because (1 > 3) is false.
Swap the operands to fix the _LIBCPP_ASSERT failure in this test.
libcxx/test/libcxx/diagnostics/nodiscard_extensions.pass.cpp