caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Peter Zotov <whitequark@whitequark.org>
To: "Daniel Bünzli" <daniel.buenzli@erratique.ch>
Cc: Benjamin Canou <benjamin.canou@gmail.com>, caml-list@inria.fr
Subject: Re: [Caml-list] proposal for finding, loading and composing ppx preprocessors
Date: Fri, 11 Jul 2014 18:36:37 +0400	[thread overview]
Message-ID: <69c5d809b89ebdc663eb45a2b422718c@whitequark.org> (raw)
In-Reply-To: <1F6CA9F698BB4509800C3FD280CE0ACB@erratique.ch>

On 2014-07-11 18:21, Daniel Bünzli wrote:
> Le vendredi, 11 juillet 2014 à 14:31, Benjamin Canou a écrit :
>> What do you think ?
> If I understand correctly this is a ppx for selectively using ppxs
> over a file. Bonus points for the higher-order ppx.
> 
> Since apparently we have to deal with this crap until we actually get
> something decent for static meta programming in this language,
> wouldn't it be easier to just define a standard annotation as you
> suggest, and then have some kind of "ppxdep" tool that just spits you
> the flags you will have to put on the command line in order to be able
> to compile it ?

This would require extensive changes to buildsystems (or just to 
ocamldep;
that doesn't make it easier), which, as I understand, this proposal is 
aiming
to avoid.

Personally I don't see anything wrong with just supplying -package to
ocamlfind c invocation, directly, via _tags, via _oasis (and possibly
_tags too, for more finely grained control) or whatever build system are
you using.

Alain Frisch suggested that constant forking might slow down builds, and
suggested some kind of a frontend that would automatically link (not 
even
dynlink) a compound ppx to make builds faster, especially on Windows.

I wonder if we should just get rid of a Unix-like build pipeline 
entirely,
and just make a hybrid frontend-buildsystem that would use compiler-libs
and never execute an external OCaml process. This would make builds even
faster and it's the logical conclusion of Alain's suggestion.

-- 
Peter Zotov
sip:whitequark@sipnet.ru

  reply	other threads:[~2014-07-11 14:36 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-11 13:31 Benjamin Canou
2014-07-11 14:21 ` Daniel Bünzli
2014-07-11 14:36   ` Peter Zotov [this message]
2014-07-11 14:49     ` Daniel Bünzli
2014-07-11 14:55       ` Peter Zotov
2014-07-11 14:52     ` Mark Shinwell
2014-07-11 15:27     ` Anil Madhavapeddy
2014-07-11 15:35       ` Mark Shinwell
2014-07-11 14:55   ` Benjamin Canou
2014-07-11 15:23     ` Daniel Bünzli
2014-07-11 16:00       ` Benjamin Canou
2014-07-11 16:13 ` Alain Frisch
2014-07-15 13:59   ` Benjamin Canou
2014-07-15 15:56     ` Alain Frisch

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=69c5d809b89ebdc663eb45a2b422718c@whitequark.org \
    --to=whitequark@whitequark.org \
    --cc=benjamin.canou@gmail.com \
    --cc=caml-list@inria.fr \
    --cc=daniel.buenzli@erratique.ch \
    /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;
as well as URLs for NNTP newsgroup(s).