[FE 1.0] Report a more precise diagnostic when parameter modifiers (vararg) are changed in actualization
^KT-62747 Fixed
This commit is contained in:
+5
-1
@@ -45,6 +45,10 @@ data class ExpectActualMemberDiff<out M, out C>(val kind: Kind, val actualMember
|
||||
"{0}: the property modifiers (lateinit) of this member must be the same in the expect class and the actual class. " +
|
||||
"This error happens because the expect class ''{1}'' is non-final"
|
||||
),
|
||||
VarargChangedInOverride(
|
||||
"{0}: the parameter modifiers (vararg) of this member must be the same in the expect class and the actual class. " +
|
||||
"This error happens because the expect class ''{1}'' is non-final"
|
||||
),
|
||||
TypeParameterNamesChangedInOverride(
|
||||
"{0}: the type parameter names of this member must be the same in the expect class and the actual class. " +
|
||||
"This error happens because the expect class ''{1}'' is non-final"
|
||||
@@ -82,6 +86,6 @@ fun ExpectActualCompatibility.Incompatible<*>.toMemberDiffKind(): ExpectActualMe
|
||||
ExpectActualCompatibility.Incompatible.TypeParameterVariance -> null // Members are not allowed to have variance
|
||||
ExpectActualCompatibility.Incompatible.ValueParameterCrossinline -> null // inline fun can't be overridden
|
||||
ExpectActualCompatibility.Incompatible.ValueParameterNoinline -> null // inline fun can't be overridden
|
||||
ExpectActualCompatibility.Incompatible.ValueParameterVararg -> ExpectActualMemberDiff.Kind.NonPrivateCallableAdded
|
||||
ExpectActualCompatibility.Incompatible.ValueParameterVararg -> ExpectActualMemberDiff.Kind.VarargChangedInOverride
|
||||
ExpectActualCompatibility.Incompatible.Visibility -> ExpectActualMemberDiff.Kind.VisibilityChangedInOverride
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user