Skip to content

BLOCKHASH opcodes should return concrete results. #926

Open
@nbanmp

Description

@nbanmp

Right now, the blockhash and number opcodes always return symbolic values. When connected to a node via rpc, this information is available when the opcodes are called with concrete arguments. We can retrieve that information and return it.

Returning the correct blockhash and number will be especially helpful in generating test cases for contracts that use these as a source of randomness.

Note that the dependence on predictable vars module searches through constraints for the term "blockhash," so it will also be necessary to update that module to use annotations.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions