Code Duplication    Length = 5-6 lines in 3 locations

PHPCompatibility/Sniff.php 3 locations

@@ 1380-1385 (lines=6) @@
1377
            // it's likely to be an array which might have arguments in it. This
1378
            // could cause problems in our parsing below, so lets just skip to the
1379
            // end of it.
1380
            if (isset($tokens[$i]['parenthesis_opener']) === true) {
1381
                // Don't do this if it's the close parenthesis for the method.
1382
                if ($i !== $tokens[$i]['parenthesis_closer']) {
1383
                    $i = ($tokens[$i]['parenthesis_closer'] + 1);
1384
                }
1385
            }
1386
1387
            if (isset($tokens[$i]['bracket_opener']) === true) {
1388
                // Don't do this if it's the close parenthesis for the method.
@@ 1387-1392 (lines=6) @@
1384
                }
1385
            }
1386
1387
            if (isset($tokens[$i]['bracket_opener']) === true) {
1388
                // Don't do this if it's the close parenthesis for the method.
1389
                if ($i !== $tokens[$i]['bracket_closer']) {
1390
                    $i = ($tokens[$i]['bracket_closer'] + 1);
1391
                }
1392
            }
1393
1394
            switch ($tokens[$i]['type']) {
1395
                case 'T_BITWISE_AND':
@@ 1965-1969 (lines=5) @@
1962
                && $i === $tokens[$i]['bracket_opener']
1963
            ) {
1964
                $i = $tokens[$i]['bracket_closer'];
1965
            } else if (isset($tokens[$i]['parenthesis_closer']) === true
1966
                && $i === $tokens[$i]['parenthesis_opener']
1967
            ) {
1968
                $i = $tokens[$i]['parenthesis_closer'];
1969
            }
1970
1971
            if (isset(\PHP_CodeSniffer_Tokens::$emptyTokens[$tokens[$i]['code']]) === false) {
1972
                $lastNotEmpty = $i;