Philipp Krones
9305659922
Book: Improve chapter on CI
...
Recommend the -Dwarnings and --all-targets/--all-features more strongly.
2022-06-06 16:17:58 +02:00
Philipp Krones
1f11cd17ac
Remove bit-rotty list of Clippy team members from CONTRIBUTING.md
2022-06-06 16:17:58 +02:00
flip1995
b551928800
Auto update lint count in Clippy book
2022-06-06 16:17:58 +02:00
flip1995
c9cbead656
Book: Add infrastructure description
2022-06-06 16:17:57 +02:00
flip1995
b37d24f7ff
Move parts of CONTRIBUTING.md to the book
2022-06-06 16:17:57 +02:00
flip1995
cbe4de2f6c
Book: Add continuous integration description
2022-06-06 16:17:57 +02:00
flip1995
6b21d386f6
Book: Add Proposals description
2022-06-06 16:17:57 +02:00
flip1995
97bceb0e31
Book: Restructure Dev chapter
...
Group everything that has something to do with Clippy development under
the "Development" chapter, so that Clippy users can't get confused.
2022-06-06 16:16:11 +02:00
flip1995
0e42282ed5
Book: Write lint group descriptions
...
This removes the empty separate files for the different groups and adds
a single file giving short explanations for each group and what to
expect from those groups.
2022-06-06 16:16:07 +02:00
flip1995
d12a5c3a52
Book: Split up and rewrite installation and usage
2022-06-06 16:16:01 +02:00
flip1995
404432b791
Book: Update GHA doc and remove GitLab placeholder
2022-06-06 16:15:53 +02:00
flip1995
b374e0f696
Remove Edition 2018 tests section from adding lints doc
...
The UI tests now use the latest edition by default. Testing on older
editions should almost never be necessary, so I don't see a need to
document this.
2022-06-06 16:15:53 +02:00
flip1995
d6b013ff9e
Reformat internal docs
...
This reformats all the internal docs, so that the md files use at most
80 characters per line. This is the usual formatting of md files. We
allow 120 chars per line in CI though.
2022-06-06 16:15:53 +02:00
flip1995
206ec6e2f6
Move syncing doc to book
2022-06-06 16:15:53 +02:00
flip1995
af385799e0
Move internal documentation to book
2022-06-06 16:15:53 +02:00
josh rotenberg
853d7eeed6
Book: add a ci chapter
2022-06-06 16:15:52 +02:00
josh rotenberg
4e6b55e9b8
Initial commit for the Clippy Book
2022-06-06 16:15:52 +02:00
bors
0f6e50fe1b
Auto merge of #8933 - DennisOSRM:needless_braces_range_literal, r=dswij
...
Add new lint [`needless_parens_on_range_literals`]
changelog: Adds a new lint [`needless_parens_on_range_literals`] to warn on needless braces on literals in a range statement
For example, the lint would catch
```log
error: needless parenthesis on range literals can be removed
--> $DIR/needless_parens_on_range_literals.rs:8:13
|
LL | let _ = ('a')..=('z');
| ^^^^^ help: try: `'a'`
|
= note: `-D clippy::needless-parens-on-range-literals` implied by `-D warnings`
```
2022-06-06 10:58:33 +00:00
bors
3e771624e1
Auto merge of #8951 - mikerite:needless-late-init-20220605, r=giraffate
...
Some refactoring in `needless_late_init`
changelog: none
2022-06-06 00:25:14 +00:00
Dennis Luxen
61d7dd2af0
Update CHANGELOG.md
2022-06-05 22:47:29 +02:00
Dennis Luxen
8ba377a783
Fix names to use plural
2022-06-05 22:47:21 +02:00
Dennis Luxen
bf7a786481
Apply suggestions from code review
...
Co-authored-by: dswij <dharmasw@outlook.com>
2022-06-05 22:47:15 +02:00
Dennis Luxen
58a605f453
Rerun cargo dev update_lints
2022-06-05 22:47:08 +02:00
Dennis Luxen
c0aa1f78b4
Implement suggestion generation with snippet_with_applicability(.)
2022-06-05 22:47:01 +02:00
Dennis Luxen
0409306bb0
Implement support for implicit start and end
2022-06-05 22:46:53 +02:00
Dennis Luxen
2e6903ccf9
Move description into lint macro
2022-06-05 22:46:41 +02:00
Dennis Luxen
90c8463d7e
Rewrite check to account for floating point literals
2022-06-05 22:46:34 +02:00
Dennis Luxen
5948959c7e
Fix misnomer braces -> parenthesis
2022-06-05 22:46:23 +02:00
Dennis Luxen
8bc1be17d6
Update clippy_lints/src/needless_braces_on_range_literal.rs
...
Co-authored-by: Alex <69764315+Serial-ATA@users.noreply.github.com>
2022-06-05 22:46:11 +02:00
Dennis Luxen
3058cb941c
Update clippy_lints/src/needless_braces_on_range_literal.rs
...
Co-authored-by: Alex <69764315+Serial-ATA@users.noreply.github.com>
2022-06-05 22:46:03 +02:00
Dennis Luxen
ba43f0aee9
Add new lint [needless_braces_on_range_literal
]
2022-06-05 22:45:57 +02:00
bors
3e52dee646
Auto merge of #8941 - DevAccentor:for_loops_over_fallibles, r=llogiq
...
improve [`for_loops_over_fallibles`] to detect the usage of iter, iter_mut and into_iterator
fix #6762
detects code like
```rust
for _ in option.iter() {
//..
}
```
changelog: Improve [`for_loops_over_fallibles`] to detect `for _ in option.iter() {}` or using `iter_mut()` or `into_iterator()`.
2022-06-05 11:16:37 +00:00
DevAccentor
3737abe802
change based on review
2022-06-05 10:26:29 +02:00
Michael Wright
a2de34720d
needless_late_init refactoring
...
Remove the unneeded wrapping and unwrapping in suggestion creation.
Collecting to Option<Vec<_>> only returns None if one of the elements is
None and that is never the case here.
2022-06-05 07:30:59 +02:00
Michael Wright
2a1a80d80c
needless_late_init refactoring
...
Simplify the creation of suggestions by using `flat_map` instead of
`chain`. Note that the order of the suggestions is not important.
2022-06-05 07:30:59 +02:00
Michael Wright
94e321a6ff
needless_late_init refactoring
...
Remove duplication in creating suggestions by first mapping assignments
to spans and then suggestions.
2022-06-05 07:30:59 +02:00
bors
542d474d38
Auto merge of #8930 - kyoto7250:issue_8920, r=Alexendoo
...
fix(manual_find_map and manual_filter_map): check clone method
close #8920
Added conditional branching when the clone method is used.
Thank you in advance.
---
changelog: check `clone()` and other variant preserving methods in [`manual_find_map`] and [`manual_filter_map`]
2022-06-04 13:05:27 +00:00
kyoto7250
42cf98553a
refactor: check copied and cloned
2022-06-04 21:28:14 +09:00
bors
d9ddce8a22
Auto merge of #8942 - flip1995:rustup, r=flip1995
...
Rustup
r? `@ghost`
changelog: none
2022-06-04 10:55:48 +00:00
Philipp Krones
36b18924a7
Bump nightly version -> 2022-06-04
2022-06-04 12:54:20 +02:00
Philipp Krones
7f402b15c7
Merge remote-tracking branch 'upstream/master' into rustup
2022-06-04 12:53:27 +02:00
bors
8ef490871c
Auto merge of #8843 - Serial-ATA:collect-renamed, r=xFrednet
...
Collect renamed lints
changelog: Display past names of renamed lints on Clippy's lint list
cc #7172
r? `@xFrednet`
2022-06-04 09:49:27 +00:00
DevAccentor
5a49918f36
improve for_loops_over_fallibles to detect the usage of iter, iter_mut and into_iterator
2022-06-04 11:11:00 +02:00
kyoto7250
990f8bf5a6
refactor: Add some methods
2022-06-04 17:15:55 +09:00
bors
b1a3e7e9c8
Auto merge of #8937 - Jarcho:merge_match_passes, r=llogiq
...
Merge various passes into `Matches`
changelog: None
2022-06-04 07:41:27 +00:00
Jason Newcomb
68c411ff94
Move ManualMap
into Matches
lint pass
2022-06-03 19:09:50 -04:00
Jason Newcomb
67cb5ec29f
Move TryErr
into Matches
lint pass
2022-06-03 19:09:49 -04:00
Jason Newcomb
dbc7753fb2
Merge SignificantDropInScrutinee
into Matches
lint pass
2022-06-03 19:09:49 -04:00
Jason Newcomb
8c8a52eeeb
Move MatchStrCaseMismatch
into Matches
lint pass
2022-06-03 19:09:49 -04:00
Jason Newcomb
3d8d734150
Move MatchOnVecItems
into Matches
lint pass
2022-06-03 19:09:49 -04:00