golang/go

cmd/compile, go/types, types2: rename 'imported and not used' error to 'imported but not used'

Open

#47,089 opened on Jul 7, 2021

View on GitHub
 (2 comments) (0 reactions) (0 assignees)Go (19,008 forks)batch import
NeedsFixhelp wanted

Repository metrics

Stars
 (133,883 stars)
PR merge metrics
 (No merged PRs in 30d)

Description

Commit 449b6ab has reworded, in Go 1.14, the "declared and not used" error message as "declared but not used". I propose to do the same for the "imported and not used" error message.

If an imported package is not used, instead of

imported and not used: "fmt"

the error message would be

imported but not used: "fmt"

Contributor guide