[libcxx-commits] [libcxx] 11fb68a - [libc++] Unbreak test suite (CWG1423)
David Zarzycki via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Feb 11 12:00:44 PST 2020
Author: David Zarzycki
Date: 2020-02-11T15:00:33-05:00
New Revision: 11fb68abab9594fd9e9b07a5facf5f5dbf4a4050
URL: https://github.com/llvm/llvm-project/commit/11fb68abab9594fd9e9b07a5facf5f5dbf4a4050
DIFF: https://github.com/llvm/llvm-project/commit/11fb68abab9594fd9e9b07a5facf5f5dbf4a4050.diff
LOG: [libc++] Unbreak test suite (CWG1423)
clang 9ce6dc9872be4081fb98f6161c28581e1cbbe7dc drops support for
implicit conversion of nullptr_t to bool. From that commit:
The C++ rules briefly allowed this, but the rule changed nearly 10
years ago and we never updated our implementation to match. However,
we've warned on this by default for a long time, and no other compiler
accepts (even as an extension).
Added:
Modified:
libcxx/test/std/language.support/support.types/nullptr_t.pass.cpp
Removed:
################################################################################
diff --git a/libcxx/test/std/language.support/support.types/nullptr_t.pass.cpp b/libcxx/test/std/language.support/support.types/nullptr_t.pass.cpp
index 14ab3c65d024..b12e5c00638b 100644
--- a/libcxx/test/std/language.support/support.types/nullptr_t.pass.cpp
+++ b/libcxx/test/std/language.support/support.types/nullptr_t.pass.cpp
@@ -56,14 +56,6 @@ void test_comparisons()
#pragma clang diagnostic ignored "-Wnull-conversion"
#endif
void test_nullptr_conversions() {
-// GCC does not accept this due to CWG Defect #1423
-// http://www.open-std.org/jtc1/sc22/wg21/docs/cwg_defects.html#1423
-#if defined(__clang__)
- {
- bool b = nullptr;
- assert(!b);
- }
-#endif
{
bool b(nullptr);
assert(!b);
More information about the libcxx-commits
mailing list