On Sun, 16 Aug 2026 22:12:19 GMT, Marcono1234 <[email protected]> wrote:
>> Naoto Sato has updated the pull request with a new target base due to a >> merge or a rebase. The pull request now contains 726 commits: >> >> - Merge remote-tracking branch 'jdk-sandbox/json' into >> JDK-8381976-Implementation-for-Simple-JSON-API >> - Address comment regarding asDouble wording in class spec >> - Reflects Alan's comments >> - Merge branch 'master' into JDK-8381976-Implementation-for-Simple-JSON-API >> - Merge remote-tracking branch 'jdk-sandbox/json' into >> JDK-8381976-Implementation-for-Simple-JSON-API >> - Removed unused imports >> - Removed unnecessary qualifiers >> - Merge remote-tracking branch 'jdk-sandbox/json' into >> JDK-8381976-Implementation-for-Simple-JSON-API >> - Merge branch 'toDisplayString' into json >> - wording >> - ... and 716 more: https://git.openjdk.org/jdk/compare/16bf2730...76272098 > > src/jdk.incubator.json/share/classes/jdk/incubator/json/JsonNumber.java line > 131: > >> 129: } >> 130: var str = Double.toString(num); >> 131: return new JsonNumberImpl(str.toCharArray(), 0, str.length(), >> str.indexOf('.'), str.indexOf('E')); > > Will using the string representation here and treating it as `doc` lead to > confusing error messages? For example `JsonNumber.of(1.5).asLong()` will > report a confusing JSON document location? Nicely spotted. Yes, this would be inconsistent because the other factory created JSON values do not use `doc`. Will need to revisit these how the factory creates these `JsonNumber`s. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/32282#discussion_r3797239344
