Warn about undefined local functions.
Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=2991
Reported by Martin Stjernholm mast@roxen.com
Consider:
class A
{
local int a();
void f() {werror ("%O\n", a());}
}
class B
{
inherit A;
int a() {return 17;}
}
int main()
{
B()->f();
}
The local modifier here doesn't have any effect; in 7.3 the call to a in f will be dynamically bound and the program prints "17" (in 7.2 it will fail with an obscure backtrace). I think a warning or perhaps even an error is in order in this case, instead of silently ignoring the local modifier. The same applies if local::a is used in the code somewhere in A.