220 33482 <8c0ebca3-0dbd-444b-b0b0-845eca5b0de7@isocpp.org> article
Path: news.gmane.org!.POSTED!not-for-mail
From: Nicol Bolas <jmckesson@gmail.com>
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: Re: P0329R0 falls short for designated initialisers
Date: Mon, 31 Jul 2017 20:13:09 -0700 (PDT)
Lines: 105
Approved: news@gmane.org
Message-ID: <8c0ebca3-0dbd-444b-b0b0-845eca5b0de7@isocpp.org>
References: <4892340.tBhI7hZKOg@tjmaciei-mobl1> <2091187.OFx8EjqvIG@tjmaciei-mobl1>
 <54c48d0d-cc17-429d-bc59-5dffa1bb8846@isocpp.org> <3975136.UunVSsvxqs@tjmaciei-mobl1>
 <CAGsORuCiG=92weihTxedEHNxe9zo4WDWps5jdem-5Hpshh32CA@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_76_1858211338.1501557189300"
X-Trace: blaine.gmane.org 1501557193 5948 195.159.176.226 (1 Aug 2017 03:13:13 GMT)
X-Complaints-To: usenet@blaine.gmane.org
NNTP-Posting-Date: Tue, 1 Aug 2017 03:13:13 +0000 (UTC)
Cc: zy@miator.net
To: ISO C++ Standard - Future Proposals <std-proposals@isocpp.org>
Original-X-From: std-proposals+bncBCEKFTV6ZUMBBRXD77FQKGQEBAJCUSQ@isocpp.org Tue Aug 01 05:13:08 2017
Return-path: <std-proposals+bncBCEKFTV6ZUMBBRXD77FQKGQEBAJCUSQ@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-yw0-f199.google.com ([209.85.161.199])
	by blaine.gmane.org with esmtp (Exim 4.84_2)
	(envelope-from <std-proposals+bncBCEKFTV6ZUMBBRXD77FQKGQEBAJCUSQ@isocpp.org>)
	id 1dcNcH-00013s-LX
	for gclcip-std-proposals@m.gmane.org; Tue, 01 Aug 2017 05:13:05 +0200
Original-Received: by mail-yw0-f199.google.com with SMTP id t139sf7422401ywg.6
        for <gclcip-std-proposals@m.gmane.org>; Mon, 31 Jul 2017 20:13:11 -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:list-post:list-help:list-archive:list-subscribe
         :list-unsubscribe;
        bh=PrrP1iOT9DwB4vR4WQ33o6TQ+/b2MrRIDDZ4axoEzJQ=;
        b=yZdeCC8uD787zdQC6G5JsyAxzKfFJfx7ZUIamhyzGf6Osh5LjYeoHzpjPrGnA3O7UQ
         AeqHG5xHpM/8cX3dQROj7Yz1kO9WHf4to+BlBUYTshdNEDXTI9Y/jj334AVSPadoOPFj
         kbnQsl3YgqYw88Wr6p9jwEZKrOdwxAqAgGWNXoUZVoPitb7bZ7Rq/1DiIsPe3BXbcVqe
         Cy9VynrRT5Ue/Zk/lN1wz/mZiaNMYTWlCBLeRMXZoJ4c6DzAlohXl18cWlzXZDyTx5lF
         vreuusYBBnmbSd+fypBw4ZqtpCUhR1fQKc1KCZnoXZ4Rm+ot36rKkboNqAVpUbkthxBM
         iOew==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=20161025;
        h=date:from:to:cc:message-id:in-reply-to:references:subject
         :mime-version:x-original-sender:reply-to:precedence:mailing-list
         :list-id:list-post:list-help:list-archive:list-subscribe
         :list-unsubscribe;
        bh=PrrP1iOT9DwB4vR4WQ33o6TQ+/b2MrRIDDZ4axoEzJQ=;
        b=jM/8jvYSHU/wQFLosATM/tLbeYx/EhqLRciEoAvNM9iho0RMLMRD/SbKuI+B8xkUpE
         PV8vdTcN6N9eDQcgCOGpmVINMIllQW0oI2bo2Heq3dnEfulMn+WLEQpXRr0ABl/r/uSZ
         icVmNYUjEyuyuIwk7nI4cGp19GAVV4fCtqVAlXkgXK+nufITP7zW2Ed9F/7BTBDKLgZM
         wN/Dgsg7fZdXcRvJf0ybLWY9fSjTJpNy4XZ986uLveeUdx1glHOaiWWkMH4julMAI+pw
         pEa2XSvvs5/nqFT6XDnhykgzOhGgIlTbPfp6PYtGUcOjPeNsQK9uI7ZPEbHNuTmrZpO8
         Cfpw==
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: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=PrrP1iOT9DwB4vR4WQ33o6TQ+/b2MrRIDDZ4axoEzJQ=;
        b=MKNTwc5I2B14QQmkMek78QsJZxyZPDCMn/8mGfYYrV9Upz/e3lt8ur9ujwhToa66dd
         89C+kFpiID3XaY2Nmki/xFNqTuhAhP5ag5QOZIK0/ETgaSzntpfjTsnWwgQ8ulhqzZw3
         poa0oPlRJJXrtexlR661zvugkZjhAV9lSbCneKvdoYOcao25+gwmPnHIwPomST+DFdWn
         k+2NuGw1i88t3kHCw3+TUw1qkfeCif5O7vpqEF20A+Nd8hqRguqIbDqvm/wcm0Eo0ZpP
         zbzhkmcpUor1VIgLfz/bmjbisDOGYdOFOXqKBXYFN710dMV2C482UNQ6WYX1tXZdN6XR
         9F7w==
