The newer -Wdelete-non-virtual-dtor has no false positives and fewer
bugs. There is very little reason to use -Wnon-virtual-dtor instead.
gcc/ChangeLog:
* doc/invoke.texi (C++ Dialect Options): Recommend using
-Wdelete-non-virtual-dtor instead of -Wnon-virtual-dtor.
case it is possible but unsafe to delete an instance of a derived
class through a pointer to the class itself or base class. This
warning is automatically enabled if @option{-Weffc++} is specified.
+The @option{-Wdelete-non-virtual-dtor} option (enabled by @option{-Wall})
+should be preferred because it warns about the unsafe cases without false
+positives.
@item -Wregister @r{(C++ and Objective-C++ only)}
@opindex Wregister