Inspectopedia Help

Unused parameter

Reports the parameters that are considered unused in the following cases:

  • The parameter is passed by value, and the value is not used anywhere or is overwritten immediately.

  • The parameter is passed by reference, and the reference is not used anywhere or is overwritten immediately.

Inspection options

Option

Type

Default

Ignore parameters of methods/functions with empty body

Checkbox

true

Ignore parameters of overriding methods

Checkbox

true

Ignore parameters of abstract classes' methods

Checkbox

false

Ignore parameters of anonymous functions

Checkbox

false

Don't report parameters accessed via 'func_num_args()'

Checkbox

false

Inspection Details

Available in:

PhpStorm 2023.3, Qodana for PHP 2023.3

Plugin:

PHP, 233.SNAPSHOT

Last modified: 13 July 2023