subnet-evm
subnet-evm copied to clipboard
add precompile gen cmd & template
Adds precompile gen cmd tool which can take a json ABI file and generates a go-lang precompiled contract. It also can directly detect if the ABI uses AllowList precompile and then configures the generated precompile accordingly.
The PR also contains a guideline and highlights for developers to guide them for a complete precompile integration.
closes #159
LGTM. Would like to propagate the error from configure (can go in as separate PR before this or with this PR)
Couple of future improvements from working on using this:
- add a unit test for precompile generation similar to the bind test
- re-organize the code so the input/output types and helpers are next to the corresponding execution functions