Bug 204394 - gcc segmentation fault when typename preceeds specified template
gcc segmentation fault when typename preceeds specified template
Status: CLOSED DUPLICATE of bug 204395
Product: Red Hat Enterprise Linux 2.1
Classification: Red Hat
Component: gcc (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Jakub Jelinek
Depends On:
  Show dependency treegraph
Reported: 2006-08-28 16:46 EDT by Peter Tippett
Modified: 2007-11-30 17:06 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2006-08-29 04:36:03 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Peter Tippett 2006-08-28 16:46:44 EDT
Description of problem:
When compiling code that uses the typename keyword against a template that 
hasn't been typedef'd (I'm actually not sure how best to describe it... but 
it's trivial to reproduce) then you get a segmentation fault.

Version-Release number of selected component (if applicable):
The version of Linux (uname -a) is actually:
Linux vanpglnx29 2.6.9-5.ELsmp #1 SMP Wed Jan 5 19:30:39 EST 2005 i686 i686 
i386 GNU/Linux
and the version of gcc (gcc --version) is:
gcc (GCC) 3.4.3 20041212 (Red Hat 3.4.3-9.EL4)

How reproducible:
Every time.

Steps to Reproduce:
Compile the following cpp program using gcc (e.g. gcc test.cpp).
Actual results:
Segmentation fault.

Expected results:
No segmentation fault.

Additional info:
Try to compile this code:

#include <map>
using namespace std;

int main (int argv, char** argc) {
  map<int,int> mymap;
  mymap.insert(typename map<int,int>::value_type(1,1));
  return 0;
Comment 1 Jakub Jelinek 2006-08-29 04:36:03 EDT

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

Note You need to log in before you can comment on or make changes to this bug.