c++/3625: Segmentation fault, while compiling template source code.
drahos@etunnels.com
drahos@etunnels.com
Mon Jul 9 11:26:00 GMT 2001
>Number: 3625
>Category: c++
>Synopsis: Segmentation fault, while compiling template source code.
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Mon Jul 09 11:26:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator: Drahos Cagan
>Release: gcc 3.0
>Organization:
>Environment:
Linux i686, kernel 2.4.5
>Description:
Please find the enclosed demonstration example. If I forget to specify the template types for vector base class, g++ compiler crashes (segmentation fault) without reporting any compiling errors in the source.
>How-To-Repeat:
Simply "g++ -c bug.cpp"
>Fix:
Compiler works fine if I uncomment the template types for the base class (uncomment the section in bug.cpp).
>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: application/octet-stream; name="bug.cpp"; name="bug.cpp"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="bug.cpp"
I2luY2x1ZGUgPHZlY3Rvcj4KCnRlbXBsYXRlIDxjbGFzcyBULCBjbGFzcyBBbGxvY2F0b3IgPSBz
dGQ6OmFsbG9jYXRvcjxUPiA+CmNsYXNzIG15X3ZlY3RvciA6IHB1YmxpYyBzdGQ6OnZlY3RvcjxU
LCBBbGxvY2F0b3I+IHsKcHVibGljOgoJbXlfdmVjdG9yKHNpemVfdCBzKTsKfTsKCnRlbXBsYXRl
IDxjbGFzcyBULCBjbGFzcyBBbGxvY2F0b3I+Cm15X3ZlY3RvcjxULCBBbGxvY2F0b3I+OjpteV92
ZWN0b3Ioc2l6ZV90IHMpIDogc3RkOjp2ZWN0b3IvKjxULCBBbGxvY2F0b3I+Ki8ocykKe30K
More information about the Gcc-prs
mailing list