diff --git a/developer-handbook.md b/developer-handbook.md index 03ba413d..3e788b66 100644 --- a/developer-handbook.md +++ b/developer-handbook.md @@ -259,12 +259,18 @@ ox::Result f() { } ox::Result f2() { - oxRequire(i, f()); // creates i and assigns it the value returned by f, returns if there was an error + oxRequire(i, f()); // const auto [out, oxConcat(oxRequire_err_, __LINE__)] = x; oxReturnError(oxConcat(oxRequire_err_, __LINE__)) return i + 4; } ``` ```oxRequire``` is not quite as versatile, but it should still cleanup a lot of otherwise less ideal code. +```oxRequire``` also has variants for throwing the error and for making to value non-const: + +* ```oxRequireM``` - oxRequire Mutable +* ```oxRequireT``` - oxRequire Throw +* ```oxRequireMT``` - oxRequire Mutable Throw + ### Logging Ox provides for logging and debug prints via the ```oxTrace```, ```oxDebug```, and ```oxError``` macros.