2010-01-01 05:34:51 -05:00
|
|
|
// RUN: %clang_cc1 -fsyntax-only -verify %s
|
2009-06-14 05:24:02 -04:00
|
|
|
|
|
|
|
|
// There is no semantic difference between class and typename in a
|
|
|
|
|
// template-parameter. typename followed by an unqualified-id names a
|
|
|
|
|
// template type parameter.
|
|
|
|
|
template<class T> struct X;
|
|
|
|
|
template<typename T> struct X;
|
|
|
|
|
|
|
|
|
|
// typename followed by aqualified-id denotes the type in a non-type
|
|
|
|
|
// parameter-declaration.
|
2009-12-01 06:08:04 -05:00
|
|
|
template<typename T, typename T::type Value> struct Y0;
|
|
|
|
|
template<typename T, typename X<T>::type Value> struct Y1;
|
2009-06-14 05:24:02 -04:00
|
|
|
|
|
|
|
|
// A storage class shall not be specified in a template-parameter declaration.
|
|
|
|
|
template<static int Value> struct Z; // FIXME: expect an error
|
|
|
|
|
|
|
|
|
|
// FIXME: add the example from p2
|