Autofix capability of linters #4485
-
Some of the listed linters indicate autofix capability: https://golangci-lint.run/usage/linters |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
This is related to #1779. The linters you're mentioning supports The linked issue is a tracking issue to support this. There's currently no automatic way to support this without adding a separate fixer for One reason it was postponed was because it wasn't stable and only a proposed api (old comment). It has since been removed and is now stable (current comment). |
Beta Was this translation helpful? Give feedback.
This is related to #1779. The linters you're mentioning supports
SuggestedFixes
butgolangci-lint
has its own fix system that was built before it was a part of theanalysis
package.The linked issue is a tracking issue to support this. There's currently no automatic way to support this without adding a separate fixer for
golangci-lint
so it would be better to add supprot forSuggestedFixes
.One reason it was postponed was because it wasn't stable and only a proposed api (old comment). It has since been removed and is now stable (current comment).