[ROOT] PyROOT and STL containers.

From: Brett Viren (bv@bnl.gov)
Date: Sun Oct 31 2004 - 01:19:27 MEST


Hi,

I'm trying to use PyROOT with classes that return STL containers.  Eg
I have a class that reutrns an "std::vector<std::string>".  Some of
the std::vector methods work but some don't, particularly operator[].

print vs
<__main__.vector<string> object at 0x41d1124c>
print vs.size()
37
print vs[0]
 *** Break *** illegal instruction

Stack trace is below.

This is ROOT CVS 4.01/03 15 October 2004 on x86 Debian GCC 3.3.3,
python 2.3.4.


-Brett.


 Generating stack trace...
/usr/bin/addr2line: python2.3: No such file or directory
/usr/bin/addr2line: python2.3: No such file or directory
/usr/bin/addr2line: python2.3: No such file or directory
/usr/bin/addr2line: python2.3: No such file or directory
/usr/bin/addr2line: python2.3: No such file or directory
/usr/bin/addr2line: python2.3: No such file or directory
/usr/bin/addr2line: python2.3: No such file or directory
/usr/bin/addr2line: python2.3: No such file or directory
/usr/bin/addr2line: python2.3: No such file or directory
/usr/bin/addr2line: python2.3: No such file or directory
/usr/bin/addr2line: python2.3: No such file or directory
/usr/bin/addr2line: python2.3: No such file or directory
/usr/bin/addr2line: python2.3: No such file or directory
 0x402c86f3 in PyROOT::bindRootObject(PyROOT::ObjectHolder*, bool) + 0xd3 from /home/bviren/opt32/root-devel/lib/libPyROOT.so
 0x402bfcb2 in PyROOT::MethodHolder::callMethod(void*) + 0x362 from /home/bviren/opt32/root-devel/lib/libPyROOT.so 0x402bff34 in PyROOT::MethodHolder::operator()(_object*, _object*) + 0xc4 from /home/bviren/opt32/root-devel/lib/libPyROOT.so
 0x402bc4b9 in PyROOT::MethodDispatcher::operator()(_object*, _object*) + 0x209 from /home/bviren/opt32/root-devel/lib/libPyROOT.so
 0x402bc155 in PyROOT::MethodDispatcher::invoke(_object*, _object*, _object*) + 0x35 from /home/bviren/opt32/root-devel/lib/libPyROOT.so
 0x080fdefe in PyCFunction_Call + 0xce from python2.3
 0x0805b989 in PyObject_Call + 0x29 from python2.3
 0x080623d8 in <unknown> from python2.3
 0x0805b989 in PyObject_Call + 0x29 from python2.3
 0x0808f7c1 in <unknown> from python2.3
 0x0808d703 in <unknown> from python2.3
 0x08059b72 in PyObject_GetItem + 0x192 from python2.3
 0x080a83ca in <unknown> from python2.3
 0x080aa76c in PyEval_EvalCodeEx + 0x49c from python2.3
 0x080aca8a in <unknown> from python2.3
 0x080a9115 in <unknown> from python2.3
 0x080aa76c in PyEval_EvalCodeEx + 0x49c from python2.3
 0x080fd9d7 in <unknown> from python2.3
 0x0805b989 in PyObject_Call + 0x29 from python2.3
 0x080ab5b7 in PyEval_CallObjectWithKeywords + 0x77 from python2.3
 0x080d8a0c in PyErr_PrintEx + 0xbc from python2.3
 0x080d8942 in PyErr_Print + 0x12 from python2.3
 0x080d8890 in PyRun_SimpleFileExFlags + 0x160 from python2.3
 0x08054e95 in Py_Main + 0x4a5 from python2.3
 0x080549eb in main + 0x1b from python2.3
 0x400767f8 in __libc_start_main + 0x108 from /lib/tls/libc.so.6
Aborted



This archive was generated by hypermail 2b29 : Sun Jan 02 2005 - 05:50:10 MET