struct S { void foo(int); private: void foo(float); }; int main() { S s; s.foo(6.0f); }
Standard input is empty
prog.cpp: In function ‘int main()’: prog.cpp:5: error: ‘void S::foo(float)’ is private prog.cpp:11: error: within this context
Standard output is empty