Skip to content

Commit 592bdc3

Browse files
Add missing links in io module docs
1 parent ac0ee51 commit 592bdc3

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

src/libstd/io/mod.rs

+6-4
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
//! you'll see a few different types of I/O throughout the documentation in
2323
//! this module: [`File`]s, [`TcpStream`]s, and sometimes even [`Vec<T>`]s. For
2424
//! example, [`Read`] adds a [`read`][`Read::read`] method, which we can use on
25-
//! `File`s:
25+
//! [`File`]s:
2626
//!
2727
//! ```
2828
//! use std::io;
@@ -146,9 +146,9 @@
146146
//! # }
147147
//! ```
148148
//!
149-
//! Note that you cannot use the `?` operator in functions that do not return
150-
//! a `Result<T, E>` (e.g. `main`). Instead, you can call `.unwrap()` or `match`
151-
//! on the return value to catch any possible errors:
149+
//! Note that you cannot use the [`?` operator] in functions that do not return
150+
//! a [`Result<T, E>`][`Result`] (e.g. `main`). Instead, you can call [`.unwrap()`]
151+
//! or `match` on the return value to catch any possible errors:
152152
//!
153153
//! ```
154154
//! use std::io;
@@ -265,6 +265,8 @@
265265
//! [`io::Result`]: type.Result.html
266266
//! [`?` operator]: ../../book/first-edition/syntax-index.html
267267
//! [`Read::read`]: trait.Read.html#tymethod.read
268+
//! [`Result`]: ../result/enum.Result.html
269+
//! [`.unwrap()`]: ../result/enum.Result.html#method.unwrap
268270
269271
#![stable(feature = "rust1", since = "1.0.0")]
270272

0 commit comments

Comments
 (0)