Skip to main content

pr_data

Function pr_data 

Source
pub fn pr_data<W: Write>(
    data: &[u8],
    output: &mut W,
    config: &PrConfig,
    filename: &str,
    file_date: Option<SystemTime>,
) -> Result<()>
Expand description

Paginate raw byte data — fast path that avoids per-line String allocation. When no tab expansion or control char processing is needed, lines are extracted as &str slices directly from the input buffer (zero-copy).