| Crates.io | abort-on-drop |
| lib.rs | abort-on-drop |
| version | 0.2.2 |
| created_at | 2022-04-27 00:49:53.464939+00 |
| updated_at | 2022-08-04 23:24:52.360656+00 |
| description | A wrapper of Tokio's JoinHandle that aborts the task when it's dropped, while still allowing it to be awaited for joining. |
| homepage | |
| repository | http://github.com/cyb0124/abort-on-drop |
| max_upload_size | |
| id | 575768 |
| size | 5,844 |
This crate provides a wrapper type of Tokio's JoinHandle: ChildTask, which aborts the task when it's dropped. ChildTask can still be awaited to join the child-task, and abort-on-drop will still trigger while it is being awaited.
For example, if task A spawned task B but is doing something else, and task B is waiting for task C to join, aborting A will also abort both B and C.