Jason Newcomb
3db0e00bdc
Lint shadow_*
lints in anon const blocks
2022-07-05 15:21:27 -04:00
Jason Newcomb
48bcc1d95f
Move let_unit_value
back into style
2022-04-14 21:33:32 -04:00
Elliot Bobrow
1b67aa74bd
fix shadow_reuse
false negative for if let bindings
2021-12-24 13:20:40 -08:00
surechen
846c0bef07
Fixes #7915
...
Fix shadow_same's positive false for async function's params:
Example Code:
```rust
#![deny(clippy::shadow_same)]
pub async fn foo(_a: i32) {
}
```
Output:
```
error: `_a` is shadowed by itself in `_a
```
Hir:
```rust
pub async fn foo(_a: i32)
->
/*impl Trait*/ #[lang = "from_generator"](move |mut _task_context|
{
let _a = _a;
{ let _t = { }; _t }
})
```
Skip checking async function's params.
changelog: Fix shadow_same's positive false for async function's params
2021-11-21 14:28:44 +08:00
dswij
64f8b9d0ea
Make shadow_reuse
suggestion less verbose
2021-10-07 16:50:13 +08:00
Cameron Steffen
8c0e4d5ccf
Rewrite shadow lint
2021-09-30 14:07:58 -05:00
Cameron Steffen
99861c0e88
Remove initialization note from shadow lint
2021-09-30 13:54:30 -05:00
Tim Nielens
07b2da884c
add lint less_concise_than_option_unwrap_or
2020-10-14 22:16:48 +02:00
Leo Meira Vital
a0640457a9
Removing snippet from SHADOW_UNRELATED message.
2020-07-15 11:12:38 -03:00
Andre Bogus
cc622608db
new lints around #[must_use]
fns
...
`must_use_unit` lints unit-returning functions with a `#[must_use]`
attribute, suggesting to remove it.
`double_must_use` lints functions with a plain `#[must_use]`
attribute, but which return a type which is already `#[must_use]`,
so the attribute has no benefit.
`must_use_candidate` is a pedantic lint that lints functions and
methods that return some non-unit type that is not already
`#[must_use]` and suggests to add the annotation.
2019-10-14 12:09:04 +02:00
Manish Goregaokar
982c51e769
arm.pats -> arm.pat
2019-09-25 12:52:16 -07:00
Philipp Hansch
38d4ac7cea
Remove all copyright license headers
...
Discussion previously happened in https://github.com/rust-lang/rust/pull/43498
2019-01-08 21:46:39 +01:00
flip1995
d2dbd0b8a5
Update *.stderr files
2018-12-28 12:41:12 +01:00
Matthias Krüger
7bcc2cd9c8
update test stderr
2018-12-10 08:22:07 +01:00
Manish Goregaokar
e9c025ea70
Add license header to Rust files
2018-10-06 09:43:08 -07:00
flip1995
e9af09c274
Adapt the *.stderr files of the ui-tests to the tool_lints
2018-08-29 11:08:29 -07:00
Oliver Schneider
4f21b5b112
Update changed ui tests
2018-01-17 14:44:40 +01:00
sinkuu
9ebc30cb0c
rustc 1.22.0-nightly (150b625a0 2017-10-08)
2017-10-09 22:49:54 +09:00
Oliver Schneider
50ffaca4c9
Reduce the hackiness of cargo-clippy
2017-10-03 12:07:24 +02:00
Oliver Schneider
d6fc34fd08
Update for rustc output changes
2017-08-14 09:54:47 +02:00
Oliver Schneider
74c776585c
Move all our tests back to ui tests
2017-08-01 17:54:21 +02:00
Oliver Schneider
4465bc3e3f
Make most tests an example
so we can run them one by one
2017-05-17 14:19:44 +02:00
Oliver Schneider
1f2c97a291
remove all //~ from tests
2017-02-08 14:58:07 +01:00
Oliver Schneider
fd1351f6e3
rustup and compile-fail -> ui test move
2017-02-07 21:05:30 +01:00