diff options
| author | Jorge Aparicio <jorge@japaric.io> | 2021-08-31 19:50:50 +0200 |
|---|---|---|
| committer | Jorge Aparicio <jorge@japaric.io> | 2021-08-31 19:50:50 +0200 |
| commit | 1a49d67490e3c1b9cb640d459890f4c880a52096 (patch) | |
| tree | b8ccee97b005fb8670ce01d847bb5bf67de730cb /ui | |
| parent | 3ef650832abef24f76c402ede64d1248cf0d0772 (diff) | |
validate unused dispatchers
closes #521
Diffstat (limited to 'ui')
| -rw-r--r-- | ui/unknown-interrupt.rs | 15 | ||||
| -rw-r--r-- | ui/unknown-interrupt.stderr | 5 |
2 files changed, 20 insertions, 0 deletions
diff --git a/ui/unknown-interrupt.rs b/ui/unknown-interrupt.rs new file mode 100644 index 0000000..f2bc629 --- /dev/null +++ b/ui/unknown-interrupt.rs @@ -0,0 +1,15 @@ +#![no_main] + +#[rtic::app(device = lm3s6965, dispatchers = [UnknownInterrupt])] +mod app { + #[shared] + struct Shared {} + + #[local] + struct Local {} + + #[init] + fn init(cx: init::Context) -> (Shared, Local, init::Monotonics) { + (Shared {}, Local {}, init::Monotonics()) + } +} diff --git a/ui/unknown-interrupt.stderr b/ui/unknown-interrupt.stderr new file mode 100644 index 0000000..d223102 --- /dev/null +++ b/ui/unknown-interrupt.stderr @@ -0,0 +1,5 @@ +error[E0599]: no variant or associated item named `UnknownInterrupt` found for enum `Interrupt` in the current scope + --> examples/unknown-interrupt.rs:3:47 + | +3 | #[rtic::app(device = lm3s6965, dispatchers = [UnknownInterrupt])] + | ^^^^^^^^^^^^^^^^ variant or associated item not found in `Interrupt`
\ No newline at end of file |
