From: "Daniel Bünzli" <daniel.buenzli@epfl.ch>
To: Jacques Garrigue <garrigue@math.nagoya-u.ac.jp>
Cc: caml-list@inria.fr
Subject: Re: [Caml-list] Fwd: "ocaml_beginners"::[] Trouble combining polymorphic classes and polymorphic methods
Date: Wed, 28 Feb 2007 14:47:59 +0100 [thread overview]
Message-ID: <2BFFE1D1-1C1B-4E33-B3AD-C75A30B5E58D@epfl.ch> (raw)
In-Reply-To: <20070228.130115.35466734.garrigue@math.nagoya-u.ac.jp>
Le 28 févr. 07 à 05:01, Jacques Garrigue a écrit :
> Wow, here is a strong statement. Basically, you seem to be saying that
> types are useless for safety if they don't ensure full correctness,
> and that in the absence of safety they need to be nominal in order to
> declare any intent?
I think you took the statement stronger that I intended (my fault).
I'm certainly not saying types are useless for safety without
correctness. I find it _immensely_ usefull that a machine takes care
of the bureaucracy of types and I often wonder, when the compiler
reminds me, how bad my software development would be in a dynamically
typed language -- not even talking about those in which you don't
declare your identifiers.
My statement was really about the module system part of the type
system. I sometimes find it a little bit artificial that if your
module structuraly matches a signature you can pass it to a functor.
If you take the point of view of a programmer who is provided with
modules he didn't write, I think it makes it easier for him to make
correct functor applications in a nominal setting because modules
explictely indicate that they were designed to support a given
interface. On the other hand, nominality hinders code reuse since you
may found a use that the initial programmer couldn't ever foresee.
But this problem can be alleviated by a simple construct that allows
to extend a module to support a new interface (even if no new code
needs to be written).
Besides that, I agree with most of your points, even though your
`Apples may be oranges to me but I quite buy your probabilistic
argument.
Best,
Daniel
prev parent reply other threads:[~2007-02-28 13:46 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <301730110702251747y72ae9fbdqd33bd8d08293cbe3@mail.gmail.com>
2007-02-27 21:22 ` Geoffrey Romer
2007-02-28 0:23 ` [Caml-list] " Jacques Garrigue
2007-02-28 1:18 ` Lukasz Stafiniak
2007-02-28 1:34 ` Jacques Garrigue
2007-02-28 1:57 ` skaller
2007-02-28 3:23 ` Daniel Bünzli
2007-02-28 4:01 ` Jacques Garrigue
2007-02-28 5:09 ` skaller
2007-02-28 13:47 ` Daniel Bünzli [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=2BFFE1D1-1C1B-4E33-B3AD-C75A30B5E58D@epfl.ch \
--to=daniel.buenzli@epfl.ch \
--cc=caml-list@inria.fr \
--cc=garrigue@math.nagoya-u.ac.jp \
/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).