Skip to content

Commit f3884ce

Browse files
committed
Clang does not have -Wuseless-cast
1 parent d725c68 commit f3884ce

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

include/boost/int128/detail/mini_from_chars.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,14 +203,14 @@ BOOST_INT128_HOST_DEVICE constexpr int from_chars_integer_impl(const char* first
203203
// since they are in the range of acceptable distances
204204

205205
// This cast is useless on 32-bit platforms
206-
#ifdef __GNUC__
206+
#if defined(__GNUC__) && !defined(__clang__)
207207
# pragma GCC diagnostic push
208208
# pragma GCC diagnostic ignored "-Wuseless-cast"
209209
#endif
210210

211211
return static_cast<int>(first - next);
212212

213-
#ifdef __GNUC__
213+
#if defined(__GNUC__) && !defined(__clang__)
214214
# pragma GCC diagnostic pop
215215
#endif
216216
}

0 commit comments

Comments
 (0)