Restrict conditions for @JvmDefault super calls

Condition was too strict
  if @JvmDefault implicitly hidden by class in inheritance.
  Diagnostic is redundant cause there isn't breaking
  change depending on interface method generation strategy and
  delegating stub generation in inheriting class.
This commit is contained in:
Mikhael Bogdanov
2018-04-10 12:13:24 +02:00
parent e23c406285
commit 56d1184515
10 changed files with 148 additions and 24 deletions
@@ -18,7 +18,7 @@ interface C : B {
}
}
open class <!JVM_DEFAULT_THROUGH_INHERITANCE!>Foo<!> : B {
open class Foo : B {
override fun test() {
super.<!USAGE_OF_JVM_DEFAULT_THROUGH_SUPER_CALL!>test<!>()
}
@@ -37,7 +37,7 @@ open class Bar2 : Bar() {
}
}
class <!JVM_DEFAULT_THROUGH_INHERITANCE!>ManySupers<!>: Foo2(), B {
class ManySupers: Foo2(), B {
fun foo() {
super<Foo2>.test()
super<<!QUALIFIED_SUPERTYPE_EXTENDED_BY_OTHER_SUPERTYPE!>B<!>>.<!USAGE_OF_JVM_DEFAULT_THROUGH_SUPER_CALL!>test<!>()