private function isOfLowerPrecedence(Token $token)
    {
        static $tokens;

        if (null === $tokens) {
            $tokens = [
                T_AND_EQUAL,    // &=
                T_BOOLEAN_AND,  // &&
                T_BOOLEAN_OR,   // ||
                T_CASE,         // case
                T_CONCAT_EQUAL, // .=
                T_DIV_EQUAL,    // /=
                T_DOUBLE_ARROW, // =>
                T_GOTO,         // goto
                T_LOGICAL_AND,  // and
                T_LOGICAL_OR,   // or
                T_LOGICAL_XOR,  // xor
                T_MINUS_EQUAL,  // -=
                T_MUL_EQUAL,    // *=
                T_OR_EQUAL,     // |=
                T_PLUS_EQUAL,   // +=
                T_RETURN,       // return
                T_SL_EQUAL,     // <<
                T_SR_EQUAL,     // >>=
                T_THROW,        // throw
                T_XOR_EQUAL,    // ^=
                T_ECHO,
                T_PRINT,
                T_OPEN_TAG,
                T_OPEN_TAG_WITH_ECHO,
            ];

            if (\defined('T_POW_EQUAL')) {
                $tokens[] = T_POW_EQUAL; // **=
            }

            if (\defined('T_COALESCE')) {
                $tokens[] = T_COALESCE; // ??
            }
        }

        static $otherTokens = [
            // bitwise and, or, xor
            '&', '|', '^',
            // ternary operators
            '?', ':',
            // assignment
            '=',
            // end of PHP statement
            ',', ';',
        ];

        return $token->isGivenKind($tokens) || $token->equalsAny($otherTokens);
    }
private function isOfLowerPrecedence(Token $token)
    {
        static $tokens;

        if (null === $tokens) {
            $tokens = [
                T_AND_EQUAL,    
                T_BOOLEAN_AND,  
                T_BOOLEAN_OR,   
                T_CASE,         
                T_CONCAT_EQUAL, 
                T_DIV_EQUAL,    
                T_DOUBLE_ARROW, 
                T_GOTO,         
                T_LOGICAL_AND,  
                T_LOGICAL_OR,   
                T_LOGICAL_XOR,  
                T_MINUS_EQUAL,  
                T_MUL_EQUAL,    
                T_OR_EQUAL,     
                T_PLUS_EQUAL,   
                T_RETURN,       
                T_SL_EQUAL,     
                T_SR_EQUAL,     
                T_THROW,        
                T_XOR_EQUAL,    
                T_ECHO,
                T_PRINT,
                T_OPEN_TAG,
                T_OPEN_TAG_WITH_ECHO,
            ];

            if (\defined('T_POW_EQUAL')) {
                $tokens[] = T_POW_EQUAL; 
            }

            if (\defined('T_COALESCE')) {
                $tokens[] = T_COALESCE; 
            }
        }

        static $otherTokens = [
            
            '&', '|', '^',
            
            '?', ':',
            
            '=',
            
            ',', ';',
        ];

        return $token->isGivenKind($tokens) || $token->equalsAny($otherTokens);
    }
private function isOfLowerPrecedence ( Token $ token ) { static $ tokens ; if ( null === $ tokens ) { $ tokens = [ T_AND_EQUAL , // &= T_BOOLEAN_AND , // && T_BOOLEAN_OR , // || T_CASE , // case T_CONCAT_EQUAL , // .= T_DIV_EQUAL , // /= T_DOUBLE_ARROW , // => T_GOTO , // goto T_LOGICAL_AND , // and T_LOGICAL_OR , // or T_LOGICAL_XOR , // xor T_MINUS_EQUAL , // -= T_MUL_EQUAL , // *= T_OR_EQUAL , // |= T_PLUS_EQUAL , // += T_RETURN , // return T_SL_EQUAL , // << T_SR_EQUAL , // >>= T_THROW , // throw T_XOR_EQUAL , // ^= T_ECHO , T_PRINT , T_OPEN_TAG , T_OPEN_TAG_WITH_ECHO , ] ; if ( \ defined ( 'T_POW_EQUAL' ) ) { $ tokens [ ] = T_POW_EQUAL ; // **= } if ( \ defined ( 'T_COALESCE' ) ) { $ tokens [ ] = T_COALESCE ; // ?? } } static $ otherTokens = [ // bitwise and, or, xor '&' , '|' , '^' , // ternary operators '?' , ':' , // assignment '=' , // end of PHP statement ',' , ';' , ] ; return $ token -> isGivenKind ( $ tokens ) || $ token -> equalsAny ( $ otherTokens ) ; }
Checks whether the given token has a lower precedence than `T_IS_EQUAL`
or `T_IS_IDENTICAL`.

@param Token $token The token to check

@return bool Whether the token has a lower precedence
Checks whether the given token has a lower precedence than T_IS_EQUAL or T_IS_IDENTICAL .