...@yquem.inria.fr] On Behalf Of m...@proof-technologies.com
Sent: 10 November 2010 07:00
To: ymin...@gmail.com; ar...@noblesamurai.com
Cc: caml-l...@inria.fr
Subject: Re: [Caml-list] Infix function composition operator
on 10/11/10 3:45 AM, ymin...@gmail.com wrote:
This is probably a minority
] Infix function composition operator
on 10/11/10 3:45 AM, ymin...@gmail.com wrote:
This is probably a minority opinion, but I have written and read
quite a
lot
of OCaml code over the years, and I've seen surprisingly few
effective
uses
of the composition operator. Somehow, I usually
On 11/09/2010 09:19 PM, Arlen Christian Mart Cuss wrote:
Hi all,
I know this was asked at least 12 years ago[1], but is there any
consensus or reason for there not being a compose function in standard
OCaml, nor an infix operator?
At the moment I tend to let compose or let (-) f g x = f
On 10 Nov 2010, at 4:45, Yaron Minsky wrote:
let ( |! ) x f = f x
This is the same as F#'s pipe operator (|) which I find extremely useful
because with it code reads the way it works, not backwards:
2 | tenfold | add 1 | double = 42
(ok, this is a ridiculous example, but you get the point).
...@inria.fr
Subject: Re: [Caml-list] Infix function composition operator
on 10/11/10 3:45 AM, ymin...@gmail.com wrote:
This is probably a minority opinion, but I have written and read
quite a
lot
of OCaml code over the years, and I've seen surprisingly few
effective
uses
of the composition
...@inria.fr
Subject: Re: [Caml-list] Infix function composition operator
So how does value restriction affect things here? (excuse my lack of
knowledge)
One thing about using a pipeline like this is that it relies on '|'
being
left-associative (which it is due to OCaml's convention
.
Cheers,
Jon.
-Original Message-
From: m...@proof-technologies.com [mailto:m...@proof-technologies.com]
Sent: 10 November 2010 13:44
To: jonathandeanhar...@googlemail.com; ymin...@gmail.com;
ar...@noblesamurai.com
Cc: caml-l...@inria.fr
Subject: Re: [Caml-list] Infix function
To: jonathandeanhar...@googlemail.com; ymin...@gmail.com;
ar...@noblesamurai.com
Cc: caml-l...@inria.fr
Subject: Re: [Caml-list] Infix function composition operator
So how does value restriction affect things here? (excuse my lack of
knowledge)
One thing about using a pipeline like
Of Stephan Tolksdorf
Sent: 10 November 2010 16:11
To: caml-l...@inria.fr
Subject: Re: [Caml-list] Infix function composition operator
On Wed, Nov 10, 2010 at 14:13 -, Jon Harrop wrote:
However, I don't see it as a useful advantage in practice because
parser combinators are so tedious
-
From: caml-list-boun...@yquem.inria.fr [mailto:caml-list-
boun...@yquem.inria.fr] On Behalf Of Stephan Tolksdorf
Sent: 10 November 2010 16:11
To: caml-l...@inria.fr
Subject: Re: [Caml-list] Infix function composition operator
On Wed, Nov 10, 2010 at 14:13 -, Jon Harrop wrote:
However, I
Hi all,
I know this was asked at least 12 years ago[1], but is there any
consensus or reason for there not being a compose function in standard
OCaml, nor an infix operator?
At the moment I tend to let compose or let (-) f g x = f (g x),
but I wish I didn't have to!
Thanks,
Arlen
[1]
This is probably a minority opinion, but I have written and read quite a lot
of OCaml code over the years, and I've seen surprisingly few effective uses
of the composition operator. Somehow, I usually find that code that avoids
it is simpler and easier to read.
I'm not averse to infix operators.
Hi Yaron,
On Tue, 2010-11-09 at 22:45 -0500, Yaron Minsky wrote:
This is probably a minority opinion, but I have written and read quite
a lot of OCaml code over the years, and I've seen surprisingly few
effective uses of the composition operator. Somehow, I usually find
that code that avoids
on 10/11/10 3:45 AM, ymin...@gmail.com wrote:
This is probably a minority opinion, but I have written and read quite a
lot
of OCaml code over the years, and I've seen surprisingly few effective
uses
of the composition operator. Somehow, I usually find that code that
avoids
it is simpler and
14 matches
Mail list logo