Skip to content

proposal: cmd/fix: apply fixes from modernizers and gofix analyzers #71859

Open
@jba

Description

@jba

(This proposal is the second of a sequence of two; #73605 is the first. --adonovan)

Proposal Details

go fix should have a type of fix called modernize that applies modernizers.

As an example, running go fix would change all occurrences of interface{} to any, provided the identifier any is not shadowed.

For the current set of modernizers, see https://go.googlesource.com/tools/+/refs/heads/master/gopls/internal/analysis/modernize.

Metadata

Metadata

Assignees

Labels

AnalysisIssues related to static analysis (vet, x/tools/go/analysis)ProposalRefactoringIssues related to refactoring toolsToolProposalIssues describing a requested change to a Go tool or command-line program.

Type

No type

Projects

Status

Incoming

Relationships

None yet

Development

No branches or pull requests

Issue actions