size() should return a size_t; avoids a warning for 64 bit machines.
authorMon P Wang <wangmp@apple.com>
Sat, 25 Apr 2009 20:46:59 +0000 (20:46 +0000)
committerMon P Wang <wangmp@apple.com>
Sat, 25 Apr 2009 20:46:59 +0000 (20:46 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70072 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/Constants.h

index f5c265570e64a65e73d8211c418452ca1bd6891b..ae3a85bc386925b51cdc2515d2c6a86492c42e4b 100644 (file)
@@ -845,7 +845,7 @@ public:
 
   /// size() - The length of this string.
   ///
-  unsigned size() const { return StrEnd - StrBegin; }
+  size_t size() const { return StrEnd - StrBegin; }
 
   /// begin() - Pointer to the first byte of the string.
   ///