1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

wasm module: globals, constant expressions and function reference types (#17950)

This commit is contained in:
l-m
2023-04-14 03:39:55 +10:00
committed by GitHub
parent 093e5c68b9
commit 8b2887d80b
8 changed files with 455 additions and 67 deletions

View File

@ -13,16 +13,22 @@ struct FunctionCallPatch {
type CallPatch = FunctionCallPatch | ImportCallPatch
struct Function {
struct FunctionGlobalPatch {
idx GlobalIndex
pos int
}
pub struct Function {
tidx int
idx int
mut:
call_patches []CallPatch
label int
export bool
mod &Module
code []u8
locals []ValType
call_patches []CallPatch
global_patches []FunctionGlobalPatch
label int
export bool
mod &Module = unsafe { nil }
code []u8
locals []ValType
pub:
name string
}