Skip to content

Commit a70eb5e

Browse files
committed
review comments
1 parent ae1e527 commit a70eb5e

File tree

1 file changed

+4
-2
lines changed
  • crates/ty_python_semantic/resources/mdtest/annotations

1 file changed

+4
-2
lines changed

crates/ty_python_semantic/resources/mdtest/annotations/self.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -310,17 +310,19 @@ class Container[T = bytes]:
310310
def method(self) -> Self:
311311
return self
312312

313-
def _(c: Container[str]):
313+
def _(c: Container[str], d: Container):
314314
reveal_type(c.method()) # revealed: Container[str]
315+
reveal_type(d.method()) # revealed: Container[bytes]
315316

316317
T = TypeVar("T", default=bytes)
317318

318319
class LegacyContainer(Generic[T]):
319320
def method(self) -> Self:
320321
return self
321322

322-
def _(c: LegacyContainer[str]):
323+
def _(c: LegacyContainer[str], d: LegacyContainer):
323324
reveal_type(c.method()) # revealed: LegacyContainer[str]
325+
reveal_type(d.method()) # revealed: LegacyContainer[bytes]
324326
```
325327

326328
## Invalid Usage

0 commit comments

Comments
 (0)