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

--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> ---
(In reply to Drea Pinski from comment #1)
> cp/typeck2.cc:1377
>               /* Not a flexible array member.  */
>               int size = TREE_INT_CST_LOW (TYPE_SIZE (type));
>               size = (size + BITS_PER_UNIT - 1) / BITS_PER_UNIT;
> 
> 
> That should be HOST_WIDE_INT instead.

Not enough, it should use TYPE_SIZE_UNIT instead which should be
already rounded appropriately.

Reply via email to