diff options
| author | 2021-05-21 01:05:04 -0400 | |
|---|---|---|
| committer | 2021-06-02 00:39:27 -0400 | |
| commit | 12c1766997f2596b4b1b1a6a411e4f6d56605ee7 (patch) | |
| tree | e718a0f18be8aaf664ebdcd197af513e5a118b72 /src/core/hle/result.h | |
| parent | Merge pull request #6395 from lioncash/result-move (diff) | |
| download | yuzu-12c1766997f2596b4b1b1a6a411e4f6d56605ee7.tar.gz yuzu-12c1766997f2596b4b1b1a6a411e4f6d56605ee7.tar.xz yuzu-12c1766997f2596b4b1b1a6a411e4f6d56605ee7.zip | |
general: Replace RESULT_SUCCESS with ResultSuccess
Transition to PascalCase for result names.
Diffstat (limited to 'src/core/hle/result.h')
| -rw-r--r-- | src/core/hle/result.h | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/core/hle/result.h b/src/core/hle/result.h index df3283fe3..9ec124cf4 100644 --- a/src/core/hle/result.h +++ b/src/core/hle/result.h | |||
| @@ -144,7 +144,7 @@ constexpr bool operator!=(const ResultCode& a, const ResultCode& b) { | |||
| 144 | // Convenience functions for creating some common kinds of errors: | 144 | // Convenience functions for creating some common kinds of errors: |
| 145 | 145 | ||
| 146 | /// The default success `ResultCode`. | 146 | /// The default success `ResultCode`. |
| 147 | constexpr ResultCode RESULT_SUCCESS(0); | 147 | constexpr ResultCode ResultSuccess(0); |
| 148 | 148 | ||
| 149 | /** | 149 | /** |
| 150 | * Placeholder result code used for unknown error codes. | 150 | * Placeholder result code used for unknown error codes. |
| @@ -321,7 +321,7 @@ private: | |||
| 321 | */ | 321 | */ |
| 322 | template <typename T, typename... Args> | 322 | template <typename T, typename... Args> |
| 323 | ResultVal<T> MakeResult(Args&&... args) { | 323 | ResultVal<T> MakeResult(Args&&... args) { |
| 324 | return ResultVal<T>::WithCode(RESULT_SUCCESS, std::forward<Args>(args)...); | 324 | return ResultVal<T>::WithCode(ResultSuccess, std::forward<Args>(args)...); |
| 325 | } | 325 | } |
| 326 | 326 | ||
| 327 | /** | 327 | /** |
| @@ -330,8 +330,7 @@ ResultVal<T> MakeResult(Args&&... args) { | |||
| 330 | */ | 330 | */ |
| 331 | template <typename Arg> | 331 | template <typename Arg> |
| 332 | ResultVal<std::remove_reference_t<Arg>> MakeResult(Arg&& arg) { | 332 | ResultVal<std::remove_reference_t<Arg>> MakeResult(Arg&& arg) { |
| 333 | return ResultVal<std::remove_reference_t<Arg>>::WithCode(RESULT_SUCCESS, | 333 | return ResultVal<std::remove_reference_t<Arg>>::WithCode(ResultSuccess, std::forward<Arg>(arg)); |
| 334 | std::forward<Arg>(arg)); | ||
| 335 | } | 334 | } |
| 336 | 335 | ||
| 337 | /** | 336 | /** |
| @@ -362,7 +361,7 @@ ResultVal<std::remove_reference_t<Arg>> MakeResult(Arg&& arg) { | |||
| 362 | #define R_SUCCEEDED(res) (res.IsSuccess()) | 361 | #define R_SUCCEEDED(res) (res.IsSuccess()) |
| 363 | 362 | ||
| 364 | /// Evaluates a boolean expression, and succeeds if that expression is true. | 363 | /// Evaluates a boolean expression, and succeeds if that expression is true. |
| 365 | #define R_SUCCEED_IF(expr) R_UNLESS(!(expr), RESULT_SUCCESS) | 364 | #define R_SUCCEED_IF(expr) R_UNLESS(!(expr), ResultSuccess) |
| 366 | 365 | ||
| 367 | /// Evaluates a boolean expression, and returns a result unless that expression is true. | 366 | /// Evaluates a boolean expression, and returns a result unless that expression is true. |
| 368 | #define R_UNLESS(expr, res) \ | 367 | #define R_UNLESS(expr, res) \ |