mirror of
https://github.com/google/comprehensive-rust.git
synced 2025-04-21 15:35:53 +02:00
Fix issues in std-types/result.md (#2186)
The expression excercise is using the standard `Result` type instead of `Res`. Co-authored-by: Jason Lin <lxj@google.com>
This commit is contained in:
parent
25b9dff9d0
commit
a64516a7e6
@ -5,9 +5,8 @@ minutes: 5
|
||||
# Result
|
||||
|
||||
`Result` is similar to `Option`, but indicates the success or failure of an
|
||||
operation, each with a different type. This is similar to the `Res` defined in
|
||||
the expression exercise, but generic: `Result<T, E>` where `T` is used in the
|
||||
`Ok` variant and `E` appears in the `Err` variant.
|
||||
operation, each with a different enum variant. It is generic: `Result<T, E>`
|
||||
where `T` is used in the `Ok` variant and `E` appears in the `Err` variant.
|
||||
|
||||
```rust,editable
|
||||
use std::fs::File;
|
||||
|
Loading…
x
Reference in New Issue
Block a user