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
OSX 10.12.2, Xcode 8.2 (8C38)
md5: c9c3f541b061abc3c8aa22c3bb8079cf
Issue Description:
When the following Objective-C is bridged to Swift:
@interface BaseClass : NSObject - (void)method; @end @interface Subclass<T> : BaseClass - (void)method; @end
And used as follows from Swift:
let subclass: Subclass<NSNumber> = Subclass() subclass.method()
It results in the following compiler error:
Ambiguous.swift:: error: ambiguous use of 'method()' subclass.method() ^ __ObjC.Subclass:3:15: note: found this candidate open func method() ^ __ObjC.BaseClass:3:15: note: found this candidate open func method() ^
The generated header looks as follows:
open class BaseClass : NSObject { open func method() } open class Subclass<T : AnyObject> : BaseClass { open func method() }
However, if you implement code identical to the generated header in Swift:
open class BaseClass : NSObject { open func method() {} } open class Subclass<T : AnyObject> : BaseClass { open override func method() {} }
There is no compiler error emitted when invoking `method` as follows:
The text was updated successfully, but these errors were encountered:
slavapestov
No branches or pull requests
Environment
OSX 10.12.2, Xcode 8.2 (8C38)
Additional Detail from JIRA
md5: c9c3f541b061abc3c8aa22c3bb8079cf
Issue Description:
When the following Objective-C is bridged to Swift:
And used as follows from Swift:
It results in the following compiler error:
The generated header looks as follows:
However, if you implement code identical to the generated header in Swift:
There is no compiler error emitted when invoking `method` as follows:
The text was updated successfully, but these errors were encountered: