Skip to content

Conversation

matthewjasper
Copy link
Contributor

Closes #45694
compile-fail test E0508 now gives

error[E0508]: cannot move out of type `[NonCopy; 1]`, a non-copy array (Ast)
  --> .\src\test\compile-fail\E0508.rs:18:18
   |
18 |     let _value = array[0];  //[ast]~ ERROR E0508
   |                  ^^^^^^^^
   |                  |
   |                  cannot move out of here
   |                  help: consider using a reference instead: `&array[0]`

error[E0508]: cannot move out of type `[NonCopy; 1]`, a non-copy array (Mir)
  --> .\src\test\compile-fail\E0508.rs:18:18
   |
18 |     let _value = array[0];  //[ast]~ ERROR E0508
   |                  ^^^^^^^^ cannot move out of here

error: aborting due to 2 previous errors

@kennytm kennytm added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Nov 14, 2017
@kennytm
Copy link
Member

kennytm commented Nov 14, 2017

r? @arielb1

@arielb1
Copy link
Contributor

arielb1 commented Nov 14, 2017

@bors r+ rollup

@bors
Copy link
Collaborator

bors commented Nov 14, 2017

📌 Commit a6824f1 has been approved by arielb1

@kennytm kennytm added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Nov 14, 2017
GuillaumeGomez added a commit to GuillaumeGomez/rust that referenced this pull request Nov 14, 2017
…rielb1

MIR-borrowck: don't ICE for cannot move from array error

Closes rust-lang#45694
compile-fail test E0508 now gives
```text
error[E0508]: cannot move out of type `[NonCopy; 1]`, a non-copy array (Ast)
  --> .\src\test\compile-fail\E0508.rs:18:18
   |
18 |     let _value = array[0];  //[ast]~ ERROR E0508
   |                  ^^^^^^^^
   |                  |
   |                  cannot move out of here
   |                  help: consider using a reference instead: `&array[0]`

error[E0508]: cannot move out of type `[NonCopy; 1]`, a non-copy array (Mir)
  --> .\src\test\compile-fail\E0508.rs:18:18
   |
18 |     let _value = array[0];  //[ast]~ ERROR E0508
   |                  ^^^^^^^^ cannot move out of here

error: aborting due to 2 previous errors
```
bors added a commit that referenced this pull request Nov 14, 2017
Rollup of 7 pull requests

- Successful merges: #45815, #45941, #45950, #45951, #45961, #45967, #45970
- Failed merges:
GuillaumeGomez added a commit to GuillaumeGomez/rust that referenced this pull request Nov 14, 2017
…rielb1

MIR-borrowck: don't ICE for cannot move from array error

Closes rust-lang#45694
compile-fail test E0508 now gives
```text
error[E0508]: cannot move out of type `[NonCopy; 1]`, a non-copy array (Ast)
  --> .\src\test\compile-fail\E0508.rs:18:18
   |
18 |     let _value = array[0];  //[ast]~ ERROR E0508
   |                  ^^^^^^^^
   |                  |
   |                  cannot move out of here
   |                  help: consider using a reference instead: `&array[0]`

error[E0508]: cannot move out of type `[NonCopy; 1]`, a non-copy array (Mir)
  --> .\src\test\compile-fail\E0508.rs:18:18
   |
18 |     let _value = array[0];  //[ast]~ ERROR E0508
   |                  ^^^^^^^^ cannot move out of here

error: aborting due to 2 previous errors
```
bors added a commit that referenced this pull request Nov 14, 2017
Rollup of 7 pull requests

- Successful merges: #45815, #45941, #45950, #45961, #45967, #45970, #45977
- Failed merges:
@bors bors merged commit a6824f1 into rust-lang:master Nov 14, 2017
@matthewjasper matthewjasper deleted the array-move-types branch November 27, 2017 19:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants