Fixed snippet to return the proper error.
This commit is contained in:
parent
0fbcebaaec
commit
2e1f75acc4
1 changed files with 3 additions and 1 deletions
|
@ -50,6 +50,8 @@ is very wrong. Wrong enough that we can't continue with things in the current
|
|||
state. Another example is using the `unreachable!()` macro:
|
||||
|
||||
```rust,ignore
|
||||
use Event::NewRelease;
|
||||
|
||||
enum Event {
|
||||
NewRelease,
|
||||
}
|
||||
|
@ -71,7 +73,7 @@ fn descriptive_probability(event: Event) -> &'static str {
|
|||
}
|
||||
|
||||
fn main() {
|
||||
std::io::println(descriptive_probability(NewRelease));
|
||||
println!("{}", descriptive_probability(NewRelease));
|
||||
}
|
||||
```
|
||||
|
||||
|
|
Loading…
Reference in a new issue