2012-05-01 02:13:01 +08:00
|
|
|
// RUN: %clang_cc1 -fsyntax-only %s -verify
|
2015-11-12 03:34:47 +08:00
|
|
|
// RUN: %clang_cc1 -fsyntax-only -std=c++98 %s -verify
|
|
|
|
// RUN: %clang_cc1 -fsyntax-only -std=c++11 %s -verify
|
2012-05-01 02:13:01 +08:00
|
|
|
|
|
|
|
// <rdar://problem/11286701>
|
|
|
|
namespace std {
|
|
|
|
template<typename T, typename U> class pair;
|
|
|
|
}
|
|
|
|
|
|
|
|
@interface NSObject
|
|
|
|
@end
|
|
|
|
|
|
|
|
@interface Test : NSObject
|
|
|
|
@end
|
|
|
|
|
|
|
|
@implementation Test
|
|
|
|
|
|
|
|
struct EvilStruct {
|
2013-11-21 07:40:57 +08:00
|
|
|
} // expected-error {{expected ';' after struct}}
|
2012-05-01 02:13:01 +08:00
|
|
|
|
2013-11-21 07:40:57 +08:00
|
|
|
typedef std::pair<int, int> IntegerPair;
|
|
|
|
|
2015-11-12 03:34:47 +08:00
|
|
|
template<typename...Ts> void f(Ts); // expected-error {{unexpanded}}
|
|
|
|
#if __cplusplus <= 199711L // C++03 or earlier modes
|
|
|
|
// expected-warning@-2 {{variadic templates are a C++11 extension}}
|
|
|
|
#endif
|
2012-05-01 02:13:01 +08:00
|
|
|
@end
|