mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-24 23:28:41 +00:00
Make the assignment operator for SmallPtrSet return a reference, and fix a long-standing bug in the copy
ctor while I'm at it. Thanks to Chris Lattner for help with this patch. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@38470 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -164,7 +164,7 @@ SmallPtrSetImpl::SmallPtrSetImpl(const SmallPtrSetImpl& that) {
|
||||
CurArray[CurArraySize] = 0;
|
||||
|
||||
// Copy over all valid entries.
|
||||
for (void **BucketPtr = that.CurArray, **E = that.CurArray+CurArraySize;
|
||||
for (void **BucketPtr = that.CurArray, **E = that.CurArray+that.CurArraySize;
|
||||
BucketPtr != E; ++BucketPtr) {
|
||||
// Copy over the element if it is valid.
|
||||
void *Elt = *BucketPtr;
|
||||
|
Reference in New Issue
Block a user