summaryrefslogtreecommitdiff
path: root/include/llvm/ADT/SmallVector.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-08-08 01:54:17 +0000
committerChris Lattner <sabre@nondot.org>2006-08-08 01:54:17 +0000
commit8e10f5b8113a5080fc916d1123377292ef2f6012 (patch)
tree6c9eac9a987849778b77a94591afaaa40abb7e13 /include/llvm/ADT/SmallVector.h
parentebfe07fb1886fd2e99c56e59d56b68c096a13ce8 (diff)
downloadllvm-8e10f5b8113a5080fc916d1123377292ef2f6012.tar.gz
llvm-8e10f5b8113a5080fc916d1123377292ef2f6012.tar.bz2
llvm-8e10f5b8113a5080fc916d1123377292ef2f6012.tar.xz
capacity is a pointer, not a value
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@29564 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/ADT/SmallVector.h')
-rw-r--r--include/llvm/ADT/SmallVector.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/llvm/ADT/SmallVector.h b/include/llvm/ADT/SmallVector.h
index 0ade4847b4..3e952ac447 100644
--- a/include/llvm/ADT/SmallVector.h
+++ b/include/llvm/ADT/SmallVector.h
@@ -148,7 +148,7 @@ public:
void assign(unsigned NumElts, const T &Elt) {
clear();
- if (NumElts > Capacity)
+ if (Begin+NumElts > Capacity)
grow(NumElts);
End = Begin+NumElts;
for (; NumElts; --NumElts)