Rust Search

Find the best content on Rust, curated by the community; a search engine for Rustaceans.
doc.rust-lang.org
pub struct NulError
An error indicating that an interior nul byte was found.
struct alloc Stable since 1.64.0 Version 1.100.0-nightly
doc.rust-lang.org
pub fn into_vec(self) -> Vec<u8>
Consumes this error, returning the underlying vector of bytes which generated the error in the first place.
method alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub fn nul_position(&self) -> usize
Returns the position of the nul byte in the slice that caused CString::new to fail.
method alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub mod fmt
Utilities for formatting and printing Strings.
module alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub fn format(args: Arguments<'_>) -> string::String
Takes an Arguments struct and returns the resulting formatted string.
function alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub macro format!
Creates a String using interpolation of runtime expressions.
macro alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub trait BufRead
A BufRead is a type of Reader which has an internal buffer, allowing it to perform extra ways of reading.
trait alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
fn consume(&mut self, amount: usize)
Marks the given amount of additional bytes from the internal buffer as having been read. Subsequent calls to read only return bytes that have not been marked as read.
method alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
fn fill_buf(&mut self) -> Result<&[u8]>
Returns the contents of the internal buffer, filling it with more data, via Read methods, if empty.
method alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
fn lines(self) -> Lines<Self>
Returns an iterator over the lines of this reader.
method alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
fn read_line(&mut self, buf: &mut String) -> Result<usize>
Reads all bytes until a newline (the 0xA byte) is reached, and append them to the provided String buffer.
method alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
fn read_until(&mut self, byte: u8, buf: &mut Vec<u8>) -> Result<usize>
Reads all bytes into buf until the delimiter byte or EOF is reached.
method alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
fn skip_until(&mut self, byte: u8) -> Result<usize>
Skips all bytes until the delimiter byte or EOF is reached.
method alloc Stable since 1.83.0 Version 1.100.0-nightly
doc.rust-lang.org
fn split(self, byte: u8) -> Split<Self>
Returns an iterator over the contents of this reader split on the byte byte.
method alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub struct IntoInnerError<W>
An error returned by BufWriter::into_inner which combines an error that happened while writing out the buffer, and the buffered writer object which may be used to recover from the condition.
struct alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub struct BufReader<R>
The BufReader<R> struct adds buffering to any reader.
struct alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub struct BufWriter<W>
Wraps a writer and buffers its output.
struct alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub struct WriterPanicked
Error returned for the buffered data from BufWriter::into_parts, when the underlying writer has previously panicked. Contains the (possibly partly written) buffered data.
struct alloc Stable since 1.56.0 Version 1.100.0-nightly
doc.rust-lang.org
pub struct LineWriter<W>
Wraps a writer and buffers output to it, flushing whenever a newline (0x0a, '\n') is detected.
struct alloc Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub fn copy<R, W>(reader: &mut R, writer: &mut W) -> crate::io::Result<u64>
Copies the entire contents of a reader into a writer.
function alloc Stable since 1.0.0 Version 1.100.0-nightly
"Code does not become better out of thin air just because you rewrite it in #rustlang."

Search tips

Type anything to search across articles, videos (including conference talks), podcasts, research, crates, and Rust API documentation. These operators give you finer control — click an example to try it.

Find pages containing all your words. Pages where the words appear together rank higher.
Quote part of your query to keep those words together as an exact phrase within a larger search.
Wrap the whole query in quotes for a verbatim search that matches text exactly, punctuation and all — perfect for Rust syntax. Needs at least 3 characters.
Put ! first to open the top result immediately. Quote the whole query for a literal leading bang, as in '!Send'. Bangs elsewhere, such as println!, stay literal. Browser and launcher shortcuts can invoke this directly. See search integrations.
Limit results to a single site. Works on its own () too. One site: per search.

Use the tabs and filters above the results to narrow by content type, publication year, and sort order.