diff options
author | Sean Hunt <scshunt@csclub.uwaterloo.ca> | 2011-05-20 21:43:47 +0000 |
---|---|---|
committer | Sean Hunt <scshunt@csclub.uwaterloo.ca> | 2011-05-20 21:43:47 +0000 |
commit | e3406826db726960ede77dd18361eb327d30c108 (patch) | |
tree | e3cdf714ef79435e4ff863753895340547a6a9c2 /test/SemaCXX/value-initialization.cpp | |
parent | ce7cd26dd03f514cb772ac8d95ef0a1e6cbfc846 (diff) |
Add a missing case for default constructor deletion.
This case is tested by the fact that the modified test produces
significatly worse diagnostics. That's on the list.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@131759 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/SemaCXX/value-initialization.cpp')
-rw-r--r-- | test/SemaCXX/value-initialization.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/test/SemaCXX/value-initialization.cpp b/test/SemaCXX/value-initialization.cpp index 10520fb8bb..dfe0f46ea2 100644 --- a/test/SemaCXX/value-initialization.cpp +++ b/test/SemaCXX/value-initialization.cpp @@ -1,12 +1,11 @@ // RUN: %clang_cc1 -fsyntax-only -verify %s -std=c++0x -struct A { // expected-error {{implicit default constructor for 'A' must explicitly initialize the const member 'i'}} \ - // expected-warning{{struct 'A' does not declare any constructor to initialize its non-modifiable members}} - const int i; // expected-note {{declared here}} \ - // expected-note{{const member 'i' will never be initialized}} +struct A { //expected-note {{marked deleted here}} \ + // expected-warning {{does not declare any constructor to initialize}} + const int i; // expected-note{{const member 'i' will never be initialized}} virtual void f() { } }; int main () { - (void)A(); // expected-note {{first required here}} + (void)A(); // expected-error {{call to deleted constructor}} } |