From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by walapai.inria.fr (8.13.6/8.13.6) with ESMTP id p0R0gGtF026951 for ; Thu, 27 Jan 2011 01:42:16 +0100 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AsQKAK5NQE1V2gB4Zmdsb2JhbAClEA0LCAgSJLxFDYVCBJAK X-IronPort-AV: E=Sophos;i="4.60,383,1291590000"; d="scan'208";a="74295693" Received: from emailfrontal1.citycable.ch ([85.218.0.120]) by mail3-smtp-sop.national.inria.fr with SMTP; 27 Jan 2011 01:42:11 +0100 X-Alinto-smtpauth-localdomain: Yes Received: from seldon (unknown [85.218.92.99]) (Authenticated sender: guillaume.yziquel@citycable.ch) by emailfrontal1.citycable.ch (Postfix) with ESMTPA id C431612C1D9; Thu, 27 Jan 2011 01:42:09 +0100 (CET) Received: from yziquel by seldon with local (Exim 4.72) (envelope-from ) id 1PiFvA-0002ep-Pq; Thu, 27 Jan 2011 01:41:09 +0100 Date: Thu, 27 Jan 2011 01:41:08 +0100 From: Guillaume Yziquel To: Raoul Duke Cc: OCaml Message-ID: <20110127004107.GO4195@localhost> References: <20110127000058.GN4195@localhost> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.20 (2009-06-14) Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by walapai.inria.fr id p0R0gGtF026951 Subject: Re: [Caml-list] return type annotation syntax? Le Wednesday 26 Jan 2011 à 16:12:40 (-0800), Raoul Duke a écrit : > On Wed, Jan 26, 2011 at 4:01 PM, Guillaume Yziquel > > > let f (x : input_typ) : return_type = ... > > oh, thanks! i was trying to use "->" in there somewhere just doing > lame human pattern matching on what the repl prints as types for > things, and i even saw "->" in the ocaml grammar spec for types so i > was figuring the "->" was to be used. :-P Well, you can always write let f : input_type -> output_type = function x -> ... -- Guillaume Yziquel