220 4428 <CAOHCbitjW4UTDb3Q=dDc4yZ2qVS6XfvZRKRvjWF8ePYEgiNwog@mail.gmail.com> article
Path: news.gmane.org!not-for-mail
From: Tony V E <tvaneerd@gmail.com>
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: Fixing Standard Library relational operators (was:
 Re: optional Rev.4 (N3672): What was the rationale to remove
 !=, >=, ...)
Date: Wed, 15 May 2013 09:58:39 -0400
Lines: 204
Approved: news@gmane.org
Message-ID: <CAOHCbitjW4UTDb3Q=dDc4yZ2qVS6XfvZRKRvjWF8ePYEgiNwog@mail.gmail.com>
References: <CAGg_6+NTws7QyEAsEUd308yx4LncpD_r6x4yJEJy5RN2w6v2Hw@mail.gmail.com>
	<CAGg_6+PTyNK6rTAdC3NKLOnLR3g0WfyqgNKmHz-9edMOdjnVNA@mail.gmail.com>
	<CAFk2RUZw2wyMrbaRpYzWApeRNp2kx0MK7wurbD09P+D5r_As9w@mail.gmail.com>
	<CAFk2RUbdNQi+qBL2H55nZcZT++t26jREW_2r24yHQq2LcdrQnQ@mail.gmail.com>
	<CAGqM8fY=iZmwKBjLvqimn5d3pAtvLQgKbknPkG6WSYFZ2_OfZw@mail.gmail.com>
	<CAPXezF-kXv6M62uuYBYspcRYg1JwUiSOx04ooeGH-z55APHbGA@mail.gmail.com>
	<CAFk2RUbbkVg5+r47UfkyD0-WTGm9=oi4OKNrX+V8--wN+74J+A@mail.gmail.com>
	<CAPXezF9fYSRtR2pExe=25JpUGvsG_UK9bZFMHcm_HGfCj-hr_w@mail.gmail.com>
	<CAFk2RUZ3iqP-Hrjkf9q_Jy1wd0ZEjyU1D6U4504EOS1C=6+i7A@mail.gmail.com>
	<CAPXezF89r7S7=-wKyet=uy+Y_aeykCgf-WeB_QY3ndVo=VPpwg@mail.gmail.com>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: plane.gmane.org
Mime-Version: 1.0
Content-Type: multipart/alternative; boundary=047d7b3432b89ea7e904dcc22553
X-Trace: ger.gmane.org 1368626322 1425 80.91.229.3 (15 May 2013 13:58:42 GMT)
X-Complaints-To: usenet@ger.gmane.org
NNTP-Posting-Date: Wed, 15 May 2013 13:58:42 +0000 (UTC)
To: std-proposals@isocpp.org
Original-X-From: std-proposals+bncBCUZ5QWKNQIJDKOORQCRUBALGPWYS@isocpp.org Wed May 15 15:58:42 2013
Return-path: <std-proposals+bncBCUZ5QWKNQIJDKOORQCRUBALGPWYS@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-we0-f199.google.com ([74.125.82.199])
	by plane.gmane.org with esmtp (Exim 4.69)
	(envelope-from <std-proposals+bncBCUZ5QWKNQIJDKOORQCRUBALGPWYS@isocpp.org>)
	id 1UccE6-0001Nz-A1
	for gclcip-std-proposals@m.gmane.org; Wed, 15 May 2013 15:58:42 +0200
