Skip to content

Commit

Permalink
core: fix compiler warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
deniskovalchuk committed Nov 11, 2024
1 parent 23532d8 commit ead9029
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ bool try_parse_uint8(std::string_view str, std::uint8_t & result)
if (value > std::numeric_limits<std::uint8_t>::max())
return false;

result = value;
result = static_cast<std::uint8_t>(value);
return true;
}

Expand All @@ -81,7 +81,7 @@ bool try_parse_uint16(std::string_view str, std::uint16_t & result)
if (value > std::numeric_limits<std::uint16_t>::max())
return false;

result = value;
result = static_cast<std::uint16_t>(value);
return true;
}

Expand All @@ -95,7 +95,7 @@ bool try_parse_uint32(std::string_view str, std::uint32_t & result)
if (value > std::numeric_limits<std::uint32_t>::max())
return false;

result = value;
result = static_cast<std::uint32_t>(value);
return true;
}

Expand Down

0 comments on commit ead9029

Please sign in to comment.