Avoid repeated rewrites of overflowing call arguments#6962
Conversation
There was a problem hiding this comment.
Does the test case need to be this big? Would be nice if this was smaller so that we could see the code changes in the GitHub UI.
There was a problem hiding this comment.
It's copied exactly as it is from rust repo. Yes, I could try make it smaller, but my ai subscription ended. Maybe leave as is?
There was a problem hiding this comment.
Let's remove the source file. Having the formatted target file should be enough
281c10d to
0f27271
Compare
0f27271 to
7c964f1
Compare
| #[derive(Clone, Eq, Hash, PartialEq)] | ||
| pub(crate) struct OverflowRewriteKey { | ||
| span_lo: u32, | ||
| span_hi: u32, | ||
| width: usize, | ||
| block_indent: usize, | ||
| alignment: usize, | ||
| offset: usize, | ||
| inside_macro: bool, | ||
| use_block: bool, | ||
| is_if_else_block: bool, | ||
| is_loop_block: bool, | ||
| force_one_line_chain: bool, | ||
| } |
There was a problem hiding this comment.
If we add new fields to RewriteContext do we need to update what gets included in OverflowRewriteKey? If so then it probably makes sense to leave a comment explaining that on RewriteContext.
There was a problem hiding this comment.
Let's remove the source file. Having the formatted target file should be enough
There was a problem hiding this comment.
Again, Let's remove this too. I don't think it's needed.
|
Reminder, once the PR becomes ready for a review, use |
Summary
Testing