150
|
1 // RUN: %clang_cc1 -std=c++17 -fsyntax-only -fmodules %s
|
|
2
|
|
3 #pragma clang module build a
|
|
4 module a {}
|
|
5 #pragma clang module contents
|
|
6 #pragma clang module begin a
|
|
7
|
|
8 template <class c, c e> struct ak { static constexpr c value = e; };
|
|
9 ak<bool, true> instantiate_class_definition;
|
|
10
|
|
11 #pragma clang module end /* a */
|
|
12 #pragma clang module endbuild
|
|
13
|
|
14
|
|
15 #pragma clang module build o
|
|
16 module o {}
|
|
17 #pragma clang module contents
|
|
18 #pragma clang module begin o
|
|
19 #pragma clang module import a
|
|
20
|
|
21 inline int instantiate_var_definition() { return ak<bool, true>::value; }
|
|
22
|
|
23 #pragma clang module end
|
|
24 #pragma clang module endbuild
|
|
25
|
|
26
|
|
27 #pragma clang module import o
|
|
28 #pragma clang module import a
|
|
29
|
|
30 int main() { return ak<bool, true>::value; }
|