Skip to content

Commit

Permalink
Rollup merge of rust-lang#62186 - GuillaumeGomez:add-missing-type-lin…
Browse files Browse the repository at this point in the history
…ks-into, r=docs

Add missing type urls in Into trait

r? @rust-lang/docs
  • Loading branch information
Mark-Simulacrum committed Jul 3, 2019
2 parents cd9d360 + 3e83728 commit 64a6736
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/libcore/convert.rs
Original file line number Diff line number Diff line change
Expand Up @@ -251,12 +251,12 @@ pub trait AsMut<T: ?Sized> {
///
/// # Examples
///
/// [`String`] implements `Into<Vec<u8>>`:
/// [`String`] implements [`Into`]`<`[`Vec`]`<`[`u8`]`>>`:
///
/// In order to express that we want a generic function to take all arguments that can be
/// converted to a specified type `T`, we can use a trait bound of [`Into`]`<T>`.
/// For example: The function `is_hello` takes all arguments that can be converted into a
/// `Vec<u8>`.
/// [`Vec`]`<`[`u8`]`>`.
///
/// ```
/// fn is_hello<T: Into<Vec<u8>>>(s: T) {
Expand All @@ -274,6 +274,7 @@ pub trait AsMut<T: ?Sized> {
/// [`String`]: ../../std/string/struct.String.html
/// [`From`]: trait.From.html
/// [`Into`]: trait.Into.html
/// [`Vec`]: ../../std/vec/struct.Vec.html
#[stable(feature = "rust1", since = "1.0.0")]
pub trait Into<T>: Sized {
/// Performs the conversion.
Expand Down

0 comments on commit 64a6736

Please sign in to comment.