Applied
Index: changes.html =================================================================== RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-4.7/changes.html,v retrieving revision 1.60 diff -u -r1.60 changes.html --- changes.html 19 Nov 2011 15:15:13 -0000 1.60 +++ changes.html 19 Nov 2011 22:02:48 -0000 @@ -312,6 +312,14 @@ of types with non-trivial destructors, as they are already destroyed at end of full-expression; the change is that now the storage is released as well.</p></li> + + <li>A new command-line option <code>-Wdelete-non-virtual-dtor</code> + has been added to warn when <code>delete</code> is used to destroy + an instance of a class which has virtual functions and non-virtual + destructor. It is unsafe to delete an instance of a derived class + through a pointer to a base class if the base class does not have a + virtual destructor. This warning is enabled by <code>-Wall</code>. + </li> </ul> <h4>Runtime Library (libstdc++)</h4>