Version française
Home     About     Download     Resources     Contact us    
Browse thread
switching to camlp4 3.10
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Martin Jambon <martin.jambon@e...>
Subject: Re: [Caml-list] switching to camlp4 3.10
On Mon, 19 Mar 2007, Nicolas Pouillard wrote:

> On 3/19/07, Martin Jambon <martin.jambon@ens-lyon.org> wrote:
>> Hello,
>> 
>> I started trying to convert my programs so that they support camlp4 3.10.
>> 
>> 1) Is there a better source of documentation than
>> http://gallium.inria.fr/~pouillar/camlp4-changes.html?
>> 
>> 2) What is the command for preprocessing a simple syntax extension?
>> 
>> This used to work:
>>
>>    camlp4o pa_extend.cmo q_MLast.cmo pr_o.cmo -loc _loc pa_foo.ml
>
> This command is supposed to works in the new version. In fact module
> names have changed but ald ones are emulated. However I recently
> noticed a bug for q_MLast.cmo, it's now fixed in the CVS.

ok, thanks.

> However this incantation should be replaced by:
>
> camlp4of -printer OCaml pa_foo.ml
>
> Note: -loc _loc is useless since _loc is the default value.

Right, until the default changes :-)
It used to be "loc" and one day it suddenly became "_loc".

> Note2: -printer o is a shortcut for -printer OCaml

Cool.

--
Martin Jambon
http://martin.jambon.free.fr