golang/go

x/tools/go/analysis/passes/modernize: minmax: suggest deletion of redundant min and max functions

Open

#75589 opened on Sep 24, 2025

View on GitHub
 (13 comments) (1 reaction) (0 assignees)Go (133,883 stars) (19,008 forks)batch import
NeedsInvestigationRefactoringToolshelp wanted

Description

Proposal Details

I proposal to add a checker to check whether user has impl a max/min instead of builtin max/min. And suggest user to replace with builtin max/min. search

language:go "func min"

in github with get about 142k result in code.

Contributor guide