Skip to content

Do not autofix comments containing bare CR #15175

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

samueltardieu
Copy link
Contributor

@samueltardieu samueltardieu commented Jun 29, 2025

When a bare CR is present in a four slashes comment, keep triggering the lint but do not issue a fix suggestion as bare CRs are not supported in doc comments. An extra note is added to the diagnostic to warn the user about it.

I have put the test in a separate file to make it clear that the bare CR is not a formatting error.

Fixes #15174

changelog: [four_forward_slashes]: warn about bare CR in comment, and do not propose invalid autofix

@rustbot
Copy link
Collaborator

rustbot commented Jun 29, 2025

r? @llogiq

rustbot has assigned @llogiq.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties label Jun 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties
Projects
None yet
Development

Successfully merging this pull request may close these issues.

four_forward_slashes does not know that doc comments cannot contain "bare CR"
3 participants