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

EDIT: Parent commenter edited the comment to append "with the same performance as C", so you can ignore my reply.

So is Python, JavaScript, Java, OCaml, Haskell...

A more distinguishing feature of Rust is not only that it is memory safe but also that it doesn’t have a GC.

In any case the presence of a single unsafe block can make the program no longer memory safe. Of course, if used appropriately, it vastly reduces the audit surface compared to something like C++.



None of those have nearly the same performance as C.


GP edited the comment, so now my reply looks silly.


OCaml can have nearly the same performance as C.


Is GC a negative? I’ve yet to see anyone go “well I would’ve written this in Golang but it’s got GC”. Even that new Windows driver style, where it’s split in two, can have half of it being GC’d, right? Looking at https://en.wikipedia.org/wiki/Windows_Driver_Frameworks at least.


> I’ve yet to see anyone go “well I would’ve written this in Golang but it’s got GC”.

This is a dealbreaker in a lot of contexts where garbage collection pauses would be unacceptable.


Yes, GC is a negative. There is a huge literature in measures to mitigate its negatives. These always involve trading off one against another, and libraries are frequently incompatible with any particular mix of them.


A GC is literally the only reason I haven't tried go.




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

Search: