Right now, in order to get a locked stdout, one needs to do as such:
let stdout = std::io::stdout(); let stdout = stdout.lock();
In order to get optimal performance, it's actually this:
let stdout = std::io::stdout(); let stdout = std::io::BufWriter::new(stdout.lock());
It'd be nice if there were a shorthand for this. Perhaps one could be an owned
fn Stdout::into_locked(self) (or just
The BufWriter thing is less concerning, but it seems to be a best kept secret of squeezing performance out of stdout.