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

Broken link to unstable book in rustc_plugin API docs #57489

Closed
fkohlgrueber opened this issue Jan 10, 2019 · 5 comments · Fixed by #60131
Closed

Broken link to unstable book in rustc_plugin API docs #57489

fkohlgrueber opened this issue Jan 10, 2019 · 5 comments · Fixed by #60131
Labels
A-docs Area: documentation for any part of the project, including the compiler, standard library, and tools E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.

Comments

@fkohlgrueber
Copy link
Contributor

The documentation of rustc_plugin links to the plugin feature in the unstable book, but that link is broken.

It points to:
https://doc.rust-lang.org/nightly/nightly-rustc/unstable-book/language-features/plugin.html

While the correct link would be:
https://doc.rust-lang.org/nightly/unstable-book/language-features/plugin.html

In the source, the link is relative:
../unstable-book/language-features/plugin.html

I'd be interested in fixing this, but I don't know whether a relative or absolute link is better in this situation.

@steveklabnik
Copy link
Member

steveklabnik commented Jan 10, 2019 via email

@fkohlgrueber
Copy link
Contributor Author

The rustc api documentation doesn't get build locally by default, right?

I could replace the relative link with ../../unstable-book/language-features/plugin.html which should work for the hosted paths I showed above, but I don't know whether this works for the local use-case as well. Do you have any suggestions?

matthiaskrgr added a commit to matthiaskrgr/rust that referenced this issue Jan 21, 2019
Changes:
````
Fixing typo in CONTRIBUTING.md
Fix breakage due to rust-lang#57651
Run rustfmt
Fixed breakage due to rust-lang#57489
Fix breakage due to rust-lang#57755
Catch up with `format_args` change
Fix bad `while_let_on_iterator` suggestion.
rustup rust-lang#57747
Fixing issues pointed out by dogfood tests.
Update to collect all the files then throw the error.
Adding a test for checking if test files are missing.
Remove bors.toml
add applicability to lint name suggestion
````
Arkweid pushed a commit to Arkweid/rust-clippy that referenced this issue Jan 23, 2019
* master: (58 commits)
  Rustfmt all the things
  Don't make decisions on values that don't represent the decision
  Improving comments.
  Rustup
  Added rustfix to the test.
  Improve span shortening.
  Added "make_return" and "blockify" convenience methods in Sugg and used them in "needless_bool".
  Actually check for constants.
  Fixed potential mistakes with nesting. Added tests.
  formatting fix
  Update clippy_lints/src/needless_bool.rs
  formatting fix
  Fixing typo in CONTRIBUTING.md
  Fix breakage due to rust-lang/rust#57651
  needless bool lint suggestion is wrapped in brackets if it is an "else" clause of an "if-else" statement
  Fix automatic suggestion on `use_self`.
  Remove negative integer literal checks.
  Fix `implicit_return` false positives.
  Run rustfmt
  Fixed breakage due to rust-lang/rust#57489
  ...
@jonas-schievink jonas-schievink added E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. A-docs Area: documentation for any part of the project, including the compiler, standard library, and tools labels Jan 26, 2019
VardhanThigle pushed a commit to jethrogb/rust that referenced this issue Jan 31, 2019
Changes:
````
Fixing typo in CONTRIBUTING.md
Fix breakage due to rust-lang#57651
Run rustfmt
Fixed breakage due to rust-lang#57489
Fix breakage due to rust-lang#57755
Catch up with `format_args` change
Fix bad `while_let_on_iterator` suggestion.
rustup rust-lang#57747
Fixing issues pointed out by dogfood tests.
Update to collect all the files then throw the error.
Adding a test for checking if test files are missing.
Remove bors.toml
add applicability to lint name suggestion
````
@polybuildr
Copy link
Contributor

@fkohlgrueber, I wasn't able to find the docs for rustc_plugin locally by default (using locate) so it seems likely that you're correct. It also seems quite likely that the path change you've proposed will work just as well for local installations, so I'd suggest going ahead and making a PR and then the reviewer(s) can comment on whether the solution is acceptable.

@agnxy
Copy link
Contributor

agnxy commented Apr 14, 2019

I tried to build rustc_plugin doc and the unstable book. The rustc_plugin doc lives at
build/x86_64-unknown-linux-gnu/compiler-doc/rustc_plugin/index.html and the link which points to the local unstable book is build/x86_64-unknown-linux-gnu/doc/unstable-book/language-features/plugin.html. So the correct relative path is different from the online docs.
I'm new to Rust documentation. There might be something I'm missing here 😄

@agnxy
Copy link
Contributor

agnxy commented Apr 20, 2019

I created a PR for further discussion. The fix replaces the broken link with a correct absolute link as suggested in the comment.

Manishearth added a commit to Manishearth/rust that referenced this issue May 5, 2019
flip1995 pushed a commit to flip1995/rust-clippy that referenced this issue May 5, 2020
Changes:
````
Fixing typo in CONTRIBUTING.md
Fix breakage due to rust-lang/rust#57651
Run rustfmt
Fixed breakage due to rust-lang/rust#57489
Fix breakage due to rust-lang/rust#57755
Catch up with `format_args` change
Fix bad `while_let_on_iterator` suggestion.
rustup rust-lang/rust#57747
Fixing issues pointed out by dogfood tests.
Update to collect all the files then throw the error.
Adding a test for checking if test files are missing.
Remove bors.toml
add applicability to lint name suggestion
````
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-docs Area: documentation for any part of the project, including the compiler, standard library, and tools E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants