mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-28 19:31:58 +00:00
RegionInfo: Do not access a value that was just moved away
This fixes a regression introduced in r206310. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@206328 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
d24010f61a
commit
d4955a007b
@ -363,8 +363,8 @@ void Region::addSubRegion(Region *SubRegion, bool moveChildren) {
|
||||
std::vector<std::unique_ptr<Region>> Keep;
|
||||
for (iterator I = begin(), E = end(); I != E; ++I)
|
||||
if (SubRegion->contains(I->get()) && I->get() != SubRegion) {
|
||||
SubRegion->children.push_back(std::move(*I));
|
||||
(*I)->parent = SubRegion;
|
||||
SubRegion->children.push_back(std::move(*I));
|
||||
} else
|
||||
Keep.push_back(std::move(*I));
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user