本文へスキップ
Kitbay
スキル

rust-system-calls

NOASSERTION2026年11月11日 更新96,758GitHubスター

A short contributor guide in the Bun repository telling agents to use Bun's own bun_sys crate, not the Rust standard library or raw libc, for system calls and file input and output in Bun's Rust code.

スキルの内容

A short contributor guide in the Bun repository telling agents to use Bun's own bun_sys crate, not the Rust standard library or raw libc, for system calls and file input and output in Bun's Rust code. It explains the File wrapper that closes its descriptor when dropped, compares bun_sys with the alternatives on Windows support, error detail and automatic retries, and shows how to propagate errors or turn them into JavaScript exceptions and how to ignore a specific error such as a missing file. It lists the key functions and open flags, recommends pooled path buffers over large stack buffers, and warns against unwrapping fallible results or closing a descriptor still owned by a File.

できること

ドキュメントに記載なし