Skip to content

Instantly share code, notes, and snippets.

@xelemental
Created August 3, 2021 07:55
Show Gist options
  • Save xelemental/5ad694725abdc7e569e7f767186a231a to your computer and use it in GitHub Desktop.
Save xelemental/5ad694725abdc7e569e7f767186a231a to your computer and use it in GitHub Desktop.
(module
(type $FUNCSIG$ii (func (param i32) (result i32)))
(import "env" "puts" (func $puts (param i32) (result i32)))
(table 0 anyfunc)
(memory $0 1)
(data (i32.const 16) "My first program in WASM\00")
(export "memory" (memory $0))
(export "main" (func $main))
(func $main (; 1 ;) (result i32)
(drop
(call $puts
(i32.const 16)
)
)
(i32.const 0)
)
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment