ImageJ1: "Compile and Run" problem with Java 9

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

ImageJ1: "Compile and Run" problem with Java 9

Burger Wilhelm
Testing ImageJ1 with Java 9 (jre.9.0.4) for the first time, I noticed that "Compile and Run" is not working any longer. When applied to a plugin's .class file (which is what I usually do) there is no reaction at all first but after several seconds a StackOverflowError is shown. This is the same on Windows7 and MacOs.

Running pre-installed plugins from the  "Plugins" menu works as expected.

Has anyone noticed this problem and can suggest a fix?

--Wilhelm
--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
Reply | Threaded
Open this post in threaded view
|

Re: ImageJ1: "Compile and Run" problem with Java 9

Burger Wilhelm
> Testing ImageJ1 with Java 9 (jre.9.0.4) for the first time, I noticed that "Compile and Run" is not working any longer.
> When applied to a plugin's .class file (which is what I usually do) there is no reaction at all first but after several seconds
> a StackOverflowError is shown. This is the same on Windows7 and MacOs.

OK, I did some more checking:
* "Compile and run" works fine as long as the plugin class is in the default package. The problem appears only when the plugin is defined inside a package (subfolder).
* In this case, ImageJ's class cloader appears to delegate class loading recursively, until the Java stack is full and the runtime crashes.

--Wilhelm

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html