diff options
| author | Jorge Aparicio <jorge@japaric.io> | 2019-04-21 20:13:15 +0200 |
|---|---|---|
| committer | Jorge Aparicio <jorge@japaric.io> | 2019-05-01 20:49:25 +0200 |
| commit | d2fb62f729de3ad24132b69298e17193ac334df4 (patch) | |
| tree | 9c1e56f6056b2cef796a33a9607ddb039e70a7c6 /tests/cpass/late-not-send.rs | |
| parent | 1b4b006bab7ee05e403a4fc48ae751d037f95b1a (diff) | |
update compile-pass tests
Diffstat (limited to 'tests/cpass/late-not-send.rs')
| -rw-r--r-- | tests/cpass/late-not-send.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/cpass/late-not-send.rs b/tests/cpass/late-not-send.rs index 5b278ab..0f69096 100644 --- a/tests/cpass/late-not-send.rs +++ b/tests/cpass/late-not-send.rs @@ -1,3 +1,5 @@ +#![deny(unsafe_code)] +#![deny(warnings)] #![no_main] #![no_std] @@ -7,20 +9,18 @@ extern crate rtfm; use core::marker::PhantomData; -use rtfm::app; - pub struct NotSend { _0: PhantomData<*const ()>, } -#[app(device = lm3s6965)] +#[rtfm::app(device = lm3s6965)] const APP: () = { static mut X: NotSend = (); static mut Y: Option<NotSend> = None; #[init(resources = [Y])] - fn init() -> init::LateResources { - *resources.Y = Some(NotSend { _0: PhantomData }); + fn init(c: init::Context) -> init::LateResources { + *c.resources.Y = Some(NotSend { _0: PhantomData }); init::LateResources { X: NotSend { _0: PhantomData }, @@ -28,7 +28,7 @@ const APP: () = { } #[idle(resources = [X, Y])] - fn idle() -> ! { + fn idle(_: idle::Context) -> ! { loop {} } }; |
