Skip to content

Commit eb0a8fd

Browse files
authored
Bump to version 0.4.2 (#99)
* Bump to version 0.4.2 * Remove take-and-replace dance There are no conflicting borrows of `self` anymore.
1 parent fdcf7b6 commit eb0a8fd

File tree

2 files changed

+2
-9
lines changed

2 files changed

+2
-9
lines changed

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "regalloc2"
3-
version = "0.4.1"
3+
version = "0.4.2"
44
authors = [
55
"Chris Fallin <[email protected]>",
66
"Mozilla SpiderMonkey Developers",

src/ion/spill.rs

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -90,10 +90,7 @@ impl<'a, F: Function> Env<'a, F> {
9090
) {
9191
self.spillsets[spillset.index()].slot = spillslot;
9292

93-
// Take `spillsets` to avoid a conflicting borrow of `self`.
94-
let spillsets = std::mem::take(&mut self.spillsets);
95-
96-
for vreg in &spillsets[spillset.index()].vregs {
93+
for vreg in &self.spillsets[spillset.index()].vregs {
9794
trace!(
9895
"spillslot {:?} alloc'ed to spillset {:?}: vreg {:?}",
9996
spillslot,
@@ -114,10 +111,6 @@ impl<'a, F: Function> Env<'a, F> {
114111
.insert(LiveRangeKey::from_range(&entry.range), entry.index);
115112
}
116113
}
117-
118-
// Replace `spillsets`.
119-
let default = std::mem::replace(&mut self.spillsets, spillsets);
120-
debug_assert!(default.is_empty());
121114
}
122115

123116
pub fn allocate_spillslots(&mut self) {

0 commit comments

Comments
 (0)