220 13625 <CAOHCbitT4RzmyuHmw1En_Aj5p3hph3QD29v-9k=z7_X0pxbqSw@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: The view concept
Date: Fri, 3 Oct 2014 13:44:01 -0400
Lines: 141
Approved: news@gmane.org
Message-ID: <CAOHCbitT4RzmyuHmw1En_Aj5p3hph3QD29v-9k=z7_X0pxbqSw@mail.gmail.com>
References: <428c47bd-67f2-47d1-98c0-e5ca85698076@isocpp.org>
	<FF740D55-733D-4969-8388-FC9E53F05C65@gmail.com>
	<e622f246-8a01-455d-9269-7b9595230185@isocpp.org>
	<CAOU91OMW1c89oyoKhpF5BgXiOmGfK5RNwwhQ+9FWM+JJKgbTNw@mail.gmail.com>
	<CAOHCbisJEJrau7kr5d8uYXq=A0pG-86uEc0QmhPTjVHJj5EzMA@mail.gmail.com>
	<e8b51487-c89f-4804-8652-15971a4c2502@isocpp.org>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: plane.gmane.org
Mime-Version: 1.0
Content-Type: multipart/alternative; boundary=089e0160bf984447ba0504884718
X-Trace: ger.gmane.org 1412358253 11053 80.91.229.3 (3 Oct 2014 17:44:13 GMT)
X-Complaints-To: usenet@ger.gmane.org
NNTP-Posting-Date: Fri, 3 Oct 2014 17:44:13 +0000 (UTC)
To: std-proposals@isocpp.org
Original-X-From: std-proposals+bncBCUZ5QWKNQIOFQF3UECRUBAXFKYDI@isocpp.org Fri Oct 03 19:44:05 2014
Return-path: <std-proposals+bncBCUZ5QWKNQIOFQF3UECRUBAXFKYDI@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-la0-f71.google.com ([209.85.215.71])
	by plane.gmane.org with esmtp (Exim 4.69)
	(envelope-from <std-proposals+bncBCUZ5QWKNQIOFQF3UECRUBAXFKYDI@isocpp.org>)
	id 1Xa6tf-0000JF-OT
	for gclcip-std-proposals@m.gmane.org; Fri, 03 Oct 2014 19:44:03 +0200
Original-Received: by mail-la0-f71.google.com with SMTP id gi9sf986827lab.6
        for <gclcip-std-proposals@m.gmane.org>; Fri, 03 Oct 2014 10:44:03 -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:in-reply-to:references:date
         :message-id:subject:from:to:x-original-sender
         :x-original-authentication-results:reply-to:precedence:mailing-list
         :list-id:list-post:list-help:list-archive:list-subscribe
         :list-unsubscribe:content-type;
        bh=gwHCoX2X/BD16+vEtDIbuiTJLG1NGc/6TUK+j9lWvuE=;
        b=KBSeERaMSFPKUcIYSFo6Zn086KXzvAlA/w81Aes71J5fgAhvVCvoYstZ0UvO0pNxOv
         0p2c56ksrNXbqfjm+eyhibD7SM27dImUvbmsgTlgEqu8MJyxtBxE/agzc4eKJqQyqn2K
         m9aiKvqKTheLyOvB9EjyW5IyOhJ8xX5ECzNlmrSeD86j5g7iZBI+BFfn0dI90e9WfBX9
         OurocNdeqJzH/iY8SbzTjwM2PwLWTXpYbqxy6MThuPNnawv86quLx3x+HPGDT7pnAYgh
         EkOZeElhWXC2g1HbiIMblrdIjgTGImwduTatRVEzX6LyiaNMNNp261U5p4RJNPcPo+/+
         QHKQ==
X-Gm-Message-State: ALoCoQnV9o1GNIrdn8t8drKNQIepfDS+ZXdzNm50u+O9ReWC3bMyRs9tJ5L3AGUfJE7Ss5PFWgMo
X-Received: by 10.152.2.97 with SMTP id 1mr1233877lat.6.1412358243513;
        Fri, 03 Oct 2014 10:44:03 -0700 (PDT)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.152.224.161 with SMTP id rd1ls387062lac.95.gmail; Fri, 03 Oct
 2014 10:44:01 -0700 (PDT)
X-Received: by 10.152.26.133 with SMTP id l5mr7856449lag.4.1412358241786;
        Fri, 03 Oct 2014 10:44:01 -0700 (PDT)
Original-Received: from mail-lb0-x22c.google.com (mail-lb0-x22c.google.com [2a00:1450:4010:c04::22c])
        by mx.google.com with ESMTPS id db6si12396668lad.9.2014.10.03.10.44.01
        for <std-proposals@isocpp.org>
        (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128);
        Fri, 03 Oct 2014 10:44:01 -0700 (PDT)
Received-SPF: pass (google.com: domain of tvaneerd@gmail.com designates 2a00:1450:4010:c04::22c as permitted sender) client-ip=2a00:1450:4010:c04::22c;
Original-Received: by mail-lb0-f172.google.com with SMTP id b6so1453710lbj.3
        for <std-proposals@isocpp.org>; Fri, 03 Oct 2014 10:44:01 -0700 (PDT)
X-Received: by 10.152.23.69 with SMTP id k5mr7646605laf.70.1412358241272; Fri,
 03 Oct 2014 10:44:01 -0700 (PDT)
