Skip to content

Commit 9190e96

Browse files
committed
Adjust clippy tests with new rustc help suggestion for lints
1 parent efbe445 commit 9190e96

File tree

751 files changed

+838
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

751 files changed

+838
-0
lines changed

src/tools/clippy/tests/ui-toml/absolute_paths/absolute_paths.allow_crates.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | std::f32::MAX;
55
| ^^^^^^^^^^^^^
66
|
77
= note: `-D clippy::absolute-paths` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::absolute_paths)]`
89

910
error: consider bringing this path into scope with the `use` keyword
1011
--> $DIR/absolute_paths.rs:41:5

src/tools/clippy/tests/ui-toml/absolute_paths/absolute_paths.disallow_crates.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | std::f32::MAX;
55
| ^^^^^^^^^^^^^
66
|
77
= note: `-D clippy::absolute-paths` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::absolute_paths)]`
89

910
error: consider bringing this path into scope with the `use` keyword
1011
--> $DIR/absolute_paths.rs:41:5

src/tools/clippy/tests/ui-toml/allow_mixed_uninlined_format_args/uninlined_format_args.stderr

+2
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | println!("val='{}'", local_i32);
55
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
66
|
77
= note: `-D clippy::uninlined-format-args` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::uninlined_format_args)]`
89
help: change this to
910
|
1011
LL - println!("val='{}'", local_i32);
@@ -30,6 +31,7 @@ LL | println!("Hello {} is {:.*}", "x", local_i32, local_f64);
3031
| ^^^
3132
|
3233
= note: `-D clippy::print-literal` implied by `-D warnings`
34+
= help: to override `-D warnings` add `#[allow(clippy::print_literal)]`
3335
help: try
3436
|
3537
LL - println!("Hello {} is {:.*}", "x", local_i32, local_f64);

src/tools/clippy/tests/ui-toml/arithmetic_side_effects_allowed/arithmetic_side_effects_allowed.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | let _ = Baz + Baz;
55
| ^^^^^^^^^
66
|
77
= note: `-D clippy::arithmetic-side-effects` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::arithmetic_side_effects)]`
89

910
error: arithmetic operation that can potentially result in unexpected side-effects
1011
--> $DIR/arithmetic_side_effects_allowed.rs:80:13

src/tools/clippy/tests/ui-toml/array_size_threshold/array_size_threshold.stderr

+2
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ LL | const ABOVE: [u8; 11] = [0; 11];
77
| help: make this a static item: `static`
88
|
99
= note: `-D clippy::large-const-arrays` implied by `-D warnings`
10+
= help: to override `-D warnings` add `#[allow(clippy::large_const_arrays)]`
1011

1112
error: allocating a local array larger than 10 bytes
1213
--> $DIR/array_size_threshold.rs:4:25
@@ -16,6 +17,7 @@ LL | const ABOVE: [u8; 11] = [0; 11];
1617
|
1718
= help: consider allocating on the heap with `vec![0; 11].into_boxed_slice()`
1819
= note: `-D clippy::large-stack-arrays` implied by `-D warnings`
20+
= help: to override `-D warnings` add `#[allow(clippy::large_stack_arrays)]`
1921

2022
error: allocating a local array larger than 10 bytes
2123
--> $DIR/array_size_threshold.rs:8:17

src/tools/clippy/tests/ui-toml/await_holding_invalid_type/await_holding_invalid_type.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ LL | let _x = String::from("hello");
66
|
77
= note: strings are bad (from clippy.toml)
88
= note: `-D clippy::await-holding-invalid-type` implied by `-D warnings`
9+
= help: to override `-D warnings` add `#[allow(clippy::await_holding_invalid_type)]`
910

1011
error: `std::net::Ipv4Addr` may not be held across an `await` point per `clippy.toml`
1112
--> $DIR/await_holding_invalid_type.rs:10:9

