<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Feb 15, 2015 at 6:04 PM, Richard <span dir="ltr"><<a href="mailto:legalize@xmission.com" target="_blank">legalize@xmission.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Thinking about this a little more, I'm conflicted as to whether or not it should allow the simplification if the boolean constant came from a macro.  If the macro is a feature detection macro, then I'm enabling/disabling chunks of code at runtime based on the resolution of the feature detection and I shouldn't be so quick to simplify that to always true or always false.<br></blockquote><div><br>I believe that was Ismael's point, if it wasn't at least it's mine. It's unfortunate to whitelist all macros like that, but I think it'll be necessary to get the false positive % down. Check out similar changes Ted Kremenek made to Clang's -Wunreachable-code warning to reduce the false positives about a year ago. You'll find that if (MACRO) { ... } else { ... } doesn't produce an unreachable code warning on either path.<br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="HOEnZb"><div class="h5"><br>
<br>
<a href="http://reviews.llvm.org/D7648" target="_blank">http://reviews.llvm.org/D7648</a><br>
<br>
EMAIL PREFERENCES<br>
  <a href="http://reviews.llvm.org/settings/panel/emailpreferences/" target="_blank">http://reviews.llvm.org/settings/panel/emailpreferences/</a><br>
<br>
<br>
<br>
_______________________________________________<br>
cfe-commits mailing list<br>
<a href="mailto:cfe-commits@cs.uiuc.edu">cfe-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits</a><br>
</div></div></blockquote></div><br></div></div>