linux-io

Crates.iolinux-io
lib.rslinux-io
version0.11.0
sourcesrc
created_at2023-02-05 19:09:39.075018
updated_at2024-07-31 02:17:59.816228
descriptionLightweight abstractions around Linux system calls related to file descriptors.
homepage
repositoryhttps://github.com/apparentlymart/rust-linux
max_upload_size
id777330
size140,909
Martin Atkins (apparentlymart)

documentation

README

linux-io crate for Rust

This crate offers some lightweight wrappers around direct Linux system calls related to file descriptors.

The goal is to make it convenient to work with the Linux system call interface and bypass std/libc without introducing any unnecessary additional abstractions beyond slight transformations of argument types and return values.

let mut f = File::create_raw(filename, 0o666)?
f.write_all(message)?; // (using the std::io::Write trait)
f.close()?;

By default this crate implements traits from the standard library where they make sense, but you can disable the default crate feature named std to remove those trait implementations and thereby make this crate usable in no_std environments.

Commit count: 76

cargo fmt