src/tools/clippy/tests/ui-toml/conf_deprecated_key/conf_deprecated_key.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ LL | fn cognitive_complexity() {
1818
|
1919
= help: you could split it up into multiple smaller functions
2020
= note: `-D clippy::cognitive-complexity` implied by `-D warnings`
21+
= help: to override `-D warnings` add `#[allow(clippy::cognitive_complexity)]`
2122

2223
error: aborting due to previous error; 2 warnings emitted
2324

src/tools/clippy/tests/ui-toml/dbg_macro/dbg_macro.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | if let Some(n) = dbg!(n.checked_sub(4)) { n } else { n }
55
| ^^^^^^^^^^^^^^^^^^^^^^
66
|
77
= note: `-D clippy::dbg-macro` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::dbg_macro)]`
89
help: remove the invocation before committing it to a version control system
910
|
1011
LL | if let Some(n) = n.checked_sub(4) { n } else { n }

src/tools/clippy/tests/ui-toml/disallowed_macros/disallowed_macros.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | println!("one");
55
| ^^^^^^^^^^^^^^^
66
|
77
= note: `-D clippy::disallowed-macros` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::disallowed_macros)]`
89

910
error: use of a disallowed macro `std::println`
1011
--> $DIR/disallowed_macros.rs:11:5

src/tools/clippy/tests/ui-toml/disallowed_names_append/disallowed_names.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | let foo = "bar";
55
| ^^^
66
|
77
= note: `-D clippy::disallowed-names` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::disallowed_names)]`
89

910
error: use of a disallowed/placeholder name `ducks`
1011
--> $DIR/disallowed_names.rs:7:9

src/tools/clippy/tests/ui-toml/disallowed_names_replace/disallowed_names.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | let ducks = ["quack", "quack"];
55
| ^^^^^
66
|
77
= note: `-D clippy::disallowed-names` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::disallowed_names)]`
89

910
error: aborting due to previous error
1011

src/tools/clippy/tests/ui-toml/doc_valid_idents_append/doc_markdown.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | /// TestItemThingyOfCoolness might sound cool but is not on the list and sh
55
| ^^^^^^^^^^^^^^^^^^^^^^^^
66
|
77
= note: `-D clippy::doc-markdown` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::doc_markdown)]`
89
help: try
910
|
1011
LL | /// `TestItemThingyOfCoolness` might sound cool but is not on the list and should be linted.

src/tools/clippy/tests/ui-toml/doc_valid_idents_replace/doc_markdown.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | /// OAuth and LaTeX are inside Clippy's default list.
55
| ^^^^^
66
|
77
= note: `-D clippy::doc-markdown` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::doc_markdown)]`
89
help: try
910
|
1011
LL | /// `OAuth` and LaTeX are inside Clippy's default list.

src/tools/clippy/tests/ui-toml/excessive_nesting/excessive_nesting.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ LL | let w = { 3 };
66
|
77
= help: try refactoring your code to minimize nesting
88
= note: `-D clippy::excessive-nesting` implied by `-D warnings`
9+
= help: to override `-D warnings` add `#[allow(clippy::excessive_nesting)]`
910

1011
error: this block is too nested
1112
--> $DIR/excessive_nesting.rs:67:17

src/tools/clippy/tests/ui-toml/expect_used/expect_used.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ LL | let _ = opt.expect("");
66
|
77
= note: if this value is `None`, it will panic
88
= note: `-D clippy::expect-used` implied by `-D warnings`
9+
= help: to override `-D warnings` add `#[allow(clippy::expect_used)]`
910

1011
error: used `expect()` on a `Result` value
1112
--> $DIR/expect_used.rs:12:13

src/tools/clippy/tests/ui-toml/fn_params_excessive_bools/test.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ LL | fn g(_: bool, _: bool) {}
66
|
77
= help: consider refactoring bools into two-variant enums
88
= note: `-D clippy::fn-params-excessive-bools` implied by `-D warnings`
9+
= help: to override `-D warnings` add `#[allow(clippy::fn_params_excessive_bools)]`
910

1011
error: aborting due to previous error
1112

src/tools/clippy/tests/ui-toml/functions_maxlines/test.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ LL | | }
88
| |_^
99
|
1010
= note: `-D clippy::too-many-lines` implied by `-D warnings`
11+
= help: to override `-D warnings` add `#[allow(clippy::too_many_lines)]`
1112

1213
error: this function has too many lines (4/1)
1314
--> $DIR/test.rs:25:1

src/tools/clippy/tests/ui-toml/ifs_same_cond/ifs_same_cond.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ note: same as this
1010
LL | if x.get() {
1111
| ^^^^^^^
1212
= note: `-D clippy::ifs-same-cond` implied by `-D warnings`
13+
= help: to override `-D warnings` add `#[allow(clippy::ifs_same_cond)]`
1314

1415
error: aborting due to previous error
1516

src/tools/clippy/tests/ui-toml/large_futures/large_futures.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | should_warn().await;
55
| ^^^^^^^^^^^^^ help: consider `Box::pin` on it: `Box::pin(should_warn())`
66
|
77
= note: `-D clippy::large-futures` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::large_futures)]`
89

910
error: aborting due to previous error
1011

src/tools/clippy/tests/ui-toml/large_include_file/large_include_file.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ LL | const TOO_BIG_INCLUDE_BYTES: &[u8; 654] = include_bytes!("too_big.txt");
66
|
77
= note: the configuration allows a maximum size of 600 bytes
88
= note: `-D clippy::large-include-file` implied by `-D warnings`
9+
= help: to override `-D warnings` add `#[allow(clippy::large_include_file)]`
910
= note: this error originates in the macro `include_bytes` (in Nightly builds, run with -Z macro-backtrace for more info)
1011

1112
error: attempted to include a large file

src/tools/clippy/tests/ui-toml/lint_decimal_readability/test.stderr

+2
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | let _fail1 = 100_200_300.123456789;
55
| ^^^^^^^^^^^^^^^^^^^^^ help: consider: `100_200_300.123_456_789`
66
|
77
= note: `-D clippy::inconsistent-digit-grouping` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::inconsistent_digit_grouping)]`
89

910
error: long literal lacking separators
1011
--> $DIR/test.rs:22:18
@@ -13,6 +14,7 @@ LL | let _fail2 = 100200300.300200100;
1314
| ^^^^^^^^^^^^^^^^^^^ help: consider: `100_200_300.300_200_100`
1415
|
1516
= note: `-D clippy::unreadable-literal` implied by `-D warnings`
17+
= help: to override `-D warnings` add `#[allow(clippy::unreadable_literal)]`
1618

1719
error: aborting due to 2 previous errors
1820

src/tools/clippy/tests/ui-toml/min_ident_chars/min_ident_chars.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | use extern_types::Aaa;
55
| ^^^
66
|
77
= note: `-D clippy::min-ident-chars` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::min_ident_chars)]`
89

910
error: this ident is too short (3 <= 3)
1011
--> $DIR/min_ident_chars.rs:10:5

src/tools/clippy/tests/ui-toml/min_rust_version/min_rust_version.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | let _: Option<u64> = Some(&16).map(|b| *b);
55
| ^^^^^^^^^^^^^^^^^^^^^ help: consider calling the dedicated `cloned` method: `Some(&16).cloned()`
66
|
77
= note: `-D clippy::map-clone` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::map_clone)]`
89

910
error: aborting due to previous error
1011

src/tools/clippy/tests/ui-toml/missing_enforced_import_rename/conf_missing_enforced_import_rename.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | use std::process::{exit as wrong_exit, Child as Kid};
55
| ^^^^^^^^^^^^^^^^^^ help: try: `exit as goodbye`
66
|
77
= note: `-D clippy::missing-enforced-import-renames` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::missing_enforced_import_renames)]`
89

910
error: this import should be renamed
1011
--> $DIR/conf_missing_enforced_import_rename.rs:6:1

src/tools/clippy/tests/ui-toml/module_inception/module_inception.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ LL | | }
77
| |_________^
88
|
99
= note: `-D clippy::module-inception` implied by `-D warnings`
10+
= help: to override `-D warnings` add `#[allow(clippy::module_inception)]`
1011

1112
error: module has the same name as its containing module
1213
--> $DIR/module_inception.rs:11:5

src/tools/clippy/tests/ui-toml/nonstandard_macro_braces/conf_nonstandard_macro_braces.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | let _ = vec! {1, 2, 3};
55
| ^^^^^^^^^^^^^^ help: consider writing: `vec![1, 2, 3]`
66
|
77
= note: `-D clippy::nonstandard-macro-braces` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::nonstandard_macro_braces)]`
89

910
error: use of irregular braces for `format!` macro
1011
--> $DIR/conf_nonstandard_macro_braces.rs:44:13

src/tools/clippy/tests/ui-toml/print_macro/print_macro.stderr

+2
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | print!("{n}");
55
| ^^^^^^^^^^^^^
66
|
77
= note: `-D clippy::print-stdout` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::print_stdout)]`
89

