Code Duplication    Length = 5-7 lines in 2 locations

PHPCompatibility/Sniff.php 1 location

@@ 993-997 (lines=5) @@
990
            return false;
991
        }
992
993
        if (isset($tokens[$stackPtr]['parenthesis_closer'], $tokens[$stackPtr]['scope_opener']) === false
994
            || ($tokens[$stackPtr]['parenthesis_closer'] + 1) === $tokens[$stackPtr]['scope_opener']
995
        ) {
996
            return false;
997
        }
998
999
        $hasColon = $phpcsFile->findNext(
1000
            array(T_COLON, T_INLINE_ELSE),

PHPCompatibility/Sniffs/PHP/NewConstantScalarExpressionsSniff.php 1 location

@@ 174-180 (lines=7) @@
171
172
                $funcToken = $tokens[$stackPtr];
173
174
                if (isset($funcToken['parenthesis_owner'], $funcToken['parenthesis_opener'], $funcToken['parenthesis_closer']) === false
175
                    || $funcToken['parenthesis_owner'] !== $stackPtr
176
                    || isset($tokens[$funcToken['parenthesis_opener']], $tokens[$funcToken['parenthesis_closer']]) === false
177
                ) {
178
                    // Hmm.. something is going wrong as these should all be available & valid.
179
                    return;
180
                }
181
182
                $opener = $funcToken['parenthesis_opener'];
183
                $closer = $funcToken['parenthesis_closer'];