blob: 02495cf1970185395332bc8eaf7ee9a98bf3a7e1 [file] [log] [blame]
int main ();
typedef int (*fptr) ();
void foo (fptr);
fptr bar ()
{
foo (main); // { dg-error "8:ISO C\\+\\+ forbids taking address of function" }
return main; // { dg-error "10:ISO C\\+\\+ forbids taking address of function" }
}