1 // Contributed by Dodji Seketeli <dodji@redhat.com> 2 // Origin: PR c++/41020 3 4 // { dg-options "" } 5 // { dg-do compile } 6 7 class frok 8 { 9 int this_errno; 10 friend int fork (void); 11 }; 12 13 void foo()14 foo () 15 { 16 fork (); // { dg-error "was not declared in this scope" } 17 } 18