-
Notifications
You must be signed in to change notification settings - Fork 13.1k
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
Ignore comments in tidy-filelength #87462
Ignore comments in tidy-filelength #87462
Conversation
(rust-highfive has picked a reviewer for you, use r? to override) |
|
It's not just about being short, it's about readability. Comments don't add complexity to the file. EDIT: I misinterpreted your comment as well 😄 |
Hm, @petrochenkov - I don't think this PR changes behavior for line length checking. Line lengths are already ignored for most of the codebase: we avoid nagging people in files under rustfmt control. Whether that was the right call, I'm not sure, but this PR seems unrelated to that topic. This PR seems to solely intend to avoid nagging on long files if the length is primarily due to comment lines. I think that's an interesting proposal, but as I personally don't really typically find file length an impediment or good proxy, I'm not sure I'm the right reviewer. Regardless, for issues like this I think it's likely best to circulate them more widely; I would suggest a T-compiler MCP. Cc @rust-lang/libs-contributors as well, since many of our longer files are such due to extensive documentation in std, core, etc. |
Ah, ok, sorry for misinterpreting the changes. |
Discussed during T-compiler meeting; no objections to just moving ahead were raised. Seems trivial to re-add if opposition is raised. An additional point of discussion was the check might be dropped entirely, but that can also be proposed in the future with little trouble. It's possible being happier to ignore the lint is preferable, though, in cases where it is causing pain for no good reason. @bors r+ |
📌 Commit 3171bd5 has been approved by |
…-comment, r=Mark-Simulacrum Ignore comments in tidy-filelength Ref rust-lang#60302 (comment)
☀️ Test successful - checks-actions |
Ref #60302 (comment)