Skip to content

Fix spacing and ordering of words in pretty printed Impl #92417

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 2 commits into from
Jan 7, 2022

Conversation

dtolnay
Copy link
Member

@dtolnay dtolnay commented Dec 29, 2021

Follow-up to #92238 fixing one of the FIXMEs.

macro_rules! repro {
    ($item:item) => {
        stringify!($item)
    };
}

fn main() {
    println!("{}", repro!(impl<T> Struct<T> {}));
    println!("{}", repro!(impl<T> const Trait for T {}));
}

Before: impl <T> Struct<T> {}
After: impl<T> Struct<T> {}

Before: impl const <T> Trait for T {} 😿
After: impl<T> const Trait for T {}

@rustbot rustbot added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Dec 29, 2021
@rust-highfive
Copy link
Contributor

r? @jackh726

(rust-highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Dec 29, 2021
@jackh726
Copy link
Member

jackh726 commented Jan 6, 2022

@bors r+ rollup

@bors
Copy link
Collaborator

bors commented Jan 6, 2022

📌 Commit a24e238 has been approved by jackh726

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jan 6, 2022
bors added a commit to rust-lang-ci/rust that referenced this pull request Jan 6, 2022
…askrgr

Rollup of 8 pull requests

Successful merges:

 - rust-lang#91055 (return the correct type for closures in `type_of`)
 - rust-lang#92207 (Delay remaining `span_bug`s in drop elaboration)
 - rust-lang#92417 (Fix spacing and ordering of words in pretty printed Impl)
 - rust-lang#92504 (Exit nonzero on rustc -Wall)
 - rust-lang#92559 (RustWrapper: adapt to new AttributeMask API)
 - rust-lang#92589 (Break the loop)
 - rust-lang#92607 (rustc_metadata: Some minor cleanups and optimizations)
 - rust-lang#92620 (Remove unused `ExtendDefault` struct)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 1a8f698 into rust-lang:master Jan 7, 2022
@rustbot rustbot added this to the 1.59.0 milestone Jan 7, 2022
@dtolnay dtolnay deleted the printimpl branch January 31, 2022 17:54
@dtolnay dtolnay added the A-pretty Area: Pretty printing (including `-Z unpretty`) label Dec 28, 2023
@dtolnay dtolnay removed the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Jan 14, 2025
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
A-pretty Area: Pretty printing (including `-Z unpretty`) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants