rollup merge of #19520: csouth3/derefmut-unsized
Right now, `DerefMut` is not `for Sized?`, so you can't impl `DerefMut<T> for Foo` where `Foo` is unsized. However, there is no reason that it can't be `for Sized?`, so this pull request fixes the issue. Closes #19493.
This commit is contained in:
commit
c7d545e2f7
@ -787,7 +787,7 @@ impl<'a, Sized? T> Deref<T> for &'a mut T {
|
||||
/// }
|
||||
/// ```
|
||||
#[lang="deref_mut"]
|
||||
pub trait DerefMut<Sized? Result>: Deref<Result> {
|
||||
pub trait DerefMut<Sized? Result> for Sized? : Deref<Result> {
|
||||
/// The method called to mutably dereference a value
|
||||
fn deref_mut<'a>(&'a mut self) -> &'a mut Result;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user