| 1 |
// RUN: rm -rf %t |
| 2 |
// RUN: mkdir -p %t |
| 3 |
// RUN: split-file %s %t |
| 4 |
// |
| 5 |
// RUN: %clang_cc1 -std=c++20 %t/A.cppm -emit-module-interface -o %t/A.pcm |
| 6 |
// RUN: %clang_cc1 -std=c++20 %t/B.cppm -fprebuilt-module-path=%t -emit-llvm -o %t/B.ll |
| 7 |
|
| 8 |
//--- A.cppm |
| 9 |
export module A; |
| 10 |
export template<typename> |
| 11 |
struct holder { |
| 12 |
}; |
| 13 |
|
| 14 |
struct a { |
| 15 |
holder<struct foo> m; |
| 16 |
}; |
| 17 |
|
| 18 |
//--- B.cppm |
| 19 |
// expected-no-diagnostics |
| 20 |
export module B; |
| 21 |
import A; |
| 22 |
|
| 23 |
struct b { |
| 24 |
holder<struct foo> m; |
| 25 |
}; |