brintos

brintos / llvm-project-archived public Read only

0
0
Text · 363 B · 1b9350b Raw
22 lines · cpp
1// RUN: %clang_cc1 -fsyntax-only -Wunused -verify %s2 3struct X0 {4  ~X0();5};6 7struct X1 { };8 9template<typename T>10void f() {11  X0 x0;12  X1 x1; // expected-warning{{unused variable 'x1'}}13}14 15template<typename T, typename U>16void g() {17  T t;18  U u; // expected-warning{{unused variable 'u'}}19}20 21template void g<X0, X1>(); // expected-note{{in instantiation of}}22