Skip to content

Commit 620a853

Browse files
committed
updates to compile-fail tests for changes to NLL.
1 parent 2d4df5b commit 620a853

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

src/test/compile-fail/borrowck/borrowck-issue-14498.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ fn indirect_write_to_imm_box() {
2727
let y: Box<_> = box &mut x;
2828
let p = &y;
2929
***p = 2; //[ast]~ ERROR cannot assign to data in a `&` reference
30-
//[mir]~^ ERROR cannot assign to data in a `&` reference
30+
//[mir]~^ ERROR cannot assign to `***p`
3131
drop(p);
3232
}
3333

src/test/compile-fail/borrowck/borrowck-overloaded-index-ref-index.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,6 @@ fn main() {
7070
};
7171
s[2] = 20;
7272
//[ast]~^ ERROR cannot assign to immutable indexed content
73-
//[mir]~^^ ERROR cannot assign to immutable item
73+
//[mir]~^^ ERROR cannot assign to data in a `&` reference
7474
drop(rs);
7575
}

src/test/compile-fail/unboxed-closures-mutated-upvar-from-fn-closure.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,6 @@ fn main() {
2323
call(|| {
2424
counter += 1;
2525
//[ast]~^ ERROR cannot assign to data in a captured outer variable in an `Fn` closure
26-
//[mir]~^^ ERROR cannot assign to immutable item `counter`
26+
//[mir]~^^ ERROR cannot assign to `counter`
2727
});
2828
}

0 commit comments

Comments
 (0)