Expand description
Misc Serde helpers for foundry crates.
Modules§
Enums§
- Number
OrHex U256 - An enum that represents either a serde_json::Number integer, or a hex [U256].
- Numeric
- Helper type to parse both
u64andU256 - Numeric64
- Helper type to parse a
u64from a JSON number or a hex/decimal string. - Numeric64
Value OrSeq - Helper type to deserialize a single
u64from either a direct value or a one-element sequence. - Numeric
Seq - Helper type to deserialize sequence of numbers
Functions§
- deserialize_
number - Deserializes a number from hex or int
- deserialize_
number_ opt - Deserializes a number from hex or int, but optionally
- deserialize_
number_ seq - Deserializes single integer params:
1, [1], ["0x01"] - deserialize_
u64_ seq - Deserializes single
u64params:1, [1], ["0x01"]. - deserialize_
u64_ seq_ opt - Deserializes an optional integer from a single-element params sequence.
Accepts
[],[null],[n],["0x.."]. - from_
int_ or_ hex - Deserializes the input into a U256, accepting both 0x-prefixed hex and decimal strings with
arbitrary precision, defined by serde_json’s
Number.