aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2010-03-10 18:22:38 +0000
committerTed Kremenek <kremenek@apple.com>2010-03-10 18:22:38 +0000
commit8515fbf1a1b89e9750ebf3e2ee2c9440424befee (patch)
treeec6bcb5aaac18b57a07049d2a2aa2af8092f0f34
parentd69493ae62e3ef89f99b08a1aa211489a2de80eb (diff)
Fix -Wsign-compare warning reported by clang++.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98170 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/Basic/SourceManager.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Basic/SourceManager.cpp b/lib/Basic/SourceManager.cpp
index 0c22de7bdd..156b809b51 100644
--- a/lib/Basic/SourceManager.cpp
+++ b/lib/Basic/SourceManager.cpp
@@ -43,7 +43,8 @@ unsigned ContentCache::getSizeBytesMapped() const {
/// scratch buffer. If the ContentCache encapsulates a source file, that
/// file is not lazily brought in from disk to satisfy this query.
unsigned ContentCache::getSize() const {
- return Buffer ? Buffer->getBufferSize() : Entry->getSize();
+ return Buffer ? (unsigned) Buffer->getBufferSize()
+ : (unsigned) Entry->getSize();
}
void ContentCache::replaceBuffer(const llvm::MemoryBuffer *B) {