From: "François Pottier" <francois.pottier@inria.fr>
To: "Christoph Höger" <christoph.hoeger@tu-berlin.de>,
"caml users" <caml-list@inria.fr>
Subject: Re: [Caml-list] ppx_deriving question: deferring code generation?
Date: Wed, 4 Jan 2017 16:58:00 +0100 [thread overview]
Message-ID: <557e41cc-0805-997b-6ec9-8da7c3cc3352@inria.fr> (raw)
In-Reply-To: <c3c306e1-8171-a24f-3d05-5f22792a7d55@tu-berlin.de>
Dear Christoph,
On 04/01/2017 14:53, Christoph Höger wrote:
> Just out of curiosity, what does "vistors" do? If it resembles the usual
> Visitor Pattern you might find my ppx_deriving_morphism useful:
Interesting -- thanks for your reply. Although I did search for related ppx
plugins, I did not find yours.
At a glance, my plugin seems broadly analogous to yours; it also generates
"iter" (= "fold") and "map" visitors. It differs superficially in that
it uses
OCaml objects instead of OCaml records. It differs perhaps more deeply
in that
the generated code can have more varied types, beyond your "map_routine" and
"fold_routine". But I need to experiment more, and write more documentation,
before making a public release.
--
François Pottier
francois.pottier@inria.fr
http://gallium.inria.fr/~fpottier/
next prev parent reply other threads:[~2017-01-04 15:58 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-04 13:08 François Pottier
2017-01-04 13:49 ` Gabriel Scherer
2017-01-04 15:37 ` François Pottier
2017-01-04 13:53 ` Christoph Höger
2017-01-04 15:58 ` François Pottier [this message]
2017-01-04 15:20 ` Alain Frisch
2017-01-04 16:04 ` François Pottier
2017-01-06 22:58 ` whitequark
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=557e41cc-0805-997b-6ec9-8da7c3cc3352@inria.fr \
--to=francois.pottier@inria.fr \
--cc=caml-list@inria.fr \
--cc=christoph.hoeger@tu-berlin.de \
/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