RFR JDK-8209553: ExceptionInInitializerError can have a default detail message if the cause is given
jason_mehrens at hotmail.com
Thu Sep 13 22:26:42 UTC 2018
Looks good. I like the change of making setCause final.
From: mandy chung <mandy.chung at oracle.com>
Sent: Thursday, September 13, 2018 3:50 PM
To: Jason Mehrens; joe darcy; Peter Levart
Subject: Re: RFR JDK-8209553: ExceptionInInitializerError can have a default detail message if the cause is given
On 9/13/18 12:47 PM, Jason Mehrens wrote:
Like in previous patches, I advocated for using 'super.getCause()' in writeObject to avoid any subclass hooking into serialization. I even lean towards the legacy getXXX methods call super.getCause too so they are compatible with previous behavior.
Good point. It's probably rare to have subclasses of these types and overrides getCause method. In any case I agree it should call super.getCause for correctness. I also added a test case with overridden getCause method.
Does Throwable.setCause need a more obscure name encase there are subclasses of throwable in the wild with that signature?
This is package-private method.
EIIE has double semi-colon in the constructor and PAE has a random javadoc modification.
Good catch! It's cleaned up.
More information about the core-libs-dev