caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* [Caml-list] META file standards for ppx extensions
@ 2015-04-08 18:20 Dario Teixeira
  2015-04-08 18:59 ` Drup
  0 siblings, 1 reply; 30+ messages in thread
From: Dario Teixeira @ 2015-04-08 18:20 UTC (permalink / raw)
  To: caml-list

Hi,

I think we need to standardise the naming and structure of META
files associated with ppx extensions.  Case in point: I was hoping
to start using sedlex instead of ulex, because the latter has been
deprecated for a while now and all the cool kids are switching to
the former.  However, sedlex currently ships with a broken META
file that severely restricts its usefulness [1].  Therefore, in
order to avoid similar problems with other ppx extensions and to
foster some uniformity in the ecosystem, here's what I suggest:

a) Suppose you have a ppx extension called 'foobar' that relies
    on a runtime library foobar.cma (and native code counterparts,
    which I'll omit from now on).  The top-level declarations in
    foobar's META should reference foobar.cma, but should *not*
    include a ppx declaration.  The ppx declaration should be
    part of a 'ppx' sub-package.

b) If the ppx extension 'foobar' does not have a runtime library,
    then the top-level declarations in the META file should consist
    only of generic version and description information.  The actual
    ppx declaration should be part of a 'ppx' sub-package, as in a).

There is obviously an alternative approach where the ppx invocations
are located at the top-level and any potential runtime libraries
are moved into a 'lib' sub-package.  I prefer the approach outlined
above, however, as it makes ppx invocations explicit and follows the
'syntax' sub-package tradition from Camlp4's glory days.

Thoughts or suggestions?

Best regards,
Dario Teixeira

[1] https://github.com/alainfrisch/sedlex/issues/22


^ permalink raw reply	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2015-04-12  6:00 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-04-08 18:20 [Caml-list] META file standards for ppx extensions Dario Teixeira
2015-04-08 18:59 ` Drup
2015-04-08 19:59   ` Dario Teixeira
2015-04-08 20:37     ` Daniel Bünzli
2015-04-09 10:07       ` Dario Teixeira
2015-04-09 10:56     ` Gerd Stolpmann
2015-04-09 12:24       ` Dario Teixeira
2015-04-09 15:33         ` Daniel Bünzli
2015-04-09 16:45           ` Gerd Stolpmann
2015-04-09 17:27             ` Daniel Bünzli
2015-04-09 18:05               ` Daniel Bünzli
2015-04-09 22:26                 ` Gerd Stolpmann
2015-04-09 22:21               ` Gerd Stolpmann
2015-04-09 23:06                 ` Daniel Bünzli
2015-04-10  8:53                   ` François Bobot
2015-04-10  9:42                     ` Daniel Bünzli
2015-04-10 10:09                       ` Alain Frisch
2015-04-10 11:45                         ` Thomas Gazagnaire
2015-04-10 11:04                       ` François Bobot
2015-04-10 11:55                         ` Daniel Bünzli
2015-04-10 16:33                           ` François Bobot
2015-04-10 17:43                             ` Daniel Bünzli
2015-04-12  6:00                       ` Anil Madhavapeddy
2015-04-10 11:25                   ` Gerd Stolpmann
2015-04-10 11:55                     ` Daniel Bünzli
2015-04-09 15:45         ` Thomas Gazagnaire
2015-04-09 16:28           ` Dario Teixeira
2015-04-09 16:51             ` Gerd Stolpmann
2015-04-10 12:23         ` Daniel Bünzli
2015-04-10 14:55           ` Gerd Stolpmann

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).