diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 12:20:29 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 12:20:29 +0000 |
commit | 631cd5845e8de329d0e227aaa707d7ea228b8f8f (patch) | |
tree | a1b87c8f8cad01cf18f7c5f57a08f102771ed303 /tests/ui/pattern/bindings-after-at/borrowck-pat-at-and-box.stderr | |
parent | Adding debian version 1.69.0+dfsg1-1. (diff) | |
download | rustc-631cd5845e8de329d0e227aaa707d7ea228b8f8f.tar.xz rustc-631cd5845e8de329d0e227aaa707d7ea228b8f8f.zip |
Merging upstream version 1.70.0+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/ui/pattern/bindings-after-at/borrowck-pat-at-and-box.stderr')
-rw-r--r-- | tests/ui/pattern/bindings-after-at/borrowck-pat-at-and-box.stderr | 40 |
1 files changed, 16 insertions, 24 deletions
diff --git a/tests/ui/pattern/bindings-after-at/borrowck-pat-at-and-box.stderr b/tests/ui/pattern/bindings-after-at/borrowck-pat-at-and-box.stderr index 2c123b01e..9305facc4 100644 --- a/tests/ui/pattern/bindings-after-at/borrowck-pat-at-and-box.stderr +++ b/tests/ui/pattern/bindings-after-at/borrowck-pat-at-and-box.stderr @@ -2,72 +2,64 @@ error: cannot move out of value because it is borrowed --> $DIR/borrowck-pat-at-and-box.rs:31:9 | LL | let ref a @ box b = Box::new(NC); - | -----^^^^^^^- - | | | - | | value is moved into `b` here + | ^^^^^ - value is moved into `b` here + | | | value is borrowed by `a` here error: cannot borrow value as mutable because it is also borrowed as immutable --> $DIR/borrowck-pat-at-and-box.rs:34:9 | LL | let ref a @ box ref mut b = Box::new(nc()); - | -----^^^^^^^--------- - | | | - | | value is mutably borrowed by `b` here + | ^^^^^ --------- value is mutably borrowed by `b` here + | | | value is borrowed by `a` here error: cannot borrow value as mutable because it is also borrowed as immutable --> $DIR/borrowck-pat-at-and-box.rs:36:9 | LL | let ref a @ box ref mut b = Box::new(NC); - | -----^^^^^^^--------- - | | | - | | value is mutably borrowed by `b` here + | ^^^^^ --------- value is mutably borrowed by `b` here + | | | value is borrowed by `a` here error: cannot borrow value as mutable because it is also borrowed as immutable --> $DIR/borrowck-pat-at-and-box.rs:38:9 | LL | let ref a @ box ref mut b = Box::new(NC); - | -----^^^^^^^--------- - | | | - | | value is mutably borrowed by `b` here + | ^^^^^ --------- value is mutably borrowed by `b` here + | | | value is borrowed by `a` here error: cannot borrow value as mutable because it is also borrowed as immutable --> $DIR/borrowck-pat-at-and-box.rs:42:9 | LL | let ref a @ box ref mut b = Box::new(NC); - | -----^^^^^^^--------- - | | | - | | value is mutably borrowed by `b` here + | ^^^^^ --------- value is mutably borrowed by `b` here + | | | value is borrowed by `a` here error: cannot borrow value as immutable because it is also borrowed as mutable --> $DIR/borrowck-pat-at-and-box.rs:48:9 | LL | let ref mut a @ box ref b = Box::new(NC); - | ---------^^^^^^^----- - | | | - | | value is borrowed by `b` here + | ^^^^^^^^^ ----- value is borrowed by `b` here + | | | value is mutably borrowed by `a` here error: cannot borrow value as immutable because it is also borrowed as mutable --> $DIR/borrowck-pat-at-and-box.rs:62:9 | LL | ref mut a @ box ref b => { - | ---------^^^^^^^----- - | | | - | | value is borrowed by `b` here + | ^^^^^^^^^ ----- value is borrowed by `b` here + | | | value is mutably borrowed by `a` here error: cannot borrow value as immutable because it is also borrowed as mutable --> $DIR/borrowck-pat-at-and-box.rs:54:11 | LL | fn f5(ref mut a @ box ref b: Box<NC>) { - | ---------^^^^^^^----- - | | | - | | value is borrowed by `b` here + | ^^^^^^^^^ ----- value is borrowed by `b` here + | | | value is mutably borrowed by `a` here error[E0382]: borrow of moved value |