Skip to content

Commit

Permalink
Add a module initializer to IKVM.Java, which should preempt any acces…
Browse files Browse the repository at this point in the history
…s to static ctors.
  • Loading branch information
wasabii committed Jun 6, 2024
1 parent c5116bb commit 84c765f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/IKVM.Java/local/ikvm/runtime/Startup.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@ private Startup()

}

@ikvm.lang.ModuleInitializer
public static void init() {
cli.System.GC.KeepAlive(cli.IKVM.Runtime.JVM.class);
};

/**
* Ensures the given assembly is added to the boot class path of the running JVM instance.
*/
Expand Down

0 comments on commit 84c765f

Please sign in to comment.