Merge "Clear exceptions before calling IsInstanceOf."