bug-classpath
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug classpath/30061] Comparator interface arguments get reversed


From: dwhire at yahoo dot com
Subject: [Bug classpath/30061] Comparator interface arguments get reversed
Date: 6 Dec 2006 07:21:11 -0000


------- Comment #4 from dwhire at yahoo dot com  2006-12-06 07:21 -------
(In reply to comment #3)
> If I understand this bug correctly, you are saying that Classpath's
> binarySearch implementation is calling your Comparator with the arguments
> ordered differently than you expect. From your test case it also sounds like
> you are expecting the first argument to be of one type, and the second another
> type. This is not guaranteed, in fact requiring that will break the contract 
> of
> Comparator.compare.
> It's perfectly valid for us to order our arguments to compare() that way. Your
> Comparator implementation is wrong.


-- 

dwhire at yahoo dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |UNCONFIRMED
         Resolution|INVALID                     |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30061





reply via email to

[Prev in Thread] Current Thread [Next in Thread]