Want to take your software engineering career to the next level? Join the mailing list for career tips & advice Click here

coroutine

A asymmetric coroutine library for C.

Subscribe to updates I use coroutine


Statistics on coroutine

Number of watchers on Github 971
Number of open issues 2
Average time to close an issue 2 days
Main language C
Average time to merge a PR about 4 hours
Open pull requests 0+
Closed pull requests 1+
Last commit about 4 years ago
Repo Created about 8 years ago
Repo Last Updated over 2 years ago
Size 9 KB
Organization / Authorcloudwu
Contributors1
Page Updated
Do you use coroutine? Leave a review!
View open issues (2)
View coroutine activity
View on github
Fresh, new opensource launches 🚀🚀🚀
Software engineers: It's time to get promoted. Starting NOW! Subscribe to my mailing list and I will equip you with tools, tips and actionable advice to grow in your career.
Evaluating coroutine for your project? Score Explanation
Commits Score (?)
Issues & PR Score (?)

It's an asymmetric coroutine library (like lua).

You can use coroutine_open to open a schedule first, and then create coroutine in that schedule.

You should call coroutine_resume in the thread that you call coroutine_open, and you can't call it in a coroutine in the same schedule.

Coroutines in the same schedule share the stack , so you can create many coroutines without worry about memory.

But switching context will copy the stack the coroutine used.

Read source for detail.

Chinese blog : http://blog.codingnow.com/2012/07/c_coroutine.html

coroutine questions on Stackoverflow (View All Questions)
  • Generalize Coroutine suspension type
  • Improve Coroutine Request type safety
  • asyncio queue consumer coroutine
  • Coroutine in Extension Method
  • Reoccurring Coroutine
  • Coroutine doesn't complete its execution every time
  • Difference between a "coroutine" and a "thread"?
  • Difference between coroutine and future/task in Python 3.5?
  • How can I reset the Coroutine after each new Trackable detected?
  • "for" loop with IEnumerator coroutine containing a yied return not looping
  • Running asyncio coroutine out of the event flow
  • Coroutine stops working
  • Run Tarantool Lua function in another coroutine
  • how to add a coroutine to a running asyncio loop?
  • Acquiring Tornado Locks with coroutine
  • Parse.com/Unity: What is the point of using ContinueWith for task results vs. yielding a coroutine while task is not complete?
  • Generator-based coroutine versus native coroutine
  • Python's logging issue in Tornado coroutine
  • How to interrupt Tornado coroutine
  • How to execute Tornado coroutine inside of synchronous environment?
  • Tornado, run coroutine method with arguments from synchronous code
  • Python asyncio: function or coroutine, which to use?
  • lua coroutine as iterator: cannot resume dead coroutine
  • Unity coroutine movement over time is not consistent/accurate?
  • Reuse coroutine with different arguments per call in lua
  • Unity3d coroutine stops after while-loop
  • How resume the execution of a stackful coroutine in the context of its strand?
  • Using asio coroutine with user-defined data structure instead of a (asio) socket?
  • asyncio's call_later raises 'generator' object is not callable with coroutine object
  • Unit-testing a periodic coroutine with mock time
coroutine list of languages used
Other projects in C