Skip to content

Commit 38ac7ad

Browse files
VincentLangletondrejmirtes
authored andcommitted
Fix test
1 parent 920f872 commit 38ac7ad

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/PHPStan/Analyser/nsrt/integer-range-types.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -471,18 +471,18 @@ function subtract($m) {
471471
}
472472

473473
if ($m != false) {
474-
assertType("mixed~0|0.0|''|'0'|array{}|false|null", $m);
474+
assertType("mixed~(0|0.0|''|'0'|array{}|false|null)", $m);
475475
assertType('int', (int) $m);
476476
}
477477
if ($m !== false) {
478478
assertType("mixed~false", $m);
479479
assertType('int', (int) $m); // mixed could still contain falsey values, which cast to 0
480480
}
481481
if (!is_string($m) && !is_float($m)) {
482-
assertType("mixed~float|string", $m);
482+
assertType("mixed~(float|string)", $m);
483483
assertType('int', (int) $m);
484484
if ($m != false) {
485-
assertType("mixed~0|array{}|float|string|false|null", $m);
485+
assertType("mixed~(0|array{}|float|string|false|null)", $m);
486486
assertType('int<min, -1>|int<1, max>', (int) $m);
487487
}
488488
}

0 commit comments

Comments
 (0)