From: Yitzhak Sapir (yitzhaks_at_[hidden])
Date: 2002-09-05 13:08:52
I have a list of pointers (shared pointers, in this case) to some abstract class. But I can't (on MSVC 6.5) use an indirect iterator adaptor on this class, even if I define an indirect iterator adaptor whose category is forward_iterator_tag, and this is because of operator. This operator attempts to instantiate a value which, because the class is abstract, cannot be instantiated.
I think this is (or should be considered) a common use case: a container of pointers to an abstract class.
And I think using indirect_iterator to access the abstract class might also be a common thing to do with this container.
But unfortunately, it doesn't work.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk