{"id":15926513,"url":"https://github.com/christianparpart/compose","last_synced_at":"2025-09-10T07:36:15.107Z","repository":{"id":145095594,"uuid":"89710230","full_name":"christianparpart/compose","owner":"christianparpart","description":"Functional Programming in C++14","archived":false,"fork":false,"pushed_at":"2017-05-02T18:51:55.000Z","size":14,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-09T02:29:31.325Z","etag":null,"topics":["cpp","cpp11","cpp14","functional-programming","library"],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/christianparpart.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":"2017-04-28T13:48:03.000Z","updated_at":"2024-03-10T14:23:43.000Z","dependencies_parsed_at":null,"dependency_job_id":"88abef50-181e-49dc-877e-b5f24ad460f1","html_url":"https://github.com/christianparpart/compose","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/christianparpart%2Fcompose","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christianparpart%2Fcompose/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christianparpart%2Fcompose/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christianparpart%2Fcompose/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/christianparpart","download_url":"https://codeload.github.com/christianparpart/compose/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247008536,"owners_count":20868394,"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":["cpp","cpp11","cpp14","functional-programming","library"],"created_at":"2024-10-06T22:41:01.168Z","updated_at":"2025-04-03T13:26:54.325Z","avatar_url":"https://github.com/christianparpart.png","language":"C++","readme":"### Compose\n\nThat's my little library for allowing myself to code in fuctional style in C++14.\n\n### Example\n```cpp\n#include \"compose.h\"\n#include \u003ciostream\u003e\n\nint main() {\n  auto v = {1, 2, 3, 4, 5, 6, 7, 8};\n\n  auto range = compose(v)\n                   .map([](auto x) { return x * x; })\n                   .select([](auto x) { return !(x % 2); })\n                   .take(3);\n\n  for (auto a: range) {\n    std::cout \u003c\u003c \"a: \" \u003c\u003c a \u003c\u003c std::endl;\n  }\n}\n```\n\n### Functions API\n\n- `map(func)`\n- `select(predicate)`\n- `take(count)`\n- `fold(init, func)`\n- `size()`\n- ... (more to come, by dragons)\n\n### TODO\n- support more functional patterns, such as zip, foldLeft, ...\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchristianparpart%2Fcompose","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchristianparpart%2Fcompose","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchristianparpart%2Fcompose/lists"}