[PATCH] D38718: [Sema] No -Wtautological-pointer-compare warning on variables within parentheses
Daniel Marjamäki via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Oct 10 04:46:30 PDT 2017
danielmarjamaki added a comment.
LGTM! However I would like to see a review from somebody else also.
There are a number of diagnostics that might be affected. The Sema::DiagnoseAlwaysNonNullPointer diagnoses these:
diag::warn_null_pointer_compare <-- I think this is the one bug 20951 is about
It seems to me that it is an improvement for all these warnings to skip the parentheses. However there is a danger that parentheses should hide some warnings to make it possible for users to hide unwanted warnings. But if that was the design decision then some regression test should complain when we skip the parentheses.
More information about the cfe-commits