T
TF
I have a fixed array of vectors like:
vector<string> a_vStr[10];
Then I grow each vector item and use it later. Everything works fine
but I am curious about following potential problem.
When we grow a vector it may copy all of its elements to different
memory location to accomodate the new vector size. Is it possible that
at some point an element of fixed array e.g. a_vStr[5] gets invalid or
does not point to the vector it was pointing to at begining?
vector<string> a_vStr[10];
Then I grow each vector item and use it later. Everything works fine
but I am curious about following potential problem.
When we grow a vector it may copy all of its elements to different
memory location to accomodate the new vector size. Is it possible that
at some point an element of fixed array e.g. a_vStr[5] gets invalid or
does not point to the vector it was pointing to at begining?