RFR: 8138614: (spec str) StringBuffer and StringBuilder methods improperly require "new" String to be returned [v3]

Stuart Marks smarks at openjdk.org
Tue Feb 25 00:54:24 UTC 2025


> A couple adjustments to the specs for four methods of StringBuilder and StringBuffer so that they no longer require new Strings to be created, just a String with the right contents. No implementation changes. Note that the actual specs (and implementations) are actually in AbstractStringBuilder, and they're inherited by StringBuilder and StringBuffer.

Stuart Marks has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains three additional commits since the last revision:

 - Merge branch 'master' into JDK-8138614-relax-new-string-requirement
 - A tiny bit of wordsmithing.
 - 8138614: Relax StringBuilder/StringBuffer requirement to create new Strings

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/23599/files
  - new: https://git.openjdk.org/jdk/pull/23599/files/0633c022..f4aed5d6

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=23599&range=02
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=23599&range=01-02

  Stats: 25683 lines in 1009 files changed: 16035 ins; 6300 del; 3348 mod
  Patch: https://git.openjdk.org/jdk/pull/23599.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/23599/head:pull/23599

PR: https://git.openjdk.org/jdk/pull/23599


More information about the core-libs-dev mailing list