Skip to content

y2kappa/functools

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Functools

Collection of functional utilities for Rust.

Crates.io

let xs = vec![1, 2, 3];
let ys = vec![4, 5, 6];

assert_eq!(vector::zip_with(xs, ys, |x, y| x + y), vec![5, 7, 9]);
let xs = vec![1, 3, 5, 7, 9];
let is_odd = |x| x % 2 != 0;

assert_eq!(truth::all(&xs, is_odd), true)

Async pipe. Instead of:

let x = f(1).await;
let y = g(x).await;
let z = h(y).await;

you can do:

let x = pipe!(1 => f => g => h);

About

Functional tools for Rust.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages