From: Basile STARYNKEVITCH <basile@starynkevitch.net>
To: Daniel de Rauglaudre <daniel.de_rauglaudre@inria.fr>
Cc: caml-list@inria.fr
Subject: Re: [Caml-list] Again on pattern matching and strings
Date: Thu, 24 Oct 2002 15:16:24 +0200 [thread overview]
Message-ID: <15799.62120.815873.654039@hector.lesours> (raw)
In-Reply-To: <20021024145904.K12351@verdot.inria.fr>
>>>>> "Daniel" == Daniel de Rauglaudre <daniel.de_rauglaudre@inria.fr> writes:
Daniel> Hi, On Thu, Oct 24, 2002 at 11:50:46AM +0200, Stefano
Daniel> Zacchiroli wrote:
>> What about "DEFINE" / "UNDEF"?
Daniel> There is already a Camlp4 syntax extension "pa_ifdef.cmo"
Daniel> which adds "define" and "ifdef" (in lowercases). This is
Daniel> more for conditional compilation.
Some thoughts on these macro issues.
1. I think it is extremly important to add the ability to have
expression macros
pattern macros
compile time flags (ifdef) for conditional compilation
inside the same source file (also containing usual Ocaml code,
perhaps using these extensions).
2. There are cases where variadic macros could be useful. I know it is
tricky to implement them.
3. If it make Daniel's life easier, having different keywords to
define expression macros, pattern macros, flags, could be ok, eg
DEFEXPRMACRO DEFPATTERNMACRO
4. mixing macros and flags is important in my opinion. I mean that in
C it is usual to code
#ifdef WANT_DEBUG
#define DEBUGME(V) if (debugflag) printf("%d", V)
#else
#define DEBUGME(V) {}
#endif
I really would like compile flags & macros to be also mixable in
Ocaml
5. having the equivalent of __FILE__ and __LINE__ is very useful
Above all, I really appreciate Camlp4 and do hope it will continue to
grow!
Regards.
--
Basile STARYNKEVITCH http://starynkevitch.net/Basile/
email: basile<at>starynkevitch<dot>net
alias: basile<at>tunes<dot>org
8, rue de la Faïencerie, 92340 Bourg La Reine, France
-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
next prev parent reply other threads:[~2002-10-24 19:40 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-10-23 23:47 Alessandro Baretta
2002-10-23 23:46 ` Alexander V.Voinov
2002-10-23 23:57 ` Stefano Zacchiroli
2002-10-24 7:10 ` Alessandro Baretta
2002-10-24 7:38 ` Stefano Zacchiroli
2002-10-24 8:01 ` Jacques Garrigue
2002-10-24 12:38 ` Alessandro Baretta
2002-10-24 13:24 ` Luc Maranget
2002-10-24 15:13 ` Alessandro Baretta
2002-10-24 16:26 ` Sven Luther
2002-10-25 8:40 ` Luc Maranget
2002-10-24 4:11 ` Christopher Quinn
[not found] ` <15799.14325.887770.501722@karryall.dnsalias.org>
2002-10-24 7:43 ` Alessandro Baretta
2002-10-24 8:51 ` Daniel de Rauglaudre
2002-10-24 9:50 ` Stefano Zacchiroli
2002-10-24 10:30 ` Noel Welsh
2002-10-24 12:59 ` Daniel de Rauglaudre
2002-10-24 13:16 ` Basile STARYNKEVITCH [this message]
2002-10-25 10:29 ` Daniel de Rauglaudre
2002-10-24 12:34 ` Alessandro Baretta
2002-10-24 12:51 ` Daniel de Rauglaudre
[not found] <IIEMJEMIMDMLIIPHPOBLOELNCAAA.fsmith@mathworks.com>
2002-10-24 7:16 ` Alessandro Baretta
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=15799.62120.815873.654039@hector.lesours \
--to=basile@starynkevitch.net \
--cc=caml-list@inria.fr \
--cc=daniel.de_rauglaudre@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