C++:Why a static member function and non-static member function can't be overloaded?

后端 未结 0 2015
忘掉有多难
忘掉有多难 2021-01-29 15:24

consider this example:

class Test { 
   static void fun(int i) {} 
   void fun(int i) {}    
}; 
  
int main() 
{ 
   Test t;
   t.fun(10); //should call non-stat         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题