Skip to content

Latest commit

 

History

History
48 lines (36 loc) · 928 Bytes

no_spaces_inside_parenthesis.rst

File metadata and controls

48 lines (36 loc) · 928 Bytes

Rule no_spaces_inside_parenthesis

There MUST NOT be a space after the opening parenthesis. There MUST NOT be a space before the closing parenthesis.

Warning

This rule is deprecated and will be removed in the next major version

You should use spaces_inside_parentheses instead.

Examples

Example #1

--- Original
+++ New
 <?php
-if ( $a ) {
-    foo( );
+if ($a) {
+    foo();
 }

Example #2

--- Original
+++ New
 <?php
-function foo( $bar, $baz )
+function foo($bar, $baz)
 {
 }

Source class

PhpCsFixer\Fixer\Whitespace\NoSpacesInsideParenthesisFixer