box
Module0x40fc…5bb2
- Move path
- 0xed6c…9f32::box
- Functions
- 22 public, 1 entry
- Structs
- 1
- Friend modules
- None
box
Bytecode35 lines
The on-chain disassembly. Offsets are bytecode positions within each function.
// Move bytecode v6
module ed6c6fe0732be937f4379bc0b471f0f6bfbe0e8741968009e0f01e6de3d59f32.box {
use 0000000000000000000000000000000000000000000000000000000000000002::object;
use 0000000000000000000000000000000000000000000000000000000000000002::transfer;
use 0000000000000000000000000000000000000000000000000000000000000002::tx_context;
struct Box<Ty0: store> has store, key {
id: UID,
obj: Ty0
}
entry public box<Ty0: store>(Arg0: address, Arg1: Ty0, Arg2: &mut TxContext) {
B0:
0MoveLoc[2](Arg2: &mut TxContext)
1Call object::new(&mut TxContext): UID
2MoveLoc[1](Arg1: Ty0)
3PackGeneric[0](Box<Ty0>)
4MoveLoc[0](Arg0: address)
5Call transfer::public_transfer<Box<Ty0>>(Box<Ty0>, address)
6Ret
}
public unbox<Ty0: store>(Arg0: Box<Ty0>): Ty0 {
L1: loc0: Ty0
B0:
0MoveLoc[0](Arg0: Box<Ty0>)
1UnpackGeneric[0](Box<Ty0>)
2StLoc[1](loc0: Ty0)
3Call object::delete(UID)
4MoveLoc[1](loc0: Ty0)
5Ret
}
}