RFR: 8355065: ConcurrentModificationException in RichDiagnosticFormatter [v3]

Vicente Romero vromero at openjdk.org
Mon Apr 28 16:57:45 UTC 2025


On Mon, 21 Apr 2025 18:20:22 GMT, Liam Miller-Cushon <cushon at openjdk.org> wrote:

>> Hi, please consider this fix for [JDK-8355065](https://bugs.openjdk.org/browse/JDK-8355065). RichDiagnosticFormatter is comparing type variables by their `toString` representation, and in this example the comparison fails due to type annotations. Replacing a call to `stripMetadataIfNeeded` with `stripMetadata` allows the comparison to succeed, and is consistent with the approach used in other parts of RichDiagnosticFormatter (e.g. for [the fix for JDK-8144580](https://github.com/openjdk/jdk/commit/570883e4dc5f769e17b3fcd8f2bbeb369dfe3a5d)).
>
> Liam Miller-Cushon has updated the pull request incrementally with one additional commit since the last revision:
> 
>   EnumMap

looks sensible

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

Marked as reviewed by vromero (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/24769#pullrequestreview-2800024191


More information about the compiler-dev mailing list