220 19223 <CALQmNFh24WJVMic7LZHE46q1saQ3TBXhST0juCCx2Bj_fb2pZQ@mail.gmail.com> article
Path: news.gmane.org!not-for-mail
From: Sean Middleditch <sean@middleditch.us>
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: Re: Overloading std::begin and std::end for std::pair
Date: Thu, 23 Jul 2015 15:26:59 -0700
Lines: 105
Approved: news@gmane.org
Message-ID: <CALQmNFh24WJVMic7LZHE46q1saQ3TBXhST0juCCx2Bj_fb2pZQ@mail.gmail.com>
References: <012fd35d-96fd-4775-835e-2105176c4f97@isocpp.org>
	<dc79f59b-77d2-45f6-96ad-50c704cb873d@isocpp.org>
	<70492682-c1ac-4d67-9c00-fe8d841aae63@isocpp.org>
	<f4f76dbb-96d2-432f-82ed-0df45658f72c@isocpp.org>
	<424cd221-d1c7-4baf-b074-b7f44ee5c82e@isocpp.org>
	<58625b71-98be-4acb-9815-af1ec2113cc6@isocpp.org>
	<ae00798f-2944-44ae-a526-4b8e2aeba2ac@isocpp.org>
	<CALQmNFi4R=od29BMMYyOL=6aHv=PoqjaGi_ykvGQD5SJ4ctonQ@mail.gmail.com>
	<f8707372-73ad-4e74-bd5a-caf79b6c361f@isocpp.org>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: plane.gmane.org
Mime-Version: 1.0
Content-Type: multipart/alternative; boundary=089e010d8358c3d37d051b92628f
X-Trace: ger.gmane.org 1437690427 31892 80.91.229.3 (23 Jul 2015 22:27:07 GMT)
X-Complaints-To: usenet@ger.gmane.org
NNTP-Posting-Date: Thu, 23 Jul 2015 22:27:07 +0000 (UTC)
To: std-proposals@isocpp.org
Original-X-From: std-proposals+bncBCDODCNR2QPRBNGUYWWQKGQEZ3UASIY@isocpp.org Fri Jul 24 00:27:05 2015
Return-path: <std-proposals+bncBCDODCNR2QPRBNGUYWWQKGQEZ3UASIY@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-wi0-f200.google.com ([209.85.212.200])
	by plane.gmane.org with esmtp (Exim 4.69)
	(envelope-from <std-proposals+bncBCDODCNR2QPRBNGUYWWQKGQEZ3UASIY@isocpp.org>)
	id 1ZIOxC-0004sZ-L5
	for gclcip-std-proposals@m.gmane.org; Fri, 24 Jul 2015 00:27:02 +0200
Original-Received: by wixh2 with SMTP id h2sf797950wix.0
        for <gclcip-std-proposals@m.gmane.org>; Thu, 23 Jul 2015 15:27:01 -0700 (PDT)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20130820;
        h=x-gm-message-state:mime-version:sender:in-reply-to:references:date
         :message-id:subject:from:to:content-type:x-original-sender
         :x-original-authentication-results:reply-to:precedence:mailing-list
         :list-id:x-spam-checked-in-group:list-post:list-help:list-archive
         :list-subscribe:list-unsubscribe;
        bh=3apd4iDJw3NP1fDNGSGVO7BUrZWi0pskYpPlu0HQZEU=;
        b=HdYutM0r10pobpcWq/F5RSC9ICvAxqGwk3iJKIRCBkWtzW5O+pdlRAWlAnWH78/3lT
         whUGnHC8Pv0NrMr5gO6aUOBZA2NDYyAdjYcvz6SOi3C+iSyQ+0dr1rQ34igjSJRb/T/e
         nhRXhUnwXbvKy98B6i4YT+cxRNB+Ah2/ijzHCi0HBBIYjWxfgGbH2mPvHQuEr8w91at6
         wEll/9rMQ8J4lsPpUoct8M8H2El8Cjocs6YYcrDU0Cs/S6urV426hgT7K5GaqWERZnb9
         rPGbO6iUEhDyEgP77OQrqd9gxW5SmjHHHe2smwKxSOAp7yc4BvNbH7dbXO0DwoyQEaaX
         Y48A==
X-Gm-Message-State: ALoCoQm4SeBl9FFkDiCN+EiTvl6j89WLEwZsbr5lDGZRRlhtqUgB64KDhG7rMrDdpzq8w8jt7h7H
X-Received: by 10.194.188.104 with SMTP id fz8mr4769534wjc.1.1437690421808;
        Thu, 23 Jul 2015 15:27:01 -0700 (PDT)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.180.77.165 with SMTP id t5ls19529wiw.8.gmail; Thu, 23 Jul 2015
 15:27:00 -0700 (PDT)
X-Received: by 10.180.24.165 with SMTP id v5mr864607wif.63.1437690420193;
        Thu, 23 Jul 2015 15:27:00 -0700 (PDT)
Original-Received: from mail-wi0-x22a.google.com (mail-wi0-x22a.google.com. [2a00:1450:400c:c05::22a])
        by mx.google.com with ESMTPS id pp7si11052972wjc.156.2015.07.23.15.27.00
        for <std-proposals@isocpp.org>
        (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
        Thu, 23 Jul 2015 15:27:00 -0700 (PDT)
Received-SPF: pass (google.com: domain of sean.middleditch@gmail.com designates 2a00:1450:400c:c05::22a as permitted sender) client-ip=2a00:1450:400c:c05::22a;
Original-Received: by wibxm9 with SMTP id xm9so3785133wib.1
        for <std-proposals@isocpp.org>; Thu, 23 Jul 2015 15:26:59 -0700 (PDT)
X-Received: by 10.194.85.130 with SMTP id h2mr21712626wjz.2.1437690419726;
 Thu, 23 Jul 2015 15:26:59 -0700 (PDT)
Original-Sender: sean.middleditch@gmail.com
Original-Received: by 10.27.86.148 with HTTP; Thu, 23 Jul 2015 15:26:59 -0700 (PDT)
Original-Received: by 10.27.86.148 with HTTP; Thu, 23 Jul 2015 15:26:59 -0700 (PDT)
In-Reply-To: <f8707372-73ad-4e74-bd5a-caf79b6c361f@isocpp.org>
X-Original-Sender: sean@middleditch.us
X-Original-Authentication-Results: mx.google.com;       spf=pass (google.com:
 domain of sean.middleditch@gmail.com designates 2a00:1450:400c:c05::22a as
 permitted sender) smtp.mail=sean.middleditch@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-Spam-Checked-In-Group: std-proposals@isocpp.org
X-Google-Group-Id: 399137483710
List-Post: <http://groups.google.com/a/isocpp.org/group/std-proposals/post>, <mailto:std-proposals@isocpp.org>
List-Help: <http://support.google.com/a/isocpp.org/bin/topic.py?topic=25838>, <mailto:std-proposals+help@isocpp.org>
List-Archive: <http://groups.google.com/a/isocpp.org/group/std-proposals/>
List-Subscribe: <http://groups.google.com/a/isocpp.org/group/std-proposals/subscribe>,
 <mailto:std-proposals+subscribe@isocpp.org>
List-Unsubscribe: <mailto:googlegroups-manage+399137483710+unsubscribe@googlegroups.com>,
 <http://groups.google.com/a/isocpp.org/group/std-proposals/subscribe>
Xref: news.gmane.org gmane.comp.lang.c++.isocpp.proposals:19223
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/19223>

--089e010d8358c3d37d051b92628f
Content-Type: text/plain; charset=UTF-8

On Jul 23, 2015 1:13 PM, "Vlad from Moscow" <vlad.moscow@mail.ru> wrote:
>
>
>
> On Thursday, July 23, 2015 at 10:57:30 PM UTC+3, Sean Middleditch wrote:
> I am sorry but this has no any great sense. As I said early you can use
any two iterators by mistake that do not make a range with any algorithm.
For example what does prevent you to write

Which requires explicitly trying to contort iterators into undefined
behavior, rather than having the library itself legitimize the UB by
providing out of the box bogus operators that pretend all pairs of
iterators are iterable ranges, which they aren't, even in the existing
standard usage.

Good interface design means avoiding handing the user a loaded shotgun
pointed at their feet, even if the user is able to load and clumsily aim
one themselves. Make it easier to do the right thing than it is to do the
wrong thing.

>>
>> We can't retroactively change return types without breaking
>> compatibility (probably), but the ranges will facilitate either adding
>> new member functions/algorithms if not an entirely new STL (with
>> concepts + ranges).
>>
> That is where ranges is not neeed you want to litter the STL with ranges.

It is most certainly not just me who wants that. I'm just informing you of
directions things are already moving towards. :)

You even want it, according to this thread. You just want "range" to be
spelled "pair of iterators" which is where the contention arises. :p

-- 

--- 
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/.

--089e010d8358c3d37d051b92628f
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<p dir=3D"ltr"><br>
On Jul 23, 2015 1:13 PM, &quot;Vlad from Moscow&quot; &lt;<a href=3D"mailto=
:vlad.moscow@mail.ru">vlad.moscow@mail.ru</a>&gt; wrote:<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt; On Thursday, July 23, 2015 at 10:57:30 PM UTC+3, Sean Middleditch wrot=
e:<br>
&gt; I am sorry but this has no any great sense. As I said early you can us=
e any two iterators by mistake that do not make a range with any algorithm.=
 For example what=C2=A0does prevent you to write</p>
<p dir=3D"ltr">Which requires explicitly trying to contort iterators into u=
ndefined behavior, rather than having the library itself legitimize the UB =
by providing out of the box bogus operators that pretend all pairs of itera=
tors are iterable ranges, which they aren&#39;t, even in the existing stand=
ard usage.</p>
<p dir=3D"ltr">Good interface design means avoiding handing the user a load=
ed shotgun pointed at their feet, even if the user is able to load and clum=
sily aim one themselves. Make it easier to do the right thing than it is to=
 do the wrong thing.</p>
<p dir=3D"ltr">&gt;&gt;<br>
&gt;&gt; We can&#39;t retroactively change return types without breaking <b=
r>
&gt;&gt; compatibility (probably), but the ranges will facilitate either ad=
ding <br>
&gt;&gt; new member functions/algorithms if not an entirely new STL (with <=
br>
&gt;&gt; concepts + ranges). <br>
&gt;&gt;<br>
&gt; That is where ranges is not neeed you want to litter the STL with rang=
es.</p>
<p dir=3D"ltr">It is most certainly not just me who wants that. I&#39;m jus=
t informing you of directions things are already moving towards. :)</p>
<p dir=3D"ltr">You even want it, according to this thread. You just want &q=
uot;range&quot; to be spelled &quot;pair of iterators&quot; which is where =
the contention arises. :p<br>
</p>

<p></p>

-- <br />
<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 <a href=3D"mailto:std-proposals+unsubscribe@isocpp.org">std-proposa=
ls+unsubscribe@isocpp.org</a>.<br />
To post to this group, send email to <a href=3D"mailto:std-proposals@isocpp=
..org">std-proposals@isocpp.org</a>.<br />
Visit this group at <a href=3D"http://groups.google.com/a/isocpp.org/group/=
std-proposals/">http://groups.google.com/a/isocpp.org/group/std-proposals/<=
/a>.<br />

--089e010d8358c3d37d051b92628f--

.
