https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65579

Paolo Carlini <paolo.carlini at oracle dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |paolo.carlini at oracle dot com

--- Comment #3 from Paolo Carlini <paolo.carlini at oracle dot com> ---
Hi Martin. Are you still actively working on this? Because something
implementing as trivially as the below what Jason suggested on the mailing list
already appears to pass testing, shouldn't be *that* far from an actual fix...

Index: decl.c
===================================================================
--- decl.c      (revision 253091)
+++ decl.c      (working copy)
@@ -12348,7 +12348,11 @@

     /* Set constexpr flag on vars (functions got it in grokfndecl).  */
     if (constexpr_p && VAR_P (decl))
-      DECL_DECLARED_CONSTEXPR_P (decl) = true;
+      {
+       DECL_DECLARED_CONSTEXPR_P (decl) = true;
+       if (!processing_template_decl)
+         complete_type (TREE_TYPE (decl));
+      }

     /* Record constancy and volatility on the DECL itself .  There's
        no need to do this when processing a template; we'll do this

Reply via email to