| 68 | |
| 69 | template <typename T> |
| 70 | T unwrap_expected(const tl::expected<T, Status> &exp) { |
| 71 | if (exp.has_value()) { |
| 72 | return exp.value(); |
| 73 | } |
| 74 | throw_if_error(exp.error()); |
| 75 | return T{}; |
| 76 | } |
| 77 | |
| 78 | template <typename T> |
| 79 | T unwrap_expected(tl::expected<T, Status> &&exp) { |
no test coverage detected