JVM IR: never produce "$s<hash>" suffix for accessors in interfaces

Not sure if this affects real code, but this could happen in erroneous
cases such as in the subsequent commit, where it was a bit weird to see
this suffix without any supercalls involved.
This commit is contained in:
Alexander Udalov
2019-12-27 23:22:07 +01:00
parent 3193689086
commit 3848ac9cac
@@ -464,8 +464,7 @@ internal class SyntheticAccessorLowering(val context: JvmBackendContext) : IrEle
// The only function accessors placed on interfaces are for private functions and JvmDefault implementations.
// The two cannot clash.
parentAsClass.isJvmInterface && Visibilities.isPrivate(visibility) -> ""
parentAsClass.isJvmInterface && hasJvmDefault() -> "\$jd"
parentAsClass.isJvmInterface -> if (!Visibilities.isPrivate(visibility) && hasJvmDefault()) "\$jd" else ""
// Accessor for _s_uper-qualified call
superQualifier != null -> "\$s" + superQualifier.descriptor.name.asString().hashCode()