timsort (original) (raw)

Martin Buchholz martinrb at google.com
Tue Jun 30 18:08:37 UTC 2009


On Tue, Jun 30, 2009 at 10:03, Jason Mehrens <jason_mehrens at hotmail.com>wrote:

Martin,

Regarding this IAE issue, another approach might be given non null Comparator 'c': if(c.getClass().desiredAssertionStatus()) { throw new AssertionError("....."); } Then there is no compatibility problem,no need to add a new switch to the JDK, and the coder gets smacked with an error.

... if assertions are turned on (which happens far too rarely)

But still an interesting idea - I had not seen it before. I wonder what Josh thinks.

Martin -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.openjdk.java.net/pipermail/core-libs-dev/attachments/20090630/90c1f139/attachment.html>



More information about the core-libs-dev mailing list