mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 08:37:45 +00:00
AK: Allow to "get a result" from Result<void>
This is to make Result<void> work inside TRY
This commit is contained in:
parent
b1982267b2
commit
6f74c1bb11
1 changed files with 4 additions and 0 deletions
|
@ -93,6 +93,10 @@ public:
|
||||||
Result(const Result& other) = default;
|
Result(const Result& other) = default;
|
||||||
~Result() = default;
|
~Result() = default;
|
||||||
|
|
||||||
|
// For compatibility with TRY().
|
||||||
|
void value() {};
|
||||||
|
void release_value() {};
|
||||||
|
|
||||||
ErrorType& error()
|
ErrorType& error()
|
||||||
{
|
{
|
||||||
return m_error.value();
|
return m_error.value();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue