constexpr E error_or()

in src/iceberg/expected.h [2066:2076]


  constexpr E error_or(G&& v) && noexcept(
      std::is_nothrow_move_constructible_v<E> &&
      expected_detail::is_nothrow_convertible_v<G, E>) {
    static_assert(std::is_move_constructible_v<E>, "E must be move-constructible");
    static_assert(std::is_convertible_v<G, E>, "is_convertible_v<G, E> must be true");
    if (this->m_has_val) {
      return static_cast<E>(std::forward<G>(v));
    } else {
      return std::move(this->m_unexpect);
    }
  }