1
1
// run-pass
2
+ // revisions: default mir-opt
3
+ //[mir-opt] compile-flags: -Zmir-opt-level=3
2
4
3
5
#![ feature( track_caller) ]
4
6
@@ -20,21 +22,21 @@ fn nested_tracked() -> &'static Location<'static> {
20
22
fn main ( ) {
21
23
let location = Location :: caller ( ) ;
22
24
assert_eq ! ( location. file( ) , file!( ) ) ;
23
- assert_eq ! ( location. line( ) , 21 ) ;
25
+ assert_eq ! ( location. line( ) , 23 ) ;
24
26
assert_eq ! ( location. column( ) , 20 ) ;
25
27
26
28
let tracked = tracked ( ) ;
27
29
assert_eq ! ( tracked. file( ) , file!( ) ) ;
28
- assert_eq ! ( tracked. line( ) , 26 ) ;
30
+ assert_eq ! ( tracked. line( ) , 28 ) ;
29
31
assert_eq ! ( tracked. column( ) , 19 ) ;
30
32
31
33
let nested = nested_intrinsic ( ) ;
32
34
assert_eq ! ( nested. file( ) , file!( ) ) ;
33
- assert_eq ! ( nested. line( ) , 13 ) ;
35
+ assert_eq ! ( nested. line( ) , 15 ) ;
34
36
assert_eq ! ( nested. column( ) , 5 ) ;
35
37
36
38
let contained = nested_tracked ( ) ;
37
39
assert_eq ! ( contained. file( ) , file!( ) ) ;
38
- assert_eq ! ( contained. line( ) , 17 ) ;
40
+ assert_eq ! ( contained. line( ) , 19 ) ;
39
41
assert_eq ! ( contained. column( ) , 5 ) ;
40
42
}
0 commit comments