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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
            Summary|Error initializing of const |Error initializing of const
                   |aggregate variable with a   |union variable with a
                   |mutable field               |mutable field
     Ever confirmed|0                           |1
   Last reconfirmed|                            |2023-06-26

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to Andrew Pinski from comment #1)
> struct also fails ...

Well clang does not reject that case but MSVC does.
So I don't think the struct case is a GCC bug; just clang does not have a
check.

Reply via email to