From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id VAA12839; Thu, 24 Oct 2002 21:40:55 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: (from weis@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id VAA12903 for caml-list@pauillac.inria.fr; Thu, 24 Oct 2002 21:40:55 +0200 (MET DST) Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id PAA03676 for ; Thu, 24 Oct 2002 15:16:28 +0200 (MET DST) X-SPAM-Warning: Sending machine is listed in blackholes.five-ten-sg.com Received: from kraid.nerim.net (kraid.nerim.net [62.4.16.95]) by concorde.inria.fr (8.11.1/8.11.1) with ESMTP id g9ODGR507782; Thu, 24 Oct 2002 15:16:28 +0200 (MET DST) Received: from hector.lesours (lesours.starynkevitch.net [80.65.224.217]) by kraid.nerim.net (Postfix) with ESMTP id 0CF7640F5D; Thu, 24 Oct 2002 15:07:07 +0200 (CEST) Received: from basile by hector.lesours with local (Exim 3.36 #1 (Debian)) id 184hqc-00047s-00; Thu, 24 Oct 2002 15:16:26 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Message-ID: <15799.62120.815873.654039@hector.lesours> Date: Thu, 24 Oct 2002 15:16:24 +0200 To: Daniel de Rauglaudre Cc: caml-list@inria.fr Subject: Re: [Caml-list] Again on pattern matching and strings In-Reply-To: <20021024145904.K12351@verdot.inria.fr> References: <3DB73515.90705@baretta.com> <15799.14325.887770.501722@karryall.dnsalias.org> <3DB7A4B9.1030607@baretta.com> <20021024105136.C12351@verdot.inria.fr> <20021024095045.GB11324@cs.unibo.it> <20021024145904.K12351@verdot.inria.fr> X-Mailer: VM 7.07 under Emacs 21.2.2 From: Basile STARYNKEVITCH Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk >>>>> "Daniel" == Daniel de Rauglaudre 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: basilestarynkevitchnet alias: basiletunesorg 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