https://github.com/v2e4lisp/lshift
A natural way to partial a function for python.
https://github.com/v2e4lisp/lshift
Last synced: about 2 months ago
JSON representation
A natural way to partial a function for python.
- Host: GitHub
- URL: https://github.com/v2e4lisp/lshift
- Owner: v2e4lisp
- Created: 2013-10-28T12:30:46.000Z (over 12 years ago)
- Default Branch: master
- Last Pushed: 2013-10-28T13:08:20.000Z (over 12 years ago)
- Last Synced: 2026-03-14T10:13:24.157Z (3 months ago)
- Language: Python
- Size: 125 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# lshift
left shift arguments to make a function a partial application.
[](https://travis-ci.org/v2e4lisp/lshift)
tested on 2.7, 3.2, 3.3
## install
```bash
pip install lshift
```
## API
* `arg(*args, **kwargs)`
## Example
```python
from lshift import arg
import operator
double = operator.mul << arg(2)
mapinc = map << arg(lambda x: x+1)
```