martinmoene / span-lite

span lite - A C++20-like span for C++98, C++11 and later in a single-file header-only library
Boost Software License 1.0
499 stars 43 forks source link

Fix remaining cases of -Wtype-limits warning #63

Closed mjacobse closed 4 years ago

mjacobse commented 4 years ago

Following up on 1a36383 by using detail::is_positive to fix a few more cases of the warning -Wtype-limits with gcc 10. Curiously, the warning does not appear for the checks of the template parameters Count and Offset of the static variants of first, last and subspan at the moment. But does not hurt to use is_positive for those too.

martinmoene commented 4 years ago

@mjacobse Thanks for looking a bit more carefully into it :)