220 29821 <e1e780b7-34ea-41bf-9aba-22a1eb6a5f3f@isocpp.org> article
Path: news.gmane.org!.POSTED!not-for-mail
From: Jonathan Wakely <cxx@kayari.org>
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: New smart pointer: CopyConstructible and
 CopyAssignable flavor of unique_ptr
Date: Fri, 16 Dec 2016 03:58:40 -0800 (PST)
Lines: 72
Approved: news@gmane.org
Message-ID: <e1e780b7-34ea-41bf-9aba-22a1eb6a5f3f@isocpp.org>
References: <13702f32-32c2-447f-9996-3624fd678675@isocpp.org> <CAFk2RUY3c67YgivjPTSCB+FLUGfiFgi8F_8kcSSUwPeBp9tMmw@mail.gmail.com>
 <CAEddoJZxM5qe9qVfags_iNrd0YpvUo2xmSw-OqifnHJ+4wJtxA@mail.gmail.com>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: blaine.gmane.org
Mime-Version: 1.0
Content-Type: multipart/mixed; 
	boundary="----=_Part_419_239395026.1481889520061"
X-Trace: blaine.gmane.org 1481889522 26821 195.159.176.226 (16 Dec 2016 11:58:42 GMT)
X-Complaints-To: usenet@blaine.gmane.org
NNTP-Posting-Date: Fri, 16 Dec 2016 11:58:42 +0000 (UTC)
To: ISO C++ Standard - Future Proposals <std-proposals@isocpp.org>
Original-X-From: std-proposals+bncBCMONUNYS4IRB4FNZ7BAKGQE2VULZGQ@isocpp.org Fri Dec 16 12:58:38 2016
Return-path: <std-proposals+bncBCMONUNYS4IRB4FNZ7BAKGQE2VULZGQ@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-qk0-f200.google.com ([209.85.220.200])
	by blaine.gmane.org with esmtp (Exim 4.84_2)
	(envelope-from <std-proposals+bncBCMONUNYS4IRB4FNZ7BAKGQE2VULZGQ@isocpp.org>)
	id 1cHr9o-00067d-TK
	for gclcip-std-proposals@m.gmane.org; Fri, 16 Dec 2016 12:58:37 +0100
Original-Received: by mail-qk0-f200.google.com with SMTP id m67sf62563419qkf.0
        for <gclcip-std-proposals@m.gmane.org>; Fri, 16 Dec 2016 03:58:41 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=isocpp-org.20150623.gappssmtp.com; s=20150623;
        h=date:from:to:message-id:in-reply-to:references:subject:mime-version
         :x-original-sender:reply-to:precedence:mailing-list:list-id
         :x-spam-checked-in-group:list-post:list-help:list-archive
         :list-subscribe:list-unsubscribe;
        bh=KZm8mKvMbg/qK3A51CeGVjIVB90bMAHdngtsmNpZF7A=;
        b=ZidnGPrQnFiCg3ksgRbcOHdw1F6b8RZKa6YfXixBhvU/Ppf9BqwXjI7nIN7DZs4UZD
         wFPP9hLg+K+wFH2AFxvnk5eFan0Ael8i79q6YfewzielsPmJgDdzXIs+JyEAuAkkP1pn
         go3Aq0vtf8RzADYyKWF8a+e/2Mdh+1q3Q7meR+pJYwKsejmL65g7CPZohztQeKDhOVQe
         xtxZmogIUuU+7XpxCritiIFDKjV7l+2Ov/UKyQMy2LjcbI0pbq/+3wuk6CcGkRd3ngru
         2LxbyHNLUj4ET6bFJZlWn5eU+0f+JIA4gWNqPf3AuuhmGqWwh9xX69oSM5T/F3fEltbP
         6YKg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20161025;
        h=x-gm-message-state:date:from:to:message-id:in-reply-to:references
         :subject:mime-version:x-original-sender:reply-to:precedence
         :mailing-list:list-id:x-spam-checked-in-group:list-post:list-help
         :list-archive:list-subscribe:list-unsubscribe;
        bh=KZm8mKvMbg/qK3A51CeGVjIVB90bMAHdngtsmNpZF7A=;
        b=R44G9ntel9INXV7FkYjqXiG1kyyE09VTYK4gI6ES8s4hexKp8CG2HGSeImtbuBMci0
         L1nKb0wca0RQFI3iepPJ0FODVu5HGY1Rbbw0K+OEEAyjhH3o3KKVZpsSUJLcX97lU6Ir
         nh3NFYw9RAXgr78xxWNYeXuat2visNkxjN40CV4rpJr9lrAWrX5zRzp3SDdW71bVgT3f
         yPdYrT4m4b+vSlegRZAMV/0PqzHEV1zYsnOQiH2WGzi13m5B63HPlgjV0DUZS00D+4R1
         aobeL3fT1f9b86eXRhAtaGu54015FYRuRF0K97NBoqmBqAYySTFHp/XPDnC1ncLnmaM1
         kRqw==
