gcc/testsuite/g++.dg/modules/gmf-4.C
raw| 1 | // PR c++/114630 |
| 2 | // { dg-additional-options "-fmodules-ts -Wno-global-module -fdump-lang-module" } |
| 3 | // { dg-module-cmi M } |
| 4 | |
| 5 | module; |
| 6 | template <typename> struct allocator { |
| 7 | allocator() {} |
| 8 | }; |
| 9 | export module M; |
| 10 | template class allocator<wchar_t>; |
| 11 | |
| 12 | // allocator is reachable because the explicit instantiation is in purview. |
| 13 | // { dg-final { scan-lang-dump {Wrote declaration[^\n]*allocator} module } } |