4 ms·
What amazes me, is all this cool stuff but a Rust process still can't return an exit code [0] without using a workaround. I actually use Rust in production, an
by yarper 10y ago
What amazes me, is all this cool stuff but a Rust process still can't return an exit code [0] without using a workaround.
I actually use Rust in production, and have generally found it very good - compared to the well discussed difficulties with CPP. I will continue to do so, but I think that the edges really need covering off properly before it'll be treated as a serious competitor to CPP (and equally often, Go).
[0]: https://github.com/rust-lang/rfcs/issues/1176 https://github.com/rust-lang/rfcs/issues/1176
- tveita 10y agoCalling std::process::exit doesn't seem like much of a "workaround"? That's basically the same as Java, which is doing OK as a language. https://doc.rust-lang.org/std/process/fn.exit.html https://doc.rust-lang.org/std/process/fn.exit.html
- yarper 10y agoThis is true! Perhaps my comment was a bit in haste, however there's a lot of caveats with "exits" rather than returns which complicate the matter, for example in Java System.exit can fail (and finizalizers may or may not be run). On top of that you have to type System.exit all the time, which is quite annoying