Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

could this be easily done without using boost?


Author here. The library itself (stackless_coroutine.hpp) has no dependencies other than C++14, and you can easily use it in any C++14 project with any async library.

For writing an interesting example, I wanted to do an example of how the library can simplify async network code. A widely used async C++ library is Boost.Asio, so that is what I used for the example.

TLDR: The library itself has no dependency on Boost. Boost.Asio was just used for the example.


It's a good example. I'm really liking asio so far. However, I've been using the standalone version[1]. Maybe you could do the same with your library?

[1]: http://think-async.com/Asio/AsioStandalone


I am planning on overhauling the example to use that latest version of Asio standalone that is tracking the C++ Networking TS. That way it will be a simple matter of people changing asio to std::experimental::net on a compiler that implements the Networking TS.


Here's one I wrote with stacks:

    https://github.com/jaroslov/coro


Would it work the same using c++11 async stuff? That would make my day :)


I'm very looking forward to playing with this library. Thanks for making it!




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: