我有以下课程,我与cout
它成为朋友,现在我正在尝试与它成为朋友,cin
但我得到一个错误......谁能帮助我,或者告诉我我做错了什么?
错误:
c:\mingw\bin../lib/gcc/mingw32/4.6.1/include/c++/bits/stl_algo.h:2215:4:错误:将'const RANgle'作为'int RANgle的'this'参数传递: :operator<(RANgle)' 丢弃限定符 [-fpermissive]
类RAngle
:
class RAngle
{
private:
int *x,*y,*l;
public:
int solution,prec;
RAngle(){
this->x = 0;
this->y = 0;
this->l = 0;
}
RAngle(int i,int j,int k){
this->x = &i;
this->y = &j;
this->l = &k;
}
friend istream& operator >>( istream& is, RAngle &ra)
{
is >> ra->x;
is >> ra->y;
is >> ra->l;
return is ;
}
}