diff options
Diffstat (limited to '')
-rw-r--r-- | ui/single/exception-invalid.rs | 4 | ||||
-rw-r--r-- | ui/single/exception-systick-used.rs | 4 | ||||
-rw-r--r-- | ui/single/extern-interrupt-not-enough.rs | 4 | ||||
-rw-r--r-- | ui/single/extern-interrupt-used.rs | 4 | ||||
-rw-r--r-- | ui/single/locals-cfg.rs | 5 | ||||
-rw-r--r-- | ui/single/locals-cfg.stderr | 30 | ||||
-rw-r--r-- | ui/single/resources-cfg.rs | 6 | ||||
-rw-r--r-- | ui/single/resources-cfg.stderr | 66 | ||||
-rw-r--r-- | ui/single/task-priority-too-high.rs | 6 | ||||
-rw-r--r-- | ui/single/task-priority-too-high.stderr | 16 |
10 files changed, 75 insertions, 70 deletions
diff --git a/ui/single/exception-invalid.rs b/ui/single/exception-invalid.rs index efe06212..04d9bc75 100644 --- a/ui/single/exception-invalid.rs +++ b/ui/single/exception-invalid.rs @@ -1,7 +1,7 @@ #![no_main] #[rtic::app(device = lm3s6965)] -const APP: () = { +mod app { #[task(binds = NonMaskableInt)] fn nmi(_: nmi::Context) {} -}; +} diff --git a/ui/single/exception-systick-used.rs b/ui/single/exception-systick-used.rs index 36ed1744..1c30b700 100644 --- a/ui/single/exception-systick-used.rs +++ b/ui/single/exception-systick-used.rs @@ -1,10 +1,10 @@ #![no_main] #[rtic::app(device = lm3s6965)] -const APP: () = { +mod app { #[task(binds = SysTick)] fn sys_tick(_: sys_tick::Context) {} #[task(schedule = [foo])] fn foo(_: foo::Context) {} -}; +} diff --git a/ui/single/extern-interrupt-not-enough.rs b/ui/single/extern-interrupt-not-enough.rs index 53820b52..f2624036 100644 --- a/ui/single/extern-interrupt-not-enough.rs +++ b/ui/single/extern-interrupt-not-enough.rs @@ -1,7 +1,7 @@ #![no_main] #[rtic::app(device = lm3s6965)] -const APP: () = { +mod app { #[task] fn a(_: a::Context) {} -}; +} diff --git a/ui/single/extern-interrupt-used.rs b/ui/single/extern-interrupt-used.rs index 82f1bdd2..89c23784 100644 --- a/ui/single/extern-interrupt-used.rs +++ b/ui/single/extern-interrupt-used.rs @@ -1,11 +1,11 @@ #![no_main] #[rtic::app(device = lm3s6965)] -const APP: () = { +mod app { #[task(binds = UART0)] fn a(_: a::Context) {} extern "C" { fn UART0(); } -}; +} diff --git a/ui/single/locals-cfg.rs b/ui/single/locals-cfg.rs index cd8677a9..45a7a911 100644 --- a/ui/single/locals-cfg.rs +++ b/ui/single/locals-cfg.rs @@ -1,7 +1,8 @@ #![no_main] +use panic_halt as _; #[rtic::app(device = lm3s6965)] -const APP: () = { +mod app { #[init] fn init(_: init::Context) -> init::LateResources { #[cfg(never)] @@ -49,4 +50,4 @@ const APP: () = { extern "C" { fn UART1(); } -}; +} diff --git a/ui/single/locals-cfg.stderr b/ui/single/locals-cfg.stderr index dc104a69..63953fc9 100644 --- a/ui/single/locals-cfg.stderr +++ b/ui/single/locals-cfg.stderr @@ -1,37 +1,41 @@ error[E0425]: cannot find value `FOO` in this scope - --> $DIR/locals-cfg.rs:10:9 + --> $DIR/locals-cfg.rs:11:9 | -10 | FOO; +11 | FOO; | ^^^ not found in this scope error[E0425]: cannot find value `FOO` in this scope - --> $DIR/locals-cfg.rs:20:9 + --> $DIR/locals-cfg.rs:21:9 | -20 | FOO; +21 | FOO; | ^^^ not found in this scope error[E0425]: cannot find value `FOO` in this scope - --> $DIR/locals-cfg.rs:30:9 + --> $DIR/locals-cfg.rs:31:9 | -30 | FOO; +31 | FOO; | ^^^ not found in this scope error[E0425]: cannot find value `FOO` in this scope - --> $DIR/locals-cfg.rs:38:9 + --> $DIR/locals-cfg.rs:39:9 | -38 | FOO; +39 | FOO; | ^^^ not found in this scope error[E0425]: cannot find value `FOO` in this scope - --> $DIR/locals-cfg.rs:46:9 + --> $DIR/locals-cfg.rs:47:9 | -46 | FOO; +47 | FOO; | ^^^ not found in this scope -error: duplicate lang item in crate `panic_halt`: `panic_impl`. +error: duplicate lang item in crate `panic_halt` (which `$CRATE` depends on): `panic_impl`. | - = note: first defined in crate `std`. + = note: the lang item is first defined in crate `std` (which `$CRATE` depends on) + = note: first definition in `std` loaded from /usr/share/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libstd-cf0f33af3a901778.rlib + = note: second definition in `panic_halt` loaded from $DIR/target/tests/target/x86_64-unknown-linux-gnu/debug/deps/libpanic_halt-ba6f0ab3439cbc7e.rmeta error: duplicate lang item in crate `panic_semihosting`: `panic_impl`. | - = note: first defined in crate `panic_halt`. + = note: the lang item is first defined in crate `panic_halt` (which `$CRATE` depends on) + = note: first definition in `panic_halt` loaded from $DIR/target/tests/target/x86_64-unknown-linux-gnu/debug/deps/libpanic_halt-ba6f0ab3439cbc7e.rmeta + = note: second definition in `panic_semihosting` loaded from $DIR/target/tests/target/x86_64-unknown-linux-gnu/debug/deps/libpanic_semihosting-805015f4a2d05965.rmeta diff --git a/ui/single/resources-cfg.rs b/ui/single/resources-cfg.rs index bcb71208..2ba65a04 100644 --- a/ui/single/resources-cfg.rs +++ b/ui/single/resources-cfg.rs @@ -1,7 +1,9 @@ #![no_main] +use panic_halt as _; #[rtic::app(device = lm3s6965)] -const APP: () = { +mod app { + #[resources] struct Resources { #[cfg(never)] #[init(0)] @@ -74,4 +76,4 @@ const APP: () = { c.resources.s2; c.resources.o5; } -}; +} diff --git a/ui/single/resources-cfg.stderr b/ui/single/resources-cfg.stderr index 68063693..17f08d81 100644 --- a/ui/single/resources-cfg.stderr +++ b/ui/single/resources-cfg.stderr @@ -1,119 +1,125 @@ +error: duplicate lang item in crate `panic_halt` (which `$CRATE` depends on): `panic_impl`. + | + = note: the lang item is first defined in crate `std` (which `$CRATE` depends on) + = note: first definition in `std` loaded from /usr/share/rust/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libstd-cf0f33af3a901778.rlib + = note: second definition in `panic_halt` loaded from $DIR/target/tests/target/x86_64-unknown-linux-gnu/debug/deps/libpanic_halt-ba6f0ab3439cbc7e.rmeta + error[E0609]: no field `o1` on type `initResources<'_>` - --> $DIR/resources-cfg.rs:45:21 + --> $DIR/resources-cfg.rs:47:21 | -45 | c.resources.o1; +47 | c.resources.o1; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `o4` on type `initResources<'_>` - --> $DIR/resources-cfg.rs:46:21 + --> $DIR/resources-cfg.rs:48:21 | -46 | c.resources.o4; +48 | c.resources.o4; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `o5` on type `initResources<'_>` - --> $DIR/resources-cfg.rs:47:21 + --> $DIR/resources-cfg.rs:49:21 | -47 | c.resources.o5; +49 | c.resources.o5; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `o6` on type `initResources<'_>` - --> $DIR/resources-cfg.rs:48:21 + --> $DIR/resources-cfg.rs:50:21 | -48 | c.resources.o6; +50 | c.resources.o6; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `s3` on type `initResources<'_>` - --> $DIR/resources-cfg.rs:49:21 + --> $DIR/resources-cfg.rs:51:21 | -49 | c.resources.s3; +51 | c.resources.s3; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `o2` on type `idleResources<'_>` - --> $DIR/resources-cfg.rs:56:21 + --> $DIR/resources-cfg.rs:58:21 | -56 | c.resources.o2; +58 | c.resources.o2; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `o4` on type `idleResources<'_>` - --> $DIR/resources-cfg.rs:57:21 + --> $DIR/resources-cfg.rs:59:21 | -57 | c.resources.o4; +59 | c.resources.o4; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `s1` on type `idleResources<'_>` - --> $DIR/resources-cfg.rs:58:21 + --> $DIR/resources-cfg.rs:60:21 | -58 | c.resources.s1; +60 | c.resources.s1; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `s3` on type `idleResources<'_>` - --> $DIR/resources-cfg.rs:59:21 + --> $DIR/resources-cfg.rs:61:21 | -59 | c.resources.s3; +61 | c.resources.s3; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `o3` on type `uart0Resources<'_>` - --> $DIR/resources-cfg.rs:66:21 + --> $DIR/resources-cfg.rs:68:21 | -66 | c.resources.o3; +68 | c.resources.o3; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `s1` on type `uart0Resources<'_>` - --> $DIR/resources-cfg.rs:67:21 + --> $DIR/resources-cfg.rs:69:21 | -67 | c.resources.s1; +69 | c.resources.s1; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `s2` on type `uart0Resources<'_>` - --> $DIR/resources-cfg.rs:68:21 + --> $DIR/resources-cfg.rs:70:21 | -68 | c.resources.s2; +70 | c.resources.s2; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `s3` on type `uart0Resources<'_>` - --> $DIR/resources-cfg.rs:69:21 + --> $DIR/resources-cfg.rs:71:21 | -69 | c.resources.s3; +71 | c.resources.s3; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `s2` on type `uart1Resources<'_>` - --> $DIR/resources-cfg.rs:74:21 + --> $DIR/resources-cfg.rs:76:21 | -74 | c.resources.s2; +76 | c.resources.s2; | ^^ unknown field | = note: available fields are: `__marker__` error[E0609]: no field `o5` on type `uart1Resources<'_>` - --> $DIR/resources-cfg.rs:75:21 + --> $DIR/resources-cfg.rs:77:21 | -75 | c.resources.o5; +77 | c.resources.o5; | ^^ unknown field | = note: available fields are: `__marker__` diff --git a/ui/single/task-priority-too-high.rs b/ui/single/task-priority-too-high.rs index 62e531d8..caa7b8ee 100644 --- a/ui/single/task-priority-too-high.rs +++ b/ui/single/task-priority-too-high.rs @@ -1,9 +1,7 @@ #![no_main] -use rtic::app; - #[rtic::app(device = lm3s6965)] -const APP: () = { +mod app { #[init] fn init(_: init::Context) -> init::LateResources { init::LateResources {} @@ -37,4 +35,4 @@ const APP: () = { // this value is too high! #[task(binds = I2C0, priority = 9)] fn i2c0(_: i2c0::Context) {} -}; +} diff --git a/ui/single/task-priority-too-high.stderr b/ui/single/task-priority-too-high.stderr index eae6074d..e84ddd3c 100644 --- a/ui/single/task-priority-too-high.stderr +++ b/ui/single/task-priority-too-high.stderr @@ -1,13 +1,7 @@ -warning: unused import: `rtic::app` - --> $DIR/task-priority-too-high.rs:3:5 - | -3 | use rtic::app; - | ^^^^^^^^^ - | - = note: #[warn(unused_imports)] on by default - error[E0080]: evaluation of constant value failed - --> $DIR/task-priority-too-high.rs:5:1 + --> $DIR/task-priority-too-high.rs:3:1 + | +3 | #[rtic::app(device = lm3s6965)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempt to compute `8_usize - 9_usize` which would overflow | -5 | #[rtic::app(device = lm3s6965)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempt to subtract with overflow + = note: this error originates in an attribute macro (in Nightly builds, run with -Z macro-backtrace for more info) |