Skip to content

x/tools/gopls/internal/settings: enable more staticcheck passes #73058

Closed
@adonovan

Description

@adonovan

This program triggers no diagnostic from staticcheck's SA4003 analyzer:

func f(x uint8) {
	if x < 0 {
		println(0)
	}
	if x >= 0 {
		println(0)
	}
}

I would have expected it to be on by default and to report that both comparisons are redundant. Why does this not happen?

Metadata

Metadata

Assignees

Labels

FeatureRequestIssues asking for a new feature that does not need a proposal.NeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.ToolsThis label describes issues relating to any tools in the x/tools repository.goplsIssues related to the Go language server, gopls.

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions