summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaCXX/new-delete.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2012-03-12 07:56:15 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2012-03-12 07:56:15 +0000
commitc5b05520550a4becec926564bef032e60023cde2 (patch)
tree56702ee487460ed91285be86f6a23cc74d863edc /clang/test/SemaCXX/new-delete.cpp
parent274d6f17771a2f75d6640de927ba997cc6caf38c (diff)
downloadbcm5719-llvm-c5b05520550a4becec926564bef032e60023cde2.tar.gz
bcm5719-llvm-c5b05520550a4becec926564bef032e60023cde2.zip
Fix parsing of type-specifier-seq's. Types are syntactically allowed to be
defined here, but not semantically, so new struct S {}; is always ill-formed, even if there is a struct S in scope. We also had a couple of bugs in ParseOptionalTypeSpecifier caused by it being under-loved (due to it only being used in a few places) so merge it into ParseDeclarationSpecifiers with a new DeclSpecContext. To avoid regressing, this required improving ParseDeclarationSpecifiers' diagnostics in some cases. This also required teaching ParseSpecifierQualifierList about constexpr... which incidentally fixes an issue where we'd allow the constexpr specifier in other bad places. llvm-svn: 152549
Diffstat (limited to 'clang/test/SemaCXX/new-delete.cpp')
-rw-r--r--clang/test/SemaCXX/new-delete.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/test/SemaCXX/new-delete.cpp b/clang/test/SemaCXX/new-delete.cpp
index 579ec33a43e..88d85ca792e 100644
--- a/clang/test/SemaCXX/new-delete.cpp
+++ b/clang/test/SemaCXX/new-delete.cpp
@@ -387,7 +387,7 @@ namespace PairedDelete {
namespace PR7702 {
void test1() {
- new DoesNotExist; // expected-error {{expected a type}}
+ new DoesNotExist; // expected-error {{unknown type name 'DoesNotExist'}}
}
}
OpenPOWER on IntegriCloud