Skip to content

Commit

Permalink
One more
Browse files Browse the repository at this point in the history
Signed-off-by: Juan Cruz Viotti <[email protected]>
  • Loading branch information
jviotti committed Feb 10, 2024
1 parent 5c52d3e commit 1f99e5b
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/runtime/include/sourcemeta/jsonbinpack/runtime_decoder.h
Original file line number Diff line number Diff line change
Expand Up @@ -130,9 +130,10 @@ class Decoder : private BasicDecoder<CharT, Traits> {
// We trust the encoder that the data we are seeing
// corresponds to a valid 64-bit signed integer.
return sourcemeta::jsontoolkit::JSON{static_cast<std::int64_t>(
-(static_cast<std::int64_t>(this->get_varint() *
options.multiplier)) +
closest_maximum_multiple)};
-(static_cast<std::int64_t>(
this->get_varint() *
static_cast<std::int64_t>(options.multiplier))) +
static_cast<std::int64_t>(closest_maximum_multiple))};
} else {
const std::uint64_t closest_maximum_multiple{
static_cast<std::uint32_t>(std::abs(closest_maximum)) *
Expand Down

0 comments on commit 1f99e5b

Please sign in to comment.