37 karma · joined Jul 10, 2017 (9y ago) · 10 submissions
comment 7y ago · link · parent
[1] https://doc.rust-lang.org/std/path/struct.PathBuf.html
[2] https://doc.rust-lang.org/std/path/struct.PathBuf.html#metho...
[3] https://doc.rust-lang.org/std/path/struct.PathBuf.html#metho...
comment 7y ago · link · parent
This is false.
Neither C# nor Rust protect from memory leaks. There are actually some gotchas in C# that can cause memory leaks - for example, you have to be very careful about events. Memory leaks are not memory unsafe, though.
On the topic of actual memory safety - C# has unsafe blocks just like Rust does. Safe Rust is just as safe from memory safety problems as safe C#, even more so, because C# doesn't require unsafe for FFI, where all bets are off. And unsafe C# is just as unsafe as unsafe Rust can be.
comment 7y ago · link · parent
See this example where I break encapsulation in a struct by abusing a race condition:
https://github.com/VictorGavrish/MultiThreading/blob/master/...
comment 7y ago · link · parent
comment 9y ago · link · parent
I mean, it's pretty unlikely to happen, but it's possible. Plus it doesn't matter if all you cared about was that the HEAD of master passes tests, but not the whole history.
However, the current approach, if rebasing is used to squash every merge request into a single commit on top of master, allows you to have a linear history of the master branch where every commit is known to pass the whole test suite that was in existence at that moment, which, I think, helps a lot when bisecting.
I'm not sure if Rust compresses merge requests into a single commit on top of master, though.