2014-08-22 09:16:44 +08:00
|
|
|
// RUN: %clang_cc1 -fsyntax-only -std=c++11 -verify %s
|
|
|
|
|
|
|
|
template <typename T>
|
|
|
|
struct X {};
|
|
|
|
auto b = []() {
|
|
|
|
struct S {
|
2020-03-28 08:08:26 +08:00
|
|
|
static typename X<decltype(int)>::type Run(){}; // expected-error {{expected '('}}
|
2014-08-22 09:16:44 +08:00
|
|
|
};
|
|
|
|
return 5;
|
|
|
|
}();
|
|
|
|
|
|
|
|
template <typename T1, typename T2>
|
|
|
|
class PC {
|
|
|
|
};
|
|
|
|
|
|
|
|
template <typename T>
|
|
|
|
class P {
|
2020-03-28 08:08:26 +08:00
|
|
|
static typename PC<T, Invalid>::Type Foo(); // expected-error {{undeclared identifier 'Invalid'}}
|
2014-08-22 09:16:44 +08:00
|
|
|
};
|