Skip to content

Commit

Permalink
Update crates/red_knot_python_semantic/src/types/infer.rs
Browse files Browse the repository at this point in the history
Co-authored-by: Carl Meyer <[email protected]>
  • Loading branch information
Glyphack and carljm authored Dec 16, 2024
1 parent 13aff20 commit 4d835da
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crates/red_knot_python_semantic/src/types/infer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1127,7 +1127,7 @@ impl<'db> TypeInferenceBuilder<'db> {
let inferred_ty = if let Some(default_ty) = default_ty {
if default_ty.is_assignable_to(self.db, declared_ty) {
UnionType::from_elements(self.db, [declared_ty, default_ty])
} else if default
} else if self.file.is_stub() && default
.as_ref()
.is_some_and(|d| d.is_ellipsis_literal_expr())
{
Expand Down

0 comments on commit 4d835da

Please sign in to comment.