src/Fixer/Phpdoc/PhpdocToCommentFixer.php
protected function applyFix(\SplFileInfo $file, Tokens $tokens)
    {
        $commentsAnalyzer = new CommentsAnalyzer();

        foreach ($tokens as $index => $token) {
            if (!$token->isGivenKind(T_DOC_COMMENT)) {
                continue;
            }

            if ($commentsAnalyzer->isHeaderComment($tokens, $index)) {
                continue;
            }

            if ($commentsAnalyzer->isBeforeStructuralElement($tokens, $index)) {
                continue;
            }

            $tokens[$index] = new Token([T_COMMENT, '/*'.ltrim($token->getContent(), '/*')]);
        }
    }
protected function applyFix(\SplFileInfo $file, Tokens $tokens)
    {
        $commentsAnalyzer = new CommentsAnalyzer();

        foreach ($tokens as $index => $token) {
            if (!$token->isGivenKind(T_DOC_COMMENT)) {
                continue;
            }

            if ($commentsAnalyzer->isHeaderComment($tokens, $index)) {
                continue;
            }

            if ($commentsAnalyzer->isBeforeStructuralElement($tokens, $index)) {
                continue;
            }

            $tokens[$index] = new Token([T_COMMENT, '/*'.ltrim($token->getContent(), '/*')]);
        }
    }
protected function applyFix ( \ SplFileInfo $ file , Tokens $ tokens ) { $ commentsAnalyzer = new CommentsAnalyzer ( ) ; foreach ( $ tokens as $ index => $ token ) { if ( ! $ token -> isGivenKind ( T_DOC_COMMENT ) ) { continue ; } if ( $ commentsAnalyzer -> isHeaderComment ( $ tokens , $ index ) ) { continue ; } if ( $ commentsAnalyzer -> isBeforeStructuralElement ( $ tokens , $ index ) ) { continue ; } $ tokens [ $ index ] = new Token ( [ T_COMMENT , '/*' . ltrim ( $ token -> getContent ( ) , '/*' ) ] ) ; } }
{@inheritdoc}
{