------- Additional Comments From bangerth at dealii dot org 2004-12-02 20:12 ------- That's as short as I can get it for now: ---------------------- #include <string> struct Record { unsigned int a, b, c, d, e; std::string description; }; template <typename T> void foobar () { const Record record = {0,0,0,0,0,std::string()}; } template void foobar<int> (); --------------------------- source/a.cc: In function 'void foobar() [with T = int]': source/a.cc:14: instantiated from here source/a.cc:12: warning: unused variable 'record' source/a.cc:12: internal compiler error: in cp_expr_size, at cp/cp-objcp-common.c:86 Please submit a full bug report, with preprocessed source if appropriate. See <URL:http://gcc.gnu.org/bugs.html> for instructions. Surprisingly, the number of elements in the structure do make a difference! W.
-- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18793