1 // { dg-additional-options "-fmodules-ts" }
2 
3 export module frob; // { dg-error "failed to write" }
4 // { dg-module-cmi !frob }
5 
6 namespace {
7 // We shouldn't be complaining about members of internal linkage
8 // entities
9 class X  // { dg-bogus "internal linkage" "" { xfail *-*-* } }
10 { // { dg-bogus "internal linkage" "" { xfail *-*-* } }
11 };
12 
13 }
14 
frob()15 static int frob ()
16 {
17   return 1;
18 }
19 
20 export int f (int = frob ()); // { dg-error "references internal linkage" }
21 int goof (X &); // { dg-error "references internal linkage" }
22