I was surprised when I noticed the following behavior:
Objective Caml version 3.11.2
# compare == compare;;
- : bool = false
# let f = compare;;
val f : 'a -> 'a -> int =
# f == compare;;
- : bool = false
# f == f;;
- : bool = true
# let g = compare;;
val g : 'a -> 'a -> int =
# f == g
On Sep 7, 2010, at 6:00 AM, caml-list-requ...@yquem.inria.fr wrote:
Date: Tue, 7 Sep 2010 06:36:35 +0200
From: Basile Starynkevitch
Subject: Re: [Caml-list] interfacing Ocaml with Mathematica
To: zaid al-zobaidi
Cc: caml-list@yquem.inria.fr
Message-ID: <20100907063635.f2e4de47.bas...@starynkev
On Jan 19, 2010, at 1:28 PM, David Allsopp wrote:
Goswin von Brederlow wrote:
# 2147483648l;;
- : int32 = -2147483648l
Isn't that documented properly? I think in the docs I saw at least
that
ocaml will silently overflow ints.
Arithmetic operations are allowed to overflow silently but at
On Oct 21, 2009, at 8:29 AM, Yoonseok Ko wrote:
I'm looking for a C preprocessing language parser with OCAML
interface.
I was recently looking for such a tool myself, and I came across the
link below mentioning Yacfe, from about a year ago. Unfortunately, it
seems that the link provided t
On Mon, 2009-08-10 at 15:36 +0200, Martin Jambon wrote:
> Elnatan Reisner wrote:
> > On Sun, 2009-08-09 at 21:09 +0200, Alain Frisch wrote:
> >> Note that (=) sometimes terminates for cylic values.
> >>
> >> # type t = A of t | B of t;;
> >> type t =
On Sun, 2009-08-09 at 21:09 +0200, Alain Frisch wrote:
> On 8/9/2009 8:56 PM, Elnatan Reisner wrote:
> > My other issue is that the description of (==) for mutable structures
> > doesn't specify that it is symmetric; reading the documentation
> > literally only implies th
Continuing this conversation about equality...
On Aug 9, 2009, at 9:20 AM, David Allsopp wrote:
Ivan Chollet wrote:
I would have thought physical equality implies structural equality,
but it
doesn't seem like it.
Can you please explain to me what’s wrong there?
"It does" - but only with t
Is there something that can complete this analogy:
(=) is to (==) as Pervasives.compare is to ___?
That is, is there a polymorphic total ordering with respect to *physical*
entities, rather than to their structure?
I'm afraid of getting into trouble with Obj.magic, but what would this do:
let f (
On Wed, 2009-07-08 at 14:54 -0400, Eric Cooper wrote:
> On Wed, Jul 08, 2009 at 08:35:27PM +0200, Bruno Daniel wrote:
> > How is it ensured that I get a <> b for a and b created as
> > polymorphic variants from two different identifiers? Will pattern
> > matching give wrong results if I accidentall
Do the polymorphic ordering functions -- (<), (>), etc. -- correspond
to the numerical ordering for Int64s and Int32s? I assume so, but I
didn't see this specified anywhere.
If the answer is 'yes', is there a reason I should prefer
Int64.compare n1 n2 < 0
to
n1 < n2
? If there's no specific r
10 matches
Mail list logo