3 ms·
But with Result encouraged over panic, you can't get to the point of being able to code the main "happy" path without peppering it throughout with calls to unwr
by saurik 12y ago
But with Result encouraged over panic, you can't get to the point of being able to code the main "happy" path without peppering it throughout with calls to unwrap and expansions of try! :(. If this is really how people are being encouraged to develop (and that would be amazing, I just haven't seen it in the Rust code I've seen, which all seems to be closer to how BurntSushi's article deals with error composition), then the error propagation mechanism that developers use as their main way of indicating failure needs to be implicit, something like unchecked exceptions, much closer to panic than Result.