We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4e5ca41 commit 09abc84Copy full SHA for 09abc84
mypyc/test-data/irbuild-weakref.test
@@ -1,7 +1,8 @@
1
[case testWeakrefRef]
2
+from typing import Any, Callable
3
from weakref import ref
-def f(x: object, cb: object) -> object:
4
- return proxy(x, cb)
+def f(x: object, cb: Callable[[object], Any]) -> object:
5
+ return ref(x, cb)
6
7
[out]
8
def f(x):
@@ -13,8 +14,9 @@ L0:
13
14
return r0
15
16
[case testWeakrefProxy]
17
18
from weakref import proxy
19
20
return proxy(x, cb)
21
22
0 commit comments