CWG 1394: Incomplete types as parameters of deleted functions
[llvm-project.git] / llvm / test / TableGen / warn-unused-template-arg.td
blob5f76e82fc0d9a4f84600c46d1077b424927d0175
1 // RUN: llvm-tblgen %s 2>&1 | FileCheck %s
2 // RUN: llvm-tblgen --no-warn-on-unused-template-args %s 2>&1 | FileCheck %s --check-prefix=CHECK-DISABLED
4 class UnusedClassArg<int foo> {}
6 // CHECK: warning: unused template argument: UnusedClassArg:foo
7 // CHECK-NEXT: class UnusedClassArg<int foo> {}
8 // CHECK-NEXT:                          ^
10 multiclass UnusedMultiClassArg<int foo> {
11   def bar;
14 defm : UnusedMultiClassArg<1>;
16 // CHECK: warning: unused template argument: UnusedMultiClassArg::foo
17 // CHECK-NEXT: multiclass UnusedMultiClassArg<int foo> {
18 // CHECK-NEXT:                                    ^
20 class NoWarning<int b> {
21   int a = b;
24 // CHECK-NOT: warning: unused template argument: NoWarning:b
25 // CHECK-DISABLED-NOT: warning