.. _php-parenthesisasparameter: .. _parenthesis-as-parameter: Parenthesis As Parameter ++++++++++++++++++++++++ Using parenthesis around parameters used to silent some internal check. This is not the case anymore in PHP 7, and should be fixed by removing the parenthesis and making the value a real reference. .. code-block:: php See also `Parentheses around function arguments no longer affect behaviour `_. Related PHP errors ------------------- + `0 `_ Connex PHP features ------------------- + `parenthesis `_ + `parameter `_ Suggestions ___________ * Remove the parenthesis when they are only encapsulating an argument * Replace the parenthesis by the no-scream operator Specs _____ +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Short name | Php/ParenthesisAsParameter | +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Rulesets | :ref:`All `, :ref:`Changed Behavior `, :ref:`CompatibilityPHP53 `, :ref:`CompatibilityPHP54 `, :ref:`CompatibilityPHP55 `, :ref:`CompatibilityPHP56 ` | +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Exakat since | 0.8.4 | +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | PHP Version | With PHP 7.0 and older | +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Severity | Major | +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Time To Fix | Quick (30 mins) | +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Precision | Very high | +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Available in | `Entreprise Edition `_, `Exakat Cloud `_ | +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+