@@ -10,7 +10,7 @@ This allows moving and dropping of a `OwningRef` without needing to recreate the
10
10
This can sometimes be useful because Rust borrowing rules normally prevent
11
11
moving a type that has been moved from. For example, this kind of code gets rejected:
12
12
13
- ```rust,ignore
13
+ ```compile_fail,E0515
14
14
fn return_owned_and_referenced<'a>() -> (Vec<u8>, &'a [u8]) {
15
15
let v = vec![1, 2, 3, 4];
16
16
let s = &v[1..3];
@@ -43,7 +43,8 @@ and preventing mutable access to root containers, which in practice requires hea
43
43
as provided by `Box<T>`, `Rc<T>`, etc.
44
44
45
45
Also provided are typedefs for common owner type combinations,
46
- which allow for less verbose type signatures. For example, `BoxRef<T>` instead of `OwningRef<Box<T>, T>`.
46
+ which allow for less verbose type signatures.
47
+ For example, `BoxRef<T>` instead of `OwningRef<Box<T>, T>`.
47
48
48
49
The crate also provides the more advanced `OwningHandle` type,
49
50
which allows more freedom in bundling a dependent handle object
@@ -495,7 +496,8 @@ impl<O, T: ?Sized> OwningRef<O, T> {
495
496
}
496
497
}
497
498
498
- /// Erases the concrete base type of the owner with a trait object which implements `Send` and `Sync`.
499
+ /// Erases the concrete base type of the owner with a trait object
500
+ /// which implements `Send` and `Sync`.
499
501
///
500
502
/// This allows mixing of owned references with different owner base types.
501
503
pub fn erase_send_sync_owner < ' a > ( self ) -> OwningRef < O :: Erased , T >
@@ -507,7 +509,7 @@ impl<O, T: ?Sized> OwningRef<O, T> {
507
509
}
508
510
}
509
511
510
- // TODO : wrap_owner
512
+ // UNIMPLEMENTED : wrap_owner
511
513
512
514
// FIXME: Naming convention?
513
515
/// A getter for the underlying owner.
@@ -753,7 +755,7 @@ impl<O, T: ?Sized> OwningRefMut<O, T> {
753
755
}
754
756
}
755
757
756
- // TODO : wrap_owner
758
+ // UNIMPLEMENTED : wrap_owner
757
759
758
760
// FIXME: Naming convention?
759
761
/// A getter for the underlying owner.
0 commit comments