What is your rule for which functions that operate on a class should be member functions vs. nonmember functions? For example, I have a class which represents a maze using a mat
When to make it a member function:
When to make it a standalone function
Herb Sutter says "we want to make them nonmember nonfriends if reasonably possible", and he's smarter than I am.
http://www.gotw.ca/gotw/084.htm