Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

First let me say that I'm not familiar with Nim. But I understand that it compiles/transpiles to C/C++. And it sounds like they're now trying to move away from dependency on the GC. In that case, might I suggest they consider switching the transpile target to SaferCPlusPlus[1]. It might make things easier as it already addresses the "efficient memory-safety via scope lifetimes without a borrow-checker" issue. And also the (data race) safe sharing of objects between threads. (Note that the documentation is currently rather out-of-date, and a major update is coming.)

[1] shameles plug: https://github.com/duneroadrunner/SaferCPlusPlus



Nim compiles to C/C++/Objective-C and Javascript and all memory safety is handled on the Nim side.

The C/C++ code generated by the Nim compiler is then free to use unsafe constructs including the dreaded goto.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: