C++编程隐蔽错误:error C2533: 构造函数不能有返回类型
问题:在编写类的时候,出现如下错误:
error C2533: 'CReadTxt::CReadTxt' : constructors not allowed a return type
博客介绍了在编写C++类时遇到的错误C2533,该错误指出构造函数不允许有返回类型。作者提供了解决此问题的方法,即检查并确保在类定义的末尾添加了分号。
问题:在编写类的时候,出现如下错误:
error C2533: 'CReadTxt::CReadTxt' : constructors not allowed a return type
2096

被折叠的 条评论
为什么被折叠?