English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
Upgrading sexplib-2.7.0 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: 2007-04-30 (14:01)
From: Nicolas Pouillard <nicolas.pouillard@g...>
Subject: Re: Upgrading sexplib-2.7.0 to camlp4 3.10
On 4/30/07, Joel Reymont <joelr1@gmail.com> wrote:
> The bit below gives an error
>      | <:ctyp< $tp1$ . $tp2$ >> ->
> ocamlc -c -I +camlp4 -pp camlp4orf -for-pack Sexplib pa_sexp_conv.ml
> File "pa_sexp_conv.ml", line 105, characters 24-29:
> While expanding quotation "ctyp" in a position of "patt":
>    Parse error: ident_of_ctyp: this type is not an identifier
> How do I interpret this and what do I need to learn to fix it?

This is because dot cannot be used anywhere in types but just for identifiers.

So Foo.t is a type but not (int -> int).int even syntactically.

So you have to take the case <:ctyp< $id:i$ >> and then play with `i'
that is an ident and can be matched with <:ident< ... >>

Nicolas Pouillard