On Fri, 20 Feb 2026 23:18:18 GMT, Michael Strauß <[email protected]> wrote:
>> so this is basically an invalid test, right? >> >> >> jshell> var a = 0.19999999999999998335; >> a ==> 0.19999999999999998 > > In contrast to a `long` literal, a `double` literal can have any number of > digits. The value of the literal is then determined by the IEEE-754 > round-to-nearest and ties-to-even rule (like in this algorithm). This is why > the literal `0.19999999999999998335` has a value of 0.19999999999999998 (the > nearest representable value). For comparison, the literal > `0.19999999999999997` also has the value 0.19999999999999998. Right, but we are not testing a double literal. We are testing the equivalence to `Double.parseDouble()`, correct? ------------- PR Review Comment: https://git.openjdk.org/jfx/pull/2069#discussion_r2835482660
