Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] Possible bug in module and class?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2002-10-22 (14:21)
From: Daniel de Rauglaudre <daniel.de_rauglaudre@i...>
Subject: Re: [Caml-list] Camlp4 pretty print comments

On Tue, Oct 22, 2002 at 03:18:38PM +0200, Stefano Zacchiroli wrote:
> Why comments are not represented? It's because the lexer don't return
> them or because the standard ocaml grammar rules skip them?
> If the first case does apply, is possible to add a camlp4 rule to
> retain them, right?

Well, as Maxence Guesdon says, it is really a pain to retain them.
Because it implies complicated actions in the lexer *and* in the parser.

Storing the comments, as Sven luther suggests, well, why not? But it
is complicated also.

A simple solution would be to store... the whole input! This way I
could read the "input file" in memory, and I am sure the change would
be easy to program.

I can do that, just for the case when the input is the standard one.
Are you interested and OK for this solution, even if it uses more
memory? (but now, machine memory spaces is big).

To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: