{"id":20522988,"url":"https://github.com/openbytedev/destruct-drop","last_synced_at":"2025-09-12T12:33:07.966Z","repository":{"id":57618436,"uuid":"411436843","full_name":"OpenByteDev/destruct-drop","owner":"OpenByteDev","description":"Macro for dropping the fields of a struct or enum without dropping the container.","archived":false,"fork":false,"pushed_at":"2023-06-07T11:38:35.000Z","size":12,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-28T07:17:52.277Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/OpenByteDev.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":"2021-09-28T20:59:53.000Z","updated_at":"2023-06-07T11:38:39.000Z","dependencies_parsed_at":"2025-01-16T10:44:02.225Z","dependency_job_id":"ea2dafa5-f766-47e8-a849-8eb8437724b6","html_url":"https://github.com/OpenByteDev/destruct-drop","commit_stats":{"total_commits":10,"total_committers":1,"mean_commits":10.0,"dds":0.0,"last_synced_commit":"2547857a4c6b68b7e1a615588de0d1a26ec1815e"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenByteDev%2Fdestruct-drop","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenByteDev%2Fdestruct-drop/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenByteDev%2Fdestruct-drop/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenByteDev%2Fdestruct-drop/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/OpenByteDev","download_url":"https://codeload.github.com/OpenByteDev/destruct-drop/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242128317,"owners_count":20076177,"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":[],"created_at":"2024-11-15T22:37:31.604Z","updated_at":"2025-03-06T00:44:01.378Z","avatar_url":"https://github.com/OpenByteDev.png","language":"Rust","readme":"# destruct-drop\n\n[![CI](https://github.com/OpenByteDev/destruct-drop/actions/workflows/ci.yml/badge.svg)](https://github.com/OpenByteDev/destruct-drop/actions/workflows/ci.yml)\n[![crates.io](https://img.shields.io/crates/v/destruct-drop.svg)](https://crates.io/crates/destruct-drop)\n[![Documentation](https://docs.rs/destruct-drop/badge.svg)](https://docs.rs/destruct-drop)\n[![dependency status](https://deps.rs/repo/github/openbytedev/destruct-drop/status.svg)](https://deps.rs/repo/github/openbytedev/destruct-drop)\n[![MIT](https://img.shields.io/crates/l/destruct-drop.svg)](https://github.com/OpenByteDev/destruct-drop/blob/master/LICENSE)\n\nMacro for dropping the fields of a struct or enum without dropping the container.\n\n## Usage\nAdd `#[derive(DestructDrop)]` to your `struct` or `enum` definition.\n```rust\nuse destruct_drop::DestructDrop;\n\n#[derive(DestructDrop)]\nstruct Container {\n    inner: Inner\n}\n\nstruct Inner;\n\nimpl Drop for Container {\n    fn drop(\u0026mut self) {\n        println!(\"dropped Container\");\n    }\n}\n\nimpl Drop for Inner {\n    fn drop(\u0026mut self) {\n        println!(\"dropped Inner\");\n    }\n}\n\nfn main() {\n    // prints \"dropped Inner\" and then \"dropped Container\"\n    drop(Container { inner: Inner });\n\n    // prints only \"dropped Inner\"\n    Container { inner: Inner }.destruct_drop();\n}\n```\n\n## License\nLicensed under MIT license ([LICENSE](https://github.com/OpenByteDev/destruct-drop/blob/master/LICENSE) or http://opensource.org/licenses/MIT)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopenbytedev%2Fdestruct-drop","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fopenbytedev%2Fdestruct-drop","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopenbytedev%2Fdestruct-drop/lists"}