SR-10198 Cannot override more than one superclass declaration
Issue Description:
Overriding a base class function and introducing an overload in the derived class based solely on the inout status of the parameter causes the compiler to think that the method is overridden twice.
This appears to happen regardless of whether an inout parameter is overridden or a non-inout parameter is overridden. This worked prior to upgrading to XCode 10.2.
Below, XCode reports the 'f(i: Int)' function declared in Derived as already overridden.
Recall that parameter types no longer include an InOutType, so the problem here is that override checking is not checking parameter flags. In 4.2 I think we just compared tuple types.
Environment
Swift 4.2
XCode 10.2
Additional Detail from JIRA
md5: 1d2b0351efbb0962eb5ccace68a59193
relates to:
Issue Description:
Overriding a base class function and introducing an overload in the derived class based solely on the inout status of the parameter causes the compiler to think that the method is overridden twice.
This appears to happen regardless of whether an inout parameter is overridden or a non-inout parameter is overridden. This worked prior to upgrading to XCode 10.2.
Below, XCode reports the 'f(i: Int)' function declared in Derived as already overridden.
The text was updated successfully, but these errors were encountered: