From: Paolo Donadeo <p.donadeo@gmail.com>
To: OCaml mailing list <caml-list@inria.fr>
Subject: Re: [Caml-list] Re: Syntax extensions without Camlp4
Date: Mon, 28 May 2012 10:17:57 +0200 [thread overview]
Message-ID: <CAPzAKVBEmvvd8Tr5Axm4Ay5BjFReL8jz+k3OTsp1wDgxsqNtpA@mail.gmail.com> (raw)
In-Reply-To: <D521C447A36B43D4B39B88CDC2A55852@erratique.ch>
[-- Attachment #1: Type: text/plain, Size: 1281 bytes --]
On Sun, May 27, 2012 at 8:04 PM, Daniel Bünzli <daniel.buenzli@erratique.ch>
wrote:
> camlp4 is one of the (conceptually) ugliest component of the OCaml system.
> Pre-processors in general are a wrong solution to a real problem;
> meta-programming facilities should be part of the core language and
> play by its scoping rules, they should not be layered on top of it.
I subscribe. At the present state OCaml, which is otherwise an almost
perfect language, needs some tool, I mean any tool, to accomplish
*simple*metaprogramming tasks.
Camlp4, which could be an awful or an amazing tool, is known by an inner
circle of wizards, and the activity of creating a new syntax extension is
a... sorcery for initiates only.
My experience of average and maybe dumb OCaml programmer: last week I tried
to write a simple ORM, something resembling the Django
ORM<https://docs.djangoproject.com/en/1.4/topics/db/models/>and, after
some (random) trial and error, I simply gave up. I have started
thinking to use cpp as a preprocessor to create very simple "templates",
which is awful, but the only alternative I have is to define the ORM
classes in something like XML, parse them and generate OCaml sources.
It's definitively a lose-lose game.
--
*Paolo*
[-- Attachment #2: Type: text/html, Size: 1572 bytes --]
next prev parent reply other threads:[~2012-05-28 8:18 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-27 15:06 [Caml-list] " Alexandre Pilkiewicz
2012-05-27 16:53 ` [Caml-list] " Hongbo Zhang
2012-05-27 18:04 ` Daniel Bünzli
2012-05-27 18:18 ` Hongbo Zhang
2012-05-27 19:01 ` Daniel Bünzli
2012-05-27 22:43 ` Wojciech Meyer
2012-05-28 9:35 ` Daniel Bünzli
2012-05-28 9:59 ` Gabriel Scherer
2012-05-30 14:45 ` Hongbo Zhang
2012-05-28 11:17 ` Wojciech Meyer
2012-05-28 15:52 ` Jeffrey Scofield
2012-05-27 18:19 ` Hongbo Zhang
2012-05-28 8:17 ` Paolo Donadeo [this message]
2012-05-30 12:41 ` Alain Frisch
2012-05-30 13:18 ` Markus Mottl
2012-05-30 13:37 ` Dan Bensen
2012-05-30 14:16 ` Hongbo Zhang
2012-05-30 14:23 ` Paolo Donadeo
[not found] ` <20120531081913.GA26742@securactive.lan>
2012-05-31 12:26 ` Paolo Donadeo
2012-05-31 12:38 ` Anil Madhavapeddy
2012-05-31 12:40 ` Anil Madhavapeddy
2012-05-31 12:46 ` Yaron Minsky
2012-05-31 12:47 ` Gabriel Scherer
2012-05-31 22:08 ` Paolo Donadeo
2012-05-30 14:14 ` Hongbo Zhang
2012-05-31 12:59 ` Alain Frisch
2012-05-31 13:21 ` Dmitry Grebeniuk
2012-05-31 14:30 ` Daniel Bünzli
2012-05-31 16:01 ` bob zhang
2012-05-31 17:28 ` Gerd Stolpmann
2012-05-31 18:03 ` Wojciech Meyer
2012-05-31 18:32 ` Gerd Stolpmann
2012-05-31 18:32 ` Hongbo Zhang
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=CAPzAKVBEmvvd8Tr5Axm4Ay5BjFReL8jz+k3OTsp1wDgxsqNtpA@mail.gmail.com \
--to=p.donadeo@gmail.com \
--cc=caml-list@inria.fr \
/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