FastLED 3.10.8
Loading...
Searching...
No Matches

◆ error_message()

template<typename T>
fl::string fl::task::PromiseResult< T >::error_message ( ) const
inline

Get the error message as a convenience.

Returns
Error message string, or empty string if successful
Note
Safe to call on success results (returns empty string)

Definition at line 115 of file promise_result.h.

115 {
116 return ok() ? fl::string() : error().message;
117 }
const Error & error() const FL_NO_EXCEPT
Get the error value.
bool ok() const FL_NO_EXCEPT
Check if the result is successful.
Result type for promise operations.

References error(), fl::FL_NO_EXCEPT, fl::task::Error::message, and ok().

+ Here is the call graph for this function: