这个typedef 哪里错了。。。
typedef template<class T> void (*Ini)(T&,const T&=T());就是弄一个函数模板的指针 不知道怎么就错了帮忙改一下啊。。。。
2010-12-13 21:45
程序代码:#include<iostream.h>
template<class T>
typedef void (*Ini)(T&,const T&);
void main()
{
cout<<"123"<<endl;
}这样就对了 格式书写问题 把template放在上面

2010-12-14 15:42
2010-12-14 16:02
2010-12-14 18:18



2010-12-14 18:49
2010-12-14 19:09
程序代码:#include<iostream>
using namespace std;
template<class T>
typedef void (*Ini)(T *d,T *v);
template<class T>
void aa(T *d,T *v)
{
;
}
void main()
{
cout<<"123"<<endl;
int i=0,j=3;
cout<<"i= "<<i<<endl;
Ini ini;
ini=aa;
aa(&i,&j);
cout<<"i= "<<i<<endl;
}


2010-12-14 21:51
2010-12-14 22:39