Skip to content

Commit

Permalink
fn need to be in parenthesis
Browse files Browse the repository at this point in the history
Otherwise intel c++ 19.1 cause an error
"expression preceding parentheses of apparent call must have (pointer-to-) function type CATCH2"
  • Loading branch information
iskakoff authored and horenmar committed Nov 16, 2023
1 parent 733b901 commit de7ba4e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/catch2/benchmark/catch_optimizer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ namespace Catch {

template <typename Fn, typename... Args>
inline auto invoke_deoptimized(Fn&& fn, Args&&... args) -> std::enable_if_t<std::is_same<void, decltype(fn(args...))>::value> {
CATCH_FORWARD(fn) (CATCH_FORWARD(args)...);
CATCH_FORWARD((fn)) (CATCH_FORWARD(args)...);
}
} // namespace Benchmark
} // namespace Catch
Expand Down

0 comments on commit de7ba4e

Please sign in to comment.