RFR: 8274075: Fix miscellaneous typos in java.base [v2]
prappo at openjdk.java.net
Tue Sep 21 17:13:28 UTC 2021
On Tue, 21 Sep 2021 16:56:03 GMT, Lance Andersen <lancea at openjdk.org> wrote:
>> src/java.base/share/classes/java/lang/Throwable.java line 68:
>>> 66: * Further, doing so would tie the API of the upper layer to the details of
>>> 67: * its implementation, assuming the lower layer's exception was a checked
>>> 68: * exception. Throwing a "wrapping exception" (i.e., an exception containing a
>> Are we sure that this should be "wrapping" and not "wrapped?" See also for example `java.security.cert.CertPathValidatorException.`
> It does seem a bit strange to say "Throwing a wrapping...."
If we have two exceptions A and B, such that B is the cause of A, then A is the wrapping exception (the one that wraps or the wrapper) and B is the wrapped exception (the one that is being wrapped or the wrappee).
I noticed that the sentence was conflicting: it started with the "wrapped" exception, but then in the "i.e." commentary in parentheses proceeded with the wrappee exception. To resolve that conflict, I proposed to rephrase the first part of that sentence. FWIW, my original suggestion elsewhere was to use "wrapper".
More information about the core-libs-dev