add more docs around lifetime downcasting
This commit is contained in:
1 parent
5f9e5f607b
commit
4bc2f4a713
10 files changed
+46
-23
No files matched your search
@@ -92,11 +92,15 @@ impl AnyStorage for UnsyncStorage {
|
||||
type Ref<'a, R: ?Sized + 'static> = GenerationalRef<Ref<'a, R>>;
|
||||
type Mut<'a, W: ?Sized + 'static> = GenerationalRefMut<RefMut<'a, W>>;
|
||||
|
||||
fn downcast_ref<'a: 'b, 'b, T: ?Sized + 'static>(ref_: Self::Ref<'a, T>) -> Self::Ref<'b, T> {
|
||||
fn downcast_lifetime_ref<'a: 'b, 'b, T: ?Sized + 'static>(
|
||||
ref_: Self::Ref<'a, T>,
|
||||
) -> Self::Ref<'b, T> {
|
||||
ref_
|
||||
}
|
||||
|
||||
fn downcast_mut<'a: 'b, 'b, T: ?Sized + 'static>(mut_: Self::Mut<'a, T>) -> Self::Mut<'b, T> {
|
||||
fn downcast_lifetime_mut<'a: 'b, 'b, T: ?Sized + 'static>(
|
||||
mut_: Self::Mut<'a, T>,
|
||||
) -> Self::Mut<'b, T> {
|
||||
mut_
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user