220 25485 <cad96977-d5d4-4eea-8169-ae1ceb8b6477@isocpp.org> article
Path: news.gmane.org!not-for-mail
From: isocppgroup@denisbider.com
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: Re: Relocation as a solution for the valueless
 variant problem?
Date: Fri, 8 Apr 2016 13:25:37 -0700 (PDT)
Lines: 341
Approved: news@gmane.org
Message-ID: <cad96977-d5d4-4eea-8169-ae1ceb8b6477@isocpp.org>
References: <b4feb52d-4cd0-475f-9f3d-6694564bc1b0@isocpp.org>
 <4187538d-68fa-4582-ba26-f406479abe67@isocpp.org>
 <eafd831f-85d2-430c-9969-7d084e6d28d2@isocpp.org>
 <CALQmNFggBQSADjEqS7pEzcdPSStGJfXkJdX0d2CwW_TmwqA=yQ@mail.gmail.com>
 <105d82bc-e1cf-4795-894c-112cd591c3af@isocpp.org>
 <CALQmNFja3Kt1XRR8S7Qr3rOktChVzuDGO7ZtSaQpsWaohU6wAA@mail.gmail.com>
 <4f31b957-05be-47cf-a1ca-03f33a9900c0@isocpp.org>
 <CALQmNFgoV-Rg4T6+KqMFt6vNa7GCDpU=jVLRcnK4dDd+eBby8A@mail.gmail.com>
 <30181f63-7189-494d-9294-3f8b8759308f@isocpp.org>
 <d7eee27f-bdfc-45b0-9c29-508dd01975b3@isocpp.org>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: plane.gmane.org
Mime-Version: 1.0
Content-Type: multipart/mixed; 
	boundary="----=_Part_954_388927962.1460147137852"
X-Trace: ger.gmane.org 1460147143 25069 80.91.229.3 (8 Apr 2016 20:25:43 GMT)
X-Complaints-To: usenet@ger.gmane.org
NNTP-Posting-Date: Fri, 8 Apr 2016 20:25:43 +0000 (UTC)
Cc: isocppgroup@denisbider.com
To: ISO C++ Standard - Future Proposals <std-proposals@isocpp.org>
Original-X-From: std-proposals+bncBD5LNK7YQYJRBQ5HUC4AKGQEDLERCUA@isocpp.org Fri Apr 08 22:25:42 2016
Return-path: <std-proposals+bncBD5LNK7YQYJRBQ5HUC4AKGQEDLERCUA@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-qg0-f72.google.com ([209.85.192.72])
	by plane.gmane.org with esmtp (Exim 4.69)
	(envelope-from <std-proposals+bncBD5LNK7YQYJRBQ5HUC4AKGQEDLERCUA@isocpp.org>)
	id 1aocyL-0006Rc-2k
	for gclcip-std-proposals@m.gmane.org; Fri, 08 Apr 2016 22:25:41 +0200
Original-Received: by mail-qg0-f72.google.com with SMTP id t38sf126955879qge.3
        for <gclcip-std-proposals@m.gmane.org>; Fri, 08 Apr 2016 13:25:40 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=isocpp-org.20150623.gappssmtp.com; s=20150623;
        h=date:from:to:cc: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=QroDEskRMYYxoXKWBPRt6P1iW7rRwziByWnpbpt6hSk=;
        b=Bp945MCX5c1rlijhdJfqWk4ydQI53eu/xpisFqFE+IaiyQ0Pjrj1J7tRod3y2GKqmC
         THGOaM1OiNBr9GCe/CyWx7VoIw6r/QkOEF5/Giho0Ar1V3lDSkxQvpHEIRpzOwdPgQUB
         ovRPvh0ppUk+s1d9VnGxOSytP2v1XhTSMFGE1gw3oxv0GlVpRAZROf1OeKDI4gmapjxT
         Ogg/gN1JiIAzny5WYTY6CoEIyhPK9N/lDhg+DKcnH5annh0SHs6C1LotIyn4/3+/8M67
         /5LaG7FDTydlTWslljgXiLn7+8pRJdqiwrgRh1Byk2LtFupHrv22cY+Y2aKZvmNnFHq5
         GryQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20130820;
        h=x-gm-message-state:date:from:to:cc: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=QroDEskRMYYxoXKWBPRt6P1iW7rRwziByWnpbpt6hSk=;
        b=Z11Gb6euXIIrfpdJTC6kJXWEwfObVWPzQon18q/PqYcGEJ7vLYiTSoBy1XAYPTi3mG
         PFrA1WW41Hb0atK4eMqZgf7x2LD+BndJZkWZWxCQWjwxOSsIOLL31LEaHmahKccIu7Va
         eFvRgSus5DCvhEq3Ke5TQWN3iL2MPwzQGi6olE8uEohicFqNEijoMKv9QoRxDm+eQvtN
         ALCF3FfObFq1673+U0P3nVsb0pcqHZQlWRxnTQiSRpYQmaZLSqNJsxkuVXmZ6JBRlLoY
         xj6mwon5hG6/gSVmb9eAtODypRtDc2NPQcijOBeOxXTUGqRUgsGl2bVH5o+mw8FwZONa
         Jjqg==
