From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by yquem.inria.fr (Postfix) with ESMTP id BB16DBBAF for ; Wed, 2 Jun 2010 15:15:01 +0200 (CEST) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AncDALX2BUxDww+FlGdsb2JhbACDGY48L4wWFQEBAQEHDQgJEQMfr1I5ggCFboh9AQQEAYEhgwJuBINI X-IronPort-AV: E=Sophos;i="4.53,347,1272837600"; d="scan'208";a="51634306" Received: from unknown (HELO web111501.mail.gq1.yahoo.com) ([67.195.15.133]) by mail3-smtp-sop.national.inria.fr with SMTP; 02 Jun 2010 15:14:32 +0200 Received: (qmail 3617 invoked by uid 60001); 2 Jun 2010 13:14:27 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1275484467; bh=8zX13Oi2WJX1HfZjWCBgpYBsP5ENBlfjqe5VbYetih0=; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=YgX5bo5GbY9R5G1HqP0AxLPfazE9BHoRof6b9u6gwsLdgC04DsnJDJ3LZozMO1+J9Ib3a8fyfo+V1OZmbEYQA8qpxGQLMkdx2Yv2MM5pCl2lRyiToZZMZKCJSeYa4vDqgXgQv3kqFMPDZAwV7zMOpjMVmRrD/OB0U4Y8nRJanjQ= DomainKey-Signature:a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=so6tnCYInnJ44iOFt8mAOo3UpOoEMidBFRpBOJJtyUUobmU2+k04f9ZMplQD94DH4IkSqYAGaQUIxc/K40Ts7Z7YE2omEUoyu8QUq2H7X5zccVBfWiA5NwHYZkaxpHbCsJekH5a0hRHBss1PZGovD+Wa6ltKPWR2lVTZyr+5yQk=; Message-ID: <367372.3609.qm@web111501.mail.gq1.yahoo.com> X-YMail-OSG: RdThhYkVM1kXmkjhL76qcQAVd4NC5auZ5AScYF.te4vAMMr 6Re6hyqylCOH3vj90oXkr.fkOdE9QDVwcImDO7hSFpkN1fXw.J1EagxAyKyt b4lU6Dkwni28l3IMpujXTvme8TtMmHqmmdUi2dlB582D2e3mcaVLNULOyGDw T1ZUlZJadaWfmYvUTDXp2Ia7Rgpzh54Mzyhohp6_nUD9XRf5c_7gfK7.V1Hr 0GhNGzHrv09NNPIWbJfheCFq8lL5YNC7p.tXRK2aMSMH.JhEjW6qRKNnWTLi XK212zxz3PlkzL12fOoQy6C1mDDUhh1XsUiYJZZMZky4EfREPn_hP2oE- Received: from [213.205.71.48] by web111501.mail.gq1.yahoo.com via HTTP; Wed, 02 Jun 2010 06:14:27 PDT X-Mailer: YahooMailClassic/11.0.8 YahooMailWebService/0.8.103.269680 Date: Wed, 2 Jun 2010 06:14:27 -0700 (PDT) From: Dario Teixeira Subject: Questions concerning modules as first-class values To: caml-list@yquem.inria.fr MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam: no; 0.00; ocaml:01 ocaml:01 ad-hoc:01 functor:01 higher-order:01 functors:01 functor:01 boolean:01 purely:02 modules:02 modules:02 represented:02 confusing:02 seems:03 module:03 Hi,=0A=0A3.12 will bring modules as first-class values to the Ocaml languag= e. =0AThis is an interesting development whose full range of applications = will=0Asurprise us for many years, I suspect. It also raises a few questio= ns,=0Atwo of which I'll throw to the audience.=0A=0AThe first is purely one= of terminology. The table below describes how up =0Auntil now core "eleme= nts" of the Ocaml language could be described; note the=0Ause of ad-hoc ter= ms such as "value-ish", "module-ish", and even "elements".=0AMoreover, sinc= e modules are now also first-class "values", the terminology =0Ais bound to= get confusing. So, what should the proper names for all these=0A"elements= " be?=0A=0A-------------------------------------------------=0A| = | 0-arity | n-arity (n>0) |=0A-----------------------------------= --------------=0A| Valueish | value | function |=0A| = | | |=0A| Moduleish | module = | functor |=0A-------------------------------------------------=0A= =0A=0ASecond, does the promotion of modules to first-class values also exte= nd to=0Ahigher-order modules, ie, functors? For the sake of symmetry I rec= kon it =0Aought to. As an illustration, consider again the same table, but= extended to=0Aa third dimension indicating with a boolean (T or F) whether= each "element"=0Ais a first-class "value" (the third dimension is represen= ted after a slash). =0AIt seems right that the question mark in the functor= cell should also be a "T".=0ABut is it?=0A=0A-----------------------------= --------------------=0A| | 0-arity | n-arity (n>0) |=0A= -------------------------------------------------=0A| Valueish | value= /T | function/T |=0A| | | = |=0A| Moduleish | module/T | functor/? |=0A-----------------= --------------------------------=0A=0A=0AThanks for your time!=0ABest regar= ds,=0ADario Teixeira=0A=0A=0A=0A