public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/11858] Name lookup error ignored when instantiated from expression within sizeof() in template function parameter
[not found] <bug-11858-4@http.gcc.gnu.org/bugzilla/>
@ 2012-10-10 19:39 ` kstutsman at gmail dot com
2012-10-10 20:30 ` redi at gcc dot gnu.org
1 sibling, 0 replies; 6+ messages in thread
From: kstutsman at gmail dot com @ 2012-10-10 19:39 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11858
--- Comment #4 from Kurt Stutsman <kstutsman at gmail dot com> 2012-10-10 19:39:12 UTC ---
Still seeing this as of version 4.6.1.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/11858] Name lookup error ignored when instantiated from expression within sizeof() in template function parameter
[not found] <bug-11858-4@http.gcc.gnu.org/bugzilla/>
2012-10-10 19:39 ` [Bug c++/11858] Name lookup error ignored when instantiated from expression within sizeof() in template function parameter kstutsman at gmail dot com
@ 2012-10-10 20:30 ` redi at gcc dot gnu.org
1 sibling, 0 replies; 6+ messages in thread
From: redi at gcc dot gnu.org @ 2012-10-10 20:30 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11858
Jonathan Wakely <redi at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Last reconfirmed|2005-09-10 19:09:16 |2012-10-10
--- Comment #5 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-10-10 20:30:13 UTC ---
and 4.8
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/11858] Name lookup error ignored when instantiated from expression within sizeof() in template function parameter
[not found] <bug-11858-5473@http.gcc.gnu.org/bugzilla/>
@ 2005-12-18 20:14 ` pinskia at gcc dot gnu dot org
0 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-12-18 20:14 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from pinskia at gcc dot gnu dot org 2005-12-18 20:14 -------
This looks like a case where array decays to a pointer too early problem (PR
24666).
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
OtherBugsDependingO| |24666
nThis| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11858
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/11858] Name lookup error ignored when instantiated from expression within sizeof() in template function parameter
2003-08-08 22:12 [Bug c++/11858] New: " gccbugs at contacts dot eelis dot net
2003-08-08 22:28 ` [Bug c++/11858] " pinskia at gcc dot gnu dot org
2003-08-09 15:52 ` bangerth at dealii dot org
@ 2003-08-23 1:12 ` dhazeghi at yahoo dot com
2 siblings, 0 replies; 6+ messages in thread
From: dhazeghi at yahoo dot com @ 2003-08-23 1:12 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11858
dhazeghi at yahoo dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|3.4 |---
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/11858] Name lookup error ignored when instantiated from expression within sizeof() in template function parameter
2003-08-08 22:12 [Bug c++/11858] New: " gccbugs at contacts dot eelis dot net
2003-08-08 22:28 ` [Bug c++/11858] " pinskia at gcc dot gnu dot org
@ 2003-08-09 15:52 ` bangerth at dealii dot org
2003-08-23 1:12 ` dhazeghi at yahoo dot com
2 siblings, 0 replies; 6+ messages in thread
From: bangerth at dealii dot org @ 2003-08-09 15:52 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11858
------- Additional Comments From bangerth at dealii dot org 2003-08-09 15:52 -------
I'm not where exactly is the bug here: T::x doesn't exist if T=int, so this is a substitution
failure. This is not an error, the function is simply not available for name lookup. If this
were the correct interpretation, then we should get an error that there is no suitable
function T::f in the sizeof expression. But there's a bug anyway.
By the way, this is rejected:
---------------------------------------------
template <int> struct X {};
template <typename T> struct S { static typename T::x f (); };
template <class T> int f (X<sizeof(T::f())> *);
int const i = f<S<int> >(0);
----------------------------------------------
So it has something to do with the fact that gcc simply ignores the size expression if
an argument to a function is an array.
W,
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/11858] Name lookup error ignored when instantiated from expression within sizeof() in template function parameter
2003-08-08 22:12 [Bug c++/11858] New: " gccbugs at contacts dot eelis dot net
@ 2003-08-08 22:28 ` pinskia at gcc dot gnu dot org
2003-08-09 15:52 ` bangerth at dealii dot org
2003-08-23 1:12 ` dhazeghi at yahoo dot com
2 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-08-08 22:28 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11858
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Keywords| |accepts-invalid
Last reconfirmed|0000-00-00 00:00:00 |2003-08-08 22:28:16
date| |
------- Additional Comments From pinskia at gcc dot gnu dot org 2003-08-08 22:28 -------
I can confirm this on the mainline (20030808).
Maybe related to bug 11814.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2012-10-10 20:30 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <bug-11858-4@http.gcc.gnu.org/bugzilla/>
2012-10-10 19:39 ` [Bug c++/11858] Name lookup error ignored when instantiated from expression within sizeof() in template function parameter kstutsman at gmail dot com
2012-10-10 20:30 ` redi at gcc dot gnu.org
[not found] <bug-11858-5473@http.gcc.gnu.org/bugzilla/>
2005-12-18 20:14 ` pinskia at gcc dot gnu dot org
2003-08-08 22:12 [Bug c++/11858] New: " gccbugs at contacts dot eelis dot net
2003-08-08 22:28 ` [Bug c++/11858] " pinskia at gcc dot gnu dot org
2003-08-09 15:52 ` bangerth at dealii dot org
2003-08-23 1:12 ` dhazeghi at yahoo dot com
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).