This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

c++/2657: ostream and namespace declarations conflict



>Number:         2657
>Category:       c++
>Synopsis:       ostream and namespace declarations conflict
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Apr 26 13:26:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     Lakshman
>Release:        gcc2.95.2 on Solaris 7, gcc2.95.3 on Linux 2.4
>Organization:
>Environment:
Solaris, Linux
>Description:
If there is an ostream<< declaration in a namespace,
ostream << std::string doesn't get recognized.
>How-To-Repeat:
compile the file with the last line
uncommented.
>Fix:
currently doing bar.c_str() everywhere this
happens.
>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: application/octet-stream; name="test.cc"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="test.cc"

I2luY2x1ZGUgPGlvc3RyZWFtPgojaW5jbHVkZSA8c3RyaW5nPgoKbmFtZXNwYWNlIGZvb2Jhcgp7
CiAgdGVtcGxhdGU8Y2xhc3MgVD4KICBjbGFzcyBGb29CYXIKICB7CiAgcHVibGljOgogICAgZnJp
ZW5kIHN0ZDo6b3N0cmVhbSYgb3BlcmF0b3IgPDwgKHN0ZDo6b3N0cmVhbSYgb3MsCiAgICAgICAg
ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc3QgRm9vQmFyJiBmKQogICAgICB7CiAg
ICAgICAgb3MgPDwgZi5hOwogICAgICAgIHJldHVybiBvczsKICAgICAgfQogICAgRm9vQmFyKFQg
aSA9IFQoKSkgOiBhKGkpCiAgICAgIHsKICAgICAgfQogIHByaXZhdGU6CiAgICBUIGE7CiAgfQog
IDsKfQoKaW50IG1haW4oKQp7CiAgc3RkOjpzdHJpbmcgYmFyKCIzIik7CgogIC8vIG9rYXkKICBz
dGQ6OmNvdXQgPDwgZm9vYmFyOjpGb29CYXI8aW50PigxKSA8PCAiIGlzIGEgbmFtZXNwYWNlIG9i
amVjdC5cbiI7CgogIC8vIHRoaXMgbGluZSBjYXVzZXMgYW4gZXJyb3IgaWYgRm9vQmFyIGlzIGRl
ZmluZWQgaW4gYSBuYW1lc3BhY2UKICAvL3N0ZDo6Y291dCA8PCBiYXIgPDwgIiBpcyBhIHN0cmlu
Zy5cbiI7Cn0K


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]