Skip to content

Commit 7995e43

Browse files
committed
these need to be positional only to be assignable
1 parent dbecc68 commit 7995e43

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

crates/ty_python_semantic/resources/mdtest/generics/legacy/functions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -379,7 +379,7 @@ T = TypeVar("T")
379379
def invoke(fn: Callable[[A], B], value: A) -> B:
380380
return fn(value)
381381

382-
def identity(x: T) -> T:
382+
def identity(x: T, /) -> T:
383383
return x
384384

385385
def head(xs: list[T]) -> T:

crates/ty_python_semantic/resources/mdtest/generics/pep695/functions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -334,7 +334,7 @@ from typing import Callable
334334
def invoke[A, B](fn: Callable[[A], B], value: A) -> B:
335335
return fn(value)
336336

337-
def identity[T](x: T) -> T:
337+
def identity[T](x: T, /) -> T:
338338
return x
339339

340340
def head[T](xs: list[T]) -> T:

0 commit comments

Comments
 (0)