diff options
| author | Michael Howell <michael@notriddle.com> | 2022-10-23 14:48:16 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-10-23 14:48:16 -0700 |
| commit | 28a1bafd48a23a9993222072a019a7c0a433bdbd (patch) | |
| tree | d2be585b9cc7acb6b4e25dcdbc965d0415e1dcfe /src/test/rustdoc/inline_cross/auxiliary | |
| parent | 3df030d4418e011dbd5a4947157bcd14ba75e189 (diff) | |
| parent | f543770de26849fee46d7974ba9212e402c22151 (diff) | |
| download | rust-28a1bafd48a23a9993222072a019a7c0a433bdbd.tar.gz rust-28a1bafd48a23a9993222072a019a7c0a433bdbd.zip | |
Rollup merge of #103254 - fmease:fix-24183, r=GuillaumeGomez
rustdoc: do not filter out cross-crate `Self: Sized` bounds All type parameters **except `Self`** are implicitly `Sized` ([via](https://doc.rust-lang.org/nightly/std/marker/trait.Sized.html)). Previously, we disregarded the exception of `Self` and omitted cross-crate `Sized` bounds of *any* type parameter *including* `Self` when rendering. From now on, we *do* render cross-crate `Self: Sized` bounds. Most notably, in `std` we now finally properly render the `Sized` bound of the `Clone` trait as well as the `Self: Sized` bound on `Iterator::map`. Fixes #24183. ``@rustbot`` label T-rustdoc A-cross-crate-reexports r? rustdoc
Diffstat (limited to 'src/test/rustdoc/inline_cross/auxiliary')
| -rw-r--r-- | src/test/rustdoc/inline_cross/auxiliary/issue-24183.rs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/test/rustdoc/inline_cross/auxiliary/issue-24183.rs b/src/test/rustdoc/inline_cross/auxiliary/issue-24183.rs new file mode 100644 index 00000000000..e7a13acc6f8 --- /dev/null +++ b/src/test/rustdoc/inline_cross/auxiliary/issue-24183.rs @@ -0,0 +1,14 @@ +#![crate_type = "lib"] + +pub trait U/*: ?Sized */ { + fn modified(self) -> Self + where + Self: Sized + { + self + } + + fn touch(&self)/* where Self: ?Sized */{} +} + +pub trait S: Sized {} |
