07:51 | <snek> | Chengzhong Wu: why does the import source call in v8 assert that the object is a wasm module object? |
09:00 | <Chengzhong Wu> | Chengzhong Wu: why does the import source call in v8 assert that the object is a wasm module object? |
09:02 | <Chengzhong Wu> | The first stage of implementation does not expose host defined module source yet |
09:13 | <snek> | I mean from a js engine perspective it can be any object right? wasm spec defines wasm module objects but other specs can define other ones. |
09:20 | <Chengzhong Wu> | Yes, it can be other objects, when it’s defined in other specs. |
10:17 | <nicolo-ribaudo> | It'd be nice if, for example, Node.js was able to support sources for .node modules even if there is no spec for it |
10:44 | <Chengzhong Wu> | are you referring to addons? I'd doubt it will be a cross-platform feature to load an addon from memory without writing to fs first. |
10:46 | <Chengzhong Wu> | It's the second stage in the design |
11:10 | <Chengzhong Wu> | At the moment, Node.js module loader does not support providing source for an addon .node module: https://nodejs.org/docs/latest/api/module.html#loadurl-context-nextload yet |