From: Gerd Stolpmann <info@gerd-stolpmann.de>
To: Berke Durak <berke.durak@gmail.com>
Cc: Richard Jones <rich@annexia.org>, caml-list <caml-list@inria.fr>
Subject: Re: [Caml-list] [OSR] Standard syntax extensions ?
Date: Fri, 25 Apr 2008 19:31:39 +0200 [thread overview]
Message-ID: <1209144699.13495.16.camel@flake.lan.gerd-stolpmann.de> (raw)
In-Reply-To: <b903a8570804250959s443d542ew3ba1fc002272cb25@mail.gmail.com>
Am Freitag, den 25.04.2008, 18:59 +0200 schrieb Berke Durak:
>
>
> On Fri, Apr 25, 2008 at 10:24 AM, Richard Jones <rich@annexia.org>
> wrote:
> On Thu, Apr 24, 2008 at 10:53:36PM +0200, Berke Durak wrote:
> > We absolutely need a standard serialization solution.
> >
> > I'm thinking of Sexplib of course but it could be another
> one. The reason
> > it must be standard is that it's difficult to provide
> > serialization/deserialization functions outside the
> imlementation.
>
>
> It isn't though. There are several serialization modules
> (sexplib,
> deriving, ...), all of them are packaged up so using them is a
> simple
> 'apt-get' away.
>
> But we need at least to enrich standard container datatypes with
> serialization functions... Do we want to have n copies of each
> datatype
> for each serialization library? I think we must agree on one such
> solution
> and ensure it is always available.
>
> As those solutions all involve syntax extensions, this means that it
> must go
> into the list of standard sytnax extensions.
>
>
> > So Sexplib should be a standard extension, or better, it
> should be included
> > in the compiler and used for the .cmo/.cmi/.cmxa files.
>
>
> Why?
>
> That would allow people to easily write tools that examine object
> files without
> relying on the unnecessarily britlle binary format.
You are very optimistic here. I'm a power user of a number of
serializers (JSON, XDR, ICEP), and it is not the problem that one format
is binary, and the other text, but that serialized representations are
usually not self-describing. So even if you could simply read in a cmi
into your program, the problem remains how to interpret it. You cannot
overcome the dependency on a certain O'Caml version by switching to a
text format.
> At the very least you
> could open it in a text editor and see if everything's OK inside, or
> simply grep
> it.
You can do that already for cmi's. Just create a file "dummy.ml" with
include Name_of_cmi
in it and run "ocamlc -c -i dummy.ml" on it which prints the definitions
of the cmi as readable text. Ok, there's more in it than only
definitions, but the ocaml distribution includes a program called
objinfo that allows you to inspect cmi's, cmo's and cma's, e.g. you can
view the MD5 sums.
> Yes, there is CMI grep, but that one would be even better. Do this,
> and
> you will instantly see 10 to 20 new metatools for Ocaml.
Which tools for example?
Gerd
--
------------------------------------------------------------
Gerd Stolpmann * Viktoriastr. 45 * 64293 Darmstadt * Germany
gerd@gerd-stolpmann.de http://www.gerd-stolpmann.de
Phone: +49-6151-153855 Fax: +49-6151-997714
------------------------------------------------------------
next prev parent reply other threads:[~2008-04-25 17:30 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-24 15:49 David Teller
2008-04-24 15:52 ` [Caml-list] " John Whitington
2008-04-25 8:22 ` Richard Jones
2008-05-01 7:45 ` Richard Jones
2008-04-24 16:16 ` [Caml-list] [OSR] Standard syntax extensions ? - voting Stefano Zacchiroli
2008-04-25 15:15 ` David Teller
2008-04-26 0:16 ` Stefano Zacchiroli
2008-04-24 16:41 ` [Caml-list] [OSR] Standard syntax extensions ? Martin Jambon
2008-04-24 17:02 ` Jon Harrop
2008-04-24 20:53 ` Berke Durak
2008-04-25 8:24 ` Richard Jones
2008-04-25 16:59 ` Berke Durak
2008-04-25 17:31 ` Gerd Stolpmann [this message]
2008-04-25 17:38 ` Richard Jones
2008-04-25 10:33 ` Andrej Bauer
2008-04-25 15:32 ` David Teller
2008-04-24 17:05 ` Dario Teixeira
2008-04-25 13:57 ` Peng Zang
2008-04-25 15:04 ` David Teller
2008-04-25 16:11 ` Peng Zang
2008-04-25 20:37 ` Arthur Chan
2008-04-26 7:41 ` Richard Jones
2008-04-26 7:53 ` Till Crueger
2008-04-26 21:32 ` Arthur Chan
2008-04-27 6:58 ` Andrej Bauer
2008-04-27 14:14 ` Christopher L Conway
2008-04-27 17:41 ` [Caml-list] " David Teller
2008-04-27 17:44 ` David Teller
2008-04-25 22:25 ` Mike Lin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1209144699.13495.16.camel@flake.lan.gerd-stolpmann.de \
--to=info@gerd-stolpmann.de \
--cc=berke.durak@gmail.com \
--cc=caml-list@inria.fr \
--cc=rich@annexia.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).