Rid the AST & HIR pretty printer of cruft#119169
Merged
bors merged 1 commit intorust-lang:masterfrom Dec 22, 2023
Merged
Conversation
Collaborator
|
(rustbot has picked a reviewer for you, use r? to override) |
fmease
commented
Dec 20, 2023
| @@ -553,17 +553,7 @@ impl<'a> State<'a> { | |||
| } | |||
| hir::ItemKind::OpaqueTy(opaque_ty) => { | |||
Member
Author
There was a problem hiding this comment.
Is this branch reachable in practice? 🤔 type T = impl B; gets printed as type T = /*impl Trait*/; since the item gets to interpreted as a normal type alias in this specific case with a RHS of hir::TyKind::OpaqueDef. Doesn't matter anyway.
Contributor
|
r=me |
Collaborator
|
☔ The latest upstream changes (presumably #119163) made this pull request unmergeable. Please resolve the merge conflicts. |
78ca460 to
b09889b
Compare
Member
Author
|
@bors r=compiler-errors rollup |
Collaborator
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Dec 22, 2023
…iaskrgr Rollup of 5 pull requests Successful merges: - rust-lang#117601 (Add support for hexagon-unknown-none-elf as target) - rust-lang#119169 (Rid the AST & HIR pretty printer of cruft) - rust-lang#119194 (Run fuchsia tests only on nightly) - rust-lang#119201 (tests: fix overaligned-constant to not over-specify getelementptr instr) - rust-lang#119215 (Emits error if has bound regions) r? `@ghost` `@rustbot` modify labels: rollup
rust-timer
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Dec 22, 2023
Rollup merge of rust-lang#119169 - fmease:pretty-yeet-syntactic-cruft, r=compiler-errors Rid the AST & HIR pretty printer of cruft Found while working on rust-lang#119163. For `trait Trait: ?Sized {}` (semantically malformed), we currently output `trait Trait for ? Sized {}` (sic!) / `trait Trait for ? Sized { }` (sic!) if `-Zunpretty=expanded` / `-Zunpretty=hir` is passed. `trait Tr for Sized? {}` (rust-lang#15521) and later also `trait Tr for ?Sized {}` (I guess, rust-lang#20194) is former Rust syntax. Hence I'm removing these outdated branches. ~~This will conflict with rust-lang#119163, therefore marking this PR as blocked.~~ Rebased
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Found while working on #119163.
For
trait Trait: ?Sized {}(semantically malformed), we currently outputtrait Trait for ? Sized {}(sic!) /trait Trait for ? Sized { }(sic!) if-Zunpretty=expanded/-Zunpretty=hiris passed.trait Tr for Sized? {}(#15521) and later alsotrait Tr for ?Sized {}(I guess, #20194) is former Rust syntax. Hence I'm removing these outdated branches.This will conflict with #119163, therefore marking this PR as blocked.Rebased