Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
In Go, acronyms should be all capitals. But some codegen does not respect this rule. For example, protoc-gen-go generates ParentId rather than ParentID from parent_id. matchIgnoreCase is useful for mapping struct fields regardless of the case of names. But the problem occurs on enum members also, not only struct fields. Currently, matchIgnoreCase is not allowed on enum type converters.
Invalid struct field mapping on method:
/.../example.go:25
var ConvertMethod func(Method) pb.Method
Field mappings like goverter:map or goverter:ignore may only be set on struct or struct pointers.
See https://goverter.jmattheis.de/guide/configure-nested
exit status 1
...: running "go": exit status 1
Describe the solution you'd like
A clear and concise description of what you want to happen.
Extending matchIgnoreCase to support both struct fields and enum members. As discussed in #157, this modification does not look like violating the existing design decision.
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Is your feature request related to a problem? Please describe. A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
In Go, acronyms should be all capitals. But some codegen does not respect this rule. For example, protoc-gen-go generates
ParentId
rather thanParentID
fromparent_id
.matchIgnoreCase
is useful for mapping struct fields regardless of the case of names. But the problem occurs on enum members also, not only struct fields. Currently,matchIgnoreCase
is not allowed on enum type converters.Describe the solution you'd like A clear and concise description of what you want to happen.
Extending
matchIgnoreCase
to support both struct fields and enum members. As discussed in #157, this modification does not look like violating the existing design decision.Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered.
N/A