title: How do I override the bool operator in a C++ class?
body: <p>I'm defining a <code>ReturnValue</code> class in C++ that needs to report whether a method was successful. I want objects of the class to evaluate to <code>true</code> on success and <code>false</code> on error. Which operator do I override to control the truthiness of my class?</p>