NoQ added inline comments.

================
Comment at: clang/lib/StaticAnalyzer/Core/RangeConstraintManager.cpp:459
+    bool CoversTheWholeType =
+        (Origin.From().isMinSignedValue() || Origin.To().isMaxValue());
+
----------------
vsavchenko wrote:
> NoQ wrote:
> > `(Origin.From() + 1).isMinSignedValue()` is another sufficient condition(?)
> I'm sorry, I don't quite get what cases does this check cover.  Can you 
> please explain what you have in mind?
Aha, ok, nvm, a different issue then: For range `[INT_MIN + 1, INT_MAX]`, the 
correct answer should be ``[INT_MIN + 1, INT_MAX]` (which is `[-C, C]` for `C = 
INT_MAX]`) rather than `[INT_MIN, INT_MAX]`.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D80117/new/

https://reviews.llvm.org/D80117



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

Reply via email to