Lets say that I have a base and derived class, and a function that takes an stl vector of pointers to the base class:
class A { public: int x; }; class B :
std::vector and std::vector are technically unrelated. C++ does not allow what you want as such.
std::vector and std::vector
A way around...Why not have a std::vector and insert into it Derived objects? That is the point of polymorphism, dynamic dispatch et al.
std::vector
Derived