7 releases (4 breaking)

Uses old Rust 2015

0.4.0 Nov 28, 2020
0.3.0 May 7, 2020
0.2.0 Jul 18, 2019
0.1.0 Oct 5, 2018
0.0.1 Jul 21, 2015

#65 in Memory management

Download history 864/week @ 2020-11-06 1144/week @ 2020-11-13 883/week @ 2020-11-20 1310/week @ 2020-11-27 1099/week @ 2020-12-04 1299/week @ 2020-12-11 682/week @ 2020-12-18 272/week @ 2020-12-25 927/week @ 2021-01-01 1032/week @ 2021-01-08 923/week @ 2021-01-15 917/week @ 2021-01-22 993/week @ 2021-01-29 1333/week @ 2021-02-05 1169/week @ 2021-02-12 849/week @ 2021-02-19

4,185 downloads per month
Used in less than 7 crates

MIT license

15KB
323 lines

pipe

travis-badge release-badge docs-badge license-badge

A synchronous memory Read/Write pipe.


lib.rs:

Synchronous in-memory pipe

Example

use std::thread::spawn;
use std::io::{Read, Write};

let (mut read, mut write) = pipe::pipe();

let message = "Hello, world!";
spawn(move || write.write_all(message.as_bytes()).unwrap());

let mut s = String::new();
read.read_to_string(&mut s).unwrap();

assert_eq!(&s, message);

Dependencies

~230KB