#mutex #arc #macro

arcmutex

A convenience library for working with Arc<Mutex<T>>s

3 unstable releases

Uses old Rust 2015

0.2.0 Dec 18, 2015
0.1.1 Mar 28, 2015
0.1.0 Mar 28, 2015

#123 in #arc

Download history 1/week @ 2024-11-13 1/week @ 2024-11-20 4/week @ 2024-12-04 3/week @ 2024-12-11 23/week @ 2025-01-01 4/week @ 2025-01-08 10/week @ 2025-01-15 32/week @ 2025-02-05 60/week @ 2025-02-12 44/week @ 2025-02-19 42/week @ 2025-02-26

178 downloads per month

MIT license

2KB

ArcMutex

A rust library for making creating Arc<Mutex<T>>s more convenient.
Defines the ArcMutex<T> type alias and the arcmutex( expr) function.

Contributions welcome! :)

Author: Kurotetsuka
License: MIT

Example

extern crate arcmutex;
use arcmutex::{ arcmutex, ArcMutex};

let a : ArcMutex<u8> = arcmutex( 0);
let mut b = a.lock().unwrap();
*b += 1;
println!( "a: {}", *b);

No runtime deps