Uh oh!
There was an error while loading. Please reload this page.
rustdoc: Remove apparently unnecessary conditional in doc_value - #91305
Conversation
Note for the future: This PR is designed to be easily reverted. Feel free to revert it if significant regressions arise. |
rustdoc: Write doc-comments directly instead of using FromIterator The FromIterator impl made the code much harder to understand. The types don't make sense until you realize there's a custom FromIterator impl. This is the first commit from rust-lang#91305; since `@camelid` wrote it originally I don't feel bad unilaterally approving it. r? `@ghost` `@bors` r+ Note that this will conflict with rust-lang#92078.
rustdoc: Write doc-comments directly instead of using FromIterator The FromIterator impl made the code much harder to understand. The types don't make sense until you realize there's a custom FromIterator impl. This is the first commit from rust-lang#91305; since ``@camelid`` wrote it originally I don't feel bad unilaterally approving it. r? ``@ghost`` ``@bors`` r+ Note that this will conflict with rust-lang#92078.
…eGomez rustdoc: Remove unused `collapsed` field `render/context` always runs after `run_global_context`, so it was always set to `true`. This is a holdover from when rustdoc allowed configuring passes, but the `collapse-docs` pass was removed ages ago, and the ability to configure passes is about to be removed. Found while reviewing rust-lang#91305.
This comment has been minimized.
This comment has been minimized.
I need to remove this conditional for rust-lang#91072, but while it seems unnecessary, we are not certain. So, the plan is to first remove the conditional and see if any regressions pop up before doing the refactor. This way, it will be easier to revert if there are subtle regressions.
camelid
commented
Dec 22, 2021
@rustbot ready |
jyn514
commented
Jan 4, 2022
I still am very uncomfortable making a change we know changes the behavior, but I don't want to block it. |
| for new_frag in iter { | ||
| if new_frag.kind != ori.kind || new_frag.parent_module != ori.parent_module { | ||
| break; | ||
| } |
There was a problem hiding this comment.
nit: this means that the iter.next() and such seems no longer necessary here (all elements of the iterator are directly added), but if you're just leaving that for easier revert seems OK.
There was a problem hiding this comment.
Let's see what @camelid thinks about it.
There was a problem hiding this comment.
That's a good point, but I do want to make this easy to revert quickly. So I think let's leave it as-is for now.
GuillaumeGomez
left a comment
There was a problem hiding this comment.
Apart from @Mark-Simulacrum's comment, looks good to me.
camelid
commented
Jan 6, 2022
Hmm... GitHub didn't notify me until just now. |
camelid
commented
Jan 6, 2022
@bors r=GuillaumeGomez rollup=never (for easy bisecting) |
bors
commented
Jan 6, 2022
📌 Commit 82d8ed4 has been approved by |
bors
commented
Jan 7, 2022
⌛ Testing commit 82d8ed4 with merge 6702eb6519fd3567230d593f986503fd38329651... |
bors
commented
Jan 7, 2022
💔 Test failed - checks-actions |
rust-log-analyzer
commented
Jan 7, 2022
GuillaumeGomez
commented
Jan 7, 2022
@bors retry |
bors
commented
Jan 7, 2022
⌛ Testing commit 82d8ed4 with merge 7d60dbbf68500d22760ab06370681c36880cd021... |
bors
commented
Jan 7, 2022
💥 Test timed out |
rust-log-analyzer
commented
Jan 7, 2022
ehuss
commented
Jan 7, 2022
@bors retry x86_64-msvc-1 took more than 4.5 hours to finish |
bors
commented
Jan 8, 2022
bors
commented
Jan 8, 2022
☀️ Test successful - checks-actions |
rust-timer
commented
Jan 8, 2022
Finished benchmarking commit (0282233): comparison url. Summary: This benchmark run did not return any relevant changes. If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf. @rustbot label: -perf-regression |
rustdoc: Remove unused `collapsed` field `render/context` always runs after `run_global_context`, so it was always set to `true`. This is a holdover from when rustdoc allowed configuring passes, but the `collapse-docs` pass was removed ages ago, and the ability to configure passes is about to be removed. Found while reviewing rust-lang/rust#91305.
I need to remove this conditional for #91072, but while it seems
unnecessary, we are not certain. So, the plan is to first remove the
conditional and see if any regressions pop up before doing the refactor.
This way, it will be easier to revert if there are subtle regressions.
r? @jyn514