{"id":18261722,"url":"https://github.com/supercip971/fibres","last_synced_at":"2025-04-04T20:30:31.151Z","repository":{"id":119190925,"uuid":"600777123","full_name":"Supercip971/fibres","owner":"Supercip971","description":"Coroutines/fibers implementation in C99","archived":false,"fork":false,"pushed_at":"2023-02-16T13:17:32.000Z","size":11,"stargazers_count":5,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-20T18:04:29.292Z","etag":null,"topics":["c","c99","coroutines","fibers"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Supercip971.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"license","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-02-12T15:15:47.000Z","updated_at":"2024-10-23T17:55:59.000Z","dependencies_parsed_at":null,"dependency_job_id":"1cfd9fc8-cd15-41d7-a94b-b3bb6bbba5c5","html_url":"https://github.com/Supercip971/fibres","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Supercip971%2Ffibres","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Supercip971%2Ffibres/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Supercip971%2Ffibres/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Supercip971%2Ffibres/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Supercip971","download_url":"https://codeload.github.com/Supercip971/fibres/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247246013,"owners_count":20907723,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["c","c99","coroutines","fibers"],"created_at":"2024-11-05T11:04:56.105Z","updated_at":"2025-04-04T20:30:31.117Z","avatar_url":"https://github.com/Supercip971.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# Fibers (or coroutines) in C99 !\n\nJust a sample project for a blog article I'm writing about fibers in C (for linux), that you can read here: [cyp.sh/blog/coroutines-in-c](https://cyp.sh/blog/coroutines-in-c) .\n\n\nIt's mainly inspired by an old code I wrote for [Brutal](https://github.com/brutal-org/brutal).\n\nIt's an experimentation and it should be used for learning purpose, there is some issues with \nthis code.\n\n\n## Examples: \n\n```c\n\n#include \"fibers.h\" \n\nvoid foo(void* args)\n{\n    for(int i = 0; i \u003c 10; i++)\n    {\n        printf(\"hello\");\n        yield(); \n    }\n}\n\nvoid bar(void* args)\n{\n    for(int i = 0; i \u003c 20; i++)\n    {\n        printf(\" world! \\n\");\n        yield();\n    }\n}\n\nint main(int argc, char** argv) \n{\n    \n    FiberID a = fiber_launch(foo, NULL);\n    FiberID b = fiber_launch(bar, NULL);\n\n    fiber_join(a);\n    fiber_join(b);\n\n    return 0;\n\n}\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsupercip971%2Ffibres","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsupercip971%2Ffibres","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsupercip971%2Ffibres/lists"}