{"id":13822367,"url":"https://github.com/andylokandy/arraydeque","last_synced_at":"2025-04-04T10:06:15.752Z","repository":{"id":12604983,"uuid":"72344989","full_name":"andylokandy/arraydeque","owner":"andylokandy","description":"A circular buffer with fixed capacity (Rust).","archived":false,"fork":false,"pushed_at":"2024-01-14T14:17:41.000Z","size":256,"stargazers_count":104,"open_issues_count":6,"forks_count":21,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-28T09:08:24.222Z","etag":null,"topics":["cirular","no-std","rust","stack"],"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/andylokandy.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":"2016-10-30T11:19:36.000Z","updated_at":"2025-03-20T18:41:30.000Z","dependencies_parsed_at":"2024-01-18T03:48:57.277Z","dependency_job_id":null,"html_url":"https://github.com/andylokandy/arraydeque","commit_stats":{"total_commits":89,"total_committers":9,"mean_commits":9.88888888888889,"dds":0.2696629213483146,"last_synced_commit":"2ccf30574a2fac91311a0fca7b32f99d41f5680e"},"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andylokandy%2Farraydeque","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andylokandy%2Farraydeque/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andylokandy%2Farraydeque/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andylokandy%2Farraydeque/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/andylokandy","download_url":"https://codeload.github.com/andylokandy/arraydeque/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247157281,"owners_count":20893220,"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":["cirular","no-std","rust","stack"],"created_at":"2024-08-04T08:01:57.089Z","updated_at":"2025-04-04T10:06:15.701Z","avatar_url":"https://github.com/andylokandy.png","language":"Rust","funding_links":[],"categories":["Rust"],"sub_categories":[],"readme":"# `arraydeque`\n\n[![build status](https://travis-ci.org/andylokandy/arraydeque.svg?branch=master)](https://travis-ci.org/andylokandy/arraydeque)\n[![crates.io](https://img.shields.io/crates/v/arraydeque.svg)](https://crates.io/crates/arraydeque)\n[![docs.rs](https://docs.rs/arraydeque/badge.svg)](https://docs.rs/arraydeque)\n\nA circular buffer with fixed capacity.  Requires Rust 1.59+.\n\nThis crate is inspired by [**bluss/arrayvec**](https://github.com/bluss/arrayvec)\n\n### [**Documentation**](https://docs.rs/arraydeque)\n\n## Usage\n\nFirst, add the following to your `Cargo.toml`:\n\n```toml\n[dependencies]\narraydeque = \"0.5\"\n```\n\nNext, add this to your crate root:\n\n```rust\nextern crate arraydeque;\n```\n\nCurrently arraydeque by default links to the standard library, but if you would\ninstead like to use arraydeque in a `#![no_std]` situation or crate you can\nrequest this via:\n\n```toml\n[dependencies]\narraydeque = { version = \"0.4\", default-features = false }\n```\n\n## Example\n\n```rust\nextern crate arraydeque;\n\nuse arraydeque::ArrayDeque;\n\nfn main() {\n    let mut deque: ArrayDeque\u003c_, 2\u003e = ArrayDeque::new();\n    assert_eq!(deque.capacity(), 2);\n    assert_eq!(deque.len(), 0);\n\n    deque.push_back(1);\n    deque.push_back(2);\n    assert_eq!(deque.len(), 2);\n\n    assert_eq!(deque.pop_front(), Some(1));\n    assert_eq!(deque.pop_front(), Some(2));\n    assert_eq!(deque.pop_front(), None);\n}\n```\n\n## Changelog\n\n- 0.5.1 Make `ArrayDeque::new()` a const fn.\n\n- 0.5.0 Support consnt generic capacity. Remove `use_generic_array` feature.\n\n- 0.4.5 Update `generic-array` to `0.12`.\n\n- 0.4.4 Fix UB: `Some(ArrayDeque::new(xs)).is_some() == false`. ([#12](https://github.com/andylokandy/arraydeque/issues/12))\n\n- 0.4.3 Add support for `generic-array` under `use_generic_array` feature.\n\n- 0.4.1 Capacity now equal to backend_array.len().\n\n- 0.3.1 Add behaviors: `Saturating` and `Wrapping`.\n\n## Contribution\n\nAll kinds of contribution are welcomed.\n\n- **Issues.** Feel free to open an issue when you find typos, bugs, or have any question.\n- **Pull requests**. New collection, better implementation, more tests, more documents and typo fixes are all welcomed.\n\n## License\n\nLicensed under MIT license ([LICENSE-MIT](LICENSE-MIT) or http://opensource.org/licenses/MIT)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandylokandy%2Farraydeque","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fandylokandy%2Farraydeque","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandylokandy%2Farraydeque/lists"}