X-Gm-Message-State: AD7BkJKy445jxab9nWb9+OqjdLOyewM/49NJNMcDE0cmGjU6qdl7ogRidYr9vCCow8BO1g==
X-Received: by 10.129.72.68 with SMTP id v65mr6819600ywa.52.1460147140123;
        Fri, 08 Apr 2016 13:25:40 -0700 (PDT)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.50.43.132 with SMTP id w4ls318814igl.32.canary; Fri, 08 Apr
 2016 13:25:38 -0700 (PDT)
X-Received: by 10.50.43.234 with SMTP id z10mr139647igl.4.1460147138824;
        Fri, 08 Apr 2016 13:25:38 -0700 (PDT)
In-Reply-To: <d7eee27f-bdfc-45b0-9c29-508dd01975b3@isocpp.org>
X-Original-Sender: isocppgroup@denisbider.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: <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:25485
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/25485>

------=_Part_954_388927962.1460147137852
Content-Type: multipart/alternative; 
	boundary="----=_Part_955_1309426839.1460147137853"

------=_Part_955_1309426839.1460147137853
Content-Type: text/plain; charset=UTF-8

Nicol - the content of your response is no less ego-based than you claim 
mine is. You are deeply annoyed both by me as a person, and by what I am 
trying to do.

As far as I can tell, this annoyance seems to be based on 
misunderstandings. Perhaps like this:


> If your relocation support can't even perform relocation in this most 
simple of cases:

How does it *not* handle that case? If std::list has a relocator, the 
compiler can just call the relocator in this case:

  std::list<T> SomeFunc() {
    std::list<T> lt = ...
    ...
    return lt; // no special syntax needed; compiler calls relocator >>list<T>
  }


What prevents the compiler from doing this?



On Friday, April 8, 2016 at 8:12:03 AM UTC-6, Nicol Bolas wrote:

