Code Duplication    Length = 8-11 lines in 3 locations

src/Tokenizers/CSS.php 1 location

@@ 155-165 (lines=11) @@
152
                continue;
153
            }
154
155
            if ($token['code'] === T_FUNCTION) {
156
                // There are no functions in CSS, so convert this to a string.
157
                $finalTokens[$newStackPtr] = array(
158
                                              'type'    => 'T_STRING',
159
                                              'code'    => T_STRING,
160
                                              'content' => $token['content'],
161
                                             );
162
163
                $newStackPtr++;
164
                continue;
165
            }
166
167
            if ($token['code'] === T_COMMENT
168
                && substr($token['content'], 0, 2) === '/*'

src/Tokenizers/PHP.php 2 locations

@@ 556-563 (lines=8) @@
553
554
            if ($tokenIsArray === false && ($token[0] === '"' || $token[0] === 'b"')) {
555
                // Binary casts need a special token.
556
                if ($token[0] === 'b"') {
557
                    $finalTokens[$newStackPtr] = array(
558
                                                  'code'    => T_BINARY_CAST,
559
                                                  'type'    => 'T_BINARY_CAST',
560
                                                  'content' => 'b',
561
                                                 );
562
                    $newStackPtr++;
563
                }
564
565
                $tokenContent = '"';
566
                $nestedVars   = array();
@@ 1009-1017 (lines=9) @@
1006
                                T_NAMESPACE            => true,
1007
                                T_PAAMAYIM_NEKUDOTAYIM => true,
1008
                               );
1009
                    if (isset($context[$finalTokens[$lastNotEmptyToken]['code']]) === true) {
1010
                        $finalTokens[$newStackPtr] = array(
1011
                                                      'content' => $token[1],
1012
                                                      'code'    => T_STRING,
1013
                                                      'type'    => 'T_STRING',
1014
                                                     );
1015
                        $newStackPtr++;
1016
                        continue;
1017
                    }
1018
                }//end if
1019
1020
                $newToken = null;