diff options
Diffstat (limited to 'clang/test')
-rw-r--r-- | clang/test/Parser/cxx-using-directive.cpp | 5 | ||||
-rw-r--r-- | clang/test/Parser/recovery.c | 5 | ||||
-rw-r--r-- | clang/test/SemaTemplate/right-angle-brackets-98.cpp | 3 | ||||
-rw-r--r-- | clang/test/SemaTemplate/temp_arg_nontype.cpp | 2 |
4 files changed, 10 insertions, 5 deletions
diff --git a/clang/test/Parser/cxx-using-directive.cpp b/clang/test/Parser/cxx-using-directive.cpp index 2ee014e54f4..b89436046be 100644 --- a/clang/test/Parser/cxx-using-directive.cpp +++ b/clang/test/Parser/cxx-using-directive.cpp @@ -28,8 +28,9 @@ namespace D { using namespace ! ; // expected-error{{expected namespace name}} using namespace A ; // expected-error{{expected namespace name}} -using namespace ::A // expected-error{{expected namespace name}} - B ; // expected-error{{expected ';' after namespace name}} +using namespace ::A // expected-error{{expected namespace name}} \ + // expected-error{{expected ';' after namespace name}} + B ; void test_nslookup() { int B; diff --git a/clang/test/Parser/recovery.c b/clang/test/Parser/recovery.c index b6ba9e6294f..5065b9446a1 100644 --- a/clang/test/Parser/recovery.c +++ b/clang/test/Parser/recovery.c @@ -68,3 +68,8 @@ int test6248081() { struct forward; // expected-note{{forward declaration of 'struct forward'}} void x(struct forward* x) {switch(x->a) {}} // expected-error {{incomplete definition of type}} +// PR3410 +void foo() { + int X; + X = 4 // expected-error{{expected ';' after expression}} +} diff --git a/clang/test/SemaTemplate/right-angle-brackets-98.cpp b/clang/test/SemaTemplate/right-angle-brackets-98.cpp index 709e8b05e5a..1994e3d965c 100644 --- a/clang/test/SemaTemplate/right-angle-brackets-98.cpp +++ b/clang/test/SemaTemplate/right-angle-brackets-98.cpp @@ -9,5 +9,4 @@ X<X<X<X<int>> // expected-error{{a space is required between consecutive right a >> *x3; // expected-error{{a space is required between consecutive right angle brackets (use '> >')}} Y<(1 >> 2)> *y1; -Y<1 >> 2> *y2; -// FIXME: when we get a -Wc++0x mode, warn about the use above +Y<1 >> 2> *y2; // expected-warning{{use of right-shift operator ('>>') in template argument will require parentheses in C++0x}} diff --git a/clang/test/SemaTemplate/temp_arg_nontype.cpp b/clang/test/SemaTemplate/temp_arg_nontype.cpp index d67cc4e4097..55815fce1fa 100644 --- a/clang/test/SemaTemplate/temp_arg_nontype.cpp +++ b/clang/test/SemaTemplate/temp_arg_nontype.cpp @@ -7,7 +7,7 @@ A<int()> *a1; // expected-error{{template argument for non-type template paramet A<int> *a2; // expected-error{{template argument for non-type template parameter must be an expression}} -A<1 >> 2> *a3; +A<1 >> 2> *a3; // expected-warning{{use of right-shift operator ('>>') in template argument will require parentheses in C++0x}} // C++ [temp.arg.nontype]p5: A<A> *a4; // expected-error{{must have an integral or enumeration type}} \ |