diff options
| author | Carol (Nichols || Goulding) <carol.nichols@gmail.com> | 2017-10-25 11:29:14 -0400 |
|---|---|---|
| committer | Carol (Nichols || Goulding) <carol.nichols@gmail.com> | 2017-10-25 11:29:52 -0400 |
| commit | 0e46cf4db4fdb8b2fd8cc0dde2425a16d478d8ed (patch) | |
| tree | a06736d547d86372ae9aa12ddab4e4915d580530 /src/test/compile-fail/mut-pattern-internal-mutability.rs | |
| parent | b2478052f88db8c8526ee2dc4a382da91eefc76c (diff) | |
| download | rust-0e46cf4db4fdb8b2fd8cc0dde2425a16d478d8ed.tar.gz rust-0e46cf4db4fdb8b2fd8cc0dde2425a16d478d8ed.zip | |
Reword to avoid using either re-assignment or reassignment in errors
Diffstat (limited to 'src/test/compile-fail/mut-pattern-internal-mutability.rs')
| -rw-r--r-- | src/test/compile-fail/mut-pattern-internal-mutability.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/test/compile-fail/mut-pattern-internal-mutability.rs b/src/test/compile-fail/mut-pattern-internal-mutability.rs index 3a84bd6565e..1c7bc9d7303 100644 --- a/src/test/compile-fail/mut-pattern-internal-mutability.rs +++ b/src/test/compile-fail/mut-pattern-internal-mutability.rs @@ -15,9 +15,9 @@ fn main() { let foo = &mut 1; let &mut x = foo; - x += 1; //[ast]~ ERROR re-assignment of immutable variable - //[mir]~^ ERROR re-assignment of immutable variable `x` (Ast) - //[mir]~| ERROR re-assignment of immutable variable `x` (Mir) + x += 1; //[ast]~ ERROR cannot assign twice to immutable variable + //[mir]~^ ERROR cannot assign twice to immutable variable `x` (Ast) + //[mir]~| ERROR cannot assign twice to immutable variable `x` (Mir) // explicitly mut-ify internals let &mut mut x = foo; |
