[PATCH] D66303: [LifetimeAnalysis] Add support for free functions

Matthias Gehre via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Aug 15 13:47:34 PDT 2019


mgehre added inline comments.


================
Comment at: clang/lib/Sema/SemaInit.cpp:6622
+    return false;
+  const auto *RD = FD->getParamDecl(0)->getType()->getPointeeCXXRecordDecl();
+  if (!FD->isInStdNamespace() || !RD || !RD->isInStdNamespace())
----------------
Maybe move the `Callee->getNumParams() == 1` check from the caller into this function so it's obvious that `getParamDecl(0)` is allowed?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D66303





More information about the cfe-commits mailing list