From d72f767b09a0908cf80669e9e4823c4d04dd9594 Mon Sep 17 00:00:00 2001 From: Alex Waygood Date: Thu, 24 Apr 2025 22:01:24 +0100 Subject: [PATCH] fix compile error after rebase --- crates/red_knot_python_semantic/src/types/narrow.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/crates/red_knot_python_semantic/src/types/narrow.rs b/crates/red_knot_python_semantic/src/types/narrow.rs index 815d6d8e3a..a63d9d5562 100644 --- a/crates/red_knot_python_semantic/src/types/narrow.rs +++ b/crates/red_knot_python_semantic/src/types/narrow.rs @@ -472,7 +472,9 @@ impl<'db> NarrowingConstraintsBuilder<'db> { union.map(db, |ty| filter_to_cannot_be_equal(db, *ty, rhs_ty)) } // Treat `bool` as `Literal[True, False]`. - Type::NominalInstance(instance) if instance.class().is_known(db, KnownClass::Bool) => { + Type::NominalInstance(instance) + if instance.class().is_known(db, KnownClass::Bool) => + { UnionType::from_elements( db, [Type::BooleanLiteral(true), Type::BooleanLiteral(false)]