src/ETSGlobalCodingStandard/Helpers/ArrayHelper.php
/**
     * Checks whether the pointer is positioned on an array.
     *
     * @param int       $arrayPointer The pointer to the array.
     */
Checks whether the pointer is positioned on an array.
@param int       $arrayPointer The pointer to the array.
Checks whether the pointer is positioned on an array . @param int $arrayPointer The pointer to the array .
public static function isArray(File $phpcsFile, int $arrayPointer): bool
    {
        $tokens = $phpcsFile->getTokens();
        return $tokens[$arrayPointer]['type'] === 'T_OPEN_SHORT_ARRAY';
    }
public static function isArray ( File $ phpcsFile , int $ arrayPointer ) : bool { $ tokens = $ phpcsFile -> getTokens ( ) ; return $ tokens [ $ arrayPointer ] [ 'type' ] === 'T_OPEN_SHORT_ARRAY' ; }
Checks whether the pointer is positioned on an array.
Checks whether the pointer is positioned on an array .