RFR: 8198317: Enhance JavacTool.getTask for flexibility [v3]

Guoxiong Li github.com+13688759+lgxbslgx at openjdk.java.net
Tue Jan 5 14:31:57 UTC 2021


On Tue, 29 Dec 2020 03:43:14 GMT, Jonathan Gibbons <jjg at openjdk.org> wrote:

>> Any time that tests split a string into lines it is really important to ensure that it works on Windows as well as Linux/Mac platforms, because of the different line endings.
>> 
>> The code looks OK. Alternatively, if you are not concerned to check for the exact line ending sequence, you can use `split("\\R")` to split on any line ending sequence.  Either way, it's worth checking the test runs on platforms with both kinds of typical line ending.
>
> Given that the `langtools/tier1` pre-submit tests worked for Linux and Windows, you're OK on the "newline" front.

@jonathan-gibbons I updated the code according to your comments. Thank you for taking the time to review.

-------------

PR: https://git.openjdk.java.net/jdk/pull/1896


More information about the compiler-dev mailing list