brintos

brintos / llvm-project-archived public Read only

0
0
Text · 452 B · 184160a Raw
27 lines · cpp
1// RUN: %clang_cc1 -fsyntax-only -verify %s2// expected-no-diagnostics3template<typename T, int N>4struct A;5 6template<typename T>7struct A<T*, 2> {8  A(T);9  ~A();10  11  void f(T*);12  13  operator T*();14  15  static T value;16};17 18template<class X> void A<X*, 2>::f(X*) { }19 20template<class X> X A<X*, 2>::value;21 22template<class X> A<X*, 2>::A(X) { value = 0; }23 24template<class X> A<X*, 2>::~A() { }25 26template<class X> A<X*, 2>::operator X*() { return 0; }27