From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=AWL autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id 70B82BC0A for ; Fri, 8 Jun 2007 23:53:37 +0200 (CEST) Received: from mail17.bluewin.ch (mail17.bluewin.ch [195.186.18.64]) by concorde.inria.fr (8.13.6/8.13.6) with ESMTP id l58LrbAP028227 for ; Fri, 8 Jun 2007 23:53:37 +0200 Received: from [10.0.1.2] (85.2.19.214) by mail17.bluewin.ch (Bluewin 7.3.121) id 465E928F0026E7A5; Fri, 8 Jun 2007 21:53:36 +0000 In-Reply-To: <4669BEDF.9010109@lix.polytechnique.fr> References: <4669BEDF.9010109@lix.polytechnique.fr> Mime-Version: 1.0 (Apple Message framework v752.2) Content-Type: text/plain; charset=ISO-8859-1; delsp=yes; format=flowed Message-Id: Cc: OCaml List Content-Transfer-Encoding: quoted-printable From: =?ISO-8859-1?Q?Daniel_B=FCnzli?= Subject: Re: [Caml-list] Existential types and W Date: Fri, 8 Jun 2007 23:54:00 +0200 To: Arnaud Spiwack X-Mailer: Apple Mail (2.752.2) X-Miltered: at concorde with ID 4669CFE1.000 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; bunzli:01 buenzli:01 existential:01 existential:01 functors:01 arrays:01 ocaml:01 arnaud:01 abstract:01 typing:01 caml-list:01 caml-list:01 algorithm:01 expression:02 caml:02 Le 8 juin 07 =E0 22:41, Arnaud Spiwack a =E9crit : > 1/ Do the reader of this list encounter the need of existential =20 > type often? Sometimes it can be useful to express an abstract type + operations =20 without going through functors which only provide static existential =20 types. This allows to store in the same datastructure such types + =20 operations with different implementations. For example imagine a =20 spatial datastructure with both float32 bigarrrays and regular caml =20 float arrays. > 2/ How would the addition of existential types impact the typing =20 > algorithm of OCaml? (because I must confess that I have absolutely =20 > no clue, would there still be a principal type to every expression? =20= > would that increase complexity?) I don't know. But if you really need them they can be encoded in the current type =20 system, see the discussion here [1]. Best, Daniel [1] http://caml.inria.fr/pub/ml-archives/caml-list/=20 2004/01/52732867110697f55650778d883ae5e9.fr.html=