Bug 43071 - g++ 2.96: In instantiation of `array<1, 8, integer>' : Internal error: Segmentation fault.
g++ 2.96: In instantiation of `array<1, 8, integer>' : Internal error: Segmen...
Product: Red Hat Linux
Classification: Retired
Component: gcc (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Jakub Jelinek
David Lawrence
Depends On:
  Show dependency treegraph
Reported: 2001-05-31 09:56 EDT by Robert K. Moniot
Modified: 2007-04-18 12:33 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-06-01 08:26:18 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
Sample c++ code that causes compiler to seg fault (413 bytes, text/plain)
2001-05-31 09:58 EDT, Robert K. Moniot
no flags Details

  None (edit)
Description Robert K. Moniot 2001-05-31 09:56:37 EDT
From Bugzilla Helper:
User-Agent: Mozilla/4.77 [en] (X11; U; Linux 2.2.19-6.2.1 i586)

Description of problem:
When compiling a C++ program produced from a Pascal original by ptoc v3.52,
instantiation of an array gives Internal error: Segmentation fault.

How reproducible:

Steps to Reproduce:
1. Download http://www.ispras.ru/~knizhnik/ptoc-3.52.tar.gz, untar.
2. Copy bug.cxx source (attached) into ptoc directory.
3. g++ -O5 -g -Wall -c  -I. -o bug.o -c bug.cxx

Actual Results:  array.h: In instantiation of `array<1, 8, integer>':
bug.cxx:23:   instantiated from here
array.h:184: Internal error: Segmentation fault.
Please submit a full bug report.
See <URL:http://bugzilla.redhat.com/bugzilla/> for instructions.

Expected Results:  Normal compilation, no error messages.

Additional info:

The attached sample program bug.cxx is as small as I can get it to
show the bug.  The ptoc source is only needed to supply the two include
files io.h and array.h.
Comment 1 Robert K. Moniot 2001-05-31 09:58:18 EDT
Created attachment 20030 [details]
Sample c++ code that causes compiler to seg fault
Comment 2 Jakub Jelinek 2001-06-01 08:26:13 EDT
Name mangling bug where it did not handle properly the subtraction in
format_string<high_bound-low_bound+1>((char*)a.buf, width);
Will be fixed in gcc-c++-2.96-86.

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