Re: [PATCH] c++: parameterized requires-expr as default argument [PR101725]

2021-08-11 Thread Jason Merrill via Gcc-patches
On 8/3/21 4:04 PM, Patrick Palka wrote: Here we're rejecting the default template argument requires (T t) { x(t); } because we consider the 't' in the requirement to be a local variable (according to local_variable_p), and we generally forbid local variables from appearing inside template ar

Re: [PATCH] c++: parameterized requires-expr as default argument [PR101725]

2021-08-11 Thread Jason Merrill via Gcc-patches
On 8/3/21 4:04 PM, Patrick Palka wrote: Here we're rejecting the default template argument requires (T t) { x(t); } because we consider the 't' in the requirement to be a local variable (according to local_variable_p), and we generally forbid local variables from appearing inside template ar

[PATCH] c++: parameterized requires-expr as default argument [PR101725]

2021-08-03 Thread Patrick Palka via Gcc-patches
Here we're rejecting the default template argument requires (T t) { x(t); } because we consider the 't' in the requirement to be a local variable (according to local_variable_p), and we generally forbid local variables from appearing inside template arguments. We can perhaps fix this by giving