Rollup merge of #25376 - swaroopch:patch-2, r=steveklabnik

I don't recall reading about this `Debug` trait so far in the book. Please ignore this PR if I have missed that part.

r? @steveklabnik
This commit is contained in:
Steve Klabnik 2015-05-13 16:51:29 -04:00
commit a96f09bf52

View file

@ -181,6 +181,8 @@ match version {
This function makes use of an enum, `ParseError`, to enumerate the various
errors that can occur.
The [`Debug`](../std/fmt/trait.Debug.html) trait is what lets us print the enum value using the `{:?}` format operation.
# Non-recoverable errors with `panic!`
In the case of an error that is unexpected and not recoverable, the `panic!`