X-Gm-Message-State: AIkVDXIkJBLN8SPJRKMTucRV21dr8VHIkkm2KA+wDUd5VW3ecr+vcpavISTM3ljDDkvm+w==
X-Received: by 10.200.54.194 with SMTP id b2mr497644qtc.35.1481889521214;
        Fri, 16 Dec 2016 03:58:41 -0800 (PST)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.157.23.193 with SMTP id j59ls8463606otj.24.gmail; Fri, 16 Dec
 2016 03:58:40 -0800 (PST)
X-Received: by 10.157.37.125 with SMTP id j58mr92333otd.18.1481889520429;
        Fri, 16 Dec 2016 03:58:40 -0800 (PST)
In-Reply-To: <CAEddoJZxM5qe9qVfags_iNrd0YpvUo2xmSw-OqifnHJ+4wJtxA@mail.gmail.com>
X-Original-Sender: cxx@kayari.org
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: <https://groups.google.com/a/isocpp.org/group/std-proposals/post>, <mailto:std-proposals@isocpp.org>
List-Help: <https://support.google.com/a/isocpp.org/bin/topic.py?topic=25838>, <mailto:std-proposals+help@isocpp.org>
List-Archive: <https://groups.google.com/a/isocpp.org/group/std-proposals/>
List-Subscribe: <https://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>,
 <https://groups.google.com/a/isocpp.org/group/std-proposals/subscribe>
Xref: news.gmane.org gmane.comp.lang.c++.isocpp.proposals:29821
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/29821>

------=_Part_419_239395026.1481889520061
Content-Type: multipart/alternative; 
	boundary="----=_Part_420_2068846563.1481889520061"

------=_Part_420_2068846563.1481889520061
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable


On Friday, 16 December 2016 11:44:40 UTC, Jonathan M=C3=BCller wrote:
>
> So it transfers ownership when moving and does a deep copy when copying?
>
> I don't think two so different semantics are a great idea.
>
>
>
That seems to work for std::vector, and many other types.

The difference here would be that the dynamic type can vary from the static=
=20
type, but I don't see why that means that "move when you can move and copy=
=20
otherwise" stops being a sensible policy.

--=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.
To view this discussion on the web visit https://groups.google.com/a/isocpp=
..org/d/msgid/std-proposals/e1e780b7-34ea-41bf-9aba-22a1eb6a5f3f%40isocpp.or=
g.

------=_Part_420_2068846563.1481889520061
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><br>On Friday, 16 December 2016 11:44:40 UTC, Jonathan M=
=C3=BCller  wrote:<blockquote class=3D"gmail_quote" style=3D"margin: 0;marg=
in-left: 0.8ex;border-left: 1px #ccc solid;padding-left: 1ex;"><p dir=3D"lt=
r">So it transfers ownership when moving and does a deep copy when copying?=
</p>
<p dir=3D"ltr">I don&#39;t think two so different semantics are a great ide=
a.</p>
<p dir=3D"ltr"><br></p></blockquote><div><br></div><div>That seems to work =
for std::vector, and many other types.</div><div><br></div><div>The differe=
nce here would be that the dynamic type can vary from the static type, but =
I don&#39;t see why that means that &quot;move when you can move and copy o=
therwise&quot; stops being a sensible policy.</div></div>

<p></p>

-- <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 />
To view this discussion on the web visit <a href=3D"https://groups.google.c=
om/a/isocpp.org/d/msgid/std-proposals/e1e780b7-34ea-41bf-9aba-22a1eb6a5f3f%=
40isocpp.org?utm_medium=3Demail&utm_source=3Dfooter">https://groups.google.=
com/a/isocpp.org/d/msgid/std-proposals/e1e780b7-34ea-41bf-9aba-22a1eb6a5f3f=
%40isocpp.org</a>.<br />

------=_Part_420_2068846563.1481889520061--

------=_Part_419_239395026.1481889520061--

.
