Article View: gnu.g++.help
Article #943template bug?
From: Eric
Date: Fri, 19 Apr 1996 14:46
Date: Fri, 19 Apr 1996 14:46
29 lines
757 bytes
757 bytes
Given the following code:
template <class T>
class C {
typedef C<T>* CPTR;
public:
int func( CPTR );
};
template <class T>
int C<T>::func( C<T>::CPTR cp )
{
return 0;
}
I get the following warnings/errors:
test.cc:10: incomplete type `C<...>' does not have member `CPTR'
test.cc:10: parse error before `)'
The same code compiles fine without the template stuff removed.
What gives?
--
Eric
Technical Details
Message-ID:
<4l890f$177@taco.cc.ncsu.edu>Path:
arc1-ca.pugleaf.net!taco.cc.ncsu.edu!easchweiShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!taco.cc.ncsu.edu!easchwei From: easchwei@unity.ncsu.edu (Eric) Newsgroups: gnu.g++.help,comp.lang.c++ Subject: template bug? Date: 19 Apr 1996 14:46:39 GMT Organization: North Carolina State University Message-ID: <4l890f$177@taco.cc.ncsu.edu> NNTP-Posting-Host: styx.csc.ncsu.edu