2016-06-30 11:02:03 +08:00
|
|
|
// RUN: %clang_cc1 %s -emit-llvm -o - -triple i686-pc-win32 | FileCheck %s
|
|
|
|
struct A {
|
|
|
|
void Foo();
|
|
|
|
void Foo(int);
|
|
|
|
};
|
|
|
|
|
|
|
|
using MpTy = void (A::*)();
|
|
|
|
|
|
|
|
void Bar(const MpTy &);
|
|
|
|
|
|
|
|
void Baz() { Bar(&A::Foo); }
|
|
|
|
|
2018-03-17 04:36:49 +08:00
|
|
|
// CHECK-LABEL: define dso_local void @"?Baz@@YAXXZ"(
|
2016-06-30 11:02:03 +08:00
|
|
|
// CHECK: %[[ref_tmp:.*]] = alloca i8*, align 4
|
2018-03-17 04:36:49 +08:00
|
|
|
// CHECK: store i8* bitcast (void (%struct.A*)* @"?Foo@A@@QAEXXZ" to i8*), i8** %[[ref_tmp]], align 4
|
2020-05-19 02:29:11 +08:00
|
|
|
// CHECK: call void @"?Bar@@YAXABQ8A@@AEXXZ@Z"(i8** nonnull align 4 dereferenceable(4) %[[ref_tmp]])
|