When I do this:
std::vector hello;
Everything works great. However, when I make it a vector of references instead:
It's a flaw in the C++ language. You can't take the address of a reference, since attempting to do so would result in the address of the object being referred to, and thus you can never get a pointer to a reference. std::vector
works with pointers to its elements, so the values being stored need to be able to be pointed to. You'll have to use pointers instead.