From mboxrd@z Thu Jan 1 00:00:00 1970
Return-Path:
Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124])
by sourceware.org (Postfix) with ESMTP id 3DFBC384A459
for ; Mon, 19 Aug 2024 20:53:07 +0000 (GMT)
DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 3DFBC384A459
Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com
Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com
ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 3DFBC384A459
Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.133.124
ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1724100789; cv=none;
b=Z79tEGwIQDBFgtcsh9ZWafnH6jxaGgkNzTLE8dq3CAXHfhCbSNw8DJTTLJ6J3xIShexwjmCpzRvG4+2lacdTGsPOM1iH0f21pTh2aHKaFM0G8Yyw7TWcWnQ1JyUbmqRaZL2OzNTNzzH1F+RjzqlQE28p9/vJCxa6k5MGqBpm1U0=
ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key;
t=1724100789; c=relaxed/simple;
bh=fccKlScumlicdaQ16E1+pp0s22+tcQQO6Z0UYs6cOzI=;
h=DKIM-Signature:Date:From:To:Subject:Message-ID:MIME-Version; b=K4TKU+upG8Z5QRDKAKWr4lkMhAW6vhetqeq7eE/yP/FxKzuWcALEBjpooiLoEeBzlhGBx6wiWlmrZXhIEzZCNNQfZvF83tr9F49rnnGNm0un/id+A1F9TZPFIF0MsU+D3Wu96BZzwrQUiTt5h76mOFVxgiN/zf3TV/4LV0mxBQo=
ARC-Authentication-Results: i=1; server2.sourceware.org
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;
s=mimecast20190719; t=1724100787;
h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
to:to:cc:cc:mime-version:mime-version:content-type:content-type:
in-reply-to:in-reply-to:references:references;
bh=yPMsQfbxSIfZl7tWPfB9RU0g8jYdLhxzXXSZzAiJpEM=;
b=L7ezBkiEF0WDOJMK60/i8HDV2KfAizedkzFGM8QDl7C9tEYp1pOXIicvjLwh7lFVAWyPSM
waDNg38MFB9Xy4CryfFdSXHncuUf69V7pkHAxeJTwgHsvRa5unA9JGxzBDhXfoMkemmiL8
2TPrdyHyfZV8GmSYx+aSBk5ytrICfnM=
Received: from mail-ot1-f72.google.com (mail-ot1-f72.google.com
[209.85.210.72]) by relay.mimecast.com with ESMTP with STARTTLS
(version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id
us-mta-332-beJ-PXOlMnOYhsbk0GujDQ-1; Mon, 19 Aug 2024 16:53:05 -0400
X-MC-Unique: beJ-PXOlMnOYhsbk0GujDQ-1
Received: by mail-ot1-f72.google.com with SMTP id 46e09a7af769-70c92c98858so4567234a34.1
for ; Mon, 19 Aug 2024 13:53:05 -0700 (PDT)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20230601; t=1724100784; x=1724705584;
h=user-agent:in-reply-to:content-disposition:mime-version:references
:message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc
:subject:date:message-id:reply-to;
bh=yPMsQfbxSIfZl7tWPfB9RU0g8jYdLhxzXXSZzAiJpEM=;
b=NHGoMBv3olzSvDY0F8Z1zd55VcsDELP+NInKGl5KHN3p2ZUuWBKv010aK+iuMnR+GG
X7Mi/buDhaf2SZGN0i5EmZRPM4gtjMSTPwMCLVxKeQ3nM9Wme9O7LIlhVtlTO8t2aYiQ
3YCpnTPO/iSVawp8AAc0lwVL/YfF6Skp199+2I2xQLNRUFv7gAoLN+t/etus1aLFCLEq
fVRAIst4zlQFaP1egEN0xVQUJYUX7KhpzANlrotmDKn1hCuD1QwilfZiLGbY4gNEt2a2
1nLG+d1XVSVzEo4BULX2rymxqenshBIjHdqutqFBvin66FIJvPaYgxEyGgFq7AeL9UMj
4dtg==
X-Gm-Message-State: AOJu0Yz2P97J1/WRBrNwXn2ltFZ2Hj7+iyKhfWNJySAH9fFJP2JYzaic
NOgOc24td9c93yzUKoGClTffVJ84ZIGp9rEug3BONSz2TrYYfpax14dmlJfBROA24TRkP2JBJJe
hUWH/nwxGv9jX04heofH3DnohQM+dN+Gjo5+wN0NbAnFrmjbjjizAs/w=
X-Received: by 2002:a05:6830:43a7:b0:70c:934c:b1e2 with SMTP id 46e09a7af769-70cac83968amr13371819a34.7.1724100784463;
Mon, 19 Aug 2024 13:53:04 -0700 (PDT)
X-Google-Smtp-Source: AGHT+IGaRszZZywsrdkPRJiKv5nCQDnUJKPXGWIAR6t7ESJGSc1x2DbuALGvqJx93aP6CdHaACgYCw==
X-Received: by 2002:a05:6830:43a7:b0:70c:934c:b1e2 with SMTP id 46e09a7af769-70cac83968amr13371808a34.7.1724100783986;
Mon, 19 Aug 2024 13:53:03 -0700 (PDT)
Received: from redhat.com ([2603:7000:9500:34a5::1db4])
by smtp.gmail.com with ESMTPSA id d75a77b69052e-45369fd9de3sm43960491cf.5.2024.08.19.13.53.03
(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
Mon, 19 Aug 2024 13:53:03 -0700 (PDT)
Date: Mon, 19 Aug 2024 16:53:02 -0400
From: Marek Polacek
To: Gerald Pfeifer
Cc: gcc-patches@gcc.gnu.org, Jonathan Wakely
Subject: Re: [wwwdocs] porting_to: Two-stage overload resolution for implicit
move removed
Message-ID:
References:
<1892d73a-c210-358c-fe40-c1bafc17fd13@pfeifer.com>
MIME-Version: 1.0
In-Reply-To: <1892d73a-c210-358c-fe40-c1bafc17fd13@pfeifer.com>
User-Agent: Mutt/2.2.12 (2023-09-09)
X-Mimecast-Spam-Score: 0
X-Mimecast-Originator: redhat.com
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
X-Spam-Status: No, score=-12.2 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,KAM_SHORT,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE,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 Mon, Aug 19, 2024 at 10:51:28PM +0200, Gerald Pfeifer wrote:
> On Wed, 12 Oct 2022, Marek Polacek via Gcc-patches wrote:
> > +
> > +The two overload resolutions approach was complicated and quirky, so users
> > +should transition to the newer model. This change means that code that
> > +previously didn't compile in C++17 will now compile, for example:
>
> I looked at this recently and am wondering whether there is a word
> missing: "two overload" -> "two-stage overload"?
>
> If so, the patch below addresses that
>
> On the way, I changed "[code] will now compile" to "[code] may now
> compile", since not every code that failed to compile before will now
> compile (e.g., syntactically incorrect code).
>
> What do you think?
LGTM, thanks.
> diff --git a/htdocs/gcc-13/porting_to.html b/htdocs/gcc-13/porting_to.html
> index c727d66f..e595e120 100644
> --- a/htdocs/gcc-13/porting_to.html
> +++ b/htdocs/gcc-13/porting_to.html
> @@ -82,9 +82,10 @@ not in C++17). Then C++23 P2266
> removed the fallback overload resolution, and changed the implicit move
> rules once again.
>
> -The two overload resolutions approach was complicated and quirky, so users
> -should transition to the newer model. This change means that code that
> -previously didn't compile in C++17 will now compile, for example:
> +The two-stage overload resolutions approach was complicated and
> +quirky, so users should transition to the newer model. This change
> +means that code that previously didn't compile in C++17 may now
> +compile, for example:
>
>
> struct S1 { S1(S1 &&); };
>
Marek