From 812d89c87d9346ac4b70426b67a8eb989a13c853 Mon Sep 17 00:00:00 2001 From: Charles Lew Date: Fri, 5 Apr 2019 12:06:29 +0800 Subject: [PATCH] Fix expectations on some ui test in nll compare mode. --- .../ui/borrowck/two-phase-nonrecv-autoref.ast.nll.stderr | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/test/ui/borrowck/two-phase-nonrecv-autoref.ast.nll.stderr b/src/test/ui/borrowck/two-phase-nonrecv-autoref.ast.nll.stderr index df74feb4f05..223de36f0df 100644 --- a/src/test/ui/borrowck/two-phase-nonrecv-autoref.ast.nll.stderr +++ b/src/test/ui/borrowck/two-phase-nonrecv-autoref.ast.nll.stderr @@ -11,13 +11,11 @@ error[E0382]: use of moved value: `f` --> $DIR/two-phase-nonrecv-autoref.rs:69:11 | LL | fn twice_ten_so i32>(f: Box) { - | - consider adding a `Copy` constraint to this type argument + | - move occurs because `f` has type `std::boxed::Box`, which does not implement the `Copy` trait LL | f(f(10)); | - ^ value used here after move | | | value moved here - | - = note: move occurs because `f` has type `std::boxed::Box`, which does not implement the `Copy` trait error[E0499]: cannot borrow `*f` as mutable more than once at a time --> $DIR/two-phase-nonrecv-autoref.rs:76:11 @@ -31,12 +29,12 @@ LL | f(f(10)); error[E0382]: use of moved value: `f` --> $DIR/two-phase-nonrecv-autoref.rs:85:11 | +LL | fn twice_ten_oo(f: Box i32>) { + | - move occurs because `f` has type `std::boxed::Box i32>`, which does not implement the `Copy` trait LL | f(f(10)); | - ^ value used here after move | | | value moved here - | - = note: move occurs because `f` has type `std::boxed::Box i32>`, which does not implement the `Copy` trait error[E0502]: cannot borrow `a` as immutable because it is also borrowed as mutable --> $DIR/two-phase-nonrecv-autoref.rs:125:27 -- 2.44.0