Skip to content

Commit 1805bba

Browse files
committed
Auto merge of #30053 - JIghtuse:master, r=steveklabnik
2 parents 498f08d + b892b5a commit 1805bba

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/doc/book/error-handling.md

+1
Original file line numberDiff line numberDiff line change
@@ -681,6 +681,7 @@ fn double_arg(mut argv: env::Args) -> Result<i32, String> {
681681
argv.nth(1)
682682
.ok_or("Please give at least one argument".to_owned())
683683
.and_then(|arg| arg.parse::<i32>().map_err(|err| err.to_string()))
684+
.map(|n| 2 * n)
684685
}
685686

686687
fn main() {

0 commit comments

Comments
 (0)