diff options
author | Chris Lattner <sabre@nondot.org> | 2007-03-20 02:10:56 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2007-03-20 02:10:56 +0000 |
commit | b9174dd5dc2a782e617fe45200ec462bcef26cee (patch) | |
tree | 2d4505fce5a9b8f21f127faeecb7fbdafc250a3b /include/llvm/ADT/BitVector.h | |
parent | 66728ef3d20b3d05a1e7478b286a164c50c510ad (diff) |
Add a dtor to fix leaks from all clients of BitVector.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35200 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/ADT/BitVector.h')
-rw-r--r-- | include/llvm/ADT/BitVector.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/llvm/ADT/BitVector.h b/include/llvm/ADT/BitVector.h index 2b0e127265..7792ab069e 100644 --- a/include/llvm/ADT/BitVector.h +++ b/include/llvm/ADT/BitVector.h @@ -86,6 +86,10 @@ public: Bits = new BitWord[Capacity]; std::copy(RHS.Bits, &RHS.Bits[Capacity], Bits); } + + ~BitVector() { + delete[] Bits; + } /// size - Returns the number of bits in this bitvector. unsigned size() const { return Size; } |