Documentation
¶
Overview ¶
Package unusedparams defines an analyzer that checks for unused parameters of functions.
Analyzer unusedparams ¶
unusedparams: check for unused parameters of functions
The unusedparams analyzer checks functions to see if there are any parameters that are not being used.
To reduce false positives it ignores: - methods - parameters that do not have a name or have the name '_' (the blank identifier) - functions in test files - functions with empty bodies or those with just a return stmt
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( Analyzer = &analysis.Analyzer{ Name: "unusedparams", Doc: analysisinternal.MustExtractDoc(doc, "unusedparams"), Requires: []*analysis.Analyzer{inspect.Analyzer}, Run: run, URL: "https://pkg.go.dev/golang.org/x/tools/gopls/internal/analysis/unusedparams", } )
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.