Error Identifiers: parameter.*

Menu

← Back to all error identifiers

There are 29 error identifiers in the parameter.* group:

  • Parameter pass-by-reference does not match the parent method declaration.

  • Default value of a parameter is incompatible with its declared type.

  • Parameter type declaration uses a deprecated class.

  • Parameter type declaration uses a deprecated enum.

  • Parameter type declaration uses a deprecated interface.

  • Parameter type references a deprecated trait.

  • Function declares the same parameter name more than once.

  • Parameter has a null default value but its type is not explicitly nullable.

  • Parameter type declaration uses an internal class from another package.

  • Parameter type declaration uses an internal enum from another package.

  • Parameter type declaration uses an internal interface from another package.

  • Parameter type declaration references an internal trait from another package.

  • Overriding method is missing a parameter that exists in the parent method.

  • Parameter uses the parent type but the class does not extend any class.

  • Parameter is not passed by reference but the parent declares it as by-reference.

  • PHPDoc tag references a parameter name that does not exist in the function signature.

  • Overriding method makes an optional parameter required.

  • Overriding method declares a parameter as non-variadic but the parent is variadic.

  • PHPDoc @param type is incompatible with the native parameter type.

  • Required parameter follows an optional parameter.

  • Using a superglobal variable name as a function or method parameter.

  • Using $this as a function or method parameter name.

  • Trait is used as a parameter type declaration, which is not allowed in PHP.

  • Native union types are used but not supported by the configured PHP version.

  • Parameter has a native type declaration that cannot exist at runtime.

  • PHPDoc @param type contains a type expression that cannot be resolved.

  • Overriding method declares a parameter as variadic but the parent is not.

  • Variadic parameter is not the last parameter in the function declaration.

  • Type void is used as a parameter type, which is not allowed in PHP.