下面的vc中的错误是什么意思?

来源:百度知道 编辑:UC知道 时间:2024/05/31 10:53:17
error C2678: binary '!=' : no operator defined which takes a left-hand operand of type 'struct ELEMENT' (or there is no acceptable conversion)什么意思?

你没重载过!=运算符
所以struct ELEMENT这个结构体的对象不能为左值

C++里,你自定义的结构和类如果没有重载某个运算符,那么就不能对结构和类的实例使用该运算符。