-
-
Notifications
You must be signed in to change notification settings - Fork 14.5k
chore: clearify tidy's error message #152202
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
Conversation
|
r? @Zalathar rustbot has assigned @Zalathar. Use Why was this reviewer chosen?The reviewer was selected based on:
|
src/tools/tidy/src/ui_tests.rs
Outdated
| { | ||
| check.error(format!( | ||
| "file `tests/{stripped_path}` must begin with a descriptive name, consider `{{reason}}-issue-{issue_n}.rs`", | ||
| "the name of the file `tests/{stripped_path}` must begin with a descriptive prefix, consider `{{reason}}-issue-{issue_n}.rs`", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"prefix" is misleading as it is not essential that it includes issue-{NN} as part of the filename and thus there is no "prefix" if it's the entire thing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what do you think would be a good error here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mm. If I had my druthers, it would be "test filenames should be descriptive instead of context-free integers", but that's probably too snarky.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
how about this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
|
r? me @bors r+ rollup |
chore: clearify tidy's error message it took me a while to realize this error was due to the name of the file, not the file's content
…uwer Rollup of 13 pull requests Successful merges: - #152191 (Convert to inline diagnostics in `rustc_hir_analysis`) - #149329 (Mark match arms in try and for as being from desugarings.) - #151474 (Minor structural improvements) - #152107 (Convert to inline diagnostics in `rustc_borrowck`) - #152117 (Convert to inline diagnostics in `rustc_trait_selection`) - #152136 (Consolidate type const checks on `tcx.is_type_const`) - #152140 (Hard code the error code registry for custom drivers) - #152155 (Fix typos in riscv64a23-unknown-linux-gnu.md) - #152170 (Port `rustc_effective_visibility` to the new attribute parser) - #152182 (update compiler stable backport zulip msg) - #152184 (Port rustc_abi to the attribute parser) - #152195 (update openmp/offload builds to LLVM 22, Part 1) - #152202 (chore: clearify tidy's error message) Failed merges: - #151744 (fix refining_impl_trait suggestion with return_type_notation) - #152212 (Port some attributes to the attr parser)
Rollup merge of #152202 - nyurik:better-msg, r=jieyouxu chore: clearify tidy's error message it took me a while to realize this error was due to the name of the file, not the file's content
it took me a while to realize this error was due to the name of the file, not the file's content