summaryrefslogtreecommitdiffstats
path: root/tests/mir-opt/issue_91633.bar.built.after.mir
blob: 92f52e138a59f7ce82db8139b8eac267f7669be1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
// MIR for `bar` after built

fn bar(_1: Box<[T]>) -> () {
    debug it => _1;
    let mut _0: ();
    let mut _2: &<[T] as std::ops::Index<usize>>::Output;
    let mut _3: &[T];
    scope 1 {
    }

    bb0: {
        StorageLive(_2);
        StorageLive(_3);
        _3 = &(*_1);
        _2 = <[T] as Index<usize>>::index(move _3, const 0_usize) -> [return: bb1, unwind: bb3];
    }

    bb1: {
        StorageDead(_3);
        PlaceMention((*_2));
        StorageDead(_2);
        _0 = const ();
        drop(_1) -> [return: bb2, unwind: bb4];
    }

    bb2: {
        return;
    }

    bb3 (cleanup): {
        drop(_1) -> [return: bb4, unwind terminate];
    }

    bb4 (cleanup): {
        resume;
    }
}