JVM, JVM IR: report error if not all parts of multifile class are @JvmSynthetic
#KT-41884 Fixed
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
// WITH_RUNTIME
|
||||
// FILE: f.kt
|
||||
|
||||
@file:JvmName("Foo")
|
||||
@file:JvmMultifileClass
|
||||
@file:JvmSynthetic
|
||||
package test
|
||||
|
||||
fun f() {}
|
||||
|
||||
// FILE: g.kt
|
||||
|
||||
@file:JvmName("Foo")
|
||||
@file:JvmMultifileClass
|
||||
@file:JvmSynthetic
|
||||
package test
|
||||
|
||||
val g = ""
|
||||
@@ -0,0 +1,19 @@
|
||||
@kotlin.Metadata
|
||||
public synthetic final class test/Foo {
|
||||
public final static method f(): void
|
||||
public final static @org.jetbrains.annotations.NotNull method getG(): java.lang.String
|
||||
}
|
||||
|
||||
@kotlin.Metadata
|
||||
synthetic final class test/Foo__FKt {
|
||||
// source: 'f.kt'
|
||||
public final static method f(): void
|
||||
}
|
||||
|
||||
@kotlin.Metadata
|
||||
synthetic final class test/Foo__GKt {
|
||||
// source: 'g.kt'
|
||||
private final static @org.jetbrains.annotations.NotNull field g: java.lang.String
|
||||
static method <clinit>(): void
|
||||
public final static @org.jetbrains.annotations.NotNull method getG(): java.lang.String
|
||||
}
|
||||
+33
@@ -0,0 +1,33 @@
|
||||
// WITH_RUNTIME
|
||||
// FILE: f.kt
|
||||
|
||||
@file:JvmName("Foo")
|
||||
@file:JvmMultifileClass
|
||||
<!NOT_ALL_MULTIFILE_CLASS_PARTS_ARE_JVM_SYNTHETIC!>package test<!>
|
||||
|
||||
fun f() {}
|
||||
|
||||
// FILE: g.kt
|
||||
|
||||
@file:JvmName("Foo")
|
||||
@file:JvmMultifileClass
|
||||
@file:JvmSynthetic
|
||||
package test
|
||||
|
||||
val g = ""
|
||||
|
||||
// FILE: h.kt
|
||||
|
||||
@file:JvmName("Foo")
|
||||
@file:JvmMultifileClass
|
||||
<!NOT_ALL_MULTIFILE_CLASS_PARTS_ARE_JVM_SYNTHETIC!>package test<!>
|
||||
|
||||
fun h() {}
|
||||
|
||||
// FILE: z.kt
|
||||
|
||||
@file:JvmName("Bar")
|
||||
@file:JvmMultifileClass
|
||||
package test
|
||||
|
||||
fun z() {}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
package
|
||||
|
||||
package test {
|
||||
public val g: kotlin.String = ""
|
||||
public fun f(): kotlin.Unit
|
||||
public fun h(): kotlin.Unit
|
||||
public fun z(): kotlin.Unit
|
||||
}
|
||||
Reference in New Issue
Block a user