mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-09 00:21:47 +00:00
JVM IR: Mangle interface implementation methods in inline classes
This commit is contained in:
committed by
Alexander Udalov
parent
d21be3b665
commit
6a1e35389c
@@ -0,0 +1,18 @@
|
||||
// !LANGUAGE: +InlineClasses
|
||||
|
||||
interface A<T> {
|
||||
fun foo(a: T): String
|
||||
}
|
||||
|
||||
inline class Foo(val x: Long) : A<Foo> {
|
||||
override fun foo(a: Foo): String = if (x != a.x) "OK" else "FAIL"
|
||||
}
|
||||
|
||||
fun box(): String {
|
||||
return Foo(0L).foo(Foo(1L))
|
||||
}
|
||||
|
||||
// 1 public foo-GWb7d6U\(J\)Ljava/lang/String;
|
||||
// 1 public synthetic bridge foo\(Ljava/lang/Object;\)Ljava/lang/String;
|
||||
// 1 public static foo-GWb7d6U\(JJ\)Ljava/lang/String;
|
||||
// 0 foo\(J
|
||||
Reference in New Issue
Block a user