enable rust_2018_idioms
for doctests
Signed-off-by: ozkanonur <work@onurozkan.dev>
This commit is contained in:
parent
8b8110e146
commit
4e7c14fe9f
37 changed files with 125 additions and 101 deletions
|
@ -3142,8 +3142,8 @@ where
|
|||
///
|
||||
/// ```
|
||||
/// # use std::borrow::Cow;
|
||||
/// let o: Cow<[i32]> = Cow::Owned(vec![1, 2, 3]);
|
||||
/// let b: Cow<[i32]> = Cow::Borrowed(&[1, 2, 3]);
|
||||
/// let o: Cow<'_, [i32]> = Cow::Owned(vec![1, 2, 3]);
|
||||
/// let b: Cow<'_, [i32]> = Cow::Borrowed(&[1, 2, 3]);
|
||||
/// assert_eq!(Vec::from(o), Vec::from(b));
|
||||
/// ```
|
||||
fn from(s: Cow<'a, [T]>) -> Vec<T> {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue