JonasToth added inline comments.

================
Comment at: clang-tidy/llvm/ProblematicStaticsCheck.cpp:33
+  const auto *VD = Result.Nodes.getNodeAs<VarDecl>("var");
+  const auto *Return = Result.Nodes.getNodeAs<ReturnStmt>("return");
+  diag(Return->getBeginLoc(), "address of static local variable %0 may not "
----------------
aaron.ballman wrote:
> JonasToth wrote:
> > Please `assert` on `VD` and `Return`
> > Please assert on VD and Return
> Why?
because the matcher might evolve over time. Right now this can not be 
triggered, that is correct. Asking for it was  inappropriate but having it 
doesn't hurt.


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D54222



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

Reply via email to