3 ms·
Re ctypes, I assume you are talking about https://developer.mozilla.org/en-US/docs/Mozilla/js-ctypes https://developer.mozilla.org/en-US/docs/Mozilla/js-ctypes.
by sjrd 10y ago
Re ctypes, I assume you are talking about https://developer.mozilla.org/en-US/docs/Mozilla/js-ctypes https://developer.mozilla.org/en-US/docs/Mozilla/js-ctypes. On that page you can read:
> js-ctypes is only available from chrome code; that is, ctypes is not available to websites, only application and extension code.
Basically `js-ctypes` won't work in an actual browser. So you cannot use it. There are other Node.js-specific native packages that give a representation for 64-bit integers, but not arithmetic operations. Besides, even if they had arithmetic operations, they would be heap-allocated, and since the JIT cannot understand them, it would not be able to optimize them as well as what we built for Scala.js.