caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* [Caml-list] camlp4 Plexer.no_quotations default
@ 2002-10-30 12:32 Hendrik Tews
  2002-10-30 14:05 ` Daniel de Rauglaudre
  0 siblings, 1 reply; 4+ messages in thread
From: Hendrik Tews @ 2002-10-30 12:32 UTC (permalink / raw)
  To: caml-list

Hi, 

the default value for Plexer.no_quotations is false. This lets
"camlp4o pr_o.cmo" fail on legal ocaml programs like 

  let ( <:> ) x y = x + y;;

I would suggest to make the default value true. 

Camlp4 modules that define grammar rules with quotations (like
q_MLast.cmo) should change Plexer.no_quotations to false in their
startup code.

Bye,

Hendrik
-------------------
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


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

* Re: [Caml-list] camlp4 Plexer.no_quotations default
  2002-10-30 12:32 [Caml-list] camlp4 Plexer.no_quotations default Hendrik Tews
@ 2002-10-30 14:05 ` Daniel de Rauglaudre
  2002-11-04 17:02   ` Hendrik Tews
  0 siblings, 1 reply; 4+ messages in thread
From: Daniel de Rauglaudre @ 2002-10-30 14:05 UTC (permalink / raw)
  To: caml-list

Hi,

On Wed, Oct 30, 2002 at 01:32:15PM +0100, Hendrik Tews wrote:
> 
> the default value for Plexer.no_quotations is false. This lets
> "camlp4o pr_o.cmo" fail on legal ocaml programs like 
>   let ( <:> ) x y = x + y;;
> I would suggest to make the default value true. 

No, because it supposes that people using the Camlp4 quotations would
always have to set it explicitely to false. And I think that there are
much more people using the Camlp4 quotations than using the token <:>

What I could do, if you want, is to add an option of the command
line of Camlp4 setting it to true. You could use it like that:
       ocamlc -pp "camlp4o -no_quot" ...

Something like that. Would you like it?

-- 
Daniel de RAUGLAUDRE
http://cristal.inria.fr/~ddr/
-------------------
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


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

* Re: [Caml-list] camlp4 Plexer.no_quotations default
  2002-10-30 14:05 ` Daniel de Rauglaudre
@ 2002-11-04 17:02   ` Hendrik Tews
  2002-11-04 17:40     ` Daniel de Rauglaudre
  0 siblings, 1 reply; 4+ messages in thread
From: Hendrik Tews @ 2002-11-04 17:02 UTC (permalink / raw)
  To: caml-list

Daniel de Rauglaudre writes:
   Date: Wed, 30 Oct 2002 15:05:14 +0100
   Subject: Re: [Caml-list] camlp4 Plexer.no_quotations default
   
   On Wed, Oct 30, 2002 at 01:32:15PM +0100, Hendrik Tews wrote:
   > 
   > the default value for Plexer.no_quotations is false. This lets
   > "camlp4o pr_o.cmo" fail on legal ocaml programs like 
   >   let ( <:> ) x y = x + y;;
   > I would suggest to make the default value true. 
   
Originally I thought that there are no quotation expanders
defined in the bare camlp4 executable. Therefore I suggested that
quotation expansion should be off by default.

By grepping for Quatation.add I learned that camlp4 contains at
least two quotation expanders: "id" and "string". Are there more?
Where are they documented? (I would also be interested in why
they are included in camlp4?)

   What I could do, if you want, is to add an option of the command
   line of Camlp4 setting it to true. You could use it like that:
          ocamlc -pp "camlp4o -no_quot" ...
   
An option would be fine.

Bye,

Hendrik
-------------------
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


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

* Re: [Caml-list] camlp4 Plexer.no_quotations default
  2002-11-04 17:02   ` Hendrik Tews
@ 2002-11-04 17:40     ` Daniel de Rauglaudre
  0 siblings, 0 replies; 4+ messages in thread
From: Daniel de Rauglaudre @ 2002-11-04 17:40 UTC (permalink / raw)
  To: caml-list

Hi,

On Mon, Nov 04, 2002 at 06:02:01PM +0100, Hendrik Tews wrote:

> By grepping for Quatation.add I learned that camlp4 contains at
> least two quotation expanders: "id" and "string". Are there more?
> Where are they documented? (I would also be interested in why
> they are included in camlp4?)

No, there are no more predefined quotation expanders than the ones
you cite (if you don't load other cmo files, of course).

Why these ones are included? Well, there is no reason, it was just to
test that it works, a very time ago. But they are not used (not by me,
in any case), I can remove them if it is a problem.

>           ocamlc -pp "camlp4o -no_quot" ...
> An option would be fine.

OK, I added it.

-- 
Daniel de RAUGLAUDRE
http://cristal.inria.fr/~ddr/
-------------------
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


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

end of thread, other threads:[~2002-11-04 17:40 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-10-30 12:32 [Caml-list] camlp4 Plexer.no_quotations default Hendrik Tews
2002-10-30 14:05 ` Daniel de Rauglaudre
2002-11-04 17:02   ` Hendrik Tews
2002-11-04 17:40     ` Daniel de Rauglaudre

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