Registry / utility / pipe-trait

pipe-trait

JSON →
library0.4.0rscratesunverified

Make it possible to chain regular functions.

# Cargo.toml [dependencies] pipe-trait = "0.4.0"
INSTALL
IMPORT
SIG · PIPE-TRAIT
P
pipe-trait
utilityrustv0.4.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Pipe
✓ use pipe_trait::Pipe;

Chains functions using the pipe operator-like syntax.

use pipe_trait::Pipe; fn add_one(x: i32) -> i32 { x + 1 } fn double(x: i32) -> i32 { x * 2 } fn main() { let result = 5.pipe(add_one).pipe(double); println!("{}", result); // 12 }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.4.0latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
9 hits · last 30 days
node
8
Amazon
1
Resources
pipe-trait — cargo add pipe-trait · libregistry