Comparators.reverseOrder issues

Remi Forax forax at
Mon Oct 29 07:08:32 PDT 2012

On 10/29/2012 12:10 PM, Paul Sandoz wrote:
> Hi Georgiy,
> Brian fixed 1) recently:
> Although arguably that could break compatibility with existing source and implementations that somehow worked around the CCE.
> For 2) i am not sure what can be done, i think we are stuck with it.

For 2), I think reverseOrder(null) should throw a NPE, if the comparator 
is null.

Note that now that we have default method, reverseOrder() should not be 
declared in Comparators
but should be a default method of Comparator.

Moreover when the compiler will accept to declare static methods in 
(I've not tested if it is already Ok) the classes Comparators, 
Predicates etc. should be removed
and all the implementations should be moved in the corresponding interfaces.

> Paul.


> On Oct 29, 2012, at 11:31 AM, Georgiy Rakov <georgiy.rakov at> wrote:
>> Hello colleagues,
>> could you please give your thoughts and comments. Do you consider it
>> worth taking into account?
>> Thanks, Georgiy.

More information about the lambda-dev mailing list