diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 9400781..9de6713 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -29,7 +29,7 @@ jobs: continue-on-error: ${{ !matrix.stable }} strategy: matrix: - php: ['8.0', 8.1', '8.2', '8.3'] + php: ['8.0', '8.1', '8.2', '8.3','8.4'] stable: [true] coverage: [true] composer-flags: [''] diff --git a/composer.json b/composer.json index f650976..088c1b4 100644 --- a/composer.json +++ b/composer.json @@ -25,7 +25,7 @@ }, "require-dev": { "mikehaertl/php-shellcommand": "^1.7.0", - "phpstan/phpstan": "^1.10.57", + "phpstan/phpstan": "^2.0", "scrutinizer/ocular": "^1.9", "squizlabs/php_codesniffer": "^3.8.1", "symfony/finder": "^6.0|^7.0", diff --git a/phpstan.neon.dist b/phpstan.neon.dist index e43e64c..c839c3f 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -1,4 +1,4 @@ parameters: - level: 3 + level: 5 paths: - src diff --git a/src/Json5Decoder.php b/src/Json5Decoder.php index 0d7209a..5b2da32 100644 --- a/src/Json5Decoder.php +++ b/src/Json5Decoder.php @@ -63,7 +63,7 @@ public static function decode(string $json, ?bool $associative = false, int $dep // Fall back to JSON5 if that fails $associative = $associative === true || ($associative === null && $flags & \JSON_OBJECT_AS_ARRAY); - $castBigIntToString = $flags & \JSON_BIGINT_AS_STRING; + $castBigIntToString = (bool) ($flags & \JSON_BIGINT_AS_STRING); $decoder = new self($json, $associative, $depth, $castBigIntToString);