diff options
author | 2022-01-21 00:49:59 +0000 | |
---|---|---|
committer | 2022-01-21 00:49:59 +0000 | |
commit | 27434e0ce0b67abdd06c1a1b9a7b5ea9121d039e (patch) | |
tree | 72338d7c4175db295828b825678e2349e13d4ca0 /cortex-m-rt/tests/compile-fail/non-static-resource.rs | |
parent | 657af97d66b7157d6a6e5704d86dd59b398e7108 (diff) | |
download | cortex-m-27434e0ce0b67abdd06c1a1b9a7b5ea9121d039e.tar.gz cortex-m-27434e0ce0b67abdd06c1a1b9a7b5ea9121d039e.tar.zst cortex-m-27434e0ce0b67abdd06c1a1b9a7b5ea9121d039e.zip |
Fix break in compilefail tests on 1.58
Diffstat (limited to 'cortex-m-rt/tests/compile-fail/non-static-resource.rs')
-rw-r--r-- | cortex-m-rt/tests/compile-fail/non-static-resource.rs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/cortex-m-rt/tests/compile-fail/non-static-resource.rs b/cortex-m-rt/tests/compile-fail/non-static-resource.rs index 970bbae..a603728 100644 --- a/cortex-m-rt/tests/compile-fail/non-static-resource.rs +++ b/cortex-m-rt/tests/compile-fail/non-static-resource.rs @@ -20,14 +20,16 @@ enum interrupt { fn SVCall() { static mut STAT: u8 = 0; - let _stat: &'static mut u8 = STAT; //~ ERROR explicit lifetime required in the type of `STAT` + let _stat: &'static mut u8 = STAT; + //~^ ERROR lifetime of reference outlives lifetime of borrowed content } #[interrupt] fn UART0() { static mut STAT: u8 = 0; - let _stat: &'static mut u8 = STAT; //~ ERROR explicit lifetime required in the type of `STAT` + let _stat: &'static mut u8 = STAT; + //~^ ERROR lifetime of reference outlives lifetime of borrowed content } #[entry] |