vsavchenko added inline comments.

================
Comment at: 
clang/include/clang/StaticAnalyzer/Core/PathSensitive/BasicValueFactory.h:85
   const NamedDecl *D;
+  QualType T;
   llvm::ImmutableList<const CXXBaseSpecifier *> L;
----------------
NoQ wrote:
> What prevents you from obtaining the type from `D`? I guess `NamedDecl` 
> itself doesn't provide a `getType()` on its own but what specific sub-classes 
> can `D` be that don't have a type?
Because it's not a declaration of `pointer-to-member`, but a declaration of the 
actual member.  It can be `nullptr` while the type is always known.
I'd prefer not to construct a pointer-to-member type myself.  It's the work for 
Sema, not for the analyzer.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D104647

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

Reply via email to