Original-Received: by 10.112.75.199 with HTTP; Fri, 3 Oct 2014 10:44:01 -0700 (PDT)
In-Reply-To: <e8b51487-c89f-4804-8652-15971a4c2502@isocpp.org>
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:c04::22c as permitted
 sender) smtp.mail=tvaneerd@gmail.com;       dkim=pass header.i=@gmail.com;
       dmarc=pass (p=NONE dis=NONE) header.from=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>, <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:13625
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/13625>

--089e0160bf984447ba0504884718
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

On Fri, Oct 3, 2014 at 1:25 PM, Matthew Fioravante <fmatthew5876@gmail.com>
wrote:

>
>
> On Friday, October 3, 2014 12:54:14 PM UTC-4, Tony V E wrote:
>>
>>
>>
>> On Fri, Oct 3, 2014 at 9:17 AM, Klaim - Jo=C3=ABl Lamotte <mjk...@gmail.=
com>
>> wrote:
>>
>>> I think that the most important question to answer is: what would be th=
e
>>> difference between a range and a view?=E2=80=8B
>>>
>>
>> One major likely difference is that range =3D=3D will probably be 'shall=
ow'.
>> Deep-compare will probably be a function.
>>
>
> I suppose the difference is that a range is a subset of a container, wher=
e
> as a view is a container itself, that is a non-owning container. In this
> sense a view is not actually a range at all but you can create a range ov=
er
> a view for generic algorithm processing. You can also create a view from =
a
> range.
>
> Since view is a container, operator=3D=3D is deep because its operating o=
n the
> container contents. However view is a non-owning container, so operator=
=3D
> reassigns it to a new owner. We should have some way to do shallow compar=
e
> and deep copy for a view.
>
>
>>
>> In general, I think a 'view' is this name we use where we'd like to use
>> range, but know that we haven't solidified what we mean by range yet, so=
 we
>> are punting and going with 'view' for now.
>>
>> Also a view is a less-generic range.  ie string_view has more than just
>> range features, it also copies over all the functions from string.
>>
>
> I think we should not call a view a range at all but a kind of container.
>
>

Of course we are still arguing whether a container is a range...

The biggest issue, in my mind, is that, IIUC, both Range and Container are
Regular.  View is not. ie View is a mix of deep and shallow, whereas both
Range and Container are consistent in their deep/shallow-ness.

Tony

--=20

---=20
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 e=
mail 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-proposa=
ls/.

--089e0160bf984447ba0504884718
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><br><div class=3D"gmail_extra"><br><div class=3D"gmail_quo=
te">On Fri, Oct 3, 2014 at 1:25 PM, Matthew Fioravante <span dir=3D"ltr">&l=
t;<a href=3D"mailto:fmatthew5876@gmail.com" target=3D"_blank">fmatthew5876@=
gmail.com</a>&gt;</span> wrote:<br><blockquote class=3D"gmail_quote" style=
=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir=
=3D"ltr"><br><br>On Friday, October 3, 2014 12:54:14 PM UTC-4, Tony V E wro=
te:<span class=3D""><blockquote class=3D"gmail_quote" style=3D"margin:0;mar=
gin-left:0.8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir=3D"ltr=
"><br><div><br><div class=3D"gmail_quote">On Fri, Oct 3, 2014 at 9:17 AM, K=
laim - Jo=C3=ABl Lamotte <span dir=3D"ltr">&lt;<a>mjk...@gmail.com</a>&gt;<=
/span> wrote:<br><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px =
0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir=
=3D"ltr">I think that the most important question to answer is: what would =
be the difference between a range and a view?=E2=80=8B</div></blockquote><d=
iv><br></div><div><div>One major likely difference is that range =3D=3D wil=
l probably be &#39;shallow&#39;.=C2=A0 Deep-compare will probably be a func=
tion.<br></div></div></div></div></div></blockquote></span><div><br>I suppo=
se the difference is that a range is a subset of a container, where as a vi=
ew is a container itself, that is a non-owning container. In this sense a v=
iew is not actually a range at all but you can create a range over a view f=
or generic algorithm processing. You can also create a view from a range.<b=
r><br>Since view is a container, operator=3D=3D is deep because its operati=
ng on the container contents. However view is a non-owning container, so op=
erator=3D reassigns it to a new owner. We should have some way to do shallo=
w compare and deep copy for a view.<br>=C2=A0</div><blockquote class=3D"gma=
il_quote" style=3D"margin:0;margin-left:0.8ex;border-left:1px #ccc solid;pa=
dding-left:1ex"><div dir=3D"ltr"><div><div class=3D"gmail_quote"><div><div>=
=C2=A0<br></div><div>In general, I think a &#39;view&#39; is this name we u=
se where we&#39;d like to use range, but know that we haven&#39;t solidifie=
d what we mean by range yet, so we are punting and going with &#39;view&#39=
; for now.<br></div><br></div><div>Also a view is a less-generic range.=C2=
=A0 ie string_view has more than just range features, it also copies over a=
ll the functions from string.<br></div></div></div></div></blockquote><div>=
<br>I think we should not call a view a range at all but a kind of containe=
r.<br>=C2=A0<br></div></div></blockquote><div><br></div><div>Of course we a=
re still arguing whether a container is a range...<br><br></div><div>The bi=
ggest issue, in my mind, is that, IIUC, both Range and Container are Regula=
r.=C2=A0 View is not. ie View is a mix of deep and shallow, whereas both Ra=
nge and Container are consistent in their deep/shallow-ness.<br><br>Tony<br=
></div></div><br><br></div></div>

<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 />

--089e0160bf984447ba0504884718--

.
