Accept `?Sized` as well as `Sized?` by nrc · Pull Request #20194 · rust-lang/rust

Nick Cameron added 2 commits

December 26, 2014 10:16
Includes a bit of refactoring to store `?` unbounds as bounds with a modifier, rather than in their own world, in the AST at least.

alexcrichton added a commit to alexcrichton/rust that referenced this pull request

Dec 30, 2014

matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request

Dec 22, 2023
…, 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

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