Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

rustdoc: Display tuple structs correctly #13639

Merged
merged 1 commit into from
Apr 20, 2014

Conversation

alexcrichton
Copy link
Member

The fields of tuple structs recently gained the ability to have privacy
associated with them, but rustdoc was not updated accodingly. This moves the
struct field filtering to the rendering phase in order to preserve the ordering
of struct fields to allow tuple structs to have their private fields printed as
underscores.

Closes #13594

@sfackler
Copy link
Member

Will this break support for "internal" docs builds that don't want privacy stripping?

@alexcrichton
Copy link
Member Author

It will break support for public/private struct fields, yes, but not for other kinds of privacy stripping.

@sfackler
Copy link
Member

It seems like we should make "should this be rendered" a separate concept from visibility inside of rustdoc. Most of the time they'd be the same, but it'd give the flexibility for callers to disable the privacy pass and get internal docs.

The fields of tuple structs recently gained the ability to have privacy
associated with them, but rustdoc was not updated accodingly. This moves the
struct field filtering to the rendering phase in order to preserve the ordering
of struct fields to allow tuple structs to have their private fields printed as
underscores.

Closes rust-lang#13594
@alexcrichton
Copy link
Member Author

Moved stripping back into rustdoc::passes and updated rendering accordingly.

bors added a commit that referenced this pull request Apr 20, 2014
…kler

The fields of tuple structs recently gained the ability to have privacy
associated with them, but rustdoc was not updated accodingly. This moves the
struct field filtering to the rendering phase in order to preserve the ordering
of struct fields to allow tuple structs to have their private fields printed as
underscores.

Closes #13594
@bors bors closed this Apr 20, 2014
@bors bors merged commit 9d546d6 into rust-lang:master Apr 20, 2014
@alexcrichton alexcrichton deleted the rustdoc-tuple-fields branch April 21, 2014 16:40
Manishearth pushed a commit to Manishearth/rust that referenced this pull request Nov 23, 2022
fix: Fix proc-macro-srv search paths for Arch Linux

Fixes rust-lang/rust-analyzer#13616
flip1995 added a commit to flip1995/rust that referenced this pull request Nov 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Tuple struct fields missing in documented signatures
3 participants