public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/29236]  New: Friend operators for class with template in template argument does not compile
@ 2006-09-26 14:04 4ekucT at tut dot by
  2006-09-26 14:08 ` [Bug c++/29236] " 4ekucT at tut dot by
                   ` (22 more replies)
  0 siblings, 23 replies; 24+ messages in thread
From: 4ekucT at tut dot by @ 2006-09-26 14:04 UTC (permalink / raw)
  To: gcc-bugs

The following code does not compile because class TestBad has both template in
template argument T2 and friend operators.

template <class T>
class Temp {};

template <class T1, template <class> class T2>
class TestBad
{
public:
  template <class OtherT1, template <class> class OtherT2>
  friend bool operator == (const TestBad<OtherT1, OtherT2>& a, const
TestBad<OtherT1, OtherT2>& b);
  template <class OtherT1, template <class> class OtherT2>
  friend bool operator != (const TestBad<OtherT1, OtherT2>& a, const
TestBad<OtherT1, OtherT2>& b);

private:
  T2<T1> vector;
};

template <class OtherT1, template <class> class OtherT2>
bool operator == (const TestBad<OtherT1, OtherT2>& a, const TestBad<OtherT1,
OtherT2>& b)
{
  (void)a;
  (void)b;
  return true;
}

template <class OtherT1, template <class> class OtherT2>
bool operator != (const TestBad<OtherT1, OtherT2>& a, const TestBad<OtherT1,
OtherT2>& b)
{
  (void)a;
  (void)b;
  return false;
}

int main(int argc, char* argv[])
{
  bool result;
  TestBad<int, Temp> a;
  TestBad<int, Temp> b;

  result = (a == b);

  (void)a;
  (void)b;
  (void)result;
  (void)argc;
  (void)argv;
  return 0;
}

I've tried with gcc 3.4.4 in Mingw32 and it shows me the following error
message:

test.cpp: In function `int main(int, char**)':
test.cpp:43: error: ambiguous overload for 'operator==' i
n 'a == b'
test.cpp:23: note: candidates are: bool operator==(const
TestBad<OtherT1, OtherT2>&, const TestBad<OtherT1, OtherT2>&) [with OtherT1 =
in
t, OtherT2 = Temp]
test.cpp:13: note:                 bool operator==(const
TestBad<OtherT1, OtherT2>&, const TestBad<OtherT1, OtherT2>&) [with OtherT1 =
in
t, OtherT2 = Temp, T1 = int, T2 = Temp]

PS: With out template in template argument everything is fine!


-- 
           Summary: Friend operators for class with template in template
                    argument does not compile
           Product: gcc
           Version: 3.4.4
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: 4ekucT at tut dot by


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] Friend operators for class with template in template argument does not compile
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
@ 2006-09-26 14:08 ` 4ekucT at tut dot by
  2006-09-26 14:14 ` 4ekucT at tut dot by
                   ` (21 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: 4ekucT at tut dot by @ 2006-09-26 14:08 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from 4ekucT at tut dot by  2006-09-26 14:07 -------
Created an attachment (id=12330)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=12330&action=view)
Friend operators with template in template argument

