JVM_IR: fix NPE in interface companion initializers

* When referencing the companion itself, they should use the $$INSTANCE
  field, not the (null until <clinit> returns) Companion field of the
  interface.

* Interface companion init blocks should be made static.
This commit is contained in:
pyos
2019-11-05 13:23:29 +01:00
committed by max-kammerer
parent 7c015564ce
commit 939a9ff53e
11 changed files with 83 additions and 129 deletions
@@ -1,6 +1,5 @@
// !LANGUAGE: +NestedClassesInAnnotations
// IGNORE_BACKEND_FIR: JVM_IR
// IGNORE_BACKEND: JVM_IR
// WITH_RUNTIME
import kotlin.test.*