src/Tokenizer/Analyzer/FunctionsAnalyzer.php
public function isGlobalFunctionCall(Tokens $tokens, $index)
    {
        if (!$tokens[$index]->isGivenKind(T_STRING)) {
            return false;
        }

        $prevIndex = $tokens->getPrevMeaningfulToken($index);
        if ($tokens[$prevIndex]->isGivenKind(T_NS_SEPARATOR)) {
            $prevIndex = $tokens->getPrevMeaningfulToken($prevIndex);
        }

        $nextIndex = $tokens->getNextMeaningfulToken($index);

        return !$tokens[$prevIndex]->isGivenKind([T_DOUBLE_COLON, T_FUNCTION, CT::T_NAMESPACE_OPERATOR, T_NEW, T_OBJECT_OPERATOR, CT::T_RETURN_REF, T_STRING])
            && $tokens[$nextIndex]->equals('(');
    }
public function isGlobalFunctionCall(Tokens $tokens, $index)
    {
        if (!$tokens[$index]->isGivenKind(T_STRING)) {
            return false;
        }

        $prevIndex = $tokens->getPrevMeaningfulToken($index);
        if ($tokens[$prevIndex]->isGivenKind(T_NS_SEPARATOR)) {
            $prevIndex = $tokens->getPrevMeaningfulToken($prevIndex);
        }

        $nextIndex = $tokens->getNextMeaningfulToken($index);

        return !$tokens[$prevIndex]->isGivenKind([T_DOUBLE_COLON, T_FUNCTION, CT::T_NAMESPACE_OPERATOR, T_NEW, T_OBJECT_OPERATOR, CT::T_RETURN_REF, T_STRING])
            && $tokens[$nextIndex]->equals('(');
    }
public function isGlobalFunctionCall ( Tokens $ tokens , $ index ) { if ( ! $ tokens [ $ index ] -> isGivenKind ( T_STRING ) ) { return false ; } $ prevIndex = $ tokens -> getPrevMeaningfulToken ( $ index ) ; if ( $ tokens [ $ prevIndex ] -> isGivenKind ( T_NS_SEPARATOR ) ) { $ prevIndex = $ tokens -> getPrevMeaningfulToken ( $ prevIndex ) ; } $ nextIndex = $ tokens -> getNextMeaningfulToken ( $ index ) ; return ! $ tokens [ $ prevIndex ] -> isGivenKind ( [ T_DOUBLE_COLON , T_FUNCTION , CT :: T_NAMESPACE_OPERATOR , T_NEW , T_OBJECT_OPERATOR , CT :: T_RETURN_REF , T_STRING ] ) && $ tokens [ $ nextIndex ] -> equals ( '(' ) ; }
@param Tokens $tokens
@param int    $index

@return bool
@param Tokens $tokens @param int $index