on Debian squeeze, Linux 2.6.26-2-amd64 #1 SMP: The following incorrect code cause g++ to segfault on "g++ (Debian 4.3.3-3) 4.3.3" but not on "g++ (GCC) 4.1.1 20070105 (Red Hat 4.1.1-51)":
================================================ // g++ -Wall -save-temps -c bugreport0.cpp template<typename pointer_type> struct Registry { pointer_type pointer; // copy-paste error should not cause ICE virtual ~ModuleRegistry() { delete pointer; } }; struct ModuleRegistry: public Registry<int *> {}; ================================================ compilation log: ================================================ g++ -Wall -save-temps -c bugreport0.cpp bugreport0.cpp:8: internal compiler error: Segmentation fault Please submit a full bug report, with preprocessed source if appropriate. See <file:///usr/share/doc/gcc-4.3/README.Bugs> for instructions. Compilation exited abnormally with code 1 at Thu May 28 12:03:42 ================================================ -- Summary: regression? ICE (segfault) on invalid virtual dtor in template Product: gcc Version: 4.3.3 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: poftwaresatent at gmail dot com GCC build triplet: x86_64-linux-gnu GCC host triplet: x86_64-linux-gnu GCC target triplet: x86_64-linux-gnu http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40284