New protocol for disabling exception suppression

Neal Gafter neal at gafter.com
Sun Apr 3 13:11:13 PDT 2011


ArrayList.add is used to add suppressed exceptions but that is not thread-safe.

On Sunday, April 3, 2011, Rémi Forax <forax at univ-mlv.fr> wrote:
> On 04/03/2011 05:43 PM, Neal Gafter wrote:
>> The mechanism for adding suppressed exceptions does not appear to be
>> thread-safe.
>
> Why do you claim that ?
> It's thread-safe like initCause is thread-safe.
>
>> Since this introduces a way in which exceptions used to
>> be thread-safe but no longer are thread-safe, this might require
>> significant nonlocal refactoring of existing code in order to use the
>> new try-with-resources statement.
>
> Exceptions are still thread-safe.
>
> Rémi
>
>
>



More information about the coin-dev mailing list