RFR (XS): 8199768 jdk/test/lib/compiler/CompilerUtils.java needs to provide more control over compilation
Alan.Bateman at oracle.com
Mon Mar 19 17:23:20 UTC 2018
On 19/03/2018 05:11, David Holmes wrote:
> Unsure exactly who should review this ...
> bug: https://bugs.openjdk.java.net/browse/JDK-8199768
> webrev: http://cr.openjdk.java.net/~dholmes/8199768/webrev/
> CompilerUtils.compile compiles all source files in a given directory
> tree into a specific directory. This is done by passing
> Integer.MAX_VALUE as the 'depth' argument to Files.find.
> There are times when we** don't want to compile the entire tree into a
> single directory so it would be useful to be able to specify whether
> or not to recurse (depth = Integer.MAX_VALUE) or not (depth = 1).
> ** I need this for some tests I'm developing for Nestmates (JEP 181)
> and it will be simpler to fix this separately in mainline.
Looks okay although an alternative is to just invoke the existing method
with the specify source files that you want to compile (which I think
what is what several tests do when they have only one or two source
files to compile).
More information about the core-libs-dev