You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
407: async: switch to async-fn-in-traits, release v0.2.0-alpha.0 r=eldruin a=Dirbaio
Latest Rust nightlies have somewhat usable async-fn-in-trait support already! 🎉
embassy-nrf updated here embassy-rs/embassy#974
Paprecuts encountered:
- there's this annoying error [playground](https://play.rust-lang.org/?version=nightly&mode=debug&edition=2021&gist=f04fca1f2a3d643c323fb49c05bd3ed3), workaround is to use the concrete type instead of `Self::Error`. This is a limitation of all `async fn`s, not just in traits, but it hits especially hard within traits, so I dunno if there's plans to improve it.
> `async fn` return type cannot contain a projection or `Self` that references lifetimes from a parent scope
- The SpiDevice trait ICEs, issue filed rust-lang/rust#102310
- default methods don't work, but there's a PR already rust-lang/rust#102308
Due to the last 2 I've left `SpiDevice` alone for now.
Co-authored-by: Dario Nieuwenhuis <[email protected]>
Copy file name to clipboardExpand all lines: embedded-hal-async/CHANGELOG.md
+5-1
Original file line number
Diff line number
Diff line change
@@ -7,6 +7,9 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
7
7
8
8
## [Unreleased]
9
9
10
+
## [v0.2.0-alpha.0] - 2022-11-23
11
+
12
+
- Switch all traits to use [`async_fn_in_trait`](https://blog.rust-lang.org/inside-rust/2022/11/17/async-fn-in-trait-nightly.html) (AFIT). Requires `nightly-2022-11-22` or newer.
10
13
11
14
## [v0.1.0-alpha.3] - 2022-10-26
12
15
@@ -34,7 +37,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
0 commit comments