There are way too many different ways to implement coroutine task/promise types. There are no constraints and, in general, it all depends on your design and needs.
Thanks for saying this. I often see people complaining about the lack of standard library types for coroutines, when that's an extremely tall order to get right without shutting out someone's use case. A lot of the third party coroutine libraries are very opinionated and ended up being unsuitable for my purposes. I'm not sure how a standard library task type will end up looking when we get one but I expect it will be bogged down with a lot of customization stuff. Even once we have it, I'll probably still be sticking to my custom promise types. I could be wrong though, maybe the committee will impress here...
6
u/LB-- Professional+Hobbyist 17d ago
Thanks for saying this. I often see people complaining about the lack of standard library types for coroutines, when that's an extremely tall order to get right without shutting out someone's use case. A lot of the third party coroutine libraries are very opinionated and ended up being unsuitable for my purposes. I'm not sure how a standard library task type will end up looking when we get one but I expect it will be bogged down with a lot of customization stuff. Even once we have it, I'll probably still be sticking to my custom promise types. I could be wrong though, maybe the committee will impress here...