Original-Received: by mail-we0-f199.google.com with SMTP id p59sf382625wes.2
        for <gclcip-std-proposals@m.gmane.org>; Wed, 15 May 2013 06:58:42 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=20120113;
        h=x-received:x-beenthere:x-received:received-spf:mime-version
         :x-received:in-reply-to:references:date:message-id:subject:from:to
         :x-original-sender:x-original-authentication-results:reply-to
         :precedence:mailing-list:list-id:x-google-group-id:list-post
         :list-help:list-archive:list-subscribe:list-unsubscribe:content-type;
        bh=Zk4dXtkaHRkkDuKK66AQGXLCF9xWSWHxu+UOcoxRYmc=;
        b=UWUNfe1+qa3LdarUJVneaAFSNYEetO40Wz+3D+cWv6JbyNUhLUUxVgegF0En92zs8C
         JjnCJUjyvrsElhR4fOKo0Zh885qIZd7smKTX8km4cSQ8kOvAkMB4BJl1weahI1oHHkPv
         uJ6t2y1bVVzGIFnvRuO0gz309diGaA8XNALCYNMz/XBEGh8vpXhG3s0ZjWWhFT+KVg3r
         DTbuxp5eFS1HG+9RroOpz2FBM67LzdKwM31IsaRKfYGd23oI0rfXk/qI0p9iAi382RSv
         GcLMPdEu/hi4u+xfoInJzoczSJfpe2QfcL3e8KX/pGxtR7wd0lhJiuuqOgrpfT1XYiur
  
X-Received: by 10.112.180.197 with SMTP id dq5mr11355998lbc.14.1368626321502;
        Wed, 15 May 2013 06:58:41 -0700 (PDT)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.152.6.39 with SMTP id x7ls55255lax.14.gmail; Wed, 15 May 2013
 06:58:40 -0700 (PDT)
X-Received: by 10.152.120.40 with SMTP id kz8mr18034964lab.30.1368626320129;
        Wed, 15 May 2013 06:58:40 -0700 (PDT)
Original-Received: from mail-la0-x234.google.com (mail-la0-x234.google.com [2a00:1450:4010:c03::234])
        by mx.google.com with ESMTPS id u6si1120312lbu.10.2013.05.15.06.58.40
        for <std-proposals@isocpp.org>
        (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128);
        Wed, 15 May 2013 06:58:40 -0700 (PDT)
Received-SPF: pass (google.com: domain of tvaneerd@gmail.com designates 2a00:1450:4010:c03::234 as permitted sender) client-ip=2a00:1450:4010:c03::234;
Original-Received: by mail-la0-f52.google.com with SMTP id fo13so1800491lab.11
        for <std-proposals@isocpp.org>; Wed, 15 May 2013 06:58:40 -0700 (PDT)
X-Received: by 10.112.145.72 with SMTP id ss8mr17899809lbb.12.1368626319761;
 Wed, 15 May 2013 06:58:39 -0700 (PDT)
Original-Received: by 10.112.143.37 with HTTP; Wed, 15 May 2013 06:58:39 -0700 (PDT)
In-Reply-To: <CAPXezF89r7S7=-wKyet=uy+Y_aeykCgf-WeB_QY3ndVo=VPpwg@mail.gmail.com>
X-Original-Sender: tvaneerd@gmail.com
X-Original-Authentication-Results: mx.google.com;       spf=pass (google.com:
 domain of tvaneerd@gmail.com designates 2a00:1450:4010:c03::234 as permitted
 sender) smtp.mail=tvaneerd@gmail.com;       dkim=pass header.i=@gmail.com
Precedence: list
Mailing-list: list std-proposals@isocpp.org; contact std-proposals+owners@isocpp.org
List-ID: <std-proposals.isocpp.org>
X-Google-Group-Id: 399137483710
List-Post: <http://groups.google.com/a/isocpp.org/group/std-proposals/post?hl=en>,
 <mailto:std-proposals@isocpp.org>
List-Help: <http://support.google.com/a/isocpp.org/bin/topic.py?hl=en&topic=25838>,
 <mailto:std-proposals+help@isocpp.org>
List-Archive: <http://groups.google.com/a/isocpp.org/group/std-proposals/?hl=en>
List-Subscribe: <http://groups.google.com/a/isocpp.org/group/std-proposals/subscribe?hl=en>,
 <mailto:std-proposals+subscribe@isocpp.org>
List-Unsubscribe: <http://groups.google.com/a/isocpp.org/group/std-proposals/subscribe?hl=en>,
 <mailto:googlegroups-manage+399137483710+unsubscribe@googlegroups.com>