> On Friday, April 8, 2016 at 2:07:17 AM UTC-4, isocp...@denisbider.com 
> wrote:
>>
>> Ah, Jesus.
>>
>> It seems to me C++ has become infested with people who call themselves 
>> "modern", but whose objective is to desperately try to divorce the 
>> language from its low-level origins, while ashamedly having to recognize 
>> that this cannot be done, because it would defeat the purpose of the 
>> language and make it useless for its primary role.
>>
>> You are now building this over-ambitious standard library monstrosity, 
>> which is trying to pretend that C++ can be a platform. But the role of C++ 
>> is not to *be* a platform. It is a tool for *building* platforms, and 
>> for building applications on top of existing platforms.
>>
>> I can honestly say I don't like what you're doing, and if you keep going 
>> in this direction, C++ will have to be replaced with something that serves 
>> its original purpose.
>>
>> Stop trying to make this a managed language, for god's sake.
>>
>
> ... So Sean points out how move support introduced a plethora of new value 
> categories in order to ensure that it does not get automatically used in 
> the wrong place. To make sure that it's reasonably safe and usable for most 
> programmers. And he suggests that you should investigate this sort of thing 
> as a way to make sure that your "relocation" is also reasonably safe, that 
> it gets used automatically where appropriate, and that it doesn't get used 
> in improper places. And so forth.
>
> And your response to this is to claim that such commentary comes from 
> people <https://en.wikipedia.org/wiki/Ad_hominem> who are "infesting" the 
> language, that even that we make the language *as safe as it currently is* 
> represents an attempt to "make this a managed language", and so forth. 
> You're basically saying that your design is perfect as is, and anyone who 
> questions it in the name of safety is "desperately try[ing] to divorce the 
> language from its low-level origins."
>
> Seriously, are you *five-years old*?
>
> And let's not forget the implied insult to the standards committee that 
> their design for move support is wrong because it actually includes such 
> safety features.
>
> Personally, my basic criticism of your proposal is that it's not even 
> really half of a proposal. You can only "relocate" objects who's lifetimes 
> are governed by `new/delete` or placement new/explicit destructor calls. 
> That is, not automatic objects. You're basically taking the *easy part* 
> of destructive move/relocation, and then pretending that you have a 
> complete "relocation" feature.
>
> If your relocation support can't even perform relocation in this most 
> simple of cases:
>
> std::list<T> SomeFunc()
> {
>   std::list<T> lt = ...
>   ...
>   return lt; //Insert syntax for relocation-returning, if needed
> }
>
> Then *what good is it*?
>
> In fact, there is *no way* in your proposal to relocate an object into a 
> return value. Not even with P0135's guaranteed elision mechanics. Since you 
> can only relocate an object through the use of `new`, and return values 
> aren't created by `new`, there is no way to use relocation on simple return 
> values.
>
> So again, *what good is this?*
>
> That's where the "safety" argument that Sean is making comes from. Your 
> proposal only works with features that are inherently unsafe and that 
> programmers increasingly do not use with any particular frequency. Unlike 
> `move`, which works on *all object*s, automatic and non-automatic alike.
>
> That's the basic point that Sean is (or seems to be) making about your 
> proposal. You cannot use your proposal without calling upon deep-magic 
> levels of C++, like placement new and so forth. Your features is brittle, 
> incomplete, and painful to use.
>
> Allow me to restate your asinine "scalpel" analogy/conversation to better 
> explain this:
>
> Surgeon: I propose this new scalpel, which does these things better than 
>> the old scalpel.
>> Committee: But it doesn't do things better than the old scalpel. It 
>> doesn't even work most of the time.
>> Surgeon: Sure it does. See, it works just fine if you stand on your head, 
>> and it does things even better than the old one.
>> Committee: But... most people stopped performing surgery while standing 
>> on their head years ago.
>> Surgeon: Isn't it up to the surgeon to decide how he wants to perform 
>> surgery?
>> Committee: That's old style thinking. In modern surgery, we want tools 
>> that work with how we actually operate on people, not tools that force us 
>> to operate in a specific way. Especially ones known to be bad.
>> Surgeon: But the old scalpel has no such protections either. The old 
>> scalpel is just... a scalpel.
>> Committee: That's not true at all. The old scalpel works just fine when 
>> standing normally.
>> Surgeon: How would we even design a scalpel that does what this does 
>> without having to stand on your head?
>> Committee: Put some effort into it, rather than doing the bare minimum 
>> that you feel you can get away with. Make a *complete* scalpel.
>>
>
> In this analogy, "stand on your head" mean "using new/delete or placement 
> new and explicit destructor calls".
>
> Indeed, it's not clear to me why it is that your proposal needs to be a 
> language feature at all. N4034 was able to do what you're talking about 
> purely as a standard library thing. All it would need to do is say that the 
> function ends the lifetime of the source object, and that the source object 
> must not be an automatic object.
>
> You can even have implicitly generated versions which will simply perform 
> a move from the source to the destination, followed by a destructor call on 
> the source. It would be deleted for any type `T` who's move constructor is 
> not `noexcept`.
>

-- 
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.
To view this discussion on the web visit https://groups.google.com/a/isocpp.org/d/msgid/std-proposals/cad96977-d5d4-4eea-8169-ae1ceb8b6477%40isocpp.org.

------=_Part_955_1309426839.1460147137853
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div>Nicol -=C2=A0the content of your response is no less =
ego-based than you claim mine is. You are deeply annoyed both by me as a pe=
rson, and by what I am trying to do.</div><div><br></div><div>As far as I c=
an tell, this annoyance seems to be based on misunderstandings. Perhaps=C2=
=A0like this:</div><div><br></div><div><br></div><div>&gt; If your relocati=
on support can&#39;t even perform relocation in this most simple of cases:<=
br></div><div><br></div><div>How does it <em>not</em> handle that case? If =
std::list has a relocator, the compiler can just call the relocator in this=
 case:</div><div><font color=3D"#666600"><br></font></div><div><font color=
