diff options
Diffstat (limited to 'src/core/hle/result.h')
-rw-r--r-- | src/core/hle/result.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/core/hle/result.h b/src/core/hle/result.h index 656e1b4a7..052f49979 100644 --- a/src/core/hle/result.h +++ b/src/core/hle/result.h @@ -108,11 +108,11 @@ union ResultCode { } constexpr bool IsSuccess() const { - return is_error.ExtractValue(raw) == 0; + return raw == 0; } constexpr bool IsError() const { - return is_error.ExtractValue(raw) == 1; + return raw != 0; } }; @@ -200,6 +200,9 @@ public: } ResultVal& operator=(const ResultVal& o) { + if (this == &o) { + return *this; + } if (!empty()) { if (!o.empty()) { object = o.object; |