On 05/11/2025 23:10, Pavel Rappo wrote:
And also this, which is a bit contrived but valid nonetheless:

     } catch (InterruptedException e) { // good
         throw new InterruptedException();

     }

The good/bad table is fun. For completeness you can also add the case where someone restores the interrupt status and rethrows the InterruptedException (or throws a new InterruptedException). It would be strange to do this but no different to a double whammy where two parts of the system are requesting you to cancel/finish-up around the same time.

-Alan

Reply via email to