Skip to content

Commit b748d74

Browse files
committed
Revert "remove unneeded special case"
This reverts commit b7c3791.
1 parent b7c3791 commit b748d74

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

crates/ty_python_semantic/src/types.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4610,6 +4610,11 @@ impl<'db> Type<'db> {
46104610
fn try_iterate(self, db: &'db dyn Db) -> Result<Cow<'db, TupleSpec<'db>>, IterationError<'db>> {
46114611
match self {
46124612
Type::Tuple(tuple_type) => return Ok(Cow::Borrowed(tuple_type.tuple(db))),
4613+
Type::GenericAlias(alias) if alias.origin(db).is_tuple(db) => {
4614+
return Ok(Cow::Owned(TupleSpec::homogeneous(todo_type!(
4615+
"*tuple[] annotations"
4616+
))));
4617+
}
46134618
Type::StringLiteral(string_literal_ty) => {
46144619
// We could go further and deconstruct to an array of `StringLiteral`
46154620
// with each individual character, instead of just an array of

0 commit comments

Comments
 (0)