summaryrefslogtreecommitdiff
path: root/crates/types/src
diff options
context:
space:
mode:
Diffstat (limited to 'crates/types/src')
-rw-r--r--crates/types/src/instructions.rs13
1 files changed, 11 insertions, 2 deletions
diff --git a/crates/types/src/instructions.rs b/crates/types/src/instructions.rs
index 95fddc5..535b727 100644
--- a/crates/types/src/instructions.rs
+++ b/crates/types/src/instructions.rs
@@ -1,3 +1,5 @@
+use crate::MemAddr;
+
use super::{FuncAddr, GlobalAddr, LabelAddr, LocalAddr, TableAddr, TypeAddr, ValType};
#[derive(Debug, Copy, Clone, PartialEq, Eq)]
@@ -26,6 +28,8 @@ pub enum ConstInstruction {
F32Const(f32),
F64Const(f64),
GlobalGet(GlobalAddr),
+ RefNull(ValType),
+ RefFunc(FuncAddr),
}
/// A WebAssembly Instruction
@@ -99,8 +103,8 @@ pub enum Instruction {
I64Store8(MemArg),
I64Store16(MemArg),
I64Store32(MemArg),
- MemorySize,
- MemoryGrow,
+ MemorySize(MemAddr, u8),
+ MemoryGrow(MemAddr, u8),
// Constants
I32Const(i32),
@@ -108,6 +112,11 @@ pub enum Instruction {
F32Const(f32),
F64Const(f64),
+ // Reference Types
+ RefNull(ValType),
+ RefFunc(FuncAddr),
+ RefIsNull,
+
// Numeric Instructions
// See <https://webassembly.github.io/spec/core/binary/instructions.html#numeric-instructions>
I32Eqz,