lebedev.ri added a comment. In https://reviews.llvm.org/D39462#936566, @bcain wrote:
> I'd like to understand/resurrect this change, so I'll try to summarize. > Please correct this as appropriate: > > 1. We got here because libc++ has code that triggers a warning for some > targets (those whose `int` and `long` have the same size). > 2. This change would "move" the existing logic for > `-Wtautological-constant-compare` to `-Wmaybe-tautological-constant-compare` > and replace `-Wtautological-constant-compare` logic with one less likely to > report that the code in libc++ is wrong. > 3. A superior checker could be defined that would thread the needle between > these cases: warning only when it should and not when it shouldn't. This > would be preferred because it avoids the creation of similar but slightly > distinct warnings. > > If this summary is really the case, what's the best way to break this > stalemate? Could we implement this change for now and improve the warnings > later? If the answer is 'no', then let's please restore > https://reviews.llvm.org/D39149. > > AFAICT Marshall and John have strong feelings on each of these proposed > libc++ and clang changes -- it would be valuable if each of you could weigh > in. After more though i agree with @rjmccall, this is incomplete at best. The current diff will basically kill the `-Wtautological-constant-compare`, introduce a lot of false-negatives, which is no-go. On the other hand, i'm not sure that at the moment i'm able to implement what @rjmccall has outlined. So if someone wants to take this over, let me know. Repository: rL LLVM https://reviews.llvm.org/D39462 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits