News for hackers. Stuff that matters.
Re:WebAssembly doesn’t make unsafe languages safe by abecedarius on Sunday November 25, 2018 @06:56PM (#18529886)
> Memory is represented as a single linear block

iirc you can have multiple instances or modules, each with its own private linear memory, and they can be set up to call each other's exported functions. It's just that current compilers don't use that encapsulation when compiling a single program. Am I wrong about this?

(I haven't used WebAssembly, only read about it some time ago. But here's a link in support: https://groups.google.com/forum/#!topic/e-lang/3A6zYWF6u5E "Multiple module instances only share an address space if they explicitly export/import a linear memory, which is just another kind of module-level definition. A module can define its own linear memory and not export it, in which case nobody else can access it.")

Re:WebAssembly doesn’t make unsafe languages safe by kbumsik on Sunday November 25, 2018 @07:10PM (#18529951)
It might be possible when exchanging only numbers. But I think it's going to be quite tricky when exchanging pointers of buffers between modules since values of a pointer in a module is meaningless to the other module if the momory block is not shared.