Test example which shows compiler error message.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] Friend operators for class with template in template argument does not compile
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
  2006-09-26 14:08 ` [Bug c++/29236] " 4ekucT at tut dot by
@ 2006-09-26 14:14 ` 4ekucT at tut dot by
  2006-10-10  4:11 ` [Bug c++/29236] [4.0/4.1/4.2? regression] Bogus ambiguity with templates + friend bangerth at dealii dot org
                   ` (20 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: 4ekucT at tut dot by @ 2006-09-26 14:14 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from 4ekucT at tut dot by  2006-09-26 14:14 -------
I've just tested this code under VC8 and it accepted it without errors.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2? regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
  2006-09-26 14:08 ` [Bug c++/29236] " 4ekucT at tut dot by
  2006-09-26 14:14 ` 4ekucT at tut dot by
@ 2006-10-10  4:11 ` bangerth at dealii dot org
  2006-10-10  4:13 ` bangerth at dealii dot org
                   ` (19 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: bangerth at dealii dot org @ 2006-10-10  4:11 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from bangerth at dealii dot org  2006-10-10 04:11 -------
Confirmed:
--------------
template <typename T> struct A {};

template <template <typename> class P>
struct B {
    template <template <typename> class Q>
    friend bool foo (const B<Q>& a);
};

template <template <typename> class Q>
bool foo (const B<Q>& a);

void bar () {
  B<A> a;
  foo (a);
}
--------------------------

g/x> /home/bangerth/bin/gcc-4.2-pre/bin/c++ -c x.cc
x.cc: In function &#8216;void bar()&#8217;:
x.cc:14: error: call of overloaded &#8216;foo(B<A>&)&#8217; is ambiguous
x.cc:10: note: candidates are: bool foo(const B<Q>&) [with Q = A]
x.cc:6: note:                 bool foo(const B<Q>&) [with Q = A, P = A]


icc accepts the code. I believe we simply forget to unify the tentative
declaration from the friend declaration with the real template once we
encounter it, and end up with two declarations instead of one. We then
get confused when we have to pick one of the two.

This is a regression introduced in 3.2 over 2.95.

W.


-- 

bangerth at dealii dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |bangerth at dealii dot org
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
           Keywords|                            |rejects-valid
      Known to fail|                            |3.2.3 3.3.5 3.4.6 4.0.1
                   |                            |4.1.1 4.2.0
      Known to work|                            |2.95
           Priority|P3                          |P2
   Last reconfirmed|0000-00-00 00:00:00         |2006-10-10 04:11:45
               date|                            |
            Summary|Friend operators for class  |[4.0/4.1/4.2? regression]
                   |with template in template   |Bogus ambiguity with
                   |argument does not compile   |templates + friend
   Target Milestone|---                         |4.2.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2? regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (2 preceding siblings ...)
  2006-10-10  4:11 ` [Bug c++/29236] [4.0/4.1/4.2? regression] Bogus ambiguity with templates + friend bangerth at dealii dot org
@ 2006-10-10  4:13 ` bangerth at dealii dot org
  2006-10-10  4:31 ` pinskia at gcc dot gnu dot org
                   ` (18 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: bangerth at dealii dot org @ 2006-10-10  4:13 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from bangerth at dealii dot org  2006-10-10 04:13 -------
btw, this only happens if Q is really a template template argument. As noted
by the original reporter, the problem goes away if Q is simply a template
argument.

W.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2? regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (3 preceding siblings ...)
  2006-10-10  4:13 ` bangerth at dealii dot org
@ 2006-10-10  4:31 ` pinskia at gcc dot gnu dot org
  2006-10-10  9:46 ` [Bug c++/29236] [4.0/4.1/4.2 Regression] " rguenth at gcc dot gnu dot org
                   ` (17 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-10-10  4:31 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from pinskia at gcc dot gnu dot org  2006-10-10 04:31 -------
foo should not have been injected by the friend.
Note the Priority should be only changed by the release manager.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to fail|3.2.3 3.3.5 3.4.6 4.0.1     |3.2.3 3.3.5 3.4.6 4.0.1
                   |4.1.1 4.2.0                 |4.1.1 4.2.0 3.0.4
           Priority|P2                          |P3


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (4 preceding siblings ...)
  2006-10-10  4:31 ` pinskia at gcc dot gnu dot org
@ 2006-10-10  9:46 ` rguenth at gcc dot gnu dot org
  2006-10-10 14:25 ` bangerth at dealii dot org
                   ` (16 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2006-10-10  9:46 UTC (permalink / raw)
  To: gcc-bugs



-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |rguenth at gcc dot gnu dot
                   |                            |org
      Known to fail|3.2.3 3.3.5 3.4.6 4.0.1     |3.2.3 3.3.5 3.4.6 4.0.3
                   |4.1.1 4.2.0 3.0.4           |4.1.1 4.2.0 3.0.4
            Summary|[4.0/4.1/4.2? regression]   |[4.0/4.1/4.2 Regression]
                   |Bogus ambiguity with        |Bogus ambiguity with
                   |templates + friend          |templates + friend
   Target Milestone|4.2.0                       |4.0.4


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (5 preceding siblings ...)
  2006-10-10  9:46 ` [Bug c++/29236] [4.0/4.1/4.2 Regression] " rguenth at gcc dot gnu dot org
@ 2006-10-10 14:25 ` bangerth at dealii dot org
  2006-10-10 16:23 ` mark at codesourcery dot com
                   ` (15 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: bangerth at dealii dot org @ 2006-10-10 14:25 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from bangerth at dealii dot org  2006-10-10 14:25 -------
(In reply to comment #5)
> foo should not have been injected by the friend.

True, but that's irrelevant here. We get a tentative declaration that we
simply have to unify with the later real declaration.


> Note the Priority should be only changed by the release manager.

We've been over that before, Andrew. It has always been the case that
bugmasters do the initial triage, including setting an initial priority.
We've done that at least back to 2002, when we were still using GNATS instead
of bugzilla. It is also true that the RM has the prerogative to downgrade
priorities if he doesn't deem things that important. 

I maintain that it is important to raise the priority of PRs that are
rejects-valid so that they get some visibility, and in particular of
regressions. If someone higher up in the food chain thinks otherwise
wants to downgrade things, that's fine by me. But it's not productive
if bugmasters quarrel among themselves if something should be a P2 or a
P3 ...

W.


-- 

bangerth at dealii dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mmitchel at gcc dot gnu dot
                   |                            |org
           Priority|P3                          |P2


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (6 preceding siblings ...)
  2006-10-10 14:25 ` bangerth at dealii dot org
@ 2006-10-10 16:23 ` mark at codesourcery dot com
  2006-10-12  3:09 ` mmitchel at gcc dot gnu dot org
                   ` (14 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: mark at codesourcery dot com @ 2006-10-10 16:23 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from mark at codesourcery dot com  2006-10-10 16:23 -------
Subject: Re:  [4.0/4.1/4.2 Regression] Bogus ambiguity with
 templates + friend

bangerth at dealii dot org wrote:

> We've been over that before, Andrew. It has always been the case that
> bugmasters do the initial triage, including setting an initial priority.
> We've done that at least back to 2002, when we were still using GNATS instead
> of bugzilla. It is also true that the RM has the prerogative to downgrade
> priorities if he doesn't deem things that important. 

I have asked that all bugs be left at P3, and that I set their initial 
priority.  I also welcome input about what the priority should be, 
ideally in the audit trail for the PR itself.  But, looking at P3 bugs 
is how I see what the new bugs are.

Thanks,


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (7 preceding siblings ...)
  2006-10-10 16:23 ` mark at codesourcery dot com
@ 2006-10-12  3:09 ` mmitchel at gcc dot gnu dot org
  2006-10-16 18:36 ` mmitchel at gcc dot gnu dot org
                   ` (13 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2006-10-12  3:09 UTC (permalink / raw)
  To: gcc-bugs



-- 

mmitchel at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P2                          |P1


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (8 preceding siblings ...)
  2006-10-12  3:09 ` mmitchel at gcc dot gnu dot org
@ 2006-10-16 18:36 ` mmitchel at gcc dot gnu dot org
  2006-10-17  1:49 ` bangerth at math dot tamu dot edu
                   ` (12 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2006-10-16 18:36 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #8 from mmitchel at gcc dot gnu dot org  2006-10-16 18:36 -------
The problem here is that tsubst, for a TEMPLATE_TEMPLATE_PARM, reduces the
parameter level for the new TEMPLATE_TEMPLATE_PARM (via a call to
reduce_template_parm_level), but does not reset
TEMPLATE_TEMPLATE_PARM_TEMPLATE_DECL to a substituted version of the template. 
Therefore, when we consider merging the friend declaration and the global
declaration, we think that there types are different.


-- 

mmitchel at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Last reconfirmed|2006-10-10 04:11:45         |2006-10-16 18:36:50
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (9 preceding siblings ...)
  2006-10-16 18:36 ` mmitchel at gcc dot gnu dot org
@ 2006-10-17  1:49 ` bangerth at math dot tamu dot edu
  2006-10-20  7:34 ` pinskia at gcc dot gnu dot org
                   ` (11 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: bangerth at math dot tamu dot edu @ 2006-10-17  1:49 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #9 from bangerth at math dot tamu dot edu  2006-10-17 01:49 -------
Subject: Re:  [4.0/4.1/4.2 Regression] Bogus ambiguity with
 templates + friend


> TEMPLATE_TEMPLATE_PARM_TEMPLATE_DECL

If I didn't know better, this would sure sound like something written
under the influence :-)

-------------------------------------------------------------------------
Wolfgang Bangerth                email:            bangerth@math.tamu.edu
                                 www: http://www.math.tamu.edu/~bangerth/


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (10 preceding siblings ...)
  2006-10-17  1:49 ` bangerth at math dot tamu dot edu
@ 2006-10-20  7:34 ` pinskia at gcc dot gnu dot org
  2006-10-20  7:35 ` pinskia at gcc dot gnu dot org
                   ` (10 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-10-20  7:34 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #10 from pinskia at gcc dot gnu dot org  2006-10-20 07:33 -------
*** Bug 29486 has been marked as a duplicate of this bug. ***


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (11 preceding siblings ...)
  2006-10-20  7:34 ` pinskia at gcc dot gnu dot org
@ 2006-10-20  7:35 ` pinskia at gcc dot gnu dot org
  2007-01-06 15:55 ` [Bug c++/29236] [4.0/4.1/4.2/4.3 " pcarlini at suse dot de
                   ` (9 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-10-20  7:35 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #11 from pinskia at gcc dot gnu dot org  2006-10-20 07:34 -------
*** Bug 29438 has been marked as a duplicate of this bug. ***


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |pcarlini at suse dot de


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2/4.3 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (12 preceding siblings ...)
  2006-10-20  7:35 ` pinskia at gcc dot gnu dot org
@ 2007-01-06 15:55 ` pcarlini at suse dot de
  2007-01-09  2:49 ` mark at codesourcery dot com
                   ` (8 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: pcarlini at suse dot de @ 2007-01-06 15:55 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #12 from pcarlini at suse dot de  2007-01-06 15:54 -------
Mark, I'm looking a bit into this issue myself, starting from your notes: at
the moment I'm puzzled because, AFAICS, in the 2.95.3 tsubst nothing special
happens after the reduce_template_parm_level, still the testcase passes. Any
additional hint? Thanks in advance.

PS: Having looked at Kriang' 2000-09-04 change, I'm working under the
assumption that BOUND_TEMPLATE_TEMPLATE_PARM is equivalent to the old
TEMPLATE_TEMPLATE_PARM && TEMPLATE_TEMPLATE_PARM_TEMPLATE_INFO.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2/4.3 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (13 preceding siblings ...)
  2007-01-06 15:55 ` [Bug c++/29236] [4.0/4.1/4.2/4.3 " pcarlini at suse dot de
@ 2007-01-09  2:49 ` mark at codesourcery dot com
  2007-02-03 20:26 ` gdr at gcc dot gnu dot org
                   ` (7 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: mark at codesourcery dot com @ 2007-01-09  2:49 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #13 from mark at codesourcery dot com  2007-01-09 02:49 -------
Subject: Re:  [4.0/4.1/4.2/4.3 Regression] Bogus ambiguity
 with templates + friend

pcarlini at suse dot de wrote:
> ------- Comment #12 from pcarlini at suse dot de  2007-01-06 15:54 -------
> Mark, I'm looking a bit into this issue myself, starting from your notes: at
> the moment I'm puzzled because, AFAICS, in the 2.95.3 tsubst nothing special
> happens after the reduce_template_parm_level, still the testcase passes. Any
> additional hint? Thanks in advance.

I no longer remember any more detail.  I wrote that note because I had
done some research, and then had to go work on something else, but it's
possible that the note wasn't as helpful as I had hoped. :-(


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2/4.3 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (14 preceding siblings ...)
  2007-01-09  2:49 ` mark at codesourcery dot com
@ 2007-02-03 20:26 ` gdr at gcc dot gnu dot org
  2007-02-03 21:01 ` pinskia at gcc dot gnu dot org
                   ` (6 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: gdr at gcc dot gnu dot org @ 2007-02-03 20:26 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #14 from gdr at gcc dot gnu dot org  2007-02-03 20:26 -------
won't fix in GCC-4.0.x.  Adjusting milestone.


-- 

gdr at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.0.4                       |4.1.3


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2/4.3 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (15 preceding siblings ...)
  2007-02-03 20:26 ` gdr at gcc dot gnu dot org
@ 2007-02-03 21:01 ` pinskia at gcc dot gnu dot org
  2007-02-14  9:04 ` mmitchel at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-02-03 21:01 UTC (permalink / raw)
  To: gcc-bugs



-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.1.3                       |4.1.2


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2/4.3 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (16 preceding siblings ...)
  2007-02-03 21:01 ` pinskia at gcc dot gnu dot org
@ 2007-02-14  9:04 ` mmitchel at gcc dot gnu dot org
  2007-10-28 15:50 ` jason at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2007-02-14  9:04 UTC (permalink / raw)
  To: gcc-bugs



-- 

mmitchel at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.1.2                       |4.1.3


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2/4.3 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (17 preceding siblings ...)
  2007-02-14  9:04 ` mmitchel at gcc dot gnu dot org
@ 2007-10-28 15:50 ` jason at gcc dot gnu dot org
  2007-11-02  5:50 ` jason at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: jason at gcc dot gnu dot org @ 2007-10-28 15:50 UTC (permalink / raw)
  To: gcc-bugs



-- 

jason at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |jason at gcc dot gnu dot org
                   |dot org                     |
             Status|NEW                         |ASSIGNED
   Last reconfirmed|2006-10-16 18:36:50         |2007-10-28 15:49:56
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2/4.3 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (18 preceding siblings ...)
  2007-10-28 15:50 ` jason at gcc dot gnu dot org
@ 2007-11-02  5:50 ` jason at gcc dot gnu dot org
  2007-11-02  5:59 ` [Bug c++/29236] [4.0/4.1/4.2 " jason at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: jason at gcc dot gnu dot org @ 2007-11-02  5:50 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #15 from jason at gcc dot gnu dot org  2007-11-02 05:50 -------
Subject: Bug 29236

Author: jason
Date: Fri Nov  2 05:50:06 2007
New Revision: 129844

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=129844
Log:
        PR c++/30897
        * pt.c (push_template_decl_real): Set DECL_CONTEXT on template
        template parms.
        (lookup_template_class): Use it to get the outer template args
        for instantiating one.

        PR c++/29236
        * pt.c (reduce_template_parm_level): tsubst the parameters
        of a template template parm.

Added:
    trunk/gcc/testsuite/g++.dg/template/ttp23.C
    trunk/gcc/testsuite/g++.dg/template/ttp24.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/pt.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.0/4.1/4.2 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (19 preceding siblings ...)
  2007-11-02  5:50 ` jason at gcc dot gnu dot org
@ 2007-11-02  5:59 ` jason at gcc dot gnu dot org
  2008-07-04 21:33 ` [Bug c++/29236] [4.2 " jsm28 at gcc dot gnu dot org
  2008-12-02 17:23 ` jason at gcc dot gnu dot org
  22 siblings, 0 replies; 24+ messages in thread
From: jason at gcc dot gnu dot org @ 2007-11-02  5:59 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #16 from jason at gcc dot gnu dot org  2007-11-02 05:59 -------
Fixed for 4.3.0.


-- 

jason at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to work|2.95                        |2.95 4.3.0
            Summary|[4.0/4.1/4.2/4.3 Regression]|[4.0/4.1/4.2 Regression]
                   |Bogus ambiguity with        |Bogus ambiguity with
                   |templates + friend          |templates + friend


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.2 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (20 preceding siblings ...)
  2007-11-02  5:59 ` [Bug c++/29236] [4.0/4.1/4.2 " jason at gcc dot gnu dot org
@ 2008-07-04 21:33 ` jsm28 at gcc dot gnu dot org
  2008-12-02 17:23 ` jason at gcc dot gnu dot org
  22 siblings, 0 replies; 24+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2008-07-04 21:33 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #17 from jsm28 at gcc dot gnu dot org  2008-07-04 21:32 -------
Closing 4.1 branch.


-- 

jsm28 at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|[4.1/4.2 Regression] Bogus  |[4.2 Regression] Bogus
                   |ambiguity with templates +  |ambiguity with templates +
                   |friend                      |friend
   Target Milestone|4.1.3                       |4.2.5


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

* [Bug c++/29236] [4.2 Regression] Bogus ambiguity with templates + friend
  2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
                   ` (21 preceding siblings ...)
  2008-07-04 21:33 ` [Bug c++/29236] [4.2 " jsm28 at gcc dot gnu dot org
@ 2008-12-02 17:23 ` jason at gcc dot gnu dot org
  22 siblings, 0 replies; 24+ messages in thread
From: jason at gcc dot gnu dot org @ 2008-12-02 17:23 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #18 from jason at gcc dot gnu dot org  2008-12-02 17:11 -------
Fixed in 4.3.


-- 

jason at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29236


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

end of thread, other threads:[~2008-12-02 17:23 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-09-26 14:04 [Bug c++/29236] New: Friend operators for class with template in template argument does not compile 4ekucT at tut dot by
2006-09-26 14:08 ` [Bug c++/29236] " 4ekucT at tut dot by
2006-09-26 14:14 ` 4ekucT at tut dot by
2006-10-10  4:11 ` [Bug c++/29236] [4.0/4.1/4.2? regression] Bogus ambiguity with templates + friend bangerth at dealii dot org
2006-10-10  4:13 ` bangerth at dealii dot org
2006-10-10  4:31 ` pinskia at gcc dot gnu dot org
2006-10-10  9:46 ` [Bug c++/29236] [4.0/4.1/4.2 Regression] " rguenth at gcc dot gnu dot org
2006-10-10 14:25 ` bangerth at dealii dot org
2006-10-10 16:23 ` mark at codesourcery dot com
2006-10-12  3:09 ` mmitchel at gcc dot gnu dot org
2006-10-16 18:36 ` mmitchel at gcc dot gnu dot org
2006-10-17  1:49 ` bangerth at math dot tamu dot edu
2006-10-20  7:34 ` pinskia at gcc dot gnu dot org
2006-10-20  7:35 ` pinskia at gcc dot gnu dot org
2007-01-06 15:55 ` [Bug c++/29236] [4.0/4.1/4.2/4.3 " pcarlini at suse dot de
2007-01-09  2:49 ` mark at codesourcery dot com
2007-02-03 20:26 ` gdr at gcc dot gnu dot org
2007-02-03 21:01 ` pinskia at gcc dot gnu dot org
2007-02-14  9:04 ` mmitchel at gcc dot gnu dot org
2007-10-28 15:50 ` jason at gcc dot gnu dot org
2007-11-02  5:50 ` jason at gcc dot gnu dot org
2007-11-02  5:59 ` [Bug c++/29236] [4.0/4.1/4.2 " jason at gcc dot gnu dot org
2008-07-04 21:33 ` [Bug c++/29236] [4.2 " jsm28 at gcc dot gnu dot org
2008-12-02 17:23 ` jason at gcc dot gnu dot org

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