Rollup merge of #47182 - aheart:master, r=steveklabnik

Equivalent example for ? operator

The example with the ? operator in the documentation for try! macro was missing file.write_all.
Now all three examples are consistent.
This commit is contained in:
kennytm 2018-01-05 17:22:11 +08:00 committed by GitHub
commit 1fea75192e

View file

@ -330,6 +330,7 @@ macro_rules! debug_assert_ne {
/// // The prefered method of quick returning Errors
/// fn write_to_file_question() -> Result<(), MyError> {
/// let mut file = File::create("my_best_friends.txt")?;
/// file.write_all(b"This is a list of my best friends.")?;
/// Ok(())
/// }
///