From: Damien Doligez <damien.doligez@inria.fr>
To: caml-list@inria.fr
Subject: Re: [Caml-list] Sorting
Date: Wed, 31 Oct 2001 14:42:22 +0100 (MET) [thread overview]
Message-ID: <200110311342.OAA0000020573@beaune.inria.fr> (raw)
>From: "Marcin 'Qrczak' Kowalczyk" <qrczak@knm.org.pl>
>Sort.array : order:('a -> 'a -> bool) -> 'a array -> unit
>Sort.list : order:('a -> 'a -> bool) -> 'a list -> 'a list
Old functions, obsolescent.
>Array.sort : cmp:('a -> 'a -> int) -> 'a array -> unit
>List.sort : cmp:('a -> 'a -> int) -> 'a list -> 'a list
New functions.
>What are advantages and disadvantages in parametrizing either by '<'
>or by the 3-way comparison?
It's better because it is more modern :-)
Seriously, the 3-way comparison is more consistent with the
definition of Map.OrderedType.
-- Damien
-------------------
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
next reply other threads:[~2001-10-31 13:42 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-10-31 13:42 Damien Doligez [this message]
2001-11-02 14:38 ` Pierre Weis
-- strict thread matches above, loose matches on Subject: below --
2001-11-02 15:10 Krishnaswami, Neel
2001-10-31 7:54 Marcin 'Qrczak' Kowalczyk
2001-11-05 9:22 ` Xavier Leroy
2001-11-05 12:26 ` jeanmarc.eber
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200110311342.OAA0000020573@beaune.inria.fr \
--to=damien.doligez@inria.fr \
--cc=caml-list@inria.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox