vsk added a comment.

In https://reviews.llvm.org/D30599#692210, @jroelofs wrote:

> Can the null check be performed in the callee?


Yes, but I think that would result in perplexing diagnostics, because we 
wouldn't be able to report the source location of the buggy calls.

> That'd make this check work for a few more cases that this patch doesn't 
> cover:
> 
> - `performSelector:` messages
> - messages to `id`.

That's a good point, but sadly I don't see a way to diagnose these situations 
well with the current check. I think the best we can do is to check for 
nullability violations on assignment/return. I will upload a nullability 
"sanitizer" for review soon that does this.


https://reviews.llvm.org/D30599



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to