You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[SR-11183] There should be a way to disambiguate methods/properties/nested types with the same name in the same type defined in extensions in different modules
#53580
Open
swift-ci opened this issue
Jul 22, 2019
· 4 comments
@belkadan I had in mind the first option with :: and it looks good to me, but I'd also want to discuss this one:
[1, 2, 3].(MyModule)myMethod
This has the advantage of more precise code completion: as soon as we see an lparen following a period, we can suggest only module names like we do when completing an import declaration, but, unlike the second option in your list, the module parens are not too close to call parens, and we save one period. Compare:
I actually have a prototype implementation of this solution locally but want to also implement the one with a double colon so that everybody could check out both variants and play with them.
Additional Detail from JIRA
md5: 88bc464882feb2ff1ad6082004a35c49
relates to:
Issue Description:
Right now if two modules extend a type with a method/property with the same name, there's no way to refer to any of them in a client module:
I couldn't find a bug for this, so I figured I should create one.
I'd like to work on supporting this in the compiler, and then pitch a syntax for disambiguation, with a working implementation.
The text was updated successfully, but these errors were encountered: