Hacker News new | ask | show | jobs
by ianjsikes 3276 days ago
Author here. It is my cursory understanding that the Emscripten SDK handles converting types to and from Javascript values and C-like data in the module's virtual memory. I'm not totally sure how that conversion is happening yet. I can tell you that when I pass a string when it expects an i32, it treats it as 0, so `add("foo", "bar") -> 0`
1 comments

Wonder if it will be possible to make it panic/error instead