| 1 | // RUN: %clang_delta --transformation=reduce-class-template-param --counter=1 %s 2>&1 | %remove_lit_checks | FileCheck %s -check-prefix=CHECK-FIRST |
| 2 | // RUN: %clang_delta --transformation=reduce-class-template-param --counter=2 %s 2>&1 | %remove_lit_checks | FileCheck %s -check-prefix=CHECK-SECOND |
| 3 | // RUN: %clang_delta --transformation=reduce-class-template-param --counter=3 %s 2>&1 | %remove_lit_checks | FileCheck %s -check-prefix=CHECK-THIRD |
| 4 | // RUN: %clang_delta --transformation=reduce-class-template-param --counter=4 %s 2>&1 | %remove_lit_checks | FileCheck %s -check-prefix=CHECK-FOURTH |
| 5 | |
| 6 | template <typename T1, typename T2 = void> |
| 7 | struct S {}; |
| 8 | struct S<int> s; |
| 9 | template <typename T1 = void, typename T2 = int > |
| 10 | struct S1 {}; |
| 11 | struct S1<> t; |
| 12 | |
| 13 | // CHECK-FIRST: template < typename T2 = void> |
| 14 | // CHECK-FIRST: struct S {}; |
| 15 | // CHECK-FIRST: struct S<> s; |
| 16 | // CHECK-FIRST: template <typename T1 = void, typename T2 = int > |
| 17 | // CHECK-FIRST: struct S1 {}; |
| 18 | // CHECK-FIRST: struct S1<> t; |
| 19 | |
| 20 | // CHECK-SECOND: template <typename T1> |
| 21 | // CHECK-SECOND: struct S {}; |
| 22 | // CHECK-SECOND: struct S<int> s; |
| 23 | // CHECK-SECOND: template <typename T1 = void, typename T2 = int > |
| 24 | // CHECK-SECOND: struct S1 {}; |
| 25 | // CHECK-SECOND: struct S1<> t; |
| 26 | |
| 27 | // CHECK-THIRD: template <typename T1, typename T2 = void> |
| 28 | // CHECK-THIRD: struct S {}; |
| 29 | // CHECK-THIRD: struct S<int> s; |
| 30 | // CHECK-THIRD: template < typename T2 = int > |
| 31 | // CHECK-THIRD: struct S1 {}; |
| 32 | // CHECK-THIRD: struct S1<> t; |
| 33 | |
| 34 | // CHECK-FOURTH: template <typename T1, typename T2 = void> |
| 35 | // CHECK-FOURTH: struct S {}; |
| 36 | // CHECK-FOURTH: struct S<int> s; |
| 37 | // CHECK-FOURTH: template <typename T1 = void > |
| 38 | // CHECK-FOURTH: struct S1 {}; |
| 39 | // CHECK-FOURTH: struct S1<> t; |
| 40 |