| Crates.io | derive_weak |
| lib.rs | derive_weak |
| version | 0.1.0 |
| created_at | 2022-06-09 08:47:33.849806+00 |
| updated_at | 2022-06-09 08:47:33.849806+00 |
| description | Make weak counterpart for structure |
| homepage | |
| repository | https://github.com/milyin/async-object |
| max_upload_size | |
| id | 602509 |
| size | 27,714 |
Implements derive macro #[derive(Weak)] which creates ‘weak’ counterpart for the structure. I.e. when original structure contains reference counting pointers (Arc, Rc), the corresponding weak structure contains the weak variants of these pointers (std::sync::Weak, std::rc::Weak).
This may be useful when it’s inconvenient to store some data under refernce counting pointer, due to performance or ergonomic reasons.