freespek / solarkraft

Solarkraft: a runtime monitoring tool for Soroban, powered by TLA+ and Apalache
Apache License 2.0
12 stars 0 forks source link

Add type hint support for Enums #92

Closed Kukovec closed 3 months ago

Kukovec commented 3 months ago

At the level of data extracted via fetch we cannot disambiguate between unary enums (or enums which wrap symbols) from vectors. One way of distinguishing the two is via an external type hints file, while another would be by pulling and processing wasm code directly. The former disregards contract lifetimes, while the latter is more automatable (though complicated to implement due to the added need rto deal with wasm bytecode). We implement the former approach, but may revisit this in the future.