RFR [16/java.xml] 8246816: XMLGregorianCalendar.hashCode() produces far too many identical hashes

naoto.sato at oracle.com naoto.sato at oracle.com
Thu Aug 6 01:13:58 UTC 2020


Hi Joe,

For the consistency with equals(), just wondering if the sub-second 
element should be obtained with getFractionalSecond() instead of 
getMillisecond(), as the equals() subsequently calls it in 
internalCompare() method. Also should it call getEonAndYear() 
appropriately for the year?

Naoto

On 8/5/20 4:37 PM, Joe Wang wrote:
> Hello,
> 
> Please review a fix for the hashCode generation.
> 
> JBS: https://bugs.openjdk.java.net/browse/JDK-8246816
> 
> webrev: http://cr.openjdk.java.net/~joehw/jdk16/8246816/webrev/
> 
> Thanks,
> Joe
> 


More information about the core-libs-dev mailing list