Child of #1724. Needed by Lido (module status enums) and ERC-4337 (IPaymaster.PostOpMode); Morpho does not use enums.
Goal
Solidity-compatible enum declarations in verity_contract:
- Underlying
uint8 representation, member constants, EnumName(x) cast with range check (revert on out-of-range, matching solc)
- Usable as function params/returns, event/error payloads, storage values, and mapping values
- ABI surface identical to solc (
uint8 in the selector/ABI JSON)
Done when
Child of #1724. Needed by Lido (module status enums) and ERC-4337 (
IPaymaster.PostOpMode); Morpho does not use enums.Goal
Solidity-compatible
enumdeclarations inverity_contract:uint8representation, member constants,EnumName(x)cast with range check (revert on out-of-range, matching solc)uint8in the selector/ABI JSON)Done when
PostOpMode-style contract expressible without uint8-constant workaround