Skip to content

Commit

Permalink
Make conv_result not constexpr
Browse files Browse the repository at this point in the history
  • Loading branch information
JaciBrunning committed Jan 21, 2024
1 parent de0581e commit 86ef3d9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/native/include/grpl/utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ namespace grpl {
static constexpr int GRAPPLE_ERROR_GENERIC = 0xFF;

template<typename T>
constexpr std::optional<T> conv_opt(libgrapplefrc::ffi::COptional<T> opt) {
inline std::optional<T> conv_opt(libgrapplefrc::ffi::COptional<T> opt) {
if (opt.tag == libgrapplefrc::ffi::COptional<T>::Tag::Some) {
return opt.some._0;
} else {
Expand All @@ -34,7 +34,7 @@ namespace grpl {
}

template<typename T>
constexpr grpl::expected<T, GrappleError> conv_result(libgrapplefrc::ffi::CGrappleResult<T> opt) {
inline grpl::expected<T, GrappleError> conv_result(libgrapplefrc::ffi::CGrappleResult<T> opt) {
if (opt.tag == libgrapplefrc::ffi::CGrappleResult<T>::Tag::Ok) {
return opt.ok._0;
} else {
Expand Down

0 comments on commit 86ef3d9

Please sign in to comment.