RFR: 8377427: Reduce substring allocations in Color.web(String, double) [v16]

Michael Strauß mstrauss at openjdk.org
Mon Feb 23 21:33:21 UTC 2026


> Color.web(string, double) parses a color string by creating substrings of the input. These string allocations can be removed.
> 
> CSS numbers are parsed by `CssNumberParser`, which parses CSS-compliant numbers using Lemire's algorithm.
> 
> There are no new tests for the `Color` class, since the existing tests already cover all relevant code paths.

Michael Strauß has updated the pull request incrementally with one additional commit since the last revision:

  review comment

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

Changes:
  - all: https://git.openjdk.org/jfx/pull/2069/files
  - new: https://git.openjdk.org/jfx/pull/2069/files/fc036b8c..b74898cd

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jfx&pr=2069&range=15
 - incr: https://webrevs.openjdk.org/?repo=jfx&pr=2069&range=14-15

  Stats: 48 lines in 1 file changed: 24 ins; 22 del; 2 mod
  Patch: https://git.openjdk.org/jfx/pull/2069.diff
  Fetch: git fetch https://git.openjdk.org/jfx.git pull/2069/head:pull/2069

PR: https://git.openjdk.org/jfx/pull/2069


More information about the openjfx-dev mailing list