Skip to content

Instantly share code, notes, and snippets.

@Hywan
Created May 12, 2020 09:36
Show Gist options
  • Save Hywan/a8c104e9c59687d04fb897546dc6020d to your computer and use it in GitHub Desktop.
Save Hywan/a8c104e9c59687d04fb897546dc6020d to your computer and use it in GitHub Desktop.
A Rust program that compiles to WebAssembly
#[no_mangle]
pub extern fn return_hello() -> *const u8 {
b"Hello, World!\0".as_ptr()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment