We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b16282e commit c7d0f2fCopy full SHA for c7d0f2f
c2rust-analyze/src/rewrite/expr/mir_op.rs
@@ -959,7 +959,7 @@ where
959
if from.option && from.own != to.own {
960
// Downgrade ownership before unwrapping the `Option` when possible. This can avoid
961
// moving/consuming the input. For example, if the `from` type is `Option<Box<T>>` and
962
- // `to` is `&mut T`, we start by calling `p.as_mut().as_deref()`, which gives
+ // `to` is `&mut T`, we start by calling `p.as_deref_mut()`, which produces
963
// `Option<&mut T>` without consuming `p`.
964
if !from.own.is_copy() {
965
match to.own {
0 commit comments