caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: skaller <skaller@users.sourceforge.net>
To: xm@xmunkki.org
Cc: caml-list <caml-list@inria.fr>
Subject: Re: [Caml-list] Announcing ocalibs.
Date: 16 May 2004 11:03:49 +1000	[thread overview]
Message-ID: <1084669428.19838.57.camel@pelican.wigram> (raw)
In-Reply-To: <20040515235711.A2644@xmunkki.org>

On Sun, 2004-05-16 at 06:57, Jere Sanisalo wrote:
> On Sat, May 15, 2004 at 10:48:25PM +0200, Nicolas Cannasse wrote:
> >However one of the problem when writing games with ocaml is the lack of
> >mutual recursives modules,

I would expect recursion is no problem for games because games
tend to need dynamic binding, which classes provide,
and recursion via class type abstraction works fine
across module boundaries.

The big problem with classes is *intramodule* type recursion,
since mutually recursive class types can't also
recurse with variants and tuples (at least they couldn't
last time I played with them).  To fix this you have to 
make your class polymorphic, and then instantiate
in an ordinary (recursive) type declaration.

Polymorphic variants may help with this since they
don't need to be declared.

-- 
John Skaller, mailto:skaller@users.sf.net
voice: 061-2-9660-0850, 
snail: PO BOX 401 Glebe NSW 2037 Australia
Checkout the Felix programming language http://felix.sf.net



-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners


      reply	other threads:[~2004-05-16  1:04 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-05-15 10:12 Jere Sanisalo
     [not found] ` <004901c43abd$f83b6ad0$19b0e152@warp>
2004-05-15 20:57   ` Jere Sanisalo
2004-05-16  1:03     ` skaller [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=1084669428.19838.57.camel@pelican.wigram \
    --to=skaller@users.sourceforge.net \
    --cc=caml-list@inria.fr \
    --cc=xm@xmunkki.org \
    /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).