diff --git a/crates/red_knot_python_semantic/src/types.rs b/crates/red_knot_python_semantic/src/types.rs index 74b8daa2fcb6a..54075eef7e5bc 100644 --- a/crates/red_knot_python_semantic/src/types.rs +++ b/crates/red_knot_python_semantic/src/types.rs @@ -1010,26 +1010,6 @@ impl<'db> Type<'db> { return false; } - // TODO: The following is a workaround that is required to unify the two different versions - // of `NoneType` and `NoDefaultType` in typeshed. This should not be required anymore once - // we understand `sys.version_info` branches. - if let ( - Type::Instance(InstanceType { class: self_class }), - Type::Instance(InstanceType { - class: target_class, - }), - ) = (self, other) - { - let self_known = self_class.known(db); - if matches!( - self_known, - Some(KnownClass::NoneType | KnownClass::NoDefaultType) - ) && self_known == target_class.known(db) - { - return true; - } - } - // type[object] ≡ type if let ( Type::SubclassOf(SubclassOfType {