Re:Hecto: Build your own text editor in Rust
by brundolf on Monday January 18, 2021 @10:08PM
(#25829558)
Picking a further nit: the key difference is that most other languages can share memory directly between threads, whereas JS can only pass messages between threads (which requires copying data, and usually serialization/deserialization)
[ Parent
| on HN ]
Re:Hecto: Build your own text editor in Rust
by pornel on Tuesday January 19, 2021 @03:47AM
(#25831279)
Workers have "transferable" objects that in theory avoid copies, but still there's a world of difference between coarse-grained message-passing style, and fine-grained data parallelism you can get from something like rayon.
JS "can" do a lot of things if you know how, and cleverly implement and optimize the code, but it's a Turing Tarpit. You wouldn't implement a video codec in JS. You could, but it's not the best language for it.