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
Issues with Sexplib (#1)
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Dario Teixeira <darioteixeira@y...>
Subject: Re: [Caml-list] Issues with Sexplib (#1)

> This is not really a bug; I'd qualify this as an "undesirable"
> feature: sexplib erases type information; for instance the
> representation of None* will always be the same and therefore
> will be desexpable to any other option type. You may also note
> that some other type have compatible representations. In
> practice it would be really hard for a camlp4 extension to keep
> track of types. In you case you could use custom converters and
> save the phantom type in the sexp.

Yes, I figured as much (see the last paragraph of my original
message).  I was just wondering if there was already a canned
solution to this sort of problem (or one in the works), before
I wrote a custom converter.

Dario Teixeira