src/Fixer/Operator/TernaryToNullCoalescingFixer.php
private function getMeaningfulSequence(Tokens $tokens, $start, $end)
    {
        $sequence = [];
        $index = $start;
        while ($index < $end) {
            $index = $tokens->getNextMeaningfulToken($index);
            if ($index >= $end || null === $index) {
                break;
            }

            $sequence[] = $tokens[$index];
        }

        return Tokens::fromArray($sequence);
    }
private function getMeaningfulSequence(Tokens $tokens, $start, $end)
    {
        $sequence = [];
        $index = $start;
        while ($index < $end) {
            $index = $tokens->getNextMeaningfulToken($index);
            if ($index >= $end || null === $index) {
                break;
            }

            $sequence[] = $tokens[$index];
        }

        return Tokens::fromArray($sequence);
    }
private function getMeaningfulSequence ( Tokens $ tokens , $ start , $ end ) { $ sequence = [ ] ; $ index = $ start ; while ( $ index < $ end ) { $ index = $ tokens -> getNextMeaningfulToken ( $ index ) ; if ( $ index >= $ end || null === $ index ) { break ; } $ sequence [ ] = $ tokens [ $ index ] ; } return Tokens :: fromArray ( $ sequence ) ; }
Get the sequence of meaningful tokens and returns a new Tokens instance.

@param Tokens $tokens
@param int    $start  start index
@param int    $end    end index

@return Tokens
Get the sequence of meaningful tokens and returns a new Tokens instance .