This repository has been archived by the owner on Feb 26, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Json artifacts are not generated for top-level structures and enums. #3124
Labels
Comments
This was referenced Jun 24, 2020
@montyly thanks for bringing this up! A workaround for now is to make sure there is a contract in the same file. YMMV. We are working on a solution to this that is more elegant/helpful. |
Would it be possible for truffle to emit a warning if one of the top-level element does not generate a json artifact? As we are seeing more and more codebase using this pattern, it breaks many analyses with Slither. |
@montyly yep, this is a good idea. Would you mind opening a separate issue for just the warning? That way it won't get lost |
1 task
Would it be possible to revisit fixing this issue as it negatively impacts the experience of truffle users who want to use Slither? crytic/slither#1834 (comment) |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hi,
Recently Solidity added the support for top-level structures and enums. Their corresponding AST are not correctly generated by Truffle during compilation, which prevents their analyses with Slither (and probably other third-parties).
Issue
Truffle does not generate the json artifacts related to top-level structures and enums.
Steps to Reproduce
Expected Behavior
The build directory should contain a json file with the
StructDefinition
forSt
's AST.Actual Results
Only the AST of the contract
A
is present, and the AST ofSt
is missingEnvironment
The text was updated successfully, but these errors were encountered: