Replace safe_bool with explicit conversions