220 29830 <CAFk2RUYq+_To254SGVAesMfZtFJDLSVmLvU=U3bhBq83xZdA1w@mail.gmail.com> article
Path: news.gmane.org!.POSTED!not-for-mail
From: Ville Voutilainen <ville.voutilainen@gmail.com>
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: New smart pointer: CopyConstructible and
 CopyAssignable flavor of unique_ptr
Date: Fri, 16 Dec 2016 14:28:57 +0200
Lines: 42
Approved: news@gmane.org
Message-ID: <CAFk2RUYq+_To254SGVAesMfZtFJDLSVmLvU=U3bhBq83xZdA1w@mail.gmail.com>
References: <13702f32-32c2-447f-9996-3624fd678675@isocpp.org>
 <CAFk2RUY3c67YgivjPTSCB+FLUGfiFgi8F_8kcSSUwPeBp9tMmw@mail.gmail.com>
 <CAEddoJZxM5qe9qVfags_iNrd0YpvUo2xmSw-OqifnHJ+4wJtxA@mail.gmail.com>
 <CAFk2RUZ9MjM=jCd2YkHHVjurPZB7mscgzbxnOjdLWqZStp0bBQ@mail.gmail.com>
 <CAEddoJb9BfQzhoWxLz4-QvD-PkEupxucguMvQEETfcUM7Ed=JA@mail.gmail.com>
 <CAFk2RUb4-hGZq8ZDNR=eMv2erJK+8UH8Qj=SNeG+9DBW678Wkw@mail.gmail.com>
 <CAEddoJbQAx5Pne+qu4A92Pd=NgiLQsj8auGuJHeZiKmz1fouQg@mail.gmail.com>
 <CAFk2RUZ-Xm2cQ6jCwQaSAhF+sCudqnHeivrJvqCQ4mhKv9rN+g@mail.gmail.com> <CAEddoJZ+AR_UC_xheJnkn4yBg7iny3_BHNXHOa1M1+iZEpuqiQ@mail.gmail.com>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: blaine.gmane.org
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Trace: blaine.gmane.org 1481891345 23489 195.159.176.226 (16 Dec 2016 12:29:05 GMT)
X-Complaints-To: usenet@blaine.gmane.org
NNTP-Posting-Date: Fri, 16 Dec 2016 12:29:05 +0000 (UTC)
To: "ISO C++ Standard - Future Proposals" <std-proposals@isocpp.org>
Original-X-From: std-proposals+bncBC5JHI7A7ALRBCV4Z7BAKGQE72BMNSY@isocpp.org Fri Dec 16 13:28:57 2016
Return-path: <std-proposals+bncBC5JHI7A7ALRBCV4Z7BAKGQE72BMNSY@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-pf0-f199.google.com ([209.85.192.199])
	by blaine.gmane.org with esmtp (Exim 4.84_2)
	(envelope-from <std-proposals+bncBC5JHI7A7ALRBCV4Z7BAKGQE72BMNSY@isocpp.org>)
	id 1cHrd9-0004aj-84
	for gclcip-std-proposals@m.gmane.org; Fri, 16 Dec 2016 13:28:55 +0100
Original-Received: by mail-pf0-f199.google.com with SMTP id 83sf119436047pfx.1
        for <gclcip-std-proposals@m.gmane.org>; Fri, 16 Dec 2016 04:29:00 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=isocpp-org.20150623.gappssmtp.com; s=20150623;
        h=mime-version:in-reply-to:references:from:date:message-id:subject:to
         :content-transfer-encoding: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=A8kUnNX2juHdW/P7fZmgsf2M0kf3AKtx2VXREedbzdA=;
        b=QoEmjm6iLlTIKMeedQistaw7J8FmKSHV6g4rjwWUUX2DTKB4nyvMDFYD9HzMuRQ2Li
         ol6HW4Bwqd3m3rj3c2DSZuY3ysbxrPDUA3slniDai9AROdNLz7mWobcW97Jr4pNKWhvb
         d58X6QkysB2zoevJ1WQGex/q2KkbEbi0J3TasdvV5wgXbjGfe2FW+fwcxhusok7xjEga
         jqw6q/FL/f5vdjoy0PhTe7EGGE9e3uCZRrc0G4mz/pMmiVef9Gth0A+MI7e7oG9RxdHg
         wMf2bvhGQjKAILFA99DqR8NsGIy4uI0wygQGmacAeFvD1lRFQ8oy6AohsE6msk2Wg/tg
         SYNw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20161025;
        h=x-gm-message-state:mime-version:in-reply-to:references:from:date
         :message-id:subject:to:content-transfer-encoding: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=A8kUnNX2juHdW/P7fZmgsf2M0kf3AKtx2VXREedbzdA=;
        b=g8MIGvewDKzKuz9/YXWVlaJ7l7KjSBV+4YGnJUX1gYN/LmVY3+b9BPM0OkkqGXCXy+
         VP4raykiycjumFsIgvDyKCvnzYuhZ+jJst9Nrivqk4Sz7SSHI86j+rzamvrUcZ52h+om
         ynTcNBUYkZxCGNHbx4oeiiWK5j4DLW5sxzlw83YtC1ubOQOw5IOXgMpiL0QZ60074F9g
         HYu0ibnOq3IlpPWhT+4OE/Eh931ChryAu1DYCVlFsCIfB2eVRPLmRDXO08Qd8fybJnaO
         tgudKj/eNjNYLy58g/GQHSS86tC7LT7sucEwfef4D8NtiKF3bigmSGtsvxQ5tzqTvp+I
         4vr 
X-Gm-Message-State: AKaTC02AW0Vk+VI6zll+08G3Gro47Iz62gDJC43tie6vs89BtkUnozT0w76+NFeugqBRkg==
X-Received: by 10.98.15.91 with SMTP id x88mr469087pfi.34.1481891339376;
        Fri, 16 Dec 2016 04:28:59 -0800 (PST)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.157.27.206 with SMTP id v14ls8143555otv.2.gmail; Fri, 16 Dec
 2016 04:28:58 -0800 (PST)
X-Received: by 10.176.0.169 with SMTP id 38mr2448570uaj.34.1481891338672;
        Fri, 16 Dec 2016 04:28:58 -0800 (PST)
Original-Received: from mail-vk0-x22b.google.com (mail-vk0-x22b.google.com. [2607:f8b0:400c:c05::22b])
        by mx.google.com with ESMTPS id 89si2141063uaq.198.2016.12.16.04.28.58
        for <std-proposals@isocpp.org>
        (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
        Fri, 16 Dec 2016 04:28:58 -0800 (PST)
Received-SPF: pass (google.com: domain of ville.voutilainen@gmail.com designates 2607:f8b0:400c:c05::22b as permitted sender) client-ip=2607:f8b0:400c:c05::22b;
Original-Received: by mail-vk0-x22b.google.com with SMTP id p9so87798166vkd.3
        for <std-proposals@isocpp.org>; Fri, 16 Dec 2016 04:28:58 -0800 (PST)
X-Received: by 10.31.81.198 with SMTP id f189mr868054vkb.160.1481891338326;
 Fri, 16 Dec 2016 04:28:58 -0800 (PST)
Original-Received: by 10.103.50.74 with HTTP; Fri, 16 Dec 2016 04:28:57 -0800 (PST)
In-Reply-To: <CAEddoJZ+AR_UC_xheJnkn4yBg7iny3_BHNXHOa1M1+iZEpuqiQ@mail.gmail.com>
X-Original-Sender: ville.voutilainen@gmail.com
X-Original-Authentication-Results: mx.google.com;       dkim=pass
 header.i=@gmail.com;       spf=pass (google.com: domain of
 ville.voutilainen@gmail.com designates 2607:f8b0:400c:c05::22b as permitted
 sender) smtp.mailfrom=ville.voutilainen@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: <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:29830
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/29830>

On 16 December 2016 at 14:26, Jonathan M=C3=BCller
<jonathanmueller.dev@gmail.com> wrote:
> On Dec 16, 2016 13:19, "Ville Voutilainen" <ville.voutilainen@gmail.com>
> wrote:
>> That doesn't provide the convenience we're looking for with these
>> proposed wrappers. The best thing
>> about them is that you can stash them into a struct and define no
>> special member functions for that
>> struct and you get the right semantics. Such a free function would
>> need to be called manually, and
>> it's not type-erasing and polymorphic, whereas the proposed indirect
>> and cloned_ptr are.
>
> But I don't think you get the right semantics for that, that's my point.
> You get inconsistent semantics.

But I do, otherwise I wouldn't have chosen a cloned_ptr.

> As a struct member I would rather have a non-null wrapper that gives valu=
e
> sematics to a polymorphic type.

Like the proposed std::indirect? I got the impression that its latest
feedback was to move it
closer to value semantics of a polymorphic type.

>Not a mix between optional and unique_ptr.

All pointers are a mix between "optional" and something else since
they can be null. And that's
just fine for many cases.

--=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/CAFk2RUYq%2B_To254SGVAesMfZtFJDLSVmLvU%3DU3bhBq8=
3xZdA1w%40mail.gmail.com.

.
