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

Fix a couple broken links to the reference from error messages. #42624

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/librustc_typeck/diagnostics.rs
Original file line number Diff line number Diff line change
@@ -240,7 +240,7 @@ trait_obj.method_two();
You can read more about trait objects in the Trait Object section of the
Reference:
https://doc.rust-lang.org/reference.html#trait-objects
https://doc.rust-lang.org/reference/types.html#trait-objects
"##,

E0034: r##"
@@ -851,7 +851,7 @@ optional namespacing), a dereference, an indexing expression or a field
reference.
More details can be found here:
https://doc.rust-lang.org/reference.html#lvalues-rvalues-and-temporaries
https://doc.rust-lang.org/reference/expressions.html#lvalues-rvalues-and-temporaries
Copy link
Member

Choose a reason for hiding this comment

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

Longer than 80 characters. It fails tidy test.

Copy link
Member Author

Choose a reason for hiding this comment

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

How do I fix this? Should I have tidy ignore this file?

Copy link
Member

Choose a reason for hiding this comment

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

I believe the correct fix here is to change https://github.com/rust-lang/rust/blob/master/src/tools/tidy/src/style.rs#L55 to properly handle URLs in non-comment lines. I haven't looked into the exact fix, though. It might be non-trivial.

Now, we can go further. Here are some erroneous code examples: