{"id":22282026,"url":"https://github.com/rustyyato/out-ref","last_synced_at":"2025-03-25T19:24:10.449Z","repository":{"id":134804425,"uuid":"164928559","full_name":"RustyYato/out-ref","owner":"RustyYato","description":null,"archived":false,"fork":false,"pushed_at":"2021-01-20T15:29:20.000Z","size":6,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-30T16:58:07.490Z","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":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/RustyYato.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2019-01-09T19:56:46.000Z","updated_at":"2022-02-16T18:31:14.000Z","dependencies_parsed_at":null,"dependency_job_id":"6476a7ca-51ef-45dd-9923-d7c848685f9f","html_url":"https://github.com/RustyYato/out-ref","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/RustyYato%2Fout-ref","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RustyYato%2Fout-ref/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RustyYato%2Fout-ref/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RustyYato%2Fout-ref/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RustyYato","download_url":"https://codeload.github.com/RustyYato/out-ref/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":236385793,"owners_count":19140689,"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-12-03T16:24:42.640Z","updated_at":"2025-01-30T16:58:36.927Z","avatar_url":"https://github.com/RustyYato.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# out-reference\n\nThis crate brings out references to Rust, this crate has `no_std` support\nOut reference *never* read values behind the reference\n\n```rust\nuse out_reference::*;\n\nlet mut x = 0;\n\nlet mut out_x: Out\u003c'_, u32\u003e = x.out();\nout_x.set(10);\n\nassert_eq!(x, 10);\n```\n\nNote that setting a value does not drop the old value,\nas that would require at least 1 read of the value behind the pointer\n\nSo, the code below leaks the vector\n```rust\nuse out_reference::*;\n\nlet mut x = vec![0, 1, 2];\n\nlet mut out_x: Out\u003c'_, Vec\u003cu32\u003e\u003e = x.out();\nout_x.set(vec![]);\n\nassert_eq!(x, vec![]);\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frustyyato%2Fout-ref","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frustyyato%2Fout-ref","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frustyyato%2Fout-ref/lists"}