An atomic class that guarantees atomic updates to its contained value.
Project description
An atomic class that guarantees atomic updates to its contained value.
from atomic import Atomic atomic = Atomic(0) atomic.update(lambda v: v + 1)
Installation
To install atomic, use pip :
pip install atomic
Acknowledgement
This is heavily inspired by ruby-atomic.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
atomic-0.4.tar.gz
(10.9 kB
view details)
File details
Details for the file atomic-0.4.tar.gz
.
File metadata
- Download URL: atomic-0.4.tar.gz
- Upload date:
- Size: 10.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a38ba9a9cac389c1469d95cda8edfd48adda578a0409212cb57f78c7fbc91b4a |
|
MD5 | 99188d677790d21bdf1b87fa865201ee |
|
BLAKE2b-256 | 7c21d7dfbf83e6473a84d7233876f006836a9c0baeaa3432a19e53c8b7b655fd |