From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id LAA06336; Mon, 29 Mar 2004 11:56:34 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id LAA07215 for ; Mon, 29 Mar 2004 11:56:33 +0200 (MET DST) Received: from out2.smtp.messagingengine.com (out2.smtp.messagingengine.com [66.111.4.26]) by nez-perce.inria.fr (8.12.10/8.12.10) with ESMTP id i2T9vEKW022966 for ; Mon, 29 Mar 2004 11:57:14 +0200 X-Sasl-enc: PXX5m7ywTt4rtUTjI0mDjw 1080554045 Received: from [192.168.1.100] (unknown [218.81.127.227]) by mail.messagingengine.com (Postfix) with ESMTP id 2987B8B60B7; Mon, 29 Mar 2004 04:54:04 -0500 (EST) Date: Mon, 29 Mar 2004 17:53:56 +0800 (HKT) From: Martin Jambon X-X-Sender: martin@localhost To: fis@wiwi.hu-berlin.de Cc: caml-list@inria.fr Subject: Re: [Caml-list] [Q] explicit typing again In-Reply-To: <16487.60787.223815.927390@gargle.gargle.HOWL> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Miltered: at nez-perce by Joe's j-chkmail ("http://j-chkmail.ensmp.fr")! X-Loop: caml-list@inria.fr X-Spam: no; 0.00; caml-list:01 2004:99 annotate:01 val:01 val:01 htmlman:01 ocaml:01 caml:01 int:01 int:01 jambon:02 jambon:02 explicit:03 explicit:03 typing:03 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk X-Status: X-Keywords: X-UID: 408 On Mon, 29 Mar 2004 fis@wiwi.hu-berlin.de wrote: > hi, > > sorry, but i am really enthusiastic about explicit typing. i will > probably start to annotate expressions like "3" soon... (-: > > could anybody tell me how i get this one straight? > > # let (a: int, b) = (1, 3) in a;; > # let (a, b) : int * int = (1, 3) in a;; # let (a : int), b = 1, 2;; val a : int = 1 val b : int = 2 # let (a, b : int * int) = 1, 2;; val a : int = 1 val b : int = 2 You can add more ( ) around tuples, but here you don't really define tuples. In theory, you could find all this information here: http://caml.inria.fr/ocaml/htmlman/manual008.html Martin ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners