有时候会报这种错误:[Error] an explicit specialization must be preceded by 'template <>'。
然后就需要加上template<>。
就是为了对于特定类型来执行不同的代码,而不是去用通用模板。
有时候会报这种错误:[Error] an explicit specialization must be preceded by 'template <>'。
然后就需要加上template<>。
就是为了对于特定类型来执行不同的代码,而不是去用通用模板。