mirror of
https://github.com/Noratrieb/coldsquare.git
synced 2026-01-16 09:25:08 +01:00
fixed clippy lints
This commit is contained in:
parent
5ec9260b59
commit
2460ab4637
8 changed files with 95 additions and 55 deletions
|
|
@ -22,9 +22,8 @@ impl OperandStack {
|
|||
}
|
||||
|
||||
pub fn swap(&mut self) {
|
||||
let tmp = self.arr[(self.sp - 1) as usize];
|
||||
self.arr[(self.sp - 1) as usize] = self.arr[(self.sp - 2) as usize];
|
||||
self.arr[(self.sp - 2) as usize] = tmp;
|
||||
self.arr
|
||||
.swap((self.sp - 2) as usize, (self.sp - 2) as usize);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue