3 ms·
In Rust, no clue because I've never tried. However, I did find a hot reload of WASM compiled from C++ [1]. If they're not equivalent, I would imagine it's a mat
by onei 5y ago
In Rust, no clue because I've never tried. However, I did find a hot reload of WASM compiled from C++ [1]. If they're not equivalent, I would imagine it's a matter of ecosystem maturity rather than it being impossible.
Realistically, hot reload is going to be something like inotify(7) hooked into a compiler and whatever it takes to reload seamlessly. If it's been solved in one general purpose language, it's likely to be possible in another.
[1] https://visualstudiomagazine.com/articles/2021/07/29/cpp-hot-reload.aspx?m=1 https://visualstudiomagazine.com/articles/2021/07/29/cpp-hot...
- CraigJPerry 5y agoYou can definitely hot reload in rust: https://fasterthanli.me/articles/so-you-want-to-live-reload-rust https://fasterthanli.me/articles/so-you-want-to-live-reload-... (this person's blog is one of my fav's, i know that's a huge post but he covers everything really well). But this is missing the difference. When we say hot reload in javascript (or even better, hot module replacement) or java or rust or c++, there's usually annoying limitations like you can't change the arity of a function or you have to pause all the threads or you need some mechanism to reset state to a known good starting point because we just broke it (potentially). The difference with a lisp is that you don't need do any of that. You replace the function object in the system image (atomically) and you crack on like nothing happened. No waiting around, no rerunning state into the app. And you triggered it just from a keystroke in your editor. The developer experience is unparalleled.