]> git.lizzy.rs Git - rust.git/log
rust.git
4 years agoAuto merge of #4512 - mati865:rustup, r=phansch
bors [Fri, 6 Sep 2019 12:13:06 +0000 (12:13 +0000)]
Auto merge of #4512 - mati865:rustup, r=phansch

Rustup to rust-lang/rust#64111

changelog: none

4 years agoRustup to rust-lang/rust#64111
Mateusz Mikuła [Fri, 6 Sep 2019 11:57:27 +0000 (13:57 +0200)]
Rustup to rust-lang/rust#64111

4 years agoAuto merge of #4500 - jeremystucki:refactoring, r=flip1995
bors [Fri, 6 Sep 2019 08:41:56 +0000 (08:41 +0000)]
Auto merge of #4500 - jeremystucki:refactoring, r=flip1995

Small refactoring

changelog: none

4 years agoAuto merge of #4506 - derivmug:fix-add-lint-example, r=phansch
bors [Fri, 6 Sep 2019 04:50:12 +0000 (04:50 +0000)]
Auto merge of #4506 - derivmug:fix-add-lint-example, r=phansch

Fix two occurences of TESTNAME=ui/foo_functions

changelog: Fix two occurrences of the wrong path to the foo_functions test in doc/adding_lints.md

This PR fixes the other two wrong paths to the example test. I already created a PR yesterday but only changed one. The old command was `TESTNAME=ui/foo_functions cargo uitest` and is now `TESTNAME=foo_functions cargo uitest`.

4 years agoFix two occurences of TESTNAME=ui/foo_functions
Luca Beetz [Thu, 5 Sep 2019 22:54:49 +0000 (00:54 +0200)]
Fix two occurences of TESTNAME=ui/foo_functions

This commit fixes two occurences of the wrong path to the foo_functions example test in doc/adding-lints.md

4 years agoAuto merge of #4489 - JohnTitor:fix-redundant-pattern-false-positive, r=flip1995
bors [Thu, 5 Sep 2019 16:15:36 +0000 (16:15 +0000)]
Auto merge of #4489 - JohnTitor:fix-redundant-pattern-false-positive, r=flip1995

Fix `redundant_pattern` false positive

Fix #4428

changelog: Fix `redundant_pattern` false positive

4 years agoRun rustfix
Yuki Okushi [Thu, 5 Sep 2019 13:45:52 +0000 (22:45 +0900)]
Run rustfix

4 years agoAuto merge of #4502 - lzutao:rustup-64141, r=phansch
bors [Thu, 5 Sep 2019 08:26:00 +0000 (08:26 +0000)]
Auto merge of #4502 - lzutao:rustup-64141, r=phansch

Rustup "Minimize uses of `LocalInternedString`"

Rustup https://github.com/rust-lang/rust/pull/64141

changelog: none

4 years agoRustup "Minimize uses of `LocalInternedString`"
Lzu Tao [Thu, 5 Sep 2019 06:56:10 +0000 (13:56 +0700)]
Rustup "Minimize uses of `LocalInternedString`"

4 years agoAuto merge of #4501 - derivmug:update-lint-doc, r=phansch
bors [Wed, 4 Sep 2019 17:59:19 +0000 (17:59 +0000)]
Auto merge of #4501 - derivmug:update-lint-doc, r=phansch

Remove ui/ from TESTNAME for foo lint example

changelog: Remove ui/ from TESTNAME in doc/adding-lints.md

This PR remove the `ui/` from the TESTNAME of the example foo lint in the 'Adding lints' documentation.

4 years agoRemove ui/ from TESTNAME for foo lint example
Luca Beetz [Wed, 4 Sep 2019 16:34:19 +0000 (18:34 +0200)]
Remove ui/ from TESTNAME for foo lint example

4 years agoAuto merge of #4495 - JohnTitor:fix-map-entry-false-positive, r=phansch
bors [Wed, 4 Sep 2019 16:25:49 +0000 (16:25 +0000)]
Auto merge of #4495 - JohnTitor:fix-map-entry-false-positive, r=phansch

Fix `map_entry` false positive

Fixes #4219

changelog: Fix `map_entry` false positive

4 years agoMake it auto fixable lint
Yuki Okushi [Wed, 4 Sep 2019 15:50:22 +0000 (00:50 +0900)]
Make it auto fixable lint

