Emit `E_inline_michelson` directly from `%michelson`
Motivation and Context
Instead of using E_raw_code
, we can use E_inline_michelson
to pass arguments. This allows for more clear inlinings in which the arguments are passed directly. E.g., this inliine
let create_ticket (type a) (v : a) (n : nat) : a ticket =
[%Michelson ({| { UNPAIR ; TICKET } |} : a * nat -> a ticket)] (v, n)
becomes
let create_ticket (type a) (v : a) (n : nat) : a ticket =
[%michelson ({| { TICKET } |} v n : a ticket)]
Description
This MR implements the changes using E_inline_michelson
. It updates the stdlib to use this form of inlining.
Component
-
compiler -
website -
webide -
vscode-plugin -
debugger
Types of changes
-
Bug fix (non-breaking change which fixes an issue) -
New feature (non-breaking change which adds functionality) -
Breaking change (fix or feature that would cause existing functionality to not work as expected) -
Performance improvement (non-breaking change that improves performance) -
None (change with no changelog)
Changelog
Checklist:
-
Changes follow the existing coding style (use dune @fmt
to check). -
Tests for the changes have been added (for bug fixes / feature). -
Documentation has been updated. -
Changelog description has been added (if appropriate). -
Start titles under ## Changelog
section with #### (if appropriate). -
There is no image or uploaded file in changelog -
Examples in changed behaviour have been added to the changelog (for breaking change / feature).
Edited by E. Rivas