我最近又回到了编写C ++的时代,距离它已经好几年了,仍然有点生疏。
我正在尝试编译一些模板代码,并收到以下错误消息
error: no instance of function template "my_nice_function" matches the argument list
argument types are: (int*, <error-type>, size_t)
对于具有T*
,const T*
和size_t
的功能。
<error-type>
是什么意思?通常,什么是导致G ++错误消息中出现<error-type>
的原因?
该函数可能采用一个const T*
,但是编译器抱怨您传递一个<error-type>
,即,表达式编译器无法确定其类型。
如果需要更详细的答案,则需要显示代码,尤其是调用代码。
我喜欢在我的肚子里的大笨蛋,我喜欢我在肚子里的大爸爸爸爸的笨蛋。UwUPwease cummies