On Tue, Nov 4, 2008 at 7:45 AM, Rich Hickey <[EMAIL PROTECTED]> wrote:
> Hmm...
>
> Do you want:
>
> (max 1 2.1 4/5)
>
> to work?
>
> If so, you can't base it on Comparable, which generally only supports
> homogenous types.
>
> max, like >, is a numeric operation as it stands, for the above and
> speed reasons. If you want a general greatest/least based on
> Comparable (or better yet Clojure's compare), I'm not opposed, but it
> should probably be a different thing.
>
> Rich

I figured there might be some performance considerations, too. Would
you rather have max/min work with compare and max-num/min-num work
with numbers? That would maybe be more immediately evident. Or max/min
for numbers and greatest/least for comparables?

I like the idea of a more general Comparable version, but I can also
see the need for an optimized numeric version.


Paul

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To post to this group, send email to clojure@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/clojure?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to