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: Fix search links to enums/typedefs #14101

Closed
wants to merge 1 commit into from

Conversation

alexcrichton
Copy link
Member

When the values in html::item_type were updated, the JS definitions were
accidentally not updated as well.

Closes #14095

When the values in html::item_type were updated, the JS definitions were
accidentally not updated as well.

Closes rust-lang#14095
"fn",
"typedef",
"type",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't actually know what this JS is for, but should it really have two entries called "type"?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok I looked at it and I think the answer is "yes". The index here matches a discriminant, so you're mapping both Enum and Typedef to the same name "type".

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately, the Def enum in the ast uses DefTy for both enums and typedefs. Instead of refactoring the whole compiler, I figured I'd just use the same pattern (for better or for worse).

We're guaranteed that they'll never clash because they're in the same namespace (resolve checks that)

bors added a commit that referenced this pull request May 11, 2014
When the values in html::item_type were updated, the JS definitions were
accidentally not updated as well.

Closes #14095
@bors bors closed this May 11, 2014
@alexcrichton alexcrichton deleted the issue-14095 branch May 11, 2014 18:20
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.

rustdoc search enum links are broken
3 participants