ASDenysPetrov added a comment. In D103096#2866730 <https://reviews.llvm.org/D103096#2866730>, @vsavchenko wrote:
> In D103096#2866704 <https://reviews.llvm.org/D103096#2866704>, @ASDenysPetrov > wrote: > >> @vsavchenko > > That's not the question I'm asking. Why do you need to set constraints for > other symbolic expressions, when `SymbolicInferrer` can look them up on its > own? Which cases will fail if we remove that part altogether? I see. Here is what fails in case if we don't update other constraints: void test(int x) { if ((char)x > -10 && (char)x < 10) { if ((short)x == 8) { // If you remove updateExistingConstraints, // then `c` won't be 8. It would be [-10, 10] instead. char c = x; if (c != 8) clang_analyzer_warnIfReached(); // should no-warning, but fail } } } CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103096/new/ https://reviews.llvm.org/D103096 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits