Skip to content

Commit 276e5fb

Browse files
authored
fix: Fix recursive type inference order dependence (#596)
1 parent c0d573a commit 276e5fb

10 files changed

Lines changed: 1107 additions & 414 deletions

File tree

‎crates/plotnik-lib/src/compiler/analyze/types/capture/normalize.rs‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -952,6 +952,13 @@ impl<'s, 'c, 'a, 'd> FieldFlowNormalizer<'s, 'c, 'a, 'd> {
952952
previous_type = right_type;
953953
}
954954
Err(()) => {
955+
// Inference already reported the structural conflict that
956+
// blocked these producers; normalization must not cascade it.
957+
if field.producers.iter().any(|capture_id| {
958+
self.session.input.blocked_capture_ids.contains(capture_id)
959+
}) {
960+
continue;
961+
}
955962
if !self
956963
.reported_conflicts
957964
.insert((name, previous_span, other_span))

0 commit comments

Comments
 (0)