1 // Testing that adding a new line in a module interface unit won't cause the BMI
2 // of consuming module unit changes.
5 // RUN: split-file %s %t
7 // RUN: %clang_cc1 -std=c++20 %t/A.cppm -emit-reduced-module-interface -o %t/A.pcm
8 // RUN: %clang_cc1 -std=c++20 %t/A.v1.cppm -emit-reduced-module-interface -o %t/A.v1.pcm
10 // The BMI may not be the same since the source location differs.
11 // RUN: not diff %t/A.pcm %t/A.v1.pcm &> /dev/null
13 // The BMI of B shouldn't change since all the locations remain the same.
14 // RUN: %clang_cc1 -std=c++20 %t/B.cppm -emit-reduced-module-interface -fmodule-file=A=%t/A.pcm \
16 // RUN: %clang_cc1 -std=c++20 %t/B.cppm -emit-reduced-module-interface -fmodule-file=A=%t/A.v1.pcm \
17 // RUN: -o %t/B.v1.pcm
18 // RUN: diff %t/B.v1.pcm %t/B.pcm &> /dev/null
20 // The BMI of C may change since the locations for instantiations changes.
21 // RUN: %clang_cc1 -std=c++20 %t/C.cppm -emit-reduced-module-interface -fmodule-file=A=%t/A.pcm \
23 // RUN: %clang_cc1 -std=c++20 %t/C.cppm -emit-reduced-module-interface -fmodule-file=A=%t/A.v1.pcm \
24 // RUN: -o %t/C.v1.pcm
25 // RUN: not diff %t/C.v1.pcm %t/C.pcm &> /dev/null
29 export template <class T>
42 export template <class T>
63 export inline void testD() {