| Crates.io | async-context |
| lib.rs | async-context |
| version | 0.1.1 |
| created_at | 2024-07-15 16:49:35.68031+00 |
| updated_at | 2024-07-15 19:14:52.667464+00 |
| description | Provide context to async functions |
| homepage | |
| repository | |
| max_upload_size | |
| id | 1304038 |
| size | 4,770 |
This crate provides an easy way to provide context to async functions.
Use provide_async_context to provide the context:
provide_async_context(16, async {
with_async_context(|my_number| {
assert_eq!(my_number, 16);
})
}).await