Skip to content

Commit

Permalink
Use constexpr instead of static const
Browse files Browse the repository at this point in the history
  • Loading branch information
guillaumekln committed Jul 27, 2021
1 parent c800b21 commit 356af8f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/ctranslate2/translator_pool.h
Original file line number Diff line number Diff line change
Expand Up @@ -607,7 +607,7 @@ namespace ctranslate2 {
std::queue<std::future<Result>> results;

auto pop_results = [&results, &output, &target_writer](bool blocking) {
static const auto zero_sec = std::chrono::seconds(0);
constexpr std::chrono::seconds zero_sec(0);
while (!results.empty()
&& (blocking
|| results.front().wait_for(zero_sec) == std::future_status::ready)) {
Expand Down

0 comments on commit 356af8f

Please sign in to comment.