summaryrefslogtreecommitdiff
path: root/include/llvm/ADT/BitVector.h
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2007-02-15 19:10:34 +0000
committerEvan Cheng <evan.cheng@apple.com>2007-02-15 19:10:34 +0000
commitccae61c5da270b0684c4c7d2450d9bf3ff35aac7 (patch)
tree9a0fd915a986e1bb2a1d7d67b590b8616b711c3c /include/llvm/ADT/BitVector.h
parent7bf26c1d68f75de9c1c8520620228b016bf9a0eb (diff)
downloadllvm-ccae61c5da270b0684c4c7d2450d9bf3ff35aac7.tar.gz
llvm-ccae61c5da270b0684c4c7d2450d9bf3ff35aac7.tar.bz2
llvm-ccae61c5da270b0684c4c7d2450d9bf3ff35aac7.tar.xz
Clear no longer deleting the bits to avoid mallocs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34315 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/ADT/BitVector.h')
-rw-r--r--include/llvm/ADT/BitVector.h6
1 files changed, 1 insertions, 5 deletions
diff --git a/include/llvm/ADT/BitVector.h b/include/llvm/ADT/BitVector.h
index 03789aa4ff..6910be04e5 100644
--- a/include/llvm/ADT/BitVector.h
+++ b/include/llvm/ADT/BitVector.h
@@ -157,11 +157,7 @@ public:
/// clear - Clear all bits.
void clear() {
- if (Capacity > 0) {
- delete[] Bits;
- Bits = NULL;
- Size = Capacity = 0;
- }
+ Size = 0;
}
/// resize - Grow or shrink the bitvector.