-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
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
overload resolution broken if untyped param
shares position with typed param in some overload
#14827
Comments
untyped param
shares position with typed paramuntyped param
shares position with typed param in some overload
This is actually covered in the spec. But I agree it sucks. |
as mentioned in #15940 (comment) in https://nim-lang.github.io/Nim/manual.html#overloading-resolution-lazy-type-resolution-for-untyped says: "But one has to watch out because other overloads might trigger the argument's resolution:"
|
overload resolution broken if
untyped param
shares position with typed param in some overload.Example
Current Output
Expected Output
works
Additional Information
devel 1.3.5 0327159
seems like the root cause of those:
toSeq
overload messes up iterator visibility RFCs#512block label
matching (template with untyped param) or (iterator) treats param as typed, causing CT errors #14778eg:
#9414 (comment)
This seems fixable, no?
The text was updated successfully, but these errors were encountered: