courbet marked 3 inline comments as done.
courbet added inline comments.
================
Comment at: 
clang-tools-extra/clang-tidy/bugprone/StringIntegerAssignmentCheck.cpp:115
+    Expr::EvalResult EvalResult;
+    if (!E->EvaluateAsInt(EvalResult, Ctx, Expr::SE_AllowSideEffects))
+      return false;
----------------
alexfh wrote:
> I believe you should also check (or assert) that `E` is not 
> instantiation-dependent before running the evaluator.
Interesting. AFAICT if I don't check that , I end up warning in the cases when 
the instantiation does result in a too large constant, which is what we want 
(the user should add a cast if they want to silence this). 


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D59360



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

Reply via email to