Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: Chris Hecker <checker@d6.com>
To: Pierre Weis <Pierre.Weis@inria.fr>
Cc: caml-list@inria.fr
Subject: Re: circular types?
Date: Sat, 21 Oct 2000 11:37:11 -0700 (PDT)	[thread overview]
Message-ID: <Pine.BSF.4.21.0010211129570.20909-100000@shell16.ba.best.com> (raw)
In-Reply-To: <200010210802.KAA17692@pauillac.inria.fr>


> By contrast if the recursivity has to spread over more than one
> module, there is no solution in Caml. This is an active research area
> to design a module system that supports this feature (the so-called
> ``mixins'').

Could you explain how this helps with mixin?  My understanding of
mixin is that you compose types such that you can easily add
"printable" or "drawable" to an object in a lightweight way.  Is this
related in some way I don't see?  Or, does mixin mean something
different?

Templates somewhat obviate the need for mixin, since "printable" just
becomes a constraint that the type support the "print" function,
"sortable" means the type has "<", etc.  This is generic programming
in the Stepanov sense.  I still need to get my head around ocaml's
generic programming constructs, though.  It seems they're more
powerful in some ways and less in others (since you can't overload,
you can't write a single generic function that operates on any types
that satisfy the constraints like you can in C++).  I'm still trying
to figure this out, though, so I could be mistaken.

Chris





  reply	other threads:[~2000-10-22 19:41 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-10-20  2:35 Chris Hecker
2000-10-20 12:24 ` Pierre Weis
2000-10-20 21:34   ` Chris Hecker
2000-10-21  8:02     ` Pierre Weis
2000-10-21 18:37       ` Chris Hecker [this message]
2000-10-21 12:22     ` Vitaly Lugovsky
2000-10-21 18:29       ` Chris Hecker
2000-10-21 22:36     ` Brian Rogoff
2000-10-23 18:43     ` Anton Moscal
2000-10-23  7:43 Tom Hirschowitz
2000-10-23 15:35 ` Brian Rogoff
2000-10-25 14:03   ` John Max Skaller
2000-10-25 19:47     ` Brian Rogoff
2000-10-26  9:12     ` Hendrik Tews
2000-10-26 16:37       ` John Max Skaller
2000-10-24  8:37 ` Hendrik Tews
2000-10-25 14:31   ` John Max Skaller
2000-10-26  8:51     ` Hendrik Tews
2000-10-24  8:48 Tom Hirschowitz
2000-10-26  8:39 ` Hendrik Tews
2000-10-26  9:11   ` Tom Hirschowitz

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=Pine.BSF.4.21.0010211129570.20909-100000@shell16.ba.best.com \
    --to=checker@d6.com \
    --cc=Pierre.Weis@inria.fr \
    --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