summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaTemplate/exception-spec-crash.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2018-09-28 01:16:43 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2018-09-28 01:16:43 +0000
commit9b2c5e7c44fd28c31f4a0b088d0bf71da4fddfa5 (patch)
tree2d42358db17e2e96f5d821a77572ecc8ae2cb1df /clang/test/SemaTemplate/exception-spec-crash.cpp
parentfdf4c76ca0a73b0c753329eb59804617a6003256 (diff)
downloadbcm5719-llvm-9b2c5e7c44fd28c31f4a0b088d0bf71da4fddfa5.tar.gz
bcm5719-llvm-9b2c5e7c44fd28c31f4a0b088d0bf71da4fddfa5.zip
[cxx2a] P0641R2: (Some) type mismatches on defaulted functions only
render the function deleted instead of rendering the program ill-formed. This change also adds an enabled-by-default warning for the case where an explicitly-defaulted special member function of a non-template class is implicitly deleted by the type checking rules. (This fires either due to this language change or due to pre-C++20 reasons for the member being implicitly deleted). I've tested this on a large codebase and found only bugs (where the program means something that's clearly different from what the programmer intended), so this is enabled by default, but we should revisit this if there are problems with this being enabled by default. llvm-svn: 343285
Diffstat (limited to 'clang/test/SemaTemplate/exception-spec-crash.cpp')
-rw-r--r--clang/test/SemaTemplate/exception-spec-crash.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/test/SemaTemplate/exception-spec-crash.cpp b/clang/test/SemaTemplate/exception-spec-crash.cpp
index 4d9355974c9..ebbb30a2c23 100644
--- a/clang/test/SemaTemplate/exception-spec-crash.cpp
+++ b/clang/test/SemaTemplate/exception-spec-crash.cpp
@@ -1,5 +1,5 @@
-// RUN: %clang_cc1 -std=c++11 -fsyntax-only -verify %s
-// RUN: %clang_cc1 -std=c++11 -fcxx-exceptions -DCXX_EXCEPTIONS -fsyntax-only -verify %s
+// RUN: %clang_cc1 -std=c++11 -fsyntax-only -verify %s -Wno-defaulted-function-deleted
+// RUN: %clang_cc1 -std=c++11 -fcxx-exceptions -DCXX_EXCEPTIONS -fsyntax-only -verify %s -Wno-defaulted-function-deleted
template <class _Tp> struct is_nothrow_move_constructible {
static const bool value = false;
OpenPOWER on IntegriCloud