Skip to main content

write_stderr_unlocked

Function write_stderr_unlocked 

Source
pub fn write_stderr_unlocked(args: Arguments<'_>)
Expand description

Writes args to standard error in one write(2), formatted into a stack buffer (cut at 1 KiB). Unlike eprintln! it neither allocates nor takes the standard library’s stderr lock. That makes it safe in an allocation-failure hook, and for the watchdog when a stuck thread holds that lock. It opens a fresh line when a progress note left stderr mid-line, as the logger’s records do: a Fatal:timeout:wallclock glued onto (Processing definitions …l3backend-pdftex.def... ) escaped every ^Fatal: count.