From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-40134.protonmail.ch (mail-40134.protonmail.ch [185.70.40.134]) by sourceware.org (Postfix) with ESMTPS id 9FE343858D33 for ; Sat, 23 Dec 2023 07:10:17 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 9FE343858D33 Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=protonmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=protonmail.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 9FE343858D33 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=185.70.40.134 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1703315419; cv=none; b=IkmV5v57gO6rfkKRx1WaGOmdJgwaceej2i6Ko/JbGpOvbeqk896AXHesfPlb83GZMmUAe/INi5d1/s76t9N/2O0fOTmU4bShcPVM+LboUoZeBXVQEm5fzdmhzvgymShBPQz/cTgZpt6MQ4H9OXLTbMburJdUaiibadvv/pJJHS4= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1703315419; c=relaxed/simple; bh=K9wkUzkQOpwH9cwqhntutapAdcxk4KGvFCKLwDe0yJQ=; h=DKIM-Signature:Date:To:From:Subject:Message-ID:MIME-Version; b=U2hmmzNve1nCj4P98zQrJMwKgj7UrI+wln05mLPtSxG+YIEEPZt0PKRuvhCoBfjl6SqqrpO7HhWxDO0kM7NNS0Mn/Fze+DEbtkezGb0sdKK3bnYUZ+u6BOgo/fNTHWM+4YBkQVmkZY94WqSKZcv1suMbrwcR3Uw4z8vqD5T8ut4= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1703315416; x=1703574616; bh=K9wkUzkQOpwH9cwqhntutapAdcxk4KGvFCKLwDe0yJQ=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=iMFp2Sh0IDpjTwMxbRMT4aN0IEg5w/9n87T83Dmg+ZGfbcY6bhS5HCeAmBWJeNXh9 Msd4CRMtYdmA/2b50GLAw2MnEzYuooMyo53Vcm4oHY2LI+vu6fH2Yf3RYLV/Nx26ff IjKu5dNm2tcgMLqIZHSf6nMBUeBlleFHmp3Rn+OoPhf1fc43Uqb5ChT0wJyzyCrlw8 PdT2BDIgWRyg3qhdJgTAReYJ2mUSRZCxqvupfcwNjbZYZsRGtOg8b51NOYmgouPesz FNPQ1MuOTTe5p81OkzdPzQ8tBjNPk6qJLR8QIQwmQRCn58qD0peB40RzdgFVlwJzJW IEFgWPSWAUU5A== Date: Sat, 23 Dec 2023 07:10:09 +0000 To: Jason Merrill From: waffl3x Cc: "gcc-patches@gcc.gnu.org" Subject: Re: [PATCH v7 1/1] c++: Initial support for P0847R7 (Deducing This) [PR102609] Message-ID: In-Reply-To: <4e1adee6-269a-4a27-ad23-2742277d7889@redhat.com> References: <575c0bbe-a3d6-4a54-b299-edff64df84b1@redhat.com> <59LofhYhxl7MLEuElXwZcESRB6MpjdG-iq-89B63siDRo5k0j-y6z-PVa6Y3iE1xE5LkJwpwTFi82bd0RZjB1yZbSJptFdPTBWfvOGj1W78=@protonmail.com> <4e1adee6-269a-4a27-ad23-2742277d7889@redhat.com> Feedback-ID: 14591686:user:proton MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,KAM_SHORT,RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On Friday, December 22nd, 2023 at 10:26 AM, Jason Merrill wrote: >=20 >=20 > On 12/22/23 04:01, waffl3x wrote: >=20 > > int n =3D 0; > > auto f =3D [](this Self){ > > static_assert(__is_same (decltype(n), int)); > > decltype((n)) a; // { dg-error {is not captured} } > > }; > > f(); > >=20 > > Could you clarify if this error being removed was intentional. I do > > recall that Patrick Palka wanted to remove this error in his patch, but > > it seemed to me like you stated it would be incorrect to allow it. > > Since the error is no longer present I assume I am misunderstanding the > > exchange. > >=20 > > In any case, let me know if I need to modify my test case or if this > > error needs to be added back in. >=20 >=20 > Removing the error was correct under > https://eel.is/c++draft/expr.prim#id.unqual-3 > Naming n in that lambda would not refer a capture by copy, so the > decltype is the same as outside the lambda. >=20 > Jason Alright, I've fixed my tests to reflect that. I've got defaulting assignment operators working. Defaulting equality and comparison operators seemed to work out of the box somehow, so I just have to make some fleshed out tests for those cases. There can always be more tests, I have a few ideas for what still needs to be covered, mostly with dependent lambdas. Tests for xobj conversion operators definitely need to be more fleshed out. I also need to formulate some tests to make sure constraints are not being taking into account when the object parameters should not correspond, but that's a little more tough to test for than the valid cases. Other than tests though, is there anything you can think of that the patch is missing? Other than the aforementioned tests, I'm pretty confident everything is done. To recap, I have CWG2789 implemented on my end with the change we discussed to require corresponding object parameters instead of the same type, and I have CWG2586 implemented. I can't recall what other outstanding issues we had, and my notes don't mention anything other than tests. So I'm assuming everything is good. Alex