Created
August 11, 2024 14:57
-
-
Save luochen1990/fa00e46474fc739299acfc41b50dad42 to your computer and use it in GitHub Desktop.
Pylance typing issue MRE
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def f(x: int): | |
return x + 1 | |
a: int = "abc" | |
f(a) | |
def g(): | |
from collections import namedtuple | |
tupt = namedtuple("Foo", 'x') | |
tup = tupt(1) | |
return tup.x | |
b: int = g() | |
f(b) |
Author
luochen1990
commented
Aug 11, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment