We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents dd38409 + 80b40f2 commit ea816fcCopy full SHA for ea816fc
1 file changed
src/PhpDoc/TypeNodeResolver.php
@@ -1260,6 +1260,10 @@ private function expandIntMaskToType(Type $type): ?Type
1260
return IntegerRangeType::fromInterval($min, $max);
1261
}
1262
1263
+ if (count($values) > InitializerExprTypeResolver::CALCULATE_SCALARS_LIMIT) {
1264
+ return IntegerRangeType::fromInterval($min, $max);
1265
+ }
1266
+
1267
return TypeCombinator::union(...array_map(static fn ($value) => new ConstantIntegerType($value), $values));
1268
1269
0 commit comments