Donald Robertson
fe8c9d5965
Ensuring correct lint message is output for Option and Result type
2018-06-04 19:43:03 +01:00
Donald Robertson
2b36017bad
Removing unnecessary allow
2018-06-04 19:43:03 +01:00
Donald Robertson
05c1ccebaf
Warn if non-trivial work is done inside .expect
...
- added tests for common usages of format and as_str arguments to expect
- added tests for usages of Option and Result types
- given performance impact of passing non literal expressions to expect, added to perf group
2018-06-04 19:43:03 +01:00
Mateusz Mikuła
424a33720d
Run rustfix
2018-05-30 10:15:50 +02:00
Philipp Hansch
6eb07cc5b6
Fix ICE for issue 2594
2018-05-17 21:12:06 +02:00
Philipp Hansch
26b48bbdfc
Rustup to 2018-05-13
2018-05-13 10:44:57 +02:00
Philipp Hansch
665cf96221
Rustup to 2018-05-11
2018-05-11 09:53:21 +02:00
Michael Wright
fcabbeb251
Fix clippy warning
...
Fix too_many_arguments on `check_general_case` by allowing it. I can't
see a sensible way of grouping the parameters.
2018-04-02 07:04:43 +02:00
Michael Wright
89cb053146
Fix clippy warning
...
Fix cyclomatic_complexity warning on `check_expr` by allowing it. This
is preferable to increasing the threshold every time the method changes.
2018-04-02 07:04:39 +02:00
Oliver Schneider
c1bbc173da
Address review comments
2018-03-29 13:41:53 +02:00
Oliver Schneider
d6344c47e3
Categorize all the lints!
2018-03-28 15:24:26 +02:00
Michael Wright
70d8f85e7e
Minor refactoring (walk_ptrs_ty_depth)
...
Replace `walk_ptrs_ty_depth` with `walk_ptrs_ty` when the depth value is
ignored.
2018-03-21 20:10:10 +02:00
Mateusz Mikuła
cfb9b982c5
Apply clippy suggestions
...
Signed-off-by: Mateusz Mikuła <mati865@gmail.com>
2018-03-16 10:54:49 +01:00
Oliver Schneider
f7b2578aea
Update to rustc master
2018-03-13 11:38:21 +01:00
Bruce Mitchener
769a1d9b6c
Fix single_char_pattern for \n, \t, etc.
...
Single characters that are escaped weren't being searched / replaced
correctly in the hint string, so it was saying to replace, say,
`"\n"` with `"\n"` rather than `'\n'`.
2018-03-02 22:00:01 +07:00
bootandy
aef07e3392
Do not pass Span by reference
2018-02-22 10:11:20 -05:00
bootandy
a7c97256dc
Stop unwanted newlines being applied on unwrap_or
2018-02-21 11:29:08 -05:00
bootandy
c708154c16
Simplify creation of span_replace_word
...
Part of unwrap_or test
2018-02-20 12:38:20 -05:00
bootandy
941e062fd4
Fix: point to correct problem part of code
...
Fix span so it no longer contains the whole train-wreck of code and only
points to the problem function (for the unwrap_or lint).
https://github.com/rust-lang-nursery/rust-clippy/issues/2422
Update ui test methods - it had several cases where the error message
span is now shorter
2018-02-19 12:14:53 -05:00
Seiichi Uchida
e40bc64f4f
Rustup to rustc 1.25.0-nightly ( 7d6e5b9da
2018-01-27)
2018-01-28 16:28:48 +09:00
Phil Ellison
29f8cea5fd
Use existing match_var function
2018-01-22 05:46:32 +00:00
Phil Ellison
2132e5c58c
Fix unnecessary_fold bug
2018-01-22 05:34:42 +00:00
Oliver Schneider
70302595a4
Merge branch 'master' of github.com:Manishearth/rust-clippy into fold_any
2018-01-19 12:10:24 +01:00
Phil Ellison
a324a2bc38
Fix typos
2018-01-17 21:54:09 +00:00
Phil Ellison
b73efad600
Add some reviewer comments
2018-01-17 21:06:16 +00:00
Phil Ellison
9806b31d53
Rename lint, improve documentation
2018-01-17 20:21:29 +00:00
Phil Ellison
1cac693bc7
Lint on folds implementing .all, .sum and .product
2018-01-17 19:12:44 +00:00
Phil Ellison
a64d19cc0e
Fix error span to play nicely with rustfix
2018-01-16 21:20:55 +00:00
Adam Lusch
f343cd22f6
Adds the missing turbofish
2018-01-14 20:19:55 -08:00
Adam Lusch
1615813960
Moves clone_on_ref_ptr
to be a restriction lint
...
Also updates the suggestion to include the full type (e.g. `Arc<Foo>::clone(&rc)`)
and adds a case using trait objects to the UI tests.
2018-01-14 19:58:09 -08:00
Phil Ellison
ad164939ed
Check that we're calling Iterator::fold
2018-01-14 20:04:34 +00:00
Phil Ellison
70a5535ffa
Address some review comments
2018-01-14 18:18:09 +00:00
Phil Ellison
360f2359d5
Fix name
2018-01-14 15:30:06 +00:00
Phil Ellison
7e833ea5ce
Add description
2018-01-14 10:07:41 +00:00
Phil Ellison
528be23c07
Move get_arg_name into utils
2018-01-14 10:05:01 +00:00
Phil Ellison
1feb9fd550
Tidy using if_chain and snippet function. Actually check that the initial fold value is false. Remove some unwraps
2018-01-14 09:30:08 +00:00
Phil Ellison
f6e56d2559
First pass at linting for .any expressed as a .fold
2018-01-14 08:27:53 +00:00
Manish Goregaokar
7e099903be
Update to handle GenericParam
...
introduced in https://github.com/rust-lang/rust/pull/45930
2017-12-21 20:54:49 -08:00
Oliver Schneider
7d7fef1690
Fix #1925
2017-11-30 10:55:06 +01:00
Oliver Schneider
299f1270a6
Rustup
2017-11-10 08:58:54 +01:00
topecongiro
a6c71e9c0d
Fix lines that exceed max width manually
2017-11-05 04:59:21 +09:00
topecongiro
7a06d312fd
Cargo fmt
2017-11-05 04:55:56 +09:00
cgm616
76e765aeda
Switch to new method of checking access
2017-11-02 23:53:48 -05:00
cgm616
ee289c9f88
Merge branch 'master' of github.com:rust-lang-nursery/rust-clippy
2017-11-02 22:57:07 -05:00
G. Endignoux
f0a1eff1c4
Start working on #1590
2017-10-30 13:08:09 +01:00
cgm616
85683bf07c
Fix mistake in merging
2017-10-28 13:23:05 -05:00
Manish Goregaokar
b0616df931
Merge branch 'pr-2140'
2017-10-28 14:04:25 -04:00
cgm616
d094f98f0b
Merge branch 'master' of github.com:rust-lang-nursery/rust-clippy
2017-10-28 12:55:16 -05:00
Alex Burka
41840ae3c4
mechanically swap if_let_chain -> if_chain
2017-10-23 15:18:02 -04:00
cgm616
0b0eb8ead6
Undo rustfmt changes unrelated to issue
2017-10-22 09:59:19 -04:00