From: Dario Teixeira <darioteixeira@yahoo.com>
To: Leo White <lpw25@cam.ac.uk>
Cc: OCaml mailing-list <caml-list@inria.fr>
Subject: Re: [Caml-list] Locally abstract type with type parameters
Date: Tue, 26 Aug 2014 07:33:01 -0700 [thread overview]
Message-ID: <1409063581.90232.YahooMailNeo@web121702.mail.ne1.yahoo.com> (raw)
In-Reply-To: <8738cl6dw1.fsf@study.localdomain>
Hi,
> This function relies on higher-kinded polymorphism (i.e. it is
> polymorphic in type `u` which has type parameters). Since OCaml's core
> language does not provide direct support for higher-kinded polymorphism
> the usual solution is to make `actually_process` into a functor. A
> possible alternative solution, which may suit your use case, is outlined
> in the paper "Lightweight higher-kinded polymorphism" [1] using the
> "higher" library available on OPAM.
Ah... It makes sense now -- thanks for the explanation!
I ended up making actually_process also part of a functor.
Still, it's nice to know about this limitation and of
the alternative offered by your Higher library.
Best regards,
Dario Teixeira
prev parent reply other threads:[~2014-08-26 14:33 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-20 18:38 Dario Teixeira
2014-08-21 1:19 ` John F. Carr
2014-08-22 2:23 ` Benjamin Greenman
2014-08-24 16:39 ` Leo White
2014-08-26 14:33 ` Dario Teixeira [this message]
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=1409063581.90232.YahooMailNeo@web121702.mail.ne1.yahoo.com \
--to=darioteixeira@yahoo.com \
--cc=caml-list@inria.fr \
--cc=lpw25@cam.ac.uk \
/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