rename
This commit is contained in:
parent
33e1904e7f
commit
dd2c58bfcf
|
@ -20,8 +20,8 @@ pub enum Instruction {
|
||||||
/// Store a value to locals table
|
/// Store a value to locals table
|
||||||
StLocal(usize),
|
StLocal(usize),
|
||||||
|
|
||||||
/// Pop a value from stack
|
/// Drop a value from stack
|
||||||
Pop,
|
Drop,
|
||||||
|
|
||||||
/// Duplicate value on stack
|
/// Duplicate value on stack
|
||||||
Dup,
|
Dup,
|
||||||
|
|
|
@ -105,7 +105,7 @@ impl<'s> Context<'s> {
|
||||||
StLocal(i) => {
|
StLocal(i) => {
|
||||||
*self.locals.get_mut(i).ok_or(IndexOutOfBoundsError::Local)? = self.stack_pop()?;
|
*self.locals.get_mut(i).ok_or(IndexOutOfBoundsError::Local)? = self.stack_pop()?;
|
||||||
}
|
}
|
||||||
Pop => {
|
Drop => {
|
||||||
self.stack_pop()?;
|
self.stack_pop()?;
|
||||||
}
|
}
|
||||||
Dup => {
|
Dup => {
|
||||||
|
|
Loading…
Reference in a new issue