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] Pickling for OCaml?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2006-01-06 (14:30)
From: Markus Mottl <markus.mottl@g...>
Subject: Re: [Caml-list] Pickling for OCaml?
On 1/6/06, Jonathan Roewen <> wrote:
> > Will the Marshall module not do?
> Marshal is unsafe. Pickling is safe. I'd take pickling =)

You could try our S-expression library, which uses CamlP4 to generate
code for converting arbitrary extensionally defined (= sum and product
types, polymorphic variants, records, types with type variables)
OCaml-types to and from S-expressions:

The library is safe and displays understandable error messages when
parsing S-expressions.  One can choose whether to print values in
human-readable ways or in very compact machine-readable (somewhat
human-readable) form.  It's also very easy to write down OCaml-values
in S-expression syntax, which makes it ideal for complex configuration


Markus Mottl