; These tests are based on clang/test/CodeGenCXX/mangle-ms-template-callback.cpp ; RUN: llvm-undname < %s | FileCheck %s ; CHECK-NOT: Invalid mangled name ?callback_void@@3V?$C@$$A6AXXZ@@A ; CHECK: class C callback_void ?callback_void_volatile@@3V?$C@$$A6AXXZ@@C ; CHECK: class C volatile callback_void_volatile ?callback_int@@3V?$C@$$A6AHXZ@@A ; CHECK: C callback_int ?callback_Type@@3V?$C@$$A6A?AVType@@XZ@@A ; CHECK: C callback_Type ?callback_void_int@@3V?$C@$$A6AXH@Z@@A ; CHECK: C callback_void_int ?callback_int_int@@3V?$C@$$A6AHH@Z@@A ; CHECK: C callback_int_int ?callback_void_Type@@3V?$C@$$A6AXVType@@@Z@@A ; CHECK: C callback_void_Type ?foo@@YAXV?$C@$$A6AXXZ@@@Z ; CHECK: void __cdecl foo(class C) ?function@@YAXV?$C@$$A6AXXZ@@@Z ; CHECK: void __cdecl function(class C) ?function_pointer@@YAXV?$C@P6AXXZ@@@Z ; CHECK: void __cdecl function_pointer(class C) ?member_pointer@@YAXV?$C@P8Z@@AEXXZ@@@Z ; CHECK: void __cdecl member_pointer(class C) ??$bar@P6AHH@Z@@YAXP6AHH@Z@Z ; CHECK: void __cdecl bar(int (__cdecl *)(int)) ??$WrapFnPtr@$1?VoidFn@@YAXXZ@@YAXXZ ; CHECK: void __cdecl WrapFnPtr<&void __cdecl VoidFn(void)>(void) ??$WrapFnRef@$1?VoidFn@@YAXXZ@@YAXXZ ; CHECK: void __cdecl WrapFnRef<&void __cdecl VoidFn(void)>(void) ??$WrapFnPtr@$1?VoidStaticMethod@Thing@@SAXXZ@@YAXXZ ; CHECK: void __cdecl WrapFnPtr<&public: static void __cdecl Thing::VoidStaticMethod(void)>(void) ??$WrapFnRef@$1?VoidStaticMethod@Thing@@SAXXZ@@YAXXZ ; CHECK: void __cdecl WrapFnRef<&public: static void __cdecl Thing::VoidStaticMethod(void)>(void)