AK: Allow to "get a result" from Result<void>

This is to make Result<void> work inside TRY
This commit is contained in:
Hendiadyoin1 2021-10-05 22:05:42 +02:00 committed by Brian Gianforcaro
parent b1982267b2
commit 6f74c1bb11
Notes: sideshowbarker 2024-07-18 00:34:21 +09:00

View file

@ -93,6 +93,10 @@ public:
Result(const Result& other) = default;
~Result() = default;
// For compatibility with TRY().
void value() {};
void release_value() {};
ErrorType& error()
{
return m_error.value();