]> git.lizzy.rs Git - rust.git/log
rust.git
5 years agoAuto merge of #4149 - flip1995:rollup-6knpdqb, r=flip1995
bors [Mon, 27 May 2019 11:33:29 +0000 (11:33 +0000)]
Auto merge of #4149 - flip1995:rollup-6knpdqb, r=flip1995

Rollup of 2 pull requests

Successful merges:

 - #4102 (Fix match_same_arms to fail late)
 - #4119 (Improve non ascii literal)

Failed merges:

r? @ghost

5 years agoRollup merge of #4119 - BO41:non_ascii_literal, r=flip1995
Philipp Krones [Mon, 27 May 2019 11:09:17 +0000 (13:09 +0200)]
Rollup merge of #4119 - BO41:non_ascii_literal, r=flip1995

Improve non ascii literal

This PR improves the example of the [non_ascii_literal](https://rust-lang.github.io/rust-clippy/master/index.html#non_ascii_literal) lint.
It also makes it auto-fixable.

Please review. This is my first PR to this project.
(Thanks @flip1995 for the help :)

changelog: none
fixes #4117

5 years agoRollup merge of #4102 - Urriel:fix/4096_match_same_arms, r=flip1995
Philipp Krones [Mon, 27 May 2019 11:09:16 +0000 (13:09 +0200)]
Rollup merge of #4102 - Urriel:fix/4096_match_same_arms, r=flip1995

Fix match_same_arms to fail late

Changes:
- Add a function search_same_list which return a list of matched expressions
- Change the match_same_arms implementation behavior. It will lint each same arms found.

fixes #4096

changelog: none

5 years agoAuto merge of #3832 - HarrisonMc555:use_last, r=flip1995
bors [Mon, 27 May 2019 11:04:38 +0000 (11:04 +0000)]
Auto merge of #3832 - HarrisonMc555:use_last, r=flip1995

Implement "Use last" lint

Closes #3673

This lint checks the use of `x.get(x.len() - 1)` and suggests `x.last()` (where `x` is a `Vec`).

There's at least one more thing that needs to happen here. I believe I am correctly checking most of the scenarios and avoiding false positives. However, if different `Vec`s are used for the `x.get` and `y.len`, then it will emit a false positive. In other words, I need to check to make sure the `Vec`s are the same.

Also, a lot of these commits were temporary and not helpful to the project history...am I supposed to squash on merge? If so, how do I do that?

changelog: New lint: `get_last_with_len`

5 years agoAuto merge of #4148 - sanxiyn:typo, r=Manishearth
bors [Mon, 27 May 2019 03:38:19 +0000 (03:38 +0000)]
Auto merge of #4148 - sanxiyn:typo, r=Manishearth

Fix typo in comment

5 years agoFix typo in comment
Seo Sanghyeon [Mon, 27 May 2019 03:32:04 +0000 (12:32 +0900)]
Fix typo in comment

5 years agoAuto merge of #4145 - rust-lang:rustup, r=oli-obk
bors [Sun, 26 May 2019 15:36:38 +0000 (15:36 +0000)]
Auto merge of #4145 - rust-lang:rustup, r=oli-obk

Rustup to rustc 1.36.0-nightly (2268d9923 2019-05-26)

changelog: none

5 years agoRustfmt
Oliver Scherer [Sun, 26 May 2019 15:36:21 +0000 (17:36 +0200)]
Rustfmt

5 years agoRustup to rustc 1.36.0-nightly (2268d9923 2019-05-26)
Oliver Scherer [Sun, 26 May 2019 14:47:26 +0000 (16:47 +0200)]
Rustup to rustc 1.36.0-nightly (2268d9923 2019-05-26)

5 years agoAuto merge of #4141 - phansch:rustup5, r=oli-obk
bors [Sat, 25 May 2019 07:50:39 +0000 (07:50 +0000)]
Auto merge of #4141 - phansch:rustup5, r=oli-obk

Rustup to https://github.com/rust-lang/rust/pull/61026

None

5 years agoRustup to https://github.com/rust-lang/rust/pull/61026
Philipp Hansch [Sat, 25 May 2019 07:45:07 +0000 (09:45 +0200)]
Rustup to https://github.com/rust-lang/rust/pull/61026

5 years agoAuto merge of #4135 - matthiaskrgr:rustup_obsol, r=phansch
bors [Fri, 24 May 2019 14:08:09 +0000 (14:08 +0000)]
Auto merge of #4135 - matthiaskrgr:rustup_obsol, r=phansch

rustup https://github.com/rust-lang/rust/pull/60803/

changelog: none

5 years agorustup https://github.com/rust-lang/rust/pull/60803/
Matthias Krüger [Fri, 24 May 2019 13:25:36 +0000 (15:25 +0200)]
rustup https://github.com/rust-lang/rust/pull/60803/

5 years agoAuto merge of #4134 - phansch:rustup4, r=Manishearth
bors [Fri, 24 May 2019 06:24:12 +0000 (06:24 +0000)]
Auto merge of #4134 - phansch:rustup4, r=Manishearth

Rustup to https://github.com/rust-lang/rust/pull/59545

Needed due to signature changes of `item_children` in [the PR](https://github.com/rust-lang/rust/pull/59545/files) (just grep for `item_children` to see the changes)

I'm not really sure where the .stderr changes came from.

5 years agoRustup to https://github.com/rust-lang/rust/pull/59545
Philipp Hansch [Fri, 24 May 2019 06:19:51 +0000 (08:19 +0200)]
Rustup to https://github.com/rust-lang/rust/pull/59545

5 years agoAuto merge of #4132 - phansch:rollup-0vxoimc, r=phansch
bors [Thu, 23 May 2019 19:29:17 +0000 (19:29 +0000)]
Auto merge of #4132 - phansch:rollup-0vxoimc, r=phansch

Rollup of 2 pull requests

Successful merges:

 - #4129 (update if_chain to 1.0.0)
 - #4130 (bump rustc_tools_util to 0.2.0 )

Failed merges:

r? @ghost

5 years agoRollup merge of #4130 - matthiaskrgr:rtu_2, r=phansch
Philipp Hansch [Thu, 23 May 2019 19:28:50 +0000 (21:28 +0200)]
Rollup merge of #4130 - matthiaskrgr:rtu_2, r=phansch

bump rustc_tools_util to 0.2.0

I want to push a new version to crates.io.

changelog: release rustc_tool_utils 0.2.0

5 years agoRollup merge of #4129 - matthiaskrgr:if_chain, r=phansch
Philipp Hansch [Thu, 23 May 2019 19:28:49 +0000 (21:28 +0200)]
Rollup merge of #4129 - matthiaskrgr:if_chain, r=phansch

update if_chain to 1.0.0

5 years agoAuto merge of #4131 - phansch:rustup2, r=phansch
bors [Thu, 23 May 2019 18:23:39 +0000 (18:23 +0000)]
Auto merge of #4131 - phansch:rustup2, r=phansch

Rustup to https://github.com/rust-lang/rust/pull/60965

https://github.com/rust-lang/rust/pull/60965

5 years agoRustup to https://github.com/rust-lang/rust/pull/60965
Philipp Hansch [Thu, 23 May 2019 18:19:00 +0000 (20:19 +0200)]
Rustup to https://github.com/rust-lang/rust/pull/60965

5 years agoclippy: bump rustc_tools util version to 0.2
Matthias Krüger [Thu, 23 May 2019 15:40:54 +0000 (17:40 +0200)]
clippy: bump rustc_tools util version to 0.2
rustc_tools_util: fix typo in docs (readme)

5 years agorustc_tool_utils: bump version to 0.2.0
Matthias Krüger [Thu, 23 May 2019 15:30:05 +0000 (17:30 +0200)]
rustc_tool_utils: bump version to 0.2.0

5 years agoupdate if_chain to 1.0.0
Matthias Krüger [Thu, 23 May 2019 15:23:59 +0000 (17:23 +0200)]
update if_chain to 1.0.0

5 years agoAuto merge of #4128 - matthiaskrgr:test_update, r=phansch
bors [Thu, 23 May 2019 15:12:29 +0000 (15:12 +0000)]
Auto merge of #4128 - matthiaskrgr:test_update, r=phansch

tests: update needless_bool test stderr

I'm getting a test failure otherwise with rust master (f688ba608923bdbf6b46ec65af2f6464b6233a75).

changelog: none

5 years agotests: update needless_bool test stderr
Matthias Krüger [Thu, 23 May 2019 15:03:59 +0000 (17:03 +0200)]
tests: update needless_bool test stderr

I'm getting a test failure otherwise with rust master (f688ba608923bdbf6b46ec65af2f6464b6233a75).

5 years agoAuto merge of #4126 - phansch:rustup, r=Manishearth
bors [Thu, 23 May 2019 05:43:15 +0000 (05:43 +0000)]
Auto merge of #4126 - phansch:rustup, r=Manishearth

Rustup to https://github.com/rust-lang/rust/pull/60740

https://github.com/rust-lang/rust/pull/60740

changelog: none

5 years agocargo fmt
Philipp Hansch [Thu, 23 May 2019 05:24:53 +0000 (07:24 +0200)]
cargo fmt

Roses are red
Violets are blue
`Add rustfmt to a pre-commit hook` is what I should do.

5 years agoRustup to https://github.com/rust-lang/rust/pull/60740
Philipp Hansch [Thu, 23 May 2019 05:19:25 +0000 (07:19 +0200)]
Rustup to https://github.com/rust-lang/rust/pull/60740

changelog: none

5 years agoAuto merge of #4120 - phansch:needless_lifetimes_async_test_cleanup, r=Manishearth
bors [Wed, 22 May 2019 10:44:39 +0000 (10:44 +0000)]
Auto merge of #4120 - phansch:needless_lifetimes_async_test_cleanup, r=Manishearth

Lifetimes UI test cleanup

* Removes an unneeded `#![warn(clippy::extra_unused_lifetimes)]` from
  the `needless_lifetimes` test - the tests for those are in a different
  file.

* Renames `unused_lt.{rs,stderr}` to `extra_unused_lifetimes.{rs,stderr}`
* Renames `lifetimes.{rs,stderr}` to `needless_lifetimes.{rs,stderr}`

5 years agoAuto merge of #4125 - Manishearth:rustup, r=oli-obk
bors [Wed, 22 May 2019 08:37:27 +0000 (08:37 +0000)]
Auto merge of #4125 - Manishearth:rustup, r=oli-obk

Rustup to rustc 1.36.0-nightly (dbfe70dfc 2019-05-22)

not 100% sure of the Symbol stuff

r? @oli-obk

5 years agoDisable cargo integration test due to clippy ICE
Oliver Scherer [Wed, 22 May 2019 08:36:20 +0000 (10:36 +0200)]
Disable cargo integration test due to clippy ICE

5 years agoRustup to rustc 1.36.0-nightly (dbfe70dfc 2019-05-22)
Manish Goregaokar [Wed, 22 May 2019 04:58:27 +0000 (21:58 -0700)]
Rustup to rustc 1.36.0-nightly (dbfe70dfc 2019-05-22)

5 years agoFix breaking tests
Vincent Dal Maso [Mon, 20 May 2019 16:25:13 +0000 (18:25 +0200)]
Fix breaking tests

Changes:
- Fix stderr breaking the tests
- Adding tests over the if arms

5 years agoAdd the common case search
Vincent Dal Maso [Mon, 20 May 2019 08:22:13 +0000 (10:22 +0200)]
Add the common case search

Changes:
- Refactor the common case search into a function.
- Fix the useless Option around the vec in the search_same_list.

5 years agoFormatting inside if_chain! macro
Philipp Krones [Tue, 21 May 2019 07:33:59 +0000 (09:33 +0200)]
Formatting inside if_chain! macro

5 years agoImplement get_last_with_len lint
Harrison McCullough [Tue, 21 May 2019 00:01:21 +0000 (18:01 -0600)]
Implement get_last_with_len lint

5 years agoLifetimes UI test cleanup
Philipp Hansch [Mon, 20 May 2019 17:19:49 +0000 (19:19 +0200)]
Lifetimes UI test cleanup

* Removes an unneeded `#![warn(clippy::extra_unused_lifetimes)]` from
  the `needless_lifetimes` test - the tests for those are in a different
  file.

* Renames `unused_lt.{rs,stderr}` to `extra_unused_lifetimes.{rs,stderr}`
* Renames `lifetimes.{rs,stderr}` to `needless_lifetimes.{rs,stderr}`

5 years agoFix tests and make other ascii lints auto-fixable
BO41 [Mon, 20 May 2019 14:02:50 +0000 (16:02 +0200)]
Fix tests and make other ascii lints auto-fixable

5 years agoAuto merge of #4118 - rust-lang:revert, r=phansch
bors [Mon, 20 May 2019 13:36:26 +0000 (13:36 +0000)]
Auto merge of #4118 - rust-lang:revert, r=phansch

Revert "Turn off two tests broken due to #4108"

This reverts commit 568a3ecfc3eebe099c1ffe44c3d9afdc5d445fd2 which is unnecessary after https://github.com/rust-lang/rust-clippy/pull/4115

changelog: none

5 years agoMake non_ascii_literal auto-fixable
BO41 [Mon, 20 May 2019 13:23:38 +0000 (15:23 +0200)]
Make non_ascii_literal auto-fixable

5 years agoImprove verbosity of non_ascii_literal lint example
BO41 [Mon, 20 May 2019 13:08:53 +0000 (15:08 +0200)]
Improve verbosity of non_ascii_literal lint example

5 years agoRevert "Turn off two tests broken due to #4108"
Oliver Scherer [Mon, 20 May 2019 10:31:53 +0000 (12:31 +0200)]
Revert "Turn off two tests broken due to #4108"

This reverts commit 568a3ecfc3eebe099c1ffe44c3d9afdc5d445fd2.

5 years agoAuto merge of #4088 - pJunger:check1, r=oli-obk
bors [Mon, 20 May 2019 09:31:09 +0000 (09:31 +0000)]
Auto merge of #4088 - pJunger:check1, r=oli-obk

Added lint for TryFrom for checked integer conversion.

works towards #3947

Added lint for try_from for checked integer conversion.
Should recognize simple & straight-forward checked integer conversions.

5 years agoAuto merge of #4115 - ehuss:fix-compiletest, r=Manishearth
bors [Sun, 19 May 2019 20:44:19 +0000 (20:44 +0000)]
Auto merge of #4115 - ehuss:fix-compiletest, r=Manishearth

Fix compile-test from forcing a rebuild.

If the `compile-test` test was run, then running a cargo build command immediately after caused everything to be rebuilt. This is because the `compile-test` test was deleting all `.rmeta` files in the target directory. Cargo recently switched to always generating `.rmeta` files (https://github.com/rust-lang/cargo/pull/6883), and when the files are deleted, it thinks it needs to be rebuilt.

I am not very familiar with compiletest or clippy, so please take a close look and test this out (with the most recent nightly). In particular, make sure it doesn't revert the fixes from #3380 (it seems to work for me). Also @oli-obk mentioned something related in https://github.com/rust-lang/rust/pull/60190#issuecomment-493617188, and I want to make sure that is addressed as well.

Fixes #4114

5 years agoFix compile-test from forcing a rebuild.
Eric Huss [Sun, 19 May 2019 20:25:06 +0000 (13:25 -0700)]
Fix compile-test from forcing a rebuild.

5 years agoAuto merge of #4109 - Manishearth:backport-merge, r=phansch
bors [Sun, 19 May 2019 11:13:40 +0000 (11:13 +0000)]
Auto merge of #4109 - Manishearth:backport-merge, r=phansch

Merge backport branches into master

Attempt 2 at https://github.com/rust-lang/rust-clippy/pull/4103

This does nothing to the code, however it keeps the backport branches in master history, so that deleting a branch won't accidentally break old rustc builds

5 years agoAuto merge of #4107 - taiki-e:useless_attribute, r=flip1995
bors [Sun, 19 May 2019 10:37:09 +0000 (10:37 +0000)]
Auto merge of #4107 - taiki-e:useless_attribute, r=flip1995

useless_attribute: Add unreachable_pub to whitelists

Fixes #4106

changelog: `useless_attribute`: whitelist `unreachable_pub` on `use` items

5 years agoAuto merge of #4099 - flip1995:ul_4094, r=oli-obk
bors [Sun, 19 May 2019 08:46:43 +0000 (08:46 +0000)]
Auto merge of #4099 - flip1995:ul_4094, r=oli-obk

Add macro check for unreadable_literal lint

Closes #4094

changelog: Disable `unreadable_literal` lint inside macros

5 years agoAuto merge of #4100 - phansch:add_stderr_length_check, r=flip1995
bors [Sun, 19 May 2019 08:13:16 +0000 (08:13 +0000)]
Auto merge of #4100 - phansch:add_stderr_length_check, r=flip1995

Add a stderr file length check to clippy_dev

This adds a check to `clippy_dev` that enforces a maximum line count for
`stderr` files. CI will fail if the line count is exceeded. It's
currently set to `320` lines.

Ideally this would be implemented in `compiletest-rs` but there are
plans to move Rust's `compiletest` into the `compiletest-rs` repository
and I don't want to do the work in `compiletest` twice. However, I also
don't want to wait until the move is done, so I added the check to
`clippy_dev` until it makes sense to add it to compiletest-rs.

cc #2038

5 years agoAuto merge of #4111 - Manishearth:changelog, r=oli-obk
bors [Sun, 19 May 2019 07:43:34 +0000 (07:43 +0000)]
Auto merge of #4111 - Manishearth:changelog, r=oli-obk

Update changelog

r? @oli-obk @phansch

5 years agoUpdate master changelog
Manish Goregaokar [Sat, 18 May 2019 15:59:38 +0000 (08:59 -0700)]
Update master changelog

Up to 60a609acaed3bf2b3ec6ab995bccf0f03bc26060

5 years agoUpdate beta changelog
Manish Goregaokar [Sat, 18 May 2019 15:38:29 +0000 (08:38 -0700)]
Update beta changelog

5 years agoUpdated README.
pJunger [Sat, 18 May 2019 12:53:56 +0000 (14:53 +0200)]
Updated README.

5 years agoRemoved symbols again.
pJunger [Sat, 18 May 2019 08:54:03 +0000 (10:54 +0200)]
Removed symbols again.

5 years agoRemoved unused lifetime.
pJunger [Tue, 14 May 2019 20:40:39 +0000 (22:40 +0200)]
Removed unused lifetime.

5 years agoChanged impl to use symbols.
pJunger [Tue, 14 May 2019 19:39:12 +0000 (21:39 +0200)]
Changed impl to use symbols.

5 years agoAdded suggestion for conversion with is_ok.
pJunger [Tue, 14 May 2019 18:05:27 +0000 (20:05 +0200)]
Added suggestion for conversion with is_ok.

5 years agoFixed more lint findings.
pJunger [Sun, 12 May 2019 19:53:28 +0000 (21:53 +0200)]
Fixed more lint findings.

5 years agoFixed clippy lints in checked_conversions.rs.
pJunger [Sun, 12 May 2019 19:14:44 +0000 (21:14 +0200)]
Fixed clippy lints in checked_conversions.rs.

5 years agoRegistered lint.
pJunger [Sun, 12 May 2019 18:42:13 +0000 (20:42 +0200)]
Registered lint.

5 years agoAdded lint for TryFrom for checked integer conversion rust-lang#3947.
pJunger [Sun, 12 May 2019 12:46:16 +0000 (14:46 +0200)]
Added lint for TryFrom for checked integer conversion rust-lang#3947.

5 years agouseless_attribute: Add unreachable_pub to whitelists
Taiki Endo [Fri, 17 May 2019 10:42:43 +0000 (19:42 +0900)]
useless_attribute: Add unreachable_pub to whitelists

5 years agoAuto merge of #4110 - rust-lang:symbolic_wasteland, r=oli-obk
bors [Fri, 17 May 2019 23:47:49 +0000 (23:47 +0000)]
Auto merge of #4110 - rust-lang:symbolic_wasteland, r=oli-obk

Prevent symbocalypse

r? @Manishearth

This is strictly better, we can just not modify rustc and bump solely the clippy submodule and then implement diagnostic lang items without beta looming over us

changelog: none

5 years agoDogfood
Oliver Scherer [Fri, 17 May 2019 23:34:52 +0000 (01:34 +0200)]
Dogfood

5 years agoDogfood and rustfmt
Oliver Scherer [Fri, 17 May 2019 22:58:25 +0000 (00:58 +0200)]
Dogfood and rustfmt

5 years agoTurn off two tests broken due to #4108
Oliver Scherer [Fri, 17 May 2019 22:57:23 +0000 (00:57 +0200)]
Turn off two tests broken due to #4108

5 years agoPrevent symbocalypse
Oliver Scherer [Fri, 17 May 2019 21:53:54 +0000 (23:53 +0200)]
Prevent symbocalypse

5 years agoMerge remote-tracking branch 'origin/beta1.35' into backport-merge
Manish Goregaokar [Fri, 17 May 2019 19:56:36 +0000 (12:56 -0700)]
Merge remote-tracking branch 'origin/beta1.35' into backport-merge

5 years agoMerge remote-tracking branch 'origin/rust-1.34.1' into HEAD
Manish Goregaokar [Fri, 17 May 2019 19:54:28 +0000 (12:54 -0700)]
Merge remote-tracking branch 'origin/rust-1.34.1' into HEAD

5 years agoMerge remote-tracking branch 'origin/rust-1.31.0' into HEAD
Manish Goregaokar [Fri, 17 May 2019 19:54:15 +0000 (12:54 -0700)]
Merge remote-tracking branch 'origin/rust-1.31.0' into HEAD

5 years agoMerge remote-tracking branch 'origin/beta_backport' into HEAD
Manish Goregaokar [Fri, 17 May 2019 19:53:52 +0000 (12:53 -0700)]
Merge remote-tracking branch 'origin/beta_backport' into HEAD

5 years agoAuto merge of #4104 - Manishearth:beta-backports, r=flip1995
bors [Fri, 17 May 2019 14:14:53 +0000 (14:14 +0000)]
Auto merge of #4104 - Manishearth:beta-backports, r=flip1995

Backport #4101 to beta

This lint has been causing lots of problems.

I'll check up on other potential beta backports when I build the new changelog

r? @oli-obk

5 years agoDon't require rustfmt on beta
Oliver Scherer [Fri, 17 May 2019 13:47:11 +0000 (15:47 +0200)]
Don't require rustfmt on beta

5 years agoDon't run dogfood on windows
Oliver Scherer [Fri, 17 May 2019 11:19:28 +0000 (13:19 +0200)]
Don't run dogfood on windows

5 years agoBackport #4101
Manish Goregaokar [Thu, 16 May 2019 16:47:21 +0000 (09:47 -0700)]
Backport #4101

https://github.com/rust-lang/rust-clippy/pull/4101

Splits up redundant_closure's method checking into a pedantic lint

5 years agoCollect at callsite, use eprintln instead of println
Philipp Hansch [Fri, 17 May 2019 05:41:25 +0000 (07:41 +0200)]
Collect at callsite, use eprintln instead of println

5 years agoAdd a stderr file length check to clippy_dev
Philipp Hansch [Thu, 16 May 2019 05:31:56 +0000 (07:31 +0200)]
Add a stderr file length check to clippy_dev

This adds a check to `clippy_dev` that enforces a maximum line count for
`stderr` files. CI will fail if the line count is exceeded. It's
currently set to `320` lines.

Ideally this would be implemented in `compiletest-rs` but there are
plans to move Rust's `compiletest` into the `compiletest-rs` repository
and I don't want to do the work in `compiletest` twice. However, I also
don't want to wait until the move is done, so I added the check to
`clippy_dev` until it makes sense to add it to compiletest-rs.

cc #2038

5 years agoAuto merge of #4101 - mikerite:redundant_closures_for_method_calls, r=Manishearth
bors [Thu, 16 May 2019 18:18:58 +0000 (18:18 +0000)]
Auto merge of #4101 - mikerite:redundant_closures_for_method_calls, r=Manishearth

Split redundant_closure lint

Move the method checking into a new lint called
`redundant_closures_for_method_calls` and put it in the pedantic group.

This aspect of the lint seems more controversial than the rest.

cc #3942

changelog: Move method checking from `redundant_closure` to a new `pedantic` lint called `redundant_closure_for_method_calls`.

5 years agoAlso rename the lint in test files
flip1995 [Thu, 16 May 2019 18:18:07 +0000 (20:18 +0200)]
Also rename the lint in test files

5 years agoAdd known problems
Manish Goregaokar [Thu, 16 May 2019 16:43:07 +0000 (09:43 -0700)]
Add known problems

5 years agoRename to redundant_closure_for_method_calls
Manish Goregaokar [Thu, 16 May 2019 16:18:15 +0000 (09:18 -0700)]
Rename to redundant_closure_for_method_calls

5 years agoAdd test for multiple same arms lints
Vincent Dal Maso [Thu, 16 May 2019 12:13:57 +0000 (14:13 +0200)]
Add test for multiple same arms lints

Changes:
- Add a test to match multiple arms in the same match statement

5 years agoFix match_same_arms to fail late
Vincent Dal Maso [Thu, 16 May 2019 09:27:45 +0000 (11:27 +0200)]
Fix match_same_arms to fail late

Changes:
- Add a function search_same_list which return a list of matched expressions
- Change the match_same_arms implementation behaviour. It will lint each same arms found.

5 years agoSplit redundant_closure lint
Michael Wright [Thu, 16 May 2019 06:25:39 +0000 (08:25 +0200)]
Split redundant_closure lint

Move the method checking into a new lint called
`redundant_closures_for_method_calls` and put it in the pedantic group.

This aspect of the lint seems more controversial than the rest.

cc #3942

5 years agoAdd macro check for unreadable_literal lint
flip1995 [Wed, 15 May 2019 12:57:56 +0000 (14:57 +0200)]
Add macro check for unreadable_literal lint

Closes #4094

5 years agoAuto merge of #4066 - rust-lang:hash, r=Manishearth
bors [Wed, 15 May 2019 05:40:02 +0000 (05:40 +0000)]
Auto merge of #4066 - rust-lang:hash, r=Manishearth

Properly hash enums

While I wrote this I was saved by a clippy lint... I accidentally fetched the discriminant of a reference to an enum and not of an enum.

changelog: reduce hash collisions during clippy-internal hashing

5 years agoFix dogfood errors
flip1995 [Tue, 14 May 2019 13:08:29 +0000 (15:08 +0200)]
Fix dogfood errors

5 years agoAlso hash mem::discriminant in hash_stmt
flip1995 [Tue, 14 May 2019 12:13:23 +0000 (14:13 +0200)]
Also hash mem::discriminant in hash_stmt

5 years agomem::discriminant trumps manual discriminant hashing
Oliver Scherer [Wed, 8 May 2019 09:34:35 +0000 (11:34 +0200)]
mem::discriminant trumps manual discriminant hashing

5 years agoAuto merge of #4095 - flip1995:mscn_test, r=phansch
bors [Tue, 14 May 2019 12:02:22 +0000 (12:02 +0000)]
Auto merge of #4095 - flip1995:mscn_test, r=phansch

Add test for #3198

Closes #3198

changelog: none

5 years agoProperly hash enums
Oliver Scherer [Tue, 7 May 2019 12:48:00 +0000 (14:48 +0200)]
Properly hash enums

5 years agoAdd test for #3198
flip1995 [Tue, 14 May 2019 11:46:10 +0000 (13:46 +0200)]
Add test for #3198

5 years agoAuto merge of #4084 - mikerite:fix-4019, r=oli-obk
bors [Tue, 14 May 2019 11:26:16 +0000 (11:26 +0000)]
Auto merge of #4084 - mikerite:fix-4019, r=oli-obk

Fix 4019

Fixes #4019

5 years agoAuto merge of #4093 - rust-lang:rustup, r=oli-obk
bors [Tue, 14 May 2019 09:02:01 +0000 (09:02 +0000)]
Auto merge of #4093 - rust-lang:rustup, r=oli-obk

Rustup to rustc 1.36.0-nightly (1764b2972 2019-05-12)

5 years agoRustfmt all the things
Oliver Scherer [Tue, 14 May 2019 08:06:21 +0000 (10:06 +0200)]
Rustfmt all the things

5 years agoClippy dogfood
Oliver Scherer [Tue, 14 May 2019 08:03:16 +0000 (10:03 +0200)]
Clippy dogfood

5 years agoUpdate for compiletest changes
Oliver Scherer [Tue, 14 May 2019 07:41:29 +0000 (09:41 +0200)]
Update for compiletest changes

5 years agoUse symbols instead of strings
Oliver Scherer [Mon, 13 May 2019 23:34:08 +0000 (01:34 +0200)]
Use symbols instead of strings

5 years agoRustup to rustc 1.36.0-nightly (1764b2972 2019-05-12)
Manish Goregaokar [Mon, 13 May 2019 18:29:54 +0000 (11:29 -0700)]
Rustup to rustc 1.36.0-nightly (1764b2972 2019-05-12)

5 years agoAuto merge of #4089 - flip1995:id_conv_reg_test, r=Manishearth
bors [Sun, 12 May 2019 19:37:39 +0000 (19:37 +0000)]
Auto merge of #4089 - flip1995:id_conv_reg_test, r=Manishearth

Add regression test for identity_conversion FP

cc #3913 #4082 #3936

changelog: none