JP Mercury wrote:
main() { A *list = new B[10]; // Allocate 10x derived, store first in A *list
this won't work. new B[10] gets you an array of 10 B objects, you can't expect that to look like an array of A objects.
you should use an array of pointers to object -- or some container object.
nathan
-- Nathan Sidwell :: http://www.codesourcery.com :: CodeSourcery LLC nathan@xxxxxxxxxxxxxxxx :: http://www.planetfall.pwp.blueyonder.co.uk