mirror of
https://github.com/roc-lang/roc.git
synced 2025-11-01 21:40:58 +00:00
wasm_module: create const ValueType::VOID to use as block type
This commit is contained in:
parent
b69be0e12d
commit
d9fe907684
2 changed files with 5 additions and 3 deletions
|
|
@ -20,8 +20,6 @@ macro_rules! log_instruction {
|
|||
};
|
||||
}
|
||||
|
||||
const BLOCK_NO_RESULT: u8 = 0x40;
|
||||
|
||||
/// A control block in our model of the VM
|
||||
/// Child blocks cannot "see" values from their parent block
|
||||
struct VmBlock<'a> {
|
||||
|
|
@ -531,7 +529,7 @@ impl<'a> CodeBuilder<'a> {
|
|||
self.inst_base(opcode, pops, false);
|
||||
|
||||
// We don't support block result types. Too hard to track types through arbitrary control flow.
|
||||
self.code.push(BLOCK_NO_RESULT);
|
||||
self.code.push(ValueType::VOID);
|
||||
|
||||
// Start a new block with a fresh value stack
|
||||
self.vm_block_stack.push(VmBlock {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue