Re: [PATCH] c++: Fall through for arrays of T vs T cv [PR104996]

2022-04-12 Thread Jason Merrill via Gcc-patches
On 3/24/22 17:06, Jason Merrill wrote: On 3/22/22 16:59, Marek Polacek via Gcc-patches wrote: On Tue, Mar 22, 2022 at 08:39:21PM +, Ed Catmur wrote: If two arrays do not have the exact same element type including qualification, this could be e.g. f(int (&&)[]) vs. f(int const (&)[]), which

Re: [PATCH] c++: Fall through for arrays of T vs T cv [PR104996]

2022-03-24 Thread Jason Merrill via Gcc-patches
On 3/22/22 16:59, Marek Polacek via Gcc-patches wrote: On Tue, Mar 22, 2022 at 08:39:21PM +, Ed Catmur wrote: If two arrays do not have the exact same element type including qualification, this could be e.g. f(int (&&)[]) vs. f(int const (&)[]), which can still be distinguished by the lval

Re: [PATCH] c++: Fall through for arrays of T vs T cv [PR104996]

2022-03-22 Thread Marek Polacek via Gcc-patches
On Tue, Mar 22, 2022 at 08:39:21PM +, Ed Catmur wrote: > If two arrays do not have the exact same element type including > qualification, this could be e.g. f(int (&&)[]) vs. f(int const (&)[]), which > can still be distinguished by the lvalue-rvalue tiebreaker. > > By tightening this branch

[PATCH] c++: Fall through for arrays of T vs T cv [PR104996]

2022-03-22 Thread Ed Catmur
If two arrays do not have the exact same element type including qualification, this could be e.g. f(int (&&)[]) vs. f(int const (&)[]), which can still be distinguished by the lvalue-rvalue tiebreaker. By tightening this branch (in accordance with the letter of the Standard) we fall through to