Author: kremenek
Date: Tue Feb 17 16:21:44 2009
New Revision: 64832

URL: http://llvm.org/viewvc/llvm-project?rev=64832&view=rev
Log:
BasicValueFactory: getMinValue/getMaxValue can be applied to any location type 
as specified by Loc::IsLocType().

Modified:
    cfe/trunk/include/clang/Analysis/PathSensitive/BasicValueFactory.h

Modified: cfe/trunk/include/clang/Analysis/PathSensitive/BasicValueFactory.h
URL: 
http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Analysis/PathSensitive/BasicValueFactory.h?rev=64832&r1=64831&r2=64832&view=diff

==============================================================================
--- cfe/trunk/include/clang/Analysis/PathSensitive/BasicValueFactory.h 
(original)
+++ cfe/trunk/include/clang/Analysis/PathSensitive/BasicValueFactory.h Tue Feb 
17 16:21:44 2009
@@ -90,16 +90,14 @@
   }
 
   inline const llvm::APSInt& getMaxValue(QualType T) {
-    assert(T->isIntegerType() || T->isPointerType() || 
T->isBlockPointerType());
-    bool isUnsigned = T->isUnsignedIntegerType() || T->isPointerType() ||
-                      T->isBlockPointerType();
+    assert(T->isIntegerType() || Loc::IsLocType(T));
+    bool isUnsigned = T->isUnsignedIntegerType() || Loc::IsLocType(T);
     return getValue(llvm::APSInt::getMaxValue(Ctx.getTypeSize(T), isUnsigned));
   }
   
   inline const llvm::APSInt& getMinValue(QualType T) {
-    assert(T->isIntegerType() || T->isPointerType() || 
T->isBlockPointerType());
-    bool isUnsigned = T->isUnsignedIntegerType() || T->isPointerType() ||
-                      T->isBlockPointerType();
+    assert(T->isIntegerType() || Loc::IsLocType(T));
+    bool isUnsigned = T->isUnsignedIntegerType() || Loc::IsLocType(T);
     return getValue(llvm::APSInt::getMinValue(Ctx.getTypeSize(T), isUnsigned));
   }
   


_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to