public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/13298] New: Non-dependend template name-lookup fails
@ 2003-12-04  9:15 rguenth at tat dot physik dot uni-tuebingen dot de
  2003-12-04  9:18 ` [Bug c++/13298] " pinskia at gcc dot gnu dot org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: rguenth at tat dot physik dot uni-tuebingen dot de @ 2003-12-04  9:15 UTC (permalink / raw)
  To: gcc-bugs

For the following testcase, lookup of A::x fails inside B::y with
test.cpp: In member function `void B<T>::y()':
test.cpp:11: error: parse error before `;' token

This is fixed by (unneededly) changing the call to x to read
a.template x<int>(), as if A would be a dependend type (which it is not).

The testcase is fine on both mainline and Intel icpc 8.0 in -ansi mode.
Note that this is not a regression, as 2.95.3 behaves the same way (didnt check
3.[012] or 3.3.[012] though).


struct A {
 template<typename T>
 void x(void) {}
};

template<typename T>
struct B {
  void y(void)
  {
   A a;
   a.x<int>();
  }
};

void foo()
{
   B<double> b;
   b.y();
}

-- 
           Summary: Non-dependend template name-lookup fails
           Product: gcc
           Version: 3.3.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: rguenth at tat dot physik dot uni-tuebingen dot de
                CC: gcc-bugs at gcc dot gnu dot org


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


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

* [Bug c++/13298] Non-dependend template name-lookup fails
  2003-12-04  9:15 [Bug c++/13298] New: Non-dependend template name-lookup fails rguenth at tat dot physik dot uni-tuebingen dot de
@ 2003-12-04  9:18 ` pinskia at gcc dot gnu dot org
  2003-12-04  9:29 ` rguenth at tat dot physik dot uni-tuebingen dot de
  2003-12-04  9:32 ` pinskia at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-12-04  9:18 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2003-12-04 09:18 -------
Did you read <http://gcc.gnu.org/bugzilla/duplicates.cgi>, the second one is this problem.
This is a dup of bug 795.

*** This bug has been marked as a duplicate of 795 ***

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |DUPLICATE


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


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

* [Bug c++/13298] Non-dependend template name-lookup fails
  2003-12-04  9:15 [Bug c++/13298] New: Non-dependend template name-lookup fails rguenth at tat dot physik dot uni-tuebingen dot de
  2003-12-04  9:18 ` [Bug c++/13298] " pinskia at gcc dot gnu dot org
@ 2003-12-04  9:29 ` rguenth at tat dot physik dot uni-tuebingen dot de
  2003-12-04  9:32 ` pinskia at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: rguenth at tat dot physik dot uni-tuebingen dot de @ 2003-12-04  9:29 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From rguenth at tat dot physik dot uni-tuebingen dot de  2003-12-04 09:29 -------
Subject: Re:  Non-dependend template name-lookup fails

On Thu, 4 Dec 2003, pinskia at gcc dot gnu dot org wrote:

> ------- Additional Comments From pinskia at gcc dot gnu dot org  2003-12-04 09:18 -------
> Did you read <http://gcc.gnu.org/bugzilla/duplicates.cgi>, the second one is this problem.
> This is a dup of bug 795.

But this is marked FIXED? Even with a patch!? But I cant find that in
cp/ChangeLog* of the 3.3 CVS. Maybe the resolution should read FIXED in
HEAD, or the Target Milestone set to 3.4?

Richard.

--
Richard Guenther <richard dot guenther at uni-tuebingen dot de>
WWW: http://www.tat.physik.uni-tuebingen.de/~rguenth/


-- 


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


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

* [Bug c++/13298] Non-dependend template name-lookup fails
  2003-12-04  9:15 [Bug c++/13298] New: Non-dependend template name-lookup fails rguenth at tat dot physik dot uni-tuebingen dot de
  2003-12-04  9:18 ` [Bug c++/13298] " pinskia at gcc dot gnu dot org
  2003-12-04  9:29 ` rguenth at tat dot physik dot uni-tuebingen dot de
@ 2003-12-04  9:32 ` pinskia at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-12-04  9:32 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2003-12-04 09:32 -------
Yes, this has been fixed for 3.4, someone forgot to change the target of the dup PR to be 3.4 when 
it was fixed (most likely because it was fixed before we switch to bugzilla).

-- 


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


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

end of thread, other threads:[~2003-12-04  9:32 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-12-04  9:15 [Bug c++/13298] New: Non-dependend template name-lookup fails rguenth at tat dot physik dot uni-tuebingen dot de
2003-12-04  9:18 ` [Bug c++/13298] " pinskia at gcc dot gnu dot org
2003-12-04  9:29 ` rguenth at tat dot physik dot uni-tuebingen dot de
2003-12-04  9:32 ` pinskia 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).