We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Currently function types are invariant with respect to argument types. This makes it impossible to use some useful and common idioms, for example:
print(list(map(str, [1, 2, 3])))
Function subtyping (and type inference, if needed) should be modified so that the above code works.
However, argument types should perhaps still be invariant in overriding to avoid complications with overloading.
The text was updated successfully, but these errors were encountered:
JukkaL
No branches or pull requests
Currently function types are invariant with respect to argument types. This makes it impossible to use some useful and common idioms, for example:
Function subtyping (and type inference, if needed) should be modified so that the above code works.
However, argument types should perhaps still be invariant in overriding to avoid complications with overloading.
The text was updated successfully, but these errors were encountered: