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

Cool, but the point of having stuff in Rust is to ideally have everything in Rust, or you're by definition not getting all the safety benefits of Rust.


Dart is also safe.


While dart is definitely not like rust, dart is a very safe language. I'd love a dart+rust project if the package ecosystem wasn't such a mess in dart


Not at all, pretty much all popular languages (except C/C++) are as safe as (safe) rust. The only safety rust brings to the table is memory safety, which most languages achieve with a runtime and a garbage collector, which have a performance tradeoff.


In three most narrow definition of safety I agree. But that's a very narrow definition. Rust does offer a lot more:

- no undefined behavior

- many classes of concurrency bugs prevented by the type system

- standard library and much of the ecosystem makes invalid states unrepresentable. E.g. a String is always valid UTF8

Those are things that are true to varying degrees for other languages. Dart does pretty well imho. But for example Java and C# offer memory safety but have very unsafe concurrency


Rust's concurrency is only safe in the very specific use case of threads trying to access common resources on the same memory space.

It does nothing to prevent data races between processes, or concurrency errors between threads accessing resources that are external to the process.

Scenarios quite relevant in distributed systems.


A bulletproof vest doesn't stop you getting stabbed, it still makes you safer though.


Unless it is a skilled shoter doing an head shot, or using high caliber ammunition.

I do agree it helps, but it isn't the improvement over other memory safe languages, that the Rust Evagelism Strike Force makes it to be.


Or you have "standard" vest (without ceramic armor plates) and the shooter shelled out for handgun designed for (and with) armor-piercing ammo or PDW-class gun or higher powered cartridge in a full rifle.. etc ;)


You definitely also get a lot more thread safety out of Rust than most languages.




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

Search: