3 ms·
In the code I write and review I care about the buffer-flush semantics and will revise, or ask for a revision, if excessive flushing will result from too many s
by not2b 4y ago
In the code I write and review I care about the buffer-flush semantics and will revise, or ask for a revision, if excessive flushing will result from too many std::endl uses when generating large volumes of output. It isn't just an academic point; you might want to look at that code to see if std::endl is justified. It is appropriate if you want to guarantee that a given record reaches the output file quickly, and if not much is written it's a don't-care.
- CoastalCoder 4y agoThat's my policy too. I was pointing out that what we consider best practice isn't necessarily common practice. So the original story might benefit from additional nuance / distinctions.