misc-throw-by-value-catch-by-reference - #11151
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan provides up to 12 included reviews per hour; 10 remain after this review. 📝 SummarySummary by CodeRabbit
WalkthroughChangesUnit test assertion helpers now construct failure objects in named locals and throw them with Unit test exception cleanup
Merge Risk: ⚪ Minimal · up to The Clang-Tidy configuration retains the intended multiple-inheritance exemption while removing unrelated early suppressions; no current merge-readiness risk is identified. Comment |
🥳 CI Workflow Results🟩 Finished in 6h 33m: Pass: 100%/69 | Total: 2d 23h | Max: 2h 00m | Hits: 54%/323960See results here. |
bernhardmgruber
left a comment
There was a problem hiding this comment.
I think the changes in this PR do not improve code readability. I find the new version harder to comprehend, since it now requires ref-qualified stream put operators.
|
I am with @bernhardmgruber I prefer the previous version |
c42fc84 to
a1f3a20
Compare
|
@miscco @bernhardmgruber Another option to fix this is to move the objects into the throw expression: Foo f;
f << "asdasdasd";
throw std::move(f);Would that be preferable? |
dd688b3 to
b162389
Compare
b162389 to
c79e992
Compare
griwes
left a comment
There was a problem hiding this comment.
That's a much nicer fix than the one before.
Fixes all clang-tidy warnings for
misc-throw-by-value-catch-by-reference