| 448 | } |
| 449 | |
| 450 | bool Status::Equals(const Status& s) const { |
| 451 | if (state_ == s.state_) { |
| 452 | return true; |
| 453 | } |
| 454 | |
| 455 | if (ok() || s.ok()) { |
| 456 | return false; |
| 457 | } |
| 458 | |
| 459 | if (detail() != s.detail()) { |
| 460 | if ((detail() && !s.detail()) || (!detail() && s.detail())) { |
| 461 | return false; |
| 462 | } |
| 463 | return *detail() == *s.detail(); |
| 464 | } |
| 465 | |
| 466 | return code() == s.code() && message() == s.message(); |
| 467 | } |
| 468 | |
| 469 | /// \cond FALSE |
| 470 | // (note: emits warnings on Doxygen < 1.8.15, |