4 years agoFix `redundant_pattern` false positive
Yuki Okushi [Mon, 2 Sep 2019 19:49:14 +0000 (04:49 +0900)]
Fix `redundant_pattern` false positive

4 years agoImprove tests
Yuki Okushi [Wed, 4 Sep 2019 15:24:45 +0000 (00:24 +0900)]
Improve tests

4 years agoAuto merge of #4487 - JohnTitor:deref-addrof-external-macro, r=flip1995
bors [Wed, 4 Sep 2019 15:01:06 +0000 (15:01 +0000)]
Auto merge of #4487 - JohnTitor:deref-addrof-external-macro, r=flip1995

Don't check across macro boundary in `deref_addrof`

Fixes #4289

changelog: Allow `deref_addrof` in macros

4 years agoRefactor option handling
Jeremy Stucki [Wed, 4 Sep 2019 14:19:59 +0000 (16:19 +0200)]
Refactor option handling

4 years agoAuto merge of #4418 - euclio:byte-lit-suggestion, r=flip1995
bors [Wed, 4 Sep 2019 13:33:47 +0000 (13:33 +0000)]
Auto merge of #4418 - euclio:byte-lit-suggestion, r=flip1995

use a structured suggestion for char-lit-as-u8

changelog: use a structured suggestion for char-lit-as-u8

4 years agoRun update_lints
flip1995 [Wed, 4 Sep 2019 13:33:14 +0000 (15:33 +0200)]
Run update_lints

4 years agouse a structured suggestion for char-lit-as-u8
Andy Russell [Tue, 20 Aug 2019 02:24:07 +0000 (22:24 -0400)]
use a structured suggestion for char-lit-as-u8

4 years agoAuto merge of #4498 - sinkuu:checked_arithmetic_unwrap, r=flip1995
bors [Wed, 4 Sep 2019 12:14:41 +0000 (12:14 +0000)]
Auto merge of #4498 - sinkuu:checked_arithmetic_unwrap, r=flip1995

Add manual_saturating_arithmetic lint

changelog: add `manual_saturating_arithmetic` lint

Fixes #1557. This lint detects manual saturating arithmetics like `x.checked_add(10u32).unwrap_or(u32::max_value())` and suggests replacing with `x.saturating_add(10u32)`.

4 years agoHide variables in doc-test
Shotaro Yamada [Wed, 4 Sep 2019 12:10:08 +0000 (21:10 +0900)]
Hide variables in doc-test

4 years agoFix doctest and renaming src
Shotaro Yamada [Wed, 4 Sep 2019 12:06:28 +0000 (21:06 +0900)]
Fix doctest and renaming src

4 years agoAuto merge of #4490 - mikerite:fix-4364, r=flip1995
bors [Wed, 4 Sep 2019 11:35:13 +0000 (11:35 +0000)]
Auto merge of #4490 - mikerite:fix-4364, r=flip1995

Fix `too_many_lines` false positive

changelog: Fix `too_many_lines` false positive

4 years agoAdd manual_saturating_arithmetic lint
Shotaro Yamada [Wed, 4 Sep 2019 07:08:48 +0000 (16:08 +0900)]
Add manual_saturating_arithmetic lint

4 years agoAuto merge of #4454 - BO41:search_is_some, r=flip1995
bors [Wed, 4 Sep 2019 07:53:44 +0000 (07:53 +0000)]
Auto merge of #4454 - BO41:search_is_some, r=flip1995

Dereference one less on search_is_some and make it auto-fixable

Fixes #4453

changelog: none

4 years agoTry to fix .fixed
BO41 [Thu, 29 Aug 2019 08:06:56 +0000 (10:06 +0200)]
Try to fix .fixed

4 years agoAuto merge of #4479 - rust-lang:uninit_assume_init, r=flip1995
bors [Tue, 3 Sep 2019 16:14:40 +0000 (16:14 +0000)]
Auto merge of #4479 - rust-lang:uninit_assume_init, r=flip1995

lint against `MaybeUninit::uninit().assume_init()`

changelog: add `uninit_assumed_init` lint

This fixes #4272

4 years agolint against `MaybeUninit::uninit().assume_init()`
Andre Bogus [Sat, 31 Aug 2019 18:25:28 +0000 (20:25 +0200)]
lint against `MaybeUninit::uninit().assume_init()`

4 years agoAuto merge of #4486 - lzutao:fix-panic-unseparate-literals, r=flip1995
bors [Tue, 3 Sep 2019 13:17:30 +0000 (13:17 +0000)]
Auto merge of #4486 - lzutao:fix-panic-unseparate-literals, r=flip1995

Fix index out of bound in case of empty snippet

cc #4480

changelog: none

4 years agoFix `map_entry` false positive
Yuki Okushi [Tue, 3 Sep 2019 00:41:37 +0000 (09:41 +0900)]
Fix `map_entry` false positive

4 years agoAuto merge of #4493 - JohnTitor:fix-build-bytes, r=flip1995
bors [Tue, 3 Sep 2019 10:44:47 +0000 (10:44 +0000)]
Auto merge of #4493 - JohnTitor:fix-build-bytes, r=flip1995

Rustup to rust-lang/rust#63561

changelog: none

4 years agoRemove Allocation::bytes
Yuki Okushi [Tue, 3 Sep 2019 09:25:56 +0000 (18:25 +0900)]
Remove Allocation::bytes

4 years agoFix occurrences of `too_many_lines` violations
Michael Wright [Tue, 3 Sep 2019 04:26:49 +0000 (06:26 +0200)]
Fix occurrences of `too_many_lines` violations

4 years agoFix `too_many_lines` false positive
Michael Wright [Tue, 3 Sep 2019 04:25:54 +0000 (06:25 +0200)]
Fix `too_many_lines` false positive

Fixes #4364

4 years agoAllow deref_addrof in macros
Yuki Okushi [Mon, 2 Sep 2019 14:26:04 +0000 (23:26 +0900)]
Allow deref_addrof in macros

4 years agoFix index out of bound in case of empty snippet
Lzu Tao [Mon, 2 Sep 2019 13:38:40 +0000 (20:38 +0700)]
Fix index out of bound in case of empty snippet

4 years agoAuto merge of #4482 - awoimbee:doc_explicit_counter_loop, r=flip1995
bors [Mon, 2 Sep 2019 12:46:13 +0000 (12:46 +0000)]
Auto merge of #4482 - awoimbee:doc_explicit_counter_loop, r=flip1995

fix misleading doc for explicit_counter_loop lint

changelog: replace misleading examples for explicit_counter_loop & more concise `Why is it bad?` section

This fixes #4472

4 years agoAuto merge of #4477 - mikerite:fix-4291, r=flip1995
bors [Mon, 2 Sep 2019 12:17:47 +0000 (12:17 +0000)]
Auto merge of #4477 - mikerite:fix-4291, r=flip1995

Fix `extra_unused_lifetimes` false positive

Fixes #4291

changelog: Fix `extra_unused_lifetimes` false positive

4 years agofix misleading doc for explicit_counter_loop lint
Arthur Woimée [Sun, 1 Sep 2019 17:59:14 +0000 (19:59 +0200)]
fix misleading doc for explicit_counter_loop lint

4 years agoFix `needless_lifetimes` false positive
Michael Wright [Sun, 1 Sep 2019 06:11:40 +0000 (08:11 +0200)]
Fix `needless_lifetimes` false positive

4 years agoSimplify issue-4291 test
Michael Wright [Sun, 1 Sep 2019 05:55:29 +0000 (07:55 +0200)]
Simplify issue-4291 test

4 years agoFix `extra_unused_lifetimes` false positive
Michael Wright [Sat, 31 Aug 2019 06:16:04 +0000 (08:16 +0200)]
Fix `extra_unused_lifetimes` false positive

Fixes #4291

4 years agoAuto merge of #4473 - phansch:fix_cast_lossless_fp, r=flip1995
bors [Fri, 30 Aug 2019 20:30:53 +0000 (20:30 +0000)]
Auto merge of #4473 - phansch:fix_cast_lossless_fp, r=flip1995

Fix cast_lossless false positive in impl const fn

Fixes https://github.com/rust-lang/rust-clippy/issues/3656#issuecomment-526387382

changelog: Fix false positive in `cast_lossless`

4 years agoAuto merge of #4475 - flip1995:rustup, r=phansch
bors [Fri, 30 Aug 2019 08:12:11 +0000 (08:12 +0000)]
Auto merge of #4475 - flip1995:rustup, r=phansch

Rustup to rust-lang/rust#60966

changelog: none

4 years agoRustup to rust-lang/rust#60966
flip1995 [Fri, 30 Aug 2019 07:33:03 +0000 (09:33 +0200)]
Rustup to rust-lang/rust#60966

4 years agoAuto merge of #4446 - mikerite:fix-4437, r=phansch
bors [Fri, 30 Aug 2019 06:07:41 +0000 (06:07 +0000)]
Auto merge of #4446 - mikerite:fix-4437, r=phansch

Fix `match_as_ref` bad suggestion

Fixes #4437

changelog: Fix `match_as_ref` bad suggestion

4 years agoFix cast_lossless false positive in impl const fn
Philipp Hansch [Fri, 30 Aug 2019 05:22:35 +0000 (07:22 +0200)]
Fix cast_lossless false positive in impl const fn

Fixes https://github.com/rust-lang/rust-clippy/issues/3656#issuecomment-526387382

4 years agoAuto merge of #4450 - phansch:fix_const_fn_fp, r=flip1995
bors [Thu, 29 Aug 2019 17:24:21 +0000 (17:24 +0000)]
Auto merge of #4450 - phansch:fix_const_fn_fp, r=flip1995

Fix missing_const_for_fn false positive

We don't want to lint if the type of the method implements drop.
(constant functions cannot evaluate destructors)

changelog: Fix `missing_const_for_fn` false positive

Fixes #4449

4 years agoAdd missing UI test change
Philipp Hansch [Thu, 29 Aug 2019 16:37:43 +0000 (18:37 +0200)]
Add missing UI test change

4 years agoFix tests
flip1995 [Wed, 28 Aug 2019 08:52:23 +0000 (10:52 +0200)]
Fix tests

4 years agoUse the spans returned by utils::method_calls
flip1995 [Wed, 28 Aug 2019 08:41:32 +0000 (10:41 +0200)]
Use the spans returned by utils::method_calls

4 years agoAlso return the method spans in utils::method_calls
flip1995 [Wed, 28 Aug 2019 08:41:06 +0000 (10:41 +0200)]
Also return the method spans in utils::method_calls

4 years agoDereference one less on search_is_some and make it auto-fixable
BO41 [Mon, 26 Aug 2019 10:50:15 +0000 (12:50 +0200)]
Dereference one less on search_is_some and make it auto-fixable

4 years agoAuto merge of #4408 - phansch:more_rustfix_tests, r=flip1995
bors [Thu, 29 Aug 2019 10:48:14 +0000 (10:48 +0000)]
Auto merge of #4408 - phansch:more_rustfix_tests, r=flip1995

More rustfix tests

<!--
Thank you for making Clippy better!

We're collecting our changelog from pull request descriptions.
If your PR only updates to the latest nightly, you can leave the
`changelog` entry as `none`. Otherwise, please write a short comment
explaining your change.

If your PR fixes an issue, you can add "fixes #issue_number" into this
PR description. This way the issue will be automatically closed when
your PR is merged.

If you added a new lint, here's a checklist for things that will be
checked during review or continuous integration.

- [ ] Followed [lint naming conventions][lint_naming]
- [ ] Added passing UI tests (including committed `.stderr` file)
- [ ] `cargo test` passes locally
- [ ] Executed `./util/dev update_lints`
- [ ] Added lint documentation
- [ ] Run `./util/dev fmt`

[lint_naming]: https://rust-lang.github.io/rfcs/0344-conventions-galore.html#lints

Note that you can skip the above if you are just opening a WIP PR in
order to get feedback.

Delete this line and everything above before opening your PR -->

cc #3630

This is probably easier reviewed per-commit.

changelog: none

4 years agoAuto merge of #4469 - vityafx:master, r=flip1995
bors [Thu, 29 Aug 2019 10:19:26 +0000 (10:19 +0000)]
Auto merge of #4469 - vityafx:master, r=flip1995

Improve the cognitive_complexity lint's warning.

Adds the value of complexity limit set for the lint
to the warning.

Fixes #4466

Signed-off-by: Victor Polevoy <fx@thefx.co>
changelog: improve the `cognitive_complexity` lint's warning message.

4 years agoImprove cognitive_complexity lint's warning.
Victor Polevoy [Thu, 29 Aug 2019 08:56:13 +0000 (10:56 +0200)]
Improve cognitive_complexity lint's warning.

Adds the value of complexity limit set for the lint
to the warning.

Fixes #4466

Signed-off-by: Victor Polevoy <fx@thefx.co>
4 years agoMerge branch 'master' into fix-4437
Michael Wright [Thu, 29 Aug 2019 06:17:36 +0000 (08:17 +0200)]
Merge branch 'master' into fix-4437

4 years agoFix missing_const_for_fn false positive
Philipp Hansch [Sun, 25 Aug 2019 13:44:22 +0000 (15:44 +0200)]
Fix missing_const_for_fn false positive

We don't want to lint if any of the input parameters implement drop.

(constant functions cannot evaluate destructors)

4 years agoMake useless_attribute suggestion MaybeIncorrect
Philipp Hansch [Wed, 28 Aug 2019 19:17:12 +0000 (21:17 +0200)]
Make useless_attribute suggestion MaybeIncorrect

4 years agoAuto merge of #4465 - JohnTitor:add-note-to-fix-toolstate, r=flip1995
bors [Wed, 28 Aug 2019 16:09:08 +0000 (16:09 +0000)]
Auto merge of #4465 - JohnTitor:add-note-to-fix-toolstate, r=flip1995

Add note to fix toolstate

The idea from https://github.com/rust-lang/rust-clippy/pull/4462#issuecomment-525725587
It's nice that we have the documentation to guide fix toolstate.

changelog: none

4 years agoAdd note to fix toolstate
Yuki Okushi [Wed, 28 Aug 2019 12:46:04 +0000 (21:46 +0900)]
Add note to fix toolstate

4 years agoAuto merge of #4464 - flip1995:fetch_prs_between, r=phansch
bors [Wed, 28 Aug 2019 12:37:29 +0000 (12:37 +0000)]
Auto merge of #4464 - flip1995:fetch_prs_between, r=phansch

Also fetch rollup merges in fetch_prs_between.sh script

Otherwise rolled up PRs won't be included in the changelog, e.g. 236666138fa15fdd48b1c12180b2c9dc936441b4

changelog: none

4 years agoAlso fetch rollup merges in fetch_prs_between.sh script
flip1995 [Wed, 28 Aug 2019 11:53:56 +0000 (13:53 +0200)]
Also fetch rollup merges in fetch_prs_between.sh script

4 years agoAuto merge of #4463 - flip1995:rollup-240kr2c, r=flip1995
bors [Wed, 28 Aug 2019 11:11:43 +0000 (11:11 +0000)]
Auto merge of #4463 - flip1995:rollup-240kr2c, r=flip1995

Rollup of 2 pull requests

Successful merges:

 - #4459 (Add note to avoid confusing)
 - #4460 (Fix `inherent_to_string` false positive)

Failed merges:

r? @ghost

changelog: none

4 years agoRollup merge of #4460 - JohnTitor:fix-inherent-to-string, r=flip1995
Philipp Krones [Wed, 28 Aug 2019 11:00:52 +0000 (13:00 +0200)]
Rollup merge of #4460 - JohnTitor:fix-inherent-to-string, r=flip1995

Fix `inherent_to_string` false positive

Fixes #4457

changelog: fixes `inherent_to_string` false positive

4 years agoRollup merge of #4459 - JohnTitor:update-testing-notes, r=flip1995
Philipp Krones [Wed, 28 Aug 2019 11:00:51 +0000 (13:00 +0200)]
Rollup merge of #4459 - JohnTitor:update-testing-notes, r=flip1995

Add note to avoid confusing

Fixes #4456

changelog: none

4 years agoAuto merge of #4462 - JohnTitor:fix-build-arg, r=flip1995
bors [Wed, 28 Aug 2019 10:28:30 +0000 (10:28 +0000)]
Auto merge of #4462 - JohnTitor:fix-build-arg, r=flip1995

Replace `Arg` with `Param`

Fix build issue.
Rustup to https://github.com/rust-lang/rust/pull/63127

changelog: none

4 years agoReplace `Arg` with `Param`
Yuki Okushi [Wed, 28 Aug 2019 09:27:06 +0000 (18:27 +0900)]
Replace `Arg` with `Param`

