17 const std::string random_string(buffer.begin(), buffer.end());
19 const auto i8{ToIntegral<int8_t>(random_string)};
20 const auto u8{ToIntegral<uint8_t>(random_string)};
21 const auto i16{ToIntegral<int16_t>(random_string)};
22 const auto u16{ToIntegral<uint16_t>(random_string)};
23 const auto i32{ToIntegral<int32_t>(random_string)};
24 const auto u32{ToIntegral<uint32_t>(random_string)};
25 const auto i64{ToIntegral<int64_t>(random_string)};
26 const auto u64{ToIntegral<uint64_t>(random_string)};
47 constexpr auto digits{
"0123456789"};
52 assert(random_string.find_first_not_of(digits) == std::string::npos);
58 (void)LocaleIndependentAtoi<int>(random_string);
61 (void)LocaleIndependentAtoi<int64_t>(random_string);
std::optional< CAmount > ParseMoney(const std::string &money_string)
Parse an amount denoted in full coins.
std::string_view RemovePrefixView(std::string_view str, std::string_view prefix)
FUZZ_TARGET(parse_numbers)
bool ParseFixedPoint(std::string_view val, int decimals, int64_t *amount_out)
Parse number as fixed point according to JSON number syntax.