Bug 28863 - ICE on template class with visibility specification
Summary: ICE on template class with visibility specification
Status: RESOLVED DUPLICATE of bug 28659
Alias: None
Product: gcc
Classification: Unclassified
Component: c++ (show other bugs)
Version: 4.1.1
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
Keywords: ice-on-valid-code
Depends on:
Reported: 2006-08-27 01:56 UTC by Bernardo Innocenti
Modified: 2006-08-28 06:20 UTC (History)
7 users (show)

See Also:
Known to work:
Known to fail: 4.2.0
Last reconfirmed:


Note You need to log in before you can comment on or make changes to this bug.
Description Bernardo Innocenti 2006-08-27 01:56:47 UTC
The following testcase:

 template<class T> class __attribute__((visibility("default"))) Foo
   Foo<T> bar();

 template<class T> Foo<T> Foo<T>::bar()


 foo.cpp: In member function &#8216;Foo<T> Foo<T>::bar()&#8217;:
 foo.cpp:6: internal compiler error: Segmentation fault
Comment 1 Andrew Pinski 2006-08-27 02:07:29 UTC
This works for me with "4.2.0 20060823" and "4.1.2 20060814" on "i686-pc-linux-gnu".
Comment 2 David Fang 2006-08-27 07:45:33 UTC
Looks recently fixed by patch for PR 28659.  
Comment 3 Andrew Pinski 2006-08-27 15:41:29 UTC
You must have something backported to 4.1.x because the patch which orginally caused this was only on the mainline.

*** This bug has been marked as a duplicate of 28659 ***