Assignment Compatibility

Assignment compatibility requires that the type of the expression on the left-hand side of the assignment is assignment‑compatible with the expression on the right-hand side.

A value t2 of type T2 is assignment-compatible with a value t1 of type T1 (that is, t1 := t2 is allowed) if any of the following is true.

JADE provides a type-safe mechanism to assign a superclass reference to a declared subclass reference. For details, see "Type Guard Expression", earlier in this chapter.