HEX
Server: Apache/2.4.65 (Debian)
System: Linux wordpress-7cb4c6b6f6-l5jc2 5.15.0-131-generic #141-Ubuntu SMP Fri Jan 10 21:18:28 UTC 2025 x86_64
User: www-data (33)
PHP: 8.3.27
Disabled: NONE
Upload Files
File: /var/www/html/wp-content/plugins/elementor/vendor_prefixed/twig/symfony/polyfill-php81/Php81.php
<?php

/*
 * This file is part of the Symfony package.
 *
 * (c) Fabien Potencier <[email protected]>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */
namespace ElementorDeps\Symfony\Polyfill\Php81;

/**
 * @author Nicolas Grekas <[email protected]>
 *
 * @internal
 */
final class Php81
{
    public static function array_is_list(array $array) : bool
    {
        if ([] === $array || $array === \array_values($array)) {
            return \true;
        }
        $nextKey = -1;
        foreach ($array as $k => $v) {
            if ($k !== ++$nextKey) {
                return \false;
            }
        }
        return \true;
    }
}