From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail1-relais-roc.national.inria.fr (mail1-relais-roc.national.inria.fr [192.134.164.82]) by sympa.inria.fr (Postfix) with ESMTPS id 1B8B07F249 for ; Wed, 31 Oct 2012 17:33:33 +0100 (CET) Received-SPF: None (mail1-smtp-roc.national.inria.fr: no sender authenticity information available from domain of Tiphaine.Turpin@free.fr) identity=pra; client-ip=212.27.42.1; receiver=mail1-smtp-roc.national.inria.fr; envelope-from="Tiphaine.Turpin@free.fr"; x-sender="Tiphaine.Turpin@free.fr"; x-conformance=sidf_compatible Received-SPF: None (mail1-smtp-roc.national.inria.fr: no sender authenticity information available from domain of Tiphaine.Turpin@free.fr) identity=mailfrom; client-ip=212.27.42.1; receiver=mail1-smtp-roc.national.inria.fr; envelope-from="Tiphaine.Turpin@free.fr"; x-sender="Tiphaine.Turpin@free.fr"; x-conformance=sidf_compatible Received-SPF: None (mail1-smtp-roc.national.inria.fr: no sender authenticity information available from domain of postmaster@smtp1-g21.free.fr) identity=helo; client-ip=212.27.42.1; receiver=mail1-smtp-roc.national.inria.fr; envelope-from="Tiphaine.Turpin@free.fr"; x-sender="postmaster@smtp1-g21.free.fr"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AvMAAHpRkVDUGyoBlGdsb2JhbABEw28jAQEBAQkLCQkUAySCHwEFUzYLISUPAkYTCAEBh28BFrI8CYoijw+DJAOVdoVpjUk X-IronPort-AV: E=Sophos;i="4.80,687,1344204000"; d="scan'208";a="179721791" Received: from smtp1-g21.free.fr ([212.27.42.1]) by mail1-smtp-roc.national.inria.fr with ESMTP; 31 Oct 2012 17:33:32 +0100 Received: from [192.168.0.1] (bur91-2-82-231-161-160.fbx.proxad.net [82.231.161.160]) (Authenticated sender: tiphaine.turpin) by smtp1-g21.free.fr (Postfix) with ESMTPA id C26599401FD for ; Wed, 31 Oct 2012 17:33:28 +0100 (CET) Message-ID: <509160B1.90801@free.fr> Date: Wed, 31 Oct 2012 18:32:33 +0100 From: Tiphaine Turpin User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0.3) Gecko/20120501 Thunderbird/10.0.3 MIME-Version: 1.0 To: caml-list@inria.fr References: <508F22BD.7010103@riken.jp> <50914480.1050408@frisch.fr> In-Reply-To: <50914480.1050408@frisch.fr> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Caml-list] Why should I use .mli files? I personally find that the most useful of the missing features that have been addressed here is the ability to write type definitions only once, when using interfaces (in particular mi files). Type annotations (especially with explicit polymorphism) are sufficient for the "value declaration" concern, in my opinion. Here is another proposal on this type topic : why not change the semantics of module type inclusion to consider missing types (and module types as well) as if they were declared with the same definition ? In other words, a signature S would be a subtype of S' if there exists some set of type declarations which, if prepended to S, make it have the type S' in the usual sense ? Exactly as [> `a ] is a subtype of [> `a | `b ] for polymorphic variants. I don't know if a sound semantics can be found for such a thing (especially since type declarations can refer to each other, unlike tags) but this would definitely be a backward-compatible modification (which we still may want to enable only with a command-line flag). Tiphaine