On Wed, 29 Mar 2023 10:13:39 -0000 (UTC)
Charlie R <
charl...@wp.pl> wrote:
>Thu, 16 Mar 2023 11:38:20 +0100, Bo Persson:
>
>> On 2023-03-16 at 10:01,
Mut...@dastardlyhq.com wrote:
>>> I was looking at some Go code last night and it has don't-care
>>> placeholders in range based loops. So I was wondering if something like
>>> this might be a good idea for C++ 23/26:
>>>
>>> vector<tuple<string,string,int>> v;
>>> :
>>> :
>>> for(auto [_,s2,_]: v) do something with s2 or for(auto &[_,s2,_]: v)
>>> ....
>>>
>>> or perhaps
>>>
>>> for(auto [,s2,]: v) .....
>>>
>>> It would only be a small gain in efficiency but might be useful.
>>>
>>>
>> There is already a proposal for this:
>>
>>
https://wg21.link/p2169
>
>std::lock_guard _(mutex1);