Check that it is possible to assign an object to another object that is of a type of any of its base classes. Also check that an error is reported if this is not the case. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>