aboutsummaryrefslogtreecommitdiff
path: root/clang/test/CodeGenCXX/module-intializer-pmf.cpp
blob: 3a2d1635fab8304f429327727fa7e350d4f95ccf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41

// RUN: %clang_cc1 -triple %itanium_abi_triple -std=c++20 %s \
// RUN:    -emit-module-interface -o %t.HasPMF.pcm
// RUN: %clang_cc1 -triple %itanium_abi_triple -std=c++20 %t.HasPMF.pcm \
// RUN:  -emit-llvm -o - | FileCheck %s

module;

struct Glob {
  Glob(){};
};

Glob G;

export module HasPMF;

export struct InMod {
  InMod(){};
};

export InMod IM;

module :private;

struct InPMF {
  InPMF(){};
};

InPMF P;

// CHECK: define internal void @__cxx_global_var_init
// CHECK: call {{.*}} @_ZN4GlobC1Ev
// CHECK: define internal void @__cxx_global_var_init
// CHECK: call {{.*}} @_ZNW6HasPMF5InPMFC1Ev
// CHECK: define internal void @__cxx_global_var_init
// CHECK: call {{.*}} @_ZNW6HasPMF5InModC1Ev
// CHECK: define void @_ZGIW6HasPMF
// CHECK: store i8 1, ptr @_ZGIW6HasPMF__in_chrg
// CHECK: call void @__cxx_global_var_init
// CHECK: call void @__cxx_global_var_init
// CHECK: call void @__cxx_global_var_init