From d28f727742303538b655309e50e0ca00fc1d2e22 Mon Sep 17 00:00:00 2001 From: Gary Talent Date: Sat, 7 Jul 2018 14:37:31 -0500 Subject: [PATCH] [ox/std] Add oxReturnError --- deps/ox/src/ox/std/error.hpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/deps/ox/src/ox/std/error.hpp b/deps/ox/src/ox/std/error.hpp index bb7b605c..b8d15852 100644 --- a/deps/ox/src/ox/std/error.hpp +++ b/deps/ox/src/ox/std/error.hpp @@ -16,6 +16,8 @@ #define OxError(x) x #endif +#define oxReturnError(x) if (const auto err = x) return OxError(err) + namespace ox { using Error = uint64_t;