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
Functional unparsing
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2009-04-17 (08:35)
From: Andrey Riabushenko <cdome@b...>
Subject: Re: [Caml-list] Functional unparsing
> The Batteries Print module and associated syntax extension may be a
> useful base for implementing something similar to what you are
> proposing:
> http://git.ocamlcore.org/cgi-bin/gitweb.cgi?p=batteries/batteries.git;a=blo
>b_plain;f=src/core/extlib/print.ml;hb=HEAD and
> http://git.ocamlcore.org/cgi-bin/gitweb.cgi?p=batteries/batteries.git;a=tre
> This allows for syntax like:
> Print.printf p"This is a list of integers: %{int list}"
> to return:
> int list -> unit = <fun>

Thank you, this one was much more helpful then standard printf.ml. This one is 
much shorter and easier to understand.