It seems that there is a problem with defining operators in CINT.
Here is a simple class definition:
class aint
{
public:
aint(int);
aint operator+(aint);
int i;
};
aint::aint(int j)
{
i=j;
}
aint aint::operator+(aint j)
{
return aint(i+j.i);
}
And now, if I use this class, here is the root answer:
root [5] .L test.C
root [6] aint i(0)
root [7] aint j(1)
root [8] aint k=i+j;
Error: Return type mismatch operator+()
FILE:/disk7/users/pbruel/optic/./test.C LINE:16
*** Interpreter error recovered ***
root [9]
I am running root 2.20.06 on HP.
Thanks in advance foor your help.
-- Philippe Bruel new email address: Philippe.Bruel@poly.in2p3.fr LPNHE, Ecole Polytechnique, 91128 PALAISEAU Cedex - France Tel: 01 69 33 44 07 - Fax: 01 69 33 30 02