Null check of typeas expression where it actually can return null