diff --git a/composer.json b/composer.json index 97b3def..7f45de5 100644 --- a/composer.json +++ b/composer.json @@ -25,7 +25,7 @@ }, "require": { "php": ">=8.1", - "cuyz/valinor": "^1.1", + "cuyz/valinor": "^2.0", "lstrojny/functional-php": "^1.0", "mention/kebab": "^1.4.2", "react/event-loop": "^1.2", diff --git a/composer.lock b/composer.lock index f20bd83..a9041ed 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "8883ddf88922362d3bf9bf43fcb9085e", + "content-hash": "2430108c8c4436e7b45544f04244135d", "packages": [ { "name": "beberlei/assert", @@ -75,34 +75,38 @@ }, { "name": "cuyz/valinor", - "version": "1.7.0", + "version": "2.1.2", "source": { "type": "git", "url": "https://github.com/CuyZ/Valinor.git", - "reference": "e384ad6d6801c3d4a03b444d267dbfec91ee23da" + "reference": "03521de8bc7fbf52b0bd07094809ff8f616bbf2d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/CuyZ/Valinor/zipball/e384ad6d6801c3d4a03b444d267dbfec91ee23da", - "reference": "e384ad6d6801c3d4a03b444d267dbfec91ee23da", + "url": "https://api.github.com/repos/CuyZ/Valinor/zipball/03521de8bc7fbf52b0bd07094809ff8f616bbf2d", + "reference": "03521de8bc7fbf52b0bd07094809ff8f616bbf2d", "shasum": "" }, "require": { "composer-runtime-api": "^2.0", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0 || ~8.3.0", - "psr/simple-cache": "^1.0 || ^2.0 || ^3.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0 || ~8.4.0" + }, + "conflict": { + "phpstan/phpstan": "<1.0 || >= 3.0", + "vimeo/psalm": "<5.0 || >=7.0" }, "require-dev": { "friendsofphp/php-cs-fixer": "^3.4", - "infection/infection": "^0.26", + "infection/infection": "^0.29", "marcocesarato/php-conventional-changelog": "^1.12", "mikey179/vfsstream": "^1.6.10", - "phpstan/phpstan": "^1.3", - "phpstan/phpstan-phpunit": "^1.0", - "phpstan/phpstan-strict-rules": "^1.0", - "phpunit/phpunit": "^9.5", - "rector/rector": "~0.17.0", - "vimeo/psalm": "^5.0" + "phpbench/phpbench": "^1.3", + "phpstan/phpstan": "^2.0", + "phpstan/phpstan-phpunit": "^2.0", + "phpstan/phpstan-strict-rules": "^2.0", + "phpunit/phpunit": "^10.5", + "rector/rector": "^2.0", + "vimeo/psalm": "^6.0" }, "type": "library", "autoload": { @@ -136,7 +140,7 @@ ], "support": { "issues": "https://github.com/CuyZ/Valinor/issues", - "source": "https://github.com/CuyZ/Valinor/tree/1.7.0" + "source": "https://github.com/CuyZ/Valinor/tree/2.1.2" }, "funding": [ { @@ -144,7 +148,7 @@ "type": "github" } ], - "time": "2023-10-23T11:05:23+00:00" + "time": "2025-08-28T12:41:24+00:00" }, { "name": "lstrojny/functional-php", @@ -350,57 +354,6 @@ }, "time": "2023-11-28T19:07:29+00:00" }, - { - "name": "psr/simple-cache", - "version": "3.0.0", - "source": { - "type": "git", - "url": "https://github.com/php-fig/simple-cache.git", - "reference": "764e0b3939f5ca87cb904f570ef9be2d78a07865" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/simple-cache/zipball/764e0b3939f5ca87cb904f570ef9be2d78a07865", - "reference": "764e0b3939f5ca87cb904f570ef9be2d78a07865", - "shasum": "" - }, - "require": { - "php": ">=8.0.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Psr\\SimpleCache\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "https://www.php-fig.org/" - } - ], - "description": "Common interfaces for simple caching", - "keywords": [ - "cache", - "caching", - "psr", - "psr-16", - "simple-cache" - ], - "support": { - "source": "https://github.com/php-fig/simple-cache/tree/3.0.0" - }, - "time": "2021-10-29T13:26:27+00:00" - }, { "name": "react/event-loop", "version": "v1.5.0", @@ -4560,12 +4513,12 @@ ], "aliases": [], "minimum-stability": "stable", - "stability-flags": [], + "stability-flags": {}, "prefer-stable": false, "prefer-lowest": false, "platform": { "php": ">=8.1" }, - "platform-dev": [], - "plugin-api-version": "2.3.0" + "platform-dev": {}, + "plugin-api-version": "2.6.0" } diff --git a/src/Internal/MapperHelper.php b/src/Internal/MapperHelper.php index 3504e72..5006522 100644 --- a/src/Internal/MapperHelper.php +++ b/src/Internal/MapperHelper.php @@ -13,7 +13,9 @@ public static function mapper(): TreeMapper return (new MapperBuilder()) ->allowSuperfluousKeys() ->allowPermissiveTypes() - ->enableFlexibleCasting() + ->allowScalarValueCasting() + ->allowNonSequentialList() + ->allowUndefinedValues() ->mapper() ; }