Skip to content

Commit

Permalink
init_from: use static_cast instead of C style cast (silence warnings)
Browse files Browse the repository at this point in the history
  • Loading branch information
felixguendling committed Sep 12, 2024
1 parent 2a783d9 commit 96ee2b5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/utl/init_from.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ struct is_complete_helper {
template <typename U>
static auto test(U*) -> std::integral_constant<bool, sizeof(U) == sizeof(U)>;
static auto test(...) -> std::false_type;
using type = decltype(test((T*)0));
using type = decltype(test(static_cast<T*>(nullptr)));
};

template <typename T>
Expand Down

0 comments on commit 96ee2b5

Please sign in to comment.