910
error: use of `eprint!`
1011
--> $DIR/print_macro.rs:7:5
@@ -13,6 +14,7 @@ LL | eprint!("{n}");
1314
| ^^^^^^^^^^^^^^
1415
|
1516
= note: `-D clippy::print-stderr` implied by `-D warnings`
17+
= help: to override `-D warnings` add `#[allow(clippy::print_stderr)]`
1618

1719
error: aborting due to 2 previous errors
1820

src/tools/clippy/tests/ui-toml/pub_crate_missing_docs/pub_crate_missing_doc.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | pub(crate) fn crate_no_docs() {}
55
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
66
|
77
= note: `-D clippy::missing-docs-in-private-items` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::missing_docs_in_private_items)]`
89

910
error: missing documentation for a function
1011
--> $DIR/pub_crate_missing_doc.rs:15:5

src/tools/clippy/tests/ui-toml/semicolon_block/both.stderr

+2
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | { unit_fn_block(); }
55
| ^^^^^^^^^^^^^^^^^^^^
66
|
77
= note: `-D clippy::semicolon-outside-block` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::semicolon_outside_block)]`
89
help: put the `;` here
910
|
1011
LL - { unit_fn_block(); }
@@ -33,6 +34,7 @@ LL | | };
3334
| |______^
3435
|
3536
= note: `-D clippy::semicolon-inside-block` implied by `-D warnings`
37+
= help: to override `-D warnings` add `#[allow(clippy::semicolon_inside_block)]`
3638
help: put the `;` here
3739
|
3840
LL ~ unit_fn_block();

src/tools/clippy/tests/ui-toml/semicolon_block/semicolon_inside_block.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ LL | | };
88
| |______^
99
|
1010
= note: `-D clippy::semicolon-inside-block` implied by `-D warnings`
11+
= help: to override `-D warnings` add `#[allow(clippy::semicolon_inside_block)]`
1112
help: put the `;` here
1213
|
1314
LL ~ unit_fn_block();

src/tools/clippy/tests/ui-toml/semicolon_block/semicolon_outside_block.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | { unit_fn_block(); }
55
| ^^^^^^^^^^^^^^^^^^^^
66
|
77
= note: `-D clippy::semicolon-outside-block` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::semicolon_outside_block)]`
89
help: put the `;` here
910
|
1011
LL - { unit_fn_block(); }

src/tools/clippy/tests/ui-toml/strict_non_send_fields_in_send_ty/test.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ LL | rc_is_not_send: Rc<String>,
1111
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
1212
= help: use a thread-safe type that implements `Send`
1313
= note: `-D clippy::non-send-fields-in-send-ty` implied by `-D warnings`
14+
= help: to override `-D warnings` add `#[allow(clippy::non_send_fields_in_send_ty)]`
1415

1516
error: some fields in `MultiField<T>` are not safe to be sent to another thread
1617
--> $DIR/test.rs:19:1

src/tools/clippy/tests/ui-toml/struct_excessive_bools/test.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ LL | | }
88
|
99
= help: consider using a state machine or refactoring bools into two-variant enums
1010
= note: `-D clippy::struct-excessive-bools` implied by `-D warnings`
11+
= help: to override `-D warnings` add `#[allow(clippy::struct_excessive_bools)]`
1112

1213
error: aborting due to previous error
1314

src/tools/clippy/tests/ui-toml/suppress_lint_in_const/test.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ LL | x[index];
1818
|
1919
= help: consider using `.get(n)` or `.get_mut(n)` instead
2020
= note: `-D clippy::indexing-slicing` implied by `-D warnings`
21+
= help: to override `-D warnings` add `#[allow(clippy::indexing_slicing)]`
2122

2223
error: indexing may panic
2324
--> $DIR/test.rs:46:5

src/tools/clippy/tests/ui-toml/toml_disallow/conf_french_disallowed_name.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | fn test(toto: ()) {}
55
| ^^^^
66
|
77
= note: `-D clippy::disallowed-names` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::disallowed_names)]`
89

910
error: use of a disallowed/placeholder name `toto`
1011
--> $DIR/conf_french_disallowed_name.rs:9:9

src/tools/clippy/tests/ui-toml/toml_disallowed_methods/conf_disallowed_methods.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | let re = Regex::new(r"ab.*c").unwrap();
55
| ^^^^^^^^^^^^^^^^^^^^
66
|
77
= note: `-D clippy::disallowed-methods` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::disallowed_methods)]`
89

910
error: use of a disallowed method `regex::Regex::is_match`
1011
--> $DIR/conf_disallowed_methods.rs:36:5

