Commit graph

1800 commits

Author SHA1 Message Date
bors
777c9099e7 Auto merge of #3510 - phansch:fix_doc_markdown_mixed_case, r=flip1995
Fix doc_markdown mixed case false positive

Fixes #2343
2018-12-12 18:36:38 +00:00
Philipp Hansch
778723630c
Fix doc_markdown mixed case false positive 2018-12-12 19:25:27 +01:00
bors
7c823cabab Auto merge of #3450 - phansch:structured_sugg_for_explicit_write, r=flip1995
Add suggestion for explicit_write lint

Closes #2083
2018-12-12 18:11:13 +00:00
Philipp Krones
b7a431ea1d
Rollup merge of #3540 - matthiaskrgr:rustup, r=flip1995
rustup https://github.com/rust-lang/rust/pull/56092

fix ui test cast_alignment failure by adding #![feature(rustc_private)]
2018-12-12 18:17:01 +01:00
Matthias Krüger
016c996e16 rustup https://github.com/rust-lang/rust/pull/56092
fix ui test cast_alignment failure by adding #![feature(rustc_private)]
2018-12-12 17:23:07 +01:00
Philipp Hansch
1cfbadb029
Fix doc_markdown off by one issue 2018-12-12 08:21:13 +01:00
bors
f26c39bab7 Auto merge of #3533 - phansch:add_to_doc_valid_idents, r=phansch
Add 'CamelCase' to doc_valid_idents

Fixes #2395
2018-12-12 06:46:21 +00:00
Philipp Hansch
194acaf8e7
Update .stderr after rebase 2018-12-12 07:33:23 +01:00
Philipp Hansch
c4c9d9fc62
Add suggestion for explicit_write lint 2018-12-12 07:31:01 +01:00
Matthias Krüger
36266b3e6c test reformatting: revert more questionable changes done by rustfmt and add #[rustfmt::skip] 2018-12-11 20:50:55 +01:00
Philipp Hansch
ee2abc36a3
Add 'CamelCase' to doc_valid_idents 2018-12-11 19:37:43 +01:00
Matthias Krüger
743e9e3561 Merge branch 'master' into rustfmt_tests 2018-12-11 01:42:38 +01:00
Matthias Krüger
625ca772b5 tests: fix more cases where rustfmt would have hurt the tests 2018-12-11 01:31:04 +01:00
Matthias Krüger
f1d5194e3d tests: revert some changs and add further rustfmt::skip attributes. 2018-12-11 00:59:59 +01:00
bors
ada0b2b095 Auto merge of #3518 - sinkuu:redundant_clone_tw, r=phansch
Lint redundant clone of fields

