466: Fix for type aliases in `mod app`, UB in `spawn_at`, and `#[cfg]` in hardware tasks r=AfoHT a=korken89
Type aliases such as the following did not work in `0.6-alpha`:
```rust
use rtic::app;
#[app(device = lm3s6965, dispatchers = [SSI0])]
mod app {
type Test = u32;
#[task]
fn t1(_: t1::Context, _val: Test) {}
}
```
Plus that accessing associated constants of monotonic timers was not working as it should dues to the syntax and codegen transforming:
```rust
#[monotonic(binds = SysTick, default = true)]
type MyMono = DwtSystick<8_000_000>; // 8 MHz
```
into
```rust
mod MyMono {
// ...
}
```
causing the original `type MyMono` to not exist anymore.
This PR fixes this and adds test to check for this by doing the following expansion instead:
```rust
#[monotonic(binds = SysTick, default = true)]
type MyMono = DwtSystick<8_000_000>; // 8 MHz
```
into
```rust
type MyMono = DwtSystick<8_000_000>;
mod monotonics {
mod MyMono {
// ...
}
// And other monotonics go here as well
}
```
**Breaking change**
This causes a breaking change in accessing the `MyMono::now()` method which now exists under `monotonics::MyMono::now()`.
---
Moreover a UB issue was found and fixed in `spawn_at` and hardware tasks properly propagate `#[cfg]`s.
Closes#460Closes#462Closes#463
Co-authored-by: Emil Fresk <emil.fresk@gmail.com>
454: Add periodic GHA job to run cargo audit r=korken89 a=AfoHT
With the recent generic-array issue affecting heapless it seems wise to stay up to date with the latest advisories.
Co-authored-by: Henrik Tjäder <henrik@grepit.se>
Fmt fixes
Spawn_after did not work with parameters
Examples working again
Revert "GHA update"
This reverts commit e0a71d4859966a6c5cf2629d3cb27e88acada9c0.
Readd flags
Only add DWT based dep with __v7 flag