X-Gm-Message-State: AIVw111Wc8kfue1gZffytyUBs2Y3BilWfub/TbERl80vMMlHJKbxFQ4D
	whlMmeH54LUf4us2
X-Received: by 10.129.118.1 with SMTP id r1mr4934722ywc.100.1501557191140;
        Mon, 31 Jul 2017 20:13:11 -0700 (PDT)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.107.180.215 with SMTP id d206ls9596915iof.31.gmail; Mon, 31
 Jul 2017 20:13:09 -0700 (PDT)
X-Received: by 10.31.142.14 with SMTP id q14mr42933vkd.19.1501557189833;
        Mon, 31 Jul 2017 20:13:09 -0700 (PDT)
In-Reply-To: <CAGsORuCiG=92weihTxedEHNxe9zo4WDWps5jdem-5Hpshh32CA@mail.gmail.com>
X-Original-Sender: jmckesson@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:33482
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/33482>

------=_Part_76_1858211338.1501557189300
Content-Type: multipart/alternative; 
	boundary="----=_Part_77_279750495.1501557189300"

------=_Part_77_279750495.1501557189300
Content-Type: text/plain; charset="UTF-8"

On Monday, July 31, 2017 at 10:28:55 PM UTC-4, Zhihao Yuan wrote:
>
> On Mon, Jul 31, 2017 at 2:42 PM, Thiago Macieira <thi...@macieira.org 
> <javascript:>> wrote: 
> > It definitely isn't for non-trivial types, but I don't 
> > know if it should be allowed for trivial ones. 
> > 
> > [...] 
> > 
> > Either way, that doesn't stop us from allowing: 
> > 
> >         Agg a { .y = 5, .x = 5 }; 
> > 
>
> I've stated my concern with dividing the feature 
> into trivial types only and those not -- it brings 
> damage when the library evolves. 
>
> However, I feel it's more acceptable if we allocate 
> a syntax to let people opt-in.  I mean, what if 
> such a discrimination happens only when a 
> user asks for it by using the = { ... } initializer 
> (copy-init syntax)?


Right, because the thing we most need to do is make "uniform 
initialization" *less uniform*.

No, having copy-list-initialization work (almost) exactly like 
direct-list-initialization is one of the best aspects of 
list-initialization. We should not undo that lightly.

If unordered designated initializers are dangerous enough to need their own 
special syntax, then they're too dangerous for C++.

-- 
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/8c0ebca3-0dbd-444b-b0b0-845eca5b0de7%40isocpp.org.

------=_Part_77_279750495.1501557189300
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">On Monday, July 31, 2017 at 10:28:55 PM UTC-4, Zhihao Yuan=
 wrote:<blockquote class=3D"gmail_quote" style=3D"margin: 0;margin-left: 0.=
8ex;border-left: 1px #ccc solid;padding-left: 1ex;">On Mon, Jul 31, 2017 at=
 2:42 PM, Thiago Macieira &lt;<a href=3D"javascript:" target=3D"_blank" gdf=
-obfuscated-mailto=3D"qUKfw5eiBAAJ" rel=3D"nofollow" onmousedown=3D"this.hr=
ef=3D&#39;javascript:&#39;;return true;" onclick=3D"this.href=3D&#39;javasc=
ript:&#39;;return true;">thi...@macieira.org</a>&gt; wrote:
<br>&gt; It definitely isn&#39;t for non-trivial types, but I don&#39;t
<br>&gt; know if it should be allowed for trivial ones.
<br>&gt;
<br>&gt; [...]
<br>&gt;
<br>&gt; Either way, that doesn&#39;t stop us from allowing:
<br>&gt;
<br>&gt; =C2=A0 =C2=A0 =C2=A0 =C2=A0 Agg a { .y =3D 5, .x =3D 5 };
<br>&gt;
<br>
<br>I&#39;ve stated my concern with dividing the feature
<br>into trivial types only and those not -- it brings
<br>damage when the library evolves.
<br>
<br>However, I feel it&#39;s more acceptable if we allocate
<br>a syntax to let people opt-in. =C2=A0I mean, what if
<br>such a discrimination happens only when a
<br>user asks for it by using the =3D { ... } initializer
<br>(copy-init syntax)?</blockquote><div><br>Right, because the thing we mo=
st need to do is make &quot;uniform initialization&quot; <i>less uniform</i=
>.<br><br>No, having copy-list-initialization work (almost) exactly like di=
rect-list-initialization is one of the best aspects of list-initialization.=
 We should not undo that lightly.<br><br>If unordered designated initialize=
rs are dangerous enough to need their own special syntax, then they&#39;re =
too dangerous for C++.</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/8c0ebca3-0dbd-444b-b0b0-845eca5b0de7%=
40isocpp.org?utm_medium=3Demail&utm_source=3Dfooter">https://groups.google.=
com/a/isocpp.org/d/msgid/std-proposals/8c0ebca3-0dbd-444b-b0b0-845eca5b0de7=
%40isocpp.org</a>.<br />

------=_Part_77_279750495.1501557189300--

------=_Part_76_1858211338.1501557189300--

.
