This is an archive of the discontinued LLVM Phabricator instance.

Initialize raw_ostream buffer mode using an enum instead of a boolean
Needs ReviewPublic

Authored by mehdi_amini on Jul 1 2015, 3:21 PM.
This revision needs review, but all reviewers have resigned.

Details

Reviewers
dexonsmith

Diff Detail

Event Timeline

mehdi_amini updated this revision to Diff 28905.Jul 1 2015, 3:21 PM
mehdi_amini retitled this revision from to Initialize raw_ostream buffer mode using an enum instead of a boolean.
mehdi_amini updated this object.
mehdi_amini edited the test plan for this revision. (Show Details)
mehdi_amini added a reviewer: dexonsmith.
mehdi_amini added a subscriber: Unknown Object (MLST).
mehdi_amini updated this revision to Diff 28907.Jul 1 2015, 3:30 PM

Comment the new enum

dexonsmith resigned from this revision.Oct 6 2020, 3:40 PM

Resigning to take this off my queue since this is 5+ years old, but this looks like a nice change that I'd be happy to review. Add me back if you want me to take a look at this or a rebased patch.

I can try to bring this back if there is interest in this.

As far as I remember I got feedback that this wasn't worth it compared to a
bool and a comment at call sites (was it Justin's feedback maybe?)
Basically:

raw_fd_ostream OF(TestFD, true, /*unbuffered=*/true);

vs

raw_fd_ostream OF(TestFD, true, StreamMode::Unbuffered);

Hmm, that rings a bell. I don't feel strongly either way.