[go: up one dir, main page]

MIR: add entrypoint to intepret

What

This MR offers entrypoint support for typechecked contracts as an optional argument in the interpret function without the need to use the deployed address.

Why

When integrating MIR with Etherlink, the Michelson smart contracts will not have tezos addresses.

Currently, it is possible to access a contract's entrypoints by manually wrapping the parameter, but this significantly hinders user experience.

How

Before, entrypoints were treated as a hashmap where the key is a string with the name of the entrypoint and the value is the type of that entrypoint. Now, the value is a pair where the first element refers to the path of the entrypoint represented by a string of {"Left ", "Right "}* showing how to wrap any parameter passed to reach the desired entrypoint.

An example of how to use it was added to the project.

Manually testing the MR

This MR can be tested with cargo test.

Closes #7107 (closed)

Edited by Luciano Freitas

Merge request reports

Loading