3 ms·
Thanks for digging this up! It is good and interesting info, but unfortunately still doesn't satisfactorily answer why they are treated differently.
by weinzierl 3y ago
Thanks for digging this up! It is good and interesting info, but unfortunately still doesn't satisfactorily answer why they are treated differently.
- loeg 3y agoI did some more digging. By RFC 899, I believe Alex Crichton meant PR 899 in this repo: https://github.com/rust-lang/rfcs/pull/899 https://github.com/rust-lang/rfcs/pull/899 Still, no real discussion of why unbuffered stderr.
- masklinn 3y agoBecause stderr being conventionally used for error reporting it's important to immediately output that information to avoid losing it in case the program then crashes or ends without flushing. Stdout is generally the "normal output" so loss of information on crash tends to be less relevant, and throughput more so as programs commonly send huge amounts of data to stdout.