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=2.1 required=5.0 tests=AWL,DNS_FROM_RFC_POST, SPF_NEUTRAL autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by yquem.inria.fr (Postfix) with ESMTP id 1C2FDBBAF for ; Tue, 6 Oct 2009 15:50:29 +0200 (CEST) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AtkBALXnykrRVdvZkGdsb2JhbACBUJhoPwEBAQEJCQwHEwNEAwECqDMBBY8XAQaEKoFXhmw X-IronPort-AV: E=Sophos;i="4.44,513,1249250400"; d="scan'208";a="34348410" Received: from mail-ew0-f217.google.com ([209.85.219.217]) by mail2-smtp-roc.national.inria.fr with ESMTP; 06 Oct 2009 15:50:28 +0200 Received: by ewy17 with SMTP id 17so4334444ewy.15 for ; Tue, 06 Oct 2009 06:50:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:received:received:sender:message-id:date:from :reply-to:user-agent:mime-version:to:subject:references:in-reply-to :content-type:content-transfer-encoding; bh=dauy5vOhvf4de7kH3otz5IgjFEdTjsMKgGHcgRw/Ne0=; b=G1L0lRkbFly6PLbT6WPPADf84EsRdTc2lCoNj8A+4okpvWy2oF6bRRwMkc4r2KEnRg pz/dRK4pm4HlB8GMGzKM84kW9ZHZoW2+9OUYgPSbcb7Q6NKgak8xf96FfDBMv/PBHGo5 Xw/Lft/7fvGQsAVwfMW7f0o5vn1cEPAoImVJs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=sender:message-id:date:from:reply-to:user-agent:mime-version:to :subject:references:in-reply-to:content-type :content-transfer-encoding; b=b3POwq7z1G3jZRft0cOKLM4aVmEMKiR4Bg9/HVtfJWn2sbSXtrWkXDg1SWDJZnR/06 MhyXXgcsD8GprOr4C3H40j51fC8bBASfy1gisSn020iZUTQk3WZKx6VPMzMPj7WNozmy WhgxbQS90+2UrhZFy9xYa93di3MKTpINBvyk0= Received: by 10.216.38.76 with SMTP id z54mr326414wea.40.1254837028414; Tue, 06 Oct 2009 06:50:28 -0700 (PDT) Received: from mm.mauny.lan (ks23009.kimsufi.com [91.121.9.195]) by mx.google.com with ESMTPS id 10sm65947eyd.8.2009.10.06.06.50.25 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 06 Oct 2009 06:50:27 -0700 (PDT) Sender: Michel Mauny Message-ID: <4ACB4B58.3030606@inria.fr> Date: Tue, 06 Oct 2009 15:51:20 +0200 From: Michel Mauny Reply-To: Michel.Mauny@inria.fr User-Agent: Mozilla/5.0 (X11; U; Linux i686; fr; rv:1.8.1.6) Gecko/20070728 Thunderbird/2.0.0.6 Mnenhy/0.7.5.0 MIME-Version: 1.0 To: 'caml-list' Subject: Re: [Caml-list] Constructors are not functions References: <4ACB319A.1080608@wanadoo.fr> <003901ca4682$d47f8460$7d7e8d20$@metastack.com> <4ACB42BC.1050603@gmail.com> In-Reply-To: <4ACB42BC.1050603@gmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam: no; 0.00; mauny:01 mauny:01 constructors:01 simulate:01 ocaml:01 camlp:01 foo:01 syntax:01 2009:98 sml:01 unbound:01 wrote:01 michel:01 michel:01 caml-list:01 Jim Farrand écrit/writes [06/10/2009 15:14] : > David Allsopp wrote: > >> I think it would be possible to simulate the SML behaviour in OCaml >> using camlp4 (if you assume that for [type foo = Bar of int] that >> future unbound references to [bar] are interpreted as [fun x -> bar x] >> instead of an error) > > I believe this is already the behaviour under the revised syntax, No it is not: # type t = [ C of int and int ]; type t = [ C of int and int ] # C; Error: The constructor C expects 2 argument(s), but is here applied to 0 argument(s) -- Michel Mauny