+private:
+ // For conversions to boolean, as would be used in an if conditional,
+ // implicit conversions from bool to int have a large number of
+ // undesirable side effects. The following safe_bool type enables
+ // use of relational objects in conditionals without those side effects
+ struct safe_bool_helper {
+ void nonnull() {};
+ };
+
+ typedef void (safe_bool_helper::*safe_bool)();