Andre Bogus
42ae1e6918
use rustc's eval_const, bail on (negative) infinity
2015-11-10 11:23:47 +01: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
Manish Goregaokar
567d5a7293
Improve cmp_owned suggestions ( fixes #386 )
2015-10-13 04:16:05 +05:30
Manish Goregaokar
15e3774cb4
rustup to 1.5.0-nightly (7bf4c885f 2015-09-26)
...
fixes #348
2015-09-28 10:34:10 +05:30
Manish Goregaokar
294d7d8586
Merge branch 'pr-347'
2015-09-24 12:01:18 +05:30
Pietro Monteiro
b2c66d1a0e
Upgrade Rust to rustc 1.5.0-nightly (b2f379cdc 2015-09-23)
...
Ident was removed in many HIR structures in favor of Name.
2015-09-23 17:30:39 -07:00
Manish Goregaokar
3609a2211a
Handle let ref in toplevel_ref_arg as well
2015-09-22 12:46:51 +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
Nathan Weston
1e320b38c1
Add is_integer_literal utility function
...
Replaces is_lit_zero and is_lit_one which were used in a couple of
places.
2015-09-15 09:41:25 -04:00
llogiq
681bce925f
less false positives for approx_const and float_cmp
2015-09-11 15:30:08 +02:00
Andre Bogus
468b410d04
de-closured the item name getter
2015-09-06 21:03:09 +02:00
Andre Bogus
87e6099ad7
fix false positive len_zero in is_empty()
2015-09-06 20:57:06 +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
llogiq
cb571bf2e2
also ignore functions
2015-09-03 10:57:11 +02:00
llogiq
0c7f05dd76
check item name for eq, fixes #268
2015-09-02 10:30:11 +02:00
Frank Denis
833493cf07
FnKind::FkClosure -> FnKind::Closure
2015-09-01 14:28:23 +02:00
Manish Goregaokar
d3da9f6c81
Merge branch 'pr-260'
...
Conflicts:
src/lib.rs
2015-08-31 15:06:53 +05:30
Georg Brandl
03abe275b2
new lint: unnecessary patterns (x@_ -> x)
2015-08-30 19:02:30 +02:00
Tim Neumann
ef0c933550
add precedence_negative_literal lint
2015-08-30 17:34:48 +02:00
Manish Goregaokar
c3d4eb5bbd
Merge branch 'pr-228'
...
Conflicts:
README.md
src/methods.rs
2015-08-27 15:25:56 +02:00
Manish Goregaokar
7a1082d916
Merge pull request #239 from jedisct1/nightly
...
Changes for rust-nightly after #27856
2015-08-27 03:44:30 +05:30
llogiq
6984d2bc09
added helpful links to lints that have wiki entries
2015-08-26 14:33:51 +02:00
Frank Denis
92db00863f
Changes for rust-nightly after #27856
2015-08-25 23:21:38 +02:00
Georg Brandl
92a3394065
all: remove unneeded deref and/or ref operations
2015-08-25 14:41:35 +02:00
Georg Brandl
8f1a237493
&-matches: dogfood fixes!
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
Georg Brandl
7f52239cab
consts: convert to using a struct with state
...
Struct has the context reference (as an Option) and the
needed_resolution flag.
2015-08-17 19:58:21 +02:00
llogiq
0e67c0134f
make float_cmp check for zero
2015-08-17 12:08:45 +02:00
Manish Goregaokar
164907ece2
restrict toplevel_ref_arg to only functions ( fixes #170 )
2015-08-16 17:24:03 +05:30
Georg Brandl
47b605304d
all: organize imports
...
* remove unused imports
* separate external and internal imports
* consistent import of rustc::lint
* move #[allow(unused_imports)] to local impl
2015-08-16 08:55:34 +02:00
Georg Brandl
542bf8d50e
misc: fix check for unit body in "match -> if let" lint ( fixes #172 )
2015-08-15 09:56:15 +02:00
Manish Goregaokar
83487c060f
Add trim_multiline utility ( fixes #139 )
2015-08-13 23:18:33 +05:30
Manish Goregaokar
09db7f3fee
fix
2015-08-13 21:45:42 +05:30
Georg Brandl
2c2716f045
all: DRY for lint descriptions
...
* use the rustc style for lint descriptions
* add a script to parse all lint descriptions
and put the generated table into README
2015-08-13 11:14:05 +02:00
Manish Goregaokar
8dfa02938d
Merge branch 'pr-149'
2015-08-13 13:00:29 +05:30
Georg Brandl
a67e55f3f0
lint messages: remove trailing period
...
Since lint messages often are suffixed by ", #[warn(xxx)] on by default"
this trailing period produces an ugly clash with the comma.
2015-08-13 08:15:42 +02:00
Georg Brandl
225969e8a3
methods: move misc.StrToStringPass to MethodsPass
2015-08-12 13:58:55 +02:00
Georg Brandl
bcd95aec1c
all: make style of lint messages consistent
...
* start first sentence lowercased
* use backticks to delimit code snippets
* use "this is wrong. Consider doing X." consistently
2015-08-12 10:47:09 +02:00
Georg Brandl
02c0cafa14
move NeedlessReturn pass out to its own module and rename to ReturnPass
2015-08-11 22:06:59 +02:00
Georg Brandl
cf96042c65
move walk_ty() to utils module and rename to walk_ptrs_ty
2015-08-11 21:16:10 +02:00
Manish Goregaokar
6bc69fa342
Merge pull request #127 from birkenfeld/better-helptext-if-let
...
better help text for "match -> if let" lint
2015-08-12 00:44:51 +05:30
Manish Goregaokar
2cb26126d3
Merge branch 'pr-78'
...
Conflicts:
src/lib.rs
2015-08-11 23:28:06 +05:30
Manish Goregaokar
efdbfe0d31
nit
2015-08-11 23:11:20 +05:30
Georg Brandl
cab9905705
better help text for "match -> if let" lint
...
Implements the suggestion from #87 .
Changes span_help_and_lint(), which is only used for this lint,
to use fileline_help() instead of span_help() to avoid printing
the span twice.
Also adds complete suggested new code. I had to distinguish
between blocks, which need no additionals braces, and other exprs.
2015-08-11 19:26:51 +02:00
Georg Brandl
0ff476b529
new lint for unneeded return stmts
2015-08-11 19:05:11 +02:00
Georg Brandl
7b074d3ac7
Remove tabs and trailing whitespace from lib and misc.
2015-08-11 17:02:04 +02:00
llogiq
f0eb36c2af
added parent method, also changed match-if-let note to help
2015-08-11 15:07:21 +02:00
Manish Goregaokar
de5ccdfab6
Upgrade to rustc 1.3.0-nightly (4d52d7c85 2015-07-30)
2015-07-31 12:00:06 +05:30
Manish Goregaokar
0e8e8cfc9b
Basic framework for structured logging
2015-07-27 00:39:09 +05:30
llogiq
251c5cfffd
rustup, also first time clippy was used on itself, which led to a small refactoring
2015-07-16 08:53:02 +02:00