// { dg-additional-options "-fmodules-ts -Wno-pedantic" } module; # 5 __FILE__ 1 class Pooh; class Piglet; # 8 "" 2 export module std; // might happen, you can't say it won't! // { dg-module-cmi std } namespace std { export template class allocator { // just for testing, not real! void M (T *); template U *N (T *); }; template void allocator::M (T *) {} template template U *allocator::N (T *) { return nullptr; } template void allocator::M (int *); template float *allocator::N (int *); } template void std::allocator::M (Pooh *); template Piglet *std::allocator::N (Pooh *); // { dg-final { scan-assembler {_ZNStW3std9allocatorIiE1MEPi:} } } // { dg-final { scan-assembler {_ZNStW3std9allocatorIiE1NIfEEPT_Pi:} } } // { dg-final { scan-assembler {_ZNStW3std9allocatorI4PoohE1MEPS1_:} } } // { dg-final { scan-assembler {_ZNStW3std9allocatorI4PoohE1NI6PigletEEPT_PS1_:} } }