Skip to content

Commit

Permalink
fix conflict with minwindef.h on windows
Browse files Browse the repository at this point in the history
  • Loading branch information
nyyakko committed Apr 1, 2024
1 parent dcf3e1a commit af61b7c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions include/cxxopts.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -976,11 +976,11 @@ integer_parser(const std::string& text, T& value)
US limit = 0;
if (negative)
{
limit = static_cast<US>(std::abs(static_cast<intmax_t>(std::numeric_limits<T>::min())));
limit = static_cast<US>(std::abs(static_cast<intmax_t>((std::numeric_limits<T>::min)())));
}
else
{
limit = std::numeric_limits<T>::max();
limit = (std::numeric_limits<T>::max)();
}

if (base != 0 && result > limit / base)
Expand Down

0 comments on commit af61b7c

Please sign in to comment.