solution:
No, the compiler will flag an error, even if they are simply declared.
For ex:
int Foo();
bool Foo();
int main()
{
}
will generate,
overload.cpp:2: error: new declaration ‘bool Foo()’
overload.cpp:1: error: ambiguates old declaration ‘int Foo()’
No comments:
Post a Comment