Commit graph

168 commits

Author SHA1 Message Date
Philipp Hansch
7226291025
Upgrade compiletest-rs to 0.6 and tester to 0.9
These updates allow us to specify multiple testnames for `TESTNAME`.

The new version of compiletest-rs also includes `bless` support, but is
not enabled with this PR.
2021-02-15 20:13:44 +01:00
Manish Goregaokar
c8cb90abbd Merge commit '3e4179766bcecd712824da04356621b8df012ea4' into sync-from-clippy 2021-02-02 20:43:30 -08:00
flip1995
ac912be984 Merge commit '95c0459217d1661edfa794c8bb122452b92fb485' into clippyup 2021-01-30 18:06:34 +01:00
xFrednet
69f2b8f0f8 Updated some NITs in the documentation from #6630 2021-01-25 19:46:19 +01:00
xFrednet
0373dc3ade Added documentation for adding a configuration to lints
* Fixed some spelling
2021-01-24 21:16:41 +01:00
xFrednet
a905cf6737 Added documentation for common abbreviations
This list was created as a collaborative effort on Zulip and the [thread] is definitely worth a read as we had quite some fun. A big **THANK YOU** goes out to everyone who participated you make this project fun to work on!!!

The Zulip [thread]: https://rust-lang.zulipchat.com/#narrow/stream/257328-clippy/topic/Common.20abbreviations.20in.20basics.2Emd/near/223548065
2021-01-22 00:25:24 +01:00
flip1995
488153ff2f Merge commit '953f024793dab92745fee9cd2c4dee6a60451771' into clippyup 2021-01-15 10:56:44 +01:00
bors
13ca5c88f1 Auto merge of #6462 - flip1995:roadmap, r=flip1995,llogiq,killercup,Manishearth,oli-obk,matthiaskrgr,phansch,mikerite,mcarton,yaahc,ebroto
Roadmap for 2021

