templ.cpp

来自「doxygen(一个自动从源代码生成文档的工具)的源代码」· C++ 代码 · 共 36 行

CPP
36
字号
/*! A template class */template<class T,int i=100> class Test{  public:    Test();    Test(const Test &);};/*! complete specialization */template<> class Test<void *,200>{  public:    Test();};/*! A partial template specialization */template<class T> class Test<T *> : public Test<void *,200>{  public:    Test();};/*! The constructor of the template class*/template<class T,int i> Test<T,i>::Test() {}/*! The copy constructor */template<class T,int i> Test<T,i>::Test(const Test<T,i> &t) {}/*! The constructor of the partial specilization */template<class T> Test<T *>::Test() {}/*! The constructor of the specilization */template<> Test<void *,200>::Test() {}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?