The static C ++

On the static member function pointers from this:
 1 , when calling static member functions and static data members, not related to the object, but related to the class
 2 , the use of static member functions, and will not pass this pointer is an invisible, not You know the call data member is a member which data objects. So in a static member function can not call non-static data members
 3 , you can call the static data members in a static member function

 

 

Guess you like

Origin www.cnblogs.com/xjyxp/p/11240728.html