Skip to content

Instantly share code, notes, and snippets.

@vmesel
Created July 17, 2018 19:13
Show Gist options
  • Save vmesel/e1e60e0e14bbc580f21970f830d621c7 to your computer and use it in GitHub Desktop.
Save vmesel/e1e60e0e14bbc580f21970f830d621c7 to your computer and use it in GitHub Desktop.
m = {}
m["Types"]["Entries"] = [
{
"Form": 0,
"ParamTypes": [
"i32"
]
},
{
"Form": 0,
"ParamTypes": [
"i32"
]
},
]
m["FunctionIndexSpace"] = [
{
"Sig": m["Types"]["Entries"][0],
"Host": eval(print),
"Body": FunctionBody()
},
{
"Sig": m["Types"]["Entries"][0],
"Host": eval(print2),
"Body": FunctionBody()
},
]
m["Export"]["Entries"] = [
{
"print": {
"FieldStr": "print",
"Kind": wasm.ExternalFunction,
"Index": 0
},
"print2": {
"FieldStr": "print2",
"Kind": wasm.ExternalFunction,
"Index": 1
},
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment