diff options
Diffstat (limited to 'clang/test/SemaCXX/struct-class-redecl.cpp')
-rw-r--r-- | clang/test/SemaCXX/struct-class-redecl.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/struct-class-redecl.cpp b/clang/test/SemaCXX/struct-class-redecl.cpp new file mode 100644 index 00000000000..d6ac3661a39 --- /dev/null +++ b/clang/test/SemaCXX/struct-class-redecl.cpp @@ -0,0 +1,8 @@ +// RUN: clang-cc -fsyntax-only -verify %s +class X; // expected-note{{here}} +typedef struct X * X_t; + +template<typename T> class Y; +template<class U> struct Y { }; + +union X { int x; float y; }; // expected-error{{use of 'X' with tag type that does not match previous declaration}} |