wg

Crates.iowg
lib.rswg
version0.9.2
created_at2021-10-24 17:26:33.058805+00
updated_at2024-10-06 20:41:51.935114+00
descriptionGolang like WaitGroup implementation for sync/async Rust.
homepagehttps://github.com/al8n/wg
repositoryhttps://github.com/al8n/wg.git
max_upload_size
id470467
size86,918
Al Liu (al8n)

documentation

https://docs.rs/wg/

README

wg

Golang like WaitGroup implementation for sync/async Rust, support no_std environment.

github Build codecov

docs.rs crates.io crates.io

license

Introduction

By default, blocking version WaitGroup is enabled.

If you are using other async runtime, you need to enbale future feature in your Cargo.toml and use wg::AsyncWaitGroup.

Installation

  • std

    [dependencies]
    wg = "0.9"
    
  • future

    [dependencies]
    wg = { version = "0.9", features = ["future"] }
    
  • no_std

    [dependencies]
    wg = { version = "0.9", default_features = false, features = ["alloc"] }
    
  • no_std & future

    [dependencies]
    wg = { version = "0.9", default_features = false, features = ["alloc", "future"] }
    

Examples

Please see examples for details.

Acknowledgements

License

Licensed under either of Apache License, Version 2.0 or MIT license at your option. Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this project by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.
Commit count: 52

cargo fmt