caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Michel Mauny <Michel.Mauny@inria.fr>
To: Christophe Raffalli <Christophe.Raffalli@univ-savoie.fr>
Cc: Caml Mailing List <caml-list@yquem.inria.fr>
Subject: Re: [Caml-list] ocaml parser
Date: Wed, 02 Jul 2008 06:48:42 +0200	[thread overview]
Message-ID: <486B08AA.5010303@inria.fr> (raw)
In-Reply-To: <486A5C84.3080005@univ-savoie.fr>

Christophe Raffalli écrit/writes [07/01/2008 06:34 PM] :

> Is it a bug to have any difference between both ocaml parser (with "-pp 
> camlp4o" or without) ?

In some situations yes, in others no.

> I expected that everything that compiles with ocamlc should compile with 
> ocamlc -pp camlp4o
> (the opposite is not true and does not need to be true) which is not the 
> case.

Camlp4o is supposed to parse all OCaml plus things such as stream
parsers.  Since adding keywords ("parser", for instance) may break
legal OCaml programs, Camlp4o is supposed to parse OCaml programs that
don't conflict with such extensions.  Camlp4o cannot therefore parse
_all_ OCaml programs.

> And a secondary question : why to have two parsers (except maybe for 
> bootstraping) ?

I'm not sure I understand your question, but the OCaml and Camlp4o
parsers use a different technology. The latter is extensible while the
former is not.

-- Michel


  reply	other threads:[~2008-07-02  7:38 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-01 16:34 Christophe Raffalli
2008-07-02  4:48 ` Michel Mauny [this message]
2008-07-02  7:44   ` [Caml-list] " Christophe Raffalli
2008-07-02 15:34     ` blue storm

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=486B08AA.5010303@inria.fr \
    --to=michel.mauny@inria.fr \
    --cc=Christophe.Raffalli@univ-savoie.fr \
    --cc=caml-list@yquem.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;
as well as URLs for NNTP newsgroup(s).