Re: [PATCH] c++: Fix CTAD for aggregates in template [PR95568]

2020-06-24 Thread Jason Merrill via Gcc-patches
On 6/23/20 6:58 PM, Marek Polacek wrote: 95568 complains that CTAD for aggregates doesn't work within requires-clause and it turned out that it doesn't work when we try the deduction in a template. The reason is that maybe_aggr_guide creates a guide that can look like this template X(decltyp

[PATCH] c++: Fix CTAD for aggregates in template [PR95568]

2020-06-23 Thread Marek Polacek via Gcc-patches
95568 complains that CTAD for aggregates doesn't work within requires-clause and it turned out that it doesn't work when we try the deduction in a template. The reason is that maybe_aggr_guide creates a guide that can look like this template X(decltype (X::x))-> X where the parameter is a decl