From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from weis@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id KAA19791 for caml-red; Tue, 12 Dec 2000 10:27:41 +0100 (MET) Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id EAA16149 for ; Tue, 12 Dec 2000 04:26:36 +0100 (MET) Received: from igw8.watson.ibm.com (igw8.watson.ibm.com [198.81.209.20]) by nez-perce.inria.fr (8.11.1/8.10.0) with ESMTP id eBC3QZv22090 for ; Tue, 12 Dec 2000 04:26:35 +0100 (MET) Received: from sp1n189at0.watson.ibm.com (sp1n189at0.watson.ibm.com [9.2.104.62]) by igw8.watson.ibm.com (8.9.3/8.9.3/05-14-1999) with ESMTP id WAA07686; Mon, 11 Dec 2000 22:26:29 -0500 Received: from bismarck-chet.watson.ibm.com ([9.95.46.140]) by sp1n189at0.watson.ibm.com (8.9.3/Feb-20-98) with ESMTP id WAA30148; Mon, 11 Dec 2000 22:26:28 -0500 Received: from bismarck (bismarck.chet.org [127.0.0.1]) by bismarck-chet.watson.ibm.com (8.9.3/8.9.3/Debian 8.9.3-21) with ESMTP id WAA12331; Mon, 11 Dec 2000 22:25:19 -0500 Message-Id: <200012120325.WAA12331@bismarck-chet.watson.ibm.com> X-Authentication-Warning: bismarck.chet.org: Host bismarck.chet.org [127.0.0.1] claimed to be bismarck To: Chris Hecker cc: Mattias Waldau , Caml-List Subject: Re: Same label in different types, how do people solve this? In-Reply-To: Your message of "Mon, 11 Dec 2000 10:23:46 PST." <4.3.2.7.2.20001211101656.00c12320@shell16.ba.best.com> References: <4.3.2.7.2.20001211101656.00c12320@shell16.ba.best.com> Date: Mon, 11 Dec 2000 22:25:19 -0500 From: Chet Murthy Sender: weis@pauillac.inria.fr The issue, about practicality, isn't whether you _can_ specify the particular types and type-usages you want. The issue is whether, if you write a phrase, and you got it wrong, you have to know all about the type system, in order to debug that phrase. In SML, you have to understand the type algorithm enough to identify when you've underspecified a type, and that can be _tricky_. In CAML, you either got it right, or got it wrong. That simplicity goes a long way. And without it, well, you've got to teach the world all the intricacies of polymorphic typing. Not a winning strategy. --chet-- >>>>> "CH" == Chris Hecker writes: >> I understand that all you functional experts thinks this >> restriction is obvious, but for me it is more like a >> bug/misfeature. So this 'misfeature' should actually be stated >> for all us who aren't interested how types are infered in >> functional programming. CH> I'm with Mattias on this one. I'm practical above CH> theoretical. All of the workarounds for this problem seem CH> like they generate way more tedious work for the programmer, CH> and they still don't quite accomplish the goal 100%. This CH> characteristic of doing more work and only asymptotically CH> approaching your goal is a bad taste I associate with C++. CH> Anyway, my "vote" would be to allow specification, with : if CH> it's possible since it's the obvious syntax, but even with @@ CH> if necessary (even though I think it's really ugly).