// RUN: %clang_cc1 -triple x86_64 -std=c++26 -ast-dump -ast-dump-filter=Test %s \ // RUN: | FileCheck --match-full-lines %s // Test with serialization: // RUN: %clang_cc1 -triple x86_64 -std=c++26 -emit-pch -o %t %s // RUN: %clang_cc1 -triple x86_64 -x c++ -std=c++26 -include-pch %t -ast-dump-all -ast-dump-filter=Test /dev/null \ // RUN: | sed -e "s/ //" -e "s/ imported//" \ // RUN: | FileCheck --match-full-lines %s namespace TestClassRedecl { template struct A {}; template struct A; template struct A; // CHECK-LABEL: Dumping TestClassRedecl: // CHECK: |-ClassTemplateDecl {{.+}} void f() {} template void f(); template void f(); // CHECK-LABEL: Dumping TestFunctionRedecl: // CHECK: |-FunctionTemplateDecl 0x[[TestFunctionRedecl_T1:[^ ]+]] T a = 0; template extern T a; template int a; // CHECK-LABEL: Dumping TestVariableRedecl: // CHECK: |-VarTemplateDecl 0x[[TestVariableRedecl_T1:[^ ]+]] struct A { template struct B; }; template struct A; template template struct A::B {}; template struct A::B; // CHECK-LABEL: Dumping TestNestedClassRedecl: // CHECK: |-ClassTemplateDecl 0x[[TestNestedClassRedecl_A_T1:[^ ]+]] line:[[@LINE-8]]:{{.+}} struct A definition // CHECK: | | `-ClassTemplateDecl 0x[[TestNestedClassRedecl_B_T1:[^ ]+]]