mirror of
https://github.com/danog/psalm.git
synced 2025-01-22 13:51:54 +01:00
Merge pull request #10156 from boesing/bugfix/prevent-infinite-loop-in-type-parser
This commit is contained in:
commit
cc7ed9586e
@ -1629,9 +1629,7 @@ class TypeParser
|
||||
continue;
|
||||
}
|
||||
|
||||
$modified = true;
|
||||
|
||||
$normalized_intersection_types[] = TypeExpander::expandAtomic(
|
||||
$expanded_intersection_type = TypeExpander::expandAtomic(
|
||||
$codebase,
|
||||
$intersection_type,
|
||||
null,
|
||||
@ -1644,6 +1642,9 @@ class TypeParser
|
||||
true,
|
||||
true,
|
||||
);
|
||||
|
||||
$modified = $modified || $expanded_intersection_type[0] !== $intersection_type;
|
||||
$normalized_intersection_types[] = $expanded_intersection_type;
|
||||
}
|
||||
|
||||
if ($modified === false) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user