From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id BAA10455; Thu, 19 Sep 2002 01:01:33 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id BAA10537 for ; Thu, 19 Sep 2002 01:01:32 +0200 (MET DST) Received: from ext-ch1gw-1.online-age.net (ext-ch1gw-1.online-age.net [216.34.191.35]) by concorde.inria.fr (8.11.1/8.11.1) with ESMTP id g8IN1Q122305 for ; Thu, 19 Sep 2002 01:01:26 +0200 (MET DST) Received: from int-ch1gw-3.online-age.net (int-ch1gw-3 [3.159.232.67]) by ext-ch1gw-1.online-age.net (8.12.3/8.9.1/990426-RLH) with ESMTP id g8IN1NCt013222; Wed, 18 Sep 2002 19:01:24 -0400 (EDT) Received: from uswaumsxb4medge.med.ge.com (localhost [127.0.0.1]) by int-ch1gw-3.online-age.net (8.12.3/8.12.3/990426-RLH) with ESMTP id g8IN1HlE009124; Wed, 18 Sep 2002 19:01:18 -0400 (EDT) Received: by USWAUMSXB4MEDGE with Internet Mail Service (5.5.2656.59) id ; Wed, 18 Sep 2002 18:01:12 -0500 Message-ID: From: "Gurr, David (MED, self)" To: "Kontra, Gergely" Cc: caml-list@inria.fr, "Gurr David (MED Self) (E-mail)" Subject: RE: [Caml-list] Does this function exist? Date: Wed, 18 Sep 2002 18:01:05 -0500 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2656.59) Content-Type: text/plain Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk > -----Original Message----- > From: Kontra, Gergely [mailto:kgergely@mlabdial.hit.bme.hu] > Sent: Tuesday, September 17, 2002 9:21 AM > To: John Prevost > Cc: Lukasz Lew; caml-list@inria.fr > Subject: Re: [Caml-list] Does this function exist? > > > >Doesn't matter--you still need type information. > > BTW allowing polymorphism doesn't solve the problem? Ocaml is strictly > typed, so one can figure out it's parameter in compile-type, right? > Or wrong? Most ML languages do type erasure rather than dictionary passing. Yeah, the compiler knows the type, but you want the runtime to know the type. But the runtime doesn't know much more than int,float,closure, pointer to something with a constructor tag. Java's reflection and C++ RTTI come at a price that is considered wrong by designers who pick type erasure. I am a fan of reflection but I agree with Ocaml's choices. What you seem to want is IMHO something that is right for debuggers and interactive toploops but not other code, thus they not the other code should pay the price. Read up on implementation of ML on JVM or MSCLR for an alternative to the Ocaml choices. -D PS if you are really into this, you could implement RTTI with preprocessing via camlp4 (?or MetaOcaml?). > Gergo > > +-[Kontra, Gergely @ Budapest University of Technology and > Economics]-+ > | Email: kgergely@mcl.hu, kgergely@turul.eet.bme.hu > | > | URL: turul.eet.bme.hu/~kgergely Mobile: (+36 20) 356 > 9656 | > +-------"Olyan langesz vagyok, hogy poroltoval kellene > jarnom!"-------+ > . > Magyar php mirror es magyar php dokumentacio: http://hu.php.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 > ------------------- 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