Re: [PATCH] c++: Fix folding of non-dependent BASELINKs [PR95468]

2021-02-22 Thread Jason Merrill via Gcc-patches
On 2/13/21 10:21 PM, Patrick Palka wrote: On Fri, 12 Feb 2021, Patrick Palka wrote: Here, the problem ultimately seems to be that tsubst_copy_and_build, when called with empty args as we do during non-dependent expression folding, doesn't touch BASELINKs at all: it delegates to tsubst_copy whic

Re: [PATCH] c++: Fix folding of non-dependent BASELINKs [PR95468]

2021-02-13 Thread Patrick Palka via Gcc-patches
On Fri, 12 Feb 2021, Patrick Palka wrote: > Here, the problem ultimately seems to be that tsubst_copy_and_build, > when called with empty args as we do during non-dependent expression > folding, doesn't touch BASELINKs at all: it delegates to tsubst_copy > which then immediately exits early due to

[PATCH] c++: Fix folding of non-dependent BASELINKs [PR95468]

2021-02-12 Thread Patrick Palka via Gcc-patches
Here, the problem ultimately seems to be that tsubst_copy_and_build, when called with empty args as we do during non-dependent expression folding, doesn't touch BASELINKs at all: it delegates to tsubst_copy which then immediately exits early due to the empty args. This means that the CAST_EXPR int