=3D"#666600"><pre style=3D"background: rgb(246, 248, 255); color: rgb(0, 0,=
 32);">  <span style=3D"color: rgb(0, 102, 238);">std</span><span style=3D"=
color: rgb(64, 96, 128);">::</span><span style=3D"color: rgb(0, 48, 96);">l=
ist</span><span style=3D"color: rgb(64, 96, 128);">&lt;</span>T<span style=
=3D"color: rgb(64, 96, 128);">&gt;</span> SomeFunc<span style=3D"color: rgb=
(48, 128, 128);">(</span><span style=3D"color: rgb(48, 128, 128);">)</span>=
 <span style=3D"color: rgb(64, 96, 128);">{</span>
    <span style=3D"color: rgb(0, 102, 238);">std</span><span style=3D"color=
: rgb(64, 96, 128);">::</span><span style=3D"color: rgb(0, 48, 96);">list</=
span><span style=3D"color: rgb(64, 96, 128);">&lt;</span>T<span style=3D"co=
lor: rgb(64, 96, 128);">&gt;</span> lt <span style=3D"color: rgb(48, 128, 1=
28);">=3D</span> <span style=3D"color: rgb(48, 128, 128);">.</span><span st=
yle=3D"color: rgb(48, 128, 128);">.</span><span style=3D"color: rgb(48, 128=
, 128);">.</span>
    <span style=3D"color: rgb(48, 128, 128);">.</span><span style=3D"color:=
 rgb(48, 128, 128);">.</span><span style=3D"color: rgb(48, 128, 128);">.</s=
pan>
    <span style=3D"color: rgb(32, 0, 128); font-weight: bold;">return</span=
> lt<span style=3D"color: rgb(64, 96, 128);">;</span> <span style=3D"color:=
 rgb(89, 89, 121);">// no special syntax needed; compiler calls relocator &=
gt;&gt;list&lt;T&gt;</span>
  <span style=3D"color: rgb(64, 96, 128);">}</span>

</pre></font></div><div><br></div><div>What prevents the compiler from doin=
g this?</div><div><br></div><div><br></div><div><br>On Friday, April 8, 201=
6 at 8:12:03 AM UTC-6, Nicol Bolas wrote:</div><blockquote class=3D"gmail_q=
uote" style=3D"margin: 0px 0px 0px 0.8ex; padding-left: 1ex; border-left-co=
lor: rgb(204, 204, 204); border-left-width: 1px; border-left-style: solid;"=
><div dir=3D"ltr">On Friday, April 8, 2016 at 2:07:17 AM UTC-4, <a>isocp...=
@denisbider.com</a> wrote:<blockquote class=3D"gmail_quote" style=3D"margin=
: 0px 0px 0px 0.8ex; padding-left: 1ex; border-left-color: rgb(204, 204, 20=
4); border-left-width: 1px; border-left-style: solid;"><div dir=3D"ltr"><di=
v>Ah, Jesus.</div><div><br></div><div>It seems to me C++ has become infeste=
d with people=C2=A0who call themselves &quot;modern&quot;, but whose=C2=A0o=
bjective is to=C2=A0desperately try to divorce=C2=A0the language=C2=A0from =
its low-level origins, while=C2=A0ashamedly having to=C2=A0recognize that t=
his cannot be done, because it would defeat the purpose of the language and=
 make it useless for its primary role.</div><div><br></div><div>You are now=
 building this over-ambitious standard library monstrosity, which is=C2=A0t=
rying to pretend that C++ can be a platform. But the=C2=A0role of C++ is no=
t to <i>be</i> a platform. It is a tool for <i>building</i> platforms, and =
for building applications on top of existing platforms.</div><div><br></div=
><div>I can honestly say I don&#39;t like what you&#39;re doing, and if you=
 keep going in this direction, C++ will have to be replaced with something =
that serves its original purpose.</div><div><br></div><div>Stop trying to m=
ake this a managed language, for god&#39;s sake.</div></div></blockquote><d=
iv><br>... So Sean points out how move support introduced a plethora of new=
 value categories in order to ensure that it does not get automatically use=
