[FIR] Consider expect declarations in defaults arguments inheritance checker
Actual functions cannot declare default values for parameters Corresponding expect function should be checked instead
This commit is contained in:
committed by
Nikolay Lunyak
parent
2982f548d4
commit
e8f5e35a86
+4
-4
@@ -16,8 +16,8 @@ expect interface I2 {
|
||||
override fun foo(<!MULTIPLE_DEFAULTS_INHERITED_FROM_SUPERTYPES!>x: Int<!>)
|
||||
}
|
||||
|
||||
interface CommonInterface : I1, I2 {
|
||||
override fun foo(x: Int)
|
||||
<!MULTIPLE_DEFAULTS_INHERITED_FROM_SUPERTYPES_WHEN_NO_EXPLICIT_OVERRIDE!>interface CommonInterface<!> : I1, I2 {
|
||||
override fun foo(<!MULTIPLE_DEFAULTS_INHERITED_FROM_SUPERTYPES!>x: Int<!>)
|
||||
}
|
||||
|
||||
// MODULE: m1-jvm()()(m1-common)
|
||||
@@ -33,6 +33,6 @@ actual interface I2 {
|
||||
actual fun bar(x: Int)
|
||||
}
|
||||
|
||||
actual interface ExpectInterface : I1, I2 {
|
||||
actual override fun foo(x: Int)
|
||||
<!MULTIPLE_DEFAULTS_INHERITED_FROM_SUPERTYPES_WHEN_NO_EXPLICIT_OVERRIDE!>actual interface ExpectInterface<!> : I1, I2 {
|
||||
actual override fun foo(<!MULTIPLE_DEFAULTS_INHERITED_FROM_SUPERTYPES!>x: Int<!>)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user