Re: [PATCH] c++: Small incremental tweak to source_location::current() folding

2021-11-29 Thread Jason Merrill via Gcc-patches
On 11/27/21 03:52, Jakub Jelinek wrote: On Wed, Nov 24, 2021 at 11:42:28PM +0100, Jakub Jelinek via Gcc-patches wrote: I'm surprised the source_location::current handling would be needed; why do calls to that function live long enough for us to walk into the ADDR_EXPR here? Maybe we should fold

[PATCH] c++: Small incremental tweak to source_location::current() folding

2021-11-27 Thread Jakub Jelinek via Gcc-patches
On Wed, Nov 24, 2021 at 11:42:28PM +0100, Jakub Jelinek via Gcc-patches wrote: > > I'm surprised the source_location::current handling would be needed; why do > > calls to that function live long enough for us to walk into the ADDR_EXPR > > here? Maybe we should fold it in cp_fold instead of cp_ge