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

Intra-doc links do not resolve for value keywords #74515

Closed
jyn514 opened this issue Jul 19, 2020 · 3 comments
Closed

Intra-doc links do not resolve for value keywords #74515

jyn514 opened this issue Jul 19, 2020 · 3 comments
Labels
A-intra-doc-links Area: Intra-doc links, the ability to link to items in docs by name C-bug Category: This is a bug. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.

Comments

@jyn514
Copy link
Member

jyn514 commented Jul 19, 2020

warning: `[true]` cannot be resolved, ignoring it.
 --> prim.rs:1:6
  |
1 | /// [`true`] and [`bool`]
  |      ^^^^^^ cannot be resolved, ignoring

The bug is here:

fn is_primitive(path_str: &str, ns: Namespace) -> Option<Res> {

It only checks for types, not for values.

I opened an issue because I'm not quite sure how to fix it: Res has PrimTy but doesn't seem to have a place for keywords in the value namespace.

Originally posted by @jyn514 in #73618

@jyn514 jyn514 added A-intra-doc-links Area: Intra-doc links, the ability to link to items in docs by name C-bug Category: This is a bug. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. labels Jul 19, 2020
@jyn514
Copy link
Member Author

jyn514 commented Jul 19, 2020

This looks like it might be the same issue as #63351.

@GuillaumeGomez
Copy link
Member

I think that "true" and "false" are the two only cases for primitives where we should check for values.

@jyn514
Copy link
Member Author

jyn514 commented Aug 4, 2020

Closing as wontfix: #75101

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-intra-doc-links Area: Intra-doc links, the ability to link to items in docs by name C-bug Category: This is a bug. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

2 participants