From: Didier.Remy@inria.fr
To: David McClain <dmcclain@azstarnet.com>
Cc: caml-list@inria.fr
Subject: Re: CLOS and ML?
Date: Wed, 4 Aug 1999 12:13:45 +0200 [thread overview]
Message-ID: <19990804121345.15126@morgon.inria.fr> (raw)
In-Reply-To: <000b01bed94a$c681b870$210148bf@dylan>; from David McClain on Wed, Jul 28, 1999 at 03:44:36PM -0700
> I have been missing CLOS sooo much that I decided to give it a try in OCAML.
> It turns out that to first order, one can quite readily acheive multi-method
> dispatch using ML-like languages (see below...) Of course it would be far
> more convenient if this were an inherent part of the language. I have
> thought briefly about making a front-end that would accept an extended
> syntax incorporating some notion of multi-methods and having it translate to
> standard OCAML as a result. This would alleviate all runtime dispatching
> except for those cases where a possibly ambiguous data type is acted upon.
What you showed is one way to compile multi-methods in Ocaml, but you turned
off the type system by using dynamic types (implemented as variant types).
An ML user would expect some typechecking, so that in particular 'message not
understood' cannot arise.
> Is there any reason not to make CLOS-like behavior (e.g., STklos, CLOS,
> Dylan) in an ML language?
Typing CLOS-like objects and classes, including polymorphism, remains an
interesting topic for research.
-Didier
prev parent reply other threads:[~1999-08-12 10:17 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
1999-07-28 22:44 David McClain
1999-08-04 10:13 ` Didier.Remy [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=19990804121345.15126@morgon.inria.fr \
--to=didier.remy@inria.fr \
--cc=caml-list@inria.fr \
--cc=dmcclain@azstarnet.com \
/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