[Rendered](https://github.com/flip1995/rust-clippy/blob/roadmap/doc/roadmap-2021.md)

This is the first time Clippy gets its own roadmap. The reason for this roadmap is, that with the Rust language growing, also Clippy is growing. With this keeping track of and implementing bigger projects gets quite hard. This roadmap should help in exactly this regard.

After having the approval of this roadmap by the Clippy team, we want to know from the community:

- What do you think in general about this roadmap?
- Are there any pain points in Clippy, that should be included here?
- What of the points listed here has the highest priority for you?

We're looking forward to getting your feedback!

changelog: Add roadmap for Clippy 2021

r? `@rust-lang/clippy`
2021-01-12 16:33:47 +00:00
flip1995
547ce0db27
Change env var used for testing Clippy
This changes the variable used for testing Clippy in the internal test
suite:

```
CLIPPY_TESTS -> __CLIPPY_INTERNAL_TESTS
```

`CLIPPY_TESTS` is understandably used in environments of Clippy users,
so we shouldn't use it in our test suite.
2021-01-07 12:38:10 +01:00
flip1995
d141cdc947
Add prioritization chapter and remove unresolved questions 2021-01-04 11:39:14 +01:00
flip1995
f03edfd7a1 Merge commit '4911ab124c481430672a3833b37075e6435ec34d' into clippyup 2020-12-20 17:19:49 +01:00
flip1995
c06793bbe7
Add Roadmap for 2021 2020-12-17 21:44:40 +01:00
Matthias Krüger
27dc565d28 cargo dev: rename ra-setup to ra_setup to be in line with the other commands 2020-12-13 18:52:46 +01:00
Philipp Hansch
4bd9ed9b88
Rewrite update-all-references bash scripts in Rust
This replaces the `update-all-references` scripts with a single

    cargo dev bless

command.

cc #5394
2020-12-12 15:09:57 +01:00
bors
baf5f2da8b Auto merge of #6401 - ebroto:pin_to_a_nightly, r=ebroto
📌 Pin Clippy to a nightly 📌

changelog: Pin Clippy to a specific nightly version (No more master/custom toolchain required to compile Clippy)

Addresses partially #5561. As proposed there in [this comment](https://github.com/rust-lang/rust-clippy/issues/5561#issuecomment-623109095), this kicks off the process, to help us get acquainted with how the syncs should work, before working on improving the tooling.

Open questions:
* When performing a rustup, we will need to exclude the commits that were merged that same day, or else wait until that nightly is released. I did not update the documentation about this part, mainly because I'm not sure about how to do that.
* When should we perform the rustups now? My first idea is to do it at the same time we do the clippyups, to have a clear cadence and to avoid the two copies of the repo to diverge enough to make the process painful.
* Who does the rustups now? If we follow my previous idea and do both rustup and clippyup at the same time, it would be more work for `@flip1995` who currently does the clippyups. I would prefer to establish some kind of rotation to spead the work. Other ideas?
* I'm not sure if this affects the release process in any way.
* ???

`@rust-lang/clippy` thoughts?

r? `@flip1995`
2020-12-11 16:25:13 +00:00
Suyash458
8df11e431b add instructions to include msrv in lints 2020-12-11 11:00:25 +05:30
Eduardo Broto
613333acd5
Pin Clippy to a nightly 2020-12-10 09:57:29 +01:00
flip1995
d3d2018ead Merge commit '3e7c6dec244539970b593824334876f8b6ed0b18' into clippyup 2020-11-23 13:51:04 +01:00
flip1995
e9afdf0740
Improve changlog update documentation 2020-11-19 11:23:59 +01:00
flip1995
34244190d4 Merge commit 'b20d4c155d2fe3a8391f86dcf9a8c49e17188703' into clippyup 2020-11-05 14:29:48 +01:00
dp304
edfa13da4a Fix typo in adding_lints.md 2020-10-31 13:31:54 +01:00
Eduardo Broto
cdb555f4fc Merge commit 'bf1c6f9871f430e284b17aa44059e0d0395e28a6' into clippyup 2020-10-23 22:16:59 +02:00
bors
85959be606 Auto merge of #6193 - Ryan1729:add-more-LintStore-documentation, r=phansch
Add more infomation about LintStore registration

Backstory: I somehow missed the fact that I needed to register a lint pass in order for it to run, and I spent some time confused until I figured it out. So I wanted to make it clear that a missing `register_(early|late)_pass` call is a likely cause of a lint not running.

changelog: none
2020-10-20 09:38:38 +00:00
bors
74530adcba Auto merge of #6166 - achris:master, r=flip1995
Suggest a compatible shell for setup-toolchain.sh

setup-toolchain.sh uses "[[" which is a bash builtin, but the guide
suggests running it with sh.  On Ubuntu, /bin/sh points to dash and
running the script fails.

---

*Please keep the line below*
changelog: none
2020-10-19 13:17:07 +00:00
Ryan Wiedemann
67bc11bd04
Add more infomation about LintStore registration
Backstory: I somehow missed the fact that I needed to register a lint pass in order for it to run, and I spent some time confused until I figured it out. So I wanted to make it clear that a missing `register_(early|late)_pass` call is a likely cause of a lint not running.
2020-10-18 17:01:57 -06:00
Eduardo Broto
2da121d97f Fix remark linting on checkboxes 2020-10-14 23:26:48 +02:00
Chris Ayoup
8c28ba39b5 suggest a compatible shell for running setup-toolchain.sh
setup-toolchain.sh uses "[[" which is a bash builtin, but the guide
suggests running it with sh.  On Ubuntu, /bin/sh points to dash and
running the script as described fails.
2020-10-12 21:56:37 -04:00
Takayuki Nakata
377d1fab1f Remove the generated files by update-references.sh if they are empty 2020-10-11 22:57:22 +09:00
bors
fcf22d90bb Auto merge of #6150 - flip1995:backport_doc_update, r=ebroto
Update backport documentation to the subtree workflow

changelog: none
2020-10-09 13:44:01 +00:00
bors
ed2b457fbe Auto merge of #6148 - flip1995:release_doc, r=ebroto
Update release documentation

When updating the beta branch, we want to reset, instead of rebase. Otherwise we might produce again new commits on the beta branch, that aren't on the master branch.

changelog: none
2020-10-09 13:02:25 +00:00
bors
e87c028a2a Auto merge of #6131 - Ambroisie:fix-doc-tools, r=flip1995
Rename tables to typecheck_result()

While working on #6130, I noticed that part of the documentation was updated to use `LateContext::typeck_results`, but the paragraph still referred to the old `tables` field of `LateContext`.

---

*Please keep the line below*
changelog: none
2020-10-09 12:41:08 +00:00
flip1995
7f846c930b
Update backport documentation to the subtree workflow 2020-10-09 14:16:59 +02:00
flip1995
fbf2430f02 Merge commit '2f6439ae6a6803d030cceb3ee14c9150e91b328b' into clippyup 2020-10-09 12:45:29 +02:00
bors
2f6439ae6a Auto merge of #6136 - dtolnay:serve, r=flip1995
Clippy dev subcommand to build and serve website

This PR adds `clippy dev serve` which will pop open a browser with a local rendered 'ALL the Clippy Lints' website, and re-render as you edit stuff.

---

changelog: none
2020-10-09 08:58:19 +00:00
flip1995
c85cb76064
Update release documentation 2020-10-09 09:40:57 +02:00
Takayuki Nakata
fd61686ad5 Add note that we follow a rustc no merge-commit policy 2020-10-08 23:13:06 +09:00
David Tolnay
e6a71066c8
Clippy dev subcommand to build and serve website 2020-10-08 06:43:02 -07:00
Bruno BELANYI
326090dbb8
fixup! Rename tables to typecheck_result()
Co-authored-by: Takayuki Nakata <f.seasons017@gmail.com>
2020-10-07 17:10:31 +02:00
Bruno BELANYI
9ef311b477 Rename tables to typecheck_result() 2020-10-07 11:59:20 +02:00
flip1995
d1f9cad102 Merge commit 'e636b88aa180e8cab9e28802aac90adbc984234d' into clippyup 2020-09-24 14:49:22 +02:00
Takayuki Nakata
b37e3cdd46 Update documentation about moving from Discord to Zulip 2020-09-17 00:10:24 +09:00
Eduardo Broto
c86a7e5f38 Misc doc updates 2020-09-15 10:29:53 +02:00
flip1995
282c59820b Merge commit '3d0b0e66afdfaa519d8855b338b35b4605775945' into clippyup 2020-08-28 18:43:25 +02:00
Takayuki Nakata
9f827abeb0 Add reference to rustc-dev-guide about lint message 2020-08-13 09:02:49 +09:00
flip1995
027780ca2c Merge commit '09bd400243ed6f7059fedc0c1623aae3792521d6' into clippyup 2020-08-11 17:50:45 +02:00
Camelid
bd71b01a82 Make the docs clearer for new contributors
* Add an easy-to-see note at the top of `CONTRIBUTING.md` that points
  new contributors to the Basics docs
* Add a note about compiler errors as a result of internals changes
  that break Clippy
2020-08-07 16:15:44 -07:00
flip1995
3a4cc9f7f0
Address review comments 2020-07-24 23:17:52 +02:00
flip1995
17903f6d71
Mention lint naming guidelines earlier 2020-07-24 17:48:43 +02:00
flip1995
51f2a6f8b6
Add documentation for basic Clippy hacking 2020-07-22 16:46:32 +02:00
Valentin Lazureanu
5a20489c5c Rename TypeckTables to TypeckResults. 2020-07-17 08:47:04 +00:00
Eduard-Mihai Burtescu
30c046ede4 Use 'tcx for references to AccessLevels wherever possible. 2020-07-03 00:04:48 +03:00
Eduard-Mihai Burtescu
f5ce0e5fe9 rustc_lint: only query typeck_tables_of when a lint needs it. 2020-06-26 02:56:23 +03:00
Lzu Tao
8db24840f7 Merge commit 'ff0993c5e9162ddaea78e83d0f0161e68bd4ea73' into clippy 2020-06-09 14:36:01 +00:00
flip1995
a0e9f9bd0d Merge commit '7ea7cd165ad6705603852771bf82cc2fd6560db5' into clippyup2 2020-05-28 15:45:24 +02:00
flip1995
451badeddf
Run fetch before testing if master contains beta 2020-04-23 23:25:35 +02:00
flip1995
c19ca0e8a8
The beta branch update should not require a force push 2020-04-23 23:25:35 +02:00
flip1995
4619bb243d
Add a note to the beta sections of release.md 2020-04-23 23:25:35 +02:00
bors
ef6ba82fee Auto merge of #5495 - phansch:update_changelog_docs, r=flip1995
Update the changelog update documentation

I just started working on updating the changelog. Hopefully the docs are a bit clearer now?

r? @flip1995

changelog: none
2020-04-20 20:40:45 +00:00
Devin R
489dd2e504 factor ifs into function, add differing mutex test 2020-04-20 15:08:44 -04:00
Philipp Hansch
2141db84eb
Update the changelog update documentation 2020-04-20 20:39:49 +02:00
Devin R
ae820924c4 use if chain 2020-04-20 06:30:01 -04:00
Devin R
fca3537fa3 add note about update-all-refs script, revert redundant pat to master 2020-04-20 06:30:00 -04:00
xiongmao86
cf4e35339b Add an Option<Span> argument to span_lint_and_help. 2020-04-18 18:28:29 +08:00
flip1995
2481d3c74a
Rename rustc -> rustc_middle in doc links 2020-04-04 17:01:42 +02:00
Philipp Krones
2a4493aaa6
Fix typo in release.md
Co-Authored-By: Phil Hansch <dev@phansch.net>
2020-03-30 19:32:48 +02:00
flip1995
d7440a0d7c
Document how to backport changes to beta 2020-03-25 19:52:58 +01:00
flip1995
14534fa071
Document how to create a Clippy release 2020-03-25 19:52:58 +01:00
flip1995
6525127c62
Update changelog_update doc to reflect the actual ordering of the changelog 2020-03-12 21:02:08 +01:00
Yuki Okushi
0de71b0e3a
Move links to the end of each chapter on adding_lints 2020-03-11 06:01:26 +09:00
Yuki Okushi
459fb53f8d
Clean-up adding_lints.md 2020-03-11 05:21:40 +09:00
Chris Simpkins
58dec1ca9c update rust-lang.github.io to rustc-dev-guide.rust-lang.org 2020-03-09 17:58:39 -04:00
Chris Simpkins
d8167128fc transition rustc-guide to rustc-dev-guide 2020-03-05 23:32:04 -05:00
flip1995
2635a602bc
Update some documentation 2020-02-14 14:37:56 +01:00
flip1995
757bbf7feb
Fix markdown Files
Rendered:

[CHANGELOG.md](https://github.com/flip1995/rust-clippy/blob/gha/CHANGELOG.md)
[CODE_OF_CONDUCT.md](https://github.com/flip1995/rust-clippy/blob/gha/CODE_OF_CONDUCT.md)
[CONTRIBUTING.md](https://github.com/flip1995/rust-clippy/blob/gha/CONTRIBUTING.md)
[README.md](https://github.com/flip1995/rust-clippy/blob/gha/README.md)
[clippy_dummy/PUBLISH.md](https://github.com/flip1995/rust-clippy/blob/gha/clippy_dummy/PUBLISH.md)
[doc/adding_lints.md](https://github.com/flip1995/rust-clippy/blob/gha/doc/adding_lints.md)
[etc/relicense/RELICENSE_DOCUMENTATION.md](https://github.com/flip1995/rust-clippy/blob/gha/etc/relicense/RELICENSE_DOCUMENTATION.md)
2020-02-12 09:34:25 +01:00
Krishna Sai Veera Reddy
1e117938cf Remove unnecessary imports from documentation 2020-02-10 19:37:25 -08:00
Philipp Hansch
4d1a11d354
Deprecate util/dev in favor of cargo alias
If you've been using `./util/dev` before, this now becomes `cargo dev`.

The key part of this change is found in `.cargo/config`.

This means one less shell script and a bit more cross-platform support
for contributors.
2020-01-30 21:34:31 +01:00
Yuki Okushi
f60f12f71f Rename span_help_and_lint to span_lint_and_help 2020-01-27 11:17:58 +09:00
Yuki Okushi
84e4bc54e0 Remove trailing whitespaces 2020-01-20 10:56:02 +09:00
Brad Sherman
237a01d116 Update documentation for adding new lints
- Add instructions for adding new lints with
  the new automation
2020-01-15 21:20:51 -06:00
Yuki Okushi
39947992b5 Rustup to rust-lang/rust#67806 2020-01-11 21:50:00 +09:00
Yuki Okushi
9086b17e14 Rustup to rust-lang/rust#67707 2019-12-31 09:17:56 +09:00
Matthias Krüger
98e433d70d
Rustup to rust-lang/rust#66878 2019-12-04 01:34:01 +01:00
Michael Zhang
3328cb25ce
Update adding_lints.md 2019-10-17 12:33:42 -04:00
Matthias Krüger
6038c31637 docs: fix broken link in adding_lints documantation 2019-09-11 21:53:12 +02:00
Luca Beetz
3390c512bc 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
2019-09-06 00:54:49 +02:00
Luca Beetz
47d89ae27f Remove ui/ from TESTNAME for foo lint example 2019-09-04 18:34:19 +02:00
Yuki Okushi
b348aae767 Add note to avoid confusing 2019-08-28 03:17:05 +09:00
bors
6d9ee9e5eb Auto merge of #4372 - phansch:changelog_update, r=flip1995
docs: Explain how to update the changelog

cc @Manishearth Is this more or less how you did it last time?

[Rendered](https://github.com/phansch/rust-clippy/blob/changelog_update/doc/changelog_update.md#changelog-update)

changelog: none
2019-08-21 08:46:10 +00:00
Philipp Hansch
a0f9af2132
Add note on how to find the latest beta commit 2019-08-21 07:23:48 +02:00
Lzu Tao
93c77b7d01 Update if_chain doc link 2019-08-20 09:59:13 +07:00
KRAAI, MATTHEW [VISUS]
204b2f3658 Remove in_macro_or_desugar 2019-08-19 09:30:32 -07:00
Philipp Hansch
38c1971b43
Further text improvements 2019-08-12 19:19:46 +02:00
Philipp Hansch
c90eb4f4b3
Add image 2019-08-12 06:56:54 +02:00
Philipp Hansch
8d24facccb
docs: Explain how to update the changelog 2019-08-11 09:24:03 +02:00
flip1995
99d1cde8d8
Document how to write tests requiring the 2018 edition 2019-08-09 19:14:59 +02:00
Lzu Tao
5cad46d15a template: Update how to format source code with ./util/dev 2019-08-08 21:37:19 +07:00
flip1995
3977843ab5
Update documentation to the dev fmt command 2019-07-07 15:11:38 +02:00
Lzu Tao
7f8e7c0772 doc: Remove pub from trait definition in foo lint example 2019-06-01 19:51:49 +07:00
Manish Goregaokar
7eb8018554 Rename in_macro to in_macro_or_desugar 2019-05-11 21:39:02 -07:00
Matthew Kraai
24bb63383a Document declare_lint_pass! 2019-04-17 06:51:21 -07:00