https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85470
Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2018-04-19 CC| |jason at gcc dot gnu.org Ever confirmed|0 |1 --- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> --- r200450 added - if (DECL_DECLARED_CONSTEXPR_P (decl)) + if (DECL_DECLARED_CONSTEXPR_P (decl) + || DECL_IN_AGGR_P (decl)) I wonder if it shouldn't have been DECL_INITIALIZED_IN_CLASS_P instead, or DECL_IN_AGGR_P (decl) && DECL_INITIALIZED_IN_CLASS_P (decl). If DECL_IN_AGGR_P (decl) check is right here, then the question is why it is set when there is the extern template line (and not otherwise).