I cannot use std containers and algorithms in cint interpreter due to iterator operations not functioning (among other problems).
I freshly compiled and installed root 5.22b with gcc 4.3.3 on kubuntu Jaunty, installed to a $ROOTSYS under my home directory.
This is my test macro:
[code]#include
using namespace std;
vector v;
void test1() {
if( v.begin() == v.end() ) { cout<< “A”<<endl; }
}
void test2() {
v.push_back(1);
for( vector::iterator i=v.begin(); i!=v.end(); ++i ) {
cout<< “B” <<endl;
}
}
[/code]
This is the error:
root [0] .L test.C
root [1] test1()
Internal error: template function call operator== failed test.C:8:
*** Interpreter error recovered ***
root [2] test2()
Error: operator!= not defined for vector<int,allocator<int> >::iterator test.C:13:
*** Interpreter error recovered ***
Could you help with the problem? Thanks in advance.