Skip to main content

storable_alloy_ints

Macro storable_alloy_ints 

Source
storable_alloy_ints!() { /* proc-macro */ }
Expand description

Generate StorableType and Storable implementations for alloy integer types.

Generates implementations for all alloy integer types (both signed and unsigned): U8/I8, U16/I16, U32/I32, U64/I64, U128/I128, U256/I256.

Each type gets:

  • StorableType impl with BYTE_COUNT constant
  • Storable impl with load(), store() methods
  • StorageKey impl for use as mapping keys
  • Auto-generated tests that verify round-trip conversions using alloy’s .random() method