public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* c++/5093: internal error with template template argument class and overloaded out stream operator
@ 2001-12-12  5:36 tobias.oberstein
  0 siblings, 0 replies; 3+ messages in thread
From: tobias.oberstein @ 2001-12-12  5:36 UTC (permalink / raw)
  To: gcc-gnats


>Number:         5093
>Category:       c++
>Synopsis:       internal error with template template argument class and overloaded out stream operator
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          ice-on-legal-code
>Submitter-Id:   net
>Arrival-Date:   Wed Dec 12 05:36:09 PST 2001
>Closed-Date:
>Last-Modified:
>Originator:     tobias.oberstein@gmx.de
>Release:        2.95.3
>Organization:
>Environment:
SuSE Linux 7.2 off-the-shelf
>Description:
Look at this template class, which takes a (unused)
template template argument:

template <typename T,
          template <typename> class C = std::vector>
struct Bug
{
    T x_;
};

now try the following

Bug<int> x;
std::cout << x;

even without defining the overloaded out operator, g++
will exit with an "internal compiler error" ;(


>How-To-Repeat:
toberste@grenada:~/work/pre/suffixtree > g++ -Wall -o bug bug.cpp
bug.cpp: In function `int main()':
bug.cpp:50: Internal compiler error.
bug.cpp:50: Please submit a full bug report.
bug.cpp:50: See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions.
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: text/x-c++src; name="bug.cpp"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="bug.cpp"

LyoKICogVGhpcyBzb3VyY2UgcmVwcm9kdWNlcyBhIGdjYyBjb21waWxlciBidWcgd2l0aAogKgog
KiAgICAgPj4+IHRlbXBsYXRlIHRlbXBsYXRlIGFyZ3VtZW50cyBhbmQgU1RMIHN0cmVhbXMgPDw8
CiAqCiAqIGdjYyAyLjk1LjMsIFN1U0UgTGludXggNy4yCiAqCiAqIHRvYmlhcy5vYmVyc3RlaW5A
Z214LmRlCiAqIDEyLzEyLzIwMDEKICovCgojaW5jbHVkZSA8aW9zdHJlYW0+CiNpbmNsdWRlIDx2
ZWN0b3I+Cgp0ZW1wbGF0ZSA8dHlwZW5hbWUgVD4Kc3RydWN0IE9rCnsKICAgIFQgeF87Cn07Cgp0
ZW1wbGF0ZSA8dHlwZW5hbWUgVD4Kb3N0cmVhbSYKb3BlcmF0b3I8PCAob3N0cmVhbSYgb3MsIE9r
PFQ+JiB4KQp7CiAgICByZXR1cm4gb3MgPDwgeC54XzsKfQoKdGVtcGxhdGUgPHR5cGVuYW1lIFQs
CiAgICAgICAgICB0ZW1wbGF0ZSA8dHlwZW5hbWU+IGNsYXNzIEMgPSBzdGQ6OnZlY3Rvcj4Kc3Ry
dWN0IEJ1Zwp7CiAgICBUIHhfOwp9OwoKdGVtcGxhdGUgPHR5cGVuYW1lIFQsCiAgICAgICAgICB0
ZW1wbGF0ZSA8dHlwZW5hbWU+IGNsYXNzIEM+Cm9zdHJlYW0mCm9wZXJhdG9yPDwgKG9zdHJlYW0m
IG9zLCBCdWc8VCxDPiYgeCkKewogICAgcmV0dXJuIG9zIDw8IHgueF87Cn0KCgppbnQgbWFpbigp
CnsKICAgIE9rPGludD4gb2s7ICAvLyBObyBwcm9ibGVtIGhlcmUuCiAgICBzdGQ6OmNvdXQgPDwg
b2s7CgogICAgQnVnPGludD4gYnVnOyAgLy8gUHJvYmxlbTogaW50ZXJuYWwgY29tcGlsZXIgZXJy
b3IuCiAgICBzdGQ6OmNvdXQgPDwgYnVnOwogICAgcmV0dXJuIDA7Cn0K


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: c++/5093: internal error with template template argument class and overloaded out stream operator
@ 2001-12-12  7:06 rodrigc
  0 siblings, 0 replies; 3+ messages in thread
From: rodrigc @ 2001-12-12  7:06 UTC (permalink / raw)
  To: nobody; +Cc: gcc-prs

The following reply was made to PR c++/5093; it has been noted by GNATS.

From: rodrigc@gcc.gnu.org
To: gcc-bugs@gcc.gnu.org, gcc-gnats@gcc.gnu.org, gcc-prs@gcc.gnu.org,
  nobody@gcc.gnu.org, tobias.oberstein@gmx.de
Cc:  
Subject: Re: c++/5093: internal error with template template argument class and overloaded out stream operator
Date: 12 Dec 2001 14:56:13 -0000

 Synopsis: internal error with template template argument class and overloaded out stream operator
 
 State-Changed-From-To: open->closed
 State-Changed-By: rodrigc
 State-Changed-When: Wed Dec 12 06:56:13 2001
 State-Changed-Why:
     Works with gcc 3.0.3 20011207 (prerelease)
 
 http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&pr=5093&database=gcc


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: c++/5093: internal error with template template argument class and overloaded out stream operator
@ 2001-12-12  6:56 rodrigc
  0 siblings, 0 replies; 3+ messages in thread
From: rodrigc @ 2001-12-12  6:56 UTC (permalink / raw)
  To: gcc-bugs, gcc-gnats, gcc-prs, nobody, tobias.oberstein

Synopsis: internal error with template template argument class and overloaded out stream operator

State-Changed-From-To: open->closed
State-Changed-By: rodrigc
State-Changed-When: Wed Dec 12 06:56:13 2001
State-Changed-Why:
    Works with gcc 3.0.3 20011207 (prerelease)

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&pr=5093&database=gcc


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2001-12-12 15:06 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-12-12  5:36 c++/5093: internal error with template template argument class and overloaded out stream operator tobias.oberstein
2001-12-12  6:56 rodrigc
2001-12-12  7:06 rodrigc

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).