Skip to content

Commit

Permalink
Removing unnecessary static casting
Browse files Browse the repository at this point in the history
  • Loading branch information
anshulchou-123 committed Apr 23, 2024
1 parent 8c5e342 commit dacdde8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/nlohmann/detail/output/binary_writer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -1085,7 +1085,7 @@ class binary_writer
write_bson_entry_header(name, 0x12 /* int64 */);
write_number<std::int64_t>(static_cast<std::int64_t>(j.m_data.m_value.number_unsigned), true);
}
else if (j.m_data.m_value.number_unsigned <= static_cast<std::uint64_t>((std::numeric_limits<std::uint64_t>::max)()))
else if (j.m_data.m_value.number_unsigned <= (std::numeric_limits<std::uint64_t>::max)())
{
write_bson_entry_header(name, 11 /* uint64 */);
write_number<std::uint64_t>(static_cast<std::uint64_t>(j.m_data.m_value.number_unsigned), true);
Expand Down

0 comments on commit dacdde8

Please sign in to comment.