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
[Caml-list] format type (again)
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2002-11-09 (16:33)
From: Pierre Weis <pierre.weis@i...>
Subject: Re: [Caml-list] format type (again)
> Could anyone tell me where in ocaml source is the type checking of the
> format type. I really need a new identifier for a function taking exacly 
> one parameter of type unit.
> Cezary Kaliszyk

[This is a kind of request for comments about the format type framework]

As already said by Gerd Stolpmann in this mailing list, the typing of
format strings is currently improving in the working version of
Objective Caml (in particular for kprintf, as Gerd pointed
out). Hence, it is a good time for requests for implementation of new
features (for printf or scanf in particular) to be included in the
next version of Objective Caml.

Your request for a new ``identifier for a function taking exactly one
parameter of type unit'', which I should call a request for a new
``conversion'', is such an extension, that we could easily add to the

However, you do not completely specified the feature you want, nor its
typical use. What would be the return type of the function ? Why is it
mandatory that the argument of the function has to be of tye unit (for
instance, why a %t conversion would not lead to the correct typing or
semantics ?). What could be the usefulness of such a conversion for
printf or scanf ?

So, all people reading this list who do need some extension to printf
or scanf or in general to the format type framework should drop me a
message personnally (not to overflow the Caml list :).

I already have a useful extension to add to handle easy i18n of printf
format strings, after a discussion with Daniel who is facing
tremendous needs for translation in his GeneWeb software (GeneWeb's
messages have been translated to more than 20 languages!)

I will summarize all your suggestions in a future message to this list.

Best regards,

Pierre Weis

INRIA, Projet Cristal, Pierre.Weis@inria.fr, http://pauillac.inria.fr/~weis/

To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners