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 XAA01981; Sat, 23 Oct 2004 23:35:57 +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 XAA02290 for ; Sat, 23 Oct 2004 23:35:56 +0200 (MET DST) Received: from maury.inria.fr (maury.inria.fr [192.93.2.7]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id i9NLZtAF022387 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL) for ; Sat, 23 Oct 2004 23:35:56 +0200 Received: from rproxy.gmail.com (rproxy.gmail.com [64.233.170.199]) by maury.inria.fr (8.13.0/8.13.0) with ESMTP id i9NLZsob002532 for ; Sat, 23 Oct 2004 23:35:55 +0200 Received: by rproxy.gmail.com with SMTP id 79so245068rnk for ; Sat, 23 Oct 2004 14:33:54 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:references; b=d5Zof9QSFXuIsaHVL5BHJgkSWMmJ/zhRl34an6mus/TWIx1yw8Krg6xTVKDtwVpiIwrrILbSqM0CEhk2Nas3FFgT0VT6o3+FrGJ/BoRf2/s5oZX+UPJkVQ1h71HNJ+v9h4aYbBiQo87f1Mwqo048RV8pUm0W06bMXAnM9UjHbak= Received: by 10.38.171.37 with SMTP id t37mr380241rne; Sat, 23 Oct 2004 14:33:54 -0700 (PDT) Received: by 10.38.65.58 with HTTP; Sat, 23 Oct 2004 14:33:54 -0700 (PDT) Message-ID: Date: Sat, 23 Oct 2004 14:33:54 -0700 From: Nathaniel Gray Reply-To: Nathaniel Gray To: Jacques Garrigue Subject: Re: [Caml-list] Single-case union types as strong typedefs Cc: caml-list@inria.fr In-Reply-To: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit References: <20041023.123139.106410806.garrigue@kurims.kyoto-u.ac.jp> X-Miltered: at nez-perce with ID 417ACEBB.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at maury with ID 417ACEBA.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Loop: caml-list@inria.fr X-Spam: no; 0.00; caml-list:01 typedefs:01 2004:99 2004:99 jacques:01 unlucky:01 boxing:01 1,3:01 1,3:01 inches:99 0700,:01 garrigue:01 garrigue:01 caltech:01 caltech:01 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk On Sat, 23 Oct 2004 14:24:28 -0700, Nathaniel Gray wrote: > On Sat, 23 Oct 2004 12:31:39 +0900 (JST), Jacques Garrigue > wrote: > > > Unlucky! > > With your example, there is no extra boxing involved. > > I.e. (1,3) and Rpos(1,3) and Apos(1,3) all share the same physical > > representation (a block with 2 fields). > > The problem you describe only occurs when your single constructor has > > only one argument. > > Really?? You're kidding. That's kind of cool but kind of strange -- > why does it only optimize for composite types? Never mind. After thinking about it for a minute I understand -- it's not an optimization, it's just the normal physical representation. That's what I get for changing my example at the last minute -- originally it was inches vs. centimeters. :-) Cheers, -n8 -- >>>-- Nathaniel Gray -- Caltech Computer Science ------> >>>-- Mojave Project -- http://mojave.cs.caltech.edu --> ------------------- 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