[PATCH] D32207: Corrrect warn_unused_result attribute

Erich Keane via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Apr 19 09:55:27 PDT 2017


erichkeane added a comment.

1 more thing:  I excepted post-increment/decrement from this warning because I figured it would give a TON of warnings from people using post-inc/dec in for loops.

However, after further discussion with Craig (who brought this up on the mailing list), I severely wonder if that is the 'right' thing to do.  Someone who is going to mark their struct in this way would likely ALSO mean it in this case, right?

Aaron: Should I simply remove the special casing all together, so that it warns on post inc/dec?  That would definitely solve all your concerns in the review so far.


https://reviews.llvm.org/D32207





More information about the cfe-commits mailing list