d in the wrong place. To make sure that it&#39;s reasonably safe and usable=
 for most programmers. And he suggests that you should investigate this sor=
t of thing as a way to make sure that your &quot;relocation&quot; is also r=
easonably safe, that it gets used automatically where appropriate, and that=
 it doesn&#39;t get used in improper places. And so forth.<br><br>And your =
response to this is <a onmousedown=3D"this.href=3D&#39;https://www.google.c=
om/url?q\75https%3A%2F%2Fen.wikipedia.org%2Fwiki%2FAd_hominem\46sa\75D\46sn=
tz\0751\46usg\75AFQjCNG-BwifY9ygNjAtJUGk8AHKdjZJiQ&#39;;return true;" oncli=
ck=3D"this.href=3D&#39;https://www.google.com/url?q\75https%3A%2F%2Fen.wiki=
pedia.org%2Fwiki%2FAd_hominem\46sa\75D\46sntz\0751\46usg\75AFQjCNG-BwifY9yg=
NjAtJUGk8AHKdjZJiQ&#39;;return true;" href=3D"https://en.wikipedia.org/wiki=
/Ad_hominem" target=3D"_blank" rel=3D"nofollow">to claim that such commenta=
ry comes from people</a> who are &quot;infesting&quot; the language, that e=
ven that we make the language <i>as safe as it currently is</i> represents =
an attempt to &quot;make this a managed language&quot;, and so forth. You&#=
39;re basically saying that your design is perfect as is, and anyone who qu=
estions it in the name of safety is &quot;desperately try[ing] to divorce=
=C2=A0the language=C2=A0from its low-level origins.&quot;<br><br>Seriously,=
 are you <i>five-years old</i>?<br><br>And let&#39;s not forget the implied=
 insult to the standards committee that their design for move support is wr=
ong because it actually includes such safety features.<br><br>Personally, m=
y basic criticism of your proposal is that it&#39;s not even really half of=
 a proposal. You can only &quot;relocate&quot; objects who&#39;s lifetimes =
are governed by `new/delete` or placement new/explicit destructor calls. Th=
at is, not automatic objects. You&#39;re basically taking the <i>easy part<=
/i> of destructive move/relocation, and then pretending that you have a com=
plete &quot;relocation&quot; feature.<br><br>If your relocation support can=
&#39;t even perform relocation in this most simple of cases:<br><br><div st=
yle=3D"border: 1px solid rgb(187, 187, 187); border-image: none; -ms-word-w=
rap: break-word; background-color: rgb(250, 250, 250);"><code><div><span st=
yle=3D"color: rgb(0, 0, 0);">std</span><span style=3D"color: rgb(102, 102, =
0);">::</span><span style=3D"color: rgb(0, 0, 0);">list</span><span style=
=3D"color: rgb(102, 102, 0);">&lt;</span><span style=3D"color: rgb(0, 0, 0)=
;">T</span><span style=3D"color: rgb(102, 102, 0);">&gt;</span><span style=
=3D"color: rgb(0, 0, 0);"> </span><span style=3D"color: rgb(102, 0, 102);">=
SomeFunc</span><span style=3D"color: rgb(102, 102, 0);">()</span><span styl=
e=3D"color: rgb(0, 0, 0);"><br></span><span style=3D"color: rgb(102, 102, 0=
);">{</span><span style=3D"color: rgb(0, 0, 0);"><br>=C2=A0 std</span><span=
 style=3D"color: rgb(102, 102, 0);">::</span><span style=3D"color: rgb(0, 0=
, 0);">list</span><span style=3D"color: rgb(102, 102, 0);">&lt;</span><span=
 style=3D"color: rgb(0, 0, 0);">T</span><span style=3D"color: rgb(102, 102,=
 0);">&gt;</span><span style=3D"color: rgb(0, 0, 0);"> lt </span><span styl=
