-
Notifications
You must be signed in to change notification settings - Fork 13k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Do not ICE on missing access place description during mutability erro…
…r reporting
- Loading branch information
Showing
3 changed files
with
27 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
// edition:2018 | ||
#![feature(async_await)] | ||
|
||
fn main() { | ||
} | ||
|
||
async fn response(data: Vec<u8>) { | ||
data.reverse(); //~ ERROR E0596 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
error[E0596]: cannot borrow temporary place as mutable, as it is not declared as mutable | ||
--> $DIR/issue-61187.rs:8:5 | ||
| | ||
LL | async fn response(data: Vec<u8>) { | ||
| ---- help: consider changing this to be mutable: `mut data` | ||
LL | data.reverse(); | ||
| ^^^^ cannot borrow as mutable | ||
|
||
error: aborting due to previous error | ||
|
||
For more information about this error, try `rustc --explain E0596`. |