Add pretty_terminator to pretty stable-mir#118172
Conversation
|
This PR changes Stable MIR cc @oli-obk, @celinval, @spastorino, @ouz-a |
|
Is there a way that we could have some sort of stdout test that shows what the output changes are? Like a small, stable example program that we could have blessed every time the output changes? |
I was thinking of writing one after couple PRs down the line. |
f594f9f to
8b971ee
Compare
Can you add |
1324363 to
b5c782d
Compare
celinval
left a comment
There was a problem hiding this comment.
Looks good. I just added a comment regarding the change to SwitchTarget.
It would be nice if we could add a little sanity check for stable-mir files. We could extend the project-stable-mir test infrastructure for now. In that case, I wouldn't do a full match though, to avoid this constantly breaking.
|
☔ The latest upstream changes (presumably #118248) made this pull request unmergeable. Please resolve the merge conflicts. |
b5c782d to
39924d8
Compare
I'm planning that for soon, in the next PR I'm going to fix projection printing and place printing and then we can have some sort of a reference program where with each change we could generate new output and see how it looks. |
|
☔ The latest upstream changes (presumably #118277) made this pull request unmergeable. Please resolve the merge conflicts. |
39924d8 to
a0d19ec
Compare
a0d19ec to
de27790
Compare
|
@bors r+ rollup |
…mpiler-errors Rollup of 9 pull requests Successful merges: - rust-lang#111133 (Detect Python-like slicing and suggest how to fix) - rust-lang#114708 (Allow setting `rla` labels via `rustbot`) - rust-lang#117526 (Account for `!` arm in tail `match` expr) - rust-lang#118172 (Add `pretty_terminator` to pretty stable-mir) - rust-lang#118202 (Added linker_arg(s) Linker trait methods for link-arg to be prefixed "-Wl," for cc-like linker args and not verbatim) - rust-lang#118374 (QueryContext: rename try_collect_active_jobs -> collect_active_jobs, change return type from Option<QueryMap> to QueryMap) - rust-lang#118381 (rustc_span: Use correct edit distance start length for suggestions) - rust-lang#118382 (Address unused tuple struct fields in the compiler) - rust-lang#118384 (Address unused tuple struct fields in rustdoc) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#118172 - ouz-a:improve_emit_stable1, r=celinval Add `pretty_terminator` to pretty stable-mir ~Because we don't have successors in `stable_mir` this is somewhat lacking but it's better than nothing~, also fixed bug(?) with `Opaque` which printed extra `"` when we try to print opaqued `String`. **Edit**: Added successors so this covers Terminators as a whole. r? `@celinval`
Because we don't have successors in, also fixed bug(?) withstable_mirthis is somewhat lacking but it's better than nothingOpaquewhich printed extra"when we try to print opaquedString.Edit: Added successors so this covers Terminators as a whole.
r? @celinval