8.16 (Casting) says, "It is always legal to assign an expression of subclass type to a variable of a class type higher in the inheritance tree (a superclass or ancestor of the expression type). It shall be illegal to directly assign avariable of a superclass type to a variable of one of its subclass types. However, $cast may be used to assign a superclass handle to a variable of a subclass type provided the superclass handle refers to an object that is assignment compatible with the subclass variable." Similarly, it says below, "When $cast is applied to class handles, it succeeds in only three cases: . 2) The type of the source expression is cast compatible with the destination type, that is, either: - the type of the source expression is a superclass of the destination type, or . and the source is an object that is assignment compatible with the destination type." Question: where is the definition of assignment compatibility between class objects? Thanks, ShalomReceived on Sun Dec 13 03:39:10 2015
This archive was generated by hypermail 2.1.8 : Sun Dec 13 2015 - 03:39:23 PST