summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaCXX/cxx0x-defaulted-functions.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test/SemaCXX/cxx0x-defaulted-functions.cpp')
-rw-r--r--clang/test/SemaCXX/cxx0x-defaulted-functions.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/cxx0x-defaulted-functions.cpp b/clang/test/SemaCXX/cxx0x-defaulted-functions.cpp
index 2aaf6197b64..16e20ff4964 100644
--- a/clang/test/SemaCXX/cxx0x-defaulted-functions.cpp
+++ b/clang/test/SemaCXX/cxx0x-defaulted-functions.cpp
@@ -196,3 +196,15 @@ namespace PR15597 {
A<int> a;
B<int> b; // expected-note {{here}}
}
+
+namespace PR27941 {
+struct ExplicitBool {
+ ExplicitBool &operator=(bool) = default; // expected-error{{only special member functions may be defaulted}}
+ int member;
+};
+
+int fn() {
+ ExplicitBool t;
+ t = true;
+}
+}
OpenPOWER on IntegriCloud