Skip to main content

gas_handle

Function gas_handle 

Source
pub fn gas_handle(meter_key: &Key) -> InstanceCap
Expand description

Build a Gas{meter_key} unit handle: a Cap::Instance with the well-known Gas image-hash chain and the meter_key packed into regs[0..1] (same packing as yield_sender). The kernel reads these handles from an Instance’s ordered gas_slots to index the gas-meter mapping; minted by the kernel:mint_gas syscall.