c++/2581: Internal error: Segmentation fault. g++ compiler message
dee@dechert.econ.uh.edu
dee@dechert.econ.uh.edu
Wed Apr 18 09:16:00 GMT 2001
>Number: 2581
>Category: c++
>Synopsis: Internal error: Segmentation fault. g++ compiler message
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Apr 18 09:16:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator: dee@dechert.econ.uh.edu
>Release: unknown-1.0
>Organization:
>Environment:
>Description:
A do-while loop that has the following error with the ;
do{
}
while(x>0;);
produces the segmentation fault error and "please generate
a bug report" message.
>How-To-Repeat:
compile the program,
>Fix:
Obviously, don't put a ; where it doesn't belong. I'm
sending this so that is some future version, it'll be
cleaned up.
>Release-Note:
>Audit-Trail:
>Unformatted:
>g++ -c bug.c
This program doesn't do anything. It just illustrates that
this coding error produces these messages. Presumably the
compiler shoud trap this coding error and not kick out the
segmentation fault and the request for a report.
----gnatsweb-attachment----
Content-Type: application/octet-stream; name="bug.c"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="bug.c"
I2luY2x1ZGUgPHN0ZGxpYi5oPgojaW5jbHVkZSA8c3RkaW8uaD4KCmludCBtYWluKHZvaWQpewoJ
ZG91YmxlIHggPSAwLjI7Cglkb3sKCQl4IC09IDAuMTsKCX0KCXdoaWxlICh4ID4gMDspOwoJcmV0
dXJuIDA7Cn0K
More information about the Gcc-prs
mailing list