Code Review Request for 4533691 (add Collections.EMPTY_SORTED_SET)

Jason Mehrens jason_mehrens at
Sat Oct 29 16:03:52 UTC 2011

I would get rid of the public static field so this class can be lazy loaded like EmptyIterator and ReverseComparator (in 1.7).  What about accepting a comparator as an argument?  I bet the bug report is predates 1.6, so maybe you should target NavigableSet instead of sorted set.

> Date: Fri, 28 Oct 2011 15:44:25 -0700
> From: darryl.mocek at
> To: core-libs-dev at
> Subject: Code Review Request for 4533691 (add Collections.EMPTY_SORTED_SET)
> Hello. Please review this patch to add empty sorted set to the 
> Collections class. Test case provided.
> Webrev:
> Additional Notes to Reviewers:
> The sets resulting from tailSet() headSet() and subSet() normally 
> include the range which was used to create them. Using these methods 
> with emptySortedSet() does not currently set a range on the resulting sets.
> Thanks,
> Darryl

More information about the core-libs-dev mailing list