Open sambacha opened 2 years ago
Is this report meant to be subimtted to the solc-typed-ast repo?
Is this report meant to be subimtted to the solc-typed-ast repo?
Imma be real with you i opened this issue as a way to reference the idea - bookmark it for myself
Really why not just go to yul ir that would be better
Could you provide more context about what you mean by "going to yul ir" in the context of the solidity debugger?
AST Query
TLDR: Provide an AST pattern, and see details about when that pattern was introduced.
Overview
This enables a much easier way to understand how or why a pattern was introduced. For instance, you can answer questions such as:
solmate
, and which are usingopen-zeppelin
?To query the codebase to search for such a pattern, we can specify an AST selector as it would be accepted by Forge Lint.
For instance, to search for console.log() calls in javascript, the ESLint selector would be
Other use cases
This could be used to help automate refactoring, finding regressions, and more since the debugger is based on a typed AST.
References
see ref. implementation for ESLint, https://github.com/NickHeiner/query-pattern-age/tree/use-in-tv#query-pattern-age