bomben
1
Hi all,
I’m triyng to create an array of stl vectors:
std::vector<word> _AMDigi[maxNTrk];
and save it in a Branch:
_tree->Branch("AMDigi","vector<word>",_AMDigi);
The code compiles but then it crashes when trying to fill:
I have defined:
typedef unsigned long int word;
/* ... */
#pragma link C++ class std::vector<word>;
I have searched in the forum but didn’t find anything similar.
Root version in 5.18
Many thanks in advance,
Marco
brun
2
This should be OK in ROOT5.20, but not in 5.18.
in 5.18 you must create a td::vector *_AMDigi[maxNTrk]; using new
Rene