OSDN Git Service

Fix for PR c++/43375
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.dg / lookup / extern-c-redecl5.C
1 // Contributed by Dodji Seketeli <dodji@redhat.com>
2 // Origin: PR c++/41020
3 // { dg-do compile }
4
5
6 class frok
7 {
8   int this_errno;
9   friend int fork (void); // { dg-error "previous declaration .*?C\\+\\+. linkage" }
10 };
11
12 extern "C" int
13 fork (void) // { dg-error "conflicts with new declaration .*?C. linkage" }}
14 {
15   frok grouped;
16   return grouped.this_errno;
17 }
18