Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: "Frank A. Christoph" <christo@nextsolution.co.jp>
To: <caml-list@inria.fr>
Subject: Re: another approach to sprintf (Re: ocaml 2.02 bug: curried printf)
Date: Thu, 25 Mar 1999 08:48:32 +0900	[thread overview]
Message-ID: <008301be7653$4f031dc0$6f50ebca@newton> (raw)
In-Reply-To: <19990323171753.17334@pauillac.inria.fr>

> > I don't know very much about *printf in ocaml, but how about Olivier
> > Danvy's approach to sprintf (http://www.brics.dk/RS/98/12/index.html)?
> > It seems safer and faster than ordinary "interpretive" approach.  I'd
> > like to hear what do you (I mean, readers of this mailing list) think
> > about it.
> 
> It's a cute trick.  One drawback is that the format is not a character
> string, but needs to be expressed using special functions and infix
> operators.  On the other hand, it doesn't need the special
> typechecking rules for format strings that we have in OCaml.
> 
> With this special typechecking rules, I don't think Danvy's "partially
> evaluated" printf is any safer than OCaml's "interpreted" printf.

However, it has the significant advantage that formats are user-extensible.

> Also, it doesn't solve (nor makes any worse) the issues with partial
> application of printf and friends that we discussed before.

--FC



      parent reply	other threads:[~1999-03-25 13:10 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-03-06  1:38 ocaml 2.02 bug: curried printf William Chesters
1999-03-12 15:00 ` Xavier Leroy
1999-03-12 15:31   ` William Chesters
1999-03-19  8:47   ` another approach to sprintf (Re: ocaml 2.02 bug: curried printf) Eijiro Sumii
1999-03-23 16:17     ` Xavier Leroy
1999-03-24 19:37       ` John Prevost
1999-03-25 13:29         ` Christian Lindig
1999-03-25 20:52           ` John Prevost
1999-03-29 16:31         ` Xavier Leroy
1999-03-24 23:48       ` Frank A. Christoph [this message]

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='008301be7653$4f031dc0$6f50ebca@newton' \
    --to=christo@nextsolution.co.jp \
    --cc=caml-list@inria.fr \
    /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