| 1 |
// Address: https://github.com/llvm/llvm-project/issues/60486 |
| 2 |
// |
| 3 |
// RUN: rm -rf %t |
| 4 |
// RUN: mkdir -p %t |
| 5 |
// RUN: split-file %s %t |
| 6 |
// |
| 7 |
// RUN: %clang_cc1 -std=c++20 %t/a.cppm -emit-module-interface -o %t/a.pcm |
| 8 |
// RUN: %clang_cc1 -std=c++20 -fmodule-file=a=%t/a.pcm %t/b.cppm -fsyntax-only -verify |
| 9 |
|
| 10 |
// RUN: %clang_cc1 -std=c++20 %t/a.cppm -emit-reduced-module-interface -o %t/a.pcm |
| 11 |
// RUN: %clang_cc1 -std=c++20 -fmodule-file=a=%t/a.pcm %t/b.cppm -fsyntax-only -verify |
| 12 |
|
| 13 |
//--- foo.h |
| 14 |
template<typename = void> |
| 15 |
struct s { |
| 16 |
}; |
| 17 |
|
| 18 |
template<typename> |
| 19 |
concept c = requires { s{}; }; |
| 20 |
|
| 21 |
//--- a.cppm |
| 22 |
module; |
| 23 |
#include "foo.h" |
| 24 |
export module a; |
| 25 |
|
| 26 |
//--- b.cppm |
| 27 |
// expected-no-diagnostics |
| 28 |
module; |
| 29 |
#include "foo.h" |
| 30 |
export module b; |
| 31 |
import a; |