I have a collection of polymorphic objects, all derived from my Animal class: Cat, Dog, and MonkeyFish.
My usual mode of operation is to store these objects in a vec
If you ever hear the argument but it'll be so costly to copy them structures all the time when you want to use full objects instead of pointers in a vector, then your 2 main arguments are:
The added cost of copying is normally taken when adding stuff to the container, not when using the data - think a bit about it: what do you do most? add items or use them?
However, when adding polymorphical objects, the pointers are necessary to avoid slicing.