src/tools/clippy/tests/ui-toml/toml_disallowed_types/conf_disallowed_types.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | use std::sync::atomic::AtomicU32;
55
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
66
|
77
= note: `-D clippy::disallowed-types` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::disallowed_types)]`
89

910
error: `std::time::Instant` is not allowed according to config
1011
--> $DIR/conf_disallowed_types.rs:8:1

src/tools/clippy/tests/ui-toml/toml_trivially_copy/test.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | fn bad(x: &u16, y: &Foo) {}
55
| ^^^^ help: consider passing by value instead: `u16`
66
|
77
= note: `-D clippy::trivially-copy-pass-by-ref` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::trivially_copy_pass_by_ref)]`
89

910
error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
1011
--> $DIR/test.rs:15:20

src/tools/clippy/tests/ui-toml/undocumented_unsafe_blocks/undocumented_unsafe_blocks.stderr

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ LL | /* Safety: */ unsafe {}
66
|
77
= help: consider adding a safety comment on the preceding line
88
= note: `-D clippy::undocumented-unsafe-blocks` implied by `-D warnings`
9+
= help: to override `-D warnings` add `#[allow(clippy::undocumented_unsafe_blocks)]`
910

1011
error: unsafe block missing a safety comment
1112
--> $DIR/undocumented_unsafe_blocks.rs:267:5
@@ -251,6 +252,7 @@ help: consider removing the safety comment
251252
LL | // SAFETY:
252253
| ^^^^^^^^^^
253254
= note: `-D clippy::unnecessary-safety-comment` implied by `-D warnings`
255+
= help: to override `-D warnings` add `#[allow(clippy::unnecessary_safety_comment)]`
254256

255257
error: unsafe impl missing a safety comment
256258
--> $DIR/undocumented_unsafe_blocks.rs:473:5

src/tools/clippy/tests/ui-toml/unwrap_used/unwrap_used.stderr

+2
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | let _ = boxed_slice.get(1).unwrap();
55
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `&boxed_slice[1]`
66
|
77
= note: `-D clippy::get-unwrap` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::get_unwrap)]`
89

910
error: used `unwrap()` on an `Option` value
1011
--> $DIR/unwrap_used.rs:38:17
@@ -15,6 +16,7 @@ LL | let _ = boxed_slice.get(1).unwrap();
1516
= note: if this value is `None`, it will panic
1617
= help: consider using `expect()` to provide a better panic message
1718
= note: `-D clippy::unwrap-used` implied by `-D warnings`
19+
= help: to override `-D warnings` add `#[allow(clippy::unwrap_used)]`
1820

1921
error: called `.get().unwrap()` on a slice. Using `[]` is more clear and more concise
2022
--> $DIR/unwrap_used.rs:39:17

src/tools/clippy/tests/ui-toml/upper_case_acronyms_aggressive/upper_case_acronyms.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | struct HTTPResponse; // not linted by default, but with cfg option
55
| ^^^^^^^^^^^^ help: consider making the acronym lowercase, except the initial letter: `HttpResponse`
66
|
77
= note: `-D clippy::upper-case-acronyms` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::upper_case_acronyms)]`
89

910
error: name `NS` contains a capitalized acronym
1011
--> $DIR/upper_case_acronyms.rs:8:5

src/tools/clippy/tests/ui-toml/vec_box_sized/test.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ LL | struct Foo(Vec<Box<u8>>);
55
| ^^^^^^^^^^^^ help: try: `Vec<u8>`
66
|
77
= note: `-D clippy::vec-box` implied by `-D warnings`
8+
= help: to override `-D warnings` add `#[allow(clippy::vec_box)]`
89

910
error: `Vec<T>` is already on the heap, the boxing is unnecessary
1011
--> $DIR/test.rs:10:12

src/tools/clippy/tests/ui/absurd-extreme-comparisons.stderr

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ LL | u <= 0;
66
|
77
= help: because `0` is the minimum value for this type, the case where the two sides are not equal never occurs, consider using `u == 0` instead
88
= note: `-D clippy::absurd-extreme-comparisons` implied by `-D warnings`
9+
= help: to override `-D warnings` add `#[allow(clippy::absurd_extreme_comparisons)]`
910

1011
error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
1112
--> $DIR/absurd-extreme-comparisons.rs:16:5

0 commit comments

Comments
 (0)