public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/15639] New: Fails to find inherited function
@ 2004-05-25 18:26 igodard at pacbell dot net
  2004-05-25 18:26 ` [Bug c++/15639] " bangerth at dealii dot org
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: igodard at pacbell dot net @ 2004-05-25 18:26 UTC (permalink / raw)
  To: gcc-bugs

template<typename T>
class A{
public:
    T*  F(int i) { return 0;}
    };

template<typename U, template<typename> class B>
class C: public B<U> {
public:
    void    G() {
        U* u = F(5);
        }
    };
int main() {
    C<bool, A> c;
    c.G();
    return 0;
    }

gives:

~/ootbc/common/test/src$ g++ foo.cc
foo.cc: In member function `void C<U, B>::G()':
foo.cc:11: error: there are no arguments to `F' that depend on a template parameter, so a declaration of `F' must be available
foo.cc:11: error: (if you use `-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated)


However, the explicit invocation of C<bool, A> binds U to bool and B to A, so the "c" derives from A<bool>, which does in fact have an F(int) to call and is available.

Ivan

-- 
           Summary: Fails to find inherited function
           Product: gcc
           Version: 3.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: igodard at pacbell dot net
                CC: gcc-bugs at gcc dot gnu dot org


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


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

* [Bug c++/15639] Fails to find inherited function
  2004-05-25 18:26 [Bug c++/15639] New: Fails to find inherited function igodard at pacbell dot net
@ 2004-05-25 18:26 ` bangerth at dealii dot org
  2004-05-25 18:27 ` igodard at pacbell dot net
                   ` (7 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: bangerth at dealii dot org @ 2004-05-25 18:26 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From bangerth at dealii dot org  2004-05-24 22:38 -------
Yet another case where looking at the release notes and non-bugs section 
of gcc 3.4 would have helped you :-) 
 
W. 

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


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


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

* [Bug c++/15639] Fails to find inherited function
  2004-05-25 18:26 [Bug c++/15639] New: Fails to find inherited function igodard at pacbell dot net
  2004-05-25 18:26 ` [Bug c++/15639] " bangerth at dealii dot org
@ 2004-05-25 18:27 ` igodard at pacbell dot net
  2004-05-25 18:29 ` pinskia at gcc dot gnu dot org
                   ` (6 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: igodard at pacbell dot net @ 2004-05-25 18:27 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From igodard at pacbell dot net  2004-05-24 22:55 -------
Begging your pardon, but where would I find the "the release notes and non-bugs section"? All I have is /include, /lib, and /bin, plus the SGI STL web site and a "C++ Programming Language" 3rd edition. My employer won't pay for copies of the standard, and based on citations in the newsgroups I would find it incomprehensible anyway. Nor (based on the number of my bug reports that have *not* been ruled invalid; *ten* outstanding at present) can I assume that when the compiler doesn't do what I expect it to do that it necesarily means that I've been dumb (although it does frequently mean that :-)

If you find my reports useful and want them to continue, you could improve their quality by helping me toward doc and ultimately toward understanding, without assuming that I know what you do and have access to the same materials you have.

Ivan

-- 


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


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

* [Bug c++/15639] Fails to find inherited function
  2004-05-25 18:26 [Bug c++/15639] New: Fails to find inherited function igodard at pacbell dot net
  2004-05-25 18:26 ` [Bug c++/15639] " bangerth at dealii dot org
  2004-05-25 18:27 ` igodard at pacbell dot net
@ 2004-05-25 18:29 ` pinskia at gcc dot gnu dot org
  2004-05-25 19:07 ` gdr at integrable-solutions dot net
                   ` (5 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-05-25 18:29 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-05-24 22:57 -------
http://gcc.gnu.org/gcc-3.4/changes.html
http://gcc.gnu.org/bugs.html

-- 


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


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

* [Bug c++/15639] Fails to find inherited function
  2004-05-25 18:26 [Bug c++/15639] New: Fails to find inherited function igodard at pacbell dot net
                   ` (2 preceding siblings ...)
  2004-05-25 18:29 ` pinskia at gcc dot gnu dot org
@ 2004-05-25 19:07 ` gdr at integrable-solutions dot net
  2004-05-25 19:34 ` bangerth at dealii dot org
                   ` (4 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: gdr at integrable-solutions dot net @ 2004-05-25 19:07 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From gdr at integrable-solutions dot net  2004-05-25 00:03 -------
Subject: Re:  Fails to find inherited function

"igodard at pacbell dot net" <gcc-bugzilla@gcc.gnu.org> writes:

| If you find my reports useful and want them to continue, you could
| improve their quality by helping me toward doc and ultimately toward
| understanding, without assuming that I know what you do and have
| access to the same materials you have. 

I believe your reports are most welcome.  

Triaging bugs reports can be something exausting, and after dealing
with a bug an nth time, one feels like repeating oneself over and over


-- gaby


-- 


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


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

* [Bug c++/15639] Fails to find inherited function
  2004-05-25 18:26 [Bug c++/15639] New: Fails to find inherited function igodard at pacbell dot net
                   ` (3 preceding siblings ...)
  2004-05-25 19:07 ` gdr at integrable-solutions dot net
@ 2004-05-25 19:34 ` bangerth at dealii dot org
  2004-05-25 19:35 ` igodard at pacbell dot net
                   ` (3 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: bangerth at dealii dot org @ 2004-05-25 19:34 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From bangerth at dealii dot org  2004-05-25 00:11 -------
Indeed, I apologize if my style was too terse. I just didn't feel 
like explaining this whole thing again :-( 
 
Sorry 
  Wolfgang 

-- 


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


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

* [Bug c++/15639] Fails to find inherited function
  2004-05-25 18:26 [Bug c++/15639] New: Fails to find inherited function igodard at pacbell dot net
                   ` (4 preceding siblings ...)
  2004-05-25 19:34 ` bangerth at dealii dot org
@ 2004-05-25 19:35 ` igodard at pacbell dot net
  2004-05-25 22:52 ` giovannibajo at libero dot it
                   ` (2 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: igodard at pacbell dot net @ 2004-05-25 19:35 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From igodard at pacbell dot net  2004-05-25 00:37 -------
Thank you for your kind words. I have read the references you sent, and understood them not at all, but will try.

May I say as an editorial comment that in serious template-banging code like what I'm writing, the number of type- and scope-qualifiers required to steer the parser makes me long for a terser language like Cobol.

Ivan

-- 


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


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

* [Bug c++/15639] Fails to find inherited function
  2004-05-25 18:26 [Bug c++/15639] New: Fails to find inherited function igodard at pacbell dot net
                   ` (5 preceding siblings ...)
  2004-05-25 19:35 ` igodard at pacbell dot net
@ 2004-05-25 22:52 ` giovannibajo at libero dot it
  2004-11-05 19:28 ` bangerth at dealii dot org
  2004-11-05 19:32 ` bangerth at dealii dot org
  8 siblings, 0 replies; 10+ messages in thread
From: giovannibajo at libero dot it @ 2004-05-25 22:52 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From giovannibajo at libero dot it  2004-05-25 01:05 -------
Ivan,

a text version of changes.html is also shipped in the original package as 
gcc/NEWS. As for the template code, I suggest you to try also your minimized 
snippets on the Comeau online compiler, at 
http://www.comeaucomputing.com/tryitout. The compiler is based on the EDG 
frontend, which is supposed to be 99.999999% conformant to the C++ standard by 
now (modulo small bugs). If both GCC and Comeau match in behaviour on a certain 
code snippet, I suggest you to quadruple-check it against C++ books etc. before 
submitting a bug report, as it would be probably invalid.

Thank you for taking the time to file all these bug reports!

-- 


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


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

* [Bug c++/15639] Fails to find inherited function
  2004-05-25 18:26 [Bug c++/15639] New: Fails to find inherited function igodard at pacbell dot net
                   ` (6 preceding siblings ...)
  2004-05-25 22:52 ` giovannibajo at libero dot it
@ 2004-11-05 19:28 ` bangerth at dealii dot org
  2004-11-05 19:32 ` bangerth at dealii dot org
  8 siblings, 0 replies; 10+ messages in thread
From: bangerth at dealii dot org @ 2004-11-05 19:28 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From bangerth at dealii dot org  2004-11-05 19:27 -------
These are all duplicates of PR 15552 

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


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


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

* [Bug c++/15639] Fails to find inherited function
  2004-05-25 18:26 [Bug c++/15639] New: Fails to find inherited function igodard at pacbell dot net
                   ` (7 preceding siblings ...)
  2004-11-05 19:28 ` bangerth at dealii dot org
@ 2004-11-05 19:32 ` bangerth at dealii dot org
  8 siblings, 0 replies; 10+ messages in thread
From: bangerth at dealii dot org @ 2004-11-05 19:32 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From bangerth at dealii dot org  2004-11-05 19:31 -------
Duplicate of PR 15552. 

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

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


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


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

end of thread, other threads:[~2004-11-05 19:32 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-05-25 18:26 [Bug c++/15639] New: Fails to find inherited function igodard at pacbell dot net
2004-05-25 18:26 ` [Bug c++/15639] " bangerth at dealii dot org
2004-05-25 18:27 ` igodard at pacbell dot net
2004-05-25 18:29 ` pinskia at gcc dot gnu dot org
2004-05-25 19:07 ` gdr at integrable-solutions dot net
2004-05-25 19:34 ` bangerth at dealii dot org
2004-05-25 19:35 ` igodard at pacbell dot net
2004-05-25 22:52 ` giovannibajo at libero dot it
2004-11-05 19:28 ` bangerth at dealii dot org
2004-11-05 19:32 ` bangerth at dealii 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).