This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
g++ - pred
- To: <gcc-bugs at gcc dot gnu dot org>
- Subject: g++ - pred
- From: "Maciej Hrebien" <m_hrebien at poczta dot onet dot pl>
- Date: Fri, 16 Mar 2001 19:30:09 +0100
Hello again,
Please look at this:
template<class T>
struct Pre
{
void operator()(const T&, const T&){}
static void op(const T&, const T&){}
};
template<class T, class PreT=Pre<T> >
void fun(const T& a, const T& b)
{
PreT::p(a,b);
}
main()
{
fun(1,2);
return 0;
}
Why g++-2.95.2 gives me errors telling that I have default arg for template
param
if function template (PreT,fun)? I know that, I wrote it :) ISO/IEC 14882 p.
14.1
says that it should work.
Maciej Hrebien
--