RFR (L, final): 8218626: Add detailed message to NullPointerException describing what is null.

Lindenmaier, Goetz goetz.lindenmaier at sap.com
Tue Sep 24 14:47:38 UTC 2019


Thanks!

Best regards,
  Goetz

> -----Original Message-----
> From: Roger Riggs <Roger.Riggs at oracle.com>
> Sent: Dienstag, 24. September 2019 15:54
> To: Lindenmaier, Goetz <goetz.lindenmaier at sap.com>; Hotspot dev runtime
> <hotspot-runtime-dev at openjdk.java.net>; Java Core Libs <core-libs-
> dev at openjdk.java.net>
> Subject: Re: RFR (L, final): 8218626: Add detailed message to
> NullPointerException describing what is null.
> 
> Hi Goetz,
> 
> Looks good.
> Count me as a (java) Reviewer.
> 
> Thanks, Roger
> 
> 
> On 9/24/19 4:13 AM, Lindenmaier, Goetz wrote:
> 
> 
> 	Hi Roger,
> 
> 	thanks for improving the text!  Good point to add
> 	@implNote.
> 	This webrev includes the fixed comments:
> 	http://cr.openjdk.java.net/~goetz/wr19/8218628-exMsg-NPE/19/
> 	Is it ok to add you as reviewer (for the java.base part)?
> 
> 	Best regards,
> 	  Goetz.
> 
> 
> 
> 		-----Original Message-----
> 		From: Roger Riggs <Roger.Riggs at oracle.com>
> <mailto:Roger.Riggs at oracle.com>
> 		Sent: Montag, 23. September 2019 17:30
> 		To: Lindenmaier, Goetz <goetz.lindenmaier at sap.com>
> <mailto:goetz.lindenmaier at sap.com> ; Hotspot dev runtime
> 		<hotspot-runtime-dev at openjdk.java.net> <mailto:hotspot-
> runtime-dev at openjdk.java.net> ; Java Core Libs <core-libs-
> 		dev at openjdk.java.net <mailto:dev at openjdk.java.net> >
> 		Subject: Re: RFR (L, final): 8218626: Add detailed message to
> 		NullPointerException describing what is null.
> 
> 		Hi Goetz,
> 
> 		A bit of wordsmithing on the javadoc of
> NullPointerException.getMessage
> 		and separating out the implementation specific description to
> an @implNote
> 
> 
> 		75:
> 		    /**
> 		     * Returns the detail message string of this throwable.
> 		     * <p>
> 		     * If a non-null message was supplied in a constructor it is
> returned.
> 		     * Otherwise, an implementation specific message or {@code
> null} is
> 		returned.
> 		     * @ImplNote
> 		     * If no explicit message was passed to the constructor, and
> as
> 		     * long as certain internal information is available, a verbose
> 		     * description of the null reference is returned.
> 		     * The internal information is not available in deserialized
> 		NullPointerExceptions.
> 		     *
> 		     * @return the detail message string, which may be {@code
> null}.
> 		     *
> 		94-97: The comment on the getExtendedNPEMessage should
> use the normal
> 		/**... */ syntax.
> 
> 		Thanks, Roger
> 
> 
> 
> 
> 		On 9/17/19 10:18 AM, Lindenmaier, Goetz wrote:
> 
> 
> 			@core-libs experts, I would appreciate comments on
> the changes
> 			to NullPointerException.java, especially wrt. the
> Javadoc comment.
> 			The change there is S.
> 
> 			Best regards,
> 			  Goetz.
> 
> 
> 				-----Original Message-----
> 				From: Lindenmaier, Goetz
> 				Sent: Dienstag, 10. September 2019 11:48
> 				To: 'Hotspot dev runtime' <hotspot-runtime-
> 		dev at openjdk.java.net <mailto:dev at openjdk.java.net> >
> <mailto:hotspot-runtime-dev at openjdk.java.net> <mailto:hotspot-runtime-
> dev at openjdk.java.net>  ; Java
> 		Core
> 				Libs <core-libs-dev at openjdk.java.net>
> <mailto:core-libs-dev at openjdk.java.net>  <mailto:core-libs-
> 		dev at openjdk.java.net> <mailto:core-libs-
> dev at openjdk.java.net>
> 				Subject: RFR (L, final): 8218626: Add detailed
> message to
> 		NullPointerException
> 				describing what is null.
> 
> 				Hi,
> 
> 
> 
> 				this is the implementation of JEP 358: Helpful
> 		NullPointerExceptions.
> 
> 
> 
> 				The JEP is in status "Candidate". Coleen (many,
> many thanks!)
> 		ran
> 
> 				it through the Oracle-internal processes.  Now I
> please need
> 		final reviews
> 
> 				for this change so that I can propose it to
> target jdk 14.
> 
> 
> 
> 				JEP:
> https://bugs.openjdk.java.net/browse/JDK-8220715
> 
> 				Enhancement:
> https://bugs.openjdk.java.net/browse/JDK-
> 		8218628
> 
> 				webrev:
> http://cr.openjdk.java.net/~goetz/wr19/8218628-
> 		exMsg-NPE/16/
> 
> 
> 
> 				The change ran through a lot of testing, all
> jtreg and jck tests to
> 		name
> 
> 				only some. The webrev points to patch
> 
> 
> 	http://cr.openjdk.java.net/~goetz/wr19/8218628-exMsg-
> 				NPE/16/enable_NPE_message.patch
> 
> 				that enables the change by default,  which was
> useful for
> 		testing to
> 
> 				assure the code is used in the tests.
> 
> 				I just pushed the change to jdk/submit once
> more.
> 
> 
> 
> 				Please review.
> 
> 
> 
> 				Thanks!
> 
> 				  Goetz.
> 
> 
> 
> 
> 
> 



More information about the core-libs-dev mailing list