diff --git a/lib/RetryableOperation.h b/lib/RetryableOperation.h index 8a7b4710..8bebb5b0 100644 --- a/lib/RetryableOperation.h +++ b/lib/RetryableOperation.h @@ -79,7 +79,12 @@ class RetryableOperation : public std::enable_shared_from_this runImpl(TimeDuration remainingTime) { + // Fix the "declared with greater visibility" error for GCC <= 7 +#ifdef __GNUC__ + __attribute__((visibility("hidden"))) +#endif + Future + runImpl(TimeDuration remainingTime) { std::weak_ptr> weakSelf{this->shared_from_this()}; func_().addListener([this, weakSelf, remainingTime](Result result, const T& value) { auto self = weakSelf.lock();