[PATCH] D146507: [clang][dataflow][NFC] Eliminate StmtToEnvMap interface.
Yitzhak Mandelbaum via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Mar 22 06:24:01 PDT 2023
ymandel accepted this revision.
ymandel added a comment.
thanks!
================
Comment at: clang/include/clang/Analysis/FlowSensitive/Transfer.h:36-40
+ auto BlockIt = CFCtx.getStmtToBlock().find(&ignoreCFGOmittedNodes(S));
+ assert(BlockIt != CFCtx.getStmtToBlock().end());
+ const auto &State = BlockToState[BlockIt->getSecond()->getBlockID()];
+ assert(State);
+ return &State->Env;
----------------
Nit: why inline vs putting the definition in Transfer.cpp? I don't have a good sense for the size cutoff on this decision but if it's only used there, then might make sense just to keep the header leaner.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D146507/new/
https://reviews.llvm.org/D146507
More information about the cfe-commits
mailing list