A library of rust-styled monad utils for python.
Project description
Monad STD
monad_std
is a library that provides some useful Rust-styled utilities for using monads in Python.
Quick Start
To install this library, simply use your favorite package manager, here we use pure pip.
pip install monad-std
Then, import the library:
>>> from monad_std import *
>>> Ok(2)
Result::Ok(2)
Now you could use the utilities this library provides. For more information and examples, see the documentation above.
For a better guide, see the documentation's quick start guide.
Contribution
Any issue and pull request is welcomed, and you can directly make a pr for new features or open an issue for bug reports.
Future Plan
Until now, this library provides the following features:
monad_std.Option
: An optional value.monad_std.Result
: A structure containing a success value or an error.monad_std.Ok
: A successful value.monad_std.Err
: An error value.
monad_std.std_types
: Wrapped api around std types.monad_std.iter
: Iterator interface with functors and monads support.
And the following are being developed:
monad_std.Either
: A structure containing two type of values, but not that specific likemonad_std.Result
- A better entry point for those utilities.
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
Built Distribution
Hashes for monad_std-0.5.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4f3fb1f7ccc2f195d4b37594744829fb90600ca2b7c9851d39efa2e90b1aaf5e |
|
MD5 | c593d06ef026d32fe4bbb81ecd1bd90b |
|
BLAKE2b-256 | 3b0e7be1f61803ab3866591317b520d7988e39606b66b717a8b69ea422696d7c |