RFR: 8283013: Simplify Arguments::parse_argument() [v2]
David Holmes
dholmes at openjdk.java.net
Mon Mar 28 22:33:43 UTC 2022
On Mon, 28 Mar 2022 20:57:50 GMT, Ioi Lam <iklam at openjdk.org> wrote:
>> src/hotspot/share/runtime/arguments.cpp line 905:
>>
>>> 903: return false;
>>> 904: }
>>> 905: if (g_isnan(v) || !g_isfinite(v)) {
>>
>> Surely the not-sign should not be there ???
>
> This is actually correct. If the number is NOT FINITE, we don't accept it. There's a test case for values like `"Infinity"`:
>
> https://github.com/openjdk/jdk/blob/8413d87666e58c18c914b7df043ba3dbc6fa9022/test/hotspot/gtest/runtime/test_arguments.cpp#L280-L287
Sorry my brain read that as `g_isinfinite()` - doh!
-------------
PR: https://git.openjdk.java.net/jdk/pull/7916
More information about the hotspot-dev
mailing list