Code Duplication    Length = 14-14 lines in 2 locations

src/Arrayy.php 2 locations

@@ 3294-3307 (lines=14) @@
3291
     * @return bool
3292
     *              <p>Returns true if associative, false otherwise.</p>
3293
     */
3294
    public function isAssoc(bool $recursive = false): bool
3295
    {
3296
        if ($this->isEmpty()) {
3297
            return false;
3298
        }
3299
3300
        /** @noinspection PhpParameterByRefIsNotUsedAsReferenceInspection */
3301
        foreach ($this->keys($recursive)->getGeneratorByReference() as &$key) {
3302
            if ((string) $key !== $key) {
3303
                return false;
3304
            }
3305
        }
3306
3307
        return true;
3308
    }
3309
3310
    /**
@@ 3372-3385 (lines=14) @@
3369
     * @return bool
3370
     *              <p>Returns true if numeric, false otherwise.</p>
3371
     */
3372
    public function isNumeric(): bool
3373
    {
3374
        if ($this->isEmpty()) {
3375
            return false;
3376
        }
3377
3378
        /** @noinspection PhpParameterByRefIsNotUsedAsReferenceInspection */
3379
        foreach ($this->keys()->getGeneratorByReference() as &$key) {
3380
            if ((int) $key !== $key) {
3381
                return false;
3382
            }
3383
        }
3384
3385
        return true;
3386
    }
3387
3388
    /**