This is part of the implementation of the dataflow analysis framework.
See "[RFC] A dataflow analysis framework for Clang AST" on cfe-dev.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
clang/lib/Analysis/FlowSensitive/Transfer.cpp | ||
---|---|---|
171 | why None? Is the idea that if the expression generates a reference, we want to get the pointer value, not the pointee? struct A { int &x; int &y = x; }; |
clang/lib/Analysis/FlowSensitive/Transfer.cpp | ||
---|---|---|
171 | Right, y gets assigned the same ReferenceValue as x in this case. |
why None? Is the idea that if the expression generates a reference, we want to get the pointer value, not the pointee?
So, in the example below, the value set for field y will (correctly) be the same pointer stored in field x?