[Bug libstdc++/87544] alloc-size-larger-than incorrectly triggered

msebor at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Wed Oct 10 02:05:00 GMT 2018


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

--- Comment #16 from Martin Sebor <msebor at gcc dot gnu.org> ---
The warning code considers just the argument to the call.  It doesn't know (and
in the constant case can't tell) where the argument came from.  It would need
to be reworked to tell the difference (e.g., along the lines of
-Wmaybe-uninitialized).  It might be worth looking into at some point.


More information about the Gcc-bugs mailing list