{"id":26633094,"url":"https://github.com/bra1l0r/iterify-rs","last_synced_at":"2025-03-24T15:13:42.487Z","repository":{"id":57710751,"uuid":"512931703","full_name":"BRA1L0R/iterify-rs","owner":"BRA1L0R","description":"Iterate over anything with Iterify!","archived":false,"fork":false,"pushed_at":"2022-07-11T23:04:30.000Z","size":4,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-28T07:48:39.607Z","etag":null,"topics":["functional-programming","iterator","rust"],"latest_commit_sha":null,"homepage":"","language":"Rust","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/BRA1L0R.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-07-11T23:00:17.000Z","updated_at":"2022-07-11T23:05:32.000Z","dependencies_parsed_at":"2022-09-26T21:21:44.109Z","dependency_job_id":null,"html_url":"https://github.com/BRA1L0R/iterify-rs","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/BRA1L0R%2Fiterify-rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BRA1L0R%2Fiterify-rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BRA1L0R%2Fiterify-rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BRA1L0R%2Fiterify-rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/BRA1L0R","download_url":"https://codeload.github.com/BRA1L0R/iterify-rs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245294776,"owners_count":20591909,"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":["functional-programming","iterator","rust"],"created_at":"2025-03-24T15:13:41.859Z","updated_at":"2025-03-24T15:13:42.472Z","avatar_url":"https://github.com/BRA1L0R.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Iterify ![Downloads](https://img.shields.io/crates/v/iterify)\n\nIterate over anything with Iterify! This crates takes any type `T` and lets you iterate over a mutable reference, yielding any type you want.\n\nIt has similar behaviour to [`std::iter::successors`](https://doc.rust-lang.org/std/iter/fn.successors.html) except that Iterify lets you mutate the type in-place through a `\u0026mut` reference.\n\n#### Example\n\n```rust\nuse iterify::Iterify;\n\nfn main() {\n    let mut num = 12;\n    let collatz: Vec\u003c_\u003e = num\n        .iterify(|num| {\n            *num = match *num {\n                0 | 1 =\u003e return None,\n                n if n % 2 != 0 =\u003e n * 3 + 1,\n                n =\u003e n / 2,\n            };\n\n            Some(*num)\n        })\n        .collect();\n\n    assert_eq!(collatz, \u0026[6, 3, 10, 5, 16, 8, 4, 2, 1]);\n    assert_eq!(num, 1);\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbra1l0r%2Fiterify-rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbra1l0r%2Fiterify-rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbra1l0r%2Fiterify-rs/lists"}