Rollup merge of #48355 - mikhail-m1:subslice_pattern_array_drop2, r=nikomatsakis

Fixes #47311.
r? @nrc
This commit is contained in:
Manish Goregaokar 2018-02-28 15:09:22 -08:00
commit f59ab8e96a
No known key found for this signature in database
GPG key ID: 3BBF4D3E2EF79F98
3 changed files with 213 additions and 11 deletions

View file

@ -57,3 +57,28 @@ fn main() {
// nop;
// _0 = ();
// END rustc.move_out_by_subslice.UniformArrayMoveOut.after.mir
// START rustc.move_out_by_subslice.RestoreSubsliceArrayMoveOut.before.mir
// StorageLive(_6);
// StorageLive(_7);
// _7 = move _1[0 of 2];
// StorageLive(_8);
// _8 = move _1[1 of 2];
// _6 = [move _7, move _8];
// StorageDead(_7);
// StorageDead(_8);
// _0 = ();
// END rustc.move_out_by_subslice.RestoreSubsliceArrayMoveOut.before.mir
// START rustc.move_out_by_subslice.RestoreSubsliceArrayMoveOut.after.mir
// StorageLive(_6);
// nop;
// nop;
// nop;
// nop;
// _6 = move _1[0:];
// nop;
// nop;
// nop;
// _0 = ();
// END rustc.move_out_by_subslice.RestoreSubsliceArrayMoveOut.after.mir