Enums
Move between a named enum state and its numeric value.
Solidity 0.8.36REPL mode
Why use this example
Use this pattern to explore how Solidity represents typed values and how state-changing expressions affect storage. The entry isolates enums so its input, result, and state changes stay easy to compare.
Solidity to run
enum Status { Pending, Active, Done }
Status status = Status.Active
status
uint256(status)What to expect
Status.Active is displayed as the selected enum member and converts to its numeric value, 1.
Continue the investigation
Change a value, add another expression, or open Inspect after the run. Accepted entries remain available to the next entry, and the clean replay keeps the complete result reproducible.
Read about state and storage Reproducible investigation