public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* Re: c++/6695: Regression: template friend declaration doesn't work
@ 2002-06-05  7:04 lerdsuwa
  0 siblings, 0 replies; 4+ messages in thread
From: lerdsuwa @ 2002-06-05  7:04 UTC (permalink / raw)
  To: benko, gcc-bugs, gcc-prs, nobody

Synopsis: Regression: template friend declaration doesn't work

State-Changed-From-To: open->analyzed
State-Changed-By: lerdsuwa
State-Changed-When: Wed Jun  5 07:04:39 2002
State-Changed-Why:
    Confirmed.  A regression from GCC 3.0.4.

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


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

* Re: c++/6695: Regression: template friend declaration doesn't work
@ 2002-06-27 14:50 mmitchel
  0 siblings, 0 replies; 4+ messages in thread
From: mmitchel @ 2002-06-27 14:50 UTC (permalink / raw)
  To: benko, gcc-bugs, gcc-prs, mmitchel

Synopsis: Regression: template friend declaration doesn't work

State-Changed-From-To: analyzed->closed
State-Changed-By: mmitchel
State-Changed-When: Thu Jun 27 14:46:44 2002
State-Changed-Why:
    Fixed in GCC 3.1.1.

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


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

* Re: c++/6695: Regression: template friend declaration doesn't work
@ 2002-06-27 10:56 mmitchel
  0 siblings, 0 replies; 4+ messages in thread
From: mmitchel @ 2002-06-27 10:56 UTC (permalink / raw)
  To: benko, gcc-bugs, gcc-prs, mmitchel, nobody

Synopsis: Regression: template friend declaration doesn't work

Responsible-Changed-From-To: unassigned->mmitchel
Responsible-Changed-By: mmitchel
Responsible-Changed-When: Thu Jun 27 09:44:29 2002
Responsible-Changed-Why:
    I will investigate.

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


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

* c++/6695: Regression: template friend declaration doesn't work
@ 2002-05-17  6:16 benko
  0 siblings, 0 replies; 4+ messages in thread
From: benko @ 2002-05-17  6:16 UTC (permalink / raw)
  To: gcc-gnats


>Number:         6695
>Category:       c++
>Synopsis:       Regression: template friend declaration doesn't work
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri May 17 06:16:01 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     Benko Pal
>Release:        3.1
>Organization:
>Environment:
SuSE 7.3, i686
>Description:
I want all instances of a class template
be friends of each other.
The syntax

template <typename T>
class a
{
  template <typename> friend class a;
};

works; it works even if this class is nested in
another class b.
But if this class b is itself a template, then I got an
error.  With 3.0.4 it worked.
>How-To-Repeat:
arta:~/c/proba$ g++3 templfriend2.cc
templfriend2.cc: In constructor `b<V>::a<T>::a(const b<V>::a<T*>&) [with T = 
   char, V = void*]':
templfriend2.cc:44:   instantiated from here
templfriend2.cc:12: `char*b<void*>::a<char*>::t_' is private
templfriend2.cc:29: within this context
zsh: exit 1     g++3 templfriend2.cc
arta:~/c/proba$ g++3 templfriend2.cc -DWORKS
arta:~/c/proba$ /gml/shared/gcc-3.0.4/bin/g++ templfriend2.cc
arta:~/c/proba$ g++3 -v
Reading specs from /gml/shared/gcc-3.1/lib/gcc-lib/i686-pc-linux-gnu/3.1/specs
Configured with: ../gcc-3.1/configure --prefix=/gml/shared/gcc-3.1 --enable-languages=c++ --with-dwarf2 --enable-threads=posix
Thread model: posix
gcc version 3.1
arta:~/c/proba$ /gml/shared/gcc-3.0.4/bin/g++ -v
Reading specs from /gml/shared/gcc-3.0.4/lib/gcc-lib/i686-pc-linux-gnu/3.0.4/specs
Configured with: ../gcc-3.0.4/configure --prefix=/gml/shared/gcc-3.0.4 --enable-threads=posix --enable-languages=c++
Thread model: posix
gcc version 3.0.4
arta:~/c/proba$ 
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: application/octet-stream; name="templfriend2.cc"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="templfriend2.cc"

IyBpZm5kZWYgV09SS1MKdGVtcGxhdGUgPHR5cGVuYW1lIFY+CiMgZW5kaWYgLy8gV09SS1MKc3Ry
dWN0IGIKewogIHRlbXBsYXRlIDx0eXBlbmFtZSBUPgogIGNsYXNzIGEKICB7CiAgICB0ZW1wbGF0
ZSA8dHlwZW5hbWU+CiAgICBmcmllbmQgY2xhc3MgYTsKCiAgICBUIHRfOwoKICAgcHVibGljOgog
ICAgYSgpIHt9CiAgICBhKGE8VCAqPiBjb25zdCAmKTsKICB9Owp9OwoKIyBpZm5kZWYgV09SS1MK
dGVtcGxhdGUgPHR5cGVuYW1lIFY+CiMgZW5kaWYgLy8gV09SS1MKdGVtcGxhdGUgPHR5cGVuYW1l
IFQ+CmIKIyBpZm5kZWYgV09SS1MKPFY+CiMgZW5kaWYgLy8gV09SS1MKOjphPFQ+OjphKGE8VCAq
PiBjb25zdCAmcmhzKTogdF8oKnJocy50XykKe30KCgppbnQKbWFpbigpCnsKICBiCiMgaWZuZGVm
IFdPUktTCiAgICA8dm9pZCAqPgojIGVuZGlmIC8vIFdPUktTCiAgICA6OmE8Y2hhciAqPiBxOwog
IGIKIyBpZm5kZWYgV09SS1MKICAgIDx2b2lkICo+CiMgZW5kaWYgLy8gV09SS1MKICAgIDo6YTxj
aGFyPiB3KHEpOwoKICByZXR1cm4gMDsKfQo=


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

end of thread, other threads:[~2002-06-27 21:46 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-06-05  7:04 c++/6695: Regression: template friend declaration doesn't work lerdsuwa
  -- strict thread matches above, loose matches on Subject: below --
2002-06-27 14:50 mmitchel
2002-06-27 10:56 mmitchel
2002-05-17  6:16 benko

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).