Makes `redundant_clone` warn on unnecessary `foo.field.clone()` sometimes (it can detect an unnecessary clone only if the base of projection, `foo` in this case, is not used at all after that). This is enough for cases like `returns_tuple().0.clone()`.
2018-12-10 18:55:49 +00:00
Matthias Krüger
0a6e568f07 test formatting: don't format tests/ui/formatting.rs 2018-12-10 15:46:01 +01:00
Matthias Krüger
7bcc2cd9c8 update test stderr 2018-12-10 08:22:07 +01:00
Shotaro Yamada
109d4b1ab3 Lint redundant clone of projection 2018-12-10 08:48:14 +09:00
Matthias Krüger
435299be30 rustfmt tests 2018-12-09 23:26:16 +01:00
Matthias Krüger
9b839cd4b5 update line numbers of tests 2018-12-09 17:24:08 +01:00
Matthias Krüger
4583d78156 add rustfmt::skip attributes to some tests 2018-12-09 17:21:49 +01:00
Shotaro Yamada
a4fe567602 Fix test
`if true` is recognized by MIR optimization.
2018-12-09 23:51:31 +09:00
Philipp Hansch
43542f8d89
Remove a run-rustfix annotation (for now)
Starting to work on #2376, this annotation got in the way. Going to
remove it for now.
2018-12-09 15:16:36 +01:00
Philipp Hansch
26602ddff4
Merge pull request #3336 from HMPerson1/clone_on_copy_deref
Fix `clone_on_copy` not detecting derefs sometimes
2018-12-08 09:59:02 +01:00
Philipp Hansch
041c49c1ed
Merge pull request #3257 from o01eg/remove-sysroot
Don't try to determine sysroot. rustc_driver will use default value.
2018-12-06 22:11:29 +01:00
Philipp Hansch
c4ef06a9b6
Merge pull request #3497 from daxpedda/master
Fix bug in `implicit_return`.
2018-12-06 14:13:20 +01:00
daxpedda
973d676cd1
Fix bug in implicit_return.
Bug was already covered by test, but test was not checked for.
2018-12-06 12:22:54 +01:00
O01eg
278b94e6db
Fix format. 2018-12-06 13:46:23 +03:00
O01eg
5113de90d1
Add sysroot gettinh code to dogfood tests. 2018-12-06 13:21:45 +03:00
Felix Kohlgrüber
a8a0b236b5 fix #3482 and add ui test for it 2018-12-06 11:07:10 +01:00
O01eg
571d4cc7bf
Add sysroot getting code to tests. 2018-12-06 12:23:47 +03:00
Philipp Hansch
f93591294d
Merge pull request #3494 from daxpedda/master
Added `IMPLICIT_RETURN` lint.
2018-12-06 07:12:01 +01:00
Wayne Warren
0442bb9ce0 Don't change current working directory of cargo tests 2018-12-05 18:18:17 -06:00
Wayne Warren
87d517df5d Use cargo's "PROFILE" envvar and set CLIPPY_DOGFOOD 2018-12-05 18:18:17 -06:00
Wayne Warren
66251c3ece Use dogfood_runner for deterministic test ordering 2018-12-05 18:18:17 -06:00
Wayne Warren
72247d8e2e Fix dogfood tests. 2018-12-05 18:18:17 -06:00
daxpedda
aed2b986e6 Renamed to implicit_return.
Covered all other kinds besides `ExprKind::Lit`.
Added check for replacing `break` with `return`.
2018-12-05 14:39:09 +01:00
daxpedda
978f8c65ee Renamed forced_return to missing_returns.
Better clarification in the docs.
Ran `update_lints`.
2018-12-05 10:54:21 +01:00
daxpedda
d5d6692288 Added FORCED_RETURN lint. 2018-12-05 01:59:09 +01:00
Philipp Krones
3f24cdf10f
Merge pull request #3490 from phansch/extract_single_match_else_ui_test
Extract single_match_else UI test
2018-12-04 14:57:19 +01:00
Philipp Hansch
68bb900eba
Merge pull request #3473 from lucasloisp/additional-bool-comparisons
Adds inequality cases to bool comparison (#3438)
2018-12-04 07:26:29 +01:00
Philipp Hansch
3f72d4d630
Extract single_match_else UI test
There's only one test currently.
I also updated the lint doc with a 'good' example and changed the lint
help text a bit.

cc #2038
2018-12-04 07:20:13 +01:00
Lucas Lois
3930148059 Adds inequality cases to bool comparison lint
The lint now checks cases like `y != true`
2018-12-03 16:32:11 -03:00
Oliver S̶c̶h̶n̶e̶i̶d̶e̶r Scherer
c00210d7ba
Merge pull request #3478 from dtolnay/setlen
Remove unsafe_vector_initialization lint
2018-12-03 12:42:31 +01:00
David Tolnay
e632a1946e
Remove unsafe_vector_initialization lint 2018-12-03 02:48:37 -08:00
David Tolnay
1a14cb3643
Keep testing large_digit_groups as ui test 2018-12-01 17:23:53 -08:00
David Tolnay
67f9d24c1b
Keep testing unsafe_vector_initialization as ui test 2018-12-01 17:19:39 -08:00
flip1995
2953ae0702
Run rustfmt on the tests 2018-11-27 21:11:50 +01:00
flip1995
0c6483bf21
Update stderr file 2018-11-27 15:29:23 +01:00
Guillem Nieto
5fa04bc3cd Lint only the first statment/expression after alloc
Instead of searching for all the successive expressions after a vector
allocation, check only the first expression.

This is done to minimize the amount of false positives of the lint.
2018-11-25 14:34:23 -08:00