Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: Bill Wood <william.wood3@comcast.net>
To: Alessandro Baretta <a.baretta@barettadeit.com>
Cc: Ocaml <caml-list@inria.fr>
Subject: Re: [Caml-list] Request for comments: Printf list conversion
Date: Thu, 12 Jan 2006 09:50:54 -0600	[thread overview]
Message-ID: <1137081054.29722.13.camel@localhost> (raw)
In-Reply-To: <43C61F1F.4030101@barettadeit.com>

On Thu, 2006-01-12 at 10:19 +0100, Alessandro Baretta wrote:
   . . .
> What do you guys think about all this?

Just a comment.  I've been anticipating getting into something like this
since I started considering OCaml as a work-horse language.  I've gone
through this exercise several times -- When I worked in Prolog, I hacked
together a list formatter; after using Scheme a while I hacked out a
list formatter package (and I'm dreading doing it yet again :-).  The
thing is, it's so terribly useful.

I'm always inspired in my hacks by Common Lisp's (format...) form, which
includes a ~{/~} pair containing conversion directives and that consumes
a list argument.  I don't want to appall you with complexity too soon,
but when you think about this, consider the possibility that the list is
a list of lists, each of which contains several items that are to be
formatted using a a recursively specified (sub) format.  This does
enhance usability a great deal.  I'm sure that there are people who will
yelp in protest at this, but I do recommend looking at CL's format as at
least one point in this design space.

Good luck; I eagerly await your results :-)

 -- Bill Wood



  parent reply	other threads:[~2006-01-12 15:51 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-01-12  9:19 Alessandro Baretta
2006-01-12  9:31 ` [Caml-list] " Jean-Marc EBER
2006-01-12  9:55 ` Jean-Christophe Filliatre
2006-01-12 12:55   ` Damien Doligez
2006-01-12 13:27     ` Virgile Prevosto
2006-01-13  8:47       ` Jean-Christophe Filliatre
2006-01-12 15:50 ` Bill Wood [this message]
2006-01-12 17:39   ` Richard Jones
2006-01-12 19:29     ` Bill Wood
2006-01-13  9:31   ` Hendrik Tews
2006-01-13 16:28     ` Bill Wood

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=1137081054.29722.13.camel@localhost \
    --to=william.wood3@comcast.net \
    --cc=a.baretta@barettadeit.com \
    --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