]> granicus.if.org Git - clang/commitdiff
Use more robust getAsRecordType() method.
authorZhongxing Xu <xuzhongxing@gmail.com>
Thu, 11 Jun 2009 07:27:30 +0000 (07:27 +0000)
committerZhongxing Xu <xuzhongxing@gmail.com>
Thu, 11 Jun 2009 07:27:30 +0000 (07:27 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@73186 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Analysis/RegionStore.cpp

index 02d3d1f885f956cefb4a127f78a484bd25bac9f4..528ee89a4ce0f4e1a1bf9f37779967d2f0e761d2 100644 (file)
@@ -840,7 +840,7 @@ SVal RegionStoreManager::RetrieveStruct(const GRState* St,const TypedRegion* R){
   QualType T = R->getValueType(getContext());
   assert(T->isStructureType());
 
-  const RecordType* RT = cast<RecordType>(T.getTypePtr());
+  const RecordType* RT = T->getAsStructureType();
   RecordDecl* RD = RT->getDecl();
   assert(RD->isDefinition());