caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Jon Harrop <jon@ffconsultancy.com>
To: caml-list@yquem.inria.fr
Subject: Re: [Caml-list] Multi-Index Container
Date: Fri, 2 Dec 2005 00:53:29 +0000	[thread overview]
Message-ID: <200512020053.30014.jon@ffconsultancy.com> (raw)
In-Reply-To: <2670dfc80512011442g560dbfd0nabdef7c65d26d04c@mail.gmail.com>

On Thursday 01 December 2005 22:42, Mako Tagliere wrote:
> My colleagues and I often debate the relative merits of OCaml and C++.
> After I tell them how expressive, fast, and all-around nifty OCaml is
> ("see! the debugger works backwards in time!"), they reply "yeah but
> C++ has STL and Boost library, which make C++ every bit as expressive as
> OCaml."  When we repeated this debate recently, they challenged me to
> show them an implementation of Boost's multi-index container
> (http://www.boost.org/libs/multi_index/doc/index.html) in OCaml.  A
> bit of searching did not reveal an existing OCaml implementation.
>
> Would someone in the OCaml community be willing to sketch out such an
> implementation?

In order to compare different languages meaningfully, you should try to solve 
problems by writing independent implementations in different languages.

There is no point in trying to mimic individual features, paradigms or styles 
found in other languages, as you suggest. Paul Graham's infamous "accumulator 
generator" challenge is a fine example this mistake:

  http://www.paulgraham.com/accgen.html

So you should ask your friends to try to come up with a real task with a C++ 
implementation that benefits from Boost's functionality, and then write your 
own implementation in OCaml before comparing the two.

I thought the examples from the page that you cite might have been suitable 
but the ones that I have looked at are all trivial in OCaml (and C++).

-- 
Dr Jon D Harrop, Flying Frog Consultancy Ltd.
Objective CAML for Scientists
http://www.ffconsultancy.com/products/ocaml_for_scientists


      parent reply	other threads:[~2005-12-02  0:58 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-12-01 22:42 Mako Tagliere
2005-12-02  0:19 ` [Caml-list] " skaller
2005-12-02  0:53 ` Jon Harrop [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=200512020053.30014.jon@ffconsultancy.com \
    --to=jon@ffconsultancy.com \
    --cc=caml-list@yquem.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;
as well as URLs for NNTP newsgroup(s).