Skip to content

Commit

Permalink
Fix warning for windows
Browse files Browse the repository at this point in the history
  • Loading branch information
MBkkt authored and Naios committed Nov 4, 2023
1 parent 9e30386 commit a354bd0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions include/function2/function2.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -1245,7 +1245,7 @@ class erasure : internal_capacity_holder<typename Config::capacity> {
template <typename T, typename Allocator = std::allocator<std::decay_t<T>>>
void assign(std::true_type /*use_bool_op*/, T&& callable,
Allocator&& allocator_ = {}) {
if (bool(callable)) {
if (!!callable) {
assign(std::false_type{}, std::forward<T>(callable),
std::forward<Allocator>(allocator_));
} else {
Expand Down Expand Up @@ -1366,7 +1366,7 @@ class erasure<false, Config,
}
template <typename T>
constexpr void assign(std::true_type /*use_bool_op*/, T&& callable) {
if (bool(callable)) {
if (!!callable) {
assign(std::false_type{}, std::forward<T>(callable));
} else {
operator=(nullptr);
Expand Down

0 comments on commit a354bd0

Please sign in to comment.