On Wed, Jan 17, 2018 at 5:34 AM, Jakub Jelinek <ja...@redhat.com> wrote: > On Fri, Jan 12, 2018 at 05:09:24PM -0500, David Malcolm wrote: >> PR c++/83814 reports an ICE introduced by the location wrapper patch >> (r256448), affecting certain memset calls within templates. > > Note, I think this issue sadly affects a lot of code, so it is quite urgent. > > That said, wonder if we really can't do any folding when > processing_template_decl, could we e.g. do at least maybe_constant_value, > or fold if the expression is not type nor value dependent?
Yes, in a template we should call fold_non_dependent_expr. > BTW, never know if cp_fold_rvalue is a superset of maybe_constant_value or > not. It is. Jason