diff options
Diffstat (limited to 'embassy-executor/src/lib.rs')
| -rw-r--r-- | embassy-executor/src/lib.rs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/embassy-executor/src/lib.rs b/embassy-executor/src/lib.rs index e26e8ee7d..e174a0594 100644 --- a/embassy-executor/src/lib.rs +++ b/embassy-executor/src/lib.rs | |||
| @@ -233,6 +233,10 @@ pub mod _export { | |||
| 233 | #[doc(hidden)] | 233 | #[doc(hidden)] |
| 234 | #[cfg(feature = "nightly")] | 234 | #[cfg(feature = "nightly")] |
| 235 | pub mod _export { | 235 | pub mod _export { |
| 236 | #[diagnostic::on_unimplemented( | ||
| 237 | message = "task futures must resolve to `()` or `!`", | ||
| 238 | note = "use `async fn` or change the return type to `impl Future<Output = ()>`" | ||
| 239 | )] | ||
| 236 | pub trait TaskReturnValue {} | 240 | pub trait TaskReturnValue {} |
| 237 | impl TaskReturnValue for () {} | 241 | impl TaskReturnValue for () {} |
| 238 | impl TaskReturnValue for Never {} | 242 | impl TaskReturnValue for Never {} |
