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

--- Comment #10 from Martin Sebor <msebor at gcc dot gnu.org> ---
(In reply to Serdar Sanli from comment #9)
> A simpler example not involving any globals, causing Wfree-nonheap-object
> warning since GCC11

This is actually a bug in the example: it's invalid to decrement a pointer to
the beginning of an object as done in Foo::allocate.

Reply via email to