What can a const member function change? [duplicate]
What can a ‘const’ method change? Without explicitly casting away constness, a const member function can change: mutable data members, and any data the class has non-const access to, irrespective of whether that data’s accessible: via member variables that are pointers or references, via pointers or references passed as function arguments, via pointers or references … Read more