From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by sympa.inria.fr (Postfix) with ESMTPS id CCBC7820A1 for ; Thu, 5 Sep 2013 04:32:01 +0200 (CEST) Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of anthony.tavener@gmail.com) identity=pra; client-ip=209.85.215.169; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="anthony.tavener@gmail.com"; x-sender="anthony.tavener@gmail.com"; x-conformance=sidf_compatible Received-SPF: Pass (mail2-smtp-roc.national.inria.fr: domain of anthony.tavener@gmail.com designates 209.85.215.169 as permitted sender) identity=mailfrom; client-ip=209.85.215.169; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="anthony.tavener@gmail.com"; x-sender="anthony.tavener@gmail.com"; x-conformance=sidf_compatible; x-record-type="v=spf1" Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of postmaster@mail-ea0-f169.google.com) identity=helo; client-ip=209.85.215.169; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="anthony.tavener@gmail.com"; x-sender="postmaster@mail-ea0-f169.google.com"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AqYBAPPsJ1LRVdepk2dsb2JhbABbhA3BRoEiCBYOAQEBAQcLCwkUBCSCJAEBBAFAARsdAQMBCwYFBAEGDS4iAREBBQEcBhOHbwEDCQacN4xQgwWEMwoZJw1kiDsBBQyPVAeEHQOJNYpmg1qKP4U+GCmEZx0 X-IPAS-Result: AqYBAPPsJ1LRVdepk2dsb2JhbABbhA3BRoEiCBYOAQEBAQcLCwkUBCSCJAEBBAFAARsdAQMBCwYFBAEGDS4iAREBBQEcBhOHbwEDCQacN4xQgwWEMwoZJw1kiDsBBQyPVAeEHQOJNYpmg1qKP4U+GCmEZx0 X-IronPort-AV: E=Sophos;i="4.90,843,1371074400"; d="scan'208";a="31539233" Received: from mail-ea0-f169.google.com ([209.85.215.169]) by mail2-smtp-roc.national.inria.fr with ESMTP/TLS/RC4-SHA; 05 Sep 2013 04:31:57 +0200 Received: by mail-ea0-f169.google.com with SMTP id k11so578392eaj.28 for ; Wed, 04 Sep 2013 19:31:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=ORkmj3tDKKeQ9282YeSfE8hi+0GWD/KgEanmRD2ul44=; b=ZHoQ3b+cSVVMjPfvM/RRBuWyZV3n8Pr4/mZEnzS4FYYadtPDOgViijV56s+SIoehop cMx7SIRyAqemh3KhuMVfcPu/8fRnfXVWLvGpxuN45A+/WPo0vtV3YFG8JxC799qQeGKZ MKNyWv2FgyjxXsGV9tEniIY/vVXC0SYPbXoICr8fH0t7UKd6BFUGRklalmFFcRL0zqAl gzB3HagsVdKKnlZjROGEaUQEUWtMXijnRLYGGBjCfiGJkordCmi1NiNEG6QQXEDQmuhX 02f476ITb3/UcsUI3kNlTer/kR07PmBWmrQUiwajIkRrPvf+tEN8uBbt+WbQhCk7Xgci yo/A== MIME-Version: 1.0 X-Received: by 10.14.225.199 with SMTP id z47mr9588428eep.24.1378348317697; Wed, 04 Sep 2013 19:31:57 -0700 (PDT) Received: by 10.14.10.68 with HTTP; Wed, 4 Sep 2013 19:31:57 -0700 (PDT) In-Reply-To: <5227E9FA.1020301@riken.jp> References: <5227E9FA.1020301@riken.jp> Date: Wed, 4 Sep 2013 20:31:57 -0600 Message-ID: From: Anthony Tavener To: Francois Berenger Cc: "caml-list@inria.fr" Content-Type: multipart/alternative; boundary=047d7b66fc0fda897f04e599b95d Subject: Re: [Caml-list] Stability of order between polymorphic variants --047d7b66fc0fda897f04e599b95d Content-Type: text/plain; charset=ISO-8859-1 On Wed, Sep 4, 2013 at 8:18 PM, Francois Berenger wrote: > On 09/05/2013 11:11 AM, Anthony Tavener wrote: > >> Addendum: On a 32b arch, those names will wrap. >> > > Why not write a to_int for your type > and then a specialized comparator using it? > A sane suggestion. :) Daniel might not want to write an explicit mapping to int if these weight types grow in number? And I need to correct my addendum. I now realize the multiplier of 223 would still fit a 4-character name in 30bits, given that the first char must be a capital letter. So I'm guessing you're already aware of all this, Daniel, and just wanted to know if there is likelihood of the calculation changing. That I know nothing about. Sorry for the noise! --047d7b66fc0fda897f04e599b95d Content-Type: text/html; charset=ISO-8859-1



On Wed, Sep 4, 2013 at 8:18 PM, Francois Berenger <berenger@riken.jp> wrote:
On 09/05/2013 11:11 AM, Anthony Tavener wrote:
Addendum: On a 32b arch, those names will wrap.

Why not write a to_int for your type
and then a specialized comparator using it?

A sane suggestion. :) Daniel might not want to write an explicit mapping to int if these
weight types grow in number?

And I need to correct my addendum. I now realize the multiplier of 223 would still fit a
4-character name in 30bits, given that the first char must be a capital letter. So I'm
guessing you're already aware of all this, Daniel, and just wanted to know if there is
likelihood of the calculation changing. That I know nothing about. Sorry for the noise!
--047d7b66fc0fda897f04e599b95d--