It might be a trivial issue, but I am not able to solve it. I have the following function in an objective-c superclass:
+(instancetype) lineWithNumber: (NSString*)number;and I am trying to inherit in a swift subclass with:
class func lineWithNumber(number:NSString)->LineYet if I put the override in front I get error:
Method does not override any method from its superclass
if on the other hand I omit the override keyword it reports:
Method 'lineWithNumber' with Objective-C selector 'lineWithNumber:' conflicts with method 'lineWithNumber' from superclass 'Line' with the same Objective-C selector
I also tried replacing instancetype with Line as in the inheited function with no change.
Calls in other classe would regularly access the Swift function if it were not for the error. What might be the problem, and is there a way to check how Xcode translates Objective-c signatures when they are imported in Swift?