PR c++/86728 - C variadic generic lambda.
[official-gcc.git] / gcc / testsuite / g++.dg / tc1 / dr101.C
blobe36add7b71568e66f486b70ed980d57cf384c83f
1 // { dg-do compile }
2 // Origin: Giovanni Bajo <giovannibajo at gcc dot gnu dot org>
3 // DR101: Redeclaration of extern "C" names via using-declarations 
5 namespace Test1 {
7   typedef unsigned int X;
8   extern "C" void f1();
9   namespace N {
10     typedef unsigned int X;
11     extern "C" void f1();
12   }
13   using N::f1; // { dg-bogus "" "redeclaration through 'using' should not be ambiguous" }
14   using N::X;  // { dg-bogus "" "redeclaration through 'using' should not be ambiguous" }
18 namespace Test2 {
20   typedef unsigned int X;   // { dg-bogus "X" }
21   extern "C" int f2();
22   namespace N {
23     typedef unsigned int X; // { dg-bogus "X" }
24     extern "C" int f2();
25   }
26   using namespace N;
27   int i = f2(); // { dg-bogus "" "redeclaration through 'using' should not be ambiguous" }
28   X x;          // { dg-bogus "" "redeclaration through 'using' should not be ambiguous" }