[Bug c++/110661] Weird handing for deleting a void* pointer

"pinskia at gcc dot gnu.org via Gcc-bugs" <[email protected]>
Newsgroups gmane.comp.gcc.bugs
Message-ID <[email protected]/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110661

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
             Blocks|55004                       |
   Last reconfirmed|                            |2026-08-11
             Status|UNCONFIRMED                 |NEW
           Keywords|                            |wrong-code

--- Comment #2 from Drea Pinski <pinskia at gcc dot gnu.org> ---
  /* Deleting ptr to void is undefined behavior [expr.delete/3].  */
  if (VOID_TYPE_P (TREE_TYPE (type)))
    {
      if (complain & tf_warning)
        warning_at (exp_loc, OPT_Wdelete_incomplete,
                    "deleting %qT is undefined", type);
      doing_vec = 0;
    }


Referenced Bugs:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55004
[Bug 55004] [meta-bug] constexpr issues
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.