Re: [Scheme-reports] R7RS-large comparators John Cowan (12 Jul 2013 15:52 UTC)
Re: [Scheme-reports] R7RS-large comparators Kevin Wortman (15 Jul 2013 23:32 UTC)
Re: [Scheme-reports] R7RS-large comparators John Cowan (16 Jul 2013 04:35 UTC)
Re: [Scheme-reports] R7RS-large comparators Kevin Wortman (17 Jul 2013 19:00 UTC)
Re: [Scheme-reports] R7RS-large comparators Alexey Radul (18 Jul 2013 17:33 UTC)
Re: [Scheme-reports] R7RS-large comparators Kevin Wortman (19 Jul 2013 22:44 UTC)

Re: [Scheme-reports] R7RS-large comparators John Cowan 16 Jul 2013 04:35 UTC

Kevin Wortman scripsit:

> I think that a comparator returns one of three conceptual results:
> less-than, equal, or greater-than. There is a long history of using the
> integer values -1, 0, and +1 to represent those concepts. However these
> concepts are not really integers, and using integers to represent them
> may be a red herring. I think Haskell gets this right by yielding one of
> the algebraic constructors LT, EQ, or GT (
> http://www.haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#t:Ordering
> ).
>
> Perhaps Scheme comparators should return one of the symbols 'less 'equal
> or 'greater ? Or perhaps we should standardize enumerated types first
> and then have comparators return an enum object.

Please read the justification at
<http://srfi.schemers.org/srfi-67/srfi-67.html#node_sec_Temp_15>.

--
In politics, obedience and support      John Cowan <cowan@ccil.org>
are the same thing.  --Hannah Arendt    http://www.ccil.org/~cowan

_______________________________________________
Scheme-reports mailing list
Scheme-reports@scheme-reports.org
http://lists.scheme-reports.org/cgi-bin/mailman/listinfo/scheme-reports