[PATCH] D131438: [clang][dataflow] Analyze constructor bodies
Sam Estep via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Aug 9 13:48:14 PDT 2022
samestep added inline comments.
================
Comment at: clang/lib/Analysis/FlowSensitive/DataflowEnvironment.cpp:219-245
// FIXME: Support references here.
- Env.ReturnLoc = Env.getStorageLocation(*Call, SkipPast::Reference);
+ ReturnLoc = getStorageLocation(*Call, SkipPast::Reference);
- const auto *FuncDecl = Call->getDirectCallee();
- assert(FuncDecl != nullptr);
// FIXME: In order to allow the callee to reference globals, we probably need
// to call `initGlobalVars` here in some way.
if (const auto *MethodCall = dyn_cast<CXXMemberCallExpr>(Call)) {
----------------
xazax.hun wrote:
> ymandel wrote:
> > I think you can push all of this logic to the type-specialized `pushCalls` now and just have pushCallInternal take the FunctionDecl, ArrayRef, etc.. WDYT?
> +1, I like that.
Great idea, thanks! Doing that now.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D131438/new/
https://reviews.llvm.org/D131438
More information about the cfe-commits
mailing list