4 years agoUpdate int_plus_one suggestion text
Philipp Hansch [Wed, 28 Aug 2019 05:29:30 +0000 (07:29 +0200)]
Update int_plus_one suggestion text

This is now in line with the recommendations from here:
https://doc.rust-lang.org/nightly/nightly-rustc/rustc_errors/struct.Diagnostic.html#method.span_suggestion

4 years agoChange float_cmp Applicability to `HasPlaceholders`
Philipp Hansch [Mon, 19 Aug 2019 06:00:39 +0000 (08:00 +0200)]
Change float_cmp Applicability to `HasPlaceholders`

The suggestion includes an 'errors' placeholder currently, so it's not
`MachineApplicable`

4 years agoAdd run-rustfix for rename test
Philipp Hansch [Sun, 18 Aug 2019 07:37:12 +0000 (09:37 +0200)]
Add run-rustfix for rename test

I removed the `Bar` static and `Foo` impl because they are not needed
for what's tested here as far as I can tell.

4 years agoAdd run-rustfix for outer_expn_data
Philipp Hansch [Sun, 18 Aug 2019 07:32:38 +0000 (09:32 +0200)]
Add run-rustfix for outer_expn_data

4 years agoAdd run-rustfix for useless_attribute test
Philipp Hansch [Sun, 18 Aug 2019 07:27:09 +0000 (09:27 +0200)]
Add run-rustfix for useless_attribute test

4 years agoAdd run-rustfix for int_plus_one test
Philipp Hansch [Sun, 18 Aug 2019 07:24:30 +0000 (09:24 +0200)]
Add run-rustfix for int_plus_one test

4 years agoAdd run-rustfix for assign_ops test
Philipp Hansch [Sun, 18 Aug 2019 07:22:49 +0000 (09:22 +0200)]
Add run-rustfix for assign_ops test

4 years agoFix `inherent_to_string` false positive
Yuki Okushi [Tue, 27 Aug 2019 19:23:26 +0000 (04:23 +0900)]
Fix `inherent_to_string` false positive

4 years agoAdd note to avoid confusing
Yuki Okushi [Tue, 27 Aug 2019 17:54:03 +0000 (02:54 +0900)]
Add note to avoid confusing

4 years agoAuto merge of #4444 - phansch:split_up_cmp_owned2, r=flip1995
bors [Mon, 26 Aug 2019 14:32:12 +0000 (14:32 +0000)]
Auto merge of #4444 - phansch:split_up_cmp_owned2, r=flip1995

Split up cmp_owned tests, add run-rustfix

Some of the cmp_owned tests emitted non-machine-applicable suggestions,
so I moved them to `tests/ui/cmp_owned/without_suggestion.rs` and added
`// run-rustfix` to the other half.

changelog: none

cc #3630

4 years agoAuto merge of #4445 - phansch:fix_unused_unit_sugg, r=flip1995
bors [Mon, 26 Aug 2019 13:29:01 +0000 (13:29 +0000)]
Auto merge of #4445 - phansch:fix_unused_unit_sugg, r=flip1995

Fix unused_unit false positive

changelog: Fix `unused_unit` false positive

For some reason the `expr` of `stmt.node` didn't contain the expansion information, but the `stmt.span` does.

Fixes #4076

4 years agoUse correct path in comment
Philipp Hansch [Mon, 26 Aug 2019 13:28:35 +0000 (15:28 +0200)]
Use correct path in comment

Co-Authored-By: Philipp Krones <hello@philkrones.com>
4 years agoAuto merge of #4430 - lzutao:defid_trait_alias, r=flip1995
bors [Mon, 26 Aug 2019 12:46:00 +0000 (12:46 +0000)]
Auto merge of #4430 - lzutao:defid_trait_alias, r=flip1995

Account for trait alias when looking for defid

I hit the crash on the `expect` call when running clippy on rustc libcore.
Hopefully this will fix it.
changelog: none

4 years agoAdd regression test for looking for trait defid in nocore
Lzu Tao [Mon, 26 Aug 2019 10:11:47 +0000 (17:11 +0700)]
Add regression test for looking for trait defid in nocore

4 years agoAuto merge of #4436 - BO41:written_as, r=phansch
bors [Mon, 26 Aug 2019 11:11:57 +0000 (11:11 +0000)]
Auto merge of #4436 - BO41:written_as, r=phansch

Add some "could be written as" examples

fixes #4405
changelog: none

4 years agoAuto merge of #4421 - lzutao:unsep_literal, r=flip1995
bors [Mon, 26 Aug 2019 10:32:24 +0000 (10:32 +0000)]
Auto merge of #4421 - lzutao:unsep_literal, r=flip1995

Cleaner code for unsep literals

Continuing discussion in https://github.com/rust-lang/rust-clippy/pull/4401#issuecomment-522498754
changelog: none
r? @flip1995

4 years agoAuto merge of #4451 - hvenev:non-exec, r=flip1995
bors [Mon, 26 Aug 2019 09:53:34 +0000 (09:53 +0000)]
Auto merge of #4451 - hvenev:non-exec, r=flip1995

Mark rust source file as non-executable.

It would be nice if you can backport this to beta as well.

changelog: none

4 years agoAuto merge of #4431 - phansch:more_rustfix, r=flip1995
bors [Mon, 26 Aug 2019 09:15:20 +0000 (09:15 +0000)]
Auto merge of #4431 - phansch:more_rustfix, r=flip1995

Add 3 more run-rustfix headers

changelog: none

cc #3630

4 years agoCleaner code for unsep literals
Lzu Tao [Mon, 26 Aug 2019 09:11:43 +0000 (16:11 +0700)]
Cleaner code for unsep literals

4 years agoRemove empty *.std{err,out} files
flip1995 [Mon, 26 Aug 2019 08:06:24 +0000 (10:06 +0200)]
Remove empty *.std{err,out} files

4 years agoMark rust source file as non-executable.
Hristo Venev [Sun, 25 Aug 2019 17:49:45 +0000 (17:49 +0000)]
Mark rust source file as non-executable.

4 years agoAccount for trait alias when looking for defid
Lzu Tao [Thu, 22 Aug 2019 03:03:26 +0000 (10:03 +0700)]
Account for trait alias when looking for defid

4 years agoAuto merge of #4447 - phansch:fix_build, r=matthiaskrgr
bors [Sun, 25 Aug 2019 06:25:35 +0000 (06:25 +0000)]
Auto merge of #4447 - phansch:fix_build, r=matthiaskrgr

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

changelog: none

4 years agoRustup to https://github.com/rust-lang/rust/pull/63854
Philipp Hansch [Sun, 25 Aug 2019 06:06:32 +0000 (08:06 +0200)]
Rustup to https://github.com/rust-lang/rust/pull/63854

4 years agoFix `match_as_ref` bad suggestion
Michael Wright [Sun, 25 Aug 2019 05:10:45 +0000 (07:10 +0200)]
Fix `match_as_ref` bad suggestion

Fixes #4437

4 years agoFix unused_unit false positive
Philipp Hansch [Sat, 24 Aug 2019 19:42:39 +0000 (21:42 +0200)]
Fix unused_unit false positive

Fixes #4076

4 years agoFix lint doc
BO41 [Sat, 24 Aug 2019 09:34:40 +0000 (11:34 +0200)]
Fix lint doc

4 years agoSplit up cmp_owned tests, add run-rustfix
Philipp Hansch [Sat, 24 Aug 2019 07:23:06 +0000 (09:23 +0200)]
Split up cmp_owned tests, add run-rustfix

Some of the cmp_owned tests emitted non-machine-applicable suggestions,
so I moved them to `tests/ui/cmp_owned/without_suggestion.rs` and added
`// run-rustfix` to the other half.

cc #3630

4 years agoAuto merge of #4443 - jeremystucki:methods-refactoring, r=phansch
bors [Sat, 24 Aug 2019 07:45:29 +0000 (07:45 +0000)]
Auto merge of #4443 - jeremystucki:methods-refactoring, r=phansch

Small refactoring of methods/mod.rs

changelog: none

4 years agoRefactor some minor things
Jeremy Stucki [Fri, 23 Aug 2019 20:52:04 +0000 (22:52 +0200)]
Refactor some minor things

4 years agoUse more if-chains
Jeremy Stucki [Fri, 23 Aug 2019 20:51:44 +0000 (22:51 +0200)]
Use more if-chains