一个template用法的问题

时间:2014.02.16 发布人:leeweif

一个template用法的问题

已解决问题

谷歌leeweif用户在2014.02.16提交了关于“法拉利一个template用法的问题”的提问,欢迎大家涌跃发表自己的观点。目前共有1个回答,最后更新于2024-02-16T02:01:53。X::templatef<int>(10);
这种用法X是怎么定义的,f是怎么定义的.希望大家能够帮助她。

详细问题描述及疑问:X::templatef<int>(10);
这种用法X是怎么定义的,f是怎么定义的.期待您的答案,当代劳模,所有人都应该向你学习 !

希望以下的回答,能够帮助你。

第1个回答

用户名:yacre  

#include<iostream>

usingnamespacestd;

classX{
public:
template<typenameT>static部制质置含及那混voidf(Tx){}
};

intmain(){
X::templatef<int>(10);
return0;
}