Interpreter: check ownership of COM casts in switch patterns
COM cast patterns use QueryInterface to obtain the destination interface.
A successful query returns an owned reference, so a bound result must
remain valid independently of the source. A failed query must preserve
the source's ownership.