Stray thought that came up in conversations with @Argorak the other day: what if async closures didn't need the `async` keyword?
The trait would still be AsyncFn (or similar), and that'd be the marker for whether it's an async closure. Unlike `move`, `async` is never optional.
-
-
Though for the second one: if surroundings change, and an async closure becomes sync, I'd argue in many cases that's a feature -- that's why type inference is so cool! (e.g. switching form Stream -> Iterator). Should def not come at the expense of good diagnostics; big agree!
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.