Xref: news.gmane.org gmane.comp.lang.c++.isocpp.proposals:4428
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/4428>

--047d7b3432b89ea7e904dcc22553
Content-Type: text/plain; charset=ISO-8859-1

On Wed, May 15, 2013 at 8:30 AM, Fernando Cacciola <
fernando.cacciola@gmail.com> wrote:

> On Wed, May 15, 2013 at 9:25 AM, Ville Voutilainen <
> ville.voutilainen@gmail.com> wrote:
>
>>
>>
>>
>> On 15 May 2013 15:20, Fernando Cacciola <fernando.cacciola@gmail.com>wrote:
>>
>>> I did a little bit of further homework on the matter. boost::tuple does
>>> NOT synthesize the comparison operators,
>>>
>>>> but rather calls the operator of the underlying type. The existing
>>>> practice isn't consistent. ;)
>>>>
>>>> This needs at least an overview paper. I'd be willing to entertain the
>>>> idea to propose making all relational
>>>> operators, including tuple and containers, to not synthesize. I suppose
>>>> the fallback plans are synthesize-for-all
>>>> and deliberately-inconsistent, not necessarily in any preference order.
>>>>
>>>> In addition to that, tuples and containers would seemingly need
>>>> std::less specializations. That's actually somewhat separate.
>>>>
>>>> Fernando, Tony, would you be interested in coauthoring?
>>>>
>>>
>>> Now that I am much more convinced that the right approach is to not
>>> synthesize (consistently across the whole library), I would definitely like
>>> to coauthor such a paper!
>>>
>>>
>>>
>> For you, and Tony too, I want to include the "fallback" options in the
>> paper. According to what Nevin said,
>> people may already rely on the existing synthesizing, so the outcome is
>> not easy to predict. At a minimum,
>> I'll live with whatever the decision will be, at least we have voiced the
>> concerns with the paper.
>>
>> Agreed.
>
>>

Since I was planning on writing a paper or two about this anyhow, I will
definitely help.

I think the best fallback plan is that in the case where T *does not have*
an operator>, the tuple will still generate one, (if T *does* have > that
it is used). So any existing code that wouldn't compile without
synthesizing will still work. (If T had inconsistent operators, they get a
behaviour change due to no longer synthesizing.)

But I'd like to consider that a (partial) backwards compatibility hack, and
not have optional support that behaviour. ie I'd rather have optional >
fail to compile if you don't have the underlying operator.

I'd prefer if as much as possible each issue was a separate paper.
 Optional operator> separate from optional std::less.  tuple/pair separate
from optional.

Tony

-- 

--- 
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposals/?hl=en.



--047d7b3432b89ea7e904dcc22553
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><br><div class=3D"gmail_extra"><br><br><div class=3D"gmail=
_quote">On Wed, May 15, 2013 at 8:30 AM, Fernando Cacciola <span dir=3D"ltr=
">&lt;<a href=3D"mailto:fernando.cacciola@gmail.com" target=3D"_blank">fern=
ando.cacciola@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p=
x #ccc solid;padding-left:1ex"><div dir=3D"ltr"><div class=3D"gmail_extra">=
<div class=3D"gmail_quote"><div class=3D"im">On Wed, May 15, 2013 at 9:25 A=
M, Ville Voutilainen <span dir=3D"ltr">&lt;<a href=3D"mailto:ville.voutilai=
nen@gmail.com" target=3D"_blank">ville.voutilainen@gmail.com</a>&gt;</span>=
 wrote:<br>


<blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p=
x #ccc solid;padding-left:1ex"><div dir=3D"ltr"><br><div class=3D"gmail_ext=
ra"><br><br><div class=3D"gmail_quote"><div>On 15 May 2013 15:20, Fernando =
Cacciola <span dir=3D"ltr">&lt;<a href=3D"mailto:fernando.cacciola@gmail.co=
m" target=3D"_blank">fernando.cacciola@gmail.com</a>&gt;</span> wrote:<br>



<blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p=
x #ccc solid;padding-left:1ex"><div dir=3D"ltr"><div class=3D"gmail_extra">=
<div class=3D"gmail_quote"><div><div>I did a little bit of further homework=
 on the matter. boost::tuple does NOT synthesize the comparison operators,<=
br>



<blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p=
x #ccc solid;padding-left:1ex"><div dir=3D"ltr"><div class=3D"gmail_extra">=
<div class=3D"gmail_quote"><div>but rather calls the operator of the underl=
ying type. The existing practice isn&#39;t consistent. ;)<br>






<br></div><div>This needs at least an overview paper. I&#39;d be willing to=
 entertain the idea to propose making all relational<br>operators, includin=
g tuple and containers, to not synthesize. I suppose the fallback plans are=
 synthesize-for-all<br>






and deliberately-inconsistent, not necessarily in any preference order.<br>=
<br></div></div>In addition to that, tuples and containers would seemingly =
need std::less specializations. That&#39;s actually somewhat separate.<br>






<br></div><div class=3D"gmail_extra">Fernando, Tony, would you be intereste=
d in coauthoring?<br></div></div></blockquote><div><br></div></div></div><d=
iv>Now that I am much more convinced that the right approach is to not synt=
hesize (consistently across the whole library), I would definitely like to =
coauthor such a paper!<br>





<br><br></div></div></div></div></blockquote><div><br></div></div><div>For =
you, and Tony too, I want to include the &quot;fallback&quot; options in th=
e paper. According to what Nevin said,<br></div><div>people may already rel=
y on the existing synthesizing, so the outcome is not easy to predict. At a=
 minimum,<br>



</div><div>I&#39;ll live with whatever the decision will be, at least we ha=
ve voiced the concerns with the paper.<br></div></div><br></div></div></blo=
ckquote></div><div>Agreed. <br></div><blockquote class=3D"gmail_quote" styl=
e=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


<div><div>

</div></div></blockquote></div></div></div></blockquote></div><br></div><di=
v class=3D"gmail_extra"><br></div><div class=3D"gmail_extra">Since I was pl=
anning on writing a paper or two about this anyhow, I will definitely help.=
</div>
<div class=3D"gmail_extra"><br></div><div class=3D"gmail_extra">I think the=
 best fallback plan is that in the case where T *does not have* an operator=
&gt;, the tuple will still generate one, (if T *does* have &gt; that it is =
used). So any existing code that wouldn&#39;t compile without synthesizing =
will still work. (If T had inconsistent operators, they get a behaviour cha=
nge due to no longer synthesizing.)</div>
<div class=3D"gmail_extra"><br></div><div class=3D"gmail_extra">But I&#39;d=
 like to consider that a (partial) backwards compatibility hack, and not ha=
ve optional support that behaviour. ie I&#39;d rather have optional &gt; fa=
il to compile if you don&#39;t have the underlying operator.</div>
<div class=3D"gmail_extra"><br></div><div class=3D"gmail_extra">I&#39;d pre=
fer if as much as possible each issue was a separate paper. =A0Optional ope=
rator&gt; separate from optional std::less. =A0tuple/pair separate from opt=
ional.<br>
</div><div class=3D"gmail_extra"><br></div><div class=3D"gmail_extra">Tony<=
/div><div class=3D"gmail_extra"><br></div></div>

<p></p>

-- <br />
&nbsp;<br />
--- <br />
You received this message because you are subscribed to the Google Groups &=
quot;ISO C++ Standard - Future Proposals&quot; group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to std-proposals+unsubscribe@isocpp.org.<br />
To post to this group, send email to std-proposals@isocpp.org.<br />
Visit this group at <a href=3D"http://groups.google.com/a/isocpp.org/group/=
std-proposals/?hl=3Den">http://groups.google.com/a/isocpp.org/group/std-pro=
posals/?hl=3Den</a>.<br />
&nbsp;<br />
&nbsp;<br />

--047d7b3432b89ea7e904dcc22553--

.
