File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -27,7 +27,6 @@ fn main() {
2727}
2828```
2929
30-
3130## Motivation
3231
3332In rust, there are two ways an operation can fail: An expected problem, like a
@@ -45,6 +44,7 @@ valid response if the route for that request (as in: logic outside of the web se
4544implementor's control) is producing a panic.
4645
4746## Disadvantages
47+
4848
4949` panic::catch_unwind ` may not catch all panics in Rust. A panic in Rust is not always
5050implemented via unwinding, but can be implemented by aborting the process as well.
6262?-operator to propagate errors
6363explain why unwinding is bad
6464other disadvantages of panic::catch_unwind
65+
6566+ "The example could be improved by adding a function and which panics and catching the panic
6667in the caller, then matching the Result. Describing the example you could show how by returning
6768a Result, the Result-ness of the function is described in the signature."
You can’t perform that action at this time.
0 commit comments