e=3D"color: rgb(102, 102, 0);">=3D</span><span style=3D"color: rgb(0, 0, 0)=
;"> </span><span style=3D"color: rgb(102, 102, 0);">...</span><span style=
=3D"color: rgb(0, 0, 0);"><br>=C2=A0 </span><span style=3D"color: rgb(102, =
102, 0);">...</span><span style=3D"color: rgb(0, 0, 0);"><br>=C2=A0 </span>=
<span style=3D"color: rgb(0, 0, 136);">return</span><span style=3D"color: r=
gb(0, 0, 0);"> lt</span><span style=3D"color: rgb(102, 102, 0);">;</span><s=
pan style=3D"color: rgb(0, 0, 0);"> </span><span style=3D"color: rgb(136, 0=
, 0);">//Insert syntax for relocation-returning, if needed</span><span styl=
e=3D"color: rgb(0, 0, 0);"><br></span><span style=3D"color: rgb(102, 102, 0=
);">}</span></div></code></div><br>Then <i>what good is it</i>?<br><br>In f=
act, there is <i>no way</i> in your proposal to relocate an object into a r=
eturn value. Not even with P0135&#39;s guaranteed elision mechanics. Since =
you can only relocate an object through the use of `new`, and return values=
 aren&#39;t created by `new`, there is no way to use relocation on simple r=
eturn values.<br><br>So again, <i>what good is this?</i><br><br>That&#39;s =
where the &quot;safety&quot; argument that Sean is making comes from. Your =
proposal only works with features that are inherently unsafe and that progr=
ammers increasingly do not use with any particular frequency. Unlike `move`=
, which works on <i>all object</i>s, automatic and non-automatic alike.<br>=
<br>That&#39;s the basic point that Sean is (or seems to be) making about y=
our proposal. You cannot use your proposal without calling upon deep-magic =
levels of C++, like placement new and so forth. Your features is brittle, i=
ncomplete, and painful to use.<br><br>Allow me to restate your asinine &quo=
t;scalpel&quot; analogy/conversation to better explain this:<br><br><blockq=
uote class=3D"gmail_quote" style=3D"margin: 0px 0px 0px 0.8ex; padding-left=
: 1ex; border-left-color: rgb(204, 204, 204); border-left-width: 1px; borde=
r-left-style: solid;">Surgeon: I propose this new scalpel, which does these=
 things better than the old scalpel.<br>Committee: But it doesn&#39;t do th=
ings better than the old scalpel. It doesn&#39;t even work most of the time=
..<br>Surgeon: Sure it does. See, it works just fine if you stand on your he=
ad, and it does things even better than the old one.<br>Committee: But... m=
ost people stopped performing surgery while standing on their head years ag=
o.<br>Surgeon: Isn&#39;t it up to the surgeon to decide how he wants to per=
form surgery?<br>Committee: That&#39;s old style thinking. In modern surger=
y, we want tools that work with how we actually operate on people, not tool=
s that force us to operate in a specific way. Especially ones known to be b=
ad.<br>Surgeon: But the old scalpel has no such protections either. The old=
 scalpel is just... a scalpel.<br>Committee: That&#39;s not true at all. Th=
e old scalpel works just fine when standing normally.<br>Surgeon: How would=
 we even design a scalpel that does what this does without having to stand =
on your head?<br>Committee: Put some effort into it, rather than doing the =
bare minimum that you feel you can get away with. Make a <i>complete</i> sc=
alpel.<br></blockquote><div><br>In this analogy, &quot;stand on your head&q=
uot; mean &quot;using new/delete or placement new and explicit destructor c=
alls&quot;.<br><br>Indeed, it&#39;s not clear to me why it is that your pro=
posal needs to be a=20
language feature at all. N4034 was able to do what you&#39;re talking about=
=20
purely as a standard library thing. All it would need to do is say that=20
the function ends the lifetime of the source object, and that the source
 object must not be an automatic object.<br><br>You can even have implicitl=
y generated versions which will simply perform a move from the source to th=
e destination, followed by a destructor call on the source. It would be del=
eted for any type `T` who&#39;s move constructor is not `noexcept`.<br></di=
v></div></div></blockquote></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/cad96977-d5d4-4eea-8169-ae1ceb8b6477%=
40isocpp.org?utm_medium=3Demail&utm_source=3Dfooter">https://groups.google.=
com/a/isocpp.org/d/msgid/std-proposals/cad96977-d5d4-4eea-8169-ae1ceb8b6477=
%40isocpp.org</a>.<br />

------=_Part_955_1309426839.1460147137853--
------=_Part_954_388927962.1460147137852--

.
