On Sep 8, 2009, at 2:14 AM, Timothy Pratley wrote:

According to the docstring compare returns -1, 0 or 1:
user=> (compare \b \g)
-5

We could fix the doc along the lines of:

"Comparator. Returns a negative number, zero, or a positive number when x is logically 'less than', 'equal to', or 'greater than' y. Same as Java x.compareTo(y) except it also works for nil, and compares numbers and collections in a type-independent manner. x must implement Comparable"

or fix the implementation to conform to the current doc.

My current thought is that we should fix the implementation and make a minor mod to the doc to replace "Same as" with something like "Works like" because compareTo only guarantees the sign of the return value.

Other thoughts?

--Steve

Attachment: smime.p7s
Description: S/MIME cryptographic signature

Reply via email to