220 41574 <566197ea-a415-4d2d-9adc-b2a2ff26bdf9@isocpp.org> article
Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail
From: =?UTF-8?Q?=27Thomas_K=C3=B6ppe=27_via_ISO_C=2B=2B_Standard_=2D_Future_Proposals?= <std-proposals@isocpp.org>
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: operator[]= (array subscript assignment operator)
Date: Sun, 17 Mar 2019 12:00:14 -0700 (PDT)
Approved: news@gmane.org
Message-ID: <566197ea-a415-4d2d-9adc-b2a2ff26bdf9@isocpp.org>
References: <39460c2e-f24c-4819-8678-267387948e69@isocpp.org>
Reply-To: std-proposals@isocpp.org
Mime-Version: 1.0
Content-Type: multipart/mixed; 
	boundary="----=_Part_1270_2047099319.1552849214526"
Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226";
	logging-data="59168"; mail-complaints-to="usenet@blaine.gmane.org"
Cc: wpmgprostotema@gmail.com
To: ISO C++ Standard - Future Proposals <std-proposals@isocpp.org>
Original-X-From: std-proposals+bncBDH3JAEPRQFBBQFSXLSAKGQEWMIK3VI@isocpp.org Sun Mar 17 20:00:20 2019
Return-path: <std-proposals+bncBDH3JAEPRQFBBQFSXLSAKGQEWMIK3VI@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-yw1-f71.google.com ([209.85.161.71])
	by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
	(Exim 4.89)
	(envelope-from <std-proposals+bncBDH3JAEPRQFBBQFSXLSAKGQEWMIK3VI@isocpp.org>)
	id 1h5b19-000FHb-5m
	for gclcip-std-proposals@m.gmane.org; Sun, 17 Mar 2019 20:00:19 +0100
Original-Received: by mail-yw1-f71.google.com with SMTP id d64sf19515252ywa.17
        for <gclcip-std-proposals@m.gmane.org>; Sun, 17 Mar 2019 12:00:18 -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=xkMZnZHrGUnpDofPXS5lmsPNzlwg5dbIA1nqdIedAYo=;
        b=Dtu61h80W1dya90+EvmFy2wy8+XTAKvT+RMMSph23JvnNLQuhv8S8Ma4EyZCbUoIxa
         lPKSMvQ8Yfvg6DFUI58iDug3/cUUM0joF0kO+OX7hoECVjfN6JfxXWn7oBNydsNdjpjU
         bvmAZ2fhJuk7k6iJAHkuaUL8PCk0TOxKN8sooM9n8TGjDKl3FdfCt6dtCzmyndxR5nQX
         9uKnMMhIGfhgimwx2lRaX5FbBFVlqVOSEQ4/5EqT6EPb3Dp+uBas7CdOL2EUEwcbGotx
         Wf2xJVp761C8ma3HIbJBM39oAo2TIb2rgXixRqAJAXCgHqiTas2Zx0Zdrft3Khmcwz8J
         jrrw==
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=xkMZnZHrGUnpDofPXS5lmsPNzlwg5dbIA1nqdIedAYo=;
        b=gL5zK1hxVqO8Vpp8mYHOeDFEsj2SrxMdqHtE/3ead/r860KWl0IFOTNdSm/ayvME5X
         vsMtrq/Vs4X7VJPZhAab99YpSuE2pK/w/P88dAyAc/3QmsgoIqx7UEwUfxsJOrx11QzD
         dNylEq2MOcu5ke39Qt3eF041VFK87021+jem1uvJhositnjup+AMZ27ApsJaAL3KNBPC
         vmFoPTrPPfctEHRsOHD+yyTsmaVPIr7zUJ3/SgDcqbpIUwlKO4xk3wW5VEcMRKstk5el
         cuzoQafPo3kzmITZs0WMcQwL6JP+mOkJgbX4RRsdnc9TwnC7bNnPLYVhNARJPKzoYsF5
         Ao0w==
X-Gm-Message-State: APjAAAV8X5kK92XcQ1pnANG0nj+MgIpGOrvFGNq+T6WNijeR3xQwf5cH
	AcG8OTaYbuaUqOW0U9oVURf9dQ==
X-Google-Smtp-Source: APXvYqwPOrwMqROXjsYeLqK7o88mshPmPnKHsT6z6xkIQIDf0Nn6G1MUAdLauNu9gNjzdlAPShuR6w==
X-Received: by 2002:a25:1c2:: with SMTP id 185mr8031044ybb.87.1552849217692;
        Sun, 17 Mar 2019 12:00:17 -0700 (PDT)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 2002:a25:1384:: with SMTP id 126ls3152434ybt.1.gmail; Sun, 17 Mar
 2019 12:00:15 -0700 (PDT)
X-Received: by 2002:a25:6d46:: with SMTP id i67mr11747960ybc.384.1552849215456;
        Sun, 17 Mar 2019 12:00:15 -0700 (PDT)
In-Reply-To: <39460c2e-f24c-4819-8678-267387948e69@isocpp.org>
X-Original-Sender: tkoeppe@google.com
X-Original-From: =?UTF-8?Q?Thomas_K=C3=B6ppe?= <tkoeppe@google.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:41574
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/41574>

------=_Part_1270_2047099319.1552849214526
Content-Type: multipart/alternative; 
	boundary="----=_Part_1271_1103837066.1552849214527"

------=_Part_1271_1103837066.1552849214527
Content-Type: text/plain; charset="UTF-8"

A few thoughts on proxies, in a modern light:

   - We should probably have "proxy invalidation" rules. It seems tricky to 
   implement something like looking up an existing value into a proxy, then 
   allowing an interleaving deletion of that element, and then still letting 
   that proxy do something useful.
   - That said, the proxy could have a two-fold nature: if the key was 
   found, it stores only the relevant iterator. If the key was not found, it 
   stores a special kind of *node-handle* where the mapped-element isn't 
   constructed yet, along with relevant hint information (a lower-bound 
   iterator for ordered maps, and a precomputed hash for unordered maps). 
   Having the *node-handle* solves the problem of retaining the key for 
   later use without making copies or having dangling references. Upon 
   assignment, the mapped-element is constructed in-place and the node handle 
   is inserted.
   
   

-- 
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/566197ea-a415-4d2d-9adc-b2a2ff26bdf9%40isocpp.org.

------=_Part_1271_1103837066.1552849214527
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">A few thoughts on proxies, in a modern light:<div><ul><li>=
We should probably have &quot;proxy invalidation&quot; rules. It seems tric=
ky to implement something like looking up an existing value into a proxy, t=
hen allowing an interleaving deletion of that element, and then still letti=
ng that proxy do something useful.</li><li>That said, the proxy could have =
a two-fold nature: if the key was found, it stores only the relevant iterat=
or. If the key was not found, it stores a special kind of=C2=A0<i>node-hand=
le</i> where the mapped-element isn&#39;t constructed yet, along with relev=
ant hint information (a lower-bound iterator for ordered maps, and a precom=
puted hash for unordered maps). Having the <i>node-handle</i> solves the pr=
oblem of retaining the key for later use without making copies or having da=
ngling references. Upon assignment, the mapped-element is constructed in-pl=
ace and the node handle is inserted.<br><br></li></ul></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/566197ea-a415-4d2d-9adc-b2a2ff26bdf9%=
40isocpp.org?utm_medium=3Demail&utm_source=3Dfooter">https://groups.google.=
com/a/isocpp.org/d/msgid/std-proposals/566197ea-a415-4d2d-9adc-b2a2ff26bdf9=
%40isocpp.org</a>.<br />

------=_Part_1271_1103837066.1552849214527--

------=_Part_1270_2047099319.1552849214526--

.
