From mboxrd@z Thu Jan 1 00:00:00 1970 From: philippeb@videotron.ca To: gcc-gnats@gcc.gnu.org Subject: c++/3637: Internal compiler error in finish_member_declaration Date: Tue, 10 Jul 2001 15:46:00 -0000 Message-id: <20010710223822.3916.qmail@sourceware.cygnus.com> X-SW-Source: 2001-07/msg00277.html List-Id: >Number: 3637 >Category: c++ >Synopsis: Internal compiler error in finish_member_declaration >Confidential: no >Severity: serious >Priority: medium >Responsible: unassigned >State: open >Class: sw-bug >Submitter-Id: net >Arrival-Date: Tue Jul 10 15:46:00 PDT 2001 >Closed-Date: >Last-Modified: >Originator: g++ 3.0 >Release: 20010402 (Debian prerelease) >Organization: >Environment: Debian i386 >Description: Internal comipler error when attempting to instanciate a template class scope template class from a template class using a template class scope typedef (with the typename keyword). I get the following messages: recursivetemplate.cpp: In instantiation of `c1::c2': recursivetemplate.cpp:19: instantiated from `c1<_T>::c2<_U>::c2() [with _U = void, _T = int]' recursivetemplate.cpp:29: instantiated from `void foo() [with _T = int]' recursivetemplate.cpp:35: instantiated from here recursivetemplate.cpp:16: Internal compiler error in finish_member_declaration, at cp/semantics.c:1844 Please submit a full bug report, with preprocessed source if appropriate. See for instructions. >How-To-Repeat: >Fix: 1- Move the nested template class into global namespace 2- Don't instanciate the nested template class using a nested typedef 3- Instanciate everything from a non class member >Release-Note: >Audit-Trail: >Unformatted: ----gnatsweb-attachment---- Content-Type: text/x-c++src; name="recursivetemplate.cpp" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="recursivetemplate.cpp" I2luY2x1ZGUgPGlvc3RyZWFtPgoKdXNpbmcgbmFtZXNwYWNlIHN0ZDsKCnRlbXBsYXRlIDxjbGFz cyBfVD4gc3RydWN0IHRyYWl0cwp7Cgl0eXBlZGVmIGxvbmcgbmV4dDsKfTsKCgp0ZW1wbGF0ZSA8 Y2xhc3MgX1Q+CglzdHJ1Y3QgYzEKCXsKCQl0ZW1wbGF0ZSA8Y2xhc3MgX1U+CgkJCXN0cnVjdCBj MgoJCQl7CgkJCQljMigpCgkJCQl7CgkJCQkJY291dCA8PCBfX1BSRVRUWV9GVU5DVElPTl9fIDw8 IGVuZGw7CgkJCQl9CgkJCX07Cgl9OwoKCnRlbXBsYXRlIDxjbGFzcyBfVD4KCXZvaWQgZm9vKCkK CXsKCQljb3V0IDw8IF9fUFJFVFRZX0ZVTkNUSU9OX18gPDwgZW5kbDsKCQljMTx0eXBlbmFtZSB0 cmFpdHM8X1Q+OjpuZXh0Pjo6YzI8dm9pZD4oKTsKCX0KCgppbnQgbWFpbigpCnsKCWZvbzxpbnQ+ KCk7Cn0K