There are type-safe ways, like making a fruit a sum type of apple and banana, or using traits or type classes, etc. But is-a/has-a discussion seems a bit off from that.
FWIW, I didn't propose the original Scala snippet, so it isn't really “my” solution.
> the original covariance/contravariance problem
The problem is precisely preventing what you're trying to do, because it's unsafe.
For this context, what I'm saying is that if you don't need to extract an apple from a list of fruits, then you can do it safely with inheritance, so whether using inheritance or delegation is irrelevant. Isn't it?