Fix some conflicting loans

This commit is contained in:
Brendan Zabarauskas 2013-03-29 12:04:59 +11:00
parent 3869c24ec8
commit fbb484408b
3 changed files with 6 additions and 3 deletions

View file

@ -281,7 +281,8 @@ impl<T:Copy + Float + Add<T,T> + Sub<T,T> + Mul<T,T> + Div<T,T> + Neg<T>> Mutabl
}
fn lerp_self(&mut self, other: &Vec2<T>, amount: T) {
self.add_self_v(&other.sub_v(self).mul_t(amount));
let v = other.sub_v(self).mul_t(amount);
self.add_self_v(&v);
}
}

View file

@ -313,7 +313,8 @@ impl<T:Copy + Float + Add<T,T> + Sub<T,T> + Mul<T,T> + Div<T,T> + Neg<T>> Mutabl
}
fn lerp_self(&mut self, other: &Vec3<T>, amount: T) {
self.add_self_v(&other.sub_v(self).mul_t(amount));
let v = other.sub_v(self).mul_t(amount);
self.add_self_v(&v);
}
}

View file

@ -311,7 +311,8 @@ impl<T: Copy + Float + Add<T,T> + Sub<T,T> + Mul<T,T> + Div<T,T> + Neg<T>> Mutab
}
fn lerp_self(&mut self, other: &Vec4<T>, amount: T) {
self.add_self_v(&other.sub_v(self).mul_t(amount));
let v = other.sub_v(self).mul_t(amount);
self.add_self_v(&v);
}
}