Fix EVM Bindings generator struct prefix bug#365
Merged
silaslenihan merged 1 commit intomainfrom Apr 9, 2026
Merged
Conversation
dd5d011 to
d756c27
Compare
nolag
approved these changes
Apr 9, 2026
Contributor
nolag
left a comment
There was a problem hiding this comment.
I'm assuming that it wasn't possible to generate code that was sometimes valid that would now be broken. If that's not the case, you may need to create an alias to the broken name...
ibrajer
approved these changes
Apr 9, 2026
Fletch153
pushed a commit
that referenced
this pull request
Apr 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Previously only
tmplStruct.Namewas being updated.tmplField.Typeis set earlier in bindStructType as a plain string and is what the template uses for struct fields in sourcecre.go.tpl({{.Type}}), not the dynamic bindtype path used for method args.So you could get:
type Foo struct { ... }← name was strippedtems []MyContractFoo← field still pointed at the old nameThat’s invalid Go and fails to compile.
Now we are sure to rename the old field names with the new names