Skip to content

Commit

Permalink
Fix GCC explicit specialization in non namespace scope error
Browse files Browse the repository at this point in the history
  • Loading branch information
arekmula committed Feb 23, 2024
1 parent f077e04 commit 230fa8e
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions support-lib/cpp/Future.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -383,16 +383,17 @@ class Future {
this->_promise.setValue(std::forward<V>(value));
}
};
template <>
struct PromiseType<void>: PromiseTypeBase {
void return_void() {
this->_promise.setValue();
}
};
using promise_type = PromiseType<T>;
#endif
};

template<> template<> struct Future<void>::PromiseType<void>:PromiseTypeBase {
void return_void() {
this->_promise.setValue();
}
}

#endif

template <typename T>
Future<T> detail::PromiseBase<T>::getFuture() {
return Future<T>(_sharedStateReadOnly);
Expand Down

0 comments on commit 230fa8e

Please sign in to comment.