-
-
Notifications
You must be signed in to change notification settings - Fork 15.3k
Sealed traits for rustdoc #68235
Copy link
Copy link
Open
Labels
A-rustdoc-uiArea: Rustdoc UI (generated HTML)Area: Rustdoc UI (generated HTML)A-trait-systemArea: Trait systemArea: Trait systemC-feature-requestCategory: A feature request, i.e: not implemented / a PR.Category: A feature request, i.e: not implemented / a PR.T-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.Relevant to the rustdoc team, which will review and decide on the PR/issue.T-rustdoc-frontendRelevant to the rustdoc-frontend team, which will review and decide on the web UI/UX output.Relevant to the rustdoc-frontend team, which will review and decide on the web UI/UX output.
Description
Metadata
Metadata
Assignees
Labels
A-rustdoc-uiArea: Rustdoc UI (generated HTML)Area: Rustdoc UI (generated HTML)A-trait-systemArea: Trait systemArea: Trait systemC-feature-requestCategory: A feature request, i.e: not implemented / a PR.Category: A feature request, i.e: not implemented / a PR.T-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.Relevant to the rustdoc team, which will review and decide on the PR/issue.T-rustdoc-frontendRelevant to the rustdoc-frontend team, which will review and decide on the web UI/UX output.Relevant to the rustdoc-frontend team, which will review and decide on the web UI/UX output.
Type
Fields
No fields configured for issues without a type.
In #67562, it was proposed to make
trait Anyan unsafe trait. This was ultimately rejected, as we do not currently want downstream users to see that it is unsafe. However, we wanted a way to have both. The suggestion is that rustdoc could have an (unstable, for now) attribute that indicates that a trait is "sealed," in the sense that no upstream impls are permitted.rustdoc would then show this trait as unimplementable. It would not show any unsafety on the trait (as it is then irrelevant to readers of the documentation).
See #67562 (comment), #67562 (comment).