josephDunne
aa819b7748
Update rust-clippy to rustc 1.9.0-nightly (d5a91e695 2016-03-26)
...
move cfg, infer, traits and ty from middle to top-level
move middle::subst into middle::ty
track the extern-crate def-id rather than path (rustc ab9b844)
2016-03-27 20:24:10 +01:00
Oliver 'ker' Schneider
d65953330b
rustup const eval changes
2016-03-15 20:09:53 +01:00
mcarton
9cfc6124a3
Improve the MATCH_REF_PATS suggestions
2016-03-09 16:22:31 +01:00
mcarton
3ab4914a29
Handle the new TryDesugar variant
2016-03-09 16:10:24 +01:00
Manish Goregaokar
bd45cfd273
rustfmt
2016-02-29 21:35:51 +05:30
Oliver Schneider
3b7720f992
lint ! and != in if expressions with else branches
2016-02-29 12:34:48 +01:00
mcarton
b753e77cbe
Rustfmt and sort all use
items
2016-02-24 17:38:57 +01:00
quininer kel
35a48bf512
fix nightly
...
9b40e1e5b3
2016-02-19 04:16:39 +08:00
Oliver 'ker' Schneider
3f34b65747
fix nightly breakage
2016-02-12 18:35:44 +01:00
mcarton
83a82a1d86
Remove redundancy in lint documentation
...
The default level is always given in the declare_lint! macro, no need to
add it inconsistently in the documentation.
2016-02-06 00:41:54 +01:00
mcarton
13f245f6c9
Fix util/update_wiki.py warnings and be consistent in declare_lint! invocations
2016-02-06 00:13:29 +01:00
mcarton
c0d2fdc723
Partially apply rustfmt
2016-02-02 22:34:20 +01:00
Oliver 'ker' Schneider
d6c0435c81
lint on single match expressions with a value in the else path
2016-02-01 11:29:03 +01:00
mcarton
3a39bbaf74
Small cleanup
2016-01-29 22:31:17 +01:00
mcarton
44daa8bd72
Use span_suggestion in matches lints
...
Ref #442
2016-01-13 13:17:11 +01:00
mcarton
9f641a1009
Add known enums to SINGLE_MATCH
2016-01-13 01:19:27 +01:00
Manish Goregaokar
c9342d0121
fmt clippy
2016-01-04 09:56:12 +05:30
mcarton
542685dad1
Merge branch 'master' of https://github.com/Manishearth/rust-clippy into #471
2016-01-02 19:36:45 +01:00
Manish Goregaokar
32cf6e32f6
Improve documentation on match_ref_pats ( fixes #532 )
2016-01-02 16:36:17 +05:30
mcarton
0fa8481ba3
Put tests in tests folder
2015-12-23 17:48:41 +01:00
mcarton
2fd3093395
Only run MATCH_OVERLAPPING_ARM on integral matches
2015-12-23 11:25:44 +01:00
mcarton
90efb7b76d
Fix typo
2015-12-23 11:25:32 +01:00
mcarton
1aa3956b8a
Update README
2015-12-23 02:45:17 +01:00
mcarton
0c8de9ed52
Split MatchPass::check_expr for dogfood
2015-12-23 02:42:01 +01:00
mcarton
3373ea43c0
Consider literal patterns in MATCH_OVERLAPPING_ARM
2015-12-23 02:42:01 +01:00
mcarton
7216e83189
Implement #471
2015-12-23 02:42:01 +01:00
Oliver Schneider
cc1d696cb9
fix fallout from CC improvements
2015-12-14 14:30:09 +01:00
llogiq
5bbc1427fd
added wiki comments + wiki-generating python script
2015-12-11 01:22:27 +01:00
Oliver Schneider
617c820e6b
compute cyclomatic complexity (adjusted to not punish Rust's match
)
2015-12-03 16:41:55 +01:00
Manish Goregaokar
ba59ed05e3
Rust upgrade to rustc 1.6.0-nightly (52d95e644 2015-11-30)
2015-11-30 23:16:28 +05:30
Seo Sanghyeon
b1a0abe404
Don't panic
2015-11-25 13:57:50 +09:00
Seo Sanghyeon
746991572f
Extend match_ref_pats to desugared matches
2015-11-25 02:47:17 +09:00
Manish Goregaokar
c7df4bd000
Rustup to rustc 1.6.0-nightly (effcd2965 2015-11-04)
...
fixes #437
2015-11-05 08:20:28 +05:30
wartman4404
8e4c2171d2
Don't show single_match if match_bool also applies
2015-10-28 22:26:48 -05:00
Andre Bogus
da82e2d3ba
added code snippet help to match_bool
2015-10-21 08:24:56 +02:00
Vikas Kumar
5e78fbbf57
Fixups from review comments
...
1. Moved common check `in_external_macro` to the top of function from inside each
conditionals.
2. Inlined `is_bool_expr` call
2015-10-20 11:26:54 -07:00
Vikas Kumar
2951b70d15
Match on bool should be replaced with if..else block
...
1. Added another conditional in `check_expr` impl to lint if match expr
is a bool.
2. Test cases.
2015-10-20 10:18:48 -07:00
Ravi Shankar
185da55263
extending while_let to warn for more statements
2015-09-29 20:26:34 +05:30
Manish Goregaokar
f4da7d09d2
Upgrade Rust to rustc 1.5.0-nightly (cff041170 2015-09-17)
...
LintPass was split and ExprParen was removed from the HIR
Fixes #338
2015-09-19 08:23:04 +05:30
Georg Brandl
e3ee87965e
ref matches: false positive with only wildcard pattern match ( fixes #335 )
2015-09-17 07:25:08 +02:00
Manish Goregaokar
eca185438b
Update rust to 0efb9dab8c7c07fa28e9df0eccc5c07ea3c17fbb (HIR+lints, Thu Sep 3 18:59:56 2015 +0530)
...
fixes #294
2015-09-03 23:12:19 +05:30
Georg Brandl
846c164709
don't say "did you mean to" - use the standard "consider..."
...
"Did you mean to ..." sounds a bit condescending to me, since
if I meant to write "if let" I probably wouldn't have written "match" :)
2015-09-02 16:46:14 +02:00
Georg Brandl
b72ef5a173
new lint: loop-match-break, which could be while-let ( fixes #118 )
2015-08-30 12:40:39 +02:00
Manish Goregaokar
9ebcd0bf29
More macro checks
2015-08-27 04:33:59 +05:30
Georg Brandl
92a3394065
all: remove unneeded deref and/or ref operations
2015-08-25 14:41:35 +02:00
Georg Brandl
7580da306e
matches: special message for this case
...
match &e { &Pat1 => {}, &Pat2 => {}, ... }
(inspired by dogfood fixes)
2015-08-22 14:34:39 +02:00
Georg Brandl
017dac2301
new lint: using &Ref patterns instead of matching on *expr ( fixes #187 )
2015-08-22 14:34:39 +02:00
Georg Brandl
5403e82681
matches: new module, move single_match lint there
2015-08-22 14:34:39 +02:00