Skip to content

feat(debugger): show generated yul when compiled --via-ir #1252

Open
@zk-tarts

Description

@zk-tarts

Component

Forge

Describe the feature you would like

I think a good feature to add to the debugger would be to see the optimized yul output if your file was compiled with --via-ir option.
This is useful when you want a better view of what the compiler is doing to your code.
My preferred UI would have you able to swap between yul and solidity, like how dapptools' debugger lets you swap between the call trace view and the memory view.
If this is hard to implement then it could be a command line option, and yul would display instead of solidity.

Additional context

Assuming the solidity compiler is consistent, the implementation could follow these steps:

  1. Compile solidity --via ir which generates a solidity --> bytecode sourcemap
  2. Compile the generated yul which will output a yul --> bytecode sourcemap.

#759 is worth mentioning because yul compilation is required to do those steps.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Todo

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions