Also, if you save a bunch of rectangles in a collection (varray of shape_t), and then do a treat to get a rectangle back, does it have the attributes of the original rectangle, or only those of the shape_t plus new default rectangle attributes?From my limited tests, it does appear that the attributes from the collection are correctly maintained (although copy would seem to be the more appropriate term).
Copying the object as a clone isn't really a solution, since that's fairly wasteful. The idea is to use the original.Can't help you there. A downcast operator that clones really isn't a downcast operator is it? :-)
Speaking of cast, what about the CAST function. Appears to convert one type of collection to another. But I can't figure how to use it.