File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -180,6 +180,7 @@ pub trait AsRef<T: ?Sized> {
180180/// write a function `add_one`that takes all arguments that can be converted to `&mut u64`.
181181/// Because [`Box<T>`] implements `AsMut<T>` `add_one` accepts arguments of type
182182/// `&mut Box<u64>` as well:
183+ ///
183184/// ```
184185/// fn add_one<T: AsMut<u64>>(num: &mut T) {
185186/// *num.as_mut() += 1;
@@ -189,8 +190,8 @@ pub trait AsRef<T: ?Sized> {
189190/// add_one(&mut boxed_num);
190191/// assert_eq!(*boxed_num, 1);
191192/// ```
192- /// [`Box<T>`]: ../../std/boxed/struct.Box.html
193193///
194+ /// [`Box<T>`]: ../../std/boxed/struct.Box.html
194195#[ stable( feature = "rust1" , since = "1.0.0" ) ]
195196pub trait AsMut < T : ?Sized > {
196197 /// Performs the conversion.
You can’t perform that action at this time.
0 commit comments