How should one handle chains of operations where some should be async and others sync? #1149
-
Hi, I'm using LINQ query with from x in collection syntax, and some times run into situations like this:
The async method calls obviously must be Aff, but what does that mean for the overall method signature? I guess if some of these return Aff instead of Eff, everything must be Aff? Am I going about this the wrong way? Previously I've just done these synchronously (only Eff, so no async/await) while using this library, but now I would like to learn how to do this async where possible. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 7 replies
-
That’s correct, but note that Effs are promoted to be Affs automatically when you combine them in a LINQ expression; so you don’t have to change your synchronous function signatures. |
Beta Was this translation helpful? Give feedback.
That’s correct, but note that Effs are promoted to be Affs automatically when you combine them in a LINQ expression; so you don’t have to change your synchronous function signatures.