]> granicus.if.org Git - clang/commitdiff
The RValueType of a TypedViewRegion should be the pointee type.
authorZhongxing Xu <xuzhongxing@gmail.com>
Wed, 11 Mar 2009 09:10:39 +0000 (09:10 +0000)
committerZhongxing Xu <xuzhongxing@gmail.com>
Wed, 11 Mar 2009 09:10:39 +0000 (09:10 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66655 91177308-0d34-0410-b5e6-96231b3b80d8

include/clang/Analysis/PathSensitive/MemRegion.h

index d22dccc77cb60055cd5b5a21b3f3a0f99d5680db..10bef309ac39cc7210d7842ee280b49bd6983157 100644 (file)
@@ -252,7 +252,9 @@ public:
   void print(llvm::raw_ostream& os) const;
   
   QualType getRValueType(ASTContext&) const {
-    return T;
+    const PointerType* PTy = T->getAsPointerType();
+    assert(PTy);
+    return PTy->getPointeeType();
   }
 
   void Profile(llvm::FoldingSetNodeID& ID) const {