{"id":16241281,"url":"https://github.com/nvzqz/malloced","last_synced_at":"2025-03-19T16:31:47.606Z","repository":{"id":57636454,"uuid":"320973946","full_name":"nvzqz/malloced","owner":"nvzqz","description":"A malloc-ed box pointer type for Rust","archived":false,"fork":false,"pushed_at":"2023-02-27T13:49:19.000Z","size":42,"stargazers_count":5,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-02-28T19:55:46.791Z","etag":null,"topics":["buf","c","ffi","free","malloc","rust","safe"],"latest_commit_sha":null,"homepage":"https://docs.rs/malloced","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nvzqz.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE-APACHE","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":"2020-12-13T03:16:15.000Z","updated_at":"2023-04-28T07:30:05.000Z","dependencies_parsed_at":"2024-10-27T21:23:54.082Z","dependency_job_id":"87a764b9-24de-4038-bd8f-077b84754152","html_url":"https://github.com/nvzqz/malloced","commit_stats":{"total_commits":51,"total_committers":1,"mean_commits":51.0,"dds":0.0,"last_synced_commit":"4d7731f5d7b55a5dcedf2c8b7f134c906ba00ecf"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nvzqz%2Fmalloced","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nvzqz%2Fmalloced/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nvzqz%2Fmalloced/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nvzqz%2Fmalloced/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nvzqz","download_url":"https://codeload.github.com/nvzqz/malloced/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244006277,"owners_count":20382444,"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":["buf","c","ffi","free","malloc","rust","safe"],"created_at":"2024-10-10T14:06:55.895Z","updated_at":"2025-03-19T16:31:47.018Z","avatar_url":"https://github.com/nvzqz.png","language":"Rust","funding_links":["https://github.com/sponsors/nvzqz","https://www.paypal.me/nvzqz)!"],"categories":[],"sub_categories":[],"readme":"# Malloced\n\nA `malloc`-ed box pointer type, brought to you by\n[@NikolaiVazquez](https://twitter.com/NikolaiVazquez)!\n\n## Table of Contents\n\n1. [Donate](#donate)\n2. [Usage](#usage)\n3. [MSRV](#msrv)\n4. [FFI Safety](#ffi-safety)\n5. [Alternatives](#alternatives)\n6. [License](#license)\n\n## Donate\n\nIf this project is useful to you, please consider\n[sponsoring me](https://github.com/sponsors/nvzqz) or\n[donating directly](https://www.paypal.me/nvzqz)!\n\nDoing so enables me to create high-quality open source software like this. ❤️\n\n## Usage\n\nThis library is available [on crates.io](https://crates.io/crates/malloced) and\ncan be used by adding the following to your project's\n[`Cargo.toml`](https://doc.rust-lang.org/cargo/reference/manifest.html):\n\n```toml\n[dependencies]\nmalloced = \"1.3.1\"\n```\n\nThe star of the show is [`Malloced`], [`Box`]-like pointer that calls `free` on\n[`Drop`]:\n\n```rust\nuse malloced::Malloced;\n```\n\n## MSRV\n\nThis library's minimum supported Rust version (MSRV) is 1.64. A new version\nrequirement would result in a minor version update.\n\n## FFI Safety\n\n`Malloced\u003cT\u003e` is a `#[repr(transparent)]` wrapper over `NonNull\u003cT\u003e`, so it can\nbe safely used in C FFI. For example, the following is safe and even compiles\nwith the `improper_ctypes` lint enabled:\n\n```rust\n#[deny(improper_ctypes)]\nextern \"C\" {\n    fn my_array_malloc() -\u003e Malloced\u003c[u8; 32]\u003e;\n}\n```\n\n## Alternatives\n\n- [`malloc_buf`](https://docs.rs/malloc_buf)\n- [`mbox`](https://docs.rs/mbox)\n\n## License\n\nThis project is released under either\n[MIT License](https://github.com/nvzqz/malloced/blob/master/LICENSE-MIT) or\n[Apache License (Version 2.0)](https://github.com/nvzqz/malloced/blob/master/LICENSE-APACHE)\nat your choosing.\n\n[`Box`]: https://doc.rust-lang.org/std/boxed/struct.Box.html\n[`Drop`]: https://doc.rust-lang.org/std/ops/trait.Drop.html\n[`Malloced`]: https://docs.rs/malloced/1.3.1/malloced/struct.Malloced.html\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnvzqz%2Fmalloced","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnvzqz%2Fmalloced","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnvzqz%2Fmalloced/lists"}